tdesign-mobile-vue
Version:
tdesign-mobile-vue
305 lines (304 loc) • 8.64 kB
TypeScript
import { GlobalConfigProvider } from './type';
import type { TdConfigProviderProps } from './type';
export * from './type';
export declare const t: <T>(pattern: T, ...args: any[]) => any;
export declare function useConfig<T extends keyof GlobalConfigProvider>(componentName?: T, componentLocale?: GlobalConfigProvider[T]): {
t: <T>(pattern: T, ...args: any[]) => any;
global: import("vue").ComputedRef<{} & (GlobalConfigProvider | ({
readonly classPrefix: 't';
readonly form: {
readonly requiredMark: any;
};
} & {
actionSheet: {
cancel: string;
};
calendar: {
title: string;
confirm: string;
weekdays: string[];
monthTitle: string;
months: string[];
};
cascader: {
title: string;
placeholder: string;
};
dropdownMenu: {
reset: string;
confirm: string;
};
dateTimePicker: {
dayjsLocale: string;
title: string;
cancel: string;
confirm: string;
format: string;
months: string[];
yearLabel: string;
monthLabel: string;
dateLabel: string;
hourLabel: string;
minuteLabel: string;
secondLabel: string;
};
form: {
errorMessage: {
date: string;
url: string;
required: string;
whitespace: string;
max: string;
min: string;
len: string;
enum: string;
idcard: string;
telnumber: string;
pattern: string;
validator: string;
boolean: string;
number: string;
};
colonText: string;
};
picker: {
cancel: string;
confirm: string;
};
pullDownRefresh: {
loadingTexts: string[];
};
rate: {
texts: string[];
valueText: string;
noValueText: string;
};
tabBar: {
newsAriaLabel: string;
moreNewsAriaLabel: string;
haveMoreNewsAriaLabel: string;
haveNewsAriaLabel: string;
};
table: {
empty: string;
};
list: {
loading: string;
loadingMoreText: string;
pulling: string;
loosing: string;
success: string;
};
upload: {
progress: {
uploadingText: string;
waitingText: string;
failText: string;
successText: string;
reloadText: string;
};
};
guide: {
next: string;
skip: string;
finish: string;
back: string;
};
typography: {
expandText: string;
collapseText: string;
copiedText: string;
};
qrcode: {
expiredText: string;
refreshText: string;
scannedText: string;
};
attachments: {
status: {
pending: string;
fail: string;
};
};
chatActionbar: {
actionBar: {
replay: string;
copy: string;
good: string;
bad: string;
share: string;
quote: string;
};
};
chatSender: {
placeholder: string;
sendText: string;
stopText: string;
};
chatThinking: {
status: {
pending: string;
complete: string;
stop: string;
};
};
}))[T] & GlobalConfigProvider[T]>;
globalConfig: import("vue").ComputedRef<{} & (GlobalConfigProvider | ({
readonly classPrefix: 't';
readonly form: {
readonly requiredMark: any;
};
} & {
actionSheet: {
cancel: string;
};
calendar: {
title: string;
confirm: string;
weekdays: string[];
monthTitle: string;
months: string[];
};
cascader: {
title: string;
placeholder: string;
};
dropdownMenu: {
reset: string;
confirm: string;
};
dateTimePicker: {
dayjsLocale: string;
title: string;
cancel: string;
confirm: string;
format: string;
months: string[];
yearLabel: string;
monthLabel: string;
dateLabel: string;
hourLabel: string;
minuteLabel: string;
secondLabel: string;
};
form: {
errorMessage: {
date: string;
url: string;
required: string;
whitespace: string;
max: string;
min: string;
len: string;
enum: string;
idcard: string;
telnumber: string;
pattern: string;
validator: string;
boolean: string;
number: string;
};
colonText: string;
};
picker: {
cancel: string;
confirm: string;
};
pullDownRefresh: {
loadingTexts: string[];
};
rate: {
texts: string[];
valueText: string;
noValueText: string;
};
tabBar: {
newsAriaLabel: string;
moreNewsAriaLabel: string;
haveMoreNewsAriaLabel: string;
haveNewsAriaLabel: string;
};
table: {
empty: string;
};
list: {
loading: string;
loadingMoreText: string;
pulling: string;
loosing: string;
success: string;
};
upload: {
progress: {
uploadingText: string;
waitingText: string;
failText: string;
successText: string;
reloadText: string;
};
};
guide: {
next: string;
skip: string;
finish: string;
back: string;
};
typography: {
expandText: string;
collapseText: string;
copiedText: string;
};
qrcode: {
expiredText: string;
refreshText: string;
scannedText: string;
};
attachments: {
status: {
pending: string;
fail: string;
};
};
chatActionbar: {
actionBar: {
replay: string;
copy: string;
good: string;
bad: string;
share: string;
quote: string;
};
};
chatSender: {
placeholder: string;
sendText: string;
stopText: string;
};
chatThinking: {
status: {
pending: string;
complete: string;
stop: string;
};
};
}))[T] & GlobalConfigProvider[T]>;
classPrefix: import("vue").ComputedRef<string>;
};
export declare const provideConfig: (props: TdConfigProviderProps) => import("vue").ComputedRef<{
actionSheet?: import("@/components").ActionSheetConfig;
calendar?: import("@/components").CalendarConfig;
cascader?: import("@/components").CascaderConfig;
classPrefix?: string;
dateTimePicker?: import("@/components").DateTimePickerConfig;
dropdownMenu?: import("@/components").DropdownMenuConfig;
guide?: import("@/components").GuideConfig;
list?: import("@/components").ListConfig;
picker?: import("@/components").PickerConfig;
pullDownRefresh?: import("@/components").PullDownRefreshConfig;
qrcode?: import("@/components").QRCodeConfig;
rate?: import("@/components").RateConfig;
tabBar?: import("@/components").TabBarConfig;
table?: import("@/components").TableConfig;
typography?: import("@/components").TypographyConfig;
upload?: import("@/components").UploadConfig;
}>;