mirror of
https://github.com/tusen-ai/naive-ui.git
synced 2025-03-31 14:20:53 +08:00
Added Czech localization; fixed some Slovak terms (#5733)
Co-authored-by: 07akioni <07akioni2@gmail.com>
This commit is contained in:
parent
f937d8580b
commit
b7ae0d8884
1
.gitignore
vendored
1
.gitignore
vendored
@ -12,6 +12,7 @@ yarn.lock
|
||||
.DS_Store
|
||||
.vscode
|
||||
.idea
|
||||
.pulsar
|
||||
*.swp
|
||||
*.tgz
|
||||
coverage
|
||||
|
@ -2,6 +2,10 @@
|
||||
|
||||
## NEXT_VERSION
|
||||
|
||||
### i18n
|
||||
|
||||
- Add csCZ locale.
|
||||
|
||||
### Fixes
|
||||
|
||||
- Fix `n-tabs` style bug with type is `segment`,closes [#5728](https://github.com/tusen-ai/naive-ui/issues/5728)
|
||||
|
@ -2,6 +2,10 @@
|
||||
|
||||
## NEXT_VERSION
|
||||
|
||||
### i18n
|
||||
|
||||
- Add csCZ locale.
|
||||
|
||||
### Fixes
|
||||
|
||||
- 修复 `n-tabs` type 为 `segment` 时样式存在问题,closes [#5728](https://github.com/tusen-ai/naive-ui/issues/5728)
|
||||
|
128
src/locales/common/csCZ.ts
Normal file
128
src/locales/common/csCZ.ts
Normal file
@ -0,0 +1,128 @@
|
||||
import type { NLocale } from './enUS'
|
||||
|
||||
const csCZ: NLocale = {
|
||||
name: 'cs-CZ',
|
||||
global: {
|
||||
undo: 'Zpět',
|
||||
redo: 'Obnovit',
|
||||
confirm: 'Potvrdit',
|
||||
clear: 'Vyčistit'
|
||||
},
|
||||
Popconfirm: {
|
||||
positiveText: 'Potvrdit',
|
||||
negativeText: 'Zrušit'
|
||||
},
|
||||
Cascader: {
|
||||
placeholder: 'Prosím vyberte',
|
||||
loading: 'Načítání',
|
||||
loadingRequiredMessage: (label: string): string =>
|
||||
`Prosím načtěte před kontrolou všechny potomky pro ${label}.`
|
||||
},
|
||||
Time: {
|
||||
dateFormat: 'd-M-yyyy',
|
||||
dateTimeFormat: 'd-M-yyyy HH:mm:ss'
|
||||
},
|
||||
DatePicker: {
|
||||
yearFormat: 'yyyy',
|
||||
monthFormat: 'MMM',
|
||||
dayFormat: 'EEEE',
|
||||
yearTypeFormat: 'yyyy',
|
||||
monthTypeFormat: 'MMM-yyyy',
|
||||
dateFormat: 'd-M-yyyy',
|
||||
dateTimeFormat: 'd-M-yyyy HH:mm:ss',
|
||||
quarterFormat: 'qqq-yyyy',
|
||||
weekFormat: 'yyyy-w',
|
||||
clear: 'Vyčistit',
|
||||
now: 'Teď',
|
||||
confirm: 'Potvrdit',
|
||||
selectTime: 'Vybrat čas',
|
||||
selectDate: 'Vybrat datum',
|
||||
datePlaceholder: 'Vyberte čas',
|
||||
datetimePlaceholder: 'Vyberte datum a čas',
|
||||
monthPlaceholder: 'Vyberte měsíc',
|
||||
yearPlaceholder: 'Vyberte rok',
|
||||
quarterPlaceholder: 'Vyberte čtvrtletí',
|
||||
weekPlaceholder: 'Vyberte týden',
|
||||
startDatePlaceholder: 'Datum začátku',
|
||||
endDatePlaceholder: 'Datum ukončení',
|
||||
startDatetimePlaceholder: 'Datum a čas začátku',
|
||||
endDatetimePlaceholder: 'Datum a čas ukončení ',
|
||||
startMonthPlaceholder: 'Začátek měsíce',
|
||||
endMonthPlaceholder: 'Konec měsíce',
|
||||
monthBeforeYear: true,
|
||||
firstDayOfWeek: 6 as 0 | 1 | 2 | 3 | 4 | 5 | 6,
|
||||
today: 'Dnes'
|
||||
},
|
||||
DataTable: {
|
||||
checkTableAll: 'Vybrat vše v tabulce',
|
||||
uncheckTableAll: 'Zrušit výběr všeho v tabulce ',
|
||||
confirm: 'Potvrdit',
|
||||
clear: 'Vyčistit'
|
||||
},
|
||||
LegacyTransfer: {
|
||||
sourceTitle: 'Zdroj',
|
||||
targetTitle: 'Cíl'
|
||||
},
|
||||
Transfer: {
|
||||
selectAll: 'Vybrat vše',
|
||||
unselectAll: 'Odznačit vše',
|
||||
clearAll: 'Vyčistit',
|
||||
total: (num: number): string => `Celkem ${num} položek`,
|
||||
selected: (num: number): string => `${num} položek vybráno`
|
||||
},
|
||||
Empty: {
|
||||
description: 'Žádná data'
|
||||
},
|
||||
Select: {
|
||||
placeholder: 'Prosím vyberte'
|
||||
},
|
||||
TimePicker: {
|
||||
placeholder: 'Vybrat čas',
|
||||
positiveText: 'OK',
|
||||
negativeText: 'Zrušit',
|
||||
now: 'Teď',
|
||||
clear: 'Vyčistit'
|
||||
},
|
||||
Pagination: {
|
||||
goto: 'Jít na',
|
||||
selectionSuffix: 'Strana'
|
||||
},
|
||||
DynamicTags: {
|
||||
add: 'Přidat'
|
||||
},
|
||||
Log: {
|
||||
loading: 'Načítání'
|
||||
},
|
||||
Input: {
|
||||
placeholder: 'Zadejte'
|
||||
},
|
||||
InputNumber: {
|
||||
placeholder: 'Zadejte'
|
||||
},
|
||||
DynamicInput: {
|
||||
create: 'Vytvořit'
|
||||
},
|
||||
ThemeEditor: {
|
||||
title: 'Editor témat',
|
||||
clearAllVars: 'Vymazat všechny proměnné',
|
||||
clearSearch: 'Vymazat vyhledávání',
|
||||
filterCompName: 'Filtrovat název komponenty',
|
||||
filterVarName: 'Filztrovat název proměnné',
|
||||
import: 'Importovat',
|
||||
export: 'Exportovat',
|
||||
restore: 'Obnovit původní nastavení'
|
||||
},
|
||||
Image: {
|
||||
tipPrevious: 'Předchozí obrázek (←)',
|
||||
tipNext: 'Další obrázek (→)',
|
||||
tipCounterclockwise: 'Proti směru hodinových ručiček',
|
||||
tipClockwise: 'Ve směru hodinových ručiček',
|
||||
tipZoomOut: 'Oddálit',
|
||||
tipZoomIn: 'Přiblížit',
|
||||
tipDownload: 'Stáhnout',
|
||||
tipClose: 'Zavřít (Esc)',
|
||||
tipOriginalSize: 'Přiblížit na původní velikost'
|
||||
}
|
||||
}
|
||||
|
||||
export default csCZ
|
@ -42,14 +42,13 @@ const skSK: NLocale = {
|
||||
monthPlaceholder: 'Vyberte mesiac',
|
||||
yearPlaceholder: 'Vyberte rok',
|
||||
quarterPlaceholder: 'Vyberte štvrťrok',
|
||||
weekPlaceholder: 'Select Week',
|
||||
weekPlaceholder: 'Vyberte týždeň',
|
||||
startDatePlaceholder: 'Dátum začiatku',
|
||||
endDatePlaceholder: 'Dátum ukončenia',
|
||||
startDatetimePlaceholder: 'Dátum a čas začiatku',
|
||||
endDatetimePlaceholder: 'Dátum a čas ukončenia ',
|
||||
// FIXME: translation needed
|
||||
startMonthPlaceholder: 'Start Month',
|
||||
endMonthPlaceholder: 'End Month',
|
||||
startMonthPlaceholder: 'Začiatok mesiaca',
|
||||
endMonthPlaceholder: 'Koniec mesiaca',
|
||||
monthBeforeYear: true,
|
||||
firstDayOfWeek: 6 as 0 | 1 | 2 | 3 | 4 | 5 | 6,
|
||||
today: 'Dnes'
|
||||
@ -64,13 +63,12 @@ const skSK: NLocale = {
|
||||
sourceTitle: 'Zdroj',
|
||||
targetTitle: 'Cieľ'
|
||||
},
|
||||
// TODO: translation
|
||||
Transfer: {
|
||||
selectAll: 'Select all',
|
||||
unselectAll: 'Unselect all',
|
||||
clearAll: 'Clear',
|
||||
total: (num: number): string => `Total ${num} items`,
|
||||
selected: (num: number): string => `${num} items selected`
|
||||
selectAll: 'Vybrať všetko',
|
||||
unselectAll: 'odznačiť všetko',
|
||||
clearAll: 'Vyčistiť',
|
||||
total: (num: number): string => `Celkom ${num} položiek`,
|
||||
selected: (num: number): string => `Vybratých ${num} položiek`
|
||||
},
|
||||
Empty: {
|
||||
description: 'Žiadne dáta'
|
||||
@ -86,7 +84,7 @@ const skSK: NLocale = {
|
||||
clear: 'Vyčistiť'
|
||||
},
|
||||
Pagination: {
|
||||
goto: 'Ísť',
|
||||
goto: 'Ísť na',
|
||||
selectionSuffix: 'Strana'
|
||||
},
|
||||
DynamicTags: {
|
||||
@ -108,13 +106,12 @@ const skSK: NLocale = {
|
||||
title: 'Editor tém',
|
||||
clearAllVars: 'Vymazať všetky premenné',
|
||||
clearSearch: 'Vymazať vyhľadávanie',
|
||||
filterCompName: 'Názov komponentu filtra',
|
||||
filterVarName: 'Názov premennej filtra',
|
||||
filterCompName: 'Filtrovať názov komponentu',
|
||||
filterVarName: 'Filtrovať názov premennej',
|
||||
import: 'Importovať',
|
||||
export: 'Exportovať',
|
||||
restore: 'Obnoviť pôvodné nastavenia'
|
||||
},
|
||||
// TODO: translation
|
||||
Image: {
|
||||
tipPrevious: 'Predchádzajúci obrázok (←)',
|
||||
tipNext: 'Ďalší obrázok (→)',
|
||||
@ -124,8 +121,7 @@ const skSK: NLocale = {
|
||||
tipZoomIn: 'Priblížiť',
|
||||
tipDownload: 'Sťahovať',
|
||||
tipClose: 'Zavrieť (Esc)',
|
||||
// TODO: translation
|
||||
tipOriginalSize: 'Zoom to original size'
|
||||
tipOriginalSize: 'Priblížiť na pôvodnú veľkosť'
|
||||
}
|
||||
}
|
||||
|
||||
|
9
src/locales/date/csCZ.ts
Normal file
9
src/locales/date/csCZ.ts
Normal file
@ -0,0 +1,9 @@
|
||||
import cs from 'date-fns/esm/locale/cs'
|
||||
import { type NDateLocale } from './enUS'
|
||||
|
||||
const dateCsCZ: NDateLocale = {
|
||||
name: 'cs-CZ',
|
||||
locale: cs
|
||||
}
|
||||
|
||||
export default dateCsCZ
|
@ -16,6 +16,7 @@ import {
|
||||
esAR,
|
||||
itIT,
|
||||
skSK,
|
||||
csCZ,
|
||||
enGB,
|
||||
plPL,
|
||||
ptBR,
|
||||
@ -41,6 +42,7 @@ import {
|
||||
dateEsAR,
|
||||
dateItIT,
|
||||
dateSkSK,
|
||||
dateCsCZ,
|
||||
dateEnGB,
|
||||
datePlPL,
|
||||
datePtBR,
|
||||
@ -274,6 +276,14 @@ describe('locale', () => {
|
||||
}
|
||||
}).html()
|
||||
).toMatchSnapshot()
|
||||
expect(
|
||||
mount(Wrapper, {
|
||||
props: {
|
||||
dateLocale: dateCsCZ,
|
||||
locale: csCZ
|
||||
}
|
||||
}).html()
|
||||
).toMatchSnapshot()
|
||||
expect(
|
||||
mount(Wrapper, {
|
||||
props: {
|
||||
|
@ -13,6 +13,7 @@ export { default as frFR } from './common/frFR'
|
||||
export { default as esAR } from './common/esAR'
|
||||
export { default as itIT } from './common/itIT'
|
||||
export { default as skSK } from './common/skSK'
|
||||
export { default as csCZ } from './common/csCZ'
|
||||
export { default as enGB } from './common/enGB'
|
||||
export { default as plPL } from './common/plPL'
|
||||
export { default as ptBR } from './common/ptBR'
|
||||
@ -39,6 +40,7 @@ export { default as dateFrFR } from './date/frFR'
|
||||
export { default as dateEsAR } from './date/esAR'
|
||||
export { default as dateItIT } from './date/itIT'
|
||||
export { default as dateSkSK } from './date/skSK'
|
||||
export { default as dateCsCZ } from './date/csCZ'
|
||||
export { default as dateEnGB } from './date/enGB'
|
||||
export { default as datePlPL } from './date/plPL'
|
||||
export { default as datePtBR } from './date/ptBR'
|
||||
|
Loading…
x
Reference in New Issue
Block a user