@crewlethq/ui 0.61.0 → 0.63.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 (103) hide show
  1. package/README.md +8 -0
  2. package/dist/AgentHandoffPanel/index.js +1 -1
  3. package/dist/AppShell/index.js +1 -1
  4. package/dist/ArtifactBar/index.js +5 -5
  5. package/dist/ArtifactCard/index.js +3 -3
  6. package/dist/AttachmentChip/AttachmentChip.d.ts +37 -0
  7. package/dist/AttachmentChip/index.d.ts +3 -0
  8. package/dist/AttachmentChip/index.js +6 -0
  9. package/dist/AttachmentChip-XF4KPQ3G.css +16 -0
  10. package/dist/AvatarPicker/index.js +6 -6
  11. package/dist/Canvas/index.js +1 -1
  12. package/dist/CanvasBoard/index.js +1 -1
  13. package/dist/CanvasToolbar/index.js +1 -1
  14. package/dist/Combobox/index.js +1 -1
  15. package/dist/CommandPalette/index.js +1 -1
  16. package/dist/CommentThread/index.js +1 -1
  17. package/dist/ContrastBadge/index.js +2 -2
  18. package/dist/ContrastHelp/index.js +3 -3
  19. package/dist/DataTable/index.js +1 -1
  20. package/dist/DataView/index.js +1 -1
  21. package/dist/DateTimePicker/index.js +1 -1
  22. package/dist/DeepWorkCard/DeepWorkCard.d.ts +85 -0
  23. package/dist/DeepWorkCard/index.d.ts +3 -0
  24. package/dist/DeepWorkCard/index.js +17 -0
  25. package/dist/DeepWorkCard-DGHRIQDM.css +80 -0
  26. package/dist/DocTabsEditor/index.js +1 -1
  27. package/dist/DownloadButton/DownloadButton.d.ts +7 -1
  28. package/dist/DownloadButton/index.js +1 -1
  29. package/dist/FileList/FileList.d.ts +42 -0
  30. package/dist/FileList/index.d.ts +3 -0
  31. package/dist/FileList/index.js +3 -0
  32. package/dist/FileList-TGDNV2QS.css +89 -0
  33. package/dist/FollowBanner/index.js +1 -1
  34. package/dist/HuePicker/index.js +5 -5
  35. package/dist/InlineEditor/index.js +1 -1
  36. package/dist/LinkInterstitial/index.js +1 -1
  37. package/dist/ListInput/index.js +1 -1
  38. package/dist/LogoSlot/index.js +3 -3
  39. package/dist/MarkdownEditor/index.js +5 -5
  40. package/dist/Menu/index.js +1 -1
  41. package/dist/MergeConflicts/index.js +5 -5
  42. package/dist/Modal/index.js +1 -1
  43. package/dist/OpenInAppCard/index.js +2 -2
  44. package/dist/PeekRail/index.js +1 -1
  45. package/dist/PresenterView/index.js +1 -1
  46. package/dist/PrincipalPicker/index.js +2 -2
  47. package/dist/ResultTableCard/index.js +3 -3
  48. package/dist/RichEditor/index.js +1 -1
  49. package/dist/SegmentedControl/index.js +4 -4
  50. package/dist/SelectionBar/index.js +1 -1
  51. package/dist/SetupWizard/index.js +2 -2
  52. package/dist/ShareDialog/index.js +1 -1
  53. package/dist/SheetColumnEditor/index.js +6 -6
  54. package/dist/SheetGrid/index.js +3 -3
  55. package/dist/SlideCompare/index.js +1 -1
  56. package/dist/SlideFilmstrip/index.js +1 -1
  57. package/dist/Switcher/index.js +1 -1
  58. package/dist/Tabs/index.js +3 -3
  59. package/dist/ThemeGallery/index.js +1 -1
  60. package/dist/ThemeSwitcher/index.js +5 -5
  61. package/dist/TimeRangePicker/index.js +5 -5
  62. package/dist/TimeWindowPicker/index.js +1 -1
  63. package/dist/TreeCanvas/index.js +1 -1
  64. package/dist/ValueField/ValueField.d.ts +117 -0
  65. package/dist/ValueField/index.d.ts +10 -0
  66. package/dist/ValueField/index.js +15 -0
  67. package/dist/ValueField/references.d.ts +66 -0
  68. package/dist/ValueField-EIBD6RYS.css +13 -0
  69. package/dist/VersionCompare/index.js +5 -5
  70. package/dist/{chunk-53NTMTRM.js → chunk-6IGIYOTV.js} +1 -1
  71. package/dist/chunk-CZXF6EFK.js +52 -0
  72. package/dist/{chunk-5ZGJ22CO.js → chunk-DHIO6Q75.js} +1 -1
  73. package/dist/{chunk-3BQWARG2.js → chunk-F7VBYCW2.js} +1 -1
  74. package/dist/{chunk-5G76O23M.js → chunk-IJIC4COR.js} +1 -1
  75. package/dist/{chunk-RPHQNXE5.js → chunk-IOZFPFQS.js} +1 -1
  76. package/dist/{chunk-NL72YZWF.js → chunk-ISHLFPNN.js} +1 -1
  77. package/dist/{chunk-5KW63GZ3.js → chunk-JAOJLEYB.js} +1 -1
  78. package/dist/{chunk-MOW65OIJ.js → chunk-JPVORBWC.js} +1 -1
  79. package/dist/chunk-KYTOEWJD.js +56 -0
  80. package/dist/chunk-LA4PX7Z6.js +118 -0
  81. package/dist/{chunk-LG6TUGET.js → chunk-NSCYGUDG.js} +2 -0
  82. package/dist/chunk-OD3Z6QKN.js +237 -0
  83. package/dist/{chunk-OM6CPZB7.js → chunk-OIMWGV2N.js} +1 -1
  84. package/dist/{chunk-5PMFRAGL.js → chunk-OU4FLGOZ.js} +1 -1
  85. package/dist/{chunk-5MN2HISF.js → chunk-PHQPQZUX.js} +1 -1
  86. package/dist/{chunk-VC2M2E7N.js → chunk-PK2P2QH6.js} +4 -3
  87. package/dist/{chunk-NRMXUNLR.js → chunk-QCVAVAF6.js} +1 -1
  88. package/dist/{chunk-LND6XSXN.js → chunk-S2VMOITT.js} +1 -1
  89. package/dist/{chunk-VRPDQSXZ.js → chunk-SELUJSTZ.js} +2 -2
  90. package/dist/{chunk-3633T7EJ.js → chunk-WSV3MBOE.js} +1 -1
  91. package/dist/generated/index.d.ts +4 -0
  92. package/dist/generated/index.js +88 -84
  93. package/dist/index.js +88 -84
  94. package/dist/styles.css +210 -0
  95. package/package.json +3 -3
  96. package/dist/{Editor-DM7X24B7.js → Editor-GHHWWXXL.js} +1 -1
  97. package/dist/{chunk-VN3DCUED.js → chunk-27JCHL64.js} +1 -1
  98. package/dist/{chunk-T4THNJ6E.js → chunk-5DCY2QUY.js} +1 -1
  99. package/dist/{chunk-WDRYUMN6.js → chunk-BSAQE7PO.js} +1 -1
  100. package/dist/{chunk-I43D5K6A.js → chunk-CT6I36FH.js} +1 -1
  101. package/dist/{chunk-MHFTG2LO.js → chunk-EBCH3MRX.js} +1 -1
  102. package/dist/{chunk-OXZKRUGM.js → chunk-TXQNWGUD.js} +0 -0
  103. package/dist/{chunk-WXSGCYZO.js → chunk-VVVB3OBW.js} +1 -1
