@patternfly/chatbot 2.2.0-prerelease.1 → 2.2.0-prerelease.11
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/ChatbotConversationHistoryNav/ChatbotConversationHistoryNav.d.ts +19 -1
- package/dist/cjs/ChatbotConversationHistoryNav/ChatbotConversationHistoryNav.js +11 -11
- package/dist/cjs/ChatbotConversationHistoryNav/ChatbotConversationHistoryNav.test.js +39 -3
- package/dist/cjs/ChatbotHeader/ChatbotHeaderCloseButton.d.ts +17 -0
- package/dist/cjs/ChatbotHeader/ChatbotHeaderCloseButton.js +14 -0
- package/dist/cjs/ChatbotHeader/ChatbotHeaderMenu.d.ts +2 -0
- package/dist/cjs/ChatbotHeader/ChatbotHeaderMenu.js +2 -2
- package/dist/cjs/ChatbotHeader/index.d.ts +1 -0
- package/dist/cjs/ChatbotHeader/index.js +1 -0
- package/dist/cjs/CodeModal/CodeModal.js +2 -12
- package/dist/cjs/Compare/Compare.d.ts +17 -0
- package/dist/cjs/Compare/Compare.js +50 -0
- package/dist/cjs/Compare/Compare.test.d.ts +1 -0
- package/dist/cjs/Compare/Compare.test.js +20 -0
- package/dist/cjs/Compare/index.d.ts +2 -0
- package/dist/cjs/Compare/index.js +23 -0
- package/dist/cjs/Message/ListMessage/OrderedListMessage.d.ts +1 -1
- package/dist/cjs/Message/ListMessage/OrderedListMessage.js +2 -2
- package/dist/cjs/Message/Message.d.ts +16 -6
- package/dist/cjs/Message/Message.js +6 -6
- package/dist/cjs/Message/Message.test.js +51 -0
- package/dist/cjs/Message/QuickResponse/QuickResponse.d.ts +15 -0
- package/dist/cjs/Message/QuickResponse/QuickResponse.js +33 -0
- package/dist/cjs/Message/QuickStarts/FallbackImg.d.ts +13 -0
- package/dist/cjs/Message/QuickStarts/FallbackImg.js +34 -0
- package/dist/cjs/Message/QuickStarts/QuickStartTile.d.ts +27 -0
- package/dist/cjs/Message/QuickStarts/QuickStartTile.js +82 -0
- package/dist/cjs/Message/QuickStarts/QuickStartTileDescription.d.ts +23 -0
- package/dist/cjs/Message/QuickStarts/QuickStartTileDescription.js +64 -0
- package/dist/cjs/Message/QuickStarts/QuickStartTileDescription.test.d.ts +1 -0
- package/dist/cjs/Message/QuickStarts/QuickStartTileDescription.test.js +76 -0
- package/dist/cjs/Message/QuickStarts/QuickStartTileHeader.d.ts +11 -0
- package/dist/cjs/Message/QuickStarts/QuickStartTileHeader.js +30 -0
- package/dist/cjs/Message/QuickStarts/monitor-sampleapp-quickstart-with-image.d.ts +30 -0
- package/dist/cjs/Message/QuickStarts/monitor-sampleapp-quickstart-with-image.js +77 -0
- package/dist/cjs/Message/QuickStarts/monitor-sampleapp-quickstart.d.ts +30 -0
- package/dist/cjs/Message/QuickStarts/monitor-sampleapp-quickstart.js +77 -0
- package/dist/cjs/Message/QuickStarts/types.d.ts +132 -0
- package/dist/cjs/Message/QuickStarts/types.js +17 -0
- package/dist/cjs/ResponseActions/ResponseActionButton.d.ts +6 -0
- package/dist/cjs/ResponseActions/ResponseActionButton.js +10 -2
- package/dist/cjs/ResponseActions/ResponseActionButton.test.d.ts +1 -0
- package/dist/cjs/ResponseActions/ResponseActionButton.test.js +54 -0
- package/dist/cjs/ResponseActions/ResponseActions.d.ts +4 -0
- package/dist/cjs/ResponseActions/ResponseActions.js +26 -9
- package/dist/cjs/ResponseActions/ResponseActions.test.js +79 -5
- package/dist/cjs/Settings/SettingsForm.d.ts +13 -0
- package/dist/cjs/Settings/SettingsForm.js +27 -0
- package/dist/cjs/Settings/index.d.ts +2 -0
- package/dist/cjs/Settings/index.js +23 -0
- package/dist/cjs/TermsOfUse/TermsOfUse.d.ts +34 -0
- package/dist/cjs/TermsOfUse/TermsOfUse.js +49 -0
- package/dist/cjs/TermsOfUse/TermsOfUse.test.d.ts +1 -0
- package/dist/cjs/TermsOfUse/TermsOfUse.test.js +79 -0
- package/dist/cjs/TermsOfUse/index.d.ts +2 -0
- package/dist/cjs/TermsOfUse/index.js +23 -0
- package/dist/cjs/index.d.ts +6 -0
- package/dist/cjs/index.js +10 -1
- package/dist/css/main.css +244 -18
- package/dist/css/main.css.map +1 -1
- package/dist/dynamic/Compare/package.json +1 -0
- package/dist/dynamic/Settings/package.json +1 -0
- package/dist/dynamic/TermsOfUse/package.json +1 -0
- package/dist/esm/ChatbotConversationHistoryNav/ChatbotConversationHistoryNav.d.ts +19 -1
- package/dist/esm/ChatbotConversationHistoryNav/ChatbotConversationHistoryNav.js +11 -11
- package/dist/esm/ChatbotConversationHistoryNav/ChatbotConversationHistoryNav.test.js +39 -3
- package/dist/esm/ChatbotHeader/ChatbotHeaderCloseButton.d.ts +17 -0
- package/dist/esm/ChatbotHeader/ChatbotHeaderCloseButton.js +8 -0
- package/dist/esm/ChatbotHeader/ChatbotHeaderMenu.d.ts +2 -0
- package/dist/esm/ChatbotHeader/ChatbotHeaderMenu.js +2 -2
- package/dist/esm/ChatbotHeader/index.d.ts +1 -0
- package/dist/esm/ChatbotHeader/index.js +1 -0
- package/dist/esm/CodeModal/CodeModal.js +2 -12
- package/dist/esm/Compare/Compare.d.ts +17 -0
- package/dist/esm/Compare/Compare.js +43 -0
- package/dist/esm/Compare/Compare.test.d.ts +1 -0
- package/dist/esm/Compare/Compare.test.js +15 -0
- package/dist/esm/Compare/index.d.ts +2 -0
- package/dist/esm/Compare/index.js +2 -0
- package/dist/esm/Message/ListMessage/OrderedListMessage.d.ts +1 -1
- package/dist/esm/Message/ListMessage/OrderedListMessage.js +2 -2
- package/dist/esm/Message/Message.d.ts +16 -6
- package/dist/esm/Message/Message.js +7 -7
- package/dist/esm/Message/Message.test.js +51 -0
- package/dist/esm/Message/QuickResponse/QuickResponse.d.ts +15 -0
- package/dist/esm/Message/QuickResponse/QuickResponse.js +26 -0
- package/dist/esm/Message/QuickStarts/FallbackImg.d.ts +13 -0
- package/dist/esm/Message/QuickStarts/FallbackImg.js +9 -0
- package/dist/esm/Message/QuickStarts/QuickStartTile.d.ts +27 -0
- package/dist/esm/Message/QuickStarts/QuickStartTile.js +52 -0
- package/dist/esm/Message/QuickStarts/QuickStartTileDescription.d.ts +23 -0
- package/dist/esm/Message/QuickStarts/QuickStartTileDescription.js +35 -0
- package/dist/esm/Message/QuickStarts/QuickStartTileDescription.test.d.ts +1 -0
- package/dist/esm/Message/QuickStarts/QuickStartTileDescription.test.js +48 -0
- package/dist/esm/Message/QuickStarts/QuickStartTileHeader.d.ts +11 -0
- package/dist/esm/Message/QuickStarts/QuickStartTileHeader.js +5 -0
- package/dist/esm/Message/QuickStarts/monitor-sampleapp-quickstart-with-image.d.ts +30 -0
- package/dist/esm/Message/QuickStarts/monitor-sampleapp-quickstart-with-image.js +74 -0
- package/dist/esm/Message/QuickStarts/monitor-sampleapp-quickstart.d.ts +30 -0
- package/dist/esm/Message/QuickStarts/monitor-sampleapp-quickstart.js +74 -0
- package/dist/esm/Message/QuickStarts/types.d.ts +132 -0
- package/dist/esm/Message/QuickStarts/types.js +14 -0
- package/dist/esm/ResponseActions/ResponseActionButton.d.ts +6 -0
- package/dist/esm/ResponseActions/ResponseActionButton.js +10 -2
- package/dist/esm/ResponseActions/ResponseActionButton.test.d.ts +1 -0
- package/dist/esm/ResponseActions/ResponseActionButton.test.js +49 -0
- package/dist/esm/ResponseActions/ResponseActions.d.ts +4 -0
- package/dist/esm/ResponseActions/ResponseActions.js +26 -9
- package/dist/esm/ResponseActions/ResponseActions.test.js +79 -5
- package/dist/esm/Settings/SettingsForm.d.ts +13 -0
- package/dist/esm/Settings/SettingsForm.js +20 -0
- package/dist/esm/Settings/index.d.ts +2 -0
- package/dist/esm/Settings/index.js +2 -0
- package/dist/esm/TermsOfUse/TermsOfUse.d.ts +34 -0
- package/dist/esm/TermsOfUse/TermsOfUse.js +42 -0
- package/dist/esm/TermsOfUse/TermsOfUse.test.d.ts +1 -0
- package/dist/esm/TermsOfUse/TermsOfUse.test.js +74 -0
- package/dist/esm/TermsOfUse/index.d.ts +2 -0
- package/dist/esm/TermsOfUse/index.js +2 -0
- package/dist/esm/index.d.ts +6 -0
- package/dist/esm/index.js +6 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +7 -13
- package/patternfly-docs/content/extensions/chatbot/examples/Messages/MessageWithCustomResponseActions.tsx +4 -0
- package/patternfly-docs/content/extensions/chatbot/examples/Messages/MessageWithQuickStart.tsx +31 -0
- package/patternfly-docs/content/extensions/chatbot/examples/Messages/Messages.md +26 -4
- package/patternfly-docs/content/extensions/chatbot/examples/Messages/explore-pipeline-quickstart.ts +65 -0
- package/patternfly-docs/content/extensions/chatbot/examples/UI/ChatbotFooter.tsx +1 -1
- package/patternfly-docs/content/extensions/chatbot/examples/UI/ChatbotFootnote.tsx +2 -2
- package/patternfly-docs/content/extensions/chatbot/examples/UI/ChatbotHeaderDrawer.tsx +2 -2
- package/patternfly-docs/content/extensions/chatbot/examples/UI/ChatbotHeaderDrawerNavigation.tsx +67 -0
- package/patternfly-docs/content/extensions/chatbot/examples/UI/ChatbotHeaderDrawerResizable.tsx +94 -0
- package/patternfly-docs/content/extensions/chatbot/examples/UI/ChatbotHeaderDrawerWithSelection.tsx +78 -0
- package/patternfly-docs/content/extensions/chatbot/examples/UI/PF-TermsAndConditionsHeader.svg +148 -0
- package/patternfly-docs/content/extensions/chatbot/examples/UI/Settings.tsx +289 -0
- package/patternfly-docs/content/extensions/chatbot/examples/UI/SquareChatbotToggle.tsx +1 -1
- package/patternfly-docs/content/extensions/chatbot/examples/UI/TermsOfUse.tsx +147 -0
- package/patternfly-docs/content/extensions/chatbot/examples/UI/UI.md +54 -0
- package/patternfly-docs/content/extensions/chatbot/examples/demos/Chatbot.md +26 -3
- package/patternfly-docs/content/extensions/chatbot/examples/demos/Chatbot.tsx +2 -2
- package/patternfly-docs/content/extensions/chatbot/examples/demos/ChatbotAttachment.tsx +20 -19
- package/patternfly-docs/content/extensions/chatbot/examples/demos/ChatbotAttachmentMenu.tsx +1 -1
- package/patternfly-docs/content/extensions/chatbot/examples/demos/EmbeddedChatbot.tsx +2 -2
- package/patternfly-docs/content/extensions/chatbot/examples/demos/EmbeddedComparisonChatbot.tsx +206 -0
- package/src/ChatbotConversationHistoryNav/ChatbotConversationHistoryNav.scss +14 -0
- package/src/ChatbotConversationHistoryNav/ChatbotConversationHistoryNav.test.tsx +112 -3
- package/src/ChatbotConversationHistoryNav/ChatbotConversationHistoryNav.tsx +46 -9
- package/src/ChatbotFooter/ChatbotFooter.scss +2 -1
- package/src/ChatbotHeader/ChatbotHeaderCloseButton.tsx +51 -0
- package/src/ChatbotHeader/ChatbotHeaderMenu.tsx +5 -2
- package/src/ChatbotHeader/index.ts +1 -0
- package/src/CodeModal/CodeModal.scss +8 -0
- package/src/CodeModal/CodeModal.tsx +2 -13
- package/src/Compare/Compare.scss +72 -0
- package/src/Compare/Compare.test.tsx +31 -0
- package/src/Compare/Compare.tsx +98 -0
- package/src/Compare/index.ts +2 -0
- package/src/FileDropZone/__snapshots__/FileDropZone.test.tsx.snap +1 -1
- package/src/Message/ListMessage/OrderedListMessage.tsx +2 -2
- package/src/Message/Message.scss +0 -14
- package/src/Message/Message.test.tsx +76 -0
- package/src/Message/Message.tsx +35 -26
- package/src/Message/QuickResponse/QuickResponse.scss +33 -0
- package/src/Message/QuickResponse/QuickResponse.tsx +50 -0
- package/src/Message/QuickStarts/FallbackImg.tsx +24 -0
- package/src/Message/QuickStarts/QuickStartTile.scss +25 -0
- package/src/Message/QuickStarts/QuickStartTile.tsx +147 -0
- package/src/Message/QuickStarts/QuickStartTileDescription.test.tsx +57 -0
- package/src/Message/QuickStarts/QuickStartTileDescription.tsx +81 -0
- package/src/Message/QuickStarts/QuickStartTileHeader.tsx +21 -0
- package/src/Message/QuickStarts/monitor-sampleapp-quickstart-with-image.ts +75 -0
- package/src/Message/QuickStarts/monitor-sampleapp-quickstart.ts +75 -0
- package/src/Message/QuickStarts/types.ts +154 -0
- package/src/ResponseActions/ResponseActionButton.test.tsx +52 -0
- package/src/ResponseActions/ResponseActionButton.tsx +46 -27
- package/src/ResponseActions/ResponseActions.scss +10 -8
- package/src/ResponseActions/ResponseActions.test.tsx +103 -5
- package/src/ResponseActions/ResponseActions.tsx +54 -7
- package/src/Settings/Settings.scss +34 -0
- package/src/Settings/SettingsForm.tsx +25 -0
- package/src/Settings/index.ts +3 -0
- package/src/TermsOfUse/TermsOfUse.scss +66 -0
- package/src/TermsOfUse/TermsOfUse.test.tsx +138 -0
- package/src/TermsOfUse/TermsOfUse.tsx +117 -0
- package/src/TermsOfUse/index.ts +3 -0
- package/src/index.ts +9 -0
- package/src/main.scss +5 -0
@@ -0,0 +1,79 @@
|
|
1
|
+
"use strict";
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
9
|
+
});
|
10
|
+
};
|
11
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
12
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
13
|
+
};
|
14
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
15
|
+
const react_1 = __importDefault(require("react"));
|
16
|
+
const react_2 = require("@testing-library/react");
|
17
|
+
require("@testing-library/jest-dom");
|
18
|
+
const user_event_1 = __importDefault(require("@testing-library/user-event"));
|
19
|
+
const TermsOfUse_1 = __importDefault(require("./TermsOfUse"));
|
20
|
+
const react_core_1 = require("@patternfly/react-core");
|
21
|
+
const handleModalToggle = jest.fn();
|
22
|
+
const onPrimaryAction = jest.fn();
|
23
|
+
const onSecondaryAction = jest.fn();
|
24
|
+
const body = (react_1.default.createElement(react_core_1.Content, null,
|
25
|
+
react_1.default.createElement("h1", null, "Heading 1"),
|
26
|
+
react_1.default.createElement("p", null, "Legal text")));
|
27
|
+
describe('TermsOfUse', () => {
|
28
|
+
afterEach(() => {
|
29
|
+
jest.clearAllMocks();
|
30
|
+
});
|
31
|
+
it('should render modal correctly', () => {
|
32
|
+
(0, react_2.render)(react_1.default.createElement(TermsOfUse_1.default, { isModalOpen: true, onSecondaryAction: onSecondaryAction, handleModalToggle: handleModalToggle, ouiaId: "Terms" }, body));
|
33
|
+
expect(react_2.screen.getByRole('heading', { name: /Terms of use/i })).toBeTruthy();
|
34
|
+
expect(react_2.screen.getByRole('button', { name: /Accept/i })).toBeTruthy();
|
35
|
+
expect(react_2.screen.getByRole('button', { name: /Decline/i })).toBeTruthy();
|
36
|
+
expect(react_2.screen.getByRole('heading', { name: /Heading 1/i })).toBeTruthy();
|
37
|
+
expect(react_2.screen.getByText(/Legal text/i)).toBeTruthy();
|
38
|
+
expect(react_2.screen.getByRole('dialog')).toHaveClass('pf-chatbot__terms-of-use-modal');
|
39
|
+
expect(react_2.screen.getByRole('dialog')).toHaveClass('pf-chatbot__terms-of-use-modal--default');
|
40
|
+
});
|
41
|
+
it('should handle image and altText props', () => {
|
42
|
+
(0, react_2.render)(react_1.default.createElement(TermsOfUse_1.default, { isModalOpen: true, onSecondaryAction: onSecondaryAction, handleModalToggle: handleModalToggle, image: "./image.png", altText: "Test image" }, body));
|
43
|
+
expect(react_2.screen.getByRole('img')).toBeTruthy();
|
44
|
+
expect(react_2.screen.getByRole('img')).toHaveAttribute('alt', 'Test image');
|
45
|
+
});
|
46
|
+
it('should handle className prop', () => {
|
47
|
+
(0, react_2.render)(react_1.default.createElement(TermsOfUse_1.default, { isModalOpen: true, onSecondaryAction: onSecondaryAction, handleModalToggle: handleModalToggle, className: "test" }, body));
|
48
|
+
expect(react_2.screen.getByRole('dialog')).toHaveClass('pf-chatbot__terms-of-use-modal');
|
49
|
+
expect(react_2.screen.getByRole('dialog')).toHaveClass('pf-chatbot__terms-of-use-modal--default');
|
50
|
+
expect(react_2.screen.getByRole('dialog')).toHaveClass('test');
|
51
|
+
});
|
52
|
+
it('should handle title prop', () => {
|
53
|
+
(0, react_2.render)(react_1.default.createElement(TermsOfUse_1.default, { isModalOpen: true, onSecondaryAction: onSecondaryAction, handleModalToggle: handleModalToggle, title: "Updated title" }, body));
|
54
|
+
expect(react_2.screen.getByRole('heading', { name: /Updated title/i })).toBeTruthy();
|
55
|
+
expect(react_2.screen.queryByRole('heading', { name: /Terms of use/i })).toBeFalsy();
|
56
|
+
});
|
57
|
+
it('should handle primary button prop', () => {
|
58
|
+
(0, react_2.render)(react_1.default.createElement(TermsOfUse_1.default, { isModalOpen: true, onSecondaryAction: onSecondaryAction, handleModalToggle: handleModalToggle, primaryActionBtn: "First" }, body));
|
59
|
+
expect(react_2.screen.getByRole('button', { name: /First/i })).toBeTruthy();
|
60
|
+
expect(react_2.screen.queryByRole('button', { name: /Accept/i })).toBeFalsy();
|
61
|
+
});
|
62
|
+
it('should handle secondary button prop', () => {
|
63
|
+
(0, react_2.render)(react_1.default.createElement(TermsOfUse_1.default, { isModalOpen: true, onSecondaryAction: onSecondaryAction, handleModalToggle: handleModalToggle, secondaryActionBtn: "Second" }, body));
|
64
|
+
expect(react_2.screen.getByRole('button', { name: /Second/i })).toBeTruthy();
|
65
|
+
expect(react_2.screen.queryByRole('button', { name: /Deny/i })).toBeFalsy();
|
66
|
+
});
|
67
|
+
it('should handle primary button click', () => __awaiter(void 0, void 0, void 0, function* () {
|
68
|
+
(0, react_2.render)(react_1.default.createElement(TermsOfUse_1.default, { isModalOpen: true, onPrimaryAction: onPrimaryAction, onSecondaryAction: onSecondaryAction, handleModalToggle: handleModalToggle }, body));
|
69
|
+
yield user_event_1.default.click(react_2.screen.getByRole('button', { name: /Accept/i }));
|
70
|
+
expect(onPrimaryAction).toHaveBeenCalledTimes(1);
|
71
|
+
expect(handleModalToggle).toHaveBeenCalledTimes(1);
|
72
|
+
}));
|
73
|
+
it('should handle secondary button click', () => __awaiter(void 0, void 0, void 0, function* () {
|
74
|
+
(0, react_2.render)(react_1.default.createElement(TermsOfUse_1.default, { isModalOpen: true, onSecondaryAction: onSecondaryAction, handleModalToggle: handleModalToggle }, body));
|
75
|
+
yield user_event_1.default.click(react_2.screen.getByRole('button', { name: /Decline/i }));
|
76
|
+
expect(onSecondaryAction).toHaveBeenCalledTimes(1);
|
77
|
+
expect(handleModalToggle).not.toHaveBeenCalled();
|
78
|
+
}));
|
79
|
+
});
|
@@ -0,0 +1,23 @@
|
|
1
|
+
"use strict";
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
3
|
+
if (k2 === undefined) k2 = k;
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
7
|
+
}
|
8
|
+
Object.defineProperty(o, k2, desc);
|
9
|
+
}) : (function(o, m, k, k2) {
|
10
|
+
if (k2 === undefined) k2 = k;
|
11
|
+
o[k2] = m[k];
|
12
|
+
}));
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
15
|
+
};
|
16
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
17
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
18
|
+
};
|
19
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
20
|
+
exports.default = void 0;
|
21
|
+
var TermsOfUse_1 = require("./TermsOfUse");
|
22
|
+
Object.defineProperty(exports, "default", { enumerable: true, get: function () { return __importDefault(TermsOfUse_1).default; } });
|
23
|
+
__exportStar(require("./TermsOfUse"), exports);
|
package/dist/cjs/index.d.ts
CHANGED
@@ -24,6 +24,8 @@ export { default as ChatbotWelcomePrompt } from './ChatbotWelcomePrompt';
|
|
24
24
|
export * from './ChatbotWelcomePrompt';
|
25
25
|
export { default as CodeModal } from './CodeModal';
|
26
26
|
export * from './CodeModal';
|
27
|
+
export { default as Compare } from './Compare';
|
28
|
+
export * from './Compare';
|
27
29
|
export { default as FileDetails } from './FileDetails';
|
28
30
|
export * from './FileDetails';
|
29
31
|
export { default as FileDetailsLabel } from './FileDetailsLabel';
|
@@ -42,7 +44,11 @@ export { default as PreviewAttachment } from './PreviewAttachment';
|
|
42
44
|
export * from './PreviewAttachment';
|
43
45
|
export { default as ResponseActions } from './ResponseActions';
|
44
46
|
export * from './ResponseActions';
|
47
|
+
export { default as Settings } from './Settings';
|
48
|
+
export * from './Settings';
|
45
49
|
export { default as SourceDetailsMenuItem } from './SourceDetailsMenuItem';
|
46
50
|
export * from './SourceDetailsMenuItem';
|
47
51
|
export { default as SourcesCard } from './SourcesCard';
|
48
52
|
export * from './SourcesCard';
|
53
|
+
export { default as TermsOfUse } from './TermsOfUse';
|
54
|
+
export * from './TermsOfUse';
|
package/dist/cjs/index.js
CHANGED
@@ -18,7 +18,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
18
18
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
19
19
|
};
|
20
20
|
Object.defineProperty(exports, "__esModule", { value: true });
|
21
|
-
exports.SourcesCard = exports.SourceDetailsMenuItem = exports.ResponseActions = exports.PreviewAttachment = exports.MessageBox = exports.MessageBar = exports.Message = exports.LoadingMessage = exports.FileDropZone = exports.FileDetailsLabel = exports.FileDetails = exports.CodeModal = exports.ChatbotWelcomePrompt = exports.ChatbotToggle = exports.ChatbotPopover = exports.ChatbotModal = exports.ChatbotHeader = exports.ChatbotFooter = exports.ChatbotConversationHistoryNav = exports.ChatbotContent = exports.ChatbotAlert = exports.Chatbot = exports.AttachMenu = exports.AttachmentEdit = void 0;
|
21
|
+
exports.TermsOfUse = exports.SourcesCard = exports.SourceDetailsMenuItem = exports.Settings = exports.ResponseActions = exports.PreviewAttachment = exports.MessageBox = exports.MessageBar = exports.Message = exports.LoadingMessage = exports.FileDropZone = exports.FileDetailsLabel = exports.FileDetails = exports.Compare = exports.CodeModal = exports.ChatbotWelcomePrompt = exports.ChatbotToggle = exports.ChatbotPopover = exports.ChatbotModal = exports.ChatbotHeader = exports.ChatbotFooter = exports.ChatbotConversationHistoryNav = exports.ChatbotContent = exports.ChatbotAlert = exports.Chatbot = exports.AttachMenu = exports.AttachmentEdit = void 0;
|
22
22
|
var AttachmentEdit_1 = require("./AttachmentEdit");
|
23
23
|
Object.defineProperty(exports, "AttachmentEdit", { enumerable: true, get: function () { return __importDefault(AttachmentEdit_1).default; } });
|
24
24
|
__exportStar(require("./AttachmentEdit"), exports);
|
@@ -58,6 +58,9 @@ __exportStar(require("./ChatbotWelcomePrompt"), exports);
|
|
58
58
|
var CodeModal_1 = require("./CodeModal");
|
59
59
|
Object.defineProperty(exports, "CodeModal", { enumerable: true, get: function () { return __importDefault(CodeModal_1).default; } });
|
60
60
|
__exportStar(require("./CodeModal"), exports);
|
61
|
+
var Compare_1 = require("./Compare");
|
62
|
+
Object.defineProperty(exports, "Compare", { enumerable: true, get: function () { return __importDefault(Compare_1).default; } });
|
63
|
+
__exportStar(require("./Compare"), exports);
|
61
64
|
var FileDetails_1 = require("./FileDetails");
|
62
65
|
Object.defineProperty(exports, "FileDetails", { enumerable: true, get: function () { return __importDefault(FileDetails_1).default; } });
|
63
66
|
__exportStar(require("./FileDetails"), exports);
|
@@ -85,9 +88,15 @@ __exportStar(require("./PreviewAttachment"), exports);
|
|
85
88
|
var ResponseActions_1 = require("./ResponseActions");
|
86
89
|
Object.defineProperty(exports, "ResponseActions", { enumerable: true, get: function () { return __importDefault(ResponseActions_1).default; } });
|
87
90
|
__exportStar(require("./ResponseActions"), exports);
|
91
|
+
var Settings_1 = require("./Settings");
|
92
|
+
Object.defineProperty(exports, "Settings", { enumerable: true, get: function () { return __importDefault(Settings_1).default; } });
|
93
|
+
__exportStar(require("./Settings"), exports);
|
88
94
|
var SourceDetailsMenuItem_1 = require("./SourceDetailsMenuItem");
|
89
95
|
Object.defineProperty(exports, "SourceDetailsMenuItem", { enumerable: true, get: function () { return __importDefault(SourceDetailsMenuItem_1).default; } });
|
90
96
|
__exportStar(require("./SourceDetailsMenuItem"), exports);
|
91
97
|
var SourcesCard_1 = require("./SourcesCard");
|
92
98
|
Object.defineProperty(exports, "SourcesCard", { enumerable: true, get: function () { return __importDefault(SourcesCard_1).default; } });
|
93
99
|
__exportStar(require("./SourcesCard"), exports);
|
100
|
+
var TermsOfUse_1 = require("./TermsOfUse");
|
101
|
+
Object.defineProperty(exports, "TermsOfUse", { enumerable: true, get: function () { return __importDefault(TermsOfUse_1).default; } });
|
102
|
+
__exportStar(require("./TermsOfUse"), exports);
|
package/dist/css/main.css
CHANGED
@@ -207,10 +207,20 @@
|
|
207
207
|
color: var(--pf-t--global--text--color--regular);
|
208
208
|
font-size: var(--pf-t--global--font--size--body--lg);
|
209
209
|
font-weight: var(--pf-t--global--font--weight--body--default);
|
210
|
+
border-radius: var(--pf-t--global--border--radius--small);
|
211
|
+
}
|
212
|
+
.pf-chatbot__history .pf-v6-c-menu__list-item.pf-chatbot__menu-item {
|
213
|
+
overflow: hidden;
|
210
214
|
}
|
211
215
|
.pf-chatbot__history .pf-chatbot__history-actions {
|
212
216
|
transform: rotate(90deg);
|
213
217
|
}
|
218
|
+
.pf-chatbot__history .pf-chatbot__menu-item--active {
|
219
|
+
background-color: var(--pf-t--global--background--color--action--plain--clicked);
|
220
|
+
}
|
221
|
+
.pf-chatbot__history button.pf-chatbot__menu-item--active {
|
222
|
+
background-color: initial;
|
223
|
+
}
|
214
224
|
|
215
225
|
.pf-chatbot__history.pf-v6-c-drawer {
|
216
226
|
--pf-v6-c-drawer__panel--MinWidth: 24rem;
|
@@ -254,6 +264,7 @@
|
|
254
264
|
border-radius: var(--pf-t--global--border--radius--pill);
|
255
265
|
justify-content: center;
|
256
266
|
align-items: center;
|
267
|
+
border-radius: var(--pf-t--global--border--radius--small);
|
257
268
|
}
|
258
269
|
.pf-chatbot__history.pf-v6-c-drawer .pf-v6-c-drawer__body {
|
259
270
|
--pf-v6-c-drawer__panel__body--PaddingBlockStart: 0;
|
@@ -330,7 +341,8 @@
|
|
330
341
|
}
|
331
342
|
.pf-chatbot--embedded .pf-chatbot__footer-container,
|
332
343
|
.pf-chatbot--fullscreen .pf-chatbot__footer-container {
|
333
|
-
width:
|
344
|
+
width: 90%;
|
345
|
+
max-width: 60rem;
|
334
346
|
padding: var(--pf-t--global--spacer--sm) 0;
|
335
347
|
}
|
336
348
|
}
|
@@ -678,6 +690,89 @@
|
|
678
690
|
--pf-v6-c-button--hover__icon--Color: #c7c7c7;
|
679
691
|
}
|
680
692
|
|
693
|
+
.pf-chatbot__code-modal-body {
|
694
|
+
flex: 1;
|
695
|
+
}
|
696
|
+
|
697
|
+
.pf-chatbot__code-modal--fullscreen {
|
698
|
+
height: inherit;
|
699
|
+
}
|
700
|
+
|
701
|
+
.pf-chatbot__compare-container {
|
702
|
+
display: flex;
|
703
|
+
flex-direction: column;
|
704
|
+
position: relative;
|
705
|
+
height: 100%;
|
706
|
+
}
|
707
|
+
|
708
|
+
.pf-chatbot__compare-toggle {
|
709
|
+
width: 100%;
|
710
|
+
}
|
711
|
+
.pf-chatbot__compare-toggle .pf-v6-c-toggle-group__button {
|
712
|
+
width: 100%;
|
713
|
+
display: flex;
|
714
|
+
justify-content: center;
|
715
|
+
}
|
716
|
+
|
717
|
+
.pf-chatbot__compare {
|
718
|
+
display: flex;
|
719
|
+
height: 100%;
|
720
|
+
width: 100%;
|
721
|
+
}
|
722
|
+
@media screen and (max-width: 900px) {
|
723
|
+
.pf-chatbot__compare {
|
724
|
+
overflow-y: auto;
|
725
|
+
}
|
726
|
+
}
|
727
|
+
.pf-chatbot__compare .pf-chatbot__compare-item:first-of-type {
|
728
|
+
border-right: 1px solid var(--pf-t--global--border--color--default);
|
729
|
+
}
|
730
|
+
@media screen and (max-width: 900px) {
|
731
|
+
.pf-chatbot__compare .pf-chatbot__compare-item:first-of-type {
|
732
|
+
border-right: 0px;
|
733
|
+
}
|
734
|
+
}
|
735
|
+
|
736
|
+
.pf-chatbot__compare-item {
|
737
|
+
flex: 1;
|
738
|
+
}
|
739
|
+
.pf-chatbot__compare-item .pf-chatbot--embedded .pf-chatbot__messagebox {
|
740
|
+
width: 100%;
|
741
|
+
}
|
742
|
+
.pf-chatbot__compare-item .pf-chatbot__content {
|
743
|
+
padding: 0;
|
744
|
+
}
|
745
|
+
@media screen and (max-width: 900px) {
|
746
|
+
.pf-chatbot__compare-item .pf-chatbot.pf-chatbot--embedded {
|
747
|
+
height: 100%;
|
748
|
+
}
|
749
|
+
}
|
750
|
+
|
751
|
+
.pf-chatbot__compare-item-hidden {
|
752
|
+
display: block;
|
753
|
+
}
|
754
|
+
@media screen and (max-width: 900px) {
|
755
|
+
.pf-chatbot__compare-item-hidden {
|
756
|
+
display: none;
|
757
|
+
}
|
758
|
+
}
|
759
|
+
|
760
|
+
.pf-chatbot__compare-mobile-controls {
|
761
|
+
padding: var(--pf-t--global--spacer--md) var(--pf-t--global--spacer--lg) 0 var(--pf-t--global--spacer--lg);
|
762
|
+
display: none;
|
763
|
+
background-color: var(--pf-t--global--background--color--secondary--default);
|
764
|
+
position: sticky;
|
765
|
+
top: 0;
|
766
|
+
z-index: 9999;
|
767
|
+
}
|
768
|
+
@media screen and (max-width: 900px) {
|
769
|
+
.pf-chatbot__compare-mobile-controls {
|
770
|
+
display: flex;
|
771
|
+
flex-direction: column;
|
772
|
+
gap: var(--pf-t--global--spacer--md);
|
773
|
+
}
|
774
|
+
}
|
775
|
+
|
681
776
|
.pf-chatbot__code-language {
|
682
777
|
color: var(--pf-t--global--text--color--subtle);
|
683
778
|
display: flex;
|
@@ -882,19 +977,6 @@
|
|
882
977
|
display: grid;
|
883
978
|
gap: var(--pf-t--global--spacer--sm);
|
884
979
|
}
|
885
|
-
.pf-chatbot__message-quick-response .pf-v6-c-label {
|
886
|
-
--pf-v6-c-label--FontSize: var(--pf-t--global--font--size--md);
|
887
|
-
}
|
888
|
-
@media screen and (min-width: 401px) and (max-width: 600px) {
|
889
|
-
.pf-chatbot__message-quick-response .pf-v6-c-label {
|
890
|
-
--pf-v6-c-label__text--MaxWidth: 20ch;
|
891
|
-
}
|
892
|
-
}
|
893
|
-
@media screen and (max-width: 400px) {
|
894
|
-
.pf-chatbot__message-quick-response .pf-v6-c-label {
|
895
|
-
--pf-v6-c-label__text--MaxWidth: 15ch;
|
896
|
-
}
|
897
|
-
}
|
898
980
|
|
899
981
|
.pf-chatbot__message-attachments-container {
|
900
982
|
display: flex;
|
@@ -1224,6 +1306,53 @@
|
|
1224
1306
|
}
|
1225
1307
|
}
|
1226
1308
|
|
1309
|
+
.pf-chatbot__quickstarts-tile {
|
1310
|
+
min-width: 360px;
|
1311
|
+
max-width: 650px;
|
1312
|
+
width: 100%;
|
1313
|
+
}
|
1314
|
+
@media screen and (max-width: 700px) {
|
1315
|
+
.pf-chatbot__quickstarts-tile {
|
1316
|
+
max-width: 100%;
|
1317
|
+
min-width: initial;
|
1318
|
+
}
|
1319
|
+
}
|
1320
|
+
.pf-chatbot__quickstarts-tile .pf-v6-c-card__header-main .pf-v6-c-icon__content {
|
1321
|
+
display: contents;
|
1322
|
+
}
|
1323
|
+
|
1324
|
+
.pf-v6-theme-dark .pf-chatbot__quickstarts-tile .pfext-catalog-item-icon__img {
|
1325
|
+
filter: brightness(1.5) invert(1) hue-rotate(180deg) saturate(4);
|
1326
|
+
}
|
1327
|
+
|
1328
|
+
.pf-chatbot__message-quick-response .pf-v6-c-label {
|
1329
|
+
--pf-v6-c-label--FontSize: var(--pf-t--global--font--size--md);
|
1330
|
+
}
|
1331
|
+
@media screen and (min-width: 401px) and (max-width: 600px) {
|
1332
|
+
.pf-chatbot__message-quick-response .pf-v6-c-label {
|
1333
|
+
--pf-v6-c-label__text--MaxWidth: 20ch;
|
1334
|
+
}
|
1335
|
+
}
|
1336
|
+
@media screen and (max-width: 400px) {
|
1337
|
+
.pf-chatbot__message-quick-response .pf-v6-c-label {
|
1338
|
+
--pf-v6-c-label__text--MaxWidth: 15ch;
|
1339
|
+
}
|
1340
|
+
}
|
1341
|
+
.pf-chatbot__message-quick-response .pf-chatbot__message-quick-response--selected .pf-v6-c-label__content:is(:hover, :focus) {
|
1342
|
+
--pf-v6-c-label--m-clickable--hover--BorderWidth: 0;
|
1343
|
+
--pf-v6-c-label--BackgroundColor: var(--pf-v6-c-label--m-blue--BackgroundColor);
|
1344
|
+
}
|
1345
|
+
.pf-chatbot__message-quick-response .pf-chatbot__message-quick-response--selected:hover,
|
1346
|
+
.pf-chatbot__message-quick-response .pf-chatbot__message-quick-response--selected:focus {
|
1347
|
+
--pf-v6-c-label--m-clickable--hover--BorderWidth: 0;
|
1348
|
+
--pf-v6-c-label--BackgroundColor: var(--pf-v6-c-label--m-blue--BackgroundColor);
|
1349
|
+
}
|
1350
|
+
.pf-chatbot__message-quick-response .pf-v6-c-label.pf-m-blue.pf-m-clickable .pf-v6-c-label__content:is(:active) {
|
1351
|
+
--pf-v6-c-label--BackgroundColor: var(--pf-v6-c-label--m-blue--BackgroundColor);
|
1352
|
+
--pf-v6-c-label--m-clickable--hover--BackgroundColor: var(--pf-v6-c-label--m-blue--BackgroundColor);
|
1353
|
+
--pf-v6-c-label--m-clickable--hover--BorderWidth: 0;
|
1354
|
+
}
|
1355
|
+
|
1227
1356
|
.pf-v6-c-button.pf-chatbot__button--attach {
|
1228
1357
|
border-radius: var(--pf-t--global--border--radius--pill);
|
1229
1358
|
padding: var(--pf-t--global--spacer--md);
|
@@ -1512,6 +1641,7 @@
|
|
1512
1641
|
grid-template-columns: repeat(auto-fit, minmax(0, max-content));
|
1513
1642
|
}
|
1514
1643
|
.pf-chatbot__response-actions .pf-v6-c-button {
|
1644
|
+
--pf-v6-c-button__icon--Color: var(--pf-t--global--icon--color--subtle);
|
1515
1645
|
border-radius: var(--pf-t--global--border--radius--pill);
|
1516
1646
|
width: 2.3125rem;
|
1517
1647
|
height: 2.3125rem;
|
@@ -1519,11 +1649,52 @@
|
|
1519
1649
|
align-items: center;
|
1520
1650
|
justify-content: center;
|
1521
1651
|
}
|
1522
|
-
.pf-chatbot__response-actions .pf-v6-c-button
|
1523
|
-
|
1652
|
+
.pf-chatbot__response-actions .pf-v6-c-button:hover {
|
1653
|
+
--pf-v6-c-button__icon--Color: var(--pf-t--global--icon--color--subtle);
|
1654
|
+
}
|
1655
|
+
.pf-chatbot__response-actions .pf-v6-c-button:focus {
|
1656
|
+
--pf-v6-c-button--hover--BackgroundColor: var(--pf-t--global--background--color--action--plain--alt--clicked);
|
1657
|
+
--pf-v6-c-button__icon--Color: var(--pf-t--global--icon--color--regular);
|
1658
|
+
}
|
1659
|
+
|
1660
|
+
.pf-v6-c-button.pf-chatbot__button--response-action-clicked {
|
1661
|
+
--pf-v6-c-button--m-plain--BackgroundColor: var(--pf-t--global--background--color--action--plain--alt--clicked);
|
1662
|
+
--pf-v6-c-button__icon--Color: var(--pf-t--global--icon--color--regular);
|
1663
|
+
}
|
1664
|
+
|
1665
|
+
.pf-chatbot__settings-form-container {
|
1666
|
+
width: 100%;
|
1667
|
+
display: flex;
|
1668
|
+
justify-content: center;
|
1669
|
+
overflow: scroll;
|
1670
|
+
}
|
1671
|
+
|
1672
|
+
.pf-chatbot__settings-form {
|
1673
|
+
display: flex;
|
1674
|
+
flex-direction: column;
|
1675
|
+
max-width: 60rem;
|
1676
|
+
flex: 1;
|
1677
|
+
}
|
1678
|
+
|
1679
|
+
.pf-chatbot__settings-form-row {
|
1680
|
+
font-size: var(--pf-t--global--font--size--body--lg);
|
1681
|
+
display: flex;
|
1682
|
+
align-items: center;
|
1683
|
+
justify-content: space-between;
|
1684
|
+
border-bottom: 1px solid var(--pf-t--global--border--color--default);
|
1685
|
+
padding: var(--pf-t--global--spacer--lg);
|
1686
|
+
font-weight: 500;
|
1524
1687
|
}
|
1525
|
-
|
1526
|
-
|
1688
|
+
|
1689
|
+
.pf-chatbot__settings-form-row:last-of-type {
|
1690
|
+
border-bottom: 0px;
|
1691
|
+
}
|
1692
|
+
|
1693
|
+
.pf-chatbot__settings--title {
|
1694
|
+
font-family: var(--pf-t--global--font--family--heading);
|
1695
|
+
font-size: var(--pf-t--global--font--size--xl);
|
1696
|
+
font-weight: 500;
|
1697
|
+
text-align: center;
|
1527
1698
|
}
|
1528
1699
|
|
1529
1700
|
.pf-chatbot__source {
|
@@ -1625,6 +1796,61 @@
|
|
1625
1796
|
max-width: 20rem;
|
1626
1797
|
}
|
1627
1798
|
|
1799
|
+
.pf-chatbot__terms-of-use-modal .pf-v6-c-content {
|
1800
|
+
font-size: var(--pf-t--global--font--size--body--lg);
|
1801
|
+
}
|
1802
|
+
.pf-chatbot__terms-of-use-modal .pf-v6-c-content h2 {
|
1803
|
+
font-size: var(--pf-t--global--icon--size--font--heading--h2);
|
1804
|
+
font-family: var(--pf-t--global--font--family--heading);
|
1805
|
+
margin-bottom: var(--pf-t--global--spacer--md);
|
1806
|
+
margin-top: var(--pf-t--global--spacer--md);
|
1807
|
+
font-weight: var(--pf-t--global--font--weight--heading--default);
|
1808
|
+
}
|
1809
|
+
.pf-chatbot__terms-of-use-modal .pf-v6-c-content h2:first-of-type {
|
1810
|
+
margin-top: 0;
|
1811
|
+
}
|
1812
|
+
.pf-chatbot__terms-of-use-modal .pf-chatbot__terms-of-use--header {
|
1813
|
+
display: flex;
|
1814
|
+
align-items: center;
|
1815
|
+
justify-content: center;
|
1816
|
+
flex-direction: column;
|
1817
|
+
gap: var(--pf-t--global--spacer--xl);
|
1818
|
+
margin-block-start: var(--pf-t--global--spacer--xl);
|
1819
|
+
}
|
1820
|
+
.pf-chatbot__terms-of-use-modal .pf-chatbot__terms-of-use--title {
|
1821
|
+
font-size: var(--pf-t--global--font--size--heading--h1);
|
1822
|
+
font-family: var(--pf-t--global--font--family--heading);
|
1823
|
+
font-weight: var(--pf-t--global--font--weight--heading--bold);
|
1824
|
+
}
|
1825
|
+
.pf-chatbot__terms-of-use-modal .pf-chatbot__terms-of-use--footer {
|
1826
|
+
margin-block-start: var(--pf-t--global--spacer--md);
|
1827
|
+
}
|
1828
|
+
.pf-chatbot__terms-of-use-modal .pf-chatbot__terms-of-use--section {
|
1829
|
+
display: flex;
|
1830
|
+
flex-direction: column;
|
1831
|
+
height: 100%;
|
1832
|
+
width: 100%;
|
1833
|
+
}
|
1834
|
+
@media screen and (max-height: 620px) {
|
1835
|
+
.pf-chatbot__terms-of-use-modal .pf-v6-c-modal-box__body {
|
1836
|
+
--pf-v6-c-modal-box__body--MinHeight: auto;
|
1837
|
+
overflow: visible;
|
1838
|
+
}
|
1839
|
+
}
|
1840
|
+
|
1841
|
+
.pf-chatbot__chatbot-modal.pf-chatbot__chatbot-modal--fullscreen.pf-chatbot__terms-of-use-modal.pf-chatbot__terms-of-use-modal--fullscreen,
|
1842
|
+
.pf-chatbot__chatbot-modal.pf-chatbot__chatbot-modal--embedded.pf-chatbot__terms-of-use-modal.pf-chatbot__terms-of-use-modal--embedded {
|
1843
|
+
height: inherit;
|
1844
|
+
}
|
1845
|
+
.pf-chatbot__chatbot-modal.pf-chatbot__chatbot-modal--fullscreen.pf-chatbot__terms-of-use-modal.pf-chatbot__terms-of-use-modal--fullscreen .pf-v6-c-content h2,
|
1846
|
+
.pf-chatbot__chatbot-modal.pf-chatbot__chatbot-modal--embedded.pf-chatbot__terms-of-use-modal.pf-chatbot__terms-of-use-modal--embedded .pf-v6-c-content h2 {
|
1847
|
+
font-size: var(--pf-t--global--icon--size--font--heading--h1);
|
1848
|
+
}
|
1849
|
+
.pf-chatbot__chatbot-modal.pf-chatbot__chatbot-modal--fullscreen.pf-chatbot__terms-of-use-modal.pf-chatbot__terms-of-use-modal--fullscreen .pf-chatbot__terms-of-use--title,
|
1850
|
+
.pf-chatbot__chatbot-modal.pf-chatbot__chatbot-modal--embedded.pf-chatbot__terms-of-use-modal.pf-chatbot__terms-of-use-modal--embedded .pf-chatbot__terms-of-use--title {
|
1851
|
+
font-size: var(--pf-t--global--font--size--heading--2xl);
|
1852
|
+
}
|
1853
|
+
|
1628
1854
|
:where(:root) {
|
1629
1855
|
--pf-t--chatbot--heading--font-family: var(
|
1630
1856
|
--pf-v6-c-content--heading--FontFamily,
|
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/FileDetails/FileDetails.scss","../../src/FileDetailsLabel/FileDetailsLabel.scss","../../src/FileDropZone/FileDropZone.scss","../../src/Message/Message.scss","../../src/Message/MessageLoading.scss","../../src/Message/CodeBlockMessage/CodeBlockMessage.scss","../../src/Message/TextMessage/TextMessage.scss","../../src/Message/ListMessage/ListMessage.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/ResponseActions/ResponseActions.scss","../../src/SourcesCard/SourcesCard.scss","../../src/SourceDetailsMenuItem/SourceDetailsMenuItem.scss","../../src/main.scss"],"names":[],"mappings":"AAAA;EACE;EACA;;;AAGF;AACE;AAsBA;AASA;;AA9BA;EACE;EACA;EACA;EACA;;AAEF;EACE;;AAGF;AACE;;AACA;EACE;EACA;EACA;EACA;EACA;;AAKJ;EACE;;AAGF;EACE;;AAIF;EACE;EACA;;AAGF;EACE;EACA;;AAGF;EACE;EACA;EACA;;AAGF;EACE;;AAGF;EACE;;;ACxDJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAGA;EACE;;AAKF;EAvBF;IAwBI;IACA;;;AAIF;EA7BF;IA8BI;;;;AAOJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAIA;EAXF;IAYI;;;;AAOJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;;AAMF;EACE;EACA;EACA;EACA;EACA;;;AAGF;EACE;EACA;EACA;EACA;EACA;EACA;;AAGA;EACE;;AAIF;EAdF;IAeI;;;;AAIJ;EACE;;;AAGF;AAAA;AAAA;EAGE;;;AC1GF;EACE;EACA;EACA;;;ACAF;EACE;EACA;EACA;EACA;EACA;;AAGA;EARF;IASI;;;;AAOJ;EAGI;AAAA;IACE;IACA;;;ACpBJ;EACE;EACA;;AAIF;EACE;EACA;;AAKF;EACE;EACA;EACA;EACA;;AAEF;EACE;;AAEF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAEF;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;;;AAQF;EACE;;;AAQF;EACE;;AACA;EACE;;;AASJ;EACE;;AACA;EACE;EACA;;AAEF;EACE;;;AASF;AAAA;AAAA;EACE;;;
|
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/FileDetails/FileDetails.scss","../../src/FileDetailsLabel/FileDetailsLabel.scss","../../src/FileDropZone/FileDropZone.scss","../../src/Message/Message.scss","../../src/Message/MessageLoading.scss","../../src/Message/CodeBlockMessage/CodeBlockMessage.scss","../../src/Message/TextMessage/TextMessage.scss","../../src/Message/ListMessage/ListMessage.scss","../../src/Message/QuickStarts/QuickStartTile.scss","../../src/Message/QuickResponse/QuickResponse.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/ResponseActions/ResponseActions.scss","../../src/Settings/Settings.scss","../../src/SourcesCard/SourcesCard.scss","../../src/SourceDetailsMenuItem/SourceDetailsMenuItem.scss","../../src/TermsOfUse/TermsOfUse.scss","../../src/main.scss"],"names":[],"mappings":"AAAA;EACE;EACA;;;AAGF;AACE;AAsBA;AASA;;AA9BA;EACE;EACA;EACA;EACA;;AAEF;EACE;;AAGF;AACE;;AACA;EACE;EACA;EACA;EACA;EACA;;AAKJ;EACE;;AAGF;EACE;;AAIF;EACE;EACA;;AAGF;EACE;EACA;;AAGF;EACE;EACA;EACA;;AAGF;EACE;;AAGF;EACE;;;ACxDJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAGA;EACE;;AAKF;EAvBF;IAwBI;IACA;;;AAIF;EA7BF;IA8BI;;;;AAOJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAIA;EAXF;IAYI;;;;AAOJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;;AAMF;EACE;EACA;EACA;EACA;EACA;;;AAGF;EACE;EACA;EACA;EACA;EACA;EACA;;AAGA;EACE;;AAIF;EAdF;IAeI;;;;AAIJ;EACE;;;AAGF;AAAA;AAAA;EAGE;;;AC1GF;EACE;EACA;EACA;;;ACAF;EACE;EACA;EACA;EACA;EACA;;AAGA;EARF;IASI;;;;AAOJ;EAGI;AAAA;IACE;IACA;;;ACpBJ;EACE;EACA;;AAIF;EACE;EACA;;AAKF;EACE;EACA;EACA;EACA;;AAEF;EACE;;AAEF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAGF;EACE;;AAEF;EACE;;AAGF;EACE;;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;EACA;;AAKJ;EACE;EACA;EACA;EACA;EAEA;EACA;EACA;EACA;;;AAQF;EACE;;;AAQF;EACE;;AACA;EACE;;;AASJ;EACE;;AACA;EACE;EACA;;AAEF;EACE;;;AASF;AAAA;AAAA;EACE;;;AChLN;EACE;;AAEA;EACE;EACA;;;ACHJ;EACE;EACA;EACA;EACA;EACA;EACA;;;AAEF;EACE;EACA;EACA;EACA;EACA;;;AAMF;EAGI;AAAA;IACE;;EACA;AAAA;IACE;;EAGJ;AAAA;IACE;IACA;IACA;;;AAUF;EACE;;AAGJ;EACE;;;ACjDJ;EACE;;;AAEF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;EACA;;AAEA;EACE;;AAKJ;EACE;EACA;EACA;;AAEA;EACE;;AAGF;EACE;EACA;;AAIJ;EACE;;AAGF;EACE;EACA;EACA;EACA;EACA;;AACA;EACE;;;AAQN;EAGI;AAAA;IACE;;EAEF;AAAA;IACE;;;AASJ;EACE;;AAEF;EACE;;;AAOJ;AAAA;EAEE;EACA;EACA;EACA;EACA;;AAEA;AAAA;AAAA;AAAA;AAAA;AAAA;EAGE;;AAGF;AAAA;AAAA;AAAA;EAEE;EACA;EACA;;AAMA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;EAGE;;;AAOJ;EACE;;;AAOJ;AAAA;EAEE;;;AAGF;EACE;;;AAGF;EACE;;;AC1IF;EACE;;;AAGF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAEF;AAAA;EAEE;;AAEF;EACE;EACA;;AAEF;EACE;;;AAOJ;EACE;AAAA;IAEE;IACA;IACA;IACA;IACA;IACA;IACA;;;AAGJ;EACE;AAAA;IAEE;IACA;IACA;IACA;IACA;IACA;IACA;;;AAOJ;EACE;;;AAMF;EACE;EACA;EACA;EACA;EACA;EACA;;;AAQE;EACE;;;AAQN;EACE;;;ACvFA;EAA0B;;AAMxB;EAAM;;AACN;EAAuB;;AACvB;EACE;;AAIF;EACE;EACA;;AAEF;EACE;;;ACnBN;EACE;EACA;EACA;EACA;EACA;EACA;;AAEA;EAEE;;AAGF;EACE;;AAIF;EACE;EACA;;;AAIJ;EACE;EACA;EACA;;;AC3BF;EACE;EACA;EACA;EACA;;AAEA;EACE;EACA;EACA;;AAGF;EACE;;AAGF;EACE;;AAGF;EACE;EACA;EACA;;AAGF;EACE;;;AAOJ;EAIM;AAAA;IACE;IACA;;;AC1CN;EACE;EACA;EACA;EACA;;AAEF;EACE;AACA;EACA;EACA;;AAEF;EACE;;AAEF;EACE;EACA;;AAEF;EACE;;AAEF;EACE;EACA;EACA;EACA;EACA;;AAEF;EACE;EACA;;AAEF;EACE;EACA;EACA;EACA;EACA;EACA;;AAEF;EACE;;AAEF;EACE;EACA;EACA;;AAEF;EACE;;AAEF;EACE;EACA;;AAEF;EACE;;AAEF;EACE;;;AASA;EACE;EACA;;;AAKN;EACE;;;AAGF;EACE;;;AClFF;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;EACA;EACA;;;AAGF;EACE;EACA;EACA;;;AAGF;EACE;;;AAIF;EACE;EACA;EACA;EACA;EACA;;;ACvBF;EACE;EACA;EACA;EACA;;;AAGF;EACE;EAEA;EACA;EACA;;AACA;EACE;;AAGF;AAAA;EAEE;EACA;;;AAIJ;EACE;EACA;EACA;;AAEA;EACE;;;AAKF;EACE;;AAGF;EACE;;;AAIJ;AAAA;EAEE;EACA;;AAEA;AAAA;EACE;;;AAKF;EACE;;;AAMF;AAAA;EACE;;;AC/DJ;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;;;;AChDR;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EAEA;EACA;EACA;EACA;;AAIA;EACE;EACA;EACA;EACA;EACA;;AAGF;EACE;EACA;EACA;;AAKF;EACE;EACA;;AAKF;EACE;EACA;EACA;EACA;;AAKF;EACE;EACA;EACA;;AAGA;EACE;EACA;EACA;;AAIF;EACE;EACA;EACA;;AAEA;EACE;;AAKJ;EACE;;AAEF;EACE;;AAMJ;EACE;EACA;EACA;EACA;EACA;;AAGF;EACE;EACA;;;AAMJ;EACE;EACA;EACA;;;ACrGF;EACE;EACA;EACA;EACA;;AAEA;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;;;;AC9CN;EACE;EACA;EACA;EACA;;AAGA;EACE;EACA;;AAIF;EACE;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAGF;EACE;EACA;;AAGF;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;;;AAKN;EACE;EACA;;;AC1EE;EACE;;;AAMN;EACE;EACA;EACA;;AAEA;AAAA;AAAA;AAAA;AAAA;EAKE;;AAGF;EACE;EACA;;;AAKF;EACE;EACA;EACA;;AAEA;AAAA;AAAA;AAAA;AAAA;EAKE;;AAGF;EACE;;;AD5CN;EACE;EACA;EACA;EACA;;AAGA;EACE;EACA;;AAIF;EACE;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAGF;EACE;EACA;;AAGF;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;;;AAKN;EACE;EACA;;;AC1EE;EACE;;;AAMN;EACE;EACA;EACA;;AAEA;AAAA;AAAA;AAAA;AAAA;EAKE;;AAGF;EACE;EACA;;;AAKF;EACE;EACA;EACA;;AAEA;AAAA;AAAA;AAAA;AAAA;EAKE;;AAGF;EACE;;;AC3CN;AAAA;EAEE;EACA;EACA;;AAEA;AAAA;AAAA;AAAA;AAAA;AAAA;EAGE;;;AAKF;AAAA;EAEE;EACA;EACA;;;AHnBJ;EACE;EACA;EACA;EACA;;AAEA;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;;;;AIjDN;EACE;EACA;EACA;;AAEA;EALF;IAMI;IACA;;;AAKA;EACE;;;AAOF;EACE;;;ACpBJ;EACE;;AAEA;EAHF;IAII;;;AAGF;EAPF;IAQI;;;AAKF;EACE;EACA;;AAIJ;AAAA;EAEE;EACA;;AAIF;EACE;EACA;EACA;;;AC3BJ;EACE;EACA;EACA;EACA;;AAEA;EACE;;AAKA;EACE;;;ACbN;EACE;EACA;EACA;EACA;;AAEA;EACE;;AAMA;EACE;;AAKJ;EACE;EACA;;AAGA;EACE;;AAKA;EACE;;;AAMR;EACE;IACE;;EAEF;IACE;;;AC1CJ;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;;;AC/CJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAGF;EAEE;;;ACTJ;EACE;EACA;EAEA;EACA;EAEA;EACA;EACA;EACA;EACA;EACA;EACA;EAEA;;AAEA;EACE;;AAGF;EACE;;AAGF;EACE;EACA;EACA;EACA;EACA;;AAGF;EACE;EACA;EACA;EACA;EACA;;AAGF;EACE;EACA;EACA;EACA;EACA;EACA;;;AAIJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;ACxEF;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;;;AAKF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;;AAGF;EAGI;AAAA;IACE;IACA;;;ADtCN;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;;;;AEhDJ;EACE;EACA;EACA;;AAEA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAEF;EACE;EACA;;;AAKN;EACE;EACA;;;AC1BF;EACE;EACA;EACA;EACA;;;AAGF;EACE;EACA;EACA;EACA;;;AAGF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;;AAGF;EACE;;;AAGF;EACE;EACA;EACA;EACA;;;AChCF;EACE;EACA;EACA;EACA;EACA;;;AAGF;EACE;;;AAGF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;AAGF;EACE;;;AAGF;EACE;EACA;;AAEA;EACE;EACA;EACA;;AAEA;EACE;EACA;EACA;;AAEA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAIA;AAAA;EACE;;AAGJ;EACE;EACA;;AAKA;AAAA;EACE;;AAGJ;EACE;;;ACrER;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;;;AC/BJ;EAKE;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;EASA;EACA;EAEA;EAEA;EAEA;AAAA;AAAA;AAAA;AAAA;AAAA;EAMA;EAKA;EAEA;EACA;EACA;EAEA;EACA;EACA;EAEA;;;AAMF;EACE;EACA;EAEA;EAEA;EACA;;;AAGF;EACE;EACA","file":"main.css"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"main":"../../cjs/Compare/index.js","module":"../../esm/Compare/index.js","typings":"../../esm/Compare/index.d.ts"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"main":"../../cjs/Settings/index.js","module":"../../esm/Settings/index.js","typings":"../../esm/Settings/index.d.ts"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"main":"../../cjs/TermsOfUse/index.js","module":"../../esm/TermsOfUse/index.js","typings":"../../esm/TermsOfUse/index.d.ts"}
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import React from 'react';
|
2
|
-
import { DrawerProps } from '@patternfly/react-core';
|
2
|
+
import { DrawerProps, MenuItemProps, MenuProps, DrawerPanelContentProps, DrawerContentProps, DrawerContentBodyProps, DrawerHeadProps, DrawerActionsProps, DrawerCloseButtonProps, DrawerPanelBodyProps } from '@patternfly/react-core';
|
3
3
|
import { ChatbotDisplayMode } from '../Chatbot/Chatbot';
|
4
4
|
export interface Conversation {
|
5
5
|
/** Conversation id */
|
@@ -18,6 +18,8 @@ export interface Conversation {
|
|
18
18
|
label?: string;
|
19
19
|
/** Callback for when user selects item. */
|
20
20
|
onSelect?: (event?: React.MouseEvent, value?: string | number) => void;
|
21
|
+
/** Additional props passed to conversation menu item */
|
22
|
+
additionalProps?: MenuItemProps;
|
21
23
|
}
|
22
24
|
export interface ChatbotConversationHistoryNavProps extends DrawerProps {
|
23
25
|
/** Function called to toggle drawer */
|
@@ -51,6 +53,22 @@ export interface ChatbotConversationHistoryNavProps extends DrawerProps {
|
|
51
53
|
reverseButtonOrder?: boolean;
|
52
54
|
/** Custom test id for the drawer actions */
|
53
55
|
drawerActionsTestId?: string;
|
56
|
+
/** Additional props applied to menu */
|
57
|
+
menuProps?: MenuProps;
|
58
|
+
/** Additional props applied to panel */
|
59
|
+
drawerPanelContentProps?: DrawerPanelContentProps;
|
60
|
+
/** Additional props applied to drawer content */
|
61
|
+
drawerContentProps?: Omit<DrawerContentProps, 'panelContent'>;
|
62
|
+
/** Additional props applied to drawer content body */
|
63
|
+
drawerContentBodyProps?: DrawerContentBodyProps;
|
64
|
+
/** Additional props applied to drawer head */
|
65
|
+
drawerHeadProps?: DrawerHeadProps;
|
66
|
+
/** Additional props applied to drawer actions */
|
67
|
+
drawerActionsProps?: DrawerActionsProps;
|
68
|
+
/** Additional props applied to drawer close button */
|
69
|
+
drawerCloseButtonProps?: DrawerCloseButtonProps;
|
70
|
+
/** Additional props appleid to drawer panel body */
|
71
|
+
drawerPanelBodyProps?: DrawerPanelBodyProps;
|
54
72
|
}
|
55
73
|
export declare const ChatbotConversationHistoryNav: React.FunctionComponent<ChatbotConversationHistoryNavProps>;
|
56
74
|
export default ChatbotConversationHistoryNav;
|
@@ -19,18 +19,18 @@ import { OutlinedCommentAltIcon } from '@patternfly/react-icons';
|
|
19
19
|
import { ChatbotDisplayMode } from '../Chatbot/Chatbot';
|
20
20
|
import ConversationHistoryDropdown from './ChatbotConversationHistoryDropdown';
|
21
21
|
export const ChatbotConversationHistoryNav = (_a) => {
|
22
|
-
var { onDrawerToggle, isDrawerOpen, setIsDrawerOpen, activeItemId, onSelectActiveItem, conversations, newChatButtonText = 'New chat', drawerContent, onNewChat, searchInputPlaceholder = 'Search...', searchInputAriaLabel = 'Filter menu items', handleTextInputChange, displayMode, reverseButtonOrder = false, drawerActionsTestId = 'chatbot-nav-drawer-actions' } = _a, props = __rest(_a, ["onDrawerToggle", "isDrawerOpen", "setIsDrawerOpen", "activeItemId", "onSelectActiveItem", "conversations", "newChatButtonText", "drawerContent", "onNewChat", "searchInputPlaceholder", "searchInputAriaLabel", "handleTextInputChange", "displayMode", "reverseButtonOrder", "drawerActionsTestId"]);
|
22
|
+
var { onDrawerToggle, isDrawerOpen, setIsDrawerOpen, activeItemId, onSelectActiveItem, conversations, newChatButtonText = 'New chat', drawerContent, onNewChat, searchInputPlaceholder = 'Search...', searchInputAriaLabel = 'Filter menu items', handleTextInputChange, displayMode, reverseButtonOrder = false, drawerActionsTestId = 'chatbot-nav-drawer-actions', menuProps, drawerPanelContentProps, drawerContentProps, drawerContentBodyProps, drawerHeadProps, drawerActionsProps, drawerCloseButtonProps, drawerPanelBodyProps } = _a, props = __rest(_a, ["onDrawerToggle", "isDrawerOpen", "setIsDrawerOpen", "activeItemId", "onSelectActiveItem", "conversations", "newChatButtonText", "drawerContent", "onNewChat", "searchInputPlaceholder", "searchInputAriaLabel", "handleTextInputChange", "displayMode", "reverseButtonOrder", "drawerActionsTestId", "menuProps", "drawerPanelContentProps", "drawerContentProps", "drawerContentBodyProps", "drawerHeadProps", "drawerActionsProps", "drawerCloseButtonProps", "drawerPanelBodyProps"]);
|
23
23
|
const drawerRef = React.useRef(null);
|
24
24
|
const onExpand = () => {
|
25
25
|
drawerRef.current && drawerRef.current.focus();
|
26
26
|
};
|
27
27
|
const getNavItem = (conversation) => {
|
28
28
|
var _a;
|
29
|
-
return (React.createElement(MenuItem, Object.assign({ className:
|
29
|
+
return (React.createElement(MenuItem, Object.assign({ className: `pf-chatbot__menu-item ${activeItemId && activeItemId === conversation.id ? 'pf-chatbot__menu-item--active' : ''}`, itemId: conversation.id, key: conversation.id }, (conversation.noIcon ? {} : { icon: (_a = conversation.icon) !== null && _a !== void 0 ? _a : React.createElement(OutlinedCommentAltIcon, null) }), (conversation.menuItems
|
30
30
|
? {
|
31
31
|
actions: (React.createElement(ConversationHistoryDropdown, { menuClassName: conversation.menuClassName, onSelect: conversation.onSelect, menuItems: conversation.menuItems, label: conversation.label }))
|
32
32
|
}
|
33
|
-
: {})), conversation.text));
|
33
|
+
: {}), conversation.additionalProps), conversation.text));
|
34
34
|
};
|
35
35
|
const buildMenu = () => {
|
36
36
|
if (Array.isArray(conversations)) {
|
@@ -46,16 +46,16 @@ export const ChatbotConversationHistoryNav = (_a) => {
|
|
46
46
|
// Menu Content
|
47
47
|
// - Consumers should pass an array to <Chatbot> of the list of conversations
|
48
48
|
// - Groups could be optional, but items need to be ordered by date
|
49
|
-
const menuContent = (React.createElement(Menu, { isPlain: true, onSelect: onSelectActiveItem, activeItemId: activeItemId },
|
49
|
+
const menuContent = (React.createElement(Menu, Object.assign({ isPlain: true, onSelect: onSelectActiveItem, activeItemId: activeItemId }, menuProps),
|
50
50
|
React.createElement(MenuContent, null, buildMenu())));
|
51
|
-
const panelContent = (React.createElement(DrawerPanelContent, { focusTrap: { enabled: true },
|
52
|
-
React.createElement(DrawerHead,
|
53
|
-
React.createElement(DrawerActions, { "data-testid": drawerActionsTestId, className: reverseButtonOrder ? 'pf-v6-c-drawer__actions--reversed' : '' },
|
54
|
-
React.createElement(DrawerCloseButton, { onClick: onDrawerToggle }),
|
51
|
+
const panelContent = (React.createElement(DrawerPanelContent, Object.assign({ focusTrap: { enabled: true }, defaultSize: "384px" }, drawerPanelContentProps),
|
52
|
+
React.createElement(DrawerHead, Object.assign({}, drawerHeadProps),
|
53
|
+
React.createElement(DrawerActions, Object.assign({ "data-testid": drawerActionsTestId, className: reverseButtonOrder ? 'pf-v6-c-drawer__actions--reversed' : '' }, drawerActionsProps),
|
54
|
+
React.createElement(DrawerCloseButton, Object.assign({ onClick: onDrawerToggle }, drawerCloseButtonProps)),
|
55
55
|
onNewChat && React.createElement(Button, { onClick: onNewChat }, newChatButtonText))),
|
56
56
|
handleTextInputChange && (React.createElement("div", { className: "pf-chatbot__input" },
|
57
57
|
React.createElement(SearchInput, { "aria-label": searchInputAriaLabel, onChange: (_event, value) => handleTextInputChange(value), placeholder: searchInputPlaceholder }))),
|
58
|
-
React.createElement(DrawerPanelBody,
|
58
|
+
React.createElement(DrawerPanelBody, Object.assign({}, drawerPanelBodyProps), menuContent)));
|
59
59
|
// An onKeyDown property must be passed to the Drawer component to handle closing
|
60
60
|
// the drawer panel and deactivating the focus trap via the Escape key.
|
61
61
|
const onEscape = (event) => {
|
@@ -67,8 +67,8 @@ export const ChatbotConversationHistoryNav = (_a) => {
|
|
67
67
|
}
|
68
68
|
};
|
69
69
|
return (React.createElement(Drawer, Object.assign({ className: "pf-chatbot__history", isExpanded: isDrawerOpen, onExpand: onExpand, position: "start", onKeyDown: onEscape, isInline: displayMode === ChatbotDisplayMode.fullscreen || displayMode === ChatbotDisplayMode.embedded }, props),
|
70
|
-
React.createElement(DrawerContent, { panelContent: panelContent },
|
71
|
-
React.createElement(DrawerContentBody,
|
70
|
+
React.createElement(DrawerContent, Object.assign({ panelContent: panelContent }, drawerContentProps),
|
71
|
+
React.createElement(DrawerContentBody, Object.assign({}, drawerContentBodyProps),
|
72
72
|
React.createElement(React.Fragment, null,
|
73
73
|
React.createElement("div", { className: `${isDrawerOpen && (displayMode === ChatbotDisplayMode.default || displayMode === ChatbotDisplayMode.docked) ? 'pf-v6-c-backdrop pf-chatbot__drawer-backdrop' : undefined} ` }),
|
74
74
|
drawerContent)))));
|