jaci-ui 0.4.0 → 0.6.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.
- package/CHANGELOG.md +14 -0
- package/README.md +68 -0
- package/dist/components/command/command.cjs +55 -34
- package/dist/components/command/command.cjs.map +1 -1
- package/dist/components/command/command.d.cts +1 -0
- package/dist/components/command/command.d.ts +1 -0
- package/dist/components/command/command.js +55 -34
- package/dist/components/command/command.js.map +1 -1
- package/dist/components/data-toolbar/data-toolbar.cjs +141 -0
- package/dist/components/data-toolbar/data-toolbar.cjs.map +1 -0
- package/dist/components/data-toolbar/data-toolbar.d.cts +50 -0
- package/dist/components/data-toolbar/data-toolbar.d.ts +50 -0
- package/dist/components/data-toolbar/data-toolbar.js +132 -0
- package/dist/components/data-toolbar/data-toolbar.js.map +1 -0
- package/dist/components/data-toolbar/index.d.cts +2 -0
- package/dist/components/data-toolbar/index.d.ts +2 -0
- package/dist/components/data-view/data-view.cjs +33 -1
- package/dist/components/data-view/data-view.cjs.map +1 -1
- package/dist/components/data-view/data-view.d.cts +12 -1
- package/dist/components/data-view/data-view.d.ts +12 -1
- package/dist/components/data-view/data-view.js +31 -2
- package/dist/components/data-view/data-view.js.map +1 -1
- package/dist/components/data-view/index.d.cts +2 -2
- package/dist/components/data-view/index.d.ts +2 -2
- package/dist/components/list/list.cjs +3 -1
- package/dist/components/list/list.cjs.map +1 -1
- package/dist/components/list/list.d.cts +3 -1
- package/dist/components/list/list.d.ts +3 -1
- package/dist/components/list/list.js +3 -1
- package/dist/components/list/list.js.map +1 -1
- package/dist/components/navigation-menu/navigation-menu.cjs +3 -3
- package/dist/components/navigation-menu/navigation-menu.cjs.map +1 -1
- package/dist/components/navigation-menu/navigation-menu.js +3 -3
- package/dist/components/navigation-menu/navigation-menu.js.map +1 -1
- package/dist/components/pagination/index.d.cts +2 -2
- package/dist/components/pagination/index.d.ts +2 -2
- package/dist/components/pagination/pagination.cjs +122 -21
- package/dist/components/pagination/pagination.cjs.map +1 -1
- package/dist/components/pagination/pagination.d.cts +25 -13
- package/dist/components/pagination/pagination.d.ts +25 -13
- package/dist/components/pagination/pagination.js +122 -23
- package/dist/components/pagination/pagination.js.map +1 -1
- package/dist/components/sidebar/sidebar.cjs +59 -11
- package/dist/components/sidebar/sidebar.cjs.map +1 -1
- package/dist/components/sidebar/sidebar.d.cts +13 -0
- package/dist/components/sidebar/sidebar.d.ts +13 -0
- package/dist/components/sidebar/sidebar.js +59 -13
- package/dist/components/sidebar/sidebar.js.map +1 -1
- package/dist/components/stepper/index.d.cts +2 -0
- package/dist/components/stepper/index.d.ts +2 -0
- package/dist/components/stepper/stepper.cjs +341 -0
- package/dist/components/stepper/stepper.cjs.map +1 -0
- package/dist/components/stepper/stepper.d.cts +52 -0
- package/dist/components/stepper/stepper.d.ts +52 -0
- package/dist/components/stepper/stepper.js +330 -0
- package/dist/components/stepper/stepper.js.map +1 -0
- package/dist/components/table/index.d.cts +2 -2
- package/dist/components/table/index.d.ts +2 -2
- package/dist/components/table/table.cjs +265 -46
- package/dist/components/table/table.cjs.map +1 -1
- package/dist/components/table/table.d.cts +41 -8
- package/dist/components/table/table.d.ts +41 -8
- package/dist/components/table/table.js +264 -48
- package/dist/components/table/table.js.map +1 -1
- package/dist/components/toast/toast.cjs +3 -1
- package/dist/components/toast/toast.cjs.map +1 -1
- package/dist/components/toast/toast.js +3 -1
- package/dist/components/toast/toast.js.map +1 -1
- package/dist/components/tree-view/index.d.cts +2 -2
- package/dist/components/tree-view/index.d.ts +2 -2
- package/dist/components/tree-view/tree-view.cjs +60 -3
- package/dist/components/tree-view/tree-view.cjs.map +1 -1
- package/dist/components/tree-view/tree-view.d.cts +12 -1
- package/dist/components/tree-view/tree-view.d.ts +12 -1
- package/dist/components/tree-view/tree-view.js +58 -4
- package/dist/components/tree-view/tree-view.js.map +1 -1
- package/dist/index.cjs +35 -0
- package/dist/index.d.cts +9 -5
- package/dist/index.d.ts +9 -5
- package/dist/index.js +7 -5
- package/dist/styled-system/recipes/data-toolbar.cjs +40 -0
- package/dist/styled-system/recipes/data-toolbar.cjs.map +1 -0
- package/dist/styled-system/recipes/data-toolbar.js +40 -0
- package/dist/styled-system/recipes/data-toolbar.js.map +1 -0
- package/dist/styled-system/recipes/data-view.cjs +3 -0
- package/dist/styled-system/recipes/data-view.cjs.map +1 -1
- package/dist/styled-system/recipes/data-view.js +3 -0
- package/dist/styled-system/recipes/data-view.js.map +1 -1
- package/dist/styled-system/recipes/list.cjs +7 -1
- package/dist/styled-system/recipes/list.cjs.map +1 -1
- package/dist/styled-system/recipes/list.js +7 -1
- package/dist/styled-system/recipes/list.js.map +1 -1
- package/dist/styled-system/recipes/pagination.cjs +9 -1
- package/dist/styled-system/recipes/pagination.cjs.map +1 -1
- package/dist/styled-system/recipes/pagination.js +9 -1
- package/dist/styled-system/recipes/pagination.js.map +1 -1
- package/dist/styled-system/recipes/sidebar.cjs +3 -0
- package/dist/styled-system/recipes/sidebar.cjs.map +1 -1
- package/dist/styled-system/recipes/sidebar.js +3 -0
- package/dist/styled-system/recipes/sidebar.js.map +1 -1
- package/dist/styled-system/recipes/stepper.cjs +53 -0
- package/dist/styled-system/recipes/stepper.cjs.map +1 -0
- package/dist/styled-system/recipes/stepper.js +53 -0
- package/dist/styled-system/recipes/stepper.js.map +1 -0
- package/dist/styled-system/recipes/table.cjs +15 -2
- package/dist/styled-system/recipes/table.cjs.map +1 -1
- package/dist/styled-system/recipes/table.js +15 -2
- package/dist/styled-system/recipes/table.js.map +1 -1
- package/dist/styled-system/recipes/tree-view.cjs +4 -1
- package/dist/styled-system/recipes/tree-view.cjs.map +1 -1
- package/dist/styled-system/recipes/tree-view.js +4 -1
- package/dist/styled-system/recipes/tree-view.js.map +1 -1
- package/dist/styles.css +602 -18
- package/package.json +1 -1
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { cx } from "../../styled-system/css/cx.js";
|
|
3
|
+
import { dataToolbar } from "../../styled-system/recipes/data-toolbar.js";
|
|
4
|
+
import { createContext, forwardRef, useContext, useState } from "react";
|
|
5
|
+
import { jsx } from "react/jsx-runtime";
|
|
6
|
+
//#region src/components/data-toolbar/data-toolbar.tsx
|
|
7
|
+
const SelectionContext = createContext(null);
|
|
8
|
+
const DataToolbarRoot = forwardRef(function DataToolbarRoot({ className, role, ...props }, ref) {
|
|
9
|
+
return /* @__PURE__ */ jsx("div", {
|
|
10
|
+
...props,
|
|
11
|
+
ref,
|
|
12
|
+
className: cx(dataToolbar().root, className),
|
|
13
|
+
"data-jaci-component": "data-toolbar",
|
|
14
|
+
"data-slot": "data-toolbar",
|
|
15
|
+
role: role ?? "toolbar"
|
|
16
|
+
});
|
|
17
|
+
});
|
|
18
|
+
const DataToolbarSearch = forwardRef(function DataToolbarSearch({ className, defaultValue = "", onValueChange, value: controlledValue, ...props }, ref) {
|
|
19
|
+
const [uncontrolledValue, setUncontrolledValue] = useState(defaultValue);
|
|
20
|
+
const value = controlledValue ?? uncontrolledValue;
|
|
21
|
+
return /* @__PURE__ */ jsx("input", {
|
|
22
|
+
...props,
|
|
23
|
+
ref,
|
|
24
|
+
className: cx(dataToolbar().search, className),
|
|
25
|
+
"data-slot": "data-toolbar-search",
|
|
26
|
+
onChange: (event) => {
|
|
27
|
+
if (controlledValue === void 0) setUncontrolledValue(event.currentTarget.value);
|
|
28
|
+
onValueChange?.(event.currentTarget.value);
|
|
29
|
+
props.onChange?.(event);
|
|
30
|
+
},
|
|
31
|
+
type: props.type ?? "search",
|
|
32
|
+
value
|
|
33
|
+
});
|
|
34
|
+
});
|
|
35
|
+
const DataToolbarFilters = forwardRef(function DataToolbarFilters({ className, ...props }, ref) {
|
|
36
|
+
return /* @__PURE__ */ jsx("div", {
|
|
37
|
+
...props,
|
|
38
|
+
ref,
|
|
39
|
+
className: cx(dataToolbar().filters, className),
|
|
40
|
+
"data-slot": "data-toolbar-filters"
|
|
41
|
+
});
|
|
42
|
+
});
|
|
43
|
+
const DataToolbarSort = forwardRef(function DataToolbarSort({ className, defaultValue = "", onValueChange, value: controlledValue, ...props }, ref) {
|
|
44
|
+
const [uncontrolledValue, setUncontrolledValue] = useState(defaultValue);
|
|
45
|
+
const value = controlledValue ?? uncontrolledValue;
|
|
46
|
+
return /* @__PURE__ */ jsx("select", {
|
|
47
|
+
...props,
|
|
48
|
+
ref,
|
|
49
|
+
className: cx(dataToolbar().sort, className),
|
|
50
|
+
"data-slot": "data-toolbar-sort",
|
|
51
|
+
onChange: (event) => {
|
|
52
|
+
if (controlledValue === void 0) setUncontrolledValue(event.currentTarget.value);
|
|
53
|
+
onValueChange?.(event.currentTarget.value);
|
|
54
|
+
props.onChange?.(event);
|
|
55
|
+
},
|
|
56
|
+
value
|
|
57
|
+
});
|
|
58
|
+
});
|
|
59
|
+
const DataToolbarSelection = forwardRef(function DataToolbarSelection({ children, className, count, label = "selected", onClear, ...props }, ref) {
|
|
60
|
+
return /* @__PURE__ */ jsx(SelectionContext.Provider, {
|
|
61
|
+
value: {
|
|
62
|
+
count,
|
|
63
|
+
onClear
|
|
64
|
+
},
|
|
65
|
+
children: /* @__PURE__ */ jsx("div", {
|
|
66
|
+
...props,
|
|
67
|
+
ref,
|
|
68
|
+
"aria-live": "polite",
|
|
69
|
+
className: cx(dataToolbar().selection, className),
|
|
70
|
+
"data-count": count,
|
|
71
|
+
"data-slot": "data-toolbar-selection",
|
|
72
|
+
children: children ?? `${count} ${label}`
|
|
73
|
+
})
|
|
74
|
+
});
|
|
75
|
+
});
|
|
76
|
+
const DataToolbarClearSelection = forwardRef(function DataToolbarClearSelection({ children = "Clear selection", className, onClick, ...props }, ref) {
|
|
77
|
+
const context = useContext(SelectionContext);
|
|
78
|
+
return /* @__PURE__ */ jsx("button", {
|
|
79
|
+
...props,
|
|
80
|
+
ref,
|
|
81
|
+
className: cx(dataToolbar().clearSelection, className),
|
|
82
|
+
"data-slot": "data-toolbar-clear-selection",
|
|
83
|
+
onClick: (event) => {
|
|
84
|
+
context?.onClear?.();
|
|
85
|
+
onClick?.(event);
|
|
86
|
+
},
|
|
87
|
+
type: "button",
|
|
88
|
+
children
|
|
89
|
+
});
|
|
90
|
+
});
|
|
91
|
+
const DataToolbarActions = forwardRef(function DataToolbarActions({ className, ...props }, ref) {
|
|
92
|
+
return /* @__PURE__ */ jsx("div", {
|
|
93
|
+
...props,
|
|
94
|
+
ref,
|
|
95
|
+
className: cx(dataToolbar().actions, className),
|
|
96
|
+
"data-slot": "data-toolbar-actions"
|
|
97
|
+
});
|
|
98
|
+
});
|
|
99
|
+
const DataToolbarClear = forwardRef(function DataToolbarClear({ children = "Clear filters", className, ...props }, ref) {
|
|
100
|
+
return /* @__PURE__ */ jsx("button", {
|
|
101
|
+
...props,
|
|
102
|
+
ref,
|
|
103
|
+
className: cx(dataToolbar().clear, className),
|
|
104
|
+
"data-slot": "data-toolbar-clear",
|
|
105
|
+
type: "button",
|
|
106
|
+
children
|
|
107
|
+
});
|
|
108
|
+
});
|
|
109
|
+
const DataToolbarSeparator = forwardRef(function DataToolbarSeparator({ className, ...props }, ref) {
|
|
110
|
+
return /* @__PURE__ */ jsx("div", {
|
|
111
|
+
...props,
|
|
112
|
+
ref,
|
|
113
|
+
"aria-hidden": "true",
|
|
114
|
+
className: cx(dataToolbar().separator, className),
|
|
115
|
+
"data-slot": "data-toolbar-separator"
|
|
116
|
+
});
|
|
117
|
+
});
|
|
118
|
+
const DataToolbar = {
|
|
119
|
+
Root: DataToolbarRoot,
|
|
120
|
+
Search: DataToolbarSearch,
|
|
121
|
+
Filters: DataToolbarFilters,
|
|
122
|
+
Sort: DataToolbarSort,
|
|
123
|
+
Selection: DataToolbarSelection,
|
|
124
|
+
ClearSelection: DataToolbarClearSelection,
|
|
125
|
+
Actions: DataToolbarActions,
|
|
126
|
+
Clear: DataToolbarClear,
|
|
127
|
+
Separator: DataToolbarSeparator
|
|
128
|
+
};
|
|
129
|
+
//#endregion
|
|
130
|
+
export { DataToolbar, DataToolbarActions, DataToolbarClear, DataToolbarClearSelection, DataToolbarFilters, DataToolbarRoot, DataToolbarSearch, DataToolbarSelection, DataToolbarSeparator, DataToolbarSort };
|
|
131
|
+
|
|
132
|
+
//# sourceMappingURL=data-toolbar.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"data-toolbar.js","names":[],"sources":["../../../src/components/data-toolbar/data-toolbar.tsx"],"sourcesContent":["\"use client\";\n\nimport { createContext, forwardRef, useContext, useState } from \"react\";\nimport type { ComponentPropsWithoutRef, ReactNode } from \"react\";\n\nimport { cx } from \"../../styled-system/css\";\nimport { dataToolbar } from \"../../styled-system/recipes\";\n\ninterface SelectionContextValue {\n count: number;\n onClear: (() => void) | undefined;\n}\n\nconst SelectionContext = createContext<SelectionContextValue | null>(null);\n\nexport type DataToolbarRootProps = ComponentPropsWithoutRef<\"div\">;\nexport const DataToolbarRoot = forwardRef<HTMLDivElement, DataToolbarRootProps>(\n function DataToolbarRoot({ className, role, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataToolbar().root, className)}\n data-jaci-component=\"data-toolbar\"\n data-slot=\"data-toolbar\"\n role={role ?? \"toolbar\"}\n />\n );\n },\n);\n\nexport interface DataToolbarSearchProps\n extends Omit<ComponentPropsWithoutRef<\"input\">, \"defaultValue\" | \"onChange\" | \"value\"> {\n defaultValue?: string;\n onChange?: ComponentPropsWithoutRef<\"input\">[\"onChange\"];\n onValueChange?: (value: string) => void;\n value?: string;\n}\n\nexport const DataToolbarSearch = forwardRef<HTMLInputElement, DataToolbarSearchProps>(\n function DataToolbarSearch(\n { className, defaultValue = \"\", onValueChange, value: controlledValue, ...props },\n ref,\n ) {\n const [uncontrolledValue, setUncontrolledValue] = useState(defaultValue);\n const value = controlledValue ?? uncontrolledValue;\n return (\n <input\n {...props}\n ref={ref}\n className={cx(dataToolbar().search, className)}\n data-slot=\"data-toolbar-search\"\n onChange={(event) => {\n if (controlledValue === undefined) setUncontrolledValue(event.currentTarget.value);\n onValueChange?.(event.currentTarget.value);\n props.onChange?.(event);\n }}\n type={props.type ?? \"search\"}\n value={value}\n />\n );\n },\n);\n\nexport type DataToolbarFiltersProps = ComponentPropsWithoutRef<\"div\">;\nexport const DataToolbarFilters = forwardRef<HTMLDivElement, DataToolbarFiltersProps>(\n function DataToolbarFilters({ className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataToolbar().filters, className)}\n data-slot=\"data-toolbar-filters\"\n />\n );\n },\n);\n\nexport interface DataToolbarSortProps\n extends Omit<ComponentPropsWithoutRef<\"select\">, \"defaultValue\" | \"onChange\" | \"value\"> {\n defaultValue?: string;\n onChange?: ComponentPropsWithoutRef<\"select\">[\"onChange\"];\n onValueChange?: (value: string) => void;\n value?: string;\n}\n\nexport const DataToolbarSort = forwardRef<HTMLSelectElement, DataToolbarSortProps>(\n function DataToolbarSort(\n { className, defaultValue = \"\", onValueChange, value: controlledValue, ...props },\n ref,\n ) {\n const [uncontrolledValue, setUncontrolledValue] = useState(defaultValue);\n const value = controlledValue ?? uncontrolledValue;\n return (\n <select\n {...props}\n ref={ref}\n className={cx(dataToolbar().sort, className)}\n data-slot=\"data-toolbar-sort\"\n onChange={(event) => {\n if (controlledValue === undefined) setUncontrolledValue(event.currentTarget.value);\n onValueChange?.(event.currentTarget.value);\n props.onChange?.(event);\n }}\n value={value}\n />\n );\n },\n);\n\nexport interface DataToolbarSelectionProps extends ComponentPropsWithoutRef<\"div\"> {\n count: number;\n label?: ReactNode;\n onClear?: () => void;\n}\nexport const DataToolbarSelection = forwardRef<HTMLDivElement, DataToolbarSelectionProps>(\n function DataToolbarSelection(\n { children, className, count, label = \"selected\", onClear, ...props },\n ref,\n ) {\n return (\n <SelectionContext.Provider value={{ count, onClear }}>\n <div\n {...props}\n ref={ref}\n aria-live=\"polite\"\n className={cx(dataToolbar().selection, className)}\n data-count={count}\n data-slot=\"data-toolbar-selection\"\n >\n {children ?? `${count} ${label}`}\n </div>\n </SelectionContext.Provider>\n );\n },\n);\n\nexport interface DataToolbarClearSelectionProps extends ComponentPropsWithoutRef<\"button\"> {\n children?: ReactNode;\n}\nexport const DataToolbarClearSelection = forwardRef<\n HTMLButtonElement,\n DataToolbarClearSelectionProps\n>(function DataToolbarClearSelection(\n { children = \"Clear selection\", className, onClick, ...props },\n ref,\n) {\n const context = useContext(SelectionContext);\n return (\n <button\n {...props}\n ref={ref}\n className={cx(dataToolbar().clearSelection, className)}\n data-slot=\"data-toolbar-clear-selection\"\n onClick={(event) => {\n context?.onClear?.();\n onClick?.(event);\n }}\n type=\"button\"\n >\n {children}\n </button>\n );\n});\n\nexport type DataToolbarActionsProps = ComponentPropsWithoutRef<\"div\">;\nexport const DataToolbarActions = forwardRef<HTMLDivElement, DataToolbarActionsProps>(\n function DataToolbarActions({ className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataToolbar().actions, className)}\n data-slot=\"data-toolbar-actions\"\n />\n );\n },\n);\n\nexport type DataToolbarClearProps = ComponentPropsWithoutRef<\"button\">;\nexport const DataToolbarClear = forwardRef<HTMLButtonElement, DataToolbarClearProps>(\n function DataToolbarClear({ children = \"Clear filters\", className, ...props }, ref) {\n return (\n <button\n {...props}\n ref={ref}\n className={cx(dataToolbar().clear, className)}\n data-slot=\"data-toolbar-clear\"\n type=\"button\"\n >\n {children}\n </button>\n );\n },\n);\n\nexport type DataToolbarSeparatorProps = ComponentPropsWithoutRef<\"div\">;\nexport const DataToolbarSeparator = forwardRef<HTMLDivElement, DataToolbarSeparatorProps>(\n function DataToolbarSeparator({ className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n aria-hidden=\"true\"\n className={cx(dataToolbar().separator, className)}\n data-slot=\"data-toolbar-separator\"\n />\n );\n },\n);\n\nexport const DataToolbar = {\n Root: DataToolbarRoot,\n Search: DataToolbarSearch,\n Filters: DataToolbarFilters,\n Sort: DataToolbarSort,\n Selection: DataToolbarSelection,\n ClearSelection: DataToolbarClearSelection,\n Actions: DataToolbarAct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;EAC5C,aAAU;EACV,MAAK;EAEJ;CACK,CAAA;AAEZ,CACF;AAGA,MAAa,uBAAuB,WAClC,SAAS,qBAAqB,EAAE,WAAW,GAAG,SAAS,KAAK;CAC1D,OACE,oBAAC,OAAD;EACE,GAAI;EACC;EACL,eAAY;EACZ,WAAW,GAAG,YAAY,CAAC,CAAC,WAAW,SAAS;EAChD,aAAU;CACX,CAAA;AAEL,CACF;AAEA,MAAa,cAAc;CACzB,MAAM;CACN,QAAQ;CACR,SAAS;CACT,MAAM;CACN,WAAW;CACX,gBAAgB;CAChB,SAAS;CACT,OAAO;CACP,WAAW;AACb"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import { DataToolbar, DataToolbarActions, DataToolbarActionsProps, DataToolbarClear, DataToolbarClearProps, DataToolbarClearSelection, DataToolbarClearSelectionProps, DataToolbarFilters, DataToolbarFiltersProps, DataToolbarRoot, DataToolbarRootProps, DataToolbarSearch, DataToolbarSearchProps, DataToolbarSelection, DataToolbarSelectionProps, DataToolbarSeparator, DataToolbarSeparatorProps, DataToolbarSort, DataToolbarSortProps } from "./data-toolbar.cjs";
|
|
2
|
+
export { DataToolbar, DataToolbarActions, type DataToolbarActionsProps, DataToolbarClear, type DataToolbarClearProps, DataToolbarClearSelection, type DataToolbarClearSelectionProps, DataToolbarFilters, type DataToolbarFiltersProps, DataToolbarRoot, type DataToolbarRootProps, DataToolbarSearch, type DataToolbarSearchProps, DataToolbarSelection, type DataToolbarSelectionProps, DataToolbarSeparator, type DataToolbarSeparatorProps, DataToolbarSort, type DataToolbarSortProps };
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import { DataToolbar, DataToolbarActions, DataToolbarActionsProps, DataToolbarClear, DataToolbarClearProps, DataToolbarClearSelection, DataToolbarClearSelectionProps, DataToolbarFilters, DataToolbarFiltersProps, DataToolbarRoot, DataToolbarRootProps, DataToolbarSearch, DataToolbarSearchProps, DataToolbarSelection, DataToolbarSelectionProps, DataToolbarSeparator, DataToolbarSeparatorProps, DataToolbarSort, DataToolbarSortProps } from "./data-toolbar.js";
|
|
2
|
+
export { DataToolbar, DataToolbarActions, type DataToolbarActionsProps, DataToolbarClear, type DataToolbarClearProps, DataToolbarClearSelection, type DataToolbarClearSelectionProps, DataToolbarFilters, type DataToolbarFiltersProps, DataToolbarRoot, type DataToolbarRootProps, DataToolbarSearch, type DataToolbarSearchProps, DataToolbarSelection, type DataToolbarSelectionProps, DataToolbarSeparator, type DataToolbarSeparatorProps, DataToolbarSort, type DataToolbarSortProps };
|
|
@@ -3,7 +3,7 @@ const require_data_view = require("../../styled-system/recipes/data-view.cjs");
|
|
|
3
3
|
let react = require("react");
|
|
4
4
|
let react_jsx_runtime = require("react/jsx-runtime");
|
|
5
5
|
//#region src/components/data-view/data-view.tsx
|
|
6
|
-
const DataViewRoot = (0, react.forwardRef)(function DataViewRoot({ children, className, columns = 3, layout = "list", ...props }, ref) {
|
|
6
|
+
const DataViewRoot = (0, react.forwardRef)(function DataViewRoot({ children, className, columns = 3, layout = "list", status = "idle", ...props }, ref) {
|
|
7
7
|
const styles = require_data_view.dataView({
|
|
8
8
|
columns: String(columns),
|
|
9
9
|
layout
|
|
@@ -12,9 +12,11 @@ const DataViewRoot = (0, react.forwardRef)(function DataViewRoot({ children, cla
|
|
|
12
12
|
...props,
|
|
13
13
|
ref,
|
|
14
14
|
className: require_cx.cx(styles.root, className),
|
|
15
|
+
"aria-busy": props["aria-busy"] ?? (status === "loading" || void 0),
|
|
15
16
|
"data-columns": columns,
|
|
16
17
|
"data-jaci-component": "data-view",
|
|
17
18
|
"data-layout": layout,
|
|
19
|
+
"data-status": status,
|
|
18
20
|
"data-slot": "data-view",
|
|
19
21
|
children
|
|
20
22
|
});
|
|
@@ -27,6 +29,14 @@ const DataViewToolbar = (0, react.forwardRef)(function DataViewToolbar({ classNa
|
|
|
27
29
|
"data-slot": "data-view-toolbar"
|
|
28
30
|
});
|
|
29
31
|
});
|
|
32
|
+
const DataViewFilters = (0, react.forwardRef)(function DataViewFilters({ className, ...props }, ref) {
|
|
33
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
34
|
+
...props,
|
|
35
|
+
ref,
|
|
36
|
+
className: require_cx.cx(require_data_view.dataView().filters, className),
|
|
37
|
+
"data-slot": "data-view-filters"
|
|
38
|
+
});
|
|
39
|
+
});
|
|
30
40
|
const DataViewContent = (0, react.forwardRef)(function DataViewContent({ className, ...props }, ref) {
|
|
31
41
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
32
42
|
...props,
|
|
@@ -35,6 +45,22 @@ const DataViewContent = (0, react.forwardRef)(function DataViewContent({ classNa
|
|
|
35
45
|
"data-slot": "data-view-content"
|
|
36
46
|
});
|
|
37
47
|
});
|
|
48
|
+
const DataViewFooter = (0, react.forwardRef)(function DataViewFooter({ className, ...props }, ref) {
|
|
49
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
50
|
+
...props,
|
|
51
|
+
ref,
|
|
52
|
+
className: require_cx.cx(require_data_view.dataView().footer, className),
|
|
53
|
+
"data-slot": "data-view-footer"
|
|
54
|
+
});
|
|
55
|
+
});
|
|
56
|
+
const DataViewPagination = (0, react.forwardRef)(function DataViewPagination({ className, ...props }, ref) {
|
|
57
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
58
|
+
...props,
|
|
59
|
+
ref,
|
|
60
|
+
className: require_cx.cx(require_data_view.dataView().pagination, className),
|
|
61
|
+
"data-slot": "data-view-pagination"
|
|
62
|
+
});
|
|
63
|
+
});
|
|
38
64
|
const DataViewLoading = (0, react.forwardRef)(function DataViewLoading({ children = "Loading…", className, ...props }, ref) {
|
|
39
65
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
40
66
|
...props,
|
|
@@ -68,7 +94,10 @@ const DataViewError = (0, react.forwardRef)(function DataViewError({ children =
|
|
|
68
94
|
const DataView = {
|
|
69
95
|
Root: DataViewRoot,
|
|
70
96
|
Toolbar: DataViewToolbar,
|
|
97
|
+
Filters: DataViewFilters,
|
|
71
98
|
Content: DataViewContent,
|
|
99
|
+
Footer: DataViewFooter,
|
|
100
|
+
Pagination: DataViewPagination,
|
|
72
101
|
Loading: DataViewLoading,
|
|
73
102
|
Empty: DataViewEmpty,
|
|
74
103
|
Error: DataViewError
|
|
@@ -78,7 +107,10 @@ exports.DataView = DataView;
|
|
|
78
107
|
exports.DataViewContent = DataViewContent;
|
|
79
108
|
exports.DataViewEmpty = DataViewEmpty;
|
|
80
109
|
exports.DataViewError = DataViewError;
|
|
110
|
+
exports.DataViewFilters = DataViewFilters;
|
|
111
|
+
exports.DataViewFooter = DataViewFooter;
|
|
81
112
|
exports.DataViewLoading = DataViewLoading;
|
|
113
|
+
exports.DataViewPagination = DataViewPagination;
|
|
82
114
|
exports.DataViewRoot = DataViewRoot;
|
|
83
115
|
exports.DataViewToolbar = DataViewToolbar;
|
|
84
116
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"data-view.cjs","names":["dataView","cx"],"sources":["../../../src/components/data-view/data-view.tsx"],"sourcesContent":["import { forwardRef } from \"react\";\nimport type { ComponentPropsWithoutRef, ReactNode } from \"react\";\n\nimport { cx } from \"../../styled-system/css\";\nimport { dataView } from \"../../styled-system/recipes\";\n\nexport type DataViewLayout = \"table\" | \"list\" | \"grid\";\nexport type DataViewColumns = 1 | 2 | 3 | 4;\n\nexport interface DataViewRootProps extends Omit<ComponentPropsWithoutRef<\"section\">, \"children\"> {\n children?: ReactNode;\n columns?: DataViewColumns;\n layout?: DataViewLayout;\n}\n\nexport const DataViewRoot = forwardRef<HTMLElement, DataViewRootProps>(function DataViewRoot(\n { children, className, columns = 3, layout = \"list\", ...props },\n ref,\n) {\n const styles = dataView({ columns: String(columns) as \"1\" | \"2\" | \"3\" | \"4\", layout });\n\n return (\n <section\n {...props}\n ref={ref}\n className={cx(styles.root, className)}\n data-columns={columns}\n data-jaci-component=\"data-view\"\n data-layout={layout}\n data-slot=\"data-view\"\n >\n {children}\n </section>\n );\n});\n\nexport type DataViewToolbarProps = ComponentPropsWithoutRef<\"div\">;\nexport const DataViewToolbar = forwardRef<HTMLDivElement, DataViewToolbarProps>(\n function DataViewToolbar({ className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataView().toolbar, className)}\n data-slot=\"data-view-toolbar\"\n />\n );\n },\n);\n\nexport type DataViewContentProps = ComponentPropsWithoutRef<\"div\">;\nexport const DataViewContent = forwardRef<HTMLDivElement, DataViewContentProps>(\n function DataViewContent({ className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataView().content, className)}\n data-slot=\"data-view-content\"\n />\n );\n },\n);\n\nexport interface DataViewStateProps extends ComponentPropsWithoutRef<\"div\"> {\n children?: ReactNode;\n}\n\nexport const DataViewLoading = forwardRef<HTMLDivElement, DataViewStateProps>(\n function DataViewLoading({ children = \"Loading…\", className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n aria-live=\"polite\"\n className={cx(dataView().loading, className)}\n data-slot=\"data-view-loading\"\n >\n {children}\n </div>\n );\n },\n);\n\nexport const DataViewEmpty = forwardRef<HTMLDivElement, DataViewStateProps>(function DataViewEmpty(\n { children = \"No results found.\", className, ...props },\n ref,\n) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataView().empty, className)}\n data-slot=\"data-view-empty\"\n >\n {children}\n </div>\n );\n});\n\nexport const DataViewError = forwardRef<HTMLDivElement, DataViewStateProps>(function DataViewError(\n { children = \"Something went wrong.\", className, ...props },\n ref,\n) {\n return (\n <div\n {...props}\n ref={ref}\n aria-live=\"assertive\"\n className={cx(dataView().error, className)}\n data-slot=\"data-view-error\"\n role=\"alert\"\n >\n {children}\n </div>\n );\n});\n\n// biome-ignore lint/suspicious/noShadowRestrictedNames: DataView is the public component API name.\nexport const DataView = {\n Root: DataViewRoot,\n Toolbar: DataViewToolbar,\n Content: DataViewContent,\n Loading: DataViewLoading,\n Empty: DataViewEmpty,\n Error: DataViewError,\n};\n"],"mappings":";;;;;
|
|
1
|
+
{"version":3,"file":"data-view.cjs","names":["dataView","cx"],"sources":["../../../src/components/data-view/data-view.tsx"],"sourcesContent":["import { forwardRef } from \"react\";\nimport type { ComponentPropsWithoutRef, ReactNode } from \"react\";\n\nimport { cx } from \"../../styled-system/css\";\nimport { dataView } from \"../../styled-system/recipes\";\n\nexport type DataViewLayout = \"table\" | \"list\" | \"grid\";\nexport type DataViewColumns = 1 | 2 | 3 | 4;\nexport type DataViewStatus = \"idle\" | \"loading\" | \"empty\" | \"error\" | \"ready\";\n\nexport interface DataViewRootProps extends Omit<ComponentPropsWithoutRef<\"section\">, \"children\"> {\n children?: ReactNode;\n columns?: DataViewColumns;\n layout?: DataViewLayout;\n status?: DataViewStatus;\n}\n\nexport const DataViewRoot = forwardRef<HTMLElement, DataViewRootProps>(function DataViewRoot(\n { children, className, columns = 3, layout = \"list\", status = \"idle\", ...props },\n ref,\n) {\n const styles = dataView({ columns: String(columns) as \"1\" | \"2\" | \"3\" | \"4\", layout });\n\n return (\n <section\n {...props}\n ref={ref}\n className={cx(styles.root, className)}\n aria-busy={props[\"aria-busy\"] ?? (status === \"loading\" || undefined)}\n data-columns={columns}\n data-jaci-component=\"data-view\"\n data-layout={layout}\n data-status={status}\n data-slot=\"data-view\"\n >\n {children}\n </section>\n );\n});\n\nexport type DataViewToolbarProps = ComponentPropsWithoutRef<\"div\">;\nexport const DataViewToolbar = forwardRef<HTMLDivElement, DataViewToolbarProps>(\n function DataViewToolbar({ className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataView().toolbar, className)}\n data-slot=\"data-view-toolbar\"\n />\n );\n },\n);\n\nexport type DataViewFiltersProps = ComponentPropsWithoutRef<\"div\">;\nexport const DataViewFilters = forwardRef<HTMLDivElement, DataViewFiltersProps>(\n function DataViewFilters({ className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataView().filters, className)}\n data-slot=\"data-view-filters\"\n />\n );\n },\n);\n\nexport type DataViewContentProps = ComponentPropsWithoutRef<\"div\">;\nexport const DataViewContent = forwardRef<HTMLDivElement, DataViewContentProps>(\n function DataViewContent({ className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataView().content, className)}\n data-slot=\"data-view-content\"\n />\n );\n },\n);\n\nexport type DataViewFooterProps = ComponentPropsWithoutRef<\"div\">;\nexport const DataViewFooter = forwardRef<HTMLDivElement, DataViewFooterProps>(\n function DataViewFooter({ className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataView().footer, className)}\n data-slot=\"data-view-footer\"\n />\n );\n },\n);\n\nexport type DataViewPaginationProps = ComponentPropsWithoutRef<\"div\">;\nexport const DataViewPagination = forwardRef<HTMLDivElement, DataViewPaginationProps>(\n function DataViewPagination({ className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataView().pagination, className)}\n data-slot=\"data-view-pagination\"\n />\n );\n },\n);\n\nexport interface DataViewStateProps extends ComponentPropsWithoutRef<\"div\"> {\n children?: ReactNode;\n}\n\nexport const DataViewLoading = forwardRef<HTMLDivElement, DataViewStateProps>(\n function DataViewLoading({ children = \"Loading…\", className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n aria-live=\"polite\"\n className={cx(dataView().loading, className)}\n data-slot=\"data-view-loading\"\n >\n {children}\n </div>\n );\n },\n);\n\nexport const DataViewEmpty = forwardRef<HTMLDivElement, DataViewStateProps>(function DataViewEmpty(\n { children = \"No results found.\", className, ...props },\n ref,\n) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataView().empty, className)}\n data-slot=\"data-view-empty\"\n >\n {children}\n </div>\n );\n});\n\nexport const DataViewError = forwardRef<HTMLDivElement, DataViewStateProps>(function DataViewError(\n { children = \"Something went wrong.\", className, ...props },\n ref,\n) {\n return (\n <div\n {...props}\n ref={ref}\n aria-live=\"assertive\"\n className={cx(dataView().error, className)}\n data-slot=\"data-view-error\"\n role=\"alert\"\n >\n {children}\n </div>\n );\n});\n\n// biome-ignore lint/suspicious/noShadowRestrictedNames: DataView is the public component API name.\nexport const DataView = {\n Root: DataViewRoot,\n Toolbar: DataViewToolbar,\n Filters: DataViewFilters,\n Content: DataViewContent,\n Footer: DataViewFooter,\n Pagination: DataViewPagination,\n Loading: DataViewLoading,\n Empty: DataViewEmpty,\n Error: DataViewError,\n};\n"],"mappings":";;;;;AAiBA,MAAa,gBAAA,GAAA,MAAA,WAAA,CAA0D,SAAS,aAC9E,EAAE,UAAU,WAAW,UAAU,GAAG,SAAS,QAAQ,SAAS,QAAQ,GAAG,SACzE,KACA;CACA,MAAM,SAASA,kBAAAA,SAAS;EAAE,SAAS,OAAO,OAAO;EAA4B;CAAO,CAAC;CAErF,OACE,iBAAA,GAAA,kBAAA,IAAA,CAAC,WAAD;EACE,GAAI;EACC;EACL,WAAWC,WAAAA,GAAG,OAAO,MAAM,SAAS;EACpC,aAAW,MAAM,iBAAiB,WAAW,aAAa,KAAA;EAC1D,gBAAc;EACd,uBAAoB;EACpB,eAAa;EACb,eAAa;EACb,aAAU;EAET;CACM,CAAA;AAEb,CAAC;AAGD,MAAa,mBAAA,GAAA,MAAA,WAAA,CACX,SAAS,gBAAgB,EAAE,WAAW,GAAG,SAAS,KAAK;CACrD,OACE,iBAAA,GAAA,kBAAA,IAAA,CAAC,OAAD;EACE,GAAI;EACC;EACL,WAAWA,WAAAA,GAAGD,kBAAAA,SAAS,CAAC,CAAC,SAAS,SAAS;EAC3C,aAAU;CACX,CAAA;AAEL,CACF;AAGA,MAAa,mBAAA,GAAA,MAAA,WAAA,CACX,SAAS,gBAAgB,EAAE,WAAW,GAAG,SAAS,KAAK;CACrD,OACE,iBAAA,GAAA,kBAAA,IAAA,CAAC,OAAD;EACE,GAAI;EACC;EACL,WAAWC,WAAAA,GAAGD,kBAAAA,SAAS,CAAC,CAAC,SAAS,SAAS;EAC3C,aA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,WAAAA,GAAGD,kBAAAA,SAAS,CAAC,CAAC,OAAO,SAAS;EACzC,aAAU;EAET;CACE,CAAA;AAET,CAAC;AAED,MAAa,iBAAA,GAAA,MAAA,WAAA,CAA+D,SAAS,cACnF,EAAE,WAAW,yBAAyB,WAAW,GAAG,SACpD,KACA;CACA,OACE,iBAAA,GAAA,kBAAA,IAAA,CAAC,OAAD;EACE,GAAI;EACC;EACL,aAAU;EACV,WAAWC,WAAAA,GAAGD,kBAAAA,SAAS,CAAC,CAAC,OAAO,SAAS;EACzC,aAAU;EACV,MAAK;EAEJ;CACE,CAAA;AAET,CAAC;AAGD,MAAa,WAAW;CACtB,MAAM;CACN,SAAS;CACT,SAAS;CACT,SAAS;CACT,QAAQ;CACR,YAAY;CACZ,SAAS;CACT,OAAO;CACP,OAAO;AACT"}
|
|
@@ -2,16 +2,24 @@ import { ComponentPropsWithoutRef, ReactNode } from "react";
|
|
|
2
2
|
//#region src/components/data-view/data-view.d.ts
|
|
3
3
|
type DataViewLayout = "table" | "list" | "grid";
|
|
4
4
|
type DataViewColumns = 1 | 2 | 3 | 4;
|
|
5
|
+
type DataViewStatus = "idle" | "loading" | "empty" | "error" | "ready";
|
|
5
6
|
interface DataViewRootProps extends Omit<ComponentPropsWithoutRef<"section">, "children"> {
|
|
6
7
|
children?: ReactNode;
|
|
7
8
|
columns?: DataViewColumns;
|
|
8
9
|
layout?: DataViewLayout;
|
|
10
|
+
status?: DataViewStatus;
|
|
9
11
|
}
|
|
10
12
|
declare const DataViewRoot: import("react").ForwardRefExoticComponent<DataViewRootProps & import("react").RefAttributes<HTMLElement>>;
|
|
11
13
|
type DataViewToolbarProps = ComponentPropsWithoutRef<"div">;
|
|
12
14
|
declare const DataViewToolbar: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
15
|
+
type DataViewFiltersProps = ComponentPropsWithoutRef<"div">;
|
|
16
|
+
declare const DataViewFilters: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
13
17
|
type DataViewContentProps = ComponentPropsWithoutRef<"div">;
|
|
14
18
|
declare const DataViewContent: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
19
|
+
type DataViewFooterProps = ComponentPropsWithoutRef<"div">;
|
|
20
|
+
declare const DataViewFooter: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
21
|
+
type DataViewPaginationProps = ComponentPropsWithoutRef<"div">;
|
|
22
|
+
declare const DataViewPagination: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
15
23
|
interface DataViewStateProps extends ComponentPropsWithoutRef<"div"> {
|
|
16
24
|
children?: ReactNode;
|
|
17
25
|
}
|
|
@@ -21,11 +29,14 @@ declare const DataViewError: import("react").ForwardRefExoticComponent<DataViewS
|
|
|
21
29
|
declare const DataView: {
|
|
22
30
|
Root: import("react").ForwardRefExoticComponent<DataViewRootProps & import("react").RefAttributes<HTMLElement>>;
|
|
23
31
|
Toolbar: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
32
|
+
Filters: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
24
33
|
Content: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
34
|
+
Footer: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
35
|
+
Pagination: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
25
36
|
Loading: import("react").ForwardRefExoticComponent<DataViewStateProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
26
37
|
Empty: import("react").ForwardRefExoticComponent<DataViewStateProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
27
38
|
Error: import("react").ForwardRefExoticComponent<DataViewStateProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
28
39
|
};
|
|
29
40
|
//#endregion
|
|
30
|
-
export { DataView, DataViewColumns, DataViewContent, DataViewContentProps, DataViewEmpty, DataViewError, DataViewLayout, DataViewLoading, DataViewRoot, DataViewRootProps, DataViewStateProps, DataViewToolbar, DataViewToolbarProps };
|
|
41
|
+
export { DataView, DataViewColumns, DataViewContent, DataViewContentProps, DataViewEmpty, DataViewError, DataViewFilters, DataViewFiltersProps, DataViewFooter, DataViewFooterProps, DataViewLayout, DataViewLoading, DataViewPagination, DataViewPaginationProps, DataViewRoot, DataViewRootProps, DataViewStateProps, DataViewStatus, DataViewToolbar, DataViewToolbarProps };
|
|
31
42
|
//# sourceMappingURL=data-view.d.cts.map
|
|
@@ -2,16 +2,24 @@ import { ComponentPropsWithoutRef, ReactNode } from "react";
|
|
|
2
2
|
//#region src/components/data-view/data-view.d.ts
|
|
3
3
|
type DataViewLayout = "table" | "list" | "grid";
|
|
4
4
|
type DataViewColumns = 1 | 2 | 3 | 4;
|
|
5
|
+
type DataViewStatus = "idle" | "loading" | "empty" | "error" | "ready";
|
|
5
6
|
interface DataViewRootProps extends Omit<ComponentPropsWithoutRef<"section">, "children"> {
|
|
6
7
|
children?: ReactNode;
|
|
7
8
|
columns?: DataViewColumns;
|
|
8
9
|
layout?: DataViewLayout;
|
|
10
|
+
status?: DataViewStatus;
|
|
9
11
|
}
|
|
10
12
|
declare const DataViewRoot: import("react").ForwardRefExoticComponent<DataViewRootProps & import("react").RefAttributes<HTMLElement>>;
|
|
11
13
|
type DataViewToolbarProps = ComponentPropsWithoutRef<"div">;
|
|
12
14
|
declare const DataViewToolbar: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
15
|
+
type DataViewFiltersProps = ComponentPropsWithoutRef<"div">;
|
|
16
|
+
declare const DataViewFilters: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
13
17
|
type DataViewContentProps = ComponentPropsWithoutRef<"div">;
|
|
14
18
|
declare const DataViewContent: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
19
|
+
type DataViewFooterProps = ComponentPropsWithoutRef<"div">;
|
|
20
|
+
declare const DataViewFooter: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
21
|
+
type DataViewPaginationProps = ComponentPropsWithoutRef<"div">;
|
|
22
|
+
declare const DataViewPagination: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
15
23
|
interface DataViewStateProps extends ComponentPropsWithoutRef<"div"> {
|
|
16
24
|
children?: ReactNode;
|
|
17
25
|
}
|
|
@@ -21,11 +29,14 @@ declare const DataViewError: import("react").ForwardRefExoticComponent<DataViewS
|
|
|
21
29
|
declare const DataView: {
|
|
22
30
|
Root: import("react").ForwardRefExoticComponent<DataViewRootProps & import("react").RefAttributes<HTMLElement>>;
|
|
23
31
|
Toolbar: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
32
|
+
Filters: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
24
33
|
Content: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
34
|
+
Footer: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
35
|
+
Pagination: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
25
36
|
Loading: import("react").ForwardRefExoticComponent<DataViewStateProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
26
37
|
Empty: import("react").ForwardRefExoticComponent<DataViewStateProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
27
38
|
Error: import("react").ForwardRefExoticComponent<DataViewStateProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
28
39
|
};
|
|
29
40
|
//#endregion
|
|
30
|
-
export { DataView, DataViewColumns, DataViewContent, DataViewContentProps, DataViewEmpty, DataViewError, DataViewLayout, DataViewLoading, DataViewRoot, DataViewRootProps, DataViewStateProps, DataViewToolbar, DataViewToolbarProps };
|
|
41
|
+
export { DataView, DataViewColumns, DataViewContent, DataViewContentProps, DataViewEmpty, DataViewError, DataViewFilters, DataViewFiltersProps, DataViewFooter, DataViewFooterProps, DataViewLayout, DataViewLoading, DataViewPagination, DataViewPaginationProps, DataViewRoot, DataViewRootProps, DataViewStateProps, DataViewStatus, DataViewToolbar, DataViewToolbarProps };
|
|
31
42
|
//# sourceMappingURL=data-view.d.ts.map
|
|
@@ -3,7 +3,7 @@ import { dataView } from "../../styled-system/recipes/data-view.js";
|
|
|
3
3
|
import { forwardRef } from "react";
|
|
4
4
|
import { jsx } from "react/jsx-runtime";
|
|
5
5
|
//#region src/components/data-view/data-view.tsx
|
|
6
|
-
const DataViewRoot = forwardRef(function DataViewRoot({ children, className, columns = 3, layout = "list", ...props }, ref) {
|
|
6
|
+
const DataViewRoot = forwardRef(function DataViewRoot({ children, className, columns = 3, layout = "list", status = "idle", ...props }, ref) {
|
|
7
7
|
const styles = dataView({
|
|
8
8
|
columns: String(columns),
|
|
9
9
|
layout
|
|
@@ -12,9 +12,11 @@ const DataViewRoot = forwardRef(function DataViewRoot({ children, className, col
|
|
|
12
12
|
...props,
|
|
13
13
|
ref,
|
|
14
14
|
className: cx(styles.root, className),
|
|
15
|
+
"aria-busy": props["aria-busy"] ?? (status === "loading" || void 0),
|
|
15
16
|
"data-columns": columns,
|
|
16
17
|
"data-jaci-component": "data-view",
|
|
17
18
|
"data-layout": layout,
|
|
19
|
+
"data-status": status,
|
|
18
20
|
"data-slot": "data-view",
|
|
19
21
|
children
|
|
20
22
|
});
|
|
@@ -27,6 +29,14 @@ const DataViewToolbar = forwardRef(function DataViewToolbar({ className, ...prop
|
|
|
27
29
|
"data-slot": "data-view-toolbar"
|
|
28
30
|
});
|
|
29
31
|
});
|
|
32
|
+
const DataViewFilters = forwardRef(function DataViewFilters({ className, ...props }, ref) {
|
|
33
|
+
return /* @__PURE__ */ jsx("div", {
|
|
34
|
+
...props,
|
|
35
|
+
ref,
|
|
36
|
+
className: cx(dataView().filters, className),
|
|
37
|
+
"data-slot": "data-view-filters"
|
|
38
|
+
});
|
|
39
|
+
});
|
|
30
40
|
const DataViewContent = forwardRef(function DataViewContent({ className, ...props }, ref) {
|
|
31
41
|
return /* @__PURE__ */ jsx("div", {
|
|
32
42
|
...props,
|
|
@@ -35,6 +45,22 @@ const DataViewContent = forwardRef(function DataViewContent({ className, ...prop
|
|
|
35
45
|
"data-slot": "data-view-content"
|
|
36
46
|
});
|
|
37
47
|
});
|
|
48
|
+
const DataViewFooter = forwardRef(function DataViewFooter({ className, ...props }, ref) {
|
|
49
|
+
return /* @__PURE__ */ jsx("div", {
|
|
50
|
+
...props,
|
|
51
|
+
ref,
|
|
52
|
+
className: cx(dataView().footer, className),
|
|
53
|
+
"data-slot": "data-view-footer"
|
|
54
|
+
});
|
|
55
|
+
});
|
|
56
|
+
const DataViewPagination = forwardRef(function DataViewPagination({ className, ...props }, ref) {
|
|
57
|
+
return /* @__PURE__ */ jsx("div", {
|
|
58
|
+
...props,
|
|
59
|
+
ref,
|
|
60
|
+
className: cx(dataView().pagination, className),
|
|
61
|
+
"data-slot": "data-view-pagination"
|
|
62
|
+
});
|
|
63
|
+
});
|
|
38
64
|
const DataViewLoading = forwardRef(function DataViewLoading({ children = "Loading…", className, ...props }, ref) {
|
|
39
65
|
return /* @__PURE__ */ jsx("div", {
|
|
40
66
|
...props,
|
|
@@ -68,12 +94,15 @@ const DataViewError = forwardRef(function DataViewError({ children = "Something
|
|
|
68
94
|
const DataView = {
|
|
69
95
|
Root: DataViewRoot,
|
|
70
96
|
Toolbar: DataViewToolbar,
|
|
97
|
+
Filters: DataViewFilters,
|
|
71
98
|
Content: DataViewContent,
|
|
99
|
+
Footer: DataViewFooter,
|
|
100
|
+
Pagination: DataViewPagination,
|
|
72
101
|
Loading: DataViewLoading,
|
|
73
102
|
Empty: DataViewEmpty,
|
|
74
103
|
Error: DataViewError
|
|
75
104
|
};
|
|
76
105
|
//#endregion
|
|
77
|
-
export { DataView, DataViewContent, DataViewEmpty, DataViewError, DataViewLoading, DataViewRoot, DataViewToolbar };
|
|
106
|
+
export { DataView, DataViewContent, DataViewEmpty, DataViewError, DataViewFilters, DataViewFooter, DataViewLoading, DataViewPagination, DataViewRoot, DataViewToolbar };
|
|
78
107
|
|
|
79
108
|
//# sourceMappingURL=data-view.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"data-view.js","names":[],"sources":["../../../src/components/data-view/data-view.tsx"],"sourcesContent":["import { forwardRef } from \"react\";\nimport type { ComponentPropsWithoutRef, ReactNode } from \"react\";\n\nimport { cx } from \"../../styled-system/css\";\nimport { dataView } from \"../../styled-system/recipes\";\n\nexport type DataViewLayout = \"table\" | \"list\" | \"grid\";\nexport type DataViewColumns = 1 | 2 | 3 | 4;\n\nexport interface DataViewRootProps extends Omit<ComponentPropsWithoutRef<\"section\">, \"children\"> {\n children?: ReactNode;\n columns?: DataViewColumns;\n layout?: DataViewLayout;\n}\n\nexport const DataViewRoot = forwardRef<HTMLElement, DataViewRootProps>(function DataViewRoot(\n { children, className, columns = 3, layout = \"list\", ...props },\n ref,\n) {\n const styles = dataView({ columns: String(columns) as \"1\" | \"2\" | \"3\" | \"4\", layout });\n\n return (\n <section\n {...props}\n ref={ref}\n className={cx(styles.root, className)}\n data-columns={columns}\n data-jaci-component=\"data-view\"\n data-layout={layout}\n data-slot=\"data-view\"\n >\n {children}\n </section>\n );\n});\n\nexport type DataViewToolbarProps = ComponentPropsWithoutRef<\"div\">;\nexport const DataViewToolbar = forwardRef<HTMLDivElement, DataViewToolbarProps>(\n function DataViewToolbar({ className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataView().toolbar, className)}\n data-slot=\"data-view-toolbar\"\n />\n );\n },\n);\n\nexport type DataViewContentProps = ComponentPropsWithoutRef<\"div\">;\nexport const DataViewContent = forwardRef<HTMLDivElement, DataViewContentProps>(\n function DataViewContent({ className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataView().content, className)}\n data-slot=\"data-view-content\"\n />\n );\n },\n);\n\nexport interface DataViewStateProps extends ComponentPropsWithoutRef<\"div\"> {\n children?: ReactNode;\n}\n\nexport const DataViewLoading = forwardRef<HTMLDivElement, DataViewStateProps>(\n function DataViewLoading({ children = \"Loading…\", className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n aria-live=\"polite\"\n className={cx(dataView().loading, className)}\n data-slot=\"data-view-loading\"\n >\n {children}\n </div>\n );\n },\n);\n\nexport const DataViewEmpty = forwardRef<HTMLDivElement, DataViewStateProps>(function DataViewEmpty(\n { children = \"No results found.\", className, ...props },\n ref,\n) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataView().empty, className)}\n data-slot=\"data-view-empty\"\n >\n {children}\n </div>\n );\n});\n\nexport const DataViewError = forwardRef<HTMLDivElement, DataViewStateProps>(function DataViewError(\n { children = \"Something went wrong.\", className, ...props },\n ref,\n) {\n return (\n <div\n {...props}\n ref={ref}\n aria-live=\"assertive\"\n className={cx(dataView().error, className)}\n data-slot=\"data-view-error\"\n role=\"alert\"\n >\n {children}\n </div>\n );\n});\n\n// biome-ignore lint/suspicious/noShadowRestrictedNames: DataView is the public component API name.\nexport const DataView = {\n Root: DataViewRoot,\n Toolbar: DataViewToolbar,\n Content: DataViewContent,\n Loading: DataViewLoading,\n Empty: DataViewEmpty,\n Error: DataViewError,\n};\n"],"mappings":";;;;;
|
|
1
|
+
{"version":3,"file":"data-view.js","names":[],"sources":["../../../src/components/data-view/data-view.tsx"],"sourcesContent":["import { forwardRef } from \"react\";\nimport type { ComponentPropsWithoutRef, ReactNode } from \"react\";\n\nimport { cx } from \"../../styled-system/css\";\nimport { dataView } from \"../../styled-system/recipes\";\n\nexport type DataViewLayout = \"table\" | \"list\" | \"grid\";\nexport type DataViewColumns = 1 | 2 | 3 | 4;\nexport type DataViewStatus = \"idle\" | \"loading\" | \"empty\" | \"error\" | \"ready\";\n\nexport interface DataViewRootProps extends Omit<ComponentPropsWithoutRef<\"section\">, \"children\"> {\n children?: ReactNode;\n columns?: DataViewColumns;\n layout?: DataViewLayout;\n status?: DataViewStatus;\n}\n\nexport const DataViewRoot = forwardRef<HTMLElement, DataViewRootProps>(function DataViewRoot(\n { children, className, columns = 3, layout = \"list\", status = \"idle\", ...props },\n ref,\n) {\n const styles = dataView({ columns: String(columns) as \"1\" | \"2\" | \"3\" | \"4\", layout });\n\n return (\n <section\n {...props}\n ref={ref}\n className={cx(styles.root, className)}\n aria-busy={props[\"aria-busy\"] ?? (status === \"loading\" || undefined)}\n data-columns={columns}\n data-jaci-component=\"data-view\"\n data-layout={layout}\n data-status={status}\n data-slot=\"data-view\"\n >\n {children}\n </section>\n );\n});\n\nexport type DataViewToolbarProps = ComponentPropsWithoutRef<\"div\">;\nexport const DataViewToolbar = forwardRef<HTMLDivElement, DataViewToolbarProps>(\n function DataViewToolbar({ className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataView().toolbar, className)}\n data-slot=\"data-view-toolbar\"\n />\n );\n },\n);\n\nexport type DataViewFiltersProps = ComponentPropsWithoutRef<\"div\">;\nexport const DataViewFilters = forwardRef<HTMLDivElement, DataViewFiltersProps>(\n function DataViewFilters({ className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataView().filters, className)}\n data-slot=\"data-view-filters\"\n />\n );\n },\n);\n\nexport type DataViewContentProps = ComponentPropsWithoutRef<\"div\">;\nexport const DataViewContent = forwardRef<HTMLDivElement, DataViewContentProps>(\n function DataViewContent({ className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataView().content, className)}\n data-slot=\"data-view-content\"\n />\n );\n },\n);\n\nexport type DataViewFooterProps = ComponentPropsWithoutRef<\"div\">;\nexport const DataViewFooter = forwardRef<HTMLDivElement, DataViewFooterProps>(\n function DataViewFooter({ className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataView().footer, className)}\n data-slot=\"data-view-footer\"\n />\n );\n },\n);\n\nexport type DataViewPaginationProps = ComponentPropsWithoutRef<\"div\">;\nexport const DataViewPagination = forwardRef<HTMLDivElement, DataViewPaginationProps>(\n function DataViewPagination({ className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataView().pagination, className)}\n data-slot=\"data-view-pagination\"\n />\n );\n },\n);\n\nexport interface DataViewStateProps extends ComponentPropsWithoutRef<\"div\"> {\n children?: ReactNode;\n}\n\nexport const DataViewLoading = forwardRef<HTMLDivElement, DataViewStateProps>(\n function DataViewLoading({ children = \"Loading…\", className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n aria-live=\"polite\"\n className={cx(dataView().loading, className)}\n data-slot=\"data-view-loading\"\n >\n {children}\n </div>\n );\n },\n);\n\nexport const DataViewEmpty = forwardRef<HTMLDivElement, DataViewStateProps>(function DataViewEmpty(\n { children = \"No results found.\", className, ...props },\n ref,\n) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(dataView().empty, className)}\n data-slot=\"data-view-empty\"\n >\n {children}\n </div>\n );\n});\n\nexport const DataViewError = forwardRef<HTMLDivElement, DataViewStateProps>(function DataViewError(\n { children = \"Something went wrong.\", className, ...props },\n ref,\n) {\n return (\n <div\n {...props}\n ref={ref}\n aria-live=\"assertive\"\n className={cx(dataView().error, className)}\n data-slot=\"data-view-error\"\n role=\"alert\"\n >\n {children}\n </div>\n );\n});\n\n// biome-ignore lint/suspicious/noShadowRestrictedNames: DataView is the public component API name.\nexport const DataView = {\n Root: DataViewRoot,\n Toolbar: DataViewToolbar,\n Filters: DataViewFilters,\n Content: DataViewContent,\n Footer: DataViewFooter,\n Pagination: DataViewPagination,\n Loading: DataViewLoading,\n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ChC,SAAS,mBAAmB,EAAE,WAAW,GAAG,SAAS,KAAK;CACxD,OACE,oBAAC,OAAD;EACE,GAAI;EACC;EACL,WAAW,GAAG,SAAS,CAAC,CAAC,YAAY,SAAS;EAC9C,aAAU;CACX,CAAA;AAEL,CACF;AAMA,MAAa,kBAAkB,WAC7B,SAAS,gBAAgB,EAAE,WAAW,YAAY,WAAW,GAAG,SAAS,KAAK;CAC5E,OACE,oBAAC,OAAD;EACE,GAAI;EACC;EACL,aAAU;EACV,WAAW,GAAG,SAAS,CAAC,CAAC,SAAS,SAAS;EAC3C,aAAU;EAET;CACE,CAAA;AAET,CACF;AAEA,MAAa,gBAAgB,WAA+C,SAAS,cACnF,EAAE,WAAW,qBAAqB,WAAW,GAAG,SAChD,KACA;CACA,OACE,oBAAC,OAAD;EACE,GAAI;EACC;EACL,WAAW,GAAG,SAAS,CAAC,CAAC,OAAO,SAAS;EACzC,aAAU;EAET;CACE,CAAA;AAET,CAAC;AAED,MAAa,gBAAgB,WAA+C,SAAS,cACnF,EAAE,WAAW,yBAAyB,WAAW,GAAG,SACpD,KACA;CACA,OACE,oBAAC,OAAD;EACE,GAAI;EACC;EACL,aAAU;EACV,WAAW,GAAG,SAAS,CAAC,CAAC,OAAO,SAAS;EACzC,aAAU;EACV,MAAK;EAEJ;CACE,CAAA;AAET,CAAC;AAGD,MAAa,WAAW;CACtB,MAAM;CACN,SAAS;CACT,SAAS;CACT,SAAS;CACT,QAAQ;CACR,YAAY;CACZ,SAAS;CACT,OAAO;CACP,OAAO;AACT"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { DataView, DataViewColumns, DataViewContent, DataViewContentProps, DataViewEmpty, DataViewError, DataViewLayout, DataViewLoading, DataViewRoot, DataViewRootProps, DataViewStateProps, DataViewToolbar, DataViewToolbarProps } from "./data-view.cjs";
|
|
2
|
-
export { DataView, type DataViewColumns, DataViewContent, type DataViewContentProps, DataViewEmpty, DataViewError, type DataViewLayout, DataViewLoading, DataViewRoot, type DataViewRootProps, type DataViewStateProps, DataViewToolbar, type DataViewToolbarProps };
|
|
1
|
+
import { DataView, DataViewColumns, DataViewContent, DataViewContentProps, DataViewEmpty, DataViewError, DataViewFilters, DataViewFiltersProps, DataViewFooter, DataViewFooterProps, DataViewLayout, DataViewLoading, DataViewPagination, DataViewPaginationProps, DataViewRoot, DataViewRootProps, DataViewStateProps, DataViewStatus, DataViewToolbar, DataViewToolbarProps } from "./data-view.cjs";
|
|
2
|
+
export { DataView, type DataViewColumns, DataViewContent, type DataViewContentProps, DataViewEmpty, DataViewError, DataViewFilters, type DataViewFiltersProps, DataViewFooter, type DataViewFooterProps, type DataViewLayout, DataViewLoading, DataViewPagination, type DataViewPaginationProps, DataViewRoot, type DataViewRootProps, type DataViewStateProps, type DataViewStatus, DataViewToolbar, type DataViewToolbarProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { DataView, DataViewColumns, DataViewContent, DataViewContentProps, DataViewEmpty, DataViewError, DataViewLayout, DataViewLoading, DataViewRoot, DataViewRootProps, DataViewStateProps, DataViewToolbar, DataViewToolbarProps } from "./data-view.js";
|
|
2
|
-
export { DataView, type DataViewColumns, DataViewContent, type DataViewContentProps, DataViewEmpty, DataViewError, type DataViewLayout, DataViewLoading, DataViewRoot, type DataViewRootProps, type DataViewStateProps, DataViewToolbar, type DataViewToolbarProps };
|
|
1
|
+
import { DataView, DataViewColumns, DataViewContent, DataViewContentProps, DataViewEmpty, DataViewError, DataViewFilters, DataViewFiltersProps, DataViewFooter, DataViewFooterProps, DataViewLayout, DataViewLoading, DataViewPagination, DataViewPaginationProps, DataViewRoot, DataViewRootProps, DataViewStateProps, DataViewStatus, DataViewToolbar, DataViewToolbarProps } from "./data-view.js";
|
|
2
|
+
export { DataView, type DataViewColumns, DataViewContent, type DataViewContentProps, DataViewEmpty, DataViewError, DataViewFilters, type DataViewFiltersProps, DataViewFooter, type DataViewFooterProps, type DataViewLayout, DataViewLoading, DataViewPagination, type DataViewPaginationProps, DataViewRoot, type DataViewRootProps, type DataViewStateProps, type DataViewStatus, DataViewToolbar, type DataViewToolbarProps };
|
|
@@ -3,8 +3,9 @@ const require_list = require("../../styled-system/recipes/list.cjs");
|
|
|
3
3
|
let react = require("react");
|
|
4
4
|
let react_jsx_runtime = require("react/jsx-runtime");
|
|
5
5
|
//#region src/components/list/list.tsx
|
|
6
|
-
const ListRoot = (0, react.forwardRef)(function ListRoot({ children, className, gap = "md", ordered = false, variant = "plain", ...props }, ref) {
|
|
6
|
+
const ListRoot = (0, react.forwardRef)(function ListRoot({ children, className, density = "comfortable", gap = "md", ordered = false, variant = "plain", ...props }, ref) {
|
|
7
7
|
const styles = require_list.list({
|
|
8
|
+
density,
|
|
8
9
|
gap,
|
|
9
10
|
variant
|
|
10
11
|
});
|
|
@@ -13,6 +14,7 @@ const ListRoot = (0, react.forwardRef)(function ListRoot({ children, className,
|
|
|
13
14
|
ref,
|
|
14
15
|
className: require_cx.cx(styles.root, className),
|
|
15
16
|
"data-gap": gap,
|
|
17
|
+
"data-density": density,
|
|
16
18
|
"data-jaci-component": "list",
|
|
17
19
|
"data-ordered": ordered || void 0,
|
|
18
20
|
"data-slot": "list",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"list.cjs","names":["list","cx"],"sources":["../../../src/components/list/list.tsx"],"sourcesContent":["import { forwardRef } from \"react\";\nimport type { ComponentPropsWithoutRef, ReactNode } from \"react\";\n\nimport { cx } from \"../../styled-system/css\";\nimport { list } from \"../../styled-system/recipes\";\n\nexport type ListVariant = \"plain\" | \"divided\" | \"card\";\nexport type ListGap = \"none\" | \"sm\" | \"md\" | \"lg\";\n\nexport interface ListRootProps extends Omit<ComponentPropsWithoutRef<\"ul\">, \"children\"> {\n children?: ReactNode;\n gap?: ListGap;\n ordered?: boolean;\n variant?: ListVariant;\n}\n\nexport const ListRoot = forwardRef<HTMLElement, ListRootProps>(function ListRoot(\n {
|
|
1
|
+
{"version":3,"file":"list.cjs","names":["list","cx"],"sources":["../../../src/components/list/list.tsx"],"sourcesContent":["import { forwardRef } from \"react\";\nimport type { ComponentPropsWithoutRef, ReactNode } from \"react\";\n\nimport { cx } from \"../../styled-system/css\";\nimport { list } from \"../../styled-system/recipes\";\n\nexport type ListVariant = \"plain\" | \"divided\" | \"card\";\nexport type ListGap = \"none\" | \"sm\" | \"md\" | \"lg\";\nexport type ListDensity = \"compact\" | \"comfortable\";\n\nexport interface ListRootProps extends Omit<ComponentPropsWithoutRef<\"ul\">, \"children\"> {\n children?: ReactNode;\n density?: ListDensity;\n gap?: ListGap;\n ordered?: boolean;\n variant?: ListVariant;\n}\n\nexport const ListRoot = forwardRef<HTMLElement, ListRootProps>(function ListRoot(\n {\n children,\n className,\n density = \"comfortable\",\n gap = \"md\",\n ordered = false,\n variant = \"plain\",\n ...props\n },\n ref,\n) {\n const styles = list({ density, gap, variant });\n const Component = ordered ? \"ol\" : \"ul\";\n\n return (\n <Component\n {...props}\n ref={ref as never}\n className={cx(styles.root, className)}\n data-gap={gap}\n data-density={density}\n data-jaci-component=\"list\"\n data-ordered={ordered || undefined}\n data-slot=\"list\"\n data-variant={variant}\n >\n {children}\n </Component>\n );\n});\n\nexport interface ListItemProps extends Omit<ComponentPropsWithoutRef<\"li\">, \"children\"> {\n children?: ReactNode;\n disabled?: boolean;\n interactive?: boolean;\n selected?: boolean;\n}\n\nexport const ListItem = forwardRef<HTMLLIElement, ListItemProps>(function ListItem(\n { children, className, disabled = false, interactive = false, selected = false, ...props },\n ref,\n) {\n const styles = list();\n\n return (\n <li\n {...props}\n ref={ref}\n aria-disabled={disabled || undefined}\n className={cx(styles.item, className)}\n data-disabled={disabled || undefined}\n data-interactive={interactive || undefined}\n data-selected={selected || undefined}\n data-slot=\"list-item\"\n >\n {children}\n </li>\n );\n});\n\nexport type ListItemContentProps = ComponentPropsWithoutRef<\"div\">;\nexport const ListItemContent = forwardRef<HTMLDivElement, ListItemContentProps>(\n function ListItemContent({ className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(list().content, className)}\n data-slot=\"list-item-content\"\n />\n );\n },\n);\n\nexport type ListItemTitleProps = ComponentPropsWithoutRef<\"span\">;\nexport const ListItemTitle = forwardRef<HTMLSpanElement, ListItemTitleProps>(function ListItemTitle(\n { className, ...props },\n ref,\n) {\n return (\n <span\n {...props}\n ref={ref}\n className={cx(list().title, className)}\n data-slot=\"list-item-title\"\n />\n );\n});\n\nexport type ListItemDescriptionProps = ComponentPropsWithoutRef<\"span\">;\nexport const ListItemDescription = forwardRef<HTMLSpanElement, ListItemDescriptionProps>(\n function ListItemDescription({ className, ...props }, ref) {\n return (\n <span\n {...props}\n ref={ref}\n className={cx(list().description, className)}\n data-slot=\"list-item-description\"\n />\n );\n },\n);\n\nexport type ListItemActionProps = ComponentPropsWithoutRef<\"div\">;\nexport const ListItemAction = forwardRef<HTMLDivElement, ListItemActionProps>(\n function ListItemAction({ className, ...props }, ref) {\n return (\n <div\n {...props}\n ref={ref}\n className={cx(list().action, className)}\n data-slot=\"list-item-action\"\n />\n );\n },\n);\n\nexport const List = {\n Root: ListRoot,\n Item: ListItem,\n ItemContent: ListItemContent,\n ItemTitle: ListItemTitle,\n ItemDescription: ListItemDescription,\n ItemAction: ListItemAction,\n};\n"],"mappings":";;;;;AAkBA,MAAa,YAAA,GAAA,MAAA,WAAA,CAAkD,SAAS,SACtE,EACE,UACA,WACA,UAAU,eACV,MAAM,MACN,UAAU,OACV,UAAU,SACV,GAAG,SAEL,KACA;CACA,MAAM,SAASA,aAAAA,KAAK;EAAE;EAAS;EAAK;CAAQ,CAAC;CAG7C,OACE,iBAAA,GAAA,kBAAA,IAAA,CAHgB,UAAU,OAAO,MAGjC;EACE,GAAI;EACC;EACL,WAAWC,WAAAA,GAAG,OAAO,MAAM,SAAS;EACpC,YAAU;EACV,gBAAc;EACd,uBAAoB;EACpB,gBAAc,WAAW,KAAA;EACzB,aAAU;EACV,gBAAc;EAEb;CACQ,CAAA;AAEf,CAAC;AASD,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AK;CACpD,OACE,iBAAA,GAAA,kBAAA,IAAA,CAAC,OAAD;EACE,GAAI;EACC;EACL,WAAWC,WAAAA,GAAGD,aAAAA,KAAK,CAAC,CAAC,QAAQ,SAAS;EACtC,aAAU;CACX,CAAA;AAEL,CACF;AAEA,MAAa,OAAO;CAClB,MAAM;CACN,MAAM;CACN,aAAa;CACb,WAAW;CACX,iBAAiB;CACjB,YAAY;AACd"}
|
|
@@ -2,8 +2,10 @@ import { ComponentPropsWithoutRef, ReactNode } from "react";
|
|
|
2
2
|
//#region src/components/list/list.d.ts
|
|
3
3
|
type ListVariant = "plain" | "divided" | "card";
|
|
4
4
|
type ListGap = "none" | "sm" | "md" | "lg";
|
|
5
|
+
type ListDensity = "compact" | "comfortable";
|
|
5
6
|
interface ListRootProps extends Omit<ComponentPropsWithoutRef<"ul">, "children"> {
|
|
6
7
|
children?: ReactNode;
|
|
8
|
+
density?: ListDensity;
|
|
7
9
|
gap?: ListGap;
|
|
8
10
|
ordered?: boolean;
|
|
9
11
|
variant?: ListVariant;
|
|
@@ -33,5 +35,5 @@ declare const List: {
|
|
|
33
35
|
ItemAction: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
34
36
|
};
|
|
35
37
|
//#endregion
|
|
36
|
-
export { List, ListGap, ListItem, ListItemAction, ListItemActionProps, ListItemContent, ListItemContentProps, ListItemDescription, ListItemDescriptionProps, ListItemProps, ListItemTitle, ListItemTitleProps, ListRoot, ListRootProps, ListVariant };
|
|
38
|
+
export { List, ListDensity, ListGap, ListItem, ListItemAction, ListItemActionProps, ListItemContent, ListItemContentProps, ListItemDescription, ListItemDescriptionProps, ListItemProps, ListItemTitle, ListItemTitleProps, ListRoot, ListRootProps, ListVariant };
|
|
37
39
|
//# sourceMappingURL=list.d.cts.map
|
|
@@ -2,8 +2,10 @@ import { ComponentPropsWithoutRef, ReactNode } from "react";
|
|
|
2
2
|
//#region src/components/list/list.d.ts
|
|
3
3
|
type ListVariant = "plain" | "divided" | "card";
|
|
4
4
|
type ListGap = "none" | "sm" | "md" | "lg";
|
|
5
|
+
type ListDensity = "compact" | "comfortable";
|
|
5
6
|
interface ListRootProps extends Omit<ComponentPropsWithoutRef<"ul">, "children"> {
|
|
6
7
|
children?: ReactNode;
|
|
8
|
+
density?: ListDensity;
|
|
7
9
|
gap?: ListGap;
|
|
8
10
|
ordered?: boolean;
|
|
9
11
|
variant?: ListVariant;
|
|
@@ -33,5 +35,5 @@ declare const List: {
|
|
|
33
35
|
ItemAction: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
34
36
|
};
|
|
35
37
|
//#endregion
|
|
36
|
-
export { List, ListGap, ListItem, ListItemAction, ListItemActionProps, ListItemContent, ListItemContentProps, ListItemDescription, ListItemDescriptionProps, ListItemProps, ListItemTitle, ListItemTitleProps, ListRoot, ListRootProps, ListVariant };
|
|
38
|
+
export { List, ListDensity, ListGap, ListItem, ListItemAction, ListItemActionProps, ListItemContent, ListItemContentProps, ListItemDescription, ListItemDescriptionProps, ListItemProps, ListItemTitle, ListItemTitleProps, ListRoot, ListRootProps, ListVariant };
|
|
37
39
|
//# sourceMappingURL=list.d.ts.map
|
|
@@ -3,8 +3,9 @@ import { list } from "../../styled-system/recipes/list.js";
|
|
|
3
3
|
import { forwardRef } from "react";
|
|
4
4
|
import { jsx } from "react/jsx-runtime";
|
|
5
5
|
//#region src/components/list/list.tsx
|
|
6
|
-
const ListRoot = forwardRef(function ListRoot({ children, className, gap = "md", ordered = false, variant = "plain", ...props }, ref) {
|
|
6
|
+
const ListRoot = forwardRef(function ListRoot({ children, className, density = "comfortable", gap = "md", ordered = false, variant = "plain", ...props }, ref) {
|
|
7
7
|
const styles = list({
|
|
8
|
+
density,
|
|
8
9
|
gap,
|
|
9
10
|
variant
|
|
10
11
|
});
|
|
@@ -13,6 +14,7 @@ const ListRoot = forwardRef(function ListRoot({ children, className, gap = "md",
|
|
|
13
14
|
ref,
|
|
14
15
|
className: cx(styles.root, className),
|
|
15
16
|
"data-gap": gap,
|
|
17
|
+
"data-density": density,
|
|
16
18
|
"data-jaci-component": "list",
|
|
17
19
|
"data-ordered": ordered || void 0,
|
|
18
20
|
"data-slot": "list",
|