@orianatech/pire 0.20.0 → 0.22.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 (35) hide show
  1. package/dist/components/core/Badge.d.cts +14 -3
  2. package/dist/components/core/Badge.d.ts +14 -3
  3. package/dist/components/core/Badge.d.ts.map +1 -1
  4. package/dist/components/core/Tag.d.cts +8 -3
  5. package/dist/components/core/Tag.d.ts +8 -3
  6. package/dist/components/core/Tag.d.ts.map +1 -1
  7. package/dist/components/core/Text.d.cts +9 -4
  8. package/dist/components/core/Text.d.ts +9 -4
  9. package/dist/components/core/Text.d.ts.map +1 -1
  10. package/dist/components/data/DataTable.d.cts +9 -1
  11. package/dist/components/data/DataTable.d.ts +9 -1
  12. package/dist/components/data/DataTable.d.ts.map +1 -1
  13. package/dist/components/forms/ComboBox.d.cts +12 -2
  14. package/dist/components/forms/ComboBox.d.ts +12 -2
  15. package/dist/components/forms/ComboBox.d.ts.map +1 -1
  16. package/dist/components/forms/DatePicker.d.cts +18 -5
  17. package/dist/components/forms/DatePicker.d.ts +18 -5
  18. package/dist/components/forms/DatePicker.d.ts.map +1 -1
  19. package/dist/components/forms/FileUpload.d.cts +10 -2
  20. package/dist/components/forms/FileUpload.d.ts +10 -2
  21. package/dist/components/forms/FileUpload.d.ts.map +1 -1
  22. package/dist/components/forms/NumberField.d.cts +37 -7
  23. package/dist/components/forms/NumberField.d.ts +37 -7
  24. package/dist/components/forms/NumberField.d.ts.map +1 -1
  25. package/dist/components/patterns/FileDropZone.d.cts +8 -1
  26. package/dist/components/patterns/FileDropZone.d.ts +8 -1
  27. package/dist/components/patterns/FileDropZone.d.ts.map +1 -1
  28. package/dist/i18n/messages.d.cts +2 -0
  29. package/dist/i18n/messages.d.ts +2 -0
  30. package/dist/i18n/messages.d.ts.map +1 -1
  31. package/dist/index.cjs +285 -150
  32. package/dist/index.cjs.map +1 -1
  33. package/dist/index.js +305 -169
  34. package/dist/index.js.map +1 -1
  35. package/package.json +1 -1
@@ -1,9 +1,20 @@
1
- import type * as React from 'react';
1
+ import * as React from 'react';
2
2
  export type BadgeStatus = 'positive' | 'critical' | 'negative' | 'informative' | 'neutral';
3
3
  export interface BadgeProps extends React.HTMLAttributes<HTMLSpanElement> {
4
4
  /** Semantic value state. Colour is never the only signal — the icon carries the same meaning. */
5
5
  status?: BadgeStatus;
6
6
  showIcon?: boolean;
7
7
  }
8
- /** Value state on an object or row. Text is the label, never a bare colour dot. */
9
- export declare function Badge({ children, status, showIcon, className, ...rest }: BadgeProps): React.JSX.Element;
8
+ /**
9
+ * Value state on an object or row. Text is the label, never a bare colour dot.
10
+ *
11
+ * Takes a ref, which is what lets it be a `Tooltip` target: React Aria's `Focusable` clones its
12
+ * child and hands it one, and a component that cannot accept a ref leaves the tooltip **silently**
13
+ * dead — no error, and a screenshot identical to a working one.
14
+ *
15
+ * Worth stating why this was invisible for so long. Under React 19 `ref` is an ordinary prop, so it
16
+ * rode along in `...rest` and landed on the span by accident; under React 18 it is stripped before
17
+ * the component ever sees it. The library develops on 19 and had consumers on 18, so the failure
18
+ * existed only where nobody was testing.
19
+ */
20
+ export declare const Badge: React.ForwardRefExoticComponent<BadgeProps & React.RefAttributes<HTMLSpanElement>>;
@@ -1,10 +1,21 @@
1
- import type * as React from 'react';
1
+ import * as React from 'react';
2
2
  export type BadgeStatus = 'positive' | 'critical' | 'negative' | 'informative' | 'neutral';
3
3
  export interface BadgeProps extends React.HTMLAttributes<HTMLSpanElement> {
4
4
  /** Semantic value state. Colour is never the only signal — the icon carries the same meaning. */
5
5
  status?: BadgeStatus;
6
6
  showIcon?: boolean;
7
7
  }
8
- /** Value state on an object or row. Text is the label, never a bare colour dot. */
9
- export declare function Badge({ children, status, showIcon, className, ...rest }: BadgeProps): React.JSX.Element;
8
+ /**
9
+ * Value state on an object or row. Text is the label, never a bare colour dot.
10
+ *
11
+ * Takes a ref, which is what lets it be a `Tooltip` target: React Aria's `Focusable` clones its
12
+ * child and hands it one, and a component that cannot accept a ref leaves the tooltip **silently**
13
+ * dead — no error, and a screenshot identical to a working one.
14
+ *
15
+ * Worth stating why this was invisible for so long. Under React 19 `ref` is an ordinary prop, so it
16
+ * rode along in `...rest` and landed on the span by accident; under React 18 it is stripped before
17
+ * the component ever sees it. The library develops on 19 and had consumers on 18, so the failure
18
+ * existed only where nobody was testing.
19
+ */
20
+ export declare const Badge: React.ForwardRefExoticComponent<BadgeProps & React.RefAttributes<HTMLSpanElement>>;
10
21
  //# sourceMappingURL=Badge.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Badge.d.ts","sourceRoot":"","sources":["../../../src/components/core/Badge.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AAIpC,MAAM,MAAM,WAAW,GAAG,UAAU,GAAG,UAAU,GAAG,UAAU,GAAG,aAAa,GAAG,SAAS,CAAC;AAO3F,MAAM,WAAW,UAAW,SAAQ,KAAK,CAAC,cAAc,CAAC,eAAe,CAAC;IACvE,iGAAiG;IACjG,MAAM,CAAC,EAAE,WAAW,CAAC;IACrB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED,mFAAmF;AACnF,wBAAgB,KAAK,CAAC,EAAE,QAAQ,EAAE,MAAkB,EAAE,QAAe,EAAE,SAAS,EAAE,GAAG,IAAI,EAAE,EAAE,UAAU,qBAOtG"}
1
+ {"version":3,"file":"Badge.d.ts","sourceRoot":"","sources":["../../../src/components/core/Badge.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAI/B,MAAM,MAAM,WAAW,GAAG,UAAU,GAAG,UAAU,GAAG,UAAU,GAAG,aAAa,GAAG,SAAS,CAAC;AAO3F,MAAM,WAAW,UAAW,SAAQ,KAAK,CAAC,cAAc,CAAC,eAAe,CAAC;IACvE,iGAAiG;IACjG,MAAM,CAAC,EAAE,WAAW,CAAC;IACrB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,KAAK,oFAShB,CAAC"}
@@ -1,4 +1,4 @@
1
- import type * as React from 'react';
1
+ import * as React from 'react';
2
2
  export interface TagProps extends React.HTMLAttributes<HTMLSpanElement> {
3
3
  /** Provide to render the remove affordance — filter tokens, multi-select values. */
4
4
  onRemove?: () => void;
@@ -19,5 +19,10 @@ export interface TagProps extends React.HTMLAttributes<HTMLSpanElement> {
19
19
  */
20
20
  category?: 1 | 2 | 3 | 4 | 5 | 6;
21
21
  }
22
- /** A removable token: applied filters, multi-select values. */
23
- export declare function Tag({ children, onRemove, isDisabled, category, className, ...rest }: TagProps): React.JSX.Element;
22
+ /**
23
+ * A removable token: applied filters, multi-select values.
24
+ *
25
+ * Takes a ref so it can be a `Tooltip` target — a truncated category label is a common reason to
26
+ * want one. See `Badge` for why the missing ref failed silently.
27
+ */
28
+ export declare const Tag: React.ForwardRefExoticComponent<TagProps & React.RefAttributes<HTMLSpanElement>>;
@@ -1,4 +1,4 @@
1
- import type * as React from 'react';
1
+ import * as React from 'react';
2
2
  export interface TagProps extends React.HTMLAttributes<HTMLSpanElement> {
3
3
  /** Provide to render the remove affordance — filter tokens, multi-select values. */
4
4
  onRemove?: () => void;
@@ -19,6 +19,11 @@ export interface TagProps extends React.HTMLAttributes<HTMLSpanElement> {
19
19
  */
20
20
  category?: 1 | 2 | 3 | 4 | 5 | 6;
21
21
  }
22
- /** A removable token: applied filters, multi-select values. */
23
- export declare function Tag({ children, onRemove, isDisabled, category, className, ...rest }: TagProps): React.JSX.Element;
22
+ /**
23
+ * A removable token: applied filters, multi-select values.
24
+ *
25
+ * Takes a ref so it can be a `Tooltip` target — a truncated category label is a common reason to
26
+ * want one. See `Badge` for why the missing ref failed silently.
27
+ */
28
+ export declare const Tag: React.ForwardRefExoticComponent<TagProps & React.RefAttributes<HTMLSpanElement>>;
24
29
  //# sourceMappingURL=Tag.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Tag.d.ts","sourceRoot":"","sources":["../../../src/components/core/Tag.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AAKpC,MAAM,WAAW,QAAS,SAAQ,KAAK,CAAC,cAAc,CAAC,eAAe,CAAC;IACrE,oFAAoF;IACpF,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;IACtB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB;;;;;;;;;;;;;OAaG;IACH,QAAQ,CAAC,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;CAClC;AAED,+DAA+D;AAC/D,wBAAgB,GAAG,CAAC,EAAE,QAAQ,EAAE,QAAQ,EAAE,UAAU,EAAE,QAAQ,EAAE,SAAS,EAAE,GAAG,IAAI,EAAE,EAAE,QAAQ,qBAe7F"}
1
+ {"version":3,"file":"Tag.d.ts","sourceRoot":"","sources":["../../../src/components/core/Tag.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAK/B,MAAM,WAAW,QAAS,SAAQ,KAAK,CAAC,cAAc,CAAC,eAAe,CAAC;IACrE,oFAAoF;IACpF,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;IACtB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB;;;;;;;;;;;;;OAaG;IACH,QAAQ,CAAC,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;CAClC;AAED;;;;;GAKG;AACH,eAAO,MAAM,GAAG,kFAiBd,CAAC"}
@@ -1,4 +1,4 @@
1
- import type * as React from 'react';
1
+ import * as React from 'react';
2
2
  /** Colour hierarchy, named after the `--text-*` token each value resolves to. */
3
3
  export type TextColor = 'primary' | 'secondary' | 'tertiary' | 'disabled' | 'inverse';
4
4
  /** Typographic scale, named after the `--type-*` tokens. */
@@ -20,10 +20,15 @@ export interface TextProps extends Omit<React.HTMLAttributes<HTMLElement>, 'colo
20
20
  elementType?: 'p' | 'span' | 'div' | 'dd' | 'li';
21
21
  className?: string;
22
22
  }
23
- /** Body copy, captions, metadata and eyebrows — everything that is text but not a heading. */
24
- export declare function Text({ size, color, weight, numeric, eyebrow, truncate, elementType: Wrapper, className, style, ...rest }: TextProps): React.JSX.Element;
23
+ /**
24
+ * Body copy, captions, metadata and eyebrows everything that is text but not a heading.
25
+ *
26
+ * Takes a ref so it can be a `Tooltip` target, and so a clamped line can be measured to decide
27
+ * whether a tooltip is warranted at all. See `Badge` for why the missing ref failed silently.
28
+ */
29
+ export declare const Text: React.ForwardRefExoticComponent<TextProps & React.RefAttributes<HTMLElement>>;
25
30
  export interface StrongProps extends Omit<React.HTMLAttributes<HTMLElement>, 'color'> {
26
31
  className?: string;
27
32
  }
28
33
  /** Inline emphasis. Sugar over `<Text weight="strong" elementType="span">`. */
29
- export declare function Strong({ className, ...rest }: StrongProps): React.JSX.Element;
34
+ export declare const Strong: React.ForwardRefExoticComponent<StrongProps & React.RefAttributes<HTMLElement>>;
@@ -1,4 +1,4 @@
1
- import type * as React from 'react';
1
+ import * as React from 'react';
2
2
  /** Colour hierarchy, named after the `--text-*` token each value resolves to. */
3
3
  export type TextColor = 'primary' | 'secondary' | 'tertiary' | 'disabled' | 'inverse';
4
4
  /** Typographic scale, named after the `--type-*` tokens. */
@@ -20,11 +20,16 @@ export interface TextProps extends Omit<React.HTMLAttributes<HTMLElement>, 'colo
20
20
  elementType?: 'p' | 'span' | 'div' | 'dd' | 'li';
21
21
  className?: string;
22
22
  }
23
- /** Body copy, captions, metadata and eyebrows — everything that is text but not a heading. */
24
- export declare function Text({ size, color, weight, numeric, eyebrow, truncate, elementType: Wrapper, className, style, ...rest }: TextProps): React.JSX.Element;
23
+ /**
24
+ * Body copy, captions, metadata and eyebrows everything that is text but not a heading.
25
+ *
26
+ * Takes a ref so it can be a `Tooltip` target, and so a clamped line can be measured to decide
27
+ * whether a tooltip is warranted at all. See `Badge` for why the missing ref failed silently.
28
+ */
29
+ export declare const Text: React.ForwardRefExoticComponent<TextProps & React.RefAttributes<HTMLElement>>;
25
30
  export interface StrongProps extends Omit<React.HTMLAttributes<HTMLElement>, 'color'> {
26
31
  className?: string;
27
32
  }
28
33
  /** Inline emphasis. Sugar over `<Text weight="strong" elementType="span">`. */
29
- export declare function Strong({ className, ...rest }: StrongProps): React.JSX.Element;
34
+ export declare const Strong: React.ForwardRefExoticComponent<StrongProps & React.RefAttributes<HTMLElement>>;
30
35
  //# sourceMappingURL=Text.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Text.d.ts","sourceRoot":"","sources":["../../../src/components/core/Text.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AAGpC,iFAAiF;AACjF,MAAM,MAAM,SAAS,GAAG,SAAS,GAAG,WAAW,GAAG,UAAU,GAAG,UAAU,GAAG,SAAS,CAAC;AAEtF,4DAA4D;AAC5D,MAAM,MAAM,QAAQ,GAAG,MAAM,GAAG,SAAS,GAAG,SAAS,GAAG,OAAO,CAAC;AAGhE,MAAM,WAAW,SAAU,SAAQ,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,WAAW,CAAC,EAAE,OAAO,CAAC;IACjF,kDAAkD;IAClD,IAAI,CAAC,EAAE,QAAQ,CAAC;IAChB,gEAAgE;IAChE,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,kFAAkF;IAClF,MAAM,CAAC,EAAE,SAAS,GAAG,QAAQ,CAAC;IAC9B,0EAA0E;IAC1E,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,wEAAwE;IACxE,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,+DAA+D;IAC/D,QAAQ,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;IAC5B,uEAAuE;IACvE,WAAW,CAAC,EAAE,GAAG,GAAG,MAAM,GAAG,KAAK,GAAG,IAAI,GAAG,IAAI,CAAC;I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AM,CAAC;IAC5B,uEAAuE;IACvE,WAAW,CAAC,EAAE,GAAG,GAAG,MAAM,GAAG,KAAK,GAAG,IAAI,GAAG,IAAI,CAAC;IACjD,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;;;;GAKG;AACH,eAAO,MAAM,IAAI,+EAuBf,CAAC;AAEH,MAAM,WAAW,WAAY,SAAQ,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,WAAW,CAAC,EAAE,OAAO,CAAC;IACnF,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,+EAA+E;AAC/E,eAAO,MAAM,MAAM,iFAIjB,CAAC"}
@@ -38,7 +38,15 @@ export interface DataTableProps<T extends {
38
38
  rows: T[];
39
39
  /** Row height: 32 / 40 / 48px. Condensed is the analyst default. */
40
40
  density?: 'condensed' | 'regular' | 'comfortable';
41
- selectable?: boolean;
41
+ /**
42
+ * `true` / `'multiple'` gives a checkbox column and a select-all header box.
43
+ *
44
+ * `'single'` selects by pressing the row and renders **no** selection column. That is not a
45
+ * shortcut: a checkbox is a claim that more than one can be ticked, and a checkbox column that
46
+ * silently unticks the previous row reads as a bug. Prefer a master/detail list — the pattern
47
+ * `SplitPane` exists for — over a grid with one checkbox per row.
48
+ */
49
+ selectable?: boolean | 'single' | 'multiple';
42
50
  selected?: Array<string | number>;
43
51
  onSelectionChange?: (ids: Array<string | number>) => void;
44
52
  sort?: DataTableSort;
@@ -38,7 +38,15 @@ export interface DataTableProps<T extends {
38
38
  rows: T[];
39
39
  /** Row height: 32 / 40 / 48px. Condensed is the analyst default. */
40
40
  density?: 'condensed' | 'regular' | 'comfortable';
41
- selectable?: boolean;
41
+ /**
42
+ * `true` / `'multiple'` gives a checkbox column and a select-all header box.
43
+ *
44
+ * `'single'` selects by pressing the row and renders **no** selection column. That is not a
45
+ * shortcut: a checkbox is a claim that more than one can be ticked, and a checkbox column that
46
+ * silently unticks the previous row reads as a bug. Prefer a master/detail list — the pattern
47
+ * `SplitPane` exists for — over a grid with one checkbox per row.
48
+ */
49
+ selectable?: boolean | 'single' | 'multiple';
42
50
  selected?: Array<string | number>;
43
51
  onSelectionChange?: (ids: Array<string | number>) => void;
44
52
  sort?: DataTableSort;
@@ -1 +1 @@
1
- {"version":3,"file":"DataTable.d.ts","sourceRoot":"","sources":["../../../src/components/data/DataTable.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AASpC,MAAM,WAAW,eAAe,CAAC,CAAC,GAAG,GAAG;IACtC,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,GAAG,OAAO,GAAG,QAAQ,CAAC;IACpC,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,wFAAwF;IACxF,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB;;;;OAIG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,MAAM,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,KAAK,KAAK,CAAC,SAAS,CAAC;CACtC;AAED,MAAM,WAAW,aAAa;IAAG,GAAG,EAAE,MAAM,CAAC;IAAC,GAAG,EAAE,KAAK,GAAG,MAAM,CAAA;CAAE;AAEnE,MAAM,WAAW,iBAAiB;IAChC,iCAAiC;IACjC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;;OAIG;IACH,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAED,MAAM,WAAW,cAAc,CAAC,CAAC,SAAS;IAAE,EAAE,EAAE,MAAM,GAAG,MAAM,CAAA;CAAE,GAAG,GAAG;IACrE,+CAA+C;IAC/C,YAAY,EAAE,MAAM,CAAC;IACrB,OAAO,EAAE,eAAe,CAAC,CAAC,CAAC,EAAE,CAAC;IAC9B,IAAI,EAAE,CAAC,EAAE,CAAC;IACV,oEAAoE;IACpE,OAAO,CAAC,EAAE,WAAW,G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AC,EAAE,KAAK,CAAC,aAAa,CAAC;CAC7B;AAED;2FAC2F;AAC3F,wBAAgB,SAAS,CAAC,CAAC,SAAS;IAAE,EAAE,EAAE,MAAM,GAAG,MAAM,CAAA;CAAE,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE,OAAmB,EAC/F,UAAU,EAAE,QAAQ,EAAE,iBAAiB,EAAE,IAAI,EAAE,YAAY,EAAE,WAAW,EAAE,YAAmB,EAC7F,UAAU,EAAE,SAAS,EAAE,eAAe,EAAE,YAAY,EACpD,MAAM,EAAE,QAAQ,EAAE,cAAc,EAAE,WAAW,EAAE,SAAS,EAAE,KAAK,EAAE,GAAG,IAAI,EAAE,EAAE,cAAc,CAAC,CAAC,CAAC,qBAsI9F"}
@@ -1,4 +1,4 @@
1
- import type * as React from 'react';
1
+ import * as React from 'react';
2
2
  export interface ComboBoxOption {
3
3
  value: string;
4
4
  label: string;
@@ -27,6 +27,16 @@ export interface ComboBoxProps {
27
27
  */
28
28
  inputValue?: string;
29
29
  options?: Array<string | ComboBoxOption>;
30
+ /**
31
+ * Adds a button that empties the field — both the text and the selection.
32
+ *
33
+ * A required field still needs this whenever the choice is *changeable*: without it the only way
34
+ * back from a wrong pick is to select something else, so there is no way to say "not this one
35
+ * yet" short of reloading the screen.
36
+ */
37
+ isClearable?: boolean;
38
+ /** Overrides the dictionary's `inputClear`. Say what is being cleared when the field is one of several. */
39
+ clearLabel?: string;
30
40
  /**
31
41
  * `options` is the final list and React Aria filters nothing locally. Required for server
32
42
  * search: fuzzy matches, synonyms, code-to-description and server ranking do not survive a
@@ -70,4 +80,4 @@ export interface ComboBoxProps {
70
80
  }
71
81
  /** Type-ahead picker for lists too long to scroll — material, cost centre, G/L account.
72
82
  * Below ~10 fixed options use Select; for master-data search with several columns use ValueHelpField. */
73
- export declare function ComboBox({ label, value, defaultValue, onChange, onInputChange, inputValue, options, description, errorMessage, size, fullWidth, isFilteredExternally, isLoading, loadingLabel, emptyLabel, onLoadMore, className, style, ...rest }: ComboBoxProps): React.JSX.Element;
83
+ export declare function ComboBox({ label, value, defaultValue, onChange, onInputChange, inputValue, options, description, errorMessage, size, fullWidth, isFilteredExternally, isLoading, loadingLabel, emptyLabel, isClearable, clearLabel, onLoadMore, className, style, ...rest }: ComboBoxProps): React.JSX.Element;
@@ -1,4 +1,4 @@
1
- import type * as React from 'react';
1
+ import * as React from 'react';
2
2
  export interface ComboBoxOption {
3
3
  value: string;
4
4
  label: string;
@@ -27,6 +27,16 @@ export interface ComboBoxProps {
27
27
  */
28
28
  inputValue?: string;
29
29
  options?: Array<string | ComboBoxOption>;
30
+ /**
31
+ * Adds a button that empties the field — both the text and the selection.
32
+ *
33
+ * A required field still needs this whenever the choice is *changeable*: without it the only way
34
+ * back from a wrong pick is to select something else, so there is no way to say "not this one
35
+ * yet" short of reloading the screen.
36
+ */
37
+ isClearable?: boolean;
38
+ /** Overrides the dictionary's `inputClear`. Say what is being cleared when the field is one of several. */
39
+ clearLabel?: string;
30
40
  /**
31
41
  * `options` is the final list and React Aria filters nothing locally. Required for server
32
42
  * search: fuzzy matches, synonyms, code-to-description and server ranking do not survive a
@@ -70,5 +80,5 @@ export interface ComboBoxProps {
70
80
  }
71
81
  /** Type-ahead picker for lists too long to scroll — material, cost centre, G/L account.
72
82
  * Below ~10 fixed options use Select; for master-data search with several columns use ValueHelpField. */
73
- export declare function ComboBox({ label, value, defaultValue, onChange, onInputChange, inputValue, options, description, errorMessage, size, fullWidth, isFilteredExternally, isLoading, loadingLabel, emptyLabel, onLoadMore, className, style, ...rest }: ComboBoxProps): React.JSX.Element;
83
+ export declare function ComboBox({ label, value, defaultValue, onChange, onInputChange, inputValue, options, description, errorMessage, size, fullWidth, isFilteredExternally, isLoading, loadingLabel, emptyLabel, isClearable, clearLabel, onLoadMore, className, style, ...rest }: ComboBoxProps): React.JSX.Element;
74
84
  //# sourceMappingURL=ComboBox.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ComboBox.d.ts","sourceRoot":"","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SAAgB,EAAE,oBAAoB,EAAE,SAAS,EACzF,YAAY,EAAE,UAAU,EAAE,WAAW,EAAE,UAAU,EAAE,UAAU,EAAE,SAAS,EAAE,KAAK,EAAE,GAAG,IAAI,EAAE,EAAE,aAAa,qBAgH1G"}
@@ -1,10 +1,23 @@
1
1
  import type * as React from 'react';
2
2
  import type { DateValue } from 'react-aria-components';
3
- export interface DatePickerProps {
3
+ export interface DatePickerProps<TFormat extends 'object' | 'iso' = 'object'> {
4
4
  label?: React.ReactNode;
5
- value?: DateValue | null;
6
- defaultValue?: DateValue | null;
7
- onChange?: (value: DateValue | null) => void;
5
+ /** A `DateValue`, or the `YYYY-MM-DD` string one arrived as — a value straight off a JSON
6
+ * response needs no conversion. A datetime is accepted and trimmed to its date (`date`
7
+ * columns commonly serialise as `"2026-08-14T00:00:00.000000Z"`); the time and zone are
8
+ * discarded, because a `DateValue` is a calendar date and holds neither. A malformed date
9
+ * shows as an empty field rather than throwing. */
10
+ value?: DateValue | string | null;
11
+ defaultValue?: DateValue | string | null;
12
+ onChange?: (value: (TFormat extends 'iso' ? string : DateValue) | null) => void;
13
+ /**
14
+ * The shape `onChange` emits.
15
+ *
16
+ * `'object'` (the default) emits the `@internationalized/date` `DateValue` this component has
17
+ * always emitted. `'iso'` emits the `YYYY-MM-DD` string a consumer sends back to its API, and
18
+ * `null` for an empty field. Input accepts both shapes in either mode.
19
+ */
20
+ valueFormat?: TFormat;
8
21
  minValue?: DateValue;
9
22
  maxValue?: DateValue;
10
23
  /** Return true for dates that cannot be picked — factory calendar, blocked periods. */
@@ -24,4 +37,4 @@ export interface DatePickerProps {
24
37
  /** Date entry with a segmented field and a calendar popover. Segments follow the user's locale,
25
38
  * so a German user types dd.mm.yyyy without any prop change. Wrap the app in React Aria's
26
39
  * I18nProvider to pin a locale. */
27
- export declare function DatePicker({ label, description, errorMessage, size, fullWidth, className, style, ...rest }: DatePickerProps): React.JSX.Element;
40
+ export declare function DatePicker<TFormat extends 'object' | 'iso' = 'object'>({ label, description, errorMessage, size, fullWidth, className, style, value, defaultValue, onChange, valueFormat, ...rest }: DatePickerProps<TFormat>): React.JSX.Element;
@@ -1,10 +1,23 @@
1
1
  import type * as React from 'react';
2
2
  import type { DateValue } from 'react-aria-components';
3
- export interface DatePickerProps {
3
+ export interface DatePickerProps<TFormat extends 'object' | 'iso' = 'object'> {
4
4
  label?: React.ReactNode;
5
- value?: DateValue | null;
6
- defaultValue?: DateValue | null;
7
- onChange?: (value: DateValue | null) => void;
5
+ /** A `DateValue`, or the `YYYY-MM-DD` string one arrived as — a value straight off a JSON
6
+ * response needs no conversion. A datetime is accepted and trimmed to its date (`date`
7
+ * columns commonly serialise as `"2026-08-14T00:00:00.000000Z"`); the time and zone are
8
+ * discarded, because a `DateValue` is a calendar date and holds neither. A malformed date
9
+ * shows as an empty field rather than throwing. */
10
+ value?: DateValue | string | null;
11
+ defaultValue?: DateValue | string | null;
12
+ onChange?: (value: (TFormat extends 'iso' ? string : DateValue) | null) => void;
13
+ /**
14
+ * The shape `onChange` emits.
15
+ *
16
+ * `'object'` (the default) emits the `@internationalized/date` `DateValue` this component has
17
+ * always emitted. `'iso'` emits the `YYYY-MM-DD` string a consumer sends back to its API, and
18
+ * `null` for an empty field. Input accepts both shapes in either mode.
19
+ */
20
+ valueFormat?: TFormat;
8
21
  minValue?: DateValue;
9
22
  maxValue?: DateValue;
10
23
  /** Return true for dates that cannot be picked — factory calendar, blocked periods. */
@@ -24,5 +37,5 @@ export interface DatePickerProps {
24
37
  /** Date entry with a segmented field and a calendar popover. Segments follow the user's locale,
25
38
  * so a German user types dd.mm.yyyy without any prop change. Wrap the app in React Aria's
26
39
  * I18nProvider to pin a locale. */
27
- export declare function DatePicker({ label, description, errorMessage, size, fullWidth, className, style, ...rest }: DatePickerProps): React.JSX.Element;
40
+ export declare function DatePicker<TFormat extends 'object' | 'iso' = 'object'>({ label, description, errorMessage, size, fullWidth, className, style, value, defaultValue, onChange, valueFormat, ...rest }: DatePickerProps<TFormat>): React.JSX.Element;
28
41
  //# sourceMappingURL=DatePicker.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"DatePicker.d.ts","sourceRoot":"","sources":["../../../src/components/forms/DatePicker.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AAIpC,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAKvD,MAAM,WAAW,eAAe;IAC9B,KAAK,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACxB,KAAK,CAAC,EAAE,SAAS,GAAG,IAAI,CAAC;IACzB,YAAY,CAAC,EAAE,SAAS,GAAG,IAAI,CAAC;IAChC,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,SAAS,GAAG,IAAI,KAAK,IAAI,CAAC;IAC7C,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,uFAAuF;IACvF,iBAAiB,CAAC,EAAE,CAAC,IAAI,EAAE,SAAS,KAAK,OAAO,CAAC;IACjD,WAAW,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC9B,YAAY,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC/B,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,IAAI,CAAC,EAAE,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;IAC1B,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;CAC7B;AAED;;oCAEoC;AACpC,wBAAgB,UAAU,CAAC,EAAE,KAAK,EAAE,WAAW,EAAE,YAAY,EAAE,IAAW,EAAE,SAAgB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AAM,CAAC;IACd,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;CAC7B;AAwBD;;oCAEoC;AACpC,wBAAgB,UAAU,CAAC,OAAO,SAAS,QAAQ,GAAG,KAAK,GAAG,QAAQ,EAAE,EAAE,KAAK,EAAE,WAAW,EAC1F,YAAY,EAAE,IAAW,EAAE,SAAgB,EAAE,SAAS,EAAE,KAAK,EAAE,KAAK,EAAE,YAAY,EAAE,QAAQ,EAC5F,WAAW,EAAE,GAAG,IAAI,EAAE,EAAE,eAAe,CAAC,OAAO,CAAC,qBAoDjD"}
@@ -9,7 +9,15 @@ export interface FileRejection {
9
9
  file: File;
10
10
  reason: 'size' | 'type';
11
11
  }
12
- export interface FileUploadProps {
12
+ /**
13
+ * Everything a caller can put on the wrapper: `id`, `data-*`, `aria-describedby`.
14
+ *
15
+ * The omissions are this component's own props under names the DOM also uses, and would otherwise
16
+ * collide: `onChange` and `onError` carry files and rejections rather than DOM events, and
17
+ * `defaultValue` a file list rather than a string.
18
+ */
19
+ export type FileFieldPassthrough = Omit<React.HTMLAttributes<HTMLDivElement>, 'onChange' | 'onError' | 'defaultValue' | 'color'>;
20
+ export interface FileUploadProps extends FileFieldPassthrough {
13
21
  label?: React.ReactNode;
14
22
  /** Controlled / uncontrolled, the same pair as `Tabs` and `MultiComboBox`. */
15
23
  value?: PireFile[];
@@ -54,4 +62,4 @@ export declare function screenFiles(files: File[], { maxSize, acceptedFileTypes
54
62
  * uploads nothing: the app owns the `FormData`, the request and the progress it reports back
55
63
  * through `uploadProgress`.
56
64
  */
57
- export declare function FileUpload({ label, value, defaultValue, onChange, acceptedFileTypes, allowsMultiple, maxSize, onError, showPreview, uploadProgress, chooseLabel, description, errorMessage, isInvalid, isDisabled, isReadOnly, isRequired, fullWidth, className, style, }: FileUploadProps): React.JSX.Element;
65
+ export declare function FileUpload({ label, value, defaultValue, onChange, acceptedFileTypes, allowsMultiple, maxSize, onError, showPreview, uploadProgress, chooseLabel, description, errorMessage, isInvalid, isDisabled, isReadOnly, isRequired, fullWidth, className, style, ...rest }: FileUploadProps): React.JSX.Element;
@@ -9,7 +9,15 @@ export interface FileRejection {
9
9
  file: File;
10
10
  reason: 'size' | 'type';
11
11
  }
12
- export interface FileUploadProps {
12
+ /**
13
+ * Everything a caller can put on the wrapper: `id`, `data-*`, `aria-describedby`.
14
+ *
15
+ * The omissions are this component's own props under names the DOM also uses, and would otherwise
16
+ * collide: `onChange` and `onError` carry files and rejections rather than DOM events, and
17
+ * `defaultValue` a file list rather than a string.
18
+ */
19
+ export type FileFieldPassthrough = Omit<React.HTMLAttributes<HTMLDivElement>, 'onChange' | 'onError' | 'defaultValue' | 'color'>;
20
+ export interface FileUploadProps extends FileFieldPassthrough {
13
21
  label?: React.ReactNode;
14
22
  /** Controlled / uncontrolled, the same pair as `Tabs` and `MultiComboBox`. */
15
23
  value?: PireFile[];
@@ -54,5 +62,5 @@ export declare function screenFiles(files: File[], { maxSize, acceptedFileTypes
54
62
  * uploads nothing: the app owns the `FormData`, the request and the progress it reports back
55
63
  * through `uploadProgress`.
56
64
  */
57
- export declare function FileUpload({ label, value, defaultValue, onChange, acceptedFileTypes, allowsMultiple, maxSize, onError, showPreview, uploadProgress, chooseLabel, description, errorMessage, isInvalid, isDisabled, isReadOnly, isRequired, fullWidth, className, style, }: FileUploadProps): React.JSX.Element;
65
+ export declare function FileUpload({ label, value, defaultValue, onChange, acceptedFileTypes, allowsMultiple, maxSize, onError, showPreview, uploadProgress, chooseLabel, description, errorMessage, isInvalid, isDisabled, isReadOnly, isRequired, fullWidth, className, style, ...rest }: FileUploadProps): React.JSX.Element;
58
66
  //# sourceMappingURL=FileUpload.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"FileUpload.d.ts","sourceRoot":"","sources":["../../../src/components/forms/FileUpload.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAS/B,MAAM,WAA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iB,EAAE,EAAE;IAAE,OAAO,CAAC,EAAE,MAAM,CAAC;IAAC,iBAAiB,CAAC,EAAE,SAAS,MAAM,EAAE,CAAA;CAAE,GAC1F;IAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;IAAC,QAAQ,EAAE,aAAa,EAAE,CAAA;CAAE,CAwBjD;AAED;;;;GAIG;AACH,wBAAgB,UAAU,CAAC,EACzB,KAAK,EAAE,KAAK,EAAE,YAAY,EAAE,QAAQ,EAAE,iBAAiB,EAAE,cAAc,EAAE,OAAO,EAAE,OAAO,EACzF,WAAkB,EAAE,cAAc,EAAE,WAAW,EAAE,WAAW,EAAE,YAAY,EAC1E,SAAS,EAAE,UAAU,EAAE,UAAU,EAAE,UAAU,EAAE,SAAgB,EAAE,SAAS,EAAE,KAAK,EAAE,GAAG,IAAI,EAC3F,EAAE,eAAe,qBA2EjB"}
@@ -1,12 +1,27 @@
1
1
  import type * as React from 'react';
2
- export interface NumberFieldProps {
2
+ export interface NumberFieldProps<TEmpty extends '' | null = never> {
3
3
  label?: React.ReactNode;
4
4
  /** Accessible name when `label` is omitted — e.g. in a table cell where the column header
5
5
  * already carries the visible text. A field with neither is unnamed and fails axe. */
6
6
  'aria-label'?: string;
7
- value?: number;
8
- defaultValue?: number;
9
- onChange?: (value: number) => void;
7
+ /** A figure, or the string one arrived as — a `decimal` column serialises as `"1500.00"`, so
8
+ * a value straight off a JSON response needs no conversion. Strings are read with `Number`,
9
+ * which is machine format only: `"1500.00"`, never the `"1.500,00"` the field *displays*
10
+ * under es-PY. Anything unparseable shows as empty rather than as `NaN`. */
11
+ value?: number | string | null;
12
+ defaultValue?: number | string | null;
13
+ onChange?: (value: number | NoInfer<TEmpty>) => void;
14
+ /**
15
+ * What this field uses to mean "empty", in both directions: accepted in `value` and emitted by
16
+ * `onChange`.
17
+ *
18
+ * Defaults to `NaN`, which is what React Aria uses internally and what this component has
19
+ * always emitted. Declare `''` or `null` when the form is serialised to JSON: `NaN` does not
20
+ * survive `JSON.stringify` (it becomes `null`) and compares `false` against everything
21
+ * including itself, so a guard like `Math.abs(total) > 0` reads an empty field as a balanced
22
+ * one.
23
+ */
24
+ emptyValue?: TEmpty;
10
25
  minValue?: number;
11
26
  maxValue?: number;
12
27
  step?: number;
@@ -28,6 +43,21 @@ export interface NumberFieldProps {
28
43
  className?: string;
29
44
  style?: React.CSSProperties;
30
45
  }
31
- /** Quantities, prices and any figure the user edits. Always right-aligned tabular mono, with
32
- * arrow-key and scroll stepping supplied by React Aria. */
33
- export declare function NumberField({ label, suffix, description, errorMessage, hideStepper, size, fullWidth, className, style, ...rest }: NumberFieldProps): React.JSX.Element;
46
+ /**
47
+ * Quantities, prices and any figure the user edits. Always right-aligned tabular mono, with
48
+ * arrow-key and scroll stepping supplied by React Aria.
49
+ *
50
+ * **`onChange` fires on commit — blur, Enter or a stepper press — never per keystroke.** That is
51
+ * React Aria's design and it is the right one: a formatted number field passes through states like
52
+ * `1,` and `-` that must not reach the form.
53
+ *
54
+ * The consequence is worth knowing before you hit it. **Do not disable an action on this field's
55
+ * value.** Typing `50000` and pressing an `isDisabled={amount <= 0}` button swallows the first
56
+ * press: the field has not committed yet, so the button is still disabled when the pointer goes
57
+ * down, and it takes a second click. It is not a race that can be tuned away — a test that clicks
58
+ * such a button deadlocks outright, waiting for an enabled state that only that click can produce.
59
+ *
60
+ * Enable the action and validate when it is pressed, surfacing the reason. A disabled control that
61
+ * does not say why is a worse affordance regardless, so the fix costs nothing.
62
+ */
63
+ export declare function NumberField<TEmpty extends '' | null = never>({ label, suffix, description, errorMessage, hideStepper, size, fullWidth, className, style, value, defaultValue, onChange, emptyValue, ...rest }: NumberFieldProps<TEmpty>): React.JSX.Element;
@@ -1,12 +1,27 @@
1
1
  import type * as React from 'react';
2
- export interface NumberFieldProps {
2
+ export interface NumberFieldProps<TEmpty extends '' | null = never> {
3
3
  label?: React.ReactNode;
4
4
  /** Accessible name when `label` is omitted — e.g. in a table cell where the column header
5
5
  * already carries the visible text. A field with neither is unnamed and fails axe. */
6
6
  'aria-label'?: string;
7
- value?: number;
8
- defaultValue?: number;
9
- onChange?: (value: number) => void;
7
+ /** A figure, or the string one arrived as — a `decimal` column serialises as `"1500.00"`, so
8
+ * a value straight off a JSON response needs no conversion. Strings are read with `Number`,
9
+ * which is machine format only: `"1500.00"`, never the `"1.500,00"` the field *displays*
10
+ * under es-PY. Anything unparseable shows as empty rather than as `NaN`. */
11
+ value?: number | string | null;
12
+ defaultValue?: number | string | null;
13
+ onChange?: (value: number | NoInfer<TEmpty>) => void;
14
+ /**
15
+ * What this field uses to mean "empty", in both directions: accepted in `value` and emitted by
16
+ * `onChange`.
17
+ *
18
+ * Defaults to `NaN`, which is what React Aria uses internally and what this component has
19
+ * always emitted. Declare `''` or `null` when the form is serialised to JSON: `NaN` does not
20
+ * survive `JSON.stringify` (it becomes `null`) and compares `false` against everything
21
+ * including itself, so a guard like `Math.abs(total) > 0` reads an empty field as a balanced
22
+ * one.
23
+ */
24
+ emptyValue?: TEmpty;
10
25
  minValue?: number;
11
26
  maxValue?: number;
12
27
  step?: number;
@@ -28,7 +43,22 @@ export interface NumberFieldProps {
28
43
  className?: string;
29
44
  style?: React.CSSProperties;
30
45
  }
31
- /** Quantities, prices and any figure the user edits. Always right-aligned tabular mono, with
32
- * arrow-key and scroll stepping supplied by React Aria. */
33
- export declare function NumberField({ label, suffix, description, errorMessage, hideStepper, size, fullWidth, className, style, ...rest }: NumberFieldProps): React.JSX.Element;
46
+ /**
47
+ * Quantities, prices and any figure the user edits. Always right-aligned tabular mono, with
48
+ * arrow-key and scroll stepping supplied by React Aria.
49
+ *
50
+ * **`onChange` fires on commit — blur, Enter or a stepper press — never per keystroke.** That is
51
+ * React Aria's design and it is the right one: a formatted number field passes through states like
52
+ * `1,` and `-` that must not reach the form.
53
+ *
54
+ * The consequence is worth knowing before you hit it. **Do not disable an action on this field's
55
+ * value.** Typing `50000` and pressing an `isDisabled={amount <= 0}` button swallows the first
56
+ * press: the field has not committed yet, so the button is still disabled when the pointer goes
57
+ * down, and it takes a second click. It is not a race that can be tuned away — a test that clicks
58
+ * such a button deadlocks outright, waiting for an enabled state that only that click can produce.
59
+ *
60
+ * Enable the action and validate when it is pressed, surfacing the reason. A disabled control that
61
+ * does not say why is a worse affordance regardless, so the fix costs nothing.
62
+ */
63
+ export declare function NumberField<TEmpty extends '' | null = never>({ label, suffix, description, errorMessage, hideStepper, size, fullWidth, className, style, value, defaultValue, onChange, emptyValue, ...rest }: NumberFieldProps<TEmpty>): React.JSX.Element;
34
64
  //# sourceMappingURL=NumberField.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"NumberField.d.ts","sourceRoot":"","sources":["../../../src/components/forms/NumberField.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AAOpC,MAAM,WAAW,gBAAgB;IAC/B,KAAK,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACxB;2FACuF;IACvF,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACnC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,sGAAsG;IACtG,aAAa,CAAC,EAAE,IAAI,CAAC,mBAAmB,CAAC;IACzC,uDAAuD;IACvD,MAAM,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACzB,WAAW,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC9B,YAAY,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC/B,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,E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C,EAAE,IAAI,CAAC,mBAAmB,CAAC;IACzC,uDAAuD;IACvD,MAAM,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACzB,WAAW,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC9B,YAAY,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC/B,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,+EAA+E;IAC/E,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,IAAI,CAAC,EAAE,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;IAC1B,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;CAC7B;AAeD;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,WAAW,CAAC,MAAM,SAAS,EAAE,GAAG,IAAI,GAAG,KAAK,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,WAAW,EACxF,YAAY,EAAE,WAAW,EAAE,IAAW,EAAE,SAAgB,EAAE,SAAS,EAAE,KAAK,EAAE,KAAK,EAAE,YAAY,EAC/F,QAAQ,EAAE,UAAU,EAAE,GAAG,IAAI,EAAE,EAAE,gBAAgB,CAAC,MAAM,CAAC,qBA+D1D"}
@@ -5,6 +5,13 @@ export interface FileDropZoneProps extends Omit<FileUploadProps, 'chooseLabel'>
5
5
  promptLabel?: React.ReactNode;
6
6
  /** `compact` for an import modal, where the zone competes with a table for height. */
7
7
  height?: 'compact' | 'regular';
8
+ /**
9
+ * Accessible name for the drop target when `label` is omitted.
10
+ *
11
+ * It lands on the `DropZone` rather than the wrapper, because the drop target is the thing
12
+ * being named — React Aria gives it a button role, and an unnamed one fails axe.
13
+ */
14
+ 'aria-label'?: string;
8
15
  }
9
16
  /**
10
17
  * The large drop surface, for import screens and anywhere a file is the point of the page.
@@ -13,4 +20,4 @@ export interface FileDropZoneProps extends Omit<FileUploadProps, 'chooseLabel'>
13
20
  * not a div with `onDragOver`. It still contains a `FileTrigger`, because drag-and-drop alone is
14
21
  * not an accessible way to supply a file.
15
22
  */
16
- export declare function FileDropZone({ label, value, defaultValue, onChange, acceptedFileTypes, allowsMultiple, maxSize, onError, showPreview, uploadProgress, promptLabel, height, description, errorMessage, isInvalid, isDisabled, isReadOnly, isRequired, fullWidth, className, style, }: FileDropZoneProps): React.JSX.Element;
23
+ export declare function FileDropZone({ label, value, defaultValue, onChange, acceptedFileTypes, allowsMultiple, maxSize, onError, showPreview, uploadProgress, promptLabel, height, description, errorMessage, isInvalid, isDisabled, isReadOnly, isRequired, fullWidth, className, style, 'aria-label': ariaLabel, ...rest }: FileDropZoneProps): React.JSX.Element;
@@ -5,6 +5,13 @@ export interface FileDropZoneProps extends Omit<FileUploadProps, 'chooseLabel'>
5
5
  promptLabel?: React.ReactNode;
6
6
  /** `compact` for an import modal, where the zone competes with a table for height. */
7
7
  height?: 'compact' | 'regular';
8
+ /**
9
+ * Accessible name for the drop target when `label` is omitted.
10
+ *
11
+ * It lands on the `DropZone` rather than the wrapper, because the drop target is the thing
12
+ * being named — React Aria gives it a button role, and an unnamed one fails axe.
13
+ */
14
+ 'aria-label'?: string;
8
15
  }
9
16
  /**
10
17
  * The large drop surface, for import screens and anywhere a file is the point of the page.
@@ -13,5 +20,5 @@ export interface FileDropZoneProps extends Omit<FileUploadProps, 'chooseLabel'>
13
20
  * not a div with `onDragOver`. It still contains a `FileTrigger`, because drag-and-drop alone is
14
21
  * not an accessible way to supply a file.
15
22
  */
16
- export declare function FileDropZone({ label, value, defaultValue, onChange, acceptedFileTypes, allowsMultiple, maxSize, onError, showPreview, uploadProgress, promptLabel, height, description, errorMessage, isInvalid, isDisabled, isReadOnly, isRequired, fullWidth, className, style, }: FileDropZoneProps): React.JSX.Element;
23
+ export declare function FileDropZone({ label, value, defaultValue, onChange, acceptedFileTypes, allowsMultiple, maxSize, onError, showPreview, uploadProgress, promptLabel, height, description, errorMessage, isInvalid, isDisabled, isReadOnly, isRequired, fullWidth, className, style, 'aria-label': ariaLabel, ...rest }: FileDropZoneProps): React.JSX.Element;
17
24
  //# sourceMappingURL=FileDropZone.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"FileDropZone.d.ts","sourceRoot":"","sources":["../../../src/components/patterns/FileDropZone.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAM/B,OAAO,EAA+B,KAAK,eAAe,EAAiB,MAAM,qBAAqB,CAAC;AAIvG,MAAM,WAAW,iBAAkB,SAAQ,IAAI,CAAC,eAAe,EAAE,aAAa,CAAC;IAC7E,oFAAoF;IACpF,WAAW,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC9B,sFAAsF;IACtF,MAAM,CAAC,EAAE,SAAS,GAAG,SAAS,CAAC;CAChC;AAID;;;;;;GAMG;AACH,wBAAgB,YAAY,CAAC,EAC3B,KAAK,EAAE,KAAK,EAAE,YAAY,EAAE,QAAQ,EAAE,iBAAiB,EAAE,cAAc,EAAE,OAAO,EAAE,OAAO,EACzF,WAAkB,EAAE,cAAc,EAAE,WAAW,EAAE,MAAkB,EAAE,WAAW,EAAE,YAAY,EAC9F,SAAS,EAAE,UAAU,EAAE,UAAU,EAAE,UAAU,EAAE,SAAgB,EAAE,SAAS,EAAE,KAAK,GAClF,EAAE,iBAAiB,qBAyFnB"}
1
+ {"version":3,"file":"FileDropZone.d.ts","sourceRoot":"","sources":["../../../src/components/patterns/FileDropZone.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAM/B,OAAO,EAA+B,KAAK,eAAe,EAAiB,MAAM,qBAAqB,CAAC;AAIvG,MAAM,WAAW,iBAAkB,SAAQ,IAAI,CAAC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