@proteos/ui 0.56.0 → 0.57.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 (45) hide show
  1. package/dist/{chunk-IKAX76MB.js → chunk-NSE4VW3Z.js} +45 -21
  2. package/dist/chunk-NSE4VW3Z.js.map +1 -0
  3. package/dist/{chunk-MWAXK66H.cjs → chunk-NWGG5WFL.cjs} +45 -21
  4. package/dist/chunk-NWGG5WFL.cjs.map +1 -0
  5. package/dist/index.cjs +336 -351
  6. package/dist/index.cjs.map +1 -1
  7. package/dist/index.d.cts +41 -12
  8. package/dist/index.d.ts +41 -12
  9. package/dist/index.js +83 -98
  10. package/dist/index.js.map +1 -1
  11. package/dist/{pdf-view-MH75RVQP.js → pdf-view-RQ2OZYHJ.js} +3 -3
  12. package/dist/{pdf-view-MH75RVQP.js.map → pdf-view-RQ2OZYHJ.js.map} +1 -1
  13. package/dist/{pdf-view-K4MMVHVY.cjs → pdf-view-RRMAUK3L.cjs} +7 -7
  14. package/dist/{pdf-view-K4MMVHVY.cjs.map → pdf-view-RRMAUK3L.cjs.map} +1 -1
  15. package/package.json +2 -2
  16. package/src/components/avatar/avatar.stories.tsx +13 -0
  17. package/src/components/avatar/avatar.tsx +16 -9
  18. package/src/components/badge-multi-select/badge-multi-select.tsx +2 -2
  19. package/src/components/button/button.stories.tsx +202 -97
  20. package/src/components/button/button.test.tsx +40 -7
  21. package/src/components/button/button.tsx +71 -18
  22. package/src/components/combobox/combobox.tsx +2 -2
  23. package/src/components/currency-input/currency-input.tsx +2 -2
  24. package/src/components/date-picker/calendar-internals.tsx +1 -1
  25. package/src/components/date-picker/date-picker.tsx +3 -3
  26. package/src/components/date-time-picker/date-time-picker.tsx +3 -3
  27. package/src/components/icon-picker/icon-picker.tsx +2 -2
  28. package/src/components/image-lightbox/image-lightbox.tsx +2 -2
  29. package/src/components/menu/menu.tsx +2 -2
  30. package/src/components/modal/modal.tsx +4 -4
  31. package/src/components/multi-select/multi-select.tsx +2 -2
  32. package/src/components/popover/popover.tsx +2 -2
  33. package/src/components/record-filter/nested-group.tsx +2 -2
  34. package/src/components/record-filter/record-filter-builder-panel.tsx +11 -23
  35. package/src/components/record-filter/record-filter-chips.tsx +3 -10
  36. package/src/components/segmented-control/segmented-control.stories.tsx +134 -8
  37. package/src/components/segmented-control/segmented-control.test.tsx +81 -8
  38. package/src/components/segmented-control/segmented-control.tsx +38 -19
  39. package/src/components/select/select.tsx +2 -2
  40. package/src/components/time-field/time-field.tsx +1 -1
  41. package/src/components/toast/toast.tsx +2 -2
  42. package/src/components/tooltip/tooltip.tsx +2 -2
  43. package/src/styles.css +58 -0
  44. package/dist/chunk-IKAX76MB.js.map +0 -1
  45. package/dist/chunk-MWAXK66H.cjs.map +0 -1
package/dist/index.d.cts CHANGED
@@ -113,6 +113,10 @@ declare const avatarStyles: tailwind_variants.TVReturnType<{
113
113
  terra: string;
114
114
  slate: string;
115
115
  };
