@alexgorbatchev/shadcn 0.0.34 → 0.0.36

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/index.js CHANGED
@@ -4,21 +4,6 @@ import {
4
4
  AccordionItem2,
5
5
  AccordionTrigger2,
6
6
  AccordionContent2,
7
- Combobox2,
8
- ComboboxValue2,
9
- ComboboxTrigger2,
10
- ComboboxInput2,
11
- ComboboxContent2,
12
- ComboboxList2,
13
- ComboboxItem2,
14
- ComboboxGroup2,
15
- ComboboxLabel2,
16
- ComboboxCollection2,
17
- ComboboxEmpty2,
18
- ComboboxSeparator2,
19
- ComboboxChips2,
20
- ComboboxChip2,
21
- ComboboxChipsInput2,
22
7
  EmptyState3,
23
8
  PageMessage2,
24
9
  JsonViewer2,
@@ -49,7 +34,6 @@ import {
49
34
  LayoutGuard2,
50
35
  ScrollGuard2,
51
36
  ThemeProvider2,
52
- useComboboxAnchor2,
53
37
  AspectRatio2,
54
38
  Breadcrumb2,
55
39
  BreadcrumbList2,
@@ -79,8 +63,6 @@ import {
79
63
  PaginationPrevious2,
80
64
  PaginationNext2,
81
65
  PaginationEllipsis2,
82
- ScrollArea2,
83
- ScrollBar2,
84
66
  Drawer2,
85
67
  DrawerTrigger2,
86
68
  DrawerPortal2,
@@ -171,13 +153,6 @@ import {
171
153
  StarRating2,
172
154
  ConfirmationDialog2,
173
155
  ImagePicker2,
174
- NumberField2,
175
- NumberFieldGroup2,
176
- NumberFieldInput2,
177
- NumberFieldDecrement2,
178
- NumberFieldIncrement2,
179
- NumberFieldScrubArea2,
180
- NumberFieldScrubAreaCursor2,
181
156
  Meter2,
182
157
  MeterLabel2,
183
158
  MeterValue2,
@@ -201,7 +176,7 @@ import {
201
176
  StatusTracker2,
202
177
  DashboardLayout2,
203
178
  BillingUsage2
204
- } from "./chunk-c6g2rbhv.js";
179
+ } from "./chunk-f71469fs.js";
205
180
  import {
206
181
  Tabs2,
207
182
  tabsListVariants2,
@@ -225,6 +200,33 @@ import {
225
200
  ToolbarGroup2,
226
201
  ToolbarSeparator2
227
202
  } from "./chunk-83zjj4jd.js";
203
+ import {
204
+ Combobox2,
205
+ ComboboxValue2,
206
+ ComboboxTrigger2,
207
+ ComboboxInput2,
208
+ ComboboxContent2,
209
+ ComboboxList2,
210
+ ComboboxItem2,
211
+ ComboboxGroup2,
212
+ ComboboxLabel2,
213
+ ComboboxCollection2,
214
+ ComboboxEmpty2,
215
+ ComboboxSeparator2,
216
+ ComboboxChips2,
217
+ ComboboxChip2,
218
+ ComboboxChipsInput2,
219
+ useComboboxAnchor2,
220
+ ScrollArea2,
221
+ ScrollBar2,
222
+ NumberField2,
223
+ NumberFieldGroup2,
224
+ NumberFieldInput2,
225
+ NumberFieldDecrement2,
226
+ NumberFieldIncrement2,
227
+ NumberFieldScrubArea2,
228
+ NumberFieldScrubAreaCursor2
229
+ } from "./chunk-c7tnf6h7.js";
228
230
  import {
229
231
  NativeSelect2,
230
232
  NativeSelectOption2,
@@ -49,3 +49,11 @@ Storybook CSF excerpts. Default args and render apply unless overridden. Local h
49
49
  render: () => <Example pagination={false}/>
50
50
  }
51
51
  ```
52
+
53
+ ### CombinedSortHeader
54
+
55
+ ```tsx
56
+ {
57
+ render: () => <CombinedSortExample />
58
+ }
59
+ ```
@@ -0,0 +1,35 @@
1
+ # DataGridFilterSummary
2
+
3
+ Story: @alexgorbatchev/shadcn/components/data-display/DataGridFilterSummary
4
+ Source: src/components/stories/data-display/DataGridFilterSummary.stories.tsx
5
+
6
+ [Full source and local helpers](https://github.com/alexgorbatchev/shadcn/blob/main/src/components/stories/data-display/DataGridFilterSummary.stories.tsx)
7
+
8
+ ## Default render
9
+
10
+ ```tsx
11
+ () => (<FilteredDataGridExample recordings={fixture_gridRecordings} initialFilters={[
12
+ { id: "tempo", value: [128, 120] },
13
+ { id: "year", value: [2000, null] },
14
+ { id: "tags", value: ["Vocal"] },
15
+ { id: "room", value: ["Studio B"] },
16
+ ]}/>)
17
+ ```
18
+
19
+ ## Examples
20
+
21
+ Storybook CSF excerpts. Default args and render apply unless overridden. Local helpers, fixtures, decorators, and providers may be required; these are reference excerpts, not standalone consumer modules. Interaction tests are omitted.
22
+
23
+ ### Default
24
+
25
+ ```tsx
26
+ {}
27
+ ```
28
+
29
+ ### OpenEndedRange
30
+
31
+ ```tsx
32
+ {
33
+ render: () => (<FilteredDataGridExample recordings={fixture_gridRecordings} initialFilters={[{ id: "tempo", value: [null, 126] }]}/>)
34
+ }
35
+ ```
@@ -0,0 +1,38 @@
1
+ # DataGridFilters
2
+
3
+ Story: @alexgorbatchev/shadcn/components/data-display/DataGridFilters
4
+ Source: src/components/stories/data-display/DataGridFilters.stories.tsx
5
+
6
+ [Full source and local helpers](https://github.com/alexgorbatchev/shadcn/blob/main/src/components/stories/data-display/DataGridFilters.stories.tsx)
7
+
8
+ ## Default render
9
+
10
+ ```tsx
11
+ () => <FilteredDataGridExample recordings={fixture_gridRecordings}/>
12
+ ```
13
+
14
+ ## Examples
15
+
16
+ Storybook CSF excerpts. Default args and render apply unless overridden. Local helpers, fixtures, decorators, and providers may be required; these are reference excerpts, not standalone consumer modules. Interaction tests are omitted.
17
+
18
+ ### Default
19
+
20
+ ```tsx
21
+ {}
22
+ ```
23
+
24
+ ### CombinedWithSearch
25
+
26
+ ```tsx
27
+ {
28
+ render: () => (<FilteredDataGridExample recordings={fixture_gridRecordings} initialFilters={[{ id: "tags", value: ["Vocal"] }]}/>)
29
+ }
30
+ ```
31
+
32
+ ### SavedValueWithoutOption
33
+
34
+ ```tsx
35
+ {
36
+ render: () => (<FilteredDataGridExample recordings={fixture_gridRecordings} initialFilters={[{ id: "genre", value: ["Polka"] }]}/>)
37
+ }
38
+ ```
package/llms/setup.md CHANGED
@@ -304,7 +304,9 @@ Compose `QuestionnaireItem`, `QuestionnaireTitle`, and answer controls inside `Q
304
304
 
305
305
  `VirtualTable` renders a bounded, dynamically measured set of native table rows using TanStack Virtual. Supply `items`, stable `getItemKey`, `header`, `label`, and `renderRow`; spread the supplied measurement props onto each native row. Optional `columns` accepts a `TableColumnGroup`; responsive columns keep their widths aligned with cells that share their `visibleFrom`. `maxHeight` defaults to `65vh`, `estimateRowHeight` to 80 pixels, and `overscan` to five rows. `retainedKeys` keeps editing rows mounted; the focused row is retained automatically. Filtering and selection belong to the consumer.
306
306
 
307
- `VirtualDataGrid` renders a TanStack Table instance built with `dataGridFeatures` through `VirtualTable`: every filtered and sorted row, without pagination, in a fixed-layout table. Column `meta` sets `label`, `textAlign`, `truncate`, `visibleFrom`, and `fill`; a `fill` column takes the width the sized columns leave. Other resizable columns get a window-splitter handle that resizes by dragging, by the arrow keys, Home, and End, and resets on double-click. Set `columnResizeMode: "onChange"` so columns follow the pointer while dragging; TanStack's default `"onEnd"` resizes only on release. Widths change through CSS variables, so a `useTable` selector can omit `columnSizing` and `columnResizing` to keep resizing from rendering rows. `renderRow` receives each row and its measurement props; spread the props onto a `TableRow` and render `DataGridCells` inside it to wrap rows in menus or drag sources. `retainedRowIds` keeps rows mounted while they hold editors. `DataGridColumnOptions` shows, hides, and reorders the columns that allow hiding; its reset restores the table's initial visibility, order, and sizes.
307
+ `VirtualDataGrid` renders a TanStack Table instance built with `dataGridFeatures` through `VirtualTable`: every filtered and sorted row, without pagination, in a fixed-layout table. Column `meta` sets `label`, `textAlign`, `truncate`, `visibleFrom`, `fill`, and `sortColumnIds`; a `fill` column takes the width the sized columns leave, and `sortColumnIds` names other columns the header sorts with its own buttons so its `aria-sort` reports them. Other resizable columns get a window-splitter handle that resizes by dragging, by the arrow keys, Home, and End, and resets on double-click. Set `columnResizeMode: "onChange"` so columns follow the pointer while dragging; TanStack's default `"onEnd"` resizes only on release. Widths change through CSS variables, so a `useTable` selector can omit `columnSizing` and `columnResizing` to keep resizing from rendering rows. `renderRow` receives each row and its measurement props; spread the props onto a `TableRow` and render `DataGridCells` inside it to wrap rows in menus or drag sources. `retainedRowIds` keeps rows mounted while they hold editors. `DataGridColumnOptions` shows, hides, and reorders the columns that allow hiding; its reset restores the table's initial visibility, order, and sizes.
308
+
309
+ Column `meta.filter` offers a column in `DataGridFilters`, hidden columns included. A `range` filter edits `[min, max]` bounds, `null` for an open end, for `filterFn: "inNumberRange"`; its inputs suggest the range of the rows the other filters leave, formatted through the filter's `Intl.NumberFormatOptions`. An `options` filter chooses among labelled string values, one or several, for `filterFn: "arrHas"` (one value per row), `"arrIncludesSome"` (an array per row), or a custom `filterFn`; each option counts the rows the other filters leave with that value, so a column whose rows hold several values or values in another form supplies them through `getUniqueValues`. Column filters combine with each other and with the global filter. `DataGridFilterSummary` lists the active filters with buttons that remove them, and both controls clear every column filter at once.
308
310
 
309
311
  `StarRating` takes a controlled numeric `value` from 0 to 5, `onValueChange`, and an accessible `label`. Its native radio buttons support keyboard selection and an Unrated option to clear the rating. Set `disabled` while saving. `Avatar shape="square"` displays square artwork with matching image, fallback, and border corners.
310
312
 
package/llms.txt CHANGED
@@ -334,6 +334,8 @@ Generated from the public package exports and Storybook sources.
334
334
  - [Chart](./llms/components/data-display/Chart.md)
335
335
  - [DataGrid](./llms/components/data-display/DataGrid.md)
336
336
  - [DataGridColumnOptions](./llms/components/data-display/DataGridColumnOptions.md)
337
+ - [DataGridFilterSummary](./llms/components/data-display/DataGridFilterSummary.md)
338
+ - [DataGridFilters](./llms/components/data-display/DataGridFilters.md)
337
339
  - [Item](./llms/components/data-display/Item.md)
338
340
  - [JsonRender](./llms/components/data-display/JsonRender.md)
339
341
  - [JsonViewer](./llms/components/data-display/JsonViewer.md)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alexgorbatchev/shadcn",
3
- "version": "0.0.34",
3
+ "version": "0.0.36",
4
4
  "description": "Sharp, monospace React components with compact and comfortable densities.",
5
5
  "license": "MIT",
6
6
  "repository": {