mirror of
https://github.com/vector-im/element-web.git
synced 2024-11-18 06:35:35 +08:00
Better translations in RoomList.js
Signed-off-by: Stefan Parviainen <pafcu@iki.fi>
This commit is contained in:
parent
047daec587
commit
1f44233e05
@ -34,27 +34,18 @@ const Receipt = require('../../../utils/Receipt');
|
|||||||
const HIDE_CONFERENCE_CHANS = true;
|
const HIDE_CONFERENCE_CHANS = true;
|
||||||
|
|
||||||
function phraseForSection(section) {
|
function phraseForSection(section) {
|
||||||
// These would probably be better as individual strings,
|
|
||||||
// but for some reason we have translations for these strings
|
|
||||||
// as-is, so keeping it like this for now.
|
|
||||||
let verb;
|
|
||||||
switch (section) {
|
switch (section) {
|
||||||
case 'm.favourite':
|
case 'm.favourite':
|
||||||
verb = _t('to favourite');
|
return _t('Drop here to favourite');
|
||||||
break;
|
|
||||||
case 'im.vector.fake.direct':
|
case 'im.vector.fake.direct':
|
||||||
verb = _t('to tag direct chat');
|
return _t('Drop here to tag direct chat');
|
||||||
break;
|
|
||||||
case 'im.vector.fake.recent':
|
case 'im.vector.fake.recent':
|
||||||
verb = _t('to restore');
|
return _t('Drop here to restore');
|
||||||
break;
|
|
||||||
case 'm.lowpriority':
|
case 'm.lowpriority':
|
||||||
verb = _t('to demote');
|
return _t('Drop here to demote');
|
||||||
break;
|
|
||||||
default:
|
default:
|
||||||
return _t('Drop here to tag %(section)s', {section: section});
|
return _t('Drop here to tag %(section)s', {section: section});
|
||||||
}
|
}
|
||||||
return _t('Drop here %(toAction)s', {toAction: verb});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
module.exports = React.createClass({
|
module.exports = React.createClass({
|
||||||
|
Loading…
Reference in New Issue
Block a user