@alexgorbatchev/shadcn 0.0.29 → 0.0.30
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/{chunk-3z5gpbh0.js → chunk-987zth0a.js} +1 -1
- package/dist/{chunk-v0k5jnk5.js → chunk-zte6pw69.js} +2 -1
- package/dist/components/Table.d.ts +6 -3
- package/dist/components/assistant-ui/elements/DataTable.js +2 -2
- package/dist/components/assistant-ui/index.js +2 -2
- package/dist/components/data-grid/index.js +1 -1
- package/dist/components/gantt/index.js +1 -1
- package/dist/components/virtual-table/index.js +1 -1
- package/dist/index.js +1 -1
- package/llms/components/data-display/Table.md +1 -1
- package/llms/components/data-display/VirtualTable.md +2 -2
- package/package.json +1 -1
|
@@ -103,10 +103,11 @@ function TableColumnGroup2(props) {
|
|
|
103
103
|
...props
|
|
104
104
|
});
|
|
105
105
|
}
|
|
106
|
-
function TableColumn2({ className, visibleFrom, ...props }) {
|
|
106
|
+
function TableColumn2({ className, style, visibleFrom, width, ...props }) {
|
|
107
107
|
return /* @__PURE__ */ jsx("col", {
|
|
108
108
|
"data-slot": "table-column",
|
|
109
109
|
className: cn2(visibleFrom && columnVisibilityClasses[visibleFrom], className),
|
|
110
|
+
style: width === undefined ? style : { ...style, width },
|
|
110
111
|
...props
|
|
111
112
|
});
|
|
112
113
|
}
|
|
@@ -25,9 +25,12 @@ type TableCellProps = ComponentProps<"td"> & IDensityProps & ITableCellOptions;
|
|
|
25
25
|
declare function TableCell({ density, className, truncate, textAlign, visibleFrom, ...props }: TableCellProps): ReactElement;
|
|
26
26
|
type TableColumnGroupProps = ComponentProps<"colgroup">;
|
|
27
27
|
declare function TableColumnGroup(props: TableColumnGroupProps): ReactElement;
|
|
28
|
-
type TableColumnProps = ComponentProps<"col"> & Pick<ITableCellOptions, "visibleFrom"
|
|
29
|
-
/**
|
|
30
|
-
|
|
28
|
+
type TableColumnProps = ComponentProps<"col"> & Pick<ITableCellOptions, "visibleFrom"> & {
|
|
29
|
+
/** Fixed column width; numbers are pixels. Columns without one share the remaining width. */
|
|
30
|
+
width?: number | string;
|
|
31
|
+
};
|
|
32
|
+
/** A column; give it the same `visibleFrom` as its header and cells. */
|
|
33
|
+
declare function TableColumn({ className, style, visibleFrom, width, ...props }: TableColumnProps): ReactElement;
|
|
31
34
|
type TableCaptionProps = ComponentProps<"caption"> & IDensityProps;
|
|
32
35
|
declare function TableCaption({ density, className, ...props }: TableCaptionProps): ReactElement;
|
|
33
36
|
export { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption, TableColumnGroup, TableColumn, };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import {
|
|
2
2
|
DataTable2
|
|
3
|
-
} from "../../../chunk-
|
|
3
|
+
} from "../../../chunk-987zth0a.js";
|
|
4
4
|
import"../../../chunk-1wz92wgg.js";
|
|
5
|
-
import"../../../chunk-
|
|
5
|
+
import"../../../chunk-zte6pw69.js";
|
|
6
6
|
import"../../../chunk-bygq5yqf.js";
|
|
7
7
|
import"../../../chunk-wjx6zf94.js";
|
|
8
8
|
import"../../../chunk-q7p28b89.js";
|
|
@@ -199,8 +199,8 @@ import"../../chunk-1wz92wgg.js";
|
|
|
199
199
|
import"../../chunk-wjx6zf94.js";
|
|
200
200
|
import {
|
|
201
201
|
DataTable2
|
|
202
|
-
} from "../../chunk-
|
|
203
|
-
import"../../chunk-
|
|
202
|
+
} from "../../chunk-987zth0a.js";
|
|
203
|
+
import"../../chunk-zte6pw69.js";
|
|
204
204
|
import {
|
|
205
205
|
DaySeparator2
|
|
206
206
|
} from "../../chunk-jhw9q2eq.js";
|
package/dist/index.js
CHANGED
|
@@ -266,7 +266,7 @@ Storybook CSF excerpts. Default args and render apply unless overridden. Local h
|
|
|
266
266
|
<Table layout="fixed">
|
|
267
267
|
<TableColumnGroup>
|
|
268
268
|
<TableColumn />
|
|
269
|
-
<TableColumn visibleFrom="container-sm"
|
|
269
|
+
<TableColumn visibleFrom="container-sm" width={60}/>
|
|
270
270
|
</TableColumnGroup>
|
|
271
271
|
<TableHeader>
|
|
272
272
|
<TableRow>
|
|
@@ -62,8 +62,8 @@ Storybook CSF excerpts. Default args and render apply unless overridden. Local h
|
|
|
62
62
|
args: {
|
|
63
63
|
columns: (<TableColumnGroup>
|
|
64
64
|
<TableColumn />
|
|
65
|
-
<TableColumn visibleFrom="container-sm"
|
|
66
|
-
<TableColumn
|
|
65
|
+
<TableColumn visibleFrom="container-sm" width={80}/>
|
|
66
|
+
<TableColumn width={60}/>
|
|
67
67
|
</TableColumnGroup>),
|
|
68
68
|
header: (<TableRow>
|
|
69
69
|
<TableHead scope="col">Name</TableHead>
|