@crewlethq/ui 0.86.1 → 0.88.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (108) hide show
  1. package/dist/AgentHandoffPanel/index.js +1 -1
  2. package/dist/AppShell/index.js +3 -3
  3. package/dist/ArrangeList/index.js +2 -2
  4. package/dist/ArtifactBar/index.js +4 -4
  5. package/dist/AuthLayout/index.js +2 -2
  6. package/dist/AvatarPicker/index.js +1 -1
  7. package/dist/BriefCard/index.js +3 -3
  8. package/dist/Canvas/index.js +1 -1
  9. package/dist/CanvasBoard/index.js +1 -1
  10. package/dist/CanvasToolbar/index.js +1 -1
  11. package/dist/CommandPalette/index.js +1 -1
  12. package/dist/CommentThread/index.js +3 -3
  13. package/dist/ContrastHelp/index.js +1 -1
  14. package/dist/DataTable/index.js +1 -1
  15. package/dist/DataView/index.js +4 -4
  16. package/dist/DatasetSource/index.js +2 -2
  17. package/dist/DateTimePicker/index.js +3 -3
  18. package/dist/DeepWorkCard/index.js +3 -3
  19. package/dist/DeliveryReceipt/DeliveryReceipt.d.ts +85 -0
  20. package/dist/DeliveryReceipt/index.d.ts +4 -0
  21. package/dist/DeliveryReceipt/index.js +3 -0
  22. package/dist/DeliveryReceipt-RMZW2DMT.css +46 -0
  23. package/dist/DocTabsEditor/index.js +1 -1
  24. package/dist/EntityList/index.js +3 -3
  25. package/dist/FollowBanner/index.js +1 -1
  26. package/dist/HuePicker/index.js +1 -1
  27. package/dist/InlineEditor/index.js +1 -1
  28. package/dist/LinkInterstitial/index.js +3 -3
  29. package/dist/List/List.d.ts +14 -1
  30. package/dist/List/index.js +1 -1
  31. package/dist/{List-JOELBLTU.css → List-ZZF6ZHRT.css} +32 -0
  32. package/dist/ListInput/index.js +1 -1
  33. package/dist/MarkdownEditor/index.js +1 -1
  34. package/dist/MentionMenu/index.js +2 -2
  35. package/dist/Menu/index.js +1 -1
  36. package/dist/MergeConflicts/index.js +1 -1
  37. package/dist/Modal/index.js +1 -1
  38. package/dist/OpenInAppCard/index.js +4 -4
  39. package/dist/PeekRail/index.js +1 -1
  40. package/dist/PersonRow/PersonRow.d.ts +7 -0
  41. package/dist/PersonRow/index.js +1 -1
  42. package/dist/{PersonRow-V5GTPNVP.css → PersonRow-ZR6US2QJ.css} +25 -0
  43. package/dist/PresenterView/index.js +1 -1
  44. package/dist/ProposalCard/index.js +3 -3
  45. package/dist/RailList/index.js +2 -2
  46. package/dist/RefusalCard/index.js +3 -3
  47. package/dist/ResultTableCard/index.js +3 -3
  48. package/dist/RichEditor/index.js +1 -1
  49. package/dist/RoomRow/RoomRow.d.ts +41 -0
  50. package/dist/RoomRow/index.d.ts +4 -0
  51. package/dist/RoomRow/index.js +4 -0
  52. package/dist/RoomRow-3OTEY6GK.css +55 -0
  53. package/dist/SegmentedControl/index.js +1 -1
  54. package/dist/SelectionBar/index.js +1 -1
  55. package/dist/ShareDialog/index.js +1 -1
  56. package/dist/SheetColumnEditor/index.js +1 -1
  57. package/dist/SheetGrid/index.js +4 -4
  58. package/dist/SlideCompare/index.js +1 -1
  59. package/dist/SlideFilmstrip/index.js +1 -1
  60. package/dist/StatusCard/index.js +2 -2
  61. package/dist/Switch/Switch.d.ts +14 -0
  62. package/dist/Switch/index.js +2 -1
  63. package/dist/{Switch-AUYLQLTN.css → Switch-XJE34BZH.css} +15 -0
  64. package/dist/Switcher/index.js +1 -1
  65. package/dist/TableCells/index.js +2 -2
  66. package/dist/Tabs/index.js +1 -1
  67. package/dist/ThemeSwitcher/index.js +1 -1
  68. package/dist/ThreadSummary/index.js +2 -2
  69. package/dist/TimeRangePicker/index.js +1 -1
  70. package/dist/TimeWindowPicker/index.js +3 -3
  71. package/dist/TreeCanvas/index.js +1 -1
  72. package/dist/VersionCompare/index.js +1 -1
  73. package/dist/{chunk-3XDT5ZWL.js → chunk-3N3XK2G5.js} +27 -9
  74. package/dist/{chunk-M33DABTW.js → chunk-3W67EZR4.js} +1 -1
  75. package/dist/{chunk-7ELFH3RJ.js → chunk-4FZDH5U6.js} +1 -1
  76. package/dist/{chunk-EALRMP7N.js → chunk-6TD2PCZB.js} +8 -3
  77. package/dist/{chunk-XTJHMP3W.js → chunk-75EGNXPZ.js} +1 -1
  78. package/dist/{chunk-AUSFKGKL.js → chunk-7RUF3QZ2.js} +1 -1
  79. package/dist/{chunk-PS5ZYIA6.js → chunk-A7UOYLK3.js} +12 -3
  80. package/dist/{chunk-XRWHDW6F.js → chunk-FA5JAF6X.js} +1 -1
  81. package/dist/{chunk-3BRXEMYT.js → chunk-G7SAFRSJ.js} +2 -2
  82. package/dist/{chunk-2L4WHYMT.js → chunk-MHDFQCE2.js} +1 -1
  83. package/dist/{chunk-35CKF77R.js → chunk-MUV2Q5E3.js} +1 -1
  84. package/dist/chunk-NGJWRR7E.js +106 -0
  85. package/dist/{chunk-2O5CMV76.js → chunk-OIRUBOPW.js} +1 -1
  86. package/dist/{chunk-G4EHZHKM.js → chunk-QL2L7Y7Z.js} +2 -2
  87. package/dist/{chunk-XYSSFI5C.js → chunk-QYONTCIN.js} +1 -1
  88. package/dist/chunk-Z34W5TM6.js +40 -0
  89. package/dist/generated/index.d.ts +2 -0
  90. package/dist/generated/index.js +83 -81
  91. package/dist/index.js +83 -81
  92. package/dist/styles.css +182 -3
  93. package/package.json +3 -3
  94. package/dist/{Editor-5D5Z3LBQ.js → Editor-VE6T3LQL.js} +2 -2
  95. package/dist/{chunk-HKUZ2GYX.js → chunk-2OUH2HDS.js} +1 -1
  96. package/dist/{chunk-MYAARF4Z.js → chunk-7CQSTVLI.js} +1 -1
  97. package/dist/{chunk-BN5FEJL5.js → chunk-DSMRQC7G.js} +1 -1
  98. package/dist/{chunk-7K6LVM5I.js → chunk-EWJKLSMD.js} +1 -1
  99. package/dist/{chunk-QPYGJ7R7.js → chunk-F4VDXWFY.js} +1 -1
  100. package/dist/{chunk-ORONAXSF.js → chunk-FX4FJMT4.js} +1 -1
  101. package/dist/{chunk-FLW5U7YS.js → chunk-FXSCAP36.js} +1 -1
  102. package/dist/{chunk-3CALM534.js → chunk-KMAVYQYO.js} +1 -1
  103. package/dist/{chunk-REWKR3S4.js → chunk-M576OESX.js} +1 -1
  104. package/dist/{chunk-46FIBJCV.js → chunk-OM6SKOXM.js} +2 -2
  105. package/dist/{chunk-IAP7APOX.js → chunk-S3DJKSJY.js} +1 -1
  106. package/dist/{chunk-3H6OZUZ3.js → chunk-SGG3NJ7A.js} +1 -1
  107. package/dist/{chunk-T3S3D4FC.js → chunk-UPFIZO4B.js} +1 -1
  108. /package/dist/{chunk-PAGITACP.js → chunk-VNACAMDK.js} +0 -0
