Skip to content

Commit

Permalink
feat: Adds danish locale (#2486)
Browse files Browse the repository at this point in the history
close #2485
  • Loading branch information
michaelkrog authored and vthinkxie committed Nov 30, 2018
1 parent 9f48b8f commit 1c7f983
Show file tree
Hide file tree
Showing 3 changed files with 69 additions and 0 deletions.
44 changes: 44 additions & 0 deletions components/i18n/languages/da_DK.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
import Calendar from './calendar/da_DK';
import DatePicker from './date-picker/da_DK';
import Pagination from './pagination/da_DK';
import TimePicker from './time-picker/da_DK';

export default {
locale: 'da',
DatePicker,
TimePicker,
Calendar,
Pagination,
Table: {
filterTitle: 'Filtermenu',
filterConfirm: 'OK',
filterReset: 'Nulstil',
emptyText: 'Ingen data',
selectAll: 'Vælg alle',
selectInvert: 'Inverter valg',
},
Modal: {
okText: 'OK',
cancelText: 'Annuller',
justOkText: 'OK',
},
Popconfirm: {
okText: 'OK',
cancelText: 'Annuller',
},
Transfer: {
notFoundContent: 'Intet match',
searchPlaceholder: 'Søg her',
itemUnit: 'element',
itemsUnit: 'elementer',
},
Select: {
notFoundContent: 'Intet match',
},
Upload: {
uploading: 'Uploader...',
removeFile: 'Fjern fil',
uploadError: 'Fejl ved upload',
previewFile: 'Forhåndsvisning',
},
};
19 changes: 19 additions & 0 deletions components/i18n/languages/date-picker/da_DK.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import CalendarLocale from '../calendar/da_DK';
import TimePickerLocale from '../time-picker/da_DK';

// Merge into a locale object
const locale = {
lang: {
placeholder: 'Vælg dato',
rangePlaceholder: ['Startdato', 'Slutdato'],
...CalendarLocale,
},
timePickerLocale: {
...TimePickerLocale,
},
};

// All settings at:
// https://github.com/ant-design/ant-design/blob/master/components/date-picker/locale/example.json

export default locale;
6 changes: 6 additions & 0 deletions components/i18n/languages/time-picker/da_DK.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
const locale = {
placeholder: 'Vælg tid',
};

export default locale;

0 comments on commit 1c7f983

Please sign in to comment.