@ark-ui/vue 5.29.0 → 5.30.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/dist/components/anatomy.cjs +5 -0
- package/dist/components/anatomy.d.cts +1 -0
- package/dist/components/anatomy.d.ts +1 -0
- package/dist/components/anatomy.js +1 -0
- package/dist/components/checkbox/use-checkbox-group.cjs +10 -5
- package/dist/components/checkbox/use-checkbox-group.d.cts +2 -2
- package/dist/components/checkbox/use-checkbox-group.d.ts +2 -2
- package/dist/components/checkbox/use-checkbox-group.js +10 -5
- package/dist/components/color-picker/color-picker-root.vue.d.cts +1 -1
- package/dist/components/color-picker/color-picker-root.vue.d.ts +1 -1
- package/dist/components/combobox/combobox-root.vue.d.cts +1 -1
- package/dist/components/combobox/combobox-root.vue.d.ts +1 -1
- package/dist/components/date-picker/date-picker-root.vue.cjs +6 -2
- package/dist/components/date-picker/date-picker-root.vue.d.cts +3 -2
- package/dist/components/date-picker/date-picker-root.vue.d.ts +3 -2
- package/dist/components/date-picker/date-picker-root.vue.js +6 -2
- package/dist/components/date-picker/date-picker.types.d.cts +8 -0
- package/dist/components/date-picker/date-picker.types.d.ts +8 -0
- package/dist/components/dialog/dialog-root.vue.d.cts +1 -1
- package/dist/components/dialog/dialog-root.vue.d.ts +1 -1
- package/dist/components/editable/editable-root.vue.d.cts +1 -1
- package/dist/components/editable/editable-root.vue.d.ts +1 -1
- package/dist/components/fieldset/fieldset-root.vue.cjs +4 -1
- package/dist/components/fieldset/fieldset-root.vue.js +4 -1
- package/dist/components/fieldset/use-fieldset.cjs +16 -9
- package/dist/components/fieldset/use-fieldset.d.cts +5 -0
- package/dist/components/fieldset/use-fieldset.d.ts +5 -0
- package/dist/components/fieldset/use-fieldset.js +16 -9
- package/dist/components/floating-panel/floating-panel-root.vue.d.cts +1 -2
- package/dist/components/floating-panel/floating-panel-root.vue.d.ts +1 -2
- package/dist/components/hover-card/hover-card-root.vue.d.cts +1 -1
- package/dist/components/hover-card/hover-card-root.vue.d.ts +1 -1
- package/dist/components/index.cjs +4 -0
- package/dist/components/index.js +2 -0
- package/dist/components/menu/menu-root.vue.d.cts +1 -1
- package/dist/components/menu/menu-root.vue.d.ts +1 -1
- package/dist/components/navigation-menu/index.cjs +44 -0
- package/dist/components/navigation-menu/index.d.cts +18 -0
- package/dist/components/navigation-menu/index.d.ts +18 -0
- package/dist/components/navigation-menu/index.js +18 -0
- package/dist/components/navigation-menu/navigation-menu-arrow.vue.cjs +29 -0
- package/dist/components/navigation-menu/navigation-menu-arrow.vue.d.cts +19 -0
- package/dist/components/navigation-menu/navigation-menu-arrow.vue.d.ts +19 -0
- package/dist/components/navigation-menu/navigation-menu-arrow.vue.js +25 -0
- package/dist/components/navigation-menu/navigation-menu-arrow.vue2.cjs +9 -0
- package/dist/components/navigation-menu/navigation-menu-arrow.vue2.js +5 -0
- package/dist/components/navigation-menu/navigation-menu-content.vue.cjs +57 -0
- package/dist/components/navigation-menu/navigation-menu-content.vue.d.cts +21 -0
- package/dist/components/navigation-menu/navigation-menu-content.vue.d.ts +21 -0
- package/dist/components/navigation-menu/navigation-menu-content.vue.js +53 -0
- package/dist/components/navigation-menu/navigation-menu-content.vue2.cjs +9 -0
- package/dist/components/navigation-menu/navigation-menu-content.vue2.js +5 -0
- package/dist/components/navigation-menu/navigation-menu-context.vue.cjs +18 -0
- package/dist/components/navigation-menu/navigation-menu-context.vue.d.cts +17 -0
- package/dist/components/navigation-menu/navigation-menu-context.vue.d.ts +17 -0
- package/dist/components/navigation-menu/navigation-menu-context.vue.js +14 -0
- package/dist/components/navigation-menu/navigation-menu-context.vue2.cjs +9 -0
- package/dist/components/navigation-menu/navigation-menu-context.vue2.js +5 -0
- package/dist/components/navigation-menu/navigation-menu-indicator.vue.cjs +35 -0
- package/dist/components/navigation-menu/navigation-menu-indicator.vue.d.cts +19 -0
- package/dist/components/navigation-menu/navigation-menu-indicator.vue.d.ts +19 -0
- package/dist/components/navigation-menu/navigation-menu-indicator.vue.js +31 -0
- package/dist/components/navigation-menu/navigation-menu-indicator.vue2.cjs +9 -0
- package/dist/components/navigation-menu/navigation-menu-indicator.vue2.js +5 -0
- package/dist/components/navigation-menu/navigation-menu-item-indicator.vue.cjs +34 -0
- package/dist/components/navigation-menu/navigation-menu-item-indicator.vue.d.cts +19 -0
- package/dist/components/navigation-menu/navigation-menu-item-indicator.vue.d.ts +19 -0
- package/dist/components/navigation-menu/navigation-menu-item-indicator.vue.js +30 -0
- package/dist/components/navigation-menu/navigation-menu-item-indicator.vue2.cjs +9 -0
- package/dist/components/navigation-menu/navigation-menu-item-indicator.vue2.js +5 -0
- package/dist/components/navigation-menu/navigation-menu-item.vue.cjs +35 -0
- package/dist/components/navigation-menu/navigation-menu-item.vue.d.cts +20 -0
- package/dist/components/navigation-menu/navigation-menu-item.vue.d.ts +20 -0
- package/dist/components/navigation-menu/navigation-menu-item.vue.js +31 -0
- package/dist/components/navigation-menu/navigation-menu-item.vue2.cjs +9 -0
- package/dist/components/navigation-menu/navigation-menu-item.vue2.js +5 -0
- package/dist/components/navigation-menu/navigation-menu-link.vue.cjs +38 -0
- package/dist/components/navigation-menu/navigation-menu-link.vue.d.cts +20 -0
- package/dist/components/navigation-menu/navigation-menu-link.vue.d.ts +20 -0
- package/dist/components/navigation-menu/navigation-menu-link.vue.js +34 -0
- package/dist/components/navigation-menu/navigation-menu-link.vue2.cjs +9 -0
- package/dist/components/navigation-menu/navigation-menu-link.vue2.js +5 -0
- package/dist/components/navigation-menu/navigation-menu-list.vue.cjs +29 -0
- package/dist/components/navigation-menu/navigation-menu-list.vue.d.cts +19 -0
- package/dist/components/navigation-menu/navigation-menu-list.vue.d.ts +19 -0
- package/dist/components/navigation-menu/navigation-menu-list.vue.js +25 -0
- package/dist/components/navigation-menu/navigation-menu-list.vue2.cjs +9 -0
- package/dist/components/navigation-menu/navigation-menu-list.vue2.js +5 -0
- package/dist/components/navigation-menu/navigation-menu-root-provider.vue.cjs +35 -0
- package/dist/components/navigation-menu/navigation-menu-root-provider.vue.d.cts +19 -0
- package/dist/components/navigation-menu/navigation-menu-root-provider.vue.d.ts +19 -0
- package/dist/components/navigation-menu/navigation-menu-root-provider.vue.js +31 -0
- package/dist/components/navigation-menu/navigation-menu-root-provider.vue2.cjs +9 -0
- package/dist/components/navigation-menu/navigation-menu-root-provider.vue2.js +5 -0
- package/dist/components/navigation-menu/navigation-menu-root.vue.cjs +51 -0
- package/dist/components/navigation-menu/navigation-menu-root.vue.d.cts +29 -0
- package/dist/components/navigation-menu/navigation-menu-root.vue.d.ts +29 -0
- package/dist/components/navigation-menu/navigation-menu-root.vue.js +47 -0
- package/dist/components/navigation-menu/navigation-menu-root.vue2.cjs +9 -0
- package/dist/components/navigation-menu/navigation-menu-root.vue2.js +5 -0
- package/dist/components/navigation-menu/navigation-menu-trigger.vue.cjs +40 -0
- package/dist/components/navigation-menu/navigation-menu-trigger.vue.d.cts +20 -0
- package/dist/components/navigation-menu/navigation-menu-trigger.vue.d.ts +20 -0
- package/dist/components/navigation-menu/navigation-menu-trigger.vue.js +36 -0
- package/dist/components/navigation-menu/navigation-menu-trigger.vue2.cjs +9 -0
- package/dist/components/navigation-menu/navigation-menu-trigger.vue2.js +5 -0
- package/dist/components/navigation-menu/navigation-menu-viewport-positioner.vue.cjs +31 -0
- package/dist/components/navigation-menu/navigation-menu-viewport-positioner.vue.d.cts +20 -0
- package/dist/components/navigation-menu/navigation-menu-viewport-positioner.vue.d.ts +20 -0
- package/dist/components/navigation-menu/navigation-menu-viewport-positioner.vue.js +27 -0
- package/dist/components/navigation-menu/navigation-menu-viewport-positioner.vue2.cjs +9 -0
- package/dist/components/navigation-menu/navigation-menu-viewport-positioner.vue2.js +5 -0
- package/dist/components/navigation-menu/navigation-menu-viewport.vue.cjs +39 -0
- package/dist/components/navigation-menu/navigation-menu-viewport.vue.d.cts +20 -0
- package/dist/components/navigation-menu/navigation-menu-viewport.vue.d.ts +20 -0
- package/dist/components/navigation-menu/navigation-menu-viewport.vue.js +35 -0
- package/dist/components/navigation-menu/navigation-menu-viewport.vue2.cjs +9 -0
- package/dist/components/navigation-menu/navigation-menu-viewport.vue2.js +5 -0
- package/dist/components/navigation-menu/navigation-menu.anatomy.d.cts +1 -0
- package/dist/components/navigation-menu/navigation-menu.anatomy.d.ts +1 -0
- package/dist/components/navigation-menu/navigation-menu.cjs +33 -0
- package/dist/components/navigation-menu/navigation-menu.d.cts +14 -0
- package/dist/components/navigation-menu/navigation-menu.d.ts +14 -0
- package/dist/components/navigation-menu/navigation-menu.js +13 -0
- package/dist/components/navigation-menu/navigation-menu.types.d.cts +64 -0
- package/dist/components/navigation-menu/navigation-menu.types.d.ts +64 -0
- package/dist/components/navigation-menu/use-navigation-menu-context.cjs +10 -0
- package/dist/components/navigation-menu/use-navigation-menu-context.d.cts +4 -0
- package/dist/components/navigation-menu/use-navigation-menu-context.d.ts +4 -0
- package/dist/components/navigation-menu/use-navigation-menu-context.js +5 -0
- package/dist/components/navigation-menu/use-navigation-menu-item-props-context.cjs +10 -0
- package/dist/components/navigation-menu/use-navigation-menu-item-props-context.d.cts +3 -0
- package/dist/components/navigation-menu/use-navigation-menu-item-props-context.d.ts +3 -0
- package/dist/components/navigation-menu/use-navigation-menu-item-props-context.js +5 -0
- package/dist/components/navigation-menu/use-navigation-menu.cjs +53 -0
- package/dist/components/navigation-menu/use-navigation-menu.d.cts +10 -0
- package/dist/components/navigation-menu/use-navigation-menu.d.ts +10 -0
- package/dist/components/navigation-menu/use-navigation-menu.js +30 -0
- package/dist/components/pagination/index.cjs +4 -0
- package/dist/components/pagination/index.d.cts +2 -0
- package/dist/components/pagination/index.d.ts +2 -0
- package/dist/components/pagination/index.js +2 -0
- package/dist/components/pagination/pagination-first-trigger.vue.cjs +29 -0
- package/dist/components/pagination/pagination-first-trigger.vue.d.cts +19 -0
- package/dist/components/pagination/pagination-first-trigger.vue.d.ts +19 -0
- package/dist/components/pagination/pagination-first-trigger.vue.js +25 -0
- package/dist/components/pagination/pagination-first-trigger.vue2.cjs +9 -0
- package/dist/components/pagination/pagination-first-trigger.vue2.js +5 -0
- package/dist/components/pagination/pagination-last-trigger.vue.cjs +29 -0
- package/dist/components/pagination/pagination-last-trigger.vue.d.cts +19 -0
- package/dist/components/pagination/pagination-last-trigger.vue.d.ts +19 -0
- package/dist/components/pagination/pagination-last-trigger.vue.js +25 -0
- package/dist/components/pagination/pagination-last-trigger.vue2.cjs +9 -0
- package/dist/components/pagination/pagination-last-trigger.vue2.js +5 -0
- package/dist/components/pagination/pagination.cjs +4 -0
- package/dist/components/pagination/pagination.d.cts +2 -0
- package/dist/components/pagination/pagination.d.ts +2 -0
- package/dist/components/pagination/pagination.js +2 -0
- package/dist/components/popover/popover-root.vue.d.cts +1 -1
- package/dist/components/popover/popover-root.vue.d.ts +1 -1
- package/dist/components/radio-group/radio-group-root.vue.cjs +5 -1
- package/dist/components/radio-group/radio-group-root.vue.d.cts +2 -0
- package/dist/components/radio-group/radio-group-root.vue.d.ts +2 -0
- package/dist/components/radio-group/radio-group-root.vue.js +5 -1
- package/dist/components/radio-group/radio-group.types.d.cts +8 -0
- package/dist/components/radio-group/radio-group.types.d.ts +8 -0
- package/dist/components/radio-group/use-radio-group.cjs +9 -0
- package/dist/components/radio-group/use-radio-group.js +9 -0
- package/dist/components/select/select-root.vue.d.cts +1 -1
- package/dist/components/select/select-root.vue.d.ts +1 -1
- package/dist/components/tags-input/tags-input-root.vue.d.cts +1 -1
- package/dist/components/tags-input/tags-input-root.vue.d.ts +1 -1
- package/dist/index.cjs +4 -0
- package/dist/index.js +2 -0
- package/dist/utils/boolean.cjs +9 -0
- package/dist/utils/boolean.d.cts +2 -0
- package/dist/utils/boolean.d.ts +2 -0
- package/dist/utils/boolean.js +5 -0
- package/package.json +72 -71
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: 'Module' } });
|
|
4
|
+
|
|
5
|
+
const vue = require('vue');
|
|
6
|
+
const vue$1 = require('@zag-js/vue');
|
|
7
|
+
const useForwardExpose = require('../../utils/use-forward-expose.cjs');
|
|
8
|
+
const factory = require('../factory.cjs');
|
|
9
|
+
const useNavigationMenuContext = require('./use-navigation-menu-context.cjs');
|
|
10
|
+
const useNavigationMenuItemPropsContext = require('./use-navigation-menu-item-props-context.cjs');
|
|
11
|
+
|
|
12
|
+
const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
13
|
+
__name: "navigation-menu-item-indicator",
|
|
14
|
+
props: {
|
|
15
|
+
asChild: { type: Boolean }
|
|
16
|
+
},
|
|
17
|
+
setup(__props) {
|
|
18
|
+
const attrs = vue.useAttrs();
|
|
19
|
+
const api = useNavigationMenuContext.useNavigationMenuContext();
|
|
20
|
+
const itemProps = useNavigationMenuItemPropsContext.useNavigationMenuItemPropsContext();
|
|
21
|
+
const mergedProps = vue.computed(() => vue$1.mergeProps({ ...attrs }, api.value.getItemIndicatorProps(itemProps?.value)));
|
|
22
|
+
useForwardExpose.useForwardExpose();
|
|
23
|
+
return (_ctx, _cache) => {
|
|
24
|
+
return vue.openBlock(), vue.createBlock(vue.unref(factory.ark).div, vue.mergeProps(mergedProps.value, { "as-child": __props.asChild }), {
|
|
25
|
+
default: vue.withCtx(() => [
|
|
26
|
+
vue.renderSlot(_ctx.$slots, "default")
|
|
27
|
+
]),
|
|
28
|
+
_: 3
|
|
29
|
+
}, 16, ["as-child"]);
|
|
30
|
+
};
|
|
31
|
+
}
|
|
32
|
+
});
|
|
33
|
+
|
|
34
|
+
exports.default = _sfc_main;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { HTMLAttributes, DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
|
|
2
|
+
import { PolymorphicProps } from '../factory';
|
|
3
|
+
export interface NavigationMenuItemIndicatorBaseProps extends PolymorphicProps {
|
|
4
|
+
}
|
|
5
|
+
export interface NavigationMenuItemIndicatorProps extends NavigationMenuItemIndicatorBaseProps,
|
|
6
|
+
/**
|
|
7
|
+
* @vue-ignore
|
|
8
|
+
*/
|
|
9
|
+
HTMLAttributes {
|
|
10
|
+
}
|
|
11
|
+
declare const _default: __VLS_WithTemplateSlots< DefineComponent<NavigationMenuItemIndicatorProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<NavigationMenuItemIndicatorProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>, {
|
|
12
|
+
default?(_: {}): any;
|
|
13
|
+
}>;
|
|
14
|
+
export default _default;
|
|
15
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
16
|
+
new (): {
|
|
17
|
+
$slots: S;
|
|
18
|
+
};
|
|
19
|
+
};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { HTMLAttributes, DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
|
|
2
|
+
import { PolymorphicProps } from '../factory';
|
|
3
|
+
export interface NavigationMenuItemIndicatorBaseProps extends PolymorphicProps {
|
|
4
|
+
}
|
|
5
|
+
export interface NavigationMenuItemIndicatorProps extends NavigationMenuItemIndicatorBaseProps,
|
|
6
|
+
/**
|
|
7
|
+
* @vue-ignore
|
|
8
|
+
*/
|
|
9
|
+
HTMLAttributes {
|
|
10
|
+
}
|
|
11
|
+
declare const _default: __VLS_WithTemplateSlots< DefineComponent<NavigationMenuItemIndicatorProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<NavigationMenuItemIndicatorProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>, {
|
|
12
|
+
default?(_: {}): any;
|
|
13
|
+
}>;
|
|
14
|
+
export default _default;
|
|
15
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
16
|
+
new (): {
|
|
17
|
+
$slots: S;
|
|
18
|
+
};
|
|
19
|
+
};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { defineComponent, useAttrs, computed, createBlock, openBlock, unref, mergeProps as mergeProps$1, withCtx, renderSlot } from 'vue';
|
|
2
|
+
import { mergeProps } from '@zag-js/vue';
|
|
3
|
+
import { useForwardExpose } from '../../utils/use-forward-expose.js';
|
|
4
|
+
import { ark } from '../factory.js';
|
|
5
|
+
import { useNavigationMenuContext } from './use-navigation-menu-context.js';
|
|
6
|
+
import { useNavigationMenuItemPropsContext } from './use-navigation-menu-item-props-context.js';
|
|
7
|
+
|
|
8
|
+
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
9
|
+
__name: "navigation-menu-item-indicator",
|
|
10
|
+
props: {
|
|
11
|
+
asChild: { type: Boolean }
|
|
12
|
+
},
|
|
13
|
+
setup(__props) {
|
|
14
|
+
const attrs = useAttrs();
|
|
15
|
+
const api = useNavigationMenuContext();
|
|
16
|
+
const itemProps = useNavigationMenuItemPropsContext();
|
|
17
|
+
const mergedProps = computed(() => mergeProps({ ...attrs }, api.value.getItemIndicatorProps(itemProps?.value)));
|
|
18
|
+
useForwardExpose();
|
|
19
|
+
return (_ctx, _cache) => {
|
|
20
|
+
return openBlock(), createBlock(unref(ark).div, mergeProps$1(mergedProps.value, { "as-child": __props.asChild }), {
|
|
21
|
+
default: withCtx(() => [
|
|
22
|
+
renderSlot(_ctx.$slots, "default")
|
|
23
|
+
]),
|
|
24
|
+
_: 3
|
|
25
|
+
}, 16, ["as-child"]);
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
});
|
|
29
|
+
|
|
30
|
+
export { _sfc_main as default };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: 'Module' } });
|
|
4
|
+
|
|
5
|
+
const navigationMenuItemIndicator_vue_vue_type_script_setup_true_lang = require('./navigation-menu-item-indicator.vue.cjs');
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
exports.default = navigationMenuItemIndicator_vue_vue_type_script_setup_true_lang.default;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: 'Module' } });
|
|
4
|
+
|
|
5
|
+
const vue = require('vue');
|
|
6
|
+
const factory = require('../factory.cjs');
|
|
7
|
+
const useNavigationMenuContext = require('./use-navigation-menu-context.cjs');
|
|
8
|
+
const useNavigationMenuItemPropsContext = require('./use-navigation-menu-item-props-context.cjs');
|
|
9
|
+
const useForwardExpose = require('../../utils/use-forward-expose.cjs');
|
|
10
|
+
|
|
11
|
+
const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
12
|
+
__name: "navigation-menu-item",
|
|
13
|
+
props: {
|
|
14
|
+
value: {},
|
|
15
|
+
disabled: { type: Boolean },
|
|
16
|
+
asChild: { type: Boolean }
|
|
17
|
+
},
|
|
18
|
+
setup(__props) {
|
|
19
|
+
const props = __props;
|
|
20
|
+
const navigationMenu = useNavigationMenuContext.useNavigationMenuContext();
|
|
21
|
+
const itemProps = vue.computed(() => ({ value: props.value, disabled: props.disabled }));
|
|
22
|
+
useNavigationMenuItemPropsContext.NavigationMenuItemPropsProvider(itemProps);
|
|
23
|
+
useForwardExpose.useForwardExpose();
|
|
24
|
+
return (_ctx, _cache) => {
|
|
25
|
+
return vue.openBlock(), vue.createBlock(vue.unref(factory.ark).div, vue.mergeProps(vue.unref(navigationMenu).getItemProps(props), { "as-child": __props.asChild }), {
|
|
26
|
+
default: vue.withCtx(() => [
|
|
27
|
+
vue.renderSlot(_ctx.$slots, "default")
|
|
28
|
+
]),
|
|
29
|
+
_: 3
|
|
30
|
+
}, 16, ["as-child"]);
|
|
31
|
+
};
|
|
32
|
+
}
|
|
33
|
+
});
|
|
34
|
+
|
|
35
|
+
exports.default = _sfc_main;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { ItemProps } from '@zag-js/navigation-menu';
|
|
2
|
+
import { HTMLAttributes, DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
|
|
3
|
+
import { PolymorphicProps } from '../factory';
|
|
4
|
+
export interface NavigationMenuItemBaseProps extends ItemProps, PolymorphicProps {
|
|
5
|
+
}
|
|
6
|
+
export interface NavigationMenuItemProps extends NavigationMenuItemBaseProps,
|
|
7
|
+
/**
|
|
8
|
+
* @vue-ignore
|
|
9
|
+
*/
|
|
10
|
+
HTMLAttributes {
|
|
11
|
+
}
|
|
12
|
+
declare const _default: __VLS_WithTemplateSlots< DefineComponent<NavigationMenuItemProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<NavigationMenuItemProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>, {
|
|
13
|
+
default?(_: {}): any;
|
|
14
|
+
}>;
|
|
15
|
+
export default _default;
|
|
16
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
17
|
+
new (): {
|
|
18
|
+
$slots: S;
|
|
19
|
+
};
|
|
20
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { ItemProps } from '@zag-js/navigation-menu';
|
|
2
|
+
import { HTMLAttributes, DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
|
|
3
|
+
import { PolymorphicProps } from '../factory';
|
|
4
|
+
export interface NavigationMenuItemBaseProps extends ItemProps, PolymorphicProps {
|
|
5
|
+
}
|
|
6
|
+
export interface NavigationMenuItemProps extends NavigationMenuItemBaseProps,
|
|
7
|
+
/**
|
|
8
|
+
* @vue-ignore
|
|
9
|
+
*/
|
|
10
|
+
HTMLAttributes {
|
|
11
|
+
}
|
|
12
|
+
declare const _default: __VLS_WithTemplateSlots< DefineComponent<NavigationMenuItemProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<NavigationMenuItemProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>, {
|
|
13
|
+
default?(_: {}): any;
|
|
14
|
+
}>;
|
|
15
|
+
export default _default;
|
|
16
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
17
|
+
new (): {
|
|
18
|
+
$slots: S;
|
|
19
|
+
};
|
|
20
|
+
};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { defineComponent, computed, createBlock, openBlock, unref, mergeProps, withCtx, renderSlot } from 'vue';
|
|
2
|
+
import { ark } from '../factory.js';
|
|
3
|
+
import { useNavigationMenuContext } from './use-navigation-menu-context.js';
|
|
4
|
+
import { NavigationMenuItemPropsProvider } from './use-navigation-menu-item-props-context.js';
|
|
5
|
+
import { useForwardExpose } from '../../utils/use-forward-expose.js';
|
|
6
|
+
|
|
7
|
+
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
8
|
+
__name: "navigation-menu-item",
|
|
9
|
+
props: {
|
|
10
|
+
value: {},
|
|
11
|
+
disabled: { type: Boolean },
|
|
12
|
+
asChild: { type: Boolean }
|
|
13
|
+
},
|
|
14
|
+
setup(__props) {
|
|
15
|
+
const props = __props;
|
|
16
|
+
const navigationMenu = useNavigationMenuContext();
|
|
17
|
+
const itemProps = computed(() => ({ value: props.value, disabled: props.disabled }));
|
|
18
|
+
NavigationMenuItemPropsProvider(itemProps);
|
|
19
|
+
useForwardExpose();
|
|
20
|
+
return (_ctx, _cache) => {
|
|
21
|
+
return openBlock(), createBlock(unref(ark).div, mergeProps(unref(navigationMenu).getItemProps(props), { "as-child": __props.asChild }), {
|
|
22
|
+
default: withCtx(() => [
|
|
23
|
+
renderSlot(_ctx.$slots, "default")
|
|
24
|
+
]),
|
|
25
|
+
_: 3
|
|
26
|
+
}, 16, ["as-child"]);
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
});
|
|
30
|
+
|
|
31
|
+
export { _sfc_main as default };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: 'Module' } });
|
|
4
|
+
|
|
5
|
+
const navigationMenuItem_vue_vue_type_script_setup_true_lang = require('./navigation-menu-item.vue.cjs');
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
exports.default = navigationMenuItem_vue_vue_type_script_setup_true_lang.default;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: 'Module' } });
|
|
4
|
+
|
|
5
|
+
const vue = require('vue');
|
|
6
|
+
const factory = require('../factory.cjs');
|
|
7
|
+
const useNavigationMenuContext = require('./use-navigation-menu-context.cjs');
|
|
8
|
+
const useNavigationMenuItemPropsContext = require('./use-navigation-menu-item-props-context.cjs');
|
|
9
|
+
const useForwardExpose = require('../../utils/use-forward-expose.cjs');
|
|
10
|
+
|
|
11
|
+
const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
12
|
+
__name: "navigation-menu-link",
|
|
13
|
+
props: {
|
|
14
|
+
value: {},
|
|
15
|
+
current: { type: Boolean },
|
|
16
|
+
onSelect: { type: Function },
|
|
17
|
+
closeOnClick: { type: Boolean },
|
|
18
|
+
asChild: { type: Boolean }
|
|
19
|
+
},
|
|
20
|
+
setup(__props) {
|
|
21
|
+
const props = __props;
|
|
22
|
+
const navigationMenu = useNavigationMenuContext.useNavigationMenuContext();
|
|
23
|
+
const itemContext = useNavigationMenuItemPropsContext.useNavigationMenuItemPropsContext();
|
|
24
|
+
const value = vue.computed(() => props.value ?? itemContext?.value?.value);
|
|
25
|
+
const linkProps = vue.computed(() => ({ ...props, value: value.value }));
|
|
26
|
+
useForwardExpose.useForwardExpose();
|
|
27
|
+
return (_ctx, _cache) => {
|
|
28
|
+
return vue.openBlock(), vue.createBlock(vue.unref(factory.ark).a, vue.mergeProps(vue.unref(navigationMenu).getLinkProps(linkProps.value), { "as-child": __props.asChild }), {
|
|
29
|
+
default: vue.withCtx(() => [
|
|
30
|
+
vue.renderSlot(_ctx.$slots, "default")
|
|
31
|
+
]),
|
|
32
|
+
_: 3
|
|
33
|
+
}, 16, ["as-child"]);
|
|
34
|
+
};
|
|
35
|
+
}
|
|
36
|
+
});
|
|
37
|
+
|
|
38
|
+
exports.default = _sfc_main;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { LinkProps } from '@zag-js/navigation-menu';
|
|
2
|
+
import { AnchorHTMLAttributes, DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
|
|
3
|
+
import { PolymorphicProps } from '../factory';
|
|
4
|
+
export interface NavigationMenuLinkBaseProps extends Partial<LinkProps>, PolymorphicProps {
|
|
5
|
+
}
|
|
6
|
+
export interface NavigationMenuLinkProps extends NavigationMenuLinkBaseProps,
|
|
7
|
+
/**
|
|
8
|
+
* @vue-ignore
|
|
9
|
+
*/
|
|
10
|
+
Omit<AnchorHTMLAttributes, 'current' | 'onSelect'> {
|
|
11
|
+
}
|
|
12
|
+
declare const _default: __VLS_WithTemplateSlots< DefineComponent<NavigationMenuLinkProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<NavigationMenuLinkProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>, {
|
|
13
|
+
default?(_: {}): any;
|
|
14
|
+
}>;
|
|
15
|
+
export default _default;
|
|
16
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
17
|
+
new (): {
|
|
18
|
+
$slots: S;
|
|
19
|
+
};
|
|
20
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { LinkProps } from '@zag-js/navigation-menu';
|
|
2
|
+
import { AnchorHTMLAttributes, DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
|
|
3
|
+
import { PolymorphicProps } from '../factory';
|
|
4
|
+
export interface NavigationMenuLinkBaseProps extends Partial<LinkProps>, PolymorphicProps {
|
|
5
|
+
}
|
|
6
|
+
export interface NavigationMenuLinkProps extends NavigationMenuLinkBaseProps,
|
|
7
|
+
/**
|
|
8
|
+
* @vue-ignore
|
|
9
|
+
*/
|
|
10
|
+
Omit<AnchorHTMLAttributes, 'current' | 'onSelect'> {
|
|
11
|
+
}
|
|
12
|
+
declare const _default: __VLS_WithTemplateSlots< DefineComponent<NavigationMenuLinkProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<NavigationMenuLinkProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>, {
|
|
13
|
+
default?(_: {}): any;
|
|
14
|
+
}>;
|
|
15
|
+
export default _default;
|
|
16
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
17
|
+
new (): {
|
|
18
|
+
$slots: S;
|
|
19
|
+
};
|
|
20
|
+
};
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { defineComponent, computed, createBlock, openBlock, unref, mergeProps, withCtx, renderSlot } from 'vue';
|
|
2
|
+
import { ark } from '../factory.js';
|
|
3
|
+
import { useNavigationMenuContext } from './use-navigation-menu-context.js';
|
|
4
|
+
import { useNavigationMenuItemPropsContext } from './use-navigation-menu-item-props-context.js';
|
|
5
|
+
import { useForwardExpose } from '../../utils/use-forward-expose.js';
|
|
6
|
+
|
|
7
|
+
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
8
|
+
__name: "navigation-menu-link",
|
|
9
|
+
props: {
|
|
10
|
+
value: {},
|
|
11
|
+
current: { type: Boolean },
|
|
12
|
+
onSelect: { type: Function },
|
|
13
|
+
closeOnClick: { type: Boolean },
|
|
14
|
+
asChild: { type: Boolean }
|
|
15
|
+
},
|
|
16
|
+
setup(__props) {
|
|
17
|
+
const props = __props;
|
|
18
|
+
const navigationMenu = useNavigationMenuContext();
|
|
19
|
+
const itemContext = useNavigationMenuItemPropsContext();
|
|
20
|
+
const value = computed(() => props.value ?? itemContext?.value?.value);
|
|
21
|
+
const linkProps = computed(() => ({ ...props, value: value.value }));
|
|
22
|
+
useForwardExpose();
|
|
23
|
+
return (_ctx, _cache) => {
|
|
24
|
+
return openBlock(), createBlock(unref(ark).a, mergeProps(unref(navigationMenu).getLinkProps(linkProps.value), { "as-child": __props.asChild }), {
|
|
25
|
+
default: withCtx(() => [
|
|
26
|
+
renderSlot(_ctx.$slots, "default")
|
|
27
|
+
]),
|
|
28
|
+
_: 3
|
|
29
|
+
}, 16, ["as-child"]);
|
|
30
|
+
};
|
|
31
|
+
}
|
|
32
|
+
});
|
|
33
|
+
|
|
34
|
+
export { _sfc_main as default };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: 'Module' } });
|
|
4
|
+
|
|
5
|
+
const navigationMenuLink_vue_vue_type_script_setup_true_lang = require('./navigation-menu-link.vue.cjs');
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
exports.default = navigationMenuLink_vue_vue_type_script_setup_true_lang.default;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: 'Module' } });
|
|
4
|
+
|
|
5
|
+
const vue = require('vue');
|
|
6
|
+
const factory = require('../factory.cjs');
|
|
7
|
+
const useNavigationMenuContext = require('./use-navigation-menu-context.cjs');
|
|
8
|
+
const useForwardExpose = require('../../utils/use-forward-expose.cjs');
|
|
9
|
+
|
|
10
|
+
const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
11
|
+
__name: "navigation-menu-list",
|
|
12
|
+
props: {
|
|
13
|
+
asChild: { type: Boolean }
|
|
14
|
+
},
|
|
15
|
+
setup(__props) {
|
|
16
|
+
const navigationMenu = useNavigationMenuContext.useNavigationMenuContext();
|
|
17
|
+
useForwardExpose.useForwardExpose();
|
|
18
|
+
return (_ctx, _cache) => {
|
|
19
|
+
return vue.openBlock(), vue.createBlock(vue.unref(factory.ark).div, vue.mergeProps(vue.unref(navigationMenu).getListProps(), { "as-child": __props.asChild }), {
|
|
20
|
+
default: vue.withCtx(() => [
|
|
21
|
+
vue.renderSlot(_ctx.$slots, "default")
|
|
22
|
+
]),
|
|
23
|
+
_: 3
|
|
24
|
+
}, 16, ["as-child"]);
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
});
|
|
28
|
+
|
|
29
|
+
exports.default = _sfc_main;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { HTMLAttributes, DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
|
|
2
|
+
import { PolymorphicProps } from '../factory';
|
|
3
|
+
export interface NavigationMenuListBaseProps extends PolymorphicProps {
|
|
4
|
+
}
|
|
5
|
+
export interface NavigationMenuListProps extends NavigationMenuListBaseProps,
|
|
6
|
+
/**
|
|
7
|
+
* @vue-ignore
|
|
8
|
+
*/
|
|
9
|
+
HTMLAttributes {
|
|
10
|
+
}
|
|
11
|
+
declare const _default: __VLS_WithTemplateSlots< DefineComponent<NavigationMenuListProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<NavigationMenuListProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>, {
|
|
12
|
+
default?(_: {}): any;
|
|
13
|
+
}>;
|
|
14
|
+
export default _default;
|
|
15
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
16
|
+
new (): {
|
|
17
|
+
$slots: S;
|
|
18
|
+
};
|
|
19
|
+
};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { HTMLAttributes, DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
|
|
2
|
+
import { PolymorphicProps } from '../factory';
|
|
3
|
+
export interface NavigationMenuListBaseProps extends PolymorphicProps {
|
|
4
|
+
}
|
|
5
|
+
export interface NavigationMenuListProps extends NavigationMenuListBaseProps,
|
|
6
|
+
/**
|
|
7
|
+
* @vue-ignore
|
|
8
|
+
*/
|
|
9
|
+
HTMLAttributes {
|
|
10
|
+
}
|
|
11
|
+
declare const _default: __VLS_WithTemplateSlots< DefineComponent<NavigationMenuListProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<NavigationMenuListProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>, {
|
|
12
|
+
default?(_: {}): any;
|
|
13
|
+
}>;
|
|
14
|
+
export default _default;
|
|
15
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
16
|
+
new (): {
|
|
17
|
+
$slots: S;
|
|
18
|
+
};
|
|
19
|
+
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { defineComponent, createBlock, openBlock, unref, mergeProps, withCtx, renderSlot } from 'vue';
|
|
2
|
+
import { ark } from '../factory.js';
|
|
3
|
+
import { useNavigationMenuContext } from './use-navigation-menu-context.js';
|
|
4
|
+
import { useForwardExpose } from '../../utils/use-forward-expose.js';
|
|
5
|
+
|
|
6
|
+
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
7
|
+
__name: "navigation-menu-list",
|
|
8
|
+
props: {
|
|
9
|
+
asChild: { type: Boolean }
|
|
10
|
+
},
|
|
11
|
+
setup(__props) {
|
|
12
|
+
const navigationMenu = useNavigationMenuContext();
|
|
13
|
+
useForwardExpose();
|
|
14
|
+
return (_ctx, _cache) => {
|
|
15
|
+
return openBlock(), createBlock(unref(ark).div, mergeProps(unref(navigationMenu).getListProps(), { "as-child": __props.asChild }), {
|
|
16
|
+
default: withCtx(() => [
|
|
17
|
+
renderSlot(_ctx.$slots, "default")
|
|
18
|
+
]),
|
|
19
|
+
_: 3
|
|
20
|
+
}, 16, ["as-child"]);
|
|
21
|
+
};
|
|
22
|
+
}
|
|
23
|
+
});
|
|
24
|
+
|
|
25
|
+
export { _sfc_main as default };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: 'Module' } });
|
|
4
|
+
|
|
5
|
+
const navigationMenuList_vue_vue_type_script_setup_true_lang = require('./navigation-menu-list.vue.cjs');
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
exports.default = navigationMenuList_vue_vue_type_script_setup_true_lang.default;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: 'Module' } });
|
|
4
|
+
|
|
5
|
+
const vue = require('vue');
|
|
6
|
+
const useRenderStrategy = require('../../utils/use-render-strategy.cjs');
|
|
7
|
+
const useForwardExpose = require('../../utils/use-forward-expose.cjs');
|
|
8
|
+
const factory = require('../factory.cjs');
|
|
9
|
+
const useNavigationMenuContext = require('./use-navigation-menu-context.cjs');
|
|
10
|
+
|
|
11
|
+
const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
12
|
+
__name: "navigation-menu-root-provider",
|
|
13
|
+
props: {
|
|
14
|
+
value: {},
|
|
15
|
+
lazyMount: { type: Boolean },
|
|
16
|
+
unmountOnExit: { type: Boolean }
|
|
17
|
+
},
|
|
18
|
+
setup(__props) {
|
|
19
|
+
const props = __props;
|
|
20
|
+
const navigationMenu = vue.computed(() => props.value);
|
|
21
|
+
useNavigationMenuContext.NavigationMenuProvider(navigationMenu);
|
|
22
|
+
useRenderStrategy.RenderStrategyPropsProvider(vue.computed(() => ({ lazyMount: props.lazyMount, unmountOnExit: props.unmountOnExit })));
|
|
23
|
+
useForwardExpose.useForwardExpose();
|
|
24
|
+
return (_ctx, _cache) => {
|
|
25
|
+
return vue.openBlock(), vue.createBlock(vue.unref(factory.ark).nav, vue.normalizeProps(vue.guardReactiveProps(navigationMenu.value.getRootProps())), {
|
|
26
|
+
default: vue.withCtx(() => [
|
|
27
|
+
vue.renderSlot(_ctx.$slots, "default")
|
|
28
|
+
]),
|
|
29
|
+
_: 3
|
|
30
|
+
}, 16);
|
|
31
|
+
};
|
|
32
|
+
}
|
|
33
|
+
});
|
|
34
|
+
|
|
35
|
+
exports.default = _sfc_main;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { UnwrapRef, DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
|
|
2
|
+
import { RenderStrategyProps } from '../../utils/use-render-strategy';
|
|
3
|
+
import { UseNavigationMenuReturn } from './use-navigation-menu';
|
|
4
|
+
interface RootProviderProps {
|
|
5
|
+
value: UnwrapRef<UseNavigationMenuReturn>;
|
|
6
|
+
}
|
|
7
|
+
export interface NavigationMenuRootProviderBaseProps extends RootProviderProps, RenderStrategyProps {
|
|
8
|
+
}
|
|
9
|
+
export interface NavigationMenuRootProviderProps extends NavigationMenuRootProviderBaseProps {
|
|
10
|
+
}
|
|
11
|
+
declare const _default: __VLS_WithTemplateSlots< DefineComponent<NavigationMenuRootProviderProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<NavigationMenuRootProviderProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>, {
|
|
12
|
+
default?(_: {}): any;
|
|
13
|
+
}>;
|
|
14
|
+
export default _default;
|
|
15
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
16
|
+
new (): {
|
|
17
|
+
$slots: S;
|
|
18
|
+
};
|
|
19
|
+
};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { UnwrapRef, DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
|
|
2
|
+
import { RenderStrategyProps } from '../../utils/use-render-strategy';
|
|
3
|
+
import { UseNavigationMenuReturn } from './use-navigation-menu';
|
|
4
|
+
interface RootProviderProps {
|
|
5
|
+
value: UnwrapRef<UseNavigationMenuReturn>;
|
|
6
|
+
}
|
|
7
|
+
export interface NavigationMenuRootProviderBaseProps extends RootProviderProps, RenderStrategyProps {
|
|
8
|
+
}
|
|
9
|
+
export interface NavigationMenuRootProviderProps extends NavigationMenuRootProviderBaseProps {
|
|
10
|
+
}
|
|
11
|
+
declare const _default: __VLS_WithTemplateSlots< DefineComponent<NavigationMenuRootProviderProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<NavigationMenuRootProviderProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>, {
|
|
12
|
+
default?(_: {}): any;
|
|
13
|
+
}>;
|
|
14
|
+
export default _default;
|
|
15
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
16
|
+
new (): {
|
|
17
|
+
$slots: S;
|
|
18
|
+
};
|
|
19
|
+
};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { defineComponent, computed, createBlock, openBlock, unref, normalizeProps, guardReactiveProps, withCtx, renderSlot } from 'vue';
|
|
2
|
+
import { RenderStrategyPropsProvider } from '../../utils/use-render-strategy.js';
|
|
3
|
+
import { useForwardExpose } from '../../utils/use-forward-expose.js';
|
|
4
|
+
import { ark } from '../factory.js';
|
|
5
|
+
import { NavigationMenuProvider } from './use-navigation-menu-context.js';
|
|
6
|
+
|
|
7
|
+
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
8
|
+
__name: "navigation-menu-root-provider",
|
|
9
|
+
props: {
|
|
10
|
+
value: {},
|
|
11
|
+
lazyMount: { type: Boolean },
|
|
12
|
+
unmountOnExit: { type: Boolean }
|
|
13
|
+
},
|
|
14
|
+
setup(__props) {
|
|
15
|
+
const props = __props;
|
|
16
|
+
const navigationMenu = computed(() => props.value);
|
|
17
|
+
NavigationMenuProvider(navigationMenu);
|
|
18
|
+
RenderStrategyPropsProvider(computed(() => ({ lazyMount: props.lazyMount, unmountOnExit: props.unmountOnExit })));
|
|
19
|
+
useForwardExpose();
|
|
20
|
+
return (_ctx, _cache) => {
|
|
21
|
+
return openBlock(), createBlock(unref(ark).nav, normalizeProps(guardReactiveProps(navigationMenu.value.getRootProps())), {
|
|
22
|
+
default: withCtx(() => [
|
|
23
|
+
renderSlot(_ctx.$slots, "default")
|
|
24
|
+
]),
|
|
25
|
+
_: 3
|
|
26
|
+
}, 16);
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
});
|
|
30
|
+
|
|
31
|
+
export { _sfc_main as default };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: 'Module' } });
|
|
4
|
+
|
|
5
|
+
const navigationMenuRootProvider_vue_vue_type_script_setup_true_lang = require('./navigation-menu-root-provider.vue.cjs');
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
exports.default = navigationMenuRootProvider_vue_vue_type_script_setup_true_lang.default;
|