refactor: rename NaiveDateLocale to NDateLocale

This commit is contained in:
07akioni 2021-02-10 13:12:44 +08:00
parent 20c86f3af9
commit 35129bf501
6 changed files with 9 additions and 8 deletions

View File

@ -17,7 +17,7 @@ import {
GlobalThemeOverrides,
ComponentProps
} from './interface'
import { NaiveDateLocale, NLocale } from '../../locales'
import { NDateLocale, NLocale } from '../../locales'
export default defineComponent({
name: 'ConfigProvider',
@ -32,7 +32,7 @@ export default defineComponent({
default: undefined
},
locale: Object as PropType<NLocale | null>,
dateLocale: Object as PropType<NaiveDateLocale | null>,
dateLocale: Object as PropType<NDateLocale | null>,
namespace: String,
tag: {
type: String,

View File

@ -1,4 +1,4 @@
import type { NaiveDateLocale, NLocale } from '../../locales'
import type { NDateLocale, NLocale } from '../../locales'
import type { ThemeCommonVars } from '../../_styles/common'
import type { AlertTheme } from '../../alert/styles'
import type { AnchorTheme } from '../../anchor/styles'
@ -220,7 +220,7 @@ export interface ConfigProviderInjection {
mergedBordered: boolean | undefined
mergedNamespace: string | undefined
mergedLocale: NLocale | undefined
mergedDateLocale: NaiveDateLocale | undefined
mergedDateLocale: NDateLocale | undefined
mergedHljs: Hljs | undefined
mergedComponentProps: ComponentProps | undefined
// wip, unstable

View File

@ -1 +1,2 @@
export { default as NDataTable } from './src/DataTable'
export { FilterRender, SorterRender } from './src/interface'

View File

@ -1,5 +1,5 @@
import { UnwrapRef } from 'vue'
import { NLocale, NaiveDateLocale } from '../../locales'
import { NLocale, NDateLocale } from '../../locales'
import {
IsHourDisabled,
IsMinuteDisabled,
@ -33,7 +33,7 @@ export type DatePickerInjection = {
mergedTheme: MergedTheme<DatePickerTheme>
timePickerSize: 'small' | 'medium' | 'large'
locale: NLocale['DatePicker']
dateLocale: NaiveDateLocale
dateLocale: NDateLocale
value: Value | null
isDateDisabled: IsDateDisabled
} & UnwrapRef<ReturnType<typeof uniCalendarValidation>> &

View File

@ -5,5 +5,5 @@ const dateEnUs = {
locale: enUS
}
export type NaiveDateLocale = typeof dateEnUs
export type NDateLocale = typeof dateEnUs
export default dateEnUs

View File

@ -3,4 +3,4 @@ export { default as enUS } from './common/enUS'
export { default as dateZhCN } from './date/zhCN'
export { default as dateEnUS } from './date/enUS'
export type { NLocale } from './common/enUS'
export type { NaiveDateLocale } from './date/enUS'
export type { NDateLocale } from './date/enUS'