@alexgorbatchev/shadcn 0.0.27 → 0.0.29

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/README.md CHANGED
@@ -50,28 +50,28 @@ Package preparation and contributor commands are documented in [AGENTS.md](./AGE
50
50
 
51
51
  Import shared controls and providers from `@alexgorbatchev/shadcn`. Import the following features from their dedicated entry points and install only the peers you use. These features, their hooks, and their types are not exported from the package root.
52
52
 
53
- | Import path suffix | Components | Install alongside the package |
54
- | ------------------- | -------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- |
55
- | `/chart` | Chart parts, AnalyticsChart, Sparkline, hooks and types | `bun add recharts@3.8.0 cssesc@3.0.0 es-toolkit@1.52.0` |
56
- | `/calendar` | Calendar, CalendarDayButton, DatePicker, DateRangePicker | `bun add @daypicker/react@^10.0.2` |
57
- | `/persian-calendar` | PersianCalendar | `bun add @daypicker/persian@^10.0.2 @daypicker/react@^10.0.2` |
58
- | `/carousel` | Carousel components, useCarousel, and carousel types | `bun add embla-carousel-react@^8.6.0` |
59
- | `/command` | Command components, including CommandDialog | `bun add cmdk@^1.1.1` |
60
- | `/resizable` | Resizable components and SplitView | `bun add react-resizable-panels@^4.14.3` |
61
- | `/fonts.css` | JetBrains Mono font stylesheet | `bun add @fontsource-variable/jetbrains-mono@^5.3.0` |
62
- | `/sonner` | Sonner, SonnerToaster, Toaster, toast, useSonner | No additional install; patched implementation is bundled |
63
- | `/input-otp` | InputOTP components | No additional install; patched implementation is bundled |
64
- | `/virtual-table` | VirtualTable and row measurement props | `@tanstack/react-virtual@3.14.13` |
65
- | `/message-scroller` | MessageScroller components, hooks, and types | No additional install; patched implementation is bundled |
66
- | `/questionnaire` | Questionnaire components and types | No additional install; patched implementation is bundled |
67
- | `/data-grid` | DataGrid and native table helpers | `bun add @tanstack/react-table@9.2.8` |
68
- | `/file-upload` | FileUpload selection and validation | `bun add react-dropzone@^20.1.4` |
69
- | `/color-picker` | ColorPicker | `bun add react-colorful@^5.8.1` |
70
- | `/image-crop` | ImageCrop and native export helpers | `bun add react-image-crop@^11.1.2` |
71
- | `/tree` | Tree, native hooks and features | `bun add @headless-tree/core@^1.8.0 @headless-tree/react@^1.8.0` |
72
- | `/editor` | RichTextEditor, native Tiptap hooks and StarterKit | `bun add @tiptap/core@^3.32.0 @tiptap/react@^3.32.0 @tiptap/pm@^3.32.0 @tiptap/starter-kit@^3.32.0` |
73
- | `/event-calendar` | EventCalendar, EventForm and native calendar APIs | `bun add react-big-calendar@^1.20.0 date-fns@^4.4.0`; TypeScript: `bun add -d @types/react-big-calendar@^1.16.3` |
74
- | `/gantt` | Gantt and Roadmap | `bun add date-fns@^4.4.0 @date-fns/tz@^1.5.0` |
53
+ | Import path suffix | Components | Install alongside the package |
54
+ | ------------------- | -------------------------------------------------------- | --------------------------------------------------------------------------------------------------- |
55
+ | `/chart` | Chart parts, AnalyticsChart, Sparkline, hooks and types | `bun add recharts@3.8.0 cssesc@3.0.0 es-toolkit@1.52.0` |
56
+ | `/calendar` | Calendar, CalendarDayButton, DatePicker, DateRangePicker | `bun add @daypicker/react@^10.0.2` |
57
+ | `/persian-calendar` | PersianCalendar | `bun add @daypicker/persian@^10.0.2 @daypicker/react@^10.0.2` |
58
+ | `/carousel` | Carousel components, useCarousel, and carousel types | `bun add embla-carousel-react@^8.6.0` |
59
+ | `/command` | Command components, including CommandDialog | `bun add cmdk@^1.1.1` |
60
+ | `/resizable` | Resizable components and SplitView | `bun add react-resizable-panels@^4.14.3` |
61
+ | `/fonts.css` | JetBrains Mono font stylesheet | `bun add @fontsource-variable/jetbrains-mono@^5.3.0` |
62
+ | `/sonner` | Sonner, SonnerToaster, Toaster, toast, useSonner | No additional install; patched implementation is bundled |
63
+ | `/input-otp` | InputOTP components | No additional install; patched implementation is bundled |
64
+ | `/virtual-table` | VirtualTable and row measurement props | `@tanstack/react-virtual@3.14.13` |
65
+ | `/message-scroller` | MessageScroller components, hooks, and types | No additional install; patched implementation is bundled |
66
+ | `/questionnaire` | Questionnaire components and types | No additional install; patched implementation is bundled |
67
+ | `/data-grid` | DataGrid and native table helpers | `bun add @tanstack/react-table@9.2.8` |
68
+ | `/file-upload` | FileUpload selection and validation | `bun add react-dropzone@^20.1.4` |
69
+ | `/color-picker` | ColorPicker | `bun add react-colorful@^5.8.1` |
70
+ | `/image-crop` | ImageCrop and native export helpers | `bun add react-image-crop@^11.1.2` |
71
+ | `/tree` | Tree, native hooks and features | `bun add @headless-tree/core@^1.8.0 @headless-tree/react@^1.8.0` |
72
+ | `/editor` | RichTextEditor, native Tiptap hooks and StarterKit | `bun add @tiptap/core@^3.32.0 @tiptap/react@^3.32.0 @tiptap/pm@^3.32.0 @tiptap/starter-kit@^3.32.0` |
73
+ | `/event-calendar` | EventCalendar, EventForm and native calendar APIs | `bun add date-fns@^4.4.0`; TypeScript: `bun add -d @types/react-big-calendar@^1.16.3` |
74
+ | `/gantt` | Gantt and Roadmap | `bun add date-fns@^4.4.0 @date-fns/tz@^1.5.0` |
75
75
 
76
76
  Import `@alexgorbatchev/shadcn/event-calendar.css` for EventCalendar, and `react-image-crop/dist/ReactCrop.css` for ImageCrop. The root also provides application shells, dashboard and billing layouts, authentication/settings forms, account/workspace controls, Kanban, facets, tags, number fields, toolbars, meters, stat cards and status displays. See the [component catalog reference](./docs/internal/component-catalog.md) for source groups, native APIs, dependency costs and consumer responsibilities.
77
77
 
@@ -83,7 +83,7 @@ import { ChartContainer, type ChartConfig } from "@alexgorbatchev/shadcn/chart";
83
83
  import { Carousel, CarouselContent, CarouselItem } from "@alexgorbatchev/shadcn/carousel";
84
84
  ```
85
85
 
86
- The patched `sonner`, `input-otp`, and `@shadcn/react` packages remain regular dependencies pending upstream fixes. `@base-ui/utils` is a regular dependency at the exact version `@base-ui/react` requires, so the portal components share Base UI's own ref merging without installing a second copy. Other feature dependencies are optional peers, so a core-only installation does not request them. Shared providers work across entry points.
86
+ The patched `sonner`, `input-otp`, and `@shadcn/react` packages remain regular dependencies pending upstream fixes. `react-big-calendar` is also a regular dependency: the calendar and its patched `uncontrollable` wrapper are bundled so React 19 consumers receive the JSX-runtime fix even when their package manager does not apply Bun patches. The corrected calendar runtime is isolated behind `/event-calendar`; React and declared peers remain external. This exception increases the installed dependency size even for core-only consumers. `@base-ui/utils` is a regular dependency at the exact version `@base-ui/react` requires, so the portal components share Base UI's own ref merging without installing a second copy. Other feature dependencies are optional peers, so a core-only installation does not request them. Shared providers work across entry points.
87
87
 
88
88
  The optional assistant-ui catalog provides presentational families under `/assistant-ui/<family>` and runtime adapters under `/assistant-ui/native/<family>`. For example, import `ApprovalCard` from `@alexgorbatchev/shadcn/assistant-ui/approval-card`. Add `@alexgorbatchev/shadcn/assistant-ui.css` to your stylesheet. Native threads require an actual assistant-ui runtime and the selected family's optional peers. See the [assistant-ui reference](./docs/internal/assistant-ui.md) for imports, dependency-bearing styles, source inventory, and the SelectionToolbar isolation limitation.
89
89
 
@@ -300,7 +300,7 @@ Compose `QuestionnaireItem`, `QuestionnaireTitle`, and answer controls inside `Q
300
300
 
301
301
  `InlineEdit` mounts an edit session with a controlled `value`, `onValueChange`, `onCommit`, and `onCancel`. Mount it in place of the displayed label. Its input focuses and selects its text by default; `shouldSelectOnMount={false}` preserves the initial caret. Enter or blur commits once, Escape cancels without committing, and asynchronous saves disable the input until completion. Rejected saves display an error and allow retry.
302
302
 
303
- `VirtualTable` renders a bounded, dynamically measured set of native table rows using TanStack Virtual. Supply `items`, stable `getItemKey`, `header`, `columnCount`, `label`, and `renderRow`; spread the supplied measurement props onto each native row. Optional `columns` accepts a colgroup. `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.
303
+ `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.
304
304
 
305
305
  `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.
306
306
 
@@ -214,4 +214,8 @@ The MIT examples at https://github.com/mantinedev/ui.mantine.dev/tree/966b0ff960
214
214
 
215
215
  ## Optional feature engines
216
216
 
217
- The optional feature imports use external, separately installed react-dropzone 20.1.4 (MIT), react-colorful 5.8.1 (MIT), react-image-crop 11.1.2 (ISC), Headless Tree 1.8.0 (MIT), Tiptap 3.32.0 (MIT), React Big Calendar 1.20.0 (MIT), date-fns 4.4.0 (MIT), and @date-fns/tz 1.5.0 (MIT). Their distributions retain their own license files. No third-party engine source is bundled into the package archive by these integrations. EventCalendar's companion stylesheet imports the externally installed React Big Calendar structural stylesheet and applies local semantic-token presentation.
217
+ The optional feature imports use external, separately installed react-dropzone 20.1.4 (MIT), react-colorful 5.8.1 (MIT), react-image-crop 11.1.2 (ISC), Headless Tree 1.8.0 (MIT), Tiptap 3.32.0 (MIT), date-fns 4.4.0 (MIT), and @date-fns/tz 1.5.0 (MIT). Their distributions retain their own license files. These feature engines remain external; the calendar exception is documented below. EventCalendar's companion stylesheet imports the installed React Big Calendar structural stylesheet and applies local semantic-token presentation.
218
+
219
+ ## React Big Calendar and uncontrollable
220
+
221
+ The `/event-calendar` entry point bundles React Big Calendar 1.20.0 (https://github.com/bigcalendar/react-big-calendar), uncontrollable 7.2.1 (https://github.com/jquense/uncontrollable), and their runtime dependencies. The version-pinned patch replaces uncontrollable’s obsolete compiled JSX calls with React’s JSX runtime in its ESM and CommonJS builds. Native state ownership, callbacks and ref forwarding are retained. React and declared peers remain external. Complete bundled dependency notices are included in [licenses/event-calendar.txt](./licenses/event-calendar.txt).
@@ -21,7 +21,7 @@ import {
21
21
  TableHead2,
22
22
  TableCell2,
23
23
  TableCaption2
24
- } from "./chunk-0y0kqaqj.js";
24
+ } from "./chunk-v0k5jnk5.js";
25
25
  import {
26
26
  safeHref
27
27
  } from "./chunk-xhtsnwnb.js";
@@ -61,6 +61,12 @@ var visibilityClasses = {
61
61
  "container-sm": "hidden @min-[400px]/table:table-cell",
62
62
  "container-md": "hidden @min-[480px]/table:table-cell"
63
63
  };
64
+ var columnVisibilityClasses = {
65
+ sm: "hidden sm:table-column",
66
+ lg: "hidden lg:table-column",
67
+ "container-sm": "hidden @min-[400px]/table:table-column",
68
+ "container-md": "hidden @min-[480px]/table:table-column"
69
+ };
64
70
  function TableHead2({
65
71
  density,
66
72
  className,
@@ -91,6 +97,19 @@ function TableCell2({
91
97
  ...props
92
98
  });
93
99
  }
100
+ function TableColumnGroup2(props) {
101
+ return /* @__PURE__ */ jsx("colgroup", {
102
+ "data-slot": "table-column-group",
103
+ ...props
104
+ });
105
+ }
106
+ function TableColumn2({ className, visibleFrom, ...props }) {
107
+ return /* @__PURE__ */ jsx("col", {
108
+ "data-slot": "table-column",
109
+ className: cn2(visibleFrom && columnVisibilityClasses[visibleFrom], className),
110
+ ...props
111
+ });
112
+ }
94
113
  function TableCaption2({ density, className, ...props }) {
95
114
  return /* @__PURE__ */ jsx("caption", {
96
115
  "data-density": density,
@@ -100,4 +119,4 @@ function TableCaption2({ density, className, ...props }) {
100
119
  });
101
120
  }
102
121
 
103
- export { Table2, TableHeader2, TableBody2, TableFooter2, TableRow2, TableHead2, TableCell2, TableCaption2 };
122
+ export { Table2, TableHeader2, TableBody2, TableFooter2, TableRow2, TableHead2, TableCell2, TableColumnGroup2, TableColumn2, TableCaption2 };
@@ -23,6 +23,11 @@ type TableHeadProps = ComponentProps<"th"> & IDensityProps & ITableCellOptions;
23
23
  declare function TableHead({ density, className, truncate, textAlign, visibleFrom, ...props }: TableHeadProps): ReactElement;
24
24
  type TableCellProps = ComponentProps<"td"> & IDensityProps & ITableCellOptions;
25
25
  declare function TableCell({ density, className, truncate, textAlign, visibleFrom, ...props }: TableCellProps): ReactElement;
26
+ type TableColumnGroupProps = ComponentProps<"colgroup">;
27
+ declare function TableColumnGroup(props: TableColumnGroupProps): ReactElement;
28
+ type TableColumnProps = ComponentProps<"col"> & Pick<ITableCellOptions, "visibleFrom">;
29
+ /** A sized column; give it the same `visibleFrom` as its header and cells. */
30
+ declare function TableColumn({ className, visibleFrom, ...props }: TableColumnProps): ReactElement;
26
31
  type TableCaptionProps = ComponentProps<"caption"> & IDensityProps;
27
32
  declare function TableCaption({ density, className, ...props }: TableCaptionProps): ReactElement;
28
- export { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };
33
+ export { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption, TableColumnGroup, TableColumn, };
@@ -1,8 +1,8 @@
1
1
  import {
2
2
  DataTable2
3
- } from "../../../chunk-g73meny4.js";
3
+ } from "../../../chunk-3z5gpbh0.js";
4
4
  import"../../../chunk-1wz92wgg.js";
5
- import"../../../chunk-0y0kqaqj.js";
5
+ import"../../../chunk-v0k5jnk5.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-g73meny4.js";
203
- import"../../chunk-0y0kqaqj.js";
202
+ } from "../../chunk-3z5gpbh0.js";
203
+ import"../../chunk-v0k5jnk5.js";
204
204
  import {
205
205
  DaySeparator2
206
206
  } from "../../chunk-jhw9q2eq.js";
@@ -9,7 +9,7 @@ import {
9
9
  TableRow2,
10
10
  TableHead2,
11
11
  TableCell2
12
- } from "../../chunk-0y0kqaqj.js";
12
+ } from "../../chunk-v0k5jnk5.js";
13
13
  import {
14
14
  NativeSelect2,
15
15
  NativeSelectOption2