From 2dbdcaa2ba6694bdce3ec37b6b9a43bc7fe26081 Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Sat, 10 Jul 2021 21:03:41 +0200 Subject: [PATCH] Move TileRange to seperate file --- Models/TileRange.ts | 1 - Utils.ts | 12 ++---------- scripts/generateCache.ts | 3 ++- 3 files changed, 4 insertions(+), 12 deletions(-) diff --git a/Models/TileRange.ts b/Models/TileRange.ts index f3c59af23..e1dba5532 100644 --- a/Models/TileRange.ts +++ b/Models/TileRange.ts @@ -5,5 +5,4 @@ export interface TileRange { yend: number, total: number, zoomlevel: number - } \ No newline at end of file diff --git a/Utils.ts b/Utils.ts index 05ebcbaab..cb8835656 100644 --- a/Utils.ts +++ b/Utils.ts @@ -1,4 +1,5 @@ import * as colors from "./assets/colors.json" +import {TileRange} from "./Models/TileRange"; export class Utils { @@ -134,7 +135,7 @@ export class Utils { } return newArr; } - + public static MergeTags(a: any, b: any) { const t = {}; for (const k in a) { @@ -449,12 +450,3 @@ export class Utils { } } -export interface TileRange { - xstart: number, - ystart: number, - xend: number, - yend: number, - total: number, - zoomlevel: number - -} \ No newline at end of file diff --git a/scripts/generateCache.ts b/scripts/generateCache.ts index 77dfa8653..f7651c4b4 100644 --- a/scripts/generateCache.ts +++ b/scripts/generateCache.ts @@ -1,7 +1,7 @@ /** * Generates a collection of geojson files based on an overpass query for a given theme */ -import {TileRange, Utils} from "../Utils"; +import {Utils} from "../Utils"; Utils.runningFromConsole = true import {Overpass} from "../Logic/Osm/Overpass"; @@ -17,6 +17,7 @@ import MetaTagging from "../Logic/MetaTagging"; import LayerConfig from "../Customizations/JSON/LayerConfig"; import {GeoOperations} from "../Logic/GeoOperations"; import {UIEventSource} from "../Logic/UIEventSource"; +import {TileRange} from "../Models/TileRange"; function createOverpassObject(theme: LayoutConfig) {