@alexgorbatchev/shadcn 0.0.127 → 0.0.129

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 (33) hide show
  1. package/dist/{chunk-pvnhmevq.js → chunk-2cfjmyah.js} +1 -1
  2. package/dist/{chunk-5hjkffyw.js → chunk-44btn29f.js} +1 -1
  3. package/dist/{chunk-yt4xp9xa.js → chunk-621hna28.js} +1 -1
  4. package/dist/{chunk-r7krv555.js → chunk-9t68th3s.js} +3 -2
  5. package/dist/{chunk-15n8r9m7.js → chunk-gtvwnr57.js} +1 -1
  6. package/dist/{chunk-4xd8araz.js → chunk-hdfkxx7z.js} +1 -1
  7. package/dist/{chunk-4ddhjtcx.js → chunk-jke6mva4.js} +1 -1
  8. package/dist/{chunk-wk3xn989.js → chunk-k7c5h30v.js} +17 -6
  9. package/dist/{chunk-f7g4cmac.js → chunk-n5q99ynh.js} +1 -1
  10. package/dist/{chunk-92hepa7b.js → chunk-q3tyvvvy.js} +1 -1
  11. package/dist/{chunk-04hj9jyt.js → chunk-q636vy9x.js} +1 -1
  12. package/dist/{chunk-hhvbf7wk.js → chunk-s5by1qxf.js} +1 -1
  13. package/dist/{chunk-w1r741f1.js → chunk-xv9y6a3q.js} +1 -1
  14. package/dist/components/Card.d.ts +8 -2
  15. package/dist/components/assistant-ui/elements/BackgroundInbox.js +2 -2
  16. package/dist/components/assistant-ui/elements/Chart.js +2 -2
  17. package/dist/components/assistant-ui/elements/CodeDiff.js +2 -2
  18. package/dist/components/assistant-ui/elements/DataTable.js +2 -2
  19. package/dist/components/assistant-ui/elements/EditMessage.js +2 -2
  20. package/dist/components/assistant-ui/elements/ElicitationForm.js +2 -2
  21. package/dist/components/assistant-ui/elements/FeedbackDialog.js +2 -2
  22. package/dist/components/assistant-ui/elements/FileTree.js +2 -2
  23. package/dist/components/assistant-ui/elements/FlowGraph.js +2 -2
  24. package/dist/components/assistant-ui/elements/McpServerPanel.js +2 -2
  25. package/dist/components/assistant-ui/elements/ModelPicker.js +2 -2
  26. package/dist/components/assistant-ui/index.js +12 -12
  27. package/dist/components/input-otp/index.js +1 -1
  28. package/dist/components/json-render/index.js +5 -2
  29. package/dist/index.js +2 -2
  30. package/dist/prototype.js +1 -1
  31. package/dist/typeset.css +41 -1
  32. package/llms/components/forms/OptionCardGroup.md +16 -0
  33. package/package.json +1 -1
@@ -10,7 +10,7 @@ import {
10
10
  CardTitle2,
11
11
  CardDescription2,
12
12
  CardContent2
13
- } from "./chunk-r7krv555.js";
13
+ } from "./chunk-9t68th3s.js";
14
14
  import {
15
15
  Collapsible2,
16
16
  CollapsibleTrigger2,
@@ -4,7 +4,7 @@ import {
4
4
  import {
5
5
  Card2,
6
6
  CardContent2
7
- } from "./chunk-r7krv555.js";
7
+ } from "./chunk-9t68th3s.js";
8
8
  import {
9
9
  FieldSet2,
10
10
  FieldLegend2,
@@ -4,7 +4,7 @@ import {
4
4
  CardTitle2,
5
5
  CardDescription2,
6
6
  CardContent2
7
- } from "./chunk-r7krv555.js";
7
+ } from "./chunk-9t68th3s.js";
8
8
  import {
9
9
  cn2
10
10
  } from "./chunk-en44w1pn.js";
@@ -93,11 +93,12 @@ function CardHeader2({ density, className, ...props }) {
93
93
  ...props
94
94
  });
95
95
  }
96
- function CardTitle2({ density, className, ...props }) {
96
+ function CardTitle2({ density, size = "default", className, ...props }) {
97
97
  return /* @__PURE__ */ jsx("div", {
98
98
  "data-density": density,
99
99
  "data-slot": "card-title",
100
- className: cn2("text-base leading-snug font-medium group-data-[size=sm]/card:text-sm", className),
100
+ "data-size": size,
101
+ className: cn2(size === "lg" ? "text-lg leading-snug font-semibold" : "text-base leading-snug font-medium group-data-[size=sm]/card:text-sm", className),
101
102
  ...props
102
103
  });
103
104
  }
@@ -25,7 +25,7 @@ import {
25
25
  CardDescription2,
26
26
  CardContent2,
27
27
  CardFooter2
28
- } from "./chunk-r7krv555.js";
28
+ } from "./chunk-9t68th3s.js";
29
29
  import {
30
30
  Switch2
31
31
  } from "./chunk-m98d89xc.js";
@@ -4,7 +4,7 @@ import {
4
4
  CardTitle2,
5
5
  CardDescription2,
6
6
  CardContent2
7
- } from "./chunk-r7krv555.js";
7
+ } from "./chunk-9t68th3s.js";
8
8
  import {
9
9
  take
10
10
  } from "./chunk-v8ks0cfq.js";
