Revert t function to returning the plain string by default

Add `t.html` function for getting the string with the `lang` attribute
This commit is contained in:
Quincy Morgan
2020-09-22 12:03:29 -04:00
parent a3549f9a76
commit 5435082d9c
132 changed files with 597 additions and 580 deletions
+9 -9
View File
@@ -54,7 +54,7 @@ export function uiNoteEditor(context) {
headerEnter
.append('h3')
.html(t('note.title'));
.html(t.html('note.title'));
var body = selection.selectAll('.body')
@@ -155,7 +155,7 @@ export function uiNoteEditor(context) {
var commentTextarea = noteSaveEnter
.append('textarea')
.attr('class', 'new-comment-input')
.attr('placeholder', t('note.inputPlaceholder', { html: false }))
.attr('placeholder', t('note.inputPlaceholder'))
.attr('maxlength', 1000)
.property('value', function(d) { return d.newComment; })
.call(utilNoAuto)
@@ -257,14 +257,14 @@ export function uiNoteEditor(context) {
authEnter
.append('span')
.html(t('note.login'));
.html(t.html('note.login'));
authEnter
.append('a')
.attr('target', '_blank')
.call(svgIcon('#iD-icon-out-link', 'inline'))
.append('span')
.html(t('login'))
.html(t.html('login'))
.on('click.note-login', function() {
d3_event.preventDefault();
osm.authenticate();
@@ -285,7 +285,7 @@ export function uiNoteEditor(context) {
prose = prose.enter()
.append('p')
.attr('class', 'note-save-prose')
.html(t('note.upload_explanation'))
.html(t.html('note.upload_explanation'))
.merge(prose);
osm.userDetails(function(err, user) {
@@ -308,7 +308,7 @@ export function uiNoteEditor(context) {
.attr('target', '_blank');
prose
.html(t('note.upload_explanation_with_user', { user: userLink.html() }));
.html(t.html('note.upload_explanation_with_user', { user: userLink.html() }));
});
}
@@ -334,12 +334,12 @@ export function uiNoteEditor(context) {
buttonEnter
.append('button')
.attr('class', 'button cancel-button secondary-action')
.html(t('confirm.cancel'));
.html(t.html('confirm.cancel'));
buttonEnter
.append('button')
.attr('class', 'button save-button action')
.html(t('note.save'));
.html(t.html('note.save'));
} else {
buttonEnter
@@ -349,7 +349,7 @@ export function uiNoteEditor(context) {
buttonEnter
.append('button')
.attr('class', 'button comment-button action')
.html(t('note.comment'));
.html(t.html('note.comment'));
}