@opensite/ui 0.6.3 → 0.6.5

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 (61) hide show
  1. package/dist/about-startup-team.cjs +2 -2
  2. package/dist/about-startup-team.js +2 -2
  3. package/dist/article-breadcrumb-social.cjs +434 -215
  4. package/dist/article-breadcrumb-social.d.cts +19 -1
  5. package/dist/article-breadcrumb-social.d.ts +19 -1
  6. package/dist/article-breadcrumb-social.js +434 -214
  7. package/dist/article-chapters-author.cjs +422 -204
  8. package/dist/article-chapters-author.d.cts +19 -1
  9. package/dist/article-chapters-author.d.ts +19 -1
  10. package/dist/article-chapters-author.js +422 -203
  11. package/dist/article-compact-toc.cjs +429 -73
  12. package/dist/article-compact-toc.d.cts +19 -1
  13. package/dist/article-compact-toc.d.ts +19 -1
  14. package/dist/article-compact-toc.js +430 -73
  15. package/dist/article-hero-prose.cjs +394 -347
  16. package/dist/article-hero-prose.d.cts +19 -1
  17. package/dist/article-hero-prose.d.ts +19 -1
  18. package/dist/article-hero-prose.js +396 -348
  19. package/dist/article-sidebar-sticky.cjs +398 -152
  20. package/dist/article-sidebar-sticky.d.cts +19 -1
  21. package/dist/article-sidebar-sticky.d.ts +19 -1
  22. package/dist/article-sidebar-sticky.js +400 -153
  23. package/dist/article-split-animated.cjs +422 -35
  24. package/dist/article-split-animated.d.cts +19 -1
  25. package/dist/article-split-animated.d.ts +19 -1
  26. package/dist/article-split-animated.js +423 -35
  27. package/dist/article-toc-sidebar.cjs +417 -356
  28. package/dist/article-toc-sidebar.d.cts +19 -1
  29. package/dist/article-toc-sidebar.d.ts +19 -1
  30. package/dist/article-toc-sidebar.js +417 -355
  31. package/dist/blog-cards-read-time.cjs +66 -27
  32. package/dist/blog-cards-read-time.js +66 -27
  33. package/dist/blog-cards-tagline-cta.cjs +64 -14
  34. package/dist/blog-cards-tagline-cta.js +64 -14
  35. package/dist/blog-carousel-apple.cjs +1255 -0
  36. package/dist/blog-carousel-apple.d.cts +113 -0
  37. package/dist/blog-carousel-apple.d.ts +113 -0
  38. package/dist/blog-carousel-apple.js +1234 -0
  39. package/dist/blog-category-overlay.cjs +77 -15
  40. package/dist/blog-category-overlay.js +77 -15
  41. package/dist/blog-featured-popular.cjs +72 -14
  42. package/dist/blog-featured-popular.js +72 -14
  43. package/dist/blog-filtered-results.cjs +122 -39
  44. package/dist/blog-filtered-results.js +122 -39
  45. package/dist/blog-grid-author-cards.cjs +40 -6
  46. package/dist/blog-grid-author-cards.js +40 -6
  47. package/dist/blog-grid-nine-posts.cjs +40 -6
  48. package/dist/blog-grid-nine-posts.js +40 -6
  49. package/dist/blog-horizontal-cards.cjs +34 -6
  50. package/dist/blog-horizontal-cards.js +34 -6
  51. package/dist/blog-horizontal-timeline.cjs +41 -12
  52. package/dist/blog-horizontal-timeline.js +41 -12
  53. package/dist/blog-masonry-featured.cjs +96 -52
  54. package/dist/blog-masonry-featured.js +96 -52
  55. package/dist/blog-related-articles.cjs +47 -9
  56. package/dist/blog-related-articles.js +47 -9
  57. package/dist/blog-tech-insights.cjs +78 -14
  58. package/dist/blog-tech-insights.js +78 -14
  59. package/dist/registry.cjs +1036 -687
  60. package/dist/registry.js +1036 -687
  61. package/package.json +1 -1
@@ -1,5 +1,7 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
  import * as React from 'react';
3
+ import { f as SectionBackground, g as SectionSpacing } from './community-initiatives-31vhKBa1.js';
4
+ import { P as PatternName } from './pattern-background-a7gKHzHy.js';
3
5
  import { a as SocialLinkItem, O as OptixFlowConfig } from './blocks-k17uluAz.js';
4
6
  import 'class-variance-authority';
5
7
  import './button-variants-lRElsmTc.js';
@@ -131,7 +133,23 @@ interface ArticleCompactTocProps {
131
133
  * OptixFlow image optimization configuration
132
134
  */
133
135
  optixFlowConfig?: OptixFlowConfig;
136
+ /**
137
+ * Background style for the section
138
+ */
139
+ background?: SectionBackground;
140
+ /**
141
+ * Vertical spacing for the section
142
+ */
143
+ spacing?: SectionSpacing;
144
+ /**
145
+ * Background pattern
146
+ */
147
+ pattern?: PatternName;
148
+ /**
149
+ * Pattern opacity (0-1)
150
+ */
151
+ patternOpacity?: number;
134
152
  }
