@alexgorbatchev/shadcn 0.0.100 → 0.0.102

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.
Files changed (82) hide show
  1. package/dist/{chunk-h3a6hmnb.js → chunk-0fs7kth5.js} +1 -1
  2. package/dist/{chunk-6z6qn9zr.js → chunk-1sptf246.js} +1 -1
  3. package/dist/{chunk-kmqx7c48.js → chunk-23ppkypt.js} +1 -1
  4. package/dist/{chunk-1vqyxxma.js → chunk-262s62aq.js} +1 -1
  5. package/dist/{chunk-ydz0pe6z.js → chunk-3embwe93.js} +1 -1
  6. package/dist/{chunk-20ebs5z7.js → chunk-3vm7crwe.js} +1 -1
  7. package/dist/{chunk-0vr1f5fz.js → chunk-4hmj9az4.js} +1 -1
  8. package/dist/{chunk-jegx00xt.js → chunk-519826kj.js} +1 -1
  9. package/dist/{chunk-wxw0v3pe.js → chunk-55sxthsw.js} +1 -1
  10. package/dist/{chunk-nfffwr34.js → chunk-685qjx1b.js} +1 -1
  11. package/dist/{chunk-5xkfbnap.js → chunk-694x8nwa.js} +1 -1
  12. package/dist/{chunk-fhjv1twk.js → chunk-6kdbnv4d.js} +1 -1
  13. package/dist/{chunk-k82ncbmy.js → chunk-6nhb1ry9.js} +1 -1
  14. package/dist/{chunk-qs48ad08.js → chunk-74b44xsc.js} +1 -1
  15. package/dist/{chunk-tzf47swm.js → chunk-7ge3mb18.js} +4 -4
  16. package/dist/{chunk-bz0erpea.js → chunk-7n0et0mp.js} +1 -1
  17. package/dist/{chunk-4szrp20a.js → chunk-7xdx6cdp.js} +1 -1
  18. package/dist/{chunk-v3ep6b3p.js → chunk-8pkttcb2.js} +1 -1
  19. package/dist/{chunk-6s630syb.js → chunk-8v4dvfm5.js} +1 -1
  20. package/dist/{chunk-er6e5fj8.js → chunk-9k5b62qf.js} +2 -2
  21. package/dist/{chunk-cc59cf5a.js → chunk-afx7cvzs.js} +1 -1
  22. package/dist/{chunk-wgvpxw3p.js → chunk-bsg378sy.js} +8 -8
  23. package/dist/{chunk-cjbh4fp5.js → chunk-c0837w3f.js} +1 -1
  24. package/dist/{chunk-fpexqbj4.js → chunk-cxgdj2ht.js} +1 -1
  25. package/dist/{chunk-paswgbzy.js → chunk-f7wfcc1g.js} +3 -3
  26. package/dist/{chunk-gc08g76v.js → chunk-fpq79ygk.js} +1 -1
  27. package/dist/{chunk-es5wc0hy.js → chunk-g4s1f61z.js} +2 -2
  28. package/dist/{chunk-b2sn56jy.js → chunk-gmvg6hap.js} +1 -1
  29. package/dist/{chunk-1bs147rq.js → chunk-j1aecx7s.js} +1 -1
  30. package/dist/{chunk-4j3fsft3.js → chunk-mm3a9s11.js} +1 -1
  31. package/dist/{chunk-77s4s3mv.js → chunk-pn35mpc0.js} +1 -1
  32. package/dist/{chunk-zg6fvfj4.js → chunk-pqjmhmdq.js} +1 -1
  33. package/dist/{chunk-pj739h1d.js → chunk-s1asnp91.js} +1 -1
  34. package/dist/{chunk-nkh5ghr0.js → chunk-szc0hkzd.js} +1 -1
  35. package/dist/{chunk-b805vc70.js → chunk-t87gra6t.js} +1 -1
  36. package/dist/{chunk-vf5tw7dk.js → chunk-x80ehefm.js} +1 -1
  37. package/dist/{chunk-w9mmcpfj.js → chunk-y4xt9zfq.js} +1 -1
  38. package/dist/components/Textarea.d.ts +6 -2
  39. package/dist/components/assistant-ui/elements/ChatPanel.js +3 -3
  40. package/dist/components/assistant-ui/elements/CommandPalette.js +4 -4
  41. package/dist/components/assistant-ui/elements/ComposerAttachments.js +3 -3
  42. package/dist/components/assistant-ui/elements/ComposerBar.js +3 -3
  43. package/dist/components/assistant-ui/elements/ComposerInput.js +3 -3
  44. package/dist/components/assistant-ui/elements/ComposerToolbar.js +3 -3
  45. package/dist/components/assistant-ui/elements/ConversationSearch.js +3 -3
  46. package/dist/components/assistant-ui/elements/EditMessage.js +2 -2
  47. package/dist/components/assistant-ui/elements/EmptyStateComposer.js +3 -3
  48. package/dist/components/assistant-ui/elements/EveAskQuestion.js +3 -3
  49. package/dist/components/assistant-ui/elements/FeedbackDialog.js +2 -2
  50. package/dist/components/assistant-ui/elements/MobileComposer.js +3 -3
  51. package/dist/components/assistant-ui/elements/ModelSelector.js +10 -10
  52. package/dist/components/assistant-ui/elements/ModelSelectorContent.js +9 -9
  53. package/dist/components/assistant-ui/elements/ModelSelectorEmpty.js +4 -4
  54. package/dist/components/assistant-ui/elements/ModelSelectorFocusAnchor.js +4 -4
  55. package/dist/components/assistant-ui/elements/ModelSelectorGroup.js +4 -4
  56. package/dist/components/assistant-ui/elements/ModelSelectorItem.js +4 -4
  57. package/dist/components/assistant-ui/elements/ModelSelectorList.js +6 -6
  58. package/dist/components/assistant-ui/elements/ModelSelectorSearch.js +4 -4
  59. package/dist/components/assistant-ui/elements/ModelSelectorSeparator.js +4 -4
  60. package/dist/components/assistant-ui/elements/PromptLibrary.js +3 -3
  61. package/dist/components/assistant-ui/elements/SettingsPanel.js +2 -2
  62. package/dist/components/assistant-ui/elements/ThreadSearch.js +3 -3
  63. package/dist/components/assistant-ui/eveAskQuestionToolkit.js +4 -4
  64. package/dist/components/assistant-ui/index.js +29 -29
  65. package/dist/components/assistant-ui/native/AssistantModal.js +4 -4
  66. package/dist/components/assistant-ui/native/AssistantSidebar.js +4 -4
  67. package/dist/components/assistant-ui/native/ModelSelector.js +12 -12
  68. package/dist/components/assistant-ui/native/TaskCard.js +3 -3
  69. package/dist/components/assistant-ui/native/TaskGroup.js +4 -4
  70. package/dist/components/assistant-ui/native/Thread.js +3 -3
  71. package/dist/components/assistant-ui/native/ToolFallbackRoot.js +2 -2
  72. package/dist/components/assistant-ui/native/index.js +18 -18
  73. package/dist/components/command/index.js +3 -3
  74. package/dist/components/data-grid/index.js +3 -3
  75. package/dist/components/json-render/index.js +4 -4
  76. package/dist/components/sonner/Sonner.d.ts +9 -2
  77. package/dist/components/sonner/index.js +8 -4
  78. package/dist/index.js +4 -4
  79. package/dist/prototype.js +1 -1
  80. package/llms/components/feedback/Sonner.md +23 -0
  81. package/llms/components/forms/Textarea.md +16 -0
  82. package/package.json +1 -1
@@ -14,7 +14,7 @@ import"../../../chunk-e6hk39ev.js";
14
14
  import"../../../chunk-7jpsybag.js";
15
15
  import {
16
16
  Thread2
17
- } from "../../../chunk-w9mmcpfj.js";
17
+ } from "../../../chunk-y4xt9zfq.js";
18
18
  import"../../../chunk-jpvw9xqy.js";
19
19
  import"../../../chunk-32t5kc0y.js";
20
20
  import"../../../chunk-xyttc32e.js";
@@ -49,7 +49,7 @@ import {
49
49
  Reasoning2,
50
50
  ReasoningGroup2
51
51
  } from "../../../chunk-t75anqyy.js";
52
- import"../../../chunk-er6e5fj8.js";
52
+ import"../../../chunk-9k5b62qf.js";
53
53
  import {
54
54
  ToolFallbackRoot2,
55
55
  ToolFallbackTrigger2,
@@ -61,7 +61,7 @@ import {
61
61
  offersInterruptAction2,
62
62
  ToolFallbackApproval2,
63
63
  ToolFallback2
64
- } from "../../../chunk-1bs147rq.js";
64
+ } from "../../../chunk-j1aecx7s.js";
65
65
  import {
66
66
  ToolGroupRoot2,
67
67
  ToolGroupTrigger2,
@@ -81,11 +81,11 @@ import {
81
81
  import"../../../chunk-7vg045gd.js";
82
82
  import {
83
83
  AssistantModal2
84
- } from "../../../chunk-h3a6hmnb.js";
84
+ } from "../../../chunk-0fs7kth5.js";
85
85
  import"../../../chunk-5jgfh8t9.js";
86
86
  import {
87
87
  AssistantSidebar2
88
- } from "../../../chunk-qs48ad08.js";
88
+ } from "../../../chunk-74b44xsc.js";
89
89
  import {
90
90
  ComposerQuotePreviewRoot2,
91
91
  ComposerQuotePreviewIcon2,
@@ -152,20 +152,20 @@ import"../../../chunk-ydfx8r6d.js";
152
152
  import"../../../chunk-k2t9ey7z.js";
153
153
  import"../../../chunk-0qkdp68h.js";
154
154
  import"../../../chunk-gb16cwpw.js";
155
- import"../../../chunk-4j3fsft3.js";
156
- import"../../../chunk-20ebs5z7.js";
157
- import"../../../chunk-5xkfbnap.js";
158
- import"../../../chunk-pj739h1d.js";
159
- import"../../../chunk-6s630syb.js";
160
- import"../../../chunk-b2sn56jy.js";
161
- import"../../../chunk-paswgbzy.js";
155
+ import"../../../chunk-mm3a9s11.js";
156
+ import"../../../chunk-3vm7crwe.js";
157
+ import"../../../chunk-694x8nwa.js";
158
+ import"../../../chunk-s1asnp91.js";
159
+ import"../../../chunk-8v4dvfm5.js";
160
+ import"../../../chunk-gmvg6hap.js";
161
+ import"../../../chunk-f7wfcc1g.js";
162
162
  import"../../../chunk-pzr1f2tz.js";
163
- import"../../../chunk-tzf47swm.js";
164
- import"../../../chunk-1vqyxxma.js";
165
- import"../../../chunk-6z6qn9zr.js";
163
+ import"../../../chunk-7ge3mb18.js";
164
+ import"../../../chunk-262s62aq.js";
165
+ import"../../../chunk-1sptf246.js";
166
166
  import {
167
167
  ModelSelector3
168
- } from "../../../chunk-wgvpxw3p.js";
168
+ } from "../../../chunk-bsg378sy.js";
169
169
  import {
170
170
  QuoteBlockRoot2,
171
171
  QuoteBlockIcon2,
@@ -193,10 +193,10 @@ import"../../../chunk-cc3wzmev.js";
193
193
  import {
194
194
  isTaskPart2,
195
195
  TaskCard2
196
- } from "../../../chunk-0vr1f5fz.js";
196
+ } from "../../../chunk-4hmj9az4.js";
197
197
  import {
198
198
  TaskGroup2
199
- } from "../../../chunk-fhjv1twk.js";
199
+ } from "../../../chunk-6kdbnv4d.js";
200
200
  import {
201
201
  TaskTray2
202
202
  } from "../../../chunk-rgdesh1z.js";
@@ -8,8 +8,8 @@ import"../../chunk-32t5kc0y.js";
8
8
  import"../../chunk-xyttc32e.js";
9
9
  import"../../chunk-7jpsybag.js";
10
10
  import"../../chunk-7vg045gd.js";
11
- import"../../chunk-er6e5fj8.js";
12
- import"../../chunk-4j3fsft3.js";
11
+ import"../../chunk-9k5b62qf.js";
12
+ import"../../chunk-mm3a9s11.js";
13
13
  import {
14
14
  Command2,
15
15
  CommandDialog2,
@@ -20,7 +20,7 @@ import {
20
20
  CommandSeparator2,
21
21
  CommandItem2,
22
22
  CommandShortcut2
23
- } from "../../chunk-20ebs5z7.js";
23
+ } from "../../chunk-3vm7crwe.js";
24
24
  import"../../chunk-5mydsjp3.js";
25
25
  export {
26
26
  Command2 as Command,
@@ -49,12 +49,12 @@ import {
49
49
  NumberField2,
50
50
  NumberFieldGroup2,
51
51
  NumberFieldInput2
52
- } from "../../chunk-kmqx7c48.js";
52
+ } from "../../chunk-23ppkypt.js";
53
53
  import {
54
54
  Badge2
55
55
  } from "../../chunk-9t530p75.js";
56
- import"../../chunk-er6e5fj8.js";
57
- import"../../chunk-4j3fsft3.js";
56
+ import"../../chunk-9k5b62qf.js";
57
+ import"../../chunk-mm3a9s11.js";
58
58
  import {
59
59
  ScrollArea2
60
60
  } from "../../chunk-f9sm5zpv.js";
