@carbon/ai-chat-components 0.7.0 → 0.7.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/custom-elements.json +1 -1
- package/es/components/code-snippet/src/codemirror/base-setup.js +3 -3
- package/es/components/code-snippet/src/codemirror/codemirror-runtime.d.ts +1 -1
- package/es/components/code-snippet/src/codemirror/codemirror-runtime.js +1 -1
- package/es/components/code-snippet/src/codemirror/content-sync.d.ts +1 -1
- package/es/components/code-snippet/src/codemirror/editor-manager.d.ts +1 -1
- package/es/components/code-snippet/src/codemirror/editor-manager.js +1 -1
- package/es/components/code-snippet/src/codemirror/language-controller.d.ts +1 -1
- package/es/components/code-snippet/src/codemirror/theme.js +1 -1
- package/es-custom/components/card/index.d.ts +11 -0
- package/es-custom/components/card/index.js +11 -0
- package/es-custom/components/card/index.js.map +1 -0
- package/es-custom/components/card/src/card-footer.d.ts +43 -0
- package/es-custom/components/card/src/card-footer.js +141 -0
- package/es-custom/components/card/src/card-footer.js.map +1 -0
- package/es-custom/components/card/src/card-footer.scss.js +13 -0
- package/es-custom/components/card/src/card-footer.scss.js.map +1 -0
- package/es-custom/components/card/src/card-steps.d.ts +28 -0
- package/es-custom/components/card/src/card-steps.js +91 -0
- package/es-custom/components/card/src/card-steps.js.map +1 -0
- package/es-custom/components/card/src/card-steps.scss.js +13 -0
- package/es-custom/components/card/src/card-steps.scss.js.map +1 -0
- package/es-custom/components/card/src/card.d.ts +27 -0
- package/es-custom/components/card/src/card.js +65 -0
- package/es-custom/components/card/src/card.js.map +1 -0
- package/es-custom/components/card/src/card.scss.js +13 -0
- package/es-custom/components/card/src/card.scss.js.map +1 -0
- package/es-custom/components/chain-of-thought/defs.d.ts +54 -0
- package/es-custom/components/chain-of-thought/defs.js +38 -0
- package/es-custom/components/chain-of-thought/defs.js.map +1 -0
- package/es-custom/components/chain-of-thought/index.d.ts +10 -0
- package/es-custom/components/chain-of-thought/index.js +13 -0
- package/es-custom/components/chain-of-thought/index.js.map +1 -0
- package/es-custom/components/chain-of-thought/src/chain-of-thought-step.d.ts +43 -0
- package/es-custom/components/chain-of-thought/src/chain-of-thought-step.js +351 -0
- package/es-custom/components/chain-of-thought/src/chain-of-thought-step.js.map +1 -0
- package/es-custom/components/chain-of-thought/src/chain-of-thought-step.scss.js +13 -0
- package/es-custom/components/chain-of-thought/src/chain-of-thought-step.scss.js.map +1 -0
- package/es-custom/components/chain-of-thought/src/chain-of-thought-toggle.d.ts +33 -0
- package/es-custom/components/chain-of-thought/src/chain-of-thought-toggle.js +107 -0
- package/es-custom/components/chain-of-thought/src/chain-of-thought-toggle.js.map +1 -0
- package/es-custom/components/chain-of-thought/src/chain-of-thought-toggle.scss.js +13 -0
- package/es-custom/components/chain-of-thought/src/chain-of-thought-toggle.scss.js.map +1 -0
- package/es-custom/components/chain-of-thought/src/chain-of-thought.d.ts +41 -0
- package/es-custom/components/chain-of-thought/src/chain-of-thought.js +132 -0
- package/es-custom/components/chain-of-thought/src/chain-of-thought.js.map +1 -0
- package/es-custom/components/chain-of-thought/src/chain-of-thought.scss.js +13 -0
- package/es-custom/components/chain-of-thought/src/chain-of-thought.scss.js.map +1 -0
- package/es-custom/components/chain-of-thought/src/tool-call-data.d.ts +33 -0
- package/es-custom/components/chain-of-thought/src/tool-call-data.js +179 -0
- package/es-custom/components/chain-of-thought/src/tool-call-data.js.map +1 -0
- package/es-custom/components/chain-of-thought/src/tool-call-data.scss.js +13 -0
- package/es-custom/components/chain-of-thought/src/tool-call-data.scss.js.map +1 -0
- package/es-custom/components/chat-button/defs.d.ts +25 -0
- package/es-custom/components/chat-button/defs.js +36 -0
- package/es-custom/components/chat-button/defs.js.map +1 -0
- package/es-custom/components/chat-button/index.d.ts +9 -0
- package/es-custom/components/chat-button/index.js +9 -0
- package/es-custom/components/chat-button/index.js.map +1 -0
- package/es-custom/components/chat-button/src/chat-button.d.ts +40 -0
- package/es-custom/components/chat-button/src/chat-button.js +78 -0
- package/es-custom/components/chat-button/src/chat-button.js.map +1 -0
- package/es-custom/components/chat-button/src/chat-button.scss.js +13 -0
- package/es-custom/components/chat-button/src/chat-button.scss.js.map +1 -0
- package/es-custom/components/code-snippet/index.d.ts +3 -0
- package/es-custom/components/code-snippet/index.js +10 -0
- package/es-custom/components/code-snippet/index.js.map +1 -0
- package/es-custom/components/code-snippet/src/code-snippet-card.d.ts +63 -0
- package/es-custom/components/code-snippet/src/code-snippet-card.js +186 -0
- package/es-custom/components/code-snippet/src/code-snippet-card.js.map +1 -0
- package/es-custom/components/code-snippet/src/code-snippet.d.ts +461 -0
- package/es-custom/components/code-snippet/src/code-snippet.js +678 -0
- package/es-custom/components/code-snippet/src/code-snippet.js.map +1 -0
- package/es-custom/components/code-snippet/src/code-snippet.scss.js +13 -0
- package/es-custom/components/code-snippet/src/code-snippet.scss.js.map +1 -0
- package/es-custom/components/code-snippet/src/codemirror/base-setup.d.ts +12 -0
- package/es-custom/components/code-snippet/src/codemirror/base-setup.js +65 -0
- package/es-custom/components/code-snippet/src/codemirror/base-setup.js.map +1 -0
- package/es-custom/components/code-snippet/src/codemirror/codemirror-loader.d.ts +12 -0
- package/es-custom/components/code-snippet/src/codemirror/codemirror-loader.js +36 -0
- package/es-custom/components/code-snippet/src/codemirror/codemirror-loader.js.map +1 -0
- package/es-custom/components/code-snippet/src/codemirror/codemirror-runtime.d.ts +7 -0
- package/es-custom/components/code-snippet/src/codemirror/codemirror-runtime.js +13 -0
- package/es-custom/components/code-snippet/src/codemirror/codemirror-runtime.js.map +1 -0
- package/es-custom/components/code-snippet/src/codemirror/content-sync.d.ts +12 -0
- package/es-custom/components/code-snippet/src/codemirror/content-sync.js +72 -0
- package/es-custom/components/code-snippet/src/codemirror/content-sync.js.map +1 -0
- package/es-custom/components/code-snippet/src/codemirror/editor-manager.d.ts +28 -0
- package/es-custom/components/code-snippet/src/codemirror/editor-manager.js +75 -0
- package/es-custom/components/code-snippet/src/codemirror/editor-manager.js.map +1 -0
- package/es-custom/components/code-snippet/src/codemirror/language-controller.d.ts +38 -0
- package/es-custom/components/code-snippet/src/codemirror/language-controller.js +220 -0
- package/es-custom/components/code-snippet/src/codemirror/language-controller.js.map +1 -0
- package/es-custom/components/code-snippet/src/codemirror/language-data.d.ts +6 -0
- package/es-custom/components/code-snippet/src/codemirror/language-data.js +1043 -0
- package/es-custom/components/code-snippet/src/codemirror/language-data.js.map +1 -0
- package/es-custom/components/code-snippet/src/codemirror/language-utils.d.ts +79 -0
- package/es-custom/components/code-snippet/src/codemirror/language-utils.js +219 -0
- package/es-custom/components/code-snippet/src/codemirror/language-utils.js.map +1 -0
- package/es-custom/components/code-snippet/src/codemirror/marker-utils.d.ts +123 -0
- package/es-custom/components/code-snippet/src/codemirror/marker-utils.js +183 -0
- package/es-custom/components/code-snippet/src/codemirror/marker-utils.js.map +1 -0
- package/es-custom/components/code-snippet/src/codemirror/theme.d.ts +54 -0
- package/es-custom/components/code-snippet/src/codemirror/theme.js +320 -0
- package/es-custom/components/code-snippet/src/codemirror/theme.js.map +1 -0
- package/es-custom/components/code-snippet/src/dom-utils.d.ts +24 -0
- package/es-custom/components/code-snippet/src/dom-utils.js +63 -0
- package/es-custom/components/code-snippet/src/dom-utils.js.map +1 -0
- package/es-custom/components/code-snippet/src/formatters.d.ts +4 -0
- package/es-custom/components/code-snippet/src/formatters.js +19 -0
- package/es-custom/components/code-snippet/src/formatters.js.map +1 -0
- package/es-custom/components/code-snippet/src/layout-utils.d.ts +22 -0
- package/es-custom/components/code-snippet/src/layout-utils.js +63 -0
- package/es-custom/components/code-snippet/src/layout-utils.js.map +1 -0
- package/es-custom/components/code-snippet/src/streaming-manager.d.ts +24 -0
- package/es-custom/components/code-snippet/src/streaming-manager.js +120 -0
- package/es-custom/components/code-snippet/src/streaming-manager.js.map +1 -0
- package/es-custom/components/feedback/index.d.ts +4 -0
- package/es-custom/components/feedback/index.js +10 -0
- package/es-custom/components/feedback/index.js.map +1 -0
- package/es-custom/components/feedback/src/feedback-buttons.d.ts +63 -0
- package/es-custom/components/feedback/src/feedback-buttons.js +113 -0
- package/es-custom/components/feedback/src/feedback-buttons.js.map +1 -0
- package/es-custom/components/feedback/src/feedback-buttons.scss.js +13 -0
- package/es-custom/components/feedback/src/feedback-buttons.scss.js.map +1 -0
- package/es-custom/components/feedback/src/feedback-buttons.template.d.ts +4 -0
- package/es-custom/components/feedback/src/feedback-buttons.template.js +79 -0
- package/es-custom/components/feedback/src/feedback-buttons.template.js.map +1 -0
- package/es-custom/components/feedback/src/feedback.d.ts +113 -0
- package/es-custom/components/feedback/src/feedback.js +195 -0
- package/es-custom/components/feedback/src/feedback.js.map +1 -0
- package/es-custom/components/feedback/src/feedback.scss.js +13 -0
- package/es-custom/components/feedback/src/feedback.scss.js.map +1 -0
- package/es-custom/components/feedback/src/feedback.template.d.ts +12 -0
- package/es-custom/components/feedback/src/feedback.template.js +115 -0
- package/es-custom/components/feedback/src/feedback.template.js.map +1 -0
- package/es-custom/components/markdown/index.d.ts +2 -0
- package/es-custom/components/markdown/index.js +9 -0
- package/es-custom/components/markdown/index.js.map +1 -0
- package/es-custom/components/markdown/src/markdown-renderer.d.ts +66 -0
- package/es-custom/components/markdown/src/markdown-renderer.js +359 -0
- package/es-custom/components/markdown/src/markdown-renderer.js.map +1 -0
- package/es-custom/components/markdown/src/markdown-token-tree.d.ts +32 -0
- package/es-custom/components/markdown/src/markdown-token-tree.js +180 -0
- package/es-custom/components/markdown/src/markdown-token-tree.js.map +1 -0
- package/es-custom/components/markdown/src/markdown.d.ts +72 -0
- package/es-custom/components/markdown/src/markdown.js +342 -0
- package/es-custom/components/markdown/src/markdown.js.map +1 -0
- package/es-custom/components/markdown/src/markdown.scss.js +13 -0
- package/es-custom/components/markdown/src/markdown.scss.js.map +1 -0
- package/es-custom/components/markdown/src/markdown.template.d.ts +6 -0
- package/es-custom/components/markdown/src/markdown.template.js +29 -0
- package/es-custom/components/markdown/src/markdown.template.js.map +1 -0
- package/es-custom/components/markdown/src/plugins/markdown-it-attrs.d.ts +7 -0
- package/es-custom/components/markdown/src/plugins/markdown-it-attrs.js +84 -0
- package/es-custom/components/markdown/src/plugins/markdown-it-attrs.js.map +1 -0
- package/es-custom/components/markdown/src/plugins/markdown-it-highlight.d.ts +7 -0
- package/es-custom/components/markdown/src/plugins/markdown-it-highlight.js +59 -0
- package/es-custom/components/markdown/src/plugins/markdown-it-highlight.js.map +1 -0
- package/es-custom/components/markdown/src/plugins/markdown-it-task-lists.d.ts +12 -0
- package/es-custom/components/markdown/src/plugins/markdown-it-task-lists.js +73 -0
- package/es-custom/components/markdown/src/plugins/markdown-it-task-lists.js.map +1 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/core.d.ts +26 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/core.js +330 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/core.js.map +1 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/patterns/blocks.d.ts +6 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/patterns/blocks.js +63 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/patterns/blocks.js.map +1 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/patterns/code.d.ts +6 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/patterns/code.js +43 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/patterns/code.js.map +1 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/patterns/index.d.ts +5 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/patterns/index.js +55 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/patterns/index.js.map +1 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/patterns/inline.d.ts +19 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/patterns/inline.js +210 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/patterns/inline.js.map +1 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/patterns/lists.d.ts +13 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/patterns/lists.js +156 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/patterns/lists.js.map +1 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/patterns/tables.d.ts +13 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/patterns/tables.js +216 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/patterns/tables.js.map +1 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/types.d.ts +34 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/types.js +8 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/types.js.map +1 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/utils.d.ts +25 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/utils.js +62 -0
- package/es-custom/components/markdown/src/plugins/markdownItAttrs/utils.js.map +1 -0
- package/es-custom/components/markdown/src/utils/html-helpers.d.ts +2 -0
- package/es-custom/components/markdown/src/utils/html-helpers.js +204 -0
- package/es-custom/components/markdown/src/utils/html-helpers.js.map +1 -0
- package/es-custom/components/markdown/src/utils/table-helpers.d.ts +31 -0
- package/es-custom/components/markdown/src/utils/table-helpers.js +106 -0
- package/es-custom/components/markdown/src/utils/table-helpers.js.map +1 -0
- package/es-custom/components/markdown/src/utils.d.ts +8 -0
- package/es-custom/components/markdown/src/utils.js +31 -0
- package/es-custom/components/markdown/src/utils.js.map +1 -0
- package/es-custom/components/processing/index.d.ts +1 -0
- package/es-custom/components/processing/index.js +9 -0
- package/es-custom/components/processing/index.js.map +1 -0
- package/es-custom/components/processing/src/processing.d.ts +16 -0
- package/es-custom/components/processing/src/processing.js +59 -0
- package/es-custom/components/processing/src/processing.js.map +1 -0
- package/es-custom/components/processing/src/processing.scss.js +13 -0
- package/es-custom/components/processing/src/processing.scss.js.map +1 -0
- package/es-custom/components/reasoning-steps/index.d.ts +4 -0
- package/es-custom/components/reasoning-steps/index.js +11 -0
- package/es-custom/components/reasoning-steps/index.js.map +1 -0
- package/es-custom/components/reasoning-steps/src/reasoning-step.d.ts +33 -0
- package/es-custom/components/reasoning-steps/src/reasoning-step.js +251 -0
- package/es-custom/components/reasoning-steps/src/reasoning-step.js.map +1 -0
- package/es-custom/components/reasoning-steps/src/reasoning-step.scss.js +13 -0
- package/es-custom/components/reasoning-steps/src/reasoning-step.scss.js.map +1 -0
- package/es-custom/components/reasoning-steps/src/reasoning-steps-toggle.d.ts +36 -0
- package/es-custom/components/reasoning-steps/src/reasoning-steps-toggle.js +81 -0
- package/es-custom/components/reasoning-steps/src/reasoning-steps-toggle.js.map +1 -0
- package/es-custom/components/reasoning-steps/src/reasoning-steps-toggle.scss.js +13 -0
- package/es-custom/components/reasoning-steps/src/reasoning-steps-toggle.scss.js.map +1 -0
- package/es-custom/components/reasoning-steps/src/reasoning-steps-toggle.template.d.ts +3 -0
- package/es-custom/components/reasoning-steps/src/reasoning-steps-toggle.template.js +43 -0
- package/es-custom/components/reasoning-steps/src/reasoning-steps-toggle.template.js.map +1 -0
- package/es-custom/components/reasoning-steps/src/reasoning-steps.d.ts +19 -0
- package/es-custom/components/reasoning-steps/src/reasoning-steps.js +112 -0
- package/es-custom/components/reasoning-steps/src/reasoning-steps.js.map +1 -0
- package/es-custom/components/reasoning-steps/src/reasoning-steps.scss.js +13 -0
- package/es-custom/components/reasoning-steps/src/reasoning-steps.scss.js.map +1 -0
- package/es-custom/components/table/index.d.ts +3 -0
- package/es-custom/components/table/index.js +9 -0
- package/es-custom/components/table/index.js.map +1 -0
- package/es-custom/components/table/src/table-loader.d.ts +4 -0
- package/es-custom/components/table/src/table-loader.js +28 -0
- package/es-custom/components/table/src/table-loader.js.map +1 -0
- package/es-custom/components/table/src/table-pagination.template.d.ts +27 -0
- package/es-custom/components/table/src/table-pagination.template.js +55 -0
- package/es-custom/components/table/src/table-pagination.template.js.map +1 -0
- package/es-custom/components/table/src/table-runtime.d.ts +2 -0
- package/es-custom/components/table/src/table-runtime.js +10 -0
- package/es-custom/components/table/src/table-runtime.js.map +1 -0
- package/es-custom/components/table/src/table-skeleton.template.d.ts +6 -0
- package/es-custom/components/table/src/table-skeleton.template.js +34 -0
- package/es-custom/components/table/src/table-skeleton.template.js.map +1 -0
- package/es-custom/components/table/src/table.d.ts +184 -0
- package/es-custom/components/table/src/table.js +543 -0
- package/es-custom/components/table/src/table.js.map +1 -0
- package/es-custom/components/table/src/table.scss.js +13 -0
- package/es-custom/components/table/src/table.scss.js.map +1 -0
- package/es-custom/components/table/src/table.template.d.ts +10 -0
- package/es-custom/components/table/src/table.template.js +89 -0
- package/es-custom/components/table/src/table.template.js.map +1 -0
- package/es-custom/components/table/src/types.d.ts +13 -0
- package/es-custom/components/table/src/types.js +8 -0
- package/es-custom/components/table/src/types.js.map +1 -0
- package/es-custom/components/toolbar/index.d.ts +1 -0
- package/es-custom/components/toolbar/index.js +9 -0
- package/es-custom/components/toolbar/index.js.map +1 -0
- package/es-custom/components/toolbar/src/toolbar.d.ts +38 -0
- package/es-custom/components/toolbar/src/toolbar.js +191 -0
- package/es-custom/components/toolbar/src/toolbar.js.map +1 -0
- package/es-custom/components/toolbar/src/toolbar.scss.js +13 -0
- package/es-custom/components/toolbar/src/toolbar.scss.js.map +1 -0
- package/es-custom/components/workspace-shell/index.d.ts +4 -0
- package/es-custom/components/workspace-shell/index.js +12 -0
- package/es-custom/components/workspace-shell/index.js.map +1 -0
- package/es-custom/components/workspace-shell/src/workspace-shell-body.d.ts +17 -0
- package/es-custom/components/workspace-shell/src/workspace-shell-body.js +50 -0
- package/es-custom/components/workspace-shell/src/workspace-shell-body.js.map +1 -0
- package/es-custom/components/workspace-shell/src/workspace-shell-footer.d.ts +40 -0
- package/es-custom/components/workspace-shell/src/workspace-shell-footer.js +144 -0
- package/es-custom/components/workspace-shell/src/workspace-shell-footer.js.map +1 -0
- package/es-custom/components/workspace-shell/src/workspace-shell-footer.scss.js +13 -0
- package/es-custom/components/workspace-shell/src/workspace-shell-footer.scss.js.map +1 -0
- package/es-custom/components/workspace-shell/src/workspace-shell-header.d.ts +28 -0
- package/es-custom/components/workspace-shell/src/workspace-shell-header.js +78 -0
- package/es-custom/components/workspace-shell/src/workspace-shell-header.js.map +1 -0
- package/es-custom/components/workspace-shell/src/workspace-shell-header.scss.js +13 -0
- package/es-custom/components/workspace-shell/src/workspace-shell-header.scss.js.map +1 -0
- package/es-custom/components/workspace-shell/src/workspace-shell.d.ts +19 -0
- package/es-custom/components/workspace-shell/src/workspace-shell.js +56 -0
- package/es-custom/components/workspace-shell/src/workspace-shell.js.map +1 -0
- package/es-custom/components/workspace-shell/src/workspace-shell.scss.js +13 -0
- package/es-custom/components/workspace-shell/src/workspace-shell.scss.js.map +1 -0
- package/es-custom/globals/decorators/carbon-element.d.ts +37 -0
- package/es-custom/globals/decorators/carbon-element.js +68 -0
- package/es-custom/globals/decorators/carbon-element.js.map +1 -0
- package/es-custom/globals/decorators/index.d.ts +1 -0
- package/es-custom/globals/decorators/index.js +9 -0
- package/es-custom/globals/decorators/index.js.map +1 -0
- package/es-custom/globals/settings.d.ts +2 -0
- package/es-custom/globals/settings.js +20 -0
- package/es-custom/globals/settings.js.map +1 -0
- package/es-custom/globals/utils/uuid.d.ts +5 -0
- package/es-custom/globals/utils/uuid.js +32 -0
- package/es-custom/globals/utils/uuid.js.map +1 -0
- package/es-custom/node_modules/@carbon/utilities/es/documentLang/documentLang.js +9 -0
- package/es-custom/node_modules/@carbon/utilities/es/documentLang/documentLang.js.map +1 -0
- package/es-custom/node_modules/@carbon/utilities/es/overflowHandler/overflowHandler.js +11 -0
- package/es-custom/node_modules/@carbon/utilities/es/overflowHandler/overflowHandler.js.map +1 -0
- package/es-custom/react/ai-label.d.ts +4 -0
- package/es-custom/react/ai-label.js +28 -0
- package/es-custom/react/ai-label.js.map +1 -0
- package/es-custom/react/button.d.ts +6 -0
- package/es-custom/react/button.js +29 -0
- package/es-custom/react/button.js.map +1 -0
- package/es-custom/react/card.d.ts +9 -0
- package/es-custom/react/card.js +43 -0
- package/es-custom/react/card.js.map +1 -0
- package/es-custom/react/chain-of-thought-step.d.ts +4 -0
- package/es-custom/react/chain-of-thought-step.js +32 -0
- package/es-custom/react/chain-of-thought-step.js.map +1 -0
- package/es-custom/react/chain-of-thought-toggle.d.ts +6 -0
- package/es-custom/react/chain-of-thought-toggle.js +31 -0
- package/es-custom/react/chain-of-thought-toggle.js.map +1 -0
- package/es-custom/react/chain-of-thought.d.ts +7 -0
- package/es-custom/react/chain-of-thought.js +33 -0
- package/es-custom/react/chain-of-thought.js.map +1 -0
- package/es-custom/react/chat-button.d.ts +13 -0
- package/es-custom/react/chat-button.js +30 -0
- package/es-custom/react/chat-button.js.map +1 -0
- package/es-custom/react/code-snippet-card.d.ts +4 -0
- package/es-custom/react/code-snippet-card.js +31 -0
- package/es-custom/react/code-snippet-card.js.map +1 -0
- package/es-custom/react/code-snippet.d.ts +4 -0
- package/es-custom/react/code-snippet.js +31 -0
- package/es-custom/react/code-snippet.js.map +1 -0
- package/es-custom/react/content-switcher.d.ts +7 -0
- package/es-custom/react/content-switcher.js +37 -0
- package/es-custom/react/content-switcher.js.map +1 -0
- package/es-custom/react/feedback-buttons.d.ts +4 -0
- package/es-custom/react/feedback-buttons.js +31 -0
- package/es-custom/react/feedback-buttons.js.map +1 -0
- package/es-custom/react/feedback.d.ts +6 -0
- package/es-custom/react/feedback.js +32 -0
- package/es-custom/react/feedback.js.map +1 -0
- package/es-custom/react/icon-button.d.ts +4 -0
- package/es-custom/react/icon-button.js +28 -0
- package/es-custom/react/icon-button.js.map +1 -0
- package/es-custom/react/icon.d.ts +4 -0
- package/es-custom/react/icon.js +28 -0
- package/es-custom/react/icon.js.map +1 -0
- package/es-custom/react/inline-notification.d.ts +4 -0
- package/es-custom/react/inline-notification.js +28 -0
- package/es-custom/react/inline-notification.js.map +1 -0
- package/es-custom/react/markdown.d.ts +4 -0
- package/es-custom/react/markdown.js +28 -0
- package/es-custom/react/markdown.js.map +1 -0
- package/es-custom/react/overflow-menu.d.ts +9 -0
- package/es-custom/react/overflow-menu.js +40 -0
- package/es-custom/react/overflow-menu.js.map +1 -0
- package/es-custom/react/processing.d.ts +4 -0
- package/es-custom/react/processing.js +28 -0
- package/es-custom/react/processing.js.map +1 -0
- package/es-custom/react/reasoning-step.d.ts +4 -0
- package/es-custom/react/reasoning-step.js +32 -0
- package/es-custom/react/reasoning-step.js.map +1 -0
- package/es-custom/react/reasoning-steps-toggle.d.ts +6 -0
- package/es-custom/react/reasoning-steps-toggle.js +31 -0
- package/es-custom/react/reasoning-steps-toggle.js.map +1 -0
- package/es-custom/react/reasoning-steps.d.ts +4 -0
- package/es-custom/react/reasoning-steps.js +28 -0
- package/es-custom/react/reasoning-steps.js.map +1 -0
- package/es-custom/react/tag.d.ts +4 -0
- package/es-custom/react/tag.js +28 -0
- package/es-custom/react/tag.js.map +1 -0
- package/es-custom/react/tile.d.ts +7 -0
- package/es-custom/react/tile.js +34 -0
- package/es-custom/react/tile.js.map +1 -0
- package/es-custom/react/tool-call-data.d.ts +4 -0
- package/es-custom/react/tool-call-data.js +28 -0
- package/es-custom/react/tool-call-data.js.map +1 -0
- package/es-custom/react/toolbar.d.ts +4 -0
- package/es-custom/react/toolbar.js +28 -0
- package/es-custom/react/toolbar.js.map +1 -0
- package/es-custom/react/utils/withWebComponentBridge.d.ts +15 -0
- package/es-custom/react/utils/withWebComponentBridge.js +95 -0
- package/es-custom/react/utils/withWebComponentBridge.js.map +1 -0
- package/es-custom/react/workspace-shell.d.ts +11 -0
- package/es-custom/react/workspace-shell.js +49 -0
- package/es-custom/react/workspace-shell.js.map +1 -0
- package/es-custom/testing/load-all-lazy-deps.d.ts +10 -0
- package/es-custom/testing/load-all-lazy-deps.js +30 -0
- package/es-custom/testing/load-all-lazy-deps.js.map +1 -0
- package/package.json +8 -6
- package/dist/16-C9Ph5740.js +0 -91
- package/dist/16-Dw0Ci4Fd.js +0 -91
- package/dist/16-FH37w-8T.js +0 -91
- package/dist/apl-ugs9-gp6.js +0 -91
- package/dist/asciiarmor-BsIYfA6P.js +0 -91
- package/dist/asn1-HkF5z2_O.js +0 -91
- package/dist/asterisk-CAIjKZq6.js +0 -91
- package/dist/button-Bc3tNCYN.js +0 -157
- package/dist/button-skeleton-DH50p4bH.js +0 -131
- package/dist/carbon-element-C38isbCs.js +0 -91
- package/dist/card.min.js +0 -193
- package/dist/chain-of-thought.min.js +0 -294
- package/dist/chat-button.min.js +0 -107
- package/dist/checkbox-skeleton-CS3inOnf.js +0 -166
- package/dist/class-map-BE4cOc2X.js +0 -128
- package/dist/clike-BIFB3b_k.js +0 -91
- package/dist/clojure-CXNiCqqB.js +0 -91
- package/dist/cmake-CR9NkLsk.js +0 -91
- package/dist/cobol-Ck90O_9v.js +0 -91
- package/dist/code-snippet.min.js +0 -91
- package/dist/codemirror-runtime-D8qZsrKE.js +0 -173
- package/dist/coffeescript-C0nvD2I-.js +0 -91
- package/dist/collection-helpers-BqatNkHh.js +0 -91
- package/dist/commonlisp-BROP4IME.js +0 -91
- package/dist/crystal-D6K96_U-.js +0 -91
- package/dist/css-CdH_tvvW.js +0 -91
- package/dist/cypher-CtHiEXsa.js +0 -91
- package/dist/d-Dcs18F9P.js +0 -91
- package/dist/diff-Bp64yuxL.js +0 -91
- package/dist/dockerfile-1DOwDLks.js +0 -91
- package/dist/dtd-DBKuh-AW.js +0 -91
- package/dist/dylan-ZUYgifRI.js +0 -91
- package/dist/ebnf-CEelJcGq.js +0 -91
- package/dist/ecl-CphVX9Cq.js +0 -91
- package/dist/eiffel-BQPneqZH.js +0 -91
- package/dist/elm-DSPAgqOt.js +0 -91
- package/dist/erlang-D_rMo9WA.js +0 -91
- package/dist/factor-CMTQjKbR.js +0 -91
- package/dist/fcl-BX3Rw6-t.js +0 -91
- package/dist/feedback.min.js +0 -281
- package/dist/forth-BGhjMNd3.js +0 -91
- package/dist/fortran-AEBjaYMh.js +0 -91
- package/dist/gas-DZXAjJGb.js +0 -91
- package/dist/gherkin-DxJx7fVg.js +0 -91
- package/dist/groovy-dfLbXlDy.js +0 -91
- package/dist/haskell-DyZ9y283.js +0 -91
- package/dist/haxe-D47ScCJn.js +0 -91
- package/dist/http-CQ5YdFwi.js +0 -91
- package/dist/icon-button-jLtiwRb4.js +0 -143
- package/dist/icon-loader-BKTEuybf.js +0 -101
- package/dist/idl-DMLd56tu.js +0 -91
- package/dist/if-defined-Dk7gHH6I.js +0 -96
- package/dist/index--CctdwCC.js +0 -91
- package/dist/index--ktPsmev.js +0 -168
- package/dist/index-BHiWR-3B.js +0 -91
- package/dist/index-BI8bnAEd.js +0 -91
- package/dist/index-BbGF94cg.js +0 -91
- package/dist/index-BnQBLEPx.js +0 -91
- package/dist/index-BsUuLdXD.js +0 -91
- package/dist/index-C2xfmTPp.js +0 -91
- package/dist/index-C3BN0MYy.js +0 -91
- package/dist/index-CD4di8Cf.js +0 -91
- package/dist/index-CVyUt3LQ.js +0 -91
- package/dist/index-Cg7m4sg1.js +0 -91
- package/dist/index-ClimwzxW.js +0 -91
- package/dist/index-CrevYuI-.js +0 -91
- package/dist/index-D5kcnwm2.js +0 -91
- package/dist/index-DCbIO0Hl.js +0 -91
- package/dist/index-Db-BDibx.js +0 -91
- package/dist/index-DmpHBiKi.js +0 -91
- package/dist/index-DzPjFlOn.js +0 -91
- package/dist/index-MgVf_8OP.js +0 -91
- package/dist/index-WHfhssUV.js +0 -91
- package/dist/index-rdaURAlB.js +0 -91
- package/dist/index-tFrMu4B_.js +0 -278
- package/dist/index-yLnmvqXN.js +0 -91
- package/dist/javascript-CB_5CYW7.js +0 -91
- package/dist/julia-DmOIk9mc.js +0 -91
- package/dist/livescript-BkgLC0lL.js +0 -91
- package/dist/loading-icon-CmnM4I_H.js +0 -106
- package/dist/lua-CWM_r9JC.js +0 -91
- package/dist/markdown.min.js +0 -298
- package/dist/mathematica-BSatVfC1.js +0 -91
- package/dist/mbox-4am1R8hd.js +0 -91
- package/dist/mirc-pdtTGW9l.js +0 -91
- package/dist/mllike-C0YFsE1U.js +0 -91
- package/dist/modelica-DVTWSHR-.js +0 -91
- package/dist/mscgen-ByAgrjGx.js +0 -91
- package/dist/mumps-X97p0_h_.js +0 -91
- package/dist/nginx-CqUadVPT.js +0 -91
- package/dist/nsis-Urp7BrWk.js +0 -91
- package/dist/ntriples-CToxeTsT.js +0 -91
- package/dist/octave-Dc4mpp8A.js +0 -91
- package/dist/oz-DX2Pk_mI.js +0 -91
- package/dist/pascal-B9GL_nqz.js +0 -91
- package/dist/perl-BvZFpXKD.js +0 -91
- package/dist/pig-BxFxDHBk.js +0 -91
- package/dist/powershell-CwCLRM7O.js +0 -91
- package/dist/processing.min.js +0 -105
- package/dist/properties-3nFD-Vnh.js +0 -91
- package/dist/protobuf-RqEyuWlw.js +0 -91
- package/dist/pug-1L6dEUb3.js +0 -91
- package/dist/puppet-C-gxR1ON.js +0 -91
- package/dist/python-BSbm1-vO.js +0 -91
- package/dist/q-4yAbTbi2.js +0 -91
- package/dist/r-BxfoMXlJ.js +0 -91
- package/dist/reasoning-steps.min.js +0 -202
- package/dist/rpm-DOp6MTEb.js +0 -91
- package/dist/ruby-DD6QCAKT.js +0 -91
- package/dist/sas-Cb-4sFOe.js +0 -91
- package/dist/scheme-CZsCl8E_.js +0 -91
- package/dist/settings-e2aItLYn.js +0 -99
- package/dist/shell-Bba6ETw_.js +0 -91
- package/dist/sieve-DZz1QovM.js +0 -91
- package/dist/simple-mode-DAyX7kcU.js +0 -91
- package/dist/smalltalk-BVigbKw-.js +0 -91
- package/dist/solr-BRh8QRgo.js +0 -91
- package/dist/sparql-DPq9GGqu.js +0 -91
- package/dist/spreadsheet-DWXWohNi.js +0 -91
- package/dist/sql-HgNux1Fi.js +0 -91
- package/dist/state-Bv4FM_9B.js +0 -96
- package/dist/stex-DB306cTl.js +0 -91
- package/dist/stylus-BVbE3BhF.js +0 -91
- package/dist/swift-k2z0otOi.js +0 -91
- package/dist/sync-D3qEZKNY.js +0 -91
- package/dist/table-runtime-Q-ak_IZE.js +0 -510
- package/dist/table.min.js +0 -91
- package/dist/tcl-BJwoeXra.js +0 -91
- package/dist/text-input-BlCqTf_p.js +0 -158
- package/dist/textile-9DAvWy-Y.js +0 -91
- package/dist/throttle-Bst9TagJ.js +0 -91
- package/dist/tiddlywiki-CDJdAycW.js +0 -91
- package/dist/tiki-Dlg5DFIR.js +0 -91
- package/dist/toml-DGqt7oU6.js +0 -91
- package/dist/toolbar.min.js +0 -178
- package/dist/troff-xJv1Y_X_.js +0 -91
- package/dist/ttcn-cfg-CrKiCUlI.js +0 -91
- package/dist/ttcn-dBogkyiy.js +0 -91
- package/dist/turtle-qtDt5E0f.js +0 -91
- package/dist/vb-h5NatM2n.js +0 -91
- package/dist/vbscript-BnXXn72l.js +0 -91
- package/dist/velocity-C_ZqzMiT.js +0 -91
- package/dist/verilog-s8oM517K.js +0 -91
- package/dist/vhdl-BgZd0MBH.js +0 -91
- package/dist/webidl-CDRn4bGa.js +0 -91
- package/dist/workspace-shell.min.js +0 -157
- package/dist/xquery-DTfjYCD7.js +0 -91
- package/dist/yacas-DxV9-gAO.js +0 -91
- package/dist/z80-PFwavMao.js +0 -91
- package/es/node_modules/@codemirror/autocomplete/dist/index.js +0 -258
- package/es/node_modules/@codemirror/autocomplete/dist/index.js.map +0 -1
- package/es/node_modules/@codemirror/commands/dist/index.js +0 -1140
- package/es/node_modules/@codemirror/commands/dist/index.js.map +0 -1
- package/es/node_modules/@codemirror/lint/dist/index.js +0 -636
- package/es/node_modules/@codemirror/lint/dist/index.js.map +0 -1
- package/es/node_modules/@lezer/common/dist/index.js +0 -253
- package/es/node_modules/@lezer/common/dist/index.js.map +0 -1
- package/es/node_modules/crelt/index.js +0 -37
- package/es/node_modules/crelt/index.js.map +0 -1
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { Compartment } from "@codemirror/state";
|
|
2
|
+
import { EditorView } from "@codemirror/view";
|
|
3
|
+
import { LanguageSupport } from "@codemirror/language";
|
|
4
|
+
import { type BaseCodeMirrorSetupOptions } from "./base-setup.js";
|
|
5
|
+
interface EditorDocChangePayload {
|
|
6
|
+
content: string;
|
|
7
|
+
lineCount: number;
|
|
8
|
+
}
|
|
9
|
+
interface EditorCreationOptions {
|
|
10
|
+
container: HTMLElement;
|
|
11
|
+
doc: string;
|
|
12
|
+
languageSupport: LanguageSupport | null;
|
|
13
|
+
languageCompartment: Compartment;
|
|
14
|
+
readOnlyCompartment: Compartment;
|
|
15
|
+
wrapCompartment: Compartment;
|
|
16
|
+
editable: boolean;
|
|
17
|
+
disabled: boolean;
|
|
18
|
+
wrapText: boolean;
|
|
19
|
+
onDocChanged?(payload: EditorDocChangePayload): void;
|
|
20
|
+
setupOptions?: BaseCodeMirrorSetupOptions;
|
|
21
|
+
}
|
|
22
|
+
export declare function createEditorView({ container, doc, languageSupport, languageCompartment, readOnlyCompartment, wrapCompartment, editable, disabled, onDocChanged, setupOptions, }: EditorCreationOptions): EditorView;
|
|
23
|
+
export declare function applyLanguageSupport(view: EditorView | undefined, languageCompartment: Compartment, support: LanguageSupport | null): void;
|
|
24
|
+
export declare function updateReadOnlyConfiguration(view: EditorView | undefined, readOnlyCompartment: Compartment, { editable, disabled }: {
|
|
25
|
+
editable: boolean;
|
|
26
|
+
disabled: boolean;
|
|
27
|
+
}): void;
|
|
28
|
+
export {};
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright IBM Corp. 2025
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
import { EditorState } from '@codemirror/state';
|
|
9
|
+
import { EditorView } from '@codemirror/view';
|
|
10
|
+
import { createCarbonTheme } from './theme.js';
|
|
11
|
+
import { baseCodeMirrorSetup } from './base-setup.js';
|
|
12
|
+
|
|
13
|
+
/*
|
|
14
|
+
* Copyright IBM Corp. 2025
|
|
15
|
+
*
|
|
16
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
|
17
|
+
* LICENSE file in the root directory of this source tree.
|
|
18
|
+
*
|
|
19
|
+
* @license
|
|
20
|
+
*/
|
|
21
|
+
const emptyLanguageExtensions = [];
|
|
22
|
+
function createEditorView({ container, doc, languageSupport, languageCompartment, readOnlyCompartment, wrapCompartment, editable, disabled, onDocChanged, setupOptions, }) {
|
|
23
|
+
const languageExtensions = languageSupport
|
|
24
|
+
? [languageSupport]
|
|
25
|
+
: emptyLanguageExtensions;
|
|
26
|
+
const readOnlyExtensions = [
|
|
27
|
+
EditorState.readOnly.of(!editable || disabled),
|
|
28
|
+
EditorView.editable.of(editable && !disabled),
|
|
29
|
+
];
|
|
30
|
+
const wrapTheme = createCarbonTheme();
|
|
31
|
+
const state = EditorState.create({
|
|
32
|
+
doc,
|
|
33
|
+
extensions: [
|
|
34
|
+
baseCodeMirrorSetup(setupOptions),
|
|
35
|
+
languageCompartment.of(languageExtensions),
|
|
36
|
+
readOnlyCompartment.of(readOnlyExtensions),
|
|
37
|
+
wrapCompartment.of(wrapTheme),
|
|
38
|
+
EditorView.updateListener.of((update) => {
|
|
39
|
+
if (update.docChanged && onDocChanged) {
|
|
40
|
+
onDocChanged({
|
|
41
|
+
content: update.state.doc.toString(),
|
|
42
|
+
lineCount: update.state.doc.lines,
|
|
43
|
+
});
|
|
44
|
+
}
|
|
45
|
+
}),
|
|
46
|
+
],
|
|
47
|
+
});
|
|
48
|
+
return new EditorView({
|
|
49
|
+
state,
|
|
50
|
+
parent: container,
|
|
51
|
+
});
|
|
52
|
+
}
|
|
53
|
+
function applyLanguageSupport(view, languageCompartment, support) {
|
|
54
|
+
if (!view) {
|
|
55
|
+
return;
|
|
56
|
+
}
|
|
57
|
+
const extensions = support ? [support] : emptyLanguageExtensions;
|
|
58
|
+
view.dispatch({
|
|
59
|
+
effects: languageCompartment.reconfigure(extensions),
|
|
60
|
+
});
|
|
61
|
+
}
|
|
62
|
+
function updateReadOnlyConfiguration(view, readOnlyCompartment, { editable, disabled }) {
|
|
63
|
+
if (!view) {
|
|
64
|
+
return;
|
|
65
|
+
}
|
|
66
|
+
view.dispatch({
|
|
67
|
+
effects: readOnlyCompartment.reconfigure([
|
|
68
|
+
EditorState.readOnly.of(!editable || disabled),
|
|
69
|
+
EditorView.editable.of(editable && !disabled),
|
|
70
|
+
]),
|
|
71
|
+
});
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
export { applyLanguageSupport, createEditorView, updateReadOnlyConfiguration };
|
|
75
|
+
//# sourceMappingURL=editor-manager.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"editor-manager.js","sources":["../../../../../src/components/code-snippet/src/codemirror/editor-manager.ts"],"sourcesContent":[null],"names":[],"mappings":";;;;;;;;;;;;AAAA;;;;;;;AAOG;AA8BH,MAAM,uBAAuB,GAAY,EAAE;AAErC,SAAU,gBAAgB,CAAC,EAC/B,SAAS,EACT,GAAG,EACH,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,eAAe,EACf,QAAQ,EACR,QAAQ,EACR,YAAY,EACZ,YAAY,GACU,EAAA;IACtB,MAAM,kBAAkB,GAAG;UACvB,CAAC,eAAe;UAChB,uBAAuB;AAE3B,IAAA,MAAM,kBAAkB,GAAG;QACzB,WAAW,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,QAAQ,IAAI,QAAQ,CAAC;QAC9C,UAAU,CAAC,QAAQ,CAAC,EAAE,CAAC,QAAQ,IAAI,CAAC,QAAQ,CAAC;KAC9C;AAED,IAAA,MAAM,SAAS,GAAG,iBAAiB,EAAE;AAErC,IAAA,MAAM,KAAK,GAAG,WAAW,CAAC,MAAM,CAAC;QAC/B,GAAG;AACH,QAAA,UAAU,EAAE;YACV,mBAAmB,CAAC,YAAY,CAAC;AACjC,YAAA,mBAAmB,CAAC,EAAE,CAAC,kBAAkB,CAAC;AAC1C,YAAA,mBAAmB,CAAC,EAAE,CAAC,kBAAkB,CAAC;AAC1C,YAAA,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+
import { Compartment } from "@codemirror/state";
|
|
2
|
+
import { LanguageSupport } from "@codemirror/language";
|
|
3
|
+
import { EditorView } from "@codemirror/view";
|
|
4
|
+
interface LanguageStateUpdate {
|
|
5
|
+
detectedLanguage?: string | null;
|
|
6
|
+
lockLabel?: boolean;
|
|
7
|
+
}
|
|
8
|
+
interface LanguageControllerConfig {
|
|
9
|
+
getLanguageAttribute(): string;
|
|
10
|
+
getContent(): string;
|
|
11
|
+
isHighlightEnabled(): boolean;
|
|
12
|
+
getEditorView(): EditorView | undefined;
|
|
13
|
+
getLanguageCompartment(): Compartment;
|
|
14
|
+
isLanguageLabelLocked(): boolean;
|
|
15
|
+
getDefaultLanguage(): string;
|
|
16
|
+
updateState(update: LanguageStateUpdate): void;
|
|
17
|
+
}
|
|
18
|
+
export declare class LanguageController {
|
|
19
|
+
private readonly config;
|
|
20
|
+
private pendingLanguageLoad;
|
|
21
|
+
private languageDetectionTimeout;
|
|
22
|
+
private highlightingDetectionTimeout;
|
|
23
|
+
private editableLanguageDetectionTimeout;
|
|
24
|
+
private canDetectForHighlighting;
|
|
25
|
+
constructor(config: LanguageControllerConfig);
|
|
26
|
+
resolveLanguageSupport(): Promise<LanguageSupport | null>;
|
|
27
|
+
handleStreamingLanguageDetection(): Promise<void>;
|
|
28
|
+
detectLanguageForEditable(content: string): void;
|
|
29
|
+
reset(): void;
|
|
30
|
+
dispose(): void;
|
|
31
|
+
private lockDetectedLanguageFromContent;
|
|
32
|
+
private scheduleHighlightingDetectionReset;
|
|
33
|
+
private clearLanguageDetectionTimeout;
|
|
34
|
+
private clearHighlightingDetectionTimeout;
|
|
35
|
+
private clearEditableDetectionTimeout;
|
|
36
|
+
private disposeTimers;
|
|
37
|
+
}
|
|
38
|
+
export type { LanguageStateUpdate };
|
|
@@ -0,0 +1,220 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright IBM Corp. 2025
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
import { LanguageDescription } from '@codemirror/language';
|
|
9
|
+
import { languages } from './language-data.js';
|
|
10
|
+
import { mapLanguageName, detectLanguage } from './language-utils.js';
|
|
11
|
+
|
|
12
|
+
/*
|
|
13
|
+
* Copyright IBM Corp. 2025
|
|
14
|
+
*
|
|
15
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
|
16
|
+
* LICENSE file in the root directory of this source tree.
|
|
17
|
+
*
|
|
18
|
+
* @license
|
|
19
|
+
*/
|
|
20
|
+
function loadLanguageSupport(langDesc) {
|
|
21
|
+
return langDesc.load();
|
|
22
|
+
}
|
|
23
|
+
class LanguageController {
|
|
24
|
+
constructor(config) {
|
|
25
|
+
this.config = config;
|
|
26
|
+
this.pendingLanguageLoad = null;
|
|
27
|
+
this.languageDetectionTimeout = null;
|
|
28
|
+
this.highlightingDetectionTimeout = null;
|
|
29
|
+
this.editableLanguageDetectionTimeout = null;
|
|
30
|
+
this.canDetectForHighlighting = true;
|
|
31
|
+
}
|
|
32
|
+
async resolveLanguageSupport() {
|
|
33
|
+
const languageAttr = this.config.getLanguageAttribute();
|
|
34
|
+
const content = this.config.getContent();
|
|
35
|
+
let languageToUse = languageAttr
|
|
36
|
+
? (mapLanguageName(languageAttr) ?? languageAttr)
|
|
37
|
+
: "";
|
|
38
|
+
if (!languageToUse && content) {
|
|
39
|
+
const trimmed = content.trim();
|
|
40
|
+
if (trimmed) {
|
|
41
|
+
const detected = detectLanguage(trimmed);
|
|
42
|
+
languageToUse = detected ?? "";
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
// Use default language for empty editable content
|
|
46
|
+
if (!languageToUse && this.config.getDefaultLanguage()) {
|
|
47
|
+
const trimmed = content.trim();
|
|
48
|
+
if (!trimmed) {
|
|
49
|
+
languageToUse = this.config.getDefaultLanguage();
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
if (!languageToUse) {
|
|
53
|
+
this.config.updateState({ detectedLanguage: null, lockLabel: false });
|
|
54
|
+
return null;
|
|
55
|
+
}
|
|
56
|
+
const langDesc = LanguageDescription.matchLanguageName(languages, languageToUse, true);
|
|
57
|
+
const detectedLanguage = langDesc ? languageToUse : null;
|
|
58
|
+
this.config.updateState({
|
|
59
|
+
detectedLanguage,
|
|
60
|
+
lockLabel: Boolean(languageAttr && detectedLanguage),
|
|
61
|
+
});
|
|
62
|
+
if (!this.config.isHighlightEnabled() || !langDesc) {
|
|
63
|
+
return null;
|
|
64
|
+
}
|
|
65
|
+
try {
|
|
66
|
+
return await loadLanguageSupport(langDesc);
|
|
67
|
+
}
|
|
68
|
+
catch (error) {
|
|
69
|
+
console.warn(`Failed to load language support for "${languageToUse}"`);
|
|
70
|
+
return null;
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
async handleStreamingLanguageDetection() {
|
|
74
|
+
if (this.config.getLanguageAttribute()) {
|
|
75
|
+
return;
|
|
76
|
+
}
|
|
77
|
+
const trimmed = this.config.getContent().trim();
|
|
78
|
+
if (!trimmed) {
|
|
79
|
+
return;
|
|
80
|
+
}
|
|
81
|
+
if (!this.config.isLanguageLabelLocked() &&
|
|
82
|
+
this.config.isHighlightEnabled() &&
|
|
83
|
+
this.canDetectForHighlighting) {
|
|
84
|
+
const detected = detectLanguage(trimmed);
|
|
85
|
+
if (detected) {
|
|
86
|
+
const langDesc = LanguageDescription.matchLanguageName(languages, detected, true);
|
|
87
|
+
if (langDesc && !this.pendingLanguageLoad) {
|
|
88
|
+
this.pendingLanguageLoad = loadLanguageSupport(langDesc)
|
|
89
|
+
.then((support) => {
|
|
90
|
+
const view = this.config.getEditorView();
|
|
91
|
+
if (!view) {
|
|
92
|
+
return;
|
|
93
|
+
}
|
|
94
|
+
view.dispatch({
|
|
95
|
+
effects: this.config
|
|
96
|
+
.getLanguageCompartment()
|
|
97
|
+
.reconfigure([support]),
|
|
98
|
+
});
|
|
99
|
+
})
|
|
100
|
+
.catch((_error) => {
|
|
101
|
+
console.warn(`Failed to load language support for "${detected}"`);
|
|
102
|
+
})
|
|
103
|
+
.finally(() => {
|
|
104
|
+
this.pendingLanguageLoad = null;
|
|
105
|
+
});
|
|
106
|
+
this.canDetectForHighlighting = false;
|
|
107
|
+
this.scheduleHighlightingDetectionReset();
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
this.clearLanguageDetectionTimeout();
|
|
112
|
+
if (!this.config.isLanguageLabelLocked()) {
|
|
113
|
+
this.languageDetectionTimeout = window.setTimeout(() => {
|
|
114
|
+
this.languageDetectionTimeout = null;
|
|
115
|
+
this.lockDetectedLanguageFromContent();
|
|
116
|
+
}, 200);
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
detectLanguageForEditable(content) {
|
|
120
|
+
if (this.config.getLanguageAttribute()) {
|
|
121
|
+
return;
|
|
122
|
+
}
|
|
123
|
+
const trimmed = content.trim();
|
|
124
|
+
if (!trimmed) {
|
|
125
|
+
this.config.updateState({ detectedLanguage: null, lockLabel: false });
|
|
126
|
+
return;
|
|
127
|
+
}
|
|
128
|
+
this.clearEditableDetectionTimeout();
|
|
129
|
+
this.editableLanguageDetectionTimeout = window.setTimeout(() => {
|
|
130
|
+
this.editableLanguageDetectionTimeout = null;
|
|
131
|
+
const detected = detectLanguage(trimmed);
|
|
132
|
+
if (!detected) {
|
|
133
|
+
return;
|
|
134
|
+
}
|
|
135
|
+
const langDesc = LanguageDescription.matchLanguageName(languages, detected, true);
|
|
136
|
+
if (!langDesc) {
|
|
137
|
+
return;
|
|
138
|
+
}
|
|
139
|
+
this.config.updateState({ detectedLanguage: detected, lockLabel: true });
|
|
140
|
+
if (this.config.isHighlightEnabled() && !this.pendingLanguageLoad) {
|
|
141
|
+
this.pendingLanguageLoad = loadLanguageSupport(langDesc)
|
|
142
|
+
.then((support) => {
|
|
143
|
+
const view = this.config.getEditorView();
|
|
144
|
+
if (!view) {
|
|
145
|
+
return;
|
|
146
|
+
}
|
|
147
|
+
view.dispatch({
|
|
148
|
+
effects: this.config
|
|
149
|
+
.getLanguageCompartment()
|
|
150
|
+
.reconfigure([support]),
|
|
151
|
+
});
|
|
152
|
+
})
|
|
153
|
+
.catch((_error) => {
|
|
154
|
+
console.warn(`Failed to load language support for "${detected}"`);
|
|
155
|
+
})
|
|
156
|
+
.finally(() => {
|
|
157
|
+
this.pendingLanguageLoad = null;
|
|
158
|
+
});
|
|
159
|
+
}
|
|
160
|
+
}, 200);
|
|
161
|
+
}
|
|
162
|
+
reset() {
|
|
163
|
+
this.disposeTimers();
|
|
164
|
+
this.pendingLanguageLoad = null;
|
|
165
|
+
this.canDetectForHighlighting = true;
|
|
166
|
+
this.config.updateState({ detectedLanguage: null, lockLabel: false });
|
|
167
|
+
}
|
|
168
|
+
dispose() {
|
|
169
|
+
this.disposeTimers();
|
|
170
|
+
this.pendingLanguageLoad = null;
|
|
171
|
+
}
|
|
172
|
+
lockDetectedLanguageFromContent() {
|
|
173
|
+
if (this.config.getLanguageAttribute() ||
|
|
174
|
+
this.config.isLanguageLabelLocked()) {
|
|
175
|
+
return;
|
|
176
|
+
}
|
|
177
|
+
const trimmed = this.config.getContent().trim();
|
|
178
|
+
if (!trimmed) {
|
|
179
|
+
return;
|
|
180
|
+
}
|
|
181
|
+
const detected = detectLanguage(trimmed);
|
|
182
|
+
if (!detected) {
|
|
183
|
+
return;
|
|
184
|
+
}
|
|
185
|
+
this.config.updateState({ detectedLanguage: detected, lockLabel: true });
|
|
186
|
+
}
|
|
187
|
+
scheduleHighlightingDetectionReset() {
|
|
188
|
+
this.clearHighlightingDetectionTimeout();
|
|
189
|
+
this.highlightingDetectionTimeout = window.setTimeout(() => {
|
|
190
|
+
this.canDetectForHighlighting = true;
|
|
191
|
+
this.highlightingDetectionTimeout = null;
|
|
192
|
+
}, 200);
|
|
193
|
+
}
|
|
194
|
+
clearLanguageDetectionTimeout() {
|
|
195
|
+
if (this.languageDetectionTimeout !== null) {
|
|
196
|
+
window.clearTimeout(this.languageDetectionTimeout);
|
|
197
|
+
this.languageDetectionTimeout = null;
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
clearHighlightingDetectionTimeout() {
|
|
201
|
+
if (this.highlightingDetectionTimeout !== null) {
|
|
202
|
+
window.clearTimeout(this.highlightingDetectionTimeout);
|
|
203
|
+
this.highlightingDetectionTimeout = null;
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
clearEditableDetectionTimeout() {
|
|
207
|
+
if (this.editableLanguageDetectionTimeout !== null) {
|
|
208
|
+
window.clearTimeout(this.editableLanguageDetectionTimeout);
|
|
209
|
+
this.editableLanguageDetectionTimeout = null;
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
disposeTimers() {
|
|
213
|
+
this.clearLanguageDetectionTimeout();
|
|
214
|
+
this.clearHighlightingDetectionTimeout();
|
|
215
|
+
this.clearEditableDetectionTimeout();
|
|
216
|
+
}
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
export { LanguageController };
|
|
220
|
+
//# sourceMappingURL=language-controller.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"language-controller.js","sources":["../../../../../src/components/code-snippet/src/codemirror/language-controller.ts"],"sourcesContent":[null],"names":[],"mappings":";;;;;;;;;;;AAAA;;;;;;;AAOG;AAwBH,SAAS,mBAAmB,CAAC,QAA6B,EAAA;AACxD,IAAA,OAAO,QAAQ,CAAC,IAAI,EAAE;AACxB;MAEa,kBAAkB,CAAA;AAO7B,IAAA,WAAA,CAA6B,MAAgC,EAAA;QAAhC,IAAA,CAAA,MAAM,GAAN,MAAM;QAN3B,IAAA,CAAA,mBAAmB,GAAyB,IAAI;QAChD,IAAA,CAAA,wBAAwB,GAAkB,IAAI;QAC9C,IAAA,CAAA,4BAA4B,GAAkB,IAAI;QAClD,IAAA,CAAA,gCAAgC,GAAkB,IAAI;QACtD,IAAA,CAAA,wBAAwB,GAAG,IAAI;IAEyB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