135
- declare function ArticleCompactTocComponent({ className, containerClassName, breadcrumbClassName, contentClassName, titleClassName, metaClassName, shareClassName, tocClassName, articleClassName, heroImageClassName, breadcrumbs, breadcrumbsSlot, currentPage, title, authorName, authorHref, publishDate, readTime, sections, tocSlot, renderSectionLink, socialLinks, shareSlot, heroImageSrc, heroImageAlt, heroMediaSlot, children, enableTocTracking, optixFlowConfig, }: ArticleCompactTocProps): react_jsx_runtime.JSX.Element;
153
+ declare function ArticleCompactTocComponent({ className, containerClassName, breadcrumbClassName, contentClassName, titleClassName, metaClassName, shareClassName, tocClassName, articleClassName, heroImageClassName, breadcrumbs, breadcrumbsSlot, currentPage, title, authorName, authorHref, publishDate, readTime, sections, tocSlot, renderSectionLink, socialLinks, shareSlot, heroImageSrc, heroImageAlt, heroMediaSlot, children, enableTocTracking, optixFlowConfig, background, spacing, pattern, patternOpacity, }: ArticleCompactTocProps): react_jsx_runtime.JSX.Element;
136
154
 
137
155
  export { ArticleCompactTocComponent as ArticleCompactToc, type ArticleCompactTocProps, type ArticleCompactTocSection };
@@ -1,10 +1,11 @@
1
1
  "use client";
2
- import * as React4 from 'react';
2
+ import * as React6 from 'react';
3
+ import React6__default from 'react';
3
4
  import { clsx } from 'clsx';
4
5
  import { twMerge } from 'tailwind-merge';
5
6
  import { Img } from '@page-speed/img';
6
7
  import { cva } from 'class-variance-authority';
7
- import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
8
+ import { jsx, jsxs } from 'react/jsx-runtime';
8
9
  import { Slot } from '@radix-ui/react-slot';
9
10
  import * as SeparatorPrimitive from '@radix-ui/react-separator';
10
11
 
