nl_tokens: Listens for insert media events happening in a Media Modal opened in a Classic Block and inserts the media into the appropriate block .
pl_tokens: function handleInsertClassicBlockMedia ( calypsoPort ) { calypsoPort . addEventListener ( 'message' , onInsertClassicBlockMedia , false ) ; calypsoPort . start ( ) ; function onInsertClassicBlockMedia ( message ) { const action = get ( message , 'data.action' ) ; if ( action !== 'insertClassicBlockMedia' ) { return ; } const editorId = get ( message , 'data.payload.editorId' ) ; const media = get ( <mask> , 'data.payload.media' ) ; tinymce . editors [ editorId ] . execCommand ( 'mceInsertContent' , false , media ) ; } }