@@ -5,7 +5,7 @@ import {
5
5
  Card2,
6
6
  CardContent2,
7
7
  CardFooter2
8
- } from "./chunk-r7krv555.js";
8
+ } from "./chunk-9t68th3s.js";
9
9
  import {
10
10
  Field2,
11
11
  FieldLabel2
@@ -88,7 +88,7 @@ import {
88
88
  CardDescription2,
89
89
  CardContent2,
90
90
  CardFooter2
91
- } from "./chunk-r7krv555.js";
91
+ } from "./chunk-9t68th3s.js";
92
92
  import {
93
93
  Combobox2,
94
94
  ComboboxValue2,
@@ -515,11 +515,15 @@ function useFold(lines) {
515
515
  const ref = useRef(null);
516
516
  const [isOverflowing, setIsOverflowing] = useState(false);
517
517
  const [isOpen, setIsOpen] = useState(false);
518
+ const [height, setHeight] = useState();
518
519
  useLayoutEffect(() => {
519
520
  const element = ref.current;
520
521
  if (!element || lines === undefined || isOpen)
521
522
  return;
522
- const measure = () => setIsOverflowing(element.scrollHeight > element.clientHeight + 1);
523
+ const measure = () => {
524
+ setHeight(lines * getLineHeight(element));
525
+ setIsOverflowing(element.scrollHeight > element.clientHeight + 1);
526
+ };
523
527
  measure();
524
528
  const observer = new ResizeObserver(measure);
525
529
  observer.observe(element);
@@ -527,11 +531,19 @@ function useFold(lines) {
527
531
  }, [lines, isOpen]);
528
532
  return {
529
533
  ref,
534
+ height,
530
535
  isFoldable: lines !== undefined && (isOverflowing || isOpen),
531
536
  isOpen,
532
537
  toggle: () => setIsOpen((open) => !open)
533
538
  };
534
539
  }
540
+ function getLineHeight(element) {
541
+ const walker = element.ownerDocument.createTreeWalker(element, NodeFilter.SHOW_TEXT, (node) => node.textContent?.trim() ? NodeFilter.FILTER_ACCEPT : NodeFilter.FILTER_SKIP);
542
+ const text = walker.nextNode()?.parentElement ?? element;
543
+ const style = getComputedStyle(text);
544
+ const lineHeight = Number.parseFloat(style.lineHeight);
545
+ return Number.isFinite(lineHeight) ? lineHeight : Number.parseFloat(style.fontSize) * 1.2;
546
+ }
535
547
  function getDescribedBy(ids, props) {
536
548
  return props.description === undefined && props.reason === undefined ? undefined : ids.description;
537
549
  }
@@ -590,7 +602,7 @@ function OptionCardContent({
590
602
  "data-slot": "option-card-description",
591
603
  "data-folded": isFolded || undefined,
592
604
  className: "flex flex-col gap-1 text-muted-foreground wrap-break-word data-folded:overflow-hidden",
593
- style: isFolded ? { maxHeight: `calc(${descriptionLines} * 1lh)` } : undefined,
605
+ style: isFolded ? { maxHeight: fold.height === undefined ? `calc(${descriptionLines} * 1lh)` : fold.height } : undefined,
594
606
  children: [
595
607
  description !== undefined && /* @__PURE__ */ jsx6("span", {
596
608
  className: "block",
@@ -598,13 +610,12 @@ function OptionCardContent({
598
610
  }),
599
611
  reason !== undefined && /* @__PURE__ */ jsxs4("span", {
600
612
  "data-slot": "option-card-reason",
601
- className: "block text-card-foreground",
613
+ className: "flow-root text-card-foreground",
602
614
  children: [
603
615
  /* @__PURE__ */ jsx6("span", {
604
- className: "font-semibold",
616
+ className: "float-start me-1 font-semibold",
605
617
  children: "Why:"
606
618
  }),
607
- " ",
608
619
  reason
609
620
  ]
610
621
  })
@@ -8,7 +8,7 @@ import {
8
8
  CardDescription2,
9
9
  CardContent2,
10
10
  CardFooter2
11
- } from "./chunk-r7krv555.js";
11
+ } from "./chunk-9t68th3s.js";
12
12
  import {
13
13
  Field2,
14
14
  FieldLabel2
@@ -7,7 +7,7 @@ import {
7
7
  CardTitle2,
8
8
  CardDescription2,
9
9
  CardContent2
10
- } from "./chunk-r7krv555.js";
10
+ } from "./chunk-9t68th3s.js";
11
11
  import {
12
12
  codeScroll,
13
13
  codeSurface
@@ -4,7 +4,7 @@ import {
4
4
  import {
5
5
  Card2,
6
6
  CardContent2
7
- } from "./chunk-r7krv555.js";
7
+ } from "./chunk-9t68th3s.js";
8
8
  import {
9
9
  take
10
10
  } from "./chunk-v8ks0cfq.js";
@@ -7,7 +7,7 @@ import {
7
7
  CardTitle2,
8
8
  CardDescription2,
9
9
  CardContent2
10
- } from "./chunk-r7krv555.js";
10
+ } from "./chunk-9t68th3s.js";
11
11
 
12
12
  // src/components/assistant-ui/elements/BackgroundInbox.tsx
13
13
  import { CheckIcon, Loader2Icon, XIcon } from "lucide-react";
@@ -15,7 +15,7 @@ import {
15
15
  } from "./chunk-2sx8m8b2.js";
16
16
  import {
17
17
  Card2
18
- } from "./chunk-r7krv555.js";
18
+ } from "./chunk-9t68th3s.js";
19
19
  import {
20
20
  Table2,
21
21
  TableHeader2,
@@ -10,8 +10,14 @@ type CardProps = ComponentProps<"div"> & VariantProps<typeof cardVariants> & {
10
10
  declare function Card({ density, className, size, variant, ...props }: CardProps): ReactElement;
11
11
  type CardHeaderProps = ComponentProps<"div"> & IDensityProps;
12
12
  declare function CardHeader({ density, className, ...props }: CardHeaderProps): ReactElement;
13
- type CardTitleProps = ComponentProps<"div"> & IDensityProps;
14
- declare function CardTitle({ density, className, ...props }: CardTitleProps): ReactElement;
13
+ type CardTitleProps = ComponentProps<"div"> & IDensityProps & {
14
+ /**
15
+ * `default` titles an app's own card. `lg` is the subheading step, larger and bolder than body text and smaller than
16
+ * a page title, for cards in rendered documents whose title heads the content under it.
17
+ */
18
+ size?: "default" | "lg";
19
+ };
20
+ declare function CardTitle({ density, size, className, ...props }: CardTitleProps): ReactElement;
15
21
  type CardDescriptionProps = ComponentProps<"div"> & IDensityProps;
16
22
  declare function CardDescription({ density, className, ...props }: CardDescriptionProps): ReactElement;
17
23
  type CardActionProps = ComponentProps<"div"> & IDensityProps;
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  BackgroundInbox2
3
- } from "../../../chunk-hhvbf7wk.js";
4
- import"../../../chunk-r7krv555.js";
3
+ } from "../../../chunk-s5by1qxf.js";
4
+ import"../../../chunk-9t68th3s.js";
5
5
  import"../../../chunk-2sx8m8b2.js";
6
6
  import"../../../chunk-x90xmrba.js";
7
7
  import"../../../chunk-jpvw9xqy.js";
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  Chart2
3
- } from "../../../chunk-yt4xp9xa.js";
4
- import"../../../chunk-r7krv555.js";
3
+ } from "../../../chunk-621hna28.js";
4
+ import"../../../chunk-9t68th3s.js";
5
5
  import"../../../chunk-6fvcqd48.js";
6
6
  import"../../../chunk-tcefvfr8.js";
7
7
  import"../../../chunk-jpvw9xqy.js";
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  CodeDiff2
3
- } from "../../../chunk-92hepa7b.js";
4
- import"../../../chunk-r7krv555.js";
3
+ } from "../../../chunk-q3tyvvvy.js";
4
+ import"../../../chunk-9t68th3s.js";
5
5
  import"../../../chunk-en44w1pn.js";
6
6
  export {
7
7
  CodeDiff2 as CodeDiff
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  DataTable2
3
- } from "../../../chunk-w1r741f1.js";
3
+ } from "../../../chunk-xv9y6a3q.js";
4
4
  import"../../../chunk-1wz92wgg.js";