@@ -26,7 +26,7 @@ import {
26
26
  PaginationPrevious2,
27
27
  PaginationNext2,
28
28
  PaginationEllipsis2
29
- } from "../../chunk-es5wc0hy.js";
29
+ } from "../../chunk-g4s1f61z.js";
30
30
  import {
31
31
  MenuPopup,
32
32
  MenuItem2,
@@ -76,7 +76,7 @@ import {
76
76
  } from "../../chunk-m98d89xc.js";
77
77
  import {
78
78
  Textarea2
79
- } from "../../chunk-er6e5fj8.js";
79
+ } from "../../chunk-9k5b62qf.js";
80
80
  import {
81
81
  RadioGroup2,
82
82
  RadioGroupItem2
@@ -91,8 +91,8 @@ import {
91
91
  CardDescription2,
92
92
  CardContent2
93
93
  } from "../../chunk-r7krv555.js";
94
- import"../../chunk-4j3fsft3.js";
95
- import"../../chunk-kmqx7c48.js";
94
+ import"../../chunk-mm3a9s11.js";
95
+ import"../../chunk-23ppkypt.js";
96
96
  import {
97
97
  Tabs2,
98
98
  TabsList2,
@@ -2,7 +2,14 @@ import type { IAnalyticsProps } from "../../analytics/types.js";
2
2
  import type { ReactElement } from "react";
3
3
  import type { ToasterProps } from "sonner";
4
4
  import type { IDensityProps } from "../../density/types.js";
5
- type SonnerProps = ToasterProps & IDensityProps & IAnalyticsProps;
6
- declare function Sonner({ analytics, density, className, toastOptions, icons, theme, dir, expand, ...props }: SonnerProps): ReactElement;
5
+ interface ISonnerLiveProps {
6
+ /**
7
+ * Render the notifications section as a polite live region. Defaults to true. Pass false when the
8
+ * application announces each toast through its own live region, so screen readers hear it once.
9
+ */
10
+ live?: boolean;
11
+ }
12
+ type SonnerProps = Omit<ToasterProps, "containerLive"> & ISonnerLiveProps & IDensityProps & IAnalyticsProps;
13
+ declare function Sonner({ analytics, density, className, toastOptions, icons, theme, dir, expand, live, ...props }: SonnerProps): ReactElement;
7
14
  export { Sonner, Sonner as SonnerToaster, Sonner as Toaster };
8
15
  export { toast } from "sonner";
@@ -944,7 +944,7 @@ var Toaster = /* @__PURE__ */ React.forwardRef(function Toaster(props, ref) {
944
944
  const { id, invert, position = "bottom-right", hotkey = [
945
945
  "altKey",
946
946
  "KeyT"
947
- ], expand, closeButton, className, offset, mobileOffset, theme = "light", richColors, duration, style, visibleToasts = VISIBLE_TOASTS_AMOUNT, toastOptions, dir = getDocumentDirection(), gap = GAP, icons, customAriaLabel, containerAriaLabel = "Notifications" } = props;
947
+ ], expand, closeButton, className, offset, mobileOffset, theme = "light", richColors, duration, style, visibleToasts = VISIBLE_TOASTS_AMOUNT, toastOptions, dir = getDocumentDirection(), gap = GAP, icons, customAriaLabel, containerAriaLabel = "Notifications", containerLive = true } = props;
948
948
  const [toasts, setToasts] = React.useState([]);
949
949
  const filteredToasts = React.useMemo(() => {
950
950
  if (id) {
@@ -1097,9 +1097,11 @@ var Toaster = /* @__PURE__ */ React.forwardRef(function Toaster(props, ref) {
1097
1097
  ref,
1098
1098
  "aria-label": customAriaLabel != null ? customAriaLabel : `${containerAriaLabel} ${hotkeyLabel}`,
1099
1099
  tabIndex: -1,
1100
- "aria-live": "polite",
1101
- "aria-relevant": "additions text",
1102
- "aria-atomic": "false",
1100
+ ...containerLive ? {
1101
+ "aria-live": "polite",
1102
+ "aria-relevant": "additions text",
1103
+ "aria-atomic": "false"
1104
+ } : {},
1103
1105
  suppressHydrationWarning: true,
1104
1106
  "data-react-aria-top-layer": true
1105
1107
  }, possiblePositions.map((position, index) => {
@@ -1207,6 +1209,7 @@ function Sonner({
1207
1209
  theme,
1208
1210
  dir,
1209
1211
  expand = true,
1212
+ live = true,
1210
1213
  ...props
1211
1214
  }) {
1212
1215
  const activate = useAnalyticsCallback("Sonner", analytics, { name: "ui.activate" }, undefined);
@@ -1225,6 +1228,7 @@ function Sonner({
1225
1228
  theme: theme ?? resolvedTheme,
1226
1229
  dir: dir ?? inheritedDirection,
1227
1230
  expand,
1231
+ containerLive: live,
1228
1232
  className: cn2("[&[data-sonner-toaster]]:font-mono", "[@media(max-width:600px)]:[&[data-sonner-toaster]]:w-auto!", "[@media(max-width:600px)]:[&[data-sonner-toaster]]:left-[var(--mobile-offset-left)]!", "[@media(max-width:600px)]:[&[data-sonner-toaster]]:right-[var(--mobile-offset-right)]!", "[@media(max-width:600px)]:[&[data-sonner-toaster]_[data-sonner-toast]]:w-full!", className),
1229
1233
  icons: {
1230
1234
  success: /* @__PURE__ */ jsx("span", {
package/dist/index.js CHANGED
@@ -165,7 +165,7 @@ import {
165
165
  StatusTracker2,
166
166
  DashboardLayout2,
167
167
  BillingUsage2
168
- } from "./chunk-es5wc0hy.js";
168
+ } from "./chunk-g4s1f61z.js";
169
169
  import {
170
170
  Combobox2,
171
171
  ComboboxValue2,
@@ -190,7 +190,7 @@ import {
190
190
  NumberFieldIncrement2,
191
191
  NumberFieldScrubArea2,
192
192
  NumberFieldScrubAreaCursor2
193
- } from "./chunk-kmqx7c48.js";
193
+ } from "./chunk-23ppkypt.js";
194
194
  import {
195
195
  Tabs2,
196
196
  tabsListVariants2,
@@ -424,10 +424,10 @@ import {
424
424
  InputGroupText2,
425
425
  InputGroupInput2,
426
426
  InputGroupTextarea2
427
- } from "./chunk-4j3fsft3.js";
427
+ } from "./chunk-mm3a9s11.js";
428
428
  import {
429
429
  Textarea2
430
- } from "./chunk-er6e5fj8.js";
430
+ } from "./chunk-9k5b62qf.js";
431
431
  import {
432
432
  Input2
433
433
  } from "./chunk-7vg045gd.js";
package/dist/prototype.js CHANGED
@@ -2051,7 +2051,7 @@ var program = new Command;
2051
2051
  // package.json
2052
2052
  var package_default = {
2053
2053
  name: "@alexgorbatchev/shadcn",
2054
- version: "0.0.100",
2054
+ version: "0.0.102",
2055
2055
  description: "Sharp, monospace React components with compact and comfortable densities.",
2056
2056
  license: "MIT",
2057
2057
  repository: {
@@ -323,3 +323,26 @@ Storybook CSF excerpts. Default args and render apply unless overridden. Local h
323
323
  }
324
324
  }
325
325
  ```
326
+
327
+ ### AnnouncedByApplication
328
+
329
+ ```tsx
330
+ {
331
+ args: { live: false },
332
+ render: function Render(args) {
333
+ const [announcement, setAnnouncement] = useState("");
334
+ return (<>
335
+ <Sonner {...args}/>
336
+ <div aria-live="polite" data-testid="application-announcer">
337
+ {announcement}
338
+ </div>
339
+ <Button onClick={() => {
340
+ toast("Archived Pricing", { toasterId: args.id, action: { label: "Undo", onClick() { } } });
341
+ setAnnouncement("Archived Pricing. Undo is in Notifications.");
342
+ }}>
343
+ Archive page
344
+ </Button>
345
+ </>);
346
+ }
347
+ }
348
+ ```
@@ -217,3 +217,19 @@ Storybook CSF excerpts. Default args and render apply unless overridden. Local h
217
217
  }
218
218
  }
219
219
  ```
220
+
221
+ ### Bounded
222
+
223
+ ```tsx
224
+ {
225
+ args: { bounded: true, defaultValue: Array.from({ length: 60 }, (_, line) => `Line ${line + 1}`).join("\n") }
226
+ }
227
+ ```
228
+
229
+ ### Unbounded
230
+
231
+ ```tsx
232
+ {
233
+ args: { defaultValue: Array.from({ length: 60 }, (_, line) => `Line ${line + 1}`).join("\n") }
234
+ }
235
+ ```
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alexgorbatchev/shadcn",
3
- "version": "0.0.100",
3
+ "version": "0.0.102",
4
4
  "description": "Sharp, monospace React components with compact and comfortable densities.",
5
5
  "license": "MIT",
6
6
  "repository": {