@carbon/ai-chat-components 0.10.0 → 0.11.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/README.md +0 -3
- package/custom-elements.json +4827 -2917
- package/es/components/card/src/card-footer.d.ts +1 -1
- package/es/components/card/src/card-footer.js +2 -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 +2 -1
- 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.d.ts +1 -1
- package/es/components/card/src/card.js +2 -1
- package/es/components/card/src/card.js.map +1 -1
- package/es/components/card/src/card.scss.js +1 -1
- package/es/components/chain-of-thought/src/chain-of-thought-step.d.ts +1 -1
- package/es/components/chain-of-thought/src/chain-of-thought-step.js +4 -5
- 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-toggle.d.ts +1 -1
- package/es/components/chain-of-thought/src/chain-of-thought-toggle.js +3 -3
- 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.d.ts +1 -1
- package/es/components/chain-of-thought/src/chain-of-thought.js +3 -2
- 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 +1 -1
- package/es/components/chain-of-thought/src/tool-call-data.d.ts +1 -1
- package/es/components/chain-of-thought/src/tool-call-data.js +2 -1
- package/es/components/chain-of-thought/src/tool-call-data.js.map +1 -1
- package/es/components/chat-button/src/chat-button.d.ts +2 -2
- package/es/components/chat-button/src/chat-button.js +3 -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-shell/index.d.ts +2 -0
- package/es/components/chat-shell/index.js +1 -0
- package/es/components/chat-shell/index.js.map +1 -1
- package/es/components/chat-shell/src/aria-announcer-manager.d.ts +40 -0
- package/es/components/chat-shell/src/aria-announcer-manager.js +104 -0
- package/es/components/chat-shell/src/aria-announcer-manager.js.map +1 -0
- package/es/components/chat-shell/src/chat-header.d.ts +177 -0
- package/es/components/chat-shell/src/chat-header.js +415 -0
- package/es/components/chat-shell/src/chat-header.js.map +1 -0
- package/es/components/chat-shell/src/chat-header.scss.js +13 -0
- package/es/components/chat-shell/src/chat-header.scss.js.map +1 -0
- package/es/components/chat-shell/src/corner-manager.d.ts +35 -0
- package/es/components/chat-shell/src/corner-manager.js +87 -0
- package/es/components/chat-shell/src/corner-manager.js.map +1 -0
- package/es/components/chat-shell/src/initialization-manager.d.ts +44 -0
- package/es/components/chat-shell/src/initialization-manager.js +88 -0
- package/es/components/chat-shell/src/initialization-manager.js.map +1 -0
- package/es/components/chat-shell/src/panel.d.ts +14 -1
- package/es/components/chat-shell/src/panel.js +32 -4
- package/es/components/chat-shell/src/panel.js.map +1 -1
- package/es/components/chat-shell/src/panel.scss.js +1 -1
- package/es/components/chat-shell/src/resize-observer-manager.d.ts +55 -0
- package/es/components/chat-shell/src/resize-observer-manager.js +219 -0
- package/es/components/chat-shell/src/resize-observer-manager.js.map +1 -0
- package/es/components/chat-shell/src/shell.d.ts +54 -21
- package/es/components/chat-shell/src/shell.js +297 -287
- package/es/components/chat-shell/src/shell.js.map +1 -1
- package/es/components/chat-shell/src/shell.scss.js +1 -1
- package/es/components/chat-shell/src/slot-observer.d.ts +53 -0
- package/es/components/chat-shell/src/slot-observer.js +156 -0
- package/es/components/chat-shell/src/slot-observer.js.map +1 -0
- package/es/components/chat-shell/src/types.d.ts +66 -0
- package/es/components/chat-shell/src/types.js +8 -0
- package/es/components/chat-shell/src/types.js.map +1 -0
- package/es/components/chat-shell/src/workspace-manager.d.ts +12 -1
- package/es/components/chat-shell/src/workspace-manager.js +42 -2
- package/es/components/chat-shell/src/workspace-manager.js.map +1 -1
- package/es/components/code-snippet/index.d.ts +3 -2
- package/es/components/code-snippet/index.js +1 -1
- package/es/components/code-snippet/src/code-snippet.d.ts +58 -15
- package/es/components/code-snippet/src/code-snippet.js +261 -95
- 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/codemirror-runtime.d.ts +1 -1
- package/es/components/code-snippet/src/codemirror/codemirror-runtime.js +1 -1
- package/es/components/code-snippet/src/codemirror/editor-manager.d.ts +4 -2
- package/es/components/code-snippet/src/codemirror/editor-manager.js +18 -3
- package/es/components/code-snippet/src/codemirror/editor-manager.js.map +1 -1
- package/es/components/code-snippet/src/codemirror/language-controller.d.ts +1 -0
- package/es/components/code-snippet/src/codemirror/language-controller.js +11 -5
- package/es/components/code-snippet/src/codemirror/language-controller.js.map +1 -1
- package/es/components/code-snippet/src/codemirror/marker-utils.js +2 -1
- package/es/components/code-snippet/src/codemirror/marker-utils.js.map +1 -1
- package/es/components/code-snippet/src/codemirror/theme.d.ts +12 -0
- package/es/components/code-snippet/src/codemirror/theme.js +26 -2
- package/es/components/code-snippet/src/codemirror/theme.js.map +1 -1
- package/es/components/code-snippet/src/dom-utils.d.ts +1 -0
- package/es/components/code-snippet/src/dom-utils.js +12 -1
- package/es/components/code-snippet/src/dom-utils.js.map +1 -1
- package/es/components/code-snippet/src/layout-utils.d.ts +9 -1
- package/es/components/code-snippet/src/layout-utils.js +21 -16
- package/es/components/code-snippet/src/layout-utils.js.map +1 -1
- package/es/components/code-snippet/src/streaming-manager.js +7 -0
- package/es/components/code-snippet/src/streaming-manager.js.map +1 -1
- package/es/components/feedback/src/feedback-buttons.d.ts +2 -0
- package/es/components/feedback/src/feedback-buttons.js +65 -3
- package/es/components/feedback/src/feedback-buttons.js.map +1 -1
- package/es/components/feedback/src/feedback-buttons.scss.js +13 -0
- package/es/components/feedback/src/feedback-buttons.scss.js.map +1 -0
- package/es/components/feedback/src/feedback.d.ts +20 -10
- package/es/components/feedback/src/feedback.js +114 -20
- package/es/components/feedback/src/feedback.js.map +1 -1
- package/es/components/feedback/src/feedback.scss.js +1 -1
- package/es/components/markdown/src/markdown-renderer.d.ts +31 -21
- package/es/components/markdown/src/markdown-renderer.js +57 -48
- package/es/components/markdown/src/markdown-renderer.js.map +1 -1
- package/es/components/markdown/src/markdown.d.ts +34 -31
- package/es/components/markdown/src/markdown.js +221 -138
- 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/markdown.template.js +1 -1
- package/es/components/markdown/src/utils.d.ts +0 -4
- package/es/components/markdown/src/utils.js +1 -7
- package/es/components/markdown/src/utils.js.map +1 -1
- package/es/components/processing/src/processing.d.ts +1 -1
- package/es/components/processing/src/processing.js +2 -1
- package/es/components/processing/src/processing.js.map +1 -1
- package/es/components/processing/src/processing.scss.js +1 -1
- package/es/components/reasoning-steps/src/reasoning-step.d.ts +1 -1
- package/es/components/reasoning-steps/src/reasoning-step.js +2 -1
- package/es/components/reasoning-steps/src/reasoning-step.js.map +1 -1
- package/es/components/reasoning-steps/src/reasoning-steps-toggle.d.ts +1 -1
- package/es/components/reasoning-steps/src/reasoning-steps-toggle.js +27 -4
- package/es/components/reasoning-steps/src/reasoning-steps-toggle.js.map +1 -1
- package/es/components/reasoning-steps/src/reasoning-steps-toggle.scss.js +1 -1
- package/es/components/reasoning-steps/src/reasoning-steps.d.ts +1 -1
- package/es/components/reasoning-steps/src/reasoning-steps.js +3 -5
- package/es/components/reasoning-steps/src/reasoning-steps.js.map +1 -1
- package/es/components/table/src/table-pagination.template.js +3 -2
- package/es/components/table/src/table-pagination.template.js.map +1 -1
- package/es/components/table/src/table-skeleton.template.js +8 -6
- package/es/components/table/src/table-skeleton.template.js.map +1 -1
- package/es/components/table/src/table.d.ts +29 -3
- package/es/components/table/src/table.js +99 -6
- package/es/components/table/src/table.js.map +1 -1
- package/es/components/table/src/table.scss.js +1 -1
- package/es/components/table/src/table.template.js +11 -2
- package/es/components/table/src/table.template.js.map +1 -1
- package/es/components/toolbar/src/toolbar.d.ts +32 -5
- package/es/components/toolbar/src/toolbar.js +111 -47
- package/es/components/toolbar/src/toolbar.js.map +1 -1
- package/es/components/toolbar/src/toolbar.scss.js +1 -1
- package/es/components/truncated-text/index.d.ts +9 -0
- package/es/components/truncated-text/index.js +9 -0
- package/es/components/truncated-text/index.js.map +1 -0
- package/es/components/truncated-text/src/truncated-text.d.ts +81 -0
- package/es/components/truncated-text/src/truncated-text.js +282 -0
- package/es/components/truncated-text/src/truncated-text.js.map +1 -0
- package/es/components/truncated-text/src/truncated-text.scss.js +13 -0
- package/es/components/truncated-text/src/truncated-text.scss.js.map +1 -0
- package/es/components/workspace-shell/src/header-collapsible-manager.d.ts +77 -0
- package/es/components/workspace-shell/src/header-collapsible-manager.js +223 -0
- package/es/components/workspace-shell/src/header-collapsible-manager.js.map +1 -0
- package/es/components/workspace-shell/src/workspace-shell-body.d.ts +1 -1
- package/es/components/workspace-shell/src/workspace-shell-body.js +2 -1
- package/es/components/workspace-shell/src/workspace-shell-body.js.map +1 -1
- package/es/components/workspace-shell/src/workspace-shell-footer.d.ts +1 -3
- package/es/components/workspace-shell/src/workspace-shell-footer.js +8 -6
- package/es/components/workspace-shell/src/workspace-shell-footer.js.map +1 -1
- package/es/components/workspace-shell/src/workspace-shell-footer.scss.js +1 -1
- package/es/components/workspace-shell/src/workspace-shell-header.d.ts +11 -1
- package/es/components/workspace-shell/src/workspace-shell-header.js +88 -14
- 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.d.ts +16 -2
- package/es/components/workspace-shell/src/workspace-shell.js +77 -7
- 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/globals/scss/common.scss.js +13 -0
- package/es/globals/scss/common.scss.js.map +1 -0
- package/es/globals/utils/focus-utils.d.ts +57 -0
- package/es/globals/utils/focus-utils.js +180 -0
- package/es/globals/utils/focus-utils.js.map +1 -0
- package/es/react/card.d.ts +3 -6
- package/es/react/chain-of-thought-step.d.ts +1 -2
- package/es/react/chain-of-thought-toggle.d.ts +1 -2
- package/es/react/chain-of-thought.d.ts +1 -2
- package/es/react/chat-button.d.ts +2 -2
- package/es/react/chat-button.js +1 -1
- package/es/react/chat-header.d.ts +73 -0
- package/es/react/chat-header.js +55 -0
- package/es/react/chat-header.js.map +1 -0
- package/es/react/chat-shell.d.ts +1 -2
- package/es/react/code-snippet.d.ts +35 -2
- package/es/react/code-snippet.js +65 -9
- package/es/react/code-snippet.js.map +1 -1
- package/es/react/feedback-buttons.d.ts +1 -2
- package/es/react/feedback.d.ts +1 -2
- package/es/react/markdown.d.ts +1 -2
- package/es/react/markdown.js +11 -1
- package/es/react/markdown.js.map +1 -1
- package/es/react/panel.d.ts +1 -2
- package/es/react/processing.d.ts +1 -2
- package/es/react/reasoning-step.d.ts +1 -2
- package/es/react/reasoning-steps-toggle.d.ts +1 -2
- package/es/react/reasoning-steps.d.ts +1 -2
- package/es/react/tool-call-data.d.ts +1 -2
- package/es/react/toolbar.d.ts +14 -10
- package/es/react/toolbar.js +2 -0
- package/es/react/toolbar.js.map +1 -1
- package/es/react/utils/withWebComponentBridge.d.ts +5 -2
- package/es/react/utils/withWebComponentBridge.js +49 -1
- package/es/react/utils/withWebComponentBridge.js.map +1 -1
- package/es/react/workspace-shell.d.ts +4 -8
- package/es/testing/PageObjectId.d.ts +22 -0
- package/es/testing/PageObjectId.js +38 -0
- package/es/testing/PageObjectId.js.map +1 -0
- package/es/typings/overflow-menu.d.ts +30 -0
- package/es/typings/overflow-menu.js +8 -0
- package/es/typings/overflow-menu.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 +2 -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 +2 -1
- 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.d.ts +1 -1
- package/es-custom/components/card/src/card.js +2 -1
- package/es-custom/components/card/src/card.js.map +1 -1
- package/es-custom/components/card/src/card.scss.js +1 -1
- package/es-custom/components/chain-of-thought/src/chain-of-thought-step.d.ts +1 -1
- package/es-custom/components/chain-of-thought/src/chain-of-thought-step.js +4 -5
- 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-toggle.d.ts +1 -1
- package/es-custom/components/chain-of-thought/src/chain-of-thought-toggle.js +3 -3
- 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.d.ts +1 -1
- package/es-custom/components/chain-of-thought/src/chain-of-thought.js +3 -2
- 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 +1 -1
- package/es-custom/components/chain-of-thought/src/tool-call-data.d.ts +1 -1
- package/es-custom/components/chain-of-thought/src/tool-call-data.js +2 -1
- 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 +2 -2
- package/es-custom/components/chat-button/src/chat-button.js +3 -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-shell/index.d.ts +2 -0
- package/es-custom/components/chat-shell/index.js +1 -0
- package/es-custom/components/chat-shell/index.js.map +1 -1
- package/es-custom/components/chat-shell/src/aria-announcer-manager.d.ts +40 -0
- package/es-custom/components/chat-shell/src/aria-announcer-manager.js +104 -0
- package/es-custom/components/chat-shell/src/aria-announcer-manager.js.map +1 -0
- package/es-custom/components/chat-shell/src/chat-header.d.ts +177 -0
- package/es-custom/components/chat-shell/src/chat-header.js +415 -0
- package/es-custom/components/chat-shell/src/chat-header.js.map +1 -0
- package/es-custom/components/chat-shell/src/chat-header.scss.js +13 -0
- package/es-custom/components/chat-shell/src/chat-header.scss.js.map +1 -0
- package/es-custom/components/chat-shell/src/corner-manager.d.ts +35 -0
- package/es-custom/components/chat-shell/src/corner-manager.js +87 -0
- package/es-custom/components/chat-shell/src/corner-manager.js.map +1 -0
- package/es-custom/components/chat-shell/src/initialization-manager.d.ts +44 -0
- package/es-custom/components/chat-shell/src/initialization-manager.js +88 -0
- package/es-custom/components/chat-shell/src/initialization-manager.js.map +1 -0
- package/es-custom/components/chat-shell/src/panel.d.ts +14 -1
- package/es-custom/components/chat-shell/src/panel.js +32 -4
- package/es-custom/components/chat-shell/src/panel.js.map +1 -1
- package/es-custom/components/chat-shell/src/panel.scss.js +1 -1
- package/es-custom/components/chat-shell/src/resize-observer-manager.d.ts +55 -0
- package/es-custom/components/chat-shell/src/resize-observer-manager.js +219 -0
- package/es-custom/components/chat-shell/src/resize-observer-manager.js.map +1 -0
- package/es-custom/components/chat-shell/src/shell.d.ts +54 -21
- package/es-custom/components/chat-shell/src/shell.js +297 -287
- package/es-custom/components/chat-shell/src/shell.js.map +1 -1
- package/es-custom/components/chat-shell/src/shell.scss.js +1 -1
- package/es-custom/components/chat-shell/src/slot-observer.d.ts +53 -0
- package/es-custom/components/chat-shell/src/slot-observer.js +156 -0
- package/es-custom/components/chat-shell/src/slot-observer.js.map +1 -0
- package/es-custom/components/chat-shell/src/types.d.ts +66 -0
- package/es-custom/components/chat-shell/src/types.js +8 -0
- package/es-custom/components/chat-shell/src/types.js.map +1 -0
- package/es-custom/components/chat-shell/src/workspace-manager.d.ts +12 -1
- package/es-custom/components/chat-shell/src/workspace-manager.js +42 -2
- package/es-custom/components/chat-shell/src/workspace-manager.js.map +1 -1
- package/es-custom/components/code-snippet/index.d.ts +3 -2
- package/es-custom/components/code-snippet/index.js +1 -1
- package/es-custom/components/code-snippet/src/code-snippet.d.ts +58 -15
- package/es-custom/components/code-snippet/src/code-snippet.js +261 -95
- 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/codemirror-runtime.d.ts +1 -1
- package/es-custom/components/code-snippet/src/codemirror/codemirror-runtime.js +1 -1
- package/es-custom/components/code-snippet/src/codemirror/editor-manager.d.ts +4 -2
- package/es-custom/components/code-snippet/src/codemirror/editor-manager.js +18 -3
- package/es-custom/components/code-snippet/src/codemirror/editor-manager.js.map +1 -1
- package/es-custom/components/code-snippet/src/codemirror/language-controller.d.ts +1 -0
- package/es-custom/components/code-snippet/src/codemirror/language-controller.js +11 -5
- package/es-custom/components/code-snippet/src/codemirror/language-controller.js.map +1 -1
- package/es-custom/components/code-snippet/src/codemirror/marker-utils.js +2 -1
- package/es-custom/components/code-snippet/src/codemirror/marker-utils.js.map +1 -1
- package/es-custom/components/code-snippet/src/codemirror/theme.d.ts +12 -0
- package/es-custom/components/code-snippet/src/codemirror/theme.js +26 -2
- package/es-custom/components/code-snippet/src/codemirror/theme.js.map +1 -1
- package/es-custom/components/code-snippet/src/dom-utils.d.ts +1 -0
- package/es-custom/components/code-snippet/src/dom-utils.js +12 -1
- package/es-custom/components/code-snippet/src/dom-utils.js.map +1 -1
- package/es-custom/components/code-snippet/src/layout-utils.d.ts +9 -1
- package/es-custom/components/code-snippet/src/layout-utils.js +21 -16
- package/es-custom/components/code-snippet/src/layout-utils.js.map +1 -1
- package/es-custom/components/code-snippet/src/streaming-manager.js +7 -0
- package/es-custom/components/code-snippet/src/streaming-manager.js.map +1 -1
- package/es-custom/components/feedback/src/feedback-buttons.d.ts +2 -0
- package/es-custom/components/feedback/src/feedback-buttons.js +65 -3
- package/es-custom/components/feedback/src/feedback-buttons.js.map +1 -1
- package/es-custom/components/feedback/src/feedback-buttons.scss.js +13 -0
- package/es-custom/components/feedback/src/feedback-buttons.scss.js.map +1 -0
- package/es-custom/components/feedback/src/feedback.d.ts +20 -10
- package/es-custom/components/feedback/src/feedback.js +114 -20
- 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/markdown/src/markdown-renderer.d.ts +31 -21
- package/es-custom/components/markdown/src/markdown-renderer.js +57 -48
- package/es-custom/components/markdown/src/markdown-renderer.js.map +1 -1
- package/es-custom/components/markdown/src/markdown.d.ts +34 -31
- package/es-custom/components/markdown/src/markdown.js +221 -138
- 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/markdown.template.js +1 -1
- package/es-custom/components/markdown/src/utils.d.ts +0 -4
- package/es-custom/components/markdown/src/utils.js +1 -7
- package/es-custom/components/markdown/src/utils.js.map +1 -1
- package/es-custom/components/processing/src/processing.d.ts +1 -1
- package/es-custom/components/processing/src/processing.js +2 -1
- package/es-custom/components/processing/src/processing.js.map +1 -1
- package/es-custom/components/processing/src/processing.scss.js +1 -1
- package/es-custom/components/reasoning-steps/src/reasoning-step.d.ts +1 -1
- package/es-custom/components/reasoning-steps/src/reasoning-step.js +2 -1
- package/es-custom/components/reasoning-steps/src/reasoning-step.js.map +1 -1
- package/es-custom/components/reasoning-steps/src/reasoning-steps-toggle.d.ts +1 -1
- package/es-custom/components/reasoning-steps/src/reasoning-steps-toggle.js +27 -4
- 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 +1 -1
- package/es-custom/components/reasoning-steps/src/reasoning-steps.d.ts +1 -1
- package/es-custom/components/reasoning-steps/src/reasoning-steps.js +3 -5
- package/es-custom/components/reasoning-steps/src/reasoning-steps.js.map +1 -1
- package/es-custom/components/table/src/table-pagination.template.js +3 -2
- package/es-custom/components/table/src/table-pagination.template.js.map +1 -1
- package/es-custom/components/table/src/table-skeleton.template.js +8 -6
- package/es-custom/components/table/src/table-skeleton.template.js.map +1 -1
- package/es-custom/components/table/src/table.d.ts +29 -3
- package/es-custom/components/table/src/table.js +99 -6
- package/es-custom/components/table/src/table.js.map +1 -1
- package/es-custom/components/table/src/table.scss.js +1 -1
- package/es-custom/components/table/src/table.template.js +11 -2
- package/es-custom/components/table/src/table.template.js.map +1 -1
- package/es-custom/components/toolbar/src/toolbar.d.ts +32 -5
- package/es-custom/components/toolbar/src/toolbar.js +111 -47
- 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/truncated-text/index.d.ts +9 -0
- package/es-custom/components/truncated-text/index.js +9 -0
- package/es-custom/components/truncated-text/index.js.map +1 -0
- package/es-custom/components/truncated-text/src/truncated-text.d.ts +81 -0
- package/es-custom/components/truncated-text/src/truncated-text.js +282 -0
- package/es-custom/components/truncated-text/src/truncated-text.js.map +1 -0
- package/es-custom/components/truncated-text/src/truncated-text.scss.js +13 -0
- package/es-custom/components/truncated-text/src/truncated-text.scss.js.map +1 -0
- package/es-custom/components/workspace-shell/src/header-collapsible-manager.d.ts +77 -0
- package/es-custom/components/workspace-shell/src/header-collapsible-manager.js +223 -0
- package/es-custom/components/workspace-shell/src/header-collapsible-manager.js.map +1 -0
- package/es-custom/components/workspace-shell/src/workspace-shell-body.d.ts +1 -1
- package/es-custom/components/workspace-shell/src/workspace-shell-body.js +2 -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.d.ts +1 -3
- package/es-custom/components/workspace-shell/src/workspace-shell-footer.js +8 -6
- 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 +1 -1
- package/es-custom/components/workspace-shell/src/workspace-shell-header.d.ts +11 -1
- package/es-custom/components/workspace-shell/src/workspace-shell-header.js +88 -14
- 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.d.ts +16 -2
- package/es-custom/components/workspace-shell/src/workspace-shell.js +77 -7
- 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/globals/scss/common.scss.js +13 -0
- package/es-custom/globals/scss/common.scss.js.map +1 -0
- package/es-custom/globals/utils/focus-utils.d.ts +57 -0
- package/es-custom/globals/utils/focus-utils.js +180 -0
- package/es-custom/globals/utils/focus-utils.js.map +1 -0
- package/es-custom/react/card.d.ts +3 -6
- package/es-custom/react/chain-of-thought-step.d.ts +1 -2
- package/es-custom/react/chain-of-thought-toggle.d.ts +1 -2
- package/es-custom/react/chain-of-thought.d.ts +1 -2
- package/es-custom/react/chat-button.d.ts +2 -2
- package/es-custom/react/chat-button.js +1 -1
- package/es-custom/react/chat-header.d.ts +73 -0
- package/es-custom/react/chat-header.js +55 -0
- package/es-custom/react/chat-header.js.map +1 -0
- package/es-custom/react/chat-shell.d.ts +1 -2
- package/es-custom/react/code-snippet.d.ts +35 -2
- package/es-custom/react/code-snippet.js +65 -9
- package/es-custom/react/code-snippet.js.map +1 -1
- package/es-custom/react/feedback-buttons.d.ts +1 -2
- package/es-custom/react/feedback.d.ts +1 -2
- package/es-custom/react/markdown.d.ts +1 -2
- package/es-custom/react/markdown.js +11 -1
- package/es-custom/react/markdown.js.map +1 -1
- package/es-custom/react/panel.d.ts +1 -2
- package/es-custom/react/processing.d.ts +1 -2
- package/es-custom/react/reasoning-step.d.ts +1 -2
- package/es-custom/react/reasoning-steps-toggle.d.ts +1 -2
- package/es-custom/react/reasoning-steps.d.ts +1 -2
- package/es-custom/react/tool-call-data.d.ts +1 -2
- package/es-custom/react/toolbar.d.ts +14 -10
- package/es-custom/react/toolbar.js +2 -0
- package/es-custom/react/toolbar.js.map +1 -1
- package/es-custom/react/utils/withWebComponentBridge.d.ts +5 -2
- package/es-custom/react/utils/withWebComponentBridge.js +49 -1
- package/es-custom/react/utils/withWebComponentBridge.js.map +1 -1
- package/es-custom/react/workspace-shell.d.ts +4 -8
- package/es-custom/testing/PageObjectId.d.ts +22 -0
- package/es-custom/testing/PageObjectId.js +38 -0
- package/es-custom/testing/PageObjectId.js.map +1 -0
- package/es-custom/typings/overflow-menu.d.ts +30 -0
- package/es-custom/typings/overflow-menu.js +8 -0
- package/es-custom/typings/overflow-menu.js.map +1 -0
- package/package.json +6 -4
- package/scss/_custom-properties.scss +70 -0
- package/scss/_modifiers.scss +231 -0
- package/scss/_tokens-component.scss +30 -0
- package/scss/_tokens-layout.scss +29 -0
- package/scss/_utilities.scss +32 -0
- package/scss/common.scss +150 -0
- package/scss/grid.scss +11 -0
- package/scss/themes.scss +33 -0
- package/scss/vars.scss +12 -0
- package/telemetry.yml +73 -33
- package/es/components/code-snippet/src/code-snippet-card.d.ts +0 -63
- package/es/components/code-snippet/src/code-snippet-card.js +0 -187
- package/es/components/code-snippet/src/code-snippet-card.js.map +0 -1
- package/es/components/feedback/src/feedback-buttons.template.d.ts +0 -4
- package/es/components/feedback/src/feedback-buttons.template.js +0 -79
- package/es/components/feedback/src/feedback-buttons.template.js.map +0 -1
- package/es/components/feedback/src/feedback.template.d.ts +0 -12
- package/es/components/feedback/src/feedback.template.js +0 -115
- package/es/components/feedback/src/feedback.template.js.map +0 -1
- package/es/components/reasoning-steps/src/reasoning-steps-toggle.template.d.ts +0 -3
- package/es/components/reasoning-steps/src/reasoning-steps-toggle.template.js +0 -43
- package/es/components/reasoning-steps/src/reasoning-steps-toggle.template.js.map +0 -1
- package/es/react/code-snippet-card.d.ts +0 -4
- package/es/react/code-snippet-card.js +0 -31
- package/es/react/code-snippet-card.js.map +0 -1
- package/es-custom/components/code-snippet/src/code-snippet-card.d.ts +0 -63
- package/es-custom/components/code-snippet/src/code-snippet-card.js +0 -187
- package/es-custom/components/code-snippet/src/code-snippet-card.js.map +0 -1
- package/es-custom/components/feedback/src/feedback-buttons.template.d.ts +0 -4
- package/es-custom/components/feedback/src/feedback-buttons.template.js +0 -79
- package/es-custom/components/feedback/src/feedback-buttons.template.js.map +0 -1
- package/es-custom/components/feedback/src/feedback.template.d.ts +0 -12
- package/es-custom/components/feedback/src/feedback.template.js +0 -115
- package/es-custom/components/feedback/src/feedback.template.js.map +0 -1
- package/es-custom/components/reasoning-steps/src/reasoning-steps-toggle.template.d.ts +0 -3
- package/es-custom/components/reasoning-steps/src/reasoning-steps-toggle.template.js +0 -43
- package/es-custom/components/reasoning-steps/src/reasoning-steps-toggle.template.js.map +0 -1
- package/es-custom/react/code-snippet-card.d.ts +0 -4
- package/es-custom/react/code-snippet-card.js +0 -31
- package/es-custom/react/code-snippet-card.js.map +0 -1
|
@@ -1,10 +1,16 @@
|
|
|
1
|
+
import "../../markdown/index.js";
|
|
2
|
+
import "@carbon/web-components/es-custom/components/button/index.js";
|
|
3
|
+
import "@carbon/web-components/es-custom/components/chat-button/index.js";
|
|
4
|
+
import "@carbon/web-components/es-custom/components/icon-button/index.js";
|
|
5
|
+
import "@carbon/web-components/es-custom/components/layer/index.js";
|
|
6
|
+
import "@carbon/web-components/es-custom/components/textarea/index.js";
|
|
1
7
|
import { LitElement, PropertyValues } from "lit";
|
|
2
8
|
/**
|
|
3
9
|
* The component for displaying a panel requesting feedback from a user.
|
|
4
10
|
* @element cds-aichat-feedback
|
|
5
11
|
*/
|
|
6
12
|
declare class CDSAIChatFeedback extends LitElement {
|
|
7
|
-
static styles: any;
|
|
13
|
+
static styles: any[];
|
|
8
14
|
/**
|
|
9
15
|
* The CSS class of this panel.
|
|
10
16
|
*/
|
|
@@ -30,9 +36,9 @@ declare class CDSAIChatFeedback extends LitElement {
|
|
|
30
36
|
*/
|
|
31
37
|
title: string;
|
|
32
38
|
/**
|
|
33
|
-
* The
|
|
39
|
+
* The body text to display to the user. A default value will be used if no value is provided here.
|
|
34
40
|
*/
|
|
35
|
-
|
|
41
|
+
body: string;
|
|
36
42
|
/**
|
|
37
43
|
* The list of categories to show.
|
|
38
44
|
*/
|
|
@@ -45,23 +51,27 @@ declare class CDSAIChatFeedback extends LitElement {
|
|
|
45
51
|
/**
|
|
46
52
|
* The placeholder to show in the text area. A default value will be used if no value is provided here.
|
|
47
53
|
*/
|
|
48
|
-
placeholder
|
|
54
|
+
placeholder: string;
|
|
49
55
|
/**
|
|
50
|
-
* The label for the
|
|
56
|
+
* The label for the secondary button. A default value will be used if no value is provided here.
|
|
51
57
|
*/
|
|
52
|
-
|
|
58
|
+
secondaryLabel?: string;
|
|
53
59
|
/**
|
|
54
|
-
* The label for the
|
|
60
|
+
* The label for the primary button. A default value will be used if no value is provided here.
|
|
55
61
|
*/
|
|
56
|
-
|
|
62
|
+
primaryLabel?: string;
|
|
63
|
+
/**
|
|
64
|
+
* The accessible label for the categories listbox. This label is used by screen readers to describe the purpose of the category selection list.
|
|
65
|
+
*/
|
|
66
|
+
categoriesLabel?: string;
|
|
57
67
|
/**
|
|
58
68
|
* Indicates whether the text area should be shown.
|
|
59
69
|
*/
|
|
60
70
|
showTextArea: boolean;
|
|
61
71
|
/**
|
|
62
|
-
* Indicates whether the
|
|
72
|
+
* Indicates whether the body line should be shown.
|
|
63
73
|
*/
|
|
64
|
-
|
|
74
|
+
showBody: boolean;
|
|
65
75
|
/**
|
|
66
76
|
* Called when the properties of the component have changed.
|
|
67
77
|
*/
|
|
@@ -6,11 +6,18 @@
|
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
8
|
import { __decorate } from 'tslib';
|
|
9
|
-
import
|
|
9
|
+
import '../../markdown/src/markdown.js';
|
|
10
|
+
import '@carbon/web-components/es-custom/components/button/index.js';
|
|
11
|
+
import '@carbon/web-components/es-custom/components/chat-button/index.js';
|
|
12
|
+
import '@carbon/web-components/es-custom/components/icon-button/index.js';
|
|
13
|
+
import '@carbon/web-components/es-custom/components/layer/index.js';
|
|
14
|
+
import '@carbon/web-components/es-custom/components/textarea/index.js';
|
|
15
|
+
import { LitElement, html } from 'lit';
|
|
10
16
|
import { property, state } from 'lit/decorators.js';
|
|
17
|
+
import { classMap } from 'lit/directives/class-map.js';
|
|
11
18
|
import { carbonElement } from '../../../globals/decorators/carbon-element.js';
|
|
12
|
-
import { feedbackElementTemplate } from './feedback.template.js';
|
|
13
19
|
import prefix from '../../../globals/settings.js';
|
|
20
|
+
import commonStyles from '../../../globals/scss/common.scss.js';
|
|
14
21
|
import styles from './feedback.scss.js';
|
|
15
22
|
|
|
16
23
|
/*
|
|
@@ -21,6 +28,8 @@ import styles from './feedback.scss.js';
|
|
|
21
28
|
*
|
|
22
29
|
* @license
|
|
23
30
|
*/
|
|
31
|
+
// The maximum number of characters the user is allowed to type into the text area.
|
|
32
|
+
const MAX_TEXT_COUNT = 1000;
|
|
24
33
|
/**
|
|
25
34
|
* The component for displaying a panel requesting feedback from a user.
|
|
26
35
|
* @element cds-aichat-feedback
|
|
@@ -39,19 +48,23 @@ let CDSAIChatFeedback = class CDSAIChatFeedback extends LitElement {
|
|
|
39
48
|
/**
|
|
40
49
|
* The title to display in the popup. A default value will be used if no value is provided here.
|
|
41
50
|
*/
|
|
42
|
-
this.title = "";
|
|
51
|
+
this.title = "Provide additional feedback";
|
|
43
52
|
/**
|
|
44
|
-
* The
|
|
53
|
+
* The body text to display to the user. A default value will be used if no value is provided here.
|
|
45
54
|
*/
|
|
46
|
-
this.
|
|
55
|
+
this.body = "What do you think of this response?";
|
|
56
|
+
/**
|
|
57
|
+
* The placeholder to show in the text area. A default value will be used if no value is provided here.
|
|
58
|
+
*/
|
|
59
|
+
this.placeholder = "Provide additional feedback...";
|
|
47
60
|
/**
|
|
48
61
|
* Indicates whether the text area should be shown.
|
|
49
62
|
*/
|
|
50
|
-
this.showTextArea =
|
|
63
|
+
this.showTextArea = false;
|
|
51
64
|
/**
|
|
52
|
-
* Indicates whether the
|
|
65
|
+
* Indicates whether the body line should be shown.
|
|
53
66
|
*/
|
|
54
|
-
this.
|
|
67
|
+
this.showBody = false;
|
|
55
68
|
/**
|
|
56
69
|
* Internal saved text values for feedback.
|
|
57
70
|
*
|
|
@@ -136,10 +149,88 @@ let CDSAIChatFeedback = class CDSAIChatFeedback extends LitElement {
|
|
|
136
149
|
this._selectedCategories = nextSelection;
|
|
137
150
|
}
|
|
138
151
|
render() {
|
|
139
|
-
|
|
152
|
+
const containerClasses = {
|
|
153
|
+
[`${prefix}--container`]: true,
|
|
154
|
+
[`${prefix}--is-closed`]: !this.isOpen,
|
|
155
|
+
};
|
|
156
|
+
return html `<div class="${classMap(containerClasses)}">
|
|
157
|
+
<div class="${prefix}--title-row">
|
|
158
|
+
<div class="${prefix}--title">${this.title}</div>
|
|
159
|
+
</div>
|
|
160
|
+
${this.showBody
|
|
161
|
+
? html `<div class="${prefix}--prompt">${this.body}</div>`
|
|
162
|
+
: ""}
|
|
163
|
+
${this.categories?.length
|
|
164
|
+
? html `<div class="${prefix}--categories">
|
|
165
|
+
<div
|
|
166
|
+
class="${prefix}--tag-list-container"
|
|
167
|
+
role="group"
|
|
168
|
+
aria-label="${this.categoriesLabel || "Feedback categories"}"
|
|
169
|
+
>
|
|
170
|
+
${this.categories.map((value) => html `<cds-custom-chat-button
|
|
171
|
+
class="${prefix}--tag-list-button"
|
|
172
|
+
kind="primary"
|
|
173
|
+
size="sm"
|
|
174
|
+
type="button"
|
|
175
|
+
is-quick-action
|
|
176
|
+
aria-pressed="${this._selectedCategories.has(value)}"
|
|
177
|
+
?is-selected=${this._selectedCategories.has(value)}
|
|
178
|
+
data-content="${value}"
|
|
179
|
+
?disabled=${this.isReadonly}
|
|
180
|
+
@click=${this._handleCategoryClick}
|
|
181
|
+
>
|
|
182
|
+
${value}
|
|
183
|
+
</cds-custom-chat-button>`)}
|
|
184
|
+
</div>
|
|
185
|
+
</div>`
|
|
186
|
+
: ""}
|
|
187
|
+
${this.showTextArea
|
|
188
|
+
? html `<div class="${prefix}--feedback-text">
|
|
189
|
+
<cds-custom-textarea
|
|
190
|
+
id="${this.id}-text-area"
|
|
191
|
+
value="${this._textInput}"
|
|
192
|
+
class="${prefix}--feedback-text-area"
|
|
193
|
+
?disabled=${this.isReadonly}
|
|
194
|
+
placeholder="${this.placeholder}"
|
|
195
|
+
rows="3"
|
|
196
|
+
max-count="${MAX_TEXT_COUNT}"
|
|
197
|
+
@input=${this._handleTextInput}
|
|
198
|
+
></cds-custom-textarea>
|
|
199
|
+
</div>`
|
|
200
|
+
: ""}
|
|
201
|
+
${this.disclaimer
|
|
202
|
+
? html `<div class="${prefix}--disclaimer">
|
|
203
|
+
<cds-aichat-markdown
|
|
204
|
+
.markdown=${this.disclaimer}
|
|
205
|
+
></cds-aichat-markdown>
|
|
206
|
+
</div>`
|
|
207
|
+
: ""}
|
|
208
|
+
<div class="${prefix}--buttons">
|
|
209
|
+
<div class="${prefix}--cancel" data-rounded="bottom-left">
|
|
210
|
+
<cds-custom-button
|
|
211
|
+
?disabled=${this.isReadonly}
|
|
212
|
+
size="lg"
|
|
213
|
+
kind="secondary"
|
|
214
|
+
@click=${this._handleCancel}
|
|
215
|
+
>
|
|
216
|
+
${this.secondaryLabel || "Cancel"}
|
|
217
|
+
</cds-custom-button>
|
|
218
|
+
</div>
|
|
219
|
+
<div class="${prefix}--submit" data-rounded="bottom-right">
|
|
220
|
+
<cds-custom-button
|
|
221
|
+
?disabled=${this.isReadonly}
|
|
222
|
+
size="lg"
|
|
223
|
+
kind="primary"
|
|
224
|
+
@click=${this._handleSubmit}
|
|
225
|
+
>
|
|
226
|
+
${this.primaryLabel || "Submit"}
|
|
227
|
+
</cds-custom-button>
|
|
228
|
+
</div>
|
|
229
|
+
</div>
|
|
230
|
+
</div>`;
|
|
140
231
|
}
|
|
141
232
|
};
|
|
142
|
-
CDSAIChatFeedback.styles = styles;
|
|
233
|
+
CDSAIChatFeedback.styles = [commonStyles, styles];
|
|
143
234
|
__decorate([
|
|
144
235
|
property({ type: String, attribute: "class", reflect: true })
|
|
145
236
|
], CDSAIChatFeedback.prototype, "class", void 0);
|
|
@@ -153,16 +244,16 @@ __decorate([
|
|
|
153
244
|
property({ type: Boolean, attribute: "is-readonly", reflect: true })
|
|
154
245
|
], CDSAIChatFeedback.prototype, "isReadonly", void 0);
|
|
155
246
|
__decorate([
|
|
156
|
-
property({ type: Object, attribute:
|
|
247
|
+
property({ type: Object, attribute: false, reflect: true })
|
|
157
248
|
], CDSAIChatFeedback.prototype, "initialValues", void 0);
|
|
158
249
|
__decorate([
|
|
159
250
|
property({ type: String, attribute: "title", reflect: true })
|
|
160
251
|
], CDSAIChatFeedback.prototype, "title", void 0);
|
|
161
252
|
__decorate([
|
|
162
|
-
property({ type: String, attribute: "
|
|
163
|
-
], CDSAIChatFeedback.prototype, "
|
|
253
|
+
property({ type: String, attribute: "body", reflect: true })
|
|
254
|
+
], CDSAIChatFeedback.prototype, "body", void 0);
|
|
164
255
|
__decorate([
|
|
165
|
-
property({ type: Array, attribute:
|
|
256
|
+
property({ type: Array, attribute: false, reflect: true })
|
|
166
257
|
], CDSAIChatFeedback.prototype, "categories", void 0);
|
|
167
258
|
__decorate([
|
|
168
259
|
property({ type: String, attribute: "disclaimer", reflect: true })
|
|
@@ -171,17 +262,20 @@ __decorate([
|
|
|
171
262
|
property({ type: String, attribute: "text-area-placeholder", reflect: true })
|
|
172
263
|
], CDSAIChatFeedback.prototype, "placeholder", void 0);
|
|
173
264
|
__decorate([
|
|
174
|
-
property({ type: String, attribute: "
|
|
175
|
-
], CDSAIChatFeedback.prototype, "
|
|
265
|
+
property({ type: String, attribute: "secondary-label", reflect: true })
|
|
266
|
+
], CDSAIChatFeedback.prototype, "secondaryLabel", void 0);
|
|
267
|
+
__decorate([
|
|
268
|
+
property({ type: String, attribute: "primary-label", reflect: true })
|
|
269
|
+
], CDSAIChatFeedback.prototype, "primaryLabel", void 0);
|
|
176
270
|
__decorate([
|
|
177
|
-
property({ type: String, attribute: "
|
|
178
|
-
], CDSAIChatFeedback.prototype, "
|
|
271
|
+
property({ type: String, attribute: "categories-label", reflect: true })
|
|
272
|
+
], CDSAIChatFeedback.prototype, "categoriesLabel", void 0);
|
|
179
273
|
__decorate([
|
|
180
274
|
property({ type: Boolean, attribute: "show-text-area", reflect: true })
|
|
181
275
|
], CDSAIChatFeedback.prototype, "showTextArea", void 0);
|
|
182
276
|
__decorate([
|
|
183
|
-
property({ type: Boolean, attribute: "show-
|
|
184
|
-
], CDSAIChatFeedback.prototype, "
|
|
277
|
+
property({ type: Boolean, attribute: "show-body", reflect: true })
|
|
278
|
+
], CDSAIChatFeedback.prototype, "showBody", void 0);
|
|
185
279
|
__decorate([
|
|
186
280
|
state()
|
|
187
281
|
], CDSAIChatFeedback.prototype, "_textInput", void 0);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"feedback.js","sources":["../../../../src/components/feedback/src/feedback.ts"],"sourcesContent":[null],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"feedback.js","sources":["../../../../src/components/feedback/src/feedback.ts"],"sourcesContent":[null],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAAA;;;;;;;AAOG;AAiBH;AACA,MAAM,cAAc,GAAG,IAAI;AAE3B;;;AAGG;AAEH,IAAM,iBAAiB,GAAvB,MAAM,iBAAkB,SAAQ,UAAU,CAAA;AAA1C,IAAA,WAAA,GAAA;;AAeE;;AAEG;QAEH,IAAA,CAAA,MAAM,GAAG,KAAK;AAEd;;AAEG;QAEH,IAAA,CAAA,UAAU,GAAG,KAAK;AAQlB;;AAEG;QAEH,IAAA,CAAA,KAAK,GAAG,6BAA6B;AAErC;;AAEG;QAEH,IAAA,CAAA,IAAI,GAAG,qCAAqC;AAe5C;;AAEG;QAEH,IAAA,CAAA,WAAW,GAAG,gCAAgC;AAoB9C;;AAEG;QAEH,IAAA,CAAA,YAAY,GAAG,KAAK;AAEpB;;AAEG;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CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,SAAS,EAAE,kBAAkB,EAAE,OAAO,EAAE,IAAI,EAAE;AAC/C,CAAA,EAAA,iBAAA,CAAA,SAAA,EAAA,iBAAA,EAAA,MAAA,CAAA;AAMzB,UAAA,CAAA;AADC,IAAA,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,SAAS,EAAE,gBAAgB,EAAE,OAAO,EAAE,IAAI,EAAE;AAClD,CAAA,EAAA,iBAAA,CAAA,SAAA,EAAA,cAAA,EAAA,MAAA,CAAA;AAMrB,UAAA,CAAA;AADC,IAAA,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,SAAS,EAAE,WAAW,EAAE,OAAO,EAAE,IAAI,EAAE;AACjD,CAAA,EAAA,iBAAA,CAAA,SAAA,EAAA,UAAA,EAAA,MAAA,CAAA;AAQjB,UAAA,CAAA;AADC,IAAA,KAAK;AACU,CAAA,EAAA,iBAAA,CAAA,SAAA,EAAA,YAAA,EAAA,MAAA,CAAA;AAQhB,UAAA,CAAA;AADC,IAAA,KAAK;AACuC,CAAA,EAAA,iBAAA,CAAA,SAAA,EAAA,qBAAA,EAAA,MAAA,CAAA;AA5GzC,iBAAiB,GAAA,UAAA,CAAA;AADtB,IAAA,aAAa,CAAC,CAAA,EAAG,MAAM,CAAA,SAAA,CAAW;AAC7B,CAAA,EAAA,iBAAiB,CAoRtB;AAiCD,+BAAe,iBAAiB;;;;"}
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
|
|
8
8
|
import { css } from 'lit';
|
|
9
9
|
|
|
10
|
-
var styles = css([":host(cds-aichat-feedback) :host([data-rounded=\"\"]),:host(cds-aichat-feedback) [data-rounded=\"\"]{border-radius:calc(var(--cds-aichat-rounded-modifier-radius) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=\"\"])::part(button),:host(cds-aichat-feedback) :host([data-rounded=\"\"])::part(link),:host(cds-aichat-feedback) [data-rounded=\"\"]::part(button),:host(cds-aichat-feedback) [data-rounded=\"\"]::part(link){border-radius:calc(var(--cds-aichat-rounded-modifier-radius) - .0625rem);outline-offset:-.0625rem}:host(cds-aichat-feedback) :host([data-rounded=\"\"])>:only-child,:host(cds-aichat-feedback) [data-rounded=\"\"]>:only-child{border-radius:calc(var(--cds-aichat-rounded-modifier-radius) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top]),:host(cds-aichat-feedback) [data-rounded=top]{border-start-end-radius:calc(var(--cds-aichat-rounded-modifier-radius-start-end, var(--cds-aichat-rounded-modifier-radius)) - .0625rem);border-start-start-radius:calc(var(--cds-aichat-rounded-modifier-radius-start-start, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top-left]),:host(cds-aichat-feedback) [data-rounded=top-left]{border-start-start-radius:calc(var(--cds-aichat-rounded-modifier-radius-start-start, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top-right]),:host(cds-aichat-feedback) [data-rounded=top-right]{border-start-end-radius:calc(var(--cds-aichat-rounded-modifier-radius-start-end, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom]),:host(cds-aichat-feedback) [data-rounded=bottom]{border-end-end-radius:calc(var(--cds-aichat-rounded-modifier-radius-end-end, var(--cds-aichat-rounded-modifier-radius)) - .0625rem);border-end-start-radius:calc(var(--cds-aichat-rounded-modifier-radius-end-start, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom-left]),:host(cds-aichat-feedback) [data-rounded=bottom-left]{border-end-start-radius:calc(var(--cds-aichat-rounded-modifier-radius-end-start, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom-right]),:host(cds-aichat-feedback) [data-rounded=bottom-right]{border-end-end-radius:calc(var(--cds-aichat-rounded-modifier-radius-end-end, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top]:not([data-stacked]))>:first-child,:host(cds-aichat-feedback) [data-rounded=top]:not([data-stacked])>:first-child{border-start-start-radius:calc(var(--cds-aichat-rounded-modifier-radius-start-start, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top]:not([data-stacked]))>:first-child::part(button),:host(cds-aichat-feedback) [data-rounded=top]:not([data-stacked])>:first-child::part(button){border-start-start-radius:calc(var(--cds-aichat-rounded-modifier-radius-start-start, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top]:not([data-stacked]))>:last-child,:host(cds-aichat-feedback) [data-rounded=top]:not([data-stacked])>:last-child{border-start-end-radius:calc(var(--cds-aichat-rounded-modifier-radius-start-end, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top]:not([data-stacked]))>:last-child::part(button),:host(cds-aichat-feedback) [data-rounded=top]:not([data-stacked])>:last-child::part(button){border-start-end-radius:calc(var(--cds-aichat-rounded-modifier-radius-start-end, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top-left]:not([data-stacked]))>:first-child,:host(cds-aichat-feedback) [data-rounded=top-left]:not([data-stacked])>:first-child{border-start-start-radius:calc(var(--cds-aichat-rounded-modifier-radius-start-start, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top-left]:not([data-stacked]))>:first-child::part(button),:host(cds-aichat-feedback) [data-rounded=top-left]:not([data-stacked])>:first-child::part(button){border-start-start-radius:calc(var(--cds-aichat-rounded-modifier-radius-start-start, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top-right]:not([data-stacked]))>:last-child,:host(cds-aichat-feedback) [data-rounded=top-right]:not([data-stacked])>:last-child{border-start-end-radius:calc(var(--cds-aichat-rounded-modifier-radius-start-end, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top-right]:not([data-stacked]))>:last-child::part(button),:host(cds-aichat-feedback) [data-rounded=top-right]:not([data-stacked])>:last-child::part(button){border-start-end-radius:calc(var(--cds-aichat-rounded-modifier-radius-start-end, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom]:not([data-stacked]))>:first-child,:host(cds-aichat-feedback) [data-rounded=bottom]:not([data-stacked])>:first-child{border-end-start-radius:calc(var(--cds-aichat-rounded-modifier-radius-end-start, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom]:not([data-stacked]))>:first-child::part(button),:host(cds-aichat-feedback) [data-rounded=bottom]:not([data-stacked])>:first-child::part(button){border-end-start-radius:calc(var(--cds-aichat-rounded-modifier-radius-end-start, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom]:not([data-stacked]))>:last-child,:host(cds-aichat-feedback) [data-rounded=bottom]:not([data-stacked])>:last-child{border-end-end-radius:calc(var(--cds-aichat-rounded-modifier-radius-end-end, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom]:not([data-stacked]))>:last-child::part(button),:host(cds-aichat-feedback) [data-rounded=bottom]:not([data-stacked])>:last-child::part(button){border-end-end-radius:calc(var(--cds-aichat-rounded-modifier-radius-end-end, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom-left]:not([data-stacked]))>:first-child,:host(cds-aichat-feedback) [data-rounded=bottom-left]:not([data-stacked])>:first-child{border-end-start-radius:calc(var(--cds-aichat-rounded-modifier-radius-end-start, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom-left]:not([data-stacked]))>:first-child::part(button),:host(cds-aichat-feedback) [data-rounded=bottom-left]:not([data-stacked])>:first-child::part(button){border-end-start-radius:calc(var(--cds-aichat-rounded-modifier-radius-end-start, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom-right]:not([data-stacked]))>:last-child,:host(cds-aichat-feedback) [data-rounded=bottom-right]:not([data-stacked])>:last-child{border-end-end-radius:calc(var(--cds-aichat-rounded-modifier-radius-end-end, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom-right]:not([data-stacked]))>:last-child::part(button),:host(cds-aichat-feedback) [data-rounded=bottom-right]:not([data-stacked])>:last-child::part(button){border-end-end-radius:calc(var(--cds-aichat-rounded-modifier-radius-end-end, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top][data-stacked])>:first-child,:host(cds-aichat-feedback) [data-rounded=top][data-stacked]>:first-child{border-start-end-radius:calc(var(--cds-aichat-rounded-modifier-radius-start-end, var(--cds-aichat-rounded-modifier-radius)) - .0625rem);border-start-start-radius:calc(var(--cds-aichat-rounded-modifier-radius-start-start, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top][data-stacked])>:first-child::part(button),:host(cds-aichat-feedback) [data-rounded=top][data-stacked]>:first-child::part(button){border-start-end-radius:calc(var(--cds-aichat-rounded-modifier-radius-start-end, var(--cds-aichat-rounded-modifier-radius)) - .0625rem);border-start-start-radius:calc(var(--cds-aichat-rounded-modifier-radius-start-start, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top-right][data-stacked])>:first-child,:host(cds-aichat-feedback) [data-rounded=top-right][data-stacked]>:first-child{border-start-end-radius:calc(var(--cds-aichat-rounded-modifier-radius-start-end, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top-right][data-stacked])>:first-child::part(button),:host(cds-aichat-feedback) [data-rounded=top-right][data-stacked]>:first-child::part(button){border-start-end-radius:calc(var(--cds-aichat-rounded-modifier-radius-start-end, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top-left][data-stacked])>:first-child,:host(cds-aichat-feedback) [data-rounded=top-left][data-stacked]>:first-child{border-start-start-radius:calc(var(--cds-aichat-rounded-modifier-radius-start-start, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top-left][data-stacked])>:first-child::part(button),:host(cds-aichat-feedback) [data-rounded=top-left][data-stacked]>:first-child::part(button){border-start-start-radius:calc(var(--cds-aichat-rounded-modifier-radius-start-start, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom][data-stacked])>:last-child,:host(cds-aichat-feedback) [data-rounded=bottom][data-stacked]>:last-child{border-end-end-radius:calc(var(--cds-aichat-rounded-modifier-radius-end-end, var(--cds-aichat-rounded-modifier-radius)) - .0625rem);border-end-start-radius:calc(var(--cds-aichat-rounded-modifier-radius-end-start, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom][data-stacked])>:last-child::part(button),:host(cds-aichat-feedback) [data-rounded=bottom][data-stacked]>:last-child::part(button){border-end-end-radius:calc(var(--cds-aichat-rounded-modifier-radius-end-end, var(--cds-aichat-rounded-modifier-radius)) - .0625rem);border-end-start-radius:calc(var(--cds-aichat-rounded-modifier-radius-end-start, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom-right][data-stacked])>:last-child,:host(cds-aichat-feedback) [data-rounded=bottom-right][data-stacked]>:last-child{border-end-end-radius:calc(var(--cds-aichat-rounded-modifier-radius-end-end, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom-right][data-stacked])>:last-child::part(button),:host(cds-aichat-feedback) [data-rounded=bottom-right][data-stacked]>:last-child::part(button){border-end-end-radius:calc(var(--cds-aichat-rounded-modifier-radius-end-end, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom-left][data-stacked])>:last-child,:host(cds-aichat-feedback) [data-rounded=bottom-left][data-stacked]>:last-child{border-end-start-radius:calc(var(--cds-aichat-rounded-modifier-radius-end-start, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom-left][data-stacked])>:last-child::part(button),:host(cds-aichat-feedback) [data-rounded=bottom-left][data-stacked]>:last-child::part(button){border-end-start-radius:calc(var(--cds-aichat-rounded-modifier-radius-end-start, var(--cds-aichat-rounded-modifier-radius)) - .0625rem)}:host(cds-aichat-feedback){--cds-aichat-rounded-modifier-radius:var(\n --cds-aichat-card-border-radius,0.5rem\n )}.cds-aichat--container{animation:cds-aichat-fade-in .6s forwards;background-color:var(--cds-chat-shell-background,#fff);border:1px solid var(--cds-chat-bubble-border,#e0e0e0);border-radius:var(--cds-aichat-rounded-modifier-radius);box-sizing:border-box;container-type:inline-size;inline-size:100%;margin-block-start:.25rem}.cds-aichat--is-closed{display:none}.cds-aichat--title-row{display:flex;margin-block-start:.75rem;margin-inline:1rem .5rem}.cds-aichat--title{flex:1;font-size:var(--cds-heading-compact-01-font-size,.875rem);font-weight:var(--cds-heading-compact-01-font-weight,600);letter-spacing:var(--cds-heading-compact-01-letter-spacing,.16px);line-height:var(--cds-heading-compact-01-line-height,1.28572)}.cds-aichat--close{margin-inline-start:.5rem}.cds-aichat--disclaimer,.cds-aichat--prompt{color:var(--cds-text-secondary,#525252);font-size:var(--cds-body-compact-01-font-size,.875rem);font-weight:var(--cds-body-compact-01-font-weight,400);letter-spacing:var(--cds-body-compact-01-letter-spacing,.16px);line-height:var(--cds-body-compact-01-line-height,1.28572);margin-block-start:.5rem;margin-inline:1rem}.cds-aichat--categories{margin-block-start:.5rem;margin-inline:1rem}.cds-aichat--tag-list-container{align-items:center;display:flex;flex-wrap:wrap;gap:.5rem;list-style:none;margin:0;padding:0}.cds-aichat--feedback-text{margin-block-start:.5rem;margin-inline:1rem}.cds-aichat--buttons{display:flex;inline-size:100%;margin-block-start:1rem}.cds-aichat--cancel,.cds-aichat--submit{align-items:stretch;display:flex;flex:1;min-inline-size:0;overflow:hidden}.cds-aichat--submit{border-end-end-radius:.5rem}.cds-aichat--cancel{border-end-start-radius:.5rem}.cds-aichat--cancel cds-custom-button,.cds-aichat--submit cds-custom-button{flex:1;inline-size:100%}"]);
|
|
10
|
+
var styles = css([":host(cds-aichat-feedback) :host([data-rounded=\"\"]),:host(cds-aichat-feedback) [data-rounded=\"\"]{border-end-end-radius:calc(var(--cds-aichat-border-radius-end-end, var(--cds-aichat-border-radius)) - .0625rem);border-end-start-radius:calc(var(--cds-aichat-border-radius-end-start, var(--cds-aichat-border-radius)) - .0625rem);border-start-end-radius:calc(var(--cds-aichat-border-radius-start-end, var(--cds-aichat-border-radius)) - .0625rem);border-start-start-radius:calc(var(--cds-aichat-border-radius-start-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=\"\"])::part(button),:host(cds-aichat-feedback) :host([data-rounded=\"\"])::part(link),:host(cds-aichat-feedback) [data-rounded=\"\"]::part(button),:host(cds-aichat-feedback) [data-rounded=\"\"]::part(link){border-end-end-radius:calc(var(--cds-aichat-border-radius-end-end, var(--cds-aichat-border-radius)) - .0625rem);border-end-start-radius:calc(var(--cds-aichat-border-radius-end-start, var(--cds-aichat-border-radius)) - .0625rem);border-start-end-radius:calc(var(--cds-aichat-border-radius-start-end, var(--cds-aichat-border-radius)) - .0625rem);border-start-start-radius:calc(var(--cds-aichat-border-radius-start-start, var(--cds-aichat-border-radius)) - .0625rem);outline-offset:-.0625rem}:host(cds-aichat-feedback) :host([data-rounded=\"\"])>:only-child,:host(cds-aichat-feedback) [data-rounded=\"\"]>:only-child{border-end-end-radius:calc(var(--cds-aichat-border-radius-end-end, var(--cds-aichat-border-radius)) - .0625rem);border-end-start-radius:calc(var(--cds-aichat-border-radius-end-start, var(--cds-aichat-border-radius)) - .0625rem);border-start-end-radius:calc(var(--cds-aichat-border-radius-start-end, var(--cds-aichat-border-radius)) - .0625rem);border-start-start-radius:calc(var(--cds-aichat-border-radius-start-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top]),:host(cds-aichat-feedback) [data-rounded=top]{border-start-end-radius:calc(var(--cds-aichat-border-radius-start-end, var(--cds-aichat-border-radius)) - .0625rem);border-start-start-radius:calc(var(--cds-aichat-border-radius-start-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top-left]),:host(cds-aichat-feedback) [data-rounded=top-left]{border-start-start-radius:calc(var(--cds-aichat-border-radius-start-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top-right]),:host(cds-aichat-feedback) [data-rounded=top-right]{border-start-end-radius:calc(var(--cds-aichat-border-radius-start-end, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom]),:host(cds-aichat-feedback) [data-rounded=bottom]{border-end-end-radius:calc(var(--cds-aichat-border-radius-end-end, var(--cds-aichat-border-radius)) - .0625rem);border-end-start-radius:calc(var(--cds-aichat-border-radius-end-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom-left]),:host(cds-aichat-feedback) [data-rounded=bottom-left]{border-end-start-radius:calc(var(--cds-aichat-border-radius-end-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom-right]),:host(cds-aichat-feedback) [data-rounded=bottom-right]{border-end-end-radius:calc(var(--cds-aichat-border-radius-end-end, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top]:not([data-stacked]))>:first-child,:host(cds-aichat-feedback) [data-rounded=top]:not([data-stacked])>:first-child{border-start-start-radius:calc(var(--cds-aichat-border-radius-start-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top]:not([data-stacked]))>:first-child::part(button),:host(cds-aichat-feedback) [data-rounded=top]:not([data-stacked])>:first-child::part(button){border-start-start-radius:calc(var(--cds-aichat-border-radius-start-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top]:not([data-stacked]))>:last-child,:host(cds-aichat-feedback) [data-rounded=top]:not([data-stacked])>:last-child{border-start-end-radius:calc(var(--cds-aichat-border-radius-start-end, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top]:not([data-stacked]))>:last-child::part(button),:host(cds-aichat-feedback) [data-rounded=top]:not([data-stacked])>:last-child::part(button){border-start-end-radius:calc(var(--cds-aichat-border-radius-start-end, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top-left]:not([data-stacked]))>:first-child,:host(cds-aichat-feedback) [data-rounded=top-left]:not([data-stacked])>:first-child{border-start-start-radius:calc(var(--cds-aichat-border-radius-start-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top-left]:not([data-stacked]))>:first-child::part(button),:host(cds-aichat-feedback) [data-rounded=top-left]:not([data-stacked])>:first-child::part(button){border-start-start-radius:calc(var(--cds-aichat-border-radius-start-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top-right]:not([data-stacked]))>:last-child,:host(cds-aichat-feedback) [data-rounded=top-right]:not([data-stacked])>:last-child{border-start-end-radius:calc(var(--cds-aichat-border-radius-start-end, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top-right]:not([data-stacked]))>:last-child::part(button),:host(cds-aichat-feedback) [data-rounded=top-right]:not([data-stacked])>:last-child::part(button){border-start-end-radius:calc(var(--cds-aichat-border-radius-start-end, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom]:not([data-stacked]))>:first-child,:host(cds-aichat-feedback) [data-rounded=bottom]:not([data-stacked])>:first-child{border-end-start-radius:calc(var(--cds-aichat-border-radius-end-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom]:not([data-stacked]))>:first-child::part(button),:host(cds-aichat-feedback) [data-rounded=bottom]:not([data-stacked])>:first-child::part(button){border-end-start-radius:calc(var(--cds-aichat-border-radius-end-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom]:not([data-stacked]))>:last-child,:host(cds-aichat-feedback) [data-rounded=bottom]:not([data-stacked])>:last-child{border-end-end-radius:calc(var(--cds-aichat-border-radius-end-end, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom]:not([data-stacked]))>:last-child::part(button),:host(cds-aichat-feedback) [data-rounded=bottom]:not([data-stacked])>:last-child::part(button){border-end-end-radius:calc(var(--cds-aichat-border-radius-end-end, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom-left]:not([data-stacked]))>:first-child,:host(cds-aichat-feedback) [data-rounded=bottom-left]:not([data-stacked])>:first-child{border-end-start-radius:calc(var(--cds-aichat-border-radius-end-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom-left]:not([data-stacked]))>:first-child::part(button),:host(cds-aichat-feedback) [data-rounded=bottom-left]:not([data-stacked])>:first-child::part(button){border-end-start-radius:calc(var(--cds-aichat-border-radius-end-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom-right]:not([data-stacked]))>:last-child,:host(cds-aichat-feedback) [data-rounded=bottom-right]:not([data-stacked])>:last-child{border-end-end-radius:calc(var(--cds-aichat-border-radius-end-end, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom-right]:not([data-stacked]))>:last-child::part(button),:host(cds-aichat-feedback) [data-rounded=bottom-right]:not([data-stacked])>:last-child::part(button){border-end-end-radius:calc(var(--cds-aichat-border-radius-end-end, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top][data-stacked])>:first-child,:host(cds-aichat-feedback) [data-rounded=top][data-stacked]>:first-child{border-start-end-radius:calc(var(--cds-aichat-border-radius-start-end, var(--cds-aichat-border-radius)) - .0625rem);border-start-start-radius:calc(var(--cds-aichat-border-radius-start-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top][data-stacked])>:first-child::part(button),:host(cds-aichat-feedback) [data-rounded=top][data-stacked]>:first-child::part(button){border-start-end-radius:calc(var(--cds-aichat-border-radius-start-end, var(--cds-aichat-border-radius)) - .0625rem);border-start-start-radius:calc(var(--cds-aichat-border-radius-start-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top-right][data-stacked])>:first-child,:host(cds-aichat-feedback) [data-rounded=top-right][data-stacked]>:first-child{border-start-end-radius:calc(var(--cds-aichat-border-radius-start-end, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top-right][data-stacked])>:first-child::part(button),:host(cds-aichat-feedback) [data-rounded=top-right][data-stacked]>:first-child::part(button){border-start-end-radius:calc(var(--cds-aichat-border-radius-start-end, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top-left][data-stacked])>:first-child,:host(cds-aichat-feedback) [data-rounded=top-left][data-stacked]>:first-child{border-start-start-radius:calc(var(--cds-aichat-border-radius-start-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=top-left][data-stacked])>:first-child::part(button),:host(cds-aichat-feedback) [data-rounded=top-left][data-stacked]>:first-child::part(button){border-start-start-radius:calc(var(--cds-aichat-border-radius-start-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom][data-stacked])>:last-child,:host(cds-aichat-feedback) [data-rounded=bottom][data-stacked]>:last-child{border-end-end-radius:calc(var(--cds-aichat-border-radius-end-end, var(--cds-aichat-border-radius)) - .0625rem);border-end-start-radius:calc(var(--cds-aichat-border-radius-end-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom][data-stacked])>:last-child::part(button),:host(cds-aichat-feedback) [data-rounded=bottom][data-stacked]>:last-child::part(button){border-end-end-radius:calc(var(--cds-aichat-border-radius-end-end, var(--cds-aichat-border-radius)) - .0625rem);border-end-start-radius:calc(var(--cds-aichat-border-radius-end-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom-right][data-stacked])>:last-child,:host(cds-aichat-feedback) [data-rounded=bottom-right][data-stacked]>:last-child{border-end-end-radius:calc(var(--cds-aichat-border-radius-end-end, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom-right][data-stacked])>:last-child::part(button),:host(cds-aichat-feedback) [data-rounded=bottom-right][data-stacked]>:last-child::part(button){border-end-end-radius:calc(var(--cds-aichat-border-radius-end-end, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom-left][data-stacked])>:last-child,:host(cds-aichat-feedback) [data-rounded=bottom-left][data-stacked]>:last-child{border-end-start-radius:calc(var(--cds-aichat-border-radius-end-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback) :host([data-rounded=bottom-left][data-stacked])>:last-child::part(button),:host(cds-aichat-feedback) [data-rounded=bottom-left][data-stacked]>:last-child::part(button){border-end-start-radius:calc(var(--cds-aichat-border-radius-end-start, var(--cds-aichat-border-radius)) - .0625rem)}:host(cds-aichat-feedback){--cds-aichat-border-radius-start-start:0.5rem;--cds-aichat-border-radius-start-end:0.5rem;--cds-aichat-border-radius-end-start:0.5rem;--cds-aichat-border-radius-end-end:0.5rem}.cds-aichat--container{animation:cds-aichat-fade-in .6s forwards;background-color:var(--cds-chat-shell-background,#fff);border:1px solid var(--cds-chat-bubble-border,#e0e0e0);border-end-end-radius:var(--cds-aichat-border-radius-end-end,0);border-end-start-radius:var(--cds-aichat-border-radius-end-start,0);border-start-end-radius:var(--cds-aichat-border-radius-start-end,0);border-start-start-radius:var(--cds-aichat-border-radius-start-start,0);box-sizing:border-box;container-type:inline-size;inline-size:100%;margin-block-start:.25rem}.cds-aichat--is-closed{display:none}.cds-aichat--title-row{display:flex;margin-block-start:.75rem;margin-inline:1rem .5rem}.cds-aichat--title{flex:1;font-size:var(--cds-heading-compact-01-font-size,.875rem);font-weight:var(--cds-heading-compact-01-font-weight,600);letter-spacing:var(--cds-heading-compact-01-letter-spacing,.16px);line-height:var(--cds-heading-compact-01-line-height,1.28572)}.cds-aichat--close{margin-inline-start:.5rem}.cds-aichat--disclaimer,.cds-aichat--prompt{color:var(--cds-text-secondary,#525252);font-size:var(--cds-body-compact-01-font-size,.875rem);font-weight:var(--cds-body-compact-01-font-weight,400);letter-spacing:var(--cds-body-compact-01-letter-spacing,.16px);line-height:var(--cds-body-compact-01-line-height,1.28572);margin-block-start:.5rem;margin-inline:1rem}.cds-aichat--categories{margin-block-start:.5rem;margin-inline:1rem}.cds-aichat--tag-list-container{align-items:center;display:flex;flex-wrap:wrap;gap:.5rem}.cds-aichat--feedback-text{margin-block-start:.5rem;margin-inline:1rem}.cds-aichat--buttons{display:flex;inline-size:100%;margin-block-start:1rem}.cds-aichat--cancel,.cds-aichat--submit{align-items:stretch;display:flex;flex:1;min-inline-size:0;overflow:hidden}.cds-aichat--submit{border-end-end-radius:.5rem}.cds-aichat--cancel{border-end-start-radius:.5rem}.cds-aichat--cancel cds-custom-button,.cds-aichat--submit cds-custom-button{flex:1;inline-size:100%}"]);
|
|
11
11
|
|
|
12
12
|
export { styles as default };
|
|
13
13
|
//# sourceMappingURL=feedback.scss.js.map
|
|
@@ -2,6 +2,7 @@ import { TemplateResult } from "lit";
|
|
|
2
2
|
import "@carbon/web-components/es-custom/components/list/index.js";
|
|
3
3
|
import "@carbon/web-components/es-custom/components/checkbox/index.js";
|
|
4
4
|
import "../../code-snippet/index.js";
|
|
5
|
+
import "../../card/index.js";
|
|
5
6
|
import "../../table/index.js";
|
|
6
7
|
import type { TokenTree } from "./markdown-token-tree.js";
|
|
7
8
|
/**
|
|
@@ -22,43 +23,52 @@ export interface RenderTokenTreeOptions {
|
|
|
22
23
|
currentIndex?: number;
|
|
23
24
|
};
|
|
24
25
|
/** Whether to enable syntax highlighting in code blocks */
|
|
25
|
-
|
|
26
|
+
codeSnippetHighlight?: boolean;
|
|
27
|
+
/** Feedback text shown after copying */
|
|
28
|
+
codeSnippetFeedback?: string;
|
|
29
|
+
/** Text for show less button */
|
|
30
|
+
codeSnippetShowLessText?: string;
|
|
31
|
+
/** Text for show more button */
|
|
32
|
+
codeSnippetShowMoreText?: string;
|
|
33
|
+
/** Tooltip text for copy button */
|
|
34
|
+
codeSnippetCopyButtonTooltipContent?: string;
|
|
35
|
+
/** Function to get formatted line count text */
|
|
36
|
+
codeSnippetGetLineCountText?: ({ count }: {
|
|
37
|
+
count: number;
|
|
38
|
+
}) => string;
|
|
39
|
+
/** Aria-label for code snippets when in read-only mode */
|
|
40
|
+
codeSnippetAriaLabelReadOnly?: string;
|
|
41
|
+
/** Aria-label for code snippets when in editable mode */
|
|
42
|
+
codeSnippetAriaLabelEditable?: string;
|
|
26
43
|
/** Placeholder text for table filter input */
|
|
27
|
-
|
|
44
|
+
tableFilterPlaceholderText?: string;
|
|
28
45
|
/** Text for previous page button tooltip */
|
|
29
|
-
|
|
46
|
+
tablePreviousPageText?: string;
|
|
30
47
|
/** Text for next page button tooltip */
|
|
31
|
-
|
|
48
|
+
tableNextPageText?: string;
|
|
32
49
|
/** Text for items per page label */
|
|
33
|
-
|
|
50
|
+
tableItemsPerPageText?: string;
|
|
34
51
|
/**
|
|
35
52
|
* The text used for the download button's accessible label.
|
|
36
53
|
*/
|
|
37
|
-
|
|
54
|
+
tableDownloadLabelText?: string;
|
|
38
55
|
/** Locale for table sorting and formatting */
|
|
39
|
-
|
|
56
|
+
tableLocale?: string;
|
|
40
57
|
/** Function to get supplemental pagination text */
|
|
41
|
-
|
|
58
|
+
tableGetPaginationSupplementalText?: ({ count }: {
|
|
42
59
|
count: number;
|
|
43
60
|
}) => string;
|
|
44
61
|
/** Function to get pagination status text */
|
|
45
|
-
|
|
62
|
+
tableGetPaginationStatusText?: ({ start, end, count, }: {
|
|
46
63
|
start: number;
|
|
47
64
|
end: number;
|
|
48
65
|
count: number;
|
|
49
66
|
}) => string;
|
|
50
|
-
/**
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
showMoreText?: string;
|
|
56
|
-
/** Tooltip text for copy button */
|
|
57
|
-
tooltipContent?: string;
|
|
58
|
-
/** Function to get formatted line count text */
|
|
59
|
-
getLineCountText?: ({ count }: {
|
|
60
|
-
count: number;
|
|
61
|
-
}) => string;
|
|
67
|
+
/**
|
|
68
|
+
* Force markdown tables to render in loading mode.
|
|
69
|
+
* Useful for freezing streaming table visuals until stream completion.
|
|
70
|
+
*/
|
|
71
|
+
forceTableLoading?: boolean;
|
|
62
72
|
}
|
|
63
73
|
/**
|
|
64
74
|
* Converts TokenTree to Lit TemplateResult.
|
|
@@ -12,11 +12,14 @@ import { unsafeHTML } from 'lit/directives/unsafe-html.js';
|
|
|
12
12
|
import { directive, Directive } from 'lit/directive.js';
|
|
13
13
|
import '@carbon/web-components/es-custom/components/list/index.js';
|
|
14
14
|
import '@carbon/web-components/es-custom/components/checkbox/index.js';
|
|
15
|
-
import '../../code-snippet/src/code-snippet
|
|
15
|
+
import '../../code-snippet/src/code-snippet.js';
|
|
16
16
|
import '@carbon/web-components/es-custom/components/code-snippet/defs.js';
|
|
17
|
+
import '../../card/src/card.js';
|
|
18
|
+
import '../../card/src/card-footer.js';
|
|
19
|
+
import '../../card/src/card-steps.js';
|
|
17
20
|
import '../../table/src/table.js';
|
|
18
21
|
import { defaultLineCountText } from '../../code-snippet/src/formatters.js';
|
|
19
|
-
import { extractTableData
|
|
22
|
+
import { extractTableData } from './utils/table-helpers.js';
|
|
20
23
|
import { combineConsecutiveHtmlInline } from './utils/html-helpers.js';
|
|
21
24
|
|
|
22
25
|
/*
|
|
@@ -49,9 +52,6 @@ class SpreadAttrs extends Directive {
|
|
|
49
52
|
}
|
|
50
53
|
}
|
|
51
54
|
const spread = directive(SpreadAttrs);
|
|
52
|
-
const EMPTY_ATTRS = {};
|
|
53
|
-
const EMPTY_TABLE_HEADERS = [];
|
|
54
|
-
const EMPTY_TABLE_ROWS = [];
|
|
55
55
|
/**
|
|
56
56
|
* Converts TokenTree to Lit TemplateResult.
|
|
57
57
|
*/
|
|
@@ -84,17 +84,23 @@ function renderTokenTree(node, options) {
|
|
|
84
84
|
// Handle fenced code blocks
|
|
85
85
|
if (token.type === "fence") {
|
|
86
86
|
const language = token.info?.trim() ?? "";
|
|
87
|
-
const {
|
|
88
|
-
return html `<cds-aichat-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
87
|
+
const { codeSnippetHighlight = true, codeSnippetShowLessText, codeSnippetShowMoreText, codeSnippetCopyButtonTooltipContent, codeSnippetGetLineCountText = defaultLineCountText, codeSnippetAriaLabelReadOnly, codeSnippetAriaLabelEditable, } = options;
|
|
88
|
+
return html `<cds-aichat-card is-flush>
|
|
89
|
+
<div slot="body">
|
|
90
|
+
<cds-aichat-code-snippet
|
|
91
|
+
data-rounded
|
|
92
|
+
.language=${language}
|
|
93
|
+
.highlight=${codeSnippetHighlight}
|
|
94
|
+
.showLessText=${codeSnippetShowLessText}
|
|
95
|
+
.showMoreText=${codeSnippetShowMoreText}
|
|
96
|
+
.copyButtonTooltipContent=${codeSnippetCopyButtonTooltipContent}
|
|
97
|
+
.getLineCountText=${codeSnippetGetLineCountText}
|
|
98
|
+
.ariaLabelReadOnly=${codeSnippetAriaLabelReadOnly}
|
|
99
|
+
.ariaLabelEditable=${codeSnippetAriaLabelEditable}
|
|
100
|
+
.code=${token.content}
|
|
101
|
+
></cds-aichat-code-snippet>
|
|
102
|
+
</div>
|
|
103
|
+
</cds-aichat-card>`;
|
|
98
104
|
}
|
|
99
105
|
// Handle structural elements (paragraphs, headings, lists, etc.)
|
|
100
106
|
const tag = token.tag;
|
|
@@ -138,14 +144,18 @@ function renderTokenTree(node, options) {
|
|
|
138
144
|
return `table-${stableKey}`;
|
|
139
145
|
}
|
|
140
146
|
return `stable-${stableKey}`;
|
|
141
|
-
}, (c, index) =>
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
147
|
+
}, (c, index) => {
|
|
148
|
+
const result = renderTokenTree(c, {
|
|
149
|
+
...options,
|
|
150
|
+
context: {
|
|
151
|
+
...childContext,
|
|
152
|
+
parentChildren: normalizedChildren,
|
|
153
|
+
currentIndex: index,
|
|
154
|
+
},
|
|
155
|
+
});
|
|
156
|
+
// Ensure we never return undefined, which Lit would render as the string "undefined"
|
|
157
|
+
return result ?? html ``;
|
|
158
|
+
})}`;
|
|
149
159
|
}
|
|
150
160
|
// Handle tokens without HTML tags (just return content)
|
|
151
161
|
if (!tag) {
|
|
@@ -289,10 +299,11 @@ function renderWithStaticTag(tag, token, content, attrs, options, _context, node
|
|
|
289
299
|
if (!node) {
|
|
290
300
|
return html `<div>Error: Missing table data</div>`;
|
|
291
301
|
}
|
|
292
|
-
const { streaming, context: parentContext,
|
|
302
|
+
const { streaming, forceTableLoading, context: parentContext, tableFilterPlaceholderText, tablePreviousPageText, tableNextPageText, tableItemsPerPageText, tableDownloadLabelText, tableLocale, tableGetPaginationSupplementalText, tableGetPaginationStatusText, } = options;
|
|
293
303
|
// Determine if we should show loading state during streaming
|
|
294
|
-
let isLoading =
|
|
295
|
-
if (
|
|
304
|
+
let isLoading = Boolean(forceTableLoading);
|
|
305
|
+
if (!isLoading &&
|
|
306
|
+
streaming &&
|
|
296
307
|
parentContext?.parentChildren &&
|
|
297
308
|
parentContext?.currentIndex !== undefined) {
|
|
298
309
|
const { parentChildren, currentIndex } = parentContext;
|
|
@@ -314,9 +325,10 @@ function renderWithStaticTag(tag, token, content, attrs, options, _context, node
|
|
|
314
325
|
? renderCellTokens(cell.tokens, contextOverrides)
|
|
315
326
|
: null,
|
|
316
327
|
});
|
|
317
|
-
//
|
|
318
|
-
|
|
319
|
-
let
|
|
328
|
+
// Only extract and process table data when not loading to avoid unnecessary work.
|
|
329
|
+
// During loading, the table shows a skeleton and doesn't need the actual data.
|
|
330
|
+
let headers = [];
|
|
331
|
+
let tableRows = [];
|
|
320
332
|
if (!isLoading) {
|
|
321
333
|
const extractedData = extractTableData(node);
|
|
322
334
|
headers = extractedData.headers.map((cell) => createCellContent(cell, { isInThead: true }));
|
|
@@ -324,28 +336,25 @@ function renderWithStaticTag(tag, token, content, attrs, options, _context, node
|
|
|
324
336
|
cells: row.map((cell) => createCellContent(cell)),
|
|
325
337
|
}));
|
|
326
338
|
}
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
const tableAttrs = isLoading ? EMPTY_ATTRS : attrs;
|
|
333
|
-
return html `<div class="cds-aichat-table-holder">
|
|
339
|
+
// Always return the same structure to allow Lit to reuse the table element.
|
|
340
|
+
// When isLoading is true, the table component will show a skeleton state.
|
|
341
|
+
// When isLoading is false, it will show the actual data.
|
|
342
|
+
// This prevents recreating the table element and preserves its internal state.
|
|
343
|
+
return html `<div class="cds-aichat-table--square">
|
|
334
344
|
<cds-aichat-table
|
|
345
|
+
data-rounded
|
|
335
346
|
.headers=${headers}
|
|
336
347
|
.rows=${tableRows}
|
|
337
348
|
.loading=${isLoading}
|
|
338
|
-
.filterPlaceholderText=${
|
|
339
|
-
.previousPageText=${
|
|
340
|
-
.nextPageText=${
|
|
341
|
-
.itemsPerPageText=${
|
|
342
|
-
.downloadLabelText=${
|
|
343
|
-
.locale=${
|
|
344
|
-
.getPaginationSupplementalText=${
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
DEFAULT_PAGINATION_STATUS_TEXT}
|
|
348
|
-
...=${tableAttrs}
|
|
349
|
+
.filterPlaceholderText=${tableFilterPlaceholderText}
|
|
350
|
+
.previousPageText=${tablePreviousPageText}
|
|
351
|
+
.nextPageText=${tableNextPageText}
|
|
352
|
+
.itemsPerPageText=${tableItemsPerPageText}
|
|
353
|
+
.downloadLabelText=${tableDownloadLabelText}
|
|
354
|
+
.locale=${tableLocale}
|
|
355
|
+
.getPaginationSupplementalText=${tableGetPaginationSupplementalText}
|
|
356
|
+
.getPaginationStatusText=${tableGetPaginationStatusText}
|
|
357
|
+
...=${attrs}
|
|
349
358
|
></cds-aichat-table>
|
|
350
359
|
</div>`;
|
|
351
360
|
}
|