Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Czech language option and locale data #8594

Merged
merged 4 commits into from Sep 4, 2018
Merged
Changes from 1 commit
Commits
File filter...
Filter file types
Jump to…
Jump to file or symbol
Failed to load files and symbols.

Always

Just for now

Add Czech locale data

  • Loading branch information...
Aditoo17 committed Sep 3, 2018
commit f48ab4e92c80527034ed31a819d17f7a3fe02c08
@@ -0,0 +1,138 @@
/*eslint eqeqeq: "off"*/

This comment has been minimized.

Copy link
@ykzts

ykzts Sep 3, 2018

Collaborator

locale-data/cs.js already exists.

This comment has been minimized.

Copy link
@Gargron

Gargron Sep 3, 2018

Member

Also the file is named Mastodon-cs-data.txt

This comment has been minimized.

Copy link
@Aditoo17

Aditoo17 Sep 3, 2018

Author Contributor

Yeah, was uploading that and forgot to rename it.

/*eslint no-nested-ternary: "off"*/

export default [
{
locale: "cs",
pluralRuleFunction: function(e, a) {
var n = String(e).split("."),
l = !n[1],
o = Number(n[0]) == e,
t = o && n[0].slice(-1),
r = o && n[0].slice(-2);
return a ? "other" : 1 == e && l ? "one" : e >= 2 && e < 5 && l ? "few" : !l ? "many" : "other"
},
fields: {
year: {
displayName: "rok",
relative: {
0: "tento rok",
1: "příští rok",
"-1": "minulý rok"
},
relativeTime: {
future: {
one: "za {0} rok",
few: "za {0} roky",
many: "za {0} roku",
other: "za {0} let"
},
past: {
one: "před {0} rokem",
few: "před {0} roky",
many: "před {0} roku",
other: "před {0} lety"
}
}
},
month: {
displayName: "měsíc",
relative: {
0: "tento měsíc",
1: "příští měsíc",
"-1": "minulý měsíc"
},
relativeTime: {
future: {
one: "za {0} měsíc",
few: "za {0} měsíce",
many: "za {0} měsíce",
other: "za {0} měsíců"
},
past: {
one: "před {0} měsícem",
few: "před {0} měsíci",
many: "před {0} měsíce",
other: "před {0} měsíci"
}
}
},
day: {
displayName: "den",
relative: {
0: "dnes",
1: "zítra",
"-1": "včera"
},
relativeTime: {
future: {
one: "za {0} den",
few: "za {0} dny",
many: "za {0} dne",
other: "za {0} dní"
},
past: {
one: "před {0} dnem",
few: "před {0} dny",
many: "před {0} dne",
other: "před {0} dny"
}
}
},
hour: {
displayName: "hodina",
relativeTime: {
future: {
one: "za {0} hodinu",
few: "za {0} hodiny",
many: "za {0} hodiny",
other: "za {0} hodin"
},
past: {
one: "před {0} hodinou",
few: "před {0} hodinami",
many: "před {0} hodiny",
other: "před {0} hodinami"
}
}
},
minute: {
displayName: "minuta",
relativeTime: {
future: {
one: "za {0} minutu",
few: "za {0} minuty",
many: "za {0} minuty",
other: "za {0} minut"
},
past: {
one: "před {0} minutou",
few: "před {0} minutami",
many: "před {0} minuty",
other: "před {0} minutami"
}
}
},
second: {
displayName: "sekunda",
relative: {
0: "teď"
},
relativeTime: {
future: {
one: "za {0} sekundu",
few: "za {0} sekundy",
many: "za {0} sekundy",
other: "za {0} sekund"
},
past: {
one: "před {0} sekundou",
few: "před {0} sekundami",
many: "před {0} sekundy",
other: "před {0} sekundami"
}
}
}
}
}
]
ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.