@nuxt/ui 4.7.0 → 4.8.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/.nuxt/{ui.css → ui.static.css} +0 -10
- package/LICENSE.md +1 -1
- package/cli/commands/make/component.mjs +6 -2
- package/cli/templates.mjs +46 -20
- package/cli/utils.mjs +19 -0
- package/dist/module.json +1 -1
- package/dist/module.mjs +4 -4
- package/dist/runtime/components/Accordion.vue +15 -14
- package/dist/runtime/components/Alert.vue +20 -20
- package/dist/runtime/components/AuthForm.vue +37 -37
- package/dist/runtime/components/Avatar.d.vue.ts +4 -0
- package/dist/runtime/components/Avatar.vue +14 -12
- package/dist/runtime/components/Avatar.vue.d.ts +4 -0
- package/dist/runtime/components/AvatarGroup.d.vue.ts +4 -0
- package/dist/runtime/components/AvatarGroup.vue +11 -8
- package/dist/runtime/components/AvatarGroup.vue.d.ts +4 -0
- package/dist/runtime/components/Badge.vue +11 -11
- package/dist/runtime/components/Banner.vue +25 -23
- package/dist/runtime/components/BlogPost.d.vue.ts +1 -1
- package/dist/runtime/components/BlogPost.vue +30 -28
- package/dist/runtime/components/BlogPost.vue.d.ts +1 -1
- package/dist/runtime/components/BlogPosts.vue +6 -6
- package/dist/runtime/components/Breadcrumb.d.vue.ts +4 -0
- package/dist/runtime/components/Breadcrumb.vue +21 -18
- package/dist/runtime/components/Breadcrumb.vue.d.ts +4 -0
- package/dist/runtime/components/Button.vue +17 -16
- package/dist/runtime/components/Calendar.vue +21 -20
- package/dist/runtime/components/Card.vue +11 -11
- package/dist/runtime/components/Carousel.vue +23 -22
- package/dist/runtime/components/ChangelogVersion.vue +31 -29
- package/dist/runtime/components/ChangelogVersions.vue +8 -8
- package/dist/runtime/components/ChatMessage.d.vue.ts +6 -0
- package/dist/runtime/components/ChatMessage.vue +46 -36
- package/dist/runtime/components/ChatMessage.vue.d.ts +6 -0
- package/dist/runtime/components/ChatMessages.vue +14 -14
- package/dist/runtime/components/ChatPalette.vue +6 -6
- package/dist/runtime/components/ChatPrompt.d.vue.ts +7 -0
- package/dist/runtime/components/ChatPrompt.vue +22 -12
- package/dist/runtime/components/ChatPrompt.vue.d.ts +7 -0
- package/dist/runtime/components/ChatPromptSubmit.d.vue.ts +3 -3
- package/dist/runtime/components/ChatPromptSubmit.vue +6 -6
- package/dist/runtime/components/ChatPromptSubmit.vue.d.ts +3 -3
- package/dist/runtime/components/ChatReasoning.vue +20 -20
- package/dist/runtime/components/ChatShimmer.vue +7 -7
- package/dist/runtime/components/ChatTool.d.vue.ts +1 -1
- package/dist/runtime/components/ChatTool.vue +19 -19
- package/dist/runtime/components/ChatTool.vue.d.ts +1 -1
- package/dist/runtime/components/Checkbox.d.vue.ts +2 -0
- package/dist/runtime/components/Checkbox.vue +25 -24
- package/dist/runtime/components/Checkbox.vue.d.ts +2 -0
- package/dist/runtime/components/CheckboxGroup.d.vue.ts +1 -1
- package/dist/runtime/components/CheckboxGroup.vue +17 -14
- package/dist/runtime/components/CheckboxGroup.vue.d.ts +1 -1
- package/dist/runtime/components/Chip.vue +8 -8
- package/dist/runtime/components/Collapsible.vue +8 -7
- package/dist/runtime/components/ColorPicker.d.vue.ts +2 -0
- package/dist/runtime/components/ColorPicker.vue +10 -10
- package/dist/runtime/components/ColorPicker.vue.d.ts +2 -0
- package/dist/runtime/components/CommandPalette.d.vue.ts +5 -5
- package/dist/runtime/components/CommandPalette.vue +92 -69
- package/dist/runtime/components/CommandPalette.vue.d.ts +5 -5
- package/dist/runtime/components/Container.vue +4 -4
- package/dist/runtime/components/ContextMenu.vue +16 -15
- package/dist/runtime/components/DashboardGroup.d.vue.ts +1 -1
- package/dist/runtime/components/DashboardGroup.vue +6 -4
- package/dist/runtime/components/DashboardGroup.vue.d.ts +1 -1
- package/dist/runtime/components/DashboardNavbar.vue +16 -16
- package/dist/runtime/components/DashboardPanel.vue +7 -7
- package/dist/runtime/components/DashboardResizeHandle.vue +5 -5
- package/dist/runtime/components/DashboardSearch.d.vue.ts +16 -1
- package/dist/runtime/components/DashboardSearch.vue +13 -11
- package/dist/runtime/components/DashboardSearch.vue.d.ts +16 -1
- package/dist/runtime/components/DashboardSearchButton.d.vue.ts +2 -2
- package/dist/runtime/components/DashboardSearchButton.vue +15 -15
- package/dist/runtime/components/DashboardSearchButton.vue.d.ts +2 -2
- package/dist/runtime/components/DashboardSidebar.d.vue.ts +1 -1
- package/dist/runtime/components/DashboardSidebar.vue +22 -22
- package/dist/runtime/components/DashboardSidebar.vue.d.ts +1 -1
- package/dist/runtime/components/DashboardSidebarCollapse.d.vue.ts +1 -1
- package/dist/runtime/components/DashboardSidebarCollapse.vue +5 -5
- package/dist/runtime/components/DashboardSidebarCollapse.vue.d.ts +1 -1
- package/dist/runtime/components/DashboardSidebarToggle.d.vue.ts +1 -1
- package/dist/runtime/components/DashboardSidebarToggle.vue +5 -5
- package/dist/runtime/components/DashboardSidebarToggle.vue.d.ts +1 -1
- package/dist/runtime/components/DashboardToolbar.vue +6 -6
- package/dist/runtime/components/Drawer.d.vue.ts +1 -1
- package/dist/runtime/components/Drawer.vue +23 -22
- package/dist/runtime/components/Drawer.vue.d.ts +1 -1
- package/dist/runtime/components/DropdownMenu.vue +21 -20
- package/dist/runtime/components/Editor.vue +8 -7
- package/dist/runtime/components/EditorDragHandle.d.vue.ts +2 -2
- package/dist/runtime/components/EditorDragHandle.vue +8 -8
- package/dist/runtime/components/EditorDragHandle.vue.d.ts +2 -2
- package/dist/runtime/components/EditorToolbar.vue +10 -9
- package/dist/runtime/components/Empty.vue +14 -14
- package/dist/runtime/components/Error.d.vue.ts +9 -1
- package/dist/runtime/components/Error.vue +17 -10
- package/dist/runtime/components/Error.vue.d.ts +9 -1
- package/dist/runtime/components/FieldGroup.vue +4 -4
- package/dist/runtime/components/FileUpload.vue +36 -37
- package/dist/runtime/components/Footer.vue +10 -10
- package/dist/runtime/components/FooterColumns.vue +15 -15
- package/dist/runtime/components/Form.d.vue.ts +1 -1
- package/dist/runtime/components/Form.vue +5 -5
- package/dist/runtime/components/Form.vue.d.ts +1 -1
- package/dist/runtime/components/FormField.d.vue.ts +2 -1
- package/dist/runtime/components/FormField.vue +21 -21
- package/dist/runtime/components/FormField.vue.d.ts +2 -1
- package/dist/runtime/components/Header.vue +19 -19
- package/dist/runtime/components/Input.vue +19 -19
- package/dist/runtime/components/InputDate.vue +21 -20
- package/dist/runtime/components/InputMenu.d.vue.ts +52 -51
- package/dist/runtime/components/InputMenu.vue +66 -63
- package/dist/runtime/components/InputMenu.vue.d.ts +52 -51
- package/dist/runtime/components/InputNumber.vue +25 -24
- package/dist/runtime/components/InputTags.vue +26 -25
- package/dist/runtime/components/InputTime.vue +21 -20
- package/dist/runtime/components/Kbd.vue +5 -5
- package/dist/runtime/components/Link.d.vue.ts +11 -2
- package/dist/runtime/components/Link.vue +13 -4
- package/dist/runtime/components/Link.vue.d.ts +11 -2
- package/dist/runtime/components/Listbox.d.vue.ts +13 -9
- package/dist/runtime/components/Listbox.vue +34 -32
- package/dist/runtime/components/Listbox.vue.d.ts +13 -9
- package/dist/runtime/components/Main.vue +4 -4
- package/dist/runtime/components/Marquee.vue +5 -5
- package/dist/runtime/components/Modal.d.vue.ts +2 -2
- package/dist/runtime/components/Modal.vue +25 -24
- package/dist/runtime/components/Modal.vue.d.ts +2 -2
- package/dist/runtime/components/NavigationMenu.vue +66 -65
- package/dist/runtime/components/Page.vue +7 -7
- package/dist/runtime/components/PageAnchors.vue +11 -11
- package/dist/runtime/components/PageAside.vue +9 -9
- package/dist/runtime/components/PageBody.vue +4 -4
- package/dist/runtime/components/PageCTA.vue +18 -16
- package/dist/runtime/components/PageCard.vue +25 -23
- package/dist/runtime/components/PageColumns.vue +4 -4
- package/dist/runtime/components/PageFeature.vue +17 -15
- package/dist/runtime/components/PageGrid.vue +4 -4
- package/dist/runtime/components/PageHeader.vue +14 -14
- package/dist/runtime/components/PageHero.vue +20 -18
- package/dist/runtime/components/PageLinks.vue +12 -12
- package/dist/runtime/components/PageList.vue +4 -4
- package/dist/runtime/components/PageLogos.vue +16 -16
- package/dist/runtime/components/PageSection.d.vue.ts +1 -1
- package/dist/runtime/components/PageSection.vue +24 -22
- package/dist/runtime/components/PageSection.vue.d.ts +1 -1
- package/dist/runtime/components/Pagination.d.vue.ts +2 -2
- package/dist/runtime/components/Pagination.vue +23 -22
- package/dist/runtime/components/Pagination.vue.d.ts +2 -2
- package/dist/runtime/components/PinInput.vue +15 -14
- package/dist/runtime/components/Popover.vue +9 -8
- package/dist/runtime/components/PricingPlan.vue +36 -36
- package/dist/runtime/components/PricingPlans.vue +6 -6
- package/dist/runtime/components/PricingTable.vue +44 -44
- package/dist/runtime/components/Progress.d.vue.ts +1 -1
- package/dist/runtime/components/Progress.vue +12 -11
- package/dist/runtime/components/Progress.vue.d.ts +1 -1
- package/dist/runtime/components/RadioGroup.d.vue.ts +2 -0
- package/dist/runtime/components/RadioGroup.vue +28 -27
- package/dist/runtime/components/RadioGroup.vue.d.ts +2 -0
- package/dist/runtime/components/ScrollArea.vue +13 -13
- package/dist/runtime/components/Select.vue +38 -40
- package/dist/runtime/components/SelectMenu.d.vue.ts +46 -46
- package/dist/runtime/components/SelectMenu.vue +49 -48
- package/dist/runtime/components/SelectMenu.vue.d.ts +46 -46
- package/dist/runtime/components/Separator.d.vue.ts +9 -3
- package/dist/runtime/components/Separator.vue +29 -16
- package/dist/runtime/components/Separator.vue.d.ts +9 -3
- package/dist/runtime/components/Sidebar.vue +28 -28
- package/dist/runtime/components/Skeleton.vue +5 -5
- package/dist/runtime/components/Slideover.d.vue.ts +3 -3
- package/dist/runtime/components/Slideover.vue +24 -23
- package/dist/runtime/components/Slideover.vue.d.ts +3 -3
- package/dist/runtime/components/Slider.vue +16 -15
- package/dist/runtime/components/Stepper.vue +19 -18
- package/dist/runtime/components/Switch.d.vue.ts +2 -0
- package/dist/runtime/components/Switch.vue +26 -23
- package/dist/runtime/components/Switch.vue.d.ts +2 -0
- package/dist/runtime/components/Table.vue +26 -25
- package/dist/runtime/components/Tabs.vue +22 -21
- package/dist/runtime/components/Textarea.vue +19 -18
- package/dist/runtime/components/Theme.d.vue.ts +13 -5
- package/dist/runtime/components/Theme.vue +32 -4
- package/dist/runtime/components/Theme.vue.d.ts +13 -5
- package/dist/runtime/components/Timeline.vue +15 -15
- package/dist/runtime/components/Toast.vue +35 -34
- package/dist/runtime/components/Toaster.d.vue.ts +1 -1
- package/dist/runtime/components/Toaster.vue +10 -9
- package/dist/runtime/components/Toaster.vue.d.ts +1 -1
- package/dist/runtime/components/Tooltip.vue +13 -12
- package/dist/runtime/components/Tree.vue +24 -23
- package/dist/runtime/components/User.vue +23 -21
- package/dist/runtime/components/color-mode/ColorModeAvatar.vue +5 -2
- package/dist/runtime/components/color-mode/ColorModeButton.d.vue.ts +1 -1
- package/dist/runtime/components/color-mode/ColorModeButton.vue +8 -6
- package/dist/runtime/components/color-mode/ColorModeButton.vue.d.ts +1 -1
- package/dist/runtime/components/color-mode/ColorModeImage.vue +4 -2
- package/dist/runtime/components/color-mode/ColorModeSwitch.vue +1 -0
- package/dist/runtime/components/content/ContentNavigation.vue +31 -30
- package/dist/runtime/components/content/ContentSearch.d.vue.ts +30 -3
- package/dist/runtime/components/content/ContentSearch.vue +66 -32
- package/dist/runtime/components/content/ContentSearch.vue.d.ts +30 -3
- package/dist/runtime/components/content/ContentSearchButton.d.vue.ts +2 -2
- package/dist/runtime/components/content/ContentSearchButton.vue +15 -15
- package/dist/runtime/components/content/ContentSearchButton.vue.d.ts +2 -2
- package/dist/runtime/components/content/ContentSurround.vue +14 -12
- package/dist/runtime/components/content/ContentToc.vue +34 -33
- package/dist/runtime/components/prose/A.vue +4 -4
- package/dist/runtime/components/prose/Accordion.vue +4 -4
- package/dist/runtime/components/prose/AccordionItem.vue +5 -5
- package/dist/runtime/components/prose/Badge.vue +4 -4
- package/dist/runtime/components/prose/Blockquote.vue +4 -4
- package/dist/runtime/components/prose/Callout.vue +8 -8
- package/dist/runtime/components/prose/Card.vue +12 -12
- package/dist/runtime/components/prose/CardGroup.vue +4 -4
- package/dist/runtime/components/prose/Code.vue +4 -4
- package/dist/runtime/components/prose/CodeCollapse.vue +8 -8
- package/dist/runtime/components/prose/CodeGroup.vue +9 -9
- package/dist/runtime/components/prose/CodePreview.vue +6 -6
- package/dist/runtime/components/prose/CodeTree.vue +14 -14
- package/dist/runtime/components/prose/Collapsible.vue +7 -7
- package/dist/runtime/components/prose/Em.vue +4 -4
- package/dist/runtime/components/prose/Field.vue +13 -13
- package/dist/runtime/components/prose/FieldGroup.vue +4 -4
- package/dist/runtime/components/prose/H1.vue +5 -5
- package/dist/runtime/components/prose/H2.vue +7 -7
- package/dist/runtime/components/prose/H3.vue +7 -7
- package/dist/runtime/components/prose/H4.vue +5 -5
- package/dist/runtime/components/prose/Hr.vue +4 -4
- package/dist/runtime/components/prose/Icon.vue +4 -4
- package/dist/runtime/components/prose/Img.vue +17 -12
- package/dist/runtime/components/prose/Kbd.d.vue.ts +10 -2
- package/dist/runtime/components/prose/Kbd.vue +8 -5
- package/dist/runtime/components/prose/Kbd.vue.d.ts +10 -2
- package/dist/runtime/components/prose/Li.vue +4 -4
- package/dist/runtime/components/prose/Ol.vue +4 -4
- package/dist/runtime/components/prose/P.vue +4 -4
- package/dist/runtime/components/prose/Pre.vue +9 -9
- package/dist/runtime/components/prose/Prompt.vue +12 -12
- package/dist/runtime/components/prose/Steps.vue +4 -4
- package/dist/runtime/components/prose/Strong.vue +4 -4
- package/dist/runtime/components/prose/Table.vue +5 -5
- package/dist/runtime/components/prose/Tabs.vue +4 -4
- package/dist/runtime/components/prose/TabsItem.vue +5 -5
- package/dist/runtime/components/prose/Tbody.vue +4 -4
- package/dist/runtime/components/prose/Td.vue +4 -4
- package/dist/runtime/components/prose/Th.vue +4 -4
- package/dist/runtime/components/prose/Thead.vue +4 -4
- package/dist/runtime/components/prose/Tr.vue +4 -4
- package/dist/runtime/components/prose/Ul.vue +4 -4
- package/dist/runtime/composables/defineShortcuts.js +7 -2
- package/dist/runtime/composables/index.d.ts +1 -2
- package/dist/runtime/composables/index.js +1 -2
- package/dist/runtime/composables/useAvatarGroup.d.ts +12 -1
- package/dist/runtime/composables/useAvatarGroup.js +4 -2
- package/dist/runtime/composables/useComponentIcons.js +1 -1
- package/dist/runtime/composables/useComponentProps.d.ts +180 -0
- package/dist/runtime/composables/useComponentProps.js +59 -0
- package/dist/runtime/composables/useContentSearch.d.ts +4 -2
- package/dist/runtime/composables/useContentSearch.js +64 -7
- package/dist/runtime/composables/useFieldGroup.d.ts +9 -1
- package/dist/runtime/composables/useFormField.d.ts +21 -1
- package/dist/runtime/composables/useForwardProps.d.ts +13 -0
- package/dist/runtime/composables/useForwardProps.js +14 -0
- package/dist/runtime/composables/usePrefix.d.ts +6 -0
- package/dist/runtime/composables/usePrefix.js +11 -0
- package/dist/runtime/composables/useResizable.d.ts +4 -0
- package/dist/runtime/composables/useResizable.js +1 -1
- package/dist/runtime/locale/ar.js +1 -0
- package/dist/runtime/locale/az.js +1 -0
- package/dist/runtime/locale/be.js +1 -0
- package/dist/runtime/locale/bg.js +1 -0
- package/dist/runtime/locale/bn.js +1 -0
- package/dist/runtime/locale/ca.js +1 -0
- package/dist/runtime/locale/ckb.js +1 -0
- package/dist/runtime/locale/cs.js +1 -0
- package/dist/runtime/locale/da.js +1 -0
- package/dist/runtime/locale/de.js +1 -0
- package/dist/runtime/locale/de_ch.js +1 -0
- package/dist/runtime/locale/el.js +1 -0
- package/dist/runtime/locale/en.js +1 -0
- package/dist/runtime/locale/es.js +1 -0
- package/dist/runtime/locale/et.js +1 -0
- package/dist/runtime/locale/eu.js +1 -0
- package/dist/runtime/locale/fa_ir.js +1 -0
- package/dist/runtime/locale/fi.js +1 -0
- package/dist/runtime/locale/fr.js +1 -0
- package/dist/runtime/locale/gl.js +1 -0
- package/dist/runtime/locale/he.js +1 -0
- package/dist/runtime/locale/hi.js +1 -0
- package/dist/runtime/locale/hr.js +1 -0
- package/dist/runtime/locale/hu.js +1 -0
- package/dist/runtime/locale/hy.js +1 -0
- package/dist/runtime/locale/id.js +1 -0
- package/dist/runtime/locale/is.js +1 -0
- package/dist/runtime/locale/it.js +1 -0
- package/dist/runtime/locale/ja.js +1 -0
- package/dist/runtime/locale/ka.js +1 -0
- package/dist/runtime/locale/kk.js +1 -0
- package/dist/runtime/locale/km.js +1 -0
- package/dist/runtime/locale/ko.js +1 -0
- package/dist/runtime/locale/ky.js +1 -0
- package/dist/runtime/locale/lb.js +1 -0
- package/dist/runtime/locale/lo.js +1 -0
- package/dist/runtime/locale/lt.js +1 -0
- package/dist/runtime/locale/mn.js +1 -0
- package/dist/runtime/locale/ms.js +1 -0
- package/dist/runtime/locale/nb_no.js +1 -0
- package/dist/runtime/locale/nl.js +1 -0
- package/dist/runtime/locale/pl.js +1 -0
- package/dist/runtime/locale/pt.js +1 -0
- package/dist/runtime/locale/pt_br.js +1 -0
- package/dist/runtime/locale/ro.js +1 -0
- package/dist/runtime/locale/ru.js +1 -0
- package/dist/runtime/locale/sk.js +1 -0
- package/dist/runtime/locale/sl.js +1 -0
- package/dist/runtime/locale/sq.js +1 -0
- package/dist/runtime/locale/sv.js +1 -0
- package/dist/runtime/locale/th.js +1 -0
- package/dist/runtime/locale/tj.js +1 -0
- package/dist/runtime/locale/tr.js +1 -0
- package/dist/runtime/locale/ug_cn.js +1 -0
- package/dist/runtime/locale/uk.js +1 -0
- package/dist/runtime/locale/ur.js +1 -0
- package/dist/runtime/locale/uz.js +1 -0
- package/dist/runtime/locale/vi.js +1 -0
- package/dist/runtime/locale/zh_cn.js +1 -0
- package/dist/runtime/locale/zh_tw.js +1 -0
- package/dist/runtime/plugins/colors.js +1 -1
- package/dist/runtime/types/content.d.ts +1 -0
- package/dist/runtime/types/content.js +1 -0
- package/dist/runtime/types/form.d.ts +2 -2
- package/dist/runtime/types/locale.d.ts +1 -0
- package/dist/runtime/utils/dashboard.d.ts +1 -1
- package/dist/runtime/utils/link.d.ts +1 -1
- package/dist/runtime/utils/link.js +1 -0
- package/dist/runtime/utils/{fuse.d.ts → search.d.ts} +2 -1
- package/dist/runtime/utils/{fuse.js → search.js} +11 -2
- package/dist/runtime/vue/components/color-mode/ColorModeSwitch.vue +1 -0
- package/dist/runtime/vue/overrides/inertia/Link.d.vue.ts +1 -1
- package/dist/runtime/vue/overrides/inertia/Link.vue +5 -0
- package/dist/runtime/vue/overrides/inertia/Link.vue.d.ts +1 -1
- package/dist/runtime/vue/overrides/none/Link.d.vue.ts +1 -1
- package/dist/runtime/vue/overrides/none/Link.vue.d.ts +1 -1
- package/dist/runtime/vue/overrides/vue-router/Link.d.vue.ts +1 -1
- package/dist/runtime/vue/overrides/vue-router/Link.vue.d.ts +1 -1
- package/dist/shared/{ui.BIQuJqNV.mjs → ui.CoJ8bnb0.mjs} +244 -83
- package/dist/unplugin.mjs +1 -1
- package/dist/vite.mjs +1 -1
- package/package.json +27 -34
- package/dist/runtime/composables/useComponentUI.d.ts +0 -33
- package/dist/runtime/composables/useComponentUI.js +0 -13
- package/dist/runtime/composables/useResolvedVariants.d.ts +0 -21
- package/dist/runtime/composables/useResolvedVariants.js +0 -14
|
@@ -6,11 +6,12 @@ import theme from "#build/ui/page-hero";
|
|
|
6
6
|
import { computed } from "vue";
|
|
7
7
|
import { Primitive } from "reka-ui";
|
|
8
8
|
import { useAppConfig } from "#imports";
|
|
9
|
-
import {
|
|
9
|
+
import { useComponentProps } from "../composables/useComponentProps";
|
|
10
|
+
import { usePrefix } from "../composables/usePrefix";
|
|
10
11
|
import { tv } from "../utils/tv";
|
|
11
12
|
import UButton from "./Button.vue";
|
|
12
13
|
import UContainer from "./Container.vue";
|
|
13
|
-
const
|
|
14
|
+
const _props = defineProps({
|
|
14
15
|
as: { type: null, required: false },
|
|
15
16
|
headline: { type: String, required: false },
|
|
16
17
|
title: { type: String, required: false },
|
|
@@ -22,8 +23,9 @@ const props = defineProps({
|
|
|
22
23
|
ui: { type: Object, required: false }
|
|
23
24
|
});
|
|
24
25
|
const slots = defineSlots();
|
|
26
|
+
const props = useComponentProps("pageHero", _props);
|
|
25
27
|
const appConfig = useAppConfig();
|
|
26
|
-
const
|
|
28
|
+
const prefix = usePrefix();
|
|
27
29
|
const ui = computed(() => tv({ extend: tv(theme), ...appConfig.ui?.pageHero || {} })({
|
|
28
30
|
orientation: props.orientation,
|
|
29
31
|
reverse: props.reverse,
|
|
@@ -32,42 +34,42 @@ const ui = computed(() => tv({ extend: tv(theme), ...appConfig.ui?.pageHero || {
|
|
|
32
34
|
</script>
|
|
33
35
|
|
|
34
36
|
<template>
|
|
35
|
-
<Primitive :as="as" :data-orientation="orientation" data-slot="root" :class="ui.root({ class: [
|
|
37
|
+
<Primitive :as="props.as" :data-orientation="props.orientation" data-slot="root" :class="ui.root({ class: [props.ui?.root, props.class] })">
|
|
36
38
|
<slot name="top" />
|
|
37
39
|
|
|
38
|
-
<UContainer data-slot="container" :class="ui.container({ class:
|
|
39
|
-
<div v-if="!!slots.header || (headline || !!slots.headline) || (title || !!slots.title) || (description || !!slots.description) || !!slots.body || !!slots.footer || (links?.length || !!slots.links)" data-slot="wrapper" :class="ui.wrapper({ class:
|
|
40
|
-
<div v-if="!!slots.header || (headline || !!slots.headline) || (title || !!slots.title) || (description || !!slots.description)" data-slot="header" :class="ui.header({ class:
|
|
40
|
+
<UContainer data-slot="container" :class="ui.container({ class: props.ui?.container })">
|
|
41
|
+
<div v-if="!!slots.header || (props.headline || !!slots.headline) || (props.title || !!slots.title) || (props.description || !!slots.description) || !!slots.body || !!slots.footer || (props.links?.length || !!slots.links)" data-slot="wrapper" :class="ui.wrapper({ class: props.ui?.wrapper })">
|
|
42
|
+
<div v-if="!!slots.header || (props.headline || !!slots.headline) || (props.title || !!slots.title) || (props.description || !!slots.description)" data-slot="header" :class="ui.header({ class: props.ui?.header })">
|
|
41
43
|
<slot name="header">
|
|
42
|
-
<div v-if="headline || !!slots.headline" data-slot="headline" :class="ui.headline({ class:
|
|
44
|
+
<div v-if="props.headline || !!slots.headline" data-slot="headline" :class="ui.headline({ class: props.ui?.headline, headline: !slots.headline })">
|
|
43
45
|
<slot name="headline">
|
|
44
|
-
{{ headline }}
|
|
46
|
+
{{ props.headline }}
|
|
45
47
|
</slot>
|
|
46
48
|
</div>
|
|
47
49
|
|
|
48
|
-
<h1 v-if="title || !!slots.title" data-slot="title" :class="ui.title({ class:
|
|
50
|
+
<h1 v-if="props.title || !!slots.title" data-slot="title" :class="ui.title({ class: props.ui?.title })">
|
|
49
51
|
<slot name="title">
|
|
50
|
-
{{ title }}
|
|
52
|
+
{{ props.title }}
|
|
51
53
|
</slot>
|
|
52
54
|
</h1>
|
|
53
55
|
|
|
54
|
-
<div v-if="description || !!slots.description" data-slot="description" :class="ui.description({ class:
|
|
56
|
+
<div v-if="props.description || !!slots.description" data-slot="description" :class="ui.description({ class: props.ui?.description })">
|
|
55
57
|
<slot name="description">
|
|
56
|
-
{{ description }}
|
|
58
|
+
{{ props.description }}
|
|
57
59
|
</slot>
|
|
58
60
|
</div>
|
|
59
61
|
</slot>
|
|
60
62
|
</div>
|
|
61
63
|
|
|
62
|
-
<div v-if="!!slots.body" data-slot="body" :class="ui.body({ class:
|
|
64
|
+
<div v-if="!!slots.body" data-slot="body" :class="ui.body({ class: props.ui?.body })">
|
|
63
65
|
<slot name="body" />
|
|
64
66
|
</div>
|
|
65
67
|
|
|
66
|
-
<div v-if="!!slots.footer || (links?.length || !!slots.links)" data-slot="footer" :class="ui.footer({ class:
|
|
68
|
+
<div v-if="!!slots.footer || (props.links?.length || !!slots.links)" data-slot="footer" :class="ui.footer({ class: props.ui?.footer })">
|
|
67
69
|
<slot name="footer">
|
|
68
|
-
<div v-if="links?.length || !!slots.links" data-slot="links" :class="ui.links({ class:
|
|
70
|
+
<div v-if="props.links?.length || !!slots.links" data-slot="links" :class="ui.links({ class: props.ui?.links })">
|
|
69
71
|
<slot name="links">
|
|
70
|
-
<UButton v-for="(link, index) in links" :key="index" size="xl" v-bind="link" />
|
|
72
|
+
<UButton v-for="(link, index) in props.links" :key="index" size="xl" v-bind="link" />
|
|
71
73
|
</slot>
|
|
72
74
|
</div>
|
|
73
75
|
</slot>
|
|
@@ -75,7 +77,7 @@ const ui = computed(() => tv({ extend: tv(theme), ...appConfig.ui?.pageHero || {
|
|
|
75
77
|
</div>
|
|
76
78
|
|
|
77
79
|
<slot v-if="!!slots.default" />
|
|
78
|
-
<div v-else-if="orientation === 'horizontal'" class="hidden lg:block" />
|
|
80
|
+
<div v-else-if="props.orientation === 'horizontal'" :class="prefix('hidden lg:block')" />
|
|
79
81
|
</UContainer>
|
|
80
82
|
|
|
81
83
|
<slot name="bottom" />
|
|
@@ -6,13 +6,13 @@ import theme from "#build/ui/page-links";
|
|
|
6
6
|
import { computed } from "vue";
|
|
7
7
|
import { Primitive } from "reka-ui";
|
|
8
8
|
import { useAppConfig } from "#imports";
|
|
9
|
-
import {
|
|
9
|
+
import { useComponentProps } from "../composables/useComponentProps";
|
|
10
10
|
import { pickLinkProps } from "../utils/link";
|
|
11
11
|
import { tv } from "../utils/tv";
|
|
12
12
|
import ULink from "./Link.vue";
|
|
13
13
|
import ULinkBase from "./LinkBase.vue";
|
|
14
14
|
import UIcon from "./Icon.vue";
|
|
15
|
-
const
|
|
15
|
+
const _props = defineProps({
|
|
16
16
|
as: { type: null, required: false, default: "nav" },
|
|
17
17
|
title: { type: String, required: false },
|
|
18
18
|
links: { type: Array, required: false },
|
|
@@ -20,34 +20,34 @@ const props = defineProps({
|
|
|
20
20
|
ui: { type: Object, required: false }
|
|
21
21
|
});
|
|
22
22
|
const slots = defineSlots();
|
|
23
|
+
const props = useComponentProps("pageLinks", _props);
|
|
23
24
|
const appConfig = useAppConfig();
|
|
24
|
-
const uiProp = useComponentUI("pageLinks", props);
|
|
25
25
|
const ui = computed(() => tv({ extend: tv(theme), ...appConfig.ui?.pageLinks || {} })());
|
|
26
26
|
</script>
|
|
27
27
|
|
|
28
28
|
<template>
|
|
29
|
-
<Primitive :as="as" data-slot="root" :class="ui.root({ class: [
|
|
30
|
-
<p v-if="title || !!slots.title" data-slot="title" :class="ui.title({ class:
|
|
29
|
+
<Primitive :as="props.as" data-slot="root" :class="ui.root({ class: [props.ui?.root, props.class] })">
|
|
30
|
+
<p v-if="props.title || !!slots.title" data-slot="title" :class="ui.title({ class: props.ui?.title })">
|
|
31
31
|
<slot name="title">
|
|
32
|
-
{{ title }}
|
|
32
|
+
{{ props.title }}
|
|
33
33
|
</slot>
|
|
34
34
|
</p>
|
|
35
35
|
|
|
36
|
-
<ul data-slot="list" :class="ui.list({ class:
|
|
37
|
-
<li v-for="(link, index) in links" :key="index" data-slot="item" :class="ui.item({ class: [
|
|
36
|
+
<ul data-slot="list" :class="ui.list({ class: props.ui?.list })">
|
|
37
|
+
<li v-for="(link, index) in props.links" :key="index" data-slot="item" :class="ui.item({ class: [props.ui?.item, link.ui?.item] })">
|
|
38
38
|
<ULink v-slot="{ active, ...slotProps }" v-bind="pickLinkProps(link)" custom>
|
|
39
|
-
<ULinkBase v-bind="slotProps" data-slot="link" :class="ui.link({ class: [
|
|
39
|
+
<ULinkBase v-bind="slotProps" data-slot="link" :class="ui.link({ class: [props.ui?.link, link.ui?.link, link.class], active })">
|
|
40
40
|
<slot name="link" :link="link" :active="active" :ui="ui">
|
|
41
41
|
<slot name="link-leading" :link="link" :active="active" :ui="ui">
|
|
42
|
-
<UIcon v-if="link.icon" :name="link.icon" data-slot="linkLeadingIcon" :class="ui.linkLeadingIcon({ class: [
|
|
42
|
+
<UIcon v-if="link.icon" :name="link.icon" data-slot="linkLeadingIcon" :class="ui.linkLeadingIcon({ class: [props.ui?.linkLeadingIcon, link.ui?.linkLeadingIcon], active })" />
|
|
43
43
|
</slot>
|
|
44
44
|
|
|
45
|
-
<span v-if="link.label || !!slots['link-label']" data-slot="linkLabel" :class="ui.linkLabel({ class: [
|
|
45
|
+
<span v-if="link.label || !!slots['link-label']" data-slot="linkLabel" :class="ui.linkLabel({ class: [props.ui?.linkLabel, link.ui?.linkLabel], active })">
|
|
46
46
|
<slot name="link-label" :link="link" :active="active">
|
|
47
47
|
{{ link.label }}
|
|
48
48
|
</slot>
|
|
49
49
|
|
|
50
|
-
<UIcon v-if="link.target === '_blank'" :name="appConfig.ui.icons.external" data-slot="linkLabelExternalIcon" :class="ui.linkLabelExternalIcon({ class: [
|
|
50
|
+
<UIcon v-if="link.target === '_blank'" :name="appConfig.ui.icons.external" data-slot="linkLabelExternalIcon" :class="ui.linkLabelExternalIcon({ class: [props.ui?.linkLabelExternalIcon, link.ui?.linkLabelExternalIcon], active })" />
|
|
51
51
|
</span>
|
|
52
52
|
|
|
53
53
|
<slot name="link-trailing" :link="link" :active="active" />
|
|
@@ -7,21 +7,21 @@ import { computed } from "vue";
|
|
|
7
7
|
import { Primitive } from "reka-ui";
|
|
8
8
|
import { useAppConfig } from "#imports";
|
|
9
9
|
import { tv } from "../utils/tv";
|
|
10
|
-
import {
|
|
11
|
-
const
|
|
10
|
+
import { useComponentProps } from "../composables/useComponentProps";
|
|
11
|
+
const _props = defineProps({
|
|
12
12
|
as: { type: null, required: false },
|
|
13
13
|
divide: { type: Boolean, required: false, default: false },
|
|
14
14
|
class: { type: null, required: false },
|
|
15
15
|
ui: { type: Object, required: false }
|
|
16
16
|
});
|
|
17
17
|
defineSlots();
|
|
18
|
+
const props = useComponentProps("pageList", _props);
|
|
18
19
|
const appConfig = useAppConfig();
|
|
19
|
-
const uiProp = useComponentUI("pageList", props);
|
|
20
20
|
const ui = computed(() => tv({ extend: tv(theme), ...appConfig.ui?.pageList || {} }));
|
|
21
21
|
</script>
|
|
22
22
|
|
|
23
23
|
<template>
|
|
24
|
-
<Primitive :as="as" role="list" :class="ui({ class: [
|
|
24
|
+
<Primitive :as="props.as" role="list" :class="ui({ class: [props.ui?.base, props.class], divide: props.divide })">
|
|
25
25
|
<slot />
|
|
26
26
|
</Primitive>
|
|
27
27
|
</template>
|
|
@@ -7,14 +7,14 @@ import { computed } from "vue";
|
|
|
7
7
|
import { Primitive } from "reka-ui";
|
|
8
8
|
import { createReusableTemplate } from "@vueuse/core";
|
|
9
9
|
import { useAppConfig } from "#imports";
|
|
10
|
-
import {
|
|
10
|
+
import { useComponentProps } from "../composables/useComponentProps";
|
|
11
11
|
import { tv } from "../utils/tv";
|
|
12
12
|
import UMarquee from "./Marquee.vue";
|
|
13
13
|
import UAvatar from "./Avatar.vue";
|
|
14
14
|
import UIcon from "./Icon.vue";
|
|
15
15
|
defineOptions({ inheritAttrs: false });
|
|
16
16
|
const [DefineCreateItemTemplate, ReuseCreateItemTemplate] = createReusableTemplate();
|
|
17
|
-
const
|
|
17
|
+
const _props = defineProps({
|
|
18
18
|
as: { type: null, required: false },
|
|
19
19
|
title: { type: String, required: false },
|
|
20
20
|
items: { type: Array, required: false },
|
|
@@ -23,48 +23,48 @@ const props = defineProps({
|
|
|
23
23
|
ui: { type: Object, required: false }
|
|
24
24
|
});
|
|
25
25
|
const slots = defineSlots();
|
|
26
|
+
const props = useComponentProps("pageLogos", _props);
|
|
26
27
|
const appConfig = useAppConfig();
|
|
27
|
-
const uiProp = useComponentUI("pageLogos", props);
|
|
28
28
|
const ui = computed(() => tv({ extend: tv(theme), ...appConfig.ui?.pageLogos || {} })());
|
|
29
29
|
</script>
|
|
30
30
|
|
|
31
31
|
<template>
|
|
32
32
|
<DefineCreateItemTemplate>
|
|
33
33
|
<slot v-if="!!slots.default" />
|
|
34
|
-
<template v-else-if="items?.length">
|
|
35
|
-
<template v-for="(item, index) in items" :key="index">
|
|
34
|
+
<template v-else-if="props.items?.length">
|
|
35
|
+
<template v-for="(item, index) in props.items" :key="index">
|
|
36
36
|
<UAvatar
|
|
37
37
|
v-if="typeof item === 'object'"
|
|
38
38
|
:src="item.src"
|
|
39
39
|
:alt="item.alt"
|
|
40
40
|
data-slot="logo"
|
|
41
|
-
:class="ui.logo({ class:
|
|
41
|
+
:class="ui.logo({ class: props.ui?.logo })"
|
|
42
42
|
/>
|
|
43
43
|
<UIcon
|
|
44
44
|
v-else
|
|
45
45
|
:name="item"
|
|
46
46
|
data-slot="logo"
|
|
47
|
-
:class="ui.logo({ class:
|
|
47
|
+
:class="ui.logo({ class: props.ui?.logo })"
|
|
48
48
|
/>
|
|
49
49
|
</template>
|
|
50
50
|
</template>
|
|
51
51
|
</DefineCreateItemTemplate>
|
|
52
52
|
|
|
53
|
-
<Primitive :as="as" v-bind="$attrs" data-slot="root" :class="ui.root({ class: [
|
|
54
|
-
<h2 v-if="title" data-slot="title" :class="ui.title({ class:
|
|
55
|
-
{{ title }}
|
|
53
|
+
<Primitive :as="props.as" v-bind="$attrs" data-slot="root" :class="ui.root({ class: [props.ui?.root, props.class] })">
|
|
54
|
+
<h2 v-if="props.title" data-slot="title" :class="ui.title({ class: props.ui?.title })">
|
|
55
|
+
{{ props.title }}
|
|
56
56
|
</h2>
|
|
57
57
|
|
|
58
58
|
<UMarquee
|
|
59
|
-
v-if="marquee"
|
|
60
|
-
v-bind="typeof marquee === 'object' ? marquee : {}"
|
|
59
|
+
v-if="props.marquee"
|
|
60
|
+
v-bind="typeof props.marquee === 'object' ? props.marquee : {}"
|
|
61
61
|
data-slot="logos"
|
|
62
|
-
:class="ui.logos({ class:
|
|
62
|
+
:class="ui.logos({ class: props.ui?.logos, marquee: true })"
|
|
63
63
|
>
|
|
64
|
-
<ReuseCreateItemTemplate :items="items" />
|
|
64
|
+
<ReuseCreateItemTemplate :items="props.items" />
|
|
65
65
|
</UMarquee>
|
|
66
|
-
<div v-else data-slot="logos" :class="ui.logos({ class:
|
|
67
|
-
<ReuseCreateItemTemplate :items="items" />
|
|
66
|
+
<div v-else data-slot="logos" :class="ui.logos({ class: props.ui?.logos })">
|
|
67
|
+
<ReuseCreateItemTemplate :items="props.items" />
|
|
68
68
|
</div>
|
|
69
69
|
</Primitive>
|
|
70
70
|
</template>
|
|
@@ -62,8 +62,8 @@ export interface PageSectionSlots {
|
|
|
62
62
|
declare const _default: typeof __VLS_export;
|
|
63
63
|
export default _default;
|
|
64
64
|
declare const __VLS_export: __VLS_WithSlots<import("vue").DefineComponent<PageSectionProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<PageSectionProps> & Readonly<{}>, {
|
|
65
|
-
orientation: PageSection["variants"]["orientation"];
|
|
66
65
|
as: any;
|
|
66
|
+
orientation: PageSection["variants"]["orientation"];
|
|
67
67
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, PageSectionSlots>;
|
|
68
68
|
type __VLS_WithSlots<T, S> = T & {
|
|
69
69
|
new (): {
|
|
@@ -6,13 +6,14 @@ import theme from "#build/ui/page-section";
|
|
|
6
6
|
import { computed } from "vue";
|
|
7
7
|
import { Primitive } from "reka-ui";
|
|
8
8
|
import { useAppConfig } from "#imports";
|
|
9
|
-
import {
|
|
9
|
+
import { useComponentProps } from "../composables/useComponentProps";
|
|
10
|
+
import { usePrefix } from "../composables/usePrefix";
|
|
10
11
|
import { tv } from "../utils/tv";
|
|
11
12
|
import UPageFeature from "./PageFeature.vue";
|
|
12
13
|
import UContainer from "./Container.vue";
|
|
13
14
|
import UIcon from "./Icon.vue";
|
|
14
15
|
import UButton from "./Button.vue";
|
|
15
|
-
const
|
|
16
|
+
const _props = defineProps({
|
|
16
17
|
as: { type: null, required: false, default: "section" },
|
|
17
18
|
headline: { type: String, required: false },
|
|
18
19
|
icon: { type: null, required: false },
|
|
@@ -26,8 +27,9 @@ const props = defineProps({
|
|
|
26
27
|
ui: { type: Object, required: false }
|
|
27
28
|
});
|
|
28
29
|
const slots = defineSlots();
|
|
30
|
+
const props = useComponentProps("pageSection", _props);
|
|
29
31
|
const appConfig = useAppConfig();
|
|
30
|
-
const
|
|
32
|
+
const prefix = usePrefix();
|
|
31
33
|
const ui = computed(() => tv({ extend: tv(theme), ...appConfig.ui?.pageSection || {} })({
|
|
32
34
|
orientation: props.orientation,
|
|
33
35
|
reverse: props.reverse,
|
|
@@ -38,45 +40,45 @@ const ui = computed(() => tv({ extend: tv(theme), ...appConfig.ui?.pageSection |
|
|
|
38
40
|
</script>
|
|
39
41
|
|
|
40
42
|
<template>
|
|
41
|
-
<Primitive :as="as" :data-orientation="orientation" data-slot="root" :class="ui.root({ class: [
|
|
43
|
+
<Primitive :as="props.as" :data-orientation="props.orientation" data-slot="root" :class="ui.root({ class: [props.ui?.root, props.class] })">
|
|
42
44
|
<slot name="top" />
|
|
43
45
|
|
|
44
|
-
<UContainer data-slot="container" :class="ui.container({ class:
|
|
45
|
-
<div v-if="!!slots.header || (icon || !!slots.leading) || (headline || !!slots.headline) || (title || !!slots.title) || (description || !!slots.description) || !!slots.body || (features?.length || !!slots.features) || !!slots.footer || (links?.length || !!slots.links)" data-slot="wrapper" :class="ui.wrapper({ class:
|
|
46
|
-
<div v-if="!!slots.header || (icon || !!slots.leading) || (headline || !!slots.headline) || (title || !!slots.title) || (description || !!slots.description)" data-slot="header" :class="ui.header({ class:
|
|
46
|
+
<UContainer data-slot="container" :class="ui.container({ class: props.ui?.container })">
|
|
47
|
+
<div v-if="!!slots.header || (props.icon || !!slots.leading) || (props.headline || !!slots.headline) || (props.title || !!slots.title) || (props.description || !!slots.description) || !!slots.body || (props.features?.length || !!slots.features) || !!slots.footer || (props.links?.length || !!slots.links)" data-slot="wrapper" :class="ui.wrapper({ class: props.ui?.wrapper })">
|
|
48
|
+
<div v-if="!!slots.header || (props.icon || !!slots.leading) || (props.headline || !!slots.headline) || (props.title || !!slots.title) || (props.description || !!slots.description)" data-slot="header" :class="ui.header({ class: props.ui?.header })">
|
|
47
49
|
<slot name="header">
|
|
48
|
-
<div v-if="icon || !!slots.leading" data-slot="leading" :class="ui.leading({ class:
|
|
50
|
+
<div v-if="props.icon || !!slots.leading" data-slot="leading" :class="ui.leading({ class: props.ui?.leading })">
|
|
49
51
|
<slot name="leading" :ui="ui">
|
|
50
|
-
<UIcon v-if="icon" :name="icon" data-slot="leadingIcon" :class="ui.leadingIcon({ class:
|
|
52
|
+
<UIcon v-if="props.icon" :name="props.icon" data-slot="leadingIcon" :class="ui.leadingIcon({ class: props.ui?.leadingIcon })" />
|
|
51
53
|
</slot>
|
|
52
54
|
</div>
|
|
53
55
|
|
|
54
|
-
<div v-if="headline || !!slots.headline" data-slot="headline" :class="ui.headline({ class:
|
|
56
|
+
<div v-if="props.headline || !!slots.headline" data-slot="headline" :class="ui.headline({ class: props.ui?.headline, headline: !slots.headline })">
|
|
55
57
|
<slot name="headline">
|
|
56
|
-
{{ headline }}
|
|
58
|
+
{{ props.headline }}
|
|
57
59
|
</slot>
|
|
58
60
|
</div>
|
|
59
61
|
|
|
60
|
-
<h2 v-if="title || !!slots.title" data-slot="title" :class="ui.title({ class:
|
|
62
|
+
<h2 v-if="props.title || !!slots.title" data-slot="title" :class="ui.title({ class: props.ui?.title })">
|
|
61
63
|
<slot name="title">
|
|
62
|
-
{{ title }}
|
|
64
|
+
{{ props.title }}
|
|
63
65
|
</slot>
|
|
64
66
|
</h2>
|
|
65
67
|
|
|
66
|
-
<div v-if="description || !!slots.description" data-slot="description" :class="ui.description({ class:
|
|
68
|
+
<div v-if="props.description || !!slots.description" data-slot="description" :class="ui.description({ class: props.ui?.description })">
|
|
67
69
|
<slot name="description">
|
|
68
|
-
{{ description }}
|
|
70
|
+
{{ props.description }}
|
|
69
71
|
</slot>
|
|
70
72
|
</div>
|
|
71
73
|
</slot>
|
|
72
74
|
</div>
|
|
73
75
|
|
|
74
|
-
<div v-if="!!slots.body || (features?.length || !!slots.features)" data-slot="body" :class="ui.body({ class:
|
|
76
|
+
<div v-if="!!slots.body || (props.features?.length || !!slots.features)" data-slot="body" :class="ui.body({ class: props.ui?.body })">
|
|
75
77
|
<slot name="body">
|
|
76
|
-
<ul v-if="features?.length || !!slots.features" data-slot="features" :class="ui.features({ class:
|
|
78
|
+
<ul v-if="props.features?.length || !!slots.features" data-slot="features" :class="ui.features({ class: props.ui?.features })">
|
|
77
79
|
<slot name="features">
|
|
78
80
|
<UPageFeature
|
|
79
|
-
v-for="(feature, index) in features"
|
|
81
|
+
v-for="(feature, index) in props.features"
|
|
80
82
|
:key="index"
|
|
81
83
|
as="li"
|
|
82
84
|
v-bind="feature"
|
|
@@ -86,11 +88,11 @@ const ui = computed(() => tv({ extend: tv(theme), ...appConfig.ui?.pageSection |
|
|
|
86
88
|
</slot>
|
|
87
89
|
</div>
|
|
88
90
|
|
|
89
|
-
<div v-if="!!slots.footer || (links?.length || !!slots.links)" data-slot="footer" :class="ui.footer({ class:
|
|
91
|
+
<div v-if="!!slots.footer || (props.links?.length || !!slots.links)" data-slot="footer" :class="ui.footer({ class: props.ui?.footer })">
|
|
90
92
|
<slot name="footer">
|
|
91
|
-
<div v-if="links?.length || !!slots.links" data-slot="links" :class="ui.links({ class:
|
|
93
|
+
<div v-if="props.links?.length || !!slots.links" data-slot="links" :class="ui.links({ class: props.ui?.links })">
|
|
92
94
|
<slot name="links">
|
|
93
|
-
<UButton v-for="(link, index) in links" :key="index" size="lg" v-bind="link" />
|
|
95
|
+
<UButton v-for="(link, index) in props.links" :key="index" size="lg" v-bind="link" />
|
|
94
96
|
</slot>
|
|
95
97
|
</div>
|
|
96
98
|
</slot>
|
|
@@ -98,7 +100,7 @@ const ui = computed(() => tv({ extend: tv(theme), ...appConfig.ui?.pageSection |
|
|
|
98
100
|
</div>
|
|
99
101
|
|
|
100
102
|
<slot v-if="!!slots.default" />
|
|
101
|
-
<div v-else-if="orientation === 'horizontal'" class="hidden lg:block" />
|
|
103
|
+
<div v-else-if="props.orientation === 'horizontal'" :class="prefix('hidden lg:block')" />
|
|
102
104
|
</UContainer>
|
|
103
105
|
|
|
104
106
|
<slot name="bottom" />
|
|
@@ -62,8 +62,8 @@ export interface PageSectionSlots {
|
|
|
62
62
|
declare const _default: typeof __VLS_export;
|
|
63
63
|
export default _default;
|
|
64
64
|
declare const __VLS_export: __VLS_WithSlots<import("vue").DefineComponent<PageSectionProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<PageSectionProps> & Readonly<{}>, {
|
|
65
|
-
orientation: PageSection["variants"]["orientation"];
|
|
66
65
|
as: any;
|
|
66
|
+
orientation: PageSection["variants"]["orientation"];
|
|
67
67
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, PageSectionSlots>;
|
|
68
68
|
type __VLS_WithSlots<T, S> = T & {
|
|
69
69
|
new (): {
|
|
@@ -104,9 +104,9 @@ declare const __VLS_export: __VLS_WithSlots<import("vue").DefineComponent<Pagina
|
|
|
104
104
|
}, string, import("vue").PublicProps, Readonly<PaginationProps> & Readonly<{
|
|
105
105
|
"onUpdate:page"?: ((value: number) => any) | undefined;
|
|
106
106
|
}>, {
|
|
107
|
-
color: "error" | "primary" | "secondary" | "success" | "info" | "warning"
|
|
107
|
+
color: "error" | "neutral" | "primary" | "secondary" | "success" | "info" | "warning";
|
|
108
|
+
activeColor: "error" | "neutral" | "primary" | "secondary" | "success" | "info" | "warning";
|
|
108
109
|
variant: "link" | "solid" | "outline" | "soft" | "subtle" | "ghost";
|
|
109
|
-
activeColor: "error" | "primary" | "secondary" | "success" | "info" | "warning" | "neutral";
|
|
110
110
|
activeVariant: "link" | "solid" | "outline" | "soft" | "subtle" | "ghost";
|
|
111
111
|
itemsPerPage: number;
|
|
112
112
|
showEdges: boolean;
|
|
@@ -4,14 +4,15 @@ import theme from "#build/ui/pagination";
|
|
|
4
4
|
|
|
5
5
|
<script setup>
|
|
6
6
|
import { computed } from "vue";
|
|
7
|
-
import { PaginationRoot, PaginationList, PaginationListItem, PaginationFirst, PaginationPrev, PaginationEllipsis, PaginationNext, PaginationLast
|
|
7
|
+
import { PaginationRoot, PaginationList, PaginationListItem, PaginationFirst, PaginationPrev, PaginationEllipsis, PaginationNext, PaginationLast } from "reka-ui";
|
|
8
|
+
import { useForwardProps } from "../composables/useForwardProps";
|
|
8
9
|
import { reactivePick } from "@vueuse/core";
|
|
9
10
|
import { useAppConfig } from "#imports";
|
|
10
|
-
import {
|
|
11
|
+
import { useComponentProps } from "../composables/useComponentProps";
|
|
11
12
|
import { useLocale } from "../composables/useLocale";
|
|
12
13
|
import { tv } from "../utils/tv";
|
|
13
14
|
import UButton from "./Button.vue";
|
|
14
|
-
const
|
|
15
|
+
const _props = defineProps({
|
|
15
16
|
as: { type: null, required: false },
|
|
16
17
|
firstIcon: { type: null, required: false },
|
|
17
18
|
prevIcon: { type: null, required: false },
|
|
@@ -37,10 +38,10 @@ const props = defineProps({
|
|
|
37
38
|
});
|
|
38
39
|
const emits = defineEmits(["update:page"]);
|
|
39
40
|
const slots = defineSlots();
|
|
41
|
+
const props = useComponentProps("pagination", _props);
|
|
40
42
|
const { dir } = useLocale();
|
|
41
43
|
const appConfig = useAppConfig();
|
|
42
|
-
const
|
|
43
|
-
const rootProps = useForwardPropsEmits(reactivePick(props, "as", "defaultPage", "disabled", "itemsPerPage", "page", "showEdges", "siblingCount", "total"), emits);
|
|
44
|
+
const rootProps = useForwardProps(reactivePick(props, "as", "defaultPage", "disabled", "itemsPerPage", "page", "showEdges", "siblingCount", "total"), emits);
|
|
44
45
|
const firstIcon = computed(() => props.firstIcon || (dir.value === "rtl" ? appConfig.ui.icons.chevronDoubleRight : appConfig.ui.icons.chevronDoubleLeft));
|
|
45
46
|
const prevIcon = computed(() => props.prevIcon || (dir.value === "rtl" ? appConfig.ui.icons.chevronRight : appConfig.ui.icons.chevronLeft));
|
|
46
47
|
const nextIcon = computed(() => props.nextIcon || (dir.value === "rtl" ? appConfig.ui.icons.chevronLeft : appConfig.ui.icons.chevronRight));
|
|
@@ -49,49 +50,49 @@ const ui = computed(() => tv({ extend: tv(theme), ...appConfig.ui?.pagination ||
|
|
|
49
50
|
</script>
|
|
50
51
|
|
|
51
52
|
<template>
|
|
52
|
-
<PaginationRoot v-slot="{ page, pageCount }" v-bind="rootProps" data-slot="root" :class="ui.root({ class: [
|
|
53
|
-
<PaginationList v-slot="{ items }" data-slot="list" :class="ui.list({ class:
|
|
54
|
-
<PaginationFirst v-if="showControls || !!slots.first" as-child data-slot="first" :class="ui.first({ class:
|
|
53
|
+
<PaginationRoot v-slot="{ page, pageCount }" v-bind="rootProps" data-slot="root" :class="ui.root({ class: [props.ui?.root, props.class] })">
|
|
54
|
+
<PaginationList v-slot="{ items }" data-slot="list" :class="ui.list({ class: props.ui?.list })">
|
|
55
|
+
<PaginationFirst v-if="props.showControls || !!slots.first" as-child data-slot="first" :class="ui.first({ class: props.ui?.first })">
|
|
55
56
|
<slot name="first">
|
|
56
|
-
<UButton :color="color" :variant="variant" :size="size" :icon="firstIcon" :to="to?.(1)" />
|
|
57
|
+
<UButton :color="props.color" :variant="props.variant" :size="props.size" :icon="firstIcon" :to="props.to?.(1)" />
|
|
57
58
|
</slot>
|
|
58
59
|
</PaginationFirst>
|
|
59
|
-
<PaginationPrev v-if="showControls || !!slots.prev" as-child data-slot="prev" :class="ui.prev({ class:
|
|
60
|
+
<PaginationPrev v-if="props.showControls || !!slots.prev" as-child data-slot="prev" :class="ui.prev({ class: props.ui?.prev })">
|
|
60
61
|
<slot name="prev">
|
|
61
|
-
<UButton :color="color" :variant="variant" :size="size" :icon="prevIcon" :to="page > 1 ? to?.(page - 1) : void 0" />
|
|
62
|
+
<UButton :color="props.color" :variant="props.variant" :size="props.size" :icon="prevIcon" :to="page > 1 ? props.to?.(page - 1) : void 0" />
|
|
62
63
|
</slot>
|
|
63
64
|
</PaginationPrev>
|
|
64
65
|
|
|
65
66
|
<template v-for="(item, index) in items" :key="index">
|
|
66
|
-
<PaginationListItem v-if="item.type === 'page'" as-child :value="item.value" data-slot="item" :class="ui.item({ class:
|
|
67
|
+
<PaginationListItem v-if="item.type === 'page'" as-child :value="item.value" data-slot="item" :class="ui.item({ class: props.ui?.item })">
|
|
67
68
|
<slot name="item" v-bind="{ item, index, page, pageCount }">
|
|
68
69
|
<UButton
|
|
69
|
-
:color="page === item.value ? activeColor : color"
|
|
70
|
-
:variant="page === item.value ? activeVariant : variant"
|
|
71
|
-
:size="size"
|
|
70
|
+
:color="page === item.value ? props.activeColor : props.color"
|
|
71
|
+
:variant="page === item.value ? props.activeVariant : props.variant"
|
|
72
|
+
:size="props.size"
|
|
72
73
|
:label="String(item.value)"
|
|
73
74
|
:ui="{ label: ui.label() }"
|
|
74
|
-
:to="to?.(item.value)"
|
|
75
|
+
:to="props.to?.(item.value)"
|
|
75
76
|
square
|
|
76
77
|
/>
|
|
77
78
|
</slot>
|
|
78
79
|
</PaginationListItem>
|
|
79
80
|
|
|
80
|
-
<PaginationEllipsis v-else as-child data-slot="ellipsis" :class="ui.ellipsis({ class:
|
|
81
|
+
<PaginationEllipsis v-else as-child data-slot="ellipsis" :class="ui.ellipsis({ class: props.ui?.ellipsis })">
|
|
81
82
|
<slot name="ellipsis" :ui="ui">
|
|
82
|
-
<UButton as="div" :color="color" :variant="variant" :size="size" :icon="ellipsisIcon || appConfig.ui.icons.ellipsis" />
|
|
83
|
+
<UButton as="div" :color="props.color" :variant="props.variant" :size="props.size" :icon="props.ellipsisIcon || appConfig.ui.icons.ellipsis" />
|
|
83
84
|
</slot>
|
|
84
85
|
</PaginationEllipsis>
|
|
85
86
|
</template>
|
|
86
87
|
|
|
87
|
-
<PaginationNext v-if="showControls || !!slots.next" as-child data-slot="next" :class="ui.next({ class:
|
|
88
|
+
<PaginationNext v-if="props.showControls || !!slots.next" as-child data-slot="next" :class="ui.next({ class: props.ui?.next })">
|
|
88
89
|
<slot name="next">
|
|
89
|
-
<UButton :color="color" :variant="variant" :size="size" :icon="nextIcon" :to="page < pageCount ? to?.(page + 1) : void 0" />
|
|
90
|
+
<UButton :color="props.color" :variant="props.variant" :size="props.size" :icon="nextIcon" :to="page < pageCount ? props.to?.(page + 1) : void 0" />
|
|
90
91
|
</slot>
|
|
91
92
|
</PaginationNext>
|
|
92
|
-
<PaginationLast v-if="showControls || !!slots.last" as-child data-slot="last" :class="ui.last({ class:
|
|
93
|
+
<PaginationLast v-if="props.showControls || !!slots.last" as-child data-slot="last" :class="ui.last({ class: props.ui?.last })">
|
|
93
94
|
<slot name="last">
|
|
94
|
-
<UButton :color="color" :variant="variant" :size="size" :icon="lastIcon" :to="to?.(pageCount)" />
|
|
95
|
+
<UButton :color="props.color" :variant="props.variant" :size="props.size" :icon="lastIcon" :to="props.to?.(pageCount)" />
|
|
95
96
|
</slot>
|
|
96
97
|
</PaginationLast>
|
|
97
98
|
</PaginationList>
|
|
@@ -104,9 +104,9 @@ declare const __VLS_export: __VLS_WithSlots<import("vue").DefineComponent<Pagina
|
|
|
104
104
|
}, string, import("vue").PublicProps, Readonly<PaginationProps> & Readonly<{
|
|
105
105
|
"onUpdate:page"?: ((value: number) => any) | undefined;
|
|
106
106
|
}>, {
|
|
107
|
-
color: "error" | "primary" | "secondary" | "success" | "info" | "warning"
|
|
107
|
+
color: "error" | "neutral" | "primary" | "secondary" | "success" | "info" | "warning";
|
|
108
|
+
activeColor: "error" | "neutral" | "primary" | "secondary" | "success" | "info" | "warning";
|
|
108
109
|
variant: "link" | "solid" | "outline" | "soft" | "subtle" | "ghost";
|
|
109
|
-
activeColor: "error" | "primary" | "secondary" | "success" | "info" | "warning" | "neutral";
|
|
110
110
|
activeVariant: "link" | "solid" | "outline" | "soft" | "subtle" | "ghost";
|
|
111
111
|
itemsPerPage: number;
|
|
112
112
|
showEdges: boolean;
|
|
@@ -4,14 +4,15 @@ import theme from "#build/ui/pin-input";
|
|
|
4
4
|
|
|
5
5
|
<script setup>
|
|
6
6
|
import { ref, computed, onMounted } from "vue";
|
|
7
|
-
import { PinInputInput, PinInputRoot
|
|
7
|
+
import { PinInputInput, PinInputRoot } from "reka-ui";
|
|
8
|
+
import { useForwardProps } from "../composables/useForwardProps";
|
|
8
9
|
import { reactivePick } from "@vueuse/core";
|
|
9
10
|
import { useAppConfig } from "#imports";
|
|
10
|
-
import {
|
|
11
|
+
import { useComponentProps } from "../composables/useComponentProps";
|
|
11
12
|
import { useFormField } from "../composables/useFormField";
|
|
12
13
|
import { looseToNumber } from "../utils";
|
|
13
14
|
import { tv } from "../utils/tv";
|
|
14
|
-
const
|
|
15
|
+
const _props = defineProps({
|
|
15
16
|
as: { type: null, required: false },
|
|
16
17
|
color: { type: null, required: false },
|
|
17
18
|
variant: { type: null, required: false },
|
|
@@ -35,15 +36,15 @@ const props = defineProps({
|
|
|
35
36
|
type: { type: null, required: false, default: "text" }
|
|
36
37
|
});
|
|
37
38
|
const emits = defineEmits(["update:modelValue", "complete", "change", "blur"]);
|
|
39
|
+
const props = useComponentProps("pinInput", _props);
|
|
38
40
|
const appConfig = useAppConfig();
|
|
39
|
-
const
|
|
40
|
-
const
|
|
41
|
-
const { emitFormInput, emitFormFocus, emitFormChange, emitFormBlur, size, color, id, name, highlight, disabled, ariaAttrs } = useFormField(props);
|
|
41
|
+
const rootProps = useForwardProps(reactivePick(props, "disabled", "id", "mask", "name", "otp", "required", "type"), emits);
|
|
42
|
+
const { emitFormInput, emitFormFocus, emitFormChange, emitFormBlur, size, color, id, name, highlight, disabled, ariaAttrs } = useFormField(_props);
|
|
42
43
|
const ui = computed(() => tv({ extend: tv(theme), ...appConfig.ui?.pinInput || {} })({
|
|
43
|
-
color: color.value,
|
|
44
|
+
color: color.value ?? props.color,
|
|
44
45
|
variant: props.variant,
|
|
45
|
-
size: size.value,
|
|
46
|
-
highlight: highlight.value,
|
|
46
|
+
size: size.value ?? props.size,
|
|
47
|
+
highlight: highlight.value ?? props.highlight,
|
|
47
48
|
fixed: props.fixed
|
|
48
49
|
}));
|
|
49
50
|
const inputsRef = ref([]);
|
|
@@ -82,11 +83,11 @@ defineExpose({
|
|
|
82
83
|
v-bind="{ ...rootProps, ...ariaAttrs }"
|
|
83
84
|
:id="id"
|
|
84
85
|
:name="name"
|
|
85
|
-
:placeholder="placeholder"
|
|
86
|
-
:model-value="modelValue"
|
|
87
|
-
:default-value="defaultValue"
|
|
86
|
+
:placeholder="props.placeholder"
|
|
87
|
+
:model-value="props.modelValue"
|
|
88
|
+
:default-value="props.defaultValue"
|
|
88
89
|
data-slot="root"
|
|
89
|
-
:class="ui.root({ class: [
|
|
90
|
+
:class="ui.root({ class: [props.ui?.root, props.class] })"
|
|
90
91
|
@update:model-value="emitFormInput()"
|
|
91
92
|
@complete="onComplete"
|
|
92
93
|
>
|
|
@@ -96,7 +97,7 @@ defineExpose({
|
|
|
96
97
|
:ref="(el) => setInputRef(index, el)"
|
|
97
98
|
:index="index"
|
|
98
99
|
data-slot="base"
|
|
99
|
-
:class="ui.base({ class:
|
|
100
|
+
:class="ui.base({ class: props.ui?.base })"
|
|
100
101
|
:disabled="disabled"
|
|
101
102
|
@blur="onBlur"
|
|
102
103
|
@focus="emitFormFocus"
|