update version
use 'wpdialogbeforeopen' as event to update codeblock list
use .on() to attach event handler