fulldev-ui 0.25.0 → 0.25.1
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 +8 -0
- package/liquid/README.md +1 -1
- package/liquid/assets/ui-licenses.json +1 -1
- package/liquid/assets/ui-manifest.json +1 -1
- package/package.json +2 -1
- package/public/r/liquid/components.json +1 -1
- package/public/r/liquid/init.json +1 -1
- package/liquid/vendor.json +0 -180
- package/public/r/accordion-examples.json +0 -49
- package/public/r/accordion.json +0 -42
- package/public/r/alert-dialog-examples.json +0 -51
- package/public/r/alert-dialog.json +0 -84
- package/public/r/alert-examples.json +0 -47
- package/public/r/alert.json +0 -38
- package/public/r/article-1.json +0 -22
- package/public/r/article-2.json +0 -22
- package/public/r/articles-1.json +0 -22
- package/public/r/articles-2.json +0 -23
- package/public/r/articles-3.json +0 -22
- package/public/r/articles-4.json +0 -22
- package/public/r/aspect-ratio-examples.json +0 -33
- package/public/r/aspect-ratio.json +0 -23
- package/public/r/attachment-examples.json +0 -48
- package/public/r/attachment.json +0 -66
- package/public/r/avatar-examples.json +0 -68
- package/public/r/avatar.json +0 -48
- package/public/r/badge-examples.json +0 -52
- package/public/r/badge.json +0 -28
- package/public/r/banner-1.json +0 -24
- package/public/r/banner-2.json +0 -22
- package/public/r/banner.json +0 -31
- package/public/r/base.json +0 -143
- package/public/r/blocks-1.json +0 -27
- package/public/r/blocks.json +0 -92
- package/public/r/breadcrumb-examples.json +0 -53
- package/public/r/breadcrumb.json +0 -56
- package/public/r/button-examples.json +0 -87
- package/public/r/button-group-examples.json +0 -75
- package/public/r/button-group.json +0 -41
- package/public/r/button.json +0 -28
- package/public/r/card-examples.json +0 -51
- package/public/r/card.json +0 -53
- package/public/r/carousel-examples.json +0 -49
- package/public/r/carousel.json +0 -50
- package/public/r/checkbox-examples.json +0 -56
- package/public/r/checkbox.json +0 -23
- package/public/r/code-block-examples.json +0 -33
- package/public/r/code-block.json +0 -65
- package/public/r/collapsible-examples.json +0 -51
- package/public/r/collapsible.json +0 -36
- package/public/r/combobox-examples.json +0 -69
- package/public/r/combobox.json +0 -81
- package/public/r/command-examples.json +0 -47
- package/public/r/command.json +0 -71
- package/public/r/components.json +0 -74
- package/public/r/contact-1.json +0 -23
- package/public/r/contact-2.json +0 -23
- package/public/r/contact-3.json +0 -29
- package/public/r/content-1.json +0 -31
- package/public/r/content-2.json +0 -31
- package/public/r/content-3.json +0 -28
- package/public/r/content-4.json +0 -31
- package/public/r/cta-1.json +0 -24
- package/public/r/cta-2.json +0 -30
- package/public/r/cta-3.json +0 -24
- package/public/r/cta-4.json +0 -30
- package/public/r/cta-5.json +0 -31
- package/public/r/cta-6.json +0 -30
- package/public/r/cta-7.json +0 -23
- package/public/r/cta-8.json +0 -22
- package/public/r/dialog-examples.json +0 -47
- package/public/r/dialog.json +0 -75
- package/public/r/doc-1.json +0 -30
- package/public/r/drawer-examples.json +0 -54
- package/public/r/drawer.json +0 -109
- package/public/r/dropdown-menu-examples.json +0 -63
- package/public/r/dropdown-menu.json +0 -77
- package/public/r/empty-examples.json +0 -55
- package/public/r/empty.json +0 -48
- package/public/r/faqs-1.json +0 -23
- package/public/r/faqs-2.json +0 -23
- package/public/r/faqs-3.json +0 -23
- package/public/r/faqs-4.json +0 -22
- package/public/r/features-1.json +0 -26
- package/public/r/features-2.json +0 -22
- package/public/r/features-3.json +0 -21
- package/public/r/features-4.json +0 -26
- package/public/r/features-5.json +0 -22
- package/public/r/features-6.json +0 -23
- package/public/r/field-examples.json +0 -86
- package/public/r/field.json +0 -72
- package/public/r/footer-1.json +0 -24
- package/public/r/footer-2.json +0 -24
- package/public/r/footer-3.json +0 -24
- package/public/r/form.json +0 -23
- package/public/r/header-1.json +0 -29
- package/public/r/header-2.json +0 -29
- package/public/r/header-3.json +0 -30
- package/public/r/header-4.json +0 -29
- package/public/r/header-5.json +0 -30
- package/public/r/header.json +0 -40
- package/public/r/hero-1.json +0 -23
- package/public/r/hero-10.json +0 -24
- package/public/r/hero-11.json +0 -24
- package/public/r/hero-12.json +0 -22
- package/public/r/hero-13.json +0 -22
- package/public/r/hero-2.json +0 -24
- package/public/r/hero-3.json +0 -22
- package/public/r/hero-4.json +0 -25
- package/public/r/hero-5.json +0 -27
- package/public/r/hero-6.json +0 -27
- package/public/r/hero-7.json +0 -27
- package/public/r/hero-8.json +0 -22
- package/public/r/hero-9.json +0 -27
- package/public/r/hover-card-examples.json +0 -29
- package/public/r/hover-card.json +0 -37
- package/public/r/icon.json +0 -27
- package/public/r/init.json +0 -44
- package/public/r/input-examples.json +0 -97
- package/public/r/input-group-examples.json +0 -91
- package/public/r/input-group.json +0 -53
- package/public/r/input.json +0 -23
- package/public/r/item-examples.json +0 -74
- package/public/r/item.json +0 -71
- package/public/r/kbd-examples.json +0 -50
- package/public/r/kbd.json +0 -28
- package/public/r/label-examples.json +0 -24
- package/public/r/label.json +0 -23
- package/public/r/layout.json +0 -41
- package/public/r/links-2.json +0 -24
- package/public/r/logo.json +0 -33
- package/public/r/logos-1.json +0 -22
- package/public/r/logos-2.json +0 -23
- package/public/r/logos-3.json +0 -22
- package/public/r/marquee.json +0 -46
- package/public/r/native-select-examples.json +0 -38
- package/public/r/native-select.json +0 -36
- package/public/r/navigation-menu-examples.json +0 -26
- package/public/r/navigation-menu.json +0 -67
- package/public/r/pagination-examples.json +0 -35
- package/public/r/pagination.json +0 -59
- package/public/r/popover-examples.json +0 -42
- package/public/r/popover.json +0 -51
- package/public/r/price.json +0 -38
- package/public/r/pricing-1.json +0 -29
- package/public/r/pricing-2.json +0 -28
- package/public/r/pricing-3.json +0 -29
- package/public/r/product-1.json +0 -24
- package/public/r/products-1.json +0 -24
- package/public/r/products-2.json +0 -24
- package/public/r/products-3.json +0 -24
- package/public/r/products-4.json +0 -24
- package/public/r/products-5.json +0 -25
- package/public/r/progress-examples.json +0 -33
- package/public/r/progress.json +0 -23
- package/public/r/radio-group-examples.json +0 -50
- package/public/r/radio-group.json +0 -31
- package/public/r/rating.json +0 -26
- package/public/r/registry.json +0 -6959
- package/public/r/resizable-examples.json +0 -33
- package/public/r/resizable.json +0 -36
- package/public/r/reviews-1.json +0 -27
- package/public/r/reviews-2.json +0 -27
- package/public/r/reviews-3.json +0 -27
- package/public/r/reviews-4.json +0 -25
- package/public/r/reviews-5.json +0 -27
- package/public/r/section.json +0 -38
- package/public/r/select-examples.json +0 -53
- package/public/r/select.json +0 -62
- package/public/r/separator-examples.json +0 -38
- package/public/r/separator.json +0 -23
- package/public/r/services-1.json +0 -32
- package/public/r/services-2.json +0 -29
- package/public/r/services-3.json +0 -29
- package/public/r/services-4.json +0 -31
- package/public/r/services-5.json +0 -26
- package/public/r/services-6.json +0 -32
- package/public/r/services-7.json +0 -32
- package/public/r/sheet-examples.json +0 -37
- package/public/r/sheet.json +0 -66
- package/public/r/sidebar-1.json +0 -35
- package/public/r/sidebar-examples.json +0 -24
- package/public/r/sidebar.json +0 -146
- package/public/r/skeleton-examples.json +0 -49
- package/public/r/skeleton.json +0 -23
- package/public/r/slider-examples.json +0 -44
- package/public/r/slider.json +0 -26
- package/public/r/spinner-examples.json +0 -61
- package/public/r/spinner.json +0 -26
- package/public/r/switch-examples.json +0 -50
- package/public/r/switch.json +0 -26
- package/public/r/table-examples.json +0 -38
- package/public/r/table.json +0 -58
- package/public/r/tabs-examples.json +0 -47
- package/public/r/tabs.json +0 -46
- package/public/r/textarea-examples.json +0 -45
- package/public/r/textarea.json +0 -23
- package/public/r/theme-toggle.json +0 -34
- package/public/r/toast-examples.json +0 -29
- package/public/r/toast.json +0 -80
- package/public/r/toc.json +0 -43
- package/public/r/toggle-examples.json +0 -46
- package/public/r/toggle-group-examples.json +0 -57
- package/public/r/toggle-group.json +0 -34
- package/public/r/toggle.json +0 -31
- package/public/r/tooltip-examples.json +0 -43
- package/public/r/tooltip.json +0 -36
- package/public/r/typography.json +0 -103
- package/public/r/video.json +0 -23
|
@@ -1,84 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
|
-
"name": "alert-dialog",
|
|
4
|
-
"title": "Alert Dialog",
|
|
5
|
-
"description": "A modal dialog for important confirmations that expects a response.",
|
|
6
|
-
"dependencies": [
|
|
7
|
-
"@data-slot/alert-dialog@^1.1.2"
|
|
8
|
-
],
|
|
9
|
-
"registryDependencies": [
|
|
10
|
-
"@fulldev/button"
|
|
11
|
-
],
|
|
12
|
-
"files": [
|
|
13
|
-
{
|
|
14
|
-
"path": "src/components/ui/alert-dialog/alert-dialog.astro",
|
|
15
|
-
"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}\n\nconst {\n class: className,\n defaultOpen,\n closeOnClickOutside,\n closeOnEscape,\n lockScroll,\n ...props\n} = Astro.props\n---\n\n<div\n data-slot=\"alert-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 class={className}\n {...props}\n>\n <slot />\n</div>\n\n<script>\n import { create } from \"@data-slot/alert-dialog\"\n\n const controllers: ReturnType<typeof create> = []\n const initialize = () => controllers.push(...create())\n initialize()\n document.addEventListener(\"astro:page-load\", initialize)\n document.addEventListener(\"astro:before-swap\", () => {\n for (const controller of controllers) controller.destroy()\n controllers.length = 0\n })\n</script>\n",
|
|
16
|
-
"type": "registry:ui"
|
|
17
|
-
},
|
|
18
|
-
{
|
|
19
|
-
"path": "src/components/ui/alert-dialog/alert-dialog-trigger.astro",
|
|
20
|
-
"content": "---\nimport type { ComponentProps } from \"astro/types\"\n\nimport { Button } from \"@/components/ui/button\"\n\ntype Props = ComponentProps<typeof Button>\n\nconst { ...props } = Astro.props\n---\n\n<Button data-slot=\"alert-dialog-trigger\" {...props}>\n <slot />\n</Button>\n",
|
|
21
|
-
"type": "registry:ui"
|
|
22
|
-
},
|
|
23
|
-
{
|
|
24
|
-
"path": "src/components/ui/alert-dialog/alert-dialog-portal.astro",
|
|
25
|
-
"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 data-slot=\"alert-dialog-portal\" class={cn(className)} {...props}>\n <slot />\n</div>\n",
|
|
26
|
-
"type": "registry:ui"
|
|
27
|
-
},
|
|
28
|
-
{
|
|
29
|
-
"path": "src/components/ui/alert-dialog/alert-dialog-overlay.astro",
|
|
30
|
-
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype Props = HTMLAttributes<\"div\">\n\nconst { class: className, style, ...props } = Astro.props\n---\n\n<div\n data-slot=\"alert-dialog-overlay\"\n hidden\n class={cn(\n \"data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs fixed inset-0 isolate z-(--alert-dialog-overlay-stack-index)\",\n className\n )}\n style={`z-index: calc(var(--alert-dialog-overlay-stack-index, 0) * 2 + 100);${style ? ` ${style}` : \"\"}`}\n {...props}\n></div>\n",
|
|
31
|
-
"type": "registry:ui"
|
|
32
|
-
},
|
|
33
|
-
{
|
|
34
|
-
"path": "src/components/ui/alert-dialog/alert-dialog-content.astro",
|
|
35
|
-
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\n\nimport AlertDialogOverlay from \"./alert-dialog-overlay.astro\"\nimport AlertDialogPortal from \"./alert-dialog-portal.astro\"\n\ntype Props = HTMLAttributes<\"div\"> & {\n size?: \"default\" | \"sm\"\n}\n\nconst { class: className, size = \"default\", style, ...props } = Astro.props\n---\n\n<AlertDialogPortal>\n <AlertDialogOverlay />\n <div\n data-slot=\"alert-dialog-content\"\n data-size={size}\n hidden\n class={cn(\n \"data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 data-closed:zoom-out-95 data-open:zoom-in-95 bg-popover text-popover-foreground ring-foreground/10 gap-6 rounded-xl p-6 ring-1 duration-100 data-[size=default]:max-w-xs data-[size=sm]:max-w-xs data-[size=default]:sm:max-w-lg group/alert-dialog-content fixed top-1/2 left-1/2 z-50 grid w-full -translate-x-1/2 -translate-y-1/2 outline-none\",\n className\n )}\n style={`z-index: calc(var(--alert-dialog-content-stack-index, 0) * 2 + 101);${style ? ` ${style}` : \"\"}`}\n {...props}\n >\n <slot />\n </div>\n</AlertDialogPortal>\n",
|
|
36
|
-
"type": "registry:ui"
|
|
37
|
-
},
|
|
38
|
-
{
|
|
39
|
-
"path": "src/components/ui/alert-dialog/alert-dialog-header.astro",
|
|
40
|
-
"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=\"alert-dialog-header\"\n class={cn(\"grid grid-rows-[auto_1fr] place-items-center gap-1.5 text-center has-data-[slot=alert-dialog-media]:grid-rows-[auto_auto_1fr] has-data-[slot=alert-dialog-media]:gap-x-6 sm:group-data-[size=default]/alert-dialog-content:place-items-start sm:group-data-[size=default]/alert-dialog-content:text-left sm:group-data-[size=default]/alert-dialog-content:has-data-[slot=alert-dialog-media]:grid-rows-[auto_1fr]\", className)}\n {...props}\n>\n <slot />\n</div>\n",
|
|
41
|
-
"type": "registry:ui"
|
|
42
|
-
},
|
|
43
|
-
{
|
|
44
|
-
"path": "src/components/ui/alert-dialog/alert-dialog-media.astro",
|
|
45
|
-
"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=\"alert-dialog-media\"\n class={cn(\"bg-muted mb-2 inline-flex size-16 items-center justify-center rounded-md sm:group-data-[size=default]/alert-dialog-content:row-span-2 *:[svg:not([class*='size-'])]:size-8\", className)}\n {...props}\n>\n <slot />\n</div>\n",
|
|
46
|
-
"type": "registry:ui"
|
|
47
|
-
},
|
|
48
|
-
{
|
|
49
|
-
"path": "src/components/ui/alert-dialog/alert-dialog-footer.astro",
|
|
50
|
-
"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=\"alert-dialog-footer\"\n class={cn(\n \"flex flex-col-reverse gap-2 group-data-[size=sm]/alert-dialog-content:grid group-data-[size=sm]/alert-dialog-content:grid-cols-2 sm:flex-row sm:justify-end\",\n className\n )}\n {...props}\n>\n <slot />\n</div>\n",
|
|
51
|
-
"type": "registry:ui"
|
|
52
|
-
},
|
|
53
|
-
{
|
|
54
|
-
"path": "src/components/ui/alert-dialog/alert-dialog-title.astro",
|
|
55
|
-
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype Props = HTMLAttributes<\"h2\">\n\nconst { class: className, ...props } = Astro.props\n---\n\n<h2\n data-slot=\"alert-dialog-title\"\n class={cn(\"text-lg font-medium sm:group-data-[size=default]/alert-dialog-content:group-has-data-[slot=alert-dialog-media]/alert-dialog-content:col-start-2 font-heading\", className)}\n {...props}\n>\n <slot />\n</h2>\n",
|
|
56
|
-
"type": "registry:ui"
|
|
57
|
-
},
|
|
58
|
-
{
|
|
59
|
-
"path": "src/components/ui/alert-dialog/alert-dialog-description.astro",
|
|
60
|
-
"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=\"alert-dialog-description\"\n class={cn(\"text-muted-foreground *:[a]:hover:text-foreground text-sm text-balance md:text-pretty *:[a]:underline *:[a]:underline-offset-3\", className)}\n {...props}\n>\n <slot />\n</p>\n",
|
|
61
|
-
"type": "registry:ui"
|
|
62
|
-
},
|
|
63
|
-
{
|
|
64
|
-
"path": "src/components/ui/alert-dialog/alert-dialog-action.astro",
|
|
65
|
-
"content": "---\nimport type { ComponentProps } from \"astro/types\"\n\nimport { Button } from \"@/components/ui/button\"\n\ntype Props = ComponentProps<typeof Button>\n\nconst { ...props } = Astro.props\n---\n\n<Button data-slot=\"alert-dialog-action\" {...props}>\n <slot />\n</Button>\n",
|
|
66
|
-
"type": "registry:ui"
|
|
67
|
-
},
|
|
68
|
-
{
|
|
69
|
-
"path": "src/components/ui/alert-dialog/alert-dialog-cancel.astro",
|
|
70
|
-
"content": "---\nimport type { ComponentProps } from \"astro/types\"\n\nimport { Button } from \"@/components/ui/button\"\n\ntype Props = ComponentProps<typeof Button>\n\nconst { variant = \"outline\", ...props } = Astro.props\n---\n\n<Button data-slot=\"alert-dialog-cancel\" variant={variant} {...props}>\n <slot />\n</Button>\n",
|
|
71
|
-
"type": "registry:ui"
|
|
72
|
-
},
|
|
73
|
-
{
|
|
74
|
-
"path": "src/components/ui/alert-dialog/index.ts",
|
|
75
|
-
"content": "export { default as AlertDialog } from \"./alert-dialog.astro\"\nexport { default as AlertDialogAction } from \"./alert-dialog-action.astro\"\nexport { default as AlertDialogCancel } from \"./alert-dialog-cancel.astro\"\nexport { default as AlertDialogContent } from \"./alert-dialog-content.astro\"\nexport { default as AlertDialogDescription } from \"./alert-dialog-description.astro\"\nexport { default as AlertDialogFooter } from \"./alert-dialog-footer.astro\"\nexport { default as AlertDialogHeader } from \"./alert-dialog-header.astro\"\nexport { default as AlertDialogMedia } from \"./alert-dialog-media.astro\"\nexport { default as AlertDialogOverlay } from \"./alert-dialog-overlay.astro\"\nexport { default as AlertDialogPortal } from \"./alert-dialog-portal.astro\"\nexport { default as AlertDialogTitle } from \"./alert-dialog-title.astro\"\nexport { default as AlertDialogTrigger } from \"./alert-dialog-trigger.astro\"\n",
|
|
76
|
-
"type": "registry:ui"
|
|
77
|
-
}
|
|
78
|
-
],
|
|
79
|
-
"docs": "https://ui.full.dev/components/alert-dialog/",
|
|
80
|
-
"categories": [
|
|
81
|
-
"ui"
|
|
82
|
-
],
|
|
83
|
-
"type": "registry:ui"
|
|
84
|
-
}
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
|
-
"name": "alert-examples",
|
|
4
|
-
"title": "Alert examples",
|
|
5
|
-
"description": "The examples from the shadcn/ui Alert docs.",
|
|
6
|
-
"dependencies": [
|
|
7
|
-
"@lucide/astro"
|
|
8
|
-
],
|
|
9
|
-
"registryDependencies": [
|
|
10
|
-
"@fulldev/alert",
|
|
11
|
-
"@fulldev/button"
|
|
12
|
-
],
|
|
13
|
-
"files": [
|
|
14
|
-
{
|
|
15
|
-
"path": "src/components/examples/alert/alert-action.astro",
|
|
16
|
-
"content": "---\nimport {\n Alert,\n AlertAction,\n AlertDescription,\n AlertTitle,\n} from \"@/components/ui/alert\"\nimport { Button } from \"@/components/ui/button\"\n---\n\n<Alert class=\"max-w-md\">\n <AlertTitle>Dark mode is now available</AlertTitle>\n <AlertDescription>\n Enable it under your profile settings to get started.\n </AlertDescription>\n <AlertAction>\n <Button size=\"xs\" variant=\"default\">\n Enable\n </Button>\n </AlertAction>\n</Alert>\n",
|
|
17
|
-
"type": "registry:component"
|
|
18
|
-
},
|
|
19
|
-
{
|
|
20
|
-
"path": "src/components/examples/alert/alert-basic.astro",
|
|
21
|
-
"content": "---\nimport CheckCircle2Icon from \"@lucide/astro/icons/circle-check\"\n\nimport { Alert, AlertDescription, AlertTitle } from \"@/components/ui/alert\"\n---\n\n<Alert class=\"max-w-md\">\n <CheckCircle2Icon />\n <AlertTitle>Account updated successfully</AlertTitle>\n <AlertDescription>\n Your profile information has been saved. Changes will be reflected\n immediately.\n </AlertDescription>\n</Alert>\n",
|
|
22
|
-
"type": "registry:component"
|
|
23
|
-
},
|
|
24
|
-
{
|
|
25
|
-
"path": "src/components/examples/alert/alert-colors.astro",
|
|
26
|
-
"content": "---\nimport AlertTriangleIcon from \"@lucide/astro/icons/triangle-alert\"\n\nimport { Alert, AlertDescription, AlertTitle } from \"@/components/ui/alert\"\n---\n\n<Alert class=\"max-w-md border-amber-200 bg-amber-50 text-amber-900 dark:border-amber-900 dark:bg-amber-950 dark:text-amber-50\">\n <AlertTriangleIcon />\n <AlertTitle>Your subscription will expire in 3 days.</AlertTitle>\n <AlertDescription>\n Renew now to avoid service interruption or upgrade to a paid plan to\n continue using the service.\n </AlertDescription>\n</Alert>\n",
|
|
27
|
-
"type": "registry:component"
|
|
28
|
-
},
|
|
29
|
-
{
|
|
30
|
-
"path": "src/components/examples/alert/alert-demo.astro",
|
|
31
|
-
"content": "---\nimport CheckCircle2Icon from \"@lucide/astro/icons/circle-check\"\nimport InfoIcon from \"@lucide/astro/icons/info\"\n\nimport { Alert, AlertDescription, AlertTitle } from \"@/components/ui/alert\"\n---\n\n<div class=\"grid w-full max-w-md items-start gap-4\">\n <Alert>\n <CheckCircle2Icon />\n <AlertTitle>Payment successful</AlertTitle>\n <AlertDescription>\n Your payment of $29.99 has been processed. A receipt has been sent to your\n email address.\n </AlertDescription>\n </Alert>\n <Alert>\n <InfoIcon />\n <AlertTitle>New feature available</AlertTitle>\n <AlertDescription>\n We've added dark mode support. You can enable it in your account settings.\n </AlertDescription>\n </Alert>\n</div>\n",
|
|
32
|
-
"type": "registry:component"
|
|
33
|
-
},
|
|
34
|
-
{
|
|
35
|
-
"path": "src/components/examples/alert/alert-destructive.astro",
|
|
36
|
-
"content": "---\nimport AlertCircleIcon from \"@lucide/astro/icons/circle-alert\"\n\nimport { Alert, AlertDescription, AlertTitle } from \"@/components/ui/alert\"\n---\n\n<Alert variant=\"destructive\" class=\"max-w-md\">\n <AlertCircleIcon />\n <AlertTitle>Payment failed</AlertTitle>\n <AlertDescription>\n Your payment could not be processed. Please check your payment method and\n try again.\n </AlertDescription>\n</Alert>\n",
|
|
37
|
-
"type": "registry:component"
|
|
38
|
-
},
|
|
39
|
-
{
|
|
40
|
-
"path": "src/components/examples/alert/alert-rtl.astro",
|
|
41
|
-
"content": "---\nimport CheckCircle2Icon from \"@lucide/astro/icons/circle-check\"\nimport InfoIcon from \"@lucide/astro/icons/info\"\n\nimport { Alert, AlertDescription, AlertTitle } from \"@/components/ui/alert\"\n\nconst translations = {\n en: {\n dir: \"ltr\",\n values: {\n paymentTitle: \"Payment successful\",\n paymentDescription:\n \"Your payment of $29.99 has been processed. A receipt has been sent to your email address.\",\n featureTitle: \"New feature available\",\n featureDescription:\n \"We've added dark mode support. You can enable it in your account settings.\",\n },\n },\n ar: {\n dir: \"rtl\",\n values: {\n paymentTitle: \"تم الدفع بنجاح\",\n paymentDescription:\n \"تمت معالجة دفعتك البالغة 29.99 دولارًا. تم إرسال إيصال إلى عنوان بريدك الإلكتروني.\",\n featureTitle: \"ميزة جديدة متاحة\",\n featureDescription:\n \"لقد أضفنا دعم الوضع الداكن. يمكنك تفعيله في إعدادات حسابك.\",\n },\n },\n he: {\n dir: \"rtl\",\n values: {\n paymentTitle: \"התשלום בוצע בהצלחה\",\n paymentDescription:\n \"התשלום שלך בסך 29.99 דולר עובד. קבלה נשלחה לכתובת האימייל שלך.\",\n featureTitle: \"תכונה חדשה זמינה\",\n featureDescription:\n \"הוספנו תמיכה במצב כהה. אתה יכול להפעיל אותו בהגדרות החשבון שלך.\",\n },\n },\n} as const\n\nconst alerts = [\n {\n icon: CheckCircle2Icon,\n titleKey: \"paymentTitle\",\n descriptionKey: \"paymentDescription\",\n },\n {\n icon: InfoIcon,\n titleKey: \"featureTitle\",\n descriptionKey: \"featureDescription\",\n },\n] as const\n\nconst { dir, values: t } = translations.ar\n---\n\n<div class=\"grid w-full max-w-md items-start gap-4\" dir={dir}>\n {alerts.map((alert) => {\n const Icon = alert.icon\n return (\n <Alert>\n <Icon />\n <AlertTitle>{t[alert.titleKey]}</AlertTitle>\n <AlertDescription>{t[alert.descriptionKey]}</AlertDescription>\n </Alert>\n )\n })}\n</div>\n",
|
|
42
|
-
"type": "registry:component"
|
|
43
|
-
}
|
|
44
|
-
],
|
|
45
|
-
"docs": "https://ui.full.dev/components/alert/",
|
|
46
|
-
"type": "registry:example"
|
|
47
|
-
}
|
package/public/r/alert.json
DELETED
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
|
-
"name": "alert",
|
|
4
|
-
"title": "Alert",
|
|
5
|
-
"description": "Displays a callout for user attention.",
|
|
6
|
-
"files": [
|
|
7
|
-
{
|
|
8
|
-
"path": "src/components/ui/alert/alert.astro",
|
|
9
|
-
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\nimport { cva, type VariantProps } from \"class-variance-authority\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype Props = VariantProps<typeof variants> & HTMLAttributes<\"div\">\n\nconst variants = cva(\"grid gap-0.5 rounded-lg border px-4 py-3 text-left text-sm has-data-[slot=alert-action]:relative has-data-[slot=alert-action]:pr-18 has-[>svg]:grid-cols-[auto_1fr] has-[>svg]:gap-x-2.5 *:[svg]:row-span-2 *:[svg]:translate-y-0.5 *:[svg]:text-current *:[svg:not([class*='size-'])]:size-4 group/alert relative w-full\", {\n variants: {\n variant: {\n default: \"bg-card text-card-foreground\",\n destructive: \"text-destructive bg-card *:data-[slot=alert-description]:text-destructive/90 *:[svg]:text-current\",\n },\n },\n defaultVariants: {\n variant: \"default\",\n },\n})\n\nconst { class: className, variant, ...props } = Astro.props\n---\n\n<div\n data-slot=\"alert\"\n role=\"alert\"\n class={cn(variants({ variant }), className)}\n {...props}\n>\n <slot />\n</div>\n",
|
|
10
|
-
"type": "registry:ui"
|
|
11
|
-
},
|
|
12
|
-
{
|
|
13
|
-
"path": "src/components/ui/alert/alert-action.astro",
|
|
14
|
-
"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=\"alert-action\"\n class={cn(\"absolute top-2.5 right-3\", className)}\n {...props}\n>\n <slot />\n</div>\n",
|
|
15
|
-
"type": "registry:ui"
|
|
16
|
-
},
|
|
17
|
-
{
|
|
18
|
-
"path": "src/components/ui/alert/alert-description.astro",
|
|
19
|
-
"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=\"alert-description\"\n class={cn(\n \"text-muted-foreground text-sm text-balance md:text-pretty [&_p:not(:last-child)]:mb-4 [&_a]:hover:text-foreground [&_a]:underline [&_a]:underline-offset-3\",\n className\n )}\n {...props}\n>\n <slot />\n</div>\n",
|
|
20
|
-
"type": "registry:ui"
|
|
21
|
-
},
|
|
22
|
-
{
|
|
23
|
-
"path": "src/components/ui/alert/alert-title.astro",
|
|
24
|
-
"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=\"alert-title\"\n class={cn(\n \"font-medium group-has-[>svg]/alert:col-start-2 [&_a]:hover:text-foreground [&_a]:underline [&_a]:underline-offset-3\",\n className\n )}\n {...props}\n>\n <slot />\n</div>\n",
|
|
25
|
-
"type": "registry:ui"
|
|
26
|
-
},
|
|
27
|
-
{
|
|
28
|
-
"path": "src/components/ui/alert/index.ts",
|
|
29
|
-
"content": "export { default as Alert } from \"./alert.astro\"\nexport { default as AlertAction } from \"./alert-action.astro\"\nexport { default as AlertTitle } from \"./alert-title.astro\"\nexport { default as AlertDescription } from \"./alert-description.astro\"\n",
|
|
30
|
-
"type": "registry:ui"
|
|
31
|
-
}
|
|
32
|
-
],
|
|
33
|
-
"docs": "https://ui.full.dev/components/alert/",
|
|
34
|
-
"categories": [
|
|
35
|
-
"ui"
|
|
36
|
-
],
|
|
37
|
-
"type": "registry:ui"
|
|
38
|
-
}
|
package/public/r/article-1.json
DELETED
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
|
-
"name": "article-1",
|
|
4
|
-
"title": "Article 1",
|
|
5
|
-
"description": "Editorial article layouts for long-form stories, interviews, and analysis.",
|
|
6
|
-
"registryDependencies": [
|
|
7
|
-
"@fulldev/avatar",
|
|
8
|
-
"@fulldev/section"
|
|
9
|
-
],
|
|
10
|
-
"files": [
|
|
11
|
-
{
|
|
12
|
-
"path": "src/components/blocks/article-1.astro",
|
|
13
|
-
"content": "---\nimport type { ImageMetadata } from \"astro\"\nimport { Image } from \"astro:assets\"\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Avatar, AvatarFallback, AvatarImage } from \"@/components/ui/avatar\"\nimport { Section, SectionContainer } from \"@/components/ui/section\"\n\ntype Props = HTMLAttributes<\"section\"> & {\n title: string\n description: string\n author: {\n image?: ImageMetadata\n initials: string\n name: string\n date: string\n }\n image: {\n src: ImageMetadata\n alt: string\n }\n}\n\nconst {\n class: className,\n title,\n description,\n author,\n image,\n ...props\n} = Astro.props\n---\n\n<Section class={cn(\"\", className)} {...props}>\n <SectionContainer class=\"max-w-2xl\">\n <article class=\"flex flex-col gap-8\">\n <header class=\"flex flex-col gap-6\">\n <div class=\"flex flex-col gap-4\">\n <h1 class=\"text-4xl leading-tight font-semibold tracking-tight text-balance sm:text-5xl\">\n {title}\n </h1>\n <p class=\"text-muted-foreground text-lg leading-8 text-balance\">\n {description}\n </p>\n </div>\n <div class=\"flex items-center gap-3\">\n <Avatar size=\"lg\" aria-hidden=\"true\">\n <AvatarImage src={author.image} />\n <AvatarFallback>{author.initials}</AvatarFallback>\n </Avatar>\n <div class=\"flex flex-col\">\n <p class=\"text-sm font-medium\">{author.name}</p>\n <p class=\"text-muted-foreground text-xs\">{author.date}</p>\n </div>\n </div>\n </header>\n <Image\n src={image.src}\n alt={image.alt}\n class=\"aspect-[16/10] w-full rounded-xl object-cover\"\n widths={[640, 960, 1280]}\n sizes=\"(min-width: 42rem) 42rem, 100vw\"\n loading=\"eager\"\n fetchpriority=\"high\"\n />\n <div class=\"flex flex-col gap-6 text-base leading-8\">\n <slot />\n </div>\n </article>\n </SectionContainer>\n</Section>\n",
|
|
14
|
-
"type": "registry:block"
|
|
15
|
-
}
|
|
16
|
-
],
|
|
17
|
-
"docs": "https://ui.full.dev/blocks/article/",
|
|
18
|
-
"categories": [
|
|
19
|
-
"article"
|
|
20
|
-
],
|
|
21
|
-
"type": "registry:block"
|
|
22
|
-
}
|
package/public/r/article-2.json
DELETED
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
|
-
"name": "article-2",
|
|
4
|
-
"title": "Article 2",
|
|
5
|
-
"description": "Editorial article layouts for long-form stories, interviews, and analysis.",
|
|
6
|
-
"registryDependencies": [
|
|
7
|
-
"@fulldev/avatar",
|
|
8
|
-
"@fulldev/section"
|
|
9
|
-
],
|
|
10
|
-
"files": [
|
|
11
|
-
{
|
|
12
|
-
"path": "src/components/blocks/article-2.astro",
|
|
13
|
-
"content": "---\nimport type { ImageMetadata } from \"astro\"\nimport { Image } from \"astro:assets\"\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Avatar, AvatarFallback, AvatarImage } from \"@/components/ui/avatar\"\nimport { Section, SectionContainer } from \"@/components/ui/section\"\n\ntype Props = HTMLAttributes<\"section\"> & {\n title: string\n description: string\n author: {\n image?: ImageMetadata\n initials: string\n name: string\n date: string\n readingTime: string\n }\n image: {\n src: ImageMetadata\n alt: string\n }\n}\n\nconst {\n class: className,\n title,\n description,\n author,\n image,\n ...props\n} = Astro.props\n---\n\n<Section class={cn(\"\", className)} {...props}>\n <SectionContainer class=\"max-w-2xl\">\n <article class=\"flex flex-col gap-8\">\n <header class=\"flex flex-col items-center gap-6 text-center\">\n <div class=\"flex flex-col gap-4\">\n <h1 class=\"text-4xl leading-tight font-semibold tracking-tight text-balance sm:text-5xl\">\n {title}\n </h1>\n <p class=\"text-muted-foreground text-lg leading-8 text-balance\">\n {description}\n </p>\n </div>\n <div class=\"flex items-center gap-3\">\n <Avatar size=\"lg\" aria-hidden=\"true\">\n <AvatarImage src={author.image} />\n <AvatarFallback>{author.initials}</AvatarFallback>\n </Avatar>\n <div class=\"flex flex-col text-left\">\n <p class=\"text-sm font-medium\">\n {author.name}{\" \"}\n <span class=\"text-muted-foreground font-normal\">\n · {author.date}\n </span>\n </p>\n <p class=\"text-muted-foreground text-xs\">{author.readingTime}</p>\n </div>\n </div>\n </header>\n <Image\n src={image.src}\n alt={image.alt}\n class=\"aspect-[16/10] w-full rounded-xl object-cover\"\n widths={[640, 960, 1280]}\n sizes=\"(min-width: 42rem) 42rem, 100vw\"\n loading=\"eager\"\n fetchpriority=\"high\"\n />\n <div class=\"flex flex-col gap-6 text-base leading-8\">\n <slot />\n </div>\n </article>\n </SectionContainer>\n</Section>\n",
|
|
14
|
-
"type": "registry:block"
|
|
15
|
-
}
|
|
16
|
-
],
|
|
17
|
-
"docs": "https://ui.full.dev/blocks/article/",
|
|
18
|
-
"categories": [
|
|
19
|
-
"article"
|
|
20
|
-
],
|
|
21
|
-
"type": "registry:block"
|
|
22
|
-
}
|
package/public/r/articles-1.json
DELETED
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
|
-
"name": "articles-1",
|
|
4
|
-
"title": "Articles 1",
|
|
5
|
-
"description": "Collection and listing layouts for journals, magazines, and editorial feeds.",
|
|
6
|
-
"registryDependencies": [
|
|
7
|
-
"@fulldev/avatar",
|
|
8
|
-
"@fulldev/section"
|
|
9
|
-
],
|
|
10
|
-
"files": [
|
|
11
|
-
{
|
|
12
|
-
"path": "src/components/blocks/articles-1.astro",
|
|
13
|
-
"content": "---\nimport type { ImageMetadata } from \"astro\"\nimport { Image } from \"astro:assets\"\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Avatar, AvatarFallback, AvatarImage } from \"@/components/ui/avatar\"\nimport {\n Section,\n SectionContainer,\n SectionTitle,\n} from \"@/components/ui/section\"\n\ntype Props = HTMLAttributes<\"section\"> & {\n title: string\n description: string\n articles: {\n image: {\n src: ImageMetadata\n alt: string\n }\n category: string\n title: string\n description: string\n href?: string\n author: {\n image?: ImageMetadata\n initials: string\n name: string\n date: string\n }\n }[]\n}\n\nconst { class: className, title, description, articles, ...props } = Astro.props\n---\n\n<Section class={cn(\"\", className)} {...props}>\n <SectionContainer class=\"flex flex-col gap-8\">\n <div class=\"flex max-w-2xl flex-col gap-4\">\n <SectionTitle>{title}</SectionTitle>\n <p class=\"text-muted-foreground text-base leading-7\">{description}</p>\n </div>\n\n <div class=\"grid gap-6 md:grid-cols-2 lg:grid-cols-3\">\n {articles.map((article) => {\n const Wrapper = article.href != null ? \"a\" : \"div\"\n return (\n <Wrapper\n href={article.href}\n class={cn(\n \"flex h-full flex-col gap-4 rounded-xl p-4\",\n article.href != null &&\n \"group hover:bg-muted/50 focus-visible:ring-ring/50 transition-colors focus-visible:ring-2 focus-visible:outline-none\"\n )}\n >\n <Image\n src={article.image.src}\n alt={article.image.alt}\n class=\"-mx-4 -mt-4 aspect-[16/9] w-[calc(100%+2rem)] max-w-none rounded-lg object-cover transition-opacity group-hover:opacity-85\"\n widths={[480, 720, 960]}\n sizes=\"(min-width: 64rem) 26rem, (min-width: 48rem) 50vw, 100vw\"\n />\n <div class=\"flex flex-col gap-2\">\n <p class=\"text-muted-foreground text-sm font-medium\">\n {article.category}\n </p>\n <h3 class=\"text-foreground line-clamp-2 text-xl leading-snug font-semibold\">\n {article.title}\n </h3>\n <p class=\"text-muted-foreground line-clamp-2 text-sm leading-6\">\n {article.description}\n </p>\n </div>\n <div class=\"mt-auto flex items-center gap-3\">\n <Avatar aria-hidden=\"true\">\n <AvatarImage src={article.author.image} />\n <AvatarFallback>{article.author.initials}</AvatarFallback>\n </Avatar>\n <div class=\"flex flex-col\">\n <p class=\"text-sm font-medium\">{article.author.name}</p>\n <p class=\"text-muted-foreground text-xs\">\n {article.author.date}\n </p>\n </div>\n </div>\n </Wrapper>\n )\n })}\n </div>\n </SectionContainer>\n</Section>\n",
|
|
14
|
-
"type": "registry:block"
|
|
15
|
-
}
|
|
16
|
-
],
|
|
17
|
-
"docs": "https://ui.full.dev/blocks/articles/",
|
|
18
|
-
"categories": [
|
|
19
|
-
"articles"
|
|
20
|
-
],
|
|
21
|
-
"type": "registry:block"
|
|
22
|
-
}
|
package/public/r/articles-2.json
DELETED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
|
-
"name": "articles-2",
|
|
4
|
-
"title": "Articles 2",
|
|
5
|
-
"description": "Collection and listing layouts for journals, magazines, and editorial feeds.",
|
|
6
|
-
"registryDependencies": [
|
|
7
|
-
"@fulldev/avatar",
|
|
8
|
-
"@fulldev/badge",
|
|
9
|
-
"@fulldev/section"
|
|
10
|
-
],
|
|
11
|
-
"files": [
|
|
12
|
-
{
|
|
13
|
-
"path": "src/components/blocks/articles-2.astro",
|
|
14
|
-
"content": "---\nimport type { ImageMetadata } from \"astro\"\nimport { Image } from \"astro:assets\"\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Avatar, AvatarFallback, AvatarImage } from \"@/components/ui/avatar\"\nimport { Badge } from \"@/components/ui/badge\"\nimport { Section, SectionContainer } from \"@/components/ui/section\"\n\ntype Props = HTMLAttributes<\"section\"> & {\n title: string\n description: string\n featured: {\n image: {\n src: ImageMetadata\n alt: string\n }\n category: string\n title: string\n description: string\n href?: string\n author: {\n image?: ImageMetadata\n initials: string\n name: string\n date: string\n }\n }\n articles: {\n image: {\n src: ImageMetadata\n alt: string\n }\n category: string\n title: string\n description: string\n href?: string\n author: {\n image?: ImageMetadata\n initials: string\n name: string\n date: string\n }\n }[]\n}\n\nconst {\n class: className,\n title,\n description,\n featured,\n articles,\n ...props\n} = Astro.props\n\nconst FeaturedWrapper = featured.href != null ? \"a\" : \"div\"\n---\n\n<Section class={cn(\"\", className)} {...props}>\n <SectionContainer class=\"flex flex-col gap-8\">\n <div class=\"mx-auto max-w-2xl text-center\">\n <h2 class=\"text-3xl font-semibold tracking-tight text-balance sm:text-4xl\">\n {title}\n </h2>\n <p class=\"text-muted-foreground mt-2 text-base leading-7 text-balance\">\n {description}\n </p>\n </div>\n\n <FeaturedWrapper\n href={featured.href}\n class={cn(\n \"grid gap-6 rounded-xl lg:grid-cols-2 lg:items-center lg:pr-4\",\n featured.href != null &&\n \"group hover:bg-muted/50 focus-visible:ring-ring/50 transition-colors focus-visible:ring-2 focus-visible:outline-none\"\n )}\n >\n <Image\n src={featured.image.src}\n alt={featured.image.alt}\n class=\"aspect-[4/3] rounded-lg object-cover transition-opacity group-hover:opacity-85\"\n widths={[640, 960, 1280]}\n sizes=\"(min-width: 80rem) 616px, (min-width: 64rem) 50vw, 100vw\"\n />\n <div class=\"flex flex-col gap-4\">\n <Badge variant=\"outline\" class=\"w-fit\">\n {featured.category}\n </Badge>\n <h3 class=\"text-foreground text-2xl leading-tight font-semibold sm:text-3xl\">\n {featured.title}\n </h3>\n <p class=\"text-muted-foreground text-base leading-7\">\n {featured.description}\n </p>\n <div class=\"flex items-center gap-3\">\n <Avatar aria-hidden=\"true\">\n <AvatarImage src={featured.author.image} />\n <AvatarFallback>{featured.author.initials}</AvatarFallback>\n </Avatar>\n <div class=\"flex flex-col\">\n <p class=\"text-sm font-medium\">{featured.author.name}</p>\n <p class=\"text-muted-foreground text-xs\">{featured.author.date}</p>\n </div>\n </div>\n </div>\n </FeaturedWrapper>\n\n <div class=\"grid gap-6 md:grid-cols-2 lg:grid-cols-3\">\n {articles.map((article) => {\n const Wrapper = article.href != null ? \"a\" : \"div\"\n return (\n <Wrapper\n href={article.href}\n class={cn(\n \"flex h-full flex-col gap-4 rounded-xl p-4\",\n article.href != null &&\n \"group hover:bg-muted/50 focus-visible:ring-ring/50 transition-colors focus-visible:ring-2 focus-visible:outline-none\"\n )}\n >\n <Image\n src={article.image.src}\n alt={article.image.alt}\n class=\"-mx-4 -mt-4 aspect-[16/9] w-[calc(100%+2rem)] max-w-none rounded-lg object-cover transition-opacity group-hover:opacity-85\"\n widths={[480, 720]}\n sizes=\"(min-width: 64rem) 26rem, (min-width: 48rem) 50vw, 100vw\"\n />\n <div class=\"flex flex-col gap-2\">\n <p class=\"text-muted-foreground text-sm font-medium\">\n {article.category}\n </p>\n <h3 class=\"text-foreground line-clamp-2 text-lg leading-snug font-semibold\">\n {article.title}\n </h3>\n <p class=\"text-muted-foreground line-clamp-2 text-sm leading-6\">\n {article.description}\n </p>\n </div>\n <div class=\"mt-auto flex items-center gap-3\">\n <Avatar aria-hidden=\"true\">\n <AvatarImage src={article.author.image} />\n <AvatarFallback>{article.author.initials}</AvatarFallback>\n </Avatar>\n <div class=\"flex flex-col\">\n <p class=\"text-sm font-medium\">{article.author.name}</p>\n <p class=\"text-muted-foreground text-xs\">\n {article.author.date}\n </p>\n </div>\n </div>\n </Wrapper>\n )\n })}\n </div>\n </SectionContainer>\n</Section>\n",
|
|
15
|
-
"type": "registry:block"
|
|
16
|
-
}
|
|
17
|
-
],
|
|
18
|
-
"docs": "https://ui.full.dev/blocks/articles/",
|
|
19
|
-
"categories": [
|
|
20
|
-
"articles"
|
|
21
|
-
],
|
|
22
|
-
"type": "registry:block"
|
|
23
|
-
}
|
package/public/r/articles-3.json
DELETED
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
|
-
"name": "articles-3",
|
|
4
|
-
"title": "Articles 3",
|
|
5
|
-
"description": "Collection and listing layouts for journals, magazines, and editorial feeds.",
|
|
6
|
-
"registryDependencies": [
|
|
7
|
-
"@fulldev/avatar",
|
|
8
|
-
"@fulldev/section"
|
|
9
|
-
],
|
|
10
|
-
"files": [
|
|
11
|
-
{
|
|
12
|
-
"path": "src/components/blocks/articles-3.astro",
|
|
13
|
-
"content": "---\nimport type { ImageMetadata } from \"astro\"\nimport { Image } from \"astro:assets\"\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Avatar, AvatarFallback, AvatarImage } from \"@/components/ui/avatar\"\nimport {\n Section,\n SectionContainer,\n SectionTitle,\n} from \"@/components/ui/section\"\n\ntype Props = HTMLAttributes<\"section\"> & {\n title: string\n articles: {\n image: {\n src: ImageMetadata\n alt: string\n }\n category: string\n title: string\n description: string\n href?: string\n author: {\n image?: ImageMetadata\n initials: string\n name: string\n date: string\n }\n }[]\n}\n\nconst { class: className, title, articles, ...props } = Astro.props\n---\n\n<Section class={cn(\"\", className)} {...props}>\n <SectionContainer class=\"flex flex-col gap-8\">\n <div class=\"flex flex-wrap items-end justify-between gap-4\">\n <div class=\"flex flex-col gap-4\">\n <SectionTitle>{title}</SectionTitle>\n </div>\n </div>\n\n <div class=\"grid gap-6 md:grid-cols-2 lg:grid-cols-4\">\n {articles.map((article) => {\n const Wrapper = article.href != null ? \"a\" : \"div\"\n return (\n <Wrapper\n href={article.href}\n class={cn(\n \"bg-muted/50 flex h-full flex-col gap-4 rounded-xl p-4\",\n article.href != null &&\n \"group hover:bg-muted focus-visible:ring-ring/50 transition-colors focus-visible:ring-2 focus-visible:outline-none\"\n )}\n >\n <Image\n src={article.image.src}\n alt={article.image.alt}\n class=\"-mx-4 -mt-4 aspect-[16/9] w-[calc(100%+2rem)] max-w-none rounded-lg object-cover transition-opacity group-hover:opacity-85\"\n widths={[480, 720]}\n sizes=\"(min-width: 64rem) 18rem, (min-width: 48rem) 50vw, 100vw\"\n />\n <div class=\"flex flex-col gap-2\">\n <p class=\"text-muted-foreground text-sm font-medium\">\n {article.category}\n </p>\n <h3 class=\"text-foreground line-clamp-2 text-lg leading-snug font-semibold\">\n {article.title}\n </h3>\n <p class=\"text-muted-foreground line-clamp-2 text-sm leading-6\">\n {article.description}\n </p>\n </div>\n <div class=\"mt-auto flex items-center gap-3\">\n <Avatar aria-hidden=\"true\">\n <AvatarImage src={article.author.image} />\n <AvatarFallback>{article.author.initials}</AvatarFallback>\n </Avatar>\n <div class=\"flex flex-col\">\n <p class=\"text-sm font-medium\">{article.author.name}</p>\n <p class=\"text-muted-foreground text-xs\">\n {article.author.date}\n </p>\n </div>\n </div>\n </Wrapper>\n )\n })}\n </div>\n </SectionContainer>\n</Section>\n",
|
|
14
|
-
"type": "registry:block"
|
|
15
|
-
}
|
|
16
|
-
],
|
|
17
|
-
"docs": "https://ui.full.dev/blocks/articles/",
|
|
18
|
-
"categories": [
|
|
19
|
-
"articles"
|
|
20
|
-
],
|
|
21
|
-
"type": "registry:block"
|
|
22
|
-
}
|
package/public/r/articles-4.json
DELETED
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
|
-
"name": "articles-4",
|
|
4
|
-
"title": "Articles 4",
|
|
5
|
-
"description": "Collection and listing layouts for journals, magazines, and editorial feeds.",
|
|
6
|
-
"registryDependencies": [
|
|
7
|
-
"@fulldev/avatar",
|
|
8
|
-
"@fulldev/section"
|
|
9
|
-
],
|
|
10
|
-
"files": [
|
|
11
|
-
{
|
|
12
|
-
"path": "src/components/blocks/articles-4.astro",
|
|
13
|
-
"content": "---\nimport type { ImageMetadata } from \"astro\"\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Avatar, AvatarFallback, AvatarImage } from \"@/components/ui/avatar\"\nimport { Section, SectionContainer } from \"@/components/ui/section\"\n\ntype Props = HTMLAttributes<\"section\"> & {\n title: string\n description: string\n articles: {\n category: string\n title: string\n description: string\n href?: string\n author: {\n image?: ImageMetadata\n initials: string\n name: string\n date: string\n }\n }[]\n}\n\nconst { class: className, title, description, articles, ...props } = Astro.props\n---\n\n<Section class={cn(\"\", className)} {...props}>\n <SectionContainer class=\"flex flex-col gap-8\">\n <div class=\"mx-auto max-w-2xl text-center\">\n <h2 class=\"text-3xl font-semibold tracking-tight text-balance sm:text-4xl\">\n {title}\n </h2>\n <p class=\"text-muted-foreground mt-2 text-base leading-7 text-balance\">\n {description}\n </p>\n </div>\n\n <div class=\"grid gap-6 md:grid-cols-2 lg:grid-cols-3\">\n {articles.map((article) => {\n const Wrapper = article.href != null ? \"a\" : \"div\"\n return (\n <Wrapper\n href={article.href}\n class={cn(\n \"flex h-full flex-col gap-4 rounded-xl border p-6\",\n article.href != null &&\n \"group hover:bg-muted/50 focus-visible:ring-ring/50 transition-colors focus-visible:ring-2 focus-visible:outline-none\"\n )}\n >\n <div class=\"flex flex-col gap-2\">\n <p class=\"text-muted-foreground text-sm font-medium\">\n {article.category}\n </p>\n <h3 class=\"text-foreground line-clamp-2 text-xl leading-snug font-semibold\">\n {article.title}\n </h3>\n <p class=\"text-muted-foreground line-clamp-2 text-sm leading-6\">\n {article.description}\n </p>\n </div>\n <div class=\"mt-auto flex items-center gap-3\">\n <Avatar aria-hidden=\"true\">\n <AvatarImage src={article.author.image} />\n <AvatarFallback>{article.author.initials}</AvatarFallback>\n </Avatar>\n <div class=\"flex flex-col\">\n <p class=\"text-sm font-medium\">{article.author.name}</p>\n <p class=\"text-muted-foreground text-xs\">\n {article.author.date}\n </p>\n </div>\n </div>\n </Wrapper>\n )\n })}\n </div>\n </SectionContainer>\n</Section>\n",
|
|
14
|
-
"type": "registry:block"
|
|
15
|
-
}
|
|
16
|
-
],
|
|
17
|
-
"docs": "https://ui.full.dev/blocks/articles/",
|
|
18
|
-
"categories": [
|
|
19
|
-
"articles"
|
|
20
|
-
],
|
|
21
|
-
"type": "registry:block"
|
|
22
|
-
}
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
|
-
"name": "aspect-ratio-examples",
|
|
4
|
-
"title": "Aspect Ratio examples",
|
|
5
|
-
"description": "The examples from the shadcn/ui Aspect Ratio docs.",
|
|
6
|
-
"registryDependencies": [
|
|
7
|
-
"@fulldev/aspect-ratio"
|
|
8
|
-
],
|
|
9
|
-
"files": [
|
|
10
|
-
{
|
|
11
|
-
"path": "src/components/examples/aspect-ratio/aspect-ratio-demo.astro",
|
|
12
|
-
"content": "---\nimport { AspectRatio } from \"@/components/ui/aspect-ratio\"\n---\n\n<AspectRatio ratio={16 / 9} class=\"bg-muted w-full max-w-sm rounded-lg\">\n <img\n src=\"https://avatar.vercel.sh/shadcn1\"\n alt=\"Photo\"\n class=\"absolute inset-0 size-full rounded-lg object-cover grayscale dark:brightness-20\"\n />\n</AspectRatio>\n",
|
|
13
|
-
"type": "registry:component"
|
|
14
|
-
},
|
|
15
|
-
{
|
|
16
|
-
"path": "src/components/examples/aspect-ratio/aspect-ratio-portrait.astro",
|
|
17
|
-
"content": "---\nimport { AspectRatio } from \"@/components/ui/aspect-ratio\"\n---\n\n<AspectRatio ratio={9 / 16} class=\"bg-muted w-full max-w-[10rem] rounded-lg\">\n <img\n src=\"https://avatar.vercel.sh/shadcn1\"\n alt=\"Photo\"\n class=\"absolute inset-0 size-full rounded-lg object-cover grayscale dark:brightness-20\"\n />\n</AspectRatio>\n",
|
|
18
|
-
"type": "registry:component"
|
|
19
|
-
},
|
|
20
|
-
{
|
|
21
|
-
"path": "src/components/examples/aspect-ratio/aspect-ratio-rtl.astro",
|
|
22
|
-
"content": "---\nimport { AspectRatio } from \"@/components/ui/aspect-ratio\"\n\nconst translations = {\n en: {\n dir: \"ltr\",\n values: {\n caption: \"Beautiful landscape\",\n },\n },\n ar: {\n dir: \"rtl\",\n values: {\n caption: \"منظر طبيعي جميل\",\n },\n },\n he: {\n dir: \"rtl\",\n values: {\n caption: \"נוף יפה\",\n },\n },\n} as const\n\nconst { dir, values: t } = translations.ar\n---\n\n<figure class=\"w-full max-w-sm\" dir={dir}>\n <AspectRatio ratio={16 / 9} class=\"bg-muted rounded-lg\">\n <img\n src=\"https://avatar.vercel.sh/shadcn1\"\n alt=\"Photo\"\n class=\"absolute inset-0 size-full rounded-lg object-cover grayscale dark:brightness-20\"\n />\n </AspectRatio>\n <figcaption class=\"text-muted-foreground mt-2 text-center text-sm\">\n {t.caption}\n </figcaption>\n</figure>\n",
|
|
23
|
-
"type": "registry:component"
|
|
24
|
-
},
|
|
25
|
-
{
|
|
26
|
-
"path": "src/components/examples/aspect-ratio/aspect-ratio-square.astro",
|
|
27
|
-
"content": "---\nimport { AspectRatio } from \"@/components/ui/aspect-ratio\"\n---\n\n<AspectRatio ratio={1 / 1} class=\"bg-muted w-full max-w-[12rem] rounded-lg\">\n <img\n src=\"https://avatar.vercel.sh/shadcn1\"\n alt=\"Photo\"\n class=\"absolute inset-0 size-full rounded-lg object-cover grayscale dark:brightness-20\"\n />\n</AspectRatio>\n",
|
|
28
|
-
"type": "registry:component"
|
|
29
|
-
}
|
|
30
|
-
],
|
|
31
|
-
"docs": "https://ui.full.dev/components/aspect-ratio/",
|
|
32
|
-
"type": "registry:example"
|
|
33
|
-
}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
|
-
"name": "aspect-ratio",
|
|
4
|
-
"title": "Aspect Ratio",
|
|
5
|
-
"description": "Displays content within a desired ratio.",
|
|
6
|
-
"files": [
|
|
7
|
-
{
|
|
8
|
-
"path": "src/components/ui/aspect-ratio/aspect-ratio.astro",
|
|
9
|
-
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype Props = HTMLAttributes<\"div\"> & {\n ratio: number\n}\n\nconst { class: className, ratio, style, ...props } = Astro.props\n\nconst resolvedStyle =\n typeof style === \"string\"\n ? `--ratio: ${ratio}; ${style}`\n : { \"--ratio\": ratio, ...(style ?? {}) }\n---\n\n<div\n data-slot=\"aspect-ratio\"\n style={resolvedStyle}\n class={cn(\"relative aspect-(--ratio)\", className)}\n {...props}\n>\n <slot />\n</div>\n",
|
|
10
|
-
"type": "registry:ui"
|
|
11
|
-
},
|
|
12
|
-
{
|
|
13
|
-
"path": "src/components/ui/aspect-ratio/index.ts",
|
|
14
|
-
"content": "export { default as AspectRatio } from \"./aspect-ratio.astro\"\n",
|
|
15
|
-
"type": "registry:ui"
|
|
16
|
-
}
|
|
17
|
-
],
|
|
18
|
-
"docs": "https://ui.full.dev/components/aspect-ratio/",
|
|
19
|
-
"categories": [
|
|
20
|
-
"ui"
|
|
21
|
-
],
|
|
22
|
-
"type": "registry:ui"
|
|
23
|
-
}
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
|
-
"name": "attachment-examples",
|
|
4
|
-
"title": "Attachment examples",
|
|
5
|
-
"description": "The examples from the shadcn/ui Attachment docs.",
|
|
6
|
-
"dependencies": [
|
|
7
|
-
"@lucide/astro"
|
|
8
|
-
],
|
|
9
|
-
"registryDependencies": [
|
|
10
|
-
"@fulldev/attachment",
|
|
11
|
-
"@fulldev/dialog",
|
|
12
|
-
"@fulldev/spinner"
|
|
13
|
-
],
|
|
14
|
-
"files": [
|
|
15
|
-
{
|
|
16
|
-
"path": "src/components/examples/attachment/attachment-demo.astro",
|
|
17
|
-
"content": "---\nimport FileCodeIcon from \"@lucide/astro/icons/file-code\"\nimport XIcon from \"@lucide/astro/icons/x\"\n\nimport {\n Attachment,\n AttachmentAction,\n AttachmentActions,\n AttachmentContent,\n AttachmentDescription,\n AttachmentGroup,\n AttachmentMedia,\n AttachmentTitle,\n} from \"@/components/ui/attachment\"\nimport { Spinner } from \"@/components/ui/spinner\"\n\nconst images = [\n {\n name: \"workspace.png\",\n meta: \"PNG · 820 KB\",\n src: \"https://images.unsplash.com/photo-1497366754035-f200968a6e72?w=900&auto=format&fit=crop&q=80\",\n alt: \"Workspace\",\n },\n {\n name: \"desk-reference.jpg\",\n meta: \"JPG · 1.1 MB\",\n src: \"https://images.unsplash.com/photo-1497215728101-856f4ea42174?w=900&auto=format&fit=crop&q=80\",\n alt: \"Desk\",\n },\n {\n name: \"office-reference.jpg\",\n meta: \"JPG · 940 KB\",\n src: \"https://images.unsplash.com/photo-1497366811353-6870744d04b2?w=900&auto=format&fit=crop&q=80\",\n alt: \"Office\",\n },\n]\n---\n\n<div class=\"mx-auto flex w-full max-w-sm flex-col gap-3 py-12\">\n <AttachmentGroup>\n {images.map((image) => (\n <Attachment orientation=\"vertical\">\n <AttachmentMedia variant=\"image\">\n <img src={image.src} alt={image.alt} />\n </AttachmentMedia>\n <AttachmentContent>\n <AttachmentTitle>{image.name}</AttachmentTitle>\n <AttachmentDescription>{image.meta}</AttachmentDescription>\n </AttachmentContent>\n </Attachment>\n ))}\n </AttachmentGroup>\n <Attachment state=\"uploading\" class=\"w-full\">\n <AttachmentMedia>\n <Spinner />\n </AttachmentMedia>\n <AttachmentContent>\n <AttachmentTitle>sales-dashboard.pdf</AttachmentTitle>\n <AttachmentDescription>Uploading · 64%</AttachmentDescription>\n </AttachmentContent>\n <AttachmentActions>\n <AttachmentAction aria-label=\"Cancel upload\">\n <XIcon />\n </AttachmentAction>\n </AttachmentActions>\n </Attachment>\n <Attachment class=\"w-full\">\n <AttachmentMedia>\n <FileCodeIcon />\n </AttachmentMedia>\n <AttachmentContent>\n <AttachmentTitle>message-renderer.tsx</AttachmentTitle>\n <AttachmentDescription>TypeScript · 12 KB</AttachmentDescription>\n </AttachmentContent>\n <AttachmentActions>\n <AttachmentAction aria-label=\"Remove message-renderer.tsx\">\n <XIcon />\n </AttachmentAction>\n </AttachmentActions>\n </Attachment>\n</div>\n",
|
|
18
|
-
"type": "registry:component"
|
|
19
|
-
},
|
|
20
|
-
{
|
|
21
|
-
"path": "src/components/examples/attachment/attachment-group.astro",
|
|
22
|
-
"content": "---\nimport FileCodeIcon from \"@lucide/astro/icons/file-code\"\nimport FileTextIcon from \"@lucide/astro/icons/file-text\"\nimport TableIcon from \"@lucide/astro/icons/table\"\nimport XIcon from \"@lucide/astro/icons/x\"\n\nimport {\n Attachment,\n AttachmentAction,\n AttachmentActions,\n AttachmentContent,\n AttachmentDescription,\n AttachmentGroup,\n AttachmentMedia,\n AttachmentTitle,\n} from \"@/components/ui/attachment\"\n\ntype Item = {\n name: string\n meta: string\n icon?: typeof FileTextIcon\n src?: string\n}\n\nconst items: Item[] = [\n { name: \"briefing-notes.pdf\", meta: \"PDF · 1.4 MB\", icon: FileTextIcon },\n {\n name: \"workspace.png\",\n meta: \"PNG · 820 KB\",\n src: \"https://images.unsplash.com/photo-1497366754035-f200968a6e72?w=900&auto=format&fit=crop&q=80\",\n },\n { name: \"customers.csv\", meta: \"CSV · 18 KB\", icon: TableIcon },\n { name: \"renderer.tsx\", meta: \"TSX · 12 KB\", icon: FileCodeIcon },\n]\n---\n\n<div class=\"mx-auto w-full max-w-sm py-12\">\n <AttachmentGroup class=\"w-full\">\n {items.map((item) => {\n const Icon = item.icon\n\n return (\n <Attachment class=\"w-64\">\n {item.src ? (\n <AttachmentMedia variant=\"image\">\n <img src={item.src} alt={item.name} />\n </AttachmentMedia>\n ) : Icon ? (\n <AttachmentMedia>\n <Icon />\n </AttachmentMedia>\n ) : null}\n <AttachmentContent>\n <AttachmentTitle>{item.name}</AttachmentTitle>\n <AttachmentDescription>{item.meta}</AttachmentDescription>\n </AttachmentContent>\n <AttachmentActions>\n <AttachmentAction aria-label={`Remove ${item.name}`}>\n <XIcon />\n </AttachmentAction>\n </AttachmentActions>\n </Attachment>\n )\n })}\n </AttachmentGroup>\n</div>\n",
|
|
23
|
-
"type": "registry:component"
|
|
24
|
-
},
|
|
25
|
-
{
|
|
26
|
-
"path": "src/components/examples/attachment/attachment-image.astro",
|
|
27
|
-
"content": "---\nimport XIcon from \"@lucide/astro/icons/x\"\n\nimport {\n Attachment,\n AttachmentAction,\n AttachmentActions,\n AttachmentContent,\n AttachmentDescription,\n AttachmentGroup,\n AttachmentMedia,\n AttachmentTitle,\n AttachmentTrigger,\n} from \"@/components/ui/attachment\"\n\nconst images = [\n {\n name: \"workspace.png\",\n meta: \"PNG · 820 KB\",\n src: \"https://images.unsplash.com/photo-1497366754035-f200968a6e72?w=900&auto=format&fit=crop&q=80\",\n alt: \"Workspace\",\n },\n {\n name: \"desk-reference.jpg\",\n meta: \"JPG · 1.1 MB\",\n src: \"https://images.unsplash.com/photo-1497215728101-856f4ea42174?w=900&auto=format&fit=crop&q=80\",\n alt: \"Desk\",\n },\n {\n name: \"office-reference.jpg\",\n meta: \"JPG · 940 KB\",\n src: \"https://images.unsplash.com/photo-1497366811353-6870744d04b2?w=900&auto=format&fit=crop&q=80\",\n alt: \"Office\",\n },\n]\n---\n\n<div class=\"mx-auto w-full max-w-sm py-12\">\n <AttachmentGroup class=\"w-full\">\n {images.map((image) => (\n <Attachment orientation=\"vertical\">\n <AttachmentMedia variant=\"image\">\n <img src={image.src} alt={image.alt} />\n </AttachmentMedia>\n <AttachmentContent>\n <AttachmentTitle>{image.name}</AttachmentTitle>\n <AttachmentDescription>{image.meta}</AttachmentDescription>\n </AttachmentContent>\n <AttachmentActions>\n <AttachmentAction aria-label={`Remove ${image.name}`}>\n <XIcon />\n </AttachmentAction>\n </AttachmentActions>\n <AttachmentTrigger\n as=\"a\"\n href={image.src}\n target=\"_blank\"\n rel=\"noreferrer\"\n aria-label={`Open ${image.name}`}\n />\n </Attachment>\n ))}\n </AttachmentGroup>\n</div>\n",
|
|
28
|
-
"type": "registry:component"
|
|
29
|
-
},
|
|
30
|
-
{
|
|
31
|
-
"path": "src/components/examples/attachment/attachment-sizes.astro",
|
|
32
|
-
"content": "---\nimport FileTextIcon from \"@lucide/astro/icons/file-text\"\n\nimport {\n Attachment,\n AttachmentContent,\n AttachmentDescription,\n AttachmentMedia,\n AttachmentTitle,\n} from \"@/components/ui/attachment\"\n---\n\n<div class=\"mx-auto flex w-full max-w-sm flex-col gap-3 py-12\">\n <Attachment size=\"default\" class=\"w-full\">\n <AttachmentMedia>\n <FileTextIcon />\n </AttachmentMedia>\n <AttachmentContent>\n <AttachmentTitle>Default attachment</AttachmentTitle>\n <AttachmentDescription>PDF · 2.4 MB</AttachmentDescription>\n </AttachmentContent>\n </Attachment>\n <Attachment size=\"sm\" class=\"w-full\">\n <AttachmentMedia>\n <FileTextIcon />\n </AttachmentMedia>\n <AttachmentContent>\n <AttachmentTitle>Small attachment</AttachmentTitle>\n <AttachmentDescription>PDF · 2.4 MB</AttachmentDescription>\n </AttachmentContent>\n </Attachment>\n <Attachment size=\"xs\" class=\"w-full\">\n <AttachmentMedia>\n <FileTextIcon />\n </AttachmentMedia>\n <AttachmentContent>\n <AttachmentTitle>Extra small attachment</AttachmentTitle>\n </AttachmentContent>\n </Attachment>\n</div>\n",
|
|
33
|
-
"type": "registry:component"
|
|
34
|
-
},
|
|
35
|
-
{
|
|
36
|
-
"path": "src/components/examples/attachment/attachment-states.astro",
|
|
37
|
-
"content": "---\nimport CheckIcon from \"@lucide/astro/icons/check\"\nimport ClockIcon from \"@lucide/astro/icons/clock\"\nimport FileWarningIcon from \"@lucide/astro/icons/file-exclamation-point\"\nimport FileTextIcon from \"@lucide/astro/icons/file-text\"\nimport RefreshCwIcon from \"@lucide/astro/icons/refresh-cw\"\nimport XIcon from \"@lucide/astro/icons/x\"\n\nimport {\n Attachment,\n AttachmentAction,\n AttachmentActions,\n AttachmentContent,\n AttachmentDescription,\n AttachmentMedia,\n AttachmentTitle,\n} from \"@/components/ui/attachment\"\nimport { Spinner } from \"@/components/ui/spinner\"\n---\n\n<div class=\"mx-auto flex w-full max-w-sm flex-col gap-2 py-12\">\n <Attachment state=\"idle\" class=\"w-full\">\n <AttachmentMedia>\n <ClockIcon />\n </AttachmentMedia>\n <AttachmentContent>\n <AttachmentTitle>selected-file.pdf</AttachmentTitle>\n <AttachmentDescription>Ready to upload</AttachmentDescription>\n </AttachmentContent>\n <AttachmentActions>\n <AttachmentAction aria-label=\"Remove selected-file.pdf\">\n <XIcon />\n </AttachmentAction>\n </AttachmentActions>\n </Attachment>\n <Attachment state=\"uploading\" class=\"w-full\">\n <AttachmentMedia>\n <Spinner />\n </AttachmentMedia>\n <AttachmentContent>\n <AttachmentTitle>design-system.zip</AttachmentTitle>\n <AttachmentDescription>Uploading · 64%</AttachmentDescription>\n </AttachmentContent>\n <AttachmentActions>\n <AttachmentAction aria-label=\"Cancel upload\">\n <XIcon />\n </AttachmentAction>\n </AttachmentActions>\n </Attachment>\n <Attachment state=\"processing\" class=\"w-full\">\n <AttachmentMedia>\n <FileTextIcon />\n </AttachmentMedia>\n <AttachmentContent>\n <AttachmentTitle>market-research.pdf</AttachmentTitle>\n <AttachmentDescription>Processing document</AttachmentDescription>\n </AttachmentContent>\n <AttachmentActions>\n <AttachmentAction aria-label=\"Remove market-research.pdf\">\n <XIcon />\n </AttachmentAction>\n </AttachmentActions>\n </Attachment>\n <Attachment state=\"error\" class=\"w-full\">\n <AttachmentMedia>\n <FileWarningIcon />\n </AttachmentMedia>\n <AttachmentContent>\n <AttachmentTitle>financial-model.xlsx</AttachmentTitle>\n <AttachmentDescription>Upload failed. Try again.</AttachmentDescription>\n </AttachmentContent>\n <AttachmentActions>\n <AttachmentAction aria-label=\"Retry upload\">\n <RefreshCwIcon />\n </AttachmentAction>\n <AttachmentAction aria-label=\"Remove financial-model.xlsx\">\n <XIcon />\n </AttachmentAction>\n </AttachmentActions>\n </Attachment>\n <Attachment state=\"done\" class=\"w-full\">\n <AttachmentMedia>\n <CheckIcon />\n </AttachmentMedia>\n <AttachmentContent>\n <AttachmentTitle>uploaded-report.pdf</AttachmentTitle>\n <AttachmentDescription>Uploaded · 1.8 MB</AttachmentDescription>\n </AttachmentContent>\n <AttachmentActions>\n <AttachmentAction aria-label=\"Remove uploaded-report.pdf\">\n <XIcon />\n </AttachmentAction>\n </AttachmentActions>\n </Attachment>\n</div>\n",
|
|
38
|
-
"type": "registry:component"
|
|
39
|
-
},
|
|
40
|
-
{
|
|
41
|
-
"path": "src/components/examples/attachment/attachment-trigger.astro",
|
|
42
|
-
"content": "---\nimport CopyIcon from \"@lucide/astro/icons/copy\"\nimport FileSearchIcon from \"@lucide/astro/icons/file-search\"\nimport XIcon from \"@lucide/astro/icons/x\"\n\nimport {\n Attachment,\n AttachmentAction,\n AttachmentActions,\n AttachmentContent,\n AttachmentDescription,\n AttachmentMedia,\n AttachmentTitle,\n AttachmentTrigger,\n} from \"@/components/ui/attachment\"\nimport {\n Dialog,\n DialogContent,\n DialogDescription,\n DialogHeader,\n DialogTitle,\n} from \"@/components/ui/dialog\"\n---\n\n<div class=\"mx-auto w-full max-w-sm py-12\">\n <Dialog>\n <Attachment class=\"w-full\">\n <AttachmentMedia>\n <FileSearchIcon />\n </AttachmentMedia>\n <AttachmentContent>\n <AttachmentTitle>research-summary.pdf</AttachmentTitle>\n <AttachmentDescription>Open preview dialog</AttachmentDescription>\n </AttachmentContent>\n <AttachmentActions>\n <AttachmentAction aria-label=\"Copy link\">\n <CopyIcon />\n </AttachmentAction>\n <AttachmentAction aria-label=\"Remove research-summary.pdf\">\n <XIcon />\n </AttachmentAction>\n </AttachmentActions>\n <AttachmentTrigger\n data-slot=\"dialog-trigger\"\n aria-label=\"Preview research-summary.pdf\"\n />\n </Attachment>\n <DialogContent class=\"sm:max-w-md\">\n <DialogHeader>\n <DialogTitle>research-summary.pdf</DialogTitle>\n <DialogDescription>\n The attachment trigger fills the card and opens the dialog, while the\n actions stay independently clickable above it.\n </DialogDescription>\n </DialogHeader>\n </DialogContent>\n </Dialog>\n</div>\n",
|
|
43
|
-
"type": "registry:component"
|
|
44
|
-
}
|
|
45
|
-
],
|
|
46
|
-
"docs": "https://ui.full.dev/components/attachment/",
|
|
47
|
-
"type": "registry:example"
|
|
48
|
-
}
|
package/public/r/attachment.json
DELETED
|
@@ -1,66 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
3
|
-
"name": "attachment",
|
|
4
|
-
"title": "Attachment",
|
|
5
|
-
"description": "Displays a file or image attachment with media, metadata, state, and actions.",
|
|
6
|
-
"registryDependencies": [
|
|
7
|
-
"@fulldev/button"
|
|
8
|
-
],
|
|
9
|
-
"files": [
|
|
10
|
-
{
|
|
11
|
-
"path": "src/components/ui/attachment/attachment-action.astro",
|
|
12
|
-
"content": "---\nimport type { HTMLTag, Polymorphic } from \"astro/types\"\n\nimport { Button, type ButtonVariantProps } from \"@/components/ui/button\"\n\ntype Props<Tag extends HTMLTag = \"button\"> = Polymorphic<{ as: Tag }> &\n ButtonVariantProps\n\nconst { as, variant = \"ghost\", size = \"icon-xs\", ...props } = Astro.props\n---\n\n<Button\n as={as}\n data-slot=\"attachment-action\"\n variant={variant}\n size={size}\n {...props}\n>\n <slot />\n</Button>\n",
|
|
13
|
-
"type": "registry:ui"
|
|
14
|
-
},
|
|
15
|
-
{
|
|
16
|
-
"path": "src/components/ui/attachment/attachment-actions.astro",
|
|
17
|
-
"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=\"attachment-actions\"\n class={cn(\"group-data-[orientation=vertical]/attachment:absolute group-data-[orientation=vertical]/attachment:top-3 group-data-[orientation=vertical]/attachment:right-3 relative z-20 group-data-[orientation=vertical]/attachment:gap-1 flex shrink-0 items-center\", className)}\n {...props}\n>\n <slot />\n</div>\n",
|
|
18
|
-
"type": "registry:ui"
|
|
19
|
-
},
|
|
20
|
-
{
|
|
21
|
-
"path": "src/components/ui/attachment/attachment-content.astro",
|
|
22
|
-
"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=\"attachment-content\"\n class={cn(\"leading-tight group-data-[orientation=vertical]/attachment:px-1 max-w-full min-w-0 flex-1\", className)}\n {...props}\n>\n <slot />\n</div>\n",
|
|
23
|
-
"type": "registry:ui"
|
|
24
|
-
},
|
|
25
|
-
{
|
|
26
|
-
"path": "src/components/ui/attachment/attachment-description.astro",
|
|
27
|
-
"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=\"attachment-description\"\n class={cn(\n \"mt-0.5 text-xs text-muted-foreground group-data-[state=error]/attachment:text-destructive/80 block max-w-full min-w-0 truncate\",\n className\n )}\n {...props}\n>\n <slot />\n</span>\n",
|
|
28
|
-
"type": "registry:ui"
|
|
29
|
-
},
|
|
30
|
-
{
|
|
31
|
-
"path": "src/components/ui/attachment/attachment-group.astro",
|
|
32
|
-
"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=\"attachment-group\"\n class={cn(\n \"gap-3 scroll-px-1 py-1 flex min-w-0 snap-x snap-mandatory overflow-x-auto overscroll-x-contain *:data-[slot=attachment]:flex-none *:data-[slot=attachment]:snap-start\",\n className\n )}\n {...props}\n>\n <slot />\n</div>\n",
|
|
33
|
-
"type": "registry:ui"
|
|
34
|
-
},
|
|
35
|
-
{
|
|
36
|
-
"path": "src/components/ui/attachment/attachment-media.astro",
|
|
37
|
-
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\nimport { cva, type VariantProps } from \"class-variance-authority\"\n\nimport { cn } from \"@/lib/utils\"\n\nconst attachmentMediaVariants = cva(\n \"bg-muted text-foreground w-10 rounded-lg group-data-[size=sm]/attachment:w-8 group-data-[size=xs]/attachment:w-7 group-data-[size=xs]/attachment:rounded-md [&_svg:not([class*='size-'])]:size-4 group-data-[size=xs]/attachment:[&_svg:not([class*='size-'])]:size-3.5 group-data-[orientation=vertical]/attachment:w-full group-data-[orientation=vertical]/attachment:[&_svg:not([class*='size-'])]:size-6 group-data-[orientation=vertical]/attachment:*:data-[slot=spinner]:size-6! relative flex aspect-square shrink-0 items-center justify-center overflow-hidden group-data-[state=error]/attachment:bg-destructive/10 group-data-[state=error]/attachment:text-destructive [&_svg]:pointer-events-none\",\n {\n variants: {\n variant: {\n icon: \"\",\n image:\n \"opacity-60 group-data-[state=idle]/attachment:opacity-100 group-data-[state=done]/attachment:opacity-100 *:[img]:aspect-square *:[img]:w-full *:[img]:object-cover\",\n },\n },\n defaultVariants: {\n variant: \"icon\",\n },\n }\n)\n\ntype Props = HTMLAttributes<\"div\"> &\n VariantProps<typeof attachmentMediaVariants>\n\nconst { class: className, variant = \"icon\", ...props } = Astro.props\n---\n\n<div\n data-slot=\"attachment-media\"\n data-variant={variant}\n class={cn(attachmentMediaVariants({ variant }), className)}\n {...props}\n>\n <slot />\n</div>\n",
|
|
38
|
-
"type": "registry:ui"
|
|
39
|
-
},
|
|
40
|
-
{
|
|
41
|
-
"path": "src/components/ui/attachment/attachment-title.astro",
|
|
42
|
-
"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=\"attachment-title\"\n class={cn(\n \"font-medium block max-w-full min-w-0 truncate group-data-[state=processing]/attachment:animate-pulse group-data-[state=uploading]/attachment:animate-pulse\",\n className\n )}\n {...props}\n>\n <slot />\n</span>\n",
|
|
43
|
-
"type": "registry:ui"
|
|
44
|
-
},
|
|
45
|
-
{
|
|
46
|
-
"path": "src/components/ui/attachment/attachment-trigger.astro",
|
|
47
|
-
"content": "---\nimport type { HTMLTag, Polymorphic } from \"astro/types\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype Props<Tag extends HTMLTag = \"button\"> = Polymorphic<{ as: Tag }>\n\nconst {\n as: Tag = \"href\" in Astro.props ? \"a\" : \"button\",\n class: className,\n ...props\n} = Astro.props\n\nconst attributes: Record<string, unknown> = { ...props }\nif (Tag === \"button\") attributes.type ??= \"button\"\n---\n\n<Tag\n data-slot=\"attachment-trigger\"\n class={cn(\"absolute inset-0 z-10 outline-none\", className)}\n {...attributes}\n>\n <slot />\n</Tag>\n",
|
|
48
|
-
"type": "registry:ui"
|
|
49
|
-
},
|
|
50
|
-
{
|
|
51
|
-
"path": "src/components/ui/attachment/attachment.astro",
|
|
52
|
-
"content": "---\nimport type { HTMLAttributes } from \"astro/types\"\nimport { cva, type VariantProps } from \"class-variance-authority\"\n\nimport { cn } from \"@/lib/utils\"\n\nconst attachmentVariants = cva(\n \"rounded-xl w-fit focus-within:ring-1 focus-within:ring-ring/50 group/attachment relative flex max-w-full min-w-0 shrink-0 flex-wrap border bg-card text-card-foreground transition-colors has-[>a,>button]:hover:bg-muted/50 data-[state=error]:border-destructive/30 data-[state=idle]:border-dashed\",\n {\n variants: {\n size: {\n default: \"gap-2 has-data-[slot=attachment-content]:px-2.5 has-data-[slot=attachment-content]:py-2 has-data-[slot=attachment-media]:p-2 text-sm\",\n sm: \"gap-2.5 has-data-[slot=attachment-content]:px-2 has-data-[slot=attachment-content]:py-1.5 has-data-[slot=attachment-media]:p-1.5 text-xs\",\n xs: \"gap-1.5 has-data-[slot=attachment-content]:px-1.5 has-data-[slot=attachment-content]:py-1 has-data-[slot=attachment-media]:p-1 text-xs rounded-lg\",\n },\n orientation: {\n horizontal: \"min-w-40 items-center\",\n vertical: \"w-24 has-data-[slot=attachment-content]:w-30 flex-col\",\n },\n },\n defaultVariants: {\n size: \"default\",\n orientation: \"horizontal\",\n },\n }\n)\n\ntype Props = HTMLAttributes<\"div\"> &\n VariantProps<typeof attachmentVariants> & {\n state?: \"idle\" | \"uploading\" | \"processing\" | \"error\" | \"done\"\n }\n\nconst {\n class: className,\n state = \"done\",\n size = \"default\",\n orientation = \"horizontal\",\n ...props\n} = Astro.props\n---\n\n<div\n data-slot=\"attachment\"\n data-state={state}\n data-size={size}\n data-orientation={orientation}\n class={cn(attachmentVariants({ size, orientation }), className)}\n {...props}\n>\n <slot />\n</div>\n",
|
|
53
|
-
"type": "registry:ui"
|
|
54
|
-
},
|
|
55
|
-
{
|
|
56
|
-
"path": "src/components/ui/attachment/index.ts",
|
|
57
|
-
"content": "export { default as Attachment } from \"./attachment.astro\"\nexport { default as AttachmentAction } from \"./attachment-action.astro\"\nexport { default as AttachmentActions } from \"./attachment-actions.astro\"\nexport { default as AttachmentContent } from \"./attachment-content.astro\"\nexport { default as AttachmentDescription } from \"./attachment-description.astro\"\nexport { default as AttachmentGroup } from \"./attachment-group.astro\"\nexport { default as AttachmentMedia } from \"./attachment-media.astro\"\nexport { default as AttachmentTitle } from \"./attachment-title.astro\"\nexport { default as AttachmentTrigger } from \"./attachment-trigger.astro\"\n",
|
|
58
|
-
"type": "registry:ui"
|
|
59
|
-
}
|
|
60
|
-
],
|
|
61
|
-
"docs": "https://ui.full.dev/components/attachment/",
|
|
62
|
-
"categories": [
|
|
63
|
-
"ui"
|
|
64
|
-
],
|
|
65
|
-
"type": "registry:ui"
|
|
66
|
-
}
|