@patternfly/chatbot 6.8.0-prerelease.4 → 6.8.0-prerelease.6
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/dist/cjs/ChatbotHeader/ChatbotHeaderMenu.js +2 -5
- package/dist/cjs/FileDetailsLabel/FileDetailsLabel.js +1 -1
- package/dist/cjs/FileDropZone/FileDropZone.js +1 -1
- package/dist/cjs/ImagePreview/ImagePreview.js +1 -1
- package/dist/cjs/Message/CodeBlockMessage/CodeBlockMessage.js +1 -2
- package/dist/cjs/Message/Message.test.js +1 -20
- package/dist/cjs/Message/QuickResponse/QuickResponse.js +1 -1
- package/dist/cjs/Message/QuickStarts/QuickStartTile.js +4 -6
- package/dist/cjs/MessageBar/AttachButton.js +2 -2
- package/dist/cjs/MessageBar/MessageBar.test.js +1 -1
- package/dist/cjs/MessageBar/MicrophoneButton.js +2 -4
- package/dist/cjs/MessageBox/JumpButton.js +2 -4
- package/dist/cjs/SourcesCardBase/SourcesCardBase.js +5 -5
- package/dist/css/main.css +0 -13
- package/dist/css/main.css.map +1 -1
- package/dist/esm/ChatbotHeader/ChatbotHeaderMenu.js +2 -2
- package/dist/esm/FileDetailsLabel/FileDetailsLabel.js +2 -2
- package/dist/esm/FileDropZone/FileDropZone.js +2 -2
- package/dist/esm/ImagePreview/ImagePreview.js +2 -2
- package/dist/esm/Message/CodeBlockMessage/CodeBlockMessage.js +2 -3
- package/dist/esm/Message/Message.test.js +1 -20
- package/dist/esm/Message/QuickResponse/QuickResponse.js +2 -2
- package/dist/esm/Message/QuickStarts/QuickStartTile.js +4 -6
- package/dist/esm/MessageBar/AttachButton.js +2 -2
- package/dist/esm/MessageBar/MessageBar.test.js +2 -2
- package/dist/esm/MessageBar/MicrophoneButton.js +2 -4
- package/dist/esm/MessageBox/JumpButton.js +2 -4
- package/dist/esm/SourcesCardBase/SourcesCardBase.js +7 -7
- package/package.json +1 -5
- package/patternfly-docs/content/extensions/chatbot/examples/Messages/MessageWithSources.tsx +3 -3
- package/patternfly-docs/content/extensions/chatbot/examples/Messages/Messages.md +1 -1
- package/patternfly-docs/content/extensions/chatbot/examples/Messages/explore-pipeline-quickstart.ts +0 -3
- package/patternfly-docs/content/extensions/chatbot/examples/demos/AttachmentDemos.md +1 -1
- package/patternfly-docs/content/extensions/chatbot/examples/demos/Chatbot.md +1 -1
- package/patternfly-docs/content/extensions/chatbot/examples/demos/ChatbotAttachmentMenu.tsx +13 -7
- package/patternfly-docs/content/extensions/chatbot/examples/demos/ChatbotDisplayMode.tsx +7 -2
- package/patternfly-docs/content/extensions/chatbot/examples/demos/ChatbotInDrawer.tsx +2 -2
- package/patternfly-docs/content/extensions/chatbot/examples/demos/EmbeddedChatbot.tsx +2 -2
- package/patternfly-docs/content/extensions/chatbot/examples/demos/EmbeddedComparisonChatbot.tsx +2 -2
- package/patternfly-docs/content/extensions/chatbot/examples/demos/WhiteEmbeddedChatbot.tsx +2 -2
- package/src/ChatbotHeader/ChatbotHeaderMenu.tsx +2 -2
- package/src/FileDetailsLabel/FileDetailsLabel.tsx +2 -2
- package/src/FileDropZone/FileDropZone.tsx +2 -2
- package/src/ImagePreview/ImagePreview.tsx +6 -2
- package/src/Message/CodeBlockMessage/CodeBlockMessage.tsx +2 -3
- package/src/Message/Message.test.tsx +8 -5
- package/src/Message/QuickResponse/QuickResponse.tsx +2 -2
- package/src/Message/QuickStarts/QuickStartTile.tsx +9 -6
- package/src/MessageBar/AttachButton.tsx +2 -2
- package/src/MessageBar/MessageBar.test.tsx +6 -6
- package/src/MessageBar/MicrophoneButton.tsx +2 -7
- package/src/MessageBox/JumpButton.tsx +2 -6
- package/src/SourcesCard/SourcesCard.scss +0 -13
- package/src/SourcesCardBase/SourcesCardBase.tsx +7 -32
- package/src/index.ts +0 -3
- package/patternfly-docs/content/extensions/chatbot/examples/Messages/AttachMenu.tsx +0 -149
- package/patternfly-docs/content/extensions/chatbot/examples/Messages/PaperclipIcon.svg +0 -10
|
@@ -10,15 +10,12 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
10
10
|
}
|
|
11
11
|
return t;
|
|
12
12
|
};
|
|
13
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
14
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
15
|
-
};
|
|
16
13
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
14
|
exports.ChatbotHeaderMenu = void 0;
|
|
18
15
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
19
16
|
const react_1 = require("react");
|
|
20
17
|
const react_core_1 = require("@patternfly/react-core");
|
|
21
|
-
const
|
|
18
|
+
const rh_ui_menu_bars_icon_1 = require("@patternfly/react-icons/dist/esm/icons/rh-ui-menu-bars-icon");
|
|
22
19
|
const ChatbotHeaderMenuBase = (_a) => {
|
|
23
20
|
var { className, onMenuToggle, tooltipProps, menuAriaLabel = 'Chat history drawer', innerRef, tooltipContent = 'Chat history drawer', isCompact } = _a, props = __rest(_a, ["className", "onMenuToggle", "tooltipProps", "menuAriaLabel", "innerRef", "tooltipContent", "isCompact"]);
|
|
24
21
|
const [isDrawerAnimating, setIsDrawerAnimating] = (0, react_1.useState)(false);
|
|
@@ -45,7 +42,7 @@ const ChatbotHeaderMenuBase = (_a) => {
|
|
|
45
42
|
return () => clearTimeout(timeout);
|
|
46
43
|
}
|
|
47
44
|
}, [drawerState, isDrawerOpen]);
|
|
48
|
-
const button = (0, react_1.useMemo)(() => ((0, jsx_runtime_1.jsx)(react_core_1.Button, Object.assign({ className: `pf-chatbot__button--toggle-menu ${isCompact ? 'pf-m-compact' : ''}`, variant: "plain", onClick: onMenuToggle, "aria-label": menuAriaLabel, ref: innerRef !== null && innerRef !== void 0 ? innerRef : buttonRef, icon: (0, jsx_runtime_1.jsx)(react_core_1.Icon, { size: isCompact ? 'lg' : 'xl', isInline: true, children: (0, jsx_runtime_1.jsx)(
|
|
45
|
+
const button = (0, react_1.useMemo)(() => ((0, jsx_runtime_1.jsx)(react_core_1.Button, Object.assign({ className: `pf-chatbot__button--toggle-menu ${isCompact ? 'pf-m-compact' : ''}`, variant: "plain", onClick: onMenuToggle, "aria-label": menuAriaLabel, ref: innerRef !== null && innerRef !== void 0 ? innerRef : buttonRef, icon: (0, jsx_runtime_1.jsx)(react_core_1.Icon, { size: isCompact ? 'lg' : 'xl', isInline: true, children: (0, jsx_runtime_1.jsx)(rh_ui_menu_bars_icon_1.RhUiMenuBarsIcon, {}) }), size: isCompact ? 'sm' : undefined }, props))),
|
|
49
46
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
50
47
|
[isCompact, menuAriaLabel, onMenuToggle, innerRef, buttonRef]);
|
|
51
48
|
return ((0, jsx_runtime_1.jsx)("div", { className: `pf-chatbot__menu ${className}`, children: isDrawerAnimating ? (button) : ((0, jsx_runtime_1.jsx)(react_core_1.Tooltip, Object.assign({ content: tooltipContent, position: "bottom",
|
|
@@ -21,7 +21,7 @@ const FileDetails_1 = __importDefault(require("../FileDetails"));
|
|
|
21
21
|
const react_core_2 = require("@patternfly/react-core");
|
|
22
22
|
const react_icons_1 = require("@patternfly/react-icons");
|
|
23
23
|
const FileDetailsLabel = (_a) => {
|
|
24
|
-
var { fileName, fileId, isLoading, onClick, onClose, closeButtonAriaLabel, languageTestId, spinnerTestId, fileSize, hasTruncation = true, closeButtonIcon = (0, jsx_runtime_1.jsx)(react_icons_1.
|
|
24
|
+
var { fileName, fileId, isLoading, onClick, onClose, closeButtonAriaLabel, languageTestId, spinnerTestId, fileSize, hasTruncation = true, closeButtonIcon = (0, jsx_runtime_1.jsx)(react_icons_1.RhMicronsCloseIcon, {}) } = _a, props = __rest(_a, ["fileName", "fileId", "isLoading", "onClick", "onClose", "closeButtonAriaLabel", "languageTestId", "spinnerTestId", "fileSize", "hasTruncation", "closeButtonIcon"]);
|
|
25
25
|
const handleClose = (event) => {
|
|
26
26
|
onClose && onClose(event, fileName, fileId);
|
|
27
27
|
};
|
|
@@ -19,7 +19,7 @@ const react_icons_1 = require("@patternfly/react-icons");
|
|
|
19
19
|
const FileDropZone = (_a) => {
|
|
20
20
|
var { children, className, infoText = 'Maximum file size is 25 MB', onFileDrop, allowedFileTypes, minSize, maxSize, maxFiles, isAttachmentDisabled, onAttach, onAttachRejected, validator, displayMode = Chatbot_1.ChatbotDisplayMode.default } = _a, props = __rest(_a, ["children", "className", "infoText", "onFileDrop", "allowedFileTypes", "minSize", "maxSize", "maxFiles", "isAttachmentDisabled", "onAttach", "onAttachRejected", "validator", "displayMode"]);
|
|
21
21
|
const [showDropZone, setShowDropZone] = (0, react_1.useState)(false);
|
|
22
|
-
const renderDropZone = () => ((0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: (0, jsx_runtime_1.jsx)(react_core_1.MultipleFileUploadMain, { titleIcon: (0, jsx_runtime_1.jsx)(react_icons_1.
|
|
22
|
+
const renderDropZone = () => ((0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: (0, jsx_runtime_1.jsx)(react_core_1.MultipleFileUploadMain, { titleIcon: (0, jsx_runtime_1.jsx)(react_icons_1.RhUiUploadIcon, {}), titleText: "Drag and drop your file here", infoText: infoText, isUploadButtonHidden: true }) }));
|
|
23
23
|
return ((0, jsx_runtime_1.jsx)(react_core_1.MultipleFileUpload, { dropzoneProps: Object.assign({ accept: allowedFileTypes, onDrop: (acceptedFiles, fileRejections, event) => {
|
|
24
24
|
setShowDropZone(false);
|
|
25
25
|
onAttach && onAttach(acceptedFiles, fileRejections, event);
|
|
@@ -34,7 +34,7 @@ const ImagePreview = (_a) => {
|
|
|
34
34
|
setPage(newPage);
|
|
35
35
|
onSetPage && onSetPage(_evt, newPage);
|
|
36
36
|
};
|
|
37
|
-
return ((0, jsx_runtime_1.jsxs)(ChatbotModal_1.default, Object.assign({ isOpen: isModalOpen, className: `pf-chatbot__image-preview-modal pf-chatbot__image-preview-modal--${displayMode} ${isCompact ? 'pf-m-compact' : ''} ${className ? className : ''}`, displayMode: displayMode, onClose: handleModalToggle, isCompact: isCompact }, props, { children: [(0, jsx_runtime_1.jsx)(react_core_1.ModalHeader, Object.assign({ title: title }, modalHeaderProps)), (0, jsx_runtime_1.jsx)(react_core_1.ModalBody, Object.assign({ className: "pf-chatbot__image-preview-body" }, modalBodyProps, { children: images.length > 0 && images[page - 1] && ((0, jsx_runtime_1.jsxs)(react_core_1.Stack, { hasGutter: true, className: "pf-chatbot__image-preview-stack", children: [(0, jsx_runtime_1.jsx)(react_core_1.StackItem, { children: (0, jsx_runtime_1.jsx)(FileDetailsLabel_1.default, Object.assign({ fileName: images[page - 1].fileName, fileSize: images[page - 1].fileSize, hasTruncation: false, onClose: onCloseFileDetailsLabel, closeButtonIcon: (0, jsx_runtime_1.jsx)(react_icons_1.
|
|
37
|
+
return ((0, jsx_runtime_1.jsxs)(ChatbotModal_1.default, Object.assign({ isOpen: isModalOpen, className: `pf-chatbot__image-preview-modal pf-chatbot__image-preview-modal--${displayMode} ${isCompact ? 'pf-m-compact' : ''} ${className ? className : ''}`, displayMode: displayMode, onClose: handleModalToggle, isCompact: isCompact }, props, { children: [(0, jsx_runtime_1.jsx)(react_core_1.ModalHeader, Object.assign({ title: title }, modalHeaderProps)), (0, jsx_runtime_1.jsx)(react_core_1.ModalBody, Object.assign({ className: "pf-chatbot__image-preview-body" }, modalBodyProps, { children: images.length > 0 && images[page - 1] && ((0, jsx_runtime_1.jsxs)(react_core_1.Stack, { hasGutter: true, className: "pf-chatbot__image-preview-stack", children: [(0, jsx_runtime_1.jsx)(react_core_1.StackItem, { children: (0, jsx_runtime_1.jsx)(FileDetailsLabel_1.default, Object.assign({ fileName: images[page - 1].fileName, fileSize: images[page - 1].fileSize, hasTruncation: false, onClose: onCloseFileDetailsLabel, closeButtonIcon: (0, jsx_runtime_1.jsx)(react_core_1.Icon, { size: "md", children: (0, jsx_runtime_1.jsx)(react_icons_1.RhUiTrashFillIcon, {}) }) }, fileDetailsLabelProps)) }), (0, jsx_runtime_1.jsx)(react_core_1.StackItem, { children: (0, jsx_runtime_1.jsx)("div", { className: "pf-chatbot__image-preview-body", children: images[page - 1].image }) })] })) })), images.length > 1 && ((0, jsx_runtime_1.jsx)(react_core_1.ModalFooter, { className: "pf-chatbot__image-preview-footer", children: (0, jsx_runtime_1.jsxs)("nav", { className: `pf-chatbot__image-preview-footer-buttons`, "aria-label": paginationAriaLabel, children: [(0, jsx_runtime_1.jsx)(react_core_1.Button, { variant: react_core_1.ButtonVariant.plain, isDisabled: isDisabled || page === 1, "data-action": "previous", onClick: (event) => {
|
|
38
38
|
const newPage = page > 1 ? page - 1 : 1;
|
|
39
39
|
handleNewPage(event, newPage);
|
|
40
40
|
onPreviousClick && onPreviousClick(event, newPage);
|
|
@@ -18,7 +18,6 @@ const jsx_runtime_1 = require("react/jsx-runtime");
|
|
|
18
18
|
const react_1 = require("react");
|
|
19
19
|
// Import PatternFly components
|
|
20
20
|
const react_core_1 = require("@patternfly/react-core");
|
|
21
|
-
const check_icon_1 = require("@patternfly/react-icons/dist/esm/icons/check-icon");
|
|
22
21
|
const react_styles_1 = require("@patternfly/react-styles");
|
|
23
22
|
const react_icons_1 = require("@patternfly/react-icons");
|
|
24
23
|
const DEFAULT_EXPANDED_TEXT = 'Show less';
|
|
@@ -75,7 +74,7 @@ const CodeBlockMessage = (_a) => {
|
|
|
75
74
|
return ((0, jsx_runtime_1.jsx)("code", Object.assign({}, props, { className: `pf-chatbot__message-inline-code ${isPrimary ? 'pf-m-primary' : ''}`, children: children })));
|
|
76
75
|
}
|
|
77
76
|
// Setup code block header
|
|
78
|
-
const actions = ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsxs)(react_core_1.CodeBlockAction, { className: "pf-chatbot__message-code-block-default-action", children: [language && (0, jsx_runtime_1.jsx)("div", { className: "pf-chatbot__message-code-block-language", children: language }), (0, jsx_runtime_1.jsx)(react_core_1.Button, { ref: buttonRef, "aria-label": ariaLabel !== null && ariaLabel !== void 0 ? ariaLabel : 'Copy code', variant: "plain", className: "pf-chatbot__button--copy", onClick: (event) => handleCopy(event, children), children: copied ? (0, jsx_runtime_1.jsx)(
|
|
77
|
+
const actions = ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsxs)(react_core_1.CodeBlockAction, { className: "pf-chatbot__message-code-block-default-action", children: [language && (0, jsx_runtime_1.jsx)("div", { className: "pf-chatbot__message-code-block-language", children: language }), (0, jsx_runtime_1.jsx)(react_core_1.Button, { ref: buttonRef, "aria-label": ariaLabel !== null && ariaLabel !== void 0 ? ariaLabel : 'Copy code', variant: "plain", className: "pf-chatbot__button--copy", onClick: (event) => handleCopy(event, children), children: copied ? (0, jsx_runtime_1.jsx)(react_icons_1.RhMicronsCheckmarkIcon, {}) : (0, jsx_runtime_1.jsx)(react_icons_1.RhUiCopyFillIcon, {}) }), (0, jsx_runtime_1.jsx)(react_core_1.Tooltip, { id: tooltipID, content: "Copy", position: "top", triggerRef: buttonRef })] }), customActions] }));
|
|
79
78
|
return ((0, jsx_runtime_1.jsx)("div", { className: (0, react_styles_1.css)('pf-chatbot__message-code-block', shouldRetainStyles && 'pf-m-markdown'), ref: codeBlockRef, children: (0, jsx_runtime_1.jsxs)(react_core_1.CodeBlock, { actions: actions, children: [(0, jsx_runtime_1.jsx)(react_core_1.CodeBlockCode, { children: (0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: isExpandable ? ((0, jsx_runtime_1.jsx)(react_core_1.ExpandableSection, Object.assign({ variant: react_core_1.ExpandableSectionVariant.truncate, isExpanded: isExpanded, isDetached: true, toggleId: toggleId, contentId: contentId }, expandableSectionProps, { children: children }))) : (children) }) }), isExpandable && ((0, jsx_runtime_1.jsx)(react_core_1.ExpandableSectionToggle, Object.assign({ isExpanded: isExpanded, onToggle: onToggle, direction: "up", toggleId: toggleId, contentId: contentId, hasTruncatedContent: true, className: "pf-chatbot__message-code-toggle" }, expandableSectionToggleProps, { children: isExpanded ? finalExpandedText : finalCollapsedText })))] }) }));
|
|
80
79
|
};
|
|
81
80
|
exports.default = CodeBlockMessage;
|
|
@@ -23,26 +23,7 @@ const monitor_sampleapp_quickstart_with_image_1 = require("./QuickStarts/monitor
|
|
|
23
23
|
const rehype_external_links_1 = __importDefault(require("../__mocks__/rehype-external-links"));
|
|
24
24
|
const react_core_1 = require("@patternfly/react-core");
|
|
25
25
|
// Mock the icon components
|
|
26
|
-
jest.mock('@patternfly/react-icons', () => ({
|
|
27
|
-
RhUiLikeIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiLikeIcon" }),
|
|
28
|
-
RhUiLikeFillIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiLikeFillIcon" }),
|
|
29
|
-
RhUiDislikeIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiDislikeIcon" }),
|
|
30
|
-
RhUiDislikeFillIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiDislikeFillIcon" }),
|
|
31
|
-
RhUiCopyIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiCopyIcon" }),
|
|
32
|
-
RhUiCopyFillIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiCopyFillIcon" }),
|
|
33
|
-
RhUiEditIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiEditIcon" }),
|
|
34
|
-
RhUiEditFillIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiEditFillIcon" }),
|
|
35
|
-
RhUiVolumeUpIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiVolumeUpIcon" }),
|
|
36
|
-
RhUiVolumeUpFillIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiVolumeUpFillIcon" }),
|
|
37
|
-
RhUiExportIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiExportIcon" }),
|
|
38
|
-
RhUiExportFillIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiExportFillIcon" }),
|
|
39
|
-
RhMicronsInformationFillIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhMicronsInformationFillIcon" }),
|
|
40
|
-
CheckIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "CheckIcon" }),
|
|
41
|
-
CloseIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "CloseIcon" }),
|
|
42
|
-
ExternalLinkSquareAltIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "ExternalLinkSquareAltIcon" }),
|
|
43
|
-
TimesIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "TimesIcon" }),
|
|
44
|
-
RhUiBackwardsIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiBackwardsIcon" })
|
|
45
|
-
}));
|
|
26
|
+
jest.mock('@patternfly/react-icons', () => (Object.assign(Object.assign({}, jest.requireActual('@patternfly/react-icons')), { RhUiLikeIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiLikeIcon" }), RhUiLikeFillIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiLikeFillIcon" }), RhUiDislikeIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiDislikeIcon" }), RhUiDislikeFillIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiDislikeFillIcon" }), RhUiCopyIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiCopyIcon" }), RhUiCopyFillIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiCopyFillIcon" }), RhUiEditIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiEditIcon" }), RhUiEditFillIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiEditFillIcon" }), RhUiVolumeUpIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiVolumeUpIcon" }), RhUiVolumeUpFillIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiVolumeUpFillIcon" }), RhUiExportIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiExportIcon" }), RhUiExportFillIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiExportFillIcon" }), RhMicronsInformationFillIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhMicronsInformationFillIcon" }), RhUiBackwardsIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiBackwardsIcon" }), RhMicronsExternalLinkIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhMicronsExternalLinkIcon" }), RhMicronsCheckmarkIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhMicronsCheckmarkIcon" }), RhMicronsCloseIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhMicronsCloseIcon" }), RhUiBookmarkIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiBookmarkIcon" }), RhUiClockIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiClockIcon" }), RhUiRocketFillIcon: () => (0, jsx_runtime_1.jsx)("div", { children: "RhUiRocketFillIcon" }) })));
|
|
46
27
|
const ALL_ACTIONS = [
|
|
47
28
|
{ label: /Good response/i },
|
|
48
29
|
{ label: /Bad response/i },
|
|
@@ -26,7 +26,7 @@ const QuickResponse = ({ quickResponses, quickResponseContainerProps = { numLabe
|
|
|
26
26
|
};
|
|
27
27
|
return ((0, jsx_runtime_1.jsx)(react_core_1.LabelGroup, Object.assign({ className: (0, react_styles_1.css)('pf-chatbot__message-quick-response', quickResponseContainerProps === null || quickResponseContainerProps === void 0 ? void 0 : quickResponseContainerProps.className) }, quickResponseContainerProps, { children: quickResponses.map((_a) => {
|
|
28
28
|
var { id, onClick, content, className } = _a, props = __rest(_a, ["id", "onClick", "content", "className"]);
|
|
29
|
-
return ((0, jsx_runtime_1.jsx)(react_core_1.Label, Object.assign({ variant: id === selectedQuickResponse ? undefined : 'outline', icon: id === selectedQuickResponse ? (0, jsx_runtime_1.jsx)(react_icons_1.
|
|
29
|
+
return ((0, jsx_runtime_1.jsx)(react_core_1.Label, Object.assign({ variant: id === selectedQuickResponse ? undefined : 'outline', icon: id === selectedQuickResponse ? (0, jsx_runtime_1.jsx)(react_icons_1.RhMicronsCheckmarkIcon, {}) : undefined, color: "blue", onClick: () => handleQuickResponseClick(id, onClick), className: (0, react_styles_1.css)(id === selectedQuickResponse && 'pf-chatbot__message-quick-response--selected', className), isCompact: isCompact }, props, { children: content }), id));
|
|
30
30
|
}) })));
|
|
31
31
|
};
|
|
32
32
|
exports.QuickResponse = QuickResponse;
|
|
@@ -5,13 +5,11 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.QuickStartTile = exports.camelize = void 0;
|
|
7
7
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
8
|
-
const rocket_icon_1 = __importDefault(require("@patternfly/react-icons/dist/js/icons/rocket-icon"));
|
|
9
|
-
const outlined_bookmark_icon_1 = __importDefault(require("@patternfly/react-icons/dist/js/icons/outlined-bookmark-icon"));
|
|
10
8
|
const react_core_1 = require("@patternfly/react-core");
|
|
11
|
-
const outlined_clock_icon_1 = __importDefault(require("@patternfly/react-icons/dist/js/icons/outlined-clock-icon"));
|
|
12
9
|
const QuickStartTileHeader_1 = __importDefault(require("./QuickStartTileHeader"));
|
|
13
10
|
const QuickStartTileDescription_1 = __importDefault(require("./QuickStartTileDescription"));
|
|
14
11
|
const FallbackImg_1 = __importDefault(require("./FallbackImg"));
|
|
12
|
+
const react_icons_1 = require("@patternfly/react-icons");
|
|
15
13
|
const camelize = (str) => str.replace(/(?:^\w|[A-Z]|\b\w|\s+)/g, function (match, index) {
|
|
16
14
|
if (+match === 0) {
|
|
17
15
|
return '';
|
|
@@ -26,7 +24,7 @@ const QuickStartTile = ({ className, quickStart, onClick, onSelectQuickStart, mi
|
|
|
26
24
|
quickStartIcon = (0, jsx_runtime_1.jsx)(react_core_1.Icon, { size: "2xl", children: icon });
|
|
27
25
|
}
|
|
28
26
|
else {
|
|
29
|
-
quickStartIcon = ((0, jsx_runtime_1.jsx)(react_core_1.Icon, { size: "2xl", children: (0, jsx_runtime_1.jsx)(FallbackImg_1.default, { src: icon, alt: "", className: "pfext-catalog-item-icon__img", fallback: (0, jsx_runtime_1.jsx)(
|
|
27
|
+
quickStartIcon = ((0, jsx_runtime_1.jsx)(react_core_1.Icon, { size: "2xl", children: (0, jsx_runtime_1.jsx)(FallbackImg_1.default, { src: icon, alt: "", className: "pfext-catalog-item-icon__img", fallback: (0, jsx_runtime_1.jsx)(react_icons_1.RhUiRocketFillIcon, {}) }) }));
|
|
30
28
|
}
|
|
31
29
|
const onSelect = () => {
|
|
32
30
|
if (!link) {
|
|
@@ -37,11 +35,11 @@ const QuickStartTile = ({ className, quickStart, onClick, onSelectQuickStart, mi
|
|
|
37
35
|
}
|
|
38
36
|
onClick && onClick();
|
|
39
37
|
};
|
|
40
|
-
const ActionIcon = (action === null || action === void 0 ? void 0 : action.icon) ||
|
|
38
|
+
const ActionIcon = (action === null || action === void 0 ? void 0 : action.icon) || react_icons_1.RhUiBookmarkIcon;
|
|
41
39
|
const additionalAction = action ? ((0, jsx_runtime_1.jsx)(react_core_1.Button, Object.assign({ "aria-label": action['aria-label'], icon: (0, jsx_runtime_1.jsx)(ActionIcon, {}), variant: "plain", onClick: action.onClick }, action.buttonProps))) : undefined;
|
|
42
40
|
return ((0, jsx_runtime_1.jsxs)(react_core_1.Card, { className: `pf-chatbot__quickstarts-tile ${className ? className : ''}`, id: `${id}-chatbot-qs-tile`, style: { height: '100%' }, "data-testid": `chatbot-qs-card-${(0, exports.camelize)(displayName)}`, isCompact: isCompact, children: [(0, jsx_runtime_1.jsx)(react_core_1.CardHeader, Object.assign({}, (action && {
|
|
43
41
|
actions: { actions: additionalAction }
|
|
44
|
-
}), { children: quickStartIcon })), (0, jsx_runtime_1.jsx)(react_core_1.CardTitle, { children: (0, jsx_runtime_1.jsx)(QuickStartTileHeader_1.default, { name: displayName, onSelect: onSelect, quickStartId: id }) }), (0, jsx_runtime_1.jsx)(react_core_1.CardBody, { children: (0, jsx_runtime_1.jsxs)(react_core_1.Stack, { hasGutter: true, children: [(0, jsx_runtime_1.jsxs)(react_core_1.Flex, { spaceItems: { default: 'spaceItemsSm' }, children: [type && (0, jsx_runtime_1.jsx)(react_core_1.Label, { color: type.color, children: type.text }), durationMinutes && ((0, jsx_runtime_1.jsx)(react_core_1.Label, { variant: "outline", "data-test": "duration", icon: (0, jsx_runtime_1.jsx)(
|
|
42
|
+
}), { children: quickStartIcon })), (0, jsx_runtime_1.jsx)(react_core_1.CardTitle, { children: (0, jsx_runtime_1.jsx)(QuickStartTileHeader_1.default, { name: displayName, onSelect: onSelect, quickStartId: id }) }), (0, jsx_runtime_1.jsx)(react_core_1.CardBody, { children: (0, jsx_runtime_1.jsxs)(react_core_1.Stack, { hasGutter: true, children: [(0, jsx_runtime_1.jsxs)(react_core_1.Flex, { spaceItems: { default: 'spaceItemsSm' }, children: [type && (0, jsx_runtime_1.jsx)(react_core_1.Label, { color: type.color, children: type.text }), durationMinutes && ((0, jsx_runtime_1.jsx)(react_core_1.Label, { variant: "outline", "data-test": "duration", icon: (0, jsx_runtime_1.jsx)(react_icons_1.RhUiClockIcon, {}), children: (0, react_core_1.pluralize)(durationMinutes, minuteWord, minuteWordPlural) }))] }), (0, jsx_runtime_1.jsx)(QuickStartTileDescription_1.default, { description: description, prerequisites: prerequisites, prerequisiteWord: prerequisiteWord, prerequisiteWordPlural: prerequisiteWordPlural, quickStartButtonAriaLabel: quickStartButtonAriaLabel })] }) }), (0, jsx_runtime_1.jsx)(react_core_1.CardFooter, { children: (0, jsx_runtime_1.jsx)(react_core_1.Button, { variant: "link", isInline: true, onClick: onSelect, children: (0, jsx_runtime_1.jsx)("span", { className: "pf-v6-c-button__text", children: "Start" }) }) })] }));
|
|
45
43
|
};
|
|
46
44
|
exports.QuickStartTile = QuickStartTile;
|
|
47
45
|
exports.default = exports.QuickStartTile;
|
|
@@ -17,9 +17,9 @@ const react_1 = require("react");
|
|
|
17
17
|
// Import PatternFly components
|
|
18
18
|
const react_core_1 = require("@patternfly/react-core");
|
|
19
19
|
const react_dropzone_1 = require("react-dropzone");
|
|
20
|
-
const
|
|
20
|
+
const react_icons_1 = require("@patternfly/react-icons");
|
|
21
21
|
const AttachButtonBase = (_a) => {
|
|
22
|
-
var { onAttachAccepted, onClick, isDisabled, className, tooltipProps, innerRef, tooltipContent = 'Attach', inputTestId, isCompact, allowedFileTypes, minSize, maxSize, maxFiles, isAttachmentDisabled, onAttach, onAttachRejected, validator, dropzoneProps, icon = (0, jsx_runtime_1.jsx)(
|
|
22
|
+
var { onAttachAccepted, onClick, isDisabled, className, tooltipProps, innerRef, tooltipContent = 'Attach', inputTestId, isCompact, allowedFileTypes, minSize, maxSize, maxFiles, isAttachmentDisabled, onAttach, onAttachRejected, validator, dropzoneProps, icon = (0, jsx_runtime_1.jsx)(react_icons_1.RhUiPaperClipIcon, {}) } = _a, props = __rest(_a, ["onAttachAccepted", "onClick", "isDisabled", "className", "tooltipProps", "innerRef", "tooltipContent", "inputTestId", "isCompact", "allowedFileTypes", "minSize", "maxSize", "maxFiles", "isAttachmentDisabled", "onAttach", "onAttachRejected", "validator", "dropzoneProps", "icon"]);
|
|
23
23
|
const { open, getInputProps } = (0, react_dropzone_1.useDropzone)(Object.assign({ multiple: true, onDropAccepted: onAttachAccepted, accept: allowedFileTypes, minSize,
|
|
24
24
|
maxSize,
|
|
25
25
|
maxFiles, disabled: isAttachmentDisabled, onDrop: onAttach, onDropRejected: onAttachRejected, validator }, dropzoneProps));
|
|
@@ -23,7 +23,7 @@ const SourceDetailsMenuItem_1 = __importDefault(require("../SourceDetailsMenuIte
|
|
|
23
23
|
const MessageBar_1 = require("./MessageBar");
|
|
24
24
|
const ATTACH_MENU_ITEMS = [
|
|
25
25
|
(0, jsx_runtime_1.jsx)(react_core_1.DropdownList, { children: (0, jsx_runtime_1.jsx)(react_core_1.DropdownItem, { className: "pf-chatbot-source-details-dropdown-item", value: "auth-operator Pod", id: "0", children: (0, jsx_runtime_1.jsx)(SourceDetailsMenuItem_1.default, { icon: (0, jsx_runtime_1.jsxs)("svg", { width: "24", height: "25", viewBox: "0 0 24 25", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: [(0, jsx_runtime_1.jsx)("path", { d: "M0 12.5C0 5.87258 5.37258 0.5 12 0.5C18.6274 0.5 24 5.87258 24 12.5C24 19.1274 18.6274 24.5 12 24.5C5.37258 24.5 0 19.1274 0 12.5Z", fill: "currentColor" }), (0, jsx_runtime_1.jsx)("g", { clipPath: "url(#clip0_3280_27488)", children: (0, jsx_runtime_1.jsx)("path", { d: "M8.25 8.75C8.25 7.92266 8.92266 7.25 9.75 7.25H12C14.0719 7.25 15.75 8.92812 15.75 11C15.75 13.0719 14.0719 14.75 12 14.75H9.75V17C9.75 17.4148 9.41484 17.75 9 17.75C8.58516 17.75 8.25 17.4148 8.25 17V14V8.75ZM9.75 13.25H12C13.2422 13.25 14.25 12.2422 14.25 11C14.25 9.75781 13.2422 8.75 12 8.75H9.75V13.25Z", fill: "white" }) }), (0, jsx_runtime_1.jsx)("defs", { children: (0, jsx_runtime_1.jsx)("clipPath", { id: "clip0_3280_27488", children: (0, jsx_runtime_1.jsx)("rect", { width: "7.5", height: "12", fill: "white", transform: "translate(8.25 6.5)" }) }) })] }), name: "auth-operator", type: "Pod" }) }) }, "list-1"),
|
|
26
|
-
(0, jsx_runtime_1.jsx)(react_core_1.DropdownGroup, { children: (0, jsx_runtime_1.jsxs)(react_core_1.DropdownList, { children: [(0, jsx_runtime_1.jsx)(react_core_1.DropdownItem, { value: "Alerts", id: "1", icon: (0, jsx_runtime_1.jsx)(react_icons_1.
|
|
26
|
+
(0, jsx_runtime_1.jsx)(react_core_1.DropdownGroup, { children: (0, jsx_runtime_1.jsxs)(react_core_1.DropdownList, { children: [(0, jsx_runtime_1.jsx)(react_core_1.DropdownItem, { value: "Alerts", id: "1", icon: (0, jsx_runtime_1.jsx)(react_icons_1.RhUiAttentionBellIcon, {}), children: "Alerts" }), (0, jsx_runtime_1.jsx)(react_core_1.DropdownItem, { value: "Events", id: "2", icon: (0, jsx_runtime_1.jsx)(react_icons_1.RhUiCalendarIcon, {}), children: "Events" }), (0, jsx_runtime_1.jsx)(react_core_1.DropdownItem, { value: "Logs", id: "3", icon: (0, jsx_runtime_1.jsx)(react_icons_1.RhUiClipboardIcon, {}), children: "Logs" }), (0, jsx_runtime_1.jsx)(react_core_1.DropdownItem, { value: "YAML - Status", id: "4", icon: (0, jsx_runtime_1.jsx)(react_icons_1.RhUiCodeIcon, {}), children: "YAML - Status" }), (0, jsx_runtime_1.jsx)(react_core_1.DropdownItem, { value: "YAML - All contents", id: "5", icon: (0, jsx_runtime_1.jsx)(react_icons_1.RhUiCodeIcon, {}), children: "YAML - All contents" })] }) }, "group2")
|
|
27
27
|
];
|
|
28
28
|
const originalSpeechRecognition = window.SpeechRecognition;
|
|
29
29
|
const mockSpeechRecognition = () => {
|
|
@@ -14,10 +14,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
14
14
|
exports.MicrophoneButton = void 0;
|
|
15
15
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
16
16
|
const react_1 = require("react");
|
|
17
|
-
// Import PatternFly components
|
|
18
17
|
const react_core_1 = require("@patternfly/react-core");
|
|
19
|
-
|
|
20
|
-
const microphone_icon_1 = require("@patternfly/react-icons/dist/esm/icons/microphone-icon");
|
|
18
|
+
const react_icons_1 = require("@patternfly/react-icons");
|
|
21
19
|
const MicrophoneButton = (_a) => {
|
|
22
20
|
var { isListening, onIsListeningChange, onSpeechRecognition, className, tooltipProps, tooltipContent = { active: 'Stop listening', inactive: 'Use microphone' }, language = 'en-US', isCompact } = _a, props = __rest(_a, ["isListening", "onIsListeningChange", "onSpeechRecognition", "className", "tooltipProps", "tooltipContent", "language", "isCompact"]);
|
|
23
21
|
// Microphone
|
|
@@ -63,7 +61,7 @@ const MicrophoneButton = (_a) => {
|
|
|
63
61
|
if (!speechRecognition) {
|
|
64
62
|
return null;
|
|
65
63
|
}
|
|
66
|
-
return ((0, jsx_runtime_1.jsx)(react_core_1.Tooltip, Object.assign({ aria: "none", "aria-live": "polite", id: "pf-chatbot__tooltip--use-microphone", content: isListening ? tooltipContent.active : tooltipContent.inactive, position: (tooltipProps === null || tooltipProps === void 0 ? void 0 : tooltipProps.position) || 'top', entryDelay: (tooltipProps === null || tooltipProps === void 0 ? void 0 : tooltipProps.entryDelay) || 0, exitDelay: (tooltipProps === null || tooltipProps === void 0 ? void 0 : tooltipProps.exitDelay) || 0, distance: (tooltipProps === null || tooltipProps === void 0 ? void 0 : tooltipProps.distance) || 8, animationDuration: (tooltipProps === null || tooltipProps === void 0 ? void 0 : tooltipProps.animationDuration) || 0 }, tooltipProps, { children: (0, jsx_runtime_1.jsx)(react_core_1.Button, Object.assign({ variant: "plain", className: `pf-chatbot__button--microphone ${isListening ? 'pf-chatbot__button--microphone--active' : ''} ${isCompact ? 'pf-m-compact' : ''} ${className !== null && className !== void 0 ? className : ''}`, "aria-label": props['aria-label'] || (isListening ? 'Stop listening' : 'Use microphone'), "aria-pressed": isListening, onClick: isListening ? stopListening : startListening, icon: (0, jsx_runtime_1.jsx)(react_core_1.Icon, { iconSize: isCompact ? 'lg' : 'xl', isInline: true, children: (0, jsx_runtime_1.jsx)(
|
|
64
|
+
return ((0, jsx_runtime_1.jsx)(react_core_1.Tooltip, Object.assign({ aria: "none", "aria-live": "polite", id: "pf-chatbot__tooltip--use-microphone", content: isListening ? tooltipContent.active : tooltipContent.inactive, position: (tooltipProps === null || tooltipProps === void 0 ? void 0 : tooltipProps.position) || 'top', entryDelay: (tooltipProps === null || tooltipProps === void 0 ? void 0 : tooltipProps.entryDelay) || 0, exitDelay: (tooltipProps === null || tooltipProps === void 0 ? void 0 : tooltipProps.exitDelay) || 0, distance: (tooltipProps === null || tooltipProps === void 0 ? void 0 : tooltipProps.distance) || 8, animationDuration: (tooltipProps === null || tooltipProps === void 0 ? void 0 : tooltipProps.animationDuration) || 0 }, tooltipProps, { children: (0, jsx_runtime_1.jsx)(react_core_1.Button, Object.assign({ variant: "plain", className: `pf-chatbot__button--microphone ${isListening ? 'pf-chatbot__button--microphone--active' : ''} ${isCompact ? 'pf-m-compact' : ''} ${className !== null && className !== void 0 ? className : ''}`, "aria-label": props['aria-label'] || (isListening ? 'Stop listening' : 'Use microphone'), "aria-pressed": isListening, onClick: isListening ? stopListening : startListening, icon: (0, jsx_runtime_1.jsx)(react_core_1.Icon, { iconSize: isCompact ? 'lg' : 'xl', isInline: true, children: (0, jsx_runtime_1.jsx)(react_icons_1.RhUiMicrophoneFillIcon, {}) }), size: isCompact ? 'sm' : undefined }, props)) })));
|
|
67
65
|
};
|
|
68
66
|
exports.MicrophoneButton = MicrophoneButton;
|
|
69
67
|
exports.default = exports.MicrophoneButton;
|
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
4
|
-
// Import PatternFly components
|
|
5
4
|
const react_core_1 = require("@patternfly/react-core");
|
|
6
|
-
const
|
|
7
|
-
const
|
|
8
|
-
const JumpButton = ({ position, isHidden, onClick, jumpButtonProps, jumpButtonTooltipProps }) => isHidden ? null : ((0, jsx_runtime_1.jsx)(react_core_1.Tooltip, Object.assign({ id: `pf-chatbot__tooltip--jump-${position}`, content: `Back to ${position}`, position: "top" }, jumpButtonTooltipProps, { children: (0, jsx_runtime_1.jsx)(react_core_1.Button, Object.assign({ variant: "plain", className: `pf-chatbot__jump pf-chatbot__jump--${position}`, "aria-label": `Back to ${position}`, onClick: onClick }, jumpButtonProps, { children: (0, jsx_runtime_1.jsx)(react_core_1.Icon, { iconSize: "lg", isInline: true, children: position === 'top' ? (0, jsx_runtime_1.jsx)(arrow_up_icon_1.ArrowUpIcon, {}) : (0, jsx_runtime_1.jsx)(arrow_down_icon_1.ArrowDownIcon, {}) }) })) })));
|
|
5
|
+
const react_icons_1 = require("@patternfly/react-icons");
|
|
6
|
+
const JumpButton = ({ position, isHidden, onClick, jumpButtonProps, jumpButtonTooltipProps }) => isHidden ? null : ((0, jsx_runtime_1.jsx)(react_core_1.Tooltip, Object.assign({ id: `pf-chatbot__tooltip--jump-${position}`, content: `Back to ${position}`, position: "top" }, jumpButtonTooltipProps, { children: (0, jsx_runtime_1.jsx)(react_core_1.Button, Object.assign({ variant: "plain", className: `pf-chatbot__jump pf-chatbot__jump--${position}`, "aria-label": `Back to ${position}`, onClick: onClick }, jumpButtonProps, { children: (0, jsx_runtime_1.jsx)(react_core_1.Icon, { iconSize: "lg", isInline: true, children: position === 'top' ? (0, jsx_runtime_1.jsx)(react_icons_1.RhMicronsArrowUpIcon, {}) : (0, jsx_runtime_1.jsx)(react_icons_1.RhMicronsArrowDownIcon, {}) }) })) })));
|
|
9
7
|
exports.default = JumpButton;
|
|
@@ -36,23 +36,23 @@ const SourcesCardBase = (_a) => {
|
|
|
36
36
|
};
|
|
37
37
|
const renderUncontrolledSourceCard = (source, index) => {
|
|
38
38
|
var _a;
|
|
39
|
-
return ((0, jsx_runtime_1.jsx)("li", { className: "pf-chatbot__sources-list-item", style: { '--pf-chatbot-sources-card-max-width': cardMaxWidth }, children: (0, jsx_runtime_1.jsxs)(react_core_1.Card, Object.assign({ isFullHeight: true, isCompact: isCompact, className: "pf-chatbot__sources-card" }, props, { children: [(0, jsx_runtime_1.jsx)(react_core_1.CardTitle, Object.assign({ className: "pf-chatbot__sources-card-title" }, cardTitleProps, { children: (0, jsx_runtime_1.jsxs)("div", { className: "pf-chatbot__sources-card-title-container", children: [(0, jsx_runtime_1.jsx)(react_core_1.Button, Object.assign({ component: "a", variant: react_core_1.ButtonVariant.link, href: source.link, icon: source.isExternal ? (0, jsx_runtime_1.jsx)(react_icons_1.
|
|
39
|
+
return ((0, jsx_runtime_1.jsx)("li", { className: "pf-chatbot__sources-list-item", style: { '--pf-chatbot-sources-card-max-width': cardMaxWidth }, children: (0, jsx_runtime_1.jsxs)(react_core_1.Card, Object.assign({ isFullHeight: true, isCompact: isCompact, className: "pf-chatbot__sources-card" }, props, { children: [(0, jsx_runtime_1.jsx)(react_core_1.CardTitle, Object.assign({ className: "pf-chatbot__sources-card-title" }, cardTitleProps, { children: (0, jsx_runtime_1.jsxs)("div", { className: "pf-chatbot__sources-card-title-container", children: [(0, jsx_runtime_1.jsx)(react_core_1.Button, Object.assign({ component: "a", variant: react_core_1.ButtonVariant.link, href: source.link, icon: source.isExternal ? (0, jsx_runtime_1.jsx)(react_icons_1.RhMicronsExternalLinkIcon, {}) : undefined, iconPosition: "end", isInline: true, rel: source.isExternal ? 'noreferrer' : undefined, target: source.isExternal ? '_blank' : undefined, onClick: (_a = source.onClick) !== null && _a !== void 0 ? _a : undefined }, source.titleProps, { children: renderTitle(source.title, index, source.truncateProps) })), source.subtitle && (0, jsx_runtime_1.jsx)("span", { className: "pf-chatbot__sources-card-subtitle", children: source.subtitle })] }) })), source.body && ((0, jsx_runtime_1.jsx)(react_core_1.CardBody, Object.assign({ className: `pf-chatbot__sources-card-body ${source.footer ? 'pf-chatbot__compact-sources-card-body' : undefined}` }, cardBodyProps, { children: source.hasShowMore ? (
|
|
40
40
|
// prevents extra VO announcements of button text - parent Message has aria-live
|
|
41
41
|
(0, jsx_runtime_1.jsx)("div", { "aria-live": "off", children: (0, jsx_runtime_1.jsx)(react_core_1.ExpandableSection, { variant: react_core_1.ExpandableSectionVariant.truncate, toggleTextCollapsed: showMoreWords, toggleTextExpanded: showLessWords, truncateMaxLines: 2, children: source.body }) })) : ((0, jsx_runtime_1.jsx)("div", { className: "pf-chatbot__sources-card-body-text", children: source.body })) }))), source.footer && ((0, jsx_runtime_1.jsx)(react_core_1.CardFooter, Object.assign({ className: "pf-chatbot__sources-card-footer" }, cardFooterProps, { children: source.footer })))] })) }, index));
|
|
42
42
|
};
|
|
43
43
|
if (layout === 'wrap') {
|
|
44
44
|
return ((0, jsx_runtime_1.jsx)("div", { className: "pf-chatbot__sources-card-base pf-m-wrap", children: (0, jsx_runtime_1.jsx)("ul", { className: "pf-chatbot__sources-list", role: "list", children: sources.map((source, index) => renderUncontrolledSourceCard(source, index)) }) }));
|
|
45
45
|
}
|
|
46
|
-
return ((0, jsx_runtime_1.jsx)("div", { className: "pf-chatbot__sources-card-base", children: (0, jsx_runtime_1.jsxs)(react_core_1.Card, Object.assign({ isCompact: isCompact, className: "pf-chatbot__sources-card" }, props, { children: [(0, jsx_runtime_1.jsx)(react_core_1.CardTitle, Object.assign({ className: "pf-chatbot__sources-card-title" }, cardTitleProps, { children: (0, jsx_runtime_1.jsxs)("div", { className: "pf-chatbot__sources-card-title-container", children: [(0, jsx_runtime_1.jsx)(react_core_1.Button, Object.assign({ component: "a", variant: react_core_1.ButtonVariant.link, href: sources[page - 1].link, icon: sources[page - 1].isExternal ? (0, jsx_runtime_1.jsx)(react_icons_1.
|
|
46
|
+
return ((0, jsx_runtime_1.jsx)("div", { className: "pf-chatbot__sources-card-base", children: (0, jsx_runtime_1.jsxs)(react_core_1.Card, Object.assign({ isCompact: isCompact, className: "pf-chatbot__sources-card" }, props, { children: [(0, jsx_runtime_1.jsx)(react_core_1.CardTitle, Object.assign({ className: "pf-chatbot__sources-card-title" }, cardTitleProps, { children: (0, jsx_runtime_1.jsxs)("div", { className: "pf-chatbot__sources-card-title-container", children: [(0, jsx_runtime_1.jsx)(react_core_1.Button, Object.assign({ component: "a", variant: react_core_1.ButtonVariant.link, href: sources[page - 1].link, icon: sources[page - 1].isExternal ? (0, jsx_runtime_1.jsx)(react_icons_1.RhMicronsExternalLinkIcon, {}) : undefined, iconPosition: "end", isInline: true, rel: sources[page - 1].isExternal ? 'noreferrer' : undefined, target: sources[page - 1].isExternal ? '_blank' : undefined, onClick: (_b = sources[page - 1].onClick) !== null && _b !== void 0 ? _b : undefined }, sources[page - 1].titleProps, { children: renderTitle(sources[page - 1].title, undefined, sources[page - 1].truncateProps) })), sources[page - 1].subtitle && ((0, jsx_runtime_1.jsx)("span", { className: "pf-chatbot__sources-card-subtitle", children: sources[page - 1].subtitle }))] }) })), sources[page - 1].body && ((0, jsx_runtime_1.jsx)(react_core_1.CardBody, Object.assign({ className: `pf-chatbot__sources-card-body ${sources[page - 1].footer ? 'pf-chatbot__compact-sources-card-body' : undefined}` }, cardBodyProps, { children: sources[page - 1].hasShowMore ? (
|
|
47
47
|
// prevents extra VO announcements of button text - parent Message has aria-live
|
|
48
|
-
(0, jsx_runtime_1.jsx)("div", { "aria-live": "off", children: (0, jsx_runtime_1.jsx)(react_core_1.ExpandableSection, { variant: react_core_1.ExpandableSectionVariant.truncate, toggleText: isExpanded ? showLessWords : showMoreWords, onToggle: onToggle, isExpanded: isExpanded, truncateMaxLines: 2, children: sources[page - 1].body }) })) : ((0, jsx_runtime_1.jsx)("div", { className: "pf-chatbot__sources-card-body-text", children: sources[page - 1].body })) }))), sources[page - 1].footer ? ((0, jsx_runtime_1.jsx)(react_core_1.CardFooter, Object.assign({ className: "pf-chatbot__sources-card-footer" }, cardFooterProps, { children: sources[page - 1].footer }))) : (sources.length > 1 && ((0, jsx_runtime_1.jsx)(react_core_1.CardFooter, Object.assign({ className: "pf-chatbot__sources-card-footer-container" }, cardFooterProps, { children: (0, jsx_runtime_1.jsx)("div", { className: "pf-chatbot__sources-card-footer", children: (0, jsx_runtime_1.jsxs)("nav", { className: `pf-chatbot__sources-card-footer-buttons ${className}`, "aria-label": paginationAriaLabel, children: [(0, jsx_runtime_1.jsx)(react_core_1.Button, { variant: react_core_1.ButtonVariant.plain, isDisabled: isDisabled || page === 1, "data-action": "previous", onClick: (event) => {
|
|
48
|
+
(0, jsx_runtime_1.jsx)("div", { "aria-live": "off", children: (0, jsx_runtime_1.jsx)(react_core_1.ExpandableSection, { variant: react_core_1.ExpandableSectionVariant.truncate, toggleText: isExpanded ? showLessWords : showMoreWords, onToggle: onToggle, isExpanded: isExpanded, truncateMaxLines: 2, children: sources[page - 1].body }) })) : ((0, jsx_runtime_1.jsx)("div", { className: "pf-chatbot__sources-card-body-text", children: sources[page - 1].body })) }))), sources[page - 1].footer ? ((0, jsx_runtime_1.jsx)(react_core_1.CardFooter, Object.assign({ className: "pf-chatbot__sources-card-footer" }, cardFooterProps, { children: sources[page - 1].footer }))) : (sources.length > 1 && ((0, jsx_runtime_1.jsx)(react_core_1.CardFooter, Object.assign({ className: "pf-chatbot__sources-card-footer-container" }, cardFooterProps, { children: (0, jsx_runtime_1.jsx)("div", { className: "pf-chatbot__sources-card-footer", children: (0, jsx_runtime_1.jsxs)("nav", { className: `pf-chatbot__sources-card-footer-buttons ${className}`, "aria-label": paginationAriaLabel, children: [(0, jsx_runtime_1.jsx)(react_core_1.Button, { variant: react_core_1.ButtonVariant.plain, isCircle: true, isDisabled: isDisabled || page === 1, "data-action": "previous", onClick: (event) => {
|
|
49
49
|
const newPage = page >= 1 ? page - 1 : 1;
|
|
50
50
|
onPreviousClick && onPreviousClick(event, newPage);
|
|
51
51
|
handleNewPage(event, newPage);
|
|
52
|
-
}, "aria-label": toPreviousPageAriaLabel, children: (0, jsx_runtime_1.jsx)(
|
|
52
|
+
}, "aria-label": toPreviousPageAriaLabel, children: (0, jsx_runtime_1.jsx)(react_icons_1.RhMicronsCaretLeftIcon, {}) }), (0, jsx_runtime_1.jsxs)("span", { "aria-hidden": "true", children: [page, "/", sources.length] }), (0, jsx_runtime_1.jsx)(react_core_1.Button, { variant: react_core_1.ButtonVariant.plain, isCircle: true, isDisabled: isDisabled || page === sources.length, "aria-label": toNextPageAriaLabel, "data-action": "next", onClick: (event) => {
|
|
53
53
|
const newPage = page + 1 <= sources.length ? page + 1 : sources.length;
|
|
54
54
|
onNextClick && onNextClick(event, newPage);
|
|
55
55
|
handleNewPage(event, newPage);
|
|
56
|
-
}, children: (0, jsx_runtime_1.jsx)(
|
|
56
|
+
}, children: (0, jsx_runtime_1.jsx)(react_icons_1.RhMicronsCaretRightIcon, {}) })] }) }) }))))] })) }));
|
|
57
57
|
};
|
|
58
58
|
exports.default = SourcesCardBase;
|
package/dist/css/main.css
CHANGED
|
@@ -2762,23 +2762,10 @@ li[id*=user-content-fn-]:has(> span > span > .pf-chatbot__message-text + .pf-cha
|
|
|
2762
2762
|
justify-content: space-between;
|
|
2763
2763
|
flex: 1;
|
|
2764
2764
|
}
|
|
2765
|
-
.pf-chatbot__sources-card-footer-container .pf-chatbot__sources-card-footer-buttons .pf-v6-c-button {
|
|
2766
|
-
border-radius: var(--pf-t--global--border--radius--pill);
|
|
2767
|
-
padding: var(--pf-t--global--spacer--sm);
|
|
2768
|
-
width: 2.31rem;
|
|
2769
|
-
height: 2.31rem;
|
|
2770
|
-
display: flex;
|
|
2771
|
-
align-items: center;
|
|
2772
|
-
justify-content: center;
|
|
2773
|
-
}
|
|
2774
2765
|
.pf-chatbot__sources-card-footer-container .pf-chatbot__sources-card-footer-buttons button:disabled .pf-v6-c-icon__content,
|
|
2775
2766
|
.pf-chatbot__sources-card-footer-container .pf-chatbot__sources-card-footer-buttons button[disabled] .pf-v6-c-icon__content {
|
|
2776
2767
|
color: var(--pf-t--global--icon--color--disabled);
|
|
2777
2768
|
}
|
|
2778
|
-
.pf-chatbot__sources-card-footer-container .pf-chatbot__sources-card-footer-buttons .pf-v6-c-button__text {
|
|
2779
|
-
display: flex;
|
|
2780
|
-
align-items: center;
|
|
2781
|
-
}
|
|
2782
2769
|
.pf-chatbot__sources-card-footer-container .pf-chatbot__sources-card-footer-buttons .pf-v6-c-button:hover .pf-v6-c-button__icon,
|
|
2783
2770
|
.pf-chatbot__sources-card-footer-container .pf-chatbot__sources-card-footer-buttons .pf-v6-c-button:focus .pf-v6-c-button__icon {
|
|
2784
2771
|
color: var(--pf-t--global--icon--color--regular);
|
package/dist/css/main.css.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sourceRoot":"","sources":["../../src/AttachMenu/AttachMenu.scss","../../src/Chatbot/Chatbot.scss","../../src/ChatbotAlert/ChatbotAlert.scss","../../src/ChatbotContent/ChatbotContent.scss","../../src/ChatbotConversationHistoryNav/ChatbotConversationHistoryNav.scss","../../src/ChatbotFooter/ChatbotFootnote.scss","../../src/ChatbotFooter/ChatbotFooter.scss","../../src/ChatbotHeader/ChatbotHeader.scss","../../src/ChatbotModal/ChatbotModal.scss","../../src/ChatbotPopover/ChatbotPopover.scss","../../src/ChatbotToggle/ChatbotToggle.scss","../../src/ChatbotWelcomePrompt/ChatbotWelcomePrompt.scss","../../src/CodeModal/CodeModal.scss","../../src/Compare/Compare.scss","../../src/DeepThinking/DeepThinking.scss","../../src/FileDetails/FileDetails.scss","../../src/FileDetailsLabel/FileDetailsLabel.scss","../../src/FileDropZone/FileDropZone.scss","../../src/FilePreview/FilePreview.scss","../../src/ImagePreview/ImagePreview.scss","../../src/Message/Message.scss","../../src/Message/MessageLoading.scss","../../src/Message/CodeBlockMessage/CodeBlockMessage.scss","../../src/Message/TextMessage/TextMessage.scss","../../src/Message/SuperscriptMessage/SuperscriptMessage.scss","../../src/Message/ImageMessage/ImageMessage.scss","../../src/Message/LinkMessage/LinkMessage.scss","../../src/Message/ListMessage/ListMessage.scss","../../src/Message/TableMessage/TableMessage.scss","../../src/Message/QuickStarts/QuickStartTile.scss","../../src/Message/QuickResponse/QuickResponse.scss","../../src/Message/UserFeedback/UserFeedback.scss","../../src/MessageBar/AttachButton.scss","../../src/MessageBar/MicrophoneButton.scss","../../src/MessageBar/SendButton.scss","../../src/MessageBar/StopButton.scss","../../src/MessageBar/MessageBar.scss","../../src/MessageBox/JumpButton.scss","../../src/MessageBox/MessageBox.scss","../../src/MessageDivider/MessageDivider.scss","../../src/Onboarding/Onboarding.scss","../../src/ResponseActions/ResponseActions.scss","../../src/Settings/Settings.scss","../../src/SourcesCard/SourcesCard.scss","../../src/SourceDetailsMenuItem/SourceDetailsMenuItem.scss","../../src/TermsOfUse/TermsOfUse.scss","../../src/ToolResponse/ToolResponse.scss","../../src/ToolCall/ToolCall.scss","../../src/main.scss"],"names":[],"mappings":";AAAA;EACE;;;AAGF;AACE;AAsBA;AAKA;;AA1BA;EACE;EACA;EACA;EACA;;AAEF;EACE;;AAGF;AACE;;AACA;EACE;EACA;EACA;EACA;EACA;;AAKJ;EACE;;AAIF;EACE;EACA;;AAGF;EACE;EACA;;AAGF;EACE;EACA;EACA;;AAGF;EACE;;;AC/CJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA,YACE;EAYF;;AAVA;EACE;EACA;EACA;;AAEF;EACE;EACA;;AAOF;EA/BF;IAgCI;IACA;;;AAIF;EArCF;IAsCI;;;AAGF;EACE;;;AAQF;EACE;;;AAOJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAES;EACP;EAEA;EACA;;;AAKF;EAnBF;IAoBI;;;;AAOJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAES;EACP;;;AAOJ;EACE;EACA;EACA;EACA;EACA;;AAES;EACP;EACA;EACA;;;AAIJ;EACE;EACA;EACA;EACA;EACA;EACA;;AAGA;EACE;;AAIF;EAdF;IAeI;;;;AAIJ;EACE;;;AAGF;AAAA;AAAA;EAGE;;;AAMF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAES;EACP;EACA;EACA;;;AAGF;EACE;;;AAKF;EACE;;;AC/KJ;EACE;EACA;EACA;;;ACAF;EACE;EACA;EACA;EACA;EACA;;AAGA;EARF;IASI;;;AAGF;EACE;;;AAKF;EACE;;;AAUJ;EAII;AAAA;AAAA;IACE;IACA;;;AClCJ;EACE;EACA;;AAGF;EACE;EACA;;AAKF;EACE;EACA;EACA;EACA;EACA;;AAEF;EACE;EACA;EACA;;AAEF;EACE;EACA;EACA;EACA;EACA;;AAKA;EACE;EACA;;AAIJ;EACE;;AAKF;EACE;EACA;EAEA;EACA;EACA;;AAEF;EACE;;AAGF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAGF;EACE;EACA;EAEA;EACA;EACA;EACA;EACA;EACA;EACA;;AAGF;EACE;EACA;EACA;EACA;EACA;EAEA;;AAIF;EACE;;AAGF;EACE;;AAGF;EACE;;AAGF;EACE;EACA;EACA;EACA;EACA;EAEA;;AAGF;EACE;;;AAMJ;EACE;EACA;EACA;;AAGA;EACE;EACA;EACA;EACA;EACA;EACA;;AAIF;EACE;EACA;EACA;EACA;EAEA;EACA;EACA;EACA;;AAIF;EACE;EACA;EAEA;EACA;EACA;EACA;EACA;EACA;;AAGF;EACE;;AAKA;EACE;EACA;EACA;EACA;EACA;;AAKJ;EACE;EACA;EACA;EACA;EAEA;EACA;EACA;EACA;;AAKA;EACE;;;AAuBJ;EACE;;;AASF;AAAA;EACE;;AACA;AAAA;EACE;;;AASJ;EACE;;AACA;EACE;EACA;;AAEF;EACE;;;AAUF;AAAA;AAAA;AAAA;EACE;;;AAKN;EACE;EACA;EACA;EACA;;;AAGF;EACE;EACA;EACA;EACA;;;AAKE;EACE;EACA;EACA;EACA;EACA;;AAGF;EACE;EACA;;AAIJ;EACE;;AAGF;EACE;EACA;;AAGA;EACE;EACA;EACA;EACA;EACA;EACA;;;ACrTN;EACE;;AAEA;EACE;EACA;;;ACHJ;EACE;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;;AAKF;EACE;;AAES;EACP;;;AAKN;EACE;EACA;EACA;EACA;EACA;;;AAMF;EAGI;AAAA;IACE;;EAGF;AAAA;IACE;IACA;IACA;;;AASJ;EACE;;;AAQF;EACE;;;AAIJ;EACE;EACA;;;AAQA;EAIM;AAAA;IACE;;;;ACrFV;EACE;;;AAEF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;EACA;;AAEA;EACE;;AAKJ;EACE;EACA;EACA;EACA;;AAEA;EACE;;AAGF;EACE;EACA;;AAIJ;EACE;;AAGF;EACE;EACA;EACA;EACA;EACA;;AACA;EACE;EACA;;;AAMJ;EACE;;AAES;EACP;;;AAQN;AAAA;EAEE;EACA;EACA;EACA;EACA;;AAEA;AAAA;EACE;;AAGF;AAAA;AAAA;AAAA;EAEE;EACA;EACA;;AAMA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;EAGE;;;AAQN;AAAA;EAEE;;;AAGF;EACE;;;AAGF;EACE;;;AAOA;EACE;EACA;;AAGF;EACE;EACA;;;AAIJ;AAAA;EAEE;EACA;;;AAGF;EACE;;;AC3IF;EACE;;;AAGF;EACE;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAGF;EACE;EACA;EACA;;AAIF;EACE;;;AAOJ;EACE;AAAA;IAEE;IACA;IACA;IACA;IACA;IACA;IACA;;;AAGJ;EACE;AAAA;IAEE;IACA;IACA;IACA;IACA;IACA;IACA;;;AAOJ;EACE;EACA;EACA;EACA;EACA;;;AAQE;EACE;;;AAQN;EACE;;;AAOA;EACE;;AAGF;EACE;EACA;;;AC3FF;EACE;;AAMA;EACE;;AAEF;EACE;;AAEF;EACE;;AAIF;EACE;EACA;;AAEF;EACE;;;ACxBN;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAIF;EACE;EACA;;AAGF;EACE;;AAGF;EACE;EACA;EACA;;AAEA;EACE;;;AAKN;EACE;EACA;EACA;;;AC5CF;EACE;EACA;EACA;EACA;;AAEA;EACE;EACA;;AAGF;EACE;;AAGF;EACE;;AAGF;EACE;EACA;EACA;;AAGF;EACE;EACA;EACA;;;AAIJ;EACE;EACA;;AAEA;EACE;;;AAOJ;EAIM;AAAA;IACE;IACA;;;ACpDN;EACE;EACA;EACA;EACA;EACA;;AAEF;EACE;EACA;AACA;EACA;EACA;;AAEF;EACE;;AAEF;EACE;EACA;;AAEF;EACE;;AAEF;EACE;EACA;EACA;AAAA;AAAA;EAGA;EACA;;AAEF;EACE;EACA;;AAEF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAEF;EACE;;AAEF;EACE;EACA;EACA;;AAEF;EACE;;AAEF;EACE;EACA;;AAEF;EACE;;AAGA;EACE;;;AAUF;EACE;EACA;;;AAKN;EACE;;;AAGF;EACE;;;AAIA;EACE;;;AC9FJ;EACE;EACA;EACA;EACA;;;AAEF;EACE;;AAEA;EACE;EACA;EACA;;;AAGJ;EACE;EACA;EACA;;AAEA;EALF;IAMI;;;AAGF;EACE;;AAEA;EAHF;IAII;;;;AAKN;EACE;;AAEA;EACE;;AAGF;EACE;;AAIA;EADF;IAEI;;;;AAIN;EACE;;AAEA;EAHF;IAII;;;;AAIJ;EACE;EACA;EACA;EACA;EACA;EACA;;AAEA;EARF;IASI;IACA;IACA;;;;ACrEJ;EACE;EACA;;;AAGF;EACE;;;AAGF;EACE;EACA;EACA;;;AAGF;EACE;EACA;EACA;;;AAGF;EACE;;;ACtBF;EACE;EACA;EACA;EACA;;;AAGF;EACE;EACA;EACA;;;AAGF;EACE;EACA;EACA;;;AAGF;EACE;;;AAGF;EACE;;;AAIF;EACE;EACA;EACA;EACA;EACA;;;ACjCF;EACE;EACA;EACA;EACA;;;AAGF;EACE;EAEA;EACA;EACA;;AACA;EACE;;AAGF;AAAA;EAEE;EACA;;;AAIJ;EACE;EACA;EACA;;AAEA;EACE;;AAGO;EACP;EACA;;;AAKF;EACE;;AAGF;EACE;;;AAIJ;AAAA;EAEE;EACA;;AAEA;AAAA;EACE;;;AAKF;EACE;;;AAMF;AAAA;EACE;;;ACpEJ;EACE;EACA;;;AAGF;EACE;EACA;EACA;;AAGA;EANF;IAOI;;;;AAIJ;EACE;EACA;EACA;EACA;;AAEA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;AAIJ;AACA;EACE;EACA;EACA;EACA;;;AAME;EADF;IAEI;IACA;IACA;;EAEA;IACE;;;;ACnDR;EACE;EACA;EACA;EACA;EACA;;;AAGF;EACE;EACA;EACA;;;AAGF;EACE;EACA;;;AAEF;EACE;EACA;;;ACpBF;EACE;EACA;EACA;EACA;EACA;;AAEA;EACE;EACA;;AAEF;EACE;;;AAIJ;EACE;;;AAGF;EACE;;;AAGF;EACE;EACA;EACA;EACA;EACA;;AAEA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAIA;AAAA;EACE;;AAGJ;EACE;EACA;;AAKA;AAAA;EACE;;AAGJ;EACE;;;ACvDJ;EACE;EACA;EACA;EACA;;AAIA;EACE;EACA;EACA;EACA;EACA;EACA;;AAGF;EACE;;AAGF;EAKE;;AAJA;EACE;EACA;;AAOJ;EACE;EACA;;AAKF;EACE;EACA;EACA;EACA;;AAKF;EACE;EACA;EACA;;AAGA;EACE;EAQA;EACA;;AAIF;EACE;EACA;;AAIF;EACE;;AAEF;EACE;;AAMJ;EACE;EACA;EACA;EACA;EACA;;AAGF;EACE;EACA;;AAGF;EACE;EACA;EACA;EACA;;AAGF;AAAA;EAEE;;AAIF;AAAA;EAEE;EACA;EACA;;AAEA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;EAME;EACA;EACA;EACA;EACA;EACA;;AAEF;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;EAKE;;AAEF;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;EAQE;;AAIJ;EACE;;AAIF;EACE;;AAEA;EACE;;;AAON;EACE;EACA;EACA;;;AAGF;EACE;;;AC1KF;EACE;EACA;EACA;EACA;EAEA;;AAGA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEF;EAEE;EACA;EACA;EACA;;AAEF;EACE;EACA;EACA;EACA;EACA;EACA;;AAEF;EACE;EACA;EACA;EACA;EACA;EACA;;AAGF;EACE;IACE;;EAEF;IAEE;;;AAIJ;EACE;;;ACtDJ;EACE;EACA;EACA;EACA;;AAGA;EACE;EACA;;AAIF;EACE;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAGF;EACE;EACA;;AAIF;EACE;EACA;EACA;EACA;EACA;EACA;;AAGF;EACE;;AAEA;EAEE;;AAMN;EACE;EACA;EACA;EACA;EACA;;AAEA;AAAA;EAEE;EACA;EACA;;AAEF;EACE;EACA;EACA;;AAGF;EACE;EACA;;AAIJ;EACE;;;AAIJ;EACE;EAEA;EACA;EACA;EAEA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;;AAKF;EACE;EACA;;;ACrGJ;EACE;;AAGE;EACE;;;AAMN;EACE;EACA;EACA;EACA;;AAEA;EACE;;AAGF;AAAA;AAAA;AAAA;AAAA;EAKE;;AAGF;EACE;EACA;;AAKF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAIA;EACE;;AAIJ;EACE;;AAEF;EACE;EACA;;;AAUJ;EAIE;;;AAIF;EAKE;;;AAIA;EACE;;;AAKF;EACE;EACA;EACA;EACA;;AACA;EACE;;AAGF;AAAA;AAAA;AAAA;AAAA;EAKE;;AAIJ;EACE;;AAGF;EACE;EACA;;;AASF;EACE;;AACA;EACE;;AAGF;AAAA;AAAA;AAAA;AAAA;EAKE;;AAGF;EACE;EACA;;;AC/IN;EACE;EACA;;AACA;EACE;EACA;;;AJoLF;EACE;EACA;;AAEA;EACE;;AAIJ;EACE;;AAIA;EACE;EACA;;AAIJ;EACE;;;AE3MJ;EACE;EACA;EACA;EACA;;AAGA;EACE;EACA;;AAIF;EACE;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAGF;EACE;EACA;;AAIF;EACE;EACA;EACA;EACA;EACA;EACA;;AAGF;EACE;;AAEA;EAEE;;AAMN;EACE;EACA;EACA;EACA;EACA;;AAEA;AAAA;EAEE;EACA;EACA;;AAEF;EACE;EACA;EACA;;AAGF;EACE;EACA;;AAIJ;EACE;;;AAIJ;EACE;EAEA;EACA;EACA;EAEA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;;AAKF;EACE;EACA;;;AGzGJ;EACE;EACA;EACA;EACA;EAGA;;;ACNA;EACE;;;AHEJ;EACE;;AAGE;EACE;;;AAMN;EACE;EACA;EACA;EACA;;AAEA;EACE;;AAGF;AAAA;AAAA;AAAA;AAAA;EAKE;;AAGF;EACE;EACA;;AAKF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAIA;EACE;;AAIJ;EACE;;AAEF;EACE;EACA;;;AAUJ;EAIE;;;AAIF;EAKE;;;AAIA;EACE;;;AAKF;EACE;EACA;EACA;EACA;;AACA;EACE;;AAGF;AAAA;AAAA;AAAA;AAAA;EAKE;;AAIJ;EACE;;AAGF;EACE;EACA;;;AASF;EACE;;AACA;EACE;;AAGF;AAAA;AAAA;AAAA;AAAA;EAKE;;AAGF;EACE;EACA;;;AI3IN;AAAA;EAEE;EACA;EACA;;AAEA;AAAA;AAAA;AAAA;AAAA;AAAA;EAGE;;AAIA;AAAA;AAAA;AAAA;AAAA;AAAA;EAGE;;;AAMJ;AAAA;EAEE;EACA;EACA;;AAGA;AAAA;EACE;;AAMF;EACE;EACA;;AAIJ;EACE;;;AC/CJ;EACE;EACA;EACA;EAEA;;AAEA;EACE;;AAGF;EACE;;AAGF;EACE;;AAGF;EACE;EACA;;AAGF;EACE;;AAIA;AAAA;AAAA;AAAA;AAAA;AAAA;EAME;;;APhCN;EACE;EACA;EACA;EACA;EAEA;;AAGA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEF;EAEE;EACA;EACA;EACA;;AAEF;EACE;EACA;EACA;EACA;EACA;EACA;;AAEF;EACE;EACA;EACA;EACA;EACA;EACA;;AAGF;EACE;IACE;;EAEF;IAEE;;;AAIJ;EACE;;;AQzDJ;EACE;EACA;;AAEA;EAJF;IAKI;IACA;;;AAKA;EACE;;;AAOF;EACE;;;AClBF;EACE;;AAGF;EALF;IAMI;;;AAGF;EATF;IAUI;;;AAKF;EACE;EACA;;AAIJ;AAAA;EAEE;EACA;;AAIF;EACE;EACA;EACA;;;AC/BJ;EACE;EAEA;EACA;;;AAIF;EACE;EACA;EACA;EACA;EACA;;;AAEF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;;AAEF;EACE;EACA;EACA;;;AAEF;EACE;EACA;EACA;EACA;;;AAKA;EACE;;;AAGJ;EACE;EACA;EACA;EACA;;;AAGF;EACE;;;AAGF;EACE;;;AAIF;EACE;EACA;EACA;EACA;;;AAIF;EACE;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAEA;EACE;;AAGF;EACE;;;AAMJ;EACE;;AAGF;EACE;;AAIA;EACE;;;AC/FN;EACE;EACA;EACA;EACA;;AAEA;EACE;;AAKA;EACE;;AAIJ;EAEE;;AAEA;EACE;;AAKA;EACE;;;AASR;EACE;EACA;EACA;;;ACxCF;EACE;EACA;EACA;EACA;;AAEA;EACE;;AAMA;EACE;;AAKJ;EACE;EACA;;AAGA;EACE;;AAKA;EACE;;;AAMR;EACE;IACE;;EAEF;IACE;;;AAOJ;EACE;EACA;EACA;;;ACpDF;EACE;EACA;EACA;EACA;;AAEA;EACE;;AAGF;EAEE;EACA;;AAEA;EACE;;;AAMJ;EACE;;AACA;EACE;;AAIJ;EACE;EACA;;AAGF;AAAA;EAEE;;;AAIJ;EACE;IACE;IACA;;EAEF;IACE;IACA;;;AAOJ;EACE;EACA;EACA;;;ACzDF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAGF;EACE;;AAGF;EACE;;AAEA;EACE;;AAKA;EACE;;;AASR;EACE;EACA;EACA;;;ACjCF;EACE;EACA;EAEA;EACA;EAEA;EACA;EACA;EACA;EACA;EAIA;EACA;EAEA;EACA;EAEA;;AAEA;EACE;EACA;EACA;EACA;EACA;EAEA;EACA,YACE;;AAKF;EACE;EACA;;AAKF;EACE;EACA;;AAIJ;EACE;EACA;EACA;EACA;EACA;;AAEA;EACE;EACA;;AAIJ;EACE;EACA;EACA;EACA;EACA;;AAGF;EACE;EACA;EACA;;;AAIJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAEF;EACE;EACA;EACA;EACA;EACA;;AAEF;EACE;;;AAIJ;EACE;EACA;EACA;EACA;EACA;;;AAGF;EACE;EACA;EACA;EACA;;;AAGF;EACE;IACE;IACA;;;AAKF;EACE;IACE;IACA;;;;AAQN;EACE;EACA;;AAEA;EACE;;;AAKF;AAAA;EAEE;EACA;;;AAOJ;EACE;;;AC1KF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA,YACE;EAIF;;AAEA;EACE;;AAGF;EAEE;EACA;EACA;;AAGF;EACE;;AAGF;EACE;;AAIF;EA3CF;IA4CI;;;;AC9CJ;EACE;EACA;EACA;EACA;EACA;EACA;;AAIA;EAVF;IAWI;;;AAGF;EAdF;IAeI;;;;AAIJ;EACE;;;AAGF;EAII;AAAA;AAAA;IACE;IACA;;;AAMJ;EACE;;;ACnCJ;EACE;EACA;;AAEA;AAAA;EAEE;EACA;;AAGF;EACE;EACA;EACA;;AAEA;EACE;EACA;;AAKF;EACE;EAEA;;AAGF;EACE;;AAKF;AAAA;EAEE;;;AFnCN;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA,YACE;EAIF;;AAEA;EACE;;AAGF;EAEE;EACA;EACA;;AAGF;EACE;;AAGF;EACE;;AAIF;EA3CF;IA4CI;;;;AGhDJ;EACE;;AAEA;EACE;;AAGF;EACE;EACA;EACA;EACA;;AAGF;EACE;EACA;;AAGF;EACE;EACA;EACA;;AAGF;EACE;;AAGF;EACE;EACA;EACA;EACA;EACA;;AAEA;EACE;EACA;;AAIJ;EACE;EACA;EACA;;AAGF;EACE;;AAIF;EACE;IACE;IACA;;;;AASF;AAAA;AAAA;EACE;EACA;;;AAKN;AAAA;EAGE;;AAEA;AAAA;EACE;;;AAKF;EACE;EACA;EACA;;AAGF;EACE;EACA;EACA;EACA;;AAGF;EACE;EACA;;;AClGJ;EACE;EACA;EACA;;AAEA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAEF;EACE;EACA;;;AAMJ;AAAA;EAEE;;;AAIJ;EACE;EACA;EACA;EACA;;AAEA;EACE;;;AAIJ;EACE;EACA;;;AC5CF;EACE;EACA;EACA;EACA;;;AAGF;EACE;EACA;EACA;EACA;;;AAGF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;;AAGF;EACE;;;AAGF;EACE;EACA;EACA;EACA;;;AAIA;EACE;EACA;;;AAIJ;EACE;;;AC3CF;AAAA;EAEE;EACA;EACA;EACA;;AAEA;AAAA;EACE;;;AAKF;EACE;EACA;EACA;;;AAKF;EACE;EACA;EACA;EACA;;AAGF;EACC;EACA;;;AAIH;EACE;;;AAGF;EACE;;;AAGF;AAAA;EAEE;EACA;EACA;;;AAGF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;AAGF;EACE;EACA;EACA;;;AAGF;EACE;EACA;;AAEA;EACE;EACA;;AAEA;EACE;EACA;EACA;EACA;EACA;;AAEA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAIA;AAAA;EACE;;AAGJ;EACE;EACA;;AAKA;AAAA;EACE;;AAGJ;EACE;;;AAON;EACE;EACA;;;ACrHJ;EACE;EACA;EACA;;;AAGF;EACE;EACA;;;AAGF;EACE;;;AAIF;EACE;EACA;;;AAGA;EACE;;;AAIJ;EACE;;;AAGF;EACE;;;AC9BA;EACE;;AAEA;EACE;EACA;EACA;EACA;EACA;;AAEF;EACE;;AAIJ;EACE;EACA;EACA;EACA;EACA;EACA;;AAGF;EACE;EACA;EACA;;AAGF;EACE;;AAGF;EACE;EACA;EACA;EACA;;AAIF;EACE;IACE;IACA;;;;AAKN;AAAA;EAGE;;AAGE;AAAA;EACE;;AAIJ;AAAA;EACE;;;AAKF;EACE;EACA;EACA;;AAGF;EACE;EACA;EACA;EACA;;AAGF;EACE;EACA;;;ACnFJ;EACE;EACA;;;AAGF;EACE;;;AAGF;EACE;EACA;EACA;;;AAGF;EACE;EACA;EACA;;;AAGF;EACE;EACA;;;AAGF;EACE;EACA;EACA;EACA;;AAEA;EACE;;;AAIJ;EACE;;;AAIA;EACE;;;AC3CJ;EACE;EACA;EAEA;EACA;;AAEA;EACE;EACA;EACA;;AAIA;EACE;EACA;EACA;;AAIJ;EACE;;AAGF;EACE;;AAEA;EACE;;AAIJ;EACE;;;ACWJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA","file":"main.css"}
|
|
1
|
+
{"version":3,"sourceRoot":"","sources":["../../src/AttachMenu/AttachMenu.scss","../../src/Chatbot/Chatbot.scss","../../src/ChatbotAlert/ChatbotAlert.scss","../../src/ChatbotContent/ChatbotContent.scss","../../src/ChatbotConversationHistoryNav/ChatbotConversationHistoryNav.scss","../../src/ChatbotFooter/ChatbotFootnote.scss","../../src/ChatbotFooter/ChatbotFooter.scss","../../src/ChatbotHeader/ChatbotHeader.scss","../../src/ChatbotModal/ChatbotModal.scss","../../src/ChatbotPopover/ChatbotPopover.scss","../../src/ChatbotToggle/ChatbotToggle.scss","../../src/ChatbotWelcomePrompt/ChatbotWelcomePrompt.scss","../../src/CodeModal/CodeModal.scss","../../src/Compare/Compare.scss","../../src/DeepThinking/DeepThinking.scss","../../src/FileDetails/FileDetails.scss","../../src/FileDetailsLabel/FileDetailsLabel.scss","../../src/FileDropZone/FileDropZone.scss","../../src/FilePreview/FilePreview.scss","../../src/ImagePreview/ImagePreview.scss","../../src/Message/Message.scss","../../src/Message/MessageLoading.scss","../../src/Message/CodeBlockMessage/CodeBlockMessage.scss","../../src/Message/TextMessage/TextMessage.scss","../../src/Message/SuperscriptMessage/SuperscriptMessage.scss","../../src/Message/ImageMessage/ImageMessage.scss","../../src/Message/LinkMessage/LinkMessage.scss","../../src/Message/ListMessage/ListMessage.scss","../../src/Message/TableMessage/TableMessage.scss","../../src/Message/QuickStarts/QuickStartTile.scss","../../src/Message/QuickResponse/QuickResponse.scss","../../src/Message/UserFeedback/UserFeedback.scss","../../src/MessageBar/AttachButton.scss","../../src/MessageBar/MicrophoneButton.scss","../../src/MessageBar/SendButton.scss","../../src/MessageBar/StopButton.scss","../../src/MessageBar/MessageBar.scss","../../src/MessageBox/JumpButton.scss","../../src/MessageBox/MessageBox.scss","../../src/MessageDivider/MessageDivider.scss","../../src/Onboarding/Onboarding.scss","../../src/ResponseActions/ResponseActions.scss","../../src/Settings/Settings.scss","../../src/SourcesCard/SourcesCard.scss","../../src/SourceDetailsMenuItem/SourceDetailsMenuItem.scss","../../src/TermsOfUse/TermsOfUse.scss","../../src/ToolResponse/ToolResponse.scss","../../src/ToolCall/ToolCall.scss","../../src/main.scss"],"names":[],"mappings":";AAAA;EACE;;;AAGF;AACE;AAsBA;AAKA;;AA1BA;EACE;EACA;EACA;EACA;;AAEF;EACE;;AAGF;AACE;;AACA;EACE;EACA;EACA;EACA;EACA;;AAKJ;EACE;;AAIF;EACE;EACA;;AAGF;EACE;EACA;;AAGF;EACE;EACA;EACA;;AAGF;EACE;;;AC/CJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA,YACE;EAYF;;AAVA;EACE;EACA;EACA;;AAEF;EACE;EACA;;AAOF;EA/BF;IAgCI;IACA;;;AAIF;EArCF;IAsCI;;;AAGF;EACE;;;AAQF;EACE;;;AAOJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAES;EACP;EAEA;EACA;;;AAKF;EAnBF;IAoBI;;;;AAOJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAES;EACP;;;AAOJ;EACE;EACA;EACA;EACA;EACA;;AAES;EACP;EACA;EACA;;;AAIJ;EACE;EACA;EACA;EACA;EACA;EACA;;AAGA;EACE;;AAIF;EAdF;IAeI;;;;AAIJ;EACE;;;AAGF;AAAA;AAAA;EAGE;;;AAMF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAES;EACP;EACA;EACA;;;AAGF;EACE;;;AAKF;EACE;;;AC/KJ;EACE;EACA;EACA;;;ACAF;EACE;EACA;EACA;EACA;EACA;;AAGA;EARF;IASI;;;AAGF;EACE;;;AAKF;EACE;;;AAUJ;EAII;AAAA;AAAA;IACE;IACA;;;AClCJ;EACE;EACA;;AAGF;EACE;EACA;;AAKF;EACE;EACA;EACA;EACA;EACA;;AAEF;EACE;EACA;EACA;;AAEF;EACE;EACA;EACA;EACA;EACA;;AAKA;EACE;EACA;;AAIJ;EACE;;AAKF;EACE;EACA;EAEA;EACA;EACA;;AAEF;EACE;;AAGF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAGF;EACE;EACA;EAEA;EACA;EACA;EACA;EACA;EACA;EACA;;AAGF;EACE;EACA;EACA;EACA;EACA;EAEA;;AAIF;EACE;;AAGF;EACE;;AAGF;EACE;;AAGF;EACE;EACA;EACA;EACA;EACA;EAEA;;AAGF;EACE;;;AAMJ;EACE;EACA;EACA;;AAGA;EACE;EACA;EACA;EACA;EACA;EACA;;AAIF;EACE;EACA;EACA;EACA;EAEA;EACA;EACA;EACA;;AAIF;EACE;EACA;EAEA;EACA;EACA;EACA;EACA;EACA;;AAGF;EACE;;AAKA;EACE;EACA;EACA;EACA;EACA;;AAKJ;EACE;EACA;EACA;EACA;EAEA;EACA;EACA;EACA;;AAKA;EACE;;;AAuBJ;EACE;;;AASF;AAAA;EACE;;AACA;AAAA;EACE;;;AASJ;EACE;;AACA;EACE;EACA;;AAEF;EACE;;;AAUF;AAAA;AAAA;AAAA;EACE;;;AAKN;EACE;EACA;EACA;EACA;;;AAGF;EACE;EACA;EACA;EACA;;;AAKE;EACE;EACA;EACA;EACA;EACA;;AAGF;EACE;EACA;;AAIJ;EACE;;AAGF;EACE;EACA;;AAGA;EACE;EACA;EACA;EACA;EACA;EACA;;;ACrTN;EACE;;AAEA;EACE;EACA;;;ACHJ;EACE;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;;AAKF;EACE;;AAES;EACP;;;AAKN;EACE;EACA;EACA;EACA;EACA;;;AAMF;EAGI;AAAA;IACE;;EAGF;AAAA;IACE;IACA;IACA;;;AASJ;EACE;;;AAQF;EACE;;;AAIJ;EACE;EACA;;;AAQA;EAIM;AAAA;IACE;;;;ACrFV;EACE;;;AAEF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;EACA;;AAEA;EACE;;AAKJ;EACE;EACA;EACA;EACA;;AAEA;EACE;;AAGF;EACE;EACA;;AAIJ;EACE;;AAGF;EACE;EACA;EACA;EACA;EACA;;AACA;EACE;EACA;;;AAMJ;EACE;;AAES;EACP;;;AAQN;AAAA;EAEE;EACA;EACA;EACA;EACA;;AAEA;AAAA;EACE;;AAGF;AAAA;AAAA;AAAA;EAEE;EACA;EACA;;AAMA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;EAGE;;;AAQN;AAAA;EAEE;;;AAGF;EACE;;;AAGF;EACE;;;AAOA;EACE;EACA;;AAGF;EACE;EACA;;;AAIJ;AAAA;EAEE;EACA;;;AAGF;EACE;;;AC3IF;EACE;;;AAGF;EACE;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAGF;EACE;EACA;EACA;;AAIF;EACE;;;AAOJ;EACE;AAAA;IAEE;IACA;IACA;IACA;IACA;IACA;IACA;;;AAGJ;EACE;AAAA;IAEE;IACA;IACA;IACA;IACA;IACA;IACA;;;AAOJ;EACE;EACA;EACA;EACA;EACA;;;AAQE;EACE;;;AAQN;EACE;;;AAOA;EACE;;AAGF;EACE;EACA;;;AC3FF;EACE;;AAMA;EACE;;AAEF;EACE;;AAEF;EACE;;AAIF;EACE;EACA;;AAEF;EACE;;;ACxBN;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAIF;EACE;EACA;;AAGF;EACE;;AAGF;EACE;EACA;EACA;;AAEA;EACE;;;AAKN;EACE;EACA;EACA;;;AC5CF;EACE;EACA;EACA;EACA;;AAEA;EACE;EACA;;AAGF;EACE;;AAGF;EACE;;AAGF;EACE;EACA;EACA;;AAGF;EACE;EACA;EACA;;;AAIJ;EACE;EACA;;AAEA;EACE;;;AAOJ;EAIM;AAAA;IACE;IACA;;;ACpDN;EACE;EACA;EACA;EACA;EACA;;AAEF;EACE;EACA;AACA;EACA;EACA;;AAEF;EACE;;AAEF;EACE;EACA;;AAEF;EACE;;AAEF;EACE;EACA;EACA;AAAA;AAAA;EAGA;EACA;;AAEF;EACE;EACA;;AAEF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAEF;EACE;;AAEF;EACE;EACA;EACA;;AAEF;EACE;;AAEF;EACE;EACA;;AAEF;EACE;;AAGA;EACE;;;AAUF;EACE;EACA;;;AAKN;EACE;;;AAGF;EACE;;;AAIA;EACE;;;AC9FJ;EACE;EACA;EACA;EACA;;;AAEF;EACE;;AAEA;EACE;EACA;EACA;;;AAGJ;EACE;EACA;EACA;;AAEA;EALF;IAMI;;;AAGF;EACE;;AAEA;EAHF;IAII;;;;AAKN;EACE;;AAEA;EACE;;AAGF;EACE;;AAIA;EADF;IAEI;;;;AAIN;EACE;;AAEA;EAHF;IAII;;;;AAIJ;EACE;EACA;EACA;EACA;EACA;EACA;;AAEA;EARF;IASI;IACA;IACA;;;;ACrEJ;EACE;EACA;;;AAGF;EACE;;;AAGF;EACE;EACA;EACA;;;AAGF;EACE;EACA;EACA;;;AAGF;EACE;;;ACtBF;EACE;EACA;EACA;EACA;;;AAGF;EACE;EACA;EACA;;;AAGF;EACE;EACA;EACA;;;AAGF;EACE;;;AAGF;EACE;;;AAIF;EACE;EACA;EACA;EACA;EACA;;;ACjCF;EACE;EACA;EACA;EACA;;;AAGF;EACE;EAEA;EACA;EACA;;AACA;EACE;;AAGF;AAAA;EAEE;EACA;;;AAIJ;EACE;EACA;EACA;;AAEA;EACE;;AAGO;EACP;EACA;;;AAKF;EACE;;AAGF;EACE;;;AAIJ;AAAA;EAEE;EACA;;AAEA;AAAA;EACE;;;AAKF;EACE;;;AAMF;AAAA;EACE;;;ACpEJ;EACE;EACA;;;AAGF;EACE;EACA;EACA;;AAGA;EANF;IAOI;;;;AAIJ;EACE;EACA;EACA;EACA;;AAEA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;AAIJ;AACA;EACE;EACA;EACA;EACA;;;AAME;EADF;IAEI;IACA;IACA;;EAEA;IACE;;;;ACnDR;EACE;EACA;EACA;EACA;EACA;;;AAGF;EACE;EACA;EACA;;;AAGF;EACE;EACA;;;AAEF;EACE;EACA;;;ACpBF;EACE;EACA;EACA;EACA;EACA;;AAEA;EACE;EACA;;AAEF;EACE;;;AAIJ;EACE;;;AAGF;EACE;;;AAGF;EACE;EACA;EACA;EACA;EACA;;AAEA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAIA;AAAA;EACE;;AAGJ;EACE;EACA;;AAKA;AAAA;EACE;;AAGJ;EACE;;;ACvDJ;EACE;EACA;EACA;EACA;;AAIA;EACE;EACA;EACA;EACA;EACA;EACA;;AAGF;EACE;;AAGF;EAKE;;AAJA;EACE;EACA;;AAOJ;EACE;EACA;;AAKF;EACE;EACA;EACA;EACA;;AAKF;EACE;EACA;EACA;;AAGA;EACE;EAQA;EACA;;AAIF;EACE;EACA;;AAIF;EACE;;AAEF;EACE;;AAMJ;EACE;EACA;EACA;EACA;EACA;;AAGF;EACE;EACA;;AAGF;EACE;EACA;EACA;EACA;;AAGF;AAAA;EAEE;;AAIF;AAAA;EAEE;EACA;EACA;;AAEA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;EAME;EACA;EACA;EACA;EACA;EACA;;AAEF;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;EAKE;;AAEF;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;EAQE;;AAIJ;EACE;;AAIF;EACE;;AAEA;EACE;;;AAON;EACE;EACA;EACA;;;AAGF;EACE;;;AC1KF;EACE;EACA;EACA;EACA;EAEA;;AAGA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEF;EAEE;EACA;EACA;EACA;;AAEF;EACE;EACA;EACA;EACA;EACA;EACA;;AAEF;EACE;EACA;EACA;EACA;EACA;EACA;;AAGF;EACE;IACE;;EAEF;IAEE;;;AAIJ;EACE;;;ACtDJ;EACE;EACA;EACA;EACA;;AAGA;EACE;EACA;;AAIF;EACE;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAGF;EACE;EACA;;AAIF;EACE;EACA;EACA;EACA;EACA;EACA;;AAGF;EACE;;AAEA;EAEE;;AAMN;EACE;EACA;EACA;EACA;EACA;;AAEA;AAAA;EAEE;EACA;EACA;;AAEF;EACE;EACA;EACA;;AAGF;EACE;EACA;;AAIJ;EACE;;;AAIJ;EACE;EAEA;EACA;EACA;EAEA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;;AAKF;EACE;EACA;;;ACrGJ;EACE;;AAGE;EACE;;;AAMN;EACE;EACA;EACA;EACA;;AAEA;EACE;;AAGF;AAAA;AAAA;AAAA;AAAA;EAKE;;AAGF;EACE;EACA;;AAKF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAIA;EACE;;AAIJ;EACE;;AAEF;EACE;EACA;;;AAUJ;EAIE;;;AAIF;EAKE;;;AAIA;EACE;;;AAKF;EACE;EACA;EACA;EACA;;AACA;EACE;;AAGF;AAAA;AAAA;AAAA;AAAA;EAKE;;AAIJ;EACE;;AAGF;EACE;EACA;;;AASF;EACE;;AACA;EACE;;AAGF;AAAA;AAAA;AAAA;AAAA;EAKE;;AAGF;EACE;EACA;;;AC/IN;EACE;EACA;;AACA;EACE;EACA;;;AJoLF;EACE;EACA;;AAEA;EACE;;AAIJ;EACE;;AAIA;EACE;EACA;;AAIJ;EACE;;;AE3MJ;EACE;EACA;EACA;EACA;;AAGA;EACE;EACA;;AAIF;EACE;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAGF;EACE;EACA;;AAIF;EACE;EACA;EACA;EACA;EACA;EACA;;AAGF;EACE;;AAEA;EAEE;;AAMN;EACE;EACA;EACA;EACA;EACA;;AAEA;AAAA;EAEE;EACA;EACA;;AAEF;EACE;EACA;EACA;;AAGF;EACE;EACA;;AAIJ;EACE;;;AAIJ;EACE;EAEA;EACA;EACA;EAEA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;;AAKF;EACE;EACA;;;AGzGJ;EACE;EACA;EACA;EACA;EAGA;;;ACNA;EACE;;;AHEJ;EACE;;AAGE;EACE;;;AAMN;EACE;EACA;EACA;EACA;;AAEA;EACE;;AAGF;AAAA;AAAA;AAAA;AAAA;EAKE;;AAGF;EACE;EACA;;AAKF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAIA;EACE;;AAIJ;EACE;;AAEF;EACE;EACA;;;AAUJ;EAIE;;;AAIF;EAKE;;;AAIA;EACE;;;AAKF;EACE;EACA;EACA;EACA;;AACA;EACE;;AAGF;AAAA;AAAA;AAAA;AAAA;EAKE;;AAIJ;EACE;;AAGF;EACE;EACA;;;AASF;EACE;;AACA;EACE;;AAGF;AAAA;AAAA;AAAA;AAAA;EAKE;;AAGF;EACE;EACA;;;AI3IN;AAAA;EAEE;EACA;EACA;;AAEA;AAAA;AAAA;AAAA;AAAA;AAAA;EAGE;;AAIA;AAAA;AAAA;AAAA;AAAA;AAAA;EAGE;;;AAMJ;AAAA;EAEE;EACA;EACA;;AAGA;AAAA;EACE;;AAMF;EACE;EACA;;AAIJ;EACE;;;AC/CJ;EACE;EACA;EACA;EAEA;;AAEA;EACE;;AAGF;EACE;;AAGF;EACE;;AAGF;EACE;EACA;;AAGF;EACE;;AAIA;AAAA;AAAA;AAAA;AAAA;AAAA;EAME;;;APhCN;EACE;EACA;EACA;EACA;EAEA;;AAGA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEF;EAEE;EACA;EACA;EACA;;AAEF;EACE;EACA;EACA;EACA;EACA;EACA;;AAEF;EACE;EACA;EACA;EACA;EACA;EACA;;AAGF;EACE;IACE;;EAEF;IAEE;;;AAIJ;EACE;;;AQzDJ;EACE;EACA;;AAEA;EAJF;IAKI;IACA;;;AAKA;EACE;;;AAOF;EACE;;;AClBF;EACE;;AAGF;EALF;IAMI;;;AAGF;EATF;IAUI;;;AAKF;EACE;EACA;;AAIJ;AAAA;EAEE;EACA;;AAIF;EACE;EACA;EACA;;;AC/BJ;EACE;EAEA;EACA;;;AAIF;EACE;EACA;EACA;EACA;EACA;;;AAEF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;;AAEF;EACE;EACA;EACA;;;AAEF;EACE;EACA;EACA;EACA;;;AAKA;EACE;;;AAGJ;EACE;EACA;EACA;EACA;;;AAGF;EACE;;;AAGF;EACE;;;AAIF;EACE;EACA;EACA;EACA;;;AAIF;EACE;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAEA;EACE;;AAGF;EACE;;;AAMJ;EACE;;AAGF;EACE;;AAIA;EACE;;;AC/FN;EACE;EACA;EACA;EACA;;AAEA;EACE;;AAKA;EACE;;AAIJ;EAEE;;AAEA;EACE;;AAKA;EACE;;;AASR;EACE;EACA;EACA;;;ACxCF;EACE;EACA;EACA;EACA;;AAEA;EACE;;AAMA;EACE;;AAKJ;EACE;EACA;;AAGA;EACE;;AAKA;EACE;;;AAMR;EACE;IACE;;EAEF;IACE;;;AAOJ;EACE;EACA;EACA;;;ACpDF;EACE;EACA;EACA;EACA;;AAEA;EACE;;AAGF;EAEE;EACA;;AAEA;EACE;;;AAMJ;EACE;;AACA;EACE;;AAIJ;EACE;EACA;;AAGF;AAAA;EAEE;;;AAIJ;EACE;IACE;IACA;;EAEF;IACE;IACA;;;AAOJ;EACE;EACA;EACA;;;ACzDF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAGF;EACE;;AAGF;EACE;;AAEA;EACE;;AAKA;EACE;;;AASR;EACE;EACA;EACA;;;ACjCF;EACE;EACA;EAEA;EACA;EAEA;EACA;EACA;EACA;EACA;EAIA;EACA;EAEA;EACA;EAEA;;AAEA;EACE;EACA;EACA;EACA;EACA;EAEA;EACA,YACE;;AAKF;EACE;EACA;;AAKF;EACE;EACA;;AAIJ;EACE;EACA;EACA;EACA;EACA;;AAEA;EACE;EACA;;AAIJ;EACE;EACA;EACA;EACA;EACA;;AAGF;EACE;EACA;EACA;;;AAIJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAEF;EACE;EACA;EACA;EACA;EACA;;AAEF;EACE;;;AAIJ;EACE;EACA;EACA;EACA;EACA;;;AAGF;EACE;EACA;EACA;EACA;;;AAGF;EACE;IACE;IACA;;;AAKF;EACE;IACE;IACA;;;;AAQN;EACE;EACA;;AAEA;EACE;;;AAKF;AAAA;EAEE;EACA;;;AAOJ;EACE;;;AC1KF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA,YACE;EAIF;;AAEA;EACE;;AAGF;EAEE;EACA;EACA;;AAGF;EACE;;AAGF;EACE;;AAIF;EA3CF;IA4CI;;;;AC9CJ;EACE;EACA;EACA;EACA;EACA;EACA;;AAIA;EAVF;IAWI;;;AAGF;EAdF;IAeI;;;;AAIJ;EACE;;;AAGF;EAII;AAAA;AAAA;IACE;IACA;;;AAMJ;EACE;;;ACnCJ;EACE;EACA;;AAEA;AAAA;EAEE;EACA;;AAGF;EACE;EACA;EACA;;AAEA;EACE;EACA;;AAKF;EACE;EAEA;;AAGF;EACE;;AAKF;AAAA;EAEE;;;AFnCN;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA,YACE;EAIF;;AAEA;EACE;;AAGF;EAEE;EACA;EACA;;AAGF;EACE;;AAGF;EACE;;AAIF;EA3CF;IA4CI;;;;AGhDJ;EACE;;AAEA;EACE;;AAGF;EACE;EACA;EACA;EACA;;AAGF;EACE;EACA;;AAGF;EACE;EACA;EACA;;AAGF;EACE;;AAGF;EACE;EACA;EACA;EACA;EACA;;AAEA;EACE;EACA;;AAIJ;EACE;EACA;EACA;;AAGF;EACE;;AAIF;EACE;IACE;IACA;;;;AASF;AAAA;AAAA;EACE;EACA;;;AAKN;AAAA;EAGE;;AAEA;AAAA;EACE;;;AAKF;EACE;EACA;EACA;;AAGF;EACE;EACA;EACA;EACA;;AAGF;EACE;EACA;;;AClGJ;EACE;EACA;EACA;;AAEA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAEF;EACE;EACA;;;AAMJ;AAAA;EAEE;;;AAIJ;EACE;EACA;EACA;EACA;;AAEA;EACE;;;AAIJ;EACE;EACA;;;AC5CF;EACE;EACA;EACA;EACA;;;AAGF;EACE;EACA;EACA;EACA;;;AAGF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;;AAGF;EACE;;;AAGF;EACE;EACA;EACA;EACA;;;AAIA;EACE;EACA;;;AAIJ;EACE;;;AC3CF;AAAA;EAEE;EACA;EACA;EACA;;AAEA;AAAA;EACE;;;AAKF;EACE;EACA;EACA;;;AAKF;EACE;EACA;EACA;EACA;;AAGF;EACC;EACA;;;AAIH;EACE;;;AAGF;EACE;;;AAGF;AAAA;EAEE;EACA;EACA;;;AAGF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;AAGF;EACE;EACA;EACA;;;AAGF;EACE;EACA;;AAEA;EACE;EACA;;AAEA;EACE;EACA;EACA;EACA;EACA;;AAIE;AAAA;EACE;;AAMF;AAAA;EACE;;AAGJ;EACE;;;AAON;EACE;EACA;;;ACxGJ;EACE;EACA;EACA;;;AAGF;EACE;EACA;;;AAGF;EACE;;;AAIF;EACE;EACA;;;AAGA;EACE;;;AAIJ;EACE;;;AAGF;EACE;;;AC9BA;EACE;;AAEA;EACE;EACA;EACA;EACA;EACA;;AAEF;EACE;;AAIJ;EACE;EACA;EACA;EACA;EACA;EACA;;AAGF;EACE;EACA;EACA;;AAGF;EACE;;AAGF;EACE;EACA;EACA;EACA;;AAIF;EACE;IACE;IACA;;;;AAKN;AAAA;EAGE;;AAGE;AAAA;EACE;;AAIJ;AAAA;EACE;;;AAKF;EACE;EACA;EACA;;AAGF;EACE;EACA;EACA;EACA;;AAGF;EACE;EACA;;;ACnFJ;EACE;EACA;;;AAGF;EACE;;;AAGF;EACE;EACA;EACA;;;AAGF;EACE;EACA;EACA;;;AAGF;EACE;EACA;;;AAGF;EACE;EACA;EACA;EACA;;AAEA;EACE;;;AAIJ;EACE;;;AAIA;EACE;;;AC3CJ;EACE;EACA;EAEA;EACA;;AAEA;EACE;EACA;EACA;;AAIA;EACE;EACA;EACA;;AAIJ;EACE;;AAGF;EACE;;AAEA;EACE;;AAIJ;EACE;;;ACWJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA","file":"main.css"}
|
|
@@ -12,7 +12,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
12
12
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
13
13
|
import { forwardRef, useEffect, useMemo, useRef, useState } from 'react';
|
|
14
14
|
import { Button, Icon, Tooltip } from '@patternfly/react-core';
|
|
15
|
-
import
|
|
15
|
+
import { RhUiMenuBarsIcon } from '@patternfly/react-icons/dist/esm/icons/rh-ui-menu-bars-icon';
|
|
16
16
|
const ChatbotHeaderMenuBase = (_a) => {
|
|
17
17
|
var { className, onMenuToggle, tooltipProps, menuAriaLabel = 'Chat history drawer', innerRef, tooltipContent = 'Chat history drawer', isCompact } = _a, props = __rest(_a, ["className", "onMenuToggle", "tooltipProps", "menuAriaLabel", "innerRef", "tooltipContent", "isCompact"]);
|
|
18
18
|
const [isDrawerAnimating, setIsDrawerAnimating] = useState(false);
|
|
@@ -39,7 +39,7 @@ const ChatbotHeaderMenuBase = (_a) => {
|
|
|
39
39
|
return () => clearTimeout(timeout);
|
|
40
40
|
}
|
|
41
41
|
}, [drawerState, isDrawerOpen]);
|
|
42
|
-
const button = useMemo(() => (_jsx(Button, Object.assign({ className: `pf-chatbot__button--toggle-menu ${isCompact ? 'pf-m-compact' : ''}`, variant: "plain", onClick: onMenuToggle, "aria-label": menuAriaLabel, ref: innerRef !== null && innerRef !== void 0 ? innerRef : buttonRef, icon: _jsx(Icon, { size: isCompact ? 'lg' : 'xl', isInline: true, children: _jsx(
|
|
42
|
+
const button = useMemo(() => (_jsx(Button, Object.assign({ className: `pf-chatbot__button--toggle-menu ${isCompact ? 'pf-m-compact' : ''}`, variant: "plain", onClick: onMenuToggle, "aria-label": menuAriaLabel, ref: innerRef !== null && innerRef !== void 0 ? innerRef : buttonRef, icon: _jsx(Icon, { size: isCompact ? 'lg' : 'xl', isInline: true, children: _jsx(RhUiMenuBarsIcon, {}) }), size: isCompact ? 'sm' : undefined }, props))),
|
|
43
43
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
44
44
|
[isCompact, menuAriaLabel, onMenuToggle, innerRef, buttonRef]);
|
|
45
45
|
return (_jsx("div", { className: `pf-chatbot__menu ${className}`, children: isDrawerAnimating ? (button) : (_jsx(Tooltip, Object.assign({ content: tooltipContent, position: "bottom",
|
|
@@ -13,9 +13,9 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
13
13
|
import { Button, Label } from '@patternfly/react-core';
|
|
14
14
|
import FileDetails from '../FileDetails';
|
|
15
15
|
import { Spinner } from '@patternfly/react-core';
|
|
16
|
-
import {
|
|
16
|
+
import { RhMicronsCloseIcon } from '@patternfly/react-icons';
|
|
17
17
|
export const FileDetailsLabel = (_a) => {
|
|
18
|
-
var { fileName, fileId, isLoading, onClick, onClose, closeButtonAriaLabel, languageTestId, spinnerTestId, fileSize, hasTruncation = true, closeButtonIcon = _jsx(
|
|
18
|
+
var { fileName, fileId, isLoading, onClick, onClose, closeButtonAriaLabel, languageTestId, spinnerTestId, fileSize, hasTruncation = true, closeButtonIcon = _jsx(RhMicronsCloseIcon, {}) } = _a, props = __rest(_a, ["fileName", "fileId", "isLoading", "onClick", "onClose", "closeButtonAriaLabel", "languageTestId", "spinnerTestId", "fileSize", "hasTruncation", "closeButtonIcon"]);
|
|
19
19
|
const handleClose = (event) => {
|
|
20
20
|
onClose && onClose(event, fileName, fileId);
|
|
21
21
|
};
|
|
@@ -13,11 +13,11 @@ import { jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
|
|
|
13
13
|
import { MultipleFileUpload, MultipleFileUploadMain } from '@patternfly/react-core';
|
|
14
14
|
import { useState } from 'react';
|
|
15
15
|
import { ChatbotDisplayMode } from '../Chatbot';
|
|
16
|
-
import {
|
|
16
|
+
import { RhUiUploadIcon } from '@patternfly/react-icons';
|
|
17
17
|
const FileDropZone = (_a) => {
|
|
18
18
|
var { children, className, infoText = 'Maximum file size is 25 MB', onFileDrop, allowedFileTypes, minSize, maxSize, maxFiles, isAttachmentDisabled, onAttach, onAttachRejected, validator, displayMode = ChatbotDisplayMode.default } = _a, props = __rest(_a, ["children", "className", "infoText", "onFileDrop", "allowedFileTypes", "minSize", "maxSize", "maxFiles", "isAttachmentDisabled", "onAttach", "onAttachRejected", "validator", "displayMode"]);
|
|
19
19
|
const [showDropZone, setShowDropZone] = useState(false);
|
|
20
|
-
const renderDropZone = () => (_jsx(_Fragment, { children: _jsx(MultipleFileUploadMain, { titleIcon: _jsx(
|
|
20
|
+
const renderDropZone = () => (_jsx(_Fragment, { children: _jsx(MultipleFileUploadMain, { titleIcon: _jsx(RhUiUploadIcon, {}), titleText: "Drag and drop your file here", infoText: infoText, isUploadButtonHidden: true }) }));
|
|
21
21
|
return (_jsx(MultipleFileUpload, { dropzoneProps: Object.assign({ accept: allowedFileTypes, onDrop: (acceptedFiles, fileRejections, event) => {
|
|
22
22
|
setShowDropZone(false);
|
|
23
23
|
onAttach && onAttach(acceptedFiles, fileRejections, event);
|
|
@@ -15,7 +15,7 @@ import { useState, useEffect } from 'react';
|
|
|
15
15
|
import { ChatbotDisplayMode } from '../Chatbot';
|
|
16
16
|
import ChatbotModal from '../ChatbotModal';
|
|
17
17
|
import FileDetailsLabel from '../FileDetailsLabel';
|
|
18
|
-
import {
|
|
18
|
+
import { RhUiTrashFillIcon } from '@patternfly/react-icons';
|
|
19
19
|
const ImagePreview = (_a) => {
|
|
20
20
|
var { isModalOpen, displayMode = ChatbotDisplayMode.default, isCompact, className, handleModalToggle, title = 'Preview images', modalHeaderProps, modalBodyProps, images, isDisabled, onSetPage, onPreviousClick, toNextPageAriaLabel = 'Go to next image', toPreviousPageAriaLabel = 'Go to previous image', onNextClick, paginationAriaLabel, onCloseFileDetailsLabel, fileDetailsLabelProps, paginationContent, screenreaderText } = _a, props = __rest(_a, ["isModalOpen", "displayMode", "isCompact", "className", "handleModalToggle", "title", "modalHeaderProps", "modalBodyProps", "images", "isDisabled", "onSetPage", "onPreviousClick", "toNextPageAriaLabel", "toPreviousPageAriaLabel", "onNextClick", "paginationAriaLabel", "onCloseFileDetailsLabel", "fileDetailsLabelProps", "paginationContent", "screenreaderText"]);
|
|
21
21
|
const [page, setPage] = useState(1);
|
|
@@ -29,7 +29,7 @@ const ImagePreview = (_a) => {
|
|
|
29
29
|
setPage(newPage);
|
|
30
30
|
onSetPage && onSetPage(_evt, newPage);
|
|
31
31
|
};
|
|
32
|
-
return (_jsxs(ChatbotModal, Object.assign({ isOpen: isModalOpen, className: `pf-chatbot__image-preview-modal pf-chatbot__image-preview-modal--${displayMode} ${isCompact ? 'pf-m-compact' : ''} ${className ? className : ''}`, displayMode: displayMode, onClose: handleModalToggle, isCompact: isCompact }, props, { children: [_jsx(ModalHeader, Object.assign({ title: title }, modalHeaderProps)), _jsx(ModalBody, Object.assign({ className: "pf-chatbot__image-preview-body" }, modalBodyProps, { children: images.length > 0 && images[page - 1] && (_jsxs(Stack, { hasGutter: true, className: "pf-chatbot__image-preview-stack", children: [_jsx(StackItem, { children: _jsx(FileDetailsLabel, Object.assign({ fileName: images[page - 1].fileName, fileSize: images[page - 1].fileSize, hasTruncation: false, onClose: onCloseFileDetailsLabel, closeButtonIcon: _jsx(
|
|
32
|
+
return (_jsxs(ChatbotModal, Object.assign({ isOpen: isModalOpen, className: `pf-chatbot__image-preview-modal pf-chatbot__image-preview-modal--${displayMode} ${isCompact ? 'pf-m-compact' : ''} ${className ? className : ''}`, displayMode: displayMode, onClose: handleModalToggle, isCompact: isCompact }, props, { children: [_jsx(ModalHeader, Object.assign({ title: title }, modalHeaderProps)), _jsx(ModalBody, Object.assign({ className: "pf-chatbot__image-preview-body" }, modalBodyProps, { children: images.length > 0 && images[page - 1] && (_jsxs(Stack, { hasGutter: true, className: "pf-chatbot__image-preview-stack", children: [_jsx(StackItem, { children: _jsx(FileDetailsLabel, Object.assign({ fileName: images[page - 1].fileName, fileSize: images[page - 1].fileSize, hasTruncation: false, onClose: onCloseFileDetailsLabel, closeButtonIcon: _jsx(Icon, { size: "md", children: _jsx(RhUiTrashFillIcon, {}) }) }, fileDetailsLabelProps)) }), _jsx(StackItem, { children: _jsx("div", { className: "pf-chatbot__image-preview-body", children: images[page - 1].image }) })] })) })), images.length > 1 && (_jsx(ModalFooter, { className: "pf-chatbot__image-preview-footer", children: _jsxs("nav", { className: `pf-chatbot__image-preview-footer-buttons`, "aria-label": paginationAriaLabel, children: [_jsx(Button, { variant: ButtonVariant.plain, isDisabled: isDisabled || page === 1, "data-action": "previous", onClick: (event) => {
|
|
33
33
|
const newPage = page > 1 ? page - 1 : 1;
|
|
34
34
|
handleNewPage(event, newPage);
|
|
35
35
|
onPreviousClick && onPreviousClick(event, newPage);
|
|
@@ -16,9 +16,8 @@ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-run
|
|
|
16
16
|
import { useState, useRef, useCallback, useEffect } from 'react';
|
|
17
17
|
// Import PatternFly components
|
|
18
18
|
import { CodeBlock, CodeBlockAction, CodeBlockCode, Button, Tooltip, ExpandableSection, ExpandableSectionToggle, ExpandableSectionVariant, getUniqueId } from '@patternfly/react-core';
|
|
19
|
-
import { CheckIcon } from '@patternfly/react-icons/dist/esm/icons/check-icon';
|
|
20
19
|
import { css } from '@patternfly/react-styles';
|
|
21
|
-
import { RhUiCopyFillIcon } from '@patternfly/react-icons';
|
|
20
|
+
import { RhMicronsCheckmarkIcon, RhUiCopyFillIcon } from '@patternfly/react-icons';
|
|
22
21
|
const DEFAULT_EXPANDED_TEXT = 'Show less';
|
|
23
22
|
const DEFAULT_COLLAPSED_TEXT = 'Show more';
|
|
24
23
|
const CodeBlockMessage = (_a) => {
|
|
@@ -73,7 +72,7 @@ const CodeBlockMessage = (_a) => {
|
|
|
73
72
|
return (_jsx("code", Object.assign({}, props, { className: `pf-chatbot__message-inline-code ${isPrimary ? 'pf-m-primary' : ''}`, children: children })));
|
|
74
73
|
}
|
|
75
74
|
// Setup code block header
|
|
76
|
-
const actions = (_jsxs(_Fragment, { children: [_jsxs(CodeBlockAction, { className: "pf-chatbot__message-code-block-default-action", children: [language && _jsx("div", { className: "pf-chatbot__message-code-block-language", children: language }), _jsx(Button, { ref: buttonRef, "aria-label": ariaLabel !== null && ariaLabel !== void 0 ? ariaLabel : 'Copy code', variant: "plain", className: "pf-chatbot__button--copy", onClick: (event) => handleCopy(event, children), children: copied ? _jsx(
|
|
75
|
+
const actions = (_jsxs(_Fragment, { children: [_jsxs(CodeBlockAction, { className: "pf-chatbot__message-code-block-default-action", children: [language && _jsx("div", { className: "pf-chatbot__message-code-block-language", children: language }), _jsx(Button, { ref: buttonRef, "aria-label": ariaLabel !== null && ariaLabel !== void 0 ? ariaLabel : 'Copy code', variant: "plain", className: "pf-chatbot__button--copy", onClick: (event) => handleCopy(event, children), children: copied ? _jsx(RhMicronsCheckmarkIcon, {}) : _jsx(RhUiCopyFillIcon, {}) }), _jsx(Tooltip, { id: tooltipID, content: "Copy", position: "top", triggerRef: buttonRef })] }), customActions] }));
|
|
77
76
|
return (_jsx("div", { className: css('pf-chatbot__message-code-block', shouldRetainStyles && 'pf-m-markdown'), ref: codeBlockRef, children: _jsxs(CodeBlock, { actions: actions, children: [_jsx(CodeBlockCode, { children: _jsx(_Fragment, { children: isExpandable ? (_jsx(ExpandableSection, Object.assign({ variant: ExpandableSectionVariant.truncate, isExpanded: isExpanded, isDetached: true, toggleId: toggleId, contentId: contentId }, expandableSectionProps, { children: children }))) : (children) }) }), isExpandable && (_jsx(ExpandableSectionToggle, Object.assign({ isExpanded: isExpanded, onToggle: onToggle, direction: "up", toggleId: toggleId, contentId: contentId, hasTruncatedContent: true, className: "pf-chatbot__message-code-toggle" }, expandableSectionToggleProps, { children: isExpanded ? finalExpandedText : finalCollapsedText })))] }) }));
|
|
78
77
|
};
|
|
79
78
|
export default CodeBlockMessage;
|
|
@@ -18,26 +18,7 @@ import { monitorSampleAppQuickStartWithImage } from './QuickStarts/monitor-sampl
|
|
|
18
18
|
import rehypeExternalLinks from '../__mocks__/rehype-external-links';
|
|
19
19
|
import { AlertActionLink, Button, CodeBlockAction } from '@patternfly/react-core';
|
|
20
20
|
// Mock the icon components
|
|
21
|
-
jest.mock('@patternfly/react-icons', () => ({
|
|
22
|
-
RhUiLikeIcon: () => _jsx("div", { children: "RhUiLikeIcon" }),
|
|
23
|
-
RhUiLikeFillIcon: () => _jsx("div", { children: "RhUiLikeFillIcon" }),
|
|
24
|
-
RhUiDislikeIcon: () => _jsx("div", { children: "RhUiDislikeIcon" }),
|
|
25
|
-
RhUiDislikeFillIcon: () => _jsx("div", { children: "RhUiDislikeFillIcon" }),
|
|
26
|
-
RhUiCopyIcon: () => _jsx("div", { children: "RhUiCopyIcon" }),
|
|
27
|
-
RhUiCopyFillIcon: () => _jsx("div", { children: "RhUiCopyFillIcon" }),
|
|
28
|
-
RhUiEditIcon: () => _jsx("div", { children: "RhUiEditIcon" }),
|
|
29
|
-
RhUiEditFillIcon: () => _jsx("div", { children: "RhUiEditFillIcon" }),
|
|
30
|
-
RhUiVolumeUpIcon: () => _jsx("div", { children: "RhUiVolumeUpIcon" }),
|
|
31
|
-
RhUiVolumeUpFillIcon: () => _jsx("div", { children: "RhUiVolumeUpFillIcon" }),
|
|
32
|
-
RhUiExportIcon: () => _jsx("div", { children: "RhUiExportIcon" }),
|
|
33
|
-
RhUiExportFillIcon: () => _jsx("div", { children: "RhUiExportFillIcon" }),
|
|
34
|
-
RhMicronsInformationFillIcon: () => _jsx("div", { children: "RhMicronsInformationFillIcon" }),
|
|
35
|
-
CheckIcon: () => _jsx("div", { children: "CheckIcon" }),
|
|
36
|
-
CloseIcon: () => _jsx("div", { children: "CloseIcon" }),
|
|
37
|
-
ExternalLinkSquareAltIcon: () => _jsx("div", { children: "ExternalLinkSquareAltIcon" }),
|
|
38
|
-
TimesIcon: () => _jsx("div", { children: "TimesIcon" }),
|
|
39
|
-
RhUiBackwardsIcon: () => _jsx("div", { children: "RhUiBackwardsIcon" })
|
|
40
|
-
}));
|
|
21
|
+
jest.mock('@patternfly/react-icons', () => (Object.assign(Object.assign({}, jest.requireActual('@patternfly/react-icons')), { RhUiLikeIcon: () => _jsx("div", { children: "RhUiLikeIcon" }), RhUiLikeFillIcon: () => _jsx("div", { children: "RhUiLikeFillIcon" }), RhUiDislikeIcon: () => _jsx("div", { children: "RhUiDislikeIcon" }), RhUiDislikeFillIcon: () => _jsx("div", { children: "RhUiDislikeFillIcon" }), RhUiCopyIcon: () => _jsx("div", { children: "RhUiCopyIcon" }), RhUiCopyFillIcon: () => _jsx("div", { children: "RhUiCopyFillIcon" }), RhUiEditIcon: () => _jsx("div", { children: "RhUiEditIcon" }), RhUiEditFillIcon: () => _jsx("div", { children: "RhUiEditFillIcon" }), RhUiVolumeUpIcon: () => _jsx("div", { children: "RhUiVolumeUpIcon" }), RhUiVolumeUpFillIcon: () => _jsx("div", { children: "RhUiVolumeUpFillIcon" }), RhUiExportIcon: () => _jsx("div", { children: "RhUiExportIcon" }), RhUiExportFillIcon: () => _jsx("div", { children: "RhUiExportFillIcon" }), RhMicronsInformationFillIcon: () => _jsx("div", { children: "RhMicronsInformationFillIcon" }), RhUiBackwardsIcon: () => _jsx("div", { children: "RhUiBackwardsIcon" }), RhMicronsExternalLinkIcon: () => _jsx("div", { children: "RhMicronsExternalLinkIcon" }), RhMicronsCheckmarkIcon: () => _jsx("div", { children: "RhMicronsCheckmarkIcon" }), RhMicronsCloseIcon: () => _jsx("div", { children: "RhMicronsCloseIcon" }), RhUiBookmarkIcon: () => _jsx("div", { children: "RhUiBookmarkIcon" }), RhUiClockIcon: () => _jsx("div", { children: "RhUiClockIcon" }), RhUiRocketFillIcon: () => _jsx("div", { children: "RhUiRocketFillIcon" }) })));
|
|
41
22
|
const ALL_ACTIONS = [
|
|
42
23
|
{ label: /Good response/i },
|
|
43
24
|
{ label: /Bad response/i },
|
|
@@ -12,7 +12,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
12
12
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
13
13
|
import { useState } from 'react';
|
|
14
14
|
import { Label, LabelGroup } from '@patternfly/react-core';
|
|
15
|
-
import {
|
|
15
|
+
import { RhMicronsCheckmarkIcon } from '@patternfly/react-icons';
|
|
16
16
|
import { css } from '@patternfly/react-styles';
|
|
17
17
|
export const QuickResponse = ({ quickResponses, quickResponseContainerProps = { numLabels: 5 }, onSelect, isCompact }) => {
|
|
18
18
|
const [selectedQuickResponse, setSelectedQuickResponse] = useState();
|
|
@@ -23,7 +23,7 @@ export const QuickResponse = ({ quickResponses, quickResponseContainerProps = {
|
|
|
23
23
|
};
|
|
24
24
|
return (_jsx(LabelGroup, Object.assign({ className: css('pf-chatbot__message-quick-response', quickResponseContainerProps === null || quickResponseContainerProps === void 0 ? void 0 : quickResponseContainerProps.className) }, quickResponseContainerProps, { children: quickResponses.map((_a) => {
|
|
25
25
|
var { id, onClick, content, className } = _a, props = __rest(_a, ["id", "onClick", "content", "className"]);
|
|
26
|
-
return (_jsx(Label, Object.assign({ variant: id === selectedQuickResponse ? undefined : 'outline', icon: id === selectedQuickResponse ? _jsx(
|
|
26
|
+
return (_jsx(Label, Object.assign({ variant: id === selectedQuickResponse ? undefined : 'outline', icon: id === selectedQuickResponse ? _jsx(RhMicronsCheckmarkIcon, {}) : undefined, color: "blue", onClick: () => handleQuickResponseClick(id, onClick), className: css(id === selectedQuickResponse && 'pf-chatbot__message-quick-response--selected', className), isCompact: isCompact }, props, { children: content }), id));
|
|
27
27
|
}) })));
|
|
28
28
|
};
|
|
29
29
|
export default QuickResponse;
|