@jonmilner/ui 0.11.5 → 0.11.6
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/dist/Table/Table.css +1 -1
- package/dist/Table/Table.css.mjs +2 -2
- package/dist/Table/index.d.mts +14 -2
- package/dist/Table/index.mjs +73 -61
- package/dist/docs/Icon.md +2 -0
- package/dist/docs/Table.md +43 -1
- package/dist/docs/manifest.json +18 -1
- package/dist/icons/ArrowDownIcon.d.mts +2 -0
- package/dist/icons/ArrowDownIcon.mjs +10 -0
- package/dist/icons/ArrowUpIcon.d.mts +2 -0
- package/dist/icons/ArrowUpIcon.mjs +10 -0
- package/dist/icons/index.d.mts +4 -2
- package/dist/icons/index.mjs +26 -24
- package/dist/index.d.mts +2 -2
- package/package.json +1 -1
package/dist/Table/Table.css
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
@layer tokens, reset, atoms.base, atoms.sm, atoms.med, atoms.lg, atoms.xl, components.box, components.checkbox, components.clickable, components.icon, components.icon-button, components.inline, components.stack, components.text, components.avatar, components.badge, components.button, components.chip, components.field, components.color-field, components.heading, components.dialog, components.alert-dialog, components.menu, components.multiselect, components.search-field, components.switch, components.tabs, components.tag, components.text-field, components.textarea, components.toast, components.visually-hidden, components.table;
|
|
2
|
-
@layer components.table{.pbjodu0{border-collapse:collapse}.pbjodu1{table-layout:auto}.pbjodu2{table-layout:fixed}.pbjodu4{border-block-end:var(--space-1) solid var(--color-border);vertical-align:middle}.pbjodu5{caption-side:top}@media (hover:hover){:where(tbody)>.pbjodu3:hover{background-image:linear-gradient(color-mix(in srgb, var(--color-fg) 5%, transparent), color-mix(in srgb, var(--color-fg) 5%, transparent))}}@media (forced-colors:active){:where(tbody)>.pbjodu3:hover{background-image:none}}}
|
|
2
|
+
@layer components.table{.pbjodu0{border-collapse:collapse}.pbjodu1{table-layout:auto}.pbjodu2{table-layout:fixed}.pbjodu4{border-block-end:var(--space-1) solid var(--color-border);vertical-align:middle}.pbjodu5{caption-side:top}.pbjodu6{visibility:hidden}@media (hover:hover){:where(tbody)>.pbjodu3:hover{background-image:linear-gradient(color-mix(in srgb, var(--color-fg) 5%, transparent), color-mix(in srgb, var(--color-fg) 5%, transparent))}}@media (forced-colors:active){:where(tbody)>.pbjodu3:hover{background-image:none}}}
|
package/dist/Table/Table.css.mjs
CHANGED
|
@@ -12,5 +12,5 @@ var t = e({
|
|
|
12
12
|
} },
|
|
13
13
|
defaultVariants: {},
|
|
14
14
|
compoundVariants: []
|
|
15
|
-
}), n = "pbjodu3", r = "pbjodu4", i = "pbjodu5";
|
|
16
|
-
export { i as caption, r as cell, n as row, t as table };
|
|
15
|
+
}), n = "pbjodu3", r = "pbjodu4", i = "pbjodu5", a = "pbjodu6";
|
|
16
|
+
export { i as caption, r as cell, n as row, t as table, a as unsortedArrow };
|
package/dist/Table/index.d.mts
CHANGED
|
@@ -36,9 +36,21 @@ type Numeric = {
|
|
|
36
36
|
numeric?: boolean;
|
|
37
37
|
};
|
|
38
38
|
export type TableCellProps = Element<"td", CellText & Numeric>;
|
|
39
|
+
export type TableSortDirection = "ascending" | "descending" | "none";
|
|
40
|
+
type Sort = {
|
|
41
|
+
hideLabel?: never;
|
|
42
|
+
onSort: () => void;
|
|
43
|
+
sort: TableSortDirection;
|
|
44
|
+
} | {
|
|
45
|
+
hideLabel?: boolean;
|
|
46
|
+
onSort?: never;
|
|
47
|
+
sort?: never;
|
|
48
|
+
};
|
|
39
49
|
export type TableHeaderCellProps = Element<"th", CellText & Numeric & {
|
|
40
50
|
hideLabel?: boolean;
|
|
41
|
-
|
|
51
|
+
onSort?: () => void;
|
|
52
|
+
sort?: TableSortDirection;
|
|
53
|
+
}> & Sort;
|
|
42
54
|
declare function TableRoot({ caption, hideCaption, layout, inlineSize, className, children, ...props }: TableProps): import("react").JSX.Element;
|
|
43
55
|
declare function TableHead(props: TableHeadProps): import("react").JSX.Element;
|
|
44
56
|
declare function TableBody(props: TableBodyProps): import("react").JSX.Element;
|
|
@@ -47,7 +59,7 @@ declare function TableRow({ tone, "aria-busy": busy, backgroundColor, color, cla
|
|
|
47
59
|
declare function TableColumnGroup(props: TableColumnGroupProps): import("react").JSX.Element;
|
|
48
60
|
declare function TableColumn(props: TableColumnProps): import("react").JSX.Element;
|
|
49
61
|
declare function TableCell({ numeric, size, display, paddingBlock, paddingInline, textAlign, className, ...props }: TableCellProps): import("react").JSX.Element;
|
|
50
|
-
declare function TableHeaderCell({ scope, numeric, hideLabel, size, weight, color, display, paddingBlock, paddingInline, textAlign, className, children, ...props }: TableHeaderCellProps): import("react").JSX.Element;
|
|
62
|
+
declare function TableHeaderCell({ scope, numeric, hideLabel, sort, onSort, size, weight, color, display, paddingBlock, paddingInline, textAlign, className, children, ...props }: TableHeaderCellProps): import("react").JSX.Element;
|
|
51
63
|
export declare const Table: typeof TableRoot & {
|
|
52
64
|
Head: typeof TableHead;
|
|
53
65
|
Body: typeof TableBody;
|
package/dist/Table/index.mjs
CHANGED
|
@@ -1,110 +1,122 @@
|
|
|
1
1
|
import { join as e } from "../styles/join.mjs";
|
|
2
2
|
import { Box as t } from "../Box/base.mjs";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
3
|
+
import { Clickable as n } from "../Clickable/index.mjs";
|
|
4
|
+
import { Text as r } from "../Text/index.mjs";
|
|
5
|
+
import { subtleFills as i } from "../styles/subtle-fills.mjs";
|
|
6
|
+
import { ArrowDownIcon as a } from "../icons/ArrowDownIcon.mjs";
|
|
7
|
+
import { ArrowUpIcon as o } from "../icons/ArrowUpIcon.mjs";
|
|
8
|
+
import { VisuallyHidden as s } from "../VisuallyHidden/index.mjs";
|
|
9
|
+
import { caption as c, cell as l, row as u, table as d, unsortedArrow as f } from "./Table.css.mjs";
|
|
10
|
+
import { jsx as p, jsxs as m } from "react/jsx-runtime";
|
|
8
11
|
// src/Table/index.tsx
|
|
9
|
-
function
|
|
10
|
-
return /* @__PURE__ */
|
|
11
|
-
...
|
|
12
|
+
function h({ caption: n, hideCaption: i = !1, layout: a = "auto", inlineSize: o = "full", className: l, children: u, ...f }) {
|
|
13
|
+
return /* @__PURE__ */ m(t, {
|
|
14
|
+
...f,
|
|
12
15
|
as: "table",
|
|
13
|
-
className: e(
|
|
14
|
-
inlineSize:
|
|
15
|
-
children: [
|
|
16
|
+
className: e(d({ layout: a }), l),
|
|
17
|
+
inlineSize: o,
|
|
18
|
+
children: [n === void 0 ? null : i ? /* @__PURE__ */ p(s, {
|
|
16
19
|
as: "caption",
|
|
17
|
-
children:
|
|
18
|
-
}) : /* @__PURE__ */
|
|
20
|
+
children: n
|
|
21
|
+
}) : /* @__PURE__ */ p(r, {
|
|
19
22
|
as: "caption",
|
|
20
|
-
className:
|
|
23
|
+
className: c,
|
|
21
24
|
display: null,
|
|
22
25
|
paddingBlockEnd: "12",
|
|
23
26
|
size: "sm",
|
|
24
27
|
textAlign: "start",
|
|
25
28
|
weight: "semibold",
|
|
26
|
-
children:
|
|
27
|
-
}),
|
|
29
|
+
children: n
|
|
30
|
+
}), u]
|
|
28
31
|
});
|
|
29
32
|
}
|
|
30
|
-
function
|
|
31
|
-
return /* @__PURE__ */
|
|
33
|
+
function g(e) {
|
|
34
|
+
return /* @__PURE__ */ p(t, {
|
|
32
35
|
...e,
|
|
33
36
|
as: "thead"
|
|
34
37
|
});
|
|
35
38
|
}
|
|
36
|
-
function
|
|
37
|
-
return /* @__PURE__ */
|
|
39
|
+
function _(e) {
|
|
40
|
+
return /* @__PURE__ */ p(t, {
|
|
38
41
|
...e,
|
|
39
42
|
as: "tbody"
|
|
40
43
|
});
|
|
41
44
|
}
|
|
42
|
-
function
|
|
43
|
-
return /* @__PURE__ */
|
|
45
|
+
function v(e) {
|
|
46
|
+
return /* @__PURE__ */ p(t, {
|
|
44
47
|
...e,
|
|
45
48
|
as: "tfoot"
|
|
46
49
|
});
|
|
47
50
|
}
|
|
48
|
-
function
|
|
49
|
-
return /* @__PURE__ */
|
|
50
|
-
...
|
|
51
|
-
"aria-busy":
|
|
51
|
+
function y({ tone: n, "aria-busy": r, backgroundColor: a = n && i[n].backgroundColor, color: o = n ? i[n].color : r === !0 || r === "true" ? "fgMuted" : void 0, className: s, ...c }) {
|
|
52
|
+
return /* @__PURE__ */ p(t, {
|
|
53
|
+
...c,
|
|
54
|
+
"aria-busy": r,
|
|
52
55
|
as: "tr",
|
|
53
56
|
backgroundColor: a,
|
|
54
|
-
className: e(
|
|
57
|
+
className: e(u, s),
|
|
55
58
|
color: o
|
|
56
59
|
});
|
|
57
60
|
}
|
|
58
|
-
function
|
|
59
|
-
return /* @__PURE__ */
|
|
61
|
+
function b(e) {
|
|
62
|
+
return /* @__PURE__ */ p(t, {
|
|
60
63
|
...e,
|
|
61
64
|
as: "colgroup"
|
|
62
65
|
});
|
|
63
66
|
}
|
|
64
|
-
function
|
|
65
|
-
return /* @__PURE__ */
|
|
67
|
+
function x(e) {
|
|
68
|
+
return /* @__PURE__ */ p(t, {
|
|
66
69
|
...e,
|
|
67
70
|
as: "col"
|
|
68
71
|
});
|
|
69
72
|
}
|
|
70
|
-
function
|
|
71
|
-
return /* @__PURE__ */
|
|
72
|
-
...
|
|
73
|
+
function S({ numeric: t = !1, size: n = "sm", display: i = null, paddingBlock: a = "8", paddingInline: o = "12", textAlign: s = t ? "end" : void 0, className: c, ...u }) {
|
|
74
|
+
return /* @__PURE__ */ p(r, {
|
|
75
|
+
...u,
|
|
73
76
|
as: "td",
|
|
74
|
-
className: e(
|
|
77
|
+
className: e(l, c),
|
|
75
78
|
display: i,
|
|
76
79
|
paddingBlock: a,
|
|
77
|
-
paddingInline:
|
|
78
|
-
size:
|
|
80
|
+
paddingInline: o,
|
|
81
|
+
size: n,
|
|
79
82
|
tabularNums: t,
|
|
80
|
-
textAlign:
|
|
83
|
+
textAlign: s
|
|
81
84
|
});
|
|
82
85
|
}
|
|
83
|
-
function
|
|
84
|
-
|
|
85
|
-
|
|
86
|
+
function C({ scope: t = "col", numeric: i = !1, hideLabel: c = !1, sort: u, onSort: d, size: h = t === "row" || t === "rowgroup" ? "sm" : "xs", weight: g = "semibold", color: _ = t === "row" || t === "rowgroup" ? void 0 : u === "ascending" || u === "descending" ? "fg" : "fgMuted", display: v = null, paddingBlock: y = "8", paddingInline: b = "12", textAlign: x = i ? "end" : "start", className: S, children: C, ...w }) {
|
|
87
|
+
let T = u === "ascending" || u === "descending";
|
|
88
|
+
return /* @__PURE__ */ p(r, {
|
|
89
|
+
...w,
|
|
90
|
+
"aria-sort": u === void 0 ? w["aria-sort"] : T ? u : void 0,
|
|
86
91
|
as: "th",
|
|
87
|
-
className: e(
|
|
88
|
-
color:
|
|
89
|
-
display:
|
|
90
|
-
paddingBlock:
|
|
91
|
-
paddingInline:
|
|
92
|
+
className: e(l, S),
|
|
93
|
+
color: _,
|
|
94
|
+
display: v,
|
|
95
|
+
paddingBlock: y,
|
|
96
|
+
paddingInline: b,
|
|
92
97
|
scope: t,
|
|
93
|
-
size:
|
|
94
|
-
tabularNums:
|
|
95
|
-
textAlign:
|
|
96
|
-
weight:
|
|
97
|
-
children:
|
|
98
|
+
size: h,
|
|
99
|
+
tabularNums: i,
|
|
100
|
+
textAlign: x,
|
|
101
|
+
weight: g,
|
|
102
|
+
children: u === void 0 ? c ? /* @__PURE__ */ p(s, { children: C }) : C : /* @__PURE__ */ m(n, {
|
|
103
|
+
gap: "4",
|
|
104
|
+
onClick: d,
|
|
105
|
+
children: [C, u === "descending" ? /* @__PURE__ */ p(a, { size: h }) : /* @__PURE__ */ p(o, {
|
|
106
|
+
className: T ? void 0 : f,
|
|
107
|
+
size: h
|
|
108
|
+
})]
|
|
109
|
+
})
|
|
98
110
|
});
|
|
99
111
|
}
|
|
100
|
-
var
|
|
101
|
-
Head:
|
|
102
|
-
Body:
|
|
103
|
-
Foot:
|
|
104
|
-
Row:
|
|
105
|
-
HeaderCell:
|
|
106
|
-
Cell:
|
|
107
|
-
ColumnGroup:
|
|
108
|
-
Column:
|
|
112
|
+
var w = Object.assign(h, {
|
|
113
|
+
Head: g,
|
|
114
|
+
Body: _,
|
|
115
|
+
Foot: v,
|
|
116
|
+
Row: y,
|
|
117
|
+
HeaderCell: C,
|
|
118
|
+
Cell: S,
|
|
119
|
+
ColumnGroup: b,
|
|
120
|
+
Column: x
|
|
109
121
|
});
|
|
110
|
-
export {
|
|
122
|
+
export { w as Table };
|
package/dist/docs/Icon.md
CHANGED
|
@@ -72,8 +72,10 @@ Generated from `src/icons/svg/` and exported from `@jonmilner/ui/icons`; each ta
|
|
|
72
72
|
|
|
73
73
|
<!-- icons:start -->
|
|
74
74
|
|
|
75
|
+
- `ArrowDownIcon` (`arrow-down.svg`)
|
|
75
76
|
- `ArrowLeftIcon` (`arrow-left.svg`)
|
|
76
77
|
- `ArrowRightIcon` (`arrow-right.svg`)
|
|
78
|
+
- `ArrowUpIcon` (`arrow-up.svg`)
|
|
77
79
|
- `CheckIcon` (`check.svg`)
|
|
78
80
|
- `ChevronDownIcon` (`chevron-down.svg`)
|
|
79
81
|
- `ChevronRightIcon` (`chevron-right.svg`)
|
package/dist/docs/Table.md
CHANGED
|
@@ -8,6 +8,7 @@ Records in rows that share named columns, so a reader can scan and compare them:
|
|
|
8
8
|
|
|
9
9
|
- A list of records with the same fields, where a reader compares one row against another: amounts, dates, statuses.
|
|
10
10
|
- Figures that should line up down a column: set `numeric` on the column's cells.
|
|
11
|
+
- Columns a reader sorts: set `sort` and `onSort` on their headers.
|
|
11
12
|
|
|
12
13
|
## When not to use
|
|
13
14
|
|
|
@@ -18,6 +19,7 @@ Records in rows that share named columns, so a reader can scan and compare them:
|
|
|
18
19
|
- A phone layout of one card per row: that is the app's layout; Table stays a table.
|
|
19
20
|
- After a row is removed, focus is the app's to move (to the next row's control, or a heading); Table does not restore it.
|
|
20
21
|
- A sticky header, edge shadows, virtualisation or column resizing: not supported.
|
|
22
|
+
- Sorting the rows themselves, or by several columns at once: the app sorts its data; a header only shows the order and reports the press.
|
|
21
23
|
|
|
22
24
|
## Rules
|
|
23
25
|
|
|
@@ -30,7 +32,9 @@ Records in rows that share named columns, so a reader can scan and compare them:
|
|
|
30
32
|
- Body rows take a light hover tint only where hover is real (`(hover: hover)`); it never means anything, it only helps the eye follow a row. On a `bgMuted` surface, colored text in a cell (`color="danger"`) falls under 4.5:1 under the tint: put a status there in a `Badge`.
|
|
31
33
|
- `layout`: `auto` (default) sizes columns from their content; `fixed` sizes them from the first row and the columns' widths, so it is faster on a long table and its columns stay put. Set a width with `inlineSize` on `Table.Column` inside `Table.ColumnGroup`: a size step, a container width, `auto`, `full` or `fit`. A width no token gives goes in `className`, the documented exception.
|
|
32
34
|
- The table is `inlineSize="full"` by default. Cells have `8` block and `12` inline padding as default style props, and a `border` rule below each. Every part takes `className`, `style`, `ref` and the style props; the consumer's win.
|
|
33
|
-
-
|
|
35
|
+
- `sort` (`"ascending"`, `"descending"` or `"none"`) and `onSort` on a `HeaderCell` make its column sortable: its label goes in a button, with an up or down arrow after it for the current order (an unsorted column keeps the arrow's room, unseen), and the sorted column's label turns `fg`. Pressing it calls `onSort`; the app re-sorts its rows and passes the new `sort`, and picks the press order (a new column ascending, the same one flipped). Pass `"none"` on each sortable column that is not the sorted one. `sort` and `onSort` go together, and `hideLabel` cannot join them: the label is the button's name.
|
|
36
|
+
- `sort` sets `aria-sort` on the header, only while the column is ascending or descending. A header sorted some other way (a link, the server) passes `aria-sort` itself and leaves `sort` unset.
|
|
37
|
+
- No part has hooks, so a server component can render the whole table. `onSort` is a function, so a sortable table renders from a client component.
|
|
34
38
|
|
|
35
39
|
## Do
|
|
36
40
|
|
|
@@ -80,6 +84,34 @@ Records in rows that share named columns, so a reader can scan and compare them:
|
|
|
80
84
|
</Table>
|
|
81
85
|
```
|
|
82
86
|
|
|
87
|
+
```tsx
|
|
88
|
+
// The app owns the order; each sortable header shows it and asks to change it.
|
|
89
|
+
const [sort, setSort] = useState<{ key: "payee" | "amount"; dir: "ascending" | "descending" }>({
|
|
90
|
+
key: "payee",
|
|
91
|
+
dir: "ascending",
|
|
92
|
+
});
|
|
93
|
+
const header = (key: "payee" | "amount") => ({
|
|
94
|
+
sort: sort.key === key ? sort.dir : ("none" as const),
|
|
95
|
+
onSort: () =>
|
|
96
|
+
setSort((current) => ({
|
|
97
|
+
key,
|
|
98
|
+
dir: current.key === key && current.dir === "ascending" ? "descending" : "ascending",
|
|
99
|
+
})),
|
|
100
|
+
});
|
|
101
|
+
|
|
102
|
+
<Table caption="Recent transactions">
|
|
103
|
+
<Table.Head>
|
|
104
|
+
<Table.Row>
|
|
105
|
+
<Table.HeaderCell {...header("payee")}>Payee</Table.HeaderCell>
|
|
106
|
+
<Table.HeaderCell numeric {...header("amount")}>
|
|
107
|
+
Amount
|
|
108
|
+
</Table.HeaderCell>
|
|
109
|
+
</Table.Row>
|
|
110
|
+
</Table.Head>
|
|
111
|
+
<Table.Body>{sortedRows}</Table.Body>
|
|
112
|
+
</Table>;
|
|
113
|
+
```
|
|
114
|
+
|
|
83
115
|
## Don't
|
|
84
116
|
|
|
85
117
|
```tsx
|
|
@@ -95,6 +127,13 @@ Records in rows that share named columns, so a reader can scan and compare them:
|
|
|
95
127
|
</Table.Row>
|
|
96
128
|
```
|
|
97
129
|
|
|
130
|
+
```tsx
|
|
131
|
+
// A click on the th: no keyboard reaches it, and nothing says it sorts. Use sort and onSort.
|
|
132
|
+
<Table.HeaderCell aria-sort="ascending" onClick={toggle}>
|
|
133
|
+
Amount
|
|
134
|
+
</Table.HeaderCell>
|
|
135
|
+
```
|
|
136
|
+
|
|
98
137
|
```tsx
|
|
99
138
|
// An empty body: say there is nothing, instead.
|
|
100
139
|
<Table caption="Invoices">
|
|
@@ -106,6 +145,7 @@ Records in rows that share named columns, so a reader can scan and compare them:
|
|
|
106
145
|
|
|
107
146
|
- Native table semantics: rows, column and row headers are announced, and screen readers' table navigation works. Column headers are `scope="col"`; set `scope="row"` on a row's first cell when it names the row.
|
|
108
147
|
- A `caption`, `aria-label` or `aria-labelledby` names the table (WCAG 1.3.1).
|
|
148
|
+
- A sortable header is a native `button` named by its label, in the tab order, pressed with Enter, Space or a click; its arrow is hidden from assistive tech, and the `th`'s `aria-sort` announces the order (WAI-ARIA sortable table pattern).
|
|
109
149
|
- Controls in cells are in the tab order, in reading order. Give each a name that says its row ("Select Ada Lovelace", "Actions for City Water").
|
|
110
150
|
- A pending row's `aria-busy` tells assistive tech it is changing; a toned row's meaning is in its text (WCAG 1.4.1).
|
|
111
151
|
- The text on each tone fill, and on the hover tint over each surface and fill (colored text roles over `bg` and `bgRaised` only), is checked for 4.5:1 in `contrast/mixes.ts`.
|
|
@@ -177,7 +217,9 @@ Also accepts the style props (see `manifest.json` `styleProps`).
|
|
|
177
217
|
| `hideLabel` | `boolean` | no | |
|
|
178
218
|
| `leading` | `"lg" \| "med" \| "sm"` | no | |
|
|
179
219
|
| `numeric` | `boolean` | no | |
|
|
220
|
+
| `onSort` | `((() => void) & (() => void))` | no | |
|
|
180
221
|
| `size` | `"2xl" \| "3xl" \| "4xl" \| "lg" \| "med" \| "sm" \| "xl" \| "xs"` | no | |
|
|
222
|
+
| `sort` | `"ascending" \| "descending" \| "none"` | no | |
|
|
181
223
|
| `weight` | `"bold" \| "medium" \| "regular" \| "semibold"` | no | |
|
|
182
224
|
| `wrap` | `"nowrap" \| "pre" \| "pre-wrap"` | no | |
|
|
183
225
|
|
package/dist/docs/manifest.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "./manifest.schema.json",
|
|
3
3
|
"package": "@jonmilner/ui",
|
|
4
|
-
"version": "0.11.
|
|
4
|
+
"version": "0.11.6",
|
|
5
5
|
"components": [
|
|
6
6
|
{
|
|
7
7
|
"name": "AlertDialog",
|
|
@@ -2096,6 +2096,11 @@
|
|
|
2096
2096
|
"type": "boolean",
|
|
2097
2097
|
"required": false
|
|
2098
2098
|
},
|
|
2099
|
+
{
|
|
2100
|
+
"name": "onSort",
|
|
2101
|
+
"type": "((() => void) & (() => void))",
|
|
2102
|
+
"required": false
|
|
2103
|
+
},
|
|
2099
2104
|
{
|
|
2100
2105
|
"name": "size",
|
|
2101
2106
|
"type": "\"2xl\" | \"3xl\" | \"4xl\" | \"lg\" | \"med\" | \"sm\" | \"xl\" | \"xs\"",
|
|
@@ -2111,6 +2116,16 @@
|
|
|
2111
2116
|
"xs"
|
|
2112
2117
|
]
|
|
2113
2118
|
},
|
|
2119
|
+
{
|
|
2120
|
+
"name": "sort",
|
|
2121
|
+
"type": "\"ascending\" | \"descending\" | \"none\"",
|
|
2122
|
+
"required": false,
|
|
2123
|
+
"values": [
|
|
2124
|
+
"ascending",
|
|
2125
|
+
"descending",
|
|
2126
|
+
"none"
|
|
2127
|
+
]
|
|
2128
|
+
},
|
|
2114
2129
|
{
|
|
2115
2130
|
"name": "weight",
|
|
2116
2131
|
"type": "\"bold\" | \"medium\" | \"regular\" | \"semibold\"",
|
|
@@ -3425,8 +3440,10 @@
|
|
|
3425
3440
|
}
|
|
3426
3441
|
],
|
|
3427
3442
|
"icons": [
|
|
3443
|
+
"ArrowDownIcon",
|
|
3428
3444
|
"ArrowLeftIcon",
|
|
3429
3445
|
"ArrowRightIcon",
|
|
3446
|
+
"ArrowUpIcon",
|
|
3430
3447
|
"CheckIcon",
|
|
3431
3448
|
"ChevronDownIcon",
|
|
3432
3449
|
"ChevronRightIcon",
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Icon as e } from "../Icon/index.mjs";
|
|
2
|
+
import { jsx as t } from "react/jsx-runtime";
|
|
3
|
+
// src/icons/ArrowDownIcon.tsx
|
|
4
|
+
function n(n) {
|
|
5
|
+
return /* @__PURE__ */ t(e, {
|
|
6
|
+
...n,
|
|
7
|
+
children: /* @__PURE__ */ t("path", { d: "M12 5v14M19 12l-7 7-7-7" })
|
|
8
|
+
});
|
|
9
|
+
}
|
|
10
|
+
export { n as ArrowDownIcon };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Icon as e } from "../Icon/index.mjs";
|
|
2
|
+
import { jsx as t } from "react/jsx-runtime";
|
|
3
|
+
// src/icons/ArrowUpIcon.tsx
|
|
4
|
+
function n(n) {
|
|
5
|
+
return /* @__PURE__ */ t(e, {
|
|
6
|
+
...n,
|
|
7
|
+
children: /* @__PURE__ */ t("path", { d: "m5 12 7-7 7 7M12 19V5" })
|
|
8
|
+
});
|
|
9
|
+
}
|
|
10
|
+
export { n as ArrowUpIcon };
|
package/dist/icons/index.d.mts
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { CircleAlertIcon } from "./CircleAlertIcon.mjs";
|
|
2
2
|
import { CircleCheckIcon } from "./CircleCheckIcon.mjs";
|
|
3
3
|
import { InfoIcon } from "./InfoIcon.mjs";
|
|
4
|
+
import { ArrowDownIcon } from "./ArrowDownIcon.mjs";
|
|
4
5
|
import { ArrowLeftIcon } from "./ArrowLeftIcon.mjs";
|
|
5
6
|
import { ArrowRightIcon } from "./ArrowRightIcon.mjs";
|
|
7
|
+
import { ArrowUpIcon } from "./ArrowUpIcon.mjs";
|
|
6
8
|
import { CheckIcon } from "./CheckIcon.mjs";
|
|
7
9
|
import { ChevronDownIcon } from "./ChevronDownIcon.mjs";
|
|
8
10
|
import { ChevronRightIcon } from "./ChevronRightIcon.mjs";
|
|
@@ -25,6 +27,6 @@ import { SearchIcon } from "./SearchIcon.mjs";
|
|
|
25
27
|
import { SettingsIcon } from "./SettingsIcon.mjs";
|
|
26
28
|
import { Trash2Icon } from "./Trash2Icon.mjs";
|
|
27
29
|
import { XIcon } from "./XIcon.mjs";
|
|
28
|
-
export declare const iconNames: readonly ["ArrowLeftIcon", "ArrowRightIcon", "CheckIcon", "ChevronDownIcon", "ChevronRightIcon", "CircleAlertIcon", "CircleCheckIcon", "CircleDotIcon", "CircleSlashIcon", "EllipsisIcon", "GitMergeIcon", "GitPullRequestClosedIcon", "GitPullRequestDraftIcon", "GitPullRequestIcon", "InboxIcon", "InfoIcon", "LoaderCircleIcon", "LockOpenIcon", "PencilIcon", "PlayIcon", "PlusIcon", "RefreshCwIcon", "ReplyIcon", "SearchIcon", "SettingsIcon", "Trash2Icon", "XIcon"];
|
|
30
|
+
export declare const iconNames: readonly ["ArrowDownIcon", "ArrowLeftIcon", "ArrowRightIcon", "ArrowUpIcon", "CheckIcon", "ChevronDownIcon", "ChevronRightIcon", "CircleAlertIcon", "CircleCheckIcon", "CircleDotIcon", "CircleSlashIcon", "EllipsisIcon", "GitMergeIcon", "GitPullRequestClosedIcon", "GitPullRequestDraftIcon", "GitPullRequestIcon", "InboxIcon", "InfoIcon", "LoaderCircleIcon", "LockOpenIcon", "PencilIcon", "PlayIcon", "PlusIcon", "RefreshCwIcon", "ReplyIcon", "SearchIcon", "SettingsIcon", "Trash2Icon", "XIcon"];
|
|
29
31
|
export type IconName = (typeof iconNames)[number];
|
|
30
|
-
export { ArrowLeftIcon, ArrowRightIcon, CheckIcon, ChevronDownIcon, ChevronRightIcon, CircleAlertIcon, CircleCheckIcon, CircleDotIcon, CircleSlashIcon, EllipsisIcon, GitMergeIcon, GitPullRequestClosedIcon, GitPullRequestDraftIcon, GitPullRequestIcon, InboxIcon, InfoIcon, LoaderCircleIcon, LockOpenIcon, PencilIcon, PlayIcon, PlusIcon, RefreshCwIcon, ReplyIcon, SearchIcon, SettingsIcon, Trash2Icon, XIcon };
|
|
32
|
+
export { ArrowDownIcon, ArrowLeftIcon, ArrowRightIcon, ArrowUpIcon, CheckIcon, ChevronDownIcon, ChevronRightIcon, CircleAlertIcon, CircleCheckIcon, CircleDotIcon, CircleSlashIcon, EllipsisIcon, GitMergeIcon, GitPullRequestClosedIcon, GitPullRequestDraftIcon, GitPullRequestIcon, InboxIcon, InfoIcon, LoaderCircleIcon, LockOpenIcon, PencilIcon, PlayIcon, PlusIcon, RefreshCwIcon, ReplyIcon, SearchIcon, SettingsIcon, Trash2Icon, XIcon };
|
package/dist/icons/index.mjs
CHANGED
|
@@ -3,28 +3,30 @@ import { CircleAlertIcon as t } from "./CircleAlertIcon.mjs";
|
|
|
3
3
|
import { ChevronDownIcon as n } from "./ChevronDownIcon.mjs";
|
|
4
4
|
import { SearchIcon as r } from "./SearchIcon.mjs";
|
|
5
5
|
import { XIcon as i } from "./XIcon.mjs";
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
27
|
-
import {
|
|
6
|
+
import { ArrowDownIcon as a } from "./ArrowDownIcon.mjs";
|
|
7
|
+
import { ArrowUpIcon as o } from "./ArrowUpIcon.mjs";
|
|
8
|
+
import { CircleCheckIcon as s } from "./CircleCheckIcon.mjs";
|
|
9
|
+
import { InfoIcon as c } from "./InfoIcon.mjs";
|
|
10
|
+
import { ArrowLeftIcon as l } from "./ArrowLeftIcon.mjs";
|
|
11
|
+
import { ArrowRightIcon as u } from "./ArrowRightIcon.mjs";
|
|
12
|
+
import { ChevronRightIcon as d } from "./ChevronRightIcon.mjs";
|
|
13
|
+
import { CircleDotIcon as f } from "./CircleDotIcon.mjs";
|
|
14
|
+
import { CircleSlashIcon as p } from "./CircleSlashIcon.mjs";
|
|
15
|
+
import { EllipsisIcon as m } from "./EllipsisIcon.mjs";
|
|
16
|
+
import { GitMergeIcon as h } from "./GitMergeIcon.mjs";
|
|
17
|
+
import { GitPullRequestClosedIcon as g } from "./GitPullRequestClosedIcon.mjs";
|
|
18
|
+
import { GitPullRequestDraftIcon as _ } from "./GitPullRequestDraftIcon.mjs";
|
|
19
|
+
import { GitPullRequestIcon as v } from "./GitPullRequestIcon.mjs";
|
|
20
|
+
import { InboxIcon as y } from "./InboxIcon.mjs";
|
|
21
|
+
import { LoaderCircleIcon as b } from "./LoaderCircleIcon.mjs";
|
|
22
|
+
import { LockOpenIcon as x } from "./LockOpenIcon.mjs";
|
|
23
|
+
import { PencilIcon as S } from "./PencilIcon.mjs";
|
|
24
|
+
import { PlayIcon as C } from "./PlayIcon.mjs";
|
|
25
|
+
import { PlusIcon as w } from "./PlusIcon.mjs";
|
|
26
|
+
import { RefreshCwIcon as T } from "./RefreshCwIcon.mjs";
|
|
27
|
+
import { ReplyIcon as E } from "./ReplyIcon.mjs";
|
|
28
|
+
import { SettingsIcon as D } from "./SettingsIcon.mjs";
|
|
29
|
+
import { Trash2Icon as O } from "./Trash2Icon.mjs";
|
|
28
30
|
// src/icons/index.ts
|
|
29
|
-
var
|
|
30
|
-
export {
|
|
31
|
+
var k = /* @__PURE__ */ "ArrowDownIcon.ArrowLeftIcon.ArrowRightIcon.ArrowUpIcon.CheckIcon.ChevronDownIcon.ChevronRightIcon.CircleAlertIcon.CircleCheckIcon.CircleDotIcon.CircleSlashIcon.EllipsisIcon.GitMergeIcon.GitPullRequestClosedIcon.GitPullRequestDraftIcon.GitPullRequestIcon.InboxIcon.InfoIcon.LoaderCircleIcon.LockOpenIcon.PencilIcon.PlayIcon.PlusIcon.RefreshCwIcon.ReplyIcon.SearchIcon.SettingsIcon.Trash2Icon.XIcon".split(".");
|
|
32
|
+
export { a as ArrowDownIcon, l as ArrowLeftIcon, u as ArrowRightIcon, o as ArrowUpIcon, e as CheckIcon, n as ChevronDownIcon, d as ChevronRightIcon, t as CircleAlertIcon, s as CircleCheckIcon, f as CircleDotIcon, p as CircleSlashIcon, m as EllipsisIcon, h as GitMergeIcon, g as GitPullRequestClosedIcon, _ as GitPullRequestDraftIcon, v as GitPullRequestIcon, y as InboxIcon, c as InfoIcon, b as LoaderCircleIcon, x as LockOpenIcon, S as PencilIcon, C as PlayIcon, w as PlusIcon, T as RefreshCwIcon, E as ReplyIcon, r as SearchIcon, D as SettingsIcon, O as Trash2Icon, i as XIcon, k as iconNames };
|
package/dist/index.d.mts
CHANGED
|
@@ -24,7 +24,7 @@ import { Menu, MenuGroupProps, MenuItemProps, MenuLinkItemProps, MenuPopupProps,
|
|
|
24
24
|
import { MultiSelect, MultiSelectOption, MultiSelectProps } from "./MultiSelect/index.mjs";
|
|
25
25
|
import { Stack, StackProps } from "./Stack/index.mjs";
|
|
26
26
|
import { Switch, SwitchProps } from "./Switch/index.mjs";
|
|
27
|
-
import { Table, TableBodyProps, TableCellProps, TableColumnGroupProps, TableColumnProps, TableFootProps, TableHeadProps, TableHeaderCellProps, TableProps, TableRowProps } from "./Table/index.mjs";
|
|
27
|
+
import { Table, TableBodyProps, TableCellProps, TableColumnGroupProps, TableColumnProps, TableFootProps, TableHeadProps, TableHeaderCellProps, TableProps, TableRowProps, TableSortDirection } from "./Table/index.mjs";
|
|
28
28
|
import { Tabs, TabsListProps, TabsPanelProps, TabsProps, TabsTabProps } from "./Tabs/index.mjs";
|
|
29
29
|
import { Tag, TagProps } from "./Tag/index.mjs";
|
|
30
30
|
import { TextField, TextFieldInputProps, TextFieldProps } from "./TextField/index.mjs";
|
|
@@ -34,4 +34,4 @@ import { Toast } from "./Toast/index.mjs";
|
|
|
34
34
|
import { VisuallyHidden, VisuallyHiddenProps } from "./VisuallyHidden/index.mjs";
|
|
35
35
|
import { Theme, defineTheme } from "./theme/define-theme.mjs";
|
|
36
36
|
import { ThemeProvider, ThemeProviderProps } from "./theme/ThemeProvider.mjs";
|
|
37
|
-
export { AlertDialog, type AlertDialogProps, type AlertDialogTriggerProps, Avatar, type AvatarProps, Badge, type BadgeProps, Box, type BoxProps, Button, type ButtonProps, Checkbox, type CheckboxProps, Chip, ChipGroup, type ChipGroupProps, type ChipProps, Clickable, type ClickableProps, ColorField, type ColorFieldInputProps, type ColorFieldProps, Dialog, type DialogActionsProps, type DialogBodyProps, type DialogCloseProps, type DialogPopupProps, type DialogProps, type DialogTriggerProps, Field, type FieldDescriptionProps, type FieldErrorProps, type FieldLabelProps, type FieldProps, Heading, type HeadingLevel, type HeadingProps, type HeadingSize, Icon, IconButton, type IconButtonProps, type IconProps, Inline, type InlineProps, Menu, type MenuGroupProps, type MenuItemProps, type MenuLinkItemProps, type MenuPopupProps, type MenuProps, type MenuSeparatorProps, type MenuTriggerProps, MultiSelect, type MultiSelectOption, type MultiSelectProps, SearchField, type SearchFieldInputProps, type SearchFieldProps, Stack, type StackProps, type StyleProps, Switch, type SwitchProps, Table, type TableBodyProps, type TableCellProps, type TableColumnGroupProps, type TableColumnProps, type TableFootProps, type TableHeadProps, type TableHeaderCellProps, type TableProps, type TableRowProps, Tabs, type TabsListProps, type TabsPanelProps, type TabsProps, type TabsTabProps, Tag, type TagProps, Text, TextField, type TextFieldInputProps, type TextFieldProps, type TextProps, Textarea, type TextareaInputProps, type TextareaProps, type Theme, ThemeProvider, type ThemeProviderProps, Toast, type ToastOptions, type ToastProviderProps, type ToastVariant, VisuallyHidden, type VisuallyHiddenProps, defineTheme, useToast };
|
|
37
|
+
export { AlertDialog, type AlertDialogProps, type AlertDialogTriggerProps, Avatar, type AvatarProps, Badge, type BadgeProps, Box, type BoxProps, Button, type ButtonProps, Checkbox, type CheckboxProps, Chip, ChipGroup, type ChipGroupProps, type ChipProps, Clickable, type ClickableProps, ColorField, type ColorFieldInputProps, type ColorFieldProps, Dialog, type DialogActionsProps, type DialogBodyProps, type DialogCloseProps, type DialogPopupProps, type DialogProps, type DialogTriggerProps, Field, type FieldDescriptionProps, type FieldErrorProps, type FieldLabelProps, type FieldProps, Heading, type HeadingLevel, type HeadingProps, type HeadingSize, Icon, IconButton, type IconButtonProps, type IconProps, Inline, type InlineProps, Menu, type MenuGroupProps, type MenuItemProps, type MenuLinkItemProps, type MenuPopupProps, type MenuProps, type MenuSeparatorProps, type MenuTriggerProps, MultiSelect, type MultiSelectOption, type MultiSelectProps, SearchField, type SearchFieldInputProps, type SearchFieldProps, Stack, type StackProps, type StyleProps, Switch, type SwitchProps, Table, type TableBodyProps, type TableCellProps, type TableColumnGroupProps, type TableColumnProps, type TableFootProps, type TableHeadProps, type TableHeaderCellProps, type TableProps, type TableRowProps, type TableSortDirection, Tabs, type TabsListProps, type TabsPanelProps, type TabsProps, type TabsTabProps, Tag, type TagProps, Text, TextField, type TextFieldInputProps, type TextFieldProps, type TextProps, Textarea, type TextareaInputProps, type TextareaProps, type Theme, ThemeProvider, type ThemeProviderProps, Toast, type ToastOptions, type ToastProviderProps, type ToastVariant, VisuallyHidden, type VisuallyHiddenProps, defineTheme, useToast };
|