Skip to content

Commit f830181

Browse files
author
Arrizal Amin
committed
fix locale that does not have plural form
1 parent fedec50 commit f830181

File tree

2 files changed

+11
-11
lines changed

2 files changed

+11
-11
lines changed

src/locale/id.js

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -16,16 +16,16 @@ const locale = {
1616
future: 'dalam %s',
1717
past: '%s yang lalu',
1818
s: 'beberapa detik',
19-
m: 'semenit',
20-
mm: '%d menit',
21-
h: 'sejam',
22-
hh: '%d jam',
23-
d: 'sehari',
24-
dd: '%d hari',
25-
M: 'sebulan',
26-
MM: '%d bulan',
27-
y: 'setahun',
28-
yy: '%d tahun'
19+
m: '%d menit',
20+
mm: '',
21+
h: '%d jam',
22+
hh: '',
23+
d: '%d hari',
24+
dd: '',
25+
M: '%d bulan',
26+
MM: '',
27+
y: '%d tahun',
28+
yy: ''
2929
},
3030
ordinal: n => `${n}.`
3131
}

src/plugin/relativeTime/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ export default (o, c, d) => {
136136
const key = t.l
137137
if (key.length === 1) {
138138
// Handle singular using a special text without any number
139-
out = loc[key]
139+
out = loc[key].replace('%d', 1)
140140
} else {
141141
// Choose the plural form using the index decided by the plural rule
142142
const pluralForms = loc[key]

0 commit comments

Comments
 (0)