5
5
  import"../../../chunk-qn4a3gg4.js";
6
- import"../../../chunk-r7krv555.js";
6
+ import"../../../chunk-9t68th3s.js";
7
7
  import"../../../chunk-m4geb1s5.js";
8
8
  import"../../../chunk-dbe9ppwf.js";
9
9
  import"../../../chunk-2sx8m8b2.js";
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  EditMessage2
3
- } from "../../../chunk-4ddhjtcx.js";
3
+ } from "../../../chunk-jke6mva4.js";
4
4
  import"../../../chunk-vxvaaptq.js";
5
5
  import"../../../chunk-bfv4qesg.js";
6
- import"../../../chunk-r7krv555.js";
6
+ import"../../../chunk-9t68th3s.js";
7
7
  import"../../../chunk-m32ptxf3.js";
8
8
  import"../../../chunk-9k5b62qf.js";
9
9
  import"../../../chunk-7jpsybag.js";
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  ElicitationForm2
3
- } from "../../../chunk-15n8r9m7.js";
3
+ } from "../../../chunk-gtvwnr57.js";
4
4
  import"../../../chunk-vxvaaptq.js";
5
5
  import"../../../chunk-kgqe8gpb.js";
6
6
  import"../../../chunk-m98d89xc.js";
7
7
  import"../../../chunk-bfv4qesg.js";
8
- import"../../../chunk-r7krv555.js";
8
+ import"../../../chunk-9t68th3s.js";
9
9
  import"../../../chunk-m32ptxf3.js";
10
10
  import"../../../chunk-7vg045gd.js";
11
11
  import"../../../chunk-7jpsybag.js";
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  FeedbackDialog2
3
- } from "../../../chunk-f7g4cmac.js";
3
+ } from "../../../chunk-n5q99ynh.js";
4
4
  import"../../../chunk-32ah7jyp.js";
5
5
  import"../../../chunk-bfv4qesg.js";
6
- import"../../../chunk-r7krv555.js";
6
+ import"../../../chunk-9t68th3s.js";
7
7
  import"../../../chunk-m32ptxf3.js";
8
8
  import"../../../chunk-9k5b62qf.js";
