Skip to content

Commit 6287fe0

Browse files
authored
Merge pull request #7965 from moodyjmz/add-translator-notes-for-maths
🌐 i10n Add notes for maths dialog translations
2 parents 5725fae + e667217 commit 6287fe0

File tree

2 files changed

+18
-10
lines changed

2 files changed

+18
-10
lines changed

src/components/Math/ShowMathModal.vue

Lines changed: 15 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,7 @@
44
-->
55

66
<template>
7-
<NcDialog
8-
v-if="show"
9-
:name="
10-
isBlock
11-
? t('text', 'Edit display formula')
12-
: t('text', 'Edit inline formula')
13-
"
14-
size="large"
15-
@closing="$emit('close')">
7+
<NcDialog v-if="show" :name="dialogTitle" size="large" @closing="$emit('close')">
168
<NcTextArea
179
v-model="localLatex"
1810
:label="t('text', 'LaTeX formula')"
@@ -62,6 +54,20 @@ export default {
6254
localLatex: this.latex,
6355
}
6456
},
57+
computed: {
58+
dialogTitle() {
59+
if (this.isBlock) {
60+
// TRANSLATORS LaTeX formula, LaTeX is a system to display complex maths and scientific notation/formulae
61+
// TRANSLATORS Block means it appears on its own, akin to a paragraph
62+
// TRANSLATORS This is the title of a modal dialog to edit a LaTeX formula in Block mode
63+
return t('text', 'Edit block formula')
64+
}
65+
// TRANSLATORS LaTeX formula, LaTeX is a system to display complex maths and scientific notation/formulae
66+
// TRANSLATORS Inline means it appears with other content, eg "something [the formula] something"
67+
// TRANSLATORS This is the title of a modal dialog to edit a LaTeX formula in Inline mode
68+
return t('text', 'Edit inline formula')
69+
},
70+
},
6571
methods: {
6672
save() {
6773
this.$emit('save', this.localLatex)

src/components/Menu/entries.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -356,14 +356,16 @@ export const MenuEntries = [
356356
},
357357
{
358358
key: 'math-inline',
359+
// TRANSLATORS Inline level math/science formula menu item, eg "something [the formula] something"
359360
label: t('text', 'Inline formula'),
360361
icon: Sigma,
361362
isActive: 'math_inline',
362363
action: (command) => command.insertMathInline(),
363364
},
364365
{
365366
key: 'math-block',
366-
label: t('text', 'Display formula'),
367+
// TRANSLATORS Block level math/science formula menu item, appears on its own, akin to a paragraph
368+
label: t('text', 'Block formula'),
367369
icon: Sigma,
368370
isActive: 'math_block',
369371
action: (command) => command.insertMathBlock(),

0 commit comments

Comments
 (0)