forked from MapComplete/MapComplete
Add control on FilteredLayer to show/hide layers
This commit is contained in:
parent
5aa620440a
commit
45351d9dd1
4 changed files with 43 additions and 16 deletions
|
@ -4,7 +4,7 @@ import { GRB } from "./Layouts/GRB";
|
|||
import { Statues } from "./Layouts/Statues";
|
||||
import { Bookcases } from "./Layouts/Bookcases";
|
||||
import Cyclofix from "./Layouts/Cyclofix";
|
||||
import { DrinkingWater } from "./Layouts/DrinkingWater";
|
||||
import { WalkByBrussels } from "./Layouts/WalkByBrussels";
|
||||
import { All } from "./Layouts/All";
|
||||
import { Layout } from "./Layout";
|
||||
|
||||
|
@ -18,7 +18,7 @@ export class AllKnownLayouts {
|
|||
new GRB(),
|
||||
new Cyclofix(),
|
||||
new Bookcases(),
|
||||
new DrinkingWater(),
|
||||
new WalkByBrussels(),
|
||||
all
|
||||
/*new Toilets(),
|
||||
new Statues(),
|
||||
|
@ -31,4 +31,13 @@ export class AllKnownLayouts {
|
|||
}
|
||||
return allSets;
|
||||
}
|
||||
|
||||
public static GetSets(layoutNames): any {
|
||||
const all = new All();
|
||||
for (const name of layoutNames) {
|
||||
all.layers = all.layers.concat(AllKnownLayouts.allSets[name].layers);
|
||||
}
|
||||
|
||||
return all;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,11 +1,14 @@
|
|||
import { Layout } from "../Layout";
|
||||
import { DrinkingWaterLayer } from "../Layers/DrinkingWater";
|
||||
import { NatureReserves } from "../Layers/NatureReserves";
|
||||
import { Park } from "../Layers/Park";
|
||||
import { BikeParkings } from "../Layers/BikeParkings";
|
||||
|
||||
export class DrinkingWater extends Layout {
|
||||
export class WalkByBrussels extends Layout {
|
||||
constructor() {
|
||||
super("drinkingwater",
|
||||
super("walkbybrussels",
|
||||
"Drinking Water Spots",
|
||||
[new DrinkingWaterLayer()],
|
||||
[new DrinkingWaterLayer(), new BikeParkings(), new Park(), new NatureReserves()],
|
||||
10,
|
||||
50.8435,
|
||||
4.3688,
|
Loading…
Add table
Add a link
Reference in a new issue