@crewlethq/ui 0.48.2 → 0.49.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 (190) hide show
  1. package/README.md +60 -0
  2. package/dist/AgentHandoffPanel/index.js +4 -4
  3. package/dist/AppShell/index.js +4 -4
  4. package/dist/{AppShell-5P575KYA.css → AppShell-BIUFNT3J.css} +30 -11
  5. package/dist/ArrangeList/index.js +4 -4
  6. package/dist/ArtifactBar/index.js +9 -9
  7. package/dist/{ArtifactBar-6PGWGKN2.css → ArtifactBar-UMZCTARR.css} +9 -0
  8. package/dist/ArtifactCard/ArtifactCard.d.ts +30 -1
  9. package/dist/ArtifactCard/index.js +12 -5
  10. package/dist/{ArtifactCard-OGTMO2KI.css → ArtifactCard-SOB63NV5.css} +72 -1
  11. package/dist/ArtifactCover/index.js +2 -2
  12. package/dist/ArtifactIcon/index.js +2 -2
  13. package/dist/ArtifactKindGlyph/ArtifactKindGlyph.d.ts +7 -3
  14. package/dist/ArtifactKindGlyph/index.js +1 -1
  15. package/dist/ArtifactKindIllustration/ArtifactKindIllustration.d.ts +4 -3
  16. package/dist/ArtifactKindIllustration/index.js +1 -1
  17. package/dist/{ArtifactKinds-CVD3FCYO.css → ArtifactKinds-O3CALPVX.css} +1 -0
  18. package/dist/ArtifactMakeRow/index.js +2 -2
  19. package/dist/ArtifactNameCell/ArtifactNameCell.d.ts +14 -1
  20. package/dist/ArtifactNameCell/index.d.ts +1 -1
  21. package/dist/ArtifactNameCell/index.js +2 -2
  22. package/dist/{ArtifactNameCell-RTVP4LO4.css → ArtifactNameCell-3AHLUSE5.css} +12 -0
  23. package/dist/AvatarPicker/index.js +7 -7
  24. package/dist/BrandChip/BrandChip.d.ts +26 -0
  25. package/dist/BrandChip/index.d.ts +3 -0
  26. package/dist/BrandChip/index.js +2 -0
  27. package/dist/BrandChip-SQWBC2WU.css +81 -0
  28. package/dist/BrandSample/BrandSample.d.ts +75 -0
  29. package/dist/BrandSample/index.d.ts +3 -0
  30. package/dist/BrandSample/index.js +5 -0
  31. package/dist/BrandSample-G5V7GKR2.css +185 -0
  32. package/dist/BrandScope/BrandScope.d.ts +61 -0
  33. package/dist/BrandScope/index.d.ts +4 -0
  34. package/dist/BrandScope/index.js +4 -0
  35. package/dist/BrandScope-H2KZHGT7.css +29 -0
  36. package/dist/Canvas/index.js +2 -2
  37. package/dist/CanvasBoard/index.js +4 -4
  38. package/dist/CanvasToolbar/index.js +3 -3
  39. package/dist/Checkbox/Checkbox.d.ts +8 -0
  40. package/dist/Checkbox/index.js +3 -3
  41. package/dist/{Checkbox-ALWG3WV2.css → Checkbox-MB22OW6P.css} +18 -0
  42. package/dist/ColorField/ColorField.d.ts +63 -0
  43. package/dist/ColorField/index.d.ts +3 -0
  44. package/dist/ColorField/index.js +11 -0
  45. package/dist/ColorField-2OIOWT3Z.css +68 -0
  46. package/dist/ColorSwatch/ColorSwatch.d.ts +43 -0
  47. package/dist/ColorSwatch/index.d.ts +3 -0
  48. package/dist/ColorSwatch/index.js +9 -0
  49. package/dist/ColorSwatch-DNMUFHNS.css +83 -0
  50. package/dist/Combobox/Combobox.d.ts +45 -4
  51. package/dist/Combobox/index.d.ts +1 -1
  52. package/dist/Combobox/index.js +3 -3
  53. package/dist/Combobox-GBCWXWEB.css +163 -0
  54. package/dist/CommandPalette/index.js +5 -5
  55. package/dist/CommentThread/index.js +5 -5
  56. package/dist/Composer/index.js +3 -3
  57. package/dist/ConfirmField/index.js +3 -3
  58. package/dist/ContrastBadge/ContrastBadge.d.ts +63 -0
  59. package/dist/ContrastBadge/index.d.ts +3 -0
  60. package/dist/ContrastBadge/index.js +6 -0
  61. package/dist/ContrastBadge-CBZPGG3G.css +47 -0
  62. package/dist/DataGrid/DataGrid.d.ts +28 -1
  63. package/dist/DataGrid/index.js +8 -1
  64. package/dist/{DataGrid-AQKPJD7W.css → DataGrid-VNGQESJA.css} +15 -0
  65. package/dist/DataTable/index.js +6 -6
  66. package/dist/DataView/index.js +10 -10
  67. package/dist/DateTimePicker/index.js +3 -3
  68. package/dist/DocTabsEditor/index.js +4 -4
  69. package/dist/{Editor-6U4BJ25W.js → Editor-MLGK3KOG.js} +3 -3
  70. package/dist/FolderTile/FolderTile.d.ts +91 -0
  71. package/dist/FolderTile/index.d.ts +3 -0
  72. package/dist/FolderTile/index.js +7 -0
  73. package/dist/FolderTile-FDT5Y63Z.css +231 -0
  74. package/dist/HuePicker/index.js +6 -6
  75. package/dist/Input/index.js +2 -2
  76. package/dist/LinkInterstitial/index.js +3 -3
  77. package/dist/ListInput/index.js +3 -3
  78. package/dist/LogoSlot/LogoSlot.d.ts +84 -0
  79. package/dist/LogoSlot/index.d.ts +3 -0
  80. package/dist/LogoSlot/index.js +9 -0
  81. package/dist/LogoSlot-T2UFOJXU.css +159 -0
  82. package/dist/MarkdownEditor/index.js +6 -6
  83. package/dist/Menu/index.js +2 -2
  84. package/dist/MergeConflicts/index.js +6 -6
  85. package/dist/Modal/Modal.d.ts +13 -0
  86. package/dist/Modal/index.js +2 -2
  87. package/dist/{Modal-TOEWHDCQ.css → Modal-3HMP7WAZ.css} +30 -0
  88. package/dist/OrgTable/index.js +1 -1
  89. package/dist/PresenterView/index.js +3 -3
  90. package/dist/PrincipalPicker/index.js +4 -4
  91. package/dist/RichEditor/index.js +1 -1
  92. package/dist/SegmentedControl/index.js +5 -5
  93. package/dist/Select/index.js +2 -2
  94. package/dist/SelectionBar/SelectionBar.d.ts +50 -0
  95. package/dist/SelectionBar/index.d.ts +3 -0
  96. package/dist/SelectionBar/index.js +9 -0
  97. package/dist/SelectionBar-XPWKUOSC.css +61 -0
  98. package/dist/ShareDialog/index.js +6 -6
  99. package/dist/SheetColumnEditor/index.js +10 -10
  100. package/dist/SheetGrid/index.js +4 -4
  101. package/dist/SlideFilmstrip/index.js +3 -3
  102. package/dist/Switcher/index.js +4 -4
  103. package/dist/Tabs/index.js +4 -4
  104. package/dist/TagsInput/index.js +2 -2
  105. package/dist/ThemeGallery/ThemeGallery.d.ts +13 -2
  106. package/dist/ThemeGallery/index.js +3 -1
  107. package/dist/{ThemeGallery-X35Y25EX.css → ThemeGallery-UEFZRT6W.css} +21 -0
  108. package/dist/ThemeSwitcher/index.js +6 -6
  109. package/dist/TimeWindowPicker/index.js +6 -6
  110. package/dist/TreeCanvas/index.js +3 -3
  111. package/dist/TreeGrid/index.js +1 -1
  112. package/dist/TypeSpecimen/TypeSpecimen.d.ts +49 -0
  113. package/dist/TypeSpecimen/index.d.ts +3 -0
  114. package/dist/TypeSpecimen/index.js +3 -0
  115. package/dist/TypeSpecimen-WK6YNHL7.css +96 -0
  116. package/dist/VersionCompare/index.js +6 -6
  117. package/dist/{chunk-RBUA7ZNK.js → chunk-34RMTXDZ.js} +1 -1
  118. package/dist/{chunk-YFUG6ARA.js → chunk-3QSKDZR5.js} +1 -1
  119. package/dist/chunk-5SGHW42B.js +23 -0
  120. package/dist/{chunk-R2EOET5Q.js → chunk-627KFRON.js} +2 -2
  121. package/dist/{chunk-SMVWDO72.js → chunk-6FVGSWLS.js} +1 -1
  122. package/dist/{chunk-ILDNJHRU.js → chunk-AVL52EME.js} +1 -1
  123. package/dist/chunk-B235ANDO.js +66 -0
  124. package/dist/{chunk-MZ3QFQDL.js → chunk-CAVWDJF4.js} +1 -1
  125. package/dist/{chunk-BLQRC7QR.js → chunk-D6MTBXAJ.js} +2 -2
  126. package/dist/{chunk-2MYSESZF.js → chunk-FB5CFQTG.js} +82 -12
  127. package/dist/{chunk-KNMQS3JY.js → chunk-GHY63X4C.js} +1 -1
  128. package/dist/{chunk-DY4DQ7EB.js → chunk-GP4YWZFO.js} +1 -1
  129. package/dist/{chunk-NRWJUGNA.js → chunk-H55D66IK.js} +1 -1
  130. package/dist/{chunk-JNFTFAPN.js → chunk-H7NMJ5AI.js} +2 -2
  131. package/dist/{chunk-GKRPPSWY.js → chunk-ILFEWRLG.js} +1 -1
  132. package/dist/chunk-ITI2Z44C.js +139 -0
  133. package/dist/{chunk-P5VGSVWG.js → chunk-J24Q4HTD.js} +17 -8
  134. package/dist/{chunk-2FDTSARB.js → chunk-JFDIMO3A.js} +2 -2
  135. package/dist/chunk-JKAFEFFC.js +44 -0
  136. package/dist/{chunk-6HYPQ5PY.js → chunk-JWNYI7UD.js} +1 -1
  137. package/dist/{chunk-WT5UPL6P.js → chunk-KHZYAEGZ.js} +1 -1
  138. package/dist/chunk-M4QM477B.js +80 -0
  139. package/dist/{chunk-YUDUYMZB.js → chunk-MIEBOO7Y.js} +2 -2
  140. package/dist/{chunk-IVA7ZWDS.js → chunk-NAWUXCBC.js} +5 -5
  141. package/dist/{chunk-YUAQSWNW.js → chunk-NCHKKYPQ.js} +6 -3
  142. package/dist/chunk-OCRVY42T.js +50 -0
  143. package/dist/chunk-OEEYL2CM.js +73 -0
  144. package/dist/chunk-P3OIM6OC.js +38 -0
  145. package/dist/{chunk-FWBKMPNR.js → chunk-P3QWT5VR.js} +1 -1
  146. package/dist/chunk-P5JBDHWC.js +206 -0
  147. package/dist/{chunk-WQJSOTEO.js → chunk-PGR2PKH6.js} +1 -1
  148. package/dist/{chunk-U2XAJONO.js → chunk-Q44X36QC.js} +80 -36
  149. package/dist/{chunk-R2IBCEU6.js → chunk-R3BA3C4Y.js} +2 -2
  150. package/dist/{chunk-HDMLHJFI.js → chunk-R6R2UHVG.js} +4 -4
  151. package/dist/{chunk-VBEMIZIJ.js → chunk-RFPCHMSX.js} +1 -1
  152. package/dist/{chunk-CE2THTQR.js → chunk-RSKW25Y5.js} +4 -3
  153. package/dist/{chunk-UBZDYOCA.js → chunk-RV6XB5UV.js} +12 -1
  154. package/dist/{chunk-LXCRHVMZ.js → chunk-SEPSXOGJ.js} +1 -1
  155. package/dist/{chunk-K2FNW3MK.js → chunk-SQ4JFHO7.js} +1 -1
  156. package/dist/{chunk-F45VSK2M.js → chunk-SS4XCUUJ.js} +2 -2
  157. package/dist/{chunk-E4BOVKNJ.js → chunk-UTESMBPL.js} +5 -3
  158. package/dist/chunk-UZMNR366.js +9 -0
  159. package/dist/{chunk-GQXVLFQB.js → chunk-V7GOOXPK.js} +1 -1
  160. package/dist/{chunk-KMNY3KEB.js → chunk-VBIM6HFC.js} +2 -2
  161. package/dist/{chunk-Z5RZXVQ7.js → chunk-VN47PYUF.js} +7 -7
  162. package/dist/{chunk-CNTBUK24.js → chunk-VP2ODUCC.js} +2 -2
  163. package/dist/{chunk-VIAQW6RK.js → chunk-VTSJMDGP.js} +5 -5
  164. package/dist/chunk-W6FOEBIL.js +119 -0
  165. package/dist/chunk-WLSEAIVC.js +48 -0
  166. package/dist/{chunk-DETVVKAH.js → chunk-WQ7S7CKZ.js} +3 -3
  167. package/dist/{chunk-OKUULQ22.js → chunk-WXOYHVWG.js} +2 -2
  168. package/dist/{chunk-NILOJV62.js → chunk-X4NIE7CI.js} +1 -1
  169. package/dist/{chunk-PZZHO6OS.js → chunk-XS2FJVMT.js} +1 -1
  170. package/dist/{chunk-6AKG2VLR.js → chunk-YCC2S7DF.js} +4 -1
  171. package/dist/{chunk-5CLWBPB5.js → chunk-ZCIL5IHU.js} +1 -1
  172. package/dist/chunk-ZH77BXMA.js +14 -0
  173. package/dist/generated/index.d.ts +10 -0
  174. package/dist/generated/index.js +101 -89
  175. package/dist/index.js +101 -89
  176. package/dist/styles.css +1370 -22
  177. package/dist/utils/fontFamily.d.ts +29 -0
  178. package/dist/utils/hexColour.d.ts +12 -0
  179. package/package.json +3 -3
  180. package/scripts/check-css-variables.mjs +18 -2
  181. package/dist/Combobox-YDONYDTM.css +0 -81
  182. package/dist/chunk-LOBV4QON.js +0 -137
  183. package/dist/{chunk-245IXG5P.js → chunk-3WMOEGEL.js} +0 -0
  184. package/dist/{chunk-ICPQIAD6.js → chunk-D7Q5MQRF.js} +1 -1
  185. package/dist/{chunk-ISDEXIXH.js → chunk-E6HXFFWO.js} +1 -1
  186. package/dist/{chunk-D4EOPIFL.js → chunk-EXRRTKWT.js} +1 -1
  187. package/dist/{chunk-S6J3EWDP.js → chunk-SXBJMBSV.js} +1 -1
  188. package/dist/{chunk-3JIZ2A6K.js → chunk-TMM32U7D.js} +1 -1
  189. package/dist/{chunk-LD3GEVQU.js → chunk-XQZ6EWOE.js} +1 -1
  190. package/dist/{chunk-K77LKW3X.js → chunk-ZFM5L7M4.js} +2 -2
@@ -1,7 +1,7 @@
1
1
  import { SlideStage } from './chunk-RMEBFYL7.js';
2
2
  import { useReorder } from './chunk-XJ2QEBMM.js';
3
3
  import { Kbd, isApplePlatform } from './chunk-SMBKXWML.js';
4
- import { Menu } from './chunk-3JIZ2A6K.js';
4
+ import { Menu } from './chunk-TMM32U7D.js';
5
5
  import { VisuallyHidden } from './chunk-BZFWDIV6.js';
6
6
  import { cx } from './chunk-ODEQTPFM.js';
7
7
  import './SlideFilmstrip-PAT7P4OG.css';
@@ -1,6 +1,6 @@
1
1
  import { Toolbar } from './chunk-NR4CPM4T.js';
2
- import { SegmentedControl } from './chunk-SMVWDO72.js';
3
- import { tabId } from './chunk-GKRPPSWY.js';
2
+ import { SegmentedControl } from './chunk-6FVGSWLS.js';
3
+ import { tabId } from './chunk-ILFEWRLG.js';
4
4
  import { IconButton } from './chunk-LACA4JGC.js';
5
5
  import { cx } from './chunk-ODEQTPFM.js';
6
6
  import './MarkdownEditor-WOKV7CLK.css';
@@ -1,8 +1,9 @@
1
1
  import { ThemeSwatch } from './chunk-MNFU2RNT.js';
