diff --git a/Customizations/AllKnownLayouts.ts b/Customizations/AllKnownLayouts.ts
new file mode 100644
index 000000000..9697fd1ca
--- /dev/null
+++ b/Customizations/AllKnownLayouts.ts
@@ -0,0 +1,24 @@
+import {Groen} from "./Layouts/Groen";
+import {Toilets} from "./Layouts/Toilets";
+import {GRB} from "./Layouts/GRB";
+import {Statues} from "./Layouts/Statues";
+import {Bookcases} from "./Layouts/Bookcases";
+
+export class AllKnownLayouts {
+ public static allSets: any = AllKnownLayouts.AllLayouts();
+
+ private static AllLayouts() {
+ const layouts = [
+ new Groen(),
+ new GRB(),
+ /*new Toilets(),
+ new Statues(),
+ new Bookcases()*/
+ ];
+ const allSets = {};
+ for (const layout of layouts) {
+ allSets[layout.name] = layout;
+ }
+ return allSets;
+ }
+}
diff --git a/LayerDefinition.ts b/Customizations/LayerDefinition.ts
similarity index 57%
rename from LayerDefinition.ts
rename to Customizations/LayerDefinition.ts
index acb76c9c7..bd64aa4ec 100644
--- a/LayerDefinition.ts
+++ b/Customizations/LayerDefinition.ts
@@ -1,14 +1,12 @@
-import {Basemap} from "./Logic/Basemap";
-import {ElementStorage} from "./Logic/ElementStorage";
-import {Changes} from "./Logic/Changes";
-import {QuestionDefinition} from "./Logic/Question";
-import {TagMappingOptions} from "./UI/TagMapping";
-import {UIEventSource} from "./UI/UIEventSource";
-import {UIElement} from "./UI/UIElement";
-import {Tag, TagsFilter} from "./Logic/TagsFilter";
-import {FilteredLayer} from "./Logic/FilteredLayer";
-import {UserDetails} from "./Logic/OsmConnection";
-
+import {Tag, TagsFilter} from "../Logic/TagsFilter";
+import {UIElement} from "../UI/UIElement";
+import {Basemap} from "../Logic/Basemap";
+import {ElementStorage} from "../Logic/ElementStorage";
+import {UIEventSource} from "../UI/UIEventSource";
+import {FilteredLayer} from "../Logic/FilteredLayer";
+import {Changes} from "../Logic/Changes";
+import {UserDetails} from "../Logic/OsmConnection";
+import {TagRenderingOptions} from "./TagRendering";
export class LayerDefinition {
@@ -19,8 +17,8 @@ export class LayerDefinition {
minzoom: number;
overpassFilter: TagsFilter;
- elementsToShow: (TagMappingOptions | QuestionDefinition | UIElement)[];
- questions: QuestionDefinition[]; // Questions are shown below elementsToShow in a questionPicker
+ title: TagRenderingOptions;
+ elementsToShow: TagRenderingOptions[];
style: (tags: any) => { color: string, icon: any };
diff --git a/Layers/Artwork.ts b/Customizations/Layers/Artwork.ts
similarity index 88%
rename from Layers/Artwork.ts
rename to Customizations/Layers/Artwork.ts
index 80897af6d..eb65dc5c6 100644
--- a/Layers/Artwork.ts
+++ b/Customizations/Layers/Artwork.ts
@@ -1,10 +1,7 @@
import {LayerDefinition} from "../LayerDefinition";
-import {FixedUiElement} from "../UI/Base/FixedUiElement";
+import {QuestionDefinition} from "../../Logic/Question";
+import {Tag} from "../../Logic/TagsFilter";
import L from "leaflet";
-import {CommonTagMappings} from "./CommonTagMappings";
-import {TagMappingOptions} from "../UI/TagMapping";
-import {QuestionDefinition} from "../Logic/Question";
-import {Tag} from "../Logic/TagsFilter";
export class Artwork extends LayerDefinition {
@@ -40,7 +37,8 @@ export class Artwork extends LayerDefinition {
iconUrl: "assets/statue.svg",
iconSize: [40, 40],
text: "hi"
- })
+ }),
+ color: "#0000ff"
};
}
@@ -80,8 +78,7 @@ export class Artwork extends LayerDefinition {
- new TagMappingOptions({key: "image", template: ""}),
- CommonTagMappings.osmLink
+ new TagMappingOptions({key: "image", template: ""})
];
}
diff --git a/Layers/Bookcases.ts b/Customizations/Layers/Bookcases.ts
similarity index 90%
rename from Layers/Bookcases.ts
rename to Customizations/Layers/Bookcases.ts
index 6723064e8..81015f140 100644
--- a/Layers/Bookcases.ts
+++ b/Customizations/Layers/Bookcases.ts
@@ -1,8 +1,8 @@
import {LayerDefinition} from "../LayerDefinition";
-import {TagMappingOptions} from "../UI/TagMapping";
import L from "leaflet";
-import {QuestionDefinition} from "../Logic/Question";
-import {Tag} from "../Logic/TagsFilter";
+import {Tag} from "../../Logic/TagsFilter";
+import {QuestionDefinition} from "../../Logic/Question";
+import {TagRenderingOptions} from "../TagRendering";
export class Bookcases extends LayerDefinition {
@@ -31,13 +31,15 @@ export class Bookcases extends LayerDefinition {
icon: new L.icon({
iconUrl: "assets/bookcase.svg",
iconSize: [40, 40]
- })
+ }),
+ color: "#0000ff"
};
}
this.elementsToShow = [
-
+
+
new TagMappingOptions({
key: "name",
template: "{name}",
diff --git a/Layers/Bos.ts b/Customizations/Layers/Bos.ts
similarity index 67%
rename from Layers/Bos.ts
rename to Customizations/Layers/Bos.ts
index 1398a9458..51520ff1a 100644
--- a/Layers/Bos.ts
+++ b/Customizations/Layers/Bos.ts
@@ -1,9 +1,11 @@
import {LayerDefinition} from "../LayerDefinition";
-import {Quests} from "../Quests";
-import {TagMappingOptions} from "../UI/TagMapping";
-import L from "leaflet"
-import {CommonTagMappings} from "./CommonTagMappings";
-import {Or, Tag} from "../Logic/TagsFilter";
+import {Quests} from "../../Quests";
+import {And, Or, Tag} from "../../Logic/TagsFilter";
+import {AccessTag} from "../Questions/AccessTag";
+import {OperatorTag} from "../Questions/OperatorTag";
+import {TagRenderingOptions} from "../TagRendering";
+import {NameQuestion} from "../Questions/NameQuestion";
+import {NameInline} from "../Questions/NameInline";
export class Bos extends LayerDefinition {
@@ -27,17 +29,12 @@ export class Bos extends LayerDefinition {
this.maxAllowedOverlapPercentage = 10;
this.minzoom = 13;
- this.questions = [Quests.nameOf(this.name), Quests.accessNatureReserve, Quests.operator];
this.style = this.generateStyleFunction();
+ this.title = new NameInline("bos");
this.elementsToShow = [
- new TagMappingOptions({
- key: "name",
- template: "{name}",
- missing: "Naamloos bos"
- }),
-
- CommonTagMappings.access,
- CommonTagMappings.operator,
+ new NameQuestion(),
+ new AccessTag(),
+ new OperatorTag()
];
}
@@ -47,9 +44,9 @@ export class Bos extends LayerDefinition {
const self = this;
return function (properties: any) {
let questionSeverity = 0;
- for (const qd of self.questions) {
- if (qd.isApplicable(properties)) {
- questionSeverity = Math.max(questionSeverity, qd.severity);
+ for (const qd of self.elementsToShow) {
+ if (qd.IsQuestioning(properties)) {
+ questionSeverity = Math.max(questionSeverity, qd.options.priority ?? 0);
}
}
@@ -63,7 +60,7 @@ export class Bos extends LayerDefinition {
let colour = colormapping[questionSeverity];
while (colour == undefined) {
questionSeverity--;
- colormapping[questionSeverity];
+ colour = colormapping[questionSeverity];
}
return {
diff --git a/Customizations/Layers/GrbToFix.ts b/Customizations/Layers/GrbToFix.ts
new file mode 100644
index 000000000..a7e395aa8
--- /dev/null
+++ b/Customizations/Layers/GrbToFix.ts
@@ -0,0 +1,88 @@
+import {LayerDefinition} from "../LayerDefinition";
+import L from "leaflet"
+import {And, Regex, Tag} from "../../Logic/TagsFilter";
+import {TagRenderingOptions} from "../TagRendering";
+
+export class GrbToFix extends LayerDefinition {
+
+ constructor() {
+ super();
+
+ this.name = "grb";
+ this.newElementTags = undefined;
+ this.icon = "./assets/star.svg";
+ this.overpassFilter = new Regex("fixme", "GRB");
+ this.minzoom = 13;
+
+
+
+ this.style = function (tags) {
+ return {
+ icon: new L.icon({
+ iconUrl: "assets/star.svg",
+ iconSize: [40, 40],
+ text: "hi"
+ }),
+ color: "#ff0000"
+ };
+
+ }
+
+ this.title = new TagRenderingOptions({
+ freeform: {
+ key: "fixme",
+ renderTemplate: "{fixme}",
+ template: "Fixme $$$"
+ }
+ })
+
+ this.elementsToShow = [
+
+ new TagRenderingOptions(
+ {
+ freeform: {
+ key: "addr:street",
+ renderTemplate: "Het adres is {addr:street} {addr:housenumber}",
+ template: "Straat? $$$"
+ }
+ }
+ ),
+
+ new TagRenderingOptions({
+
+ question: "Wat is het huisnummer?",
+ tagsPreprocessor: tags => {
+ const newTags = {};
+ newTags["addr:housenumber"] = tags["addr:housenumber"]
+ newTags["addr:street"] = tags["addr:street"]
+
+ const telltale = "GRB thinks that this has number ";
+ const index = tags.fixme.indexOf(telltale);
+ if (index >= 0) {
+ const housenumber = tags.fixme.slice(index + telltale.length);
+ newTags["grb:housenumber:human"] = housenumber;
+ newTags["grb:housenumber"] = housenumber == "no number" ? "" : housenumber;
+ }
+
+ return newTags;
+ },
+ mappings: [
+ {
+ k: new And([new Tag("addr:housenumber", "{grb:housenumber}"), new Tag("fixme", "")]),
+ txt: "Volg GRB: {grb:housenumber:human}",
+ substitute: true
+ },
+ {
+ k: new And([new Tag("addr:housenumber", "{addr:housenumber}"), new Tag("fixme", "")]),
+ txt: "Volg OSM: {addr:housenumber}",
+ substitute: true
+ }
+ ]
+ })
+
+
+ ];
+ }
+
+
+}
\ No newline at end of file
diff --git a/Layers/NatureReserves.ts b/Customizations/Layers/NatureReserves.ts
similarity index 67%
rename from Layers/NatureReserves.ts
rename to Customizations/Layers/NatureReserves.ts
index ae6a5f9bf..c74176633 100644
--- a/Layers/NatureReserves.ts
+++ b/Customizations/Layers/NatureReserves.ts
@@ -1,8 +1,10 @@
import {LayerDefinition} from "../LayerDefinition";
-import {Quests} from "../Quests";
-import {TagMappingOptions} from "../UI/TagMapping";
-import {CommonTagMappings} from "./CommonTagMappings";
-import {Or, Tag} from "../Logic/TagsFilter";
+import {Or, Tag} from "../../Logic/TagsFilter";
+import {TagRenderingOptions} from "../TagRendering";
+import {AccessTag} from "../Questions/AccessTag";
+import {OperatorTag} from "../Questions/OperatorTag";
+import {NameQuestion} from "../Questions/NameQuestion";
+import {NameInline} from "../Questions/NameInline";
export class NatureReserves extends LayerDefinition {
@@ -17,16 +19,12 @@ export class NatureReserves extends LayerDefinition {
this.newElementTags = [new Tag("leisure", "nature_reserve"),
new Tag("fixme", "Toegevoegd met MapComplete, geometry nog uit te tekenen")]
this.minzoom = 13;
- this.questions = [Quests.nameOf(this.name), Quests.accessNatureReserve, Quests.operator];
+ this.title = new NameInline("natuurreservaat");
this.style = this.generateStyleFunction();
this.elementsToShow = [
- new TagMappingOptions({
- key: "name",
- template: "{name}",
- missing: "Naamloos gebied"
- }),
- CommonTagMappings.access,
- CommonTagMappings.operator,
+ new NameQuestion(),
+ new AccessTag(),
+ new OperatorTag(),
];
}
@@ -35,9 +33,9 @@ export class NatureReserves extends LayerDefinition {
const self = this;
return function (properties: any) {
let questionSeverity = 0;
- for (const qd of self.questions) {
- if (qd.isApplicable(properties)) {
- questionSeverity = Math.max(questionSeverity, qd.severity);
+ for (const qd of self.elementsToShow) {
+ if (qd.IsQuestioning(properties)) {
+ questionSeverity = Math.max(questionSeverity, qd.options.priority ?? 0);
}
}
@@ -51,7 +49,7 @@ export class NatureReserves extends LayerDefinition {
let colour = colormapping[questionSeverity];
while (colour == undefined) {
questionSeverity--;
- colormapping[questionSeverity];
+ colour = colormapping[questionSeverity];
}
return {
diff --git a/Layers/Park.ts b/Customizations/Layers/Park.ts
similarity index 56%
rename from Layers/Park.ts
rename to Customizations/Layers/Park.ts
index cc74a6121..373643500 100644
--- a/Layers/Park.ts
+++ b/Customizations/Layers/Park.ts
@@ -1,8 +1,11 @@
import {LayerDefinition} from "../LayerDefinition";
-import {Quests} from "../Quests";
-import {TagMappingOptions} from "../UI/TagMapping";
-import {CommonTagMappings} from "./CommonTagMappings";
-import {Or, Tag} from "../Logic/TagsFilter";
+import {Quests} from "../../Quests";
+import {And, Or, Tag} from "../../Logic/TagsFilter";
+import {AccessTag} from "../Questions/AccessTag";
+import {OperatorTag} from "../Questions/OperatorTag";
+import {TagRenderingOptions} from "../TagRendering";
+import {NameQuestion} from "../Questions/NameQuestion";
+import {NameInline} from "../Questions/NameInline";
export class Park extends LayerDefinition {
@@ -10,25 +13,16 @@ export class Park extends LayerDefinition {
super();
this.name = "park";
this.icon = "./assets/tree_white_background.svg";
- this.overpassFilter =
- new Or([new Tag("leisure","park"), new Tag("landuse","village_green")]);
- this.newElementTags = [new Tag("leisure", "park"),
+ this.overpassFilter =
+ new Or([new Tag("leisure", "park"), new Tag("landuse", "village_green")]);
+ this.newElementTags = [new Tag("leisure", "park"),
new Tag("fixme", "Toegevoegd met MapComplete, geometry nog uit te tekenen")];
this.maxAllowedOverlapPercentage = 25;
this.minzoom = 13;
- this.questions = [Quests.nameOf("park")];
this.style = this.generateStyleFunction();
- this.elementsToShow = [
- new TagMappingOptions({
- key: "name",
- template: "{name}",
- missing: "Naamloos park"
- }),
-
- CommonTagMappings.access,
- CommonTagMappings.operator,
- ];
+ this.title = new NameInline("park");
+ this.elementsToShow = [new NameQuestion()];
}
@@ -39,9 +33,9 @@ export class Park extends LayerDefinition {
const self = this;
return function (properties: any) {
let questionSeverity = 0;
- for (const qd of self.questions) {
- if (qd.isApplicable(properties)) {
- questionSeverity = Math.max(questionSeverity, qd.severity);
+ for (const qd of self.elementsToShow) {
+ if (qd.IsQuestioning(properties)) {
+ questionSeverity = Math.max(questionSeverity, qd.options.priority ?? 0);
}
}
@@ -55,7 +49,7 @@ export class Park extends LayerDefinition {
let colour = colormapping[questionSeverity];
while (colour == undefined) {
questionSeverity--;
- colormapping[questionSeverity];
+ colour = colormapping[questionSeverity];
}
return {
diff --git a/Layers/Toilets.ts b/Customizations/Layers/Toilets.ts
similarity index 93%
rename from Layers/Toilets.ts
rename to Customizations/Layers/Toilets.ts
index 6e7768619..2c0b69b43 100644
--- a/Layers/Toilets.ts
+++ b/Customizations/Layers/Toilets.ts
@@ -1,9 +1,8 @@
import {LayerDefinition} from "../LayerDefinition";
-import {Quests} from "../Quests";
-import {FixedUiElement} from "../UI/Base/FixedUiElement";
-import {TagMappingOptions} from "../UI/TagMapping";
+import {Quests} from "../../Quests";
+import {FixedUiElement} from "../../UI/Base/FixedUiElement";
import L from "leaflet";
-import {Tag} from "../Logic/TagsFilter";
+import {Tag} from "../../Logic/TagsFilter";
export class Toilets extends LayerDefinition{
diff --git a/Customizations/Layout.ts b/Customizations/Layout.ts
new file mode 100644
index 000000000..9ff0e4cd2
--- /dev/null
+++ b/Customizations/Layout.ts
@@ -0,0 +1,53 @@
+import {LayerDefinition} from "./LayerDefinition";
+
+/**
+ * A layout is a collection of settings of the global view (thus: welcome text, title, selection of layers).
+ */
+export class Layout {
+ public name: string;
+ public title: string;
+ public layers: LayerDefinition[];
+ public welcomeMessage: string;
+ public gettingStartedPlzLogin: string;
+ public welcomeBackMessage: string;
+
+ public startzoom: number;
+ public startLon: number;
+ public startLat: number;
+ public welcomeTail: string;
+
+
+ constructor(
+ name: string,
+ title: string,
+ layers: LayerDefinition[],
+ startzoom: number,
+ startLat: number,
+ startLon: number,
+ welcomeMessage: string,
+ gettingStartedPlzLogin: string,
+ welcomeBackMessage: string,
+ welcomeTail: string = ""
+ ) {
+ this.title = title;
+ this.startLon = startLon;
+ this.startLat = startLat;
+ this.startzoom = startzoom;
+ this.name = name;
+ this.layers = layers;
+ this.welcomeMessage = welcomeMessage;
+ this.gettingStartedPlzLogin = gettingStartedPlzLogin;
+ this.welcomeBackMessage = welcomeBackMessage;
+ this.welcomeTail = welcomeTail;
+ }
+
+/*
+
+
+ static statues = new Layout(
+
+ );
+
+*/
+}
+
diff --git a/Customizations/Layouts/Bookcases.ts b/Customizations/Layouts/Bookcases.ts
new file mode 100644
index 000000000..7d02aabb9
--- /dev/null
+++ b/Customizations/Layouts/Bookcases.ts
@@ -0,0 +1,27 @@
+import {Layout} from "../Layout";
+import * as Layer from "../Layers/Bookcases";
+
+export class Bookcases extends Layout{
+ constructor() {
+ super( "bookcases",
+ "Open Bookcase Map",
+ [new Layer.Bookcases()],
+ 14,
+ 51.2,
+ 3.2,
+
+
+ "
Open BoekenkastjesKaart
\n" +
+ "\n" +
+ "
" +
+ "Help mee met het creëeren van een volledige kaart met alle boekenruilkastjes!" +
+ "Een boekenruilkastje is een vaste plaats in publieke ruimte waar iedereen een boek in kan zetten of uit kan meenemen." +
+ "Meestal een klein kastje of doosje dat op straat staat, maar ook een oude telefooncellen of een schap in een station valt hieronder."+
+ "
",
+ "Klik op een boekenruilkastje om vragen te beantwoorden");
+ }
+}
\ No newline at end of file
diff --git a/Customizations/Layouts/GRB.ts b/Customizations/Layouts/GRB.ts
new file mode 100644
index 000000000..93514a1de
--- /dev/null
+++ b/Customizations/Layouts/GRB.ts
@@ -0,0 +1,21 @@
+import {Layout} from "../Layout";
+import {GrbToFix} from "../Layers/GrbToFix";
+
+export class GRB extends Layout {
+ constructor() {
+ super("grb",
+ "Grb import fix tool",
+ [new GrbToFix()],
+ 15,
+ 51.2083,
+ 3.2279,
+
+
+ "
GRB Fix tool
\n" +
+ "\n" +
+ "Expert use only"
+
+ ,
+ "", "");
+ }
+}
\ No newline at end of file
diff --git a/Customizations/Layouts/Groen.ts b/Customizations/Layouts/Groen.ts
new file mode 100644
index 000000000..2432869d4
--- /dev/null
+++ b/Customizations/Layouts/Groen.ts
@@ -0,0 +1,50 @@
+import {NatureReserves} from "../Layers/NatureReserves";
+import {Park} from "../Layers/Park";
+import {Bos} from "../Layers/Bos";
+import {Layout} from "../Layout";
+
+export class Groen extends Layout {
+
+ constructor() {
+ super("groen",
+ "Buurtnatuur",
+ [new NatureReserves(), new Park(), new Bos()],
+ 10,
+ 50.8435,
+ 4.3688,
+ "\n" +
+ " " +
+ "
Breng jouw buurtnatuur in kaart
" +
+ "Natuur maakt gelukkig. Aan de hand van deze website willen we de natuur dicht bij ons beter inventariseren. Met als doel meer mensen te laten genieten van toegankelijke natuur én te strijden voor meer natuur in onze buurten. \n" +
+ "
" +
+ "
In welke natuurgebieden kan jij terecht? Hoe toegankelijk zijn ze?
" +
+ "
In welke bossen kan een gezin in jouw gemeente opnieuw op adem komen?
" +
+ "
Op welke onbekende plekjes is het zalig spelen?
" +
+ "
" +
+ "
Samen kleuren we heel Vlaanderen en Brussel groen.
Over groen ingekleurde gebieden weten we alles wat we willen weten.
" +
+ "
Bij rood ingekleurde gebieden ontbreekt nog heel wat info: klik een gebied aan en beantwoord de vragen.
" +
+ "
Je kan altijd een foto toevoegen
" +
+ "
Je kan ook zelf een gebied toevoegen door op de kaart te klikken
" +
+ "
" +
+ "" +
+ "
" +
+ "De oorspronkelijke data komt van OpenStreetMap en je antwoorden worden daar bewaard. Omdat iedereen vrij kan meewerken aan dit project, kunnen we niet garanderen dat er geen fouten opduiken." +
+ "
" +
+ "Je privacy is belangrijk. We tellen wel hoeveel gebruikers deze website bezoeken. We plaatsen een cookie waar geen persoonlijke informatie in bewaard wordt. " +
+ "Als je inlogt, komt er een tweede cookie bij met je inloggegevens." +
+ ""
+ );
+ }
+}
\ No newline at end of file
diff --git a/Customizations/Layouts/Statues.ts b/Customizations/Layouts/Statues.ts
new file mode 100644
index 000000000..76a46dd26
--- /dev/null
+++ b/Customizations/Layouts/Statues.ts
@@ -0,0 +1,26 @@
+import {Layout} from "../Layout";
+import {Artwork} from "../Layers/Artwork";
+
+export class Statues extends Layout{
+ constructor() {
+ super( "statues",
+ "Open Artwork Map",
+ [new Artwork()],
+ 10,
+ 50.8435,
+ 4.3688,
+
+
+ "
Open Statue Map
\n" +
+ "\n" +
+ "
" +
+ "Help with creating a map of all statues all over the world!"
+
+ ,
+ "
",
+ "Start by clicking a pin and answering the questions");
+ }
+
+}
\ No newline at end of file
diff --git a/Customizations/Layouts/Toilets.ts b/Customizations/Layouts/Toilets.ts
new file mode 100644
index 000000000..c6c585e90
--- /dev/null
+++ b/Customizations/Layouts/Toilets.ts
@@ -0,0 +1,24 @@
+import {Layout} from "../Layout";
+import * as Layer from "../Layers/Toilets";
+
+export class Toilets extends Layout{
+ constructor() {
+ super( "toilets",
+ "Open Toilet Map",
+ [new Layer.Toilets()],
+ 12,
+ 51.2,
+ 3.2,
+
+
+ "
Open Toilet Map
\n" +
+ "\n" +
+ "
Help us to create the most complete map about all the toilets in the world, based on openStreetMap." +
+ "One can answer questions here, which help users all over the world to find an accessible toilet, close to them.
"
+ }
+
+ if (this.IsKnown()) {
+ const html = this.RenderAnwser();
+ if (html == "") {
+ return "";
+ }
+ return "" +
+ "" + html + "" + this._editButton.Render() +
+ "";
+ }
+
+ return "";
+
+ }
+
+ InnerUpdate(htmlElement: HTMLElement) {
+ super.InnerUpdate(htmlElement);
+ this._questionElement.Update();
+ this._saveButton.Update();
+ this._skipButton.Update();
+ this._textField?.Update();
+ this._editButton.Update();
+ }
+
+}
\ No newline at end of file
diff --git a/Layers/CommonTagMappings.ts b/Layers/CommonTagMappings.ts
deleted file mode 100644
index f64b163fb..000000000
--- a/Layers/CommonTagMappings.ts
+++ /dev/null
@@ -1,60 +0,0 @@
-import {TagMappingOptions} from "../UI/TagMapping";
-import {Img} from "../UI/Img";
-
-
-export class CommonTagMappings {
-
-
- public static access = new TagMappingOptions({
- key: "access",
- mapping: {
- yes: "Vrij toegankelijk (op de paden)",
- no: "Niet toegankelijk",
- private: "Niet toegankelijk, want privegebied",
- permissive: "Toegankelijk, maar het is privegebied",
- guided: "Enkel met gids of op activiteit"
- }
- });
-
- public static operator = new TagMappingOptions({
- key: "operator",
- template: "Beheer door {operator}",
- mapping: {
- private: 'Beheer door een privepersoon of organisatie'
- }
-
- });
- public static osmLink = new TagMappingOptions({
- key: "id",
- mapping: {
- "node/-1": ""
- },
- template: "" +
- Img.osmAbstractLogo +
- ""
- });
-
- public static wikipediaLink = new TagMappingOptions({
- key: "wikipedia",
- missing: "",
- freeform: (value: string) => {
- let link = "";
- // @ts-ignore
- if (value.startsWith("https")) {
- link = value;
- } else {
-
- const splitted = value.split(":");
- const language = splitted[0];
- splitted.shift();
- const page = splitted.join(":");
- link = 'https://' + language + '.wikipedia.org/wiki/' + page;
-
- }
- return "" +
- "" +
- "";
- }
- });
-}
\ No newline at end of file
diff --git a/Layers/GrbToFix.ts b/Layers/GrbToFix.ts
deleted file mode 100644
index 38e569dca..000000000
--- a/Layers/GrbToFix.ts
+++ /dev/null
@@ -1,58 +0,0 @@
-import {LayerDefinition} from "../LayerDefinition";
-import {QuestionDefinition} from "../Logic/Question";
-import {TagMappingOptions} from "../UI/TagMapping";
-import {CommonTagMappings} from "./CommonTagMappings";
-import L from "leaflet"
-import {Regex} from "../Logic/TagsFilter";
-
-export class GrbToFix extends LayerDefinition {
-
- constructor() {
- super();
-
- this.name = "grb";
- this.newElementTags = undefined;
- this.icon = "./assets/star.svg";
- this.overpassFilter = new Regex("fixme","GRB");
- this.minzoom = 13;
-
-
- this.questions = [
- QuestionDefinition.GrbNoNumberQuestion(),
- QuestionDefinition.GrbHouseNumberQuestion()
- ];
-
- this.style = function (tags) {
- return {
- icon: new L.icon({
- iconUrl: "assets/star.svg",
- iconSize: [40, 40],
- text: "hi"
- })
- };
-
- }
-
- this.elementsToShow = [
- new TagMappingOptions(
- {
- key: "fixme",
- template: "
Fixme
{fixme}",
- }),
- new TagMappingOptions({
- key: "addr:street",
- template: "Straat: {addr:street}",
- missing: "Geen straat bekend"
- }),
- new TagMappingOptions({
- key: "addr:housenumber",
- template: "Nummer: {addr:housenumber}",
- missing: "Geen huisnummer bekend"
- }),
- CommonTagMappings.osmLink
-
- ];
- }
-
-
-}
\ No newline at end of file
diff --git a/Layers/KnownSet.ts b/Layers/KnownSet.ts
deleted file mode 100644
index 70f1444ae..000000000
--- a/Layers/KnownSet.ts
+++ /dev/null
@@ -1,175 +0,0 @@
-import {LayerDefinition} from "../LayerDefinition";
-import {NatureReserves} from "./NatureReserves";
-import {Toilets} from "./Toilets";
-import {Bos} from "./Bos";
-import {Park} from "./Park";
-import {Playground} from "./Playground";
-import {Bookcases} from "./Bookcases";
-import {Artwork} from "./Artwork";
-import {GrbToFix} from "./GrbToFix";
-
-
-export class KnownSet {
- public name: string;
- public title: string;
- public layers: LayerDefinition[];
- public welcomeMessage: string;
- public gettingStartedPlzLogin: string;
- public welcomeBackMessage: string;
-
- public startzoom: number;
- public startLon: number;
- public startLat: number;
-
- static allSets : any = {};
- public welcomeTail: string;
-
- constructor(
- name: string,
- title: string,
- layers: LayerDefinition[],
- startzoom: number,
- startLat: number,
- startLon: number,
- welcomeMessage: string,
- gettingStartedPlzLogin: string,
- welcomeBackMessage: string,
- welcomeTail: string = ""
- ) {
- this.title = title;
- this.startLon = startLon;
- this.startLat = startLat;
- this.startzoom = startzoom;
- this.name = name;
- this.layers = layers;
- this.welcomeMessage = welcomeMessage;
- this.gettingStartedPlzLogin = gettingStartedPlzLogin;
- this.welcomeBackMessage = welcomeBackMessage;
- this.welcomeTail = welcomeTail;
- KnownSet.allSets[this.name] = this;
- }
-
-
- static groen = new KnownSet("groen",
- "Buurtnatuur",
- [new NatureReserves(), new Park(), new Bos()],
- 10,
- 50.8435,
- 4.3688,
-"\n" +
- " " +
- "
Breng jouw buurtnatuur in kaart
" +
- "Natuur maakt gelukkig. Aan de hand van deze website willen we de natuur dicht bij ons beter inventariseren. Met als doel meer mensen te laten genieten van toegankelijke natuur én te strijden voor meer natuur in onze buurten. \n" +
- "
" +
- "
In welke natuurgebieden kan jij terecht? Hoe toegankelijk zijn ze?
" +
- "
In welke bossen kan een gezin in jouw gemeente opnieuw op adem komen?
" +
- "
Op welke onbekende plekjes is het zalig spelen?
" +
- "
" +
- "
Samen kleuren we heel Vlaanderen en Brussel groen.
Over groen ingekleurde gebieden weten we alles wat we willen weten.
" +
- "
Bij rood ingekleurde gebieden ontbreekt nog heel wat info: klik een gebied aan en beantwoord de vragen.
" +
- "
Je kan altijd een foto toevoegen
" +
- "
Je kan ook zelf een gebied toevoegen door op de kaart te klikken
" +
- "
" +
- "" +
- "
" +
- "De oorspronkelijke data komt van OpenStreetMap en je antwoorden worden daar bewaard. Omdat iedereen vrij kan meewerken aan dit project, kunnen we niet garanderen dat er geen fouten opduiken." +
- "
" +
- "Je privacy is belangrijk. We tellen wel hoeveel gebruikers deze website bezoeken. We plaatsen een cookie waar geen persoonlijke informatie in bewaard wordt. " +
- "Als je inlogt, komt er een tweede cookie bij met je inloggegevens." +
- ""
- );
-
- static openToiletMap = new KnownSet(
- "toilets",
- "Open Toilet Map",
- [new Toilets()],
- 12,
- 51.2,
- 3.2,
-
-
- "
Open Toilet Map
\n" +
- "\n" +
- "
Help us to create the most complete map about all the toilets in the world, based on openStreetMap." +
- "One can answer questions here, which help users all over the world to find an accessible toilet, close to them.
",
- "Start by clicking a pin and answering the questions"
- );
-
- static bookcases = new KnownSet(
- "bookcases",
- "Open Bookcase Map",
- [new Bookcases()],
- 14,
- 51.2,
- 3.2,
-
-
- "
Open BoekenkastjesKaart
\n" +
- "\n" +
- "
" +
- "Help mee met het creëeren van een volledige kaart met alle boekenruilkastjes!" +
- "Een boekenruilkastje is een vaste plaats in publieke ruimte waar iedereen een boek in kan zetten of uit kan meenemen." +
- "Meestal een klein kastje of doosje dat op straat staat, maar ook een oude telefooncellen of een schap in een station valt hieronder."+
- "