116
+ shape: {
117
+ circle: string;
118
+ square: string;
119
+ };
116
120
  }, undefined, string[], {
117
121
  size: {
118
122
  sm: string;
@@ -127,6 +131,10 @@ declare const avatarStyles: tailwind_variants.TVReturnType<{
127
131
  terra: string;
128
132
  slate: string;
129
133
  };
134
+ shape: {
135
+ circle: string;
136
+ square: string;
137
+ };
130
138
  }, undefined, tailwind_variants.TVReturnType<{
131
139
  size: {
132
140
  sm: string;
@@ -141,6 +149,10 @@ declare const avatarStyles: tailwind_variants.TVReturnType<{
141
149
  terra: string;
142
150
  slate: string;
143
151
  };
152
+ shape: {
153
+ circle: string;
154
+ square: string;
155
+ };
144
156
  }, undefined, string[], unknown, unknown, undefined>>;
145
157
  type AvatarVariants = VariantProps<typeof avatarStyles>;
146
158
  type AvatarProps = HTMLAttributes<HTMLSpanElement> & AvatarVariants & {
@@ -154,7 +166,7 @@ type AvatarProps = HTMLAttributes<HTMLSpanElement> & AvatarVariants & {
154
166
  /** Alt text for the image. Defaults to empty — the avatar is decorative. */
155
167
  alt?: string;
156
168
  };
157
- declare function Avatar({ size, tone, initials, src, alt, className, children, ...props }: AvatarProps): react_jsx_runtime.JSX.Element;
169
+ declare function Avatar({ size, tone, shape, initials, src, alt, className, children, ...props }: AvatarProps): react_jsx_runtime.JSX.Element;
158
170
 
159
171
  declare const avatarGroupStyles: tailwind_variants.TVReturnType<{
160
172
  size: {
@@ -477,12 +489,14 @@ declare function Breadcrumbs({ items, separator, className, ...props }: Breadcru
477
489
 
478
490
  declare const buttonStyles: tailwind_variants.TVReturnType<{
479
491
  variant: {
480
- primary: string[];
492
+ cta: string[];
481
493
  accent: string[];
494
+ primary: string[];
482
495
  secondary: string[];
483
496
  ghost: string[];
484
497
  subtle: string[];
485
498
  link: string[];
499
+ danger: string[];
486
500
  };
487
501
  size: {
488
502
  sm: string;
@@ -498,12 +512,14 @@ declare const buttonStyles: tailwind_variants.TVReturnType<{
498
512
  };
499
513
  }, undefined, string[], {
500
514
  variant: {
501
- primary: string[];
515
+ cta: string[];
502
516
  accent: string[];
517
+ primary: string[];
503
518
  secondary: string[];
504
519
  ghost: string[];
505
520
  subtle: string[];
506
521
  link: string[];
522
+ danger: string[];
507
523
  };
508
524
  size: {
509
525
  sm: string;
@@ -519,12 +535,14 @@ declare const buttonStyles: tailwind_variants.TVReturnType<{
519
535
  };
520
536
  }, undefined, tailwind_variants.TVReturnType<{
521
537
  variant: {
522
- primary: string[];
538
+ cta: string[];
523
539
  accent: string[];
540
+ primary: string[];
524
541
  secondary: string[];
525
542
  ghost: string[];
526
543
  subtle: string[];
527
544
  link: string[];
545
+ danger: string[];
528
546
  };
529
547
  size: {
530
548
  sm: string;
@@ -2705,10 +2723,12 @@ declare const segmentedControlStyles: tailwind_variants.TVReturnType<{
2705
2723
  segment: string;
2706
2724
  };
2707
2725
  };
2708
- tone: {
2709
- default: {
2726
+ wrap: {
2727
+ true: {
2728
+ group: string;
2710
2729
  segment: string;
2711
2730
  };
2731
+ false: {};
2712
2732
  };
2713
2733
  }, {
2714
2734
  group: string;
@@ -2722,10 +2742,12 @@ declare const segmentedControlStyles: tailwind_variants.TVReturnType<{
2722
2742
  segment: string;
2723
2743
  };
2724
2744
  };
2725
- tone: {
2726
- default: {
2745
+ wrap: {
2746
+ true: {
2747
+ group: string;
2727
2748
  segment: string;
2728
2749
  };
2750
+ false: {};
2729
2751
  };
2730
2752
  }, {
2731
2753
  group: string;
@@ -2739,10 +2761,12 @@ declare const segmentedControlStyles: tailwind_variants.TVReturnType<{
2739
2761
  segment: string;
2740
2762
  };
2741
2763
  };
2742
- tone: {
2743
- default: {
2764
+ wrap: {
2765
+ true: {
2766
+ group: string;
2744
2767
  segment: string;
2745
2768
  };
2769
+ false: {};
2746
2770
  };
2747
2771
  }, {
2748
2772
  group: string;
@@ -2753,12 +2777,17 @@ type SegmentedControlOption<T extends Key$1 = Key$1> = {
2753
2777
  id: T;
2754
2778
  label: ReactNode;
2755
2779
  isDisabled?: boolean;
2780
+ /** Accessible name for icon-only segments. */
2781
+ 'aria-label'?: string;
2756
2782
  };
2757
2783
  type SegmentedControlProps<T extends Key$1 = Key$1> = Omit<RadioGroupProps$1, 'children' | 'value' | 'onChange'> & {
2758
2784
  options: ReadonlyArray<SegmentedControlOption<T>>;
2759
- value: T;
2785
+ /** `null` renders no selected segment. */
2786
+ value: T | null;
2760
2787
  onChange: (value: T) => void;
2761
2788
  size?: SegmentedControlVariants['size'];
2789
+ /** Flow-wrap long option lists; segments share the line equally. */
2790
+ wrap?: boolean;
2762
2791
  /** Focus the selected segment on mount. RAC's RadioGroup doesn't surface
2763
2792
  * `autoFocus` itself — it's a per-Radio prop — so we apply it to the
2764
2793
  * Radio whose value matches `value`. */
@@ -2766,7 +2795,7 @@ type SegmentedControlProps<T extends Key$1 = Key$1> = Omit<RadioGroupProps$1, 'c
2766
2795
  /** Visual override for the group wrapper. */
2767
2796
  className?: string;
2768
2797
  };
2769
- declare function SegmentedControl<T extends Key$1>({ options, value, onChange, size, autoFocus, className, orientation, ...props }: SegmentedControlProps<T>): react_jsx_runtime.JSX.Element;
2798
+ declare function SegmentedControl<T extends Key$1>({ options, value, onChange, size, wrap, autoFocus, className, orientation, ...props }: SegmentedControlProps<T>): react_jsx_runtime.JSX.Element;
2770
2799
 
2771
2800
  type SelectOption<T extends Key = Key> = {
2772
2801
  id: T;
package/dist/index.d.ts CHANGED
@@ -113,6 +113,10 @@ declare const avatarStyles: tailwind_variants.TVReturnType<{
113
113
  terra: string;
114
114
  slate: string;
115
115
  };
116
+ shape: {
117
+ circle: string;
118
+ square: string;
119
+ };
116
120
  }, undefined, string[], {
117
121
  size: {
118
122
  sm: string;
@@ -127,6 +131,10 @@ declare const avatarStyles: tailwind_variants.TVReturnType<{
127
131
  terra: string;
128
132
  slate: string;
129
133
  };
134
+ shape: {
135
+ circle: string;
136
+ square: string;
137
+ };
130
138
  }, undefined, tailwind_variants.TVReturnType<{
131
139
  size: {
132
140
  sm: string;
@@ -141,6 +149,10 @@ declare const avatarStyles: tailwind_variants.TVReturnType<{
141
149
  terra: string;
142
150
  slate: string;
143
151
  };
152
+ shape: {
153
+ circle: string;
154
+ square: string;
155
+ };
144
156
  }, undefined, string[], unknown, unknown, undefined>>;
145
157
  type AvatarVariants = VariantProps<typeof avatarStyles>;
146
158
  type AvatarProps = HTMLAttributes<HTMLSpanElement> & AvatarVariants & {
@@ -154,7 +166,7 @@ type AvatarProps = HTMLAttributes<HTMLSpanElement> & AvatarVariants & {
154
166
  /** Alt text for the image. Defaults to empty — the avatar is decorative. */
155
167
  alt?: string;
156
168
  };
157
- declare function Avatar({ size, tone, initials, src, alt, className, children, ...props }: AvatarProps): react_jsx_runtime.JSX.Element;
169
+ declare function Avatar({ size, tone, shape, initials, src, alt, className, children, ...props }: AvatarProps): react_jsx_runtime.JSX.Element;
158
170
 
159
171
  declare const avatarGroupStyles: tailwind_variants.TVReturnType<{
160
172
  size: {
@@ -477,12 +489,14 @@ declare function Breadcrumbs({ items, separator, className, ...props }: Breadcru
477
489
 
478
490
  declare const buttonStyles: tailwind_variants.TVReturnType<{
479
491
  variant: {
480
- primary: string[];
492
+ cta: string[];
481
493
  accent: string[];
494
+ primary: string[];
482
495
  secondary: string[];
483
496
  ghost: string[];
484
497
  subtle: string[];
485
498
  link: string[];
499
+ danger: string[];
486
500
  };
487
501
  size: {
488
502
  sm: string;
@@ -498,12 +512,14 @@ declare const buttonStyles: tailwind_variants.TVReturnType<{
498
512
  };
499
513
  }, undefined, string[], {
500
514
  variant: {
501
- primary: string[];
515
+ cta: string[];
502
516
  accent: string[];
517
+ primary: string[];
503
518
  secondary: string[];
504
519
  ghost: string[];
505
520
  subtle: string[];
506
521
  link: string[];
522
+ danger: string[];
507
523
  };
508
524
  size: {
509
525
  sm: string;
@@ -519,12 +535,14 @@ declare const buttonStyles: tailwind_variants.TVReturnType<{
519
535
  };
520
536
  }, undefined, tailwind_variants.TVReturnType<{
521
537
  variant: {
522
- primary: string[];
538
+ cta: string[];
523
539
  accent: string[];
540
+ primary: string[];
524
541
  secondary: string[];
525
542
  ghost: string[];
526
543
  subtle: string[];
527
544
  link: string[];
545
+ danger: string[];
528
546
  };
529
547
  size: {
530
548
  sm: string;
@@ -2705,10 +2723,12 @@ declare const segmentedControlStyles: tailwind_variants.TVReturnType<{
2705
2723
  segment: string;
2706
2724
  };
2707
2725
  };
2708
- tone: {
2709
- default: {
2726
+ wrap: {
2727
+ true: {
2728
+ group: string;
2710
2729
  segment: string;
2711
2730
  };
2731
+ false: {};
2712
2732
  };
2713
2733
  }, {
2714
2734
  group: string;
@@ -2722,10 +2742,12 @@ declare const segmentedControlStyles: tailwind_variants.TVReturnType<{
2722
2742
  segment: string;
2723
2743
  };
2724
2744
  };
2725
- tone: {
2726
- default: {
2745
+ wrap: {
2746
+ true: {
2747
+ group: string;
2727
2748
  segment: string;
2728
2749
  };
2750
+ false: {};
2729
2751
  };
2730
2752
  }, {
2731
2753
  group: string;
@@ -2739,10 +2761,12 @@ declare const segmentedControlStyles: tailwind_variants.TVReturnType<{
2739
2761
  segment: string;
2740
2762
  };
2741
2763
  };
2742
- tone: {
2743
- default: {
2764
+ wrap: {
2765
+ true: {
2766
+ group: string;
2744
2767
  segment: string;
2745
2768
  };
2769
+ false: {};
2746
2770
  };
2747
2771
  }, {
2748
2772
  group: string;
@@ -2753,12 +2777,17 @@ type SegmentedControlOption<T extends Key$1 = Key$1> = {
2753
2777
  id: T;
2754
2778
  label: ReactNode;
2755
2779
  isDisabled?: boolean;
2780
+ /** Accessible name for icon-only segments. */
2781
+ 'aria-label'?: string;
2756
2782
  };
2757
2783
  type SegmentedControlProps<T extends Key$1 = Key$1> = Omit<RadioGroupProps$1, 'children' | 'value' | 'onChange'> & {
2758
2784
  options: ReadonlyArray<SegmentedControlOption<T>>;
2759
- value: T;
2785
+ /** `null` renders no selected segment. */
2786
+ value: T | null;
2760
2787
  onChange: (value: T) => void;
2761
2788
  size?: SegmentedControlVariants['size'];
2789
+ /** Flow-wrap long option lists; segments share the line equally. */
2790
+ wrap?: boolean;
2762
2791
  /** Focus the selected segment on mount. RAC's RadioGroup doesn't surface
2763
2792
  * `autoFocus` itself — it's a per-Radio prop — so we apply it to the
2764
2793
  * Radio whose value matches `value`. */
@@ -2766,7 +2795,7 @@ type SegmentedControlProps<T extends Key$1 = Key$1> = Omit<RadioGroupProps$1, 'c
2766
2795
  /** Visual override for the group wrapper. */
2767
2796
  className?: string;
2768
2797
  };
2769
- declare function SegmentedControl<T extends Key$1>({ options, value, onChange, size, autoFocus, className, orientation, ...props }: SegmentedControlProps<T>): react_jsx_runtime.JSX.Element;
2798
+ declare function SegmentedControl<T extends Key$1>({ options, value, onChange, size, wrap, autoFocus, className, orientation, ...props }: SegmentedControlProps<T>): react_jsx_runtime.JSX.Element;
2770
2799
 
2771
2800
  type SelectOption<T extends Key = Key> = {
2772
2801
  id: T;