@ark-ui/react 5.21.0 → 5.23.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/combobox/combobox-empty.cjs +22 -0
- package/dist/components/combobox/combobox-empty.d.cts +7 -0
- package/dist/components/combobox/combobox-empty.d.ts +7 -0
- package/dist/components/combobox/combobox-empty.js +18 -0
- package/dist/components/combobox/combobox-root-provider.d.cts +3 -2
- package/dist/components/combobox/combobox-root-provider.d.ts +3 -2
- package/dist/components/combobox/combobox-root.d.cts +2 -2
- package/dist/components/combobox/combobox-root.d.ts +2 -2
- package/dist/components/combobox/combobox.anatomy.cjs +10 -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 +6 -0
- package/dist/components/combobox/combobox.cjs +2 -0
- package/dist/components/combobox/combobox.d.cts +3 -2
- package/dist/components/combobox/combobox.d.ts +3 -2
- package/dist/components/combobox/combobox.js +1 -0
- package/dist/components/combobox/index.cjs +6 -7
- package/dist/components/combobox/index.d.cts +3 -2
- package/dist/components/combobox/index.d.ts +3 -2
- package/dist/components/combobox/index.js +2 -1
- package/dist/components/field/use-field.cjs +2 -1
- package/dist/components/field/use-field.js +2 -1
- package/dist/components/index.cjs +12 -14
- package/dist/components/index.js +4 -2
- package/dist/components/listbox/index.cjs +6 -7
- package/dist/components/listbox/index.d.cts +3 -2
- package/dist/components/listbox/index.d.ts +3 -2
- package/dist/components/listbox/index.js +2 -1
- package/dist/components/listbox/listbox-empty.cjs +22 -0
- package/dist/components/listbox/listbox-empty.d.cts +7 -0
- package/dist/components/listbox/listbox-empty.d.ts +7 -0
- package/dist/components/listbox/listbox-empty.js +18 -0
- package/dist/components/listbox/listbox-root-provider.d.cts +3 -2
- package/dist/components/listbox/listbox-root-provider.d.ts +3 -2
- package/dist/components/listbox/listbox-root.d.cts +2 -2
- package/dist/components/listbox/listbox-root.d.ts +2 -2
- package/dist/components/listbox/listbox.anatomy.cjs +10 -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 +6 -0
- package/dist/components/listbox/listbox.cjs +2 -0
- package/dist/components/listbox/listbox.d.cts +3 -2
- package/dist/components/listbox/listbox.d.ts +3 -2
- package/dist/components/listbox/listbox.js +1 -0
- package/dist/components/menu/menu-root.cjs +1 -0
- package/dist/components/menu/menu-root.js +1 -0
- package/dist/components/menu/menu-trigger-item.cjs +2 -1
- package/dist/components/menu/menu-trigger-item.js +2 -1
- 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/select/index.d.cts +2 -2
- package/dist/components/select/index.d.ts +2 -2
- package/dist/components/select/select-root-provider.d.cts +3 -2
- package/dist/components/select/select-root-provider.d.ts +3 -2
- package/dist/components/select/select-root.d.cts +2 -2
- package/dist/components/select/select-root.d.ts +2 -2
- package/dist/components/select/select.d.cts +2 -2
- package/dist/components/select/select.d.ts +2 -2
- package/dist/components/tree-view/index.d.cts +2 -2
- package/dist/components/tree-view/index.d.ts +2 -2
- package/dist/components/tree-view/tree-view-root-provider.d.cts +3 -2
- package/dist/components/tree-view/tree-view-root-provider.d.ts +3 -2
- package/dist/components/tree-view/tree-view-root.d.cts +3 -2
- package/dist/components/tree-view/tree-view-root.d.ts +3 -2
- package/dist/components/tree-view/tree-view.d.cts +2 -2
- package/dist/components/tree-view/tree-view.d.ts +2 -2
- package/dist/index.cjs +12 -14
- package/dist/index.js +4 -2
- package/package.json +70 -70
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
'use strict';
|
|
3
|
+
|
|
4
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
5
|
+
|
|
6
|
+
const jsxRuntime = require('react/jsx-runtime');
|
|
7
|
+
const react = require('react');
|
|
8
|
+
const factory = require('../factory.cjs');
|
|
9
|
+
const listbox_anatomy = require('./listbox.anatomy.cjs');
|
|
10
|
+
const useListboxContext = require('./use-listbox-context.cjs');
|
|
11
|
+
|
|
12
|
+
const parts = listbox_anatomy.listboxAnatomy.build();
|
|
13
|
+
const ListboxEmpty = react.forwardRef((props, ref) => {
|
|
14
|
+
const listbox = useListboxContext.useListboxContext();
|
|
15
|
+
if (listbox.collection.size !== 0) {
|
|
16
|
+
return null;
|
|
17
|
+
}
|
|
18
|
+
return /* @__PURE__ */ jsxRuntime.jsx(factory.ark.div, { ...parts.empty.attrs, ...props, role: "presentation", ref });
|
|
19
|
+
});
|
|
20
|
+
ListboxEmpty.displayName = "ListboxEmpty";
|
|
21
|
+
|
|
22
|
+
exports.ListboxEmpty = ListboxEmpty;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { HTMLProps, PolymorphicProps } from '../factory';
|
|
2
|
+
import { ForwardRefExoticComponent, RefAttributes } from 'react';
|
|
3
|
+
export interface ListboxEmptyBaseProps extends PolymorphicProps {
|
|
4
|
+
}
|
|
5
|
+
export interface ListboxEmptyProps extends HTMLProps<'div'>, ListboxEmptyBaseProps {
|
|
6
|
+
}
|
|
7
|
+
export declare const ListboxEmpty: ForwardRefExoticComponent<ListboxEmptyProps & RefAttributes<HTMLDivElement>>;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { HTMLProps, PolymorphicProps } from '../factory';
|
|
2
|
+
import { ForwardRefExoticComponent, RefAttributes } from 'react';
|
|
3
|
+
export interface ListboxEmptyBaseProps extends PolymorphicProps {
|
|
4
|
+
}
|
|
5
|
+
export interface ListboxEmptyProps extends HTMLProps<'div'>, ListboxEmptyBaseProps {
|
|
6
|
+
}
|
|
7
|
+
export declare const ListboxEmpty: ForwardRefExoticComponent<ListboxEmptyProps & RefAttributes<HTMLDivElement>>;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
import { jsx } from 'react/jsx-runtime';
|
|
3
|
+
import { forwardRef } from 'react';
|
|
4
|
+
import { ark } from '../factory.js';
|
|
5
|
+
import { listboxAnatomy } from './listbox.anatomy.js';
|
|
6
|
+
import { useListboxContext } from './use-listbox-context.js';
|
|
7
|
+
|
|
8
|
+
const parts = listboxAnatomy.build();
|
|
9
|
+
const ListboxEmpty = forwardRef((props, ref) => {
|
|
10
|
+
const listbox = useListboxContext();
|
|
11
|
+
if (listbox.collection.size !== 0) {
|
|
12
|
+
return null;
|
|
13
|
+
}
|
|
14
|
+
return /* @__PURE__ */ jsx(ark.div, { ...parts.empty.attrs, ...props, role: "presentation", ref });
|
|
15
|
+
});
|
|
16
|
+
ListboxEmpty.displayName = "ListboxEmpty";
|
|
17
|
+
|
|
18
|
+
export { ListboxEmpty };
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { JSX } from 'react';
|
|
2
|
+
import { Assign } from '../../types';
|
|
2
3
|
import { CollectionItem } from '../collection';
|
|
3
4
|
import { HTMLProps, PolymorphicProps } from '../factory';
|
|
4
5
|
import { UseListboxReturn } from './use-listbox';
|
|
@@ -9,6 +10,6 @@ export interface ListboxRootProviderBaseProps<T extends CollectionItem> extends
|
|
|
9
10
|
}
|
|
10
11
|
export interface ListboxRootProviderProps<T extends CollectionItem> extends HTMLProps<'div'>, ListboxRootProviderBaseProps<T> {
|
|
11
12
|
}
|
|
12
|
-
export type
|
|
13
|
-
export declare const ListboxRootProvider:
|
|
13
|
+
export type ListboxRootProviderComponent<P = {}> = <T extends CollectionItem>(props: Assign<ListboxRootProviderProps<T>, P> & React.RefAttributes<HTMLDivElement>) => JSX.Element;
|
|
14
|
+
export declare const ListboxRootProvider: ListboxRootProviderComponent;
|
|
14
15
|
export {};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { JSX } from 'react';
|
|
2
|
+
import { Assign } from '../../types';
|
|
2
3
|
import { CollectionItem } from '../collection';
|
|
3
4
|
import { HTMLProps, PolymorphicProps } from '../factory';
|
|
4
5
|
import { UseListboxReturn } from './use-listbox';
|
|
@@ -9,6 +10,6 @@ export interface ListboxRootProviderBaseProps<T extends CollectionItem> extends
|
|
|
9
10
|
}
|
|
10
11
|
export interface ListboxRootProviderProps<T extends CollectionItem> extends HTMLProps<'div'>, ListboxRootProviderBaseProps<T> {
|
|
11
12
|
}
|
|
12
|
-
export type
|
|
13
|
-
export declare const ListboxRootProvider:
|
|
13
|
+
export type ListboxRootProviderComponent<P = {}> = <T extends CollectionItem>(props: Assign<ListboxRootProviderProps<T>, P> & React.RefAttributes<HTMLDivElement>) => JSX.Element;
|
|
14
|
+
export declare const ListboxRootProvider: ListboxRootProviderComponent;
|
|
14
15
|
export {};
|
|
@@ -7,5 +7,5 @@ export interface ListboxRootBaseProps<T extends CollectionItem> extends UseListb
|
|
|
7
7
|
}
|
|
8
8
|
export interface ListboxRootProps<T extends CollectionItem> extends Assign<HTMLProps<'div'>, ListboxRootBaseProps<T>> {
|
|
9
9
|
}
|
|
10
|
-
export type
|
|
11
|
-
export declare const ListboxRoot:
|
|
10
|
+
export type ListboxRootComponent<P = {}> = <T extends CollectionItem>(props: Assign<ListboxRootProps<T>, P> & React.RefAttributes<HTMLDivElement>) => JSX.Element;
|
|
11
|
+
export declare const ListboxRoot: ListboxRootComponent;
|
|
@@ -7,5 +7,5 @@ export interface ListboxRootBaseProps<T extends CollectionItem> extends UseListb
|
|
|
7
7
|
}
|
|
8
8
|
export interface ListboxRootProps<T extends CollectionItem> extends Assign<HTMLProps<'div'>, ListboxRootBaseProps<T>> {
|
|
9
9
|
}
|
|
10
|
-
export type
|
|
11
|
-
export declare const ListboxRoot:
|
|
10
|
+
export type ListboxRootComponent<P = {}> = <T extends CollectionItem>(props: Assign<ListboxRootProps<T>, P> & React.RefAttributes<HTMLDivElement>) => JSX.Element;
|
|
11
|
+
export declare const ListboxRoot: ListboxRootComponent;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
'use strict';
|
|
3
|
+
|
|
4
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
5
|
+
|
|
6
|
+
const listbox = require('@zag-js/listbox');
|
|
7
|
+
|
|
8
|
+
const listboxAnatomy = listbox.anatomy.extendWith("empty");
|
|
9
|
+
|
|
10
|
+
exports.listboxAnatomy = listboxAnatomy;
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
import { AnatomyInstance } from '@zag-js/anatomy';
|
|
2
|
+
export declare const listboxAnatomy: AnatomyInstance<"input" | "label" | "content" | "root" | "item" | "valueText" | "itemGroup" | "itemGroupLabel" | "itemIndicator" | "itemText" | "empty">;
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
import { AnatomyInstance } from '@zag-js/anatomy';
|
|
2
|
+
export declare const listboxAnatomy: AnatomyInstance<"input" | "label" | "content" | "root" | "item" | "valueText" | "itemGroup" | "itemGroupLabel" | "itemIndicator" | "itemText" | "empty">;
|
|
@@ -4,6 +4,7 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
|
4
4
|
|
|
5
5
|
const listboxContext = require('./listbox-context.cjs');
|
|
6
6
|
const listboxContent = require('./listbox-content.cjs');
|
|
7
|
+
const listboxEmpty = require('./listbox-empty.cjs');
|
|
7
8
|
const listboxInput = require('./listbox-input.cjs');
|
|
8
9
|
const listboxItem = require('./listbox-item.cjs');
|
|
9
10
|
const listboxItemContext = require('./listbox-item-context.cjs');
|
|
@@ -20,6 +21,7 @@ const listboxValueText = require('./listbox-value-text.cjs');
|
|
|
20
21
|
|
|
21
22
|
exports.Context = listboxContext.ListboxContext;
|
|
22
23
|
exports.Content = listboxContent.ListboxContent;
|
|
24
|
+
exports.Empty = listboxEmpty.ListboxEmpty;
|
|
23
25
|
exports.Input = listboxInput.ListboxInput;
|
|
24
26
|
exports.Item = listboxItem.ListboxItem;
|
|
25
27
|
exports.ItemContext = listboxItemContext.ListboxItemContext;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export type { HighlightChangeDetails, ScrollToIndexDetails, SelectionDetails, SelectionMode, ValueChangeDetails, } from '@zag-js/listbox';
|
|
2
2
|
export { ListboxContext as Context, type ListboxContextProps as ContextProps } from './listbox-context';
|
|
3
3
|
export { ListboxContent as Content, type ListboxContentBaseProps as ContentBaseProps, type ListboxContentProps as ContentProps, } from './listbox-content';
|
|
4
|
+
export { ListboxEmpty as Empty, type ListboxEmptyBaseProps as EmptyBaseProps, type ListboxEmptyProps as EmptyProps, } from './listbox-empty';
|
|
4
5
|
export { ListboxInput as Input, type ListboxInputBaseProps as InputBaseProps, type ListboxInputProps as InputProps, } from './listbox-input';
|
|
5
6
|
export { ListboxItem as Item, type ListboxItemBaseProps as ItemBaseProps, type ListboxItemProps as ItemProps, } from './listbox-item';
|
|
6
7
|
export { ListboxItemContext as ItemContext, type ListboxItemContextProps as ItemContextProps, } from './listbox-item-context';
|
|
@@ -9,6 +10,6 @@ export { ListboxItemGroupLabel as ItemGroupLabel, type ListboxItemGroupLabelBase
|
|
|
9
10
|
export { ListboxItemIndicator as ItemIndicator, type ListboxItemIndicatorBaseProps as ItemIndicatorBaseProps, type ListboxItemIndicatorProps as ItemIndicatorProps, } from './listbox-item-indicator';
|
|
10
11
|
export { ListboxItemText as ItemText, type ListboxItemTextBaseProps as ItemTextBaseProps, type ListboxItemTextProps as ItemTextProps, } from './listbox-item-text';
|
|
11
12
|
export { ListboxLabel as Label, type ListboxLabelBaseProps as LabelBaseProps, type ListboxLabelProps as LabelProps, } from './listbox-label';
|
|
12
|
-
export { ListboxRoot as Root, type ListboxRootBaseProps as RootBaseProps, type ListboxRootProps as RootProps, } from './listbox-root';
|
|
13
|
-
export { ListboxRootProvider as RootProvider, type ListboxRootProviderBaseProps as RootProviderBaseProps, type ListboxRootProviderProps as RootProviderProps, } from './listbox-root-provider';
|
|
13
|
+
export { ListboxRoot as Root, type ListboxRootBaseProps as RootBaseProps, type ListboxRootProps as RootProps, type ListboxRootComponent as RootComponent, } from './listbox-root';
|
|
14
|
+
export { ListboxRootProvider as RootProvider, type ListboxRootProviderBaseProps as RootProviderBaseProps, type ListboxRootProviderProps as RootProviderProps, type ListboxRootProviderComponent as RootProviderComponent, } from './listbox-root-provider';
|
|
14
15
|
export { ListboxValueText as ValueText, type ListboxValueTextBaseProps as ValueTextBaseProps, type ListboxValueTextProps as ValueTextProps, } from './listbox-value-text';
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export type { HighlightChangeDetails, ScrollToIndexDetails, SelectionDetails, SelectionMode, ValueChangeDetails, } from '@zag-js/listbox';
|
|
2
2
|
export { ListboxContext as Context, type ListboxContextProps as ContextProps } from './listbox-context';
|
|
3
3
|
export { ListboxContent as Content, type ListboxContentBaseProps as ContentBaseProps, type ListboxContentProps as ContentProps, } from './listbox-content';
|
|
4
|
+
export { ListboxEmpty as Empty, type ListboxEmptyBaseProps as EmptyBaseProps, type ListboxEmptyProps as EmptyProps, } from './listbox-empty';
|
|
4
5
|
export { ListboxInput as Input, type ListboxInputBaseProps as InputBaseProps, type ListboxInputProps as InputProps, } from './listbox-input';
|
|
5
6
|
export { ListboxItem as Item, type ListboxItemBaseProps as ItemBaseProps, type ListboxItemProps as ItemProps, } from './listbox-item';
|
|
6
7
|
export { ListboxItemContext as ItemContext, type ListboxItemContextProps as ItemContextProps, } from './listbox-item-context';
|
|
@@ -9,6 +10,6 @@ export { ListboxItemGroupLabel as ItemGroupLabel, type ListboxItemGroupLabelBase
|
|
|
9
10
|
export { ListboxItemIndicator as ItemIndicator, type ListboxItemIndicatorBaseProps as ItemIndicatorBaseProps, type ListboxItemIndicatorProps as ItemIndicatorProps, } from './listbox-item-indicator';
|
|
10
11
|
export { ListboxItemText as ItemText, type ListboxItemTextBaseProps as ItemTextBaseProps, type ListboxItemTextProps as ItemTextProps, } from './listbox-item-text';
|
|
11
12
|
export { ListboxLabel as Label, type ListboxLabelBaseProps as LabelBaseProps, type ListboxLabelProps as LabelProps, } from './listbox-label';
|
|
12
|
-
export { ListboxRoot as Root, type ListboxRootBaseProps as RootBaseProps, type ListboxRootProps as RootProps, } from './listbox-root';
|
|
13
|
-
export { ListboxRootProvider as RootProvider, type ListboxRootProviderBaseProps as RootProviderBaseProps, type ListboxRootProviderProps as RootProviderProps, } from './listbox-root-provider';
|
|
13
|
+
export { ListboxRoot as Root, type ListboxRootBaseProps as RootBaseProps, type ListboxRootProps as RootProps, type ListboxRootComponent as RootComponent, } from './listbox-root';
|
|
14
|
+
export { ListboxRootProvider as RootProvider, type ListboxRootProviderBaseProps as RootProviderBaseProps, type ListboxRootProviderProps as RootProviderProps, type ListboxRootProviderComponent as RootProviderComponent, } from './listbox-root-provider';
|
|
14
15
|
export { ListboxValueText as ValueText, type ListboxValueTextBaseProps as ValueTextBaseProps, type ListboxValueTextProps as ValueTextProps, } from './listbox-value-text';
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export { ListboxContext as Context } from './listbox-context.js';
|
|
2
2
|
export { ListboxContent as Content } from './listbox-content.js';
|
|
3
|
+
export { ListboxEmpty as Empty } from './listbox-empty.js';
|
|
3
4
|
export { ListboxInput as Input } from './listbox-input.js';
|
|
4
5
|
export { ListboxItem as Item } from './listbox-item.js';
|
|
5
6
|
export { ListboxItemContext as ItemContext } from './listbox-item-context.js';
|
|
@@ -8,11 +8,12 @@ const react$1 = require('@zag-js/react');
|
|
|
8
8
|
const react = require('react');
|
|
9
9
|
const factory = require('../factory.cjs');
|
|
10
10
|
const useMenuTriggerItemContext = require('./use-menu-trigger-item-context.cjs');
|
|
11
|
+
const useMenuOptionItemPropsContext = require('./use-menu-option-item-props-context.cjs');
|
|
11
12
|
|
|
12
13
|
const MenuTriggerItem = react.forwardRef((props, ref) => {
|
|
13
14
|
const getTriggerItemProps = useMenuTriggerItemContext.useMenuTriggerItemContext();
|
|
14
15
|
const mergedProps = react$1.mergeProps(getTriggerItemProps?.() ?? {}, props);
|
|
15
|
-
return /* @__PURE__ */ jsxRuntime.jsx(factory.ark.div, { ...mergedProps, ref });
|
|
16
|
+
return /* @__PURE__ */ jsxRuntime.jsx(useMenuOptionItemPropsContext.MenuItemPropsProvider, { value: { value: mergedProps["data-value"] }, children: /* @__PURE__ */ jsxRuntime.jsx(factory.ark.div, { ...mergedProps, ref }) });
|
|
16
17
|
});
|
|
17
18
|
MenuTriggerItem.displayName = "MenuTriggerItem";
|
|
18
19
|
|
|
@@ -4,11 +4,12 @@ import { mergeProps } from '@zag-js/react';
|
|
|
4
4
|
import { forwardRef } from 'react';
|
|
5
5
|
import { ark } from '../factory.js';
|
|
6
6
|
import { useMenuTriggerItemContext } from './use-menu-trigger-item-context.js';
|
|
7
|
+
import { MenuItemPropsProvider } from './use-menu-option-item-props-context.js';
|
|
7
8
|
|
|
8
9
|
const MenuTriggerItem = forwardRef((props, ref) => {
|
|
9
10
|
const getTriggerItemProps = useMenuTriggerItemContext();
|
|
10
11
|
const mergedProps = mergeProps(getTriggerItemProps?.() ?? {}, props);
|
|
11
|
-
return /* @__PURE__ */ jsx(ark.div, { ...mergedProps, ref });
|
|
12
|
+
return /* @__PURE__ */ jsx(MenuItemPropsProvider, { value: { value: mergedProps["data-value"] }, children: /* @__PURE__ */ jsx(ark.div, { ...mergedProps, ref }) });
|
|
12
13
|
});
|
|
13
14
|
MenuTriggerItem.displayName = "MenuTriggerItem";
|
|
14
15
|
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { Anatomy, AnatomyPart } from '@zag-js/anatomy';
|
|
2
|
-
export declare const segmentGroupAnatomy: Anatomy<"label" | "root" | "item" | "indicator" | "
|
|
3
|
-
export declare const parts: Record<"label" | "root" | "item" | "indicator" | "
|
|
2
|
+
export declare const segmentGroupAnatomy: Anatomy<"label" | "root" | "item" | "indicator" | "itemText" | "itemControl">;
|
|
3
|
+
export declare const parts: Record<"label" | "root" | "item" | "indicator" | "itemText" | "itemControl", AnatomyPart>;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { Anatomy, AnatomyPart } from '@zag-js/anatomy';
|
|
2
|
-
export declare const segmentGroupAnatomy: Anatomy<"label" | "root" | "item" | "indicator" | "
|
|
3
|
-
export declare const parts: Record<"label" | "root" | "item" | "indicator" | "
|
|
2
|
+
export declare const segmentGroupAnatomy: Anatomy<"label" | "root" | "item" | "indicator" | "itemText" | "itemControl">;
|
|
3
|
+
export declare const parts: Record<"label" | "root" | "item" | "indicator" | "itemText" | "itemControl", AnatomyPart>;
|
|
@@ -15,8 +15,8 @@ export { SelectItemText, type SelectItemTextBaseProps, type SelectItemTextProps
|
|
|
15
15
|
export { SelectLabel, type SelectLabelBaseProps, type SelectLabelProps } from './select-label';
|
|
16
16
|
export { SelectList, type SelectListBaseProps, type SelectListProps } from './select-list';
|
|
17
17
|
export { SelectPositioner, type SelectPositionerBaseProps, type SelectPositionerProps } from './select-positioner';
|
|
18
|
-
export { SelectRoot, type SelectRootBaseProps, type SelectRootProps } from './select-root';
|
|
19
|
-
export { SelectRootProvider, type SelectRootProviderBaseProps, type SelectRootProviderProps, } from './select-root-provider';
|
|
18
|
+
export { SelectRoot, type SelectRootBaseProps, type SelectRootProps, type SelectRootComponent } from './select-root';
|
|
19
|
+
export { SelectRootProvider, type SelectRootProviderBaseProps, type SelectRootProviderProps, type SelectRootProviderComponent, } from './select-root-provider';
|
|
20
20
|
export { SelectTrigger, type SelectTriggerBaseProps, type SelectTriggerProps } from './select-trigger';
|
|
21
21
|
export { SelectValueText, type SelectValueTextBaseProps, type SelectValueTextProps } from './select-value-text';
|
|
22
22
|
export { selectAnatomy } from './select.anatomy';
|
|
@@ -15,8 +15,8 @@ export { SelectItemText, type SelectItemTextBaseProps, type SelectItemTextProps
|
|
|
15
15
|
export { SelectLabel, type SelectLabelBaseProps, type SelectLabelProps } from './select-label';
|
|
16
16
|
export { SelectList, type SelectListBaseProps, type SelectListProps } from './select-list';
|
|
17
17
|
export { SelectPositioner, type SelectPositionerBaseProps, type SelectPositionerProps } from './select-positioner';
|
|
18
|
-
export { SelectRoot, type SelectRootBaseProps, type SelectRootProps } from './select-root';
|
|
19
|
-
export { SelectRootProvider, type SelectRootProviderBaseProps, type SelectRootProviderProps, } from './select-root-provider';
|
|
18
|
+
export { SelectRoot, type SelectRootBaseProps, type SelectRootProps, type SelectRootComponent } from './select-root';
|
|
19
|
+
export { SelectRootProvider, type SelectRootProviderBaseProps, type SelectRootProviderProps, type SelectRootProviderComponent, } from './select-root-provider';
|
|
20
20
|
export { SelectTrigger, type SelectTriggerBaseProps, type SelectTriggerProps } from './select-trigger';
|
|
21
21
|
export { SelectValueText, type SelectValueTextBaseProps, type SelectValueTextProps } from './select-value-text';
|
|
22
22
|
export { selectAnatomy } from './select.anatomy';
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { JSX } from 'react';
|
|
2
|
+
import { Assign } from '../../types';
|
|
2
3
|
import { CollectionItem } from '../collection';
|
|
3
4
|
import { HTMLProps, PolymorphicProps } from '../factory';
|
|
4
5
|
import { UsePresenceProps } from '../presence';
|
|
@@ -10,6 +11,6 @@ export interface SelectRootProviderBaseProps<T extends CollectionItem> extends R
|
|
|
10
11
|
}
|
|
11
12
|
export interface SelectRootProviderProps<T extends CollectionItem> extends HTMLProps<'div'>, SelectRootProviderBaseProps<T> {
|
|
12
13
|
}
|
|
13
|
-
export type
|
|
14
|
-
export declare const SelectRootProvider:
|
|
14
|
+
export type SelectRootProviderComponent<P = {}> = <T extends CollectionItem>(props: Assign<SelectRootProviderProps<T>, P> & React.RefAttributes<HTMLDivElement>) => JSX.Element;
|
|
15
|
+
export declare const SelectRootProvider: SelectRootProviderComponent;
|
|
15
16
|
export {};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { JSX } from 'react';
|
|
2
|
+
import { Assign } from '../../types';
|
|
2
3
|
import { CollectionItem } from '../collection';
|
|
3
4
|
import { HTMLProps, PolymorphicProps } from '../factory';
|
|
4
5
|
import { UsePresenceProps } from '../presence';
|
|
@@ -10,6 +11,6 @@ export interface SelectRootProviderBaseProps<T extends CollectionItem> extends R
|
|
|
10
11
|
}
|
|
11
12
|
export interface SelectRootProviderProps<T extends CollectionItem> extends HTMLProps<'div'>, SelectRootProviderBaseProps<T> {
|
|
12
13
|
}
|
|
13
|
-
export type
|
|
14
|
-
export declare const SelectRootProvider:
|
|
14
|
+
export type SelectRootProviderComponent<P = {}> = <T extends CollectionItem>(props: Assign<SelectRootProviderProps<T>, P> & React.RefAttributes<HTMLDivElement>) => JSX.Element;
|
|
15
|
+
export declare const SelectRootProvider: SelectRootProviderComponent;
|
|
15
16
|
export {};
|
|
@@ -8,5 +8,5 @@ export interface SelectRootBaseProps<T extends CollectionItem> extends UseSelect
|
|
|
8
8
|
}
|
|
9
9
|
export interface SelectRootProps<T extends CollectionItem> extends Assign<HTMLProps<'div'>, SelectRootBaseProps<T>> {
|
|
10
10
|
}
|
|
11
|
-
export type
|
|
12
|
-
export declare const SelectRoot:
|
|
11
|
+
export type SelectRootComponent<P = {}> = <T extends CollectionItem>(props: Assign<SelectRootProps<T>, P> & React.RefAttributes<HTMLDivElement>) => JSX.Element;
|
|
12
|
+
export declare const SelectRoot: SelectRootComponent;
|
|
@@ -8,5 +8,5 @@ export interface SelectRootBaseProps<T extends CollectionItem> extends UseSelect
|
|
|
8
8
|
}
|
|
9
9
|
export interface SelectRootProps<T extends CollectionItem> extends Assign<HTMLProps<'div'>, SelectRootBaseProps<T>> {
|
|
10
10
|
}
|
|
11
|
-
export type
|
|
12
|
-
export declare const SelectRoot:
|
|
11
|
+
export type SelectRootComponent<P = {}> = <T extends CollectionItem>(props: Assign<SelectRootProps<T>, P> & React.RefAttributes<HTMLDivElement>) => JSX.Element;
|
|
12
|
+
export declare const SelectRoot: SelectRootComponent;
|
|
@@ -15,7 +15,7 @@ export { SelectItemText as ItemText, type SelectItemTextBaseProps as ItemTextBas
|
|
|
15
15
|
export { SelectLabel as Label, type SelectLabelBaseProps as LabelBaseProps, type SelectLabelProps as LabelProps, } from './select-label';
|
|
16
16
|
export { SelectList as List, type SelectListBaseProps as ListBaseProps, type SelectListProps as ListProps, } from './select-list';
|
|
17
17
|
export { SelectPositioner as Positioner, type SelectPositionerBaseProps as PositionerBaseProps, type SelectPositionerProps as PositionerProps, } from './select-positioner';
|
|
18
|
-
export { SelectRoot as Root, type SelectRootBaseProps as RootBaseProps, type SelectRootProps as RootProps, } from './select-root';
|
|
19
|
-
export { SelectRootProvider as RootProvider, type SelectRootProviderBaseProps as RootProviderBaseProps, type SelectRootProviderProps as RootProviderProps, } from './select-root-provider';
|
|
18
|
+
export { SelectRoot as Root, type SelectRootBaseProps as RootBaseProps, type SelectRootProps as RootProps, type SelectRootComponent as RootComponent, } from './select-root';
|
|
19
|
+
export { SelectRootProvider as RootProvider, type SelectRootProviderBaseProps as RootProviderBaseProps, type SelectRootProviderProps as RootProviderProps, type SelectRootProviderComponent as RootProviderComponent, } from './select-root-provider';
|
|
20
20
|
export { SelectTrigger as Trigger, type SelectTriggerBaseProps as TriggerBaseProps, type SelectTriggerProps as TriggerProps, } from './select-trigger';
|
|
21
21
|
export { SelectValueText as ValueText, type SelectValueTextBaseProps as ValueTextBaseProps, type SelectValueTextProps as ValueTextProps, } from './select-value-text';
|
|
@@ -15,7 +15,7 @@ export { SelectItemText as ItemText, type SelectItemTextBaseProps as ItemTextBas
|
|
|
15
15
|
export { SelectLabel as Label, type SelectLabelBaseProps as LabelBaseProps, type SelectLabelProps as LabelProps, } from './select-label';
|
|
16
16
|
export { SelectList as List, type SelectListBaseProps as ListBaseProps, type SelectListProps as ListProps, } from './select-list';
|
|
17
17
|
export { SelectPositioner as Positioner, type SelectPositionerBaseProps as PositionerBaseProps, type SelectPositionerProps as PositionerProps, } from './select-positioner';
|
|
18
|
-
export { SelectRoot as Root, type SelectRootBaseProps as RootBaseProps, type SelectRootProps as RootProps, } from './select-root';
|
|
19
|
-
export { SelectRootProvider as RootProvider, type SelectRootProviderBaseProps as RootProviderBaseProps, type SelectRootProviderProps as RootProviderProps, } from './select-root-provider';
|
|
18
|
+
export { SelectRoot as Root, type SelectRootBaseProps as RootBaseProps, type SelectRootProps as RootProps, type SelectRootComponent as RootComponent, } from './select-root';
|
|
19
|
+
export { SelectRootProvider as RootProvider, type SelectRootProviderBaseProps as RootProviderBaseProps, type SelectRootProviderProps as RootProviderProps, type SelectRootProviderComponent as RootProviderComponent, } from './select-root-provider';
|
|
20
20
|
export { SelectTrigger as Trigger, type SelectTriggerBaseProps as TriggerBaseProps, type SelectTriggerProps as TriggerProps, } from './select-trigger';
|
|
21
21
|
export { SelectValueText as ValueText, type SelectValueTextBaseProps as ValueTextBaseProps, type SelectValueTextProps as ValueTextProps, } from './select-value-text';
|
|
@@ -14,8 +14,8 @@ export { TreeViewItemText, type TreeViewItemTextBaseProps, type TreeViewItemText
|
|
|
14
14
|
export { TreeViewLabel, type TreeViewLabelBaseProps, type TreeViewLabelProps } from './tree-view-label';
|
|
15
15
|
export { TreeViewNodeContext, type TreeViewNodeContextProps } from './tree-view-node-context';
|
|
16
16
|
export { TreeViewNodeProvider, type TreeViewNodeProviderBaseProps, type TreeViewNodeProviderProps, } from './tree-view-node-provider';
|
|
17
|
-
export { TreeViewRoot, type TreeViewRootBaseProps, type TreeViewRootProps } from './tree-view-root';
|
|
18
|
-
export { TreeViewRootProvider, type TreeViewRootProviderBaseProps, type TreeViewRootProviderProps, } from './tree-view-root-provider';
|
|
17
|
+
export { TreeViewRoot, type TreeViewRootBaseProps, type TreeViewRootComponent, type TreeViewRootProps, } from './tree-view-root';
|
|
18
|
+
export { TreeViewRootProvider, type TreeViewRootProviderBaseProps, type TreeViewRootProviderComponent, type TreeViewRootProviderProps, } from './tree-view-root-provider';
|
|
19
19
|
export { TreeViewTree, type TreeViewTreeBaseProps, type TreeViewTreeProps } from './tree-view-tree';
|
|
20
20
|
export { TreeViewNodeCheckbox, type TreeViewNodeCheckboxBaseProps, type TreeViewNodeCheckboxProps, } from './tree-view-node-checkbox';
|
|
21
21
|
export { TreeViewNodeCheckboxIndicator, type TreeViewNodeCheckboxIndicatorBaseProps, type TreeViewNodeCheckboxIndicatorProps, } from './tree-view-node-checkbox-indicator';
|
|
@@ -14,8 +14,8 @@ export { TreeViewItemText, type TreeViewItemTextBaseProps, type TreeViewItemText
|
|
|
14
14
|
export { TreeViewLabel, type TreeViewLabelBaseProps, type TreeViewLabelProps } from './tree-view-label';
|
|
15
15
|
export { TreeViewNodeContext, type TreeViewNodeContextProps } from './tree-view-node-context';
|
|
16
16
|
export { TreeViewNodeProvider, type TreeViewNodeProviderBaseProps, type TreeViewNodeProviderProps, } from './tree-view-node-provider';
|
|
17
|
-
export { TreeViewRoot, type TreeViewRootBaseProps, type TreeViewRootProps } from './tree-view-root';
|
|
18
|
-
export { TreeViewRootProvider, type TreeViewRootProviderBaseProps, type TreeViewRootProviderProps, } from './tree-view-root-provider';
|
|
17
|
+
export { TreeViewRoot, type TreeViewRootBaseProps, type TreeViewRootComponent, type TreeViewRootProps, } from './tree-view-root';
|
|
18
|
+
export { TreeViewRootProvider, type TreeViewRootProviderBaseProps, type TreeViewRootProviderComponent, type TreeViewRootProviderProps, } from './tree-view-root-provider';
|
|
19
19
|
export { TreeViewTree, type TreeViewTreeBaseProps, type TreeViewTreeProps } from './tree-view-tree';
|
|
20
20
|
export { TreeViewNodeCheckbox, type TreeViewNodeCheckboxBaseProps, type TreeViewNodeCheckboxProps, } from './tree-view-node-checkbox';
|
|
21
21
|
export { TreeViewNodeCheckboxIndicator, type TreeViewNodeCheckboxIndicatorBaseProps, type TreeViewNodeCheckboxIndicatorProps, } from './tree-view-node-checkbox-indicator';
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { JSX } from 'react';
|
|
2
|
+
import { Assign } from '../../types';
|
|
2
3
|
import { RenderStrategyProps } from '../../utils/render-strategy';
|
|
3
4
|
import { TreeNode } from '../collection';
|
|
4
5
|
import { HTMLProps, PolymorphicProps } from '../factory';
|
|
@@ -10,6 +11,6 @@ export interface TreeViewRootProviderBaseProps<T extends TreeNode> extends RootP
|
|
|
10
11
|
}
|
|
11
12
|
export interface TreeViewRootProviderProps<T extends TreeNode> extends HTMLProps<'div'>, TreeViewRootProviderBaseProps<T> {
|
|
12
13
|
}
|
|
13
|
-
export type
|
|
14
|
-
export declare const TreeViewRootProvider:
|
|
14
|
+
export type TreeViewRootProviderComponent<P = {}> = <T extends TreeNode>(props: Assign<TreeViewRootProviderProps<T>, P> & React.RefAttributes<HTMLDivElement>) => JSX.Element;
|
|
15
|
+
export declare const TreeViewRootProvider: TreeViewRootProviderComponent;
|
|
15
16
|
export {};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { JSX } from 'react';
|
|
2
|
+
import { Assign } from '../../types';
|
|
2
3
|
import { RenderStrategyProps } from '../../utils/render-strategy';
|
|
3
4
|
import { TreeNode } from '../collection';
|
|
4
5
|
import { HTMLProps, PolymorphicProps } from '../factory';
|
|
@@ -10,6 +11,6 @@ export interface TreeViewRootProviderBaseProps<T extends TreeNode> extends RootP
|
|
|
10
11
|
}
|
|
11
12
|
export interface TreeViewRootProviderProps<T extends TreeNode> extends HTMLProps<'div'>, TreeViewRootProviderBaseProps<T> {
|
|
12
13
|
}
|
|
13
|
-
export type
|
|
14
|
-
export declare const TreeViewRootProvider:
|
|
14
|
+
export type TreeViewRootProviderComponent<P = {}> = <T extends TreeNode>(props: Assign<TreeViewRootProviderProps<T>, P> & React.RefAttributes<HTMLDivElement>) => JSX.Element;
|
|
15
|
+
export declare const TreeViewRootProvider: TreeViewRootProviderComponent;
|
|
15
16
|
export {};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { JSX } from 'react';
|
|
2
|
+
import { Assign } from '../../types';
|
|
2
3
|
import { RenderStrategyProps } from '../../utils/render-strategy';
|
|
3
4
|
import { TreeNode } from '../collection';
|
|
4
5
|
import { HTMLProps, PolymorphicProps } from '../factory';
|
|
@@ -7,5 +8,5 @@ export interface TreeViewRootBaseProps<T extends TreeNode> extends UseTreeViewPr
|
|
|
7
8
|
}
|
|
8
9
|
export interface TreeViewRootProps<T extends TreeNode> extends HTMLProps<'div'>, TreeViewRootBaseProps<T> {
|
|
9
10
|
}
|
|
10
|
-
export type
|
|
11
|
-
export declare const TreeViewRoot:
|
|
11
|
+
export type TreeViewRootComponent<P = {}> = <T extends TreeNode>(props: Assign<TreeViewRootProps<T>, P> & React.RefAttributes<HTMLDivElement>) => JSX.Element;
|
|
12
|
+
export declare const TreeViewRoot: TreeViewRootComponent;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { JSX } from 'react';
|
|
2
|
+
import { Assign } from '../../types';
|
|
2
3
|
import { RenderStrategyProps } from '../../utils/render-strategy';
|
|
3
4
|
import { TreeNode } from '../collection';
|
|
4
5
|
import { HTMLProps, PolymorphicProps } from '../factory';
|
|
@@ -7,5 +8,5 @@ export interface TreeViewRootBaseProps<T extends TreeNode> extends UseTreeViewPr
|
|
|
7
8
|
}
|
|
8
9
|
export interface TreeViewRootProps<T extends TreeNode> extends HTMLProps<'div'>, TreeViewRootBaseProps<T> {
|
|
9
10
|
}
|
|
10
|
-
export type
|
|
11
|
-
export declare const TreeViewRoot:
|
|
11
|
+
export type TreeViewRootComponent<P = {}> = <T extends TreeNode>(props: Assign<TreeViewRootProps<T>, P> & React.RefAttributes<HTMLDivElement>) => JSX.Element;
|
|
12
|
+
export declare const TreeViewRoot: TreeViewRootComponent;
|
|
@@ -13,8 +13,8 @@ export { TreeViewItemText as ItemText, type TreeViewItemTextBaseProps as ItemTex
|
|
|
13
13
|
export { TreeViewLabel as Label, type TreeViewLabelBaseProps as LabelBaseProps, type TreeViewLabelProps as LabelProps, } from './tree-view-label';
|
|
14
14
|
export { TreeViewNodeContext as NodeContext, type TreeViewNodeContextProps as NodeContextProps, } from './tree-view-node-context';
|
|
15
15
|
export { TreeViewNodeProvider as NodeProvider, type TreeViewNodeProviderBaseProps as NodeProviderBaseProps, type TreeViewNodeProviderProps as NodeProviderProps, } from './tree-view-node-provider';
|
|
16
|
-
export { TreeViewRoot as Root, type TreeViewRootBaseProps as RootBaseProps, type TreeViewRootProps as RootProps, } from './tree-view-root';
|
|
17
|
-
export { TreeViewRootProvider as RootProvider, type TreeViewRootProviderBaseProps as RootProviderBaseProps, type TreeViewRootProviderProps as RootProviderProps, } from './tree-view-root-provider';
|
|
16
|
+
export { TreeViewRoot as Root, type TreeViewRootBaseProps as RootBaseProps, type TreeViewRootComponent as RootComponent, type TreeViewRootProps as RootProps, } from './tree-view-root';
|
|
17
|
+
export { TreeViewRootProvider as RootProvider, type TreeViewRootProviderBaseProps as RootProviderBaseProps, type TreeViewRootProviderComponent as RootProviderComponent, type TreeViewRootProviderProps as RootProviderProps, } from './tree-view-root-provider';
|
|
18
18
|
export { TreeViewTree as Tree, type TreeViewTreeBaseProps as TreeBaseProps, type TreeViewTreeProps as TreeProps, } from './tree-view-tree';
|
|
19
19
|
export { TreeViewNodeCheckbox as NodeCheckbox, type TreeViewNodeCheckboxBaseProps as NodeCheckboxBaseProps, type TreeViewNodeCheckboxProps as NodeCheckboxProps, } from './tree-view-node-checkbox';
|
|
20
20
|
export { TreeViewNodeCheckboxIndicator as NodeCheckboxIndicator, type TreeViewNodeCheckboxIndicatorBaseProps as NodeCheckboxIndicatorBaseProps, type TreeViewNodeCheckboxIndicatorProps as NodeCheckboxIndicatorProps, } from './tree-view-node-checkbox-indicator';
|
|
@@ -13,8 +13,8 @@ export { TreeViewItemText as ItemText, type TreeViewItemTextBaseProps as ItemTex
|
|
|
13
13
|
export { TreeViewLabel as Label, type TreeViewLabelBaseProps as LabelBaseProps, type TreeViewLabelProps as LabelProps, } from './tree-view-label';
|
|
14
14
|
export { TreeViewNodeContext as NodeContext, type TreeViewNodeContextProps as NodeContextProps, } from './tree-view-node-context';
|
|
15
15
|
export { TreeViewNodeProvider as NodeProvider, type TreeViewNodeProviderBaseProps as NodeProviderBaseProps, type TreeViewNodeProviderProps as NodeProviderProps, } from './tree-view-node-provider';
|
|
16
|
-
export { TreeViewRoot as Root, type TreeViewRootBaseProps as RootBaseProps, type TreeViewRootProps as RootProps, } from './tree-view-root';
|
|
17
|
-
export { TreeViewRootProvider as RootProvider, type TreeViewRootProviderBaseProps as RootProviderBaseProps, type TreeViewRootProviderProps as RootProviderProps, } from './tree-view-root-provider';
|
|
16
|
+
export { TreeViewRoot as Root, type TreeViewRootBaseProps as RootBaseProps, type TreeViewRootComponent as RootComponent, type TreeViewRootProps as RootProps, } from './tree-view-root';
|
|
17
|
+
export { TreeViewRootProvider as RootProvider, type TreeViewRootProviderBaseProps as RootProviderBaseProps, type TreeViewRootProviderComponent as RootProviderComponent, type TreeViewRootProviderProps as RootProviderProps, } from './tree-view-root-provider';
|
|
18
18
|
export { TreeViewTree as Tree, type TreeViewTreeBaseProps as TreeBaseProps, type TreeViewTreeProps as TreeProps, } from './tree-view-tree';
|
|
19
19
|
export { TreeViewNodeCheckbox as NodeCheckbox, type TreeViewNodeCheckboxBaseProps as NodeCheckboxBaseProps, type TreeViewNodeCheckboxProps as NodeCheckboxProps, } from './tree-view-node-checkbox';
|
|
20
20
|
export { TreeViewNodeCheckboxIndicator as NodeCheckboxIndicator, type TreeViewNodeCheckboxIndicatorBaseProps as NodeCheckboxIndicatorBaseProps, type TreeViewNodeCheckboxIndicatorProps as NodeCheckboxIndicatorProps, } from './tree-view-node-checkbox-indicator';
|