2
+ import { Tag } from './chunk-KYIAFNU7.js';
2
3
  import { useHighlightRest } from './chunk-7KHM2FZH.js';
3
4
  import { useRoving, tabStop } from './chunk-EGMQURBR.js';
4
5
  import { cx } from './chunk-ODEQTPFM.js';
5
- import './ThemeGallery-X35Y25EX.css';
6
+ import './ThemeGallery-UEFZRT6W.css';
6
7
  import { useId } from 'react';
7
8
  import { themeGroups, themeRegistry } from '@crewlethq/tokens';
8
9
  import { CheckGlyph } from '@crewlethq/icons/glyphs';
@@ -69,7 +70,7 @@ function ThemeGallery({
69
70
  type: "button",
70
71
  role: "radio",
71
72
  "aria-checked": chosen,
72
- "aria-label": `${theme.name}, ${theme.tag}`,
73
+ "aria-label": theme.tag ? `${theme.name}, ${theme.tag}` : theme.name,
73
74
  "aria-describedby": section.group ? headingId : void 0,
74
75
  tabIndex: at === stop ? 0 : -1,
75
76
  disabled,
@@ -83,7 +84,8 @@ function ThemeGallery({
83
84
  /* @__PURE__ */ jsxs("span", { className: "crewlet-theme-gallery__label", children: [
84
85
  /* @__PURE__ */ jsx("span", { className: "crewlet-theme-gallery__name", children: theme.name }),
85
86
  chosen ? /* @__PURE__ */ jsx(CheckGlyph, { size: "xs", className: "crewlet-theme-gallery__check", "aria-hidden": "true" }) : null
86
- ] })
87
+ ] }),
88
+ theme.tag && theme.tagTone ? theme.tagTone === "brand" ? /* @__PURE__ */ jsx("span", { className: "crewlet-theme-gallery__tag crewlet-theme-gallery__tag--brand", children: /* @__PURE__ */ jsx(Tag, { size: "xs", variant: "brand", children: theme.tag }) }) : /* @__PURE__ */ jsx("span", { className: "crewlet-theme-gallery__tag", title: theme.tag, children: theme.tag }) : null
87
89
  ]
