@pcoi/components 0.1.0 → 0.1.2

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 (72) hide show
  1. package/dist/components.css +1 -1
  2. package/dist/index.d.ts +50 -13
  3. package/dist/index.js +2 -2
  4. package/dist/index.mjs +499 -553
  5. package/package.json +14 -7
  6. package/src/Badge/Badge.css +2 -2
  7. package/src/Button/Button.css +4 -4
  8. package/src/Button/Button.figma.tsx +3 -5
  9. package/src/Button/Button.test.tsx +32 -0
  10. package/src/Callout/Callout.css +10 -5
  11. package/src/Callout/Callout.figma.tsx +25 -0
  12. package/src/Callout/Callout.tsx +14 -10
  13. package/src/Card/Card.css +8 -8
  14. package/src/Card/Card.figma.tsx +28 -0
  15. package/src/ChatInterface/ChatInterface.css +6 -5
  16. package/src/ChatInterface/ChatInterface.integration.test.tsx +123 -0
  17. package/src/ChatInterface/ChatInterface.tsx +6 -1
  18. package/src/ChatMessage/ChatMessage.css +8 -8
  19. package/src/ChatMessageList/ChatMessageList.css +4 -4
  20. package/src/ChatMessageList/ChatMessageList.test.tsx +70 -0
  21. package/src/ChatMessageList/ChatMessageList.tsx +7 -2
  22. package/src/Checkbox/Checkbox.css +6 -6
  23. package/src/CitationMark/CitationMark.css +3 -3
  24. package/src/CitedExcerpt/CitedExcerpt.css +7 -7
  25. package/src/CitedExcerpt/CitedExcerpt.tsx +2 -0
  26. package/src/ComparisonTable/ComparisonTable.css +6 -6
  27. package/src/ComparisonTable/ComparisonTable.tsx +6 -0
  28. package/src/ContactForm/ContactForm.css +5 -5
  29. package/src/ContactForm/ContactForm.tsx +2 -1
  30. package/src/DataTable/DataTable.css +4 -4
  31. package/src/DocumentOverlay/DocumentOverlay.css +5 -5
  32. package/src/DocumentOverlay/DocumentOverlay.test.tsx +95 -0
  33. package/src/DocumentOverlay/DocumentOverlay.tsx +1 -0
  34. package/src/Footer/Footer.css +9 -9
  35. package/src/Footer/Footer.tsx +5 -2
  36. package/src/FormField/FormField.css +4 -4
  37. package/src/FormField/FormField.figma.tsx +28 -0
  38. package/src/HowStep/HowStep.css +4 -4
  39. package/src/HowStep/HowStep.figma.tsx +23 -0
  40. package/src/LogoMark/LogoMark.tsx +3 -4
  41. package/src/Modal/Modal.css +11 -11
  42. package/src/Modal/Modal.figma.tsx +28 -0
  43. package/src/Modal/Modal.test.tsx +46 -0
  44. package/src/Modal/Modal.tsx +88 -85
  45. package/src/Nav/Nav.css +16 -16
  46. package/src/Nav/Nav.tsx +6 -2
  47. package/src/Panel/Panel.css +3 -3
  48. package/src/PromptBar/PromptBar.css +10 -10
  49. package/src/PromptBar/PromptBar.figma.tsx +25 -0
  50. package/src/PromptBar/PromptBar.test.tsx +83 -0
  51. package/src/PromptBar/PromptBar.tsx +2 -2
  52. package/src/RadioGroup/RadioGroup.css +11 -11
  53. package/src/SectionHeader/SectionHeader.css +4 -4
  54. package/src/SectionHeader/SectionHeader.figma.tsx +23 -0
  55. package/src/Select/Select.css +5 -5
  56. package/src/Select/Select.figma.tsx +33 -0
  57. package/src/Select/Select.tsx +1 -1
  58. package/src/SignalsPanel/SignalsPanel.css +9 -9
  59. package/src/SignalsPanel/SignalsPanel.tsx +2 -0
  60. package/src/SuggestionCard/SuggestionCard.css +5 -5
  61. package/src/SuggestionCards/SuggestionCards.css +1 -1
  62. package/src/SuggestionCards/SuggestionCards.test.tsx +27 -0
  63. package/src/SuggestionCards/SuggestionCards.tsx +1 -1
  64. package/src/Toast/Toast.css +14 -14
  65. package/src/Toast/Toast.tsx +50 -45
  66. package/src/Toggle/Toggle.css +15 -15
  67. package/src/Toggle/Toggle.figma.tsx +24 -0
  68. package/src/TypingIndicator/TypingIndicator.css +6 -6
  69. package/src/TypingIndicator/TypingIndicator.tsx +2 -2
  70. package/src/index.ts +2 -0
  71. package/src/styles.css +1 -0
  72. package/src/types.ts +1 -0
package/dist/index.mjs CHANGED
@@ -1,58 +1,59 @@
1
- import { jsxs as n, jsx as e, Fragment as E } from "react/jsx-runtime";
2
- import _, { useState as $, useEffect as y, useRef as w, useCallback as R } from "react";
1
+ import { jsxs as n, jsx as e, Fragment as j } from "react/jsx-runtime";
2
+ import _, { useState as x, useEffect as y, useRef as w, useCallback as $ } from "react";
3
+ import { ChevronDownIcon as z, CloseIcon as E, ArrowRightIcon as Y } from "@pcoi/icons";
3
4
  import { createPortal as F } from "react-dom";
