myesn

myEsn2E9

hi
github

wangEditor: Add a floating menu to achieve table selection.

Introduction#

Dynamic GIF effect:
Animation

Introduction of Hover Menu File#

Download and copy it to the project:
wang-editor-table-select-all-hover-menu.js

Add Hover Menu to Table#

Then configure the table hover menu after instantiating the wang-Editor:

const editor = createEditor({
    selector: '#editor-container',
    html: '<p><br></p>',
    config: editorConfig,
    mode: 'default', // or 'simple'
});

// Register menu
wangEditor.Boot.registerMenu(wangEditorTableSelectAllHoverMenu);
// Push after editor creation, or through
// editor.getConfig().hoverbarKeys.table.menuKeys.push(wangEditorTableSelectAllHoverMenu.key);
// Insert at a specified index position
editor.getConfig().hoverbarKeys.table.menuKeys.splice(1, 0, wangEditorTableSelectAllHoverMenu.key);

Complete Code#

Loading...
Ownership of this post data is guaranteed by blockchain and smart contracts to the creator alone.