@ai-matrx/design-system 0.61.2 → 0.61.4
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.
- package/CHANGELOG.md +30 -0
- package/dist/controls.cjs +11 -2
- package/dist/controls.cjs.map +1 -1
- package/dist/controls.css +40 -3
- package/dist/controls.d.cts +11 -2
- package/dist/controls.d.ts +11 -2
- package/dist/controls.js +11 -2
- package/dist/controls.js.map +1 -1
- package/dist/data-table/copy-helpers.d.cts +1 -1
- package/dist/data-table/copy-helpers.d.ts +1 -1
- package/dist/data-table/filter-engine.d.cts +1 -1
- package/dist/data-table/filter-engine.d.ts +1 -1
- package/dist/data-table/host.d.cts +1 -1
- package/dist/data-table/host.d.ts +1 -1
- package/dist/data-table/index.cjs +48 -28
- package/dist/data-table/index.cjs.map +1 -1
- package/dist/data-table/index.d.cts +2 -2
- package/dist/data-table/index.d.ts +2 -2
- package/dist/data-table/index.js +48 -28
- package/dist/data-table/index.js.map +1 -1
- package/dist/data-table/infer-filter.d.cts +1 -1
- package/dist/data-table/infer-filter.d.ts +1 -1
- package/dist/data-table/layered-filters.d.cts +1 -1
- package/dist/data-table/layered-filters.d.ts +1 -1
- package/dist/data-table/query-control.d.cts +1 -1
- package/dist/data-table/query-control.d.ts +1 -1
- package/dist/data-table/types.cjs.map +1 -1
- package/dist/data-table/types.d.cts +1 -1
- package/dist/data-table/types.d.ts +1 -1
- package/dist/data-table/url-state.d.cts +1 -1
- package/dist/data-table/url-state.d.ts +1 -1
- package/dist/data-table/xlsx.d.cts +1 -1
- package/dist/data-table/xlsx.d.ts +1 -1
- package/dist/{layered-filters-CkkbZfmk.d.ts → layered-filters-CCWzLsOC.d.ts} +4 -0
- package/dist/{layered-filters-dlFZjEqc.d.cts → layered-filters-DL5BU8Mf.d.cts} +4 -0
- package/dist/tap-target.css +6 -0
- package/package.json +1 -1
package/dist/controls.css
CHANGED
|
@@ -37,6 +37,7 @@
|
|
|
37
37
|
--matrx-control-touch: 2.75rem; /* 44px hit area on coarse pointers */
|
|
38
38
|
--matrx-control-row: 2.25rem; /* 36px hairline row */
|
|
39
39
|
--matrx-control-radius-surface: 0.5rem; /* 8px card skin */
|
|
40
|
+
--matrx-control-field-radius: 9999px; /* fields are capsules (owner pick over 8px) */
|
|
40
41
|
}
|
|
41
42
|
|
|
42
43
|
/* THE CONTROL SCOPE. Until the tap tokens themselves move to 28/34 (the
|
|
@@ -118,7 +119,9 @@
|
|
|
118
119
|
|
|
119
120
|
/* ── Button ──────────────────────────────────────────────────────────── */
|
|
120
121
|
.matrx-control-button {
|
|
121
|
-
|
|
122
|
+
/* Content alignment is placement (ui-drift's one table): a full-width
|
|
123
|
+
action row may say \`justify-start\`. */
|
|
124
|
+
justify-content: center;
|
|
122
125
|
padding-block: 0 !important;
|
|
123
126
|
padding-inline: var(--matrx-control-inset-text) !important;
|
|
124
127
|
border: 1px solid transparent !important;
|
|
@@ -174,11 +177,30 @@
|
|
|
174
177
|
[data-matrx-row-actions] .matrx-control-button[data-variant="quiet"]:not([data-delete]) {
|
|
175
178
|
color: hsl(var(--muted-foreground)) !important;
|
|
176
179
|
}
|
|
177
|
-
.matrx-control-list-row:hover [data-matrx-row-actions] .matrx-control-button[data-variant="quiet"]:not([data-delete]),
|
|
178
|
-
.matrx-control-list-row:focus-within [data-matrx-row-actions] .matrx-control-button[data-variant="quiet"]:not([data-delete]) {
|
|
180
|
+
:is(.matrx-control-list-row, .matrx-control-setting-row):hover [data-matrx-row-actions] .matrx-control-button[data-variant="quiet"]:not([data-delete]),
|
|
181
|
+
:is(.matrx-control-list-row, .matrx-control-setting-row):focus-within [data-matrx-row-actions] .matrx-control-button[data-variant="quiet"]:not([data-delete]) {
|
|
179
182
|
color: hsl(var(--foreground)) !important;
|
|
180
183
|
}
|
|
181
184
|
|
|
185
|
+
/* Split button: the pair carries the half-gap; inside it they join. */
|
|
186
|
+
.matrx-control-split {
|
|
187
|
+
display: inline-flex !important;
|
|
188
|
+
flex-shrink: 0;
|
|
189
|
+
margin-inline: var(--matrx-control-half-gap) !important;
|
|
190
|
+
}
|
|
191
|
+
.matrx-control-split > .matrx-control {
|
|
192
|
+
margin-inline: 0 !important;
|
|
193
|
+
}
|
|
194
|
+
.matrx-control-split > .matrx-control:not(:last-child) {
|
|
195
|
+
border-start-end-radius: 0 !important;
|
|
196
|
+
border-end-end-radius: 0 !important;
|
|
197
|
+
}
|
|
198
|
+
.matrx-control-split > .matrx-control:not(:first-child) {
|
|
199
|
+
border-start-start-radius: 0 !important;
|
|
200
|
+
border-end-start-radius: 0 !important;
|
|
201
|
+
border-inline-start: 1px solid hsl(var(--background) / 0.3) !important;
|
|
202
|
+
}
|
|
203
|
+
|
|
182
204
|
/* ── Field (input capsule) and Select trigger ───────────────────────── */
|
|
183
205
|
.matrx-control-field,
|
|
184
206
|
.matrx-control-select {
|
|
@@ -190,6 +212,7 @@
|
|
|
190
212
|
font-weight: 400 !important;
|
|
191
213
|
min-width: 0;
|
|
192
214
|
box-shadow: none !important;
|
|
215
|
+
border-radius: var(--matrx-control-field-radius) !important;
|
|
193
216
|
}
|
|
194
217
|
.matrx-control-field[data-glyph="start"] {
|
|
195
218
|
padding-inline-start: var(--matrx-control-inset-glyph) !important;
|
|
@@ -209,6 +232,17 @@
|
|
|
209
232
|
color: inherit;
|
|
210
233
|
cursor: text;
|
|
211
234
|
}
|
|
235
|
+
.matrx-control-field > button {
|
|
236
|
+
all: unset;
|
|
237
|
+
display: inline-flex;
|
|
238
|
+
flex-shrink: 0;
|
|
239
|
+
align-items: center;
|
|
240
|
+
color: hsl(var(--muted-foreground));
|
|
241
|
+
cursor: pointer;
|
|
242
|
+
}
|
|
243
|
+
.matrx-control-field > button:hover {
|
|
244
|
+
color: hsl(var(--foreground));
|
|
245
|
+
}
|
|
212
246
|
.matrx-control-field > input::placeholder {
|
|
213
247
|
color: hsl(var(--muted-foreground));
|
|
214
248
|
}
|
|
@@ -314,6 +348,9 @@
|
|
|
314
348
|
scrollbar-width: none;
|
|
315
349
|
border-bottom: 1px solid hsl(var(--border)) !important;
|
|
316
350
|
}
|
|
351
|
+
.matrx-control-tabs[data-rule="none"] {
|
|
352
|
+
border-bottom: 0 !important;
|
|
353
|
+
}
|
|
317
354
|
.matrx-control-tab {
|
|
318
355
|
box-sizing: border-box !important;
|
|
319
356
|
position: relative;
|
package/dist/controls.d.cts
CHANGED
|
@@ -55,9 +55,13 @@ type ButtonProps = LabelledButton | IconOnlyButton;
|
|
|
55
55
|
* icon + text, or icon-only (a 28px circle). `asChild` puts the skin on a link.
|
|
56
56
|
*/
|
|
57
57
|
declare const Button: React.ForwardRefExoticComponent<ButtonProps & React.RefAttributes<HTMLButtonElement>>;
|
|
58
|
+
/** A split button: two Buttons joined — the act, and its menu of variants. */
|
|
59
|
+
declare const SplitButton: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
58
60
|
interface FieldProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, "size"> {
|
|
59
61
|
/** Leading 16px glyph. */
|
|
60
62
|
icon?: React.ReactNode;
|
|
63
|
+
/** Trailing content inside the capsule — a clear button, a unit. */
|
|
64
|
+
end?: React.ReactNode;
|
|
61
65
|
}
|
|
62
66
|
/** The input capsule. `className`/`style` place the capsule (width, flex). */
|
|
63
67
|
declare const Field: React.ForwardRefExoticComponent<FieldProps & React.RefAttributes<HTMLInputElement>>;
|
|
@@ -89,6 +93,8 @@ interface SegmentOption<T extends string = string> {
|
|
|
89
93
|
/** An 11px count after the label. */
|
|
90
94
|
count?: number | null;
|
|
91
95
|
ariaLabel?: string;
|
|
96
|
+
/** Hover text (an icon-only segment's name). */
|
|
97
|
+
title?: string;
|
|
92
98
|
disabled?: boolean;
|
|
93
99
|
}
|
|
94
100
|
interface SegmentedControlProps<T extends string = string> {
|
|
@@ -105,9 +111,12 @@ declare function SegmentedControl<T extends string = string>({ value, onValueCha
|
|
|
105
111
|
interface TabsProps<T extends string = string> extends SegmentedControlProps<T> {
|
|
106
112
|
/** `underline` for page sections (default); `capsule` for filters. */
|
|
107
113
|
variant?: "underline" | "capsule";
|
|
114
|
+
/** Underline tabs draw their own hairline (default). Pass `false` when the row the tabs
|
|
115
|
+
* sit in already draws it — the selected underline then lands on that row's rule. */
|
|
116
|
+
rule?: boolean;
|
|
108
117
|
}
|
|
109
118
|
/** Tabs: underline for page sections, capsule for filters. */
|
|
110
|
-
declare function Tabs<T extends string = string>({ variant, value, onValueChange, data, className, style, "aria-label": ariaLabel, }: TabsProps<T>): React.JSX.Element;
|
|
119
|
+
declare function Tabs<T extends string = string>({ variant, rule, value, onValueChange, data, className, style, "aria-label": ariaLabel, }: TabsProps<T>): React.JSX.Element;
|
|
111
120
|
type BadgeTone = "neutral" | "primary" | "success" | "warning" | "destructive" | "info";
|
|
112
121
|
interface BadgeProps extends React.HTMLAttributes<HTMLSpanElement> {
|
|
113
122
|
/** A status tint from the role tokens. Default `neutral` (plain outline). */
|
|
@@ -229,4 +238,4 @@ interface PromoBannerProps {
|
|
|
229
238
|
*/
|
|
230
239
|
declare function PromoBanner({ icon, eyebrow, title, line, chips, action, tone, className, "aria-label": ariaLabel, }: PromoBannerProps): React.JSX.Element;
|
|
231
240
|
|
|
232
|
-
export { Badge, type BadgeProps, type BadgeTone, Button, type ButtonProps, ConfirmDelete, type ConfirmDeleteProps, ControlRow, type ControlRowProps, ControlScope, type ControlVariant, DangerZone, DeleteButton, type DeleteButtonProps, EmptyState, type EmptyStateProps, Field, type FieldProps, PromoBanner, type PromoBannerProps, type PromoTone, RegionSkeleton, type RegionSkeletonProps, RowGroup, type RowGroupProps, SearchField, type SegmentOption, SegmentedControl, type SegmentedControlProps, Select, type SelectOption, type SelectProps, SettingRow, type SettingRowProps, Switch, type SwitchProps, Tabs, type TabsProps, Textarea };
|
|
241
|
+
export { Badge, type BadgeProps, type BadgeTone, Button, type ButtonProps, ConfirmDelete, type ConfirmDeleteProps, ControlRow, type ControlRowProps, ControlScope, type ControlVariant, DangerZone, DeleteButton, type DeleteButtonProps, EmptyState, type EmptyStateProps, Field, type FieldProps, PromoBanner, type PromoBannerProps, type PromoTone, RegionSkeleton, type RegionSkeletonProps, RowGroup, type RowGroupProps, SearchField, type SegmentOption, SegmentedControl, type SegmentedControlProps, Select, type SelectOption, type SelectProps, SettingRow, type SettingRowProps, SplitButton, Switch, type SwitchProps, Tabs, type TabsProps, Textarea };
|
package/dist/controls.d.ts
CHANGED
|
@@ -55,9 +55,13 @@ type ButtonProps = LabelledButton | IconOnlyButton;
|
|
|
55
55
|
* icon + text, or icon-only (a 28px circle). `asChild` puts the skin on a link.
|
|
56
56
|
*/
|
|
57
57
|
declare const Button: React.ForwardRefExoticComponent<ButtonProps & React.RefAttributes<HTMLButtonElement>>;
|
|
58
|
+
/** A split button: two Buttons joined — the act, and its menu of variants. */
|
|
59
|
+
declare const SplitButton: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
58
60
|
interface FieldProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, "size"> {
|
|
59
61
|
/** Leading 16px glyph. */
|
|
60
62
|
icon?: React.ReactNode;
|
|
63
|
+
/** Trailing content inside the capsule — a clear button, a unit. */
|
|
64
|
+
end?: React.ReactNode;
|
|
61
65
|
}
|
|
62
66
|
/** The input capsule. `className`/`style` place the capsule (width, flex). */
|
|
63
67
|
declare const Field: React.ForwardRefExoticComponent<FieldProps & React.RefAttributes<HTMLInputElement>>;
|
|
@@ -89,6 +93,8 @@ interface SegmentOption<T extends string = string> {
|
|
|
89
93
|
/** An 11px count after the label. */
|
|
90
94
|
count?: number | null;
|
|
91
95
|
ariaLabel?: string;
|
|
96
|
+
/** Hover text (an icon-only segment's name). */
|
|
97
|
+
title?: string;
|
|
92
98
|
disabled?: boolean;
|
|
93
99
|
}
|
|
94
100
|
interface SegmentedControlProps<T extends string = string> {
|
|
@@ -105,9 +111,12 @@ declare function SegmentedControl<T extends string = string>({ value, onValueCha
|
|
|
105
111
|
interface TabsProps<T extends string = string> extends SegmentedControlProps<T> {
|
|
106
112
|
/** `underline` for page sections (default); `capsule` for filters. */
|
|
107
113
|
variant?: "underline" | "capsule";
|
|
114
|
+
/** Underline tabs draw their own hairline (default). Pass `false` when the row the tabs
|
|
115
|
+
* sit in already draws it — the selected underline then lands on that row's rule. */
|
|
116
|
+
rule?: boolean;
|
|
108
117
|
}
|
|
109
118
|
/** Tabs: underline for page sections, capsule for filters. */
|
|
110
|
-
declare function Tabs<T extends string = string>({ variant, value, onValueChange, data, className, style, "aria-label": ariaLabel, }: TabsProps<T>): React.JSX.Element;
|
|
119
|
+
declare function Tabs<T extends string = string>({ variant, rule, value, onValueChange, data, className, style, "aria-label": ariaLabel, }: TabsProps<T>): React.JSX.Element;
|
|
111
120
|
type BadgeTone = "neutral" | "primary" | "success" | "warning" | "destructive" | "info";
|
|
112
121
|
interface BadgeProps extends React.HTMLAttributes<HTMLSpanElement> {
|
|
113
122
|
/** A status tint from the role tokens. Default `neutral` (plain outline). */
|
|
@@ -229,4 +238,4 @@ interface PromoBannerProps {
|
|
|
229
238
|
*/
|
|
230
239
|
declare function PromoBanner({ icon, eyebrow, title, line, chips, action, tone, className, "aria-label": ariaLabel, }: PromoBannerProps): React.JSX.Element;
|
|
231
240
|
|
|
232
|
-
export { Badge, type BadgeProps, type BadgeTone, Button, type ButtonProps, ConfirmDelete, type ConfirmDeleteProps, ControlRow, type ControlRowProps, ControlScope, type ControlVariant, DangerZone, DeleteButton, type DeleteButtonProps, EmptyState, type EmptyStateProps, Field, type FieldProps, PromoBanner, type PromoBannerProps, type PromoTone, RegionSkeleton, type RegionSkeletonProps, RowGroup, type RowGroupProps, SearchField, type SegmentOption, SegmentedControl, type SegmentedControlProps, Select, type SelectOption, type SelectProps, SettingRow, type SettingRowProps, Switch, type SwitchProps, Tabs, type TabsProps, Textarea };
|
|
241
|
+
export { Badge, type BadgeProps, type BadgeTone, Button, type ButtonProps, ConfirmDelete, type ConfirmDeleteProps, ControlRow, type ControlRowProps, ControlScope, type ControlVariant, DangerZone, DeleteButton, type DeleteButtonProps, EmptyState, type EmptyStateProps, Field, type FieldProps, PromoBanner, type PromoBannerProps, type PromoTone, RegionSkeleton, type RegionSkeletonProps, RowGroup, type RowGroupProps, SearchField, type SegmentOption, SegmentedControl, type SegmentedControlProps, Select, type SelectOption, type SelectProps, SettingRow, type SettingRowProps, SplitButton, Switch, type SwitchProps, Tabs, type TabsProps, Textarea };
|
package/dist/controls.js
CHANGED
|
@@ -756,8 +756,12 @@ var Button2 = React7.forwardRef(
|
|
|
756
756
|
}
|
|
757
757
|
);
|
|
758
758
|
Button2.displayName = "Button";
|
|
759
|
+
var SplitButton = React7.forwardRef(
|
|
760
|
+
({ className, ...props }, ref) => /* @__PURE__ */ jsx7("div", { ref, role: "group", "data-matrx-control": "split", className: cn("matrx-control-split", className), ...props })
|
|
761
|
+
);
|
|
762
|
+
SplitButton.displayName = "SplitButton";
|
|
759
763
|
var Field = React7.forwardRef(
|
|
760
|
-
({ className, style, icon, ...props }, ref) => /* @__PURE__ */ jsxs5(
|
|
764
|
+
({ className, style, icon, end, ...props }, ref) => /* @__PURE__ */ jsxs5(
|
|
761
765
|
"label",
|
|
762
766
|
{
|
|
763
767
|
"data-matrx-control": "field",
|
|
@@ -766,7 +770,8 @@ var Field = React7.forwardRef(
|
|
|
766
770
|
style,
|
|
767
771
|
children: [
|
|
768
772
|
icon,
|
|
769
|
-
/* @__PURE__ */ jsx7("input", { ref, ...props })
|
|
773
|
+
/* @__PURE__ */ jsx7("input", { ref, ...props }),
|
|
774
|
+
end
|
|
770
775
|
]
|
|
771
776
|
}
|
|
772
777
|
)
|
|
@@ -839,6 +844,7 @@ function SegmentItems({
|
|
|
839
844
|
"aria-selected": role ? on : void 0,
|
|
840
845
|
"aria-pressed": role ? void 0 : on,
|
|
841
846
|
"aria-label": o.ariaLabel,
|
|
847
|
+
title: o.title,
|
|
842
848
|
disabled: o.disabled,
|
|
843
849
|
"data-state": on ? "on" : "off",
|
|
844
850
|
className: "matrx-control-segment",
|
|
@@ -874,6 +880,7 @@ function SegmentedControl({
|
|
|
874
880
|
}
|
|
875
881
|
function Tabs({
|
|
876
882
|
variant = "underline",
|
|
883
|
+
rule = true,
|
|
877
884
|
value,
|
|
878
885
|
onValueChange,
|
|
879
886
|
data,
|
|
@@ -900,6 +907,7 @@ function Tabs({
|
|
|
900
907
|
role: "tablist",
|
|
901
908
|
"aria-label": ariaLabel,
|
|
902
909
|
"data-matrx-control": "tabs",
|
|
910
|
+
"data-rule": rule ? void 0 : "none",
|
|
903
911
|
className: cn("matrx-control-tabs", className),
|
|
904
912
|
style,
|
|
905
913
|
children: data.map((o) => /* @__PURE__ */ jsxs5(
|
|
@@ -1420,6 +1428,7 @@ export {
|
|
|
1420
1428
|
SegmentedControl,
|
|
1421
1429
|
Select,
|
|
1422
1430
|
SettingRow,
|
|
1431
|
+
SplitButton,
|
|
1423
1432
|
Switch,
|
|
1424
1433
|
Tabs,
|
|
1425
1434
|
Textarea
|