@booga/vblocks 0.3.1 → 0.3.3

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 (47) hide show
  1. package/CHANGELOG.md +44 -0
  2. package/dist/blog/index.cjs +8 -8
  3. package/dist/blog/index.cjs.map +1 -1
  4. package/dist/blog/index.js +8 -8
  5. package/dist/blog/index.js.map +1 -1
  6. package/dist/business/index.cjs +1 -1
  7. package/dist/business/index.cjs.map +1 -1
  8. package/dist/business/index.js +1 -1
  9. package/dist/business/index.js.map +1 -1
  10. package/dist/cta/index.cjs +2 -2
  11. package/dist/cta/index.cjs.map +1 -1
  12. package/dist/cta/index.js +2 -2
  13. package/dist/cta/index.js.map +1 -1
  14. package/dist/features/index.cjs +1 -1
  15. package/dist/features/index.cjs.map +1 -1
  16. package/dist/features/index.js +1 -1
  17. package/dist/features/index.js.map +1 -1
  18. package/dist/gallery/index.cjs +1 -1
  19. package/dist/gallery/index.cjs.map +1 -1
  20. package/dist/gallery/index.js +1 -1
  21. package/dist/gallery/index.js.map +1 -1
  22. package/dist/hero/index.cjs +2 -2
  23. package/dist/hero/index.cjs.map +1 -1
  24. package/dist/hero/index.js +2 -2
  25. package/dist/hero/index.js.map +1 -1
  26. package/dist/index.cjs +24 -29
  27. package/dist/index.cjs.map +1 -1
  28. package/dist/index.js +25 -30
  29. package/dist/index.js.map +1 -1
  30. package/dist/portfolio/index.cjs +3 -3
  31. package/dist/portfolio/index.cjs.map +1 -1
  32. package/dist/portfolio/index.js +3 -3
  33. package/dist/portfolio/index.js.map +1 -1
  34. package/dist/post/index.cjs +3 -3
  35. package/dist/post/index.cjs.map +1 -1
  36. package/dist/post/index.js +3 -3
  37. package/dist/post/index.js.map +1 -1
  38. package/dist/styles.css +1 -1
  39. package/dist/team/index.cjs +1 -1
  40. package/dist/team/index.cjs.map +1 -1
  41. package/dist/team/index.js +1 -1
  42. package/dist/team/index.js.map +1 -1
  43. package/dist/testimonial/index.cjs +2 -7
  44. package/dist/testimonial/index.cjs.map +1 -1
  45. package/dist/testimonial/index.js +3 -8
  46. package/dist/testimonial/index.js.map +1 -1
  47. package/package.json +2 -2
package/dist/index.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { Box, Stack, Grid, Inline, cn, Button, Card, CardHeader, CardTitle, CardContent, Separator, Badge, Avatar, AvatarImage, AvatarFallback } from '@booga/vui';
2
2
  import { dsl } from '@booga/vdsl';
3
3
  import { z } from 'zod';
4
- import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
4
+ import { jsx, jsxs } from 'react/jsx-runtime';
5
5
 
6
6
  // src/hero/HeroSplit/index.tsx
7
7
  var DBox = dsl(Box);
