import { registerPlugin } from '@/wp-externals/plugins'; import EditorPanels, { LlmagnetIcon } from '@/components/editor-panel'; /** * Gutenberg editor entry (adoption plan F2.2, Phase E Lane E1). * * Built by vite.editor.config.ts (NOT the main vite.config.ts) so that * react / react-dom / react-jsx-runtime resolve to the editor's own copies * via the src/wp-externals shims — the bundle ships zero React duplicates. * Enqueued by includes/class-editor-assets.php on enqueue_block_editor_assets * with the wp-* / react script dependencies declared. */ try { if (typeof registerPlugin === 'function' && window.llmagnetEditorData) { registerPlugin('llmagnet', { render: EditorPanels, icon: , }); } } catch (err) { // Never break the editor over our integration. // eslint-disable-next-line no-console console.error('LLMagnet: failed to register editor integration.', err); }