@unovis/ts 1.1.1-beta.7 → 1.1.1-beta.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/area/config.d.ts +25 -0
- package/components/area/config.js +16 -0
- package/components/area/config.js.map +1 -0
- package/components/area/index.d.ts +19 -0
- package/components/area/index.js +102 -0
- package/components/area/index.js.map +1 -0
- package/components/area/style.d.ts +3 -0
- package/{src/components/area/style.ts → components/area/style.js} +10 -9
- package/components/area/style.js.map +1 -0
- package/components/area/types.d.ts +6 -0
- package/components/axis/config.d.ts +71 -0
- package/components/axis/config.js +32 -0
- package/components/axis/config.js.map +1 -0
- package/components/axis/index.d.ts +44 -0
- package/components/axis/index.js +305 -0
- package/components/axis/index.js.map +1 -0
- package/components/axis/style.d.ts +9 -0
- package/{src/components/axis/style.ts → components/axis/style.js} +22 -27
- package/components/axis/style.js.map +1 -0
- package/components/axis/types.d.ts +4 -0
- package/components/axis/types.js +8 -0
- package/components/axis/types.js.map +1 -0
- package/components/brush/config.d.ts +42 -0
- package/components/brush/config.js +24 -0
- package/components/brush/config.js.map +1 -0
- package/components/brush/index.d.ts +28 -0
- package/components/brush/index.js +199 -0
- package/components/brush/index.js.map +1 -0
- package/components/brush/style.d.ts +5 -0
- package/{src/components/brush/style.ts → components/brush/style.js} +14 -15
- package/components/brush/style.js.map +1 -0
- package/components/brush/types.d.ts +7 -0
- package/components/brush/types.js +8 -0
- package/components/brush/types.js.map +1 -0
- package/components/bullet-legend/config.d.ts +34 -0
- package/components/bullet-legend/config.js +16 -0
- package/components/bullet-legend/config.js.map +1 -0
- package/components/bullet-legend/index.d.ts +19 -0
- package/components/bullet-legend/index.js +79 -0
- package/components/bullet-legend/index.js.map +1 -0
- package/components/bullet-legend/style.d.ts +6 -0
- package/{src/components/bullet-legend/style.ts → components/bullet-legend/style.js} +16 -18
- package/components/bullet-legend/style.js.map +1 -0
- package/components/bullet-legend/types.d.ts +7 -0
- package/components/bullet-legend/types.js +2 -0
- package/components/bullet-legend/types.js.map +1 -0
- package/components/chord-diagram/config.d.ts +44 -0
- package/components/chord-diagram/config.js +25 -0
- package/components/chord-diagram/config.js.map +1 -0
- package/components/chord-diagram/index.d.ts +42 -0
- package/components/chord-diagram/index.js +305 -0
- package/components/chord-diagram/index.js.map +1 -0
- package/components/chord-diagram/modules/label.d.ts +8 -0
- package/components/chord-diagram/modules/label.js +115 -0
- package/components/chord-diagram/modules/label.js.map +1 -0
- package/components/chord-diagram/modules/link.d.ts +21 -0
- package/components/chord-diagram/modules/link.js +63 -0
- package/components/chord-diagram/modules/link.js.map +1 -0
- package/components/chord-diagram/modules/node.d.ts +17 -0
- package/components/chord-diagram/modules/node.js +52 -0
- package/components/chord-diagram/modules/node.js.map +1 -0
- package/components/chord-diagram/style.d.ts +13 -0
- package/{src/components/chord-diagram/style.ts → components/chord-diagram/style.js} +30 -39
- package/components/chord-diagram/style.js.map +1 -0
- package/components/chord-diagram/types.d.ts +58 -0
- package/components/chord-diagram/types.js +8 -0
- package/components/chord-diagram/types.js.map +1 -0
- package/components/crosshair/config.d.ts +43 -0
- package/components/crosshair/config.js +19 -0
- package/components/crosshair/config.js.map +1 -0
- package/components/crosshair/index.d.ts +35 -0
- package/components/crosshair/index.js +183 -0
- package/components/crosshair/index.js.map +1 -0
- package/components/crosshair/style.d.ts +4 -0
- package/{src/components/crosshair/style.ts → components/crosshair/style.js} +12 -12
- package/components/crosshair/style.js.map +1 -0
- package/components/crosshair/types.d.ts +13 -0
- package/components/crosshair/types.js +2 -0
- package/components/crosshair/types.js.map +1 -0
- package/components/donut/config.d.ts +59 -0
- package/components/donut/config.js +28 -0
- package/components/donut/config.js.map +1 -0
- package/components/donut/index.d.ts +21 -0
- package/components/donut/index.js +107 -0
- package/components/donut/index.js.map +1 -0
- package/components/donut/modules/arc.d.ts +10 -0
- package/components/donut/modules/arc.js +59 -0
- package/components/donut/modules/arc.js.map +1 -0
- package/components/donut/style.d.ts +7 -0
- package/{src/components/donut/style.ts → components/donut/style.js} +18 -20
- package/components/donut/style.js.map +1 -0
- package/components/donut/types.d.ts +20 -0
- package/components/flow-legend/config.d.ts +29 -0
- package/components/flow-legend/config.js +18 -0
- package/components/flow-legend/config.js.map +1 -0
- package/components/flow-legend/index.d.ts +16 -0
- package/components/flow-legend/index.js +75 -0
- package/components/flow-legend/index.js.map +1 -0
- package/components/flow-legend/style.d.ts +8 -0
- package/{src/components/flow-legend/style.ts → components/flow-legend/style.js} +21 -25
- package/components/flow-legend/style.js.map +1 -0
- package/components/flow-legend/types.d.ts +9 -0
- package/components/flow-legend/types.js +8 -0
- package/components/flow-legend/types.js.map +1 -0
- package/components/free-brush/config.d.ts +45 -0
- package/components/free-brush/config.js +24 -0
- package/components/free-brush/config.js.map +1 -0
- package/components/free-brush/index.d.ts +20 -0
- package/components/free-brush/index.js +192 -0
- package/components/free-brush/index.js.map +1 -0
- package/components/free-brush/style.d.ts +4 -0
- package/{src/components/free-brush/style.ts → components/free-brush/style.js} +12 -12
- package/components/free-brush/style.js.map +1 -0
- package/components/free-brush/types.d.ts +7 -0
- package/components/free-brush/types.js +9 -0
- package/components/free-brush/types.js.map +1 -0
- package/components/graph/config.d.ts +238 -0
- package/components/graph/config.js +84 -0
- package/components/graph/config.js.map +1 -0
- package/components/graph/index.d.ts +126 -0
- package/components/graph/index.js +656 -0
- package/components/graph/index.js.map +1 -0
- package/components/graph/modules/layout-helpers.d.ts +21 -0
- package/components/graph/modules/layout-helpers.js +69 -0
- package/components/graph/modules/layout-helpers.js.map +1 -0
- package/components/graph/modules/layout.d.ts +10 -0
- package/components/graph/modules/layout.js +399 -0
- package/components/graph/modules/layout.js.map +1 -0
- package/components/graph/modules/link/helper.d.ts +25 -0
- package/components/graph/modules/link/helper.js +74 -0
- package/components/graph/modules/link/helper.js.map +1 -0
- package/components/graph/modules/link/index.d.ts +11 -0
- package/components/graph/modules/link/index.js +212 -0
- package/components/graph/modules/link/index.js.map +1 -0
- package/components/graph/modules/link/style.d.ts +15 -0
- package/{src/components/graph/modules/link/style.ts → components/graph/modules/link/style.js} +34 -45
- package/components/graph/modules/link/style.js.map +1 -0
- package/components/graph/modules/node/helper.d.ts +21 -0
- package/components/graph/modules/node/helper.js +126 -0
- package/components/graph/modules/node/helper.js.map +1 -0
- package/components/graph/modules/node/index.d.ts +11 -0
- package/components/graph/modules/node/index.js +252 -0
- package/components/graph/modules/node/index.js.map +1 -0
- package/components/graph/modules/node/style.d.ts +24 -0
- package/{src/components/graph/modules/node/style.ts → components/graph/modules/node/style.js} +52 -72
- package/components/graph/modules/node/style.js.map +1 -0
- package/components/graph/modules/panel/helper.d.ts +18 -0
- package/components/graph/modules/panel/helper.js +111 -0
- package/components/graph/modules/panel/helper.js.map +1 -0
- package/components/graph/modules/panel/index.d.ts +7 -0
- package/components/graph/modules/panel/index.js +98 -0
- package/components/graph/modules/panel/index.js.map +1 -0
- package/components/graph/modules/panel/style.d.ts +14 -0
- package/{src/components/graph/modules/panel/style.ts → components/graph/modules/panel/style.js} +32 -42
- package/components/graph/modules/panel/style.js.map +1 -0
- package/components/graph/modules/shape.d.ts +6 -0
- package/components/graph/modules/shape.js +80 -0
- package/components/graph/modules/shape.js.map +1 -0
- package/components/graph/modules/zoom-levels.d.ts +6 -0
- package/components/graph/modules/zoom-levels.js +10 -0
- package/components/graph/modules/zoom-levels.js.map +1 -0
- package/components/graph/style.d.ts +6 -0
- package/components/graph/style.js +66 -0
- package/components/graph/style.js.map +1 -0
- package/components/graph/types.d.ts +125 -0
- package/components/graph/types.js +30 -0
- package/components/graph/types.js.map +1 -0
- package/components/grouped-bar/config.d.ts +36 -0
- package/components/grouped-bar/config.js +20 -0
- package/components/grouped-bar/config.js.map +1 -0
- package/components/grouped-bar/index.d.ts +32 -0
- package/components/grouped-bar/index.js +249 -0
- package/components/grouped-bar/index.js.map +1 -0
- package/components/grouped-bar/style.d.ts +5 -0
- package/{src/components/grouped-bar/style.ts → components/grouped-bar/style.js} +14 -15
- package/components/grouped-bar/style.js.map +1 -0
- package/components/leaflet-flow-map/config.d.ts +46 -0
- package/components/leaflet-flow-map/config.js +25 -0
- package/components/leaflet-flow-map/config.js.map +1 -0
- package/components/leaflet-flow-map/index.d.ts +52 -0
- package/components/leaflet-flow-map/index.js +220 -0
- package/components/leaflet-flow-map/index.js.map +1 -0
- package/components/leaflet-flow-map/renderer-utils.d.ts +5 -0
- package/components/leaflet-flow-map/renderer-utils.js +15 -0
- package/components/leaflet-flow-map/renderer-utils.js.map +1 -0
- package/components/leaflet-flow-map/renderer.d.ts +26 -0
- package/components/leaflet-flow-map/renderer.js +117 -0
- package/components/leaflet-flow-map/renderer.js.map +1 -0
- package/components/leaflet-flow-map/shaders.d.ts +2 -0
- package/{src/components/leaflet-flow-map/shaders.ts → components/leaflet-flow-map/shaders.js} +7 -4
- package/components/leaflet-flow-map/shaders.js.map +1 -0
- package/components/leaflet-flow-map/types.d.ts +23 -0
- package/components/leaflet-map/config.d.ts +193 -0
- package/components/leaflet-map/config.js +71 -0
- package/components/leaflet-map/config.js.map +1 -0
- package/components/leaflet-map/index.d.ts +130 -0
- package/components/leaflet-map/index.js +690 -0
- package/components/leaflet-map/index.js.map +1 -0
- package/components/leaflet-map/leaflet.css.js +5 -0
- package/components/leaflet-map/leaflet.css.js.map +1 -0
- package/components/leaflet-map/modules/clusterBackground.d.ts +5 -0
- package/components/leaflet-map/modules/clusterBackground.js +27 -0
- package/components/leaflet-map/modules/clusterBackground.js.map +1 -0
- package/components/leaflet-map/modules/donut.d.ts +3 -0
- package/components/leaflet-map/modules/donut.js +25 -0
- package/components/leaflet-map/modules/donut.js.map +1 -0
- package/components/leaflet-map/modules/map.d.ts +14 -0
- package/components/leaflet-map/modules/map.js +154 -0
- package/components/leaflet-map/modules/map.js.map +1 -0
- package/components/leaflet-map/modules/node.d.ts +9 -0
- package/components/leaflet-map/modules/node.js +162 -0
- package/components/leaflet-map/modules/node.js.map +1 -0
- package/components/leaflet-map/modules/selectionRing.d.ts +7 -0
- package/components/leaflet-map/modules/selectionRing.js +41 -0
- package/components/leaflet-map/modules/selectionRing.js.map +1 -0
- package/components/leaflet-map/modules/utils.d.ts +50 -0
- package/components/leaflet-map/modules/utils.js +210 -0
- package/components/leaflet-map/modules/utils.js.map +1 -0
- package/{src/components → components}/leaflet-map/renderer/leaflet-maplibre-gl.js +78 -76
- package/components/leaflet-map/renderer/leaflet-maplibre-gl.js.map +1 -0
- package/components/leaflet-map/renderer/map-style.d.ts +4 -0
- package/components/leaflet-map/renderer/map-style.js +15 -0
- package/components/leaflet-map/renderer/map-style.js.map +1 -0
- package/components/leaflet-map/renderer/mapboxgl/mapboxgl-dark-theme.json.js +40 -0
- package/components/leaflet-map/renderer/mapboxgl/mapboxgl-dark-theme.json.js.map +1 -0
- package/components/leaflet-map/renderer/mapboxgl/mapboxgl-light-theme.json.js +40 -0
- package/components/leaflet-map/renderer/mapboxgl/mapboxgl-light-theme.json.js.map +1 -0
- package/components/leaflet-map/renderer/mapboxgl/mapboxgl-settings.json.js +4981 -0
- package/components/leaflet-map/renderer/mapboxgl/mapboxgl-settings.json.js.map +1 -0
- package/components/leaflet-map/renderer/mapboxgl-layer.d.ts +8 -0
- package/components/leaflet-map/renderer/mapboxgl-layer.js +27 -0
- package/components/leaflet-map/renderer/mapboxgl-layer.js.map +1 -0
- package/components/leaflet-map/renderer/mapboxgl-utils.d.ts +4 -0
- package/components/leaflet-map/renderer/mapboxgl-utils.js +39 -0
- package/components/leaflet-map/renderer/mapboxgl-utils.js.map +1 -0
- package/{src/components → components}/leaflet-map/renderer/maplibre-gl.css.js +4 -2
- package/components/leaflet-map/renderer/maplibre-gl.css.js.map +1 -0
- package/components/leaflet-map/style.d.ts +52 -0
- package/components/leaflet-map/style.js +183 -0
- package/components/leaflet-map/style.js.map +1 -0
- package/components/leaflet-map/types.d.ts +75 -0
- package/components/leaflet-map/types.js +15 -0
- package/components/leaflet-map/types.js.map +1 -0
- package/components/line/config.d.ts +30 -0
- package/components/line/config.js +17 -0
- package/components/line/config.js.map +1 -0
- package/components/line/index.d.ts +27 -0
- package/components/line/index.js +152 -0
- package/components/line/index.js.map +1 -0
- package/components/line/style.d.ts +6 -0
- package/{src/components/line/style.ts → components/line/style.js} +16 -18
- package/components/line/style.js.map +1 -0
- package/components/line/types.d.ts +12 -0
- package/components/nested-donut/config.d.ts +59 -0
- package/components/nested-donut/config.js +19 -0
- package/components/nested-donut/config.js.map +1 -0
- package/components/nested-donut/index.d.ts +38 -0
- package/components/nested-donut/index.js +133 -0
- package/components/nested-donut/index.js.map +1 -0
- package/components/nested-donut/modules/arc.d.ts +17 -0
- package/components/nested-donut/modules/arc.js +50 -0
- package/components/nested-donut/modules/arc.js.map +1 -0
- package/components/nested-donut/modules/label.d.ts +7 -0
- package/components/nested-donut/modules/label.js +34 -0
- package/components/nested-donut/modules/label.js.map +1 -0
- package/components/nested-donut/style.d.ts +26 -0
- package/components/nested-donut/style.js +70 -0
- package/components/nested-donut/style.js.map +1 -0
- package/components/nested-donut/types.d.ts +24 -0
- package/components/nested-donut/types.js +11 -0
- package/components/nested-donut/types.js.map +1 -0
- package/components/sankey/config.d.ts +162 -0
- package/components/sankey/config.js +65 -0
- package/components/sankey/config.js.map +1 -0
- package/components/sankey/index.d.ts +59 -0
- package/components/sankey/index.js +306 -0
- package/components/sankey/index.js.map +1 -0
- package/components/sankey/modules/label.d.ts +23 -0
- package/components/sankey/modules/label.js +168 -0
- package/components/sankey/modules/label.js.map +1 -0
- package/components/sankey/modules/link.d.ts +14 -0
- package/components/sankey/modules/link.js +108 -0
- package/components/sankey/modules/link.js.map +1 -0
- package/components/sankey/modules/node.d.ts +10 -0
- package/components/sankey/modules/node.js +156 -0
- package/components/sankey/modules/node.js.map +1 -0
- package/components/sankey/style.d.ts +20 -0
- package/{src/components/sankey/style.ts → components/sankey/style.js} +44 -60
- package/components/sankey/style.js.map +1 -0
- package/components/sankey/types.d.ts +84 -0
- package/components/sankey/types.js +34 -0
- package/components/sankey/types.js.map +1 -0
- package/components/scatter/config.d.ts +44 -0
- package/components/scatter/config.js +23 -0
- package/components/scatter/config.js.map +1 -0
- package/components/scatter/index.d.ts +28 -0
- package/components/scatter/index.js +167 -0
- package/components/scatter/index.js.map +1 -0
- package/components/scatter/modules/point.d.ts +7 -0
- package/components/scatter/modules/point.js +86 -0
- package/components/scatter/modules/point.js.map +1 -0
- package/components/scatter/modules/utils.d.ts +11 -0
- package/components/scatter/modules/utils.js +112 -0
- package/components/scatter/modules/utils.js.map +1 -0
- package/components/scatter/style.d.ts +5 -0
- package/{src/components/scatter/style.ts → components/scatter/style.js} +14 -15
- package/components/scatter/style.js.map +1 -0
- package/components/scatter/types.d.ts +19 -0
- package/components/stacked-bar/config.d.ts +38 -0
- package/components/stacked-bar/config.js +20 -0
- package/components/stacked-bar/config.js.map +1 -0
- package/components/stacked-bar/index.d.ts +28 -0
- package/components/stacked-bar/index.js +208 -0
- package/components/stacked-bar/index.js.map +1 -0
- package/components/stacked-bar/style.d.ts +5 -0
- package/{src/components/stacked-bar/style.ts → components/stacked-bar/style.js} +14 -15
- package/components/stacked-bar/style.js.map +1 -0
- package/components/stacked-bar/types.d.ts +5 -0
- package/components/timeline/config.d.ts +43 -0
- package/components/timeline/config.js +24 -0
- package/components/timeline/config.js.map +1 -0
- package/components/timeline/index.d.ts +41 -0
- package/components/timeline/index.js +244 -0
- package/components/timeline/index.js.map +1 -0
- package/components/timeline/style.d.ts +13 -0
- package/{src/components/timeline/style.ts → components/timeline/style.js} +30 -39
- package/components/timeline/style.js.map +1 -0
- package/components/tooltip/config.d.ts +68 -0
- package/components/tooltip/config.js +20 -0
- package/components/tooltip/config.js.map +1 -0
- package/components/tooltip/index.d.ts +36 -0
- package/components/tooltip/index.js +184 -0
- package/components/tooltip/index.js.map +1 -0
- package/{src/components → components}/tooltip/style.js +14 -11
- package/components/tooltip/style.js.map +1 -0
- package/components/topojson-map/config.d.ts +99 -0
- package/components/topojson-map/config.js +42 -0
- package/components/topojson-map/config.js.map +1 -0
- package/components/topojson-map/index.d.ts +52 -0
- package/components/topojson-map/index.js +355 -0
- package/components/topojson-map/index.js.map +1 -0
- package/components/topojson-map/style.d.ts +11 -0
- package/{src/components/topojson-map/style.ts → components/topojson-map/style.js} +26 -33
- package/components/topojson-map/style.js.map +1 -0
- package/components/topojson-map/types.d.ts +78 -0
- package/components/topojson-map/types.js +80 -0
- package/components/topojson-map/types.js.map +1 -0
- package/components/topojson-map/utils.d.ts +3 -0
- package/components/topojson-map/utils.js +30 -0
- package/components/topojson-map/utils.js.map +1 -0
- package/components/vis-controls/config.d.ts +12 -0
- package/components/vis-controls/config.js +13 -0
- package/components/vis-controls/config.js.map +1 -0
- package/components/vis-controls/index.d.ts +14 -0
- package/components/vis-controls/index.js +52 -0
- package/components/vis-controls/index.js.map +1 -0
- package/components/vis-controls/style.d.ts +11 -0
- package/{src/components/vis-controls/style.ts → components/vis-controls/style.js} +27 -34
- package/components/vis-controls/style.js.map +1 -0
- package/components/vis-controls/types.d.ts +13 -0
- package/components/vis-controls/types.js +8 -0
- package/components/vis-controls/types.js.map +1 -0
- package/components/xy-labels/config.d.ts +48 -0
- package/components/xy-labels/config.js +25 -0
- package/components/xy-labels/config.js.map +1 -0
- package/components/xy-labels/index.d.ts +15 -0
- package/components/xy-labels/index.js +87 -0
- package/components/xy-labels/index.js.map +1 -0
- package/components/xy-labels/modules/label.d.ts +9 -0
- package/components/xy-labels/modules/label.js +107 -0
- package/components/xy-labels/modules/label.js.map +1 -0
- package/components/xy-labels/style.d.ts +5 -0
- package/{src/components/xy-labels/style.ts → components/xy-labels/style.js} +14 -15
- package/components/xy-labels/style.js.map +1 -0
- package/components/xy-labels/types.d.ts +23 -0
- package/components/xy-labels/types.js +9 -0
- package/components/xy-labels/types.js.map +1 -0
- package/components.d.ts +51 -0
- package/components.js +29 -0
- package/components.js.map +1 -0
- package/containers/single-container/config.d.ts +12 -0
- package/containers/single-container/config.js +12 -0
- package/containers/single-container/config.js.map +1 -0
- package/containers/single-container/index.d.ts +19 -0
- package/containers/single-container/index.js +128 -0
- package/containers/single-container/index.js.map +1 -0
- package/containers/xy-container/config.d.ts +99 -0
- package/containers/xy-container/config.js +30 -0
- package/containers/xy-container/config.js.map +1 -0
- package/containers/xy-container/index.d.ts +34 -0
- package/containers/xy-container/index.js +330 -0
- package/containers/xy-container/index.js.map +1 -0
- package/containers.d.ts +6 -0
- package/containers.js +4 -0
- package/containers.js.map +1 -0
- package/core/component/config.d.ts +58 -0
- package/core/component/config.js +14 -0
- package/core/component/config.js.map +1 -0
- package/core/component/index.d.ts +43 -0
- package/core/component/index.js +118 -0
- package/core/component/index.js.map +1 -0
- package/core/component/types.d.ts +2 -0
- package/core/component/types.js +2 -0
- package/core/component/types.js.map +1 -0
- package/core/config/index.d.ts +3 -0
- package/core/config/index.js +16 -0
- package/core/config/index.js.map +1 -0
- package/core/container/config.d.ts +48 -0
- package/core/container/config.js +29 -0
- package/core/container/config.js.map +1 -0
- package/core/container/index.d.ts +26 -0
- package/core/container/index.js +106 -0
- package/core/container/index.js.map +1 -0
- package/core/xy-component/config.d.ts +38 -0
- package/core/xy-component/config.js +20 -0
- package/core/xy-component/config.js.map +1 -0
- package/core/xy-component/index.d.ts +27 -0
- package/core/xy-component/index.js +74 -0
- package/core/xy-component/index.js.map +1 -0
- package/data-models/core.d.ts +6 -0
- package/data-models/core.js +14 -0
- package/data-models/core.js.map +1 -0
- package/data-models/graph.d.ts +24 -0
- package/data-models/graph.js +107 -0
- package/data-models/graph.js.map +1 -0
- package/data-models/map-graph.d.ts +21 -0
- package/data-models/map-graph.js +62 -0
- package/data-models/map-graph.js.map +1 -0
- package/data-models/map.d.ts +5 -0
- package/data-models/map.js +12 -0
- package/data-models/map.js.map +1 -0
- package/data-models/series.d.ts +6 -0
- package/data-models/series.js +19 -0
- package/data-models/series.js.map +1 -0
- package/index.d.ts +7 -0
- package/index.js +55 -0
- package/index.js.map +1 -0
- package/maps/china-provinces.json.js +140373 -0
- package/maps/fr-regions.json.js +14162 -0
- package/maps/germany-regions.json.js +35760 -0
- package/maps/ind-regions.json.js +290584 -0
- package/maps/uk-regions.json.js +96233 -0
- package/maps/us-counties.json.js +206318 -0
- package/maps/us-states.json.js +16345 -0
- package/maps/world-110m-alpha.json.js +251366 -0
- package/maps/world-simple.json.js +89428 -0
- package/maps/world-simplest.json.js +28175 -0
- package/maps.d.ts +60 -0
- package/maps.js +23 -0
- package/package.json +1 -1
- package/styles/colors.d.ts +7 -0
- package/styles/colors.js +24 -0
- package/styles/colors.js.map +1 -0
- package/styles/index.d.ts +7 -0
- package/styles/index.js +38 -0
- package/styles/index.js.map +1 -0
- package/styles/sizes.d.ts +2 -0
- package/{src/styles/sizes.ts → styles/sizes.js} +8 -6
- package/styles/sizes.js.map +1 -0
- package/types/accessor.d.ts +5 -0
- package/types/accessor.js +2 -0
- package/types/accessor.js.map +1 -0
- package/types/component.d.ts +13 -0
- package/types/component.js +14 -0
- package/types/component.js.map +1 -0
- package/types/curve.d.ts +40 -0
- package/types/curve.js +46 -0
- package/types/curve.js.map +1 -0
- package/types/data.d.ts +7 -0
- package/types/data.js +2 -0
- package/types/data.js.map +1 -0
- package/types/direction.d.ts +6 -0
- package/types/direction.js +10 -0
- package/types/direction.js.map +1 -0
- package/types/graph.d.ts +35 -0
- package/types/graph.js +2 -0
- package/types/graph.js.map +1 -0
- package/types/map.d.ts +4 -0
- package/types/map.js +2 -0
- package/types/map.js.map +1 -0
- package/types/misc.d.ts +8 -0
- package/types/position.d.ts +20 -0
- package/types/position.js +27 -0
- package/types/position.js.map +1 -0
- package/types/scale.d.ts +23 -0
- package/types/scale.js +27 -0
- package/types/scale.js.map +1 -0
- package/types/shape.d.ts +7 -0
- package/types/shape.js +11 -0
- package/types/shape.js.map +1 -0
- package/types/spacing.d.ts +6 -0
- package/types/spacing.js +2 -0
- package/types/spacing.js.map +1 -0
- package/types/svg.d.ts +18 -0
- package/types/svg.js +22 -0
- package/types/svg.js.map +1 -0
- package/types/symbol.d.ts +18 -0
- package/types/symbol.js +24 -0
- package/types/symbol.js.map +1 -0
- package/types/text.d.ts +47 -0
- package/types/text.js +26 -0
- package/types/text.js.map +1 -0
- package/types.d.ts +27 -0
- package/types.js +30 -0
- package/types.js.map +1 -0
- package/utils/color.d.ts +10 -0
- package/utils/color.js +32 -0
- package/utils/color.js.map +1 -0
- package/utils/d3.d.ts +3 -0
- package/utils/d3.js +16 -0
- package/utils/d3.js.map +1 -0
- package/utils/data.d.ts +45 -0
- package/utils/data.js +274 -0
- package/utils/data.js.map +1 -0
- package/utils/html.d.ts +1 -0
- package/utils/html.js +16 -0
- package/utils/html.js.map +1 -0
- package/utils/map.d.ts +2 -0
- package/utils/map.js +20 -0
- package/utils/map.js.map +1 -0
- package/utils/misc.d.ts +9 -0
- package/utils/misc.js +47 -0
- package/utils/misc.js.map +1 -0
- package/utils/path.d.ts +23 -0
- package/utils/path.js +144 -0
- package/utils/path.js.map +1 -0
- package/utils/scale.d.ts +1 -0
- package/utils/style.d.ts +6 -0
- package/utils/style.js +24 -0
- package/utils/style.js.map +1 -0
- package/utils/svg.d.ts +3 -0
- package/utils/text.d.ts +139 -0
- package/utils/text.js +443 -0
- package/utils/text.js.map +1 -0
- package/utils/type.d.ts +5 -0
- package/declaration.d.ts +0 -1
- package/index.ts +0 -1
- package/licences.txt +0 -43
- package/maps.ts +0 -1
- package/rollup.config.js +0 -71
- package/rules/ts-getter-setter.js +0 -35
- package/src/components/area/config.ts +0 -29
- package/src/components/area/index.ts +0 -133
- package/src/components/area/types.ts +0 -2
- package/src/components/axis/config.ts +0 -76
- package/src/components/axis/index.ts +0 -363
- package/src/components/axis/types.ts +0 -4
- package/src/components/brush/config.ts +0 -51
- package/src/components/brush/index.ts +0 -233
- package/src/components/brush/types.ts +0 -8
- package/src/components/bullet-legend/config.ts +0 -38
- package/src/components/bullet-legend/index.ts +0 -104
- package/src/components/bullet-legend/types.ts +0 -7
- package/src/components/chord-diagram/config.ts +0 -53
- package/src/components/chord-diagram/index.ts +0 -401
- package/src/components/chord-diagram/modules/label.ts +0 -155
- package/src/components/chord-diagram/modules/link.ts +0 -91
- package/src/components/chord-diagram/modules/node.ts +0 -80
- package/src/components/chord-diagram/types.ts +0 -68
- package/src/components/crosshair/config.ts +0 -48
- package/src/components/crosshair/index.ts +0 -220
- package/src/components/crosshair/types.ts +0 -15
- package/src/components/donut/config.ts +0 -65
- package/src/components/donut/index.ts +0 -148
- package/src/components/donut/modules/arc.ts +0 -86
- package/src/components/donut/types.ts +0 -17
- package/src/components/flow-legend/config.ts +0 -31
- package/src/components/flow-legend/index.ts +0 -103
- package/src/components/flow-legend/types.ts +0 -10
- package/src/components/free-brush/config.ts +0 -54
- package/src/components/free-brush/index.ts +0 -207
- package/src/components/free-brush/types.ts +0 -8
- package/src/components/graph/config.ts +0 -280
- package/src/components/graph/index.ts +0 -809
- package/src/components/graph/modules/layout-helpers.ts +0 -96
- package/src/components/graph/modules/layout.ts +0 -502
- package/src/components/graph/modules/link/helper.ts +0 -105
- package/src/components/graph/modules/link/index.ts +0 -302
- package/src/components/graph/modules/node/helper.ts +0 -162
- package/src/components/graph/modules/node/index.ts +0 -343
- package/src/components/graph/modules/panel/helper.ts +0 -160
- package/src/components/graph/modules/panel/index.ts +0 -137
- package/src/components/graph/modules/shape.ts +0 -108
- package/src/components/graph/modules/zoom-levels.ts +0 -6
- package/src/components/graph/style.ts +0 -72
- package/src/components/graph/types.ts +0 -152
- package/src/components/grouped-bar/config.ts +0 -40
- package/src/components/grouped-bar/index.ts +0 -325
- package/src/components/leaflet-flow-map/config.ts +0 -60
- package/src/components/leaflet-flow-map/index.ts +0 -279
- package/src/components/leaflet-flow-map/renderer-utils.ts +0 -14
- package/src/components/leaflet-flow-map/renderer.ts +0 -146
- package/src/components/leaflet-flow-map/types.ts +0 -18
- package/src/components/leaflet-map/config.ts +0 -234
- package/src/components/leaflet-map/index.ts +0 -808
- package/src/components/leaflet-map/leaflet.css +0 -625
- package/src/components/leaflet-map/modules/clusterBackground.ts +0 -34
- package/src/components/leaflet-map/modules/donut.ts +0 -37
- package/src/components/leaflet-map/modules/map.ts +0 -178
- package/src/components/leaflet-map/modules/node.ts +0 -208
- package/src/components/leaflet-map/modules/selectionRing.ts +0 -63
- package/src/components/leaflet-map/modules/utils.ts +0 -290
- package/src/components/leaflet-map/renderer/map-style.ts +0 -24
- package/src/components/leaflet-map/renderer/mapboxgl/mapboxgl-dark-theme.json +0 -35
- package/src/components/leaflet-map/renderer/mapboxgl/mapboxgl-light-theme.json +0 -35
- package/src/components/leaflet-map/renderer/mapboxgl/mapboxgl-settings.json +0 -2185
- package/src/components/leaflet-map/renderer/mapboxgl-layer.ts +0 -43
- package/src/components/leaflet-map/renderer/mapboxgl-utils.ts +0 -40
- package/src/components/leaflet-map/style.ts +0 -217
- package/src/components/leaflet-map/types.ts +0 -75
- package/src/components/line/config.ts +0 -34
- package/src/components/line/index.ts +0 -188
- package/src/components/line/types.ts +0 -3
- package/src/components/nested-donut/config.ts +0 -75
- package/src/components/nested-donut/index.ts +0 -176
- package/src/components/nested-donut/modules/arc.ts +0 -78
- package/src/components/nested-donut/modules/label.ts +0 -63
- package/src/components/nested-donut/style.ts +0 -82
- package/src/components/nested-donut/types.ts +0 -29
- package/src/components/sankey/config.ts +0 -195
- package/src/components/sankey/index.ts +0 -387
- package/src/components/sankey/modules/label.ts +0 -228
- package/src/components/sankey/modules/link.ts +0 -141
- package/src/components/sankey/modules/node.ts +0 -221
- package/src/components/sankey/types.ts +0 -95
- package/src/components/scatter/config.ts +0 -49
- package/src/components/scatter/index.ts +0 -220
- package/src/components/scatter/modules/point.ts +0 -123
- package/src/components/scatter/modules/utils.ts +0 -150
- package/src/components/scatter/types.ts +0 -21
- package/src/components/stacked-bar/config.ts +0 -42
- package/src/components/stacked-bar/index.ts +0 -267
- package/src/components/stacked-bar/types.ts +0 -5
- package/src/components/timeline/config.ts +0 -49
- package/src/components/timeline/index.ts +0 -302
- package/src/components/tooltip/config.ts +0 -69
- package/src/components/tooltip/index.ts +0 -220
- package/src/components/topojson-map/config.ts +0 -124
- package/src/components/topojson-map/index.ts +0 -436
- package/src/components/topojson-map/types.ts +0 -123
- package/src/components/topojson-map/utils.ts +0 -29
- package/src/components/vis-controls/config.ts +0 -16
- package/src/components/vis-controls/index.ts +0 -68
- package/src/components/vis-controls/types.ts +0 -14
- package/src/components/xy-labels/config.ts +0 -56
- package/src/components/xy-labels/index.ts +0 -109
- package/src/components/xy-labels/modules/label.ts +0 -140
- package/src/components/xy-labels/types.ts +0 -26
- package/src/components.ts +0 -56
- package/src/containers/single-container/config.ts +0 -15
- package/src/containers/single-container/index.ts +0 -150
- package/src/containers/xy-container/config.ts +0 -112
- package/src/containers/xy-container/index.ts +0 -407
- package/src/containers.ts +0 -6
- package/src/core/component/config.ts +0 -61
- package/src/core/component/index.ts +0 -154
- package/src/core/component/types.ts +0 -9
- package/src/core/config/index.ts +0 -12
- package/src/core/container/config.ts +0 -56
- package/src/core/container/index.ts +0 -136
- package/src/core/xy-component/config.ts +0 -46
- package/src/core/xy-component/index.ts +0 -90
- package/src/data-models/core.ts +0 -15
- package/src/data-models/graph.ts +0 -138
- package/src/data-models/map-graph.ts +0 -72
- package/src/data-models/map.ts +0 -18
- package/src/data-models/series.ts +0 -16
- package/src/index.ts +0 -7
- package/src/maps/china-provinces.json +0 -1
- package/src/maps/fr-regions.json +0 -1
- package/src/maps/germany-regions.json +0 -1
- package/src/maps/ind-regions.json +0 -1
- package/src/maps/uk-regions.json +0 -1
- package/src/maps/us-counties.json +0 -1
- package/src/maps/us-states.json +0 -1
- package/src/maps/world-110m-alpha.json +0 -1
- package/src/maps/world-simple.json +0 -1
- package/src/maps/world-simplest.json +0 -1
- package/src/maps.ts +0 -34
- package/src/styles/colors.ts +0 -28
- package/src/styles/index.ts +0 -38
- package/src/types/accessor.ts +0 -5
- package/src/types/component.ts +0 -15
- package/src/types/curve.ts +0 -62
- package/src/types/data.ts +0 -5
- package/src/types/direction.ts +0 -6
- package/src/types/graph.ts +0 -40
- package/src/types/map.ts +0 -5
- package/src/types/misc.ts +0 -10
- package/src/types/position.ts +0 -23
- package/src/types/scale.ts +0 -47
- package/src/types/shape.ts +0 -7
- package/src/types/spacing.ts +0 -6
- package/src/types/svg.ts +0 -32
- package/src/types/symbol.ts +0 -21
- package/src/types/text.ts +0 -71
- package/src/types.ts +0 -31
- package/src/utils/color.ts +0 -41
- package/src/utils/d3.ts +0 -15
- package/src/utils/data.ts +0 -328
- package/src/utils/html.ts +0 -13
- package/src/utils/map.ts +0 -29
- package/src/utils/misc.ts +0 -54
- package/src/utils/path.ts +0 -196
- package/src/utils/scale.ts +0 -1
- package/src/utils/style.ts +0 -37
- package/src/utils/svg.ts +0 -49
- package/src/utils/text.ts +0 -529
- package/src/utils/type.ts +0 -9
- package/tsconfig.json +0 -29
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
// eslint-disable-next-line @typescript-eslint/explicit-function-return-type
|
|
2
|
-
|
|
2
|
+
function MaplibreGLLayer (leaflet, maplibre, options) {
|
|
3
3
|
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
4
4
|
const Layer = leaflet.Layer.extend({
|
|
5
5
|
options: {
|
|
@@ -15,39 +15,39 @@ export function MaplibreGLLayer (leaflet, maplibre, options) {
|
|
|
15
15
|
},
|
|
16
16
|
|
|
17
17
|
initialize: function (options) {
|
|
18
|
-
leaflet.setOptions(this, options)
|
|
18
|
+
leaflet.setOptions(this, options);
|
|
19
19
|
|
|
20
20
|
// setup throttling the update event when panning
|
|
21
|
-
this._throttledUpdate = leaflet.Util.throttle(this._update, this.options.updateInterval, this)
|
|
21
|
+
this._throttledUpdate = leaflet.Util.throttle(this._update, this.options.updateInterval, this);
|
|
22
22
|
},
|
|
23
23
|
|
|
24
24
|
onAdd: function (map) {
|
|
25
25
|
if (!this._container) {
|
|
26
|
-
this._initContainer()
|
|
26
|
+
this._initContainer();
|
|
27
27
|
}
|
|
28
28
|
|
|
29
|
-
const paneName = this.getPaneName()
|
|
30
|
-
map.getPane(paneName).appendChild(this._container)
|
|
29
|
+
const paneName = this.getPaneName();
|
|
30
|
+
map.getPane(paneName).appendChild(this._container);
|
|
31
31
|
|
|
32
|
-
this._initGL()
|
|
32
|
+
this._initGL();
|
|
33
33
|
|
|
34
|
-
this._offset = this._map.containerPointToLayerPoint([0, 0])
|
|
34
|
+
this._offset = this._map.containerPointToLayerPoint([0, 0]);
|
|
35
35
|
|
|
36
36
|
// work around https://github.com/mapbox/mapbox-gl-leaflet/issues/47
|
|
37
37
|
if (map.options.zoomAnimation) {
|
|
38
|
-
leaflet.DomEvent.on(map._proxy, leaflet.DomUtil.TRANSITION_END, this._transitionEnd, this)
|
|
38
|
+
leaflet.DomEvent.on(map._proxy, leaflet.DomUtil.TRANSITION_END, this._transitionEnd, this);
|
|
39
39
|
}
|
|
40
40
|
},
|
|
41
41
|
|
|
42
42
|
onRemove: function (map) {
|
|
43
43
|
if (this._map._proxy && this._map.options.zoomAnimation) {
|
|
44
|
-
leaflet.DomEvent.off(this._map._proxy, leaflet.DomUtil.TRANSITION_END, this._transitionEnd, this)
|
|
44
|
+
leaflet.DomEvent.off(this._map._proxy, leaflet.DomUtil.TRANSITION_END, this._transitionEnd, this);
|
|
45
45
|
}
|
|
46
|
-
const paneName = this.getPaneName()
|
|
47
|
-
map.getPane(paneName).removeChild(this._container)
|
|
46
|
+
const paneName = this.getPaneName();
|
|
47
|
+
map.getPane(paneName).removeChild(this._container);
|
|
48
48
|
|
|
49
|
-
this._glMap.remove()
|
|
50
|
-
this._glMap = null
|
|
49
|
+
this._glMap.remove();
|
|
50
|
+
this._glMap = null;
|
|
51
51
|
},
|
|
52
52
|
|
|
53
53
|
getEvents: function () {
|
|
@@ -74,8 +74,8 @@ export function MaplibreGLLayer (leaflet, maplibre, options) {
|
|
|
74
74
|
},
|
|
75
75
|
|
|
76
76
|
getBounds: function () {
|
|
77
|
-
const halfSize = this.getSize().multiplyBy(0.5)
|
|
78
|
-
const center = this._map.latLngToContainerPoint(this._map.getCenter())
|
|
77
|
+
const halfSize = this.getSize().multiplyBy(0.5);
|
|
78
|
+
const center = this._map.latLngToContainerPoint(this._map.getCenter());
|
|
79
79
|
return leaflet.latLngBounds(
|
|
80
80
|
this._map.containerPointToLatLng(center.subtract(halfSize)),
|
|
81
81
|
this._map.containerPointToLatLng(center.add(halfSize))
|
|
@@ -92,100 +92,100 @@ export function MaplibreGLLayer (leaflet, maplibre, options) {
|
|
|
92
92
|
},
|
|
93
93
|
|
|
94
94
|
_initContainer: function () {
|
|
95
|
-
const container = this._container = leaflet.DomUtil.create('div', 'leaflet-gl-layer')
|
|
95
|
+
const container = this._container = leaflet.DomUtil.create('div', 'leaflet-gl-layer');
|
|
96
96
|
|
|
97
|
-
const size = this.getSize()
|
|
98
|
-
const offset = this._map.getSize().multiplyBy(this.options.padding)
|
|
99
|
-
container.style.width = `${size.x}px
|
|
100
|
-
container.style.height = `${size.y}px
|
|
97
|
+
const size = this.getSize();
|
|
98
|
+
const offset = this._map.getSize().multiplyBy(this.options.padding);
|
|
99
|
+
container.style.width = `${size.x}px`;
|
|
100
|
+
container.style.height = `${size.y}px`;
|
|
101
101
|
|
|
102
|
-
const topLeft = this._map.containerPointToLayerPoint([0, 0]).subtract(offset)
|
|
102
|
+
const topLeft = this._map.containerPointToLayerPoint([0, 0]).subtract(offset);
|
|
103
103
|
|
|
104
|
-
leaflet.DomUtil.setPosition(container, topLeft)
|
|
104
|
+
leaflet.DomUtil.setPosition(container, topLeft);
|
|
105
105
|
},
|
|
106
106
|
|
|
107
107
|
_initGL: function () {
|
|
108
|
-
const center = this._map.getCenter()
|
|
108
|
+
const center = this._map.getCenter();
|
|
109
109
|
|
|
110
110
|
const options = leaflet.extend({}, this.options, {
|
|
111
111
|
container: this._container,
|
|
112
112
|
center: [center.lng, center.lat],
|
|
113
113
|
zoom: this._map.getZoom() - 1,
|
|
114
114
|
attributionControl: false,
|
|
115
|
-
})
|
|
115
|
+
});
|
|
116
116
|
|
|
117
|
-
this._glMap = new maplibre.Map(options)
|
|
117
|
+
this._glMap = new maplibre.Map(options);
|
|
118
118
|
|
|
119
119
|
// allow GL base map to pan beyond min/max latitudes
|
|
120
|
-
this._glMap.transform.latRange = null
|
|
121
|
-
this._glMap.transform.maxValidLatitude = Infinity
|
|
120
|
+
this._glMap.transform.latRange = null;
|
|
121
|
+
this._glMap.transform.maxValidLatitude = Infinity;
|
|
122
122
|
|
|
123
|
-
this._transformGL(this._glMap)
|
|
123
|
+
this._transformGL(this._glMap);
|
|
124
124
|
|
|
125
125
|
if (this._glMap._canvas.canvas) {
|
|
126
126
|
// older versions of mapbox-gl surfaced the canvas differently
|
|
127
|
-
this._glMap._actualCanvas = this._glMap._canvas.canvas
|
|
127
|
+
this._glMap._actualCanvas = this._glMap._canvas.canvas;
|
|
128
128
|
} else {
|
|
129
|
-
this._glMap._actualCanvas = this._glMap._canvas
|
|
129
|
+
this._glMap._actualCanvas = this._glMap._canvas;
|
|
130
130
|
}
|
|
131
131
|
|
|
132
132
|
// treat child <canvas> element like leaflet.ImageOverlay
|
|
133
|
-
const canvas = this._glMap._actualCanvas
|
|
134
|
-
leaflet.DomUtil.addClass(canvas, 'leaflet-image-layer')
|
|
135
|
-
leaflet.DomUtil.addClass(canvas, 'leaflet-zoom-animated')
|
|
133
|
+
const canvas = this._glMap._actualCanvas;
|
|
134
|
+
leaflet.DomUtil.addClass(canvas, 'leaflet-image-layer');
|
|
135
|
+
leaflet.DomUtil.addClass(canvas, 'leaflet-zoom-animated');
|
|
136
136
|
if (this.options.interactive) {
|
|
137
|
-
leaflet.DomUtil.addClass(canvas, 'leaflet-interactive')
|
|
137
|
+
leaflet.DomUtil.addClass(canvas, 'leaflet-interactive');
|
|
138
138
|
}
|
|
139
139
|
if (this.options.className) {
|
|
140
|
-
leaflet.DomUtil.addClass(canvas, this.options.className)
|
|
140
|
+
leaflet.DomUtil.addClass(canvas, this.options.className);
|
|
141
141
|
}
|
|
142
142
|
},
|
|
143
143
|
|
|
144
144
|
_update: function (e) {
|
|
145
145
|
// update the offset so we can correct for it later when we zoom
|
|
146
|
-
this._offset = this._map.containerPointToLayerPoint([0, 0])
|
|
146
|
+
this._offset = this._map.containerPointToLayerPoint([0, 0]);
|
|
147
147
|
|
|
148
148
|
if (this._zooming) {
|
|
149
149
|
return
|
|
150
150
|
}
|
|
151
151
|
|
|
152
|
-
const size = this.getSize()
|
|
153
|
-
const container = this._container
|
|
154
|
-
const gl = this._glMap
|
|
155
|
-
const offset = this._map.getSize().multiplyBy(this.options.padding)
|
|
156
|
-
const topLeft = this._map.containerPointToLayerPoint([0, 0]).subtract(offset)
|
|
152
|
+
const size = this.getSize();
|
|
153
|
+
const container = this._container;
|
|
154
|
+
const gl = this._glMap;
|
|
155
|
+
const offset = this._map.getSize().multiplyBy(this.options.padding);
|
|
156
|
+
const topLeft = this._map.containerPointToLayerPoint([0, 0]).subtract(offset);
|
|
157
157
|
|
|
158
|
-
leaflet.DomUtil.setPosition(container, topLeft)
|
|
158
|
+
leaflet.DomUtil.setPosition(container, topLeft);
|
|
159
159
|
|
|
160
|
-
this._transformGL(gl)
|
|
160
|
+
this._transformGL(gl);
|
|
161
161
|
|
|
162
162
|
if (gl.transform.width !== size.x || gl.transform.height !== size.y) {
|
|
163
|
-
container.style.width = `${size.x}px
|
|
164
|
-
container.style.height = `${size.y}px
|
|
163
|
+
container.style.width = `${size.x}px`;
|
|
164
|
+
container.style.height = `${size.y}px`;
|
|
165
165
|
if (gl._resize !== null && gl._resize !== undefined) {
|
|
166
|
-
gl._resize()
|
|
166
|
+
gl._resize();
|
|
167
167
|
} else {
|
|
168
|
-
gl.resize()
|
|
168
|
+
gl.resize();
|
|
169
169
|
}
|
|
170
170
|
} else {
|
|
171
171
|
// older versions of mapbox-gl surfaced update publicly
|
|
172
172
|
if (gl._update !== null && gl._update !== undefined) {
|
|
173
|
-
gl._update()
|
|
173
|
+
gl._update();
|
|
174
174
|
} else {
|
|
175
|
-
gl.update()
|
|
175
|
+
gl.update();
|
|
176
176
|
}
|
|
177
177
|
}
|
|
178
178
|
},
|
|
179
179
|
|
|
180
180
|
_transformGL: function (gl) {
|
|
181
|
-
const center = this._map.getCenter()
|
|
181
|
+
const center = this._map.getCenter();
|
|
182
182
|
|
|
183
183
|
// gl.setView([center.lat, center.lng], this._map.getZoom() - 1, 0);
|
|
184
184
|
// calling setView directly causes sync issues because it uses requestAnimFrame
|
|
185
185
|
|
|
186
|
-
const tr = gl.transform
|
|
187
|
-
tr.center = maplibre.LngLat.convert([center.lng, center.lat])
|
|
188
|
-
tr.zoom = this._map.getZoom() - 1
|
|
186
|
+
const tr = gl.transform;
|
|
187
|
+
tr.center = maplibre.LngLat.convert([center.lng, center.lat]);
|
|
188
|
+
tr.zoom = this._map.getZoom() - 1;
|
|
189
189
|
},
|
|
190
190
|
|
|
191
191
|
// update the map constantly during a pinch zoom
|
|
@@ -193,79 +193,81 @@ export function MaplibreGLLayer (leaflet, maplibre, options) {
|
|
|
193
193
|
this._glMap.jumpTo({
|
|
194
194
|
zoom: this._map.getZoom() - 1,
|
|
195
195
|
center: this._map.getCenter(),
|
|
196
|
-
})
|
|
196
|
+
});
|
|
197
197
|
},
|
|
198
198
|
|
|
199
199
|
// borrowed from leaflet.ImageOverlay
|
|
200
200
|
// https://github.com/Leaflet/Leaflet/blob/master/src/layer/ImageOverlay.js#L139-L144
|
|
201
201
|
_animateZoom: function (e) {
|
|
202
|
-
const scale = this._map.getZoomScale(e.zoom)
|
|
203
|
-
const padding = this._map.getSize().multiplyBy(this.options.padding * scale)
|
|
204
|
-
const viewHalf = this.getSize()._divideBy(2)
|
|
202
|
+
const scale = this._map.getZoomScale(e.zoom);
|
|
203
|
+
const padding = this._map.getSize().multiplyBy(this.options.padding * scale);
|
|
204
|
+
const viewHalf = this.getSize()._divideBy(2);
|
|
205
205
|
// corrections for padding (scaled), adapted from
|
|
206
206
|
// https://github.com/Leaflet/Leaflet/blob/master/src/map/Map.js#L1490-L1508
|
|
207
207
|
const topLeft = this._map.project(e.center, e.zoom)
|
|
208
208
|
._subtract(viewHalf)
|
|
209
209
|
._add(this._map._getMapPanePos()
|
|
210
|
-
.add(padding))._round()
|
|
210
|
+
.add(padding))._round();
|
|
211
211
|
const offset = this._map.project(this._map.getBounds().getNorthWest(), e.zoom)
|
|
212
|
-
._subtract(topLeft)
|
|
212
|
+
._subtract(topLeft);
|
|
213
213
|
|
|
214
214
|
leaflet.DomUtil.setTransform(
|
|
215
215
|
this._glMap._actualCanvas,
|
|
216
216
|
offset.subtract(this._offset),
|
|
217
217
|
scale
|
|
218
|
-
)
|
|
218
|
+
);
|
|
219
219
|
},
|
|
220
220
|
|
|
221
221
|
_zoomStart: function (e) {
|
|
222
|
-
this._zooming = true
|
|
222
|
+
this._zooming = true;
|
|
223
223
|
},
|
|
224
224
|
|
|
225
225
|
_zoomEnd: function () {
|
|
226
|
-
const scale = this._map.getZoomScale(this._map.getZoom())
|
|
226
|
+
const scale = this._map.getZoomScale(this._map.getZoom());
|
|
227
227
|
|
|
228
228
|
leaflet.DomUtil.setTransform(
|
|
229
229
|
this._glMap._actualCanvas,
|
|
230
230
|
// https://github.com/mapbox/mapbox-gl-leaflet/pull/130
|
|
231
231
|
null,
|
|
232
232
|
scale
|
|
233
|
-
)
|
|
233
|
+
);
|
|
234
234
|
|
|
235
|
-
this._zooming = false
|
|
235
|
+
this._zooming = false;
|
|
236
236
|
|
|
237
|
-
this._update()
|
|
237
|
+
this._update();
|
|
238
238
|
},
|
|
239
239
|
|
|
240
240
|
_transitionEnd: function (e) {
|
|
241
241
|
leaflet.Util.requestAnimFrame(function () {
|
|
242
|
-
const zoom = this._map.getZoom()
|
|
243
|
-
const center = this._map.getCenter()
|
|
242
|
+
const zoom = this._map.getZoom();
|
|
243
|
+
const center = this._map.getCenter();
|
|
244
244
|
const offset = this._map.latLngToContainerPoint(
|
|
245
245
|
this._map.getBounds().getNorthWest()
|
|
246
|
-
)
|
|
246
|
+
);
|
|
247
247
|
|
|
248
248
|
// reset the scale and offset
|
|
249
|
-
leaflet.DomUtil.setTransform(this._glMap._actualCanvas, offset, 1)
|
|
249
|
+
leaflet.DomUtil.setTransform(this._glMap._actualCanvas, offset, 1);
|
|
250
250
|
|
|
251
251
|
// enable panning once the gl map is ready again
|
|
252
252
|
this._glMap.once('moveend', leaflet.Util.bind(function () {
|
|
253
|
-
this._zoomEnd()
|
|
254
|
-
}, this))
|
|
253
|
+
this._zoomEnd();
|
|
254
|
+
}, this));
|
|
255
255
|
|
|
256
256
|
// update the map position
|
|
257
257
|
this._glMap.jumpTo({
|
|
258
258
|
center: center,
|
|
259
259
|
zoom: zoom - 1,
|
|
260
|
-
})
|
|
261
|
-
}, this)
|
|
260
|
+
});
|
|
261
|
+
}, this);
|
|
262
262
|
},
|
|
263
263
|
|
|
264
264
|
_resize: function (e) {
|
|
265
|
-
this._transitionEnd(e)
|
|
265
|
+
this._transitionEnd(e);
|
|
266
266
|
},
|
|
267
|
-
})
|
|
267
|
+
});
|
|
268
268
|
|
|
269
269
|
return new Layer(options)
|
|
270
270
|
}
|
|
271
271
|
|
|
272
|
+
export { MaplibreGLLayer };
|
|
273
|
+
//# sourceMappingURL=leaflet-maplibre-gl.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"leaflet-maplibre-gl.js","sources":["../../../../src/components/leaflet-map/renderer/leaflet-maplibre-gl.js"],"sourcesContent":["// eslint-disable-next-line @typescript-eslint/explicit-function-return-type\nexport function MaplibreGLLayer (leaflet, maplibre, options) {\n // eslint-disable-next-line @typescript-eslint/naming-convention\n const Layer = leaflet.Layer.extend({\n options: {\n updateInterval: 32,\n // How much to extend the overlay view (relative to map size)\n // e.g. 0.1 would be 10% of map view in each direction\n padding: 0.1,\n // whether or not to register the mouse and keyboard\n // events on the maplibre overlay\n interactive: false,\n // set the tilepane as the default pane to draw gl tiles\n pane: 'tilePane',\n },\n\n initialize: function (options) {\n leaflet.setOptions(this, options)\n\n // setup throttling the update event when panning\n this._throttledUpdate = leaflet.Util.throttle(this._update, this.options.updateInterval, this)\n },\n\n onAdd: function (map) {\n if (!this._container) {\n this._initContainer()\n }\n\n const paneName = this.getPaneName()\n map.getPane(paneName).appendChild(this._container)\n\n this._initGL()\n\n this._offset = this._map.containerPointToLayerPoint([0, 0])\n\n // work around https://github.com/mapbox/mapbox-gl-leaflet/issues/47\n if (map.options.zoomAnimation) {\n leaflet.DomEvent.on(map._proxy, leaflet.DomUtil.TRANSITION_END, this._transitionEnd, this)\n }\n },\n\n onRemove: function (map) {\n if (this._map._proxy && this._map.options.zoomAnimation) {\n leaflet.DomEvent.off(this._map._proxy, leaflet.DomUtil.TRANSITION_END, this._transitionEnd, this)\n }\n const paneName = this.getPaneName()\n map.getPane(paneName).removeChild(this._container)\n\n this._glMap.remove()\n this._glMap = null\n },\n\n getEvents: function () {\n return {\n move: this._throttledUpdate, // sensibly throttle updating while panning\n zoomanim: this._animateZoom, // applys the zoom animation to the <canvas>\n zoom: this._pinchZoom, // animate every zoom event for smoother pinch-zooming\n zoomstart: this._zoomStart, // flag starting a zoom to disable panning\n zoomend: this._zoomEnd,\n resize: this._resize,\n }\n },\n\n getMaplibreMap: function () {\n return this._glMap\n },\n\n getCanvas: function () {\n return this._glMap.getCanvas()\n },\n\n getSize: function () {\n return this._map.getSize().multiplyBy(1 + this.options.padding * 2)\n },\n\n getBounds: function () {\n const halfSize = this.getSize().multiplyBy(0.5)\n const center = this._map.latLngToContainerPoint(this._map.getCenter())\n return leaflet.latLngBounds(\n this._map.containerPointToLatLng(center.subtract(halfSize)),\n this._map.containerPointToLatLng(center.add(halfSize))\n )\n },\n\n getContainer: function () {\n return this._container\n },\n\n // returns the pane name set in options if it is a valid pane, defaults to tilePane\n getPaneName: function () {\n return this._map.getPane(this.options.pane) ? this.options.pane : 'tilePane'\n },\n\n _initContainer: function () {\n const container = this._container = leaflet.DomUtil.create('div', 'leaflet-gl-layer')\n\n const size = this.getSize()\n const offset = this._map.getSize().multiplyBy(this.options.padding)\n container.style.width = `${size.x}px`\n container.style.height = `${size.y}px`\n\n const topLeft = this._map.containerPointToLayerPoint([0, 0]).subtract(offset)\n\n leaflet.DomUtil.setPosition(container, topLeft)\n },\n\n _initGL: function () {\n const center = this._map.getCenter()\n\n const options = leaflet.extend({}, this.options, {\n container: this._container,\n center: [center.lng, center.lat],\n zoom: this._map.getZoom() - 1,\n attributionControl: false,\n })\n\n this._glMap = new maplibre.Map(options)\n\n // allow GL base map to pan beyond min/max latitudes\n this._glMap.transform.latRange = null\n this._glMap.transform.maxValidLatitude = Infinity\n\n this._transformGL(this._glMap)\n\n if (this._glMap._canvas.canvas) {\n // older versions of mapbox-gl surfaced the canvas differently\n this._glMap._actualCanvas = this._glMap._canvas.canvas\n } else {\n this._glMap._actualCanvas = this._glMap._canvas\n }\n\n // treat child <canvas> element like leaflet.ImageOverlay\n const canvas = this._glMap._actualCanvas\n leaflet.DomUtil.addClass(canvas, 'leaflet-image-layer')\n leaflet.DomUtil.addClass(canvas, 'leaflet-zoom-animated')\n if (this.options.interactive) {\n leaflet.DomUtil.addClass(canvas, 'leaflet-interactive')\n }\n if (this.options.className) {\n leaflet.DomUtil.addClass(canvas, this.options.className)\n }\n },\n\n _update: function (e) {\n // update the offset so we can correct for it later when we zoom\n this._offset = this._map.containerPointToLayerPoint([0, 0])\n\n if (this._zooming) {\n return\n }\n\n const size = this.getSize()\n const container = this._container\n const gl = this._glMap\n const offset = this._map.getSize().multiplyBy(this.options.padding)\n const topLeft = this._map.containerPointToLayerPoint([0, 0]).subtract(offset)\n\n leaflet.DomUtil.setPosition(container, topLeft)\n\n this._transformGL(gl)\n\n if (gl.transform.width !== size.x || gl.transform.height !== size.y) {\n container.style.width = `${size.x}px`\n container.style.height = `${size.y}px`\n if (gl._resize !== null && gl._resize !== undefined) {\n gl._resize()\n } else {\n gl.resize()\n }\n } else {\n // older versions of mapbox-gl surfaced update publicly\n if (gl._update !== null && gl._update !== undefined) {\n gl._update()\n } else {\n gl.update()\n }\n }\n },\n\n _transformGL: function (gl) {\n const center = this._map.getCenter()\n\n // gl.setView([center.lat, center.lng], this._map.getZoom() - 1, 0);\n // calling setView directly causes sync issues because it uses requestAnimFrame\n\n const tr = gl.transform\n tr.center = maplibre.LngLat.convert([center.lng, center.lat])\n tr.zoom = this._map.getZoom() - 1\n },\n\n // update the map constantly during a pinch zoom\n _pinchZoom: function (e) {\n this._glMap.jumpTo({\n zoom: this._map.getZoom() - 1,\n center: this._map.getCenter(),\n })\n },\n\n // borrowed from leaflet.ImageOverlay\n // https://github.com/Leaflet/Leaflet/blob/master/src/layer/ImageOverlay.js#L139-L144\n _animateZoom: function (e) {\n const scale = this._map.getZoomScale(e.zoom)\n const padding = this._map.getSize().multiplyBy(this.options.padding * scale)\n const viewHalf = this.getSize()._divideBy(2)\n // corrections for padding (scaled), adapted from\n // https://github.com/Leaflet/Leaflet/blob/master/src/map/Map.js#L1490-L1508\n const topLeft = this._map.project(e.center, e.zoom)\n ._subtract(viewHalf)\n ._add(this._map._getMapPanePos()\n .add(padding))._round()\n const offset = this._map.project(this._map.getBounds().getNorthWest(), e.zoom)\n ._subtract(topLeft)\n\n leaflet.DomUtil.setTransform(\n this._glMap._actualCanvas,\n offset.subtract(this._offset),\n scale\n )\n },\n\n _zoomStart: function (e) {\n this._zooming = true\n },\n\n _zoomEnd: function () {\n const scale = this._map.getZoomScale(this._map.getZoom())\n\n leaflet.DomUtil.setTransform(\n this._glMap._actualCanvas,\n // https://github.com/mapbox/mapbox-gl-leaflet/pull/130\n null,\n scale\n )\n\n this._zooming = false\n\n this._update()\n },\n\n _transitionEnd: function (e) {\n leaflet.Util.requestAnimFrame(function () {\n const zoom = this._map.getZoom()\n const center = this._map.getCenter()\n const offset = this._map.latLngToContainerPoint(\n this._map.getBounds().getNorthWest()\n )\n\n // reset the scale and offset\n leaflet.DomUtil.setTransform(this._glMap._actualCanvas, offset, 1)\n\n // enable panning once the gl map is ready again\n this._glMap.once('moveend', leaflet.Util.bind(function () {\n this._zoomEnd()\n }, this))\n\n // update the map position\n this._glMap.jumpTo({\n center: center,\n zoom: zoom - 1,\n })\n }, this)\n },\n\n _resize: function (e) {\n this._transitionEnd(e)\n },\n })\n\n return new Layer(options)\n}\n\n"],"names":[],"mappings":"AAAA;AACO,SAAS,eAAe,EAAE,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE;AAC7D;AACA,EAAE,MAAM,KAAK,GAAG,OAAO,CAAC,KAAK,CAAC,MAAM,CAAC;AACrC,IAAI,OAAO,EAAE;AACb,MAAM,cAAc,EAAE,EAAE;AACxB;AACA;AACA,MAAM,OAAO,EAAE,GAAG;AAClB;AACA;AACA,MAAM,WAAW,EAAE,KAAK;AACxB;AACA,MAAM,IAAI,EAAE,UAAU;AACtB,KAAK;AACL;AACA,IAAI,UAAU,EAAE,UAAU,OAAO,EAAE;AACnC,MAAM,OAAO,CAAC,UAAU,CAAC,IAAI,EAAE,OAAO,EAAC;AACvC;AACA;AACA,MAAM,IAAI,CAAC,gBAAgB,GAAG,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,cAAc,EAAE,IAAI,EAAC;AACpG,KAAK;AACL;AACA,IAAI,KAAK,EAAE,UAAU,GAAG,EAAE;AAC1B,MAAM,IAAI,CAAC,IAAI,CAAC,UAAU,EAAE;AAC5B,QAAQ,IAAI,CAAC,cAAc,GAAE;AAC7B,OAAO;AACP;AACA,MAAM,MAAM,QAAQ,GAAG,IAAI,CAAC,WAAW,GAAE;AACzC,MAAM,GAAG,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,WAAW,CAAC,IAAI,CAAC,UAAU,EAAC;AACxD;AACA,MAAM,IAAI,CAAC,OAAO,GAAE;AACpB;AACA,MAAM,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC,IAAI,CAAC,0BAA0B,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,EAAC;AACjE;AACA;AACA,MAAM,IAAI,GAAG,CAAC,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C,IAAI,CAAC,SAAS,EAAE,CAAC,YAAY,EAAE;AAC9C,UAAS;AACT;AACA;AACA,QAAQ,OAAO,CAAC,OAAO,CAAC,YAAY,CAAC,IAAI,CAAC,MAAM,CAAC,aAAa,EAAE,MAAM,EAAE,CAAC,EAAC;AAC1E;AACA;AACA,QAAQ,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,SAAS,EAAE,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,YAAY;AAClE,UAAU,IAAI,CAAC,QAAQ,GAAE;AACzB,SAAS,EAAE,IAAI,CAAC,EAAC;AACjB;AACA;AACA,QAAQ,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC;AAC3B,UAAU,MAAM,EAAE,MAAM;AACxB,UAAU,IAAI,EAAE,IAAI,GAAG,CAAC;AACxB,SAAS,EAAC;AACV,OAAO,EAAE,IAAI,EAAC;AACd,KAAK;AACL;AACA,IAAI,OAAO,EAAE,UAAU,CAAC,EAAE;AAC1B,MAAM,IAAI,CAAC,cAAc,CAAC,CAAC,EAAC;AAC5B,KAAK;AACL,GAAG,EAAC;AACJ;AACA,EAAE,OAAO,IAAI,KAAK,CAAC,OAAO,CAAC;AAC3B;;;;"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import mapLibreBaseSettings from './mapboxgl/mapboxgl-settings.json.js';
|
|
2
|
+
import mapLibreDarkTheme from './mapboxgl/mapboxgl-dark-theme.json.js';
|
|
3
|
+
import mapLibreLightTheme from './mapboxgl/mapboxgl-light-theme.json.js';
|
|
4
|
+
|
|
5
|
+
const MapLibreArcticDark = Object.assign(Object.assign({}, mapLibreBaseSettings), { layers: [
|
|
6
|
+
...mapLibreDarkTheme.layers,
|
|
7
|
+
...mapLibreBaseSettings.layers,
|
|
8
|
+
] });
|
|
9
|
+
const MapLibreArcticLight = Object.assign(Object.assign({}, mapLibreBaseSettings), { layers: [
|
|
10
|
+
...mapLibreLightTheme.layers,
|
|
11
|
+
...mapLibreBaseSettings.layers,
|
|
12
|
+
] });
|
|
13
|
+
|
|
14
|
+
export { MapLibreArcticDark, MapLibreArcticLight };
|
|
15
|
+
//# sourceMappingURL=map-style.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"map-style.js","sources":["../../../../src/components/leaflet-map/renderer/map-style.ts"],"sourcesContent":["import { StyleSpecification, LayerSpecification } from 'maplibre-gl'\n\nimport mapLibreBaseSettings from './mapboxgl/mapboxgl-settings.json'\nimport mapLibreDarkTheme from './mapboxgl/mapboxgl-dark-theme.json'\nimport mapLibreLightTheme from './mapboxgl/mapboxgl-light-theme.json'\n\n\nexport type MapLibreStyleSpecs = StyleSpecification\n\nexport const MapLibreArcticDark: MapLibreStyleSpecs = {\n ...(mapLibreBaseSettings as StyleSpecification),\n layers: [\n ...mapLibreDarkTheme.layers,\n ...mapLibreBaseSettings.layers,\n ] as Array<LayerSpecification>,\n}\n\nexport const MapLibreArcticLight: MapLibreStyleSpecs = {\n ...(mapLibreBaseSettings as StyleSpecification),\n layers: [\n ...mapLibreLightTheme.layers,\n ...mapLibreBaseSettings.layers,\n ] as Array<LayerSpecification>,\n}\n"],"names":[],"mappings":";;;;AASa,MAAA,kBAAkB,mCACzB,oBAA2C,CAAA,EAAA,EAC/C,MAAM,EAAE;QACN,GAAG,iBAAiB,CAAC,MAAM;QAC3B,GAAG,oBAAoB,CAAC,MAAM;AACF,KAAA,EAAA,EAC/B;AAEY,MAAA,mBAAmB,mCAC1B,oBAA2C,CAAA,EAAA,EAC/C,MAAM,EAAE;QACN,GAAG,kBAAkB,CAAC,MAAM;QAC5B,GAAG,oBAAoB,CAAC,MAAM;AACF,KAAA,EAAA;;;;"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
var layers = [
|
|
2
|
+
{
|
|
3
|
+
id: "background",
|
|
4
|
+
layout: {
|
|
5
|
+
visibility: "visible"
|
|
6
|
+
},
|
|
7
|
+
paint: {
|
|
8
|
+
"background-color": "#5C627A"
|
|
9
|
+
},
|
|
10
|
+
type: "background"
|
|
11
|
+
},
|
|
12
|
+
{
|
|
13
|
+
filter: [
|
|
14
|
+
"all",
|
|
15
|
+
[
|
|
16
|
+
"!=",
|
|
17
|
+
"intermittent",
|
|
18
|
+
1
|
|
19
|
+
]
|
|
20
|
+
],
|
|
21
|
+
id: "water",
|
|
22
|
+
layout: {
|
|
23
|
+
visibility: "visible"
|
|
24
|
+
},
|
|
25
|
+
metadata: {
|
|
26
|
+
},
|
|
27
|
+
paint: {
|
|
28
|
+
"fill-color": "#2A2D39"
|
|
29
|
+
},
|
|
30
|
+
source: "openmaptiles",
|
|
31
|
+
"source-layer": "water",
|
|
32
|
+
type: "fill"
|
|
33
|
+
}
|
|
34
|
+
];
|
|
35
|
+
var mapLibreDarkTheme = {
|
|
36
|
+
layers: layers
|
|
37
|
+
};
|
|
38
|
+
|
|
39
|
+
export { mapLibreDarkTheme as default, layers };
|
|
40
|
+
//# sourceMappingURL=mapboxgl-dark-theme.json.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mapboxgl-dark-theme.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
var layers = [
|
|
2
|
+
{
|
|
3
|
+
id: "background",
|
|
4
|
+
layout: {
|
|
5
|
+
visibility: "visible"
|
|
6
|
+
},
|
|
7
|
+
paint: {
|
|
8
|
+
"background-color": "rgba(255, 255, 255, 1)"
|
|
9
|
+
},
|
|
10
|
+
type: "background"
|
|
11
|
+
},
|
|
12
|
+
{
|
|
13
|
+
filter: [
|
|
14
|
+
"all",
|
|
15
|
+
[
|
|
16
|
+
"!=",
|
|
17
|
+
"intermittent",
|
|
18
|
+
1
|
|
19
|
+
]
|
|
20
|
+
],
|
|
21
|
+
id: "water",
|
|
22
|
+
layout: {
|
|
23
|
+
visibility: "visible"
|
|
24
|
+
},
|
|
25
|
+
metadata: {
|
|
26
|
+
},
|
|
27
|
+
paint: {
|
|
28
|
+
"fill-color": "rgb(223, 229, 235)"
|
|
29
|
+
},
|
|
30
|
+
source: "openmaptiles",
|
|
31
|
+
"source-layer": "water",
|
|
32
|
+
type: "fill"
|
|
33
|
+
}
|
|
34
|
+
];
|
|
35
|
+
var mapLibreLightTheme = {
|
|
36
|
+
layers: layers
|
|
37
|
+
};
|
|
38
|
+
|
|
39
|
+
export { mapLibreLightTheme as default, layers };
|
|
40
|
+
//# sourceMappingURL=mapboxgl-light-theme.json.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mapboxgl-light-theme.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|