fulldev-ui 0.9.3 → 0.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/README.md +100 -16
- package/package.json +3 -2
- package/public/r/accordion.json +3 -5
- package/public/r/alert-dialog.json +1 -1
- package/public/r/alert.json +0 -5
- package/public/r/article-1.json +1 -1
- package/public/r/article-2.json +1 -1
- package/public/r/articles-1.json +1 -1
- package/public/r/articles-2.json +1 -1
- package/public/r/articles-3.json +1 -1
- package/public/r/avatar.json +1 -16
- package/public/r/badge.json +1 -1
- package/public/r/banner-1.json +5 -3
- package/public/r/banner-2.json +1 -1
- package/public/r/banner.json +5 -3
- package/public/r/blocks-1.json +6 -3
- package/public/r/breadcrumb.json +4 -4
- package/public/r/button.json +1 -1
- package/public/r/card.json +4 -4
- package/public/r/carousel.json +5 -5
- package/public/r/checkbox.json +1 -1
- package/public/r/combobox.json +8 -8
- package/public/r/command.json +6 -6
- package/public/r/components.json +1 -7
- package/public/r/contact-1.json +4 -2
- package/public/r/contact-2.json +4 -2
- package/public/r/contact-3.json +11 -3
- package/public/r/content-1.json +11 -3
- package/public/r/content-2.json +11 -3
- package/public/r/content-3.json +7 -1
- package/public/r/content-4.json +11 -3
- package/public/r/cta-2.json +7 -1
- package/public/r/cta-4.json +7 -1
- package/public/r/cta-5.json +11 -3
- package/public/r/cta-6.json +7 -1
- package/public/r/dialog.json +6 -6
- package/public/r/doc-1.json +6 -3
- package/public/r/dropdown-menu.json +9 -11
- package/public/r/features-1.json +5 -3
- package/public/r/features-2.json +5 -3
- package/public/r/features-4.json +5 -3
- package/public/r/features-5.json +4 -2
- package/public/r/field.json +2 -7
- package/public/r/footer-1.json +5 -3
- package/public/r/footer-2.json +5 -3
- package/public/r/footer-3.json +5 -3
- package/public/r/header-1.json +1 -1
- package/public/r/header.json +3 -0
- package/public/r/hero-13.json +1 -1
- package/public/r/hero-4.json +5 -3
- package/public/r/hero-5.json +5 -3
- package/public/r/hero-6.json +5 -3
- package/public/r/hero-7.json +5 -3
- package/public/r/hero-8.json +1 -1
- package/public/r/hero-9.json +5 -3
- package/public/r/hover-card.json +2 -2
- package/public/r/icon.json +1 -1
- package/public/r/input-group.json +1 -1
- package/public/r/item.json +2 -20
- package/public/r/kbd.json +2 -2
- package/public/r/layout.json +4 -7
- package/public/r/links-2.json +5 -3
- package/public/r/marquee.json +1 -1
- package/public/r/native-select.json +3 -3
- package/public/r/navigation-menu.json +6 -8
- package/public/r/page.json +17 -0
- package/public/r/popover.json +1 -1
- package/public/r/pricing-1.json +5 -3
- package/public/r/pricing-2.json +5 -3
- package/public/r/pricing-3.json +5 -3
- package/public/r/products-1.json +1 -1
- package/public/r/products-4.json +1 -1
- package/public/r/products-5.json +1 -1
- package/public/r/radio-group.json +1 -1
- package/public/r/rating.json +3 -3
- package/public/r/registry.json +186 -450
- package/public/r/reviews-1.json +5 -3
- package/public/r/reviews-2.json +5 -3
- package/public/r/reviews-3.json +5 -3
- package/public/r/reviews-4.json +1 -1
- package/public/r/reviews-5.json +5 -3
- package/public/r/select.json +6 -8
- package/public/r/services-1.json +11 -3
- package/public/r/services-2.json +7 -1
- package/public/r/services-3.json +7 -1
- package/public/r/services-4.json +11 -3
- package/public/r/services-5.json +5 -3
- package/public/r/services-6.json +11 -3
- package/public/r/services-7.json +11 -3
- package/public/r/sheet.json +6 -3
- package/public/r/sidebar-1.json +4 -2
- package/public/r/sidebar.json +10 -7
- package/public/r/slider.json +1 -1
- package/public/r/spinner.json +3 -3
- package/public/r/switch.json +1 -1
- package/public/r/theme-toggle.json +5 -3
- package/public/r/tooltip.json +1 -1
- package/public/r/typography.json +16 -16
- package/public/r/video.json +1 -1
- package/registry.json +186 -450
- package/src/components/blocks/article-1.astro +1 -1
- package/src/components/blocks/article-2.astro +1 -1
- package/src/components/blocks/articles-1.astro +1 -1
- package/src/components/blocks/articles-2.astro +2 -2
- package/src/components/blocks/articles-3.astro +1 -1
- package/src/components/blocks/banner-1.astro +3 -5
- package/src/components/blocks/banner-2.astro +1 -1
- package/src/components/blocks/blocks-1.astro +25 -37
- package/src/components/blocks/contact-3.astro +4 -3
- package/src/components/blocks/content-1.astro +5 -4
- package/src/components/blocks/content-2.astro +6 -5
- package/src/components/blocks/content-3.astro +9 -2
- package/src/components/blocks/content-4.astro +6 -5
- package/src/components/blocks/cta-2.astro +4 -3
- package/src/components/blocks/cta-4.astro +3 -2
- package/src/components/blocks/cta-5.astro +6 -5
- package/src/components/blocks/cta-6.astro +4 -3
- package/src/components/blocks/doc-1.astro +28 -56
- package/src/components/blocks/features-1.astro +3 -1
- package/src/components/blocks/features-2.astro +4 -2
- package/src/components/blocks/features-4.astro +3 -1
- package/src/components/blocks/footer-1.astro +26 -12
- package/src/components/blocks/footer-2.astro +24 -12
- package/src/components/blocks/footer-3.astro +26 -12
- package/src/components/blocks/header-1.astro +2 -3
- package/src/components/blocks/hero-13.astro +1 -1
- package/src/components/blocks/hero-4.astro +2 -2
- package/src/components/blocks/hero-5.astro +3 -3
- package/src/components/blocks/hero-6.astro +3 -3
- package/src/components/blocks/hero-7.astro +3 -3
- package/src/components/blocks/hero-8.astro +1 -1
- package/src/components/blocks/hero-9.astro +2 -2
- package/src/components/blocks/links-2.astro +3 -5
- package/src/components/blocks/pricing-1.astro +3 -2
- package/src/components/blocks/pricing-2.astro +3 -2
- package/src/components/blocks/pricing-3.astro +3 -2
- package/src/components/blocks/products-1.astro +1 -1
- package/src/components/blocks/products-4.astro +2 -2
- package/src/components/blocks/products-5.astro +4 -4
- package/src/components/blocks/reviews-1.astro +2 -2
- package/src/components/blocks/reviews-2.astro +2 -2
- package/src/components/blocks/reviews-3.astro +2 -2
- package/src/components/blocks/reviews-4.astro +4 -4
- package/src/components/blocks/reviews-5.astro +16 -25
- package/src/components/blocks/services-1.astro +7 -9
- package/src/components/blocks/services-2.astro +5 -4
- package/src/components/blocks/services-3.astro +6 -5
- package/src/components/blocks/services-4.astro +7 -9
- package/src/components/blocks/services-5.astro +3 -4
- package/src/components/blocks/services-6.astro +7 -6
- package/src/components/blocks/services-7.astro +7 -9
- package/src/components/blocks/sidebar-1.astro +42 -97
- package/src/components/ui/accordion/accordion-trigger.astro +7 -8
- package/src/components/ui/alert-dialog/alert-dialog.astro +23 -3
- package/src/components/ui/avatar/avatar.astro +1 -1
- package/src/components/ui/badge/badge.astro +1 -0
- package/src/components/ui/banner/banner-container.astro +3 -3
- package/src/components/ui/breadcrumb/breadcrumb-ellipsis.astro +2 -2
- package/src/components/ui/breadcrumb/breadcrumb-separator.astro +2 -2
- package/src/components/ui/button/button-variants.ts +8 -7
- package/src/components/ui/card/card-content.astro +1 -1
- package/src/components/ui/card/card-footer.astro +1 -1
- package/src/components/ui/card/card-header.astro +1 -1
- package/src/components/ui/card/card.astro +1 -1
- package/src/components/ui/carousel/carousel-next.astro +3 -3
- package/src/components/ui/carousel/carousel-previous.astro +3 -3
- package/src/components/ui/checkbox/checkbox.astro +1 -1
- package/src/components/ui/combobox/combobox-input.astro +2 -2
- package/src/components/ui/combobox/combobox-item.astro +4 -4
- package/src/components/ui/combobox/combobox-list.astro +1 -1
- package/src/components/ui/combobox/combobox-trigger.astro +2 -5
- package/src/components/ui/combobox/combobox.astro +3 -0
- package/src/components/ui/command/command-dialog.astro +10 -10
- package/src/components/ui/command/command-input.astro +2 -2
- package/src/components/ui/command/command-item.astro +4 -5
- package/src/components/ui/dialog/dialog-close.astro +2 -2
- package/src/components/ui/dialog/dialog-content.astro +2 -2
- package/src/components/ui/dialog/dialog.astro +26 -3
- package/src/components/ui/dropdown-menu/dropdown-menu-checkbox-item.astro +4 -5
- package/src/components/ui/dropdown-menu/dropdown-menu-content.astro +4 -4
- package/src/components/ui/dropdown-menu/dropdown-menu-item.astro +1 -1
- package/src/components/ui/dropdown-menu/dropdown-menu-label.astro +1 -1
- package/src/components/ui/dropdown-menu/dropdown-menu-radio-item.astro +4 -5
- package/src/components/ui/dropdown-menu/dropdown-menu-shortcut.astro +1 -1
- package/src/components/ui/dropdown-menu/dropdown-menu.astro +3 -0
- package/src/components/ui/field/field-label.astro +1 -1
- package/src/components/ui/field/field-title.astro +1 -1
- package/src/components/ui/hover-card/hover-card-content.astro +4 -4
- package/src/components/ui/hover-card/hover-card.astro +2 -2
- package/src/components/ui/icon/icon.astro +8 -17
- package/src/components/ui/input-group/input-group-button.astro +0 -1
- package/src/components/ui/item/item-media.astro +1 -1
- package/src/components/ui/item/item.astro +0 -18
- package/src/components/ui/kbd/kbd-group.astro +1 -1
- package/src/components/ui/kbd/kbd.astro +1 -1
- package/src/components/ui/layout/layout-body.astro +1 -1
- package/src/components/ui/layout/layout-head.astro +3 -2
- package/src/components/ui/layout/layout-main.astro +1 -1
- package/src/components/ui/layout/layout.astro +4 -0
- package/src/components/ui/marquee/marquee.astro +50 -69
- package/src/components/ui/native-select/native-select.astro +2 -3
- package/src/components/ui/navigation-menu/navigation-menu-content.astro +1 -1
- package/src/components/ui/navigation-menu/navigation-menu-list.astro +1 -1
- package/src/components/ui/navigation-menu/navigation-menu-trigger.astro +2 -3
- package/src/components/ui/navigation-menu/navigation-menu.astro +1 -1
- package/src/components/ui/popover/popover-content.astro +1 -1
- package/src/components/ui/radio-group/radio-group-item.astro +3 -3
- package/src/components/ui/rating/rating.astro +3 -3
- package/src/components/ui/select/select-content.astro +1 -1
- package/src/components/ui/select/select-item.astro +4 -4
- package/src/components/ui/select/select-trigger.astro +3 -6
- package/src/components/ui/select/select.astro +6 -0
- package/src/components/ui/sheet/sheet-content.astro +4 -5
- package/src/components/ui/sidebar/sidebar-menu-button.astro +13 -10
- package/src/components/ui/sidebar/sidebar-menu-sub-button.astro +10 -8
- package/src/components/ui/sidebar/sidebar-provider.astro +1 -13
- package/src/components/ui/sidebar/sidebar-rail.astro +1 -1
- package/src/components/ui/sidebar/sidebar-trigger.astro +3 -3
- package/src/components/ui/sidebar/sidebar.astro +1 -1
- package/src/components/ui/slider/slider.astro +6 -4
- package/src/components/ui/spinner/spinner.astro +4 -4
- package/src/components/ui/switch/switch.astro +1 -1
- package/src/components/ui/theme-toggle/theme-toggle.astro +4 -3
- package/src/components/ui/tooltip/tooltip-content.astro +1 -1
- package/src/components/ui/typography/typography-a.astro +19 -4
- package/src/components/ui/typography/typography-blockquote.astro +26 -6
- package/src/components/ui/typography/typography-h1.astro +7 -9
- package/src/components/ui/typography/typography-h2.astro +12 -9
- package/src/components/ui/typography/typography-h3.astro +7 -9
- package/src/components/ui/typography/typography-h4.astro +7 -9
- package/src/components/ui/typography/typography-inline-code.astro +28 -12
- package/src/components/ui/typography/typography-lead.astro +29 -4
- package/src/components/ui/typography/typography-list-item.astro +25 -9
- package/src/components/ui/typography/typography-list.astro +29 -11
- package/src/components/ui/typography/typography-p.astro +26 -6
- package/src/components/ui/typography/typography-table-cell.astro +32 -13
- package/src/components/ui/typography/typography-table-head.astro +27 -13
- package/src/components/ui/typography/typography-table-row.astro +23 -13
- package/src/components/ui/typography/typography-table.astro +29 -20
- package/src/components/ui/typography/typography.astro +172 -46
- package/src/components/ui/video/video.astro +11 -27
- package/src/styles/global.css +2 -15
- package/public/r/beta-repo-setup.json +0 -125
- package/public/r/blocks.json +0 -91
- package/public/r/content-5.json +0 -17
- package/public/r/content-6.json +0 -17
- package/public/r/gradient.json +0 -17
- package/public/r/init.json +0 -23
- package/public/r/tile.json +0 -27
- package/src/components/blocks/content-5.astro +0 -115
- package/src/components/blocks/content-6.astro +0 -91
- package/src/components/ui/gradient/gradient.astro +0 -45
- package/src/components/ui/gradient/index.ts +0 -1
- package/src/components/ui/tile/index.ts +0 -3
- package/src/components/ui/tile/tile-content.astro +0 -17
- package/src/components/ui/tile/tile-group.astro +0 -76
- package/src/components/ui/tile/tile.astro +0 -46
package/public/r/dialog.json
CHANGED
|
@@ -2,16 +2,16 @@
|
|
|
2
2
|
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
3
|
"name": "dialog",
|
|
4
4
|
"dependencies": [
|
|
5
|
-
"@data-slot/dialog"
|
|
5
|
+
"@data-slot/dialog",
|
|
6
|
+
"@lucide/astro"
|
|
6
7
|
],
|
|
7
8
|
"registryDependencies": [
|
|
8
|
-
"@fulldev/button"
|
|
9
|
-
"@fulldev/icon"
|
|
9
|
+
"@fulldev/button"
|
|
10
10
|
],
|
|
11
11
|
"files": [
|
|
12
12
|
{
|
|
13
13
|
"path": "src/components/ui/dialog/dialog.astro",
|
|
14
|
-
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\n\ntype Props = HTMLAttributes<\"div\"
|
|
14
|
+
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\n\ntype Props = HTMLAttributes<\"div\"> & {\n defaultOpen?: boolean\n closeOnClickOutside?: boolean\n closeOnEscape?: boolean\n lockScroll?: boolean\n alertDialog?: boolean\n}\n\nconst {\n class: className,\n defaultOpen,\n closeOnClickOutside,\n closeOnEscape,\n lockScroll,\n alertDialog,\n ...props\n} = Astro.props\n---\n\n<div\n data-slot=\"dialog\"\n data-default-open={defaultOpen}\n data-close-on-click-outside={closeOnClickOutside}\n data-close-on-escape={closeOnEscape}\n data-lock-scroll={lockScroll}\n data-alert-dialog={alertDialog}\n class={className}\n {...props}\n>\n <slot />\n</div>\n\n<script>\n import { create } from \"@data-slot/dialog\"\n\n create()\n</script>\n",
|
|
15
15
|
"type": "registry:ui"
|
|
16
16
|
},
|
|
17
17
|
{
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
},
|
|
32
32
|
{
|
|
33
33
|
"path": "src/components/ui/dialog/dialog-content.astro",
|
|
34
|
-
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Button } from \"@/components/ui/button\"\nimport DialogOverlay from \"@/components/ui/dialog/dialog-overlay.astro\"\nimport DialogPortal from \"@/components/ui/dialog/dialog-portal.astro\"\
|
|
34
|
+
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\nimport XIcon from \"@lucide/astro/icons/x\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Button } from \"@/components/ui/button\"\nimport DialogOverlay from \"@/components/ui/dialog/dialog-overlay.astro\"\nimport DialogPortal from \"@/components/ui/dialog/dialog-portal.astro\"\n\ntype Props = HTMLAttributes<\"div\"> & {\n showCloseButton?: boolean\n}\n\nconst {\n class: className,\n showCloseButton = true,\n style,\n ...props\n} = Astro.props\n---\n\n<DialogPortal>\n <DialogOverlay />\n <div\n data-slot=\"dialog-content\"\n hidden\n class={cn(\n \"bg-popover text-popover-foreground ring-foreground/10 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95 fixed top-1/2 left-1/2 z-50 grid w-full max-w-[calc(100%-2rem)] -translate-x-1/2 -translate-y-1/2 gap-6 rounded-xl p-6 text-sm ring-1 duration-100 outline-none sm:max-w-md\",\n className\n )}\n style={`z-index: calc(var(--dialog-content-stack-index, 0) + 101);${style ? ` ${style}` : \"\"}`}\n {...props}\n >\n {\n showCloseButton && (\n <Button\n type=\"button\"\n data-slot=\"dialog-close\"\n variant=\"ghost\"\n size=\"icon-sm\"\n class=\"absolute top-4 right-4\"\n >\n <XIcon />\n <span class=\"sr-only\">Close</span>\n </Button>\n )\n }\n <slot />\n </div>\n</DialogPortal>\n",
|
|
35
35
|
"type": "registry:ui"
|
|
36
36
|
},
|
|
37
37
|
{
|
|
@@ -56,7 +56,7 @@
|
|
|
56
56
|
},
|
|
57
57
|
{
|
|
58
58
|
"path": "src/components/ui/dialog/dialog-close.astro",
|
|
59
|
-
"content": "---\nimport type { ComponentProps } from \"astro/types\"\
|
|
59
|
+
"content": "---\nimport type { ComponentProps } from \"astro/types\"\nimport X from \"@lucide/astro/icons/x\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Button } from \"@/components/ui/button\"\n\ntype Props = ComponentProps<typeof Button>\n\nconst { class: className, ...props } = Astro.props\n---\n\n<Button class={cn(className)} data-slot=\"dialog-close\" {...props}>\n <slot>\n <X />\n </slot>\n</Button>\n",
|
|
60
60
|
"type": "registry:ui"
|
|
61
61
|
},
|
|
62
62
|
{
|
package/public/r/doc-1.json
CHANGED
|
@@ -1,19 +1,22 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
3
|
"name": "doc-1",
|
|
4
|
+
"dependencies": [
|
|
5
|
+
"@lucide/astro",
|
|
6
|
+
"simple-icons-astro"
|
|
7
|
+
],
|
|
4
8
|
"registryDependencies": [
|
|
5
9
|
"@fulldev/button",
|
|
6
10
|
"@fulldev/card",
|
|
7
11
|
"@fulldev/dropdown-menu",
|
|
8
12
|
"@fulldev/section",
|
|
9
13
|
"@fulldev/toc",
|
|
10
|
-
"@fulldev/typography"
|
|
11
|
-
"@fulldev/icon"
|
|
14
|
+
"@fulldev/typography"
|
|
12
15
|
],
|
|
13
16
|
"files": [
|
|
14
17
|
{
|
|
15
18
|
"path": "src/components/blocks/doc-1.astro",
|
|
16
|
-
"content": "---\nimport { cn } from \"@/lib/utils\"\nimport { Button } from \"@/components/ui/button\"\nimport { buttonVariants } from \"@/components/ui/button/button-variants\"\nimport {\n Card,\n CardDescription,\n CardFooter,\n CardHeader,\n} from \"@/components/ui/card\"\nimport {\n DropdownMenu,\n DropdownMenuContent,\n DropdownMenuTrigger,\n} from \"@/components/ui/dropdown-menu\"\nimport { Icon } from \"@/components/ui/icon\"\nimport { SectionContainer } from \"@/components/ui/section\"\nimport {\n Toc,\n TocMenu,\n TocMenuItem,\n TocMenuLink,\n TocTitle,\n} from \"@/components/ui/toc\"\nimport {\n Typography,\n TypographyH1,\n TypographyLead,\n} from \"@/components/ui/typography\"\n\ntype Props = {\n class?: string\n title: string\n description?: string\n copyButton?: {\n id: string\n source: string\n }\n markdownUrl?: string\n tocItems: {\n depth: number\n href: string\n label: string\n }[]\n callout?: {\n description: string\n button: {\n label: string\n href: string\n variant?: \"default\" | \"outline\" | \"secondary\" | \"ghost\"\n }\n }\n previousPage?: {\n href: string\n title: string\n }\n nextPage?: {\n href: string\n title: string\n }\n labels: {\n copyMarkdown: string\n openIn: string\n openInMarkdown: string\n openInChatGPT: string\n openInClaude: string\n openInCursor: string\n pagination: {\n previous: string\n next: string\n ariaLabel: string\n }\n toc: string\n }\n}\n\nconst {\n class: className,\n title,\n description,\n copyButton,\n markdownUrl,\n tocItems,\n callout,\n previousPage,\n nextPage,\n labels,\n} = Astro.props\nconst showCopyButton = Boolean(copyButton)\nconst showOpenButton = Boolean(markdownUrl)\nconst showPagination = Boolean(previousPage || nextPage)\nconst assistantPrompt = markdownUrl\n ? `Read ${markdownUrl}, I want to ask questions about it.`\n : \"\"\nconst openLinks = markdownUrl\n ? [\n {\n label: labels.openInMarkdown,\n href: markdownUrl,\n icon: \"markdown\",\n },\n {\n label: labels.openInChatGPT,\n href: `https://chatgpt.com/?hints=search&q=${encodeURIComponent(assistantPrompt)}`,\n icon: \"chatgpt\",\n },\n {\n label: labels.openInClaude,\n href: `https://claude.ai/new?q=${encodeURIComponent(assistantPrompt)}`,\n icon: \"claude\",\n },\n {\n label: labels.openInCursor,\n href: `https://cursor.com/link/prompt?text=${encodeURIComponent(assistantPrompt)}`,\n icon: \"cursor\",\n },\n ]\n : []\n---\n\n<SectionContainer\n class={cn(\n \"gap-10 pt-10 pb-8 sm:pt-12 sm:pb-10 xl:grid xl:grid-cols-[minmax(0,1fr)_16rem] xl:items-start xl:gap-x-16\",\n className\n )}\n>\n <div class=\"mx-auto flex w-full max-w-3xl min-w-0 flex-col gap-10\">\n <header\n class=\"flex flex-col gap-4 sm:flex-row sm:items-start sm:justify-between\"\n >\n <div class=\"flex min-w-0 flex-1 flex-col gap-2\">\n <TypographyH1\n size=\"sm\"\n class=\"text-foreground text-left tracking-tight\"\n >\n {title}\n </TypographyH1>\n {\n description && (\n <TypographyLead class=\"max-w-2xl text-base! leading-7\">\n {description}\n </TypographyLead>\n )\n }\n </div>\n <div class=\"flex shrink-0 items-center gap-2 self-start\">\n {\n showCopyButton && (\n <Button\n id={copyButton?.id}\n type=\"button\"\n variant=\"outline\"\n size=\"xs\"\n data-source={copyButton?.source}\n aria-label={labels.copyMarkdown}\n >\n <Icon\n name=\"copy\"\n data-copy-icon\n class=\"docs-copy-icon size-3.5\"\n />\n <Icon\n name=\"check\"\n data-check-icon\n class=\"docs-check-icon hidden size-3.5\"\n />\n <span>{labels.copyMarkdown}</span>\n </Button>\n )\n }\n {\n showOpenButton && (\n <DropdownMenu>\n <DropdownMenuTrigger\n class={buttonVariants({ variant: \"outline\", size: \"xs\" })}\n >\n <span>{labels.openIn}</span>\n <Icon name=\"chevron-down\" class=\"size-3.5 opacity-70\" />\n </DropdownMenuTrigger>\n <DropdownMenuContent align=\"end\" sideOffset={6} class=\"w-56\">\n {openLinks.map((link) => (\n <a\n href={link.href}\n target=\"_blank\"\n rel=\"noreferrer noopener\"\n class=\"hover:bg-accent hover:text-accent-foreground flex items-center gap-2 rounded-sm px-2 py-1.5 text-sm transition-colors outline-none\"\n >\n {link.icon === \"markdown\" && (\n <Icon name=\"markdown\" class=\"size-4 fill-current\" />\n )}\n {link.icon === \"chatgpt\" && (\n <svg\n role=\"img\"\n viewBox=\"0 0 24 24\"\n fill=\"currentColor\"\n class=\"size-4\"\n aria-hidden=\"true\"\n >\n <path d=\"M22.282 9.821a5.985 5.985 0 0 0-.516-4.91 6.046 6.046 0 0 0-6.51-2.9A6.065 6.065 0 0 0 4.981 4.182a5.985 5.985 0 0 0-3.998 2.9 6.046 6.046 0 0 0 .743 7.097 5.98 5.98 0 0 0 .511 4.91 6.051 6.051 0 0 0 6.515 2.9A5.985 5.985 0 0 0 13.26 24a6.056 6.056 0 0 0 5.772-4.206 5.989 5.989 0 0 0 3.998-2.9 6.056 6.056 0 0 0-.748-7.073ZM13.26 22.43a4.476 4.476 0 0 1-2.876-1.04l.142-.081 4.778-2.758a.795.795 0 0 0 .393-.681v-6.737l2.02 1.169a.071.071 0 0 1 .038.052v5.583a4.504 4.504 0 0 1-4.495 4.494Zm-9.66-4.125a4.471 4.471 0 0 1-.535-3.014l.142.085 4.783 2.758a.771.771 0 0 0 .781 0l5.843-3.368v2.332a.08.08 0 0 1-.034.062L9.74 19.95a4.499 4.499 0 0 1-6.14-1.646ZM2.34 7.896a4.485 4.485 0 0 1 2.366-1.973V11.6a.766.766 0 0 0 .388.677l5.814 3.354-2.02 1.169a.076.076 0 0 1-.071 0l-4.83-2.787A4.504 4.504 0 0 1 2.34 7.872Zm16.596 3.856-5.833-3.388L15.12 7.2a.076.076 0 0 1 .071 0l4.83 2.791a4.494 4.494 0 0 1-.676 8.104v-5.677a.79.79 0 0 0-.407-.667Zm2.011-3.024-.142-.085-4.774-2.782a.776.776 0 0 0-.785 0L9.409 9.23V6.897a.066.066 0 0 1 .028-.061l4.83-2.787a4.499 4.499 0 0 1 6.68 4.66ZM8.307 12.863l-2.02-1.164a.08.08 0 0 1-.038-.057V6.074a4.499 4.499 0 0 1 7.376-3.453l-.142.08-4.778 2.758a.795.795 0 0 0-.393.681Zm1.097-2.365 2.602-1.5 2.607 1.5v2.999l-2.597 1.5-2.607-1.5Z\" />\n </svg>\n )}\n {link.icon === \"claude\" && (\n <Icon name=\"claude\" class=\"size-4 fill-current\" />\n )}\n {link.icon === \"cursor\" && (\n <Icon name=\"cursor\" class=\"size-4 fill-current\" />\n )}\n <span>{link.label}</span>\n <Icon\n name=\"external-link\"\n class=\"text-muted-foreground ml-auto size-3.5\"\n />\n </a>\n ))}\n </DropdownMenuContent>\n </DropdownMenu>\n )\n }\n </div>\n </header>\n\n <Typography as=\"article\" size=\"sm\">\n <slot />\n </Typography>\n\n {\n showPagination && (\n <nav\n class=\"flex items-center justify-between gap-3\"\n aria-label={labels.pagination.ariaLabel}\n >\n {previousPage ? (\n <Button\n as=\"a\"\n href={previousPage.href}\n variant=\"outline\"\n class=\"h-auto min-w-0 items-center justify-start gap-2 px-3 py-2 whitespace-normal\"\n >\n <Icon name=\"arrow-left\" class=\"size-4\" />\n <span class=\"truncate text-sm font-medium\">\n {previousPage.title}\n </span>\n </Button>\n ) : (\n <div aria-hidden=\"true\" />\n )}\n\n {nextPage ? (\n <Button\n as=\"a\"\n href={nextPage.href}\n variant=\"outline\"\n class=\"h-auto min-w-0 items-center justify-end gap-2 px-3 py-2 text-right whitespace-normal\"\n >\n <span class=\"truncate text-sm font-medium\">{nextPage.title}</span>\n <Icon name=\"arrow-right\" class=\"size-4\" />\n </Button>\n ) : (\n <div aria-hidden=\"true\" />\n )}\n </nav>\n )\n }\n </div>\n\n {\n (tocItems.length > 0 || callout) && (\n <aside class=\"hidden w-64 xl:sticky xl:top-12 xl:mr-0 xl:ml-auto xl:block xl:self-start\">\n <div class=\"flex flex-col gap-6\">\n {tocItems.length > 0 && (\n <Toc aria-label={labels.toc}>\n <TocTitle>{labels.toc}</TocTitle>\n <TocMenu>\n {tocItems.map((item) => (\n <TocMenuItem>\n <TocMenuLink href={item.href} depth={item.depth}>\n {item.label}\n </TocMenuLink>\n </TocMenuItem>\n ))}\n </TocMenu>\n </Toc>\n )}\n\n {callout && (\n <Card size=\"sm\">\n <CardHeader>\n <CardDescription>{callout.description}</CardDescription>\n </CardHeader>\n <CardFooter>\n <Button\n as=\"a\"\n href={callout.button.href}\n variant={callout.button.variant}\n size=\"sm\"\n target=\"_blank\"\n rel=\"noreferrer\"\n >\n {callout.button.label}\n </Button>\n </CardFooter>\n </Card>\n )}\n </div>\n </aside>\n )\n }\n</SectionContainer>\n\n<script is:inline>\n const copyIcon = `<svg viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><rect width=\"14\" height=\"14\" x=\"8\" y=\"8\" rx=\"2\" ry=\"2\"></rect><path d=\"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2\"></path></svg>`\n const checkIcon = `<svg viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path d=\"M20 6 9 17l-5-5\"></path></svg>`\n document.querySelectorAll(\"[data-slot='typography'] > pre\").forEach((pre) => {\n if (pre.closest(\".docs-code-block\")) return\n const wrapper = document.createElement(\"div\")\n const button = document.createElement(\"button\")\n wrapper.className = \"docs-code-block\"\n button.type = \"button\"\n button.className = \"docs-code-copy\"\n button.ariaLabel = \"Copy code\"\n button.innerHTML = `<span data-copy-icon>${copyIcon}</span><span data-check-icon class=\"hidden\">${checkIcon}</span>`\n pre.before(wrapper)\n wrapper.append(pre, button)\n })\n\n const writeToClipboard = async (text) => {\n if (navigator.clipboard && window.isSecureContext) {\n try {\n await navigator.clipboard.writeText(text)\n return true\n } catch {\n return false\n }\n }\n\n return false\n }\n\n const showCopySuccess = (button) => {\n button.querySelector(\"[data-copy-icon]\")?.classList.add(\"hidden\")\n button.querySelector(\"[data-check-icon]\")?.classList.remove(\"hidden\")\n setTimeout(() => {\n button.querySelector(\"[data-copy-icon]\")?.classList.remove(\"hidden\")\n button.querySelector(\"[data-check-icon]\")?.classList.add(\"hidden\")\n }, 1200)\n }\n\n document.addEventListener(\"click\", async (event) => {\n const button = event.target?.closest?.(\n \"[id^='docs-copy-page-'], .docs-code-copy\"\n )\n if (!button) return\n const source =\n button.dataset.source ??\n button\n .closest(\".docs-code-block\")\n ?.querySelector(\"pre\")\n ?.textContent?.replace(/\\n$/, \"\")\n if (!source) return\n\n const copied = await writeToClipboard(source)\n if (copied) showCopySuccess(button)\n })\n</script>\n",
|
|
19
|
+
"content": "---\nimport ArrowLeft from \"@lucide/astro/icons/arrow-left\"\nimport ArrowRight from \"@lucide/astro/icons/arrow-right\"\nimport Check from \"@lucide/astro/icons/check\"\nimport ChevronDown from \"@lucide/astro/icons/chevron-down\"\nimport Copy from \"@lucide/astro/icons/copy\"\nimport ExternalLink from \"@lucide/astro/icons/external-link\"\nimport Claude from \"simple-icons-astro/Claude\"\nimport Cursor from \"simple-icons-astro/Cursor\"\nimport Markdown from \"simple-icons-astro/Markdown\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Button } from \"@/components/ui/button\"\nimport { buttonVariants } from \"@/components/ui/button/button-variants\"\nimport {\n Card,\n CardDescription,\n CardFooter,\n CardHeader,\n} from \"@/components/ui/card\"\nimport {\n DropdownMenu,\n DropdownMenuContent,\n DropdownMenuTrigger,\n} from \"@/components/ui/dropdown-menu\"\nimport { SectionContainer } from \"@/components/ui/section\"\nimport {\n Toc,\n TocMenu,\n TocMenuItem,\n TocMenuLink,\n TocTitle,\n} from \"@/components/ui/toc\"\nimport {\n Typography,\n TypographyH1,\n TypographyLead,\n} from \"@/components/ui/typography\"\n\ntype Props = {\n class?: string\n title: string\n description?: string\n copyButton?: {\n id: string\n source: string\n }\n markdownUrl?: string\n tocItems: {\n depth: number\n href: string\n label: string\n }[]\n callout?: {\n description: string\n button: {\n label: string\n href: string\n variant?: \"default\" | \"outline\" | \"secondary\" | \"ghost\"\n }\n }\n previousPage?: {\n href: string\n title: string\n }\n nextPage?: {\n href: string\n title: string\n }\n labels: {\n copyMarkdown: string\n openIn: string\n openInMarkdown: string\n openInChatGPT: string\n openInClaude: string\n openInCursor: string\n pagination: {\n previous: string\n next: string\n ariaLabel: string\n }\n toc: string\n }\n}\n\nconst {\n class: className,\n title,\n description,\n copyButton,\n markdownUrl,\n tocItems,\n callout,\n previousPage,\n nextPage,\n labels,\n} = Astro.props\nconst showCopyButton = Boolean(copyButton)\nconst showOpenButton = Boolean(markdownUrl)\nconst showPagination = Boolean(previousPage || nextPage)\nconst assistantPrompt = markdownUrl\n ? `Read ${markdownUrl}, I want to ask questions about it.`\n : \"\"\nconst openLinks = markdownUrl\n ? [\n {\n label: labels.openInMarkdown,\n href: markdownUrl,\n icon: \"markdown\",\n },\n {\n label: labels.openInChatGPT,\n href: `https://chatgpt.com/?hints=search&q=${encodeURIComponent(assistantPrompt)}`,\n icon: \"chatgpt\",\n },\n {\n label: labels.openInClaude,\n href: `https://claude.ai/new?q=${encodeURIComponent(assistantPrompt)}`,\n icon: \"claude\",\n },\n {\n label: labels.openInCursor,\n href: `https://cursor.com/link/prompt?text=${encodeURIComponent(assistantPrompt)}`,\n icon: \"cursor\",\n },\n ]\n : []\n---\n\n<SectionContainer\n class={cn(\n \"gap-10 pt-10 pb-8 sm:pt-12 sm:pb-10 xl:grid xl:grid-cols-[minmax(0,1fr)_16rem] xl:items-start xl:gap-x-16\",\n className\n )}\n>\n <div class=\"mx-auto flex w-full max-w-3xl min-w-0 flex-col gap-10\">\n <header\n class=\"flex flex-col gap-4 sm:flex-row sm:items-start sm:justify-between\"\n >\n <div class=\"flex min-w-0 flex-1 flex-col gap-2\">\n <TypographyH1\n size=\"sm\"\n class=\"text-foreground text-left tracking-tight\"\n >\n {title}\n </TypographyH1>\n {\n description && (\n <TypographyLead size=\"sm\" class=\"max-w-2xl leading-7\">\n {description}\n </TypographyLead>\n )\n }\n </div>\n <div class=\"flex shrink-0 items-center gap-2 self-start\">\n {\n showCopyButton && (\n <Button\n id={copyButton?.id}\n type=\"button\"\n variant=\"outline\"\n size=\"xs\"\n data-source={copyButton?.source}\n aria-label={labels.copyMarkdown}\n >\n <Copy data-copy-icon class=\"docs-copy-icon size-3.5\" />\n <Check data-check-icon class=\"docs-check-icon hidden size-3.5\" />\n <span>{labels.copyMarkdown}</span>\n </Button>\n )\n }\n {\n showOpenButton && (\n <DropdownMenu>\n <DropdownMenuTrigger\n class={buttonVariants({ variant: \"outline\", size: \"xs\" })}\n >\n <span>{labels.openIn}</span>\n <ChevronDown class=\"size-3.5 opacity-70\" />\n </DropdownMenuTrigger>\n <DropdownMenuContent align=\"end\" sideOffset={6} class=\"w-56\">\n {openLinks.map((link) => (\n <a\n href={link.href}\n target=\"_blank\"\n rel=\"noreferrer noopener\"\n class=\"hover:bg-accent hover:text-accent-foreground flex items-center gap-2 rounded-sm px-2 py-1.5 text-sm transition-colors outline-none\"\n >\n {link.icon === \"markdown\" && <Markdown class=\"size-4\" />}\n {link.icon === \"chatgpt\" && (\n <svg\n role=\"img\"\n viewBox=\"0 0 24 24\"\n fill=\"currentColor\"\n class=\"size-4\"\n aria-hidden=\"true\"\n >\n <path d=\"M22.282 9.821a5.985 5.985 0 0 0-.516-4.91 6.046 6.046 0 0 0-6.51-2.9A6.065 6.065 0 0 0 4.981 4.182a5.985 5.985 0 0 0-3.998 2.9 6.046 6.046 0 0 0 .743 7.097 5.98 5.98 0 0 0 .511 4.91 6.051 6.051 0 0 0 6.515 2.9A5.985 5.985 0 0 0 13.26 24a6.056 6.056 0 0 0 5.772-4.206 5.989 5.989 0 0 0 3.998-2.9 6.056 6.056 0 0 0-.748-7.073ZM13.26 22.43a4.476 4.476 0 0 1-2.876-1.04l.142-.081 4.778-2.758a.795.795 0 0 0 .393-.681v-6.737l2.02 1.169a.071.071 0 0 1 .038.052v5.583a4.504 4.504 0 0 1-4.495 4.494Zm-9.66-4.125a4.471 4.471 0 0 1-.535-3.014l.142.085 4.783 2.758a.771.771 0 0 0 .781 0l5.843-3.368v2.332a.08.08 0 0 1-.034.062L9.74 19.95a4.499 4.499 0 0 1-6.14-1.646ZM2.34 7.896a4.485 4.485 0 0 1 2.366-1.973V11.6a.766.766 0 0 0 .388.677l5.814 3.354-2.02 1.169a.076.076 0 0 1-.071 0l-4.83-2.787A4.504 4.504 0 0 1 2.34 7.872Zm16.596 3.856-5.833-3.388L15.12 7.2a.076.076 0 0 1 .071 0l4.83 2.791a4.494 4.494 0 0 1-.676 8.104v-5.677a.79.79 0 0 0-.407-.667Zm2.011-3.024-.142-.085-4.774-2.782a.776.776 0 0 0-.785 0L9.409 9.23V6.897a.066.066 0 0 1 .028-.061l4.83-2.787a4.499 4.499 0 0 1 6.68 4.66ZM8.307 12.863l-2.02-1.164a.08.08 0 0 1-.038-.057V6.074a4.499 4.499 0 0 1 7.376-3.453l-.142.08-4.778 2.758a.795.795 0 0 0-.393.681Zm1.097-2.365 2.602-1.5 2.607 1.5v2.999l-2.597 1.5-2.607-1.5Z\" />\n </svg>\n )}\n {link.icon === \"claude\" && <Claude class=\"size-4\" />}\n {link.icon === \"cursor\" && <Cursor class=\"size-4\" />}\n <span>{link.label}</span>\n <ExternalLink class=\"text-muted-foreground ml-auto size-3.5\" />\n </a>\n ))}\n </DropdownMenuContent>\n </DropdownMenu>\n )\n }\n </div>\n </header>\n\n <Typography as=\"article\" size=\"sm\">\n <slot />\n </Typography>\n\n {\n showPagination && (\n <nav\n class=\"flex items-center justify-between gap-3\"\n aria-label={labels.pagination.ariaLabel}\n >\n {previousPage ? (\n <Button\n as=\"a\"\n href={previousPage.href}\n variant=\"outline\"\n class=\"h-auto min-w-0 items-center justify-start gap-2 px-3 py-2 whitespace-normal\"\n >\n <ArrowLeft class=\"size-4\" />\n <span class=\"truncate text-sm font-medium\">\n {previousPage.title}\n </span>\n </Button>\n ) : (\n <div aria-hidden=\"true\" />\n )}\n\n {nextPage ? (\n <Button\n as=\"a\"\n href={nextPage.href}\n variant=\"outline\"\n class=\"h-auto min-w-0 items-center justify-end gap-2 px-3 py-2 text-right whitespace-normal\"\n >\n <span class=\"truncate text-sm font-medium\">{nextPage.title}</span>\n <ArrowRight class=\"size-4\" />\n </Button>\n ) : (\n <div aria-hidden=\"true\" />\n )}\n </nav>\n )\n }\n </div>\n\n {\n (tocItems.length > 0 || callout) && (\n <aside class=\"hidden w-64 xl:sticky xl:top-12 xl:mr-0 xl:ml-auto xl:block xl:self-start\">\n <div class=\"flex flex-col gap-6\">\n {tocItems.length > 0 && (\n <Toc aria-label={labels.toc}>\n <TocTitle>{labels.toc}</TocTitle>\n <TocMenu>\n {tocItems.map((item) => (\n <TocMenuItem>\n <TocMenuLink href={item.href} depth={item.depth}>\n {item.label}\n </TocMenuLink>\n </TocMenuItem>\n ))}\n </TocMenu>\n </Toc>\n )}\n\n {callout && (\n <Card size=\"sm\">\n <CardHeader>\n <CardDescription>{callout.description}</CardDescription>\n </CardHeader>\n <CardFooter>\n <Button\n as=\"a\"\n href={callout.button.href}\n variant={callout.button.variant}\n size=\"sm\"\n target=\"_blank\"\n rel=\"noreferrer\"\n >\n {callout.button.label}\n </Button>\n </CardFooter>\n </Card>\n )}\n </div>\n </aside>\n )\n }\n</SectionContainer>\n\n<script is:inline>\n const copyIcon = `<svg viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><rect width=\"14\" height=\"14\" x=\"8\" y=\"8\" rx=\"2\" ry=\"2\"></rect><path d=\"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2\"></path></svg>`\n const checkIcon = `<svg viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path d=\"M20 6 9 17l-5-5\"></path></svg>`\n document.querySelectorAll(\"[data-slot='typography'] > pre\").forEach((pre) => {\n if (pre.closest(\".docs-code-block\")) return\n const wrapper = document.createElement(\"div\")\n const button = document.createElement(\"button\")\n wrapper.className = \"docs-code-block\"\n button.type = \"button\"\n button.className = \"docs-code-copy\"\n button.ariaLabel = \"Copy code\"\n button.innerHTML = `<span data-copy-icon>${copyIcon}</span><span data-check-icon class=\"hidden\">${checkIcon}</span>`\n pre.before(wrapper)\n wrapper.append(pre, button)\n })\n document.addEventListener(\"click\", (event) => {\n const button = event.target?.closest?.(\n \"[id^='docs-copy-page-'], .docs-code-copy\"\n )\n if (!button) return\n const source =\n button.dataset.source ??\n button\n .closest(\".docs-code-block\")\n ?.querySelector(\"pre\")\n ?.textContent?.replace(/\\n$/, \"\")\n button.querySelector(\"[data-copy-icon]\")?.classList.add(\"hidden\")\n button.querySelector(\"[data-check-icon]\")?.classList.remove(\"hidden\")\n navigator.clipboard?.writeText(source ?? \"\")\n setTimeout(() => {\n button.querySelector(\"[data-copy-icon]\")?.classList.remove(\"hidden\")\n button.querySelector(\"[data-check-icon]\")?.classList.add(\"hidden\")\n }, 1200)\n })\n</script>\n",
|
|
17
20
|
"type": "registry:block"
|
|
18
21
|
}
|
|
19
22
|
],
|
|
@@ -2,15 +2,13 @@
|
|
|
2
2
|
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
3
|
"name": "dropdown-menu",
|
|
4
4
|
"dependencies": [
|
|
5
|
-
"@data-slot/dropdown-menu"
|
|
6
|
-
|
|
7
|
-
"registryDependencies": [
|
|
8
|
-
"@fulldev/icon"
|
|
5
|
+
"@data-slot/dropdown-menu",
|
|
6
|
+
"@lucide/astro"
|
|
9
7
|
],
|
|
10
8
|
"files": [
|
|
11
9
|
{
|
|
12
10
|
"path": "src/components/ui/dropdown-menu/dropdown-menu.astro",
|
|
13
|
-
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\nimport type { Align, Side } from \"@data-slot/dropdown-menu\"\n\ntype Props = HTMLAttributes<\"div\"> & {\n defaultOpen?: boolean\n defaultValue?: string | null\n defaultValues?: string[]\n closeOnClickOutside?: boolean\n closeOnEscape?: boolean\n closeOnSelect?: boolean\n highlightItemOnHover?: boolean\n side?: Side\n align?: Align\n sideOffset?: number\n alignOffset?: number\n avoidCollisions?: boolean\n collisionPadding?: number\n}\n\nconst {\n class: className,\n defaultOpen,\n defaultValue,\n defaultValues,\n closeOnClickOutside,\n closeOnEscape,\n closeOnSelect,\n highlightItemOnHover,\n side,\n align,\n sideOffset,\n alignOffset,\n avoidCollisions,\n collisionPadding,\n ...props\n} = Astro.props\n\nconst defaultValuesAttr =\n defaultValues === undefined ? undefined : JSON.stringify(defaultValues)\n---\n\n<div\n data-slot=\"dropdown-menu\"\n data-default-open={defaultOpen}\n data-default-value={defaultValue}\n data-default-values={defaultValuesAttr}\n data-close-on-click-outside={closeOnClickOutside}\n data-close-on-escape={closeOnEscape}\n data-close-on-select={closeOnSelect}\n data-highlight-item-on-hover={highlightItemOnHover}\n data-side={side}\n data-align={align}\n data-side-offset={sideOffset}\n data-align-offset={alignOffset}\n data-avoid-collisions={avoidCollisions}\n data-collision-padding={collisionPadding}\n class={className}\n {...props}\n>\n <slot />\n</div>\n\n<script>\n import { create } from \"@data-slot/dropdown-menu\"\n\n create()\n</script>\n",
|
|
11
|
+
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\nimport type { Align, Side } from \"@data-slot/dropdown-menu\"\n\ntype Props = HTMLAttributes<\"div\"> & {\n defaultOpen?: boolean\n defaultValue?: string | null\n defaultValues?: string[]\n closeOnClickOutside?: boolean\n closeOnEscape?: boolean\n closeOnSelect?: boolean\n highlightItemOnHover?: boolean\n side?: Side\n align?: Align\n sideOffset?: number\n alignOffset?: number\n avoidCollisions?: boolean\n collisionPadding?: number\n lockScroll?: boolean\n}\n\nconst {\n class: className,\n defaultOpen,\n defaultValue,\n defaultValues,\n closeOnClickOutside,\n closeOnEscape,\n closeOnSelect,\n highlightItemOnHover,\n side,\n align,\n sideOffset,\n alignOffset,\n avoidCollisions,\n collisionPadding,\n lockScroll,\n ...props\n} = Astro.props\n\nconst defaultValuesAttr =\n defaultValues === undefined ? undefined : JSON.stringify(defaultValues)\n---\n\n<div\n data-slot=\"dropdown-menu\"\n data-default-open={defaultOpen}\n data-default-value={defaultValue}\n data-default-values={defaultValuesAttr}\n data-close-on-click-outside={closeOnClickOutside}\n data-close-on-escape={closeOnEscape}\n data-close-on-select={closeOnSelect}\n data-highlight-item-on-hover={highlightItemOnHover}\n data-side={side}\n data-align={align}\n data-side-offset={sideOffset}\n data-align-offset={alignOffset}\n data-avoid-collisions={avoidCollisions}\n data-collision-padding={collisionPadding}\n data-lock-scroll={lockScroll}\n class={className}\n {...props}\n>\n <slot />\n</div>\n\n<script>\n import { create } from \"@data-slot/dropdown-menu\"\n\n create()\n</script>\n",
|
|
14
12
|
"type": "registry:ui"
|
|
15
13
|
},
|
|
16
14
|
{
|
|
@@ -20,22 +18,22 @@
|
|
|
20
18
|
},
|
|
21
19
|
{
|
|
22
20
|
"path": "src/components/ui/dropdown-menu/dropdown-menu-content.astro",
|
|
23
|
-
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\nimport type { Align, Side } from \"@data-slot/dropdown-menu\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype Props = HTMLAttributes<\"div\"> & {\n side?: Side\n align?: Align\n sideOffset?: number\n alignOffset?: number\n avoidCollisions?: boolean\n collisionPadding?: number\n}\n\nconst {\n class: className,\n hidden = true,\n side
|
|
21
|
+
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\nimport type { Align, Side } from \"@data-slot/dropdown-menu\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype Props = HTMLAttributes<\"div\"> & {\n side?: Side\n align?: Align\n sideOffset?: number\n alignOffset?: number\n avoidCollisions?: boolean\n collisionPadding?: number\n}\n\nconst {\n class: className,\n hidden = true,\n side,\n align,\n sideOffset,\n alignOffset,\n avoidCollisions,\n collisionPadding,\n ...props\n} = Astro.props\n---\n\n<div data-slot=\"dropdown-menu-portal\">\n <div\n data-slot=\"dropdown-menu-positioner\"\n data-side={side}\n data-align={align}\n data-side-offset={sideOffset}\n data-align-offset={alignOffset}\n data-avoid-collisions={avoidCollisions}\n data-collision-padding={collisionPadding}\n class=\"isolate z-50 outline-none\"\n >\n <div\n data-slot=\"dropdown-menu-content\"\n data-side={side}\n data-align={align}\n data-side-offset={sideOffset}\n data-align-offset={alignOffset}\n data-avoid-collisions={avoidCollisions}\n data-collision-padding={collisionPadding}\n hidden={hidden}\n class={cn(\n \"bg-popover text-popover-foreground ring-foreground/10 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 max-h-(--available-height) w-(--anchor-width) min-w-32 origin-(--transform-origin) overflow-x-hidden overflow-y-auto rounded-md p-1 shadow-md ring-1 duration-100 outline-none data-closed:overflow-hidden\",\n className\n )}\n {...props}\n >\n <slot />\n </div>\n </div>\n</div>\n",
|
|
24
22
|
"type": "registry:ui"
|
|
25
23
|
},
|
|
26
24
|
{
|
|
27
25
|
"path": "src/components/ui/dropdown-menu/dropdown-menu-item.astro",
|
|
28
|
-
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype Props = HTMLAttributes<\"button\"> & {\n disabled?: boolean\n variant?: \"default\" | \"destructive\"\n inset?: boolean\n}\n\nconst {\n class: className,\n type = \"button\",\n disabled,\n variant,\n inset,\n ...props\n} = Astro.props\n---\n\n<button\n data-slot=\"dropdown-menu-item\"\n data-disabled={disabled}\n data-variant={variant}\n data-inset={inset}\n disabled={disabled ? true : undefined}\n type={type}\n class={cn(\n \"group/dropdown-menu-item data-highlighted:bg-accent data-highlighted:text-accent-foreground not-data-[variant=destructive]:data-highlighted:**:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:data-highlighted:bg-destructive/10 data-[variant=destructive]:data-highlighted:text-destructive data-[variant=destructive]:*:[svg]:text-destructive relative flex w-full cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-
|
|
26
|
+
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype Props = HTMLAttributes<\"button\"> & {\n disabled?: boolean\n variant?: \"default\" | \"destructive\"\n inset?: boolean\n}\n\nconst {\n class: className,\n type = \"button\",\n disabled,\n variant,\n inset,\n ...props\n} = Astro.props\n---\n\n<button\n data-slot=\"dropdown-menu-item\"\n data-disabled={disabled}\n data-variant={variant}\n data-inset={inset}\n disabled={disabled ? true : undefined}\n type={type}\n class={cn(\n \"group/dropdown-menu-item data-[highlighted]:bg-accent data-[highlighted]:text-accent-foreground not-data-[variant=destructive]:data-[highlighted]:**:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:data-[highlighted]:bg-destructive/10 data-[variant=destructive]:data-[highlighted]:text-destructive dark:data-[variant=destructive]:data-[highlighted]:bg-destructive/20 data-[variant=destructive]:*:[svg]:text-destructive relative flex w-full cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4\",\n className\n )}\n {...props}\n>\n <slot />\n</button>\n",
|
|
29
27
|
"type": "registry:ui"
|
|
30
28
|
},
|
|
31
29
|
{
|
|
32
30
|
"path": "src/components/ui/dropdown-menu/dropdown-menu-radio-item.astro",
|
|
33
|
-
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\
|
|
31
|
+
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\nimport CheckIcon from \"@lucide/astro/icons/check\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype Props = HTMLAttributes<\"button\"> & {\n value: string\n defaultChecked?: boolean\n disabled?: boolean\n variant?: \"default\" | \"destructive\"\n inset?: boolean\n}\n\nconst {\n class: className,\n type = \"button\",\n value,\n defaultChecked,\n disabled,\n variant,\n inset,\n ...props\n} = Astro.props\n---\n\n<button\n data-slot=\"dropdown-menu-radio-item\"\n data-value={value}\n data-default-checked={defaultChecked}\n data-disabled={disabled}\n data-variant={variant}\n data-inset={inset}\n disabled={disabled ? true : undefined}\n type={type}\n class={cn(\n \"group/dropdown-menu-radio-item data-[highlighted]:bg-accent data-[highlighted]:text-accent-foreground data-[highlighted]:**:text-accent-foreground relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4\",\n className\n )}\n {...props}\n>\n <span\n data-slot=\"dropdown-menu-radio-item-indicator\"\n class=\"pointer-events-none absolute right-2 flex items-center justify-center\"\n >\n <CheckIcon\n class=\"opacity-0 group-data-[checked]/dropdown-menu-radio-item:opacity-100\"\n />\n </span>\n <slot />\n</button>\n",
|
|
34
32
|
"type": "registry:ui"
|
|
35
33
|
},
|
|
36
34
|
{
|
|
37
35
|
"path": "src/components/ui/dropdown-menu/dropdown-menu-checkbox-item.astro",
|
|
38
|
-
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\
|
|
36
|
+
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\nimport CheckIcon from \"@lucide/astro/icons/check\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype Props = HTMLAttributes<\"button\"> & {\n value: string\n defaultChecked?: boolean\n disabled?: boolean\n variant?: \"default\" | \"destructive\"\n inset?: boolean\n}\n\nconst {\n class: className,\n type = \"button\",\n value,\n defaultChecked,\n disabled,\n variant,\n inset,\n ...props\n} = Astro.props\n---\n\n<button\n data-slot=\"dropdown-menu-checkbox-item\"\n data-value={value}\n data-default-checked={defaultChecked}\n data-disabled={disabled}\n data-variant={variant}\n data-inset={inset}\n disabled={disabled ? true : undefined}\n type={type}\n class={cn(\n \"group/dropdown-menu-checkbox-item data-[highlighted]:bg-accent data-[highlighted]:text-accent-foreground data-[highlighted]:**:text-accent-foreground relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4\",\n className\n )}\n {...props}\n>\n <span\n data-slot=\"dropdown-menu-checkbox-item-indicator\"\n class=\"pointer-events-none absolute right-2 flex items-center justify-center\"\n >\n <CheckIcon\n class=\"opacity-0 group-data-[checked]/dropdown-menu-checkbox-item:opacity-100\"\n />\n </span>\n <slot />\n</button>\n",
|
|
39
37
|
"type": "registry:ui"
|
|
40
38
|
},
|
|
41
39
|
{
|
|
@@ -45,7 +43,7 @@
|
|
|
45
43
|
},
|
|
46
44
|
{
|
|
47
45
|
"path": "src/components/ui/dropdown-menu/dropdown-menu-label.astro",
|
|
48
|
-
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype Props = HTMLAttributes<\"div\"> & {\n inset?: boolean\n}\n\nconst { class: className, inset, ...props } = Astro.props\n---\n\n<div\n data-slot=\"dropdown-menu-label\"\n data-inset={inset}\n class={cn(\n \"text-muted-foreground px-2 py-1.5 text-xs font-medium data-inset:pl-8\",\n className\n )}\n {...props}\n>\n <slot />\n</div>\n",
|
|
46
|
+
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype Props = HTMLAttributes<\"div\"> & {\n inset?: boolean\n}\n\nconst { class: className, inset, ...props } = Astro.props\n---\n\n<div\n data-slot=\"dropdown-menu-label\"\n data-inset={inset}\n class={cn(\n \"text-muted-foreground px-2 py-1.5 text-xs font-medium data-[inset]:pl-8\",\n className\n )}\n {...props}\n>\n <slot />\n</div>\n",
|
|
49
47
|
"type": "registry:ui"
|
|
50
48
|
},
|
|
51
49
|
{
|
|
@@ -55,7 +53,7 @@
|
|
|
55
53
|
},
|
|
56
54
|
{
|
|
57
55
|
"path": "src/components/ui/dropdown-menu/dropdown-menu-shortcut.astro",
|
|
58
|
-
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype Props = HTMLAttributes<\"span\">\n\nconst { class: className, ...props } = Astro.props\n---\n\n<span\n data-slot=\"dropdown-menu-shortcut\"\n class={cn(\n \"text-muted-foreground group-data-highlighted/dropdown-menu-item:text-accent-foreground ml-auto text-xs tracking-widest\",\n className\n )}\n {...props}\n>\n <slot />\n</span>\n",
|
|
56
|
+
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype Props = HTMLAttributes<\"span\">\n\nconst { class: className, ...props } = Astro.props\n---\n\n<span\n data-slot=\"dropdown-menu-shortcut\"\n class={cn(\n \"text-muted-foreground group-data-[highlighted]/dropdown-menu-item:text-accent-foreground ml-auto text-xs tracking-widest\",\n className\n )}\n {...props}\n>\n <slot />\n</span>\n",
|
|
59
57
|
"type": "registry:ui"
|
|
60
58
|
},
|
|
61
59
|
{
|
package/public/r/features-1.json
CHANGED
|
@@ -1,15 +1,17 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
3
|
"name": "features-1",
|
|
4
|
+
"dependencies": [
|
|
5
|
+
"@lucide/astro"
|
|
6
|
+
],
|
|
4
7
|
"registryDependencies": [
|
|
5
8
|
"@fulldev/button",
|
|
6
|
-
"@fulldev/section"
|
|
7
|
-
"@fulldev/icon"
|
|
9
|
+
"@fulldev/section"
|
|
8
10
|
],
|
|
9
11
|
"files": [
|
|
10
12
|
{
|
|
11
13
|
"path": "src/components/blocks/features-1.astro",
|
|
12
|
-
"content": "---\nimport { cn } from \"@/lib/utils\"\nimport { Button } from \"@/components/ui/button\"\nimport { Icon } from \"@/components/ui/icon\"\nimport { Section, SectionContainer } from \"@/components/ui/section\"\n\ntype Props = {\n class?: string\n title: string\n description: string\n buttons?: {\n label: string\n href: string\n variant?: \"default\" | \"outline\" | \"secondary\" | \"ghost\"\n }[]\n features: {\n title: string\n description: string\n icon: string\n href?: string\n linkText?: string\n }[]\n}\n\nconst { class: className, title, description, buttons, features } = Astro.props\n---\n\n<Section class={cn(\"\", className)}>\n <SectionContainer class=\"items-center gap-6 text-center\">\n <div class=\"flex max-w-2xl flex-col items-center gap-4\">\n <h2\n class=\"text-foreground text-3xl font-semibold tracking-tight text-balance sm:text-4xl\"\n >\n {title}\n </h2>\n <p\n class=\"text-muted-foreground max-w-2xl text-lg leading-relaxed text-balance\"\n >\n {description}\n </p>\n </div>\n {\n buttons?.length && (\n <div class=\"flex flex-wrap justify-center gap-3\">\n {buttons.map(({ href, label, ...button }, index) => (\n <Button\n as=\"a\"\n href={href}\n variant={button.variant ?? (index === 0 ? \"default\" : \"outline\")}\n {...button}\n >\n {label}\n </Button>\n ))}\n </div>\n )\n }\n </SectionContainer>\n <SectionContainer>\n <div class=\"grid gap-6 sm:grid-cols-2\">\n {\n features.map((feature) => (\n <div class=\"group/feature hover:bg-muted/40 flex flex-col gap-4 rounded-xl border p-6 transition-colors\">\n <div class=\"bg-primary/10 text-primary flex size-10 items-center justify-center rounded-lg\">\n <Icon name={feature.icon} class=\"size-5\" />\n </div>\n <div class=\"flex flex-col gap-1.5\">\n <h3 class=\"text-foreground text-base font-medium\">\n {feature.title}\n </h3>\n <p class=\"text-muted-foreground text-sm leading-relaxed\">\n {feature.description}\n </p>\n </div>\n {feature.href && feature.linkText && (\n <a\n href={feature.href}\n class=\"text-primary mt-auto inline-flex items-center gap-1 text-sm font-medium hover:underline\"\n >\n {feature.linkText}\n <
|
|
14
|
+
"content": "---\nimport ArrowRightIcon from \"@lucide/astro/icons/arrow-right\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Button } from \"@/components/ui/button\"\nimport { Icon } from \"@/components/ui/icon\"\nimport { Section, SectionContainer } from \"@/components/ui/section\"\n\ntype Props = {\n class?: string\n title: string\n description: string\n buttons?: {\n label: string\n href: string\n variant?: \"default\" | \"outline\" | \"secondary\" | \"ghost\"\n }[]\n features: {\n title: string\n description: string\n icon: string\n href?: string\n linkText?: string\n }[]\n}\n\nconst { class: className, title, description, buttons, features } = Astro.props\n---\n\n<Section class={cn(\"\", className)}>\n <SectionContainer class=\"items-center gap-6 text-center\">\n <div class=\"flex max-w-2xl flex-col items-center gap-4\">\n <h2\n class=\"text-foreground text-3xl font-semibold tracking-tight text-balance sm:text-4xl\"\n >\n {title}\n </h2>\n <p\n class=\"text-muted-foreground max-w-2xl text-lg leading-relaxed text-balance\"\n >\n {description}\n </p>\n </div>\n {\n buttons?.length && (\n <div class=\"flex flex-wrap justify-center gap-3\">\n {buttons.map(({ href, label, ...button }, index) => (\n <Button\n as=\"a\"\n href={href}\n variant={button.variant ?? (index === 0 ? \"default\" : \"outline\")}\n {...button}\n >\n {label}\n </Button>\n ))}\n </div>\n )\n }\n </SectionContainer>\n <SectionContainer>\n <div class=\"grid gap-6 sm:grid-cols-2\">\n {\n features.map((feature) => (\n <div class=\"group/feature hover:bg-muted/40 flex flex-col gap-4 rounded-xl border p-6 transition-colors\">\n <div class=\"bg-primary/10 text-primary flex size-10 items-center justify-center rounded-lg\">\n <Icon name={feature.icon} class=\"size-5\" />\n </div>\n <div class=\"flex flex-col gap-1.5\">\n <h3 class=\"text-foreground text-base font-medium\">\n {feature.title}\n </h3>\n <p class=\"text-muted-foreground text-sm leading-relaxed\">\n {feature.description}\n </p>\n </div>\n {feature.href && feature.linkText && (\n <a\n href={feature.href}\n class=\"text-primary mt-auto inline-flex items-center gap-1 text-sm font-medium hover:underline\"\n >\n {feature.linkText}\n <ArrowRightIcon class=\"size-3.5\" />\n </a>\n )}\n </div>\n ))\n }\n </div>\n </SectionContainer>\n</Section>\n",
|
|
13
15
|
"type": "registry:block"
|
|
14
16
|
}
|
|
15
17
|
],
|
package/public/r/features-2.json
CHANGED
|
@@ -1,15 +1,17 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
3
|
"name": "features-2",
|
|
4
|
+
"dependencies": [
|
|
5
|
+
"@lucide/astro"
|
|
6
|
+
],
|
|
4
7
|
"registryDependencies": [
|
|
5
8
|
"@fulldev/button",
|
|
6
|
-
"@fulldev/section"
|
|
7
|
-
"@fulldev/icon"
|
|
9
|
+
"@fulldev/section"
|
|
8
10
|
],
|
|
9
11
|
"files": [
|
|
10
12
|
{
|
|
11
13
|
"path": "src/components/blocks/features-2.astro",
|
|
12
|
-
"content": "---\nimport { cn } from \"@/lib/utils\"\nimport { Button } from \"@/components/ui/button\"\nimport { Icon } from \"@/components/ui/icon\"\nimport { Section, SectionContainer } from \"@/components/ui/section\"\n\ntype Props = {\n class?: string\n title: string\n description: string\n buttons?: {\n label: string\n href: string\n variant?: \"default\" | \"outline\" | \"secondary\" | \"ghost\"\n }[]\n features: {\n title: string\n description: string\n icon: string\n }[]\n}\n\nconst { class: className, title, description, buttons, features } = Astro.props\n---\n\n<Section class={cn(\"\", className)}>\n <SectionContainer class=\"items-center gap-6 text-center\">\n <div class=\"flex max-w-2xl flex-col items-center gap-4\">\n <h2\n class=\"text-foreground text-3xl font-semibold tracking-tight text-balance sm:text-4xl\"\n >\n {title}\n </h2>\n <p\n class=\"text-muted-foreground max-w-2xl text-lg leading-relaxed text-balance\"\n >\n {description}\n </p>\n </div>\n {\n buttons?.length && (\n <div class=\"flex flex-wrap justify-center gap-3\">\n {buttons.map(({ href, label, ...button }, index) => (\n <Button\n as=\"a\"\n href={href}\n variant={button.variant ?? (index === 0 ? \"default\" : \"outline\")}\n {...button}\n >\n {label}\n </Button>\n ))}\n </div>\n )\n }\n </SectionContainer>\n <SectionContainer>\n <div
|
|
14
|
+
"content": "---\nimport { cn } from \"@/lib/utils\"\nimport { Button } from \"@/components/ui/button\"\nimport { Icon } from \"@/components/ui/icon\"\nimport { Section, SectionContainer } from \"@/components/ui/section\"\n\ntype Props = {\n class?: string\n title: string\n description: string\n buttons?: {\n label: string\n href: string\n variant?: \"default\" | \"outline\" | \"secondary\" | \"ghost\"\n }[]\n features: {\n title: string\n description: string\n icon: string\n }[]\n}\n\nconst { class: className, title, description, buttons, features } = Astro.props\n---\n\n<Section class={cn(\"\", className)}>\n <SectionContainer class=\"items-center gap-6 text-center\">\n <div class=\"flex max-w-2xl flex-col items-center gap-4\">\n <h2\n class=\"text-foreground text-3xl font-semibold tracking-tight text-balance sm:text-4xl\"\n >\n {title}\n </h2>\n <p\n class=\"text-muted-foreground max-w-2xl text-lg leading-relaxed text-balance\"\n >\n {description}\n </p>\n </div>\n {\n buttons?.length && (\n <div class=\"flex flex-wrap justify-center gap-3\">\n {buttons.map(({ href, label, ...button }, index) => (\n <Button\n as=\"a\"\n href={href}\n variant={button.variant ?? (index === 0 ? \"default\" : \"outline\")}\n {...button}\n >\n {label}\n </Button>\n ))}\n </div>\n )\n }\n </SectionContainer>\n <SectionContainer>\n <div\n class=\"ring-foreground/10 bg-border grid gap-px overflow-hidden rounded-xl ring-1 ring-inset sm:grid-cols-2 lg:grid-cols-3\"\n >\n {\n features.map((feature) => (\n <div class=\"bg-background group/feature hover:bg-accent/30 relative flex flex-col items-center gap-4 p-7 text-center transition-colors\">\n <div class=\"bg-primary/10 text-primary ring-primary/15 flex size-10 items-center justify-center rounded-lg ring-1 transition-transform ring-inset group-hover/feature:scale-105\">\n <Icon name={feature.icon} class=\"size-5\" />\n </div>\n <h3 class=\"text-foreground text-base font-medium tracking-tight text-balance\">\n {feature.title}\n </h3>\n <p class=\"text-muted-foreground text-sm leading-relaxed text-balance\">\n {feature.description}\n </p>\n </div>\n ))\n }\n </div>\n </SectionContainer>\n</Section>\n",
|
|
13
15
|
"type": "registry:block"
|
|
14
16
|
}
|
|
15
17
|
],
|
package/public/r/features-4.json
CHANGED
|
@@ -1,15 +1,17 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
3
|
"name": "features-4",
|
|
4
|
+
"dependencies": [
|
|
5
|
+
"@lucide/astro"
|
|
6
|
+
],
|
|
4
7
|
"registryDependencies": [
|
|
5
8
|
"@fulldev/button",
|
|
6
|
-
"@fulldev/section"
|
|
7
|
-
"@fulldev/icon"
|
|
9
|
+
"@fulldev/section"
|
|
8
10
|
],
|
|
9
11
|
"files": [
|
|
10
12
|
{
|
|
11
13
|
"path": "src/components/blocks/features-4.astro",
|
|
12
|
-
"content": "---\nimport { cn } from \"@/lib/utils\"\nimport { Button } from \"@/components/ui/button\"\nimport { Icon } from \"@/components/ui/icon\"\nimport { Section, SectionContainer } from \"@/components/ui/section\"\n\ntype Props = {\n class?: string\n title: string\n description: string\n buttons?: {\n label: string\n href: string\n variant?: \"default\" | \"outline\" | \"secondary\" | \"ghost\"\n }[]\n features: {\n title: string\n description: string\n icon: string\n href?: string\n linkText?: string\n }[]\n}\n\nconst { class: className, title, description, buttons, features } = Astro.props\n---\n\n<Section class={cn(\"\", className)}>\n <SectionContainer>\n <div class=\"grid gap-12 lg:grid-cols-[1fr_2fr] lg:items-start\">\n <div class=\"lg:sticky lg:top-28\">\n <h2\n class=\"text-foreground text-3xl font-semibold tracking-tight text-balance sm:text-4xl\"\n >\n {title}\n </h2>\n <p\n class=\"text-muted-foreground mt-4 text-base leading-relaxed text-balance\"\n >\n {description}\n </p>\n {\n buttons?.length && (\n <div class=\"mt-6 flex flex-wrap gap-3\">\n {buttons.map(({ href, label, ...button }, index) => (\n <Button\n as=\"a\"\n href={href}\n variant={\n button.variant ?? (index === 0 ? \"default\" : \"outline\")\n }\n {...button}\n >\n {label}\n </Button>\n ))}\n </div>\n )\n }\n </div>\n <div class=\"grid gap-6 sm:grid-cols-2\">\n {\n features.map((feature) => (\n <div class=\"group/feature hover:bg-muted/40 flex flex-col gap-4 rounded-xl border p-6 transition-colors\">\n <div class=\"bg-primary/10 text-primary flex size-10 items-center justify-center rounded-lg\">\n <Icon name={feature.icon} class=\"size-5\" />\n </div>\n <div class=\"flex flex-col gap-1.5\">\n <h3 class=\"text-foreground text-base font-medium\">\n {feature.title}\n </h3>\n <p class=\"text-muted-foreground text-sm leading-relaxed\">\n {feature.description}\n </p>\n </div>\n {feature.href && feature.linkText && (\n <a\n href={feature.href}\n class=\"text-primary mt-auto inline-flex items-center gap-1 text-sm font-medium hover:underline\"\n >\n {feature.linkText}\n <
|
|
14
|
+
"content": "---\nimport ArrowRightIcon from \"@lucide/astro/icons/arrow-right\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Button } from \"@/components/ui/button\"\nimport { Icon } from \"@/components/ui/icon\"\nimport { Section, SectionContainer } from \"@/components/ui/section\"\n\ntype Props = {\n class?: string\n title: string\n description: string\n buttons?: {\n label: string\n href: string\n variant?: \"default\" | \"outline\" | \"secondary\" | \"ghost\"\n }[]\n features: {\n title: string\n description: string\n icon: string\n href?: string\n linkText?: string\n }[]\n}\n\nconst { class: className, title, description, buttons, features } = Astro.props\n---\n\n<Section class={cn(\"\", className)}>\n <SectionContainer>\n <div class=\"grid gap-12 lg:grid-cols-[1fr_2fr] lg:items-start\">\n <div class=\"lg:sticky lg:top-28\">\n <h2\n class=\"text-foreground text-3xl font-semibold tracking-tight text-balance sm:text-4xl\"\n >\n {title}\n </h2>\n <p\n class=\"text-muted-foreground mt-4 text-base leading-relaxed text-balance\"\n >\n {description}\n </p>\n {\n buttons?.length && (\n <div class=\"mt-6 flex flex-wrap gap-3\">\n {buttons.map(({ href, label, ...button }, index) => (\n <Button\n as=\"a\"\n href={href}\n variant={\n button.variant ?? (index === 0 ? \"default\" : \"outline\")\n }\n {...button}\n >\n {label}\n </Button>\n ))}\n </div>\n )\n }\n </div>\n <div class=\"grid gap-6 sm:grid-cols-2\">\n {\n features.map((feature) => (\n <div class=\"group/feature hover:bg-muted/40 flex flex-col gap-4 rounded-xl border p-6 transition-colors\">\n <div class=\"bg-primary/10 text-primary flex size-10 items-center justify-center rounded-lg\">\n <Icon name={feature.icon} class=\"size-5\" />\n </div>\n <div class=\"flex flex-col gap-1.5\">\n <h3 class=\"text-foreground text-base font-medium\">\n {feature.title}\n </h3>\n <p class=\"text-muted-foreground text-sm leading-relaxed\">\n {feature.description}\n </p>\n </div>\n {feature.href && feature.linkText && (\n <a\n href={feature.href}\n class=\"text-primary mt-auto inline-flex items-center gap-1 text-sm font-medium hover:underline\"\n >\n {feature.linkText}\n <ArrowRightIcon class=\"size-3.5\" />\n </a>\n )}\n </div>\n ))\n }\n </div>\n </div>\n </SectionContainer>\n</Section>\n",
|
|
13
15
|
"type": "registry:block"
|
|
14
16
|
}
|
|
15
17
|
],
|
package/public/r/features-5.json
CHANGED
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
3
|
"name": "features-5",
|
|
4
|
+
"dependencies": [
|
|
5
|
+
"@lucide/astro"
|
|
6
|
+
],
|
|
4
7
|
"registryDependencies": [
|
|
5
8
|
"@fulldev/button",
|
|
6
|
-
"@fulldev/section"
|
|
7
|
-
"@fulldev/icon"
|
|
9
|
+
"@fulldev/section"
|
|
8
10
|
],
|
|
9
11
|
"files": [
|
|
10
12
|
{
|
package/public/r/field.json
CHANGED
|
@@ -21,11 +21,6 @@
|
|
|
21
21
|
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype Props = HTMLAttributes<\"p\">\n\nconst { class: className, ...props } = Astro.props\n---\n\n<p\n data-slot=\"field-description\"\n class={cn(\n \"text-muted-foreground text-left text-sm leading-normal font-normal group-has-data-horizontal/field:text-balance [[data-variant=legend]+&]:-mt-1.5\",\n \"last:mt-0 nth-last-2:-mt-1\",\n \"[&>a:hover]:text-primary [&>a]:underline [&>a]:underline-offset-4\",\n className\n )}\n {...props}\n>\n <slot />\n</p>\n",
|
|
22
22
|
"type": "registry:ui"
|
|
23
23
|
},
|
|
24
|
-
{
|
|
25
|
-
"path": "src/components/ui/field/field-error.astro",
|
|
26
|
-
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype Props = HTMLAttributes<\"div\"> & {\n errors?: Array<{ message?: string } | undefined>\n}\n\nconst { class: className, errors, ...props } = Astro.props\n\nconst messages = [\n ...new Set(\n (errors ?? [])\n .map((error) => error?.message?.trim())\n .filter((message): message is string => Boolean(message))\n ),\n]\n\nconst hasDefaultSlot = Astro.slots.has(\"default\")\nconst shouldRender = hasDefaultSlot || messages.length > 0\n---\n\n{\n shouldRender && (\n <div\n role=\"alert\"\n data-slot=\"field-error\"\n class={cn(\"text-destructive text-sm font-normal\", className)}\n {...props}\n >\n {hasDefaultSlot ? (\n <slot />\n ) : messages.length === 1 ? (\n messages[0]\n ) : (\n <ul class=\"ml-4 flex list-disc flex-col gap-1\">\n {messages.map((message) => (\n <li>{message}</li>\n ))}\n </ul>\n )}\n </div>\n )\n}\n",
|
|
27
|
-
"type": "registry:ui"
|
|
28
|
-
},
|
|
29
24
|
{
|
|
30
25
|
"path": "src/components/ui/field/field-group.astro",
|
|
31
26
|
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype Props = HTMLAttributes<\"div\">\n\nconst { class: className, ...props } = Astro.props\n---\n\n<div\n data-slot=\"field-group\"\n class={cn(\n \"group/field-group @container/field-group flex w-full flex-col gap-7 data-[slot=checkbox-group]:gap-3 *:data-[slot=field-group]:gap-4\",\n className\n )}\n {...props}\n>\n <slot />\n</div>\n",
|
|
@@ -33,7 +28,7 @@
|
|
|
33
28
|
},
|
|
34
29
|
{
|
|
35
30
|
"path": "src/components/ui/field/field-label.astro",
|
|
36
|
-
"content": "---\nimport type { ComponentProps } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Label } from \"@/components/ui/label\"\n\ntype Props = ComponentProps<typeof Label>\n\nconst { class: className, ...props } = Astro.props\n---\n\n<Label\n data-slot=\"field-label\"\n class={cn(\n \"has-data-checked:bg-primary/5 has-data-checked:border-primary/30 dark:has-data-checked:border-primary/20 dark:has-data-checked:bg-primary/10 group/field-label peer/field-label flex w-fit gap-2 leading-snug group-data-[disabled=true]/field:opacity-50 has-[>[data-slot=field]]:rounded-md has-[>[data-slot=field]]:border *:data-[slot=field]:p-3\",\n \"has-[>[data-slot=field]]:w-full has-[>[data-slot=field]]:flex-col\",\n className\n )}\n {...props}\n>\n <slot />\n</Label>\n",
|
|
31
|
+
"content": "---\nimport type { ComponentProps } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Label } from \"@/components/ui/label\"\n\ntype Props = ComponentProps<typeof Label>\n\nconst { class: className, ...props } = Astro.props\n---\n\n<Label\n data-slot=\"field-label\"\n class={cn(\n \"has-data-checked:bg-primary/5 has-data-checked:border-primary/30 dark:has-data-checked:border-primary/20 dark:has-data-checked:bg-primary/10 group/field-label peer/field-label has-[>[data-slot=field]]:not-has-[:disabled,[data-disabled]]:hover:bg-muted/50 has-[>[data-slot=field]]:has-[:focus-visible]:border-ring has-[>[data-slot=field]]:has-[:focus-visible]:ring-ring/50 flex w-fit gap-2 leading-snug group-data-[disabled=true]/field:opacity-50 has-[>[data-slot=field]]:rounded-md has-[>[data-slot=field]]:border has-[>[data-slot=field]]:has-[:focus-visible]:ring-3 *:data-[slot=field]:p-3\",\n \"has-[>[data-slot=field]]:w-full has-[>[data-slot=field]]:flex-col\",\n className\n )}\n {...props}\n>\n <slot />\n</Label>\n",
|
|
37
32
|
"type": "registry:ui"
|
|
38
33
|
},
|
|
39
34
|
{
|
|
@@ -53,7 +48,7 @@
|
|
|
53
48
|
},
|
|
54
49
|
{
|
|
55
50
|
"path": "src/components/ui/field/field-title.astro",
|
|
56
|
-
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype Props = HTMLAttributes<\"div\">\n\nconst { class: className, ...props } = Astro.props\n---\n\n<div\n data-slot=\"field-label\"\n class={cn(\n \"flex w-fit items-center gap-2 text-sm
|
|
51
|
+
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype Props = HTMLAttributes<\"div\">\n\nconst { class: className, ...props } = Astro.props\n---\n\n<div\n data-slot=\"field-label\"\n class={cn(\n \"flex w-fit items-center gap-2 text-sm font-medium group-data-[disabled=true]/field:opacity-50\",\n className\n )}\n {...props}\n>\n <slot />\n</div>\n",
|
|
57
52
|
"type": "registry:ui"
|
|
58
53
|
},
|
|
59
54
|
{
|
package/public/r/footer-1.json
CHANGED
|
@@ -1,16 +1,18 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
3
|
"name": "footer-1",
|
|
4
|
+
"dependencies": [
|
|
5
|
+
"simple-icons-astro"
|
|
6
|
+
],
|
|
4
7
|
"registryDependencies": [
|
|
5
8
|
"@fulldev/logo",
|
|
6
9
|
"@fulldev/section",
|
|
7
|
-
"@fulldev/separator"
|
|
8
|
-
"@fulldev/icon"
|
|
10
|
+
"@fulldev/separator"
|
|
9
11
|
],
|
|
10
12
|
"files": [
|
|
11
13
|
{
|
|
12
14
|
"path": "src/components/blocks/footer-1.astro",
|
|
13
|
-
"content": "---\nimport
|
|
15
|
+
"content": "---\nimport Discord from \"simple-icons-astro/Discord\"\nimport Github from \"simple-icons-astro/Github\"\nimport X from \"simple-icons-astro/X\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Logo, LogoText } from \"@/components/ui/logo\"\nimport { Section, SectionContainer } from \"@/components/ui/section\"\nimport { Separator } from \"@/components/ui/separator\"\n\ntype Props = {\n class?: string\n brandName: string\n brandHref: string\n description: string\n socials?: {\n label: string\n href: string\n icon: string\n }[]\n columns: {\n title: string\n links: {\n label: string\n href: string\n }[]\n }[]\n copyright: string\n}\n\nconst {\n class: className,\n brandName,\n brandHref,\n description,\n socials,\n columns,\n copyright,\n} = Astro.props\n\nconst iconMap: Record<string, any> = {\n github: Github,\n discord: Discord,\n x: X,\n}\n---\n\n<footer class={cn(\"\", className)}>\n <Section class=\"py-16 lg:py-20\">\n <SectionContainer>\n <div class=\"grid gap-10 lg:grid-cols-[1fr_2fr]\">\n <div class=\"flex flex-col gap-5\">\n <Logo href={brandHref}>\n <LogoText>{brandName}</LogoText>\n </Logo>\n <p class=\"text-muted-foreground max-w-xs text-sm leading-relaxed\">\n {description}\n </p>\n {\n socials && socials.length > 0 && (\n <div class=\"flex items-center gap-3\">\n {socials.map((social) => {\n const IconComp = iconMap[social.icon]\n return (\n <a\n href={social.href}\n class=\"text-muted-foreground hover:text-foreground transition-colors\"\n aria-label={social.label}\n target=\"_blank\"\n rel=\"noreferrer\"\n >\n {IconComp && (\n <IconComp class=\"size-4\" fill=\"currentColor\" />\n )}\n </a>\n )\n })}\n </div>\n )\n }\n </div>\n <div class=\"grid gap-8 sm:grid-cols-3\">\n {\n columns.map((column) => (\n <div class=\"flex flex-col gap-3\">\n <p class=\"text-sm font-medium\">{column.title}</p>\n <ul class=\"flex flex-col gap-2.5\">\n {column.links.map((link) => (\n <li>\n <a\n href={link.href}\n class=\"text-muted-foreground hover:text-foreground text-sm transition-colors\"\n >\n {link.label}\n </a>\n </li>\n ))}\n </ul>\n </div>\n ))\n }\n </div>\n </div>\n <Separator />\n <p class=\"text-muted-foreground text-sm\">{copyright}</p>\n </SectionContainer>\n </Section>\n</footer>\n",
|
|
14
16
|
"type": "registry:block"
|
|
15
17
|
}
|
|
16
18
|
],
|
package/public/r/footer-2.json
CHANGED
|
@@ -1,16 +1,18 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
3
|
"name": "footer-2",
|
|
4
|
+
"dependencies": [
|
|
5
|
+
"simple-icons-astro"
|
|
6
|
+
],
|
|
4
7
|
"registryDependencies": [
|
|
5
8
|
"@fulldev/logo",
|
|
6
9
|
"@fulldev/section",
|
|
7
|
-
"@fulldev/separator"
|
|
8
|
-
"@fulldev/icon"
|
|
10
|
+
"@fulldev/separator"
|
|
9
11
|
],
|
|
10
12
|
"files": [
|
|
11
13
|
{
|
|
12
14
|
"path": "src/components/blocks/footer-2.astro",
|
|
13
|
-
"content": "---\nimport
|
|
15
|
+
"content": "---\nimport Discord from \"simple-icons-astro/Discord\"\nimport Github from \"simple-icons-astro/Github\"\nimport X from \"simple-icons-astro/X\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Logo, LogoText } from \"@/components/ui/logo\"\nimport { Section, SectionContainer } from \"@/components/ui/section\"\nimport { Separator } from \"@/components/ui/separator\"\n\ntype Props = {\n class?: string\n brandName: string\n brandHref: string\n description: string\n links?: {\n label: string\n href: string\n }[]\n socials?: {\n label: string\n href: string\n icon: string\n }[]\n copyright: string\n}\n\nconst {\n class: className,\n brandName,\n brandHref,\n description,\n links,\n socials,\n copyright,\n} = Astro.props\n\nconst iconMap: Record<string, any> = {\n github: Github,\n discord: Discord,\n x: X,\n}\n---\n\n<footer class={cn(\"\", className)}>\n <Section class=\"py-12 lg:py-16\">\n <SectionContainer class=\"items-center text-center\">\n <Logo href={brandHref}>\n <LogoText>{brandName}</LogoText>\n </Logo>\n <p class=\"text-muted-foreground max-w-md text-sm leading-relaxed\">\n {description}\n </p>\n {\n links && links.length > 0 && (\n <nav class=\"flex flex-wrap items-center justify-center gap-x-6 gap-y-2\">\n {links.map((link) => (\n <a\n href={link.href}\n class=\"text-muted-foreground hover:text-foreground text-sm transition-colors\"\n >\n {link.label}\n </a>\n ))}\n </nav>\n )\n }\n {\n socials && socials.length > 0 && (\n <div class=\"flex items-center justify-center gap-3\">\n {socials.map((social) => {\n const IconComp = iconMap[social.icon]\n return (\n <a\n href={social.href}\n class=\"text-muted-foreground hover:text-foreground transition-colors\"\n aria-label={social.label}\n target=\"_blank\"\n rel=\"noreferrer\"\n >\n {IconComp && <IconComp class=\"size-4\" fill=\"currentColor\" />}\n </a>\n )\n })}\n </div>\n )\n }\n <Separator />\n <p class=\"text-muted-foreground text-sm\">{copyright}</p>\n </SectionContainer>\n </Section>\n</footer>\n",
|
|
14
16
|
"type": "registry:block"
|
|
15
17
|
}
|
|
16
18
|
],
|
package/public/r/footer-3.json
CHANGED
|
@@ -1,16 +1,18 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
3
|
"name": "footer-3",
|
|
4
|
+
"dependencies": [
|
|
5
|
+
"simple-icons-astro"
|
|
6
|
+
],
|
|
4
7
|
"registryDependencies": [
|
|
5
8
|
"@fulldev/logo",
|
|
6
9
|
"@fulldev/section",
|
|
7
|
-
"@fulldev/separator"
|
|
8
|
-
"@fulldev/icon"
|
|
10
|
+
"@fulldev/separator"
|
|
9
11
|
],
|
|
10
12
|
"files": [
|
|
11
13
|
{
|
|
12
14
|
"path": "src/components/blocks/footer-3.astro",
|
|
13
|
-
"content": "---\nimport
|
|
15
|
+
"content": "---\nimport Discord from \"simple-icons-astro/Discord\"\nimport Github from \"simple-icons-astro/Github\"\nimport X from \"simple-icons-astro/X\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Logo, LogoText } from \"@/components/ui/logo\"\nimport { Section, SectionContainer } from \"@/components/ui/section\"\nimport { Separator } from \"@/components/ui/separator\"\n\ntype Props = {\n class?: string\n brandName: string\n brandHref: string\n description: string\n socials?: {\n label: string\n href: string\n icon: string\n }[]\n columns: {\n title: string\n links: {\n label: string\n href: string\n }[]\n }[]\n copyright: string\n bottomLinks?: {\n label: string\n href: string\n }[]\n}\n\nconst {\n class: className,\n brandName,\n brandHref,\n description,\n socials,\n columns,\n copyright,\n bottomLinks,\n} = Astro.props\n\nconst iconMap: Record<string, any> = {\n github: Github,\n discord: Discord,\n x: X,\n}\n---\n\n<footer class={cn(\"\", className)}>\n <Section class=\"py-16 lg:py-20\">\n <SectionContainer>\n <div class=\"grid gap-10 lg:grid-cols-[1fr_2fr]\">\n <div class=\"flex flex-col gap-5\">\n <Logo href={brandHref}>\n <LogoText>{brandName}</LogoText>\n </Logo>\n <p class=\"text-muted-foreground max-w-xs text-sm leading-relaxed\">\n {description}\n </p>\n {\n socials && socials.length > 0 && (\n <div class=\"flex items-center gap-3\">\n {socials.map((social) => {\n const IconComp = iconMap[social.icon]\n return (\n <a\n href={social.href}\n class=\"text-muted-foreground hover:text-foreground transition-colors\"\n aria-label={social.label}\n target=\"_blank\"\n rel=\"noreferrer\"\n >\n {IconComp && (\n <IconComp class=\"size-4\" fill=\"currentColor\" />\n )}\n </a>\n )\n })}\n </div>\n )\n }\n </div>\n <div class=\"grid gap-8 sm:grid-cols-3\">\n {\n columns.map((column) => (\n <div class=\"flex flex-col gap-3\">\n <p class=\"text-sm font-medium\">{column.title}</p>\n <ul class=\"flex flex-col gap-2.5\">\n {column.links.map((link) => (\n <li>\n <a\n href={link.href}\n class=\"text-muted-foreground hover:text-foreground text-sm transition-colors\"\n >\n {link.label}\n </a>\n </li>\n ))}\n </ul>\n </div>\n ))\n }\n </div>\n </div>\n <Separator />\n <div\n class=\"flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between\"\n >\n <p class=\"text-muted-foreground text-sm\">{copyright}</p>\n {\n bottomLinks && bottomLinks.length > 0 && (\n <nav class=\"flex flex-wrap items-center gap-x-5 gap-y-2\">\n {bottomLinks.map((link) => (\n <a\n href={link.href}\n class=\"text-muted-foreground hover:text-foreground text-sm transition-colors\"\n >\n {link.label}\n </a>\n ))}\n </nav>\n )\n }\n </div>\n </SectionContainer>\n </Section>\n</footer>\n",
|
|
14
16
|
"type": "registry:block"
|
|
15
17
|
}
|
|
16
18
|
],
|
package/public/r/header-1.json
CHANGED
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
"files": [
|
|
13
13
|
{
|
|
14
14
|
"path": "src/components/blocks/header-1.astro",
|
|
15
|
-
"content": "---\nimport { cn } from \"@/lib/utils\"\nimport { Button } from \"@/components/ui/button\"\nimport { Header, HeaderContainer, HeaderGroup } from \"@/components/ui/header\"\nimport { Icon } from \"@/components/ui/icon\"\nimport { Logo, LogoImage, LogoText } from \"@/components/ui/logo\"\nimport {\n NavigationMenu,\n NavigationMenuItem,\n NavigationMenuLink,\n NavigationMenuList,\n} from \"@/components/ui/navigation-menu\"\nimport {\n Sheet,\n SheetClose,\n SheetContent,\n SheetDescription,\n SheetHeader,\n SheetTitle,\n SheetTrigger,\n} from \"@/components/ui/sheet\"\n\ntype Props = {\n class?: string\n logo: {\n label: string\n href: string\n src?: any\n srcLight?: any\n srcDark?: any\n alt?: string\n }\n navigation: {\n label: string\n href: string\n
|
|
15
|
+
"content": "---\nimport { cn } from \"@/lib/utils\"\nimport { Button } from \"@/components/ui/button\"\nimport { Header, HeaderContainer, HeaderGroup } from \"@/components/ui/header\"\nimport { Icon } from \"@/components/ui/icon\"\nimport { Logo, LogoImage, LogoText } from \"@/components/ui/logo\"\nimport {\n NavigationMenu,\n NavigationMenuItem,\n NavigationMenuLink,\n NavigationMenuList,\n} from \"@/components/ui/navigation-menu\"\nimport {\n Sheet,\n SheetClose,\n SheetContent,\n SheetDescription,\n SheetHeader,\n SheetTitle,\n SheetTrigger,\n} from \"@/components/ui/sheet\"\n\ntype Props = {\n class?: string\n logo: {\n label: string\n href: string\n src?: any\n srcLight?: any\n srcDark?: any\n alt?: string\n }\n navigation: {\n label: string\n href: string\n links?: {\n label: string\n href: string\n }[]\n }[]\n buttons: {\n label: string\n href: string\n icon?: string\n variant?: \"default\" | \"outline\" | \"secondary\" | \"ghost\"\n }[]\n}\n\nconst { class: className, logo, navigation, buttons } = Astro.props\n---\n\n<Header class={cn(\"\", className)}>\n <HeaderContainer class=\"justify-between gap-4\">\n <HeaderGroup>\n <Logo href={logo.href}>\n <LogoImage\n src={logo.src}\n srcLight={logo.srcLight}\n srcDark={logo.srcDark}\n alt={logo.alt}\n />\n {logo.label && <LogoText>{logo.label}</LogoText>}\n </Logo>\n </HeaderGroup>\n <NavigationMenu class=\"hidden flex-none justify-start lg:flex\">\n <NavigationMenuList class=\"justify-start\">\n {\n navigation.map((item, index) => (\n <NavigationMenuItem value={`nav-${index}`}>\n <NavigationMenuLink href={item.href}>\n {item.label}\n </NavigationMenuLink>\n </NavigationMenuItem>\n ))\n }\n </NavigationMenuList>\n </NavigationMenu>\n <HeaderGroup class=\"ml-auto hidden flex-1 justify-end lg:flex\">\n <slot />\n {\n buttons.map(({ label, icon, ...button }) => (\n <Button\n as=\"a\"\n size={icon && !label ? \"icon-sm\" : \"sm\"}\n aria-label={label}\n target={button.href.startsWith(\"http\") ? \"_blank\" : undefined}\n rel={button.href.startsWith(\"http\") ? \"noreferrer\" : undefined}\n {...button}\n >\n {icon && <Icon name={icon} />}\n {label}\n </Button>\n ))\n }\n </HeaderGroup>\n <Sheet class=\"lg:hidden\">\n <SheetTrigger\n variant=\"ghost\"\n size=\"icon-sm\"\n class=\"ml-auto\"\n aria-label=\"Open menu\"\n >\n <Icon name=\"menu\" />\n </SheetTrigger>\n <SheetContent side=\"right\" class=\"p-0\">\n <SheetHeader class=\"sr-only\">\n <SheetTitle>Menu</SheetTitle>\n <SheetDescription>Site navigation and actions.</SheetDescription>\n </SheetHeader>\n <div class=\"flex h-full flex-col gap-6 px-4 py-12\">\n <nav aria-label=\"Main navigation\" class=\"flex flex-col gap-1\">\n {\n navigation.map((item) => (\n <SheetClose variant=\"ghost\" class=\"justify-start\">\n {item.label}\n </SheetClose>\n ))\n }\n </nav>\n <div class=\"mt-auto flex flex-col gap-2\">\n <slot />\n </div>\n </div>\n </SheetContent>\n </Sheet>\n </HeaderContainer>\n</Header>\n",
|
|
16
16
|
"type": "registry:block"
|
|
17
17
|
}
|
|
18
18
|
],
|
package/public/r/header.json
CHANGED
package/public/r/hero-13.json
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
"files": [
|
|
9
9
|
{
|
|
10
10
|
"path": "src/components/blocks/hero-13.astro",
|
|
11
|
-
"content": "---\nimport type { ImageMetadata } from \"astro\"\nimport { Image } from \"astro:assets\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Button } from \"@/components/ui/button\"\nimport { Section, SectionContainer } from \"@/components/ui/section\"\n\ntype Props = {\n class?: string\n title: string\n description: string\n buttons: {\n label: string\n href: string\n variant?: \"default\" | \"outline\" | \"secondary\" | \"ghost\"\n }[]\n image: {\n src: ImageMetadata\n alt: string\n }\n}\n\nconst { class: className, title, description, buttons, image } = Astro.props\n---\n\n<Section class={cn(\"\", className)}>\n <SectionContainer class=\"grid gap-12 lg:grid-cols-[1fr_3fr] lg:items-start\">\n <div class=\"flex flex-col gap-6 pt-8\">\n <div class=\"flex flex-col gap-4\">\n <h1\n class=\"text-foreground text-2xl leading-[1.2] font-semibold tracking-tight text-balance sm:text-3xl\"\n >\n {title}\n </h1>\n <p class=\"text-muted-foreground text-base leading-relaxed\">\n {description}\n </p>\n </div>\n <div class=\"flex flex-wrap gap-3\">\n {\n buttons.map(({ href, label, ...button }, index) => (\n <Button\n as=\"a\"\n href={href}\n variant={\n button.variant ?? (index === 0 ? \"default\" : \"secondary\")\n }\n {...button}\n >\n {label}\n </Button>\n ))\n }\n </div>\n </div>\n <Image\n src={image.src}\n alt={image.alt}\n class=\"aspect-4/3 w-full rounded-xl border object-cover\"\n widths={[640, 960, 1280]}\n sizes=\"(min-width: 1024px) 75vw, 100vw\"\n loading=\"eager\"\n />\n </SectionContainer>\n</Section>\n",
|
|
11
|
+
"content": "---\nimport type { ImageMetadata } from \"astro\"\nimport { Image } from \"astro:assets\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Button } from \"@/components/ui/button\"\nimport { Section, SectionContainer } from \"@/components/ui/section\"\n\ntype Props = {\n class?: string\n title: string\n description: string\n buttons: {\n label: string\n href: string\n variant?: \"default\" | \"outline\" | \"secondary\" | \"ghost\"\n }[]\n image: {\n src: ImageMetadata\n alt: string\n }\n}\n\nconst { class: className, title, description, buttons, image } = Astro.props\n---\n\n<Section class={cn(\"\", className)}>\n <SectionContainer class=\"grid gap-12 lg:grid-cols-[1fr_3fr] lg:items-start\">\n <div class=\"flex flex-col gap-6 pt-8\">\n <div class=\"flex flex-col gap-4\">\n <h1\n class=\"text-foreground text-2xl leading-[1.2] font-semibold tracking-tight text-balance sm:text-3xl\"\n >\n {title}\n </h1>\n <p class=\"text-muted-foreground text-base leading-relaxed\">\n {description}\n </p>\n </div>\n <div class=\"flex flex-wrap gap-3\">\n {\n buttons.map(({ href, label, ...button }, index) => (\n <Button\n as=\"a\"\n href={href}\n variant={\n button.variant ?? (index === 0 ? \"default\" : \"secondary\")\n }\n {...button}\n >\n {label}\n </Button>\n ))\n }\n </div>\n </div>\n <Image\n src={image.src}\n alt={image.alt}\n class=\"aspect-[4/3] w-full rounded-xl border object-cover\"\n widths={[640, 960, 1280]}\n sizes=\"(min-width: 1024px) 75vw, 100vw\"\n loading=\"eager\"\n />\n </SectionContainer>\n</Section>\n",
|
|
12
12
|
"type": "registry:block"
|
|
13
13
|
}
|
|
14
14
|
],
|