mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-13 18:27:35 +00:00
Bug 1575078 - Adds spaces between two words separated by commas.r=johannh
Differential Revision: https://phabricator.services.mozilla.com/D42668 --HG-- extra : moz-landing-system : lando
This commit is contained in:
parent
8cc2863d6c
commit
54c46b1ae8
@ -31,7 +31,9 @@ export class InfoItem extends HTMLElement {
|
||||
this.classList.add(labelText);
|
||||
|
||||
let info = this.shadowRoot.querySelector(".info");
|
||||
info.textContent = this.item.info;
|
||||
info.textContent = Array.isArray(this.item.info)
|
||||
? this.item.info.join(", ")
|
||||
: this.item.info;
|
||||
|
||||
// TODO: Use Fluent-friendly condition.
|
||||
if (this.item.label === "Modulus") {
|
||||
|
@ -89,13 +89,19 @@ add_task(async function test() {
|
||||
.toLowerCase();
|
||||
|
||||
let adjustedCertsElemInfo = adjustedCertsElem.sectionItems[i].info;
|
||||
|
||||
if (adjustedCertsElemInfo == null) {
|
||||
adjustedCertsElemInfo = "";
|
||||
}
|
||||
|
||||
if (typeof adjustedCertsElemInfo !== "string") {
|
||||
if (
|
||||
typeof adjustedCertsElemInfo !== "string" ||
|
||||
Array.isArray(adjustedCertsElemInfo)
|
||||
) {
|
||||
// there is a case where we have a boolean
|
||||
adjustedCertsElemInfo = adjustedCertsElemInfo.toString();
|
||||
adjustedCertsElemInfo = adjustedCertsElemInfo
|
||||
.toString()
|
||||
.replace(/,/g, ", ");
|
||||
}
|
||||
|
||||
Assert.ok(
|
||||
|
Loading…
Reference in New Issue
Block a user