@rimelight/ui 0.0.4 → 0.0.6
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/package.json +36 -6
- package/src/components/BlogPost.astro +181 -0
- package/src/components/DynamicShowcase.astro +681 -0
- package/src/components/ExtendedCarousel.astro +107 -0
- package/src/components/Head.astro +150 -0
- package/src/components/LanguageSwitcher.astro +128 -0
- package/src/components/ProjectPost.astro +183 -0
- package/src/components/RLHead.astro +3 -0
- package/src/components/ThemeToggle.astro +30 -42
- package/src/components/astro/RLAButton.astro +85 -0
- package/src/components/astro/RLAHeader.astro +75 -0
- package/src/components/vue/RLVButton.vue +90 -0
- package/src/components/vue/RLVHeader.vue +78 -0
- package/src/composables/index.ts +1 -0
- package/src/composables/useUi.ts +27 -0
- package/src/config/index.ts +0 -2
- package/src/config/site.config.ts +1 -1
- package/src/env.d.ts +9 -42
- package/src/integrations/index.ts +2 -0
- package/src/integrations/ui.ts +87 -0
- package/src/themes/button.theme.ts +361 -0
- package/src/themes/header.theme.ts +33 -0
- package/src/themes/index.ts +13 -0
- package/src/utils/index.ts +3 -2
- package/i18n-data.json +0 -186
- package/src/components/accordion/Accordion.astro +0 -257
- package/src/components/accordion/AccordionContent.astro +0 -34
- package/src/components/accordion/AccordionItem.astro +0 -29
- package/src/components/accordion/AccordionTrigger.astro +0 -33
- package/src/components/alert/Alert.astro +0 -34
- package/src/components/alert/AlertDescription.astro +0 -15
- package/src/components/alert/AlertTitle.astro +0 -17
- package/src/components/alert-dialog/AlertDialog.astro +0 -275
- package/src/components/alert-dialog/AlertDialogAction.astro +0 -46
- package/src/components/alert-dialog/AlertDialogCancel.astro +0 -46
- package/src/components/alert-dialog/AlertDialogContent.astro +0 -52
- package/src/components/alert-dialog/AlertDialogDescription.astro +0 -18
- package/src/components/alert-dialog/AlertDialogFooter.astro +0 -16
- package/src/components/alert-dialog/AlertDialogHeader.astro +0 -14
- package/src/components/alert-dialog/AlertDialogTitle.astro +0 -20
- package/src/components/alert-dialog/AlertDialogTrigger.astro +0 -47
- package/src/components/aspect-ratio/AspectRatio.astro +0 -32
- package/src/components/avatar/Avatar.astro +0 -29
- package/src/components/avatar/AvatarFallback.astro +0 -18
- package/src/components/avatar/AvatarImage.astro +0 -66
- package/src/components/badge/Badge.astro +0 -57
- package/src/components/breadcrumb/Breadcrumb.astro +0 -12
- package/src/components/breadcrumb/BreadcrumbEllipsis.astro +0 -29
- package/src/components/breadcrumb/BreadcrumbItem.astro +0 -15
- package/src/components/breadcrumb/BreadcrumbLink.astro +0 -24
- package/src/components/breadcrumb/BreadcrumbList.astro +0 -17
- package/src/components/breadcrumb/BreadcrumbPage.astro +0 -22
- package/src/components/breadcrumb/BreadcrumbSeparator.astro +0 -24
- package/src/components/button/Button.astro +0 -58
- package/src/components/button-group/ButtonGroup.astro +0 -64
- package/src/components/button-group/ButtonGroupSeparator.astro +0 -20
- package/src/components/button-group/ButtonGroupText.astro +0 -19
- package/src/components/card/Card.astro +0 -36
- package/src/components/card/CardAction.astro +0 -16
- package/src/components/card/CardContent.astro +0 -16
- package/src/components/card/CardDescription.astro +0 -16
- package/src/components/card/CardFooter.astro +0 -16
- package/src/components/card/CardHeader.astro +0 -19
- package/src/components/card/CardTitle.astro +0 -16
- package/src/components/carousel/Carousel.astro +0 -55
- package/src/components/carousel/CarouselContent.astro +0 -26
- package/src/components/carousel/CarouselItem.astro +0 -26
- package/src/components/carousel/CarouselNext.astro +0 -39
- package/src/components/carousel/CarouselPrevious.astro +0 -41
- package/src/components/carousel/carousel-script.ts +0 -188
- package/src/components/carousel/index.ts +0 -1
- package/src/components/checkbox/Checkbox.astro +0 -133
- package/src/components/collapsible/Collapsible.astro +0 -161
- package/src/components/collapsible/CollapsibleContent.astro +0 -22
- package/src/components/collapsible/CollapsibleTrigger.astro +0 -44
- package/src/components/dialog/Dialog.astro +0 -389
- package/src/components/dialog/DialogClose.astro +0 -35
- package/src/components/dialog/DialogContent.astro +0 -78
- package/src/components/dialog/DialogDescription.astro +0 -14
- package/src/components/dialog/DialogFooter.astro +0 -14
- package/src/components/dialog/DialogHeader.astro +0 -14
- package/src/components/dialog/DialogTitle.astro +0 -18
- package/src/components/dialog/DialogTrigger.astro +0 -47
- package/src/components/dropdown/Dropdown.astro +0 -604
- package/src/components/dropdown/DropdownContent.astro +0 -118
- package/src/components/dropdown/DropdownItem.astro +0 -48
- package/src/components/dropdown/DropdownLabel.astro +0 -29
- package/src/components/dropdown/DropdownSeparator.astro +0 -21
- package/src/components/dropdown/DropdownShortcut.astro +0 -17
- package/src/components/dropdown/DropdownSub.astro +0 -15
- package/src/components/dropdown/DropdownSubContent.astro +0 -39
- package/src/components/dropdown/DropdownSubTrigger.astro +0 -34
- package/src/components/dropdown/DropdownTrigger.astro +0 -52
- package/src/components/dropzone/Dropzone.astro +0 -236
- package/src/components/dropzone/DropzoneFilesList.astro +0 -26
- package/src/components/dropzone/DropzoneLoadingIndicator.astro +0 -10
- package/src/components/dropzone/DropzoneUploadIndicator.astro +0 -10
- package/src/components/embeds/YoutubeEmbed.astro +0 -94
- package/src/components/hero/Hero.astro +0 -166
- package/src/components/icons/Flag.astro +0 -62
- package/src/components/image/ExtendedImage.astro +0 -46
- package/src/components/image/Image.astro +0 -25
- package/src/components/input/Input.astro +0 -27
- package/src/components/input-group/InputGroup.astro +0 -28
- package/src/components/input-group/InputGroupAddon.astro +0 -76
- package/src/components/input-group/InputGroupButton.astro +0 -36
- package/src/components/input-group/InputGroupInput.astro +0 -18
- package/src/components/input-group/InputGroupText.astro +0 -17
- package/src/components/input-group/InputGroupTextarea.astro +0 -22
- package/src/components/input-otp/InputOtp.astro +0 -352
- package/src/components/input-otp/InputOtpGroup.astro +0 -16
- package/src/components/input-otp/InputOtpSeparator.astro +0 -25
- package/src/components/input-otp/InputOtpSlot.astro +0 -50
- package/src/components/input-otp/InputOtpTypes.ts +0 -6
- package/src/components/item/Item.astro +0 -52
- package/src/components/item/ItemActions.astro +0 -16
- package/src/components/item/ItemContent.astro +0 -16
- package/src/components/item/ItemDescription.astro +0 -19
- package/src/components/item/ItemFooter.astro +0 -16
- package/src/components/item/ItemGroup.astro +0 -16
- package/src/components/item/ItemHeader.astro +0 -16
- package/src/components/item/ItemMedia.astro +0 -40
- package/src/components/item/ItemSeparator.astro +0 -23
- package/src/components/item/ItemTitle.astro +0 -16
- package/src/components/kbd/Kbd.astro +0 -21
- package/src/components/kbd/KbdGroup.astro +0 -16
- package/src/components/label/Label.astro +0 -24
- package/src/components/marquee/Marquee.astro +0 -73
- package/src/components/native-select/NativeSelect.astro +0 -68
- package/src/components/native-select/NativeSelectOptGroup.astro +0 -15
- package/src/components/native-select/NativeSelectOption.astro +0 -15
- package/src/components/pagination/Pagination.astro +0 -20
- package/src/components/pagination/PaginationContent.astro +0 -16
- package/src/components/pagination/PaginationEllipsis.astro +0 -37
- package/src/components/pagination/PaginationItem.astro +0 -16
- package/src/components/pagination/PaginationLink.astro +0 -27
- package/src/components/pagination/PaginationNext.astro +0 -33
- package/src/components/pagination/PaginationPrevious.astro +0 -33
- package/src/components/popover/Popover.astro +0 -717
- package/src/components/popover/PopoverContent.astro +0 -102
- package/src/components/popover/PopoverDescription.astro +0 -14
- package/src/components/popover/PopoverHeader.astro +0 -14
- package/src/components/popover/PopoverTitle.astro +0 -14
- package/src/components/popover/PopoverTrigger.astro +0 -51
- package/src/components/progress/Progress.astro +0 -154
- package/src/components/prose/Prose.astro +0 -619
- package/src/components/radio-group/RadioGroup.astro +0 -162
- package/src/components/radio-group/RadioGroupItem.astro +0 -133
- package/src/components/radio-group/RadioGroupTypes.ts +0 -6
- package/src/components/section/Section.astro +0 -167
- package/src/components/select/Select.astro +0 -752
- package/src/components/select/SelectContent.astro +0 -94
- package/src/components/select/SelectGroup.astro +0 -9
- package/src/components/select/SelectItem.astro +0 -51
- package/src/components/select/SelectLabel.astro +0 -14
- package/src/components/select/SelectSearch.astro +0 -49
- package/src/components/select/SelectSeparator.astro +0 -12
- package/src/components/select/SelectTrigger.astro +0 -56
- package/src/components/select/SelectTypes.ts +0 -13
- package/src/components/select/SelectValue.astro +0 -19
- package/src/components/separator/Separator.astro +0 -36
- package/src/components/sheet/Sheet.astro +0 -15
- package/src/components/sheet/SheetClose.astro +0 -15
- package/src/components/sheet/SheetContent.astro +0 -89
- package/src/components/sheet/SheetDescription.astro +0 -16
- package/src/components/sheet/SheetFooter.astro +0 -16
- package/src/components/sheet/SheetHeader.astro +0 -16
- package/src/components/sheet/SheetTitle.astro +0 -16
- package/src/components/sheet/SheetTrigger.astro +0 -15
- package/src/components/sidebar/Sidebar.astro +0 -231
- package/src/components/sidebar/SidebarContent.astro +0 -25
- package/src/components/sidebar/SidebarFooter.astro +0 -22
- package/src/components/sidebar/SidebarGroup.astro +0 -22
- package/src/components/sidebar/SidebarGroupContent.astro +0 -22
- package/src/components/sidebar/SidebarGroupLabel.astro +0 -53
- package/src/components/sidebar/SidebarHeader.astro +0 -22
- package/src/components/sidebar/SidebarInput.astro +0 -24
- package/src/components/sidebar/SidebarInset.astro +0 -22
- package/src/components/sidebar/SidebarMenu.astro +0 -22
- package/src/components/sidebar/SidebarMenuAction.astro +0 -63
- package/src/components/sidebar/SidebarMenuBadge.astro +0 -31
- package/src/components/sidebar/SidebarMenuButton.astro +0 -124
- package/src/components/sidebar/SidebarMenuItem.astro +0 -22
- package/src/components/sidebar/SidebarMenuSkeleton.astro +0 -43
- package/src/components/sidebar/SidebarMenuSub.astro +0 -25
- package/src/components/sidebar/SidebarMenuSubButton.astro +0 -52
- package/src/components/sidebar/SidebarMenuSubItem.astro +0 -17
- package/src/components/sidebar/SidebarProvider.astro +0 -215
- package/src/components/sidebar/SidebarRail.astro +0 -72
- package/src/components/sidebar/SidebarSeparator.astro +0 -25
- package/src/components/sidebar/SidebarTrigger.astro +0 -69
- package/src/components/skeleton/Skeleton.astro +0 -14
- package/src/components/slider/Slider.astro +0 -425
- package/src/components/spinner/Spinner.astro +0 -23
- package/src/components/switch/Switch.astro +0 -192
- package/src/components/switch/SwitchTypes.ts +0 -6
- package/src/components/table/Table.astro +0 -20
- package/src/components/table/TableBody.astro +0 -18
- package/src/components/table/TableCaption.astro +0 -18
- package/src/components/table/TableCell.astro +0 -18
- package/src/components/table/TableFoot.astro +0 -18
- package/src/components/table/TableHead.astro +0 -18
- package/src/components/table/TableHeader.astro +0 -18
- package/src/components/table/TableRow.astro +0 -17
- package/src/components/tabs/Tabs.astro +0 -270
- package/src/components/tabs/TabsContent.astro +0 -28
- package/src/components/tabs/TabsList.astro +0 -23
- package/src/components/tabs/TabsTrigger.astro +0 -34
- package/src/components/textarea/Textarea.astro +0 -31
- package/src/components/toast/ToastDescription.astro +0 -22
- package/src/components/toast/ToastItem.astro +0 -56
- package/src/components/toast/ToastTemplate.astro +0 -27
- package/src/components/toast/ToastTitle.astro +0 -59
- package/src/components/toast/Toaster.astro +0 -981
- package/src/components/toast/index.ts +0 -1
- package/src/components/toast/toast-manager.ts +0 -234
- package/src/components/toggle/Toggle.astro +0 -174
- package/src/components/toggle/ToggleTypes.ts +0 -14
- package/src/components/tooltip/Tooltip.astro +0 -422
- package/src/components/tooltip/TooltipContent.astro +0 -83
- package/src/components/tooltip/TooltipTrigger.astro +0 -13
- package/src/components/video/Video.astro +0 -121
- package/src/config/cookies.ts +0 -5
- package/src/config/links.ts +0 -4
- package/src/domain/cms/index.ts +0 -1
- package/src/domain/cms/types.ts +0 -20
- package/src/domain/i18n/constants.ts +0 -21
- package/src/domain/i18n/cookie-storage.ts +0 -13
- package/src/domain/i18n/country-to-locale-map.ts +0 -67
- package/src/domain/i18n/fallbacks.generated.ts +0 -230
- package/src/domain/i18n/fetcher.ts +0 -278
- package/src/domain/i18n/flags.ts +0 -16
- package/src/domain/i18n/format.ts +0 -90
- package/src/domain/i18n/index.ts +0 -10
- package/src/domain/i18n/middleware/i18n.ts +0 -161
- package/src/domain/i18n/resolve-locale.ts +0 -55
- package/src/domain/i18n/runtime-constants.ts +0 -14
- package/src/domain/i18n/schema.ts +0 -29
- package/src/domain/index.ts +0 -4
- package/src/domain/seo/constants.ts +0 -6
- package/src/domain/seo/index.ts +0 -3
- package/src/domain/seo/services/index.ts +0 -3
- package/src/domain/seo/services/llms.ts +0 -56
- package/src/domain/seo/services/robots.ts +0 -12
- package/src/domain/seo/services/sitemap.ts +0 -56
- package/src/domain/seo/utils.ts +0 -36
- package/src/domain/theme/constants.ts +0 -6
- package/src/domain/theme/index.ts +0 -2
- package/src/domain/theme/schema.ts +0 -10
- package/src/i18n.generated.d.ts +0 -202
- package/src/lib/component-preview.ts +0 -73
- package/src/lib/index.ts +0 -6
- package/src/lib/remark/remark-modified-time.ts +0 -13
- package/src/lib/showcase-preview-elements.ts +0 -408
- package/src/lib/showcase-renderer.ts +0 -218
- package/src/lib/showcase-utils.ts +0 -189
- package/src/lib/turnstile.ts +0 -35
- package/src/lib/utils/starwind/positioning.ts +0 -318
- package/src/locales/de/blog.json +0 -9
- package/src/locales/de/common.json +0 -19
- package/src/locales/de/errors.json +0 -6
- package/src/locales/de/home.json +0 -20
- package/src/locales/de/messages.json +0 -8
- package/src/locales/de/nav.json +0 -13
- package/src/locales/de/projects.json +0 -9
- package/src/locales/de/services.json +0 -43
- package/src/locales/en/blog.json +0 -9
- package/src/locales/en/chat.json +0 -29
- package/src/locales/en/common.json +0 -19
- package/src/locales/en/cookie_notice.json +0 -11
- package/src/locales/en/editor.json +0 -24
- package/src/locales/en/errors.json +0 -6
- package/src/locales/en/home.json +0 -20
- package/src/locales/en/messages.json +0 -8
- package/src/locales/en/nav.json +0 -13
- package/src/locales/en/projects.json +0 -9
- package/src/locales/en/services.json +0 -43
- package/src/locales/es/blog.json +0 -9
- package/src/locales/es/common.json +0 -19
- package/src/locales/es/errors.json +0 -6
- package/src/locales/es/home.json +0 -20
- package/src/locales/es/messages.json +0 -8
- package/src/locales/es/nav.json +0 -13
- package/src/locales/es/projects.json +0 -9
- package/src/locales/es/services.json +0 -43
- package/src/locales/ja/blog.json +0 -9
- package/src/locales/ja/common.json +0 -19
- package/src/locales/ja/errors.json +0 -6
- package/src/locales/ja/home.json +0 -20
- package/src/locales/ja/messages.json +0 -8
- package/src/locales/ja/nav.json +0 -13
- package/src/locales/ja/projects.json +0 -9
- package/src/locales/ja/services.json +0 -43
- package/src/locales/pt/blog.json +0 -9
- package/src/locales/pt/chat.json +0 -29
- package/src/locales/pt/common.json +0 -19
- package/src/locales/pt/cookie_notice.json +0 -11
- package/src/locales/pt/editor.json +0 -24
- package/src/locales/pt/errors.json +0 -6
- package/src/locales/pt/home.json +0 -20
- package/src/locales/pt/messages.json +0 -8
- package/src/locales/pt/nav.json +0 -13
- package/src/locales/pt/projects.json +0 -9
- package/src/locales/pt/services.json +0 -43
- package/src/utils/server/cookies.ts +0 -98
- package/src/utils/server/index.ts +0 -1
- package/src/utils/shared/index.ts +0 -3
- /package/src/utils/{shared/deep-merge.ts → deep-merge.ts} +0 -0
- /package/src/utils/{shared/embed.ts → embed.ts} +0 -0
- /package/src/utils/{shared/parse-boolean.ts → parse-boolean.ts} +0 -0
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
import type { HTMLAttributes } from "astro/types";
|
|
3
|
-
import { cv } from "css-variants";
|
|
4
|
-
|
|
5
|
-
type Props = HTMLAttributes<"kbd">;
|
|
6
|
-
|
|
7
|
-
export const kbd = cv({
|
|
8
|
-
base: [
|
|
9
|
-
"pointer-events-none inline-flex h-5 w-fit min-w-5 items-center justify-center gap-1 rounded-sm px-1 font-sans text-xs font-medium select-none",
|
|
10
|
-
"bg-muted text-muted-foreground",
|
|
11
|
-
"[&_svg:not([class*='size-'])]:size-3",
|
|
12
|
-
"[[data-slot=tooltip-content]_&]:bg-background/20 [[data-slot=tooltip-content]_&]:text-background dark:[[data-slot=tooltip-content]_&]:bg-background/10",
|
|
13
|
-
],
|
|
14
|
-
});
|
|
15
|
-
|
|
16
|
-
const { class: className, ...rest } = Astro.props;
|
|
17
|
-
---
|
|
18
|
-
|
|
19
|
-
<kbd class:list={[kbd(), className]} {...rest} data-slot="kbd">
|
|
20
|
-
<slot />
|
|
21
|
-
</kbd>
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
import type { HTMLAttributes } from "astro/types";
|
|
3
|
-
import { cv } from "css-variants";
|
|
4
|
-
|
|
5
|
-
type Props = HTMLAttributes<"kbd">;
|
|
6
|
-
|
|
7
|
-
export const kbdGroup = cv({
|
|
8
|
-
base: "inline-flex items-center gap-2xs",
|
|
9
|
-
});
|
|
10
|
-
|
|
11
|
-
const { class: className, ...rest } = Astro.props;
|
|
12
|
-
---
|
|
13
|
-
|
|
14
|
-
<kbd class:list={[kbdGroup(), className]} {...rest} data-slot="kbd-group">
|
|
15
|
-
<slot />
|
|
16
|
-
</kbd>
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
import type { HTMLAttributes } from "astro/types";
|
|
3
|
-
import { cv } from "css-variants";
|
|
4
|
-
|
|
5
|
-
type VariantProps<T extends (...args: any) => any> = NonNullable<Parameters<T>[0]>;
|
|
6
|
-
|
|
7
|
-
type Props = HTMLAttributes<"label"> & VariantProps<typeof label>;
|
|
8
|
-
|
|
9
|
-
export const label = cv({
|
|
10
|
-
base: [
|
|
11
|
-
"text-foreground leading-none font-medium",
|
|
12
|
-
"peer-disabled:cursor-not-allowed peer-disabled:op-70 has-[+:disabled]:cursor-not-allowed has-[+:disabled]:op-70",
|
|
13
|
-
],
|
|
14
|
-
variants: { size: { sm: "text-sm", md: "text-base", lg: "text-lg" } },
|
|
15
|
-
defaultVariants: { size: "md" },
|
|
16
|
-
});
|
|
17
|
-
|
|
18
|
-
const { size, class: className, ...rest } = Astro.props;
|
|
19
|
-
---
|
|
20
|
-
|
|
21
|
-
{/* eslint-disable-next-line astro/jsx-a11y/label-has-associated-control */}
|
|
22
|
-
<label class:list={[label({ size }), className]} {...rest} data-slot="label">
|
|
23
|
-
<slot />
|
|
24
|
-
</label>
|
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
import { scv } from "css-variants";
|
|
3
|
-
|
|
4
|
-
const marqueeVariants = scv({
|
|
5
|
-
slots: ["root", "content"],
|
|
6
|
-
base: {
|
|
7
|
-
root: "relative flex overflow-hidden w-full py-8",
|
|
8
|
-
content: "flex shrink-0 items-center justify-around gap-8 min-w-full",
|
|
9
|
-
},
|
|
10
|
-
variants: {
|
|
11
|
-
variant: {
|
|
12
|
-
static: {
|
|
13
|
-
root: "justify-center",
|
|
14
|
-
content: "animate-none",
|
|
15
|
-
},
|
|
16
|
-
scroll: {
|
|
17
|
-
root: "",
|
|
18
|
-
content: "animate-marquee",
|
|
19
|
-
},
|
|
20
|
-
},
|
|
21
|
-
size: {
|
|
22
|
-
xs: {
|
|
23
|
-
content: "gap-xs",
|
|
24
|
-
},
|
|
25
|
-
sm: {
|
|
26
|
-
content: "gap-sm",
|
|
27
|
-
},
|
|
28
|
-
md: {
|
|
29
|
-
content: "gap-md",
|
|
30
|
-
},
|
|
31
|
-
lg: {
|
|
32
|
-
content: "gap-lg",
|
|
33
|
-
},
|
|
34
|
-
xl: {
|
|
35
|
-
content: "gap-xl",
|
|
36
|
-
},
|
|
37
|
-
},
|
|
38
|
-
},
|
|
39
|
-
defaultVariants: {
|
|
40
|
-
variant: "static",
|
|
41
|
-
size: "md",
|
|
42
|
-
},
|
|
43
|
-
});
|
|
44
|
-
|
|
45
|
-
export interface MarqueeProps extends NonNullable<Parameters<typeof marqueeVariants>[0]> {
|
|
46
|
-
class?: string;
|
|
47
|
-
repeat?: number;
|
|
48
|
-
title?: string;
|
|
49
|
-
}
|
|
50
|
-
type Props = MarqueeProps;
|
|
51
|
-
|
|
52
|
-
const { variant, size, class: className, repeat = 2, title } = Astro.props;
|
|
53
|
-
const { root, content } = marqueeVariants({ variant, size });
|
|
54
|
-
---
|
|
55
|
-
|
|
56
|
-
<div class:list={[root, className]}>
|
|
57
|
-
<div class="container flex flex-col items-center gap-8">
|
|
58
|
-
{title && (
|
|
59
|
-
<h4 class="text-lg font-medium text-muted-foreground/80">
|
|
60
|
-
{title}
|
|
61
|
-
</h4>
|
|
62
|
-
)}
|
|
63
|
-
<div class="flex w-full items-center justify-around gap-inherit">
|
|
64
|
-
{Array.from({ length: variant === "scroll" ? repeat : 1 }).map(() => (
|
|
65
|
-
<div class={content}>
|
|
66
|
-
<slot />
|
|
67
|
-
</div>
|
|
68
|
-
))}
|
|
69
|
-
</div>
|
|
70
|
-
</div>
|
|
71
|
-
</div>
|
|
72
|
-
|
|
73
|
-
|
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
import type { HTMLAttributes } from "astro/types";
|
|
3
|
-
import { cv } from "css-variants";
|
|
4
|
-
import IconChevronDown from "~icons/lucide/chevron-down";
|
|
5
|
-
|
|
6
|
-
type VariantProps<T extends (...args: any) => any> = NonNullable<Parameters<T>[0]>;
|
|
7
|
-
|
|
8
|
-
type Props = Omit<HTMLAttributes<"select">, "size"> & VariantProps<typeof nativeSelect>;
|
|
9
|
-
|
|
10
|
-
export const nativeSelectWrapper = cv({
|
|
11
|
-
base: [
|
|
12
|
-
"starwind-native-select-wrapper",
|
|
13
|
-
"group/native-select relative w-fit has-[select:disabled]:op-50",
|
|
14
|
-
],
|
|
15
|
-
});
|
|
16
|
-
|
|
17
|
-
export const nativeSelect = cv({
|
|
18
|
-
base: [
|
|
19
|
-
"starwind-native-select",
|
|
20
|
-
"border-input dark:bg-input/30 text-foreground ring-offset-background w-full rounded-md b bg-transparent shadow-xs",
|
|
21
|
-
"placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground appearance-none bg-none select-none",
|
|
22
|
-
"focus-visible:border-outline focus-visible:ring-outline/50 transition-[color,box-shadow] outline-none focus-visible:ring-3",
|
|
23
|
-
"disabled:pointer-events-none disabled:cursor-not-allowed",
|
|
24
|
-
"aria-invalid:border-error aria-invalid:focus-visible:ring-error/40 aria-invalid:focus-visible:ring-3",
|
|
25
|
-
],
|
|
26
|
-
variants: {
|
|
27
|
-
size: {
|
|
28
|
-
sm: "h-2xl pr-2xl pl-3xs text-sm",
|
|
29
|
-
md: "h-3xl pr-3xl pl-xs text-base",
|
|
30
|
-
lg: "h-3xl pr-3xl px-2xl text-lg",
|
|
31
|
-
},
|
|
32
|
-
},
|
|
33
|
-
defaultVariants: {
|
|
34
|
-
size: "md",
|
|
35
|
-
},
|
|
36
|
-
});
|
|
37
|
-
|
|
38
|
-
export const nativeSelectIcon = cv({
|
|
39
|
-
base: ["text-foreground pointer-events-none absolute top-1/2 -translate-y-1/2 op-50"],
|
|
40
|
-
variants: {
|
|
41
|
-
size: {
|
|
42
|
-
sm: "right-3xs size-3.5",
|
|
43
|
-
md: "right-xs size-4",
|
|
44
|
-
lg: "right-2xl size-5",
|
|
45
|
-
},
|
|
46
|
-
},
|
|
47
|
-
defaultVariants: {
|
|
48
|
-
size: "md",
|
|
49
|
-
},
|
|
50
|
-
});
|
|
51
|
-
|
|
52
|
-
const { class: className, size, ...rest } = Astro.props;
|
|
53
|
-
---
|
|
54
|
-
|
|
55
|
-
<div class={nativeSelectWrapper()} data-size={size} data-slot="native-select-wrapper">
|
|
56
|
-
<select class:list={[nativeSelect({ size }), className]} {...rest} data-slot="native-select">
|
|
57
|
-
<slot />
|
|
58
|
-
</select>
|
|
59
|
-
<slot name="icon">
|
|
60
|
-
<span
|
|
61
|
-
class={nativeSelectIcon({ size })}
|
|
62
|
-
aria-hidden="true"
|
|
63
|
-
data-slot="native-select-icon"
|
|
64
|
-
>
|
|
65
|
-
<IconChevronDown />
|
|
66
|
-
</span>
|
|
67
|
-
</slot>
|
|
68
|
-
</div>
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
import type { HTMLAttributes } from "astro/types";
|
|
3
|
-
|
|
4
|
-
type Props = HTMLAttributes<"optgroup">;
|
|
5
|
-
|
|
6
|
-
const { class: className, ...rest } = Astro.props;
|
|
7
|
-
---
|
|
8
|
-
|
|
9
|
-
<optgroup
|
|
10
|
-
class:list={["starwind-native-select-optgroup", className]}
|
|
11
|
-
{...rest}
|
|
12
|
-
data-slot="native-select-optgroup"
|
|
13
|
-
>
|
|
14
|
-
<slot />
|
|
15
|
-
</optgroup>
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
import type { HTMLAttributes } from "astro/types";
|
|
3
|
-
|
|
4
|
-
type Props = HTMLAttributes<"option">;
|
|
5
|
-
|
|
6
|
-
const { class: className, ...rest } = Astro.props;
|
|
7
|
-
---
|
|
8
|
-
|
|
9
|
-
<option
|
|
10
|
-
class:list={["starwind-native-select-option", className]}
|
|
11
|
-
{...rest}
|
|
12
|
-
data-slot="native-select-option"
|
|
13
|
-
>
|
|
14
|
-
<slot />
|
|
15
|
-
</option>
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
import type { HTMLAttributes } from "astro/types";
|
|
3
|
-
import { cv } from "css-variants";
|
|
4
|
-
|
|
5
|
-
type Props = HTMLAttributes<"nav">;
|
|
6
|
-
|
|
7
|
-
export const pagination = cv({ base: "mx-auto flex w-full justify-center" });
|
|
8
|
-
|
|
9
|
-
const { class: className, ...rest } = Astro.props;
|
|
10
|
-
---
|
|
11
|
-
|
|
12
|
-
<nav
|
|
13
|
-
role="navigation"
|
|
14
|
-
aria-label="pagination"
|
|
15
|
-
class:list={[pagination(), className]}
|
|
16
|
-
{...rest}
|
|
17
|
-
data-slot="pagination"
|
|
18
|
-
>
|
|
19
|
-
<slot />
|
|
20
|
-
</nav>
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
import type { HTMLAttributes } from "astro/types";
|
|
3
|
-
import { cv } from "css-variants";
|
|
4
|
-
|
|
5
|
-
type Props = HTMLAttributes<"ul"> & {
|
|
6
|
-
children: any;
|
|
7
|
-
};
|
|
8
|
-
|
|
9
|
-
export const paginationContent = cv({ base: "flex flex-row items-center gap-2xs" });
|
|
10
|
-
|
|
11
|
-
const { class: className, ...rest } = Astro.props;
|
|
12
|
-
---
|
|
13
|
-
|
|
14
|
-
<ul class:list={[paginationContent(), className]} {...rest} data-slot="pagination-content">
|
|
15
|
-
<slot />
|
|
16
|
-
</ul>
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
import type { HTMLAttributes } from "astro/types";
|
|
3
|
-
import { cv } from "css-variants";
|
|
4
|
-
import IconMoreHorizontal from "~icons/lucide/more-horizontal";
|
|
5
|
-
|
|
6
|
-
type VariantProps<T extends (...args: any) => any> = NonNullable<Parameters<T>[0]>;
|
|
7
|
-
|
|
8
|
-
type Props = HTMLAttributes<"span"> & VariantProps<typeof paginationEllipsis>;
|
|
9
|
-
|
|
10
|
-
export const paginationEllipsis = cv({
|
|
11
|
-
base: "flex items-center justify-center",
|
|
12
|
-
variants: {
|
|
13
|
-
size: {
|
|
14
|
-
"icon-sm": "size-9",
|
|
15
|
-
icon: "size-11",
|
|
16
|
-
"icon-lg": "size-12",
|
|
17
|
-
},
|
|
18
|
-
},
|
|
19
|
-
defaultVariants: { size: "icon" },
|
|
20
|
-
});
|
|
21
|
-
|
|
22
|
-
const { class: className, size, ...rest } = Astro.props;
|
|
23
|
-
---
|
|
24
|
-
|
|
25
|
-
<span
|
|
26
|
-
aria-hidden
|
|
27
|
-
class:list={[paginationEllipsis({ size }), className]}
|
|
28
|
-
{...rest}
|
|
29
|
-
data-slot="pagination-ellipsis"
|
|
30
|
-
>
|
|
31
|
-
<slot name="icon">
|
|
32
|
-
<IconMoreHorizontal class="size-4" />
|
|
33
|
-
</slot>
|
|
34
|
-
<slot>
|
|
35
|
-
<span class="sr-only">More pages</span>
|
|
36
|
-
</slot>
|
|
37
|
-
</span>
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
import type { HTMLAttributes } from "astro/types";
|
|
3
|
-
import { cv } from "css-variants";
|
|
4
|
-
|
|
5
|
-
type Props = HTMLAttributes<"li"> & {
|
|
6
|
-
children: any;
|
|
7
|
-
};
|
|
8
|
-
|
|
9
|
-
export const paginationItem = cv({ base: "" });
|
|
10
|
-
|
|
11
|
-
const { class: className, ...rest } = Astro.props;
|
|
12
|
-
---
|
|
13
|
-
|
|
14
|
-
<li class:list={[paginationItem(), className]} {...rest} data-slot="pagination-item">
|
|
15
|
-
<slot />
|
|
16
|
-
</li>
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
import type { HTMLAttributes } from "astro/types";
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
type VariantProps<T extends (...args: any) => any> = NonNullable<Parameters<T>[0]>;
|
|
6
|
-
|
|
7
|
-
import { button } from "../button/Button.astro";
|
|
8
|
-
|
|
9
|
-
type Props = HTMLAttributes<"a"> &
|
|
10
|
-
Omit<VariantProps<typeof button>, "variant"> & {
|
|
11
|
-
isActive?: boolean;
|
|
12
|
-
};
|
|
13
|
-
|
|
14
|
-
export const paginationLink = button;
|
|
15
|
-
|
|
16
|
-
const { class: className, isActive, size = "icon", ...rest } = Astro.props;
|
|
17
|
-
---
|
|
18
|
-
|
|
19
|
-
<a
|
|
20
|
-
aria-current={isActive ? "page" : undefined}
|
|
21
|
-
class:list={[button({ variant: isActive ? "outline" : "ghost", size }), className]}
|
|
22
|
-
{...rest}
|
|
23
|
-
data-slot="pagination-link"
|
|
24
|
-
>
|
|
25
|
-
<slot />
|
|
26
|
-
</a>
|
|
27
|
-
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
import type { HTMLAttributes } from "astro/types";
|
|
3
|
-
import { cv } from "css-variants";
|
|
4
|
-
import IconChevronRight from "~icons/lucide/chevron-right";
|
|
5
|
-
|
|
6
|
-
type VariantProps<T extends (...args: any) => any> = NonNullable<Parameters<T>[0]>;
|
|
7
|
-
|
|
8
|
-
import type { button } from "../button/Button.astro";
|
|
9
|
-
|
|
10
|
-
import PaginationLink from "./PaginationLink.astro";
|
|
11
|
-
|
|
12
|
-
type Props = HTMLAttributes<"a"> & {
|
|
13
|
-
size?: VariantProps<typeof button>["size"];
|
|
14
|
-
};
|
|
15
|
-
|
|
16
|
-
export const paginationNext = cv({ base: "group gap-2xs" });
|
|
17
|
-
|
|
18
|
-
const { class: className, size = "md", ...rest } = Astro.props;
|
|
19
|
-
---
|
|
20
|
-
|
|
21
|
-
<PaginationLink
|
|
22
|
-
aria-label="Go to next page"
|
|
23
|
-
size={size}
|
|
24
|
-
class:list={[paginationNext(), className]}
|
|
25
|
-
{...rest}
|
|
26
|
-
data-slot="pagination-next"
|
|
27
|
-
>
|
|
28
|
-
<slot />
|
|
29
|
-
<slot name="icon">
|
|
30
|
-
<IconChevronRight class="size-4 transition-transform group-hover:translate-x-1" />
|
|
31
|
-
</slot>
|
|
32
|
-
</PaginationLink>
|
|
33
|
-
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
import type { HTMLAttributes } from "astro/types";
|
|
3
|
-
import { cv } from "css-variants";
|
|
4
|
-
import IconChevronLeft from "~icons/lucide/chevron-left";
|
|
5
|
-
|
|
6
|
-
type VariantProps<T extends (...args: any) => any> = NonNullable<Parameters<T>[0]>;
|
|
7
|
-
|
|
8
|
-
import type { button } from "../button/Button.astro";
|
|
9
|
-
|
|
10
|
-
import PaginationLink from "./PaginationLink.astro";
|
|
11
|
-
|
|
12
|
-
type Props = HTMLAttributes<"a"> & {
|
|
13
|
-
size?: VariantProps<typeof button>["size"];
|
|
14
|
-
};
|
|
15
|
-
|
|
16
|
-
export const paginationPrevious = cv({ base: "group gap-2xs" });
|
|
17
|
-
|
|
18
|
-
const { class: className, size = "md", ...rest } = Astro.props;
|
|
19
|
-
---
|
|
20
|
-
|
|
21
|
-
<PaginationLink
|
|
22
|
-
aria-label="Go to previous page"
|
|
23
|
-
size={size}
|
|
24
|
-
class:list={[paginationPrevious(), className]}
|
|
25
|
-
{...rest}
|
|
26
|
-
data-slot="pagination-previous"
|
|
27
|
-
>
|
|
28
|
-
<slot name="icon">
|
|
29
|
-
<IconChevronLeft class="size-4 transition-transform group-hover:-translate-x-1" />
|
|
30
|
-
</slot>
|
|
31
|
-
<slot />
|
|
32
|
-
</PaginationLink>
|
|
33
|
-
|