diff --git a/examples/i18n.html b/examples/i18n.html index 20867287..7d9e7eca 100644 --- a/examples/i18n.html +++ b/examples/i18n.html @@ -389,7 +389,7 @@ { "alt": "error", "pid": 3, - "src": "", + "src": "错误提示演示", }, { "alt": "universe", diff --git a/examples/i18n/en.js b/examples/i18n/en.js index 2c1d20e3..2a88d614 100644 --- a/examples/i18n/en.js +++ b/examples/i18n/en.js @@ -136,19 +136,7 @@ export default { }, toDateString: { meridiem: function (hours, minutes) { - var hm = hours * 100 + minutes; - if (hm < 600) { - return 'Midnight'; - } else if (hm < 900) { - return 'Morning'; - } else if (hm < 1100) { - return 'Forenoon'; - } else if (hm < 1300) { - return 'Noon'; - } else if (hm < 1800) { - return 'Afternoon'; - } - return 'Evening'; + return hours < 12 ? 'AM' : 'PM'; } } } diff --git a/examples/i18n/fr.js b/examples/i18n/fr.js index 93165939..7b88dd1d 100644 --- a/examples/i18n/fr.js +++ b/examples/i18n/fr.js @@ -135,19 +135,7 @@ export default { }, toDateString: { meridiem: function(hours, minutes){ - var hm = hours * 100 + minutes; - if (hm < 600) { - return 'Tôt le matin'; - } else if (hm < 900) { - return 'Matin'; - } else if (hm < 1100) { - return 'Avant-midi'; - } else if (hm < 1300) { - return 'Midi'; - } else if (hm < 1800) { - return 'Après-midi'; - } - return 'Soir'; + return hours < 12 ? 'AM' : 'PM'; } } }