9
9
  import"../../../chunk-7jpsybag.js";
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  FileTree2
3
- } from "../../../chunk-4xd8araz.js";
4
- import"../../../chunk-r7krv555.js";
3
+ } from "../../../chunk-hdfkxx7z.js";
4
+ import"../../../chunk-9t68th3s.js";
5
5
  import"../../../chunk-en44w1pn.js";
6
6
  export {
7
7
  FileTree2 as FileTree
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  FlowGraph2
3
- } from "../../../chunk-04hj9jyt.js";
4
- import"../../../chunk-r7krv555.js";
3
+ } from "../../../chunk-q636vy9x.js";
4
+ import"../../../chunk-9t68th3s.js";
5
5
  import"../../../chunk-en44w1pn.js";
6
6
  export {
7
7
  FlowGraph2 as FlowGraph
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  McpServerPanel2
3
- } from "../../../chunk-pvnhmevq.js";
4
- import"../../../chunk-r7krv555.js";
3
+ } from "../../../chunk-2cfjmyah.js";
4
+ import"../../../chunk-9t68th3s.js";
5
5
  import"../../../chunk-dbe9ppwf.js";
6
6
  import"../../../chunk-fw86vanx.js";
7
7
  import"../../../chunk-2sx8m8b2.js";
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  ModelPicker2
3
- } from "../../../chunk-5hjkffyw.js";
3
+ } from "../../../chunk-44btn29f.js";
4
4
  import"../../../chunk-kgqe8gpb.js";
5
5
  import"../../../chunk-bfv4qesg.js";
6
- import"../../../chunk-r7krv555.js";
6
+ import"../../../chunk-9t68th3s.js";
7
7
  import"../../../chunk-dbe9ppwf.js";
8
8
  import"../../../chunk-m32ptxf3.js";
9
9
  import"../../../chunk-52aadmkc.js";
@@ -39,10 +39,10 @@ import {
39
39
  AudioPlayer2
40
40
  } from "../../chunk-5kj8xadr.js";
41
41
  import"../../chunk-pb8tsrdf.js";
42
- import"../../chunk-r7krv555.js";
42
+ import"../../chunk-9t68th3s.js";
43
43
  import {
44
44
  BackgroundInbox2
45
- } from "../../chunk-hhvbf7wk.js";
45
+ } from "../../chunk-s5by1qxf.js";
46
46
  import {
47
47
  CanvasSplit2,
48
48
  CanvasSplitThread2,
@@ -56,7 +56,7 @@ import"../../chunk-tcefvfr8.js";
56
56
  import"../../chunk-6fvcqd48.js";
57
57
  import {
58
58
  Chart2
59
- } from "../../chunk-yt4xp9xa.js";
59
+ } from "../../chunk-621hna28.js";
60
60
  import"../../chunk-7vg045gd.js";
61
61
  import"../../chunk-9k5b62qf.js";
62
62
  import"../../chunk-remfbhfg.js";
@@ -81,7 +81,7 @@ import {
81
81
  } from "../../chunk-kjx7n6a7.js";
82
82
  import {
83
83
  CodeDiff2
84
- } from "../../chunk-92hepa7b.js";
84
+ } from "../../chunk-q3tyvvvy.js";
85
85
  import {
86
86
  CodeRunner2
87
87
  } from "../../chunk-gn90f4cf.js";
@@ -203,7 +203,7 @@ import"../../chunk-1wz92wgg.js";
203
203
  import"../../chunk-dbe9ppwf.js";
204
204
  import {
205
205
  DataTable2
206
- } from "../../chunk-w1r741f1.js";
206
+ } from "../../chunk-xv9y6a3q.js";
207
207
  import"../../chunk-qn4a3gg4.js";
208
208
  import {
209
209
  DaySeparator2
@@ -229,12 +229,12 @@ import"../../chunk-52aadmkc.js";
229
229
  import"../../chunk-bfv4qesg.js";
230
230
  import {
231
231
  EditMessage2
232
- } from "../../chunk-4ddhjtcx.js";
232
+ } from "../../chunk-jke6mva4.js";
233
233
  import"../../chunk-kgqe8gpb.js";
234
234
  import"../../chunk-m98d89xc.js";
235
235
  import {
236
236
  ElicitationForm2
237
- } from "../../chunk-15n8r9m7.js";
237
+ } from "../../chunk-gtvwnr57.js";
238
238
  import"../../chunk-4e96tpw0.js";
239
239
  import {
240
240
  EmptyState2
@@ -262,7 +262,7 @@ import {
262
262
  import"../../chunk-32ah7jyp.js";
263
263
  import {
264
264
  FeedbackDialog2
265
- } from "../../chunk-f7g4cmac.js";
265
+ } from "../../chunk-n5q99ynh.js";
266
266
  import {
267
267
  FileRoot2,
268
268
  FileIconDisplay2,
@@ -277,10 +277,10 @@ import {
277
277
  } from "../../chunk-wrvxzfdb.js";
278
278
  import {
279
279
  FileTree2
280
- } from "../../chunk-4xd8araz.js";
280
+ } from "../../chunk-hdfkxx7z.js";
281
281
  import {
282
282
  FlowGraph2
283
- } from "../../chunk-04hj9jyt.js";
283
+ } from "../../chunk-q636vy9x.js";
284
284
  import {
285
285
  Frac2
286
286
  } from "../../chunk-4mmxn1c3.js";
@@ -346,7 +346,7 @@ import {
346
346
  } from "../../chunk-0ybqnkcy.js";
347
347
  import {
348
348
  McpServerPanel2
349
- } from "../../chunk-pvnhmevq.js";
349
+ } from "../../chunk-2cfjmyah.js";
350
350
  import {
351
351
  MemoryChips2
352
352
  } from "../../chunk-40jpafh1.js";
@@ -373,7 +373,7 @@ import {
373
373
  } from "../../chunk-hm8rs6a2.js";
374
374
  import {
375
375
  ModelPicker2
376
- } from "../../chunk-5hjkffyw.js";
376
+ } from "../../chunk-44btn29f.js";
377
377
  import"../../chunk-kp3jgjng.js";
378
378
  import {
379
379
  ModelSelectorRoot2
@@ -21,7 +21,7 @@ import {
21
21
  CardDescription2,
22
22
  CardContent2,
23
23
  CardFooter2
24
- } from "../../chunk-r7krv555.js";
24
+ } from "../../chunk-9t68th3s.js";
25
25
  import"../../chunk-m32ptxf3.js";
26
26
  import"../../chunk-52aadmkc.js";
27
27
  import {
@@ -26,7 +26,7 @@ import {
26
26
  PaginationPrevious2,
27
27
  PaginationNext2,
28
28
  PaginationEllipsis2
29
- } from "../../chunk-wk3xn989.js";
29
+ } from "../../chunk-k7c5h30v.js";
30
30
  import {
31
31
  MenuPopup,
32
32
  MenuItem2,
@@ -92,7 +92,7 @@ import {
92
92
  CardTitle2,
93
93
  CardDescription2,
94
94
  CardContent2
95
- } from "../../chunk-r7krv555.js";
95
+ } from "../../chunk-9t68th3s.js";
96
96
  import"../../chunk-remfbhfg.js";
97
97
  import"../../chunk-636bahx2.js";
