aov-agent 1.0.1 → 1.0.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/README.md +313 -250
- package/dist/agent-ui/components/Assistant/AgentButton/AgentButton.js +5 -5
- package/dist/agent-ui/components/Assistant/AgentButton/AgentButton.scss +40 -40
- package/dist/agent-ui/components/Assistant/Assistant.js +29 -34
- package/dist/agent-ui/components/Assistant/Assistant.scss +3 -3
- package/dist/agent-ui/components/Assistant/AssistantWidget/AssistantWidget.js +42 -36
- package/dist/agent-ui/components/Assistant/AssistantWidget/AssistantWidget.scss +205 -211
- package/dist/agent-ui/components/Assistant/AssistantWidget/components/ListChat.js +8 -8
- package/dist/agent-ui/components/Assistant/Markdown/MarkdownText.js +21 -21
- package/dist/agent-ui/components/Assistant/Markdown/MarkdownText.scss +222 -222
- package/dist/agent-ui/components/Assistant/Markdown/MathRenderer.js +29 -23
- package/dist/agent-ui/components/Assistant/Suggestions/Suggestions.scss +22 -22
- package/dist/agent-ui/components/Assistant/ThreadProvider.js +20 -21
- package/dist/agent-ui/components/Assistant/ToolResult/CardTool.js +58 -1
- package/dist/agent-ui/components/Assistant/ToolResult/CardTool.scss +12 -0
- package/dist/agent-ui/components/Assistant/ToolResult/ToolResult.js +31 -7
- package/dist/agent-ui/components/CopyToClipboard/CopyToClipboard.js +43 -0
- package/dist/agent-ui/components/CopyToClipboard/index.js +2 -0
- package/dist/agent-ui/components/ResizableModal/ResizableModal.js +20 -20
- package/dist/agent-ui/components/ResizableModal/ResizableModal.scss +117 -117
- package/dist/agent-ui/const/appName.js +6 -0
- package/dist/agent-ui/const/option.js +9 -0
- package/dist/agent-ui/const/toolName.js +6 -0
- package/dist/agent-ui/contexts/AgentContext.js +26 -11
- package/dist/agent-ui/contexts/SuggestionsContext.js +11 -11
- package/dist/agent-ui/contexts/ThreadContext.js +3 -3
- package/dist/agent-ui/helpers/copyToClipboard.js +33 -0
- package/dist/agent-ui/helpers/formatQuery.js +15 -0
- package/dist/agent-ui/hooks/useFetchApi.js +14 -14
- package/dist/agent-ui/hooks/useStreamApi.js +5 -5
- package/dist/agent-ui/resources/assistant-avatar.svg +51 -0
- package/dist/agent-ui/services/errorService.js +11 -11
- package/dist/agent-ui/utils/api.js +14 -14
- package/package.json +24 -6
|
@@ -7,13 +7,10 @@ import ThreadProvider from "./ThreadProvider.js";
|
|
|
7
7
|
import AssistantWidget from "./AssistantWidget/AssistantWidget.js";
|
|
8
8
|
import ResizableModal from "../ResizableModal/ResizableModal.js";
|
|
9
9
|
import "./Assistant.scss";
|
|
10
|
-
var AssistantCore = function AssistantCore(
|
|
11
|
-
var shop = _ref.shop,
|
|
12
|
-
apiUrl = _ref.apiUrl;
|
|
10
|
+
var AssistantCore = function AssistantCore() {
|
|
13
11
|
var _useContext = useContext(AgentContext),
|
|
14
12
|
openAgent = _useContext.openAgent,
|
|
15
13
|
setOpenAgent = _useContext.setOpenAgent;
|
|
16
|
-
if (!(shop !== null && shop !== void 0 && shop.showAgentChat)) return null;
|
|
17
14
|
return /*#__PURE__*/React.createElement("div", {
|
|
18
15
|
className: "aov-assistant-core"
|
|
19
16
|
}, /*#__PURE__*/React.createElement(AgentButton, {
|
|
@@ -26,48 +23,46 @@ var AssistantCore = function AssistantCore(_ref) {
|
|
|
26
23
|
return setOpenAgent(false);
|
|
27
24
|
},
|
|
28
25
|
accessibilityLabel: "Mavi"
|
|
29
|
-
}, /*#__PURE__*/React.createElement(SuggestionsProvider, null, /*#__PURE__*/React.createElement(ThreadProvider, {
|
|
30
|
-
shop: shop,
|
|
31
|
-
apiUrl: apiUrl
|
|
32
|
-
}, /*#__PURE__*/React.createElement(AssistantWidget, {
|
|
33
|
-
shop: shop,
|
|
26
|
+
}, /*#__PURE__*/React.createElement(SuggestionsProvider, null, /*#__PURE__*/React.createElement(ThreadProvider, null, /*#__PURE__*/React.createElement(AssistantWidget, {
|
|
34
27
|
onClose: function onClose() {
|
|
35
28
|
return setOpenAgent(false);
|
|
36
29
|
}
|
|
37
30
|
})))));
|
|
38
31
|
};
|
|
39
|
-
AssistantCore.propTypes = {
|
|
40
|
-
shop: PropTypes.shape({
|
|
41
|
-
showAgentChat: PropTypes.bool,
|
|
42
|
-
id: PropTypes.string
|
|
43
|
-
}),
|
|
44
|
-
apiUrl: PropTypes.string
|
|
45
|
-
};
|
|
46
32
|
|
|
47
|
-
/**
|
|
48
|
-
* Assistant - Main AI assistant component with chat interface
|
|
49
|
-
*
|
|
50
|
-
* @param {Object} shop - Shop data object
|
|
51
|
-
* @param {boolean} shop.showAgentChat - Whether to show the agent chat
|
|
52
|
-
* @param {string} shop.id - Shop identifier
|
|
53
|
-
* @param {string} apiUrl - API endpoint URL for chat
|
|
54
|
-
* @
|
|
33
|
+
/**
|
|
34
|
+
* Assistant - Main AI assistant component with chat interface
|
|
35
|
+
*
|
|
36
|
+
* @param {Object} shop - Shop data object
|
|
37
|
+
* @param {boolean} shop.showAgentChat - Whether to show the agent chat
|
|
38
|
+
* @param {string} shop.id - Shop identifier
|
|
39
|
+
* @param {string} apiUrl - API endpoint URL for chat
|
|
40
|
+
* @param {string} appName - Application name
|
|
41
|
+
* @param {Object} customToolRenderers - Custom renderers for tools
|
|
42
|
+
* @returns {React.ReactElement} Assistant component
|
|
55
43
|
*/
|
|
56
|
-
export var Assistant = function Assistant(
|
|
57
|
-
var shop =
|
|
58
|
-
apiUrl =
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
44
|
+
export var Assistant = function Assistant(_ref) {
|
|
45
|
+
var shop = _ref.shop,
|
|
46
|
+
apiUrl = _ref.apiUrl,
|
|
47
|
+
appName = _ref.appName,
|
|
48
|
+
customToolRenderers = _ref.customToolRenderers;
|
|
49
|
+
if (!shop.showAgentChat) return null;
|
|
50
|
+
return /*#__PURE__*/React.createElement(AgentProvider, {
|
|
51
|
+
contextValue: {
|
|
52
|
+
appName: appName,
|
|
53
|
+
shop: shop,
|
|
54
|
+
apiUrl: apiUrl,
|
|
55
|
+
customToolRenderers: customToolRenderers
|
|
56
|
+
}
|
|
57
|
+
}, /*#__PURE__*/React.createElement(AssistantCore, null));
|
|
65
58
|
};
|
|
66
59
|
Assistant.propTypes = {
|
|
67
60
|
shop: PropTypes.shape({
|
|
68
61
|
showAgentChat: PropTypes.bool,
|
|
69
62
|
id: PropTypes.string
|
|
70
63
|
}),
|
|
71
|
-
apiUrl: PropTypes.string
|
|
64
|
+
apiUrl: PropTypes.string,
|
|
65
|
+
appName: PropTypes.string,
|
|
66
|
+
customToolRenderers: PropTypes.object
|
|
72
67
|
};
|
|
73
68
|
export default Assistant;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
.aov-assistant-core {
|
|
2
|
-
position: relative;
|
|
3
|
-
}
|
|
1
|
+
.aov-assistant-core {
|
|
2
|
+
position: relative;
|
|
3
|
+
}
|
|
@@ -1,14 +1,17 @@
|
|
|
1
|
+
var _excluded = ["shop"];
|
|
1
2
|
function _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }
|
|
2
3
|
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
3
4
|
function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
|
|
4
5
|
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
5
6
|
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t["return"] && (u = t["return"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
6
7
|
function _arrayWithHoles(r) { if (Array.isArray(r)) return r; }
|
|
8
|
+
function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
|
|
9
|
+
function _objectWithoutProperties(e, t) { if (null == e) return {}; var o, r, i = _objectWithoutPropertiesLoose(e, t); if (Object.getOwnPropertySymbols) { var n = Object.getOwnPropertySymbols(e); for (r = 0; r < n.length; r++) o = n[r], -1 === t.indexOf(o) && {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]); } return i; }
|
|
10
|
+
function _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t = {}; for (var n in r) if ({}.hasOwnProperty.call(r, n)) { if (-1 !== e.indexOf(n)) continue; t[n] = r[n]; } return t; }
|
|
7
11
|
import React, { useCallback, useState, useContext, useMemo } from "react";
|
|
8
12
|
import PropTypes from "prop-types";
|
|
9
|
-
import { Box, Button, InlineStack, Popover, Spinner } from "@shopify/polaris";
|
|
13
|
+
import { Box, Button, InlineStack, Popover, Spinner, Text } from "@shopify/polaris";
|
|
10
14
|
import { ComposeIcon, XIcon } from "@shopify/polaris-icons";
|
|
11
|
-
import { connect } from "react-redux";
|
|
12
15
|
import { ThreadContext } from "../../../contexts/ThreadContext.js";
|
|
13
16
|
import { Composer, Thread, ThreadWelcome } from "@assistant-ui/react-ui";
|
|
14
17
|
import { MarkdownText } from "../Markdown/MarkdownText.js";
|
|
@@ -19,6 +22,9 @@ import "@assistant-ui/react-markdown/styles/dot.css";
|
|
|
19
22
|
import ToolResult from "../ToolResult/ToolResult.js";
|
|
20
23
|
import ListChat from "./components/ListChat.js";
|
|
21
24
|
import "./AssistantWidget.scss";
|
|
25
|
+
import Avatar from "../../../resources/assistant-avatar.svg";
|
|
26
|
+
import { welcomeSuggestions } from "../../../const/option";
|
|
27
|
+
import { AgentContext } from "../../../contexts/AgentContext.js";
|
|
22
28
|
var AssistantText = /*#__PURE__*/React.memo(function AssistantText(props) {
|
|
23
29
|
try {
|
|
24
30
|
return /*#__PURE__*/React.createElement("div", {
|
|
@@ -31,27 +37,33 @@ var AssistantText = /*#__PURE__*/React.memo(function AssistantText(props) {
|
|
|
31
37
|
}, props.children);
|
|
32
38
|
}
|
|
33
39
|
});
|
|
34
|
-
var AssistantTool = /*#__PURE__*/React.memo(function AssistantTool(
|
|
40
|
+
var AssistantTool = /*#__PURE__*/React.memo(function AssistantTool(_ref) {
|
|
41
|
+
var shop = _ref.shop,
|
|
42
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
35
43
|
try {
|
|
36
|
-
return /*#__PURE__*/React.createElement(ToolResult, props
|
|
44
|
+
return /*#__PURE__*/React.createElement(ToolResult, _extends({}, props, {
|
|
45
|
+
shop: shop
|
|
46
|
+
}));
|
|
37
47
|
} catch (err) {
|
|
38
48
|
console.error("Error rendering tool result:", err);
|
|
39
49
|
return null;
|
|
40
50
|
}
|
|
41
51
|
});
|
|
42
|
-
var AssistantWidget = function AssistantWidget(
|
|
43
|
-
var
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
52
|
+
var AssistantWidget = function AssistantWidget(_ref2) {
|
|
53
|
+
var onClose = _ref2.onClose;
|
|
54
|
+
var _useContext = useContext(AgentContext),
|
|
55
|
+
appName = _useContext.appName,
|
|
56
|
+
shop = _useContext.shop;
|
|
57
|
+
var _useContext2 = useContext(ThreadContext),
|
|
58
|
+
threads = _useContext2.threads,
|
|
59
|
+
loadingThreads = _useContext2.loadingThreads,
|
|
60
|
+
getThread = _useContext2.getThread,
|
|
61
|
+
loadingMessages = _useContext2.loadingMessages,
|
|
62
|
+
thread = _useContext2.thread,
|
|
63
|
+
_setThread = _useContext2.setThread,
|
|
64
|
+
resetThread = _useContext2.resetThread,
|
|
65
|
+
updateThread = _useContext2.updateThread,
|
|
66
|
+
deleteThread = _useContext2.deleteThread;
|
|
55
67
|
var _useThreadAutoScrollF = useThreadAutoScrollFix(),
|
|
56
68
|
autoScroll = _useThreadAutoScrollF.autoScroll,
|
|
57
69
|
handleScroll = _useThreadAutoScrollF.handleScroll;
|
|
@@ -73,19 +85,24 @@ var AssistantWidget = function AssistantWidget(_ref) {
|
|
|
73
85
|
}, /*#__PURE__*/React.createElement(Box, {
|
|
74
86
|
width: "fit-content",
|
|
75
87
|
minWidth: "60px"
|
|
76
|
-
},
|
|
88
|
+
}, /*#__PURE__*/React.createElement(Text, {
|
|
89
|
+
truncate: true
|
|
90
|
+
}, thread && "title" in thread ? thread.title : "New chat"))));
|
|
77
91
|
var assistantComponents = useMemo(function () {
|
|
78
92
|
return {
|
|
79
93
|
Text: AssistantText,
|
|
80
|
-
ToolFallback:
|
|
94
|
+
ToolFallback: function ToolFallback(props) {
|
|
95
|
+
return /*#__PURE__*/React.createElement(AssistantTool, _extends({
|
|
96
|
+
shop: shop
|
|
97
|
+
}, props));
|
|
98
|
+
}
|
|
81
99
|
};
|
|
82
|
-
}, []);
|
|
83
|
-
var welcomeSuggestions = ["How do I create my first Buy X Get Y campaign?", "How do I set a spending threshold for free gifts?", "How do I customize the Pop-up for my campaign?", "How do I check campaign performance and reports?"];
|
|
100
|
+
}, [shop]);
|
|
84
101
|
return /*#__PURE__*/React.createElement("div", {
|
|
85
102
|
className: "AOV-Sidekick__Container"
|
|
86
103
|
}, /*#__PURE__*/React.createElement(Box, {
|
|
87
104
|
paddingBlockStart: "300",
|
|
88
|
-
paddingBlockEnd: "
|
|
105
|
+
paddingBlockEnd: "200",
|
|
89
106
|
paddingInlineStart: "200",
|
|
90
107
|
paddingInlineEnd: "300"
|
|
91
108
|
}, /*#__PURE__*/React.createElement(InlineStack, {
|
|
@@ -136,8 +153,7 @@ var AssistantWidget = function AssistantWidget(_ref) {
|
|
|
136
153
|
message: "Hi! I'm Mavi, AOV Free Gift Assistant. I'm here to help you."
|
|
137
154
|
},
|
|
138
155
|
assistantAvatar: {
|
|
139
|
-
src:
|
|
140
|
-
// TODO: Add avatar path
|
|
156
|
+
src: Avatar,
|
|
141
157
|
alt: "Mavi"
|
|
142
158
|
},
|
|
143
159
|
assistantMessage: {
|
|
@@ -159,7 +175,7 @@ var AssistantWidget = function AssistantWidget(_ref) {
|
|
|
159
175
|
size: "large"
|
|
160
176
|
}), /*#__PURE__*/React.createElement(ThreadWelcome.Message, null)), /*#__PURE__*/React.createElement("div", {
|
|
161
177
|
className: "aui-thread-welcome-suggestion-container"
|
|
162
|
-
}, welcomeSuggestions.map(function (prompt, index) {
|
|
178
|
+
}, welcomeSuggestions(appName).map(function (prompt, index) {
|
|
163
179
|
return /*#__PURE__*/React.createElement(ThreadWelcome.Suggestion, {
|
|
164
180
|
key: index,
|
|
165
181
|
suggestion: {
|
|
@@ -172,16 +188,6 @@ var AssistantWidget = function AssistantWidget(_ref) {
|
|
|
172
188
|
}), /*#__PURE__*/React.createElement(Composer.Action, null)))));
|
|
173
189
|
};
|
|
174
190
|
AssistantWidget.propTypes = {
|
|
175
|
-
shop: PropTypes.shape({
|
|
176
|
-
id: PropTypes.string,
|
|
177
|
-
showAgentChat: PropTypes.bool
|
|
178
|
-
}),
|
|
179
191
|
onClose: PropTypes.func.isRequired
|
|
180
192
|
};
|
|
181
|
-
|
|
182
|
-
var _state$shop;
|
|
183
|
-
return {
|
|
184
|
-
shop: (_state$shop = state.shop) === null || _state$shop === void 0 ? void 0 : _state$shop.activeShop
|
|
185
|
-
};
|
|
186
|
-
};
|
|
187
|
-
export default connect(mapStateToProps)(AssistantWidget);
|
|
193
|
+
export default AssistantWidget;
|
|
@@ -1,211 +1,205 @@
|
|
|
1
|
-
.AOV-Sidekick__Container {
|
|
2
|
-
position: relative;
|
|
3
|
-
background-color: #fff;
|
|
4
|
-
height: 100%;
|
|
5
|
-
padding-bottom: 5px;
|
|
6
|
-
|
|
7
|
-
.Polaris-Spinner--sizeSmall {
|
|
8
|
-
height: 20px;
|
|
9
|
-
}
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
.AOV-Sidekick__Loading {
|
|
13
|
-
display: flex;
|
|
14
|
-
justify-content: center;
|
|
15
|
-
align-items: center;
|
|
16
|
-
height: 100%;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
.
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
.aui-assistant-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
}
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
}
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
.
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
}
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
}
|
|
207
|
-
}
|
|
208
|
-
}
|
|
209
|
-
}
|
|
210
|
-
}
|
|
211
|
-
|
|
1
|
+
.AOV-Sidekick__Container {
|
|
2
|
+
position: relative;
|
|
3
|
+
background-color: #fff;
|
|
4
|
+
height: 100%;
|
|
5
|
+
padding-bottom: 5px;
|
|
6
|
+
|
|
7
|
+
.Polaris-Spinner--sizeSmall {
|
|
8
|
+
height: 20px;
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.AOV-Sidekick__Loading {
|
|
13
|
+
display: flex;
|
|
14
|
+
justify-content: center;
|
|
15
|
+
align-items: center;
|
|
16
|
+
height: 100%;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
.aui-thread-root {
|
|
20
|
+
height: 100%;
|
|
21
|
+
font-family: Arial, Helvetica, sans-serif;
|
|
22
|
+
display: flex;
|
|
23
|
+
flex-direction: column;
|
|
24
|
+
padding-bottom: 20px;
|
|
25
|
+
button {
|
|
26
|
+
cursor: pointer;
|
|
27
|
+
}
|
|
28
|
+
.aui-thread-message-content {
|
|
29
|
+
font-size: 14px;
|
|
30
|
+
}
|
|
31
|
+
.aui-avatar-root img {
|
|
32
|
+
width: 32px;
|
|
33
|
+
height: 32px;
|
|
34
|
+
max-width: 32px;
|
|
35
|
+
max-height: 32px;
|
|
36
|
+
border-radius: 16px;
|
|
37
|
+
}
|
|
38
|
+
.aui-thread-viewport {
|
|
39
|
+
flex: 1;
|
|
40
|
+
overflow-y: auto;
|
|
41
|
+
scrollbar-width: thin;
|
|
42
|
+
padding: 1rem 0;
|
|
43
|
+
display: flex;
|
|
44
|
+
flex-direction: column;
|
|
45
|
+
gap: 6px;
|
|
46
|
+
.aui-thread-welcome-root {
|
|
47
|
+
text-align: center;
|
|
48
|
+
display: flex;
|
|
49
|
+
flex-direction: column;
|
|
50
|
+
align-items: center;
|
|
51
|
+
gap: 8rem;
|
|
52
|
+
justify-content: center;
|
|
53
|
+
height: 100%;
|
|
54
|
+
padding: 1rem;
|
|
55
|
+
.aui-thread-welcome-center {
|
|
56
|
+
display: flex;
|
|
57
|
+
flex-direction: column;
|
|
58
|
+
align-items: center;
|
|
59
|
+
gap: 8px;
|
|
60
|
+
}
|
|
61
|
+
.aui-thread-welcome-message {
|
|
62
|
+
font-weight: 500;
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
.aui-thread-welcome-suggestion-container {
|
|
66
|
+
display: grid;
|
|
67
|
+
grid-template-columns: 1fr 1fr;
|
|
68
|
+
gap: 0.75rem;
|
|
69
|
+
width: 100%;
|
|
70
|
+
max-width: 500px;
|
|
71
|
+
margin: 0 auto;
|
|
72
|
+
.aui-thread-welcome-suggestion {
|
|
73
|
+
font-family: Arial, Helvetica, sans-serif !important;
|
|
74
|
+
background-color: transparent;
|
|
75
|
+
border: 1px solid #e0e0e0;
|
|
76
|
+
border-radius: 10px;
|
|
77
|
+
padding: 6px 12px;
|
|
78
|
+
font-size: 12px;
|
|
79
|
+
cursor: pointer;
|
|
80
|
+
font-weight: 500;
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
.aui-user-message-root {
|
|
84
|
+
padding: 1px 12px;
|
|
85
|
+
display: flex;
|
|
86
|
+
justify-content: flex-end;
|
|
87
|
+
margin-left: 2rem;
|
|
88
|
+
.aui-user-message-content {
|
|
89
|
+
width: fit-content;
|
|
90
|
+
padding: 4px 12px;
|
|
91
|
+
background-color: rgb(241, 241, 241);
|
|
92
|
+
border-radius: 10px;
|
|
93
|
+
p {
|
|
94
|
+
word-break: break-word;
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
.aui-assistant-message-root {
|
|
99
|
+
display: flex;
|
|
100
|
+
flex-wrap: wrap;
|
|
101
|
+
gap: 6px;
|
|
102
|
+
padding: 1px 12px;
|
|
103
|
+
margin-right: 6px;
|
|
104
|
+
.aui-assistant-message-content {
|
|
105
|
+
width: calc(100% - 40px);
|
|
106
|
+
max-width: 100%;
|
|
107
|
+
}
|
|
108
|
+
.aui-assistant-action-bar-root {
|
|
109
|
+
height: 20px;
|
|
110
|
+
left: 0px;
|
|
111
|
+
&[data-floating="true"] {
|
|
112
|
+
display: none;
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
.aui-branch-picker-root {
|
|
116
|
+
display: flex;
|
|
117
|
+
align-items: center;
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
img {
|
|
121
|
+
display: block;
|
|
122
|
+
width: 100%;
|
|
123
|
+
height: auto;
|
|
124
|
+
object-fit: contain;
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
.aui-thread-viewport-footer {
|
|
128
|
+
height: fit-content;
|
|
129
|
+
min-height: 85px;
|
|
130
|
+
display: flex;
|
|
131
|
+
flex-direction: column;
|
|
132
|
+
justify-content: end;
|
|
133
|
+
width: 100%;
|
|
134
|
+
padding: 12px;
|
|
135
|
+
background-color: #fff;
|
|
136
|
+
gap: 8px;
|
|
137
|
+
margin-bottom: 6px;
|
|
138
|
+
.aui-composer-root {
|
|
139
|
+
display: flex;
|
|
140
|
+
align-items: center;
|
|
141
|
+
gap: 8px;
|
|
142
|
+
padding: 4px 8px;
|
|
143
|
+
border: 1px solid #e0e0e0;
|
|
144
|
+
border-radius: 16px;
|
|
145
|
+
background-color: #ffffff;
|
|
146
|
+
.aui-composer-input {
|
|
147
|
+
width: 100%;
|
|
148
|
+
font-family: Arial, Helvetica, sans-serif;
|
|
149
|
+
resize: none;
|
|
150
|
+
border: none;
|
|
151
|
+
outline: none;
|
|
152
|
+
background-color: transparent;
|
|
153
|
+
font-size: 12px;
|
|
154
|
+
padding-left: 6px;
|
|
155
|
+
scrollbar-width: none;
|
|
156
|
+
max-height: 200px;
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
.aui-button {
|
|
161
|
+
border: none;
|
|
162
|
+
height: 24px;
|
|
163
|
+
background-color: transparent;
|
|
164
|
+
svg {
|
|
165
|
+
width: 16px;
|
|
166
|
+
height: 16px;
|
|
167
|
+
}
|
|
168
|
+
span {
|
|
169
|
+
display: none;
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
.Polaris-Scrollable {
|
|
175
|
+
scrollbar-width: thin;
|
|
176
|
+
li {
|
|
177
|
+
.AOV-Sidekick__ChatItem {
|
|
178
|
+
width: 100%;
|
|
179
|
+
display: flex;
|
|
180
|
+
align-items: center;
|
|
181
|
+
flex-wrap: nowrap;
|
|
182
|
+
position: relative;
|
|
183
|
+
gap: 4px;
|
|
184
|
+
> span {
|
|
185
|
+
width: 100%;
|
|
186
|
+
}
|
|
187
|
+
.AOV-Sidekick__ChatAction {
|
|
188
|
+
display: none;
|
|
189
|
+
position: absolute;
|
|
190
|
+
right: 0;
|
|
191
|
+
}
|
|
192
|
+
> div:first-child {
|
|
193
|
+
width: calc(100% - 50px);
|
|
194
|
+
}
|
|
195
|
+
&:hover {
|
|
196
|
+
> span {
|
|
197
|
+
width: calc(100% - 60px);
|
|
198
|
+
}
|
|
199
|
+
.AOV-Sidekick__ChatAction {
|
|
200
|
+
display: flex;
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
}
|