@carbon/ai-chat-components 1.7.0 → 1.9.0-alpha.0
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 +16062 -10795
- package/es/components/audio-player/src/audio-player.js +9 -10
- package/es/components/audio-player/src/audio-player.js.map +1 -1
- package/es/components/audio-player/src/providers/base-provider.js +0 -1
- package/es/components/audio-player/src/providers/base-provider.js.map +1 -1
- package/es/components/audio-player/src/providers/native-audio-provider.js +0 -1
- package/es/components/audio-player/src/providers/native-audio-provider.js.map +1 -1
- package/es/components/audio-player/src/providers/soundcloud-provider.js +0 -1
- package/es/components/audio-player/src/providers/soundcloud-provider.js.map +1 -1
- package/es/components/audio-player/src/transcript.js +15 -15
- package/es/components/audio-player/src/transcript.js.map +1 -1
- package/es/components/audio-player/src/utils/url-detector.js +0 -1
- package/es/components/audio-player/src/utils/url-detector.js.map +1 -1
- package/es/components/autocomplete/index.d.ts +15 -0
- package/es/components/autocomplete/index.js +11 -0
- package/es/components/autocomplete/index.js.map +1 -0
- package/es/components/autocomplete/src/autocomplete-item-group.d.ts +44 -0
- package/es/components/autocomplete/src/autocomplete-item-group.js +139 -0
- package/es/components/autocomplete/src/autocomplete-item-group.js.map +1 -0
- package/es/components/autocomplete/src/autocomplete-item-group.scss.js +13 -0
- package/es/components/autocomplete/src/autocomplete-item-group.scss.js.map +1 -0
- package/es/components/autocomplete/src/autocomplete-item.d.ts +54 -0
- package/es/components/autocomplete/src/autocomplete-item.js +197 -0
- package/es/components/autocomplete/src/autocomplete-item.js.map +1 -0
- package/es/components/autocomplete/src/autocomplete-item.scss.js +13 -0
- package/es/components/autocomplete/src/autocomplete-item.scss.js.map +1 -0
- package/es/components/autocomplete/src/autocomplete.d.ts +97 -0
- package/es/components/autocomplete/src/autocomplete.js +321 -0
- package/es/components/autocomplete/src/autocomplete.js.map +1 -0
- package/es/components/autocomplete/src/autocomplete.scss.js +13 -0
- package/es/components/autocomplete/src/autocomplete.scss.js.map +1 -0
- package/es/components/card/src/card-footer.d.ts +1 -1
- package/es/components/card/src/card-footer.js +1 -1
- package/es/components/card/src/card-footer.js.map +1 -1
- package/es/components/card/src/card-footer.scss.js +1 -1
- package/es/components/card/src/card-steps.d.ts +1 -1
- package/es/components/card/src/card-steps.js +28 -28
- package/es/components/card/src/card-steps.js.map +1 -1
- package/es/components/card/src/card-steps.scss.js +1 -1
- package/es/components/card/src/card.scss.js +1 -1
- package/es/components/carousel/src/carousel.js +0 -1
- package/es/components/carousel/src/carousel.js.map +1 -1
- package/es/components/chain-of-thought/src/chain-of-thought-step.js +1 -1
- package/es/components/chain-of-thought/src/chain-of-thought-step.js.map +1 -1
- package/es/components/chain-of-thought/src/tool-call-data.js +4 -4
- package/es/components/chain-of-thought/src/tool-call-data.js.map +1 -1
- package/es/components/chat-button/src/chat-button.d.ts +1 -1
- package/es/components/chat-button/src/chat-button.js +1 -1
- package/es/components/chat-button/src/chat-button.js.map +1 -1
- package/es/components/chat-button/src/chat-button.scss.js +1 -1
- package/es/components/chat-history/src/chat-history.scss.js +1 -1
- package/es/components/chat-history/src/history-content.js +2 -2
- package/es/components/chat-history/src/history-content.js.map +1 -1
- package/es/components/chat-history/src/history-header.js +8 -8
- package/es/components/chat-history/src/history-header.js.map +1 -1
- package/es/components/chat-history/src/history-panel-item-input.d.ts +19 -2
- package/es/components/chat-history/src/history-panel-item-input.js +69 -19
- package/es/components/chat-history/src/history-panel-item-input.js.map +1 -1
- package/es/components/chat-history/src/history-panel-item.d.ts +14 -0
- package/es/components/chat-history/src/history-panel-item.js +59 -27
- package/es/components/chat-history/src/history-panel-item.js.map +1 -1
- package/es/components/chat-history/src/history-toolbar.js +3 -3
- package/es/components/chat-history/src/history-toolbar.js.map +1 -1
- package/es/components/chat-shell/src/chat-header.js +15 -16
- package/es/components/chat-shell/src/chat-header.js.map +1 -1
- package/es/components/chat-shell/src/corner-manager.d.ts +1 -1
- package/es/components/chat-shell/src/corner-manager.js +1 -2
- package/es/components/chat-shell/src/corner-manager.js.map +1 -1
- package/es/components/chat-shell/src/initialization-manager.d.ts +1 -1
- package/es/components/chat-shell/src/initialization-manager.js +1 -2
- package/es/components/chat-shell/src/initialization-manager.js.map +1 -1
- package/es/components/chat-shell/src/resize-observer-manager.js +0 -1
- package/es/components/chat-shell/src/resize-observer-manager.js.map +1 -1
- package/es/components/chat-shell/src/shell.d.ts +1 -1
- package/es/components/chat-shell/src/shell.js +3 -3
- package/es/components/chat-shell/src/shell.js.map +1 -1
- package/es/components/chat-shell/src/slot-observer.d.ts +1 -1
- package/es/components/chat-shell/src/slot-observer.js +1 -2
- package/es/components/chat-shell/src/slot-observer.js.map +1 -1
- package/es/components/chat-shell/src/types.d.ts +1 -1
- package/es/components/chat-shell/src/workspace-manager-utils.d.ts +1 -1
- package/es/components/chat-shell/src/workspace-manager-utils.js +1 -2
- package/es/components/chat-shell/src/workspace-manager-utils.js.map +1 -1
- package/es/components/chat-shell/src/workspace-manager.d.ts +1 -1
- package/es/components/chat-shell/src/workspace-manager.js +1 -2
- package/es/components/chat-shell/src/workspace-manager.js.map +1 -1
- package/es/components/code-snippet/src/code-snippet.d.ts +23 -0
- package/es/components/code-snippet/src/code-snippet.js +111 -36
- package/es/components/code-snippet/src/code-snippet.js.map +1 -1
- package/es/components/code-snippet/src/code-snippet.scss.js +1 -1
- package/es/components/code-snippet/src/codemirror/diff-decorator.js +1 -1
- package/es/components/code-snippet/src/codemirror/diff-decorator.js.map +1 -1
- package/es/components/code-snippet/src/codemirror/theme.js +5 -0
- package/es/components/code-snippet/src/codemirror/theme.js.map +1 -1
- package/es/components/code-snippet/src/layout-utils.js +21 -8
- package/es/components/code-snippet/src/layout-utils.js.map +1 -1
- package/es/components/feedback/src/feedback-buttons.js +1 -1
- package/es/components/feedback/src/feedback-buttons.js.map +1 -1
- package/es/components/feedback/src/feedback.js +38 -38
- package/es/components/feedback/src/feedback.js.map +1 -1
- package/es/components/feedback/src/feedback.scss.js +1 -1
- package/es/components/file-uploads/index.d.ts +12 -0
- package/es/components/file-uploads/index.js +10 -0
- package/es/components/file-uploads/index.js.map +1 -0
- package/es/components/file-uploads/src/file-upload-item.d.ts +43 -0
- package/es/components/file-uploads/src/file-upload-item.js +267 -0
- package/es/components/file-uploads/src/file-upload-item.js.map +1 -0
- package/es/components/file-uploads/src/file-upload-item.scss.js +13 -0
- package/es/components/file-uploads/src/file-upload-item.scss.js.map +1 -0
- package/es/components/file-uploads/src/file-uploads.d.ts +87 -0
- package/es/components/file-uploads/src/file-uploads.js +213 -0
- package/es/components/file-uploads/src/file-uploads.js.map +1 -0
- package/es/components/file-uploads/src/file-uploads.scss.js +13 -0
- package/es/components/file-uploads/src/file-uploads.scss.js.map +1 -0
- package/es/components/markdown/index.d.ts +1 -0
- package/es/components/markdown/index.js +1 -0
- package/es/components/markdown/index.js.map +1 -1
- package/es/components/markdown/src/markdown-token-tree.d.ts +8 -0
- package/es/components/markdown/src/markdown-token-tree.js +12 -1
- package/es/components/markdown/src/markdown-token-tree.js.map +1 -1
- package/es/components/markdown/src/markdown.js +4 -0
- package/es/components/markdown/src/markdown.js.map +1 -1
- package/es/components/markdown/src/markdown.scss.js +1 -1
- package/es/components/markdown/src/utils/html-helpers.js.map +1 -1
- package/es/components/prompt-line/index.d.ts +26 -0
- package/es/components/prompt-line/index.js +32 -0
- package/es/components/prompt-line/index.js.map +1 -0
- package/es/components/prompt-line/src/autocomplete-controller.d.ts +178 -0
- package/es/components/prompt-line/src/autocomplete-controller.js +548 -0
- package/es/components/prompt-line/src/autocomplete-controller.js.map +1 -0
- package/es/components/prompt-line/src/error-message.d.ts +50 -0
- package/es/components/prompt-line/src/error-message.js +144 -0
- package/es/components/prompt-line/src/error-message.js.map +1 -0
- package/es/components/prompt-line/src/error-message.scss.js +13 -0
- package/es/components/prompt-line/src/error-message.scss.js.map +1 -0
- package/es/components/prompt-line/src/prompt-line-constants.d.ts +17 -0
- package/es/components/prompt-line/src/prompt-line-constants.js +27 -0
- package/es/components/prompt-line/src/prompt-line-constants.js.map +1 -0
- package/es/components/prompt-line/src/prompt-line-controller.d.ts +155 -0
- package/es/components/prompt-line/src/prompt-line-controller.js +394 -0
- package/es/components/prompt-line/src/prompt-line-controller.js.map +1 -0
- package/es/components/prompt-line/src/prompt-line-rich-loader.d.ts +34 -0
- package/es/components/prompt-line/src/prompt-line-rich-loader.js +51 -0
- package/es/components/prompt-line/src/prompt-line-rich-loader.js.map +1 -0
- package/es/components/prompt-line/src/prompt-line-rich-runtime.d.ts +14 -0
- package/es/components/prompt-line/src/prompt-line-rich-runtime.js +340 -0
- package/es/components/prompt-line/src/prompt-line-rich-runtime.js.map +1 -0
- package/es/components/prompt-line/src/prompt-line-shell.d.ts +72 -0
- package/es/components/prompt-line/src/prompt-line-shell.js +227 -0
- package/es/components/prompt-line/src/prompt-line-shell.js.map +1 -0
- package/es/components/prompt-line/src/prompt-line-shell.scss.js +13 -0
- package/es/components/prompt-line/src/prompt-line-shell.scss.js.map +1 -0
- package/es/components/prompt-line/src/prompt-line.d.ts +147 -0
- package/es/components/prompt-line/src/prompt-line.js +391 -0
- package/es/components/prompt-line/src/prompt-line.js.map +1 -0
- package/es/components/prompt-line/src/prompt-line.scss.js +13 -0
- package/es/components/prompt-line/src/prompt-line.scss.js.map +1 -0
- package/es/components/prompt-line/src/send-control.d.ts +46 -0
- package/es/components/prompt-line/src/send-control.js +138 -0
- package/es/components/prompt-line/src/send-control.js.map +1 -0
- package/es/components/prompt-line/src/send-control.scss.js +13 -0
- package/es/components/prompt-line/src/send-control.scss.js.map +1 -0
- package/es/components/prompt-line/src/stop-streaming-button.d.ts +42 -0
- package/es/components/prompt-line/src/stop-streaming-button.js +93 -0
- package/es/components/prompt-line/src/stop-streaming-button.js.map +1 -0
- package/es/components/prompt-line/src/stop-streaming-button.scss.js +13 -0
- package/es/components/prompt-line/src/stop-streaming-button.scss.js.map +1 -0
- package/es/components/prompt-line/src/tiptap/build-extensions.d.ts +30 -0
- package/es/components/prompt-line/src/tiptap/build-extensions.js +38 -0
- package/es/components/prompt-line/src/tiptap/build-extensions.js.map +1 -0
- package/es/components/prompt-line/src/tiptap/carbon-autocomplete.d.ts +21 -0
- package/es/components/prompt-line/src/tiptap/carbon-autocomplete.js +127 -0
- package/es/components/prompt-line/src/tiptap/carbon-autocomplete.js.map +1 -0
- package/es/components/prompt-line/src/tiptap/carbon-mention.d.ts +19 -0
- package/es/components/prompt-line/src/tiptap/carbon-mention.js +237 -0
- package/es/components/prompt-line/src/tiptap/carbon-mention.js.map +1 -0
- package/es/components/prompt-line/src/tiptap/carbon-starter-trigger.d.ts +22 -0
- package/es/components/prompt-line/src/tiptap/carbon-starter-trigger.js +64 -0
- package/es/components/prompt-line/src/tiptap/carbon-starter-trigger.js.map +1 -0
- package/es/components/prompt-line/src/tiptap/chat-enter.d.ts +17 -0
- package/es/components/prompt-line/src/tiptap/chat-enter.js +46 -0
- package/es/components/prompt-line/src/tiptap/chat-enter.js.map +1 -0
- package/es/components/prompt-line/src/tiptap/editor-styles.d.ts +18 -0
- package/es/components/prompt-line/src/tiptap/editor-styles.js +83 -0
- package/es/components/prompt-line/src/tiptap/editor-styles.js.map +1 -0
- package/es/components/prompt-line/src/tiptap/index.d.ts +42 -0
- package/es/components/prompt-line/src/tiptap/index.js +43 -0
- package/es/components/prompt-line/src/tiptap/index.js.map +1 -0
- package/es/components/prompt-line/src/tiptap/json-utils.d.ts +61 -0
- package/es/components/prompt-line/src/tiptap/json-utils.js +158 -0
- package/es/components/prompt-line/src/tiptap/json-utils.js.map +1 -0
- package/es/components/prompt-line/src/tiptap/keymap.d.ts +31 -0
- package/es/components/prompt-line/src/tiptap/keymap.js +59 -0
- package/es/components/prompt-line/src/tiptap/keymap.js.map +1 -0
- package/es/components/prompt-line/src/tiptap/origin-meta.d.ts +11 -0
- package/es/components/prompt-line/src/tiptap/origin-meta.js +33 -0
- package/es/components/prompt-line/src/tiptap/origin-meta.js.map +1 -0
- package/es/components/prompt-line/src/tiptap/plain-text-paste.d.ts +16 -0
- package/es/components/prompt-line/src/tiptap/plain-text-paste.js +85 -0
- package/es/components/prompt-line/src/tiptap/plain-text-paste.js.map +1 -0
- package/es/components/prompt-line/src/tiptap/render-in-light-dom.d.ts +87 -0
- package/es/components/prompt-line/src/tiptap/render-in-light-dom.js +41 -0
- package/es/components/prompt-line/src/tiptap/render-in-light-dom.js.map +1 -0
- package/es/components/prompt-line/src/tiptap/render-token-chip.d.ts +57 -0
- package/es/components/prompt-line/src/tiptap/render-token-chip.js +95 -0
- package/es/components/prompt-line/src/tiptap/render-token-chip.js.map +1 -0
- package/es/components/prompt-line/src/tiptap/token-node-view.d.ts +36 -0
- package/es/components/prompt-line/src/tiptap/token-node-view.js +41 -0
- package/es/components/prompt-line/src/tiptap/token-node-view.js.map +1 -0
- package/es/components/prompt-line/src/tiptap/trigger-utils.d.ts +30 -0
- package/es/components/prompt-line/src/tiptap/trigger-utils.js +44 -0
- package/es/components/prompt-line/src/tiptap/trigger-utils.js.map +1 -0
- package/es/components/prompt-line/src/tiptap/types.d.ts +161 -0
- package/es/components/prompt-line/src/tiptap/types.js +8 -0
- package/es/components/prompt-line/src/tiptap/types.js.map +1 -0
- package/es/components/prompt-line/src/tiptap/typing-indicator.d.ts +30 -0
- package/es/components/prompt-line/src/tiptap/typing-indicator.js +104 -0
- package/es/components/prompt-line/src/tiptap/typing-indicator.js.map +1 -0
- package/es/components/prompt-line/src/tiptap/value-sync.d.ts +25 -0
- package/es/components/prompt-line/src/tiptap/value-sync.js +65 -0
- package/es/components/prompt-line/src/tiptap/value-sync.js.map +1 -0
- package/es/components/prompt-line/src/types.d.ts +100 -0
- package/es/components/prompt-line/src/types.js +50 -0
- package/es/components/prompt-line/src/types.js.map +1 -0
- package/es/components/reasoning-steps/src/reasoning-step.d.ts +13 -0
- package/es/components/reasoning-steps/src/reasoning-step.js +38 -0
- package/es/components/reasoning-steps/src/reasoning-step.js.map +1 -1
- package/es/components/reasoning-steps/src/reasoning-steps.d.ts +23 -0
- package/es/components/reasoning-steps/src/reasoning-steps.js +56 -1
- package/es/components/reasoning-steps/src/reasoning-steps.js.map +1 -1
- package/es/components/shared/dynamic-css-var-sheet.js +4 -1
- package/es/components/shared/dynamic-css-var-sheet.js.map +1 -1
- package/es/components/shared/media-utils/script-loader.js +0 -1
- package/es/components/shared/media-utils/script-loader.js.map +1 -1
- package/es/components/table/src/table.scss.js +1 -1
- package/es/components/table/src/table.template.js +9 -9
- package/es/components/table/src/table.template.js.map +1 -1
- package/es/components/toolbar/src/toolbar.js +51 -53
- package/es/components/toolbar/src/toolbar.js.map +1 -1
- package/es/components/video-player/src/providers/base-provider.js +0 -1
- package/es/components/video-player/src/providers/base-provider.js.map +1 -1
- package/es/components/video-player/src/providers/kaltura-provider.js +0 -1
- package/es/components/video-player/src/providers/kaltura-provider.js.map +1 -1
- package/es/components/video-player/src/providers/native-video-provider.js +0 -1
- package/es/components/video-player/src/providers/native-video-provider.js.map +1 -1
- package/es/components/video-player/src/providers/vimeo-provider.js +0 -1
- package/es/components/video-player/src/providers/vimeo-provider.js.map +1 -1
- package/es/components/video-player/src/providers/youtube-provider.js +0 -1
- package/es/components/video-player/src/providers/youtube-provider.js.map +1 -1
- package/es/components/video-player/src/utils/url-detector.js +0 -1
- package/es/components/video-player/src/utils/url-detector.js.map +1 -1
- package/es/components/video-player/src/video-player.js +9 -10
- package/es/components/video-player/src/video-player.js.map +1 -1
- package/es/components/workspace-shell/src/header-collapsible-manager.js +0 -1
- package/es/components/workspace-shell/src/header-collapsible-manager.js.map +1 -1
- package/es/components/workspace-shell/src/workspace-shell-header.js +25 -25
- package/es/components/workspace-shell/src/workspace-shell-header.js.map +1 -1
- package/es/globals/utils/aria-announcer-manager.d.ts +62 -0
- package/es/globals/utils/aria-announcer-manager.js +125 -0
- package/es/globals/utils/aria-announcer-manager.js.map +1 -0
- package/es/globals/utils/browser-utils.d.ts +10 -0
- package/es/globals/utils/browser-utils.js +37 -0
- package/es/globals/utils/browser-utils.js.map +1 -0
- package/es/globals/utils/dom-utils.d.ts +6 -0
- package/es/globals/utils/dom-utils.js +39 -0
- package/es/globals/utils/dom-utils.js.map +1 -0
- package/{es-custom/react → es/globals}/utils/iconTransform.js +1 -2
- package/es/globals/utils/iconTransform.js.map +1 -0
- package/es/react/__tests__/jest.setup.js +1 -2
- package/es/react/__tests__/jest.setup.js.map +1 -1
- package/es/react/audio-player.js +0 -1
- package/es/react/audio-player.js.map +1 -1
- package/es/react/autocomplete.d.ts +11 -0
- package/es/react/autocomplete.js +36 -0
- package/es/react/autocomplete.js.map +1 -0
- package/es/react/chat-header.js +1 -1
- package/es/react/code-snippet.js +1 -1
- package/es/react/error-message.d.ts +11 -0
- package/es/react/error-message.js +28 -0
- package/es/react/error-message.js.map +1 -0
- package/es/react/file-uploads.d.ts +11 -0
- package/es/react/file-uploads.js +31 -0
- package/es/react/file-uploads.js.map +1 -0
- package/es/react/history/history-panel-item-input.js +1 -0
- package/es/react/history/history-panel-item-input.js.map +1 -1
- package/es/react/history/history-panel-item.js +1 -0
- package/es/react/history/history-panel-item.js.map +1 -1
- package/es/react/hooks/useChatAutocomplete.d.ts +41 -0
- package/es/react/hooks/useChatAutocomplete.js +178 -0
- package/es/react/hooks/useChatAutocomplete.js.map +1 -0
- package/es/react/input-send-control.d.ts +11 -0
- package/es/react/input-send-control.js +32 -0
- package/es/react/input-send-control.js.map +1 -0
- package/es/react/prompt-line-shell.d.ts +18 -0
- package/es/react/prompt-line-shell.js +36 -0
- package/es/react/prompt-line-shell.js.map +1 -0
- package/es/react/prompt-line.d.ts +25 -0
- package/es/react/prompt-line.js +52 -0
- package/es/react/prompt-line.js.map +1 -0
- package/es/react/stop-streaming-button.d.ts +11 -0
- package/es/react/stop-streaming-button.js +28 -0
- package/es/react/stop-streaming-button.js.map +1 -0
- package/es/react/toolbar.js +1 -1
- package/es/react/transcript.js +0 -1
- package/es/react/transcript.js.map +1 -1
- package/es/react/utils/transformSuggestionConfig.d.ts +21 -0
- package/es/react/utils/transformSuggestionConfig.js +67 -0
- package/es/react/utils/transformSuggestionConfig.js.map +1 -0
- package/es/react/video-player.js +0 -1
- package/es/react/video-player.js.map +1 -1
- package/es/testing/PageObjectId.js +1 -2
- package/es/testing/PageObjectId.js.map +1 -1
- package/es-custom/components/audio-player/src/audio-player.js +9 -10
- package/es-custom/components/audio-player/src/audio-player.js.map +1 -1
- package/es-custom/components/audio-player/src/providers/base-provider.js +0 -1
- package/es-custom/components/audio-player/src/providers/base-provider.js.map +1 -1
- package/es-custom/components/audio-player/src/providers/native-audio-provider.js +0 -1
- package/es-custom/components/audio-player/src/providers/native-audio-provider.js.map +1 -1
- package/es-custom/components/audio-player/src/providers/soundcloud-provider.js +0 -1
- package/es-custom/components/audio-player/src/providers/soundcloud-provider.js.map +1 -1
- package/es-custom/components/audio-player/src/transcript.js +15 -15
- package/es-custom/components/audio-player/src/transcript.js.map +1 -1
- package/es-custom/components/audio-player/src/utils/url-detector.js +0 -1
- package/es-custom/components/audio-player/src/utils/url-detector.js.map +1 -1
- package/es-custom/components/autocomplete/index.d.ts +15 -0
- package/es-custom/components/autocomplete/index.js +11 -0
- package/es-custom/components/autocomplete/index.js.map +1 -0
- package/es-custom/components/autocomplete/src/autocomplete-item-group.d.ts +44 -0
- package/es-custom/components/autocomplete/src/autocomplete-item-group.js +139 -0
- package/es-custom/components/autocomplete/src/autocomplete-item-group.js.map +1 -0
- package/es-custom/components/autocomplete/src/autocomplete-item-group.scss.js +13 -0
- package/es-custom/components/autocomplete/src/autocomplete-item-group.scss.js.map +1 -0
- package/es-custom/components/autocomplete/src/autocomplete-item.d.ts +54 -0
- package/es-custom/components/autocomplete/src/autocomplete-item.js +197 -0
- package/es-custom/components/autocomplete/src/autocomplete-item.js.map +1 -0
- package/es-custom/components/autocomplete/src/autocomplete-item.scss.js +13 -0
- package/es-custom/components/autocomplete/src/autocomplete-item.scss.js.map +1 -0
- package/es-custom/components/autocomplete/src/autocomplete.d.ts +97 -0
- package/es-custom/components/autocomplete/src/autocomplete.js +321 -0
- package/es-custom/components/autocomplete/src/autocomplete.js.map +1 -0
- package/es-custom/components/autocomplete/src/autocomplete.scss.js +13 -0
- package/es-custom/components/autocomplete/src/autocomplete.scss.js.map +1 -0
- package/es-custom/components/card/src/card-footer.d.ts +1 -1
- package/es-custom/components/card/src/card-footer.js +1 -1
- package/es-custom/components/card/src/card-footer.js.map +1 -1
- package/es-custom/components/card/src/card-footer.scss.js +1 -1
- package/es-custom/components/card/src/card-steps.d.ts +1 -1
- package/es-custom/components/card/src/card-steps.js +28 -28
- package/es-custom/components/card/src/card-steps.js.map +1 -1
- package/es-custom/components/card/src/card-steps.scss.js +1 -1
- package/es-custom/components/card/src/card.scss.js +1 -1
- package/es-custom/components/carousel/src/carousel.js +0 -1
- package/es-custom/components/carousel/src/carousel.js.map +1 -1
- package/es-custom/components/chain-of-thought/src/chain-of-thought-step.js +1 -1
- package/es-custom/components/chain-of-thought/src/chain-of-thought-step.js.map +1 -1
- package/es-custom/components/chain-of-thought/src/tool-call-data.js +4 -4
- package/es-custom/components/chain-of-thought/src/tool-call-data.js.map +1 -1
- package/es-custom/components/chat-button/src/chat-button.d.ts +1 -1
- package/es-custom/components/chat-button/src/chat-button.js +1 -1
- package/es-custom/components/chat-button/src/chat-button.js.map +1 -1
- package/es-custom/components/chat-button/src/chat-button.scss.js +1 -1
- package/es-custom/components/chat-history/src/chat-history.scss.js +1 -1
- package/es-custom/components/chat-history/src/history-content.js +2 -2
- package/es-custom/components/chat-history/src/history-content.js.map +1 -1
- package/es-custom/components/chat-history/src/history-header.js +8 -8
- package/es-custom/components/chat-history/src/history-header.js.map +1 -1
- package/es-custom/components/chat-history/src/history-panel-item-input.d.ts +19 -2
- package/es-custom/components/chat-history/src/history-panel-item-input.js +69 -19
- package/es-custom/components/chat-history/src/history-panel-item-input.js.map +1 -1
- package/es-custom/components/chat-history/src/history-panel-item.d.ts +14 -0
- package/es-custom/components/chat-history/src/history-panel-item.js +59 -27
- package/es-custom/components/chat-history/src/history-panel-item.js.map +1 -1
- package/es-custom/components/chat-history/src/history-toolbar.js +3 -3
- package/es-custom/components/chat-history/src/history-toolbar.js.map +1 -1
- package/es-custom/components/chat-shell/src/chat-header.js +15 -16
- package/es-custom/components/chat-shell/src/chat-header.js.map +1 -1
- package/es-custom/components/chat-shell/src/corner-manager.d.ts +1 -1
- package/es-custom/components/chat-shell/src/corner-manager.js +1 -2
- package/es-custom/components/chat-shell/src/corner-manager.js.map +1 -1
- package/es-custom/components/chat-shell/src/initialization-manager.d.ts +1 -1
- package/es-custom/components/chat-shell/src/initialization-manager.js +1 -2
- package/es-custom/components/chat-shell/src/initialization-manager.js.map +1 -1
- package/es-custom/components/chat-shell/src/resize-observer-manager.js +0 -1
- package/es-custom/components/chat-shell/src/resize-observer-manager.js.map +1 -1
- package/es-custom/components/chat-shell/src/shell.d.ts +1 -1
- package/es-custom/components/chat-shell/src/shell.js +3 -3
- package/es-custom/components/chat-shell/src/shell.js.map +1 -1
- package/es-custom/components/chat-shell/src/slot-observer.d.ts +1 -1
- package/es-custom/components/chat-shell/src/slot-observer.js +1 -2
- package/es-custom/components/chat-shell/src/slot-observer.js.map +1 -1
- package/es-custom/components/chat-shell/src/types.d.ts +1 -1
- package/es-custom/components/chat-shell/src/workspace-manager-utils.d.ts +1 -1
- package/es-custom/components/chat-shell/src/workspace-manager-utils.js +1 -2
- package/es-custom/components/chat-shell/src/workspace-manager-utils.js.map +1 -1
- package/es-custom/components/chat-shell/src/workspace-manager.d.ts +1 -1
- package/es-custom/components/chat-shell/src/workspace-manager.js +1 -2
- package/es-custom/components/chat-shell/src/workspace-manager.js.map +1 -1
- package/es-custom/components/code-snippet/src/code-snippet.d.ts +23 -0
- package/es-custom/components/code-snippet/src/code-snippet.js +111 -36
- package/es-custom/components/code-snippet/src/code-snippet.js.map +1 -1
- package/es-custom/components/code-snippet/src/code-snippet.scss.js +1 -1
- package/es-custom/components/code-snippet/src/codemirror/diff-decorator.js +1 -1
- package/es-custom/components/code-snippet/src/codemirror/diff-decorator.js.map +1 -1
- package/es-custom/components/code-snippet/src/codemirror/theme.js +5 -0
- package/es-custom/components/code-snippet/src/codemirror/theme.js.map +1 -1
- package/es-custom/components/code-snippet/src/layout-utils.js +21 -8
- package/es-custom/components/code-snippet/src/layout-utils.js.map +1 -1
- package/es-custom/components/feedback/src/feedback-buttons.js +1 -1
- package/es-custom/components/feedback/src/feedback-buttons.js.map +1 -1
- package/es-custom/components/feedback/src/feedback.js +38 -38
- package/es-custom/components/feedback/src/feedback.js.map +1 -1
- package/es-custom/components/feedback/src/feedback.scss.js +1 -1
- package/es-custom/components/file-uploads/index.d.ts +12 -0
- package/es-custom/components/file-uploads/index.js +10 -0
- package/es-custom/components/file-uploads/index.js.map +1 -0
- package/es-custom/components/file-uploads/src/file-upload-item.d.ts +43 -0
- package/es-custom/components/file-uploads/src/file-upload-item.js +267 -0
- package/es-custom/components/file-uploads/src/file-upload-item.js.map +1 -0
- package/es-custom/components/file-uploads/src/file-upload-item.scss.js +13 -0
- package/es-custom/components/file-uploads/src/file-upload-item.scss.js.map +1 -0
- package/es-custom/components/file-uploads/src/file-uploads.d.ts +87 -0
- package/es-custom/components/file-uploads/src/file-uploads.js +213 -0
- package/es-custom/components/file-uploads/src/file-uploads.js.map +1 -0
- package/es-custom/components/file-uploads/src/file-uploads.scss.js +13 -0
- package/es-custom/components/file-uploads/src/file-uploads.scss.js.map +1 -0
- package/es-custom/components/markdown/index.d.ts +1 -0
- package/es-custom/components/markdown/index.js +1 -0
- package/es-custom/components/markdown/index.js.map +1 -1
- package/es-custom/components/markdown/src/markdown-token-tree.d.ts +8 -0
- package/es-custom/components/markdown/src/markdown-token-tree.js +12 -1
- package/es-custom/components/markdown/src/markdown-token-tree.js.map +1 -1
- package/es-custom/components/markdown/src/markdown.js +4 -0
- package/es-custom/components/markdown/src/markdown.js.map +1 -1
- package/es-custom/components/markdown/src/markdown.scss.js +1 -1
- package/es-custom/components/markdown/src/utils/html-helpers.js.map +1 -1
- package/es-custom/components/prompt-line/index.d.ts +26 -0
- package/es-custom/components/prompt-line/index.js +32 -0
- package/es-custom/components/prompt-line/index.js.map +1 -0
- package/es-custom/components/prompt-line/src/autocomplete-controller.d.ts +178 -0
- package/es-custom/components/prompt-line/src/autocomplete-controller.js +548 -0
- package/es-custom/components/prompt-line/src/autocomplete-controller.js.map +1 -0
- package/es-custom/components/prompt-line/src/error-message.d.ts +50 -0
- package/es-custom/components/prompt-line/src/error-message.js +144 -0
- package/es-custom/components/prompt-line/src/error-message.js.map +1 -0
- package/es-custom/components/prompt-line/src/error-message.scss.js +13 -0
- package/es-custom/components/prompt-line/src/error-message.scss.js.map +1 -0
- package/es-custom/components/prompt-line/src/prompt-line-constants.d.ts +17 -0
- package/es-custom/components/prompt-line/src/prompt-line-constants.js +27 -0
- package/es-custom/components/prompt-line/src/prompt-line-constants.js.map +1 -0
- package/es-custom/components/prompt-line/src/prompt-line-controller.d.ts +155 -0
- package/es-custom/components/prompt-line/src/prompt-line-controller.js +394 -0
- package/es-custom/components/prompt-line/src/prompt-line-controller.js.map +1 -0
- package/es-custom/components/prompt-line/src/prompt-line-rich-loader.d.ts +34 -0
- package/es-custom/components/prompt-line/src/prompt-line-rich-loader.js +51 -0
- package/es-custom/components/prompt-line/src/prompt-line-rich-loader.js.map +1 -0
- package/es-custom/components/prompt-line/src/prompt-line-rich-runtime.d.ts +14 -0
- package/es-custom/components/prompt-line/src/prompt-line-rich-runtime.js +340 -0
- package/es-custom/components/prompt-line/src/prompt-line-rich-runtime.js.map +1 -0
- package/es-custom/components/prompt-line/src/prompt-line-shell.d.ts +72 -0
- package/es-custom/components/prompt-line/src/prompt-line-shell.js +227 -0
- package/es-custom/components/prompt-line/src/prompt-line-shell.js.map +1 -0
- package/es-custom/components/prompt-line/src/prompt-line-shell.scss.js +13 -0
- package/es-custom/components/prompt-line/src/prompt-line-shell.scss.js.map +1 -0
- package/es-custom/components/prompt-line/src/prompt-line.d.ts +147 -0
- package/es-custom/components/prompt-line/src/prompt-line.js +391 -0
- package/es-custom/components/prompt-line/src/prompt-line.js.map +1 -0
- package/es-custom/components/prompt-line/src/prompt-line.scss.js +13 -0
- package/es-custom/components/prompt-line/src/prompt-line.scss.js.map +1 -0
- package/es-custom/components/prompt-line/src/send-control.d.ts +46 -0
- package/es-custom/components/prompt-line/src/send-control.js +138 -0
- package/es-custom/components/prompt-line/src/send-control.js.map +1 -0
- package/es-custom/components/prompt-line/src/send-control.scss.js +13 -0
- package/es-custom/components/prompt-line/src/send-control.scss.js.map +1 -0
- package/es-custom/components/prompt-line/src/stop-streaming-button.d.ts +42 -0
- package/es-custom/components/prompt-line/src/stop-streaming-button.js +93 -0
- package/es-custom/components/prompt-line/src/stop-streaming-button.js.map +1 -0
- package/es-custom/components/prompt-line/src/stop-streaming-button.scss.js +13 -0
- package/es-custom/components/prompt-line/src/stop-streaming-button.scss.js.map +1 -0
- package/es-custom/components/prompt-line/src/tiptap/build-extensions.d.ts +30 -0
- package/es-custom/components/prompt-line/src/tiptap/build-extensions.js +38 -0
- package/es-custom/components/prompt-line/src/tiptap/build-extensions.js.map +1 -0
- package/es-custom/components/prompt-line/src/tiptap/carbon-autocomplete.d.ts +21 -0
- package/es-custom/components/prompt-line/src/tiptap/carbon-autocomplete.js +127 -0
- package/es-custom/components/prompt-line/src/tiptap/carbon-autocomplete.js.map +1 -0
- package/es-custom/components/prompt-line/src/tiptap/carbon-mention.d.ts +19 -0
- package/es-custom/components/prompt-line/src/tiptap/carbon-mention.js +237 -0
- package/es-custom/components/prompt-line/src/tiptap/carbon-mention.js.map +1 -0
- package/es-custom/components/prompt-line/src/tiptap/carbon-starter-trigger.d.ts +22 -0
- package/es-custom/components/prompt-line/src/tiptap/carbon-starter-trigger.js +64 -0
- package/es-custom/components/prompt-line/src/tiptap/carbon-starter-trigger.js.map +1 -0
- package/es-custom/components/prompt-line/src/tiptap/chat-enter.d.ts +17 -0
- package/es-custom/components/prompt-line/src/tiptap/chat-enter.js +46 -0
- package/es-custom/components/prompt-line/src/tiptap/chat-enter.js.map +1 -0
- package/es-custom/components/prompt-line/src/tiptap/editor-styles.d.ts +18 -0
- package/es-custom/components/prompt-line/src/tiptap/editor-styles.js +83 -0
- package/es-custom/components/prompt-line/src/tiptap/editor-styles.js.map +1 -0
- package/es-custom/components/prompt-line/src/tiptap/index.d.ts +42 -0
- package/es-custom/components/prompt-line/src/tiptap/index.js +43 -0
- package/es-custom/components/prompt-line/src/tiptap/index.js.map +1 -0
- package/es-custom/components/prompt-line/src/tiptap/json-utils.d.ts +61 -0
- package/es-custom/components/prompt-line/src/tiptap/json-utils.js +158 -0
- package/es-custom/components/prompt-line/src/tiptap/json-utils.js.map +1 -0
- package/es-custom/components/prompt-line/src/tiptap/keymap.d.ts +31 -0
- package/es-custom/components/prompt-line/src/tiptap/keymap.js +59 -0
- package/es-custom/components/prompt-line/src/tiptap/keymap.js.map +1 -0
- package/es-custom/components/prompt-line/src/tiptap/origin-meta.d.ts +11 -0
- package/es-custom/components/prompt-line/src/tiptap/origin-meta.js +33 -0
- package/es-custom/components/prompt-line/src/tiptap/origin-meta.js.map +1 -0
- package/es-custom/components/prompt-line/src/tiptap/plain-text-paste.d.ts +16 -0
- package/es-custom/components/prompt-line/src/tiptap/plain-text-paste.js +85 -0
- package/es-custom/components/prompt-line/src/tiptap/plain-text-paste.js.map +1 -0
- package/es-custom/components/prompt-line/src/tiptap/render-in-light-dom.d.ts +87 -0
- package/es-custom/components/prompt-line/src/tiptap/render-in-light-dom.js +41 -0
- package/es-custom/components/prompt-line/src/tiptap/render-in-light-dom.js.map +1 -0
- package/es-custom/components/prompt-line/src/tiptap/render-token-chip.d.ts +57 -0
- package/es-custom/components/prompt-line/src/tiptap/render-token-chip.js +95 -0
- package/es-custom/components/prompt-line/src/tiptap/render-token-chip.js.map +1 -0
- package/es-custom/components/prompt-line/src/tiptap/token-node-view.d.ts +36 -0
- package/es-custom/components/prompt-line/src/tiptap/token-node-view.js +41 -0
- package/es-custom/components/prompt-line/src/tiptap/token-node-view.js.map +1 -0
- package/es-custom/components/prompt-line/src/tiptap/trigger-utils.d.ts +30 -0
- package/es-custom/components/prompt-line/src/tiptap/trigger-utils.js +44 -0
- package/es-custom/components/prompt-line/src/tiptap/trigger-utils.js.map +1 -0
- package/es-custom/components/prompt-line/src/tiptap/types.d.ts +161 -0
- package/es-custom/components/prompt-line/src/tiptap/types.js +8 -0
- package/es-custom/components/prompt-line/src/tiptap/types.js.map +1 -0
- package/es-custom/components/prompt-line/src/tiptap/typing-indicator.d.ts +30 -0
- package/es-custom/components/prompt-line/src/tiptap/typing-indicator.js +104 -0
- package/es-custom/components/prompt-line/src/tiptap/typing-indicator.js.map +1 -0
- package/es-custom/components/prompt-line/src/tiptap/value-sync.d.ts +25 -0
- package/es-custom/components/prompt-line/src/tiptap/value-sync.js +65 -0
- package/es-custom/components/prompt-line/src/tiptap/value-sync.js.map +1 -0
- package/es-custom/components/prompt-line/src/types.d.ts +100 -0
- package/es-custom/components/prompt-line/src/types.js +50 -0
- package/es-custom/components/prompt-line/src/types.js.map +1 -0
- package/es-custom/components/reasoning-steps/src/reasoning-step.d.ts +13 -0
- package/es-custom/components/reasoning-steps/src/reasoning-step.js +38 -0
- package/es-custom/components/reasoning-steps/src/reasoning-step.js.map +1 -1
- package/es-custom/components/reasoning-steps/src/reasoning-steps.d.ts +23 -0
- package/es-custom/components/reasoning-steps/src/reasoning-steps.js +56 -1
- package/es-custom/components/reasoning-steps/src/reasoning-steps.js.map +1 -1
- package/es-custom/components/shared/dynamic-css-var-sheet.js +4 -1
- package/es-custom/components/shared/dynamic-css-var-sheet.js.map +1 -1
- package/es-custom/components/shared/media-utils/script-loader.js +0 -1
- package/es-custom/components/shared/media-utils/script-loader.js.map +1 -1
- package/es-custom/components/table/src/table.scss.js +1 -1
- package/es-custom/components/table/src/table.template.js +9 -9
- package/es-custom/components/table/src/table.template.js.map +1 -1
- package/es-custom/components/toolbar/src/toolbar.js +51 -53
- package/es-custom/components/toolbar/src/toolbar.js.map +1 -1
- package/es-custom/components/video-player/src/providers/base-provider.js +0 -1
- package/es-custom/components/video-player/src/providers/base-provider.js.map +1 -1
- package/es-custom/components/video-player/src/providers/kaltura-provider.js +0 -1
- package/es-custom/components/video-player/src/providers/kaltura-provider.js.map +1 -1
- package/es-custom/components/video-player/src/providers/native-video-provider.js +0 -1
- package/es-custom/components/video-player/src/providers/native-video-provider.js.map +1 -1
- package/es-custom/components/video-player/src/providers/vimeo-provider.js +0 -1
- package/es-custom/components/video-player/src/providers/vimeo-provider.js.map +1 -1
- package/es-custom/components/video-player/src/providers/youtube-provider.js +0 -1
- package/es-custom/components/video-player/src/providers/youtube-provider.js.map +1 -1
- package/es-custom/components/video-player/src/utils/url-detector.js +0 -1
- package/es-custom/components/video-player/src/utils/url-detector.js.map +1 -1
- package/es-custom/components/video-player/src/video-player.js +9 -10
- package/es-custom/components/video-player/src/video-player.js.map +1 -1
- package/es-custom/components/workspace-shell/src/header-collapsible-manager.js +0 -1
- package/es-custom/components/workspace-shell/src/header-collapsible-manager.js.map +1 -1
- package/es-custom/components/workspace-shell/src/workspace-shell-header.js +25 -25
- package/es-custom/components/workspace-shell/src/workspace-shell-header.js.map +1 -1
- package/es-custom/globals/utils/aria-announcer-manager.d.ts +62 -0
- package/es-custom/globals/utils/aria-announcer-manager.js +125 -0
- package/es-custom/globals/utils/aria-announcer-manager.js.map +1 -0
- package/es-custom/globals/utils/browser-utils.d.ts +10 -0
- package/es-custom/globals/utils/browser-utils.js +37 -0
- package/es-custom/globals/utils/browser-utils.js.map +1 -0
- package/es-custom/globals/utils/dom-utils.d.ts +6 -0
- package/es-custom/globals/utils/dom-utils.js +39 -0
- package/es-custom/globals/utils/dom-utils.js.map +1 -0
- package/{es/react → es-custom/globals}/utils/iconTransform.js +1 -2
- package/es-custom/globals/utils/iconTransform.js.map +1 -0
- package/es-custom/react/__tests__/jest.setup.js +1 -2
- package/es-custom/react/__tests__/jest.setup.js.map +1 -1
- package/es-custom/react/audio-player.js +0 -1
- package/es-custom/react/audio-player.js.map +1 -1
- package/es-custom/react/autocomplete.d.ts +11 -0
- package/es-custom/react/autocomplete.js +36 -0
- package/es-custom/react/autocomplete.js.map +1 -0
- package/es-custom/react/chat-header.js +1 -1
- package/es-custom/react/code-snippet.js +1 -1
- package/es-custom/react/error-message.d.ts +11 -0
- package/es-custom/react/error-message.js +28 -0
- package/es-custom/react/error-message.js.map +1 -0
- package/es-custom/react/file-uploads.d.ts +11 -0
- package/es-custom/react/file-uploads.js +31 -0
- package/es-custom/react/file-uploads.js.map +1 -0
- package/es-custom/react/history/history-panel-item-input.js +1 -0
- package/es-custom/react/history/history-panel-item-input.js.map +1 -1
- package/es-custom/react/history/history-panel-item.js +1 -0
- package/es-custom/react/history/history-panel-item.js.map +1 -1
- package/es-custom/react/hooks/useChatAutocomplete.d.ts +41 -0
- package/es-custom/react/hooks/useChatAutocomplete.js +178 -0
- package/es-custom/react/hooks/useChatAutocomplete.js.map +1 -0
- package/es-custom/react/input-send-control.d.ts +11 -0
- package/es-custom/react/input-send-control.js +32 -0
- package/es-custom/react/input-send-control.js.map +1 -0
- package/es-custom/react/prompt-line-shell.d.ts +18 -0
- package/es-custom/react/prompt-line-shell.js +36 -0
- package/es-custom/react/prompt-line-shell.js.map +1 -0
- package/es-custom/react/prompt-line.d.ts +25 -0
- package/es-custom/react/prompt-line.js +52 -0
- package/es-custom/react/prompt-line.js.map +1 -0
- package/es-custom/react/stop-streaming-button.d.ts +11 -0
- package/es-custom/react/stop-streaming-button.js +28 -0
- package/es-custom/react/stop-streaming-button.js.map +1 -0
- package/es-custom/react/toolbar.js +1 -1
- package/es-custom/react/transcript.js +0 -1
- package/es-custom/react/transcript.js.map +1 -1
- package/es-custom/react/utils/transformSuggestionConfig.d.ts +21 -0
- package/es-custom/react/utils/transformSuggestionConfig.js +67 -0
- package/es-custom/react/utils/transformSuggestionConfig.js.map +1 -0
- package/es-custom/react/video-player.js +0 -1
- package/es-custom/react/video-player.js.map +1 -1
- package/es-custom/testing/PageObjectId.js +1 -2
- package/es-custom/testing/PageObjectId.js.map +1 -1
- package/package.json +27 -6
- package/scss/_custom-properties.scss +1 -3
- package/scss/_modifiers.scss +17 -49
- package/scss/_tokens-component.scss +1 -3
- package/scss/_tokens-layout.scss +1 -3
- package/scss/_utilities.scss +1 -3
- package/LICENSE +0 -201
- package/es/components/chat-shell/src/aria-announcer-manager.d.ts +0 -40
- package/es/components/chat-shell/src/aria-announcer-manager.js +0 -104
- package/es/components/chat-shell/src/aria-announcer-manager.js.map +0 -1
- package/es/react/utils/iconTransform.js.map +0 -1
- package/es-custom/components/chat-shell/src/aria-announcer-manager.d.ts +0 -40
- package/es-custom/components/chat-shell/src/aria-announcer-manager.js +0 -104
- package/es-custom/components/chat-shell/src/aria-announcer-manager.js.map +0 -1
- package/es-custom/react/utils/iconTransform.js.map +0 -1
- /package/es/{react → globals}/utils/iconTransform.d.ts +0 -0
- /package/es-custom/{react → globals}/utils/iconTransform.d.ts +0 -0
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*
|
|
4
|
+
* Copyright IBM Corp. 2026
|
|
5
|
+
*
|
|
6
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
|
7
|
+
* LICENSE file in the root directory of this source tree.
|
|
8
|
+
*/
|
|
9
|
+
import { LitElement } from "lit";
|
|
10
|
+
import "@carbon/web-components/es-custom/components/icon-button/index.js";
|
|
11
|
+
/**
|
|
12
|
+
* Stop streaming button component for AI Chat input.
|
|
13
|
+
*
|
|
14
|
+
* @element cds-custom-aichat-stop-streaming-button
|
|
15
|
+
*/
|
|
16
|
+
declare class StopStreamingButton extends LitElement {
|
|
17
|
+
static styles: import("lit").CSSResult;
|
|
18
|
+
/**
|
|
19
|
+
* The label to display in the button tooltip.
|
|
20
|
+
*/
|
|
21
|
+
label: string;
|
|
22
|
+
/**
|
|
23
|
+
* The direction to align the tooltip to the button.
|
|
24
|
+
*/
|
|
25
|
+
tooltipAlignment: string;
|
|
26
|
+
/**
|
|
27
|
+
* Determines whether the stop generating button is disabled.
|
|
28
|
+
*/
|
|
29
|
+
disabled: boolean;
|
|
30
|
+
/**
|
|
31
|
+
* The callback function that is called when the user clicks the stop streaming button.
|
|
32
|
+
*/
|
|
33
|
+
onClick: (() => void) | undefined;
|
|
34
|
+
_handleOnClick: () => void;
|
|
35
|
+
render(): import("lit-html").TemplateResult<1>;
|
|
36
|
+
}
|
|
37
|
+
declare global {
|
|
38
|
+
interface HTMLElementTagNameMap {
|
|
39
|
+
"cds-custom-aichat-stop-streaming-button": StopStreamingButton;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
export default StopStreamingButton;
|
|
@@ -0,0 +1,93 @@
|
|
|
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 { __decorate } from 'tslib';
|
|
9
|
+
import { unsafeCSS, css, LitElement, html } from 'lit';
|
|
10
|
+
import { property } from 'lit/decorators.js';
|
|
11
|
+
import '@carbon/web-components/es-custom/components/icon-button/index.js';
|
|
12
|
+
import { iconLoader } from '@carbon/web-components/es-custom/globals/internal/icon-loader.js';
|
|
13
|
+
import StopFilled16 from '@carbon/icons/es/stop--filled/16.js';
|
|
14
|
+
import { carbonElement } from '../../../globals/decorators/carbon-element.js';
|
|
15
|
+
import prefix from '../../../globals/settings.js';
|
|
16
|
+
import { BUTTON_KIND, BUTTON_SIZE } from '@carbon/web-components/es-custom/components/button/defs.js';
|
|
17
|
+
import styles from './stop-streaming-button.scss.js';
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* @license
|
|
21
|
+
*
|
|
22
|
+
* Copyright IBM Corp. 2026
|
|
23
|
+
*
|
|
24
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
|
25
|
+
* LICENSE file in the root directory of this source tree.
|
|
26
|
+
*/
|
|
27
|
+
/**
|
|
28
|
+
* Stop streaming button component for AI Chat input.
|
|
29
|
+
*
|
|
30
|
+
* @element cds-custom-aichat-stop-streaming-button
|
|
31
|
+
*/
|
|
32
|
+
let StopStreamingButton = class StopStreamingButton extends LitElement {
|
|
33
|
+
constructor() {
|
|
34
|
+
super(...arguments);
|
|
35
|
+
/**
|
|
36
|
+
* The label to display in the button tooltip.
|
|
37
|
+
*/
|
|
38
|
+
this.label = "";
|
|
39
|
+
/**
|
|
40
|
+
* The direction to align the tooltip to the button.
|
|
41
|
+
*/
|
|
42
|
+
this.tooltipAlignment = "";
|
|
43
|
+
/**
|
|
44
|
+
* Determines whether the stop generating button is disabled.
|
|
45
|
+
*/
|
|
46
|
+
this.disabled = false;
|
|
47
|
+
this._handleOnClick = () => {
|
|
48
|
+
this.onClick?.();
|
|
49
|
+
};
|
|
50
|
+
}
|
|
51
|
+
render() {
|
|
52
|
+
return html `
|
|
53
|
+
<cds-custom-icon-button
|
|
54
|
+
class="${prefix}--stop-streaming-button"
|
|
55
|
+
align="${this.tooltipAlignment}"
|
|
56
|
+
kind="${BUTTON_KIND.GHOST}"
|
|
57
|
+
size="${BUTTON_SIZE.SMALL}"
|
|
58
|
+
?disabled=${this.disabled}
|
|
59
|
+
@click="${this._handleOnClick}"
|
|
60
|
+
>
|
|
61
|
+
<span slot="icon">
|
|
62
|
+
<span
|
|
63
|
+
class="${prefix}--stop-icon ${this.disabled ? `${prefix}--stop-icon--disabled` : ""}"
|
|
64
|
+
>${iconLoader(StopFilled16)}</span
|
|
65
|
+
>
|
|
66
|
+
</span>
|
|
67
|
+
<span slot="tooltip-content">${this.label}</span>
|
|
68
|
+
</cds-custom-icon-button>
|
|
69
|
+
`;
|
|
70
|
+
}
|
|
71
|
+
};
|
|
72
|
+
StopStreamingButton.styles = css `
|
|
73
|
+
${unsafeCSS(styles)}
|
|
74
|
+
`;
|
|
75
|
+
__decorate([
|
|
76
|
+
property({ type: String, attribute: "label" })
|
|
77
|
+
], StopStreamingButton.prototype, "label", void 0);
|
|
78
|
+
__decorate([
|
|
79
|
+
property({ type: String, attribute: "tooltip-alignment" })
|
|
80
|
+
], StopStreamingButton.prototype, "tooltipAlignment", void 0);
|
|
81
|
+
__decorate([
|
|
82
|
+
property({ type: Boolean, attribute: "disabled" })
|
|
83
|
+
], StopStreamingButton.prototype, "disabled", void 0);
|
|
84
|
+
__decorate([
|
|
85
|
+
property({ type: Object })
|
|
86
|
+
], StopStreamingButton.prototype, "onClick", void 0);
|
|
87
|
+
StopStreamingButton = __decorate([
|
|
88
|
+
carbonElement(`${prefix}-stop-streaming-button`)
|
|
89
|
+
], StopStreamingButton);
|
|
90
|
+
var StopStreamingButton$1 = StopStreamingButton;
|
|
91
|
+
|
|
92
|
+
export { StopStreamingButton$1 as default };
|
|
93
|
+
//# sourceMappingURL=stop-streaming-button.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"stop-streaming-button.js","sources":["../../../../src/components/prompt-line/src/stop-streaming-button.ts"],"sourcesContent":[null],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAAA;;;;;;;AAOG;AAoBH;;;;AAIG;AAEH,IAAM,mBAAmB,GAAzB,MAAM,mBAAoB,SAAQ,UAAU,CAAA;AAA5C,IAAA,WAAA,GAAA;;AAKE;;AAEG;QAEH,IAAA,CAAA,KAAK,GAAG,EAAE;AAEV;;AAEG;QAEH,IAAA,CAAA,gBAAgB,GAAG,EAAE;AAErB;;AAEG;QAEH,IAAA,CAAA,QAAQ,GAAG,KAAK;QAQhB,IAAA,CAAA,cAAc,GAAG,MAAK;AACpB,YAAA,IAAI,CAAC,OAAO,IAAI;AAClB,QAAA,CAAC;IAwBH;IAtBE,MAAM,GAAA;AACJ,QAAA,OAAO,IAAI,CAAA;;iBAEE,MAAM,CAAA;AACN,eAAA,EAAA,IAAI,CAAC,gBAAgB,CAAA;AACtB,cAAA,EAAA,WA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;;"}
|
|
@@ -0,0 +1,13 @@
|
|
|
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 { css } from 'lit';
|
|
9
|
+
|
|
10
|
+
var styles = css([".cds-custom-aichat--stop-icon svg{padding-block-start:4px}.cds-custom-aichat--stop-icon--disabled svg{fill:var(--cds-icon-disabled,hsla(0,0%,9%,.25))}"]);
|
|
11
|
+
|
|
12
|
+
export { styles as default };
|
|
13
|
+
//# sourceMappingURL=stop-streaming-button.scss.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"stop-streaming-button.scss.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*
|
|
4
|
+
* Copyright IBM Corp. 2026
|
|
5
|
+
*
|
|
6
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
|
7
|
+
* LICENSE file in the root directory of this source tree.
|
|
8
|
+
*/
|
|
9
|
+
/**
|
|
10
|
+
* Pure helper: translate the chat-domain configs surfaced on
|
|
11
|
+
* `<cds-custom-aichat-prompt-line-shell>` (and `InputConfig`) into a curated Tiptap
|
|
12
|
+
* extension list. Used by the shell's render logic and exposed publicly so
|
|
13
|
+
* direct `<cds-custom-aichat-prompt-line>` consumers can call the same builder
|
|
14
|
+
* without bringing the chrome along.
|
|
15
|
+
*
|
|
16
|
+
* Filters out `undefined` / empty configs so the returned list contains
|
|
17
|
+
* exactly the extensions whose backing config was supplied. Enter-to-send is
|
|
18
|
+
* **not** included here — `<cds-custom-aichat-prompt-line>` bakes `carbonChatEnter`
|
|
19
|
+
* into its own base bundle, so both the textarea and rich surfaces send on
|
|
20
|
+
* Enter without this builder.
|
|
21
|
+
*/
|
|
22
|
+
import type { Extension } from "@tiptap/core";
|
|
23
|
+
import type { AutocompleteConfig, SuggestionItem, TriggerSuggestionConfig } from "./types.js";
|
|
24
|
+
export interface BuildCarbonExtensionsConfig {
|
|
25
|
+
mention?: TriggerSuggestionConfig;
|
|
26
|
+
command?: TriggerSuggestionConfig;
|
|
27
|
+
autocomplete?: AutocompleteConfig;
|
|
28
|
+
starters?: SuggestionItem[];
|
|
29
|
+
}
|
|
30
|
+
export declare function buildCarbonExtensions(configs: BuildCarbonExtensionsConfig): Extension[];
|
|
@@ -0,0 +1,38 @@
|
|
|
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 { carbonAutocomplete } from './carbon-autocomplete.js';
|
|
9
|
+
import { carbonMention, carbonCommand } from './carbon-mention.js';
|
|
10
|
+
import { carbonStarterTrigger } from './carbon-starter-trigger.js';
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* @license
|
|
14
|
+
*
|
|
15
|
+
* Copyright IBM Corp. 2026
|
|
16
|
+
*
|
|
17
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
|
18
|
+
* LICENSE file in the root directory of this source tree.
|
|
19
|
+
*/
|
|
20
|
+
function buildCarbonExtensions(configs) {
|
|
21
|
+
const out = [];
|
|
22
|
+
if (configs.mention) {
|
|
23
|
+
out.push(carbonMention(configs.mention));
|
|
24
|
+
}
|
|
25
|
+
if (configs.command) {
|
|
26
|
+
out.push(carbonCommand(configs.command));
|
|
27
|
+
}
|
|
28
|
+
if (configs.autocomplete) {
|
|
29
|
+
out.push(carbonAutocomplete(configs.autocomplete));
|
|
30
|
+
}
|
|
31
|
+
if (configs.starters && configs.starters.length > 0) {
|
|
32
|
+
out.push(carbonStarterTrigger(configs.starters));
|
|
33
|
+
}
|
|
34
|
+
return out;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
export { buildCarbonExtensions };
|
|
38
|
+
//# sourceMappingURL=build-extensions.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"build-extensions.js","sources":["../../../../../src/components/prompt-line/src/tiptap/build-extensions.ts"],"sourcesContent":[null],"names":[],"mappings":";;;;;;;;;;;AAAA;;;;;;;AAOG;AAkCG,SAAU,qBAAqB,CACnC,OAAoC,EAAA;IAEpC,MAAM,GAAG,GAAgB,EAAE;AAC3B,IAAA,IAAI,OAAO,CAAC,OAAO,EAAE;QACnB,GAAG,CAAC,IAAI,CAAC,aAAa,CAAC,OAAO,CAAC,OAAO,CAAyB,CAAC;IAClE;AACA,IAAA,IAAI,OAAO,CAAC,OAAO,EAAE;QACnB,GAAG,CAAC,IAAI,CAAC,aAAa,CAAC,OAAO,CAAC,OAAO,CAAyB,CAAC;IAClE;AACA,IAAA,IAAI,OAAO,CAAC,YAAY,EAAE;QACxB,GAAG,CAAC,IAAI,CAAC,kBAAkB,CAAC,OAAO,CAAC,YAAY,CAAC,CAAC;IACpD;AACA,IAAA,IAAI,OAAO,CAAC,QAAQ,IAAI,OAAO,CAAC,QAAQ,CAAC,MAAM,GAAG,CAAC,EAAE;QACnD,GAAG,CAAC,IAAI,CAAC,oBAAoB,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC;IAClD;AACA,IAAA,OAAO,GAAG;AACZ;;;;"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*
|
|
4
|
+
* Copyright IBM Corp. 2026
|
|
5
|
+
*
|
|
6
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
|
7
|
+
* LICENSE file in the root directory of this source tree.
|
|
8
|
+
*/
|
|
9
|
+
/**
|
|
10
|
+
* `carbonAutocomplete` factory. Wraps `@tiptap/suggestion` directly (no
|
|
11
|
+
* Mention node) — the `command` callback inserts plain text rather than a
|
|
12
|
+
* schema node. Activates whenever the input has any non-empty text (the
|
|
13
|
+
* legacy autocomplete contract).
|
|
14
|
+
*
|
|
15
|
+
* Dispatches `cds-custom-aichat-trigger-change` with `type: "autocomplete"` from
|
|
16
|
+
* the suggestion-render lifecycle via the shared `dispatchTriggerChange`
|
|
17
|
+
* helper.
|
|
18
|
+
*/
|
|
19
|
+
import { Extension } from "@tiptap/core";
|
|
20
|
+
import type { AutocompleteConfig } from "./types.js";
|
|
21
|
+
export declare function carbonAutocomplete(config: AutocompleteConfig): Extension;
|
|
@@ -0,0 +1,127 @@
|
|
|
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 { Extension } from '@tiptap/core';
|
|
9
|
+
import { PluginKey } from '@tiptap/pm/state';
|
|
10
|
+
import Suggestion from '@tiptap/suggestion';
|
|
11
|
+
import { dispatchTriggerChange } from './trigger-utils.js';
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* @license
|
|
15
|
+
*
|
|
16
|
+
* Copyright IBM Corp. 2026
|
|
17
|
+
*
|
|
18
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
|
19
|
+
* LICENSE file in the root directory of this source tree.
|
|
20
|
+
*/
|
|
21
|
+
/**
|
|
22
|
+
* `carbonAutocomplete` factory. Wraps `@tiptap/suggestion` directly (no
|
|
23
|
+
* Mention node) — the `command` callback inserts plain text rather than a
|
|
24
|
+
* schema node. Activates whenever the input has any non-empty text (the
|
|
25
|
+
* legacy autocomplete contract).
|
|
26
|
+
*
|
|
27
|
+
* Dispatches `cds-custom-aichat-trigger-change` with `type: "autocomplete"` from
|
|
28
|
+
* the suggestion-render lifecycle via the shared `dispatchTriggerChange`
|
|
29
|
+
* helper.
|
|
30
|
+
*/
|
|
31
|
+
function carbonAutocomplete(config) {
|
|
32
|
+
const name = config.name ?? "autocomplete";
|
|
33
|
+
const pluginKey = new PluginKey(`carbonAutocompleteSuggestion_${name}`);
|
|
34
|
+
return Extension.create({
|
|
35
|
+
name: `carbon${capitalize(name)}`,
|
|
36
|
+
addProseMirrorPlugins() {
|
|
37
|
+
const editor = this.editor;
|
|
38
|
+
let lastQuery = null;
|
|
39
|
+
return [
|
|
40
|
+
Suggestion({
|
|
41
|
+
editor,
|
|
42
|
+
char: "",
|
|
43
|
+
pluginKey,
|
|
44
|
+
// Match any non-empty text as the autocomplete query.
|
|
45
|
+
allowedPrefixes: null,
|
|
46
|
+
findSuggestionMatch: ({ $position }) => {
|
|
47
|
+
const text = $position.parent.textBetween(0, $position.parentOffset, "\n", "\0");
|
|
48
|
+
if (!text || text.length === 0) {
|
|
49
|
+
return null;
|
|
50
|
+
}
|
|
51
|
+
// Restrict the query to the trailing word (split on whitespace).
|
|
52
|
+
const trailing = /\S+$/.exec(text);
|
|
53
|
+
if (!trailing) {
|
|
54
|
+
return null;
|
|
55
|
+
}
|
|
56
|
+
const query = trailing[0];
|
|
57
|
+
const matchStart = $position.start() + $position.parentOffset - query.length;
|
|
58
|
+
return {
|
|
59
|
+
range: {
|
|
60
|
+
from: matchStart,
|
|
61
|
+
to: $position.start() + $position.parentOffset,
|
|
62
|
+
},
|
|
63
|
+
query,
|
|
64
|
+
text: query,
|
|
65
|
+
};
|
|
66
|
+
},
|
|
67
|
+
items: ({ query }) => resolveItems(config, query),
|
|
68
|
+
command: ({ editor: ed, range, props }) => {
|
|
69
|
+
const item = props;
|
|
70
|
+
const insertText = item.value ?? item.label;
|
|
71
|
+
ed.chain()
|
|
72
|
+
.focus()
|
|
73
|
+
.insertContentAt(range, [{ type: "text", text: insertText }])
|
|
74
|
+
.run();
|
|
75
|
+
config.onSelect?.(item);
|
|
76
|
+
},
|
|
77
|
+
render: () => ({
|
|
78
|
+
onStart: (props) => {
|
|
79
|
+
lastQuery = props.query;
|
|
80
|
+
dispatchTriggerChange(props.editor, {
|
|
81
|
+
type: "autocomplete",
|
|
82
|
+
query: props.query,
|
|
83
|
+
triggerOffset: props.range.from,
|
|
84
|
+
});
|
|
85
|
+
},
|
|
86
|
+
onUpdate: (props) => {
|
|
87
|
+
if (props.query === lastQuery) {
|
|
88
|
+
return;
|
|
89
|
+
}
|
|
90
|
+
lastQuery = props.query;
|
|
91
|
+
dispatchTriggerChange(props.editor, {
|
|
92
|
+
type: "autocomplete",
|
|
93
|
+
query: props.query,
|
|
94
|
+
triggerOffset: props.range.from,
|
|
95
|
+
});
|
|
96
|
+
},
|
|
97
|
+
onExit: (props) => {
|
|
98
|
+
lastQuery = null;
|
|
99
|
+
dispatchTriggerChange(props.editor, null);
|
|
100
|
+
},
|
|
101
|
+
onKeyDown: () => false,
|
|
102
|
+
}),
|
|
103
|
+
}),
|
|
104
|
+
];
|
|
105
|
+
},
|
|
106
|
+
});
|
|
107
|
+
}
|
|
108
|
+
async function resolveItems(config, query) {
|
|
109
|
+
const minQueryLength = config.minQueryLength ?? 0;
|
|
110
|
+
if (query.length < minQueryLength) {
|
|
111
|
+
return [];
|
|
112
|
+
}
|
|
113
|
+
if (typeof config.items === "function") {
|
|
114
|
+
return Promise.resolve(config.items(query));
|
|
115
|
+
}
|
|
116
|
+
if (!query) {
|
|
117
|
+
return config.items;
|
|
118
|
+
}
|
|
119
|
+
const lower = query.toLowerCase();
|
|
120
|
+
return config.items.filter((item) => item.label.toLowerCase().includes(lower));
|
|
121
|
+
}
|
|
122
|
+
function capitalize(value) {
|
|
123
|
+
return value.charAt(0).toUpperCase() + value.slice(1);
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
export { carbonAutocomplete };
|
|
127
|
+
//# sourceMappingURL=carbon-autocomplete.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"carbon-autocomplete.js","sources":["../../../../../src/components/prompt-line/src/tiptap/carbon-autocomplete.ts"],"sourcesContent":[null],"names":[],"mappings":";;;;;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
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
|
7
|
+
* LICENSE file in the root directory of this source tree.
|
|
8
|
+
*/
|
|
9
|
+
import type { SuggestionItem, TriggerSuggestionConfig } from "./types.js";
|
|
10
|
+
/**
|
|
11
|
+
* Resolve whether a selected item's chip should be prefixed with the
|
|
12
|
+
* trigger character: the item's own {@link SuggestionItem.showTriggerInChip}
|
|
13
|
+
* wins when set, then the config's
|
|
14
|
+
* {@link TriggerSuggestionConfig.showTriggerInChip}, then the
|
|
15
|
+
* command/mention default.
|
|
16
|
+
*/
|
|
17
|
+
export declare function resolveShowTriggerInChip(item: SuggestionItem, config: Pick<TriggerSuggestionConfig, "showTriggerInChip">, isCommand: boolean): boolean;
|
|
18
|
+
export declare function carbonMention(config: TriggerSuggestionConfig): import("@tiptap/core").Node<import("@tiptap/extension-mention").MentionOptions<any, import("@tiptap/extension-mention").MentionNodeAttrs>, any>;
|
|
19
|
+
export declare function carbonCommand(config: TriggerSuggestionConfig): import("@tiptap/core").Node<import("@tiptap/extension-mention").MentionOptions<any, import("@tiptap/extension-mention").MentionNodeAttrs>, any>;
|
|
@@ -0,0 +1,237 @@
|
|
|
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 Mention from '@tiptap/extension-mention';
|
|
9
|
+
import { PluginKey, Plugin } from '@tiptap/pm/state';
|
|
10
|
+
import { isHostOrigin } from './origin-meta.js';
|
|
11
|
+
import { CarbonTokenNodeView } from './token-node-view.js';
|
|
12
|
+
import { dispatchTriggerChange } from './trigger-utils.js';
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* @license
|
|
16
|
+
*
|
|
17
|
+
* Copyright IBM Corp. 2026
|
|
18
|
+
*
|
|
19
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
|
20
|
+
* LICENSE file in the root directory of this source tree.
|
|
21
|
+
*/
|
|
22
|
+
function buildTriggerExtension(config, build) {
|
|
23
|
+
const name = config.name ?? build.defaultName;
|
|
24
|
+
const pluginKey = new PluginKey(`${build.defaultPluginKeyName}_${name}`);
|
|
25
|
+
return Mention.extend({
|
|
26
|
+
name,
|
|
27
|
+
addAttributes() {
|
|
28
|
+
const parent = (this.parent?.() ?? {});
|
|
29
|
+
return {
|
|
30
|
+
...parent,
|
|
31
|
+
value: { default: null },
|
|
32
|
+
data: { default: null },
|
|
33
|
+
trigger: { default: null },
|
|
34
|
+
};
|
|
35
|
+
},
|
|
36
|
+
addNodeView() {
|
|
37
|
+
return ({ node, editor }) => new CarbonTokenNodeView(node, editor.view, {
|
|
38
|
+
renderCustomToken: config.renderCustomToken,
|
|
39
|
+
});
|
|
40
|
+
},
|
|
41
|
+
addProseMirrorPlugins() {
|
|
42
|
+
const parentPlugins = this.parent?.() ?? [];
|
|
43
|
+
const onRemove = config.onRemove;
|
|
44
|
+
if (!onRemove) {
|
|
45
|
+
return parentPlugins;
|
|
46
|
+
}
|
|
47
|
+
// Fire `onRemove` once per token node of this type that leaves the doc
|
|
48
|
+
// via a USER edit. Mirrors the value-sync extension's origin model:
|
|
49
|
+
// `appendTransaction` records whether the batch was host-origin, and the
|
|
50
|
+
// view's `update` runs the diff (after state is applied, so host
|
|
51
|
+
// callbacks never re-enter `dispatch`). Host-origin batches — the
|
|
52
|
+
// framework's post-send clear and any `getEditor()`/`updateContent`
|
|
53
|
+
// mutation — are skipped, symmetric with `onSelect` firing only on user
|
|
54
|
+
// popup selection.
|
|
55
|
+
let lastBatchIsHost = false;
|
|
56
|
+
const removalPlugin = new Plugin({
|
|
57
|
+
key: new PluginKey(`${name}_removal`),
|
|
58
|
+
appendTransaction(transactions) {
|
|
59
|
+
lastBatchIsHost = transactions.some((tr) => isHostOrigin(tr));
|
|
60
|
+
return null;
|
|
61
|
+
},
|
|
62
|
+
view: () => ({
|
|
63
|
+
update(view, prevState) {
|
|
64
|
+
if (view.state.doc === prevState.doc || lastBatchIsHost) {
|
|
65
|
+
return;
|
|
66
|
+
}
|
|
67
|
+
const removed = diffRemovedTokens(prevState.doc, view.state.doc, name);
|
|
68
|
+
for (const item of removed) {
|
|
69
|
+
onRemove(item);
|
|
70
|
+
}
|
|
71
|
+
},
|
|
72
|
+
}),
|
|
73
|
+
});
|
|
74
|
+
return [...parentPlugins, removalPlugin];
|
|
75
|
+
},
|
|
76
|
+
}).configure({
|
|
77
|
+
HTMLAttributes: { "data-token-type": name },
|
|
78
|
+
suggestion: {
|
|
79
|
+
char: config.trigger,
|
|
80
|
+
pluginKey,
|
|
81
|
+
startOfLine: config.triggerPosition === "start",
|
|
82
|
+
items: ({ query }) => resolveItems(config, query),
|
|
83
|
+
command: ({ editor, range, props }) => {
|
|
84
|
+
const item = props;
|
|
85
|
+
// Insert the mention/command node with our extended attrs.
|
|
86
|
+
editor
|
|
87
|
+
.chain()
|
|
88
|
+
.focus()
|
|
89
|
+
.insertContentAt(range, [
|
|
90
|
+
{
|
|
91
|
+
type: name,
|
|
92
|
+
attrs: {
|
|
93
|
+
id: item.id,
|
|
94
|
+
label: item.label,
|
|
95
|
+
value: item.value ?? item.label,
|
|
96
|
+
// Item overrides config overrides the command/mention
|
|
97
|
+
// default (see resolveShowTriggerInChip).
|
|
98
|
+
trigger: resolveShowTriggerInChip(item, config, build.defaultName === "command")
|
|
99
|
+
? config.trigger
|
|
100
|
+
: null,
|
|
101
|
+
data: stripPresentationFields(item),
|
|
102
|
+
},
|
|
103
|
+
},
|
|
104
|
+
{ type: "text", text: " " },
|
|
105
|
+
])
|
|
106
|
+
.run();
|
|
107
|
+
config.onSelect?.(item);
|
|
108
|
+
},
|
|
109
|
+
render: () => {
|
|
110
|
+
let lastQuery = null;
|
|
111
|
+
return {
|
|
112
|
+
onStart: (props) => emitTrigger(props.editor, name, props.query, props.range, () => {
|
|
113
|
+
lastQuery = props.query;
|
|
114
|
+
}),
|
|
115
|
+
onUpdate: (props) => {
|
|
116
|
+
if (props.query === lastQuery) {
|
|
117
|
+
return;
|
|
118
|
+
}
|
|
119
|
+
lastQuery = props.query;
|
|
120
|
+
emitTrigger(props.editor, name, props.query, props.range);
|
|
121
|
+
},
|
|
122
|
+
onExit: (props) => {
|
|
123
|
+
lastQuery = null;
|
|
124
|
+
dispatchTriggerChange(props.editor, null);
|
|
125
|
+
},
|
|
126
|
+
onKeyDown: () => false,
|
|
127
|
+
};
|
|
128
|
+
},
|
|
129
|
+
},
|
|
130
|
+
});
|
|
131
|
+
}
|
|
132
|
+
function emitTrigger(editor, type, query, range, postEmit) {
|
|
133
|
+
dispatchTriggerChange(editor, {
|
|
134
|
+
type,
|
|
135
|
+
query,
|
|
136
|
+
triggerOffset: range.from,
|
|
137
|
+
});
|
|
138
|
+
postEmit?.();
|
|
139
|
+
}
|
|
140
|
+
/**
|
|
141
|
+
* Collect the attrs of every node named `name` in `doc`, grouped by id and
|
|
142
|
+
* kept in document order, so a multiset diff can tell which specific node
|
|
143
|
+
* instances were removed (duplicate chips with the same id are tracked by
|
|
144
|
+
* count, not collapsed).
|
|
145
|
+
*/
|
|
146
|
+
function collectTokenAttrsById(doc, name) {
|
|
147
|
+
const byId = new Map();
|
|
148
|
+
doc.descendants((node) => {
|
|
149
|
+
if (node.type.name !== name) {
|
|
150
|
+
return;
|
|
151
|
+
}
|
|
152
|
+
const attrs = node.attrs;
|
|
153
|
+
const id = String(attrs.id);
|
|
154
|
+
const bucket = byId.get(id);
|
|
155
|
+
if (bucket) {
|
|
156
|
+
bucket.push(attrs);
|
|
157
|
+
}
|
|
158
|
+
else {
|
|
159
|
+
byId.set(id, [attrs]);
|
|
160
|
+
}
|
|
161
|
+
});
|
|
162
|
+
return byId;
|
|
163
|
+
}
|
|
164
|
+
/**
|
|
165
|
+
* Reconstruct a {@link SuggestionItem} from a removed token node's attrs.
|
|
166
|
+
* Presentation-only fields were stripped at insert time, so only `id`,
|
|
167
|
+
* `label`, `value`, and any custom fields stashed in `data` survive.
|
|
168
|
+
*/
|
|
169
|
+
function attrsToItem(attrs) {
|
|
170
|
+
const data = (attrs.data ?? {});
|
|
171
|
+
return {
|
|
172
|
+
...data,
|
|
173
|
+
id: String(attrs.id),
|
|
174
|
+
label: attrs.label,
|
|
175
|
+
value: (attrs.value ?? undefined),
|
|
176
|
+
};
|
|
177
|
+
}
|
|
178
|
+
/**
|
|
179
|
+
* Diff token nodes named `name` between `before` and `after`, returning the
|
|
180
|
+
* reconstructed items for each removed node instance (one entry per removed
|
|
181
|
+
* duplicate).
|
|
182
|
+
*/
|
|
183
|
+
function diffRemovedTokens(before, after, name) {
|
|
184
|
+
const beforeById = collectTokenAttrsById(before, name);
|
|
185
|
+
const afterById = collectTokenAttrsById(after, name);
|
|
186
|
+
const removed = [];
|
|
187
|
+
for (const [id, beforeAttrs] of beforeById) {
|
|
188
|
+
const afterCount = afterById.get(id)?.length ?? 0;
|
|
189
|
+
for (let i = afterCount; i < beforeAttrs.length; i += 1) {
|
|
190
|
+
removed.push(attrsToItem(beforeAttrs[i]));
|
|
191
|
+
}
|
|
192
|
+
}
|
|
193
|
+
return removed;
|
|
194
|
+
}
|
|
195
|
+
async function resolveItems(config, query) {
|
|
196
|
+
const minQueryLength = config.minQueryLength ?? 0;
|
|
197
|
+
if (query.length < minQueryLength) {
|
|
198
|
+
return [];
|
|
199
|
+
}
|
|
200
|
+
if (typeof config.items === "function") {
|
|
201
|
+
return Promise.resolve(config.items(query));
|
|
202
|
+
}
|
|
203
|
+
if (!query) {
|
|
204
|
+
return config.items;
|
|
205
|
+
}
|
|
206
|
+
const lower = query.toLowerCase();
|
|
207
|
+
return config.items.filter((item) => item.label.toLowerCase().includes(lower));
|
|
208
|
+
}
|
|
209
|
+
/**
|
|
210
|
+
* Resolve whether a selected item's chip should be prefixed with the
|
|
211
|
+
* trigger character: the item's own {@link SuggestionItem.showTriggerInChip}
|
|
212
|
+
* wins when set, then the config's
|
|
213
|
+
* {@link TriggerSuggestionConfig.showTriggerInChip}, then the
|
|
214
|
+
* command/mention default.
|
|
215
|
+
*/
|
|
216
|
+
function resolveShowTriggerInChip(item, config, isCommand) {
|
|
217
|
+
return item.showTriggerInChip ?? config.showTriggerInChip ?? isCommand;
|
|
218
|
+
}
|
|
219
|
+
function stripPresentationFields(item) {
|
|
220
|
+
const { id: _id, label: _label, value: _value, avatar: _avatar, description: _description, disabled: _disabled, showTriggerInChip: _showTriggerInChip, ...rest } = item;
|
|
221
|
+
return rest;
|
|
222
|
+
}
|
|
223
|
+
function carbonMention(config) {
|
|
224
|
+
return buildTriggerExtension(config, {
|
|
225
|
+
defaultName: "mention",
|
|
226
|
+
defaultPluginKeyName: "carbonMentionSuggestion",
|
|
227
|
+
});
|
|
228
|
+
}
|
|
229
|
+
function carbonCommand(config) {
|
|
230
|
+
return buildTriggerExtension(config, {
|
|
231
|
+
defaultName: "command",
|
|
232
|
+
defaultPluginKeyName: "carbonCommandSuggestion",
|
|
233
|
+
});
|
|
234
|
+
}
|
|
235
|
+
|
|
236
|
+
export { carbonCommand, carbonMention, resolveShowTriggerInChip };
|
|
237
|
+
//# sourceMappingURL=carbon-mention.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"carbon-mention.js","sources":["../../../../../src/components/prompt-line/src/tiptap/carbon-mention.ts"],"sourcesContent":[null],"names":[],"mappings":";;;;;;;;;;;;;AAAA;;;;;;;AAOG;AA2CH,SAAS,qBAAqB,CAC5B,MAA+B,EAC/B,KAAmB,EAAA;IAEnB,MAAM,IAAI,GAAG,MAAM,CAAC,IAAI,IAAI,KAAK,CAAC,WAAW;AAC7C,IAAA,MAAM,SAAS,GAAG,IAAI,SAAS,CAAC,CAAA,EAAG,KAAK,CAAC,oBAAoB,CAAA,CAAA,EAAI,IAAI,CAAA,CAAE,CAAC;IAExE,OAAO,OAAO,CAAC,MAAM,CAAC;QACpB,IAAI;QAEJ,aAAa,GAAA;YACX,MAAM,MAAM,IAAI,IA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