98
98
  import {
@@ -184,6 +184,9 @@ var JsonCard = ({ props, children }) => {
184
184
  (props.title || props.description) && /* @__PURE__ */ jsxs(CardHeader2, {
185
185
  children: [
186
186
  props.title && /* @__PURE__ */ jsx(CardTitle2, {
187
+ size: "lg",
188
+ role: "heading",
189
+ "aria-level": 2,
187
190
  children: props.title
188
191
  }),
189
192
  props.description && /* @__PURE__ */ jsx(CardDescription2, {
package/dist/index.js CHANGED
@@ -187,7 +187,7 @@ import {
187
187
  StatusTracker2,
188
188
  DashboardLayout2,
189
189
  BillingUsage2
190
- } from "./chunk-wk3xn989.js";
190
+ } from "./chunk-k7c5h30v.js";
191
191
  import {
192
192
  Combobox2,
193
193
  ComboboxValue2,
@@ -347,7 +347,7 @@ import {
347
347
  CardAction2,
348
348
  CardContent2,
349
349
  CardFooter2
350
- } from "./chunk-r7krv555.js";
350
+ } from "./chunk-9t68th3s.js";
351
351
  import {
352
352
  Sheet2,
353
353
  SheetTrigger2,
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.127",
2054
+ version: "0.0.129",
2055
2055
  description: "Sharp, monospace React components with compact and comfortable densities.",
2056
2056
  license: "MIT",
2057
2057
  repository: {
package/dist/typeset.css CHANGED
@@ -374,10 +374,22 @@
374
374
 
375
375
  /* Horizontal scroll for any wide block. Wrap it and the wrapper owns the
376
376
  flow margin. Tables shrink to fit, so widen the table to make it scroll
377
- instead of compress. */
377
+ instead of compress. An edge that hides more content fades out, so the
378
+ box reads as scrollable where an overlay scrollbar stays hidden. The
379
+ fades follow the box's own scroll position on any surface colour; a box
380
+ with nothing to scroll has no timeline and shows no fade. */
378
381
  &:where(.typeset-scroll) {
379
382
  overflow-x: auto;
380
383
  margin-block-start: var(--typeset-flow);
384
+ mask-image: linear-gradient(
385
+ to right,
386
+ transparent,
387
+ #000 var(--typeset-scroll-fade-start),
388
+ #000 calc(100% - var(--typeset-scroll-fade-end)),
389
+ transparent
390
+ );
391
+ animation: typeset-scroll-fade linear both;
392
+ animation-timeline: scroll(self inline);
381
393
  }
382
394
  &:where(.typeset-scroll > *) {
383
395
  margin-block-start: 0;
@@ -454,3 +466,31 @@
454
466
  margin-block-start: 0;
455
467
  }
456
468
  }
469
+
470
+ @property --typeset-scroll-fade-start {
471
+ syntax: "<length>";
472
+ inherits: false;
473
+ initial-value: 0px;
474
+ }
475
+
476
+ @property --typeset-scroll-fade-end {
477
+ syntax: "<length>";
478
+ inherits: false;
479
+ initial-value: 0px;
480
+ }
481
+
482
+ @keyframes typeset-scroll-fade {
483
+ 0% {
484
+ --typeset-scroll-fade-start: 0px;
485
+ --typeset-scroll-fade-end: 2em;
486
+ }
487
+ 10%,
488
+ 90% {
489
+ --typeset-scroll-fade-start: 2em;
490
+ --typeset-scroll-fade-end: 2em;
491
+ }
492
+ 100% {
493
+ --typeset-scroll-fade-start: 2em;
494
+ --typeset-scroll-fade-end: 0px;
495
+ }
496
+ }
@@ -258,3 +258,19 @@ Storybook CSF excerpts. Default args and render apply unless overridden. Local h
258
258
  </div>)
259
259
  }
260
260
  ```
261
+
262
+ ### FoldedProse
263
+
264
+ ```tsx
265
+ {
266
+ render: (args) => (<div className="w-80">
267
+ <OptionCardGroup aria-label="Rollout" {...args}>
268
+ <OptionCard value="blue-green" label="Blue-green" descriptionLines={3} description={<span className="typeset typeset-compact block" data-testid="prose">
269
+ <p>{LONG_TRADE_OFF}</p>
270
+ </span>} recommended reason={<span className="typeset typeset-compact block">
271
+ <p>Payment retries are where a slow rollback costs the most.</p>
272
+ </span>}/>
273
+ </OptionCardGroup>
274
+ </div>)
275
+ }
276
+ ```
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alexgorbatchev/shadcn",
3
- "version": "0.0.127",
3
+ "version": "0.0.129",
4
4
  "description": "Sharp, monospace React components with compact and comfortable densities.",
5
5
  "license": "MIT",
6
6
  "repository": {