@@ -41,7 +41,7 @@ var HeroSplitContentSchema = z.object({
41
41
  function HeroSplit({ content, theme }) {
42
42
  HeroSplitContentSchema.parse(content);
43
43
  const { eyebrow, heading, description, primaryCta, secondaryCta, image } = content;
44
- return /* @__PURE__ */ jsx(DBox, { as: "section", "aria-label": heading, style: themeStyle(theme), children: /* @__PURE__ */ jsxs(DGrid, { columns: 2, px: 6, py: 16, gap: 12, align: "center", className: cn("max-w-6xl mx-auto"), children: [
44
+ return /* @__PURE__ */ jsx(DBox, { as: "section", "aria-label": heading, style: themeStyle(theme), children: /* @__PURE__ */ jsxs(DGrid, { columns: 2, px: 6, py: 24, gap: 12, align: "center", className: cn("max-w-6xl mx-auto"), children: [
45
45
  /* @__PURE__ */ jsxs(DStack, { gap: 6, children: [
46
46
  eyebrow && /* @__PURE__ */ jsx(DBox, { as: "p", color: "accent", className: cn("text-sm font-semibold uppercase tracking-widest"), children: eyebrow }),
47
47
  /* @__PURE__ */ jsx(DBox, { as: "h1", className: cn("text-5xl font-bold tracking-tight leading-tight"), children: heading }),
@@ -84,7 +84,7 @@ function HeroCentered({ content, theme }) {
84
84
  return /* @__PURE__ */ jsx(DBox, { as: "section", "aria-label": heading, style: themeStyle(theme), children: /* @__PURE__ */ jsxs(DStack, { px: 6, py: 24, gap: 8, align: "center", className: cn("max-w-3xl mx-auto text-center"), children: [
85
85
  eyebrow && /* @__PURE__ */ jsx(DBox, { as: "p", color: "accent", className: cn("text-sm font-semibold uppercase tracking-widest"), children: eyebrow }),
86
86
  /* @__PURE__ */ jsx(DBox, { as: "h1", className: cn("text-5xl font-bold tracking-tight leading-tight"), children: heading }),
87
- /* @__PURE__ */ jsx(DBox, { as: "p", color: "muted", className: cn("text-xl"), children: description }),
87
+ /* @__PURE__ */ jsx(DBox, { as: "p", color: "muted", className: cn("text-lg"), children: description }),
88
88
  /* @__PURE__ */ jsxs(DInline, { wrap: true, gap: 3, justify: "center", children: [
89
89
  /* @__PURE__ */ jsx(Button, { as: "a", href: primaryCta.href, children: primaryCta.label }),
90
90
  secondaryCta && /* @__PURE__ */ jsx(Button, { as: "a", href: secondaryCta.href, variant: "outline", children: secondaryCta.label })
@@ -110,7 +110,7 @@ function CtaSplit({ content, theme }) {
110
110
  const { heading, description, primaryCta, image } = content;
111
111
  return /* @__PURE__ */ jsx(DBox, { as: "section", "aria-label": heading, style: themeStyle(theme), children: /* @__PURE__ */ jsxs(DGrid, { columns: 2, px: 6, py: 16, gap: 12, align: "center", className: cn("max-w-6xl mx-auto"), children: [
112
112
  /* @__PURE__ */ jsxs(DStack, { gap: 6, children: [
113
- /* @__PURE__ */ jsx(DBox, { as: "h2", className: cn("text-4xl font-bold tracking-tight"), children: heading }),
113
+ /* @__PURE__ */ jsx(DBox, { as: "h2", className: cn("text-3xl font-bold tracking-tight"), children: heading }),
114
114
  /* @__PURE__ */ jsx(DBox, { as: "p", color: "muted", className: cn("text-lg"), children: description }),
115
115
  /* @__PURE__ */ jsx(Button, { as: "a", href: primaryCta.href, size: "lg", children: primaryCta.label })
116
116
  ] }),
@@ -143,7 +143,7 @@ function CtaCentered({ content, theme }) {
143
143
  CtaCenteredContentSchema.parse(content);
144
144
  const { heading, description, primaryCta, secondaryCta } = content;
145
145
  return /* @__PURE__ */ jsx(DBox, { as: "section", "aria-label": heading, style: themeStyle(theme), children: /* @__PURE__ */ jsxs(DStack, { px: 6, gap: 8, align: "center", className: cn("max-w-2xl mx-auto text-center py-20"), children: [
146
- /* @__PURE__ */ jsx(DBox, { as: "h2", className: cn("text-4xl font-bold tracking-tight"), children: heading }),
146
+ /* @__PURE__ */ jsx(DBox, { as: "h2", className: cn("text-3xl font-bold tracking-tight"), children: heading }),
147
147
  /* @__PURE__ */ jsx(DBox, { as: "p", color: "muted", className: cn("text-lg"), children: description }),
148
148
  /* @__PURE__ */ jsxs(DInline, { wrap: true, gap: 3, justify: "center", children: [
149
149
  /* @__PURE__ */ jsx(Button, { as: "a", href: primaryCta.href, size: "lg", children: primaryCta.label }),
@@ -352,7 +352,7 @@ var GalleryGridContentSchema = z.object({
352
352
  function GalleryGrid({ content, theme }) {
353
353
  GalleryGridContentSchema.parse(content);
354
354
  const { items } = content;
355
- return /* @__PURE__ */ jsx(DBox, { as: "section", "aria-label": "Gallery", style: themeStyle(theme), children: /* @__PURE__ */ jsx(DGrid, { columns: 3, px: 6, py: 12, gap: 4, className: cn("max-w-6xl mx-auto"), children: items.map((item, i) => /* @__PURE__ */ jsxs(DBox, { as: "figure", m: 0, children: [
355
+ return /* @__PURE__ */ jsx(DBox, { as: "section", "aria-label": "Gallery", style: themeStyle(theme), children: /* @__PURE__ */ jsx(DGrid, { columns: 3, px: 6, py: 16, gap: 4, className: cn("max-w-6xl mx-auto"), children: items.map((item, i) => /* @__PURE__ */ jsxs(DBox, { as: "figure", m: 0, children: [
356
356
  /* @__PURE__ */ jsx(
357
357
  DBox,
358
358
  {
@@ -404,7 +404,7 @@ function PortfolioSplit({ content, theme }) {
404
404
  }
405
405
  ),
406
406
  /* @__PURE__ */ jsx(CardContent, { children: /* @__PURE__ */ jsxs(DStack, { gap: 2, pt: 2, children: [
407
- /* @__PURE__ */ jsx(Badge, { variant: "secondary", children: item.category }),
407
+ /* @__PURE__ */ jsx(Badge, { variant: "secondary", className: cn("self-start"), children: item.category }),
408
408
  /* @__PURE__ */ jsx(DBox, { as: "h3", className: cn("font-semibold text-lg"), children: item.title })
409
409
  ] }) })
410
410
  ] }, i)) })
@@ -432,7 +432,7 @@ var PortfolioGridContentSchema = z.object({
432
432
  function PortfolioGrid({ content, theme }) {
433
433
  PortfolioGridContentSchema.parse(content);
434
434
  const { items } = content;
435
- return /* @__PURE__ */ jsx(DBox, { as: "section", "aria-label": "Portfolio", style: themeStyle(theme), children: /* @__PURE__ */ jsx(DGrid, { columns: 2, px: 6, py: 12, gap: 6, className: cn("max-w-6xl mx-auto"), children: items.map((item, i) => /* @__PURE__ */ jsxs(Card, { children: [
435
+ return /* @__PURE__ */ jsx(DBox, { as: "section", "aria-label": "Portfolio", style: themeStyle(theme), children: /* @__PURE__ */ jsx(DGrid, { columns: 2, px: 6, py: 16, gap: 6, className: cn("max-w-6xl mx-auto"), children: items.map((item, i) => /* @__PURE__ */ jsxs(Card, { children: [
436
436
  /* @__PURE__ */ jsx(
437
437
  DBox,
438
438
  {
@@ -443,7 +443,7 @@ function PortfolioGrid({ content, theme }) {
443
443
  }
444
444
  ),
445
445
  /* @__PURE__ */ jsx(CardContent, { children: /* @__PURE__ */ jsxs(DStack, { gap: 2, pt: 2, children: [
446
- /* @__PURE__ */ jsx(Badge, { variant: "secondary", children: item.category }),
446
+ /* @__PURE__ */ jsx(Badge, { variant: "secondary", className: cn("self-start"), children: item.category }),
447
447
  /* @__PURE__ */ jsx(DBox, { as: "h3", className: cn("font-semibold text-lg"), children: item.title })
448
448
  ] }) })
449
449
  ] }, i)) }) });
@@ -471,8 +471,8 @@ function PostSplit({ content, theme }) {
471
471
  const { title, author, date, category, body, image } = content;
472
472
  return /* @__PURE__ */ jsx(DBox, { as: "article", style: themeStyle(theme), children: /* @__PURE__ */ jsxs(DGrid, { columns: 2, px: 6, py: 16, gap: 16, align: "start", className: cn("max-w-6xl mx-auto"), children: [
473
473
  /* @__PURE__ */ jsxs(DStack, { gap: 6, className: cn("sticky top-16"), children: [
474
- category && /* @__PURE__ */ jsx(Badge, { variant: "secondary", children: category }),
475
- /* @__PURE__ */ jsx(DBox, { as: "h1", className: cn("text-3xl font-bold tracking-tight leading-snug"), children: title }),
474
+ category && /* @__PURE__ */ jsx(Badge, { variant: "secondary", className: cn("self-start"), children: category }),
475
+ /* @__PURE__ */ jsx(DBox, { as: "h1", className: cn("text-4xl font-bold tracking-tight leading-snug"), children: title }),
476
476
  /* @__PURE__ */ jsx(Separator, {}),
477
477
  /* @__PURE__ */ jsxs(DInline, { gap: 2, color: "muted", className: cn("text-sm"), children: [
478
478
  /* @__PURE__ */ jsx(DBox, { as: "span", children: author }),
@@ -515,7 +515,7 @@ function PostCentered({ content, theme }) {
515
515
  PostCenteredContentSchema.parse(content);
516
516
  const { title, author, date, category, body } = content;
517
517
  return /* @__PURE__ */ jsx(DBox, { as: "article", style: themeStyle(theme), children: /* @__PURE__ */ jsxs(DStack, { px: 6, py: 16, gap: 6, className: cn("max-w-2xl mx-auto"), children: [
518
- category && /* @__PURE__ */ jsx(Badge, { variant: "secondary", children: category }),
518
+ category && /* @__PURE__ */ jsx(Badge, { variant: "secondary", className: cn("self-start"), children: category }),
519
519
  /* @__PURE__ */ jsx(DBox, { as: "h1", className: cn("text-4xl font-bold tracking-tight leading-snug"), children: title }),
520
520
  /* @__PURE__ */ jsxs(DInline, { gap: 2, color: "muted", className: cn("text-sm"), children: [
521
521
  /* @__PURE__ */ jsx(DBox, { as: "span", children: author }),
@@ -592,7 +592,7 @@ function TeamGrid({ content, theme }) {
592
592
  const { heading, members } = content;
593
593
  return /* @__PURE__ */ jsx(DBox, { as: "section", "aria-label": heading, style: themeStyle(theme), children: /* @__PURE__ */ jsxs(DStack, { px: 6, py: 16, className: cn("max-w-6xl mx-auto gap-10"), children: [
594
594
  /* @__PURE__ */ jsx(DBox, { as: "h2", className: cn("text-3xl font-bold tracking-tight text-center"), children: heading }),
595
- /* @__PURE__ */ jsx(DGrid, { columns: 3, gap: 6, children: members.map((member, i) => /* @__PURE__ */ jsx(Card, { children: /* @__PURE__ */ jsx(CardContent, { children: /* @__PURE__ */ jsxs(DStack, { gap: 3, align: "center", pt: 4, className: cn("text-center"), children: [
595
+ /* @__PURE__ */ jsx(DGrid, { columns: 3, gap: 6, children: members.map((member, i) => /* @__PURE__ */ jsx(Card, { children: /* @__PURE__ */ jsx(CardContent, { children: /* @__PURE__ */ jsxs(DStack, { gap: 4, align: "center", py: 6, className: cn("text-center"), children: [
596
596
  /* @__PURE__ */ jsxs(Avatar, { className: cn("w-16 h-16"), children: [
597
597
  /* @__PURE__ */ jsx(AvatarImage, { src: member.avatar.src, alt: member.avatar.alt }),
598
598
  /* @__PURE__ */ jsx(AvatarFallback, { children: member.name.slice(0, 2).toUpperCase() })
@@ -640,14 +640,9 @@ function TestimonialSplit({ content, theme }) {
640
640
  /* @__PURE__ */ jsx(AvatarImage, { src: avatar.src, alt: avatar.alt }),
641
641
  /* @__PURE__ */ jsx(AvatarFallback, { children: author.slice(0, 2).toUpperCase() })
642
642
  ] }),
643
- /* @__PURE__ */ jsxs(DInline, { gap: 1, color: "muted", className: cn("text-sm"), children: [
643
+ /* @__PURE__ */ jsxs(DInline, { gap: 0, color: "muted", className: cn("text-sm"), children: [
644
644
  /* @__PURE__ */ jsx(DBox, { as: "cite", color: "fg", className: cn("font-semibold not-italic"), children: author }),
645
- /* @__PURE__ */ jsx(DBox, { as: "span", children: "," }),
646
- /* @__PURE__ */ jsx(DBox, { as: "span", children: role }),
647
- company && /* @__PURE__ */ jsxs(Fragment, { children: [
648
- /* @__PURE__ */ jsx(DBox, { as: "span", children: "at" }),
649
- /* @__PURE__ */ jsx(DBox, { as: "span", children: company })
650
- ] })
645
+ /* @__PURE__ */ jsx(DBox, { as: "span", children: `, ${company ? `${role} at ${company}` : role}` })
651
646
  ] })
652
647
  ] })
653
648
  ] }) });
@@ -734,8 +729,8 @@ function BlogSplit({ content, theme }) {
734
729
  }
735
730
  ),
736
731
  /* @__PURE__ */ jsxs(DStack, { gap: 2, children: [
737
- featured.category && /* @__PURE__ */ jsx(Badge, { variant: "secondary", children: featured.category }),
738
- /* @__PURE__ */ jsx(DBox, { as: "h3", className: cn("text-xl font-semibold"), children: featured.title }),
732
+ featured.category && /* @__PURE__ */ jsx(Badge, { variant: "secondary", className: cn("self-start"), children: featured.category }),
733
+ /* @__PURE__ */ jsx(DBox, { as: "h3", className: cn("text-lg font-semibold"), children: featured.title }),
739
734
  /* @__PURE__ */ jsx(DBox, { as: "p", color: "muted", children: featured.excerpt }),
740
735
  /* @__PURE__ */ jsx(DBox, { as: "time", dateTime: featured.date, color: "muted", className: cn("text-xs"), children: featured.date })
741
736
  ] })
@@ -751,8 +746,8 @@ function BlogSplit({ content, theme }) {
751
746
  }
752
747
  ),
753
748
  /* @__PURE__ */ jsxs(DStack, { gap: 1, children: [
754
- post.category && /* @__PURE__ */ jsx(Badge, { variant: "secondary", children: post.category }),
755
- /* @__PURE__ */ jsx(DBox, { as: "h3", className: cn("font-semibold leading-snug"), children: post.title }),
749
+ post.category && /* @__PURE__ */ jsx(Badge, { variant: "secondary", className: cn("self-start"), children: post.category }),
750
+ /* @__PURE__ */ jsx(DBox, { as: "h3", className: cn("text-lg font-semibold leading-snug"), children: post.title }),
756
751
  /* @__PURE__ */ jsx(DBox, { as: "time", dateTime: post.date, color: "muted", className: cn("text-xs"), children: post.date })
757
752
  ] })
758
753
  ] }) }) }, i)) })
@@ -765,7 +760,7 @@ var BlogSplitDefaultContent = {
765
760
  heading: "Latest posts",
766
761
  posts: [
767
762
  { title: "Designing for composability", excerpt: "How modular thinking unlocks maintainable systems at scale.", date: "2026-05-01", category: "Design", image: { src: "https://placehold.co/600x400", alt: "Design systems post" } },
768
- { title: "Type-safe content at runtime", excerpt: "Zod schemas as the single source of truth for block content.", date: "2026-04-18", image: { src: "https://placehold.co/400x280", alt: "Type safety post" } },
763
+ { title: "Type-safe content at runtime", excerpt: "Zod schemas as the single source of truth for block content.", date: "2026-04-18", category: "Engineering", image: { src: "https://placehold.co/400x280", alt: "Type safety post" } },
769
764
  { title: "Tree-shaking section blocks", excerpt: "Per-category entry points and how they keep bundles lean.", date: "2026-04-05", category: "Engineering", image: { src: "https://placehold.co/400x280", alt: "Tree-shaking post" } }
770
765
  ]
771
766
  };
@@ -796,8 +791,8 @@ function BlogGrid({ content, theme }) {
796
791
  }
797
792
  ),
798
793
  /* @__PURE__ */ jsx(CardContent, { children: /* @__PURE__ */ jsxs(DStack, { gap: 2, pt: 2, children: [
799
- post.category && /* @__PURE__ */ jsx(Badge, { variant: "secondary", children: post.category }),
800
- /* @__PURE__ */ jsx(DBox, { as: "h3", className: cn("font-semibold leading-snug"), children: post.title }),
794
+ post.category && /* @__PURE__ */ jsx(Badge, { variant: "secondary", className: cn("self-start"), children: post.category }),
795
+ /* @__PURE__ */ jsx(DBox, { as: "h3", className: cn("text-lg font-semibold leading-snug"), children: post.title }),
801
796
  /* @__PURE__ */ jsx(DBox, { as: "p", color: "muted", className: cn("text-sm"), children: post.excerpt }),
802
797
  /* @__PURE__ */ jsx(DBox, { as: "time", dateTime: post.date, color: "muted", className: cn("text-xs"), children: post.date })
803
798
  ] }) })
@@ -810,7 +805,7 @@ var BlogGridDefaultContent = {
810
805
  heading: "From the blog",
811
806
  posts: [
812
807
  { title: "Designing for composability", excerpt: "Modular thinking at scale.", date: "2026-05-01", category: "Design", image: { src: "https://placehold.co/480x320", alt: "Design post" } },
813
- { title: "Type-safe content at runtime", excerpt: "Zod as single source of truth.", date: "2026-04-18", image: { src: "https://placehold.co/480x320", alt: "Types post" } },
808
+ { title: "Type-safe content at runtime", excerpt: "Zod as single source of truth.", date: "2026-04-18", category: "Engineering", image: { src: "https://placehold.co/480x320", alt: "Types post" } },
814
809
  { title: "Tree-shaking section blocks", excerpt: "Lean bundles, per-category entry points.", date: "2026-04-05", category: "Engineering", image: { src: "https://placehold.co/480x320", alt: "Bundling post" } }
815
810
  ]
816
811
  };
@@ -832,7 +827,7 @@ function BusinessSplit({ content, theme }) {
832
827
  return /* @__PURE__ */ jsx(DBox, { as: "section", "aria-label": name, style: themeStyle(theme), children: /* @__PURE__ */ jsxs(DGrid, { columns: 2, px: 6, py: 16, gap: 16, align: "center", className: cn("max-w-6xl mx-auto"), children: [
833
828
  /* @__PURE__ */ jsxs(DStack, { gap: 6, children: [
834
829
  /* @__PURE__ */ jsxs(DStack, { gap: 2, children: [
835
- /* @__PURE__ */ jsx(DBox, { as: "h2", className: cn("text-4xl font-bold tracking-tight"), children: name }),
830
+ /* @__PURE__ */ jsx(DBox, { as: "h2", className: cn("text-3xl font-bold tracking-tight"), children: name }),
836
831
  /* @__PURE__ */ jsx(DBox, { as: "p", color: "accent", className: cn("text-xl"), children: tagline })
837
832
  ] }),
838
833
  /* @__PURE__ */ jsx(DBox, { as: "p", color: "muted", className: cn("text-lg leading-relaxed"), children: description }),
@@ -917,7 +912,7 @@ function FeaturesSplit({ content, theme }) {
917
912
  /* @__PURE__ */ jsx(DBox, { as: "ul", m: 0, p: 0, gap: 8, display: "flex", className: cn("list-none flex-col"), children: features.map((feature, i) => /* @__PURE__ */ jsx(DBox, { as: "li", children: /* @__PURE__ */ jsxs(DInline, { gap: 4, align: "start", children: [
918
913
  feature.icon && /* @__PURE__ */ jsx(DBox, { as: "span", className: cn("text-xl flex-shrink-0 mt-0.5"), "aria-hidden": "true", children: feature.icon }),
919
914
  /* @__PURE__ */ jsxs(DStack, { gap: 1, children: [
920
- /* @__PURE__ */ jsx(DBox, { as: "h3", className: cn("font-semibold"), children: feature.title }),
915
+ /* @__PURE__ */ jsx(DBox, { as: "h3", className: cn("text-lg font-semibold"), children: feature.title }),
921
916
  /* @__PURE__ */ jsx(DBox, { as: "p", color: "muted", className: cn("text-sm"), children: feature.description })
922
917
  ] })
923
918
  ] }) }, i)) })