@@ -87,7 +88,7 @@ function useNavigation({
87
88
  href,
88
89
  onClick
89
90
  } = {}) {
90
- const linkType = React4.useMemo(() => {
91
+ const linkType = React6.useMemo(() => {
91
92
  if (!href || href.trim() === "") {
92
93
  return onClick ? "none" : "none";
93
94
  }
@@ -108,7 +109,7 @@ function useNavigation({
108
109
  return "internal";
109
110
  }
110
111
  }, [href, onClick]);
111
- const normalizedHref = React4.useMemo(() => {
112
+ const normalizedHref = React6.useMemo(() => {
112
113
  if (!href || href.trim() === "") {
113
114
  return void 0;
114
115
  }
@@ -126,7 +127,7 @@ function useNavigation({
126
127
  return trimmed;
127
128
  }
128
129
  }, [href, linkType]);
129
- const target = React4.useMemo(() => {
130
+ const target = React6.useMemo(() => {
130
131
  switch (linkType) {
131
132
  case "external":
132
133
  return "_blank";
@@ -139,7 +140,7 @@ function useNavigation({
139
140
  return void 0;
140
141
  }
141
142
  }, [linkType]);
142
- const rel = React4.useMemo(() => {
143
+ const rel = React6.useMemo(() => {
143
144
  if (linkType === "external") {
144
145
  return "noopener noreferrer";
145
146
  }
@@ -148,7 +149,7 @@ function useNavigation({
148
149
  const isExternal = linkType === "external";
149
150
  const isInternal = linkType === "internal";
150
151
  const shouldUseRouter = isInternal && typeof normalizedHref === "string" && normalizedHref.startsWith("/");
151
- const handleClick = React4.useCallback(
152
+ const handleClick = React6.useCallback(
152
153
  (event) => {
153
154
  if (onClick) {
154
155
  try {
@@ -332,7 +333,7 @@ var buttonVariants = cva(baseStyles, {
332
333
  size: "default"
333
334
  }
334
335
  });
335
- var Pressable = React4.forwardRef(
336
+ var Pressable = React6.forwardRef(
336
337
  ({
337
338
  children,
338
339
  className,
@@ -438,10 +439,10 @@ function DynamicIcon({
438
439
  className,
439
440
  alt
440
441
  }) {
441
- const [svgContent, setSvgContent] = React4.useState(null);
442
- const [isLoading, setIsLoading] = React4.useState(true);
443
- const [error, setError] = React4.useState(null);
444
- const { url, iconName } = React4.useMemo(() => {
442
+ const [svgContent, setSvgContent] = React6.useState(null);
443
+ const [isLoading, setIsLoading] = React6.useState(true);
444
+ const [error, setError] = React6.useState(null);
445
+ const { url, iconName } = React6.useMemo(() => {
445
446
  const separator = name.includes("/") ? "/" : ":";
446
447
  const [prefix, iconName2] = name.split(separator);
447
448
  const baseUrl = `https://icons.opensite.ai/api/icon/${prefix}/${iconName2}?format=svg&width=${size}&height=${size}`;
@@ -450,7 +451,7 @@ function DynamicIcon({
450
451
  iconName: iconName2
451
452
  };
452
453
  }, [name, size]);
453
- React4.useEffect(() => {
454
+ React6.useEffect(() => {
454
455
  let isMounted = true;
455
456
  const fetchSvg = async () => {
456
457
  const cached = svgCache.get(url);
@@ -626,37 +627,379 @@ function Separator({
626
627
  }
627
628
  );
628
629
  }
629
- var defaultArticleContent = () => /* @__PURE__ */ jsxs(Fragment, { children: [
630
- /* @__PURE__ */ jsxs("section", { id: "introduction", children: [
631
- /* @__PURE__ */ jsx("h2", { children: "Introduction" }),
632
- /* @__PURE__ */ jsx("p", { children: "Understanding user behavior is fundamental to creating effective web applications. This study examines patterns in user interaction and provides insights for improving user experience." }),
633
- /* @__PURE__ */ jsx("p", { children: "Our research focuses on identifying key factors that influence user engagement and satisfaction in modern web applications." })
634
- ] }),
635
- /* @__PURE__ */ jsxs("section", { id: "methodology", children: [
636
- /* @__PURE__ */ jsx("h2", { children: "Methodology" }),
637
- /* @__PURE__ */ jsx("p", { children: "We employed a mixed-methods approach combining quantitative analytics with qualitative user interviews. Data was collected from over 10,000 users across diverse demographics." }),
638
- /* @__PURE__ */ jsx("p", { children: "Statistical analysis was performed using industry-standard tools to ensure reliability and validity of our findings." })
639
- ] }),
640
- /* @__PURE__ */ jsxs("section", { id: "results", children: [
641
- /* @__PURE__ */ jsx("h2", { children: "Results" }),
642
- /* @__PURE__ */ jsx("p", { children: "Our findings reveal several key patterns in user behavior:" }),
643
- /* @__PURE__ */ jsxs("ul", { children: [
644
- /* @__PURE__ */ jsx("li", { children: "Users prefer intuitive navigation over complex menus" }),
645
- /* @__PURE__ */ jsx("li", { children: "Page load time significantly impacts engagement" }),
646
- /* @__PURE__ */ jsx("li", { children: "Mobile-first design improves overall satisfaction" }),
647
- /* @__PURE__ */ jsx("li", { children: "Clear calls-to-action increase conversion rates" })
648
- ] })
649
- ] }),
650
- /* @__PURE__ */ jsxs("section", { id: "discussion", children: [
651
- /* @__PURE__ */ jsx("h2", { children: "Discussion" }),
652
- /* @__PURE__ */ jsx("p", { children: "These results align with existing literature while providing new insights into emerging user expectations. The implications for web development practices are significant." }),
653
- /* @__PURE__ */ jsx("blockquote", { children: "\u201CUser experience is not just about usability\u2014it's about creating meaningful interactions that resonate with users.\u201D" })
654
- ] }),
655
- /* @__PURE__ */ jsxs("section", { id: "conclusion", children: [
656
- /* @__PURE__ */ jsx("h2", { children: "Conclusion" }),
657
- /* @__PURE__ */ jsx("p", { children: "This study provides actionable insights for developers and designers seeking to improve user experience. Future research should explore the impact of emerging technologies on user behavior patterns." })
658
- ] })
659
- ] });
630
+ var maxWidthStyles = {
631
+ sm: "max-w-screen-sm",
632
+ md: "max-w-screen-md",
633
+ lg: "max-w-screen-lg",
634
+ xl: "max-w-7xl",
635
+ "2xl": "max-w-screen-2xl",
636
+ "4xl": "max-w-[1536px]",
637
+ full: "max-w-full"
638
+ };
639
+ var Container = React6__default.forwardRef(
640
+ ({ children, maxWidth = "xl", className, as = "div", ...props }, ref) => {
641
+ const Component = as;
642
+ return /* @__PURE__ */ jsx(
643
+ Component,
644
+ {
645
+ ref,
646
+ className: cn(
647
+ "mx-auto w-full px-2 sm:px-4 lg:px-8",
648
+ maxWidthStyles[maxWidth],
649
+ className
650
+ ),
651
+ ...props,
652
+ children
653
+ }
654
+ );
655
+ }
656
+ );
657
+ Container.displayName = "Container";
658
+
659
+ // lib/patternSvgs.ts
660
+ var patternSvgs = {
661
+ squareAltGrid: "https://cdn.ing/assets/files/record/286187/4gpn0yq2ptra8iwlvmwwv860ggwv",
662
+ grid1: "https://cdn.ing/assets/files/record/286186/nbdflpgp4ostrno079hygibsflp3",
663
+ noise: "https://cdn.ing/assets/i/r/286188/zrqcp9hynh3j7p2laihwzfbujgrl/noise.png",
664
+ dots: "https://cdn.ing/assets/files/record/286198/yfsjx9thvtxzhl2qtshxyhkrm524",
665
+ dotPattern: "https://cdn.ing/assets/files/record/286192/7ig0cku8aqbboiza8nuk6hw0nnsr",
666
+ dotPattern2: "https://cdn.ing/assets/files/record/286189/arez6gd2s7isn9i1o6c7sexdq7bl",
667
+ circles: "https://cdn.ing/assets/files/record/286190/gtmia3sncjtzetdshc20zf1d3c17",
668
+ waves: "https://cdn.ing/assets/files/record/286191/mqlb33fzxz9cdth1bx7if0wmpkp1",
669
+ crossPattern: "https://cdn.ing/assets/files/record/286193/9yfqwdbnqaipbp7fsb3wbzzmq472",
670
+ architect: "https://cdn.ing/assets/files/record/286194/vgs88ugpvyhxu13wqgy0acvae6re",
671
+ tinyCheckers: "https://cdn.ing/assets/files/record/286195/65efaknsw8kcpf9o3c2gybytsl5b",
672
+ p6: "https://cdn.ing/assets/i/r/286196/6kl0rqnd6mjk8j7e525fo8fo0vkc/p6.webp"
673
+ };
674
+ var maskTop = "radial-gradient(ellipse 70% 60% at 50% 0%, #000 60%, transparent 100%)";
675
+ var maskBottom = "radial-gradient(ellipse 100% 80% at 50% 100%, #000 50%, transparent 90%)";
676
+ var maskCenter = "radial-gradient(ellipse 60% 60% at 50% 50%, #000 30%, transparent 70%)";
677
+ var maskTopLeft = "radial-gradient(ellipse 80% 80% at 0% 0%, #000 50%, transparent 90%)";
678
+ var maskTopRight = "radial-gradient(ellipse 80% 80% at 100% 0%, #000 50%, transparent 90%)";
679
+ var maskBottomLeft = "radial-gradient(ellipse 80% 80% at 0% 100%, #000 50%, transparent 90%)";
680
+ var maskBottomRight = "radial-gradient(ellipse 80% 80% at 100% 100%, #000 50%, transparent 90%)";
681
+ var circuitBoardPattern = (id, mask) => /* @__PURE__ */ jsxs(
682
+ "svg",
683
+ {
684
+ className: "h-full w-full",
685
+ xmlns: "http://www.w3.org/2000/svg",
686
+ style: mask ? {
687
+ maskImage: mask,
688
+ WebkitMaskImage: mask
689
+ } : void 0,
690
+ children: [
691
+ /* @__PURE__ */ jsx("defs", { children: /* @__PURE__ */ jsxs(
692
+ "pattern",
693
+ {
694
+ id,
695
+ x: "0",
696
+ y: "0",
697
+ width: "100",
698
+ height: "100",
699
+ patternUnits: "userSpaceOnUse",
700
+ children: [
701
+ /* @__PURE__ */ jsx(
702
+ "path",
703
+ {
704
+ d: "M0 50h40M60 50h40M50 0v40M50 60v40",
705
+ stroke: "hsl(var(--muted))",
706
+ strokeWidth: "1",
707
+ fill: "none"
708
+ }
709
+ ),
710
+ /* @__PURE__ */ jsx("circle", { cx: "50", cy: "50", r: "3", fill: "hsl(var(--muted))" }),
711
+ /* @__PURE__ */ jsx("circle", { cx: "0", cy: "50", r: "2", fill: "hsl(var(--muted))" }),
712
+ /* @__PURE__ */ jsx("circle", { cx: "100", cy: "50", r: "2", fill: "hsl(var(--muted))" }),
713
+ /* @__PURE__ */ jsx("circle", { cx: "50", cy: "0", r: "2", fill: "hsl(var(--muted))" }),
714
+ /* @__PURE__ */ jsx("circle", { cx: "50", cy: "100", r: "2", fill: "hsl(var(--muted))" })
715
+ ]
716
+ }
717
+ ) }),
718
+ /* @__PURE__ */ jsx("rect", { width: "100%", height: "100%", fill: `url(#${id})` })
719
+ ]
720
+ }
721
+ );
722
+ var gridDotsPattern = (id, mask) => /* @__PURE__ */ jsxs(
723
+ "svg",
724
+ {
725
+ className: "h-full w-full",
726
+ xmlns: "http://www.w3.org/2000/svg",
727
+ style: mask ? {
728
+ maskImage: mask,
729
+ WebkitMaskImage: mask
730
+ } : void 0,
731
+ children: [
732
+ /* @__PURE__ */ jsx("defs", { children: /* @__PURE__ */ jsxs(
733
+ "pattern",
734
+ {
735
+ id,
736
+ x: "0",
737
+ y: "0",
738
+ width: "40",
739
+ height: "40",
740
+ patternUnits: "userSpaceOnUse",
741
+ children: [
742
+ /* @__PURE__ */ jsx(
743
+ "path",
744
+ {
745
+ d: "M0 20h40M20 0v40",
746
+ stroke: "hsl(var(--muted))",
747
+ strokeWidth: "0.5",
748
+ fill: "none"
749
+ }
750
+ ),
751
+ /* @__PURE__ */ jsx("circle", { cx: "20", cy: "20", r: "2", fill: "hsl(var(--muted))" })
752
+ ]
753
+ }
754
+ ) }),
755
+ /* @__PURE__ */ jsx("rect", { width: "100%", height: "100%", fill: `url(#${id})` })
756
+ ]
757
+ }
758
+ );
759
+ var gridPattern = (size, mask) => /* @__PURE__ */ jsx(
760
+ "div",
761
+ {
762
+ className: "h-full w-full bg-[linear-gradient(to_right,_hsl(var(--muted))_1px,_transparent_1px),linear-gradient(to_bottom,_hsl(var(--muted))_1px,_transparent_1px)]",
763
+ style: {
764
+ backgroundSize: `${size}px ${size}px`,
765
+ ...mask ? {
766
+ maskImage: mask,
767
+ WebkitMaskImage: mask
768
+ } : {}
769
+ }
770
+ }
771
+ );
772
+ var diagonalCrossPattern = (mask) => /* @__PURE__ */ jsx(
773
+ "div",
774
+ {
775
+ className: "h-full w-full",
776
+ style: {
777
+ backgroundImage: "repeating-linear-gradient(45deg, transparent, transparent 32px, hsl(var(--muted)) 32px, hsl(var(--muted)) 33px), repeating-linear-gradient(135deg, transparent, transparent 32px, hsl(var(--muted)) 32px, hsl(var(--muted)) 33px)",
778
+ ...mask ? {
779
+ maskImage: mask,
780
+ WebkitMaskImage: mask
781
+ } : {}
782
+ }
783
+ }
784
+ );
785
+ var dashedGridMaskBase = "repeating-linear-gradient(to right, black 0px, black 3px, transparent 3px, transparent 8px), repeating-linear-gradient(to bottom, black 0px, black 3px, transparent 3px, transparent 8px)";
786
+ var dashedGridPattern = (fadeMask) => {
787
+ const mask = fadeMask ? `${dashedGridMaskBase}, ${fadeMask}` : dashedGridMaskBase;
788
+ return /* @__PURE__ */ jsx(
789
+ "div",
790
+ {
791
+ className: "h-full w-full",
792
+ style: {
793
+ backgroundImage: "linear-gradient(to right, hsl(var(--muted)) 1px, transparent 1px), linear-gradient(to bottom, hsl(var(--muted)) 1px, transparent 1px)",
794
+ backgroundSize: "20px 20px",
795
+ backgroundPosition: "0 0, 0 0",
796
+ maskImage: mask,
797
+ WebkitMaskImage: mask,
798
+ maskComposite: "intersect",
799
+ WebkitMaskComposite: "source-in"
800
+ }
801
+ }
802
+ );
803
+ };
804
+ var gradientGlow = (position) => /* @__PURE__ */ jsx(
805
+ "div",
806
+ {
807
+ className: cn(
808
+ "pointer-events-none absolute left-1/2 z-0 aspect-square w-3/4 -translate-x-1/2 rounded-full opacity-50 blur-3xl",
809
+ position === "top" ? "-top-1/4" : "-bottom-1/4"
810
+ ),
811
+ style: {
812
+ background: "radial-gradient(circle, hsl(var(--primary)) 0%, transparent 70%)"
813
+ }
814
+ }
815
+ );
816
+ var spotlight = (position) => /* @__PURE__ */ jsx(
817
+ "div",
818
+ {
819
+ className: cn(
820
+ "pointer-events-none absolute top-1/2 z-0 aspect-square w-3/4 -translate-y-1/2 rounded-full opacity-40 blur-3xl",
821
+ position === "left" ? "-left-1/4" : "-right-1/4"
822
+ ),
823
+ style: {
824
+ background: "radial-gradient(circle, hsl(var(--primary)) 0%, transparent 70%)"
825
+ }
826
+ }
827
+ );
828
+ var patternOverlays = {
829
+ circuitBoardBasic: () => circuitBoardPattern("circuit-board-basic"),
830
+ circuitBoardFadeTop: () => circuitBoardPattern("circuit-board-fade-top", maskTop),
831
+ circuitBoardFadeBottom: () => circuitBoardPattern("circuit-board-fade-bottom", maskBottom),
832
+ circuitBoardFadeCenter: () => circuitBoardPattern("circuit-board-fade-center", maskCenter),
833
+ circuitBoardFadeTopLeft: () => circuitBoardPattern("circuit-board-fade-top-left", maskTopLeft),
834
+ circuitBoardFadeTopRight: () => circuitBoardPattern("circuit-board-fade-top-right", maskTopRight),
835
+ circuitBoardFadeBottomLeft: () => circuitBoardPattern("circuit-board-fade-bottom-left", maskBottomLeft),
836
+ circuitBoardFadeBottomRight: () => circuitBoardPattern("circuit-board-fade-bottom-right", maskBottomRight),
837
+ dashedGridBasic: () => dashedGridPattern(),
838
+ dashedGridFadeTop: () => dashedGridPattern(maskTop),
839
+ dashedGridFadeBottom: () => dashedGridPattern(maskBottom),
840
+ dashedGridFadeCenter: () => dashedGridPattern(maskCenter),
841
+ dashedGridFadeTopLeft: () => dashedGridPattern(maskTopLeft),
842
+ dashedGridFadeTopRight: () => dashedGridPattern(maskTopRight),
843
+ dashedGridFadeBottomLeft: () => dashedGridPattern(maskBottomLeft),
844
+ dashedGridFadeBottomRight: () => dashedGridPattern(maskBottomRight),
845
+ diagonalCrossBasic: () => diagonalCrossPattern(),
846
+ diagonalCrossFadeTop: () => diagonalCrossPattern(maskTop),
847
+ diagonalCrossFadeBottom: () => diagonalCrossPattern(maskBottom),
848
+ diagonalCrossFadeCenter: () => diagonalCrossPattern(maskCenter),
849
+ diagonalCrossFadeTopLeft: () => diagonalCrossPattern(maskTopLeft),
850
+ diagonalCrossFadeTopRight: () => diagonalCrossPattern(maskTopRight),
851
+ diagonalCrossFadeBottomLeft: () => diagonalCrossPattern(maskBottomLeft),
852
+ diagonalCrossFadeBottomRight: () => diagonalCrossPattern(maskBottomRight),
853
+ gridBasic: () => gridPattern(40),
854
+ gridFadeTop: () => gridPattern(32, maskTop),
855
+ gridFadeBottom: () => gridPattern(32, maskBottom),
856
+ gridFadeCenter: () => gridPattern(40, maskCenter),
857
+ gridFadeTopLeft: () => gridPattern(32, maskTopLeft),
858
+ gridFadeTopRight: () => gridPattern(32, maskTopRight),
859
+ gridFadeBottomLeft: () => gridPattern(32, maskBottomLeft),
860
+ gridFadeBottomRight: () => gridPattern(32, maskBottomRight),
861
+ gridDotsBasic: () => gridDotsPattern("grid-dots-basic"),
862
+ gridDotsFadeCenter: () => gridDotsPattern("grid-dots-fade-center", maskCenter),
863
+ gradientGlowTop: () => gradientGlow("top"),
864
+ gradientGlowBottom: () => gradientGlow("bottom"),
865
+ spotlightLeft: () => spotlight("left"),
866
+ spotlightRight: () => spotlight("right")
867
+ };
868
+ var inlinePatternStyles = {
869
+ radialGradientTop: {
870
+ background: "radial-gradient(125% 125% at 50% 10%, hsl(var(--background)) 40%, hsl(var(--primary)) 100%)"
871
+ },
872
+ radialGradientBottom: {
873
+ background: "radial-gradient(125% 125% at 50% 90%, hsl(var(--background)) 40%, hsl(var(--primary)) 100%)"
874
+ }
875
+ };
876
+ function PatternBackground({
877
+ pattern,
878
+ opacity = 0.08,
879
+ className,
880
+ style
881
+ }) {
882
+ if (!pattern) {
883
+ return null;
884
+ }
885
+ if (pattern in inlinePatternStyles) {
886
+ const inlineStyle = inlinePatternStyles[pattern];
887
+ return /* @__PURE__ */ jsx(
888
+ "div",
889
+ {
890
+ className: cn("pointer-events-none absolute inset-0 z-0", className),
891
+ style: { ...inlineStyle, opacity, ...style },
892
+ "aria-hidden": "true"
893
+ }
894
+ );
895
+ }
896
+ if (pattern in patternOverlays) {
897
+ const Overlay = patternOverlays[pattern];
898
+ return /* @__PURE__ */ jsx(
899
+ "div",
900
+ {
901
+ className: cn("pointer-events-none absolute inset-0 z-0", className),
902
+ style: { opacity, ...style },
903
+ "aria-hidden": "true",
904
+ children: Overlay()
905
+ }
906
+ );
907
+ }
908
+ const patternUrl = pattern in patternSvgs ? patternSvgs[pattern] : pattern;
909
+ return /* @__PURE__ */ jsx(
910
+ "div",
911
+ {
912
+ className: cn("pointer-events-none absolute inset-0 z-0", className),
913
+ style: {
914
+ backgroundImage: `url(${patternUrl})`,
915
+ backgroundRepeat: "repeat",
916
+ backgroundSize: "auto",
917
+ opacity,
918
+ ...style
919
+ },
920
+ "aria-hidden": "true"
921
+ }
922
+ );
923
+ }
924
+ var backgroundStyles = {
925
+ default: "bg-background text-foreground",
926
+ white: "bg-white text-dark",
927
+ gray: "bg-muted/30 text-foreground",
928
+ dark: "bg-foreground text-background",
929
+ transparent: "bg-transparent text-foreground",
930
+ gradient: "bg-linear-to-br from-primary via-primary/90 to-foreground text-primary-foreground",
931
+ primary: "bg-primary text-primary-foreground",
932
+ secondary: "bg-secondary text-secondary-foreground",
933
+ muted: "bg-muted text-muted-foreground"
934
+ };
935
+ var spacingStyles = {
936
+ none: "py-0 md:py-0",
937
+ sm: "py-12 md:py-16",
938
+ md: "py-16 md:py-24",
939
+ lg: "py-20 md:py-32",
940
+ xl: "py-24 md:py-40"
941
+ };
942
+ var Section = React6__default.forwardRef(
943
+ ({
944
+ id,
945
+ title,
946
+ subtitle,
947
+ children,
948
+ className,
949
+ style,
950
+ background = "default",
951
+ spacing = "lg",
952
+ pattern,
953
+ patternOpacity,
954
+ patternClassName,
955
+ containerClassName,
956
+ containerMaxWidth = "xl",
957
+ ...props
958
+ }, ref) => {
959
+ const effectivePatternOpacity = patternOpacity !== void 0 ? patternOpacity : pattern ? 1 : 0;
960
+ return /* @__PURE__ */ jsxs(
961
+ "section",
962
+ {
963
+ ref,
964
+ id,
965
+ className: cn(
966
+ "relative",
967
+ pattern ? "overflow-hidden" : null,
968
+ backgroundStyles[background],
969
+ spacingStyles[spacing],
970
+ className
971
+ ),
972
+ style,
973
+ ...props,
974
+ children: [
975
+ /* @__PURE__ */ jsx(
976
+ PatternBackground,
977
+ {
978
+ pattern,
979
+ opacity: effectivePatternOpacity,
980
+ className: patternClassName
981
+ }
982
+ ),
983
+ /* @__PURE__ */ jsxs(
984
+ Container,
985
+ {
986
+ maxWidth: containerMaxWidth,
987
+ className: cn("relative z-10", containerClassName),
988
+ children: [
989
+ (title || subtitle) && /* @__PURE__ */ jsxs("div", { className: "mb-12 text-center md:mb-16", children: [
990
+ subtitle && /* @__PURE__ */ jsx("p", { className: "mb-2 text-sm font-semibold uppercase tracking-wider text-primary", children: subtitle }),
991
+ title && /* @__PURE__ */ jsx("h2", { className: "text-3xl font-bold tracking-tight md:text-4xl lg:text-5xl", children: title })
992
+ ] }),
993
+ children
994
+ ]
995
+ }
996
+ )
997
+ ]
998
+ }
999
+ );
1000
+ }
1001
+ );
1002
+ Section.displayName = "Section";
660
1003
  function ArticleCompactTocComponent({
661
1004
  className,
662
1005
  containerClassName,
@@ -686,13 +1029,17 @@ function ArticleCompactTocComponent({
686
1029
  heroMediaSlot,
687
1030
  children,
688
1031
  enableTocTracking = true,
689
- optixFlowConfig
1032
+ optixFlowConfig,
1033
+ background,
1034
+ spacing,
1035
+ pattern,
1036
+ patternOpacity
690
1037
  }) {
691
- const [activeSection, setActiveSection] = React4.useState(
1038
+ const [activeSection, setActiveSection] = React6.useState(
692
1039
  sections?.[0]?.id || ""
693
1040
  );
694
- const [isTocOpen, setIsTocOpen] = React4.useState(false);
695
- React4.useEffect(() => {
1041
+ const [isTocOpen, setIsTocOpen] = React6.useState(false);
1042
+ React6.useEffect(() => {
696
1043
  if (!enableTocTracking) return;
697
1044
  const observer = new IntersectionObserver(
698
1045
  (entries) => {
@@ -710,12 +1057,12 @@ function ArticleCompactTocComponent({
710
1057
  });
711
1058
  return () => observer.disconnect();
712
1059
  }, [sections, enableTocTracking]);
713
- const breadcrumbsContent = React4.useMemo(() => {
1060
+ const breadcrumbsContent = React6.useMemo(() => {
714
1061
  if (breadcrumbsSlot) return breadcrumbsSlot;
715
1062
  if (!breadcrumbs && !currentPage) return null;
716
1063
  return /* @__PURE__ */ jsx(Breadcrumb, { className: cn("mb-6", breadcrumbClassName), children: /* @__PURE__ */ jsxs(BreadcrumbList, { children: [
717
1064
  /* @__PURE__ */ jsx(BreadcrumbItem, { children: /* @__PURE__ */ jsx(BreadcrumbLink, { asChild: true, children: /* @__PURE__ */ jsx(Pressable, { href: "#", children: /* @__PURE__ */ jsx(DynamicIcon, { name: "lucide/home", size: 16 }) }) }) }),
718
- breadcrumbs?.map((crumb, index) => /* @__PURE__ */ jsxs(React4.Fragment, { children: [
1065
+ breadcrumbs?.map((crumb, index) => /* @__PURE__ */ jsxs(React6.Fragment, { children: [
719
1066
  /* @__PURE__ */ jsx(BreadcrumbSeparator, {}),
720
1067
  /* @__PURE__ */ jsx(BreadcrumbItem, { children: /* @__PURE__ */ jsx(BreadcrumbLink, { asChild: true, children: /* @__PURE__ */ jsx(Pressable, { href: crumb.href, children: crumb.label }) }) })
721
1068
  ] }, index)),
@@ -723,7 +1070,7 @@ function ArticleCompactTocComponent({
723
1070
  /* @__PURE__ */ jsx(BreadcrumbItem, { children: /* @__PURE__ */ jsx(BreadcrumbPage, { children: currentPage }) })
724
1071
  ] }) });
725
1072
  }, [breadcrumbsSlot, breadcrumbs, currentPage, breadcrumbClassName]);
726
- const shareContent = React4.useMemo(() => {
1073
+ const shareContent = React6.useMemo(() => {
727
1074
  if (shareSlot) return shareSlot;
728
1075
  if (!socialLinks || socialLinks.length === 0) return null;
729
1076
  return /* @__PURE__ */ jsxs("div", { className: cn("mt-6 flex items-center gap-2", shareClassName), children: [
@@ -740,7 +1087,7 @@ function ArticleCompactTocComponent({
740
1087
  ))
741
1088
  ] });
742
1089
  }, [shareSlot, socialLinks, shareClassName]);
743
- const tocContent = React4.useMemo(() => {
1090
+ const tocContent = React6.useMemo(() => {
744
1091
  if (tocSlot) return tocSlot;
745
1092
  if (!sections || sections.length === 0) return null;
746
1093
  return /* @__PURE__ */ jsxs("div", { className: "mb-8 lg:hidden", children: [
@@ -767,7 +1114,7 @@ function ArticleCompactTocComponent({
767
1114
  isTocOpen && /* @__PURE__ */ jsx("nav", { className: "mt-2 space-y-2 rounded-lg border p-4", children: sections.map((section) => {
768
1115
  const isActive = activeSection === section.id;
769
1116
  if (renderSectionLink) {
770
- return /* @__PURE__ */ jsx(React4.Fragment, { children: renderSectionLink(section, isActive) }, section.id);
1117
+ return /* @__PURE__ */ jsx(React6.Fragment, { children: renderSectionLink(section, isActive) }, section.id);
771
1118
  }
772
1119
  return /* @__PURE__ */ jsx(
773
1120
  Pressable,
@@ -785,7 +1132,7 @@ function ArticleCompactTocComponent({
785
1132
  }) })
786
1133
  ] });
787
1134
  }, [tocSlot, sections, isTocOpen, activeSection, renderSectionLink, tocClassName]);
788
- const heroMediaContent = React4.useMemo(() => {
1135
+ const heroMediaContent = React6.useMemo(() => {
789
1136
  if (heroMediaSlot) return heroMediaSlot;
790
1137
  if (!heroImageSrc) return null;
791
1138
  return /* @__PURE__ */ jsx(
@@ -798,26 +1145,36 @@ function ArticleCompactTocComponent({
798
1145
  }
799
1146
  );
800
1147
  }, [heroMediaSlot, heroImageSrc, heroImageAlt, heroImageClassName, optixFlowConfig]);
801
- return /* @__PURE__ */ jsx("section", { className: cn("py-32", className), children: /* @__PURE__ */ jsxs("div", { className: cn("container", containerClassName), children: [
802
- breadcrumbsContent,
803
- /* @__PURE__ */ jsxs("div", { className: cn("mx-auto max-w-3xl", contentClassName), children: [
804
- title && (typeof title === "string" ? /* @__PURE__ */ jsx("h1", { className: cn("text-3xl font-bold tracking-tight md:text-4xl lg:text-5xl", titleClassName), children: title }) : /* @__PURE__ */ jsx("div", { className: titleClassName, children: title })),
805
- (authorName || publishDate || readTime) && /* @__PURE__ */ jsxs("div", { className: cn("mt-4 flex flex-wrap items-center gap-4 text-sm text-muted-foreground", metaClassName), children: [
806
- authorName && (authorHref ? /* @__PURE__ */ jsx(Pressable, { href: authorHref, className: "hover:underline", children: authorName }) : /* @__PURE__ */ jsx("span", { children: authorName })),
807
- authorName && publishDate && /* @__PURE__ */ jsx(Separator, { orientation: "vertical", className: "h-4" }),
808
- publishDate && /* @__PURE__ */ jsx("span", { children: publishDate }),
809
- publishDate && readTime && /* @__PURE__ */ jsx(Separator, { orientation: "vertical", className: "h-4" }),
810
- readTime && /* @__PURE__ */ jsx("span", { children: readTime })
811
- ] }),
812
- shareContent,
813
- /* @__PURE__ */ jsx(Separator, { className: "my-8" }),
814
- tocContent,
815
- /* @__PURE__ */ jsxs("article", { className: cn("prose max-w-none dark:prose-invert", articleClassName), children: [
816
- heroMediaContent,
817
- children ?? defaultArticleContent()
1148
+ return /* @__PURE__ */ jsx(
1149
+ Section,
1150
+ {
1151
+ background,
1152
+ spacing,
1153
+ pattern,
1154
+ patternOpacity,
1155
+ className,
1156
+ children: /* @__PURE__ */ jsxs("div", { className: cn("container", containerClassName), children: [
1157
+ breadcrumbsContent,
1158
+ /* @__PURE__ */ jsxs("div", { className: cn("mx-auto max-w-3xl", contentClassName), children: [
1159
+ title && (typeof title === "string" ? /* @__PURE__ */ jsx("h1", { className: cn("text-3xl font-bold tracking-tight md:text-4xl lg:text-5xl", titleClassName), children: title }) : /* @__PURE__ */ jsx("div", { className: titleClassName, children: title })),
1160
+ (authorName || publishDate || readTime) && /* @__PURE__ */ jsxs("div", { className: cn("mt-4 flex flex-wrap items-center gap-4 text-sm text-muted-foreground", metaClassName), children: [
1161
+ authorName && (authorHref ? /* @__PURE__ */ jsx(Pressable, { href: authorHref, className: "hover:underline", children: authorName }) : /* @__PURE__ */ jsx("span", { children: authorName })),
1162
+ authorName && publishDate && /* @__PURE__ */ jsx(Separator, { orientation: "vertical", className: "h-4" }),
1163
+ publishDate && /* @__PURE__ */ jsx("span", { children: publishDate }),
1164
+ publishDate && readTime && /* @__PURE__ */ jsx(Separator, { orientation: "vertical", className: "h-4" }),
1165
+ readTime && /* @__PURE__ */ jsx("span", { children: readTime })
1166
+ ] }),
1167
+ shareContent,
1168
+ /* @__PURE__ */ jsx(Separator, { className: "my-8" }),
1169
+ tocContent,
1170
+ children && /* @__PURE__ */ jsxs("article", { className: cn("prose max-w-none dark:prose-invert", articleClassName), children: [
1171
+ heroMediaContent,
1172
+ children
1173
+ ] })
1174
+ ] })
818
1175
  ] })
819
- ] })
820
- ] }) });
1176
+ }
1177
+ );
821
1178
  }
822
1179
 
823
1180
  export { ArticleCompactTocComponent as ArticleCompactToc };