@carbon/ai-chat-components 1.9.0 → 1.10.0-rc.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 +2362 -2201
- package/es/components/audio-player/src/audio-player.js.map +1 -1
- package/es/components/audio-player/src/audio-player.scss.js.map +1 -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.map +1 -1
- package/es/components/audio-player/src/providers/soundcloud-provider.js.map +1 -1
- package/es/components/audio-player/src/transcript.js.map +1 -1
- package/es/components/audio-player/src/transcript.scss.js.map +1 -1
- package/es/components/audio-player/src/utils/url-detector.js.map +1 -1
- package/es/components/card/src/card-footer.js.map +1 -1
- package/es/components/card/src/card-footer.scss.js.map +1 -1
- package/es/components/card/src/card-steps.js.map +1 -1
- package/es/components/card/src/card-steps.scss.js.map +1 -1
- package/es/components/card/src/card.js.map +1 -1
- package/es/components/card/src/card.scss.js.map +1 -1
- package/es/components/carousel/src/carousel.js.map +1 -1
- package/es/components/carousel/src/carousel.scss.js.map +1 -1
- package/es/components/chain-of-thought/defs.js.map +1 -1
- package/es/components/chain-of-thought/src/chain-of-thought-step.js.map +1 -1
- package/es/components/chain-of-thought/src/chain-of-thought-step.scss.js.map +1 -1
- package/es/components/chain-of-thought/src/chain-of-thought-toggle.js.map +1 -1
- package/es/components/chain-of-thought/src/chain-of-thought-toggle.scss.js.map +1 -1
- package/es/components/chain-of-thought/src/chain-of-thought.js.map +1 -1
- package/es/components/chain-of-thought/src/chain-of-thought.scss.js.map +1 -1
- package/es/components/chain-of-thought/src/tool-call-data.js.map +1 -1
- package/es/components/chain-of-thought/src/tool-call-data.scss.js.map +1 -1
- package/es/components/chat-button/defs.js.map +1 -1
- package/es/components/chat-button/index.d.ts +1 -0
- package/es/components/chat-button/index.js +1 -0
- package/es/components/chat-button/index.js.map +1 -1
- package/es/components/chat-button/src/chat-button-skeleton.d.ts +30 -0
- package/es/components/chat-button/src/chat-button-skeleton.js +41 -0
- package/es/components/chat-button/src/chat-button-skeleton.js.map +1 -0
- package/es/components/chat-button/src/chat-button.d.ts +4 -1
- package/es/components/chat-button/src/chat-button.js +30 -2
- 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-button/src/chat-button.scss.js.map +1 -1
- package/es/components/chat-history/src/chat-history.scss.js +1 -1
- package/es/components/chat-history/src/chat-history.scss.js.map +1 -1
- package/es/components/chat-history/src/history-content.js.map +1 -1
- package/es/components/chat-history/src/history-delete-panel.js +1 -0
- package/es/components/chat-history/src/history-delete-panel.js.map +1 -1
- package/es/components/chat-history/src/history-header.js.map +1 -1
- package/es/components/chat-history/src/history-loading.js.map +1 -1
- package/es/components/chat-history/src/history-panel-item-input.js.map +1 -1
- package/es/components/chat-history/src/history-panel-item.js.map +1 -1
- package/es/components/chat-history/src/history-panel-items.js.map +1 -1
- package/es/components/chat-history/src/history-panel-menu.js.map +1 -1
- package/es/components/chat-history/src/history-panel.js.map +1 -1
- package/es/components/chat-history/src/history-search-item.js.map +1 -1
- package/es/components/chat-history/src/history-shell.js.map +1 -1
- package/es/components/chat-history/src/history-toolbar.js.map +1 -1
- package/es/components/chat-shell/src/chat-header.js.map +1 -1
- package/es/components/chat-shell/src/chat-header.scss.js.map +1 -1
- package/es/components/chat-shell/src/corner-manager.js.map +1 -1
- package/es/components/chat-shell/src/initialization-manager.js.map +1 -1
- package/es/components/chat-shell/src/panel-manager.js.map +1 -1
- package/es/components/chat-shell/src/panel.js.map +1 -1
- package/es/components/chat-shell/src/panel.scss.js.map +1 -1
- package/es/components/chat-shell/src/resize-observer-manager.js.map +1 -1
- package/es/components/chat-shell/src/shell.js.map +1 -1
- package/es/components/chat-shell/src/shell.scss.js.map +1 -1
- package/es/components/chat-shell/src/slot-observer.js.map +1 -1
- package/es/components/chat-shell/src/workspace-manager-utils.js.map +1 -1
- package/es/components/chat-shell/src/workspace-manager.js.map +1 -1
- package/es/components/code-snippet/src/code-snippet.js.map +1 -1
- package/es/components/code-snippet/src/code-snippet.scss.js.map +1 -1
- package/es/components/code-snippet/src/codemirror/base-setup.js.map +1 -1
- package/es/components/code-snippet/src/codemirror/codemirror-loader.js.map +1 -1
- package/es/components/code-snippet/src/codemirror/content-sync.js.map +1 -1
- package/es/components/code-snippet/src/codemirror/detect-language.js.map +1 -1
- package/es/components/code-snippet/src/codemirror/diff-decorator.js.map +1 -1
- package/es/components/code-snippet/src/codemirror/editor-manager.js.map +1 -1
- package/es/components/code-snippet/src/codemirror/language-controller.js.map +1 -1
- package/es/components/code-snippet/src/codemirror/language-data.js.map +1 -1
- package/es/components/code-snippet/src/codemirror/language-utils.js.map +1 -1
- package/es/components/code-snippet/src/codemirror/marker-utils.js.map +1 -1
- package/es/components/code-snippet/src/codemirror/theme.js.map +1 -1
- package/es/components/code-snippet/src/dom-utils.js.map +1 -1
- package/es/components/code-snippet/src/formatters.js.map +1 -1
- package/es/components/code-snippet/src/layout-utils.js.map +1 -1
- package/es/components/code-snippet/src/streaming-manager.js.map +1 -1
- package/es/components/feedback/src/feedback-buttons.js.map +1 -1
- package/es/components/feedback/src/feedback-buttons.scss.js.map +1 -1
- package/es/components/feedback/src/feedback.js.map +1 -1
- package/es/components/feedback/src/feedback.scss.js.map +1 -1
- package/es/components/file-uploads/src/file-type-icon.js.map +1 -1
- package/es/components/file-uploads/src/file-upload-item.js.map +1 -1
- package/es/components/file-uploads/src/file-upload-item.scss.js.map +1 -1
- package/es/components/file-uploads/src/file-uploads.js.map +1 -1
- package/es/components/file-uploads/src/file-uploads.scss.js.map +1 -1
- package/es/components/launcher/src/launcher.js +1 -0
- package/es/components/launcher/src/launcher.js.map +1 -1
- package/es/components/launcher/src/launcher.scss.js +1 -1
- package/es/components/launcher/src/launcher.scss.js.map +1 -1
- package/es/components/markdown/src/markdown-renderer-types.d.ts +3 -14
- package/es/components/markdown/src/markdown-renderer.js +0 -4
- package/es/components/markdown/src/markdown-renderer.js.map +1 -1
- package/es/components/markdown/src/markdown-token-tree.d.ts +0 -2
- package/es/components/markdown/src/markdown-token-tree.js.map +1 -1
- package/es/components/markdown/src/markdown.js +0 -1
- package/es/components/markdown/src/markdown.js.map +1 -1
- package/es/components/markdown/src/markdown.scss.js.map +1 -1
- package/es/components/markdown/src/markdown.template.js.map +1 -1
- package/es/components/markdown/src/plugins/markdown-it-attrs.js +2 -3
- package/es/components/markdown/src/plugins/markdown-it-attrs.js.map +1 -1
- package/es/components/markdown/src/plugins/markdown-it-highlight.js.map +1 -1
- package/es/components/markdown/src/plugins/markdown-it-task-lists.js.map +1 -1
- package/es/components/markdown/src/utils/html-helpers.js.map +1 -1
- package/es/components/markdown/src/utils/lit-directives.js.map +1 -1
- package/es/components/markdown/src/utils/plugin-fallback.js +0 -1
- package/es/components/markdown/src/utils/plugin-fallback.js.map +1 -1
- package/es/components/markdown/src/utils/slot-names.js.map +1 -1
- package/es/components/markdown/src/utils/streaming-table.js.map +1 -1
- package/es/components/markdown/src/utils/table-helpers.js +0 -1
- package/es/components/markdown/src/utils/table-helpers.js.map +1 -1
- package/es/components/processing/src/processing.js.map +1 -1
- package/es/components/processing/src/processing.scss.js.map +1 -1
- package/es/components/prompt-line/autocomplete/src/autocomplete.d.ts +10 -3
- package/es/components/prompt-line/autocomplete/src/autocomplete.js +95 -48
- package/es/components/prompt-line/autocomplete/src/autocomplete.js.map +1 -1
- package/es/components/prompt-line/autocomplete/src/autocomplete.scss.js +1 -1
- package/es/components/prompt-line/autocomplete/src/autocomplete.scss.js.map +1 -1
- package/es/components/prompt-line/index.d.ts +1 -1
- package/es/components/prompt-line/src/autocomplete-controller.d.ts +12 -1
- package/es/components/prompt-line/src/autocomplete-controller.js +42 -6
- package/es/components/prompt-line/src/autocomplete-controller.js.map +1 -1
- package/es/components/prompt-line/src/error-message.js.map +1 -1
- package/es/components/prompt-line/src/error-message.scss.js.map +1 -1
- package/es/components/prompt-line/src/prompt-line-constants.js.map +1 -1
- package/es/components/prompt-line/src/prompt-line-controller.js.map +1 -1
- package/es/components/prompt-line/src/prompt-line-rich-loader.js.map +1 -1
- package/es/components/prompt-line/src/prompt-line-rich-runtime.js.map +1 -1
- package/es/components/prompt-line/src/prompt-line-shell.js.map +1 -1
- package/es/components/prompt-line/src/prompt-line-shell.scss.js +1 -1
- package/es/components/prompt-line/src/prompt-line-shell.scss.js.map +1 -1
- package/es/components/prompt-line/src/prompt-line.js.map +1 -1
- package/es/components/prompt-line/src/prompt-line.scss.js.map +1 -1
- package/es/components/prompt-line/src/send-control.js.map +1 -1
- package/es/components/prompt-line/src/send-control.scss.js.map +1 -1
- package/es/components/prompt-line/src/stop-streaming-button.js.map +1 -1
- package/es/components/prompt-line/src/stop-streaming-button.scss.js.map +1 -1
- package/es/components/prompt-line/src/tiptap/build-extensions.js.map +1 -1
- package/es/components/prompt-line/src/tiptap/carbon-autocomplete.js.map +1 -1
- package/es/components/prompt-line/src/tiptap/carbon-mention.js +1 -0
- package/es/components/prompt-line/src/tiptap/carbon-mention.js.map +1 -1
- package/es/components/prompt-line/src/tiptap/carbon-starter-trigger.js +2 -3
- package/es/components/prompt-line/src/tiptap/carbon-starter-trigger.js.map +1 -1
- package/es/components/prompt-line/src/tiptap/chat-enter.js.map +1 -1
- package/es/components/prompt-line/src/tiptap/editor-styles.js.map +1 -1
- package/es/components/prompt-line/src/tiptap/extension-equivalence.js.map +1 -1
- package/es/components/prompt-line/src/tiptap/index.d.ts +1 -1
- package/es/components/prompt-line/src/tiptap/json-utils.js.map +1 -1
- package/es/components/prompt-line/src/tiptap/keymap.js.map +1 -1
- package/es/components/prompt-line/src/tiptap/origin-meta.js.map +1 -1
- package/es/components/prompt-line/src/tiptap/plain-text-paste.js.map +1 -1
- package/es/components/prompt-line/src/tiptap/render-in-light-dom.js.map +1 -1
- package/es/components/prompt-line/src/tiptap/render-token-chip.js.map +1 -1
- package/es/components/prompt-line/src/tiptap/token-node-view.js.map +1 -1
- package/es/components/prompt-line/src/tiptap/trigger-utils.js.map +1 -1
- package/es/components/prompt-line/src/tiptap/types.d.ts +16 -3
- package/es/components/prompt-line/src/tiptap/typing-indicator.js.map +1 -1
- package/es/components/prompt-line/src/tiptap/value-sync.js.map +1 -1
- package/es/components/prompt-line/src/types.js.map +1 -1
- package/es/components/reasoning-steps/src/reasoning-step.js.map +1 -1
- package/es/components/reasoning-steps/src/reasoning-step.scss.js +1 -1
- package/es/components/reasoning-steps/src/reasoning-step.scss.js.map +1 -1
- package/es/components/reasoning-steps/src/reasoning-steps-toggle.js.map +1 -1
- package/es/components/reasoning-steps/src/reasoning-steps-toggle.scss.js.map +1 -1
- package/es/components/reasoning-steps/src/reasoning-steps.js.map +1 -1
- package/es/components/reasoning-steps/src/reasoning-steps.scss.js +1 -1
- package/es/components/reasoning-steps/src/reasoning-steps.scss.js.map +1 -1
- package/es/components/shared/dynamic-css-var-sheet.js +24 -2
- package/es/components/shared/dynamic-css-var-sheet.js.map +1 -1
- package/es/components/shared/media-utils/script-loader.js.map +1 -1
- package/es/components/table/src/table-loader.js.map +1 -1
- package/es/components/table/src/table-pagination.template.js.map +1 -1
- package/es/components/table/src/table-skeleton.template.js.map +1 -1
- package/es/components/table/src/table.js.map +1 -1
- package/es/components/table/src/table.scss.js.map +1 -1
- package/es/components/table/src/table.template.js.map +1 -1
- package/es/components/toolbar/src/toolbar.js.map +1 -1
- package/es/components/toolbar/src/toolbar.scss.js +1 -1
- package/es/components/toolbar/src/toolbar.scss.js.map +1 -1
- package/es/components/truncated-text/src/truncated-text.js.map +1 -1
- package/es/components/truncated-text/src/truncated-text.scss.js.map +1 -1
- package/es/components/video-player/src/providers/base-provider.js.map +1 -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.map +1 -1
- package/es/components/video-player/src/providers/vimeo-provider.js.map +1 -1
- package/es/components/video-player/src/providers/youtube-provider.js.map +1 -1
- package/es/components/video-player/src/utils/url-detector.js.map +1 -1
- package/es/components/video-player/src/video-player.js.map +1 -1
- package/es/components/video-player/src/video-player.scss.js.map +1 -1
- package/es/components/workspace-shell/src/header-collapsible-manager.js.map +1 -1
- package/es/components/workspace-shell/src/workspace-shell-body.js.map +1 -1
- package/es/components/workspace-shell/src/workspace-shell-footer.js.map +1 -1
- package/es/components/workspace-shell/src/workspace-shell-footer.scss.js.map +1 -1
- package/es/components/workspace-shell/src/workspace-shell-header.js +2 -1
- package/es/components/workspace-shell/src/workspace-shell-header.js.map +1 -1
- package/es/components/workspace-shell/src/workspace-shell-header.scss.js +1 -1
- package/es/components/workspace-shell/src/workspace-shell-header.scss.js.map +1 -1
- package/es/components/workspace-shell/src/workspace-shell.js.map +1 -1
- package/es/components/workspace-shell/src/workspace-shell.scss.js +1 -1
- package/es/components/workspace-shell/src/workspace-shell.scss.js.map +1 -1
- package/es/globals/decorators/carbon-element.js.map +1 -1
- package/es/globals/scss/common.scss.js.map +1 -1
- package/es/globals/settings.js.map +1 -1
- package/es/globals/utils/aria-announcer-manager.js.map +1 -1
- package/es/globals/utils/browser-utils.js.map +1 -1
- package/es/globals/utils/csv.js.map +1 -1
- package/es/globals/utils/dom-utils.js.map +1 -1
- package/es/globals/utils/focus-utils.js.map +1 -1
- package/es/globals/utils/iconTransform.js.map +1 -1
- package/es/globals/utils/rtl-utils.js.map +1 -1
- package/es/globals/utils/uuid.js.map +1 -1
- package/es/react/ai-label-action-button.js.map +1 -1
- package/es/react/audio-player.js.map +1 -1
- package/es/react/autocomplete.js.map +1 -1
- package/es/react/card.js.map +1 -1
- package/es/react/carousel.js.map +1 -1
- package/es/react/chain-of-thought-step.js.map +1 -1
- package/es/react/chain-of-thought-toggle.js.map +1 -1
- package/es/react/chain-of-thought.js.map +1 -1
- package/es/react/chat-button-skeleton.d.ts +11 -0
- package/es/react/chat-button-skeleton.js +28 -0
- package/es/react/chat-button-skeleton.js.map +1 -0
- package/es/react/chat-button.js.map +1 -1
- package/es/react/chat-header.js.map +1 -1
- package/es/react/chat-shell.js.map +1 -1
- package/es/react/code-snippet.d.ts +1 -1
- package/es/react/code-snippet.js +1 -1
- package/es/react/code-snippet.js.map +1 -1
- package/es/react/error-message.js.map +1 -1
- package/es/react/feedback-buttons.js.map +1 -1
- package/es/react/feedback.js.map +1 -1
- package/es/react/file-upload-item.js.map +1 -1
- package/es/react/file-uploads.js.map +1 -1
- package/es/react/history/history-content.js.map +1 -1
- package/es/react/history/history-delete-panel.js.map +1 -1
- package/es/react/history/history-header.js.map +1 -1
- package/es/react/history/history-loading.js.map +1 -1
- package/es/react/history/history-panel-item-input.js.map +1 -1
- package/es/react/history/history-panel-item.js.map +1 -1
- package/es/react/history/history-panel-items.js.map +1 -1
- package/es/react/history/history-panel-menu.js.map +1 -1
- package/es/react/history/history-panel.js.map +1 -1
- package/es/react/history/history-search-item.js.map +1 -1
- package/es/react/history/history-shell.js.map +1 -1
- package/es/react/history/history-toolbar.js.map +1 -1
- package/es/react/hooks/useChatAutocomplete.js +4 -3
- package/es/react/hooks/useChatAutocomplete.js.map +1 -1
- package/es/react/input-send-control.js.map +1 -1
- package/es/react/launcher.js.map +1 -1
- package/es/react/markdown.js.map +1 -1
- package/es/react/panel.js.map +1 -1
- package/es/react/processing.js.map +1 -1
- package/es/react/prompt-line-shell.js.map +1 -1
- package/es/react/prompt-line.js.map +1 -1
- package/es/react/reasoning-step.js.map +1 -1
- package/es/react/reasoning-steps-toggle.js.map +1 -1
- package/es/react/reasoning-steps.js.map +1 -1
- package/es/react/stop-streaming-button.js.map +1 -1
- package/es/react/table.js.map +1 -1
- package/es/react/tool-call-data.js.map +1 -1
- package/es/react/toolbar.js +1 -1
- package/es/react/toolbar.js.map +1 -1
- package/es/react/transcript.js.map +1 -1
- package/es/react/utils/transformSuggestionConfig.js.map +1 -1
- package/es/react/utils/withWebComponentBridge.js.map +1 -1
- package/es/react/video-player.js.map +1 -1
- package/es/react/workspace-shell.js.map +1 -1
- package/es/testing/PageObjectId.js.map +1 -1
- package/es/testing/load-all-lazy-deps.js.map +1 -1
- package/es-custom/components/audio-player/src/audio-player.js.map +1 -1
- package/es-custom/components/audio-player/src/audio-player.scss.js.map +1 -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.map +1 -1
- package/es-custom/components/audio-player/src/providers/soundcloud-provider.js.map +1 -1
- package/es-custom/components/audio-player/src/transcript.js.map +1 -1
- package/es-custom/components/audio-player/src/transcript.scss.js.map +1 -1
- package/es-custom/components/audio-player/src/utils/url-detector.js.map +1 -1
- package/es-custom/components/card/src/card-footer.js.map +1 -1
- package/es-custom/components/card/src/card-footer.scss.js.map +1 -1
- package/es-custom/components/card/src/card-steps.js.map +1 -1
- package/es-custom/components/card/src/card-steps.scss.js.map +1 -1
- package/es-custom/components/card/src/card.js.map +1 -1
- package/es-custom/components/card/src/card.scss.js.map +1 -1
- package/es-custom/components/carousel/src/carousel.js.map +1 -1
- package/es-custom/components/carousel/src/carousel.scss.js.map +1 -1
- package/es-custom/components/chain-of-thought/defs.js.map +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/chain-of-thought-step.scss.js.map +1 -1
- package/es-custom/components/chain-of-thought/src/chain-of-thought-toggle.js.map +1 -1
- package/es-custom/components/chain-of-thought/src/chain-of-thought-toggle.scss.js.map +1 -1
- package/es-custom/components/chain-of-thought/src/chain-of-thought.js.map +1 -1
- package/es-custom/components/chain-of-thought/src/chain-of-thought.scss.js.map +1 -1
- package/es-custom/components/chain-of-thought/src/tool-call-data.js.map +1 -1
- package/es-custom/components/chain-of-thought/src/tool-call-data.scss.js.map +1 -1
- package/es-custom/components/chat-button/defs.js.map +1 -1
- package/es-custom/components/chat-button/index.d.ts +1 -0
- package/es-custom/components/chat-button/index.js +1 -0
- package/es-custom/components/chat-button/index.js.map +1 -1
- package/es-custom/components/chat-button/src/chat-button-skeleton.d.ts +30 -0
- package/es-custom/components/chat-button/src/chat-button-skeleton.js +41 -0
- package/es-custom/components/chat-button/src/chat-button-skeleton.js.map +1 -0
- package/es-custom/components/chat-button/src/chat-button.d.ts +4 -1
- package/es-custom/components/chat-button/src/chat-button.js +30 -2
- 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-button/src/chat-button.scss.js.map +1 -1
- package/es-custom/components/chat-history/src/chat-history.scss.js +1 -1
- package/es-custom/components/chat-history/src/chat-history.scss.js.map +1 -1
- package/es-custom/components/chat-history/src/history-content.js.map +1 -1
- package/es-custom/components/chat-history/src/history-delete-panel.js +1 -0
- package/es-custom/components/chat-history/src/history-delete-panel.js.map +1 -1
- package/es-custom/components/chat-history/src/history-header.js.map +1 -1
- package/es-custom/components/chat-history/src/history-loading.js.map +1 -1
- 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.js.map +1 -1
- package/es-custom/components/chat-history/src/history-panel-items.js.map +1 -1
- package/es-custom/components/chat-history/src/history-panel-menu.js.map +1 -1
- package/es-custom/components/chat-history/src/history-panel.js.map +1 -1
- package/es-custom/components/chat-history/src/history-search-item.js.map +1 -1
- package/es-custom/components/chat-history/src/history-shell.js.map +1 -1
- package/es-custom/components/chat-history/src/history-toolbar.js.map +1 -1
- package/es-custom/components/chat-shell/src/chat-header.js.map +1 -1
- package/es-custom/components/chat-shell/src/chat-header.scss.js.map +1 -1
- package/es-custom/components/chat-shell/src/corner-manager.js.map +1 -1
- package/es-custom/components/chat-shell/src/initialization-manager.js.map +1 -1
- package/es-custom/components/chat-shell/src/panel-manager.js.map +1 -1
- package/es-custom/components/chat-shell/src/panel.js.map +1 -1
- package/es-custom/components/chat-shell/src/panel.scss.js.map +1 -1
- package/es-custom/components/chat-shell/src/resize-observer-manager.js.map +1 -1
- package/es-custom/components/chat-shell/src/shell.js.map +1 -1
- package/es-custom/components/chat-shell/src/shell.scss.js.map +1 -1
- package/es-custom/components/chat-shell/src/slot-observer.js.map +1 -1
- package/es-custom/components/chat-shell/src/workspace-manager-utils.js.map +1 -1
- package/es-custom/components/chat-shell/src/workspace-manager.js.map +1 -1
- package/es-custom/components/code-snippet/src/code-snippet.js.map +1 -1
- package/es-custom/components/code-snippet/src/code-snippet.scss.js.map +1 -1
- package/es-custom/components/code-snippet/src/codemirror/base-setup.js.map +1 -1
- package/es-custom/components/code-snippet/src/codemirror/codemirror-loader.js.map +1 -1
- package/es-custom/components/code-snippet/src/codemirror/content-sync.js.map +1 -1
- package/es-custom/components/code-snippet/src/codemirror/detect-language.js.map +1 -1
- package/es-custom/components/code-snippet/src/codemirror/diff-decorator.js.map +1 -1
- package/es-custom/components/code-snippet/src/codemirror/editor-manager.js.map +1 -1
- package/es-custom/components/code-snippet/src/codemirror/language-controller.js.map +1 -1
- package/es-custom/components/code-snippet/src/codemirror/language-data.js.map +1 -1
- package/es-custom/components/code-snippet/src/codemirror/language-utils.js.map +1 -1
- package/es-custom/components/code-snippet/src/codemirror/marker-utils.js.map +1 -1
- package/es-custom/components/code-snippet/src/codemirror/theme.js.map +1 -1
- package/es-custom/components/code-snippet/src/dom-utils.js.map +1 -1
- package/es-custom/components/code-snippet/src/formatters.js.map +1 -1
- package/es-custom/components/code-snippet/src/layout-utils.js.map +1 -1
- package/es-custom/components/code-snippet/src/streaming-manager.js.map +1 -1
- package/es-custom/components/feedback/src/feedback-buttons.js.map +1 -1
- package/es-custom/components/feedback/src/feedback-buttons.scss.js.map +1 -1
- package/es-custom/components/feedback/src/feedback.js.map +1 -1
- package/es-custom/components/feedback/src/feedback.scss.js.map +1 -1
- package/es-custom/components/file-uploads/src/file-type-icon.js.map +1 -1
- package/es-custom/components/file-uploads/src/file-upload-item.js.map +1 -1
- package/es-custom/components/file-uploads/src/file-upload-item.scss.js.map +1 -1
- package/es-custom/components/file-uploads/src/file-uploads.js.map +1 -1
- package/es-custom/components/file-uploads/src/file-uploads.scss.js.map +1 -1
- package/es-custom/components/launcher/src/launcher.js +1 -0
- package/es-custom/components/launcher/src/launcher.js.map +1 -1
- package/es-custom/components/launcher/src/launcher.scss.js +1 -1
- package/es-custom/components/launcher/src/launcher.scss.js.map +1 -1
- package/es-custom/components/markdown/src/markdown-renderer-types.d.ts +3 -14
- package/es-custom/components/markdown/src/markdown-renderer.js +0 -4
- package/es-custom/components/markdown/src/markdown-renderer.js.map +1 -1
- package/es-custom/components/markdown/src/markdown-token-tree.d.ts +0 -2
- package/es-custom/components/markdown/src/markdown-token-tree.js.map +1 -1
- package/es-custom/components/markdown/src/markdown.js +0 -1
- package/es-custom/components/markdown/src/markdown.js.map +1 -1
- package/es-custom/components/markdown/src/markdown.scss.js.map +1 -1
- package/es-custom/components/markdown/src/markdown.template.js.map +1 -1
- package/es-custom/components/markdown/src/plugins/markdown-it-attrs.js +2 -3
- package/es-custom/components/markdown/src/plugins/markdown-it-attrs.js.map +1 -1
- package/es-custom/components/markdown/src/plugins/markdown-it-highlight.js.map +1 -1
- package/es-custom/components/markdown/src/plugins/markdown-it-task-lists.js.map +1 -1
- package/es-custom/components/markdown/src/utils/html-helpers.js.map +1 -1
- package/es-custom/components/markdown/src/utils/lit-directives.js.map +1 -1
- package/es-custom/components/markdown/src/utils/plugin-fallback.js +0 -1
- package/es-custom/components/markdown/src/utils/plugin-fallback.js.map +1 -1
- package/es-custom/components/markdown/src/utils/slot-names.js.map +1 -1
- package/es-custom/components/markdown/src/utils/streaming-table.js.map +1 -1
- package/es-custom/components/markdown/src/utils/table-helpers.js +0 -1
- package/es-custom/components/markdown/src/utils/table-helpers.js.map +1 -1
- package/es-custom/components/processing/src/processing.js.map +1 -1
- package/es-custom/components/processing/src/processing.scss.js.map +1 -1
- package/es-custom/components/prompt-line/autocomplete/src/autocomplete.d.ts +10 -3
- package/es-custom/components/prompt-line/autocomplete/src/autocomplete.js +95 -48
- package/es-custom/components/prompt-line/autocomplete/src/autocomplete.js.map +1 -1
- package/es-custom/components/prompt-line/autocomplete/src/autocomplete.scss.js +1 -1
- package/es-custom/components/prompt-line/autocomplete/src/autocomplete.scss.js.map +1 -1
- package/es-custom/components/prompt-line/index.d.ts +1 -1
- package/es-custom/components/prompt-line/src/autocomplete-controller.d.ts +12 -1
- package/es-custom/components/prompt-line/src/autocomplete-controller.js +42 -6
- package/es-custom/components/prompt-line/src/autocomplete-controller.js.map +1 -1
- package/es-custom/components/prompt-line/src/error-message.js.map +1 -1
- package/es-custom/components/prompt-line/src/error-message.scss.js.map +1 -1
- package/es-custom/components/prompt-line/src/prompt-line-constants.js.map +1 -1
- package/es-custom/components/prompt-line/src/prompt-line-controller.js.map +1 -1
- package/es-custom/components/prompt-line/src/prompt-line-rich-loader.js.map +1 -1
- package/es-custom/components/prompt-line/src/prompt-line-rich-runtime.js.map +1 -1
- package/es-custom/components/prompt-line/src/prompt-line-shell.js.map +1 -1
- package/es-custom/components/prompt-line/src/prompt-line-shell.scss.js +1 -1
- package/es-custom/components/prompt-line/src/prompt-line-shell.scss.js.map +1 -1
- package/es-custom/components/prompt-line/src/prompt-line.js.map +1 -1
- package/es-custom/components/prompt-line/src/prompt-line.scss.js.map +1 -1
- package/es-custom/components/prompt-line/src/send-control.js.map +1 -1
- package/es-custom/components/prompt-line/src/send-control.scss.js.map +1 -1
- package/es-custom/components/prompt-line/src/stop-streaming-button.js.map +1 -1
- package/es-custom/components/prompt-line/src/stop-streaming-button.scss.js.map +1 -1
- package/es-custom/components/prompt-line/src/tiptap/build-extensions.js.map +1 -1
- package/es-custom/components/prompt-line/src/tiptap/carbon-autocomplete.js.map +1 -1
- package/es-custom/components/prompt-line/src/tiptap/carbon-mention.js +1 -0
- package/es-custom/components/prompt-line/src/tiptap/carbon-mention.js.map +1 -1
- package/es-custom/components/prompt-line/src/tiptap/carbon-starter-trigger.js +2 -3
- package/es-custom/components/prompt-line/src/tiptap/carbon-starter-trigger.js.map +1 -1
- package/es-custom/components/prompt-line/src/tiptap/chat-enter.js.map +1 -1
- package/es-custom/components/prompt-line/src/tiptap/editor-styles.js.map +1 -1
- package/es-custom/components/prompt-line/src/tiptap/extension-equivalence.js.map +1 -1
- package/es-custom/components/prompt-line/src/tiptap/index.d.ts +1 -1
- package/es-custom/components/prompt-line/src/tiptap/json-utils.js.map +1 -1
- package/es-custom/components/prompt-line/src/tiptap/keymap.js.map +1 -1
- package/es-custom/components/prompt-line/src/tiptap/origin-meta.js.map +1 -1
- package/es-custom/components/prompt-line/src/tiptap/plain-text-paste.js.map +1 -1
- package/es-custom/components/prompt-line/src/tiptap/render-in-light-dom.js.map +1 -1
- package/es-custom/components/prompt-line/src/tiptap/render-token-chip.js.map +1 -1
- package/es-custom/components/prompt-line/src/tiptap/token-node-view.js.map +1 -1
- package/es-custom/components/prompt-line/src/tiptap/trigger-utils.js.map +1 -1
- package/es-custom/components/prompt-line/src/tiptap/types.d.ts +16 -3
- package/es-custom/components/prompt-line/src/tiptap/typing-indicator.js.map +1 -1
- package/es-custom/components/prompt-line/src/tiptap/value-sync.js.map +1 -1
- package/es-custom/components/prompt-line/src/types.js.map +1 -1
- package/es-custom/components/reasoning-steps/src/reasoning-step.js.map +1 -1
- package/es-custom/components/reasoning-steps/src/reasoning-step.scss.js +1 -1
- package/es-custom/components/reasoning-steps/src/reasoning-step.scss.js.map +1 -1
- package/es-custom/components/reasoning-steps/src/reasoning-steps-toggle.js.map +1 -1
- package/es-custom/components/reasoning-steps/src/reasoning-steps-toggle.scss.js.map +1 -1
- package/es-custom/components/reasoning-steps/src/reasoning-steps.js.map +1 -1
- package/es-custom/components/reasoning-steps/src/reasoning-steps.scss.js +1 -1
- package/es-custom/components/reasoning-steps/src/reasoning-steps.scss.js.map +1 -1
- package/es-custom/components/shared/dynamic-css-var-sheet.js +24 -2
- package/es-custom/components/shared/dynamic-css-var-sheet.js.map +1 -1
- package/es-custom/components/shared/media-utils/script-loader.js.map +1 -1
- package/es-custom/components/table/src/table-loader.js.map +1 -1
- package/es-custom/components/table/src/table-pagination.template.js.map +1 -1
- package/es-custom/components/table/src/table-skeleton.template.js.map +1 -1
- package/es-custom/components/table/src/table.js.map +1 -1
- package/es-custom/components/table/src/table.scss.js.map +1 -1
- package/es-custom/components/table/src/table.template.js.map +1 -1
- package/es-custom/components/toolbar/src/toolbar.js.map +1 -1
- package/es-custom/components/toolbar/src/toolbar.scss.js +1 -1
- package/es-custom/components/toolbar/src/toolbar.scss.js.map +1 -1
- package/es-custom/components/truncated-text/src/truncated-text.js.map +1 -1
- package/es-custom/components/truncated-text/src/truncated-text.scss.js.map +1 -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.map +1 -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.map +1 -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.map +1 -1
- package/es-custom/components/video-player/src/video-player.js.map +1 -1
- package/es-custom/components/video-player/src/video-player.scss.js.map +1 -1
- package/es-custom/components/workspace-shell/src/header-collapsible-manager.js.map +1 -1
- package/es-custom/components/workspace-shell/src/workspace-shell-body.js.map +1 -1
- package/es-custom/components/workspace-shell/src/workspace-shell-footer.js.map +1 -1
- package/es-custom/components/workspace-shell/src/workspace-shell-footer.scss.js.map +1 -1
- package/es-custom/components/workspace-shell/src/workspace-shell-header.js +2 -1
- package/es-custom/components/workspace-shell/src/workspace-shell-header.js.map +1 -1
- package/es-custom/components/workspace-shell/src/workspace-shell-header.scss.js +1 -1
- package/es-custom/components/workspace-shell/src/workspace-shell-header.scss.js.map +1 -1
- package/es-custom/components/workspace-shell/src/workspace-shell.js.map +1 -1
- package/es-custom/components/workspace-shell/src/workspace-shell.scss.js +1 -1
- package/es-custom/components/workspace-shell/src/workspace-shell.scss.js.map +1 -1
- package/es-custom/globals/decorators/carbon-element.js.map +1 -1
- package/es-custom/globals/scss/common.scss.js.map +1 -1
- package/es-custom/globals/settings.js.map +1 -1
- package/es-custom/globals/utils/aria-announcer-manager.js.map +1 -1
- package/es-custom/globals/utils/browser-utils.js.map +1 -1
- package/es-custom/globals/utils/csv.js.map +1 -1
- package/es-custom/globals/utils/dom-utils.js.map +1 -1
- package/es-custom/globals/utils/focus-utils.js.map +1 -1
- package/es-custom/globals/utils/iconTransform.js.map +1 -1
- package/es-custom/globals/utils/rtl-utils.js.map +1 -1
- package/es-custom/globals/utils/uuid.js.map +1 -1
- package/es-custom/react/ai-label-action-button.js.map +1 -1
- package/es-custom/react/audio-player.js.map +1 -1
- package/es-custom/react/autocomplete.js.map +1 -1
- package/es-custom/react/card.js.map +1 -1
- package/es-custom/react/carousel.js.map +1 -1
- package/es-custom/react/chain-of-thought-step.js.map +1 -1
- package/es-custom/react/chain-of-thought-toggle.js.map +1 -1
- package/es-custom/react/chain-of-thought.js.map +1 -1
- package/es-custom/react/chat-button-skeleton.d.ts +11 -0
- package/es-custom/react/chat-button-skeleton.js +28 -0
- package/es-custom/react/chat-button-skeleton.js.map +1 -0
- package/es-custom/react/chat-button.js.map +1 -1
- package/es-custom/react/chat-header.js.map +1 -1
- package/es-custom/react/chat-shell.js.map +1 -1
- package/es-custom/react/code-snippet.d.ts +1 -1
- package/es-custom/react/code-snippet.js +1 -1
- package/es-custom/react/code-snippet.js.map +1 -1
- package/es-custom/react/error-message.js.map +1 -1
- package/es-custom/react/feedback-buttons.js.map +1 -1
- package/es-custom/react/feedback.js.map +1 -1
- package/es-custom/react/file-upload-item.js.map +1 -1
- package/es-custom/react/file-uploads.js.map +1 -1
- package/es-custom/react/history/history-content.js.map +1 -1
- package/es-custom/react/history/history-delete-panel.js.map +1 -1
- package/es-custom/react/history/history-header.js.map +1 -1
- package/es-custom/react/history/history-loading.js.map +1 -1
- package/es-custom/react/history/history-panel-item-input.js.map +1 -1
- package/es-custom/react/history/history-panel-item.js.map +1 -1
- package/es-custom/react/history/history-panel-items.js.map +1 -1
- package/es-custom/react/history/history-panel-menu.js.map +1 -1
- package/es-custom/react/history/history-panel.js.map +1 -1
- package/es-custom/react/history/history-search-item.js.map +1 -1
- package/es-custom/react/history/history-shell.js.map +1 -1
- package/es-custom/react/history/history-toolbar.js.map +1 -1
- package/es-custom/react/hooks/useChatAutocomplete.js +4 -3
- package/es-custom/react/hooks/useChatAutocomplete.js.map +1 -1
- package/es-custom/react/input-send-control.js.map +1 -1
- package/es-custom/react/launcher.js.map +1 -1
- package/es-custom/react/markdown.js.map +1 -1
- package/es-custom/react/panel.js.map +1 -1
- package/es-custom/react/processing.js.map +1 -1
- package/es-custom/react/prompt-line-shell.js.map +1 -1
- package/es-custom/react/prompt-line.js.map +1 -1
- package/es-custom/react/reasoning-step.js.map +1 -1
- package/es-custom/react/reasoning-steps-toggle.js.map +1 -1
- package/es-custom/react/reasoning-steps.js.map +1 -1
- package/es-custom/react/stop-streaming-button.js.map +1 -1
- package/es-custom/react/table.js.map +1 -1
- package/es-custom/react/tool-call-data.js.map +1 -1
- package/es-custom/react/toolbar.js +1 -1
- package/es-custom/react/toolbar.js.map +1 -1
- package/es-custom/react/transcript.js.map +1 -1
- package/es-custom/react/utils/transformSuggestionConfig.js.map +1 -1
- package/es-custom/react/utils/withWebComponentBridge.js.map +1 -1
- package/es-custom/react/video-player.js.map +1 -1
- package/es-custom/react/workspace-shell.js.map +1 -1
- package/es-custom/testing/PageObjectId.js.map +1 -1
- package/es-custom/testing/load-all-lazy-deps.js.map +1 -1
- package/package.json +3 -3
- package/es/react/__tests__/jest.setup.js +0 -82
- package/es/react/__tests__/jest.setup.js.map +0 -1
- package/es-custom/react/__tests__/jest.setup.js +0 -82
- package/es-custom/react/__tests__/jest.setup.js.map +0 -1
|
@@ -0,0 +1,41 @@
|
|
|
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 { property } from 'lit/decorators.js';
|
|
10
|
+
import CDSButtonSkeleton from '@carbon/web-components/es/components/button/button-skeleton.js';
|
|
11
|
+
import { carbonElement } from '../../../globals/decorators/carbon-element.js';
|
|
12
|
+
import prefix from '../../../globals/settings.js';
|
|
13
|
+
import commonStyles from '../../../globals/scss/common.scss.js';
|
|
14
|
+
import styles from './chat-button.scss.js';
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* @license
|
|
18
|
+
*
|
|
19
|
+
* Copyright IBM Corp. 2025, 2026
|
|
20
|
+
*
|
|
21
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
|
22
|
+
* LICENSE file in the root directory of this source tree.
|
|
23
|
+
*/
|
|
24
|
+
/**
|
|
25
|
+
* Component extending the @carbon/web-components' button skeleton
|
|
26
|
+
*
|
|
27
|
+
* @element cds-aichat-button-skeleton
|
|
28
|
+
*/
|
|
29
|
+
let CDSAIChatButtonSkeleton = class CDSAIChatButtonSkeleton extends CDSButtonSkeleton {
|
|
30
|
+
};
|
|
31
|
+
CDSAIChatButtonSkeleton.styles = [commonStyles, styles];
|
|
32
|
+
__decorate([
|
|
33
|
+
property({ reflect: true, attribute: 'size' })
|
|
34
|
+
], CDSAIChatButtonSkeleton.prototype, "size", void 0);
|
|
35
|
+
CDSAIChatButtonSkeleton = __decorate([
|
|
36
|
+
carbonElement(`${prefix}-button-skeleton`)
|
|
37
|
+
], CDSAIChatButtonSkeleton);
|
|
38
|
+
var CDSAIChatButtonSkeleton$1 = CDSAIChatButtonSkeleton;
|
|
39
|
+
|
|
40
|
+
export { CDSAIChatButtonSkeleton, CDSAIChatButtonSkeleton$1 as default };
|
|
41
|
+
//# sourceMappingURL=chat-button-skeleton.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"chat-button-skeleton.js","sources":["../../../../src/components/chat-button/src/chat-button-skeleton.ts"],"sourcesContent":["/**\n * @license\n *\n * Copyright IBM Corp. 2025, 2026\n *\n * This source code is licensed under the Apache-2.0 license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport { property } from 'lit/decorators.js';\nimport CDSButtonSkeleton from '@carbon/web-components/es/components/button/button-skeleton.js';\nimport { carbonElement } from '../../../globals/decorators/index.js';\nimport prefix from '../../../globals/settings.js';\nimport commonStyles from '../../../globals/scss/common.scss?lit';\nimport styles from './chat-button.scss?lit';\nimport type { ChatButtonSize } from './chat-button.js';\n\n/**\n * Component extending the @carbon/web-components' button skeleton\n *\n * @element cds-aichat-button-skeleton\n */\n@carbonElement(`${prefix}-button-skeleton`)\nclass CDSAIChatButtonSkeleton extends CDSButtonSkeleton {\n static styles = [commonStyles, styles];\n\n /**\n * Button size.\n * Options: \"sm\", \"md\", \"lg\".\n */\n @property({ reflect: true, attribute: 'size' })\n declare size: ChatButtonSize;\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'cds-aichat-button-skeleton': CDSAIChatButtonSkeleton;\n }\n}\n\nexport { CDSAIChatButtonSkeleton };\nexport default CDSAIChatButtonSkeleton;\n"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA;;;;;;;AAOG;AAUH;;;;AAIG;AAEH,IAAM,uBAAuB,GAA7B,MAAM,uBAAwB,SAAQ,iBAAiB,CAAA;;AAC9C,uBAAA,CAAA,MAAM,GAAG,CAAC,YAAY,EAAE,MAAM,CAAC;AAO9B,UAAA,CAAA;IADP,QAAQ,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,MAAM,EAAE;AACjB,CAAA,EAAA,uBAAA,CAAA,SAAA,EAAA,MAAA,EAAA,MAAA,CAAA;AARzB,uBAAuB,GAAA,UAAA,CAAA;AAD5B,IAAA,aAAa,CAAC,CAAA,EAAG,MAAM,CAAA,gBAAA,CAAkB;AACpC,CAAA,EAAA,uBAAuB,CAS5B;AASD,gCAAe,uBAAuB;;"}
|
|
@@ -11,7 +11,7 @@ import { CHAT_BUTTON_SIZE } from '../defs';
|
|
|
11
11
|
import { BUTTON_KIND as CHAT_BUTTON_KIND, BUTTON_TYPE as CHAT_BUTTON_TYPE, BUTTON_TOOLTIP_ALIGNMENT as CHAT_BUTTON_TOOLTIP_ALIGNMENT, BUTTON_TOOLTIP_POSITION as CHAT_BUTTON_TOOLTIP_POSITION } from '@carbon/web-components/es/components/button/button.js';
|
|
12
12
|
import CDSButton from '@carbon/web-components/es/components/button/button.js';
|
|
13
13
|
export { CHAT_BUTTON_KIND, CHAT_BUTTON_TYPE, CHAT_BUTTON_SIZE, CHAT_BUTTON_TOOLTIP_ALIGNMENT, CHAT_BUTTON_TOOLTIP_POSITION, };
|
|
14
|
-
type ChatButtonSize = CHAT_BUTTON_SIZE.SMALL | CHAT_BUTTON_SIZE.MEDIUM | CHAT_BUTTON_SIZE.LARGE;
|
|
14
|
+
export type ChatButtonSize = CHAT_BUTTON_SIZE.SMALL | CHAT_BUTTON_SIZE.MEDIUM | CHAT_BUTTON_SIZE.LARGE;
|
|
15
15
|
/**
|
|
16
16
|
* Component extending the @carbon/web-components' button
|
|
17
17
|
*
|
|
@@ -23,6 +23,9 @@ declare class CDSAIChatButton extends CDSButton {
|
|
|
23
23
|
* Specify whether the `ChatButton` should be rendered as a quick action button
|
|
24
24
|
*/
|
|
25
25
|
isQuickAction: boolean;
|
|
26
|
+
private readonly _handleSelectedClick;
|
|
27
|
+
connectedCallback(): void;
|
|
28
|
+
disconnectedCallback(): void;
|
|
26
29
|
/**
|
|
27
30
|
* Button size.
|
|
28
31
|
* Options: "sm", "md", "lg".
|
|
@@ -35,6 +35,14 @@ let CDSAIChatButton = class CDSAIChatButton extends CDSButton {
|
|
|
35
35
|
* Specify whether the `ChatButton` should be rendered as a quick action button
|
|
36
36
|
*/
|
|
37
37
|
this.isQuickAction = false;
|
|
38
|
+
// Blocks programmatic el.click() when isSelected — `inert` only blocks user
|
|
39
|
+
// input, not programmatic calls. Registered manually (not via @HostListener)
|
|
40
|
+
// to avoid mutating the shared CDSButton._hostListeners table.
|
|
41
|
+
this._handleSelectedClick = (e) => {
|
|
42
|
+
if (this.isSelected) {
|
|
43
|
+
e.stopImmediatePropagation();
|
|
44
|
+
}
|
|
45
|
+
};
|
|
38
46
|
/**
|
|
39
47
|
* @internal
|
|
40
48
|
*/
|
|
@@ -44,8 +52,22 @@ let CDSAIChatButton = class CDSAIChatButton extends CDSButton {
|
|
|
44
52
|
CHAT_BUTTON_SIZE.LARGE,
|
|
45
53
|
];
|
|
46
54
|
}
|
|
55
|
+
connectedCallback() {
|
|
56
|
+
super.connectedCallback();
|
|
57
|
+
this.addEventListener('click', this._handleSelectedClick, {
|
|
58
|
+
capture: true,
|
|
59
|
+
});
|
|
60
|
+
}
|
|
61
|
+
disconnectedCallback() {
|
|
62
|
+
this.removeEventListener('click', this._handleSelectedClick, {
|
|
63
|
+
capture: true,
|
|
64
|
+
});
|
|
65
|
+
super.disconnectedCallback();
|
|
66
|
+
}
|
|
47
67
|
willUpdate(changedProps) {
|
|
48
68
|
if (changedProps.has('isQuickAction') ||
|
|
69
|
+
changedProps.has('isSelected') ||
|
|
70
|
+
changedProps.has('disabled') ||
|
|
49
71
|
changedProps.has('size') ||
|
|
50
72
|
changedProps.has('kind')) {
|
|
51
73
|
this._normalizeButtonState(changedProps);
|
|
@@ -54,13 +76,19 @@ let CDSAIChatButton = class CDSAIChatButton extends CDSButton {
|
|
|
54
76
|
_normalizeButtonState(changedProps) {
|
|
55
77
|
if (this.isQuickAction) {
|
|
56
78
|
this.size = CHAT_BUTTON_SIZE.SMALL;
|
|
57
|
-
// Only default to ghost when kind was not explicitly provided in this update.
|
|
58
79
|
if (!changedProps.has('kind')) {
|
|
59
80
|
this.kind = BUTTON_KIND.GHOST;
|
|
60
81
|
}
|
|
82
|
+
// When isSelected, set the HTML `inert` attribute on the host element to
|
|
83
|
+
// block pointer and keyboard interaction. This leaves `this.disabled`
|
|
84
|
+
// untouched so it always reflects exactly what the consumer set.
|
|
85
|
+
// tabIndex is also set explicitly — `inert` alone doesn't update it.
|
|
86
|
+
const isBlocked = this.isSelected || this.disabled;
|
|
87
|
+
this.inert = this.isSelected;
|
|
88
|
+
this.tabIndex = isBlocked ? -1 : 0;
|
|
89
|
+
this.toggleAttribute('data-is-selected', this.isSelected);
|
|
61
90
|
return;
|
|
62
91
|
}
|
|
63
|
-
// Do not allow size larger than `lg`
|
|
64
92
|
if (!this.allowedSizes.includes(this.size)) {
|
|
65
93
|
this.size = CHAT_BUTTON_SIZE.LARGE;
|
|
66
94
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"chat-button.js","sources":["../../../../src/components/chat-button/src/chat-button.ts"],"sourcesContent":[
|
|
1
|
+
{"version":3,"file":"chat-button.js","sources":["../../../../src/components/chat-button/src/chat-button.ts"],"sourcesContent":["/**\n * @license\n *\n * Copyright IBM Corp. 2025, 2026\n *\n * This source code is licensed under the Apache-2.0 license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport { property } from 'lit/decorators.js';\nimport { PropertyValues } from 'lit';\nimport { CHAT_BUTTON_SIZE } from '../defs';\nimport {\n BUTTON_KIND as CHAT_BUTTON_KIND,\n BUTTON_TYPE as CHAT_BUTTON_TYPE,\n BUTTON_TOOLTIP_ALIGNMENT as CHAT_BUTTON_TOOLTIP_ALIGNMENT,\n BUTTON_TOOLTIP_POSITION as CHAT_BUTTON_TOOLTIP_POSITION,\n} from '@carbon/web-components/es/components/button/button.js';\nimport CDSButton from '@carbon/web-components/es/components/button/button.js';\nimport { carbonElement } from '../../../globals/decorators/index.js';\nimport prefix from '../../../globals/settings.js';\nimport commonStyles from '../../../globals/scss/common.scss?lit';\nimport styles from './chat-button.scss?lit';\n\nexport {\n CHAT_BUTTON_KIND,\n CHAT_BUTTON_TYPE,\n CHAT_BUTTON_SIZE,\n CHAT_BUTTON_TOOLTIP_ALIGNMENT,\n CHAT_BUTTON_TOOLTIP_POSITION,\n};\n\nexport type ChatButtonSize =\n CHAT_BUTTON_SIZE.SMALL | CHAT_BUTTON_SIZE.MEDIUM | CHAT_BUTTON_SIZE.LARGE;\n\n/**\n * Component extending the @carbon/web-components' button\n *\n * @element cds-aichat-button\n */\n@carbonElement(`${prefix}-button`)\nclass CDSAIChatButton extends CDSButton {\n static styles = [commonStyles, styles];\n\n /**\n * Specify whether the `ChatButton` should be rendered as a quick action button\n */\n @property({ type: Boolean, attribute: 'is-quick-action' })\n isQuickAction = false;\n\n // Blocks programmatic el.click() when isSelected — `inert` only blocks user\n // input, not programmatic calls. Registered manually (not via @HostListener)\n // to avoid mutating the shared CDSButton._hostListeners table.\n private readonly _handleSelectedClick = (e: Event): void => {\n if (this.isSelected) {\n e.stopImmediatePropagation();\n }\n };\n\n connectedCallback(): void {\n super.connectedCallback();\n this.addEventListener('click', this._handleSelectedClick, {\n capture: true,\n });\n }\n\n disconnectedCallback(): void {\n this.removeEventListener('click', this._handleSelectedClick, {\n capture: true,\n });\n super.disconnectedCallback();\n }\n\n /**\n * Button size.\n * Options: \"sm\", \"md\", \"lg\".\n */\n @property({ reflect: true, attribute: 'size' })\n declare size: ChatButtonSize;\n\n /**\n * @internal\n */\n private readonly allowedSizes: CHAT_BUTTON_SIZE[] = [\n CHAT_BUTTON_SIZE.SMALL,\n CHAT_BUTTON_SIZE.MEDIUM,\n CHAT_BUTTON_SIZE.LARGE,\n ];\n\n protected willUpdate(changedProps: PropertyValues<this>): void {\n if (\n changedProps.has('isQuickAction') ||\n changedProps.has('isSelected') ||\n changedProps.has('disabled') ||\n changedProps.has('size') ||\n changedProps.has('kind')\n ) {\n this._normalizeButtonState(changedProps);\n }\n }\n\n private _normalizeButtonState(changedProps: PropertyValues<this>): void {\n if (this.isQuickAction) {\n this.size = CHAT_BUTTON_SIZE.SMALL;\n if (!changedProps.has('kind')) {\n this.kind = CHAT_BUTTON_KIND.GHOST;\n }\n\n // When isSelected, set the HTML `inert` attribute on the host element to\n // block pointer and keyboard interaction. This leaves `this.disabled`\n // untouched so it always reflects exactly what the consumer set.\n // tabIndex is also set explicitly — `inert` alone doesn't update it.\n const isBlocked = this.isSelected || this.disabled;\n this.inert = this.isSelected;\n this.tabIndex = isBlocked ? -1 : 0;\n this.toggleAttribute('data-is-selected', this.isSelected);\n\n return;\n }\n\n if (!this.allowedSizes.includes(this.size as CHAT_BUTTON_SIZE)) {\n this.size = CHAT_BUTTON_SIZE.LARGE;\n }\n\n if (\n !Object.values(CHAT_BUTTON_KIND).includes(this.kind as CHAT_BUTTON_KIND)\n ) {\n this.kind = CHAT_BUTTON_KIND.PRIMARY;\n }\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'cds-aichat-button': CDSAIChatButton;\n }\n}\n\nexport { CDSAIChatButton };\nexport default CDSAIChatButton;\n"],"names":["CHAT_BUTTON_KIND"],"mappings":"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"}
|