UNPKG

antd-fx67ll-test

Version:

这是一个测试着玩的私服antd项目,完全照抄v4.16.6的antd源码,请勿使用,仅做发布测试(因每次发布必须要升版本,如发现版本出入请忽略,与官方无关)

22 lines (21 loc) 938 B
import * as React from 'react'; import { Locale } from '.'; export interface LocaleReceiverProps<C extends keyof Locale = keyof Locale> { componentName: C; defaultLocale?: Locale[C] | (() => Locale[C]); children: (locale: Exclude<Locale[C], undefined>, localeCode?: string, fullLocale?: object) => React.ReactNode; } export default class LocaleReceiver<C extends keyof Locale = keyof Locale> extends React.Component<LocaleReceiverProps<C>> { static defaultProps: { componentName: string; }; static contextType: React.Context<(Partial<Locale> & { exist?: boolean | undefined; }) | undefined>; getLocale(): Exclude<Locale[C], undefined>; getLocaleCode(): any; render(): React.ReactNode; } declare type LocaleComponent = keyof Locale; export declare function useLocaleReceiver<T extends LocaleComponent>(componentName: T, defaultLocale?: Locale[T] | Function): [Locale[T]]; export {};