@@ -1,5 +1,5 @@
1
1
  import { cx } from './chunk-ODEQTPFM.js';
2
- import './PersonRow-V5GTPNVP.css';
2
+ import './PersonRow-ZR6US2QJ.css';
3
3
  import { forwardRef } from 'react';
4
4
  import { CheckGlyph, PlusGlyph } from '@crewlethq/icons/glyphs';
5
5
  import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
@@ -48,8 +48,8 @@ var PersonRow = forwardRef(function PersonRow2(props, ref) {
48
48
  }
49
49
  );
50
50
  }
51
- const { as: _as, avatar, name, tag, detail, meta, mark, density = "default", selected, onSelect, onClick, className, type = "button", ...rest } = props;
52
- return /* @__PURE__ */ jsx(
51
+ const { as: _as, avatar, name, tag, detail, meta, mark, density = "default", selected, onSelect, onClick, action, className, type = "button", ...rest } = props;
52
+ const row = /* @__PURE__ */ jsx(
53
53
  "button",
54
54
  {
55
55
  ...rest,
@@ -64,6 +64,11 @@ var PersonRow = forwardRef(function PersonRow2(props, ref) {
64
64
  children: /* @__PURE__ */ jsx(PersonRowBody, { avatar, name, tag, detail, meta, mark, density, selected })
65
65
  }
66
66
  );
67
+ if (action === void 0 || action === null) return row;
68
+ return /* @__PURE__ */ jsxs("div", { className: cx("crewlet-person-row-group", `crewlet-person-row-group--${density}`), children: [
69
+ row,
70
+ /* @__PURE__ */ jsx("span", { className: "crewlet-person-row__action", children: action })
71
+ ] });
67
72
  });
68
73
 
69
74
  export { PersonRow };
@@ -1,4 +1,4 @@
1
- import { Switch } from './chunk-3XDT5ZWL.js';
1
+ import { Switch } from './chunk-3N3XK2G5.js';
2
2
  import { useReorder } from './chunk-BVML4UVB.js';
3
3
  import { Checkbox } from './chunk-YQ7Q52XU.js';
4
4
  import { IconButton } from './chunk-UAUP6XGK.js';
@@ -9,7 +9,7 @@ import { jsx } from 'react/jsx-runtime';
9
9
  var engine = null;
10
10
  var loading = null;
11
11
  function loadEngine() {
12
- loading ??= import('./Editor-5D5Z3LBQ.js').then(
12
+ loading ??= import('./Editor-VE6T3LQL.js').then(
13
13
  (module) => {
14
14
  engine = module.Editor;
15
15
  return engine;
@@ -1,6 +1,6 @@
1
1
  import { VisuallyHidden } from './chunk-UT6CW3C7.js';
2
2
  import { cx } from './chunk-ODEQTPFM.js';
3
- import './List-JOELBLTU.css';
3
+ import './List-ZZF6ZHRT.css';
4
4
  import { createContext, useContext, Children, isValidElement, cloneElement } from 'react';
5
5
  import { CircleAlertGlyph } from '@crewlethq/icons/glyphs';
6
6
  import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
@@ -40,6 +40,8 @@ function ListItem({
40
40
  onClick,
41
41
  leading,
42
42
  trailing,
43
+ action,
44
+ note,
43
45
  tone = "default",
44
46
  dangerLabel = "Failed",
45
47
  selected = false,
@@ -98,7 +100,9 @@ function ListItem({
98
100
  } else {
99
101
  row = /* @__PURE__ */ jsx("span", { className: rowClass, children: contents(children) });
100
102
  }
101
- return /* @__PURE__ */ jsx(
103
+ const hasAction = action !== void 0 && action !== null;
104
+ const hasNote = note !== void 0 && note !== null;
105
+ return /* @__PURE__ */ jsxs(
102
106
  "li",
103
107
  {
104
108
  ...rest,
@@ -106,10 +110,15 @@ function ListItem({
106
110
  "crewlet-list__item",
107
111
  tone === "danger" && "crewlet-list__item--danger",
108
112
  selected && "crewlet-list__item--selected",
113
+ (hasAction || hasNote) && "crewlet-list__item--split",
109
114
  className
110
115
  ),
111
116
  "aria-current": interactive ? void 0 : current,
112
- children: row
117
+ children: [
118
+ row,
119
+ hasAction ? /* @__PURE__ */ jsx("span", { className: "crewlet-list__action", children: action }) : null,
120
+ hasNote ? /* @__PURE__ */ jsx("div", { className: "crewlet-list__note", children: note }) : null
121
+ ]
113
122
  }
114
123
  );
115
124
  }
@@ -1,6 +1,6 @@
1
1
  import { PageHeader } from './chunk-FPDIHEM4.js';
2
2
  import { FilterPill } from './chunk-K4LZXSKZ.js';
3
- import { DateTimePicker } from './chunk-7K6LVM5I.js';
3
+ import { DateTimePicker } from './chunk-EWJKLSMD.js';
4
4
  import { DataTable } from './chunk-WANKINXG.js';
5
5
  import { useListbox, useOptionKeys } from './chunk-YGRTX67J.js';
6
6
  import { Toolbar } from './chunk-NXFTCPF6.js';
@@ -1,6 +1,6 @@
1
- import { PersonRow } from './chunk-EALRMP7N.js';
1
+ import { PersonRow } from './chunk-6TD2PCZB.js';
2
2
  import { cx } from './chunk-ODEQTPFM.js';
3
- import './PersonRow-V5GTPNVP.css';
3
+ import './PersonRow-ZR6US2QJ.css';
4
4
  import './MentionMenu-4NAQ45S4.css';
5
5
  import { jsx, jsxs } from 'react/jsx-runtime';
6
6
 
@@ -1,6 +1,6 @@
1
1
  import { Table } from './chunk-75NQV4R4.js';
2
2
  import { DownloadButton } from './chunk-EHFQMY3B.js';
3
- import { StatusCard } from './chunk-FLW5U7YS.js';
3
+ import { StatusCard } from './chunk-FXSCAP36.js';
4
4
  import { cx } from './chunk-ODEQTPFM.js';
5
5
  import './ResultTableCard-AP355LQM.css';
6
6
  import { useState } from 'react';
@@ -1,7 +1,7 @@
1
1
  import { StepList } from './chunk-TMML7BHT.js';
2
2
  import { ReceiptStrip } from './chunk-ZWCK4N4L.js';
3
3
  import { Meter } from './chunk-RQFRRPV6.js';
4
- import { StatusCard } from './chunk-FLW5U7YS.js';
4
+ import { StatusCard } from './chunk-FXSCAP36.js';
5
5
  import { Disclosure } from './chunk-NAHA62WD.js';
6
6
  import { Spinner } from './chunk-XSPCITPN.js';
7
7
  import { cx } from './chunk-ODEQTPFM.js';
@@ -0,0 +1,106 @@
1
+ import { VisuallyHidden } from './chunk-UT6CW3C7.js';
2
+ import { cx } from './chunk-ODEQTPFM.js';
3
+ import './ChatScale-L4SIHSKL.css';
4
+ import './DeliveryReceipt-RMZW2DMT.css';
5
+ import { CheckGlyph, TriangleAlertGlyph } from '@crewlethq/icons/glyphs';
6
+ import { jsx, jsxs } from 'react/jsx-runtime';
7
+
8
+ var DELIVERY_RECEIPT_LABELS = {
9
+ reached: (who) => `Reached ${who}`,
10
+ reaches: (who) => `Will reach ${who}`,
11
+ none: "Reached no agent",
12
+ noneDraft: "Will reach no agent",
13
+ answered: (who) => `${who} answered`,
14
+ list: (names) => names.join(", "),
15
+ reason: (words) => `(${words})`,
16
+ groups: (groups) => groups.join("; "),
17
+ truncated: "Some seats were not reached"
18
+ };
19
+ function reachOf(recipients, labels) {
20
+ const order = [];
21
+ const byReason = /* @__PURE__ */ new Map();
22
+ for (const r of recipients) {
23
+ const key = r.reason ?? "";
24
+ const names = byReason.get(key);
25
+ if (names) {
26
+ names.push(r.name);
27
+ } else {
28
+ order.push(key);
29
+ byReason.set(key, [r.name]);
30
+ }
31
+ }
32
+ return labels.groups(
33
+ order.map((key) => {
34
+ const list = labels.list(byReason.get(key) ?? []);
35
+ return key ? `${list} ${labels.reason(key)}` : list;
36
+ })
37
+ );
38
+ }
39
+ function DeliveryReceipt({
40
+ recipients,
41
+ tense = "sent",
42
+ truncated = false,
43
+ hint,
44
+ announce = false,
45
+ labels: overrides,
46
+ className,
47
+ ...rest
48
+ }) {
49
+ const labels = overrides ? { ...DELIVERY_RECEIPT_LABELS, ...overrides } : DELIVERY_RECEIPT_LABELS;
50
+ const none = recipients.length === 0;
51
+ const answered = tense === "sent" ? recipients.filter((r) => r.answered).map((r) => r.name) : [];
52
+ const reach = none ? tense === "draft" ? labels.noneDraft : labels.none : (tense === "draft" ? labels.reaches : labels.reached)(
53
+ reachOf(recipients, labels)
54
+ );
55
+ const parts = [
56
+ {
57
+ key: "reach",
58
+ mark: none ? /* @__PURE__ */ jsx(TriangleAlertGlyph, { size: "xs" }) : void 0,
59
+ words: reach
60
+ }
61
+ ];
62
+ if (truncated && !none)
63
+ parts.push({ key: "truncated", words: labels.truncated });
64
+ if (answered.length > 0) {
65
+ parts.push({
66
+ key: "answered",
67
+ className: "crewlet-delivery-receipt__answered",
68
+ mark: /* @__PURE__ */ jsx(CheckGlyph, { size: "xs" }),
69
+ words: labels.answered(labels.list(answered))
70
+ });
71
+ }
72
+ if (none && hint)
73
+ parts.push({
74
+ key: "hint",
75
+ className: "crewlet-delivery-receipt__hint",
76
+ words: hint
77
+ });
78
+ return /* @__PURE__ */ jsx(
79
+ "p",
80
+ {
81
+ ...rest,
82
+ role: announce ? "status" : void 0,
83
+ "data-tense": tense,
84
+ className: cx(
85
+ "crewlet-delivery-receipt",
86
+ none && "crewlet-delivery-receipt--none",
87
+ className
88
+ ),
89
+ children: parts.map((part, i) => /* @__PURE__ */ jsxs(
90
+ "span",
91
+ {
92
+ className: cx("crewlet-delivery-receipt__part", part.className),
93
+ children: [
94
+ i > 0 ? /* @__PURE__ */ jsx("span", { className: "crewlet-delivery-receipt__dot", "aria-hidden": "true", children: "\xB7" }) : null,
95
+ part.mark ? /* @__PURE__ */ jsx("span", { className: "crewlet-delivery-receipt__mark", "aria-hidden": "true", children: part.mark }) : null,
96
+ /* @__PURE__ */ jsx("span", { children: part.words }),
97
+ i < parts.length - 1 ? /* @__PURE__ */ jsx(VisuallyHidden, { children: ". " }) : null
98
+ ]
99
+ },
100
+ part.key
101
+ ))
102
+ }
103
+ );
104
+ }
105
+
106
+ export { DELIVERY_RECEIPT_LABELS, DeliveryReceipt };
@@ -1,4 +1,4 @@
1
- import { StatusCard } from './chunk-FLW5U7YS.js';
1
+ import { StatusCard } from './chunk-FXSCAP36.js';
2
2
  import { cx } from './chunk-ODEQTPFM.js';
3
3
  import './EntityList-DT3BQLUW.css';
4
4
  import { jsx, jsxs } from 'react/jsx-runtime';
@@ -1,7 +1,7 @@
1
- import { safeHref } from './chunk-KBZO4B33.js';
2
1
  import { IconTile } from './chunk-3LI4TRUR.js';
2
+ import { safeHref } from './chunk-KBZO4B33.js';
3
3
  import { ReceiptStrip } from './chunk-ZWCK4N4L.js';
4
- import { StatusCard } from './chunk-FLW5U7YS.js';
4
+ import { StatusCard } from './chunk-FXSCAP36.js';
5
5
  import { ButtonLink, Button } from './chunk-DGXZ635L.js';
6
6
  import { cx } from './chunk-ODEQTPFM.js';
7
7
  import './OpenInAppCard-CKHCK7DO.css';
@@ -1,6 +1,6 @@
1
1
  import { SuggestionList, SuggestionRow } from './chunk-Y7PVLEZJ.js';
2
2
  import { developing } from './chunk-6C7GQOBV.js';
3
- import { StatusCard } from './chunk-FLW5U7YS.js';
3
+ import { StatusCard } from './chunk-FXSCAP36.js';
4
4
  import { StatusDot } from './chunk-CYQBDZ6M.js';
5
5
  import { Button } from './chunk-DGXZ635L.js';
6
6
  import { cx } from './chunk-ODEQTPFM.js';
@@ -0,0 +1,40 @@
1
+ import { ListItem } from './chunk-A7UOYLK3.js';
2
+ import { cx } from './chunk-ODEQTPFM.js';
3
+ import './ChatScale-L4SIHSKL.css';
4
+ import './RoomRow-3OTEY6GK.css';
5
+ import { Fragment as Fragment$1 } from 'react';
6
+ import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
7
+
8
+ function RoomRow({ href, mark, name, tags, topic, facts, className, ...rest }) {
9
+ const shown = (facts ?? []).filter((fact) => fact !== void 0 && fact !== null && fact !== false && fact !== "");
10
+ return /* @__PURE__ */ jsxs(ListItem, { ...rest, href, className: cx("crewlet-room-row", className), children: [
11
+ /* @__PURE__ */ jsxs("span", { className: "crewlet-room-row__name", children: [
12
+ /* @__PURE__ */ jsx("span", { className: "crewlet-room-row__mark", "aria-hidden": "true", children: mark }),
13
+ /* @__PURE__ */ jsx("span", { className: "crewlet-room-row__title", children: name }),
14
+ tags === void 0 || tags === null ? null : /* @__PURE__ */ jsxs(Fragment, { children: [
15
+ " ",
16
+ tags
17
+ ] })
18
+ ] }),
19
+ topic === void 0 || topic === null || topic === "" ? null : /* @__PURE__ */ jsxs(Fragment, { children: [
20
+ " ",
21
+ /* @__PURE__ */ jsx("span", { className: "crewlet-room-row__topic", children: topic })
22
+ ] }),
23
+ shown.length === 0 ? null : /* @__PURE__ */ jsxs(Fragment, { children: [
24
+ " ",
25
+ /* @__PURE__ */ jsx("span", { className: "crewlet-room-row__facts", children: shown.map((fact, index) => (
26
+ // KEYED BY PLACE: the facts are positional and drawn whole each time.
27
+ /* @__PURE__ */ jsxs(Fragment$1, { children: [
28
+ index === 0 ? null : /* @__PURE__ */ jsxs(Fragment, { children: [
29
+ " ",
30
+ /* @__PURE__ */ jsx("span", { className: "crewlet-room-row__sep", "aria-hidden": "true", children: "\xB7" }),
31
+ " "
32
+ ] }),
33
+ fact
34
+ ] }, index)
35
+ )) })
36
+ ] })
37
+ ] });
38
+ }
39
+
40
+ export { RoomRow };
@@ -80,6 +80,7 @@ export * from '../DataView/index.js';
80
80
  export * from '../DatasetSource/index.js';
81
81
  export * from '../DateTimePicker/index.js';
82
82
  export * from '../DeepWorkCard/index.js';
83
+ export * from '../DeliveryReceipt/index.js';
83
84
  export * from '../DescriptionList/index.js';
84
85
  export * from '../DiffList/index.js';
85
86
  export * from '../DiffView/index.js';
@@ -189,6 +190,7 @@ export * from '../ResultTableCard/index.js';
189
190
  export * from '../ReviewList/index.js';
190
191
  export * from '../RichEditor/index.js';
191
192
  export * from '../RichEditorMarkdown/index.js';
193
+ export * from '../RoomRow/index.js';
192
194
  export * from '../RunChip/index.js';
193
195
  export * from '../SandboxedFrame/index.js';
194
196
  export * from '../SearchTrigger/index.js';