@wordup-md/nuxt-layer-shadcn-unocss 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.cursor/rules/active-context-rule.mdc +8 -0
- package/.cursor/rules/memory-bank-overview.mdc +17 -0
- package/.cursor/rules/product-context-rule.mdc +8 -0
- package/.cursor/rules/progress-rule.mdc +8 -0
- package/.cursor/rules/projectbrief-rule.mdc +8 -0
- package/.cursor/rules/system-patterns-rule.mdc +8 -0
- package/.cursor/rules/tech-context-rule.mdc +8 -0
- package/.cursorrules +52 -0
- package/.editorconfig +12 -0
- package/.nuxtrc +1 -0
- package/.playground/app.config.ts +189 -0
- package/.playground/assets/style.css +15 -0
- package/.playground/components/content/MdcExample.vue +81 -0
- package/.playground/components/content/MdcReplay.vue +319 -0
- package/.playground/content/1.getting-started/1.introduction.md +8 -0
- package/.playground/content/1.getting-started/2.writing/1.markdown.md +56 -0
- package/.playground/content/1.getting-started/2.writing/2.pages.md +177 -0
- package/.playground/content/1.getting-started/2.writing/3.folders.md +56 -0
- package/.playground/content/1.getting-started/2.writing/_dir.yml +3 -0
- package/.playground/content/1.getting-started/_dir.yml +3 -0
- package/.playground/content/2.content-elements/1.text-formatting.md +60 -0
- package/.playground/content/2.content-elements/10.horizontal-rule.md +25 -0
- package/.playground/content/2.content-elements/11.tables.md +25 -0
- package/.playground/content/2.content-elements/12.overview.md +93 -0
- package/.playground/content/2.content-elements/13.text-components.md +36 -0
- package/.playground/content/2.content-elements/2.headings.md +32 -0
- package/.playground/content/2.content-elements/3.paragraphs.md +39 -0
- package/.playground/content/2.content-elements/4.lists.md +37 -0
- package/.playground/content/2.content-elements/5.links.md +17 -0
- package/.playground/content/2.content-elements/6.images.md +17 -0
- package/.playground/content/2.content-elements/7.blockquotes.md +17 -0
- package/.playground/content/2.content-elements/8.code-blocks.md +141 -0
- package/.playground/content/2.content-elements/9.inline-code.md +21 -0
- package/.playground/content/2.content-elements/_dir.yml +3 -0
- package/.playground/content/2.content-elements/index.md +8 -0
- package/.playground/content/3.components/1.index.md +187 -0
- package/.playground/content/3.components/2.docs/_dir.yml +3 -0
- package/.playground/content/3.components/2.docs/alert.md +152 -0
- package/.playground/content/3.components/2.docs/badge.md +131 -0
- package/.playground/content/3.components/2.docs/button-link.md +53 -0
- package/.playground/content/3.components/2.docs/callout.md +16 -0
- package/.playground/content/3.components/2.docs/code-group.md +77 -0
- package/.playground/content/3.components/2.docs/code-snippet.md +129 -0
- package/.playground/content/3.components/2.docs/field-group.md +62 -0
- package/.playground/content/3.components/2.docs/field.md +39 -0
- package/.playground/content/3.components/2.docs/file-tree.md +144 -0
- package/.playground/content/3.components/2.docs/icon.md +94 -0
- package/.playground/content/3.components/2.docs/pm.md +67 -0
- package/.playground/content/3.components/2.docs/read-more.md +44 -0
- package/.playground/content/3.components/2.docs/shortcut.md +36 -0
- package/.playground/content/3.components/2.docs/stack.md +81 -0
- package/.playground/content/3.components/2.docs/steps.md +148 -0
- package/.playground/content/3.components/2.docs/tabs.md +375 -0
- package/.playground/content/3.components/3.page/_dir.yml +2 -0
- package/.playground/content/3.components/3.page/accordion.md +74 -0
- package/.playground/content/3.components/3.page/card-group.md +115 -0
- package/.playground/content/3.components/3.page/card.md +142 -0
- package/.playground/content/3.components/3.page/collapsible.md +61 -0
- package/.playground/content/3.components/3.page/hero-alt.md +118 -0
- package/.playground/content/3.components/3.page/hero.md +60 -0
- package/.playground/content/3.components/3.page/team-card.md +82 -0
- package/.playground/content/3.components/_dir.yml +2 -0
- package/.playground/content/4.development/1.configuration/1.overview.md +297 -0
- package/.playground/content/4.development/1.configuration/2.nuxt-content.md +105 -0
- package/.playground/content/4.development/1.configuration/3.og-image.md +86 -0
- package/.playground/content/4.development/1.configuration/4.edit-link.md +63 -0
- package/.playground/content/4.development/1.configuration/5.banner.md +52 -0
- package/.playground/content/4.development/1.configuration/6.carbon-ads.md +65 -0
- package/.playground/content/4.development/1.configuration/7.umami.md +41 -0
- package/.playground/content/4.development/1.configuration/_dir.yml +3 -0
- package/.playground/content/4.development/2.advanced/1.override.md +49 -0
- package/.playground/content/4.development/2.advanced/2.math.md +89 -0
- package/.playground/content/4.development/2.advanced/_dir.yml +3 -0
- package/.playground/content/4.development/3.themes.md +9 -0
- package/.playground/content/4.development/4.composables.md +38 -0
- package/.playground/content/4.development/5.installation.md +36 -0
- package/.playground/content/4.development/_dir.yml +3 -0
- package/.playground/content/_menu-footer.md +5 -0
- package/.playground/content/index.md +67 -0
- package/.playground/content/test-card.md +187 -0
- package/.playground/content/test.md +88 -0
- package/.playground/content/test2.md +12 -0
- package/.playground/content/test3.md +187 -0
- package/.playground/nuxt.config.ts +52 -0
- package/.playground/public/banner-preview.png +0 -0
- package/.playground/public/favicon.ico +0 -0
- package/.playground/public/front-matter-showcase/authors.png +0 -0
- package/.playground/public/front-matter-showcase/badges.png +0 -0
- package/.playground/public/front-matter-showcase/nav-badges.png +0 -0
- package/.playground/public/hero.png +0 -0
- package/.playground/public/logo-dark.svg +12 -0
- package/.playground/public/logo.svg +12 -0
- package/.playground/public/og-nuxt-seo.png +0 -0
- package/.playground/public/og-nuxt.png +0 -0
- package/.playground/public/og-shadcn-docs-dark.png +0 -0
- package/.playground/public/og-shadcn-docs.png +0 -0
- package/.playground/public/sidebar-default.png +0 -0
- package/.playground/public/sidebar-group.png +0 -0
- package/.playground/public/sidebar-tree.png +0 -0
- package/.playground/uno.config.ts +16 -0
- package/README.md +93 -0
- package/app.vue +59 -0
- package/assets/css/a11y.css +48 -0
- package/assets/css/mdc-editor.css +91 -0
- package/components/A11yModeToggle.vue +23 -0
- package/components/DarkModeToggle.vue +26 -0
- package/components/LinkIcon.vue +32 -0
- package/components/OgImage/ShadcnDocs.vue +55 -0
- package/components/ThemeCustomizer.vue +156 -0
- package/components/ThemePopover.vue +27 -0
- package/components/content/Accordion.vue +18 -0
- package/components/content/AccordionItem.vue +32 -0
- package/components/content/Alert.vue +100 -0
- package/components/content/Badge.vue +52 -0
- package/components/content/ButtonLink.vue +38 -0
- package/components/content/Callout.vue +17 -0
- package/components/content/Card.vue +173 -0
- package/components/content/CardGroup.vue +38 -0
- package/components/content/CodeCopy.vue +52 -0
- package/components/content/CodeGroup._vue +27 -0
- package/components/content/CodeSnippet._vue +78 -0
- package/components/content/Collapsible.vue +80 -0
- package/components/content/Field.vue +53 -0
- package/components/content/FieldGroup.vue +5 -0
- package/components/content/FileTree.vue +110 -0
- package/components/content/FileTreeItem.vue +64 -0
- package/components/content/FileTreeRoot.vue +27 -0
- package/components/content/Hero.vue +154 -0
- package/components/content/HeroAlt.vue +116 -0
- package/components/content/Icon.vue +69 -0
- package/components/content/Kbd.vue +20 -0
- package/components/content/PmInstall.vue +35 -0
- package/components/content/PmRun.vue +31 -0
- package/components/content/PmX.vue +31 -0
- package/components/content/ProseA.vue +21 -0
- package/components/content/ProseBlockquote.vue +5 -0
- package/components/content/ProseCode.vue +121 -0
- package/components/content/ProseCodeInline.vue +24 -0
- package/components/content/ProseEm.vue +5 -0
- package/components/content/ProseH1.vue +27 -0
- package/components/content/ProseH2.vue +22 -0
- package/components/content/ProseH3.vue +21 -0
- package/components/content/ProseH4.vue +21 -0
- package/components/content/ProseH5.vue +21 -0
- package/components/content/ProseH6.vue +21 -0
- package/components/content/ProseHr.vue +3 -0
- package/components/content/ProseImg.vue +42 -0
- package/components/content/ProseLi.vue +5 -0
- package/components/content/ProseOl.vue +5 -0
- package/components/content/ProseP.vue +5 -0
- package/components/content/ProsePre.vue +56 -0
- package/components/content/ProseSection.vue +27 -0
- package/components/content/ProseStrong.vue +5 -0
- package/components/content/ProseTable.vue +7 -0
- package/components/content/ProseTbody.vue +5 -0
- package/components/content/ProseTd.vue +5 -0
- package/components/content/ProseTh.vue +5 -0
- package/components/content/ProseThead.vue +5 -0
- package/components/content/ProseTr.vue +5 -0
- package/components/content/ProseUl.vue +5 -0
- package/components/content/ReadMore.vue +41 -0
- package/components/content/Shortcut.vue +20 -0
- package/components/content/Stack.vue +17 -0
- package/components/content/Steps.vue +23 -0
- package/components/content/Tabs.vue +52 -0
- package/components/content/TabsInner.vue +263 -0
- package/components/content/TeamCard.vue +52 -0
- package/components/content/TeamCardGroup.vue +5 -0
- package/components/content/global/AlertEditor.vue +58 -0
- package/components/content/global/BadgeEditor.vue +56 -0
- package/components/content/global/BrEditor.vue +3 -0
- package/components/content/global/CardEditor.vue +142 -0
- package/components/content/global/CardGroupEditor.vue +50 -0
- package/components/content/global/CodeGroup.vue +13 -0
- package/components/content/global/CodeGroupEditor.vue +50 -0
- package/components/content/global/DivEditor.vue +22 -0
- package/components/content/global/FieldEditor.vue +38 -0
- package/components/content/global/FieldGroupEditor.vue +24 -0
- package/components/content/global/HeroEditor.vue +67 -0
- package/components/content/global/ProseSectionEditor.vue +180 -0
- package/components/content/global/ReadMoreEditor.vue +70 -0
- package/components/content/global/SectionEditor.vue +22 -0
- package/components/content/global/StackEditor.vue +35 -0
- package/components/content/global/StepsEditor.vue +55 -0
- package/components/content/global/Tabs._vue +97 -0
- package/components/content/global/TabsEditor.vue +38 -0
- package/components/layout/Aside.vue +83 -0
- package/components/layout/AsideTree.vue +25 -0
- package/components/layout/AsideTreeItem.vue +86 -0
- package/components/layout/AsideTreeItemButton.vue +32 -0
- package/components/layout/Banner.vue +77 -0
- package/components/layout/Breadcrumb.vue +34 -0
- package/components/layout/DocsFooter.vue +6 -0
- package/components/layout/EditLink.vue +23 -0
- package/components/layout/Footer.vue +80 -0
- package/components/layout/FooterItem.vue +50 -0
- package/components/layout/FooterSubmenuItem.vue +39 -0
- package/components/layout/Header/Logo.vue +30 -0
- package/components/layout/Header/MenuItem.vue +83 -0
- package/components/layout/Header/Nav.vue +112 -0
- package/components/layout/Header/NavMobile.vue +14 -0
- package/components/layout/Header/NavMobileItem.vue +79 -0
- package/components/layout/Header/SubmenuItem.vue +39 -0
- package/components/layout/Header.vue +160 -0
- package/components/layout/LangSwitcher.vue +90 -0
- package/components/layout/MobileNav.vue +44 -0
- package/components/layout/PrevNext.vue +24 -0
- package/components/layout/PrevNextButton.vue +50 -0
- package/components/layout/SearchButton.vue +46 -0
- package/components/layout/SearchDialog.vue +217 -0
- package/components/layout/Title.vue +98 -0
- package/components/layout/Toc.vue +99 -0
- package/components/layout/TocTree.vue +42 -0
- package/components/ui/accordion/Accordion.vue +19 -0
- package/components/ui/accordion/AccordionContent.vue +24 -0
- package/components/ui/accordion/AccordionItem.vue +24 -0
- package/components/ui/accordion/AccordionTrigger.vue +39 -0
- package/components/ui/accordion/index.ts +4 -0
- package/components/ui/alert/Alert.vue +19 -0
- package/components/ui/alert/AlertDescription.vue +14 -0
- package/components/ui/alert/AlertTitle.vue +14 -0
- package/components/ui/alert/index.ts +23 -0
- package/components/ui/avatar/Avatar.vue +25 -0
- package/components/ui/avatar/AvatarFallback.vue +11 -0
- package/components/ui/avatar/AvatarImage.vue +12 -0
- package/components/ui/avatar/index.ts +24 -0
- package/components/ui/badge/Badge.vue +17 -0
- package/components/ui/badge/index.ts +71 -0
- package/components/ui/breadcrumb/Breadcrumb.vue +16 -0
- package/components/ui/breadcrumb/BreadcrumbItem.vue +16 -0
- package/components/ui/breadcrumb/BreadcrumbLink.vue +23 -0
- package/components/ui/breadcrumb/BreadcrumbList.vue +16 -0
- package/components/ui/breadcrumb/BreadcrumbPage.vue +19 -0
- package/components/ui/breadcrumb/BreadcrumbSeparator.vue +23 -0
- package/components/ui/breadcrumb/index.ts +6 -0
- package/components/ui/button/Button.vue +29 -0
- package/components/ui/button/index.ts +35 -0
- package/components/ui/card/Card.vue +21 -0
- package/components/ui/card/CardContent.vue +14 -0
- package/components/ui/card/CardDescription.vue +14 -0
- package/components/ui/card/CardFooter.vue +14 -0
- package/components/ui/card/CardHeader.vue +14 -0
- package/components/ui/card/CardTitle.vue +18 -0
- package/components/ui/card/index.ts +6 -0
- package/components/ui/collapsible/Collapsible.vue +18 -0
- package/components/ui/collapsible/CollapsibleContent.vue +14 -0
- package/components/ui/collapsible/CollapsibleTrigger.vue +11 -0
- package/components/ui/collapsible/index.ts +3 -0
- package/components/ui/command/Command.vue +89 -0
- package/components/ui/command/CommandEmpty.vue +30 -0
- package/components/ui/command/CommandGroup.vue +50 -0
- package/components/ui/command/CommandInput.vue +44 -0
- package/components/ui/command/CommandInputOnly.vue +50 -0
- package/components/ui/command/CommandItem.vue +79 -0
- package/components/ui/command/CommandList.vue +28 -0
- package/components/ui/command/CommandSeparator.vue +24 -0
- package/components/ui/command/index.ts +24 -0
- package/components/ui/dialog/Dialog.vue +14 -0
- package/components/ui/dialog/DialogClose.vue +11 -0
- package/components/ui/dialog/DialogContent.vue +52 -0
- package/components/ui/dialog/DialogDescription.vue +24 -0
- package/components/ui/dialog/DialogFooter.vue +19 -0
- package/components/ui/dialog/DialogHeader.vue +16 -0
- package/components/ui/dialog/DialogScrollContent.vue +61 -0
- package/components/ui/dialog/DialogTitle.vue +29 -0
- package/components/ui/dialog/DialogTrigger.vue +11 -0
- package/components/ui/dialog/index.ts +9 -0
- package/components/ui/input/Input.vue +27 -0
- package/components/ui/input/index.ts +1 -0
- package/components/ui/label/Label.vue +27 -0
- package/components/ui/label/index.ts +1 -0
- package/components/ui/navigation-menu/NavigationMenu.vue +33 -0
- package/components/ui/navigation-menu/NavigationMenuContent.vue +34 -0
- package/components/ui/navigation-menu/NavigationMenuIndicator.vue +24 -0
- package/components/ui/navigation-menu/NavigationMenuItem.vue +11 -0
- package/components/ui/navigation-menu/NavigationMenuLink.vue +19 -0
- package/components/ui/navigation-menu/NavigationMenuList.vue +33 -0
- package/components/ui/navigation-menu/NavigationMenuTrigger.vue +34 -0
- package/components/ui/navigation-menu/NavigationMenuViewport.vue +33 -0
- package/components/ui/navigation-menu/index.ts +14 -0
- package/components/ui/popover/Popover.vue +15 -0
- package/components/ui/popover/PopoverContent.vue +49 -0
- package/components/ui/popover/PopoverTrigger.vue +11 -0
- package/components/ui/popover/index.ts +4 -0
- package/components/ui/scroll-area/ScrollArea.vue +32 -0
- package/components/ui/scroll-area/ScrollBar.vue +41 -0
- package/components/ui/scroll-area/index.ts +2 -0
- package/components/ui/separator/Separator.vue +20 -0
- package/components/ui/separator/index.ts +1 -0
- package/components/ui/sheet/Sheet.vue +14 -0
- package/components/ui/sheet/SheetClose.vue +11 -0
- package/components/ui/sheet/SheetContent.vue +58 -0
- package/components/ui/sheet/SheetDescription.vue +22 -0
- package/components/ui/sheet/SheetFooter.vue +19 -0
- package/components/ui/sheet/SheetHeader.vue +16 -0
- package/components/ui/sheet/SheetTitle.vue +22 -0
- package/components/ui/sheet/SheetTrigger.vue +11 -0
- package/components/ui/sheet/index.ts +31 -0
- package/components/ui/slider/Slider.vue +36 -0
- package/components/ui/slider/index.ts +1 -0
- package/components/ui/tabs/Tabs.vue +15 -0
- package/components/ui/tabs/TabsContent.vue +22 -0
- package/components/ui/tabs/TabsList.vue +25 -0
- package/components/ui/tabs/TabsTrigger.vue +27 -0
- package/components/ui/tabs/index.ts +4 -0
- package/components/ui/textarea/Textarea.vue +27 -0
- package/components/ui/textarea/index.ts +1 -0
- package/components/ui/toast/Toast.vue +28 -0
- package/components/ui/toast/ToastAction.vue +22 -0
- package/components/ui/toast/ToastClose.vue +27 -0
- package/components/ui/toast/ToastDescription.vue +22 -0
- package/components/ui/toast/ToastProvider.vue +11 -0
- package/components/ui/toast/ToastTitle.vue +22 -0
- package/components/ui/toast/ToastViewport.vue +20 -0
- package/components/ui/toast/Toaster.vue +34 -0
- package/components/ui/toast/index.ts +38 -0
- package/components/ui/toast/use-toast.ts +165 -0
- package/components.json +18 -0
- package/composables/useBreadcrumb.ts +47 -0
- package/composables/useCollapsedMap.ts +3 -0
- package/composables/useConfig.ts +227 -0
- package/composables/useEditLink.ts +27 -0
- package/composables/useI18nDocs.ts +114 -0
- package/composables/useMdcMenu.ts +204 -0
- package/composables/usePm.ts +58 -0
- package/composables/useScrollspy.ts +51 -0
- package/composables/useThemes.ts +46 -0
- package/composables/useToast.ts +1 -0
- package/content/index.md +45 -0
- package/eslint.config.js +3 -0
- package/i18n/i18n.config.ts +414 -0
- package/index.d.ts +610 -0
- package/layouts/blank.vue +5 -0
- package/layouts/default.vue +9 -0
- package/layouts/editorial.vue +83 -0
- package/lib/registry/themes.ts +636 -0
- package/lib/uno-preset.ts +143 -0
- package/memory-bank/activeContext.md +17 -0
- package/memory-bank/productContext.md +21 -0
- package/memory-bank/progress.md +16 -0
- package/memory-bank/projectbrief.md +20 -0
- package/memory-bank/systemPatterns.md +25 -0
- package/memory-bank/techContext.md +29 -0
- package/modules/inject-css.ts +40 -0
- package/nuxt.config.ts +124 -0
- package/package.json +71 -0
- package/pages/[...slug].vue +109 -0
- package/pages/admin/[...slug].vue +145 -0
- package/pages/index.vue +24 -0
- package/plugins/injectCssHmr.ts +26 -0
- package/plugins/wordup.ts +130 -0
- package/public/content-doc.json +792 -0
- package/public/iconesjs.svg +4 -0
- package/scripts/buildContentDoc-cli.ts +8 -0
- package/scripts/buildContentDoc.ts +165 -0
- package/tailwind.config.js +1 -0
- package/tsconfig.json +3 -0
- package/uno.config.mjs +58 -0
- package/utils/index.ts +12 -0
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<NavigationMenuItem v-bind="props">
|
|
3
|
+
<slot />
|
|
4
|
+
</NavigationMenuItem>
|
|
5
|
+
</template>
|
|
6
|
+
|
|
7
|
+
<script setup lang="ts">
|
|
8
|
+
import { NavigationMenuItem, type NavigationMenuItemProps } from 'reka-ui'
|
|
9
|
+
|
|
10
|
+
const props = defineProps<NavigationMenuItemProps>()
|
|
11
|
+
</script>
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<NavigationMenuLink v-bind="forwarded">
|
|
3
|
+
<slot />
|
|
4
|
+
</NavigationMenuLink>
|
|
5
|
+
</template>
|
|
6
|
+
|
|
7
|
+
<script setup lang="ts">
|
|
8
|
+
import {
|
|
9
|
+
NavigationMenuLink,
|
|
10
|
+
type NavigationMenuLinkEmits,
|
|
11
|
+
type NavigationMenuLinkProps,
|
|
12
|
+
useForwardPropsEmits,
|
|
13
|
+
} from 'reka-ui'
|
|
14
|
+
|
|
15
|
+
const props = defineProps<NavigationMenuLinkProps>()
|
|
16
|
+
const emits = defineEmits<NavigationMenuLinkEmits>()
|
|
17
|
+
|
|
18
|
+
const forwarded = useForwardPropsEmits(props, emits)
|
|
19
|
+
</script>
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<NavigationMenuList
|
|
3
|
+
v-bind="forwardedProps"
|
|
4
|
+
:class="
|
|
5
|
+
cn(
|
|
6
|
+
'group flex flex-1 list-none items-center justify-center gap-x-1',
|
|
7
|
+
props.class,
|
|
8
|
+
)
|
|
9
|
+
"
|
|
10
|
+
>
|
|
11
|
+
<slot />
|
|
12
|
+
</NavigationMenuList>
|
|
13
|
+
</template>
|
|
14
|
+
|
|
15
|
+
<script setup lang="ts">
|
|
16
|
+
import {
|
|
17
|
+
NavigationMenuList,
|
|
18
|
+
type NavigationMenuListProps,
|
|
19
|
+
useForwardProps,
|
|
20
|
+
} from 'reka-ui'
|
|
21
|
+
import { computed, type HTMLAttributes } from 'vue'
|
|
22
|
+
import { cn } from '@/lib/utils'
|
|
23
|
+
|
|
24
|
+
const props = defineProps<NavigationMenuListProps & { class?: HTMLAttributes['class'] }>()
|
|
25
|
+
|
|
26
|
+
const delegatedProps = computed(() => {
|
|
27
|
+
const { class: _, ...delegated } = props
|
|
28
|
+
|
|
29
|
+
return delegated
|
|
30
|
+
})
|
|
31
|
+
|
|
32
|
+
const forwardedProps = useForwardProps(delegatedProps)
|
|
33
|
+
</script>
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<NavigationMenuTrigger
|
|
3
|
+
v-bind="forwardedProps"
|
|
4
|
+
:class="cn(navigationMenuTriggerStyle(), 'group', props.class)"
|
|
5
|
+
>
|
|
6
|
+
<slot />
|
|
7
|
+
<NuxtIcon
|
|
8
|
+
name="lucide:chevron-down"
|
|
9
|
+
class="relative top-px ml-1 block size-3 transition duration-200 group-data-[state=open]:rotate-180"
|
|
10
|
+
aria-hidden="true"
|
|
11
|
+
/>
|
|
12
|
+
</NavigationMenuTrigger>
|
|
13
|
+
</template>
|
|
14
|
+
|
|
15
|
+
<script setup lang="ts">
|
|
16
|
+
import {
|
|
17
|
+
NavigationMenuTrigger,
|
|
18
|
+
type NavigationMenuTriggerProps,
|
|
19
|
+
useForwardProps,
|
|
20
|
+
} from 'reka-ui'
|
|
21
|
+
import { computed, type HTMLAttributes } from 'vue'
|
|
22
|
+
import { navigationMenuTriggerStyle } from '.'
|
|
23
|
+
import { cn } from '@/lib/utils'
|
|
24
|
+
|
|
25
|
+
const props = defineProps<NavigationMenuTriggerProps & { class?: HTMLAttributes['class'] }>()
|
|
26
|
+
|
|
27
|
+
const delegatedProps = computed(() => {
|
|
28
|
+
const { class: _, ...delegated } = props
|
|
29
|
+
|
|
30
|
+
return delegated
|
|
31
|
+
})
|
|
32
|
+
|
|
33
|
+
const forwardedProps = useForwardProps(delegatedProps)
|
|
34
|
+
</script>
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="absolute left-0 top-full flex justify-center">
|
|
3
|
+
<NavigationMenuViewport
|
|
4
|
+
v-bind="forwardedProps"
|
|
5
|
+
:class="
|
|
6
|
+
cn(
|
|
7
|
+
'origin-top-center relative mt-1.5 h-[--reka-navigation-menu-viewport-height] w-full overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-90 md:w-[--reka-navigation-menu-viewport-width]',
|
|
8
|
+
props.class,
|
|
9
|
+
)
|
|
10
|
+
"
|
|
11
|
+
/>
|
|
12
|
+
</div>
|
|
13
|
+
</template>
|
|
14
|
+
|
|
15
|
+
<script setup lang="ts">
|
|
16
|
+
import {
|
|
17
|
+
NavigationMenuViewport,
|
|
18
|
+
type NavigationMenuViewportProps,
|
|
19
|
+
useForwardProps,
|
|
20
|
+
} from 'reka-ui'
|
|
21
|
+
import { computed, type HTMLAttributes } from 'vue'
|
|
22
|
+
import { cn } from '@/lib/utils'
|
|
23
|
+
|
|
24
|
+
const props = defineProps<NavigationMenuViewportProps & { class?: HTMLAttributes['class'] }>()
|
|
25
|
+
|
|
26
|
+
const delegatedProps = computed(() => {
|
|
27
|
+
const { class: _, ...delegated } = props
|
|
28
|
+
|
|
29
|
+
return delegated
|
|
30
|
+
})
|
|
31
|
+
|
|
32
|
+
const forwardedProps = useForwardProps(delegatedProps)
|
|
33
|
+
</script>
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { cva } from 'class-variance-authority'
|
|
2
|
+
|
|
3
|
+
export { default as NavigationMenu } from './NavigationMenu.vue'
|
|
4
|
+
export { default as NavigationMenuContent } from './NavigationMenuContent.vue'
|
|
5
|
+
export { default as NavigationMenuIndicator } from './NavigationMenuIndicator.vue'
|
|
6
|
+
export { default as NavigationMenuItem } from './NavigationMenuItem.vue'
|
|
7
|
+
export { default as NavigationMenuLink } from './NavigationMenuLink.vue'
|
|
8
|
+
export { default as NavigationMenuList } from './NavigationMenuList.vue'
|
|
9
|
+
export { default as NavigationMenuTrigger } from './NavigationMenuTrigger.vue'
|
|
10
|
+
export { default as NavigationMenuViewport } from './NavigationMenuViewport.vue'
|
|
11
|
+
|
|
12
|
+
export const navigationMenuTriggerStyle = cva(
|
|
13
|
+
'group inline-flex h-10 w-max items-center justify-center rounded-md bg-background px-4 py-2 text-sm font-medium transition-colors hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground focus:outline-none disabled:pointer-events-none disabled:opacity-50 data-[active]:bg-accent/50 data-[state=open]:bg-accent/50',
|
|
14
|
+
)
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<PopoverRoot v-bind="forwarded">
|
|
3
|
+
<slot />
|
|
4
|
+
</PopoverRoot>
|
|
5
|
+
</template>
|
|
6
|
+
|
|
7
|
+
<script setup lang="ts">
|
|
8
|
+
import type { PopoverRootEmits, PopoverRootProps } from 'reka-ui'
|
|
9
|
+
import { PopoverRoot, useForwardPropsEmits } from 'reka-ui'
|
|
10
|
+
|
|
11
|
+
const props = defineProps<PopoverRootProps>()
|
|
12
|
+
const emits = defineEmits<PopoverRootEmits>()
|
|
13
|
+
|
|
14
|
+
const forwarded = useForwardPropsEmits(props, emits)
|
|
15
|
+
</script>
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<PopoverPortal>
|
|
3
|
+
<PopoverContent
|
|
4
|
+
v-bind="{ ...forwarded, ...$attrs }"
|
|
5
|
+
:class="
|
|
6
|
+
cn(
|
|
7
|
+
'z-50 w-72 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2',
|
|
8
|
+
props.class,
|
|
9
|
+
)
|
|
10
|
+
"
|
|
11
|
+
>
|
|
12
|
+
<slot />
|
|
13
|
+
</PopoverContent>
|
|
14
|
+
</PopoverPortal>
|
|
15
|
+
</template>
|
|
16
|
+
|
|
17
|
+
<script setup lang="ts">
|
|
18
|
+
import {
|
|
19
|
+
PopoverContent,
|
|
20
|
+
type PopoverContentEmits,
|
|
21
|
+
type PopoverContentProps,
|
|
22
|
+
PopoverPortal,
|
|
23
|
+
useForwardPropsEmits,
|
|
24
|
+
} from 'reka-ui'
|
|
25
|
+
import { computed, type HTMLAttributes } from 'vue'
|
|
26
|
+
import { cn } from '@/lib/utils'
|
|
27
|
+
|
|
28
|
+
defineOptions({
|
|
29
|
+
inheritAttrs: false,
|
|
30
|
+
})
|
|
31
|
+
|
|
32
|
+
const props = withDefaults(
|
|
33
|
+
defineProps<PopoverContentProps & { class?: HTMLAttributes['class'] }>(),
|
|
34
|
+
{
|
|
35
|
+
class: '',
|
|
36
|
+
align: 'center',
|
|
37
|
+
sideOffset: 4,
|
|
38
|
+
},
|
|
39
|
+
)
|
|
40
|
+
const emits = defineEmits<PopoverContentEmits>()
|
|
41
|
+
|
|
42
|
+
const delegatedProps = computed(() => {
|
|
43
|
+
const { class: _, ...delegated } = props
|
|
44
|
+
|
|
45
|
+
return delegated
|
|
46
|
+
})
|
|
47
|
+
|
|
48
|
+
const forwarded = useForwardPropsEmits(delegatedProps, emits)
|
|
49
|
+
</script>
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<ScrollAreaRoot
|
|
3
|
+
v-bind="delegatedProps"
|
|
4
|
+
:class="cn('relative overflow-hidden', props.class)"
|
|
5
|
+
>
|
|
6
|
+
<ScrollAreaViewport class="size-full rounded-[inherit]">
|
|
7
|
+
<slot />
|
|
8
|
+
</ScrollAreaViewport>
|
|
9
|
+
<ScrollBar />
|
|
10
|
+
<ScrollAreaCorner />
|
|
11
|
+
</ScrollAreaRoot>
|
|
12
|
+
</template>
|
|
13
|
+
|
|
14
|
+
<script setup lang="ts">
|
|
15
|
+
import {
|
|
16
|
+
ScrollAreaCorner,
|
|
17
|
+
ScrollAreaRoot,
|
|
18
|
+
type ScrollAreaRootProps,
|
|
19
|
+
ScrollAreaViewport,
|
|
20
|
+
} from 'reka-ui'
|
|
21
|
+
import { computed, type HTMLAttributes } from 'vue'
|
|
22
|
+
import ScrollBar from './ScrollBar.vue'
|
|
23
|
+
import { cn } from '@/lib/utils'
|
|
24
|
+
|
|
25
|
+
const props = defineProps<ScrollAreaRootProps & { class?: HTMLAttributes['class'] }>()
|
|
26
|
+
|
|
27
|
+
const delegatedProps = computed(() => {
|
|
28
|
+
const { class: _, ...delegated } = props
|
|
29
|
+
|
|
30
|
+
return delegated
|
|
31
|
+
})
|
|
32
|
+
</script>
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<ScrollAreaScrollbar
|
|
3
|
+
v-bind="delegatedProps"
|
|
4
|
+
:class="
|
|
5
|
+
cn(
|
|
6
|
+
'flex touch-none select-none transition-colors',
|
|
7
|
+
orientation === 'vertical'
|
|
8
|
+
&& 'h-full w-2.5 border-l border-l-transparent p-px',
|
|
9
|
+
orientation === 'horizontal'
|
|
10
|
+
&& 'h-2.5 flex-col border-t border-t-transparent p-px',
|
|
11
|
+
props.class,
|
|
12
|
+
)
|
|
13
|
+
"
|
|
14
|
+
>
|
|
15
|
+
<ScrollAreaThumb class="relative flex-1 rounded-full bg-border" />
|
|
16
|
+
</ScrollAreaScrollbar>
|
|
17
|
+
</template>
|
|
18
|
+
|
|
19
|
+
<script setup lang="ts">
|
|
20
|
+
import {
|
|
21
|
+
ScrollAreaScrollbar,
|
|
22
|
+
type ScrollAreaScrollbarProps,
|
|
23
|
+
ScrollAreaThumb,
|
|
24
|
+
} from 'reka-ui'
|
|
25
|
+
import { computed, type HTMLAttributes } from 'vue'
|
|
26
|
+
import { cn } from '@/lib/utils'
|
|
27
|
+
|
|
28
|
+
const props = withDefaults(
|
|
29
|
+
defineProps<ScrollAreaScrollbarProps & { class?: HTMLAttributes['class'] }>(),
|
|
30
|
+
{
|
|
31
|
+
class: '',
|
|
32
|
+
orientation: 'vertical',
|
|
33
|
+
},
|
|
34
|
+
)
|
|
35
|
+
|
|
36
|
+
const delegatedProps = computed(() => {
|
|
37
|
+
const { class: _, ...delegated } = props
|
|
38
|
+
|
|
39
|
+
return delegated
|
|
40
|
+
})
|
|
41
|
+
</script>
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<Separator
|
|
3
|
+
v-bind="delegatedProps"
|
|
4
|
+
:class="cn('shrink-0 bg-border', props.orientation === 'vertical' ? 'w-px h-full' : 'h-px w-full', props.class)"
|
|
5
|
+
/>
|
|
6
|
+
</template>
|
|
7
|
+
|
|
8
|
+
<script setup lang="ts">
|
|
9
|
+
import { Separator, type SeparatorProps } from 'reka-ui'
|
|
10
|
+
import { computed, type HTMLAttributes } from 'vue'
|
|
11
|
+
import { cn } from '@/lib/utils'
|
|
12
|
+
|
|
13
|
+
const props = defineProps<SeparatorProps & { class?: HTMLAttributes['class'] }>()
|
|
14
|
+
|
|
15
|
+
const delegatedProps = computed(() => {
|
|
16
|
+
const { class: _, ...delegated } = props
|
|
17
|
+
|
|
18
|
+
return delegated
|
|
19
|
+
})
|
|
20
|
+
</script>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Separator } from './Separator.vue'
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<DialogRoot v-bind="forwarded">
|
|
3
|
+
<slot />
|
|
4
|
+
</DialogRoot>
|
|
5
|
+
</template>
|
|
6
|
+
|
|
7
|
+
<script setup lang="ts">
|
|
8
|
+
import { DialogRoot, type DialogRootEmits, type DialogRootProps, useForwardPropsEmits } from 'reka-ui'
|
|
9
|
+
|
|
10
|
+
const props = defineProps<DialogRootProps>()
|
|
11
|
+
const emits = defineEmits<DialogRootEmits>()
|
|
12
|
+
|
|
13
|
+
const forwarded = useForwardPropsEmits(props, emits)
|
|
14
|
+
</script>
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<DialogPortal>
|
|
3
|
+
<DialogOverlay
|
|
4
|
+
class="fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0"
|
|
5
|
+
/>
|
|
6
|
+
<DialogContent
|
|
7
|
+
:class="cn(sheetVariants({ side }), props.class)"
|
|
8
|
+
v-bind="{ ...forwarded, ...$attrs }"
|
|
9
|
+
>
|
|
10
|
+
<slot />
|
|
11
|
+
|
|
12
|
+
<DialogClose
|
|
13
|
+
class="absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary"
|
|
14
|
+
>
|
|
15
|
+
<NuxtIcon
|
|
16
|
+
name="lucide:x"
|
|
17
|
+
class="block size-4 text-muted-foreground"
|
|
18
|
+
/>
|
|
19
|
+
</DialogClose>
|
|
20
|
+
</DialogContent>
|
|
21
|
+
</DialogPortal>
|
|
22
|
+
</template>
|
|
23
|
+
|
|
24
|
+
<script setup lang="ts">
|
|
25
|
+
import {
|
|
26
|
+
DialogClose,
|
|
27
|
+
DialogContent,
|
|
28
|
+
type DialogContentEmits,
|
|
29
|
+
type DialogContentProps,
|
|
30
|
+
DialogOverlay,
|
|
31
|
+
DialogPortal,
|
|
32
|
+
useForwardPropsEmits,
|
|
33
|
+
} from 'reka-ui'
|
|
34
|
+
import { computed, type HTMLAttributes } from 'vue'
|
|
35
|
+
import { type SheetVariants, sheetVariants } from '.'
|
|
36
|
+
import { cn } from '@/lib/utils'
|
|
37
|
+
|
|
38
|
+
interface SheetContentProps extends DialogContentProps {
|
|
39
|
+
class?: HTMLAttributes['class']
|
|
40
|
+
side?: SheetVariants['side']
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
defineOptions({
|
|
44
|
+
inheritAttrs: false,
|
|
45
|
+
})
|
|
46
|
+
|
|
47
|
+
const props = defineProps<SheetContentProps>()
|
|
48
|
+
|
|
49
|
+
const emits = defineEmits<DialogContentEmits>()
|
|
50
|
+
|
|
51
|
+
const delegatedProps = computed(() => {
|
|
52
|
+
const { class: _, side, ...delegated } = props
|
|
53
|
+
|
|
54
|
+
return delegated
|
|
55
|
+
})
|
|
56
|
+
|
|
57
|
+
const forwarded = useForwardPropsEmits(delegatedProps, emits)
|
|
58
|
+
</script>
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<DialogDescription
|
|
3
|
+
:class="cn('text-sm text-muted-foreground', props.class)"
|
|
4
|
+
v-bind="delegatedProps"
|
|
5
|
+
>
|
|
6
|
+
<slot />
|
|
7
|
+
</DialogDescription>
|
|
8
|
+
</template>
|
|
9
|
+
|
|
10
|
+
<script setup lang="ts">
|
|
11
|
+
import { DialogDescription, type DialogDescriptionProps } from 'reka-ui'
|
|
12
|
+
import { computed, type HTMLAttributes } from 'vue'
|
|
13
|
+
import { cn } from '@/lib/utils'
|
|
14
|
+
|
|
15
|
+
const props = defineProps<DialogDescriptionProps & { class?: HTMLAttributes['class'] }>()
|
|
16
|
+
|
|
17
|
+
const delegatedProps = computed(() => {
|
|
18
|
+
const { class: _, ...delegated } = props
|
|
19
|
+
|
|
20
|
+
return delegated
|
|
21
|
+
})
|
|
22
|
+
</script>
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div
|
|
3
|
+
:class="
|
|
4
|
+
cn(
|
|
5
|
+
'flex flex-col-reverse sm:flex-row sm:justify-end sm:gap-x-2',
|
|
6
|
+
props.class,
|
|
7
|
+
)
|
|
8
|
+
"
|
|
9
|
+
>
|
|
10
|
+
<slot />
|
|
11
|
+
</div>
|
|
12
|
+
</template>
|
|
13
|
+
|
|
14
|
+
<script setup lang="ts">
|
|
15
|
+
import type { HTMLAttributes } from 'vue'
|
|
16
|
+
import { cn } from '@/lib/utils'
|
|
17
|
+
|
|
18
|
+
const props = defineProps<{ class?: HTMLAttributes['class'] }>()
|
|
19
|
+
</script>
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div
|
|
3
|
+
:class="
|
|
4
|
+
cn('flex flex-col gap-y-2 text-center sm:text-left', props.class)
|
|
5
|
+
"
|
|
6
|
+
>
|
|
7
|
+
<slot />
|
|
8
|
+
</div>
|
|
9
|
+
</template>
|
|
10
|
+
|
|
11
|
+
<script setup lang="ts">
|
|
12
|
+
import type { HTMLAttributes } from 'vue'
|
|
13
|
+
import { cn } from '@/lib/utils'
|
|
14
|
+
|
|
15
|
+
const props = defineProps<{ class?: HTMLAttributes['class'] }>()
|
|
16
|
+
</script>
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<DialogTitle
|
|
3
|
+
:class="cn('text-lg font-semibold text-foreground', props.class)"
|
|
4
|
+
v-bind="delegatedProps"
|
|
5
|
+
>
|
|
6
|
+
<slot />
|
|
7
|
+
</DialogTitle>
|
|
8
|
+
</template>
|
|
9
|
+
|
|
10
|
+
<script setup lang="ts">
|
|
11
|
+
import { DialogTitle, type DialogTitleProps } from 'reka-ui'
|
|
12
|
+
import { computed, type HTMLAttributes } from 'vue'
|
|
13
|
+
import { cn } from '@/lib/utils'
|
|
14
|
+
|
|
15
|
+
const props = defineProps<DialogTitleProps & { class?: HTMLAttributes['class'] }>()
|
|
16
|
+
|
|
17
|
+
const delegatedProps = computed(() => {
|
|
18
|
+
const { class: _, ...delegated } = props
|
|
19
|
+
|
|
20
|
+
return delegated
|
|
21
|
+
})
|
|
22
|
+
</script>
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { cva, type VariantProps } from 'class-variance-authority'
|
|
2
|
+
|
|
3
|
+
export { default as Sheet } from './Sheet.vue'
|
|
4
|
+
export { default as SheetClose } from './SheetClose.vue'
|
|
5
|
+
export { default as SheetContent } from './SheetContent.vue'
|
|
6
|
+
export { default as SheetDescription } from './SheetDescription.vue'
|
|
7
|
+
export { default as SheetFooter } from './SheetFooter.vue'
|
|
8
|
+
export { default as SheetHeader } from './SheetHeader.vue'
|
|
9
|
+
export { default as SheetTitle } from './SheetTitle.vue'
|
|
10
|
+
export { default as SheetTrigger } from './SheetTrigger.vue'
|
|
11
|
+
|
|
12
|
+
export const sheetVariants = cva(
|
|
13
|
+
'fixed z-50 gap-4 bg-background p-6 shadow-lg transition ease-in-out data-[state=closed]:duration-300 data-[state=open]:duration-500 data-[state=open]:animate-in data-[state=closed]:animate-out',
|
|
14
|
+
{
|
|
15
|
+
variants: {
|
|
16
|
+
side: {
|
|
17
|
+
top: 'inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top',
|
|
18
|
+
bottom:
|
|
19
|
+
'inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom',
|
|
20
|
+
left: 'inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm',
|
|
21
|
+
right:
|
|
22
|
+
'inset-y-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm',
|
|
23
|
+
},
|
|
24
|
+
},
|
|
25
|
+
defaultVariants: {
|
|
26
|
+
side: 'right',
|
|
27
|
+
},
|
|
28
|
+
},
|
|
29
|
+
)
|
|
30
|
+
|
|
31
|
+
export type SheetVariants = VariantProps<typeof sheetVariants>
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import type { SliderRootEmits, SliderRootProps } from 'reka-ui'
|
|
3
|
+
import { SliderRange, SliderRoot, SliderThumb, SliderTrack, useForwardPropsEmits } from 'reka-ui'
|
|
4
|
+
import { computed, type HTMLAttributes } from 'vue'
|
|
5
|
+
import { cn } from '@/lib/utils'
|
|
6
|
+
|
|
7
|
+
const props = defineProps<SliderRootProps & { class?: HTMLAttributes['class'] }>()
|
|
8
|
+
const emits = defineEmits<SliderRootEmits>()
|
|
9
|
+
|
|
10
|
+
const delegatedProps = computed(() => {
|
|
11
|
+
const { class: _, ...delegated } = props
|
|
12
|
+
|
|
13
|
+
return delegated
|
|
14
|
+
})
|
|
15
|
+
|
|
16
|
+
const forwarded = useForwardPropsEmits(delegatedProps, emits)
|
|
17
|
+
</script>
|
|
18
|
+
|
|
19
|
+
<template>
|
|
20
|
+
<SliderRoot
|
|
21
|
+
:class="cn(
|
|
22
|
+
'relative flex w-full touch-none select-none items-center data-[orientation=vertical]:flex-col data-[orientation=vertical]:w-2 data-[orientation=vertical]:h-full',
|
|
23
|
+
props.class,
|
|
24
|
+
)"
|
|
25
|
+
v-bind="forwarded"
|
|
26
|
+
>
|
|
27
|
+
<SliderTrack class="relative h-2 w-full data-[orientation=vertical]:w-2 grow overflow-hidden rounded-full bg-secondary">
|
|
28
|
+
<SliderRange class="absolute h-full data-[orientation=vertical]:w-full bg-primary" />
|
|
29
|
+
</SliderTrack>
|
|
30
|
+
<SliderThumb
|
|
31
|
+
v-for="(_, key) in modelValue"
|
|
32
|
+
:key="key"
|
|
33
|
+
class="block h-5 w-5 rounded-full border-2 border-primary bg-background ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50"
|
|
34
|
+
/>
|
|
35
|
+
</SliderRoot>
|
|
36
|
+
</template>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Slider } from './Slider.vue'
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<TabsRoot v-bind="forwarded">
|
|
3
|
+
<slot />
|
|
4
|
+
</TabsRoot>
|
|
5
|
+
</template>
|
|
6
|
+
|
|
7
|
+
<script setup lang="ts">
|
|
8
|
+
import type { TabsRootEmits, TabsRootProps } from 'reka-ui'
|
|
9
|
+
import { TabsRoot, useForwardPropsEmits } from 'reka-ui'
|
|
10
|
+
|
|
11
|
+
const props = defineProps<TabsRootProps>()
|
|
12
|
+
const emits = defineEmits<TabsRootEmits>()
|
|
13
|
+
|
|
14
|
+
const forwarded = useForwardPropsEmits(props, emits)
|
|
15
|
+
</script>
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<TabsContent
|
|
3
|
+
:class="cn('mt-2 ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2', props.class)"
|
|
4
|
+
v-bind="delegatedProps"
|
|
5
|
+
>
|
|
6
|
+
<slot />
|
|
7
|
+
</TabsContent>
|
|
8
|
+
</template>
|
|
9
|
+
|
|
10
|
+
<script setup lang="ts">
|
|
11
|
+
import { TabsContent, type TabsContentProps } from 'reka-ui'
|
|
12
|
+
import { computed, type HTMLAttributes } from 'vue'
|
|
13
|
+
import { cn } from '@/lib/utils'
|
|
14
|
+
|
|
15
|
+
const props = defineProps<TabsContentProps & { class?: HTMLAttributes['class'] }>()
|
|
16
|
+
|
|
17
|
+
const delegatedProps = computed(() => {
|
|
18
|
+
const { class: _, ...delegated } = props
|
|
19
|
+
|
|
20
|
+
return delegated
|
|
21
|
+
})
|
|
22
|
+
</script>
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<TabsList
|
|
3
|
+
v-bind="delegatedProps"
|
|
4
|
+
:class="cn(
|
|
5
|
+
'inline-flex h-10 items-center justify-center rounded-md bg-muted p-1 text-muted-foreground',
|
|
6
|
+
props.class,
|
|
7
|
+
)"
|
|
8
|
+
>
|
|
9
|
+
<slot />
|
|
10
|
+
</TabsList>
|
|
11
|
+
</template>
|
|
12
|
+
|
|
13
|
+
<script setup lang="ts">
|
|
14
|
+
import { TabsList, type TabsListProps } from 'reka-ui'
|
|
15
|
+
import { computed, type HTMLAttributes } from 'vue'
|
|
16
|
+
import { cn } from '@/lib/utils'
|
|
17
|
+
|
|
18
|
+
const props = defineProps<TabsListProps & { class?: HTMLAttributes['class'] }>()
|
|
19
|
+
|
|
20
|
+
const delegatedProps = computed(() => {
|
|
21
|
+
const { class: _, ...delegated } = props
|
|
22
|
+
|
|
23
|
+
return delegated
|
|
24
|
+
})
|
|
25
|
+
</script>
|