]> git.ipfire.org Git - thirdparty/moment.git/commitdiff
12-hour time for Korean
authorJason Katz-Brown <jason@airbnb.com>
Tue, 15 Nov 2016 09:25:17 +0000 (02:25 -0700)
committerIskren Chernev <iskren.chernev@gmail.com>
Thu, 2 Mar 2017 08:40:17 +0000 (10:40 +0200)
src/locale/ko.js
src/test/locale/ko.js

index e84799307f52ea6e118e56669a0890d7e3320601..4fdcae1de19d8bdd3783fb854416ecec6db83f97 100644 (file)
@@ -12,16 +12,16 @@ export default moment.defineLocale('ko', {
     weekdaysShort : '일_월_화_수_목_금_토'.split('_'),
     weekdaysMin : '일_월_화_수_목_금_토'.split('_'),
     longDateFormat : {
-        LT : 'HH:mm',
-        LTS : 'HH:mm:ss',
+        LT : 'A h:mm',
+        LTS : 'A h:mm:ss',
         L : 'YYYY.MM.DD',
         LL : 'YYYY년 MMMM D일',
-        LLL : 'YYYY년 MMMM D일 HH:mm',
-        LLLL : 'YYYY년 MMMM D일 dddd HH:mm',
+        LLL : 'YYYY년 MMMM D일 A h:mm',
+        LLLL : 'YYYY년 MMMM D일 dddd A h:mm',
         l : 'YYYY.MM.DD',
         ll : 'YYYY년 MMMM D일',
-        lll : 'YYYY년 MMMM D일 HH:mm',
-        llll : 'YYYY년 MMMM D일 dddd HH:mm'
+        lll : 'YYYY년 MMMM D일 A h:mm',
+        llll : 'YYYY년 MMMM D일 dddd A h:mm'
     },
     calendar : {
         sameDay : '오늘 LT',
index 0b71d5bae341fd9fb65783aa82571a4106803e4d..25e331f3f8c6fa370d2c89ceb306a87520da3686 100644 (file)
@@ -71,15 +71,15 @@ test('format', function (assert) {
             ['s ss',                               '50 50'],
             ['a A',                                '오후 오후'],
             ['일년 중 DDDo째 되는 날',                 '일년 중 45일째 되는 날'],
-            ['LTS',                                '15:25:50'],
+            ['LTS',                                '오후 3:25:50'],
             ['L',                                  '2010.02.14'],
             ['LL',                                 '2010년 2월 14일'],
-            ['LLL',                                '2010년 2월 14일 15:25'],
-            ['LLLL',                               '2010년 2월 14일 일요일 15:25'],
+            ['LLL',                                '2010년 2월 14일 오후 3:25'],
+            ['LLLL',                               '2010년 2월 14일 일요일 오후 3:25'],
             ['l',                                  '2010.02.14'],
             ['ll',                                 '2010년 2월 14일'],
-            ['lll',                                '2010년 2월 14일 15:25'],
-            ['llll',                               '2010년 2월 14일 일요일 15:25']
+            ['lll',                                '2010년 2월 14일 오후 3:25'],
+            ['llll',                               '2010년 2월 14일 일요일 오후 3:25']
         ],
         b = moment(new Date(2010, 1, 14, 15, 25, 50, 125)),
         i;
@@ -188,12 +188,12 @@ test('fromNow', function (assert) {
 test('calendar day', function (assert) {
     var a = moment().hours(12).minutes(0).seconds(0);
 
-    assert.equal(moment(a).calendar(),                   '오늘 12:00', 'today at the same time');
-    assert.equal(moment(a).add({m: 25}).calendar(),      '오늘 12:25', 'Now plus 25 min');
-    assert.equal(moment(a).add({h: 1}).calendar(),       '오늘 13:00', 'Now plus 1 hour');
-    assert.equal(moment(a).add({d: 1}).calendar(),       '내일 12:00', 'tomorrow at the same time');
-    assert.equal(moment(a).subtract({h: 1}).calendar(),  '오늘 11:00', 'Now minus 1 hour');
-    assert.equal(moment(a).subtract({d: 1}).calendar(),  '어제 12:00', 'yesterday at the same time');
+    assert.equal(moment(a).calendar(),                   '오늘 오후 12:00', 'today at the same time');
+    assert.equal(moment(a).add({m: 25}).calendar(),      '오늘 오후 12:25', 'Now plus 25 min');
+    assert.equal(moment(a).add({h: 1}).calendar(),       '오늘 오후 1:00',  'Now plus 1 hour');
+    assert.equal(moment(a).add({d: 1}).calendar(),       '내일 오후 12:00', 'tomorrow at the same time');
+    assert.equal(moment(a).subtract({h: 1}).calendar(),  '오늘 오전 11:00', 'Now minus 1 hour');
+    assert.equal(moment(a).subtract({d: 1}).calendar(),  '어제 오후 12:00', 'yesterday at the same time');
 });
 
 test('calendar next week', function (assert) {