package/README.md CHANGED
@@ -205,6 +205,14 @@ places:
205
205
  - A surface that pans or zooms dispatches `LAYER_REPOSITION_EVENT` on its host
206
206
  when the content beneath it moves, and every panel anchored inside follows.
207
207
 
208
+ ## Changes in 0.62.0
209
+
210
+ **`ValueField`, a labelled value with the control its kind needs.** `FormField` with the control and the rules every form holding configuration values otherwise rewrites, in one component (`ValueField`, `ValueFieldKind`, `ValueFieldChoice`, `ValueFieldLabels`, `ValueFieldProps`). `kind` picks the control: `text`, `id`, `email` and `url` are a text field, `secret` a password field, `multiline` a `Textarea`, and `choice` and `handle` the `Select` listbox. A `secret` is masked unless its value is exactly one `${NAME}` reference, which reads as a name in the `reference` appearance. Typing `$` in a one-line field offers the names in `references`, ranked closest first and written in as a whole `${NAME}` (`onReferencesNeeded` is called as the list opens, so a caller can refresh it). A `url` wears an `https://` `InputAffix`, read as part of the value, which steps aside for `http://` and for a reference. `url`, `id` and `email` drop whitespace; no kind sets `type="email"`, so a reference is never refused by the browser. Required is the unmarked default: `required={false}` says "(optional)", and `markRequired` says "(required)" where it is news. A choice's `hint` is drawn under its option and joins the help line once chosen, and a stored answer the list no longer offers keeps a row of its own. `isReference` replaces the default `${NAME}` grammar, `mark` draws a logo before the label, `helperOnFocus` is passed to `FormField`, and `labels` replaces the list's name ("Secrets") and the choice placeholder ("Choose one").
211
+
212
+ **The completion helpers are exported with it**: `referenceAt`, `rankReferences`, `completeReference`, `isWholeReference`, `urlSchemeOf`, `REFERENCE_NAME_PATTERN` and the `ReferenceQuery` type, for a field that completes references in a control of its own.
213
+
214
+ **`Combobox` on a password field is a combobox only while its list is open.** HTML allows no ARIA role on `type="password"`, so a masked field carried an invalid `role="combobox"` (and `aria-autocomplete` and `aria-expanded`) at rest. It now takes those only while it has options to show. Every other field is unchanged.
215
+
208
216
  ## Changes in 0.58.0
209
217
 
210
218
  **`Spinner` turns at a calm pace, and its arc breathes.** It turned once per `--motion-duration-slow` (300ms), a transition step, so every running mark (a pending `Button`, `RunChip` while it thinks or works, a running step in `StepList`, `StepStateMark`) spun more than three times a second and read as alarm rather than as work. It now turns once a second (`--motion-duration-turn`, linear) while its arc eases between a quarter and three quarters of the ring on a slower cycle (`--motion-duration-sweep`, 1.5s), with soft ends. The stroke is still one 2px border in the current ink at every size (`em`, `xs`, `sm`, `md`); the arc is cut by a mask, so no side of the border is transparent any more. Under reduced motion it stops as before and keeps its open quarter. The arc's length is a registered custom property (`@property --crewlet-spinner-arc`); a browser without `@property` support steps between the two lengths rather than easing.
@@ -14,9 +14,9 @@ import '../chunk-PQADV6P6.js';
14
14
  import '../chunk-2G355KDJ.js';
15
15
  import '../chunk-PIYJNCN7.js';
16
16
  import '../chunk-7QTPJDRF.js';
17
- import '../chunk-XSPCITPN.js';
18
17
  import '../chunk-OMV5W53A.js';
19
18
  import '../chunk-2YTOOH3A.js';
19
+ import '../chunk-XSPCITPN.js';
20
20
  import '../chunk-H5XTJ7GJ.js';
21
21
  import '../chunk-2XWFWNDT.js';
22
22
  import '../chunk-NUZHC6MM.js';
@@ -3,9 +3,9 @@ import '../chunk-RTPQDNW3.js';
3
3
  import '../chunk-LODRX4FU.js';
4
4
  export { RESIZE_HANDLE_LARGE_STEP, RESIZE_HANDLE_STEP, ResizeHandle, clampSize, useAppShellAside, useAppShellPeek } from '../chunk-PIYJNCN7.js';
5
5
  import '../chunk-7QTPJDRF.js';
6
- import '../chunk-XSPCITPN.js';
7
6
  import '../chunk-OMV5W53A.js';
8
7
  import '../chunk-2YTOOH3A.js';
8
+ import '../chunk-XSPCITPN.js';
9
9
  import '../chunk-H5XTJ7GJ.js';
10
10
  import '../chunk-2XWFWNDT.js';
11
11
  import '../chunk-NUZHC6MM.js';
@@ -1,19 +1,19 @@
1
- export { ARTIFACT_BAR_LABELS, ArtifactBar, ArtifactVersionChip } from '../chunk-5KW63GZ3.js';
1
+ export { ARTIFACT_BAR_LABELS, ArtifactBar, ArtifactVersionChip } from '../chunk-JAOJLEYB.js';
2
2
  import '../chunk-OOC7Q67K.js';
3
3
  import '../chunk-I33UIUZD.js';
4
- import '../chunk-3BQWARG2.js';
5
- import '../chunk-VN3DCUED.js';
6
- import '../chunk-WIATRXEJ.js';
4
+ import '../chunk-F7VBYCW2.js';
5
+ import '../chunk-27JCHL64.js';
7
6
  import '../chunk-EGMQURBR.js';
8
7
  import '../chunk-AVL52EME.js';
8
+ import '../chunk-WIATRXEJ.js';
9
9
  import '../chunk-RSKW25Y5.js';
10
10
  import '../chunk-ACRRRPWT.js';
11
11
  import '../chunk-5KRRJNQO.js';
12
12
  import '../chunk-LODRX4FU.js';
13
13
  import '../chunk-7QTPJDRF.js';
14
- import '../chunk-XSPCITPN.js';
15
14
  import '../chunk-OMV5W53A.js';
16
15
  import '../chunk-2YTOOH3A.js';
16
+ import '../chunk-XSPCITPN.js';
17
17
  import '../chunk-H5XTJ7GJ.js';
18
18
  import '../chunk-2XWFWNDT.js';
19
19
  import '../chunk-NUZHC6MM.js';
@@ -1,13 +1,13 @@
1
- export { ArtifactCard, ArtifactCardSkeleton, ArtifactPreviewGlyph } from '../chunk-MHFTG2LO.js';
1
+ export { ArtifactCard, ArtifactCardSkeleton, ArtifactPreviewGlyph } from '../chunk-EBCH3MRX.js';
2
2
  import '../chunk-QBI5ETKY.js';
3
3
  import '../chunk-CI3VPIJN.js';
4
4
  import '../chunk-L6NG7CUA.js';
5
5
  import '../chunk-RE3FBGQQ.js';
6
+ import '../chunk-MKKX6N7C.js';
7
+ import '../chunk-AV2DXAEL.js';
6
8
  import '../chunk-5AQBPHZD.js';
7
9
  import '../chunk-PZKHBB7D.js';
8
10
  import '../chunk-QZLNKLYD.js';
9
- import '../chunk-MKKX6N7C.js';
10
- import '../chunk-AV2DXAEL.js';
11
11
  import '../chunk-KIPAFCVS.js';
12
12
  import '../chunk-BGLKLXL3.js';
13
13
  export { ARTIFACT_KINDS, ArtifactKindGlyph } from '../chunk-RSKW25Y5.js';