88
90
  },
89
91
  theme.id
@@ -0,0 +1,9 @@
1
+ import { parseHex } from '@crewlethq/tokens';
2
+
3
+ // src/utils/hexColour.ts
4
+ function normalizeHex(value) {
5
+ if (typeof value !== "string") return null;
6
+ return parseHex(value) === null ? null : value.trim().toLowerCase();
7
+ }
8
+
9
+ export { normalizeHex };
@@ -1,7 +1,7 @@
1
1
  import { Timeline } from './chunk-AUQPBL4O.js';
2
2
  import { Section } from './chunk-JQ7IFSF6.js';
3
3
  import { Disclosure } from './chunk-OGXHZHRX.js';
4
- import { Composer } from './chunk-KNMQS3JY.js';
4
+ import { Composer } from './chunk-GHY63X4C.js';
5
5
  import { ArtifactPanel } from './chunk-NBDN5JZV.js';
6
6
  import { Button } from './chunk-OG6CL3EB.js';
7
7
  import { cx } from './chunk-ODEQTPFM.js';
@@ -1,9 +1,9 @@
1
- import { Modal } from './chunk-6AKG2VLR.js';
1
+ import { Modal } from './chunk-YCC2S7DF.js';
2
2
  import { useListbox, useOptionKeys } from './chunk-7KHM2FZH.js';
3
3
  import { Popover } from './chunk-KHJIEPZV.js';
4
4
  import { KeyChip, highlightMatch } from './chunk-FYTIJM2T.js';
5
5
  import { Skeleton } from './chunk-TEUQWOWZ.js';
6
- import { Input } from './chunk-D4EOPIFL.js';
6
+ import { Input } from './chunk-EXRRTKWT.js';
7
7
  import { announce } from './chunk-RSAQOKH3.js';
8
8
  import { useMediaMatch } from './chunk-RTPQDNW3.js';
9
9
  import { focusables, isComposing } from './chunk-H5XTJ7GJ.js';
@@ -1,14 +1,14 @@
1
- import { SegmentedControl } from './chunk-SMVWDO72.js';
2
1
  import { Tooltip } from './chunk-I33UIUZD.js';
