map-ol-utils 0.1.17 → 0.1.19
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/dist/index.cjs +24 -29
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +24 -29
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -733,7 +733,7 @@ var import_source2 = require("ol/source");
|
|
|
733
733
|
var import_tilegrid = require("ol/tilegrid");
|
|
734
734
|
var import_layer = require("ol/layer");
|
|
735
735
|
var import_WMTS = __toESM(require("ol/tilegrid/WMTS"), 1);
|
|
736
|
-
var createBaseLayer = (
|
|
736
|
+
var createBaseLayer = (layerName = "hzsyvector_dark") => {
|
|
737
737
|
return new import_layer.Tile({
|
|
738
738
|
zIndex: -5,
|
|
739
739
|
minZoom: 8,
|
|
@@ -742,39 +742,34 @@ var createBaseLayer = (isDark = true) => {
|
|
|
742
742
|
tileGrid: new import_tilegrid.TileGrid({
|
|
743
743
|
tileSize: 256,
|
|
744
744
|
resolutions: [
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
0.
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
745
|
+
0.00549933137253187,
|
|
746
|
+
0.00274966568626595,
|
|
747
|
+
0.00137483284313297,
|
|
748
|
+
687416421566485e-18,
|
|
749
|
+
343708210783242e-18,
|
|
750
|
+
171854105391621e-18,
|
|
751
|
+
859270526958104e-19,
|
|
752
|
+
429635263479052e-19,
|
|
753
|
+
214817631739526e-19,
|
|
754
|
+
107408815869763e-19,
|
|
755
|
+
537044079348816e-20,
|
|
756
|
+
268522039674407e-20,
|
|
757
|
+
134261019837204e-20
|
|
758
758
|
],
|
|
759
|
-
origin: [118.
|
|
759
|
+
origin: [118.122911693886, 31.2869311022836],
|
|
760
760
|
extent: [
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
761
|
+
116.43263049006,
|
|
762
|
+
28.6201742126026,
|
|
763
|
+
123.705594256347,
|
|
764
|
+
31.9765041681924
|
|
765
765
|
]
|
|
766
766
|
}),
|
|
767
767
|
projection: "EPSG:4326",
|
|
768
|
-
urls:
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
] : [
|
|
774
|
-
"https://ywtg.citybrain.hangzhou.gov.cn:9456/hzsyvector/{z}/{y}/{x}",
|
|
775
|
-
"https://ywtg.citybrain.hangzhou.gov.cn:9457/hzsyvector/{z}/{y}/{x}",
|
|
776
|
-
"https://ywtg.citybrain.hangzhou.gov.cn:9458/hzsyvector/{z}/{y}/{x}",
|
|
777
|
-
"https://ywtg.citybrain.hangzhou.gov.cn:9459/hzsyvector/{z}/{y}/{x}"
|
|
768
|
+
urls: [
|
|
769
|
+
`https://ywtg.citybrain.hangzhou.gov.cn:9456/${layerName}/{z}/{y}/{x}`,
|
|
770
|
+
`https://ywtg.citybrain.hangzhou.gov.cn:9457/${layerName}/{z}/{y}/{x}`,
|
|
771
|
+
`https://ywtg.citybrain.hangzhou.gov.cn:9458/${layerName}/{z}/{y}/{x}`,
|
|
772
|
+
`https://ywtg.citybrain.hangzhou.gov.cn:9459/${layerName}/{z}/{y}/{x}`
|
|
778
773
|
]
|
|
779
774
|
}),
|
|
780
775
|
properties: {
|
package/dist/index.d.cts
CHANGED
|
@@ -123,9 +123,9 @@ declare const createWmtsLayer: (serverUrl: string) => (config: WmtsSourceOptions
|
|
|
123
123
|
|
|
124
124
|
/**
|
|
125
125
|
* 创建杭州规自地图
|
|
126
|
-
* @param
|
|
126
|
+
* @param layerName
|
|
127
127
|
*/
|
|
128
|
-
declare const createBaseLayer: (
|
|
128
|
+
declare const createBaseLayer: (layerName?: string) => Tile<XYZ>;
|
|
129
129
|
/**
|
|
130
130
|
* 创建天地图
|
|
131
131
|
* @param layerName - 图层名称
|
package/dist/index.d.ts
CHANGED
|
@@ -123,9 +123,9 @@ declare const createWmtsLayer: (serverUrl: string) => (config: WmtsSourceOptions
|
|
|
123
123
|
|
|
124
124
|
/**
|
|
125
125
|
* 创建杭州规自地图
|
|
126
|
-
* @param
|
|
126
|
+
* @param layerName
|
|
127
127
|
*/
|
|
128
|
-
declare const createBaseLayer: (
|
|
128
|
+
declare const createBaseLayer: (layerName?: string) => Tile<XYZ>;
|
|
129
129
|
/**
|
|
130
130
|
* 创建天地图
|
|
131
131
|
* @param layerName - 图层名称
|
package/dist/index.js
CHANGED
|
@@ -672,7 +672,7 @@ import { WMTS } from "ol/source";
|
|
|
672
672
|
import { TileGrid } from "ol/tilegrid";
|
|
673
673
|
import { Tile } from "ol/layer";
|
|
674
674
|
import WMTSTileGrid from "ol/tilegrid/WMTS";
|
|
675
|
-
var createBaseLayer = (
|
|
675
|
+
var createBaseLayer = (layerName = "hzsyvector_dark") => {
|
|
676
676
|
return new Tile({
|
|
677
677
|
zIndex: -5,
|
|
678
678
|
minZoom: 8,
|
|
@@ -681,39 +681,34 @@ var createBaseLayer = (isDark = true) => {
|
|
|
681
681
|
tileGrid: new TileGrid({
|
|
682
682
|
tileSize: 256,
|
|
683
683
|
resolutions: [
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
0.
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
684
|
+
0.00549933137253187,
|
|
685
|
+
0.00274966568626595,
|
|
686
|
+
0.00137483284313297,
|
|
687
|
+
687416421566485e-18,
|
|
688
|
+
343708210783242e-18,
|
|
689
|
+
171854105391621e-18,
|
|
690
|
+
859270526958104e-19,
|
|
691
|
+
429635263479052e-19,
|
|
692
|
+
214817631739526e-19,
|
|
693
|
+
107408815869763e-19,
|
|
694
|
+
537044079348816e-20,
|
|
695
|
+
268522039674407e-20,
|
|
696
|
+
134261019837204e-20
|
|
697
697
|
],
|
|
698
|
-
origin: [118.
|
|
698
|
+
origin: [118.122911693886, 31.2869311022836],
|
|
699
699
|
extent: [
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
700
|
+
116.43263049006,
|
|
701
|
+
28.6201742126026,
|
|
702
|
+
123.705594256347,
|
|
703
|
+
31.9765041681924
|
|
704
704
|
]
|
|
705
705
|
}),
|
|
706
706
|
projection: "EPSG:4326",
|
|
707
|
-
urls:
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
] : [
|
|
713
|
-
"https://ywtg.citybrain.hangzhou.gov.cn:9456/hzsyvector/{z}/{y}/{x}",
|
|
714
|
-
"https://ywtg.citybrain.hangzhou.gov.cn:9457/hzsyvector/{z}/{y}/{x}",
|
|
715
|
-
"https://ywtg.citybrain.hangzhou.gov.cn:9458/hzsyvector/{z}/{y}/{x}",
|
|
716
|
-
"https://ywtg.citybrain.hangzhou.gov.cn:9459/hzsyvector/{z}/{y}/{x}"
|
|
707
|
+
urls: [
|
|
708
|
+
`https://ywtg.citybrain.hangzhou.gov.cn:9456/${layerName}/{z}/{y}/{x}`,
|
|
709
|
+
`https://ywtg.citybrain.hangzhou.gov.cn:9457/${layerName}/{z}/{y}/{x}`,
|
|
710
|
+
`https://ywtg.citybrain.hangzhou.gov.cn:9458/${layerName}/{z}/{y}/{x}`,
|
|
711
|
+
`https://ywtg.citybrain.hangzhou.gov.cn:9459/${layerName}/{z}/{y}/{x}`
|
|
717
712
|
]
|
|
718
713
|
}),
|
|
719
714
|
properties: {
|