From b92f0a6d090a88626cffb6d07fb3ef4e69e3b885 Mon Sep 17 00:00:00 2001 From: Quincy Morgan <2046746+quincylvania@users.noreply.github.com> Date: Tue, 22 Sep 2020 15:11:12 -0400 Subject: [PATCH] Fix styling issue in panels Add lang attribute to more text (re: #7963) --- css/80_app.css | 2 +- modules/ui/panels/measurement.js | 3 +-- modules/ui/success.js | 2 +- 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/css/80_app.css b/css/80_app.css index a0ebcd792..bc1778718 100644 --- a/css/80_app.css +++ b/css/80_app.css @@ -4284,7 +4284,7 @@ img.tile-debug { display: none; } -.panel-content li span { +.panel-content li span:not(.localized-text) { display: inline-block; white-space: nowrap; margin: 0 8px; diff --git a/modules/ui/panels/measurement.js b/modules/ui/panels/measurement.js index f06057f59..cd5333c3c 100644 --- a/modules/ui/panels/measurement.js +++ b/modules/ui/panels/measurement.js @@ -144,10 +144,9 @@ export function uiPanelMeasurement(context) { } if (length) { - var lengthLabel = t('info_panels.measurement.' + (closed ? 'perimeter' : 'length')); list .append('li') - .html(lengthLabel + ':') + .html(t.html('info_panels.measurement.' + (closed ? 'perimeter' : 'length')) + ':') .append('span') .html(displayLength(length, isImperial)); } diff --git a/modules/ui/success.js b/modules/ui/success.js index 64db51b07..78918f886 100644 --- a/modules/ui/success.js +++ b/modules/ui/success.js @@ -243,7 +243,7 @@ export function uiSuccess(context) { .attr('href', d.url) .html(t.html(`community.${d.id}.name`)); - let descriptionHTML = t(`community.${d.id}.description`, replacements); + let descriptionHTML = t.html(`community.${d.id}.description`, replacements); if (d.type === 'reddit') { // linkify subreddits #4997 descriptionHTML = descriptionHTML