@bikdotai/bik-component-library 0.0.866 → 0.0.867

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.
Files changed (137) hide show
  1. package/dist/cjs/components/agent-builder/AgentBuilder.js +1 -1
  2. package/dist/cjs/components/agent-builder/AgentBuilder.js.map +1 -1
  3. package/dist/cjs/components/agent-builder/AgentBuilder.styled.js +151 -29
  4. package/dist/cjs/components/agent-builder/AgentBuilder.styled.js.map +1 -1
  5. package/dist/cjs/components/agent-builder/components/ChannelSelectModal.js +2 -0
  6. package/dist/cjs/components/agent-builder/components/ChannelSelectModal.js.map +1 -0
  7. package/dist/cjs/components/agent-builder/components/ChannelsSection.js +2 -0
  8. package/dist/cjs/components/agent-builder/components/ChannelsSection.js.map +1 -0
  9. package/dist/cjs/components/agent-builder/components/CreateSubAgentPanel.js +5 -5
  10. package/dist/cjs/components/agent-builder/components/CreateSubAgentPanel.js.map +1 -1
  11. package/dist/cjs/components/agent-builder/components/GoLiveModal.js +1 -1
  12. package/dist/cjs/components/agent-builder/components/GoLiveModal.js.map +1 -1
  13. package/dist/cjs/components/agent-builder/components/MentionEditor.js +2 -2
  14. package/dist/cjs/components/agent-builder/components/MentionEditor.js.map +1 -1
  15. package/dist/cjs/components/agent-builder/components/MentionField.js +1 -1
  16. package/dist/cjs/components/agent-builder/components/MentionField.js.map +1 -1
  17. package/dist/cjs/components/agent-builder/components/MentionPicker.js +13 -13
  18. package/dist/cjs/components/agent-builder/components/MentionPicker.js.map +1 -1
  19. package/dist/cjs/components/agent-builder/components/SelectableListSection.js +3 -3
  20. package/dist/cjs/components/agent-builder/components/SelectableListSection.js.map +1 -1
  21. package/dist/cjs/components/agent-builder/constants/channels.js +2 -0
  22. package/dist/cjs/components/agent-builder/constants/channels.js.map +1 -0
  23. package/dist/cjs/components/agent-builder/constants/steps.js +1 -1
  24. package/dist/cjs/components/agent-builder/constants/steps.js.map +1 -1
  25. package/dist/cjs/components/agent-builder/context/AgentBuilderContext.js +1 -1
  26. package/dist/cjs/components/agent-builder/context/AgentBuilderContext.js.map +1 -1
  27. package/dist/cjs/components/agent-builder/steps/Step1About.js +1 -1
  28. package/dist/cjs/components/agent-builder/steps/Step1About.js.map +1 -1
  29. package/dist/cjs/components/agent-builder/steps/Step2WhenItStepsIn.js +2 -2
  30. package/dist/cjs/components/agent-builder/steps/Step2WhenItStepsIn.js.map +1 -1
  31. package/dist/cjs/components/agent-builder/steps/Step3HowItResponds.js +1 -1
  32. package/dist/cjs/components/agent-builder/steps/Step3HowItResponds.js.map +1 -1
  33. package/dist/cjs/components/agent-builder/steps/Step4HandoverRules.js +1 -1
  34. package/dist/cjs/components/agent-builder/steps/Step4HandoverRules.js.map +1 -1
  35. package/dist/cjs/components/agent-builder/utils/mentionSerialization.js +2 -2
  36. package/dist/cjs/components/agent-builder/utils/mentionSerialization.js.map +1 -1
  37. package/dist/cjs/components/agent-builder/utils/sourceIcons.js +1 -1
  38. package/dist/cjs/components/agent-builder/utils/sourceIcons.js.map +1 -1
  39. package/dist/cjs/icons/Social/Channels/ManifestGlass.js +2 -0
  40. package/dist/cjs/icons/Social/Channels/ManifestGlass.js.map +1 -0
  41. package/dist/cjs/icons/Social/Channels/ShipStation.js +2 -0
  42. package/dist/cjs/icons/Social/Channels/ShipStation.js.map +1 -0
  43. package/dist/cjs/icons/Social/Channels/Skio.js +2 -0
  44. package/dist/cjs/icons/Social/Channels/Skio.js.map +1 -0
  45. package/dist/cjs/icons/index.js +1 -1
  46. package/dist/cjs/index.js +1 -1
  47. package/dist/esm/components/agent-builder/AgentBuilder.js +103 -97
  48. package/dist/esm/components/agent-builder/AgentBuilder.js.map +1 -1
  49. package/dist/esm/components/agent-builder/AgentBuilder.model.d.ts +76 -0
  50. package/dist/esm/components/agent-builder/AgentBuilder.styled.d.ts +68 -0
  51. package/dist/esm/components/agent-builder/AgentBuilder.styled.js +224 -59
  52. package/dist/esm/components/agent-builder/AgentBuilder.styled.js.map +1 -1
  53. package/dist/esm/components/agent-builder/components/ChannelSelectModal.d.ts +26 -0
  54. package/dist/esm/components/agent-builder/components/ChannelSelectModal.js +121 -0
  55. package/dist/esm/components/agent-builder/components/ChannelSelectModal.js.map +1 -0
  56. package/dist/esm/components/agent-builder/components/ChannelsSection.d.ts +10 -0
  57. package/dist/esm/components/agent-builder/components/ChannelsSection.js +183 -0
  58. package/dist/esm/components/agent-builder/components/ChannelsSection.js.map +1 -0
  59. package/dist/esm/components/agent-builder/components/CreateSubAgentPanel.js +135 -132
  60. package/dist/esm/components/agent-builder/components/CreateSubAgentPanel.js.map +1 -1
  61. package/dist/esm/components/agent-builder/components/GoLiveModal.js +12 -12
  62. package/dist/esm/components/agent-builder/components/GoLiveModal.js.map +1 -1
  63. package/dist/esm/components/agent-builder/components/MentionEditor.d.ts +2 -0
  64. package/dist/esm/components/agent-builder/components/MentionEditor.js +47 -45
  65. package/dist/esm/components/agent-builder/components/MentionEditor.js.map +1 -1
  66. package/dist/esm/components/agent-builder/components/MentionField.js +52 -51
  67. package/dist/esm/components/agent-builder/components/MentionField.js.map +1 -1
  68. package/dist/esm/components/agent-builder/components/MentionPicker.d.ts +5 -0
  69. package/dist/esm/components/agent-builder/components/MentionPicker.js +134 -132
  70. package/dist/esm/components/agent-builder/components/MentionPicker.js.map +1 -1
  71. package/dist/esm/components/agent-builder/components/SelectableListSection.d.ts +2 -0
  72. package/dist/esm/components/agent-builder/components/SelectableListSection.js +48 -46
  73. package/dist/esm/components/agent-builder/components/SelectableListSection.js.map +1 -1
  74. package/dist/esm/components/agent-builder/constants/channels.d.ts +56 -0
  75. package/dist/esm/components/agent-builder/constants/channels.js +41 -0
  76. package/dist/esm/components/agent-builder/constants/channels.js.map +1 -0
  77. package/dist/esm/components/agent-builder/constants/steps.d.ts +31 -1
  78. package/dist/esm/components/agent-builder/constants/steps.js +15 -6
  79. package/dist/esm/components/agent-builder/constants/steps.js.map +1 -1
  80. package/dist/esm/components/agent-builder/context/AgentBuilderContext.d.ts +13 -1
  81. package/dist/esm/components/agent-builder/context/AgentBuilderContext.js +157 -148
  82. package/dist/esm/components/agent-builder/context/AgentBuilderContext.js.map +1 -1
  83. package/dist/esm/components/agent-builder/index.d.ts +5 -2
  84. package/dist/esm/components/agent-builder/steps/Step1About.js +15 -13
  85. package/dist/esm/components/agent-builder/steps/Step1About.js.map +1 -1
  86. package/dist/esm/components/agent-builder/steps/Step2WhenItStepsIn.js +55 -48
  87. package/dist/esm/components/agent-builder/steps/Step2WhenItStepsIn.js.map +1 -1
  88. package/dist/esm/components/agent-builder/steps/Step3HowItResponds.js +158 -157
  89. package/dist/esm/components/agent-builder/steps/Step3HowItResponds.js.map +1 -1
  90. package/dist/esm/components/agent-builder/steps/Step4HandoverRules.d.ts +11 -0
  91. package/dist/esm/components/agent-builder/steps/Step4HandoverRules.js +127 -23
  92. package/dist/esm/components/agent-builder/steps/Step4HandoverRules.js.map +1 -1
  93. package/dist/esm/components/agent-builder/utils/mentionSerialization.d.ts +10 -3
  94. package/dist/esm/components/agent-builder/utils/mentionSerialization.js +31 -23
  95. package/dist/esm/components/agent-builder/utils/mentionSerialization.js.map +1 -1
  96. package/dist/esm/components/agent-builder/utils/sourceIcons.d.ts +7 -5
  97. package/dist/esm/components/agent-builder/utils/sourceIcons.js +26 -26
  98. package/dist/esm/components/agent-builder/utils/sourceIcons.js.map +1 -1
  99. package/dist/esm/icons/Social/Channels/ManifestGlass.d.ts +6 -0
  100. package/dist/esm/icons/Social/Channels/ManifestGlass.js +252 -0
  101. package/dist/esm/icons/Social/Channels/ManifestGlass.js.map +1 -0
  102. package/dist/esm/icons/Social/Channels/ShipStation.d.ts +6 -0
  103. package/dist/esm/icons/Social/Channels/ShipStation.js +31 -0
  104. package/dist/esm/icons/Social/Channels/ShipStation.js.map +1 -0
  105. package/dist/esm/icons/Social/Channels/Skio.d.ts +6 -0
  106. package/dist/{cjs/assets/icons/Skio.svg.js → esm/icons/Social/Channels/Skio.js} +31 -2
  107. package/dist/esm/icons/Social/Channels/Skio.js.map +1 -0
  108. package/dist/esm/icons/Social/Channels/index.d.ts +3 -0
  109. package/dist/esm/icons/index.d.ts +25 -25
  110. package/dist/esm/icons/index.js +330 -324
  111. package/dist/esm/icons/index.js.map +1 -1
  112. package/dist/esm/index.js +671 -663
  113. package/dist/esm/index.js.map +1 -1
  114. package/package.json +1 -1
  115. package/dist/cjs/assets/icons/BigCommerce.svg.js +0 -2
  116. package/dist/cjs/assets/icons/BigCommerce.svg.js.map +0 -1
  117. package/dist/cjs/assets/icons/Gorgias.svg.js +0 -2
  118. package/dist/cjs/assets/icons/Gorgias.svg.js.map +0 -1
  119. package/dist/cjs/assets/icons/ManifestGlass.svg.js +0 -2
  120. package/dist/cjs/assets/icons/ManifestGlass.svg.js.map +0 -1
  121. package/dist/cjs/assets/icons/ShipStation.svg.js +0 -2
  122. package/dist/cjs/assets/icons/ShipStation.svg.js.map +0 -1
  123. package/dist/cjs/assets/icons/Shopify.svg.js +0 -2
  124. package/dist/cjs/assets/icons/Shopify.svg.js.map +0 -1
  125. package/dist/cjs/assets/icons/Skio.svg.js.map +0 -1
  126. package/dist/esm/assets/icons/BigCommerce.svg.js +0 -6
  127. package/dist/esm/assets/icons/BigCommerce.svg.js.map +0 -1
  128. package/dist/esm/assets/icons/Gorgias.svg.js +0 -6
  129. package/dist/esm/assets/icons/Gorgias.svg.js.map +0 -1
  130. package/dist/esm/assets/icons/ManifestGlass.svg.js +0 -6
  131. package/dist/esm/assets/icons/ManifestGlass.svg.js.map +0 -1
  132. package/dist/esm/assets/icons/ShipStation.svg.js +0 -6
  133. package/dist/esm/assets/icons/ShipStation.svg.js.map +0 -1
  134. package/dist/esm/assets/icons/Shopify.svg.js +0 -6
  135. package/dist/esm/assets/icons/Shopify.svg.js.map +0 -1
  136. package/dist/esm/assets/icons/Skio.svg.js +0 -6
  137. package/dist/esm/assets/icons/Skio.svg.js.map +0 -1