3
- import { ArtifactIcon } from './chunk-ILDNJHRU.js';
2
+ import { SegmentedControl } from './chunk-6FVGSWLS.js';
3
+ import { ArtifactIcon } from './chunk-AVL52EME.js';
4
4
  import { isApplePlatform, Kbd } from './chunk-SMBKXWML.js';
5
- import { Menu } from './chunk-3JIZ2A6K.js';
5
+ import { Menu } from './chunk-TMM32U7D.js';
6
6
  import { Button } from './chunk-OG6CL3EB.js';
7
- import { returnFocus } from './chunk-NUZHC6MM.js';
8
7
  import { IconButton } from './chunk-LACA4JGC.js';
8
+ import { returnFocus } from './chunk-NUZHC6MM.js';
9
9
  import { cx } from './chunk-ODEQTPFM.js';
10
- import './ArtifactKinds-CVD3FCYO.css';
11
- import './ArtifactBar-6PGWGKN2.css';
10
+ import './ArtifactKinds-O3CALPVX.css';
11
+ import './ArtifactBar-UMZCTARR.css';
12
12
  import { useId, useState, useRef, useEffect } from 'react';
13
13
  import { ChevronLeftGlyph, EllipsisGlyph, ChevronDownGlyph } from '@crewlethq/icons/glyphs';
14
14
  import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
@@ -250,7 +250,7 @@ function BarTitle({
250
250
  el?.select();
251
251
  }, [editing]);
252
252
  if (onRename === void 0) {
253
- return /* @__PURE__ */ jsx(Heading, { id, className: "crewlet-artifact-bar__title", title, children: title });
253
+ return /* @__PURE__ */ jsx(Heading, { id, className: "crewlet-artifact-bar__title", title, children: /* @__PURE__ */ jsx("span", { className: "crewlet-artifact-bar__text", children: title }) });
254
254
  }