4
5
  const I = _.forwardRef(
5
- ({ href: i = "#", className: a = "", ...c }, l) => /* @__PURE__ */ n("a", { ref: l, href: i, className: `pcoi-logo ${a}`, ...c, children: [
6
- /* @__PURE__ */ e("span", { className: "pcoi-logo__mark", children: "P" }),
6
+ ({ href: i = "#", className: l = "", ...a }, o) => /* @__PURE__ */ n("a", { ref: o, href: i, className: `pcoi-logo ${l}`, "aria-label": "PCOI home", ...a, children: [
7
+ /* @__PURE__ */ e("span", { className: "pcoi-logo__mark", "aria-hidden": "true", children: "P" }),
7
8
  "COI"
8
9
  ] })
9
10
  );
10
11
  I.displayName = "LogoMark";
11
12
  const k = _.forwardRef(
12
- ({ variant: i = "primary", size: a = "default", children: c, className: l = "", ...o }, s) => {
13
+ ({ variant: i = "primary", size: l = "default", children: a, className: o = "", ...c }, s) => {
13
14
  const r = [
14
15
  "pcoi-btn",
15
16
  `pcoi-btn--${i}`,
16
- a !== "default" ? `pcoi-btn--${a}` : "",
17
- l
17
+ l !== "default" ? `pcoi-btn--${l}` : "",
18
+ o
18
19
  ].filter(Boolean).join(" ");
19
- return /* @__PURE__ */ e("button", { ref: s, className: r, ...o, children: c });
20
+ return /* @__PURE__ */ e("button", { ref: s, className: r, ...c, children: a });
20
21
  }
21
22
  );
22
23
  k.displayName = "Button";
23
24
  const g = _.forwardRef(
24
25
  ({
25
26
  label: i,
26
- name: a,
27
- multiline: c = !1,
28
- rows: l = 3,
29
- error: o,
27
+ name: l,
28
+ multiline: a = !1,
29
+ rows: o = 3,
30
+ error: c,
30
31
  required: s = !1,
31
32
  disabled: r = !1,
32
- className: t = "",
33
+ className: d = "",
33
34
  ...p
34
- }, d) => {
35
- const h = `pcoi-field-${a}`, m = o ? `${h}-error` : void 0, u = [
35
+ }, t) => {
36
+ const h = `pcoi-field-${l}`, m = c ? `${h}-error` : void 0, N = [
36
37
  "pcoi-field",
37
- o ? "pcoi-field--error" : "",
38
+ c ? "pcoi-field--error" : "",
38
39
  r ? "pcoi-field--disabled" : "",
39
- t
40
+ d
40
41
  ].filter(Boolean).join(" ");
41
- return /* @__PURE__ */ n("div", { className: u, children: [
42
+ return /* @__PURE__ */ n("div", { className: N, children: [
42
43
  /* @__PURE__ */ n("label", { htmlFor: h, className: "pcoi-field__label", children: [
43
44
  i,
44
45
  s && /* @__PURE__ */ e("span", { className: "pcoi-field__required", "aria-hidden": "true", children: "*" })
45
46
  ] }),
46
- c ? /* @__PURE__ */ e(
47
+ a ? /* @__PURE__ */ e(
47
48
  "textarea",
48
49
  {
49
- ref: d,
50
+ ref: t,
50
51
  id: h,
51
- name: a,
52
- rows: l,
52
+ name: l,
53
+ rows: o,
53
54
  required: s,
54
55
  disabled: r,
55
- "aria-invalid": !!o,
56
+ "aria-invalid": !!c,
56
57
  "aria-describedby": m,
57
58
  className: "pcoi-field__textarea",
58
59
  ...p
@@ -60,39 +61,39 @@ const g = _.forwardRef(
60
61
  ) : /* @__PURE__ */ e(
61
62
  "input",
62
63
  {
63
- ref: d,
64
+ ref: t,
64
65
  id: h,
65
- name: a,
66
+ name: l,
66
67
  required: s,
67
68
  disabled: r,
68
- "aria-invalid": !!o,
69
+ "aria-invalid": !!c,
69
70
  "aria-describedby": m,
70
71
  className: "pcoi-field__input",
71
72
  ...p
72
73
  }
73
74
  ),
74
- o && /* @__PURE__ */ e("span", { id: m, className: "pcoi-field__error", role: "alert", children: o })
75
+ c && /* @__PURE__ */ e("span", { id: m, className: "pcoi-field__error", role: "alert", children: c })
75
76
  ] });
76
77
  }
77
78
  );
78
79
  g.displayName = "FormField";
79
- const Y = _.forwardRef(
80
- ({ variant: i = "problem", title: a, description: c, icon: l, number: o, headingLevel: s = "h3", className: r = "", ...t }, p) => {
81
- const d = s, h = [
80
+ const V = _.forwardRef(
81
+ ({ variant: i = "problem", title: l, description: a, icon: o, number: c, headingLevel: s = "h3", className: r = "", ...d }, p) => {
82
+ const t = s, h = [
82
83
  "pcoi-card",
83
84
  `pcoi-card--${i}`,
84
85
  r
85
86
  ].filter(Boolean).join(" ");
86
- return /* @__PURE__ */ n("div", { ref: p, className: h, ...t, children: [
87
- i === "problem" && l && /* @__PURE__ */ e("div", { className: "pcoi-card__icon", children: l }),
88
- i === "principle" && o && /* @__PURE__ */ e("div", { className: "pcoi-card__number", children: o }),
89
- /* @__PURE__ */ e(d, { className: "pcoi-card__title", children: a }),
90
- /* @__PURE__ */ e("p", { className: "pcoi-card__description", children: c })
87
+ return /* @__PURE__ */ n("div", { ref: p, className: h, ...d, children: [
88
+ i === "problem" && o && /* @__PURE__ */ e("div", { className: "pcoi-card__icon", children: o }),
89
+ i === "principle" && c && /* @__PURE__ */ e("div", { className: "pcoi-card__number", children: c }),
90
+ /* @__PURE__ */ e(t, { className: "pcoi-card__title", children: l }),
91
+ /* @__PURE__ */ e("p", { className: "pcoi-card__description", children: a })
91
92
  ] });
92
93
  }
93
94
  );
94
- Y.displayName = "Card";
95
- const K = _.forwardRef(
95
+ V.displayName = "Card";
96
+ const W = _.forwardRef(
96
97
  ({
97
98
  links: i = [
98
99
  { label: "Problem", href: "#problem" },
@@ -100,27 +101,27 @@ const K = _.forwardRef(
100
101
  { label: "Difference", href: "#difference" },
101
102
  { label: "Who It's For", href: "#who" }
102
103
  ],
103
- ctaLabel: a = "Start a Conversation",
104
- ctaHref: c = "#contact",
105
- onCtaClick: l,
106
- className: o = "",
104
+ ctaLabel: l = "Start a Conversation",
105
+ ctaHref: a = "#contact",
106
+ onCtaClick: o,
107
+ className: c = "",
107
108
  ...s
108
109
  }, r) => {
109
- const [t, p] = $(!1), [d, h] = $(!1);
110
+ const [d, p] = x(!1), [t, h] = x(!1);
110
111
  return y(() => {
111
112
  const m = () => p(window.scrollY > 40);
112
113
  return window.addEventListener("scroll", m, { passive: !0 }), m(), () => window.removeEventListener("scroll", m);
113
114
  }, []), y(() => {
114
- if (!d) return;
115
- const m = (u) => {
116
- u.key === "Escape" && h(!1);
115
+ if (!t) return;
116
+ const m = (N) => {
117
+ N.key === "Escape" && h(!1);
117
118
  };
118
119
  return document.addEventListener("keydown", m), () => document.removeEventListener("keydown", m);
119
- }, [d]), /* @__PURE__ */ n(
120
+ }, [t]), /* @__PURE__ */ n(
120
121
  "nav",
121
122
  {
122
123
  ref: r,
123
- className: `pcoi-nav ${t ? "pcoi-nav--scrolled" : ""} ${d ? "pcoi-nav--menu-open" : ""} ${o}`,
124
+ className: `pcoi-nav ${d ? "pcoi-nav--scrolled" : ""} ${t ? "pcoi-nav--menu-open" : ""} ${c}`,
124
125
  "aria-label": "Main",
125
126
  ...s,
126
127
  children: [
@@ -128,15 +129,15 @@ const K = _.forwardRef(
128
129
  /* @__PURE__ */ e(I, {}),
129
130
  /* @__PURE__ */ n("div", { className: "pcoi-nav__links", children: [
130
131
  i.map((m) => /* @__PURE__ */ e("a", { href: m.href, "data-track-id": m.trackingId, children: m.label }, m.href)),
131
- /* @__PURE__ */ e("a", { href: c, children: /* @__PURE__ */ e(k, { variant: "nav-cta", onClick: l, children: a }) })
132
+ /* @__PURE__ */ e("a", { href: a, children: /* @__PURE__ */ e(k, { variant: "nav-cta", onClick: o, children: l }) })
132
133
  ] }),
133
134
  /* @__PURE__ */ n(
134
135
  "button",
135
136
  {
136
- className: `pcoi-nav__hamburger ${d ? "pcoi-nav__hamburger--active" : ""}`,
137
- onClick: () => h(!d),
137
+ className: `pcoi-nav__hamburger ${t ? "pcoi-nav__hamburger--active" : ""}`,
138
+ onClick: () => h(!t),
138
139
  "aria-label": "Toggle menu",
139
- "aria-expanded": d,
140
+ "aria-expanded": t,
140
141
  "aria-controls": "pcoi-mobile-menu",
141
142
  children: [
142
143
  /* @__PURE__ */ e("span", {}),
@@ -146,68 +147,68 @@ const K = _.forwardRef(
146
147
  }
147
148
  )
148
149
  ] }),
149
- /* @__PURE__ */ n("div", { className: "pcoi-nav__mobile-menu", id: "pcoi-mobile-menu", children: [
150
- i.map((m) => /* @__PURE__ */ e("a", { href: m.href, "data-track-id": m.trackingId, onClick: () => h(!1), children: m.label }, m.href)),
151
- /* @__PURE__ */ e("a", { href: c, children: /* @__PURE__ */ e(k, { variant: "nav-cta", onClick: () => {
152
- l == null || l(), h(!1);
153
- }, children: a }) })
150
+ /* @__PURE__ */ n("div", { className: "pcoi-nav__mobile-menu", id: "pcoi-mobile-menu", role: "menu", "aria-hidden": !t, children: [
151
+ i.map((m) => /* @__PURE__ */ e("a", { href: m.href, "data-track-id": m.trackingId, role: "menuitem", tabIndex: t ? 0 : -1, onClick: () => h(!1), children: m.label }, m.href)),
152
+ /* @__PURE__ */ e("a", { href: a, children: /* @__PURE__ */ e(k, { variant: "nav-cta", onClick: () => {
153
+ o == null || o(), h(!1);
154
+ }, children: l }) })
154
155
  ] })
155
156
  ]
156
157
  }
157
158
  );
158
159
  }
159
160
  );
160
- K.displayName = "Nav";
161
- const z = _.forwardRef(
162
- ({ label: i, title: a, titleEmphasis: c, description: l, headingLevel: o = "h2", className: s = "", ...r }, t) => {
163
- const p = o;
164
- return /* @__PURE__ */ n("div", { ref: t, className: `pcoi-section-header ${s}`, ...r, children: [
161
+ W.displayName = "Nav";
162
+ const K = _.forwardRef(
163
+ ({ label: i, title: l, titleEmphasis: a, description: o, headingLevel: c = "h2", className: s = "", ...r }, d) => {
164
+ const p = c;
165
+ return /* @__PURE__ */ n("div", { ref: d, className: `pcoi-section-header ${s}`, ...r, children: [
165
166
  /* @__PURE__ */ e("span", { className: "pcoi-section-header__label", children: i }),
166
- /* @__PURE__ */ e(p, { className: "pcoi-section-header__title", children: c ? /* @__PURE__ */ n(E, { children: [
167
- a.replace(c, ""),
168
- /* @__PURE__ */ e("em", { children: c })
169
- ] }) : a }),
170
- l && /* @__PURE__ */ e("p", { className: "pcoi-section-header__desc", children: l })
167
+ /* @__PURE__ */ e(p, { className: "pcoi-section-header__title", children: a ? /* @__PURE__ */ n(j, { children: [
168
+ l.replace(a, ""),
169
+ /* @__PURE__ */ e("em", { children: a })
170
+ ] }) : l }),
171
+ o && /* @__PURE__ */ e("p", { className: "pcoi-section-header__desc", children: o })
171
172
  ] });
172
173
  }
173
174
  );
174
- z.displayName = "SectionHeader";
175
- const V = _.forwardRef(
176
- ({ number: i, title: a, description: c, isLast: l = !1, headingLevel: o = "h3", className: s = "", ...r }, t) => {
177
- const p = o;
178
- return /* @__PURE__ */ n("div", { ref: t, className: `pcoi-how-step ${l ? "pcoi-how-step--last" : ""} ${s}`, ...r, children: [
175
+ K.displayName = "SectionHeader";
176
+ const G = _.forwardRef(
177
+ ({ number: i, title: l, description: a, isLast: o = !1, headingLevel: c = "h3", className: s = "", ...r }, d) => {
178
+ const p = c;
179
+ return /* @__PURE__ */ n("div", { ref: d, className: `pcoi-how-step ${o ? "pcoi-how-step--last" : ""} ${s}`, ...r, children: [
179
180
  /* @__PURE__ */ e("div", { className: "pcoi-how-step__number", children: i }),
180
181
  /* @__PURE__ */ n("div", { className: "pcoi-how-step__content", children: [
181
- /* @__PURE__ */ e(p, { className: "pcoi-how-step__title", children: a }),
182
- /* @__PURE__ */ e("p", { className: "pcoi-how-step__desc", children: c })
182
+ /* @__PURE__ */ e(p, { className: "pcoi-how-step__title", children: l }),
183
+ /* @__PURE__ */ e("p", { className: "pcoi-how-step__desc", children: a })
183
184
  ] })
184
185
  ] });
185
186
  }
186
187
  );
187
- V.displayName = "HowStep";
188
- const G = _.forwardRef(
189
- ({ competitorName: i = "Typical SaaS AI", pcoiName: a = "PCOI", rows: c, className: l = "", ...o }, s) => /* @__PURE__ */ e("div", { ref: s, className: `pcoi-comparison ${l}`, ...o, children: /* @__PURE__ */ n("table", { className: "pcoi-comparison__table", children: [
188
+ G.displayName = "HowStep";
189
+ const J = _.forwardRef(
190
+ ({ competitorName: i = "Typical SaaS AI", pcoiName: l = "PCOI", rows: a, className: o = "", ...c }, s) => /* @__PURE__ */ e("div", { ref: s, className: `pcoi-comparison ${o}`, ...c, children: /* @__PURE__ */ n("table", { className: "pcoi-comparison__table", children: [
190
191
  /* @__PURE__ */ e("thead", { children: /* @__PURE__ */ n("tr", { className: "pcoi-comparison__header", children: [
191
192
  /* @__PURE__ */ e("th", { className: "pcoi-comparison__col", scope: "col", children: /* @__PURE__ */ e("span", { className: "pcoi-sr-only", children: "Feature" }) }),
192
193
  /* @__PURE__ */ e("th", { className: "pcoi-comparison__col", scope: "col", children: i }),
193
- /* @__PURE__ */ e("th", { className: "pcoi-comparison__col pcoi-comparison__col--highlight", scope: "col", children: a })
194
+ /* @__PURE__ */ e("th", { className: "pcoi-comparison__col pcoi-comparison__col--highlight", scope: "col", children: l })
194
195
  ] }) }),
195
- /* @__PURE__ */ e("tbody", { children: c.map((r, t) => /* @__PURE__ */ n("tr", { className: "pcoi-comparison__row", children: [
196
+ /* @__PURE__ */ e("tbody", { children: a.map((r, d) => /* @__PURE__ */ n("tr", { className: "pcoi-comparison__row", children: [
196
197
  /* @__PURE__ */ e("th", { className: "pcoi-comparison__col pcoi-comparison__col--label", scope: "row", children: r.label }),
197
198
  /* @__PURE__ */ e("td", { className: "pcoi-comparison__col", children: r.competitor }),
198
199
  /* @__PURE__ */ e("td", { className: "pcoi-comparison__col pcoi-comparison__col--highlight", children: r.pcoi })
199
- ] }, t)) })
200
+ ] }, d)) })
200
201
  ] }) })
201
202
  );
202
- G.displayName = "ComparisonTable";
203
- const J = _.forwardRef(
204
- ({ onSubmit: i, className: a = "", ...c }, l) => {
205
- const [o, s] = $(!1), r = (t) => {
206
- t.preventDefault();
207
- const p = t.currentTarget, d = new FormData(p), h = Object.fromEntries(d.entries());
203
+ J.displayName = "ComparisonTable";
204
+ const Q = _.forwardRef(
205
+ ({ onSubmit: i, className: l = "", ...a }, o) => {
206
+ const [c, s] = x(!1), r = (d) => {
207
+ d.preventDefault();
208
+ const p = d.currentTarget, t = new FormData(p), h = Object.fromEntries(t.entries());
208
209
  i == null || i(h), s(!0), p.reset(), setTimeout(() => s(!1), 3e3);
209
210
  };
210
- return /* @__PURE__ */ n("form", { ref: l, className: `pcoi-form ${a}`, onSubmit: r, "aria-label": "Contact form", ...c, children: [
211
+ return /* @__PURE__ */ n("form", { ref: o, className: `pcoi-form ${l}`, onSubmit: r, "aria-label": "Contact form", ...a, children: [
211
212
  /* @__PURE__ */ n("div", { className: "pcoi-form__row", children: [
212
213
  /* @__PURE__ */ e(g, { label: "Name", name: "name", placeholder: "Your name", required: !0 }),
213
214
  /* @__PURE__ */ e(g, { label: "Company", name: "company", placeholder: "Company name", required: !0 })
@@ -227,41 +228,41 @@ const J = _.forwardRef(
227
228
  className: "pcoi-form__full"
228
229
  }
229
230
  ),
230
- /* @__PURE__ */ e(k, { type: "submit", variant: "primary", size: "large", disabled: o, children: o ? "Message Received" : "Start the Conversation" }),
231
+ /* @__PURE__ */ e(k, { type: "submit", variant: "primary", size: "large", disabled: c, children: c ? "Message Received" : "Start the Conversation" }),
231
232
  /* @__PURE__ */ e("p", { className: "pcoi-form__note", children: "No sales automation. A real person reads this and responds personally." })
232
233
  ] });
233
234
  }
234
235
  );
235
- J.displayName = "ContactForm";
236
- const Q = _.forwardRef(
237
- ({ quote: i, attribution: a, attributionTitle: c, sourceUrl: l, sourceLabel: o, className: s = "", ...r }, t) => /* @__PURE__ */ n("div", { ref: t, className: `pcoi-callout ${s}`, ...r, children: [
238
- /* @__PURE__ */ e("div", { className: "pcoi-callout__line" }),
239
- /* @__PURE__ */ e("p", { className: "pcoi-callout__quote", children: i }),
240
- (a || l) && /* @__PURE__ */ n("p", { className: "pcoi-callout__attribution", children: [
241
- c && /* @__PURE__ */ n("span", { children: [
242
- c,
236
+ Q.displayName = "ContactForm";
237
+ const X = _.forwardRef(
238
+ ({ quote: i, attribution: l, attributionTitle: a, sourceUrl: o, sourceLabel: c, className: s = "", ...r }, d) => /* @__PURE__ */ n("figure", { ref: d, className: `pcoi-callout ${s}`, ...r, children: [
239
+ /* @__PURE__ */ e("div", { className: "pcoi-callout__line", "aria-hidden": "true" }),
240
+ /* @__PURE__ */ e("blockquote", { className: "pcoi-callout__quote", children: /* @__PURE__ */ e("p", { children: i }) }),
241
+ (l || o) && /* @__PURE__ */ n("figcaption", { className: "pcoi-callout__attribution", children: [
242
+ a && /* @__PURE__ */ n("span", { children: [
243
+ a,
243
244
  "  ~  "
244
245
  ] }),
245
- a,
246
- l && /* @__PURE__ */ n(E, { children: [
246
+ l,
247
+ o && /* @__PURE__ */ n(j, { children: [
247
248
  "  |  ",
248
- /* @__PURE__ */ e("a", { href: l, target: "_blank", rel: "noopener noreferrer", children: o || "Source" })
249
+ /* @__PURE__ */ e("a", { href: o, target: "_blank", rel: "noopener noreferrer", children: c || "Source" })
249
250
  ] })
250
251
  ] })
251
252
  ] })
252
253
  );
253
- Q.displayName = "Callout";
254
- const X = _.forwardRef(
255
- ({ title: i = "You'll know this is for you if:", signals: a, headingLevel: c = "h3", className: l = "", ...o }, s) => {
256
- const r = c;
257
- return /* @__PURE__ */ n("div", { ref: s, className: `pcoi-signals ${l}`, ...o, children: [
254
+ X.displayName = "Callout";
255
+ const Z = _.forwardRef(
256
+ ({ title: i = "You'll know this is for you if:", signals: l, headingLevel: a = "h3", className: o = "", ...c }, s) => {
257
+ const r = a;
258
+ return /* @__PURE__ */ n("div", { ref: s, className: `pcoi-signals ${o}`, ...c, children: [
258
259
  /* @__PURE__ */ e(r, { className: "pcoi-signals__title", children: i }),
259
- /* @__PURE__ */ e("ul", { className: "pcoi-signals__list", children: a.map((t, p) => /* @__PURE__ */ e("li", { className: "pcoi-signals__item", children: t }, p)) })
260
+ /* @__PURE__ */ e("ul", { className: "pcoi-signals__list", children: l.map((d, p) => /* @__PURE__ */ e("li", { className: "pcoi-signals__item", children: d }, p)) })
260
261
  ] });
261
262
  }
262
263
  );
263
- X.displayName = "SignalsPanel";
264
- const Z = _.forwardRef(
264
+ Z.displayName = "SignalsPanel";
265
+ const U = _.forwardRef(
265
266
  ({
266
267
  links: i = [
267
268
  { label: "Problem", href: "#problem" },
@@ -271,68 +272,42 @@ const Z = _.forwardRef(
271
272
  { label: "Who It's For", href: "#who" },
272
273
  { label: "Contact", href: "#contact" }
273
274
  ],
274
- tagline: a = `Portable, Company-Owned
275
+ tagline: l = `Portable, Company-Owned
275
276
  Operational Intelligence`,
276
- copyright: c = `© ${(/* @__PURE__ */ new Date()).getFullYear()} PCOI. Operational intelligence you own.`,
277
- className: l = "",
278
- ...o
279
- }, s) => /* @__PURE__ */ n("footer", { ref: s, className: `pcoi-footer ${l}`, ...o, children: [
277
+ copyright: a = `© ${(/* @__PURE__ */ new Date()).getFullYear()} PCOI. Operational intelligence you own.`,
278
+ className: o = "",
279
+ ...c
280
+ }, s) => /* @__PURE__ */ n("footer", { ref: s, className: `pcoi-footer ${o}`, ...c, children: [
280
281
  /* @__PURE__ */ n("div", { className: "pcoi-footer__inner", children: [
281
282
  /* @__PURE__ */ n("div", { className: "pcoi-footer__brand", children: [
282
283
  /* @__PURE__ */ e(I, { className: "pcoi-footer__logo" }),
283
- /* @__PURE__ */ e("p", { className: "pcoi-footer__tagline", children: a })
284
+ /* @__PURE__ */ e("p", { className: "pcoi-footer__tagline", children: l })
284
285
  ] }),
285
- /* @__PURE__ */ e("div", { className: "pcoi-footer__links", children: i.map((r) => /* @__PURE__ */ e("a", { href: r.href, "data-track-id": r.trackingId, children: r.label }, r.href)) })
286
+ /* @__PURE__ */ e("nav", { className: "pcoi-footer__links", "aria-label": "Footer", children: i.map((r) => /* @__PURE__ */ e("a", { href: r.href, "data-track-id": r.trackingId, children: r.label }, r.href)) })
286
287
  ] }),
287
- /* @__PURE__ */ e("div", { className: "pcoi-footer__bottom", children: /* @__PURE__ */ e("p", { children: c }) })
288
+ /* @__PURE__ */ e("div", { className: "pcoi-footer__bottom", children: /* @__PURE__ */ e("p", { children: a }) })
288
289
  ] })
289
290
  );
290
- Z.displayName = "Footer";
291
- const T = ({
292
- size: i = 24,
293
- title: a,
294
- ...c
295
- }) => /* @__PURE__ */ n(
296
- "svg",
297
- {
298
- width: i,
299
- height: i,
300
- viewBox: "0 0 24 24",
301
- fill: "none",
302
- stroke: "currentColor",
303
- strokeWidth: 1.5,
304
- strokeLinecap: "round",
305
- strokeLinejoin: "round",
306
- role: a ? "img" : "presentation",
307
- "aria-hidden": !a,
308
- xmlns: "http://www.w3.org/2000/svg",
309
- ...c,
310
- children: [
311
- a && /* @__PURE__ */ e("title", { children: a }),
312
- /* @__PURE__ */ e("polyline", { points: "6 9 12 15 18 9" })
313
- ]
314
- }
315
- );
316
- T.displayName = "ChevronDownIcon";
317
- const U = _.forwardRef(
291
+ U.displayName = "Footer";
292
+ const ee = _.forwardRef(
318
293
  ({
319
294
  label: i,
320
- name: a,
321
- options: c,
322
- placeholder: l,
323
- error: o,
295
+ name: l,
296
+ options: a,
297
+ placeholder: o,
298
+ error: c,
324
299
  required: s = !1,
325
300
  disabled: r = !1,
326
- className: t = "",
301
+ className: d = "",
327
302
  ...p
328
- }, d) => {
329
- const h = `pcoi-field-${a}`, m = o ? `${h}-error` : void 0, u = [
303
+ }, t) => {
304
+ const h = `pcoi-field-${l}`, m = c ? `${h}-error` : void 0, N = [
330
305
  "pcoi-select",
331
- o ? "pcoi-select--error" : "",
306
+ c ? "pcoi-select--error" : "",
332
307
  r ? "pcoi-select--disabled" : "",
333
- t
308
+ d
334
309
  ].filter(Boolean).join(" ");
335
- return /* @__PURE__ */ n("div", { className: u, children: [
310
+ return /* @__PURE__ */ n("div", { className: N, children: [
336
311
  /* @__PURE__ */ n("label", { htmlFor: h, className: "pcoi-select__label", children: [
337
312
  i,
338
313
  s && /* @__PURE__ */ e("span", { className: "pcoi-select__required", "aria-hidden": "true", children: "*" })
@@ -341,55 +316,55 @@ const U = _.forwardRef(
341
316
  /* @__PURE__ */ n(
342
317
  "select",
343
318
  {
344
- ref: d,
319
+ ref: t,
345
320
  id: h,
346
- name: a,
321
+ name: l,
347
322
  required: s,
348
323
  disabled: r,
349
- "aria-invalid": !!o,
324
+ "aria-invalid": !!c,
350
325
  "aria-describedby": m,
351
326
  className: "pcoi-select__native",
352
- defaultValue: l ? "" : void 0,
327
+ defaultValue: o ? "" : void 0,
353
328
  ...p,
354
329
  children: [
355
- l && /* @__PURE__ */ e("option", { value: "", disabled: !0, hidden: !0, children: l }),
356
- c.map((f) => /* @__PURE__ */ e("option", { value: f.value, disabled: f.disabled, children: f.label }, f.value))
330
+ o && /* @__PURE__ */ e("option", { value: "", disabled: !0, hidden: !0, children: o }),
331
+ a.map((f) => /* @__PURE__ */ e("option", { value: f.value, disabled: f.disabled, children: f.label }, f.value))
357
332
  ]
358
333
  }
359
334
  ),
360
- /* @__PURE__ */ e("span", { className: "pcoi-select__chevron", "aria-hidden": "true", children: /* @__PURE__ */ e(T, { size: 16 }) })
335
+ /* @__PURE__ */ e("span", { className: "pcoi-select__chevron", "aria-hidden": "true", children: /* @__PURE__ */ e(z, { size: 16 }) })
361
336
  ] }),
362
- o && /* @__PURE__ */ e("span", { id: m, className: "pcoi-select__error", role: "alert", children: o })
337
+ c && /* @__PURE__ */ e("span", { id: m, className: "pcoi-select__error", role: "alert", children: c })
363
338
  ] });
364
339
  }
365
340
  );
366
- U.displayName = "Select";
367
- const ee = _.forwardRef(
341
+ ee.displayName = "Select";
342
+ const ae = _.forwardRef(
368
343
  ({
369
344
  label: i,
370
- name: a,
371
- error: c,
372
- disabled: l = !1,
373
- className: o = "",
345
+ name: l,
346
+ error: a,
347
+ disabled: o = !1,
348
+ className: c = "",
374
349
  ...s
375
350
  }, r) => {
376
- const t = `pcoi-field-${a}`, p = c ? `${t}-error` : void 0, d = [
351
+ const d = `pcoi-field-${l}`, p = a ? `${d}-error` : void 0, t = [
377
352
  "pcoi-checkbox",
378
- c ? "pcoi-checkbox--error" : "",
379
- l ? "pcoi-checkbox--disabled" : "",
380
- o
353
+ a ? "pcoi-checkbox--error" : "",
354
+ o ? "pcoi-checkbox--disabled" : "",
355
+ c
381
356
  ].filter(Boolean).join(" ");
382
- return /* @__PURE__ */ n("div", { className: d, children: [
383
- /* @__PURE__ */ n("label", { htmlFor: t, className: "pcoi-checkbox__control", children: [
357
+ return /* @__PURE__ */ n("div", { className: t, children: [
358
+ /* @__PURE__ */ n("label", { htmlFor: d, className: "pcoi-checkbox__control", children: [
384
359
  /* @__PURE__ */ e(
385
360
  "input",
386
361
  {
387
362
  ref: r,
388
363
  type: "checkbox",
389
- id: t,
390
- name: a,
391
- disabled: l,
392
- "aria-invalid": !!c,
364
+ id: d,
365
+ name: l,
366
+ disabled: o,
367
+ "aria-invalid": !!a,
393
368
  "aria-describedby": p,
394
369
  className: "pcoi-checkbox__input",
395
370
  ...s
@@ -398,37 +373,37 @@ const ee = _.forwardRef(
398
373
  /* @__PURE__ */ e("span", { className: "pcoi-checkbox__box", "aria-hidden": "true" }),
399
374
  /* @__PURE__ */ e("span", { className: "pcoi-checkbox__label", children: i })
400
375
  ] }),
401
- c && /* @__PURE__ */ e("span", { id: p, className: "pcoi-checkbox__error", role: "alert", children: c })
376
+ a && /* @__PURE__ */ e("span", { id: p, className: "pcoi-checkbox__error", role: "alert", children: a })
402
377
  ] });
403
378
  }
404
379
  );
405
- ee.displayName = "Checkbox";
406
- const ae = _.forwardRef(
380
+ ae.displayName = "Checkbox";
381
+ const ie = _.forwardRef(
407
382
  ({
408
383
  label: i,
409
- name: a,
410
- error: c,
411
- disabled: l = !1,
412
- className: o = "",
384
+ name: l,
385
+ error: a,
386
+ disabled: o = !1,
387
+ className: c = "",
413
388
  ...s
414
389
  }, r) => {
415
- const t = `pcoi-field-${a}`, p = c ? `${t}-error` : void 0, d = [
390
+ const d = `pcoi-field-${l}`, p = a ? `${d}-error` : void 0, t = [
416
391
  "pcoi-toggle",
417
- c ? "pcoi-toggle--error" : "",
418
- l ? "pcoi-toggle--disabled" : "",
419
- o
392
+ a ? "pcoi-toggle--error" : "",
393
+ o ? "pcoi-toggle--disabled" : "",
394
+ c
420
395
  ].filter(Boolean).join(" ");
421
- return /* @__PURE__ */ n("div", { className: d, children: [
422
- /* @__PURE__ */ n("label", { htmlFor: t, className: "pcoi-toggle__control", children: [
396
+ return /* @__PURE__ */ n("div", { className: t, children: [
397
+ /* @__PURE__ */ n("label", { htmlFor: d, className: "pcoi-toggle__control", children: [
423
398
  /* @__PURE__ */ e(
424
399
  "input",
425
400
  {
426
401
  ref: r,
427
402
  type: "checkbox",
428
- id: t,
429
- name: a,
430
- disabled: l,
431
- "aria-invalid": !!c,
403
+ id: d,
404
+ name: l,
405
+ disabled: o,
406
+ "aria-invalid": !!a,
432
407
  "aria-describedby": p,
433
408
  className: "pcoi-toggle__input",
434
409
  role: "switch",
@@ -438,328 +413,322 @@ const ae = _.forwardRef(
438
413
  /* @__PURE__ */ e("span", { className: "pcoi-toggle__track", "aria-hidden": "true", children: /* @__PURE__ */ e("span", { className: "pcoi-toggle__thumb" }) }),
439
414
  /* @__PURE__ */ e("span", { className: "pcoi-toggle__label", children: i })
440
415
  ] }),
441
- c && /* @__PURE__ */ e("span", { id: p, className: "pcoi-toggle__error", role: "alert", children: c })
416
+ a && /* @__PURE__ */ e("span", { id: p, className: "pcoi-toggle__error", role: "alert", children: a })
442
417
  ] });
443
418
  }
444
419
  );
445
- ae.displayName = "Toggle";
446
- const ie = _.forwardRef(
420
+ ie.displayName = "Toggle";
421
+ const ce = _.forwardRef(
447
422
  ({
448
423
  label: i,
449
- name: a,
450
- options: c,
451
- defaultValue: l,
452
- error: o,
424
+ name: l,
425
+ options: a,
426
+ defaultValue: o,
427
+ error: c,
453
428
  required: s = !1,
454
429
  disabled: r = !1,
455
- onChange: t,
430
+ onChange: d,
456
431
  className: p = "",
457
- ...d
432
+ ...t
458
433
  }, h) => {
459
- const m = o ? `pcoi-field-${a}-error` : void 0, u = [
434
+ const m = c ? `pcoi-field-${l}-error` : void 0, N = [
460
435
  "pcoi-radio-group",
461
- o ? "pcoi-radio-group--error" : "",
436
+ c ? "pcoi-radio-group--error" : "",
462
437
  r ? "pcoi-radio-group--disabled" : "",
463
438
  p
464
- ].filter(Boolean).join(" "), f = (N) => {
465
- t == null || t(N.target.value);
439
+ ].filter(Boolean).join(" "), f = (u) => {
440
+ d == null || d(u.target.value);
466
441
  };
467
442
  return /* @__PURE__ */ n(
468
443
  "fieldset",
469
444
  {
470
445
  ref: h,
471
- className: u,
472
- "aria-invalid": !!o,
446
+ className: N,
447
+ "aria-invalid": !!c,
473
448
  "aria-describedby": m,
474
- ...d,
449
+ ...t,
475
450
  children: [
476
451
  /* @__PURE__ */ n("legend", { className: "pcoi-radio-group__legend", children: [
477
452
  i,
478
453
  s && /* @__PURE__ */ e("span", { className: "pcoi-radio-group__required", "aria-hidden": "true", children: "*" })
479
454
  ] }),
480
- /* @__PURE__ */ e("div", { className: "pcoi-radio-group__options", children: c.map((N) => {
481
- const x = `pcoi-field-${a}-${N.value}`;
455
+ /* @__PURE__ */ e("div", { className: "pcoi-radio-group__options", children: a.map((u) => {
456
+ const C = `pcoi-field-${l}-${u.value}`;
482
457
  return /* @__PURE__ */ n(
483
458
  "label",
484
459
  {
485
- htmlFor: x,
460
+ htmlFor: C,
486
461
  className: "pcoi-radio-group__option",
487
462
  children: [
488
463
  /* @__PURE__ */ e(
489
464
  "input",
490
465
  {
491
466
  type: "radio",
492
- id: x,
493
- name: a,
494
- value: N.value,
495
- defaultChecked: l === N.value,
467
+ id: C,
468
+ name: l,
469
+ value: u.value,
470
+ defaultChecked: o === u.value,
496
471
  required: s,
497
- disabled: r || N.disabled,
472
+ disabled: r || u.disabled,
498
473
  onChange: f,
499
474
  className: "pcoi-radio-group__input"
500
475
  }
501
476
  ),
502
477
  /* @__PURE__ */ e("span", { className: "pcoi-radio-group__circle", "aria-hidden": "true" }),
503
- /* @__PURE__ */ e("span", { className: "pcoi-radio-group__label", children: N.label })
478
+ /* @__PURE__ */ e("span", { className: "pcoi-radio-group__label", children: u.label })
504
479
  ]
505
480
  },
506
- N.value
481
+ u.value
507
482
  );
508
483
  }) }),
509
- o && /* @__PURE__ */ e("span", { id: m, className: "pcoi-radio-group__error", role: "alert", children: o })
484
+ c && /* @__PURE__ */ e("span", { id: m, className: "pcoi-radio-group__error", role: "alert", children: c })
510
485
  ]
511
486
  }
512
487
  );
513
488
  }
514
489
  );
515
- ie.displayName = "RadioGroup";
516
- const ce = _.forwardRef(
490
+ ce.displayName = "RadioGroup";
491
+ const le = _.forwardRef(
517
492
  ({
518
493
  title: i,
519
- headingLevel: a = "h3",
520
- action: c,
521
- children: l,
522
- flush: o = !1,
494
+ headingLevel: l = "h3",
495
+ action: a,
496
+ children: o,
497
+ flush: c = !1,
523
498
  className: s = "",
524
499
  ...r
525
- }, t) => {
526
- const p = a, d = [
500
+ }, d) => {
501
+ const p = l, t = [
527
502
  "pcoi-panel",
528
- o ? "pcoi-panel--flush" : "",
503
+ c ? "pcoi-panel--flush" : "",
529
504
  s
530
505
  ].filter(Boolean).join(" ");
531
- return /* @__PURE__ */ n("div", { ref: t, className: d, ...r, children: [
532
- (i || c) && /* @__PURE__ */ n("div", { className: "pcoi-panel__header", children: [
506
+ return /* @__PURE__ */ n("div", { ref: d, className: t, ...r, children: [
507
+ (i || a) && /* @__PURE__ */ n("div", { className: "pcoi-panel__header", children: [
533
508
  i && /* @__PURE__ */ e(p, { className: "pcoi-panel__title", children: i }),
534
- c && /* @__PURE__ */ e("div", { className: "pcoi-panel__action", children: c })
509
+ a && /* @__PURE__ */ e("div", { className: "pcoi-panel__action", children: a })
535
510
  ] }),
536
- /* @__PURE__ */ e("div", { className: "pcoi-panel__body", children: l })
511
+ /* @__PURE__ */ e("div", { className: "pcoi-panel__body", children: o })
537
512
  ] });
538
513
  }
539
514
  );
540
- ce.displayName = "Panel";
515
+ le.displayName = "Panel";
541
516
  const oe = _.forwardRef(
542
517
  ({
543
518
  columns: i,
544
- rows: a,
545
- rowKey: c,
546
- emptyText: l = "No data available",
547
- ariaLabel: o,
519
+ rows: l,
520
+ rowKey: a,
521
+ emptyText: o = "No data available",
522
+ ariaLabel: c,
548
523
  className: s = "",
549
524
  ...r
550
- }, t) => {
551
- const p = (d, h) => c ? typeof c == "function" ? c(d, h) : String(d[c]) : String(h);
552
- return /* @__PURE__ */ e("div", { ref: t, className: `pcoi-data-table ${s}`, ...r, children: /* @__PURE__ */ n("table", { className: "pcoi-data-table__table", "aria-label": o, children: [
553
- /* @__PURE__ */ e("thead", { className: "pcoi-data-table__head", children: /* @__PURE__ */ e("tr", { className: "pcoi-data-table__head-row", children: i.map((d) => /* @__PURE__ */ e(
525
+ }, d) => {
526
+ const p = (t, h) => a ? typeof a == "function" ? a(t, h) : String(t[a]) : String(h);
527
+ return /* @__PURE__ */ e("div", { ref: d, className: `pcoi-data-table ${s}`, ...r, children: /* @__PURE__ */ n("table", { className: "pcoi-data-table__table", "aria-label": c, children: [
528
+ /* @__PURE__ */ e("thead", { className: "pcoi-data-table__head", children: /* @__PURE__ */ e("tr", { className: "pcoi-data-table__head-row", children: i.map((t) => /* @__PURE__ */ e(
554
529
  "th",
555
530
  {
556
- className: `pcoi-data-table__th${d.align ? ` pcoi-data-table__th--${d.align}` : ""}`,
557
- children: d.header
531
+ className: `pcoi-data-table__th${t.align ? ` pcoi-data-table__th--${t.align}` : ""}`,
532
+ children: t.header
558
533
  },
559
- d.key
534
+ t.key
560
535
  )) }) }),
561
- /* @__PURE__ */ e("tbody", { className: "pcoi-data-table__body", children: a.length === 0 ? /* @__PURE__ */ e("tr", { children: /* @__PURE__ */ e(
536
+ /* @__PURE__ */ e("tbody", { className: "pcoi-data-table__body", children: l.length === 0 ? /* @__PURE__ */ e("tr", { children: /* @__PURE__ */ e(
562
537
  "td",
563
538
  {
564
539
  colSpan: i.length,
565
540
  className: "pcoi-data-table__empty",
566
- children: l
541
+ children: o
567
542
  }
568
- ) }) : a.map((d, h) => /* @__PURE__ */ e(
543
+ ) }) : l.map((t, h) => /* @__PURE__ */ e(
569
544
  "tr",
570
545
  {
571
546
  className: "pcoi-data-table__row",
572
547
  children: i.map((m) => {
573
- const u = d[m.key];
548
+ const N = t[m.key];
574
549
  return /* @__PURE__ */ e(
575
550
  "td",
576
551
  {
577
552
  className: `pcoi-data-table__td${m.align ? ` pcoi-data-table__td--${m.align}` : ""}`,
578
- children: m.render ? m.render(u, d) : String(u ?? "")
553
+ children: m.render ? m.render(N, t) : String(N ?? "")
579
554
  },
580
555
  m.key
581
556
  );
582
557
  })
583
558
  },
584
- p(d, h)
559
+ p(t, h)
585
560
  )) })
586
561
  ] }) });
587
562
  }
588
563
  );
589
564
  oe.displayName = "DataTable";
590
- const C = _.forwardRef(
591
- ({ children: i, variant: a = "default", className: c = "", ...l }, o) => {
565
+ const R = _.forwardRef(
566
+ ({ children: i, variant: l = "default", className: a = "", ...o }, c) => {
592
567
  const s = [
593
568
  "pcoi-badge",
594
- `pcoi-badge--${a}`,
595
- c
569
+ `pcoi-badge--${l}`,
570
+ a
596
571
  ].filter(Boolean).join(" ");
597
- return /* @__PURE__ */ e("span", { ref: o, className: s, ...l, children: i });
598
- }
599
- );
600
- C.displayName = "Badge";
601
- const B = ({
602
- size: i = 24,
603
- title: a,
604
- ...c
605
- }) => /* @__PURE__ */ n(
606
- "svg",
607
- {
608
- width: i,
609
- height: i,
610
- viewBox: "0 0 24 24",
611
- fill: "none",
612
- stroke: "currentColor",
613
- strokeWidth: 1.5,
614
- strokeLinecap: "round",
615
- strokeLinejoin: "round",
616
- role: a ? "img" : "presentation",
617
- "aria-hidden": !a,
618
- xmlns: "http://www.w3.org/2000/svg",
619
- ...c,
620
- children: [
621
- a && /* @__PURE__ */ e("title", { children: a }),
622
- /* @__PURE__ */ e("line", { x1: "18", y1: "6", x2: "6", y2: "18" }),
623
- /* @__PURE__ */ e("line", { x1: "6", y1: "6", x2: "18", y2: "18" })
624
- ]
572
+ return /* @__PURE__ */ e("span", { ref: c, className: s, ...o, children: i });
625
573
  }
626
574
  );
627
- B.displayName = "CloseIcon";
628
- const D = ({
629
- open: i,
630
- onClose: a,
631
- title: c,
632
- headingLevel: l = "h2",
633
- size: o = "default",
634
- children: s,
635
- footer: r,
636
- className: t = "",
637
- ...p
638
- }) => {
639
- const d = w(null), h = w(null), m = l, u = c ? "pcoi-modal-title" : void 0, f = R(
640
- (b) => {
641
- if (b.key === "Escape") {
642
- a();
643
- return;
644
- }
645
- if (b.key === "Tab" && d.current) {
646
- const v = d.current.querySelectorAll(
647
- 'button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])'
648
- );
649
- if (v.length === 0) return;
650
- const S = v[0], j = v[v.length - 1];
651
- b.shiftKey && document.activeElement === S ? (b.preventDefault(), j.focus()) : !b.shiftKey && document.activeElement === j && (b.preventDefault(), S.focus());
652
- }
653
- },
654
- [a]
655
- );
656
- y(() => (i && (h.current = document.activeElement, document.addEventListener("keydown", f), document.body.style.overflow = "hidden", requestAnimationFrame(() => {
657
- var v;
658
- const b = (v = d.current) == null ? void 0 : v.querySelector(
659
- 'button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])'
575
+ R.displayName = "Badge";
576
+ const T = _.forwardRef(
577
+ ({
578
+ open: i,
579
+ onClose: l,
580
+ title: a,
581
+ headingLevel: o = "h2",
582
+ size: c = "default",
583
+ children: s,
584
+ footer: r,
585
+ className: d = "",
586
+ ...p
587
+ }, t) => {
588
+ const h = w(null), m = w(null), N = o, f = a ? "pcoi-modal-title" : void 0, u = $(
589
+ (b) => {
590
+ if (b.key === "Escape") {
591
+ l();
592
+ return;
593
+ }
594
+ if (b.key === "Tab" && h.current) {
595
+ const v = h.current.querySelectorAll(
596
+ 'button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])'
597
+ );
598
+ if (v.length === 0) return;
599
+ const B = v[0], S = v[v.length - 1];
600
+ b.shiftKey && document.activeElement === B ? (b.preventDefault(), S.focus()) : !b.shiftKey && document.activeElement === S && (b.preventDefault(), B.focus());
601
+ }
602
+ },
603
+ [l]
660
604
  );
661
- b == null || b.focus();
662
- })), () => {
663
- var b;
664
- document.removeEventListener("keydown", f), document.body.style.overflow = "", (b = h.current) == null || b.focus();
665
- }), [i, f]);
666
- const N = (b) => {
667
- b.target === b.currentTarget && a();
668
- };
669
- if (!i) return null;
670
- const x = ["pcoi-modal", t].filter(Boolean).join(" ");
671
- return F(
672
- /* @__PURE__ */ e("div", { className: x, onClick: N, children: /* @__PURE__ */ n(
673
- "div",
674
- {
675
- ref: d,
676
- className: `pcoi-modal__dialog${o === "wide" ? " pcoi-modal__dialog--wide" : ""}`,
677
- role: "dialog",
678
- "aria-modal": "true",
679
- "aria-labelledby": u,
680
- ...p,
681
- children: [
682
- /* @__PURE__ */ n("div", { className: "pcoi-modal__header", children: [
683
- c && /* @__PURE__ */ e(m, { id: u, className: "pcoi-modal__title", children: c }),
684
- /* @__PURE__ */ e(
685
- "button",
686
- {
687
- type: "button",
688
- className: "pcoi-modal__close",
689
- onClick: a,
690
- "aria-label": "Close modal",
691
- children: /* @__PURE__ */ e(B, { size: 20 })
692
- }
693
- )
694
- ] }),
695
- /* @__PURE__ */ e("div", { className: "pcoi-modal__body", children: s }),
696
- r && /* @__PURE__ */ e("div", { className: "pcoi-modal__footer", children: r })
697
- ]
698
- }
699
- ) }),
700
- document.body
701
- );
702
- };
703
- D.displayName = "Modal";
704
- const le = ({
705
- message: i,
706
- variant: a = "info",
707
- open: c,
708
- onClose: l,
709
- duration: o = 5e3,
710
- className: s = "",
711
- ...r
712
- }) => {
713
- const t = R(() => {
714
- l == null || l();
715
- }, [l]);
716
- if (y(() => {
717
- if (!c || o === 0) return;
718
- const d = setTimeout(t, o);
719
- return () => clearTimeout(d);
720
- }, [c, o, t]), !c) return null;
721
- const p = [
722
- "pcoi-toast",
723
- `pcoi-toast--${a}`,
724
- s
725
- ].filter(Boolean).join(" ");
726
- return F(
727
- /* @__PURE__ */ e("div", { className: p, role: "alert", ...r, children: /* @__PURE__ */ n("div", { className: "pcoi-toast__content", children: [
728
- /* @__PURE__ */ e("span", { className: "pcoi-toast__message", children: i }),
729
- l && /* @__PURE__ */ e(
730
- "button",
605
+ y(() => (i && (m.current = document.activeElement, document.addEventListener("keydown", u), document.body.style.overflow = "hidden", requestAnimationFrame(() => {
606
+ var v;
607
+ const b = (v = h.current) == null ? void 0 : v.querySelector(
608
+ 'button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])'
609
+ );
610
+ b == null || b.focus();
611
+ })), () => {
612
+ var b;
613
+ document.removeEventListener("keydown", u), document.body.style.overflow = "", (b = m.current) == null || b.focus();
614
+ }), [i, u]);
615
+ const C = (b) => {
616
+ b.target === b.currentTarget && l();
617
+ };
618
+ if (!i) return null;
619
+ const L = ["pcoi-modal", d].filter(Boolean).join(" ");
620
+ return F(
621
+ /* @__PURE__ */ e("div", { className: L, onClick: C, children: /* @__PURE__ */ n(
622
+ "div",
731
623
  {
732
- type: "button",
733
- className: "pcoi-toast__close",
734
- onClick: t,
735
- "aria-label": "Dismiss notification",
736
- children: /* @__PURE__ */ e(B, { size: 16 })
624
+ ref: h,
625
+ className: `pcoi-modal__dialog${c === "wide" ? " pcoi-modal__dialog--wide" : ""}`,
626
+ role: "dialog",
627
+ "aria-modal": "true",
628
+ "aria-labelledby": f,
629
+ ...p,
630
+ children: [
631
+ /* @__PURE__ */ n("div", { className: "pcoi-modal__header", children: [
632
+ a && /* @__PURE__ */ e(N, { id: f, className: "pcoi-modal__title", children: a }),
633
+ /* @__PURE__ */ e(
634
+ "button",
635
+ {
636
+ type: "button",
637
+ className: "pcoi-modal__close",
638
+ onClick: l,
639
+ "aria-label": "Close modal",
640
+ children: /* @__PURE__ */ e(E, { size: 20 })
641
+ }
642
+ )
643
+ ] }),
644
+ /* @__PURE__ */ e("div", { className: "pcoi-modal__body", children: s }),
645
+ r && /* @__PURE__ */ e("div", { className: "pcoi-modal__footer", children: r })
646
+ ]
737
647
  }
738
- )
739
- ] }) }),
740
- document.body
648
+ ) }),
649
+ document.body
650
+ );
651
+ }
652
+ );
653
+ T.displayName = "Modal";
654
+ const re = _.forwardRef(
655
+ ({
656
+ message: i,
657
+ variant: l = "info",
658
+ open: a,
659
+ onClose: o,
660
+ duration: c = 5e3,
661
+ className: s = "",
662
+ ...r
663
+ }, d) => {
664
+ const p = $(() => {
665
+ o == null || o();
666
+ }, [o]);
667
+ if (y(() => {
668
+ if (!a || c === 0) return;
669
+ const h = setTimeout(p, c);
670
+ return () => clearTimeout(h);
671
+ }, [a, c, p]), !a) return null;
672
+ const t = [
673
+ "pcoi-toast",
674
+ `pcoi-toast--${l}`,
675
+ s
676
+ ].filter(Boolean).join(" ");
677
+ return F(
678
+ /* @__PURE__ */ e("div", { ref: d, className: t, role: "alert", ...r, children: /* @__PURE__ */ n("div", { className: "pcoi-toast__content", children: [
679
+ /* @__PURE__ */ e("span", { className: "pcoi-toast__message", children: i }),
680
+ o && /* @__PURE__ */ e(
681
+ "button",
682
+ {
683
+ type: "button",
684
+ className: "pcoi-toast__close",
685
+ onClick: p,
686
+ "aria-label": "Dismiss notification",
687
+ children: /* @__PURE__ */ e(E, { size: 16 })
688
+ }
689
+ )
690
+ ] }) }),
691
+ document.body
692
+ );
693
+ }
694
+ );
695
+ re.displayName = "Toast";
696
+ const se = _.forwardRef(({ index: i, sourceLabel: l, className: a = "", ...o }, c) => {
697
+ const s = ["pcoi-citation-mark", a].filter(Boolean).join(" ");
698
+ return /* @__PURE__ */ e(
699
+ "button",
700
+ {
701
+ ref: c,
702
+ type: "button",
703
+ className: s,
704
+ title: l ?? `Citation ${i}`,
705
+ "aria-label": l ?? `Citation ${i}`,
706
+ ...o,
707
+ children: i
708
+ }
741
709
  );
742
- };
743
- le.displayName = "Toast";
744
- const O = _.forwardRef(({ label: i, icon: a, className: c = "", ...l }, o) => {
745
- const s = ["pcoi-suggestion-card", c].filter(Boolean).join(" ");
746
- return /* @__PURE__ */ n("button", { ref: o, type: "button", className: s, ...l, children: [
747
- a && /* @__PURE__ */ e("span", { className: "pcoi-suggestion-card__icon", children: a }),
710
+ });
711
+ se.displayName = "CitationMark";
712
+ const O = _.forwardRef(({ label: i, icon: l, className: a = "", ...o }, c) => {
713
+ const s = ["pcoi-suggestion-card", a].filter(Boolean).join(" ");
714
+ return /* @__PURE__ */ n("button", { ref: c, type: "button", className: s, ...o, children: [
715
+ l && /* @__PURE__ */ e("span", { className: "pcoi-suggestion-card__icon", children: l }),
748
716
  /* @__PURE__ */ e("span", { className: "pcoi-suggestion-card__label", children: i })
749
717
  ] });
750
718
  });
751
719
  O.displayName = "SuggestionCard";
752
- const P = _.forwardRef(
753
- ({ index: i, excerpt: a, sourceTitle: c, onSourceClick: l, className: o = "", ...s }, r) => {
754
- const t = ["pcoi-cited-excerpt", o].filter(Boolean).join(" ");
755
- return /* @__PURE__ */ n("div", { ref: r, className: t, ...s, children: [
720
+ const D = _.forwardRef(
721
+ ({ index: i, excerpt: l, sourceTitle: a, onSourceClick: o, className: c = "", ...s }, r) => {
722
+ const d = ["pcoi-cited-excerpt", c].filter(Boolean).join(" ");
723
+ return /* @__PURE__ */ n("div", { ref: r, className: d, ...s, children: [
756
724
  /* @__PURE__ */ e(
757
725
  "button",
758
726
  {
759
727
  type: "button",
760
728
  className: "pcoi-cited-excerpt__source",
761
- onClick: l,
762
- children: c
729
+ onClick: o,
730
+ "aria-label": `View source: ${a}`,
731
+ children: a
763
732
  }
764
733
  ),
765
734
  /* @__PURE__ */ n("div", { className: "pcoi-cited-excerpt__body", children: [
@@ -768,7 +737,8 @@ const P = _.forwardRef(
768
737
  {
769
738
  type: "button",
770
739
  className: "pcoi-cited-excerpt__index",
771
- onClick: l,
740
+ onClick: o,
741
+ "aria-label": `Citation ${i}, view source: ${a}`,
772
742
  children: [
773
743
  "[",
774
744
  i,
@@ -776,71 +746,44 @@ const P = _.forwardRef(
776
746
  ]
777
747
  }
778
748
  ),
779
- /* @__PURE__ */ e("p", { className: "pcoi-cited-excerpt__text", children: a })
749
+ /* @__PURE__ */ e("p", { className: "pcoi-cited-excerpt__text", children: l })
780
750
  ] })
781
751
  ] });
782
752
  }
783
753
  );
784
- P.displayName = "CitedExcerpt";
785
- const L = ({
786
- size: i = 24,
787
- title: a,
788
- ...c
789
- }) => /* @__PURE__ */ n(
790
- "svg",
791
- {
792
- width: i,
793
- height: i,
794
- viewBox: "0 0 24 24",
795
- fill: "none",
796
- stroke: "currentColor",
797
- strokeWidth: 1.5,
798
- strokeLinecap: "round",
799
- strokeLinejoin: "round",
800
- role: a ? "img" : "presentation",
801
- "aria-hidden": !a,
802
- xmlns: "http://www.w3.org/2000/svg",
803
- ...c,
804
- children: [
805
- a && /* @__PURE__ */ e("title", { children: a }),
806
- /* @__PURE__ */ e("line", { x1: "5", y1: "12", x2: "19", y2: "12" }),
807
- /* @__PURE__ */ e("polyline", { points: "12 5 19 12 12 19" })
808
- ]
809
- }
810
- );
811
- L.displayName = "ArrowRightIcon";
812
- const H = _.forwardRef(
754
+ D.displayName = "CitedExcerpt";
755
+ const P = _.forwardRef(
813
756
  ({
814
757
  value: i,
815
- onChange: a,
816
- onSubmit: c,
817
- placeholder: l = "Ask a question…",
818
- disabled: o = !1,
758
+ onChange: l,
759
+ onSubmit: a,
760
+ placeholder: o = "Ask a question…",
761
+ disabled: c = !1,
819
762
  loading: s = !1,
820
763
  className: r = "",
821
- ...t
764
+ ...d
822
765
  }, p) => {
823
- const d = w(null), h = R(
766
+ const t = w(null), h = $(
824
767
  (f) => {
825
- f.key === "Enter" && !f.shiftKey && (f.preventDefault(), i.trim() && !o && !s && c(i.trim()));
768
+ f.key === "Enter" && !f.shiftKey && (f.preventDefault(), i.trim() && !c && !s && a(i.trim()));
826
769
  },
827
- [i, o, s, c]
828
- ), m = R(() => {
829
- i.trim() && !o && !s && c(i.trim());
830
- }, [i, o, s, c]), u = ["pcoi-prompt-bar", r].filter(Boolean).join(" ");
831
- return /* @__PURE__ */ n("div", { ref: p, className: u, ...t, children: [
770
+ [i, c, s, a]
771
+ ), m = $(() => {
772
+ i.trim() && !c && !s && a(i.trim());
773
+ }, [i, c, s, a]), N = ["pcoi-prompt-bar", r].filter(Boolean).join(" ");
774
+ return /* @__PURE__ */ n("div", { ref: p, className: N, ...d, children: [
832
775
  /* @__PURE__ */ e(
833
776
  "textarea",
834
777
  {
835
- ref: d,
778
+ ref: t,
836
779
  className: "pcoi-prompt-bar__input",
837
780
  value: i,
838
- onChange: (f) => a(f.target.value),
781
+ onChange: (f) => l(f.target.value),
839
782
  onKeyDown: h,
840
- placeholder: l,
841
- disabled: o,
783
+ placeholder: o,
784
+ disabled: c,
842
785
  rows: 1,
843
- "aria-label": l
786
+ "aria-label": o
844
787
  }
845
788
  ),
846
789
  /* @__PURE__ */ e("div", { className: "pcoi-prompt-bar__actions", children: /* @__PURE__ */ e(
@@ -849,163 +792,165 @@ const H = _.forwardRef(
849
792
  variant: "primary",
850
793
  className: "pcoi-prompt-bar__send",
851
794
  onClick: m,
852
- disabled: o || s || !i.trim(),
795
+ disabled: c || s || !i.trim(),
853
796
  "aria-label": "Send message",
854
- children: /* @__PURE__ */ e("span", { className: "pcoi-prompt-bar__send-icon", children: /* @__PURE__ */ e(L, { size: 16 }) })
797
+ children: /* @__PURE__ */ e("span", { className: "pcoi-prompt-bar__send-icon", children: /* @__PURE__ */ e(Y, { size: 16 }) })
855
798
  }
856
799
  ) })
857
800
  ] });
858
801
  }
859
802
  );
860
- H.displayName = "PromptBar";
803
+ P.displayName = "PromptBar";
861
804
  const M = _.forwardRef(
862
- ({ role: i, children: a, citations: c, timestamp: l, onCitationClick: o, className: s = "", ...r }, t) => {
805
+ ({ role: i, children: l, citations: a, timestamp: o, onCitationClick: c, className: s = "", ...r }, d) => {
863
806
  const p = [
864
807
  "pcoi-chat-message",
865
808
  `pcoi-chat-message--${i}`,
866
809
  s
867
810
  ].filter(Boolean).join(" ");
868
- return /* @__PURE__ */ n("div", { ref: t, className: p, ...r, children: [
869
- /* @__PURE__ */ e("div", { className: "pcoi-chat-message__header", children: /* @__PURE__ */ e(C, { variant: i === "assistant" ? "default" : "info", children: i === "assistant" ? "PCOI" : "You" }) }),
870
- /* @__PURE__ */ e("div", { className: "pcoi-chat-message__body", children: a }),
871
- c && c.length > 0 && /* @__PURE__ */ e("div", { className: "pcoi-chat-message__citations", children: c.map((d) => /* @__PURE__ */ e(
872
- P,
811
+ return /* @__PURE__ */ n("div", { ref: d, className: p, ...r, children: [
812
+ /* @__PURE__ */ e("div", { className: "pcoi-chat-message__header", children: /* @__PURE__ */ e(R, { variant: i === "assistant" ? "default" : "info", children: i === "assistant" ? "PCOI" : "You" }) }),
813
+ /* @__PURE__ */ e("div", { className: "pcoi-chat-message__body", children: l }),
814
+ a && a.length > 0 && /* @__PURE__ */ e("div", { className: "pcoi-chat-message__citations", children: a.map((t) => /* @__PURE__ */ e(
815
+ D,
873
816
  {
874
- index: d.index,
875
- excerpt: d.excerpt,
876
- sourceTitle: d.sourceTitle,
877
- onSourceClick: () => o == null ? void 0 : o(d)
817
+ index: t.index,
818
+ excerpt: t.excerpt,
819
+ sourceTitle: t.sourceTitle,
820
+ onSourceClick: () => c == null ? void 0 : c(t)
878
821
  },
879
- d.index
822
+ t.index
880
823
  )) }),
881
- l && /* @__PURE__ */ e("time", { className: "pcoi-chat-message__timestamp", children: l })
824
+ o && /* @__PURE__ */ e("time", { className: "pcoi-chat-message__timestamp", children: o })
882
825
  ] });
883
826
  }
884
827
  );
885
828
  M.displayName = "ChatMessage";
886
- const q = _.forwardRef(({ suggestions: i, onSelect: a, className: c = "", ...l }, o) => {
887
- const s = ["pcoi-suggestion-cards", c].filter(Boolean).join(" ");
888
- return /* @__PURE__ */ e("div", { ref: o, className: s, ...l, children: i.map((r) => /* @__PURE__ */ e(
829
+ const H = _.forwardRef(({ suggestions: i, onSelect: l, className: a = "", ...o }, c) => {
830
+ const s = ["pcoi-suggestion-cards", a].filter(Boolean).join(" ");
831
+ return /* @__PURE__ */ e("div", { ref: c, className: s, ...o, children: i.map((r) => /* @__PURE__ */ e(
889
832
  O,
890
833
  {
891
834
  label: r.label,
892
835
  icon: r.icon,
893
- onClick: () => a(r)
836
+ onClick: () => l(r)
894
837
  },
895
838
  r.id
896
839
  )) });
897
840
  });
898
- q.displayName = "SuggestionCards";
899
- const A = _.forwardRef(({ children: i, className: a = "", ...c }, l) => {
900
- const o = w(null);
841
+ H.displayName = "SuggestionCards";
842
+ const q = _.forwardRef(({ children: i, className: l = "", ...a }, o) => {
843
+ const c = w(null);
901
844
  y(() => {
902
- const r = o.current;
845
+ const r = c.current;
903
846
  if (!r) return;
904
- const t = () => {
847
+ const d = () => {
905
848
  requestAnimationFrame(() => {
906
- r.scrollTop = r.scrollHeight;
849
+ const t = r.lastElementChild;
850
+ t ? t.scrollIntoView({ block: "nearest" }) : r.scrollTop = r.scrollHeight;
907
851
  });
908
- }, p = new MutationObserver(t);
909
- return p.observe(r, { childList: !0, subtree: !0 }), t(), () => p.disconnect();
852
+ }, p = new MutationObserver(d);
853
+ return p.observe(r, { childList: !0, subtree: !0 }), d(), () => p.disconnect();
910
854
  }, []);
911
- const s = ["pcoi-chat-message-list", a].filter(Boolean).join(" ");
912
- return /* @__PURE__ */ e("div", { ref: l, className: s, ...c, children: /* @__PURE__ */ e("div", { ref: o, className: "pcoi-chat-message-list__inner", children: i }) });
855
+ const s = ["pcoi-chat-message-list", l].filter(Boolean).join(" ");
856
+ return /* @__PURE__ */ e("div", { ref: o, className: s, role: "log", "aria-label": "Conversation", ...a, children: /* @__PURE__ */ e("div", { ref: c, className: "pcoi-chat-message-list__inner", children: i }) });
913
857
  });
914
- A.displayName = "ChatMessageList";
915
- const re = _.forwardRef(
916
- ({ open: i, onClose: a, title: c, sourceLabel: l, children: o, highlightId: s, highlightIndex: r, className: t = "", ...p }, d) => {
858
+ q.displayName = "ChatMessageList";
859
+ const te = _.forwardRef(
860
+ ({ open: i, onClose: l, title: a, sourceLabel: o, children: c, highlightId: s, highlightIndex: r, className: d = "", ...p }, t) => {
917
861
  const h = w(null);
918
862
  y(() => {
919
863
  i && s && h.current && requestAnimationFrame(() => {
920
- var N;
921
- const f = (N = h.current) == null ? void 0 : N.querySelector(`#${CSS.escape(s)}`);
864
+ var u;
865
+ const f = (u = h.current) == null ? void 0 : u.querySelector(`#${CSS.escape(s)}`);
922
866
  f && (f.scrollIntoView({ behavior: "smooth", block: "center" }), f.classList.add("pcoi-doc-overlay__highlight"), r !== void 0 && f.setAttribute("data-highlight-index", `[${r}]`));
923
867
  });
924
868
  }, [i, s, r]);
925
- const m = ["pcoi-doc-overlay", t].filter(Boolean).join(" "), u = l ? _.createElement(
869
+ const m = ["pcoi-doc-overlay", d].filter(Boolean).join(" "), N = o ? _.createElement(
926
870
  "div",
927
871
  { className: "pcoi-doc-overlay__source" },
928
- _.createElement(C, null, l)
872
+ _.createElement(R, null, o)
929
873
  ) : void 0;
930
874
  return _.createElement(
931
- D,
875
+ T,
932
876
  {
877
+ ref: t,
933
878
  open: i,
934
- onClose: a,
935
- title: c,
879
+ onClose: l,
880
+ title: a,
936
881
  size: "wide",
937
- footer: u,
882
+ footer: N,
938
883
  className: m,
939
884
  ...p
940
885
  },
941
886
  _.createElement(
942
887
  "div",
943
888
  { ref: h, className: "pcoi-doc-overlay__content" },
944
- o
889
+ c
945
890
  )
946
891
  );
947
892
  }
948
893
  );
949
- re.displayName = "DocumentOverlay";
950
- const W = _.forwardRef(({ label: i = "PCOI", className: a = "", ...c }, l) => {
951
- const o = ["pcoi-typing-indicator", a].filter(Boolean).join(" ");
952
- return /* @__PURE__ */ n("div", { ref: l, className: o, ...c, children: [
953
- /* @__PURE__ */ e("div", { className: "pcoi-typing-indicator__header", children: /* @__PURE__ */ e(C, { children: i }) }),
954
- /* @__PURE__ */ n("div", { className: "pcoi-typing-indicator__dots", "aria-label": "Typing", children: [
894
+ te.displayName = "DocumentOverlay";
895
+ const A = _.forwardRef(({ label: i = "PCOI", className: l = "", ...a }, o) => {
896
+ const c = ["pcoi-typing-indicator", l].filter(Boolean).join(" ");
897
+ return /* @__PURE__ */ n("div", { ref: o, className: c, role: "status", "aria-live": "polite", "aria-label": `${i} is typing`, ...a, children: [
898
+ /* @__PURE__ */ e("div", { className: "pcoi-typing-indicator__header", children: /* @__PURE__ */ e(R, { children: i }) }),
899
+ /* @__PURE__ */ n("div", { className: "pcoi-typing-indicator__dots", "aria-hidden": "true", children: [
955
900
  /* @__PURE__ */ e("span", { className: "pcoi-typing-indicator__dot" }),
956
901
  /* @__PURE__ */ e("span", { className: "pcoi-typing-indicator__dot" }),
957
902
  /* @__PURE__ */ e("span", { className: "pcoi-typing-indicator__dot" })
958
903
  ] })
959
904
  ] });
960
905
  });
961
- W.displayName = "TypingIndicator";
962
- const se = _.forwardRef(
906
+ A.displayName = "TypingIndicator";
907
+ const ne = _.forwardRef(
963
908
  ({
964
909
  messages: i,
965
- suggestions: a,
966
- promptValue: c,
967
- onPromptChange: l,
968
- onPromptSubmit: o,
910
+ suggestions: l,
911
+ promptValue: a,
912
+ onPromptChange: o,
913
+ onPromptSubmit: c,
969
914
  onSuggestionSelect: s,
970
915
  onCitationClick: r,
971
- placeholder: t,
916
+ placeholder: d,
972
917
  loading: p = !1,
973
- className: d = "",
918
+ className: t = "",
974
919
  ...h
975
920
  }, m) => {
976
- const u = i.length === 0, f = [
921
+ const N = i.length === 0, f = [
977
922
  "pcoi-chat",
978
- u ? "pcoi-chat--empty" : "",
979
- d
923
+ N ? "pcoi-chat--empty" : "",
924
+ t
980
925
  ].filter(Boolean).join(" ");
981
926
  return /* @__PURE__ */ n("div", { ref: m, className: f, ...h, children: [
982
- u ? /* @__PURE__ */ e("div", { className: "pcoi-chat__empty-state", children: a && a.length > 0 && s && /* @__PURE__ */ e("div", { className: "pcoi-chat__suggestions", children: /* @__PURE__ */ e(
983
- q,
927
+ N ? /* @__PURE__ */ e("div", { className: "pcoi-chat__empty-state", children: l && l.length > 0 && s && /* @__PURE__ */ e("div", { className: "pcoi-chat__suggestions", children: /* @__PURE__ */ e(
928
+ H,
984
929
  {
985
- suggestions: a,
930
+ suggestions: l,
986
931
  onSelect: s
987
932
  }
988
- ) }) }) : /* @__PURE__ */ n(A, { className: "pcoi-chat__messages", children: [
989
- i.map((N) => /* @__PURE__ */ e(
933
+ ) }) }) : /* @__PURE__ */ n(q, { className: "pcoi-chat__messages", "aria-live": "polite", "aria-relevant": "additions", children: [
934
+ i.map((u) => /* @__PURE__ */ e(
990
935
  M,
991
936
  {
992
- role: N.role,
993
- citations: N.citations,
994
- timestamp: N.timestamp,
937
+ role: u.role,
938
+ citations: u.citations,
939
+ timestamp: u.timestamp,
995
940
  onCitationClick: r,
996
- children: N.content
941
+ children: u.content
997
942
  },
998
- N.id
943
+ u.id
999
944
  )),
1000
- p && /* @__PURE__ */ e(W, {})
945
+ p && /* @__PURE__ */ e(A, {})
1001
946
  ] }),
1002
947
  /* @__PURE__ */ e("div", { className: "pcoi-chat__prompt", children: /* @__PURE__ */ e(
1003
- H,
948
+ P,
1004
949
  {
1005
- value: c,
1006
- onChange: l,
1007
- onSubmit: o,
1008
- placeholder: t,
950
+ value: a,
951
+ onChange: o,
952
+ onSubmit: c,
953
+ placeholder: d,
1009
954
  loading: p,
1010
955
  disabled: p
1011
956
  }
@@ -1013,36 +958,37 @@ const se = _.forwardRef(
1013
958
  ] });
1014
959
  }
1015
960
  );
1016
- se.displayName = "ChatInterface";
961
+ ne.displayName = "ChatInterface";
1017
962
  export {
1018
- C as Badge,
963
+ R as Badge,
1019
964
  k as Button,
1020
- Q as Callout,
1021
- Y as Card,
1022
- se as ChatInterface,
965
+ X as Callout,
966
+ V as Card,
967
+ ne as ChatInterface,
1023
968
  M as ChatMessage,
1024
- A as ChatMessageList,
1025
- ee as Checkbox,
1026
- P as CitedExcerpt,
1027
- G as ComparisonTable,
1028
- J as ContactForm,
969
+ q as ChatMessageList,
970
+ ae as Checkbox,
971
+ se as CitationMark,
972
+ D as CitedExcerpt,
973
+ J as ComparisonTable,
974
+ Q as ContactForm,
1029
975
  oe as DataTable,
1030
- re as DocumentOverlay,
1031
- Z as Footer,
976
+ te as DocumentOverlay,
977
+ U as Footer,
1032
978
  g as FormField,
1033
- V as HowStep,
979
+ G as HowStep,
1034
980
  I as LogoMark,
1035
- D as Modal,
1036
- K as Nav,
1037
- ce as Panel,
1038
- H as PromptBar,
1039
- ie as RadioGroup,
1040
- z as SectionHeader,
1041
- U as Select,
1042
- X as SignalsPanel,
981
+ T as Modal,
982
+ W as Nav,
983
+ le as Panel,
984
+ P as PromptBar,
985
+ ce as RadioGroup,
986
+ K as SectionHeader,
987
+ ee as Select,
988
+ Z as SignalsPanel,
1043
989
  O as SuggestionCard,
1044
- q as SuggestionCards,
1045
- le as Toast,
1046
- ae as Toggle,
1047
- W as TypingIndicator
990
+ H as SuggestionCards,
991
+ re as Toast,
992
+ ie as Toggle,
993
+ A as TypingIndicator
1048
994
  };