@@ -1,111 +1,112 @@
1
- import { jsxs as x, jsx as c, Fragment as ae } from "react/jsx-runtime";
2
- import ce from "../../../assets/icons/chevronRight.svg.js";
3
- import se from "../../../assets/icons/searchIcon.svg.js";
4
- import de from "../../../icons/Arrows/Normal arrows/ArrowLeft.js";
5
- import { useState as M, useMemo as I, useEffect as V, useRef as ue } from "react";
1
+ import { jsxs as x, jsx as c, Fragment as ce } from "react/jsx-runtime";
2
+ import se from "../../../assets/icons/chevronRight.svg.js";
3
+ import de from "../../../assets/icons/searchIcon.svg.js";
4
+ import ue from "../../../icons/Arrows/Normal arrows/ArrowLeft.js";
5
+ import { useState as z, useMemo as I, useEffect as j, useRef as he } from "react";
6
6
  import u from "styled-components";
7
- import { TitleSmall as he, BodySecondary as pe, BodyCaption as fe } from "../../TypographyStyle.js";
7
+ import { TitleSmall as pe, BodySecondary as fe, BodyCaption as ge } from "../../TypographyStyle.js";
8
8
  import { COLORS as o } from "../../../constants/Theme.js";
9
- import { PickerType as ge } from "../../variable-picker-v3/model.js";
10
- import { CATEGORIES as be, MORE_INTEGRATIONS_KEY as v, isMoreIntegrationSource as z, toolSourceRank as j, MORE_INTEGRATIONS_LABEL as ee, isIntegrationSource as me, CONFIG_TOOL_SOURCES as ke, MORE_INTEGRATIONS_RANK as xe } from "../constants/tools.js";
11
- import { toolSourceLabel as Y } from "../utils/mentionSerialization.js";
12
- import { renderSourceIcon as te, sourceIcon as q } from "../utils/sourceIcons.js";
13
- import ve from "../../../icons/Informational/Identity/PuzzlePiece.js";
14
- import { VariablePicker as we } from "../../variable-picker-v3/VariablePicker.js";
15
- import re from "../../../icons/Informational/Common UI/Shield.js";
16
- const ne = {
17
- Icon: ve,
9
+ import { PickerType as be } from "../../variable-picker-v3/model.js";
10
+ import { CATEGORIES as me, MORE_INTEGRATIONS_KEY as v, isMoreIntegrationSource as q, toolSourceRank as Y, MORE_INTEGRATIONS_LABEL as te, isIntegrationSource as ke, CONFIG_TOOL_SOURCES as xe, MORE_INTEGRATIONS_RANK as ve } from "../constants/tools.js";
11
+ import { toolSourceLabel as H } from "../utils/mentionSerialization.js";
12
+ import { renderSourceIcon as re, sourceIcon as D } from "../utils/sourceIcons.js";
13
+ import we from "../../../icons/Informational/Identity/PuzzlePiece.js";
14
+ import { VariablePicker as ye } from "../../variable-picker-v3/VariablePicker.js";
15
+ import ne from "../../../icons/Informational/Common UI/Shield.js";
16
+ const oe = {
17
+ Icon: we,
18
18
  w: 20,
19
19
  h: 20
20
- }, b = (s) => s.meta, A = (s) => b(s)?.plainLabel ?? s.label, ye = "__bik_create_subagent__", Xe = ({
20
+ }, b = (s) => s.meta, A = (s) => b(s)?.plainLabel ?? s.label, Ie = "__bik_create_subagent__", Ze = ({
21
21
  items: s,
22
- onSelect: L,
23
- registerKeyHandler: C,
22
+ onSelect: C,
23
+ registerKeyHandler: $,
24
24
  onClose: w,
25
25
  onCreateSubAgent: R,
26
- initialSource: H,
26
+ initialSource: J,
27
27
  toolActions: y,
28
- integrationStatus: J,
29
- onConnectIntegration: K,
30
- variablesData: D,
31
- onSelectVariable: G
28
+ integrationStatus: K,
29
+ onConnectIntegration: Q,
30
+ appLabel: B,
31
+ variablesData: G,
32
+ onSelectVariable: F
32
33
  }) => {
33
- const [oe, $] = M(null), [i, S] = M(H ?? null), [B, m] = M(-1), [E, Q] = M(""), k = I(
34
+ const [ie, O] = z(null), [i, S] = z(J ?? null), [T, m] = z(-1), [E, W] = z(""), k = I(
34
35
  () => s.filter((e) => b(e)?.kind === "tool"),
35
36
  [s]
36
- ), O = I(
37
+ ), L = I(
37
38
  () => s.filter((e) => b(e)?.kind === "subagent"),
38
39
  [s]
39
- ), F = I(() => {
40
+ ), U = I(() => {
40
41
  const e = [];
41
42
  return k.forEach((n) => {
42
43
  const f = b(n)?.source ?? "other";
43
44
  e.includes(f) || e.push(f);
44
45
  }), e;
45
- }, [k]), U = I(
46
+ }, [k]), V = I(
46
47
  () => new Map(
47
48
  (y ?? []).map((e) => [e.source, e])
48
49
  ),
49
50
  [y]
50
- ), T = I(
51
- () => be.filter((e) => e.key === "tool" ? k.length > 0 || (y?.length ?? 0) > 0 : e.key === "variable" ? (D?.length ?? 0) > 0 && !!G : O.length > 0 || !!R),
51
+ ), _ = I(
52
+ () => me.filter((e) => e.key === "tool" ? k.length > 0 || (y?.length ?? 0) > 0 : e.key === "variable" ? (G?.length ?? 0) > 0 && !!F : L.length > 0 || !!R),
52
53
  [
53
54
  k.length,
54
- O.length,
55
+ L.length,
55
56
  R,
56
57
  y?.length,
57
- D?.length,
58
- G
58
+ G?.length,
59
+ F
59
60
  ]
60
- ), _ = T.length === 1 ? T[0].key : null, a = oe ?? _, h = a ? a === "subagent" ? (
61
+ ), P = _.length === 1 ? _[0].key : null, a = ie ?? P, h = a ? a === "subagent" ? (
61
62
  // Always titled — with a back arrow only when the category chooser is above.
62
63
  {
63
64
  title: "Sub-agent",
64
- onBack: _ ? void 0 : () => $(null)
65
+ onBack: P ? void 0 : () => O(null)
65
66
  }
66
67
  ) : a === "variable" ? {
67
68
  title: "Variables",
68
- onBack: _ ? void 0 : () => $(null)
69
+ onBack: P ? void 0 : () => O(null)
69
70
  } : i === v ? {
70
- title: ee,
71
+ title: te,
71
72
  onBack: () => S(null),
72
- icon: ne
73
+ icon: oe
73
74
  } : i ? {
74
- title: Y(i),
75
+ title: H(i, B),
75
76
  // Deep-linked to a source (opened from a right-panel source button):
76
77
  // that source IS the root, so no back arrow. Otherwise back returns to
77
78
  // the "More Integrations" umbrella for a vendor that lives under it,
78
79
  // else to the source chooser.
79
- onBack: H ? void 0 : () => S(
80
- z(i) ? v : null
80
+ onBack: J ? void 0 : () => S(
81
+ q(i) ? v : null
81
82
  ),
82
- icon: q(i)
83
+ icon: D(i)
83
84
  } : (
84
85
  // Always titled — matches the Sub-agent header; back arrow only when the
85
86
  // category chooser is above (i.e. not the sole category).
86
87
  {
87
88
  title: "Tools",
88
- onBack: _ ? void 0 : () => $(null)
89
+ onBack: P ? void 0 : () => O(null)
89
90
  }
90
91
  ) : null, d = I(() => {
91
92
  if (!a)
92
- return T.map((r) => ({
93
+ return _.map((r) => ({
93
94
  id: r.key,
94
95
  label: r.label,
95
96
  drillsIn: !0,
96
97
  onActivate: () => {
97
- $(r.key), S(null);
98
+ O(r.key), S(null);
98
99
  }
99
100
  }));
100
101
  if (a === "subagent") {
101
- const r = E.trim().toLowerCase(), p = O.filter((g) => !r || A(g).toLowerCase().includes(r)).map((g) => ({
102
+ const r = E.trim().toLowerCase(), p = L.filter((g) => !r || A(g).toLowerCase().includes(r)).map((g) => ({
102
103
  id: String(g.id),
103
104
  label: A(g),
104
105
  drillsIn: !1,
105
- onActivate: () => L(g)
106
+ onActivate: () => C(g)
106
107
  }));
107
108
  return R && p.push({
108
- id: ye,
109
+ id: Ie,
109
110
  label: "Create new",
110
111
  drillsIn: !1,
111
112
  isCreate: !0,
@@ -117,75 +118,75 @@ const ne = {
117
118
  if (a === "variable")
118
119
  return [];
119
120
  if (!i || i === v) {
120
- const r = (y ?? []).map((t) => t.source).filter((t) => !F.includes(t)), p = [...F, ...r], g = (t) => {
121
- const l = U.get(t);
122
- if ((l !== void 0 ? l.connected : J?.[t]) === !1)
121
+ const r = (y ?? []).map((t) => t.source).filter((t) => !U.includes(t)), p = [...U, ...r], g = (t) => {
122
+ const l = V.get(t);
123
+ if ((l !== void 0 ? l.connected : K?.[t]) === !1)
123
124
  return {
124
125
  id: t,
125
- label: Y(t),
126
+ label: H(t, B),
126
127
  drillsIn: !1,
127
- icon: q(t) ?? l?.icon,
128
+ icon: D(t) ?? l?.icon,
128
129
  rightLabel: "Connect",
129
130
  onActivate: () => {
130
- w?.(), l?.onConnect ? l.onConnect() : K?.(t);
131
+ w?.(), l?.onConnect ? l.onConnect() : Q?.(t);
131
132
  }
132
133
  };
133
- const Z = k.filter(
134
- (P) => (b(P)?.source ?? "other") === t
134
+ const ee = k.filter(
135
+ (N) => (b(N)?.source ?? "other") === t
135
136
  );
136
- if (Z.length + (l ? 1 : 0) === 1 && !(l === void 0 && me(t))) {
137
- const P = q(t) ?? l?.icon;
137
+ if (ee.length + (l ? 1 : 0) === 1 && !(l === void 0 && ke(t))) {
138
+ const N = D(t) ?? l?.icon;
138
139
  if (l)
139
140
  return {
140
141
  id: t,
141
142
  label: l.label,
142
143
  drillsIn: !1,
143
- icon: P,
144
+ icon: N,
144
145
  onActivate: () => {
145
146
  w?.(), l.onSelect();
146
147
  }
147
148
  };
148
- const N = Z[0];
149
+ const M = ee[0];
149
150
  return {
150
- id: String(N.id),
151
- label: A(N),
151
+ id: String(M.id),
152
+ label: A(M),
152
153
  drillsIn: !1,
153
- icon: P,
154
- authRequired: b(N)?.authRequired,
155
- onActivate: () => L(N)
154
+ icon: N,
155
+ authRequired: b(M)?.authRequired,
156
+ onActivate: () => C(M)
156
157
  };
157
158
  }
158
159
  return {
159
160
  id: t,
160
- label: Y(t),
161
+ label: H(t, B),
161
162
  drillsIn: !0,
162
- icon: q(t) ?? l?.icon,
163
+ icon: D(t) ?? l?.icon,
163
164
  onActivate: () => S(t)
164
165
  };
165
166
  };
166
167
  if (i === v)
167
- return p.filter((t) => z(t)).sort((t, l) => j(t) - j(l)).map(g);
168
- const X = p.filter((t) => !z(t)).map((t) => ({ row: g(t), rank: j(t) }));
169
- return p.some((t) => z(t)) && X.push({
170
- rank: xe,
168
+ return p.filter((t) => q(t)).sort((t, l) => Y(t) - Y(l)).map(g);
169
+ const Z = p.filter((t) => !q(t)).map((t) => ({ row: g(t), rank: Y(t) }));
170
+ return p.some((t) => q(t)) && Z.push({
171
+ rank: ve,
171
172
  row: {
172
173
  id: v,
173
- label: ee,
174
+ label: te,
174
175
  drillsIn: !0,
175
- icon: ne,
176
+ icon: oe,
176
177
  onActivate: () => S(v)
177
178
  }
178
- }), X.sort((t, l) => t.rank - l.rank).map((t) => t.row);
179
+ }), Z.sort((t, l) => t.rank - l.rank).map((t) => t.row);
179
180
  }
180
181
  const e = E.trim().toLowerCase(), n = k.filter((r) => (b(r)?.source ?? "other") === i).filter((r) => !e || A(r).toLowerCase().includes(e)).map((r) => ({
181
182
  id: String(r.id),
182
183
  label: A(r),
183
184
  drillsIn: !1,
184
185
  authRequired: b(r)?.authRequired,
185
- onActivate: () => L(r)
186
- })), f = U.get(i);
186
+ onActivate: () => C(r)
187
+ })), f = V.get(i);
187
188
  if (f) {
188
- const r = i in ke;
189
+ const r = i in xe;
189
190
  n.push({
190
191
  id: `create:${i}`,
191
192
  label: f.label,
@@ -199,26 +200,27 @@ const ne = {
199
200
  return n;
200
201
  }, [
201
202
  a,
202
- T,
203
+ _,
203
204
  i,
204
205
  E,
205
206
  k,
206
- O,
207
- F,
208
207
  L,
208
+ U,
209
+ C,
209
210
  w,
210
211
  R,
211
212
  y,
212
- U,
213
- J,
214
- K
213
+ V,
214
+ K,
215
+ Q,
216
+ B
215
217
  ]);
216
- V(() => m(-1), [a, i, E, s]), V(() => Q(""), [a, i]);
217
- const W = ue({ rows: d, activeIndex: B, header: h });
218
- W.current = { rows: d, activeIndex: B, header: h }, V(() => {
219
- if (C)
220
- return C((e) => {
221
- const { rows: n, activeIndex: f, header: r } = W.current;
218
+ j(() => m(-1), [a, i, E, s]), j(() => W(""), [a, i]);
219
+ const X = he({ rows: d, activeIndex: T, header: h });
220
+ X.current = { rows: d, activeIndex: T, header: h }, j(() => {
221
+ if ($)
222
+ return $((e) => {
223
+ const { rows: n, activeIndex: f, header: r } = X.current;
222
224
  if (!n.length && e.key !== "ArrowLeft")
223
225
  return !1;
224
226
  switch (e.key) {
@@ -234,17 +236,17 @@ const ne = {
234
236
  default:
235
237
  return !1;
236
238
  }
237
- }), () => C(null);
238
- }, [C]);
239
- const ie = a ? d.length && !d[0].drillsIn ? "items" : "sources" : "categories", le = a === "tool" && !!i && i !== v || a === "subagent";
239
+ }), () => $(null);
240
+ }, [$]);
241
+ const le = a ? d.length && !d[0].drillsIn ? "items" : "sources" : "categories", ae = a === "tool" && !!i && i !== v || a === "subagent";
240
242
  return /* @__PURE__ */ x(
241
- Ie,
243
+ Re,
242
244
  {
243
- className: `bik-mention-picker bik-mention-picker--${ie}`,
245
+ className: `bik-mention-picker bik-mention-picker--${le}`,
244
246
  $fixedHeight: a === "variable",
245
247
  children: [
246
248
  h && /* @__PURE__ */ x(
247
- Te,
249
+ _e,
248
250
  {
249
251
  type: "button",
250
252
  onClick: h.onBack,
@@ -255,24 +257,24 @@ const ne = {
255
257
  },
256
258
  children: [
257
259
  h.onBack && /* @__PURE__ */ c(
258
- de,
260
+ ue,
259
261
  {
260
262
  width: 20,
261
263
  height: 20,
262
264
  color: o.content.primary
263
265
  }
264
266
  ),
265
- h.icon && te(h.icon),
266
- /* @__PURE__ */ x(he, { children: [
267
+ h.icon && re(h.icon),
268
+ /* @__PURE__ */ x(pe, { children: [
267
269
  " ",
268
270
  h.title
269
271
  ] })
270
272
  ]
271
273
  }
272
274
  ),
273
- le && /* @__PURE__ */ x(Ee, { children: [
275
+ ae && /* @__PURE__ */ x(Ae, { children: [
274
276
  /* @__PURE__ */ c(
275
- se,
277
+ de,
276
278
  {
277
279
  width: 20,
278
280
  height: 20,
@@ -280,15 +282,15 @@ const ne = {
280
282
  }
281
283
  ),
282
284
  /* @__PURE__ */ c(
283
- Ae,
285
+ Ce,
284
286
  {
285
287
  autoFocus: !0,
286
288
  value: E,
287
289
  placeholder: "Search",
288
290
  "data-test": "mention-picker-search",
289
- onChange: (e) => Q(e.target.value),
291
+ onChange: (e) => W(e.target.value),
290
292
  onKeyDown: (e) => {
291
- d.length && (e.key === "ArrowDown" ? (e.preventDefault(), m((n) => (n + 1) % d.length)) : e.key === "ArrowUp" ? (e.preventDefault(), m((n) => (n + d.length - 1) % d.length)) : e.key === "Enter" && (e.preventDefault(), (d[B] ?? d[0])?.onActivate()));
293
+ d.length && (e.key === "ArrowDown" ? (e.preventDefault(), m((n) => (n + 1) % d.length)) : e.key === "ArrowUp" ? (e.preventDefault(), m((n) => (n + d.length - 1) % d.length)) : e.key === "Enter" && (e.preventDefault(), (d[T] ?? d[0])?.onActivate()));
292
294
  }
293
295
  }
294
296
  )
@@ -299,51 +301,51 @@ const ne = {
299
301
  // fixed and only the variable list below scrolls. Selecting a
300
302
  // variable dismisses the menu FIRST (strips the typed "@" + query),
301
303
  // then hands the variable up to insert its `{{token}}` at the cursor.
302
- /* @__PURE__ */ c(Se, { children: /* @__PURE__ */ c(
303
- we,
304
+ /* @__PURE__ */ c(Ee, { children: /* @__PURE__ */ c(
305
+ ye,
304
306
  {
305
- type: ge.EMBEDDED,
306
- data: D ?? [],
307
+ type: be.EMBEDDED,
308
+ data: G ?? [],
307
309
  showRecommendedBar: !0,
308
310
  skipDefaultVariableContent: !0,
309
311
  onSelect: (e) => {
310
- w?.(), G?.(e);
312
+ w?.(), F?.(e);
311
313
  }
312
314
  }
313
315
  ) })
314
- ) : d.length === 0 ? /* @__PURE__ */ c(_e, { children: a === "subagent" ? null : "No tools available" }) : /* @__PURE__ */ c(Re, { children: d.map((e, n) => /* @__PURE__ */ c(
315
- Le,
316
+ ) : d.length === 0 ? /* @__PURE__ */ c(Pe, { children: a === "subagent" ? null : "No tools available" }) : /* @__PURE__ */ c(Se, { children: d.map((e, n) => /* @__PURE__ */ c(
317
+ $e,
316
318
  {
317
319
  type: "button",
318
- $active: n === B,
320
+ $active: n === T,
319
321
  onMouseEnter: () => m(n),
320
322
  onMouseLeave: () => m(-1),
321
323
  onClick: e.onActivate,
322
- children: e.isCreate ? /* @__PURE__ */ c(Oe, { children: e.label }) : /* @__PURE__ */ x(ae, { children: [
323
- /* @__PURE__ */ x(Ce, { children: [
324
- te(e.icon),
325
- /* @__PURE__ */ c(pe, { color: o.content.primary, children: e.label }),
324
+ children: e.isCreate ? /* @__PURE__ */ c(Le, { children: e.label }) : /* @__PURE__ */ x(ce, { children: [
325
+ /* @__PURE__ */ x(Be, { children: [
326
+ re(e.icon),
327
+ /* @__PURE__ */ c(fe, { color: o.content.primary, children: e.label }),
326
328
  e.authRequired && /* @__PURE__ */ c(
327
- re,
329
+ ne,
328
330
  {
329
331
  size: 14,
330
332
  "aria-label": "Requires customer verification"
331
333
  }
332
334
  )
333
335
  ] }),
334
- e.rightLabel ? /* @__PURE__ */ c(Be, { children: e.rightLabel }) : e.drillsIn && /* @__PURE__ */ c(ce, { width: 12, height: 12 })
336
+ e.rightLabel ? /* @__PURE__ */ c(Te, { children: e.rightLabel }) : e.drillsIn && /* @__PURE__ */ c(se, { width: 12, height: 12 })
335
337
  ] })
336
338
  },
337
339
  e.id
338
340
  )) }),
339
- d.some((e) => e.authRequired) && /* @__PURE__ */ x($e, { children: [
340
- /* @__PURE__ */ c(re, { size: 16 }),
341
- /* @__PURE__ */ c(fe, { color: o.content.secondary, children: "Requires customer verification" })
341
+ d.some((e) => e.authRequired) && /* @__PURE__ */ x(Oe, { children: [
342
+ /* @__PURE__ */ c(ne, { size: 16 }),
343
+ /* @__PURE__ */ c(ge, { color: o.content.secondary, children: "Requires customer verification" })
342
344
  ] })
343
345
  ]
344
346
  }
345
347
  );
346
- }, Ie = u.div`
348
+ }, Re = u.div`
347
349
  display: flex;
348
350
  flex-direction: column;
349
351
  min-width: 240px;
@@ -356,7 +358,7 @@ const ne = {
356
358
  border: 1px solid ${o.stroke.primary};
357
359
  border-radius: 4px;
358
360
  box-shadow: 0px -2px 8px 0px #0000001f;
359
- `, Re = u.div`
361
+ `, Se = u.div`
360
362
  flex: 1 1 auto;
361
363
  min-height: 0;
362
364
  overflow-y: auto;
@@ -365,7 +367,7 @@ const ne = {
365
367
  &::-webkit-scrollbar {
366
368
  display: none;
367
369
  }
368
- `, Se = u.div`
370
+ `, Ee = u.div`
369
371
  flex: 1 1 auto;
370
372
  min-height: 0;
371
373
 
@@ -380,14 +382,14 @@ const ne = {
380
382
  *::-webkit-scrollbar {
381
383
  display: none;
382
384
  }
383
- `, Ee = u.div`
385
+ `, Ae = u.div`
384
386
  display: flex;
385
387
  align-items: center;
386
388
  gap: 8px;
387
389
  padding: 10px 12px;
388
390
  flex-shrink: 0;
389
391
  border-bottom: 1px solid ${o.stroke.primary};
390
- `, Ae = u.input`
392
+ `, Ce = u.input`
391
393
  flex: 1;
392
394
  min-width: 0;
393
395
  border: none;
@@ -400,7 +402,7 @@ const ne = {
400
402
  &::placeholder {
401
403
  color: ${o.content.placeholder};
402
404
  }
403
- `, Le = u.button`
405
+ `, $e = u.button`
404
406
  display: flex;
405
407
  justify-content: space-between;
406
408
  align-items: center;
@@ -422,32 +424,32 @@ const ne = {
422
424
  &:hover {
423
425
  background: ${o.surface.hovered};
424
426
  }
425
- `, Ce = u.div`
427
+ `, Be = u.div`
426
428
  display: flex;
427
429
  align-items: center;
428
430
  gap: 12px;
429
431
  min-width: 0;
430
- `, $e = u.div`
432
+ `, Oe = u.div`
431
433
  display: flex;
432
434
  align-items: center;
433
435
  gap: 6px;
434
436
  padding: 8px 12px;
435
437
  border-top: 1px solid ${o.stroke.primary};
436
- `, Be = u.span`
438
+ `, Te = u.span`
437
439
  flex-shrink: 0;
438
440
  color: ${o.content.brand};
439
441
  font-family: Inter;
440
442
  font-size: 14px;
441
443
  font-weight: 600;
442
444
  white-space: nowrap;
443
- `, Oe = u.div`
445
+ `, Le = u.div`
444
446
  width: 100%;
445
447
  text-align: center;
446
448
  color: ${o.content.brand};
447
449
  font-family: Inter;
448
450
  font-size: 14px;
449
451
  font-weight: 600;
450
- `, Te = u.button`
452
+ `, _e = u.button`
451
453
  display: flex;
452
454
  align-items: center;
453
455
  padding: 12px 16px;
@@ -462,13 +464,13 @@ const ne = {
462
464
  box-sizing: border-box;
463
465
  flex-shrink: 0;
464
466
  gap: 4px;
465
- `, _e = u.div`
467
+ `, Pe = u.div`
466
468
  padding: 12px 10px;
467
469
  font-family: Inter;
468
470
  font-size: 13px;
469
471
  color: ${o.content.secondary};
470
472
  `;
471
473
  export {
472
- Xe as MentionPicker
474
+ Ze as MentionPicker
473
475
  };
474
476
  //# sourceMappingURL=MentionPicker.js.map