255
255
  const finish = (refocus) => {
256
256
  settled.current = true;
@@ -1,6 +1,6 @@
1
1
  import { Note } from './chunk-5SZGKSGL.js';
2
- import { CanvasToolbar, toolForKey } from './chunk-NILOJV62.js';
3
- import { IDENTITY_VIEW, Canvas } from './chunk-ICPQIAD6.js';
2
+ import { CanvasToolbar, toolForKey } from './chunk-X4NIE7CI.js';
3
+ import { IDENTITY_VIEW, Canvas } from './chunk-D7Q5MQRF.js';
4
4
  import { IconButton } from './chunk-LACA4JGC.js';
5
5
  import { cx } from './chunk-ODEQTPFM.js';
6
6
  import './CanvasBoard-JMYNIAHK.css';
@@ -1,11 +1,11 @@
1
- import { Select } from './chunk-LD3GEVQU.js';
1
+ import { Select } from './chunk-XQZ6EWOE.js';
2
2
  import { SHEET_LABELS, SHEET_COLUMN_TYPES, optionHue, retypeColumn } from './chunk-LFSIKGRQ.js';
3
- import { HueSwatch } from './chunk-RBUA7ZNK.js';
3
+ import { HueSwatch } from './chunk-34RMTXDZ.js';
4
4
  import { NODE_HUES, NODE_HUE_NAMES } from './chunk-AYKXMIOR.js';
5
- import { Checkbox } from './chunk-YUAQSWNW.js';
5
+ import { Checkbox } from './chunk-NCHKKYPQ.js';
6
6
  import { Kbd } from './chunk-SMBKXWML.js';
7
- import { FormField, Input } from './chunk-D4EOPIFL.js';
8
- import { Menu } from './chunk-3JIZ2A6K.js';
7
+ import { FormField, Input } from './chunk-EXRRTKWT.js';
8
+ import { Menu } from './chunk-TMM32U7D.js';
9
9
  import { Button } from './chunk-OG6CL3EB.js';
10
10
  import { IconButton } from './chunk-LACA4JGC.js';
11
11
  import { VisuallyHidden } from './chunk-BZFWDIV6.js';
@@ -0,0 +1,119 @@
1
+ import { normalizeHex } from './chunk-UZMNR366.js';
2
+ import { FormField, Input } from './chunk-EXRRTKWT.js';
3
+ import { cx } from './chunk-ODEQTPFM.js';
4
+ import './ColorField-2OIOWT3Z.css';
5
+ import { useId, useState } from 'react';
6
+ import { jsx, jsxs } from 'react/jsx-runtime';
7
+
8
+ var LABELS = {
9
+ invalid: "Enter the colour as # and six hex digits, such as #5b3df5.",
10
+ missing: "Choose a colour.",
11
+ picker: (label) => `Pick the ${label} colour`,
12
+ placeholder: "#rrggbb"
13
+ };
14
+ var PICKER_START = "#000000";
15
+ function ColorField({
16
+ label,
17
+ value,
18
+ onChange,
19
+ required = false,
20
+ optional,
21
+ helper,
22
+ error,
23
+ disabled = false,
24
+ name,
25
+ id,
26
+ className,
27
+ labels
28
+ }) {
29
+ const text = { ...LABELS, ...labels };
30
+ const autoId = useId();
31
+ const fieldId = id ?? autoId;
32
+ const committed = normalizeHex(value) ?? "";
33
+ const [draft, setDraft] = useState(committed);
34
+ const [seen, setSeen] = useState(committed);
35
+ const [left, setLeft] = useState(false);
36
+ if (committed !== seen) {
37
+ setSeen(committed);
38
+ if ((normalizeHex(draft) ?? "") !== committed) {
39
+ setDraft(committed);
40
+ setLeft(false);
41
+ }
42
+ }
43
+ const typed = draft.trim();
44
+ const reads = normalizeHex(typed);
45
+ const refusal = typed === "" ? required ? text.missing : null : reads === null ? text.invalid : null;
46
+ const shown = error ?? (left ? refusal : null);
47
+ const swatch = reads ?? (typed === "" ? null : committed || null);
48
+ const take = (next) => {
49
+ setDraft(next);
50
+ const colour = normalizeHex(next);
51
+ if (colour !== null) onChange(colour);
52
+ else if (next.trim() === "" && !required) onChange("");
53
+ };
54
+ const settle = () => {
55
+ setLeft(true);
56
+ if (reads !== null && reads !== draft) setDraft(reads);
57
+ };
58
+ return /* @__PURE__ */ jsx(
59
+ FormField,
60
+ {
61
+ label,
62
+ htmlFor: fieldId,
63
+ required,
64
+ optional,
65
+ helper,
66
+ error: shown ?? void 0,
67
+ className: cx("crewlet-color-field", className),
68
+ children: (field) => /* @__PURE__ */ jsxs("span", { className: "crewlet-color-field__row", children: [
69
+ /* @__PURE__ */ jsx(
70
+ "span",
71
+ {
72
+ className: cx("crewlet-color-field__swatch", swatch === null && "is-empty", disabled && "is-disabled"),
73
+ style: swatch ? { "--crewlet-color-field-value": swatch } : void 0,
74
+ children: /* @__PURE__ */ jsx(
75
+ "input",
76
+ {
77
+ type: "color",
78
+ className: "crewlet-color-field__picker",
79
+ value: swatch ?? PICKER_START,
80
+ disabled,
81
+ "aria-label": text.picker(label),
82
+ onChange: (event) => {
83
+ setLeft(true);
84
+ take(event.target.value);
85
+ }
86
+ }
87
+ )
88
+ }
89
+ ),
90
+ /* @__PURE__ */ jsx(
91
+ Input,
92
+ {
93
+ id: field.id,
94
+ name,
95
+ appearance: "reference",
96
+ width: "sm",
97
+ value: draft,
98
+ placeholder: text.placeholder,
99
+ maxLength: 9,
100
+ spellCheck: false,
101
+ autoComplete: "off",
102
+ autoCapitalize: "off",
103
+ disabled,
104
+ error: Boolean(shown),
105
+ "aria-describedby": field.describedBy,
106
+ "aria-required": required || void 0,
107
+ onChange: (event) => take(event.target.value),
108
+ onBlur: settle,
109
+ onKeyDown: (event) => {
110
+ if (event.key === "Enter") settle();
111
+ }
112
+ }
113
+ )
114
+ ] })
115
+ }
116
+ );
117
+ }
118
+
119
+ export { ColorField };
@@ -0,0 +1,48 @@
1
+ import { Copyable } from './chunk-7SHAFLEX.js';
2
+ import { normalizeHex } from './chunk-UZMNR366.js';
3
+ import { cx } from './chunk-ODEQTPFM.js';
4
+ import './ColorSwatch-DNMUFHNS.css';
5
+ import { jsxs, jsx } from 'react/jsx-runtime';
6
+
7
+ var LABELS = {
8
+ copy: (name) => `Copy the ${name} colour`,
9
+ copied: (hex) => `${hex} copied to the clipboard`,
10
+ failed: "The browser refused the clipboard",
11
+ empty: "Not set"
12
+ };
13
+ function ColorSwatch({
14
+ name,
15
+ value,
16
+ description,
17
+ copyable = true,
18
+ size = "md",
19
+ className,
20
+ labels
21
+ }) {
22
+ const text = { ...LABELS, ...labels };
23
+ const hex = normalizeHex(value);
24
+ const chip = hex ? { "--crewlet-color-swatch-value": hex } : void 0;
25
+ return /* @__PURE__ */ jsxs("div", { className: cx("crewlet-color-swatch", `crewlet-color-swatch--${size}`, className), children: [
26
+ /* @__PURE__ */ jsx("span", { className: cx("crewlet-color-swatch__chip", !hex && "is-empty"), style: chip, "aria-hidden": "true" }),
27
+ /* @__PURE__ */ jsxs("span", { className: "crewlet-color-swatch__words", children: [
28
+ /* @__PURE__ */ jsx("span", { className: "crewlet-color-swatch__name", children: name }),
29
+ description ? /* @__PURE__ */ jsx("span", { className: "crewlet-color-swatch__description", children: description }) : null,
30
+ hex ? copyable ? /* @__PURE__ */ jsx(
31
+ Copyable,
32
+ {
33
+ variant: "inline",
34
+ monospace: true,
35
+ value: hex,
36
+ ariaLabel: text.copy(name),
37
+ title: text.copy(name),
38
+ copiedMessage: text.copied(hex),
39
+ failedMessage: text.failed,
40
+ failedResetMs: null,
41
+ className: "crewlet-color-swatch__value"
42
+ }
43
+ ) : /* @__PURE__ */ jsx("span", { className: "crewlet-color-swatch__value crewlet-color-swatch__value--plain", children: hex }) : /* @__PURE__ */ jsx("span", { className: "crewlet-color-swatch__empty", children: text.empty })
44
+ ] })
45
+ ] });
46
+ }
47
+
48
+ export { ColorSwatch };
@@ -1,9 +1,9 @@
1
+ import { Modal } from './chunk-YCC2S7DF.js';
1
2
  import { useClipboard } from './chunk-STJ7QBC3.js';
2
- import { Modal } from './chunk-6AKG2VLR.js';
3
- import { Checkbox } from './chunk-YUAQSWNW.js';
4
3
  import { EmptyValue } from './chunk-EUCC37WY.js';
5
4
  import { useCardHeaderSlot } from './chunk-AV2DXAEL.js';
6
- import { Menu } from './chunk-3JIZ2A6K.js';
5
+ import { Checkbox } from './chunk-NCHKKYPQ.js';
6
+ import { Menu } from './chunk-TMM32U7D.js';
7
7
  import { Button } from './chunk-OG6CL3EB.js';
8
8
  import { IconButton } from './chunk-LACA4JGC.js';
9
9
  import { VisuallyHidden } from './chunk-BZFWDIV6.js';
@@ -6,10 +6,10 @@ import { ChangeMark } from './chunk-66X5WDKE.js';
6
6
  import { isEmptyValue, displayText, ratingMax, findPerson, findOption, statusTone, editText, textMax, sheetLabels, normalizeValue, sameValue, spokenText, drawnColumns, fitSamples, fittedWidth, columnWidth, SHEET_COLUMN_BOUNDS, sortRows, SHEET_ROW_HEIGHT, cellKey, columnOffsets, SHEET_ROW_NUMBER_WIDTH, rangeOf, presenceByCell, presenceByRow, presenceByColumn, scrollToRow, planClear, visibleRows, cellDescription, nextSort, rowName, inRange, hasPrevious, flagText, toTSV, planPaste, parseTSV, isMod, moveFrom, isTypingKey, editorSide, optionHue, parseText, liveOptions, checkValue } from './chunk-LFSIKGRQ.js';
7
7
  import { presenceLabels } from './chunk-Z7JYG5TF.js';
8
8
  import { Popover } from './chunk-KHJIEPZV.js';
9
- import { StatusDot } from './chunk-WIATRXEJ.js';
10
9
  import { Tooltip } from './chunk-I33UIUZD.js';
10
+ import { StatusDot } from './chunk-WIATRXEJ.js';
11
11
  import { Avatar } from './chunk-PZKHBB7D.js';
12
- import { Menu } from './chunk-3JIZ2A6K.js';
12
+ import { Menu } from './chunk-TMM32U7D.js';
13
13
  import { Button } from './chunk-OG6CL3EB.js';
14
14
  import { isComposing } from './chunk-H5XTJ7GJ.js';
15
15
  import { IconButton } from './chunk-LACA4JGC.js';
@@ -1,5 +1,5 @@
1
1
  import { Toolbar } from './chunk-NR4CPM4T.js';
2
- import { ShortcutTip } from './chunk-ICPQIAD6.js';
2
+ import { ShortcutTip } from './chunk-D7Q5MQRF.js';
3
3
  import { IconButton } from './chunk-LACA4JGC.js';
4
4
  import { cx } from './chunk-ODEQTPFM.js';
5
5
  import './CanvasToolbar-EM5EVZED.css';
@@ -1,4 +1,4 @@
1
- import { SegmentedControl } from './chunk-SMVWDO72.js';
1
+ import { SegmentedControl } from './chunk-6FVGSWLS.js';
2
2
  import { Button } from './chunk-OG6CL3EB.js';
3
3
  import { cx } from './chunk-ODEQTPFM.js';
4
4
  import './MergeConflicts-O44ESH4T.css';
@@ -4,7 +4,7 @@ import { Button } from './chunk-OG6CL3EB.js';
4
4
  import { focusables, useModalLayer, useBodyScrollLock } from './chunk-H5XTJ7GJ.js';
5
5
  import { IconButton } from './chunk-LACA4JGC.js';
6
6
  import { cx } from './chunk-ODEQTPFM.js';
7
- import './Modal-TOEWHDCQ.css';
7
+ import './Modal-3HMP7WAZ.css';
8
8
  import { useId, useRef, useCallback } from 'react';
9
9
  import { createPortal } from 'react-dom';
10
10
  import { ChevronLeftGlyph, XGlyph } from '@crewlethq/icons/glyphs';
@@ -42,6 +42,7 @@ function ModalFrame({
42
42
  variant = "dialog",
43
43
  shape = "framed",
44
44
  placement,
45
+ phoneSheet = false,
45
46
  role = "dialog",
46
47
  dismissable = true,
47
48
  closeOnBackdrop = true,
@@ -65,6 +66,7 @@ function ModalFrame({
65
66
  const banded = !prompt;
66
67
  const sheet = variant === "sheet";
67
68
  const place = placement ?? (prompt ? "center" : "top");
69
+ const phone = phoneSheet && variant === "dialog" && !prompt;
68
70
  const frame = useRef(null);
69
71
  const body = useRef(null);
70
72
  const foot = useRef(null);
@@ -184,6 +186,7 @@ function ModalFrame({
184
186
  "crewlet-modal-overlay",
185
187
  `crewlet-modal-overlay--${variant}`,
186
188
  `crewlet-modal-overlay--${place}`,
189
+ phone && "crewlet-modal-overlay--phone-sheet",
187
190
  backdrop === "clear" && "crewlet-modal-overlay--clear",
188
191
  // Fixed against the window, absolute inside a LayerHost: a fullscreen
189
192
  // container paints only its own subtree, so a surface drawn there
@@ -1,5 +1,5 @@
1
1
  import { InlineCode } from './chunk-5CLW2CXT.js';
2
- import { FormField, Input } from './chunk-D4EOPIFL.js';
2
+ import { FormField, Input } from './chunk-EXRRTKWT.js';
3
3
  import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
4
4
 
5
5
  function confirmMatches(typed, phrase) {
@@ -0,0 +1,14 @@
1
+ import { cx } from './chunk-ODEQTPFM.js';
2
+ import './BrandChip-SQWBC2WU.css';
3
+ import { SwatchBookGlyph, ChevronRightGlyph } from '@crewlethq/icons/glyphs';
4
+ import { jsxs, jsx } from 'react/jsx-runtime';
5
+
6
+ function BrandChip({ href, label, mark, className, ...rest }) {
7
+ return /* @__PURE__ */ jsxs("a", { ...rest, href, className: cx("crewlet-brand-chip", className), children: [
8
+ /* @__PURE__ */ jsx("span", { className: cx("crewlet-brand-chip__mark", !mark && "crewlet-brand-chip__mark--glyph"), "aria-hidden": "true", children: mark ? /* @__PURE__ */ jsx("img", { src: mark, alt: "", className: "crewlet-brand-chip__image", draggable: false }) : /* @__PURE__ */ jsx(SwatchBookGlyph, { size: "sm" }) }),
9
+ /* @__PURE__ */ jsx("span", { className: "crewlet-brand-chip__label", children: label }),
10
+ /* @__PURE__ */ jsx("span", { className: "crewlet-brand-chip__chevron", "aria-hidden": "true", children: /* @__PURE__ */ jsx(ChevronRightGlyph, { size: "xs" }) })
11
+ ] });
12
+ }
13
+
14
+ export { BrandChip };
@@ -23,7 +23,10 @@ export * from '../AsideLayout/index.js';
23
23
  export * from '../AuthLayout/index.js';
24
24
  export * from '../Avatar/index.js';
25
25
  export * from '../AvatarPicker/index.js';
26
+ export * from '../BrandChip/index.js';
26
27
  export * from '../BrandLockup/index.js';
28
+ export * from '../BrandSample/index.js';
29
+ export * from '../BrandScope/index.js';
27
30
  export * from '../Breadcrumb/index.js';
28
31
  export * from '../Button/index.js';
29
32
  export * from '../CalendarGrid/index.js';
@@ -42,6 +45,8 @@ export * from '../Checkbox/index.js';
42
45
  export * from '../ChoiceButtons/index.js';
43
46
  export * from '../ChoiceList/index.js';
44
47
  export * from '../CodeBlock/index.js';
48
+ export * from '../ColorField/index.js';
49
+ export * from '../ColorSwatch/index.js';
45
50
  export * from '../Combobox/index.js';
46
51
  export * from '../CommandPalette/index.js';
47
52
  export * from '../CommentThread/index.js';
@@ -49,6 +54,7 @@ export * from '../Composer/index.js';
49
54
  export * from '../ConfirmField/index.js';
50
55
  export * from '../ConflictNote/index.js';
51
56
  export * from '../Container/index.js';
57
+ export * from '../ContrastBadge/index.js';
52
58
  export * from '../Copyable/index.js';
53
59
  export * from '../Count/index.js';
54
60
  export * from '../CursorFlag/index.js';
@@ -76,6 +82,7 @@ export * from '../FactList/index.js';
76
82
  export * from '../FileDrop/index.js';
77
83
  export * from '../FilterChip/index.js';
78
84
  export * from '../FindingList/index.js';
85
+ export * from '../FolderTile/index.js';
79
86
  export * from '../FollowBanner/index.js';
80
87
  export * from '../FrameProtocol/index.js';
81
88
  export * from '../Fullscreen/index.js';
@@ -103,6 +110,7 @@ export * from '../Listbox/index.js';
103
110
  export * from '../LiveCursor/index.js';
104
111
  export * from '../LivePreview/index.js';
105
112
  export * from '../LockedLabel/index.js';
113
+ export * from '../LogoSlot/index.js';
106
114
  export * from '../Markdown/index.js';
107
115
  export * from '../MarkdownEditor/index.js';
108
116
  export * from '../MediaMatch/index.js';
@@ -145,6 +153,7 @@ export * from '../SectionFrame/index.js';
145
153
  export * from '../SegmentedControl/index.js';
146
154
  export * from '../SegmentedMeter/index.js';
147
155
  export * from '../Select/index.js';
156
+ export * from '../SelectionBar/index.js';
148
157
  export * from '../SettingsTable/index.js';
149
158
  export * from '../ShareDialog/index.js';
150
159
  export * from '../SheetColumnEditor/index.js';
@@ -186,6 +195,7 @@ export * from '../Tooltip/index.js';
186
195
  export * from '../Tree/index.js';
187
196
  export * from '../TreeCanvas/index.js';
188
197
  export * from '../TreeGrid/index.js';
198
+ export * from '../TypeSpecimen/index.js';
189
199
  export * from '../VersionCompare/index.js';
190
200
  export * from '../VersionTimeline/index.js';
191
201
  export * from '../VisuallyHidden/index.js';