update HTML event handlers for M3