fix AM/PM text in datetime picker is not translated
This commit is contained in:
@@ -37,6 +37,9 @@
|
|||||||
<template #month-overlay-value="{ text }">
|
<template #month-overlay-value="{ text }">
|
||||||
{{ getMonthShortName(text) }}
|
{{ getMonthShortName(text) }}
|
||||||
</template>
|
</template>
|
||||||
|
<template #am-pm-button="{ toggle, value }">
|
||||||
|
<button class="dp__pm_am_button" tabindex="0" @click="toggle">{{ $t(`datetime.${value}.content`) }}</button>
|
||||||
|
</template>
|
||||||
</vue-date-picker>
|
</vue-date-picker>
|
||||||
</v-card-text>
|
</v-card-text>
|
||||||
<v-card-text class="overflow-y-visible">
|
<v-card-text class="overflow-y-visible">
|
||||||
|
|||||||
@@ -34,6 +34,9 @@
|
|||||||
<template #month-overlay-value="{ text }">
|
<template #month-overlay-value="{ text }">
|
||||||
{{ getMonthShortName(text) }}
|
{{ getMonthShortName(text) }}
|
||||||
</template>
|
</template>
|
||||||
|
<template #am-pm-button="{ toggle, value }">
|
||||||
|
<button class="dp__pm_am_button" tabindex="0" @click="toggle">{{ $t(`datetime.${value}.content`) }}</button>
|
||||||
|
</template>
|
||||||
</vue-date-picker>
|
</vue-date-picker>
|
||||||
<f7-button large fill
|
<f7-button large fill
|
||||||
:class="{ 'disabled': !dateRange[0] || !dateRange[1] }"
|
:class="{ 'disabled': !dateRange[0] || !dateRange[1] }"
|
||||||
|
|||||||
@@ -29,6 +29,9 @@
|
|||||||
<template #month-overlay-value="{ text }">
|
<template #month-overlay-value="{ text }">
|
||||||
{{ getMonthShortName(text) }}
|
{{ getMonthShortName(text) }}
|
||||||
</template>
|
</template>
|
||||||
|
<template #am-pm-button="{ toggle, value }">
|
||||||
|
<button class="dp__pm_am_button" tabindex="0" @click="toggle">{{ $t(`datetime.${value}.content`) }}</button>
|
||||||
|
</template>
|
||||||
</vue-date-picker>
|
</vue-date-picker>
|
||||||
</f7-page-content>
|
</f7-page-content>
|
||||||
</f7-sheet>
|
</f7-sheet>
|
||||||
|
|||||||
+2
-2
@@ -1079,9 +1079,9 @@ function setLanguage(i18nGlobal, locale, force) {
|
|||||||
weekdaysMin : getAllMinWeekdayNames(i18nGlobal.t),
|
weekdaysMin : getAllMinWeekdayNames(i18nGlobal.t),
|
||||||
meridiem: function (hours) {
|
meridiem: function (hours) {
|
||||||
if (hours > 11) {
|
if (hours > 11) {
|
||||||
return i18nGlobal.t('datetime.PM.upperCase');
|
return i18nGlobal.t('datetime.PM.content');
|
||||||
} else {
|
} else {
|
||||||
return i18nGlobal.t('datetime.AM.upperCase');
|
return i18nGlobal.t('datetime.AM.content');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|||||||
+2
-2
@@ -81,10 +81,10 @@ export default {
|
|||||||
},
|
},
|
||||||
'datetime': {
|
'datetime': {
|
||||||
'AM': {
|
'AM': {
|
||||||
'upperCase': 'AM'
|
'content': 'AM'
|
||||||
},
|
},
|
||||||
'PM': {
|
'PM': {
|
||||||
'upperCase': 'PM'
|
'content': 'PM'
|
||||||
},
|
},
|
||||||
'Monday': {
|
'Monday': {
|
||||||
'min': 'Mo',
|
'min': 'Mo',
|
||||||
|
|||||||
@@ -81,10 +81,10 @@ export default {
|
|||||||
},
|
},
|
||||||
'datetime': {
|
'datetime': {
|
||||||
'AM': {
|
'AM': {
|
||||||
'upperCase': '上午'
|
'content': '上午'
|
||||||
},
|
},
|
||||||
'PM': {
|
'PM': {
|
||||||
'upperCase': '下午'
|
'content': '下午'
|
||||||
},
|
},
|
||||||
'Monday': {
|
'Monday': {
|
||||||
'min': '一',
|
'min': '一',
|
||||||
|
|||||||
Reference in New Issue
Block a user