asdasd
This commit is contained in:
@@ -1108,6 +1108,23 @@
|
||||
}
|
||||
});
|
||||
|
||||
const ensurePlaceholderCommandStub = (editor) => {
|
||||
if (!editor || !editor.Commands) return;
|
||||
const existing = editor.Commands.get && editor.Commands.get('bridge-placeholder:edit');
|
||||
if (existing) return;
|
||||
editor.Commands.add('bridge-placeholder:edit', {
|
||||
__bridgePlaceholderStub: true,
|
||||
run(ed, sender, opts = {}) {
|
||||
if (sender && sender.set) sender.set('active', 0);
|
||||
const component = opts.component || (ed.getSelected && ed.getSelected());
|
||||
if (window.BridgeBlocksPlaceholder && typeof window.BridgeBlocksPlaceholder.openModal === 'function') {
|
||||
window.BridgeBlocksPlaceholder.openModal(ed, component);
|
||||
}
|
||||
},
|
||||
});
|
||||
};
|
||||
ensurePlaceholderCommandStub(ed);
|
||||
|
||||
try {
|
||||
const textTags = ['p','span','div','br','b','strong','i','em','u','a','ul','ol','li'];
|
||||
if (ed.Config) {
|
||||
|
||||
Reference in New Issue
Block a user