Merge branch 'develop' into travis/sourcemaps

pull/11713/head
Travis Ralston 2019-12-20 12:34:22 -07:00
commit c44a6e296e
3 changed files with 38 additions and 5 deletions

View File

@ -47,7 +47,11 @@ let Seshat = null;
try { try {
Seshat = require('matrix-seshat'); Seshat = require('matrix-seshat');
} catch (e) { } catch (e) {
console.warn("seshat unavailable", e); if (e.code === "MODULE_NOT_FOUND") {
console.log("Seshat isn't installed, event indexing is disabled.");
} else {
console.warn("Seshat unexpected error:", e);
}
} }
if (argv["help"]) { if (argv["help"]) {

View File

@ -56,7 +56,7 @@ function onLinkContextMenu(ev, params) {
let addSaveAs = false; let addSaveAs = false;
if (params.mediaType && params.mediaType === 'image' && !url.startsWith('file://')) { if (params.mediaType && params.mediaType === 'image' && !url.startsWith('file://')) {
popupMenu.append(new MenuItem({ popupMenu.append(new MenuItem({
label: 'Copy image', label: '&Copy image',
click() { click() {
if (url.startsWith('data:')) { if (url.startsWith('data:')) {
clipboard.writeImage(nativeImage.createFromDataURL(url)); clipboard.writeImage(nativeImage.createFromDataURL(url));
@ -76,14 +76,14 @@ function onLinkContextMenu(ev, params) {
// Special-case e-mail URLs to strip the `mailto:` like modern browsers do // Special-case e-mail URLs to strip the `mailto:` like modern browsers do
if (url.startsWith(MAILTO_PREFIX)) { if (url.startsWith(MAILTO_PREFIX)) {
popupMenu.append(new MenuItem({ popupMenu.append(new MenuItem({
label: 'Copy email address', label: 'Copy email &address',
click() { click() {
clipboard.writeText(url.substr(MAILTO_PREFIX.length)); clipboard.writeText(url.substr(MAILTO_PREFIX.length));
}, },
})); }));
} else { } else {
popupMenu.append(new MenuItem({ popupMenu.append(new MenuItem({
label: 'Copy link address', label: 'Copy link &address',
click() { click() {
clipboard.writeText(url); clipboard.writeText(url);
}, },
@ -93,7 +93,7 @@ function onLinkContextMenu(ev, params) {
if (addSaveAs) { if (addSaveAs) {
popupMenu.append(new MenuItem({ popupMenu.append(new MenuItem({
label: 'Save image as...', label: 'Sa&ve image as...',
click() { click() {
const targetFileName = params.titleText || "image.png"; const targetFileName = params.titleText || "image.png";
const filePath = dialog.showSaveDialog({ const filePath = dialog.showSaveDialog({
@ -128,18 +128,22 @@ function onLinkContextMenu(ev, params) {
function _CutCopyPasteSelectContextMenus(params) { function _CutCopyPasteSelectContextMenus(params) {
return [{ return [{
role: 'cut', role: 'cut',
label: 'Cu&t',
enabled: params.editFlags.canCut, enabled: params.editFlags.canCut,
}, { }, {
role: 'copy', role: 'copy',
label: '&Copy',
enabled: params.editFlags.canCopy, enabled: params.editFlags.canCopy,
}, { }, {
role: 'paste', role: 'paste',
label: '&Paste',
enabled: params.editFlags.canPaste, enabled: params.editFlags.canPaste,
}, { }, {
role: 'pasteandmatchstyle', role: 'pasteandmatchstyle',
enabled: params.editFlags.canPaste, enabled: params.editFlags.canPaste,
}, { }, {
role: 'selectall', role: 'selectall',
label: "Select &All",
enabled: params.editFlags.canSelectAll, enabled: params.editFlags.canSelectAll,
}]; }];
} }

25
src/i18n/strings/mn.json Normal file
View File

@ -0,0 +1,25 @@
{
"Your Riot configuration contains invalid JSON. Please correct the problem and reload the page.": "Таны Риот тохиргоо буруу ЖСОН агуулж байна. Зөв болгоод, хуудсыг ахин дуудна уу.",
"The message from the parser is: %(message)s": "Парсераас ирсэн мессеж нь: %(message)s",
"Invalid JSON": "Буруу ЖСОН",
"Your Riot is misconfigured": "Таны РИОТ тохиргоо буруу",
"Unexpected error preparing the app. See console for details.": "Апп бэлдэх үед гарах ёсгүй алдаа. Дэлгэрэнгүйг консолоос харна уу.",
"Invalid configuration: can only specify one of default_server_config, default_server_name, or default_hs_url.": "Буруу тохиргоо: default_server_config, default_server_name, эсвэл default_hs_url утгын зөвхөн аль нэгийг л зааж болно.",
"Invalid configuration: no default server specified.": "Буруу тохиргоо: Өгөгдсөл серверийг зааж өгөөгүй байна.",
"Riot Desktop on %(platformName)s": "%(platformName)s дээрх Риот Десктоп",
"Unknown device": "Үл мэдэгдэх төхөөрөмж",
"%(appName)s via %(browserName)s on %(osName)s": "%(osName)s дээр %(browserName)s -ээр дамжсан %(appName)s",
"You need to be using HTTPS to place a screen-sharing call.": "Та дэлгэц хуваалцах дуудлага хийхдээ HTTPS ашиглах ёстой.",
"powered by Matrix": "Matrix - Ивээв",
"Custom Server Options": "Кастом серверийн сонголтууд",
"You can use the custom server options to sign into other Matrix servers by specifying a different homeserver URL. This allows you to use Riot with an existing Matrix account on a different homeserver.": "Та кастом серверийн сонголтууд ашиглан серверийн хаягийг зааж, өөр сервер рүү нэвтэрч болно. Энэ нь танд Риотыг одоо байгаа матрикс аккаунтаараа өөр сервер дээр ашиглах боломж олгоно.",
"Dismiss": "Орхих",
"Welcome to Riot.im": "Riot.im -д тавтай морил",
"Decentralised, encrypted chat & collaboration powered by [matrix]": "Төвлөрсөн бус, нууцлалтай чат & хамтын ажиллагааг [matrix] - ивээв",
"Sign In": "Нэвтрэх",
"Create Account": "Хэрэглэгч үүсгэх",
"Need help?": "Тусламж хэрэгтэй юу?",
"Chat with Riot Bot": "Риот боттой чатлах",
"Explore rooms": "Өрөөнүүд үзэх",
"Room Directory": "Өрөөний директор"
}