@box/box-ai-agent-selector 0.24.1 → 0.25.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm/lib/box-ai-agent-selector.js +83 -82
- package/esm/lib/box-ai-agent.js +60 -44
- package/i18n/en-x-pseudo.js +8 -8
- package/i18n/en-x-pseudo.properties +8 -8
- package/package.json +2 -2
- package/styles/box-ai-agent-selector.css +1 -1
- package/styles/box-ai-agent.css +1 -1
- package/types/lib/box-ai-agent.d.ts +5 -1
@@ -1,145 +1,146 @@
|
|
1
|
-
import { useFullTextTooltip as z, FilterChip as
|
1
|
+
import { useFullTextTooltip as z, FilterChip as g, Popover as d, Tooltip as H, Status as J, LoadingIndicator as X, SmallList as Z, Button as $ } from "@box/blueprint-web";
|
2
2
|
import { AlertBadge as q } from "@box/blueprint-web-assets/icons/Fill";
|
3
|
-
import
|
4
|
-
import { useState as
|
3
|
+
import m from "clsx";
|
4
|
+
import { useState as B, useRef as tt, useEffect as et, useCallback as _ } from "react";
|
5
5
|
import { useIntl as at } from "react-intl";
|
6
6
|
import { BoxAiAgent as nt } from "./box-ai-agent.js";
|
7
|
-
import { LOGGER_BASE_CONFIG as
|
7
|
+
import { LOGGER_BASE_CONFIG as y, LOGGER_ACTION_CLICK as S, LOGGER_TARGET as T } from "./constants.js";
|
8
8
|
import { ACTIONS as ot } from "./contexts/actions.js";
|
9
9
|
import { useAgentsDispatch as rt } from "./contexts/context.js";
|
10
|
-
import
|
11
|
-
import { R } from "../../chunks/types.js";
|
12
|
-
import { jsx as
|
13
|
-
import '../../styles/box-ai-agent-selector.css';const it = "
|
10
|
+
import s from "./messages.js";
|
11
|
+
import { R as I } from "../../chunks/types.js";
|
12
|
+
import { jsx as e, jsxs as R } from "react/jsx-runtime";
|
13
|
+
import '../../styles/box-ai-agent-selector.css';const it = "_agentSelector_1y96v_1", st = "_agentStatus_1y96v_4", lt = "_agentLoader_1y96v_18", ct = "_agentError_1y96v_21", pt = "_triggerChip_1y96v_24", gt = "_agentLabel_1y96v_30", dt = "_dropdownIndicator_1y96v_36", mt = "_sidebar_1y96v_51", _t = "_agentListItemIcon_1y96v_70", ft = "_agentListContainer_1y96v_75", Lt = "_agentListRetryButton_1y96v_105", a = {
|
14
14
|
agentSelector: it,
|
15
15
|
agentStatus: st,
|
16
16
|
agentLoader: lt,
|
17
17
|
agentError: ct,
|
18
|
-
triggerChip:
|
19
|
-
agentLabel:
|
20
|
-
dropdownIndicator:
|
21
|
-
sidebar:
|
18
|
+
triggerChip: pt,
|
19
|
+
agentLabel: gt,
|
20
|
+
dropdownIndicator: dt,
|
21
|
+
sidebar: mt,
|
22
22
|
agentListItemIcon: _t,
|
23
23
|
agentListContainer: ft,
|
24
|
-
agentListRetryButton:
|
24
|
+
agentListRetryButton: Lt
|
25
25
|
};
|
26
|
-
function
|
26
|
+
function Ot({
|
27
27
|
agents: f,
|
28
|
-
contentClassName:
|
28
|
+
contentClassName: P,
|
29
29
|
onErrorAction: b,
|
30
30
|
recordAction: n,
|
31
|
-
requestState:
|
32
|
-
disabled:
|
33
|
-
selectedAgent:
|
34
|
-
triggerChipClassName:
|
35
|
-
variant:
|
31
|
+
requestState: L,
|
32
|
+
disabled: D,
|
33
|
+
selectedAgent: o,
|
34
|
+
triggerChipClassName: k,
|
35
|
+
variant: K = "modal"
|
36
36
|
}) {
|
37
37
|
const {
|
38
|
-
formatMessage:
|
39
|
-
} = at(), [l, c] =
|
40
|
-
let
|
41
|
-
|
38
|
+
formatMessage: r
|
39
|
+
} = at(), [l, c] = B(!1), i = L === I.ERROR, [M, u] = B(i), N = rt(), v = L === I.SUCCESS, E = L === I.IN_PROGRESS, O = r(s.selectAgent), F = r(s.defaultAgent);
|
40
|
+
let p = "";
|
41
|
+
v ? p = (o == null ? void 0 : o.name) || O : i && (p = F);
|
42
42
|
const G = tt(null), {
|
43
|
-
Wrapper:
|
44
|
-
wrapperProps:
|
43
|
+
Wrapper: j,
|
44
|
+
wrapperProps: A
|
45
45
|
} = z({
|
46
46
|
ref: G,
|
47
|
-
textValue:
|
47
|
+
textValue: p
|
48
48
|
});
|
49
49
|
et(() => {
|
50
50
|
l && n && n({
|
51
|
-
...
|
52
|
-
action:
|
53
|
-
target:
|
51
|
+
...y,
|
52
|
+
action: S,
|
53
|
+
target: T.OPEN_SELECTOR
|
54
54
|
});
|
55
55
|
}, [l, n]);
|
56
|
-
const h = _((
|
56
|
+
const h = _((t) => {
|
57
57
|
c(!1), N({
|
58
58
|
type: ot.SET_SELECTED_AGENT,
|
59
|
-
id:
|
59
|
+
id: t.id
|
60
60
|
}), n && n({
|
61
|
-
...
|
62
|
-
action:
|
63
|
-
target:
|
61
|
+
...y,
|
62
|
+
action: S,
|
63
|
+
target: T.SELECT_AGENT
|
64
64
|
});
|
65
65
|
}, [N, n]), U = _(() => {
|
66
66
|
c(!1), b(), n && n({
|
67
|
-
...
|
68
|
-
action:
|
69
|
-
target:
|
67
|
+
...y,
|
68
|
+
action: S,
|
69
|
+
target: T.RETRY_LOADING_AGENTS
|
70
70
|
});
|
71
|
-
}, [b, n]), Q = _((
|
72
|
-
if (
|
73
|
-
const
|
74
|
-
if (
|
75
|
-
const W =
|
76
|
-
|
71
|
+
}, [b, n]), Q = _((t) => {
|
72
|
+
if (t.key === "Escape" && (c(!1), t.stopPropagation()), t.key === " ") {
|
73
|
+
const x = t.target;
|
74
|
+
if (x) {
|
75
|
+
const W = x.getAttribute("data-key"), w = f.find((Y) => Y.id === W);
|
76
|
+
w && h(w);
|
77
77
|
}
|
78
78
|
}
|
79
|
-
}, [f, h]), V = _((
|
80
|
-
return /* @__PURE__ */
|
81
|
-
className:
|
82
|
-
name:
|
79
|
+
}, [f, h]), V = _((t) => u(i && i && !l && t ? t : !1), [i, l]), C = K === "sidebar" && a.sidebar;
|
80
|
+
return /* @__PURE__ */ e(g.Group, {
|
81
|
+
className: m(a.agentSelector, k, C),
|
82
|
+
name: O,
|
83
83
|
type: "multiple",
|
84
|
-
children: /* @__PURE__ */
|
84
|
+
children: /* @__PURE__ */ R(d.Root, {
|
85
85
|
modal: !1,
|
86
86
|
onOpenChange: c,
|
87
87
|
open: l,
|
88
|
-
children: [/* @__PURE__ */
|
89
|
-
content:
|
88
|
+
children: [/* @__PURE__ */ e(H, {
|
89
|
+
content: r(s.errorTooltip),
|
90
90
|
onOpenChange: V,
|
91
|
-
open:
|
91
|
+
open: M,
|
92
92
|
side: "bottom",
|
93
93
|
variant: "error",
|
94
|
-
children: /* @__PURE__ */
|
95
|
-
disabled:
|
96
|
-
children: /* @__PURE__ */
|
94
|
+
children: /* @__PURE__ */ e(d.Trigger, {
|
95
|
+
disabled: D || E,
|
96
|
+
children: /* @__PURE__ */ R(g.TriggerChip, {
|
97
97
|
className: a.triggerChip,
|
98
98
|
value: "trigger-chip",
|
99
|
-
children: [/* @__PURE__ */
|
99
|
+
children: [/* @__PURE__ */ e(J, {
|
100
100
|
className: a.agentStatus,
|
101
101
|
colorIndex: 0,
|
102
|
-
text:
|
103
|
-
}), E && /* @__PURE__ */
|
104
|
-
"aria-label":
|
102
|
+
text: r(s.agent)
|
103
|
+
}), E && /* @__PURE__ */ e(X, {
|
104
|
+
"aria-label": r(s.loadingMessage),
|
105
105
|
className: a.agentLoader,
|
106
106
|
variant: "default"
|
107
|
-
}),
|
107
|
+
}), i && /* @__PURE__ */ e(q, {
|
108
108
|
className: a.agentError,
|
109
109
|
height: "1rem",
|
110
110
|
role: "presentation",
|
111
111
|
width: "1rem"
|
112
|
-
}), /* @__PURE__ */
|
113
|
-
...
|
114
|
-
children: /* @__PURE__ */
|
112
|
+
}), /* @__PURE__ */ e(j, {
|
113
|
+
...A,
|
114
|
+
children: /* @__PURE__ */ e(g.Label, {
|
115
115
|
ref: G,
|
116
116
|
className: a.agentLabel,
|
117
|
-
children:
|
117
|
+
children: p
|
118
118
|
})
|
119
|
-
}), !E && /* @__PURE__ */
|
119
|
+
}), !E && /* @__PURE__ */ e("div", {
|
120
120
|
className: a.dropdownIndicator,
|
121
|
-
children: /* @__PURE__ */
|
121
|
+
children: /* @__PURE__ */ e(g.DropdownIndicator, {})
|
122
122
|
})]
|
123
123
|
})
|
124
124
|
})
|
125
|
-
}), /* @__PURE__ */
|
125
|
+
}), /* @__PURE__ */ e(d.ContentContainer, {
|
126
126
|
align: "start",
|
127
|
-
className:
|
127
|
+
className: m(a.agentListContainer, C),
|
128
128
|
onKeyDownCapture: Q,
|
129
|
-
children: /* @__PURE__ */
|
130
|
-
children: [
|
131
|
-
"aria-label":
|
132
|
-
className:
|
133
|
-
selectedKeys: [(
|
134
|
-
children: f.map((
|
135
|
-
agent:
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
129
|
+
children: /* @__PURE__ */ R(d.MainContent, {
|
130
|
+
children: [v && /* @__PURE__ */ e(Z, {
|
131
|
+
"aria-label": r(s.agentList),
|
132
|
+
className: m([a.agentList, P]),
|
133
|
+
selectedKeys: [(o == null ? void 0 : o.id) || ""],
|
134
|
+
children: f.map((t) => /* @__PURE__ */ e(nt, {
|
135
|
+
agent: t,
|
136
|
+
isSelected: (o == null ? void 0 : o.id) === t.id,
|
137
|
+
onAction: () => h(t)
|
138
|
+
}, t.id))
|
139
|
+
}), i && /* @__PURE__ */ e($, {
|
140
|
+
className: m(a.agentListRetryButton, C),
|
140
141
|
onClick: U,
|
141
142
|
variant: "tertiary",
|
142
|
-
children:
|
143
|
+
children: r(s.errorMessage)
|
143
144
|
})]
|
144
145
|
})
|
145
146
|
})]
|
@@ -147,6 +148,6 @@ function yt({
|
|
147
148
|
});
|
148
149
|
}
|
149
150
|
export {
|
150
|
-
|
151
|
-
|
151
|
+
Ot as BoxAiAgentSelector,
|
152
|
+
Ot as default
|
152
153
|
};
|
package/esm/lib/box-ai-agent.js
CHANGED
@@ -1,69 +1,85 @@
|
|
1
|
-
import { useFullTextTooltip as
|
2
|
-
import { BoxAiLogo as
|
3
|
-
import {
|
4
|
-
import {
|
5
|
-
import {
|
6
|
-
import
|
7
|
-
import
|
8
|
-
import
|
1
|
+
import { useFullTextTooltip as u, SmallList as r, Text as d, Status as f } from "@box/blueprint-web";
|
2
|
+
import { BoxAiLogo as h } from "@box/blueprint-web-assets/icons/Logo";
|
3
|
+
import { Checkmark as _ } from "@box/blueprint-web-assets/icons/Line";
|
4
|
+
import { SurfaceStatusSurfaceGray as I } from "@box/blueprint-web-assets/tokens/tokens";
|
5
|
+
import { useRef as k } from "react";
|
6
|
+
import { useIntl as g } from "react-intl";
|
7
|
+
import A from "./messages.js";
|
8
|
+
import { jsxs as c, jsx as t, Fragment as N } from "react/jsx-runtime";
|
9
|
+
import '../../styles/box-ai-agent.css';const S = "_agentListItem_szp3n_1", W = "_thumbnailWrapper_szp3n_6", L = "_checkMarkIconWrapper_szp3n_9", b = "_checkMarkIcon_szp3n_9", x = "_agentListItemIcon_szp3n_22", M = "_defaultAgentHeader_szp3n_31", z = "_defaultAgentName_szp3n_35", v = "_defaultAgentStatusWrapper_szp3n_41", a = {
|
9
10
|
agentListItem: S,
|
11
|
+
thumbnailWrapper: W,
|
12
|
+
checkMarkIconWrapper: L,
|
13
|
+
checkMarkIcon: b,
|
10
14
|
agentListItemIcon: x,
|
11
|
-
defaultAgentHeader:
|
12
|
-
defaultAgentName:
|
13
|
-
|
15
|
+
defaultAgentHeader: M,
|
16
|
+
defaultAgentName: z,
|
17
|
+
defaultAgentStatusWrapper: v
|
14
18
|
};
|
15
|
-
function
|
19
|
+
function C({
|
16
20
|
agent: e,
|
17
|
-
|
21
|
+
isSelected: l,
|
22
|
+
onAction: o
|
18
23
|
}) {
|
19
24
|
const {
|
20
|
-
formatMessage:
|
21
|
-
} =
|
22
|
-
Wrapper:
|
23
|
-
wrapperProps:
|
24
|
-
} =
|
25
|
-
ref:
|
25
|
+
formatMessage: i
|
26
|
+
} = g(), s = e.isEnterpriseDefault, n = k(null), {
|
27
|
+
Wrapper: m,
|
28
|
+
wrapperProps: p
|
29
|
+
} = u({
|
30
|
+
ref: n,
|
26
31
|
textValue: e.name,
|
27
|
-
skipOverflowCheck: !
|
32
|
+
skipOverflowCheck: !s
|
28
33
|
});
|
29
|
-
return /* @__PURE__ */
|
34
|
+
return /* @__PURE__ */ c(r.Item, {
|
30
35
|
className: a.agentListItem,
|
31
36
|
id: e.id,
|
32
|
-
onAction:
|
33
|
-
children: [/* @__PURE__ */
|
34
|
-
className: a.
|
35
|
-
children:
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
})
|
41
|
-
|
42
|
-
|
37
|
+
onAction: o,
|
38
|
+
children: [/* @__PURE__ */ c(r.Thumbnail, {
|
39
|
+
className: a.thumbnailWrapper,
|
40
|
+
children: [/* @__PURE__ */ t("div", {
|
41
|
+
className: a.checkMarkIconWrapper,
|
42
|
+
children: l && /* @__PURE__ */ t(_, {
|
43
|
+
className: a.checkMarkIcon
|
44
|
+
})
|
45
|
+
}), /* @__PURE__ */ t("div", {
|
46
|
+
className: a.agentListItemIcon,
|
47
|
+
children: e.imageURL ? /* @__PURE__ */ t("img", {
|
48
|
+
"aria-label": e.name,
|
49
|
+
src: e.imageURL
|
50
|
+
}) : /* @__PURE__ */ t(h, {
|
51
|
+
"aria-label": e.name
|
52
|
+
})
|
53
|
+
})]
|
54
|
+
}), /* @__PURE__ */ t(r.Header, {
|
55
|
+
className: s ? a.defaultAgentHeader : void 0,
|
43
56
|
textValue: e.name,
|
44
|
-
children:
|
45
|
-
children:
|
46
|
-
...
|
57
|
+
children: s ? /* @__PURE__ */ t(N, {
|
58
|
+
children: /* @__PURE__ */ t(m, {
|
59
|
+
...p,
|
47
60
|
children: /* @__PURE__ */ t(d, {
|
48
|
-
ref:
|
61
|
+
ref: n,
|
49
62
|
as: "span",
|
50
63
|
className: a.defaultAgentName,
|
51
64
|
variant: "bodyDefaultSemibold",
|
52
65
|
children: e.name
|
53
66
|
})
|
54
|
-
})
|
55
|
-
className: a.defaultAgentStatus,
|
56
|
-
color: g,
|
57
|
-
text: m(I.defaultStatus)
|
58
|
-
})]
|
67
|
+
})
|
59
68
|
}) : e.name
|
60
|
-
}),
|
69
|
+
}), /* @__PURE__ */ t(r.Actions, {
|
70
|
+
className: a.defaultAgentStatusWrapper,
|
71
|
+
children: s && /* @__PURE__ */ t(f, {
|
72
|
+
className: a.defaultAgentStatus,
|
73
|
+
color: I,
|
74
|
+
text: i(A.defaultStatus)
|
75
|
+
})
|
76
|
+
}), e.description && /* @__PURE__ */ t(r.Subtitle, {
|
61
77
|
className: a.agentDescription,
|
62
78
|
children: e.description
|
63
79
|
})]
|
64
80
|
});
|
65
81
|
}
|
66
82
|
export {
|
67
|
-
|
68
|
-
|
83
|
+
C as BoxAiAgent,
|
84
|
+
C as default
|
69
85
|
};
|
package/i18n/en-x-pseudo.js
CHANGED
@@ -1,10 +1,10 @@
|
|
1
1
|
export default {
|
2
|
-
"boxAI.agentSelector.agent": "⟦萬
|
3
|
-
"boxAI.agentSelector.agentList": "⟦萬萬
|
4
|
-
"boxAI.agentSelector.defaultAgent": "⟦萬萬
|
5
|
-
"boxAI.agentSelector.defaultStatus": "⟦萬萬
|
6
|
-
"boxAI.agentSelector.errorMessage": "⟦萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬
|
7
|
-
"boxAI.agentSelector.errorTooltip": "⟦萬萬萬萬萬萬萬萬萬
|
8
|
-
"boxAI.agentSelector.loadingMessage": "⟦萬萬萬萬萬萬萬
|
9
|
-
"boxAI.agentSelector.selectAgent": "⟦萬萬萬萬
|
2
|
+
"boxAI.agentSelector.agent": "⟦萬 Άĝеņŧ 國⟧",
|
3
|
+
"boxAI.agentSelector.agentList": "⟦萬萬 Ăğèňţ Ļίŝţ 國國⟧",
|
4
|
+
"boxAI.agentSelector.defaultAgent": "⟦萬萬 Ðěƒάūļť 國國⟧",
|
5
|
+
"boxAI.agentSelector.defaultStatus": "⟦萬萬 ĎĘ₣ÅÚĻΤ 國國⟧",
|
6
|
+
"boxAI.agentSelector.errorMessage": "⟦萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬 ₣áίľêď τσ ļŏâď āνăіļáьļё åğĕлτş. Ŷσù'ґè ¢ùяѓēŋŧļý µŝīńĝ ỳõŭř οяĝâήϊżăŧïōń'ş ďêƒáùļť άğéήτ. Ćĺĭ¢ĸ ħëŗë ťŏ ŕεŧѓỳ. 國國國國國國國國國國國國國國國國國國國國國國國國國國國國國國國國國⟧",
|
7
|
+
"boxAI.agentSelector.errorTooltip": "⟦萬萬萬萬萬萬萬萬萬 ₣àĩļεď ţö ĺοáď ανάίĺāьĺé ąĝёлťş 國國國國國國國國國⟧",
|
8
|
+
"boxAI.agentSelector.loadingMessage": "⟦萬萬萬萬萬萬萬 Ŀòάďїйğ äνåιľăьĺε åğέπŧŝ 國國國國國國國⟧",
|
9
|
+
"boxAI.agentSelector.selectAgent": "⟦萬萬萬萬 Ŝėľę¢τ άʼn Ąğелť 國國國國⟧"
|
10
10
|
}
|
@@ -1,16 +1,16 @@
|
|
1
1
|
# AI agent label
|
2
|
-
boxAI.agentSelector.agent = ⟦萬
|
2
|
+
boxAI.agentSelector.agent = ⟦萬 Άĝеņŧ 國⟧
|
3
3
|
# Aria Label for the list displaying the agents
|
4
|
-
boxAI.agentSelector.agentList = ⟦萬萬
|
4
|
+
boxAI.agentSelector.agentList = ⟦萬萬 Ăğèňţ Ļίŝţ 國國⟧
|
5
5
|
# Label for the default agent used when no other agents are available
|
6
|
-
boxAI.agentSelector.defaultAgent = ⟦萬萬
|
6
|
+
boxAI.agentSelector.defaultAgent = ⟦萬萬 Ðěƒάūļť 國國⟧
|
7
7
|
# Status indicator to define whether or not the agent on the list is the default for the enterprise
|
8
|
-
boxAI.agentSelector.defaultStatus = ⟦萬萬
|
8
|
+
boxAI.agentSelector.defaultStatus = ⟦萬萬 ĎĘ₣ÅÚĻΤ 國國⟧
|
9
9
|
# Error message for retry option when the agents failed to load
|
10
|
-
boxAI.agentSelector.errorMessage = ⟦萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬
|
10
|
+
boxAI.agentSelector.errorMessage = ⟦萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬萬 ₣áίľêď τσ ļŏâď āνăіļáьļё åğĕлτş. Ŷσù'ґè ¢ùяѓēŋŧļý µŝīńĝ ỳõŭř οяĝâήϊżăŧïōń'ş ďêƒáùļť άğéήτ. Ćĺĭ¢ĸ ħëŗë ťŏ ŕεŧѓỳ. 國國國國國國國國國國國國國國國國國國國國國國國國國國國國國國國國國⟧
|
11
11
|
# Error tooltip content for agent selector when the agents failed to load
|
12
|
-
boxAI.agentSelector.errorTooltip = ⟦萬萬萬萬萬萬萬萬萬
|
12
|
+
boxAI.agentSelector.errorTooltip = ⟦萬萬萬萬萬萬萬萬萬 ₣àĩļεď ţö ĺοáď ανάίĺāьĺé ąĝёлťş 國國國國國國國國國⟧
|
13
13
|
# Message for loading indicator while loading available agents
|
14
|
-
boxAI.agentSelector.loadingMessage = ⟦萬萬萬萬萬萬萬
|
14
|
+
boxAI.agentSelector.loadingMessage = ⟦萬萬萬萬萬萬萬 Ŀòάďїйğ äνåιľăьĺε åğέπŧŝ 國國國國國國國⟧
|
15
15
|
# Label for the AI agent selector when the user has not selected any agent
|
16
|
-
boxAI.agentSelector.selectAgent = ⟦萬萬萬萬
|
16
|
+
boxAI.agentSelector.selectAgent = ⟦萬萬萬萬 Ŝėľę¢τ άʼn Ąğелť 國國國國⟧
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@box/box-ai-agent-selector",
|
3
|
-
"version": "0.
|
3
|
+
"version": "0.25.0",
|
4
4
|
"license": "SEE LICENSE IN LICENSE",
|
5
5
|
"peerDependencies": {
|
6
6
|
"@box/blueprint-web": "^7.31.1",
|
@@ -46,5 +46,5 @@
|
|
46
46
|
"sideEffects": [
|
47
47
|
"**/*.css"
|
48
48
|
],
|
49
|
-
"gitHead": "
|
49
|
+
"gitHead": "58fabc68edaabf373556e0c8ca656ffcbbd6ac5d"
|
50
50
|
}
|
@@ -1 +1 @@
|
|
1
|
-
.
|
1
|
+
._agentSelector_1y96v_1{margin-inline-start:.75rem}._agentSelector_1y96v_1 ._agentStatus_1y96v_4{margin-inline-start:.5rem}._agentSelector_1y96v_1 ._agentStatus_1y96v_4>span{background:linear-gradient(#f4f4f4 0,#f4f4f4 0) padding-box,linear-gradient(135deg,#fe01da,#2486fc) border-box;border:.0625rem solid rgba(0,0,0,0)}._agentSelector_1y96v_1 ._agentStatus_1y96v_4>span span{color:transparent;text-transform:uppercase;background:linear-gradient(135deg,#fe01da,#2486fc);-webkit-background-clip:text;background-clip:text}._agentSelector_1y96v_1 ._agentLoader_1y96v_18{position:inherit}._agentSelector_1y96v_1 ._agentError_1y96v_21 path{fill:#d5324e}._agentSelector_1y96v_1 ._triggerChip_1y96v_24{display:flex;max-width:376px;text-align:start;background-color:#faf5fe}._agentSelector_1y96v_1 ._triggerChip_1y96v_24 ._agentLabel_1y96v_30{flex-grow:1;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}._agentSelector_1y96v_1 ._triggerChip_1y96v_24 ._dropdownIndicator_1y96v_36{flex-shrink:0;margin-inline-start:0}._agentSelector_1y96v_1 ._triggerChip_1y96v_24 ._dropdownIndicator_1y96v_36 svg{margin-inline-start:0}._agentSelector_1y96v_1 ._triggerChip_1y96v_24:disabled ._dropdownIndicator_1y96v_36{opacity:.3}@media (max-width: 374px){._agentSelector_1y96v_1 ._triggerChip_1y96v_24{width:100%}}._agentSelector_1y96v_1._sidebar_1y96v_51{margin:0 .25rem 0 0;margin-inline-start:0}@media (max-width: 767px){._agentSelector_1y96v_1._sidebar_1y96v_51{width:100%}}._agentSelector_1y96v_1._sidebar_1y96v_51 ._triggerChip_1y96v_24{width:246px}@media (max-width: 767px){._agentSelector_1y96v_1._sidebar_1y96v_51 ._triggerChip_1y96v_24{width:100%;max-width:100%}}._agentListItemIcon_1y96v_70{width:2rem;height:2rem}._agentListContainer_1y96v_75{min-width:320px;max-width:376px;width:360px}@media (max-width: 376px){._agentListContainer_1y96v_75{max-width:320px}}._agentListContainer_1y96v_75>div{padding:var(--space-3)}._agentListContainer_1y96v_75._sidebar_1y96v_51{min-width:320px;max-width:360px;transform:translate(-6px)}@media (max-width: 360px){._agentListContainer_1y96v_75._sidebar_1y96v_51{max-width:320px}}@media (max-width: 767px){._agentListContainer_1y96v_75._sidebar_1y96v_51{max-width:unset;width:auto}}._agentListRetryButton_1y96v_105{max-width:320px;margin:.25rem;text-wrap:wrap}._agentListRetryButton_1y96v_105._sidebar_1y96v_51{max-width:184px}
|
package/styles/box-ai-agent.css
CHANGED
@@ -1 +1 @@
|
|
1
|
-
.
|
1
|
+
._agentListItem_szp3n_1{align-items:center;grid-template-columns:48px auto auto!important;column-gap:var(--space-4)!important}._agentListItem_szp3n_1 ._thumbnailWrapper_szp3n_6{aspect-ratio:auto!important}._agentListItem_szp3n_1 ._thumbnailWrapper_szp3n_6 ._checkMarkIconWrapper_szp3n_9{height:1rem;width:1rem;margin-right:1rem}._agentListItem_szp3n_1 ._thumbnailWrapper_szp3n_6 ._checkMarkIconWrapper_szp3n_9 ._checkMarkIcon_szp3n_9{height:1rem;width:1rem}._agentListItem_szp3n_1 ._thumbnailWrapper_szp3n_6 ._checkMarkIconWrapper_szp3n_9 ._checkMarkIcon_szp3n_9 svg{height:100%;width:100%}._agentListItem_szp3n_1 ._thumbnailWrapper_szp3n_6 ._agentListItemIcon_szp3n_22{height:1rem;width:1rem}._agentListItem_szp3n_1 ._thumbnailWrapper_szp3n_6 ._agentListItemIcon_szp3n_22 svg,._agentListItem_szp3n_1 ._thumbnailWrapper_szp3n_6 ._agentListItemIcon_szp3n_22 img{vertical-align:top;height:100%;width:100%}._agentListItem_szp3n_1 ._defaultAgentHeader_szp3n_31{display:flex!important;align-items:center}._agentListItem_szp3n_1 ._defaultAgentName_szp3n_35{flex-grow:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}._agentListItem_szp3n_1 ._defaultAgentStatusWrapper_szp3n_41{--default-opacity: 1;opacity:var(--default-opacity)!important}._agentListItem_szp3n_1 ._defaultAgentStatusWrapper_szp3n_41>div{background:transparent!important}
|
@@ -4,10 +4,14 @@ export interface BoxAiAgentProps {
|
|
4
4
|
* Object representation of agent.
|
5
5
|
*/
|
6
6
|
agent: AgentType;
|
7
|
+
/**
|
8
|
+
* Flag that the agent is selected
|
9
|
+
*/
|
10
|
+
isSelected: boolean;
|
7
11
|
/**
|
8
12
|
* Callback function triggered when an agent is selected
|
9
13
|
*/
|
10
14
|
onAction: () => void;
|
11
15
|
}
|
12
|
-
export declare function BoxAiAgent({ agent, onAction }: BoxAiAgentProps): import("react/jsx-runtime").JSX.Element;
|
16
|
+
export declare function BoxAiAgent({ agent, isSelected, onAction }: BoxAiAgentProps): import("react/jsx-runtime").JSX.Element;
|
13
17
|
export default BoxAiAgent;
|