sard-uniapp
Version:
sard-uniapp 是一套基于 Uniapp + Vue3 框架开发的兼容多端的 UI 组件库
65 lines (64 loc) • 1.21 kB
JavaScript
import { extend } from '../../utils';
// #region defaultConfig
export const defaultConfig = {
// 全局初始 zIndex
// initialZIndex: 1000,
/**
* 设置点击清除按钮后的值
*
* - 类型:() => any
* - 默认值:() = undefined
*
* 支持以下组件:
*
* - CalendarInput
* - DatetimePickerInput
* - DatetimeRangePickerInput
* - CascaderInput
* - CheckboxInput
* - PickerInput
* - RadioInput
*/
// valueOnClear: undefined,
};
// #endregion defaultConfig
export function setConfig(...optionsArgs) {
extend(defaultConfig, ...optionsArgs);
}
export function getDurationConfig(duration) {
return {
actionSheet: {
duration,
},
dialog: {
duration,
},
dropdown: {
duration,
},
fab: {
duration,
},
notify: {
duration,
},
overlay: {
duration,
},
popout: {
duration,
},
popover: {
duration,
},
popup: {
duration,
},
shareSheet: {
duration,
},
toast: {
duration,
},
};
}