forked from MapComplete/MapComplete
Merge branch 'master' into develop
This commit is contained in:
commit
d6b56f4eb3
61 changed files with 691 additions and 458 deletions
|
@ -335,7 +335,11 @@ In the case that MapComplete is pointed to the testing grounds, the edit will be
|
|||
if (v["asHumanString"]) {
|
||||
v = v.asHumanString(true, false)
|
||||
} else if (useLang !== undefined && v?.translations !== undefined) {
|
||||
v = v.translations[useLang] ?? v.translations["*"] ?? v?.textFor(useLang) ?? v
|
||||
v =
|
||||
v.translations[useLang] ??
|
||||
v.translations["*"] ??
|
||||
v?.textFor(useLang) ??
|
||||
v
|
||||
} else if (v.InnerConstructElement !== undefined) {
|
||||
console.warn(
|
||||
"SubstituteKeys received a BaseUIElement to substitute in - this is probably a bug and will be downcast to a string\nThe key is",
|
||||
|
@ -346,12 +350,11 @@ In the case that MapComplete is pointed to the testing grounds, the edit will be
|
|||
v = v.InnerConstructElement()?.textContent
|
||||
} else if (typeof v === "object") {
|
||||
v = JSON.stringify(v)
|
||||
} else{
|
||||
} else {
|
||||
v = "" + v
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
v = v.replace(/\n/g, "<br/>")
|
||||
} else {
|
||||
// v === undefined
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue