From 4f5a2ebb476e424437f364677f169099da0585a4 Mon Sep 17 00:00:00 2001 From: Vinayak Kulkarni <19776877+vinayakkulkarni@users.noreply.github.com> Date: Sat, 28 Sep 2024 01:00:40 +0530 Subject: [PATCH] =?UTF-8?q?chore:=20minor=20housekeeping=20=F0=9F=8D=BF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Vinayak Kulkarni <19776877+vinayakkulkarni@users.noreply.github.com> --- lib/v-mapbox/constants/events/layer.ts | 2 +- lib/v-mapbox/constants/events/map.ts | 2 +- lib/v-mapbox/constants/events/popup.ts | 2 +- .../attribution/VControlAttribution.vue | 12 +- lib/v-mapbox/controls/attribution/types.ts | 2 +- .../fullscreen/VControlFullscreen.vue | 8 +- lib/v-mapbox/controls/fullscreen/types.ts | 2 +- .../controls/geolocate/VControlGeolocate.vue | 10 +- lib/v-mapbox/controls/geolocate/types.ts | 2 +- .../navigation/VControlNavigation.vue | 2 +- lib/v-mapbox/controls/scale/VControlScale.vue | 8 +- lib/v-mapbox/controls/scale/types.ts | 2 +- .../maplibre/canvas/VLayerMaplibreCanvas.vue | 6 +- .../geojson/VLayerMaplibreGeojson.vue | 9 +- .../maplibre/image/VLayerMaplibreImage.vue | 130 ++++---- .../maplibre/raster/VLayerMaplibreRaster.vue | 140 ++++----- .../maplibre/vector/VLayerMaplibreVector.vue | 131 ++++---- .../maplibre/video/VLayerMaplibreVideo.vue | 131 ++++---- lib/v-mapbox/map/VMap.vue | 23 +- lib/v-mapbox/markers/VMarker.vue | 293 +++++++----------- lib/v-mapbox/popups/VPopup.vue | 214 ++++++------- 21 files changed, 499 insertions(+), 632 deletions(-) diff --git a/lib/v-mapbox/constants/events/layer.ts b/lib/v-mapbox/constants/events/layer.ts index ebc2b2e..d32759c 100644 --- a/lib/v-mapbox/constants/events/layer.ts +++ b/lib/v-mapbox/constants/events/layer.ts @@ -1,4 +1,4 @@ -import { MapLayerEventType } from 'maplibre-gl'; +import type { MapLayerEventType } from 'maplibre-gl'; export const mapLayerEvents: Array = [ 'click', diff --git a/lib/v-mapbox/constants/events/map.ts b/lib/v-mapbox/constants/events/map.ts index f4fe23d..bccdb3a 100644 --- a/lib/v-mapbox/constants/events/map.ts +++ b/lib/v-mapbox/constants/events/map.ts @@ -1,4 +1,4 @@ -import { MapEventType } from 'maplibre-gl'; +import type { MapEventType } from 'maplibre-gl'; export const mapEvents: Array = [ 'error', diff --git a/lib/v-mapbox/constants/events/popup.ts b/lib/v-mapbox/constants/events/popup.ts index bee65e3..ac910c9 100644 --- a/lib/v-mapbox/constants/events/popup.ts +++ b/lib/v-mapbox/constants/events/popup.ts @@ -1 +1 @@ -export const popupEvents = ['open', 'close']; +export const popupEvents = ['open', 'close'] as Array<'open' | 'close'>; diff --git a/lib/v-mapbox/controls/attribution/VControlAttribution.vue b/lib/v-mapbox/controls/attribution/VControlAttribution.vue index 2636071..4281eab 100644 --- a/lib/v-mapbox/controls/attribution/VControlAttribution.vue +++ b/lib/v-mapbox/controls/attribution/VControlAttribution.vue @@ -1,17 +1,17 @@ diff --git a/lib/v-mapbox/controls/attribution/types.ts b/lib/v-mapbox/controls/attribution/types.ts index bdd4dfe..b7566a2 100644 --- a/lib/v-mapbox/controls/attribution/types.ts +++ b/lib/v-mapbox/controls/attribution/types.ts @@ -1 +1 @@ -export type { AttributionOptions, ControlPosition } from 'maplibre-gl'; +export type { AttributionControlOptions, ControlPosition } from 'maplibre-gl'; diff --git a/lib/v-mapbox/controls/fullscreen/VControlFullscreen.vue b/lib/v-mapbox/controls/fullscreen/VControlFullscreen.vue index 0a8bfb2..35c79c5 100644 --- a/lib/v-mapbox/controls/fullscreen/VControlFullscreen.vue +++ b/lib/v-mapbox/controls/fullscreen/VControlFullscreen.vue @@ -1,16 +1,16 @@ - - diff --git a/lib/v-mapbox/controls/scale/types.ts b/lib/v-mapbox/controls/scale/types.ts index fc08d3b..f17c83b 100644 --- a/lib/v-mapbox/controls/scale/types.ts +++ b/lib/v-mapbox/controls/scale/types.ts @@ -1 +1 @@ -export type { ControlPosition, ScaleOptions } from 'maplibre-gl'; +export type { ControlPosition, ScaleControlOptions } from 'maplibre-gl'; diff --git a/lib/v-mapbox/layers/maplibre/canvas/VLayerMaplibreCanvas.vue b/lib/v-mapbox/layers/maplibre/canvas/VLayerMaplibreCanvas.vue index ae2fe40..34bf1f0 100644 --- a/lib/v-mapbox/layers/maplibre/canvas/VLayerMaplibreCanvas.vue +++ b/lib/v-mapbox/layers/maplibre/canvas/VLayerMaplibreCanvas.vue @@ -23,8 +23,8 @@ before: '', }, ); - let map = injectStrict(MapKey); - let loaded: Ref = ref(false); + const map = injectStrict(MapKey); + const loaded: Ref = ref(false); const layer = { ...props.layer, @@ -62,5 +62,5 @@ diff --git a/lib/v-mapbox/layers/maplibre/geojson/VLayerMaplibreGeojson.vue b/lib/v-mapbox/layers/maplibre/geojson/VLayerMaplibreGeojson.vue index 2028fca..33a9440 100644 --- a/lib/v-mapbox/layers/maplibre/geojson/VLayerMaplibreGeojson.vue +++ b/lib/v-mapbox/layers/maplibre/geojson/VLayerMaplibreGeojson.vue @@ -1,8 +1,8 @@ diff --git a/lib/v-mapbox/layers/maplibre/image/VLayerMaplibreImage.vue b/lib/v-mapbox/layers/maplibre/image/VLayerMaplibreImage.vue index ff4a0b6..f54c45f 100644 --- a/lib/v-mapbox/layers/maplibre/image/VLayerMaplibreImage.vue +++ b/lib/v-mapbox/layers/maplibre/image/VLayerMaplibreImage.vue @@ -1,88 +1,76 @@ - diff --git a/lib/v-mapbox/layers/maplibre/raster/VLayerMaplibreRaster.vue b/lib/v-mapbox/layers/maplibre/raster/VLayerMaplibreRaster.vue index a7a8377..c9edb0b 100644 --- a/lib/v-mapbox/layers/maplibre/raster/VLayerMaplibreRaster.vue +++ b/lib/v-mapbox/layers/maplibre/raster/VLayerMaplibreRaster.vue @@ -1,93 +1,83 @@ - diff --git a/lib/v-mapbox/layers/maplibre/vector/VLayerMaplibreVector.vue b/lib/v-mapbox/layers/maplibre/vector/VLayerMaplibreVector.vue index acbef1a..cdd1f0b 100644 --- a/lib/v-mapbox/layers/maplibre/vector/VLayerMaplibreVector.vue +++ b/lib/v-mapbox/layers/maplibre/vector/VLayerMaplibreVector.vue @@ -1,88 +1,77 @@ - diff --git a/lib/v-mapbox/layers/maplibre/video/VLayerMaplibreVideo.vue b/lib/v-mapbox/layers/maplibre/video/VLayerMaplibreVideo.vue index 65d3d03..fa8c31b 100644 --- a/lib/v-mapbox/layers/maplibre/video/VLayerMaplibreVideo.vue +++ b/lib/v-mapbox/layers/maplibre/video/VLayerMaplibreVideo.vue @@ -1,88 +1,77 @@ - diff --git a/lib/v-mapbox/map/VMap.vue b/lib/v-mapbox/map/VMap.vue index 986ca08..e9776fe 100644 --- a/lib/v-mapbox/map/VMap.vue +++ b/lib/v-mapbox/map/VMap.vue @@ -1,13 +1,8 @@ - + +