forked from MapComplete/MapComplete
Translations
This commit is contained in:
parent
68929e4067
commit
1343955f44
6 changed files with 76 additions and 40 deletions
|
@ -4,7 +4,7 @@ import {LicenseInfo} from "../../Logic/Wikimedia";
|
|||
import {Imgur} from "../../Logic/Imgur";
|
||||
|
||||
|
||||
export class ImgurImage extends UIElement {
|
||||
export class ImgurImage extends UIElement {
|
||||
|
||||
|
||||
/***
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import {UIEventSource} from "./UIEventSource";
|
||||
import {TagDependantUIElement} from "../Customizations/UIElementConstructor";
|
||||
|
||||
export abstract class UIElement {
|
||||
export abstract class UIElement extends UIEventSource<string>{
|
||||
|
||||
private static nextId: number = 0;
|
||||
|
||||
|
@ -14,6 +14,7 @@ export abstract class UIElement {
|
|||
public static runningFromConsole = false;
|
||||
|
||||
protected constructor(source: UIEventSource<any>) {
|
||||
super("");
|
||||
this.id = "ui-element-" + UIElement.nextId;
|
||||
this._source = source;
|
||||
UIElement.nextId++;
|
||||
|
@ -50,7 +51,8 @@ export abstract class UIElement {
|
|||
// The element is not painted
|
||||
return;
|
||||
}
|
||||
element.innerHTML = this.InnerRender();
|
||||
this.setData(this.InnerRender());
|
||||
element.innerHTML = this.data;
|
||||
if (this._hideIfEmpty) {
|
||||
if (element.innerHTML === "") {
|
||||
element.parentElement.style.display = "none";
|
||||
|
|
|
@ -327,8 +327,39 @@ export default class Translations {
|
|||
}
|
||||
),
|
||||
bookcase: new T({
|
||||
nl: "Boekenruilkastje"
|
||||
})
|
||||
nl: "Boekenruilkastje",
|
||||
en: "Public bookcase"
|
||||
}),
|
||||
questions: {
|
||||
hasName: new T(
|
||||
{
|
||||
nl: "Heeft dit boekenruilkastje een naam?",
|
||||
en: "Does this bookcase have a name?"
|
||||
}),
|
||||
noname: new T({
|
||||
nl: "Neen, er is geen naam aangeduid op het boekenruilkastje",
|
||||
en: "No, there is no clearly visible name on the public bookcase"
|
||||
},
|
||||
),
|
||||
capacity: new T({
|
||||
nl: "Hoeveel boeken passen in dit boekenruilkastje?",
|
||||
en: "How much books fit into this public bookcase?"
|
||||
}),
|
||||
capacityRender: new T({
|
||||
nl: "Er passen {capacity} boeken in dit boekenruilkastje",
|
||||
en: "{capacity} books fit in this bookcase"
|
||||
}),
|
||||
capacityInput: new T({
|
||||
nl: "Er passen $nat$ boeken in dit boekenruilkastje",
|
||||
en: "$nat$ books fit into this public bookcase"
|
||||
}),
|
||||
bookkinds: new T({
|
||||
nl: "Wat voor soort boeken heeft dit boekenruilkastje?",
|
||||
en: "What kind of books can be found in this public bookcase"
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
},
|
||||
|
||||
image: {
|
||||
|
@ -469,8 +500,8 @@ export default class Translations {
|
|||
|
||||
}),
|
||||
phoneNumberIs: new T({
|
||||
en: "The phone number of this {category} is <a href='tel:{phone}'>{phone}</a>",
|
||||
nl: "Het telefoonnummer van {category} is <a href='tel:{phone}'>{phone}</a>"
|
||||
en: "The phone number of this {category} is <a href='tel:{phone}' target='_blank'>{phone}</a>",
|
||||
nl: "Het telefoonnummer van {category} is <a href='tel:{phone}' target='_blank'>{phone}</a>"
|
||||
})
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue