@yamada-ui/react 2.3.4-dev-20261114103548 → 2.3.4-dev-20261114185317
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/cjs/components/switch/use-switch.cjs +18 -25
- package/dist/cjs/components/switch/use-switch.cjs.map +1 -1
- package/dist/esm/components/switch/use-switch.js +18 -25
- package/dist/esm/components/switch/use-switch.js.map +1 -1
- package/dist/types/components/avatar/avatar.d.ts +3 -3
- package/dist/types/components/avatar/avatar.style.d.ts +1 -1
- package/dist/types/components/carousel/carousel.style.d.ts +2 -2
- package/dist/types/components/field/field.style.d.ts +2 -2
- package/dist/types/components/fieldset/fieldset.style.d.ts +1 -1
- package/dist/types/components/menu/menu.style.d.ts +2 -2
- package/dist/types/components/segmented-control/segmented-control.style.d.ts +2 -2
- package/dist/types/components/steps/steps.style.d.ts +1 -1
- package/dist/types/components/timeline/timeline.d.ts +1 -1
- package/dist/types/components/timeline/timeline.style.d.ts +1 -1
- package/dist/types/components/tree/tree.style.d.ts +1 -1
- package/package.json +1 -1
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
const require_dom = require("../../utils/dom.cjs");
|
|
3
|
-
const require_ref = require("../../utils/ref.cjs");
|
|
4
3
|
const require_utils_index = require("../../utils/index.cjs");
|
|
5
4
|
const require_props = require("../../core/components/props.cjs");
|
|
6
5
|
const require_hooks_use_controllable_state_index = require("../../hooks/use-controllable-state/index.cjs");
|
|
@@ -41,30 +40,24 @@ const useSwitch = (props = {}) => {
|
|
|
41
40
|
const getThumbProps = (0, react.useCallback)((props = {}) => require_props.mergeProps(dataProps, { "data-checked": (0, require_utils_index.utils_exports.dataAttr)(checked) }, props)(), [checked, dataProps]);
|
|
42
41
|
return {
|
|
43
42
|
checked,
|
|
44
|
-
getInputProps: (0, react.useCallback)((props = {}) => {
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
onChange,
|
|
63
|
-
onKeyDown
|
|
64
|
-
})({ mergeRef: false }),
|
|
65
|
-
ref: require_ref.mergeRefs(inputRef, props.ref, ref)
|
|
66
|
-
};
|
|
67
|
-
}, [
|
|
43
|
+
getInputProps: (0, react.useCallback)((props = {}) => require_props.mergeProps(ariaProps, dataProps, eventProps, {
|
|
44
|
+
id,
|
|
45
|
+
ref: inputRef,
|
|
46
|
+
type: "checkbox",
|
|
47
|
+
name,
|
|
48
|
+
style: require_dom.visuallyHiddenAttributes.style,
|
|
49
|
+
checked,
|
|
50
|
+
disabled,
|
|
51
|
+
readOnly,
|
|
52
|
+
required,
|
|
53
|
+
role: "switch",
|
|
54
|
+
tabIndex: interactive ? 0 : -1,
|
|
55
|
+
value
|
|
56
|
+
}, props, {
|
|
57
|
+
ref,
|
|
58
|
+
onChange,
|
|
59
|
+
onKeyDown
|
|
60
|
+
})(), [
|
|
68
61
|
ariaProps,
|
|
69
62
|
dataProps,
|
|
70
63
|
id,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"use-switch.cjs","names":["useId","useFieldProps","useRef","useControllableState","useCallback","mergeProps","visuallyHiddenAttributes"
|
|
1
|
+
{"version":3,"file":"use-switch.cjs","names":["useId","useFieldProps","useRef","useControllableState","useCallback","mergeProps","visuallyHiddenAttributes"],"sources":["../../../../src/components/switch/use-switch.ts"],"sourcesContent":["\"use client\"\n\nimport type {\n ChangeEvent,\n ChangeEventHandler,\n FocusEventHandler,\n KeyboardEvent,\n} from \"react\"\nimport type { HTMLProps, HTMLRefAttributes, PropGetter } from \"../../core\"\nimport type { FieldProps } from \"../field\"\nimport { useCallback, useId, useRef } from \"react\"\nimport { mergeProps } from \"../../core\"\nimport { useControllableState } from \"../../hooks/use-controllable-state\"\nimport { dataAttr, visuallyHiddenAttributes } from \"../../utils\"\nimport { useFieldProps } from \"../field\"\n\nexport interface UseSwitchProps<Y extends number | string = string>\n extends\n Omit<HTMLProps<\"label\">, \"onBlur\" | \"onChange\" | \"onFocus\" | \"ref\">,\n HTMLRefAttributes<\"input\">,\n FieldProps {\n /**\n * If `true`, the switch will be checked.\n *\n * @default false\n */\n checked?: boolean\n /**\n * If `true`, the switch will be checked when the Enter key is pressed.\n *\n * @default true\n */\n checkOnEnter?: boolean\n /**\n * If `true`, the switch will be initially checked.\n *\n * @default false\n */\n defaultChecked?: boolean\n /**\n * id assigned to input.\n */\n id?: string\n /**\n * The HTML `name` attribute used for forms.\n */\n name?: string\n /**\n * The tab-index property of the underlying input element.\n */\n tabIndex?: number\n /**\n * The value to be used in the switch input.\n */\n value?: Y\n /**\n * The callback invoked when the switch is blurred.\n */\n onBlur?: FocusEventHandler<HTMLInputElement>\n /**\n * The callback invoked when the checked state changes.\n */\n onChange?: ChangeEventHandler<HTMLInputElement>\n /**\n * The callback invoked when the switch is focused.\n */\n onFocus?: FocusEventHandler<HTMLInputElement>\n}\n\nexport const useSwitch = <Y extends number | string = string>(\n props: UseSwitchProps<Y> = {},\n) => {\n const uuid = useId()\n const {\n props: {\n id = uuid,\n ref,\n name,\n checked: checkedProp,\n checkOnEnter = true,\n defaultChecked = false,\n disabled,\n readOnly,\n required,\n value,\n onChange: onChangeProp,\n ...rest\n },\n ariaProps,\n dataProps,\n eventProps,\n } = useFieldProps(props)\n const interactive = !(readOnly || disabled)\n const inputRef = useRef<HTMLInputElement>(null)\n const [checked, setChecked] = useControllableState({\n defaultValue: defaultChecked,\n value: checkedProp,\n })\n\n const onChange = useCallback(\n (ev: ChangeEvent<HTMLInputElement>) => {\n if (!interactive) return ev.preventDefault()\n\n setChecked(ev.target.checked)\n onChangeProp?.(ev)\n },\n [onChangeProp, setChecked, interactive],\n )\n\n const onKeyDown = useCallback(\n (ev: KeyboardEvent<HTMLInputElement>) => {\n if (interactive && checkOnEnter && ev.key === \"Enter\")\n inputRef.current?.click()\n },\n [interactive, checkOnEnter],\n )\n\n const getRootProps: PropGetter<\"label\"> = useCallback(\n (props = {}) =>\n mergeProps(\n dataProps,\n { htmlFor: id, \"data-checked\": dataAttr(checked) },\n rest,\n props,\n )(),\n [checked, rest, id, dataProps],\n )\n\n const getTrackProps: PropGetter = useCallback(\n (props = {}) =>\n mergeProps(dataProps, { \"data-checked\": dataAttr(checked) }, props)(),\n [checked, dataProps],\n )\n\n const getThumbProps: PropGetter = useCallback(\n (props = {}) =>\n mergeProps(dataProps, { \"data-checked\": dataAttr(checked) }, props)(),\n [checked, dataProps],\n )\n\n const getInputProps: PropGetter<\"input\"> = useCallback(\n (props = {}) =>\n mergeProps(\n ariaProps,\n dataProps,\n eventProps,\n {\n id,\n ref: inputRef,\n type: \"checkbox\",\n name,\n style: visuallyHiddenAttributes.style,\n checked,\n disabled,\n readOnly,\n required,\n role: \"switch\",\n tabIndex: interactive ? 0 : -1,\n value,\n },\n props,\n { ref, onChange, onKeyDown },\n )(),\n [\n ariaProps,\n dataProps,\n id,\n name,\n checked,\n disabled,\n readOnly,\n required,\n interactive,\n value,\n ref,\n eventProps,\n onChange,\n onKeyDown,\n ],\n )\n\n const getLabelProps: PropGetter<\"span\"> = useCallback(\n (props = {}) =>\n mergeProps(dataProps, { \"data-checked\": dataAttr(checked) }, props)(),\n [dataProps, checked],\n )\n\n return {\n checked,\n getInputProps,\n getLabelProps,\n getRootProps,\n getThumbProps,\n getTrackProps,\n }\n}\n\nexport type UseSwitchReturn = ReturnType<typeof useSwitch>\n"],"mappings":";;;;;;;;AAqEA,MAAa,aACX,QAA2B,CAAC,MACzB;CACH,MAAM,QAAA,GAAOA,MAAAA,MAAAA,CAAM;CACnB,MAAM,EACJ,OAAO,EACL,KAAK,MACL,KACA,MACA,SAAS,aACT,eAAe,MACf,iBAAiB,OACjB,UACA,UACA,UACA,OACA,UAAU,cACV,GAAG,QAEL,WAC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AC,MACRC,cAAAA,WACE,WACA,WACA,YACA;GACE;GACA,KAAK;GACL,MAAM;GACN;GACA,OAAOC,YAAAA,yBAAyB;GAChC;GACA;GACA;GACA;GACA,MAAM;GACN,UAAU,cAAc,IAAI;GAC5B;EACF,GACA,OACA;GAAE;GAAK;GAAU;EAAU,CAC7B,CAAC,CAAC,GACJ;GACE;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;EACF,CAWY;EACZ,gBAAA,GATwCF,MAAAA,YAAAA,EACvC,QAAQ,CAAC,MACRC,cAAAA,WAAW,WAAW,EAAE,iBAAA,GAAA,oBAAA,cAAgB,SAAA,CAAS,OAAO,EAAE,GAAG,KAAK,CAAC,CAAC,GACtE,CAAC,WAAW,OAAO,CAMP;EACZ;EACA;EACA;CACF;AACF"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { visuallyHiddenAttributes } from "../../utils/dom.js";
|
|
3
|
-
import { mergeRefs } from "../../utils/ref.js";
|
|
4
3
|
import { utils_exports } from "../../utils/index.js";
|
|
5
4
|
import { mergeProps } from "../../core/components/props.js";
|
|
6
5
|
import { useControllableState } from "../../hooks/use-controllable-state/index.js";
|
|
@@ -41,30 +40,24 @@ const useSwitch = (props = {}) => {
|
|
|
41
40
|
const getThumbProps = useCallback((props = {}) => mergeProps(dataProps, { "data-checked": (0, utils_exports.dataAttr)(checked) }, props)(), [checked, dataProps]);
|
|
42
41
|
return {
|
|
43
42
|
checked,
|
|
44
|
-
getInputProps: useCallback((props = {}) => {
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
onChange,
|
|
63
|
-
onKeyDown
|
|
64
|
-
})({ mergeRef: false }),
|
|
65
|
-
ref: mergeRefs(inputRef, props.ref, ref)
|
|
66
|
-
};
|
|
67
|
-
}, [
|
|
43
|
+
getInputProps: useCallback((props = {}) => mergeProps(ariaProps, dataProps, eventProps, {
|
|
44
|
+
id,
|
|
45
|
+
ref: inputRef,
|
|
46
|
+
type: "checkbox",
|
|
47
|
+
name,
|
|
48
|
+
style: visuallyHiddenAttributes.style,
|
|
49
|
+
checked,
|
|
50
|
+
disabled,
|
|
51
|
+
readOnly,
|
|
52
|
+
required,
|
|
53
|
+
role: "switch",
|
|
54
|
+
tabIndex: interactive ? 0 : -1,
|
|
55
|
+
value
|
|
56
|
+
}, props, {
|
|
57
|
+
ref,
|
|
58
|
+
onChange,
|
|
59
|
+
onKeyDown
|
|
60
|
+
})(), [
|
|
68
61
|
ariaProps,
|
|
69
62
|
dataProps,
|
|
70
63
|
id,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"use-switch.js","names":["dataAttr"],"sources":["../../../../src/components/switch/use-switch.ts"],"sourcesContent":["\"use client\"\n\nimport type {\n ChangeEvent,\n ChangeEventHandler,\n FocusEventHandler,\n KeyboardEvent,\n} from \"react\"\nimport type { HTMLProps, HTMLRefAttributes, PropGetter } from \"../../core\"\nimport type { FieldProps } from \"../field\"\nimport { useCallback, useId, useRef } from \"react\"\nimport { mergeProps } from \"../../core\"\nimport { useControllableState } from \"../../hooks/use-controllable-state\"\nimport { dataAttr,
|
|
1
|
+
{"version":3,"file":"use-switch.js","names":["dataAttr"],"sources":["../../../../src/components/switch/use-switch.ts"],"sourcesContent":["\"use client\"\n\nimport type {\n ChangeEvent,\n ChangeEventHandler,\n FocusEventHandler,\n KeyboardEvent,\n} from \"react\"\nimport type { HTMLProps, HTMLRefAttributes, PropGetter } from \"../../core\"\nimport type { FieldProps } from \"../field\"\nimport { useCallback, useId, useRef } from \"react\"\nimport { mergeProps } from \"../../core\"\nimport { useControllableState } from \"../../hooks/use-controllable-state\"\nimport { dataAttr, visuallyHiddenAttributes } from \"../../utils\"\nimport { useFieldProps } from \"../field\"\n\nexport interface UseSwitchProps<Y extends number | string = string>\n extends\n Omit<HTMLProps<\"label\">, \"onBlur\" | \"onChange\" | \"onFocus\" | \"ref\">,\n HTMLRefAttributes<\"input\">,\n FieldProps {\n /**\n * If `true`, the switch will be checked.\n *\n * @default false\n */\n checked?: boolean\n /**\n * If `true`, the switch will be checked when the Enter key is pressed.\n *\n * @default true\n */\n checkOnEnter?: boolean\n /**\n * If `true`, the switch will be initially checked.\n *\n * @default false\n */\n defaultChecked?: boolean\n /**\n * id assigned to input.\n */\n id?: string\n /**\n * The HTML `name` attribute used for forms.\n */\n name?: string\n /**\n * The tab-index property of the underlying input element.\n */\n tabIndex?: number\n /**\n * The value to be used in the switch input.\n */\n value?: Y\n /**\n * The callback invoked when the switch is blurred.\n */\n onBlur?: FocusEventHandler<HTMLInputElement>\n /**\n * The callback invoked when the checked state changes.\n */\n onChange?: ChangeEventHandler<HTMLInputElement>\n /**\n * The callback invoked when the switch is focused.\n */\n onFocus?: FocusEventHandler<HTMLInputElement>\n}\n\nexport const useSwitch = <Y extends number | string = string>(\n props: UseSwitchProps<Y> = {},\n) => {\n const uuid = useId()\n const {\n props: {\n id = uuid,\n ref,\n name,\n checked: checkedProp,\n checkOnEnter = true,\n defaultChecked = false,\n disabled,\n readOnly,\n required,\n value,\n onChange: onChangeProp,\n ...rest\n },\n ariaProps,\n dataProps,\n eventProps,\n } = useFieldProps(props)\n const interactive = !(readOnly || disabled)\n const inputRef = useRef<HTMLInputElement>(null)\n const [checked, setChecked] = useControllableState({\n defaultValue: defaultChecked,\n value: checkedProp,\n })\n\n const onChange = useCallback(\n (ev: ChangeEvent<HTMLInputElement>) => {\n if (!interactive) return ev.preventDefault()\n\n setChecked(ev.target.checked)\n onChangeProp?.(ev)\n },\n [onChangeProp, setChecked, interactive],\n )\n\n const onKeyDown = useCallback(\n (ev: KeyboardEvent<HTMLInputElement>) => {\n if (interactive && checkOnEnter && ev.key === \"Enter\")\n inputRef.current?.click()\n },\n [interactive, checkOnEnter],\n )\n\n const getRootProps: PropGetter<\"label\"> = useCallback(\n (props = {}) =>\n mergeProps(\n dataProps,\n { htmlFor: id, \"data-checked\": dataAttr(checked) },\n rest,\n props,\n )(),\n [checked, rest, id, dataProps],\n )\n\n const getTrackProps: PropGetter = useCallback(\n (props = {}) =>\n mergeProps(dataProps, { \"data-checked\": dataAttr(checked) }, props)(),\n [checked, dataProps],\n )\n\n const getThumbProps: PropGetter = useCallback(\n (props = {}) =>\n mergeProps(dataProps, { \"data-checked\": dataAttr(checked) }, props)(),\n [checked, dataProps],\n )\n\n const getInputProps: PropGetter<\"input\"> = useCallback(\n (props = {}) =>\n mergeProps(\n ariaProps,\n dataProps,\n eventProps,\n {\n id,\n ref: inputRef,\n type: \"checkbox\",\n name,\n style: visuallyHiddenAttributes.style,\n checked,\n disabled,\n readOnly,\n required,\n role: \"switch\",\n tabIndex: interactive ? 0 : -1,\n value,\n },\n props,\n { ref, onChange, onKeyDown },\n )(),\n [\n ariaProps,\n dataProps,\n id,\n name,\n checked,\n disabled,\n readOnly,\n required,\n interactive,\n value,\n ref,\n eventProps,\n onChange,\n onKeyDown,\n ],\n )\n\n const getLabelProps: PropGetter<\"span\"> = useCallback(\n (props = {}) =>\n mergeProps(dataProps, { \"data-checked\": dataAttr(checked) }, props)(),\n [dataProps, checked],\n )\n\n return {\n checked,\n getInputProps,\n getLabelProps,\n getRootProps,\n getThumbProps,\n getTrackProps,\n }\n}\n\nexport type UseSwitchReturn = ReturnType<typeof useSwitch>\n"],"mappings":";;;;;;;;AAqEA,MAAa,aACX,QAA2B,CAAC,MACzB;CACH,MAAM,OAAO,MAAM;CACnB,MAAM,EACJ,OAAO,EACL,KAAK,MACL,KACA,MACA,SAAS,aACT,eAAe,MACf,iBAAiB,OACjB,UACA,UACA,UACA,OACA,UAAU,cACV,GAAG,QAEL,WACA,WACA,eACE,cAAc,KAAK;CACvB,MAAM,c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GACA;GACA;GACA;GACA;GACA;EACF,CAWY;EACZ,eATwC,aACvC,QAAQ,CAAC,MACR,WAAW,WAAW,EAAE,iBAAA,GAAgBA,cAAAA,SAAAA,CAAS,OAAO,EAAE,GAAG,KAAK,CAAC,CAAC,GACtE,CAAC,WAAW,OAAO,CAMP;EACZ;EACA;EACA;CACF;AACF"}
|
|
@@ -21,7 +21,7 @@ export interface AvatarProps extends HTMLStyledProps, ThemeProps<AvatarStyle>, U
|
|
|
21
21
|
*/
|
|
22
22
|
imageProps?: AvatarImageProps;
|
|
23
23
|
}
|
|
24
|
-
declare const component: <H extends As | "fragment" = "div", R extends import("@yamada-ui/utils").Dict = import("@yamada-ui/utils").Dict<any>>(el: H | import("react").FC<R>, slot?: ComponentSlot<ComponentSlotName<ComponentSlotStyle<"image" | "group" | "
|
|
24
|
+
declare const component: <H extends As | "fragment" = "div", R extends import("@yamada-ui/utils").Dict = import("@yamada-ui/utils").Dict<any>>(el: H | import("react").FC<R>, slot?: ComponentSlot<ComponentSlotName<ComponentSlotStyle<"image" | "group" | "fallback" | "root", {
|
|
25
25
|
shape: {
|
|
26
26
|
circle: {
|
|
27
27
|
root: {
|
|
@@ -140,7 +140,7 @@ declare const component: <H extends As | "fragment" = "div", R extends import("@
|
|
|
140
140
|
};
|
|
141
141
|
};
|
|
142
142
|
};
|
|
143
|
-
}>>> | undefined, { name, className, ...options }?: ComponentOptions) => (initialProps?: InitialProps<R>, ...superProps: SuperProps<R>[]) => H extends "fragment" ? import("react").FunctionComponent<R> : Component<Exclude<H, "fragment">, R>, AvatarPropsContext: import("react").Context<Partial<AvatarProps> | undefined>, useAvatarPropsContext: () => Partial<AvatarProps> | undefined, useRootComponentProps: <Y extends import("@yamada-ui/utils").Dict = {}, R extends keyof Y = keyof Y>(props: Y, slot?: ComponentSlot<ComponentSlotName<ComponentSlotStyle<"image" | "group" | "
|
|
143
|
+
}>>> | undefined, { name, className, ...options }?: ComponentOptions) => (initialProps?: InitialProps<R>, ...superProps: SuperProps<R>[]) => H extends "fragment" ? import("react").FunctionComponent<R> : Component<Exclude<H, "fragment">, R>, AvatarPropsContext: import("react").Context<Partial<AvatarProps> | undefined>, useAvatarPropsContext: () => Partial<AvatarProps> | undefined, useRootComponentProps: <Y extends import("@yamada-ui/utils").Dict = {}, R extends keyof Y = keyof Y>(props: Y, slot?: ComponentSlot<ComponentSlotName<ComponentSlotStyle<"image" | "group" | "fallback" | "root", {
|
|
144
144
|
shape: {
|
|
145
145
|
circle: {
|
|
146
146
|
root: {
|
|
@@ -259,7 +259,7 @@ declare const component: <H extends As | "fragment" = "div", R extends import("@
|
|
|
259
259
|
};
|
|
260
260
|
};
|
|
261
261
|
};
|
|
262
|
-
}>>> | undefined, { className, withContext, transferProps }?: UseComponentPropsOptions<R>) => [CSSSlotObject, import("@yamada-ui/utils").Merge<WithoutThemeProps<Y, ComponentSlotStyle<"image" | "group" | "
|
|
262
|
+
}>>> | undefined, { className, withContext, transferProps }?: UseComponentPropsOptions<R>) => [CSSSlotObject, import("@yamada-ui/utils").Merge<WithoutThemeProps<Y, ComponentSlotStyle<"image" | "group" | "fallback" | "root", {
|
|
263
263
|
shape: {
|
|
264
264
|
circle: {
|
|
265
265
|
root: {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ComponentSlotStyle } from "../../core/system/index.type.js";
|
|
2
2
|
import "../../index.js";
|
|
3
|
-
export declare const avatarStyle: ComponentSlotStyle<"image" | "group" | "
|
|
3
|
+
export declare const avatarStyle: ComponentSlotStyle<"image" | "group" | "fallback" | "root", {
|
|
4
4
|
/**
|
|
5
5
|
* The shape of the component
|
|
6
6
|
*
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ComponentSlotStyle } from "../../core/system/index.type.js";
|
|
2
2
|
import { CSSModifierObject, CSSPropObject, CSSSlotObject } from "../../core/css/index.type.js";
|
|
3
3
|
import "../../index.js";
|
|
4
|
-
export declare const carouselStyle: ComponentSlotStyle<"list" | "next" | "root" | "
|
|
4
|
+
export declare const carouselStyle: ComponentSlotStyle<"list" | "next" | "root" | "item" | "indicator" | "trigger" | "prev" | "indicators", CSSPropObject<CSSSlotObject<"list" | "next" | "root" | "item" | "indicator" | "trigger" | "prev" | "indicators">>, {
|
|
5
5
|
sm: {
|
|
6
6
|
root: {
|
|
7
7
|
h: "sm";
|
|
@@ -17,6 +17,6 @@ export declare const carouselStyle: ComponentSlotStyle<"list" | "next" | "root"
|
|
|
17
17
|
h: "lg";
|
|
18
18
|
};
|
|
19
19
|
};
|
|
20
|
-
}, CSSModifierObject<CSSSlotObject<"list" | "next" | "root" | "
|
|
20
|
+
}, CSSModifierObject<CSSSlotObject<"list" | "next" | "root" | "item" | "indicator" | "trigger" | "prev" | "indicators">>>;
|
|
21
21
|
export type CarouselStyle = typeof carouselStyle;
|
|
22
22
|
//# sourceMappingURL=carousel.style.d.ts.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ComponentSlotStyle } from "../../core/system/index.type.js";
|
|
2
2
|
import { CSSModifierObject, CSSSlotObject } from "../../core/css/index.type.js";
|
|
3
3
|
import "../../index.js";
|
|
4
|
-
export declare const fieldStyle: ComponentSlotStyle<"label" | "root" | "
|
|
4
|
+
export declare const fieldStyle: ComponentSlotStyle<"label" | "root" | "errorMessage" | "helperMessage" | "requiredIndicator", {
|
|
5
5
|
/**
|
|
6
6
|
* The orientation of the field.
|
|
7
7
|
*/
|
|
@@ -35,6 +35,6 @@ export declare const fieldStyle: ComponentSlotStyle<"label" | "root" | "helperMe
|
|
|
35
35
|
};
|
|
36
36
|
};
|
|
37
37
|
};
|
|
38
|
-
}, CSSModifierObject<CSSSlotObject<"label" | "root" | "
|
|
38
|
+
}, CSSModifierObject<CSSSlotObject<"label" | "root" | "errorMessage" | "helperMessage" | "requiredIndicator">>, CSSModifierObject<CSSSlotObject<"label" | "root" | "errorMessage" | "helperMessage" | "requiredIndicator">>>;
|
|
39
39
|
export type FieldStyle = typeof fieldStyle;
|
|
40
40
|
//# sourceMappingURL=field.style.d.ts.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ComponentSlotStyle } from "../../core/system/index.type.js";
|
|
2
2
|
import { CSSPropObject, CSSSlotObject } from "../../core/css/index.type.js";
|
|
3
3
|
import "../../index.js";
|
|
4
|
-
export declare const fieldsetStyle: ComponentSlotStyle<"header" | "legend" | "content" | "root" | "
|
|
4
|
+
export declare const fieldsetStyle: ComponentSlotStyle<"header" | "legend" | "content" | "root" | "errorMessage" | "helperMessage", CSSPropObject<CSSSlotObject<"header" | "legend" | "content" | "root" | "errorMessage" | "helperMessage">>, {
|
|
5
5
|
sm: {
|
|
6
6
|
content: {
|
|
7
7
|
gap: "3";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ComponentSlotStyle } from "../../core/system/index.type.js";
|
|
2
2
|
import { CSSModifierObject, CSSPropObject, CSSSlotObject } from "../../core/css/index.type.js";
|
|
3
3
|
import "../../index.js";
|
|
4
|
-
export declare const menuStyle: ComponentSlotStyle<"footer" | "header" | "label" | "content" | "command" | "group" | "separator" | "
|
|
4
|
+
export declare const menuStyle: ComponentSlotStyle<"footer" | "header" | "label" | "content" | "command" | "group" | "separator" | "item" | "indicator", CSSPropObject<CSSSlotObject<"footer" | "header" | "label" | "content" | "command" | "group" | "separator" | "item" | "indicator">>, {
|
|
5
5
|
sm: {
|
|
6
6
|
command: {
|
|
7
7
|
fontSize: "2xs";
|
|
@@ -86,6 +86,6 @@ export declare const menuStyle: ComponentSlotStyle<"footer" | "header" | "label"
|
|
|
86
86
|
px: "2";
|
|
87
87
|
};
|
|
88
88
|
};
|
|
89
|
-
}, CSSModifierObject<CSSSlotObject<"footer" | "header" | "label" | "content" | "command" | "group" | "separator" | "
|
|
89
|
+
}, CSSModifierObject<CSSSlotObject<"footer" | "header" | "label" | "content" | "command" | "group" | "separator" | "item" | "indicator">>>;
|
|
90
90
|
export type MenuStyle = typeof menuStyle;
|
|
91
91
|
//# sourceMappingURL=menu.style.d.ts.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ComponentSlotStyle } from "../../core/system/index.type.js";
|
|
2
2
|
import { CSSModifierObject, CSSSlotObject } from "../../core/css/index.type.js";
|
|
3
3
|
import "../../index.js";
|
|
4
|
-
export declare const segmentedControlStyle: ComponentSlotStyle<"root" | "
|
|
4
|
+
export declare const segmentedControlStyle: ComponentSlotStyle<"root" | "item" | "indicator", {
|
|
5
5
|
/**
|
|
6
6
|
* If `true`, the segmented control will be full rounded.
|
|
7
7
|
*
|
|
@@ -113,6 +113,6 @@ export declare const segmentedControlStyle: ComponentSlotStyle<"root" | "indicat
|
|
|
113
113
|
};
|
|
114
114
|
};
|
|
115
115
|
};
|
|
116
|
-
}, CSSModifierObject<CSSSlotObject<"root" | "
|
|
116
|
+
}, CSSModifierObject<CSSSlotObject<"root" | "item" | "indicator">>>;
|
|
117
117
|
export type SegmentedControlStyle = typeof segmentedControlStyle;
|
|
118
118
|
//# sourceMappingURL=segmented-control.style.d.ts.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ComponentSlotStyle } from "../../core/system/index.type.js";
|
|
2
2
|
import "../../index.js";
|
|
3
|
-
export declare const stepsStyle: ComponentSlotStyle<"title" | "list" | "separator" | "root" | "
|
|
3
|
+
export declare const stepsStyle: ComponentSlotStyle<"title" | "list" | "separator" | "root" | "item" | "indicator" | "description", {
|
|
4
4
|
/**
|
|
5
5
|
* The orientation of the steps.
|
|
6
6
|
*
|
|
@@ -61,7 +61,7 @@ declare const TimelinePropsContext: import("react").Context<Partial<TimelineRoot
|
|
|
61
61
|
*
|
|
62
62
|
* @see https://yamada-ui.com/docs/components/timeline
|
|
63
63
|
*/
|
|
64
|
-
export declare const TimelineRoot: Component<({ variant: variantProp, children, index, items, ...rest }: WithoutThemeProps<TimelineRootProps, ComponentSlotStyle<"title" | "content" | "root" | "
|
|
64
|
+
export declare const TimelineRoot: Component<({ variant: variantProp, children, index, items, ...rest }: WithoutThemeProps<TimelineRootProps, ComponentSlotStyle<"title" | "content" | "root" | "item" | "indicator" | "description" | "connector", {
|
|
65
65
|
align: {
|
|
66
66
|
center: {
|
|
67
67
|
content: {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ComponentSlotStyle } from "../../core/system/index.type.js";
|
|
2
2
|
import "../../index.js";
|
|
3
|
-
export declare const timelineStyle: ComponentSlotStyle<"title" | "content" | "root" | "
|
|
3
|
+
export declare const timelineStyle: ComponentSlotStyle<"title" | "content" | "root" | "item" | "indicator" | "description" | "connector", {
|
|
4
4
|
/**
|
|
5
5
|
* The alignment of the timeline.
|
|
6
6
|
*
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ComponentSlotStyle } from "../../core/system/index.type.js";
|
|
2
2
|
import "../../index.js";
|
|
3
|
-
export declare const treeStyle: ComponentSlotStyle<"label" | "checkbox" | "group" | "end" | "start" | "element" | "root" | "
|
|
3
|
+
export declare const treeStyle: ComponentSlotStyle<"label" | "checkbox" | "group" | "end" | "start" | "element" | "root" | "item" | "indicator", {
|
|
4
4
|
/**
|
|
5
5
|
* The shape of the component
|
|
6
6
|
*
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@yamada-ui/react",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "2.3.4-dev-
|
|
4
|
+
"version": "2.3.4-dev-20261114185317",
|
|
5
5
|
"description": "React UI components of the Yamada, by the Yamada, for the Yamada built with React and Emotion",
|
|
6
6
|
"keywords": [
|
|
7
7
|
"yamada",
|