@@ -0,0 +1,37 @@
1
+ import { type HTMLAttributes } from 'react';
2
+ /** Where an attached file stands: on its way up, ready to send, or refused. */
3
+ export type AttachmentChipState = 'uploading' | 'ready' | 'failed';
4
+ /** The words a state is said with after the file's name, for a screen reader. */
5
+ export interface AttachmentChipLabels {
6
+ uploading: string;
7
+ failed: string;
8
+ /** Names the remove control, by the file's name. */
9
+ remove: (name: string) => string;
10
+ }
11
+ export declare const ATTACHMENT_CHIP_LABELS: AttachmentChipLabels;
12
+ export interface AttachmentChipProps extends Omit<HTMLAttributes<HTMLSpanElement>, 'children'> {
13
+ /** The file's name. */
14
+ name: string;
15
+ /**
16
+ * The address of an image to draw as the chip's thumbnail, or nothing for
17
+ * the image mark. DRAWN ONLY AS AN `<img>`, so a picture never runs what it
18
+ * carries; one that fails to load falls back to the mark.
19
+ */
20
+ preview?: string | undefined;
21
+ state?: AttachmentChipState | undefined;
22
+ /** Takes the file off what is being sent. Without it, the chip only shows what was sent. */
23
+ onRemove?: (() => void) | undefined;
24
+ labels?: Partial<AttachmentChipLabels> | undefined;
25
+ }
26
+ /**
27
+ * A file attached to a message, as the chip in a composer's attachments row
28
+ * and under the message it was sent with: a thumbnail, the file's name, and
29
+ * a remove control while it can still be taken off.
30
+ *
31
+ * A `Tag`, SO IT STANDS IN ONE ROW with the other things a message carries
32
+ * (the page a question is asked about) at the same height and in the same
33
+ * outline. Uploading, the thumbnail gives way to the spinner; refused, the
34
+ * chip takes the danger tone and the alert mark, and its state is said in
35
+ * words after the name, because the mark is a picture of it.
36
+ */
37
+ export declare function AttachmentChip({ name, preview, state, onRemove, labels: overrides, className, ...rest }: AttachmentChipProps): import("react").JSX.Element;
@@ -0,0 +1,3 @@
1
+ import './AttachmentChip.css';
2
+ export { ATTACHMENT_CHIP_LABELS, AttachmentChip } from './AttachmentChip.js';
3
+ export type { AttachmentChipLabels, AttachmentChipProps, AttachmentChipState } from './AttachmentChip.js';
@@ -0,0 +1,6 @@
1
+ export { ATTACHMENT_CHIP_LABELS, AttachmentChip } from '../chunk-KYTOEWJD.js';
2
+ import '../chunk-KYIAFNU7.js';
3
+ import '../chunk-WIATRXEJ.js';
4
+ import '../chunk-XSPCITPN.js';
5
+ import '../chunk-UT6CW3C7.js';
6
+ import '../chunk-ODEQTPFM.js';
@@ -0,0 +1,16 @@
1
+ /*
2
+ * A file attached to a message: a Tag whose leading mark is the file's
3
+ * thumbnail, at the glyph's own box so the pill keeps its height, with the
4
+ * name cut short rather than widening the composer's row.
5
+ */
6
+ .crewlet-attachment-chip {
7
+ max-width: 14rem;
8
+ }
9
+
10
+ .crewlet-attachment-chip__thumb {
11
+ display: block;
12
+ width: var(--font-size-md);
13
+ height: var(--font-size-md);
14
+ border-radius: var(--radius-xs);
15
+ object-fit: cover;
16
+ }
@@ -1,19 +1,19 @@
1
- export { AvatarPicker } from '../chunk-5ZGJ22CO.js';
2
- import '../chunk-NRMXUNLR.js';
1
+ export { AvatarPicker } from '../chunk-DHIO6Q75.js';
2
+ import '../chunk-QCVAVAF6.js';
3
3
  import '../chunk-KHJIEPZV.js';
4
4
  import '../chunk-AYKXMIOR.js';
5
5
  import '../chunk-SNQRGH4A.js';
6
- import '../chunk-3BQWARG2.js';
7
- import '../chunk-VN3DCUED.js';
8
- import '../chunk-WIATRXEJ.js';
6
+ import '../chunk-F7VBYCW2.js';
7
+ import '../chunk-27JCHL64.js';
9
8
  import '../chunk-EGMQURBR.js';
9
+ import '../chunk-WIATRXEJ.js';
10
10
  import '../chunk-PZKHBB7D.js';
11
11
  import '../chunk-5KRRJNQO.js';
12
12
  import '../chunk-LODRX4FU.js';
13
13
  import '../chunk-7QTPJDRF.js';
14
- import '../chunk-XSPCITPN.js';
15
14
  import '../chunk-OMV5W53A.js';
16
15
  import '../chunk-2YTOOH3A.js';
16
+ import '../chunk-XSPCITPN.js';
17
17
  import '../chunk-H5XTJ7GJ.js';
18
18
  import '../chunk-2XWFWNDT.js';
19
19
  import '../chunk-NUZHC6MM.js';
@@ -3,8 +3,8 @@ import '../chunk-LM3ISVJA.js';
3
3
  import '../chunk-I33UIUZD.js';
4
4
  import '../chunk-ACRRRPWT.js';
5
5
  import '../chunk-7QTPJDRF.js';
6
- import '../chunk-XSPCITPN.js';
7
6
  import '../chunk-OMV5W53A.js';
7
+ import '../chunk-XSPCITPN.js';
8
8
  import '../chunk-H5XTJ7GJ.js';
9
9
  import '../chunk-2XWFWNDT.js';
10
10
  import '../chunk-NUZHC6MM.js';
@@ -7,8 +7,8 @@ import '../chunk-LM3ISVJA.js';
7
7
  import '../chunk-I33UIUZD.js';
8
8
  import '../chunk-ACRRRPWT.js';
9
9
  import '../chunk-7QTPJDRF.js';
10
- import '../chunk-XSPCITPN.js';
11
10
  import '../chunk-OMV5W53A.js';
11
+ import '../chunk-XSPCITPN.js';
12
12
  import '../chunk-H5XTJ7GJ.js';
13
13
  import '../chunk-2XWFWNDT.js';
14
14
  import '../chunk-NUZHC6MM.js';
@@ -5,8 +5,8 @@ import '../chunk-LM3ISVJA.js';
5
5
  import '../chunk-I33UIUZD.js';
6
6
  import '../chunk-ACRRRPWT.js';
7
7
  import '../chunk-7QTPJDRF.js';
8
- import '../chunk-XSPCITPN.js';
9
8
  import '../chunk-OMV5W53A.js';
9
+ import '../chunk-XSPCITPN.js';
10
10
  import '../chunk-H5XTJ7GJ.js';
11
11
  import '../chunk-2XWFWNDT.js';
12
12
  import '../chunk-NUZHC6MM.js';
@@ -1,4 +1,4 @@
1
- export { Combobox } from '../chunk-VC2M2E7N.js';
1
+ export { Combobox } from '../chunk-PK2P2QH6.js';
2
2
  import '../chunk-7KHM2FZH.js';
3
3
  import '../chunk-TLIJG4TP.js';
4
4
  import '../chunk-PGCLHYVP.js';
@@ -8,9 +8,9 @@ import '../chunk-5KRRJNQO.js';
8
8
  import '../chunk-PQADV6P6.js';
9
9
  import '../chunk-2G355KDJ.js';
10
10
  import '../chunk-7QTPJDRF.js';
11
- import '../chunk-XSPCITPN.js';
12
11
  import '../chunk-OMV5W53A.js';
13
12
  import '../chunk-2YTOOH3A.js';
13
+ import '../chunk-XSPCITPN.js';
14
14
  import '../chunk-H5XTJ7GJ.js';
15
15
  import '../chunk-2XWFWNDT.js';
16
16
  import '../chunk-NUZHC6MM.js';
@@ -13,8 +13,8 @@ import '../chunk-5KRRJNQO.js';
13
13
  import '../chunk-PQADV6P6.js';
14
14
  import '../chunk-2G355KDJ.js';
15
15
  import '../chunk-7QTPJDRF.js';
16
- import '../chunk-XSPCITPN.js';
17
16
  import '../chunk-OMV5W53A.js';
17
+ import '../chunk-XSPCITPN.js';
18
18
  import '../chunk-H5XTJ7GJ.js';
19
19
  import '../chunk-2XWFWNDT.js';
20
20
  import '../chunk-NUZHC6MM.js';
@@ -1,6 +1,6 @@
1
- export { ContrastBadge, ContrastLevelTag, contrastLevel, contrastRatio, formatContrastRatio } from '../chunk-WDRYUMN6.js';
2
- import '../chunk-KYIAFNU7.js';
1
+ export { ContrastBadge, ContrastLevelTag, contrastLevel, contrastRatio, formatContrastRatio } from '../chunk-BSAQE7PO.js';
3
2
  import '../chunk-7W3LYIOC.js';
3
+ import '../chunk-KYIAFNU7.js';
4
4
  import '../chunk-WIATRXEJ.js';
5
5
  import '../chunk-UT6CW3C7.js';
6
6
  import '../chunk-ODEQTPFM.js';
@@ -1,8 +1,8 @@
1
- export { ContrastHelp } from '../chunk-3633T7EJ.js';
2
- import '../chunk-WDRYUMN6.js';
3
- import '../chunk-KYIAFNU7.js';
1
+ export { ContrastHelp } from '../chunk-WSV3MBOE.js';
2
+ import '../chunk-BSAQE7PO.js';
4
3
  import '../chunk-KHJIEPZV.js';
5
4
  import '../chunk-7W3LYIOC.js';
5
+ import '../chunk-KYIAFNU7.js';
6
6
  import '../chunk-WIATRXEJ.js';
7
7
  import '../chunk-OMV5W53A.js';
8
8
  import '../chunk-H5XTJ7GJ.js';
@@ -11,8 +11,8 @@ import '../chunk-PQADV6P6.js';
11
11
  import '../chunk-2G355KDJ.js';
12
12
  import '../chunk-LODRX4FU.js';
13
13
  import '../chunk-7QTPJDRF.js';
14
- import '../chunk-XSPCITPN.js';
15
14
  import '../chunk-OMV5W53A.js';
15
+ import '../chunk-XSPCITPN.js';
16
16
  import '../chunk-H5XTJ7GJ.js';
17
17
  import '../chunk-2XWFWNDT.js';
18
18
  import '../chunk-NUZHC6MM.js';
@@ -21,8 +21,8 @@ import '../chunk-PQADV6P6.js';
21
21
  import '../chunk-2G355KDJ.js';
22
22
  import '../chunk-LODRX4FU.js';
23
23
  import '../chunk-7QTPJDRF.js';
24
- import '../chunk-XSPCITPN.js';
25
24
  import '../chunk-OMV5W53A.js';
25
+ import '../chunk-XSPCITPN.js';
26
26
  import '../chunk-H5XTJ7GJ.js';
27
27
  import '../chunk-2XWFWNDT.js';
28
28
  import '../chunk-NUZHC6MM.js';
@@ -2,8 +2,8 @@ export { DEFAULT_DATE_TIME_PICKER_LABELS, DateTimePicker } from '../chunk-2BDPR4
2
2
  import '../chunk-GXQ3B46I.js';
3
3
  import '../chunk-KHJIEPZV.js';
4
4
  import '../chunk-7QTPJDRF.js';
5
- import '../chunk-XSPCITPN.js';
6
5
  import '../chunk-OMV5W53A.js';
6
+ import '../chunk-XSPCITPN.js';
7
7
  import '../chunk-H5XTJ7GJ.js';
8
8
  import '../chunk-2XWFWNDT.js';
9
9
  import '../chunk-NUZHC6MM.js';
@@ -0,0 +1,85 @@
1
+ import { type HTMLAttributes, type ReactNode } from 'react';
2
+ import { type StepListStep } from '../Stepper/index.js';
3
+ /**
4
+ * Where a long, bounded run stands: `starting` before its first step,
5
+ * `running` while it works, `waiting` on the person's approval of a change it
6
+ * prepared, `finished`, `stopped` (by the person, or at one of its limits)
7
+ * and `failed` (the system could not finish it).
8
+ */
9
+ export type DeepWorkState = 'starting' | 'running' | 'waiting' | 'finished' | 'stopped' | 'failed';
10
+ export declare const DEEP_WORK_STATES: readonly ["starting", "running", "waiting", "finished", "stopped", "failed"];
11
+ /** The words each state is said with, on the card's state tag. */
12
+ export type DeepWorkStateLabels = Record<DeepWorkState, string>;
13
+ export declare const DEEP_WORK_STATE_LABELS: DeepWorkStateLabels;
14
+ /** One of the run's limits, as a meter: time against its deadline, calls against their cap, budget used. */
15
+ export interface DeepWorkMeasure {
16
+ /** What tells two measures apart, unique within the card. */
17
+ key: string;
18
+ /** What is measured, in a word or two: "Time", "Crewlet calls", "Budget used". */
19
+ label: string;
20
+ value: number;
21
+ /** The limit. A run's measure always has one. */
22
+ max: number;
23
+ /** The reading in words, at the legend's end: "4m of 20m", "12 of 60", "34%". */
24
+ hint: string;
25
+ /** The reading for a screen reader, where the hint abbreviates: "4 minutes of 20". Defaults to `hint`. */
26
+ valueText?: string | undefined;
27
+ }
28
+ export interface DeepWorkCardLabels {
29
+ /** The card's title. */
30
+ title: string;
31
+ /** Names the activity lines for a screen reader. */
32
+ activity: string;
33
+ /** Names the nested steps for a screen reader. */
34
+ steps: string;
35
+ /** The folded steps' title, by their count. */
36
+ stepCount: (count: number) => string;
37
+ }
38
+ export declare const DEEP_WORK_CARD_LABELS: DeepWorkCardLabels;
39
+ export interface DeepWorkCardProps extends Omit<HTMLAttributes<HTMLElement>, 'title' | 'children'> {
40
+ state: DeepWorkState;
41
+ /** What the run was asked to do, in the person's or the assistant's words. */
42
+ goal: ReactNode;
43
+ /** The run's limits, each drawn as a compact meter in the order given. */
44
+ measures?: readonly DeepWorkMeasure[] | undefined;
45
+ /**
46
+ * The run's own latest account of itself, oldest first: a command it ran,
47
+ * a file it wrote. Drawn in the mono face, one line each, never wrapped
48
+ * into a paragraph. The consumer bounds how many it keeps.
49
+ */
50
+ activity?: readonly string[] | undefined;
51
+ /** The steps the run took, nested under it. */
52
+ steps?: readonly StepListStep[] | undefined;
53
+ /**
54
+ * Up to this many steps are drawn open; more fold behind one disclosure
55
+ * named by their count, so a long run stays one card. 3 by default.
56
+ */
57
+ stepsOpenAt?: number | undefined;
58
+ /**
59
+ * One sentence at the card's foot, in the state's tone: why a run stopped
60
+ * or failed, or what a waiting run waits on.
61
+ */
62
+ note?: ReactNode;
63
+ /** The state words on the card's tag. */
64
+ stateLabels?: Partial<DeepWorkStateLabels> | undefined;
65
+ labels?: Partial<DeepWorkCardLabels> | undefined;
66
+ }
67
+ /**
68
+ * A long, bounded run an assistant switched to: its goal, where it stands,
69
+ * how much of each limit it has used, what it is doing now and the steps it
70
+ * took, on the product's `StatusCard`.
71
+ *
72
+ * UPDATED IN PLACE. The run is re-sent as it moves, so every part is drawn
73
+ * from props and nothing animates on arrival: a meter's fill moves, a line of
74
+ * activity is added at the end, and the reader's open or closed steps stay as
75
+ * they left them.
76
+ *
77
+ * NOT A LIVE REGION. The card changes every second while the run works, so
78
+ * it announces nothing itself; the note at its foot is the strip's own status
79
+ * (an alert for a failure), which changes only when the run's state does.
80
+ *
81
+ * THE LIMITS ARE METERS ON THE SPENT RAMP: time, calls and budget are all
82
+ * spent towards a ceiling, so a run near one reads as near it without the
83
+ * consumer judging the number.
84
+ */
85
+ export declare function DeepWorkCard({ state, goal, measures, activity, steps, stepsOpenAt, note, stateLabels, labels: labelOverrides, className, ...rest }: DeepWorkCardProps): import("react").JSX.Element;
@@ -0,0 +1,3 @@
1
+ import './DeepWorkCard.css';
2
+ export { DEEP_WORK_CARD_LABELS, DEEP_WORK_STATE_LABELS, DEEP_WORK_STATES, DeepWorkCard } from './DeepWorkCard.js';
3
+ export type { DeepWorkCardLabels, DeepWorkCardProps, DeepWorkMeasure, DeepWorkState, DeepWorkStateLabels, } from './DeepWorkCard.js';
@@ -0,0 +1,17 @@
1
+ export { DEEP_WORK_CARD_LABELS, DEEP_WORK_STATES, DEEP_WORK_STATE_LABELS, DeepWorkCard } from '../chunk-LA4PX7Z6.js';
2
+ import '../chunk-Z4EKUMZW.js';
3
+ import '../chunk-RQFRRPV6.js';
4
+ import '../chunk-NLI7OVO2.js';
5
+ import '../chunk-WW4E5EUS.js';
6
+ import '../chunk-KYIAFNU7.js';
7
+ import '../chunk-WIATRXEJ.js';
8
+ import '../chunk-MKKX6N7C.js';
9
+ import '../chunk-AV2DXAEL.js';
10
+ import '../chunk-P4YORMRZ.js';
11
+ import '../chunk-ZYO2QFU6.js';
12
+ import '../chunk-5KRRJNQO.js';
13
+ import '../chunk-PQADV6P6.js';
14
+ import '../chunk-7QTPJDRF.js';
15
+ import '../chunk-XSPCITPN.js';
16
+ import '../chunk-UT6CW3C7.js';
17
+ import '../chunk-ODEQTPFM.js';
@@ -0,0 +1,80 @@
1
+ /*
2
+ * A deep run on the product's StatusCard: the goal with its mark, the limits
3
+ * as compact meters on a two-column grid that folds to one, the latest
4
+ * activity as mono lines in an inset well, then the steps. Only the body's
5
+ * own parts are said here; the card, its head, its tag and its strip are
6
+ * StatusCard's.
7
+ */
8
+ .crewlet-deep-work-card .crewlet-status-card__body {
9
+ display: flex;
10
+ flex-direction: column;
11
+ gap: var(--spacing-3);
12
+ }
13
+
14
+ /* The goal: the mark on the first line, the words wrapping beside it. */
15
+ .crewlet-deep-work-card__goal {
16
+ display: grid;
17
+ grid-template-columns: auto minmax(0, 1fr);
18
+ align-items: start;
19
+ gap: var(--spacing-2);
20
+ }
21
+
22
+ .crewlet-deep-work-card__goal-mark {
23
+ height: calc(var(--font-size-compact) * var(--font-line-height-normal));
24
+ color: var(--color-text-tertiary);
25
+ }
26
+
27
+ .crewlet-deep-work-card__goal-text {
28
+ margin: 0;
29
+ font-size: var(--font-size-compact);
30
+ line-height: var(--font-line-height-normal);
31
+ color: var(--color-text-primary);
32
+ overflow-wrap: anywhere;
33
+ }
34
+
35
+ /* THE LIMITS SIDE BY SIDE where the card has room, one under another in a
36
+ narrow drawer, so no legend is cut to fit. */
37
+ .crewlet-deep-work-card__measures {
38
+ display: grid;
39
+ grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr));
40
+ gap: var(--spacing-2) var(--spacing-4);
41
+ }
42
+
43
+ /* THE LATEST ACTIVITY: one line each, never wrapped into a paragraph, cut
44
+ with an ellipsis rather than widening the card; the whole line is its
45
+ title for a pointer and its text for a screen reader. */
46
+ .crewlet-deep-work-card__activity {
47
+ display: flex;
48
+ flex-direction: column;
49
+ gap: var(--spacing-1);
50
+ min-width: 0;
51
+ margin: 0;
52
+ padding: var(--spacing-2) var(--spacing-3);
53
+ border-radius: var(--radius-md);
54
+ background: var(--color-surface-inset);
55
+ list-style: none;
56
+ }
57
+
58
+ .crewlet-deep-work-card__line {
59
+ min-width: 0;
60
+ overflow: hidden;
61
+ font-family: var(--font-family-mono);
62
+ font-size: var(--font-size-xs);
63
+ line-height: var(--font-line-height-normal);
64
+ color: var(--color-text-secondary);
65
+ text-overflow: ellipsis;
66
+ white-space: nowrap;
67
+ }
68
+
69
+ /* The newest line is what the run is doing now, in the primary ink. */
70
+ .crewlet-deep-work-card__line:last-child {
71
+ color: var(--color-text-primary);
72
+ }
73
+
74
+ .crewlet-deep-work-card__line code {
75
+ font: inherit;
76
+ }
77
+
78
+ .crewlet-deep-work-card__steps {
79
+ min-width: 0;
80
+ }
@@ -6,8 +6,8 @@ import '../chunk-PQADV6P6.js';
6
6
  import '../chunk-2G355KDJ.js';
7
7
  import '../chunk-LODRX4FU.js';
8
8
  import '../chunk-7QTPJDRF.js';
9
- import '../chunk-XSPCITPN.js';
10
9
  import '../chunk-OMV5W53A.js';
10
+ import '../chunk-XSPCITPN.js';
11
11
  import '../chunk-H5XTJ7GJ.js';
12
12
  import '../chunk-2XWFWNDT.js';
13
13
  import '../chunk-NUZHC6MM.js';
@@ -39,6 +39,12 @@ export interface DownloadButtonBaseProps {
39
39
  size?: ButtonSize | undefined;
40
40
  variant?: ButtonVariant | undefined;
41
41
  title?: string | undefined;
42
+ /**
43
+ * The control's name where several stand side by side, such as one per
44
+ * file in a list: "Download report.csv". It must contain the visible label,
45
+ * so a reader who says the label to a voice control still finds it.
46
+ */
47
+ 'aria-label'?: string | undefined;
42
48
  /**
43
49
  * Nothing to offer yet, such as an export of an empty table. Give a `title`
44
50
  * that says why, so the control is never a dead button with no reason.
@@ -66,4 +72,4 @@ export type DownloadButtonProps = DownloadButtonBaseProps & DownloadButtonSource
66
72
  * refusal holds until the next press, and every attempt replaces the status
67
73
  * message, so a second identical refusal is still announced.
68
74
  */
69
- export declare function DownloadButton({ text, file, filename, mime, label, startedLabel, failedLabel, startedMessage, failedMessage, size, variant, title, disabled, resetMs, failedResetMs, className, }: DownloadButtonProps): import("react").JSX.Element;
75
+ export declare function DownloadButton({ text, file, filename, mime, label, startedLabel, failedLabel, startedMessage, failedMessage, size, variant, title, 'aria-label': ariaLabel, disabled, resetMs, failedResetMs, className, }: DownloadButtonProps): import("react").JSX.Element;
@@ -1,4 +1,4 @@
1
- export { DownloadButton } from '../chunk-LG6TUGET.js';
1
+ export { DownloadButton } from '../chunk-NSCYGUDG.js';
2
2
  import '../chunk-YNRKVY7X.js';
3
3
  import '../chunk-DTIW4CHZ.js';
4
4
  import '../chunk-7QTPJDRF.js';
@@ -0,0 +1,42 @@
1
+ import { type HTMLAttributes, type ReactNode } from 'react';
2
+ /** One file in a list. */
3
+ export interface FileListItem {
4
+ /** What tells two files apart, unique within the list. */
5
+ id: string;
6
+ /** The file's name, as it will be saved. */
7
+ name: string;
8
+ /** What the file is, in words: "PNG image", "CSV file". */
9
+ type: string;
10
+ /** How large it is, already formatted: "120 KB". */
11
+ size: string;
12
+ /**
13
+ * The address of an image to preview it from, or nothing for no preview.
14
+ *
15
+ * DRAWN ONLY AS AN `<img>`. An image element renders a picture and runs no
16
+ * script, so a preview of an SVG that carries one is still only a picture.
17
+ * The primitive never draws a file's markup inline and never embeds it in
18
+ * a frame or an object. A preview that fails to load falls back to the
19
+ * file's mark.
20
+ */
21
+ preview?: string | undefined;
22
+ /** The file's control at the row's end, usually a `DownloadButton`. */
23
+ action?: ReactNode;
24
+ }
25
+ export interface FileListProps extends Omit<HTMLAttributes<HTMLUListElement>, 'children'> {
26
+ files: readonly FileListItem[];
27
+ /** Names the list for a screen reader: "Files". REQUIRED, since a list of files has no heading of its own. */
28
+ label: string;
29
+ }
30
+ /**
31
+ * Files handed to the reader: each with its name, what it is, how large it is
32
+ * and its download, and an image with a preview under its row.
33
+ *
34
+ * A PREVIEW IS ONLY EVER A PICTURE. It is an `<img>` with no alternative text
35
+ * of its own (the row's name already names it) and no referrer, so an SVG
36
+ * delivered by a run is drawn without running anything it carries, and a
37
+ * file's markup never reaches the page as markup.
38
+ *
39
+ * AN UNORDERED LIST named by `label`, one item per file, so a reader hears how
40
+ * many there are before the first.
41
+ */
42
+ export declare function FileList({ files, label, className, ...rest }: FileListProps): import("react").JSX.Element;
@@ -0,0 +1,3 @@
1
+ import './FileList.css';
2
+ export { FileList } from './FileList.js';
3
+ export type { FileListItem, FileListProps } from './FileList.js';
@@ -0,0 +1,3 @@
1
+ export { FileList } from '../chunk-CZXF6EFK.js';
2
+ import '../chunk-UT6CW3C7.js';
3
+ import '../chunk-ODEQTPFM.js';