@ark-ui/vue 5.20.0 → 5.22.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/collection/index.cjs +2 -0
- package/dist/components/collection/index.d.cts +1 -0
- package/dist/components/collection/index.d.ts +1 -0
- package/dist/components/collection/index.js +1 -0
- package/dist/components/collection/tree-collection.js +1 -1
- package/dist/components/collection/use-async-list.cjs +35 -0
- package/dist/components/collection/use-async-list.d.cts +7 -0
- package/dist/components/collection/use-async-list.d.ts +7 -0
- package/dist/components/collection/use-async-list.js +12 -0
- package/dist/components/combobox/combobox-empty.vue.cjs +35 -0
- package/dist/components/combobox/combobox-empty.vue.d.cts +19 -0
- package/dist/components/combobox/combobox-empty.vue.d.ts +19 -0
- package/dist/components/combobox/combobox-empty.vue.js +31 -0
- package/dist/components/combobox/combobox-empty.vue2.cjs +9 -0
- package/dist/components/combobox/combobox-empty.vue2.js +5 -0
- package/dist/components/combobox/combobox.anatomy.cjs +9 -0
- package/dist/components/combobox/combobox.anatomy.d.cts +2 -1
- package/dist/components/combobox/combobox.anatomy.d.ts +2 -1
- package/dist/components/combobox/combobox.anatomy.js +5 -0
- package/dist/components/combobox/combobox.cjs +2 -0
- package/dist/components/combobox/combobox.d.cts +1 -0
- package/dist/components/combobox/combobox.d.ts +1 -0
- package/dist/components/combobox/combobox.js +1 -0
- package/dist/components/combobox/index.cjs +6 -7
- package/dist/components/combobox/index.d.cts +1 -0
- package/dist/components/combobox/index.d.ts +1 -0
- package/dist/components/combobox/index.js +2 -1
- package/dist/components/dialog/dialog-root.vue.cjs +1 -1
- package/dist/components/dialog/dialog-root.vue.d.cts +12 -0
- package/dist/components/dialog/dialog-root.vue.d.ts +12 -0
- package/dist/components/dialog/dialog-root.vue.js +1 -1
- package/dist/components/dialog/dialog.types.d.cts +11 -0
- package/dist/components/dialog/dialog.types.d.ts +11 -0
- package/dist/components/dialog/use-dialog.cjs +4 -0
- package/dist/components/dialog/use-dialog.js +4 -0
- package/dist/components/field/use-field.d.cts +16 -16
- package/dist/components/field/use-field.d.ts +16 -16
- package/dist/components/fieldset/fieldset-legend.vue.cjs +1 -1
- package/dist/components/fieldset/fieldset-legend.vue.js +1 -1
- package/dist/components/fieldset/use-fieldset.cjs +2 -1
- package/dist/components/fieldset/use-fieldset.d.cts +3 -3
- package/dist/components/fieldset/use-fieldset.d.ts +3 -3
- package/dist/components/fieldset/use-fieldset.js +2 -1
- package/dist/components/hover-card/hover-card-root.vue.cjs +2 -0
- package/dist/components/hover-card/hover-card-root.vue.d.cts +1 -0
- package/dist/components/hover-card/hover-card-root.vue.d.ts +1 -0
- package/dist/components/hover-card/hover-card-root.vue.js +2 -0
- package/dist/components/hover-card/hover-card.types.d.cts +4 -0
- package/dist/components/hover-card/hover-card.types.d.ts +4 -0
- package/dist/components/index.cjs +25 -21
- package/dist/components/index.d.cts +1 -0
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.js +10 -5
- package/dist/components/listbox/index.cjs +6 -7
- package/dist/components/listbox/index.d.cts +1 -0
- package/dist/components/listbox/index.d.ts +1 -0
- package/dist/components/listbox/index.js +2 -1
- package/dist/components/listbox/listbox-empty.vue.cjs +35 -0
- package/dist/components/listbox/listbox-empty.vue.d.cts +19 -0
- package/dist/components/listbox/listbox-empty.vue.d.ts +19 -0
- package/dist/components/listbox/listbox-empty.vue.js +31 -0
- package/dist/components/listbox/listbox-empty.vue2.cjs +9 -0
- package/dist/components/listbox/listbox-empty.vue2.js +5 -0
- package/dist/components/listbox/listbox.anatomy.cjs +9 -0
- package/dist/components/listbox/listbox.anatomy.d.cts +2 -1
- package/dist/components/listbox/listbox.anatomy.d.ts +2 -1
- package/dist/components/listbox/listbox.anatomy.js +5 -0
- package/dist/components/listbox/listbox.cjs +2 -0
- package/dist/components/listbox/listbox.d.cts +1 -0
- package/dist/components/listbox/listbox.d.ts +1 -0
- package/dist/components/listbox/listbox.js +1 -0
- package/dist/components/menu/menu-root.vue.cjs +1 -1
- package/dist/components/menu/menu-root.vue.d.cts +12 -0
- package/dist/components/menu/menu-root.vue.d.ts +12 -0
- package/dist/components/menu/menu-root.vue.js +1 -1
- package/dist/components/menu/menu.types.d.cts +11 -0
- package/dist/components/menu/menu.types.d.ts +11 -0
- package/dist/components/popover/popover-root.vue.cjs +1 -1
- package/dist/components/popover/popover-root.vue.d.cts +12 -0
- package/dist/components/popover/popover-root.vue.d.ts +12 -0
- package/dist/components/popover/popover-root.vue.js +1 -1
- package/dist/components/popover/popover.types.d.cts +11 -0
- package/dist/components/popover/popover.types.d.ts +11 -0
- package/dist/components/segment-group/segment-group.anatomy.d.cts +2 -2
- package/dist/components/segment-group/segment-group.anatomy.d.ts +2 -2
- package/dist/components/signature-pad/signature-pad-segment.vue.cjs +1 -2
- package/dist/components/signature-pad/signature-pad-segment.vue.js +1 -2
- package/dist/components/toast/index.d.cts +1 -0
- package/dist/components/toast/index.d.ts +1 -0
- package/dist/index.cjs +27 -21
- package/dist/index.js +11 -5
- package/dist/providers/index.cjs +2 -0
- package/dist/providers/index.js +1 -0
- package/dist/providers/locale/index.cjs +2 -0
- package/dist/providers/locale/index.d.cts +1 -0
- package/dist/providers/locale/index.d.ts +1 -0
- package/dist/providers/locale/index.js +1 -0
- package/dist/providers/locale/use-collator.cjs +19 -0
- package/dist/providers/locale/use-collator.d.cts +7 -0
- package/dist/providers/locale/use-collator.d.ts +7 -0
- package/dist/providers/locale/use-collator.js +15 -0
- package/package.json +68 -67
|
@@ -5,6 +5,7 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
|
5
5
|
const gridCollection = require('./grid-collection.cjs');
|
|
6
6
|
const listCollection = require('./list-collection.cjs');
|
|
7
7
|
const treeCollection = require('./tree-collection.cjs');
|
|
8
|
+
const useAsyncList = require('./use-async-list.cjs');
|
|
8
9
|
const useListCollection = require('./use-list-collection.cjs');
|
|
9
10
|
const useListSelection = require('./use-list-selection.cjs');
|
|
10
11
|
|
|
@@ -14,5 +15,6 @@ exports.createGridCollection = gridCollection.createGridCollection;
|
|
|
14
15
|
exports.createListCollection = listCollection.createListCollection;
|
|
15
16
|
exports.createFileTreeCollection = treeCollection.createFileTreeCollection;
|
|
16
17
|
exports.createTreeCollection = treeCollection.createTreeCollection;
|
|
18
|
+
exports.useAsyncList = useAsyncList.useAsyncList;
|
|
17
19
|
exports.useListCollection = useListCollection.useListCollection;
|
|
18
20
|
exports.useListSelection = useListSelection.useListSelection;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export { createGridCollection, type GridCollection, type GridCollectionOptions } from './grid-collection';
|
|
2
2
|
export { createListCollection, type CollectionItem, type CollectionOptions, type ListCollection, } from './list-collection';
|
|
3
3
|
export { createFileTreeCollection, createTreeCollection, type FilePathTreeNode, type FlatTreeNode, type TreeCollection, type TreeCollectionOptions, type TreeNode, } from './tree-collection';
|
|
4
|
+
export { useAsyncList, type UseAsyncListProps, type UseAsyncListReturn } from './use-async-list';
|
|
4
5
|
export { useListCollection, type UseListCollectionProps, type UseListCollectionReturn } from './use-list-collection';
|
|
5
6
|
export { useListSelection, type UseListSelectionProps, type UseListSelectionReturn } from './use-list-selection';
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export { createGridCollection, type GridCollection, type GridCollectionOptions } from './grid-collection';
|
|
2
2
|
export { createListCollection, type CollectionItem, type CollectionOptions, type ListCollection, } from './list-collection';
|
|
3
3
|
export { createFileTreeCollection, createTreeCollection, type FilePathTreeNode, type FlatTreeNode, type TreeCollection, type TreeCollectionOptions, type TreeNode, } from './tree-collection';
|
|
4
|
+
export { useAsyncList, type UseAsyncListProps, type UseAsyncListReturn } from './use-async-list';
|
|
4
5
|
export { useListCollection, type UseListCollectionProps, type UseListCollectionReturn } from './use-list-collection';
|
|
5
6
|
export { useListSelection, type UseListSelectionProps, type UseListSelectionReturn } from './use-list-selection';
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export { createGridCollection } from './grid-collection.js';
|
|
2
2
|
export { createListCollection } from './list-collection.js';
|
|
3
3
|
export { createFileTreeCollection, createTreeCollection } from './tree-collection.js';
|
|
4
|
+
export { useAsyncList } from './use-async-list.js';
|
|
4
5
|
export { useListCollection } from './use-list-collection.js';
|
|
5
6
|
export { useListSelection } from './use-list-selection.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { filePathToTree, TreeCollection } from '@zag-js/collection';
|
|
2
2
|
|
|
3
3
|
const createTreeCollection = (options) => new TreeCollection(options);
|
|
4
4
|
const createFileTreeCollection = (paths) => filePathToTree(paths);
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
4
|
+
|
|
5
|
+
const asyncList = require('@zag-js/async-list');
|
|
6
|
+
const vue$1 = require('@zag-js/vue');
|
|
7
|
+
const vue = require('vue');
|
|
8
|
+
const cleanProps = require('../../utils/clean-props.cjs');
|
|
9
|
+
|
|
10
|
+
function _interopNamespaceDefault(e) {
|
|
11
|
+
const n = Object.create(null, { [Symbol.toStringTag]: { value: 'Module' } });
|
|
12
|
+
if (e) {
|
|
13
|
+
for (const k in e) {
|
|
14
|
+
if (k !== 'default') {
|
|
15
|
+
const d = Object.getOwnPropertyDescriptor(e, k);
|
|
16
|
+
Object.defineProperty(n, k, d.get ? d : {
|
|
17
|
+
enumerable: true,
|
|
18
|
+
get: () => e[k]
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
n.default = e;
|
|
24
|
+
return Object.freeze(n);
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
const asyncList__namespace = /*#__PURE__*/_interopNamespaceDefault(asyncList);
|
|
28
|
+
|
|
29
|
+
const useAsyncList = (props = {}) => {
|
|
30
|
+
const context = vue.computed(() => cleanProps.cleanProps(vue.toValue(props)));
|
|
31
|
+
const service = vue$1.useMachine(asyncList__namespace.machine, context);
|
|
32
|
+
return vue.computed(() => asyncList__namespace.connect(service));
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
exports.useAsyncList = useAsyncList;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { ComputedRef, MaybeRef } from 'vue';
|
|
2
|
+
import * as asyncList from '@zag-js/async-list';
|
|
3
|
+
export interface UseAsyncListProps<T, C = string> extends asyncList.Props<T, C> {
|
|
4
|
+
}
|
|
5
|
+
export interface UseAsyncListReturn<T, C = string> extends ComputedRef<asyncList.Api<T, C>> {
|
|
6
|
+
}
|
|
7
|
+
export declare const useAsyncList: <T, C = string>(props?: MaybeRef<UseAsyncListProps<T, C>>) => UseAsyncListReturn<T, C>;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { ComputedRef, MaybeRef } from 'vue';
|
|
2
|
+
import * as asyncList from '@zag-js/async-list';
|
|
3
|
+
export interface UseAsyncListProps<T, C = string> extends asyncList.Props<T, C> {
|
|
4
|
+
}
|
|
5
|
+
export interface UseAsyncListReturn<T, C = string> extends ComputedRef<asyncList.Api<T, C>> {
|
|
6
|
+
}
|
|
7
|
+
export declare const useAsyncList: <T, C = string>(props?: MaybeRef<UseAsyncListProps<T, C>>) => UseAsyncListReturn<T, C>;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import * as asyncList from '@zag-js/async-list';
|
|
2
|
+
import { useMachine } from '@zag-js/vue';
|
|
3
|
+
import { computed, toValue } from 'vue';
|
|
4
|
+
import { cleanProps } from '../../utils/clean-props.js';
|
|
5
|
+
|
|
6
|
+
const useAsyncList = (props = {}) => {
|
|
7
|
+
const context = computed(() => cleanProps(toValue(props)));
|
|
8
|
+
const service = useMachine(asyncList.machine, context);
|
|
9
|
+
return computed(() => asyncList.connect(service));
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
export { useAsyncList };
|
|
@@ -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 combobox_anatomy = require('./combobox.anatomy.cjs');
|
|
8
|
+
const useComboboxContext = require('./use-combobox-context.cjs');
|
|
9
|
+
const useForwardExpose = require('../../utils/use-forward-expose.cjs');
|
|
10
|
+
|
|
11
|
+
const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
12
|
+
__name: "combobox-empty",
|
|
13
|
+
props: {
|
|
14
|
+
asChild: { type: Boolean }
|
|
15
|
+
},
|
|
16
|
+
setup(__props) {
|
|
17
|
+
const parts = combobox_anatomy.comboboxAnatomy.build();
|
|
18
|
+
const combobox = useComboboxContext.useComboboxContext();
|
|
19
|
+
const isEmpty = vue.computed(() => combobox.value.collection.size === 0);
|
|
20
|
+
useForwardExpose.useForwardExpose();
|
|
21
|
+
return (_ctx, _cache) => {
|
|
22
|
+
return isEmpty.value ? (vue.openBlock(), vue.createBlock(vue.unref(factory.ark).div, vue.mergeProps({ key: 0 }, vue.unref(parts).empty.attrs, {
|
|
23
|
+
role: "presentation",
|
|
24
|
+
"as-child": _ctx.asChild
|
|
25
|
+
}), {
|
|
26
|
+
default: vue.withCtx(() => [
|
|
27
|
+
vue.renderSlot(_ctx.$slots, "default")
|
|
28
|
+
]),
|
|
29
|
+
_: 3
|
|
30
|
+
}, 16, ["as-child"])) : vue.createCommentVNode("", true);
|
|
31
|
+
};
|
|
32
|
+
}
|
|
33
|
+
});
|
|
34
|
+
|
|
35
|
+
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 ComboboxEmptyBaseProps extends PolymorphicProps {
|
|
4
|
+
}
|
|
5
|
+
export interface ComboboxEmptyProps extends ComboboxEmptyBaseProps,
|
|
6
|
+
/**
|
|
7
|
+
* @vue-ignore
|
|
8
|
+
*/
|
|
9
|
+
HTMLAttributes {
|
|
10
|
+
}
|
|
11
|
+
declare const _default: __VLS_WithTemplateSlots< DefineComponent<ComboboxEmptyProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<ComboboxEmptyProps> & 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 ComboboxEmptyBaseProps extends PolymorphicProps {
|
|
4
|
+
}
|
|
5
|
+
export interface ComboboxEmptyProps extends ComboboxEmptyBaseProps,
|
|
6
|
+
/**
|
|
7
|
+
* @vue-ignore
|
|
8
|
+
*/
|
|
9
|
+
HTMLAttributes {
|
|
10
|
+
}
|
|
11
|
+
declare const _default: __VLS_WithTemplateSlots< DefineComponent<ComboboxEmptyProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<ComboboxEmptyProps> & 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, createCommentVNode, openBlock, unref, mergeProps, withCtx, renderSlot } from 'vue';
|
|
2
|
+
import { ark } from '../factory.js';
|
|
3
|
+
import { comboboxAnatomy } from './combobox.anatomy.js';
|
|
4
|
+
import { useComboboxContext } from './use-combobox-context.js';
|
|
5
|
+
import { useForwardExpose } from '../../utils/use-forward-expose.js';
|
|
6
|
+
|
|
7
|
+
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
8
|
+
__name: "combobox-empty",
|
|
9
|
+
props: {
|
|
10
|
+
asChild: { type: Boolean }
|
|
11
|
+
},
|
|
12
|
+
setup(__props) {
|
|
13
|
+
const parts = comboboxAnatomy.build();
|
|
14
|
+
const combobox = useComboboxContext();
|
|
15
|
+
const isEmpty = computed(() => combobox.value.collection.size === 0);
|
|
16
|
+
useForwardExpose();
|
|
17
|
+
return (_ctx, _cache) => {
|
|
18
|
+
return isEmpty.value ? (openBlock(), createBlock(unref(ark).div, mergeProps({ key: 0 }, unref(parts).empty.attrs, {
|
|
19
|
+
role: "presentation",
|
|
20
|
+
"as-child": _ctx.asChild
|
|
21
|
+
}), {
|
|
22
|
+
default: withCtx(() => [
|
|
23
|
+
renderSlot(_ctx.$slots, "default")
|
|
24
|
+
]),
|
|
25
|
+
_: 3
|
|
26
|
+
}, 16, ["as-child"])) : createCommentVNode("", true);
|
|
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 comboboxEmpty_vue_vue_type_script_setup_true_lang = require('./combobox-empty.vue.cjs');
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
exports.default = comboboxEmpty_vue_vue_type_script_setup_true_lang.default;
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
import { AnatomyInstance } from '@zag-js/anatomy';
|
|
2
|
+
export declare const comboboxAnatomy: AnatomyInstance<"input" | "label" | "list" | "content" | "root" | "item" | "trigger" | "control" | "itemGroup" | "positioner" | "clearTrigger" | "itemGroupLabel" | "itemIndicator" | "itemText" | "empty">;
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
import { AnatomyInstance } from '@zag-js/anatomy';
|
|
2
|
+
export declare const comboboxAnatomy: AnatomyInstance<"input" | "label" | "list" | "content" | "root" | "item" | "trigger" | "control" | "itemGroup" | "positioner" | "clearTrigger" | "itemGroupLabel" | "itemIndicator" | "itemText" | "empty">;
|
|
@@ -4,6 +4,7 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
|
4
4
|
|
|
5
5
|
const comboboxClearTrigger_vue_vue_type_script_setup_true_lang = require('./combobox-clear-trigger.vue.cjs');
|
|
6
6
|
const comboboxContent_vue_vue_type_script_setup_true_lang = require('./combobox-content.vue.cjs');
|
|
7
|
+
const comboboxEmpty_vue_vue_type_script_setup_true_lang = require('./combobox-empty.vue.cjs');
|
|
7
8
|
const comboboxContext_vue_vue_type_script_setup_true_lang = require('./combobox-context.vue.cjs');
|
|
8
9
|
const comboboxControl_vue_vue_type_script_setup_true_lang = require('./combobox-control.vue.cjs');
|
|
9
10
|
const comboboxInput_vue_vue_type_script_setup_true_lang = require('./combobox-input.vue.cjs');
|
|
@@ -24,6 +25,7 @@ const comboboxTrigger_vue_vue_type_script_setup_true_lang = require('./combobox-
|
|
|
24
25
|
|
|
25
26
|
exports.ClearTrigger = comboboxClearTrigger_vue_vue_type_script_setup_true_lang.default;
|
|
26
27
|
exports.Content = comboboxContent_vue_vue_type_script_setup_true_lang.default;
|
|
28
|
+
exports.Empty = comboboxEmpty_vue_vue_type_script_setup_true_lang.default;
|
|
27
29
|
exports.Context = comboboxContext_vue_vue_type_script_setup_true_lang.default;
|
|
28
30
|
exports.Control = comboboxControl_vue_vue_type_script_setup_true_lang.default;
|
|
29
31
|
exports.Input = comboboxInput_vue_vue_type_script_setup_true_lang.default;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export type { HighlightChangeDetails, InputValueChangeDetails, OpenChangeDetails, ValueChangeDetails, SelectionDetails, } from '@zag-js/combobox';
|
|
2
2
|
export { default as ClearTrigger, type ComboboxClearTriggerProps as ClearTriggerProps, type ComboboxClearTriggerBaseProps as ClearTriggerBaseProps, } from './combobox-clear-trigger.vue';
|
|
3
3
|
export { default as Content, type ComboboxContentProps as ContentProps, type ComboboxContentBaseProps as ContentBaseProps, } from './combobox-content.vue';
|
|
4
|
+
export { default as Empty, type ComboboxEmptyProps as EmptyProps, type ComboboxEmptyBaseProps as EmptyBaseProps, } from './combobox-empty.vue';
|
|
4
5
|
export { default as Context, type ComboboxContextProps as ContextProps } from './combobox-context.vue';
|
|
5
6
|
export { default as Control, type ComboboxControlProps as ControlProps, type ComboboxControlBaseProps as ControlBaseProps, } from './combobox-control.vue';
|
|
6
7
|
export { default as Input, type ComboboxInputProps as InputProps, type ComboboxInputBaseProps as InputBaseProps, } from './combobox-input.vue';
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export type { HighlightChangeDetails, InputValueChangeDetails, OpenChangeDetails, ValueChangeDetails, SelectionDetails, } from '@zag-js/combobox';
|
|
2
2
|
export { default as ClearTrigger, type ComboboxClearTriggerProps as ClearTriggerProps, type ComboboxClearTriggerBaseProps as ClearTriggerBaseProps, } from './combobox-clear-trigger.vue';
|
|
3
3
|
export { default as Content, type ComboboxContentProps as ContentProps, type ComboboxContentBaseProps as ContentBaseProps, } from './combobox-content.vue';
|
|
4
|
+
export { default as Empty, type ComboboxEmptyProps as EmptyProps, type ComboboxEmptyBaseProps as EmptyBaseProps, } from './combobox-empty.vue';
|
|
4
5
|
export { default as Context, type ComboboxContextProps as ContextProps } from './combobox-context.vue';
|
|
5
6
|
export { default as Control, type ComboboxControlProps as ControlProps, type ComboboxControlBaseProps as ControlBaseProps, } from './combobox-control.vue';
|
|
6
7
|
export { default as Input, type ComboboxInputProps as InputProps, type ComboboxInputBaseProps as InputBaseProps, } from './combobox-input.vue';
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export { default as ClearTrigger } from './combobox-clear-trigger.vue.js';
|
|
2
2
|
export { default as Content } from './combobox-content.vue.js';
|
|
3
|
+
export { default as Empty } from './combobox-empty.vue.js';
|
|
3
4
|
export { default as Context } from './combobox-context.vue.js';
|
|
4
5
|
export { default as Control } from './combobox-control.vue.js';
|
|
5
6
|
export { default as Input } from './combobox-input.vue.js';
|
|
@@ -6,6 +6,7 @@ const listCollection = require('../collection/list-collection.cjs');
|
|
|
6
6
|
const useListCollection = require('../collection/use-list-collection.cjs');
|
|
7
7
|
const comboboxClearTrigger_vue_vue_type_script_setup_true_lang = require('./combobox-clear-trigger.vue.cjs');
|
|
8
8
|
const comboboxContent_vue_vue_type_script_setup_true_lang = require('./combobox-content.vue.cjs');
|
|
9
|
+
const comboboxEmpty_vue_vue_type_script_setup_true_lang = require('./combobox-empty.vue.cjs');
|
|
9
10
|
const comboboxContext_vue_vue_type_script_setup_true_lang = require('./combobox-context.vue.cjs');
|
|
10
11
|
const comboboxControl_vue_vue_type_script_setup_true_lang = require('./combobox-control.vue.cjs');
|
|
11
12
|
const comboboxInput_vue_vue_type_script_setup_true_lang = require('./combobox-input.vue.cjs');
|
|
@@ -21,11 +22,11 @@ const comboboxPositioner_vue_vue_type_script_setup_true_lang = require('./combob
|
|
|
21
22
|
const comboboxRootProvider_vue_vue_type_script_setup_true_lang = require('./combobox-root-provider.vue.cjs');
|
|
22
23
|
const comboboxRoot_vue_vue_type_script_setup_true_lang = require('./combobox-root.vue.cjs');
|
|
23
24
|
const comboboxTrigger_vue_vue_type_script_setup_true_lang = require('./combobox-trigger.vue.cjs');
|
|
25
|
+
const combobox_anatomy = require('./combobox.anatomy.cjs');
|
|
24
26
|
const useCombobox = require('./use-combobox.cjs');
|
|
25
27
|
const useComboboxContext = require('./use-combobox-context.cjs');
|
|
26
28
|
const useComboboxItemContext = require('./use-combobox-item-context.cjs');
|
|
27
|
-
const combobox
|
|
28
|
-
const combobox = require('@zag-js/combobox');
|
|
29
|
+
const combobox = require('./combobox.cjs');
|
|
29
30
|
|
|
30
31
|
|
|
31
32
|
|
|
@@ -33,6 +34,7 @@ exports.createListCollection = listCollection.createListCollection;
|
|
|
33
34
|
exports.useListCollection = useListCollection.useListCollection;
|
|
34
35
|
exports.ComboboxClearTrigger = comboboxClearTrigger_vue_vue_type_script_setup_true_lang.default;
|
|
35
36
|
exports.ComboboxContent = comboboxContent_vue_vue_type_script_setup_true_lang.default;
|
|
37
|
+
exports.ComboboxEmpty = comboboxEmpty_vue_vue_type_script_setup_true_lang.default;
|
|
36
38
|
exports.ComboboxContext = comboboxContext_vue_vue_type_script_setup_true_lang.default;
|
|
37
39
|
exports.ComboboxControl = comboboxControl_vue_vue_type_script_setup_true_lang.default;
|
|
38
40
|
exports.ComboboxInput = comboboxInput_vue_vue_type_script_setup_true_lang.default;
|
|
@@ -48,11 +50,8 @@ exports.ComboboxPositioner = comboboxPositioner_vue_vue_type_script_setup_true_l
|
|
|
48
50
|
exports.ComboboxRootProvider = comboboxRootProvider_vue_vue_type_script_setup_true_lang.default;
|
|
49
51
|
exports.ComboboxRoot = comboboxRoot_vue_vue_type_script_setup_true_lang.default;
|
|
50
52
|
exports.ComboboxTrigger = comboboxTrigger_vue_vue_type_script_setup_true_lang.default;
|
|
53
|
+
exports.comboboxAnatomy = combobox_anatomy.comboboxAnatomy;
|
|
51
54
|
exports.useCombobox = useCombobox.useCombobox;
|
|
52
55
|
exports.useComboboxContext = useComboboxContext.useComboboxContext;
|
|
53
56
|
exports.useComboboxItemContext = useComboboxItemContext.useComboboxItemContext;
|
|
54
|
-
exports.Combobox = combobox
|
|
55
|
-
Object.defineProperty(exports, "comboboxAnatomy", {
|
|
56
|
-
enumerable: true,
|
|
57
|
-
get: () => combobox.anatomy
|
|
58
|
-
});
|
|
57
|
+
exports.Combobox = combobox;
|
|
@@ -2,6 +2,7 @@ export type { HighlightChangeDetails as ComboboxHighlightChangeDetails, InputVal
|
|
|
2
2
|
export { createListCollection, type CollectionItem, type ListCollection, useListCollection, type UseListCollectionProps, } from '../collection';
|
|
3
3
|
export { default as ComboboxClearTrigger, type ComboboxClearTriggerBaseProps, type ComboboxClearTriggerProps, } from './combobox-clear-trigger.vue';
|
|
4
4
|
export { default as ComboboxContent, type ComboboxContentBaseProps, type ComboboxContentProps, } from './combobox-content.vue';
|
|
5
|
+
export { default as ComboboxEmpty, type ComboboxEmptyBaseProps, type ComboboxEmptyProps } from './combobox-empty.vue';
|
|
5
6
|
export { default as ComboboxContext, type ComboboxContextProps } from './combobox-context.vue';
|
|
6
7
|
export { default as ComboboxControl, type ComboboxControlBaseProps, type ComboboxControlProps, } from './combobox-control.vue';
|
|
7
8
|
export { default as ComboboxInput, type ComboboxInputBaseProps, type ComboboxInputProps } from './combobox-input.vue';
|
|
@@ -2,6 +2,7 @@ export type { HighlightChangeDetails as ComboboxHighlightChangeDetails, InputVal
|
|
|
2
2
|
export { createListCollection, type CollectionItem, type ListCollection, useListCollection, type UseListCollectionProps, } from '../collection';
|
|
3
3
|
export { default as ComboboxClearTrigger, type ComboboxClearTriggerBaseProps, type ComboboxClearTriggerProps, } from './combobox-clear-trigger.vue';
|
|
4
4
|
export { default as ComboboxContent, type ComboboxContentBaseProps, type ComboboxContentProps, } from './combobox-content.vue';
|
|
5
|
+
export { default as ComboboxEmpty, type ComboboxEmptyBaseProps, type ComboboxEmptyProps } from './combobox-empty.vue';
|
|
5
6
|
export { default as ComboboxContext, type ComboboxContextProps } from './combobox-context.vue';
|
|
6
7
|
export { default as ComboboxControl, type ComboboxControlBaseProps, type ComboboxControlProps, } from './combobox-control.vue';
|
|
7
8
|
export { default as ComboboxInput, type ComboboxInputBaseProps, type ComboboxInputProps } from './combobox-input.vue';
|
|
@@ -2,6 +2,7 @@ export { createListCollection } from '../collection/list-collection.js';
|
|
|
2
2
|
export { useListCollection } from '../collection/use-list-collection.js';
|
|
3
3
|
export { default as ComboboxClearTrigger } from './combobox-clear-trigger.vue.js';
|
|
4
4
|
export { default as ComboboxContent } from './combobox-content.vue.js';
|
|
5
|
+
export { default as ComboboxEmpty } from './combobox-empty.vue.js';
|
|
5
6
|
export { default as ComboboxContext } from './combobox-context.vue.js';
|
|
6
7
|
export { default as ComboboxControl } from './combobox-control.vue.js';
|
|
7
8
|
export { default as ComboboxInput } from './combobox-input.vue.js';
|
|
@@ -17,9 +18,9 @@ export { default as ComboboxPositioner } from './combobox-positioner.vue.js';
|
|
|
17
18
|
export { default as ComboboxRootProvider } from './combobox-root-provider.vue.js';
|
|
18
19
|
export { default as ComboboxRoot } from './combobox-root.vue.js';
|
|
19
20
|
export { default as ComboboxTrigger } from './combobox-trigger.vue.js';
|
|
21
|
+
export { comboboxAnatomy } from './combobox.anatomy.js';
|
|
20
22
|
export { useCombobox } from './use-combobox.js';
|
|
21
23
|
export { useComboboxContext } from './use-combobox-context.js';
|
|
22
24
|
export { useComboboxItemContext } from './use-combobox-item-context.js';
|
|
23
25
|
import * as combobox from './combobox.js';
|
|
24
26
|
export { combobox as Combobox };
|
|
25
|
-
export { anatomy as comboboxAnatomy } from '@zag-js/combobox';
|
|
@@ -38,7 +38,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
38
38
|
restoreFocus: void 0,
|
|
39
39
|
trapFocus: void 0
|
|
40
40
|
}),
|
|
41
|
-
emits: ["escapeKeyDown", "focusOutside", "interactOutside", "openChange", "pointerDownOutside", "update:open"],
|
|
41
|
+
emits: ["escapeKeyDown", "focusOutside", "interactOutside", "openChange", "pointerDownOutside", "requestDismiss", "update:open"],
|
|
42
42
|
setup(__props, { emit: __emit }) {
|
|
43
43
|
const props = __props;
|
|
44
44
|
const emits = __emit;
|
|
@@ -16,6 +16,12 @@ declare const _default: __VLS_WithTemplateSlots< DefineComponent<DialogRootProps
|
|
|
16
16
|
interactOutside: (event: InteractOutsideEvent) => any;
|
|
17
17
|
pointerDownOutside: (event: PointerDownOutsideEvent) => any;
|
|
18
18
|
escapeKeyDown: (event: KeyboardEvent) => any;
|
|
19
|
+
requestDismiss: (event: CustomEvent<{
|
|
20
|
+
originalLayer: HTMLElement;
|
|
21
|
+
targetLayer: HTMLElement | undefined;
|
|
22
|
+
originalIndex: number;
|
|
23
|
+
targetIndex: number;
|
|
24
|
+
}>) => any;
|
|
19
25
|
}, string, PublicProps, Readonly<DialogRootProps> & Readonly<{
|
|
20
26
|
onOpenChange?: ((details: OpenChangeDetails) => any) | undefined;
|
|
21
27
|
"onUpdate:open"?: ((open: boolean) => any) | undefined;
|
|
@@ -23,6 +29,12 @@ declare const _default: __VLS_WithTemplateSlots< DefineComponent<DialogRootProps
|
|
|
23
29
|
onInteractOutside?: ((event: InteractOutsideEvent) => any) | undefined;
|
|
24
30
|
onPointerDownOutside?: ((event: PointerDownOutsideEvent) => any) | undefined;
|
|
25
31
|
onEscapeKeyDown?: ((event: KeyboardEvent) => any) | undefined;
|
|
32
|
+
onRequestDismiss?: ((event: CustomEvent<{
|
|
33
|
+
originalLayer: HTMLElement;
|
|
34
|
+
targetLayer: HTMLElement | undefined;
|
|
35
|
+
originalIndex: number;
|
|
36
|
+
targetIndex: number;
|
|
37
|
+
}>) => any) | undefined;
|
|
26
38
|
}>, {
|
|
27
39
|
open: boolean;
|
|
28
40
|
defaultOpen: boolean;
|
|
@@ -16,6 +16,12 @@ declare const _default: __VLS_WithTemplateSlots< DefineComponent<DialogRootProps
|
|
|
16
16
|
interactOutside: (event: InteractOutsideEvent) => any;
|
|
17
17
|
pointerDownOutside: (event: PointerDownOutsideEvent) => any;
|
|
18
18
|
escapeKeyDown: (event: KeyboardEvent) => any;
|
|
19
|
+
requestDismiss: (event: CustomEvent<{
|
|
20
|
+
originalLayer: HTMLElement;
|
|
21
|
+
targetLayer: HTMLElement | undefined;
|
|
22
|
+
originalIndex: number;
|
|
23
|
+
targetIndex: number;
|
|
24
|
+
}>) => any;
|
|
19
25
|
}, string, PublicProps, Readonly<DialogRootProps> & Readonly<{
|
|
20
26
|
onOpenChange?: ((details: OpenChangeDetails) => any) | undefined;
|
|
21
27
|
"onUpdate:open"?: ((open: boolean) => any) | undefined;
|
|
@@ -23,6 +29,12 @@ declare const _default: __VLS_WithTemplateSlots< DefineComponent<DialogRootProps
|
|
|
23
29
|
onInteractOutside?: ((event: InteractOutsideEvent) => any) | undefined;
|
|
24
30
|
onPointerDownOutside?: ((event: PointerDownOutsideEvent) => any) | undefined;
|
|
25
31
|
onEscapeKeyDown?: ((event: KeyboardEvent) => any) | undefined;
|
|
32
|
+
onRequestDismiss?: ((event: CustomEvent<{
|
|
33
|
+
originalLayer: HTMLElement;
|
|
34
|
+
targetLayer: HTMLElement | undefined;
|
|
35
|
+
originalIndex: number;
|
|
36
|
+
targetIndex: number;
|
|
37
|
+
}>) => any) | undefined;
|
|
26
38
|
}>, {
|
|
27
39
|
open: boolean;
|
|
28
40
|
defaultOpen: boolean;
|
|
@@ -34,7 +34,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
34
34
|
restoreFocus: void 0,
|
|
35
35
|
trapFocus: void 0
|
|
36
36
|
}),
|
|
37
|
-
emits: ["escapeKeyDown", "focusOutside", "interactOutside", "openChange", "pointerDownOutside", "update:open"],
|
|
37
|
+
emits: ["escapeKeyDown", "focusOutside", "interactOutside", "openChange", "pointerDownOutside", "requestDismiss", "update:open"],
|
|
38
38
|
setup(__props, { emit: __emit }) {
|
|
39
39
|
const props = __props;
|
|
40
40
|
const emits = __emit;
|
|
@@ -100,6 +100,17 @@ export type RootEmits = {
|
|
|
100
100
|
* Function called when the pointer is pressed down outside the component
|
|
101
101
|
*/
|
|
102
102
|
pointerDownOutside: [event: dialog.PointerDownOutsideEvent];
|
|
103
|
+
/**
|
|
104
|
+
* Function called when this layer is closed due to a parent layer being closed
|
|
105
|
+
*/
|
|
106
|
+
requestDismiss: [
|
|
107
|
+
event: CustomEvent<{
|
|
108
|
+
originalLayer: HTMLElement;
|
|
109
|
+
targetLayer: HTMLElement | undefined;
|
|
110
|
+
originalIndex: number;
|
|
111
|
+
targetIndex: number;
|
|
112
|
+
}>
|
|
113
|
+
];
|
|
103
114
|
/**
|
|
104
115
|
* The callback fired when the open state changes.
|
|
105
116
|
*/
|
|
@@ -100,6 +100,17 @@ export type RootEmits = {
|
|
|
100
100
|
* Function called when the pointer is pressed down outside the component
|
|
101
101
|
*/
|
|
102
102
|
pointerDownOutside: [event: dialog.PointerDownOutsideEvent];
|
|
103
|
+
/**
|
|
104
|
+
* Function called when this layer is closed due to a parent layer being closed
|
|
105
|
+
*/
|
|
106
|
+
requestDismiss: [
|
|
107
|
+
event: CustomEvent<{
|
|
108
|
+
originalLayer: HTMLElement;
|
|
109
|
+
targetLayer: HTMLElement | undefined;
|
|
110
|
+
originalIndex: number;
|
|
111
|
+
targetIndex: number;
|
|
112
|
+
}>
|
|
113
|
+
];
|
|
103
114
|
/**
|
|
104
115
|
* The callback fired when the open state changes.
|
|
105
116
|
*/
|
|
@@ -59,6 +59,10 @@ const useDialog = (props = {}, emit) => {
|
|
|
59
59
|
onPointerDownOutside: (details) => {
|
|
60
60
|
emit?.("pointerDownOutside", details);
|
|
61
61
|
localeProps.onPointerDownOutside?.(details);
|
|
62
|
+
},
|
|
63
|
+
onRequestDismiss: (details) => {
|
|
64
|
+
emit?.("requestDismiss", details);
|
|
65
|
+
localeProps.onRequestDismiss?.(details);
|
|
62
66
|
}
|
|
63
67
|
};
|
|
64
68
|
});
|
|
@@ -36,6 +36,10 @@ const useDialog = (props = {}, emit) => {
|
|
|
36
36
|
onPointerDownOutside: (details) => {
|
|
37
37
|
emit?.("pointerDownOutside", details);
|
|
38
38
|
localeProps.onPointerDownOutside?.(details);
|
|
39
|
+
},
|
|
40
|
+
onRequestDismiss: (details) => {
|
|
41
|
+
emit?.("requestDismiss", details);
|
|
42
|
+
localeProps.onRequestDismiss?.(details);
|
|
39
43
|
}
|
|
40
44
|
};
|
|
41
45
|
});
|
|
@@ -44,9 +44,9 @@ export declare const useField: (props?: MaybeRef<UseFieldProps>) => ComputedRef<
|
|
|
44
44
|
required: boolean | undefined;
|
|
45
45
|
getLabelProps: () => {
|
|
46
46
|
id: string;
|
|
47
|
-
'data-disabled': boolean | "
|
|
48
|
-
'data-invalid': boolean | "
|
|
49
|
-
'data-readonly': boolean | "
|
|
47
|
+
'data-disabled': boolean | "false" | "true";
|
|
48
|
+
'data-invalid': boolean | "false" | "true";
|
|
49
|
+
'data-readonly': boolean | "false" | "true";
|
|
50
50
|
htmlFor: string;
|
|
51
51
|
"data-scope": string;
|
|
52
52
|
"data-part": string;
|
|
@@ -54,9 +54,9 @@ export declare const useField: (props?: MaybeRef<UseFieldProps>) => ComputedRef<
|
|
|
54
54
|
getRootProps: () => {
|
|
55
55
|
id: string;
|
|
56
56
|
role: string;
|
|
57
|
-
'data-disabled': boolean | "
|
|
58
|
-
'data-invalid': boolean | "
|
|
59
|
-
'data-readonly': boolean | "
|
|
57
|
+
'data-disabled': boolean | "false" | "true";
|
|
58
|
+
'data-invalid': boolean | "false" | "true";
|
|
59
|
+
'data-readonly': boolean | "false" | "true";
|
|
60
60
|
"data-scope": string;
|
|
61
61
|
"data-part": string;
|
|
62
62
|
};
|
|
@@ -65,9 +65,9 @@ export declare const useField: (props?: MaybeRef<UseFieldProps>) => ComputedRef<
|
|
|
65
65
|
"data-part": string;
|
|
66
66
|
'aria-describedby': string | undefined;
|
|
67
67
|
'aria-invalid': "true" | undefined;
|
|
68
|
-
'data-invalid': boolean | "
|
|
69
|
-
'data-required': boolean | "
|
|
70
|
-
'data-readonly': boolean | "
|
|
68
|
+
'data-invalid': boolean | "false" | "true";
|
|
69
|
+
'data-required': boolean | "false" | "true";
|
|
70
|
+
'data-readonly': boolean | "false" | "true";
|
|
71
71
|
id: string;
|
|
72
72
|
required: boolean | undefined;
|
|
73
73
|
disabled: boolean | undefined;
|
|
@@ -78,9 +78,9 @@ export declare const useField: (props?: MaybeRef<UseFieldProps>) => ComputedRef<
|
|
|
78
78
|
"data-part": string;
|
|
79
79
|
'aria-describedby': string | undefined;
|
|
80
80
|
'aria-invalid': "true" | undefined;
|
|
81
|
-
'data-invalid': boolean | "
|
|
82
|
-
'data-required': boolean | "
|
|
83
|
-
'data-readonly': boolean | "
|
|
81
|
+
'data-invalid': boolean | "false" | "true";
|
|
82
|
+
'data-required': boolean | "false" | "true";
|
|
83
|
+
'data-readonly': boolean | "false" | "true";
|
|
84
84
|
id: string;
|
|
85
85
|
required: boolean | undefined;
|
|
86
86
|
disabled: boolean | undefined;
|
|
@@ -91,16 +91,16 @@ export declare const useField: (props?: MaybeRef<UseFieldProps>) => ComputedRef<
|
|
|
91
91
|
"data-part": string;
|
|
92
92
|
'aria-describedby': string | undefined;
|
|
93
93
|
'aria-invalid': "true" | undefined;
|
|
94
|
-
'data-invalid': boolean | "
|
|
95
|
-
'data-required': boolean | "
|
|
96
|
-
'data-readonly': boolean | "
|
|
94
|
+
'data-invalid': boolean | "false" | "true";
|
|
95
|
+
'data-required': boolean | "false" | "true";
|
|
96
|
+
'data-readonly': boolean | "false" | "true";
|
|
97
97
|
id: string;
|
|
98
98
|
required: boolean | undefined;
|
|
99
99
|
disabled: boolean | undefined;
|
|
100
100
|
readOnly: boolean | undefined;
|
|
101
101
|
};
|
|
102
102
|
getHelperTextProps: () => {
|
|
103
|
-
'data-disabled': boolean | "
|
|
103
|
+
'data-disabled': boolean | "false" | "true";
|
|
104
104
|
"data-scope": string;
|
|
105
105
|
"data-part": string;
|
|
106
106
|
id: string;
|