forked from MapComplete/MapComplete
Add support for units to clean up tags when they enter mapcomplete; add example of this usage in the climbing theme, add climbing theme title icons with length and needed number of carabiners
This commit is contained in:
parent
89f6f606c8
commit
966fcda8d1
20 changed files with 302 additions and 111 deletions
|
@ -9,6 +9,7 @@ import {LayoutConfigJson} from "../Customizations/JSON/LayoutConfigJson";
|
|||
import {Layer} from "leaflet";
|
||||
import LayerConfig from "../Customizations/JSON/LayerConfig";
|
||||
import SmallLicense from "../Models/smallLicense";
|
||||
import AllKnownLayers from "../Customizations/AllKnownLayers";
|
||||
|
||||
if(process.argv.length == 2){
|
||||
console.log("USAGE: ts-node scripts/fixTheme <path to theme>")
|
||||
|
@ -37,7 +38,7 @@ for (const layerConfigJson of themeConfigJson.layers) {
|
|||
layerConfigJson["source"] = { osmTags : tags}
|
||||
}
|
||||
// @ts-ignore
|
||||
const layerConfig = new LayerConfig(layerConfigJson, true)
|
||||
const layerConfig = new LayerConfig(layerConfigJson, AllKnownLayers.sharedUnits, "fix theme",true)
|
||||
const images : string[] = Array.from(layerConfig.ExtractImages())
|
||||
const remoteImages = images.filter(img => img.startsWith("http"))
|
||||
for (const remoteImage of remoteImages) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue