UNPKG

@fesjs/fes-design

Version:
89 lines (88 loc) 3.21 kB
import { type PropType } from 'vue'; import type { ExtractPublicPropTypes } from '../_util/interface'; type SwitchValue = string | [] | object | number | boolean; type SwitchSize = 'normal' | 'small'; export declare const switchProps: { readonly modelValue: { readonly type: PropType<SwitchValue>; }; readonly disabled: { readonly type: BooleanConstructor; readonly default: false; }; readonly activeValue: { readonly type: PropType<SwitchValue>; readonly default: true; }; readonly inactiveValue: { readonly type: PropType<SwitchValue>; readonly default: false; }; readonly beforeChange: PropType<(val: SwitchValue) => boolean | Promise<boolean>>; readonly size: { readonly type: PropType<SwitchSize>; readonly default: "normal"; }; }; export type SwitchProps = ExtractPublicPropTypes<typeof switchProps>; declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{ readonly modelValue: { readonly type: PropType<SwitchValue>; }; readonly disabled: { readonly type: BooleanConstructor; readonly default: false; }; readonly activeValue: { readonly type: PropType<SwitchValue>; readonly default: true; }; readonly inactiveValue: { readonly type: PropType<SwitchValue>; readonly default: false; }; readonly beforeChange: PropType<(val: SwitchValue) => boolean | Promise<boolean>>; readonly size: { readonly type: PropType<SwitchSize>; readonly default: "normal"; }; }>, { prefixCls: string; wrapperClass: import("vue").ComputedRef<string[]>; toggle: () => Promise<void>; activeRef: import("vue").ComputedRef<boolean>; inactiveRef: import("vue").ComputedRef<boolean>; loadingRef: import("vue").Ref<boolean, boolean>; }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("change" | "update:modelValue")[], "change" | "update:modelValue", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{ readonly modelValue: { readonly type: PropType<SwitchValue>; }; readonly disabled: { readonly type: BooleanConstructor; readonly default: false; }; readonly activeValue: { readonly type: PropType<SwitchValue>; readonly default: true; }; readonly inactiveValue: { readonly type: PropType<SwitchValue>; readonly default: false; }; readonly beforeChange: PropType<(val: SwitchValue) => boolean | Promise<boolean>>; readonly size: { readonly type: PropType<SwitchSize>; readonly default: "normal"; }; }>> & Readonly<{ onChange?: (...args: any[]) => any; "onUpdate:modelValue"?: (...args: any[]) => any; }>, { readonly size: SwitchSize; readonly disabled: boolean; readonly activeValue: SwitchValue; readonly inactiveValue: SwitchValue; }, {}, { LoadingOutlined: (props?: import("../icon/IconWrapper").IconProps) => import("vue/jsx-runtime").JSX.Element; }, {}, string, import("vue").ComponentProvideOptions, true, {}, any>; export default _default;