@dartcom/ui-kit 10.2.13 → 10.2.15
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/components/layers/leaflet/config/constants.d.ts +1 -6
- package/dist/components/layers/leaflet/config/constants.d.ts.map +1 -1
- package/dist/components/layers/leaflet/layers/camera/lib/utils.d.ts.map +1 -1
- package/dist/components/layers/leaflet/layers/lane-marking-line/constants.d.ts +7 -0
- package/dist/components/layers/leaflet/layers/lane-marking-line/constants.d.ts.map +1 -0
- package/dist/components/layers/leaflet/layers/lane-marking-line/index.d.ts +2 -0
- package/dist/components/layers/leaflet/layers/lane-marking-line/index.d.ts.map +1 -0
- package/dist/components/layers/leaflet/layers/lane-marking-line/utils.d.ts +3 -0
- package/dist/components/layers/leaflet/layers/lane-marking-line/utils.d.ts.map +1 -0
- package/dist/components/layers/leaflet/layers/lane-marking-poly/index.d.ts +2 -0
- package/dist/components/layers/leaflet/layers/lane-marking-poly/index.d.ts.map +1 -0
- package/dist/components/layers/leaflet/layers/lane-marking-poly/utils.d.ts +3 -0
- package/dist/components/layers/leaflet/layers/lane-marking-poly/utils.d.ts.map +1 -0
- package/dist/components/layers/leaflet/layers/parking-line/index.d.ts +2 -0
- package/dist/components/layers/leaflet/layers/parking-line/index.d.ts.map +1 -0
- package/dist/components/layers/leaflet/layers/parking-line/utils.d.ts +3 -0
- package/dist/components/layers/leaflet/layers/parking-line/utils.d.ts.map +1 -0
- package/dist/components/layers/leaflet/layers/pillar/lib/utils.d.ts.map +1 -1
- package/dist/components/layers/leaflet/layers/road-poly/constants.d.ts +5 -0
- package/dist/components/layers/leaflet/layers/road-poly/constants.d.ts.map +1 -0
- package/dist/components/layers/leaflet/layers/road-poly/index.d.ts +4 -0
- package/dist/components/layers/leaflet/layers/road-poly/index.d.ts.map +1 -0
- package/dist/components/layers/leaflet/layers/road-poly/types.d.ts +8 -0
- package/dist/components/layers/leaflet/layers/road-poly/types.d.ts.map +1 -0
- package/dist/components/layers/leaflet/layers/road-poly/utils.d.ts +3 -0
- package/dist/components/layers/leaflet/layers/road-poly/utils.d.ts.map +1 -0
- package/dist/components/layers/leaflet/layers/traffic-sign/lib/utils.d.ts.map +1 -1
- package/dist/components/layers/leaflet/layers/traffic-signal/lib/utils.d.ts.map +1 -1
- package/dist/components/layers/leaflet/leaflet.d.ts +2 -2
- package/dist/components/layers/leaflet/leaflet.d.ts.map +1 -1
- package/dist/components/layers/leaflet/leaflet.stories.d.ts +2 -0
- package/dist/components/layers/leaflet/leaflet.stories.d.ts.map +1 -1
- package/dist/components/layers/leaflet/lib/types.d.ts +16 -15
- package/dist/components/layers/leaflet/lib/types.d.ts.map +1 -1
- package/dist/components/layers/leaflet/lib/utils.d.ts.map +1 -1
- package/dist/configs/global/global.d.ts.map +1 -1
- package/dist/constants/index.d.ts +0 -1
- package/dist/constants/index.d.ts.map +1 -1
- package/dist/index.cjs +640 -735
- package/dist/index.cjs.map +1 -1
- package/dist/index.esm.js +5 -5
- package/dist/index.esm.js.map +1 -1
- package/dist/lib/utils.d.ts +2 -0
- package/dist/lib/utils.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -1964,6 +1964,12 @@ const getUniqueKey = () => {
|
|
|
1964
1964
|
const uniqueKey = uuid();
|
|
1965
1965
|
return uniqueKey;
|
|
1966
1966
|
};
|
|
1967
|
+
const getNewId = (numberSigns) => {
|
|
1968
|
+
const min = Math.pow(10, numberSigns - 1) + 1;
|
|
1969
|
+
const max = Math.pow(10, numberSigns) - 1;
|
|
1970
|
+
const newId = -Math.floor(Math.random() * (max - min + 1) + min);
|
|
1971
|
+
return newId;
|
|
1972
|
+
};
|
|
1967
1973
|
const getCoordinateByLatLng = (latLng) => {
|
|
1968
1974
|
const coordinate = {
|
|
1969
1975
|
lat: latLng.lat,
|
|
@@ -1978,6 +1984,10 @@ const getEntityNames = ({ entity, names, }) => {
|
|
|
1978
1984
|
});
|
|
1979
1985
|
return layerNames;
|
|
1980
1986
|
};
|
|
1987
|
+
const getImageSrc = (path) => {
|
|
1988
|
+
const imageSrc = `${"https://dalganmap.ru/api-image/images"}/${path}`;
|
|
1989
|
+
return imageSrc;
|
|
1990
|
+
};
|
|
1981
1991
|
|
|
1982
1992
|
var niceErrors = {
|
|
1983
1993
|
0: "Invalid value for configuration 'enforceActions', expected 'never', 'always' or 'observed'",
|
|
@@ -14734,8 +14744,6 @@ const arraySchema = create$2();
|
|
|
14734
14744
|
const dateSchema = create$4();
|
|
14735
14745
|
const dateRequiredSchema = dateSchema.required(requiredMessage);
|
|
14736
14746
|
|
|
14737
|
-
const _backendUrl = 'https://dalganmap.ru/api';
|
|
14738
|
-
|
|
14739
14747
|
const Accordion = ({ items, onOpen, defaultValue = null, }) => {
|
|
14740
14748
|
const [currentValue, setCurrentValue] = React__namespace.useState(defaultValue);
|
|
14741
14749
|
const handleClose = React__namespace.useCallback(() => {
|
|
@@ -24658,730 +24666,265 @@ class LoggerService {
|
|
|
24658
24666
|
const loggerService = new LoggerService();
|
|
24659
24667
|
|
|
24660
24668
|
const tile_size = 256;
|
|
24661
|
-
const imagesPath = 'https://dalganmap.ru/api-image/images';
|
|
24662
|
-
const apiUrl = "http://89.108.118.23:3070";
|
|
24663
24669
|
const sourceUrl = {
|
|
24664
|
-
[exports.TangramSourceNames.TILE]: `${
|
|
24665
|
-
[exports.TangramSourceNames.NATURE_TILE]: `${
|
|
24666
|
-
[exports.TangramSourceNames.MSK]: `${
|
|
24670
|
+
[exports.TangramSourceNames.TILE]: `${"https://dalganmap.ru/api"}/tiles/get_tile/{z}/{x}/{y}.mvt`,
|
|
24671
|
+
[exports.TangramSourceNames.NATURE_TILE]: `${"https://dalganmap.ru/api"}/tiles/get_nature_tile/{z}/{x}/{y}.mvt`,
|
|
24672
|
+
[exports.TangramSourceNames.MSK]: `${"http://89.108.118.23:3070"}/tiles/get_tile/{z}/{x}/{y}.mvt`,
|
|
24667
24673
|
};
|
|
24668
|
-
|
|
24674
|
+
|
|
24675
|
+
var data = { global:{ links:{ getIsConstruction:"function (feature) {\n const { construction } = feature;\n\n return construction;\n}\n",
|
|
24676
|
+
getIsFunctionalClass:"function (feature) {\n const { functional_class, access_id } = feature;\n\n return functional_class === 5 && access_id === 32;\n}\n",
|
|
24677
|
+
getIsLowMobility:"function (feature) {\n const { functional_class, low_mobility } = feature;\n\n return functional_class === 5 && low_mobility === 1;\n}\n" } },
|
|
24678
|
+
cameras:{ camera1:{ type:"perspective",
|
|
24679
|
+
vanishing_point:[ 0,
|
|
24680
|
+
-500 ] } },
|
|
24681
|
+
textures:{ arrow:{ url:"https://dalganmap.ru/api-image/images/arrow-20.png",
|
|
24682
|
+
sprites:{ base:[ 0,
|
|
24683
|
+
0,
|
|
24684
|
+
20,
|
|
24685
|
+
20 ] } },
|
|
24686
|
+
"traffic-signal":{ url:"https://dalganmap.ru/api-image/images/conditions/traffic-signal.png",
|
|
24687
|
+
filtering:"mipmap",
|
|
24688
|
+
sprites:{ base:[ 0,
|
|
24689
|
+
0,
|
|
24690
|
+
20,
|
|
24691
|
+
20 ] } },
|
|
24692
|
+
pedestrian_crossing:{ url:"https://dalganmap.ru/api-image/images/conditions/pedestrian_crossing.png",
|
|
24693
|
+
filtering:"mipmap",
|
|
24694
|
+
sprites:{ base:[ 0,
|
|
24695
|
+
0,
|
|
24696
|
+
20,
|
|
24697
|
+
20 ] } },
|
|
24698
|
+
physical:{ url:"https://dalganmap.ru/api-image/images/conditions/physical.png",
|
|
24699
|
+
filtering:"mipmap",
|
|
24700
|
+
sprites:{ base:[ 0,
|
|
24701
|
+
0,
|
|
24702
|
+
20,
|
|
24703
|
+
20 ] } },
|
|
24704
|
+
gate:{ url:"https://dalganmap.ru/api-image/images/conditions/gate.png",
|
|
24705
|
+
filtering:"mipmap",
|
|
24706
|
+
sprites:{ base:[ 0,
|
|
24707
|
+
0,
|
|
24708
|
+
20,
|
|
24709
|
+
20 ] } },
|
|
24710
|
+
POI_3578:{ url:"https://dalganmap.ru/api-image/images/POI/3578.png",
|
|
24711
|
+
filtering:"mipmap",
|
|
24712
|
+
sprites:{ base:[ 0,
|
|
24713
|
+
0,
|
|
24714
|
+
20,
|
|
24715
|
+
20 ] } },
|
|
24716
|
+
POI_5813:{ url:"https://dalganmap.ru/api-image/images/POI/5813.png",
|
|
24717
|
+
filtering:"mipmap",
|
|
24718
|
+
sprites:{ base:[ 0,
|
|
24719
|
+
0,
|
|
24720
|
+
20,
|
|
24721
|
+
20 ] } },
|
|
24722
|
+
POI_5541:{ url:"https://dalganmap.ru/api-image/images/POI/5541.png",
|
|
24723
|
+
filtering:"mipmap",
|
|
24724
|
+
sprites:{ base:[ 0,
|
|
24725
|
+
0,
|
|
24726
|
+
20,
|
|
24727
|
+
20 ] } },
|
|
24728
|
+
POI_5540:{ url:"https://dalganmap.ru/api-image/images/POI/5540.png",
|
|
24729
|
+
filtering:"mipmap",
|
|
24730
|
+
sprites:{ base:[ 0,
|
|
24731
|
+
0,
|
|
24732
|
+
20,
|
|
24733
|
+
20 ] } },
|
|
24734
|
+
"POI_9530(Mail)":{ url:"https://dalganmap.ru/api-image/images/POI/mail.png",
|
|
24735
|
+
filtering:"mipmap",
|
|
24736
|
+
sprites:{ base:[ 0,
|
|
24737
|
+
0,
|
|
24738
|
+
20,
|
|
24739
|
+
20 ] } },
|
|
24740
|
+
"POI_9530(Delivery)":{ url:"https://dalganmap.ru/api-image/images/POI/delivery.png",
|
|
24741
|
+
filtering:"mipmap",
|
|
24742
|
+
sprites:{ base:[ 0,
|
|
24743
|
+
0,
|
|
24744
|
+
20,
|
|
24745
|
+
20 ] } },
|
|
24746
|
+
POI_5400:{ url:"https://dalganmap.ru/api-image/images/POI/5400.png",
|
|
24747
|
+
filtering:"mipmap",
|
|
24748
|
+
sprites:{ base:[ 0,
|
|
24749
|
+
0,
|
|
24750
|
+
20,
|
|
24751
|
+
20 ] } },
|
|
24752
|
+
POI_6000:{ url:"https://dalganmap.ru/api-image/images/POI/6000.png",
|
|
24753
|
+
filtering:"mipmap",
|
|
24754
|
+
sprites:{ base:[ 0,
|
|
24755
|
+
0,
|
|
24756
|
+
20,
|
|
24757
|
+
20 ] } },
|
|
24758
|
+
POI_9565:{ url:"https://dalganmap.ru/api-image/images/POI/9565.png",
|
|
24759
|
+
filtering:"mipmap",
|
|
24760
|
+
sprites:{ base:[ 0,
|
|
24761
|
+
0,
|
|
24762
|
+
20,
|
|
24763
|
+
20 ] } },
|
|
24764
|
+
POI_9583:{ url:"https://dalganmap.ru/api-image/images/POI/9583.png",
|
|
24765
|
+
filtering:"mipmap",
|
|
24766
|
+
sprites:{ base:[ 0,
|
|
24767
|
+
0,
|
|
24768
|
+
20,
|
|
24769
|
+
20 ] } },
|
|
24770
|
+
POI_8060:{ url:"https://dalganmap.ru/api-image/images/POI/8060.png",
|
|
24771
|
+
filtering:"mipmap",
|
|
24772
|
+
sprites:{ base:[ 0,
|
|
24773
|
+
0,
|
|
24774
|
+
20,
|
|
24775
|
+
20 ] } },
|
|
24776
|
+
POI_5511:{ url:"https://dalganmap.ru/api-image/images/POI/5511.png",
|
|
24777
|
+
filtering:"mipmap",
|
|
24778
|
+
sprites:{ base:[ 0,
|
|
24779
|
+
0,
|
|
24780
|
+
20,
|
|
24781
|
+
20 ] } },
|
|
24782
|
+
POI_5512:{ url:"https://dalganmap.ru/api-image/images/POI/5512.png",
|
|
24783
|
+
filtering:"mipmap",
|
|
24784
|
+
sprites:{ base:[ 0,
|
|
24785
|
+
0,
|
|
24786
|
+
20,
|
|
24787
|
+
20 ] } },
|
|
24788
|
+
POI_5800:{ url:"https://dalganmap.ru/api-image/images/POI/5800.png",
|
|
24789
|
+
filtering:"mipmap",
|
|
24790
|
+
sprites:{ base:[ 0,
|
|
24791
|
+
0,
|
|
24792
|
+
20,
|
|
24793
|
+
20 ] } },
|
|
24794
|
+
POI_5999:{ url:"https://dalganmap.ru/api-image/images/POI/5999.png",
|
|
24795
|
+
filtering:"mipmap",
|
|
24796
|
+
sprites:{ base:[ 0,
|
|
24797
|
+
0,
|
|
24798
|
+
20,
|
|
24799
|
+
20 ] } },
|
|
24800
|
+
POI_7011:{ url:"https://dalganmap.ru/api-image/images/POI/7011.png",
|
|
24801
|
+
filtering:"mipmap",
|
|
24802
|
+
sprites:{ base:[ 0,
|
|
24803
|
+
0,
|
|
24804
|
+
20,
|
|
24805
|
+
20 ] } },
|
|
24806
|
+
POI_7389:{ url:"https://dalganmap.ru/api-image/images/POI/7389.png",
|
|
24807
|
+
filtering:"mipmap",
|
|
24808
|
+
sprites:{ base:[ 0,
|
|
24809
|
+
0,
|
|
24810
|
+
20,
|
|
24811
|
+
20 ] } },
|
|
24812
|
+
POI_7832:{ url:"https://dalganmap.ru/api-image/images/POI/7832.png",
|
|
24813
|
+
filtering:"mipmap",
|
|
24814
|
+
sprites:{ base:[ 0,
|
|
24815
|
+
0,
|
|
24816
|
+
20,
|
|
24817
|
+
20 ] } },
|
|
24818
|
+
POI_7929:{ url:"https://dalganmap.ru/api-image/images/POI/7929.png",
|
|
24819
|
+
filtering:"mipmap",
|
|
24820
|
+
sprites:{ base:[ 0,
|
|
24821
|
+
0,
|
|
24822
|
+
20,
|
|
24823
|
+
20 ] } },
|
|
24824
|
+
POI_7990:{ url:"https://dalganmap.ru/api-image/images/POI/7990.png",
|
|
24825
|
+
filtering:"mipmap",
|
|
24826
|
+
sprites:{ base:[ 0,
|
|
24827
|
+
0,
|
|
24828
|
+
20,
|
|
24829
|
+
20 ] } },
|
|
24830
|
+
POI_7999:{ url:"https://dalganmap.ru/api-image/images/POI/7999.png",
|
|
24831
|
+
filtering:"mipmap",
|
|
24832
|
+
sprites:{ base:[ 0,
|
|
24833
|
+
0,
|
|
24834
|
+
20,
|
|
24835
|
+
20 ] } },
|
|
24836
|
+
POI_8410:{ url:"https://dalganmap.ru/api-image/images/POI/8410.png",
|
|
24837
|
+
filtering:"mipmap",
|
|
24838
|
+
sprites:{ base:[ 0,
|
|
24839
|
+
0,
|
|
24840
|
+
20,
|
|
24841
|
+
20 ] } },
|
|
24842
|
+
POI_9517:{ url:"https://dalganmap.ru/api-image/images/POI/9517.png",
|
|
24843
|
+
filtering:"mipmap",
|
|
24844
|
+
sprites:{ base:[ 0,
|
|
24845
|
+
0,
|
|
24846
|
+
20,
|
|
24847
|
+
20 ] } },
|
|
24848
|
+
POI_9718:{ url:"https://dalganmap.ru/api-image/images/POI/9718.png",
|
|
24849
|
+
filtering:"mipmap",
|
|
24850
|
+
sprites:{ base:[ 0,
|
|
24851
|
+
0,
|
|
24852
|
+
20,
|
|
24853
|
+
20 ] } },
|
|
24854
|
+
"POI_9992(mosque)":{ url:"https://dalganmap.ru/api-image/images/POI/9992_mosque.png",
|
|
24855
|
+
filtering:"mipmap",
|
|
24856
|
+
sprites:{ base:[ 0,
|
|
24857
|
+
0,
|
|
24858
|
+
20,
|
|
24859
|
+
20 ] } },
|
|
24860
|
+
"POI_9992(church)":{ url:"https://dalganmap.ru/api-image/images/POI/9992_church.png",
|
|
24861
|
+
filtering:"mipmap",
|
|
24862
|
+
sprites:{ base:[ 0,
|
|
24863
|
+
0,
|
|
24864
|
+
20,
|
|
24865
|
+
20 ] } },
|
|
24866
|
+
"POI_9992(temple)":{ url:"https://dalganmap.ru/api-image/images/POI/9992_temple.png",
|
|
24867
|
+
filtering:"mipmap",
|
|
24868
|
+
sprites:{ base:[ 0,
|
|
24869
|
+
0,
|
|
24870
|
+
20,
|
|
24871
|
+
20 ] } },
|
|
24872
|
+
"POI_9992(davidStar)":{ url:"https://dalganmap.ru/api-image/images/POI/9992_davidStar.png",
|
|
24873
|
+
filtering:"mipmap",
|
|
24874
|
+
sprites:{ base:[ 0,
|
|
24875
|
+
0,
|
|
24876
|
+
20,
|
|
24877
|
+
20 ] } },
|
|
24878
|
+
"POI_9992(mortar)":{ url:"https://dalganmap.ru/api-image/images/POI/9992_mortar.png",
|
|
24879
|
+
filtering:"mipmap",
|
|
24880
|
+
sprites:{ base:[ 0,
|
|
24881
|
+
0,
|
|
24882
|
+
20,
|
|
24883
|
+
20 ] } },
|
|
24884
|
+
"POI_4100(metro)":{ url:"https://dalganmap.ru/api-image/images/POI/4100_metro.png",
|
|
24885
|
+
filtering:"mipmap",
|
|
24886
|
+
sprites:{ base:[ 0,
|
|
24887
|
+
0,
|
|
24888
|
+
20,
|
|
24889
|
+
20 ] } },
|
|
24890
|
+
"POI_4100(diameter)":{ url:"https://dalganmap.ru/api-image/images/POI/4100_diameter.png",
|
|
24891
|
+
filtering:"mipmap",
|
|
24892
|
+
sprites:{ base:[ 0,
|
|
24893
|
+
0,
|
|
24894
|
+
41,
|
|
24895
|
+
15 ] } },
|
|
24896
|
+
POI_4013:{ url:"https://dalganmap.ru/api-image/images/POI/4013.png",
|
|
24897
|
+
filtering:"mipmap",
|
|
24898
|
+
sprites:{ base:[ 0,
|
|
24899
|
+
0,
|
|
24900
|
+
20,
|
|
24901
|
+
20 ] } } },
|
|
24902
|
+
layers:null,
|
|
24903
|
+
styles:{ buildings:{ base:"polygons",
|
|
24904
|
+
shaders:{ blocks:{ color:"color.rgb;\n" } } } },
|
|
24905
|
+
lights:{ light1:{ type:"directional",
|
|
24906
|
+
direction:[ 0.1,
|
|
24907
|
+
0.5,
|
|
24908
|
+
-1 ],
|
|
24909
|
+
diffuse:0.7,
|
|
24910
|
+
ambient:0.5 } },
|
|
24911
|
+
sources:null };
|
|
24912
|
+
data.global;
|
|
24913
|
+
data.cameras;
|
|
24914
|
+
data.textures;
|
|
24915
|
+
data.layers;
|
|
24916
|
+
data.styles;
|
|
24917
|
+
data.lights;
|
|
24918
|
+
data.sources;
|
|
24919
|
+
|
|
24920
|
+
const getBuildingLayers = (source) => {
|
|
24669
24921
|
const layers = [];
|
|
24670
24922
|
const data = {
|
|
24671
24923
|
source,
|
|
24672
|
-
layer: exports.SourceLayers.
|
|
24924
|
+
layer: exports.SourceLayers.BUILDING_AREA,
|
|
24925
|
+
minzoom: 15,
|
|
24673
24926
|
};
|
|
24674
|
-
const
|
|
24675
|
-
id: getUniqueKey(),
|
|
24676
|
-
data,
|
|
24677
|
-
filter: `function() {
|
|
24678
|
-
const { type } = feature;
|
|
24679
|
-
|
|
24680
|
-
const isFilter = type === 'Road';
|
|
24681
|
-
|
|
24682
|
-
return isFilter;
|
|
24683
|
-
}`,
|
|
24684
|
-
draw: {
|
|
24685
|
-
polygons: {
|
|
24686
|
-
color: '#BABCC2',
|
|
24687
|
-
},
|
|
24688
|
-
},
|
|
24689
|
-
};
|
|
24690
|
-
const tramLayer = {
|
|
24691
|
-
id: getUniqueKey(),
|
|
24692
|
-
data,
|
|
24693
|
-
filter: `function() {
|
|
24694
|
-
const { type } = feature;
|
|
24695
|
-
|
|
24696
|
-
const isFilter = type === 'Tram';
|
|
24697
|
-
|
|
24698
|
-
return isFilter;
|
|
24699
|
-
}`,
|
|
24700
|
-
draw: {
|
|
24701
|
-
polygons: {
|
|
24702
|
-
color: '#ADA8A8',
|
|
24703
|
-
},
|
|
24704
|
-
},
|
|
24705
|
-
};
|
|
24706
|
-
const curbLayer = {
|
|
24707
|
-
id: getUniqueKey(),
|
|
24708
|
-
data,
|
|
24709
|
-
filter: `function() {
|
|
24710
|
-
const { type } = feature;
|
|
24711
|
-
|
|
24712
|
-
const isFilter = type === 'Curb';
|
|
24713
|
-
|
|
24714
|
-
return isFilter;
|
|
24715
|
-
}`,
|
|
24716
|
-
draw: {
|
|
24717
|
-
polygons: {
|
|
24718
|
-
color: '#D2D9E6',
|
|
24719
|
-
},
|
|
24720
|
-
},
|
|
24721
|
-
};
|
|
24722
|
-
const bridgeLayer = {
|
|
24723
|
-
id: getUniqueKey(),
|
|
24724
|
-
data,
|
|
24725
|
-
filter: `function() {
|
|
24726
|
-
const { type } = feature;
|
|
24727
|
-
|
|
24728
|
-
const isFilter = type === 'Bridge';
|
|
24729
|
-
|
|
24730
|
-
return isFilter;
|
|
24731
|
-
}`,
|
|
24732
|
-
draw: {
|
|
24733
|
-
polygons: {
|
|
24734
|
-
color: '#E1DFDD',
|
|
24735
|
-
},
|
|
24736
|
-
},
|
|
24737
|
-
};
|
|
24738
|
-
layers.push(roadLayer, tramLayer, curbLayer, bridgeLayer);
|
|
24739
|
-
return layers;
|
|
24740
|
-
};
|
|
24741
|
-
const getLaneMarkingPolyLayers = (source) => {
|
|
24742
|
-
const layers = [];
|
|
24743
|
-
const data = {
|
|
24744
|
-
source,
|
|
24745
|
-
layer: exports.SourceLayers.LINE_MARKING_POLY,
|
|
24746
|
-
};
|
|
24747
|
-
const layer__1_14_1 = {
|
|
24748
|
-
id: getUniqueKey(),
|
|
24749
|
-
data,
|
|
24750
|
-
filter: `function() {
|
|
24751
|
-
const { poly_number } = feature;
|
|
24752
|
-
|
|
24753
|
-
const isFilter = poly_number === '1.14.1';
|
|
24754
|
-
|
|
24755
|
-
return isFilter;
|
|
24756
|
-
}`,
|
|
24757
|
-
draw: {
|
|
24758
|
-
styles: {
|
|
24759
|
-
zebra_crossing: {
|
|
24760
|
-
attributes: {
|
|
24761
|
-
a_angle: `function() {
|
|
24762
|
-
return feature.angle;
|
|
24763
|
-
}`,
|
|
24764
|
-
},
|
|
24765
|
-
},
|
|
24766
|
-
},
|
|
24767
|
-
},
|
|
24768
|
-
};
|
|
24769
|
-
const layer__1_18 = {
|
|
24770
|
-
id: getUniqueKey(),
|
|
24771
|
-
data,
|
|
24772
|
-
filter: `function() {
|
|
24773
|
-
const { poly_number } = feature;
|
|
24774
|
-
|
|
24775
|
-
const isFilter = poly_number === '1.18';
|
|
24776
|
-
|
|
24777
|
-
return isFilter;
|
|
24778
|
-
}`,
|
|
24779
|
-
draw: {
|
|
24780
|
-
polygons: {
|
|
24781
|
-
color: 'white',
|
|
24782
|
-
},
|
|
24783
|
-
},
|
|
24784
|
-
};
|
|
24785
|
-
layers.push(layer__1_18, layer__1_14_1);
|
|
24786
|
-
return layers;
|
|
24787
|
-
};
|
|
24788
|
-
const getLaneMarkingLineLayers = (source) => {
|
|
24789
|
-
const layers = [];
|
|
24790
|
-
const data = {
|
|
24791
|
-
source,
|
|
24792
|
-
layer: exports.SourceLayers.LINE_MARKING_LINE,
|
|
24793
|
-
};
|
|
24794
|
-
const color = 'white';
|
|
24795
|
-
const width = 0.5;
|
|
24796
|
-
const singleLayer = {
|
|
24797
|
-
id: getUniqueKey(),
|
|
24798
|
-
data,
|
|
24799
|
-
sublayers: {
|
|
24800
|
-
'1.1': {
|
|
24801
|
-
filter: `function () {
|
|
24802
|
-
const { lane_number } = feature;
|
|
24803
|
-
|
|
24804
|
-
const isFilter = lane_number === '1.1';
|
|
24805
|
-
|
|
24806
|
-
return isFilter;
|
|
24807
|
-
}`,
|
|
24808
|
-
draw: {
|
|
24809
|
-
lines: {
|
|
24810
|
-
color,
|
|
24811
|
-
width,
|
|
24812
|
-
},
|
|
24813
|
-
},
|
|
24814
|
-
},
|
|
24815
|
-
'1.5': {
|
|
24816
|
-
filter: `function () {
|
|
24817
|
-
const { lane_number } = feature;
|
|
24818
|
-
|
|
24819
|
-
const isFilter = lane_number === '1.5';
|
|
24820
|
-
|
|
24821
|
-
return isFilter;
|
|
24822
|
-
}`,
|
|
24823
|
-
draw: {
|
|
24824
|
-
lines: {
|
|
24825
|
-
color,
|
|
24826
|
-
width,
|
|
24827
|
-
dash: [4, 10],
|
|
24828
|
-
},
|
|
24829
|
-
},
|
|
24830
|
-
},
|
|
24831
|
-
'1.6': {
|
|
24832
|
-
filter: `function () {
|
|
24833
|
-
const { lane_number } = feature;
|
|
24834
|
-
|
|
24835
|
-
const isFilter = lane_number === '1.6';
|
|
24836
|
-
|
|
24837
|
-
return isFilter;
|
|
24838
|
-
}`,
|
|
24839
|
-
draw: {
|
|
24840
|
-
lines: {
|
|
24841
|
-
color,
|
|
24842
|
-
width,
|
|
24843
|
-
dash: [5, 5],
|
|
24844
|
-
},
|
|
24845
|
-
},
|
|
24846
|
-
},
|
|
24847
|
-
'1.16.1': {
|
|
24848
|
-
filter: `function () {
|
|
24849
|
-
const { lane_number } = feature;
|
|
24850
|
-
|
|
24851
|
-
const isFilter = lane_number === '1.16.1';
|
|
24852
|
-
|
|
24853
|
-
return isFilter;
|
|
24854
|
-
}`,
|
|
24855
|
-
draw: {
|
|
24856
|
-
lines: {
|
|
24857
|
-
color,
|
|
24858
|
-
width,
|
|
24859
|
-
},
|
|
24860
|
-
},
|
|
24861
|
-
},
|
|
24862
|
-
'1.7': {
|
|
24863
|
-
filter: `function () {
|
|
24864
|
-
const { lane_number } = feature;
|
|
24865
|
-
|
|
24866
|
-
const isFilter = lane_number === '1.7';
|
|
24867
|
-
|
|
24868
|
-
return isFilter;
|
|
24869
|
-
}`,
|
|
24870
|
-
draw: {
|
|
24871
|
-
lines: {
|
|
24872
|
-
color,
|
|
24873
|
-
width,
|
|
24874
|
-
dash: [4, 10],
|
|
24875
|
-
},
|
|
24876
|
-
},
|
|
24877
|
-
},
|
|
24878
|
-
'1.7-blue': {
|
|
24879
|
-
filter: `function () {
|
|
24880
|
-
const { lane_number } = feature;
|
|
24881
|
-
|
|
24882
|
-
const isFilter = lane_number === '1.7blue';
|
|
24883
|
-
|
|
24884
|
-
return isFilter;
|
|
24885
|
-
}`,
|
|
24886
|
-
draw: {
|
|
24887
|
-
lines: {
|
|
24888
|
-
color: 'blue',
|
|
24889
|
-
width,
|
|
24890
|
-
dash: [4, 10],
|
|
24891
|
-
},
|
|
24892
|
-
},
|
|
24893
|
-
},
|
|
24894
|
-
'1.14.3': {
|
|
24895
|
-
filter: `function () {
|
|
24896
|
-
const { lane_number } = feature;
|
|
24897
|
-
|
|
24898
|
-
const isFilter = lane_number === '1.14.3';
|
|
24899
|
-
|
|
24900
|
-
return isFilter;
|
|
24901
|
-
}`,
|
|
24902
|
-
draw: {
|
|
24903
|
-
lines: {
|
|
24904
|
-
color,
|
|
24905
|
-
width,
|
|
24906
|
-
dash: [3, 8],
|
|
24907
|
-
},
|
|
24908
|
-
},
|
|
24909
|
-
},
|
|
24910
|
-
'1.12': {
|
|
24911
|
-
filter: `function () {
|
|
24912
|
-
const { lane_number } = feature;
|
|
24913
|
-
|
|
24914
|
-
const isFilter = lane_number === '1.12';
|
|
24915
|
-
|
|
24916
|
-
return isFilter;
|
|
24917
|
-
}`,
|
|
24918
|
-
draw: {
|
|
24919
|
-
lines: {
|
|
24920
|
-
color,
|
|
24921
|
-
width: 1.5,
|
|
24922
|
-
},
|
|
24923
|
-
},
|
|
24924
|
-
},
|
|
24925
|
-
'1.17.1': {
|
|
24926
|
-
filter: `function () {
|
|
24927
|
-
const { lane_number } = feature;
|
|
24928
|
-
|
|
24929
|
-
const isFilter = lane_number === '1.17.1';
|
|
24930
|
-
|
|
24931
|
-
return isFilter;
|
|
24932
|
-
}`,
|
|
24933
|
-
draw: {
|
|
24934
|
-
lines: {
|
|
24935
|
-
color: 'yellow',
|
|
24936
|
-
width,
|
|
24937
|
-
},
|
|
24938
|
-
},
|
|
24939
|
-
},
|
|
24940
|
-
'1.26': {
|
|
24941
|
-
filter: `function () {
|
|
24942
|
-
const { lane_number } = feature;
|
|
24943
|
-
|
|
24944
|
-
const isFilter = lane_number === '1.26';
|
|
24945
|
-
|
|
24946
|
-
return isFilter;
|
|
24947
|
-
}`,
|
|
24948
|
-
draw: {
|
|
24949
|
-
lines: {
|
|
24950
|
-
color: 'yellow',
|
|
24951
|
-
width,
|
|
24952
|
-
},
|
|
24953
|
-
},
|
|
24954
|
-
},
|
|
24955
|
-
},
|
|
24956
|
-
};
|
|
24957
|
-
const doubleLayers = {
|
|
24958
|
-
'1.3-left': {
|
|
24959
|
-
id: getUniqueKey(),
|
|
24960
|
-
data,
|
|
24961
|
-
filter: `function() {
|
|
24962
|
-
const { lane_number } = feature;
|
|
24963
|
-
|
|
24964
|
-
const isFilter = lane_number === '1.3';
|
|
24965
|
-
|
|
24966
|
-
return isFilter;
|
|
24967
|
-
}`,
|
|
24968
|
-
draw: {
|
|
24969
|
-
lines: {
|
|
24970
|
-
color,
|
|
24971
|
-
width,
|
|
24972
|
-
offset: -width,
|
|
24973
|
-
},
|
|
24974
|
-
},
|
|
24975
|
-
},
|
|
24976
|
-
'1.3-right': {
|
|
24977
|
-
id: getUniqueKey(),
|
|
24978
|
-
data,
|
|
24979
|
-
filter: `function() {
|
|
24980
|
-
const { lane_number } = feature;
|
|
24981
|
-
|
|
24982
|
-
const isFilter = lane_number === '1.3';
|
|
24983
|
-
|
|
24984
|
-
return isFilter;
|
|
24985
|
-
}`,
|
|
24986
|
-
draw: {
|
|
24987
|
-
lines: {
|
|
24988
|
-
color,
|
|
24989
|
-
width,
|
|
24990
|
-
offset: width,
|
|
24991
|
-
},
|
|
24992
|
-
},
|
|
24993
|
-
},
|
|
24994
|
-
'1.11r-left': {
|
|
24995
|
-
id: getUniqueKey(),
|
|
24996
|
-
data,
|
|
24997
|
-
filter: `function() {
|
|
24998
|
-
const { lane_number } = feature;
|
|
24999
|
-
|
|
25000
|
-
const isFilter = lane_number === '1.11r';
|
|
25001
|
-
|
|
25002
|
-
return isFilter;
|
|
25003
|
-
}`,
|
|
25004
|
-
draw: {
|
|
25005
|
-
lines: {
|
|
25006
|
-
color,
|
|
25007
|
-
width,
|
|
25008
|
-
offset: -width,
|
|
25009
|
-
},
|
|
25010
|
-
},
|
|
25011
|
-
},
|
|
25012
|
-
'1.11r-right': {
|
|
25013
|
-
id: getUniqueKey(),
|
|
25014
|
-
data,
|
|
25015
|
-
filter: `function() {
|
|
25016
|
-
const { lane_number } = feature;
|
|
25017
|
-
|
|
25018
|
-
const isFilter = lane_number === '1.11r';
|
|
25019
|
-
|
|
25020
|
-
return isFilter;
|
|
25021
|
-
}`,
|
|
25022
|
-
draw: {
|
|
25023
|
-
lines: {
|
|
25024
|
-
color,
|
|
25025
|
-
width,
|
|
25026
|
-
offset: width,
|
|
25027
|
-
dash: [5, 5],
|
|
25028
|
-
},
|
|
25029
|
-
},
|
|
25030
|
-
},
|
|
25031
|
-
'1.11l-left': {
|
|
25032
|
-
id: getUniqueKey(),
|
|
25033
|
-
data,
|
|
25034
|
-
filter: `function() {
|
|
25035
|
-
const { lane_number } = feature;
|
|
25036
|
-
|
|
25037
|
-
const isFilter = lane_number === '1.11l';
|
|
25038
|
-
|
|
25039
|
-
return isFilter;
|
|
25040
|
-
}`,
|
|
25041
|
-
draw: {
|
|
25042
|
-
lines: {
|
|
25043
|
-
color,
|
|
25044
|
-
width,
|
|
25045
|
-
offset: -width,
|
|
25046
|
-
dash: [5, 5],
|
|
25047
|
-
},
|
|
25048
|
-
},
|
|
25049
|
-
},
|
|
25050
|
-
'1.11l-right': {
|
|
25051
|
-
id: getUniqueKey(),
|
|
25052
|
-
data,
|
|
25053
|
-
filter: `function() {
|
|
25054
|
-
const { lane_number } = feature;
|
|
25055
|
-
|
|
25056
|
-
const isFilter = lane_number === '1.11l';
|
|
25057
|
-
|
|
25058
|
-
return isFilter;
|
|
25059
|
-
}`,
|
|
25060
|
-
draw: {
|
|
25061
|
-
lines: {
|
|
25062
|
-
color,
|
|
25063
|
-
width,
|
|
25064
|
-
offset: width,
|
|
25065
|
-
},
|
|
25066
|
-
},
|
|
25067
|
-
},
|
|
25068
|
-
'1.25-left': {
|
|
25069
|
-
id: getUniqueKey(),
|
|
25070
|
-
data,
|
|
25071
|
-
filter: `function() {
|
|
25072
|
-
const { lane_number } = feature;
|
|
25073
|
-
|
|
25074
|
-
const isFilter = lane_number === '1.25';
|
|
25075
|
-
|
|
25076
|
-
return isFilter;
|
|
25077
|
-
}`,
|
|
25078
|
-
draw: {
|
|
25079
|
-
lines: {
|
|
25080
|
-
color,
|
|
25081
|
-
width: 1,
|
|
25082
|
-
offset: -0.5,
|
|
25083
|
-
dash: [1, 1],
|
|
25084
|
-
dash_background_color: [0.0, 0.0, 0.0, 0.0],
|
|
25085
|
-
},
|
|
25086
|
-
},
|
|
25087
|
-
},
|
|
25088
|
-
'1.25-right': {
|
|
25089
|
-
id: getUniqueKey(),
|
|
25090
|
-
data,
|
|
25091
|
-
filter: `function() {
|
|
25092
|
-
const { lane_number } = feature;
|
|
25093
|
-
|
|
25094
|
-
const isFilter = lane_number === '1.25';
|
|
25095
|
-
|
|
25096
|
-
return isFilter;
|
|
25097
|
-
}`,
|
|
25098
|
-
draw: {
|
|
25099
|
-
lines: {
|
|
25100
|
-
color: 'rgba(0,0,0,0)',
|
|
25101
|
-
width: 1,
|
|
25102
|
-
offset: 1 / 2,
|
|
25103
|
-
dash: [1, 1],
|
|
25104
|
-
dash_background_color: [1.0, 1.0, 1.0],
|
|
25105
|
-
},
|
|
25106
|
-
},
|
|
25107
|
-
},
|
|
25108
|
-
};
|
|
25109
|
-
layers.push(singleLayer, ...Object.values(doubleLayers));
|
|
25110
|
-
return layers;
|
|
25111
|
-
};
|
|
25112
|
-
const getParkingLineLayers = (source) => {
|
|
25113
|
-
const layers = [];
|
|
25114
|
-
const data = {
|
|
25115
|
-
source,
|
|
25116
|
-
layer: exports.SourceLayers.PARKING_LINE,
|
|
25117
|
-
};
|
|
25118
|
-
const layer = {
|
|
25119
|
-
id: getUniqueKey(),
|
|
25120
|
-
data,
|
|
25121
|
-
draw: {
|
|
25122
|
-
lines: {
|
|
25123
|
-
color: 'white',
|
|
25124
|
-
width: 1,
|
|
25125
|
-
},
|
|
25126
|
-
},
|
|
25127
|
-
};
|
|
25128
|
-
layers.push(layer);
|
|
25129
|
-
return layers;
|
|
25130
|
-
};
|
|
25131
|
-
|
|
25132
|
-
var data = { global:{ links:{ getIsConstruction:"function (feature) {\n const { construction } = feature;\n\n return construction;\n}\n",
|
|
25133
|
-
getIsFunctionalClass:"function (feature) {\n const { functional_class, access_id } = feature;\n\n return functional_class === 5 && access_id === 32;\n}\n",
|
|
25134
|
-
getIsLowMobility:"function (feature) {\n const { functional_class, low_mobility } = feature;\n\n return functional_class === 5 && low_mobility === 1;\n}\n" } },
|
|
25135
|
-
cameras:{ camera1:{ type:"perspective",
|
|
25136
|
-
vanishing_point:[ 0,
|
|
25137
|
-
-500 ] } },
|
|
25138
|
-
textures:{ arrow:{ url:"https://dalganmap.ru/api-image/images/arrow-20.png",
|
|
25139
|
-
sprites:{ base:[ 0,
|
|
25140
|
-
0,
|
|
25141
|
-
20,
|
|
25142
|
-
20 ] } },
|
|
25143
|
-
"traffic-signal":{ url:"https://dalganmap.ru/api-image/images/conditions/traffic-signal.png",
|
|
25144
|
-
filtering:"mipmap",
|
|
25145
|
-
sprites:{ base:[ 0,
|
|
25146
|
-
0,
|
|
25147
|
-
20,
|
|
25148
|
-
20 ] } },
|
|
25149
|
-
pedestrian_crossing:{ url:"https://dalganmap.ru/api-image/images/conditions/pedestrian_crossing.png",
|
|
25150
|
-
filtering:"mipmap",
|
|
25151
|
-
sprites:{ base:[ 0,
|
|
25152
|
-
0,
|
|
25153
|
-
20,
|
|
25154
|
-
20 ] } },
|
|
25155
|
-
physical:{ url:"https://dalganmap.ru/api-image/images/conditions/physical.png",
|
|
25156
|
-
filtering:"mipmap",
|
|
25157
|
-
sprites:{ base:[ 0,
|
|
25158
|
-
0,
|
|
25159
|
-
20,
|
|
25160
|
-
20 ] } },
|
|
25161
|
-
gate:{ url:"https://dalganmap.ru/api-image/images/conditions/gate.png",
|
|
25162
|
-
filtering:"mipmap",
|
|
25163
|
-
sprites:{ base:[ 0,
|
|
25164
|
-
0,
|
|
25165
|
-
20,
|
|
25166
|
-
20 ] } },
|
|
25167
|
-
POI_3578:{ url:"https://dalganmap.ru/api-image/images/POI/3578.png",
|
|
25168
|
-
filtering:"mipmap",
|
|
25169
|
-
sprites:{ base:[ 0,
|
|
25170
|
-
0,
|
|
25171
|
-
20,
|
|
25172
|
-
20 ] } },
|
|
25173
|
-
POI_5813:{ url:"https://dalganmap.ru/api-image/images/POI/5813.png",
|
|
25174
|
-
filtering:"mipmap",
|
|
25175
|
-
sprites:{ base:[ 0,
|
|
25176
|
-
0,
|
|
25177
|
-
20,
|
|
25178
|
-
20 ] } },
|
|
25179
|
-
POI_5541:{ url:"https://dalganmap.ru/api-image/images/POI/5541.png",
|
|
25180
|
-
filtering:"mipmap",
|
|
25181
|
-
sprites:{ base:[ 0,
|
|
25182
|
-
0,
|
|
25183
|
-
20,
|
|
25184
|
-
20 ] } },
|
|
25185
|
-
POI_5540:{ url:"https://dalganmap.ru/api-image/images/POI/5540.png",
|
|
25186
|
-
filtering:"mipmap",
|
|
25187
|
-
sprites:{ base:[ 0,
|
|
25188
|
-
0,
|
|
25189
|
-
20,
|
|
25190
|
-
20 ] } },
|
|
25191
|
-
"POI_9530(Mail)":{ url:"https://dalganmap.ru/api-image/images/POI/mail.png",
|
|
25192
|
-
filtering:"mipmap",
|
|
25193
|
-
sprites:{ base:[ 0,
|
|
25194
|
-
0,
|
|
25195
|
-
20,
|
|
25196
|
-
20 ] } },
|
|
25197
|
-
"POI_9530(Delivery)":{ url:"https://dalganmap.ru/api-image/images/POI/delivery.png",
|
|
25198
|
-
filtering:"mipmap",
|
|
25199
|
-
sprites:{ base:[ 0,
|
|
25200
|
-
0,
|
|
25201
|
-
20,
|
|
25202
|
-
20 ] } },
|
|
25203
|
-
POI_5400:{ url:"https://dalganmap.ru/api-image/images/POI/5400.png",
|
|
25204
|
-
filtering:"mipmap",
|
|
25205
|
-
sprites:{ base:[ 0,
|
|
25206
|
-
0,
|
|
25207
|
-
20,
|
|
25208
|
-
20 ] } },
|
|
25209
|
-
POI_6000:{ url:"https://dalganmap.ru/api-image/images/POI/6000.png",
|
|
25210
|
-
filtering:"mipmap",
|
|
25211
|
-
sprites:{ base:[ 0,
|
|
25212
|
-
0,
|
|
25213
|
-
20,
|
|
25214
|
-
20 ] } },
|
|
25215
|
-
POI_9565:{ url:"https://dalganmap.ru/api-image/images/POI/9565.png",
|
|
25216
|
-
filtering:"mipmap",
|
|
25217
|
-
sprites:{ base:[ 0,
|
|
25218
|
-
0,
|
|
25219
|
-
20,
|
|
25220
|
-
20 ] } },
|
|
25221
|
-
POI_9583:{ url:"https://dalganmap.ru/api-image/images/POI/9583.png",
|
|
25222
|
-
filtering:"mipmap",
|
|
25223
|
-
sprites:{ base:[ 0,
|
|
25224
|
-
0,
|
|
25225
|
-
20,
|
|
25226
|
-
20 ] } },
|
|
25227
|
-
POI_8060:{ url:"https://dalganmap.ru/api-image/images/POI/8060.png",
|
|
25228
|
-
filtering:"mipmap",
|
|
25229
|
-
sprites:{ base:[ 0,
|
|
25230
|
-
0,
|
|
25231
|
-
20,
|
|
25232
|
-
20 ] } },
|
|
25233
|
-
POI_5511:{ url:"https://dalganmap.ru/api-image/images/POI/5511.png",
|
|
25234
|
-
filtering:"mipmap",
|
|
25235
|
-
sprites:{ base:[ 0,
|
|
25236
|
-
0,
|
|
25237
|
-
20,
|
|
25238
|
-
20 ] } },
|
|
25239
|
-
POI_5512:{ url:"https://dalganmap.ru/api-image/images/POI/5512.png",
|
|
25240
|
-
filtering:"mipmap",
|
|
25241
|
-
sprites:{ base:[ 0,
|
|
25242
|
-
0,
|
|
25243
|
-
20,
|
|
25244
|
-
20 ] } },
|
|
25245
|
-
POI_5800:{ url:"https://dalganmap.ru/api-image/images/POI/5800.png",
|
|
25246
|
-
filtering:"mipmap",
|
|
25247
|
-
sprites:{ base:[ 0,
|
|
25248
|
-
0,
|
|
25249
|
-
20,
|
|
25250
|
-
20 ] } },
|
|
25251
|
-
POI_5999:{ url:"https://dalganmap.ru/api-image/images/POI/5999.png",
|
|
25252
|
-
filtering:"mipmap",
|
|
25253
|
-
sprites:{ base:[ 0,
|
|
25254
|
-
0,
|
|
25255
|
-
20,
|
|
25256
|
-
20 ] } },
|
|
25257
|
-
POI_7011:{ url:"https://dalganmap.ru/api-image/images/POI/7011.png",
|
|
25258
|
-
filtering:"mipmap",
|
|
25259
|
-
sprites:{ base:[ 0,
|
|
25260
|
-
0,
|
|
25261
|
-
20,
|
|
25262
|
-
20 ] } },
|
|
25263
|
-
POI_7389:{ url:"https://dalganmap.ru/api-image/images/POI/7389.png",
|
|
25264
|
-
filtering:"mipmap",
|
|
25265
|
-
sprites:{ base:[ 0,
|
|
25266
|
-
0,
|
|
25267
|
-
20,
|
|
25268
|
-
20 ] } },
|
|
25269
|
-
POI_7832:{ url:"https://dalganmap.ru/api-image/images/POI/7832.png",
|
|
25270
|
-
filtering:"mipmap",
|
|
25271
|
-
sprites:{ base:[ 0,
|
|
25272
|
-
0,
|
|
25273
|
-
20,
|
|
25274
|
-
20 ] } },
|
|
25275
|
-
POI_7929:{ url:"https://dalganmap.ru/api-image/images/POI/7929.png",
|
|
25276
|
-
filtering:"mipmap",
|
|
25277
|
-
sprites:{ base:[ 0,
|
|
25278
|
-
0,
|
|
25279
|
-
20,
|
|
25280
|
-
20 ] } },
|
|
25281
|
-
POI_7990:{ url:"https://dalganmap.ru/api-image/images/POI/7990.png",
|
|
25282
|
-
filtering:"mipmap",
|
|
25283
|
-
sprites:{ base:[ 0,
|
|
25284
|
-
0,
|
|
25285
|
-
20,
|
|
25286
|
-
20 ] } },
|
|
25287
|
-
POI_7999:{ url:"https://dalganmap.ru/api-image/images/POI/7999.png",
|
|
25288
|
-
filtering:"mipmap",
|
|
25289
|
-
sprites:{ base:[ 0,
|
|
25290
|
-
0,
|
|
25291
|
-
20,
|
|
25292
|
-
20 ] } },
|
|
25293
|
-
POI_8410:{ url:"https://dalganmap.ru/api-image/images/POI/8410.png",
|
|
25294
|
-
filtering:"mipmap",
|
|
25295
|
-
sprites:{ base:[ 0,
|
|
25296
|
-
0,
|
|
25297
|
-
20,
|
|
25298
|
-
20 ] } },
|
|
25299
|
-
POI_9517:{ url:"https://dalganmap.ru/api-image/images/POI/9517.png",
|
|
25300
|
-
filtering:"mipmap",
|
|
25301
|
-
sprites:{ base:[ 0,
|
|
25302
|
-
0,
|
|
25303
|
-
20,
|
|
25304
|
-
20 ] } },
|
|
25305
|
-
POI_9718:{ url:"https://dalganmap.ru/api-image/images/POI/9718.png",
|
|
25306
|
-
filtering:"mipmap",
|
|
25307
|
-
sprites:{ base:[ 0,
|
|
25308
|
-
0,
|
|
25309
|
-
20,
|
|
25310
|
-
20 ] } },
|
|
25311
|
-
"POI_9992(mosque)":{ url:"https://dalganmap.ru/api-image/images/POI/9992_mosque.png",
|
|
25312
|
-
filtering:"mipmap",
|
|
25313
|
-
sprites:{ base:[ 0,
|
|
25314
|
-
0,
|
|
25315
|
-
20,
|
|
25316
|
-
20 ] } },
|
|
25317
|
-
"POI_9992(church)":{ url:"https://dalganmap.ru/api-image/images/POI/9992_church.png",
|
|
25318
|
-
filtering:"mipmap",
|
|
25319
|
-
sprites:{ base:[ 0,
|
|
25320
|
-
0,
|
|
25321
|
-
20,
|
|
25322
|
-
20 ] } },
|
|
25323
|
-
"POI_9992(temple)":{ url:"https://dalganmap.ru/api-image/images/POI/9992_temple.png",
|
|
25324
|
-
filtering:"mipmap",
|
|
25325
|
-
sprites:{ base:[ 0,
|
|
25326
|
-
0,
|
|
25327
|
-
20,
|
|
25328
|
-
20 ] } },
|
|
25329
|
-
"POI_9992(davidStar)":{ url:"https://dalganmap.ru/api-image/images/POI/9992_davidStar.png",
|
|
25330
|
-
filtering:"mipmap",
|
|
25331
|
-
sprites:{ base:[ 0,
|
|
25332
|
-
0,
|
|
25333
|
-
20,
|
|
25334
|
-
20 ] } },
|
|
25335
|
-
"POI_9992(mortar)":{ url:"https://dalganmap.ru/api-image/images/POI/9992_mortar.png",
|
|
25336
|
-
filtering:"mipmap",
|
|
25337
|
-
sprites:{ base:[ 0,
|
|
25338
|
-
0,
|
|
25339
|
-
20,
|
|
25340
|
-
20 ] } },
|
|
25341
|
-
"POI_4100(metro)":{ url:"https://dalganmap.ru/api-image/images/POI/4100_metro.png",
|
|
25342
|
-
filtering:"mipmap",
|
|
25343
|
-
sprites:{ base:[ 0,
|
|
25344
|
-
0,
|
|
25345
|
-
20,
|
|
25346
|
-
20 ] } },
|
|
25347
|
-
"POI_4100(diameter)":{ url:"https://dalganmap.ru/api-image/images/POI/4100_diameter.png",
|
|
25348
|
-
filtering:"mipmap",
|
|
25349
|
-
sprites:{ base:[ 0,
|
|
25350
|
-
0,
|
|
25351
|
-
41,
|
|
25352
|
-
15 ] } },
|
|
25353
|
-
POI_4013:{ url:"https://dalganmap.ru/api-image/images/POI/4013.png",
|
|
25354
|
-
filtering:"mipmap",
|
|
25355
|
-
sprites:{ base:[ 0,
|
|
25356
|
-
0,
|
|
25357
|
-
20,
|
|
25358
|
-
20 ] } } },
|
|
25359
|
-
layers:null,
|
|
25360
|
-
styles:{ buildings:{ base:"polygons",
|
|
25361
|
-
shaders:{ blocks:{ color:"color.rgb;\n" } } } },
|
|
25362
|
-
lights:{ light1:{ type:"directional",
|
|
25363
|
-
direction:[ 0.1,
|
|
25364
|
-
0.5,
|
|
25365
|
-
-1 ],
|
|
25366
|
-
diffuse:0.7,
|
|
25367
|
-
ambient:0.5 } },
|
|
25368
|
-
sources:null };
|
|
25369
|
-
data.global;
|
|
25370
|
-
data.cameras;
|
|
25371
|
-
data.textures;
|
|
25372
|
-
data.layers;
|
|
25373
|
-
data.styles;
|
|
25374
|
-
data.lights;
|
|
25375
|
-
data.sources;
|
|
25376
|
-
|
|
25377
|
-
const getBuildingLayers = (source) => {
|
|
25378
|
-
const layers = [];
|
|
25379
|
-
const data = {
|
|
25380
|
-
source,
|
|
25381
|
-
layer: exports.SourceLayers.BUILDING_AREA,
|
|
25382
|
-
minzoom: 15,
|
|
25383
|
-
};
|
|
25384
|
-
const layer = {
|
|
24927
|
+
const layer = {
|
|
25385
24928
|
id: getUniqueKey(),
|
|
25386
24929
|
data,
|
|
25387
24930
|
extruded: {
|
|
@@ -25503,7 +25046,7 @@ const getCameraLayers = (source) => {
|
|
|
25503
25046
|
const sublayers = {};
|
|
25504
25047
|
const texture = `camera`;
|
|
25505
25048
|
textures[texture] = {
|
|
25506
|
-
url:
|
|
25049
|
+
url: getImageSrc(`msk/${texture}/${texture}_${cameraConfig.size}.${cameraConfig.extension}`),
|
|
25507
25050
|
filtering: 'mipmap',
|
|
25508
25051
|
sprites: {
|
|
25509
25052
|
base: [0, 0, cameraConfig.size, cameraConfig.size],
|
|
@@ -26356,9 +25899,8 @@ const getPillarLayers = (source) => {
|
|
|
26356
25899
|
const textures = {};
|
|
26357
25900
|
const sublayers = {};
|
|
26358
25901
|
const texture = `pillar`;
|
|
26359
|
-
const textureUrl = `${imagesPath}/msk/${texture}/${texture}_${pillarConfig.size}.${pillarConfig.extension}`;
|
|
26360
25902
|
textures[texture] = {
|
|
26361
|
-
url:
|
|
25903
|
+
url: getImageSrc(`msk/${texture}/${texture}_${pillarConfig.size}.${pillarConfig.extension}`),
|
|
26362
25904
|
filtering: 'mipmap',
|
|
26363
25905
|
sprites: {
|
|
26364
25906
|
base: [0, 0, pillarConfig.size, pillarConfig.size],
|
|
@@ -28519,7 +28061,7 @@ const getTrafficSignLayers = (source) => {
|
|
|
28519
28061
|
};
|
|
28520
28062
|
const getTrafficSignImgSrc = ({ type, number, }) => {
|
|
28521
28063
|
const width = trafficSignConfig.widths[type];
|
|
28522
|
-
const textureUrl =
|
|
28064
|
+
const textureUrl = getImageSrc(`msk/${trafficSignConfig.fileName}_${width}/${number}.${trafficSignConfig.extension}`);
|
|
28523
28065
|
return textureUrl;
|
|
28524
28066
|
};
|
|
28525
28067
|
const parseTrafficSignCSVFile = (data) => {
|
|
@@ -28549,9 +28091,8 @@ const getTrafficSignalLayers = (source) => {
|
|
|
28549
28091
|
const textures = {};
|
|
28550
28092
|
const sublayers = {};
|
|
28551
28093
|
const texture = `traffic_signal`;
|
|
28552
|
-
const textureUrl = `${imagesPath}/msk/${texture}/${texture}_${trafficSignalConfig.size}.${trafficSignalConfig.extension}`;
|
|
28553
28094
|
textures[texture] = {
|
|
28554
|
-
url:
|
|
28095
|
+
url: getImageSrc(`msk/${texture}/${texture}_${trafficSignalConfig.size}.${trafficSignalConfig.extension}`),
|
|
28555
28096
|
filtering: 'mipmap',
|
|
28556
28097
|
sprites: {
|
|
28557
28098
|
base: [0, 0, trafficSignalConfig.size, trafficSignalConfig.size],
|
|
@@ -28693,6 +28234,374 @@ const getWaterLinkLayers = (source) => {
|
|
|
28693
28234
|
return layers;
|
|
28694
28235
|
};
|
|
28695
28236
|
|
|
28237
|
+
const color = 'white';
|
|
28238
|
+
const width = 0.5;
|
|
28239
|
+
const laneMarkingLineNumbers = {
|
|
28240
|
+
'1.1': {
|
|
28241
|
+
color,
|
|
28242
|
+
width,
|
|
28243
|
+
},
|
|
28244
|
+
'1.2': {
|
|
28245
|
+
color,
|
|
28246
|
+
width,
|
|
28247
|
+
},
|
|
28248
|
+
'1.5': {
|
|
28249
|
+
color,
|
|
28250
|
+
width,
|
|
28251
|
+
dash: [4, 10],
|
|
28252
|
+
},
|
|
28253
|
+
'1.6': {
|
|
28254
|
+
color,
|
|
28255
|
+
width,
|
|
28256
|
+
dash: [5, 5],
|
|
28257
|
+
},
|
|
28258
|
+
'1.7': {
|
|
28259
|
+
color,
|
|
28260
|
+
width,
|
|
28261
|
+
dash: [4, 10],
|
|
28262
|
+
},
|
|
28263
|
+
'1.7-blue': {
|
|
28264
|
+
color: 'blue',
|
|
28265
|
+
width,
|
|
28266
|
+
dash: [4, 10],
|
|
28267
|
+
},
|
|
28268
|
+
'1.8': {
|
|
28269
|
+
color,
|
|
28270
|
+
width,
|
|
28271
|
+
},
|
|
28272
|
+
'1.12': {
|
|
28273
|
+
color,
|
|
28274
|
+
width: 1.5,
|
|
28275
|
+
},
|
|
28276
|
+
'1.14.3': {
|
|
28277
|
+
color,
|
|
28278
|
+
width,
|
|
28279
|
+
dash: [3, 8],
|
|
28280
|
+
},
|
|
28281
|
+
'1.16.1': {
|
|
28282
|
+
color,
|
|
28283
|
+
width,
|
|
28284
|
+
},
|
|
28285
|
+
'1.16.2': {
|
|
28286
|
+
color,
|
|
28287
|
+
width,
|
|
28288
|
+
},
|
|
28289
|
+
'1.16.3': {
|
|
28290
|
+
color,
|
|
28291
|
+
width,
|
|
28292
|
+
},
|
|
28293
|
+
'1.16.x': {
|
|
28294
|
+
color,
|
|
28295
|
+
width,
|
|
28296
|
+
},
|
|
28297
|
+
'1.17.1': {
|
|
28298
|
+
color: 'yellow',
|
|
28299
|
+
width,
|
|
28300
|
+
},
|
|
28301
|
+
'1.26': {
|
|
28302
|
+
color: 'yellow',
|
|
28303
|
+
width,
|
|
28304
|
+
},
|
|
28305
|
+
};
|
|
28306
|
+
|
|
28307
|
+
const getLaneMarkingLineLayers = (source) => {
|
|
28308
|
+
const layers = [];
|
|
28309
|
+
const data = {
|
|
28310
|
+
source,
|
|
28311
|
+
layer: exports.SourceLayers.LINE_MARKING_LINE,
|
|
28312
|
+
};
|
|
28313
|
+
const sublayers = Object.entries(laneMarkingLineNumbers).reduce((sublayers, [lane_number, lines]) => {
|
|
28314
|
+
const sublayer = {
|
|
28315
|
+
filter: `function () {
|
|
28316
|
+
const { lane_number } = feature;
|
|
28317
|
+
|
|
28318
|
+
const isFilter = lane_number === '${lane_number}';
|
|
28319
|
+
|
|
28320
|
+
return isFilter;
|
|
28321
|
+
}`,
|
|
28322
|
+
draw: {
|
|
28323
|
+
lines,
|
|
28324
|
+
},
|
|
28325
|
+
};
|
|
28326
|
+
return {
|
|
28327
|
+
...sublayers,
|
|
28328
|
+
[lane_number]: sublayer,
|
|
28329
|
+
};
|
|
28330
|
+
}, {});
|
|
28331
|
+
const singleLayer = {
|
|
28332
|
+
id: getUniqueKey(),
|
|
28333
|
+
data,
|
|
28334
|
+
sublayers,
|
|
28335
|
+
};
|
|
28336
|
+
const doubleLayers = {
|
|
28337
|
+
'1.3-left': {
|
|
28338
|
+
id: getUniqueKey(),
|
|
28339
|
+
data,
|
|
28340
|
+
filter: `function() {
|
|
28341
|
+
const { lane_number } = feature;
|
|
28342
|
+
|
|
28343
|
+
const isFilter = lane_number === '1.3';
|
|
28344
|
+
|
|
28345
|
+
return isFilter;
|
|
28346
|
+
}`,
|
|
28347
|
+
draw: {
|
|
28348
|
+
lines: {
|
|
28349
|
+
color,
|
|
28350
|
+
width,
|
|
28351
|
+
offset: -width,
|
|
28352
|
+
},
|
|
28353
|
+
},
|
|
28354
|
+
},
|
|
28355
|
+
'1.3-right': {
|
|
28356
|
+
id: getUniqueKey(),
|
|
28357
|
+
data,
|
|
28358
|
+
filter: `function() {
|
|
28359
|
+
const { lane_number } = feature;
|
|
28360
|
+
|
|
28361
|
+
const isFilter = lane_number === '1.3';
|
|
28362
|
+
|
|
28363
|
+
return isFilter;
|
|
28364
|
+
}`,
|
|
28365
|
+
draw: {
|
|
28366
|
+
lines: {
|
|
28367
|
+
color,
|
|
28368
|
+
width,
|
|
28369
|
+
offset: width,
|
|
28370
|
+
},
|
|
28371
|
+
},
|
|
28372
|
+
},
|
|
28373
|
+
'1.11r-left': {
|
|
28374
|
+
id: getUniqueKey(),
|
|
28375
|
+
data,
|
|
28376
|
+
filter: `function() {
|
|
28377
|
+
const { lane_number } = feature;
|
|
28378
|
+
|
|
28379
|
+
const isFilter = lane_number === '1.11r';
|
|
28380
|
+
|
|
28381
|
+
return isFilter;
|
|
28382
|
+
}`,
|
|
28383
|
+
draw: {
|
|
28384
|
+
lines: {
|
|
28385
|
+
color,
|
|
28386
|
+
width,
|
|
28387
|
+
offset: -width,
|
|
28388
|
+
},
|
|
28389
|
+
},
|
|
28390
|
+
},
|
|
28391
|
+
'1.11r-right': {
|
|
28392
|
+
id: getUniqueKey(),
|
|
28393
|
+
data,
|
|
28394
|
+
filter: `function() {
|
|
28395
|
+
const { lane_number } = feature;
|
|
28396
|
+
|
|
28397
|
+
const isFilter = lane_number === '1.11r';
|
|
28398
|
+
|
|
28399
|
+
return isFilter;
|
|
28400
|
+
}`,
|
|
28401
|
+
draw: {
|
|
28402
|
+
lines: {
|
|
28403
|
+
color,
|
|
28404
|
+
width,
|
|
28405
|
+
offset: width,
|
|
28406
|
+
dash: [5, 5],
|
|
28407
|
+
},
|
|
28408
|
+
},
|
|
28409
|
+
},
|
|
28410
|
+
'1.11l-left': {
|
|
28411
|
+
id: getUniqueKey(),
|
|
28412
|
+
data,
|
|
28413
|
+
filter: `function() {
|
|
28414
|
+
const { lane_number } = feature;
|
|
28415
|
+
|
|
28416
|
+
const isFilter = lane_number === '1.11l';
|
|
28417
|
+
|
|
28418
|
+
return isFilter;
|
|
28419
|
+
}`,
|
|
28420
|
+
draw: {
|
|
28421
|
+
lines: {
|
|
28422
|
+
color,
|
|
28423
|
+
width,
|
|
28424
|
+
offset: -width,
|
|
28425
|
+
dash: [5, 5],
|
|
28426
|
+
},
|
|
28427
|
+
},
|
|
28428
|
+
},
|
|
28429
|
+
'1.11l-right': {
|
|
28430
|
+
id: getUniqueKey(),
|
|
28431
|
+
data,
|
|
28432
|
+
filter: `function() {
|
|
28433
|
+
const { lane_number } = feature;
|
|
28434
|
+
|
|
28435
|
+
const isFilter = lane_number === '1.11l';
|
|
28436
|
+
|
|
28437
|
+
return isFilter;
|
|
28438
|
+
}`,
|
|
28439
|
+
draw: {
|
|
28440
|
+
lines: {
|
|
28441
|
+
color,
|
|
28442
|
+
width,
|
|
28443
|
+
offset: width,
|
|
28444
|
+
},
|
|
28445
|
+
},
|
|
28446
|
+
},
|
|
28447
|
+
'1.25-left': {
|
|
28448
|
+
id: getUniqueKey(),
|
|
28449
|
+
data,
|
|
28450
|
+
filter: `function() {
|
|
28451
|
+
const { lane_number } = feature;
|
|
28452
|
+
|
|
28453
|
+
const isFilter = lane_number === '1.25';
|
|
28454
|
+
|
|
28455
|
+
return isFilter;
|
|
28456
|
+
}`,
|
|
28457
|
+
draw: {
|
|
28458
|
+
lines: {
|
|
28459
|
+
color,
|
|
28460
|
+
width: 1,
|
|
28461
|
+
offset: -0.5,
|
|
28462
|
+
dash: [1, 1],
|
|
28463
|
+
dash_background_color: [0.0, 0.0, 0.0, 0.0],
|
|
28464
|
+
},
|
|
28465
|
+
},
|
|
28466
|
+
},
|
|
28467
|
+
'1.25-right': {
|
|
28468
|
+
id: getUniqueKey(),
|
|
28469
|
+
data,
|
|
28470
|
+
filter: `function() {
|
|
28471
|
+
const { lane_number } = feature;
|
|
28472
|
+
|
|
28473
|
+
const isFilter = lane_number === '1.25';
|
|
28474
|
+
|
|
28475
|
+
return isFilter;
|
|
28476
|
+
}`,
|
|
28477
|
+
draw: {
|
|
28478
|
+
lines: {
|
|
28479
|
+
color: 'rgba(0,0,0,0)',
|
|
28480
|
+
width: 1,
|
|
28481
|
+
offset: 1 / 2,
|
|
28482
|
+
dash: [1, 1],
|
|
28483
|
+
dash_background_color: [1.0, 1.0, 1.0],
|
|
28484
|
+
},
|
|
28485
|
+
},
|
|
28486
|
+
},
|
|
28487
|
+
};
|
|
28488
|
+
layers.push(singleLayer, ...Object.values(doubleLayers));
|
|
28489
|
+
return layers;
|
|
28490
|
+
};
|
|
28491
|
+
|
|
28492
|
+
const getLaneMarkingPolyLayers = (source) => {
|
|
28493
|
+
const layers = [];
|
|
28494
|
+
const data = {
|
|
28495
|
+
source,
|
|
28496
|
+
layer: exports.SourceLayers.LINE_MARKING_POLY,
|
|
28497
|
+
};
|
|
28498
|
+
const layer__1_14_1 = {
|
|
28499
|
+
id: getUniqueKey(),
|
|
28500
|
+
data,
|
|
28501
|
+
filter: `function() {
|
|
28502
|
+
const { poly_number } = feature;
|
|
28503
|
+
|
|
28504
|
+
const isFilter = poly_number === '1.14.1';
|
|
28505
|
+
|
|
28506
|
+
return isFilter;
|
|
28507
|
+
}`,
|
|
28508
|
+
draw: {
|
|
28509
|
+
styles: {
|
|
28510
|
+
zebra_crossing: {
|
|
28511
|
+
attributes: {
|
|
28512
|
+
a_angle: `function() {
|
|
28513
|
+
return feature.angle;
|
|
28514
|
+
}`,
|
|
28515
|
+
},
|
|
28516
|
+
},
|
|
28517
|
+
},
|
|
28518
|
+
},
|
|
28519
|
+
};
|
|
28520
|
+
const layer__1_18 = {
|
|
28521
|
+
id: getUniqueKey(),
|
|
28522
|
+
data,
|
|
28523
|
+
filter: `function() {
|
|
28524
|
+
const { poly_number } = feature;
|
|
28525
|
+
|
|
28526
|
+
const isFilter = poly_number === '1.18';
|
|
28527
|
+
|
|
28528
|
+
return isFilter;
|
|
28529
|
+
}`,
|
|
28530
|
+
draw: {
|
|
28531
|
+
polygons: {
|
|
28532
|
+
color: 'white',
|
|
28533
|
+
},
|
|
28534
|
+
},
|
|
28535
|
+
};
|
|
28536
|
+
layers.push(layer__1_18, layer__1_14_1);
|
|
28537
|
+
return layers;
|
|
28538
|
+
};
|
|
28539
|
+
|
|
28540
|
+
const getParkingLineLayers = (source) => {
|
|
28541
|
+
const layers = [];
|
|
28542
|
+
const data = {
|
|
28543
|
+
source,
|
|
28544
|
+
layer: exports.SourceLayers.PARKING_LINE,
|
|
28545
|
+
};
|
|
28546
|
+
const layer = {
|
|
28547
|
+
id: getUniqueKey(),
|
|
28548
|
+
data,
|
|
28549
|
+
draw: {
|
|
28550
|
+
lines: {
|
|
28551
|
+
color: 'white',
|
|
28552
|
+
width: 1,
|
|
28553
|
+
},
|
|
28554
|
+
},
|
|
28555
|
+
};
|
|
28556
|
+
layers.push(layer);
|
|
28557
|
+
return layers;
|
|
28558
|
+
};
|
|
28559
|
+
|
|
28560
|
+
var RoadPolyTypes;
|
|
28561
|
+
(function (RoadPolyTypes) {
|
|
28562
|
+
RoadPolyTypes["ROAD"] = "Road";
|
|
28563
|
+
RoadPolyTypes["TUNNEL"] = "Tunnel";
|
|
28564
|
+
RoadPolyTypes["TRAM"] = "Tram";
|
|
28565
|
+
RoadPolyTypes["CURB"] = "Curb";
|
|
28566
|
+
RoadPolyTypes["BRIDGE"] = "Bridge";
|
|
28567
|
+
})(RoadPolyTypes || (RoadPolyTypes = {}));
|
|
28568
|
+
|
|
28569
|
+
const roadPolyColors = {
|
|
28570
|
+
[RoadPolyTypes.ROAD]: '#BABCC2',
|
|
28571
|
+
[RoadPolyTypes.TUNNEL]: '#EAEBEE',
|
|
28572
|
+
[RoadPolyTypes.TRAM]: '#ADA8A8',
|
|
28573
|
+
[RoadPolyTypes.CURB]: '#D2D9E6',
|
|
28574
|
+
[RoadPolyTypes.BRIDGE]: '#E1DFDD',
|
|
28575
|
+
};
|
|
28576
|
+
|
|
28577
|
+
const getRoadPolyLayers = (source) => {
|
|
28578
|
+
const layers = [];
|
|
28579
|
+
const data = {
|
|
28580
|
+
source,
|
|
28581
|
+
layer: exports.SourceLayers.ROAD_POLY,
|
|
28582
|
+
};
|
|
28583
|
+
Object.values(RoadPolyTypes).forEach((type) => {
|
|
28584
|
+
const layer = {
|
|
28585
|
+
id: getUniqueKey(),
|
|
28586
|
+
data,
|
|
28587
|
+
filter: `function() {
|
|
28588
|
+
const { type } = feature;
|
|
28589
|
+
|
|
28590
|
+
const isFilter = type === '${type}';
|
|
28591
|
+
|
|
28592
|
+
return isFilter;
|
|
28593
|
+
}`,
|
|
28594
|
+
draw: {
|
|
28595
|
+
polygons: {
|
|
28596
|
+
color: roadPolyColors[type],
|
|
28597
|
+
},
|
|
28598
|
+
},
|
|
28599
|
+
};
|
|
28600
|
+
layers.push(layer);
|
|
28601
|
+
});
|
|
28602
|
+
return layers;
|
|
28603
|
+
};
|
|
28604
|
+
|
|
28696
28605
|
const getLayerName = ({ id, data: { source, layer }, }) => {
|
|
28697
28606
|
const layerName = `${id}-${source}-${layer}`;
|
|
28698
28607
|
return layerName;
|
|
@@ -29156,7 +29065,7 @@ function useMap() {
|
|
|
29156
29065
|
return useLeafletContext().map;
|
|
29157
29066
|
}
|
|
29158
29067
|
|
|
29159
|
-
const LeafletLayer = ({
|
|
29068
|
+
const LeafletLayer = ({ layers }) => {
|
|
29160
29069
|
const { layer, addLayer } = useGetLeafletLayer({});
|
|
29161
29070
|
const map = useMap();
|
|
29162
29071
|
React__namespace.useEffect(() => {
|
|
@@ -29165,8 +29074,8 @@ const LeafletLayer = ({ source }) => {
|
|
|
29165
29074
|
}
|
|
29166
29075
|
}, [layer]);
|
|
29167
29076
|
React__namespace.useEffect(() => {
|
|
29168
|
-
|
|
29169
|
-
}, [addLayer,
|
|
29077
|
+
layers.map(addLayer);
|
|
29078
|
+
}, [addLayer, layers]);
|
|
29170
29079
|
return null;
|
|
29171
29080
|
};
|
|
29172
29081
|
|
|
@@ -31847,7 +31756,6 @@ exports.StoreContext = StoreContext;
|
|
|
31847
31756
|
exports.Tabs = Tabs;
|
|
31848
31757
|
exports.TextField = TextField;
|
|
31849
31758
|
exports.UploadButton = UploadButton;
|
|
31850
|
-
exports._backendUrl = _backendUrl;
|
|
31851
31759
|
exports._testApiKeys = _testApiKeys;
|
|
31852
31760
|
exports.alertStore = alertStore;
|
|
31853
31761
|
exports.allTrafficSigns = allTrafficSigns;
|
|
@@ -31875,23 +31783,21 @@ exports.getCoordinateByLatLng = getCoordinateByLatLng;
|
|
|
31875
31783
|
exports.getDefaultPOI = getDefaultPOI;
|
|
31876
31784
|
exports.getEntityNames = getEntityNames;
|
|
31877
31785
|
exports.getFacilityAreaLayers = getFacilityAreaLayers;
|
|
31786
|
+
exports.getImageSrc = getImageSrc;
|
|
31878
31787
|
exports.getLanduseAreaLayers = getLanduseAreaLayers;
|
|
31879
|
-
exports.getLaneMarkingLineLayers = getLaneMarkingLineLayers;
|
|
31880
|
-
exports.getLaneMarkingPolyLayers = getLaneMarkingPolyLayers;
|
|
31881
31788
|
exports.getLayerModalsNames = getLayerModalsNames;
|
|
31882
31789
|
exports.getLayerName = getLayerName;
|
|
31883
31790
|
exports.getLinkLayers = getLinkLayers;
|
|
31884
31791
|
exports.getNatureFieldLayers = getNatureFieldLayers;
|
|
31885
31792
|
exports.getNatureForestLayers = getNatureForestLayers;
|
|
31793
|
+
exports.getNewId = getNewId;
|
|
31886
31794
|
exports.getOceanAreaLayers = getOceanAreaLayers;
|
|
31887
31795
|
exports.getOneWayLayers = getOneWayLayers;
|
|
31888
31796
|
exports.getPOILayers = getPOILayers;
|
|
31889
31797
|
exports.getPOITypeLayer = getPOITypeLayer;
|
|
31890
|
-
exports.getParkingLineLayers = getParkingLineLayers;
|
|
31891
31798
|
exports.getPillarLayers = getPillarLayers;
|
|
31892
31799
|
exports.getPointAddressLayers = getPointAddressLayers;
|
|
31893
31800
|
exports.getRailroadLayers = getRailroadLayers;
|
|
31894
|
-
exports.getRoadPolyLayers = getRoadPolyLayers;
|
|
31895
31801
|
exports.getStringRequiredSchema = getStringRequiredSchema;
|
|
31896
31802
|
exports.getStringSchema = getStringSchema;
|
|
31897
31803
|
exports.getTrafficSignImgSrc = getTrafficSignImgSrc;
|
|
@@ -31902,7 +31808,6 @@ exports.getUrlencodedBody = getUrlencodedBody;
|
|
|
31902
31808
|
exports.getValidLayer = getValidLayer;
|
|
31903
31809
|
exports.getWaterAreaLayers = getWaterAreaLayers;
|
|
31904
31810
|
exports.getWaterLinkLayers = getWaterLinkLayers;
|
|
31905
|
-
exports.imagesPath = imagesPath;
|
|
31906
31811
|
exports.loggerService = loggerService;
|
|
31907
31812
|
exports.modalStore = modalStore;
|
|
31908
31813
|
exports.modalStyle = modalStyle;
|