diff --git a/404.html b/404.html index 18f99f0c1c..b53b74429b 100644 --- a/404.html +++ b/404.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/:language/examples/:topic/:example/index.html b/:language/examples/:topic/:example/index.html index 18f99f0c1c..b53b74429b 100644 --- a/:language/examples/:topic/:example/index.html +++ b/:language/examples/:topic/:example/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/:language/examples/index.html b/:language/examples/index.html index 18f99f0c1c..b53b74429b 100644 --- a/:language/examples/index.html +++ b/:language/examples/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/base_layer/base/index.html b/api/base_layer/base/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/base_layer/base/index.html +++ b/api/base_layer/base/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/component/component/index.html b/api/component/component/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/component/component/index.html +++ b/api/component/component/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/component/control/control/index.html b/api/component/control/control/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/component/control/control/index.html +++ b/api/component/control/control/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/component/control/export-image/index.html b/api/component/control/export-image/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/component/control/export-image/index.html +++ b/api/component/control/export-image/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/component/control/fullscreen/index.html b/api/component/control/fullscreen/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/component/control/fullscreen/index.html +++ b/api/component/control/fullscreen/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/component/control/geolocate/index.html b/api/component/control/geolocate/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/component/control/geolocate/index.html +++ b/api/component/control/geolocate/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/component/control/layer-switch/index.html b/api/component/control/layer-switch/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/component/control/layer-switch/index.html +++ b/api/component/control/layer-switch/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/component/control/logo/index.html b/api/component/control/logo/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/component/control/logo/index.html +++ b/api/component/control/logo/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/component/control/map-theme/index.html b/api/component/control/map-theme/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/component/control/map-theme/index.html +++ b/api/component/control/map-theme/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/component/control/mouse-location/index.html b/api/component/control/mouse-location/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/component/control/mouse-location/index.html +++ b/api/component/control/mouse-location/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/component/control/scale/index.html b/api/component/control/scale/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/component/control/scale/index.html +++ b/api/component/control/scale/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/component/control/zoom/index.html b/api/component/control/zoom/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/component/control/zoom/index.html +++ b/api/component/control/zoom/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/component/marker/marker-layer/index.html b/api/component/marker/marker-layer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/component/marker/marker-layer/index.html +++ b/api/component/marker/marker-layer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/component/marker/marker/index.html b/api/component/marker/marker/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/component/marker/marker/index.html +++ b/api/component/marker/marker/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/component/popup/layer-popup/index.html b/api/component/popup/layer-popup/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/component/popup/layer-popup/index.html +++ b/api/component/popup/layer-popup/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/component/popup/popup/index.html b/api/component/popup/popup/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/component/popup/popup/index.html +++ b/api/component/popup/popup/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/debug/debugservice/index.html b/api/debug/debugservice/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/debug/debugservice/index.html +++ b/api/debug/debugservice/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/experiment/canvas/index.html b/api/experiment/canvas/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/experiment/canvas/index.html +++ b/api/experiment/canvas/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/experiment/earth/earth/index.html b/api/experiment/earth/earth/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/experiment/earth/earth/index.html +++ b/api/experiment/earth/earth/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/experiment/earth/flyline/index.html b/api/experiment/earth/flyline/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/experiment/earth/flyline/index.html +++ b/api/experiment/earth/flyline/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/experiment/earth/point/index.html b/api/experiment/earth/point/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/experiment/earth/point/index.html +++ b/api/experiment/earth/point/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/experiment/pass/index.html b/api/experiment/pass/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/experiment/pass/index.html +++ b/api/experiment/pass/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/experiment/simplecoordinates/index.html b/api/experiment/simplecoordinates/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/experiment/simplecoordinates/index.html +++ b/api/experiment/simplecoordinates/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/experiment/three/index.html b/api/experiment/three/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/experiment/three/index.html +++ b/api/experiment/three/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/experiment/wind/index.html b/api/experiment/wind/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/experiment/wind/index.html +++ b/api/experiment/wind/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/heatmap_layer/heatmap/index.html b/api/heatmap_layer/heatmap/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/heatmap_layer/heatmap/index.html +++ b/api/heatmap_layer/heatmap/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/heatmap_layer/options/index.html b/api/heatmap_layer/options/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/heatmap_layer/options/index.html +++ b/api/heatmap_layer/options/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/heatmap_layer/scale/index.html b/api/heatmap_layer/scale/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/heatmap_layer/scale/index.html +++ b/api/heatmap_layer/scale/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/heatmap_layer/shape/index.html b/api/heatmap_layer/shape/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/heatmap_layer/shape/index.html +++ b/api/heatmap_layer/shape/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/heatmap_layer/source/index.html b/api/heatmap_layer/source/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/heatmap_layer/source/index.html +++ b/api/heatmap_layer/source/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/heatmap_layer/style/index.html b/api/heatmap_layer/style/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/heatmap_layer/style/index.html +++ b/api/heatmap_layer/style/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/image_layer/imagelayer/index.html b/api/image_layer/imagelayer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/image_layer/imagelayer/index.html +++ b/api/image_layer/imagelayer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/image_layer/options/index.html b/api/image_layer/options/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/image_layer/options/index.html +++ b/api/image_layer/options/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/image_layer/source/index.html b/api/image_layer/source/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/image_layer/source/index.html +++ b/api/image_layer/source/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/image_layer/style/index.html b/api/image_layer/style/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/image_layer/style/index.html +++ b/api/image_layer/style/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/line_layer/animate/index.html b/api/line_layer/animate/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/line_layer/animate/index.html +++ b/api/line_layer/animate/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/line_layer/color/index.html b/api/line_layer/color/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/line_layer/color/index.html +++ b/api/line_layer/color/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/line_layer/features/animate/index.html b/api/line_layer/features/animate/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/line_layer/features/animate/index.html +++ b/api/line_layer/features/animate/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/line_layer/features/border/index.html b/api/line_layer/features/border/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/line_layer/features/border/index.html +++ b/api/line_layer/features/border/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/line_layer/features/dash/index.html b/api/line_layer/features/dash/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/line_layer/features/dash/index.html +++ b/api/line_layer/features/dash/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/line_layer/features/linear/index.html b/api/line_layer/features/linear/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/line_layer/features/linear/index.html +++ b/api/line_layer/features/linear/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/line_layer/features/segment-number/index.html b/api/line_layer/features/segment-number/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/line_layer/features/segment-number/index.html +++ b/api/line_layer/features/segment-number/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/line_layer/features/texture/index.html b/api/line_layer/features/texture/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/line_layer/features/texture/index.html +++ b/api/line_layer/features/texture/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/line_layer/features/theta-offset/index.html b/api/line_layer/features/theta-offset/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/line_layer/features/theta-offset/index.html +++ b/api/line_layer/features/theta-offset/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/line_layer/features/vertex-height/index.html b/api/line_layer/features/vertex-height/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/line_layer/features/vertex-height/index.html +++ b/api/line_layer/features/vertex-height/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/line_layer/linelayer/index.html b/api/line_layer/linelayer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/line_layer/linelayer/index.html +++ b/api/line_layer/linelayer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/line_layer/options/index.html b/api/line_layer/options/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/line_layer/options/index.html +++ b/api/line_layer/options/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/line_layer/scale/index.html b/api/line_layer/scale/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/line_layer/scale/index.html +++ b/api/line_layer/scale/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/line_layer/shape/index.html b/api/line_layer/shape/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/line_layer/shape/index.html +++ b/api/line_layer/shape/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/line_layer/size/index.html b/api/line_layer/size/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/line_layer/size/index.html +++ b/api/line_layer/size/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/line_layer/source/index.html b/api/line_layer/source/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/line_layer/source/index.html +++ b/api/line_layer/source/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/line_layer/style/index.html b/api/line_layer/style/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/line_layer/style/index.html +++ b/api/line_layer/style/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/line_layer/texture/index.html b/api/line_layer/texture/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/line_layer/texture/index.html +++ b/api/line_layer/texture/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/map/map/index.html b/api/map/map/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/map/map/index.html +++ b/api/map/map/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/mask_layer/masklayer/index.html b/api/mask_layer/masklayer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/mask_layer/masklayer/index.html +++ b/api/mask_layer/masklayer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/mask_layer/options/index.html b/api/mask_layer/options/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/mask_layer/options/index.html +++ b/api/mask_layer/options/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/mask_layer/source/index.html b/api/mask_layer/source/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/mask_layer/source/index.html +++ b/api/mask_layer/source/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/mini/demos/chinapopulation/index.html b/api/mini/demos/chinapopulation/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/mini/demos/chinapopulation/index.html +++ b/api/mini/demos/chinapopulation/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/mini/demos/flyline/index.html b/api/mini/demos/flyline/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/mini/demos/flyline/index.html +++ b/api/mini/demos/flyline/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/mini/demos/heat/index.html b/api/mini/demos/heat/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/mini/demos/heat/index.html +++ b/api/mini/demos/heat/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/mini/demos/hexagon/index.html b/api/mini/demos/hexagon/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/mini/demos/hexagon/index.html +++ b/api/mini/demos/hexagon/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/mini/demos/high-line/index.html b/api/mini/demos/high-line/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/mini/demos/high-line/index.html +++ b/api/mini/demos/high-line/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/mini/mini/index.html b/api/mini/mini/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/mini/mini/index.html +++ b/api/mini/mini/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/other/citybuilding/index.html b/api/other/citybuilding/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/other/citybuilding/index.html +++ b/api/other/citybuilding/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/other/plane/index.html b/api/other/plane/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/other/plane/index.html +++ b/api/other/plane/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/other/sprite/index.html b/api/other/sprite/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/other/sprite/index.html +++ b/api/other/sprite/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/point_layer/animate/index.html b/api/point_layer/animate/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/point_layer/animate/index.html +++ b/api/point_layer/animate/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/point_layer/color/index.html b/api/point_layer/color/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/point_layer/color/index.html +++ b/api/point_layer/color/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/point_layer/options/index.html b/api/point_layer/options/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/point_layer/options/index.html +++ b/api/point_layer/options/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/point_layer/pointlayer/index.html b/api/point_layer/pointlayer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/point_layer/pointlayer/index.html +++ b/api/point_layer/pointlayer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/point_layer/scale/index.html b/api/point_layer/scale/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/point_layer/scale/index.html +++ b/api/point_layer/scale/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/point_layer/shape/index.html b/api/point_layer/shape/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/point_layer/shape/index.html +++ b/api/point_layer/shape/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/point_layer/size/index.html b/api/point_layer/size/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/point_layer/size/index.html +++ b/api/point_layer/size/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/point_layer/source/index.html b/api/point_layer/source/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/point_layer/source/index.html +++ b/api/point_layer/source/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/point_layer/style/index.html b/api/point_layer/style/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/point_layer/style/index.html +++ b/api/point_layer/style/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/polygon_layer/animate/index.html b/api/polygon_layer/animate/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/polygon_layer/animate/index.html +++ b/api/polygon_layer/animate/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/polygon_layer/color/index.html b/api/polygon_layer/color/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/polygon_layer/color/index.html +++ b/api/polygon_layer/color/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/polygon_layer/options/index.html b/api/polygon_layer/options/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/polygon_layer/options/index.html +++ b/api/polygon_layer/options/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/polygon_layer/polygonlayer/index.html b/api/polygon_layer/polygonlayer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/polygon_layer/polygonlayer/index.html +++ b/api/polygon_layer/polygonlayer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/polygon_layer/scale/index.html b/api/polygon_layer/scale/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/polygon_layer/scale/index.html +++ b/api/polygon_layer/scale/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/polygon_layer/shape/index.html b/api/polygon_layer/shape/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/polygon_layer/shape/index.html +++ b/api/polygon_layer/shape/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/polygon_layer/source/index.html b/api/polygon_layer/source/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/polygon_layer/source/index.html +++ b/api/polygon_layer/source/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/polygon_layer/style/index.html b/api/polygon_layer/style/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/polygon_layer/style/index.html +++ b/api/polygon_layer/style/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/raster_layer/common/rampcolors/index.html b/api/raster_layer/common/rampcolors/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/raster_layer/common/rampcolors/index.html +++ b/api/raster_layer/common/rampcolors/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/raster_layer/common/style/index.html b/api/raster_layer/common/style/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/raster_layer/common/style/index.html +++ b/api/raster_layer/common/style/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/raster_layer/common/style_single/index.html b/api/raster_layer/common/style_single/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/raster_layer/common/style_single/index.html +++ b/api/raster_layer/common/style_single/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/raster_layer/raster_layer/index.html b/api/raster_layer/raster_layer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/raster_layer/raster_layer/index.html +++ b/api/raster_layer/raster_layer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/raster_layer/raster_multi_band/index.html b/api/raster_layer/raster_multi_band/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/raster_layer/raster_multi_band/index.html +++ b/api/raster_layer/raster_multi_band/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/raster_layer/raster_rgb/index.html b/api/raster_layer/raster_rgb/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/raster_layer/raster_rgb/index.html +++ b/api/raster_layer/raster_rgb/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/raster_layer/raster_single_band/index.html b/api/raster_layer/raster_single_band/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/raster_layer/raster_single_band/index.html +++ b/api/raster_layer/raster_single_band/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/scene/index.html b/api/scene/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/scene/index.html +++ b/api/scene/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/source/csv/index.html b/api/source/csv/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/source/csv/index.html +++ b/api/source/csv/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/source/geojson/index.html b/api/source/geojson/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/source/geojson/index.html +++ b/api/source/geojson/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/source/image/index.html b/api/source/image/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/source/image/index.html +++ b/api/source/image/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/source/json/index.html b/api/source/json/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/source/json/index.html +++ b/api/source/json/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/source/mvt/index.html b/api/source/mvt/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/source/mvt/index.html +++ b/api/source/mvt/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/source/raster/index.html b/api/source/raster/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/source/raster/index.html +++ b/api/source/raster/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/source/raster/raster_band_calc/index.html b/api/source/raster/raster_band_calc/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/source/raster/raster_band_calc/index.html +++ b/api/source/raster/raster_band_calc/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/source/raster/raster_multi/index.html b/api/source/raster/raster_multi/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/source/raster/raster_multi/index.html +++ b/api/source/raster/raster_multi/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/source/raster/raster_rgb/index.html b/api/source/raster/raster_rgb/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/source/raster/raster_rgb/index.html +++ b/api/source/raster/raster_rgb/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/source/raster/raster_single/index.html b/api/source/raster/raster_single/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/source/raster/raster_single/index.html +++ b/api/source/raster/raster_single/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/source/raster_rgb/index.html b/api/source/raster_rgb/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/source/raster_rgb/index.html +++ b/api/source/raster_rgb/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/source/rastertile/index.html b/api/source/rastertile/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/source/rastertile/index.html +++ b/api/source/rastertile/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/source/source/index.html b/api/source/source/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/source/source/index.html +++ b/api/source/source/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/tile/common/options/index.html b/api/tile/common/options/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/tile/common/options/index.html +++ b/api/tile/common/options/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/tile/common/style/index.html b/api/tile/common/style/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/tile/common/style/index.html +++ b/api/tile/common/style/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/tile/geojsonvt_tile_layer/index.html b/api/tile/geojsonvt_tile_layer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/tile/geojsonvt_tile_layer/index.html +++ b/api/tile/geojsonvt_tile_layer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/tile/raster_tile_layer/index.html b/api/tile/raster_tile_layer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/tile/raster_tile_layer/index.html +++ b/api/tile/raster_tile_layer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/api/tile/vector_tile_layer/index.html b/api/tile/vector_tile_layer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/api/tile/vector_tile_layer/index.html +++ b/api/tile/vector_tile_layer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/control/api/index.html b/common/control/api/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/control/api/index.html +++ b/common/control/api/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/control/btn-api/index.html b/common/control/btn-api/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/control/btn-api/index.html +++ b/common/control/btn-api/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/control/event/index.html b/common/control/event/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/control/event/index.html +++ b/common/control/event/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/control/method/index.html b/common/control/method/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/control/method/index.html +++ b/common/control/method/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/control/popper-api/index.html b/common/control/popper-api/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/control/popper-api/index.html +++ b/common/control/popper-api/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/control/popper-event/index.html b/common/control/popper-event/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/control/popper-event/index.html +++ b/common/control/popper-event/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/control/select-event/index.html b/common/control/select-event/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/control/select-event/index.html +++ b/common/control/select-event/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/district/bubble/index.html b/common/district/bubble/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/district/bubble/index.html +++ b/common/district/bubble/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/district/choropleth/index.html b/common/district/choropleth/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/district/choropleth/index.html +++ b/common/district/choropleth/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/district/event/index.html b/common/district/event/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/district/event/index.html +++ b/common/district/event/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/district/fill/index.html b/common/district/fill/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/district/fill/index.html +++ b/common/district/fill/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/district/label/index.html b/common/district/label/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/district/label/index.html +++ b/common/district/label/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/district/option/index.html b/common/district/option/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/district/option/index.html +++ b/common/district/option/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/district/popup/index.html b/common/district/popup/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/district/popup/index.html +++ b/common/district/popup/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/layer/base/index.html b/common/layer/base/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/layer/base/index.html +++ b/common/layer/base/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/layer/color/index.html b/common/layer/color/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/layer/color/index.html +++ b/common/layer/color/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/layer/layer_ctr/index.html b/common/layer/layer_ctr/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/layer/layer_ctr/index.html +++ b/common/layer/layer_ctr/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/layer/layer_encode/index.html b/common/layer/layer_encode/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/layer/layer_encode/index.html +++ b/common/layer/layer_encode/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/layer/layer_event/index.html b/common/layer/layer_event/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/layer/layer_event/index.html +++ b/common/layer/layer_event/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/layer/layer_interaction/index.html b/common/layer/layer_interaction/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/layer/layer_interaction/index.html +++ b/common/layer/layer_interaction/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/layer/layer_style/index.html b/common/layer/layer_style/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/layer/layer_style/index.html +++ b/common/layer/layer_style/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/layer/layer_texture/index.html b/common/layer/layer_texture/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/layer/layer_texture/index.html +++ b/common/layer/layer_texture/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/layer/layer_update/index.html b/common/layer/layer_update/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/layer/layer_update/index.html +++ b/common/layer/layer_update/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/layer/mouse_event/index.html b/common/layer/mouse_event/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/layer/mouse_event/index.html +++ b/common/layer/mouse_event/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/layer/options/index.html b/common/layer/options/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/layer/options/index.html +++ b/common/layer/options/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/layer/scale/index.html b/common/layer/scale/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/layer/scale/index.html +++ b/common/layer/scale/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/layer/source/index.html b/common/layer/source/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/layer/source/index.html +++ b/common/layer/source/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/common/style/index.html b/common/style/index.html index 18f99f0c1c..b53b74429b 100644 --- a/common/style/index.html +++ b/common/style/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/dumi__tmp-production__theme-antv__ContextWrapper.dd3d94fc.async.js b/dumi__tmp-production__theme-antv__ContextWrapper.d9e36a41.async.js similarity index 97% rename from dumi__tmp-production__theme-antv__ContextWrapper.dd3d94fc.async.js rename to dumi__tmp-production__theme-antv__ContextWrapper.d9e36a41.async.js index 6a20198421..f9983e5395 100644 --- a/dumi__tmp-production__theme-antv__ContextWrapper.dd3d94fc.async.js +++ b/dumi__tmp-production__theme-antv__ContextWrapper.d9e36a41.async.js @@ -1 +1 @@ -"use strict";(self.webpackChunk_antv_l7_site=self.webpackChunk_antv_l7_site||[]).push([[2643],{95084:function(n,e,a){a.r(e),a.d(e,{default:function(){return r}});a(41398);var t=a(66541),o=a(74927),s=a(46228);function r(){var n=(0,t.pC)();return(0,s.jsx)(o.w.Provider,{value:{meta:{exampleTopics:[{id:"gallery",title:{zh:"官方精品库",en:"Featured"},icon:"gallery",examples:[{demos:[{id:"grid",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*h-AMQodd7s4AAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport { ThreeLayer, ThreeRender } from '@antv/l7-three';\nimport * as THREE from 'three';\nimport { GLTFLoader } from 'three/examples/jsm/loaders/GLTFLoader';\n\nfunction getImageData(img) {\n const canvas = document.createElement('canvas');\n const ctx = canvas.getContext('2d');\n const { width, height } = img;\n canvas.width = width;\n canvas.height = height;\n\n ctx.drawImage(img, 0, 0, width, height);\n const imageData = ctx.getImageData(0, 0, width, height);\n\n return imageData;\n}\n\nfunction getLatData(data) {\n const size = Math.floor(Math.sqrt(data.length));\n\n const arr = [];\n const startLng = 110,\n lngStep = 5 / (size - 1);\n const startLat = 30,\n latStep = -5 / (size - 1);\n for (let i = 0; i < size; i++) {\n const arr2 = [];\n for (let j = 0; j < size; j++) {\n const index = i + j * size;\n const x = startLng + lngStep * i;\n const y = startLat + latStep * j;\n\n arr2.push([ x, y, data[index] ]);\n }\n arr.push(arr2);\n }\n return arr;\n}\n\nfunction getLngData(data) {\n const size = Math.floor(Math.sqrt(data.length));\n const arr = [];\n const startLng = 110,\n lngStep = 5 / (size - 1);\n const startLat = 30,\n latStep = -5 / (size - 1);\n\n for (let i = 0; i < size; i++) {\n const arr2 = [];\n for (let j = 0; j < size; j++) {\n const index = i * size + j;\n const x = startLng + lngStep * j;\n const y = startLat + latStep * i;\n\n arr2.push([ x, y, data[index] ]);\n }\n arr.push(arr2);\n }\n return arr;\n}\n\nfunction getR(data) {\n const arr = [];\n for (let i = 0; i < data.length; i += 4) {\n arr.push(data[i]);\n }\n return arr;\n}\n\nfunction setMaterial(object) {\n if (object.children && object.children.length && object.children.length > 0) {\n object.children.map(child => setMaterial(child));\n } else if (object.material) {\n object.material.wireframe = true;\n object.material.opacity = 0.6;\n }\n}\n\n\nconst airPorts = [\n {\n name: '常德桃花源机场',\n lng: 111.641101,\n lat: 28.91165\n },\n {\n name: '芷江机场',\n lng: 109.709699,\n lat: 27.442172\n },\n {\n name: '铜仁凤凰机场',\n lng: 109.313971,\n lat: 27.880629\n },\n {\n name: '永州零陵机场',\n lng: 111.616049,\n lat: 26.335053\n },\n {\n name: '桂林两江国际机场',\n lng: 110.049256,\n lat: 25.210065\n },\n {\n name: '长沙黄花国际机场',\n lng: 113.216412,\n lat: 28.183613\n },\n {\n name: '井冈山机场',\n lng: 114.745845,\n lat: 26.852646\n }\n];\nconst planeTarget = {\n lng2: 111.616049,\n lat2: 26.335053\n};\nconst airLineData = [\n {\n name: '常德桃花源机场',\n lng: 111.641101,\n lat: 28.91165,\n ...planeTarget\n },\n {\n name: '芷江机场',\n lng: 109.709699,\n lat: 27.442172,\n ...planeTarget\n },\n {\n name: '铜仁凤凰机场',\n lng: 109.313971,\n lat: 27.880629,\n ...planeTarget\n },\n {\n name: '桂林两江国际机场',\n lng: 110.049256,\n lat: 25.210065,\n ...planeTarget\n },\n {\n name: '长沙黄花国际机场',\n lng: 113.216412,\n lat: 28.183613,\n ...planeTarget\n },\n {\n name: '井冈山机场',\n lng: 114.745845,\n lat: 26.852646,\n ...planeTarget\n }\n];\n\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 113, 29 ],\n pitch: 70,\n zoom: 7.5,\n rotation: 170,\n style: 'blank'\n })\n});\nscene.setBgColor('#000');\n\nscene.registerRenderService(ThreeRender);\n\nconst threeJSLayer = new ThreeLayer({\n enableMultiPassRenderer: false,\n // @ts-ignore\n onAddMeshes: (threeScene, layer) => {\n threeScene.add(new THREE.AmbientLight(0xffffff));\n const sunlight = new THREE.DirectionalLight(0xffffff, 0.25);\n sunlight.position.set(0, 800000, 1000000);\n sunlight.matrixWorldNeedsUpdate = true;\n threeScene.add(sunlight);\n\n // 使用 Three.js glTFLoader 加载模型\n const loader = new GLTFLoader();\n loader.load(\n 'https://gw.alipayobjects.com/os/bmw-prod/3ca0a546-92d8-4ba0-a89c-017c218d5bea.gltf',\n gltf => {\n const antModel = gltf.scene;\n setMaterial(antModel);\n layer.adjustMeshToMap(antModel);\n layer.setMeshScale(antModel, 2000, 2000, 2000);\n layer.setObjectLngLat(\n antModel,\n [ 113, 29 ],\n 0\n );\n\n const animations = gltf.animations;\n if (animations && animations.length) {\n const mixer = new THREE.AnimationMixer(antModel);\n const animation = animations[1];\n const action = mixer.clipAction(animation);\n action.timeScale = 1;\n action.play();\n layer.addAnimateMixer(mixer);\n }\n antModel.rotation.y = Math.PI;\n threeScene.add(antModel);\n layer.render();\n return '';\n }\n );\n },\n zIndex: 1\n});\n\nscene.addImage(\n 'plane',\n 'https://gw.alipayobjects.com/zos/bmw-prod/96327aa6-7fc5-4b5b-b1d8-65771e05afd8.svg'\n);\nconst airPrtsLayer = new PointLayer()\n .source(airPorts, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n })\n .shape('name', 'text')\n .color('rgb(22,119,255)')\n .size(10);\n\nconst airLineLayer = new LineLayer({ blend: 'normal' })\n .source(airLineData, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat',\n x1: 'lng2',\n y1: 'lat2'\n }\n })\n .shape('arc3d')\n .size(1)\n .color('#f00')\n .style({\n sourceColor: 'rgb(22,119,255)',\n targetColor: 'rgba(242,246,250,0.1)'\n });\n\nconst airPlaneLayer = new LineLayer({ blend: 'normal', zIndex: 1 })\n .source(airLineData, {\n parser: {\n type: 'json',\n x: 'lng2',\n y: 'lat2',\n x1: 'lng',\n y1: 'lat'\n }\n })\n .shape('arc3d')\n .texture('plane')\n .size(30)\n .color('#f00')\n .animate({\n duration: 0.2,\n interval: 0.2,\n trailLength: 0.2\n })\n .style({\n textureBlend: 'replace',\n lineTexture: true, // 开启线的贴图功能\n iconStep: 6 // 设置贴图纹理的间距\n });\n\n\nfetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/ec5351c9-d22b-4918-ad6c-1838064d3a64.json'\n)\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data)\n .size(10000)\n .shape('wall')\n .style({\n opacity: 0.4,\n sourceColor: '#0DCCFF',\n targetColor: 'rbga(255,255,255, 0)',\n heightfixed: true\n });\n scene.addLayer(layer);\n\n const nameLayer = new PointLayer({ zIndex: 3 })\n .source(data)\n .color('rgb(22,119,255)')\n .size(15)\n .shape('name', 'text');\n scene.addLayer(nameLayer);\n });\n\nconst img = new Image();\nimg.crossOrigin = 'none';\nimg.src =\n 'https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*UkvYRYS5jTAAAAAAAAAAAAAAARQnAQ';\nimg.onload = function() {\n const data = getImageData(img);\n const rData = getR(data.data);\n const d1 = getLngData(rData);\n const d2 = getLatData(rData);\n const geoData = {\n type: 'FeatureCollection',\n features: [\n {\n type: 'Feature',\n properties: {},\n geometry: {\n type: 'MultiLineString',\n coordinates: d1\n }\n },\n {\n type: 'Feature',\n properties: {},\n geometry: {\n type: 'MultiLineString',\n coordinates: d2\n }\n }\n ]\n };\n const layer = new LineLayer({})\n .source(geoData)\n .size(1)\n .shape('simple')\n .color('rgb(22, 119, 255)')\n .style({\n vertexHeightScale: 2000,\n opacity: 0.4\n });\n scene.addLayer(layer);\n};\nconst pointData = [\n { lng: 113, lat: 29, size: 10000 },\n { lng: 113.5, lat: 29.5, size: 30000 },\n { lng: 110.23681640625, lat: 29.64509464986076, size: 74020.50373907911 }, \n { lng: 115.01586914062499, lat: 26.88777988202911, size: 22908.885529976185 }, \n { lng: 111.181640625, lat: 28.724313406473463, size: 73359.37302978932 }, \n { lng: 112.686767578125, lat: 29.257648503615542, size: 18500.90838085843 }, \n { lng: 114.664306640625, lat: 28.98892237190413, size: 20293.183968726793 }, \n { lng: 113.90075683593749, lat: 28.17855984939698, size: 18051.412077639496 }, \n { lng: 111.51123046875, lat: 27.45466493898314, size: 37645.94186119526 }, \n { lng: 110.67626953125, lat: 28.004101830368654, size: 4214.588023703825 }, \n { lng: 114.43359375, lat: 29.477861195816843, size: 61722.01580332115 }, \n { lng: 110.445556640625, lat: 26.96124577052697, size: 70806.75519747598 }, \n { lng: 113.75244140624999, lat: 27.88278388425912, size: 70930.24993464859 }\n];\nconst waveLayer = new PointLayer({ zIndex: 2, blend: 'additive' })\n .source(pointData,\n {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n }\n )\n .shape('circle')\n .color('rgb(22, 119, 255)')\n .size('size', v => v)\n .animate(true)\n .style({\n unit: 'meter'\n });\n\nconst barLayer = new PointLayer({ zIndex: 2, depth: false })\n .source(pointData,\n {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n }\n )\n .shape('cylinder')\n .color('rgb(22, 119, 255)')\n .size('size', v => [ 5, 5, v / 350 ])\n .animate(true)\n .style({\n opacityLinear: {\n enable: true,\n dir: 'up'\n },\n lightEnable: false\n });\n\nscene.on('loaded', () => {\n scene.addLayer(waveLayer);\n scene.addLayer(barLayer);\n scene.addLayer(threeJSLayer);\n\n scene.addLayer(airPrtsLayer);\n scene.addLayer(airLineLayer);\n scene.addLayer(airPlaneLayer);\n});\n",title:"网格地图",filename:"grid.js",isNew:!1},{id:"build_sweep",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*TVs2R4bBH6wAAAAAAAAAAAAAARQnAQ",source:"import { Scene, CityBuildingLayer, LineLayer, PolygonLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 120.145, 30.238915 ],\n pitch: 60,\n zoom: 13.2\n })\n});\nfetch(\n 'https://gw.alipayobjects.com/os/rmsportal/ggFwDClGjjvpSMBIrcEx.json'\n).then(async res => {\n const pointLayer = new CityBuildingLayer();\n pointLayer\n .source(await res.json())\n .size('floor', [ 0, 500 ])\n .color('rgba(242,246,250,1.0)')\n .animate({\n enable: true\n })\n .active({\n color: '#0ff',\n mix: 0.5\n })\n .style({\n opacity: 0.7,\n baseColor: 'rgb(16, 16, 16)',\n windowColor: 'rgb(30, 60, 89)',\n brightColor: 'rgb(255, 176, 38)',\n sweep: {\n enable: true,\n sweepRadius: 2,\n sweepColor: '#1990FF',\n sweepSpeed: 0.5,\n sweepCenter: [ 120.145319, 30.238915 ]\n }\n });\n scene.addLayer(pointLayer);\n});\n\nfetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/67130c6c-7f49-4680-915c-54e69730861d.json'\n)\n .then(data => data.json())\n .then(\n ({\n lakeBorderData,\n lakeData,\n landData\n }) => {\n const lakeLayer = new PolygonLayer()\n .source(lakeData)\n .shape('fill')\n .color('#1E90FF')\n .style({\n opacity: 0.4,\n opacityLinear: {\n enable: true,\n dir: 'out' // in - out\n }\n });\n const landLayer = new PolygonLayer()\n .source(landData)\n .shape('fill')\n .color('#3CB371')\n .style({\n opacity: 0.4,\n opacityLinear: {\n enable: true,\n dir: 'in' // in - out\n }\n });\n\n const lakeBorderLayer = new PolygonLayer()\n .source(lakeBorderData)\n .shape('fill')\n .color('#ccc')\n .style({\n opacity: 0.5,\n opacityLinear: {\n enable: true,\n dir: 'in' // in - out\n }\n });\n\n scene.addLayer(lakeLayer);\n scene.addLayer(lakeBorderLayer);\n scene.addLayer(landLayer);\n }\n );\n\nfetch(\n 'https://gw.alipayobjects.com/os/basement_prod/40ef2173-df66-4154-a8c0-785e93a5f18e.json'\n)\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({\n zIndex: 0,\n depth: true\n })\n .source(data)\n .size(1)\n .shape('line')\n .color('#1990FF')\n .animate({\n interval: 1, // 间隔\n duration: 2, // 持续时间,延时\n trailLength: 2 // 流线长度\n });\n scene.addLayer(layer);\n });\n",title:"圆形扫光城市",filename:"build_sweep.js",isNew:!1},{id:"wind",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*K6NHRL_fjTQAAAAAAAAAAAAAARQnAQ",source:"import { Scene, WindLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 105.732421875, 32.24997445586331 ],\n style: 'dark',\n zoom: 2,\n })\n});\n\nscene.on('loaded', () => {\n const layer = new WindLayer({});\n layer\n .source(\n 'https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*wcU8S5xMEDYAAAAAAAAAAAAAARQnAQ',\n {\n parser: {\n type: 'image',\n extent: [ -180, -85, 180, 85 ]\n }\n }\n )\n .animate(true)\n .style({\n uMin: -21.32,\n uMax: 26.8,\n vMin: -21.57,\n vMax: 21.42,\n numParticles: 35535,\n fadeOpacity: 0.996,\n sizeScale: 1.2,\n rampColors: {\n 0.0: '#c6dbef',\n 0.1: '#9ecae1',\n 0.2: '#6baed6',\n 0.3: '#4292c6',\n 0.4: '#2171b5',\n 0.5: '#084594'\n }\n });\n scene.addLayer(layer);\n});\n",title:"风场图层",filename:"wind.js",isNew:!1},{id:"animate_path_texture",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*0DwvSIHihVEAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PolygonLayer, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 120.15, 30.246 ],\n zoom: 13.5,\n style: 'dark',\n pitchEnable: false,\n rotation: -90\n })\n});\n\nscene.on('loaded', () => {\n scene.addImage(\n 'arrow',\n 'https://gw.alipayobjects.com/zos/bmw-prod/ce83fc30-701f-415b-9750-4b146f4b3dd6.svg'\n );\n\n fetch('https://gw.alipayobjects.com/os/bmw-prod/67130c6c-7f49-4680-915c-54e69730861d.json')\n .then(data => data.json())\n .then(({ lakeBorderData, lakeData, landData }) => {\n const lakeLayer = new PolygonLayer()\n .source(lakeData)\n .shape('fill')\n .color('#1E90FF')\n .style({\n opacity: 0.4,\n opacityLinear: {\n enable: true,\n dir: 'out' // in - out\n }\n });\n const landLayer = new PolygonLayer()\n .source(landData)\n .shape('fill')\n .color('#3CB371')\n .style({\n opacity: 0.4,\n opacityLinear: {\n enable: true,\n dir: 'in' // in - out\n }\n });\n\n const lakeBorderLayer = new PolygonLayer()\n .source(lakeBorderData)\n .shape('fill')\n .color('#ccc')\n .style({\n opacity: 0.5,\n opacityLinear: {\n enable: true,\n dir: 'in' // in - out\n }\n });\n\n scene.addLayer(lakeLayer);\n scene.addLayer(lakeBorderLayer);\n scene.addLayer(landLayer);\n\n });\n\n\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/40ef2173-df66-4154-a8c0-785e93a5f18e.json'\n )\n .then(res => res.json())\n .then(data => {\n\n const layer = new LineLayer({})\n .source(data)\n .size(3)\n .shape('line')\n .texture('arrow')\n .color('rgb(22,119,255)')\n .animate({\n interval: 1, // 间隔\n duration: 1, // 持续时间,延时\n trailLength: 2 // 流线长度\n })\n .style({\n opacity: 0.6,\n lineTexture: true, // 开启线的贴图功能\n iconStep: 10, // 设置贴图纹理的间距\n borderWidth: 0.4, // 默认文 0,最大有效值为 0.5\n borderColor: '#fff' // 默认为 #ccc\n });\n scene.addLayer(layer);\n });\n});\n",title:"路径贴图",filename:"animate_path_texture.js",isNew:!1},{id:"turin",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*P1o6R7jm0JsAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 7.65, 45.053 ],\n zoom: 12,\n style: 'dark'\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/98a5d9ec-be97-44bd-bff0-5742d929c003.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data)\n .shape('line')\n .color('highway', v => {\n switch (v) {\n case 'motorway':\n return '#F9D371';\n case 'motorway_link':\n return '#3DB2FF';\n case 'trunk':\n return 'green';\n case 'trunk_link':\n return '#6E85B2';\n case 'primary':\n return '#F47340';\n case 'primary_link':\n return '#F6A9A9';\n case 'secondary':\n return '#EF2F88';\n case 'secondary_link':\n return '#5F7A61';\n case 'tertiary':\n return '#1ee3cf';\n case 'tertiary_link':\n return '#C2F784';\n case 'pedestrian':\n return '#FFF89A';\n case 'residential':\n return 'rgba(22, 119, 255, .5)';\n case 'road':\n return '#93FFD8';\n case 'path':\n return '#BAFFB4';\n case 'unclassified':\n return '#D3DEDC';\n case 'service':\n return '#AEFEFF';\n case 'living_street':\n return '#9B0000';\n case 'track':\n return '#F5F5F5';\n case 'highway':\n return 'red';\n case 'rail':\n return '#08ffc8';\n default:\n return '#FFE3E3';\n }\n })\n .animate({\n interval: 1, // 间隔\n duration: 1, // 持续时间,延时\n trailLength: 2 // 流线长度\n });\n scene.addLayer(layer);\n });\n});\n\n",title:"都灵道路图",filename:"turin.js",isNew:!1}],icon:"",id:"animate",title:{en:"Recommend",zh:"推荐"},childrenKey:"demos",order:0},{demos:[{id:"column_dark",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*FGjMT4CenkkAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 35.210526315789465,\n style: 'dark',\n center: [ 104.288144, 31.239692 ],\n zoom: 4.4\n })\n});\nconsole.log('111');\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/oVTMqfzuuRFKiDwhPSFL.json')\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data.list, {\n parser: {\n type: 'json',\n x: 'j',\n y: 'w'\n }\n })\n .shape('cylinder')\n .size('t', function(level) {\n return [ 2, 2, level * 2 + 20 ];\n })\n .animate(true)\n .active(true)\n .color('t', [\n '#094D4A',\n '#146968',\n '#1D7F7E',\n '#289899',\n '#34B6B7',\n '#4AC5AF',\n '#5FD3A6',\n '#7BE39E',\n '#A1EDB8',\n '#CEF8D6'\n ])\n scene.addLayer(pointLayer);\n });\n});\n",title:"3D柱图深色",filename:"column_dark.js",isNew:!1},{id:"arc-circle",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*hX_VQ5q77xMAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 107.77791556935472, 35.443286920228644 ],\n zoom: 2.9142882493605033\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/UEXQMifxtkQlYfChpPwT.txt')\n .then(res => res.text())\n .then(data => {\n const layer = new LineLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'lng1',\n y: 'lat1',\n x1: 'lng2',\n y1: 'lat2'\n }\n })\n .size(1)\n .shape('arc')\n .color('#8C1EB2')\n .style({\n opacity: 0.8,\n blur: 0.99\n });\n scene.addLayer(layer);\n });\n});\n",title:"弧线地图",filename:"arc-circle.js",isNew:!1},{id:"bus_dark",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*cvU2R7WFfeAAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 103.83735604457024, 1.360253881403068 ],\n pitch: 4.00000000000001,\n zoom: 10.210275860702593,\n rotation: 19.313180925794313\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/ee07641d-5490-4768-9826-25862e8019e1.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data, {\n parser: {\n coordinates: 'path',\n type: 'json'\n }\n })\n .size('level', level => {\n return [ 1.0, level * 1 ];\n })\n .shape('line')\n .color(\n 'level',\n [\n '#312B60',\n '#4A457E',\n '#615C99',\n '#816CAD',\n '#A67FB5',\n '#C997C7',\n '#DEB8D4',\n '#F5D4E6',\n '#FAE4F1',\n '#FFF3FC'\n ].slice(0, 8)\n );\n scene.addLayer(layer);\n });\n});\n",title:"公交线路深色",filename:"bus_dark.js",isNew:!1},{id:"light",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*PtMUR6hsN9EAAAAAAAAAAAAAARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n pitch: 43,\n center: [ 120.13383079335335, 29.651873105004427 ],\n zoom: 7.068989519212174\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/a1a8158d-6fe3-424b-8e50-694ccf61c4d7.csv'\n )\n .then(res => res.text())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'lng',\n y: 'lat'\n },\n transforms: [\n {\n type: 'hexagon',\n size: 2500,\n field: 'v',\n method: 'sum'\n }\n ]\n })\n .size('sum', sum => {\n return sum * 1000000;\n })\n .shape('hexagonColumn')\n .style({\n coverage: 0.8,\n angle: 0,\n })\n .color('sum', [\n '#094D4A',\n '#146968',\n '#1D7F7E',\n '#289899',\n '#34B6B7',\n '#4AC5AF',\n '#5FD3A6',\n '#7BE39E',\n '#A1EDB8',\n '#C3F9CC',\n '#DEFAC0',\n '#ECFFB1'\n ]);\n scene.addLayer(layer);\n });\n});\n",title:"蜂窝图3D",filename:"light.js",isNew:!1},{id:"point",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*OiQxQKq-P9MAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 64.88,\n style: 'dark',\n center: [ 114.060288, 22.53684 ],\n zoom: 15.63\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/513add53-dcb2-4295-8860-9e7aa5236699.json'\n )\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data)\n .size(2)\n .color('h8', [\n '#0A3663',\n '#1558AC',\n '#3771D9',\n '#4D89E5',\n '#64A5D3',\n '#72BED6',\n '#83CED6',\n '#A6E1E0',\n '#B8EFE2',\n '#D7F9F0'\n ]);\n\n scene.addLayer(pointLayer);\n });\n});\n",title:"海量点",filename:"point.js",isNew:!1},{id:"normal",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*qI2gRo_w0XoAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 121.417463, 31.215175 ],\n style: 'dark',\n zoom: 11\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/BElVQFEFvpAKzddxFZxJ.txt')\n .then(res => res.text())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n y: 'lat',\n x: 'lng'\n }\n })\n .size(0.5)\n .color('#080298');\n\n scene.addLayer(pointLayer);\n });\n});\n",title:"亮度图",filename:"normal.js",isNew:!1}],icon:"",id:"basic",title:{en:"Featured",zh:"基础可视化"},childrenKey:"demos",order:1}],childrenKey:"examples"},{id:"point",title:{zh:"点图层",en:"Point Layer"},icon:"point",examples:[{demos:[{id:"point",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*BGJfT5GYaZAAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 140.067171, 36.26186 ],\n zoom: 5.32,\n maxZoom: 10\n })\n});\nscene.on('loaded', () => {\n const plane = initPlane();\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/d3564b06-670f-46ea-8edb-842f7010a7c6.json'\n )\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data)\n .shape('circle')\n .size('mag', [ 1, 25 ])\n .color('mag', mag => {\n return mag > 4.5 ? '#5B8FF9' : '#5CCEA1';\n })\n .active(true)\n .style({\n opacity: 0.3,\n strokeWidth: 1\n });\n scene.addLayer(pointLayer);\n pointLayer.on('click', e => {\n const { lng, lat } = e.lngLat;\n scene.setCenter([ lng, lat ], {\n padding: {\n right: 120\n }\n });\n plane.style.right = '0px';\n plane.innerHTML = `\n

click info\n

featureId: ${e.featureId}

\n

lng: ${lng}

\n

lat: ${lat}

\n `;\n });\n pointLayer.on('unclick', () => {\n plane.style.right = '-120px';\n scene.setCenter([ 140.067171, 36.26186 ], {\n padding: {\n right: 0\n }\n });\n });\n });\n});\n\nfunction initPlane() {\n const el = document.createElement('div');\n el.style.background = '#fff';\n el.style.position = 'absolute';\n el.style.padding = '10px';\n el.style.top = '0';\n el.style.right = '-120px';\n el.style.width = '100px';\n el.style.height = '100%';\n el.style.zIndex = '10';\n el.style.transition = '0.5s';\n // el.innerText = '123'\n const wrap = document.getElementById('map');\n wrap.appendChild(el);\n return el;\n}\n",title:"气泡图(点击拾取)",filename:"point.js",isNew:!1},{id:"color",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*p48-TK_yGZ8AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap} from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 121.435159, 31.256971 ],\n zoom: 14.89,\n minZoom: 10\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/893d1d5f-11d9-45f3-8322-ee9140d288ae.json'\n )\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data, {\n parser: {\n type: 'json',\n x: 'longitude',\n y: 'latitude'\n }\n })\n .shape('name', [\n 'circle',\n 'triangle',\n 'square',\n 'pentagon',\n 'hexagon',\n 'octogon',\n 'hexagram',\n 'rhombus',\n 'vesica'\n ])\n .size('unit_price', [ 10, 25 ])\n .active(true)\n .color('name', [ '#5B8FF9', '#5CCEA1', '#5D7092', '#F6BD16', '#E86452' ])\n .style({\n opacity: 0.3,\n strokeWidth: 2\n });\n\n scene.addLayer(pointLayer);\n });\n});\n",title:"形状映射",filename:"color.js",isNew:!1},{id:"world",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*ecV4T63Yk40AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 96.99215001469588, 29.281597225674773 ],\n zoom: 2.194613775109773,\n maxZoom: 10\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/337ddbb7-aa3f-4679-ab60-d64359241955.json'\n )\n .then(res => res.json())\n .then(data => {\n data.features = data.features.filter(item => {\n return item.properties.capacity > 800;\n });\n const pointLayer = new PointLayer({})\n .source(data)\n .shape('circle')\n .size('capacity', [ 0, 16 ])\n .color('capacity', [\n '#34B6B7',\n '#4AC5AF',\n '#5FD3A6',\n '#7BE39E',\n '#A1EDB8',\n '#CEF8D6'\n ])\n .active(true)\n .style({\n opacity: 0.5,\n strokeWidth: 0\n });\n\n scene.addLayer(pointLayer);\n });\n});\n",title:"气泡图",filename:"world.js",isNew:!1},{id:"scatter",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*Jd4HQpnWQaQAAAAAAAAAAAAAARQnAQ",source:"window.onLoad = function(err){ \n console.log('完成',err)\n}\nvar url = 'https://webapi.amap.com/maps?v=2.0&key=ff533602d57df6f8ab3b0fea226ae52f&callback=onLoad';\nvar jsapi = document.createElement('script');\njsapi.charset = 'utf-8';\njsapi.src = url;\ndocument.head.appendChild(jsapi);\n// const scene = new Scene({\n// id: 'map',\n// map: new GaodeMapV2({\n// style: 'dark',\n// version:'2.1.0',\n// center: [ 112, 23.69 ],\n// zoom: 2.5\n// })\n// });\n// scene.on('loaded', () => {\n// fetch(\n// 'https://gw.alipayobjects.com/os/basement_prod/9078fd36-ce8d-4ee2-91bc-605db8315fdf.csv'\n// )\n// .then(res => res.text())\n// .then(data => {\n// const pointLayer = new PointLayer({})\n// .source(data, {\n// parser: {\n// type: 'csv',\n// x: 'Longitude',\n// y: 'Latitude'\n// }\n// })\n// .shape('circle')\n// .active(true)\n// .animate(true)\n// .size(56)\n// .color('#4cfd47');\n\n// scene.addLayer(pointLayer);\n// });\n// });\n",title:"气泡图动画",filename:"scatter.js",isNew:!1}],icon:"",id:"bubble",title:{en:"Bubble Map",zh:"气泡地图"},childrenKey:"demos",order:0},{demos:[{id:"cluster",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*_KdAR67mrNUAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 120.19382669582967, 30.258134 ],\n style: 'dark',\n zoom: 3\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/basement_prod/d3564b06-670f-46ea-8edb-842f7010a7c6.json')\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data, {\n cluster: true\n })\n .shape('circle')\n .scale('point_count', {\n type: 'quantile'\n })\n .size('point_count', [ 5, 10, 15, 20, 25 ])\n .active(true)\n .color('yellow')\n .style({\n opacity: 0.5,\n strokeWidth: 1\n });\n\n scene.addLayer(pointLayer);\n });\n});\n",title:"聚合图",filename:"cluster.js",isNew:!1},{id:"cluster2",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*ATjEQKEScq8AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer, Source } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 120.19382669582967, 30.258134 ],\n style: 'dark',\n zoom: 3\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/bmw-prod/87e40417-a5da-4fdb-8313-c796ea15f982.csv')\n .then(res => res.text())\n .then(data => {\n const dataSource = new Source(data, {\n parser: {\n type: 'csv',\n x: 'lng',\n y: 'lat'\n\n },\n cluster: true\n });\n const pointLayer = new PointLayer({\n autoFit: true\n })\n .source(dataSource)\n .shape('circle')\n .scale('point_count', {\n type: 'quantile'\n })\n .size('point_count', [ 5, 10, 15, 20, 25 ])\n .active(true)\n .color('rgb(73,167,86)')\n .style({\n strokeWidth: 1,\n stroke: '#fff'\n });\n\n // 聚合图标注\n const pointLayerText = new PointLayer({\n autoFit: false\n })\n .source(dataSource)\n .shape('point_count', 'text')\n .size(15)\n .active(true)\n .color('#fff')\n .style({\n strokeWidth: 0,\n stroke: '#fff'\n });\n\n scene.addLayer(pointLayer);\n scene.addLayer(pointLayerText);\n });\n});\n",title:"充电桩分布聚合图",filename:"cluster2.js",isNew:!1}],icon:"",id:"cluster",title:{en:"Cluster Map",zh:"聚合图"},childrenKey:"demos",order:1},{demos:[{id:"normal2",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*OiQxQKq-P9MAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 64.88,\n style: 'dark',\n center: [ 114.060288, 22.53684 ],\n zoom: 15.63\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/513add53-dcb2-4295-8860-9e7aa5236699.json'\n )\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data)\n .size(2)\n .color('h8', [\n '#0A3663',\n '#1558AC',\n '#3771D9',\n '#4D89E5',\n '#64A5D3',\n '#72BED6',\n '#83CED6',\n '#A6E1E0',\n '#B8EFE2',\n '#D7F9F0'\n ]);\n\n scene.addLayer(pointLayer);\n });\n});\n",title:"城市亮度图",filename:"normal2.js",isNew:!1},{id:"normal",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*qI2gRo_w0XoAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 121.417463, 31.215175 ],\n zoom: 11\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/BElVQFEFvpAKzddxFZxJ.txt')\n .then(res => res.text())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n y: 'lat',\n x: 'lng'\n }\n })\n .size(0.5)\n .color('#080298');\n\n scene.addLayer(pointLayer);\n });\n});\n",title:"海量点",filename:"normal.js",isNew:!1}],icon:"",id:"dot",title:{en:"Dot Intensity",zh:"亮度图"},childrenKey:"demos",order:1},{demos:[{id:"scatter",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*hH8lT6AWcqEAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ -121.24357, 37.58264 ],\n zoom: 6.45\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/6c4bb5f2-850b-419d-afc4-e46032fc9f94.csv'\n )\n .then(res => res.text())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'Longitude',\n y: 'Latitude'\n }\n })\n .shape('circle')\n .size(4)\n .active(true)\n .color('Magnitude', [\n '#0A3663',\n '#1558AC',\n '#3771D9',\n '#4D89E5',\n '#64A5D3',\n '#72BED6',\n '#83CED6',\n '#A6E1E0',\n '#B8EFE2',\n '#D7F9F0'\n ])\n .style({\n opacity: 0.5,\n strokeWidth: 0\n });\n\n scene.addLayer(pointLayer);\n });\n});\n",title:"散点图",filename:"scatter.js",isNew:!1},{id:"scatterstylemap",screenshot:"https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*F_QoSr-W0BwAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 112, 30.267069 ],\n style: 'dark',\n zoom: 6\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/bmw-prod/450b2d95-006c-4bad-8269-15729269e142.json')\n .then(res => res.json())\n .then(data => {\n const layer = new PointLayer()\n .source(data, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n })\n .shape('circle')\n .color('color')\n .size('value', v => 5 + 15 * v)\n .style({\n stroke: 'strokeColor',\n strokeWidth: 'strokeWidth',\n strokeOpacity: [\n 'strokeOpacity',\n d => {\n return d * 2;\n }\n ],\n\n opacity: 'opacity'\n })\n .active(true);\n scene.addLayer(layer);\n });\n\n});\n",title:"样式映射散点",filename:"scatterstylemap.js",isNew:!1},{id:"blur",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*v7v6SacA_5AAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 112, 30.267069 ],\n style: 'dark',\n zoom: 3.8\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/bmw-prod/450b2d95-006c-4bad-8269-15729269e142.json')\n .then(res => res.json())\n .then(data => {\n const layer = new PointLayer({ blend: 'additive' })\n .source(data, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n })\n .shape('circle')\n .color('#f00')\n .size('value', v => 15 + 15 * v)\n .style({\n blur: 2.5,\n opacity: 'opacity'\n })\n .active(true);\n scene.addLayer(layer);\n });\n\n});\n",title:"模糊点",filename:"blur.js",isNew:!1},{id:"animatepoint",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*N7KDR4kfIDQAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 112, 23.69 ],\n zoom: 2.5\n })\n});\n\nfetch(\n 'https://gw.alipayobjects.com/os/basement_prod/9078fd36-ce8d-4ee2-91bc-605db8315fdf.csv'\n)\n .then(res => res.text())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'Longitude',\n y: 'Latitude'\n }\n })\n .shape('circle')\n .active(true)\n .animate(true)\n .size(40)\n .color('#ffa842')\n .style({\n offsets: [ 40, 40 ]\n });\n const pointLayer2 = new PointLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'Longitude',\n y: 'Latitude'\n }\n })\n .shape('circle')\n .active(true)\n .animate(true)\n .size(50)\n .color('#f00');\n\n scene.addLayer(pointLayer);\n scene.addLayer(pointLayer2);\n });\n",title:"水波散点",filename:"animatepoint.js",isNew:!1},{id:"radarpoint",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*nfAwRaTOYj0AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 120, 30 ],\n zoom: 13\n })\n});\n\nconst layer = new PointLayer()\n .source(\n [\n {\n lng: 120,\n lat: 30\n }\n ],\n {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n }\n )\n .shape('radar')\n .size(100)\n .color('#d00')\n .style({\n speed: 5\n })\n .animate(true);\n\nscene.on('loaded', () => {\n scene.addLayer(layer);\n});\n",title:"雷达图",filename:"radarpoint.js",isNew:!1}],icon:"",id:"scatter",title:{en:"Scatter Map",zh:"散点地图"},childrenKey:"demos",order:1},{demos:[{id:"point_text",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*QAfOQr1alNoAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 110, 36 ],\n style: 'light',\n zoom: 3\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/oVTMqfzuuRFKiDwhPSFL.json')\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data.list, {\n parser: {\n type: 'json',\n x: 'j',\n y: 'w'\n }\n })\n .shape('m', 'text')\n .size(12)\n .color('w', [ '#0e0030', '#0e0030', '#0e0030' ])\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n textOffset: [ 0, 0 ], // 文本相对锚点的偏移量 [水平, 垂直]\n spacing: 2, // 字符间距\n padding: [ 1, 1 ], // 文本包围盒 padding [水平,垂直],影响碰撞检测结果,避免相邻文本靠的太近\n stroke: '#ffffff', // 描边颜色\n strokeWidth: 0.3, // 描边宽度\n strokeOpacity: 1.0\n });\n\n scene.addLayer(pointLayer);\n });\n\n});\n",title:"点数据标注",filename:"point_text.js",isNew:!1},{id:"polygon_text",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*1iRfT56__38AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PolygonLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ -96, 37.8 ],\n zoom: 3\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/d36ad90e-3902-4742-b8a2-d93f7e5dafa2.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new PolygonLayer({})\n .source(data)\n .color('blue')\n .shape('name', 'text')\n .size(18)\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n textOffset: [ 0, 0 ], // 文本相对锚点的偏移量 [水平, 垂直]\n spacing: 2, // 字符间距\n padding: [ 1, 1 ], // 文本包围盒 padding [水平,垂直],影响碰撞检测结果,避免相邻文本靠的太近\n stroke: '#ffffff', // 描边颜色\n strokeWidth: 0.3, // 描边宽度\n strokeOpacity: 1.0\n });\n scene.addLayer(layer);\n });\n});\n",title:"面数据标注",filename:"polygon_text.js",isNew:!1},{id:"iconfont",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*1Ox-T7mht18AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 110, 30 ],\n style: 'amap://styles/453e2f8e11603fc8f7548fe18959e9e9',\n zoom: 5\n })\n});\nconst fontFamily = 'iconfont';\nconst fontPath = '//at.alicdn.com/t/font_2534097_fcae9o2mxbv.woff2?t=1622200439140';\nscene.addFontFace(fontFamily, fontPath);\nscene.addIconFont('icon1', '');\n\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/70408903-80db-4278-a318-461604acb2df.json'\n )\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data.list, {\n parser: {\n type: 'json',\n x: 'j',\n y: 'w'\n }\n })\n .shape('icon', 'text')\n .size(20)\n .color('w', [ '#a6cee3', '#1f78b4', '#b2df8a', '#33a02c', '#fb9a99' ])\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n padding: [ 0, 0 ], // 文本包围盒 padding [水平,垂直],影响碰撞检测结果,避免相邻文本靠的太近\n stroke: '#ffffff', // 描边颜色\n fontFamily,\n iconfont: true,\n textAllowOverlap: true\n });\n scene.addLayer(pointLayer);\n });\n});\n",title:"图标标注",filename:"iconfont.js",isNew:!1},{id:"iconfonts",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*NCz5R7YA3VIAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 120.5, 30.2 ],\n style: 'dark',\n zoom: 8.5,\n zooms: [ 8, 10 ]\n })\n});\nconst fontFamily = 'iconfont';\nconst fontPath = '//at.alicdn.com/t/font_2534097_ao9soua2obv.woff2?t=1622021146076';\nscene.addFontFace(fontFamily, fontPath);\nscene.addIconFonts([\n [ 'smallRain', '' ],\n [ 'middleRain', '' ],\n [ 'hugeRain', '' ],\n [ 'sun', '' ],\n [ 'cloud', '' ]\n]);\n\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/bmw-prod/9eb3f1b5-0c3b-49b2-8221-191d4ba8aa5e.json')\n .then(res => res.json())\n .then(originData => {\n const layer = new PointLayer()\n .source(originData, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n })\n .shape('circle')\n .color('backgoundColor')\n .size(42);\n scene.addLayer(layer);\n\n const pointIconFontLayer = new PointLayer({})\n .source(originData, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n }\n )\n .shape('iconType', 'text')\n .size(30)\n .color('iconColor')\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n textOffset: [ -10, 10 ], // 文本相对锚点的偏移量 [水平, 垂直]\n fontFamily,\n iconfont: true,\n textAllowOverlap: true\n });\n scene.addLayer(pointIconFontLayer);\n\n const textLayer = new PointLayer({})\n .source(originData,\n {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n }\n )\n .shape('temperature', 'text')\n .size(10)\n .color('#ffffff')\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n textOffset: [ 5, -55 ], // 文本相对锚点的偏移量 [水平, 垂直]\n spacing: 2, // 字符间距\n padding: [ 1, 1 ], // 文本包围盒 padding [水平,垂直],影响碰撞检测结果,避免相邻文本靠的太近\n stroke: '#ffffff', // 描边颜色\n strokeWidth: 0.3, // 描边宽度\n strokeOpacity: 1.0,\n fontFamily: 'Times New Roman',\n textAllowOverlap: true\n });\n scene.addLayer(textLayer);\n\n const textLayer2 = new PointLayer({})\n .source(originData,\n {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n }\n )\n .shape('weather', 'text')\n .size(14)\n .color('#ffffff')\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n textOffset: [ 5, -15 ], // 文本相对锚点的偏移量 [水平, 垂直]\n spacing: 2, // 字符间距\n padding: [ 1, 1 ], // 文本包围盒 padding [水平,垂直],影响碰撞检测结果,避免相邻文本靠的太近\n stroke: '#ffffff', // 描边颜色\n strokeWidth: 0.3, // 描边宽度\n strokeOpacity: 1.0,\n fontFamily: 'Times New Roman',\n textAllowOverlap: true\n });\n scene.addLayer(textLayer2);\n });\n\n\n});\n",title:"天气图标标注",filename:"iconfonts.js",isNew:!1},{id:"stylemap",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*cfShR4lVaUYAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 120.5, 30.2 ],\n style: 'dark',\n zoom: 7.5,\n zooms: [ 8, 10 ]\n })\n});\n\nconst fontFamily = 'iconfont';\nconst fontPath =\n '//at.alicdn.com/t/font_2534097_ao9soua2obv.woff2?t=1622021146076';\nscene.addIconFonts([\n [ 'smallRain', '' ],\n [ 'middleRain', '' ],\n [ 'hugeRain', '' ],\n [ 'sun', '' ],\n [ 'cloud', '' ]\n]);\nscene.addFontFace(fontFamily, fontPath);\nscene.on('loaded', () => {\n\n fetch('https://gw.alipayobjects.com/os/bmw-prod/f7d083e2-ad55-44fd-b324-15e1b549948a.json')\n .then(res => res.json())\n .then(data => {\n const pointIconFontLayer = new PointLayer({})\n .source(data, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n })\n .shape('iconType', 'text')\n .size(30)\n .color('iconColor')\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n textOffset: 'textOffset', // 文本相对锚点的偏移量 [水平, 垂直]\n fontFamily,\n iconfont: true,\n textAllowOverlap: true\n });\n scene.addLayer(pointIconFontLayer);\n\n const textLayer = new PointLayer({})\n .source(data, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n })\n .shape('weather', 'text')\n .size(16)\n .color('#fff')\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n textOffset: [ 0, 0 ], // 文本相对锚点的偏移量 [水平, 垂直]\n spacing: 2, // 字符间距\n padding: [ 1, 1 ], // 文本包围盒 padding [水平,垂直],影响碰撞检测结果,避免相邻文本靠的太近\n fontFamily: 'Times New Roman',\n textAllowOverlap: true\n });\n scene.addLayer(textLayer);\n });\n\n});\n",title:"文本动态偏移",filename:"stylemap.js",isNew:!1},{id:"temperture",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*nvwuQIi8_9oAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer, PolygonLayer, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n pitch: 40,\n center: [ 118.8, 32.056 ],\n zoom: 12.5\n })\n});\nconst fontFamily = 'iconfont';\nconst fontPath =\n '//at.alicdn.com/t/font_2534097_x6rsov3i1g.woff2?t=1622107341225';\nscene.addIconFont('icon', '');\nscene.addFontFace(fontFamily, fontPath);\n\nconst colors = [\n '#87CEFA',\n '#00BFFF',\n\n '#7FFFAA',\n '#00FF7F',\n '#32CD32',\n\n '#F0E68C',\n '#FFD700',\n\n '#FF7F50',\n '#FF6347',\n '#FF0000'\n];\n\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/bmw-prod/94763191-2816-4c1a-8d0d-8bcf4181056a.json')\n .then(res => res.json())\n .then(data => {\n\n const filllayer = new PolygonLayer({\n name: 'fill',\n zIndex: 3\n })\n .source(data)\n .shape('fill')\n .color('count', [ '#f2f0f7', '#dadaeb', '#bcbddc', '#9e9ac8', '#756bb1', '#54278f' ])\n .style({\n opacity: 0.6,\n opacityLinear: {\n enable: true,\n dir: 'out' // in - out\n }\n });\n scene.addLayer(filllayer);\n\n const linelayer = new LineLayer({\n zIndex: 5,\n name: 'line2'\n })\n .source(data)\n .shape('line')\n .size(1)\n .color('#fff')\n .style({\n opacity: 0.3\n });\n scene.addLayer(linelayer);\n\n const pointLayer = new PointLayer({\n zIndex: 10\n })\n .source(data)\n .shape('icon', 'text')\n .size(25)\n .color('count', t => {\n const c = Number(t.replace('℃', ''));\n return colors[Math.floor(((c - 18) / 16) * 10)];\n })\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n textOffset: [ -25, 15 ],\n padding: [ 2, 2 ],\n fontFamily,\n iconfont: true,\n textAllowOverlap: true\n });\n scene.addLayer(pointLayer);\n\n const tempertureLayer = new PointLayer({\n zIndex: 10\n })\n .source(data)\n .shape('count', 'text')\n .size(12)\n .color('count', t => {\n const c = Number(t.replace('℃', ''));\n return colors[Math.floor(((c - 18) / 16) * 10)];\n })\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n textOffset: [ 35, 30 ],\n padding: [ 1, 1 ]\n });\n scene.addLayer(tempertureLayer);\n\n });\n});\n",title:"气温图标标注",filename:"temperture.js",isNew:!1},{id:"simplecoordinate",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*OXlZRKw7AoUAAAAAAAAAAAAAARQnAQ",source:"import { Scene, ImageLayer, PointLayer } from '@antv/l7';\nimport { Map } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new Map({\n center: [ 500, 500 ],\n zoom: 3,\n version: 'SIMPLE',\n mapSize: 1000,\n maxZoom: 5,\n minZoom: 2,\n pitchEnabled: false,\n rotateEnabled: false\n })\n});\nscene.setBgColor('rgb(94, 182, 140)');\n\nconst imagelayer = new ImageLayer({}).source(\n 'https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*I0X5R4jAUQ4AAAAAAAAAAAAAARQnAQ',\n {\n parser: {\n type: 'image',\n extent: [ 360, 400, 640, 600 ]\n }\n }\n);\n\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/bmw-prod/7dc0d454-fabc-4461-a5d5-d404dadb49a9.json')\n .then(res => res.json())\n .then(data => {\n const textlayer = new PointLayer({ zIndex: 2 })\n .source(\n data,\n {\n parser: {\n type: 'json',\n x: 'x',\n y: 'y'\n }\n }\n )\n .shape('t', 'text')\n .size(12)\n .active({\n color: '#00f',\n mix: 0.9\n })\n .color('rgb(86, 156, 214)')\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n spacing: 2, // 字符间距\n fontWeight: '800',\n padding: [ 1, 1 ], // 文本包围盒 padding [水平,垂直],影响碰撞检测结果,避免相邻文本靠的太近\n stroke: '#ffffff', // 描边颜色\n strokeWidth: 2, // 描边宽度\n textAllowOverlap: true\n });\n scene.addLayer(textlayer);\n });\n\n scene.addLayer(imagelayer);\n\n});\n",title:"平面区域标注",filename:"simplecoordinate.js",isNew:!1}],icon:"",id:"text",title:{en:"label",zh:"文本标注"},childrenKey:"demos",order:1},{demos:[{id:"image",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*uzwBSLxwZGMAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 121.434765, 31.256735 ],\n zoom: 14.83\n })\n});\nscene.addImage(\n '00',\n 'https://gw.alipayobjects.com/zos/basement_prod/604b5e7f-309e-40db-b95b-4fac746c5153.svg'\n);\nscene.addImage(\n '01',\n 'https://gw.alipayobjects.com/zos/basement_prod/30580bc9-506f-4438-8c1a-744e082054ec.svg'\n);\nscene.addImage(\n '02',\n 'https://gw.alipayobjects.com/zos/basement_prod/7aa1f460-9f9f-499f-afdf-13424aa26bbf.svg'\n);\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/893d1d5f-11d9-45f3-8322-ee9140d288ae.json'\n )\n .then(res => res.json())\n .then(data => {\n const imageLayer = new PointLayer()\n .source(data, {\n parser: {\n type: 'json',\n x: 'longitude',\n y: 'latitude'\n }\n })\n .shape('name', [ '00', '01', '02' ])\n .size(25);\n scene.addLayer(imageLayer);\n });\n});\n",title:"符号图",filename:"image.js",isNew:!1},{id:"locate",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*rkFFQYBOJt4AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 116.276227, 35.256776 ],\n zoom: 6\n })\n});\nscene.addImage(\n 'marker',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*BJ6cTpDcuLcAAAAAAAAAAABkARQnAQ'\n);\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/e2fc6e0a-af2a-4320-96e5-d9f5a5fda442.json'\n )\n .then(res => res.json())\n .then(data => {\n \n const imageLayer = new PointLayer()\n .source(data)\n .shape('marker')\n .size(12);\n scene.addLayer(imageLayer);\n });\n});\n",title:"精确符号",filename:"locate.js",isNew:!1},{id:"weather",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*CC5YRp2OY3gAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 120.5969, 29.7918 ],\n pitch: 35,\n zoom: 7,\n rotation: 4.183582\n })\n});\nscene.on('loaded', () => {\n scene.addImage(\n '00',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*kzTMQqS2QdUAAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '01',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*jH1XRb7F7hMAAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '02',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*YaKSTr3L5i8AAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '04',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*dmniQrDpCYwAAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '11',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*YaKSTr3L5i8AAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '15',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*YNlXQYCIzroAAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '07',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*DccRTI6ZRLoAAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '16',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*iQKoS6I-rO8AAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '06',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*f-wyS7ad5p0AAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '08',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*lHhzQrOW4AQAAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '17',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*9Q0QS4GdaYcAAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '05',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*LyuVRowl6nAAAAAAAAAAAABkARQnAQ'\n );\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/c6042c6b-45fd-4e2e-adf8-fdbf060441e8.json'\n )\n .then(res => res.json())\n .then(data => {\n const imageLayer = new PointLayer()\n .source(data)\n .shape('w', function(w) {\n return w;\n })\n .size(15);\n scene.addLayer(imageLayer);\n });\n});\n",title:"天气",filename:"weather.js",isNew:!1},{id:"monsoon",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*Zq5ZTKNeU6sAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 105, 35 ],\n zoom: 2.5\n })\n});\n\n\nscene.addImage(\n 'arrRed',\n 'https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*KWGqT6Oz50EAAAAAAAAAAAAAARQnAQ'\n);\nscene.addImage(\n 'arrBlue',\n 'https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*ZKhURq53OgIAAAAAAAAAAAAAARQnAQ'\n);\n\nscene.on('loaded', () => {\n\n fetch('https://gw.alipayobjects.com/os/bmw-prod/4c02515b-cb7a-47be-93cf-5596731ef982.json')\n .then(res => res.json())\n .then(monsoon => {\n const { data, borderData } = monsoon;\n const imageLayer = new PointLayer()\n .source(data)\n .shape('wind', wind => {\n if (wind === 'up') {\n return 'arrBlue';\n }\n return 'arrRed';\n\n })\n .rotate('r', r => Math.PI * r)\n .size(15)\n .style({\n rotation: 0,\n layerType: 'fillImage'\n });\n scene.addLayer(imageLayer);\n\n\n const border = new LineLayer()\n .source(borderData)\n .size(1.5)\n .color('#575757')\n .style({\n lineType: 'dash',\n dashArray: [ 5, 5 ]\n });\n scene.addLayer(border);\n\n const text = new PointLayer({ zIndex: 2 })\n .source([\n { lng: 90, lat: 35, n: '非季风区' },\n { lng: 125, lat: 30, n: '季风区' }\n ], {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n })\n .shape('n', 'text')\n .size(25)\n .color('#575757')\n .style({\n spacing: 20\n });\n\n scene.addLayer(text);\n });\n\n\n});\n",title:"季风分布",filename:"monsoon.js",isNew:!1}],icon:"",id:"image",title:{en:"Symbol Map",zh:"符号地图"},childrenKey:"demos",order:2},{demos:[{id:"column_light",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*UGw1T6ms2D0AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer, Popup } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 60,\n style: 'dark',\n center: [ 110, 31.847 ],\n rotation: 0,\n zoom: 4\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/oVTMqfzuuRFKiDwhPSFL.json')\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({ depth: false })\n .source(data.list, {\n parser: {\n type: 'json',\n x: 'j',\n y: 'w'\n }\n })\n .shape('cylinder')\n .size('t', function(level) {\n return [ 1, 1, level * 2 + 20 ];\n })\n .active(true)\n .color('#006CFF')\n .style({\n opacity: 0.6,\n opacityLinear: {\n enable: true, // true - false\n dir: 'up' // up - down\n },\n lightEnable: false\n });\n pointLayer.on('mousemove', e => {\n const popup = new Popup({\n offsets: [ 0, 0 ],\n closeButton: false\n })\n .setLnglat(e.lngLat)\n .setHTML(`${e.feature.s}: ${e.feature.t}℃`);\n scene.addPopup(popup);\n });\n scene.addLayer(pointLayer);\n });\n});\n",title:"3D柱图 光标",filename:"column_light.js",isNew:!1},{id:"column_linear",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*GJhASbfQTK8AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer, Popup } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 70,\n style: 'dark',\n center: [ 105, 31.847 ],\n rotation: 0,\n zoom: 4.2\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/oVTMqfzuuRFKiDwhPSFL.json')\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({ depth: false })\n .source(data.list, {\n parser: {\n type: 'json',\n x: 'j',\n y: 'w'\n }\n })\n .shape('cylinder')\n .size('t', function(level) {\n return [ 1, 1, level * 2 + 20 ];\n })\n .animate(true)\n .active(true)\n .color('#006CFF')\n .style({\n opacity: 0.8,\n sourceColor: 'red',\n targetColor: 'yellow',\n lightEnable: false\n });\n pointLayer.on('mousemove', e => {\n const popup = new Popup({\n offsets: [ 0, 0 ],\n closeButton: false\n })\n .setLnglat(e.lngLat)\n .setHTML(`${e.feature.s}: ${e.feature.t}℃`);\n scene.addPopup(popup);\n });\n scene.addLayer(pointLayer);\n });\n});\n",title:"3D 渐变柱图",filename:"column_linear.js",isNew:!1},{id:"column_dark",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*FG4fT7h5AYMAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 40,\n style: 'dark',\n center: [ 104.288144, 31.239692 ],\n zoom: 4.4\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/oVTMqfzuuRFKiDwhPSFL.json')\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data.list, {\n parser: {\n type: 'json',\n x: 'j',\n y: 'w'\n }\n })\n .shape('cylinder')\n .size('t', function(level) {\n return [ 2, 2, level * 2 + 20 ];\n })\n .animate(true)\n .active(true)\n .color('t', [\n '#094D4A',\n '#146968',\n '#1D7F7E',\n '#289899',\n '#34B6B7',\n '#4AC5AF',\n '#5FD3A6',\n '#7BE39E',\n '#A1EDB8',\n '#CEF8D6'\n ]);\n scene.addLayer(pointLayer);\n });\n});\n",title:"3D柱图 深色底图",filename:"column_dark.js",isNew:!1},{id:"clumn_shape",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*9EoxQpBxNyIAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 66.02383,\n style: 'dark',\n center: [ 121.400257, 31.25287 ],\n zoom: 14.55,\n rotation: 134.95\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/893d1d5f-11d9-45f3-8322-ee9140d288ae.json'\n )\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data, {\n parser: {\n type: 'json',\n x: 'longitude',\n y: 'latitude'\n }\n })\n .animate(true)\n .active(true)\n .shape('name', [\n 'cylinder',\n 'triangleColumn',\n 'hexagonColumn',\n 'squareColumn'\n ])\n .size('unit_price', h => {\n return [ 6, 6, h / 500 ];\n })\n .color('name', [ '#739DFF', '#61FCBF', '#FFDE74', '#FF896F' ]);\n\n scene.addLayer(pointLayer);\n });\n});\n",title:"3D 深色柱图",filename:"clumn_shape.js",isNew:!1}],icon:"",id:"column",title:{en:"Column Map",zh:"3D 柱状地图"},childrenKey:"demos",order:4},{demos:[{id:"simple",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*NHMmTr0SMFQAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 20,\n style: 'light',\n center: [ 120, 20 ],\n zoom: 3\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/d3564b06-670f-46ea-8edb-842f7010a7c6.json'\n )\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data)\n .shape('simple')\n .size(15)\n .color('mag', mag => {\n return mag > 4.5 ? '#5B8FF9' : '#5CCEA1';\n })\n .active(true)\n .style({\n opacity: 0.6,\n strokeWidth: 3\n });\n scene.addLayer(pointLayer);\n });\n});\n",title:"简单点图层",filename:"simple.js",isNew:!1}],icon:"",id:"simple",title:{en:"Simple Point",zh:"简单点"},childrenKey:"demos",order:4},{demos:[{id:"custom",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*7FgbRppWc38AAAAAAAAAAAAAARQnAQ",source:"import { Scene, CanvasLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nlet x = 0;\nfunction draw(option) {\n const { size, ctx, mapService } = option;\n const [ width, height ] = size;\n\n const radius = 30,\n rectWidth = radius * 2;\n const rectHeight = rectWidth;\n\n ctx.clearRect(0, 0, width, height);\n\n const points = [\n {\n lng: 108.544921875,\n lat: 30.977609093348686,\n level: 85,\n color: 'rgba(\t220,20,60, 0.6)'\n },\n {\n lng: 110.654296875,\n lat: 31.090574094954192,\n level: 75,\n color: 'rgba(\t255,140,0, 0.6)'\n },\n {\n lng: 112.5,\n lat: 29.80251790576445,\n level: 65,\n color: 'rgba(255,165,0, 0.6)'\n },\n {\n lng: 114.78515624999999,\n lat: 30.64867367928756,\n level: 40,\n color: 'rgba(30,144,255, 0.6)'\n },\n {\n lng: 116.49902343749999,\n lat: 29.84064389983441,\n level: 50,\n color: 'rgba(30,144,255, 0.6)'\n },\n {\n lng: 118.21289062499999,\n lat: 31.16580958786196,\n level: 20,\n color: 'rgba(\t127,255,0, 0.6)'\n },\n {\n lng: 119.091796875,\n lat: 32.509761735919426,\n level: 50,\n color: 'rgba(30,144,255, 0.6)'\n },\n {\n lng: 121.0693359374999,\n lat: 31.80289258670676,\n level: 45,\n color: 'rgba(30,144,255, 0.6)'\n }\n ];\n ctx.fillStyle = 'rgb(35,75,225)';\n ctx.font = 'normal small-caps bold 14px arial';\n ctx.textAlign = 'center';\n ctx.textBaseline = 'middle';\n\n points.map(point => {\n const pixelCenter = mapService.lngLatToContainer([ point.lng, point.lat ]);\n pixelCenter.x *= window.devicePixelRatio;\n pixelCenter.y *= window.devicePixelRatio;\n const rectStartX = pixelCenter.x - radius;\n const rectStartY = pixelCenter.y - radius;\n\n ctx.save();\n\n ctx.fillText(point.level + '%', pixelCenter.x, pixelCenter.y);\n\n ctx.beginPath();\n ctx.arc(pixelCenter.x, pixelCenter.y, radius, 0, Math.PI * 2);\n ctx.fillStyle = 'rgba(135,206,250,0.2)';\n ctx.closePath();\n ctx.fill();\n ctx.clip();\n\n ctx.beginPath();\n ctx.fillStyle = point.color;\n ctx.moveTo(rectStartX, pixelCenter.y);\n\n const waterheight = rectStartY + ((100 - point.level) / 100) * rectHeight;\n for (let i = 0; i <= rectWidth; i += 10) {\n ctx.lineTo(\n rectStartX + i,\n waterheight + Math.sin(Math.PI * 2 * (i / rectWidth) + x) * 3 + 1\n );\n }\n\n ctx.lineTo(pixelCenter.x + radius, pixelCenter.y + radius);\n ctx.lineTo(rectStartX, pixelCenter.y + radius);\n ctx.lineTo(rectStartX, pixelCenter.y);\n ctx.closePath();\n\n ctx.fill();\n\n ctx.restore();\n return '';\n });\n return '';\n}\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'fresh',\n center: [ 115, 31 ],\n zoom: 5.0\n })\n});\nscene.on('loaded', () => {\n const layer = new CanvasLayer({})\n .style({\n zIndex: 10,\n update: 'always',\n drawingOnCanvas: draw\n })\n .animate({\n enable: true\n });\n scene.addLayer(layer);\n\n setInterval(() => {\n x += 0.1;\n layer.style({\n drawingOnCanvas: draw\n });\n scene.render();\n return '';\n }, 30);\n return '';\n});\n\n",title:"自定义水位图",filename:"custom.js",isNew:!1},{id:"custom2",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*SsiSTaYwCBgAAAAAAAAAAAAAARQnAQ",source:"import { Scene, CanvasLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'fresh',\n center: [ 90, 31 ],\n zoom: 2\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/337ddbb7-aa3f-4679-ab60-d64359241955.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new CanvasLayer({})\n .style({\n zIndex: 10,\n update: 'dragend',\n drawingOnCanvas: option => {\n const { size, ctx, mapService } = option;\n const [ width, height ] = size;\n\n ctx.clearRect(0, 0, width, height);\n ctx.fillStyle = 'rgba(0, 200, 0, 0.2)';\n data.features.map(feature => {\n const pixelCenter = mapService.lngLatToContainer(\n feature.geometry.coordinates\n );\n pixelCenter.x *= window.devicePixelRatio;\n pixelCenter.y *= window.devicePixelRatio;\n if (\n pixelCenter.x < 0 ||\n pixelCenter.y < 0 ||\n pixelCenter.x > width ||\n pixelCenter.y > height\n ) { return ''; }\n ctx.beginPath();\n ctx.arc(\n pixelCenter.x,\n pixelCenter.y,\n feature.properties.capacity / 200,\n 0,\n Math.PI * 2\n );\n ctx.fill();\n ctx.closePath();\n return '';\n });\n return '';\n }\n });\n\n scene.addLayer(layer);\n return '';\n });\n return '';\n});\n\n",title:"自定义气泡图",filename:"custom2.js",isNew:!1},{id:"bar",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*XEPUSISnWUAAAAAAAAAAAAAAARQnAQ",source:"import { Scene, Marker } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport * as G2 from '@antv/g2';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [2.6125016864608597, 49.359131],\n zoom: 4.19,\n }),\n});\nscene.on('loaded', () => {\n addChart();\n scene.render();\n});\nfunction addChart() {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/0b96cca4-7e83-449a-93d0-2a77053e74ab.json',\n )\n .then((res) => res.json())\n .then((data) => {\n data.nodes.forEach(function (item) {\n const el = document.createElement('div');\n const total =\n item.gdp.Agriculture + item.gdp.Industry + item.gdp.Service;\n\n const size = Math.min(parseInt(total / 30000, 10), 70);\n if (size < 30) {\n return;\n }\n const itemData = [\n {\n item: 'Agriculture',\n count: item.gdp.Agriculture,\n percent: item.gdp.Agriculture / total,\n },\n {\n item: 'Industry',\n count: item.gdp.Industry,\n percent: item.gdp.Industry / total,\n },\n {\n item: 'Service',\n count: item.gdp.Service,\n percent: item.gdp.Service / total,\n },\n ];\n\n const chart = new G2.Chart({\n container: el,\n width: size,\n height: size,\n render: 'svg',\n padding: 0,\n });\n chart.legend(false);\n chart.data(itemData);\n chart.tooltip(false);\n\n chart.axis('count', false);\n chart.axis('item', false);\n chart\n .interval()\n .position('item*count')\n .color('item', ['#5CCEA1', '#5D7092', '#5B8FF9']);\n chart.render();\n const marker = new Marker({\n element: el,\n }).setLnglat({\n lng: item.coordinates[0],\n lat: item.coordinates[1],\n });\n scene.addMarker(marker);\n });\n });\n}\n",title:"柱图",filename:"bar.js",isNew:!1},{id:"chart",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*EqfuRqkVZG4AAAAAAAAAAAAAARQnAQ",source:"import { Scene, Marker } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport * as G2 from '@antv/g2';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [2.6125016864608597, 49.359131],\n zoom: 4.19\n })\n});\nscene.on('loaded', () => {\n addChart();\n scene.render();\n});\nfunction addChart() {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/0b96cca4-7e83-449a-93d0-2a77053e74ab.json'\n )\n .then(res => res.json())\n .then(data => {\n data.nodes.forEach(function (item) {\n const el = document.createElement('div');\n const total =\n item.gdp.Agriculture + item.gdp.Industry + item.gdp.Service;\n\n const size = Math.min(parseInt(total / 30000, 10), 70);\n if (size < 30) {\n return;\n }\n const itemData = [\n {\n item: 'Agriculture',\n count: item.gdp.Agriculture,\n percent: item.gdp.Agriculture / total\n },\n {\n item: 'Industry',\n count: item.gdp.Industry,\n percent: item.gdp.Industry / total\n },\n {\n item: 'Service',\n count: item.gdp.Service,\n percent: item.gdp.Service / total\n }\n ];\n\n const chart = new G2.Chart({\n container: el,\n width: size,\n height: size,\n render: 'svg',\n padding: 0\n });\n console.log(chart)\n chart.legend(false);\n chart.data(itemData);\n chart.coord('theta', {\n innerRadius: 0.6\n });\n chart.tooltip(false);\n chart\n .interval()\n .adjust('stack')\n .position('percent').color('item', ['#5CCEA1', '#5D7092', '#5B8FF9'])\n .shape('sliceShape')\n chart.render();\n const marker = new Marker({\n element: el\n }).setLnglat({\n lng: item.coordinates[0],\n lat: item.coordinates[1]\n });\n scene.addMarker(marker);\n });\n });\n}\n",title:"环图",filename:"chart.js",isNew:!1}],icon:"",id:"chart",title:{en:"Chart Map",zh:"复合图表地图"},childrenKey:"demos",order:6}],childrenKey:"examples"},{id:"line",title:{zh:"线图层",en:"Line Layer"},icon:"line",examples:[{demos:[{id:"shanghai_bus",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*EkhYRbNGkswAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 121.472644, 31.231706 ],\n zoom: 8.15,\n style: 'dark'\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/0290a972-eedd-42f6-b69e-50a35e8a0824.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data, {\n parser: {\n type: 'json',\n coordinates: 'coordinates'\n }\n })\n .size(0.5)\n .shape('line')\n .active(true)\n .color('length', [\n '#0A3663',\n '#1558AC',\n '#3771D9',\n '#4D89E5',\n '#64A5D3',\n '#72BED6',\n '#83CED6',\n '#A6E1E0',\n '#B8EFE2',\n '#D7F9F0'\n ]);\n scene.addLayer(layer);\n });\n});\n",title:"上海公交",filename:"shanghai_bus.js",isNew:!1},{id:"bus_light",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*sSx9TIOthmkAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer, Popup } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 103.83735604457024, 1.360253881403068 ],\n zoom: 9.4678190476727,\n pitch: 20,\n style: 'light'\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/ee07641d-5490-4768-9826-25862e8019e1.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data, {\n parser: {\n type: 'json',\n coordinates: 'path'\n }\n })\n .size('level', level => {\n return [ 0.8, level * 0.1 ];\n })\n .shape('line')\n .active(true)\n .color(\n 'level',\n [\n '#0A3663',\n '#1558AC',\n '#3771D9',\n '#4D89E5',\n '#64A5D3',\n '#72BED6',\n '#83CED6',\n '#A6E1E0',\n '#B8EFE2',\n '#D7F9F0'\n ]\n .reverse()\n .slice(0, 8)\n );\n layer.on('mousemove', e => {\n const popup = new Popup({\n offsets: [ 0, 0 ],\n closeButton: false\n })\n .setLnglat(e.lngLat)\n .setHTML(`车次: ${e.feature.number}`);\n scene.addPopup(popup);\n });\n scene.addLayer(layer);\n });\n});\n",title:"3D 公交线路-亮",filename:"bus_light.js",isNew:!1},{id:"bus_dark",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*92cnRJiUIf4AAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 103.83735, 1.3602538 ],\n zoom: 9.4678190476727,\n pitch: 20,\n style: 'dark'\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/ee07641d-5490-4768-9826-25862e8019e1.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data, {\n parser: {\n type: 'json',\n coordinates: 'path'\n }\n })\n .size('level', level => {\n return [ 0.8, level * 0.1 ];\n })\n .shape('line')\n .color(\n 'level',\n [\n '#312B60',\n '#4A457E',\n '#615C99',\n '#816CAD',\n '#A67FB5',\n '#C997C7',\n '#DEB8D4',\n '#F5D4E6',\n '#FAE4F1',\n '#FFF3FC'\n ].slice(0, 8)\n );\n scene.addLayer(layer);\n });\n});\n",title:"3D 公交线路-暗",filename:"bus_dark.js",isNew:!1},{id:"road_dark",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*Zq3ORrdexZwAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 116.3956, 39.9392 ],\n pitch: 20,\n zoom: 10,\n style: 'dark'\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/0d2f0113-f48b-4db9-8adc-a3937243d5a3.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data)\n .size(4)\n .shape('line')\n .color('标准名称', [ '#5B8FF9', '#5CCEA1', '#F6BD16' ])\n .style({\n borderWidth: 0.4,\n borderColor: '#fff'\n });\n scene.addLayer(layer);\n });\n});\n\n",title:"路径边框",filename:"road_dark.js",isNew:!1},{id:"road_dark_dash",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*vZFUTaBCGoEAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 116.3956, 39.9392 ],\n zoom: 10,\n style: 'dark'\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/0d2f0113-f48b-4db9-8adc-a3937243d5a3.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data)\n .size(1.5)\n .shape('line')\n .color('标准名称', [ '#5B8FF9', '#5CCEA1', '#F6BD16' ])\n .style({\n lineType: 'dash',\n dashArray: [ 5, 5 ]\n })\n ;\n scene.addLayer(layer);\n });\n});\n",title:"路径虚线",filename:"road_dark_dash.js",isNew:!1},{id:"arrow",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*glWTSoFfy1sAAAAAAAAAAAAAARQnAQ",source:"import {\n Scene,\n LineLayer,\n PointLayer\n} from '@antv/l7';\nimport {\n GaodeMap\n} from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 120.15, 30.3 ],\n zoom: 10,\n style: 'light'\n })\n});\n\nconst pointLayer = new PointLayer()\n .source([{ lng: 120.155, lat: 30.31 }], {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n })\n .shape('circle')\n .size(6000)\n .color('#f00')\n .animate(true)\n .style({\n unit: 'meter'\n });\nconst lineLayer = new LineLayer({})\n .source({\n type: 'FeatureCollection',\n features: [\n {\n type: 'Feature',\n properties: {},\n geometry: {\n type: 'LineString',\n coordinates: [\n [\n 120.1863098144,\n 30.321915039121\n ],\n [\n 120.3401184082,\n 30.43446594614\n ]\n ]\n }\n },\n {\n type: 'Feature',\n properties: {},\n geometry: {\n type: 'LineString',\n coordinates: [\n [\n 120.19660949707033,\n 30.298796461361665\n ],\n [\n 120.31883239746092,\n 30.28041626667403\n ]\n ]\n }\n },\n {\n type: 'Feature',\n properties: {},\n geometry: {\n type: 'LineString',\n coordinates: [\n [\n 120.12245178222656,\n 30.29523927312319\n ],\n [\n 120.01808166503906,\n 30.261439550638762\n ]\n ]\n }\n },\n {\n type: 'Feature',\n properties: {},\n geometry: {\n type: 'LineString',\n coordinates: [\n [\n 120.15609741210938,\n 30.285159872426014\n ],\n [\n 120.14923095703124,\n 30.20626765511821\n ]\n ]\n }\n },\n {\n type: 'Feature',\n properties: {},\n geometry: {\n type: 'LineString',\n coordinates: [\n [\n 120.10940551757812,\n 30.320136880604423\n ],\n [\n 120.01327514648438,\n 30.362803774813028\n ]\n ]\n }\n }\n ]\n }\n )\n .size(2)\n .shape('line')\n .style({\n arrow: {\n enable: true,\n arrowWidth: 4,\n arrowHeight: 4,\n tailWidth: 0.4\n }\n })\n .color('#f00');\nscene.on('loaded', () => {\n scene.addLayer(pointLayer);\n scene.addLayer(lineLayer);\n});\n",title:"箭头路径",filename:"arrow.js",isNew:!1}],icon:"",id:"path",title:{en:"Path Map",zh:"路径地图"},childrenKey:"demos",order:0},{demos:[{id:"wind_animate",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*wH50SZfOywcAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 60, 40.7128 ],\n zoom: 2\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/7455fead-1dc0-458d-b91a-fb4cf99e701e.txt'\n )\n .then(res => res.text())\n .then(data => {\n const layer = new LineLayer({ blend: 'normal' })\n .source(data,\n {\n parser: {\n type: 'csv',\n x: 'lng1',\n y: 'lat1',\n x1: 'lng2',\n y1: 'lat2'\n }\n })\n .size(1)\n .shape('arc')\n .color('#6495ED')\n .animate({\n duration: 4,\n interval: 0.2,\n trailLength: 0.6\n });\n // .forward(false)\n scene.addLayer(layer);\n });\n});\n",title:"风场动画",filename:"wind_animate.js",isNew:!1},{id:"line_animate",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*eckNS70gTfwAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 107.77791556935472, 35.443286920228644 ],\n zoom: 2.9142882493605033\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/UEXQMifxtkQlYfChpPwT.txt')\n .then(res => res.text())\n .then(data => {\n const layer = new LineLayer({\n blend: 'normal'\n })\n .source(data, {\n parser: {\n type: 'csv',\n x: 'lng1',\n y: 'lat1',\n x1: 'lng2',\n y1: 'lat2'\n }\n })\n .size(1)\n .shape('greatcircle')\n .animate({\n enable: true,\n interval: 0.1,\n trailLength: 0.5,\n duration: 2\n })\n .color('#8C1EB2')\n .style({\n opacity: 0.8\n });\n scene.addLayer(layer);\n });\n});\n",title:"直线动画",filename:"line_animate.js",isNew:!1},{id:"plane_animate2",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*2wDIS5hXKYwAAAAAAAAAAAAAARQnAQ",source:"/* eslint-disable no-eval */\nimport { Scene, LineLayer, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 40,\n center: [ 40, 40.16797 ],\n style: 'dark',\n zoom: 2.5\n })\n});\nscene.addImage(\n 'plane',\n 'https://gw.alipayobjects.com/zos/bmw-prod/0ca1668e-38c2-4010-8568-b57cb33839b9.svg'\n);\nscene.on('loaded', () => {\n Promise.all([\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/2960e1fc-b543-480f-a65e-d14c229dd777.json'\n ).then(d => d.json()),\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/4472780b-fea1-4fc2-9e4b-3ca716933dc7.json'\n ).then(d => d.text()),\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/a5ac7bce-181b-40d1-8a16-271356264ad8.json'\n ).then(d => d.text())\n ]).then(function onLoad([ world, dot, flyline ]) {\n const dotData = eval(dot);\n // @ts-ignore\n const flydata = eval(flyline).map(item => {\n // @ts-ignore\n const latlng1 = item.from.split(',').map(e => {\n return e * 1;\n });\n // @ts-ignore\n const latlng2 = item.to.split(',').map(e => {\n return e * 1;\n });\n return { coord: [ latlng1, latlng2 ] };\n });\n\n const worldLine = new LineLayer()\n .source(world)\n .color('#41fc9d')\n .size(0.5)\n .style({\n opacity: 0.4\n });\n const dotPoint = new PointLayer()\n .source(dotData, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n })\n .shape('circle')\n .color('#ffed11')\n .animate(true)\n .size(40);\n const flyLine = new LineLayer({ blend: 'normal' })\n .source(flydata, {\n parser: {\n type: 'json',\n coordinates: 'coord'\n }\n })\n .color('#ff6b34')\n .texture('plane')\n .shape('arc')\n .size(15)\n .animate({\n duration: 1,\n interval: 0.2,\n trailLength: 0.05\n })\n .style({\n textureBlend: 'replace',\n lineTexture: true, // 开启线的贴图功能\n iconStep: 10, // 设置贴图纹理的间距\n });\n\n const flyLine2 = new LineLayer()\n .source(flydata, {\n parser: {\n type: 'json',\n coordinates: 'coord'\n }\n })\n .color('#ff6b34')\n .shape('arc')\n .size(1)\n .style({\n lineType: 'dash',\n dashArray: [ 5, 5 ],\n opacity: 0.5\n });\n scene.addLayer(worldLine);\n scene.addLayer(dotPoint);\n scene.addLayer(flyLine2);\n scene.addLayer(flyLine);\n });\n});",title:"航向图",filename:"plane_animate2.js",isNew:!1},{id:"trip_animate",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*cmB1SLuyB1cAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 60,\n style: 'light',\n center: [ -74.05371169148452, 40.72573640479783 ],\n zoom: 12.45977,\n rotation: -38.39999999999969\n })\n});\n\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/bd33a685-a17e-4686-bc79-b0e6a89fd950.csv'\n )\n .then(res => res.text())\n .then(data => {\n const layer = new LineLayer({\n blend: 'normal'\n })\n .source(data, {\n parser: {\n type: 'csv',\n x: 'start station longitude',\n y: 'start station latitude',\n x1: 'end station longitude',\n y1: 'end station latitude'\n }\n })\n .size(2)\n .shape('arc3d')\n .color('#0C47BF')\n .animate({\n interval: 0.5,\n trailLength: 0.5,\n duration: 5\n })\n .style({\n opacity: 0.5\n });\n scene.addLayer(layer);\n });\n});\n",title:"3D 弧线动画",filename:"trip_animate.js",isNew:!1},{id:"animate_line",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*d7PjSo0izNAAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ -74.006, 40.7128 ],\n zoom: 14,\n style: 'dark'\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/5592c737-1c70-4d6b-82c1-e74e5a019b04.json'\n )\n .then(res => res.json())\n .then(data => {\n const lineLayer = new LineLayer()\n .source(data, {\n parser: {\n type: 'json',\n coordinates: 'path'\n }\n })\n .size(1.5)\n .shape('line')\n .color('color', v => {\n return `rgb(${v})`;\n })\n .animate({\n interval: 0.6,\n trailLength: 1.5,\n duration: 6\n });\n scene.addLayer(lineLayer);\n });\n});\n",title:"轨迹动画",filename:"animate_line.js",isNew:!1}],icon:"",id:"animate",title:{en:"Line Animate",zh:"线动画"},childrenKey:"demos",order:1},{demos:[{id:"arccircle",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*6Qm_QY69sBMAAAAAAAAAAABkARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 107.77791556935472, 35.443286920228644 ],\n zoom: 2.9142882493605033\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/UEXQMifxtkQlYfChpPwT.txt')\n .then(res => res.text())\n .then(data => {\n const layer = new LineLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'lng1',\n y: 'lat1',\n x1: 'lng2',\n y1: 'lat2'\n }\n })\n .size(1)\n .shape('greatcircle')\n .color('#8C1EB2')\n .style({\n opacity: 0.8\n });\n scene.addLayer(layer);\n });\n});\n",title:"大圆弧线",filename:"arccircle.js",isNew:!1},{id:"trip_arc_dark",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*Qg8sQ4H9RVsAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 60,\n style: 'dark',\n center: [ 104.34278, 41.12554 ],\n zoom: 2.94888,\n rotation: 42.3999\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/bmw-prod/e495c407-953b-44cc-8f77-87b9cf257578.json')\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data, {\n parser: {\n type: 'json',\n x: 'from_lon',\n y: 'from_lat',\n x1: 'to_lon',\n y1: 'to_lat'\n }\n })\n .size(1)\n .shape('arc3d')\n .color('#FF7C6A')\n .style({\n segmentNumber: 15,\n opacity: 0.8\n });\n scene.addLayer(layer);\n });\n});\n",title:"3D 弧线",filename:"trip_arc_dark.js",isNew:!1},{id:"trip_arc_dark_linear",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*8DYQTZeQyZ4AAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 57.999999999999964,\n style: 'dark',\n center: [ 101.94365594271085, 40.46139674355291 ],\n zoom: 2.7484264183323437,\n rotation: -21.600099999999884\n })\n});\n\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/UEXQMifxtkQlYfChpPwT.txt')\n .then(res => res.text())\n .then(data => {\n const layer = new LineLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'lng1',\n y: 'lat1',\n x1: 'lng2',\n y1: 'lat2'\n }\n })\n .size(1)\n .shape('arc3d')\n .color('#FF7C6A')\n .style({\n opacity: 0.8,\n sourceColor: '#f00',\n targetColor: '#6F19FF'\n });\n scene.addLayer(layer);\n });\n});\n",title:"3D 弧线(渐变)",filename:"trip_arc_dark_linear.js",isNew:!1},{id:"trip_arc",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*xvaaQo2c0gMAAAAAAAAAAABkARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 60,\n style: 'light',\n center: [ -74.06967, 40.720399 ],\n zoom: 12.45977\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/bd33a685-a17e-4686-bc79-b0e6a89fd950.csv'\n )\n .then(res => res.text())\n .then(data => {\n const layer = new LineLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'start station longitude',\n y: 'start station latitude',\n x1: 'end station longitude',\n y1: 'end station latitude'\n }\n })\n .size(1)\n .shape('arc3d')\n .color('#0C47BF')\n .style({\n blur: 0.9\n });\n scene.addLayer(layer);\n });\n});\n",title:"3D 弧线",filename:"trip_arc.js",isNew:!1}],icon:"",id:"arc",title:{en:"Arc Line Map",zh:"弧线地图"},childrenKey:"demos",order:1},{demos:[{id:"ele",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*p6LsTp3M144AAAAAAAAAAABkARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 53.6305,\n style: 'light',\n center: [ 102.600579, 23.114887 ],\n zoom: 13.5\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/ZVfOvhVCzwBkISNsuKCc.json')\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data)\n .size('ELEV', h => {\n return [ h % 50 === 0 ? 1.0 : 0.5, (h - 1400) * 20 ];\n })\n .shape('line')\n .scale('ELEV', {\n type: 'quantize'\n })\n .style({\n heightfixed: true\n })\n .color(\n 'ELEV',\n [\n '#E4682F',\n '#FF8752',\n '#FFA783',\n '#FFBEA8',\n '#FFDCD6',\n '#EEF3FF',\n '#C8D7F5',\n '#A5C1FC',\n '#7FA7F9',\n '#5F8AE5'\n ].reverse()\n );\n scene.addLayer(layer);\n });\n});\n",title:"等高线",filename:"ele.js",isNew:!1},{id:"ele_dark",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*jJd0Qq_E3_UAAAAAAAAAAABkARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 45.06995336442376,\n style: 'dark',\n center: [ 102.597971, 23.110479 ],\n zoom: 13.34,\n rotation: 360,\n })\n});\n\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/ZVfOvhVCzwBkISNsuKCc.json')\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({\n })\n .source(data)\n .size('ELEV', h => {\n return [ h % 50 === 0 ? 1.0 : 0.5, (h - 1400) * 20 ];\n })\n .shape('line')\n .scale('ELEV', {\n type: 'quantize'\n })\n .style({\n heightfixed: true\n })\n .color('ELEV', [\n '#094D4A',\n '#146968',\n '#1D7F7E',\n '#289899',\n '#34B6B7',\n '#4AC5AF',\n '#5FD3A6',\n '#7BE39E',\n '#A1EDB8',\n '#CEF8D6'\n ]);\n scene.addLayer(layer);\n });\n});\n",title:"等高线",filename:"ele_dark.js",isNew:!1},{id:"isoline",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*RLvsSbS4PJMAAAAAAAAAAABkARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 104.117492, 36.492696 ],\n zoom: 3.89\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/9f6afbcd-3aec-4a26-bd4a-2276d3439e0d.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data)\n .scale('value', {\n type: 'quantile'\n })\n .size('value', [ 0.5, 1, 1.5, 2 ])\n .shape('line')\n .color(\n 'value',\n [\n '#0A3663',\n '#1558AC',\n '#3771D9',\n '#4D89E5',\n '#64A5D3',\n '#72BED6',\n '#83CED6',\n '#A6E1E0',\n '#B8EFE2',\n '#D7F9F0'\n ].reverse()\n );\n scene.addLayer(layer);\n });\n});\n",title:"等高线",filename:"isoline.js",isNew:!1},{id:"height",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*AARcS4YKlTYAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 60,\n style: 'dark',\n center: [ 120.958472, 23.464292 ],\n zoom: 7.65,\n rotation: 33.375609237091055\n })\n});\n\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/65589ef3-7f1d-440f-ba5d-86b03ee6ba7e.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data)\n .size(1)\n .shape('line')\n .style({\n vertexHeightScale: 30\n })\n .color('#0D5EFF');\n\n scene.addLayer(layer);\n });\n});\n",title:"海拔线",filename:"height.js",isNew:!1}],icon:"",id:"isoline",title:{en:"Isoline Map",zh:"等值线地图"},childrenKey:"demos",order:2},{demos:[{id:"hangzhou_wall",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*aIKDQaTiGkkAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 119.297868, 29.732983 ],\n zoom: 7.11,\n rotation: 1.22,\n pitch: 45.42056074766357,\n style: 'dark'\n })\n});\n\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/93a55259-328e-4e8b-8dc2-35e05844ed31.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data)\n .size(40)\n .shape('wall')\n .style({\n opacity: 'testOpacity',\n sourceColor: '#0DCCFF',\n targetColor: 'rbga(255,255,255, 0)'\n });\n scene.addLayer(layer);\n });\n});\n",title:"杭州区县围墙",filename:"hangzhou_wall.js",isNew:!1},{id:"bus_wall",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*BmYdS7zoKvYAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 121.461531, 31.096775 ],\n zoom: 8.64,\n rotation: 358.78,\n pitch: 45.42056074766357,\n style: 'dark'\n })\n});\n\nscene.addImage(\n '02',\n 'https://gw.alipayobjects.com/zos/bmw-prod/ce83fc30-701f-415b-9750-4b146f4b3dd6.svg'\n);\n\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/0290a972-eedd-42f6-b69e-50a35e8a0824.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data.slice(0, 50), {\n parser: {\n type: 'json',\n coordinates: 'coordinates'\n }\n })\n .animate({\n interval: 1, // 间隔\n duration: 1, // 持续时间,延时\n trailLength: 2 // 流线长度\n })\n .size(20)\n .shape('wall')\n .texture('02')\n .style({\n opacity: 'testOpacity',\n lineTexture: true, // 开启线的贴图功能\n iconStep: 40, // 设置贴图纹理的间距\n iconStepCount: 4,\n sourceColor: '#00BCD2',\n targetColor: '#0074d0'\n });\n scene.addLayer(layer);\n });\n});\n",title:"公交线路围墙",filename:"bus_wall.js",isNew:!1}],icon:"",id:"wall",title:{en:"Line Wall",zh:"线路围墙"},childrenKey:"demos",order:5}],childrenKey:"examples"},{id:"polygon",title:{zh:"面图层",en:"Polygon Layer"},icon:"polygon",examples:[{demos:[{id:"polygon",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*ovizSr4Y-kYAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PolygonLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 114.050008, 22.529272 ],\n zoom: 14.1\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/972566c5-a2b9-4a7e-8da1-bae9d0eb0117.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new PolygonLayer({})\n .source(data)\n .shape('extrude')\n .size('h20', [ 100, 120, 160, 200, 260, 500 ])\n .color('h20', [\n '#816CAD',\n '#A67FB5',\n '#C997C7',\n '#DEB8D4',\n '#F5D4E6',\n '#FAE4F1',\n '#FFF3FC'\n ]);\n scene.addLayer(layer);\n });\n});\n",title:"3D 建筑面",filename:"polygon.js",isNew:!1},{id:"polygonstylemap",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*yxRiTJDOrS8AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PolygonLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n pitch: 50,\n center: [ 118.8, 32.056 ],\n zoom: 10\n })\n});\nconst colors = [\n '#87CEFA',\n '#00BFFF',\n\n '#7FFFAA',\n '#00FF7F',\n '#32CD32',\n\n '#F0E68C',\n '#FFD700',\n\n '#FF7F50',\n '#FF6347',\n '#FF0000'\n];\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/94763191-2816-4c1a-8d0d-8bcf4181056a.json'\n )\n .then(res => res.json())\n .then(data => {\n const filllayer = new PolygonLayer({\n name: 'fill',\n zIndex: 3\n })\n .source(data)\n .shape('extrude')\n .color('unit_price', colors)\n .size('unit_price', unit_price => unit_price * 50)\n .style({\n opacity: [ 'unit_price', [ 0, 1 ]],\n pickLight: true\n })\n .active(true);\n scene.addLayer(filllayer);\n });\n});\n",title:"3D 几何体样式映射",filename:"polygonstylemap.js",isNew:!1},{id:"floatmap",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*D8GeSKNZxWIAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PolygonLayer, LineLayer, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 120, 29.732983 ],\n zoom: 6.2,\n pitch: 60\n })\n});\nscene.on('loaded', () => {\n let lineDown,\n lineUp,\n textLayer;\n\n fetch('https://gw.alipayobjects.com/os/bmw-prod/ecd1aaac-44c0-4232-b66c-c0ced76d5c7d.json')\n .then(res => res.json())\n .then(data => {\n const texts = [];\n\n data.features.map(option => {\n const { name, center } = option.properties;\n const [ lng, lat ] = center;\n texts.push({ name, lng, lat });\n return '';\n });\n\n textLayer = new PointLayer({ zIndex: 2 })\n .source(texts, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n })\n .shape('name', 'text')\n .size(14)\n .color('#0ff')\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n spacing: 2, // 字符间距\n padding: [ 1, 1 ], // 文本包围盒 padding [水平,垂直],影响碰撞检测结果,避免相邻文本靠的太近\n stroke: '#0ff', // 描边颜色\n strokeWidth: 0.2, // 描边宽度\n raisingHeight: 200000 + 150000 + 10000,\n textAllowOverlap: true\n });\n scene.addLayer(textLayer);\n\n lineDown = new LineLayer()\n .source(data)\n .shape('line')\n .color('#0DCCFF')\n .size(1)\n .style({\n raisingHeight: 200000\n });\n\n lineUp = new LineLayer({ zIndex: 1 })\n .source(data)\n .shape('line')\n .color('#0DCCFF')\n .size(1)\n .style({\n raisingHeight: 200000 + 150000\n });\n\n scene.addLayer(lineDown);\n scene.addLayer(lineUp);\n return '';\n });\n\n fetch('https://gw.alipayobjects.com/os/bmw-prod/d434cac3-124e-4922-8eed-ccde01674cd3.json')\n .then(res => res.json())\n .then(data => {\n const lineLayer = new LineLayer()\n .source(data)\n .shape('wall')\n .size(150000)\n .style({\n heightfixed: true,\n opacity: 0.6,\n sourceColor: '#0DCCFF',\n targetColor: 'rbga(255,255,255, 0)'\n });\n scene.addLayer(lineLayer);\n\n const provincelayer = new PolygonLayer({})\n .source(data)\n .size(150000)\n .shape('extrude')\n .color('#0DCCFF')\n .active({\n color: 'rgb(100,230,255)'\n })\n .style({\n heightfixed: true,\n pickLight: true,\n raisingHeight: 200000,\n opacity: 0.8\n });\n\n scene.addLayer(provincelayer);\n\n provincelayer.on('mousemove', () => {\n provincelayer.style({\n raisingHeight: 200000 + 100000\n });\n lineDown.style({\n raisingHeight: 200000 + 100000\n });\n lineUp.style({\n raisingHeight: 200000 + 150000 + 100000\n });\n textLayer.style({\n raisingHeight: 200000 + 150000 + 10000 + 100000\n });\n });\n\n provincelayer.on('unmousemove', () => {\n provincelayer.style({\n raisingHeight: 200000\n });\n lineDown.style({\n raisingHeight: 200000\n });\n lineUp.style({\n raisingHeight: 200000 + 150000\n });\n textLayer.style({\n raisingHeight: 200000 + 150000 + 10000\n });\n });\n return '';\n });\n return '';\n});\n",title:"漂浮地图板块",filename:"floatmap.js",isNew:!1}],icon:"",id:"3d",title:{en:"Extrude Map",zh:"3D填充图"},childrenKey:"demos",order:0},{demos:[{id:"usa",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*4Kp4Qp00kq4AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PolygonLayer, LineLayer, Popup } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ -96, 37.8 ],\n zoom: 3\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/d36ad90e-3902-4742-b8a2-d93f7e5dafa2.json'\n )\n .then(res => res.json())\n .then(data => {\n const color = [ 'rgb(255,255,217)', 'rgb(237,248,177)', 'rgb(199,233,180)', 'rgb(127,205,187)', 'rgb(65,182,196)', 'rgb(29,145,192)', 'rgb(34,94,168)', 'rgb(12,44,132)' ];\n const layer = new PolygonLayer({})\n .source(data)\n .scale('density', {\n type: 'quantile'\n })\n .color(\n 'density', color\n )\n .shape('fill')\n .active(true);\n const layer2 = new LineLayer({\n zIndex: 2\n })\n .source(data)\n .color('#fff')\n .active(true)\n .size(1)\n .style({\n lineType: 'dash',\n dashArray: [ 2, 2 ],\n });\n scene.addLayer(layer);\n scene.addLayer(layer2);\n\n layer.on('mousemove', e => {\n const popup = new Popup({\n offsets: [ 0, 0 ],\n closeButton: false\n })\n .setLnglat(e.lngLat)\n .setHTML(`${e.feature.properties.name}: ${e.feature.properties.density}`);\n scene.addPopup(popup);\n });\n });\n});\n",title:"地图交互",filename:"usa.js",isNew:!1},{id:"fill",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*t9QJRL7uVk4AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PolygonLayer, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 116.368652, 39.93866 ],\n zoom: 10.07\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/1d27c363-af3a-469e-ab5b-7a7e1ce4f311.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new PolygonLayer({})\n .source(data)\n .color(\n 'unit_price',\n [\n '#1A4397',\n '#2555B7',\n '#3165D1',\n '#467BE8',\n '#6296FE',\n '#7EA6F9',\n '#98B7F7',\n '#BDD0F8',\n '#DDE6F7',\n '#F2F5FC'\n ].reverse()\n )\n .shape('fill')\n .active(true);\n const layer2 = new LineLayer({\n zIndex: 2\n })\n .source(data)\n .color('#fff')\n .size(0.8);\n\n scene.addLayer(layer);\n scene.addLayer(layer2);\n });\n});\n",title:"连续填充图",filename:"fill.js",isNew:!1},{id:"water",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*1kqvSYvWP3MAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PolygonLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ -44.40673828125, -18.375379094031825 ],\n zoom: 13\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/67130c6c-7f49-4680-915c-54e69730861d.json'\n )\n .then(data => data.json())\n .then(({ lakeData }) => {\n const lakeLayer = new PolygonLayer({ autoFit: true })\n .source(lakeData)\n .shape('water')\n .color('#1E90FF')\n .style({\n speed: 0.4\n // waterTexture: 'https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*EojwT4VzSiYAAAAAAAAAAAAAARQnAQ'\n })\n .animate(true);\n\n scene.addLayer(lakeLayer);\n });\n});\n",title:"简单水面",filename:"water.js",isNew:!1},{id:"ocean",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*BiawTbtX-CYAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PolygonLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ -44.40673828125, -18.375379094031825 ],\n zoom: 13\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/67130c6c-7f49-4680-915c-54e69730861d.json'\n )\n .then(data => data.json())\n .then(({ lakeData }) => {\n const lakeLayer = new PolygonLayer({ autoFit: true })\n .source(lakeData)\n .shape('ocean')\n .color('#1E90FF')\n .style({\n watercolor: '#6D99A8'\n // watercolor: '#0f0',\n })\n .animate(true);\n\n scene.addLayer(lakeLayer);\n });\n});\n",title:"拟真水面",filename:"ocean.js",isNew:!1}],icon:"",id:"fill",title:{en:"Choropleth Map",zh:"填充地图"},childrenKey:"demos",order:0}],childrenKey:"examples"},{id:"heatmap",title:{zh:"热力图",en:"HeatMap Layer"},icon:"heatmap",examples:[{demos:[{id:"heatmap",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*QstiQq4JBOIAAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 127.5671666579043, 7.445038892195569 ],\n zoom: 2.632456779444394\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/d3564b06-670f-46ea-8edb-842f7010a7c6.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data)\n .shape('heatmap')\n .size('mag', [ 0, 1.0 ]) // weight映射通道\n .style({\n intensity: 2,\n radius: 20,\n rampColors: {\n colors: [\n '#FF4818',\n '#F7B74A',\n '#FFF598',\n '#91EABC',\n '#2EA9A1',\n '#206C7C'\n ].reverse(),\n positions: [ 0, 0.2, 0.4, 0.6, 0.8, 1.0 ]\n }\n });\n scene.addLayer(layer);\n });\n});\n",title:"经典热力图2D",filename:"heatmap.js",isNew:!1},{id:"heatmap_purple",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*GD2bR7pb-yIAAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 127.5671666579043, 7.445038892195569 ],\n zoom: 2.632456779444394\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/d3564b06-670f-46ea-8edb-842f7010a7c6.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data)\n .shape('heatmap')\n .size('mag', [ 0, 1.0 ]) // weight映射通道\n .style({\n intensity: 2,\n radius: 20,\n rampColors: {\n colors: [\n '#FF4818',\n '#F7B74A',\n '#FFF598',\n '#F27DEB',\n '#8C1EB2',\n '#421EB2'\n ].reverse(),\n positions: [ 0, 0.2, 0.4, 0.6, 0.8, 1.0 ]\n }\n });\n scene.addLayer(layer);\n });\n});\n",title:"经典热力图2D",filename:"heatmap_purple.js",isNew:!1},{id:"heatmap3d",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*dmhzTqrHpR4AAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n pitch: 50,\n center: [ 100, 30.6942 ],\n rotation: 10,\n zoom: 2\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/337ddbb7-aa3f-4679-ab60-d64359241955.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data)\n .size('capacity', [ 0, 1 ])\n .shape('heatmap3D')\n // weight映射通道\n .style({\n intensity: 5,\n radius: 10,\n rampColors: {\n colors: [\n '#2E8AE6',\n '#69D1AB',\n '#DAF291',\n '#FFD591',\n '#FF7A45',\n '#CF1D49'\n ],\n positions: [ 0, 0.2, 0.4, 0.6, 0.8, 1.0 ]\n }\n });\n scene.addLayer(layer);\n });\n});\n",title:"经典热力图3D",filename:"heatmap3d.js",isNew:!1}],icon:"",id:"heatmap",title:{en:"HeatMap",zh:"经典热力图"},childrenKey:"demos",order:0},{demos:[{id:"grid_world",screenshot:"https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*1PeGSboLGUUAAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'blank',\n center: [ 110.097892, 33.853662 ],\n zoom: 4.056\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/3dadb1f5-8f54-4449-8206-72db6e142c40.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new HeatmapLayer({\n autoFit: true\n })\n .source(data, {\n transforms: [\n {\n type: 'hexagon',\n size: 5 * 100000\n }\n ]\n })\n .shape('circle')\n .active(false)\n .color('#aaa')\n .style({\n coverage: 0.7,\n angle: 0,\n });\n scene.addLayer(layer);\n });\n});\n",title:"网格世界地图",filename:"grid_world.js",isNew:!1},{id:"china",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*XPBuSIPPgsgAAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 107.054293, 35.246265 ],\n zoom: 4.056\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/7359a5e9-3c5e-453f-b207-bc892fb23b84.csv'\n )\n .then(res => res.text())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'lng',\n y: 'lat'\n },\n transforms: [\n {\n type: 'grid',\n size: 20000,\n field: 'v',\n method: 'sum'\n }\n ]\n })\n .shape('square')\n .style({\n coverage: 1,\n angle: 0\n })\n .color(\n 'count',\n [\n '#0B0030',\n '#100243',\n '#100243',\n '#1B048B',\n '#051FB7',\n '#0350C1',\n '#0350C1',\n '#0072C4',\n '#0796D3',\n '#2BA9DF',\n '#30C7C4',\n '#6BD5A0',\n '#A7ECB2',\n '#D0F4CA'\n ].reverse()\n );\n\n scene.addLayer(layer);\n });\n});\n",title:"网格热力图",filename:"china.js",isNew:!1},{id:"heatmap3",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*Ucz6SJ5wU_0AAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 110.097892, 33.853662 ],\n zoom: 4.056\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/7359a5e9-3c5e-453f-b207-bc892fb23b84.csv'\n )\n .then(res => res.text())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'lng',\n y: 'lat'\n },\n transforms: [\n {\n type: 'grid',\n size: 20000,\n field: 'v',\n method: 'sum'\n }\n ]\n })\n .shape('circle')\n .style({\n coverage: 0.9,\n angle: 0\n })\n .color(\n 'count',\n [\n '#8C1EB2',\n '#8C1EB2',\n '#DA05AA',\n '#F0051A',\n '#FF2A3C',\n '#FF4818',\n '#FF4818',\n '#FF8B18',\n '#F77B00',\n '#ED9909',\n '#ECC357',\n '#EDE59C'\n ].reverse()\n );\n scene.addLayer(layer);\n });\n});\n",title:"网格布局 圆形",filename:"heatmap3.js",isNew:!1},{id:"world",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*f1IDQ7AG-00AAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 110.097892, 33.853662 ],\n zoom: 4.056\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/7359a5e9-3c5e-453f-b207-bc892fb23b84.csv'\n )\n .then(res => res.text())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'lng',\n y: 'lat'\n },\n transforms: [\n {\n type: 'grid',\n size: 10000,\n field: 'v',\n method: 'sum'\n }\n ]\n })\n .shape('square')\n .style({\n coverage: 1,\n angle: 0\n })\n .color(\n 'count',\n [\n '#FF3417',\n '#FF7412',\n '#FFB02A',\n '#FFE754',\n '#46F3FF',\n '#02BEFF',\n '#1A7AFF',\n '#0A1FB2'\n ].reverse()\n );\n scene.addLayer(layer);\n });\n});\n",title:"网格热力图",filename:"world.js",isNew:!1}],icon:"",id:"grid",title:{en:"Grid Map",zh:"网格热力图"},childrenKey:"demos",order:1},{demos:[{id:"china",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*hLVeSqPl9asAAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n pitch: 47.49999999999995,\n center: [ 112.50447776627743, 30.830476390931125 ],\n zoom: 3.9879693680088626\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/7359a5e9-3c5e-453f-b207-bc892fb23b84.csv'\n )\n .then(res => res.text())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'lng',\n y: 'lat'\n },\n transforms: [\n {\n type: 'hexagon',\n size: 200000,\n field: 'v',\n method: 'sum'\n }\n ]\n })\n .size('sum', value => {\n return value * 20;\n })\n .shape('hexagonColumn')\n .color(\n 'count',\n [\n '#FF4818',\n '#F7B74A',\n '#FFF598',\n '#FF40F3',\n '#9415FF',\n '#421EB2'\n ].reverse()\n )\n .style({\n coverage: 0.9,\n angle: 0\n });\n\n scene.addLayer(layer);\n });\n});\n",title:"蜂窝热力图",filename:"china.js",isNew:!1},{id:"light",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*SLcGSbvZoEwAAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n pitch: 43,\n center: [ 120.13383079335335, 29.651873105004427 ],\n zoom: 7.068989519212174\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/a1a8158d-6fe3-424b-8e50-694ccf61c4d7.csv'\n )\n .then(res => res.text())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'lng',\n y: 'lat'\n },\n transforms: [\n {\n type: 'hexagon',\n size: 2500,\n field: 'v',\n method: 'sum'\n }\n ]\n })\n .size('sum', sum => {\n return sum * 200;\n })\n .shape('hexagonColumn')\n .style({\n coverage: 0.8,\n angle: 0,\n })\n .color('sum', [\n '#094D4A',\n '#146968',\n '#1D7F7E',\n '#289899',\n '#34B6B7',\n '#4AC5AF',\n '#5FD3A6',\n '#7BE39E',\n '#A1EDB8',\n '#C3F9CC',\n '#DEFAC0',\n '#ECFFB1'\n ]);\n scene.addLayer(layer);\n });\n});\n",title:"蜂窝热力图",filename:"light.js",isNew:!1},{id:"hexagon",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*JBibTKlhhWQAAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n pitch: 56.499,\n center: [ 114.07737552216226, 22.542656745583486 ],\n rotation: 39.19,\n zoom: 12.47985\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/513add53-dcb2-4295-8860-9e7aa5236699.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data, {\n transforms: [\n {\n type: 'hexagon',\n size: 100,\n field: 'h12',\n method: 'sum'\n }\n ]\n })\n .size('sum', [ 0, 600 ])\n .shape('hexagonColumn')\n .style({\n coverage: 0.8,\n angle: 0,\n })\n .color(\n 'sum',\n [\n '#094D4A',\n '#146968',\n '#1D7F7E',\n '#289899',\n '#34B6B7',\n '#4AC5AF',\n '#5FD3A6',\n '#7BE39E',\n '#A1EDB8',\n '#CEF8D6'\n ].reverse()\n );\n scene.addLayer(layer);\n });\n});\n",title:"蜂窝热力图",filename:"hexagon.js",isNew:!1},{id:"world",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*0uVgSoxXP-cAAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 104.995156, 31.450658 ],\n zoom: 3.79\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/337ddbb7-aa3f-4679-ab60-d64359241955.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data, {\n transforms: [\n {\n type: 'hexagon',\n size: 90000,\n field: 'capacity',\n method: 'sum'\n }\n ]\n })\n .shape('hexagon')\n .style({\n coverage: 0.9,\n angle: 0,\n })\n .color(\n 'sum',\n [\n '#3F4BBA',\n '#3F4BBA',\n '#3F4BBA',\n '#3F4BBA',\n '#3C73DA',\n '#3C73DA',\n '#3C73DA',\n '#0F62FF',\n '#0F62FF',\n '#30B2E9',\n '#30B2E9',\n '#40C4CE'\n ].reverse()\n );\n scene.addLayer(layer);\n });\n});\n",title:"蜂窝热力图",filename:"world.js",isNew:!1}],icon:"",id:"hexagon",title:{en:"Hexagon Map",zh:"蜂窝热力图"},childrenKey:"demos",order:1}],childrenKey:"examples"},{id:"raster",title:{zh:"栅格图层🌟",en:"Raster Layer🌟"},icon:"raster",examples:[{demos:[{id:"radar",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*JDO-R5XU7xwAAAAAAAAAAAAAARQnAQ",source:"import { Scene, ImageLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 115.5268, 34.3628 ],\n zoom: 7\n })\n});\nscene.on('loaded', () => {\n const layer = new ImageLayer({});\n layer.source(\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*8SUaRr7bxNsAAAAAAAAAAABkARQnAQ',\n {\n parser: {\n type: 'image',\n extent: [ 113.1277263548, 32.3464238863, 118.1365790452, 36.4786759137 ]\n }\n }\n );\n scene.addLayer(layer);\n});\n",title:"雷达图",filename:"radar.js",isNew:!1},{id:"image",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*8MtWSIGTN8UAAAAAAAAAAAAAARQnAQ",source:"import { Scene, ImageLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 121.268, 30.3628 ],\n zoom: 10\n })\n});\nscene.on('loaded', () => {\n const layer = new ImageLayer({});\n layer.source(\n 'https://gw.alipayobjects.com/zos/rmsportal/FnHFeFklTzKDdUESRNDv.jpg',\n {\n parser: {\n type: 'image',\n extent: [ 121.168, 30.2828, 121.384, 30.4219 ]\n }\n }\n );\n scene.addLayer(layer);\n});\n",title:"图片",filename:"image.js",isNew:!1}],icon:"",id:"basic",title:{en:"Raster Map",zh:"图片栅格"},childrenKey:"demos",order:0},{demos:[{id:"543",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*uOX7RaIElMsAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { RasterLayer, Scene } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\nimport React, { useEffect } from 'react';\nimport * as GeoTIFF from 'geotiff';\n\nasync function getTiffData(url: string) {\n const response = await fetch(url);\n const arrayBuffer = await response.arrayBuffer();\n return arrayBuffer;\n}\n\nconst scene = new Scene({\n id: 'map',\n map: new Map({\n center: [130.5, 47],\n zoom: 10.5,\n }),\n});\n\nscene.on('loaded', async () => {\n const url2 =\n 'https://t0.tianditu.gov.cn/img_w/wmts?tk=b72aa81ac2b3cae941d1eb213499e15e&';\n\n const layer2 = new RasterLayer({\n zIndex: 1,\n }).source(url2, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n wmtsOptions: {\n layer: 'img',\n tileMatrixset: 'w',\n format: 'tiles',\n },\n },\n });\n scene.addLayer(layer2);\n const url1 =\n 'https://gw.alipayobjects.com/zos/raptor/1667832825992/LC08_3857_clip_2.tif';\n const tiffdata = await getTiffData(url1);\n\n const layer = new RasterLayer({ zIndex: 10 });\n layer\n .source(\n [\n {\n data: tiffdata,\n bands: [5, 4, 3].map((v) => v - 1),\n },\n ],\n {\n parser: {\n type: 'rasterRgb',\n format: async (data, bands) => {\n const tiff = await GeoTIFF.fromArrayBuffer(data);\n const image1 = await tiff.getImage();\n const value = await image1.readRasters();\n return bands.map((band) => {\n return {\n rasterData: value[band],\n width: value.width,\n height: value.height,\n };\n });\n },\n operation: {\n type: 'rgb',\n },\n extent: [\n 130.39565357746957, 46.905730725742366, 130.73364094187343,\n 47.10217234153133,\n ],\n },\n },\n )\n .style({\n opacity: 1,\n });\n scene.addLayer(layer);\n});\n\n\n",title:"标准假彩色",filename:"543.ts",isNew:!1},{id:"432",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*JhucSo3pVVAAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { RasterLayer, Scene } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\nimport React, { useEffect } from 'react';\nimport * as GeoTIFF from 'geotiff';\n\nasync function getTiffData(url: string) {\n const response = await fetch(url);\n const arrayBuffer = await response.arrayBuffer();\n return arrayBuffer;\n}\n\nconst scene = new Scene({\n id: 'map',\n map: new Map({\n center: [130.5, 47],\n zoom: 10.5,\n }),\n});\n\nscene.on('loaded', async () => {\n const url2 =\n 'https://t0.tianditu.gov.cn/img_w/wmts?tk=b72aa81ac2b3cae941d1eb213499e15e&';\n\n const layer2 = new RasterLayer({\n zIndex: 1,\n }).source(url2, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n wmtsOptions: {\n layer: 'img',\n tileMatrixset: 'w',\n format: 'tiles',\n },\n },\n });\n scene.addLayer(layer2);\n const url1 =\n 'https://gw.alipayobjects.com/zos/raptor/1667832825992/LC08_3857_clip_2.tif';\n const tiffdata = await getTiffData(url1);\n\n const layer = new RasterLayer({ zIndex: 10 });\n layer\n .source(\n [\n {\n data: tiffdata,\n bands: [4, 3, 2].map((v) => v - 1),\n },\n ],\n {\n parser: {\n type: 'rasterRgb',\n format: async (data, bands) => {\n const tiff = await GeoTIFF.fromArrayBuffer(data);\n const image1 = await tiff.getImage();\n const value = await image1.readRasters();\n return bands.map((band) => {\n return {\n rasterData: value[band],\n width: value.width,\n height: value.height,\n };\n });\n },\n operation: {\n type: 'rgb',\n },\n extent: [\n 130.39565357746957, 46.905730725742366, 130.73364094187343,\n 47.10217234153133,\n ],\n },\n },\n )\n .style({\n opacity: 1,\n });\n scene.addLayer(layer);\n});\n\n\n",title:"自然色彩",filename:"432.ts",isNew:!1},{id:"ndbi",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*Kd59RqRj0V0AAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { RasterLayer, Scene } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nimport * as GeoTIFF from 'geotiff';\n\nasync function getTiffData(url: string) {\n const response = await fetch(url);\n const arrayBuffer = await response.arrayBuffer();\n return arrayBuffer;\n}\n\nconst scene = new Scene({\n id: 'map',\n map: new Map({\n center: [130.5, 47],\n zoom: 10.5,\n }),\n});\n\nscene.on('loaded', async () => {\n const url1 =\n 'https://gw.alipayobjects.com/zos/raptor/1667832825992/LC08_3857_clip_2.tif';\n const tiffdata = await getTiffData(url1);\n const url2 =\n 'https://t0.tianditu.gov.cn/img_w/wmts?tk=b72aa81ac2b3cae941d1eb213499e15e&';\n\n const layer2 = new RasterLayer({\n zIndex: 1,\n }).source(url2, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n zoomOffset: 1,\n wmtsOptions: {\n layer: 'img',\n tileMatrixset: 'w',\n format: 'tiles',\n },\n },\n });\n // NDBI 6,5\n // NDWI 3,5\n const layer = new RasterLayer({\n zIndex: 10,\n });\n\n layer\n .source(\n [\n {\n data: tiffdata,\n bands: [6, 5].map((v) => v - 1),\n },\n ],\n {\n parser: {\n type: 'raster',\n format: async (data, bands) => {\n const tiff = await GeoTIFF.fromArrayBuffer(data);\n const image = await tiff.getImage();\n const width = image.getWidth();\n const height = image.getHeight();\n const values = await image.readRasters();\n return [\n { rasterData: values[bands[0]], width, height }, // R\n { rasterData: values[bands[1]], width, height }, // NIR\n ];\n },\n operation: {\n type: 'nd',\n },\n extent: [\n 130.39565357746957, 46.905730725742366, 130.73364094187343,\n 47.10217234153133,\n ],\n },\n },\n )\n .style({\n domain: [-0.35, 0.6],\n rampColors: {\n colors: ['#276419', '#f7f7f7', '#ff0000'].reverse(),\n positions: [0, 0.38, 1.0],\n },\n });\n\n scene.addLayer(layer2);\n scene.addLayer(layer);\n});\n",title:"建筑指数",filename:"ndbi.ts",isNew:!1},{id:"ndvi",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*HWiES58tAhYAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { RasterLayer, Scene } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nimport * as GeoTIFF from 'geotiff';\n\nasync function getTiffData(url: string) {\n const response = await fetch(url);\n const arrayBuffer = await response.arrayBuffer();\n return arrayBuffer;\n}\n\n\nconst scene = new Scene({\n id: 'map',\n map: new Map({\n center: [130.5, 47],\n zoom: 10.5,\n }),\n});\n\nscene.on('loaded', async () => {\n const url1 =\n 'https://gw.alipayobjects.com/zos/raptor/1667832825992/LC08_3857_clip_2.tif';\n const tiffdata = await getTiffData(url1);\n const url2 =\n 'https://t0.tianditu.gov.cn/img_w/wmts?tk=b72aa81ac2b3cae941d1eb213499e15e&';\n\n const layer2 = new RasterLayer({\n zIndex: 1,\n }).source(url2, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n wmtsOptions: {\n layer: 'img',\n tileMatrixset: 'w',\n format: 'tiles',\n },\n },\n });\n // NDBI 6,5\n // NDWI 3,5\n const layer = new RasterLayer({\n zIndex: 10,\n });\n\n layer\n .source(\n [\n {\n data: tiffdata,\n bands: [4, 5].map((v) => v - 1),\n },\n ],\n {\n parser: {\n type: 'raster',\n format: async (data, bands) => {\n const tiff = await GeoTIFF.fromArrayBuffer(data);\n const image = await tiff.getImage();\n const width = image.getWidth();\n const height = image.getHeight();\n const values = await image.readRasters();\n return [\n { rasterData: values[bands[0]], width, height }, // R\n { rasterData: values[bands[1]], width, height }, // NIR\n ];\n },\n operation: {\n type: 'nd',\n },\n extent: [\n 130.39565357746957, 46.905730725742366, 130.73364094187343,\n 47.10217234153133,\n ],\n },\n },\n )\n .style({\n domain: [-0.3, 0.5],\n rampColors: {\n colors: [\n '#ce4a2e',\n '#f0a875',\n '#fff8ba',\n '#bddd8a',\n '#5da73e',\n '#235117',\n ],\n positions: [0, 0.2, 0.4, 0.6, 0.8, 1.0],\n },\n });\n\n scene.addLayer(layer2);\n scene.addLayer(layer);\n});\n",title:"植被指数",filename:"ndvi.ts",isNew:!1},{id:"ndwi",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*L4AcTbE69qcAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { RasterLayer, Scene } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nimport * as GeoTIFF from 'geotiff';\n\nasync function getTiffData(url: string) {\n const response = await fetch(url);\n const arrayBuffer = await response.arrayBuffer();\n return arrayBuffer;\n}\n\nconst scene = new Scene({\n id: 'map',\n map: new Map({\n center: [130.5, 47],\n zoom: 10.5,\n }),\n});\n\nscene.on('loaded', async () => {\n const url1 =\n 'https://gw.alipayobjects.com/zos/raptor/1667832825992/LC08_3857_clip_2.tif';\n const tiffdata = await getTiffData(url1);\n const url2 =\n 'https://t0.tianditu.gov.cn/img_w/wmts?tk=b72aa81ac2b3cae941d1eb213499e15e&';\n\n const layer2 = new RasterLayer({\n zIndex: 1,\n }).source(url2, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n wmtsOptions: {\n layer: 'img',\n tileMatrixset: 'w',\n format: 'tiles',\n },\n },\n });\n // NDBI 6,5\n // NDWI 3,5\n const layer = new RasterLayer({\n zIndex: 10,\n });\n\n layer\n .source(\n [\n {\n data: tiffdata,\n bands: [3, 5].map((v) => v - 1),\n },\n ],\n {\n parser: {\n type: 'raster',\n format: async (data, bands) => {\n const tiff = await GeoTIFF.fromArrayBuffer(data);\n const image = await tiff.getImage();\n const width = image.getWidth();\n const height = image.getHeight();\n const values = await image.readRasters();\n return [\n { rasterData: values[bands[0]], width, height }, // R\n { rasterData: values[bands[1]], width, height }, // NIR\n ];\n },\n operation: {\n type: 'nd',\n },\n extent: [\n 130.39565357746957, 46.905730725742366, 130.73364094187343,\n 47.10217234153133,\n ],\n },\n },\n )\n .style({\n domain: [0, 1],\n rampColors: {\n colors: ['#0000FF', '#FF0000'],\n positions: [0, 1.0],\n },\n });\n\n scene.addLayer(layer2);\n scene.addLayer(layer);\n});\n",title:"水体指数",filename:"ndwi.ts",isNew:!1},{id:"rgb",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*HWiES58tAhYAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { RasterLayer, Scene, metersToLngLat } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\nimport React, { useEffect } from 'react';\nimport * as GeoTIFF from 'geotiff';\n\nasync function getTiffData(url: string) {\n const response = await fetch(url);\n const arrayBuffer = await response.arrayBuffer();\n return arrayBuffer;\n}\n\n\nconst scene = new Scene({\n id: 'map',\n \n map: new Map({\n center: [130.5, 47],\n zoom: 2,\n }),\n});\n\nscene.on('loaded', async () => {\n const url1 =\n 'https://gw.alipayobjects.com/zos/raptor/1667920165972/china.tif';\n const tiffdata = await getTiffData(url1);\n const maskData = await (\n await fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/d2e0e930-fd44-4fca-8872-c1037b0fee7b.json',\n )\n ).json();\n const layer = new RasterLayer({\n zIndex: 10,\n mask: true,\n maskfence: maskData,\n });\n layer\n .source(\n [\n {\n data: tiffdata,\n bands: [0, 1, 2],\n },\n ],\n {\n parser: {\n type: 'rasterRgb',\n format: async (data, bands) => {\n const tiff = await GeoTIFF.fromArrayBuffer(data);\n const image1 = await tiff.getImage();\n const value = await image1.readRasters();\n\n return bands.map((band) => {\n return {\n rasterData: value[band],\n width: value.width,\n height: value.height,\n };\n });\n },\n operation: {\n type: 'rgb',\n options: {},\n },\n extent: [\n ...metersToLngLat([\n 8182125.2558000003919005, 427435.8622000003233552,\n ]),\n ...metersToLngLat([\n 15038832.4410999994724989, 7087852.7587999999523163,\n ]),\n ],\n },\n },\n )\n .style({\n opacity: 1,\n });\n scene.addLayer(layer);\n});\n",title:"TiFF 正射影像",filename:"rgb.ts",isNew:!1}],icon:"",id:"data_raster",title:{en:"Raster Data",zh:"多波段"},childrenKey:"demos",order:0},{demos:[{id:"light_default",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*xznhSJFEAXYAAAAAAAAAAAAAARQnAQ",source:"// https://gw.alipayobjects.com/zos/antvdemo/assets/2019_clip/ndvi_201905.tif\nimport { RasterLayer, Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport * as GeoTIFF from 'geotiff';\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 105, 37.5 ],\n zoom: 2.5\n })\n});\nscene.on('loaded', () => {\n addLayer();\n});\nasync function getTiffData() {\n const response = await fetch(\n 'https://gw.alipayobjects.com/zos/antvdemo/assets/light_clip/lightF182013.tiff'\n );\n const arrayBuffer = await response.arrayBuffer();\n const tiff = await GeoTIFF.fromArrayBuffer(arrayBuffer);\n const image = await tiff.getImage();\n const width = image.getWidth();\n const height = image.getHeight();\n const values = await image.readRasters();\n return {\n data: values[0],\n width,\n height\n };\n}\n\nasync function addLayer() {\n const tiffdata = await getTiffData();\n\n const layer = new RasterLayer({});\n layer\n .source(tiffdata.data, {\n parser: {\n type: 'raster',\n width: tiffdata.width,\n height: tiffdata.height,\n extent: [ 73.4821902409999979, 3.8150178409999995, 135.1066187319999869, 57.6300459959999998 ]\n }\n })\n .style({\n clampLow: false,\n clampHigh: false,\n domain: [ 0, 90 ],\n nodataValue: 0,\n rampColors: {\n positions: [ 0, 0.05, 0.1, 0.25, 0.5, 1.0 ],// 数据需要换成 0-1\n colors: ['rgba(92,58,16,0)','rgba(92,58,16,0)', '#fabd08', '#f1e93f', '#f1ff8f', '#fcfff7' ],\n \n }\n });\n\n scene.addLayer(layer);\n}\n",title:"夜光图-默认线性",filename:"light_default.js",isNew:!1},{id:"light",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*xznhSJFEAXYAAAAAAAAAAAAAARQnAQ",source:"// https://gw.alipayobjects.com/zos/antvdemo/assets/2019_clip/ndvi_201905.tif\nimport { RasterLayer, Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport * as GeoTIFF from 'geotiff';\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 105, 37.5 ],\n zoom: 2.5\n })\n});\nscene.on('loaded', () => {\n addLayer();\n});\nasync function getTiffData() {\n const response = await fetch(\n 'https://gw.alipayobjects.com/zos/antvdemo/assets/light_clip/lightF182013.tiff'\n );\n const arrayBuffer = await response.arrayBuffer();\n const tiff = await GeoTIFF.fromArrayBuffer(arrayBuffer);\n const image = await tiff.getImage();\n const width = image.getWidth();\n const height = image.getHeight();\n const values = await image.readRasters();\n return {\n data: values[0],\n width,\n height\n };\n}\n\nasync function addLayer() {\n const tiffdata = await getTiffData();\n\n const layer = new RasterLayer({});\n layer\n .source(tiffdata.data, {\n parser: {\n type: 'raster',\n width: tiffdata.width,\n height: tiffdata.height,\n extent: [ 73.4821902409999979, 3.8150178409999995, 135.1066187319999869, 57.6300459959999998 ]\n }\n })\n .style({\n clampLow: false,\n clampHigh: false,\n domain: [ 0, 90 ],\n nodataValue: 0,\n rampColors: {\n type:'linear', // 2.13.0 及以后版本支持\n colors: ['rgba(92,58,16,0)','rgba(92,58,16,0)', '#fabd08', '#f1e93f', '#f1ff8f', '#fcfff7' ],\n positions: [0,3, 9, 22.5, 45, 90 ]\n }\n });\n\n scene.addLayer(layer);\n}\n",title:"夜光图-线性色带",filename:"light.js",isNew:!1},{id:"dem",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*_RtOTrYOOrUAAAAAAAAAAAAADmJ7AQ/original",source:"// https://gw.alipayobjects.com/zos/antvdemo/assets/2019_clip/ndvi_201905.tif\nimport { RasterLayer, Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport * as GeoTIFF from 'geotiff';\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [121.268, 30.3628],\n zoom: 3,\n }),\n });\n async function getTiffData() {\n const response = await fetch(\n 'https://gw.alipayobjects.com/os/rmsportal/XKgkjjGaAzRyKupCBiYW.dat',\n );\n const arrayBuffer = await response.arrayBuffer();\n return arrayBuffer;\n }\n scene.on('loaded', async () => {\n const tiffdata = await getTiffData();\n const tiff = await GeoTIFF.fromArrayBuffer(tiffdata);\n const image = await tiff.getImage();\n const width = image.getWidth();\n const height = image.getHeight();\n const values = await image.readRasters();\n\n const layer = new RasterLayer();\n layer\n .source(values[0], {\n parser: {\n type: 'raster',\n width,\n height,\n extent: [73.482190241, 3.82501784112, 135.106618732, 57.6300459963],\n },\n })\n .style({\n opacity: 1,\n clampLow: false,\n clampHigh: false,\n domain: [0, 10000],\n rampColors: {\n type:'custom',\n colors: ['#b2182b','#d6604d','#f4a582','#fddbc7','#f7f7f7','#d1e5f0','#92c5de','#4393c3','#2166ac'],\n positions: [0, 50, 200, 500, 2000, 3000, 4000, 5000, 8000,10000],\n },\n });\n\n scene.addLayer(layer)\n});",title:"高程图-自定义色带",filename:"dem.js",isNew:!1},{id:"dem_quantize",screenshot:"https://mdn.alipayobjects.com//huamei_qa8qxu/afts/img/A*DT1HQbl4JKMAAAAAAAAAAAAADmJ7AQ/original",source:"// https://gw.alipayobjects.com/zos/antvdemo/assets/2019_clip/ndvi_201905.tif\nimport { RasterLayer, Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport * as GeoTIFF from 'geotiff';\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [121.268, 30.3628],\n zoom: 3,\n }),\n });\n async function getTiffData() {\n const response = await fetch(\n 'https://gw.alipayobjects.com/os/rmsportal/XKgkjjGaAzRyKupCBiYW.dat',\n );\n const arrayBuffer = await response.arrayBuffer();\n return arrayBuffer;\n }\n scene.on('loaded', async () => {\n const tiffdata = await getTiffData();\n const tiff = await GeoTIFF.fromArrayBuffer(tiffdata);\n const image = await tiff.getImage();\n const width = image.getWidth();\n const height = image.getHeight();\n const values = await image.readRasters();\n\n const layer = new RasterLayer();\n layer\n .source(values[0], {\n parser: {\n type: 'raster',\n width,\n height,\n extent: [73.482190241, 3.82501784112, 135.106618732, 57.6300459963],\n },\n })\n .style({\n opacity: 1,\n clampLow: false,\n clampHigh: false,\n domain: [0, 10000],\n rampColors: {\n type:'quantize', // 等间距 不需要设置 position\n colors: ['#b2182b','#d6604d','#f4a582','#fddbc7','#f7f7f7','#d1e5f0','#92c5de','#4393c3','#2166ac'],\n \n },\n });\n\n scene.addLayer(layer)\n});",title:"高程图-等间距色带",filename:"dem_quantize.js",isNew:!1}],icon:"",id:"single_raster",title:{en:"Raster Data Map",zh:"单波段"},childrenKey:"demos",order:0}],childrenKey:"examples"},{id:"tile",title:{zh:"瓦片图层 🌟",en:"Tile Layer🌟 "},icon:"raster",examples:[{demos:[{id:"dem",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*3UcORbAv_zEAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { Scene, RasterLayer } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n \n map: new Map({\n center: [113.270854, 23.141717],\n zoom: 5,\n }),\n});\n\nconst url1 =\n 'https://tiles{1-3}.geovisearth.com/base/v1/ter/{z}/{x}/{y}?format=webp&tmsIds=w&token=b2a0cfc132cd60b61391b9dd63c15711eadb9b38a9943e3f98160d5710aef788';\nconst url2 =\n 'https://tiles{1-3}.geovisearth.com/base/v1/cat/{z}/{x}/{y}?format=png&tmsIds=w&token=b2a0cfc132cd60b61391b9dd63c15711eadb9b38a9943e3f98160d5710aef788';\nconst layer1 = new RasterLayer({\n zIndex: 1,\n}).source(url1, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n zoomOffset: 0,\n },\n});\n\nconst layer2 = new RasterLayer({\n zIndex: 1,\n}).source(url2, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n zoomOffset: 0,\n },\n});\nscene.addLayer(layer1);\nscene.addLayer(layer2);\n",title:"地形图",filename:"dem.ts",isNew:!1},{id:"amap-satellite",screenshot:"https://gw.alipayobjects.com/zos/antfincdn/oRfnb3AR05/7866c85b-2d33-4ad2-a276-c52cbde041b0.png",source:"import { Scene, RasterLayer } from '@antv/l7';\nimport { Map } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new Map({\n center: [ 90.268, 40.3628 ],\n zoom: 3\n })\n});\n\nscene.on('loaded', () => {\n // 影像底图服务\n const baseLayer = new RasterLayer({\n zIndex: 1\n });\n baseLayer.source(\n 'https://webst0{1-4}.is.autonavi.com/appmaptile?style=6&x={x}&y={y}&z={z}',\n {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n // minZoom: 6,\n // maxZoom: 15,\n zoomOffset: 0\n // extent: [-180, -85.051129, 179, 85.051129],\n }\n }\n );\n\n // 影像注记服务\n const annotionLayer = new RasterLayer({\n zIndex: 2\n });\n annotionLayer.source(\n 'https://webst0{1-3}.is.autonavi.com/appmaptile?style=8&x={x}&y={y}&z={z}',\n {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n // minZoom: 6,\n // maxZoom: 15,\n zoomOffset: 0\n // extent: [-180, -85.051129, 179, 85.051129],\n }\n }\n );\n\n scene.addLayer(baseLayer);\n scene.addLayer(annotionLayer);\n});\n",title:"高德卫星影像",filename:"amap-satellite.js",isNew:!1},{id:"mask",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*UPwFRI5cUsoAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { Scene, RasterLayer, MaskLayer } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n \n map: new Map({\n center: [112, 30],\n // zoom: 12,\n zoom: 3,\n }),\n});\n\nconst mask = new MaskLayer({\n sourceLayer: 'ecoregions2', // woods hillshade contour ecoregions ecoregions2 city\n}).source(\n 'http://ganos.oss-cn-hangzhou.aliyuncs.com/m2/rs_l7/{z}/{x}/{y}.pbf',\n {\n parser: {\n type: 'mvt',\n tileSize: 256,\n maxZoom: 9,\n },\n },\n);\n\nconst layer = new RasterLayer({\n zIndex: 1,\n mask: true,\n}).source(\n 'https://tiles{1-3}.geovisearth.com/base/v1/img/{z}/{x}/{y}?format=webp&tmsIds=w&token=b2a0cfc132cd60b61391b9dd63c15711eadb9b38a9943e3f98160d5710aef788',\n {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n },\n },\n);\n\nscene.on('loaded', () => {\n scene.addLayer(mask);\n scene.addLayer(layer);\n});\n",title:"影像底图掩膜",filename:"mask.ts",isNew:!1},{id:"raster",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*Gg87TbHRYNcAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { Scene, RasterLayer } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n \n map: new Map({\n center: [113.270854, 23.141717],\n zoom: 5,\n }),\n});\n\nconst url1 =\n 'https://tiles{1-3}.geovisearth.com/base/v1/img/{z}/{x}/{y}?format=webp&tmsIds=w&token=b2a0cfc132cd60b61391b9dd63c15711eadb9b38a9943e3f98160d5710aef788';\nconst url2 =\n 'https://tiles{1-3}.geovisearth.com/base/v1/cia/{z}/{x}/{y}?format=png&tmsIds=w&token=b2a0cfc132cd60b61391b9dd63c15711eadb9b38a9943e3f98160d5710aef788';\nconst layer1 = new RasterLayer({\n zIndex: 1,\n}).source(url1, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n },\n});\n\nconst layer2 = new RasterLayer({\n zIndex: 1,\n}).source(url2, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n },\n});\n\nscene.on('loaded', () => {\n scene.addLayer(layer1);\n scene.addLayer(layer2);\n});\n",title:"卫星图",filename:"raster.ts",isNew:!1},{id:"normal",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*ZM2lR56TIwoAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { Scene, RasterLayer } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n \n map: new Map({\n center: [113.270854, 23.141717],\n zoom: 5,\n }),\n});\n\nconst url1 =\n 'https://tiles{1-3}.geovisearth.com/base/v1/vec/{z}/{x}/{y}?format=png&tmsIds=w&token=b2a0cfc132cd60b61391b9dd63c15711eadb9b38a9943e3f98160d5710aef788';\n\nconst layer1 = new RasterLayer({\n zIndex: 1,\n}).source(url1, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n zoomOffset: 0,\n },\n});\n\nconst layer2 = new RasterLayer({\n zIndex: 1,\n}).source(url1, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n zoomOffset: 0,\n },\n});\n\nscene.on('loaded', () => {\n scene.addLayer(layer1);\n scene.addLayer(layer2);\n});\n",title:"普通底图",filename:"normal.ts",isNew:!1},{id:"wms",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*Ge03Qo2cKv0AAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { Scene, RasterLayer } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n \n map: new Map({\n center: [114.061677, 22.54899],\n zoom: 11,\n }),\n});\nconst url1 =\n 'https://tiles{1-3}.geovisearth.com/base/v1/img/{z}/{x}/{y}?format=webp&tmsIds=w&token=b2a0cfc132cd60b61391b9dd63c15711eadb9b38a9943e3f98160d5710aef788';\nconst url2 =\n 'https://tiles{1-3}.geovisearth.com/base/v1/cia/{z}/{x}/{y}?format=png&tmsIds=w&token=b2a0cfc132cd60b61391b9dd63c15711eadb9b38a9943e3f98160d5710aef788';\nconst layer1 = new RasterLayer({\n zIndex: 1,\n}).source(url1, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n },\n});\n\nconst layer2 = new RasterLayer({\n zIndex: 1,\n}).source(url2, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n },\n});\n// WMS 底图 BBOX获取数据\nconst url =\n 'https://pnr.sz.gov.cn/d-suplicmap/dynamap_1/rest/services/LAND_CERTAIN/MapServer/export?F=image&FORMAT=PNG32&TRANSPARENT=true&layers=show:1&SIZE=256,256&BBOX={bbox}&BBOXSR=4326&IMAGESR=3857&DPI=90';\n\nconst layer = new RasterLayer({\n zIndex: 3,\n}).source(url, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n zoomOffset: 0,\n },\n});\n\nscene.on('loaded', () => {\n scene.addLayer(layer1);\n scene.addLayer(layer2);\n scene.addLayer(layer);\n\n});\n",title:"WMS 底图",filename:"wms.ts",isNew:!1},{id:"wmts",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*afuwT64AJVYAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { Scene, RasterLayer } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n \n map: new Map({\n center: [113.270854, 23.141717],\n zoom: 11,\n }),\n});\n\nconst url1 =\n 'https://t0.tianditu.gov.cn/img_w/wmts?tk=b72aa81ac2b3cae941d1eb213499e15e&';\nconst layer1 = new RasterLayer({\n zIndex: 1,\n}).source(url1, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n wmtsOptions: {\n layer: 'img',\n tileMatrixset: 'w',\n format: 'tiles',\n },\n },\n});\n\n\n\nscene.on('loaded', () => {\n scene.addLayer(layer1);\n});\n",title:"天地图 WMTS 底图",filename:"wmts.ts",isNew:!1}],icon:"",id:"basemap",title:{en:"BaseMap",zh:"地图底图"},childrenKey:"demos",order:0},{demos:[{id:"terrain",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*pNs4R6YVI54AAAAAAAAAAAAADmJ7AQ/original",source:"//@ts-ignore\nimport { Scene, RasterLayer } from '@antv/l7';\n//@ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new Map({\n center: [130, 30],\n pitch: 0,\n zoom: 1.5,\n }),\n});\nscene.on('loaded', () => {\n const layer = new RasterLayer()\n .source(\n 'https://tiles{1-3}.geovisearth.com/base/v1/terrain_rgb/{z}/{x}/{y}?format=png&tmsIds=w&token=b2a0cfc132cd60b61391b9dd63c15711eadb9b38a9943e3f98160d5710aef788',\n {\n parser: {\n type: 'rasterTile',\n dataType: 'terrainRGB',\n tileSize: 256,\n zoomOffset: 0,\n },\n },\n )\n .style({\n clampLow: false,\n clampHigh: false,\n domain: [0, 7000],\n rampColors: {\n colors: ['#d73027', '#fc8d59', '#fee08b', '#d9ef8b', '#91cf60', '#1a9850'],\n positions: [0, 0.2, 0.4, 0.6, 0.8, 1.0],\n }\n });\n\n scene.addLayer(layer);\n});\n\n",title:"Terrain-RGB 高程图",filename:"terrain.ts",isNew:!1},{id:"lerc",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*Q2SlRZ8L2_sAAAAAAAAAAAAAARQnAQ",source:"import { Scene, RasterLayer, Source } from '@antv/l7';\nimport { Map } from '@antv/l7-maps';\nimport * as Lerc from 'lerc';\n\nconst colorList = [ '#fff7fb', '#ece7f2', '#d0d1e6', '#a6bddb', '#74a9cf', '#3690c0', '#0570b0', '#045a8d', '#023858' ];\nconst positions = [ 0, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 1.0 ];\nconst scene = new Scene({\n id: 'map',\n map: new Map({\n center: [ 90.268, 35.3628 ],\n zoom: 3\n })\n});\n\nscene.on('loaded', () => {\n const layer = new RasterLayer();\n const tileSource = new Source('https://elevation3d.arcgis.com/arcgis/rest/services/WorldElevation3D/Terrain3D/ImageServer/tile/{z}/{y}/{x}',\n {\n parser: {\n type: 'rasterTile',\n dataType: 'arraybuffer',\n tileSize: 256,\n format: async data => {\n const image = Lerc.decode(data);\n return {\n rasterData: image.pixels[0],\n width: image.width,\n height: image.height\n };\n }\n }\n });\n\n layer.source(tileSource)\n .style({\n domain: [ 0, 1024 ],\n clampLow: true,\n rampColors: {\n colors: colorList,\n positions\n }\n });\n\n scene.addLayer(layer);\n return '';\n});\n\nconst wrap = document.getElementById('map');\nconst legend = document.createElement('div');\n\nconst data = [];\nfor (let i = 0; i < colorList.length; i++) {\n data.push({\n color: colorList[i],\n text: positions[i]\n });\n}\nconst strArr = [];\ndata.map(({ color, text }) => {\n strArr.push(`
\n
\n ${text}\n
\n
\n
`);\n return '';\n});\nlegend.innerHTML = strArr.join('');\nlegend.style.position = 'absolute';\nlegend.style.left = '10px';\nlegend.style.bottom = '30px';\nlegend.style.background = '#fff';\nlegend.style.zIndex = 10;\n\nwrap.appendChild(legend);\n",title:"lerc 高程栅格",filename:"lerc.js",isNew:!1},{id:"tiff",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*QUb2TY71GjIAAAAAAAAAAAAAARQnAQ",source:"import { Scene, RasterLayer, Source } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport * as GeoTIFF from 'geotiff';\n\nconst colorList = [\n '#419bdf', // Water\n\n '#358221', // Tree\n\n '#88b053', // Grass\n\n\n '#7a87c6', // vegetation\n\n\n '#e49635', // Crops\n\n\n '#dfc35a', // shrub\n\n\n '#ED022A', // Built Area\n\n\n '#EDE9E4', // Bare ground\n \n\n '#F2FAFF', // Snow\n\n '#C8C8C8', // Clouds\n];\nconst positions = [\n 1,2,3,4,5,6,7,8,9,10,11,\n];\n\nconst scene = new Scene({\n id: 'map',\n \n map: new GaodeMap({\n center: [ 116, 27 ],\n zoom: 6,\n style: 'dark'\n })\n});\n\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/fccd80c0-2611-49f9-9a9f-e2a4dd12226f.json'\n )\n .then(res => res.json())\n .then(maskData => {\n const layer = new RasterLayer({\n mask: true,\n maskfence: maskData\n });\n\n const tileSource = new Source('https://ganos.oss-cn-hangzhou.aliyuncs.com/m2/l7/tiff_jx/{z}/{x}/{y}.tiff',\n {\n parser: {\n type: 'rasterTile',\n dataType: 'arraybuffer',\n tileSize: 256,\n maxZoom: 13.1,\n format: async data => {\n const tiff = await GeoTIFF.fromArrayBuffer(data);\n const image = await tiff.getImage();\n const width = image.getWidth();\n const height = image.getHeight();\n const values = await image.readRasters();\n return { rasterData: values[0], width, height };\n }\n }\n });\n\n layer.source(tileSource)\n .style({\n domain: [ 0, 255],// 枚举类型domain 必须为0-255\n clampLow: false,\n rampColors: {\n type:'cat',\n colors: colorList,\n positions\n }\n });\n\n scene.addLayer(layer);\n return '';\n });\n return '';\n});\n\nconst wrap = document.getElementById('map');\nconst legend = document.createElement('div');\n\nconst data = [];\nfor (let i = 0; i < colorList.length; i += 1) {\n data.push({\n color: colorList[i],\n text: [\n 'Water',\n 'Trees',\n 'Grass',\n 'Vegetation',\n 'Crops',\n 'Shrub',\n 'Built Area',\n 'Bare ground',\n 'Snow',\n 'Clouds'\n ][i]\n });\n}\nconst strArr = [];\ndata.map(({ color, text }) => {\n strArr.push(`
\n
\n ${text}\n
\n
\n
`);\n return '';\n});\nlegend.innerHTML = strArr.join('');\nlegend.style.position = 'absolute';\nlegend.style.left = '10px';\nlegend.style.bottom = '30px';\nlegend.style.zIndex = 10;\n\nwrap.appendChild(legend);\n\n",title:"TIFF 土地覆盖",filename:"tiff.js",isNew:!1}],icon:"",id:"raster",title:{en:"Raster Tile",zh:"栅格瓦片"},childrenKey:"demos",order:0},{demos:[{id:"chinadistrictmap",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*QlNPTpxjWEAAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { Scene, Source, PolygonLayer, LineLayer } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n \n map: new Map({\n zoom: 4.5,\n center: [116.412427, 39.303573],\n }),\n});\n\nconst url =\n 'https://mvt.amap.com/district/CHN3/{z}/{x}/{y}/4096?key=309f07ac6bc48160e80b480ae511e1e9&version=';\nconst source = new Source(url, {\n parser: {\n type: 'mvt',\n tileSize: 256,\n warp: false,\n },\n});\n\nscene.on('loaded', () => {\n const colors = {};\n const getColorByAdcode = function (adcode) {\n if (!colors[adcode]) {\n const gb = Math.floor(Math.random() * 155 + 50);\n colors[adcode] = 'rgb(' + gb + ',' + gb + ',255)';\n }\n\n return colors[adcode];\n };\n // 绿地\n const fill = new PolygonLayer({\n sourceLayer: 'CHN_Districts',\n })\n .source(source)\n .shape('fill')\n .color('adcode', getColorByAdcode);\n\n const line = new LineLayer({\n sourceLayer: 'CHN_Districts_L',\n })\n .source(source)\n .shape('simple')\n .color('#fee0d2');\n\n const line2 = new LineLayer({\n sourceLayer: 'CHN_Citys_L',\n })\n .source(source)\n .shape('line')\n .size(0.6)\n .color('#fc9272');\n\n const line3 = new LineLayer({\n sourceLayer: 'CHN_Provinces_L',\n })\n .source(source)\n .shape('line')\n .size(0.6)\n .color('#de2d26');\n\n scene.addLayer(fill);\n scene.addLayer(line);\n scene.addLayer(line2);\n scene.addLayer(line3);\n // scene.addLayer(line2);\n // const debugerLayer = new TileDebugLayer({ usage: 'basemap' });\n // scene.addLayer(debugerLayer);\n});\n",title:"中国区县地图",filename:"chinadistrictmap.ts",isNew:!1},{id:"chinamap",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*kY2sRLu2sTYAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport {\n Scene,\n Source,\n PolygonLayer,\n PointLayer,\n LineLayer,\n} from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nconst colors = {};\nconst GDPSpeed = {\n '520000': 10, //贵州\n '540000': 10, //西藏\n '530000': 8.5, //云南\n '500000': 8.5, //重庆\n '360000': 8.5, //江西\n '340000': 8.0, //安徽\n '510000': 7.5, //四川\n '350000': 8.5, //福建\n '430000': 8.0, //湖南\n '420000': 7.5, //湖北\n '410000': 7.5, //河南\n '330000': 7.0, //浙江\n '640000': 7.5, //宁夏\n '650000': 7.0, //新疆\n '440000': 7.0, //广东\n '370000': 7.0, //山东\n '450000': 7.3, //广西\n '630000': 7.0, //青海\n '320000': 7.0, //江苏\n '140000': 6.5, //山西\n '460000': 7, // 海南\n '310000': 6.5, //上海\n '110000': 6.5, // 北京\n '130000': 6.5, // 河北\n '230000': 6, // 黑龙江\n '220000': 6, // 吉林\n '210000': 6.5, //辽宁\n '150000': 6.5, //内蒙古\n '120000': 5, // 天津\n '620000': 6, // 甘肃\n '610000': 8.5, // 甘肃\n '710000': 6.64, //台湾\n '810000': 6.0, //香港\n '820000': 6.7, //澳门\n};\nconst getColorByDGP = function (adcode) {\n if (!colors[adcode]) {\n const gdp = GDPSpeed[adcode];\n if (!gdp) {\n colors[adcode] = 'rgb(227,227,227)';\n } else {\n const rg = 255 - Math.floor(((gdp - 5) / 5) * 255);\n colors[adcode] = 'rgb(' + rg + ',' + rg + ',255)';\n }\n }\n return colors[adcode];\n};\n\nconst scene = new Scene({\n id: 'map',\n \n map: new Map({\n center: [112, 30],\n\n // zoom: 12,\n zoom: 3,\n }),\n});\n\nconst url =\n 'https://mvt.amap.com/district/CHN2/{z}/{x}/{y}/4096?key=309f07ac6bc48160e80b480ae511e1e9&version=';\nconst source = new Source(url, {\n parser: {\n type: 'mvt',\n tileSize: 256,\n warp: false,\n },\n});\n\nscene.on('loaded', () => {\n // 绿地\n const fill = new PolygonLayer({\n sourceLayer: 'CHN_Cities',\n })\n .source(source)\n .shape('fill')\n .color('adcode_pro', getColorByDGP);\n\n const line = new LineLayer({\n sourceLayer: 'CHN_Cities_L',\n })\n .source(source)\n .shape('line')\n .color('#FFA500');\n\n const line2 = new LineLayer({\n sourceLayer: 'CHN_L',\n })\n .source(source)\n .shape('line')\n .size(0.6)\n .color('#053061');\n\n const text = new PointLayer({\n sourceLayer: 'CHN_Cities',\n blend: 'normal',\n })\n .source(source)\n .shape('id', 'text')\n .size(12)\n .color('#000');\n scene.addLayer(fill);\n scene.addLayer(line);\n scene.addLayer(line2);\n scene.addLayer(text);\n});\n",title:"中国城市地图",filename:"chinamap.ts",isNew:!1},{id:"point",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*LF3vSbPk2ZEAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { Scene, PointLayer } from '@antv/l7';\n// @ts-ignore\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [112, 30],\n zoom: 3,\n style:'normal'\n }),\n});\n\nconst layer = new PointLayer({\n featureId: 'COLOR',\n sourceLayer: 'ecoregions2', // woods hillshade contour ecoregions ecoregions2 city\n});\nlayer\n .source(\n 'http://ganos.oss-cn-hangzhou.aliyuncs.com/m2/rs_l7/{z}/{x}/{y}.pbf',\n {\n parser: {\n type: 'mvt',\n tileSize: 256,\n zoomOffset: 0,\n maxZoom: 9,\n extent: [-180, -85.051129, 179, 85.051129],\n },\n },\n )\n .shape('circle')\n .color('COLOR')\n .size(10);\n// .select(true);\n\nscene.on('loaded', () => {\n scene.addLayer(layer);\n});\n",title:"瓦片点图层",filename:"point.ts",isNew:!1},{id:"polygon",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*OLv5T4PTzH4AAAAAAAAAAAAADmJ7AQ/fmt.webp",source:"// @ts-ignore\nimport { Scene, PolygonLayer, PointLayer } from '@antv/l7';\n// @ts-ignore\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n \n map: new GaodeMap({\n center: [112, 30],\n zoom: 3,\n }),\n});\n\nconst layer = new PolygonLayer({\n featureId: 'COLOR',\n sourceLayer: 'ecoregions2', // woods hillshade contour ecoregions ecoregions2 city\n});\nlayer\n .source(\n 'http://ganos.oss-cn-hangzhou.aliyuncs.com/m2/rs_l7/{z}/{x}/{y}.pbf',\n {\n parser: {\n type: 'mvt',\n tileSize: 256,\n maxZoom: 9,\n extent: [-180, -85.051129, 179, 85.051129],\n },\n },\n )\n // .shape('line')\n .color('COLOR')\n // .active(true)\n .size(10)\n .select(true)\n\n .style({\n // opacity: 0.3\n });\n\nconst point = new PointLayer({ zIndex: 1 })\n .source(\n [\n {\n lng: 120,\n lat: 30,\n },\n ],\n {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat',\n },\n },\n )\n .shape('circle')\n .size(40)\n .active(true)\n .color('#f00');\n\nscene.on('loaded', () => {\n scene.addLayer(layer);\n\n setTimeout(() => {\n point.setData([\n {\n lng: 123,\n lat: 30,\n },\n ]);\n\n point.color('#ff0');\n scene.render();\n console.log('update');\n }, 3000);\n // layer.on('inited', () => {\n // console.log(\n // 'layer.getLayerConfig().enableHighlight',\n // layer.getLayerConfig().enableHighlight,\n // );\n // });\n\n layer.on('click', (e) => {\n console.log('click');\n console.log(e);\n });\n\n scene.addLayer(point);\n});\n",title:"面图层",filename:"polygon.ts",isNew:!1},{id:"simpleline",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*cF8gRqAdXTMAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { Scene, LineLayer } from '@antv/l7';\n// @ts-ignore\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n \n map: new GaodeMap({\n style:\"light\",\n center: [112, 30],\n zoom: 6,\n }),\n});\n\nconst layer = new LineLayer({\n featureId: 'COLOR',\n sourceLayer: 'ecoregions2', // woods hillshade contour ecoregions ecoregions2 city\n});\nlayer\n .source(\n 'http://ganos.oss-cn-hangzhou.aliyuncs.com/m2/rs_l7/{z}/{x}/{y}.pbf',\n {\n parser: {\n type: 'mvt',\n tileSize: 256,\n zoomOffset: 0,\n maxZoom: 9,\n },\n },\n )\n .shape('simple')\n .color('COLOR')\n .size(1)\n .select(true);\nscene.on('loaded', () => {\n scene.addLayer(layer);\n});\n",title:"线图层",filename:"simpleline.ts",isNew:!1},{id:"worldmap",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*v9uTSJpdeksAAAAAAAAAAAAADmJ7AQ/original",source:'// @ts-ignore\nimport {\n Scene,\n Source,\n PolygonLayer,\n LineLayer,\n PointLayer\n} from \'@antv/l7\';\n// @ts-ignore\nimport { GaodeMap } from \'@antv/l7-maps\';\n\nconst data = [{ "name": "美国", "qz": "82404" }, { "name": "格陵兰(丹)", "qz": "18" }, { "name": "中国", "qz": "79404" }, { "name": "意大利", "qz": "80539" }, { "name": "西班牙", "qz": "56188" }, { "name": "德国", "qz": "36508" }, { "name": "伊朗", "qz": "29406" }, { "name": "法国", "qz": "29155" }, { "name": "英国", "qz": "11658" }, { "name": "韩国", "qz": "9232" }, { "name": "瑞士", "qz": "8789" }, { "name": "荷兰", "qz": "7431" }, { "name": "比利时", "qz": "6235" }, { "name": "奥地利", "qz": "5888" }, { "name": "土耳其", "qz": "3629" }, { "name": "加拿大", "qz": "3409" }, { "name": "葡萄牙", "qz": "2995" }, { "name": "挪威", "qz": "2916" }, { "name": "澳大利亚", "qz": "2799" }, { "name": "瑞典", "qz": "2510" }, { "name": "巴西", "qz": "2433" }, { "name": "以色列", "qz": "2369" }, { "name": "马来西亚", "qz": "2031" }, { "name": "爱尔兰", "qz": "1819" }, { "name": "丹麦", "qz": "1724" }, { "name": "捷克", "qz": "1654" }, { "name": "卢森堡", "qz": "1453" }, { "name": "日本", "qz": "1313" }, { "name": "厄瓜多尔", "qz": "1211" }, { "name": "智利", "qz": "1142" }, { "name": "巴基斯坦", "qz": "1057" }, { "name": "波兰", "qz": "1051" }, { "name": "泰国", "qz": "1045" }, { "name": "罗马尼亚", "qz": "906" }, { "name": "沙特阿拉伯", "qz": "900" }, { "name": "印度尼西亚", "qz": "893" }, { "name": "芬兰", "qz": "880" }, { "name": "俄罗斯", "qz": "840" }, { "name": "希腊", "qz": "821" }, { "name": "冰岛", "qz": "737" }, { "name": "钻石公主号邮轮", "qz": "712" }, { "name": "南非", "qz": "709" }, { "name": "印度", "qz": "694" }, { "name": "菲律宾", "qz": "636" }, { "name": "新加坡", "qz": "631" }, { "name": "巴拿马", "qz": "558" }, { "name": "卡塔尔", "qz": "537" }, { "name": "斯洛文尼亚", "qz": "528" }, { "name": "阿根廷", "qz": "502" }, { "name": "秘鲁", "qz": "480" }, { "name": "墨西哥", "qz": "478" }, { "name": "哥伦比亚", "qz": "470" }, { "name": "埃及", "qz": "456" }, { "name": "巴林", "qz": "419" }, { "name": "克罗地亚", "qz": "418" }, { "name": "爱沙尼亚", "qz": "404" }, { "name": "多米尼加共和国", "qz": "392" }, { "name": "塞尔维亚", "qz": "384" }, { "name": "黎巴嫩", "qz": "368" }, { "name": "伊拉克", "qz": "346" }, { "name": "阿拉伯联合酋长国", "qz": "333" }, { "name": "亚美尼亚", "qz": "290" }, { "name": "立陶宛", "qz": "290" }, { "name": "新西兰", "qz": "262" }, { "name": "匈牙利", "qz": "261" }, { "name": "阿尔及利亚", "qz": "246" }, { "name": "保加利亚", "qz": "242" }, { "name": "摩洛哥", "qz": "225" }, { "name": "拉脱维亚", "qz": "221" }, { "name": "乌拉圭", "qz": "217" }, { "name": "斯洛伐克", "qz": "216" }, { "name": "安道尔共和国", "qz": "213" }, { "name": "圣马力诺", "qz": "208" }, { "name": "科威特", "qz": "208" }, { "name": "哥斯达黎加", "qz": "201" }, { "name": "北马其顿共和国", "qz": "177" }, { "name": "阿尔巴尼亚", "qz": "174" }, { "name": "波斯尼亚和黑塞哥维那", "qz": "173" }, { "name": "突尼斯", "qz": "173" }, { "name": "约旦", "qz": "172" }, { "name": "乌克兰", "qz": "156" }, { "name": "摩尔多瓦", "qz": "149" }, { "name": "布基纳法索", "qz": "146" }, { "name": "越南", "qz": "141" }, { "name": "塞浦路斯", "qz": "132" }, { "name": "法罗群岛", "qz": "132" }, { "name": "马耳他", "qz": "129" }, { "name": "文莱", "qz": "109" }, { "name": "委内瑞拉", "qz": "107" }, { "name": "塞内加尔", "qz": "105" }, { "name": "斯里兰卡", "qz": "102" }, { "name": "阿曼", "qz": "99" }, { "name": "柬埔寨", "qz": "98" }, { "name": "哈萨克斯坦", "qz": "97" }, { "name": "阿塞拜疆", "qz": "93" }, { "name": "白俄罗斯", "qz": "86" }, { "name": "留尼汪岛", "qz": "83" }, { "name": "阿富汗", "qz": "80" }, { "name": "科特迪瓦", "qz": "80" }, { "name": "格鲁吉亚", "qz": "77" }, { "name": "瓜德罗普", "qz": "76" }, { "name": "喀麦隆", "qz": "72" }, { "name": "科索沃地区", "qz": "71" }, { "name": "加纳", "qz": "68" }, { "name": "马提尼克", "qz": "66" }, { "name": "乌兹别克斯坦", "qz": "65" }, { "name": "巴勒斯坦", "qz": "64" }, { "name": "特立尼达和多巴哥", "qz": "60" }, { "name": "古巴", "qz": "57" }, { "name": "黑山", "qz": "52" }, { "name": "洪都拉斯", "qz": "52" }, { "name": "波多黎各", "qz": "51" }, { "name": "刚果(金)", "qz": "51" }, { "name": "列支敦士登", "qz": "51" }, { "name": "毛里求斯", "qz": "47" }, { "name": "尼日利亚", "qz": "46" }, { "name": "吉尔吉斯斯坦", "qz": "44" }, { "name": "巴拉圭", "qz": "41" }, { "name": "卢旺达", "qz": "41" }, { "name": "玻利维亚", "qz": "39" }, { "name": "孟加拉国", "qz": "39" }, { "name": "关岛", "qz": "37" }, { "name": "马约特岛", "qz": "35" }, { "name": "肯尼亚", "qz": "31" }, { "name": "根西岛", "qz": "30" }, { "name": "法属圭亚那", "qz": "28" }, { "name": "牙买加", "qz": "26" }, { "name": "直布罗陀", "qz": "26" }, { "name": "法属玻利尼西亚", "qz": "25" }, { "name": "危地马拉", "qz": "24" }, { "name": "多哥", "qz": "23" }, { "name": "马恩岛", "qz": "23" }, { "name": "摩纳哥", "qz": "23" }, { "name": "阿鲁巴岛", "qz": "19" }, { "name": "马达加斯加", "qz": "19" }, { "name": "巴巴多斯", "qz": "18" }, { "name": "泽西岛", "qz": "18" }, { "name": "美属维尔京群岛", "qz": "17" }, { "name": "新喀里多尼亚", "qz": "14" }, { "name": "乌干达", "qz": "14" }, { "name": "马尔代夫", "qz": "13" }, { "name": "坦桑尼亚", "qz": "13" }, { "name": "萨尔瓦多", "qz": "13" }, { "name": "吉布提", "qz": "12" }, { "name": "埃塞俄比亚", "qz": "12" }, { "name": "赤道几内亚", "qz": "11" }, { "name": "法属圣马丁岛", "qz": "11" }, { "name": "蒙古", "qz": "10" }, { "name": "海地", "qz": "8" }, { "name": "开曼群岛", "qz": "8" }, { "name": "塞舌尔", "qz": "7" }, { "name": "百慕大群岛", "qz": "7" }, { "name": "苏里南", "qz": "7" }, { "name": "加蓬", "qz": "6" }, { "name": "库拉索", "qz": "6" }, { "name": "圭亚那", "qz": "5" }, { "name": "叙利亚", "qz": "5" }, { "name": "格林兰岛", "qz": "5" }, { "name": "中非共和国", "qz": "5" }, { "name": "莫桑比克", "qz": "5" }, { "name": "斐济", "qz": "5" }, { "name": "贝宁", "qz": "5" }, { "name": "纳米比亚", "qz": "5" }, { "name": "巴哈马", "qz": "5" }, { "name": "缅甸", "qz": "5" }, { "name": "几内亚", "qz": "5" }, { "name": "史瓦帝尼", "qz": "4" }, { "name": "斯威士兰", "qz": "4" }, { "name": "厄立特里亚", "qz": "4" }, { "name": "梵蒂冈", "qz": "4" }, { "name": "刚果(布)", "qz": "4" }, { "name": "尼日尔", "qz": "4" }, { "name": "老挝", "qz": "3" }, { "name": "安提瓜和巴布达", "qz": "3" }, { "name": "圣卢西亚", "qz": "3" }, { "name": "圣巴泰勒米岛", "qz": "3" }, { "name": "尼泊尔", "qz": "3" }, { "name": "乍得", "qz": "3" }, { "name": "苏丹", "qz": "3" }, { "name": "利比里亚", "qz": "3" }, { "name": "佛得角", "qz": "3" }, { "name": "赞比亚", "qz": "3" }, { "name": "毛里塔尼亚", "qz": "2" }, { "name": "索马里", "qz": "2" }, { "name": "尼加拉瓜", "qz": "2" }, { "name": "马里", "qz": "2" }, { "name": "几内亚比绍", "qz": "2" }, { "name": "多米尼克", "qz": "2" }, { "name": "圣基茨和尼維斯", "qz": "2" }, { "name": "蒙特塞拉特", "qz": "2" }, { "name": "冈比亚", "qz": "2" }, { "name": "伯利兹", "qz": "2" }, { "name": "安哥拉", "qz": "2" }, { "name": "津巴布韦", "qz": "2" }, { "name": "不丹", "qz": "2" }, { "name": "荷属圣马丁", "qz": "2" }, { "name": "圣文森特和格林纳丁斯", "qz": "1" }, { "name": "东帝汶", "qz": "1" }, { "name": "格林纳达", "qz": "1" }, { "name": "特克斯和凯科斯群岛", "qz": "1" }, { "name": "利比亚", "qz": "1" }, { "name": "巴布亚新几内亚", "qz": "1" }];\n\nconst counts = [10000, 5000, 1000, 500, 100];\nconst color = [\'#fcfbfd\',\'#efedf5\',\'#dadaeb\',\'#bcbddc\',\'#9e9ac8\',\'#807dba\',\'#6a51a3\',\'#4a1486\'].reverse();\nconst scene = new Scene({\n id: \'map\',\n \n map: new GaodeMap({\n center: [100, 30],\n minZoom: 0,\n zoom: 2,\n }),\n});\n\nconst url =\n \'https://mvt.amap.com/district/WLD/{z}/{x}/{y}/4096?key=309f07ac6bc48160e80b480ae511e1e9&version=\';\nconst source = new Source(url, {\n parser: {\n type: \'mvt\',\n tileSize: 256,\n warp: false,\n },\n});\nfunction unicode2Char(name) {\n const code = name\n .split(\'/\')\n .slice(1)\n .map((c) => {\n return String.fromCharCode(\'0x\' + c);\n });\n return code.join(\'\');\n}\n\nscene.on(\'loaded\', () => {\n // 绿地\n const water_surface = new PolygonLayer({\n sourceLayer: \'WLD\',\n zIndex: 1,\n })\n .source(source)\n .select(true)\n .active(false)\n .shape(\'fill\')\n // .color(\'red\')\n .color(\'NAME_CHN\', (NAME_CHN) => {\n const namestr = unicode2Char(NAME_CHN);\n const country = data.find((c) => {\n return c.name == namestr;\n });\n if (!country) {\n return \'#ffff33\';\n }\n const qz = ((country.qz as unknown) as number) * 1;\n if (qz > counts[0]) {\n return color[0];\n } else if (qz > counts[1]) {\n return color[1];\n } else if (qz > counts[2]) {\n return color[2];\n } else if (qz > counts[3]) {\n return color[3];\n } else {\n return color[4];\n }\n });\n\n const line = new LineLayer({\n sourceLayer: \'WLD_L\',\n zIndex: 2,\n })\n .source(source)\n .shape(\'line\')\n .size(0.6)\n .color(\'type\', (t) => {\n if (t === \'0\') {\n return \'red\';\n }\n if (t === \'2\') {\n return \'#09f\';\n }\n return \'#fc9272\';\n });\n\n const text = new PointLayer({\n sourceLayer: \'WLD\',\n blend: \'normal\',\n zIndex: 10,\n })\n .source(source)\n .shape(\'NAME_CHN\', (NAME_CHN) => {\n return unicode2Char(NAME_CHN);\n })\n .size(12)\n .color(\'#000\');\n\n // water_surface.on(\'click\', (e) => {\n // console.log(e);\n // });\n\n\n scene.addLayer(water_surface);\n scene.addLayer(text);\n scene.addLayer(line);\n});\n',title:"世界地图-瓦片",filename:"worldmap.ts",isNew:!1},{id:"geojson-vt",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*amqiQaYHIKYAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { Scene, Source, PolygonLayer } from '@antv/l7';\n// @ts-ignore\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [121.268, 30.3628],\n pitch: 0,\n zoom: 4,\n }),\n});\n\nfetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/2b7aae6e-5f40-437f-8047-100e9a0d2808.json',\n)\n .then((d) => d.json())\n .then((data) => {\n const source = new Source(data, {\n parser: {\n type: 'geojsonvt',\n tileSize: 256,\n zoomOffset: 0,\n maxZoom: 9,\n // extent: [-180, -85.051129, 179, 85.051129],\n },\n });\n\n const polygon = new PolygonLayer({\n featureId: 'COLOR',\n })\n .source(source)\n .color('COLOR')\n .shape('fill')\n // .active(true)\n // .select(true)\n .style({\n opacity: 0.6,\n });\n scene.addLayer(polygon);\n\n });\n",title:"GeoJSON-Vt",filename:"geojson-vt.ts",isNew:!1}],icon:"",id:"vector",title:{en:"Vector Tile",zh:"矢量瓦片"},childrenKey:"demos",order:0}],childrenKey:"examples"},{id:"component",title:{zh:"组件",en:"Component"},icon:"map",examples:[{demos:[{id:"logo",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*XgipRbN_k3wAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GaodeMap, Logo } from '@antv/l7';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n // 关闭默认 L7 Logo\n logoVisible: false,\n});\nscene.on('loaded', () => {\n const logo = new Logo();\n scene.addControl(logo);\n});\n",title:{zh:"Logo",en:"Logo"},filename:"logo.ts",isNew:!1},{id:"zoom",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*PRkHRonRENYAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GaodeMap, Zoom } from '@antv/l7';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n});\nscene.on('loaded', () => {\n const zoom = new Zoom();\n scene.addControl(zoom);\n});\n",title:{zh:"Zoom 缩放",en:"Zoom"},filename:"zoom.ts",isNew:!1},{id:"scale",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*5dWeRaRpOHEAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GaodeMap, Scale } from '@antv/l7';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n logoVisible: false,\n});\nscene.on('loaded', () => {\n const scale = new Scale();\n scene.addControl(scale);\n});\n",title:{zh:"Scale 比例尺",en:"Scale"},filename:"scale.ts",isNew:!1},{id:"fullscreen",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*fqJlQ5vJVicAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GaodeMap, Fullscreen } from '@antv/l7';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n});\nscene.on('loaded', () => {\n const fullscreen = new Fullscreen();\n scene.addControl(fullscreen);\n});\n",title:{zh:"Fullscreen 全屏",en:"Fullscreen"},filename:"fullscreen.ts",isNew:!1},{id:"geolocate",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*aElZR7bPFGAAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GaodeMap, GeoLocate } from '@antv/l7';\nimport gcoord from 'gcoord';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n});\nscene.on('loaded', () => {\n const geoLocate = new GeoLocate({\n transform: (position) => {\n // 将获取到基于 WGS84 地理坐标系 的坐标转成 GCJ02 坐标系\n return gcoord.transform(position, gcoord.WGS84, gcoord.GCJ02);\n },\n });\n scene.addControl(geoLocate);\n});\n",title:{zh:"GeoLocate 定位",en:"GeoLocate"},filename:"geolocate.ts",isNew:!1},{id:"exportimage",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*at1HRbHfipUAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GaodeMap, ExportImage, PolygonLayer } from '@antv/l7';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n WebGLParams: {\n preserveDrawingBuffer: true,\n },\n }),\n});\nscene.on('loaded', () => {\n const polygonLayer = new PolygonLayer({});\n polygonLayer\n .source({\n type: 'FeatureCollection',\n features: [\n {\n type: 'Feature',\n properties: {},\n geometry: {\n type: 'Polygon',\n coordinates: [\n [\n [120.143575, 30.239811],\n [120.143575, 30.247856],\n [120.151213, 30.247856],\n [120.151213, 30.239811],\n [120.143575, 30.239811],\n ],\n ],\n },\n },\n ],\n })\n .color('#ff0000')\n .style({\n opacity: 0.5,\n });\n scene.addLayer(polygonLayer);\n const exportImage = new ExportImage({\n onExport: (base64) => {\n alert(base64);\n },\n });\n scene.addControl(exportImage);\n});\n",title:{zh:"ExportImage 导出图片",en:"ExportImage"},filename:"exportimage.ts",isNew:!1},{id:"mouselocation",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*sJF1S4JaPx8AAAAAAAAAAAAAARQnAQ",source:"import { Scene, GaodeMap, MouseLocation } from '@antv/l7';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n});\nscene.on('loaded', () => {\n const mouseLocation = new MouseLocation({\n position: 'bottomright',\n });\n scene.addControl(mouseLocation);\n});\n",title:{zh:"MouseLocation 鼠标经纬度",en:"MouseLocation"},filename:"mouselocation.ts",isNew:!1},{id:"layerswitch",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*gWO_T6xpVtwAAAAAAAAAAAAAARQnAQ",source:"import {\n Scene,\n GaodeMap,\n PolygonLayer,\n LayerSwitch,\n LineLayer,\n} from '@antv/l7';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n});\nscene.on('loaded', () => {\n const polygonLayer = new PolygonLayer({\n name: '填充图层',\n });\n polygonLayer\n .source({\n type: 'FeatureCollection',\n features: [\n {\n type: 'Feature',\n properties: {},\n geometry: {\n type: 'Polygon',\n coordinates: [\n [\n [120.143575, 30.239811],\n [120.143575, 30.247856],\n [120.151213, 30.247856],\n [120.151213, 30.239811],\n [120.143575, 30.239811],\n ],\n ],\n },\n },\n ],\n })\n .color('#ff0000')\n .style({\n opacity: 0.5,\n });\n scene.addLayer(polygonLayer);\n\n const lineLayer = new LineLayer({\n name: '边框图层',\n });\n lineLayer\n .source({\n type: 'FeatureCollection',\n features: [\n {\n type: 'Feature',\n properties: {},\n geometry: {\n type: 'Polygon',\n coordinates: [\n [\n [120.143575, 30.239811],\n [120.143575, 30.247856],\n [120.151213, 30.247856],\n [120.151213, 30.239811],\n [120.143575, 30.239811],\n ],\n ],\n },\n },\n ],\n })\n .color('#700000')\n .size(2);\n scene.addLayer(lineLayer);\n\n const layerSwitch = new LayerSwitch({\n layers: [polygonLayer, lineLayer],\n });\n scene.addControl(layerSwitch);\n});\n",title:{zh:"LayerSwitch 图层显隐控制",en:"LayerSwitch"},filename:"layerswitch.ts",isNew:!1},{id:"maptheme",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*byM3QZbjqScAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GaodeMap, MapTheme } from '@antv/l7';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n});\nscene.on('loaded', () => {\n const mapTheme = new MapTheme();\n scene.addControl(mapTheme);\n});\n",title:{zh:"MapTheme 地图样式切换",en:"MapTheme"},filename:"maptheme.ts",isNew:!1}],icon:"",id:"control",title:{en:"Controls",zh:"控件"},childrenKey:"demos",order:0},{demos:[{id:"popup",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*cNMlSLwgjboAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GaodeMap, Popup } from '@antv/l7';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n logoVisible: false,\n});\nscene.on('loaded', () => {\n const popup = new Popup({\n title: '自定义标题',\n html: '

Popup 示例的自定义内容

',\n lngLat: {\n lng: 120.154672,\n lat: 30.241095,\n },\n });\n\n scene.addPopup(popup);\n});\n",title:{zh:"Popup 基础气泡",en:"Popup"},filename:"popup.ts",isNew:!1},{id:"popup2",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*cNMlSLwgjboAAAAAAAAAAAAAARQnAQ",source:"// @ts-ignore\nimport { PointLayer, Scene, Popup } from '@antv/l7';\n// @ts-ignore\nimport { GaodeMap } from '@antv/l7-maps';\n\nasync function initMap() {\n const response = await fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/893d1d5f-11d9-45f3-8322-ee9140d288ae.json',\n );\n const scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [121.4, 31.258134],\n zoom: 12,\n pitch: 0,\n style: 'normal',\n }),\n });\n scene.addImage(\n '00',\n 'https://gw.alipayobjects.com/mdn/rms_fcd5b3/afts/img/A*g8cUQ7pPT9YAAAAAAAAAAAAAARQnAQ',\n );\n scene.addImage(\n '01',\n 'https://gw.alipayobjects.com/mdn/rms_fcd5b3/afts/img/A*LTcXTLBM7kYAAAAAAAAAAAAAARQnAQ',\n );\n scene.addImage(\n '02',\n 'https://gw.alipayobjects.com/zos/bmw-prod/904d047a-16a5-461b-a921-98fa537fc04a.svg',\n );\n const data = await response.json();\n const newData = data.map((item: any) => {\n item.type = ['00', '01', '02'][Math.floor(Math.random() * 3)];\n return item;\n });\n const imageLayer = new PointLayer({\n })\n .source(newData, {\n parser: {\n type: 'json',\n x: 'longitude',\n y: 'latitude',\n },\n })\n .shape('type', (v: any) => {\n return v;\n })\n .active(false)\n .size(20);\n scene.addLayer(imageLayer);\n imageLayer.on('mousedown', (e) => {\n console.log('mousedown', e);\n });\n const popup = new Popup({\n });\n\n scene.addPopup(popup);\n imageLayer.on('click', (e) => {\n console.log(e)\n const { lng, lat } = e.lngLat\n\n popup.setOptions({\n title: e.feature.name,\n html: e.feature.name,\n lngLat: {\n lng,\n lat,\n },\n });\n\n });\n}\n\ninitMap();",title:{zh:"图层点击 气泡",en:"Popup"},filename:"popup2.ts",isNew:!1},{id:"layerpopup",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*HbyzRqv6JZcAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GaodeMap, LayerPopup, PointLayer } from '@antv/l7';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n logoVisible: false,\n});\nscene.on('loaded', () => {\n const pointLayer = new PointLayer({});\n pointLayer\n .source(\n [\n {\n lng: 120.132235,\n lat: 30.250868,\n value: 34.71314604052238,\n name: '坐标点1',\n },\n {\n lng: 120.156236,\n lat: 30.260268,\n value: 96.807880210153,\n name: '坐标点2',\n },\n {\n lng: 120.163014,\n lat: 30.251297,\n value: 29.615472482876815,\n name: '坐标点3',\n },\n {\n lng: 120.15394,\n lat: 30.231489,\n value: 49.90316258911784,\n name: '坐标点4',\n },\n {\n lng: 120.154596,\n lat: 30.24065,\n value: 45.788587061188466,\n name: '坐标点5',\n },\n {\n lng: 120.150223,\n lat: 30.235078,\n value: 29.741111717098544,\n name: '坐标点6',\n },\n {\n lng: 120.143992,\n lat: 30.229411,\n value: 40.241555782182935,\n name: '坐标点7',\n },\n {\n lng: 120.136995,\n lat: 30.237439,\n value: 86.5369792415296,\n name: '坐标点8',\n },\n ],\n {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat',\n },\n },\n )\n .color('value', ['#FFCCC6', '#CF1421'])\n .size(10)\n .shape('circle');\n scene.addLayer(pointLayer);\n const layerPopup = new LayerPopup({\n items: [\n {\n layer: pointLayer,\n fields: [\n {\n field: 'name',\n formatField: () => '名称',\n },\n {\n field: 'value',\n formatField: () => '权值',\n formatValue: (val) => val.toFixed(2),\n },\n 'lng',\n 'lat',\n ],\n },\n ],\n });\n\n scene.addPopup(layerPopup);\n});\n",title:{zh:"LayerPopup 图层气泡",en:"LayerPopup"},filename:"layerpopup.ts",isNew:!1},{id:"customContent",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*orwHQKugIdIAAAAAAAAAAAAADmJ7AQ/original",source:"import * as G2 from '@antv/g2';\nimport { GaodeMap, LayerPopup, PointLayer, Scene } from '@antv/l7';\n\nconst data: any[] = [\n {\n lng: 120.132235,\n lat: 30.250868,\n value: 34.71314604052238,\n name: '坐标点1',\n },\n {\n lng: 120.156236,\n lat: 30.260268,\n value: 96.807880210153,\n name: '坐标点2',\n },\n {\n lng: 120.163014,\n lat: 30.251297,\n value: 29.615472482876815,\n name: '坐标点3',\n },\n {\n lng: 120.15394,\n lat: 30.231489,\n value: 49.90316258911784,\n name: '坐标点4',\n },\n {\n lng: 120.154596,\n lat: 30.24065,\n value: 45.788587061188466,\n name: '坐标点5',\n },\n {\n lng: 120.150223,\n lat: 30.235078,\n value: 29.741111717098544,\n name: '坐标点6',\n },\n {\n lng: 120.143992,\n lat: 30.229411,\n value: 40.241555782182935,\n name: '坐标点7',\n },\n {\n lng: 120.136995,\n lat: 30.237439,\n value: 86.5369792415296,\n name: '坐标点8',\n },\n];\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n logoVisible: false,\n});\nscene.on('loaded', () => {\n const pointLayer = new PointLayer({});\n pointLayer\n .source(data, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat',\n },\n })\n .color('value', ['#FFCCC6', '#CF1421'])\n .size(10)\n .shape('circle');\n scene.addLayer(pointLayer);\n\n const div = document.createElement('div');\n const chart = new G2.Chart({\n container: div,\n autoFit: true,\n width: 200,\n height: 200,\n });\n // 新建一个 view 用来单独渲染Annotation\n chart.coordinate('theta', {\n radius: 0.75,\n innerRadius: 0.5,\n });\n\n chart.scale('percent', {\n formatter: (val) => {\n val = val * 100 + '%';\n return val;\n },\n });\n\n chart.tooltip(false);\n\n // 声明需要进行自定义图例字段: 'item'\n chart.legend(false);\n\n chart\n .interval()\n .adjust('stack')\n .position('percent')\n .color('item', ['#5B8FF9', '#797979'])\n .style({\n fillOpacity: 1,\n });\n\n const layerPopup = new LayerPopup({\n items: [\n {\n layer: pointLayer,\n customContent: (e) => {\n const otherValue = 100 - e.value;\n chart.data([\n { item: '值', count: e.value, percent: e.value / 100 },\n { item: '', count: otherValue, percent: otherValue / 100 },\n ]);\n chart.render();\n return div;\n },\n },\n ],\n });\n\n scene.addPopup(layerPopup);\n});\n",title:{zh:"图层气泡 自定义内容",en:"LayerPopup"},filename:"customContent.ts",isNew:!1}],icon:"",id:"popup",title:{en:"Popup",zh:"信息框"},childrenKey:"demos",order:1},{demos:[{id:"defaultmarker",screenshot:"https://mdn.alipayobjects.com/afts/img/A*Lwx2RoaXjmwAAAAAAAAAAAAADrd2AQ/20230207225205.jpg",source:"import { Scene, Marker } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 105.790327, 36.495636 ],\n zoom: 4\n })\n});\nscene.on('loaded', () => {\n addMarkers();\n scene.render();\n});\nfunction addMarkers() {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/67f47049-8787-45fc-acfe-e19924afe032.json'\n )\n .then(res => res.json())\n .then(nodes => {\n for (let i = 0; i < nodes.length; i++) {\n if (nodes[i].g !== '1' || nodes[i].v === '') {\n continue;\n }\n \n const marker = new Marker().setLnglat({ lng: nodes[i].x * 1, lat: nodes[i].y });\n scene.addMarker(marker);\n }\n });\n}\n\n",title:"默认 Marker",filename:"defaultmarker.js",isNew:!1},{id:"markerlayer",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*zb-0TrdH8wUAAAAAAAAAAAAAARQnAQ",source:"import { Scene, Marker, MarkerLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 105.790327, 36.495636 ],\n zoom: 4\n })\n});\nscene.on('loaded', () => {\n addMarkers();\n scene.render();\n});\nfunction addMarkers() {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/67f47049-8787-45fc-acfe-e19924afe032.json'\n )\n .then(res => res.json())\n .then(nodes => {\n const markerLayer = new MarkerLayer();\n for (let i = 0; i < nodes.length; i++) {\n if (nodes[i].g !== '1' || nodes[i].v === '') {\n continue;\n }\n const el = document.createElement('label');\n el.className = 'labelclass';\n el.textContent = nodes[i].v + '℃';\n el.style.background = getColor(nodes[i].v);\n el.style.borderColor = getColor(nodes[i].v);\n const marker = new Marker({\n element: el\n }).setLnglat({ lng: nodes[i].x * 1, lat: nodes[i].y });\n markerLayer.addMarker(marker);\n }\n scene.addMarkerLayer(markerLayer);\n });\n}\n\nfunction getColor(v) {\n const colors = [ '#ffffe5', '#f7fcb9', '#d9f0a3', '#addd8e', '#78c679', '#41ab5d', '#238443', '#005a32' ];\n return v > 50\n ? colors[7]\n : v > 40\n ? colors[6]\n : v > 30\n ? colors[5]\n : v > 20\n ? colors[4]\n : v > 10\n ? colors[3]\n : v > 5\n ? colors[2]\n : v > 0\n ? colors[1]\n : colors[0];\n}\n",title:"MarkerLayer 统一管理Marker",filename:"markerlayer.js",isNew:!1},{id:"clustermarker",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*h6_kQKiM2cwAAAAAAAAAAAAAARQnAQ",source:"import { Scene, Marker, MarkerLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 105.790327, 30 ],\n zoom: 2\n })\n});\nscene.on('loaded', () => {\n addMarkers();\n scene.render();\n});\nfunction addMarkers() {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/d3564b06-670f-46ea-8edb-842f7010a7c6.json'\n )\n .then(res => res.json())\n .then(nodes => {\n const markerLayer = new MarkerLayer({\n cluster: true\n });\n for (let i = 0; i < nodes.features.length; i++) {\n const { coordinates } = nodes.features[i].geometry;\n const marker = new Marker().setLnglat({\n lng: coordinates[0],\n lat: coordinates[1]\n });\n markerLayer.addMarker(marker);\n }\n scene.addMarkerLayer(markerLayer);\n });\n}\n",title:"MarkerLayer 聚合Marker",filename:"clustermarker.js",isNew:!1},{id:"marker",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*m0rwQZBpZ6MAAAAAAAAAAAAAARQnAQ",source:"import { Scene, Marker } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 105.790327, 36.495636 ],\n zoom: 4\n })\n});\nscene.on('loaded', () => {\n addMarkers();\n scene.render();\n});\nfunction addMarkers() {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/67f47049-8787-45fc-acfe-e19924afe032.json'\n )\n .then(res => res.json())\n .then(nodes => {\n for (let i = 0; i < nodes.length; i++) {\n if (nodes[i].g !== '1' || nodes[i].v === '') {\n continue;\n }\n const el = document.createElement('label');\n el.className = 'labelclass';\n el.textContent = nodes[i].v + '℃';\n el.style.background = getColor(nodes[i].v);\n el.style.borderColor = getColor(nodes[i].v);\n const marker = new Marker({\n element: el\n }).setLnglat({ lng: nodes[i].x * 1, lat: nodes[i].y });\n scene.addMarker(marker);\n }\n });\n}\n\nfunction getColor(v) {\n return v > 50\n ? '#800026'\n : v > 40\n ? '#BD0026'\n : v > 30\n ? '#E31A1C'\n : v > 20\n ? '#FC4E2A'\n : v > 10\n ? '#FD8D3C'\n : v > 5\n ? '#FEB24C'\n : v > 0\n ? '#FED976'\n : '#FFEDA0';\n}\n",title:"温度",filename:"marker.js",isNew:!1}],icon:"",id:"marker",title:{en:"Marker",zh:"Marker 标注"},childrenKey:"demos",order:2}],childrenKey:"examples"},{id:"draw",title:{zh:"绘制组件",en:"L7Draw"},icon:"map",examples:[{demos:[{id:"draw_point",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*9UalSKnKqOAAAAAAAAAAAAAAARQnAQ",source:"import { Scene } from '@antv/l7';\nimport { DrawEvent, DrawPoint } from '@antv/l7-draw';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [120.211944, 30.288946],\n zoom: 7.05,\n }),\n});\nscene.on('loaded', () => {\n const drawPoint = new DrawPoint(scene, {});\n drawPoint.enable();\n\n drawPoint.on(DrawEvent.Change, (allFeatures) => {\n console.log(allFeatures);\n });\n\n setInterval(() => {\n console.log(scene.getZoom(), scene.getCenter());\n }, 2000);\n});\n",title:"绘制点",filename:"draw_point.js",isNew:!1},{id:"draw_line",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*y68yToJoy34AAAAAAAAAAAAAARQnAQ",source:"import { Scene } from '@antv/l7';\nimport { DrawEvent, DrawLine } from '@antv/l7-draw';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [120.211944, 30.288946],\n zoom: 7.05,\n }),\n});\nscene.on('loaded', () => {\n const drawLine = new DrawLine(scene, {\n distanceOptions: {},\n });\n drawLine.enable();\n\n drawLine.on(DrawEvent.Change, (allFeatures) => {\n console.log(allFeatures);\n });\n});\n",title:"绘制线",filename:"draw_line.js",isNew:!1},{id:"draw_polygon",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*YmIPSK2bY0oAAAAAAAAAAAAAARQnAQ",source:"import { Scene } from '@antv/l7';\nimport { DrawEvent, DrawPolygon } from '@antv/l7-draw';\nimport { GaodeMap } from '@antv/l7-maps';\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [120.211944, 30.288946],\n zoom: 7.05,\n }),\n});\nscene.on('loaded', () => {\n const drawPolygon = new DrawPolygon(scene, {\n areaOptions: {},\n });\n drawPolygon.enable();\n\n drawPolygon.on(DrawEvent.Change, (allFeatures) => {\n console.log(allFeatures);\n });\n});\n",title:"绘制面",filename:"draw_polygon.js",isNew:!1},{id:"draw_rect",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*X_IGRrjsPCoAAAAAAAAAAAAAARQnAQ",source:"import { Scene } from '@antv/l7';\nimport { DrawEvent, DrawRect } from '@antv/l7-draw';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [120.211944, 30.288946],\n zoom: 7.05,\n }),\n});\nscene.on('loaded', () => {\n const drawRect = new DrawRect(scene, {});\n drawRect.enable();\n\n drawRect.on(DrawEvent.Change, (allFeatures) => {\n console.log(allFeatures);\n });\n});\n",title:"绘制矩形",filename:"draw_rect.js",isNew:!1},{id:"draw_circle",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*bnaxRLpYvdwAAAAAAAAAAAAAARQnAQ",source:"import { Scene } from '@antv/l7';\nimport { DrawCircle, DrawEvent } from '@antv/l7-draw';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [120.211944, 30.288946],\n zoom: 7.05,\n }),\n});\nscene.on('loaded', () => {\n const drawCircle = new DrawCircle(scene, {});\n drawCircle.enable();\n\n drawCircle.on(DrawEvent.Change, (allFeatures) => {\n console.log(allFeatures);\n });\n});\n",title:"绘制圆",filename:"draw_circle.js",isNew:!1}],icon:"",id:"basic",title:{en:"L7Draw",zh:"地图绘制"},childrenKey:"demos",order:3},{demos:[{id:"amap",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*-5KDT6d7pLcAAAAAAAAAAAAAARQnAQ",source:"// https://gw.alipayobjects.com/zos/antvdemo/assets/2019_clip/ndvi_201905.tif\nimport { Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport { ControlEvent, DrawControl } from '@antv/l7-draw';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [116.1608, 40.1119],\n zoom: 15,\n }),\n});\nscene.on('loaded', () => {\n const tileLayer = new AMap.TileLayer.Satellite();\n tileLayer.setMap(scene.map);\n\n const drawControl = new DrawControl(scene, {});\n scene.addControl(drawControl);\n drawControl.on(ControlEvent.DrawChange, (changeType) => {\n console.log(changeType);\n });\n});\n",title:"高德地图绘制",filename:"amap.js",isNew:!1}],icon:"",id:"control",title:{en:"Draw Control",zh:"绘制控件"},childrenKey:"demos",order:3}],childrenKey:"examples"},{id:"wind",title:{zh:"风场图层",en:"Wind Layer"},icon:"raster",examples:[{demos:[{id:"wind",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*ADr-SIxhM9AAAAAAAAAAAAAAARQnAQ",source:"import { Scene, WindLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 90, 32.24997445586331 ],\n style: 'dark',\n zoom: 2\n })\n});\n\nscene.on('loaded', () => {\n const layer = new WindLayer({});\n layer\n .source(\n 'https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*wcU8S5xMEDYAAAAAAAAAAAAAARQnAQ',\n {\n parser: {\n type: 'image',\n extent: [ -180, -85, 180, 85 ]\n }\n }\n )\n .animate(true)\n .style({\n uMin: -21.32,\n uMax: 26.8,\n vMin: -21.57,\n vMax: 21.42,\n numParticles: 35535,\n fadeOpacity: 0.996,\n sizeScale: 1.2,\n rampColors: {\n 0.0: '#3288bd',\n 0.1: '#66c2a5',\n 0.2: '#abdda4',\n 0.3: '#e6f598',\n 0.4: '#fee08b',\n 0.5: '#fdae61',\n 0.6: '#f46d43',\n 1.0: '#d53e4f'\n }\n });\n scene.addLayer(layer);\n});\n",title:"风场图层",filename:"wind.js",isNew:!1}],icon:"",id:"basic",title:{en:"Wind Layer",zh:"风场图层"},childrenKey:"demos",order:7}],childrenKey:"examples"},{id:"earth",title:{zh:"地球模式",en:"Earth Mode"},icon:"map",examples:[{demos:[{id:"flyline",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*hak1RaMjp1MAAAAAAAAAAAAAARQnAQ",source:"import { Scene, EarthLayer, LineLayer } from '@antv/l7';\nimport { Earth } from '@antv/l7-maps';\nconst scene = new Scene({\n id: 'map',\n map: new Earth({})\n});\n\n// 地球模式下背景色默认为 #000 通过 setBgColor 方法我们可以设置可视化层的背景色\nscene.setBgColor('#333');\n\nconst earthlayer = new EarthLayer()\n .source(\n 'https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*3-3NSpqRqUoAAAAAAAAAAAAAARQnAQ',\n {\n parser: {\n type: 'image'\n }\n }\n )\n .color('#2E8AE6')\n .shape('fill')\n .style({\n globalOptions: {\n ambientRatio: 0.6, // 环境光\n diffuseRatio: 0.4, // 漫反射\n specularRatio: 0.1 // 高光反射\n }\n })\n .animate(true);\n\nconst atomLayer = new EarthLayer()\n .color('#2E8AE6')\n .shape('atomSphere');\n\nconst bloomLayer = new EarthLayer().color('#fff').shape('bloomSphere')\n .style({\n opacity: 0.7\n });\n\nscene.on('loaded', () => {\n scene.addLayer(earthlayer);\n\n scene.addLayer(atomLayer);\n scene.addLayer(bloomLayer);\n\n fetch('https://gw.alipayobjects.com/os/bmw-prod/20a69b46-3d6d-4ab5-b8b5-150b6aa52c88.json')\n .then(res => res.json())\n .then(flydata => {\n const flyLine = new LineLayer({ blend: 'normal' })\n .source(flydata, {\n parser: {\n type: 'json',\n coordinates: 'coord'\n }\n })\n .color('#b97feb')\n .shape('arc3d')\n .size(0.5)\n .active(true)\n .animate({\n interval: 2,\n trailLength: 2,\n duration: 1\n })\n .style({\n segmentNumber: 60,\n globalArcHeight: 20\n });\n scene.addLayer(flyLine);\n });\n\n earthlayer.setEarthTime(4.0);\n});\n",title:"飞线",filename:"flyline.js",isNew:!1}],icon:"",id:"arc3d",title:{en:"flyline",zh:"飞线"},childrenKey:"demos",order:0}],childrenKey:"examples"},{id:"geometry",title:{zh:"几何体图层",en:"Geometry Layer"},icon:"raster",examples:[{demos:[{id:"plane",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*BMVzSrx9TpEAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GeometryLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 120.1025, 30.2594 ],\n style: 'dark',\n zoom: 10\n })\n});\n\nscene.on('loaded', () => {\n const layer = new GeometryLayer()\n .shape('plane')\n .style({\n opacity: 0.8,\n width: 0.074,\n height: 0.061,\n center: [ 120.1025, 30.2594 ]\n })\n .active(true)\n .color('#ff0');\n scene.addLayer(layer);\n});\n",title:"平面图层",filename:"plane.js",isNew:!1},{id:"terrain",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*DIb4TaijKIAAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GeometryLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 120.1025, 30.2594 ],\n style: 'dark',\n pitch: 65,\n rotation: 180,\n zoom: 14\n })\n});\nlet currentZoom = 14,\n currentModelData = '100x100';\n\nscene.on('loaded', () => {\n const layer = new GeometryLayer()\n .shape('plane')\n .style({\n width: 0.074,\n height: 0.061,\n center: [ 120.1025, 30.2594 ],\n widthSegments: 100,\n heightSegments: 100,\n terrainClipHeight: 1,\n mapTexture:\n 'https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*gA0NRbuOF5cAAAAAAAAAAAAAARQnAQ',\n terrainTexture:\n 'https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*eYFaRYlnnOUAAAAAAAAAAAAAARQnAQ',\n rgb2height: (r, g, b) => {\n let h =\n -10000.0 +\n (r * 255.0 * 256.0 * 256.0 + g * 255.0 * 256.0 + b * 255.0) * 0.1;\n h = h / 20 - 127600;\n h = Math.max(0, h);\n return h;\n }\n });\n scene.addLayer(layer);\n\n let modelData10,\n modelData20 = null,\n modelData100;\n\n layer.on('terrainImageLoaded', () => {\n\n modelData10 = layer.createModelData([], {\n widthSegments: 10,\n heightSegments: 10\n });\n\n modelData20 = layer.createModelData([], {\n widthSegments: 20,\n heightSegments: 20\n });\n\n modelData100 = layer.createModelData([], {\n widthSegments: 100,\n heightSegments: 100\n });\n });\n\n\n scene.on('zoom', ({ value }) => {\n const zoom = Math.floor(value);\n if (currentZoom !== zoom) {\n if (zoom > 13) {\n if (currentModelData !== '100x100') {\n layer.updateModelData(modelData100);\n currentModelData = '100x100';\n }\n } else if (zoom > 12) {\n if (currentModelData !== '20x20') {\n layer.updateModelData(modelData20);\n currentModelData = '20x20';\n }\n } else {\n if (currentModelData !== '10x10') {\n layer.updateModelData(modelData10);\n currentModelData = '10x10';\n }\n }\n currentZoom = zoom;\n }\n return '';\n });\n});\n",title:"自定义 3D 地形(LOD)",filename:"terrain.js",isNew:!1},{id:"snow",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*jJQtRqa6_f8AAAAAAAAAAAAAARQnAQ",source:"import { Scene, GeometryLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 40,\n style: 'dark',\n center: [ 120, 30 ],\n zoom: 6\n })\n});\n\nscene.on('loaded', () => {\n const layer = new GeometryLayer()\n .shape('sprite')\n .size(10)\n .style({\n mapTexture:\n 'https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*zLQwQKBSagYAAAAAAAAAAAAAARQnAQ', // snow\n center: [ 120, 30 ],\n spriteCount: 60,\n spriteRadius: 10,\n spriteTop: 2500000,\n });\n scene.addLayer(layer);\n});\n",title:"雪花粒子",filename:"snow.js",isNew:!1},{id:"rain",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*rmcvQ5iwyZAAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GeometryLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 90,\n style: 'dark',\n center: [ 120, 30 ],\n zoom: 6\n })\n});\n\nscene.on('loaded', () => {\n const layer = new GeometryLayer()\n .shape('sprite')\n .size(10)\n .style({\n opacity: 0.3,\n mapTexture: 'https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*w2SFSZJp4nIAAAAAAAAAAAAAARQnAQ', // rain\n center: [ 120, 30 ],\n spriteCount: 120,\n spriteRadius: 10,\n spriteTop: 2500000,\n spriteUpdate: 20000,\n spriteScale: 0.6\n });\n scene.addLayer(layer);\n});\n",title:"雨滴粒子",filename:"rain.js",isNew:!1}],icon:"",id:"geometry",title:{en:"Geometry Layer",zh:"几何体图层"},childrenKey:"demos",order:7}],childrenKey:"examples"},{id:"engine",title:{zh:"第三方引擎",en:"other engine"},icon:"map",examples:[{demos:[{id:"amap_ant",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*mjmxT7DaVQgAAAAAAAAAAAAAARQnAQ",source:"import { Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport { ThreeLayer, ThreeRender } from '@antv/l7-three';\nimport * as THREE from 'three';\nimport { GLTFLoader } from 'three/examples/jsm/loaders/GLTFLoader';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 111.4453125, 32.84267363195431 ],\n pitch: 45,\n rotation: 30,\n zoom: 12\n })\n});\n\nscene.on('loaded', () => {\n scene.registerRenderService(ThreeRender);\n\n const threeJSLayer = new ThreeLayer({\n enableMultiPassRenderer: false,\n onAddMeshes: (threeScene, layer) => {\n threeScene.add(new THREE.AmbientLight(0xffffff));\n const sunlight = new THREE.DirectionalLight(0xffffff, 0.25);\n sunlight.position.set(0, 80000000, 100000000);\n sunlight.matrixWorldNeedsUpdate = true;\n threeScene.add(sunlight);\n\n const center = scene.getCenter();\n\n const cubeGeometry = new THREE.BoxBufferGeometry(10000, 10000, 10000);\n const cubeMaterial = new THREE.MeshNormalMaterial({ side: THREE.DoubleSide });\n const cube = new THREE.Mesh(cubeGeometry, cubeMaterial);\n layer.setObjectLngLat(cube, [ center.lng + 0.05, center.lat ], 0);\n threeScene.add(cube);\n\n // 使用 Three.js glTFLoader 加载模型\n const loader = new GLTFLoader();\n loader.load(\n 'https://gw.alipayobjects.com/os/bmw-prod/3ca0a546-92d8-4ba0-a89c-017c218d5bea.gltf',\n gltf => {\n const gltfScene = gltf.scene;\n setDouble(gltfScene);\n layer.adjustMeshToMap(gltfScene);\n // gltfScene.scale.set(1000, 1000, 1000)\n layer.setMeshScale(gltfScene, 1000, 1000, 1000);\n\n layer.setObjectLngLat(\n gltfScene,\n [ center.lng, center.lat ],\n 0\n );\n\n const animations = gltf.animations;\n if (animations && animations.length) {\n const mixer = new THREE.AnimationMixer(gltfScene);\n\n const animation = animations[2];\n\n const action = mixer.clipAction(animation);\n\n action.play();\n layer.addAnimateMixer(mixer);\n }\n // layer.setObjectLngLat(gltfScene, [center.lng + 0.05, center.lat] as ILngLat, 0)\n let t = 0;\n setInterval(() => {\n t += 0.01;\n layer.setObjectLngLat(\n gltfScene,\n [ center.lng, center.lat + Math.sin(t) * 0.1 ],\n 0\n );\n }, 16);\n\n // 向场景中添加模型\n threeScene.add(gltfScene);\n // 重绘图层\n layer.render();\n }\n );\n }\n }).animate(true);\n scene.addLayer(threeJSLayer);\n});\n\nfunction setDouble(object) {\n if (object.children && object.children.length && object.children.length > 0) {\n object.children.map(child => setDouble(child));\n } else if (object.material) {\n object.material.side = THREE.DoubleSide;\n }\n}\n\n",title:"高德地图",filename:"amap_ant.js",isNew:!1},{id:"space_click",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*ilK5R4SidkMAAAAAAAAAAAAAARQnAQ",source:"import { Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport { ThreeLayer, ThreeRender } from '@antv/l7-three';\nimport * as THREE from 'three';\nimport { GLTFLoader } from 'three/examples/jsm/loaders/GLTFLoader';\nimport { FBXLoader } from 'three/examples/jsm/loaders/FBXLoader';\nimport { animate, easeInOut } from 'popmotion';\nfunction changeValue(\n startValue,\n endValue,\n duration = 500,\n callback,\n complete\n) {\n if (typeof startValue === 'number') {\n animate({\n from: {\n v: startValue\n },\n to: {\n v: endValue\n },\n ease: easeInOut,\n duration,\n onUpdate: o => {\n callback(o.v);\n return '';\n },\n onComplete: () => {\n complete && complete();\n return '';\n }\n });\n } else {\n animate({\n from: {\n lng: startValue.lng,\n lat: startValue.lat,\n pitch: startValue.pitch,\n rotation: startValue.rotation,\n zoom: startValue.zoom\n },\n to: {\n lng: (endValue).lng,\n lat: (endValue).lat,\n pitch: (endValue).pitch,\n rotation: (endValue).rotation,\n zoom: (endValue).zoom\n },\n ease: easeInOut,\n duration,\n onUpdate: o => {\n callback(o);\n return '';\n },\n onComplete: () => {\n complete && complete();\n return '';\n }\n });\n }\n return '';\n}\n\nconst raycaster = new THREE.Raycaster();\nconst lng = 120.1;\nconst lat = 30.265;\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ lng, lat ],\n pitch: 70,\n rotation: 220,\n zoom: 16\n })\n});\n\nscene.on('loaded', () => {\n\n const mouse = new THREE.Vector2();\n let zspace,\n aspace,\n ASpaceTextMesh,\n ZSpaceTextMesh;\n\n scene.registerRenderService(ThreeRender);\n\n const center = scene.getCenter();\n\n const threeJSLayer = new ThreeLayer({\n enableMultiPassRenderer: false,\n // @ts-ignore\n onAddMeshes: (threeScene, layer) => {\n threeScene.add(new THREE.AmbientLight(0xffffff));\n const sunlight = new THREE.DirectionalLight(0xffffff, 0.25);\n sunlight.position.set(0, 80000000, 100000000);\n sunlight.matrixWorldNeedsUpdate = true;\n threeScene.add(sunlight);\n\n // map\n // https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*gA0NRbuOF5cAAAAAAAAAAAAAARQnAQ\n\n // height\n // https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*eYFaRYlnnOUAAAAAAAAAAAAAARQnAQ\n\n const image = new Image();\n image.crossOrigin = '';\n image.src =\n 'https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*eYFaRYlnnOUAAAAAAAAAAAAAARQnAQ';\n image.onload = () => {\n const canvas = document.createElement('canvas');\n canvas.width = image.width;\n canvas.height = image.height;\n const ctx = canvas.getContext('2d');\n ctx.drawImage(image, 0, 0, image.width, image.height);\n const heightData = ctx.getImageData(0, 0, image.width, image.height)\n .data;\n\n const s = 53000;\n\n const geometry = new THREE.PlaneGeometry(s, s, 255, 255);\n\n geometry.vertices.map((v, i) => {\n const r = heightData[i * 4];\n const g = heightData[i * 4 + 1];\n const b = heightData[i * 4 + 2];\n let h =\n -10000.0 +\n (r * 255.0 * 256.0 * 256.0 + g * 255.0 * 256.0 + b * 255.0) *\n 0.1;\n h = h / 20 - 127600;\n h = Math.max(0, h);\n\n v.z = h;\n return '';\n });\n const material = new THREE.MeshPhongMaterial({\n transparent: true,\n // opacity: 0.6,\n map: new THREE.TextureLoader().load(\n 'https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*gA0NRbuOF5cAAAAAAAAAAAAAARQnAQ'\n ),\n side: THREE.DoubleSide\n });\n const plane = new THREE.Mesh(geometry, material);\n layer.setObjectLngLat(plane, [ 120.1008, 30.2573 ], 0);\n plane.position.z = 10;\n threeScene.add(plane);\n\n return '';\n };\n\n // 使用 Three.js glTFLoader 加载模型\n const loader = new GLTFLoader();\n loader.load(\n 'https://gw.alipayobjects.com/os/bmw-prod/3ca0a546-92d8-4ba0-a89c-017c218d5bea.gltf',\n gltf => {\n const antModel = gltf.scene;\n setDouble(antModel);\n // antModel.children[0].material.side = THREE.DoubleSide\n layer.adjustMeshToMap(antModel);\n layer.setMeshScale(antModel, 20, 20, 20);\n layer.setObjectLngLat(\n antModel,\n [ center.lng - 0.002, center.lat ],\n 0\n );\n\n const animations = gltf.animations;\n if (animations && animations.length) {\n const mixer = new THREE.AnimationMixer(antModel);\n const animation = animations[1];\n const action = mixer.clipAction(animation);\n action.play();\n layer.addAnimateMixer(mixer);\n }\n antModel.rotation.y = Math.PI;\n // 向场景中添加模型\n threeScene.add(antModel);\n // 重绘图层\n layer.render();\n return '';\n }\n );\n\n const v = `\n varying vec2 vUv;\n varying vec4 worldPosition;\n void main() {\n vUv = uv;\n worldPosition = modelMatrix * vec4(position, 1.0);\n gl_Position = projectionMatrix * modelViewMatrix * vec4(position, 1.0);\n }`;\n const f = `\n varying vec2 vUv;\n varying vec4 worldPosition;\n uniform vec3 color;\n void main() {\n gl_FragColor = vec4(color, fract(worldPosition.z / 50.0));\n }`;\n const shadermaterial = new THREE.ShaderMaterial({\n uniforms: {\n color: {\n value: new THREE.Vector3(0.21372549, 0.34705882, 0.56470588)\n }\n },\n vertexShader: v,\n fragmentShader: f,\n side: THREE.DoubleSide\n });\n\n const fbxLoaded = new FBXLoader();\n // load ZSpace\n fbxLoaded.load(\n 'https://gw.alipayobjects.com/os/bmw-prod/af1652c9-3c4f-4e73-ac4c-1f78fefbaf6a.fbx',\n gltf => {\n zspace = gltf;\n layer.adjustMeshToMap(zspace);\n // @ts-ignore\n zspace.children[0].material = shadermaterial;\n layer.setMeshScale(zspace, 10, 10, 10);\n\n layer.setObjectLngLat(zspace, [ 120.1015, 30.2661 ], 0);\n zspace.rotation.x = Math.PI * 2;\n zspace.rotation.z = -Math.PI * (-2 / 15);\n threeScene.add(zspace);\n\n return '';\n }\n );\n\n fbxLoaded.load(\n 'https://gw.alipayobjects.com/os/bmw-prod/11d6e4c1-bd5b-4dc1-bae5-ac51c14e9056.fbx',\n model => {\n aspace = model;\n layer.adjustMeshToMap(aspace);\n // @ts-ignore\n aspace.children[0].material = shadermaterial;\n\n layer.setMeshScale(aspace, 8, 8, 8);\n layer.setObjectLngLat(aspace, [ 120.099, 30.261 ], 0);\n aspace.rotation.x = Math.PI * 2;\n aspace.rotation.z = -Math.PI * (3 / 15);\n threeScene.add(aspace);\n\n return '';\n }\n );\n console.log(THREE.FontLoader)\n const textLoader = new THREE.FontLoader();\n textLoader.load(\n 'https://gw.alipayobjects.com/os/bmw-prod/0a3f46eb-294e-4d95-87f2-052c26ad4bf1.json',\n font => {\n const fontOptions = {\n size: 360, // 字号大小,一般为大写字母的高度\n height: 50, // 文字的厚度\n font, // 字体,默认是'helvetiker',需对应引用的字体文件\n bevelThickness: 10, // 倒角厚度\n bevelSize: 10, // 倒角宽度\n curveSegments: 30, // 弧线分段数,使得文字的曲线更加光滑\n bevelEnabled: true // 布尔值,是否使用倒角,意为在边缘处斜切\n };\n const aspaceGeo = new THREE.TextGeometry('ASpace', fontOptions);\n aspaceGeo.center();\n const zspaceGeo = new THREE.TextGeometry('ZSpace', fontOptions);\n zspaceGeo.center();\n\n const fontMat = new THREE.MeshPhongMaterial({\n color: 0xcccccc,\n shininess: 60,\n specular: 0xcccccc,\n side: THREE.DoubleSide\n });\n\n const testHeight = 900;\n\n ASpaceTextMesh = new THREE.Mesh(aspaceGeo, fontMat);\n ASpaceTextMesh.rotation.x = Math.PI / 2;\n ASpaceTextMesh.rotation.y = (-Math.PI * 3) / 4;\n layer.setObjectLngLat(\n ASpaceTextMesh,\n [ 120.099, 30.261 ],\n testHeight\n );\n threeScene.add(ASpaceTextMesh);\n\n ZSpaceTextMesh = new THREE.Mesh(zspaceGeo, fontMat);\n ZSpaceTextMesh.rotation.x = Math.PI / 2;\n ZSpaceTextMesh.rotation.y = (-Math.PI * 3) / 4;\n layer.setObjectLngLat(\n ZSpaceTextMesh,\n [ 120.103, 30.2661 ],\n testHeight\n );\n threeScene.add(ZSpaceTextMesh);\n\n getH(0, 200);\n function getH(h1, h2) {\n changeValue(\n h1,\n h2,\n 1000,\n h => {\n ASpaceTextMesh.position.z = testHeight + h;\n ZSpaceTextMesh.position.z = testHeight + h;\n return '';\n },\n () => {\n setTimeout(() => getH(h2, h1), 10);\n return '';\n }\n );\n }\n\n return '';\n }\n );\n }\n })\n .animate(true);\n scene.addLayer(threeJSLayer);\n // @ts-ignore\n let currentCamera = threeJSLayer.threeRenderService?.getRenderCamera();\n const currentView = {\n lng: center.lng,\n lat: center.lat,\n pitch: 70,\n rotation: 220,\n zoom: 16\n };\n\n scene.on('zoom', () => {\n const cen = scene.getCenter();\n currentView.lng = cen.lng;\n currentView.lat = cen.lat;\n currentView.pitch = scene.getPitch();\n currentView.zoom = scene.getZoom();\n return '';\n });\n\n scene.getMapService().on('mapchange', () => {\n // @ts-ignore\n currentCamera = threeJSLayer.getRenderCamera();\n currentView.pitch = scene.getPitch();\n return '';\n });\n\n const ASpaceView = {\n lng: 120.109509,\n lat: 30.251529,\n pitch: 83,\n rotation: 225,\n zoom: 15\n };\n const ZSpaceView = {\n lng: 120.112026,\n lat: 30.256881,\n pitch: 80,\n rotation: 220,\n zoom: 15\n };\n\n scene.on('click', ev => {\n // @ts-ignore\n const size = scene?.map?.getSize();\n mouse.x = (ev.pixel.x / size.width) * 2 - 1;\n mouse.y = -(ev.pixel.y / size.height) * 2 + 1;\n raycaster.setFromCamera(mouse, currentCamera);\n const intersects = raycaster.intersectObjects([ zspace, aspace ], true);\n if (intersects.length > 0) {\n const object = intersects[0].object;\n if (object.name === 'Z空间') {\n selectSpace(currentView, ZSpaceView, ZSpaceTextMesh);\n } else {\n selectSpace(currentView, ASpaceView, ASpaceTextMesh);\n }\n }\n return '';\n });\n\n function selectSpace(\n currentView,\n targetView,\n spaceText\n ) {\n if (spaceText) {\n changeValue(\n spaceText.rotation.y,\n spaceText.rotation.y + Math.PI * 2,\n 500,\n r => {\n spaceText.rotation.y = r;\n return '';\n }\n );\n }\n\n changeValue(currentView, targetView, 500, view => {\n scene.setCenter([ view.lng, view.lat ]);\n scene.setPitch(view.pitch);\n scene.setRotation(view.rotation);\n scene.setZoom(view.zoom);\n\n currentView.lng = view.lng;\n currentView.lat = view.lat;\n currentView.pitch = view.pitch;\n currentView.rotation = view.rotation;\n currentView.zoom = view.zoom;\n\n return '';\n });\n }\n return '';\n});\n\nfunction setDouble(object) {\n if (object.children && object.children.length && object.children.length > 0) {\n object.children.map(child => setDouble(child));\n } else if (object.material) {\n object.material.side = THREE.DoubleSide;\n }\n}\n\n",title:"点击建筑",filename:"space_click.js",isNew:!1}],icon:"",id:"three",title:{en:"Threejs",zh:"Threejs"},childrenKey:"demos",order:0}],childrenKey:"examples"},{id:"amap-plugin",title:{zh:"高德地图插件",en:"Amap Plugin"},icon:"map",examples:[{demos:[{id:"busstop",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*9MHrRZTvaiAAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 116.475, 39.985 ],\n zoom: 12.2,\n plugin: [ 'AMap.ToolBar', 'AMap.LineSearch' ]\n })\n});\n\nscene.addImage(\n 'road',\n 'https://gw.alipayobjects.com/zos/bmw-prod/ce83fc30-701f-415b-9750-4b146f4b3dd6.svg'\n);\nscene.addImage(\n 'start',\n 'https://gw.alipayobjects.com/zos/bmw-prod/1c301f25-9bb8-4e67-8d5c-41117c877caf.svg'\n);\nscene.addImage(\n 'end',\n 'https://gw.alipayobjects.com/zos/bmw-prod/f3db4998-e657-4c46-b5ab-205ddc12031f.svg'\n);\n\nscene.addImage(\n 'busStop',\n 'https://gw.alipayobjects.com/zos/bmw-prod/54345af2-1d01-43e1-9d11-cd9bb953202c.svg'\n);\n\nscene.on('loaded', () => {\n window.AMap.plugin([ 'AMap.ToolBar', 'AMap.LineSearch' ], () => {\n scene.map.addControl(new AMap.ToolBar());\n\n const linesearch = new AMap.LineSearch({\n pageIndex: 1, // 页码,默认值为1\n pageSize: 1, // 单页显示结果条数,默认值为20,最大值为50\n city: '北京', // 限定查询城市,可以是城市名(中文/中文全拼)、城市编码,默认值为『全国』\n extensions: 'all' // 是否返回公交线路详细信息,默认值为『base』\n });\n\n // 执行公交路线关键字查询\n linesearch.search('536', function(status, result) {\n // 打印状态信息status和结果信息result\n\n const { path, via_stops } = result.lineInfo[0];\n const startPoint = [ path[0] ];\n const endpoint = [ path[path.length - 1] ];\n const budStopsData = via_stops.map(stop => ({\n lng: stop.location.lng,\n lat: stop.location.lat,\n name: stop.name\n }));\n const data = [\n {\n id: '1',\n coord: path.map(p => [ p.lng, p.lat ])\n }\n ];\n\n const busLine = new LineLayer({ blend: 'normal' })\n .source(data, {\n parser: {\n type: 'json',\n coordinates: 'coord'\n }\n })\n .size(5)\n .shape('line')\n .color('rgb(99, 166, 242)')\n .texture('road')\n .animate({\n interval: 1, // 间隔\n duration: 1, // 持续时间,延时\n trailLength: 2 // 流线长度\n })\n .style({\n lineTexture: true,\n iconStep: 25\n });\n\n scene.addLayer(busLine);\n\n const startPointLayer = new PointLayer({ zIndex: 1 })\n .source(startPoint, {\n parser: {\n x: 'lng',\n y: 'lat',\n type: 'json'\n }\n })\n .shape('start')\n .size(20)\n .style({\n offsets: [ 0, 25 ]\n });\n scene.addLayer(startPointLayer);\n\n const endPointLayer = new PointLayer({ zIndex: 1 })\n .source(endpoint, {\n parser: {\n x: 'lng',\n y: 'lat',\n type: 'json'\n }\n })\n .shape('end')\n .size(25)\n .style({\n offsets: [ 0, 25 ]\n });\n scene.addLayer(endPointLayer);\n\n const busStops = new PointLayer()\n .source(budStopsData, {\n parser: {\n x: 'lng',\n y: 'lat',\n type: 'json'\n }\n })\n .shape('busStop')\n .size(13)\n .style({\n offsets: [ 20, 0 ]\n });\n scene.addLayer(busStops);\n\n const busStopsName = new PointLayer()\n .source(budStopsData, {\n parser: {\n x: 'lng',\n y: 'lat',\n type: 'json'\n }\n })\n .shape('name', 'text')\n .size(12)\n .color('#000')\n .style({\n textAnchor: 'left',\n textOffset: [ 80, 0 ],\n stroke: '#fff',\n strokeWidth: 1\n });\n scene.addLayer(busStopsName);\n });\n });\n});\n",title:"公交线路插件",filename:"busstop.js",isNew:!1},{id:"xyztile",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*ydN_QpzVraQAAAAAAAAAAAAAARQnAQ",source:"import { Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 105, 30 ],\n zoom: 2\n })\n});\n\nscene.on('loaded', () => {\n const xyzTileLayer = new window.AMap.TileLayer({\n getTileUrl:\n 'https://wprd0{1,2,3,4}.is.autonavi.com/appmaptile?x=[x]&y=[y]&z=[z]&size=1&scl=1&style=8<ype=11',\n zIndex: 100\n });\n scene.getMapService().map.add(xyzTileLayer);\n});\n",title:"xyz瓦片地图",filename:"xyztile.js",isNew:!1},{id:"satellite",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*bYbdT6N6IGwAAAAAAAAAAAAAARQnAQ",source:"import { Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 105, 30 ],\n zoom: 2\n })\n});\n\n\nscene.on('loaded', () => {\n scene.getMapService().map.add(new window.AMap.TileLayer.Satellite());\n});\n",title:"卫星地图",filename:"satellite.js",isNew:!1}],icon:"",id:"bus",title:{en:"amapPlugin",zh:"高德插件"},childrenKey:"demos",order:0}],childrenKey:"examples"},{id:"choropleth",title:{zh:"行政区划",en:"Choropleth"},icon:"map",examples:[{demos:[{id:"zhejiang-province",screenshot:"https://gw.alipayobjects.com/zos/antfincdn/tX2zfzui76/821b3d1d-421c-4f09-a44e-53422db302f6.png",source:"import { GaodeMap, Scene } from '@antv/l7';\nimport { Choropleth } from '@antv/l7plot';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'blank',\n center: [120.19382669582967, 30.258134],\n zoom: 3,\n }),\n});\n\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/alisis/geo-data-v0.1.1/administrative-data/area-list.json',\n )\n .then((response) => response.json())\n .then((list) => {\n const data = list\n .filter(({ level, parent }) => level === 'city' && parent === 330000)\n .map((item) => ({ ...item, value: Math.random() * 5000 }));\n\n const choropleth = new Choropleth({\n source: {\n data,\n joinBy: {\n sourceField: 'adcode',\n geoField: 'adcode',\n },\n },\n viewLevel: {\n level: 'province',\n adcode: 330000,\n },\n autoFit: true,\n color: {\n field: 'value',\n value: ['#B8E1FF', '#7DAAFF', '#3D76DD', '#0047A5', '#001D70'],\n scale: { type: 'quantize' },\n },\n style: {\n opacity: 1,\n stroke: '#ccc',\n lineWidth: 0.6,\n lineOpacity: 1,\n },\n label: {\n visible: true,\n field: 'name',\n style: {\n fill: '#000',\n opacity: 0.8,\n fontSize: 10,\n stroke: '#fff',\n strokeWidth: 1.5,\n textAllowOverlap: false,\n padding: [5, 5],\n },\n },\n state: {\n active: { stroke: 'black', lineWidth: 1 },\n },\n tooltip: {\n items: ['name', 'adcode', 'value'],\n },\n zoom: {\n position: 'bottomright',\n },\n legend: {\n position: 'bottomleft',\n },\n });\n\n choropleth.addToScene(scene);\n });\n});\n",title:{zh:"浙江省地图",en:"Zhejiang Province Map"},filename:"zhejiang-province.ts",isNew:!1},{id:"zhejiang-province-district",screenshot:"https://gw.alipayobjects.com/zos/antfincdn/YQU0%24nl0gh/c9a9a70d-8abc-42f6-8795-856646346326.png",source:"import { GaodeMap, Scene } from '@antv/l7';\nimport { Choropleth } from '@antv/l7plot';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'blank',\n center: [120.19382669582967, 30.258134],\n zoom: 3,\n }),\n});\n\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/alisis/geo-data-v0.1.1/administrative-data/area-list.json',\n )\n .then((response) => response.json())\n .then((list) => {\n const data = list\n .filter(({ level }) => level === 'district')\n .map((item) => ({ ...item, value: Math.random() * 5000 }));\n\n const choropleth = new Choropleth({\n source: {\n data,\n joinBy: {\n sourceField: 'adcode',\n geoField: 'adcode',\n },\n },\n viewLevel: {\n level: 'province',\n adcode: 330000,\n granularity: 'district',\n },\n autoFit: true,\n color: {\n field: 'value',\n value: ['#B8E1FF', '#7DAAFF', '#3D76DD', '#0047A5', '#001D70'],\n scale: { type: 'quantize' },\n },\n style: {\n opacity: 1,\n stroke: '#ccc',\n lineWidth: 0.6,\n lineOpacity: 1,\n },\n label: {\n visible: true,\n field: 'name',\n style: {\n fill: '#000',\n opacity: 0.8,\n fontSize: 10,\n stroke: '#fff',\n strokeWidth: 1.5,\n textAllowOverlap: false,\n padding: [5, 5],\n },\n },\n state: {\n active: { stroke: 'black', lineWidth: 1 },\n },\n tooltip: {\n items: ['name', 'adcode', 'value'],\n },\n zoom: {\n position: 'bottomright',\n },\n legend: {\n position: 'bottomleft',\n },\n });\n\n choropleth.addToScene(scene);\n });\n});\n",title:{zh:"浙江省县级地图",en:"Zhejiang District Map"},filename:"zhejiang-province-district.ts",isNew:!1},{id:"hangzhou-city",screenshot:"https://gw.alipayobjects.com/zos/antfincdn/kagsfItG%26g/49861247-bc88-4d64-b5b1-0913c8ff55f8.png",source:"import { GaodeMap, Scene } from '@antv/l7';\nimport { Choropleth } from '@antv/l7plot';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'blank',\n center: [120.19382669582967, 30.258134],\n zoom: 3,\n }),\n});\n\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/alisis/geo-data-v0.1.1/administrative-data/area-list.json',\n )\n .then((response) => response.json())\n .then((list) => {\n const data = list\n .filter(\n ({ level, parent }) => level === 'district' && parent === 330100,\n )\n .map((item) => ({ ...item, value: Math.random() * 5000 }));\n\n const choropleth = new Choropleth({\n source: {\n data,\n joinBy: {\n sourceField: 'adcode',\n geoField: 'adcode',\n },\n },\n viewLevel: {\n level: 'city',\n adcode: 330100,\n },\n autoFit: true,\n color: {\n field: 'value',\n value: ['#B8E1FF', '#7DAAFF', '#3D76DD', '#0047A5', '#001D70'],\n scale: { type: 'quantize' },\n },\n style: {\n opacity: 1,\n stroke: '#ccc',\n lineWidth: 0.6,\n lineOpacity: 1,\n },\n label: {\n visible: true,\n field: 'name',\n style: {\n fill: '#000',\n opacity: 0.8,\n fontSize: 10,\n stroke: '#fff',\n strokeWidth: 1.5,\n textAllowOverlap: false,\n padding: [5, 5],\n },\n },\n state: {\n active: { stroke: 'black', lineWidth: 1 },\n },\n tooltip: {\n items: ['name', 'adcode', 'value'],\n },\n zoom: {\n position: 'bottomright',\n },\n legend: {\n position: 'bottomleft',\n },\n });\n\n choropleth.addToScene(scene);\n });\n});\n",title:{zh:"杭州市地图",en:"Hangzhou City Map"},filename:"hangzhou-city.ts",isNew:!1},{id:"xihu-district",screenshot:"https://gw.alipayobjects.com/zos/antfincdn/04xm5U4yvt/828e6055-f005-4dba-8936-aaf451487db9.png",source:"import { GaodeMap, Scene } from '@antv/l7';\nimport { Choropleth } from '@antv/l7plot';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'blank',\n center: [120.19382669582967, 30.258134],\n zoom: 3,\n }),\n});\n\nconst choropleth = new Choropleth({\n source: {\n data: [{ adcode: 330106, value: 200 }],\n joinBy: {\n sourceField: 'adcode',\n geoField: 'adcode',\n },\n },\n viewLevel: {\n level: 'district',\n adcode: 330106,\n },\n autoFit: true,\n color: {\n field: 'value',\n value: ['#B8E1FF', '#7DAAFF', '#3D76DD', '#0047A5', '#001D70'],\n scale: { type: 'quantize' },\n },\n style: {\n opacity: 1,\n stroke: '#ccc',\n lineWidth: 0.6,\n lineOpacity: 1,\n },\n label: {\n visible: true,\n field: 'name',\n style: {\n fill: '#000',\n opacity: 0.8,\n fontSize: 10,\n stroke: '#fff',\n strokeWidth: 1.5,\n textAllowOverlap: false,\n padding: [5, 5],\n },\n },\n state: {\n active: { stroke: 'black', lineWidth: 1 },\n },\n tooltip: {\n items: ['name', 'adcode', 'value'],\n },\n zoom: {\n position: 'bottomright',\n },\n legend: {\n position: 'bottomleft',\n },\n});\n\nscene.on('loaded', () => {\n choropleth.addToScene(scene);\n});\n",title:{zh:"西湖区地图",en:"Xihu District Map"},filename:"xihu-district.ts",isNew:!1}],icon:"",id:"administrative",title:{en:"Administrative Division",zh:"行政区域"},childrenKey:"demos",order:0}],childrenKey:"examples"},{id:"tutorial",title:{zh:"教程示例",en:"Tutorial demo"},icon:"map",examples:[{demos:[{id:"gaodemap",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*C4BvT5gcclMAAAAAAAAAAAAAARQnAQ",source:"import { Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nnew Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 107.054293, 35.246265 ],\n zoom: 4.056\n })\n});\n",title:"高德底图",filename:"gaodemap.js",isNew:!1},{id:"amapInstance",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*A4BOR4hBNcUAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nfunction initMap() {\n // 全局加载高德地图API\n const map = new AMap.Map('map', {\n viewMode: '3D',\n mapStyle: 'amap://styles/darkblue',\n center: [ 121.435159, 31.256971 ],\n zoom: 14.89,\n minZoom: 10\n });\n const scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n mapInstance: map\n })\n });\n scene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/893d1d5f-11d9-45f3-8322-ee9140d288ae.json'\n )\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer()\n .source(data, {\n parser: {\n type: 'json',\n x: 'longitude',\n y: 'latitude'\n }\n })\n .shape('name', [\n 'circle',\n 'triangle',\n 'square',\n 'pentagon',\n 'hexagon',\n 'octogon',\n 'hexagram',\n 'rhombus',\n 'vesica'\n ])\n .size('unit_price', [ 10, 25 ])\n .color('name', [ '#5B8FF9', '#5CCEA1', '#5D7092', '#F6BD16', '#E86452' ])\n .style({\n opacity: 0.3,\n strokeWidth: 2\n });\n scene.addLayer(pointLayer);\n });\n });\n}\n initMap();",title:"高德地图实例化",filename:"amapInstance.js",isNew:!1}],icon:"",id:"map",title:{en:"Map",zh:"地图"},childrenKey:"demos",order:0},{demos:[{id:"amap",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*4Jj2RJQIQTAAAAAAAAAAAAAAARQnAQ",source:"import { PointLayer, Scale, Scene, Layers, Zoom } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 121.4316962, 31.26082325 ],\n zoom: 15.056\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/893d1d5f-11d9-45f3-8322-ee9140d288ae.json'\n )\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data, {\n parser: {\n type: 'json',\n x: 'longitude',\n y: 'latitude'\n }\n })\n .shape('circle')\n .size('unit_price', [ 5, 25 ])\n .color('name', [ '#49B5AD', '#5B8FF9' ])\n .style({\n opacity: 0.3,\n strokeWidth: 1\n });\n\n scene.addLayer(pointLayer);\n const overlayers = {\n 气泡图: pointLayer\n };\n const layersControl = new Layers({\n overlayers,\n position: 'rightcenter'\n });\n\n scene.addControl(layersControl);\n });\n\n const zoomControl = new Zoom({\n position: 'rightcenter'\n });\n\n const scaleControl = new Scale({\n position: 'bottomright'\n });\n scene.addControl(zoomControl);\n scene.addControl(scaleControl);\n});\n",title:"高德底图组件",filename:"amap.js",isNew:!1}],icon:"",id:"control",title:{en:"Control",zh:"组件"},childrenKey:"demos",order:2},{demos:[{id:"layer_highlight",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*CnSaSaPwyX8AAAAAAAAAAAAAARQnAQ",source:"import { PolygonLayer, LineLayer, Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 118.7368, 32.0560 ],\n zoom: 9\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/91247d10-585b-4406-b1e2-93b001e3a0e4.json'\n )\n .then(res => res.json())\n .then(data => {\n const filllayer = new PolygonLayer({\n name: 'fill'\n })\n .source(data)\n .shape('fill')\n .color('unit_price', [ '#f0f9e8', '#ccebc5', '#a8ddb5', '#7bccc4', '#43a2ca', '#0868ac' ]);\n const linelayer = new LineLayer({\n zIndex: 1,\n name: 'line'\n })\n .source(data)\n .shape('line')\n .size(0.5)\n .color('#fff')\n .style({\n opacity: 0.5\n });\n const hightLayer = new LineLayer({\n zIndex: 4, // 设置显示层级\n name: 'hightlight'\n })\n .source({\n type: 'FeatureCollection',\n features: [ ]\n })\n .shape('line')\n .size(2)\n .color('red');\n scene.addLayer(filllayer);\n scene.addLayer(linelayer);\n scene.addLayer(hightLayer);\n filllayer.on('click', feature => {\n console.log(feature);\n hightLayer.setData({\n type: 'FeatureCollection',\n features: [ feature.feature ]\n });\n });\n });\n});\n",title:"交互高亮图层",filename:"layer_highlight.js",isNew:!1},{id:"layer_boxselect",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*5kzJQYS_N20AAAAAAAAAAAAADmJ7AQ/original",source:"import { PolygonLayer, LineLayer, Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [120.13618469238281, 30.247352897833554],\n zoom: 9,\n }),\n});\nscene.on('loaded', () => {\n fetch('https://geo.datav.aliyun.com/areas_v3/bound/330100_full.json')\n .then((res) => res.json())\n .then((data) => {\n const fillLayer = new PolygonLayer({\n name: 'fill',\n autoFit: true,\n })\n .source(data)\n .shape('fill')\n .color('adcode', [\n '#f0f9e8',\n '#ccebc5',\n '#a8ddb5',\n '#7bccc4',\n '#43a2ca',\n '#0868ac',\n ]);\n\n const lineLayer = new LineLayer({\n zIndex: 1,\n name: 'line',\n })\n .source(data)\n .shape('line')\n .size(1)\n .color('#fff');\n\n const selectLayer = new LineLayer({\n zIndex: 2,\n name: 'select',\n })\n .source([])\n .shape('line')\n .size(2)\n .color('#f00');\n\n scene.addLayer(fillLayer);\n scene.addLayer(lineLayer);\n scene.addLayer(selectLayer);\n\n scene.enableBoxSelect(false);\n\n const onBoxSelect = (bbox, startEvent, endEvent) => {\n const { x: x1, y: y1 } = startEvent;\n const { x: x2, y: y2 } = endEvent;\n fillLayer.boxSelect(\n [\n Math.min(x1, x2),\n Math.min(y1, y2),\n Math.max(x1, x2),\n Math.max(y1, y2),\n ],\n (features) => {\n selectLayer.setData({\n type: 'FeatureCollection',\n features: features ?? [],\n });\n },\n );\n };\n\n scene.on('selecting', onBoxSelect);\n scene.on('selectend', onBoxSelect);\n });\n});\n",title:"框选图层",filename:"layer_boxselect.js",isNew:!1}],icon:"",id:"layer",title:{en:"Layer",zh:"图层"},childrenKey:"demos",order:2},{demos:[{id:"amap",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*VEy6S6UrAV8AAAAAAAAAAAAAARQnAQ",source:"import { Scene, Marker, Popup } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 121.4316962, 31.26082325 ],\n zoom: 12.056\n })\n});\nscene.on('loaded', () => {\n// 创建默认 marker\n const popup = new Popup({\n offsets: [ 0, 20 ]\n }).setText('hello');\n\n const marker = new Marker()\n .setLnglat([ 121.4316962, 31.26082325 ])\n .setPopup(popup);\n\n scene.addMarker(marker);\n});\n",title:"添加默认Marker",filename:"amap.js",isNew:!1}],icon:"",id:"marker",title:{en:"Marker",zh:"Marker"},childrenKey:"demos",order:2}],childrenKey:"examples"}]}},children:n})}},74927:function(n,e,a){a.d(e,{w:function(){return t}});var t=(0,a(41398).createContext)({})}}]); \ No newline at end of file +"use strict";(self.webpackChunk_antv_l7_site=self.webpackChunk_antv_l7_site||[]).push([[2643],{95084:function(n,e,a){a.r(e),a.d(e,{default:function(){return r}});a(41398);var t=a(66541),o=a(74927),s=a(46228);function r(){var n=(0,t.pC)();return(0,s.jsx)(o.w.Provider,{value:{meta:{exampleTopics:[{id:"gallery",title:{zh:"官方精品库",en:"Featured"},icon:"gallery",examples:[{demos:[{id:"grid",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*h-AMQodd7s4AAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport { ThreeLayer, ThreeRender } from '@antv/l7-three';\nimport * as THREE from 'three';\nimport { GLTFLoader } from 'three/examples/jsm/loaders/GLTFLoader';\n\nfunction getImageData(img) {\n const canvas = document.createElement('canvas');\n const ctx = canvas.getContext('2d');\n const { width, height } = img;\n canvas.width = width;\n canvas.height = height;\n\n ctx.drawImage(img, 0, 0, width, height);\n const imageData = ctx.getImageData(0, 0, width, height);\n\n return imageData;\n}\n\nfunction getLatData(data) {\n const size = Math.floor(Math.sqrt(data.length));\n\n const arr = [];\n const startLng = 110,\n lngStep = 5 / (size - 1);\n const startLat = 30,\n latStep = -5 / (size - 1);\n for (let i = 0; i < size; i++) {\n const arr2 = [];\n for (let j = 0; j < size; j++) {\n const index = i + j * size;\n const x = startLng + lngStep * i;\n const y = startLat + latStep * j;\n\n arr2.push([ x, y, data[index] ]);\n }\n arr.push(arr2);\n }\n return arr;\n}\n\nfunction getLngData(data) {\n const size = Math.floor(Math.sqrt(data.length));\n const arr = [];\n const startLng = 110,\n lngStep = 5 / (size - 1);\n const startLat = 30,\n latStep = -5 / (size - 1);\n\n for (let i = 0; i < size; i++) {\n const arr2 = [];\n for (let j = 0; j < size; j++) {\n const index = i * size + j;\n const x = startLng + lngStep * j;\n const y = startLat + latStep * i;\n\n arr2.push([ x, y, data[index] ]);\n }\n arr.push(arr2);\n }\n return arr;\n}\n\nfunction getR(data) {\n const arr = [];\n for (let i = 0; i < data.length; i += 4) {\n arr.push(data[i]);\n }\n return arr;\n}\n\nfunction setMaterial(object) {\n if (object.children && object.children.length && object.children.length > 0) {\n object.children.map(child => setMaterial(child));\n } else if (object.material) {\n object.material.wireframe = true;\n object.material.opacity = 0.6;\n }\n}\n\n\nconst airPorts = [\n {\n name: '常德桃花源机场',\n lng: 111.641101,\n lat: 28.91165\n },\n {\n name: '芷江机场',\n lng: 109.709699,\n lat: 27.442172\n },\n {\n name: '铜仁凤凰机场',\n lng: 109.313971,\n lat: 27.880629\n },\n {\n name: '永州零陵机场',\n lng: 111.616049,\n lat: 26.335053\n },\n {\n name: '桂林两江国际机场',\n lng: 110.049256,\n lat: 25.210065\n },\n {\n name: '长沙黄花国际机场',\n lng: 113.216412,\n lat: 28.183613\n },\n {\n name: '井冈山机场',\n lng: 114.745845,\n lat: 26.852646\n }\n];\nconst planeTarget = {\n lng2: 111.616049,\n lat2: 26.335053\n};\nconst airLineData = [\n {\n name: '常德桃花源机场',\n lng: 111.641101,\n lat: 28.91165,\n ...planeTarget\n },\n {\n name: '芷江机场',\n lng: 109.709699,\n lat: 27.442172,\n ...planeTarget\n },\n {\n name: '铜仁凤凰机场',\n lng: 109.313971,\n lat: 27.880629,\n ...planeTarget\n },\n {\n name: '桂林两江国际机场',\n lng: 110.049256,\n lat: 25.210065,\n ...planeTarget\n },\n {\n name: '长沙黄花国际机场',\n lng: 113.216412,\n lat: 28.183613,\n ...planeTarget\n },\n {\n name: '井冈山机场',\n lng: 114.745845,\n lat: 26.852646,\n ...planeTarget\n }\n];\n\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 113, 29 ],\n pitch: 70,\n zoom: 7.5,\n rotation: 170,\n style: 'blank'\n })\n});\nscene.setBgColor('#000');\n\nscene.registerRenderService(ThreeRender);\n\nconst threeJSLayer = new ThreeLayer({\n enableMultiPassRenderer: false,\n // @ts-ignore\n onAddMeshes: (threeScene, layer) => {\n threeScene.add(new THREE.AmbientLight(0xffffff));\n const sunlight = new THREE.DirectionalLight(0xffffff, 0.25);\n sunlight.position.set(0, 800000, 1000000);\n sunlight.matrixWorldNeedsUpdate = true;\n threeScene.add(sunlight);\n\n // 使用 Three.js glTFLoader 加载模型\n const loader = new GLTFLoader();\n loader.load(\n 'https://gw.alipayobjects.com/os/bmw-prod/3ca0a546-92d8-4ba0-a89c-017c218d5bea.gltf',\n gltf => {\n const antModel = gltf.scene;\n setMaterial(antModel);\n layer.adjustMeshToMap(antModel);\n layer.setMeshScale(antModel, 2000, 2000, 2000);\n layer.setObjectLngLat(\n antModel,\n [ 113, 29 ],\n 0\n );\n\n const animations = gltf.animations;\n if (animations && animations.length) {\n const mixer = new THREE.AnimationMixer(antModel);\n const animation = animations[1];\n const action = mixer.clipAction(animation);\n action.timeScale = 1;\n action.play();\n layer.addAnimateMixer(mixer);\n }\n antModel.rotation.y = Math.PI;\n threeScene.add(antModel);\n layer.render();\n return '';\n }\n );\n },\n zIndex: 1\n});\n\nscene.addImage(\n 'plane',\n 'https://gw.alipayobjects.com/zos/bmw-prod/96327aa6-7fc5-4b5b-b1d8-65771e05afd8.svg'\n);\nconst airPrtsLayer = new PointLayer()\n .source(airPorts, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n })\n .shape('name', 'text')\n .color('rgb(22,119,255)')\n .size(10);\n\nconst airLineLayer = new LineLayer({ blend: 'normal' })\n .source(airLineData, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat',\n x1: 'lng2',\n y1: 'lat2'\n }\n })\n .shape('arc3d')\n .size(1)\n .color('#f00')\n .style({\n sourceColor: 'rgb(22,119,255)',\n targetColor: 'rgba(242,246,250,0.1)'\n });\n\nconst airPlaneLayer = new LineLayer({ blend: 'normal', zIndex: 1 })\n .source(airLineData, {\n parser: {\n type: 'json',\n x: 'lng2',\n y: 'lat2',\n x1: 'lng',\n y1: 'lat'\n }\n })\n .shape('arc3d')\n .texture('plane')\n .size(30)\n .color('#f00')\n .animate({\n duration: 0.2,\n interval: 0.2,\n trailLength: 0.2\n })\n .style({\n textureBlend: 'replace',\n lineTexture: true, // 开启线的贴图功能\n iconStep: 6 // 设置贴图纹理的间距\n });\n\n\nfetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/ec5351c9-d22b-4918-ad6c-1838064d3a64.json'\n)\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data)\n .size(10000)\n .shape('wall')\n .style({\n opacity: 0.4,\n sourceColor: '#0DCCFF',\n targetColor: 'rbga(255,255,255, 0)',\n heightfixed: true\n });\n scene.addLayer(layer);\n\n const nameLayer = new PointLayer({ zIndex: 3 })\n .source(data)\n .color('rgb(22,119,255)')\n .size(15)\n .shape('name', 'text');\n scene.addLayer(nameLayer);\n });\n\nconst img = new Image();\nimg.crossOrigin = 'none';\nimg.src =\n 'https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*UkvYRYS5jTAAAAAAAAAAAAAAARQnAQ';\nimg.onload = function() {\n const data = getImageData(img);\n const rData = getR(data.data);\n const d1 = getLngData(rData);\n const d2 = getLatData(rData);\n const geoData = {\n type: 'FeatureCollection',\n features: [\n {\n type: 'Feature',\n properties: {},\n geometry: {\n type: 'MultiLineString',\n coordinates: d1\n }\n },\n {\n type: 'Feature',\n properties: {},\n geometry: {\n type: 'MultiLineString',\n coordinates: d2\n }\n }\n ]\n };\n const layer = new LineLayer({})\n .source(geoData)\n .size(1)\n .shape('simple')\n .color('rgb(22, 119, 255)')\n .style({\n vertexHeightScale: 2000,\n opacity: 0.4\n });\n scene.addLayer(layer);\n};\nconst pointData = [\n { lng: 113, lat: 29, size: 10000 },\n { lng: 113.5, lat: 29.5, size: 30000 },\n { lng: 110.23681640625, lat: 29.64509464986076, size: 74020.50373907911 }, \n { lng: 115.01586914062499, lat: 26.88777988202911, size: 22908.885529976185 }, \n { lng: 111.181640625, lat: 28.724313406473463, size: 73359.37302978932 }, \n { lng: 112.686767578125, lat: 29.257648503615542, size: 18500.90838085843 }, \n { lng: 114.664306640625, lat: 28.98892237190413, size: 20293.183968726793 }, \n { lng: 113.90075683593749, lat: 28.17855984939698, size: 18051.412077639496 }, \n { lng: 111.51123046875, lat: 27.45466493898314, size: 37645.94186119526 }, \n { lng: 110.67626953125, lat: 28.004101830368654, size: 4214.588023703825 }, \n { lng: 114.43359375, lat: 29.477861195816843, size: 61722.01580332115 }, \n { lng: 110.445556640625, lat: 26.96124577052697, size: 70806.75519747598 }, \n { lng: 113.75244140624999, lat: 27.88278388425912, size: 70930.24993464859 }\n];\nconst waveLayer = new PointLayer({ zIndex: 2, blend: 'additive' })\n .source(pointData,\n {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n }\n )\n .shape('circle')\n .color('rgb(22, 119, 255)')\n .size('size', v => v)\n .animate(true)\n .style({\n unit: 'meter'\n });\n\nconst barLayer = new PointLayer({ zIndex: 2, depth: false })\n .source(pointData,\n {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n }\n )\n .shape('cylinder')\n .color('rgb(22, 119, 255)')\n .size('size', v => [ 5, 5, v / 350 ])\n .animate(true)\n .style({\n opacityLinear: {\n enable: true,\n dir: 'up'\n },\n lightEnable: false\n });\n\nscene.on('loaded', () => {\n scene.addLayer(waveLayer);\n scene.addLayer(barLayer);\n scene.addLayer(threeJSLayer);\n\n scene.addLayer(airPrtsLayer);\n scene.addLayer(airLineLayer);\n scene.addLayer(airPlaneLayer);\n});\n",title:"网格地图",filename:"grid.js",isNew:!1},{id:"build_sweep",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*TVs2R4bBH6wAAAAAAAAAAAAAARQnAQ",source:"import { Scene, CityBuildingLayer, LineLayer, PolygonLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 120.145, 30.238915 ],\n pitch: 60,\n zoom: 13.2\n })\n});\nfetch(\n 'https://gw.alipayobjects.com/os/rmsportal/ggFwDClGjjvpSMBIrcEx.json'\n).then(async res => {\n const pointLayer = new CityBuildingLayer();\n pointLayer\n .source(await res.json())\n .size('floor', [ 0, 500 ])\n .color('rgba(242,246,250,1.0)')\n .animate({\n enable: true\n })\n .active({\n color: '#0ff',\n mix: 0.5\n })\n .style({\n opacity: 0.7,\n baseColor: 'rgb(16, 16, 16)',\n windowColor: 'rgb(30, 60, 89)',\n brightColor: 'rgb(255, 176, 38)',\n sweep: {\n enable: true,\n sweepRadius: 2,\n sweepColor: '#1990FF',\n sweepSpeed: 0.5,\n sweepCenter: [ 120.145319, 30.238915 ]\n }\n });\n scene.addLayer(pointLayer);\n});\n\nfetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/67130c6c-7f49-4680-915c-54e69730861d.json'\n)\n .then(data => data.json())\n .then(\n ({\n lakeBorderData,\n lakeData,\n landData\n }) => {\n const lakeLayer = new PolygonLayer()\n .source(lakeData)\n .shape('fill')\n .color('#1E90FF')\n .style({\n opacity: 0.4,\n opacityLinear: {\n enable: true,\n dir: 'out' // in - out\n }\n });\n const landLayer = new PolygonLayer()\n .source(landData)\n .shape('fill')\n .color('#3CB371')\n .style({\n opacity: 0.4,\n opacityLinear: {\n enable: true,\n dir: 'in' // in - out\n }\n });\n\n const lakeBorderLayer = new PolygonLayer()\n .source(lakeBorderData)\n .shape('fill')\n .color('#ccc')\n .style({\n opacity: 0.5,\n opacityLinear: {\n enable: true,\n dir: 'in' // in - out\n }\n });\n\n scene.addLayer(lakeLayer);\n scene.addLayer(lakeBorderLayer);\n scene.addLayer(landLayer);\n }\n );\n\nfetch(\n 'https://gw.alipayobjects.com/os/basement_prod/40ef2173-df66-4154-a8c0-785e93a5f18e.json'\n)\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({\n zIndex: 0,\n depth: true\n })\n .source(data)\n .size(1)\n .shape('line')\n .color('#1990FF')\n .animate({\n interval: 1, // 间隔\n duration: 2, // 持续时间,延时\n trailLength: 2 // 流线长度\n });\n scene.addLayer(layer);\n });\n",title:"圆形扫光城市",filename:"build_sweep.js",isNew:!1},{id:"wind",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*K6NHRL_fjTQAAAAAAAAAAAAAARQnAQ",source:"import { Scene, WindLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 105.732421875, 32.24997445586331 ],\n style: 'dark',\n zoom: 2,\n })\n});\n\nscene.on('loaded', () => {\n const layer = new WindLayer({});\n layer\n .source(\n 'https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*wcU8S5xMEDYAAAAAAAAAAAAAARQnAQ',\n {\n parser: {\n type: 'image',\n extent: [ -180, -85, 180, 85 ]\n }\n }\n )\n .animate(true)\n .style({\n uMin: -21.32,\n uMax: 26.8,\n vMin: -21.57,\n vMax: 21.42,\n numParticles: 35535,\n fadeOpacity: 0.996,\n sizeScale: 1.2,\n rampColors: {\n 0.0: '#c6dbef',\n 0.1: '#9ecae1',\n 0.2: '#6baed6',\n 0.3: '#4292c6',\n 0.4: '#2171b5',\n 0.5: '#084594'\n }\n });\n scene.addLayer(layer);\n});\n",title:"风场图层",filename:"wind.js",isNew:!1},{id:"animate_path_texture",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*0DwvSIHihVEAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PolygonLayer, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 120.15, 30.246 ],\n zoom: 13.5,\n style: 'dark',\n pitchEnable: false,\n rotation: -90\n })\n});\n\nscene.on('loaded', () => {\n scene.addImage(\n 'arrow',\n 'https://gw.alipayobjects.com/zos/bmw-prod/ce83fc30-701f-415b-9750-4b146f4b3dd6.svg'\n );\n\n fetch('https://gw.alipayobjects.com/os/bmw-prod/67130c6c-7f49-4680-915c-54e69730861d.json')\n .then(data => data.json())\n .then(({ lakeBorderData, lakeData, landData }) => {\n const lakeLayer = new PolygonLayer()\n .source(lakeData)\n .shape('fill')\n .color('#1E90FF')\n .style({\n opacity: 0.4,\n opacityLinear: {\n enable: true,\n dir: 'out' // in - out\n }\n });\n const landLayer = new PolygonLayer()\n .source(landData)\n .shape('fill')\n .color('#3CB371')\n .style({\n opacity: 0.4,\n opacityLinear: {\n enable: true,\n dir: 'in' // in - out\n }\n });\n\n const lakeBorderLayer = new PolygonLayer()\n .source(lakeBorderData)\n .shape('fill')\n .color('#ccc')\n .style({\n opacity: 0.5,\n opacityLinear: {\n enable: true,\n dir: 'in' // in - out\n }\n });\n\n scene.addLayer(lakeLayer);\n scene.addLayer(lakeBorderLayer);\n scene.addLayer(landLayer);\n\n });\n\n\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/40ef2173-df66-4154-a8c0-785e93a5f18e.json'\n )\n .then(res => res.json())\n .then(data => {\n\n const layer = new LineLayer({})\n .source(data)\n .size(3)\n .shape('line')\n .texture('arrow')\n .color('rgb(22,119,255)')\n .animate({\n interval: 1, // 间隔\n duration: 1, // 持续时间,延时\n trailLength: 2 // 流线长度\n })\n .style({\n opacity: 0.6,\n lineTexture: true, // 开启线的贴图功能\n iconStep: 10, // 设置贴图纹理的间距\n borderWidth: 0.4, // 默认文 0,最大有效值为 0.5\n borderColor: '#fff' // 默认为 #ccc\n });\n scene.addLayer(layer);\n });\n});\n",title:"路径贴图",filename:"animate_path_texture.js",isNew:!1},{id:"turin",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*P1o6R7jm0JsAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 7.65, 45.053 ],\n zoom: 12,\n style: 'dark'\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/98a5d9ec-be97-44bd-bff0-5742d929c003.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data)\n .shape('line')\n .color('highway', v => {\n switch (v) {\n case 'motorway':\n return '#F9D371';\n case 'motorway_link':\n return '#3DB2FF';\n case 'trunk':\n return 'green';\n case 'trunk_link':\n return '#6E85B2';\n case 'primary':\n return '#F47340';\n case 'primary_link':\n return '#F6A9A9';\n case 'secondary':\n return '#EF2F88';\n case 'secondary_link':\n return '#5F7A61';\n case 'tertiary':\n return '#1ee3cf';\n case 'tertiary_link':\n return '#C2F784';\n case 'pedestrian':\n return '#FFF89A';\n case 'residential':\n return 'rgba(22, 119, 255, .5)';\n case 'road':\n return '#93FFD8';\n case 'path':\n return '#BAFFB4';\n case 'unclassified':\n return '#D3DEDC';\n case 'service':\n return '#AEFEFF';\n case 'living_street':\n return '#9B0000';\n case 'track':\n return '#F5F5F5';\n case 'highway':\n return 'red';\n case 'rail':\n return '#08ffc8';\n default:\n return '#FFE3E3';\n }\n })\n .animate({\n interval: 1, // 间隔\n duration: 1, // 持续时间,延时\n trailLength: 2 // 流线长度\n });\n scene.addLayer(layer);\n });\n});\n\n",title:"都灵道路图",filename:"turin.js",isNew:!1}],icon:"",id:"animate",title:{en:"Recommend",zh:"推荐"},childrenKey:"demos",order:0},{demos:[{id:"column_dark",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*FGjMT4CenkkAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 35.210526315789465,\n style: 'dark',\n center: [ 104.288144, 31.239692 ],\n zoom: 4.4\n })\n});\nconsole.log('111');\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/oVTMqfzuuRFKiDwhPSFL.json')\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data.list, {\n parser: {\n type: 'json',\n x: 'j',\n y: 'w'\n }\n })\n .shape('cylinder')\n .size('t', function(level) {\n return [ 2, 2, level * 2 + 20 ];\n })\n .animate(true)\n .active(true)\n .color('t', [\n '#094D4A',\n '#146968',\n '#1D7F7E',\n '#289899',\n '#34B6B7',\n '#4AC5AF',\n '#5FD3A6',\n '#7BE39E',\n '#A1EDB8',\n '#CEF8D6'\n ])\n scene.addLayer(pointLayer);\n });\n});\n",title:"3D柱图深色",filename:"column_dark.js",isNew:!1},{id:"arc-circle",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*hX_VQ5q77xMAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 107.77791556935472, 35.443286920228644 ],\n zoom: 2.9142882493605033\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/UEXQMifxtkQlYfChpPwT.txt')\n .then(res => res.text())\n .then(data => {\n const layer = new LineLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'lng1',\n y: 'lat1',\n x1: 'lng2',\n y1: 'lat2'\n }\n })\n .size(1)\n .shape('arc')\n .color('#8C1EB2')\n .style({\n opacity: 0.8,\n blur: 0.99\n });\n scene.addLayer(layer);\n });\n});\n",title:"弧线地图",filename:"arc-circle.js",isNew:!1},{id:"bus_dark",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*cvU2R7WFfeAAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 103.83735604457024, 1.360253881403068 ],\n pitch: 4.00000000000001,\n zoom: 10.210275860702593,\n rotation: 19.313180925794313\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/ee07641d-5490-4768-9826-25862e8019e1.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data, {\n parser: {\n coordinates: 'path',\n type: 'json'\n }\n })\n .size('level', level => {\n return [ 1.0, level * 1 ];\n })\n .shape('line')\n .color(\n 'level',\n [\n '#312B60',\n '#4A457E',\n '#615C99',\n '#816CAD',\n '#A67FB5',\n '#C997C7',\n '#DEB8D4',\n '#F5D4E6',\n '#FAE4F1',\n '#FFF3FC'\n ].slice(0, 8)\n );\n scene.addLayer(layer);\n });\n});\n",title:"公交线路深色",filename:"bus_dark.js",isNew:!1},{id:"light",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*PtMUR6hsN9EAAAAAAAAAAAAAARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n pitch: 43,\n center: [ 120.13383079335335, 29.651873105004427 ],\n zoom: 7.068989519212174\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/a1a8158d-6fe3-424b-8e50-694ccf61c4d7.csv'\n )\n .then(res => res.text())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'lng',\n y: 'lat'\n },\n transforms: [\n {\n type: 'hexagon',\n size: 2500,\n field: 'v',\n method: 'sum'\n }\n ]\n })\n .size('sum', sum => {\n return sum * 1000000;\n })\n .shape('hexagonColumn')\n .style({\n coverage: 0.8,\n angle: 0,\n })\n .color('sum', [\n '#094D4A',\n '#146968',\n '#1D7F7E',\n '#289899',\n '#34B6B7',\n '#4AC5AF',\n '#5FD3A6',\n '#7BE39E',\n '#A1EDB8',\n '#C3F9CC',\n '#DEFAC0',\n '#ECFFB1'\n ]);\n scene.addLayer(layer);\n });\n});\n",title:"蜂窝图3D",filename:"light.js",isNew:!1},{id:"point",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*OiQxQKq-P9MAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 64.88,\n style: 'dark',\n center: [ 114.060288, 22.53684 ],\n zoom: 15.63\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/513add53-dcb2-4295-8860-9e7aa5236699.json'\n )\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data)\n .size(2)\n .color('h8', [\n '#0A3663',\n '#1558AC',\n '#3771D9',\n '#4D89E5',\n '#64A5D3',\n '#72BED6',\n '#83CED6',\n '#A6E1E0',\n '#B8EFE2',\n '#D7F9F0'\n ]);\n\n scene.addLayer(pointLayer);\n });\n});\n",title:"海量点",filename:"point.js",isNew:!1},{id:"normal",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*qI2gRo_w0XoAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 121.417463, 31.215175 ],\n style: 'dark',\n zoom: 11\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/BElVQFEFvpAKzddxFZxJ.txt')\n .then(res => res.text())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n y: 'lat',\n x: 'lng'\n }\n })\n .size(0.5)\n .color('#080298');\n\n scene.addLayer(pointLayer);\n });\n});\n",title:"亮度图",filename:"normal.js",isNew:!1}],icon:"",id:"basic",title:{en:"Featured",zh:"基础可视化"},childrenKey:"demos",order:1}],childrenKey:"examples"},{id:"point",title:{zh:"点图层",en:"Point Layer"},icon:"point",examples:[{demos:[{id:"point",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*BGJfT5GYaZAAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 140.067171, 36.26186 ],\n zoom: 5.32,\n maxZoom: 10\n })\n});\nscene.on('loaded', () => {\n const plane = initPlane();\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/d3564b06-670f-46ea-8edb-842f7010a7c6.json'\n )\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data)\n .shape('circle')\n .size('mag', [ 1, 25 ])\n .color('mag', mag => {\n return mag > 4.5 ? '#5B8FF9' : '#5CCEA1';\n })\n .active(true)\n .style({\n opacity: 0.3,\n strokeWidth: 1\n });\n scene.addLayer(pointLayer);\n pointLayer.on('click', e => {\n const { lng, lat } = e.lngLat;\n scene.setCenter([ lng, lat ], {\n padding: {\n right: 120\n }\n });\n plane.style.right = '0px';\n plane.innerHTML = `\n

click info\n

featureId: ${e.featureId}

\n

lng: ${lng}

\n

lat: ${lat}

\n `;\n });\n pointLayer.on('unclick', () => {\n plane.style.right = '-120px';\n scene.setCenter([ 140.067171, 36.26186 ], {\n padding: {\n right: 0\n }\n });\n });\n });\n});\n\nfunction initPlane() {\n const el = document.createElement('div');\n el.style.background = '#fff';\n el.style.position = 'absolute';\n el.style.padding = '10px';\n el.style.top = '0';\n el.style.right = '-120px';\n el.style.width = '100px';\n el.style.height = '100%';\n el.style.zIndex = '10';\n el.style.transition = '0.5s';\n // el.innerText = '123'\n const wrap = document.getElementById('map');\n wrap.appendChild(el);\n return el;\n}\n",title:"气泡图(点击拾取)",filename:"point.js",isNew:!1},{id:"color",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*p48-TK_yGZ8AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap} from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 121.435159, 31.256971 ],\n zoom: 14.89,\n minZoom: 10\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/893d1d5f-11d9-45f3-8322-ee9140d288ae.json'\n )\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data, {\n parser: {\n type: 'json',\n x: 'longitude',\n y: 'latitude'\n }\n })\n .shape('name', [\n 'circle',\n 'triangle',\n 'square',\n 'pentagon',\n 'hexagon',\n 'octogon',\n 'hexagram',\n 'rhombus',\n 'vesica'\n ])\n .size('unit_price', [ 10, 25 ])\n .active(true)\n .color('name', [ '#5B8FF9', '#5CCEA1', '#5D7092', '#F6BD16', '#E86452' ])\n .style({\n opacity: 0.3,\n strokeWidth: 2\n });\n\n scene.addLayer(pointLayer);\n });\n});\n",title:"形状映射",filename:"color.js",isNew:!1},{id:"world",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*ecV4T63Yk40AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 96.99215001469588, 29.281597225674773 ],\n zoom: 2.194613775109773,\n maxZoom: 10\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/337ddbb7-aa3f-4679-ab60-d64359241955.json'\n )\n .then(res => res.json())\n .then(data => {\n data.features = data.features.filter(item => {\n return item.properties.capacity > 800;\n });\n const pointLayer = new PointLayer({})\n .source(data)\n .shape('circle')\n .size('capacity', [ 0, 16 ])\n .color('capacity', [\n '#34B6B7',\n '#4AC5AF',\n '#5FD3A6',\n '#7BE39E',\n '#A1EDB8',\n '#CEF8D6'\n ])\n .active(true)\n .style({\n opacity: 0.5,\n strokeWidth: 0\n });\n\n scene.addLayer(pointLayer);\n });\n});\n",title:"气泡图",filename:"world.js",isNew:!1},{id:"scatter",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*Jd4HQpnWQaQAAAAAAAAAAAAAARQnAQ",source:"window.onLoad = function(err){ \n console.log('完成',err)\n}\nvar url = 'https://webapi.amap.com/maps?v=2.0&key=ff533602d57df6f8ab3b0fea226ae52f&callback=onLoad';\nvar jsapi = document.createElement('script');\njsapi.charset = 'utf-8';\njsapi.src = url;\ndocument.head.appendChild(jsapi);\n// const scene = new Scene({\n// id: 'map',\n// map: new GaodeMapV2({\n// style: 'dark',\n// version:'2.1.0',\n// center: [ 112, 23.69 ],\n// zoom: 2.5\n// })\n// });\n// scene.on('loaded', () => {\n// fetch(\n// 'https://gw.alipayobjects.com/os/basement_prod/9078fd36-ce8d-4ee2-91bc-605db8315fdf.csv'\n// )\n// .then(res => res.text())\n// .then(data => {\n// const pointLayer = new PointLayer({})\n// .source(data, {\n// parser: {\n// type: 'csv',\n// x: 'Longitude',\n// y: 'Latitude'\n// }\n// })\n// .shape('circle')\n// .active(true)\n// .animate(true)\n// .size(56)\n// .color('#4cfd47');\n\n// scene.addLayer(pointLayer);\n// });\n// });\n",title:"气泡图动画",filename:"scatter.js",isNew:!1}],icon:"",id:"bubble",title:{en:"Bubble Map",zh:"气泡地图"},childrenKey:"demos",order:0},{demos:[{id:"cluster",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*_KdAR67mrNUAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 120.19382669582967, 30.258134 ],\n style: 'dark',\n zoom: 3\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/basement_prod/d3564b06-670f-46ea-8edb-842f7010a7c6.json')\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data, {\n cluster: true\n })\n .shape('circle')\n .scale('point_count', {\n type: 'quantile'\n })\n .size('point_count', [ 5, 10, 15, 20, 25 ])\n .active(true)\n .color('yellow')\n .style({\n opacity: 0.5,\n strokeWidth: 1\n });\n\n scene.addLayer(pointLayer);\n });\n});\n",title:"聚合图",filename:"cluster.js",isNew:!1},{id:"cluster2",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*ATjEQKEScq8AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer, Source } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 120.19382669582967, 30.258134 ],\n style: 'dark',\n zoom: 3\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/bmw-prod/87e40417-a5da-4fdb-8313-c796ea15f982.csv')\n .then(res => res.text())\n .then(data => {\n const dataSource = new Source(data, {\n parser: {\n type: 'csv',\n x: 'lng',\n y: 'lat'\n\n },\n cluster: true\n });\n const pointLayer = new PointLayer({\n autoFit: true\n })\n .source(dataSource)\n .shape('circle')\n .scale('point_count', {\n type: 'quantile'\n })\n .size('point_count', [ 5, 10, 15, 20, 25 ])\n .active(true)\n .color('rgb(73,167,86)')\n .style({\n strokeWidth: 1,\n stroke: '#fff'\n });\n\n // 聚合图标注\n const pointLayerText = new PointLayer({\n autoFit: false\n })\n .source(dataSource)\n .shape('point_count', 'text')\n .size(15)\n .active(true)\n .color('#fff')\n .style({\n strokeWidth: 0,\n stroke: '#fff'\n });\n\n scene.addLayer(pointLayer);\n scene.addLayer(pointLayerText);\n });\n});\n",title:"充电桩分布聚合图",filename:"cluster2.js",isNew:!1}],icon:"",id:"cluster",title:{en:"Cluster Map",zh:"聚合图"},childrenKey:"demos",order:1},{demos:[{id:"normal2",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*OiQxQKq-P9MAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 64.88,\n style: 'dark',\n center: [ 114.060288, 22.53684 ],\n zoom: 15.63\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/513add53-dcb2-4295-8860-9e7aa5236699.json'\n )\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data)\n .size(2)\n .color('h8', [\n '#0A3663',\n '#1558AC',\n '#3771D9',\n '#4D89E5',\n '#64A5D3',\n '#72BED6',\n '#83CED6',\n '#A6E1E0',\n '#B8EFE2',\n '#D7F9F0'\n ]);\n\n scene.addLayer(pointLayer);\n });\n});\n",title:"城市亮度图",filename:"normal2.js",isNew:!1},{id:"normal",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*qI2gRo_w0XoAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 121.417463, 31.215175 ],\n zoom: 11\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/BElVQFEFvpAKzddxFZxJ.txt')\n .then(res => res.text())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n y: 'lat',\n x: 'lng'\n }\n })\n .size(0.5)\n .color('#080298');\n\n scene.addLayer(pointLayer);\n });\n});\n",title:"海量点",filename:"normal.js",isNew:!1}],icon:"",id:"dot",title:{en:"Dot Intensity",zh:"亮度图"},childrenKey:"demos",order:1},{demos:[{id:"scatter",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*hH8lT6AWcqEAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ -121.24357, 37.58264 ],\n zoom: 6.45\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/6c4bb5f2-850b-419d-afc4-e46032fc9f94.csv'\n )\n .then(res => res.text())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'Longitude',\n y: 'Latitude'\n }\n })\n .shape('circle')\n .size(4)\n .active(true)\n .color('Magnitude', [\n '#0A3663',\n '#1558AC',\n '#3771D9',\n '#4D89E5',\n '#64A5D3',\n '#72BED6',\n '#83CED6',\n '#A6E1E0',\n '#B8EFE2',\n '#D7F9F0'\n ])\n .style({\n opacity: 0.5,\n strokeWidth: 0\n });\n\n scene.addLayer(pointLayer);\n });\n});\n",title:"散点图",filename:"scatter.js",isNew:!1},{id:"scatterstylemap",screenshot:"https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*F_QoSr-W0BwAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 112, 30.267069 ],\n style: 'dark',\n zoom: 6\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/bmw-prod/450b2d95-006c-4bad-8269-15729269e142.json')\n .then(res => res.json())\n .then(data => {\n const layer = new PointLayer()\n .source(data, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n })\n .shape('circle')\n .color('color')\n .size('value', v => 5 + 15 * v)\n .style({\n stroke: 'strokeColor',\n strokeWidth: 'strokeWidth',\n strokeOpacity: [\n 'strokeOpacity',\n d => {\n return d * 2;\n }\n ],\n\n opacity: 'opacity'\n })\n .active(true);\n scene.addLayer(layer);\n });\n\n});\n",title:"样式映射散点",filename:"scatterstylemap.js",isNew:!1},{id:"blur",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*v7v6SacA_5AAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 112, 30.267069 ],\n style: 'dark',\n zoom: 3.8\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/bmw-prod/450b2d95-006c-4bad-8269-15729269e142.json')\n .then(res => res.json())\n .then(data => {\n const layer = new PointLayer({ blend: 'additive' })\n .source(data, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n })\n .shape('circle')\n .color('#f00')\n .size('value', v => 15 + 15 * v)\n .style({\n blur: 2.5,\n opacity: 'opacity'\n })\n .active(true);\n scene.addLayer(layer);\n });\n\n});\n",title:"模糊点",filename:"blur.js",isNew:!1},{id:"animatepoint",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*N7KDR4kfIDQAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 112, 23.69 ],\n zoom: 2.5\n })\n});\n\nfetch(\n 'https://gw.alipayobjects.com/os/basement_prod/9078fd36-ce8d-4ee2-91bc-605db8315fdf.csv'\n)\n .then(res => res.text())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'Longitude',\n y: 'Latitude'\n }\n })\n .shape('circle')\n .active(true)\n .animate(true)\n .size(40)\n .color('#ffa842')\n .style({\n offsets: [ 40, 40 ]\n });\n const pointLayer2 = new PointLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'Longitude',\n y: 'Latitude'\n }\n })\n .shape('circle')\n .active(true)\n .animate(true)\n .size(50)\n .color('#f00');\n\n scene.addLayer(pointLayer);\n scene.addLayer(pointLayer2);\n });\n",title:"水波散点",filename:"animatepoint.js",isNew:!1},{id:"radarpoint",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*nfAwRaTOYj0AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 120, 30 ],\n zoom: 13\n })\n});\n\nconst layer = new PointLayer()\n .source(\n [\n {\n lng: 120,\n lat: 30\n }\n ],\n {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n }\n )\n .shape('radar')\n .size(100)\n .color('#d00')\n .style({\n speed: 5\n })\n .animate(true);\n\nscene.on('loaded', () => {\n scene.addLayer(layer);\n});\n",title:"雷达图",filename:"radarpoint.js",isNew:!1}],icon:"",id:"scatter",title:{en:"Scatter Map",zh:"散点地图"},childrenKey:"demos",order:1},{demos:[{id:"point_text",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*QAfOQr1alNoAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 110, 36 ],\n style: 'light',\n zoom: 3\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/oVTMqfzuuRFKiDwhPSFL.json')\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data.list, {\n parser: {\n type: 'json',\n x: 'j',\n y: 'w'\n }\n })\n .shape('m', 'text')\n .size(12)\n .color('w', [ '#0e0030', '#0e0030', '#0e0030' ])\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n textOffset: [ 0, 0 ], // 文本相对锚点的偏移量 [水平, 垂直]\n spacing: 2, // 字符间距\n padding: [ 1, 1 ], // 文本包围盒 padding [水平,垂直],影响碰撞检测结果,避免相邻文本靠的太近\n stroke: '#ffffff', // 描边颜色\n strokeWidth: 0.3, // 描边宽度\n strokeOpacity: 1.0\n });\n\n scene.addLayer(pointLayer);\n });\n\n});\n",title:"点数据标注",filename:"point_text.js",isNew:!1},{id:"polygon_text",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*1iRfT56__38AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PolygonLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ -96, 37.8 ],\n zoom: 3\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/d36ad90e-3902-4742-b8a2-d93f7e5dafa2.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new PolygonLayer({})\n .source(data)\n .color('blue')\n .shape('name', 'text')\n .size(18)\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n textOffset: [ 0, 0 ], // 文本相对锚点的偏移量 [水平, 垂直]\n spacing: 2, // 字符间距\n padding: [ 1, 1 ], // 文本包围盒 padding [水平,垂直],影响碰撞检测结果,避免相邻文本靠的太近\n stroke: '#ffffff', // 描边颜色\n strokeWidth: 0.3, // 描边宽度\n strokeOpacity: 1.0\n });\n scene.addLayer(layer);\n });\n});\n",title:"面数据标注",filename:"polygon_text.js",isNew:!1},{id:"iconfont",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*1Ox-T7mht18AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 110, 30 ],\n style: 'amap://styles/453e2f8e11603fc8f7548fe18959e9e9',\n zoom: 5\n })\n});\nconst fontFamily = 'iconfont';\nconst fontPath = '//at.alicdn.com/t/font_2534097_fcae9o2mxbv.woff2?t=1622200439140';\nscene.addFontFace(fontFamily, fontPath);\nscene.addIconFont('icon1', '');\n\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/70408903-80db-4278-a318-461604acb2df.json'\n )\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data.list, {\n parser: {\n type: 'json',\n x: 'j',\n y: 'w'\n }\n })\n .shape('icon', 'text')\n .size(20)\n .color('w', [ '#a6cee3', '#1f78b4', '#b2df8a', '#33a02c', '#fb9a99' ])\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n padding: [ 0, 0 ], // 文本包围盒 padding [水平,垂直],影响碰撞检测结果,避免相邻文本靠的太近\n stroke: '#ffffff', // 描边颜色\n fontFamily,\n iconfont: true,\n textAllowOverlap: true\n });\n scene.addLayer(pointLayer);\n });\n});\n",title:"图标标注",filename:"iconfont.js",isNew:!1},{id:"iconfonts",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*NCz5R7YA3VIAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 120.5, 30.2 ],\n style: 'dark',\n zoom: 8.5,\n zooms: [ 8, 10 ]\n })\n});\nconst fontFamily = 'iconfont';\nconst fontPath = '//at.alicdn.com/t/font_2534097_ao9soua2obv.woff2?t=1622021146076';\nscene.addFontFace(fontFamily, fontPath);\nscene.addIconFonts([\n [ 'smallRain', '' ],\n [ 'middleRain', '' ],\n [ 'hugeRain', '' ],\n [ 'sun', '' ],\n [ 'cloud', '' ]\n]);\n\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/bmw-prod/9eb3f1b5-0c3b-49b2-8221-191d4ba8aa5e.json')\n .then(res => res.json())\n .then(originData => {\n const layer = new PointLayer()\n .source(originData, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n })\n .shape('circle')\n .color('backgoundColor')\n .size(42);\n scene.addLayer(layer);\n\n const pointIconFontLayer = new PointLayer({})\n .source(originData, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n }\n )\n .shape('iconType', 'text')\n .size(30)\n .color('iconColor')\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n textOffset: [ -10, 10 ], // 文本相对锚点的偏移量 [水平, 垂直]\n fontFamily,\n iconfont: true,\n textAllowOverlap: true\n });\n scene.addLayer(pointIconFontLayer);\n\n const textLayer = new PointLayer({})\n .source(originData,\n {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n }\n )\n .shape('temperature', 'text')\n .size(10)\n .color('#ffffff')\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n textOffset: [ 5, -55 ], // 文本相对锚点的偏移量 [水平, 垂直]\n spacing: 2, // 字符间距\n padding: [ 1, 1 ], // 文本包围盒 padding [水平,垂直],影响碰撞检测结果,避免相邻文本靠的太近\n stroke: '#ffffff', // 描边颜色\n strokeWidth: 0.3, // 描边宽度\n strokeOpacity: 1.0,\n fontFamily: 'Times New Roman',\n textAllowOverlap: true\n });\n scene.addLayer(textLayer);\n\n const textLayer2 = new PointLayer({})\n .source(originData,\n {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n }\n )\n .shape('weather', 'text')\n .size(14)\n .color('#ffffff')\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n textOffset: [ 5, -15 ], // 文本相对锚点的偏移量 [水平, 垂直]\n spacing: 2, // 字符间距\n padding: [ 1, 1 ], // 文本包围盒 padding [水平,垂直],影响碰撞检测结果,避免相邻文本靠的太近\n stroke: '#ffffff', // 描边颜色\n strokeWidth: 0.3, // 描边宽度\n strokeOpacity: 1.0,\n fontFamily: 'Times New Roman',\n textAllowOverlap: true\n });\n scene.addLayer(textLayer2);\n });\n\n\n});\n",title:"天气图标标注",filename:"iconfonts.js",isNew:!1},{id:"stylemap",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*cfShR4lVaUYAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 120.5, 30.2 ],\n style: 'dark',\n zoom: 7.5,\n zooms: [ 8, 10 ]\n })\n});\n\nconst fontFamily = 'iconfont';\nconst fontPath =\n '//at.alicdn.com/t/font_2534097_ao9soua2obv.woff2?t=1622021146076';\nscene.addIconFonts([\n [ 'smallRain', '' ],\n [ 'middleRain', '' ],\n [ 'hugeRain', '' ],\n [ 'sun', '' ],\n [ 'cloud', '' ]\n]);\nscene.addFontFace(fontFamily, fontPath);\nscene.on('loaded', () => {\n\n fetch('https://gw.alipayobjects.com/os/bmw-prod/f7d083e2-ad55-44fd-b324-15e1b549948a.json')\n .then(res => res.json())\n .then(data => {\n const pointIconFontLayer = new PointLayer({})\n .source(data, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n })\n .shape('iconType', 'text')\n .size(30)\n .color('iconColor')\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n textOffset: 'textOffset', // 文本相对锚点的偏移量 [水平, 垂直]\n fontFamily,\n iconfont: true,\n textAllowOverlap: true\n });\n scene.addLayer(pointIconFontLayer);\n\n const textLayer = new PointLayer({})\n .source(data, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n })\n .shape('weather', 'text')\n .size(16)\n .color('#fff')\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n textOffset: [ 0, 0 ], // 文本相对锚点的偏移量 [水平, 垂直]\n spacing: 2, // 字符间距\n padding: [ 1, 1 ], // 文本包围盒 padding [水平,垂直],影响碰撞检测结果,避免相邻文本靠的太近\n fontFamily: 'Times New Roman',\n textAllowOverlap: true\n });\n scene.addLayer(textLayer);\n });\n\n});\n",title:"文本动态偏移",filename:"stylemap.js",isNew:!1},{id:"temperture",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*nvwuQIi8_9oAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer, PolygonLayer, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n pitch: 40,\n center: [ 118.8, 32.056 ],\n zoom: 12.5\n })\n});\nconst fontFamily = 'iconfont';\nconst fontPath =\n '//at.alicdn.com/t/font_2534097_x6rsov3i1g.woff2?t=1622107341225';\nscene.addIconFont('icon', '');\nscene.addFontFace(fontFamily, fontPath);\n\nconst colors = [\n '#87CEFA',\n '#00BFFF',\n\n '#7FFFAA',\n '#00FF7F',\n '#32CD32',\n\n '#F0E68C',\n '#FFD700',\n\n '#FF7F50',\n '#FF6347',\n '#FF0000'\n];\n\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/bmw-prod/94763191-2816-4c1a-8d0d-8bcf4181056a.json')\n .then(res => res.json())\n .then(data => {\n\n const filllayer = new PolygonLayer({\n name: 'fill',\n zIndex: 3\n })\n .source(data)\n .shape('fill')\n .color('count', [ '#f2f0f7', '#dadaeb', '#bcbddc', '#9e9ac8', '#756bb1', '#54278f' ])\n .style({\n opacity: 0.6,\n opacityLinear: {\n enable: true,\n dir: 'out' // in - out\n }\n });\n scene.addLayer(filllayer);\n\n const linelayer = new LineLayer({\n zIndex: 5,\n name: 'line2'\n })\n .source(data)\n .shape('line')\n .size(1)\n .color('#fff')\n .style({\n opacity: 0.3\n });\n scene.addLayer(linelayer);\n\n const pointLayer = new PointLayer({\n zIndex: 10\n })\n .source(data)\n .shape('icon', 'text')\n .size(25)\n .color('count', t => {\n const c = Number(t.replace('℃', ''));\n return colors[Math.floor(((c - 18) / 16) * 10)];\n })\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n textOffset: [ -25, 15 ],\n padding: [ 2, 2 ],\n fontFamily,\n iconfont: true,\n textAllowOverlap: true\n });\n scene.addLayer(pointLayer);\n\n const tempertureLayer = new PointLayer({\n zIndex: 10\n })\n .source(data)\n .shape('count', 'text')\n .size(12)\n .color('count', t => {\n const c = Number(t.replace('℃', ''));\n return colors[Math.floor(((c - 18) / 16) * 10)];\n })\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n textOffset: [ 35, 30 ],\n padding: [ 1, 1 ]\n });\n scene.addLayer(tempertureLayer);\n\n });\n});\n",title:"气温图标标注",filename:"temperture.js",isNew:!1},{id:"simplecoordinate",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*OXlZRKw7AoUAAAAAAAAAAAAAARQnAQ",source:"import { Scene, ImageLayer, PointLayer } from '@antv/l7';\nimport { Map } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new Map({\n center: [ 500, 500 ],\n zoom: 3,\n version: 'SIMPLE',\n mapSize: 1000,\n maxZoom: 5,\n minZoom: 2,\n pitchEnabled: false,\n rotateEnabled: false\n })\n});\nscene.setBgColor('rgb(94, 182, 140)');\n\nconst imagelayer = new ImageLayer({}).source(\n 'https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*I0X5R4jAUQ4AAAAAAAAAAAAAARQnAQ',\n {\n parser: {\n type: 'image',\n extent: [ 360, 400, 640, 600 ]\n }\n }\n);\n\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/bmw-prod/7dc0d454-fabc-4461-a5d5-d404dadb49a9.json')\n .then(res => res.json())\n .then(data => {\n const textlayer = new PointLayer({ zIndex: 2 })\n .source(\n data,\n {\n parser: {\n type: 'json',\n x: 'x',\n y: 'y'\n }\n }\n )\n .shape('t', 'text')\n .size(12)\n .active({\n color: '#00f',\n mix: 0.9\n })\n .color('rgb(86, 156, 214)')\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n spacing: 2, // 字符间距\n fontWeight: '800',\n padding: [ 1, 1 ], // 文本包围盒 padding [水平,垂直],影响碰撞检测结果,避免相邻文本靠的太近\n stroke: '#ffffff', // 描边颜色\n strokeWidth: 2, // 描边宽度\n textAllowOverlap: true\n });\n scene.addLayer(textlayer);\n });\n\n scene.addLayer(imagelayer);\n\n});\n",title:"平面区域标注",filename:"simplecoordinate.js",isNew:!1}],icon:"",id:"text",title:{en:"label",zh:"文本标注"},childrenKey:"demos",order:1},{demos:[{id:"image",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*uzwBSLxwZGMAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 121.434765, 31.256735 ],\n zoom: 14.83\n })\n});\nscene.addImage(\n '00',\n 'https://gw.alipayobjects.com/zos/basement_prod/604b5e7f-309e-40db-b95b-4fac746c5153.svg'\n);\nscene.addImage(\n '01',\n 'https://gw.alipayobjects.com/zos/basement_prod/30580bc9-506f-4438-8c1a-744e082054ec.svg'\n);\nscene.addImage(\n '02',\n 'https://gw.alipayobjects.com/zos/basement_prod/7aa1f460-9f9f-499f-afdf-13424aa26bbf.svg'\n);\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/893d1d5f-11d9-45f3-8322-ee9140d288ae.json'\n )\n .then(res => res.json())\n .then(data => {\n const imageLayer = new PointLayer()\n .source(data, {\n parser: {\n type: 'json',\n x: 'longitude',\n y: 'latitude'\n }\n })\n .shape('name', [ '00', '01', '02' ])\n .size(25);\n scene.addLayer(imageLayer);\n });\n});\n",title:"符号图",filename:"image.js",isNew:!1},{id:"locate",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*rkFFQYBOJt4AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 116.276227, 35.256776 ],\n zoom: 6\n })\n});\nscene.addImage(\n 'marker',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*BJ6cTpDcuLcAAAAAAAAAAABkARQnAQ'\n);\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/e2fc6e0a-af2a-4320-96e5-d9f5a5fda442.json'\n )\n .then(res => res.json())\n .then(data => {\n \n const imageLayer = new PointLayer()\n .source(data)\n .shape('marker')\n .size(12);\n scene.addLayer(imageLayer);\n });\n});\n",title:"精确符号",filename:"locate.js",isNew:!1},{id:"weather",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*CC5YRp2OY3gAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 120.5969, 29.7918 ],\n pitch: 35,\n zoom: 7,\n rotation: 4.183582\n })\n});\nscene.on('loaded', () => {\n scene.addImage(\n '00',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*kzTMQqS2QdUAAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '01',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*jH1XRb7F7hMAAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '02',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*YaKSTr3L5i8AAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '04',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*dmniQrDpCYwAAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '11',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*YaKSTr3L5i8AAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '15',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*YNlXQYCIzroAAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '07',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*DccRTI6ZRLoAAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '16',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*iQKoS6I-rO8AAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '06',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*f-wyS7ad5p0AAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '08',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*lHhzQrOW4AQAAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '17',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*9Q0QS4GdaYcAAAAAAAAAAABkARQnAQ'\n );\n scene.addImage(\n '05',\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*LyuVRowl6nAAAAAAAAAAAABkARQnAQ'\n );\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/c6042c6b-45fd-4e2e-adf8-fdbf060441e8.json'\n )\n .then(res => res.json())\n .then(data => {\n const imageLayer = new PointLayer()\n .source(data)\n .shape('w', function(w) {\n return w;\n })\n .size(15);\n scene.addLayer(imageLayer);\n });\n});\n",title:"天气",filename:"weather.js",isNew:!1},{id:"monsoon",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*Zq5ZTKNeU6sAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 105, 35 ],\n zoom: 2.5\n })\n});\n\n\nscene.addImage(\n 'arrRed',\n 'https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*KWGqT6Oz50EAAAAAAAAAAAAAARQnAQ'\n);\nscene.addImage(\n 'arrBlue',\n 'https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*ZKhURq53OgIAAAAAAAAAAAAAARQnAQ'\n);\n\nscene.on('loaded', () => {\n\n fetch('https://gw.alipayobjects.com/os/bmw-prod/4c02515b-cb7a-47be-93cf-5596731ef982.json')\n .then(res => res.json())\n .then(monsoon => {\n const { data, borderData } = monsoon;\n const imageLayer = new PointLayer()\n .source(data)\n .shape('wind', wind => {\n if (wind === 'up') {\n return 'arrBlue';\n }\n return 'arrRed';\n\n })\n .rotate('r', r => Math.PI * r)\n .size(15)\n .style({\n rotation: 0,\n layerType: 'fillImage'\n });\n scene.addLayer(imageLayer);\n\n\n const border = new LineLayer()\n .source(borderData)\n .size(1.5)\n .color('#575757')\n .style({\n lineType: 'dash',\n dashArray: [ 5, 5 ]\n });\n scene.addLayer(border);\n\n const text = new PointLayer({ zIndex: 2 })\n .source([\n { lng: 90, lat: 35, n: '非季风区' },\n { lng: 125, lat: 30, n: '季风区' }\n ], {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n })\n .shape('n', 'text')\n .size(25)\n .color('#575757')\n .style({\n spacing: 20\n });\n\n scene.addLayer(text);\n });\n\n\n});\n",title:"季风分布",filename:"monsoon.js",isNew:!1}],icon:"",id:"image",title:{en:"Symbol Map",zh:"符号地图"},childrenKey:"demos",order:2},{demos:[{id:"column_light",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*UGw1T6ms2D0AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer, Popup } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 60,\n style: 'dark',\n center: [ 110, 31.847 ],\n rotation: 0,\n zoom: 4\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/oVTMqfzuuRFKiDwhPSFL.json')\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({ depth: false })\n .source(data.list, {\n parser: {\n type: 'json',\n x: 'j',\n y: 'w'\n }\n })\n .shape('cylinder')\n .size('t', function(level) {\n return [ 1, 1, level * 2 + 20 ];\n })\n .active(true)\n .color('#006CFF')\n .style({\n opacity: 0.6,\n opacityLinear: {\n enable: true, // true - false\n dir: 'up' // up - down\n },\n lightEnable: false\n });\n pointLayer.on('mousemove', e => {\n const popup = new Popup({\n offsets: [ 0, 0 ],\n closeButton: false\n })\n .setLnglat(e.lngLat)\n .setHTML(`${e.feature.s}: ${e.feature.t}℃`);\n scene.addPopup(popup);\n });\n scene.addLayer(pointLayer);\n });\n});\n",title:"3D柱图 光标",filename:"column_light.js",isNew:!1},{id:"column_linear",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*GJhASbfQTK8AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer, Popup } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 70,\n style: 'dark',\n center: [ 105, 31.847 ],\n rotation: 0,\n zoom: 4.2\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/oVTMqfzuuRFKiDwhPSFL.json')\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({ depth: false })\n .source(data.list, {\n parser: {\n type: 'json',\n x: 'j',\n y: 'w'\n }\n })\n .shape('cylinder')\n .size('t', function(level) {\n return [ 1, 1, level * 2 + 20 ];\n })\n .animate(true)\n .active(true)\n .color('#006CFF')\n .style({\n opacity: 0.8,\n sourceColor: 'red',\n targetColor: 'yellow',\n lightEnable: false\n });\n pointLayer.on('mousemove', e => {\n const popup = new Popup({\n offsets: [ 0, 0 ],\n closeButton: false\n })\n .setLnglat(e.lngLat)\n .setHTML(`${e.feature.s}: ${e.feature.t}℃`);\n scene.addPopup(popup);\n });\n scene.addLayer(pointLayer);\n });\n});\n",title:"3D 渐变柱图",filename:"column_linear.js",isNew:!1},{id:"column_dark",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*FG4fT7h5AYMAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 40,\n style: 'dark',\n center: [ 104.288144, 31.239692 ],\n zoom: 4.4\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/oVTMqfzuuRFKiDwhPSFL.json')\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data.list, {\n parser: {\n type: 'json',\n x: 'j',\n y: 'w'\n }\n })\n .shape('cylinder')\n .size('t', function(level) {\n return [ 2, 2, level * 2 + 20 ];\n })\n .animate(true)\n .active(true)\n .color('t', [\n '#094D4A',\n '#146968',\n '#1D7F7E',\n '#289899',\n '#34B6B7',\n '#4AC5AF',\n '#5FD3A6',\n '#7BE39E',\n '#A1EDB8',\n '#CEF8D6'\n ]);\n scene.addLayer(pointLayer);\n });\n});\n",title:"3D柱图 深色底图",filename:"column_dark.js",isNew:!1},{id:"clumn_shape",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*9EoxQpBxNyIAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 66.02383,\n style: 'dark',\n center: [ 121.400257, 31.25287 ],\n zoom: 14.55,\n rotation: 134.95\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/893d1d5f-11d9-45f3-8322-ee9140d288ae.json'\n )\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data, {\n parser: {\n type: 'json',\n x: 'longitude',\n y: 'latitude'\n }\n })\n .animate(true)\n .active(true)\n .shape('name', [\n 'cylinder',\n 'triangleColumn',\n 'hexagonColumn',\n 'squareColumn'\n ])\n .size('unit_price', h => {\n return [ 6, 6, h / 500 ];\n })\n .color('name', [ '#739DFF', '#61FCBF', '#FFDE74', '#FF896F' ]);\n\n scene.addLayer(pointLayer);\n });\n});\n",title:"3D 深色柱图",filename:"clumn_shape.js",isNew:!1}],icon:"",id:"column",title:{en:"Column Map",zh:"3D 柱状地图"},childrenKey:"demos",order:4},{demos:[{id:"simple",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*NHMmTr0SMFQAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 20,\n style: 'light',\n center: [ 120, 20 ],\n zoom: 3\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/d3564b06-670f-46ea-8edb-842f7010a7c6.json'\n )\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data)\n .shape('simple')\n .size(15)\n .color('mag', mag => {\n return mag > 4.5 ? '#5B8FF9' : '#5CCEA1';\n })\n .active(true)\n .style({\n opacity: 0.6,\n strokeWidth: 3\n });\n scene.addLayer(pointLayer);\n });\n});\n",title:"简单点图层",filename:"simple.js",isNew:!1}],icon:"",id:"simple",title:{en:"Simple Point",zh:"简单点"},childrenKey:"demos",order:4},{demos:[{id:"custom",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*7FgbRppWc38AAAAAAAAAAAAAARQnAQ",source:"import { Scene, CanvasLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nlet x = 0;\nfunction draw(option) {\n const { size, ctx, mapService } = option;\n const [ width, height ] = size;\n\n const radius = 30,\n rectWidth = radius * 2;\n const rectHeight = rectWidth;\n\n ctx.clearRect(0, 0, width, height);\n\n const points = [\n {\n lng: 108.544921875,\n lat: 30.977609093348686,\n level: 85,\n color: 'rgba(\t220,20,60, 0.6)'\n },\n {\n lng: 110.654296875,\n lat: 31.090574094954192,\n level: 75,\n color: 'rgba(\t255,140,0, 0.6)'\n },\n {\n lng: 112.5,\n lat: 29.80251790576445,\n level: 65,\n color: 'rgba(255,165,0, 0.6)'\n },\n {\n lng: 114.78515624999999,\n lat: 30.64867367928756,\n level: 40,\n color: 'rgba(30,144,255, 0.6)'\n },\n {\n lng: 116.49902343749999,\n lat: 29.84064389983441,\n level: 50,\n color: 'rgba(30,144,255, 0.6)'\n },\n {\n lng: 118.21289062499999,\n lat: 31.16580958786196,\n level: 20,\n color: 'rgba(\t127,255,0, 0.6)'\n },\n {\n lng: 119.091796875,\n lat: 32.509761735919426,\n level: 50,\n color: 'rgba(30,144,255, 0.6)'\n },\n {\n lng: 121.0693359374999,\n lat: 31.80289258670676,\n level: 45,\n color: 'rgba(30,144,255, 0.6)'\n }\n ];\n ctx.fillStyle = 'rgb(35,75,225)';\n ctx.font = 'normal small-caps bold 14px arial';\n ctx.textAlign = 'center';\n ctx.textBaseline = 'middle';\n\n points.map(point => {\n const pixelCenter = mapService.lngLatToContainer([ point.lng, point.lat ]);\n pixelCenter.x *= window.devicePixelRatio;\n pixelCenter.y *= window.devicePixelRatio;\n const rectStartX = pixelCenter.x - radius;\n const rectStartY = pixelCenter.y - radius;\n\n ctx.save();\n\n ctx.fillText(point.level + '%', pixelCenter.x, pixelCenter.y);\n\n ctx.beginPath();\n ctx.arc(pixelCenter.x, pixelCenter.y, radius, 0, Math.PI * 2);\n ctx.fillStyle = 'rgba(135,206,250,0.2)';\n ctx.closePath();\n ctx.fill();\n ctx.clip();\n\n ctx.beginPath();\n ctx.fillStyle = point.color;\n ctx.moveTo(rectStartX, pixelCenter.y);\n\n const waterheight = rectStartY + ((100 - point.level) / 100) * rectHeight;\n for (let i = 0; i <= rectWidth; i += 10) {\n ctx.lineTo(\n rectStartX + i,\n waterheight + Math.sin(Math.PI * 2 * (i / rectWidth) + x) * 3 + 1\n );\n }\n\n ctx.lineTo(pixelCenter.x + radius, pixelCenter.y + radius);\n ctx.lineTo(rectStartX, pixelCenter.y + radius);\n ctx.lineTo(rectStartX, pixelCenter.y);\n ctx.closePath();\n\n ctx.fill();\n\n ctx.restore();\n return '';\n });\n return '';\n}\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'fresh',\n center: [ 115, 31 ],\n zoom: 5.0\n })\n});\nscene.on('loaded', () => {\n const layer = new CanvasLayer({})\n .style({\n zIndex: 10,\n update: 'always',\n drawingOnCanvas: draw\n })\n .animate({\n enable: true\n });\n scene.addLayer(layer);\n\n setInterval(() => {\n x += 0.1;\n layer.style({\n drawingOnCanvas: draw\n });\n scene.render();\n return '';\n }, 30);\n return '';\n});\n\n",title:"自定义水位图",filename:"custom.js",isNew:!1},{id:"custom2",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*SsiSTaYwCBgAAAAAAAAAAAAAARQnAQ",source:"import { Scene, CanvasLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'fresh',\n center: [ 90, 31 ],\n zoom: 2\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/337ddbb7-aa3f-4679-ab60-d64359241955.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new CanvasLayer({})\n .style({\n zIndex: 10,\n update: 'dragend',\n drawingOnCanvas: option => {\n const { size, ctx, mapService } = option;\n const [ width, height ] = size;\n\n ctx.clearRect(0, 0, width, height);\n ctx.fillStyle = 'rgba(0, 200, 0, 0.2)';\n data.features.map(feature => {\n const pixelCenter = mapService.lngLatToContainer(\n feature.geometry.coordinates\n );\n pixelCenter.x *= window.devicePixelRatio;\n pixelCenter.y *= window.devicePixelRatio;\n if (\n pixelCenter.x < 0 ||\n pixelCenter.y < 0 ||\n pixelCenter.x > width ||\n pixelCenter.y > height\n ) { return ''; }\n ctx.beginPath();\n ctx.arc(\n pixelCenter.x,\n pixelCenter.y,\n feature.properties.capacity / 200,\n 0,\n Math.PI * 2\n );\n ctx.fill();\n ctx.closePath();\n return '';\n });\n return '';\n }\n });\n\n scene.addLayer(layer);\n return '';\n });\n return '';\n});\n\n",title:"自定义气泡图",filename:"custom2.js",isNew:!1},{id:"bar",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*XEPUSISnWUAAAAAAAAAAAAAAARQnAQ",source:"import { Scene, Marker } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport * as G2 from '@antv/g2';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [2.6125016864608597, 49.359131],\n zoom: 4.19,\n }),\n});\nscene.on('loaded', () => {\n addChart();\n scene.render();\n});\nfunction addChart() {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/0b96cca4-7e83-449a-93d0-2a77053e74ab.json',\n )\n .then((res) => res.json())\n .then((data) => {\n data.nodes.forEach(function (item) {\n const el = document.createElement('div');\n const total =\n item.gdp.Agriculture + item.gdp.Industry + item.gdp.Service;\n\n const size = Math.min(parseInt(total / 30000, 10), 70);\n if (size < 30) {\n return;\n }\n const itemData = [\n {\n item: 'Agriculture',\n count: item.gdp.Agriculture,\n percent: item.gdp.Agriculture / total,\n },\n {\n item: 'Industry',\n count: item.gdp.Industry,\n percent: item.gdp.Industry / total,\n },\n {\n item: 'Service',\n count: item.gdp.Service,\n percent: item.gdp.Service / total,\n },\n ];\n\n const chart = new G2.Chart({\n container: el,\n width: size,\n height: size,\n render: 'svg',\n padding: 0,\n });\n chart.legend(false);\n chart.data(itemData);\n chart.tooltip(false);\n\n chart.axis('count', false);\n chart.axis('item', false);\n chart\n .interval()\n .position('item*count')\n .color('item', ['#5CCEA1', '#5D7092', '#5B8FF9']);\n chart.render();\n const marker = new Marker({\n element: el,\n }).setLnglat({\n lng: item.coordinates[0],\n lat: item.coordinates[1],\n });\n scene.addMarker(marker);\n });\n });\n}\n",title:"柱图",filename:"bar.js",isNew:!1},{id:"chart",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*EqfuRqkVZG4AAAAAAAAAAAAAARQnAQ",source:"import { Scene, Marker } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport * as G2 from '@antv/g2';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [2.6125016864608597, 49.359131],\n zoom: 4.19\n })\n});\nscene.on('loaded', () => {\n addChart();\n scene.render();\n});\nfunction addChart() {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/0b96cca4-7e83-449a-93d0-2a77053e74ab.json'\n )\n .then(res => res.json())\n .then(data => {\n data.nodes.forEach(function (item) {\n const el = document.createElement('div');\n const total =\n item.gdp.Agriculture + item.gdp.Industry + item.gdp.Service;\n\n const size = Math.min(parseInt(total / 30000, 10), 70);\n if (size < 30) {\n return;\n }\n const itemData = [\n {\n item: 'Agriculture',\n count: item.gdp.Agriculture,\n percent: item.gdp.Agriculture / total\n },\n {\n item: 'Industry',\n count: item.gdp.Industry,\n percent: item.gdp.Industry / total\n },\n {\n item: 'Service',\n count: item.gdp.Service,\n percent: item.gdp.Service / total\n }\n ];\n\n const chart = new G2.Chart({\n container: el,\n width: size,\n height: size,\n render: 'svg',\n padding: 0\n });\n console.log(chart)\n chart.legend(false);\n chart.data(itemData);\n chart.coord('theta', {\n innerRadius: 0.6\n });\n chart.tooltip(false);\n chart\n .interval()\n .adjust('stack')\n .position('percent').color('item', ['#5CCEA1', '#5D7092', '#5B8FF9'])\n .shape('sliceShape')\n chart.render();\n const marker = new Marker({\n element: el\n }).setLnglat({\n lng: item.coordinates[0],\n lat: item.coordinates[1]\n });\n scene.addMarker(marker);\n });\n });\n}\n",title:"环图",filename:"chart.js",isNew:!1}],icon:"",id:"chart",title:{en:"Chart Map",zh:"复合图表地图"},childrenKey:"demos",order:6}],childrenKey:"examples"},{id:"line",title:{zh:"线图层",en:"Line Layer"},icon:"line",examples:[{demos:[{id:"shanghai_bus",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*EkhYRbNGkswAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 121.472644, 31.231706 ],\n zoom: 8.15,\n style: 'dark'\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/0290a972-eedd-42f6-b69e-50a35e8a0824.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data, {\n parser: {\n type: 'json',\n coordinates: 'coordinates'\n }\n })\n .size(0.5)\n .shape('line')\n .active(true)\n .color('length', [\n '#0A3663',\n '#1558AC',\n '#3771D9',\n '#4D89E5',\n '#64A5D3',\n '#72BED6',\n '#83CED6',\n '#A6E1E0',\n '#B8EFE2',\n '#D7F9F0'\n ]);\n scene.addLayer(layer);\n });\n});\n",title:"上海公交",filename:"shanghai_bus.js",isNew:!1},{id:"bus_light",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*sSx9TIOthmkAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer, Popup } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 103.83735604457024, 1.360253881403068 ],\n zoom: 9.4678190476727,\n pitch: 20,\n style: 'light'\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/ee07641d-5490-4768-9826-25862e8019e1.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data, {\n parser: {\n type: 'json',\n coordinates: 'path'\n }\n })\n .size('level', level => {\n return [ 0.8, level * 0.1 ];\n })\n .shape('line')\n .active(true)\n .color(\n 'level',\n [\n '#0A3663',\n '#1558AC',\n '#3771D9',\n '#4D89E5',\n '#64A5D3',\n '#72BED6',\n '#83CED6',\n '#A6E1E0',\n '#B8EFE2',\n '#D7F9F0'\n ]\n .reverse()\n .slice(0, 8)\n );\n layer.on('mousemove', e => {\n const popup = new Popup({\n offsets: [ 0, 0 ],\n closeButton: false\n })\n .setLnglat(e.lngLat)\n .setHTML(`车次: ${e.feature.number}`);\n scene.addPopup(popup);\n });\n scene.addLayer(layer);\n });\n});\n",title:"3D 公交线路-亮",filename:"bus_light.js",isNew:!1},{id:"bus_dark",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*92cnRJiUIf4AAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 103.83735, 1.3602538 ],\n zoom: 9.4678190476727,\n pitch: 20,\n style: 'dark'\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/ee07641d-5490-4768-9826-25862e8019e1.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data, {\n parser: {\n type: 'json',\n coordinates: 'path'\n }\n })\n .size('level', level => {\n return [ 0.8, level * 0.1 ];\n })\n .shape('line')\n .color(\n 'level',\n [\n '#312B60',\n '#4A457E',\n '#615C99',\n '#816CAD',\n '#A67FB5',\n '#C997C7',\n '#DEB8D4',\n '#F5D4E6',\n '#FAE4F1',\n '#FFF3FC'\n ].slice(0, 8)\n );\n scene.addLayer(layer);\n });\n});\n",title:"3D 公交线路-暗",filename:"bus_dark.js",isNew:!1},{id:"road_dark",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*Zq3ORrdexZwAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 116.3956, 39.9392 ],\n pitch: 20,\n zoom: 10,\n style: 'dark'\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/0d2f0113-f48b-4db9-8adc-a3937243d5a3.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data)\n .size(4)\n .shape('line')\n .color('标准名称', [ '#5B8FF9', '#5CCEA1', '#F6BD16' ])\n .style({\n borderWidth: 0.4,\n borderColor: '#fff'\n });\n scene.addLayer(layer);\n });\n});\n\n",title:"路径边框",filename:"road_dark.js",isNew:!1},{id:"road_dark_dash",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*vZFUTaBCGoEAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 116.3956, 39.9392 ],\n zoom: 10,\n style: 'dark'\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/0d2f0113-f48b-4db9-8adc-a3937243d5a3.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data)\n .size(1.5)\n .shape('line')\n .color('标准名称', [ '#5B8FF9', '#5CCEA1', '#F6BD16' ])\n .style({\n lineType: 'dash',\n dashArray: [ 5, 5 ]\n })\n ;\n scene.addLayer(layer);\n });\n});\n",title:"路径虚线",filename:"road_dark_dash.js",isNew:!1},{id:"arrow",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*glWTSoFfy1sAAAAAAAAAAAAAARQnAQ",source:"import {\n Scene,\n LineLayer,\n PointLayer\n} from '@antv/l7';\nimport {\n GaodeMap\n} from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 120.15, 30.3 ],\n zoom: 10,\n style: 'light'\n })\n});\n\nconst pointLayer = new PointLayer()\n .source([{ lng: 120.155, lat: 30.31 }], {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n })\n .shape('circle')\n .size(6000)\n .color('#f00')\n .animate(true)\n .style({\n unit: 'meter'\n });\nconst lineLayer = new LineLayer({})\n .source({\n type: 'FeatureCollection',\n features: [\n {\n type: 'Feature',\n properties: {},\n geometry: {\n type: 'LineString',\n coordinates: [\n [\n 120.1863098144,\n 30.321915039121\n ],\n [\n 120.3401184082,\n 30.43446594614\n ]\n ]\n }\n },\n {\n type: 'Feature',\n properties: {},\n geometry: {\n type: 'LineString',\n coordinates: [\n [\n 120.19660949707033,\n 30.298796461361665\n ],\n [\n 120.31883239746092,\n 30.28041626667403\n ]\n ]\n }\n },\n {\n type: 'Feature',\n properties: {},\n geometry: {\n type: 'LineString',\n coordinates: [\n [\n 120.12245178222656,\n 30.29523927312319\n ],\n [\n 120.01808166503906,\n 30.261439550638762\n ]\n ]\n }\n },\n {\n type: 'Feature',\n properties: {},\n geometry: {\n type: 'LineString',\n coordinates: [\n [\n 120.15609741210938,\n 30.285159872426014\n ],\n [\n 120.14923095703124,\n 30.20626765511821\n ]\n ]\n }\n },\n {\n type: 'Feature',\n properties: {},\n geometry: {\n type: 'LineString',\n coordinates: [\n [\n 120.10940551757812,\n 30.320136880604423\n ],\n [\n 120.01327514648438,\n 30.362803774813028\n ]\n ]\n }\n }\n ]\n }\n )\n .size(2)\n .shape('line')\n .style({\n arrow: {\n enable: true,\n arrowWidth: 4,\n arrowHeight: 4,\n tailWidth: 0.4\n }\n })\n .color('#f00');\nscene.on('loaded', () => {\n scene.addLayer(pointLayer);\n scene.addLayer(lineLayer);\n});\n",title:"箭头路径",filename:"arrow.js",isNew:!1}],icon:"",id:"path",title:{en:"Path Map",zh:"路径地图"},childrenKey:"demos",order:0},{demos:[{id:"wind_animate",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*wH50SZfOywcAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 60, 40.7128 ],\n zoom: 2\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/7455fead-1dc0-458d-b91a-fb4cf99e701e.txt'\n )\n .then(res => res.text())\n .then(data => {\n const layer = new LineLayer({ blend: 'normal' })\n .source(data,\n {\n parser: {\n type: 'csv',\n x: 'lng1',\n y: 'lat1',\n x1: 'lng2',\n y1: 'lat2'\n }\n })\n .size(1)\n .shape('arc')\n .color('#6495ED')\n .animate({\n duration: 4,\n interval: 0.2,\n trailLength: 0.6\n });\n // .forward(false)\n scene.addLayer(layer);\n });\n});\n",title:"风场动画",filename:"wind_animate.js",isNew:!1},{id:"line_animate",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*eckNS70gTfwAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 107.77791556935472, 35.443286920228644 ],\n zoom: 2.9142882493605033\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/UEXQMifxtkQlYfChpPwT.txt')\n .then(res => res.text())\n .then(data => {\n const layer = new LineLayer({\n blend: 'normal'\n })\n .source(data, {\n parser: {\n type: 'csv',\n x: 'lng1',\n y: 'lat1',\n x1: 'lng2',\n y1: 'lat2'\n }\n })\n .size(1)\n .shape('greatcircle')\n .animate({\n enable: true,\n interval: 0.1,\n trailLength: 0.5,\n duration: 2\n })\n .color('#8C1EB2')\n .style({\n opacity: 0.8\n });\n scene.addLayer(layer);\n });\n});\n",title:"直线动画",filename:"line_animate.js",isNew:!1},{id:"plane_animate2",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*2wDIS5hXKYwAAAAAAAAAAAAAARQnAQ",source:"/* eslint-disable no-eval */\nimport { Scene, LineLayer, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 40,\n center: [ 40, 40.16797 ],\n style: 'dark',\n zoom: 2.5\n })\n});\nscene.addImage(\n 'plane',\n 'https://gw.alipayobjects.com/zos/bmw-prod/0ca1668e-38c2-4010-8568-b57cb33839b9.svg'\n);\nscene.on('loaded', () => {\n Promise.all([\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/2960e1fc-b543-480f-a65e-d14c229dd777.json'\n ).then(d => d.json()),\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/4472780b-fea1-4fc2-9e4b-3ca716933dc7.json'\n ).then(d => d.text()),\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/a5ac7bce-181b-40d1-8a16-271356264ad8.json'\n ).then(d => d.text())\n ]).then(function onLoad([ world, dot, flyline ]) {\n const dotData = eval(dot);\n // @ts-ignore\n const flydata = eval(flyline).map(item => {\n // @ts-ignore\n const latlng1 = item.from.split(',').map(e => {\n return e * 1;\n });\n // @ts-ignore\n const latlng2 = item.to.split(',').map(e => {\n return e * 1;\n });\n return { coord: [ latlng1, latlng2 ] };\n });\n\n const worldLine = new LineLayer()\n .source(world)\n .color('#41fc9d')\n .size(0.5)\n .style({\n opacity: 0.4\n });\n const dotPoint = new PointLayer()\n .source(dotData, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n })\n .shape('circle')\n .color('#ffed11')\n .animate(true)\n .size(40);\n const flyLine = new LineLayer({ blend: 'normal' })\n .source(flydata, {\n parser: {\n type: 'json',\n coordinates: 'coord'\n }\n })\n .color('#ff6b34')\n .texture('plane')\n .shape('arc')\n .size(15)\n .animate({\n duration: 1,\n interval: 0.2,\n trailLength: 0.05\n })\n .style({\n textureBlend: 'replace',\n lineTexture: true, // 开启线的贴图功能\n iconStep: 10, // 设置贴图纹理的间距\n });\n\n const flyLine2 = new LineLayer()\n .source(flydata, {\n parser: {\n type: 'json',\n coordinates: 'coord'\n }\n })\n .color('#ff6b34')\n .shape('arc')\n .size(1)\n .style({\n lineType: 'dash',\n dashArray: [ 5, 5 ],\n opacity: 0.5\n });\n scene.addLayer(worldLine);\n scene.addLayer(dotPoint);\n scene.addLayer(flyLine2);\n scene.addLayer(flyLine);\n });\n});",title:"航向图",filename:"plane_animate2.js",isNew:!1},{id:"trip_animate",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*cmB1SLuyB1cAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 60,\n style: 'light',\n center: [ -74.05371169148452, 40.72573640479783 ],\n zoom: 12.45977,\n rotation: -38.39999999999969\n })\n});\n\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/bd33a685-a17e-4686-bc79-b0e6a89fd950.csv'\n )\n .then(res => res.text())\n .then(data => {\n const layer = new LineLayer({\n blend: 'normal'\n })\n .source(data, {\n parser: {\n type: 'csv',\n x: 'start station longitude',\n y: 'start station latitude',\n x1: 'end station longitude',\n y1: 'end station latitude'\n }\n })\n .size(2)\n .shape('arc3d')\n .color('#0C47BF')\n .animate({\n interval: 0.5,\n trailLength: 0.5,\n duration: 5\n })\n .style({\n opacity: 0.5\n });\n scene.addLayer(layer);\n });\n});\n",title:"3D 弧线动画",filename:"trip_animate.js",isNew:!1},{id:"animate_line",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*d7PjSo0izNAAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ -74.006, 40.7128 ],\n zoom: 14,\n style: 'dark'\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/5592c737-1c70-4d6b-82c1-e74e5a019b04.json'\n )\n .then(res => res.json())\n .then(data => {\n const lineLayer = new LineLayer()\n .source(data, {\n parser: {\n type: 'json',\n coordinates: 'path'\n }\n })\n .size(1.5)\n .shape('line')\n .color('color', v => {\n return `rgb(${v})`;\n })\n .animate({\n interval: 0.6,\n trailLength: 1.5,\n duration: 6\n });\n scene.addLayer(lineLayer);\n });\n});\n",title:"轨迹动画",filename:"animate_line.js",isNew:!1}],icon:"",id:"animate",title:{en:"Line Animate",zh:"线动画"},childrenKey:"demos",order:1},{demos:[{id:"arccircle",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*6Qm_QY69sBMAAAAAAAAAAABkARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 107.77791556935472, 35.443286920228644 ],\n zoom: 2.9142882493605033\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/UEXQMifxtkQlYfChpPwT.txt')\n .then(res => res.text())\n .then(data => {\n const layer = new LineLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'lng1',\n y: 'lat1',\n x1: 'lng2',\n y1: 'lat2'\n }\n })\n .size(1)\n .shape('greatcircle')\n .color('#8C1EB2')\n .style({\n opacity: 0.8\n });\n scene.addLayer(layer);\n });\n});\n",title:"大圆弧线",filename:"arccircle.js",isNew:!1},{id:"trip_arc_dark",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*Qg8sQ4H9RVsAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 60,\n style: 'dark',\n center: [ 104.34278, 41.12554 ],\n zoom: 2.94888,\n rotation: 42.3999\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/bmw-prod/e495c407-953b-44cc-8f77-87b9cf257578.json')\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data, {\n parser: {\n type: 'json',\n x: 'from_lon',\n y: 'from_lat',\n x1: 'to_lon',\n y1: 'to_lat'\n }\n })\n .size(1)\n .shape('arc3d')\n .color('#FF7C6A')\n .style({\n segmentNumber: 15,\n opacity: 0.8\n });\n scene.addLayer(layer);\n });\n});\n",title:"3D 弧线",filename:"trip_arc_dark.js",isNew:!1},{id:"trip_arc_dark_linear",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*8DYQTZeQyZ4AAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 57.999999999999964,\n style: 'dark',\n center: [ 101.94365594271085, 40.46139674355291 ],\n zoom: 2.7484264183323437,\n rotation: -21.600099999999884\n })\n});\n\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/UEXQMifxtkQlYfChpPwT.txt')\n .then(res => res.text())\n .then(data => {\n const layer = new LineLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'lng1',\n y: 'lat1',\n x1: 'lng2',\n y1: 'lat2'\n }\n })\n .size(1)\n .shape('arc3d')\n .color('#FF7C6A')\n .style({\n opacity: 0.8,\n sourceColor: '#f00',\n targetColor: '#6F19FF'\n });\n scene.addLayer(layer);\n });\n});\n",title:"3D 弧线(渐变)",filename:"trip_arc_dark_linear.js",isNew:!1},{id:"trip_arc",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*xvaaQo2c0gMAAAAAAAAAAABkARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 60,\n style: 'light',\n center: [ -74.06967, 40.720399 ],\n zoom: 12.45977\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/bd33a685-a17e-4686-bc79-b0e6a89fd950.csv'\n )\n .then(res => res.text())\n .then(data => {\n const layer = new LineLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'start station longitude',\n y: 'start station latitude',\n x1: 'end station longitude',\n y1: 'end station latitude'\n }\n })\n .size(1)\n .shape('arc3d')\n .color('#0C47BF')\n .style({\n blur: 0.9\n });\n scene.addLayer(layer);\n });\n});\n",title:"3D 弧线",filename:"trip_arc.js",isNew:!1}],icon:"",id:"arc",title:{en:"Arc Line Map",zh:"弧线地图"},childrenKey:"demos",order:1},{demos:[{id:"ele",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*p6LsTp3M144AAAAAAAAAAABkARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 53.6305,\n style: 'light',\n center: [ 102.600579, 23.114887 ],\n zoom: 13.5\n })\n});\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/ZVfOvhVCzwBkISNsuKCc.json')\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data)\n .size('ELEV', h => {\n return [ h % 50 === 0 ? 1.0 : 0.5, (h - 1400) * 20 ];\n })\n .shape('line')\n .scale('ELEV', {\n type: 'quantize'\n })\n .style({\n heightfixed: true\n })\n .color(\n 'ELEV',\n [\n '#E4682F',\n '#FF8752',\n '#FFA783',\n '#FFBEA8',\n '#FFDCD6',\n '#EEF3FF',\n '#C8D7F5',\n '#A5C1FC',\n '#7FA7F9',\n '#5F8AE5'\n ].reverse()\n );\n scene.addLayer(layer);\n });\n});\n",title:"等高线",filename:"ele.js",isNew:!1},{id:"ele_dark",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*jJd0Qq_E3_UAAAAAAAAAAABkARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 45.06995336442376,\n style: 'dark',\n center: [ 102.597971, 23.110479 ],\n zoom: 13.34,\n rotation: 360,\n })\n});\n\nscene.on('loaded', () => {\n fetch('https://gw.alipayobjects.com/os/rmsportal/ZVfOvhVCzwBkISNsuKCc.json')\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({\n })\n .source(data)\n .size('ELEV', h => {\n return [ h % 50 === 0 ? 1.0 : 0.5, (h - 1400) * 20 ];\n })\n .shape('line')\n .scale('ELEV', {\n type: 'quantize'\n })\n .style({\n heightfixed: true\n })\n .color('ELEV', [\n '#094D4A',\n '#146968',\n '#1D7F7E',\n '#289899',\n '#34B6B7',\n '#4AC5AF',\n '#5FD3A6',\n '#7BE39E',\n '#A1EDB8',\n '#CEF8D6'\n ]);\n scene.addLayer(layer);\n });\n});\n",title:"等高线",filename:"ele_dark.js",isNew:!1},{id:"isoline",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*RLvsSbS4PJMAAAAAAAAAAABkARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 104.117492, 36.492696 ],\n zoom: 3.89\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/9f6afbcd-3aec-4a26-bd4a-2276d3439e0d.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data)\n .scale('value', {\n type: 'quantile'\n })\n .size('value', [ 0.5, 1, 1.5, 2 ])\n .shape('line')\n .color(\n 'value',\n [\n '#0A3663',\n '#1558AC',\n '#3771D9',\n '#4D89E5',\n '#64A5D3',\n '#72BED6',\n '#83CED6',\n '#A6E1E0',\n '#B8EFE2',\n '#D7F9F0'\n ].reverse()\n );\n scene.addLayer(layer);\n });\n});\n",title:"等高线",filename:"isoline.js",isNew:!1},{id:"height",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*AARcS4YKlTYAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 60,\n style: 'dark',\n center: [ 120.958472, 23.464292 ],\n zoom: 7.65,\n rotation: 33.375609237091055\n })\n});\n\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/65589ef3-7f1d-440f-ba5d-86b03ee6ba7e.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data)\n .size(1)\n .shape('line')\n .style({\n vertexHeightScale: 30\n })\n .color('#0D5EFF');\n\n scene.addLayer(layer);\n });\n});\n",title:"海拔线",filename:"height.js",isNew:!1}],icon:"",id:"isoline",title:{en:"Isoline Map",zh:"等值线地图"},childrenKey:"demos",order:2},{demos:[{id:"hangzhou_wall",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*aIKDQaTiGkkAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 119.297868, 29.732983 ],\n zoom: 7.11,\n rotation: 1.22,\n pitch: 45.42056074766357,\n style: 'dark'\n })\n});\n\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/93a55259-328e-4e8b-8dc2-35e05844ed31.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data)\n .size(40)\n .shape('wall')\n .style({\n opacity: 'testOpacity',\n sourceColor: '#0DCCFF',\n targetColor: 'rbga(255,255,255, 0)'\n });\n scene.addLayer(layer);\n });\n});\n",title:"杭州区县围墙",filename:"hangzhou_wall.js",isNew:!1},{id:"bus_wall",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*BmYdS7zoKvYAAAAAAAAAAAAAARQnAQ",source:"import { Scene, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 121.461531, 31.096775 ],\n zoom: 8.64,\n rotation: 358.78,\n pitch: 45.42056074766357,\n style: 'dark'\n })\n});\n\nscene.addImage(\n '02',\n 'https://gw.alipayobjects.com/zos/bmw-prod/ce83fc30-701f-415b-9750-4b146f4b3dd6.svg'\n);\n\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/0290a972-eedd-42f6-b69e-50a35e8a0824.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new LineLayer({})\n .source(data.slice(0, 50), {\n parser: {\n type: 'json',\n coordinates: 'coordinates'\n }\n })\n .animate({\n interval: 1, // 间隔\n duration: 1, // 持续时间,延时\n trailLength: 2 // 流线长度\n })\n .size(20)\n .shape('wall')\n .texture('02')\n .style({\n opacity: 'testOpacity',\n lineTexture: true, // 开启线的贴图功能\n iconStep: 40, // 设置贴图纹理的间距\n iconStepCount: 4,\n sourceColor: '#00BCD2',\n targetColor: '#0074d0'\n });\n scene.addLayer(layer);\n });\n});\n",title:"公交线路围墙",filename:"bus_wall.js",isNew:!1}],icon:"",id:"wall",title:{en:"Line Wall",zh:"线路围墙"},childrenKey:"demos",order:5}],childrenKey:"examples"},{id:"polygon",title:{zh:"面图层",en:"Polygon Layer"},icon:"polygon",examples:[{demos:[{id:"polygon",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*ovizSr4Y-kYAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PolygonLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 114.050008, 22.529272 ],\n zoom: 14.1\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/972566c5-a2b9-4a7e-8da1-bae9d0eb0117.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new PolygonLayer({})\n .source(data)\n .shape('extrude')\n .size('h20', [ 100, 120, 160, 200, 260, 500 ])\n .color('h20', [\n '#816CAD',\n '#A67FB5',\n '#C997C7',\n '#DEB8D4',\n '#F5D4E6',\n '#FAE4F1',\n '#FFF3FC'\n ]);\n scene.addLayer(layer);\n });\n});\n",title:"3D 建筑面",filename:"polygon.js",isNew:!1},{id:"polygonstylemap",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*yxRiTJDOrS8AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PolygonLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n pitch: 50,\n center: [ 118.8, 32.056 ],\n zoom: 10\n })\n});\nconst colors = [\n '#87CEFA',\n '#00BFFF',\n\n '#7FFFAA',\n '#00FF7F',\n '#32CD32',\n\n '#F0E68C',\n '#FFD700',\n\n '#FF7F50',\n '#FF6347',\n '#FF0000'\n];\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/94763191-2816-4c1a-8d0d-8bcf4181056a.json'\n )\n .then(res => res.json())\n .then(data => {\n const filllayer = new PolygonLayer({\n name: 'fill',\n zIndex: 3\n })\n .source(data)\n .shape('extrude')\n .color('unit_price', colors)\n .size('unit_price', unit_price => unit_price * 50)\n .style({\n opacity: [ 'unit_price', [ 0, 1 ]],\n pickLight: true\n })\n .active(true);\n scene.addLayer(filllayer);\n });\n});\n",title:"3D 几何体样式映射",filename:"polygonstylemap.js",isNew:!1},{id:"floatmap",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*D8GeSKNZxWIAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PolygonLayer, LineLayer, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 120, 29.732983 ],\n zoom: 6.2,\n pitch: 60\n })\n});\nscene.on('loaded', () => {\n let lineDown,\n lineUp,\n textLayer;\n\n fetch('https://gw.alipayobjects.com/os/bmw-prod/ecd1aaac-44c0-4232-b66c-c0ced76d5c7d.json')\n .then(res => res.json())\n .then(data => {\n const texts = [];\n\n data.features.map(option => {\n const { name, center } = option.properties;\n const [ lng, lat ] = center;\n texts.push({ name, lng, lat });\n return '';\n });\n\n textLayer = new PointLayer({ zIndex: 2 })\n .source(texts, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat'\n }\n })\n .shape('name', 'text')\n .size(14)\n .color('#0ff')\n .style({\n textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left\n spacing: 2, // 字符间距\n padding: [ 1, 1 ], // 文本包围盒 padding [水平,垂直],影响碰撞检测结果,避免相邻文本靠的太近\n stroke: '#0ff', // 描边颜色\n strokeWidth: 0.2, // 描边宽度\n raisingHeight: 200000 + 150000 + 10000,\n textAllowOverlap: true\n });\n scene.addLayer(textLayer);\n\n lineDown = new LineLayer()\n .source(data)\n .shape('line')\n .color('#0DCCFF')\n .size(1)\n .style({\n raisingHeight: 200000\n });\n\n lineUp = new LineLayer({ zIndex: 1 })\n .source(data)\n .shape('line')\n .color('#0DCCFF')\n .size(1)\n .style({\n raisingHeight: 200000 + 150000\n });\n\n scene.addLayer(lineDown);\n scene.addLayer(lineUp);\n return '';\n });\n\n fetch('https://gw.alipayobjects.com/os/bmw-prod/d434cac3-124e-4922-8eed-ccde01674cd3.json')\n .then(res => res.json())\n .then(data => {\n const lineLayer = new LineLayer()\n .source(data)\n .shape('wall')\n .size(150000)\n .style({\n heightfixed: true,\n opacity: 0.6,\n sourceColor: '#0DCCFF',\n targetColor: 'rbga(255,255,255, 0)'\n });\n scene.addLayer(lineLayer);\n\n const provincelayer = new PolygonLayer({})\n .source(data)\n .size(150000)\n .shape('extrude')\n .color('#0DCCFF')\n .active({\n color: 'rgb(100,230,255)'\n })\n .style({\n heightfixed: true,\n pickLight: true,\n raisingHeight: 200000,\n opacity: 0.8\n });\n\n scene.addLayer(provincelayer);\n\n provincelayer.on('mousemove', () => {\n provincelayer.style({\n raisingHeight: 200000 + 100000\n });\n lineDown.style({\n raisingHeight: 200000 + 100000\n });\n lineUp.style({\n raisingHeight: 200000 + 150000 + 100000\n });\n textLayer.style({\n raisingHeight: 200000 + 150000 + 10000 + 100000\n });\n });\n\n provincelayer.on('unmousemove', () => {\n provincelayer.style({\n raisingHeight: 200000\n });\n lineDown.style({\n raisingHeight: 200000\n });\n lineUp.style({\n raisingHeight: 200000 + 150000\n });\n textLayer.style({\n raisingHeight: 200000 + 150000 + 10000\n });\n });\n return '';\n });\n return '';\n});\n",title:"漂浮地图板块",filename:"floatmap.js",isNew:!1}],icon:"",id:"3d",title:{en:"Extrude Map",zh:"3D填充图"},childrenKey:"demos",order:0},{demos:[{id:"usa",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*4Kp4Qp00kq4AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PolygonLayer, LineLayer, Popup } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ -96, 37.8 ],\n zoom: 3\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/d36ad90e-3902-4742-b8a2-d93f7e5dafa2.json'\n )\n .then(res => res.json())\n .then(data => {\n const color = [ 'rgb(255,255,217)', 'rgb(237,248,177)', 'rgb(199,233,180)', 'rgb(127,205,187)', 'rgb(65,182,196)', 'rgb(29,145,192)', 'rgb(34,94,168)', 'rgb(12,44,132)' ];\n const layer = new PolygonLayer({})\n .source(data)\n .scale('density', {\n type: 'quantile'\n })\n .color(\n 'density', color\n )\n .shape('fill')\n .active(true);\n const layer2 = new LineLayer({\n zIndex: 2\n })\n .source(data)\n .color('#fff')\n .active(true)\n .size(1)\n .style({\n lineType: 'dash',\n dashArray: [ 2, 2 ],\n });\n scene.addLayer(layer);\n scene.addLayer(layer2);\n\n layer.on('mousemove', e => {\n const popup = new Popup({\n offsets: [ 0, 0 ],\n closeButton: false\n })\n .setLnglat(e.lngLat)\n .setHTML(`${e.feature.properties.name}: ${e.feature.properties.density}`);\n scene.addPopup(popup);\n });\n });\n});\n",title:"地图交互",filename:"usa.js",isNew:!1},{id:"fill",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*t9QJRL7uVk4AAAAAAAAAAAAAARQnAQ",source:"import { Scene, PolygonLayer, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 116.368652, 39.93866 ],\n zoom: 10.07\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/1d27c363-af3a-469e-ab5b-7a7e1ce4f311.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new PolygonLayer({})\n .source(data)\n .color(\n 'unit_price',\n [\n '#1A4397',\n '#2555B7',\n '#3165D1',\n '#467BE8',\n '#6296FE',\n '#7EA6F9',\n '#98B7F7',\n '#BDD0F8',\n '#DDE6F7',\n '#F2F5FC'\n ].reverse()\n )\n .shape('fill')\n .active(true);\n const layer2 = new LineLayer({\n zIndex: 2\n })\n .source(data)\n .color('#fff')\n .size(0.8);\n\n scene.addLayer(layer);\n scene.addLayer(layer2);\n });\n});\n",title:"连续填充图",filename:"fill.js",isNew:!1},{id:"water",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*1kqvSYvWP3MAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PolygonLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ -44.40673828125, -18.375379094031825 ],\n zoom: 13\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/67130c6c-7f49-4680-915c-54e69730861d.json'\n )\n .then(data => data.json())\n .then(({ lakeData }) => {\n const lakeLayer = new PolygonLayer({ autoFit: true })\n .source(lakeData)\n .shape('water')\n .color('#1E90FF')\n .style({\n speed: 0.4\n // waterTexture: 'https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*EojwT4VzSiYAAAAAAAAAAAAAARQnAQ'\n })\n .animate(true);\n\n scene.addLayer(lakeLayer);\n });\n});\n",title:"简单水面",filename:"water.js",isNew:!1},{id:"ocean",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*BiawTbtX-CYAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PolygonLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ -44.40673828125, -18.375379094031825 ],\n zoom: 13\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/67130c6c-7f49-4680-915c-54e69730861d.json'\n )\n .then(data => data.json())\n .then(({ lakeData }) => {\n const lakeLayer = new PolygonLayer({ autoFit: true })\n .source(lakeData)\n .shape('ocean')\n .color('#1E90FF')\n .style({\n watercolor: '#6D99A8'\n // watercolor: '#0f0',\n })\n .animate(true);\n\n scene.addLayer(lakeLayer);\n });\n});\n",title:"拟真水面",filename:"ocean.js",isNew:!1}],icon:"",id:"fill",title:{en:"Choropleth Map",zh:"填充地图"},childrenKey:"demos",order:0}],childrenKey:"examples"},{id:"heatmap",title:{zh:"热力图",en:"HeatMap Layer"},icon:"heatmap",examples:[{demos:[{id:"heatmap",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*QstiQq4JBOIAAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 127.5671666579043, 7.445038892195569 ],\n zoom: 2.632456779444394\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/d3564b06-670f-46ea-8edb-842f7010a7c6.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data)\n .shape('heatmap')\n .size('mag', [ 0, 1.0 ]) // weight映射通道\n .style({\n intensity: 2,\n radius: 20,\n rampColors: {\n colors: [\n '#FF4818',\n '#F7B74A',\n '#FFF598',\n '#91EABC',\n '#2EA9A1',\n '#206C7C'\n ].reverse(),\n positions: [ 0, 0.2, 0.4, 0.6, 0.8, 1.0 ]\n }\n });\n scene.addLayer(layer);\n });\n});\n",title:"经典热力图2D",filename:"heatmap.js",isNew:!1},{id:"heatmap_purple",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*GD2bR7pb-yIAAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 127.5671666579043, 7.445038892195569 ],\n zoom: 2.632456779444394\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/d3564b06-670f-46ea-8edb-842f7010a7c6.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data)\n .shape('heatmap')\n .size('mag', [ 0, 1.0 ]) // weight映射通道\n .style({\n intensity: 2,\n radius: 20,\n rampColors: {\n colors: [\n '#FF4818',\n '#F7B74A',\n '#FFF598',\n '#F27DEB',\n '#8C1EB2',\n '#421EB2'\n ].reverse(),\n positions: [ 0, 0.2, 0.4, 0.6, 0.8, 1.0 ]\n }\n });\n scene.addLayer(layer);\n });\n});\n",title:"经典热力图2D",filename:"heatmap_purple.js",isNew:!1},{id:"heatmap3d",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*dmhzTqrHpR4AAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n pitch: 50,\n center: [ 100, 30.6942 ],\n rotation: 10,\n zoom: 2\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/337ddbb7-aa3f-4679-ab60-d64359241955.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data)\n .size('capacity', [ 0, 1 ])\n .shape('heatmap3D')\n // weight映射通道\n .style({\n intensity: 5,\n radius: 10,\n rampColors: {\n colors: [\n '#2E8AE6',\n '#69D1AB',\n '#DAF291',\n '#FFD591',\n '#FF7A45',\n '#CF1D49'\n ],\n positions: [ 0, 0.2, 0.4, 0.6, 0.8, 1.0 ]\n }\n });\n scene.addLayer(layer);\n });\n});\n",title:"经典热力图3D",filename:"heatmap3d.js",isNew:!1}],icon:"",id:"heatmap",title:{en:"HeatMap",zh:"经典热力图"},childrenKey:"demos",order:0},{demos:[{id:"grid_world",screenshot:"https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*1PeGSboLGUUAAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'blank',\n center: [ 110.097892, 33.853662 ],\n zoom: 4.056\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/3dadb1f5-8f54-4449-8206-72db6e142c40.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new HeatmapLayer({\n autoFit: true\n })\n .source(data, {\n transforms: [\n {\n type: 'hexagon',\n size: 5 * 100000\n }\n ]\n })\n .shape('circle')\n .active(false)\n .color('#aaa')\n .style({\n coverage: 0.7,\n angle: 0,\n });\n scene.addLayer(layer);\n });\n});\n",title:"网格世界地图",filename:"grid_world.js",isNew:!1},{id:"china",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*XPBuSIPPgsgAAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 107.054293, 35.246265 ],\n zoom: 4.056\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/7359a5e9-3c5e-453f-b207-bc892fb23b84.csv'\n )\n .then(res => res.text())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'lng',\n y: 'lat'\n },\n transforms: [\n {\n type: 'grid',\n size: 20000,\n field: 'v',\n method: 'sum'\n }\n ]\n })\n .shape('square')\n .style({\n coverage: 1,\n angle: 0\n })\n .color(\n 'count',\n [\n '#0B0030',\n '#100243',\n '#100243',\n '#1B048B',\n '#051FB7',\n '#0350C1',\n '#0350C1',\n '#0072C4',\n '#0796D3',\n '#2BA9DF',\n '#30C7C4',\n '#6BD5A0',\n '#A7ECB2',\n '#D0F4CA'\n ].reverse()\n );\n\n scene.addLayer(layer);\n });\n});\n",title:"网格热力图",filename:"china.js",isNew:!1},{id:"heatmap3",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*Ucz6SJ5wU_0AAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 110.097892, 33.853662 ],\n zoom: 4.056\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/7359a5e9-3c5e-453f-b207-bc892fb23b84.csv'\n )\n .then(res => res.text())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'lng',\n y: 'lat'\n },\n transforms: [\n {\n type: 'grid',\n size: 20000,\n field: 'v',\n method: 'sum'\n }\n ]\n })\n .shape('circle')\n .style({\n coverage: 0.9,\n angle: 0\n })\n .color(\n 'count',\n [\n '#8C1EB2',\n '#8C1EB2',\n '#DA05AA',\n '#F0051A',\n '#FF2A3C',\n '#FF4818',\n '#FF4818',\n '#FF8B18',\n '#F77B00',\n '#ED9909',\n '#ECC357',\n '#EDE59C'\n ].reverse()\n );\n scene.addLayer(layer);\n });\n});\n",title:"网格布局 圆形",filename:"heatmap3.js",isNew:!1},{id:"world",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*f1IDQ7AG-00AAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 110.097892, 33.853662 ],\n zoom: 4.056\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/7359a5e9-3c5e-453f-b207-bc892fb23b84.csv'\n )\n .then(res => res.text())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'lng',\n y: 'lat'\n },\n transforms: [\n {\n type: 'grid',\n size: 10000,\n field: 'v',\n method: 'sum'\n }\n ]\n })\n .shape('square')\n .style({\n coverage: 1,\n angle: 0\n })\n .color(\n 'count',\n [\n '#FF3417',\n '#FF7412',\n '#FFB02A',\n '#FFE754',\n '#46F3FF',\n '#02BEFF',\n '#1A7AFF',\n '#0A1FB2'\n ].reverse()\n );\n scene.addLayer(layer);\n });\n});\n",title:"网格热力图",filename:"world.js",isNew:!1}],icon:"",id:"grid",title:{en:"Grid Map",zh:"网格热力图"},childrenKey:"demos",order:1},{demos:[{id:"china",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*hLVeSqPl9asAAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n pitch: 47.49999999999995,\n center: [ 112.50447776627743, 30.830476390931125 ],\n zoom: 3.9879693680088626\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/7359a5e9-3c5e-453f-b207-bc892fb23b84.csv'\n )\n .then(res => res.text())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'lng',\n y: 'lat'\n },\n transforms: [\n {\n type: 'hexagon',\n size: 200000,\n field: 'v',\n method: 'sum'\n }\n ]\n })\n .size('sum', value => {\n return value * 20;\n })\n .shape('hexagonColumn')\n .color(\n 'count',\n [\n '#FF4818',\n '#F7B74A',\n '#FFF598',\n '#FF40F3',\n '#9415FF',\n '#421EB2'\n ].reverse()\n )\n .style({\n coverage: 0.9,\n angle: 0\n });\n\n scene.addLayer(layer);\n });\n});\n",title:"蜂窝热力图",filename:"china.js",isNew:!1},{id:"light",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*SLcGSbvZoEwAAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n pitch: 43,\n center: [ 120.13383079335335, 29.651873105004427 ],\n zoom: 7.068989519212174\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/a1a8158d-6fe3-424b-8e50-694ccf61c4d7.csv'\n )\n .then(res => res.text())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data, {\n parser: {\n type: 'csv',\n x: 'lng',\n y: 'lat'\n },\n transforms: [\n {\n type: 'hexagon',\n size: 2500,\n field: 'v',\n method: 'sum'\n }\n ]\n })\n .size('sum', sum => {\n return sum * 200;\n })\n .shape('hexagonColumn')\n .style({\n coverage: 0.8,\n angle: 0,\n })\n .color('sum', [\n '#094D4A',\n '#146968',\n '#1D7F7E',\n '#289899',\n '#34B6B7',\n '#4AC5AF',\n '#5FD3A6',\n '#7BE39E',\n '#A1EDB8',\n '#C3F9CC',\n '#DEFAC0',\n '#ECFFB1'\n ]);\n scene.addLayer(layer);\n });\n});\n",title:"蜂窝热力图",filename:"light.js",isNew:!1},{id:"hexagon",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*JBibTKlhhWQAAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n pitch: 56.499,\n center: [ 114.07737552216226, 22.542656745583486 ],\n rotation: 39.19,\n zoom: 12.47985\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/513add53-dcb2-4295-8860-9e7aa5236699.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data, {\n transforms: [\n {\n type: 'hexagon',\n size: 100,\n field: 'h12',\n method: 'sum'\n }\n ]\n })\n .size('sum', [ 0, 600 ])\n .shape('hexagonColumn')\n .style({\n coverage: 0.8,\n angle: 0,\n })\n .color(\n 'sum',\n [\n '#094D4A',\n '#146968',\n '#1D7F7E',\n '#289899',\n '#34B6B7',\n '#4AC5AF',\n '#5FD3A6',\n '#7BE39E',\n '#A1EDB8',\n '#CEF8D6'\n ].reverse()\n );\n scene.addLayer(layer);\n });\n});\n",title:"蜂窝热力图",filename:"hexagon.js",isNew:!1},{id:"world",screenshot:"https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*0uVgSoxXP-cAAAAAAAAAAABkARQnAQ",source:"import { Scene, HeatmapLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 104.995156, 31.450658 ],\n zoom: 3.79\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/337ddbb7-aa3f-4679-ab60-d64359241955.json'\n )\n .then(res => res.json())\n .then(data => {\n const layer = new HeatmapLayer({})\n .source(data, {\n transforms: [\n {\n type: 'hexagon',\n size: 90000,\n field: 'capacity',\n method: 'sum'\n }\n ]\n })\n .shape('hexagon')\n .style({\n coverage: 0.9,\n angle: 0,\n })\n .color(\n 'sum',\n [\n '#3F4BBA',\n '#3F4BBA',\n '#3F4BBA',\n '#3F4BBA',\n '#3C73DA',\n '#3C73DA',\n '#3C73DA',\n '#0F62FF',\n '#0F62FF',\n '#30B2E9',\n '#30B2E9',\n '#40C4CE'\n ].reverse()\n );\n scene.addLayer(layer);\n });\n});\n",title:"蜂窝热力图",filename:"world.js",isNew:!1}],icon:"",id:"hexagon",title:{en:"Hexagon Map",zh:"蜂窝热力图"},childrenKey:"demos",order:1}],childrenKey:"examples"},{id:"raster",title:{zh:"栅格图层🌟",en:"Raster Layer🌟"},icon:"raster",examples:[{demos:[{id:"radar",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*JDO-R5XU7xwAAAAAAAAAAAAAARQnAQ",source:"import { Scene, ImageLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 115.5268, 34.3628 ],\n zoom: 7\n })\n});\nscene.on('loaded', () => {\n const layer = new ImageLayer({});\n layer.source(\n 'https://gw.alipayobjects.com/mdn/antv_site/afts/img/A*8SUaRr7bxNsAAAAAAAAAAABkARQnAQ',\n {\n parser: {\n type: 'image',\n extent: [ 113.1277263548, 32.3464238863, 118.1365790452, 36.4786759137 ]\n }\n }\n );\n scene.addLayer(layer);\n});\n",title:"雷达图",filename:"radar.js",isNew:!1},{id:"image",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*8MtWSIGTN8UAAAAAAAAAAAAAARQnAQ",source:"import { Scene, ImageLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 121.268, 30.3628 ],\n zoom: 10\n })\n});\nscene.on('loaded', () => {\n const layer = new ImageLayer({});\n layer.source(\n 'https://gw.alipayobjects.com/zos/rmsportal/FnHFeFklTzKDdUESRNDv.jpg',\n {\n parser: {\n type: 'image',\n extent: [ 121.168, 30.2828, 121.384, 30.4219 ]\n }\n }\n );\n scene.addLayer(layer);\n});\n",title:"图片",filename:"image.js",isNew:!1}],icon:"",id:"basic",title:{en:"Raster Map",zh:"图片栅格"},childrenKey:"demos",order:0},{demos:[{id:"543",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*uOX7RaIElMsAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { RasterLayer, Scene } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\nimport React, { useEffect } from 'react';\nimport * as GeoTIFF from 'geotiff';\n\nasync function getTiffData(url: string) {\n const response = await fetch(url);\n const arrayBuffer = await response.arrayBuffer();\n return arrayBuffer;\n}\n\nconst scene = new Scene({\n id: 'map',\n map: new Map({\n center: [130.5, 47],\n zoom: 10.5,\n }),\n});\n\nscene.on('loaded', async () => {\n const url2 =\n 'https://t0.tianditu.gov.cn/img_w/wmts?tk=b72aa81ac2b3cae941d1eb213499e15e&';\n\n const layer2 = new RasterLayer({\n zIndex: 1,\n }).source(url2, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n wmtsOptions: {\n layer: 'img',\n tileMatrixset: 'w',\n format: 'tiles',\n },\n },\n });\n scene.addLayer(layer2);\n const url1 =\n 'https://gw.alipayobjects.com/zos/raptor/1667832825992/LC08_3857_clip_2.tif';\n const tiffdata = await getTiffData(url1);\n\n const layer = new RasterLayer({ zIndex: 10 });\n layer\n .source(\n [\n {\n data: tiffdata,\n bands: [5, 4, 3].map((v) => v - 1),\n },\n ],\n {\n parser: {\n type: 'rasterRgb',\n format: async (data, bands) => {\n const tiff = await GeoTIFF.fromArrayBuffer(data);\n const image1 = await tiff.getImage();\n const value = await image1.readRasters();\n return bands.map((band) => {\n return {\n rasterData: value[band],\n width: value.width,\n height: value.height,\n };\n });\n },\n operation: {\n type: 'rgb',\n },\n extent: [\n 130.39565357746957, 46.905730725742366, 130.73364094187343,\n 47.10217234153133,\n ],\n },\n },\n )\n .style({\n opacity: 1,\n });\n scene.addLayer(layer);\n});\n\n\n",title:"标准假彩色",filename:"543.ts",isNew:!1},{id:"432",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*JhucSo3pVVAAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { RasterLayer, Scene } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\nimport React, { useEffect } from 'react';\nimport * as GeoTIFF from 'geotiff';\n\nasync function getTiffData(url: string) {\n const response = await fetch(url);\n const arrayBuffer = await response.arrayBuffer();\n return arrayBuffer;\n}\n\nconst scene = new Scene({\n id: 'map',\n map: new Map({\n center: [130.5, 47],\n zoom: 10.5,\n }),\n});\n\nscene.on('loaded', async () => {\n const url2 =\n 'https://t0.tianditu.gov.cn/img_w/wmts?tk=b72aa81ac2b3cae941d1eb213499e15e&';\n\n const layer2 = new RasterLayer({\n zIndex: 1,\n }).source(url2, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n wmtsOptions: {\n layer: 'img',\n tileMatrixset: 'w',\n format: 'tiles',\n },\n },\n });\n scene.addLayer(layer2);\n const url1 =\n 'https://gw.alipayobjects.com/zos/raptor/1667832825992/LC08_3857_clip_2.tif';\n const tiffdata = await getTiffData(url1);\n\n const layer = new RasterLayer({ zIndex: 10 });\n layer\n .source(\n [\n {\n data: tiffdata,\n bands: [4, 3, 2].map((v) => v - 1),\n },\n ],\n {\n parser: {\n type: 'rasterRgb',\n format: async (data, bands) => {\n const tiff = await GeoTIFF.fromArrayBuffer(data);\n const image1 = await tiff.getImage();\n const value = await image1.readRasters();\n return bands.map((band) => {\n return {\n rasterData: value[band],\n width: value.width,\n height: value.height,\n };\n });\n },\n operation: {\n type: 'rgb',\n },\n extent: [\n 130.39565357746957, 46.905730725742366, 130.73364094187343,\n 47.10217234153133,\n ],\n },\n },\n )\n .style({\n opacity: 1,\n });\n scene.addLayer(layer);\n});\n\n\n",title:"自然色彩",filename:"432.ts",isNew:!1},{id:"ndbi",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*Kd59RqRj0V0AAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { RasterLayer, Scene } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nimport * as GeoTIFF from 'geotiff';\n\nasync function getTiffData(url: string) {\n const response = await fetch(url);\n const arrayBuffer = await response.arrayBuffer();\n return arrayBuffer;\n}\n\nconst scene = new Scene({\n id: 'map',\n map: new Map({\n center: [130.5, 47],\n zoom: 10.5,\n }),\n});\n\nscene.on('loaded', async () => {\n const url1 =\n 'https://gw.alipayobjects.com/zos/raptor/1667832825992/LC08_3857_clip_2.tif';\n const tiffdata = await getTiffData(url1);\n const url2 =\n 'https://t0.tianditu.gov.cn/img_w/wmts?tk=b72aa81ac2b3cae941d1eb213499e15e&';\n\n const layer2 = new RasterLayer({\n zIndex: 1,\n }).source(url2, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n zoomOffset: 1,\n wmtsOptions: {\n layer: 'img',\n tileMatrixset: 'w',\n format: 'tiles',\n },\n },\n });\n // NDBI 6,5\n // NDWI 3,5\n const layer = new RasterLayer({\n zIndex: 10,\n });\n\n layer\n .source(\n [\n {\n data: tiffdata,\n bands: [6, 5].map((v) => v - 1),\n },\n ],\n {\n parser: {\n type: 'raster',\n format: async (data, bands) => {\n const tiff = await GeoTIFF.fromArrayBuffer(data);\n const image = await tiff.getImage();\n const width = image.getWidth();\n const height = image.getHeight();\n const values = await image.readRasters();\n return [\n { rasterData: values[bands[0]], width, height }, // R\n { rasterData: values[bands[1]], width, height }, // NIR\n ];\n },\n operation: {\n type: 'nd',\n },\n extent: [\n 130.39565357746957, 46.905730725742366, 130.73364094187343,\n 47.10217234153133,\n ],\n },\n },\n )\n .style({\n domain: [-0.35, 0.6],\n rampColors: {\n colors: ['#276419', '#f7f7f7', '#ff0000'].reverse(),\n positions: [0, 0.38, 1.0],\n },\n });\n\n scene.addLayer(layer2);\n scene.addLayer(layer);\n});\n",title:"建筑指数",filename:"ndbi.ts",isNew:!1},{id:"ndvi",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*HWiES58tAhYAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { RasterLayer, Scene } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nimport * as GeoTIFF from 'geotiff';\n\nasync function getTiffData(url: string) {\n const response = await fetch(url);\n const arrayBuffer = await response.arrayBuffer();\n return arrayBuffer;\n}\n\n\nconst scene = new Scene({\n id: 'map',\n map: new Map({\n center: [130.5, 47],\n zoom: 10.5,\n }),\n});\n\nscene.on('loaded', async () => {\n const url1 =\n 'https://gw.alipayobjects.com/zos/raptor/1667832825992/LC08_3857_clip_2.tif';\n const tiffdata = await getTiffData(url1);\n const url2 =\n 'https://t0.tianditu.gov.cn/img_w/wmts?tk=b72aa81ac2b3cae941d1eb213499e15e&';\n\n const layer2 = new RasterLayer({\n zIndex: 1,\n }).source(url2, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n wmtsOptions: {\n layer: 'img',\n tileMatrixset: 'w',\n format: 'tiles',\n },\n },\n });\n // NDBI 6,5\n // NDWI 3,5\n const layer = new RasterLayer({\n zIndex: 10,\n });\n\n layer\n .source(\n [\n {\n data: tiffdata,\n bands: [4, 5].map((v) => v - 1),\n },\n ],\n {\n parser: {\n type: 'raster',\n format: async (data, bands) => {\n const tiff = await GeoTIFF.fromArrayBuffer(data);\n const image = await tiff.getImage();\n const width = image.getWidth();\n const height = image.getHeight();\n const values = await image.readRasters();\n return [\n { rasterData: values[bands[0]], width, height }, // R\n { rasterData: values[bands[1]], width, height }, // NIR\n ];\n },\n operation: {\n type: 'nd',\n },\n extent: [\n 130.39565357746957, 46.905730725742366, 130.73364094187343,\n 47.10217234153133,\n ],\n },\n },\n )\n .style({\n domain: [-0.3, 0.5],\n rampColors: {\n colors: [\n '#ce4a2e',\n '#f0a875',\n '#fff8ba',\n '#bddd8a',\n '#5da73e',\n '#235117',\n ],\n positions: [0, 0.2, 0.4, 0.6, 0.8, 1.0],\n },\n });\n\n scene.addLayer(layer2);\n scene.addLayer(layer);\n});\n",title:"植被指数",filename:"ndvi.ts",isNew:!1},{id:"ndwi",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*L4AcTbE69qcAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { RasterLayer, Scene } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nimport * as GeoTIFF from 'geotiff';\n\nasync function getTiffData(url: string) {\n const response = await fetch(url);\n const arrayBuffer = await response.arrayBuffer();\n return arrayBuffer;\n}\n\nconst scene = new Scene({\n id: 'map',\n map: new Map({\n center: [130.5, 47],\n zoom: 10.5,\n }),\n});\n\nscene.on('loaded', async () => {\n const url1 =\n 'https://gw.alipayobjects.com/zos/raptor/1667832825992/LC08_3857_clip_2.tif';\n const tiffdata = await getTiffData(url1);\n const url2 =\n 'https://t0.tianditu.gov.cn/img_w/wmts?tk=b72aa81ac2b3cae941d1eb213499e15e&';\n\n const layer2 = new RasterLayer({\n zIndex: 1,\n }).source(url2, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n wmtsOptions: {\n layer: 'img',\n tileMatrixset: 'w',\n format: 'tiles',\n },\n },\n });\n // NDBI 6,5\n // NDWI 3,5\n const layer = new RasterLayer({\n zIndex: 10,\n });\n\n layer\n .source(\n [\n {\n data: tiffdata,\n bands: [3, 5].map((v) => v - 1),\n },\n ],\n {\n parser: {\n type: 'raster',\n format: async (data, bands) => {\n const tiff = await GeoTIFF.fromArrayBuffer(data);\n const image = await tiff.getImage();\n const width = image.getWidth();\n const height = image.getHeight();\n const values = await image.readRasters();\n return [\n { rasterData: values[bands[0]], width, height }, // R\n { rasterData: values[bands[1]], width, height }, // NIR\n ];\n },\n operation: {\n type: 'nd',\n },\n extent: [\n 130.39565357746957, 46.905730725742366, 130.73364094187343,\n 47.10217234153133,\n ],\n },\n },\n )\n .style({\n domain: [0, 1],\n rampColors: {\n colors: ['#0000FF', '#FF0000'],\n positions: [0, 1.0],\n },\n });\n\n scene.addLayer(layer2);\n scene.addLayer(layer);\n});\n",title:"水体指数",filename:"ndwi.ts",isNew:!1},{id:"rgb",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*HWiES58tAhYAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { RasterLayer, Scene, metersToLngLat } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\nimport React, { useEffect } from 'react';\nimport * as GeoTIFF from 'geotiff';\n\nasync function getTiffData(url: string) {\n const response = await fetch(url);\n const arrayBuffer = await response.arrayBuffer();\n return arrayBuffer;\n}\n\n\nconst scene = new Scene({\n id: 'map',\n \n map: new Map({\n center: [130.5, 47],\n zoom: 2,\n }),\n});\n\nscene.on('loaded', async () => {\n const url1 =\n 'https://gw.alipayobjects.com/zos/raptor/1667920165972/china.tif';\n const tiffdata = await getTiffData(url1);\n const maskData = await (\n await fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/d2e0e930-fd44-4fca-8872-c1037b0fee7b.json',\n )\n ).json();\n const layer = new RasterLayer({\n zIndex: 10,\n mask: true,\n maskfence: maskData,\n });\n layer\n .source(\n [\n {\n data: tiffdata,\n bands: [0, 1, 2],\n },\n ],\n {\n parser: {\n type: 'rasterRgb',\n format: async (data, bands) => {\n const tiff = await GeoTIFF.fromArrayBuffer(data);\n const image1 = await tiff.getImage();\n const value = await image1.readRasters();\n\n return bands.map((band) => {\n return {\n rasterData: value[band],\n width: value.width,\n height: value.height,\n };\n });\n },\n operation: {\n type: 'rgb',\n options: {},\n },\n extent: [\n ...metersToLngLat([\n 8182125.2558000003919005, 427435.8622000003233552,\n ]),\n ...metersToLngLat([\n 15038832.4410999994724989, 7087852.7587999999523163,\n ]),\n ],\n },\n },\n )\n .style({\n opacity: 1,\n });\n scene.addLayer(layer);\n});\n",title:"TiFF 正射影像",filename:"rgb.ts",isNew:!1}],icon:"",id:"data_raster",title:{en:"Raster Data",zh:"多波段"},childrenKey:"demos",order:0},{demos:[{id:"light_default",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*xznhSJFEAXYAAAAAAAAAAAAAARQnAQ",source:"// https://gw.alipayobjects.com/zos/antvdemo/assets/2019_clip/ndvi_201905.tif\nimport { RasterLayer, Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport * as GeoTIFF from 'geotiff';\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 105, 37.5 ],\n zoom: 2.5\n })\n});\nscene.on('loaded', () => {\n addLayer();\n});\nasync function getTiffData() {\n const response = await fetch(\n 'https://gw.alipayobjects.com/zos/antvdemo/assets/light_clip/lightF182013.tiff'\n );\n const arrayBuffer = await response.arrayBuffer();\n const tiff = await GeoTIFF.fromArrayBuffer(arrayBuffer);\n const image = await tiff.getImage();\n const width = image.getWidth();\n const height = image.getHeight();\n const values = await image.readRasters();\n return {\n data: values[0],\n width,\n height\n };\n}\n\nasync function addLayer() {\n const tiffdata = await getTiffData();\n\n const layer = new RasterLayer({});\n layer\n .source(tiffdata.data, {\n parser: {\n type: 'raster',\n width: tiffdata.width,\n height: tiffdata.height,\n extent: [ 73.4821902409999979, 3.8150178409999995, 135.1066187319999869, 57.6300459959999998 ]\n }\n })\n .style({\n clampLow: false,\n clampHigh: false,\n domain: [ 0, 90 ],\n nodataValue: 0,\n rampColors: {\n positions: [ 0, 0.05, 0.1, 0.25, 0.5, 1.0 ],// 数据需要换成 0-1\n colors: ['rgba(92,58,16,0)','rgba(92,58,16,0)', '#fabd08', '#f1e93f', '#f1ff8f', '#fcfff7' ],\n \n }\n });\n\n scene.addLayer(layer);\n}\n",title:"夜光图-默认线性",filename:"light_default.js",isNew:!1},{id:"light",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*xznhSJFEAXYAAAAAAAAAAAAAARQnAQ",source:"// https://gw.alipayobjects.com/zos/antvdemo/assets/2019_clip/ndvi_201905.tif\nimport { RasterLayer, Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport * as GeoTIFF from 'geotiff';\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'dark',\n center: [ 105, 37.5 ],\n zoom: 2.5\n })\n});\nscene.on('loaded', () => {\n addLayer();\n});\nasync function getTiffData() {\n const response = await fetch(\n 'https://gw.alipayobjects.com/zos/antvdemo/assets/light_clip/lightF182013.tiff'\n );\n const arrayBuffer = await response.arrayBuffer();\n const tiff = await GeoTIFF.fromArrayBuffer(arrayBuffer);\n const image = await tiff.getImage();\n const width = image.getWidth();\n const height = image.getHeight();\n const values = await image.readRasters();\n return {\n data: values[0],\n width,\n height\n };\n}\n\nasync function addLayer() {\n const tiffdata = await getTiffData();\n\n const layer = new RasterLayer({});\n layer\n .source(tiffdata.data, {\n parser: {\n type: 'raster',\n width: tiffdata.width,\n height: tiffdata.height,\n extent: [ 73.4821902409999979, 3.8150178409999995, 135.1066187319999869, 57.6300459959999998 ]\n }\n })\n .style({\n clampLow: false,\n clampHigh: false,\n domain: [ 0, 90 ],\n nodataValue: 0,\n rampColors: {\n type:'linear', // 2.13.0 及以后版本支持\n colors: ['rgba(92,58,16,0)','rgba(92,58,16,0)', '#fabd08', '#f1e93f', '#f1ff8f', '#fcfff7' ],\n positions: [0,3, 9, 22.5, 45, 90 ]\n }\n });\n\n scene.addLayer(layer);\n}\n",title:"夜光图-线性色带",filename:"light.js",isNew:!1},{id:"dem",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*_RtOTrYOOrUAAAAAAAAAAAAADmJ7AQ/original",source:"// https://gw.alipayobjects.com/zos/antvdemo/assets/2019_clip/ndvi_201905.tif\nimport { RasterLayer, Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport * as GeoTIFF from 'geotiff';\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [121.268, 30.3628],\n zoom: 3,\n }),\n });\n async function getTiffData() {\n const response = await fetch(\n 'https://gw.alipayobjects.com/os/rmsportal/XKgkjjGaAzRyKupCBiYW.dat',\n );\n const arrayBuffer = await response.arrayBuffer();\n return arrayBuffer;\n }\n scene.on('loaded', async () => {\n const tiffdata = await getTiffData();\n const tiff = await GeoTIFF.fromArrayBuffer(tiffdata);\n const image = await tiff.getImage();\n const width = image.getWidth();\n const height = image.getHeight();\n const values = await image.readRasters();\n\n const layer = new RasterLayer();\n layer\n .source(values[0], {\n parser: {\n type: 'raster',\n width,\n height,\n extent: [73.482190241, 3.82501784112, 135.106618732, 57.6300459963],\n },\n })\n .style({\n opacity: 1,\n clampLow: false,\n clampHigh: false,\n domain: [0, 10000],\n rampColors: {\n type:'custom',\n colors: ['#b2182b','#d6604d','#f4a582','#fddbc7','#f7f7f7','#d1e5f0','#92c5de','#4393c3','#2166ac'],\n positions: [0, 50, 200, 500, 2000, 3000, 4000, 5000, 8000,10000],\n },\n });\n\n scene.addLayer(layer)\n});",title:"高程图-自定义色带",filename:"dem.js",isNew:!1},{id:"dem_quantize",screenshot:"https://mdn.alipayobjects.com//huamei_qa8qxu/afts/img/A*DT1HQbl4JKMAAAAAAAAAAAAADmJ7AQ/original",source:"// https://gw.alipayobjects.com/zos/antvdemo/assets/2019_clip/ndvi_201905.tif\nimport { RasterLayer, Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport * as GeoTIFF from 'geotiff';\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [121.268, 30.3628],\n zoom: 3,\n }),\n });\n async function getTiffData() {\n const response = await fetch(\n 'https://gw.alipayobjects.com/os/rmsportal/XKgkjjGaAzRyKupCBiYW.dat',\n );\n const arrayBuffer = await response.arrayBuffer();\n return arrayBuffer;\n }\n scene.on('loaded', async () => {\n const tiffdata = await getTiffData();\n const tiff = await GeoTIFF.fromArrayBuffer(tiffdata);\n const image = await tiff.getImage();\n const width = image.getWidth();\n const height = image.getHeight();\n const values = await image.readRasters();\n\n const layer = new RasterLayer();\n layer\n .source(values[0], {\n parser: {\n type: 'raster',\n width,\n height,\n extent: [73.482190241, 3.82501784112, 135.106618732, 57.6300459963],\n },\n })\n .style({\n opacity: 1,\n clampLow: false,\n clampHigh: false,\n domain: [0, 10000],\n rampColors: {\n type:'quantize', // 等间距 不需要设置 position\n colors: ['#b2182b','#d6604d','#f4a582','#fddbc7','#f7f7f7','#d1e5f0','#92c5de','#4393c3','#2166ac'],\n \n },\n });\n\n scene.addLayer(layer)\n});",title:"高程图-等间距色带",filename:"dem_quantize.js",isNew:!1}],icon:"",id:"single_raster",title:{en:"Raster Data Map",zh:"单波段"},childrenKey:"demos",order:0}],childrenKey:"examples"},{id:"tile",title:{zh:"瓦片图层 🌟",en:"Tile Layer🌟 "},icon:"raster",examples:[{demos:[{id:"dem",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*3UcORbAv_zEAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { Scene, RasterLayer } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n \n map: new Map({\n center: [113.270854, 23.141717],\n zoom: 5,\n }),\n});\n\nconst url1 =\n 'https://tiles{1-3}.geovisearth.com/base/v1/ter/{z}/{x}/{y}?format=webp&tmsIds=w&token=b2a0cfc132cd60b61391b9dd63c15711eadb9b38a9943e3f98160d5710aef788';\nconst url2 =\n 'https://tiles{1-3}.geovisearth.com/base/v1/cat/{z}/{x}/{y}?format=png&tmsIds=w&token=b2a0cfc132cd60b61391b9dd63c15711eadb9b38a9943e3f98160d5710aef788';\nconst layer1 = new RasterLayer({\n zIndex: 1,\n}).source(url1, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n zoomOffset: 0,\n },\n});\n\nconst layer2 = new RasterLayer({\n zIndex: 1,\n}).source(url2, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n zoomOffset: 0,\n },\n});\nscene.addLayer(layer1);\nscene.addLayer(layer2);\n",title:"地形图",filename:"dem.ts",isNew:!1},{id:"amap-satellite",screenshot:"https://gw.alipayobjects.com/zos/antfincdn/oRfnb3AR05/7866c85b-2d33-4ad2-a276-c52cbde041b0.png",source:"import { Scene, RasterLayer } from '@antv/l7';\nimport { Map } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new Map({\n center: [ 90.268, 40.3628 ],\n zoom: 3\n })\n});\n\nscene.on('loaded', () => {\n // 影像底图服务\n const baseLayer = new RasterLayer({\n zIndex: 1\n });\n baseLayer.source(\n 'https://webst0{1-4}.is.autonavi.com/appmaptile?style=6&x={x}&y={y}&z={z}',\n {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n // minZoom: 6,\n // maxZoom: 15,\n zoomOffset: 0\n // extent: [-180, -85.051129, 179, 85.051129],\n }\n }\n );\n\n // 影像注记服务\n const annotionLayer = new RasterLayer({\n zIndex: 2\n });\n annotionLayer.source(\n 'https://webst0{1-3}.is.autonavi.com/appmaptile?style=8&x={x}&y={y}&z={z}',\n {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n // minZoom: 6,\n // maxZoom: 15,\n zoomOffset: 0\n // extent: [-180, -85.051129, 179, 85.051129],\n }\n }\n );\n\n scene.addLayer(baseLayer);\n scene.addLayer(annotionLayer);\n});\n",title:"高德卫星影像",filename:"amap-satellite.js",isNew:!1},{id:"mask",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*UPwFRI5cUsoAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { Scene, RasterLayer, MaskLayer } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n \n map: new Map({\n center: [112, 30],\n // zoom: 12,\n zoom: 3,\n }),\n});\n\nconst mask = new MaskLayer({\n sourceLayer: 'ecoregions2', // woods hillshade contour ecoregions ecoregions2 city\n}).source(\n 'http://ganos.oss-cn-hangzhou.aliyuncs.com/m2/rs_l7/{z}/{x}/{y}.pbf',\n {\n parser: {\n type: 'mvt',\n tileSize: 256,\n maxZoom: 9,\n },\n },\n);\n\nconst layer = new RasterLayer({\n zIndex: 1,\n mask: true,\n}).source(\n 'https://tiles{1-3}.geovisearth.com/base/v1/img/{z}/{x}/{y}?format=webp&tmsIds=w&token=b2a0cfc132cd60b61391b9dd63c15711eadb9b38a9943e3f98160d5710aef788',\n {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n },\n },\n);\n\nscene.on('loaded', () => {\n scene.addLayer(mask);\n scene.addLayer(layer);\n});\n",title:"影像底图掩膜",filename:"mask.ts",isNew:!1},{id:"raster",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*Gg87TbHRYNcAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { Scene, RasterLayer } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n \n map: new Map({\n center: [113.270854, 23.141717],\n zoom: 5,\n }),\n});\n\nconst url1 =\n 'https://tiles{1-3}.geovisearth.com/base/v1/img/{z}/{x}/{y}?format=webp&tmsIds=w&token=b2a0cfc132cd60b61391b9dd63c15711eadb9b38a9943e3f98160d5710aef788';\nconst url2 =\n 'https://tiles{1-3}.geovisearth.com/base/v1/cia/{z}/{x}/{y}?format=png&tmsIds=w&token=b2a0cfc132cd60b61391b9dd63c15711eadb9b38a9943e3f98160d5710aef788';\nconst layer1 = new RasterLayer({\n zIndex: 1,\n}).source(url1, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n },\n});\n\nconst layer2 = new RasterLayer({\n zIndex: 1,\n}).source(url2, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n },\n});\n\nscene.on('loaded', () => {\n scene.addLayer(layer1);\n scene.addLayer(layer2);\n});\n",title:"卫星图",filename:"raster.ts",isNew:!1},{id:"normal",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*ZM2lR56TIwoAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { Scene, RasterLayer } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n \n map: new Map({\n center: [113.270854, 23.141717],\n zoom: 5,\n }),\n});\n\nconst url1 =\n 'https://tiles{1-3}.geovisearth.com/base/v1/vec/{z}/{x}/{y}?format=png&tmsIds=w&token=b2a0cfc132cd60b61391b9dd63c15711eadb9b38a9943e3f98160d5710aef788';\n\nconst layer1 = new RasterLayer({\n zIndex: 1,\n}).source(url1, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n zoomOffset: 0,\n },\n});\n\nconst layer2 = new RasterLayer({\n zIndex: 1,\n}).source(url1, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n zoomOffset: 0,\n },\n});\n\nscene.on('loaded', () => {\n scene.addLayer(layer1);\n scene.addLayer(layer2);\n});\n",title:"普通底图",filename:"normal.ts",isNew:!1},{id:"wms",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*Ge03Qo2cKv0AAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { Scene, RasterLayer } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n \n map: new Map({\n center: [114.061677, 22.54899],\n zoom: 11,\n }),\n});\nconst url1 =\n 'https://tiles{1-3}.geovisearth.com/base/v1/img/{z}/{x}/{y}?format=webp&tmsIds=w&token=b2a0cfc132cd60b61391b9dd63c15711eadb9b38a9943e3f98160d5710aef788';\nconst url2 =\n 'https://tiles{1-3}.geovisearth.com/base/v1/cia/{z}/{x}/{y}?format=png&tmsIds=w&token=b2a0cfc132cd60b61391b9dd63c15711eadb9b38a9943e3f98160d5710aef788';\nconst layer1 = new RasterLayer({\n zIndex: 1,\n}).source(url1, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n },\n});\n\nconst layer2 = new RasterLayer({\n zIndex: 1,\n}).source(url2, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n },\n});\n// WMS 底图 BBOX获取数据\nconst url =\n 'https://pnr.sz.gov.cn/d-suplicmap/dynamap_1/rest/services/LAND_CERTAIN/MapServer/export?F=image&FORMAT=PNG32&TRANSPARENT=true&layers=show:1&SIZE=256,256&BBOX={bbox}&BBOXSR=4326&IMAGESR=3857&DPI=90';\n\nconst layer = new RasterLayer({\n zIndex: 3,\n}).source(url, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n zoomOffset: 0,\n },\n});\n\nscene.on('loaded', () => {\n scene.addLayer(layer1);\n scene.addLayer(layer2);\n scene.addLayer(layer);\n\n});\n",title:"WMS 底图",filename:"wms.ts",isNew:!1},{id:"wmts",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*afuwT64AJVYAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { Scene, RasterLayer } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n \n map: new Map({\n center: [113.270854, 23.141717],\n zoom: 11,\n }),\n});\n\nconst url1 =\n 'https://t0.tianditu.gov.cn/img_w/wmts?tk=b72aa81ac2b3cae941d1eb213499e15e&';\nconst layer1 = new RasterLayer({\n zIndex: 1,\n}).source(url1, {\n parser: {\n type: 'rasterTile',\n tileSize: 256,\n wmtsOptions: {\n layer: 'img',\n tileMatrixset: 'w',\n format: 'tiles',\n },\n },\n});\n\n\n\nscene.on('loaded', () => {\n scene.addLayer(layer1);\n});\n",title:"天地图 WMTS 底图",filename:"wmts.ts",isNew:!1}],icon:"",id:"basemap",title:{en:"BaseMap",zh:"地图底图"},childrenKey:"demos",order:0},{demos:[{id:"terrain",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*pNs4R6YVI54AAAAAAAAAAAAADmJ7AQ/original",source:"//@ts-ignore\nimport { Scene, RasterLayer } from '@antv/l7';\n//@ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new Map({\n center: [130, 30],\n pitch: 0,\n zoom: 1.5,\n }),\n});\nscene.on('loaded', () => {\n const layer = new RasterLayer()\n .source(\n 'https://tiles{1-3}.geovisearth.com/base/v1/terrain_rgb/{z}/{x}/{y}?format=png&tmsIds=w&token=b2a0cfc132cd60b61391b9dd63c15711eadb9b38a9943e3f98160d5710aef788',\n {\n parser: {\n type: 'rasterTile',\n dataType: 'terrainRGB',\n tileSize: 256,\n zoomOffset: 0,\n },\n },\n )\n .style({\n clampLow: false,\n clampHigh: false,\n domain: [0, 7000],\n rampColors: {\n colors: ['#d73027', '#fc8d59', '#fee08b', '#d9ef8b', '#91cf60', '#1a9850'],\n positions: [0, 0.2, 0.4, 0.6, 0.8, 1.0],\n }\n });\n\n scene.addLayer(layer);\n});\n\n",title:"Terrain-RGB 高程图",filename:"terrain.ts",isNew:!1},{id:"lerc",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*Q2SlRZ8L2_sAAAAAAAAAAAAAARQnAQ",source:"import { Scene, RasterLayer, Source } from '@antv/l7';\nimport { Map } from '@antv/l7-maps';\nimport * as Lerc from 'lerc';\n\nconst colorList = [ '#fff7fb', '#ece7f2', '#d0d1e6', '#a6bddb', '#74a9cf', '#3690c0', '#0570b0', '#045a8d', '#023858' ];\nconst positions = [ 0, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 1.0 ];\nconst scene = new Scene({\n id: 'map',\n map: new Map({\n center: [ 90.268, 35.3628 ],\n zoom: 3\n })\n});\n\nscene.on('loaded', () => {\n const layer = new RasterLayer();\n const tileSource = new Source('https://elevation3d.arcgis.com/arcgis/rest/services/WorldElevation3D/Terrain3D/ImageServer/tile/{z}/{y}/{x}',\n {\n parser: {\n type: 'rasterTile',\n dataType: 'arraybuffer',\n tileSize: 256,\n format: async data => {\n const image = Lerc.decode(data);\n return {\n rasterData: image.pixels[0],\n width: image.width,\n height: image.height\n };\n }\n }\n });\n\n layer.source(tileSource)\n .style({\n domain: [ 0, 1024 ],\n clampLow: true,\n rampColors: {\n colors: colorList,\n positions\n }\n });\n\n scene.addLayer(layer);\n return '';\n});\n\nconst wrap = document.getElementById('map');\nconst legend = document.createElement('div');\n\nconst data = [];\nfor (let i = 0; i < colorList.length; i++) {\n data.push({\n color: colorList[i],\n text: positions[i]\n });\n}\nconst strArr = [];\ndata.map(({ color, text }) => {\n strArr.push(`
\n
\n ${text}\n
\n
\n
`);\n return '';\n});\nlegend.innerHTML = strArr.join('');\nlegend.style.position = 'absolute';\nlegend.style.left = '10px';\nlegend.style.bottom = '30px';\nlegend.style.background = '#fff';\nlegend.style.zIndex = 10;\n\nwrap.appendChild(legend);\n",title:"lerc 高程栅格",filename:"lerc.js",isNew:!1},{id:"tiff",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*QUb2TY71GjIAAAAAAAAAAAAAARQnAQ",source:"import { Scene, RasterLayer, Source } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport * as GeoTIFF from 'geotiff';\n\nconst colorList = [\n '#419bdf', // Water\n\n '#358221', // Tree\n\n '#88b053', // Grass\n\n\n '#7a87c6', // vegetation\n\n\n '#e49635', // Crops\n\n\n '#dfc35a', // shrub\n\n\n '#ED022A', // Built Area\n\n\n '#EDE9E4', // Bare ground\n \n\n '#F2FAFF', // Snow\n\n '#C8C8C8', // Clouds\n];\nconst positions = [\n 1,2,3,4,5,6,7,8,9,10,11,\n];\n\nconst scene = new Scene({\n id: 'map',\n \n map: new GaodeMap({\n center: [ 116, 27 ],\n zoom: 6,\n style: 'dark'\n })\n});\n\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/fccd80c0-2611-49f9-9a9f-e2a4dd12226f.json'\n )\n .then(res => res.json())\n .then(maskData => {\n const layer = new RasterLayer({\n mask: true,\n maskfence: maskData\n });\n\n const tileSource = new Source('https://ganos.oss-cn-hangzhou.aliyuncs.com/m2/l7/tiff_jx/{z}/{x}/{y}.tiff',\n {\n parser: {\n type: 'rasterTile',\n dataType: 'arraybuffer',\n tileSize: 256,\n maxZoom: 13.1,\n format: async data => {\n const tiff = await GeoTIFF.fromArrayBuffer(data);\n const image = await tiff.getImage();\n const width = image.getWidth();\n const height = image.getHeight();\n const values = await image.readRasters();\n return { rasterData: values[0], width, height };\n }\n }\n });\n\n layer.source(tileSource)\n .style({\n domain: [ 0, 255],// 枚举类型domain 必须为0-255\n clampLow: false,\n rampColors: {\n type:'cat',\n colors: colorList,\n positions\n }\n });\n\n scene.addLayer(layer);\n return '';\n });\n return '';\n});\n\nconst wrap = document.getElementById('map');\nconst legend = document.createElement('div');\n\nconst data = [];\nfor (let i = 0; i < colorList.length; i += 1) {\n data.push({\n color: colorList[i],\n text: [\n 'Water',\n 'Trees',\n 'Grass',\n 'Vegetation',\n 'Crops',\n 'Shrub',\n 'Built Area',\n 'Bare ground',\n 'Snow',\n 'Clouds'\n ][i]\n });\n}\nconst strArr = [];\ndata.map(({ color, text }) => {\n strArr.push(`
\n
\n ${text}\n
\n
\n
`);\n return '';\n});\nlegend.innerHTML = strArr.join('');\nlegend.style.position = 'absolute';\nlegend.style.left = '10px';\nlegend.style.bottom = '30px';\nlegend.style.zIndex = 10;\n\nwrap.appendChild(legend);\n\n",title:"TIFF 土地覆盖",filename:"tiff.js",isNew:!1}],icon:"",id:"raster",title:{en:"Raster Tile",zh:"栅格瓦片"},childrenKey:"demos",order:0},{demos:[{id:"chinadistrictmap",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*QlNPTpxjWEAAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { Scene, Source, PolygonLayer, LineLayer } from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n \n map: new Map({\n zoom: 4.5,\n center: [116.412427, 39.303573],\n }),\n});\n\nconst url =\n 'https://mvt.amap.com/district/CHN3/{z}/{x}/{y}/4096?key=309f07ac6bc48160e80b480ae511e1e9&version=';\nconst source = new Source(url, {\n parser: {\n type: 'mvt',\n tileSize: 256,\n warp: false,\n },\n});\n\nscene.on('loaded', () => {\n const colors = {};\n const getColorByAdcode = function (adcode) {\n if (!colors[adcode]) {\n const gb = Math.floor(Math.random() * 155 + 50);\n colors[adcode] = 'rgb(' + gb + ',' + gb + ',255)';\n }\n\n return colors[adcode];\n };\n // 绿地\n const fill = new PolygonLayer({\n sourceLayer: 'CHN_Districts',\n })\n .source(source)\n .shape('fill')\n .color('adcode', getColorByAdcode);\n\n const line = new LineLayer({\n sourceLayer: 'CHN_Districts_L',\n })\n .source(source)\n .shape('simple')\n .color('#fee0d2');\n\n const line2 = new LineLayer({\n sourceLayer: 'CHN_Citys_L',\n })\n .source(source)\n .shape('line')\n .size(0.6)\n .color('#fc9272');\n\n const line3 = new LineLayer({\n sourceLayer: 'CHN_Provinces_L',\n })\n .source(source)\n .shape('line')\n .size(0.6)\n .color('#de2d26');\n\n scene.addLayer(fill);\n scene.addLayer(line);\n scene.addLayer(line2);\n scene.addLayer(line3);\n // scene.addLayer(line2);\n // const debugerLayer = new TileDebugLayer({ usage: 'basemap' });\n // scene.addLayer(debugerLayer);\n});\n",title:"中国区县地图",filename:"chinadistrictmap.ts",isNew:!1},{id:"chinamap",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*kY2sRLu2sTYAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport {\n Scene,\n Source,\n PolygonLayer,\n PointLayer,\n LineLayer,\n} from '@antv/l7';\n// @ts-ignore\nimport { Map } from '@antv/l7-maps';\n\nconst colors = {};\nconst GDPSpeed = {\n '520000': 10, //贵州\n '540000': 10, //西藏\n '530000': 8.5, //云南\n '500000': 8.5, //重庆\n '360000': 8.5, //江西\n '340000': 8.0, //安徽\n '510000': 7.5, //四川\n '350000': 8.5, //福建\n '430000': 8.0, //湖南\n '420000': 7.5, //湖北\n '410000': 7.5, //河南\n '330000': 7.0, //浙江\n '640000': 7.5, //宁夏\n '650000': 7.0, //新疆\n '440000': 7.0, //广东\n '370000': 7.0, //山东\n '450000': 7.3, //广西\n '630000': 7.0, //青海\n '320000': 7.0, //江苏\n '140000': 6.5, //山西\n '460000': 7, // 海南\n '310000': 6.5, //上海\n '110000': 6.5, // 北京\n '130000': 6.5, // 河北\n '230000': 6, // 黑龙江\n '220000': 6, // 吉林\n '210000': 6.5, //辽宁\n '150000': 6.5, //内蒙古\n '120000': 5, // 天津\n '620000': 6, // 甘肃\n '610000': 8.5, // 甘肃\n '710000': 6.64, //台湾\n '810000': 6.0, //香港\n '820000': 6.7, //澳门\n};\nconst getColorByDGP = function (adcode) {\n if (!colors[adcode]) {\n const gdp = GDPSpeed[adcode];\n if (!gdp) {\n colors[adcode] = 'rgb(227,227,227)';\n } else {\n const rg = 255 - Math.floor(((gdp - 5) / 5) * 255);\n colors[adcode] = 'rgb(' + rg + ',' + rg + ',255)';\n }\n }\n return colors[adcode];\n};\n\nconst scene = new Scene({\n id: 'map',\n \n map: new Map({\n center: [112, 30],\n\n // zoom: 12,\n zoom: 3,\n }),\n});\n\nconst url =\n 'https://mvt.amap.com/district/CHN2/{z}/{x}/{y}/4096?key=309f07ac6bc48160e80b480ae511e1e9&version=';\nconst source = new Source(url, {\n parser: {\n type: 'mvt',\n tileSize: 256,\n warp: false,\n },\n});\n\nscene.on('loaded', () => {\n // 绿地\n const fill = new PolygonLayer({\n sourceLayer: 'CHN_Cities',\n })\n .source(source)\n .shape('fill')\n .color('adcode_pro', getColorByDGP);\n\n const line = new LineLayer({\n sourceLayer: 'CHN_Cities_L',\n })\n .source(source)\n .shape('line')\n .color('#FFA500');\n\n const line2 = new LineLayer({\n sourceLayer: 'CHN_L',\n })\n .source(source)\n .shape('line')\n .size(0.6)\n .color('#053061');\n\n const text = new PointLayer({\n sourceLayer: 'CHN_Cities',\n blend: 'normal',\n })\n .source(source)\n .shape('id', 'text')\n .size(12)\n .color('#000');\n scene.addLayer(fill);\n scene.addLayer(line);\n scene.addLayer(line2);\n scene.addLayer(text);\n});\n",title:"中国城市地图",filename:"chinamap.ts",isNew:!1},{id:"point",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*LF3vSbPk2ZEAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { Scene, PointLayer } from '@antv/l7';\n// @ts-ignore\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [112, 30],\n zoom: 3,\n style:'normal'\n }),\n});\n\nconst layer = new PointLayer({\n featureId: 'COLOR',\n sourceLayer: 'ecoregions2', // woods hillshade contour ecoregions ecoregions2 city\n});\nlayer\n .source(\n 'http://ganos.oss-cn-hangzhou.aliyuncs.com/m2/rs_l7/{z}/{x}/{y}.pbf',\n {\n parser: {\n type: 'mvt',\n tileSize: 256,\n zoomOffset: 0,\n maxZoom: 9,\n extent: [-180, -85.051129, 179, 85.051129],\n },\n },\n )\n .shape('circle')\n .color('COLOR')\n .size(10);\n// .select(true);\n\nscene.on('loaded', () => {\n scene.addLayer(layer);\n});\n",title:"瓦片点图层",filename:"point.ts",isNew:!1},{id:"polygon",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*OLv5T4PTzH4AAAAAAAAAAAAADmJ7AQ/fmt.webp",source:"// @ts-ignore\nimport { Scene, PolygonLayer, PointLayer } from '@antv/l7';\n// @ts-ignore\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n \n map: new GaodeMap({\n center: [112, 30],\n zoom: 3,\n }),\n});\n\nconst layer = new PolygonLayer({\n featureId: 'COLOR',\n sourceLayer: 'ecoregions2', // woods hillshade contour ecoregions ecoregions2 city\n});\nlayer\n .source(\n 'http://ganos.oss-cn-hangzhou.aliyuncs.com/m2/rs_l7/{z}/{x}/{y}.pbf',\n {\n parser: {\n type: 'mvt',\n tileSize: 256,\n maxZoom: 9,\n extent: [-180, -85.051129, 179, 85.051129],\n },\n },\n )\n // .shape('line')\n .color('COLOR')\n // .active(true)\n .size(10)\n .select(true)\n\n .style({\n // opacity: 0.3\n });\n\nconst point = new PointLayer({ zIndex: 1 })\n .source(\n [\n {\n lng: 120,\n lat: 30,\n },\n ],\n {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat',\n },\n },\n )\n .shape('circle')\n .size(40)\n .active(true)\n .color('#f00');\n\nscene.on('loaded', () => {\n scene.addLayer(layer);\n\n setTimeout(() => {\n point.setData([\n {\n lng: 123,\n lat: 30,\n },\n ]);\n\n point.color('#ff0');\n scene.render();\n console.log('update');\n }, 3000);\n // layer.on('inited', () => {\n // console.log(\n // 'layer.getLayerConfig().enableHighlight',\n // layer.getLayerConfig().enableHighlight,\n // );\n // });\n\n layer.on('click', (e) => {\n console.log('click');\n console.log(e);\n });\n\n scene.addLayer(point);\n});\n",title:"面图层",filename:"polygon.ts",isNew:!1},{id:"simpleline",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*cF8gRqAdXTMAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { Scene, LineLayer } from '@antv/l7';\n// @ts-ignore\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n \n map: new GaodeMap({\n style:\"light\",\n center: [112, 30],\n zoom: 6,\n }),\n});\n\nconst layer = new LineLayer({\n featureId: 'COLOR',\n sourceLayer: 'ecoregions2', // woods hillshade contour ecoregions ecoregions2 city\n});\nlayer\n .source(\n 'http://ganos.oss-cn-hangzhou.aliyuncs.com/m2/rs_l7/{z}/{x}/{y}.pbf',\n {\n parser: {\n type: 'mvt',\n tileSize: 256,\n zoomOffset: 0,\n maxZoom: 9,\n },\n },\n )\n .shape('simple')\n .color('COLOR')\n .size(1)\n .select(true);\nscene.on('loaded', () => {\n scene.addLayer(layer);\n});\n",title:"线图层",filename:"simpleline.ts",isNew:!1},{id:"worldmap",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*v9uTSJpdeksAAAAAAAAAAAAADmJ7AQ/original",source:'// @ts-ignore\nimport {\n Scene,\n Source,\n PolygonLayer,\n LineLayer,\n PointLayer\n} from \'@antv/l7\';\n// @ts-ignore\nimport { GaodeMap } from \'@antv/l7-maps\';\n\nconst data = [{ "name": "美国", "qz": "82404" }, { "name": "格陵兰(丹)", "qz": "18" }, { "name": "中国", "qz": "79404" }, { "name": "意大利", "qz": "80539" }, { "name": "西班牙", "qz": "56188" }, { "name": "德国", "qz": "36508" }, { "name": "伊朗", "qz": "29406" }, { "name": "法国", "qz": "29155" }, { "name": "英国", "qz": "11658" }, { "name": "韩国", "qz": "9232" }, { "name": "瑞士", "qz": "8789" }, { "name": "荷兰", "qz": "7431" }, { "name": "比利时", "qz": "6235" }, { "name": "奥地利", "qz": "5888" }, { "name": "土耳其", "qz": "3629" }, { "name": "加拿大", "qz": "3409" }, { "name": "葡萄牙", "qz": "2995" }, { "name": "挪威", "qz": "2916" }, { "name": "澳大利亚", "qz": "2799" }, { "name": "瑞典", "qz": "2510" }, { "name": "巴西", "qz": "2433" }, { "name": "以色列", "qz": "2369" }, { "name": "马来西亚", "qz": "2031" }, { "name": "爱尔兰", "qz": "1819" }, { "name": "丹麦", "qz": "1724" }, { "name": "捷克", "qz": "1654" }, { "name": "卢森堡", "qz": "1453" }, { "name": "日本", "qz": "1313" }, { "name": "厄瓜多尔", "qz": "1211" }, { "name": "智利", "qz": "1142" }, { "name": "巴基斯坦", "qz": "1057" }, { "name": "波兰", "qz": "1051" }, { "name": "泰国", "qz": "1045" }, { "name": "罗马尼亚", "qz": "906" }, { "name": "沙特阿拉伯", "qz": "900" }, { "name": "印度尼西亚", "qz": "893" }, { "name": "芬兰", "qz": "880" }, { "name": "俄罗斯", "qz": "840" }, { "name": "希腊", "qz": "821" }, { "name": "冰岛", "qz": "737" }, { "name": "钻石公主号邮轮", "qz": "712" }, { "name": "南非", "qz": "709" }, { "name": "印度", "qz": "694" }, { "name": "菲律宾", "qz": "636" }, { "name": "新加坡", "qz": "631" }, { "name": "巴拿马", "qz": "558" }, { "name": "卡塔尔", "qz": "537" }, { "name": "斯洛文尼亚", "qz": "528" }, { "name": "阿根廷", "qz": "502" }, { "name": "秘鲁", "qz": "480" }, { "name": "墨西哥", "qz": "478" }, { "name": "哥伦比亚", "qz": "470" }, { "name": "埃及", "qz": "456" }, { "name": "巴林", "qz": "419" }, { "name": "克罗地亚", "qz": "418" }, { "name": "爱沙尼亚", "qz": "404" }, { "name": "多米尼加共和国", "qz": "392" }, { "name": "塞尔维亚", "qz": "384" }, { "name": "黎巴嫩", "qz": "368" }, { "name": "伊拉克", "qz": "346" }, { "name": "阿拉伯联合酋长国", "qz": "333" }, { "name": "亚美尼亚", "qz": "290" }, { "name": "立陶宛", "qz": "290" }, { "name": "新西兰", "qz": "262" }, { "name": "匈牙利", "qz": "261" }, { "name": "阿尔及利亚", "qz": "246" }, { "name": "保加利亚", "qz": "242" }, { "name": "摩洛哥", "qz": "225" }, { "name": "拉脱维亚", "qz": "221" }, { "name": "乌拉圭", "qz": "217" }, { "name": "斯洛伐克", "qz": "216" }, { "name": "安道尔共和国", "qz": "213" }, { "name": "圣马力诺", "qz": "208" }, { "name": "科威特", "qz": "208" }, { "name": "哥斯达黎加", "qz": "201" }, { "name": "北马其顿共和国", "qz": "177" }, { "name": "阿尔巴尼亚", "qz": "174" }, { "name": "波斯尼亚和黑塞哥维那", "qz": "173" }, { "name": "突尼斯", "qz": "173" }, { "name": "约旦", "qz": "172" }, { "name": "乌克兰", "qz": "156" }, { "name": "摩尔多瓦", "qz": "149" }, { "name": "布基纳法索", "qz": "146" }, { "name": "越南", "qz": "141" }, { "name": "塞浦路斯", "qz": "132" }, { "name": "法罗群岛", "qz": "132" }, { "name": "马耳他", "qz": "129" }, { "name": "文莱", "qz": "109" }, { "name": "委内瑞拉", "qz": "107" }, { "name": "塞内加尔", "qz": "105" }, { "name": "斯里兰卡", "qz": "102" }, { "name": "阿曼", "qz": "99" }, { "name": "柬埔寨", "qz": "98" }, { "name": "哈萨克斯坦", "qz": "97" }, { "name": "阿塞拜疆", "qz": "93" }, { "name": "白俄罗斯", "qz": "86" }, { "name": "留尼汪岛", "qz": "83" }, { "name": "阿富汗", "qz": "80" }, { "name": "科特迪瓦", "qz": "80" }, { "name": "格鲁吉亚", "qz": "77" }, { "name": "瓜德罗普", "qz": "76" }, { "name": "喀麦隆", "qz": "72" }, { "name": "科索沃地区", "qz": "71" }, { "name": "加纳", "qz": "68" }, { "name": "马提尼克", "qz": "66" }, { "name": "乌兹别克斯坦", "qz": "65" }, { "name": "巴勒斯坦", "qz": "64" }, { "name": "特立尼达和多巴哥", "qz": "60" }, { "name": "古巴", "qz": "57" }, { "name": "黑山", "qz": "52" }, { "name": "洪都拉斯", "qz": "52" }, { "name": "波多黎各", "qz": "51" }, { "name": "刚果(金)", "qz": "51" }, { "name": "列支敦士登", "qz": "51" }, { "name": "毛里求斯", "qz": "47" }, { "name": "尼日利亚", "qz": "46" }, { "name": "吉尔吉斯斯坦", "qz": "44" }, { "name": "巴拉圭", "qz": "41" }, { "name": "卢旺达", "qz": "41" }, { "name": "玻利维亚", "qz": "39" }, { "name": "孟加拉国", "qz": "39" }, { "name": "关岛", "qz": "37" }, { "name": "马约特岛", "qz": "35" }, { "name": "肯尼亚", "qz": "31" }, { "name": "根西岛", "qz": "30" }, { "name": "法属圭亚那", "qz": "28" }, { "name": "牙买加", "qz": "26" }, { "name": "直布罗陀", "qz": "26" }, { "name": "法属玻利尼西亚", "qz": "25" }, { "name": "危地马拉", "qz": "24" }, { "name": "多哥", "qz": "23" }, { "name": "马恩岛", "qz": "23" }, { "name": "摩纳哥", "qz": "23" }, { "name": "阿鲁巴岛", "qz": "19" }, { "name": "马达加斯加", "qz": "19" }, { "name": "巴巴多斯", "qz": "18" }, { "name": "泽西岛", "qz": "18" }, { "name": "美属维尔京群岛", "qz": "17" }, { "name": "新喀里多尼亚", "qz": "14" }, { "name": "乌干达", "qz": "14" }, { "name": "马尔代夫", "qz": "13" }, { "name": "坦桑尼亚", "qz": "13" }, { "name": "萨尔瓦多", "qz": "13" }, { "name": "吉布提", "qz": "12" }, { "name": "埃塞俄比亚", "qz": "12" }, { "name": "赤道几内亚", "qz": "11" }, { "name": "法属圣马丁岛", "qz": "11" }, { "name": "蒙古", "qz": "10" }, { "name": "海地", "qz": "8" }, { "name": "开曼群岛", "qz": "8" }, { "name": "塞舌尔", "qz": "7" }, { "name": "百慕大群岛", "qz": "7" }, { "name": "苏里南", "qz": "7" }, { "name": "加蓬", "qz": "6" }, { "name": "库拉索", "qz": "6" }, { "name": "圭亚那", "qz": "5" }, { "name": "叙利亚", "qz": "5" }, { "name": "格林兰岛", "qz": "5" }, { "name": "中非共和国", "qz": "5" }, { "name": "莫桑比克", "qz": "5" }, { "name": "斐济", "qz": "5" }, { "name": "贝宁", "qz": "5" }, { "name": "纳米比亚", "qz": "5" }, { "name": "巴哈马", "qz": "5" }, { "name": "缅甸", "qz": "5" }, { "name": "几内亚", "qz": "5" }, { "name": "史瓦帝尼", "qz": "4" }, { "name": "斯威士兰", "qz": "4" }, { "name": "厄立特里亚", "qz": "4" }, { "name": "梵蒂冈", "qz": "4" }, { "name": "刚果(布)", "qz": "4" }, { "name": "尼日尔", "qz": "4" }, { "name": "老挝", "qz": "3" }, { "name": "安提瓜和巴布达", "qz": "3" }, { "name": "圣卢西亚", "qz": "3" }, { "name": "圣巴泰勒米岛", "qz": "3" }, { "name": "尼泊尔", "qz": "3" }, { "name": "乍得", "qz": "3" }, { "name": "苏丹", "qz": "3" }, { "name": "利比里亚", "qz": "3" }, { "name": "佛得角", "qz": "3" }, { "name": "赞比亚", "qz": "3" }, { "name": "毛里塔尼亚", "qz": "2" }, { "name": "索马里", "qz": "2" }, { "name": "尼加拉瓜", "qz": "2" }, { "name": "马里", "qz": "2" }, { "name": "几内亚比绍", "qz": "2" }, { "name": "多米尼克", "qz": "2" }, { "name": "圣基茨和尼維斯", "qz": "2" }, { "name": "蒙特塞拉特", "qz": "2" }, { "name": "冈比亚", "qz": "2" }, { "name": "伯利兹", "qz": "2" }, { "name": "安哥拉", "qz": "2" }, { "name": "津巴布韦", "qz": "2" }, { "name": "不丹", "qz": "2" }, { "name": "荷属圣马丁", "qz": "2" }, { "name": "圣文森特和格林纳丁斯", "qz": "1" }, { "name": "东帝汶", "qz": "1" }, { "name": "格林纳达", "qz": "1" }, { "name": "特克斯和凯科斯群岛", "qz": "1" }, { "name": "利比亚", "qz": "1" }, { "name": "巴布亚新几内亚", "qz": "1" }];\n\nconst counts = [10000, 5000, 1000, 500, 100];\nconst color = [\'#fcfbfd\',\'#efedf5\',\'#dadaeb\',\'#bcbddc\',\'#9e9ac8\',\'#807dba\',\'#6a51a3\',\'#4a1486\'].reverse();\nconst scene = new Scene({\n id: \'map\',\n \n map: new GaodeMap({\n center: [100, 30],\n minZoom: 0,\n zoom: 2,\n }),\n});\n\nconst url =\n \'https://mvt.amap.com/district/WLD/{z}/{x}/{y}/4096?key=309f07ac6bc48160e80b480ae511e1e9&version=\';\nconst source = new Source(url, {\n parser: {\n type: \'mvt\',\n tileSize: 256,\n warp: false,\n },\n});\nfunction unicode2Char(name) {\n const code = name\n .split(\'/\')\n .slice(1)\n .map((c) => {\n return String.fromCharCode(\'0x\' + c);\n });\n return code.join(\'\');\n}\n\nscene.on(\'loaded\', () => {\n // 绿地\n const water_surface = new PolygonLayer({\n sourceLayer: \'WLD\',\n zIndex: 1,\n })\n .source(source)\n .select(true)\n .active(false)\n .shape(\'fill\')\n // .color(\'red\')\n .color(\'NAME_CHN\', (NAME_CHN) => {\n const namestr = unicode2Char(NAME_CHN);\n const country = data.find((c) => {\n return c.name == namestr;\n });\n if (!country) {\n return \'#ffff33\';\n }\n const qz = ((country.qz as unknown) as number) * 1;\n if (qz > counts[0]) {\n return color[0];\n } else if (qz > counts[1]) {\n return color[1];\n } else if (qz > counts[2]) {\n return color[2];\n } else if (qz > counts[3]) {\n return color[3];\n } else {\n return color[4];\n }\n });\n\n const line = new LineLayer({\n sourceLayer: \'WLD_L\',\n zIndex: 2,\n })\n .source(source)\n .shape(\'line\')\n .size(0.6)\n .color(\'type\', (t) => {\n if (t === \'0\') {\n return \'red\';\n }\n if (t === \'2\') {\n return \'#09f\';\n }\n return \'#fc9272\';\n });\n\n const text = new PointLayer({\n sourceLayer: \'WLD\',\n blend: \'normal\',\n zIndex: 10,\n })\n .source(source)\n .shape(\'NAME_CHN\', (NAME_CHN) => {\n return unicode2Char(NAME_CHN);\n })\n .size(12)\n .color(\'#000\');\n\n // water_surface.on(\'click\', (e) => {\n // console.log(e);\n // });\n\n\n scene.addLayer(water_surface);\n scene.addLayer(text);\n scene.addLayer(line);\n});\n',title:"世界地图-瓦片",filename:"worldmap.ts",isNew:!1},{id:"geojson-vt",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*amqiQaYHIKYAAAAAAAAAAAAADmJ7AQ/original",source:"// @ts-ignore\nimport { Scene, Source, PolygonLayer } from '@antv/l7';\n// @ts-ignore\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [121.268, 30.3628],\n pitch: 0,\n zoom: 4,\n }),\n});\n\nfetch(\n 'https://gw.alipayobjects.com/os/bmw-prod/2b7aae6e-5f40-437f-8047-100e9a0d2808.json',\n)\n .then((d) => d.json())\n .then((data) => {\n const source = new Source(data, {\n parser: {\n type: 'geojsonvt',\n tileSize: 256,\n zoomOffset: 0,\n maxZoom: 9,\n // extent: [-180, -85.051129, 179, 85.051129],\n },\n });\n\n const polygon = new PolygonLayer({\n featureId: 'COLOR',\n })\n .source(source)\n .color('COLOR')\n .shape('fill')\n // .active(true)\n // .select(true)\n .style({\n opacity: 0.6,\n });\n scene.addLayer(polygon);\n\n });\n",title:"GeoJSON-Vt",filename:"geojson-vt.ts",isNew:!1}],icon:"",id:"vector",title:{en:"Vector Tile",zh:"矢量瓦片"},childrenKey:"demos",order:0}],childrenKey:"examples"},{id:"component",title:{zh:"组件",en:"Component"},icon:"map",examples:[{demos:[{id:"logo",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*XgipRbN_k3wAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GaodeMap, Logo } from '@antv/l7';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n // 关闭默认 L7 Logo\n logoVisible: false,\n});\nscene.on('loaded', () => {\n const logo = new Logo();\n scene.addControl(logo);\n});\n",title:{zh:"Logo",en:"Logo"},filename:"logo.ts",isNew:!1},{id:"zoom",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*PRkHRonRENYAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GaodeMap, Zoom } from '@antv/l7';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n});\nscene.on('loaded', () => {\n const zoom = new Zoom();\n scene.addControl(zoom);\n});\n",title:{zh:"Zoom 缩放",en:"Zoom"},filename:"zoom.ts",isNew:!1},{id:"scale",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*5dWeRaRpOHEAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GaodeMap, Scale } from '@antv/l7';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n logoVisible: false,\n});\nscene.on('loaded', () => {\n const scale = new Scale();\n scene.addControl(scale);\n});\n",title:{zh:"Scale 比例尺",en:"Scale"},filename:"scale.ts",isNew:!1},{id:"fullscreen",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*fqJlQ5vJVicAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GaodeMap, Fullscreen } from '@antv/l7';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n});\nscene.on('loaded', () => {\n const fullscreen = new Fullscreen();\n scene.addControl(fullscreen);\n});\n",title:{zh:"Fullscreen 全屏",en:"Fullscreen"},filename:"fullscreen.ts",isNew:!1},{id:"geolocate",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*aElZR7bPFGAAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GaodeMap, GeoLocate } from '@antv/l7';\nimport gcoord from 'gcoord';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n});\nscene.on('loaded', () => {\n const geoLocate = new GeoLocate({\n transform: (position) => {\n // 将获取到基于 WGS84 地理坐标系 的坐标转成 GCJ02 坐标系\n return gcoord.transform(position, gcoord.WGS84, gcoord.GCJ02);\n },\n });\n scene.addControl(geoLocate);\n});\n",title:{zh:"GeoLocate 定位",en:"GeoLocate"},filename:"geolocate.ts",isNew:!1},{id:"exportimage",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*at1HRbHfipUAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GaodeMap, ExportImage, PolygonLayer } from '@antv/l7';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n WebGLParams: {\n preserveDrawingBuffer: true,\n },\n }),\n});\nscene.on('loaded', () => {\n const polygonLayer = new PolygonLayer({});\n polygonLayer\n .source({\n type: 'FeatureCollection',\n features: [\n {\n type: 'Feature',\n properties: {},\n geometry: {\n type: 'Polygon',\n coordinates: [\n [\n [120.143575, 30.239811],\n [120.143575, 30.247856],\n [120.151213, 30.247856],\n [120.151213, 30.239811],\n [120.143575, 30.239811],\n ],\n ],\n },\n },\n ],\n })\n .color('#ff0000')\n .style({\n opacity: 0.5,\n });\n scene.addLayer(polygonLayer);\n const exportImage = new ExportImage({\n onExport: (base64) => {\n alert(base64);\n },\n });\n scene.addControl(exportImage);\n});\n",title:{zh:"ExportImage 导出图片",en:"ExportImage"},filename:"exportimage.ts",isNew:!1},{id:"mouselocation",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*sJF1S4JaPx8AAAAAAAAAAAAAARQnAQ",source:"import { Scene, GaodeMap, MouseLocation } from '@antv/l7';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n});\nscene.on('loaded', () => {\n const mouseLocation = new MouseLocation({\n position: 'bottomright',\n });\n scene.addControl(mouseLocation);\n});\n",title:{zh:"MouseLocation 鼠标经纬度",en:"MouseLocation"},filename:"mouselocation.ts",isNew:!1},{id:"layerswitch",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*gWO_T6xpVtwAAAAAAAAAAAAAARQnAQ",source:"import {\n Scene,\n GaodeMap,\n PolygonLayer,\n LayerSwitch,\n LineLayer,\n} from '@antv/l7';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n});\nscene.on('loaded', () => {\n const polygonLayer = new PolygonLayer({\n name: '填充图层',\n });\n polygonLayer\n .source({\n type: 'FeatureCollection',\n features: [\n {\n type: 'Feature',\n properties: {},\n geometry: {\n type: 'Polygon',\n coordinates: [\n [\n [120.143575, 30.239811],\n [120.143575, 30.247856],\n [120.151213, 30.247856],\n [120.151213, 30.239811],\n [120.143575, 30.239811],\n ],\n ],\n },\n },\n ],\n })\n .color('#ff0000')\n .style({\n opacity: 0.5,\n });\n scene.addLayer(polygonLayer);\n\n const lineLayer = new LineLayer({\n name: '边框图层',\n });\n lineLayer\n .source({\n type: 'FeatureCollection',\n features: [\n {\n type: 'Feature',\n properties: {},\n geometry: {\n type: 'Polygon',\n coordinates: [\n [\n [120.143575, 30.239811],\n [120.143575, 30.247856],\n [120.151213, 30.247856],\n [120.151213, 30.239811],\n [120.143575, 30.239811],\n ],\n ],\n },\n },\n ],\n })\n .color('#700000')\n .size(2);\n scene.addLayer(lineLayer);\n\n const layerSwitch = new LayerSwitch({\n layers: [polygonLayer, lineLayer],\n });\n scene.addControl(layerSwitch);\n});\n",title:{zh:"LayerSwitch 图层显隐控制",en:"LayerSwitch"},filename:"layerswitch.ts",isNew:!1},{id:"maptheme",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*byM3QZbjqScAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GaodeMap, MapTheme } from '@antv/l7';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n});\nscene.on('loaded', () => {\n const mapTheme = new MapTheme();\n scene.addControl(mapTheme);\n});\n",title:{zh:"MapTheme 地图样式切换",en:"MapTheme"},filename:"maptheme.ts",isNew:!1}],icon:"",id:"control",title:{en:"Controls",zh:"控件"},childrenKey:"demos",order:0},{demos:[{id:"popup",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*cNMlSLwgjboAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GaodeMap, Popup } from '@antv/l7';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n logoVisible: false,\n});\nscene.on('loaded', () => {\n const popup = new Popup({\n title: '自定义标题',\n html: '

Popup 示例的自定义内容

',\n lngLat: {\n lng: 120.154672,\n lat: 30.241095,\n },\n });\n\n scene.addPopup(popup);\n});\n",title:{zh:"Popup 基础气泡",en:"Popup"},filename:"popup.ts",isNew:!1},{id:"popup2",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*cNMlSLwgjboAAAAAAAAAAAAAARQnAQ",source:"// @ts-ignore\nimport { PointLayer, Scene, Popup } from '@antv/l7';\n// @ts-ignore\nimport { GaodeMap } from '@antv/l7-maps';\n\nasync function initMap() {\n const response = await fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/893d1d5f-11d9-45f3-8322-ee9140d288ae.json',\n );\n const scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [121.4, 31.258134],\n zoom: 12,\n pitch: 0,\n style: 'normal',\n }),\n });\n scene.addImage(\n '00',\n 'https://gw.alipayobjects.com/mdn/rms_fcd5b3/afts/img/A*g8cUQ7pPT9YAAAAAAAAAAAAAARQnAQ',\n );\n scene.addImage(\n '01',\n 'https://gw.alipayobjects.com/mdn/rms_fcd5b3/afts/img/A*LTcXTLBM7kYAAAAAAAAAAAAAARQnAQ',\n );\n scene.addImage(\n '02',\n 'https://gw.alipayobjects.com/zos/bmw-prod/904d047a-16a5-461b-a921-98fa537fc04a.svg',\n );\n const data = await response.json();\n const newData = data.map((item: any) => {\n item.type = ['00', '01', '02'][Math.floor(Math.random() * 3)];\n return item;\n });\n const imageLayer = new PointLayer({\n })\n .source(newData, {\n parser: {\n type: 'json',\n x: 'longitude',\n y: 'latitude',\n },\n })\n .shape('type', (v: any) => {\n return v;\n })\n .active(false)\n .size(20);\n scene.addLayer(imageLayer);\n imageLayer.on('mousedown', (e) => {\n console.log('mousedown', e);\n });\n const popup = new Popup({\n });\n\n scene.addPopup(popup);\n imageLayer.on('click', (e) => {\n console.log(e)\n const { lng, lat } = e.lngLat\n\n popup.setOptions({\n title: e.feature.name,\n html: e.feature.name,\n lngLat: {\n lng,\n lat,\n },\n });\n\n });\n}\n\ninitMap();",title:{zh:"图层点击 气泡",en:"Popup"},filename:"popup2.ts",isNew:!1},{id:"layerpopup",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*HbyzRqv6JZcAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GaodeMap, LayerPopup, PointLayer } from '@antv/l7';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n logoVisible: false,\n});\nscene.on('loaded', () => {\n const pointLayer = new PointLayer({});\n pointLayer\n .source(\n [\n {\n lng: 120.132235,\n lat: 30.250868,\n value: 34.71314604052238,\n name: '坐标点1',\n },\n {\n lng: 120.156236,\n lat: 30.260268,\n value: 96.807880210153,\n name: '坐标点2',\n },\n {\n lng: 120.163014,\n lat: 30.251297,\n value: 29.615472482876815,\n name: '坐标点3',\n },\n {\n lng: 120.15394,\n lat: 30.231489,\n value: 49.90316258911784,\n name: '坐标点4',\n },\n {\n lng: 120.154596,\n lat: 30.24065,\n value: 45.788587061188466,\n name: '坐标点5',\n },\n {\n lng: 120.150223,\n lat: 30.235078,\n value: 29.741111717098544,\n name: '坐标点6',\n },\n {\n lng: 120.143992,\n lat: 30.229411,\n value: 40.241555782182935,\n name: '坐标点7',\n },\n {\n lng: 120.136995,\n lat: 30.237439,\n value: 86.5369792415296,\n name: '坐标点8',\n },\n ],\n {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat',\n },\n },\n )\n .color('value', ['#FFCCC6', '#CF1421'])\n .size(10)\n .shape('circle');\n scene.addLayer(pointLayer);\n const layerPopup = new LayerPopup({\n items: [\n {\n layer: pointLayer,\n fields: [\n {\n field: 'name',\n formatField: () => '名称',\n },\n {\n field: 'value',\n formatField: () => '权值',\n formatValue: (val) => val.toFixed(2),\n },\n 'lng',\n 'lat',\n ],\n },\n ],\n });\n\n scene.addPopup(layerPopup);\n});\n",title:{zh:"LayerPopup 图层气泡",en:"LayerPopup"},filename:"layerpopup.ts",isNew:!1},{id:"customContent",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*orwHQKugIdIAAAAAAAAAAAAADmJ7AQ/original",source:"import * as G2 from '@antv/g2';\nimport { GaodeMap, LayerPopup, PointLayer, Scene } from '@antv/l7';\n\nconst data: any[] = [\n {\n lng: 120.132235,\n lat: 30.250868,\n value: 34.71314604052238,\n name: '坐标点1',\n },\n {\n lng: 120.156236,\n lat: 30.260268,\n value: 96.807880210153,\n name: '坐标点2',\n },\n {\n lng: 120.163014,\n lat: 30.251297,\n value: 29.615472482876815,\n name: '坐标点3',\n },\n {\n lng: 120.15394,\n lat: 30.231489,\n value: 49.90316258911784,\n name: '坐标点4',\n },\n {\n lng: 120.154596,\n lat: 30.24065,\n value: 45.788587061188466,\n name: '坐标点5',\n },\n {\n lng: 120.150223,\n lat: 30.235078,\n value: 29.741111717098544,\n name: '坐标点6',\n },\n {\n lng: 120.143992,\n lat: 30.229411,\n value: 40.241555782182935,\n name: '坐标点7',\n },\n {\n lng: 120.136995,\n lat: 30.237439,\n value: 86.5369792415296,\n name: '坐标点8',\n },\n];\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 0,\n style: 'normal',\n center: [120.154672, 30.241095],\n zoom: 12,\n }),\n logoVisible: false,\n});\nscene.on('loaded', () => {\n const pointLayer = new PointLayer({});\n pointLayer\n .source(data, {\n parser: {\n type: 'json',\n x: 'lng',\n y: 'lat',\n },\n })\n .color('value', ['#FFCCC6', '#CF1421'])\n .size(10)\n .shape('circle');\n scene.addLayer(pointLayer);\n\n const div = document.createElement('div');\n const chart = new G2.Chart({\n container: div,\n autoFit: true,\n width: 200,\n height: 200,\n });\n // 新建一个 view 用来单独渲染Annotation\n chart.coordinate('theta', {\n radius: 0.75,\n innerRadius: 0.5,\n });\n\n chart.scale('percent', {\n formatter: (val) => {\n val = val * 100 + '%';\n return val;\n },\n });\n\n chart.tooltip(false);\n\n // 声明需要进行自定义图例字段: 'item'\n chart.legend(false);\n\n chart\n .interval()\n .adjust('stack')\n .position('percent')\n .color('item', ['#5B8FF9', '#797979'])\n .style({\n fillOpacity: 1,\n });\n\n const layerPopup = new LayerPopup({\n items: [\n {\n layer: pointLayer,\n customContent: (e) => {\n const otherValue = 100 - e.value;\n chart.data([\n { item: '值', count: e.value, percent: e.value / 100 },\n { item: '', count: otherValue, percent: otherValue / 100 },\n ]);\n chart.render();\n return div;\n },\n },\n ],\n });\n\n scene.addPopup(layerPopup);\n});\n",title:{zh:"图层气泡 自定义内容",en:"LayerPopup"},filename:"customContent.ts",isNew:!1}],icon:"",id:"popup",title:{en:"Popup",zh:"信息框"},childrenKey:"demos",order:1},{demos:[{id:"defaultmarker",screenshot:"https://mdn.alipayobjects.com/afts/img/A*Lwx2RoaXjmwAAAAAAAAAAAAADrd2AQ/20230207225205.jpg",source:"import { Scene, Marker } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 105.790327, 36.495636 ],\n zoom: 4\n })\n});\nscene.on('loaded', () => {\n addMarkers();\n scene.render();\n});\nfunction addMarkers() {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/67f47049-8787-45fc-acfe-e19924afe032.json'\n )\n .then(res => res.json())\n .then(nodes => {\n for (let i = 0; i < nodes.length; i++) {\n if (nodes[i].g !== '1' || nodes[i].v === '') {\n continue;\n }\n \n const marker = new Marker().setLnglat({ lng: nodes[i].x * 1, lat: nodes[i].y });\n scene.addMarker(marker);\n }\n });\n}\n\n",title:"默认 Marker",filename:"defaultmarker.js",isNew:!1},{id:"markerlayer",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*zb-0TrdH8wUAAAAAAAAAAAAAARQnAQ",source:"import { Scene, Marker, MarkerLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 105.790327, 36.495636 ],\n zoom: 4\n })\n});\nscene.on('loaded', () => {\n addMarkers();\n scene.render();\n});\nfunction addMarkers() {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/67f47049-8787-45fc-acfe-e19924afe032.json'\n )\n .then(res => res.json())\n .then(nodes => {\n const markerLayer = new MarkerLayer();\n for (let i = 0; i < nodes.length; i++) {\n if (nodes[i].g !== '1' || nodes[i].v === '') {\n continue;\n }\n const el = document.createElement('label');\n el.className = 'labelclass';\n el.textContent = nodes[i].v + '℃';\n el.style.background = getColor(nodes[i].v);\n el.style.borderColor = getColor(nodes[i].v);\n const marker = new Marker({\n element: el\n }).setLnglat({ lng: nodes[i].x * 1, lat: nodes[i].y });\n markerLayer.addMarker(marker);\n }\n scene.addMarkerLayer(markerLayer);\n });\n}\n\nfunction getColor(v) {\n const colors = [ '#ffffe5', '#f7fcb9', '#d9f0a3', '#addd8e', '#78c679', '#41ab5d', '#238443', '#005a32' ];\n return v > 50\n ? colors[7]\n : v > 40\n ? colors[6]\n : v > 30\n ? colors[5]\n : v > 20\n ? colors[4]\n : v > 10\n ? colors[3]\n : v > 5\n ? colors[2]\n : v > 0\n ? colors[1]\n : colors[0];\n}\n",title:"MarkerLayer 统一管理Marker",filename:"markerlayer.js",isNew:!1},{id:"clustermarker",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*h6_kQKiM2cwAAAAAAAAAAAAAARQnAQ",source:"import { Scene, Marker, MarkerLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 105.790327, 30 ],\n zoom: 2\n })\n});\nscene.on('loaded', () => {\n addMarkers();\n scene.render();\n});\nfunction addMarkers() {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/d3564b06-670f-46ea-8edb-842f7010a7c6.json'\n )\n .then(res => res.json())\n .then(nodes => {\n const markerLayer = new MarkerLayer({\n cluster: true\n });\n for (let i = 0; i < nodes.features.length; i++) {\n const { coordinates } = nodes.features[i].geometry;\n const marker = new Marker().setLnglat({\n lng: coordinates[0],\n lat: coordinates[1]\n });\n markerLayer.addMarker(marker);\n }\n scene.addMarkerLayer(markerLayer);\n });\n}\n",title:"MarkerLayer 聚合Marker",filename:"clustermarker.js",isNew:!1},{id:"marker",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*m0rwQZBpZ6MAAAAAAAAAAAAAARQnAQ",source:"import { Scene, Marker } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 105.790327, 36.495636 ],\n zoom: 4\n })\n});\nscene.on('loaded', () => {\n addMarkers();\n scene.render();\n});\nfunction addMarkers() {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/67f47049-8787-45fc-acfe-e19924afe032.json'\n )\n .then(res => res.json())\n .then(nodes => {\n for (let i = 0; i < nodes.length; i++) {\n if (nodes[i].g !== '1' || nodes[i].v === '') {\n continue;\n }\n const el = document.createElement('label');\n el.className = 'labelclass';\n el.textContent = nodes[i].v + '℃';\n el.style.background = getColor(nodes[i].v);\n el.style.borderColor = getColor(nodes[i].v);\n const marker = new Marker({\n element: el\n }).setLnglat({ lng: nodes[i].x * 1, lat: nodes[i].y });\n scene.addMarker(marker);\n }\n });\n}\n\nfunction getColor(v) {\n return v > 50\n ? '#800026'\n : v > 40\n ? '#BD0026'\n : v > 30\n ? '#E31A1C'\n : v > 20\n ? '#FC4E2A'\n : v > 10\n ? '#FD8D3C'\n : v > 5\n ? '#FEB24C'\n : v > 0\n ? '#FED976'\n : '#FFEDA0';\n}\n",title:"温度",filename:"marker.js",isNew:!1}],icon:"",id:"marker",title:{en:"Marker",zh:"Marker 标注"},childrenKey:"demos",order:2}],childrenKey:"examples"},{id:"draw",title:{zh:"绘制组件",en:"L7Draw"},icon:"map",examples:[{demos:[{id:"draw_point",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*9UalSKnKqOAAAAAAAAAAAAAAARQnAQ",source:"import { Scene } from '@antv/l7';\nimport { DrawEvent, DrawPoint } from '@antv/l7-draw';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [120.211944, 30.288946],\n zoom: 7.05,\n }),\n});\nscene.on('loaded', () => {\n const drawPoint = new DrawPoint(scene, {});\n drawPoint.enable();\n\n drawPoint.on(DrawEvent.Change, (allFeatures) => {\n console.log(allFeatures);\n });\n\n setInterval(() => {\n console.log(scene.getZoom(), scene.getCenter());\n }, 2000);\n});\n",title:"绘制点",filename:"draw_point.js",isNew:!1},{id:"draw_line",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*y68yToJoy34AAAAAAAAAAAAAARQnAQ",source:"import { Scene } from '@antv/l7';\nimport { DrawEvent, DrawLine } from '@antv/l7-draw';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [120.211944, 30.288946],\n zoom: 7.05,\n }),\n});\nscene.on('loaded', () => {\n const drawLine = new DrawLine(scene, {\n distanceOptions: {},\n });\n drawLine.enable();\n\n drawLine.on(DrawEvent.Change, (allFeatures) => {\n console.log(allFeatures);\n });\n});\n",title:"绘制线",filename:"draw_line.js",isNew:!1},{id:"draw_polygon",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*YmIPSK2bY0oAAAAAAAAAAAAAARQnAQ",source:"import { Scene } from '@antv/l7';\nimport { DrawEvent, DrawPolygon } from '@antv/l7-draw';\nimport { GaodeMap } from '@antv/l7-maps';\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [120.211944, 30.288946],\n zoom: 7.05,\n }),\n});\nscene.on('loaded', () => {\n const drawPolygon = new DrawPolygon(scene, {\n areaOptions: {},\n });\n drawPolygon.enable();\n\n drawPolygon.on(DrawEvent.Change, (allFeatures) => {\n console.log(allFeatures);\n });\n});\n",title:"绘制面",filename:"draw_polygon.js",isNew:!1},{id:"draw_rect",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*X_IGRrjsPCoAAAAAAAAAAAAAARQnAQ",source:"import { Scene } from '@antv/l7';\nimport { DrawEvent, DrawRect } from '@antv/l7-draw';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [120.211944, 30.288946],\n zoom: 7.05,\n }),\n});\nscene.on('loaded', () => {\n const drawRect = new DrawRect(scene, {});\n drawRect.enable();\n\n drawRect.on(DrawEvent.Change, (allFeatures) => {\n console.log(allFeatures);\n });\n});\n",title:"绘制矩形",filename:"draw_rect.js",isNew:!1},{id:"draw_circle",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*bnaxRLpYvdwAAAAAAAAAAAAAARQnAQ",source:"import { Scene } from '@antv/l7';\nimport { DrawCircle, DrawEvent } from '@antv/l7-draw';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [120.211944, 30.288946],\n zoom: 7.05,\n }),\n});\nscene.on('loaded', () => {\n const drawCircle = new DrawCircle(scene, {});\n drawCircle.enable();\n\n drawCircle.on(DrawEvent.Change, (allFeatures) => {\n console.log(allFeatures);\n });\n});\n",title:"绘制圆",filename:"draw_circle.js",isNew:!1}],icon:"",id:"basic",title:{en:"L7Draw",zh:"地图绘制"},childrenKey:"demos",order:3},{demos:[{id:"amap",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*-5KDT6d7pLcAAAAAAAAAAAAAARQnAQ",source:"// https://gw.alipayobjects.com/zos/antvdemo/assets/2019_clip/ndvi_201905.tif\nimport { Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport { ControlEvent, DrawControl } from '@antv/l7-draw';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [116.1608, 40.1119],\n zoom: 15,\n }),\n});\nscene.on('loaded', () => {\n const tileLayer = new AMap.TileLayer.Satellite();\n tileLayer.setMap(scene.map);\n\n const drawControl = new DrawControl(scene, {});\n scene.addControl(drawControl);\n drawControl.on(ControlEvent.DrawChange, (changeType) => {\n console.log(changeType);\n });\n});\n",title:"高德地图绘制",filename:"amap.js",isNew:!1}],icon:"",id:"control",title:{en:"Draw Control",zh:"绘制控件"},childrenKey:"demos",order:3}],childrenKey:"examples"},{id:"wind",title:{zh:"风场图层",en:"Wind Layer"},icon:"raster",examples:[{demos:[{id:"wind",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*ADr-SIxhM9AAAAAAAAAAAAAAARQnAQ",source:"import { Scene, WindLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 90, 32.24997445586331 ],\n style: 'dark',\n zoom: 2\n })\n});\n\nscene.on('loaded', () => {\n const layer = new WindLayer({});\n layer\n .source(\n 'https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*wcU8S5xMEDYAAAAAAAAAAAAAARQnAQ',\n {\n parser: {\n type: 'image',\n extent: [ -180, -85, 180, 85 ]\n }\n }\n )\n .animate(true)\n .style({\n uMin: -21.32,\n uMax: 26.8,\n vMin: -21.57,\n vMax: 21.42,\n numParticles: 35535,\n fadeOpacity: 0.996,\n sizeScale: 1.2,\n rampColors: {\n 0.0: '#3288bd',\n 0.1: '#66c2a5',\n 0.2: '#abdda4',\n 0.3: '#e6f598',\n 0.4: '#fee08b',\n 0.5: '#fdae61',\n 0.6: '#f46d43',\n 1.0: '#d53e4f'\n }\n });\n scene.addLayer(layer);\n});\n",title:"风场图层",filename:"wind.js",isNew:!1}],icon:"",id:"basic",title:{en:"Wind Layer",zh:"风场图层"},childrenKey:"demos",order:7}],childrenKey:"examples"},{id:"earth",title:{zh:"地球模式",en:"Earth Mode"},icon:"map",examples:[{demos:[{id:"flyline",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*hak1RaMjp1MAAAAAAAAAAAAAARQnAQ",source:"import { Scene, EarthLayer, LineLayer } from '@antv/l7';\nimport { Earth } from '@antv/l7-maps';\nconst scene = new Scene({\n id: 'map',\n map: new Earth({})\n});\n\n// 地球模式下背景色默认为 #000 通过 setBgColor 方法我们可以设置可视化层的背景色\nscene.setBgColor('#333');\n\nconst earthlayer = new EarthLayer()\n .source(\n 'https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*3-3NSpqRqUoAAAAAAAAAAAAAARQnAQ',\n {\n parser: {\n type: 'image'\n }\n }\n )\n .color('#2E8AE6')\n .shape('fill')\n .style({\n globalOptions: {\n ambientRatio: 0.6, // 环境光\n diffuseRatio: 0.4, // 漫反射\n specularRatio: 0.1 // 高光反射\n }\n })\n .animate(true);\n\nconst atomLayer = new EarthLayer()\n .color('#2E8AE6')\n .shape('atomSphere');\n\nconst bloomLayer = new EarthLayer().color('#fff').shape('bloomSphere')\n .style({\n opacity: 0.7\n });\n\nscene.on('loaded', () => {\n scene.addLayer(earthlayer);\n\n scene.addLayer(atomLayer);\n scene.addLayer(bloomLayer);\n\n fetch('https://gw.alipayobjects.com/os/bmw-prod/20a69b46-3d6d-4ab5-b8b5-150b6aa52c88.json')\n .then(res => res.json())\n .then(flydata => {\n const flyLine = new LineLayer({ blend: 'normal' })\n .source(flydata, {\n parser: {\n type: 'json',\n coordinates: 'coord'\n }\n })\n .color('#b97feb')\n .shape('arc3d')\n .size(0.5)\n .active(true)\n .animate({\n interval: 2,\n trailLength: 2,\n duration: 1\n })\n .style({\n segmentNumber: 60,\n globalArcHeight: 20\n });\n scene.addLayer(flyLine);\n });\n\n earthlayer.setEarthTime(4.0);\n});\n",title:"飞线",filename:"flyline.js",isNew:!1}],icon:"",id:"arc3d",title:{en:"flyline",zh:"飞线"},childrenKey:"demos",order:0}],childrenKey:"examples"},{id:"geometry",title:{zh:"几何体图层",en:"Geometry Layer"},icon:"raster",examples:[{demos:[{id:"plane",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*BMVzSrx9TpEAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GeometryLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 120.1025, 30.2594 ],\n style: 'dark',\n zoom: 10\n })\n});\n\nscene.on('loaded', () => {\n const layer = new GeometryLayer()\n .shape('plane')\n .style({\n opacity: 0.8,\n width: 0.074,\n height: 0.061,\n center: [ 120.1025, 30.2594 ]\n })\n .active(true)\n .color('#ff0');\n scene.addLayer(layer);\n});\n",title:"平面图层",filename:"plane.js",isNew:!1},{id:"terrain",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*DIb4TaijKIAAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GeometryLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 120.1025, 30.2594 ],\n style: 'dark',\n pitch: 65,\n rotation: 180,\n zoom: 14\n })\n});\nlet currentZoom = 14,\n currentModelData = '100x100';\n\nscene.on('loaded', () => {\n const layer = new GeometryLayer()\n .shape('plane')\n .style({\n width: 0.074,\n height: 0.061,\n center: [ 120.1025, 30.2594 ],\n widthSegments: 100,\n heightSegments: 100,\n terrainClipHeight: 1,\n mapTexture:\n 'https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*gA0NRbuOF5cAAAAAAAAAAAAAARQnAQ',\n terrainTexture:\n 'https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*eYFaRYlnnOUAAAAAAAAAAAAAARQnAQ',\n rgb2height: (r, g, b) => {\n let h =\n -10000.0 +\n (r * 255.0 * 256.0 * 256.0 + g * 255.0 * 256.0 + b * 255.0) * 0.1;\n h = h / 20 - 127600;\n h = Math.max(0, h);\n return h;\n }\n });\n scene.addLayer(layer);\n\n let modelData10,\n modelData20 = null,\n modelData100;\n\n layer.on('terrainImageLoaded', () => {\n\n modelData10 = layer.createModelData([], {\n widthSegments: 10,\n heightSegments: 10\n });\n\n modelData20 = layer.createModelData([], {\n widthSegments: 20,\n heightSegments: 20\n });\n\n modelData100 = layer.createModelData([], {\n widthSegments: 100,\n heightSegments: 100\n });\n });\n\n\n scene.on('zoom', ({ value }) => {\n const zoom = Math.floor(value);\n if (currentZoom !== zoom) {\n if (zoom > 13) {\n if (currentModelData !== '100x100') {\n layer.updateModelData(modelData100);\n currentModelData = '100x100';\n }\n } else if (zoom > 12) {\n if (currentModelData !== '20x20') {\n layer.updateModelData(modelData20);\n currentModelData = '20x20';\n }\n } else {\n if (currentModelData !== '10x10') {\n layer.updateModelData(modelData10);\n currentModelData = '10x10';\n }\n }\n currentZoom = zoom;\n }\n return '';\n });\n});\n",title:"自定义 3D 地形(LOD)",filename:"terrain.js",isNew:!1},{id:"snow",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*jJQtRqa6_f8AAAAAAAAAAAAAARQnAQ",source:"import { Scene, GeometryLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 40,\n style: 'dark',\n center: [ 120, 30 ],\n zoom: 6\n })\n});\n\nscene.on('loaded', () => {\n const layer = new GeometryLayer()\n .shape('sprite')\n .size(10)\n .style({\n mapTexture:\n 'https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*zLQwQKBSagYAAAAAAAAAAAAAARQnAQ', // snow\n center: [ 120, 30 ],\n spriteCount: 60,\n spriteRadius: 10,\n spriteTop: 2500000,\n });\n scene.addLayer(layer);\n});\n",title:"雪花粒子",filename:"snow.js",isNew:!1},{id:"rain",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*rmcvQ5iwyZAAAAAAAAAAAAAAARQnAQ",source:"import { Scene, GeometryLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n pitch: 90,\n style: 'dark',\n center: [ 120, 30 ],\n zoom: 6\n })\n});\n\nscene.on('loaded', () => {\n const layer = new GeometryLayer()\n .shape('sprite')\n .size(10)\n .style({\n opacity: 0.3,\n mapTexture: 'https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*w2SFSZJp4nIAAAAAAAAAAAAAARQnAQ', // rain\n center: [ 120, 30 ],\n spriteCount: 120,\n spriteRadius: 10,\n spriteTop: 2500000,\n spriteUpdate: 20000,\n spriteScale: 0.6\n });\n scene.addLayer(layer);\n});\n",title:"雨滴粒子",filename:"rain.js",isNew:!1}],icon:"",id:"geometry",title:{en:"Geometry Layer",zh:"几何体图层"},childrenKey:"demos",order:7}],childrenKey:"examples"},{id:"engine",title:{zh:"第三方引擎",en:"other engine"},icon:"map",examples:[{demos:[{id:"amap_ant",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*mjmxT7DaVQgAAAAAAAAAAAAAARQnAQ",source:"import { Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport { ThreeLayer, ThreeRender } from '@antv/l7-three';\nimport * as THREE from 'three';\nimport { GLTFLoader } from 'three/examples/jsm/loaders/GLTFLoader';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 111.4453125, 32.84267363195431 ],\n pitch: 45,\n rotation: 30,\n zoom: 12\n })\n});\n\nscene.on('loaded', () => {\n scene.registerRenderService(ThreeRender);\n\n const threeJSLayer = new ThreeLayer({\n enableMultiPassRenderer: false,\n onAddMeshes: (threeScene, layer) => {\n threeScene.add(new THREE.AmbientLight(0xffffff));\n const sunlight = new THREE.DirectionalLight(0xffffff, 0.25);\n sunlight.position.set(0, 80000000, 100000000);\n sunlight.matrixWorldNeedsUpdate = true;\n threeScene.add(sunlight);\n\n const center = scene.getCenter();\n\n const cubeGeometry = new THREE.BoxBufferGeometry(10000, 10000, 10000);\n const cubeMaterial = new THREE.MeshNormalMaterial({ side: THREE.DoubleSide });\n const cube = new THREE.Mesh(cubeGeometry, cubeMaterial);\n layer.setObjectLngLat(cube, [ center.lng + 0.05, center.lat ], 0);\n threeScene.add(cube);\n\n // 使用 Three.js glTFLoader 加载模型\n const loader = new GLTFLoader();\n loader.load(\n 'https://gw.alipayobjects.com/os/bmw-prod/3ca0a546-92d8-4ba0-a89c-017c218d5bea.gltf',\n gltf => {\n const gltfScene = gltf.scene;\n setDouble(gltfScene);\n layer.adjustMeshToMap(gltfScene);\n // gltfScene.scale.set(1000, 1000, 1000)\n layer.setMeshScale(gltfScene, 1000, 1000, 1000);\n\n layer.setObjectLngLat(\n gltfScene,\n [ center.lng, center.lat ],\n 0\n );\n\n const animations = gltf.animations;\n if (animations && animations.length) {\n const mixer = new THREE.AnimationMixer(gltfScene);\n\n const animation = animations[2];\n\n const action = mixer.clipAction(animation);\n\n action.play();\n layer.addAnimateMixer(mixer);\n }\n // layer.setObjectLngLat(gltfScene, [center.lng + 0.05, center.lat] as ILngLat, 0)\n let t = 0;\n setInterval(() => {\n t += 0.01;\n layer.setObjectLngLat(\n gltfScene,\n [ center.lng, center.lat + Math.sin(t) * 0.1 ],\n 0\n );\n }, 16);\n\n // 向场景中添加模型\n threeScene.add(gltfScene);\n // 重绘图层\n layer.render();\n }\n );\n }\n }).animate(true);\n scene.addLayer(threeJSLayer);\n});\n\nfunction setDouble(object) {\n if (object.children && object.children.length && object.children.length > 0) {\n object.children.map(child => setDouble(child));\n } else if (object.material) {\n object.material.side = THREE.DoubleSide;\n }\n}\n\n",title:"高德地图",filename:"amap_ant.js",isNew:!1},{id:"space_click",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*ilK5R4SidkMAAAAAAAAAAAAAARQnAQ",source:"import { Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nimport { ThreeLayer, ThreeRender } from '@antv/l7-three';\nimport * as THREE from 'three';\nimport { GLTFLoader } from 'three/examples/jsm/loaders/GLTFLoader';\nimport { FBXLoader } from 'three/examples/jsm/loaders/FBXLoader';\nimport { animate, easeInOut } from 'popmotion';\nfunction changeValue(\n startValue,\n endValue,\n duration = 500,\n callback,\n complete\n) {\n if (typeof startValue === 'number') {\n animate({\n from: {\n v: startValue\n },\n to: {\n v: endValue\n },\n ease: easeInOut,\n duration,\n onUpdate: o => {\n callback(o.v);\n return '';\n },\n onComplete: () => {\n complete && complete();\n return '';\n }\n });\n } else {\n animate({\n from: {\n lng: startValue.lng,\n lat: startValue.lat,\n pitch: startValue.pitch,\n rotation: startValue.rotation,\n zoom: startValue.zoom\n },\n to: {\n lng: (endValue).lng,\n lat: (endValue).lat,\n pitch: (endValue).pitch,\n rotation: (endValue).rotation,\n zoom: (endValue).zoom\n },\n ease: easeInOut,\n duration,\n onUpdate: o => {\n callback(o);\n return '';\n },\n onComplete: () => {\n complete && complete();\n return '';\n }\n });\n }\n return '';\n}\n\nconst raycaster = new THREE.Raycaster();\nconst lng = 120.1;\nconst lat = 30.265;\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ lng, lat ],\n pitch: 70,\n rotation: 220,\n zoom: 16\n })\n});\n\nscene.on('loaded', () => {\n\n const mouse = new THREE.Vector2();\n let zspace,\n aspace,\n ASpaceTextMesh,\n ZSpaceTextMesh;\n\n scene.registerRenderService(ThreeRender);\n\n const center = scene.getCenter();\n\n const threeJSLayer = new ThreeLayer({\n enableMultiPassRenderer: false,\n // @ts-ignore\n onAddMeshes: (threeScene, layer) => {\n threeScene.add(new THREE.AmbientLight(0xffffff));\n const sunlight = new THREE.DirectionalLight(0xffffff, 0.25);\n sunlight.position.set(0, 80000000, 100000000);\n sunlight.matrixWorldNeedsUpdate = true;\n threeScene.add(sunlight);\n\n // map\n // https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*gA0NRbuOF5cAAAAAAAAAAAAAARQnAQ\n\n // height\n // https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*eYFaRYlnnOUAAAAAAAAAAAAAARQnAQ\n\n const image = new Image();\n image.crossOrigin = '';\n image.src =\n 'https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*eYFaRYlnnOUAAAAAAAAAAAAAARQnAQ';\n image.onload = () => {\n const canvas = document.createElement('canvas');\n canvas.width = image.width;\n canvas.height = image.height;\n const ctx = canvas.getContext('2d');\n ctx.drawImage(image, 0, 0, image.width, image.height);\n const heightData = ctx.getImageData(0, 0, image.width, image.height)\n .data;\n\n const s = 53000;\n\n const geometry = new THREE.PlaneGeometry(s, s, 255, 255);\n\n geometry.vertices.map((v, i) => {\n const r = heightData[i * 4];\n const g = heightData[i * 4 + 1];\n const b = heightData[i * 4 + 2];\n let h =\n -10000.0 +\n (r * 255.0 * 256.0 * 256.0 + g * 255.0 * 256.0 + b * 255.0) *\n 0.1;\n h = h / 20 - 127600;\n h = Math.max(0, h);\n\n v.z = h;\n return '';\n });\n const material = new THREE.MeshPhongMaterial({\n transparent: true,\n // opacity: 0.6,\n map: new THREE.TextureLoader().load(\n 'https://gw.alipayobjects.com/mdn/rms_23a451/afts/img/A*gA0NRbuOF5cAAAAAAAAAAAAAARQnAQ'\n ),\n side: THREE.DoubleSide\n });\n const plane = new THREE.Mesh(geometry, material);\n layer.setObjectLngLat(plane, [ 120.1008, 30.2573 ], 0);\n plane.position.z = 10;\n threeScene.add(plane);\n\n return '';\n };\n\n // 使用 Three.js glTFLoader 加载模型\n const loader = new GLTFLoader();\n loader.load(\n 'https://gw.alipayobjects.com/os/bmw-prod/3ca0a546-92d8-4ba0-a89c-017c218d5bea.gltf',\n gltf => {\n const antModel = gltf.scene;\n setDouble(antModel);\n // antModel.children[0].material.side = THREE.DoubleSide\n layer.adjustMeshToMap(antModel);\n layer.setMeshScale(antModel, 20, 20, 20);\n layer.setObjectLngLat(\n antModel,\n [ center.lng - 0.002, center.lat ],\n 0\n );\n\n const animations = gltf.animations;\n if (animations && animations.length) {\n const mixer = new THREE.AnimationMixer(antModel);\n const animation = animations[1];\n const action = mixer.clipAction(animation);\n action.play();\n layer.addAnimateMixer(mixer);\n }\n antModel.rotation.y = Math.PI;\n // 向场景中添加模型\n threeScene.add(antModel);\n // 重绘图层\n layer.render();\n return '';\n }\n );\n\n const v = `\n varying vec2 vUv;\n varying vec4 worldPosition;\n void main() {\n vUv = uv;\n worldPosition = modelMatrix * vec4(position, 1.0);\n gl_Position = projectionMatrix * modelViewMatrix * vec4(position, 1.0);\n }`;\n const f = `\n varying vec2 vUv;\n varying vec4 worldPosition;\n uniform vec3 color;\n void main() {\n gl_FragColor = vec4(color, fract(worldPosition.z / 50.0));\n }`;\n const shadermaterial = new THREE.ShaderMaterial({\n uniforms: {\n color: {\n value: new THREE.Vector3(0.21372549, 0.34705882, 0.56470588)\n }\n },\n vertexShader: v,\n fragmentShader: f,\n side: THREE.DoubleSide\n });\n\n const fbxLoaded = new FBXLoader();\n // load ZSpace\n fbxLoaded.load(\n 'https://gw.alipayobjects.com/os/bmw-prod/af1652c9-3c4f-4e73-ac4c-1f78fefbaf6a.fbx',\n gltf => {\n zspace = gltf;\n layer.adjustMeshToMap(zspace);\n // @ts-ignore\n zspace.children[0].material = shadermaterial;\n layer.setMeshScale(zspace, 10, 10, 10);\n\n layer.setObjectLngLat(zspace, [ 120.1015, 30.2661 ], 0);\n zspace.rotation.x = Math.PI * 2;\n zspace.rotation.z = -Math.PI * (-2 / 15);\n threeScene.add(zspace);\n\n return '';\n }\n );\n\n fbxLoaded.load(\n 'https://gw.alipayobjects.com/os/bmw-prod/11d6e4c1-bd5b-4dc1-bae5-ac51c14e9056.fbx',\n model => {\n aspace = model;\n layer.adjustMeshToMap(aspace);\n // @ts-ignore\n aspace.children[0].material = shadermaterial;\n\n layer.setMeshScale(aspace, 8, 8, 8);\n layer.setObjectLngLat(aspace, [ 120.099, 30.261 ], 0);\n aspace.rotation.x = Math.PI * 2;\n aspace.rotation.z = -Math.PI * (3 / 15);\n threeScene.add(aspace);\n\n return '';\n }\n );\n console.log(THREE.FontLoader)\n const textLoader = new THREE.FontLoader();\n textLoader.load(\n 'https://gw.alipayobjects.com/os/bmw-prod/0a3f46eb-294e-4d95-87f2-052c26ad4bf1.json',\n font => {\n const fontOptions = {\n size: 360, // 字号大小,一般为大写字母的高度\n height: 50, // 文字的厚度\n font, // 字体,默认是'helvetiker',需对应引用的字体文件\n bevelThickness: 10, // 倒角厚度\n bevelSize: 10, // 倒角宽度\n curveSegments: 30, // 弧线分段数,使得文字的曲线更加光滑\n bevelEnabled: true // 布尔值,是否使用倒角,意为在边缘处斜切\n };\n const aspaceGeo = new THREE.TextGeometry('ASpace', fontOptions);\n aspaceGeo.center();\n const zspaceGeo = new THREE.TextGeometry('ZSpace', fontOptions);\n zspaceGeo.center();\n\n const fontMat = new THREE.MeshPhongMaterial({\n color: 0xcccccc,\n shininess: 60,\n specular: 0xcccccc,\n side: THREE.DoubleSide\n });\n\n const testHeight = 900;\n\n ASpaceTextMesh = new THREE.Mesh(aspaceGeo, fontMat);\n ASpaceTextMesh.rotation.x = Math.PI / 2;\n ASpaceTextMesh.rotation.y = (-Math.PI * 3) / 4;\n layer.setObjectLngLat(\n ASpaceTextMesh,\n [ 120.099, 30.261 ],\n testHeight\n );\n threeScene.add(ASpaceTextMesh);\n\n ZSpaceTextMesh = new THREE.Mesh(zspaceGeo, fontMat);\n ZSpaceTextMesh.rotation.x = Math.PI / 2;\n ZSpaceTextMesh.rotation.y = (-Math.PI * 3) / 4;\n layer.setObjectLngLat(\n ZSpaceTextMesh,\n [ 120.103, 30.2661 ],\n testHeight\n );\n threeScene.add(ZSpaceTextMesh);\n\n getH(0, 200);\n function getH(h1, h2) {\n changeValue(\n h1,\n h2,\n 1000,\n h => {\n ASpaceTextMesh.position.z = testHeight + h;\n ZSpaceTextMesh.position.z = testHeight + h;\n return '';\n },\n () => {\n setTimeout(() => getH(h2, h1), 10);\n return '';\n }\n );\n }\n\n return '';\n }\n );\n }\n })\n .animate(true);\n scene.addLayer(threeJSLayer);\n // @ts-ignore\n let currentCamera = threeJSLayer.threeRenderService?.getRenderCamera();\n const currentView = {\n lng: center.lng,\n lat: center.lat,\n pitch: 70,\n rotation: 220,\n zoom: 16\n };\n\n scene.on('zoom', () => {\n const cen = scene.getCenter();\n currentView.lng = cen.lng;\n currentView.lat = cen.lat;\n currentView.pitch = scene.getPitch();\n currentView.zoom = scene.getZoom();\n return '';\n });\n\n scene.getMapService().on('mapchange', () => {\n // @ts-ignore\n currentCamera = threeJSLayer.getRenderCamera();\n currentView.pitch = scene.getPitch();\n return '';\n });\n\n const ASpaceView = {\n lng: 120.109509,\n lat: 30.251529,\n pitch: 83,\n rotation: 225,\n zoom: 15\n };\n const ZSpaceView = {\n lng: 120.112026,\n lat: 30.256881,\n pitch: 80,\n rotation: 220,\n zoom: 15\n };\n\n scene.on('click', ev => {\n // @ts-ignore\n const size = scene?.map?.getSize();\n mouse.x = (ev.pixel.x / size.width) * 2 - 1;\n mouse.y = -(ev.pixel.y / size.height) * 2 + 1;\n raycaster.setFromCamera(mouse, currentCamera);\n const intersects = raycaster.intersectObjects([ zspace, aspace ], true);\n if (intersects.length > 0) {\n const object = intersects[0].object;\n if (object.name === 'Z空间') {\n selectSpace(currentView, ZSpaceView, ZSpaceTextMesh);\n } else {\n selectSpace(currentView, ASpaceView, ASpaceTextMesh);\n }\n }\n return '';\n });\n\n function selectSpace(\n currentView,\n targetView,\n spaceText\n ) {\n if (spaceText) {\n changeValue(\n spaceText.rotation.y,\n spaceText.rotation.y + Math.PI * 2,\n 500,\n r => {\n spaceText.rotation.y = r;\n return '';\n }\n );\n }\n\n changeValue(currentView, targetView, 500, view => {\n scene.setCenter([ view.lng, view.lat ]);\n scene.setPitch(view.pitch);\n scene.setRotation(view.rotation);\n scene.setZoom(view.zoom);\n\n currentView.lng = view.lng;\n currentView.lat = view.lat;\n currentView.pitch = view.pitch;\n currentView.rotation = view.rotation;\n currentView.zoom = view.zoom;\n\n return '';\n });\n }\n return '';\n});\n\nfunction setDouble(object) {\n if (object.children && object.children.length && object.children.length > 0) {\n object.children.map(child => setDouble(child));\n } else if (object.material) {\n object.material.side = THREE.DoubleSide;\n }\n}\n\n",title:"点击建筑",filename:"space_click.js",isNew:!1}],icon:"",id:"three",title:{en:"Threejs",zh:"Threejs"},childrenKey:"demos",order:0}],childrenKey:"examples"},{id:"amap-plugin",title:{zh:"高德地图插件",en:"Amap Plugin"},icon:"map",examples:[{demos:[{id:"busstop",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*9MHrRZTvaiAAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer, LineLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 116.475, 39.985 ],\n zoom: 12.2,\n plugin: [ 'AMap.ToolBar', 'AMap.LineSearch' ]\n })\n});\n\nscene.addImage(\n 'road',\n 'https://gw.alipayobjects.com/zos/bmw-prod/ce83fc30-701f-415b-9750-4b146f4b3dd6.svg'\n);\nscene.addImage(\n 'start',\n 'https://gw.alipayobjects.com/zos/bmw-prod/1c301f25-9bb8-4e67-8d5c-41117c877caf.svg'\n);\nscene.addImage(\n 'end',\n 'https://gw.alipayobjects.com/zos/bmw-prod/f3db4998-e657-4c46-b5ab-205ddc12031f.svg'\n);\n\nscene.addImage(\n 'busStop',\n 'https://gw.alipayobjects.com/zos/bmw-prod/54345af2-1d01-43e1-9d11-cd9bb953202c.svg'\n);\n\nscene.on('loaded', () => {\n window.AMap.plugin([ 'AMap.ToolBar', 'AMap.LineSearch' ], () => {\n scene.map.addControl(new AMap.ToolBar());\n\n const linesearch = new AMap.LineSearch({\n pageIndex: 1, // 页码,默认值为1\n pageSize: 1, // 单页显示结果条数,默认值为20,最大值为50\n city: '北京', // 限定查询城市,可以是城市名(中文/中文全拼)、城市编码,默认值为『全国』\n extensions: 'all' // 是否返回公交线路详细信息,默认值为『base』\n });\n\n // 执行公交路线关键字查询\n linesearch.search('536', function(status, result) {\n // 打印状态信息status和结果信息result\n\n const { path, via_stops } = result.lineInfo[0];\n const startPoint = [ path[0] ];\n const endpoint = [ path[path.length - 1] ];\n const budStopsData = via_stops.map(stop => ({\n lng: stop.location.lng,\n lat: stop.location.lat,\n name: stop.name\n }));\n const data = [\n {\n id: '1',\n coord: path.map(p => [ p.lng, p.lat ])\n }\n ];\n\n const busLine = new LineLayer({ blend: 'normal' })\n .source(data, {\n parser: {\n type: 'json',\n coordinates: 'coord'\n }\n })\n .size(5)\n .shape('line')\n .color('rgb(99, 166, 242)')\n .texture('road')\n .animate({\n interval: 1, // 间隔\n duration: 1, // 持续时间,延时\n trailLength: 2 // 流线长度\n })\n .style({\n lineTexture: true,\n iconStep: 25\n });\n\n scene.addLayer(busLine);\n\n const startPointLayer = new PointLayer({ zIndex: 1 })\n .source(startPoint, {\n parser: {\n x: 'lng',\n y: 'lat',\n type: 'json'\n }\n })\n .shape('start')\n .size(20)\n .style({\n offsets: [ 0, 25 ]\n });\n scene.addLayer(startPointLayer);\n\n const endPointLayer = new PointLayer({ zIndex: 1 })\n .source(endpoint, {\n parser: {\n x: 'lng',\n y: 'lat',\n type: 'json'\n }\n })\n .shape('end')\n .size(25)\n .style({\n offsets: [ 0, 25 ]\n });\n scene.addLayer(endPointLayer);\n\n const busStops = new PointLayer()\n .source(budStopsData, {\n parser: {\n x: 'lng',\n y: 'lat',\n type: 'json'\n }\n })\n .shape('busStop')\n .size(13)\n .style({\n offsets: [ 20, 0 ]\n });\n scene.addLayer(busStops);\n\n const busStopsName = new PointLayer()\n .source(budStopsData, {\n parser: {\n x: 'lng',\n y: 'lat',\n type: 'json'\n }\n })\n .shape('name', 'text')\n .size(12)\n .color('#000')\n .style({\n textAnchor: 'left',\n textOffset: [ 80, 0 ],\n stroke: '#fff',\n strokeWidth: 1\n });\n scene.addLayer(busStopsName);\n });\n });\n});\n",title:"公交线路插件",filename:"busstop.js",isNew:!1},{id:"xyztile",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*ydN_QpzVraQAAAAAAAAAAAAAARQnAQ",source:"import { Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 105, 30 ],\n zoom: 2\n })\n});\n\nscene.on('loaded', () => {\n const xyzTileLayer = new window.AMap.TileLayer({\n getTileUrl:\n 'https://wprd0{1,2,3,4}.is.autonavi.com/appmaptile?x=[x]&y=[y]&z=[z]&size=1&scl=1&style=8<ype=11',\n zIndex: 100\n });\n scene.getMapService().map.add(xyzTileLayer);\n});\n",title:"xyz瓦片地图",filename:"xyztile.js",isNew:!1},{id:"satellite",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*bYbdT6N6IGwAAAAAAAAAAAAAARQnAQ",source:"import { Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n center: [ 105, 30 ],\n zoom: 2\n })\n});\n\n\nscene.on('loaded', () => {\n scene.getMapService().map.add(new window.AMap.TileLayer.Satellite());\n});\n",title:"卫星地图",filename:"satellite.js",isNew:!1}],icon:"",id:"bus",title:{en:"amapPlugin",zh:"高德插件"},childrenKey:"demos",order:0}],childrenKey:"examples"},{id:"choropleth",title:{zh:"行政区划",en:"Choropleth"},icon:"map",examples:[{demos:[{id:"zhejiang-province",screenshot:"https://gw.alipayobjects.com/zos/antfincdn/tX2zfzui76/821b3d1d-421c-4f09-a44e-53422db302f6.png",source:"import { GaodeMap, Scene } from '@antv/l7';\nimport { Choropleth } from '@antv/l7plot';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'blank',\n center: [120.19382669582967, 30.258134],\n zoom: 3,\n }),\n});\n\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/alisis/geo-data-v0.1.1/administrative-data/area-list.json',\n )\n .then((response) => response.json())\n .then((list) => {\n const data = list\n .filter(({ level, parent }) => level === 'city' && parent === 330000)\n .map((item) => ({ ...item, value: Math.random() * 5000 }));\n\n const choropleth = new Choropleth({\n source: {\n data,\n joinBy: {\n sourceField: 'adcode',\n geoField: 'adcode',\n },\n },\n viewLevel: {\n level: 'province',\n adcode: 330000,\n },\n autoFit: true,\n color: {\n field: 'value',\n value: ['#B8E1FF', '#7DAAFF', '#3D76DD', '#0047A5', '#001D70'],\n scale: { type: 'quantize' },\n },\n style: {\n opacity: 1,\n stroke: '#ccc',\n lineWidth: 0.6,\n lineOpacity: 1,\n },\n label: {\n visible: true,\n field: 'name',\n style: {\n fill: '#000',\n opacity: 0.8,\n fontSize: 10,\n stroke: '#fff',\n strokeWidth: 1.5,\n textAllowOverlap: false,\n padding: [5, 5],\n },\n },\n state: {\n active: { stroke: 'black', lineWidth: 1 },\n },\n tooltip: {\n items: ['name', 'adcode', 'value'],\n },\n zoom: {\n position: 'bottomright',\n },\n legend: {\n position: 'bottomleft',\n },\n });\n\n choropleth.addToScene(scene);\n });\n});\n",title:{zh:"浙江省地图",en:"Zhejiang Province Map"},filename:"zhejiang-province.ts",isNew:!1},{id:"zhejiang-province-district",screenshot:"https://gw.alipayobjects.com/zos/antfincdn/YQU0%24nl0gh/c9a9a70d-8abc-42f6-8795-856646346326.png",source:"import { GaodeMap, Scene } from '@antv/l7';\nimport { Choropleth } from '@antv/l7plot';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'blank',\n center: [120.19382669582967, 30.258134],\n zoom: 3,\n }),\n});\n\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/alisis/geo-data-v0.1.1/administrative-data/area-list.json',\n )\n .then((response) => response.json())\n .then((list) => {\n const data = list\n .filter(({ level }) => level === 'district')\n .map((item) => ({ ...item, value: Math.random() * 5000 }));\n\n const choropleth = new Choropleth({\n source: {\n data,\n joinBy: {\n sourceField: 'adcode',\n geoField: 'adcode',\n },\n },\n viewLevel: {\n level: 'province',\n adcode: 330000,\n granularity: 'district',\n },\n autoFit: true,\n color: {\n field: 'value',\n value: ['#B8E1FF', '#7DAAFF', '#3D76DD', '#0047A5', '#001D70'],\n scale: { type: 'quantize' },\n },\n style: {\n opacity: 1,\n stroke: '#ccc',\n lineWidth: 0.6,\n lineOpacity: 1,\n },\n label: {\n visible: true,\n field: 'name',\n style: {\n fill: '#000',\n opacity: 0.8,\n fontSize: 10,\n stroke: '#fff',\n strokeWidth: 1.5,\n textAllowOverlap: false,\n padding: [5, 5],\n },\n },\n state: {\n active: { stroke: 'black', lineWidth: 1 },\n },\n tooltip: {\n items: ['name', 'adcode', 'value'],\n },\n zoom: {\n position: 'bottomright',\n },\n legend: {\n position: 'bottomleft',\n },\n });\n\n choropleth.addToScene(scene);\n });\n});\n",title:{zh:"浙江省县级地图",en:"Zhejiang District Map"},filename:"zhejiang-province-district.ts",isNew:!1},{id:"hangzhou-city",screenshot:"https://gw.alipayobjects.com/zos/antfincdn/kagsfItG%26g/49861247-bc88-4d64-b5b1-0913c8ff55f8.png",source:"import { GaodeMap, Scene } from '@antv/l7';\nimport { Choropleth } from '@antv/l7plot';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'blank',\n center: [120.19382669582967, 30.258134],\n zoom: 3,\n }),\n});\n\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/alisis/geo-data-v0.1.1/administrative-data/area-list.json',\n )\n .then((response) => response.json())\n .then((list) => {\n const data = list\n .filter(\n ({ level, parent }) => level === 'district' && parent === 330100,\n )\n .map((item) => ({ ...item, value: Math.random() * 5000 }));\n\n const choropleth = new Choropleth({\n source: {\n data,\n joinBy: {\n sourceField: 'adcode',\n geoField: 'adcode',\n },\n },\n viewLevel: {\n level: 'city',\n adcode: 330100,\n },\n autoFit: true,\n color: {\n field: 'value',\n value: ['#B8E1FF', '#7DAAFF', '#3D76DD', '#0047A5', '#001D70'],\n scale: { type: 'quantize' },\n },\n style: {\n opacity: 1,\n stroke: '#ccc',\n lineWidth: 0.6,\n lineOpacity: 1,\n },\n label: {\n visible: true,\n field: 'name',\n style: {\n fill: '#000',\n opacity: 0.8,\n fontSize: 10,\n stroke: '#fff',\n strokeWidth: 1.5,\n textAllowOverlap: false,\n padding: [5, 5],\n },\n },\n state: {\n active: { stroke: 'black', lineWidth: 1 },\n },\n tooltip: {\n items: ['name', 'adcode', 'value'],\n },\n zoom: {\n position: 'bottomright',\n },\n legend: {\n position: 'bottomleft',\n },\n });\n\n choropleth.addToScene(scene);\n });\n});\n",title:{zh:"杭州市地图",en:"Hangzhou City Map"},filename:"hangzhou-city.ts",isNew:!1},{id:"xihu-district",screenshot:"https://gw.alipayobjects.com/zos/antfincdn/04xm5U4yvt/828e6055-f005-4dba-8936-aaf451487db9.png",source:"import { GaodeMap, Scene } from '@antv/l7';\nimport { Choropleth } from '@antv/l7plot';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'blank',\n center: [120.19382669582967, 30.258134],\n zoom: 3,\n }),\n});\n\nconst choropleth = new Choropleth({\n source: {\n data: [{ adcode: 330106, value: 200 }],\n joinBy: {\n sourceField: 'adcode',\n geoField: 'adcode',\n },\n },\n viewLevel: {\n level: 'district',\n adcode: 330106,\n },\n autoFit: true,\n color: {\n field: 'value',\n value: ['#B8E1FF', '#7DAAFF', '#3D76DD', '#0047A5', '#001D70'],\n scale: { type: 'quantize' },\n },\n style: {\n opacity: 1,\n stroke: '#ccc',\n lineWidth: 0.6,\n lineOpacity: 1,\n },\n label: {\n visible: true,\n field: 'name',\n style: {\n fill: '#000',\n opacity: 0.8,\n fontSize: 10,\n stroke: '#fff',\n strokeWidth: 1.5,\n textAllowOverlap: false,\n padding: [5, 5],\n },\n },\n state: {\n active: { stroke: 'black', lineWidth: 1 },\n },\n tooltip: {\n items: ['name', 'adcode', 'value'],\n },\n zoom: {\n position: 'bottomright',\n },\n legend: {\n position: 'bottomleft',\n },\n});\n\nscene.on('loaded', () => {\n choropleth.addToScene(scene);\n});\n",title:{zh:"西湖区地图",en:"Xihu District Map"},filename:"xihu-district.ts",isNew:!1}],icon:"",id:"administrative",title:{en:"Administrative Division",zh:"行政区域"},childrenKey:"demos",order:0}],childrenKey:"examples"},{id:"tutorial",title:{zh:"教程示例",en:"Tutorial demo"},icon:"map",examples:[{demos:[{id:"gaodemap",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*C4BvT5gcclMAAAAAAAAAAAAAARQnAQ",source:"import { Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nnew Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 107.054293, 35.246265 ],\n zoom: 4.056\n })\n});\n",title:"高德底图",filename:"gaodemap.js",isNew:!1},{id:"amapInstance",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*A4BOR4hBNcUAAAAAAAAAAAAAARQnAQ",source:"import { Scene, PointLayer } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nfunction initMap() {\n // 全局加载高德地图API\n const map = new AMap.Map('map', {\n viewMode: '3D',\n mapStyle: 'amap://styles/darkblue',\n center: [ 121.435159, 31.256971 ],\n zoom: 14.89,\n minZoom: 10\n });\n const scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n mapInstance: map\n })\n });\n scene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/893d1d5f-11d9-45f3-8322-ee9140d288ae.json'\n )\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer()\n .source(data, {\n parser: {\n type: 'json',\n x: 'longitude',\n y: 'latitude'\n }\n })\n .shape('name', [\n 'circle',\n 'triangle',\n 'square',\n 'pentagon',\n 'hexagon',\n 'octogon',\n 'hexagram',\n 'rhombus',\n 'vesica'\n ])\n .size('unit_price', [ 10, 25 ])\n .color('name', [ '#5B8FF9', '#5CCEA1', '#5D7092', '#F6BD16', '#E86452' ])\n .style({\n opacity: 0.3,\n strokeWidth: 2\n });\n scene.addLayer(pointLayer);\n });\n });\n}\n initMap();",title:"高德地图实例化",filename:"amapInstance.js",isNew:!1}],icon:"",id:"map",title:{en:"Map",zh:"地图"},childrenKey:"demos",order:0},{demos:[{id:"amap",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*4Jj2RJQIQTAAAAAAAAAAAAAAARQnAQ",source:"import { PointLayer, Scale, Scene, LayerSwitch, Zoom } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 121.4316962, 31.26082325 ],\n zoom: 15.056\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/893d1d5f-11d9-45f3-8322-ee9140d288ae.json'\n )\n .then(res => res.json())\n .then(data => {\n const pointLayer = new PointLayer({})\n .source(data, {\n parser: {\n type: 'json',\n x: 'longitude',\n y: 'latitude'\n }\n })\n .shape('circle')\n .size('unit_price', [ 5, 25 ])\n .color('name', [ '#49B5AD', '#5B8FF9' ])\n .style({\n opacity: 0.3,\n strokeWidth: 1\n });\n\n scene.addLayer(pointLayer);\n });\n\n const layerSwitch = new LayerSwitch({\n position: 'rightcenter'\n })\n scene.addControl(layerSwitch);\n\n const zoomControl = new Zoom({\n position: 'rightcenter'\n });\n\n const scaleControl = new Scale({\n position: 'bottomright'\n });\n scene.addControl(zoomControl);\n scene.addControl(scaleControl);\n});\n",title:"高德底图组件",filename:"amap.js",isNew:!1}],icon:"",id:"control",title:{en:"Control",zh:"组件"},childrenKey:"demos",order:2},{demos:[{id:"layer_highlight",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*CnSaSaPwyX8AAAAAAAAAAAAAARQnAQ",source:"import { PolygonLayer, LineLayer, Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 118.7368, 32.0560 ],\n zoom: 9\n })\n});\nscene.on('loaded', () => {\n fetch(\n 'https://gw.alipayobjects.com/os/basement_prod/91247d10-585b-4406-b1e2-93b001e3a0e4.json'\n )\n .then(res => res.json())\n .then(data => {\n const filllayer = new PolygonLayer({\n name: 'fill'\n })\n .source(data)\n .shape('fill')\n .color('unit_price', [ '#f0f9e8', '#ccebc5', '#a8ddb5', '#7bccc4', '#43a2ca', '#0868ac' ]);\n const linelayer = new LineLayer({\n zIndex: 1,\n name: 'line'\n })\n .source(data)\n .shape('line')\n .size(0.5)\n .color('#fff')\n .style({\n opacity: 0.5\n });\n const hightLayer = new LineLayer({\n zIndex: 4, // 设置显示层级\n name: 'hightlight'\n })\n .source({\n type: 'FeatureCollection',\n features: [ ]\n })\n .shape('line')\n .size(2)\n .color('red');\n scene.addLayer(filllayer);\n scene.addLayer(linelayer);\n scene.addLayer(hightLayer);\n filllayer.on('click', feature => {\n console.log(feature);\n hightLayer.setData({\n type: 'FeatureCollection',\n features: [ feature.feature ]\n });\n });\n });\n});\n",title:"交互高亮图层",filename:"layer_highlight.js",isNew:!1},{id:"layer_boxselect",screenshot:"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*5kzJQYS_N20AAAAAAAAAAAAADmJ7AQ/original",source:"import { PolygonLayer, LineLayer, Scene } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\n\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [120.13618469238281, 30.247352897833554],\n zoom: 9,\n }),\n});\nscene.on('loaded', () => {\n fetch('https://geo.datav.aliyun.com/areas_v3/bound/330100_full.json')\n .then((res) => res.json())\n .then((data) => {\n const fillLayer = new PolygonLayer({\n name: 'fill',\n autoFit: true,\n })\n .source(data)\n .shape('fill')\n .color('adcode', [\n '#f0f9e8',\n '#ccebc5',\n '#a8ddb5',\n '#7bccc4',\n '#43a2ca',\n '#0868ac',\n ]);\n\n const lineLayer = new LineLayer({\n zIndex: 1,\n name: 'line',\n })\n .source(data)\n .shape('line')\n .size(1)\n .color('#fff');\n\n const selectLayer = new LineLayer({\n zIndex: 2,\n name: 'select',\n })\n .source([])\n .shape('line')\n .size(2)\n .color('#f00');\n\n scene.addLayer(fillLayer);\n scene.addLayer(lineLayer);\n scene.addLayer(selectLayer);\n\n scene.enableBoxSelect(false);\n\n const onBoxSelect = (bbox, startEvent, endEvent) => {\n const { x: x1, y: y1 } = startEvent;\n const { x: x2, y: y2 } = endEvent;\n fillLayer.boxSelect(\n [\n Math.min(x1, x2),\n Math.min(y1, y2),\n Math.max(x1, x2),\n Math.max(y1, y2),\n ],\n (features) => {\n selectLayer.setData({\n type: 'FeatureCollection',\n features: features ?? [],\n });\n },\n );\n };\n\n scene.on('selecting', onBoxSelect);\n scene.on('selectend', onBoxSelect);\n });\n});\n",title:"框选图层",filename:"layer_boxselect.js",isNew:!1}],icon:"",id:"layer",title:{en:"Layer",zh:"图层"},childrenKey:"demos",order:2},{demos:[{id:"amap",screenshot:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*VEy6S6UrAV8AAAAAAAAAAAAAARQnAQ",source:"import { Scene, Marker, Popup } from '@antv/l7';\nimport { GaodeMap } from '@antv/l7-maps';\nconst scene = new Scene({\n id: 'map',\n map: new GaodeMap({\n style: 'light',\n center: [ 121.4316962, 31.26082325 ],\n zoom: 12.056\n })\n});\nscene.on('loaded', () => {\n// 创建默认 marker\n const popup = new Popup({\n offsets: [ 0, 20 ]\n }).setText('hello');\n\n const marker = new Marker()\n .setLnglat([ 121.4316962, 31.26082325 ])\n .setPopup(popup);\n\n scene.addMarker(marker);\n});\n",title:"添加默认Marker",filename:"amap.js",isNew:!1}],icon:"",id:"marker",title:{en:"Marker",zh:"Marker"},childrenKey:"demos",order:2}],childrenKey:"examples"}]}},children:n})}},74927:function(n,e,a){a.d(e,{w:function(){return t}});var t=(0,a(41398).createContext)({})}}]); \ No newline at end of file diff --git a/en/api/base_layer/base/index.html b/en/api/base_layer/base/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/base_layer/base/index.html +++ b/en/api/base_layer/base/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/component/marker/marker-layer/index.html b/en/api/component/marker/marker-layer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/component/marker/marker-layer/index.html +++ b/en/api/component/marker/marker-layer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/component/marker/marker/index.html b/en/api/component/marker/marker/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/component/marker/marker/index.html +++ b/en/api/component/marker/marker/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/component/popup/popup/index.html b/en/api/component/popup/popup/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/component/popup/popup/index.html +++ b/en/api/component/popup/popup/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/debug/debugservice/index.html b/en/api/debug/debugservice/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/debug/debugservice/index.html +++ b/en/api/debug/debugservice/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/experiment/canvas/index.html b/en/api/experiment/canvas/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/experiment/canvas/index.html +++ b/en/api/experiment/canvas/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/experiment/earth/earth/index.html b/en/api/experiment/earth/earth/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/experiment/earth/earth/index.html +++ b/en/api/experiment/earth/earth/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/experiment/earth/flyline/index.html b/en/api/experiment/earth/flyline/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/experiment/earth/flyline/index.html +++ b/en/api/experiment/earth/flyline/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/experiment/earth/point/index.html b/en/api/experiment/earth/point/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/experiment/earth/point/index.html +++ b/en/api/experiment/earth/point/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/experiment/pass/index.html b/en/api/experiment/pass/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/experiment/pass/index.html +++ b/en/api/experiment/pass/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/experiment/simplecoordinates/index.html b/en/api/experiment/simplecoordinates/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/experiment/simplecoordinates/index.html +++ b/en/api/experiment/simplecoordinates/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/experiment/three/index.html b/en/api/experiment/three/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/experiment/three/index.html +++ b/en/api/experiment/three/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/experiment/wind/index.html b/en/api/experiment/wind/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/experiment/wind/index.html +++ b/en/api/experiment/wind/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/heatmap_layer/heatmap/index.html b/en/api/heatmap_layer/heatmap/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/heatmap_layer/heatmap/index.html +++ b/en/api/heatmap_layer/heatmap/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/heatmap_layer/options/index.html b/en/api/heatmap_layer/options/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/heatmap_layer/options/index.html +++ b/en/api/heatmap_layer/options/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/heatmap_layer/scale/index.html b/en/api/heatmap_layer/scale/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/heatmap_layer/scale/index.html +++ b/en/api/heatmap_layer/scale/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/heatmap_layer/shape/index.html b/en/api/heatmap_layer/shape/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/heatmap_layer/shape/index.html +++ b/en/api/heatmap_layer/shape/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/heatmap_layer/source/index.html b/en/api/heatmap_layer/source/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/heatmap_layer/source/index.html +++ b/en/api/heatmap_layer/source/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/heatmap_layer/style/index.html b/en/api/heatmap_layer/style/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/heatmap_layer/style/index.html +++ b/en/api/heatmap_layer/style/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/image_layer/imagelayer/index.html b/en/api/image_layer/imagelayer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/image_layer/imagelayer/index.html +++ b/en/api/image_layer/imagelayer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/image_layer/options/index.html b/en/api/image_layer/options/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/image_layer/options/index.html +++ b/en/api/image_layer/options/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/image_layer/source/index.html b/en/api/image_layer/source/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/image_layer/source/index.html +++ b/en/api/image_layer/source/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/image_layer/style/index.html b/en/api/image_layer/style/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/image_layer/style/index.html +++ b/en/api/image_layer/style/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/line_layer/animate/index.html b/en/api/line_layer/animate/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/line_layer/animate/index.html +++ b/en/api/line_layer/animate/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/line_layer/color/index.html b/en/api/line_layer/color/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/line_layer/color/index.html +++ b/en/api/line_layer/color/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/line_layer/linelayer/index.html b/en/api/line_layer/linelayer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/line_layer/linelayer/index.html +++ b/en/api/line_layer/linelayer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/line_layer/options/index.html b/en/api/line_layer/options/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/line_layer/options/index.html +++ b/en/api/line_layer/options/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/line_layer/scale/index.html b/en/api/line_layer/scale/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/line_layer/scale/index.html +++ b/en/api/line_layer/scale/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/line_layer/shape/index.html b/en/api/line_layer/shape/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/line_layer/shape/index.html +++ b/en/api/line_layer/shape/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/line_layer/size/index.html b/en/api/line_layer/size/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/line_layer/size/index.html +++ b/en/api/line_layer/size/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/line_layer/source/index.html b/en/api/line_layer/source/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/line_layer/source/index.html +++ b/en/api/line_layer/source/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/line_layer/style/index.html b/en/api/line_layer/style/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/line_layer/style/index.html +++ b/en/api/line_layer/style/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/line_layer/texture/index.html b/en/api/line_layer/texture/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/line_layer/texture/index.html +++ b/en/api/line_layer/texture/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/map/map/index.html b/en/api/map/map/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/map/map/index.html +++ b/en/api/map/map/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/mask_layer/masklayer/index.html b/en/api/mask_layer/masklayer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/mask_layer/masklayer/index.html +++ b/en/api/mask_layer/masklayer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/mask_layer/options/index.html b/en/api/mask_layer/options/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/mask_layer/options/index.html +++ b/en/api/mask_layer/options/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/mask_layer/source/index.html b/en/api/mask_layer/source/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/mask_layer/source/index.html +++ b/en/api/mask_layer/source/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/mini/demos/chinapopulation/index.html b/en/api/mini/demos/chinapopulation/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/mini/demos/chinapopulation/index.html +++ b/en/api/mini/demos/chinapopulation/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/mini/demos/flyline/index.html b/en/api/mini/demos/flyline/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/mini/demos/flyline/index.html +++ b/en/api/mini/demos/flyline/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/mini/demos/heat/index.html b/en/api/mini/demos/heat/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/mini/demos/heat/index.html +++ b/en/api/mini/demos/heat/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/mini/demos/hexagon/index.html b/en/api/mini/demos/hexagon/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/mini/demos/hexagon/index.html +++ b/en/api/mini/demos/hexagon/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/mini/demos/high-line/index.html b/en/api/mini/demos/high-line/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/mini/demos/high-line/index.html +++ b/en/api/mini/demos/high-line/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/mini/mini/index.html b/en/api/mini/mini/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/mini/mini/index.html +++ b/en/api/mini/mini/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/other/citybuilding/index.html b/en/api/other/citybuilding/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/other/citybuilding/index.html +++ b/en/api/other/citybuilding/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/other/plane/index.html b/en/api/other/plane/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/other/plane/index.html +++ b/en/api/other/plane/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/other/sprite/index.html b/en/api/other/sprite/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/other/sprite/index.html +++ b/en/api/other/sprite/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/point_layer/animate/index.html b/en/api/point_layer/animate/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/point_layer/animate/index.html +++ b/en/api/point_layer/animate/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/point_layer/color/index.html b/en/api/point_layer/color/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/point_layer/color/index.html +++ b/en/api/point_layer/color/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/point_layer/options/index.html b/en/api/point_layer/options/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/point_layer/options/index.html +++ b/en/api/point_layer/options/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/point_layer/pointlayer/index.html b/en/api/point_layer/pointlayer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/point_layer/pointlayer/index.html +++ b/en/api/point_layer/pointlayer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/point_layer/scale/index.html b/en/api/point_layer/scale/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/point_layer/scale/index.html +++ b/en/api/point_layer/scale/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/point_layer/shape/index.html b/en/api/point_layer/shape/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/point_layer/shape/index.html +++ b/en/api/point_layer/shape/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/point_layer/size/index.html b/en/api/point_layer/size/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/point_layer/size/index.html +++ b/en/api/point_layer/size/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/point_layer/source/index.html b/en/api/point_layer/source/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/point_layer/source/index.html +++ b/en/api/point_layer/source/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/point_layer/style/index.html b/en/api/point_layer/style/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/point_layer/style/index.html +++ b/en/api/point_layer/style/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/polygon_layer/animate/index.html b/en/api/polygon_layer/animate/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/polygon_layer/animate/index.html +++ b/en/api/polygon_layer/animate/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/polygon_layer/color/index.html b/en/api/polygon_layer/color/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/polygon_layer/color/index.html +++ b/en/api/polygon_layer/color/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/polygon_layer/options/index.html b/en/api/polygon_layer/options/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/polygon_layer/options/index.html +++ b/en/api/polygon_layer/options/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/polygon_layer/polygonlayer/index.html b/en/api/polygon_layer/polygonlayer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/polygon_layer/polygonlayer/index.html +++ b/en/api/polygon_layer/polygonlayer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/polygon_layer/scale/index.html b/en/api/polygon_layer/scale/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/polygon_layer/scale/index.html +++ b/en/api/polygon_layer/scale/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/polygon_layer/shape/index.html b/en/api/polygon_layer/shape/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/polygon_layer/shape/index.html +++ b/en/api/polygon_layer/shape/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/polygon_layer/source/index.html b/en/api/polygon_layer/source/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/polygon_layer/source/index.html +++ b/en/api/polygon_layer/source/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/polygon_layer/style/index.html b/en/api/polygon_layer/style/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/polygon_layer/style/index.html +++ b/en/api/polygon_layer/style/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/raster_layer/raster_muti_band/index.html b/en/api/raster_layer/raster_muti_band/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/raster_layer/raster_muti_band/index.html +++ b/en/api/raster_layer/raster_muti_band/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/raster_layer/raster_rgb/index.html b/en/api/raster_layer/raster_rgb/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/raster_layer/raster_rgb/index.html +++ b/en/api/raster_layer/raster_rgb/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/raster_layer/raster_single_band/index.html b/en/api/raster_layer/raster_single_band/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/raster_layer/raster_single_band/index.html +++ b/en/api/raster_layer/raster_single_band/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/scene/index.html b/en/api/scene/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/scene/index.html +++ b/en/api/scene/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/source/csv/index.html b/en/api/source/csv/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/source/csv/index.html +++ b/en/api/source/csv/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/source/geojson/index.html b/en/api/source/geojson/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/source/geojson/index.html +++ b/en/api/source/geojson/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/source/image/index.html b/en/api/source/image/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/source/image/index.html +++ b/en/api/source/image/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/source/json/index.html b/en/api/source/json/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/source/json/index.html +++ b/en/api/source/json/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/source/mvt/index.html b/en/api/source/mvt/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/source/mvt/index.html +++ b/en/api/source/mvt/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/source/raster/index.html b/en/api/source/raster/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/source/raster/index.html +++ b/en/api/source/raster/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/source/raster_rgb/index.html b/en/api/source/raster_rgb/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/source/raster_rgb/index.html +++ b/en/api/source/raster_rgb/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/source/rastertile/index.html b/en/api/source/rastertile/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/source/rastertile/index.html +++ b/en/api/source/rastertile/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/source/source/index.html b/en/api/source/source/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/source/source/index.html +++ b/en/api/source/source/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/tile/geojsonvt_tile_layer/index.html b/en/api/tile/geojsonvt_tile_layer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/tile/geojsonvt_tile_layer/index.html +++ b/en/api/tile/geojsonvt_tile_layer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/tile/raster_tile_layer/index.html b/en/api/tile/raster_tile_layer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/tile/raster_tile_layer/index.html +++ b/en/api/tile/raster_tile_layer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/api/tile/vector_tile_layer/index.html b/en/api/tile/vector_tile_layer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/api/tile/vector_tile_layer/index.html +++ b/en/api/tile/vector_tile_layer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/amap-plugin/bus/index.html b/en/examples/amap-plugin/bus/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/amap-plugin/bus/index.html +++ b/en/examples/amap-plugin/bus/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/choropleth/administrative/index.html b/en/examples/choropleth/administrative/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/choropleth/administrative/index.html +++ b/en/examples/choropleth/administrative/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/component/control/index.html b/en/examples/component/control/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/component/control/index.html +++ b/en/examples/component/control/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/component/marker/index.html b/en/examples/component/marker/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/component/marker/index.html +++ b/en/examples/component/marker/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/component/popup/index.html b/en/examples/component/popup/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/component/popup/index.html +++ b/en/examples/component/popup/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/draw/basic/index.html b/en/examples/draw/basic/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/draw/basic/index.html +++ b/en/examples/draw/basic/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/draw/control/index.html b/en/examples/draw/control/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/draw/control/index.html +++ b/en/examples/draw/control/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/earth/arc3d/index.html b/en/examples/earth/arc3d/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/earth/arc3d/index.html +++ b/en/examples/earth/arc3d/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/engine/three/index.html b/en/examples/engine/three/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/engine/three/index.html +++ b/en/examples/engine/three/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/gallery/animate/index.html b/en/examples/gallery/animate/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/gallery/animate/index.html +++ b/en/examples/gallery/animate/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/gallery/basic/index.html b/en/examples/gallery/basic/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/gallery/basic/index.html +++ b/en/examples/gallery/basic/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/geometry/geometry/index.html b/en/examples/geometry/geometry/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/geometry/geometry/index.html +++ b/en/examples/geometry/geometry/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/heatmap/grid/index.html b/en/examples/heatmap/grid/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/heatmap/grid/index.html +++ b/en/examples/heatmap/grid/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/heatmap/heatmap/index.html b/en/examples/heatmap/heatmap/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/heatmap/heatmap/index.html +++ b/en/examples/heatmap/heatmap/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/heatmap/hexagon/index.html b/en/examples/heatmap/hexagon/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/heatmap/hexagon/index.html +++ b/en/examples/heatmap/hexagon/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/line/animate/index.html b/en/examples/line/animate/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/line/animate/index.html +++ b/en/examples/line/animate/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/line/arc/index.html b/en/examples/line/arc/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/line/arc/index.html +++ b/en/examples/line/arc/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/line/isoline/index.html b/en/examples/line/isoline/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/line/isoline/index.html +++ b/en/examples/line/isoline/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/line/path/index.html b/en/examples/line/path/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/line/path/index.html +++ b/en/examples/line/path/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/line/wall/index.html b/en/examples/line/wall/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/line/wall/index.html +++ b/en/examples/line/wall/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/point/bubble/index.html b/en/examples/point/bubble/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/point/bubble/index.html +++ b/en/examples/point/bubble/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/point/chart/index.html b/en/examples/point/chart/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/point/chart/index.html +++ b/en/examples/point/chart/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/point/cluster/index.html b/en/examples/point/cluster/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/point/cluster/index.html +++ b/en/examples/point/cluster/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/point/column/index.html b/en/examples/point/column/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/point/column/index.html +++ b/en/examples/point/column/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/point/dot/index.html b/en/examples/point/dot/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/point/dot/index.html +++ b/en/examples/point/dot/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/point/image/index.html b/en/examples/point/image/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/point/image/index.html +++ b/en/examples/point/image/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/point/scatter/index.html b/en/examples/point/scatter/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/point/scatter/index.html +++ b/en/examples/point/scatter/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/point/simple/index.html b/en/examples/point/simple/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/point/simple/index.html +++ b/en/examples/point/simple/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/point/text/index.html b/en/examples/point/text/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/point/text/index.html +++ b/en/examples/point/text/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/polygon/3d/index.html b/en/examples/polygon/3d/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/polygon/3d/index.html +++ b/en/examples/polygon/3d/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/polygon/fill/index.html b/en/examples/polygon/fill/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/polygon/fill/index.html +++ b/en/examples/polygon/fill/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/raster/basic/index.html b/en/examples/raster/basic/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/raster/basic/index.html +++ b/en/examples/raster/basic/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/raster/data_raster/index.html b/en/examples/raster/data_raster/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/raster/data_raster/index.html +++ b/en/examples/raster/data_raster/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/raster/single_raster/index.html b/en/examples/raster/single_raster/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/raster/single_raster/index.html +++ b/en/examples/raster/single_raster/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/tile/basemap/index.html b/en/examples/tile/basemap/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/tile/basemap/index.html +++ b/en/examples/tile/basemap/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/tile/raster/index.html b/en/examples/tile/raster/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/tile/raster/index.html +++ b/en/examples/tile/raster/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/tile/vector/index.html b/en/examples/tile/vector/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/tile/vector/index.html +++ b/en/examples/tile/vector/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/tutorial/control/index.html b/en/examples/tutorial/control/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/tutorial/control/index.html +++ b/en/examples/tutorial/control/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/tutorial/layer/index.html b/en/examples/tutorial/layer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/tutorial/layer/index.html +++ b/en/examples/tutorial/layer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/tutorial/map/index.html b/en/examples/tutorial/map/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/tutorial/map/index.html +++ b/en/examples/tutorial/map/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/tutorial/marker/index.html b/en/examples/tutorial/marker/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/tutorial/marker/index.html +++ b/en/examples/tutorial/marker/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/examples/wind/basic/index.html b/en/examples/wind/basic/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/examples/wind/basic/index.html +++ b/en/examples/wind/basic/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/index.html b/en/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/index.html +++ b/en/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/data/index.html b/en/tutorial/data/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/data/index.html +++ b/en/tutorial/data/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/debug/layer-init/index.html b/en/tutorial/debug/layer-init/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/debug/layer-init/index.html +++ b/en/tutorial/debug/layer-init/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/debug/map-init/index.html b/en/tutorial/debug/map-init/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/debug/map-init/index.html +++ b/en/tutorial/debug/map-init/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/debug/render/index.html b/en/tutorial/debug/render/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/debug/render/index.html +++ b/en/tutorial/debug/render/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/demo/index.html b/en/tutorial/demo/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/demo/index.html +++ b/en/tutorial/demo/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/faq/index.html b/en/tutorial/faq/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/faq/index.html +++ b/en/tutorial/faq/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/heatmap/grid/index.html b/en/tutorial/heatmap/grid/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/heatmap/grid/index.html +++ b/en/tutorial/heatmap/grid/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/heatmap/hexagon/index.html b/en/tutorial/heatmap/hexagon/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/heatmap/hexagon/index.html +++ b/en/tutorial/heatmap/hexagon/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/heatmap/normal/index.html b/en/tutorial/heatmap/normal/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/heatmap/normal/index.html +++ b/en/tutorial/heatmap/normal/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/interactive/hightlight/index.html b/en/tutorial/interactive/hightlight/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/interactive/hightlight/index.html +++ b/en/tutorial/interactive/hightlight/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/l7/index.html b/en/tutorial/l7/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/l7/index.html +++ b/en/tutorial/l7/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/line/arc/index.html b/en/tutorial/line/arc/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/line/arc/index.html +++ b/en/tutorial/line/arc/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/line/arc3d/index.html b/en/tutorial/line/arc3d/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/line/arc3d/index.html +++ b/en/tutorial/line/arc3d/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/line/greatcircle/index.html b/en/tutorial/line/greatcircle/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/line/greatcircle/index.html +++ b/en/tutorial/line/greatcircle/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/line/path/index.html b/en/tutorial/line/path/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/line/path/index.html +++ b/en/tutorial/line/path/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/line/simple/index.html b/en/tutorial/line/simple/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/line/simple/index.html +++ b/en/tutorial/line/simple/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/line/wall/index.html b/en/tutorial/line/wall/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/line/wall/index.html +++ b/en/tutorial/line/wall/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/map/amap/index.html b/en/tutorial/map/amap/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/map/amap/index.html +++ b/en/tutorial/map/amap/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/map/amapplugin/index.html b/en/tutorial/map/amapplugin/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/map/amapplugin/index.html +++ b/en/tutorial/map/amapplugin/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/map/blankmap/index.html b/en/tutorial/map/blankmap/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/map/blankmap/index.html +++ b/en/tutorial/map/blankmap/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/map/leaflet/index.html b/en/tutorial/map/leaflet/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/map/leaflet/index.html +++ b/en/tutorial/map/leaflet/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/map/mapbox/index.html b/en/tutorial/map/mapbox/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/map/mapbox/index.html +++ b/en/tutorial/map/mapbox/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/map/offline/index.html b/en/tutorial/map/offline/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/map/offline/index.html +++ b/en/tutorial/map/offline/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/map/tianditu/index.html b/en/tutorial/map/tianditu/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/map/tianditu/index.html +++ b/en/tutorial/map/tianditu/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/mask/init/index.html b/en/tutorial/mask/init/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/mask/init/index.html +++ b/en/tutorial/mask/init/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/mask/option/index.html b/en/tutorial/mask/option/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/mask/option/index.html +++ b/en/tutorial/mask/option/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/mask/tile/index.html b/en/tutorial/mask/tile/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/mask/tile/index.html +++ b/en/tutorial/mask/tile/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/point/bubble/index.html b/en/tutorial/point/bubble/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/point/bubble/index.html +++ b/en/tutorial/point/bubble/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/point/chart/index.html b/en/tutorial/point/chart/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/point/chart/index.html +++ b/en/tutorial/point/chart/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/point/cluster/index.html b/en/tutorial/point/cluster/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/point/cluster/index.html +++ b/en/tutorial/point/cluster/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/point/column/index.html b/en/tutorial/point/column/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/point/column/index.html +++ b/en/tutorial/point/column/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/point/dot/index.html b/en/tutorial/point/dot/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/point/dot/index.html +++ b/en/tutorial/point/dot/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/point/iconfont/index.html b/en/tutorial/point/iconfont/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/point/iconfont/index.html +++ b/en/tutorial/point/iconfont/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/point/mark/index.html b/en/tutorial/point/mark/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/point/mark/index.html +++ b/en/tutorial/point/mark/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/point/radar/index.html b/en/tutorial/point/radar/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/point/radar/index.html +++ b/en/tutorial/point/radar/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/point/scatter/index.html b/en/tutorial/point/scatter/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/point/scatter/index.html +++ b/en/tutorial/point/scatter/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/point/simple/index.html b/en/tutorial/point/simple/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/point/simple/index.html +++ b/en/tutorial/point/simple/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/point/symbol/index.html b/en/tutorial/point/symbol/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/point/symbol/index.html +++ b/en/tutorial/point/symbol/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/point/text/index.html b/en/tutorial/point/text/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/point/text/index.html +++ b/en/tutorial/point/text/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/point/wave/index.html b/en/tutorial/point/wave/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/point/wave/index.html +++ b/en/tutorial/point/wave/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/polygon/extrude/index.html b/en/tutorial/polygon/extrude/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/polygon/extrude/index.html +++ b/en/tutorial/polygon/extrude/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/polygon/fill/index.html b/en/tutorial/polygon/fill/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/polygon/fill/index.html +++ b/en/tutorial/polygon/fill/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/polygon/water/index.html b/en/tutorial/polygon/water/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/polygon/water/index.html +++ b/en/tutorial/polygon/water/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/quickstart/index.html b/en/tutorial/quickstart/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/quickstart/index.html +++ b/en/tutorial/quickstart/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/scale/index.html b/en/tutorial/scale/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/scale/index.html +++ b/en/tutorial/scale/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/tile/raster-tile/index.html b/en/tutorial/tile/raster-tile/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/tile/raster-tile/index.html +++ b/en/tutorial/tile/raster-tile/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/tile/tile/index.html b/en/tutorial/tile/tile/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/tile/tile/index.html +++ b/en/tutorial/tile/tile/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/en/tutorial/tile/vector-tile/index.html b/en/tutorial/tile/vector-tile/index.html index 18f99f0c1c..b53b74429b 100644 --- a/en/tutorial/tile/vector-tile/index.html +++ b/en/tutorial/tile/vector-tile/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/:topic/:example/index.html b/examples/:topic/:example/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/:topic/:example/index.html +++ b/examples/:topic/:example/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/amap-plugin/bus/index.html b/examples/amap-plugin/bus/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/amap-plugin/bus/index.html +++ b/examples/amap-plugin/bus/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/choropleth/administrative/index.html b/examples/choropleth/administrative/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/choropleth/administrative/index.html +++ b/examples/choropleth/administrative/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/component/control/index.html b/examples/component/control/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/component/control/index.html +++ b/examples/component/control/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/component/marker/index.html b/examples/component/marker/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/component/marker/index.html +++ b/examples/component/marker/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/component/popup/index.html b/examples/component/popup/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/component/popup/index.html +++ b/examples/component/popup/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/draw/basic/index.html b/examples/draw/basic/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/draw/basic/index.html +++ b/examples/draw/basic/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/draw/control/index.html b/examples/draw/control/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/draw/control/index.html +++ b/examples/draw/control/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/earth/arc3d/index.html b/examples/earth/arc3d/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/earth/arc3d/index.html +++ b/examples/earth/arc3d/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/engine/three/index.html b/examples/engine/three/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/engine/three/index.html +++ b/examples/engine/three/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/gallery/animate/index.html b/examples/gallery/animate/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/gallery/animate/index.html +++ b/examples/gallery/animate/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/gallery/basic/index.html b/examples/gallery/basic/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/gallery/basic/index.html +++ b/examples/gallery/basic/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/geometry/geometry/index.html b/examples/geometry/geometry/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/geometry/geometry/index.html +++ b/examples/geometry/geometry/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/heatmap/grid/index.html b/examples/heatmap/grid/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/heatmap/grid/index.html +++ b/examples/heatmap/grid/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/heatmap/heatmap/index.html b/examples/heatmap/heatmap/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/heatmap/heatmap/index.html +++ b/examples/heatmap/heatmap/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/heatmap/hexagon/index.html b/examples/heatmap/hexagon/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/heatmap/hexagon/index.html +++ b/examples/heatmap/hexagon/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/index.html b/examples/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/index.html +++ b/examples/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/line/animate/index.html b/examples/line/animate/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/line/animate/index.html +++ b/examples/line/animate/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/line/arc/index.html b/examples/line/arc/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/line/arc/index.html +++ b/examples/line/arc/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/line/isoline/index.html b/examples/line/isoline/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/line/isoline/index.html +++ b/examples/line/isoline/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/line/path/index.html b/examples/line/path/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/line/path/index.html +++ b/examples/line/path/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/line/wall/index.html b/examples/line/wall/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/line/wall/index.html +++ b/examples/line/wall/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/point/bubble/index.html b/examples/point/bubble/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/point/bubble/index.html +++ b/examples/point/bubble/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/point/chart/index.html b/examples/point/chart/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/point/chart/index.html +++ b/examples/point/chart/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/point/cluster/index.html b/examples/point/cluster/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/point/cluster/index.html +++ b/examples/point/cluster/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/point/column/index.html b/examples/point/column/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/point/column/index.html +++ b/examples/point/column/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/point/dot/index.html b/examples/point/dot/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/point/dot/index.html +++ b/examples/point/dot/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/point/image/index.html b/examples/point/image/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/point/image/index.html +++ b/examples/point/image/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/point/scatter/index.html b/examples/point/scatter/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/point/scatter/index.html +++ b/examples/point/scatter/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/point/simple/index.html b/examples/point/simple/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/point/simple/index.html +++ b/examples/point/simple/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/point/text/index.html b/examples/point/text/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/point/text/index.html +++ b/examples/point/text/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/polygon/3d/index.html b/examples/polygon/3d/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/polygon/3d/index.html +++ b/examples/polygon/3d/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/polygon/fill/index.html b/examples/polygon/fill/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/polygon/fill/index.html +++ b/examples/polygon/fill/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/raster/basic/index.html b/examples/raster/basic/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/raster/basic/index.html +++ b/examples/raster/basic/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/raster/data_raster/index.html b/examples/raster/data_raster/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/raster/data_raster/index.html +++ b/examples/raster/data_raster/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/raster/single_raster/index.html b/examples/raster/single_raster/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/raster/single_raster/index.html +++ b/examples/raster/single_raster/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/tile/basemap/index.html b/examples/tile/basemap/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/tile/basemap/index.html +++ b/examples/tile/basemap/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/tile/raster/index.html b/examples/tile/raster/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/tile/raster/index.html +++ b/examples/tile/raster/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/tile/vector/index.html b/examples/tile/vector/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/tile/vector/index.html +++ b/examples/tile/vector/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/tutorial/control/index.html b/examples/tutorial/control/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/tutorial/control/index.html +++ b/examples/tutorial/control/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/tutorial/layer/index.html b/examples/tutorial/layer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/tutorial/layer/index.html +++ b/examples/tutorial/layer/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/tutorial/map/index.html b/examples/tutorial/map/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/tutorial/map/index.html +++ b/examples/tutorial/map/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/tutorial/marker/index.html b/examples/tutorial/marker/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/tutorial/marker/index.html +++ b/examples/tutorial/marker/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/examples/wind/basic/index.html b/examples/wind/basic/index.html index 18f99f0c1c..b53b74429b 100644 --- a/examples/wind/basic/index.html +++ b/examples/wind/basic/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/index.html b/index.html index 18f99f0c1c..b53b74429b 100644 --- a/index.html +++ b/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/data/index.html b/tutorial/data/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/data/index.html +++ b/tutorial/data/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/debug/layer-init/index.html b/tutorial/debug/layer-init/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/debug/layer-init/index.html +++ b/tutorial/debug/layer-init/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/debug/map-init/index.html b/tutorial/debug/map-init/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/debug/map-init/index.html +++ b/tutorial/debug/map-init/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/debug/render/index.html b/tutorial/debug/render/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/debug/render/index.html +++ b/tutorial/debug/render/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/demo/index.html b/tutorial/demo/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/demo/index.html +++ b/tutorial/demo/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/faq/index.html b/tutorial/faq/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/faq/index.html +++ b/tutorial/faq/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/heatmap/grid/index.html b/tutorial/heatmap/grid/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/heatmap/grid/index.html +++ b/tutorial/heatmap/grid/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/heatmap/hexagon/index.html b/tutorial/heatmap/hexagon/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/heatmap/hexagon/index.html +++ b/tutorial/heatmap/hexagon/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/heatmap/normal/index.html b/tutorial/heatmap/normal/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/heatmap/normal/index.html +++ b/tutorial/heatmap/normal/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/interactive/hightlight/index.html b/tutorial/interactive/hightlight/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/interactive/hightlight/index.html +++ b/tutorial/interactive/hightlight/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/l7/index.html b/tutorial/l7/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/l7/index.html +++ b/tutorial/l7/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/line/arc/index.html b/tutorial/line/arc/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/line/arc/index.html +++ b/tutorial/line/arc/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/line/arc3d/index.html b/tutorial/line/arc3d/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/line/arc3d/index.html +++ b/tutorial/line/arc3d/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/line/greatcircle/index.html b/tutorial/line/greatcircle/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/line/greatcircle/index.html +++ b/tutorial/line/greatcircle/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/line/path/index.html b/tutorial/line/path/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/line/path/index.html +++ b/tutorial/line/path/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/line/simple/index.html b/tutorial/line/simple/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/line/simple/index.html +++ b/tutorial/line/simple/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/line/wall/index.html b/tutorial/line/wall/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/line/wall/index.html +++ b/tutorial/line/wall/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/map/amap/index.html b/tutorial/map/amap/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/map/amap/index.html +++ b/tutorial/map/amap/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/map/amapplugin/index.html b/tutorial/map/amapplugin/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/map/amapplugin/index.html +++ b/tutorial/map/amapplugin/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/map/blankmap/index.html b/tutorial/map/blankmap/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/map/blankmap/index.html +++ b/tutorial/map/blankmap/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/map/leaflet/index.html b/tutorial/map/leaflet/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/map/leaflet/index.html +++ b/tutorial/map/leaflet/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/map/mapbox/index.html b/tutorial/map/mapbox/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/map/mapbox/index.html +++ b/tutorial/map/mapbox/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/map/offline/index.html b/tutorial/map/offline/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/map/offline/index.html +++ b/tutorial/map/offline/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/map/tianditu/index.html b/tutorial/map/tianditu/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/map/tianditu/index.html +++ b/tutorial/map/tianditu/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/mask/init/index.html b/tutorial/mask/init/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/mask/init/index.html +++ b/tutorial/mask/init/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/mask/option/index.html b/tutorial/mask/option/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/mask/option/index.html +++ b/tutorial/mask/option/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/mask/tile/index.html b/tutorial/mask/tile/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/mask/tile/index.html +++ b/tutorial/mask/tile/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/point/bubble/index.html b/tutorial/point/bubble/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/point/bubble/index.html +++ b/tutorial/point/bubble/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/point/chart/index.html b/tutorial/point/chart/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/point/chart/index.html +++ b/tutorial/point/chart/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/point/cluster/index.html b/tutorial/point/cluster/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/point/cluster/index.html +++ b/tutorial/point/cluster/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/point/column/index.html b/tutorial/point/column/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/point/column/index.html +++ b/tutorial/point/column/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/point/dot/index.html b/tutorial/point/dot/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/point/dot/index.html +++ b/tutorial/point/dot/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/point/iconfont/index.html b/tutorial/point/iconfont/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/point/iconfont/index.html +++ b/tutorial/point/iconfont/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/point/mark/index.html b/tutorial/point/mark/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/point/mark/index.html +++ b/tutorial/point/mark/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/point/radar/index.html b/tutorial/point/radar/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/point/radar/index.html +++ b/tutorial/point/radar/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/point/scatter/index.html b/tutorial/point/scatter/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/point/scatter/index.html +++ b/tutorial/point/scatter/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/point/simple/index.html b/tutorial/point/simple/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/point/simple/index.html +++ b/tutorial/point/simple/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/point/symbol/index.html b/tutorial/point/symbol/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/point/symbol/index.html +++ b/tutorial/point/symbol/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/point/text/index.html b/tutorial/point/text/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/point/text/index.html +++ b/tutorial/point/text/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/point/wave/index.html b/tutorial/point/wave/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/point/wave/index.html +++ b/tutorial/point/wave/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/polygon/extrude/index.html b/tutorial/polygon/extrude/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/polygon/extrude/index.html +++ b/tutorial/polygon/extrude/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/polygon/fill/index.html b/tutorial/polygon/fill/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/polygon/fill/index.html +++ b/tutorial/polygon/fill/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/polygon/water/index.html b/tutorial/polygon/water/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/polygon/water/index.html +++ b/tutorial/polygon/water/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/quickstart/index.html b/tutorial/quickstart/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/quickstart/index.html +++ b/tutorial/quickstart/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/scale/index.html b/tutorial/scale/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/scale/index.html +++ b/tutorial/scale/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/tile/raster-tile/index.html b/tutorial/tile/raster-tile/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/tile/raster-tile/index.html +++ b/tutorial/tile/raster-tile/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/tile/tile/index.html b/tutorial/tile/tile/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/tile/tile/index.html +++ b/tutorial/tile/tile/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/tutorial/tile/vector-tile/index.html b/tutorial/tile/vector-tile/index.html index 18f99f0c1c..b53b74429b 100644 --- a/tutorial/tile/vector-tile/index.html +++ b/tutorial/tile/vector-tile/index.html @@ -7,7 +7,7 @@
- + \ No newline at end of file diff --git a/umi.23579427.js b/umi.79ee5141.js similarity index 53% rename from umi.23579427.js rename to umi.79ee5141.js index 8705c25475..6dfcb26d67 100644 --- a/umi.23579427.js +++ b/umi.79ee5141.js @@ -1 +1 @@ -(function(){var __webpack_modules__={7684:function(e){"use strict";e.exports=function(){function e(e){var r=[];return e.AMapUI&&r.push(t(e.AMapUI)),e.Loca&&r.push(n(e.Loca)),Promise.all(r)}function t(e){return new Promise((function(t,n){var a=[];if(e.plugins)for(var l=0;l=60&&Math.round(e.h)<=240?n?Math.round(e.h)-2*t:Math.round(e.h)+2*t:n?Math.round(e.h)+2*t:Math.round(e.h)-2*t)<0?r+=360:r>=360&&(r-=360),r}function c(e,t,n){return 0===e.h&&0===e.s?e.s:((r=n?e.s-.16*t:4===t?e.s+.16:e.s+.05*t)>1&&(r=1),n&&5===t&&r>.1&&(r=.1),r<.06&&(r=.06),Number(r.toFixed(2)));var r}function d(e,t,n){var r;return(r=n?e.v+.05*t:e.v-.15*t)>1&&(r=1),Number(r.toFixed(2))}function p(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=[],r=(0,a.uA)(e),p=5;p>0;p-=1){var h=o(r),f=s((0,a.uA)({h:u(h,p,!0),s:c(h,p,!0),v:d(h,p,!0)}));n.push(f)}n.push(s(r));for(var v=1;v<=4;v+=1){var m=o(r),g=s((0,a.uA)({h:u(m,v),s:c(m,v),v:d(m,v)}));n.push(g)}return"dark"===t.theme?i.map((function(e){var r=e.index,i=e.opacity;return s(l((0,a.uA)(t.backgroundColor||"#141414"),(0,a.uA)(n[r]),100*i))})):n}var h={red:"#F5222D",volcano:"#FA541C",orange:"#FA8C16",gold:"#FAAD14",yellow:"#FADB14",lime:"#A0D911",green:"#52C41A",cyan:"#13C2C2",blue:"#1890FF",geekblue:"#2F54EB",purple:"#722ED1",magenta:"#EB2F96",grey:"#666666"},f={},v={};Object.keys(h).forEach((function(e){f[e]=p(h[e]),f[e].primary=f[e][5],v[e]=p(h[e],{theme:"dark",backgroundColor:"#141414"}),v[e].primary=v[e][5]}));f.red,f.volcano,f.gold,f.orange,f.yellow,f.lime,f.green,f.cyan,f.blue,f.geekblue,f.purple,f.magenta,f.grey},80367:function(e,t,n){"use strict";n.d(t,{Z:function(){return x}});var r=n(33028),a=n(76854),i=n(56666),o=n(99980),s=n(41398),l=n(72779),u=n.n(l),c=n(58838),d=n(4373),p=["icon","className","onClick","style","primaryColor","secondaryColor"],h={primaryColor:"#333",secondaryColor:"#E6E6E6",calculated:!1};var f=function(e){var t=e.icon,n=e.className,a=e.onClick,i=e.style,s=e.primaryColor,l=e.secondaryColor,u=(0,o.Z)(e,p),c=h;if(s&&(c={primaryColor:s,secondaryColor:l||(0,d.pw)(s)}),(0,d.C3)(),(0,d.Kp)((0,d.r)(t),"icon should be icon definiton, but got ".concat(t)),!(0,d.r)(t))return null;var f=t;return f&&"function"==typeof f.icon&&(f=(0,r.Z)((0,r.Z)({},f),{},{icon:f.icon(c.primaryColor,c.secondaryColor)})),(0,d.R_)(f.icon,"svg-".concat(f.name),(0,r.Z)({className:n,onClick:a,style:i,"data-icon":f.name,width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true"},u))};f.displayName="IconReact",f.getTwoToneColors=function(){return(0,r.Z)({},h)},f.setTwoToneColors=function(e){var t=e.primaryColor,n=e.secondaryColor;h.primaryColor=t,h.secondaryColor=n||(0,d.pw)(t),h.calculated=!!n};var v=f;function m(e){var t=(0,d.H9)(e),n=(0,a.Z)(t,2),r=n[0],i=n[1];return v.setTwoToneColors({primaryColor:r,secondaryColor:i})}var g=["className","icon","spin","rotate","tabIndex","onClick","twoToneColor"];m("#1890ff");var y=s.forwardRef((function(e,t){var n,l=e.className,p=e.icon,h=e.spin,f=e.rotate,m=e.tabIndex,y=e.onClick,x=e.twoToneColor,I=(0,o.Z)(e,g),_=s.useContext(c.Z),b=_.prefixCls,w=void 0===b?"anticon":b,S=_.rootClassName,E=u()(S,w,(n={},(0,i.Z)(n,"".concat(w,"-").concat(p.name),!!p.name),(0,i.Z)(n,"".concat(w,"-spin"),!!h||"loading"===p.name),n),l),C=m;void 0===C&&y&&(C=-1);var k=f?{msTransform:"rotate(".concat(f,"deg)"),transform:"rotate(".concat(f,"deg)")}:void 0,M=(0,d.H9)(x),T=(0,a.Z)(M,2),A=T[0],L=T[1];return s.createElement("span",(0,r.Z)((0,r.Z)({role:"img","aria-label":p.name},I),{},{ref:t,tabIndex:C,onClick:y,className:E}),s.createElement(v,{icon:p,primaryColor:A,secondaryColor:L,style:k}))}));y.displayName="AntdIcon",y.getTwoToneColor=function(){var e=v.getTwoToneColors();return e.calculated?[e.primaryColor,e.secondaryColor]:e.primaryColor},y.setTwoToneColor=m;var x=y},58838:function(e,t,n){"use strict";var r=(0,n(41398).createContext)({});t.Z=r},96813:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M872 474H286.9l350.2-304c5.6-4.9 2.2-14-5.2-14h-88.5c-3.9 0-7.6 1.4-10.5 3.9L155 487.8a31.96 31.96 0 000 48.3L535.1 866c1.5 1.3 3.3 2 5.2 2h91.5c7.4 0 10.8-9.2 5.2-14L286.9 550H872c4.4 0 8-3.6 8-8v-60c0-4.4-3.6-8-8-8z"}}]},name:"arrow-left",theme:"outlined"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="ArrowLeftOutlined";var l=a.forwardRef(s)},2622:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M869 487.8L491.2 159.9c-2.9-2.5-6.6-3.9-10.5-3.9h-88.5c-7.4 0-10.8 9.2-5.2 14l350.2 304H152c-4.4 0-8 3.6-8 8v60c0 4.4 3.6 8 8 8h585.1L386.9 854c-5.6 4.9-2.2 14 5.2 14h91.5c1.9 0 3.8-.7 5.2-2L869 536.2a32.07 32.07 0 000-48.4z"}}]},name:"arrow-right",theme:"outlined"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="ArrowRightOutlined";var l=a.forwardRef(s)},69344:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M840.4 300H183.6c-19.7 0-30.7 20.8-18.5 35l328.4 380.8c9.4 10.9 27.5 10.9 37 0L858.9 335c12.2-14.2 1.2-35-18.5-35z"}}]},name:"caret-down",theme:"filled"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="CaretDownFilled";var l=a.forwardRef(s)},5300:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm193.5 301.7l-210.6 292a31.8 31.8 0 01-51.7 0L318.5 484.9c-3.8-5.3 0-12.7 6.5-12.7h46.9c10.2 0 19.9 4.9 25.9 13.3l71.2 98.8 157.2-218c6-8.3 15.6-13.3 25.9-13.3H699c6.5 0 10.3 7.4 6.5 12.7z"}}]},name:"check-circle",theme:"filled"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="CheckCircleFilled";var l=a.forwardRef(s)},58433:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M699 353h-46.9c-10.2 0-19.9 4.9-25.9 13.3L469 584.3l-71.2-98.8c-6-8.3-15.6-13.3-25.9-13.3H325c-6.5 0-10.3 7.4-6.5 12.7l124.6 172.8a31.8 31.8 0 0051.7 0l210.6-292c3.9-5.3.1-12.7-6.4-12.7z"}},{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}}]},name:"check-circle",theme:"outlined"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="CheckCircleOutlined";var l=a.forwardRef(s)},68597:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M912 190h-69.9c-9.8 0-19.1 4.5-25.1 12.2L404.7 724.5 207 474a32 32 0 00-25.1-12.2H112c-6.7 0-10.4 7.7-6.3 12.9l273.9 347c12.8 16.2 37.4 16.2 50.3 0l488.4-618.9c4.1-5.1.4-12.8-6.3-12.8z"}}]},name:"check",theme:"outlined"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="CheckOutlined";var l=a.forwardRef(s)},52416:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm165.4 618.2l-66-.3L512 563.4l-99.3 118.4-66.1.3c-4.4 0-8-3.5-8-8 0-1.9.7-3.7 1.9-5.2l130.1-155L340.5 359a8.32 8.32 0 01-1.9-5.2c0-4.4 3.6-8 8-8l66.1.3L512 464.6l99.3-118.4 66-.3c4.4 0 8 3.5 8 8 0 1.9-.7 3.7-1.9 5.2L553.5 514l130 155c1.2 1.5 1.9 3.3 1.9 5.2 0 4.4-3.6 8-8 8z"}}]},name:"close-circle",theme:"filled"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="CloseCircleFilled";var l=a.forwardRef(s)},7253:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M685.4 354.8c0-4.4-3.6-8-8-8l-66 .3L512 465.6l-99.3-118.4-66.1-.3c-4.4 0-8 3.5-8 8 0 1.9.7 3.7 1.9 5.2l130.1 155L340.5 670a8.32 8.32 0 00-1.9 5.2c0 4.4 3.6 8 8 8l66.1-.3L512 564.4l99.3 118.4 66 .3c4.4 0 8-3.5 8-8 0-1.9-.7-3.7-1.9-5.2L553.5 515l130.1-155c1.2-1.4 1.8-3.3 1.8-5.2z"}},{tag:"path",attrs:{d:"M512 65C264.6 65 64 265.6 64 513s200.6 448 448 448 448-200.6 448-448S759.4 65 512 65zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}}]},name:"close-circle",theme:"outlined"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="CloseCircleOutlined";var l=a.forwardRef(s)},66522:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M563.8 512l262.5-312.9c4.4-5.2.7-13.1-6.1-13.1h-79.8c-4.7 0-9.2 2.1-12.3 5.7L511.6 449.8 295.1 191.7c-3-3.6-7.5-5.7-12.3-5.7H203c-6.8 0-10.5 7.9-6.1 13.1L459.4 512 196.9 824.9A7.95 7.95 0 00203 838h79.8c4.7 0 9.2-2.1 12.3-5.7l216.5-258.1 216.5 258.1c3 3.6 7.5 5.7 12.3 5.7h79.8c6.8 0 10.5-7.9 6.1-13.1L563.8 512z"}}]},name:"close",theme:"outlined"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="CloseOutlined";var l=a.forwardRef(s)},70788:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"}}]},name:"down",theme:"outlined"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="DownOutlined";var l=a.forwardRef(s)},40631:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M176 511a56 56 0 10112 0 56 56 0 10-112 0zm280 0a56 56 0 10112 0 56 56 0 10-112 0zm280 0a56 56 0 10112 0 56 56 0 10-112 0z"}}]},name:"ellipsis",theme:"outlined"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="EllipsisOutlined";var l=a.forwardRef(s)},32125:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm-32 232c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V296zm32 440a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"}}]},name:"exclamation-circle",theme:"filled"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="ExclamationCircleFilled";var l=a.forwardRef(s)},17088:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}},{tag:"path",attrs:{d:"M464 688a48 48 0 1096 0 48 48 0 10-96 0zm24-112h48c4.4 0 8-3.6 8-8V296c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8v272c0 4.4 3.6 8 8 8z"}}]},name:"exclamation-circle",theme:"outlined"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="ExclamationCircleOutlined";var l=a.forwardRef(s)},76534:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M942.2 486.2C847.4 286.5 704.1 186 512 186c-192.2 0-335.4 100.5-430.2 300.3a60.3 60.3 0 000 51.5C176.6 737.5 319.9 838 512 838c192.2 0 335.4-100.5 430.2-300.3 7.7-16.2 7.7-35 0-51.5zM512 766c-161.3 0-279.4-81.8-362.7-254C232.6 339.8 350.7 258 512 258c161.3 0 279.4 81.8 362.7 254C791.5 684.2 673.4 766 512 766zm-4-430c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm0 288c-61.9 0-112-50.1-112-112s50.1-112 112-112 112 50.1 112 112-50.1 112-112 112z"}}]},name:"eye",theme:"outlined"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="EyeOutlined";var l=a.forwardRef(s)},61745:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm32 664c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V456c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272zm-32-344a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"}}]},name:"info-circle",theme:"filled"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="InfoCircleFilled";var l=a.forwardRef(s)},16678:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}},{tag:"path",attrs:{d:"M464 336a48 48 0 1096 0 48 48 0 10-96 0zm72 112h-48c-4.4 0-8 3.6-8 8v272c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V456c0-4.4-3.6-8-8-8z"}}]},name:"info-circle",theme:"outlined"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="InfoCircleOutlined";var l=a.forwardRef(s)},97924:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M724 218.3V141c0-6.7-7.7-10.4-12.9-6.3L260.3 486.8a31.86 31.86 0 000 50.3l450.8 352.1c5.3 4.1 12.9.4 12.9-6.3v-77.3c0-4.9-2.3-9.6-6.1-12.6l-360-281 360-281.1c3.8-3 6.1-7.7 6.1-12.6z"}}]},name:"left",theme:"outlined"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="LeftOutlined";var l=a.forwardRef(s)},23698:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M988 548c-19.9 0-36-16.1-36-36 0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.3C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3.1 19.9-16 36-35.9 36z"}}]},name:"loading",theme:"outlined"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="LoadingOutlined";var l=a.forwardRef(s)},51287:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}},{tag:"path",attrs:{d:"M623.6 316.7C593.6 290.4 554 276 512 276s-81.6 14.5-111.6 40.7C369.2 344 352 380.7 352 420v7.6c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V420c0-44.1 43.1-80 96-80s96 35.9 96 80c0 31.1-22 59.6-56.1 72.7-21.2 8.1-39.2 22.3-52.1 40.9-13.1 19-19.9 41.8-19.9 64.9V620c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8v-22.7a48.3 48.3 0 0130.9-44.8c59-22.7 97.1-74.7 97.1-132.5.1-39.3-17.1-76-48.3-103.3zM472 732a40 40 0 1080 0 40 40 0 10-80 0z"}}]},name:"question-circle",theme:"outlined"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="QuestionCircleOutlined";var l=a.forwardRef(s)},73833:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M765.7 486.8L314.9 134.7A7.97 7.97 0 00302 141v77.3c0 4.9 2.3 9.6 6.1 12.6l360 281.1-360 281.1c-3.9 3-6.1 7.7-6.1 12.6V883c0 6.7 7.7 10.4 12.9 6.3l450.8-352.1a31.96 31.96 0 000-50.4z"}}]},name:"right",theme:"outlined"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="RightOutlined";var l=a.forwardRef(s)},34858:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M909.6 854.5L649.9 594.8C690.2 542.7 712 479 712 412c0-80.2-31.3-155.4-87.9-212.1-56.6-56.7-132-87.9-212.1-87.9s-155.5 31.3-212.1 87.9C143.2 256.5 112 331.8 112 412c0 80.1 31.3 155.5 87.9 212.1C256.5 680.8 331.8 712 412 712c67 0 130.6-21.8 182.7-62l259.7 259.6a8.2 8.2 0 0011.6 0l43.6-43.5a8.2 8.2 0 000-11.6zM570.4 570.4C528 612.7 471.8 636 412 636s-116-23.3-158.4-65.6C211.3 528 188 471.8 188 412s23.3-116.1 65.6-158.4C296 211.3 352.2 188 412 188s116.1 23.2 158.4 65.6S636 352.2 636 412s-23.3 116.1-65.6 158.4z"}}]},name:"search",theme:"outlined"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="SearchOutlined";var l=a.forwardRef(s)},57342:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(33028),a=n(41398),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M859.9 168H164.1c-4.5 0-8.1 3.6-8.1 8v60c0 4.4 3.6 8 8.1 8h695.8c4.5 0 8.1-3.6 8.1-8v-60c0-4.4-3.6-8-8.1-8zM518.3 355a8 8 0 00-12.6 0l-112 141.7a7.98 7.98 0 006.3 12.9h73.9V848c0 4.4 3.6 8 8 8h60c4.4 0 8-3.6 8-8V509.7H624c6.7 0 10.4-7.7 6.3-12.9L518.3 355z"}}]},name:"vertical-align-top",theme:"outlined"},o=n(80367),s=function(e,t){return a.createElement(o.Z,(0,r.Z)((0,r.Z)({},e),{},{ref:t,icon:i}))};s.displayName="VerticalAlignTopOutlined";var l=a.forwardRef(s)},4373:function(e,t,n){"use strict";n.d(t,{C3:function(){return y},H9:function(){return v},Kp:function(){return c},R_:function(){return h},pw:function(){return f},r:function(){return d},vD:function(){return m}});var r=n(33028),a=n(86522),i=n(1139),o=n(41398),s=n(72895),l=n(13167),u=n(58838);function c(e,t){(0,s.ZP)(e,"[@ant-design/icons] ".concat(t))}function d(e){return"object"===(0,a.Z)(e)&&"string"==typeof e.name&&"string"==typeof e.theme&&("object"===(0,a.Z)(e.icon)||"function"==typeof e.icon)}function p(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return Object.keys(e).reduce((function(t,n){var r=e[n];if("class"===n)t.className=r,delete t.class;else t[n]=r;return t}),{})}function h(e,t,n){return n?o.createElement(e.tag,(0,r.Z)((0,r.Z)({key:t},p(e.attrs)),n),(e.children||[]).map((function(n,r){return h(n,"".concat(t,"-").concat(e.tag,"-").concat(r))}))):o.createElement(e.tag,(0,r.Z)({key:t},p(e.attrs)),(e.children||[]).map((function(n,r){return h(n,"".concat(t,"-").concat(e.tag,"-").concat(r))})))}function f(e){return(0,i.R_)(e)[0]}function v(e){return e?Array.isArray(e)?e:[e]:[]}var m={width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true",focusable:"false"},g="\n.anticon {\n display: inline-block;\n color: inherit;\n font-style: normal;\n line-height: 0;\n text-align: center;\n text-transform: none;\n vertical-align: -0.125em;\n text-rendering: optimizeLegibility;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n}\n\n.anticon > * {\n line-height: 1;\n}\n\n.anticon svg {\n display: inline-block;\n}\n\n.anticon::before {\n display: none;\n}\n\n.anticon .anticon-icon {\n display: block;\n}\n\n.anticon[tabindex] {\n cursor: pointer;\n}\n\n.anticon-spin::before,\n.anticon-spin {\n display: inline-block;\n -webkit-animation: loadingCircle 1s infinite linear;\n animation: loadingCircle 1s infinite linear;\n}\n\n@-webkit-keyframes loadingCircle {\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n\n@keyframes loadingCircle {\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n",y=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:g,t=(0,o.useContext)(u.Z),n=t.csp;(0,o.useEffect)((function(){(0,l.hq)(e,"@ant-design-icons",{prepend:!0,csp:n})}),[])}},68160:function(e,t,n){"use strict";n.d(t,{S$:function(){return q},bf:function(){return W},ni:function(){return F},oI:function(){return H},sX:function(){return G}});var r=n(34406);function a(e,t,n,r){return new(n||(n=Promise))((function(a,i){function o(e){try{l(r.next(e))}catch(e){i(e)}}function s(e){try{l(r.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?a(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(o,s)}l((r=r.apply(e,t||[])).next())}))}function i(e,t){var n,r,a,i,o={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;o;)try{if(n=1,r&&(a=2&i[0]?r.return:i[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,i[1])).done)return a;switch(r=0,a&&(i=[2&i[0],a.value]),i[0]){case 0:case 1:a=i;break;case 4:return o.label++,{value:i[1],done:!1};case 5:o.label++,r=i[1],i=[0];continue;case 7:i=o.ops.pop(),o.trys.pop();continue;default:if(!(a=o.trys,(a=a.length>0&&a[a.length-1])||6!==i[0]&&2!==i[0])){o=0;continue}if(3===i[0]&&(!a||i[1]>a[0]&&i[1]0)&&!(r=i.next()).done;)o.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(a)throw a.error}}return o}function s(e,t,n){if(n||2===arguments.length)for(var r,a=0,i=t.length;a=0&&e.length%1==0},u.exports=c.default;var f={},v={exports:{}},m={exports:{}};!function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return function(){for(var t=[],n=arguments.length;n--;)t[n]=arguments[n];var r=t.pop();return e.call(this,t,r)}},e.exports=t.default}(m,m.exports);var g={};Object.defineProperty(g,"__esModule",{value:!0}),g.fallback=b,g.wrap=w;var y,x=g.hasQueueMicrotask="function"==typeof queueMicrotask&&queueMicrotask,I=g.hasSetImmediate="function"==typeof setImmediate&&setImmediate,_=g.hasNextTick="object"==typeof r&&"function"==typeof r.nextTick;function b(e){setTimeout(e,0)}function w(e){return function(t){for(var n=[],r=arguments.length-1;r-- >0;)n[r]=arguments[r+1];return e((function(){return t.apply(void 0,n)}))}}y=x?queueMicrotask:I?setImmediate:_?r.nextTick:b,g.default=w(y),function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){if((0,a.isAsync)(e))return function(){for(var t=[],n=arguments.length;n--;)t[n]=arguments[n];var r=t.pop(),a=e.apply(this,t);return o(a,r)};return(0,n.default)((function(t,n){var r;try{r=e.apply(this,t)}catch(e){return n(e)}if(r&&"function"==typeof r.then)return o(r,n);n(null,r)}))};var n=i(m.exports),r=i(g),a=f;function i(e){return e&&e.__esModule?e:{default:e}}function o(e,t){return e.then((function(e){s(t,null,e)}),(function(e){s(t,e&&e.message?e:new Error(e))}))}function s(e,t,n){try{e(t,n)}catch(e){(0,r.default)((function(e){throw e}),e)}}e.exports=t.default}(v,v.exports),Object.defineProperty(f,"__esModule",{value:!0}),f.isAsyncIterable=f.isAsyncGenerator=f.isAsync=void 0;var S,E=(S=v.exports)&&S.__esModule?S:{default:S};function C(e){return"AsyncFunction"===e[Symbol.toStringTag]}f.default=function(e){if("function"!=typeof e)throw new Error("expected a function");return C(e)?(0,E.default)(e):e},f.isAsync=C,f.isAsyncGenerator=function(e){return"AsyncGenerator"===e[Symbol.toStringTag]},f.isAsyncIterable=function(e){return"function"==typeof e[Symbol.asyncIterator]};var k={exports:{}};!function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){void 0===t&&(t=e.length);if(!t)throw new Error("arity is undefined");return function(){for(var n=this,r=[],a=arguments.length;a--;)r[a]=arguments[a];return"function"==typeof r[t-1]?e.apply(this,r):new Promise((function(a,i){r[t-1]=function(e){for(var t=[],n=arguments.length-1;n-- >0;)t[n]=arguments[n+1];if(e)return i(e);a(t.length>1?t:t[0])},e.apply(n,r)}))}},e.exports=t.default}(k,k.exports),function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=i(h.exports),r=i(f),a=i(k.exports);function i(e){return e&&e.__esModule?e:{default:e}}t.default=(0,a.default)((function(e,t,a){var i=(0,n.default)(t)?[]:{};e(t,(function(e,t,n){(0,r.default)(e)((function(e){for(var r=[],a=arguments.length-1;a-- >0;)r[a]=arguments[a+1];r.length<2&&(r=r[0]),i[t]=r,n(e)}))}),(function(e){return a(e,i)}))}),3),e.exports=t.default}(p,p.exports);var M={exports:{}},T={exports:{}},A={exports:{}},L={exports:{}};!function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){function t(){for(var t=[],n=arguments.length;n--;)t[n]=arguments[n];if(null!==e){var r=e;e=null,r.apply(this,t)}}return Object.assign(t,e),t},e.exports=t.default}(L,L.exports);var P={exports:{}},O={exports:{}};!function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return e[Symbol.iterator]&&e[Symbol.iterator]()},e.exports=t.default}(O,O.exports),function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){if((0,n.default)(e))return function(e){var t=-1,n=e.length;return function(){return++t=t||s||i||(s=!0,e.next().then((function(e){var t=e.value,n=e.done;if(!o&&!i){if(s=!1,n)return i=!0,void(l<=0&&a(null));l++,r(t,u,d),u++,c()}})).catch(p))}function d(e,t){if(l-=1,!o)return e?p(e):!1===e?(i=!0,void(o=!0)):t===n.default||i&&l<=0?(i=!0,a(null)):void c()}function p(e){o||(s=!1,i=!0,a(e))}c()};var n=function(e){return e&&e.__esModule?e:{default:e}}(N.exports);e.exports=t.default}(D,D.exports),function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=l(L.exports),r=l(P.exports),a=l(R.exports),i=f,o=l(D.exports),s=l(N.exports);function l(e){return e&&e.__esModule?e:{default:e}}t.default=function(e){return function(t,l,u){if(u=(0,n.default)(u),e<=0)throw new RangeError("concurrency limit cannot be less than 1");if(!t)return u(null);if((0,i.isAsyncGenerator)(t))return(0,o.default)(t,e,l,u);if((0,i.isAsyncIterable)(t))return(0,o.default)(t[Symbol.asyncIterator](),e,l,u);var c=(0,r.default)(t),d=!1,p=!1,h=0,f=!1;function v(e,t){if(!p)if(h-=1,e)d=!0,u(e);else if(!1===e)d=!0,p=!0;else{if(t===s.default||d&&h<=0)return d=!0,u(null);f||m()}}function m(){for(f=!0;h0;)r[a]=arguments[a+1];if(!1!==n)return n||i===e.length?t.apply(void 0,[n].concat(r)):void o(r)}o([])})),e.exports=t.default}(U,U.exports);var V=l(U.exports),H=(function(){function e(){this.tasks=[]}e.prototype.call=function(){return V(this.tasks)},e.prototype.tap=function(e,t){0===this.tasks.length?this.tasks.push((function(e){var n=t();e(!!n&&null,n)})):this.tasks.push((function(n,r){r(!!t.apply(void 0,s([],o(n),!1))&&null,e)}))}}(),function(){function e(){this.tasks=[]}return e.prototype.call=function(){return z(this.tasks)},e.prototype.tap=function(e,t){this.tasks.push((function(n){n(t(),e)}))},e}()),G=function(){function e(){this.args=[],this.tasks=[]}return e.prototype.promise=function(){for(var e=arguments,t=[],n=0;n]*>/,o={tr:document.createElement("tbody"),tbody:r,thead:r,tfoot:r,td:a,th:a,"*":document.createElement("div")});var t=i.test(e)&&RegExp.$1;t&&t in o||(t="*");var n=o[t];e="string"==typeof e?e.replace(/(^\s*)|(\s*$)/g,""):e,n.innerHTML=""+e;var s=n.childNodes[0];return s&&n.contains(s)&&n.removeChild(s),s}n.d(t,{Z:function(){return s}})},66767:function(e,t,n){"use strict";function r(e,t){if(e)for(var n in t)t.hasOwnProperty(n)&&(e.style[n]=t[n]);return e}n.d(t,{Z:function(){return r}})},89331:function(e,t){"use strict";var n=function(){function e(){this._events={}}return e.prototype.on=function(e,t,n){return this._events[e]||(this._events[e]=[]),this._events[e].push({callback:t,once:!!n}),this},e.prototype.once=function(e,t){return this.on(e,t,!0)},e.prototype.emit=function(e){for(var t=this,n=[],r=1;r=0&&t._call.call(null,e),t=t._next;--c}()}finally{c=0,function(){var e,t,n=r,i=1/0;for(;n;)n._call?(i>n._time&&(i=n._time),e=n,n=n._next):(t=n._next,n._next=null,n=e?e._next=t:r=t);a=e,S(i)}(),f=0}}function w(){var e=m.now(),t=e-h;t>1e3&&(v-=t,h=e)}function S(e){c||(d&&(d=clearTimeout(d)),e-f>24?(e<1/0&&(d=setTimeout(b,e-m.now()-v)),p&&(p=clearInterval(p))):(p||(h=m.now(),p=setInterval(w,1e3)),c=1,g(b)))}I.prototype=_.prototype={constructor:I,restart:function(e,t,n){if("function"!=typeof e)throw new TypeError("callback is not a function");n=(null==n?y():+n)+(null==t?0:+t),this._next||a===this||(a?a._next=this:r=this,a=this),this._call=e,this._time=n,S()},stop:function(){this._call&&(this._call=null,this._time=1/0,S())}};var E=n(67425);function C(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function k(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function M(){}var T=.7,A=1/T,L="\\s*([+-]?\\d+)\\s*",P="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",O="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",R=/^#([0-9a-f]{3,8})$/,D=new RegExp("^rgb\\(".concat(L,",").concat(L,",").concat(L,"\\)$")),N=new RegExp("^rgb\\(".concat(O,",").concat(O,",").concat(O,"\\)$")),z=new RegExp("^rgba\\(".concat(L,",").concat(L,",").concat(L,",").concat(P,"\\)$")),F=new RegExp("^rgba\\(".concat(O,",").concat(O,",").concat(O,",").concat(P,"\\)$")),B=new RegExp("^hsl\\(".concat(P,",").concat(O,",").concat(O,"\\)$")),j=new RegExp("^hsla\\(".concat(P,",").concat(O,",").concat(O,",").concat(P,"\\)$")),Z={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function U(){return this.rgb().formatHex()}function V(){return this.rgb().formatRgb()}function H(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=R.exec(e))?(n=t[1].length,t=parseInt(t[1],16),6===n?G(t):3===n?new X(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===n?q(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===n?q(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|240&t,((15&t)<<4|15&t)/255):null):(t=D.exec(e))?new X(t[1],t[2],t[3],1):(t=N.exec(e))?new X(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=z.exec(e))?q(t[1],t[2],t[3],t[4]):(t=F.exec(e))?q(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=B.exec(e))?te(t[1],t[2]/100,t[3]/100,1):(t=j.exec(e))?te(t[1],t[2]/100,t[3]/100,t[4]):Z.hasOwnProperty(e)?G(Z[e]):"transparent"===e?new X(NaN,NaN,NaN,0):null}function G(e){return new X(e>>16&255,e>>8&255,255&e,1)}function q(e,t,n,r){return r<=0&&(e=t=n=NaN),new X(e,t,n,r)}function W(e){return e instanceof M||(e=H(e)),e?new X((e=e.rgb()).r,e.g,e.b,e.opacity):new X}function Y(e,t,n,r){return 1===arguments.length?W(e):new X(e,t,n,null==r?1:r)}function X(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}function K(){return"#".concat(ee(this.r)).concat(ee(this.g)).concat(ee(this.b))}function J(){var e=$(this.opacity);return"".concat(1===e?"rgb(":"rgba(").concat(Q(this.r),", ").concat(Q(this.g),", ").concat(Q(this.b)).concat(1===e?")":", ".concat(e,")"))}function $(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Q(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function ee(e){return((e=Q(e))<16?"0":"")+e.toString(16)}function te(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new re(e,t,n,r)}function ne(e){if(e instanceof re)return new re(e.h,e.s,e.l,e.opacity);if(e instanceof M||(e=H(e)),!e)return new re;if(e instanceof re)return e;var t=(e=e.rgb()).r/255,n=e.g/255,r=e.b/255,a=Math.min(t,n,r),i=Math.max(t,n,r),o=NaN,s=i-a,l=(i+a)/2;return s?(o=t===i?(n-r)/s+6*(n0&&l<1?0:o,new re(o,s,l,e.opacity)}function re(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function ae(e){return(e=(e||0)%360)<0?e+360:e}function ie(e){return Math.max(0,Math.min(1,e||0))}function oe(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}function se(e,t,n,r,a){var i=e*e,o=i*e;return((1-3*e+3*i-o)*t+(4-6*i+3*o)*n+(1+3*e+3*i-3*o)*r+o*a)/6}C(M,H,{copy:function(e){return Object.assign(new this.constructor,this,e)},displayable:function(){return this.rgb().displayable()},hex:U,formatHex:U,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return ne(this).formatHsl()},formatRgb:V,toString:V}),C(X,Y,k(M,{brighter:function(e){return e=null==e?A:Math.pow(A,e),new X(this.r*e,this.g*e,this.b*e,this.opacity)},darker:function(e){return e=null==e?T:Math.pow(T,e),new X(this.r*e,this.g*e,this.b*e,this.opacity)},rgb:function(){return this},clamp:function(){return new X(Q(this.r),Q(this.g),Q(this.b),$(this.opacity))},displayable:function(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:K,formatHex:K,formatHex8:function(){return"#".concat(ee(this.r)).concat(ee(this.g)).concat(ee(this.b)).concat(ee(255*(isNaN(this.opacity)?1:this.opacity)))},formatRgb:J,toString:J})),C(re,(function(e,t,n,r){return 1===arguments.length?ne(e):new re(e,t,n,null==r?1:r)}),k(M,{brighter:function(e){return e=null==e?A:Math.pow(A,e),new re(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=null==e?T:Math.pow(T,e),new re(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,a=2*n-r;return new X(oe(e>=240?e-240:e+120,a,r),oe(e,a,r),oe(e<120?e+240:e-120,a,r),this.opacity)},clamp:function(){return new re(ae(this.h),ie(this.s),ie(this.l),$(this.opacity))},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var e=$(this.opacity);return"".concat(1===e?"hsl(":"hsla(").concat(ae(this.h),", ").concat(100*ie(this.s),"%, ").concat(100*ie(this.l),"%").concat(1===e?")":", ".concat(e,")"))}}));var le=function(e){return function(){return e}};function ue(e,t){return function(n){return e+n*t}}function ce(e){return 1==(e=+e)?de:function(t,n){return n-t?function(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}(t,n,e):le(isNaN(t)?n:t)}}function de(e,t){var n=t-e;return n?ue(e,n):le(isNaN(e)?t:e)}var pe=function e(t){var n=ce(t);function r(e,t){var r=n((e=Y(e)).r,(t=Y(t)).r),a=n(e.g,t.g),i=n(e.b,t.b),o=de(e.opacity,t.opacity);return function(t){return e.r=r(t),e.g=a(t),e.b=i(t),e.opacity=o(t),e+""}}return r.gamma=e,r}(1);function he(e){return function(t){var n,r,a=t.length,i=new Array(a),o=new Array(a),s=new Array(a);for(n=0;n=1?(n=1,t-1):Math.floor(n*t),a=e[r],i=e[r+1],o=r>0?e[r-1]:2*a-i,s=ri&&(a=t.slice(i,a),s[o]?s[o]+=a:s[++o]=a),(n=n[0])===(r=r[0])?s[o]?s[o]+=r:s[++o]=r:(s[++o]=null,l.push({i:o,x:ye(n,r)})),i=_e.lastIndex;return ih.length?(p=Ee.parsePathString(i[d]),h=Ee.parsePathString(a[d]),h=Ee.fillPathByDiff(h,p),h=Ee.formatPath(h,p),t.fromAttrs.path=h,t.toAttrs.path=p):t.pathFormatted||(p=Ee.parsePathString(i[d]),h=Ee.parsePathString(a[d]),h=Ee.formatPath(h,p),t.fromAttrs.path=h,t.toAttrs.path=p,t.pathFormatted=!0),r[d]=[];for(var f=0;f0){for(var i=r.animators.length-1;i>=0;i--)if((e=r.animators[i]).destroyed)r.removeAnimator(i);else{if(!e.isAnimatePaused())for(var o=(t=e.get("animations")).length-1;o>=0;o--)n=t[o],ke(e,n,a)&&(t.splice(o,1),!1,n.callback&&n.callback());0===t.length&&r.removeAnimator(i)}r.canvas.get("autoDraw")||r.canvas.draw()}}))},e.prototype.addAnimator=function(e){this.animators.push(e)},e.prototype.removeAnimator=function(e){this.animators.splice(e,1)},e.prototype.isAnimating=function(){return!!this.animators.length},e.prototype.stop=function(){this.timer&&this.timer.stop()},e.prototype.stopAllAnimations=function(e){void 0===e&&(e=!0),this.animators.forEach((function(t){t.stopAnimate(e)})),this.animators=[],this.canvas.draw()},e.prototype.getTime=function(){return this.current},e}(),Te=Me,Ae=n(93296),Le=["mousedown","mouseup","dblclick","mouseout","mouseover","mousemove","mouseleave","mouseenter","touchstart","touchmove","touchend","dragenter","dragover","dragleave","drop","contextmenu","mousewheel"];function Pe(e,t,n){n.name=t,n.target=e,n.currentTarget=e,n.delegateTarget=e,e.emit(t,n)}function Oe(e,t,n){if(n.bubbles){var r=void 0,a=!1;if("mouseenter"===t?(r=n.fromShape,a=!0):"mouseleave"===t&&(a=!0,r=n.toShape),e.isCanvas()&&a)return;if(r&&(0,l.UY)(e,r))return void(n.bubbles=!1);n.name=t,n.currentTarget=e,n.delegateTarget=e,e.emit(t,n)}}var Re=function(){function e(e){var t=this;this.draggingShape=null,this.dragging=!1,this.currentShape=null,this.mousedownShape=null,this.mousedownPoint=null,this._eventCallback=function(e){var n=e.type;t._triggerEvent(n,e)},this._onDocumentMove=function(e){if(t.canvas.get("el")!==e.target&&(t.dragging||t.currentShape)){var n=t._getPointInfo(e);t.dragging&&t._emitEvent("drag",e,n,t.draggingShape)}},this._onDocumentMouseUp=function(e){if(t.canvas.get("el")!==e.target&&t.dragging){var n=t._getPointInfo(e);t.draggingShape&&t._emitEvent("drop",e,n,null),t._emitEvent("dragend",e,n,t.draggingShape),t._afterDrag(t.draggingShape,n,e)}},this.canvas=e.canvas}return e.prototype.init=function(){this._bindEvents()},e.prototype._bindEvents=function(){var e=this,t=this.canvas.get("el");(0,l.S6)(Le,(function(n){t.addEventListener(n,e._eventCallback)})),document&&(document.addEventListener("mousemove",this._onDocumentMove),document.addEventListener("mouseup",this._onDocumentMouseUp))},e.prototype._clearEvents=function(){var e=this,t=this.canvas.get("el");(0,l.S6)(Le,(function(n){t.removeEventListener(n,e._eventCallback)})),document&&(document.removeEventListener("mousemove",this._onDocumentMove),document.removeEventListener("mouseup",this._onDocumentMouseUp))},e.prototype._getEventObj=function(e,t,n,r,a,i){var o=new Ae.Z(e,t);return o.fromShape=a,o.toShape=i,o.x=n.x,o.y=n.y,o.clientX=n.clientX,o.clientY=n.clientY,o.propagationPath.push(r),o},e.prototype._getShape=function(e,t){return this.canvas.getShape(e.x,e.y,t)},e.prototype._getPointInfo=function(e){var t=this.canvas,n=t.getClientByEvent(e),r=t.getPointByEvent(e);return{x:r.x,y:r.y,clientX:n.x,clientY:n.y}},e.prototype._triggerEvent=function(e,t){var n=this._getPointInfo(t),r=this._getShape(n,t),a=this["_on"+e],i=!1;if(a)a.call(this,n,r,t);else{var o=this.currentShape;"mouseenter"===e||"dragenter"===e||"mouseover"===e?(this._emitEvent(e,t,n,null,null,r),r&&this._emitEvent(e,t,n,r,null,r),"mouseenter"===e&&this.draggingShape&&this._emitEvent("dragenter",t,n,null)):"mouseleave"===e||"dragleave"===e||"mouseout"===e?(i=!0,o&&this._emitEvent(e,t,n,o,o,null),this._emitEvent(e,t,n,null,o,null),"mouseleave"===e&&this.draggingShape&&this._emitEvent("dragleave",t,n,null)):this._emitEvent(e,t,n,r,null,null)}if(i||(this.currentShape=r),r&&!r.get("destroyed")){var s=this.canvas;s.get("el").style.cursor=r.attr("cursor")||s.get("cursor")}},e.prototype._onmousedown=function(e,t,n){0===n.button&&(this.mousedownShape=t,this.mousedownPoint=e,this.mousedownTimeStamp=n.timeStamp),this._emitEvent("mousedown",n,e,t,null,null)},e.prototype._emitMouseoverEvents=function(e,t,n,r){var a=this.canvas.get("el");n!==r&&(n&&(this._emitEvent("mouseout",e,t,n,n,r),this._emitEvent("mouseleave",e,t,n,n,r),r&&!r.get("destroyed")||(a.style.cursor=this.canvas.get("cursor"))),r&&(this._emitEvent("mouseover",e,t,r,n,r),this._emitEvent("mouseenter",e,t,r,n,r)))},e.prototype._emitDragoverEvents=function(e,t,n,r,a){r?(r!==n&&(n&&this._emitEvent("dragleave",e,t,n,n,r),this._emitEvent("dragenter",e,t,r,n,r)),a||this._emitEvent("dragover",e,t,r)):n&&this._emitEvent("dragleave",e,t,n,n,r),a&&this._emitEvent("dragover",e,t,r)},e.prototype._afterDrag=function(e,t,n){e&&(e.set("capture",!0),this.draggingShape=null),this.dragging=!1;var r=this._getShape(t,n);r!==e&&this._emitMouseoverEvents(n,t,e,r),this.currentShape=r},e.prototype._onmouseup=function(e,t,n){if(0===n.button){var r=this.draggingShape;this.dragging?(r&&this._emitEvent("drop",n,e,t),this._emitEvent("dragend",n,e,r),this._afterDrag(r,e,n)):(this._emitEvent("mouseup",n,e,t),t===this.mousedownShape&&this._emitEvent("click",n,e,t),this.mousedownShape=null,this.mousedownPoint=null)}},e.prototype._ondragover=function(e,t,n){n.preventDefault();var r=this.currentShape;this._emitDragoverEvents(n,e,r,t,!0)},e.prototype._onmousemove=function(e,t,n){var r=this.canvas,a=this.currentShape,i=this.draggingShape;if(this.dragging)i&&this._emitDragoverEvents(n,e,a,t,!1),this._emitEvent("drag",n,e,i);else{var o=this.mousedownPoint;if(o){var s=this.mousedownShape,l=n.timeStamp-this.mousedownTimeStamp,u=o.clientX-e.clientX,c=o.clientY-e.clientY;l>120||u*u+c*c>40?s&&s.get("draggable")?((i=this.mousedownShape).set("capture",!1),this.draggingShape=i,this.dragging=!0,this._emitEvent("dragstart",n,e,i),this.mousedownShape=null,this.mousedownPoint=null):!s&&r.get("draggable")?(this.dragging=!0,this._emitEvent("dragstart",n,e,null),this.mousedownShape=null,this.mousedownPoint=null):(this._emitMouseoverEvents(n,e,a,t),this._emitEvent("mousemove",n,e,t)):(this._emitMouseoverEvents(n,e,a,t),this._emitEvent("mousemove",n,e,t))}else this._emitMouseoverEvents(n,e,a,t),this._emitEvent("mousemove",n,e,t)}},e.prototype._emitEvent=function(e,t,n,r,a,i){var o=this._getEventObj(e,t,n,r,a,i);if(r){o.shape=r,Pe(r,e,o);for(var s=r.getParent();s;)s.emitDelegation(e,o),o.propagationStopped||Oe(s,e,o),o.propagationPath.push(s),s=s.getParent()}else{Pe(this.canvas,e,o)}},e.prototype.destroy=function(){this._clearEvents(),this.canvas=null,this.currentShape=null,this.draggingShape=null,this.mousedownPoint=null,this.mousedownShape=null,this.mousedownTimeStamp=null},e}(),De=Re,Ne=(0,o.qY)(),ze=Ne&&"firefox"===Ne.name,Fe=function(e){function t(t){var n=e.call(this,t)||this;return n.initContainer(),n.initDom(),n.initEvents(),n.initTimeline(),n}return(0,i.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return t.cursor="default",t.supportCSSTransform=!1,t},t.prototype.initContainer=function(){var e=this.get("container");(0,l.HD)(e)&&(e=document.getElementById(e),this.set("container",e))},t.prototype.initDom=function(){var e=this.createDom();this.set("el",e),this.get("container").appendChild(e),this.setDOMSize(this.get("width"),this.get("height"))},t.prototype.initEvents=function(){var e=new De({canvas:this});e.init(),this.set("eventController",e)},t.prototype.initTimeline=function(){var e=new Te(this);this.set("timeline",e)},t.prototype.setDOMSize=function(e,t){var n=this.get("el");l.jU&&(n.style.width=e+"px",n.style.height=t+"px")},t.prototype.changeSize=function(e,t){this.setDOMSize(e,t),this.set("width",e),this.set("height",t),this.onCanvasChange("changeSize")},t.prototype.getRenderer=function(){return this.get("renderer")},t.prototype.getCursor=function(){return this.get("cursor")},t.prototype.setCursor=function(e){this.set("cursor",e);var t=this.get("el");l.jU&&t&&(t.style.cursor=e)},t.prototype.getPointByEvent=function(e){if(this.get("supportCSSTransform")){if(ze&&!(0,l.kK)(e.layerX)&&e.layerX!==e.offsetX)return{x:e.layerX,y:e.layerY};if(!(0,l.kK)(e.offsetX))return{x:e.offsetX,y:e.offsetY}}var t=this.getClientByEvent(e),n=t.x,r=t.y;return this.getPointByClient(n,r)},t.prototype.getClientByEvent=function(e){var t=e;return e.touches&&(t="touchend"===e.type?e.changedTouches[0]:e.touches[0]),{x:t.clientX,y:t.clientY}},t.prototype.getPointByClient=function(e,t){var n=this.get("el").getBoundingClientRect();return{x:e-n.left,y:t-n.top}},t.prototype.getClientByPoint=function(e,t){var n=this.get("el").getBoundingClientRect();return{x:e+n.left,y:t+n.top}},t.prototype.draw=function(){},t.prototype.removeDom=function(){var e=this.get("el");e.parentNode.removeChild(e)},t.prototype.clearEvents=function(){this.get("eventController").destroy()},t.prototype.isCanvas=function(){return!0},t.prototype.getParent=function(){return null},t.prototype.destroy=function(){var t=this.get("timeline");this.get("destroyed")||(this.clear(),t&&t.stop(),this.clearEvents(),this.removeDom(),e.prototype.destroy.call(this))},t}(s.Z),Be=Fe},20218:function(e,t,n){"use strict";var r=n(5163),a=n(83677),i=n(95835),o=n(11838),s={},l="_INDEX";function u(e,t){if(e.set("canvas",t),e.isGroup()){var n=e.get("children");n.length&&n.forEach((function(e){u(e,t)}))}}function c(e,t){if(e.set("timeline",t),e.isGroup()){var n=e.get("children");n.length&&n.forEach((function(e){c(e,t)}))}}var d=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,r.ZT)(t,e),t.prototype.isCanvas=function(){return!1},t.prototype.getBBox=function(){var e=1/0,t=-1/0,n=1/0,r=-1/0,i=[],s=[],l=this.getChildren().filter((function(e){return e.get("visible")&&(!e.isGroup()||e.isGroup()&&e.getChildren().length>0)}));return l.length>0?((0,o.S6)(l,(function(e){var t=e.getBBox();i.push(t.minX,t.maxX),s.push(t.minY,t.maxY)})),e=(0,a.VV)(i),t=(0,a.Fp)(i),n=(0,a.VV)(s),r=(0,a.Fp)(s)):(e=0,t=0,n=0,r=0),{x:e,y:n,minX:e,minY:n,maxX:t,maxY:r,width:t-e,height:r-n}},t.prototype.getCanvasBBox=function(){var e=1/0,t=-1/0,n=1/0,r=-1/0,i=[],s=[],l=this.getChildren().filter((function(e){return e.get("visible")&&(!e.isGroup()||e.isGroup()&&e.getChildren().length>0)}));return l.length>0?((0,o.S6)(l,(function(e){var t=e.getCanvasBBox();i.push(t.minX,t.maxX),s.push(t.minY,t.maxY)})),e=(0,a.VV)(i),t=(0,a.Fp)(i),n=(0,a.VV)(s),r=(0,a.Fp)(s)):(e=0,t=0,n=0,r=0),{x:e,y:n,minX:e,minY:n,maxX:t,maxY:r,width:t-e,height:r-n}},t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return t.children=[],t},t.prototype.onAttrChange=function(t,n,r){if(e.prototype.onAttrChange.call(this,t,n,r),"matrix"===t){var a=this.getTotalMatrix();this._applyChildrenMarix(a)}},t.prototype.applyMatrix=function(t){var n=this.getTotalMatrix();e.prototype.applyMatrix.call(this,t);var r=this.getTotalMatrix();r!==n&&this._applyChildrenMarix(r)},t.prototype._applyChildrenMarix=function(e){var t=this.getChildren();(0,o.S6)(t,(function(t){t.applyMatrix(e)}))},t.prototype.addShape=function(){for(var e=[],t=0;t=0;i--){var s=e[i];if((0,o.pP)(s)&&(s.isGroup()?a=s.getShape(t,n,r):s.isHit(t,n)&&(a=s)),a)break}return a},t.prototype.add=function(e){var t=this.getCanvas(),n=this.getChildren(),r=this.get("timeline"),a=e.getParent();a&&function(e,t,n){void 0===n&&(n=!0),n?t.destroy():(t.set("parent",null),t.set("canvas",null)),(0,o.As)(e.getChildren(),t)}(a,e,!1),e.set("parent",this),t&&u(e,t),r&&c(e,r),n.push(e),e.onCanvasChange("add"),this._applyElementMatrix(e)},t.prototype._applyElementMatrix=function(e){var t=this.getTotalMatrix();t&&e.applyMatrix(t)},t.prototype.getChildren=function(){return this.get("children")},t.prototype.sort=function(){var e,t=this.getChildren();(0,o.S6)(t,(function(e,t){return e[l]=t,e})),t.sort((e=function(e,t){return e.get("zIndex")-t.get("zIndex")},function(t,n){var r=e(t,n);return 0===r?t[l]-n[l]:r})),this.onCanvasChange("sort")},t.prototype.clear=function(){if(this.set("clearing",!0),!this.destroyed){for(var e=this.getChildren(),t=e.length-1;t>=0;t--)e[t].destroy();this.set("children",[]),this.onCanvasChange("clear"),this.set("clearing",!1)}},t.prototype.destroy=function(){this.get("destroyed")||(this.clear(),e.prototype.destroy.call(this))},t.prototype.getFirst=function(){return this.getChildByIndex(0)},t.prototype.getLast=function(){var e=this.getChildren();return this.getChildByIndex(e.length-1)},t.prototype.getChildByIndex=function(e){return this.getChildren()[e]},t.prototype.getCount=function(){return this.getChildren().length},t.prototype.contain=function(e){return this.getChildren().indexOf(e)>-1},t.prototype.removeChild=function(e,t){void 0===t&&(t=!0),this.contain(e)&&e.remove(t)},t.prototype.findAll=function(e){var t=[],n=this.getChildren();return(0,o.S6)(n,(function(n){e(n)&&t.push(n),n.isGroup()&&(t=t.concat(n.findAll(e)))})),t},t.prototype.find=function(e){var t=null,n=this.getChildren();return(0,o.S6)(n,(function(n){if(e(n)?t=n:n.isGroup()&&(t=n.find(e)),t)return!1})),t},t.prototype.findById=function(e){return this.find((function(t){return t.get("id")===e}))},t.prototype.findByClassName=function(e){return this.find((function(t){return t.get("className")===e}))},t.prototype.findAllByName=function(e){return this.findAll((function(t){return t.get("name")===e}))},t}(i.Z);t.Z=d},95835:function(e,t,n){"use strict";var r=n(5163),a=n(83677),i=n(72502),o=n(11838),s=n(96630),l=n(71549),u=i.vs,c="matrix",d=["zIndex","capture","visible","type"],p=["repeat"];function h(e,t){var n={},r=t.attrs;for(var a in e)n[a]=r[a];return n}function f(e,t){var n={},r=t.attr();return(0,a.S6)(e,(function(e,t){-1!==p.indexOf(t)||(0,a.Xy)(r[t],e)||(n[t]=e)})),n}function v(e,t){if(t.onFrame)return e;var n=t.startTime,r=t.delay,i=t.duration,o=Object.prototype.hasOwnProperty;return(0,a.S6)(e,(function(e){n+re.delay&&(0,a.S6)(t.toAttrs,(function(t,n){o.call(e.toAttrs,n)&&(delete e.toAttrs[n],delete e.fromAttrs[n])}))})),e}var m=function(e){function t(t){var n=e.call(this,t)||this;n.attrs={};var r=n.getDefaultAttrs();return(0,a.CD)(r,t.attrs),n.attrs=r,n.initAttrs(r),n.initAnimate(),n}return(0,r.ZT)(t,e),t.prototype.getDefaultCfg=function(){return{visible:!0,capture:!0,zIndex:0}},t.prototype.getDefaultAttrs=function(){return{matrix:this.getDefaultMatrix(),opacity:1}},t.prototype.onCanvasChange=function(e){},t.prototype.initAttrs=function(e){},t.prototype.initAnimate=function(){this.set("animable",!0),this.set("animating",!1)},t.prototype.isGroup=function(){return!1},t.prototype.getParent=function(){return this.get("parent")},t.prototype.getCanvas=function(){return this.get("canvas")},t.prototype.attr=function(){for(var e,t=[],n=0;n0?r=v(r,b):n.addAnimator(this),r.push(b),this.set("animations",r),this.set("_pause",{isPaused:!1})}},t.prototype.stopAnimate=function(e){var t=this;void 0===e&&(e=!0);var n=this.get("animations");(0,a.S6)(n,(function(n){e&&(n.onFrame?t.attr(n.onFrame(1)):t.attr(n.toAttrs)),n.callback&&n.callback()})),this.set("animating",!1),this.set("animations",[])},t.prototype.pauseAnimate=function(){var e=this.get("timeline"),t=this.get("animations"),n=e.getTime();return(0,a.S6)(t,(function(e){e._paused=!0,e._pauseTime=n,e.pauseCallback&&e.pauseCallback()})),this.set("_pause",{isPaused:!0,pauseTime:n}),this},t.prototype.resumeAnimate=function(){var e=this.get("timeline").getTime(),t=this.get("animations"),n=this.get("_pause").pauseTime;return(0,a.S6)(t,(function(t){t.startTime=t.startTime+(e-n),t._paused=!1,t._pauseTime=null,t.resumeCallback&&t.resumeCallback()})),this.set("_pause",{isPaused:!1}),this.set("animations",t),this},t.prototype.emitDelegation=function(e,t){var n,r=this,i=t.propagationPath;this.getEvents();"mouseenter"===e?n=t.fromShape:"mouseleave"===e&&(n=t.toShape);for(var s=function(e){var s=i[e],u=s.get("name");if(u){if((s.isGroup()||s.isCanvas&&s.isCanvas())&&n&&(0,o.UY)(s,n))return"break";(0,a.kJ)(u)?(0,a.S6)(u,(function(e){r.emitDelegateEvent(s,e,t)})):l.emitDelegateEvent(s,u,t)}},l=this,u=0;u=e&&n.minY<=t&&n.maxY>=t},t.prototype.afterAttrsChange=function(t){e.prototype.afterAttrsChange.call(this,t),this.clearCacheBBox()},t.prototype.getBBox=function(){var e=this.cfg.bbox;return e||(e=this.calculateBBox(),this.set("bbox",e)),e},t.prototype.getCanvasBBox=function(){var e=this.cfg.canvasBBox;return e||(e=this.calculateCanvasBBox(),this.set("canvasBBox",e)),e},t.prototype.applyMatrix=function(t){e.prototype.applyMatrix.call(this,t),this.set("canvasBBox",null)},t.prototype.calculateCanvasBBox=function(){var e=this.getBBox(),t=this.getTotalMatrix(),n=e.minX,r=e.minY,a=e.maxX,o=e.maxY;if(t){var s=(0,i.rG)(t,[e.minX,e.minY]),l=(0,i.rG)(t,[e.maxX,e.minY]),u=(0,i.rG)(t,[e.minX,e.maxY]),c=(0,i.rG)(t,[e.maxX,e.maxY]);n=Math.min(s[0],l[0],u[0],c[0]),a=Math.max(s[0],l[0],u[0],c[0]),r=Math.min(s[1],l[1],u[1],c[1]),o=Math.max(s[1],l[1],u[1],c[1])}var d=this.attrs;if(d.shadowColor){var p=d.shadowBlur,h=void 0===p?0:p,f=d.shadowOffsetX,v=void 0===f?0:f,m=d.shadowOffsetY,g=void 0===m?0:m,y=n-h+v,x=a+h+v,I=r-h+g,_=o+h+g;n=Math.min(n,y),a=Math.max(a,x),r=Math.min(r,I),o=Math.max(o,_)}return{x:n,y:r,minX:n,minY:r,maxX:a,maxY:o,width:a-n,height:o-r}},t.prototype.clearCacheBBox=function(){this.set("bbox",null),this.set("canvasBBox",null)},t.prototype.isClipShape=function(){return this.get("isClipShape")},t.prototype.isInShape=function(e,t){return!1},t.prototype.isOnlyHitBox=function(){return!1},t.prototype.isHit=function(e,t){var n=this.get("startArrowShape"),r=this.get("endArrowShape"),a=[e,t,1],i=(a=this.invertFromMatrix(a))[0],o=a[1],s=this._isInBBox(i,o);if(this.isOnlyHitBox())return s;if(s&&!this.isClipped(i,o)){if(this.isInShape(i,o))return!0;if(n&&n.isHit(i,o))return!0;if(r&&r.isHit(i,o))return!0}return!1},t}(a.Z);t.Z=o},54410:function(e,t,n){"use strict";n.d(t,{_:function(){return j},C:function(){return Z}});var r={};function a(e){return+e}function i(e){return e*e}function o(e){return e*(2-e)}function s(e){return((e*=2)<=1?e*e:--e*(2-e)+1)/2}function l(e){return e*e*e}function u(e){return--e*e*e+1}function c(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}n.r(r),n.d(r,{easeBack:function(){return R},easeBackIn:function(){return P},easeBackInOut:function(){return R},easeBackOut:function(){return O},easeBounce:function(){return T},easeBounceIn:function(){return M},easeBounceInOut:function(){return A},easeBounceOut:function(){return T},easeCircle:function(){return E},easeCircleIn:function(){return w},easeCircleInOut:function(){return E},easeCircleOut:function(){return S},easeCubic:function(){return c},easeCubicIn:function(){return l},easeCubicInOut:function(){return c},easeCubicOut:function(){return u},easeElastic:function(){return z},easeElasticIn:function(){return N},easeElasticInOut:function(){return F},easeElasticOut:function(){return z},easeExp:function(){return b},easeExpIn:function(){return I},easeExpInOut:function(){return b},easeExpOut:function(){return _},easeLinear:function(){return a},easePoly:function(){return h},easePolyIn:function(){return d},easePolyInOut:function(){return h},easePolyOut:function(){return p},easeQuad:function(){return s},easeQuadIn:function(){return i},easeQuadInOut:function(){return s},easeQuadOut:function(){return o},easeSin:function(){return y},easeSinIn:function(){return m},easeSinInOut:function(){return y},easeSinOut:function(){return g}});var d=function e(t){function n(e){return Math.pow(e,t)}return t=+t,n.exponent=e,n}(3),p=function e(t){function n(e){return 1-Math.pow(1-e,t)}return t=+t,n.exponent=e,n}(3),h=function e(t){function n(e){return((e*=2)<=1?Math.pow(e,t):2-Math.pow(2-e,t))/2}return t=+t,n.exponent=e,n}(3),f=Math.PI,v=f/2;function m(e){return 1==+e?1:1-Math.cos(e*v)}function g(e){return Math.sin(e*v)}function y(e){return(1-Math.cos(f*e))/2}function x(e){return 1.0009775171065494*(Math.pow(2,-10*e)-.0009765625)}function I(e){return x(1-+e)}function _(e){return 1-x(e)}function b(e){return((e*=2)<=1?x(1-e):2-x(e-1))/2}function w(e){return 1-Math.sqrt(1-e*e)}function S(e){return Math.sqrt(1- --e*e)}function E(e){return((e*=2)<=1?1-Math.sqrt(1-e*e):Math.sqrt(1-(e-=2)*e)+1)/2}var C=4/11,k=7.5625;function M(e){return 1-T(1-e)}function T(e){return(e=+e)Math.PI/2?Math.PI-u:u,c=c>Math.PI/2?Math.PI-c:c,{xExtra:Math.cos(l/2-u)*(t/2*(1/Math.sin(l/2)))-t/2||0,yExtra:Math.cos(c-l/2)*(t/2*(1/Math.sin(l/2)))-t/2||0}}a("rect",o),a("image",o),a("circle",s),a("marker",s),a("polyline",(function(e){for(var t=e.attr().points,n=[],r=[],a=0;a2&&(n.push([a].concat(s.splice(0,2))),l="l",a="m"===a?"l":"L"),"o"===l&&1===s.length&&n.push([a,s[0]]),"r"===l)n.push([a].concat(s));else for(;s.length>=t[l]&&(n.push([a].concat(s.splice(0,t[l]))),t[l]););return e})),n},l=function(e,t){for(var n=[],r=0,a=e.length;a-2*!t>r;r+=2){var i=[{x:+e[r-2],y:+e[r-1]},{x:+e[r],y:+e[r+1]},{x:+e[r+2],y:+e[r+3]},{x:+e[r+4],y:+e[r+5]}];t?r?a-4===r?i[3]={x:+e[0],y:+e[1]}:a-2===r&&(i[2]={x:+e[0],y:+e[1]},i[3]={x:+e[2],y:+e[3]}):i[0]={x:+e[a-2],y:+e[a-1]}:a-4===r?i[3]=i[2]:r||(i[0]={x:+e[r],y:+e[r+1]}),n.push(["C",(-i[0].x+6*i[1].x+i[2].x)/6,(-i[0].y+6*i[1].y+i[2].y)/6,(i[1].x+6*i[2].x-i[3].x)/6,(i[1].y+6*i[2].y-i[3].y)/6,i[2].x,i[2].y])}return n},u=function(e,t,n,r,a){var i=[];if(null===a&&null===r&&(r=n),e=+e,t=+t,n=+n,r=+r,null!==a){var o=Math.PI/180,s=e+n*Math.cos(-r*o),l=e+n*Math.cos(-a*o);i=[["M",s,t+n*Math.sin(-r*o)],["A",n,n,0,+(a-r>180),0,l,t+n*Math.sin(-a*o)]]}else i=[["M",e,t],["m",0,-r],["a",n,r,0,1,1,0,2*r],["a",n,r,0,1,1,0,-2*r],["z"]];return i},c=function(e){if(!(e=s(e))||!e.length)return[["M",0,0]];var t,n,r=[],a=0,i=0,o=0,c=0,d=0;"M"===e[0][0]&&(o=a=+e[0][1],c=i=+e[0][2],d++,r[0]=["M",a,i]);for(var p=3===e.length&&"M"===e[0][0]&&"R"===e[1][0].toUpperCase()&&"Z"===e[2][0].toUpperCase(),h=void 0,f=void 0,v=d,m=e.length;v1&&(n*=b=Math.sqrt(b),r*=b);var w=n*n,S=r*r,E=(i===o?-1:1)*Math.sqrt(Math.abs((w*S-w*_*_-S*I*I)/(w*_*_+S*I*I)));f=E*n*_/r+(e+s)/2,v=E*-r*I/n+(t+l)/2,d=Math.asin(((t-v)/r).toFixed(9)),p=Math.asin(((l-v)/r).toFixed(9)),d=ep&&(d-=2*Math.PI),!o&&p>d&&(p-=2*Math.PI)}var C=p-d;if(Math.abs(C)>m){var k=p,M=s,T=l;p=d+m*(o&&p>d?1:-1),s=f+n*Math.cos(p),l=v+r*Math.sin(p),y=h(s,l,n,r,a,0,o,M,T,[p,k,f,v])}C=p-d;var A=Math.cos(d),L=Math.sin(d),P=Math.cos(p),O=Math.sin(p),R=Math.tan(C/4),D=4/3*n*R,N=4/3*r*R,z=[e,t],F=[e+D*L,t-N*A],B=[s+D*O,l-N*P],j=[s,l];if(F[0]=2*z[0]-F[0],F[1]=2*z[1]-F[1],u)return[F,B,j].concat(y);for(var Z=[],U=0,V=(y=[F,B,j].concat(y).join().split(",")).length;U7){e[t].shift();for(var i=e[t];i.length;)s[t]="A",a&&(l[t]="A"),e.splice(t++,0,["C"].concat(i.splice(0,6)));e.splice(t,1),n=Math.max(r.length,a&&a.length||0)}},g=function(e,t,i,o,s){e&&t&&"M"===e[s][0]&&"M"!==t[s][0]&&(t.splice(s,0,["M",o.x,o.y]),i.bx=0,i.by=0,i.x=e[s][1],i.y=e[s][2],n=Math.max(r.length,a&&a.length||0))};n=Math.max(r.length,a&&a.length||0);for(var y=0;y1?1:l<0?0:l)/2,c=[-.1252,.1252,-.3678,.3678,-.5873,.5873,-.7699,.7699,-.9041,.9041,-.9816,.9816],d=[.2491,.2491,.2335,.2335,.2032,.2032,.1601,.1601,.1069,.1069,.0472,.0472],p=0,h=0;h<12;h++){var f=u*c[h]+u,v=g(f,e,n,a,o),m=g(f,t,r,i,s),y=v*v+m*m;p+=d[h]*Math.sqrt(y)}return u*p},x=function(e,t,n,r,a,i,o,s){for(var l,u,c,d,p=[],h=[[],[]],f=0;f<2;++f)if(0===f?(u=6*e-12*n+6*a,l=-3*e+9*n-9*a+3*o,c=3*n-3*e):(u=6*t-12*r+6*i,l=-3*t+9*r-9*i+3*s,c=3*r-3*t),Math.abs(l)<1e-12){if(Math.abs(u)<1e-12)continue;(d=-c/u)>0&&d<1&&p.push(d)}else{var v=u*u-4*c*l,m=Math.sqrt(v);if(!(v<0)){var g=(-u+m)/(2*l);g>0&&g<1&&p.push(g);var y=(-u-m)/(2*l);y>0&&y<1&&p.push(y)}}for(var x,I=p.length,_=I;I--;)x=1-(d=p[I]),h[0][I]=x*x*x*e+3*x*x*d*n+3*x*d*d*a+d*d*d*o,h[1][I]=x*x*x*t+3*x*x*d*r+3*x*d*d*i+d*d*d*s;return h[0][_]=e,h[1][_]=t,h[0][_+1]=o,h[1][_+1]=s,h[0].length=h[1].length=_+2,{min:{x:Math.min.apply(0,h[0]),y:Math.min.apply(0,h[1])},max:{x:Math.max.apply(0,h[0]),y:Math.max.apply(0,h[1])}}},I=function(e,t,n,r,a,i,o,s){if(!(Math.max(e,n)Math.max(a,o)||Math.max(t,r)Math.max(i,s))){var l=(e-n)*(i-s)-(t-r)*(a-o);if(l){var u=((e*r-t*n)*(a-o)-(e-n)*(a*s-i*o))/l,c=((e*r-t*n)*(i-s)-(t-r)*(a*s-i*o))/l,d=+u.toFixed(2),p=+c.toFixed(2);if(!(d<+Math.min(e,n).toFixed(2)||d>+Math.max(e,n).toFixed(2)||d<+Math.min(a,o).toFixed(2)||d>+Math.max(a,o).toFixed(2)||p<+Math.min(t,r).toFixed(2)||p>+Math.max(t,r).toFixed(2)||p<+Math.min(i,s).toFixed(2)||p>+Math.max(i,s).toFixed(2)))return{x:u,y:c}}}},_=function(e,t,n){return t>=e.x&&t<=e.x+e.width&&n>=e.y&&n<=e.y+e.height},b=function(e,t,n,r,a){if(a)return[["M",+e+ +a,t],["l",n-2*a,0],["a",a,a,0,0,1,a,a],["l",0,r-2*a],["a",a,a,0,0,1,-a,a],["l",2*a-n,0],["a",a,a,0,0,1,-a,-a],["l",0,2*a-r],["a",a,a,0,0,1,a,-a],["z"]];var i=[["M",e,t],["l",n,0],["l",0,r],["l",-n,0],["z"]];return i.parsePathArray=m,i},w=function(e,t,n,r){return null===e&&(e=t=n=r=0),null===t&&(t=e.y,n=e.width,r=e.height,e=e.x),{x:e,y:t,width:n,w:n,height:r,h:r,x2:e+n,y2:t+r,cx:e+n/2,cy:t+r/2,r1:Math.min(n,r)/2,r2:Math.max(n,r)/2,r0:Math.sqrt(n*n+r*r)/2,path:b(e,t,n,r),vb:[e,t,n,r].join(" ")}},S=function(e,t,n,a,i,o,s,l){(0,r.kJ)(e)||(e=[e,t,n,a,i,o,s,l]);var u=x.apply(null,e);return w(u.min.x,u.min.y,u.max.x-u.min.x,u.max.y-u.min.y)},E=function(e,t,n,r,a,i,o,s,l){var u=1-l,c=Math.pow(u,3),d=Math.pow(u,2),p=l*l,h=p*l,f=e+2*l*(n-e)+p*(a-2*n+e),v=t+2*l*(r-t)+p*(i-2*r+t),m=n+2*l*(a-n)+p*(o-2*a+n),g=r+2*l*(i-r)+p*(s-2*i+r);return{x:c*e+3*d*l*n+3*u*l*l*a+h*o,y:c*t+3*d*l*r+3*u*l*l*i+h*s,m:{x:f,y:v},n:{x:m,y:g},start:{x:u*e+l*n,y:u*t+l*r},end:{x:u*a+l*o,y:u*i+l*s},alpha:90-180*Math.atan2(f-m,v-g)/Math.PI}},C=function(e,t,n){if(!function(e,t){return e=w(e),t=w(t),_(t,e.x,e.y)||_(t,e.x2,e.y)||_(t,e.x,e.y2)||_(t,e.x2,e.y2)||_(e,t.x,t.y)||_(e,t.x2,t.y)||_(e,t.x,t.y2)||_(e,t.x2,t.y2)||(e.xt.x||t.xe.x)&&(e.yt.y||t.ye.y)}(S(e),S(t)))return n?0:[];for(var r=~~(y.apply(0,e)/8),a=~~(y.apply(0,t)/8),i=[],o=[],s={},l=n?0:[],u=0;u=0&&b<=1&&C>=0&&C<=1&&(n?l+=1:l.push({x:x.x,y:x.y,t1:b,t2:C}))}}return l},k=function(e,t){return function(e,t,n){var r,a,i,o,s,l,u,c,d,p;e=f(e),t=f(t);for(var h=n?0:[],v=0,m=e.length;v=3&&(3===e.length&&t.push("Q"),t=t.concat(e[1])),2===e.length&&t.push("L"),t.concat(e[e.length-1])}))}(e,t,n));else{var a=[].concat(e);"M"===a[0]&&(a[0]="L");for(var i=0;i<=n-1;i++)r.push(a)}return r},A=function(e,t){if(1===e.length)return e;var n=e.length-1,r=t.length-1,a=n/r,i=[];if(1===e.length&&"M"===e[0][0]){for(var o=0;o=0;l--)o=i[l].index,"add"===i[l].type?e.splice(o,0,[].concat(e[o])):e.splice(o,1)}var d=a-(r=e.length);if(r0)){e[r]=t[r];break}n=R(n,e[r-1],1)}e[r]=["Q"].concat(n.reduce((function(e,t){return e.concat(t)}),[]));break;case"T":e[r]=["T"].concat(n[0]);break;case"C":if(n.length<3){if(!(r>0)){e[r]=t[r];break}n=R(n,e[r-1],2)}e[r]=["C"].concat(n.reduce((function(e,t){return e.concat(t)}),[]));break;case"S":if(n.length<2){if(!(r>0)){e[r]=t[r];break}n=R(n,e[r-1],1)}e[r]=["S"].concat(n.reduce((function(e,t){return e.concat(t)}),[]));break;default:e[r]=t[r]}return e}},24629:function(e,t,n){"use strict";n.d(t,{$O:function(){return s},FE:function(){return i},mY:function(){return o}});var r=n(11838),a=n(49096);function i(e,t,n){var a=1;if((0,r.HD)(e)&&(a=e.split("\n").length),a>1){var i=function(e,t){return t?t-e:.14*e}(t,n);return t*a+i*(a-1)}return t}function o(e,t){var n=(0,a.L)(),i=0;if((0,r.kK)(e)||""===e)return i;if(n.save(),n.font=t,(0,r.HD)(e)&&e.includes("\n")){var o=e.split("\n");(0,r.S6)(o,(function(e){var t=n.measureText(e).width;i(n-e)*(n-e)+(r-t)*(r-t)?i(n,r,a,o):this.pointToLine(e,t,n,r,a,o)},pointToLine:function(e,t,n,r,a,i){var o=[n-e,r-t];if(c.I6(o,[0,0]))return Math.sqrt((a-e)*(a-e)+(i-t)*(i-t));var s=[-o[1],o[0]];c.Fv(s,s);var l=[a-e,i-t];return Math.abs(c.AK(l,s))},tangentAngle:function(e,t,n,r){return Math.atan2(r-t,n-e)}};function p(e,t,n,r,a,o){var s,l=1/0,u=[n,r],c=20;o&&o>200&&(c=o/10);for(var d=1/c,p=d/10,h=0;h<=c;h++){var f=h*d,v=[a.apply(null,e.concat([f])),a.apply(null,t.concat([f]))];(x=i(u[0],u[1],v[0],v[1]))=0&&x=0?[a]:[]}function v(e,t,n,r){return 2*(1-r)*(t-e)+2*r*(n-t)}function m(e,t,n,r,a,i,o){var s=h(e,n,a,o),l=h(t,r,i,o),u=d.pointAt(e,t,n,r,o),c=d.pointAt(n,r,a,i,o);return[[e,t,u.x,u.y,s,l],[s,l,c.x,c.y,a,i]]}function g(e,t,n,r,a,o,s){if(0===s)return(i(e,t,n,r)+i(n,r,a,o)+i(e,t,a,o))/2;var l=m(e,t,n,r,a,o,.5),u=l[0],c=l[1];return u.push(s-1),c.push(s-1),g.apply(null,u)+g.apply(null,c)}var y={box:function(e,t,n,r,a,i){var o=f(e,n,a)[0],l=f(t,r,i)[0],u=[e,a],c=[t,i];return void 0!==o&&u.push(h(e,n,a,o)),void 0!==l&&c.push(h(t,r,i,l)),s(u,c)},length:function(e,t,n,r,a,i){return g(e,t,n,r,a,i,3)},nearestPoint:function(e,t,n,r,a,i,o,s){return p([e,n,a],[t,r,i],o,s,h)},pointDistance:function(e,t,n,r,a,o,s,l){var u=this.nearestPoint(e,t,n,r,a,o,s,l);return i(u.x,u.y,s,l)},interpolationAt:h,pointAt:function(e,t,n,r,a,i,o){return{x:h(e,n,a,o),y:h(t,r,i,o)}},divide:function(e,t,n,r,a,i,o){return m(e,t,n,r,a,i,o)},tangentAngle:function(e,t,n,r,a,i,o){var s=v(e,n,a,o),l=v(t,r,i,o);return u(Math.atan2(l,s))}};function x(e,t,n,r,a){var i=1-a;return i*i*i*e+3*t*a*i*i+3*n*a*a*i+r*a*a*a}function I(e,t,n,r,a){var i=1-a;return 3*(i*i*(t-e)+2*i*a*(n-t)+a*a*(r-n))}function _(e,t,n,r){var a,i,s,l=-3*e+9*t-9*n+3*r,u=6*e-12*t+6*n,c=3*t-3*e,d=[];if(o(l,0))o(u,0)||(a=-c/u)>=0&&a<=1&&d.push(a);else{var p=u*u-4*l*c;o(p,0)?d.push(-u/(2*l)):p>0&&(i=(-u-(s=Math.sqrt(p)))/(2*l),(a=(-u+s)/(2*l))>=0&&a<=1&&d.push(a),i>=0&&i<=1&&d.push(i))}return d}function b(e,t,n,r,a,i,o,s,l){var u=x(e,n,a,o,l),c=x(t,r,i,s,l),p=d.pointAt(e,t,n,r,l),h=d.pointAt(n,r,a,i,l),f=d.pointAt(a,i,o,s,l),v=d.pointAt(p.x,p.y,h.x,h.y,l),m=d.pointAt(h.x,h.y,f.x,f.y,l);return[[e,t,p.x,p.y,v.x,v.y,u,c],[u,c,m.x,m.y,f.x,f.y,o,s]]}function w(e,t,n,r,a,o,s,l,u){if(0===u)return function(e,t){for(var n=0,r=e.length,a=0;a0?n:-1*n}var C=function(e,t,n,r,a,i){var o=n,s=r;if(0===o||0===s)return{x:e,y:t};for(var l,u,c=a-e,d=i-t,p=Math.abs(c),h=Math.abs(d),f=o*o,v=s*s,m=Math.PI/4,g=0;g<4;g++){l=o*Math.cos(m),u=s*Math.sin(m);var y=(f-v)*Math.pow(Math.cos(m),3)/o,x=(v-f)*Math.pow(Math.sin(m),3)/s,I=l-y,_=u-x,b=p-y,w=h-x,S=Math.hypot(_,I),C=Math.hypot(w,b);m+=S*Math.asin((I*w-_*b)/(S*C))/Math.sqrt(f+v-l*l-u*u),m=Math.min(Math.PI/2,Math.max(0,m))}return{x:e+E(l,c),y:t+E(u,d)}};function k(e,t,n,r,a,i){return n*Math.cos(a)*Math.cos(i)-r*Math.sin(a)*Math.sin(i)+e}function M(e,t,n,r,a,i){return n*Math.sin(a)*Math.cos(i)+r*Math.cos(a)*Math.sin(i)+t}function T(e,t,n){return{x:e*Math.cos(n),y:t*Math.sin(n)}}function A(e,t,n){var r=Math.cos(n),a=Math.sin(n);return[e*r-t*a,e*a+t*r]}var L={box:function(e,t,n,r,a,i,o){for(var s=function(e,t,n){return Math.atan(-t/e*Math.tan(n))}(n,r,a),l=1/0,u=-1/0,c=[i,o],d=2*-Math.PI;d<=2*Math.PI;d+=Math.PI){var p=s+d;iu&&(u=h)}var f=function(e,t,n){return Math.atan(t/(e*Math.tan(n)))}(n,r,a),v=1/0,m=-1/0,g=[i,o];for(d=2*-Math.PI;d<=2*Math.PI;d+=Math.PI){var y=f+d;im&&(m=x)}return{x:l,y:v,width:u-l,height:m-v}},length:function(e,t,n,r,a,i,o){},nearestPoint:function(e,t,n,r,a,i,o,s,l){var u=A(s-e,l-t,-a),c=u[0],d=u[1],p=C(0,0,n,r,c,d),h=function(e,t,n,r){return(Math.atan2(r*e,n*t)+2*Math.PI)%(2*Math.PI)}(n,r,p.x,p.y);ho&&(p=T(n,r,o));var f=A(p.x,p.y,a);return{x:f[0]+e,y:f[1]+t}},pointDistance:function(e,t,n,r,a,o,s,l,u){var c=this.nearestPoint(e,t,n,r,l,u);return i(c.x,c.y,l,u)},pointAt:function(e,t,n,r,a,i,o,s){var l=(o-i)*s+i;return{x:k(e,0,n,r,a,l),y:M(0,t,n,r,a,l)}},tangentAngle:function(e,t,n,r,a,i,o,s){var l=(o-i)*s+i,c=function(e,t,n,r,a,i,o,s){return-1*n*Math.cos(a)*Math.sin(s)-r*Math.sin(a)*Math.cos(s)}(0,0,n,r,a,0,0,l),d=function(e,t,n,r,a,i,o,s){return-1*n*Math.sin(a)*Math.sin(s)+r*Math.cos(a)*Math.cos(s)}(0,0,n,r,a,0,0,l);return u(Math.atan2(d,c))}};function P(e){for(var t=0,n=[],r=0;r1||t<0||e.length<2)return null;var n=P(e),r=n.segments,a=n.totalLength;if(0===a)return{x:e[0][0],y:e[0][1]};for(var i=0,o=null,s=0;s=i&&t<=i+p){var h=(t-i)/p;o=d.pointAt(u[0],u[1],c[0],c[1],h);break}i+=p}return o}function D(e,t){if(t>1||t<0||e.length<2)return 0;for(var n=P(e),r=n.segments,a=n.totalLength,i=0,o=0,s=0;s=i&&t<=i+d){o=Math.atan2(c[1]-u[1],c[0]-u[0]);break}i+=d}return o}function N(e,t,n){for(var r=1/0,a=0;a=0},e.prototype.getAdjustRange=function(e,t,n){var r,a,i=this.yField,o=n.indexOf(t),s=n.length;return!i&&this.isAdjust("y")?(r=0,a=1):s>1?(r=n[0===o?0:o-1],a=n[o===s-1?s-1:o+1],0!==o?r+=(t-r)/2:r-=(a-t)/2,o!==s-1?a-=(a-t)/2:a+=(t-n[s-2])/2):(r=0===t?0:t-.5,a=0===t?1:t+.5),{pre:r,next:a}},e.prototype.adjustData=function(e,t){var n=this,r=this.getDimValues(t);x.S6(e,(function(e,t){x.S6(r,(function(r,a){n.adjustDim(a,r,e,t)}))}))},e.prototype.groupData=function(e,t){return x.S6(e,(function(e){void 0===e[t]&&(e[t]=0)})),x.vM(e,t)},e.prototype.adjustDim=function(e,t,n,r){},e.prototype.getDimValues=function(e){var t=this.xField,n=this.yField,r=x.f0({},this.dimValuesMap),a=[];if(t&&this.isAdjust("x")&&a.push(t),n&&this.isAdjust("y")&&a.push(n),a.forEach((function(t){r&&r[t]||(r[t]=x.I(e,t).sort((function(e,t){return e-t})))})),!n&&this.isAdjust("y")){r.y=[0,1]}return r},e}(),j=B,Z={},U=function(e){return Z[e.toLowerCase()]},V=function(e,t){if(U(e))throw new Error("Adjust type '"+e+"' existed.");Z[e.toLowerCase()]=t},H=(n(67425),function(e,t){return H=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},H(e,t)});function G(e,t){function n(){this.constructor=e}H(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var q=function(){return q=Object.assign||function(e){for(var t,n=1,r=arguments.length;n=0)r=u+this.getIntervalOnlyOffset(n,t);else if(!x.UM(l)&&x.UM(s)&&l>=0){r=u+this.getDodgeOnlyOffset(n,t)}else if(!x.UM(s)&&!x.UM(l)&&s>=0&&l>=0){r=u+this.getIntervalAndDodgeOffset(n,t)}else{var p=d*i/n,h=o*p;r=(u+c)/2+(.5*(d-n*p-(n-1)*h)+((t+1)*p+t*h)-.5*p-.5*d)}return r},t.prototype.getIntervalOnlyOffset=function(e,t){var n=this,r=n.defaultSize,a=n.intervalPadding,i=n.xDimensionLegenth,o=n.groupNum,s=n.dodgeRatio,l=n.maxColumnWidth,u=n.minColumnWidth,c=n.columnWidthRatio,d=a/i,p=(1-(o-1)*d)/o*s/(e-1),h=((1-d*(o-1))/o-p*(e-1))/e;if(h=x.UM(c)?h:1/o/e*c,!x.UM(l)){var f=l/i;h=Math.min(h,f)}if(!x.UM(u)){var v=u/i;h=Math.max(h,v)}return((.5+t)*(h=r?r/i:h)+t*(p=((1-(o-1)*d)/o-e*h)/(e-1))+.5*d)*o-d/2},t.prototype.getDodgeOnlyOffset=function(e,t){var n=this,r=n.defaultSize,a=n.dodgePadding,i=n.xDimensionLegenth,o=n.groupNum,s=n.marginRatio,l=n.maxColumnWidth,u=n.minColumnWidth,c=n.columnWidthRatio,d=a/i,p=1*s/(o-1),h=((1-p*(o-1))/o-d*(e-1))/e;if(h=c?1/o/e*c:h,!x.UM(l)){var f=l/i;h=Math.min(h,f)}if(!x.UM(u)){var v=u/i;h=Math.max(h,v)}return((.5+t)*(h=r?r/i:h)+t*d+.5*(p=(1-(h*e+d*(e-1))*o)/(o-1)))*o-p/2},t.prototype.getIntervalAndDodgeOffset=function(e,t){var n=this,r=n.intervalPadding,a=n.dodgePadding,i=n.xDimensionLegenth,o=n.groupNum,s=r/i,l=a/i;return((.5+t)*(((1-s*(o-1))/o-l*(e-1))/e)+t*l+.5*s)*o-s/2},t.prototype.getDistribution=function(e){var t=this.adjustDataArray,n=this.cacheMap,r=n[e];return r||(r={},x.S6(t,(function(t,n){var a=x.I(t,e);a.length||a.push(0),x.S6(a,(function(e){r[e]||(r[e]=[]),r[e].push(n)}))})),n[e]=r),r},t}(j),Y=W;var X=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return G(t,e),t.prototype.process=function(e){var t=x.d9(e),n=x.xH(t);return this.adjustData(t,n),t},t.prototype.adjustDim=function(e,t,n){var r=this,a=this.groupData(n,e);return x.S6(a,(function(n,a){return r.adjustGroup(n,e,parseFloat(a),t)}))},t.prototype.getAdjustOffset=function(e){var t,n=e.pre,r=e.next,a=.05*(r-n);return(r-a-(t=n+a))*Math.random()+t},t.prototype.adjustGroup=function(e,t,n,r){var a=this,i=this.getAdjustRange(t,n,r);return x.S6(e,(function(e){e[t]=a.getAdjustOffset(i)})),e},t}(j),K=X,J=x.Ct,$=function(e){function t(t){var n=e.call(this,t)||this,r=t.adjustNames,a=void 0===r?["y"]:r,i=t.height,o=void 0===i?NaN:i,s=t.size,l=void 0===s?10:s,u=t.reverseOrder,c=void 0!==u&&u;return n.adjustNames=a,n.height=o,n.size=l,n.reverseOrder=c,n}return G(t,e),t.prototype.process=function(e){var t=this.yField,n=this.reverseOrder,r=t?this.processStack(e):this.processOneDimStack(e);return n?this.reverse(r):r},t.prototype.reverse=function(e){return e.slice(0).reverse()},t.prototype.processStack=function(e){var t=this,n=t.xField,r=t.yField,a=t.reverseOrder?this.reverse(e):e,i=new J,o=new J;return a.map((function(e){return e.map((function(e){var t,a=x.U2(e,n,0),s=x.U2(e,[r]),l=a.toString();if(s=x.kJ(s)?s[1]:s,!x.UM(s)){var u=s>=0?i:o;u.has(l)||u.set(l,0);var c=u.get(l),d=s+c;return u.set(l,d),q(q({},e),((t={})[r]=[c,d],t))}return e}))}))},t.prototype.processOneDimStack=function(e){var t=this,n=this,r=n.xField,a=n.height,i=n.reverseOrder,o=i?this.reverse(e):e,s=new J;return o.map((function(e){return e.map((function(e){var n,i=t.size,o=e[r],l=2*i/a;s.has(o)||s.set(o,l/2);var u=s.get(o);return s.set(o,u+l),q(q({},e),((n={}).y=u,n))}))}))},t}(j),Q=$,ee=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return G(t,e),t.prototype.process=function(e){var t=x.xH(e),n=this.xField,r=this.yField,a=this.getXValuesMaxMap(t),i=Math.max.apply(Math,Object.keys(a).map((function(e){return a[e]})));return x.UI(e,(function(e){return x.UI(e,(function(e){var t,o,s=e[r],l=e[n];if(x.kJ(s)){var u=(i-a[l])/2;return q(q({},e),((t={})[r]=x.UI(s,(function(e){return u+e})),t))}var c=(i-s)/2;return q(q({},e),((o={})[r]=[c,s+c],o))}))}))},t.prototype.getXValuesMaxMap=function(e){var t=this,n=this.xField,r=this.yField,a=x.vM(e,(function(e){return e[n]}));return x.Q8(a,(function(e){return t.getDimMaxValue(e,r)}))},t.prototype.getDimMaxValue=function(e,t){var n=x.UI(e,(function(e){return x.U2(e,t,[])})),r=x.xH(n);return Math.max.apply(Math,r)},t}(j),te=ee;V("Dodge",Y),V("Jitter",K),V("Stack",Q),V("Symmetric",te);var ne=function(e,t){return(0,x.HD)(t)?t:e.invert(e.scale(t))},re=function(){function e(e){this.names=[],this.scales=[],this.linear=!1,this.values=[],this.callback=function(){return[]},this._parseCfg(e)}return e.prototype.mapping=function(){for(var e=this,t=[],n=0;n1?1:Number(t),r=e.length-1,a=Math.floor(r*n),i=r*n-a,o=e[a],s=a===r?o:e[a+1];return pe([de(o,s,i,0),de(o,s,i,1),de(o,s,i,2)])}(n,e)}},toRGB:(0,x.HP)(me),toCSSGradient:function(e){if(/^[r,R,L,l]{1}[\s]*\(/.test(e)){var t,n=void 0;if("l"===e[0]){var r=+(a=le.exec(e))[1]+90;n=a[2],t="linear-gradient("+r+"deg, "}else if("r"===e[0]){var a;t="radial-gradient(",n=(a=ue.exec(e))[4]}var i=n.match(ce);return(0,x.S6)(i,(function(e,n){var r=e.split(":");t+=r[1]+" "+100*r[0]+"%",n!==i.length-1&&(t+=", ")})),t+=")"}return e}},ye=function(e){function t(t){var n=e.call(this,t)||this;return n.type="color",n.names=["color"],(0,x.HD)(n.values)&&(n.linear=!0),n.gradient=ge.gradient(n.values),n}return oe(t,e),t.prototype.getLinearValue=function(e){return this.gradient(e)},t}(ae),xe=function(e){function t(t){var n=e.call(this,t)||this;return n.type="opacity",n.names=["opacity"],n}return oe(t,e),t}(ae),Ie=function(e){function t(t){var n=e.call(this,t)||this;return n.names=["x","y"],n.type="position",n}return oe(t,e),t.prototype.mapping=function(e,t){var n=this.scales,r=n[0],a=n[1];return(0,x.UM)(e)||(0,x.UM)(t)?[]:[(0,x.kJ)(e)?e.map((function(e){return r.scale(e)})):r.scale(e),(0,x.kJ)(t)?t.map((function(e){return a.scale(e)})):a.scale(t)]},t}(ae),_e=Ie,be=function(e){function t(t){var n=e.call(this,t)||this;return n.type="shape",n.names=["shape"],n}return oe(t,e),t.prototype.getLinearValue=function(e){var t=Math.round((this.values.length-1)*e);return this.values[t]},t}(ae),we=function(e){function t(t){var n=e.call(this,t)||this;return n.type="size",n.names=["size"],n}return oe(t,e),t}(ae),Se={};function Ee(e,t){Se[e]=t}var Ce=function(){function e(e){this.type="base",this.isCategory=!1,this.isLinear=!1,this.isContinuous=!1,this.isIdentity=!1,this.values=[],this.range=[0,1],this.ticks=[],this.__cfg__=e,this.initCfg(),this.init()}return e.prototype.translate=function(e){return e},e.prototype.change=function(e){(0,x.f0)(this.__cfg__,e),this.init()},e.prototype.clone=function(){return this.constructor(this.__cfg__)},e.prototype.getTicks=function(){var e=this;return(0,x.UI)(this.ticks,(function(t,n){return(0,x.Kn)(t)?t:{text:e.getText(t,n),tickValue:t,value:e.scale(t)}}))},e.prototype.getText=function(e,t){var n=this.formatter,r=n?n(e,t):e;return(0,x.UM)(r)||!(0,x.mf)(r.toString)?"":r.toString()},e.prototype.getConfig=function(e){return this.__cfg__[e]},e.prototype.init=function(){(0,x.f0)(this,this.__cfg__),this.setDomain(),(0,x.xb)(this.getConfig("ticks"))&&(this.ticks=this.calculateTicks())},e.prototype.initCfg=function(){},e.prototype.setDomain=function(){},e.prototype.calculateTicks=function(){var e=this.tickMethod,t=[];if((0,x.HD)(e)){var n=Se[e];if(!n)throw new Error("There is no method to to calculate ticks!");t=n(this)}else(0,x.mf)(e)&&(t=e(this));return t},e.prototype.rangeMin=function(){return this.range[0]},e.prototype.rangeMax=function(){return this.range[1]},e.prototype.calcPercent=function(e,t,n){return(0,x.hj)(e)?(e-t)/(n-t):NaN},e.prototype.calcValue=function(e,t,n){return t+e*(n-t)},e}(),ke=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="cat",t.isCategory=!0,t}return(0,y.ZT)(t,e),t.prototype.buildIndexMap=function(){if(!this.translateIndexMap){this.translateIndexMap=new Map;for(var e=0;ethis.max?NaN:this.values[r]},t.prototype.getText=function(t){for(var n=[],r=1;r1?e-1:e}this.translateIndexMap&&(this.translateIndexMap=void 0)},t}(Ce),Me=ke,Te=/d{1,4}|M{1,4}|YY(?:YY)?|S{1,3}|Do|ZZ|Z|([HhMsDm])\1?|[aA]|"[^"]*"|'[^']*'/g,Ae="\\d\\d?",Le="\\d\\d",Pe="[^\\s]+",Oe=/\[([^]*?)\]/gm;function Re(e,t){for(var n=[],r=0,a=e.length;r-1?a:null}};function Ne(e){for(var t=[],n=1;n3?0:(e-e%10!=10?1:0)*e%10]}},Ze=Ne({},je),Ue=function(e){return Ze=Ne(Ze,e)},Ve=function(e){return e.replace(/[|\\{()[^$+*?.-]/g,"\\$&")},He=function(e,t){for(void 0===t&&(t=2),e=String(e);e.length0?"-":"+")+He(100*Math.floor(Math.abs(t)/60)+Math.abs(t)%60,4)},Z:function(e){var t=e.getTimezoneOffset();return(t>0?"-":"+")+He(Math.floor(Math.abs(t)/60),2)+":"+He(Math.abs(t)%60,2)}},qe=function(e){return+e-1},We=[null,Ae],Ye=[null,Pe],Xe=["isPm",Pe,function(e,t){var n=e.toLowerCase();return n===t.amPm[0]?0:n===t.amPm[1]?1:null}],Ke=["timezoneOffset","[^\\s]*?[\\+\\-]\\d\\d:?\\d\\d|[^\\s]*?Z?",function(e){var t=(e+"").match(/([+-]|\d\d)/gi);if(t){var n=60*+t[1]+parseInt(t[2],10);return"+"===t[0]?n:-n}return 0}],Je={D:["day",Ae],DD:["day",Le],Do:["day",Ae+Pe,function(e){return parseInt(e,10)}],M:["month",Ae,qe],MM:["month",Le,qe],YY:["year",Le,function(e){var t=+(""+(new Date).getFullYear()).substr(0,2);return+(""+(+e>68?t-1:t)+e)}],h:["hour",Ae,void 0,"isPm"],hh:["hour",Le,void 0,"isPm"],H:["hour",Ae],HH:["hour",Le],m:["minute",Ae],mm:["minute",Le],s:["second",Ae],ss:["second",Le],YYYY:["year","\\d{4}"],S:["millisecond","\\d",function(e){return 100*+e}],SS:["millisecond",Le,function(e){return 10*+e}],SSS:["millisecond","\\d{3}"],d:We,dd:We,ddd:Ye,dddd:Ye,MMM:["month",Pe,De("monthNamesShort")],MMMM:["month",Pe,De("monthNames")],a:Xe,A:Xe,ZZ:Ke,Z:Ke},$e={default:"ddd MMM DD YYYY HH:mm:ss",shortDate:"M/D/YY",mediumDate:"MMM D, YYYY",longDate:"MMMM D, YYYY",fullDate:"dddd, MMMM D, YYYY",isoDate:"YYYY-MM-DD",isoDateTime:"YYYY-MM-DDTHH:mm:ssZ",shortTime:"HH:mm",mediumTime:"HH:mm:ss",longTime:"HH:mm:ss.SSS"},Qe=function(e){return Ne($e,e)},et=function(e,t,n){if(void 0===t&&(t=$e.default),void 0===n&&(n={}),"number"==typeof e&&(e=new Date(e)),"[object Date]"!==Object.prototype.toString.call(e)||isNaN(e.getTime()))throw new Error("Invalid Date pass to format");var r=[];t=(t=$e[t]||t).replace(Oe,(function(e,t){return r.push(t),"@@@"}));var a=Ne(Ne({},Ze),n);return(t=t.replace(Te,(function(t){return Ge[t](e,a)}))).replace(/@@@/g,(function(){return r.shift()}))};function tt(e,t,n){if(void 0===n&&(n={}),"string"!=typeof t)throw new Error("Invalid format in fecha parse");if(t=$e[t]||t,e.length>1e3)return null;var r={year:(new Date).getFullYear(),month:0,day:1,hour:0,minute:0,second:0,millisecond:0,isPm:null,timezoneOffset:null},a=[],i=[],o=t.replace(Oe,(function(e,t){return i.push(Ve(t)),"@@@"})),s={},l={};o=Ve(o).replace(Te,(function(e){var t=Je[e],n=t[0],r=t[1],i=t[3];if(s[n])throw new Error("Invalid format. "+n+" specified twice in format");return s[n]=!0,i&&(l[i]=!0),a.push(t),"("+r+")"})),Object.keys(l).forEach((function(e){if(!s[e])throw new Error("Invalid format. "+e+" is required in specified format")})),o=o.replace(/@@@/g,(function(){return i.shift()}));var u=e.match(new RegExp(o,"i"));if(!u)return null;for(var c,d=Ne(Ne({},Ze),n),p=1;p11||r.month<0||r.day>31||r.day<1||r.hour>23||r.hour<0||r.minute>59||r.minute<0||r.second>59||r.second<0)return null;return c}var nt={format:et,parse:tt,defaultI18n:je,setGlobalDateI18n:Ue,setGlobalDateMasks:Qe};var rt="format";function at(e,t){return(r[rt]||nt[rt])(e,t)}function it(e){return(0,x.HD)(e)&&(e=e.indexOf("T")>0?new Date(e).getTime():new Date(e.replace(/-/gi,"/")).getTime()),(0,x.J_)(e)&&(e=e.getTime()),e}var ot=1e3,st=6e4,lt=36e5,ut=24*lt,ct=31*ut,dt=365*ut,pt=[["HH:mm:ss",ot],["HH:mm:ss",1e4],["HH:mm:ss",3e4],["HH:mm",st],["HH:mm",6e5],["HH:mm",18e5],["HH",lt],["HH",6*lt],["HH",12*lt],["YYYY-MM-DD",ut],["YYYY-MM-DD",4*ut],["YYYY-WW",7*ut],["YYYY-MM",ct],["YYYY-MM",4*ct],["YYYY-MM",6*ct],["YYYY",380*ut]];function ht(e,t,n){var r,a=(r=function(e){return e[1]},function(e,t,n,a){for(var i=(0,x.UM)(n)?0:n,o=(0,x.UM)(a)?e.length:a;i>>1;r(e[s])>t?o=s:i=s+1}return i})(pt,(t-e)/n)-1,i=pt[a];return a<0?i=pt[0]:a>=pt.length&&(i=(0,x.Z$)(pt)),i}var ft=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="timeCat",t}return(0,y.ZT)(t,e),t.prototype.translate=function(e){e=it(e);var t=this.values.indexOf(e);return-1===t&&(t=(0,x.hj)(e)&&e-1){var r=this.values[n],a=this.formatter;return r=a?a(r,t):at(r,this.mask)}return e},t.prototype.initCfg=function(){this.tickMethod="time-cat",this.mask="YYYY-MM-DD",this.tickCount=7},t.prototype.setDomain=function(){var t=this.values;(0,x.S6)(t,(function(e,n){t[n]=it(e)})),t.sort((function(e,t){return e-t})),e.prototype.setDomain.call(this)},t}(Me),vt=ft,mt=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.isContinuous=!0,t}return(0,y.ZT)(t,e),t.prototype.scale=function(e){if((0,x.UM)(e))return NaN;var t=this.rangeMin(),n=this.rangeMax();return this.max===this.min?t:t+this.getScalePercent(e)*(n-t)},t.prototype.init=function(){e.prototype.init.call(this);var t=this.ticks,n=(0,x.YM)(t),r=(0,x.Z$)(t);nthis.max&&(this.max=r),(0,x.UM)(this.minLimit)||(this.min=n),(0,x.UM)(this.maxLimit)||(this.max=r)},t.prototype.setDomain=function(){var e=(0,x.rx)(this.values),t=e.min,n=e.max;(0,x.UM)(this.min)&&(this.min=t),(0,x.UM)(this.max)&&(this.max=n),this.min>this.max&&(this.min=t,this.max=n)},t.prototype.calculateTicks=function(){var t=this,n=e.prototype.calculateTicks.call(this);return this.nice||(n=(0,x.hX)(n,(function(e){return e>=t.min&&e<=t.max}))),n},t.prototype.getScalePercent=function(e){var t=this.max,n=this.min;return(e-n)/(t-n)},t.prototype.getInvertPercent=function(e){return(e-this.rangeMin())/(this.rangeMax()-this.rangeMin())},t}(Ce),gt=mt,yt=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="linear",t.isLinear=!0,t}return(0,y.ZT)(t,e),t.prototype.invert=function(e){var t=this.getInvertPercent(e);return this.min+t*(this.max-this.min)},t.prototype.initCfg=function(){this.tickMethod="wilkinson-extended",this.nice=!1},t}(gt),xt=yt;function It(e,t){var n=Math.E;return t>=0?Math.pow(n,Math.log(t)/e):-1*Math.pow(n,Math.log(-t)/e)}function _t(e,t){return 1===e?1:Math.log(t)/Math.log(e)}function bt(e,t,n){(0,x.UM)(n)&&(n=Math.max.apply(null,e));var r=n;return(0,x.S6)(e,(function(e){e>0&&e1&&(r=1),r}var wt=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="log",t}return(0,y.ZT)(t,e),t.prototype.invert=function(e){var t,n=this.base,r=_t(n,this.max),a=this.rangeMin(),i=this.rangeMax()-a,o=this.positiveMin;if(o){if(0===e)return 0;var s=1/(r-(t=_t(n,o/n)))*i;if(e=0?1:-1;return Math.pow(i,n)*o},t.prototype.initCfg=function(){this.tickMethod="pow",this.exponent=2,this.tickCount=5,this.nice=!0},t.prototype.getScalePercent=function(e){var t=this.max,n=this.min;if(t===n)return 0;var r=this.exponent;return(It(r,e)-It(r,n))/(It(r,t)-It(r,n))},t}(gt),Ct=Et,kt=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="time",t}return(0,y.ZT)(t,e),t.prototype.getText=function(e,t){var n=this.translate(e),r=this.formatter;return r?r(n,t):at(n,this.mask)},t.prototype.scale=function(t){var n=t;return((0,x.HD)(n)||(0,x.J_)(n))&&(n=this.translate(n)),e.prototype.scale.call(this,n)},t.prototype.translate=function(e){return it(e)},t.prototype.initCfg=function(){this.tickMethod="time-pretty",this.mask="YYYY-MM-DD",this.tickCount=7,this.nice=!1},t.prototype.setDomain=function(){var e=this.values,t=this.getConfig("min"),n=this.getConfig("max");if((0,x.UM)(t)&&(0,x.hj)(t)||(this.min=this.translate(this.min)),(0,x.UM)(n)&&(0,x.hj)(n)||(this.max=this.translate(this.max)),e&&e.length){var r=[],a=1/0,i=a,o=0;(0,x.S6)(e,(function(e){var t=it(e);if(isNaN(t))throw new TypeError("Invalid Time: "+e+" in time scale!");a>t?(i=a,a=t):i>t&&(i=t),o1&&(this.minTickInterval=i-a),(0,x.UM)(t)&&(this.min=a),(0,x.UM)(n)&&(this.max=o)}},t}(xt),Mt=kt,Tt=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="quantize",t}return(0,y.ZT)(t,e),t.prototype.invert=function(e){var t=this.ticks,n=t.length,r=this.getInvertPercent(e),a=Math.floor(r*(n-1));if(a>=n-1)return(0,x.Z$)(t);if(a<0)return(0,x.YM)(t);var i=t[a],o=a/(n-1);return i+(r-o)/((a+1)/(n-1)-o)*(t[a+1]-i)},t.prototype.initCfg=function(){this.tickMethod="r-pretty",this.tickCount=5,this.nice=!0},t.prototype.calculateTicks=function(){var t=e.prototype.calculateTicks.call(this);return this.nice||((0,x.Z$)(t)!==this.max&&t.push(this.max),(0,x.YM)(t)!==this.min&&t.unshift(this.min)),t},t.prototype.getScalePercent=function(e){var t=this.ticks;if(e<(0,x.YM)(t))return 0;if(e>(0,x.Z$)(t))return 1;var n=0;return(0,x.S6)(t,(function(t,r){if(!(e>=t))return!1;n=r})),n/(t.length-1)},t}(gt),At=Tt,Lt=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="quantile",t}return(0,y.ZT)(t,e),t.prototype.initCfg=function(){this.tickMethod="quantile",this.tickCount=5,this.nice=!0},t}(At),Pt=Lt,Ot={};function Rt(e){return Ot[e]}function Dt(e,t){if(Rt(e))throw new Error("type '"+e+"' existed.");Ot[e]=t}var Nt=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="identity",t.isIdentity=!0,t}return(0,y.ZT)(t,e),t.prototype.calculateTicks=function(){return this.values},t.prototype.scale=function(e){return this.values[0]!==e&&(0,x.hj)(e)?e:this.range[0]},t.prototype.invert=function(e){var t=this.range;return et[1]?NaN:this.values[0]},t}(Ce),zt=Nt;function Ft(e){var t=e.values,n=e.tickInterval,r=e.tickCount,a=e.showLast;if((0,x.hj)(n)){var i=(0,x.hX)(t,(function(e,t){return t%n==0})),o=(0,x.Z$)(t);return a&&(0,x.Z$)(i)!==o&&i.push(o),i}var s=t.length,l=e.min,u=e.max;if((0,x.UM)(l)&&(l=0),(0,x.UM)(u)&&(u=t.length-1),!(0,x.hj)(r)||r>=s)return t.slice(l,u+1);if(r<=0||u<=0)return[];for(var c=1===r?s:Math.floor(s/(r-1)),d=[],p=l,h=0;h=u);h++)p=Math.min(l+h*c,u),h===r-1&&a?d.push(t[u]):d.push(t[p]);return d}var Bt=Math.sqrt(50),jt=Math.sqrt(10),Zt=Math.sqrt(2),Ut=function(){function e(){this._domain=[0,1]}return e.prototype.domain=function(e){return e?(this._domain=Array.from(e,Number),this):this._domain.slice()},e.prototype.nice=function(e){var t,n;void 0===e&&(e=5);var r,a=this._domain.slice(),i=0,o=this._domain.length-1,s=this._domain[i],l=this._domain[o];return l0?r=Vt(s=Math.floor(s/r)*r,l=Math.ceil(l/r)*r,e):r<0&&(r=Vt(s=Math.ceil(s*r)/r,l=Math.floor(l*r)/r,e)),r>0?(a[i]=Math.floor(s/r)*r,a[o]=Math.ceil(l/r)*r,this.domain(a)):r<0&&(a[i]=Math.ceil(s*r)/r,a[o]=Math.floor(l*r)/r,this.domain(a)),this},e.prototype.ticks=function(e){return void 0===e&&(e=5),function(e,t,n){var r,a,i,o,s=-1;if(n=+n,(e=+e)===(t=+t)&&n>0)return[e];(r=t0)for(e=Math.ceil(e/o),t=Math.floor(t/o),i=new Array(a=Math.ceil(t-e+1));++s=0?(i>=Bt?10:i>=jt?5:i>=Zt?2:1)*Math.pow(10,a):-Math.pow(10,-a)/(i>=Bt?10:i>=jt?5:i>=Zt?2:1)}function Ht(e,t,n){return("ceil"===n?Math.ceil(e/t):"floor"===n?Math.floor(e/t):Math.round(e/t))*t}function Gt(e,t,n){var r=Ht(e,n,"floor"),a=Ht(t,n,"ceil");r=(0,x.ri)(r,n),a=(0,x.ri)(a,n);for(var i=[],o=Math.max((a-r)/(Math.pow(2,12)-1),n),s=r;s<=a;s+=o){var l=(0,x.ri)(s,o);i.push(l)}return{min:r,max:a,ticks:i}}function qt(e,t,n){var r,a=e.minLimit,i=e.maxLimit,o=e.min,s=e.max,l=e.tickCount,u=void 0===l?5:l,c=(0,x.UM)(a)?(0,x.UM)(t)?o:t:a,d=(0,x.UM)(i)?(0,x.UM)(n)?s:n:i;if(c>d&&(d=(r=[c,d])[0],c=r[1]),u<=2)return[c,d];for(var p=(d-c)/(u-1),h=[],f=0;f=0&&(l=1),1-s/(o-1)-n+l}function Jt(e,t,n){var r=(0,x.dp)(t);return 1-(0,x.cq)(t,e)/(r-1)-n+1}function $t(e,t,n,r,a,i){var o=(e-1)/(i-a),s=(t-1)/(Math.max(i,r)-Math.min(n,a));return 2-Math.max(o/s,s/o)}function Qt(e,t){return e>=t?2-(e-1)/(t-1):1}function en(e,t,n,r){var a=t-e;return 1-.5*(Math.pow(t-r,2)+Math.pow(e-n,2))/Math.pow(.1*a,2)}function tn(e,t,n){var r=t-e;if(n>r){var a=(n-r)/2;return 1-Math.pow(a,2)/Math.pow(.1*r,2)}return 1}function nn(e,t,n,r,a,i){void 0===n&&(n=5),void 0===r&&(r=!0),void 0===a&&(a=Yt),void 0===i&&(i=[.25,.2,.5,.05]);var o=n<0?0:Math.round(n);if(Number.isNaN(e)||Number.isNaN(t)||"number"!=typeof e||"number"!=typeof t||!o)return{min:0,max:0,ticks:[]};if(t-e<1e-15||1===o)return{min:e,max:t,ticks:[e]};if(t-e>1e148){var s=(t-e)/(b=n||5);return{min:e,max:t,ticks:Array(b).fill(null).map((function(t,n){return Wt(e+s*n)}))}}for(var l={score:-2,lmin:0,lmax:0,lstep:0},u=1;u<1/0;){for(var c=0;cl.score&&(!r||S<=e&&E>=t)&&(l.lmin=S,l.lmax=E,l.lstep=C,l.score=A)}m+=1}h+=1}}u+=1}var L=Wt(l.lmax),P=Wt(l.lmin),O=Wt(l.lstep),R=Math.floor(function(e){return Math.round(1e12*e)/1e12}((L-P)/O))+1,D=new Array(R);D[0]=Wt(P);for(c=1;c1&&(a*=Math.ceil(o)),r&&adt)for(var l=on(n),u=Math.ceil(i/dt),c=s;c<=l+u;c+=u)o.push(sn(c));else if(i>ct){var d=Math.ceil(i/ct),p=ln(t),h=function(e,t){var n=on(e),r=on(t),a=ln(e);return 12*(r-n)+(ln(t)-a)%12}(t,n);for(c=0;c<=h+d;c+=d)o.push(un(s,c+p))}else if(i>ut){var f=(x=new Date(t)).getFullYear(),v=x.getMonth(),m=x.getDate(),g=Math.ceil(i/ut),y=function(e,t){return Math.ceil((t-e)/ut)}(t,n);for(c=0;clt){f=(x=new Date(t)).getFullYear(),v=x.getMonth(),g=x.getDate();var x,I=x.getHours(),_=Math.ceil(i/lt),b=function(e,t){return Math.ceil((t-e)/lt)}(t,n);for(c=0;c<=b+_;c+=_)o.push(new Date(f,v,g,I+c).getTime())}else if(i>st){var w=function(e,t){return Math.ceil((t-e)/6e4)}(t,n),S=Math.ceil(i/st);for(c=0;c<=w+S;c+=S)o.push(t+c*st)}else{var E=i;E=512&&console.warn("Notice: current ticks length("+o.length+') >= 512, may cause performance issues, even out of memory. Because of the configure "tickInterval"(in milliseconds, current is '+i+") is too small, increase the value to solve the problem!"),o})),Ee("log",(function(e){var t,n=e.base,r=e.tickCount,a=e.min,i=e.max,o=e.values,s=_t(n,i);if(a>0)t=Math.floor(_t(n,a));else{var l=bt(o,n,i);t=Math.floor(_t(n,l))}for(var u=s-t,c=Math.ceil(u/r),d=[],p=t;p=0?1:-1;return Math.pow(e,t)*n}))})),Ee("quantile",(function(e){var t=e.tickCount,n=e.values;if(!n||!n.length)return[];for(var r=n.slice().sort((function(e,t){return e-t})),a=[],i=0;i=0&&this.radius<=1&&(n*=this.radius),this.d=Math.floor(n*(1-this.innerRadius)/t),this.a=this.d/(2*Math.PI),this.x={start:this.startAngle,end:this.endAngle},this.y={start:this.innerRadius*n,end:this.innerRadius*n+.99*this.d}},t.prototype.convertPoint=function(e){var t,n=e.x,r=e.y;this.isTransposed&&(n=(t=[r,n])[0],r=t[1]);var a=this.convertDim(n,"x"),i=this.a*a,o=this.convertDim(r,"y");return{x:this.center.x+Math.cos(a)*(i+o),y:this.center.y+Math.sin(a)*(i+o)}},t.prototype.invertPoint=function(e){var t,n=this.d+this.y.start,r=In.$X([0,0],[e.x,e.y],[this.center.x,this.center.y]),a=vn.Dg(r,[1,0],!0),i=a*this.a;In.kE(r)this.width/r?(t=this.width/r,this.circleCenter={x:this.center.x-(.5-i)*this.width,y:this.center.y-(.5-o)*t*a}):(t=this.height/a,this.circleCenter={x:this.center.x-(.5-i)*t*r,y:this.center.y-(.5-o)*this.height}),this.polarRadius=this.radius,this.radius?this.radius>0&&this.radius<=1?this.polarRadius=t*this.radius:(this.radius<=0||this.radius>t)&&(this.polarRadius=t):this.polarRadius=t,this.x={start:this.startAngle,end:this.endAngle},this.y={start:this.innerRadius*this.polarRadius,end:this.polarRadius}},t.prototype.getRadius=function(){return this.polarRadius},t.prototype.convertPoint=function(e){var t,n=this.getCenter(),r=e.x,a=e.y;return this.isTransposed&&(r=(t=[a,r])[0],a=t[1]),r=this.convertDim(r,"x"),a=this.convertDim(a,"y"),{x:n.x+Math.cos(r)*a,y:n.y+Math.sin(r)*a}},t.prototype.invertPoint=function(e){var t,n=this.getCenter(),r=[e.x-n.x,e.y-n.y],a=this.startAngle,i=this.endAngle;this.isReflect("x")&&(a=(t=[i,a])[0],i=t[1]);var o=[1,0,0,0,1,0,0,0,1];vn.zu(o,o,a);var s=[1,0,0];hn.transformMat3(s,s,o);var l=[s[0],s[1]],u=vn.Dg(l,r,i0?d:-d;var p=this.invertDim(c,"y"),h={x:0,y:0};return h.x=this.isTransposed?p:d,h.y=this.isTransposed?d:p,h},t.prototype.getCenter=function(){return this.circleCenter},t.prototype.getOneBox=function(){var e=this.startAngle,t=this.endAngle;if(Math.abs(t-e)>=2*Math.PI)return{minX:-1,maxX:1,minY:-1,maxY:1};for(var n=[0,Math.cos(e),Math.cos(t)],r=[0,Math.sin(e),Math.sin(t)],a=Math.min(e,t);a=0;n--)e.removeChild(t[n])}function Nn(e){var t=e.start,n=e.end,r=Math.min(t.x,n.x),a=Math.min(t.y,n.y),i=Math.max(t.x,n.x),o=Math.max(t.y,n.y);return{x:r,y:a,minX:r,minY:a,maxX:i,maxY:o,width:i-r,height:o-a}}function zn(e,t,n,r){var a=e+n,i=t+r;return{x:e,y:t,width:n,height:r,minX:e,minY:t,maxX:isNaN(a)?0:a,maxY:isNaN(i)?0:i}}function Fn(e,t,n){return(1-n)*e+t*n}function Bn(e,t,n){return{x:e.x+Math.cos(n)*t,y:e.y+Math.sin(n)*t}}var jn=function(e,t,n){return void 0===n&&(n=Math.pow(Number.EPSILON,.5)),[e,t].includes(1/0)?Math.abs(e)===Math.abs(t):Math.abs(e-t)0?(0,x.S6)(p,(function(e){if(e.get("visible")){if(e.isGroup()&&0===e.get("children").length)return!0;var t=Zn(e),n=e.applyToMatrix([t.minX,t.minY,1]),r=e.applyToMatrix([t.minX,t.maxY,1]),a=e.applyToMatrix([t.maxX,t.minY,1]),i=e.applyToMatrix([t.maxX,t.maxY,1]),o=Math.min(n[0],r[0],a[0],i[0]),s=Math.max(n[0],r[0],a[0],i[0]),p=Math.min(n[1],r[1],a[1],i[1]),h=Math.max(n[1],r[1],a[1],i[1]);ou&&(u=s),pd&&(d=h)}})):(l=0,u=0,c=0,d=0),t=zn(l,c,u-l,d-c)}else t=e.getBBox();return s?(n=t,r=s,a=Math.max(n.minX,r.minX),i=Math.max(n.minY,r.minY),zn(a,i,Math.min(n.maxX,r.maxX)-a,Math.min(n.maxY,r.maxY)-i)):t}function Un(e){return e+"px"}function Vn(e,t,n,r){var a,i,o,s,l=r/(a=e,o=(i=t).x-a.x,s=i.y-a.y,Math.sqrt(o*o+s*s)),u=0;return"start"===n?u=0-l:"end"===n&&(u=1+l),{x:Fn(e.x,t.x,u),y:Fn(e.y,t.y,u)}}var Hn={none:[],point:["x","y"],region:["start","end"],points:["points"],circle:["center","radius","startAngle","endAngle"]},Gn=function(e){function t(t){var n=e.call(this,t)||this;return n.initCfg(),n}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){return{id:"",name:"",type:"",locationType:"none",offsetX:0,offsetY:0,animate:!1,capture:!0,updateAutoRender:!1,animateOption:{appear:null,update:{duration:400,easing:"easeQuadInOut"},enter:{duration:400,easing:"easeQuadInOut"},leave:{duration:350,easing:"easeQuadIn"}},events:null,defaultCfg:{},visible:!0}},t.prototype.clear=function(){},t.prototype.update=function(e){var t=this,n=this.get("defaultCfg")||{};(0,x.S6)(e,(function(e,r){var a=e;t.get(r)!==e&&((0,x.Kn)(e)&&n[r]&&(a=(0,x.b$)({},n[r],e)),t.set(r,a))})),this.updateInner(e),this.afterUpdate(e)},t.prototype.updateInner=function(e){},t.prototype.afterUpdate=function(e){(0,x.wH)(e,"visible")&&(e.visible?this.show():this.hide()),(0,x.wH)(e,"capture")&&this.setCapture(e.capture)},t.prototype.getLayoutBBox=function(){return this.getBBox()},t.prototype.getLocationType=function(){return this.get("locationType")},t.prototype.getOffset=function(){return{offsetX:this.get("offsetX"),offsetY:this.get("offsetY")}},t.prototype.setOffset=function(e,t){this.update({offsetX:e,offsetY:t})},t.prototype.setLocation=function(e){var t=(0,y.pi)({},e);this.update(t)},t.prototype.getLocation=function(){var e=this,t={},n=this.get("locationType"),r=Hn[n];return(0,x.S6)(r,(function(n){t[n]=e.get(n)})),t},t.prototype.isList=function(){return!1},t.prototype.isSlider=function(){return!1},t.prototype.init=function(){},t.prototype.initCfg=function(){var e=this,t=this.get("defaultCfg");(0,x.S6)(t,(function(t,n){var r=e.get(n);if((0,x.Kn)(r)){var a=(0,x.b$)({},t,r);e.set(n,a)}}))},t}(F.Base),qn="update_status",Wn=["visible","tip","delegateObject"],Yn=["container","group","shapesMap","isRegister","isUpdating","destroyed"],Xn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{container:null,shapesMap:{},group:null,capture:!0,isRegister:!1,isUpdating:!1,isInit:!0})},t.prototype.remove=function(){this.clear(),this.get("group").remove()},t.prototype.clear=function(){this.get("group").clear(),this.set("shapesMap",{}),this.clearOffScreenCache(),this.set("isInit",!0)},t.prototype.getChildComponentById=function(e){var t=this.getElementById(e);return t&&t.get("component")},t.prototype.getElementById=function(e){return this.get("shapesMap")[e]},t.prototype.getElementByLocalId=function(e){var t=this.getElementId(e);return this.getElementById(t)},t.prototype.getElementsByName=function(e){var t=[];return(0,x.S6)(this.get("shapesMap"),(function(n){n.get("name")===e&&t.push(n)})),t},t.prototype.getContainer=function(){return this.get("container")},t.prototype.updateInner=function(e){this.offScreenRender(),this.get("updateAutoRender")&&this.render()},t.prototype.render=function(){var e=this.get("offScreenGroup");e||(e=this.offScreenRender());var t=this.get("group");this.updateElements(e,t),this.deleteElements(),this.applyOffset(),this.get("eventInitted")||(this.initEvent(),this.set("eventInitted",!0)),this.set("isInit",!1)},t.prototype.show=function(){this.get("group").show(),this.set("visible",!0)},t.prototype.hide=function(){this.get("group").hide(),this.set("visible",!1)},t.prototype.setCapture=function(e){this.get("group").set("capture",e),this.set("capture",e)},t.prototype.destroy=function(){this.removeEvent(),this.remove(),e.prototype.destroy.call(this)},t.prototype.getBBox=function(){return this.get("group").getCanvasBBox()},t.prototype.getLayoutBBox=function(){var e=this.get("group"),t=this.getInnerLayoutBBox(),n=e.getTotalMatrix();return n&&(t=function(e,t){var n=Ln(e,[t.minX,t.minY]),r=Ln(e,[t.maxX,t.minY]),a=Ln(e,[t.minX,t.maxY]),i=Ln(e,[t.maxX,t.maxY]),o=Math.min(n[0],r[0],a[0],i[0]),s=Math.max(n[0],r[0],a[0],i[0]),l=Math.min(n[1],r[1],a[1],i[1]),u=Math.max(n[1],r[1],a[1],i[1]);return{x:o,y:l,minX:o,minY:l,maxX:s,maxY:u,width:s-o,height:u-l}}(n,t)),t},t.prototype.on=function(e,t,n){return this.get("group").on(e,t,n),this},t.prototype.off=function(e,t){var n=this.get("group");return n&&n.off(e,t),this},t.prototype.emit=function(e,t){this.get("group").emit(e,t)},t.prototype.init=function(){e.prototype.init.call(this),this.get("group")||this.initGroup(),this.offScreenRender()},t.prototype.getInnerLayoutBBox=function(){return this.get("offScreenBBox")||this.get("group").getBBox()},t.prototype.delegateEmit=function(e,t){var n=this.get("group");t.target=n,n.emit(e,t),kn(n,e,t)},t.prototype.createOffScreenGroup=function(){return new(this.get("group").getGroupBase())({delegateObject:this.getDelegateObject()})},t.prototype.applyOffset=function(){var e=this.get("offsetX"),t=this.get("offsetY");this.moveElementTo(this.get("group"),{x:e,y:t})},t.prototype.initGroup=function(){var e=this.get("container");this.set("group",e.addGroup({id:this.get("id"),name:this.get("name"),capture:this.get("capture"),visible:this.get("visible"),isComponent:!0,component:this,delegateObject:this.getDelegateObject()}))},t.prototype.offScreenRender=function(){this.clearOffScreenCache();var e=this.createOffScreenGroup();return this.renderInner(e),this.set("offScreenGroup",e),this.set("offScreenBBox",Zn(e)),e},t.prototype.addGroup=function(e,t){this.appendDelegateObject(e,t);var n=e.addGroup(t);return this.get("isRegister")&&this.registerElement(n),n},t.prototype.addShape=function(e,t){this.appendDelegateObject(e,t);var n=e.addShape(t);return this.get("isRegister")&&this.registerElement(n),n},t.prototype.addComponent=function(e,t){var n=t.id,r=t.component,a=(0,y._T)(t,["id","component"]),i=new r((0,y.pi)((0,y.pi)({},a),{id:n,container:e,updateAutoRender:this.get("updateAutoRender")}));return i.init(),i.render(),this.get("isRegister")&&this.registerElement(i.get("group")),i},t.prototype.initEvent=function(){},t.prototype.removeEvent=function(){this.get("group").off()},t.prototype.getElementId=function(e){return this.get("id")+"-"+this.get("name")+"-"+e},t.prototype.registerElement=function(e){var t=e.get("id");this.get("shapesMap")[t]=e},t.prototype.unregisterElement=function(e){var t=e.get("id");delete this.get("shapesMap")[t]},t.prototype.moveElementTo=function(e,t){var n=An(t);e.attr("matrix",n)},t.prototype.addAnimation=function(e,t,n){var r=t.attr("opacity");(0,x.UM)(r)&&(r=1),t.attr("opacity",0),t.animate({opacity:r},n)},t.prototype.removeAnimation=function(e,t,n){t.animate({opacity:0},n)},t.prototype.updateAnimation=function(e,t,n,r){t.animate(n,r)},t.prototype.updateElements=function(e,t){var n,r=this,a=this.get("animate"),i=this.get("animateOption"),o=e.getChildren().slice(0);(0,x.S6)(o,(function(e){var o=e.get("id"),s=r.getElementById(o),l=e.get("name");if(s)if(e.get("isComponent")){var u=e.get("component"),c=s.get("component"),d=(0,x.ei)(u.cfg,(0,x.e5)((0,x.XP)(u.cfg),Yn));c.update(d),s.set(qn,"update")}else{var p=r.getReplaceAttrs(s,e);a&&i.update?r.updateAnimation(l,s,p,i.update):s.attr(p),e.isGroup()&&r.updateElements(e,s),(0,x.S6)(Wn,(function(t){s.set(t,e.get(t))})),function(e,t){if(e.getClip()||t.getClip()){var n=t.getClip();if(n){var r={type:n.get("type"),attrs:n.attr()};e.setClip(r)}else e.setClip(null)}}(s,e),n=s,s.set(qn,"update")}else{t.add(e);var h=t.getChildren();if(h.splice(h.length-1,1),n){var f=h.indexOf(n);h.splice(f+1,0,e)}else h.unshift(e);if(r.registerElement(e),e.set(qn,"add"),e.get("isComponent"))(u=e.get("component")).set("container",t);else e.isGroup()&&r.registerNewGroup(e);if(n=e,a){var v=r.get("isInit")?i.appear:i.enter;v&&r.addAnimation(l,e,v)}}}))},t.prototype.clearUpdateStatus=function(e){var t=e.getChildren();(0,x.S6)(t,(function(e){e.set(qn,null)}))},t.prototype.clearOffScreenCache=function(){var e=this.get("offScreenGroup");e&&e.destroy(),this.set("offScreenGroup",null),this.set("offScreenBBox",null)},t.prototype.getDelegateObject=function(){var e;return(e={})[this.get("name")]=this,e.component=this,e},t.prototype.appendDelegateObject=function(e,t){var n=e.get("delegateObject");t.delegateObject||(t.delegateObject={}),(0,x.CD)(t.delegateObject,n)},t.prototype.getReplaceAttrs=function(e,t){var n=e.attr(),r=t.attr();return(0,x.S6)(n,(function(e,t){void 0===r[t]&&(r[t]=void 0)})),r},t.prototype.registerNewGroup=function(e){var t=this,n=e.getChildren();(0,x.S6)(n,(function(e){t.registerElement(e),e.set(qn,"add"),e.isGroup()&&t.registerNewGroup(e)}))},t.prototype.deleteElements=function(){var e=this,t=this.get("shapesMap"),n=[];(0,x.S6)(t,(function(e,t){!e.get(qn)||e.destroyed?n.push([t,e]):e.set(qn,null)}));var r=this.get("animate"),a=this.get("animateOption");(0,x.S6)(n,(function(n){var i=n[0],o=n[1];if(!o.destroyed){var s=o.get("name");if(r&&a.leave){var l=(0,x.CD)({callback:function(){e.removeElement(o)}},a.leave);e.removeAnimation(s,o,l)}else e.removeElement(o)}delete t[i]}))},t.prototype.removeElement=function(e){if(e.get("isGroup")){var t=e.get("component");t&&t.destroy()}e.remove()},t}(Gn),Kn=Xn;function Jn(e,t){return e.charCodeAt(t)>0&&e.charCodeAt(t)<128?1:2}function $n(e){if(e.length>400)return function(e){for(var t=e.map((function(e){var t=e.attr("text");return(0,x.UM)(t)?"":""+t})),n=0,r=0,a=0;a=19968&&s<=40869?2:1}i>n&&(n=i,r=a)}return e[r].getBBox().width}(e);var t=0;return(0,x.S6)(e,(function(e){var n=e.getBBox().width;t=0?function(e,t,n){void 0===n&&(n="tail");var r=e.length,a="";if("tail"===n){for(var i=0,o=0;i1||r<0)&&(r=1),{x:Fn(e.x,t.x,r),y:Fn(e.y,t.y,r)}},t.prototype.renderLabel=function(e){var t=this.get("text"),n=this.get("start"),r=this.get("end"),a=t.position,i=t.content,o=t.style,s=t.offsetX,l=t.offsetY,u=t.autoRotate,c=t.maxLength,d=t.autoEllipsis,p=t.ellipsisPosition,h=t.background,f=t.isVertical,v=void 0!==f&&f,m=this.getLabelPoint(n,r,a),g=m.x+s,y=m.y+l,x={id:this.getElementId("line-text"),name:"annotation-line-text",x:g,y:y,content:i,style:o,maxLength:c,autoEllipsis:d,ellipsisPosition:p,background:h,isVertical:v};if(u){var I=[r.x-n.x,r.y-n.y];x.rotate=Math.atan2(I[1],I[0])}er(e,x)},t}(Kn),rr=nr,ar=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{name:"annotation",type:"text",locationType:"point",x:0,y:0,content:"",rotate:null,style:{},background:null,maxLength:null,autoEllipsis:!0,isVertical:!1,ellipsisPosition:"tail",defaultCfg:{style:{fill:tr.textColor,fontSize:12,textAlign:"center",textBaseline:"middle",fontFamily:tr.fontFamily}}})},t.prototype.setLocation=function(e){this.set("x",e.x),this.set("y",e.y),this.resetLocation()},t.prototype.renderInner=function(e){var t=this.getLocation(),n=t.x,r=t.y,a=this.get("content"),i=this.get("style");er(e,{id:this.getElementId("text"),name:this.get("name")+"-text",x:n,y:r,content:a,style:i,maxLength:this.get("maxLength"),autoEllipsis:this.get("autoEllipsis"),isVertical:this.get("isVertical"),ellipsisPosition:this.get("ellipsisPosition"),background:this.get("background"),rotate:this.get("rotate")})},t.prototype.resetLocation=function(){var e=this.getElementByLocalId("text-group");if(e){var t=this.getLocation(),n=t.x,r=t.y,a=this.get("rotate");On(e,n,r),Pn(e,a,n,r)}},t}(Kn),ir=ar,or=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{name:"annotation",type:"arc",locationType:"circle",center:null,radius:100,startAngle:-Math.PI/2,endAngle:3*Math.PI/2,style:{stroke:"#999",lineWidth:1}})},t.prototype.renderInner=function(e){this.renderArc(e)},t.prototype.getArcPath=function(){var e=this.getLocation(),t=e.center,n=e.radius,r=e.startAngle,a=e.endAngle,i=Bn(t,n,r),o=Bn(t,n,a),s=a-r>Math.PI?1:0,l=[["M",i.x,i.y]];if(a-r==2*Math.PI){var u=Bn(t,n,r+Math.PI);l.push(["A",n,n,0,s,1,u.x,u.y]),l.push(["A",n,n,0,s,1,o.x,o.y])}else l.push(["A",n,n,0,s,1,o.x,o.y]);return l},t.prototype.renderArc=function(e){var t=this.getArcPath(),n=this.get("style");this.addShape(e,{type:"path",id:this.getElementId("arc"),name:"annotation-arc",attrs:(0,y.pi)({path:t},n)})},t}(Kn),sr=or,lr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{name:"annotation",type:"region",locationType:"region",start:null,end:null,style:{},defaultCfg:{style:{lineWidth:0,fill:tr.regionColor,opacity:.4}}})},t.prototype.renderInner=function(e){this.renderRegion(e)},t.prototype.renderRegion=function(e){var t=this.get("start"),n=this.get("end"),r=this.get("style"),a=Nn({start:t,end:n});this.addShape(e,{type:"rect",id:this.getElementId("region"),name:"annotation-region",attrs:(0,y.pi)({x:a.x,y:a.y,width:a.width,height:a.height},r)})},t}(Kn),ur=lr,cr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{name:"annotation",type:"image",locationType:"region",start:null,end:null,src:null,style:{}})},t.prototype.renderInner=function(e){this.renderImage(e)},t.prototype.getImageAttrs=function(){var e=this.get("start"),t=this.get("end"),n=this.get("style"),r=Nn({start:e,end:t}),a=this.get("src");return(0,y.pi)({x:r.x,y:r.y,img:a,width:r.width,height:r.height},n)},t.prototype.renderImage=function(e){this.addShape(e,{type:"image",id:this.getElementId("image"),name:"annotation-image",attrs:this.getImageAttrs()})},t}(Kn),dr=cr,pr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{name:"annotation",type:"dataMarker",locationType:"point",x:0,y:0,point:{},line:{},text:{},direction:"upward",autoAdjust:!0,coordinateBBox:null,defaultCfg:{point:{display:!0,style:{r:3,fill:"#FFFFFF",stroke:"#1890FF",lineWidth:2}},line:{display:!0,length:20,style:{stroke:tr.lineColor,lineWidth:1}},text:{content:"",display:!0,style:{fill:tr.textColor,opacity:.65,fontSize:12,textAlign:"start",fontFamily:tr.fontFamily}}}})},t.prototype.renderInner=function(e){(0,x.U2)(this.get("line"),"display")&&this.renderLine(e),(0,x.U2)(this.get("text"),"display")&&this.renderText(e),(0,x.U2)(this.get("point"),"display")&&this.renderPoint(e),this.get("autoAdjust")&&this.autoAdjust(e)},t.prototype.applyOffset=function(){this.moveElementTo(this.get("group"),{x:this.get("x")+this.get("offsetX"),y:this.get("y")+this.get("offsetY")})},t.prototype.renderPoint=function(e){var t=this.getShapeAttrs().point;this.addShape(e,{type:"circle",id:this.getElementId("point"),name:"annotation-point",attrs:t})},t.prototype.renderLine=function(e){var t=this.getShapeAttrs().line;this.addShape(e,{type:"path",id:this.getElementId("line"),name:"annotation-line",attrs:t})},t.prototype.renderText=function(e){var t=this.getShapeAttrs().text,n=t.x,r=t.y,a=t.text,i=(0,y._T)(t,["x","y","text"]),o=this.get("text"),s=o.background,l=o.maxLength,u=o.autoEllipsis,c=o.isVertival,d=o.ellipsisPosition;er(e,{x:n,y:r,id:this.getElementId("text"),name:"annotation-text",content:a,style:i,background:s,maxLength:l,autoEllipsis:u,isVertival:c,ellipsisPosition:d})},t.prototype.autoAdjust=function(e){var t=this.get("direction"),n=this.get("x"),r=this.get("y"),a=(0,x.U2)(this.get("line"),"length",0),i=this.get("coordinateBBox"),o=e.getBBox(),s=o.minX,l=o.maxX,u=o.minY,c=o.maxY,d=e.findById(this.getElementId("text-group")),p=e.findById(this.getElementId("text")),h=e.findById(this.getElementId("line"));if(i){if(d){if(n+s<=i.minX){var f=i.minX-(n+s);On(d,d.attr("x")+f,d.attr("y"))}if(n+l>=i.maxX){f=n+l-i.maxX;On(d,d.attr("x")-f,d.attr("y"))}}if("upward"===t&&r+u<=i.minY||"upward"!==t&&r+c>=i.maxY){var v=void 0,m=void 0;"upward"===t&&r+u<=i.minY?(v="top",m=1):(v="bottom",m=-1),p.attr("textBaseline",v),h&&h.attr("path",[["M",0,0],["L",0,a*m]]),On(d,d.attr("x"),(a+2)*m)}}},t.prototype.getShapeAttrs=function(){var e=(0,x.U2)(this.get("line"),"display"),t=(0,x.U2)(this.get("point"),"style",{}),n=(0,x.U2)(this.get("line"),"style",{}),r=(0,x.U2)(this.get("text"),"style",{}),a=this.get("direction"),i=e?(0,x.U2)(this.get("line"),"length",0):0,o="upward"===a?-1:1;return{point:(0,y.pi)({x:0,y:0},t),line:(0,y.pi)({path:[["M",0,0],["L",0,i*o]]},n),text:(0,y.pi)({x:0,y:(i+2)*o,text:(0,x.U2)(this.get("text"),"content",""),textBaseline:"upward"===a?"bottom":"top"},r)}},t}(Kn),hr=pr,fr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{name:"annotation",type:"dataRegion",locationType:"points",points:[],lineLength:0,region:{},text:{},defaultCfg:{region:{style:{lineWidth:0,fill:tr.regionColor,opacity:.4}},text:{content:"",style:{textAlign:"center",textBaseline:"bottom",fontSize:12,fill:tr.textColor,fontFamily:tr.fontFamily}}}})},t.prototype.renderInner=function(e){var t=(0,x.U2)(this.get("region"),"style",{}),n=((0,x.U2)(this.get("text"),"style",{}),this.get("lineLength")||0),r=this.get("points");if(r.length){var a=function(e){var t=e.map((function(e){return e.x})),n=e.map((function(e){return e.y})),r=Math.min.apply(Math,t),a=Math.min.apply(Math,n),i=Math.max.apply(Math,t),o=Math.max.apply(Math,n);return{x:r,y:a,minX:r,minY:a,maxX:i,maxY:o,width:i-r,height:o-a}}(r),i=[];i.push(["M",r[0].x,a.minY-n]),r.forEach((function(e){i.push(["L",e.x,e.y])})),i.push(["L",r[r.length-1].x,r[r.length-1].y-n]),this.addShape(e,{type:"path",id:this.getElementId("region"),name:"annotation-region",attrs:(0,y.pi)({path:i},t)}),er(e,(0,y.pi)({id:this.getElementId("text"),name:"annotation-text",x:(a.minX+a.maxX)/2,y:a.minY-n},this.get("text")))}},t}(Kn),vr=fr,mr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{name:"annotation",type:"regionFilter",locationType:"region",start:null,end:null,color:null,shape:[]})},t.prototype.renderInner=function(e){var t=this,n=this.get("start"),r=this.get("end"),a=this.addGroup(e,{id:this.getElementId("region-filter"),capture:!1});(0,x.S6)(this.get("shapes"),(function(e,n){var r=e.get("type"),i=(0,x.d9)(e.attr());t.adjustShapeAttrs(i),t.addShape(a,{id:t.getElementId("shape-"+r+"-"+n),capture:!1,type:r,attrs:i})}));var i=Nn({start:n,end:r});a.setClip({type:"rect",attrs:{x:i.minX,y:i.minY,width:i.width,height:i.height}})},t.prototype.adjustShapeAttrs=function(e){var t=this.get("color");e.fill&&(e.fill=e.fillStyle=t),e.stroke=e.strokeStyle=t},t}(Kn),gr=mr,yr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{name:"annotation",type:"shape",draw:x.ZT})},t.prototype.renderInner=function(e){var t=this.get("render");(0,x.mf)(t)&&t(e)},t}(Kn),xr=yr;function Ir(e,t,n){var r;try{r=window.getComputedStyle?window.getComputedStyle(e,null)[t]:e.style[t]}catch(e){}finally{r=void 0===r?n:r}return r}function _r(e,t){var n=function(e,t){var n=Ir(e,"width",t);return"auto"===n&&(n=e.offsetWidth),parseFloat(n)}(e,t),r=parseFloat(Ir(e,"borderLeftWidth"))||0,a=parseFloat(Ir(e,"paddingLeft"))||0,i=parseFloat(Ir(e,"paddingRight"))||0,o=parseFloat(Ir(e,"borderRightWidth"))||0,s=parseFloat(Ir(e,"marginRight"))||0;return n+r+o+a+i+(parseFloat(Ir(e,"marginLeft"))||0)+s}function br(e,t){var n=function(e,t){var n=Ir(e,"height",t);return"auto"===n&&(n=e.offsetHeight),parseFloat(n)}(e,t),r=parseFloat(Ir(e,"borderTopWidth"))||0,a=parseFloat(Ir(e,"paddingTop"))||0,i=parseFloat(Ir(e,"paddingBottom"))||0;return n+r+(parseFloat(Ir(e,"borderBottomWidth"))||0)+a+i+(parseFloat(Ir(e,"marginTop"))||0)+(parseFloat(Ir(e,"marginBottom"))||0)}var wr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{container:null,containerTpl:"
",updateAutoRender:!0,containerClassName:"",parent:null})},t.prototype.getContainer=function(){return this.get("container")},t.prototype.show=function(){this.get("container").style.display="",this.set("visible",!0)},t.prototype.hide=function(){this.get("container").style.display="none",this.set("visible",!1)},t.prototype.setCapture=function(e){var t=e?"auto":"none";this.getContainer().style.pointerEvents=t,this.set("capture",e)},t.prototype.getBBox=function(){var e=this.getContainer();return zn(parseFloat(e.style.left)||0,parseFloat(e.style.top)||0,e.clientWidth,e.clientHeight)},t.prototype.clear=function(){Dn(this.get("container"))},t.prototype.destroy=function(){this.removeEvent(),this.removeDom(),e.prototype.destroy.call(this)},t.prototype.init=function(){e.prototype.init.call(this),this.initContainer(),this.initDom(),this.resetStyles(),this.applyStyles(),this.initEvent(),this.initCapture(),this.initVisible()},t.prototype.initCapture=function(){this.setCapture(this.get("capture"))},t.prototype.initVisible=function(){this.get("visible")?this.show():this.hide()},t.prototype.initDom=function(){},t.prototype.initContainer=function(){var e=this.get("container");if((0,x.UM)(e)){e=this.createDom();var t=this.get("parent");(0,x.HD)(t)&&(t=document.getElementById(t),this.set("parent",t)),t.appendChild(e),this.get("containerId")&&e.setAttribute("id",this.get("containerId")),this.set("container",e)}else(0,x.HD)(e)&&(e=document.getElementById(e),this.set("container",e));this.get("parent")||this.set("parent",e.parentNode)},t.prototype.resetStyles=function(){var e=this.get("domStyles"),t=this.get("defaultStyles");e=e?(0,x.b$)({},t,e):t,this.set("domStyles",e)},t.prototype.applyStyles=function(){var e=this.get("domStyles");if(e){var t=this.getContainer();this.applyChildrenStyles(t,e);var n,r=this.get("containerClassName");if(r&&(n=r,t.className.match(new RegExp("(\\s|^)"+n+"(\\s|$)")))){var a=e[r];(0,O.Z)(t,a)}}},t.prototype.applyChildrenStyles=function(e,t){(0,x.S6)(t,(function(t,n){var r=e.getElementsByClassName(n);(0,x.S6)(r,(function(e){(0,O.Z)(e,t)}))}))},t.prototype.applyStyle=function(e,t){var n=this.get("domStyles");(0,O.Z)(t,n[e])},t.prototype.createDom=function(){var e=this.get("containerTpl");return(0,P.Z)(e)},t.prototype.initEvent=function(){},t.prototype.removeDom=function(){var e=this.get("container");e&&e.parentNode&&e.parentNode.removeChild(e)},t.prototype.removeEvent=function(){},t.prototype.updateInner=function(e){(0,x.wH)(e,"domStyles")&&(this.resetStyles(),this.applyStyles()),this.resetPosition()},t.prototype.resetPosition=function(){},t}(Gn),Sr=wr,Er=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{name:"annotation",type:"html",locationType:"point",x:0,y:0,containerTpl:'
',alignX:"left",alignY:"top",html:"",zIndex:7})},t.prototype.render=function(){var e=this.getContainer(),t=this.get("html");Dn(e);var n=(0,x.mf)(t)?t(e):t;if((0,x.kK)(n))e.appendChild(n);else if((0,x.HD)(n)||(0,x.hj)(n)){var r=(0,P.Z)(""+n);r&&e.appendChild(r)}this.resetPosition()},t.prototype.resetPosition=function(){var e=this.getContainer(),t=this.getLocation(),n=t.x,r=t.y,a=this.get("alignX"),i=this.get("alignY"),o=this.get("offsetX"),s=this.get("offsetY"),l=_r(e),u=br(e),c={x:n,y:r};"middle"===a?c.x-=Math.round(l/2):"right"===a&&(c.x-=Math.round(l)),"middle"===i?c.y-=Math.round(u/2):"bottom"===i&&(c.y-=Math.round(u)),o&&(c.x+=o),s&&(c.y+=s),(0,O.Z)(e,{position:"absolute",left:c.x+"px",top:c.y+"px",zIndex:this.get("zIndex")})},t}(Sr),Cr=Er;function kr(e,t,n){var r=t+"Style",a=null;return(0,x.S6)(n,(function(t,n){e[n]&&t[r]&&(a||(a={}),(0,x.CD)(a,t[r]))})),a}var Mr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{name:"axis",ticks:[],line:{},tickLine:{},subTickLine:null,title:null,label:{},verticalFactor:1,verticalLimitLength:null,overlapOrder:["autoRotate","autoEllipsis","autoHide"],tickStates:{},optimize:{},defaultCfg:{line:{style:{lineWidth:1,stroke:tr.lineColor}},tickLine:{style:{lineWidth:1,stroke:tr.lineColor},alignTick:!0,length:5,displayWithLabel:!0},subTickLine:{style:{lineWidth:1,stroke:tr.lineColor},count:4,length:2},label:{autoRotate:!0,autoHide:!1,autoEllipsis:!1,style:{fontSize:12,fill:tr.textColor,fontFamily:tr.fontFamily,fontWeight:"normal"},offset:10,offsetX:0,offsetY:0},title:{autoRotate:!0,spacing:5,position:"center",style:{fontSize:12,fill:tr.textColor,textBaseline:"middle",fontFamily:tr.fontFamily,textAlign:"center"},iconStyle:{fill:tr.descriptionIconFill,stroke:tr.descriptionIconStroke},description:""},tickStates:{active:{labelStyle:{fontWeight:500},tickLineStyle:{lineWidth:2}},inactive:{labelStyle:{fill:tr.uncheckedColor}}},optimize:{enable:!0,threshold:400}},theme:{}})},t.prototype.renderInner=function(e){this.get("line")&&this.drawLine(e),this.drawTicks(e),this.get("title")&&this.drawTitle(e)},t.prototype.isList=function(){return!0},t.prototype.getItems=function(){return this.get("ticks")},t.prototype.setItems=function(e){this.update({ticks:e})},t.prototype.updateItem=function(e,t){(0,x.CD)(e,t),this.clear(),this.render()},t.prototype.clearItems=function(){var e=this.getElementByLocalId("label-group");e&&e.clear()},t.prototype.setItemState=function(e,t,n){e[t]=n,this.updateTickStates(e)},t.prototype.hasState=function(e,t){return!!e[t]},t.prototype.getItemStates=function(e){var t=this.get("tickStates"),n=[];return(0,x.S6)(t,(function(t,r){e[r]&&n.push(r)})),n},t.prototype.clearItemsState=function(e){var t=this,n=this.getItemsByState(e);(0,x.S6)(n,(function(n){t.setItemState(n,e,!1)}))},t.prototype.getItemsByState=function(e){var t=this,n=this.getItems();return(0,x.hX)(n,(function(n){return t.hasState(n,e)}))},t.prototype.getSidePoint=function(e,t){var n=this.getSideVector(t,e);return{x:e.x+n[0],y:e.y+n[1]}},t.prototype.getTextAnchor=function(e){var t;return(0,x.vQ)(e[0],0)?t="center":e[0]>0?t="start":e[0]<0&&(t="end"),t},t.prototype.getTextBaseline=function(e){var t;return(0,x.vQ)(e[1],0)?t="middle":e[1]>0?t="top":e[1]<0&&(t="bottom"),t},t.prototype.processOverlap=function(e){},t.prototype.drawLine=function(e){var t=this.getLinePath(),n=this.get("line");this.addShape(e,{type:"path",id:this.getElementId("line"),name:"axis-line",attrs:(0,x.CD)({path:t},n.style)})},t.prototype.getTickLineItems=function(e){var t=this,n=[],r=this.get("tickLine"),a=r.alignTick,i=r.length,o=1;return e.length>=2&&(o=e[1].value-e[0].value),(0,x.S6)(e,(function(e){var r=e.point;a||(r=t.getTickPoint(e.value-o/2));var s=t.getSidePoint(r,i);n.push({startPoint:r,tickValue:e.value,endPoint:s,tickId:e.id,id:"tickline-"+e.id})})),n},t.prototype.getSubTickLineItems=function(e){var t=[],n=this.get("subTickLine"),r=n.count,a=e.length;if(a>=2)for(var i=0;i0){var n=(0,x.dp)(t);if(n>e.threshold){var r=Math.ceil(n/e.threshold),a=t.filter((function(e,t){return t%r==0}));this.set("ticks",a),this.set("originalTicks",t)}}},t.prototype.getLabelAttrs=function(e,t,n){var r=this.get("label"),a=r.offset,i=r.offsetX,o=r.offsetY,s=r.rotate,l=r.formatter,u=this.getSidePoint(e.point,a),c=this.getSideVector(a,u),d=l?l(e.name,e,t):e.name,p=r.style;p=(0,x.mf)(p)?(0,x.U2)(this.get("theme"),["label","style"],{}):p;var h=(0,x.CD)({x:u.x+i,y:u.y+o,text:d,textAlign:this.getTextAnchor(c),textBaseline:this.getTextBaseline(c)},p);return s&&(h.matrix=Tn(u,s)),h},t.prototype.drawLabels=function(e){var t=this,n=this.get("ticks"),r=this.addGroup(e,{name:"axis-label-group",id:this.getElementId("label-group")});(0,x.S6)(n,(function(e,a){t.addShape(r,{type:"text",name:"axis-label",id:t.getElementId("label-"+e.id),attrs:t.getLabelAttrs(e,a,n),delegateObject:{tick:e,item:e,index:a}})})),this.processOverlap(r);var a=r.getChildren(),i=(0,x.U2)(this.get("theme"),["label","style"],{}),o=this.get("label"),s=o.style,l=o.formatter;if((0,x.mf)(s)){var u=a.map((function(e){return(0,x.U2)(e.get("delegateObject"),"tick")}));(0,x.S6)(a,(function(e,t){var n=e.get("delegateObject").tick,r=l?l(n.name,n,t):n.name,a=(0,x.CD)({},i,s(r,t,u));e.attr(a)}))}},t.prototype.getTitleAttrs=function(){var e=this.get("title"),t=e.style,n=e.position,r=e.offset,a=e.spacing,i=void 0===a?0:a,o=e.autoRotate,s=t.fontSize,l=.5;"start"===n?l=0:"end"===n&&(l=1);var u=this.getTickPoint(l),c=this.getSidePoint(u,r||i+s/2),d=(0,x.CD)({x:c.x,y:c.y,text:e.text},t),p=e.rotate,h=p;if((0,x.UM)(p)&&o){var f=this.getAxisVector(u);h=vn.Dg(f,[1,0],!0)}if(h){var v=Tn(c,h);d.matrix=v}return d},t.prototype.drawTitle=function(e){var t,n=this.getTitleAttrs(),r=this.addShape(e,{type:"text",id:this.getElementId("title"),name:"axis-title",attrs:n});(null===(t=this.get("title"))||void 0===t?void 0:t.description)&&this.drawDescriptionIcon(e,r,n.matrix)},t.prototype.drawDescriptionIcon=function(e,t,n){var r=this.addGroup(e,{name:"axis-description",id:this.getElementById("description")}),a=t.getBBox(),i=a.maxX,o=a.maxY,s=a.height,l=this.get("title").iconStyle,u=s/2,c=u/6,d=i+4,p=o-s/2,h=[d+u,p-u],f=h[0],v=h[1],m=[f+u,v+u],g=m[0],x=m[1],I=[f,x+u],_=I[0],b=I[1],w=[d,v+u],S=w[0],E=w[1],C=[d+u,p-s/4],k=C[0],M=C[1],T=[k,M+c],A=T[0],L=T[1],P=[A,L+c],O=P[0],R=P[1],D=[O,R+3*u/4],N=D[0],z=D[1];this.addShape(r,{type:"path",id:this.getElementId("title-description-icon"),name:"axis-title-description-icon",attrs:(0,y.pi)({path:[["M",f,v],["A",u,u,0,0,1,g,x],["A",u,u,0,0,1,_,b],["A",u,u,0,0,1,S,E],["A",u,u,0,0,1,f,v],["M",k,M],["L",A,L],["M",O,R],["L",N,z]],lineWidth:c,matrix:n},l)}),this.addShape(r,{type:"rect",id:this.getElementId("title-description-rect"),name:"axis-title-description-rect",attrs:{x:d,y:p-s/2,width:s,height:s,stroke:"#000",fill:"#000",opacity:0,matrix:n,cursor:"pointer"}})},t.prototype.applyTickStates=function(e,t){if(this.getItemStates(e).length){var n=this.get("tickStates"),r=this.getElementId("label-"+e.id),a=t.findById(r);if(a){var i=kr(e,"label",n);i&&a.attr(i)}var o=this.getElementId("tickline-"+e.id),s=t.findById(o);if(s){var l=kr(e,"tickLine",n);l&&s.attr(l)}}},t.prototype.updateTickStates=function(e){var t=this.getItemStates(e),n=this.get("tickStates"),r=this.get("label"),a=this.getElementByLocalId("label-"+e.id),i=this.get("tickLine"),o=this.getElementByLocalId("tickline-"+e.id);if(t.length){if(a){var s=kr(e,"label",n);s&&a.attr(s)}if(o){var l=kr(e,"tickLine",n);l&&o.attr(l)}}else a&&a.attr(r.style),o&&o.attr(i.style)},t}(Kn),Tr=Mr;function Ar(e,t,n,r){var a=t.getChildren(),i=!1;return(0,x.S6)(a,(function(t){var a=Qn(e,t,n,r);i=i||a})),i}function Lr(){return Or}function Pr(e,t,n){return Ar(e,t,n,"head")}function Or(e,t,n){return Ar(e,t,n,"tail")}function Rr(e,t,n){return Ar(e,t,n,"middle")}function Dr(e){var t=function(e){var t=e.attr("matrix");return t&&1!==t[0]}(e)?function(e){var t=[0,0,0];return hn.transformMat3(t,[1,0,0],e),Math.atan2(t[1],t[0])}(e.attr("matrix")):0;return t%360}function Nr(e,t,n,r){var a=!1,i=Dr(t),o=e?Math.abs(n.attr("y")-t.attr("y")):Math.abs(n.attr("x")-t.attr("x")),s=(e?n.attr("y")>t.attr("y"):n.attr("x")>t.attr("x"))?t.getBBox():n.getBBox();if(e){var l=Math.abs(Math.cos(i));a=jn(l,0,Math.PI/180)?s.width+r>o:s.height/l+r>o}else{l=Math.abs(Math.sin(i));a=jn(l,0,Math.PI/180)?s.width+r>o:s.height/l+r>o}return a}function zr(e,t,n,r){var a=(null==r?void 0:r.minGap)||0,i=t.getChildren().slice().filter((function(e){return e.get("visible")}));if(!i.length)return!1;var o=!1;n&&i.reverse();for(var s=i.length,l=i[0],u=1;u1){p=Math.ceil(p);for(var f=0;f2){var o=a[0],s=a[a.length-1];o.get("visible")||(o.show(),zr(e,t,!1,r)&&(i=!0)),s.get("visible")||(s.show(),zr(e,t,!0,r)&&(i=!0))}return i}function Gr(e,t,n,r){var a=t.getChildren();if(!a.length)return!1;if(!e&&a.length<2)return!1;var i=$n(a),o=!1;e?o=!!n&&i>n:o=i>Math.abs(a[1].attr("x")-a[0].attr("x"));o&&function(e,t){(0,x.S6)(e,(function(e){var n=Tn({x:e.attr("x"),y:e.attr("y")},t);e.attr("matrix",n)}))}(a,r(n,i));return o}function qr(){return Wr}function Wr(e,t,n,r){return Gr(e,t,n,(function(){return(0,x.hj)(r)?r:e?tr.verticalAxisRotate:tr.horizontalAxisRotate}))}function Yr(e,t,n){return Gr(e,t,n,(function(t,n){if(!t)return e?tr.verticalAxisRotate:tr.horizontalAxisRotate;if(e)return-Math.acos(t/n);var r=0;return(t>n||(r=Math.asin(t/n))>Math.PI/4)&&(r=Math.PI/4),r}))}var Xr,Kr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{type:"line",locationType:"region",start:null,end:null})},t.prototype.getLinePath=function(){var e=this.get("start"),t=this.get("end"),n=[];return n.push(["M",e.x,e.y]),n.push(["L",t.x,t.y]),n},t.prototype.getInnerLayoutBBox=function(){var t=this.get("start"),n=this.get("end"),r=e.prototype.getInnerLayoutBBox.call(this),a=Math.min(t.x,n.x,r.x),i=Math.min(t.y,n.y,r.y),o=Math.max(t.x,n.x,r.maxX),s=Math.max(t.y,n.y,r.maxY);return{x:a,y:i,minX:a,minY:i,maxX:o,maxY:s,width:o-a,height:s-i}},t.prototype.isVertical=function(){var e=this.get("start"),t=this.get("end");return(0,x.vQ)(e.x,t.x)},t.prototype.isHorizontal=function(){var e=this.get("start"),t=this.get("end");return(0,x.vQ)(e.y,t.y)},t.prototype.getTickPoint=function(e){var t=this.get("start"),n=this.get("end"),r=n.x-t.x,a=n.y-t.y;return{x:t.x+r*e,y:t.y+a*e}},t.prototype.getSideVector=function(e){var t=this.getAxisVector(),n=In.Fv([0,0],t),r=this.get("verticalFactor"),a=[n[1],-1*n[0]];return In.bA([0,0],a,e*r)},t.prototype.getAxisVector=function(){var e=this.get("start"),t=this.get("end");return[t.x-e.x,t.y-e.y]},t.prototype.processOverlap=function(e){var t=this,n=this.isVertical(),r=this.isHorizontal();if(n||r){var a=this.get("label"),i=this.get("title"),o=this.get("verticalLimitLength"),s=a.offset,l=o,u=0,c=0;i&&(u=i.style.fontSize,c=i.spacing),l&&(l=l-s-c-u);var d=this.get("overlapOrder");if((0,x.S6)(d,(function(n){a[n]&&t.canProcessOverlap(n)&&t.autoProcessOverlap(n,a[n],e,l)})),i&&(0,x.UM)(i.offset)){var p=e.getCanvasBBox(),h=n?p.width:p.height;i.offset=s+h+c+u/2}}},t.prototype.canProcessOverlap=function(e){var t=this.get("label");return"autoRotate"!==e||(0,x.UM)(t.rotate)},t.prototype.autoProcessOverlap=function(e,t,n,r){var a=this,i=this.isVertical(),o=!1,s=l[e];if(!0===t){this.get("label");o=s.getDefault()(i,n,r)}else if((0,x.mf)(t))o=t(i,n,r);else if((0,x.Kn)(t)){var u=t;s[u.type]&&(o=s[u.type](i,n,r,u.cfg))}else s[t]&&(o=s[t](i,n,r));if("autoRotate"===e){if(o){var c=n.getChildren(),d=this.get("verticalFactor");(0,x.S6)(c,(function(e){if("center"===e.attr("textAlign")){var t=d>0?"end":"start";e.attr("textAlign",t)}}))}}else if("autoHide"===e){var p=n.getChildren().slice(0);(0,x.S6)(p,(function(e){e.get("visible")||(a.get("isRegister")&&a.unregisterElement(e),e.remove())}))}},t}(Tr),Jr=Kr,$r=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{type:"circle",locationType:"circle",center:null,radius:null,startAngle:-Math.PI/2,endAngle:3*Math.PI/2})},t.prototype.getLinePath=function(){var e=this.get("center"),t=e.x,n=e.y,r=this.get("radius"),a=r,i=this.get("startAngle"),o=this.get("endAngle"),s=[];if(Math.abs(o-i)===2*Math.PI)s=[["M",t,n-a],["A",r,a,0,1,1,t,n+a],["A",r,a,0,1,1,t,n-a],["Z"]];else{var l=this.getCirclePoint(i),u=this.getCirclePoint(o),c=Math.abs(o-i)>Math.PI?1:0,d=i>o?0:1;s=[["M",t,n],["L",l.x,l.y],["A",r,a,0,c,d,u.x,u.y],["L",t,n]]}return s},t.prototype.getTickPoint=function(e){var t=this.get("startAngle"),n=t+(this.get("endAngle")-t)*e;return this.getCirclePoint(n)},t.prototype.getSideVector=function(e,t){var n=this.get("center"),r=[t.x-n.x,t.y-n.y],a=this.get("verticalFactor"),i=In.kE(r);return In.bA(r,r,a*e/i),r},t.prototype.getAxisVector=function(e){var t=this.get("center"),n=[e.x-t.x,e.y-t.y];return[n[1],-1*n[0]]},t.prototype.getCirclePoint=function(e,t){var n=this.get("center");return t=t||this.get("radius"),{x:n.x+Math.cos(e)*t,y:n.y+Math.sin(e)*t}},t.prototype.canProcessOverlap=function(e){var t=this.get("label");return"autoRotate"!==e||(0,x.UM)(t.rotate)},t.prototype.processOverlap=function(e){var t=this,n=this.get("label"),r=this.get("title"),a=this.get("verticalLimitLength"),i=n.offset,o=a,s=0,l=0;r&&(s=r.style.fontSize,l=r.spacing),o&&(o=o-i-l-s);var u=this.get("overlapOrder");if((0,x.S6)(u,(function(r){n[r]&&t.canProcessOverlap(r)&&t.autoProcessOverlap(r,n[r],e,o)})),r&&(0,x.UM)(r.offset)){var c=e.getCanvasBBox().height;r.offset=i+c+l+s/2}},t.prototype.autoProcessOverlap=function(e,t,n,r){var a=this,i=!1,o=l[e];if(r>0)if(!0===t)i=o.getDefault()(!1,n,r);else if((0,x.mf)(t))i=t(!1,n,r);else if((0,x.Kn)(t)){var s=t;o[s.type]&&(i=o[s.type](!1,n,r,s.cfg))}else o[t]&&(i=o[t](!1,n,r));if("autoRotate"===e){if(i){var u=n.getChildren(),c=this.get("verticalFactor");(0,x.S6)(u,(function(e){if("center"===e.attr("textAlign")){var t=c>0?"end":"start";e.attr("textAlign",t)}}))}}else if("autoHide"===e){var d=n.getChildren().slice(0);(0,x.S6)(d,(function(e){e.get("visible")||(a.get("isRegister")&&a.unregisterElement(e),e.remove())}))}},t}(Tr),Qr=$r,ea=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{name:"crosshair",type:"base",line:{},text:null,textBackground:{},capture:!1,defaultCfg:{line:{style:{lineWidth:1,stroke:tr.lineColor}},text:{position:"start",offset:10,autoRotate:!1,content:null,style:{fill:tr.textColor,textAlign:"center",textBaseline:"middle",fontFamily:tr.fontFamily}},textBackground:{padding:5,style:{stroke:tr.lineColor}}}})},t.prototype.renderInner=function(e){this.get("line")&&this.renderLine(e),this.get("text")&&(this.renderText(e),this.renderBackground(e))},t.prototype.renderText=function(e){var t=this.get("text"),n=t.style,r=t.autoRotate,a=t.content;if(!(0,x.UM)(a)){var i=this.getTextPoint(),o=null;if(r)o=Tn(i,this.getRotateAngle());this.addShape(e,{type:"text",name:"crosshair-text",id:this.getElementId("text"),attrs:(0,y.pi)((0,y.pi)((0,y.pi)({},i),{text:a,matrix:o}),n)})}},t.prototype.renderLine=function(e){var t=this.getLinePath(),n=this.get("line").style;this.addShape(e,{type:"path",name:"crosshair-line",id:this.getElementId("line"),attrs:(0,y.pi)({path:t},n)})},t.prototype.renderBackground=function(e){var t=this.getElementId("text"),n=e.findById(t),r=this.get("textBackground");if(r&&n){var a=n.getBBox(),i=Rn(r.padding),o=r.style;this.addShape(e,{type:"rect",name:"crosshair-text-background",id:this.getElementId("text-background"),attrs:(0,y.pi)({x:a.x-i[3],y:a.y-i[0],width:a.width+i[1]+i[3],height:a.height+i[0]+i[2],matrix:n.attr("matrix")},o)}).toBack()}},t}(Kn),ta=ea,na=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{type:"line",locationType:"region",start:null,end:null})},t.prototype.getRotateAngle=function(){var e=this.getLocation(),t=e.start,n=e.end,r=this.get("text").position,a=Math.atan2(n.y-t.y,n.x-t.x);return"start"===r?a-Math.PI/2:a+Math.PI/2},t.prototype.getTextPoint=function(){var e=this.getLocation(),t=e.start,n=e.end,r=this.get("text");return Vn(t,n,r.position,r.offset)},t.prototype.getLinePath=function(){var e=this.getLocation(),t=e.start,n=e.end;return[["M",t.x,t.y],["L",n.x,n.y]]},t}(ta),ra=na,aa=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{type:"circle",locationType:"circle",center:null,radius:100,startAngle:-Math.PI/2,endAngle:3*Math.PI/2})},t.prototype.getRotateAngle=function(){var e=this.getLocation(),t=e.startAngle,n=e.endAngle;return"start"===this.get("text").position?t+Math.PI/2:n-Math.PI/2},t.prototype.getTextPoint=function(){var e=this.get("text"),t=e.position,n=e.offset,r=this.getLocation(),a=r.center,i=r.radius,o=r.startAngle,s=r.endAngle,l="start"===t?o:s,u=this.getRotateAngle()-Math.PI,c=Bn(a,i,l),d=Math.cos(u)*n,p=Math.sin(u)*n;return{x:c.x+d,y:c.y+p}},t.prototype.getLinePath=function(){var e=this.getLocation(),t=e.center,n=e.radius,r=e.startAngle,a=e.endAngle,i=null;if(a-r==2*Math.PI){var o=t.x,s=t.y;i=[["M",o,s-n],["A",n,n,0,1,1,o,s+n],["A",n,n,0,1,1,o,s-n],["Z"]]}else{var l=Bn(t,n,r),u=Bn(t,n,a),c=Math.abs(a-r)>Math.PI?1:0,d=r>a?0:1;i=[["M",l.x,l.y],["A",n,n,0,c,d,u.x,u.y]]}return i},t}(ta),ia=aa,oa="g2-crosshair",sa=oa+"-line",la=oa+"-text",ua=((Xr={})[""+oa]={position:"relative"},Xr[""+sa]={position:"absolute",backgroundColor:"rgba(0, 0, 0, 0.25)"},Xr[""+la]={position:"absolute",color:tr.textColor,fontFamily:tr.fontFamily},Xr),ca=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{name:"crosshair",type:"html",locationType:"region",start:{x:0,y:0},end:{x:0,y:0},capture:!1,text:null,containerTpl:'
',crosshairTpl:'
',textTpl:'{content}',domStyles:null,containerClassName:oa,defaultStyles:ua,defaultCfg:{text:{position:"start",content:null,align:"center",offset:10}}})},t.prototype.render=function(){this.resetText(),this.resetPosition()},t.prototype.initCrossHair=function(){var e=this.getContainer(),t=this.get("crosshairTpl"),n=(0,P.Z)(t);e.appendChild(n),this.applyStyle(sa,n),this.set("crosshairEl",n)},t.prototype.getTextPoint=function(){var e=this.getLocation(),t=e.start,n=e.end,r=this.get("text");return Vn(t,n,r.position,r.offset)},t.prototype.resetText=function(){var e=this.get("text"),t=this.get("textEl");if(e){var n=e.content;if(!t){var r=this.getContainer(),a=(0,x.ng)(this.get("textTpl"),e);t=(0,P.Z)(a),r.appendChild(t),this.applyStyle(la,t),this.set("textEl",t)}t.innerHTML=n}else t&&t.remove()},t.prototype.isVertical=function(e,t){return e.x===t.x},t.prototype.resetPosition=function(){var e=this.get("crosshairEl");e||(this.initCrossHair(),e=this.get("crosshairEl"));var t=this.get("start"),n=this.get("end"),r=Math.min(t.x,n.x),a=Math.min(t.y,n.y);this.isVertical(t,n)?(0,O.Z)(e,{width:"1px",height:Un(Math.abs(n.y-t.y))}):(0,O.Z)(e,{height:"1px",width:Un(Math.abs(n.x-t.x))}),(0,O.Z)(e,{top:Un(a),left:Un(r)}),this.alignText()},t.prototype.alignText=function(){var e=this.get("textEl");if(e){var t=this.get("text").align,n=e.clientWidth,r=this.getTextPoint();switch(t){case"center":r.x=r.x-n/2;break;case"right":r.x=r.x-n}(0,O.Z)(e,{top:Un(r.y),left:Un(r.x)})}},t.prototype.updateInner=function(t){(0,x.wH)(t,"text")&&this.resetText(),e.prototype.updateInner.call(this,t)},t}(Sr),da=ca,pa=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{name:"grid",line:{},alternateColor:null,capture:!1,items:[],closed:!1,defaultCfg:{line:{type:"line",style:{lineWidth:1,stroke:tr.lineColor}}}})},t.prototype.getLineType=function(){return(this.get("line")||this.get("defaultCfg").line).type},t.prototype.renderInner=function(e){this.drawGrid(e)},t.prototype.getAlternatePath=function(e,t){var n=this.getGridPath(e),r=t.slice(0).reverse(),a=this.getGridPath(r,!0);return this.get("closed")?n=n.concat(a):(a[0][0]="L",(n=n.concat(a)).push(["Z"])),n},t.prototype.getPathStyle=function(){return this.get("line").style},t.prototype.drawGrid=function(e){var t=this,n=this.get("line"),r=this.get("items"),a=this.get("alternateColor"),i=null;(0,x.S6)(r,(function(o,s){var l=o.id||s;if(n){var u=t.getPathStyle();u=(0,x.mf)(u)?u(o,s,r):u;var c=t.getElementId("line-"+l),d=t.getGridPath(o.points);t.addShape(e,{type:"path",name:"grid-line",id:c,attrs:(0,x.CD)({path:d},u)})}if(a&&s>0){var p=t.getElementId("region-"+l),h=s%2==0;if((0,x.HD)(a))h&&t.drawAlternateRegion(p,e,i.points,o.points,a);else{var f=h?a[1]:a[0];t.drawAlternateRegion(p,e,i.points,o.points,f)}}i=o}))},t.prototype.drawAlternateRegion=function(e,t,n,r,a){var i=this.getAlternatePath(n,r);this.addShape(t,{type:"path",id:e,name:"grid-region",attrs:{path:i,fill:a}})},t}(Kn),ha=pa;var fa,va=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{type:"circle",center:null,closed:!0})},t.prototype.getGridPath=function(e,t){var n,r,a,i,o,s,l=this.getLineType(),u=this.get("closed"),c=[];if(e.length)if("circle"===l){var d=this.get("center"),p=e[0],h=(n=d.x,r=d.y,a=p.x,i=p.y,o=a-n,s=i-r,Math.sqrt(o*o+s*s)),f=t?0:1;u?(c.push(["M",d.x,d.y-h]),c.push(["A",h,h,0,0,f,d.x,d.y+h]),c.push(["A",h,h,0,0,f,d.x,d.y-h]),c.push(["Z"])):(0,x.S6)(e,(function(e,t){0===t?c.push(["M",e.x,e.y]):c.push(["A",h,h,0,0,f,e.x,e.y])}))}else(0,x.S6)(e,(function(e,t){0===t?c.push(["M",e.x,e.y]):c.push(["L",e.x,e.y])})),u&&c.push(["Z"]);return c},t}(ha),ma=va,ga=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{type:"line"})},t.prototype.getGridPath=function(e){var t=[];return(0,x.S6)(e,(function(e,n){0===n?t.push(["M",e.x,e.y]):t.push(["L",e.x,e.y])})),t},t}(ha),ya=ga,xa=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{name:"legend",layout:"horizontal",locationType:"point",x:0,y:0,offsetX:0,offsetY:0,title:null,background:null})},t.prototype.getLayoutBBox=function(){var t=e.prototype.getLayoutBBox.call(this),n=this.get("maxWidth"),r=this.get("maxHeight"),a=t.width,i=t.height;return n&&(a=Math.min(a,n)),r&&(i=Math.min(i,r)),zn(t.minX,t.minY,a,i)},t.prototype.setLocation=function(e){this.set("x",e.x),this.set("y",e.y),this.resetLocation()},t.prototype.resetLocation=function(){var e=this.get("x"),t=this.get("y"),n=this.get("offsetX"),r=this.get("offsetY");this.moveElementTo(this.get("group"),{x:e+n,y:t+r})},t.prototype.applyOffset=function(){this.resetLocation()},t.prototype.getDrawPoint=function(){return this.get("currentPoint")},t.prototype.setDrawPoint=function(e){return this.set("currentPoint",e)},t.prototype.renderInner=function(e){this.resetDraw(),this.get("title")&&this.drawTitle(e),this.drawLegendContent(e),this.get("background")&&this.drawBackground(e)},t.prototype.drawBackground=function(e){var t=this.get("background"),n=e.getBBox(),r=Rn(t.padding),a=(0,y.pi)({x:0,y:0,width:n.width+r[1]+r[3],height:n.height+r[0]+r[2]},t.style);this.addShape(e,{type:"rect",id:this.getElementId("background"),name:"legend-background",attrs:a}).toBack()},t.prototype.drawTitle=function(e){var t=this.get("currentPoint"),n=this.get("title"),r=n.spacing,a=n.style,i=n.text,o=this.addShape(e,{type:"text",id:this.getElementId("title"),name:"legend-title",attrs:(0,y.pi)({text:i,x:t.x,y:t.y},a)}).getBBox();this.set("currentPoint",{x:t.x,y:o.maxY+r})},t.prototype.resetDraw=function(){var e=this.get("background"),t={x:0,y:0};if(e){var n=Rn(e.padding);t.x=n[3],t.y=n[0]}this.set("currentPoint",t)},t}(Kn),Ia=xa,_a={marker:{style:{inactiveFill:"#000",inactiveOpacity:.45,fill:"#000",opacity:1,size:12}},text:{style:{fill:"#ccc",fontSize:12}}},ba={fill:tr.textColor,fontSize:12,textAlign:"start",textBaseline:"middle",fontFamily:tr.fontFamily,fontWeight:"normal",lineHeight:12},wa="navigation-arrow-right",Sa="navigation-arrow-left",Ea={right:90*Math.PI/180,left:270*Math.PI/180,up:0,down:180*Math.PI/180},Ca=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.currentPageIndex=1,t.totalPagesCnt=1,t.pageWidth=0,t.pageHeight=0,t.startX=0,t.startY=0,t.onNavigationBack=function(){var e=t.getElementByLocalId("item-group");if(t.currentPageIndex>1){t.currentPageIndex-=1,t.updateNavigation();var n=t.getCurrentNavigationMatrix();t.get("animate")?e.animate({matrix:n},100):e.attr({matrix:n})}},t.onNavigationAfter=function(){var e=t.getElementByLocalId("item-group");if(t.currentPageIndexf&&(f=y),"horizontal"===d?(v&&vy&&(y=t.width)})),I=y,y+=c,s&&(y=Math.min(s,y),I=Math.min(s,I)),this.pageWidth=y,this.pageHeight=l-Math.max(f.height,d+_);var S=Math.floor(this.pageHeight/(d+_));(0,x.S6)(o,(function(e,t){0!==t&&t%S==0&&(m+=1,v.x+=y,v.y=a),n.moveElementTo(e,v),e.getParent().setClip({type:"rect",attrs:{x:v.x,y:v.y,width:y,height:d}}),v.y+=d+_})),this.totalPagesCnt=m,this.moveElementTo(h,{x:r+I/2-f.width/2-f.minX,y:l-f.height-f.minY})}this.pageHeight&&this.pageWidth&&t.getParent().setClip({type:"rect",attrs:{x:this.startX,y:this.startY,width:this.pageWidth,height:this.pageHeight}}),"horizontal"===i&&this.get("maxRow")?this.totalPagesCnt=Math.ceil(m/this.get("maxRow")):this.totalPagesCnt=m,this.currentPageIndex>this.totalPagesCnt&&(this.currentPageIndex=1),this.updateNavigation(h),t.attr("matrix",this.getCurrentNavigationMatrix())},t.prototype.drawNavigation=function(e,t,n,r){var a={x:0,y:0},i=this.addGroup(e,{id:this.getElementId("navigation-group"),name:"legend-navigation"}),o=(0,x.U2)(r.marker,"style",{}),s=o.size,l=void 0===s?12:s,u=(0,y._T)(o,["size"]),c=this.drawArrow(i,a,Sa,"horizontal"===t?"up":"left",l,u);c.on("click",this.onNavigationBack);var d=c.getBBox();a.x+=d.width+2;var p=this.addShape(i,{type:"text",id:this.getElementId("navigation-text"),name:"navigation-text",attrs:(0,y.pi)({x:a.x,y:a.y+l/2,text:n,textBaseline:"middle"},(0,x.U2)(r.text,"style"))}).getBBox();return a.x+=p.width+2,this.drawArrow(i,a,wa,"horizontal"===t?"down":"right",l,u).on("click",this.onNavigationAfter),i},t.prototype.updateNavigation=function(e){var t=(0,x.b$)({},_a,this.get("pageNavigator")).marker.style,n=t.fill,r=t.opacity,a=t.inactiveFill,i=t.inactiveOpacity,o=this.currentPageIndex+"/"+this.totalPagesCnt,s=e?e.getChildren()[1]:this.getElementByLocalId("navigation-text"),l=e?e.findById(this.getElementId(Sa)):this.getElementByLocalId(Sa),u=e?e.findById(this.getElementId(wa)):this.getElementByLocalId(wa);s.attr("text",o),l.attr("opacity",1===this.currentPageIndex?i:r),l.attr("fill",1===this.currentPageIndex?a:n),l.attr("cursor",1===this.currentPageIndex?"not-allowed":"pointer"),u.attr("opacity",this.currentPageIndex===this.totalPagesCnt?i:r),u.attr("fill",this.currentPageIndex===this.totalPagesCnt?a:n),u.attr("cursor",this.currentPageIndex===this.totalPagesCnt?"not-allowed":"pointer");var c=l.getBBox().maxX+2;s.attr("x",c),c+=s.getBBox().width+2,this.updateArrowPath(u,{x:c,y:0})},t.prototype.drawArrow=function(e,t,n,r,a,i){var o=t.x,s=t.y,l=this.addShape(e,{type:"path",id:this.getElementId(n),name:n,attrs:(0,y.pi)({size:a,direction:r,path:[["M",o+a/2,s],["L",o,s+a],["L",o+a,s+a],["Z"]],cursor:"pointer"},i)});return l.attr("matrix",Tn({x:o+a/2,y:s+a/2},Ea[r])),l},t.prototype.updateArrowPath=function(e,t){var n=t.x,r=t.y,a=e.attr(),i=a.size,o=a.direction,s=Tn({x:n+i/2,y:r+i/2},Ea[o]);e.attr("path",[["M",n+i/2,r],["L",n,r+i],["L",n+i,r+i],["Z"]]),e.attr("matrix",s)},t.prototype.getCurrentNavigationMatrix=function(){var e=this,t=e.currentPageIndex,n=e.pageWidth,r=e.pageHeight;return An("horizontal"===this.get("layout")?{x:0,y:r*(1-t)}:{x:n*(1-t),y:0})},t.prototype.applyItemStates=function(e,t){if(this.getItemStates(e).length>0){var n=t.getChildren(),r=this.get("itemStates");(0,x.S6)(n,(function(t){var n=t.get("name").split("-")[2],a=kr(e,n,r);a&&(t.attr(a),"marker"!==n||t.get("isStroke")&&t.get("isFill")||(t.get("isStroke")&&t.attr("fill",null),t.get("isFill")&&t.attr("stroke",null)))}))}},t.prototype.getLimitItemWidth=function(){var e=this.get("itemWidth"),t=this.get("maxItemWidth");return t?e&&(t=e<=t?e:t):e&&(t=e),t},t}(Ia),ka=Ca,Ma=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{type:"continue",min:0,max:100,value:null,colors:[],track:{},rail:{},label:{},handler:{},slidable:!0,tip:null,step:null,maxWidth:null,maxHeight:null,defaultCfg:{label:{align:"rail",spacing:5,formatter:null,style:{fontSize:12,fill:tr.textColor,textBaseline:"middle",fontFamily:tr.fontFamily}},handler:{size:10,style:{fill:"#fff",stroke:"#333"}},track:{},rail:{type:"color",size:20,defaultLength:100,style:{fill:"#DCDEE2"}},title:{spacing:5,style:{fill:tr.textColor,fontSize:12,textAlign:"start",textBaseline:"top"}}}})},t.prototype.isSlider=function(){return!0},t.prototype.getValue=function(){return this.getCurrentValue()},t.prototype.getRange=function(){return{min:this.get("min"),max:this.get("max")}},t.prototype.setRange=function(e,t){this.update({min:e,max:t})},t.prototype.setValue=function(e){var t=this.getValue();this.set("value",e);var n=this.get("group");this.resetTrackClip(),this.get("slidable")&&this.resetHandlers(n),this.delegateEmit("valuechanged",{originValue:t,value:e})},t.prototype.initEvent=function(){var e=this.get("group");this.bindSliderEvent(e),this.bindRailEvent(e),this.bindTrackEvent(e)},t.prototype.drawLegendContent=function(e){this.drawRail(e),this.drawLabels(e),this.fixedElements(e),this.resetTrack(e),this.resetTrackClip(e),this.get("slidable")&&this.resetHandlers(e)},t.prototype.bindSliderEvent=function(e){this.bindHandlersEvent(e)},t.prototype.bindHandlersEvent=function(e){var t=this;e.on("legend-handler-min:drag",(function(e){var n=t.getValueByCanvasPoint(e.x,e.y),r=t.getCurrentValue()[1];rn&&(r=n),t.setValue([r,n])}))},t.prototype.bindRailEvent=function(e){},t.prototype.bindTrackEvent=function(e){var t=this,n=null;e.on("legend-track:dragstart",(function(e){n={x:e.x,y:e.y}})),e.on("legend-track:drag",(function(e){if(n){var r=t.getValueByCanvasPoint(n.x,n.y),a=t.getValueByCanvasPoint(e.x,e.y),i=t.getCurrentValue(),o=i[1]-i[0],s=t.getRange(),l=a-r;l<0?i[0]+l>s.min?t.setValue([i[0]+l,i[1]+l]):t.setValue([s.min,s.min+o]):l>0&&(l>0&&i[1]+la&&(l=a),l0&&this.changeRailLength(r,a,n[a]-u)}},t.prototype.changeRailLength=function(e,t,n){var r,a=e.getBBox();r="height"===t?this.getRailPath(a.x,a.y,a.width,n):this.getRailPath(a.x,a.y,n,a.height),e.attr("path",r)},t.prototype.changeRailPosition=function(e,t,n){var r=e.getBBox(),a=this.getRailPath(t,n,r.width,r.height);e.attr("path",a)},t.prototype.fixedHorizontal=function(e,t,n,r){var a=this.get("label"),i=a.align,o=a.spacing,s=n.getBBox(),l=e.getBBox(),u=t.getBBox(),c=s.height;this.fitRailLength(l,u,s,n),s=n.getBBox(),"rail"===i?(e.attr({x:r.x,y:r.y+c/2}),this.changeRailPosition(n,r.x+l.width+o,r.y),t.attr({x:r.x+l.width+s.width+2*o,y:r.y+c/2})):"top"===i?(e.attr({x:r.x,y:r.y}),t.attr({x:r.x+s.width,y:r.y}),this.changeRailPosition(n,r.x,r.y+l.height+o)):(this.changeRailPosition(n,r.x,r.y),e.attr({x:r.x,y:r.y+s.height+o}),t.attr({x:r.x+s.width,y:r.y+s.height+o}))},t.prototype.fixedVertail=function(e,t,n,r){var a=this.get("label"),i=a.align,o=a.spacing,s=n.getBBox(),l=e.getBBox(),u=t.getBBox();if(this.fitRailLength(l,u,s,n),s=n.getBBox(),"rail"===i)e.attr({x:r.x,y:r.y}),this.changeRailPosition(n,r.x,r.y+l.height+o),t.attr({x:r.x,y:r.y+l.height+s.height+2*o});else if("right"===i)e.attr({x:r.x+s.width+o,y:r.y}),this.changeRailPosition(n,r.x,r.y),t.attr({x:r.x+s.width+o,y:r.y+s.height});else{var c=Math.max(l.width,u.width);e.attr({x:r.x,y:r.y}),this.changeRailPosition(n,r.x+c+o,r.y),t.attr({x:r.x,y:r.y+s.height})}},t}(Ia),Ta=Ma,Aa="g2-tooltip",La="g2-tooltip-title",Pa="g2-tooltip-list",Oa="g2-tooltip-list-item",Ra="g2-tooltip-marker",Da="g2-tooltip-value",Na="g2-tooltip-name",za="g2-tooltip-crosshair-x",Fa="g2-tooltip-crosshair-y",Ba=((fa={})[""+Aa]={position:"absolute",visibility:"visible",zIndex:8,transition:"visibility 0.2s cubic-bezier(0.23, 1, 0.32, 1), left 0.4s cubic-bezier(0.23, 1, 0.32, 1), top 0.4s cubic-bezier(0.23, 1, 0.32, 1)",backgroundColor:"rgba(255, 255, 255, 0.9)",boxShadow:"0px 0px 10px #aeaeae",borderRadius:"3px",color:"rgb(87, 87, 87)",fontSize:"12px",fontFamily:tr.fontFamily,lineHeight:"20px",padding:"10px 10px 6px 10px"},fa[""+La]={marginBottom:"4px"},fa[""+Pa]={margin:"0px",listStyleType:"none",padding:"0px"},fa[""+Oa]={listStyleType:"none",marginBottom:"4px"},fa[""+Ra]={width:"8px",height:"8px",borderRadius:"50%",display:"inline-block",marginRight:"8px"},fa[""+Da]={display:"inline-block",float:"right",marginLeft:"30px"},fa[""+za]={position:"absolute",width:"1px",backgroundColor:"rgba(0, 0, 0, 0.25)"},fa[""+Fa]={position:"absolute",height:"1px",backgroundColor:"rgba(0, 0, 0, 0.25)"},fa);var ja=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{name:"tooltip",type:"html",x:0,y:0,items:[],customContent:null,containerTpl:'
    ',itemTpl:'
  • \n \n {name}:\n {value}\n
  • ',xCrosshairTpl:'
    ',yCrosshairTpl:'
    ',title:null,showTitle:!0,region:null,crosshairsRegion:null,containerClassName:Aa,crosshairs:null,offset:10,position:"right",domStyles:null,defaultStyles:Ba})},t.prototype.render=function(){this.get("customContent")?this.renderCustomContent():(this.resetTitle(),this.renderItems()),this.resetPosition()},t.prototype.clear=function(){this.clearCrosshairs(),this.setTitle(""),this.clearItemDoms()},t.prototype.show=function(){var e=this.getContainer();e&&!this.destroyed&&(this.set("visible",!0),(0,O.Z)(e,{visibility:"visible"}),this.setCrossHairsVisible(!0))},t.prototype.hide=function(){var e=this.getContainer();e&&!this.destroyed&&(this.set("visible",!1),(0,O.Z)(e,{visibility:"hidden"}),this.setCrossHairsVisible(!1))},t.prototype.getLocation=function(){return{x:this.get("x"),y:this.get("y")}},t.prototype.setLocation=function(e){this.set("x",e.x),this.set("y",e.y),this.resetPosition()},t.prototype.setCrossHairsVisible=function(e){var t=e?"":"none",n=this.get("xCrosshairDom"),r=this.get("yCrosshairDom");n&&(0,O.Z)(n,{display:t}),r&&(0,O.Z)(r,{display:t})},t.prototype.initContainer=function(){if(e.prototype.initContainer.call(this),this.get("customContent")){this.get("container")&&this.get("container").remove();var t=this.getHtmlContentNode();this.get("parent").appendChild(t),this.set("container",t),this.resetStyles(),this.applyStyles()}},t.prototype.updateInner=function(t){var n,r,a;this.get("customContent")?this.renderCustomContent():(n=t,r=["title","showTitle"],a=!1,(0,x.S6)(r,(function(e){if((0,x.wH)(n,e))return a=!0,!1})),a&&this.resetTitle(),(0,x.wH)(t,"items")&&this.renderItems()),e.prototype.updateInner.call(this,t)},t.prototype.initDom=function(){this.cacheDoms()},t.prototype.removeDom=function(){e.prototype.removeDom.call(this),this.clearCrosshairs()},t.prototype.resetPosition=function(){var e,t=this.get("x"),n=this.get("y"),r=this.get("offset"),a=this.getOffset(),i=a.offsetX,o=a.offsetY,s=this.get("position"),l=this.get("region"),u=this.getContainer(),c=this.getBBox(),d=c.width,p=c.height;l&&(e=Nn(l));var h=function(e,t,n,r,a,i,o){var s=function(e,t,n,r,a,i){var o=e,s=t;switch(i){case"left":o=e-r-n,s=t-a/2;break;case"right":o=e+n,s=t-a/2;break;case"top":o=e-r/2,s=t-a-n;break;case"bottom":o=e-r/2,s=t+n;break;default:o=e+n,s=t-a-n}return{x:o,y:s}}(e,t,n,r,a,i);if(o){var l=function(e,t,n,r,a){return{left:ea.x+a.width,top:ta.y+a.height}}(s.x,s.y,r,a,o);"auto"===i?(l.right&&(s.x=Math.max(0,e-r-n)),l.top&&(s.y=Math.max(0,t-a-n))):"top"===i||"bottom"===i?(l.left&&(s.x=o.x),l.right&&(s.x=o.x+o.width-r),"top"===i&&l.top&&(s.y=t+n),"bottom"===i&&l.bottom&&(s.y=t-a-n)):(l.top&&(s.y=o.y),l.bottom&&(s.y=o.y+o.height-a),"left"===i&&l.left&&(s.x=e+n),"right"===i&&l.right&&(s.x=e-r-n))}return s}(t,n,r,d,p,s,e);(0,O.Z)(u,{left:Un(h.x+i),top:Un(h.y+o)}),this.resetCrosshairs()},t.prototype.renderCustomContent=function(){var e=this.getHtmlContentNode(),t=this.get("parent"),n=this.get("container");n&&n.parentNode===t?t.replaceChild(e,n):t.appendChild(e),this.set("container",e),this.resetStyles(),this.applyStyles()},t.prototype.getHtmlContentNode=function(){var e,t=this.get("customContent");if(t){var n=t(this.get("title"),this.get("items"));e=(0,x.kK)(n)?n:(0,P.Z)(n)}return e},t.prototype.cacheDoms=function(){var e=this.getContainer(),t=e.getElementsByClassName(La)[0],n=e.getElementsByClassName(Pa)[0];this.set("titleDom",t),this.set("listDom",n)},t.prototype.resetTitle=function(){var e=this.get("title");this.get("showTitle")&&e?this.setTitle(e):this.setTitle("")},t.prototype.setTitle=function(e){var t=this.get("titleDom");t&&(t.innerText=e)},t.prototype.resetCrosshairs=function(){var e=this.get("crosshairsRegion"),t=this.get("crosshairs");if(e&&t){var n=Nn(e),r=this.get("xCrosshairDom"),a=this.get("yCrosshairDom");"x"===t?(this.resetCrosshair("x",n),a&&(a.remove(),this.set("yCrosshairDom",null))):"y"===t?(this.resetCrosshair("y",n),r&&(r.remove(),this.set("xCrosshairDom",null))):(this.resetCrosshair("x",n),this.resetCrosshair("y",n)),this.setCrossHairsVisible(this.get("visible"))}else this.clearCrosshairs()},t.prototype.resetCrosshair=function(e,t){var n=this.checkCrosshair(e),r=this.get(e);"x"===e?(0,O.Z)(n,{left:Un(r),top:Un(t.y),height:Un(t.height)}):(0,O.Z)(n,{top:Un(r),left:Un(t.x),width:Un(t.width)})},t.prototype.checkCrosshair=function(e){var t=e+"CrosshairDom",n=e+"CrosshairTpl",r="CROSSHAIR_"+e.toUpperCase(),a=c[r],i=this.get(t),o=this.get("parent");return i||(i=(0,P.Z)(this.get(n)),this.applyStyle(a,i),o.appendChild(i),this.set(t,i)),i},t.prototype.renderItems=function(){this.clearItemDoms();var e=this.get("items"),t=this.get("itemTpl"),n=this.get("listDom");n&&((0,x.S6)(e,(function(e){var r=ge.toCSSGradient(e.color),a=(0,y.pi)((0,y.pi)({},e),{color:r}),i=(0,x.ng)(t,a),o=(0,P.Z)(i);n.appendChild(o)})),this.applyChildrenStyles(n,this.get("domStyles")))},t.prototype.clearItemDoms=function(){this.get("listDom")&&Dn(this.get("listDom"))},t.prototype.clearCrosshairs=function(){var e=this.get("xCrosshairDom"),t=this.get("yCrosshairDom");e&&e.remove(),t&&t.remove(),this.set("xCrosshairDom",null),this.set("yCrosshairDom",null)},t}(Sr),Za=ja,Ua={opacity:0},Va={stroke:"#C5C5C5",strokeOpacity:.85},Ha={fill:"#CACED4",opacity:.85},Ga=n(45958);function qa(e){return function(e){return(0,x.UI)(e,(function(e,t){return[0===t?"M":"L",e[0],e[1]]}))}(e)}function Wa(e,t,n,r){void 0===r&&(r=!0);var a=new xt({values:e}),i=new Me({values:(0,x.UI)(e,(function(e,t){return t}))}),o=(0,x.UI)(e,(function(e,r){return[i.scale(r)*t,n-a.scale(e)*n]}));return r?function(e){if(e.length<=2)return qa(e);var t=[];(0,x.S6)(e,(function(e){(0,x.Xy)(e,t.slice(t.length-2))||t.push(e[0],e[1])}));var n=(0,Ga.e9)(t,!1),r=(0,x.YM)(e),a=r[0],i=r[1];return n.unshift(["M",a,i]),n}(o):qa(o)}function Ya(e,t,n,r){var a=(0,y.pr)(e),i=function(e,t){var n=new xt({values:e}),r=n.max<0?n.max:Math.max(0,n.min);return t-n.scale(r)*t}(r,n);return a.push(["L",t,i]),a.push(["L",0,i]),a.push(["Z"]),a}var Xa=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{name:"trend",x:0,y:0,width:200,height:16,smooth:!0,isArea:!1,data:[],backgroundStyle:Ua,lineStyle:Va,areaStyle:Ha})},t.prototype.renderInner=function(e){var t=this.cfg,n=t.width,r=t.height,a=t.data,i=t.smooth,o=t.isArea,s=t.backgroundStyle,l=t.lineStyle,u=t.areaStyle;this.addShape(e,{id:this.getElementId("background"),type:"rect",attrs:(0,y.pi)({x:0,y:0,width:n,height:r},s)});var c=Wa(a,n,r,i);if(this.addShape(e,{id:this.getElementId("line"),type:"path",attrs:(0,y.pi)({path:c},l)}),o){var d=Ya(c,n,r,a);this.addShape(e,{id:this.getElementId("area"),type:"path",attrs:(0,y.pi)({path:d},u)})}},t.prototype.applyOffset=function(){var e=this.cfg,t=e.x,n=e.y;this.moveElementTo(this.get("group"),{x:t,y:n})},t}(Kn),Ka={fill:"#F7F7F7",stroke:"#BFBFBF",radius:2,opacity:1,cursor:"ew-resize",highLightFill:"#FFF"},Ja=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{name:"handler",x:0,y:0,width:10,height:24,style:Ka})},t.prototype.renderInner=function(e){var t=this.cfg,n=t.width,r=t.height,a=t.style,i=a.fill,o=a.stroke,s=a.radius,l=a.opacity,u=a.cursor;this.addShape(e,{type:"rect",id:this.getElementId("background"),attrs:{x:0,y:0,width:n,height:r,fill:i,stroke:o,radius:s,opacity:l,cursor:u}});var c=1/3*n,d=2/3*n,p=1/4*r,h=3/4*r;this.addShape(e,{id:this.getElementId("line-left"),type:"line",attrs:{x1:c,y1:p,x2:c,y2:h,stroke:o,cursor:u}}),this.addShape(e,{id:this.getElementId("line-right"),type:"line",attrs:{x1:d,y1:p,x2:d,y2:h,stroke:o,cursor:u}})},t.prototype.applyOffset=function(){this.moveElementTo(this.get("group"),{x:this.get("x"),y:this.get("y")})},t.prototype.initEvent=function(){this.bindEvents()},t.prototype.bindEvents=function(){var e=this;this.get("group").on("mouseenter",(function(){var t=e.get("style").highLightFill;e.getElementByLocalId("background").attr("fill",t),e.draw()})),this.get("group").on("mouseleave",(function(){var t=e.get("style").fill;e.getElementByLocalId("background").attr("fill",t),e.draw()}))},t.prototype.draw=function(){var e=this.get("container").get("canvas");e&&e.draw()},t}(Kn),$a={fill:"#416180",opacity:.05},Qa={fill:"#5B8FF9",opacity:.15,cursor:"move"},ei={width:10,height:24},ti={textBaseline:"middle",fill:"#000",opacity:.45},ni="sliderchange",ri=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.onMouseDown=function(e){return function(n){t.currentTarget=e;var r=n.originalEvent;r.stopPropagation(),r.preventDefault(),t.prevX=(0,x.U2)(r,"touches.0.pageX",r.pageX),t.prevY=(0,x.U2)(r,"touches.0.pageY",r.pageY);var a=t.getContainerDOM();a.addEventListener("mousemove",t.onMouseMove),a.addEventListener("mouseup",t.onMouseUp),a.addEventListener("mouseleave",t.onMouseUp),a.addEventListener("touchmove",t.onMouseMove),a.addEventListener("touchend",t.onMouseUp),a.addEventListener("touchcancel",t.onMouseUp)}},t.onMouseMove=function(e){var n=t.cfg.width,r=[t.get("start"),t.get("end")];e.stopPropagation(),e.preventDefault();var a=(0,x.U2)(e,"touches.0.pageX",e.pageX),i=(0,x.U2)(e,"touches.0.pageY",e.pageY),o=a-t.prevX,s=t.adjustOffsetRange(o/n);t.updateStartEnd(s),t.updateUI(t.getElementByLocalId("foreground"),t.getElementByLocalId("minText"),t.getElementByLocalId("maxText")),t.prevX=a,t.prevY=i,t.draw(),t.emit(ni,[t.get("start"),t.get("end")].sort()),t.delegateEmit("valuechanged",{originValue:r,value:[t.get("start"),t.get("end")]})},t.onMouseUp=function(){t.currentTarget&&(t.currentTarget=void 0);var e=t.getContainerDOM();e&&(e.removeEventListener("mousemove",t.onMouseMove),e.removeEventListener("mouseup",t.onMouseUp),e.removeEventListener("mouseleave",t.onMouseUp),e.removeEventListener("touchmove",t.onMouseMove),e.removeEventListener("touchend",t.onMouseUp),e.removeEventListener("touchcancel",t.onMouseUp))},t}return(0,y.ZT)(t,e),t.prototype.setRange=function(e,t){this.set("minLimit",e),this.set("maxLimit",t);var n=this.get("start"),r=this.get("end"),a=(0,x.uZ)(n,e,t),i=(0,x.uZ)(r,e,t);this.get("isInit")||n===a&&r===i||this.setValue([a,i])},t.prototype.getRange=function(){return{min:this.get("minLimit")||0,max:this.get("maxLimit")||1}},t.prototype.setValue=function(e){var t=this.getRange();if((0,x.kJ)(e)&&2===e.length){var n=[this.get("start"),this.get("end")];this.update({start:(0,x.uZ)(e[0],t.min,t.max),end:(0,x.uZ)(e[1],t.min,t.max)}),this.get("updateAutoRender")||this.render(),this.delegateEmit("valuechanged",{originValue:n,value:e})}},t.prototype.getValue=function(){return[this.get("start"),this.get("end")]},t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{name:"slider",x:0,y:0,width:100,height:16,backgroundStyle:{},foregroundStyle:{},handlerStyle:{},textStyle:{},defaultCfg:{backgroundStyle:$a,foregroundStyle:Qa,handlerStyle:ei,textStyle:ti}})},t.prototype.update=function(t){var n=t.start,r=t.end,a=(0,y.pi)({},t);(0,x.UM)(n)||(a.start=(0,x.uZ)(n,0,1)),(0,x.UM)(r)||(a.end=(0,x.uZ)(r,0,1)),e.prototype.update.call(this,a),this.minHandler=this.getChildComponentById(this.getElementId("minHandler")),this.maxHandler=this.getChildComponentById(this.getElementId("maxHandler")),this.trend=this.getChildComponentById(this.getElementId("trend"))},t.prototype.init=function(){this.set("start",(0,x.uZ)(this.get("start"),0,1)),this.set("end",(0,x.uZ)(this.get("end"),0,1)),e.prototype.init.call(this)},t.prototype.render=function(){e.prototype.render.call(this),this.updateUI(this.getElementByLocalId("foreground"),this.getElementByLocalId("minText"),this.getElementByLocalId("maxText"))},t.prototype.renderInner=function(e){var t=this.cfg,n=(t.start,t.end,t.width),r=t.height,a=t.trendCfg,i=void 0===a?{}:a,o=t.minText,s=t.maxText,l=t.backgroundStyle,u=void 0===l?{}:l,c=t.foregroundStyle,d=void 0===c?{}:c,p=t.textStyle,h=void 0===p?{}:p,f=(0,x.b$)({},Ka,this.cfg.handlerStyle);(0,x.dp)((0,x.U2)(i,"data"))&&(this.trend=this.addComponent(e,(0,y.pi)({component:Xa,id:this.getElementId("trend"),x:0,y:0,width:n,height:r},i))),this.addShape(e,{id:this.getElementId("background"),type:"rect",attrs:(0,y.pi)({x:0,y:0,width:n,height:r},u)});this.addShape(e,{id:this.getElementId("minText"),type:"text",attrs:(0,y.pi)({y:r/2,textAlign:"right",text:o,silent:!1},h)}),this.addShape(e,{id:this.getElementId("maxText"),type:"text",attrs:(0,y.pi)({y:r/2,textAlign:"left",text:s,silent:!1},h)}),this.addShape(e,{id:this.getElementId("foreground"),name:"foreground",type:"rect",attrs:(0,y.pi)({y:0,height:r},d)});var v=(0,x.U2)(f,"width",10),m=(0,x.U2)(f,"height",24);this.minHandler=this.addComponent(e,{component:Ja,id:this.getElementId("minHandler"),name:"handler-min",x:0,y:(r-m)/2,width:v,height:m,cursor:"ew-resize",style:f}),this.maxHandler=this.addComponent(e,{component:Ja,id:this.getElementId("maxHandler"),name:"handler-max",x:0,y:(r-m)/2,width:v,height:m,cursor:"ew-resize",style:f})},t.prototype.applyOffset=function(){this.moveElementTo(this.get("group"),{x:this.get("x"),y:this.get("y")})},t.prototype.initEvent=function(){this.bindEvents()},t.prototype.updateUI=function(e,t,n){var r=this.cfg,a=r.start,i=r.end,o=r.width,s=r.minText,l=r.maxText,u=r.handlerStyle,c=r.height,d=a*o,p=i*o;this.trend&&(this.trend.update({width:o,height:c}),this.get("updateAutoRender")||this.trend.render()),e.attr("x",d),e.attr("width",p-d);var h=(0,x.U2)(u,"width",10);t.attr("text",s),n.attr("text",l);var f=this._dodgeText([d,p],t,n),v=f[0],m=f[1];this.minHandler&&(this.minHandler.update({x:d-h/2}),this.get("updateAutoRender")||this.minHandler.render()),(0,x.S6)(v,(function(e,n){return t.attr(n,e)})),this.maxHandler&&(this.maxHandler.update({x:p-h/2}),this.get("updateAutoRender")||this.maxHandler.render()),(0,x.S6)(m,(function(e,t){return n.attr(t,e)}))},t.prototype.bindEvents=function(){var e=this.get("group");e.on("handler-min:mousedown",this.onMouseDown("minHandler")),e.on("handler-min:touchstart",this.onMouseDown("minHandler")),e.on("handler-max:mousedown",this.onMouseDown("maxHandler")),e.on("handler-max:touchstart",this.onMouseDown("maxHandler"));var t=e.findById(this.getElementId("foreground"));t.on("mousedown",this.onMouseDown("foreground")),t.on("touchstart",this.onMouseDown("foreground"))},t.prototype.adjustOffsetRange=function(e){var t=this.cfg,n=t.start,r=t.end;switch(this.currentTarget){case"minHandler":var a=0-n,i=1-n;return Math.min(i,Math.max(a,e));case"maxHandler":a=0-r,i=1-r;return Math.min(i,Math.max(a,e));case"foreground":a=0-n,i=1-r;return Math.min(i,Math.max(a,e))}},t.prototype.updateStartEnd=function(e){var t=this.cfg,n=t.start,r=t.end;switch(this.currentTarget){case"minHandler":n+=e;break;case"maxHandler":r+=e;break;case"foreground":n+=e,r+=e}this.set("start",n),this.set("end",r)},t.prototype._dodgeText=function(e,t,n){var r,a,i=this.cfg,o=i.handlerStyle,s=i.width,l=(0,x.U2)(o,"width",10),u=e[0],c=e[1],d=!1;u>c&&(u=(r=[c,u])[0],c=r[1],t=(a=[n,t])[0],n=a[1],d=!0);var p=t.getBBox(),h=n.getBBox(),f=p.width>u-2?{x:u+l/2+2,textAlign:"left"}:{x:u-l/2-2,textAlign:"right"},v=h.width>s-c-2?{x:c-l/2-2,textAlign:"right"}:{x:c+l/2+2,textAlign:"left"};return d?[v,f]:[f,v]},t.prototype.draw=function(){var e=this.get("container"),t=e&&e.get("canvas");t&&t.draw()},t.prototype.getContainerDOM=function(){var e=this.get("container"),t=e&&e.get("canvas");return t&&t.get("container")},t}(Kn);function ai(e,t,n){if(e){if("function"==typeof e.addEventListener)return e.addEventListener(t,n,!1),{remove:function(){e.removeEventListener(t,n,!1)}};if("function"==typeof e.attachEvent)return e.attachEvent("on"+t,n),{remove:function(){e.detachEvent("on"+t,n)}}}}var ii={default:{trackColor:"rgba(0,0,0,0)",thumbColor:"rgba(0,0,0,0.15)",size:8,lineCap:"round"},hover:{thumbColor:"rgba(0,0,0,0.2)"}},oi=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.clearEvents=x.ZT,t.onStartEvent=function(e){return function(n){t.isMobile=e,n.originalEvent.preventDefault();var r=e?(0,x.U2)(n.originalEvent,"touches.0.clientX"):n.clientX,a=e?(0,x.U2)(n.originalEvent,"touches.0.clientY"):n.clientY;t.startPos=t.cfg.isHorizontal?r:a,t.bindLaterEvent()}},t.bindLaterEvent=function(){var e=t.getContainerDOM(),n=[];n=t.isMobile?[ai(e,"touchmove",t.onMouseMove),ai(e,"touchend",t.onMouseUp),ai(e,"touchcancel",t.onMouseUp)]:[ai(e,"mousemove",t.onMouseMove),ai(e,"mouseup",t.onMouseUp),ai(e,"mouseleave",t.onMouseUp)],t.clearEvents=function(){n.forEach((function(e){e.remove()}))}},t.onMouseMove=function(e){var n=t.cfg,r=n.isHorizontal,a=n.thumbOffset;e.preventDefault();var i=t.isMobile?(0,x.U2)(e,"touches.0.clientX"):e.clientX,o=t.isMobile?(0,x.U2)(e,"touches.0.clientY"):e.clientY,s=r?i:o,l=s-t.startPos;t.startPos=s,t.updateThumbOffset(a+l)},t.onMouseUp=function(e){e.preventDefault(),t.clearEvents()},t.onTrackClick=function(e){var n=t.cfg,r=n.isHorizontal,a=n.x,i=n.y,o=n.thumbLen,s=t.getContainerDOM().getBoundingClientRect(),l=e.clientX,u=e.clientY,c=r?l-s.left-a-o/2:u-s.top-i-o/2,d=t.validateRange(c);t.updateThumbOffset(d)},t.onThumbMouseOver=function(){var e=t.cfg.theme.hover.thumbColor;t.getElementByLocalId("thumb").attr("stroke",e),t.draw()},t.onThumbMouseOut=function(){var e=t.cfg.theme.default.thumbColor;t.getElementByLocalId("thumb").attr("stroke",e),t.draw()},t}return(0,y.ZT)(t,e),t.prototype.setRange=function(e,t){this.set("minLimit",e),this.set("maxLimit",t);var n=this.getValue(),r=(0,x.uZ)(n,e,t);n===r||this.get("isInit")||this.setValue(r)},t.prototype.getRange=function(){return{min:this.get("minLimit")||0,max:this.get("maxLimit")||1}},t.prototype.setValue=function(e){var t=this.getRange(),n=this.getValue();this.update({thumbOffset:(this.get("trackLen")-this.get("thumbLen"))*(0,x.uZ)(e,t.min,t.max)}),this.delegateEmit("valuechange",{originalValue:n,value:this.getValue()})},t.prototype.getValue=function(){return(0,x.uZ)(this.get("thumbOffset")/(this.get("trackLen")-this.get("thumbLen")),0,1)},t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return(0,y.pi)((0,y.pi)({},t),{name:"scrollbar",isHorizontal:!0,minThumbLen:20,thumbOffset:0,theme:ii})},t.prototype.renderInner=function(e){this.renderTrackShape(e),this.renderThumbShape(e)},t.prototype.applyOffset=function(){this.moveElementTo(this.get("group"),{x:this.get("x"),y:this.get("y")})},t.prototype.initEvent=function(){this.bindEvents()},t.prototype.renderTrackShape=function(e){var t=this.cfg,n=t.trackLen,r=t.theme,a=void 0===r?{default:{}}:r,i=(0,x.b$)({},ii,a).default,o=i.lineCap,s=i.trackColor,l=i.size,u=(0,x.U2)(this.cfg,"size",l),c=this.get("isHorizontal")?{x1:0+u/2,y1:u/2,x2:n-u/2,y2:u/2,lineWidth:u,stroke:s,lineCap:o}:{x1:u/2,y1:0+u/2,x2:u/2,y2:n-u/2,lineWidth:u,stroke:s,lineCap:o};return this.addShape(e,{id:this.getElementId("track"),name:"track",type:"line",attrs:c})},t.prototype.renderThumbShape=function(e){var t=this.cfg,n=t.thumbOffset,r=t.thumbLen,a=t.theme,i=(0,x.b$)({},ii,a).default,o=i.size,s=i.lineCap,l=i.thumbColor,u=(0,x.U2)(this.cfg,"size",o),c=this.get("isHorizontal")?{x1:n+u/2,y1:u/2,x2:n+r-u/2,y2:u/2,lineWidth:u,stroke:l,lineCap:s,cursor:"default"}:{x1:u/2,y1:n+u/2,x2:u/2,y2:n+r-u/2,lineWidth:u,stroke:l,lineCap:s,cursor:"default"};return this.addShape(e,{id:this.getElementId("thumb"),name:"thumb",type:"line",attrs:c})},t.prototype.bindEvents=function(){var e=this.get("group");e.on("mousedown",this.onStartEvent(!1)),e.on("mouseup",this.onMouseUp),e.on("touchstart",this.onStartEvent(!0)),e.on("touchend",this.onMouseUp),e.findById(this.getElementId("track")).on("click",this.onTrackClick);var t=e.findById(this.getElementId("thumb"));t.on("mouseover",this.onThumbMouseOver),t.on("mouseout",this.onThumbMouseOut)},t.prototype.getContainerDOM=function(){var e=this.get("container"),t=e&&e.get("canvas");return t&&t.get("container")},t.prototype.validateRange=function(e){var t=this.cfg,n=t.thumbLen,r=t.trackLen,a=e;return e+n>r?a=r-n:e+ne.x?e.x:t,n=ne.y?e.y:r,a=a=r&&e<=a}function bi(e,t){return"object"==typeof e&&t.forEach((function(t){delete e[t]})),e}function wi(e,t,n){var r,a;void 0===t&&(t=[]),void 0===n&&(n=new Map);try{for(var i=(0,y.XA)(e),o=i.next();!o.done;o=i.next()){var s=o.value;n.has(s)||(t.push(s),n.set(s,!0))}}catch(e){r={error:e}}finally{try{o&&!o.done&&(a=i.return)&&a.call(i)}finally{if(r)throw r.error}}return t}var Si=function(){function e(e,t,n,r){void 0===e&&(e=0),void 0===t&&(t=0),void 0===n&&(n=0),void 0===r&&(r=0),this.x=e,this.y=t,this.height=r,this.width=n}return e.fromRange=function(t,n,r,a){return new e(t,n,r-t,a-n)},e.fromObject=function(t){return new e(t.minX,t.minY,t.width,t.height)},Object.defineProperty(e.prototype,"minX",{get:function(){return this.x},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"maxX",{get:function(){return this.x+this.width},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"minY",{get:function(){return this.y},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"maxY",{get:function(){return this.y+this.height},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tl",{get:function(){return{x:this.x,y:this.y}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tr",{get:function(){return{x:this.maxX,y:this.y}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"bl",{get:function(){return{x:this.x,y:this.maxY}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"br",{get:function(){return{x:this.maxX,y:this.maxY}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"top",{get:function(){return{x:this.x+this.width/2,y:this.minY}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"right",{get:function(){return{x:this.maxX,y:this.y+this.height/2}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"bottom",{get:function(){return{x:this.x+this.width/2,y:this.maxY}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"left",{get:function(){return{x:this.minX,y:this.y+this.height/2}},enumerable:!1,configurable:!0}),e.prototype.isEqual=function(e){return this.x===e.x&&this.y===e.y&&this.width===e.width&&this.height===e.height},e.prototype.contains=function(e){return e.minX>=this.minX&&e.maxX<=this.maxX&&e.minY>=this.minY&&e.maxY<=this.maxY},e.prototype.clone=function(){return new e(this.x,this.y,this.width,this.height)},e.prototype.add=function(){for(var e=[],t=0;te.minX&&this.minYe.minY},e.prototype.size=function(){return this.width*this.height},e.prototype.isPointIn=function(e){return e.x>=this.minX&&e.x<=this.maxX&&e.y>=this.minY&&e.y<=this.maxY},e}();function Ei(e){if(e.isPolar&&!e.isTransposed)return(e.endAngle-e.startAngle)*e.getRadius();var t=e.convert({x:0,y:0}),n=e.convert({x:1,y:0});return Math.sqrt(Math.pow(n.x-t.x,2)+Math.pow(n.y-t.y,2))}function Ci(e,t){var n=e.getCenter();return Math.sqrt(Math.pow(t.x-n.x,2)+Math.pow(t.y-n.y,2))}function ki(e,t){var n=e.getCenter();return Math.atan2(t.y-n.y,t.x-n.x)}function Mi(e,t){void 0===t&&(t=0);var n,r=e.start,a=e.end,i=e.getWidth(),o=e.getHeight();if(e.isPolar){var s=e.startAngle,l=e.endAngle,u=e.getCenter(),c=e.getRadius();return{type:"path",startState:{path:gi(u.x,u.y,c+t,s,s)},endState:function(e){var n=(l-s)*e+s;return{path:gi(u.x,u.y,c+t,s,n)}},attrs:{path:gi(u.x,u.y,c+t,s,l)}}}return n=e.isTransposed?{height:o+2*t}:{width:i+2*t},{type:"rect",startState:{x:r.x-t,y:a.y-t,width:e.isTransposed?i+2*t:0,height:e.isTransposed?0:o+2*t},endState:n,attrs:{x:r.x-t,y:a.y-t,width:i+2*t,height:o+2*t}}}var Ti=/^(?:(?!0000)[0-9]{4}([-/.]+)(?:(?:0?[1-9]|1[0-2])\1(?:0?[1-9]|1[0-9]|2[0-8])|(?:0?[13-9]|1[0-2])\1(?:29|30)|(?:0?[13578]|1[02])\1(?:31))|(?:[0-9]{2}(?:0[48]|[2468][048]|[13579][26])|(?:0[48]|[2468][048]|[13579][26])00)([-/.]+)0?2\2(?:29))(\s+([01]|([01][0-9]|2[0-3])):([0-9]|[0-5][0-9]):([0-9]|[0-5][0-9]))?$/;function Ai(e,t,n,r){return void 0===t&&(t={}),t.type?t.type:"identity"!==e.type&&k.includes(n)&&["interval"].includes(r)||e.isCategory?"cat":e.type}function Li(e,t,n){var r=t||[];if((0,x.hj)(e)||(0,x.UM)((0,x.Wx)(r,e))&&(0,x.xb)(n))return new(Rt("identity"))({field:e.toString(),values:[e]});var a=(0,x.I)(r,e);return new(Rt((0,x.U2)(n,"type",function(e){var t="linear";return Ti.test(e)?t="timeCat":(0,x.HD)(e)&&(t="cat"),t}(a[0]))))((0,y.pi)({field:e,values:a},n))}function Pi(e){return e.alias||e.field}function Oi(e,t,n){var r,a=e.values.length;if(1===a)r=[.5,1];else{var i=0;r=function(e){if(e.isPolar){var t=e.startAngle;return e.endAngle-t==2*Math.PI}return!1}(t)?t.isTransposed?[(i=1/a*(0,x.U2)(n,"widthRatio.multiplePie",1/1.3))/2,1-i/2]:[0,1-1/a]:[i=1/a/2,1-i]}return r}function Ri(e){var t=e.values.filter((function(e){return!(0,x.UM)(e)&&!isNaN(e)}));return Math.max.apply(Math,(0,y.ev)((0,y.ev)([],(0,y.CR)(t),!1),[(0,x.UM)(e.max)?-1/0:e.max],!1))}function Di(e,t){var n={start:{x:0,y:0},end:{x:0,y:0}};e.isRect?n=function(e){var t,n;switch(e){case m.TOP:t={x:0,y:1},n={x:1,y:1};break;case m.RIGHT:t={x:1,y:0},n={x:1,y:1};break;case m.BOTTOM:t={x:0,y:0},n={x:1,y:0};break;case m.LEFT:t={x:0,y:0},n={x:0,y:1};break;default:t=n={x:0,y:0}}return{start:t,end:n}}(t):e.isPolar&&(n=function(e){var t,n;return e.isTransposed?(t={x:0,y:0},n={x:1,y:0}):(t={x:0,y:0},n={x:0,y:1}),{start:t,end:n}}(e));var r=n.start,a=n.end;return{start:e.convert(r),end:e.convert(a)}}function Ni(e){var t=e.start,n=e.end;return t.x===n.x}function zi(e,t){var n=e.start,r=e.end;return Ni(e)?(n.y-r.y)*(t.x-n.x)>0?1:-1:(r.x-n.x)*(n.y-t.y)>0?-1:1}function Fi(e,t){var n=(0,x.U2)(e,["components","axis"],{});return(0,x.b$)({},(0,x.U2)(n,["common"],{}),(0,x.b$)({},(0,x.U2)(n,[t],{})))}function Bi(e,t,n){var r=(0,x.U2)(e,["components","axis"],{});return(0,x.b$)({},(0,x.U2)(r,["common","title"],{}),(0,x.b$)({},(0,x.U2)(r,[t,"title"],{})),n)}function ji(e){var t=e.x,n=e.y,r=e.circleCenter,a=n.start>n.end,i=e.isTransposed?e.convert({x:a?0:1,y:0}):e.convert({x:0,y:a?0:1}),o=[i.x-r.x,i.y-r.y],s=[1,0],l=i.y>r.y?In.EU(o,s):-1*In.EU(o,s),u=l+(t.end-t.start);return{center:r,radius:Math.sqrt(Math.pow(i.x-r.x,2)+Math.pow(i.y-r.y,2)),startAngle:l,endAngle:u}}function Zi(e,t){return(0,x.jn)(e)?!1!==e&&{}:(0,x.U2)(e,[t])}function Ui(e,t){return(0,x.U2)(e,"position",t)}function Vi(e,t){return(0,x.U2)(t,["title","text"],Pi(e))}var Hi=function(){function e(e,t){this.destroyed=!1,this.facets=[],this.view=e,this.cfg=(0,x.b$)({},this.getDefaultCfg(),t)}return e.prototype.init=function(){this.container||(this.container=this.createContainer());var e=this.view.getData();this.facets=this.generateFacets(e)},e.prototype.render=function(){this.renderViews()},e.prototype.update=function(){},e.prototype.clear=function(){this.clearFacetViews()},e.prototype.destroy=function(){this.clear(),this.container&&(this.container.remove(!0),this.container=void 0),this.destroyed=!0,this.view=void 0,this.facets=[]},e.prototype.facetToView=function(e){var t=e.region,n=e.data,r=e.padding,a=void 0===r?this.cfg.padding:r,i=this.view.createView({region:t,padding:a});i.data(n||[]),e.view=i,this.beforeEachView(i,e);var o=this.cfg.eachView;return o&&o(i,e),this.afterEachView(i,e),i},e.prototype.createContainer=function(){return this.view.getLayer(v.FORE).addGroup()},e.prototype.renderViews=function(){this.createFacetViews()},e.prototype.createFacetViews=function(){var e=this;return this.facets.map((function(t){return e.facetToView(t)}))},e.prototype.clearFacetViews=function(){var e=this;(0,x.S6)(this.facets,(function(t){t.view&&(e.view.removeView(t.view),t.view=void 0)}))},e.prototype.parseSpacing=function(){var e=this.view.viewBBox,t=e.width,n=e.height;return this.cfg.spacing.map((function(e,r){return(0,x.hj)(e)?e/(0===r?t:n):parseFloat(e)/100}))},e.prototype.getFieldValues=function(e,t){var n=[],r={};return(0,x.S6)(e,(function(e){var a=e[t];(0,x.UM)(a)||r[a]||(n.push(a),r[a]=!0)})),n},e.prototype.getRegion=function(e,t,n,r){var a=(0,y.CR)(this.parseSpacing(),2),i=a[0],o=a[1],s=(1+i)/(0===t?1:t)-i,l=(1+o)/(0===e?1:e)-o,u={x:(s+i)*n,y:(l+o)*r};return{start:u,end:{x:u.x+s,y:u.y+l}}},e.prototype.getDefaultCfg=function(){return{eachView:void 0,showTitle:!0,spacing:[0,0],padding:10,fields:[]}},e.prototype.getDefaultTitleCfg=function(){return{style:{fontSize:14,fill:"#666",fontFamily:this.view.getTheme().fontFamily}}},e.prototype.processAxis=function(e,t){var n=e.getOptions(),r=n.coordinate,a=e.geometries;if("rect"===(0,x.U2)(r,"type","rect")&&a.length){(0,x.UM)(n.axes)&&(n.axes={});var i=n.axes,o=(0,y.CR)(a[0].getXYFields(),2),s=o[0],l=o[1],u=Zi(i,s),c=Zi(i,l);!1!==u&&(n.axes[s]=this.getXAxisOption(s,i,u,t)),!1!==c&&(n.axes[l]=this.getYAxisOption(l,i,c,t))}},e.prototype.getFacetDataFilter=function(e){return function(t){return(0,x.yW)(e,(function(e){var n=e.field,r=e.value;return!(!(0,x.UM)(r)&&n)||t[n]===r}))}},e}(),Gi={},qi=function(e){return Gi[(0,x.vl)(e)]},Wi=function(e,t){Gi[(0,x.vl)(e)]=t},Yi=function(){function e(e,t){this.context=e,this.cfg=t,e.addAction(this)}return e.prototype.applyCfg=function(e){(0,x.f0)(this,e)},e.prototype.init=function(){this.applyCfg(this.cfg)},e.prototype.destroy=function(){this.context.removeAction(this),this.context=null},e}(),Xi=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.execute=function(){this.callback&&this.callback(this.context)},t.prototype.destroy=function(){e.prototype.destroy.call(this),this.callback=null},t}(Yi),Ki=Xi,Ji={};function $i(e){var t=Ji[e];return(0,x.U2)(t,"ActionClass")}function Qi(e,t,n){Ji[e]={ActionClass:t,cfg:n}}function eo(e,t){var n=new Ki(t);return n.callback=e,n.name="callback",n}function to(e,t){for(var n=[e[0]],r=1,a=e.length;r=o[u]?1:0,p=c>Math.PI?1:0,h=n.convert(s),f=Ci(n,h);if(f>=.5)if(c===2*Math.PI){var v={x:(s.x+o.x)/2,y:(s.y+o.y)/2},m=n.convert(v);l.push(["A",f,f,0,p,d,m.x,m.y]),l.push(["A",f,f,0,p,d,h.x,h.y])}else l.push(["A",f,f,0,p,d,h.x,h.y]);return l}(n,r,e)):i.push(to(o,e));break;case"a":i.push(no(o,e));break;default:i.push(o)}})),function(e){(0,x.S6)(e,(function(t,n){if("a"===t[0].toLowerCase()){var r=e[n-1],a=e[n+1];a&&"a"===a[0].toLowerCase()?r&&"l"===r[0].toLowerCase()&&(r[0]="M"):r&&"a"===r[0].toLowerCase()&&a&&"l"===a[0].toLowerCase()&&(a[0]="M")}}))}(i),i}function so(e,t){var n=e.event.target.getCanvasBBox();return n.width>=t||n.height>=t?n:null}function lo(e){var t,n=e.event.target;return n&&(t=n.get("element")),t}function uo(e){var t,n=e.event.target;return n&&(t=n.get("delegateObject")),t}function co(e){var t=e.event.gEvent;return!(t&&t.fromShape&&t.toShape&&t.fromShape.get("element")===t.toShape.get("element"))}function po(e){return e&&e.component&&e.component.isList()}function ho(e){return e&&e.component&&e.component.isSlider()}function fo(e){var t=e.event.target;return t&&"mask"===t.get("name")}function vo(e,t){if("path"===e.event.target.get("type")){var n=function(e,t){var n=e.event.target,r=n.getCanvasBBox();return r.width>=t||r.height>=t?n.attr("path"):null}(e,t);if(!n)return;return function(e,t){var n=go(e),r=_o(t),a=n.filter((function(e){var t,n,a=e.shape;if("path"===a.get("type"))t=_o(a.attr("path"));else{var i=a.getCanvasBBox();t=[[(n=i).minX,n.minY],[n.maxX,n.minY],[n.maxX,n.maxY],[n.minX,n.maxY]]}return(0,Ga.Wq)(r,t)}));return a}(e.view,n)}var r=so(e,t);return r?Io(e.view,r):null}function mo(e,t,n){var r=so(e,n);if(!r)return null;var a=e.view,i=Co(a,t,{x:r.x,y:r.y}),o=Co(a,t,{x:r.maxX,y:r.maxY});return Io(t,{minX:i.x,minY:i.y,maxX:o.x,maxY:o.y})}function go(e){var t=e.geometries,n=[];return(0,x.S6)(t,(function(e){var t=e.elements;n=n.concat(t)})),e.views&&e.views.length&&(0,x.S6)(e.views,(function(e){n=n.concat(go(e))})),n}function yo(e,t){var n=e.geometries,r=[];return(0,x.S6)(n,(function(e){var n=e.getElementsBy((function(e){return e.hasState(t)}));r=r.concat(n)})),r}function xo(e,t){var n=e.getModel().data;return(0,x.kJ)(n)?n[0][t]:n[t]}function Io(e,t){var n=go(e),r=[];return(0,x.S6)(n,(function(e){var n,a,i=e.shape.getCanvasBBox();n=t,(a=i).minX>n.maxX||a.maxXn.maxY||a.maxY=t.x&&e.y<=t.y&&e.maxY>t.y}function Eo(e){var t=e.parent,n=null;return t&&(n=t.views.filter((function(t){return t!==e}))),n}function Co(e,t,n){var r=function(e,t){return e.getCoordinate().invert(t)}(e,n);return t.getCoordinate().convert(r)}function ko(e,t,n,r){var a=!1;return(0,x.S6)(e,(function(e){if(e[n]===t[n]&&e[r]===t[r])return a=!0,!1})),a}function Mo(e,t){var n=e.getScaleByField(t);return!n&&e.views&&(0,x.S6)(e.views,(function(e){if(n=Mo(e,t))return!1})),n}var To=function(){function e(e){this.actions=[],this.event=null,this.cacheMap={},this.view=e}return e.prototype.cache=function(){for(var e=[],t=0;t=0&&t.splice(n,1)},e.prototype.getCurrentPoint=function(){var e=this.event;return e?e.target instanceof HTMLElement?this.view.getCanvas().getPointByClient(e.clientX,e.clientY):{x:e.x,y:e.y}:null},e.prototype.getCurrentShape=function(){return(0,x.U2)(this.event,["gEvent","shape"])},e.prototype.isInPlot=function(){var e=this.getCurrentPoint();return!!e&&this.view.isPointInPlot(e)},e.prototype.isInShape=function(e){var t=this.getCurrentShape();return!!t&&t.get("name")===e},e.prototype.isInComponent=function(e){var t=bo(this.view),n=this.getCurrentPoint();return!!n&&!!t.find((function(t){var r=t.getBBox();return e?t.get("name")===e&&So(r,n):So(r,n)}))},e.prototype.destroy=function(){(0,x.S6)(this.actions.slice(),(function(e){e.destroy()})),this.view=null,this.event=null,this.actions=null,this.cacheMap=null},e}(),Ao=To,Lo=function(){function e(e,t){this.view=e,this.cfg=t}return e.prototype.init=function(){this.initEvents()},e.prototype.initEvents=function(){},e.prototype.clearEvents=function(){},e.prototype.destroy=function(){this.clearEvents()},e}(),Po=Lo;function Oo(e,t,n){var r=e.split(":"),a=r[0],i=t.getAction(a)||function(e,t){var n=Ji[e],r=null;return n&&((r=new(0,n.ActionClass)(t,n.cfg)).name=e,r.init()),r}(a,t);if(!i)throw new Error("There is no action named ".concat(a));return{action:i,methodName:r[1],arg:n}}function Ro(e){var t=e.action,n=e.methodName,r=e.arg;if(!t[n])throw new Error("Action(".concat(t.name,") doesn't have a method called ").concat(n));t[n](r)}var Do="start",No="showEnable",zo="end",Fo="rollback",Bo="processing",jo=function(e){function t(t,n){var r=e.call(this,t,n)||this;return r.callbackCaches={},r.emitCaches={},r.steps=n,r}return(0,y.ZT)(t,e),t.prototype.init=function(){this.initContext(),e.prototype.init.call(this)},t.prototype.destroy=function(){e.prototype.destroy.call(this),this.steps=null,this.context&&(this.context.destroy(),this.context=null),this.callbackCaches=null,this.view=null},t.prototype.initEvents=function(){var e=this;(0,x.S6)(this.steps,(function(t,n){(0,x.S6)(t,(function(t){var r=e.getActionCallback(n,t);r&&e.bindEvent(t.trigger,r)}))}))},t.prototype.clearEvents=function(){var e=this;(0,x.S6)(this.steps,(function(t,n){(0,x.S6)(t,(function(t){var r=e.getActionCallback(n,t);r&&e.offEvent(t.trigger,r)}))}))},t.prototype.initContext=function(){var e=this.view,t=new Ao(e);this.context=t;var n=this.steps;(0,x.S6)(n,(function(e){(0,x.S6)(e,(function(e){if((0,x.mf)(e.action))e.actionObject={action:eo(e.action,t),methodName:"execute"};else if((0,x.HD)(e.action))e.actionObject=Oo(e.action,t,e.arg);else if((0,x.kJ)(e.action)){var n=e.action,r=(0,x.kJ)(e.arg)?e.arg:[e.arg];e.actionObject=[],(0,x.S6)(n,(function(n,a){e.actionObject.push(Oo(n,t,r[a]))}))}}))}))},t.prototype.isAllowStep=function(e){var t=this.currentStepName,n=this.steps;if(t===e)return!0;if(e===No)return!0;if(e===Bo)return t===Do;if(e===Do)return t!==Bo;if(e===zo)return t===Bo||t===Do;if(e===Fo){if(n[zo])return t===zo;if(t===Do)return!0}return!1},t.prototype.isAllowExecute=function(e,t){if(this.isAllowStep(e)){var n=this.getKey(e,t);return(!t.once||!this.emitCaches[n])&&(!t.isEnable||t.isEnable(this.context))}return!1},t.prototype.enterStep=function(e){this.currentStepName=e,this.emitCaches={}},t.prototype.afterExecute=function(e,t){e!==No&&this.currentStepName!==e&&this.enterStep(e);var n=this.getKey(e,t);this.emitCaches[n]=!0},t.prototype.getKey=function(e,t){return e+t.trigger+t.action},t.prototype.getActionCallback=function(e,t){var n=this,r=this.context,a=this.callbackCaches,i=t.actionObject;if(t.action&&i){var o=this.getKey(e,t);if(!a[o]){var s=function(a){r.event=a,n.isAllowExecute(e,t)?((0,x.kJ)(i)?(0,x.S6)(i,(function(e){r.event=a,Ro(e)})):(r.event=a,Ro(i)),n.afterExecute(e,t),t.callback&&(r.event=a,t.callback(r))):r.event=null};t.debounce?a[o]=(0,x.Ds)(s,t.debounce.wait,t.debounce.immediate):t.throttle?a[o]=(0,x.P2)(s,t.throttle.wait,{leading:t.throttle.leading,trailing:t.throttle.trailing}):a[o]=s}return a[o]}return null},t.prototype.bindEvent=function(e,t){var n=e.split(":");"window"===n[0]?window.addEventListener(n[1],t):"document"===n[0]?document.addEventListener(n[1],t):this.view.on(e,t)},t.prototype.offEvent=function(e,t){var n=e.split(":");"window"===n[0]?window.removeEventListener(n[1],t):"document"===n[0]?document.removeEventListener(n[1],t):this.view.off(e,t)},t}(Po),Zo=jo,Uo={};function Vo(e){return Uo[(0,x.vl)(e)]}function Ho(e,t){Uo[(0,x.vl)(e)]=t}function Go(e){var t,n={point:{default:{fill:e.pointFillColor,r:e.pointSize,stroke:e.pointBorderColor,lineWidth:e.pointBorder,fillOpacity:e.pointFillOpacity},active:{stroke:e.pointActiveBorderColor,lineWidth:e.pointActiveBorder},selected:{stroke:e.pointSelectedBorderColor,lineWidth:e.pointSelectedBorder},inactive:{fillOpacity:e.pointInactiveFillOpacity,strokeOpacity:e.pointInactiveBorderOpacity}},hollowPoint:{default:{fill:e.hollowPointFillColor,lineWidth:e.hollowPointBorder,stroke:e.hollowPointBorderColor,strokeOpacity:e.hollowPointBorderOpacity,r:e.hollowPointSize},active:{stroke:e.hollowPointActiveBorderColor,strokeOpacity:e.hollowPointActiveBorderOpacity},selected:{lineWidth:e.hollowPointSelectedBorder,stroke:e.hollowPointSelectedBorderColor,strokeOpacity:e.hollowPointSelectedBorderOpacity},inactive:{strokeOpacity:e.hollowPointInactiveBorderOpacity}},area:{default:{fill:e.areaFillColor,fillOpacity:e.areaFillOpacity,stroke:null},active:{fillOpacity:e.areaActiveFillOpacity},selected:{fillOpacity:e.areaSelectedFillOpacity},inactive:{fillOpacity:e.areaInactiveFillOpacity}},hollowArea:{default:{fill:null,stroke:e.hollowAreaBorderColor,lineWidth:e.hollowAreaBorder,strokeOpacity:e.hollowAreaBorderOpacity},active:{fill:null,lineWidth:e.hollowAreaActiveBorder},selected:{fill:null,lineWidth:e.hollowAreaSelectedBorder},inactive:{strokeOpacity:e.hollowAreaInactiveBorderOpacity}},interval:{default:{fill:e.intervalFillColor,fillOpacity:e.intervalFillOpacity},active:{stroke:e.intervalActiveBorderColor,lineWidth:e.intervalActiveBorder},selected:{stroke:e.intervalSelectedBorderColor,lineWidth:e.intervalSelectedBorder},inactive:{fillOpacity:e.intervalInactiveFillOpacity,strokeOpacity:e.intervalInactiveBorderOpacity}},hollowInterval:{default:{fill:e.hollowIntervalFillColor,stroke:e.hollowIntervalBorderColor,lineWidth:e.hollowIntervalBorder,strokeOpacity:e.hollowIntervalBorderOpacity},active:{stroke:e.hollowIntervalActiveBorderColor,lineWidth:e.hollowIntervalActiveBorder,strokeOpacity:e.hollowIntervalActiveBorderOpacity},selected:{stroke:e.hollowIntervalSelectedBorderColor,lineWidth:e.hollowIntervalSelectedBorder,strokeOpacity:e.hollowIntervalSelectedBorderOpacity},inactive:{stroke:e.hollowIntervalInactiveBorderColor,lineWidth:e.hollowIntervalInactiveBorder,strokeOpacity:e.hollowIntervalInactiveBorderOpacity}},line:{default:{stroke:e.lineBorderColor,lineWidth:e.lineBorder,strokeOpacity:e.lineBorderOpacity,fill:null,lineAppendWidth:10,lineCap:"round",lineJoin:"round"},active:{lineWidth:e.lineActiveBorder},selected:{lineWidth:e.lineSelectedBorder},inactive:{strokeOpacity:e.lineInactiveBorderOpacity}}},r=function(e){return{title:{autoRotate:!0,position:"center",spacing:e.axisTitleSpacing,style:{fill:e.axisTitleTextFillColor,fontSize:e.axisTitleTextFontSize,lineHeight:e.axisTitleTextLineHeight,textBaseline:"middle",fontFamily:e.fontFamily},iconStyle:{fill:e.axisDescriptionIconFillColor}},label:{autoRotate:!1,autoEllipsis:!1,autoHide:{type:"equidistance",cfg:{minGap:6}},offset:e.axisLabelOffset,style:{fill:e.axisLabelFillColor,fontSize:e.axisLabelFontSize,lineHeight:e.axisLabelLineHeight,fontFamily:e.fontFamily}},line:{style:{lineWidth:e.axisLineBorder,stroke:e.axisLineBorderColor}},grid:{line:{type:"line",style:{stroke:e.axisGridBorderColor,lineWidth:e.axisGridBorder,lineDash:e.axisGridLineDash}},alignTick:!0,animate:!0},tickLine:{style:{lineWidth:e.axisTickLineBorder,stroke:e.axisTickLineBorderColor},alignTick:!0,length:e.axisTickLineLength},subTickLine:null,animate:!0}}(e),a=function(e){return{title:null,marker:{symbol:"circle",spacing:e.legendMarkerSpacing,style:{r:e.legendCircleMarkerSize,fill:e.legendMarkerColor}},itemName:{spacing:5,style:{fill:e.legendItemNameFillColor,fontFamily:e.fontFamily,fontSize:e.legendItemNameFontSize,lineHeight:e.legendItemNameLineHeight,fontWeight:e.legendItemNameFontWeight,textAlign:"start",textBaseline:"middle"}},itemStates:{active:{nameStyle:{opacity:.8}},unchecked:{nameStyle:{fill:"#D8D8D8"},markerStyle:{fill:"#D8D8D8",stroke:"#D8D8D8"}},inactive:{nameStyle:{fill:"#D8D8D8"},markerStyle:{opacity:.2}}},flipPage:!0,pageNavigator:{marker:{style:{size:e.legendPageNavigatorMarkerSize,inactiveFill:e.legendPageNavigatorMarkerInactiveFillColor,inactiveOpacity:e.legendPageNavigatorMarkerInactiveFillOpacity,fill:e.legendPageNavigatorMarkerFillColor,opacity:e.legendPageNavigatorMarkerFillOpacity}},text:{style:{fill:e.legendPageNavigatorTextFillColor,fontSize:e.legendPageNavigatorTextFontSize}}},animate:!1,maxItemWidth:200,itemSpacing:e.legendItemSpacing,itemMarginBottom:e.legendItemMarginBottom,padding:e.legendPadding}}(e);return{background:e.backgroundColor,defaultColor:e.brandColor,subColor:e.subColor,semanticRed:e.paletteSemanticRed,semanticGreen:e.paletteSemanticGreen,padding:"auto",fontFamily:e.fontFamily,columnWidthRatio:.5,maxColumnWidth:null,minColumnWidth:null,roseWidthRatio:.9999999,multiplePieWidthRatio:1/1.3,colors10:e.paletteQualitative10,colors20:e.paletteQualitative20,sequenceColors:e.paletteSequence,shapes:{point:["hollow-circle","hollow-square","hollow-bowtie","hollow-diamond","hollow-hexagon","hollow-triangle","hollow-triangle-down","circle","square","bowtie","diamond","hexagon","triangle","triangle-down","cross","tick","plus","hyphen","line"],line:["line","dash","dot","smooth"],area:["area","smooth","line","smooth-line"],interval:["rect","hollow-rect","line","tick"]},sizes:[1,10],geometries:{interval:{rect:{default:{style:n.interval.default},active:{style:n.interval.active},inactive:{style:n.interval.inactive},selected:{style:function(e){var t=e.geometry.coordinate;if(t.isPolar&&t.isTransposed){var r=xi(e.getModel(),t),a=(r.startAngle+r.endAngle)/2,i=7.5*Math.cos(a),o=7.5*Math.sin(a);return{matrix:vn.vs(null,[["t",i,o]])}}return n.interval.selected}}},"hollow-rect":{default:{style:n.hollowInterval.default},active:{style:n.hollowInterval.active},inactive:{style:n.hollowInterval.inactive},selected:{style:n.hollowInterval.selected}},line:{default:{style:n.hollowInterval.default},active:{style:n.hollowInterval.active},inactive:{style:n.hollowInterval.inactive},selected:{style:n.hollowInterval.selected}},tick:{default:{style:n.hollowInterval.default},active:{style:n.hollowInterval.active},inactive:{style:n.hollowInterval.inactive},selected:{style:n.hollowInterval.selected}},funnel:{default:{style:n.interval.default},active:{style:n.interval.active},inactive:{style:n.interval.inactive},selected:{style:n.interval.selected}},pyramid:{default:{style:n.interval.default},active:{style:n.interval.active},inactive:{style:n.interval.inactive},selected:{style:n.interval.selected}}},line:{line:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}},dot:{default:{style:(0,y.pi)((0,y.pi)({},n.line.default),{lineCap:null,lineDash:[1,1]})},active:{style:(0,y.pi)((0,y.pi)({},n.line.active),{lineCap:null,lineDash:[1,1]})},inactive:{style:(0,y.pi)((0,y.pi)({},n.line.inactive),{lineCap:null,lineDash:[1,1]})},selected:{style:(0,y.pi)((0,y.pi)({},n.line.selected),{lineCap:null,lineDash:[1,1]})}},dash:{default:{style:(0,y.pi)((0,y.pi)({},n.line.default),{lineCap:null,lineDash:[5.5,1]})},active:{style:(0,y.pi)((0,y.pi)({},n.line.active),{lineCap:null,lineDash:[5.5,1]})},inactive:{style:(0,y.pi)((0,y.pi)({},n.line.inactive),{lineCap:null,lineDash:[5.5,1]})},selected:{style:(0,y.pi)((0,y.pi)({},n.line.selected),{lineCap:null,lineDash:[5.5,1]})}},smooth:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}},hv:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}},vh:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}},hvh:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}},vhv:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}}},polygon:{polygon:{default:{style:n.interval.default},active:{style:n.interval.active},inactive:{style:n.interval.inactive},selected:{style:n.interval.selected}}},point:{circle:{default:{style:n.point.default},active:{style:n.point.active},inactive:{style:n.point.inactive},selected:{style:n.point.selected}},square:{default:{style:n.point.default},active:{style:n.point.active},inactive:{style:n.point.inactive},selected:{style:n.point.selected}},bowtie:{default:{style:n.point.default},active:{style:n.point.active},inactive:{style:n.point.inactive},selected:{style:n.point.selected}},diamond:{default:{style:n.point.default},active:{style:n.point.active},inactive:{style:n.point.inactive},selected:{style:n.point.selected}},hexagon:{default:{style:n.point.default},active:{style:n.point.active},inactive:{style:n.point.inactive},selected:{style:n.point.selected}},triangle:{default:{style:n.point.default},active:{style:n.point.active},inactive:{style:n.point.inactive},selected:{style:n.point.selected}},"triangle-down":{default:{style:n.point.default},active:{style:n.point.active},inactive:{style:n.point.inactive},selected:{style:n.point.selected}},"hollow-circle":{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},"hollow-square":{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},"hollow-bowtie":{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},"hollow-diamond":{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},"hollow-hexagon":{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},"hollow-triangle":{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},"hollow-triangle-down":{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},cross:{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},tick:{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},plus:{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},hyphen:{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},line:{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}}},area:{area:{default:{style:n.area.default},active:{style:n.area.active},inactive:{style:n.area.inactive},selected:{style:n.area.selected}},smooth:{default:{style:n.area.default},active:{style:n.area.active},inactive:{style:n.area.inactive},selected:{style:n.area.selected}},line:{default:{style:n.hollowArea.default},active:{style:n.hollowArea.active},inactive:{style:n.hollowArea.inactive},selected:{style:n.hollowArea.selected}},"smooth-line":{default:{style:n.hollowArea.default},active:{style:n.hollowArea.active},inactive:{style:n.hollowArea.inactive},selected:{style:n.hollowArea.selected}}},schema:{candle:{default:{style:n.hollowInterval.default},active:{style:n.hollowInterval.active},inactive:{style:n.hollowInterval.inactive},selected:{style:n.hollowInterval.selected}},box:{default:{style:n.hollowInterval.default},active:{style:n.hollowInterval.active},inactive:{style:n.hollowInterval.inactive},selected:{style:n.hollowInterval.selected}}},edge:{line:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}},vhv:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}},smooth:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}},arc:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}}},violin:{violin:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}},smooth:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}},hollow:{default:{style:n.hollowArea.default},active:{style:n.hollowArea.active},inactive:{style:n.hollowArea.inactive},selected:{style:n.hollowArea.selected}},"hollow-smooth":{default:{style:n.hollowArea.default},active:{style:n.hollowArea.active},inactive:{style:n.hollowArea.inactive},selected:{style:n.hollowArea.selected}}}},components:{axis:{common:r,top:{position:"top",grid:null,title:null,verticalLimitLength:.5},bottom:{position:"bottom",grid:null,title:null,verticalLimitLength:.5},left:{position:"left",title:null,line:null,tickLine:null,verticalLimitLength:1/3},right:{position:"right",title:null,line:null,tickLine:null,verticalLimitLength:1/3},circle:{title:null,grid:(0,x.b$)({},r.grid,{line:{type:"line"}})},radius:{title:null,grid:(0,x.b$)({},r.grid,{line:{type:"circle"}})}},legend:{common:a,right:{layout:"vertical",padding:e.legendVerticalPadding},left:{layout:"vertical",padding:e.legendVerticalPadding},top:{layout:"horizontal",padding:e.legendHorizontalPadding},bottom:{layout:"horizontal",padding:e.legendHorizontalPadding},continuous:{title:null,background:null,track:{},rail:{type:"color",size:e.sliderRailHeight,defaultLength:e.sliderRailWidth,style:{fill:e.sliderRailFillColor,stroke:e.sliderRailBorderColor,lineWidth:e.sliderRailBorder}},label:{align:"rail",spacing:4,formatter:null,style:{fill:e.sliderLabelTextFillColor,fontSize:e.sliderLabelTextFontSize,lineHeight:e.sliderLabelTextLineHeight,textBaseline:"middle",fontFamily:e.fontFamily}},handler:{size:e.sliderHandlerWidth,style:{fill:e.sliderHandlerFillColor,stroke:e.sliderHandlerBorderColor}},slidable:!0,padding:a.padding}},tooltip:{showContent:!0,follow:!0,showCrosshairs:!1,showMarkers:!0,shared:!1,enterable:!1,position:"auto",marker:{symbol:"circle",stroke:"#fff",shadowBlur:10,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"rgba(0,0,0,0.09)",lineWidth:2,r:4},crosshairs:{line:{style:{stroke:e.tooltipCrosshairsBorderColor,lineWidth:e.tooltipCrosshairsBorder}},text:null,textBackground:{padding:2,style:{fill:"rgba(0, 0, 0, 0.25)",lineWidth:0,stroke:null}},follow:!1},domStyles:(t={},t["".concat(Aa)]={position:"absolute",visibility:"hidden",zIndex:8,transition:"left 0.4s cubic-bezier(0.23, 1, 0.32, 1) 0s, top 0.4s cubic-bezier(0.23, 1, 0.32, 1) 0s",backgroundColor:e.tooltipContainerFillColor,opacity:e.tooltipContainerFillOpacity,boxShadow:e.tooltipContainerShadow,borderRadius:"".concat(e.tooltipContainerBorderRadius,"px"),color:e.tooltipTextFillColor,fontSize:"".concat(e.tooltipTextFontSize,"px"),fontFamily:e.fontFamily,lineHeight:"".concat(e.tooltipTextLineHeight,"px"),padding:"0 12px 0 12px"},t["".concat(La)]={marginBottom:"12px",marginTop:"12px"},t["".concat(Pa)]={margin:0,listStyleType:"none",padding:0},t["".concat(Oa)]={listStyleType:"none",padding:0,marginBottom:"12px",marginTop:"12px",marginLeft:0,marginRight:0},t["".concat(Ra)]={width:"8px",height:"8px",borderRadius:"50%",display:"inline-block",marginRight:"8px"},t["".concat(Da)]={display:"inline-block",float:"right",marginLeft:"30px"},t)},annotation:{arc:{style:{stroke:e.annotationArcBorderColor,lineWidth:e.annotationArcBorder},animate:!0},line:{style:{stroke:e.annotationLineBorderColor,lineDash:e.annotationLineDash,lineWidth:e.annotationLineBorder},text:{position:"start",autoRotate:!0,style:{fill:e.annotationTextFillColor,stroke:e.annotationTextBorderColor,lineWidth:e.annotationTextBorder,fontSize:e.annotationTextFontSize,textAlign:"start",fontFamily:e.fontFamily,textBaseline:"bottom"}},animate:!0},text:{style:{fill:e.annotationTextFillColor,stroke:e.annotationTextBorderColor,lineWidth:e.annotationTextBorder,fontSize:e.annotationTextFontSize,textBaseline:"middle",textAlign:"start",fontFamily:e.fontFamily},animate:!0},region:{top:!1,style:{lineWidth:e.annotationRegionBorder,stroke:e.annotationRegionBorderColor,fill:e.annotationRegionFillColor,fillOpacity:e.annotationRegionFillOpacity},animate:!0},image:{top:!1,animate:!0},dataMarker:{top:!0,point:{style:{r:3,stroke:e.brandColor,lineWidth:2}},line:{style:{stroke:e.annotationLineBorderColor,lineWidth:e.annotationLineBorder},length:e.annotationDataMarkerLineLength},text:{style:{textAlign:"start",fill:e.annotationTextFillColor,stroke:e.annotationTextBorderColor,lineWidth:e.annotationTextBorder,fontSize:e.annotationTextFontSize,fontFamily:e.fontFamily}},direction:"upward",autoAdjust:!0,animate:!0},dataRegion:{style:{region:{fill:e.annotationRegionFillColor,fillOpacity:e.annotationRegionFillOpacity},text:{textAlign:"center",textBaseline:"bottom",fill:e.annotationTextFillColor,stroke:e.annotationTextBorderColor,lineWidth:e.annotationTextBorder,fontSize:e.annotationTextFontSize,fontFamily:e.fontFamily}},animate:!0}},slider:{common:{padding:[8,8,8,8],backgroundStyle:{fill:e.cSliderBackgroundFillColor,opacity:e.cSliderBackgroundFillOpacity},foregroundStyle:{fill:e.cSliderForegroundFillColor,opacity:e.cSliderForegroundFillOpacity},handlerStyle:{width:e.cSliderHandlerWidth,height:e.cSliderHandlerHeight,fill:e.cSliderHandlerFillColor,opacity:e.cSliderHandlerFillOpacity,stroke:e.cSliderHandlerBorderColor,lineWidth:e.cSliderHandlerBorder,radius:e.cSliderHandlerBorderRadius,highLightFill:e.cSliderHandlerHighlightFillColor},textStyle:{fill:e.cSliderTextFillColor,opacity:e.cSliderTextFillOpacity,fontSize:e.cSliderTextFontSize,lineHeight:e.cSliderTextLineHeight,fontWeight:e.cSliderTextFontWeight,stroke:e.cSliderTextBorderColor,lineWidth:e.cSliderTextBorder}}},scrollbar:{common:{padding:[8,8,8,8]},default:{style:{trackColor:e.scrollbarTrackFillColor,thumbColor:e.scrollbarThumbFillColor}},hover:{style:{thumbColor:e.scrollbarThumbHighlightFillColor}}}},labels:{offset:12,style:{fill:e.labelFillColor,fontSize:e.labelFontSize,fontFamily:e.fontFamily,stroke:e.labelBorderColor,lineWidth:e.labelBorder},fillColorDark:e.labelFillColorDark,fillColorLight:e.labelFillColorLight,autoRotate:!0},innerLabels:{style:{fill:e.innerLabelFillColor,fontSize:e.innerLabelFontSize,fontFamily:e.fontFamily,stroke:e.innerLabelBorderColor,lineWidth:e.innerLabelBorder},autoRotate:!0},overflowLabels:{style:{fill:e.overflowLabelFillColor,fontSize:e.overflowLabelFontSize,fontFamily:e.fontFamily,stroke:e.overflowLabelBorderColor,lineWidth:e.overflowLabelBorder}},pieLabels:{labelHeight:14,offset:10,labelLine:{style:{lineWidth:e.labelLineBorder}},autoRotate:!0}}}var qo="#000",Wo="#595959",Yo="#8C8C8C",Xo="#BFBFBF",Ko="#D9D9D9",Jo="#F0F0F0",$o="#FFFFFF",Qo="#D9D9D9",es=["#5B8FF9","#5AD8A6","#5D7092","#F6BD16","#6F5EF9","#6DC8EC","#945FB9","#FF9845","#1E9493","#FF99C3"],ts=["#5B8FF9","#CDDDFD","#5AD8A6","#CDF3E4","#5D7092","#CED4DE","#F6BD16","#FCEBB9","#6F5EF9","#D3CEFD","#6DC8EC","#D3EEF9","#945FB9","#DECFEA","#FF9845","#FFE0C7","#1E9493","#BBDEDE","#FF99C3","#FFE0ED"],ns=["#B8E1FF","#9AC5FF","#7DAAFF","#5B8FF9","#3D76DD","#085EC0","#0047A5","#00318A","#001D70"],rs=function(e){void 0===e&&(e={});var t=e.paletteQualitative10,n=void 0===t?es:t,r=e.paletteQualitative20,a=void 0===r?ts:r,i=e.brandColor,o=void 0===i?n[0]:i,s={backgroundColor:"transparent",brandColor:o,subColor:"rgba(0,0,0,0.05)",paletteQualitative10:n,paletteQualitative20:a,paletteSemanticRed:"#F4664A",paletteSemanticGreen:"#30BF78",paletteSemanticYellow:"#FAAD14",paletteSequence:ns,fontFamily:'"Segoe UI", Roboto, "Helvetica Neue", Arial,\n "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol",\n "Noto Color Emoji"',axisLineBorderColor:Xo,axisLineBorder:1,axisLineDash:null,axisTitleTextFillColor:Wo,axisTitleTextFontSize:12,axisTitleTextLineHeight:12,axisTitleTextFontWeight:"normal",axisTitleSpacing:12,axisDescriptionIconFillColor:Qo,axisTickLineBorderColor:Xo,axisTickLineLength:4,axisTickLineBorder:1,axisSubTickLineBorderColor:Ko,axisSubTickLineLength:2,axisSubTickLineBorder:1,axisLabelFillColor:Yo,axisLabelFontSize:12,axisLabelLineHeight:12,axisLabelFontWeight:"normal",axisLabelOffset:8,axisGridBorderColor:Ko,axisGridBorder:1,axisGridLineDash:null,legendTitleTextFillColor:Yo,legendTitleTextFontSize:12,legendTitleTextLineHeight:21,legendTitleTextFontWeight:"normal",legendMarkerColor:o,legendMarkerSpacing:8,legendMarkerSize:4,legendCircleMarkerSize:4,legendSquareMarkerSize:4,legendLineMarkerSize:5,legendItemNameFillColor:Wo,legendItemNameFontSize:12,legendItemNameLineHeight:12,legendItemNameFontWeight:"normal",legendItemSpacing:24,legendItemMarginBottom:12,legendPadding:[8,8,8,8],legendHorizontalPadding:[8,0,8,0],legendVerticalPadding:[0,8,0,8],legendPageNavigatorMarkerSize:12,legendPageNavigatorMarkerInactiveFillColor:qo,legendPageNavigatorMarkerInactiveFillOpacity:.45,legendPageNavigatorMarkerFillColor:qo,legendPageNavigatorMarkerFillOpacity:1,legendPageNavigatorTextFillColor:Yo,legendPageNavigatorTextFontSize:12,sliderRailFillColor:Ko,sliderRailBorder:0,sliderRailBorderColor:null,sliderRailWidth:100,sliderRailHeight:12,sliderLabelTextFillColor:Yo,sliderLabelTextFontSize:12,sliderLabelTextLineHeight:12,sliderLabelTextFontWeight:"normal",sliderHandlerFillColor:Jo,sliderHandlerWidth:10,sliderHandlerHeight:14,sliderHandlerBorder:1,sliderHandlerBorderColor:Xo,annotationArcBorderColor:Ko,annotationArcBorder:1,annotationLineBorderColor:Xo,annotationLineBorder:1,annotationLineDash:null,annotationTextFillColor:Wo,annotationTextFontSize:12,annotationTextLineHeight:12,annotationTextFontWeight:"normal",annotationTextBorderColor:null,annotationTextBorder:0,annotationRegionFillColor:qo,annotationRegionFillOpacity:.06,annotationRegionBorder:0,annotationRegionBorderColor:null,annotationDataMarkerLineLength:16,tooltipCrosshairsBorderColor:Xo,tooltipCrosshairsBorder:1,tooltipCrosshairsLineDash:null,tooltipContainerFillColor:"rgb(255, 255, 255)",tooltipContainerFillOpacity:.95,tooltipContainerShadow:"0px 0px 10px #aeaeae",tooltipContainerBorderRadius:3,tooltipTextFillColor:Wo,tooltipTextFontSize:12,tooltipTextLineHeight:12,tooltipTextFontWeight:"bold",labelFillColor:Wo,labelFillColorDark:"#2c3542",labelFillColorLight:"#ffffff",labelFontSize:12,labelLineHeight:12,labelFontWeight:"normal",labelBorderColor:null,labelBorder:0,innerLabelFillColor:$o,innerLabelFontSize:12,innerLabelLineHeight:12,innerLabelFontWeight:"normal",innerLabelBorderColor:null,innerLabelBorder:0,overflowLabelFillColor:Wo,overflowLabelFontSize:12,overflowLabelLineHeight:12,overflowLabelFontWeight:"normal",overflowLabelBorderColor:$o,overflowLabelBorder:1,labelLineBorder:1,labelLineBorderColor:Xo,cSliderRailHieght:16,cSliderBackgroundFillColor:"#416180",cSliderBackgroundFillOpacity:.05,cSliderForegroundFillColor:"#5B8FF9",cSliderForegroundFillOpacity:.15,cSliderHandlerHeight:24,cSliderHandlerWidth:10,cSliderHandlerFillColor:"#F7F7F7",cSliderHandlerFillOpacity:1,cSliderHandlerHighlightFillColor:"#FFF",cSliderHandlerBorderColor:"#BFBFBF",cSliderHandlerBorder:1,cSliderHandlerBorderRadius:2,cSliderTextFillColor:"#000",cSliderTextFillOpacity:.45,cSliderTextFontSize:12,cSliderTextLineHeight:12,cSliderTextFontWeight:"normal",cSliderTextBorderColor:null,cSliderTextBorder:0,scrollbarTrackFillColor:"rgba(0,0,0,0)",scrollbarThumbFillColor:"rgba(0,0,0,0.15)",scrollbarThumbHighlightFillColor:"rgba(0,0,0,0.2)",pointFillColor:o,pointFillOpacity:.95,pointSize:4,pointBorder:1,pointBorderColor:$o,pointBorderOpacity:1,pointActiveBorderColor:qo,pointSelectedBorder:2,pointSelectedBorderColor:qo,pointInactiveFillOpacity:.3,pointInactiveBorderOpacity:.3,hollowPointSize:4,hollowPointBorder:1,hollowPointBorderColor:o,hollowPointBorderOpacity:.95,hollowPointFillColor:$o,hollowPointActiveBorder:1,hollowPointActiveBorderColor:qo,hollowPointActiveBorderOpacity:1,hollowPointSelectedBorder:2,hollowPointSelectedBorderColor:qo,hollowPointSelectedBorderOpacity:1,hollowPointInactiveBorderOpacity:.3,lineBorder:2,lineBorderColor:o,lineBorderOpacity:1,lineActiveBorder:3,lineSelectedBorder:3,lineInactiveBorderOpacity:.3,areaFillColor:o,areaFillOpacity:.25,areaActiveFillColor:o,areaActiveFillOpacity:.5,areaSelectedFillColor:o,areaSelectedFillOpacity:.5,areaInactiveFillOpacity:.3,hollowAreaBorderColor:o,hollowAreaBorder:2,hollowAreaBorderOpacity:1,hollowAreaActiveBorder:3,hollowAreaActiveBorderColor:qo,hollowAreaSelectedBorder:3,hollowAreaSelectedBorderColor:qo,hollowAreaInactiveBorderOpacity:.3,intervalFillColor:o,intervalFillOpacity:.95,intervalActiveBorder:1,intervalActiveBorderColor:qo,intervalActiveBorderOpacity:1,intervalSelectedBorder:2,intervalSelectedBorderColor:qo,intervalSelectedBorderOpacity:1,intervalInactiveBorderOpacity:.3,intervalInactiveFillOpacity:.3,hollowIntervalBorder:2,hollowIntervalBorderColor:o,hollowIntervalBorderOpacity:1,hollowIntervalFillColor:$o,hollowIntervalActiveBorder:2,hollowIntervalActiveBorderColor:qo,hollowIntervalSelectedBorder:3,hollowIntervalSelectedBorderColor:qo,hollowIntervalSelectedBorderOpacity:1,hollowIntervalInactiveBorderOpacity:.3};return(0,y.pi)((0,y.pi)({},s),e)};rs();function as(e){var t=e.styleSheet,n=void 0===t?{}:t,r=(0,y._T)(e,["styleSheet"]),a=rs(n);return(0,x.b$)({},Go(a),r)}var is={default:as({})};function os(e){return(0,x.U2)(is,(0,x.vl)(e),is.default)}function ss(e,t){is[(0,x.vl)(e)]=as(t)}function ls(e,t,n){var r=n.translate(e),a=n.translate(t);return(0,x.vQ)(r,a)}function us(e,t,n){var r=n.coordinate,a=n.getYScale(),i=a.field,o=r.invert(t),s=a.invert(o.y);return(0,x.sE)(e,(function(e){var t=e[M];return t[i][0]<=s&&t[i][1]>=s}))||e[e.length-1]}var cs=(0,x.HP)((function(e){if(e.isCategory)return 1;for(var t=e.values,n=t.length,r=e.translate(t[0]),a=r,i=0;ia&&(a=s)}return(a-r)/(n-1)}));function ds(e){var t,n,r,a=function(e){var t=(0,x.VO)(e.attributes);return(0,x.hX)(t,(function(e){return(0,x.FX)(k,e.type)}))}(e);try{for(var i=(0,y.XA)(a),o=i.next();!o.done;o=i.next()){var s=o.value,l=s.getScale(s.type);if(l&&l.isLinear)if("cat"!==Ai(l,(0,x.U2)(e.scaleDefs,l.field),s.type,e.type)){r=l;break}}}catch(e){t={error:e}}finally{try{o&&!o.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}var u=e.getXScale(),c=e.getYScale();return r||c||u}function ps(e,t,n){if(0===t.length)return null;var r=n.type,a=n.getXScale(),i=n.getYScale(),o=a.field,s=i.field,l=null;if("heatmap"===r||"point"===r){for(var u=n.coordinate.invert(e),c=a.invert(u.x),d=i.invert(u.y),p=1/0,h=0;h(1+i)/2&&(s=o),r.translate(r.invert(s))}(e,n),_=g[M][o],b=g[M][s],w=y[M][o],S=i.isLinear&&(0,x.kJ)(b);if((0,x.kJ)(_)){for(h=0;h=I){if(!S){l=L;break}(0,x.kJ)(l)||(l=[]),l.push(L)}}(0,x.kJ)(l)&&(l=us(l,e,n))}else{var E=void 0;if(a.isLinear||"timeCat"===a.type){if((I>a.translate(w)||Ia.max||IMath.abs(a.translate(E[M][o])-I)&&(y=E)}var P=cs(n.getXScale());return!l&&Math.abs(a.translate(y[M][o])-I)<=P/2&&(l=y),l}function hs(e,t,n,r){var a,i;void 0===n&&(n=""),void 0===r&&(r=!1);var o,s,l=e[M],u=function(e,t,n){var r=t.getAttribute("position").getFields(),a=t.scales,i=(0,x.mf)(n)||!n?r[0]:n,o=a[i],s=o?o.getText(e[i]):e[i]||i;return(0,x.mf)(n)?n(s,e):s}(l,t,n),c=t.tooltipOption,d=t.theme.defaultColor,p=[];function h(t,n){if(r||!(0,x.UM)(n)&&""!==n){var a={title:u,data:l,mappingData:e,name:t,value:n,color:e.color||d,marker:!0};p.push(a)}}if((0,x.Kn)(c)){var f=c.fields,v=c.callback;if(v){var m=f.map((function(t){return e[M][t]})),g=v.apply(void 0,(0,y.ev)([],(0,y.CR)(m),!1)),I=(0,y.pi)({data:e[M],mappingData:e,title:u,color:e.color||d,marker:!0},g);p.push(I)}else{var _=t.scales;try{for(var b=(0,y.XA)(f),w=b.next();!w.done;w=b.next()){var S=w.value;if(!(0,x.UM)(l[S])){var E=_[S];h(o=Pi(E),s=E.getText(l[S]))}}}catch(e){a={error:e}}finally{try{w&&!w.done&&(i=b.return)&&i.call(b)}finally{if(a)throw a.error}}}}else{var C=ds(t);s=function(e,t){var n=e[t.field];return(0,x.kJ)(n)?n.map((function(e){return t.getText(e)})).join("-"):t.getText(n)}(l,C),o=function(e,t){var n,r=t.getGroupScales();if(r.length&&(n=r[0]),n){var a=n.field;return n.getText(e[a])}return Pi(ds(t))}(l,t),h(o,s)}return p}function fs(e,t,n,r){var a,i,o=r.showNil,s=[],l=e.dataArray;if(!(0,x.xb)(l)){e.sort(l);try{for(var u=(0,y.XA)(l),c=u.next();!c.done;c=u.next()){var d=ps(t,c.value,e);if(d){var p=e.getElementId(d),h=e.elementsMap[p];if("heatmap"===e.type||h.visible){var f=hs(d,e,n,o);f.length&&s.push(f)}}}}catch(e){a={error:e}}finally{try{c&&!c.done&&(i=u.return)&&i.call(u)}finally{if(a)throw a.error}}}return s}function vs(e,t,n,r){var a=r.showNil,i=[],o=e.container.getShape(t.x,t.y);if(o&&o.get("visible")&&o.get("origin")){var s=hs(o.get("origin").mappingData,e,n,a);s.length&&i.push(s)}return i}function ms(e,t,n){var r,a,i=[],o=e.geometries,s=n.shared,l=n.title,u=n.reversed;try{for(var c=(0,y.XA)(o),d=c.next();!d.done;d=c.next()){var p=d.value;if(p.visible&&!1!==p.tooltipOption){var h=p.type,f=void 0;(f=["point","edge","polygon"].includes(h)?vs(p,t,l,n):["area","line","path","heatmap"].includes(h)||!1!==s?fs(p,t,l,n):vs(p,t,l,n)).length&&(u&&f.reverse(),i.push(f))}}}catch(e){r={error:e}}finally{try{d&&!d.done&&(a=c.return)&&a.call(c)}finally{if(r)throw r.error}}return i}function gs(e){void 0===e&&(e=0);var t=(0,x.kJ)(e)?e:[e];switch(t.length){case 0:t=[0,0,0,0];break;case 1:t=new Array(4).fill(t[0]);break;case 2:t=(0,y.ev)((0,y.ev)([],(0,y.CR)(t),!1),(0,y.CR)(t),!1);break;case 3:t=(0,y.ev)((0,y.ev)([],(0,y.CR)(t),!1),[t[1]],!1);break;default:t=t.slice(0,4)}return t}var ys={};function xs(e,t){ys[e]=t}var Is=function(){function e(e){this.option=this.wrapperOption(e)}return e.prototype.update=function(e){return this.option=this.wrapperOption(e),this},e.prototype.hasAction=function(e){var t=this.option.actions;return(0,x.G)(t,(function(t){return t[0]===e}))},e.prototype.create=function(e,t){var n=this.option,r=n.type,a=n.cfg,i="theta"===r,o=(0,y.pi)({start:e,end:t},a),s=function(e){return En[e.toLowerCase()]}(i?"polar":r);return this.coordinate=new s(o),this.coordinate.type=r,i&&(this.hasAction("transpose")||this.transpose()),this.execActions(),this.coordinate},e.prototype.adjust=function(e,t){return this.coordinate.update({start:e,end:t}),this.coordinate.resetMatrix(),this.execActions(["scale","rotate","translate"]),this.coordinate},e.prototype.rotate=function(e){return this.option.actions.push(["rotate",e]),this},e.prototype.reflect=function(e){return this.option.actions.push(["reflect",e]),this},e.prototype.scale=function(e,t){return this.option.actions.push(["scale",e,t]),this},e.prototype.transpose=function(){return this.option.actions.push(["transpose"]),this},e.prototype.getOption=function(){return this.option},e.prototype.getCoordinate=function(){return this.coordinate},e.prototype.wrapperOption=function(e){return(0,y.pi)({type:"rect",actions:[],cfg:{}},e)},e.prototype.execActions=function(e){var t=this,n=this.option.actions;(0,x.S6)(n,(function(n){var r,a=(0,y.CR)(n),i=a[0],o=a.slice(1);(!!(0,x.UM)(e)||e.includes(i))&&(r=t.coordinate)[i].apply(r,(0,y.ev)([],(0,y.CR)(o),!1))}))},e}(),_s=Is,bs=function(){function e(e,t,n){this.view=e,this.gEvent=t,this.data=n,this.type=t.type}return e.fromData=function(t,n,r){return new e(t,new F.Event(n,{}),r)},Object.defineProperty(e.prototype,"target",{get:function(){return this.gEvent.target},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"event",{get:function(){return this.gEvent.originalEvent},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"x",{get:function(){return this.gEvent.x},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"y",{get:function(){return this.gEvent.y},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"clientX",{get:function(){return this.gEvent.clientX},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"clientY",{get:function(){return this.gEvent.clientY},enumerable:!1,configurable:!0}),e.prototype.toString=function(){return"[Event (type=".concat(this.type,")]")},e.prototype.clone=function(){return new e(this.view,this.gEvent,this.data)},e}(),ws=bs;function Ss(e){var t=e.getController("axis"),n=e.getController("legend"),r=e.getController("annotation");[t,e.getController("slider"),e.getController("scrollbar"),n,r].forEach((function(e){e&&e.layout()}))}var Es=function(){function e(){this.scales=new Map,this.syncScales=new Map}return e.prototype.createScale=function(e,t,n,r){var a=n,i=this.getScaleMeta(r);if(0===t.length&&i){var o=i.scale,s={type:o.type};o.isCategory&&(s.values=o.values),a=(0,x.b$)(s,i.scaleDef,n)}var l=Li(e,t,a);return this.cacheScale(l,n,r),l},e.prototype.sync=function(e,t){var n=this;this.syncScales.forEach((function(r,a){var i=Number.MAX_SAFE_INTEGER,o=Number.MIN_SAFE_INTEGER,s=[];(0,x.S6)(r,(function(e){var t=n.getScale(e);o=(0,x.hj)(t.max)?Math.max(o,t.max):o,i=(0,x.hj)(t.min)?Math.min(i,t.min):i,(0,x.S6)(t.values,(function(e){s.includes(e)||s.push(e)}))})),(0,x.S6)(r,(function(r){var a=n.getScale(r);if(a.isContinuous)a.change({min:i,max:o,values:s});else if(a.isCategory){var l=a.range,u=n.getScaleMeta(r);s&&!(0,x.U2)(u,["scaleDef","range"])&&(l=Oi((0,x.b$)({},a,{values:s}),e,t)),a.change({values:s,range:l})}}))}))},e.prototype.cacheScale=function(e,t,n){var r=this.getScaleMeta(n);r&&r.scale.type===e.type?(!function(e,t){if("identity"!==e.type&&"identity"!==t.type){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(n[r]=t[r]);e.change(n)}}(r.scale,e),r.scaleDef=t):(r={key:n,scale:e,scaleDef:t},this.scales.set(n,r));var a=this.getSyncKey(r);if(r.syncKey=a,this.removeFromSyncScales(n),a){var i=this.syncScales.get(a);i||(i=[],this.syncScales.set(a,i)),i.push(n)}},e.prototype.getScale=function(e){var t=this.getScaleMeta(e);if(!t){var n=(0,x.Z$)(e.split("-")),r=this.syncScales.get(n);r&&r.length&&(t=this.getScaleMeta(r[0]))}return t&&t.scale},e.prototype.deleteScale=function(e){var t=this.getScaleMeta(e);if(t){var n=t.syncKey,r=this.syncScales.get(n);if(r&&r.length){var a=r.indexOf(e);-1!==a&&r.splice(a,1)}}this.scales.delete(e)},e.prototype.clear=function(){this.scales.clear(),this.syncScales.clear()},e.prototype.removeFromSyncScales=function(e){var t=this;this.syncScales.forEach((function(n,r){var a=n.indexOf(e);if(-1!==a)return n.splice(a,1),0===n.length&&t.syncScales.delete(r),!1}))},e.prototype.getSyncKey=function(e){var t=e.scale,n=e.scaleDef,r=t.field,a=(0,x.U2)(n,["sync"]);return!0===a?r:!1===a?void 0:a},e.prototype.getScaleMeta=function(e){return this.scales.get(e)},e}(),Cs=function(){function e(e,t,n,r){void 0===e&&(e=0),void 0===t&&(t=0),void 0===n&&(n=0),void 0===r&&(r=0),this.top=e,this.right=t,this.bottom=n,this.left=r}return e.instance=function(t,n,r,a){return void 0===t&&(t=0),void 0===n&&(n=0),void 0===r&&(r=0),void 0===a&&(a=0),new e(t,n,r,a)},e.prototype.max=function(e){var t=(0,y.CR)(e,4),n=t[0],r=t[1],a=t[2],i=t[3];return this.top=Math.max(this.top,n),this.right=Math.max(this.right,r),this.bottom=Math.max(this.bottom,a),this.left=Math.max(this.left,i),this},e.prototype.shrink=function(e){var t=(0,y.CR)(e,4),n=t[0],r=t[1],a=t[2],i=t[3];return this.top+=n,this.right+=r,this.bottom+=a,this.left+=i,this},e.prototype.inc=function(e,t){var n=e.width,r=e.height;switch(t){case m.TOP:case m.TOP_LEFT:case m.TOP_RIGHT:this.top+=r;break;case m.RIGHT:case m.RIGHT_TOP:case m.RIGHT_BOTTOM:this.right+=n;break;case m.BOTTOM:case m.BOTTOM_LEFT:case m.BOTTOM_RIGHT:this.bottom+=r;break;case m.LEFT:case m.LEFT_TOP:case m.LEFT_BOTTOM:this.left+=n}return this},e.prototype.getPadding=function(){return[this.top,this.right,this.bottom,this.left]},e.prototype.clone=function(){return new(e.bind.apply(e,(0,y.ev)([void 0],(0,y.CR)(this.getPadding()),!1)))},e}();function ks(e){var t=e.padding;if(!function(e){return!(0,x.hj)(e)&&!(0,x.kJ)(e)}(t))return new(Cs.bind.apply(Cs,(0,y.ev)([void 0],(0,y.CR)(gs(t)),!1)));var n=e.viewBBox,r=new Cs,a=[],i=[],o=[];return(0,x.S6)(e.getComponents(),(function(e){var t=e.type;t===g.AXIS?a.push(e):[g.LEGEND,g.SLIDER,g.SCROLLBAR].includes(t)?i.push(e):t!==g.GRID&&t!==g.TOOLTIP&&o.push(e)})),(0,x.S6)(a,(function(e){var t=e.component.getLayoutBBox(),a=new Si(t.x,t.y,t.width,t.height).exceed(n);r.max(a)})),(0,x.S6)(i,(function(e){var t=e.component,n=e.direction,a=t.getLayoutBBox(),i=t.get("padding"),o=new Si(a.x,a.y,a.width,a.height).expand(i);r.inc(o,n)})),(0,x.S6)(o,(function(e){var t=e.component,n=e.direction,a=t.getLayoutBBox(),i=new Si(a.x,a.y,a.width,a.height);r.inc(i,n)})),r}function Ms(e,t,n){var r=n.instance();t.forEach((function(e){e.autoPadding=r.max(e.autoPadding.getPadding())}))}var Ts=function(e){function t(t){var n=e.call(this,{visible:t.visible})||this;n.views=[],n.geometries=[],n.controllers=[],n.interactions={},n.limitInPlot=!1,n.options={data:[],animate:!0},n.usedControllers=Object.keys(ys),n.scalePool=new Es,n.layoutFunc=Ss,n.isPreMouseInPlot=!1,n.isDataChanged=!1,n.isCoordinateChanged=!1,n.createdScaleKeys=new Map,n.onCanvasEvent=function(e){var t=e.name;if(!t.includes(":")){var r=n.createViewEvent(e);n.doPlotEvent(r),n.emit(t,r)}},n.onDelegateEvents=function(e){var t=e.name;if(t.includes(":")){var r=n.createViewEvent(e);n.emit(t,r)}};var r=t.id,a=void 0===r?(0,x.EL)("view"):r,i=t.parent,o=t.canvas,s=t.backgroundGroup,l=t.middleGroup,u=t.foregroundGroup,c=t.region,d=void 0===c?{start:{x:0,y:0},end:{x:1,y:1}}:c,p=t.padding,h=t.appendPadding,f=t.theme,v=t.options,m=t.limitInPlot,g=t.syncViewPadding;return n.parent=i,n.canvas=o,n.backgroundGroup=s,n.middleGroup=l,n.foregroundGroup=u,n.region=d,n.padding=p,n.appendPadding=h,n.options=(0,y.pi)((0,y.pi)({},n.options),v),n.limitInPlot=m,n.id=a,n.syncViewPadding=g,n.themeObject=(0,x.Kn)(f)?(0,x.b$)({},os("default"),as(f)):os(f),n.init(),n}return(0,y.ZT)(t,e),t.prototype.setLayout=function(e){this.layoutFunc=e},t.prototype.init=function(){this.calculateViewBBox(),this.initEvents(),this.initComponentController(),this.initOptions()},t.prototype.render=function(e,t){void 0===e&&(e=!1),this.emit(I.BEFORE_RENDER,ws.fromData(this,I.BEFORE_RENDER,t)),this.paint(e),this.emit(I.AFTER_RENDER,ws.fromData(this,I.AFTER_RENDER,t)),!1===this.visible&&this.changeVisible(!1)},t.prototype.clear=function(){var e=this;this.emit(I.BEFORE_CLEAR),this.filteredData=[],this.coordinateInstance=void 0,this.isDataChanged=!1,this.isCoordinateChanged=!1;for(var t=this.geometries,n=0;n');L.appendChild(O);var R=D(L,s,a,i),N=new(A(d).Canvas)((0,y.pi)({container:O,pixelRatio:p,localRefresh:f,supportCSSTransform:I},R));return(n=e.call(this,{parent:null,canvas:N,backgroundGroup:N.addGroup({zIndex:C}),middleGroup:N.addGroup({zIndex:E}),foregroundGroup:N.addGroup({zIndex:S}),padding:l,appendPadding:u,visible:m,options:w,limitInPlot:k,theme:M,syncViewPadding:T})||this).onResize=(0,x.Ds)((function(){n.forceFit()}),300),n.ele=L,n.canvas=N,n.width=R.width,n.height=R.height,n.autoFit=s,n.localRefresh=f,n.renderer=d,n.wrapperElement=O,n.updateCanvasStyle(),n.bindAutoFit(),n.initDefaultInteractions(b),n}return(0,y.ZT)(t,e),t.prototype.initDefaultInteractions=function(e){var t=this;(0,x.S6)(e,(function(e){t.interaction(e)}))},t.prototype.aria=function(e){var t="aria-label";!1===e?this.ele.removeAttribute(t):this.ele.setAttribute(t,e.label)},t.prototype.changeSize=function(e,t){return this.width===e&&this.height===t||(this.emit(I.BEFORE_CHANGE_SIZE),this.width=e,this.height=t,this.canvas.changeSize(e,t),this.render(!0),this.emit(I.AFTER_CHANGE_SIZE)),this},t.prototype.clear=function(){e.prototype.clear.call(this),this.aria(!1)},t.prototype.destroy=function(){e.prototype.destroy.call(this),this.unbindAutoFit(),this.canvas.destroy(),function(e){var t=e.parentNode;t&&t.removeChild(e)}(this.wrapperElement),this.wrapperElement=null},t.prototype.changeVisible=function(t){return e.prototype.changeVisible.call(this,t),this.wrapperElement.style.display=t?"":"none",this},t.prototype.forceFit=function(){if(!this.destroyed){var e=D(this.ele,!0,this.width,this.height),t=e.width,n=e.height;this.changeSize(t,n)}},t.prototype.updateCanvasStyle=function(){(0,O.Z)(this.canvas.get("el"),{display:"inline-block",verticalAlign:"middle"})},t.prototype.bindAutoFit=function(){this.autoFit&&window.addEventListener("resize",this.onResize)},t.prototype.unbindAutoFit=function(){this.autoFit&&window.removeEventListener("resize",this.onResize)},t}(Ls),Os=Ps,Rs=function(){function e(e){this.visible=!0,this.components=[],this.view=e}return e.prototype.clear=function(e){(0,x.S6)(this.components,(function(e){e.component.destroy()})),this.components=[]},e.prototype.destroy=function(){this.clear()},e.prototype.getComponents=function(){return this.components},e.prototype.changeVisible=function(e){this.visible!==e&&(this.components.forEach((function(t){e?t.component.show():t.component.hide()})),this.visible=e)},e}();var Ds=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.isLocked=!1,t}return(0,y.ZT)(t,e),Object.defineProperty(t.prototype,"name",{get:function(){return"tooltip"},enumerable:!1,configurable:!0}),t.prototype.init=function(){},t.prototype.isVisible=function(){return!1!==this.view.getOptions().tooltip},t.prototype.render=function(){},t.prototype.showTooltip=function(e){if(this.point=e,this.isVisible()){var t=this.view,n=this.getTooltipItems(e);if(n.length){var r=this.getTitle(n),a={x:n[0].x,y:n[0].y};t.emit("tooltip:show",ws.fromData(t,"tooltip:show",(0,y.pi)({items:n,title:r},e)));var i=this.getTooltipCfg(),o=i.follow,s=i.showMarkers,l=i.showCrosshairs,u=i.showContent,c=i.marker,d=this.items,p=this.title;if((0,x.Xy)(p,r)&&(0,x.Xy)(d,n)?(this.tooltip&&o&&(this.tooltip.update(e),this.tooltip.show()),this.tooltipMarkersGroup&&this.tooltipMarkersGroup.show()):(t.emit("tooltip:change",ws.fromData(t,"tooltip:change",(0,y.pi)({items:n,title:r},e))),((0,x.mf)(u)?u(n):u)&&(this.tooltip||this.renderTooltip(),this.tooltip.update((0,x.CD)({},i,{items:this.getItemsAfterProcess(n),title:r},o?e:{})),this.tooltip.show()),s&&this.renderTooltipMarkers(n,c)),this.items=n,this.title=r,l){var h=(0,x.U2)(i,["crosshairs","follow"],!1);this.renderCrosshairs(h?e:a,i)}}else this.hideTooltip()}},t.prototype.hideTooltip=function(){if(this.getTooltipCfg().follow){var e=this.tooltipMarkersGroup;e&&e.hide();var t=this.xCrosshair,n=this.yCrosshair;t&&t.hide(),n&&n.hide();var r=this.tooltip;r&&r.hide(),this.view.emit("tooltip:hide",ws.fromData(this.view,"tooltip:hide",{})),this.point=null}else this.point=null},t.prototype.lockTooltip=function(){this.isLocked=!0,this.tooltip&&this.tooltip.setCapture(!0)},t.prototype.unlockTooltip=function(){this.isLocked=!1;var e=this.getTooltipCfg();this.tooltip&&this.tooltip.setCapture(e.capture)},t.prototype.isTooltipLocked=function(){return this.isLocked},t.prototype.clear=function(){var e=this,t=e.tooltip,n=e.xCrosshair,r=e.yCrosshair,a=e.tooltipMarkersGroup;t&&(t.hide(),t.clear()),n&&n.clear(),r&&r.clear(),a&&a.clear(),(null==t?void 0:t.get("customContent"))&&(this.tooltip.destroy(),this.tooltip=null),this.title=null,this.items=null},t.prototype.destroy=function(){this.tooltip&&this.tooltip.destroy(),this.xCrosshair&&this.xCrosshair.destroy(),this.yCrosshair&&this.yCrosshair.destroy(),this.guideGroup&&this.guideGroup.remove(!0),this.reset()},t.prototype.reset=function(){this.items=null,this.title=null,this.tooltipMarkersGroup=null,this.tooltipCrosshairsGroup=null,this.xCrosshair=null,this.yCrosshair=null,this.tooltip=null,this.guideGroup=null,this.isLocked=!1,this.point=null},t.prototype.changeVisible=function(e){if(this.visible!==e){var t=this,n=t.tooltip,r=t.tooltipMarkersGroup,a=t.xCrosshair,i=t.yCrosshair;e?(n&&n.show(),r&&r.show(),a&&a.show(),i&&i.show()):(n&&n.hide(),r&&r.hide(),a&&a.hide(),i&&i.hide()),this.visible=e}},t.prototype.getTooltipItems=function(e){var t,n,r,a,i,o,s=this.findItemsFromView(this.view,e);if(s.length){s=(0,x.xH)(s);try{for(var l=(0,y.XA)(s),u=l.next();!u.done;u=l.next()){var c=u.value;try{for(var d=(r=void 0,(0,y.XA)(c)),p=d.next();!p.done;p=d.next()){var h=p.value,f=h.mappingData,v=f.x,m=f.y;h.x=(0,x.kJ)(v)?v[v.length-1]:v,h.y=(0,x.kJ)(m)?m[m.length-1]:m}}catch(e){r={error:e}}finally{try{p&&!p.done&&(a=d.return)&&a.call(d)}finally{if(r)throw r.error}}}}catch(e){t={error:e}}finally{try{u&&!u.done&&(n=l.return)&&n.call(l)}finally{if(t)throw t.error}}if(!1===this.getTooltipCfg().shared&&s.length>1){var g=s[0],I=Math.abs(e.y-g[0].y);try{for(var _=(0,y.XA)(s),b=_.next();!b.done;b=_.next()){var w=b.value,S=Math.abs(e.y-w[0].y);S<=I&&(g=w,I=S)}}catch(e){i={error:e}}finally{try{b&&!b.done&&(o=_.return)&&o.call(_)}finally{if(i)throw i.error}}s=[g]}return function(e){for(var t=[],n=function(n){var r=e[n];(0,x.sE)(t,(function(e){return e.color===r.color&&e.name===r.name&&e.value===r.value&&e.title===r.title}))||t.push(r)},r=0;r'+r+"":r}})},t.prototype.getTitle=function(e){var t=e[0].title||e[0].name;return this.title=t,t},t.prototype.renderTooltip=function(){var e=this.view.getCanvas(),t={start:{x:0,y:0},end:{x:e.get("width"),y:e.get("height")}},n=this.getTooltipCfg(),r=new hi((0,y.pi)((0,y.pi)({parent:e.get("el").parentNode,region:t},n),{visible:!1,crosshairs:null}));r.init(),this.tooltip=r},t.prototype.renderTooltipMarkers=function(e,t){var n,r,a=this.getTooltipMarkersGroup(),i=this.view.getRootView(),o=i.limitInPlot;try{for(var s=(0,y.XA)(e),l=s.next();!l.done;l=s.next()){var u=l.value,c=u.x,d=u.y;if(o||(null==a?void 0:a.getClip())){var p=Mi(i.getCoordinate()),h=p.type,f=p.attrs;null==a||a.setClip({type:h,attrs:f})}else null==a||a.setClip(void 0);var v=this.view.getTheme(),m=(0,x.U2)(v,["components","tooltip","marker"],{}),g=(0,y.pi)((0,y.pi)({fill:u.color,symbol:"circle",shadowColor:u.color},(0,x.mf)(t)?(0,y.pi)((0,y.pi)({},m),t(u)):t),{x:c,y:d});a.addShape("marker",{attrs:g})}}catch(e){n={error:e}}finally{try{l&&!l.done&&(r=s.return)&&r.call(s)}finally{if(n)throw n.error}}},t.prototype.renderCrosshairs=function(e,t){var n=(0,x.U2)(t,["crosshairs","type"],"x");"x"===n?(this.yCrosshair&&this.yCrosshair.hide(),this.renderXCrosshairs(e,t)):"y"===n?(this.xCrosshair&&this.xCrosshair.hide(),this.renderYCrosshairs(e,t)):"xy"===n&&(this.renderXCrosshairs(e,t),this.renderYCrosshairs(e,t))},t.prototype.renderXCrosshairs=function(e,t){var n,r,a=this.getViewWithGeometry(this.view).getCoordinate();if(a.isRect)a.isTransposed?(n={x:a.start.x,y:e.y},r={x:a.end.x,y:e.y}):(n={x:e.x,y:a.end.y},r={x:e.x,y:a.start.y});else{var i=ki(a,e),o=a.getCenter(),s=a.getRadius();r=mi(o.x,o.y,s,i),n=o}var l=(0,x.b$)({start:n,end:r,container:this.getTooltipCrosshairsGroup()},(0,x.U2)(t,"crosshairs",{}),this.getCrosshairsText("x",e,t));delete l.type;var u=this.xCrosshair;u?u.update(l):(u=new ra(l)).init(),u.render(),u.show(),this.xCrosshair=u},t.prototype.renderYCrosshairs=function(e,t){var n,r,a=this.getViewWithGeometry(this.view).getCoordinate();if(a.isRect){var i=void 0,o=void 0;a.isTransposed?(i={x:e.x,y:a.end.y},o={x:e.x,y:a.start.y}):(i={x:a.start.x,y:e.y},o={x:a.end.x,y:e.y}),n={start:i,end:o},r="Line"}else n={center:a.getCenter(),radius:Ci(a,e),startAngle:a.startAngle,endAngle:a.endAngle},r="Circle";delete(n=(0,x.b$)({container:this.getTooltipCrosshairsGroup()},n,(0,x.U2)(t,"crosshairs",{}),this.getCrosshairsText("y",e,t))).type;var s=this.yCrosshair;s?a.isRect&&"circle"===s.get("type")||!a.isRect&&"line"===s.get("type")?(s=new u[r](n)).init():s.update(n):(s=new u[r](n)).init(),s.render(),s.show(),this.yCrosshair=s},t.prototype.getCrosshairsText=function(e,t,n){var r=(0,x.U2)(n,["crosshairs","text"]),a=(0,x.U2)(n,["crosshairs","follow"]),i=this.items;if(r){var o=this.getViewWithGeometry(this.view),s=i[0],l=o.getXScale(),u=o.getYScales()[0],c=void 0,d=void 0;if(a){var p=this.view.getCoordinate().invert(t);c=l.invert(p.x),d=u.invert(p.y)}else c=s.data[l.field],d=s.data[u.field];var h="x"===e?c:d;return(0,x.mf)(r)?r=r(e,h,i,t):r.content=h,{text:r}}},t.prototype.getGuideGroup=function(){if(!this.guideGroup){var e=this.view.foregroundGroup;this.guideGroup=e.addGroup({name:"tooltipGuide",capture:!1})}return this.guideGroup},t.prototype.getTooltipMarkersGroup=function(){var e=this.tooltipMarkersGroup;return e&&!e.destroyed?(e.clear(),e.show()):((e=this.getGuideGroup().addGroup({name:"tooltipMarkersGroup"})).toFront(),this.tooltipMarkersGroup=e),e},t.prototype.getTooltipCrosshairsGroup=function(){var e=this.tooltipCrosshairsGroup;return e||((e=this.getGuideGroup().addGroup({name:"tooltipCrosshairsGroup",capture:!1})).toBack(),this.tooltipCrosshairsGroup=e),e},t.prototype.findItemsFromView=function(e,t){var n,r;if(!1===e.getOptions().tooltip)return[];var a=ms(e,t,this.getTooltipCfg());try{for(var i=(0,y.XA)(e.views),o=i.next();!o.done;o=i.next()){var s=o.value;a=a.concat(this.findItemsFromView(s,t))}}catch(e){n={error:e}}finally{try{o&&!o.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}return a},t.prototype.getViewWithGeometry=function(e){var t=this;return e.geometries.length?e:(0,x.sE)(e.views,(function(e){return t.getViewWithGeometry(e)}))},t.prototype.getItemsAfterProcess=function(e){var t=this.getTooltipCfg().customItems;return(t||function(e){return e})(e)},t}(Rs),Ns=Ds,zs={};function Fs(e){return zs[e.toLowerCase()]}function Bs(e,t){zs[e.toLowerCase()]=t}var js={appear:{duration:450,easing:"easeQuadOut"},update:{duration:400,easing:"easeQuadInOut"},enter:{duration:400,easing:"easeQuadInOut"},leave:{duration:350,easing:"easeQuadIn"}},Zs={interval:function(e){return{enter:{animation:e.isRect?e.isTransposed?"scale-in-x":"scale-in-y":"fade-in"},update:{animation:e.isPolar&&e.isTransposed?"sector-path-update":null},leave:{animation:"fade-out"}}},line:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},path:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},point:{appear:{animation:"zoom-in"},enter:{animation:"zoom-in"},leave:{animation:"zoom-out"}},area:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},polygon:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},schema:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},edge:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},label:{appear:{animation:"fade-in",delay:450},enter:{animation:"fade-in"},update:{animation:"position-update"},leave:{animation:"fade-out"}}},Us={line:function(){return{animation:"wave-in"}},area:function(){return{animation:"wave-in"}},path:function(){return{animation:"fade-in"}},interval:function(e){var t;return e.isRect?t=e.isTransposed?"grow-in-x":"grow-in-y":(t="grow-in-xy",e.isPolar&&e.isTransposed&&(t="wave-in")),{animation:t}},schema:function(e){return{animation:e.isRect?e.isTransposed?"grow-in-x":"grow-in-y":"grow-in-xy"}},polygon:function(){return{animation:"fade-in",duration:500}},edge:function(){return{animation:"fade-in"}}};function Vs(e,t,n){var r=Zs[e];return r&&((0,x.mf)(r)&&(r=r(t)),r=(0,x.b$)({},js,r),n)?r[n]:r}function Hs(e,t,n){var r=(0,x.U2)(e.get("origin"),"data",M),a=t.animation,i=function(e,t){return{delay:(0,x.mf)(e.delay)?e.delay(t):e.delay,easing:(0,x.mf)(e.easing)?e.easing(t):e.easing,duration:(0,x.mf)(e.duration)?e.duration(t):e.duration,callback:e.callback,repeat:e.repeat}}(t,r);if(a){var o=Fs(a);o&&o(e,i,n)}else e.animate(n.toAttrs,i)}var Gs="element-background",qs=function(e){function t(t){var n=e.call(this,t)||this;n.labelShape=[],n.states=[];var r=t.shapeFactory,a=t.container,i=t.offscreenGroup,o=t.elementIndex,s=t.visible,l=void 0===s||s;return n.shapeFactory=r,n.container=a,n.offscreenGroup=i,n.visible=l,n.elementIndex=o,n}return(0,y.ZT)(t,e),t.prototype.draw=function(e,t){void 0===t&&(t=!1),this.model=e,this.data=e.data,this.shapeType=this.getShapeType(e),this.drawShape(e,t),!1===this.visible&&this.changeVisible(!1)},t.prototype.update=function(e){var t=this.shapeFactory,n=this.shape;if(n){this.model=e,this.data=e.data,this.shapeType=this.getShapeType(e),this.setShapeInfo(n,e);var r=this.getOffscreenGroup(),a=t.drawShape(this.shapeType,e,r);a.cfg.data=this.data,a.cfg.origin=e,a.cfg.element=this,this.syncShapeStyle(n,a,this.getStates(),this.getAnimateCfg("update"))}},t.prototype.destroy=function(){var t=this.shapeFactory,n=this.shape;if(n){var r=this.getAnimateCfg("leave");r?Hs(n,r,{coordinate:t.coordinate,toAttrs:(0,y.pi)({},n.attr())}):n.remove(!0)}this.states=[],this.shapeFactory=void 0,this.container=void 0,this.shape=void 0,this.animate=void 0,this.geometry=void 0,this.labelShape=[],this.model=void 0,this.data=void 0,this.offscreenGroup=void 0,this.statesStyle=void 0,e.prototype.destroy.call(this)},t.prototype.changeVisible=function(t){e.prototype.changeVisible.call(this,t),t?(this.shape&&this.shape.show(),this.labelShape&&this.labelShape.forEach((function(e){e.show()}))):(this.shape&&this.shape.hide(),this.labelShape&&this.labelShape.forEach((function(e){e.hide()})))},t.prototype.setState=function(e,t){var n=this,r=n.states,a=n.shapeFactory,i=n.model,o=n.shape,s=n.shapeType,l=r.indexOf(e);if(t){if(l>-1)return;r.push(e),"active"!==e&&"selected"!==e||null==o||o.toFront()}else{if(-1===l)return;if(r.splice(l,1),"active"===e||"selected"===e){var u=this.geometry,c=u.sortZIndex,d=u.zIndexReversed?this.geometry.elements.length-this.elementIndex:this.elementIndex;c?o.setZIndex(d):o.set("zIndex",d)}}var p=a.drawShape(s,i,this.getOffscreenGroup());r.length?this.syncShapeStyle(o,p,r,null):this.syncShapeStyle(o,p,["reset"],null),p.remove(!0);var h={state:e,stateStatus:t,element:this,target:this.container};this.container.emit("statechange",h),kn(this.shape,"statechange",h)},t.prototype.clearStates=function(){var e=this,t=this.states;(0,x.S6)(t,(function(t){e.setState(t,!1)})),this.states=[]},t.prototype.hasState=function(e){return this.states.includes(e)},t.prototype.getStates=function(){return this.states},t.prototype.getData=function(){return this.data},t.prototype.getModel=function(){return this.model},t.prototype.getBBox=function(){var e=this.shape,t=this.labelShape,n={x:0,y:0,minX:0,minY:0,maxX:0,maxY:0,width:0,height:0};return e&&(n=e.getCanvasBBox()),t&&t.forEach((function(e){var t=e.getCanvasBBox();n.x=Math.min(t.x,n.x),n.y=Math.min(t.y,n.y),n.minX=Math.min(t.minX,n.minX),n.minY=Math.min(t.minY,n.minY),n.maxX=Math.max(t.maxX,n.maxX),n.maxY=Math.max(t.maxY,n.maxY)})),n.width=n.maxX-n.minX,n.height=n.maxY-n.minY,n},t.prototype.getStatesStyle=function(){if(!this.statesStyle){var e=this,t=e.shapeType,n=e.geometry,r=e.shapeFactory,a=n.stateOption,i=r.defaultShapeType,o=r.theme[t]||r.theme[i];this.statesStyle=(0,x.b$)({},o,a)}return this.statesStyle},t.prototype.getStateStyle=function(e,t){var n=this.getStatesStyle(),r=(0,x.U2)(n,[e,"style"],{}),a=r[t]||r;return(0,x.mf)(a)?a(this):a},t.prototype.getAnimateCfg=function(e){var t=this,n=this.animate;if(n){var r=n[e];return r?(0,y.pi)((0,y.pi)({},r),{callback:function(){var e;(0,x.mf)(r.callback)&&r.callback(),null===(e=t.geometry)||void 0===e||e.emit(_.AFTER_DRAW_ANIMATE)}}):r}return null},t.prototype.drawShape=function(e,t){var n;void 0===t&&(t=!1);var r=this,a=r.shapeFactory,i=r.container,o=r.shapeType;if(this.shape=a.drawShape(o,e,i),this.shape){this.setShapeInfo(this.shape,e);var s=this.shape.cfg.name;s?(0,x.HD)(s)&&(this.shape.cfg.name=["element",s]):this.shape.cfg.name=["element",this.shapeFactory.geometryType];var l=t?"enter":"appear",u=this.getAnimateCfg(l);u&&(null===(n=this.geometry)||void 0===n||n.emit(_.BEFORE_DRAW_ANIMATE),Hs(this.shape,u,{coordinate:a.coordinate,toAttrs:(0,y.pi)({},this.shape.attr())}))}},t.prototype.getOffscreenGroup=function(){if(!this.offscreenGroup){var e=this.container.getGroupBase();this.offscreenGroup=new e({})}return this.offscreenGroup},t.prototype.setShapeInfo=function(e,t){var n=this;(e.cfg.origin=t,e.cfg.element=this,e.isGroup())&&e.get("children").forEach((function(e){n.setShapeInfo(e,t)}))},t.prototype.syncShapeStyle=function(e,t,n,r,a){var i,o=this;if(void 0===n&&(n=[]),void 0===a&&(a=0),e&&t){var s=e.get("clipShape"),l=t.get("clipShape");if(this.syncShapeStyle(s,l,n,r),e.isGroup())for(var u=e.get("children"),c=t.get("children"),d=0;d=0?t:n<=0?n:0},t.prototype.createAttrOption=function(e,t,n){if((0,x.UM)(t)||(0,x.Kn)(t))(0,x.Kn)(t)&&(0,x.Xy)(Object.keys(t),["values"])?(0,x.t8)(this.attributeOption,e,{fields:t.values}):(0,x.t8)(this.attributeOption,e,t);else{var r={};(0,x.hj)(t)?r.values=[t]:r.fields=sl(t),n&&((0,x.mf)(n)?r.callback=n:r.values=n),(0,x.t8)(this.attributeOption,e,r)}},t.prototype.initAttributes=function(){var e=this,t=this,n=t.attributes,r=t.attributeOption,a=t.theme,i=t.shapeType;this.groupScales=[];var o={},s=function(t){if(r.hasOwnProperty(t)){var s=r[t];if(!s)return{value:void 0};var l=(0,y.pi)({},s),u=l.callback,c=l.values,d=l.fields,p=(void 0===d?[]:d).map((function(n){var r=e.scales[n];!o[n]&&k.includes(t)&&("cat"===Ai(r,(0,x.U2)(e.scaleDefs,n),t,e.type)&&(e.groupScales.push(r),o[n]=!0));return r}));l.scales=p,"position"!==t&&1===p.length&&"identity"===p[0].type?l.values=p[0].values:u||c||("size"===t?l.values=a.sizes:"shape"===t?l.values=a.shapes[i]||[]:"color"===t&&(p.length?l.values=p[0].values.length<=10?a.colors10:a.colors20:l.values=a.colors10));var h=dn(t);n[t]=new h(l)}};for(var l in r){var u=s(l);if("object"==typeof u)return u.value}},t.prototype.processData=function(e){var t,n;this.hasSorted=!1;for(var r=this.getAttribute("position").scales.filter((function(e){return e.isCategory})),a=this.groupData(e),i=[],o=0,s=a.length;oi&&(i=u)}var c=this.scaleDefs,d={};ae.max&&!(0,x.U2)(c,[r,"max"])&&(d.max=i),e.change(d)},t.prototype.beforeMapping=function(e){var t=e;if(this.sortable&&this.sort(t),this.generatePoints)for(var n=0,r=t.length;n1)for(var c=0;c0}))}function gl(e,t,n){var r=n.data,a=n.origin,i=n.animateCfg,o=n.coordinate,s=(0,x.U2)(i,"update");e.set("data",r),e.set("origin",a),e.set("animateCfg",i),e.set("coordinate",o),e.set("visible",t.get("visible")),(e.getChildren()||[]).forEach((function(l,u){var c=t.getChildByIndex(u);if(c){l.set("data",r),l.set("origin",a),l.set("animateCfg",i),l.set("coordinate",o);var d=Ii(l,c);s?Hs(l,s,{toAttrs:d,coordinate:o}):l.attr(d),c.isGroup()&&gl(l,c,n)}else e.removeChild(l),l.remove(!0)})),(0,x.S6)(t.getChildren(),(function(t,n){n>=e.getCount()&&(t.destroyed||e.add(t))}))}var yl=function(){function e(e){this.shapesMap={};var t=e.layout,n=e.container;this.layout=t,this.container=n}return e.prototype.render=function(e,t,n){return void 0===n&&(n=!1),(0,y.mG)(this,void 0,void 0,(function(){var r,a,i,o,s,l,u,c,d=this;return(0,y.Jh)(this,(function(p){switch(p.label){case 0:if(r={},a=this.createOffscreenGroup(),!e.length)return[3,2];try{for(i=(0,y.XA)(e),o=i.next();!o.done;o=i.next())(s=o.value)&&(r[s.id]=this.renderLabel(s,a))}catch(e){u={error:e}}finally{try{o&&!o.done&&(c=i.return)&&c.call(i)}finally{if(u)throw u.error}}return[4,this.doLayout(e,t,r)];case 1:p.sent(),this.renderLabelLine(e,r),this.renderLabelBackground(e,r),this.adjustLabel(e,r),p.label=2;case 2:return l=this.shapesMap,(0,x.S6)(r,(function(e,t){if(e.destroyed)delete r[t];else{if(l[t]){var a=e.get("data"),i=e.get("origin"),o=e.get("coordinate"),s=e.get("animateCfg"),u=l[t];gl(u,r[t],{data:a,origin:i,animateCfg:s,coordinate:o}),r[t]=u}else{if(d.container.destroyed)return;d.container.add(e);var c=(0,x.U2)(e.get("animateCfg"),n?"enter":"appear");c&&Hs(e,c,{toAttrs:(0,y.pi)({},e.attr()),coordinate:e.get("coordinate")})}delete l[t]}})),(0,x.S6)(l,(function(e){var t=(0,x.U2)(e.get("animateCfg"),"leave");t?Hs(e,t,{toAttrs:null,coordinate:e.get("coordinate")}):e.remove(!0)})),this.shapesMap=r,a.destroy(),[2]}}))}))},e.prototype.clear=function(){this.container.clear(),this.shapesMap={}},e.prototype.destroy=function(){this.container.destroy(),this.shapesMap=null},e.prototype.renderLabel=function(e,t){var n,r=e.id,a=e.elementId,i=e.data,o=e.mappingData,s=e.coordinate,l=e.animate,u=e.content,c={id:r,elementId:a,capture:e.capture,data:i,origin:(0,y.pi)((0,y.pi)({},o),{data:o[M]}),coordinate:s},d=t.addGroup((0,y.pi)({name:"label",animateCfg:!1!==this.animate&&null!==l&&!1!==l&&(0,x.b$)({},this.animate,l)},c));if(u.isGroup&&u.isGroup()||u.isShape&&u.isShape()){var p=u.getCanvasBBox(),h=p.width,f=p.height,v=(0,x.U2)(e,"textAlign","left"),m=e.x;"center"===v?m-=h/2:"right"!==v&&"end"!==v||(m-=h),pl(u,m,e.y-f/2),n=u,d.add(u)}else{var g=(0,x.U2)(e,["style","fill"]);n=d.addShape("text",(0,y.pi)({attrs:(0,y.pi)((0,y.pi)({x:e.x,y:e.y,textAlign:e.textAlign,textBaseline:(0,x.U2)(e,"textBaseline","middle"),text:e.content},e.style),{fill:(0,x.Ft)(g)?e.color:g})},c))}return e.rotate&&hl(n,e.rotate),d},e.prototype.doLayout=function(e,t,n){return(0,y.mG)(this,void 0,void 0,(function(){var r,a=this;return(0,y.Jh)(this,(function(i){switch(i.label){case 0:return this.layout?(r=(0,x.kJ)(this.layout)?this.layout:[this.layout],[4,Promise.all(r.map((function(r){var i=$s((0,x.U2)(r,"type",""));if(i){var o=[],s=[];return(0,x.S6)(n,(function(e,n){o.push(e),s.push(t[e.get("elementId")])})),i(e,o,s,a.region,r.cfg)}})))]):[3,2];case 1:i.sent(),i.label=2;case 2:return[2]}}))}))},e.prototype.renderLabelLine=function(e,t){(0,x.S6)(e,(function(e){var n=(0,x.U2)(e,"coordinate");if(e&&n){var r=n.getCenter(),a=n.getRadius();if(e.labelLine){var i=(0,x.U2)(e,"labelLine",{}),o=e.id,s=i.path;if(!s){var l=mi(r.x,r.y,a,e.angle);s=[["M",l.x,l.y],["L",e.x,e.y]]}var u=t[o];u.destroyed||u.addShape("path",{capture:!1,attrs:(0,y.pi)({path:s,stroke:e.color?e.color:(0,x.U2)(e,["style","fill"],"#000"),fill:null},i.style),id:o,origin:e.mappingData,data:e.data,coordinate:e.coordinate})}}}))},e.prototype.renderLabelBackground=function(e,t){(0,x.S6)(e,(function(e){var n=(0,x.U2)(e,"coordinate"),r=(0,x.U2)(e,"background");if(r&&n){var a=e.id,i=t[a];if(!i.destroyed){var o=i.getChildren()[0];if(o){var s=vl(i,e,r.padding),l=s.rotation,u=(0,y._T)(s,["rotation"]),c=i.addShape("rect",{attrs:(0,y.pi)((0,y.pi)({},u),r.style||{}),id:a,origin:e.mappingData,data:e.data,coordinate:e.coordinate});if(c.setZIndex(-1),l){var d=o.getMatrix();c.setMatrix(d)}}}}}))},e.prototype.createOffscreenGroup=function(){return new(this.container.getGroupBase())({})},e.prototype.adjustLabel=function(e,t){(0,x.S6)(e,(function(e){if(e){var n=e.id,r=t[n];if(!r.destroyed){var a=r.findAll((function(e){return"path"!==e.get("type")}));(0,x.S6)(a,(function(t){t&&(e.offsetX&&t.attr("x",t.attr("x")+e.offsetX),e.offsetY&&t.attr("y",t.attr("y")+e.offsetY))}))}}}))},e}(),xl=yl;function Il(e){var t=0;return(0,x.S6)(e,(function(e){t+=e})),t/e.length}var _l=function(){function e(e){this.geometry=e}return e.prototype.getLabelItems=function(e){var t=this,n=[],r=this.getLabelCfgs(e);return(0,x.S6)(e,(function(e,a){var i=r[a];if(!i||(0,x.UM)(e.x)||(0,x.UM)(e.y))n.push(null);else{var o=(0,x.kJ)(i.content)?i.content:[i.content];i.content=o;var s=o.length;(0,x.S6)(o,(function(r,a){if((0,x.UM)(r)||""===r)n.push(null);else{var o=(0,y.pi)((0,y.pi)({},i),t.getLabelPoint(i,e,a));o.textAlign||(o.textAlign=t.getLabelAlign(o,a,s)),o.offset<=0&&(o.labelLine=null),n.push(o)}}))}})),n},e.prototype.render=function(e,t){return void 0===t&&(t=!1),(0,y.mG)(this,void 0,void 0,(function(){var n,r,a;return(0,y.Jh)(this,(function(i){switch(i.label){case 0:return n=this.getLabelItems(e),r=this.getLabelsRenderer(),a=this.getGeometryShapes(),[4,r.render(n,a,t)];case 1:return i.sent(),[2]}}))}))},e.prototype.clear=function(){var e=this.labelsRenderer;e&&e.clear()},e.prototype.destroy=function(){var e=this.labelsRenderer;e&&e.destroy(),this.labelsRenderer=null},e.prototype.getCoordinate=function(){return this.geometry.coordinate},e.prototype.getDefaultLabelCfg=function(e,t){var n=this.geometry,r=n.type,a=n.theme;return"polygon"===r||"interval"===r&&"middle"===t||e<0&&!["line","point","path"].includes(r)?(0,x.U2)(a,"innerLabels",{}):(0,x.U2)(a,"labels",{})},e.prototype.getThemedLabelCfg=function(e){var t=this.geometry,n=this.getDefaultLabelCfg(),r=t.type,a=t.theme;return"polygon"===r||e.offset<0&&!["line","point","path"].includes(r)?(0,x.b$)({},n,a.innerLabels,e):(0,x.b$)({},n,a.labels,e)},e.prototype.setLabelPosition=function(e,t,n,r){},e.prototype.getLabelOffset=function(e){var t=this.getCoordinate(),n=this.getOffsetVector(e);return t.isTransposed?n[0]:n[1]},e.prototype.getLabelOffsetPoint=function(e,t,n){var r=e.offset,a=this.getCoordinate().isTransposed,i=a?"x":"y",o=a?1:-1,s={x:0,y:0};return s[i]=t>0||1===n?r*o:r*o*-1,s},e.prototype.getLabelPoint=function(e,t,n){var r=this.getCoordinate(),a=e.content.length;function i(t,n,r){void 0===r&&(r=!1);var a=t;return(0,x.kJ)(a)&&(a=1===e.content.length?r?Il(a):a.length<=2?a[t.length-1]:Il(a):a[n]),a}var o={content:e.content[n],x:0,y:0,start:{x:0,y:0},color:"#fff"},s=(0,x.kJ)(t.shape)?t.shape[0]:t.shape,l="funnel"===s||"pyramid"===s;if("polygon"===this.geometry.type){var u=function(e,t){if((0,x.hj)(e)&&(0,x.hj)(t))return[e,t];if(fi(e)||fi(t))return[vi(e),vi(t)];for(var n,r,a=-1,i=0,o=0,s=e.length-1,l=0;++a1&&0===t&&("right"===r?r="left":"left"===r&&(r="right"))}return r},e.prototype.getLabelId=function(e){var t=this.geometry,n=t.type,r=t.getXScale(),a=t.getYScale(),i=e[M],o=t.getElementId(e);return"line"===n||"area"===n?o+=" ".concat(i[r.field]):"path"===n&&(o+=" ".concat(i[r.field],"-").concat(i[a.field])),o},e.prototype.getLabelsRenderer=function(){var e=this.geometry,t=e.labelsContainer,n=e.labelOption,r=e.canvasRegion,a=e.animateOption,i=this.geometry.coordinate,o=this.labelsRenderer;return o||(o=new xl({container:t,layout:(0,x.U2)(n,["cfg","layout"],{type:this.defaultLayout})}),this.labelsRenderer=o),o.region=r,o.animate=!!a&&Vs("label",i),o},e.prototype.getLabelCfgs=function(e){var t=this,n=this.geometry,r=n.labelOption,a=n.scales,i=n.coordinate,o=r,s=o.fields,l=o.callback,u=o.cfg,c=s.map((function(e){return a[e]})),d=[];return(0,x.S6)(e,(function(e,n){var r,a=e[M],o=t.getLabelText(a,c);if(l){var p=s.map((function(e){return a[e]}));if(r=l.apply(void 0,(0,y.ev)([],(0,y.CR)(p),!1)),(0,x.UM)(r))return void d.push(null)}var h=(0,y.pi)((0,y.pi)({id:t.getLabelId(e),elementId:t.geometry.getElementId(e),data:a,mappingData:e,coordinate:i},u),r);(0,x.mf)(h.position)&&(h.position=h.position(a,e,n));var f=t.getLabelOffset(h.offset||0),v=t.getDefaultLabelCfg(f,h.position);(h=(0,x.b$)({},v,h)).offset=t.getLabelOffset(h.offset||0);var m=h.content;(0,x.mf)(m)?h.content=m(a,e,n):(0,x.o8)(m)&&(h.content=o[0]),d.push(h)})),d},e.prototype.getLabelText=function(e,t){var n=[];return(0,x.S6)(t,(function(t){var r=e[t.field];r=(0,x.kJ)(r)?r.map((function(e){return t.getText(e)})):t.getText(r),(0,x.UM)(r)||""===r?n.push(null):n.push(r)})),n},e.prototype.getOffsetVector=function(e){void 0===e&&(e=0);var t=this.getCoordinate(),n=0;return(0,x.hj)(e)&&(n=e),t.isTransposed?t.applyMatrix(n,0):t.applyMatrix(0,n)},e.prototype.getGeometryShapes=function(){var e=this.geometry,t={};return(0,x.S6)(e.elementsMap,(function(e,n){t[n]=e.shape})),(0,x.S6)(e.getOffscreenGroup().getChildren(),(function(n){var r=e.getElementId(n.get("origin").mappingData);t[r]=n})),t},e}(),bl=_l;function wl(e,t,n){if(!e)return n;var r;if(e.callback&&e.callback.length>1){var a=Array(e.callback.length-1).fill("");r=e.mapping.apply(e,(0,y.ev)([t],(0,y.CR)(a),!1)).join("")}else r=e.mapping(t).join("");return r||n}var Sl={hexagon:function(e,t,n){var r=n/2*Math.sqrt(3);return[["M",e,t-n],["L",e+r,t-n/2],["L",e+r,t+n/2],["L",e,t+n],["L",e-r,t+n/2],["L",e-r,t-n/2],["Z"]]},bowtie:function(e,t,n){var r=n-1.5;return[["M",e-n,t-r],["L",e+n,t+r],["L",e+n,t-r],["L",e-n,t+r],["Z"]]},cross:function(e,t,n){return[["M",e-n,t-n],["L",e+n,t+n],["M",e+n,t-n],["L",e-n,t+n]]},tick:function(e,t,n){return[["M",e-n/2,t-n],["L",e+n/2,t-n],["M",e,t-n],["L",e,t+n],["M",e-n/2,t+n],["L",e+n/2,t+n]]},plus:function(e,t,n){return[["M",e-n,t],["L",e+n,t],["M",e,t-n],["L",e,t+n]]},hyphen:function(e,t,n){return[["M",e-n,t],["L",e+n,t]]},line:function(e,t,n){return[["M",e,t-n],["L",e,t+n]]}},El=["line","cross","tick","plus","hyphen"];function Cl(e){var t=e.symbol;(0,x.HD)(t)&&Sl[t]&&(e.symbol=Sl[t])}function kl(e){return e.startsWith(m.LEFT)||e.startsWith(m.RIGHT)?"vertical":"horizontal"}function Ml(e,t,n,r,a){var i=n.getScale(n.type);if(i.isCategory){var o=i.field,s=t.getAttribute("color"),l=t.getAttribute("shape"),u=e.getTheme().defaultColor,c=t.coordinate.isPolar;return i.getTicks().map((function(n,d){var p,h=n.text,f=n.value,v=h,m=i.invert(f),g=0===e.filterFieldData(o,[(p={},p[o]=m,p)]).length;(0,x.S6)(e.views,(function(e){var t;e.filterFieldData(o,[(t={},t[o]=m,t)]).length||(g=!0)}));var I,_,b=wl(s,m,u),w=wl(l,m,"point"),S=t.getShapeMarker(w,{color:b,isInPolar:c}),E=a;return(0,x.mf)(E)&&(E=E(v,d,(0,y.pi)({name:v,value:m},(0,x.b$)({},r,S)))),function(e,t){var n=e.symbol;if((0,x.HD)(n)&&-1!==El.indexOf(n)){var r=(0,x.U2)(e,"style",{}),a=(0,x.U2)(r,"lineWidth",1),i=r.stroke||r.fill||t;e.style=(0,x.b$)({},e.style,{lineWidth:a,stroke:i,fill:null})}}(S=(0,x.b$)({},r,S,bi((0,y.pi)({},E),["style"])),b),E&&E.style&&(S.style=(I=S.style,_=E.style,(0,x.mf)(_)?_(I):(0,x.b$)({},I,_))),Cl(S),{id:m,name:v,value:m,marker:S,unchecked:g}}))}return[]}function Tl(e,t){var n=(0,x.U2)(e,["components","legend"],{});return(0,x.b$)({},(0,x.U2)(n,["common"],{}),(0,x.b$)({},(0,x.U2)(n,[t],{})))}function Al(e){return!e&&(null==e||isNaN(e))}function Ll(e){if((0,x.kJ)(e))return Al(e[1].y);var t=e.y;return(0,x.kJ)(t)?Al(t[0]):Al(t)}function Pl(e,t,n){if(void 0===t&&(t=!1),void 0===n&&(n=!0),!e.length||1===e.length&&!n)return[];if(t){for(var r=[],a=0,i=e.length;a=e&&a<=e+n&&i>=t&&i<=t+r}function iu(e,t){return!(t.minX>e.maxX||t.maxXe.maxY||t.maxY=0&&o<.5*Math.PI?(r={x:l.minX,y:l.minY},a={x:l.maxX,y:l.maxY}):.5*Math.PI<=o&&o1&&(n*=Math.sqrt(h),r*=Math.sqrt(h));var f=n*n*(p*p)+r*r*(d*d),v=f?Math.sqrt((n*n*(r*r)-f)/f):1;i===o&&(v*=-1),isNaN(v)&&(v=0);var m=r?v*n*p/r:0,g=n?v*-r*d/n:0,y=(s+u)/2+Math.cos(a)*m-Math.sin(a)*g,I=(l+c)/2+Math.sin(a)*m+Math.cos(a)*g,_=[(d-m)/n,(p-g)/r],b=[(-1*d-m)/n,(-1*p-g)/r],w=vu([1,0],_),S=vu(_,b);return fu(_,b)<=-1&&(S=Math.PI),fu(_,b)>=1&&(S=0),0===o&&S>0&&(S-=2*Math.PI),1===o&&S<0&&(S+=2*Math.PI),{cx:y,cy:I,rx:ou(e,[u,c])?0:n,ry:ou(e,[u,c])?0:r,startAngle:w,endAngle:w+S,xRotation:a,arcFlag:i,sweepFlag:o}}var gu=Math.sin,yu=Math.cos,xu=Math.atan2,Iu=Math.PI;function _u(e,t,n,r,a,i,o){var s=t.stroke,l=t.lineWidth,u=xu(r-i,n-a),c=new dc({type:"path",canvas:e.get("canvas"),isArrowShape:!0,attrs:{path:"M"+10*yu(Iu/6)+","+10*gu(Iu/6)+" L0,0 L"+10*yu(Iu/6)+",-"+10*gu(Iu/6),stroke:s,lineWidth:l}});c.translate(a,i),c.rotateAtPoint(a,i,u),e.set(o?"startArrowShape":"endArrowShape",c)}function bu(e,t,n,r,a,i,o){var s=t.startArrow,l=t.endArrow,u=t.stroke,c=t.lineWidth,d=o?s:l,p=d.d,h=d.fill,f=d.stroke,v=d.lineWidth,m=(0,y._T)(d,["d","fill","stroke","lineWidth"]),g=xu(r-i,n-a);p&&(a-=yu(g)*p,i-=gu(g)*p);var x=new dc({type:"path",canvas:e.get("canvas"),isArrowShape:!0,attrs:(0,y.pi)((0,y.pi)({},m),{stroke:f||u,lineWidth:v||c,fill:h})});x.translate(a,i),x.rotateAtPoint(a,i,g),e.set(o?"startArrowShape":"endArrowShape",x)}function wu(e,t,n,r,a){var i=xu(r-t,n-e);return{dx:yu(i)*a,dy:gu(i)*a}}function Su(e,t,n,r,a,i){"object"==typeof t.startArrow?bu(e,t,n,r,a,i,!0):t.startArrow?_u(e,t,n,r,a,i,!0):e.set("startArrowShape",null)}function Eu(e,t,n,r,a,i){"object"==typeof t.endArrow?bu(e,t,n,r,a,i,!1):t.endArrow?_u(e,t,n,r,a,i,!1):e.set("startArrowShape",null)}var Cu={fill:"fillStyle",stroke:"strokeStyle",opacity:"globalAlpha"};function ku(e,t){var n=t.attr();for(var r in n){var a=n[r],i=Cu[r]?Cu[r]:r;"matrix"===i&&a?e.transform(a[0],a[1],a[3],a[4],a[6],a[7]):"lineDash"===i&&e.setLineDash?(0,x.kJ)(a)&&e.setLineDash(a):("strokeStyle"===i||"fillStyle"===i?a=pu(e,t,a):"globalAlpha"===i&&(a*=e.globalAlpha),e[i]=a)}}function Mu(e,t,n){for(var r=0;rI?x:I,C=x>I?1:x/I,k=x>I?I/x:1;t.translate(g,y),t.rotate(w),t.scale(C,k),t.arc(0,0,E,_,b,1-S),t.scale(1/C,1/k),t.rotate(-w),t.translate(-g,-y)}break;case"Z":t.closePath()}if("Z"===p)s=l;else{var M=d.length;s=[d[M-2],d[M-1]]}}}}function Du(e,t){var n=e.get("canvas");n&&("remove"===t&&(e._cacheCanvasBBox=e.get("cacheCanvasBBox")),e.get("hasChanged")||(e.set("hasChanged",!0),e.cfg.parent&&e.cfg.parent.get("hasChanged")||(n.refreshElement(e,t,n),n.get("autoDraw")&&n.draw())))}function Nu(e){var t,n,r;if(e.destroyed)t=e._cacheCanvasBBox;else{var a=e.get("cacheCanvasBBox"),i=a&&!(!a.width||!a.height),o=e.getCanvasBBox(),s=o&&!(!o.width||!o.height);i&&s?(r=o,t=(n=a)&&r?{minX:Math.min(n.minX,r.minX),minY:Math.min(n.minY,r.minY),maxX:Math.max(n.maxX,r.maxX),maxY:Math.max(n.maxY,r.maxY)}:n||r):i?t=a:s&&(t=o)}return t}var zu=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.onCanvasChange=function(e){Du(this,e)},t.prototype.getShapeBase=function(){return d},t.prototype.getGroupBase=function(){return t},t.prototype._applyClip=function(e,t){t&&(e.save(),ku(e,t),t.createPath(e),e.restore(),e.clip(),t._afterDraw())},t.prototype.cacheCanvasBBox=function(){var e=this.cfg.children,t=[],n=[];(0,x.S6)(e,(function(e){var r=e.cfg.cacheCanvasBBox;r&&e.cfg.isInView&&(t.push(r.minX,r.maxX),n.push(r.minY,r.maxY))}));var r=null;if(t.length){var a=(0,x.VV)(t),i=(0,x.Fp)(t),o=(0,x.VV)(n),s=(0,x.Fp)(n);r={minX:a,minY:o,x:a,y:o,maxX:i,maxY:s,width:i-a,height:s-o};var l=this.cfg.canvas;if(l){var u=l.getViewRange();this.set("isInView",iu(r,u))}}else this.set("isInView",!1);this.set("cacheCanvasBBox",r)},t.prototype.draw=function(e,t){var n=this.cfg.children,r=!t||this.cfg.refresh;n.length&&r&&(e.save(),ku(e,this),this._applyClip(e,this.getClip()),Mu(e,n,t),e.restore(),this.cacheCanvasBBox()),this.cfg.refresh=null,this.set("hasChanged",!1)},t.prototype.skipDraw=function(){this.set("cacheCanvasBBox",null),this.set("hasChanged",!1)},t}(F.AbstractGroup),Fu=zu,Bu=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return(0,y.pi)((0,y.pi)({},t),{lineWidth:1,lineAppendWidth:0,strokeOpacity:1,fillOpacity:1})},t.prototype.getShapeBase=function(){return d},t.prototype.getGroupBase=function(){return Fu},t.prototype.onCanvasChange=function(e){Du(this,e)},t.prototype.calculateBBox=function(){var e=this.get("type"),t=this.getHitLineWidth(),n=(0,F.getBBoxMethod)(e)(this),r=t/2,a=n.x-r,i=n.y-r,o=n.x+n.width+r,s=n.y+n.height+r;return{x:a,minX:a,y:i,minY:i,width:n.width+t,height:n.height+t,maxX:o,maxY:s}},t.prototype.isFill=function(){return!!this.attrs.fill||this.isClipShape()},t.prototype.isStroke=function(){return!!this.attrs.stroke},t.prototype._applyClip=function(e,t){t&&(e.save(),ku(e,t),t.createPath(e),e.restore(),e.clip(),t._afterDraw())},t.prototype.draw=function(e,t){var n=this.cfg.clipShape;if(t){if(!1===this.cfg.refresh)return void this.set("hasChanged",!1);if(!iu(t,this.getCanvasBBox()))return this.set("hasChanged",!1),void(this.cfg.isInView&&this._afterDraw())}e.save(),ku(e,this),this._applyClip(e,n),this.drawPath(e),e.restore(),this._afterDraw()},t.prototype.getCanvasViewBox=function(){var e=this.cfg.canvas;return e?e.getViewRange():null},t.prototype.cacheCanvasBBox=function(){var e=this.getCanvasViewBox();if(e){var t=this.getCanvasBBox(),n=iu(t,e);this.set("isInView",n),n?this.set("cacheCanvasBBox",t):this.set("cacheCanvasBBox",null)}},t.prototype._afterDraw=function(){this.cacheCanvasBBox(),this.set("hasChanged",!1),this.set("refresh",null)},t.prototype.skipDraw=function(){this.set("cacheCanvasBBox",null),this.set("isInView",null),this.set("hasChanged",!1)},t.prototype.drawPath=function(e){this.createPath(e),this.strokeAndFill(e),this.afterDrawPath(e)},t.prototype.fill=function(e){e.fill()},t.prototype.stroke=function(e){e.stroke()},t.prototype.strokeAndFill=function(e){var t=this.attrs,n=t.lineWidth,r=t.opacity,a=t.strokeOpacity,i=t.fillOpacity;this.isFill()&&((0,x.UM)(i)||1===i?this.fill(e):(e.globalAlpha=i,this.fill(e),e.globalAlpha=r)),this.isStroke()&&n>0&&((0,x.UM)(a)||1===a||(e.globalAlpha=a),this.stroke(e)),this.afterDrawPath(e)},t.prototype.createPath=function(e){},t.prototype.afterDrawPath=function(e){},t.prototype.isInShape=function(e,t){var n=this.isStroke(),r=this.isFill(),a=this.getHitLineWidth();return this.isInStrokeOrPath(e,t,n,r,a)},t.prototype.isInStrokeOrPath=function(e,t,n,r,a){return!1},t.prototype.getHitLineWidth=function(){if(!this.isStroke())return 0;var e=this.attrs;return e.lineWidth+e.lineAppendWidth},t}(F.AbstractShape),ju=Bu,Zu=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return(0,y.pi)((0,y.pi)({},t),{x:0,y:0,r:0})},t.prototype.isInStrokeOrPath=function(e,t,n,r,a){var i=this.attr(),o=i.x,s=i.y,l=i.r,u=a/2,c=ru(o,s,e,t);return r&&n?c<=l+u:r?c<=l:!!n&&(c>=l-u&&c<=l+u)},t.prototype.createPath=function(e){var t=this.attr(),n=t.x,r=t.y,a=t.r;e.beginPath(),e.arc(n,r,a,0,2*Math.PI,!1),e.closePath()},t}(ju),Uu=Zu;function Vu(e,t,n,r){return e/(n*n)+t/(r*r)}var Hu=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return(0,y.pi)((0,y.pi)({},t),{x:0,y:0,rx:0,ry:0})},t.prototype.isInStrokeOrPath=function(e,t,n,r,a){var i=this.attr(),o=a/2,s=i.x,l=i.y,u=i.rx,c=i.ry,d=(e-s)*(e-s),p=(t-l)*(t-l);return r&&n?Vu(d,p,u+o,c+o)<=1:r?Vu(d,p,u,c)<=1:!!n&&(Vu(d,p,u-o,c-o)>=1&&Vu(d,p,u+o,c+o)<=1)},t.prototype.createPath=function(e){var t=this.attr(),n=t.x,r=t.y,a=t.rx,i=t.ry;if(e.beginPath(),e.ellipse)e.ellipse(n,r,a,i,0,0,2*Math.PI,!1);else{var o=a>i?a:i,s=a>i?1:a/i,l=a>i?i/a:1;e.save(),e.translate(n,r),e.scale(s,l),e.arc(0,0,o,0,2*Math.PI),e.restore(),e.closePath()}},t}(ju),Gu=Hu;function qu(e){return e instanceof HTMLElement&&(0,x.HD)(e.nodeName)&&"CANVAS"===e.nodeName.toUpperCase()}var Wu=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return(0,y.pi)((0,y.pi)({},t),{x:0,y:0,width:0,height:0})},t.prototype.initAttrs=function(e){this._setImage(e.img)},t.prototype.isStroke=function(){return!1},t.prototype.isOnlyHitBox=function(){return!0},t.prototype._afterLoading=function(){if(!0===this.get("toDraw")){var e=this.get("canvas");e?e.draw():this.createPath(this.get("context"))}},t.prototype._setImage=function(e){var t=this,n=this.attrs;if((0,x.HD)(e)){var r=new Image;r.onload=function(){if(t.destroyed)return!1;t.attr("img",r),t.set("loading",!1),t._afterLoading();var e=t.get("callback");e&&e.call(t)},r.crossOrigin="Anonymous",r.src=e,this.set("loading",!0)}else e instanceof Image?(n.width||(n.width=e.width),n.height||(n.height=e.height)):qu(e)&&(n.width||(n.width=Number(e.getAttribute("width"))),n.height||(n.height,Number(e.getAttribute("height"))))},t.prototype.onAttrChange=function(t,n,r){e.prototype.onAttrChange.call(this,t,n,r),"img"===t&&this._setImage(n)},t.prototype.createPath=function(e){if(this.get("loading"))return this.set("toDraw",!0),void this.set("context",e);var t=this.attr(),n=t.x,r=t.y,a=t.width,i=t.height,o=t.sx,s=t.sy,l=t.swidth,u=t.sheight,c=t.img;(c instanceof Image||qu(c))&&((0,x.UM)(o)||(0,x.UM)(s)||(0,x.UM)(l)||(0,x.UM)(u)?e.drawImage(c,n,r,a,i):e.drawImage(c,o,s,l,u,n,r,a,i))},t}(ju),Yu=Wu,Xu=n(41883);function Ku(e,t,n,r,a,i,o){var s=Math.min(e,n),l=Math.max(e,n),u=Math.min(t,r),c=Math.max(t,r),d=a/2;return i>=s-d&&i<=l+d&&o>=u-d&&o<=c+d&&Xu.x1.pointToLine(e,t,n,r,i,o)<=a/2}var Ju=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return(0,y.pi)((0,y.pi)({},t),{x1:0,y1:0,x2:0,y2:0,startArrow:!1,endArrow:!1})},t.prototype.initAttrs=function(e){this.setArrow()},t.prototype.onAttrChange=function(t,n,r){e.prototype.onAttrChange.call(this,t,n,r),this.setArrow()},t.prototype.setArrow=function(){var e=this.attr(),t=e.x1,n=e.y1,r=e.x2,a=e.y2,i=e.startArrow,o=e.endArrow;i&&Su(this,e,r,a,t,n),o&&Eu(this,e,t,n,r,a)},t.prototype.isInStrokeOrPath=function(e,t,n,r,a){if(!n||!a)return!1;var i=this.attr();return Ku(i.x1,i.y1,i.x2,i.y2,a,e,t)},t.prototype.createPath=function(e){var t=this.attr(),n=t.x1,r=t.y1,a=t.x2,i=t.y2,o=t.startArrow,s=t.endArrow,l={dx:0,dy:0},u={dx:0,dy:0};o&&o.d&&(l=wu(n,r,a,i,t.startArrow.d)),s&&s.d&&(u=wu(n,r,a,i,t.endArrow.d)),e.beginPath(),e.moveTo(n+l.dx,r+l.dy),e.lineTo(a-u.dx,i-u.dy)},t.prototype.afterDrawPath=function(e){var t=this.get("startArrowShape"),n=this.get("endArrowShape");t&&t.draw(e),n&&n.draw(e)},t.prototype.getTotalLength=function(){var e=this.attr(),t=e.x1,n=e.y1,r=e.x2,a=e.y2;return Xu.x1.length(t,n,r,a)},t.prototype.getPoint=function(e){var t=this.attr(),n=t.x1,r=t.y1,a=t.x2,i=t.y2;return Xu.x1.pointAt(n,r,a,i,e)},t}(ju),$u=Ju,Qu={circle:function(e,t,n){return[["M",e-n,t],["A",n,n,0,1,0,e+n,t],["A",n,n,0,1,0,e-n,t]]},square:function(e,t,n){return[["M",e-n,t-n],["L",e+n,t-n],["L",e+n,t+n],["L",e-n,t+n],["Z"]]},diamond:function(e,t,n){return[["M",e-n,t],["L",e,t-n],["L",e+n,t],["L",e,t+n],["Z"]]},triangle:function(e,t,n){var r=n*Math.sin(1/3*Math.PI);return[["M",e-n,t+r],["L",e,t-r],["L",e+n,t+r],["Z"]]},"triangle-down":function(e,t,n){var r=n*Math.sin(1/3*Math.PI);return[["M",e-n,t-r],["L",e+n,t-r],["L",e,t+r],["Z"]]}},ec=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.initAttrs=function(e){this._resetParamsCache()},t.prototype._resetParamsCache=function(){this.set("paramsCache",{})},t.prototype.onAttrChange=function(t,n,r){e.prototype.onAttrChange.call(this,t,n,r),-1!==["symbol","x","y","r","radius"].indexOf(t)&&this._resetParamsCache()},t.prototype.isOnlyHitBox=function(){return!0},t.prototype._getR=function(e){return(0,x.UM)(e.r)?e.radius:e.r},t.prototype._getPath=function(){var e,n,r=this.attr(),a=r.x,i=r.y,o=r.symbol||"circle",s=this._getR(r);if((0,x.mf)(o))n=(e=o)(a,i,s),n=(0,Ga.wb)(n);else{if(!(e=t.Symbols[o]))return console.warn(o+" marker is not supported."),null;n=e(a,i,s)}return n},t.prototype.createPath=function(e){Ru(this,e,{path:this._getPath()},this.get("paramsCache"))},t.Symbols=Qu,t}(ju),tc=ec;function nc(e,t,n){var r=(0,F.getOffScreenContext)();return e.createPath(r),r.isPointInPath(t,n)}function rc(e){return Math.abs(e)<1e-6?0:e<0?-1:1}function ac(e,t,n){return(n[0]-e[0])*(t[1]-e[1])==(t[0]-e[0])*(n[1]-e[1])&&Math.min(e[0],t[0])<=n[0]&&n[0]<=Math.max(e[0],t[0])&&Math.min(e[1],t[1])<=n[1]&&n[1]<=Math.max(e[1],t[1])}function ic(e,t,n){var r=!1,a=e.length;if(a<=2)return!1;for(var i=0;i0!=rc(s[1]-n)>0&&rc(t-(n-o[1])*(o[0]-s[0])/(o[1]-s[1])-o[0])<0&&(r=!r)}return r}function oc(e,t,n,r,a,i,o,s){var l=(Math.atan2(s-t,o-e)+2*Math.PI)%(2*Math.PI);if(la)return!1;var u={x:e+n*Math.cos(l),y:t+n*Math.sin(l)};return ru(u.x,u.y,o,s)<=i/2}var sc=vn.vs;var lc=(0,y.pi)({hasArc:function(e){for(var t=!1,n=e.length,r=0;r0&&r.push(a),{polygons:n,polylines:r}},isPointInStroke:function(e,t,n,r,a){for(var i=!1,o=t/2,s=0;sg?m:g,w=sc(null,[["t",-f,-v],["r",-I],["s",1/(m>g?1:m/g),1/(m>g?g/m:1)]]);hn.transformMat3(_,_,w),i=oc(0,0,b,y,x,t,_[0],_[1])}if(i)break}}return i}},F.PathUtil);function uc(e,t,n){for(var r=!1,a=0;a=r[0]&&e<=r[1]&&(t=(e-r[0])/(r[1]-r[0]),n=a)}));var i=a[n];if((0,x.UM)(i)||(0,x.UM)(n))return null;var o=i.length,s=a[n+1];return Xu.Ll.pointAt(i[o-2],i[o-1],s[1],s[2],s[3],s[4],s[5],s[6],t)},t.prototype._calculateCurve=function(){var e=this.attr().path;this.set("curve",lc.pathToCurve(e))},t.prototype._setTcache=function(){var e,t,n,r,a=0,i=0,o=[],s=this.get("curve");s&&((0,x.S6)(s,(function(e,t){n=s[t+1],r=e.length,n&&(a+=Xu.Ll.length(e[r-2],e[r-1],n[1],n[2],n[3],n[4],n[5],n[6])||0)})),this.set("totalLength",a),0!==a?((0,x.S6)(s,(function(l,u){n=s[u+1],r=l.length,n&&((e=[])[0]=i/a,t=Xu.Ll.length(l[r-2],l[r-1],n[1],n[2],n[3],n[4],n[5],n[6]),i+=t||0,e[1]=i/a,o.push(e))})),this.set("tCache",o)):this.set("tCache",[]))},t.prototype.getStartTangent=function(){var e,t=this.getSegments();if(t.length>1){var n=t[0].currentPoint,r=t[1].currentPoint,a=t[1].startTangent;e=[],a?(e.push([n[0]-a[0],n[1]-a[1]]),e.push([n[0],n[1]])):(e.push([r[0],r[1]]),e.push([n[0],n[1]]))}return e},t.prototype.getEndTangent=function(){var e,t=this.getSegments(),n=t.length;if(n>1){var r=t[n-2].currentPoint,a=t[n-1].currentPoint,i=t[n-1].endTangent;e=[],i?(e.push([a[0]-i[0],a[1]-i[1]]),e.push([a[0],a[1]])):(e.push([r[0],r[1]]),e.push([a[0],a[1]]))}return e},t}(ju),dc=cc;function pc(e,t,n,r,a){var i=e.length;if(i<2)return!1;for(var o=0;o=r[0]&&e<=r[1]&&(t=(e-r[0])/(r[1]-r[0]),n=a)})),Xu.x1.pointAt(r[n][0],r[n][1],r[n+1][0],r[n+1][1],t)},t.prototype._setTcache=function(){var e=this.attr().points;if(e&&0!==e.length){var t=this.getTotalLength();if(!(t<=0)){var n,r,a=0,i=[];(0,x.S6)(e,(function(o,s){e[s+1]&&((n=[])[0]=a/t,r=Xu.x1.length(o[0],o[1],e[s+1][0],e[s+1][1]),a+=r,n[1]=a/t,i.push(n))})),this.set("tCache",i)}}},t.prototype.getStartTangent=function(){var e=this.attr().points,t=[];return t.push([e[1][0],e[1][1]]),t.push([e[0][0],e[0][1]]),t},t.prototype.getEndTangent=function(){var e=this.attr().points,t=e.length-1,n=[];return n.push([e[t-1][0],e[t-1][1]]),n.push([e[t][0],e[t][1]]),n},t}(ju),mc=vc;var gc=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return(0,y.pi)((0,y.pi)({},t),{x:0,y:0,width:0,height:0,radius:0})},t.prototype.isInStrokeOrPath=function(e,t,n,r,a){var i=this.attr(),o=i.x,s=i.y,l=i.width,u=i.height,c=i.radius;if(c){var d=!1;return n&&(d=function(e,t,n,r,a,i,o,s){return Ku(e+a,t,e+n-a,t,i,o,s)||Ku(e+n,t+a,e+n,t+r-a,i,o,s)||Ku(e+n-a,t+r,e+a,t+r,i,o,s)||Ku(e,t+r-a,e,t+a,i,o,s)||oc(e+n-a,t+a,a,1.5*Math.PI,2*Math.PI,i,o,s)||oc(e+n-a,t+r-a,a,0,.5*Math.PI,i,o,s)||oc(e+a,t+r-a,a,.5*Math.PI,Math.PI,i,o,s)||oc(e+a,t+a,a,Math.PI,1.5*Math.PI,i,o,s)}(o,s,l,u,c,a,e,t)),!d&&r&&(d=nc(this,e,t)),d}var p=a/2;return r&&n?au(o-p,s-p,l+p,u+p,e,t):r?au(o,s,l,u,e,t):n?function(e,t,n,r,a,i,o){var s=a/2;return au(e-s,t-s,n,a,i,o)||au(e+n-s,t-s,a,r,i,o)||au(e+s,t+r-s,n,a,i,o)||au(e-s,t+s,a,r,i,o)}(o,s,l,u,a,e,t):void 0},t.prototype.createPath=function(e){var t=this.attr(),n=t.x,r=t.y,a=t.width,i=t.height,o=t.radius;if(e.beginPath(),0===o)e.rect(n,r,a,i);else{var s=function(e){var t=0,n=0,r=0,a=0;return(0,x.kJ)(e)?1===e.length?t=n=r=a=e[0]:2===e.length?(t=r=e[0],n=a=e[1]):3===e.length?(t=e[0],n=a=e[1],r=e[2]):(t=e[0],n=e[1],r=e[2],a=e[3]):t=n=r=a=e,[t,n,r,a]}(o),l=s[0],u=s[1],c=s[2],d=s[3];e.moveTo(n+l,r),e.lineTo(n+a-u,r),0!==u&&e.arc(n+a-u,r+u,u,-Math.PI/2,0),e.lineTo(n+a,r+i-c),0!==c&&e.arc(n+a-c,r+i-c,c,0,Math.PI/2),e.lineTo(n+d,r+i),0!==d&&e.arc(n+d,r+i-d,d,Math.PI/2,Math.PI),e.lineTo(n,r+l),0!==l&&e.arc(n+l,r+l,l,Math.PI,1.5*Math.PI),e.closePath()}},t}(ju),yc=gc,xc=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return(0,y.pi)((0,y.pi)({},t),{x:0,y:0,text:null,fontSize:12,fontFamily:"sans-serif",fontStyle:"normal",fontWeight:"normal",fontVariant:"normal",textAlign:"start",textBaseline:"bottom"})},t.prototype.isOnlyHitBox=function(){return!0},t.prototype.initAttrs=function(e){this._assembleFont(),e.text&&this._setText(e.text)},t.prototype._assembleFont=function(){var e=this.attrs;e.font=(0,F.assembleFont)(e)},t.prototype._setText=function(e){var t=null;(0,x.HD)(e)&&-1!==e.indexOf("\n")&&(t=e.split("\n")),this.set("textArr",t)},t.prototype.onAttrChange=function(t,n,r){e.prototype.onAttrChange.call(this,t,n,r),t.startsWith("font")&&this._assembleFont(),"text"===t&&this._setText(n)},t.prototype._getSpaceingY=function(){var e=this.attrs,t=e.lineHeight,n=1*e.fontSize;return t?t-n:.14*n},t.prototype._drawTextArr=function(e,t,n){var r,a=this.attrs,i=a.textBaseline,o=a.x,s=a.y,l=1*a.fontSize,u=this._getSpaceingY(),c=(0,F.getTextHeight)(a.text,a.fontSize,a.lineHeight);(0,x.S6)(t,(function(t,a){r=s+a*(u+l)-c+l,"middle"===i&&(r+=c-l-(c-l)/2),"top"===i&&(r+=c-l),(0,x.UM)(t)||(n?e.fillText(t,o,r):e.strokeText(t,o,r))}))},t.prototype._drawText=function(e,t){var n=this.attr(),r=n.x,a=n.y,i=this.get("textArr");if(i)this._drawTextArr(e,i,t);else{var o=n.text;(0,x.UM)(o)||(t?e.fillText(o,r,a):e.strokeText(o,r,a))}},t.prototype.strokeAndFill=function(e){var t=this.attrs,n=t.lineWidth,r=t.opacity,a=t.strokeOpacity,i=t.fillOpacity;this.isStroke()&&n>0&&((0,x.UM)(a)||1===a||(e.globalAlpha=r),this.stroke(e)),this.isFill()&&((0,x.UM)(i)||1===i?this.fill(e):(e.globalAlpha=i,this.fill(e),e.globalAlpha=r)),this.afterDrawPath(e)},t.prototype.fill=function(e){this._drawText(e,!0)},t.prototype.stroke=function(e){this._drawText(e,!1)},t}(ju),Ic=xc;function _c(e,t,n){var r=e.getTotalMatrix();if(r){var a=function(e,t){if(t){var n=(0,F.invert)(t);return(0,F.multiplyVec2)(n,e)}return e}([t,n,1],r);return[a[0],a[1]]}return[t,n]}function bc(e,t,n){if(e.isCanvas&&e.isCanvas())return!0;if(!(0,F.isAllowCapture)(e)||!1===e.cfg.isInView)return!1;if(e.cfg.clipShape){var r=_c(e,t,n),a=r[0],i=r[1];if(e.isClipped(a,i))return!1}var o=e.cfg.cacheCanvasBBox||e.getCanvasBBox();return t>=o.minX&&t<=o.maxX&&n>=o.minY&&n<=o.maxY}function wc(e,t,n){if(!bc(e,t,n))return null;for(var r=null,a=e.getChildren(),i=a.length-1;i>=0;i--){var o=a[i];if(o.isGroup())r=wc(o,t,n);else if(bc(o,t,n)){var s=o,l=_c(o,t,n),u=l[0],c=l[1];s.isInShape(u,c)&&(r=o)}if(r)break}return r}var Sc=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return t.renderer="canvas",t.autoDraw=!0,t.localRefresh=!0,t.refreshElements=[],t.clipView=!0,t.quickHit=!1,t},t.prototype.onCanvasChange=function(e){"attr"!==e&&"sort"!==e&&"changeSize"!==e||(this.set("refreshElements",[this]),this.draw())},t.prototype.getShapeBase=function(){return d},t.prototype.getGroupBase=function(){return Fu},t.prototype.getPixelRatio=function(){var e=this.get("pixelRatio")||(window?window.devicePixelRatio:1);return e>=1?Math.ceil(e):1},t.prototype.getViewRange=function(){return{minX:0,minY:0,maxX:this.cfg.width,maxY:this.cfg.height}},t.prototype.createDom=function(){var e=document.createElement("canvas"),t=e.getContext("2d");return this.set("context",t),e},t.prototype.setDOMSize=function(t,n){e.prototype.setDOMSize.call(this,t,n);var r=this.get("context"),a=this.get("el"),i=this.getPixelRatio();a.width=i*t,a.height=i*n,i>1&&r.scale(i,i)},t.prototype.clear=function(){e.prototype.clear.call(this),this._clearFrame();var t=this.get("context"),n=this.get("el");t.clearRect(0,0,n.width,n.height)},t.prototype.getShape=function(t,n){return this.get("quickHit")?wc(this,t,n):e.prototype.getShape.call(this,t,n,null)},t.prototype._getRefreshRegion=function(){var e,t=this.get("refreshElements"),n=this.getViewRange();t.length&&t[0]===this?e=n:(e=function(e){if(!e.length)return null;var t=[],n=[],r=[],a=[];return(0,x.S6)(e,(function(e){var i=Nu(e);i&&(t.push(i.minX),n.push(i.minY),r.push(i.maxX),a.push(i.maxY))})),{minX:(0,x.VV)(t),minY:(0,x.VV)(n),maxX:(0,x.Fp)(r),maxY:(0,x.Fp)(a)}}(t),e&&(e.minX=Math.floor(e.minX),e.minY=Math.floor(e.minY),e.maxX=Math.ceil(e.maxX),e.maxY=Math.ceil(e.maxY),e.maxY+=1,this.get("clipView")&&(e=function(e,t){return e&&t&&iu(e,t)?{minX:Math.max(e.minX,t.minX),minY:Math.max(e.minY,t.minY),maxX:Math.min(e.maxX,t.maxX),maxY:Math.min(e.maxY,t.maxY)}:null}(e,n))));return e},t.prototype.refreshElement=function(e){this.get("refreshElements").push(e)},t.prototype._clearFrame=function(){var e=this.get("drawFrame");e&&((0,x.VS)(e),this.set("drawFrame",null),this.set("refreshElements",[]))},t.prototype.draw=function(){var e=this.get("drawFrame");this.get("autoDraw")&&e||this._startDraw()},t.prototype._drawAll=function(){var e=this.get("context"),t=this.get("el"),n=this.getChildren();e.clearRect(0,0,t.width,t.height),ku(e,this),Mu(e,n),this.set("refreshElements",[])},t.prototype._drawRegion=function(){var e=this.get("context"),t=this.get("refreshElements"),n=this.getChildren(),r=this._getRefreshRegion();r?(e.clearRect(r.minX,r.minY,r.maxX-r.minX,r.maxY-r.minY),e.save(),e.beginPath(),e.rect(r.minX,r.minY,r.maxX-r.minX,r.maxY-r.minY),e.clip(),ku(e,this),Tu(this,n,r),Mu(e,n,r),e.restore()):t.length&&Lu(t),(0,x.S6)(t,(function(e){e.get("hasChanged")&&e.set("hasChanged",!1)})),this.set("refreshElements",[])},t.prototype._startDraw=function(){var e=this,t=this.get("drawFrame");t||(t=(0,x.U7)((function(){e.get("localRefresh")?e._drawRegion():e._drawAll(),e.set("drawFrame",null)})),this.set("drawFrame",t))},t.prototype.skipDraw=function(){},t.prototype.removeDom=function(){var e=this.get("el");e.width=0,e.height=0,e.parentNode.removeChild(e)},t}(F.AbstractCanvas),Ec=Sc,Cc="0.5.12",kc={rect:"path",circle:"circle",line:"line",path:"path",marker:"path",text:"text",polyline:"polyline",polygon:"polygon",image:"image",ellipse:"ellipse",dom:"foreignObject"},Mc={opacity:"opacity",fillStyle:"fill",fill:"fill",fillOpacity:"fill-opacity",strokeStyle:"stroke",strokeOpacity:"stroke-opacity",stroke:"stroke",x:"x",y:"y",r:"r",rx:"rx",ry:"ry",width:"width",height:"height",x1:"x1",x2:"x2",y1:"y1",y2:"y2",lineCap:"stroke-linecap",lineJoin:"stroke-linejoin",lineWidth:"stroke-width",lineDash:"stroke-dasharray",lineDashOffset:"stroke-dashoffset",miterLimit:"stroke-miterlimit",font:"font",fontSize:"font-size",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",fontFamily:"font-family",startArrow:"marker-start",endArrow:"marker-end",path:"d",class:"class",id:"id",style:"style",preserveAspectRatio:"preserveAspectRatio"};function Tc(e){return document.createElementNS("http://www.w3.org/2000/svg",e)}function Ac(e){var t=kc[e.type],n=e.getParent();if(!t)throw new Error("the type "+e.type+" is not supported by svg");var r=Tc(t);if(e.get("id")&&(r.id=e.get("id")),e.set("el",r),e.set("attrs",{}),n){var a=n.get("el");a||(a=n.createDom(),n.set("el",a)),a.appendChild(r)}return r}function Lc(e,t){var n=e.get("el"),r=(0,x.qo)(n.children).sort(t),a=document.createDocumentFragment();r.forEach((function(e){a.appendChild(e)})),n.appendChild(a)}function Pc(e){var t=e.attr().matrix;if(t){for(var n=e.cfg.el,r=[],a=0;a<9;a+=3)r.push(t[a]+","+t[a+1]);-1===(r=r.join(",")).indexOf("NaN")?n.setAttribute("transform","matrix("+r+")"):console.warn("invalid matrix:",t)}}function Oc(e,t){var n=e.getClip(),r=e.get("el");if(n){if(n&&!r.hasAttribute("clip-path")){Ac(n),n.createPath(t);var a=t.addClip(n);r.setAttribute("clip-path","url(#"+a+")")}}else r.removeAttribute("clip-path")}function Rc(e,t){t.forEach((function(t){t.draw(e)}))}function Dc(e,t){var n=e.get("canvas");if(n&&n.get("autoDraw")){var r=n.get("context"),a=e.getParent(),i=a?a.getChildren():[n],o=e.get("el");if("remove"===t)if(e.get("isClipShape")){var s=o&&o.parentNode,l=s&&s.parentNode;s&&l&&l.removeChild(s)}else o&&o.parentNode&&o.parentNode.removeChild(o);else if("show"===t)o.setAttribute("visibility","visible");else if("hide"===t)o.setAttribute("visibility","hidden");else if("zIndex"===t)!function(e,t){var n=e.parentNode,r=Array.from(n.childNodes).filter((function(e){return 1===e.nodeType&&"defs"!==e.nodeName.toLowerCase()})),a=r[t],i=r.indexOf(e);if(a){if(i>t)n.insertBefore(e,a);else if(i0&&(t?"stroke"in n?this._setColor(e,"stroke",i):"strokeStyle"in n&&this._setColor(e,"stroke",o):this._setColor(e,"stroke",i||o),l&&c.setAttribute(Mc.strokeOpacity,l),u&&c.setAttribute(Mc.lineWidth,u))},t.prototype._setColor=function(e,t,n){var r=this.get("el");if(n)if(n=n.trim(),/^[r,R,L,l]{1}[\s]*\(/.test(n))(a=e.find("gradient",n))||(a=e.addGradient(n)),r.setAttribute(Mc[t],"url(#"+a+")");else if(/^[p,P]{1}[\s]*\(/.test(n)){var a;(a=e.find("pattern",n))||(a=e.addPattern(n)),r.setAttribute(Mc[t],"url(#"+a+")")}else r.setAttribute(Mc[t],n);else r.setAttribute(Mc[t],"none")},t.prototype.shadow=function(e,t){var n=this.attr(),r=t||n,a=r.shadowOffsetX,i=r.shadowOffsetY,o=r.shadowBlur,s=r.shadowColor;(a||i||o||s)&&function(e,t){var n=e.cfg.el,r=e.attr(),a={dx:r.shadowOffsetX,dy:r.shadowOffsetY,blur:r.shadowBlur,color:r.shadowColor};if(a.dx||a.dy||a.blur||a.color){var i=t.find("filter",a);i||(i=t.addShadow(a)),n.setAttribute("filter","url(#"+i+")")}else n.removeAttribute("filter")}(this,e)},t.prototype.transform=function(e){var t=this.attr();(e||t).matrix&&Pc(this)},t.prototype.isInShape=function(e,t){return this.isPointInPath(e,t)},t.prototype.isPointInPath=function(e,t){var n=this.get("el"),r=this.get("canvas").get("el").getBoundingClientRect(),a=e+r.left,i=t+r.top,o=document.elementFromPoint(a,i);return!(!o||!o.isEqualNode(n))},t.prototype.getHitLineWidth=function(){var e=this.attrs,t=e.lineWidth,n=e.lineAppendWidth;return this.isStroke()?t+n:0},t}(F.AbstractShape),Bc=Fc,jc=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="circle",t.canFill=!0,t.canStroke=!0,t}return(0,y.ZT)(t,e),t.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return(0,y.pi)((0,y.pi)({},t),{x:0,y:0,r:0})},t.prototype.createPath=function(e,t){var n=this.attr(),r=this.get("el");(0,x.S6)(t||n,(function(e,t){"x"===t||"y"===t?r.setAttribute("c"+t,e):Mc[t]&&r.setAttribute(Mc[t],e)}))},t}(Bc),Zc=jc,Uc=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="dom",t.canFill=!1,t.canStroke=!1,t}return(0,y.ZT)(t,e),t.prototype.createPath=function(e,t){var n=this.attr(),r=this.get("el");if((0,x.S6)(t||n,(function(e,t){Mc[t]&&r.setAttribute(Mc[t],e)})),"function"==typeof n.html){var a=n.html.call(this,n);if(a instanceof Element||a instanceof HTMLDocument){for(var i=r.childNodes,o=i.length-1;o>=0;o--)r.removeChild(i[o]);r.appendChild(a)}else r.innerHTML=a}else r.innerHTML=n.html},t}(Bc),Vc=Uc,Hc=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="ellipse",t.canFill=!0,t.canStroke=!0,t}return(0,y.ZT)(t,e),t.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return(0,y.pi)((0,y.pi)({},t),{x:0,y:0,rx:0,ry:0})},t.prototype.createPath=function(e,t){var n=this.attr(),r=this.get("el");(0,x.S6)(t||n,(function(e,t){"x"===t||"y"===t?r.setAttribute("c"+t,e):Mc[t]&&r.setAttribute(Mc[t],e)}))},t}(Bc),Gc=Hc,qc=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="image",t.canFill=!1,t.canStroke=!1,t}return(0,y.ZT)(t,e),t.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return(0,y.pi)((0,y.pi)({},t),{x:0,y:0,width:0,height:0})},t.prototype.createPath=function(e,t){var n=this,r=this.attr(),a=this.get("el");(0,x.S6)(t||r,(function(e,t){"img"===t?n._setImage(r.img):Mc[t]&&a.setAttribute(Mc[t],e)}))},t.prototype.setAttr=function(e,t){this.attrs[e]=t,"img"===e&&this._setImage(t)},t.prototype._setImage=function(e){var t=this.attr(),n=this.get("el");if((0,x.HD)(e))n.setAttribute("href",e);else if(e instanceof window.Image)t.width||(n.setAttribute("width",e.width),this.attr("width",e.width)),t.height||(n.setAttribute("height",e.height),this.attr("height",e.height)),n.setAttribute("href",e.src);else if(e instanceof HTMLElement&&(0,x.HD)(e.nodeName)&&"CANVAS"===e.nodeName.toUpperCase())n.setAttribute("href",e.toDataURL());else if(e instanceof ImageData){var r=document.createElement("canvas");r.setAttribute("width",""+e.width),r.setAttribute("height",""+e.height),r.getContext("2d").putImageData(e,0,0),t.width||(n.setAttribute("width",""+e.width),this.attr("width",e.width)),t.height||(n.setAttribute("height",""+e.height),this.attr("height",e.height)),n.setAttribute("href",r.toDataURL())}},t}(Bc),Wc=qc,Yc=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="line",t.canFill=!1,t.canStroke=!0,t}return(0,y.ZT)(t,e),t.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return(0,y.pi)((0,y.pi)({},t),{x1:0,y1:0,x2:0,y2:0,startArrow:!1,endArrow:!1})},t.prototype.createPath=function(e,t){var n=this.attr(),r=this.get("el");(0,x.S6)(t||n,(function(t,a){if("startArrow"===a||"endArrow"===a)if(t){var i=(0,x.Kn)(t)?e.addArrow(n,Mc[a]):e.getDefaultArrow(n,Mc[a]);r.setAttribute(Mc[a],"url(#"+i+")")}else r.removeAttribute(Mc[a]);else Mc[a]&&r.setAttribute(Mc[a],t)}))},t.prototype.getTotalLength=function(){var e=this.attr(),t=e.x1,n=e.y1,r=e.x2,a=e.y2;return Xu.x1.length(t,n,r,a)},t.prototype.getPoint=function(e){var t=this.attr(),n=t.x1,r=t.y1,a=t.x2,i=t.y2;return Xu.x1.pointAt(n,r,a,i,e)},t}(Bc),Xc=Yc,Kc={circle:function(e,t,n){return[["M",e,t],["m",-n,0],["a",n,n,0,1,0,2*n,0],["a",n,n,0,1,0,2*-n,0]]},square:function(e,t,n){return[["M",e-n,t-n],["L",e+n,t-n],["L",e+n,t+n],["L",e-n,t+n],["Z"]]},diamond:function(e,t,n){return[["M",e-n,t],["L",e,t-n],["L",e+n,t],["L",e,t+n],["Z"]]},triangle:function(e,t,n){var r=n*Math.sin(1/3*Math.PI);return[["M",e-n,t+r],["L",e,t-r],["L",e+n,t+r],["z"]]},triangleDown:function(e,t,n){var r=n*Math.sin(1/3*Math.PI);return[["M",e-n,t-r],["L",e+n,t-r],["L",e,t+r],["Z"]]}},Jc={get:function(e){return Kc[e]},register:function(e,t){Kc[e]=t},remove:function(e){delete Kc[e]},getAll:function(){return Kc}},$c=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="marker",t.canFill=!0,t.canStroke=!0,t}return(0,y.ZT)(t,e),t.prototype.createPath=function(e){this.get("el").setAttribute("d",this._assembleMarker())},t.prototype._assembleMarker=function(){var e=this._getPath();return(0,x.kJ)(e)?e.map((function(e){return e.join(" ")})).join(""):e},t.prototype._getPath=function(){var e,t=this.attr(),n=t.x,r=t.y,a=t.r||t.radius,i=t.symbol||"circle";return(e=(0,x.mf)(i)?i:Jc.get(i))?e(n,r,a):(console.warn(e+" symbol is not exist."),null)},t.symbolsFactory=Jc,t}(Bc),Qc=$c,ed=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="path",t.canFill=!0,t.canStroke=!0,t}return(0,y.ZT)(t,e),t.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return(0,y.pi)((0,y.pi)({},t),{startArrow:!1,endArrow:!1})},t.prototype.createPath=function(e,t){var n=this,r=this.attr(),a=this.get("el");(0,x.S6)(t||r,(function(t,i){if("path"===i&&(0,x.kJ)(t))a.setAttribute("d",n._formatPath(t));else if("startArrow"===i||"endArrow"===i)if(t){var o=(0,x.Kn)(t)?e.addArrow(r,Mc[i]):e.getDefaultArrow(r,Mc[i]);a.setAttribute(Mc[i],"url(#"+o+")")}else a.removeAttribute(Mc[i]);else Mc[i]&&a.setAttribute(Mc[i],t)}))},t.prototype._formatPath=function(e){var t=e.map((function(e){return e.join(" ")})).join("");return~t.indexOf("NaN")?"":t},t.prototype.getTotalLength=function(){var e=this.get("el");return e?e.getTotalLength():null},t.prototype.getPoint=function(e){var t=this.get("el"),n=this.getTotalLength();if(0===n)return null;var r=t?t.getPointAtLength(e*n):null;return r?{x:r.x,y:r.y}:null},t}(Bc),td=ed,nd=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="polygon",t.canFill=!0,t.canStroke=!0,t}return(0,y.ZT)(t,e),t.prototype.createPath=function(e,t){var n=this.attr(),r=this.get("el");(0,x.S6)(t||n,(function(e,t){"points"===t&&(0,x.kJ)(e)&&e.length>=2?r.setAttribute("points",e.map((function(e){return e[0]+","+e[1]})).join(" ")):Mc[t]&&r.setAttribute(Mc[t],e)}))},t}(Bc),rd=nd,ad=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="polyline",t.canFill=!0,t.canStroke=!0,t}return(0,y.ZT)(t,e),t.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return(0,y.pi)((0,y.pi)({},t),{startArrow:!1,endArrow:!1})},t.prototype.onAttrChange=function(t,n,r){e.prototype.onAttrChange.call(this,t,n,r),-1!==["points"].indexOf(t)&&this._resetCache()},t.prototype._resetCache=function(){this.set("totalLength",null),this.set("tCache",null)},t.prototype.createPath=function(e,t){var n=this.attr(),r=this.get("el");(0,x.S6)(t||n,(function(e,t){"points"===t&&(0,x.kJ)(e)&&e.length>=2?r.setAttribute("points",e.map((function(e){return e[0]+","+e[1]})).join(" ")):Mc[t]&&r.setAttribute(Mc[t],e)}))},t.prototype.getTotalLength=function(){var e=this.attr().points,t=this.get("totalLength");return(0,x.UM)(t)?(this.set("totalLength",Xu.aH.length(e)),this.get("totalLength")):t},t.prototype.getPoint=function(e){var t,n,r=this.attr().points,a=this.get("tCache");return a||(this._setTcache(),a=this.get("tCache")),(0,x.S6)(a,(function(r,a){e>=r[0]&&e<=r[1]&&(t=(e-r[0])/(r[1]-r[0]),n=a)})),Xu.x1.pointAt(r[n][0],r[n][1],r[n+1][0],r[n+1][1],t)},t.prototype._setTcache=function(){var e=this.attr().points;if(e&&0!==e.length){var t=this.getTotalLength();if(!(t<=0)){var n,r,a=0,i=[];(0,x.S6)(e,(function(o,s){e[s+1]&&((n=[])[0]=a/t,r=Xu.x1.length(o[0],o[1],e[s+1][0],e[s+1][1]),a+=r,n[1]=a/t,i.push(n))})),this.set("tCache",i)}}},t.prototype.getStartTangent=function(){var e=this.attr().points,t=[];return t.push([e[1][0],e[1][1]]),t.push([e[0][0],e[0][1]]),t},t.prototype.getEndTangent=function(){var e=this.attr().points,t=e.length-1,n=[];return n.push([e[t-1][0],e[t-1][1]]),n.push([e[t][0],e[t][1]]),n},t}(Bc),id=ad;var od=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="rect",t.canFill=!0,t.canStroke=!0,t}return(0,y.ZT)(t,e),t.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return(0,y.pi)((0,y.pi)({},t),{x:0,y:0,width:0,height:0,radius:0})},t.prototype.createPath=function(e,t){var n=this,r=this.attr(),a=this.get("el"),i=!1,o=["x","y","width","height","radius"];(0,x.S6)(t||r,(function(e,t){-1===o.indexOf(t)||i?-1===o.indexOf(t)&&Mc[t]&&a.setAttribute(Mc[t],e):(a.setAttribute("d",n._assembleRect(r)),i=!0)}))},t.prototype._assembleRect=function(e){var t=e.x,n=e.y,r=e.width,a=e.height,i=e.radius;if(!i)return"M "+t+","+n+" l "+r+",0 l 0,"+a+" l"+-r+" 0 z";var o=function(e){var t=0,n=0,r=0,a=0;return(0,x.kJ)(e)?1===e.length?t=n=r=a=e[0]:2===e.length?(t=r=e[0],n=a=e[1]):3===e.length?(t=e[0],n=a=e[1],r=e[2]):(t=e[0],n=e[1],r=e[2],a=e[3]):t=n=r=a=e,{r1:t,r2:n,r3:r,r4:a}}(i);return(0,x.kJ)(i)?1===i.length?o.r1=o.r2=o.r3=o.r4=i[0]:2===i.length?(o.r1=o.r3=i[0],o.r2=o.r4=i[1]):3===i.length?(o.r1=i[0],o.r2=o.r4=i[1],o.r3=i[2]):(o.r1=i[0],o.r2=i[1],o.r3=i[2],o.r4=i[3]):o.r1=o.r2=o.r3=o.r4=i,[["M "+(t+o.r1)+","+n],["l "+(r-o.r1-o.r2)+",0"],["a "+o.r2+","+o.r2+",0,0,1,"+o.r2+","+o.r2],["l 0,"+(a-o.r2-o.r3)],["a "+o.r3+","+o.r3+",0,0,1,"+-o.r3+","+o.r3],["l "+(o.r3+o.r4-r)+",0"],["a "+o.r4+","+o.r4+",0,0,1,"+-o.r4+","+-o.r4],["l 0,"+(o.r4+o.r1-a)],["a "+o.r1+","+o.r1+",0,0,1,"+o.r1+","+-o.r1],["z"]].join(" ")},t}(Bc),sd=od,ld=n(54924),ud={top:"before-edge",middle:"central",bottom:"after-edge",alphabetic:"baseline",hanging:"hanging"},cd={top:"text-before-edge",middle:"central",bottom:"text-after-edge",alphabetic:"alphabetic",hanging:"hanging"},dd={left:"left",start:"left",center:"middle",right:"end",end:"end"},pd=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="text",t.canFill=!0,t.canStroke=!0,t}return(0,y.ZT)(t,e),t.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return(0,y.pi)((0,y.pi)({},t),{x:0,y:0,text:null,fontSize:12,fontFamily:"sans-serif",fontStyle:"normal",fontWeight:"normal",fontVariant:"normal",textAlign:"start",textBaseline:"bottom"})},t.prototype.createPath=function(e,t){var n=this,r=this.attr(),a=this.get("el");this._setFont(),(0,x.S6)(t||r,(function(e,t){"text"===t?n._setText(""+e):"matrix"===t&&e?Pc(n):Mc[t]&&a.setAttribute(Mc[t],e)})),a.setAttribute("paint-order","stroke"),a.setAttribute("style","stroke-linecap:butt; stroke-linejoin:miter;")},t.prototype._setFont=function(){var e=this.get("el"),t=this.attr(),n=t.textBaseline,r=t.textAlign,a=(0,ld.qY)();a&&"firefox"===a.name?e.setAttribute("dominant-baseline",cd[n]||"alphabetic"):e.setAttribute("alignment-baseline",ud[n]||"baseline"),e.setAttribute("text-anchor",dd[r]||"left")},t.prototype._setText=function(e){var t=this.get("el"),n=this.attr(),r=n.x,a=n.textBaseline,i=void 0===a?"bottom":a;if(e)if(~e.indexOf("\n")){var o=e.split("\n"),s=o.length-1,l="";(0,x.S6)(o,(function(e,t){0===t?"alphabetic"===i?l+=''+e+"":"top"===i?l+=''+e+"":"middle"===i?l+=''+e+"":"bottom"===i?l+=''+e+"":"hanging"===i&&(l+=''+e+""):l+=''+e+""})),t.innerHTML=l}else t.innerHTML=e;else t.innerHTML=""},t}(Bc),hd=pd,fd=/^l\s*\(\s*([\d.]+)\s*\)\s*(.*)/i,vd=/^r\s*\(\s*([\d.]+)\s*,\s*([\d.]+)\s*,\s*([\d.]+)\s*\)\s*(.*)/i,md=/[\d.]+:(#[^\s]+|[^)]+\))/gi;function gd(e){var t=e.match(md);if(!t)return"";var n="";return t.sort((function(e,t){return e=e.split(":"),t=t.split(":"),Number(e[0])-Number(t[0])})),(0,x.S6)(t,(function(e){e=e.split(":"),n+=''})),n}var yd=function(){function e(e){this.cfg={};var t=null,n=(0,x.EL)("gradient_");return"l"===e.toLowerCase()[0]?function(e,t){var n,r,a=fd.exec(e),i=(0,x.wQ)((0,x.c$)(parseFloat(a[1])),2*Math.PI),o=a[2];i>=0&&i<.5*Math.PI?(n={x:0,y:0},r={x:1,y:1}):.5*Math.PI<=i&&i';t.innerHTML=n},e}(),wd=function(){function e(e,t){this.cfg={};var n=Tc("marker"),r=(0,x.EL)("marker_");n.setAttribute("id",r);var a=Tc("path");a.setAttribute("stroke",e.stroke||"none"),a.setAttribute("fill",e.fill||"none"),n.appendChild(a),n.setAttribute("overflow","visible"),n.setAttribute("orient","auto-start-reverse"),this.el=n,this.child=a,this.id=r;var i=e["marker-start"===t?"startArrow":"endArrow"];return this.stroke=e.stroke||"#000",!0===i?this._setDefaultPath(t,a):(this.cfg=i,this._setMarker(e.lineWidth,a)),this}return e.prototype.match=function(){return!1},e.prototype._setDefaultPath=function(e,t){var n=this.el;t.setAttribute("d","M0,0 L"+10*Math.cos(Math.PI/6)+",5 L0,10"),n.setAttribute("refX",""+10*Math.cos(Math.PI/6)),n.setAttribute("refY","5")},e.prototype._setMarker=function(e,t){var n=this.el,r=this.cfg.path,a=this.cfg.d;(0,x.kJ)(r)&&(r=r.map((function(e){return e.join(" ")})).join("")),t.setAttribute("d",r),n.appendChild(t),a&&n.setAttribute("refX",""+a/e)},e.prototype.update=function(e){var t=this.child;t.attr?t.attr("fill",e):t.setAttribute("fill",e)},e}(),Sd=wd,Ed=function(){function e(e){this.type="clip",this.cfg={};var t=Tc("clipPath");this.el=t,this.id=(0,x.EL)("clip_"),t.id=this.id;var n=e.cfg.el;return t.appendChild(n),this.cfg=e,this}return e.prototype.match=function(){return!1},e.prototype.remove=function(){var e=this.el;e.parentNode.removeChild(e)},e}(),Cd=/^p\s*\(\s*([axyn])\s*\)\s*(.*)/i,kd=function(){function e(e){this.cfg={};var t=Tc("pattern");t.setAttribute("patternUnits","userSpaceOnUse");var n=Tc("image");t.appendChild(n);var r=(0,x.EL)("pattern_");t.id=r,this.el=t,this.id=r,this.cfg=e;var a=Cd.exec(e)[2];n.setAttribute("href",a);var i=new Image;function o(){t.setAttribute("width",""+i.width),t.setAttribute("height",""+i.height)}return a.match(/^data:/i)||(i.crossOrigin="Anonymous"),i.src=a,i.complete?o():(i.onload=o,i.src=i.src),this}return e.prototype.match=function(e,t){return this.cfg===t},e}(),Md=function(){function e(e){var t=Tc("defs"),n=(0,x.EL)("defs_");t.id=n,e.appendChild(t),this.children=[],this.defaultArrow={},this.el=t,this.canvas=e}return e.prototype.find=function(e,t){for(var n=this.children,r=null,a=0;a0&&(u[0][0]="L")),i=i.concat(u)})),i.push(["Z"])}return i}function Nd(e,t,n,r,a){for(var i=Dl(e,t,!t,"lineWidth"),o=e.connectNulls,s=e.isInCircle,l=Pl(e.points,o,e.showSinglePoint),u=[],c=0,d=l.length;cr&&(r=a),a=t[0]})));var h=this.scales[d];try{for(var f=(0,y.XA)(e),v=f.next();!v.done;v=f.next()){var m=v.value,g=this.getDrawCfg(m),x=g.x,I=g.y,_=h.scale(m[M][d]);this.drawGrayScaleBlurredCircle(x-s.x,I-l.y,n+r,_,p)}}catch(e){a={error:e}}finally{try{v&&!v.done&&(i=f.return)&&i.call(f)}finally{if(a)throw a.error}}var b=p.getImageData(0,0,u,c);this.clearShadowCanvasCtx(),this.colorize(b),p.putImageData(b,0,0);var w=this.getImageShape();w.attr("x",s.x),w.attr("y",l.y),w.attr("width",u),w.attr("height",c),w.attr("img",p.canvas),w.set("origin",this.getShapeInfo(e))},t.prototype.getDefaultSize=function(){var e=this.getAttribute("position"),t=this.coordinate;return Math.min(t.getWidth()/(4*e.scales[0].ticks.length),t.getHeight()/(4*e.scales[1].ticks.length))},t.prototype.clearShadowCanvasCtx=function(){var e=this.getShadowCanvasCtx();e.clearRect(0,0,e.canvas.width,e.canvas.height)},t.prototype.getShadowCanvasCtx=function(){var e=this.shadowCanvas;return e||(e=document.createElement("canvas"),this.shadowCanvas=e),e.width=this.coordinate.getWidth(),e.height=this.coordinate.getHeight(),e.getContext("2d")},t.prototype.getGrayScaleBlurredCanvas=function(){return this.grayScaleBlurredCanvas||(this.grayScaleBlurredCanvas=document.createElement("canvas")),this.grayScaleBlurredCanvas},t.prototype.drawGrayScaleBlurredCircle=function(e,t,n,r,a){var i=this.getGrayScaleBlurredCanvas();a.globalAlpha=r,a.drawImage(i,e-n,t-n)},t.prototype.colorize=function(e){for(var t=this.getAttribute("color"),n=e.data,r=this.paletteCache,a=3;at&&(r=t-(n=n?t/(1+r/n):0)),a+i>t&&(i=t-(a=a?t/(1+i/a):0)),[n||0,r||0,a||0,i||0]}function Wd(e,t,n){var r=[];if(n.isRect){var a=n.isTransposed?{x:n.start.x,y:t[0].y}:{x:t[0].x,y:n.start.y},i=n.isTransposed?{x:n.end.x,y:t[2].y}:{x:t[3].x,y:n.end.y},o=(0,x.U2)(e,["background","style","radius"]);if(o){var s=n.isTransposed?Math.abs(t[0].y-t[2].y):t[2].x-t[1].x,l=n.isTransposed?n.getWidth():n.getHeight(),u=(0,y.CR)(qd(o,Math.min(s,l)),4),c=u[0],d=u[1],p=u[2],h=u[3],f=n.isTransposed&&n.isReflect("y"),v=f?0:1,m=function(e){return f?-e:e};r.push(["M",a.x,i.y+m(c)]),0!==c&&r.push(["A",c,c,0,0,v,a.x+c,i.y]),r.push(["L",i.x-d,i.y]),0!==d&&r.push(["A",d,d,0,0,v,i.x,i.y+m(d)]),r.push(["L",i.x,a.y-m(p)]),0!==p&&r.push(["A",p,p,0,0,v,i.x-p,a.y]),r.push(["L",a.x+h,a.y]),0!==h&&r.push(["A",h,h,0,0,v,a.x,a.y-m(h)])}else r.push(["M",a.x,a.y]),r.push(["L",i.x,a.y]),r.push(["L",i.x,i.y]),r.push(["L",a.x,i.y]),r.push(["L",a.x,a.y]);r.push(["z"])}if(n.isPolar){var g=n.getCenter(),I=xi(e,n),_=I.startAngle,b=I.endAngle;if("theta"===n.type||n.isTransposed){var w=function(e){return Math.pow(e,2)};c=Math.sqrt(w(g.x-t[0].x)+w(g.y-t[0].y)),d=Math.sqrt(w(g.x-t[2].x)+w(g.y-t[2].y));r=gi(g.x,g.y,c,n.startAngle,n.endAngle,d)}else r=gi(g.x,g.y,n.getRadius(),_,b)}return r}function Yd(e,t,n){var r=[];return(0,x.UM)(t)?n?r.push(["M",e[0].x,e[0].y],["L",e[1].x,e[1].y],["L",(e[2].x+e[3].x)/2,(e[2].y+e[3].y)/2],["Z"]):r.push(["M",e[0].x,e[0].y],["L",e[1].x,e[1].y],["L",e[2].x,e[2].y],["L",e[3].x,e[3].y],["Z"]):r.push(["M",e[0].x,e[0].y],["L",e[1].x,e[1].y],["L",t[1].x,t[1].y],["L",t[0].x,t[0].y],["Z"]),r}function Xd(e,t){return[t,e]}rl("interval",{defaultShapeType:"rect",getDefaultPoints:function(e){return Hd(e)}});al("interval","rect",{draw:function(e,t){var n,r=Dl(e,!1,!0),a=t,i=null==e?void 0:e.background;if(i){a=t.addGroup({name:"interval-group"});var o=Nl(e),s=Wd(e,this.parsePoints(e.points),this.coordinate);a.addShape("path",{attrs:(0,y.pi)((0,y.pi)({},o),{path:s}),zIndex:-1,name:Gs})}n=r.radius&&this.coordinate.isRect?function(e,t,n){var r,a,i,o,s,l,u,c=(0,y.CR)((0,y.ev)([],(0,y.CR)(e),!1),4),d=c[0],p=c[1],h=c[2],f=c[3],v=(0,y.CR)("number"==typeof n?Array(4).fill(n):n,4),m=v[0],g=v[1],x=v[2],I=v[3];t.isTransposed&&(p=(r=(0,y.CR)(Xd(p,f),2))[0],f=r[1]),t.isReflect("y")&&(d=(a=(0,y.CR)(Xd(d,p),2))[0],p=a[1],h=(i=(0,y.CR)(Xd(h,f),2))[0],f=i[1]),t.isReflect("x")&&(d=(o=(0,y.CR)(Xd(d,f),2))[0],f=o[1],p=(s=(0,y.CR)(Xd(p,h),2))[0],h=s[1]);var _=[],b=function(e){return Math.abs(e)};return m=(l=(0,y.CR)(qd([m,g,x,I],Math.min(b(f.x-d.x),b(p.y-d.y))).map((function(e){return b(e)})),4))[0],g=l[1],x=l[2],I=l[3],t.isTransposed&&(m=(u=(0,y.CR)([I,m,g,x],4))[0],g=u[1],x=u[2],I=u[3]),d.y1){a.sort();var v=function(e,t){var n=e.length,r=e;(0,x.HD)(r[0])&&(r=e.map((function(e){return t.translate(e)})));for(var a=r[1]-r[0],i=2;io&&(a=o)}return a}(a,r);o=(r.max-r.min)/v,a.length>o&&(o=a.length)}var m=r.range,g=1/o,y=1;(n.isPolar?y=n.isTransposed&&o>1?h:f:(r.isLinear&&(g*=m[1]-m[0]),y=p),!(0,x.UM)(l)&&l>=0)?g=(1-(o-1)*(l/s))/o:g*=y;if(e.getAdjust("dodge")){var I=function(e,t){if(t){var n=(0,x.xH)(e);return(0,x.I)(n,t).length}return e.length}(i,e.getAdjust("dodge").dodgeBy);if(!(0,x.UM)(u)&&u>=0)g=(g-u/s*(I-1))/I;else!(0,x.UM)(l)&&l>=0?(g*=y,g/=I):g/=I;g=g>=0?g:0}if(!(0,x.UM)(c)&&c>=0){var _=c/s;g>_&&(g=_)}if(!(0,x.UM)(d)&&d>=0){var b=d/s;g0&&!(0,x.U2)(n,[r,"min"])&&t.change({min:0}),i<=0&&!(0,x.U2)(n,[r,"max"])&&t.change({max:0}))}},t.prototype.getDrawCfg=function(t){var n=e.prototype.getDrawCfg.call(this,t);return n.background=this.background,n},t}(cl),$d=Jd,Qd=function(e){function t(t){var n=e.call(this,t)||this;n.type="line";var r=t.sortable,a=void 0!==r&&r;return n.sortable=a,n}return(0,y.ZT)(t,e),t}(Rd),ep=Qd,tp=["circle","square","bowtie","diamond","hexagon","triangle","triangle-down"];function np(e,t,n,r,a){var i,o,s=Dl(t,a,!a,"r"),l=e.parsePoints(t.points),u=l[0];if(t.isStack)u=l[1];else if(l.length>1){var c=n.addGroup();try{for(var d=(0,y.XA)(l),p=d.next();!p.done;p=d.next()){var h=p.value;c.addShape({type:"marker",attrs:(0,y.pi)((0,y.pi)((0,y.pi)({},s),{symbol:Sl[r]||r}),h)})}}catch(e){i={error:e}}finally{try{p&&!p.done&&(o=d.return)&&o.call(d)}finally{if(i)throw i.error}}return c}return n.addShape({type:"marker",attrs:(0,y.pi)((0,y.pi)((0,y.pi)({},s),{symbol:Sl[r]||r}),u)})}rl("point",{defaultShapeType:"hollow-circle",getDefaultPoints:function(e){return zl(e)}});(0,x.S6)(tp,(function(e){al("point","hollow-".concat(e),{draw:function(t,n){return np(this,t,n,e,!0)},getMarker:function(t){var n=t.color;return{symbol:Sl[e]||e,style:{r:4.5,stroke:n,fill:null}}}})}));var rp=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="point",t.shapeType="point",t.generatePoints=!0,t}return(0,y.ZT)(t,e),t.prototype.getDrawCfg=function(t){var n=e.prototype.getDrawCfg.call(this,t);return(0,y.pi)((0,y.pi)({},n),{isStack:!!this.getAdjust("stack")})},t}(cl),ap=rp;rl("polygon",{defaultShapeType:"polygon",getDefaultPoints:function(e){var t=[];return(0,x.S6)(e.x,(function(n,r){var a=e.y[r];t.push({x:n,y:a})})),t}});al("polygon","polygon",{draw:function(e,t){if(!(0,x.xb)(e.points)){var n=Dl(e,!0,!0),r=this.parsePath(function(e){for(var t=e[0],n=1,r=[["M",t.x,t.y]];n2?"weight":"normal";if(e.isInCircle){var o={x:0,y:1};return"normal"===i?n=function(e,t,n){var r=pp(t,n),a=[["M",e.x,e.y]];return a.push(r),a}(a[0],a[1],o):(r.fill=r.stroke,n=function(e,t){var n=pp(e[1],t),r=pp(e[3],t),a=[["M",e[0].x,e[0].y]];return a.push(r),a.push(["L",e[3].x,e[3].y]),a.push(["L",e[2].x,e[2].y]),a.push(n),a.push(["L",e[1].x,e[1].y]),a.push(["L",e[0].x,e[0].y]),a.push(["Z"]),a}(a,o)),n=this.parsePath(n),t.addShape("path",{attrs:(0,y.pi)((0,y.pi)({},r),{path:n})})}if("normal"===i)return n=yi(((a=this.parsePoints(a))[1].x+a[0].x)/2,a[0].y,Math.abs(a[1].x-a[0].x)/2,Math.PI,2*Math.PI),t.addShape("path",{attrs:(0,y.pi)((0,y.pi)({},r),{path:n})});var s=dp(a[1],a[3]),l=dp(a[2],a[0]);return n=[["M",a[0].x,a[0].y],["L",a[1].x,a[1].y],s,["L",a[3].x,a[3].y],["L",a[2].x,a[2].y],l,["Z"]],n=this.parsePath(n),r.fill=r.stroke,t.addShape("path",{attrs:(0,y.pi)((0,y.pi)({},r),{path:n})})},getMarker:function(e){return{symbol:"circle",style:{r:4.5,fill:e.color}}}}),al("edge","smooth",{draw:function(e,t){var n=Dl(e,!0,!1,"lineWidth"),r=e.points,a=this.parsePath(function(e,t){var n=dp(e,t),r=[["M",e.x,e.y]];return r.push(n),r}(r[0],r[1]));return t.addShape("path",{attrs:(0,y.pi)((0,y.pi)({},n),{path:a})})},getMarker:function(e){return{symbol:"circle",style:{r:4.5,fill:e.color}}}});var hp=1/3;al("edge","vhv",{draw:function(e,t){var n=Dl(e,!0,!1,"lineWidth"),r=e.points,a=this.parsePath(function(e,t){var n=[];n.push({x:e.x,y:e.y*(1-hp)+t.y*hp}),n.push({x:t.x,y:e.y*(1-hp)+t.y*hp}),n.push(t);var r=[["M",e.x,e.y]];return(0,x.S6)(n,(function(e){r.push(["L",e.x,e.y])})),r}(r[0],r[1]));return t.addShape("path",{attrs:(0,y.pi)((0,y.pi)({},n),{path:a})})},getMarker:function(e){return{symbol:"circle",style:{r:4.5,fill:e.color}}}}),al("interval","funnel",{getPoints:function(e){return e.size=2*e.size,Hd(e)},draw:function(e,t){var n=Dl(e,!1,!0),r=this.parsePath(Yd(e.points,e.nextPoints,!1));return t.addShape("path",{attrs:(0,y.pi)((0,y.pi)({},n),{path:r}),name:"interval"})},getMarker:function(e){return{symbol:"square",style:{r:4,fill:e.color}}}}),al("interval","hollow-rect",{draw:function(e,t){var n=Dl(e,!0,!1),r=t,a=null==e?void 0:e.background;if(a){r=t.addGroup();var i=Nl(e),o=Wd(e,this.parsePoints(e.points),this.coordinate);r.addShape("path",{attrs:(0,y.pi)((0,y.pi)({},i),{path:o}),zIndex:-1,name:Gs})}var s=this.parsePath(Gd(e.points)),l=r.addShape("path",{attrs:(0,y.pi)((0,y.pi)({},n),{path:s}),name:"interval"});return a?r:l},getMarker:function(e){var t=e.color;return e.isInPolar?{symbol:"circle",style:{r:4.5,stroke:t,fill:null}}:{symbol:"square",style:{r:4,stroke:t,fill:null}}}}),al("interval","line",{getPoints:function(e){return n=(t=e).x,r=t.y,a=t.y0,(0,x.kJ)(r)?r.map((function(e,t){return{x:(0,x.kJ)(n)?n[t]:n,y:e}})):[{x:n,y:a},{x:n,y:r}];var t,n,r,a},draw:function(e,t){var n=Dl(e,!0,!1,"lineWidth"),r=bi((0,y.pi)({},n),["fill"]),a=this.parsePath(Gd(e.points,!1));return t.addShape("path",{attrs:(0,y.pi)((0,y.pi)({},r),{path:a}),name:"interval"})},getMarker:function(e){return{symbol:function(e,t,n){return[["M",e,t-n],["L",e,t+n]]},style:{r:5,stroke:e.color}}}}),al("interval","pyramid",{getPoints:function(e){return e.size=2*e.size,Hd(e)},draw:function(e,t){var n=Dl(e,!1,!0),r=this.parsePath(Yd(e.points,e.nextPoints,!0));return t.addShape("path",{attrs:(0,y.pi)((0,y.pi)({},n),{path:r}),name:"interval"})},getMarker:function(e){return{symbol:"square",style:{r:4,fill:e.color}}}}),al("interval","tick",{getPoints:function(e){return function(e){var t,n,r,a=e.x,i=e.y,o=e.y0,s=e.size;(0,x.kJ)(i)?(n=(t=(0,y.CR)(i,2))[0],r=t[1]):(n=o,r=i);var l=a+s/2,u=a-s/2;return[{x:a,y:n},{x:a,y:r},{x:u,y:n},{x:l,y:n},{x:u,y:r},{x:l,y:r}]}(e)},draw:function(e,t){var n,r=Dl(e,!0,!1),a=this.parsePath([["M",(n=e.points)[0].x,n[0].y],["L",n[1].x,n[1].y],["M",n[2].x,n[2].y],["L",n[3].x,n[3].y],["M",n[4].x,n[4].y],["L",n[5].x,n[5].y]]);return t.addShape("path",{attrs:(0,y.pi)((0,y.pi)({},r),{path:a}),name:"interval"})},getMarker:function(e){return{symbol:function(e,t,n){return[["M",e-n/2,t-n],["L",e+n/2,t-n],["M",e,t-n],["L",e,t+n],["M",e-n/2,t+n],["L",e+n/2,t+n]]},style:{r:5,stroke:e.color}}}});function fp(e,t){var n=Pl(e.points,e.connectNulls,e.showSinglePoint),r=[];return(0,x.S6)(n,(function(e){var n=function(e,t){var n=[];return(0,x.S6)(e,(function(r,a){var i=e[a+1];if(n.push(r),i){var o=function(e,t,n){var r,a=e.x,i=e.y,o=t.x,s=t.y;switch(n){case"hv":r=[{x:o,y:i}];break;case"vh":r=[{x:a,y:s}];break;case"hvh":var l=(o+a)/2;r=[{x:l,y:i},{x:l,y:s}];break;case"vhv":var u=(i+s)/2;r=[{x:a,y:u},{x:o,y:u}]}return r}(r,i,t);n=n.concat(o)}})),n}(e,t);r=r.concat(function(e){return e.map((function(e,t){return 0===t?["M",e.x,e.y]:["L",e.x,e.y]}))}(n))})),(0,y.pi)((0,y.pi)({},Dl(e,!0,!1,"lineWidth")),{path:r})}function vp(e){var t=(0,x.kJ)(e)?e:[e],n=t[0],r=t[t.length-1],a=t.length>1?t[1]:n;return{min:n,max:r,min1:a,max1:t.length>3?t[3]:r,median:t.length>2?t[2]:a}}function mp(e,t,n){var r,a=n/2;if((0,x.kJ)(t)){var i=vp(t),o=i.min,s=i.max,l=i.median,u=i.min1,c=e-a,d=e+a;r=[[c,s],[d,s],[e,s],[e,p=i.max1],[c,u],[c,p],[d,p],[d,u],[e,u],[e,o],[c,o],[d,o],[c,l],[d,l]]}else{t=(0,x.UM)(t)?.5:t;var p,h=vp(e),f=(o=h.min,s=h.max,l=h.median,t-a),v=t+a;r=[[o,f],[o,v],[o,t],[u=h.min1,t],[u,f],[u,v],[p=h.max1,v],[p,f],[p,t],[s,t],[s,f],[s,v],[l,f],[l,v]]}return r.map((function(e){return{x:e[0],y:e[1]}}))}function gp(e){var t=((0,x.kJ)(e)?e:[e]).sort((function(e,t){return t-e}));return function(e,t,n){if((0,x.HD)(e))return e.padEnd(t,n);if((0,x.kJ)(e)){var r=e.length;if(r1){var s=t.addGroup();try{for(var l=(0,y.XA)(i),u=l.next();!u.done;u=l.next()){var c=u.value;s.addShape("image",{attrs:{x:c.x-a/2,y:c.y-a,width:a,height:a,img:e.shape[1]}})}}catch(e){n={error:e}}finally{try{u&&!u.done&&(r=l.return)&&r.call(l)}finally{if(n)throw n.error}}return s}return t.addShape("image",{attrs:{x:o.x-a/2,y:o.y-a,width:a,height:a,img:e.shape[1]}})},getMarker:function(e){return{symbol:"circle",style:{r:4.5,fill:e.color}}}}),(0,x.S6)(tp,(function(e){al("point",e,{draw:function(t,n){return np(this,t,n,e,!1)},getMarker:function(t){var n=t.color;return{symbol:Sl[e]||e,style:{r:4.5,fill:n}}}})})),al("schema","box",{getPoints:function(e){return mp(e.x,e.y,e.size)},draw:function(e,t){var n,r=Dl(e,!0,!1),a=this.parsePath([["M",(n=e.points)[0].x,n[0].y],["L",n[1].x,n[1].y],["M",n[2].x,n[2].y],["L",n[3].x,n[3].y],["M",n[4].x,n[4].y],["L",n[5].x,n[5].y],["L",n[6].x,n[6].y],["L",n[7].x,n[7].y],["L",n[4].x,n[4].y],["Z"],["M",n[8].x,n[8].y],["L",n[9].x,n[9].y],["M",n[10].x,n[10].y],["L",n[11].x,n[11].y],["M",n[12].x,n[12].y],["L",n[13].x,n[13].y]]);return t.addShape("path",{attrs:(0,y.pi)((0,y.pi)({},r),{path:a,name:"schema"})})},getMarker:function(e){return{symbol:function(e,t,n){var r=mp(e,[t-6,t-3,t,t+3,t+6],n);return[["M",r[0].x+1,r[0].y],["L",r[1].x-1,r[1].y],["M",r[2].x,r[2].y],["L",r[3].x,r[3].y],["M",r[4].x,r[4].y],["L",r[5].x,r[5].y],["L",r[6].x,r[6].y],["L",r[7].x,r[7].y],["L",r[4].x,r[4].y],["Z"],["M",r[8].x,r[8].y],["L",r[9].x,r[9].y],["M",r[10].x+1,r[10].y],["L",r[11].x-1,r[11].y],["M",r[12].x,r[12].y],["L",r[13].x,r[13].y]]},style:{r:6,lineWidth:1,stroke:e.color}}}}),al("schema","candle",{getPoints:function(e){return yp(e.x,e.y,e.size)},draw:function(e,t){var n,r=Dl(e,!0,!0),a=this.parsePath([["M",(n=e.points)[0].x,n[0].y],["L",n[1].x,n[1].y],["M",n[2].x,n[2].y],["L",n[3].x,n[3].y],["L",n[4].x,n[4].y],["L",n[5].x,n[5].y],["Z"],["M",n[6].x,n[6].y],["L",n[7].x,n[7].y]]);return t.addShape("path",{attrs:(0,y.pi)((0,y.pi)({},r),{path:a,name:"schema"})})},getMarker:function(e){var t=e.color;return{symbol:function(e,t,n){var r=yp(e,[t+7.5,t+3,t-3,t-7.5],n);return[["M",r[0].x,r[0].y],["L",r[1].x,r[1].y],["M",r[2].x,r[2].y],["L",r[3].x,r[3].y],["L",r[4].x,r[4].y],["L",r[5].x,r[5].y],["Z"],["M",r[6].x,r[6].y],["L",r[7].x,r[7].y]]},style:{lineWidth:1,stroke:t,fill:t,r:6}}}}),al("polygon","square",{draw:function(e,t){if(!(0,x.xb)(e.points)){var n=Dl(e,!0,!0),r=this.parsePoints(e.points);return t.addShape("rect",{attrs:(0,y.pi)((0,y.pi)({},n),xp(r,e.size)),name:"polygon"})}},getMarker:function(e){return{symbol:"square",style:{r:4,fill:e.color}}}}),al("violin","smooth",{draw:function(e,t){var n=Dl(e,!0,!0),r=this.parsePath(Rl(e.points));return t.addShape("path",{attrs:(0,y.pi)((0,y.pi)({},n),{path:r})})},getMarker:function(e){return{symbol:"circle",style:{stroke:null,r:4,fill:e.color}}}}),al("violin","hollow",{draw:function(e,t){var n=Dl(e,!0,!1),r=this.parsePath(Ol(e.points));return t.addShape("path",{attrs:(0,y.pi)((0,y.pi)({},n),{path:r})})},getMarker:function(e){return{symbol:"circle",style:{r:4,fill:null,stroke:e.color}}}}),al("violin","hollow-smooth",{draw:function(e,t){var n=Dl(e,!0,!1),r=this.parsePath(Rl(e.points));return t.addShape("path",{attrs:(0,y.pi)((0,y.pi)({},n),{path:r})})},getMarker:function(e){return{symbol:"circle",style:{r:4,fill:null,stroke:e.color}}}});var Ip=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getLabelValueDir=function(e){var t=e.points;return t[0].y<=t[2].y?1:-1},t.prototype.getLabelOffsetPoint=function(t,n,r,a){var i,o=e.prototype.getLabelOffsetPoint.call(this,t,n,r),s=this.getCoordinate(),l=s.isTransposed?"x":"y",u=this.getLabelValueDir(t.mappingData);return o=(0,y.pi)((0,y.pi)({},o),((i={})[l]=o[l]*u,i)),s.isReflect("x")&&(o=(0,y.pi)((0,y.pi)({},o),{x:-1*o.x})),s.isReflect("y")&&(o=(0,y.pi)((0,y.pi)({},o),{y:-1*o.y})),o},t.prototype.getThemedLabelCfg=function(e){var t=this.geometry,n=this.getDefaultLabelCfg(),r=t.theme;return(0,x.b$)({},n,r.labels,"middle"===e.position?{offset:0}:{},e)},t.prototype.setLabelPosition=function(e,t,n,r){var a,i,o,s,l=this.getCoordinate(),u=l.isTransposed,c=t.points,d=l.convert(c[0]),p=l.convert(c[2]),h=this.getLabelValueDir(t),f=(0,x.kJ)(t.shape)?t.shape[0]:t.shape;if("funnel"===f||"pyramid"===f){var v=(0,x.U2)(t,"nextPoints"),m=(0,x.U2)(t,"points");if(v){var g=l.convert(m[0]),y=l.convert(m[1]),I=l.convert(v[0]),_=l.convert(v[1]);u?(a=Math.min(I.y,g.y),o=Math.max(I.y,g.y),i=(y.x+_.x)/2,s=(g.x+I.x)/2):(a=Math.min((y.y+_.y)/2,(g.y+I.y)/2),o=Math.max((y.y+_.y)/2,(g.y+I.y)/2),i=_.x,s=g.x)}else a=Math.min(p.y,d.y),o=Math.max(p.y,d.y),i=p.x,s=d.x}else a=Math.min(p.y,d.y),o=Math.max(p.y,d.y),i=p.x,s=d.x;switch(r){case"right":e.x=i,e.y=(a+o)/2,e.textAlign=(0,x.U2)(e,"textAlign",h>0?"left":"right");break;case"left":e.x=s,e.y=(a+o)/2,e.textAlign=(0,x.U2)(e,"textAlign",h>0?"left":"right");break;case"bottom":u&&(e.x=(i+s)/2),e.y=o,e.textAlign=(0,x.U2)(e,"textAlign","center"),e.textBaseline=(0,x.U2)(e,"textBaseline",h>0?"bottom":"top");break;case"middle":u&&(e.x=(i+s)/2),e.y=(a+o)/2,e.textAlign=(0,x.U2)(e,"textAlign","center"),e.textBaseline=(0,x.U2)(e,"textBaseline","middle");break;case"top":u&&(e.x=(i+s)/2),e.y=a,e.textAlign=(0,x.U2)(e,"textAlign","center"),e.textBaseline=(0,x.U2)(e,"textBaseline",h>0?"bottom":"top")}},t}(bl),_p=Ip,bp=Math.PI/2,wp=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getLabelOffset=function(e){var t=this.getCoordinate(),n=0;if((0,x.hj)(e))n=e;else if((0,x.HD)(e)&&-1!==e.indexOf("%")){var r=t.getRadius();t.innerRadius>0&&(r*=1-t.innerRadius),n=.01*parseFloat(e)*r}return n},t.prototype.getLabelItems=function(t){var n=e.prototype.getLabelItems.call(this,t),r=this.geometry.getYScale();return(0,x.UI)(n,(function(e){if(e&&r){var t=r.scale((0,x.U2)(e.data,r.field));return(0,y.pi)((0,y.pi)({},e),{percent:t})}return e}))},t.prototype.getLabelAlign=function(e){var t,n=this.getCoordinate();if(e.labelEmit)t=e.angle<=Math.PI/2&&e.angle>=-Math.PI/2?"left":"right";else if(n.isTransposed){var r=n.getCenter(),a=e.offset;t=Math.abs(e.x-r.x)<1?"center":e.angle>Math.PI||e.angle<=0?a>0?"left":"right":a>0?"right":"left"}else t="center";return t},t.prototype.getLabelPoint=function(e,t,n){var r,a=1,i=e.content[n];this.isToMiddle(t)?r=this.getMiddlePoint(t.points):(1===e.content.length&&0===n?n=1:0===n&&(a=-1),r=this.getArcPoint(t,n));var o=e.offset*a,s=this.getPointAngle(r),l=e.labelEmit,u=this.getCirclePoint(s,o,r,l);return 0===u.r?u.content="":(u.content=i,u.angle=s,u.color=t.color),u.rotate=e.autoRotate?this.getLabelRotate(s,o,l):e.rotate,u.start={x:r.x,y:r.y},u},t.prototype.getArcPoint=function(e,t){return void 0===t&&(t=0),(0,x.kJ)(e.x)||(0,x.kJ)(e.y)?{x:(0,x.kJ)(e.x)?e.x[t]:e.x,y:(0,x.kJ)(e.y)?e.y[t]:e.y}:{x:e.x,y:e.y}},t.prototype.getPointAngle=function(e){return ki(this.getCoordinate(),e)},t.prototype.getCirclePoint=function(e,t,n,r){var a=this.getCoordinate(),i=a.getCenter(),o=Ci(a,n);if(0===o)return(0,y.pi)((0,y.pi)({},i),{r:o});var s=e;a.isTransposed&&o>t&&!r?s=e+2*Math.asin(t/(2*o)):o+=t;return{x:i.x+o*Math.cos(s),y:i.y+o*Math.sin(s),r:o}},t.prototype.getLabelRotate=function(e,t,n){var r=e+bp;return n&&(r-=bp),r&&(r>bp?r-=Math.PI:r<-bp&&(r+=Math.PI)),r},t.prototype.getMiddlePoint=function(e){var t=this.getCoordinate(),n=e.length,r={x:0,y:0};return(0,x.S6)(e,(function(e){r.x+=e.x,r.y+=e.y})),r.x/=n,r.y/=n,r=t.convert(r)},t.prototype.isToMiddle=function(e){return e.x.length>2},t}(bl),Sp=wp,Ep=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.defaultLayout="distribute",t}return(0,y.ZT)(t,e),t.prototype.getDefaultLabelCfg=function(t,n){var r=e.prototype.getDefaultLabelCfg.call(this,t,n);return(0,x.b$)({},r,(0,x.U2)(this.geometry.theme,"pieLabels",{}))},t.prototype.getLabelOffset=function(t){return e.prototype.getLabelOffset.call(this,t)||0},t.prototype.getLabelRotate=function(e,t,n){var r;return t<0&&((r=e)>Math.PI/2&&(r-=Math.PI),r<-Math.PI/2&&(r+=Math.PI)),r},t.prototype.getLabelAlign=function(e){var t,n=this.getCoordinate().getCenter();return t=e.angle<=Math.PI/2&&e.x>=n.x?"left":"right",e.offset<=0&&(t="right"===t?"left":"right"),t},t.prototype.getArcPoint=function(e){return e},t.prototype.getPointAngle=function(e){var t,n=this.getCoordinate(),r={x:(0,x.kJ)(e.x)?e.x[0]:e.x,y:e.y[0]},a={x:(0,x.kJ)(e.x)?e.x[1]:e.x,y:e.y[1]},i=ki(n,r);if(e.points&&e.points[0].y===e.points[1].y)t=i;else{var o=ki(n,a);i>=o&&(o+=2*Math.PI),t=i+(o-i)/2}return t},t.prototype.getCirclePoint=function(e,t){var n=this.getCoordinate(),r=n.getCenter(),a=n.getRadius()+t;return(0,y.pi)((0,y.pi)({},mi(r.x,r.y,a,e)),{angle:e,r:a})},t}(Sp),Cp=Ep;function kp(e,t,n){var r=e.filter((function(e){return!e.invisible}));r.sort((function(e,t){return e.y-t.y}));var a,i=!0,o=n.minY,s=n.maxY,l=Math.abs(o-s),u=0,c=Number.MIN_VALUE,d=r.map((function(e){return e.y>u&&(u=e.y),e.yl&&(l=u-o);i;)for(d.forEach((function(e){var t=(Math.min.apply(c,e.targets)+Math.max.apply(c,e.targets))/2;e.pos=Math.min(Math.max(c,t-e.size/2),l-e.size),e.pos=Math.max(0,e.pos)})),i=!1,a=d.length;a--;)if(a>0){var p=d[a-1],h=d[a];p.pos+p.size>h.pos&&(p.size+=h.size,p.targets=p.targets.concat(h.targets),p.pos+p.size>l&&(p.pos=l-p.size),d.splice(a,1),i=!0)}a=0,d.forEach((function(e){var n=o+t/2;e.targets.forEach((function(){r[a].y=e.pos+n,n+=t,a++}))}))}var Mp=function(){function e(e){void 0===e&&(e={}),this.bitmap={};var t=e.xGap,n=void 0===t?1:t,r=e.yGap,a=void 0===r?8:r;this.xGap=n,this.yGap=a}return e.prototype.hasGap=function(e){for(var t=!0,n=this.bitmap,r=Math.round(e.minX),a=Math.round(e.maxX),i=Math.round(e.minY),o=Math.round(e.maxY),s=r;s<=a;s+=1)if(n[s]){if(s===r||s===a){for(var l=i;l<=o;l++)if(n[s][l]){t=!1;break}}else if(n[s][i]||n[s][o]){t=!1;break}}else n[s]={};return t},e.prototype.fillGap=function(e){for(var t=this.bitmap,n=Math.round(e.minX),r=Math.round(e.maxX),a=Math.round(e.minY),i=Math.round(e.maxY),o=n;o<=r;o+=1)t[o]||(t[o]={});for(o=n;o<=r;o+=this.xGap){for(var s=a;s<=i;s+=this.yGap)t[o][s]=!0;t[o][i]=!0}if(1!==this.yGap)for(o=a;o<=i;o+=1)t[n][o]=!0,t[r][o]=!0;if(1!==this.xGap)for(o=n;o<=r;o+=1)t[o][a]=!0,t[o][i]=!0},e.prototype.destroy=function(){this.bitmap={}},e}();function Tp(e,t,n,r){var a=e.getCanvasBBox(),i=a.width,o=a.height,s={x:t,y:n,textAlign:"center"};switch(r){case 0:s.y-=o+1,s.x+=1,s.textAlign="left";break;case 1:s.y-=o+1,s.x-=1,s.textAlign="right";break;case 2:s.y+=o+1,s.x-=1,s.textAlign="right";break;case 3:s.y+=o+1,s.x+=1,s.textAlign="left";break;case 5:s.y-=2*o+2;break;case 6:s.y+=2*o+2;break;case 7:s.x+=i+1,s.textAlign="left";break;case 8:s.x-=i+1,s.textAlign="right"}return e.attr(s),e.getCanvasBBox()}function Ap(e){if(e.length>4)return[];var t=function(e,t){return[t.x-e.x,t.y-e.y]};return[t(e[0],e[1]),t(e[1],e[2])]}function Lp(e,t,n){void 0===t&&(t=0),void 0===n&&(n={x:0,y:0});var r=e.x,a=e.y;return{x:(r-n.x)*Math.cos(-t)+(a-n.y)*Math.sin(-t)+n.x,y:(n.x-r)*Math.sin(-t)+(a-n.y)*Math.cos(-t)+n.y}}function Pp(e){var t=[{x:e.x,y:e.y},{x:e.x+e.width,y:e.y},{x:e.x+e.width,y:e.y+e.height},{x:e.x,y:e.y+e.height}],n=e.rotation;return n?[Lp(t[0],n,t[0]),Lp(t[1],n,t[0]),Lp(t[2],n,t[0]),Lp(t[3],n,t[0])]:t}function Op(e,t){if(e.length>4)return{min:0,max:0};var n=[];return e.forEach((function(e){var r,a;n.push((r=[e.x,e.y],a=t,(r[0]||0)*(a[0]||0)+(r[1]||0)*(a[1]||0)+(r[2]||0)*(a[2]||0)))})),{min:Math.min.apply(Math,(0,y.ev)([],(0,y.CR)(n),!1)),max:Math.max.apply(Math,(0,y.ev)([],(0,y.CR)(n),!1))}}function Rp(e,t){return e.max>t.min&&e.mine.x+e.width+n||t.x+t.widthe.y+e.height+n||t.y+t.height4)return[];var t=function(e,t){return[t.x-e.x,t.y-e.y]};return[t(e[0],e[1]),t(e[1],e[2])]}function t(e,t,n){void 0===t&&(t=0),void 0===n&&(n={x:0,y:0});var r=e.x,a=e.y;return{x:(r-n.x)*Math.cos(-t)+(a-n.y)*Math.sin(-t)+n.x,y:(n.x-r)*Math.sin(-t)+(a-n.y)*Math.cos(-t)+n.y}}function n(e){var n=[{x:e.x,y:e.y},{x:e.x+e.width,y:e.y},{x:e.x+e.width,y:e.y+e.height},{x:e.x,y:e.y+e.height}],r=e.rotation;return r?[t(n[0],r,n[0]),t(n[1],r,n[0]),t(n[2],r,n[0]),t(n[3],r,n[0])]:n}function r(e,t){if(e.length>4)return{min:0,max:0};var n=[];return e.forEach((function(e){var r,a;n.push((r=[e.x,e.y],a=t,(r[0]||0)*(a[0]||0)+(r[1]||0)*(a[1]||0)+(r[2]||0)*(a[2]||0)))})),{min:Math.min.apply(null,n),max:Math.max.apply(null,n)}}function a(e,t){return e.max>t.min&&e.mine.x+e.width+n||t.x+t.widthe.y+e.height+n||t.y+t.height=i.height:o.width>=i.width}(e,t,a)}))}function Gp(e,t,n){return e.some((function(e){return n(e,t)}))}function qp(e,t){return Gp(e,t,(function(e,t){var n,r,a,i=fl(e),o=fl(t);return n=i.getCanvasBBox(),r=o.getCanvasBBox(),void 0===(a=2)&&(a=0),Math.max(0,Math.min(n.x+n.width+a,r.x+r.width+a)-Math.max(n.x-a,r.x-a))*Math.max(0,Math.min(n.y+n.height+a,r.y+r.height+a)-Math.max(n.y-a,r.y-a))>0}))}function Wp(e,t,n){return e.some((function(e){return n(e,t)}))}function Yp(e,t){return Wp(e,t,(function(e,t){var n,r,a,i=fl(e),o=fl(t);return n=i.getCanvasBBox(),r=o.getCanvasBBox(),void 0===(a=2)&&(a=0),Math.max(0,Math.min(n.x+n.width+a,r.x+r.width+a)-Math.max(n.x-a,r.x-a))*Math.max(0,Math.min(n.y+n.height+a,r.y+r.height+a)-Math.max(n.y-a,r.y-a))>0}))}function Xp(){return Up||(Up=document.createElement("canvas").getContext("2d")),Up}var Kp=(0,x.HP)((function(e,t){void 0===t&&(t={});var n=t.fontSize,r=t.fontFamily,a=t.fontWeight,i=t.fontStyle,o=t.fontVariant,s=Xp();return s.font=[i,o,a,"".concat(n,"px"),r].join(" "),s.measureText((0,x.HD)(e)?e:"").width}),(function(e,t){return void 0===t&&(t={}),(0,y.ev)([e],(0,y.CR)((0,x.VO)(t)),!1).join("")}));function Jp(e,t,n,r,a){var i,o,s=n.start,l=n.end,u=n.getWidth(),c=n.getHeight();"y"===a?(i=s.x+u/2,o=r.ys.x?r.x:s.x,o=s.y+c/2):"xy"===a&&(n.isPolar?(i=n.getCenter().x,o=n.getCenter().y):(i=(s.x+l.x)/2,o=(s.y+l.y)/2));var d=function(e,t,n){var r,a=(0,y.CR)(t,2),i=a[0],o=a[1];return e.applyToMatrix([i,o,1]),"x"===n?(e.setMatrix(vn.vs(e.getMatrix(),[["t",-i,-o],["s",.01,1],["t",i,o]])),r=vn.vs(e.getMatrix(),[["t",-i,-o],["s",100,1],["t",i,o]])):"y"===n?(e.setMatrix(vn.vs(e.getMatrix(),[["t",-i,-o],["s",1,.01],["t",i,o]])),r=vn.vs(e.getMatrix(),[["t",-i,-o],["s",1,100],["t",i,o]])):"xy"===n&&(e.setMatrix(vn.vs(e.getMatrix(),[["t",-i,-o],["s",.01,.01],["t",i,o]])),r=vn.vs(e.getMatrix(),[["t",-i,-o],["s",100,100],["t",i,o]])),r}(e,[i,o],a);e.animate({matrix:d},t)}function $p(e,t){var n,r=mu(e,t),a=r.startAngle,i=r.endAngle;return!(0,x.vQ)(a,.5*-Math.PI)&&a<.5*-Math.PI&&(a+=2*Math.PI),!(0,x.vQ)(i,.5*-Math.PI)&&i<.5*-Math.PI&&(i+=2*Math.PI),0===t[5]&&(a=(n=(0,y.CR)([i,a],2))[0],i=n[1]),(0,x.vQ)(a,1.5*Math.PI)&&(a=-.5*Math.PI),(0,x.vQ)(i,-.5*Math.PI)&&!(0,x.vQ)(a,i)&&(i=1.5*Math.PI),{startAngle:a,endAngle:i}}function Qp(e){var t;return"M"===e[0]||"L"===e[0]?t=[e[1],e[2]]:"a"!==e[0]&&"A"!==e[0]&&"C"!==e[0]||(t=[e[e.length-2],e[e.length-1]]),t}function eh(e){var t,n,r,a=e.filter((function(e){return"A"===e[0]||"a"===e[0]}));if(0===a.length)return{startAngle:0,endAngle:0,radius:0,innerRadius:0};var i=a[0],o=a.length>1?a[1]:a[0],s=e.indexOf(i),l=e.indexOf(o),u=Qp(e[s-1]),c=Qp(e[l-1]),d=$p(u,i),p=d.startAngle,h=d.endAngle,f=$p(c,o),v=f.startAngle,m=f.endAngle;(0,x.vQ)(p,v)&&(0,x.vQ)(h,m)?(n=p,r=h):(n=Math.min(p,v),r=Math.max(h,m));var g=i[1],I=a[a.length-1][1];return g=0;o--){var s=this.getFacetsByLevel(e,o);try{for(var l=(t=void 0,(0,y.XA)(s)),u=l.next();!u.done;u=l.next()){var c=u.value;this.isLeaf(c)||(c.originColIndex=c.columnIndex,c.columnIndex=this.getRegionIndex(c.children),c.columnValuesLength=a.length)}}catch(e){t={error:e}}finally{try{u&&!u.done&&(n=l.return)&&n.call(l)}finally{if(t)throw t.error}}}},t.prototype.getFacetsByLevel=function(e,t){var n=[];return e.forEach((function(e){e.rowIndex===t&&n.push(e)})),n},t.prototype.getRegionIndex=function(e){var t=e[0];return(e[e.length-1].columnIndex-t.columnIndex)/2+t.columnIndex},t.prototype.isLeaf=function(e){return!e.children||!e.children.length},t.prototype.getRows=function(){return this.cfg.fields.length+1},t.prototype.getChildFacets=function(e,t,n){var r=this,a=this.cfg.fields;if(!(a.length=n){var a=r.parsePosition([e[s],e[o.field]]);a&&d.push(a)}if(e[s]===c)return!1})),d},t.prototype.parsePercentPosition=function(e){var t=parseFloat(e[0])/100,n=parseFloat(e[1])/100,r=this.view.getCoordinate(),a=r.start,i=r.end,o=Math.min(a.x,i.x),s=Math.min(a.y,i.y);return{x:r.getWidth()*t+o,y:r.getHeight()*n+s}},t.prototype.getCoordinateBBox=function(){var e=this.view.getCoordinate(),t=e.start,n=e.end,r=e.getWidth(),a=e.getHeight(),i={x:Math.min(t.x,n.x),y:Math.min(t.y,n.y)};return{x:i.x,y:i.y,minX:i.x,minY:i.y,maxX:i.x+r,maxY:i.y+a,width:r,height:a}},t.prototype.getAnnotationCfg=function(e,t,n){var r=this,a=this.view.getCoordinate(),i=this.view.getCanvas(),o={};if((0,x.UM)(t))return null;var s=t.start,l=t.end,u=t.position,c=this.parsePosition(s),d=this.parsePosition(l),p=this.parsePosition(u);if(!(!["arc","image","line","region","regionFilter"].includes(e)||c&&d))return null;if(["text","dataMarker","html"].includes(e)&&!p)return null;if("arc"===e){var h=t,f=(h.start,h.end,(0,y._T)(h,["start","end"])),v=ki(a,c),m=ki(a,d);v>m&&(m=2*Math.PI+m),o=(0,y.pi)((0,y.pi)({},f),{center:a.getCenter(),radius:Ci(a,c),startAngle:v,endAngle:m})}else if("image"===e){var g=t;g.start,g.end,f=(0,y._T)(g,["start","end"]);o=(0,y.pi)((0,y.pi)({},f),{start:c,end:d,src:t.src})}else if("line"===e){var I=t;I.start,I.end,f=(0,y._T)(I,["start","end"]);o=(0,y.pi)((0,y.pi)({},f),{start:c,end:d,text:(0,x.U2)(t,"text",null)})}else if("region"===e){var _=t;_.start,_.end,f=(0,y._T)(_,["start","end"]);o=(0,y.pi)((0,y.pi)({},f),{start:c,end:d})}else if("text"===e){var b=this.view.getData(),w=t,S=(w.position,w.content),E=(f=(0,y._T)(w,["position","content"]),S);(0,x.mf)(S)&&(E=S(b)),o=(0,y.pi)((0,y.pi)((0,y.pi)({},p),f),{content:E})}else if("dataMarker"===e){var C=t,k=(C.position,C.point),M=C.line,T=C.text,A=C.autoAdjust,L=C.direction;f=(0,y._T)(C,["position","point","line","text","autoAdjust","direction"]);o=(0,y.pi)((0,y.pi)((0,y.pi)({},f),p),{coordinateBBox:this.getCoordinateBBox(),point:k,line:M,text:T,autoAdjust:A,direction:L})}else if("dataRegion"===e){var P=t,O=P.start,R=P.end,D=P.region,N=(T=P.text,P.lineLength);f=(0,y._T)(P,["start","end","region","text","lineLength"]);o=(0,y.pi)((0,y.pi)({},f),{points:this.getRegionPoints(O,R),region:D,text:T,lineLength:N})}else if("regionFilter"===e){var z=t,F=(z.start,z.end,z.apply),B=z.color,j=(f=(0,y._T)(z,["start","end","apply","color"]),this.view.geometries),Z=[],U=function(e){e&&(e.isGroup()?e.getChildren().forEach((function(e){return U(e)})):Z.push(e))};(0,x.S6)(j,(function(e){F?(0,x.FX)(F,e.type)&&(0,x.S6)(e.elements,(function(e){U(e.shape)})):(0,x.S6)(e.elements,(function(e){U(e.shape)}))})),o=(0,y.pi)((0,y.pi)({},f),{color:B,shapes:Z,start:c,end:d})}else if("shape"===e){var V=t,H=V.render,G=(0,y._T)(V,["render"]);o=(0,y.pi)((0,y.pi)({},G),{render:function(e){if((0,x.mf)(t.render))return H(e,r.view,{parsePosition:r.parsePosition.bind(r)})}})}else if("html"===e){var q=t,W=q.html;q.position,G=(0,y._T)(q,["html","position"]);o=(0,y.pi)((0,y.pi)((0,y.pi)({},G),p),{parent:i.get("el").parentNode,html:function(e){return(0,x.mf)(W)?W(e,r.view):W}})}var Y=(0,x.b$)({},n,(0,y.pi)((0,y.pi)({},o),{top:t.top,style:t.style,offsetX:t.offsetX,offsetY:t.offsetY}));return"html"!==e&&(Y.container=this.getComponentContainer(Y)),Y.animate=this.view.getOptions().animate&&Y.animate&&(0,x.U2)(t,"animate",Y.animate),Y.animateOption=(0,x.b$)({},js,Y.animateOption,t.animateOption),Y},t.prototype.isTop=function(e){return(0,x.U2)(e,"top",!0)},t.prototype.getComponentContainer=function(e){return this.isTop(e)?this.foregroundContainer:this.backgroundContainer},t.prototype.getAnnotationTheme=function(e){return(0,x.U2)(this.view.getTheme(),["components","annotation",e],{})},t.prototype.updateOrCreate=function(e){var t=this.cache.get(this.getCacheKey(e));if(t){var n=e.type,r=this.getAnnotationTheme(n),a=this.getAnnotationCfg(n,e,r);a&&bi(a,["container"]),t.component.update((0,y.pi)((0,y.pi)({},a||{}),{visible:!!a})),(0,x.q9)(yh,e.type)&&t.component.render()}else(t=this.createAnnotation(e))&&(t.component.init(),(0,x.q9)(yh,e.type)&&t.component.render());return t},t.prototype.syncCache=function(e){var t=this,n=new Map(this.cache);return e.forEach((function(e,t){n.set(t,e)})),n.forEach((function(e,r){(0,x.sE)(t.option,(function(e){return r===t.getCacheKey(e)}))||(e.component.destroy(),n.delete(r))})),n},t.prototype.getCacheKey=function(e){return e},t}(Rs),Ih=xh;function _h(e,t){var n=(0,x.b$)({},(0,x.U2)(e,["components","axis","common"]),(0,x.U2)(e,["components","axis",t]));return(0,x.U2)(n,["grid"],{})}function bh(e,t,n,r){var a=[],i=t.getTicks();return e.isPolar&&i.push({value:1,text:"",tickValue:""}),i.reduce((function(t,i,o){var s=i.value;if(r)a.push({points:[e.convert("y"===n?{x:0,y:s}:{x:s,y:0}),e.convert("y"===n?{x:1,y:s}:{x:s,y:1})]});else if(o){var l=(t.value+s)/2;a.push({points:[e.convert("y"===n?{x:0,y:l}:{x:l,y:0}),e.convert("y"===n?{x:1,y:l}:{x:l,y:1})]})}return i}),i[0]),a}function wh(e,t,n,r,a){var i=t.values.length,o=[],s=n.getTicks();return s.reduce((function(t,n){var s=t?t.value:n.value,l=n.value,u=(s+l)/2;return"x"===a?o.push({points:[e.convert({x:r?l:u,y:0}),e.convert({x:r?l:u,y:1})]}):o.push({points:(0,x.UI)(Array(i+1),(function(t,n){return e.convert({x:n/i,y:r?l:u})}))}),n}),s[0]),o}function Sh(e,t){var n=(0,x.U2)(t,"grid");if(null===n)return!1;var r=(0,x.U2)(e,"grid");return!(void 0===n&&null===r)}var Eh=["container"],Ch=(0,y.pi)((0,y.pi)({},js),{appear:null}),kh=function(e){function t(t){var n=e.call(this,t)||this;return n.cache=new Map,n.gridContainer=n.view.getLayer(v.BG).addGroup(),n.gridForeContainer=n.view.getLayer(v.FORE).addGroup(),n.axisContainer=n.view.getLayer(v.BG).addGroup(),n.axisForeContainer=n.view.getLayer(v.FORE).addGroup(),n}return(0,y.ZT)(t,e),Object.defineProperty(t.prototype,"name",{get:function(){return"axis"},enumerable:!1,configurable:!0}),t.prototype.init=function(){},t.prototype.render=function(){this.update()},t.prototype.layout=function(){var e=this,t=this.view.getCoordinate();(0,x.S6)(this.getComponents(),(function(n){var r,a=n.component,i=n.direction,o=n.type,s=n.extra,l=s.dim,u=s.scale,c=s.alignTick;if(o===g.AXIS)t.isPolar?"x"===l?r=t.isTransposed?Di(t,i):ji(t):"y"===l&&(r=t.isTransposed?ji(t):Di(t,i)):r=Di(t,i);else if(o===g.GRID)if(t.isPolar){r={items:t.isTransposed?"x"===l?wh(t,e.view.getYScales()[0],u,c,l):bh(t,u,l,c):"x"===l?bh(t,u,l,c):wh(t,e.view.getXScale(),u,c,l),center:e.view.getCoordinate().getCenter()}}else r={items:bh(t,u,l,c)};a.update(r)}))},t.prototype.update=function(){this.option=this.view.getOptions().axes;var e=new Map;this.updateXAxes(e),this.updateYAxes(e);var t=new Map;this.cache.forEach((function(n,r){e.has(r)?t.set(r,n):n.component.destroy()})),this.cache=t},t.prototype.clear=function(){e.prototype.clear.call(this),this.cache.clear(),this.gridContainer.clear(),this.gridForeContainer.clear(),this.axisContainer.clear(),this.axisForeContainer.clear()},t.prototype.destroy=function(){e.prototype.destroy.call(this),this.gridContainer.remove(!0),this.gridForeContainer.remove(!0),this.axisContainer.remove(!0),this.axisForeContainer.remove(!0)},t.prototype.getComponents=function(){var e=[];return this.cache.forEach((function(t){e.push(t)})),e},t.prototype.updateXAxes=function(e){var t=this.view.getXScale();if(t&&!t.isIdentity){var n=Zi(this.option,t.field);if(!1!==n){var r=Ui(n,m.BOTTOM),a=v.BG,i="x",o=this.view.getCoordinate(),s=this.getId("axis",t.field),l=this.getId("grid",t.field);if(o.isRect){if(u=this.cache.get(s))bi(d=this.getLineAxisCfg(t,n,r),Eh),u.component.update(d),e.set(s,u);else u=this.createLineAxis(t,n,a,r,i),this.cache.set(s,u),e.set(s,u);if(c=this.cache.get(l))bi(d=this.getLineGridCfg(t,n,r,i),Eh),c.component.update(d),e.set(l,c);else(c=this.createLineGrid(t,n,a,r,i))&&(this.cache.set(l,c),e.set(l,c))}else if(o.isPolar){var u,c;if(u=this.cache.get(s)){bi(d=o.isTransposed?this.getLineAxisCfg(t,n,m.RADIUS):this.getCircleAxisCfg(t,n,r),Eh),u.component.update(d),e.set(s,u)}else{if(o.isTransposed){if((0,x.o8)(n))return;u=this.createLineAxis(t,n,a,m.RADIUS,i)}else u=this.createCircleAxis(t,n,a,r,i);this.cache.set(s,u),e.set(s,u)}if(c=this.cache.get(l)){var d;bi(d=o.isTransposed?this.getCircleGridCfg(t,n,m.RADIUS,i):this.getLineGridCfg(t,n,m.CIRCLE,i),Eh),c.component.update(d),e.set(l,c)}else{if(o.isTransposed){if((0,x.o8)(n))return;c=this.createCircleGrid(t,n,a,m.RADIUS,i)}else c=this.createLineGrid(t,n,a,m.CIRCLE,i);c&&(this.cache.set(l,c),e.set(l,c))}}}}},t.prototype.updateYAxes=function(e){var t=this,n=this.view.getYScales();(0,x.S6)(n,(function(n,r){if(n&&!n.isIdentity){var a=n.field,i=Zi(t.option,a);if(!1!==i){var o=v.BG,s="y",l=t.getId("axis",a),u=t.getId("grid",a),c=t.view.getCoordinate();if(c.isRect){var d=Ui(i,0===r?m.LEFT:m.RIGHT);if(p=t.cache.get(l))bi(f=t.getLineAxisCfg(n,i,d),Eh),p.component.update(f),e.set(l,p);else p=t.createLineAxis(n,i,o,d,s),t.cache.set(l,p),e.set(l,p);if(h=t.cache.get(u))bi(f=t.getLineGridCfg(n,i,d,s),Eh),h.component.update(f),e.set(u,h);else(h=t.createLineGrid(n,i,o,d,s))&&(t.cache.set(u,h),e.set(u,h))}else if(c.isPolar){var p,h;if(p=t.cache.get(l)){bi(f=c.isTransposed?t.getCircleAxisCfg(n,i,m.CIRCLE):t.getLineAxisCfg(n,i,m.RADIUS),Eh),p.component.update(f),e.set(l,p)}else{if(c.isTransposed){if((0,x.o8)(i))return;p=t.createCircleAxis(n,i,o,m.CIRCLE,s)}else p=t.createLineAxis(n,i,o,m.RADIUS,s);t.cache.set(l,p),e.set(l,p)}if(h=t.cache.get(u)){var f;bi(f=c.isTransposed?t.getLineGridCfg(n,i,m.CIRCLE,s):t.getCircleGridCfg(n,i,m.RADIUS,s),Eh),h.component.update(f),e.set(u,h)}else{if(c.isTransposed){if((0,x.o8)(i))return;h=t.createLineGrid(n,i,o,m.CIRCLE,s)}else h=t.createCircleGrid(n,i,o,m.RADIUS,s);h&&(t.cache.set(u,h),e.set(u,h))}}}}}))},t.prototype.createLineAxis=function(e,t,n,r,a){var i={component:new si(this.getLineAxisCfg(e,t,r)),layer:n,direction:r===m.RADIUS?m.NONE:r,type:g.AXIS,extra:{dim:a,scale:e}};return i.component.set("field",e.field),i.component.init(),i},t.prototype.createLineGrid=function(e,t,n,r,a){var i=this.getLineGridCfg(e,t,r,a);if(i){var o={component:new ui(i),layer:n,direction:m.NONE,type:g.GRID,extra:{dim:a,scale:e,alignTick:(0,x.U2)(i,"alignTick",!0)}};return o.component.init(),o}},t.prototype.createCircleAxis=function(e,t,n,r,a){var i={component:new li(this.getCircleAxisCfg(e,t,r)),layer:n,direction:r,type:g.AXIS,extra:{dim:a,scale:e}};return i.component.set("field",e.field),i.component.init(),i},t.prototype.createCircleGrid=function(e,t,n,r,a){var i=this.getCircleGridCfg(e,t,r,a);if(i){var o={component:new ci(i),layer:n,direction:m.NONE,type:g.GRID,extra:{dim:a,scale:e,alignTick:(0,x.U2)(i,"alignTick",!0)}};return o.component.init(),o}},t.prototype.getLineAxisCfg=function(e,t,n){var r=(0,x.U2)(t,["top"])?this.axisForeContainer:this.axisContainer,a=this.view.getCoordinate(),i=Di(a,n),o=Vi(e,t),s=Fi(this.view.getTheme(),n),l=(0,x.U2)(t,["title"])?(0,x.b$)({title:{style:{text:o}}},{title:Bi(this.view.getTheme(),n,t.title)},t):t,u=(0,x.b$)((0,y.pi)((0,y.pi)({container:r},i),{ticks:e.getTicks().map((function(e){return{id:"".concat(e.tickValue),name:e.text,value:e.value}})),verticalFactor:a.isPolar?-1*zi(i,a.getCenter()):zi(i,a.getCenter()),theme:s}),s,l),c=this.getAnimateCfg(u),d=c.animate,p=c.animateOption;u.animateOption=p,u.animate=d;var h=Ni(i),f=(0,x.U2)(u,"verticalLimitLength",h?1/3:.5);if(f<=1){var v=this.view.getCanvas().get("width"),m=this.view.getCanvas().get("height");u.verticalLimitLength=f*(h?v:m)}return u},t.prototype.getLineGridCfg=function(e,t,n,r){if(Sh(Fi(this.view.getTheme(),n),t)){var a=_h(this.view.getTheme(),n),i=(0,x.b$)({container:(0,x.U2)(t,["top"])?this.gridForeContainer:this.gridContainer},a,(0,x.U2)(t,"grid"),this.getAnimateCfg(t));return i.items=bh(this.view.getCoordinate(),e,r,(0,x.U2)(i,"alignTick",!0)),i}},t.prototype.getCircleAxisCfg=function(e,t,n){var r=(0,x.U2)(t,["top"])?this.axisForeContainer:this.axisContainer,a=this.view.getCoordinate(),i=e.getTicks().map((function(e){return{id:"".concat(e.tickValue),name:e.text,value:e.value}}));e.isCategory||Math.abs(a.endAngle-a.startAngle)!==2*Math.PI||i.pop();var o=Vi(e,t),s=Fi(this.view.getTheme(),m.CIRCLE),l=(0,x.U2)(t,["title"])?(0,x.b$)({title:{style:{text:o}}},{title:Bi(this.view.getTheme(),n,t.title)},t):t,u=(0,x.b$)((0,y.pi)((0,y.pi)({container:r},ji(this.view.getCoordinate())),{ticks:i,verticalFactor:1,theme:s}),s,l),c=this.getAnimateCfg(u),d=c.animate,p=c.animateOption;return u.animate=d,u.animateOption=p,u},t.prototype.getCircleGridCfg=function(e,t,n,r){if(Sh(Fi(this.view.getTheme(),n),t)){var a=_h(this.view.getTheme(),m.RADIUS),i=(0,x.b$)({container:(0,x.U2)(t,["top"])?this.gridForeContainer:this.gridContainer,center:this.view.getCoordinate().getCenter()},a,(0,x.U2)(t,"grid"),this.getAnimateCfg(t)),o=(0,x.U2)(i,"alignTick",!0),s="x"===r?this.view.getYScales()[0]:this.view.getXScale();return i.items=wh(this.view.getCoordinate(),s,e,o,r),i}},t.prototype.getId=function(e,t){var n=this.view.getCoordinate();return"".concat(e,"-").concat(t,"-").concat(n.type)},t.prototype.getAnimateCfg=function(e){return{animate:this.view.getOptions().animate&&(0,x.U2)(e,"animate"),animateOption:e&&e.animateOption?(0,x.b$)({},Ch,e.animateOption):Ch}},t}(Rs),Mh=kh;function Th(e,t,n){return n===m.TOP?[e.minX+e.width/2-t.width/2,e.minY]:n===m.BOTTOM?[e.minX+e.width/2-t.width/2,e.maxY-t.height]:n===m.LEFT?[e.minX,e.minY+e.height/2-t.height/2]:n===m.RIGHT?[e.maxX-t.width,e.minY+e.height/2-t.height/2]:n===m.TOP_LEFT||n===m.LEFT_TOP?[e.tl.x,e.tl.y]:n===m.TOP_RIGHT||n===m.RIGHT_TOP?[e.tr.x-t.width,e.tr.y]:n===m.BOTTOM_LEFT||n===m.LEFT_BOTTOM?[e.bl.x,e.bl.y-t.height]:n===m.BOTTOM_RIGHT||n===m.RIGHT_BOTTOM?[e.br.x-t.width,e.br.y-t.height]:[0,0]}function Ah(e,t){return(0,x.jn)(e)?!1!==e&&{}:(0,x.U2)(e,[t],e)}function Lh(e){return(0,x.U2)(e,"position",m.BOTTOM)}var Ph=function(e){function t(t){var n=e.call(this,t)||this;return n.container=n.view.getLayer(v.FORE).addGroup(),n}return(0,y.ZT)(t,e),Object.defineProperty(t.prototype,"name",{get:function(){return"legend"},enumerable:!1,configurable:!0}),t.prototype.init=function(){},t.prototype.render=function(){this.update()},t.prototype.layout=function(){var e=this;this.layoutBBox=this.view.viewBBox,(0,x.S6)(this.components,(function(t){var n=t.component,r=t.direction,a=kl(r),i=n.get("maxWidthRatio"),o=n.get("maxHeightRatio"),s=e.getCategoryLegendSizeCfg(a,i,o),l=n.get("maxWidth"),u=n.get("maxHeight");n.update({maxWidth:Math.min(s.maxWidth,l||0),maxHeight:Math.min(s.maxHeight,u||0)});var c=n.get("padding"),d=n.getLayoutBBox(),p=new Si(d.x,d.y,d.width,d.height).expand(c),h=(0,y.CR)(Th(e.view.viewBBox,p,r),2),f=h[0],v=h[1],m=(0,y.CR)(Th(e.layoutBBox,p,r),2),g=m[0],x=m[1],I=0,_=0;r.startsWith("top")||r.startsWith("bottom")?(I=f,_=x):(I=g,_=v),n.setLocation({x:I+c[3],y:_+c[0]}),e.layoutBBox=e.layoutBBox.cut(p,r)}))},t.prototype.update=function(){var e=this;this.option=this.view.getOptions().legends;var t={};if((0,x.U2)(this.option,"custom")){var n="global-custom",r=this.getComponentById(n);if(r){var a=this.getCategoryCfg(void 0,void 0,void 0,this.option,!0);bi(a,["container"]),r.component.update(a),t[n]=!0}else{var i=this.createCustomLegend(void 0,void 0,void 0,this.option);if(i){i.init();var o=v.FORE,s=Lh(this.option);this.components.push({id:n,component:i,layer:o,direction:s,type:g.LEGEND,extra:void 0}),t[n]=!0}}}else this.loopLegends((function(n,r,a){var i=e.getId(a.field),o=e.getComponentById(i);if(o){var s=void 0,l=Ah(e.option,a.field);!1!==l&&((0,x.U2)(l,"custom")?s=e.getCategoryCfg(n,r,a,l,!0):a.isLinear?s=e.getContinuousCfg(n,r,a,l):a.isCategory&&(s=e.getCategoryCfg(n,r,a,l))),s&&(bi(s,["container"]),o.direction=Lh(l),o.component.update(s),t[i]=!0)}else{var u=e.createFieldLegend(n,r,a);u&&(u.component.init(),e.components.push(u),t[i]=!0)}}));var l=[];(0,x.S6)(this.getComponents(),(function(e){t[e.id]?l.push(e):e.component.destroy()})),this.components=l},t.prototype.clear=function(){e.prototype.clear.call(this),this.container.clear()},t.prototype.destroy=function(){e.prototype.destroy.call(this),this.container.remove(!0)},t.prototype.getGeometries=function(e){var t=this,n=e.geometries;return(0,x.S6)(e.views,(function(e){n=n.concat(t.getGeometries(e))})),n},t.prototype.loopLegends=function(e){if(this.view.getRootView()===this.view){var t=this.getGeometries(this.view),n={};(0,x.S6)(t,(function(t){var r=t.getGroupAttributes();(0,x.S6)(r,(function(r){var a=r.getScale(r.type);a&&"identity"!==a.type&&!n[a.field]&&(e(t,r,a),n[a.field]=!0)}))}))}},t.prototype.createFieldLegend=function(e,t,n){var r,a=Ah(this.option,n.field),i=v.FORE,o=Lh(a);if(!1!==a&&((0,x.U2)(a,"custom")?r=this.createCustomLegend(e,t,n,a):n.isLinear?r=this.createContinuousLegend(e,t,n,a):n.isCategory&&(r=this.createCategoryLegend(e,t,n,a))),r)return r.set("field",n.field),{id:this.getId(n.field),component:r,layer:i,direction:o,type:g.LEGEND,extra:{scale:n}}},t.prototype.createCustomLegend=function(e,t,n,r){var a=this.getCategoryCfg(e,t,n,r,!0);return new di(a)},t.prototype.createContinuousLegend=function(e,t,n,r){var a=this.getContinuousCfg(e,t,n,bi(r,["value"]));return new pi(a)},t.prototype.createCategoryLegend=function(e,t,n,r){var a=this.getCategoryCfg(e,t,n,r);return new di(a)},t.prototype.getContinuousCfg=function(e,t,n,r){var a=n.getTicks(),i=(0,x.sE)(a,(function(e){return 0===e.value})),o=(0,x.sE)(a,(function(e){return 1===e.value})),s=a.map((function(e){var r=e.value,a=e.tickValue,i=t.mapping(n.invert(r)).join("");return{value:a,attrValue:i,color:i,scaleValue:r}}));i||s.push({value:n.min,attrValue:t.mapping(n.invert(0)).join(""),color:t.mapping(n.invert(0)).join(""),scaleValue:0}),o||s.push({value:n.max,attrValue:t.mapping(n.invert(1)).join(""),color:t.mapping(n.invert(1)).join(""),scaleValue:1}),s.sort((function(e,t){return e.value-t.value}));var l={min:(0,x.YM)(s).value,max:(0,x.Z$)(s).value,colors:[],rail:{type:t.type},track:{}};"size"===t.type&&(l.track={style:{fill:"size"===t.type?this.view.getTheme().defaultColor:void 0}}),"color"===t.type&&(l.colors=s.map((function(e){return e.attrValue})));var u=this.container,c=kl(Lh(r)),d=(0,x.U2)(r,"title");return d&&(d=(0,x.b$)({text:Pi(n)},d)),l.container=u,l.layout=c,l.title=d,l.animateOption=js,this.mergeLegendCfg(l,r,"continuous")},t.prototype.getCategoryCfg=function(e,t,n,r,a){var i=this.container,o=(0,x.U2)(r,"position",m.BOTTOM),s=Tl(this.view.getTheme(),o),l=(0,x.U2)(s,["marker"]),u=(0,x.U2)(r,"marker"),c=kl(o),d=(0,x.U2)(s,["pageNavigator"]),p=(0,x.U2)(r,"pageNavigator"),h=a?function(e,t,n){return n.map((function(n,r){var a=t;(0,x.mf)(a)&&(a=a(n.name,r,(0,x.b$)({},e,n)));var i=(0,x.mf)(n.marker)?n.marker(n.name,r,(0,x.b$)({},e,n)):n.marker,o=(0,x.b$)({},e,a,i);return Cl(o),n.marker=o,n}))}(l,u,r.items):Ml(this.view,e,t,l,u),f=(0,x.U2)(r,"title");f&&(f=(0,x.b$)({text:n?Pi(n):""},f));var v=(0,x.U2)(r,"maxWidthRatio"),g=(0,x.U2)(r,"maxHeightRatio"),y=this.getCategoryLegendSizeCfg(c,v,g);y.container=i,y.layout=c,y.items=h,y.title=f,y.animateOption=js,y.pageNavigator=(0,x.b$)({},d,p);var I=this.mergeLegendCfg(y,r,o);I.reversed&&I.items.reverse();var _=(0,x.U2)(I,"maxItemWidth");return _&&_<=1&&(I.maxItemWidth=this.view.viewBBox.width*_),I},t.prototype.mergeLegendCfg=function(e,t,n){var r=n.split("-")[0],a=Tl(this.view.getTheme(),r);return(0,x.b$)({},a,e,t)},t.prototype.getId=function(e){return"".concat(this.name,"-").concat(e)},t.prototype.getComponentById=function(e){return(0,x.sE)(this.components,(function(t){return t.id===e}))},t.prototype.getCategoryLegendSizeCfg=function(e,t,n){void 0===t&&(t=.25),void 0===n&&(n=.25);var r=this.view.viewBBox,a=r.width,i=r.height;return"vertical"===e?{maxWidth:a*t,maxHeight:i}:{maxWidth:a,maxHeight:i*n}},t}(Rs),Oh=Ph,Rh=function(e){function t(t){var n=e.call(this,t)||this;return n.onChangeFn=x.ZT,n.resetMeasure=function(){n.clear()},n.onValueChange=function(e){var t=(0,y.CR)(e,2),r=t[0],a=t[1];n.start=r,n.end=a,n.changeViewData(r,a)},n.container=n.view.getLayer(v.FORE).addGroup(),n.onChangeFn=(0,x.P2)(n.onValueChange,20,{leading:!0}),n.width=0,n.view.on(I.BEFORE_CHANGE_DATA,n.resetMeasure),n.view.on(I.BEFORE_CHANGE_SIZE,n.resetMeasure),n}return(0,y.ZT)(t,e),Object.defineProperty(t.prototype,"name",{get:function(){return"slider"},enumerable:!1,configurable:!0}),t.prototype.destroy=function(){e.prototype.destroy.call(this),this.view.off(I.BEFORE_CHANGE_DATA,this.resetMeasure),this.view.off(I.BEFORE_CHANGE_SIZE,this.resetMeasure)},t.prototype.init=function(){},t.prototype.render=function(){this.option=this.view.getOptions().slider;var e=this.getSliderCfg(),t=e.start,n=e.end;(0,x.UM)(this.start)&&(this.start=t,this.end=n);var r=this.view.getOptions().data;this.option&&!(0,x.xb)(r)?this.slider?this.slider=this.updateSlider():(this.slider=this.createSlider(),this.slider.component.on("sliderchange",this.onChangeFn)):this.slider&&(this.slider.component.destroy(),this.slider=void 0)},t.prototype.layout=function(){var e=this;if(this.option&&!this.width&&(this.measureSlider(),setTimeout((function(){e.view.destroyed||e.changeViewData(e.start,e.end)}),0)),this.slider){var t=this.view.coordinateBBox.width,n=this.slider.component.get("padding"),r=(0,y.CR)(n,4),a=r[0],i=(r[1],r[2],r[3]),o=this.slider.component.getLayoutBBox(),s=new Si(o.x,o.y,Math.min(o.width,t),o.height).expand(n),l=this.getMinMaxText(this.start,this.end),u=l.minText,c=l.maxText,d=(0,y.CR)(Th(this.view.viewBBox,s,m.BOTTOM),2),p=(d[0],d[1]),h=(0,y.CR)(Th(this.view.coordinateBBox,s,m.BOTTOM),2),f=h[0];h[1];this.slider.component.update((0,y.pi)((0,y.pi)({},this.getSliderCfg()),{x:f+i,y:p+a,width:this.width,start:this.start,end:this.end,minText:u,maxText:c})),this.view.viewBBox=this.view.viewBBox.cut(s,m.BOTTOM)}},t.prototype.update=function(){this.render()},t.prototype.createSlider=function(){var e=this.getSliderCfg(),t=new ri((0,y.pi)({container:this.container},e));return t.init(),{component:t,layer:v.FORE,direction:m.BOTTOM,type:g.SLIDER}},t.prototype.updateSlider=function(){var e=this.getSliderCfg();if(this.width){var t=this.getMinMaxText(this.start,this.end),n=t.minText,r=t.maxText;e=(0,y.pi)((0,y.pi)({},e),{width:this.width,start:this.start,end:this.end,minText:n,maxText:r})}return this.slider.component.update(e),this.slider},t.prototype.measureSlider=function(){var e=this.getSliderCfg().width;this.width=e},t.prototype.getSliderCfg=function(){var e={height:16,start:0,end:1,minText:"",maxText:"",x:0,y:0,width:this.view.coordinateBBox.width};if((0,x.Kn)(this.option)){var t=(0,y.pi)({data:this.getData()},(0,x.U2)(this.option,"trendCfg",{}));e=(0,x.b$)({},e,this.getThemeOptions(),this.option),e=(0,y.pi)((0,y.pi)({},e),{trendCfg:t})}return e.start=(0,x.uZ)(Math.min((0,x.UM)(e.start)?0:e.start,(0,x.UM)(e.end)?1:e.end),0,1),e.end=(0,x.uZ)(Math.max((0,x.UM)(e.start)?0:e.start,(0,x.UM)(e.end)?1:e.end),0,1),e},t.prototype.getData=function(){var e=this.view.getOptions().data,t=(0,y.CR)(this.view.getYScales(),1)[0],n=this.view.getGroupScales();if(n.length){var r=n[0],a=r.field,i=r.ticks;return e.reduce((function(e,n){return n[a]===i[0]&&e.push(n[t.field]),e}),[])}return e.map((function(e){return e[t.field]||0}))},t.prototype.getThemeOptions=function(){var e=this.view.getTheme();return(0,x.U2)(e,["components","slider","common"],{})},t.prototype.getMinMaxText=function(e,t){var n=this.view.getOptions().data,r=this.view.getXScale(),a=(0,x.I)(n,r.field);r.isLinear&&(a=a.sort());var i=a,o=(0,x.dp)(n);if(!r||!o)return{};var s=(0,x.dp)(i),l=Math.round(e*(s-1)),u=Math.round(t*(s-1)),c=(0,x.U2)(i,[l]),d=(0,x.U2)(i,[u]),p=this.getSliderCfg().formatter;return p&&(c=p(c,n[l],l),d=p(d,n[u],u)),{minText:c,maxText:d}},t.prototype.changeViewData=function(e,t){var n=this.view.getOptions().data,r=this.view.getXScale(),a=(0,x.dp)(n);if(r&&a){var i=(0,x.I)(n,r.field),o=this.view.getXScale().isLinear?i.sort((function(e,t){return Number(e)-Number(t)})):i,s=o,l=(0,x.dp)(s),u=Math.round(e*(l-1)),c=Math.round(t*(l-1));this.view.filter(r.field,(function(e,t){var n=s.indexOf(e);return!(n>-1)||_i(n,u,c)})),this.view.render(!0)}},t.prototype.getComponents=function(){return this.slider?[this.slider]:[]},t.prototype.clear=function(){this.slider&&(this.slider.component.destroy(),this.slider=void 0),this.width=0,this.start=void 0,this.end=void 0},t}(Rs),Dh=Rh,Nh=function(e){function t(t){var n=e.call(this,t)||this;return n.onChangeFn=x.ZT,n.resetMeasure=function(){n.clear()},n.onValueChange=function(e){var t=e.ratio,r=n.getValidScrollbarCfg().animate;n.ratio=(0,x.uZ)(t,0,1);var a=n.view.getOptions().animate;r||n.view.animate(!1),n.changeViewData(n.getScrollRange(),!0),n.view.animate(a)},n.container=n.view.getLayer(v.FORE).addGroup(),n.onChangeFn=(0,x.P2)(n.onValueChange,20,{leading:!0}),n.trackLen=0,n.thumbLen=0,n.ratio=0,n.view.on(I.BEFORE_CHANGE_DATA,n.resetMeasure),n.view.on(I.BEFORE_CHANGE_SIZE,n.resetMeasure),n}return(0,y.ZT)(t,e),Object.defineProperty(t.prototype,"name",{get:function(){return"scrollbar"},enumerable:!1,configurable:!0}),t.prototype.destroy=function(){e.prototype.destroy.call(this),this.view.off(I.BEFORE_CHANGE_DATA,this.resetMeasure),this.view.off(I.BEFORE_CHANGE_SIZE,this.resetMeasure)},t.prototype.init=function(){},t.prototype.render=function(){this.option=this.view.getOptions().scrollbar,this.option?this.scrollbar?this.scrollbar=this.updateScrollbar():(this.scrollbar=this.createScrollbar(),this.scrollbar.component.on("scrollchange",this.onChangeFn)):this.scrollbar&&(this.scrollbar.component.destroy(),this.scrollbar=void 0)},t.prototype.layout=function(){var e=this;if(this.option&&!this.trackLen&&(this.measureScrollbar(),setTimeout((function(){e.view.destroyed||e.changeViewData(e.getScrollRange(),!0)}))),this.scrollbar){var t=this.view.coordinateBBox.width,n=this.scrollbar.component.get("padding"),r=this.scrollbar.component.getLayoutBBox(),a=new Si(r.x,r.y,Math.min(r.width,t),r.height).expand(n),i=this.getScrollbarComponentCfg(),o=void 0,s=void 0;if(i.isHorizontal){var l=(0,y.CR)(Th(this.view.viewBBox,a,m.BOTTOM),2),u=(l[0],l[1]),c=(0,y.CR)(Th(this.view.coordinateBBox,a,m.BOTTOM),2),d=c[0];c[1];o=d,s=u}else{var p=(0,y.CR)(Th(this.view.viewBBox,a,m.RIGHT),2),h=(p[0],u=p[1],(0,y.CR)(Th(this.view.viewBBox,a,m.RIGHT),2));d=h[0],h[1];o=d,s=u}o+=n[3],s+=n[0],this.trackLen?this.scrollbar.component.update((0,y.pi)((0,y.pi)({},i),{x:o,y:s,trackLen:this.trackLen,thumbLen:this.thumbLen,thumbOffset:(this.trackLen-this.thumbLen)*this.ratio})):this.scrollbar.component.update((0,y.pi)((0,y.pi)({},i),{x:o,y:s})),this.view.viewBBox=this.view.viewBBox.cut(a,i.isHorizontal?m.BOTTOM:m.RIGHT)}},t.prototype.update=function(){this.render()},t.prototype.getComponents=function(){return this.scrollbar?[this.scrollbar]:[]},t.prototype.clear=function(){this.scrollbar&&(this.scrollbar.component.destroy(),this.scrollbar=void 0),this.trackLen=0,this.thumbLen=0,this.ratio=0,this.cnt=0,this.step=0,this.data=void 0,this.xScaleCfg=void 0,this.yScalesCfg=[]},t.prototype.setValue=function(e){this.onValueChange({ratio:e})},t.prototype.getValue=function(){return this.ratio},t.prototype.getThemeOptions=function(){var e=this.view.getTheme();return(0,x.U2)(e,["components","scrollbar","common"],{})},t.prototype.getScrollbarTheme=function(e){var t=(0,x.U2)(this.view.getTheme(),["components","scrollbar"]),n=e||{},r=n.thumbHighlightColor,a=(0,y._T)(n,["thumbHighlightColor"]);return{default:(0,x.b$)({},(0,x.U2)(t,["default","style"],{}),a),hover:(0,x.b$)({},(0,x.U2)(t,["hover","style"],{}),{thumbColor:r})}},t.prototype.measureScrollbar=function(){var e=this.view.getXScale(),t=this.view.getYScales().slice();this.data=this.getScrollbarData(),this.step=this.getStep(),this.cnt=this.getCnt();var n=this.getScrollbarComponentCfg(),r=n.trackLen,a=n.thumbLen;this.trackLen=r,this.thumbLen=a,this.xScaleCfg={field:e.field,values:e.values||[]},this.yScalesCfg=t},t.prototype.getScrollRange=function(){var e=Math.floor((this.cnt-this.step)*(0,x.uZ)(this.ratio,0,1));return[e,Math.min(e+this.step-1,this.cnt-1)]},t.prototype.changeViewData=function(e,t){var n=this,r=(0,y.CR)(e,2),a=r[0],i=r[1],o="vertical"!==this.getValidScrollbarCfg().type,s=(0,x.I)(this.data,this.xScaleCfg.field),l=this.view.getXScale().isLinear?s.sort((function(e,t){return Number(e)-Number(t)})):s,u=o?l:l.reverse();this.yScalesCfg.forEach((function(e){n.view.scale(e.field,{formatter:e.formatter,type:e.type,min:e.min,max:e.max,tickMethod:e.tickMethod})})),this.view.filter(this.xScaleCfg.field,(function(e){var t=u.indexOf(e);return!(t>-1)||_i(t,a,i)})),this.view.render(!0)},t.prototype.createScrollbar=function(){var e="vertical"!==this.getValidScrollbarCfg().type,t=new oi((0,y.pi)((0,y.pi)({container:this.container},this.getScrollbarComponentCfg()),{x:0,y:0}));return t.init(),{component:t,layer:v.FORE,direction:e?m.BOTTOM:m.RIGHT,type:g.SCROLLBAR}},t.prototype.updateScrollbar=function(){var e=this.getScrollbarComponentCfg(),t=this.trackLen?(0,y.pi)((0,y.pi)({},e),{trackLen:this.trackLen,thumbLen:this.thumbLen,thumbOffset:(this.trackLen-this.thumbLen)*this.ratio}):(0,y.pi)({},e);return this.scrollbar.component.update(t),this.scrollbar},t.prototype.getStep=function(){if(this.step)return this.step;var e=this.view.coordinateBBox,t=this.getValidScrollbarCfg(),n=t.type,r=t.categorySize,a="vertical"!==n;return Math.floor((a?e.width:e.height)/r)},t.prototype.getCnt=function(){if(this.cnt)return this.cnt;var e=this.view.getXScale(),t=this.getScrollbarData(),n=(0,x.I)(t,e.field);return(0,x.dp)(n)},t.prototype.getScrollbarComponentCfg=function(){var e=this.view,t=e.coordinateBBox,n=e.viewBBox,r=this.getValidScrollbarCfg(),a=r.type,i=r.padding,o=r.width,s=r.height,l=r.style,u="vertical"!==a,c=(0,y.CR)(i,4),d=c[0],p=c[1],h=c[2],f=c[3],v=u?{x:t.minX+f,y:n.maxY-s-h}:{x:n.maxX-o-p,y:t.minY+d},m=this.getStep(),g=this.getCnt(),I=u?t.width-f-p:t.height-d-h,_=Math.max(I*(0,x.uZ)(m/g,0,1),20);return(0,y.pi)((0,y.pi)({},this.getThemeOptions()),{x:v.x,y:v.y,size:u?s:o,isHorizontal:u,trackLen:I,thumbLen:_,thumbOffset:0,theme:this.getScrollbarTheme(l)})},t.prototype.getValidScrollbarCfg=function(){var e={type:"horizontal",categorySize:32,width:8,height:8,padding:[0,0,0,0],animate:!0,style:{}};return(0,x.Kn)(this.option)&&(e=(0,y.pi)((0,y.pi)({},e),this.option)),(0,x.Kn)(this.option)&&this.option.padding||(e.padding=(e.type,[0,0,0,0])),e},t.prototype.getScrollbarData=function(){var e=this.view.getCoordinate(),t=this.getValidScrollbarCfg(),n=this.view.getOptions().data||[];return e.isReflect("y")&&"vertical"===t.type&&(n=(0,y.ev)([],(0,y.CR)(n),!1).reverse()),n},t}(Rs),zh=Nh,Fh={fill:"#CCD6EC",opacity:.3};function Bh(e,t,n){var r,a,i,o,s,l,u=function(e,t,n){var r,a,i=ms(e,t,n);try{for(var o=(0,y.XA)(e.views),s=o.next();!s.done;s=o.next()){var l=s.value;i=i.concat(ms(l,t,n))}}catch(e){r={error:e}}finally{try{s&&!s.done&&(a=o.return)&&a.call(o)}finally{if(r)throw r.error}}return i}(e,t,n);if(u.length){u=(0,x.xH)(u);try{for(var c=(0,y.XA)(u),d=c.next();!d.done;d=c.next()){var p=d.value;try{for(var h=(i=void 0,(0,y.XA)(p)),f=h.next();!f.done;f=h.next()){var v=f.value,m=v.mappingData,g=m.x,I=m.y;v.x=(0,x.kJ)(g)?g[g.length-1]:g,v.y=(0,x.kJ)(I)?I[I.length-1]:I}}catch(e){i={error:e}}finally{try{f&&!f.done&&(o=h.return)&&o.call(h)}finally{if(i)throw i.error}}}}catch(e){r={error:e}}finally{try{d&&!d.done&&(a=c.return)&&a.call(c)}finally{if(r)throw r.error}}if(!1===n.shared&&u.length>1){var _=u[0],b=Math.abs(t.y-_[0].y);try{for(var w=(0,y.XA)(u),S=w.next();!S.done;S=w.next()){var E=S.value,C=Math.abs(t.y-E[0].y);C<=b&&(_=E,b=C)}}catch(e){s={error:e}}finally{try{S&&!S.done&&(l=w.return)&&l.call(w)}finally{if(s)throw s.error}}u=[_]}return(0,x.jj)((0,x.xH)(u))}return[]}var jh=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.show=function(e){var t=this.context.view,n=this.context.event,r=t.getController("tooltip").getTooltipCfg(),a=Bh(t,{x:n.x,y:n.y},r);if(!(0,x.Xy)(a,this.items)&&(this.items=a,a.length)){var i=t.getXScale().field,o=a[0].data[i],s=[],l=t.geometries;if((0,x.S6)(l,(function(e){if("interval"===e.type||"schema"===e.type){var t=e.getElementsBy((function(e){return e.getData()[i]===o}));s=s.concat(t)}})),s.length){var u=t.getCoordinate(),c=s[0].shape.getCanvasBBox(),d=s[0].shape.getCanvasBBox(),p=c;(0,x.S6)(s,(function(e){var t=e.shape.getCanvasBBox();u.isTransposed?(t.minYd.maxY&&(d=t)):(t.minXd.maxX&&(d=t)),p.x=Math.min(t.minX,p.minX),p.y=Math.min(t.minY,p.minY),p.width=Math.max(t.maxX,p.maxX)-p.x,p.height=Math.max(t.maxY,p.maxY)-p.y}));var h=t.backgroundGroup,f=t.coordinateBBox,v=void 0;if(u.isRect){var m=t.getXScale(),g=e||{},I=g.appendRatio,_=g.appendWidth;(0,x.UM)(_)&&(I=(0,x.UM)(I)?m.isLinear?0:.25:I,_=u.isTransposed?I*d.height:I*c.width);var b=void 0,w=void 0,S=void 0,E=void 0;u.isTransposed?(b=f.minX,w=Math.min(d.minY,c.minY)-_,S=f.width,E=p.height+2*_):(b=Math.min(c.minX,d.minX)-_,w=f.minY,S=p.width+2*_,E=f.height),v=[["M",b,w],["L",b+S,w],["L",b+S,w+E],["L",b,w+E],["Z"]]}else{var C=(0,x.YM)(s),k=(0,x.Z$)(s),M=xi(C.getModel(),u).startAngle,T=xi(k.getModel(),u).endAngle,A=u.getCenter(),L=u.getRadius(),P=u.innerRadius*L;v=gi(A.x,A.y,L,M,T,P)}if(this.regionPath)this.regionPath.attr("path",v),this.regionPath.show();else{var O=(0,x.U2)(e,"style",Fh);this.regionPath=h.addShape({type:"path",name:"active-region",capture:!1,attrs:(0,y.pi)((0,y.pi)({},O),{path:v})})}}}},t.prototype.hide=function(){this.regionPath&&this.regionPath.hide(),this.items=null},t.prototype.destroy=function(){this.hide(),this.regionPath&&this.regionPath.remove(!0),e.prototype.destroy.call(this)},t}(Yi),Zh=jh,Uh=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.timeStamp=0,t}return(0,y.ZT)(t,e),t.prototype.show=function(){var e=this.context,t=e.event,n=e.view;if(!n.isTooltipLocked()){var r=this.timeStamp,a=+new Date;if(a-r>(0,x.U2)(e.view.getOptions(),"tooltip.showDelay",16)){var i=this.location,o={x:t.x,y:t.y};i&&(0,x.Xy)(i,o)||this.showTooltip(n,o),this.timeStamp=a,this.location=o}}},t.prototype.hide=function(){var e=this.context.view,t=e.getController("tooltip"),n=this.context.event,r=n.clientX,a=n.clientY;t.isCursorEntered({x:r,y:a})||e.isTooltipLocked()||(this.hideTooltip(e),this.location=null)},t.prototype.showTooltip=function(e,t){e.showTooltip(t)},t.prototype.hideTooltip=function(e){e.hideTooltip()},t}(Yi),Vh=Uh,Hh=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.showTooltip=function(e,t){var n=Eo(e);(0,x.S6)(n,(function(n){var r=Co(e,n,t);n.showTooltip(r)}))},t.prototype.hideTooltip=function(e){var t=Eo(e);(0,x.S6)(t,(function(e){e.hideTooltip()}))},t}(Vh),Gh=Hh,qh=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.timeStamp=0,t}return(0,y.ZT)(t,e),t.prototype.destroy=function(){e.prototype.destroy.call(this),this.tooltip&&this.tooltip.destroy()},t.prototype.show=function(){var e=this.context.event,t=this.timeStamp,n=+new Date;if(n-t>16){var r=this.location,a={x:e.x,y:e.y};r&&(0,x.Xy)(r,a)||this.showTooltip(a),this.timeStamp=n,this.location=a}},t.prototype.hide=function(){this.hideTooltip(),this.location=null},t.prototype.showTooltip=function(e){var t=this.context.event.target;if(t&&t.get("tip")){this.tooltip||this.renderTooltip();var n=t.get("tip");this.tooltip.update((0,y.pi)({title:n},e)),this.tooltip.show()}},t.prototype.hideTooltip=function(){this.tooltip&&this.tooltip.hide()},t.prototype.renderTooltip=function(){var e,t=this.context.view,n=t.canvas,r={start:{x:0,y:0},end:{x:n.get("width"),y:n.get("height")}},a=t.getTheme(),i=(0,x.U2)(a,["components","tooltip","domStyles"],{}),o=new hi({parent:n.get("el").parentNode,region:r,visible:!1,crosshairs:null,domStyles:(0,y.pi)({},(0,x.b$)({},i,(e={},e[Aa]={"max-width":"50%"},e[La]={"word-break":"break-all"},e)))});o.init(),o.setCapture(!1),this.tooltip=o},t}(Yi),Wh=qh,Yh=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.stateName="",t}return(0,y.ZT)(t,e),t.prototype.hasState=function(e){return e.hasState(this.stateName)},t.prototype.setElementState=function(e,t){e.setState(this.stateName,t)},t.prototype.setState=function(){this.setStateEnable(!0)},t.prototype.clear=function(){var e=this.context.view;this.clearViewState(e)},t.prototype.clearViewState=function(e){var t=this,n=yo(e,this.stateName);(0,x.S6)(n,(function(e){t.setElementState(e,!1)}))},t}(Yi),Xh=Yh;function Kh(e){return(0,x.U2)(e.get("delegateObject"),"item")}var Jh=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.ignoreListItemStates=["unchecked"],t}return(0,y.ZT)(t,e),t.prototype.isItemIgnore=function(e,t){var n=this.ignoreListItemStates.filter((function(n){return t.hasState(e,n)}));return!!n.length},t.prototype.setStateByComponent=function(e,t,n){var r=this.context.view,a=e.get("field"),i=go(r);this.setElementsStateByItem(i,a,t,n)},t.prototype.setStateByElement=function(e,t){this.setElementState(e,t)},t.prototype.isMathItem=function(e,t,n){var r=Mo(this.context.view,t),a=xo(e,t);return!(0,x.UM)(a)&&n.name===r.getText(a)},t.prototype.setElementsStateByItem=function(e,t,n,r){var a=this;(0,x.S6)(e,(function(e){a.isMathItem(e,t,n)&&e.setState(a.stateName,r)}))},t.prototype.setStateEnable=function(e){var t=lo(this.context);if(t)co(this.context)&&this.setStateByElement(t,e);else{var n=uo(this.context);if(po(n)){var r=n.item,a=n.component;if(r&&a&&!this.isItemIgnore(r,a)){var i=this.context.event.gEvent;if(i&&i.fromShape&&i.toShape&&Kh(i.fromShape)===Kh(i.toShape))return;this.setStateByComponent(a,r,e)}}}},t.prototype.toggle=function(){var e=lo(this.context);if(e){var t=e.hasState(this.stateName);this.setElementState(e,!t)}},t.prototype.reset=function(){this.setStateEnable(!1)},t}(Xh),$h=Jh,Qh=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.stateName="active",t}return(0,y.ZT)(t,e),t.prototype.active=function(){this.setState()},t}($h),ef=Qh,tf=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.cache={},t}return(0,y.ZT)(t,e),t.prototype.getColorScale=function(e,t){var n=t.geometry.getAttribute("color");return n?e.getScaleByField(n.getFields()[0]):null},t.prototype.getLinkPath=function(e,t){var n=this.context.view.getCoordinate().isTransposed,r=e.shape.getCanvasBBox(),a=t.shape.getCanvasBBox();return n?[["M",r.minX,r.minY],["L",a.minX,a.maxY],["L",a.maxX,a.maxY],["L",r.maxX,r.minY],["Z"]]:[["M",r.maxX,r.minY],["L",a.minX,a.minY],["L",a.minX,a.maxY],["L",r.maxX,r.maxY],["Z"]]},t.prototype.addLinkShape=function(e,t,n,r){var a={opacity:.4,fill:t.shape.attr("fill")};e.addShape({type:"path",attrs:(0,y.pi)((0,y.pi)({},(0,x.b$)({},a,(0,x.mf)(r)?r(a,t):r)),{path:this.getLinkPath(t,n)})})},t.prototype.linkByElement=function(e,t){var n=this,r=this.context.view,a=this.getColorScale(r,e);if(a){var i=xo(e,a.field);if(!this.cache[i]){var o=function(e,t,n){return go(e).filter((function(e){return xo(e,t)===n}))}(r,a.field,i),s=this.linkGroup.addGroup();this.cache[i]=s;var l=o.length;(0,x.S6)(o,(function(e,r){if(r=0}),t)},t}(af),Cf=Ef,kf=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.stateName="active",t}return(0,y.ZT)(t,e),t.prototype.highlight=function(){this.setState()},t.prototype.setElementState=function(e,t){vf(go(this.context.view),(function(t){return e===t}),t)},t.prototype.clear=function(){ff(this.context.view)},t}(uf),Mf=kf,Tf=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.stateName="selected",t}return(0,y.ZT)(t,e),t.prototype.selected=function(){this.setState()},t}(af),Af=Tf,Lf=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.stateName="selected",t}return(0,y.ZT)(t,e),t.prototype.selected=function(){this.setState()},t}($h),Pf=Lf,Of=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.stateName="selected",t}return(0,y.ZT)(t,e),t.prototype.selected=function(){this.setState()},t}(uf),Rf=Of,Df=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.stateName="",t.ignoreItemStates=[],t}return(0,y.ZT)(t,e),t.prototype.getTriggerListInfo=function(){var e=uo(this.context),t=null;return po(e)&&(t={item:e.item,list:e.component}),t},t.prototype.getAllowComponents=function(){var e=this,t=bo(this.context.view),n=[];return(0,x.S6)(t,(function(t){t.isList()&&e.allowSetStateByElement(t)&&n.push(t)})),n},t.prototype.hasState=function(e,t){return e.hasState(t,this.stateName)},t.prototype.clearAllComponentsState=function(){var e=this,t=this.getAllowComponents();(0,x.S6)(t,(function(t){t.clearItemsState(e.stateName)}))},t.prototype.allowSetStateByElement=function(e){var t=e.get("field");if(!t)return!1;if(this.cfg&&this.cfg.componentNames){var n=e.get("name");if(-1===this.cfg.componentNames.indexOf(n))return!1}var r=Mo(this.context.view,t);return r&&r.isCategory},t.prototype.allowSetStateByItem=function(e,t){var n=this.ignoreItemStates;if(n.length){var r=n.filter((function(n){return t.hasState(e,n)}));return 0===r.length}return!0},t.prototype.setStateByElement=function(e,t,n){var r=e.get("field"),a=Mo(this.context.view,r),i=xo(t,r),o=a.getText(i);this.setItemsState(e,o,n)},t.prototype.setStateEnable=function(e){var t=this,n=lo(this.context);if(n){var r=this.getAllowComponents();(0,x.S6)(r,(function(r){t.setStateByElement(r,n,e)}))}else{var a=uo(this.context);if(po(a)){var i=a.item,o=a.component;this.allowSetStateByElement(o)&&this.allowSetStateByItem(i,o)&&this.setItemState(o,i,e)}}},t.prototype.setItemsState=function(e,t,n){var r=this,a=e.getItems();(0,x.S6)(a,(function(a){a.name===t&&r.setItemState(e,a,n)}))},t.prototype.setItemState=function(e,t,n){e.setItemState(t,this.stateName,n)},t.prototype.setState=function(){this.setStateEnable(!0)},t.prototype.reset=function(){this.setStateEnable(!1)},t.prototype.toggle=function(){var e=this.getTriggerListInfo();if(e&&e.item){var t=e.list,n=e.item,r=this.hasState(t,n);this.setItemState(t,n,!r)}},t.prototype.clear=function(){var e=this.getTriggerListInfo();e?e.list.clearItemsState(this.stateName):this.clearAllComponentsState()},t}(Yi),Nf=Df,zf=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.stateName="active",t}return(0,y.ZT)(t,e),t.prototype.active=function(){this.setState()},t}(Nf),Ff=zf,Bf="inactive",jf="active";var Zf="inactive",Uf="active",Vf=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.stateName=Uf,t.ignoreItemStates=["unchecked"],t}return(0,y.ZT)(t,e),t.prototype.setItemsState=function(e,t,n){this.setHighlightBy(e,(function(e){return e.name===t}),n)},t.prototype.setItemState=function(e,t,n){e.getItems();this.setHighlightBy(e,(function(e){return e===t}),n)},t.prototype.setHighlightBy=function(e,t,n){var r=e.getItems();if(n)(0,x.S6)(r,(function(n){t(n)?(e.hasState(n,Zf)&&e.setItemState(n,Zf,!1),e.setItemState(n,Uf,!0)):e.hasState(n,Uf)||e.setItemState(n,Zf,!0)}));else{var a=e.getItemsByState(Uf),i=!0;(0,x.S6)(a,(function(e){if(!t(e))return i=!1,!1})),i?this.clear():(0,x.S6)(r,(function(n){t(n)&&(e.hasState(n,Uf)&&e.setItemState(n,Uf,!1),e.setItemState(n,Zf,!0))}))}},t.prototype.highlight=function(){this.setState()},t.prototype.clear=function(){var e=this.getTriggerListInfo();if(e)!function(e){var t=e.getItems();(0,x.S6)(t,(function(t){e.hasState(t,jf)&&e.setItemState(t,jf,!1),e.hasState(t,Bf)&&e.setItemState(t,Bf,!1)}))}(e.list);else{var t=this.getAllowComponents();(0,x.S6)(t,(function(e){e.clearItemsState(Uf),e.clearItemsState(Zf)}))}},t}(Nf),Hf=Vf,Gf=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.stateName="selected",t}return(0,y.ZT)(t,e),t.prototype.selected=function(){this.setState()},t}(Nf),qf=Gf,Wf=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.stateName="unchecked",t}return(0,y.ZT)(t,e),t.prototype.unchecked=function(){this.setState()},t}(Nf),Yf=Wf,Xf="unchecked",Kf="checked",Jf=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.stateName=Kf,t}return(0,y.ZT)(t,e),t.prototype.setItemState=function(e,t,n){this.setCheckedBy(e,(function(e){return e===t}),n)},t.prototype.setCheckedBy=function(e,t,n){var r=e.getItems();n&&(0,x.S6)(r,(function(n){t(n)?(e.hasState(n,Xf)&&e.setItemState(n,Xf,!1),e.setItemState(n,Kf,!0)):e.hasState(n,Kf)||e.setItemState(n,Xf,!0)}))},t.prototype.toggle=function(){var e=this.getTriggerListInfo();if(e&&e.item){var t=e.list,n=e.item;!(0,x.G)(t.getItems(),(function(e){return t.hasState(e,Xf)}))||t.hasState(n,Xf)?this.setItemState(t,n,!0):this.reset()}},t.prototype.checked=function(){this.setState()},t.prototype.reset=function(){var e=this.getAllowComponents();(0,x.S6)(e,(function(e){e.clearItemsState(Kf),e.clearItemsState(Xf)}))},t}(Nf),$f=Jf,Qf="unchecked",ev=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.toggle=function(){var e,t,n,r,a,i,o,s,l=this.getTriggerListInfo();if(null==l?void 0:l.item){var u=l.list,c=l.item,d=u.getItems(),p=d.filter((function(e){return!u.hasState(e,Qf)})),h=d.filter((function(e){return u.hasState(e,Qf)})),f=p[0];if(d.length===p.length)try{for(var v=(0,y.XA)(d),m=v.next();!m.done;m=v.next()){var g=m.value;u.setItemState(g,Qf,g.id!==c.id)}}catch(t){e={error:t}}finally{try{m&&!m.done&&(t=v.return)&&t.call(v)}finally{if(e)throw e.error}}else if(d.length-h.length==1)if(f.id===c.id)try{for(var x=(0,y.XA)(d),I=x.next();!I.done;I=x.next()){g=I.value;u.setItemState(g,Qf,!1)}}catch(e){n={error:e}}finally{try{I&&!I.done&&(r=x.return)&&r.call(x)}finally{if(n)throw n.error}}else try{for(var _=(0,y.XA)(d),b=_.next();!b.done;b=_.next()){g=b.value;u.setItemState(g,Qf,g.id!==c.id)}}catch(e){a={error:e}}finally{try{b&&!b.done&&(i=_.return)&&i.call(_)}finally{if(a)throw a.error}}else try{for(var w=(0,y.XA)(d),S=w.next();!S.done;S=w.next()){g=S.value;u.setItemState(g,Qf,g.id!==c.id)}}catch(e){o={error:e}}finally{try{S&&!S.done&&(s=w.return)&&s.call(w)}finally{if(o)throw o.error}}}},t}(Nf),tv=ev,nv="showRadio",rv="legend-radio-tip",av=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.timeStamp=0,t}return(0,y.ZT)(t,e),t.prototype.show=function(){var e=this.getTriggerListInfo();if(null==e?void 0:e.item){var t=e.list,n=e.item;t.setItemState(n,nv,!0)}},t.prototype.hide=function(){var e=this.getTriggerListInfo();if(null==e?void 0:e.item){var t=e.list,n=e.item;t.setItemState(n,nv,!1)}},t.prototype.destroy=function(){e.prototype.destroy.call(this),this.tooltip&&this.tooltip.destroy()},t.prototype.showTip=function(){var e=this.context.event,t=this.timeStamp,n=+new Date,r=this.context.event.target;if(n-t>16&&"legend-item-radio"===r.get("name")){var a=this.location,i={x:e.x,y:e.y};this.timeStamp=n,this.location=i,a&&(0,x.Xy)(a,i)||this.showTooltip(i)}},t.prototype.hideTip=function(){this.hideTooltip(),this.location=null},t.prototype.showTooltip=function(e){var t=this.context,n=t.event.target;if(n&&n.get("tip")){this.tooltip||this.renderTooltip();var r=t.view.getCanvas().get("el").getBoundingClientRect(),a=r.x,i=r.y;this.tooltip.update((0,y.pi)((0,y.pi)({title:n.get("tip")},e),{x:e.x+a,y:e.y+i})),this.tooltip.show()}},t.prototype.hideTooltip=function(){this.tooltip&&this.tooltip.hide()},t.prototype.renderTooltip=function(){var e,t=((e={})[Aa]={padding:"6px 8px",transform:"translate(-50%, -80%)",background:"rgba(0,0,0,0.75)",color:"#fff","border-radius":"2px","z-index":100},e[La]={"font-size":"12px","line-height":"14px","margin-bottom":0,"word-break":"break-all"},e);document.getElementById(rv)&&document.body.removeChild(document.getElementById(rv));var n=new hi({parent:document.body,region:null,visible:!1,crosshairs:null,domStyles:t,containerId:rv});n.init(),n.setCapture(!1),this.tooltip=n},t}(Nf),iv=av,ov=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.maskShape=null,t.points=[],t.starting=!1,t.moving=!1,t.preMovePoint=null,t.shapeType="path",t}return(0,y.ZT)(t,e),t.prototype.getCurrentPoint=function(){var e=this.context.event;return{x:e.x,y:e.y}},t.prototype.emitEvent=function(e){var t="mask:".concat(e),n=this.context.view,r=this.context.event;n.emit(t,{target:this.maskShape,shape:this.maskShape,points:this.points,x:r.x,y:r.y})},t.prototype.createMask=function(){var e=this.context.view,t=this.getMaskAttrs();return e.foregroundGroup.addShape({type:this.shapeType,name:"mask",draggable:!0,attrs:(0,y.pi)({fill:"#C5D4EB",opacity:.3},t)})},t.prototype.getMaskPath=function(){return[]},t.prototype.show=function(){this.maskShape&&(this.maskShape.show(),this.emitEvent("show"))},t.prototype.start=function(e){this.starting=!0,this.moving=!1,this.points=[this.getCurrentPoint()],this.maskShape||(this.maskShape=this.createMask(),this.maskShape.set("capture",!1)),this.updateMask(null==e?void 0:e.maskStyle),this.emitEvent("start")},t.prototype.moveStart=function(){this.moving=!0,this.preMovePoint=this.getCurrentPoint()},t.prototype.move=function(){if(this.moving&&this.maskShape){var e=this.getCurrentPoint(),t=this.preMovePoint,n=e.x-t.x,r=e.y-t.y,a=this.points;(0,x.S6)(a,(function(e){e.x+=n,e.y+=r})),this.updateMask(),this.emitEvent("change"),this.preMovePoint=e}},t.prototype.updateMask=function(e){var t=(0,x.b$)({},this.getMaskAttrs(),e);this.maskShape.attr(t)},t.prototype.moveEnd=function(){this.moving=!1,this.preMovePoint=null},t.prototype.end=function(){this.starting=!1,this.emitEvent("end"),this.maskShape&&this.maskShape.set("capture",!0)},t.prototype.hide=function(){this.maskShape&&(this.maskShape.hide(),this.emitEvent("hide"))},t.prototype.resize=function(){this.starting&&this.maskShape&&(this.points.push(this.getCurrentPoint()),this.updateMask(),this.emitEvent("change"))},t.prototype.destroy=function(){this.points=[],this.maskShape&&this.maskShape.remove(),this.maskShape=null,this.preMovePoint=null,e.prototype.destroy.call(this)},t}(Yi),sv=ov,lv=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.shapeType="circle",t}return(0,y.ZT)(t,e),t.prototype.getMaskAttrs=function(){var e=this.points,t=(0,x.Z$)(this.points),n=0,r=0,a=0;if(e.length){var i=e[0];n=wo(i,t)/2,r=(t.x+i.x)/2,a=(t.y+i.y)/2}return{x:r,y:a,r:n}},t}(sv),uv=lv,cv=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.shapeType="rect",t}return(0,y.ZT)(t,e),t.prototype.getRegion=function(){var e=this.points;return{start:(0,x.YM)(e),end:(0,x.Z$)(e)}},t.prototype.getMaskAttrs=function(){var e=this.getRegion(),t=e.start,n=e.end;return{x:Math.min(t.x,n.x),y:Math.min(t.y,n.y),width:Math.abs(n.x-t.x),height:Math.abs(n.y-t.y)}},t}(sv),dv=cv;function pv(e){e.x=(0,x.uZ)(e.x,0,1),e.y=(0,x.uZ)(e.y,0,1)}var hv,fv=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.dim="x",t.inPlot=!0,t}return(0,y.ZT)(t,e),t.prototype.getRegion=function(){var e=null,t=null,n=this.points,r=this.dim,a=this.context.view.getCoordinate(),i=a.invert((0,x.YM)(n)),o=a.invert((0,x.Z$)(n));return this.inPlot&&(pv(i),pv(o)),"x"===r?(e=a.convert({x:i.x,y:0}),t=a.convert({x:o.x,y:1})):(e=a.convert({x:0,y:i.y}),t=a.convert({x:1,y:o.y})),{start:e,end:t}},t}(dv),vv=fv,mv=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getMaskPath=function(){var e=this.points,t=[];return e.length&&((0,x.S6)(e,(function(e,n){0===n?t.push(["M",e.x,e.y]):t.push(["L",e.x,e.y])})),t.push(["L",e[0].x,e[0].y])),t},t.prototype.getMaskAttrs=function(){return{path:this.getMaskPath()}},t.prototype.addPoint=function(){this.resize()},t}(sv),gv=mv,yv=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.getMaskPath=function(){return function(e,t){if(e.length<=2)return ao(e,!1);var n=e[0],r=[];(0,x.S6)(e,(function(e){r.push(e.x),r.push(e.y)}));var a=ro(r,t,null);return a.unshift(["M",n.x,n.y]),a}(this.points,!0)},t}(gv),xv=yv,Iv=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.setCursor=function(e){this.context.view.getCanvas().setCursor(e)},t.prototype.default=function(){this.setCursor("default")},t.prototype.pointer=function(){this.setCursor("pointer")},t.prototype.move=function(){this.setCursor("move")},t.prototype.crosshair=function(){this.setCursor("crosshair")},t.prototype.wait=function(){this.setCursor("wait")},t.prototype.help=function(){this.setCursor("help")},t.prototype.text=function(){this.setCursor("text")},t.prototype.eResize=function(){this.setCursor("e-resize")},t.prototype.wResize=function(){this.setCursor("w-resize")},t.prototype.nResize=function(){this.setCursor("n-resize")},t.prototype.sResize=function(){this.setCursor("s-resize")},t.prototype.neResize=function(){this.setCursor("ne-resize")},t.prototype.nwResize=function(){this.setCursor("nw-resize")},t.prototype.seResize=function(){this.setCursor("se-resize")},t.prototype.swResize=function(){this.setCursor("sw-resize")},t.prototype.nsResize=function(){this.setCursor("ns-resize")},t.prototype.ewResize=function(){this.setCursor("ew-resize")},t.prototype.zoomIn=function(){this.setCursor("zoom-in")},t.prototype.zoomOut=function(){this.setCursor("zoom-out")},t}(Yi),_v=Iv,bv=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.filterView=function(e,t,n){var r=this;e.getScaleByField(t)&&e.filter(t,n),e.views&&e.views.length&&(0,x.S6)(e.views,(function(e){r.filterView(e,t,n)}))},t.prototype.filter=function(){var e=uo(this.context);if(e){var t=this.context.view,n=e.component,r=n.get("field");if(po(e)){if(r){var a=n.getItemsByState("unchecked"),i=Mo(t,r),o=a.map((function(e){return e.name}));o.length?this.filterView(t,r,(function(e){var t=i.getText(e);return!o.includes(t)})):this.filterView(t,r,null),t.render(!0)}}else if(ho(e)){var s=n.getValue(),l=(0,y.CR)(s,2),u=l[0],c=l[1];this.filterView(t,r,(function(e){return e>=u&&e<=c})),t.render(!0)}}},t}(Yi),wv=bv;function Sv(e,t,n,r){var a=Math.min(n[t],r[t]),i=Math.max(n[t],r[t]),o=(0,y.CR)(e.range,2),s=o[0],l=o[1];if(al&&(i=l),a===l&&i===l)return null;var u=e.invert(a),c=e.invert(i);if(e.isCategory){var d=e.values.indexOf(u),p=e.values.indexOf(c),h=e.values.slice(d,p+1);return function(e){return h.includes(e)}}return function(e){return e>=u&&e<=c}}!function(e){e.FILTER="brush-filter-processing",e.RESET="brush-filter-reset",e.BEFORE_FILTER="brush-filter:beforefilter",e.AFTER_FILTER="brush-filter:afterfilter",e.BEFORE_RESET="brush-filter:beforereset",e.AFTER_RESET="brush-filter:afterreset"}(hv||(hv={}));var Ev=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.dims=["x","y"],t.startPoint=null,t.isStarted=!1,t}return(0,y.ZT)(t,e),t.prototype.hasDim=function(e){return this.dims.includes(e)},t.prototype.start=function(){var e=this.context;this.isStarted=!0,this.startPoint=e.getCurrentPoint()},t.prototype.filter=function(){var e,t;if(fo(this.context)){var n=this.context.event.target.getCanvasBBox();e={x:n.x,y:n.y},t={x:n.maxX,y:n.maxY}}else{if(!this.isStarted)return;e=this.startPoint,t=this.context.getCurrentPoint()}if(!(Math.abs(e.x-t.x)<5||Math.abs(e.x-t.y)<5)){var r=this.context,a=r.view,i={view:a,event:r.event,dims:this.dims};a.emit(hv.BEFORE_FILTER,ws.fromData(a,hv.BEFORE_FILTER,i));var o=a.getCoordinate(),s=o.invert(t),l=o.invert(e);if(this.hasDim("x")){var u=a.getXScale(),c=Sv(u,"x",s,l);this.filterView(a,u.field,c)}if(this.hasDim("y")){var d=a.getYScales()[0];c=Sv(d,"y",s,l);this.filterView(a,d.field,c)}this.reRender(a,{source:hv.FILTER}),a.emit(hv.AFTER_FILTER,ws.fromData(a,hv.AFTER_FILTER,i))}},t.prototype.end=function(){this.isStarted=!1},t.prototype.reset=function(){var e=this.context.view;if(e.emit(hv.BEFORE_RESET,ws.fromData(e,hv.BEFORE_RESET,{})),this.isStarted=!1,this.hasDim("x")){var t=e.getXScale();this.filterView(e,t.field,null)}if(this.hasDim("y")){var n=e.getYScales()[0];this.filterView(e,n.field,null)}this.reRender(e,{source:hv.RESET}),e.emit(hv.AFTER_RESET,ws.fromData(e,hv.AFTER_RESET,{}))},t.prototype.filterView=function(e,t,n){e.filter(t,n)},t.prototype.reRender=function(e,t){e.render(!0,t)},t}(Yi),Cv=Ev,kv=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.filterView=function(e,t,n){var r=Eo(e);(0,x.S6)(r,(function(e){e.filter(t,n)}))},t.prototype.reRender=function(e){var t=Eo(e);(0,x.S6)(t,(function(e){e.render(!0)}))},t}(Cv),Mv=kv,Tv=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.filter=function(){var e=uo(this.context),t=this.context.view,n=go(t);if(fo(this.context)){var r=vo(this.context,10);r&&(0,x.S6)(n,(function(e){r.includes(e)?e.show():e.hide()}))}else if(e){var a=e.component,i=a.get("field");if(po(e)){if(i){var o=a.getItemsByState("unchecked"),s=Mo(t,i),l=o.map((function(e){return e.name}));(0,x.S6)(n,(function(e){var t=xo(e,i),n=s.getText(t);l.indexOf(n)>=0?e.hide():e.show()}))}}else if(ho(e)){var u=a.getValue(),c=(0,y.CR)(u,2),d=c[0],p=c[1];(0,x.S6)(n,(function(e){var t=xo(e,i);t>=d&&t<=p?e.show():e.hide()}))}}},t.prototype.clear=function(){var e=go(this.context.view);(0,x.S6)(e,(function(e){e.show()}))},t.prototype.reset=function(){this.clear()},t}(Yi),Av=Tv,Lv=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.byRecord=!1,t}return(0,y.ZT)(t,e),t.prototype.filter=function(){fo(this.context)&&(this.byRecord?this.filterByRecord():this.filterByBBox())},t.prototype.filterByRecord=function(){var e=this.context.view,t=vo(this.context,10);if(t){var n=e.getXScale().field,r=e.getYScales()[0].field,a=t.map((function(e){return e.getModel().data})),i=Eo(e);(0,x.S6)(i,(function(e){var t=go(e);(0,x.S6)(t,(function(e){var t=e.getModel().data;ko(a,t,n,r)?e.show():e.hide()}))}))}},t.prototype.filterByBBox=function(){var e=this,t=Eo(this.context.view);(0,x.S6)(t,(function(t){var n=mo(e.context,t,10),r=go(t);n&&(0,x.S6)(r,(function(e){n.includes(e)?e.show():e.hide()}))}))},t.prototype.reset=function(){var e=Eo(this.context.view);(0,x.S6)(e,(function(e){var t=go(e);(0,x.S6)(t,(function(e){e.show()}))}))},t}(Yi),Pv=Lv,Ov=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.buttonGroup=null,t.buttonCfg={name:"button",text:"button",textStyle:{x:0,y:0,fontSize:12,fill:"#333333",cursor:"pointer"},padding:[8,10],style:{fill:"#f7f7f7",stroke:"#cccccc",cursor:"pointer"},activeStyle:{fill:"#e6e6e6"}},t}return(0,y.ZT)(t,e),t.prototype.getButtonCfg=function(){return(0,x.b$)(this.buttonCfg,this.cfg)},t.prototype.drawButton=function(){var e=this.getButtonCfg(),t=this.context.view.foregroundGroup.addGroup({name:e.name}),n=t.addShape({type:"text",name:"button-text",attrs:(0,y.pi)({text:e.text},e.textStyle)}).getBBox(),r=gs(e.padding),a=t.addShape({type:"rect",name:"button-rect",attrs:(0,y.pi)({x:n.x-r[3],y:n.y-r[0],width:n.width+r[1]+r[3],height:n.height+r[0]+r[2]},e.style)});a.toBack(),t.on("mouseenter",(function(){a.attr(e.activeStyle)})),t.on("mouseleave",(function(){a.attr(e.style)})),this.buttonGroup=t},t.prototype.resetPosition=function(){var e=this.context.view.getCoordinate().convert({x:1,y:1}),t=this.buttonGroup,n=t.getBBox(),r=vn.vs(null,[["t",e.x-n.width-10,e.y+n.height+5]]);t.setMatrix(r)},t.prototype.show=function(){this.buttonGroup||this.drawButton(),this.resetPosition(),this.buttonGroup.show()},t.prototype.hide=function(){this.buttonGroup&&this.buttonGroup.hide()},t.prototype.destroy=function(){var t=this.buttonGroup;t&&t.remove(),e.prototype.destroy.call(this)},t}(Yi),Rv=Ov,Dv=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.starting=!1,t.dragStart=!1,t}return(0,y.ZT)(t,e),t.prototype.start=function(){this.starting=!0,this.startPoint=this.context.getCurrentPoint()},t.prototype.drag=function(){if(this.startPoint){var e=this.context.getCurrentPoint(),t=this.context.view,n=this.context.event;this.dragStart?t.emit("drag",{target:n.target,x:n.x,y:n.y}):wo(e,this.startPoint)>4&&(t.emit("dragstart",{target:n.target,x:n.x,y:n.y}),this.dragStart=!0)}},t.prototype.end=function(){if(this.dragStart){var e=this.context.view,t=this.context.event;e.emit("dragend",{target:t.target,x:t.x,y:t.y})}this.starting=!1,this.dragStart=!1},t}(Yi),Nv=Dv,zv=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.starting=!1,t.isMoving=!1,t.startPoint=null,t.startMatrix=null,t}return(0,y.ZT)(t,e),t.prototype.start=function(){this.starting=!0,this.startPoint=this.context.getCurrentPoint(),this.startMatrix=this.context.view.middleGroup.getMatrix()},t.prototype.move=function(){if(this.starting){var e=this.startPoint,t=this.context.getCurrentPoint();if(wo(e,t)>5&&!this.isMoving&&(this.isMoving=!0),this.isMoving){var n=this.context.view,r=vn.vs(this.startMatrix,[["t",t.x-e.x,t.y-e.y]]);n.backgroundGroup.setMatrix(r),n.foregroundGroup.setMatrix(r),n.middleGroup.setMatrix(r)}}},t.prototype.end=function(){this.isMoving&&(this.isMoving=!1),this.startMatrix=null,this.starting=!1,this.startPoint=null},t.prototype.reset=function(){this.starting=!1,this.startPoint=null,this.isMoving=!1;var e=this.context.view;e.backgroundGroup.resetMatrix(),e.foregroundGroup.resetMatrix(),e.middleGroup.resetMatrix(),this.isMoving=!1},t}(Yi),Fv=zv,Bv=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.dims=["x","y"],t.cfgFields=["dims"],t.cacheScaleDefs={},t}return(0,y.ZT)(t,e),t.prototype.hasDim=function(e){return this.dims.includes(e)},t.prototype.getScale=function(e){var t=this.context.view;return"x"===e?t.getXScale():t.getYScales()[0]},t.prototype.resetDim=function(e){var t=this.context.view;if(this.hasDim(e)&&this.cacheScaleDefs[e]){var n=this.getScale(e);t.scale(n.field,this.cacheScaleDefs[e]),this.cacheScaleDefs[e]=null}},t.prototype.reset=function(){this.resetDim("x"),this.resetDim("y"),this.context.view.render(!0)},t}(Yi),jv=Bv,Zv=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.startPoint=null,t.starting=!1,t.startCache={},t}return(0,y.ZT)(t,e),t.prototype.start=function(){var e=this;this.startPoint=this.context.getCurrentPoint(),this.starting=!0;var t=this.dims;(0,x.S6)(t,(function(t){var n=e.getScale(t),r=n.min,a=n.max,i=n.values;e.startCache[t]={min:r,max:a,values:i}}))},t.prototype.end=function(){this.startPoint=null,this.starting=!1,this.startCache={}},t.prototype.translate=function(){var e=this;if(this.starting){var t=this.startPoint,n=this.context.view.getCoordinate(),r=this.context.getCurrentPoint(),a=n.invert(t),i=n.invert(r),o=i.x-a.x,s=i.y-a.y,l=this.context.view,u=this.dims;(0,x.S6)(u,(function(t){e.translateDim(t,{x:-1*o,y:-1*s})})),l.render(!0)}},t.prototype.translateDim=function(e,t){if(this.hasDim(e)){var n=this.getScale(e);n.isLinear&&this.translateLinear(e,n,t)}},t.prototype.translateLinear=function(e,t,n){var r=this.context.view,a=this.startCache[e],i=a.min,o=a.max,s=o-i,l=n[e]*s;this.cacheScaleDefs[e]||(this.cacheScaleDefs[e]={nice:t.nice,min:i,max:o}),r.scale(t.field,{nice:!1,min:i+l,max:o+l})},t.prototype.reset=function(){e.prototype.reset.call(this),this.startPoint=null,this.starting=!1},t}(jv),Uv=Zv,Vv=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.zoomRatio=.05,t}return(0,y.ZT)(t,e),t.prototype.zoomIn=function(){this.zoom(this.zoomRatio)},t.prototype.zoom=function(e){var t=this,n=this.dims;(0,x.S6)(n,(function(n){t.zoomDim(n,e)})),this.context.view.render(!0)},t.prototype.zoomOut=function(){this.zoom(-1*this.zoomRatio)},t.prototype.zoomDim=function(e,t){if(this.hasDim(e)){var n=this.getScale(e);n.isLinear&&this.zoomLinear(e,n,t)}},t.prototype.zoomLinear=function(e,t,n){var r=this.context.view;this.cacheScaleDefs[e]||(this.cacheScaleDefs[e]={nice:t.nice,min:t.min,max:t.max});var a=this.cacheScaleDefs[e],i=a.max-a.min,o=t.min,s=t.max,l=n*i,u=o-l,c=s+l,d=(c-u)/i;c>u&&d<100&&d>.01&&r.scale(t.field,{nice:!1,min:o-l,max:s+l})},t}(jv),Hv=Vv;var Gv=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.scroll=function(e){var t=this.context,n=t.view,r=t.event;if(n.getOptions().scrollbar){var a=(null==e?void 0:e.wheelDelta)||1,i=n.getController("scrollbar"),o=n.getXScale(),s=n.getOptions().data,l=(0,x.dp)((0,x.I)(s,o.field)),u=(0,x.dp)(o.values),c=i.getValue(),d=Math.floor((l-u)*c)+(function(e){return e.gEvent.originalEvent.deltaY>0}(r)?a:-a),p=a/(l-u)/1e4,h=(0,x.uZ)(d/(l-u)+p,0,1);i.setValue(h)}},t}(Yi),qv=Gv,Wv=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,y.ZT)(t,e),t.prototype.show=function(){var e=this.context,t=uo(e).axis.cfg.title,n=t.description,r=t.text,a=t.descriptionTooltipStyle,i=e.event,o=i.x,s=i.y;this.tooltip||this.renderTooltip(),this.tooltip.update({title:r||"",customContent:function(){return'\n
    \n
    \n 字段说明:').concat(n,"\n
    \n
    \n ")},x:o,y:s}),this.tooltip.show()},t.prototype.destroy=function(){e.prototype.destroy.call(this),this.tooltip&&this.tooltip.destroy()},t.prototype.hide=function(){this.tooltip&&this.tooltip.hide()},t.prototype.renderTooltip=function(){var e,t=this.context.view.canvas,n={start:{x:0,y:0},end:{x:t.get("width"),y:t.get("height")}},r=new hi({parent:t.get("el").parentNode,region:n,visible:!1,containerId:"aixs-description-tooltip",domStyles:(0,y.pi)({},(0,x.b$)({},(e={},e[Aa]={"max-width":"50%",padding:"10px","line-height":"15px","font-size":"12px",color:"rgba(0, 0, 0, .65)"},e[La]={"word-break":"break-all","margin-bottom":"3px"},e)))});r.init(),r.setCapture(!1),this.tooltip=r},t}(Yi),Yv=Wv;function Xv(e){return e.isInPlot()}function Kv(e){return e.gEvent.preventDefault(),e.gEvent.originalEvent.deltaY>0}ss("dark",Go(nu)),L("canvas",p),L("svg",f),As("Polygon",op),As("Interval",$d),As("Schema",lp),As("Path",Rd),As("Point",ap),As("Line",ep),As("Area",Bd),As("Edge",Zd),As("Heatmap",Vd),As("Violin",cp),Js("base",bl),Js("interval",_p),Js("pie",Cp),Js("polar",Sp),Qs("overlap",(function(e,t,n,r){var a=new Mp;(0,x.S6)(t,(function(e){for(var t=e.find((function(e){return"text"===e.get("type")})),n=t.attr(),r=n.x,i=n.y,o=!1,s=0;s<=8;s++){var l=Tp(t,r,i,s);if(a.hasGap(l)){a.fillGap(l),o=!0;break}}o||e.remove(!0)})),a.destroy()})),Qs("distribute",(function(e,t,n,r){if(e.length&&t.length){var a=e[0]?e[0].offset:0,i=t[0].get("coordinate"),o=i.getRadius(),s=i.getCenter();if(a>0){var l=2*(o+a)+28,u={start:i.start,end:i.end},c=[[],[]];e.forEach((function(e){e&&("right"===e.textAlign?c[0].push(e):c[1].push(e))})),c.forEach((function(e,n){var r=l/14;e.length>r&&(e.sort((function(e,t){return t["..percent"]-e["..percent"]})),e.splice(r,e.length-r)),e.sort((function(e,t){return e.y-t.y})),function(e,t,n,r,a,i){var o,s,l,u=!0,c=r.start,d=r.end,p=Math.min(c.y,d.y),h=Math.abs(c.y-d.y),f=0,v=Number.MIN_VALUE,m=t.map((function(e){return e.y>f&&(f=e.y),e.yh&&(h=f-p);u;)for(m.forEach((function(e){var t=(Math.min.apply(v,e.targets)+Math.max.apply(v,e.targets))/2;e.pos=Math.min(Math.max(v,t-e.size/2),h-e.size)})),u=!1,l=m.length;l--;)if(l>0){var g=m[l-1],I=m[l];g.pos+g.size>I.pos&&(g.size+=I.size,g.targets=g.targets.concat(I.targets),g.pos+g.size>h&&(g.pos=h-g.size),m.splice(l,1),u=!0)}l=0,m.forEach((function(e){var r=p+n/2;e.targets.forEach((function(){t[l].y=e.pos+r,r+=n,l++}))}));var _={};try{for(var b=(0,y.XA)(e),w=b.next();!w.done;w=b.next()){var S=w.value;_[S.get("id")]=S}}catch(e){o={error:e}}finally{try{w&&!w.done&&(s=b.return)&&s.call(b)}finally{if(o)throw o.error}}t.forEach((function(e){var t=e.r*e.r,n=Math.pow(Math.abs(e.y-a.y),2);if(ta.maxX||r.maxY>a.maxY)&&e.remove(!0)}))})),Qs("limit-in-canvas",(function(e,t,n,r){(0,x.S6)(t,(function(e){var t=r.minX,n=r.minY,a=r.maxX,i=r.maxY,o=e.getCanvasBBox(),s=o.minX,l=o.minY,u=o.maxX,c=o.maxY,d=o.x,p=o.y,h=o.width,f=o.height,v=d,m=p;(sa?v=a-h:u>a&&(v-=u-a),l>i?m=i-f:c>i&&(m-=c-i),v===d&&m===p||pl(e,v-d,m-p)}))})),Qs("limit-in-plot",(function(e,t,n,r,a){if(!(t.length<=0)){var i=(null==a?void 0:a.direction)||["top","right","bottom","left"],o=(null==a?void 0:a.action)||"translate",s=(null==a?void 0:a.margin)||0,l=t[0].get("coordinate");if(l){var u=function(e,t){void 0===t&&(t=0);var n=e.start,r=e.end,a=e.getWidth(),i=e.getHeight(),o=Math.min(n.x,r.x),s=Math.min(n.y,r.y);return Si.fromRange(o-t,s-t,o+a+t,s+i+t)}(l,s),c=u.minX,d=u.minY,p=u.maxX,h=u.maxY;(0,x.S6)(t,(function(e){var t=e.getCanvasBBox(),n=t.minX,r=t.minY,a=t.maxX,s=t.maxY,l=t.x,u=t.y,f=t.width,v=t.height,m=l,g=u;if(i.indexOf("left")>=0&&(n=0&&(r=0&&(n>p?m=p-f:a>p&&(m-=a-p)),i.indexOf("bottom")>=0&&(r>h?g=h-v:s>h&&(g-=s-h)),m!==l||g!==u){var y=m-l;if("translate"===o)pl(e,y,g-u);else if("ellipsis"===o){var I=e.findAll((function(e){return"text"===e.get("type")}));I.forEach((function(e){var t=(0,x.ei)(e.attr(),["fontSize","fontFamily","fontWeight","fontStyle","fontVariant"]),n=e.getCanvasBBox(),r=function(e,t,n){var r,a=Kp("...",n);r=(0,x.HD)(e)?e:(0,x.BB)(e);var i,o,s=t,l=[];if(Kp(e,n)<=t)return e;for(;i=r.substr(0,16),!((o=Kp(i,n))+a>s&&o>s);)if(l.push(i),s-=o,!(r=r.substr(16)))return l.join("");for(;i=r.substr(0,1),!((o=Kp(i,n))+a>s);)if(l.push(i),s-=o,!(r=r.substr(1)))return l.join("");return"".concat(l.join(""),"...")}(e.attr("text"),n.width-Math.abs(y),t);e.attr("text",r)}))}else e.hide()}}))}}})),Qs("pie-outer",(function(e,t,n,r){var a,i,o=(0,x.hX)(e,(function(e){return!(0,x.UM)(e)})),s=t[0]&&t[0].get("coordinate");if(s){var l=s.getCenter(),u=s.getRadius(),c={};try{for(var d=(0,y.XA)(t),p=d.next();!p.done;p=d.next()){var h=p.value;c[h.get("id")]=h}}catch(e){a={error:e}}finally{try{p&&!p.done&&(i=d.return)&&i.call(d)}finally{if(a)throw a.error}}var f=(0,x.U2)(o[0],"labelHeight",14),v=(0,x.U2)(o[0],"offset",0);if(!(v<=0)){var m="right",g=(0,x.vM)(o,(function(e){return e.xn&&(e.sort((function(e,t){return t.percent-e.percent})),(0,x.S6)(e,(function(e,t){t+1>n&&(c[e.id].set("visible",!1),e.invisible=!0)}))),kp(e,f,S)})),(0,x.S6)(g,(function(e,t){(0,x.S6)(e,(function(e){var n=t===m,r=c[e.id].getChildByIndex(0);if(r){var a=u+v,i=e.y-l.y,o=Math.pow(a,2),d=Math.pow(i,2),p=o-d>0?o-d:0,h=Math.sqrt(p),f=Math.abs(Math.cos(e.angle)*a);e.x=n?l.x+Math.max(h,f):l.x-Math.max(h,f)}r&&(r.attr("y",e.y),r.attr("x",e.x)),function(e,t){var n=t.getCenter(),r=t.getRadius();if(e&&e.labelLine){var a=e.angle,i=e.offset,o=mi(n.x,n.y,r,a),s=e.x+(0,x.U2)(e,"offsetX",0)*(Math.cos(a)>0?1:-1),l=e.y+(0,x.U2)(e,"offsetY",0)*(Math.sin(a)>0?1:-1),u={x:s-4*Math.cos(a),y:l-4*Math.sin(a)},c=e.labelLine.smooth,d=[],p=u.x-n.x,h=u.y-n.y,f=Math.atan(h/p);if(p<0&&(f+=Math.PI),!1===c){(0,x.Kn)(e.labelLine)||(e.labelLine={});var v=0;(a<0&&a>-Math.PI/2||a>1.5*Math.PI)&&u.y>o.y&&(v=1),a>=0&&ao.y&&(v=1),a>=Math.PI/2&&au.y&&(v=1),(a<-Math.PI/2||a>=Math.PI&&a<1.5*Math.PI)&&o.y>u.y&&(v=1);var m=i/2>4?4:Math.max(i/2-1,0),g=mi(n.x,n.y,r+m,a),y=mi(n.x,n.y,r+i/2,f);d.push("M ".concat(o.x," ").concat(o.y)),d.push("L ".concat(g.x," ").concat(g.y)),d.push("A ".concat(n.x," ").concat(n.y," 0 ").concat(0," ").concat(v," ").concat(y.x," ").concat(y.y)),d.push("L ".concat(u.x," ").concat(u.y))}else{g=mi(n.x,n.y,r+(i/2>4?4:Math.max(i/2-1,0)),a);var I=o.xMath.pow(Math.E,-16)&&d.push.apply(d,["C",u.x+4*I,u.y,2*g.x-o.x,2*g.y-o.y,o.x,o.y]),d.push("L ".concat(o.x," ").concat(o.y))}e.labelLine.path=d.join(" ")}}(e,s)}))}))}}})),Qs("adjust-color",(function(e,t,n){if(0!==n.length){var r=n[0].get("element").geometry.theme,a=r.labels||{},i=a.fillColorLight,o=a.fillColorDark;n.forEach((function(e,n){var a=t[n].find((function(e){return"text"===e.get("type")})),s=Si.fromObject(e.getBBox()),l=Si.fromObject(a.getCanvasBBox()),u=!s.contains(l),c=function(e){var t=ge.toRGB(e).toUpperCase();if(Vp[t])return Vp[t];var n=(0,y.CR)(ge.rgb2arr(t),3);return(299*n[0]+587*n[1]+114*n[2])/1e3<128}(e.attr("fill"));u?a.attr(r.overflowLabels.style):c?i&&a.attr("fill",i):o&&a.attr("fill",o)}))}})),Qs("interval-adjust-position",(function(e,t,n){var r;if(0!==n.length){var a=null===(r=n[0])||void 0===r?void 0:r.get("element"),i=null==a?void 0:a.geometry;if(i&&"interval"===i.type)Hp(i,t,n)&&n.forEach((function(e,n){var r=t[n];!function(e,t,n){var r=e.coordinate,a=Si.fromObject(n.getBBox()),i=fl(t);r.isTransposed?i.attr({x:a.minX+a.width/2,textAlign:"center"}):i.attr({y:a.minY+a.height/2,textBaseline:"middle"})}(i,r,e)}))}})),Qs("interval-hide-overlap",(function(e,t,n){var r;if(0!==n.length){var a=null===(r=n[0])||void 0===r?void 0:r.get("element"),i=null==a?void 0:a.geometry;if(i&&"interval"===i.type){var o,s=function(e){var t=[],n=Math.max(Math.floor(e.length/500),1);return(0,x.S6)(e,(function(e,r){r%n==0?t.push(e):e.set("visible",!1)})),t}(t),l=(0,y.CR)(i.getXYFields(),1)[0],u=[],c=[],d=(0,x.vM)(s,(function(e){return e.get("data")[l]})),p=(0,x.jj)((0,x.UI)(s,(function(e){return e.get("data")[l]})));s.forEach((function(e){e.set("visible",!0)}));var h=function(e){e&&(e.length&&c.push(e.pop()),c.push.apply(c,(0,y.ev)([],(0,y.CR)(e),!1)))};for((0,x.dp)(p)>0&&(o=p.shift(),h(d[o])),(0,x.dp)(p)>0&&(o=p.pop(),h(d[o])),(0,x.S6)(p.reverse(),(function(e){h(d[e])}));c.length>0;){var f=c.shift();f.get("visible")&&(ml(f,u)?f.set("visible",!1):u.push(f))}}}})),Qs("point-adjust-position",(function(e,t,n,r,a){var i,o;if(0!==n.length){var s=null===(i=n[0])||void 0===i?void 0:i.get("element"),l=null==s?void 0:s.geometry;if(l&&"point"===l.type){var u=(0,y.CR)(l.getXYFields(),2),c=u[0],d=u[1],p=(0,x.vM)(t,(function(e){return e.get("data")[c]})),h=[],f=a&&a.offset||(null===(o=e[0])||void 0===o?void 0:o.offset)||12;(0,x.UI)((0,x.XP)(p).reverse(),(function(e){for(var t=function(e,t){var n=e.getXYFields()[1],r=[],a=t.sort((function(e,t){return e.get("data")[n]-e.get("data")[n]}));return a.length>0&&r.push(a.shift()),a.length>0&&r.push(a.pop()),r.push.apply(r,(0,y.ev)([],(0,y.CR)(a),!1)),r}(l,p[e]);t.length;){var n=t.shift(),r=fl(n);if(Gp(h,n,(function(e,t){return e.get("data")[c]===t.get("data")[c]&&e.get("data")[d]===t.get("data")[d]})))r.set("visible",!1);else{var a=!1;qp(h,n)&&(r.attr("y",r.attr("y")+2*f),a=qp(h,n)),a?r.set("visible",!1):h.push(n)}}}))}}})),Qs("pie-spider",(function(e,t,n,r){var a,i,o=t[0]&&t[0].get("coordinate");if(o){var s=o.getCenter(),l=o.getRadius(),u={};try{for(var c=(0,y.XA)(t),d=c.next();!d.done;d=c.next()){var p=d.value;u[p.get("id")]=p}}catch(e){a={error:e}}finally{try{d&&!d.done&&(i=c.return)&&i.call(c)}finally{if(a)throw a.error}}var h=(0,x.U2)(e[0],"labelHeight",14),f=Math.max((0,x.U2)(e[0],"offset",0),4);(0,x.S6)(e,(function(e){if(e&&(0,x.U2)(u,[e.id])){var t=e.x>s.x||e.x===s.x&&e.y>s.y,n=(0,x.UM)(e.offsetX)?4:e.offsetX,r=mi(s.x,s.y,l+4,e.angle),a=f+n;e.x=s.x+(t?1:-1)*(l+a),e.y=r.y}}));var v=o.start,m=o.end,g="right",I=(0,x.vM)(e,(function(e){return e.x_&&(_=Math.min(t,Math.abs(v.y-m.y)))}));var b={minX:v.x,maxX:m.x,minY:s.y-_/2,maxY:s.y+_/2};(0,x.S6)(I,(function(e,t){var n=_/h;e.length>n&&(e.sort((function(e,t){return t.percent-e.percent})),(0,x.S6)(e,(function(e,t){t>n&&(u[e.id].set("visible",!1),e.invisible=!0)}))),kp(e,h,b)}));var w=b.minY,S=b.maxY;(0,x.S6)(I,(function(e,t){var n=t===g;(0,x.S6)(e,(function(e){var t=(0,x.U2)(u,e&&[e.id]);if(t)if(e.yS)t.set("visible",!1);else{var r=t.getChildByIndex(0),a=r.getCanvasBBox(),i=n?a.x:a.maxX,s=a.y+a.height/2;pl(r,e.x-i,e.y-s),e.labelLine&&function(e,t,n){var r,a=t.getCenter(),i=t.getRadius(),o={x:e.x-(n?4:-4),y:e.y},s=mi(a.x,a.y,i+4,e.angle),l={x:o.x,y:o.y},u={x:s.x,y:s.y},c=mi(a.x,a.y,i,e.angle);if(o.y!==s.y){var d=n?4:-4;l.y=o.y,e.angle<0&&e.angle>=-Math.PI/2&&(l.x=Math.max(s.x,o.x-d),o.y0&&e.angles.y?u.y=l.y:(u.y=s.y,u.x=Math.max(u.x,l.x-d))),e.angle>Math.PI/2&&(l.x=Math.min(s.x,o.x-d),o.y>s.y?u.y=l.y:(u.y=s.y,u.x=Math.min(u.x,l.x-d))),e.angle<-Math.PI/2&&(l.x=Math.min(s.x,o.x-d),o.y0&&r.push(a.shift()),a.length>0&&r.push(a.pop()),r.push.apply(r,(0,y.ev)([],(0,y.CR)(a),!1)),r}(l,p[e]);t.length;){var n=t.shift(),r=fl(n);if(Wp(h,n,(function(e,t){return e.get("data")[c]===t.get("data")[c]&&e.get("data")[d]===t.get("data")[d]})))r.set("visible",!1);else{var a=!1;Yp(h,n)&&(r.attr("y",r.attr("y")+2*f),a=Yp(h,n)),a?r.set("visible",!1):h.push(n)}}}))}}})),Bs("fade-in",(function(e,t,n){var r={fillOpacity:(0,x.UM)(e.attr("fillOpacity"))?1:e.attr("fillOpacity"),strokeOpacity:(0,x.UM)(e.attr("strokeOpacity"))?1:e.attr("strokeOpacity"),opacity:(0,x.UM)(e.attr("opacity"))?1:e.attr("opacity")};e.attr({fillOpacity:0,strokeOpacity:0,opacity:0}),e.animate(r,t)})),Bs("fade-out",(function(e,t,n){var r=t.easing,a=t.duration,i=t.delay;e.animate({fillOpacity:0,strokeOpacity:0,opacity:0},a,r,(function(){e.remove(!0)}),i)})),Bs("grow-in-x",(function(e,t,n){Jp(e,t,n.coordinate,n.minYPoint,"x")})),Bs("grow-in-xy",(function(e,t,n){Jp(e,t,n.coordinate,n.minYPoint,"xy")})),Bs("grow-in-y",(function(e,t,n){Jp(e,t,n.coordinate,n.minYPoint,"y")})),Bs("scale-in-x",(function(e,t,n){var r=e.getBBox(),a=e.get("origin").mappingData.points,i=a[0].y-a[1].y>0?r.maxX:r.minX,o=(r.minY+r.maxY)/2;e.applyToMatrix([i,o,1]);var s=vn.vs(e.getMatrix(),[["t",-i,-o],["s",.01,1],["t",i,o]]);e.setMatrix(s),e.animate({matrix:vn.vs(e.getMatrix(),[["t",-i,-o],["s",100,1],["t",i,o]])},t)})),Bs("scale-in-y",(function(e,t,n){var r=e.getBBox(),a=e.get("origin").mappingData,i=(r.minX+r.maxX)/2,o=a.points,s=o[0].y-o[1].y<=0?r.maxY:r.minY;e.applyToMatrix([i,s,1]);var l=vn.vs(e.getMatrix(),[["t",-i,-s],["s",1,.01],["t",i,s]]);e.setMatrix(l),e.animate({matrix:vn.vs(e.getMatrix(),[["t",-i,-s],["s",1,100],["t",i,s]])},t)})),Bs("wave-in",(function(e,t,n){var r=Mi(n.coordinate,20),a=r.type,i=r.startState,o=r.endState,s=e.setClip({type:a,attrs:i});n.toAttrs&&e.attr(n.toAttrs),s.animate(o,(0,y.pi)((0,y.pi)({},t),{callback:function(){e&&!e.get("destroyed")&&e.set("clipShape",null),s.remove(!0)}}))})),Bs("zoom-in",(function(e,t,n){th(e,t,"zoomIn")})),Bs("zoom-out",(function(e,t,n){th(e,t,"zoomOut")})),Bs("position-update",(function(e,t,n){var r=n.toAttrs,a=r.x,i=r.y;delete r.x,delete r.y,e.attr(r),e.animate({x:a,y:i},t)})),Bs("sector-path-update",(function(e,t,n){var r=n.toAttrs,a=n.coordinate,i=r.path||[],o=i.map((function(e){return e[0]}));if(!(i.length<1)){var s=eh(i),l=s.startAngle,u=s.endAngle,c=s.radius,d=s.innerRadius,p=eh(e.attr("path")),h=p.startAngle,f=p.endAngle,v=a.getCenter(),m=l-h,g=u-f;0!==m||0!==g?e.animate((function(e){var t=h+e*m,n=f+e*g;return(0,y.pi)((0,y.pi)({},r),{path:(0,x.Xy)(o,["M","A","A","Z"])?yi(v.x,v.y,c,t,n):gi(v.x,v.y,c,t,n,d)})}),(0,y.pi)((0,y.pi)({},t),{callback:function(){e.attr("path",i)}})):e.attr("path",i)}})),Bs("path-in",(function(e,t,n){var r=e.getTotalLength();e.attr("lineDash",[r]),e.animate((function(e){return{lineDashOffset:(1-e)*r}}),t)})),Wi("rect",hh),Wi("mirror",dh),Wi("list",sh),Wi("matrix",uh),Wi("circle",ih),Wi("tree",vh),xs("axis",Mh),xs("legend",Oh),xs("tooltip",Ns),xs("annotation",Ih),xs("slider",Dh),xs("scrollbar",zh),Qi("tooltip",Vh),Qi("sibling-tooltip",Gh),Qi("ellipsis-text",Wh),Qi("element-active",ef),Qi("element-single-active",df),Qi("element-range-active",sf),Qi("element-highlight",If),Qi("element-highlight-by-x",Sf),Qi("element-highlight-by-color",bf),Qi("element-single-highlight",Mf),Qi("element-range-highlight",Cf),Qi("element-sibling-highlight",Cf,{effectSiblings:!0,effectByRecord:!0}),Qi("element-selected",Pf),Qi("element-single-selected",Rf),Qi("element-range-selected",Af),Qi("element-link-by-color",nf),Qi("active-region",Zh),Qi("list-active",Ff),Qi("list-selected",qf),Qi("list-highlight",Hf),Qi("list-unchecked",Yf),Qi("list-checked",$f),Qi("list-focus",tv),Qi("list-radio",iv),Qi("legend-item-highlight",Hf,{componentNames:["legend"]}),Qi("axis-label-highlight",Hf,{componentNames:["axis"]}),Qi("axis-description",Yv),Qi("rect-mask",dv),Qi("x-rect-mask",vv,{dim:"x"}),Qi("y-rect-mask",vv,{dim:"y"}),Qi("circle-mask",uv),Qi("path-mask",gv),Qi("smooth-path-mask",xv),Qi("cursor",_v),Qi("data-filter",wv),Qi("brush",Cv),Qi("brush-x",Cv,{dims:["x"]}),Qi("brush-y",Cv,{dims:["y"]}),Qi("sibling-filter",Mv),Qi("sibling-x-filter",Mv),Qi("sibling-y-filter",Mv),Qi("element-filter",Av),Qi("element-sibling-filter",Pv),Qi("element-sibling-filter-record",Pv,{byRecord:!0}),Qi("view-drag",Nv),Qi("view-move",Fv),Qi("scale-translate",Uv),Qi("scale-zoom",Hv),Qi("reset-button",Rv,{name:"reset-button",text:"reset"}),Qi("mousewheel-scroll",qv),Ho("tooltip",{start:[{trigger:"plot:mousemove",action:"tooltip:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"plot:touchmove",action:"tooltip:show",throttle:{wait:50,leading:!0,trailing:!1}}],end:[{trigger:"plot:mouseleave",action:"tooltip:hide"},{trigger:"plot:leave",action:"tooltip:hide"},{trigger:"plot:touchend",action:"tooltip:hide"}]}),Ho("ellipsis-text",{start:[{trigger:"legend-item-name:mousemove",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"legend-item-name:touchstart",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"axis-label:mousemove",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"axis-label:touchstart",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}}],end:[{trigger:"legend-item-name:mouseleave",action:"ellipsis-text:hide"},{trigger:"legend-item-name:touchend",action:"ellipsis-text:hide"},{trigger:"axis-label:mouseleave",action:"ellipsis-text:hide"},{trigger:"axis-label:mouseout",action:"ellipsis-text:hide"},{trigger:"axis-label:touchend",action:"ellipsis-text:hide"}]}),Ho("element-active",{start:[{trigger:"element:mouseenter",action:"element-active:active"}],end:[{trigger:"element:mouseleave",action:"element-active:reset"}]}),Ho("element-selected",{start:[{trigger:"element:click",action:"element-selected:toggle"}]}),Ho("element-highlight",{start:[{trigger:"element:mouseenter",action:"element-highlight:highlight"}],end:[{trigger:"element:mouseleave",action:"element-highlight:reset"}]}),Ho("element-highlight-by-x",{start:[{trigger:"element:mouseenter",action:"element-highlight-by-x:highlight"}],end:[{trigger:"element:mouseleave",action:"element-highlight-by-x:reset"}]}),Ho("element-highlight-by-color",{start:[{trigger:"element:mouseenter",action:"element-highlight-by-color:highlight"}],end:[{trigger:"element:mouseleave",action:"element-highlight-by-color:reset"}]}),Ho("legend-active",{start:[{trigger:"legend-item:mouseenter",action:["list-active:active","element-active:active"]}],end:[{trigger:"legend-item:mouseleave",action:["list-active:reset","element-active:reset"]}]}),Ho("legend-highlight",{start:[{trigger:"legend-item:mouseenter",action:["legend-item-highlight:highlight","element-highlight:highlight"]}],end:[{trigger:"legend-item:mouseleave",action:["legend-item-highlight:reset","element-highlight:reset"]}]}),Ho("axis-label-highlight",{start:[{trigger:"axis-label:mouseenter",action:["axis-label-highlight:highlight","element-highlight:highlight"]}],end:[{trigger:"axis-label:mouseleave",action:["axis-label-highlight:reset","element-highlight:reset"]}]}),Ho("element-list-highlight",{start:[{trigger:"element:mouseenter",action:["list-highlight:highlight","element-highlight:highlight"]}],end:[{trigger:"element:mouseleave",action:["list-highlight:reset","element-highlight:reset"]}]}),Ho("element-range-highlight",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"mask:mouseenter",action:"cursor:move"},{trigger:"plot:mouseleave",action:"cursor:default"},{trigger:"mask:mouseleave",action:"cursor:crosshair"}],start:[{trigger:"plot:mousedown",isEnable:function(e){return!e.isInShape("mask")},action:["rect-mask:start","rect-mask:show"]},{trigger:"mask:dragstart",action:["rect-mask:moveStart"]}],processing:[{trigger:"plot:mousemove",action:["rect-mask:resize"]},{trigger:"mask:drag",action:["rect-mask:move"]},{trigger:"mask:change",action:["element-range-highlight:highlight"]}],end:[{trigger:"plot:mouseup",action:["rect-mask:end"]},{trigger:"mask:dragend",action:["rect-mask:moveEnd"]},{trigger:"document:mouseup",isEnable:function(e){return!e.isInPlot()},action:["element-range-highlight:clear","rect-mask:end","rect-mask:hide"]}],rollback:[{trigger:"dblclick",action:["element-range-highlight:clear","rect-mask:hide"]}]}),Ho("brush",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:Xv,action:["brush:start","rect-mask:start","rect-mask:show"]}],processing:[{trigger:"mousemove",isEnable:Xv,action:["rect-mask:resize"]}],end:[{trigger:"mouseup",isEnable:Xv,action:["brush:filter","brush:end","rect-mask:end","rect-mask:hide","reset-button:show"]}],rollback:[{trigger:"reset-button:click",action:["brush:reset","reset-button:hide","cursor:crosshair"]}]}),Ho("brush-visible",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"plot:mousedown",action:["rect-mask:start","rect-mask:show"]}],processing:[{trigger:"plot:mousemove",action:["rect-mask:resize"]},{trigger:"mask:change",action:["element-range-highlight:highlight"]}],end:[{trigger:"plot:mouseup",action:["rect-mask:end","rect-mask:hide","element-filter:filter","element-range-highlight:clear"]}],rollback:[{trigger:"dblclick",action:["element-filter:clear"]}]}),Ho("brush-x",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:Xv,action:["brush-x:start","x-rect-mask:start","x-rect-mask:show"]}],processing:[{trigger:"mousemove",isEnable:Xv,action:["x-rect-mask:resize"]}],end:[{trigger:"mouseup",isEnable:Xv,action:["brush-x:filter","brush-x:end","x-rect-mask:end","x-rect-mask:hide"]}],rollback:[{trigger:"dblclick",action:["brush-x:reset"]}]}),Ho("element-path-highlight",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:Xv,action:"path-mask:start"},{trigger:"mousedown",isEnable:Xv,action:"path-mask:show"}],processing:[{trigger:"mousemove",action:"path-mask:addPoint"}],end:[{trigger:"mouseup",action:"path-mask:end"}],rollback:[{trigger:"dblclick",action:"path-mask:hide"}]}),Ho("element-single-selected",{start:[{trigger:"element:click",action:"element-single-selected:toggle"}]}),Ho("legend-filter",{showEnable:[{trigger:"legend-item:mouseenter",action:["cursor:pointer","list-radio:show"]},{trigger:"legend-item:mouseleave",action:["cursor:default","list-radio:hide"]}],start:[{trigger:"legend-item:click",isEnable:function(e){return!e.isInShape("legend-item-radio")},action:["legend-item-highlight:reset","element-highlight:reset","list-unchecked:toggle","data-filter:filter","list-radio:show"]},{trigger:"legend-item-radio:mouseenter",action:["list-radio:showTip"]},{trigger:"legend-item-radio:mouseleave",action:["list-radio:hideTip"]},{trigger:"legend-item-radio:click",action:["list-focus:toggle","data-filter:filter","list-radio:show"]}]}),Ho("continuous-filter",{start:[{trigger:"legend:valuechanged",action:"data-filter:filter"}]}),Ho("continuous-visible-filter",{start:[{trigger:"legend:valuechanged",action:"element-filter:filter"}]}),Ho("legend-visible-filter",{showEnable:[{trigger:"legend-item:mouseenter",action:"cursor:pointer"},{trigger:"legend-item:mouseleave",action:"cursor:default"}],start:[{trigger:"legend-item:click",action:["legend-item-highlight:reset","element-highlight:reset","list-unchecked:toggle","element-filter:filter"]}]}),Ho("active-region",{start:[{trigger:"plot:mousemove",action:"active-region:show"}],end:[{trigger:"plot:mouseleave",action:"active-region:hide"}]}),Ho("axis-description",{start:[{trigger:"axis-description:mousemove",action:"axis-description:show"}],end:[{trigger:"axis-description:mouseleave",action:"axis-description:hide"}]}),Ho("view-zoom",{start:[{trigger:"plot:mousewheel",isEnable:function(e){return Kv(e.event)},action:"scale-zoom:zoomOut",throttle:{wait:100,leading:!0,trailing:!1}},{trigger:"plot:mousewheel",isEnable:function(e){return!Kv(e.event)},action:"scale-zoom:zoomIn",throttle:{wait:100,leading:!0,trailing:!1}}]}),Ho("sibling-tooltip",{start:[{trigger:"plot:mousemove",action:"sibling-tooltip:show"}],end:[{trigger:"plot:mouseleave",action:"sibling-tooltip:hide"}]}),Ho("plot-mousewheel-scroll",{start:[{trigger:"plot:mousewheel",action:"mousewheel-scroll:scroll"}]})},86984:function(e,t,n){!function(e,t){"use strict";var r={draw:"crosshair",pointHover:"pointer",pointDrag:"move",lineHover:"pointer",lineDrag:"move",polygonHover:"pointer",polygonDrag:"move"},a={point:[],line:[],polygon:[],midPoint:[],dashLine:[],text:[]},i="top",o="bottom",s="right",l="left",u="auto",c=[i,o,s,l],d="start",p="end",h="viewport",f="popper",v=c.reduce((function(e,t){return e.concat([t+"-"+d,t+"-"+p])}),[]),m=[].concat(c,[u]).reduce((function(e,t){return e.concat([t,t+"-"+d,t+"-"+p])}),[]),g=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function y(e){return e?(e.nodeName||"").toLowerCase():null}function x(e){if(null==e)return window;if(""+e!="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function I(e){return e instanceof x(e).Element||e instanceof Element}function _(e){return e instanceof x(e).HTMLElement||e instanceof HTMLElement}function b(e){return"undefined"!=typeof ShadowRoot&&(e instanceof x(e).ShadowRoot||e instanceof ShadowRoot)}var w={name:"applyStyles",enabled:!0,phase:"write",fn:function(e){var t=e.state;Object.keys(t.elements).forEach((function(e){var n=t.styles[e]||{},r=t.attributes[e]||{},a=t.elements[e];_(a)&&y(a)&&(Object.assign(a.style,n),Object.keys(r).forEach((function(e){var t=r[e];!1===t?a.removeAttribute(e):a.setAttribute(e,!0===t?"":t)})))}))},effect:function(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach((function(e){var r=t.elements[e],a=t.attributes[e]||{},i=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:n[e]).reduce((function(e,t){return e[t]="",e}),{});_(r)&&y(r)&&(Object.assign(r.style,i),Object.keys(a).forEach((function(e){r.removeAttribute(e)})))}))}},requires:["computeStyles"]};function S(e){return e.split("-")[0]}var E=Math.max,C=Math.min,k=Math.round;function M(){var e=navigator.userAgentData;return null!=e&&e.brands?e.brands.map((function(e){return e.brand+"/"+e.version})).join(" "):navigator.userAgent}function T(){return!/^((?!chrome|android).)*safari/i.test(M())}function A(e,t,n){void 0===t&&(t=!1),void 0===n&&(n=!1);var r=e.getBoundingClientRect(),a=1,i=1;t&&_(e)&&(a=e.offsetWidth>0&&k(r.width)/e.offsetWidth||1,i=e.offsetHeight>0&&k(r.height)/e.offsetHeight||1);var o=(I(e)?x(e):window).visualViewport,s=!T()&&n,l=(r.left+(s&&o?o.offsetLeft:0))/a,u=(r.top+(s&&o?o.offsetTop:0))/i,c=r.width/a,d=r.height/i;return{width:c,height:d,top:u,right:l+c,bottom:u+d,left:l,x:l,y:u}}function L(e){var t=A(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)>1||(n=t.width),Math.abs(t.height-r)>1||(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function P(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&b(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function O(e){return x(e).getComputedStyle(e)}function R(e){return["table","td","th"].indexOf(y(e))>=0}function D(e){return((I(e)?e.ownerDocument:e.document)||window.document).documentElement}function N(e){return"html"===y(e)?e:e.assignedSlot||e.parentNode||(b(e)?e.host:null)||D(e)}function z(e){return _(e)&&"fixed"!==O(e).position?e.offsetParent:null}function F(e){for(var t=x(e),n=z(e);n&&R(n)&&"static"===O(n).position;)n=z(n);return n&&("html"===y(n)||"body"===y(n)&&"static"===O(n).position)?t:n||function(e){var t=/firefox/i.test(M());if(/Trident/i.test(M())&&_(e)&&"fixed"===O(e).position)return null;var n=N(e);for(b(n)&&(n=n.host);_(n)&&0>["html","body"].indexOf(y(n));){var r=O(n);if("none"!==r.transform||"none"!==r.perspective||"paint"===r.contain||-1!==["transform","perspective"].indexOf(r.willChange)||t&&"filter"===r.willChange||t&&r.filter&&"none"!==r.filter)return n;n=n.parentNode}return null}(e)||t}function B(e){return 0>["top","bottom"].indexOf(e)?"y":"x"}function j(e,t,n){return E(e,C(t,n))}function Z(e){return Object.assign({},{top:0,right:0,bottom:0,left:0},e)}function U(e,t){return t.reduce((function(t,n){return t[n]=e,t}),{})}var V={name:"arrow",enabled:!0,phase:"main",fn:function(e){var t,n=e.state,r=e.name,a=e.options,u=n.elements.arrow,d=n.modifiersData.popperOffsets,p=S(n.placement),h=B(p),f=[l,s].indexOf(p)>=0?"height":"width";if(u&&d){var v=function(e,t){return Z("number"!=typeof(e="function"==typeof e?e(Object.assign({},t.rects,{placement:t.placement})):e)?e:U(e,c))}(a.padding,n),m=L(u),g="y"===h?i:l,y="y"===h?o:s,x=n.rects.reference[f]+n.rects.reference[h]-d[h]-n.rects.popper[f],I=d[h]-n.rects.reference[h],_=F(u),b=_?"y"===h?_.clientHeight||0:_.clientWidth||0:0,w=b/2-m[f]/2+(x/2-I/2),E=j(v[g],w,b-m[f]-v[y]);n.modifiersData[r]=((t={})[h]=E,t.centerOffset=E-w,t)}},effect:function(e){var t=e.state,n=e.options.element,r=void 0===n?"[data-popper-arrow]":n;null!=r&&("string"!=typeof r||(r=t.elements.popper.querySelector(r)))&&P(t.elements.popper,r)&&(t.elements.arrow=r)},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function H(e){return e.split("-")[1]}var G={top:"auto",right:"auto",bottom:"auto",left:"auto"};function q(e){var t,n=e.popper,r=e.popperRect,a=e.placement,u=e.variation,c=e.offsets,d=e.position,h=e.gpuAcceleration,f=e.adaptive,v=e.roundOffsets,m=e.isFixed,g=c.x,y=void 0===g?0:g,I=c.y,_=void 0===I?0:I,b="function"==typeof v?v({x:y,y:_}):{x:y,y:_};y=b.x,_=b.y;var w=c.hasOwnProperty("x"),S=c.hasOwnProperty("y"),E=l,C=i,M=window;if(f){var T=F(n),A="clientHeight",L="clientWidth";T===x(n)&&"static"!==O(T=D(n)).position&&"absolute"===d&&(A="scrollHeight",L="scrollWidth"),(a===i||(a===l||a===s)&&u===p)&&(C=o,_-=(m&&T===M&&M.visualViewport?M.visualViewport.height:T[A])-r.height,_*=h?1:-1),a!==l&&(a!==i&&a!==o||u!==p)||(E=s,y-=(m&&T===M&&M.visualViewport?M.visualViewport.width:T[L])-r.width,y*=h?1:-1)}var P,R=Object.assign({position:d},f&&G),N=!0===v?function(e){var t=e.y,n=window.devicePixelRatio||1;return{x:k(e.x*n)/n||0,y:k(t*n)/n||0}}({x:y,y:_}):{x:y,y:_};return y=N.x,_=N.y,Object.assign({},R,h?((P={})[C]=S?"0":"",P[E]=w?"0":"",P.transform=(M.devicePixelRatio||1)>1?"translate3d("+y+"px, "+_+"px, 0)":"translate("+y+"px, "+_+"px)",P):((t={})[C]=S?_+"px":"",t[E]=w?y+"px":"",t.transform="",t))}var W={passive:!0},Y={left:"right",right:"left",bottom:"top",top:"bottom"};function X(e){return e.replace(/left|right|bottom|top/g,(function(e){return Y[e]}))}var K={start:"end",end:"start"};function J(e){return e.replace(/start|end/g,(function(e){return K[e]}))}function $(e){var t=x(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function Q(e){return A(D(e)).left+$(e).scrollLeft}function ee(e){var t=O(e);return/auto|scroll|overlay|hidden/.test(t.overflow+t.overflowY+t.overflowX)}function te(e){return 0>["html","body","#document"].indexOf(y(e))?_(e)&&ee(e)?e:te(N(e)):e.ownerDocument.body}function ne(e,t){var n;void 0===t&&(t=[]);var r=te(e),a=r===(null==(n=e.ownerDocument)?void 0:n.body),i=x(r),o=a?[i].concat(i.visualViewport||[],ee(r)?r:[]):r,s=t.concat(o);return a?s:s.concat(ne(N(o)))}function re(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function ae(e,t,n){return t===h?re(function(e,t){var n=x(e),r=D(e),a=n.visualViewport,i=r.clientWidth,o=r.clientHeight,s=0,l=0;if(a){i=a.width,o=a.height;var u=T();(u||!u&&"fixed"===t)&&(s=a.offsetLeft,l=a.offsetTop)}return{width:i,height:o,x:s+Q(e),y:l}}(e,n)):I(t)?function(e,t){var n=A(e,!1,"fixed"===t);return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}(t,n):re(function(e){var t,n=D(e),r=$(e),a=null==(t=e.ownerDocument)?void 0:t.body,i=E(n.scrollWidth,n.clientWidth,a?a.scrollWidth:0,a?a.clientWidth:0),o=E(n.scrollHeight,n.clientHeight,a?a.scrollHeight:0,a?a.clientHeight:0),s=-r.scrollLeft+Q(e),l=-r.scrollTop;return"rtl"===O(a||n).direction&&(s+=E(n.clientWidth,a?a.clientWidth:0)-i),{width:i,height:o,x:s,y:l}}(D(e)))}function ie(e,t,n,r){var a="clippingParents"===t?function(e){var t=ne(N(e)),n=["absolute","fixed"].indexOf(O(e).position)>=0&&_(e)?F(e):e;return I(n)?t.filter((function(e){return I(e)&&P(e,n)&&"body"!==y(e)})):[]}(e):[].concat(t),i=[].concat(a,[n]),o=i.reduce((function(t,n){var a=ae(e,n,r);return t.top=E(a.top,t.top),t.right=C(a.right,t.right),t.bottom=C(a.bottom,t.bottom),t.left=E(a.left,t.left),t}),ae(e,i[0],r));return o.width=o.right-o.left,o.height=o.bottom-o.top,o.x=o.left,o.y=o.top,o}function oe(e){var t,n=e.reference,r=e.element,a=e.placement,u=a?S(a):null,c=a?H(a):null,h=n.x+n.width/2-r.width/2,f=n.y+n.height/2-r.height/2;switch(u){case i:t={x:h,y:n.y-r.height};break;case o:t={x:h,y:n.y+n.height};break;case s:t={x:n.x+n.width,y:f};break;case l:t={x:n.x-r.width,y:f};break;default:t={x:n.x,y:n.y}}var v=u?B(u):null;if(null!=v){var m="y"===v?"height":"width";switch(c){case d:t[v]=t[v]-(n[m]/2-r[m]/2);break;case p:t[v]=t[v]+(n[m]/2-r[m]/2)}}return t}function se(e,t){void 0===t&&(t={});var n=t.placement,r=void 0===n?e.placement:n,a=t.strategy,l=void 0===a?e.strategy:a,u=t.boundary,d=void 0===u?"clippingParents":u,p=t.rootBoundary,v=void 0===p?h:p,m=t.elementContext,g=void 0===m?f:m,y=t.altBoundary,x=void 0!==y&&y,_=t.padding,b=void 0===_?0:_,w=Z("number"!=typeof b?b:U(b,c)),S=e.rects.popper,E=e.elements[x?g===f?"reference":f:g],C=ie(I(E)?E:E.contextElement||D(e.elements.popper),d,v,l),k=A(e.elements.reference),M=oe({reference:k,element:S,strategy:"absolute",placement:r}),T=re(Object.assign({},S,M)),L=g===f?T:k,P={top:C.top-L.top+w.top,bottom:L.bottom-C.bottom+w.bottom,left:C.left-L.left+w.left,right:L.right-C.right+w.right},O=e.modifiersData.offset;if(g===f&&O){var R=O[r];Object.keys(P).forEach((function(e){var t=0>[s,o].indexOf(e)?-1:1;P[e]+=R[0>[i,o].indexOf(e)?"x":"y"]*t}))}return P}function le(e,t){void 0===t&&(t={});var n=t.boundary,r=t.rootBoundary,a=t.padding,i=t.flipVariations,o=t.allowedAutoPlacements,s=void 0===o?m:o,l=H(t.placement),u=l?i?v:v.filter((function(e){return H(e)===l})):c,d=u.filter((function(e){return s.indexOf(e)>=0}));0===d.length&&(d=u);var p=d.reduce((function(t,i){return t[i]=se(e,{placement:i,boundary:n,rootBoundary:r,padding:a})[S(i)],t}),{});return Object.keys(p).sort((function(e,t){return p[e]-p[t]}))}var ue={name:"flip",enabled:!0,phase:"main",fn:function(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var a=n.mainAxis,c=void 0===a||a,p=n.altAxis,h=void 0===p||p,f=n.fallbackPlacements,v=n.padding,m=n.boundary,g=n.rootBoundary,y=n.altBoundary,x=n.flipVariations,I=void 0===x||x,_=n.allowedAutoPlacements,b=t.options.placement,w=S(b),E=f||(w!==b&&I?function(e){if(S(e)===u)return[];var t=X(e);return[J(e),t,J(t)]}(b):[X(b)]),C=[b].concat(E).reduce((function(e,n){return e.concat(S(n)===u?le(t,{placement:n,boundary:m,rootBoundary:g,padding:v,flipVariations:I,allowedAutoPlacements:_}):n)}),[]),k=t.rects.reference,M=t.rects.popper,T=new Map,A=!0,L=C[0],P=0;C.length>P;P++){var O=C[P],R=S(O),D=H(O)===d,N=[i,o].indexOf(R)>=0,z=N?"width":"height",F=se(t,{placement:O,boundary:m,rootBoundary:g,altBoundary:y,padding:v}),B=N?D?s:l:D?o:i;k[z]>M[z]&&(B=X(B));var j=X(B),Z=[];if(c&&Z.push(0>=F[R]),h&&Z.push(0>=F[B],0>=F[j]),Z.every((function(e){return e}))){L=O,A=!1;break}T.set(O,Z)}if(A)for(var U=function(e){var t=C.find((function(t){var n=T.get(t);if(n)return n.slice(0,e).every((function(e){return e}))}));if(t)return L=t,"break"},V=I?3:1;V>0&&"break"!==U(V);V--);t.placement!==L&&(t.modifiersData[r]._skip=!0,t.placement=L,t.reset=!0)}},requiresIfExists:["offset"],data:{_skip:!1}};function ce(e,t,n){return void 0===n&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function de(e){return[i,s,o,l].some((function(t){return e[t]>=0}))}var pe={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function(e){var t=e.state,n=e.name,r=e.options.offset,a=void 0===r?[0,0]:r,o=m.reduce((function(e,n){return e[n]=function(e,t,n){var r=S(e),a=0>[l,i].indexOf(r)?1:-1,o="function"==typeof n?n(Object.assign({},t,{placement:e})):n,u=o[0],c=o[1];return u=u||0,c=(c||0)*a,0>[l,s].indexOf(r)?{x:u,y:c}:{x:c,y:u}}(n,t.rects,a),e}),{}),u=o[t.placement],c=u.y;null!=t.modifiersData.popperOffsets&&(t.modifiersData.popperOffsets.x+=u.x,t.modifiersData.popperOffsets.y+=c),t.modifiersData[n]=o}},he={name:"preventOverflow",enabled:!0,phase:"main",fn:function(e){var t=e.state,n=e.options,r=e.name,a=n.mainAxis,u=void 0===a||a,c=n.altAxis,p=void 0!==c&&c,h=n.tether,f=void 0===h||h,v=n.tetherOffset,m=void 0===v?0:v,g=se(t,{boundary:n.boundary,rootBoundary:n.rootBoundary,padding:n.padding,altBoundary:n.altBoundary}),y=S(t.placement),x=H(t.placement),I=!x,_=B(y),b="x"===_?"y":"x",w=t.modifiersData.popperOffsets,k=t.rects.reference,M=t.rects.popper,T="function"==typeof m?m(Object.assign({},t.rects,{placement:t.placement})):m,A="number"==typeof T?{mainAxis:T,altAxis:T}:Object.assign({mainAxis:0,altAxis:0},T),P=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,O={x:0,y:0};if(w){if(u){var R,D="y"===_?i:l,N="y"===_?o:s,z="y"===_?"height":"width",Z=w[_],U=Z+g[D],V=Z-g[N],G=f?-M[z]/2:0,q=x===d?k[z]:M[z],W=x===d?-M[z]:-k[z],Y=t.elements.arrow,X=f&&Y?L(Y):{width:0,height:0},K=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:{top:0,right:0,bottom:0,left:0},J=K[D],$=K[N],Q=j(0,k[z],X[z]),ee=I?k[z]/2-G-Q-J-A.mainAxis:q-Q-J-A.mainAxis,te=I?-k[z]/2+G+Q+$+A.mainAxis:W+Q+$+A.mainAxis,ne=t.elements.arrow&&F(t.elements.arrow),re=null!=(R=null==P?void 0:P[_])?R:0,ae=Z+te-re,ie=j(f?C(U,Z+ee-re-(ne?"y"===_?ne.clientTop||0:ne.clientLeft||0:0)):U,Z,f?E(V,ae):V);w[_]=ie,O[_]=ie-Z}if(p){var oe,le=w[b],ue="y"===b?"height":"width",ce=le+g["x"===_?i:l],de=le-g["x"===_?o:s],pe=-1!==[i,l].indexOf(y),he=null!=(oe=null==P?void 0:P[b])?oe:0,fe=pe?ce:le-k[ue]-M[ue]-he+A.altAxis,ve=pe?le+k[ue]+M[ue]-he-A.altAxis:de,me=f&&pe?function(e,t,n){var r=j(e,t,n);return r>n?n:r}(fe,le,ve):j(f?fe:ce,le,f?ve:de);w[b]=me,O[b]=me-le}t.modifiersData[r]=O}},requiresIfExists:["offset"]};function fe(e,t,n){void 0===n&&(n=!1);var r,a,i=_(t),o=_(t)&&function(e){var t=e.getBoundingClientRect(),n=k(t.width)/e.offsetWidth||1,r=k(t.height)/e.offsetHeight||1;return 1!==n||1!==r}(t),s=D(t),l=A(e,o,n),u={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(i||!i&&!n)&&(("body"!==y(t)||ee(s))&&(u=(r=t)!==x(r)&&_(r)?{scrollLeft:(a=r).scrollLeft,scrollTop:a.scrollTop}:$(r)),_(t)?((c=A(t,!0)).x+=t.clientLeft,c.y+=t.clientTop):s&&(c.x=Q(s))),{x:l.left+u.scrollLeft-c.x,y:l.top+u.scrollTop-c.y,width:l.width,height:l.height}}function ve(e){var t=new Map,n=new Set,r=[];function a(e){n.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach((function(e){if(!n.has(e)){var r=t.get(e);r&&a(r)}})),r.push(e)}return e.forEach((function(e){t.set(e.name,e)})),e.forEach((function(e){n.has(e.name)||a(e)})),r}var me={placement:"bottom",modifiers:[],strategy:"absolute"};function ge(){for(var e=arguments.length,t=Array(e),n=0;e>n;n++)t[n]=arguments[n];return!t.some((function(e){return!(e&&"function"==typeof e.getBoundingClientRect)}))}function ye(e){void 0===e&&(e={});var t=e.defaultModifiers,n=void 0===t?[]:t,r=e.defaultOptions,a=void 0===r?me:r;return function(e,t,r){void 0===r&&(r=a);var i,o,s={placement:"bottom",orderedModifiers:[],options:Object.assign({},me,a),modifiersData:{},elements:{reference:e,popper:t},attributes:{},styles:{}},l=[],u=!1,c={state:s,setOptions:function(r){var i="function"==typeof r?r(s.options):r;d(),s.options=Object.assign({},a,s.options,i),s.scrollParents={reference:I(e)?ne(e):e.contextElement?ne(e.contextElement):[],popper:ne(t)};var o,u,p=function(e){var t=ve(e);return g.reduce((function(e,n){return e.concat(t.filter((function(e){return e.phase===n})))}),[])}((o=[].concat(n,s.options.modifiers),u=o.reduce((function(e,t){var n=e[t.name];return e[t.name]=n?Object.assign({},n,t,{options:Object.assign({},n.options,t.options),data:Object.assign({},n.data,t.data)}):t,e}),{}),Object.keys(u).map((function(e){return u[e]}))));return s.orderedModifiers=p.filter((function(e){return e.enabled})),s.orderedModifiers.forEach((function(e){var t=e.options,n=e.effect;if("function"==typeof n){var r=n({state:s,name:e.name,instance:c,options:void 0===t?{}:t});l.push(r||function(){})}})),c.update()},forceUpdate:function(){if(!u){var e=s.elements,t=e.reference,n=e.popper;if(ge(t,n)){s.rects={reference:fe(t,F(n),"fixed"===s.options.strategy),popper:L(n)},s.reset=!1,s.placement=s.options.placement,s.orderedModifiers.forEach((function(e){return s.modifiersData[e.name]=Object.assign({},e.data)}));for(var r=0;s.orderedModifiers.length>r;r++)if(!0!==s.reset){var a=s.orderedModifiers[r],i=a.fn,o=a.options;"function"==typeof i&&(s=i({state:s,options:void 0===o?{}:o,name:a.name,instance:c})||s)}else s.reset=!1,r=-1}}},update:(i=function(){return new Promise((function(e){c.forceUpdate(),e(s)}))},function(){return o||(o=new Promise((function(e){Promise.resolve().then((function(){o=void 0,e(i())}))}))),o}),destroy:function(){d(),u=!0}};if(!ge(e,t))return c;function d(){l.forEach((function(e){return e()})),l=[]}return c.setOptions(r).then((function(e){!u&&r.onFirstUpdate&&r.onFirstUpdate(e)})),c}}var xe=ye({defaultModifiers:[{name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function(e){var t=e.state,n=e.instance,r=e.options,a=r.scroll,i=void 0===a||a,o=r.resize,s=void 0===o||o,l=x(t.elements.popper),u=[].concat(t.scrollParents.reference,t.scrollParents.popper);return i&&u.forEach((function(e){e.addEventListener("scroll",n.update,W)})),s&&l.addEventListener("resize",n.update,W),function(){i&&u.forEach((function(e){e.removeEventListener("scroll",n.update,W)})),s&&l.removeEventListener("resize",n.update,W)}},data:{}},{name:"popperOffsets",enabled:!0,phase:"read",fn:function(e){var t=e.state;t.modifiersData[e.name]=oe({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})},data:{}},{name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function(e){var t=e.state,n=e.options,r=n.gpuAcceleration,a=void 0===r||r,i=n.adaptive,o=void 0===i||i,s=n.roundOffsets,l=void 0===s||s,u={placement:S(t.placement),variation:H(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:a,isFixed:"fixed"===t.options.strategy};null!=t.modifiersData.popperOffsets&&(t.styles.popper=Object.assign({},t.styles.popper,q(Object.assign({},u,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:o,roundOffsets:l})))),null!=t.modifiersData.arrow&&(t.styles.arrow=Object.assign({},t.styles.arrow,q(Object.assign({},u,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})},data:{}},w,pe,ue,he,V,{name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function(e){var t=e.state,n=e.name,r=t.rects.reference,a=t.rects.popper,i=t.modifiersData.preventOverflow,o=se(t,{elementContext:"reference"}),s=se(t,{altBoundary:!0}),l=ce(o,r),u=ce(s,a,i),c=de(l),d=de(u);t.modifiersData[n]={referenceClippingOffsets:l,popperEscapeOffsets:u,isReferenceHidden:c,hasPopperEscaped:d},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":c,"data-popper-escaped":d})}}]}),Ie="tippy-content",_e="tippy-arrow",be="tippy-svg-arrow",we={passive:!0,capture:!0},Se=function(){return document.body};function Ee(e,t,n){if(Array.isArray(e)){var r=e[t];return null==r?Array.isArray(n)?n[t]:n:r}return e}function Ce(e,t){var n={}.toString.call(e);return 0===n.indexOf("[object")&&n.indexOf(t+"]")>-1}function ke(e,t){return"function"==typeof e?e.apply(void 0,t):e}function Me(e,t){return 0===t?e:function(r){clearTimeout(n),n=setTimeout((function(){e(r)}),t)};var n}function Te(e){return[].concat(e)}function Ae(e,t){-1===e.indexOf(t)&&e.push(t)}function Le(e){return[].slice.call(e)}function Pe(e){return Object.keys(e).reduce((function(t,n){return void 0!==e[n]&&(t[n]=e[n]),t}),{})}function Oe(){return document.createElement("div")}function Re(e){return["Element","Fragment"].some((function(t){return Ce(e,t)}))}function De(e){return Ce(e,"MouseEvent")}function Ne(e){return Re(e)?[e]:function(e){return Ce(e,"NodeList")}(e)?Le(e):Array.isArray(e)?e:Le(document.querySelectorAll(e))}function ze(e,t){e.forEach((function(e){e&&(e.style.transitionDuration=t+"ms")}))}function Fe(e,t){e.forEach((function(e){e&&e.setAttribute("data-state",t)}))}function Be(e){var t,n=Te(e)[0];return null!=n&&null!=(t=n.ownerDocument)&&t.body?n.ownerDocument:document}function je(e,t,n){var r=t+"EventListener";["transitionend","webkitTransitionEnd"].forEach((function(t){e[r](t,n)}))}function Ze(e,t){for(var n=t;n;){var r;if(e.contains(n))return!0;n=null==n.getRootNode||null==(r=n.getRootNode())?void 0:r.host}return!1}var Ue={isTouch:!1},Ve=0;function He(){Ue.isTouch||(Ue.isTouch=!0,window.performance&&document.addEventListener("mousemove",Ge))}function Ge(){var e=performance.now();20>e-Ve&&(Ue.isTouch=!1,document.removeEventListener("mousemove",Ge)),Ve=e}function qe(){var e,t=document.activeElement;(e=t)&&e._tippy&&e._tippy.reference===e&&t.blur&&!t._tippy.state.isVisible&&t.blur()}var We=!("undefined"==typeof window||"undefined"==typeof document||!window.msCrypto),Ye=Object.assign({appendTo:Se,aria:{content:"auto",expanded:"auto"},delay:0,duration:[300,250],getReferenceClientRect:null,hideOnClick:!0,ignoreAttributes:!1,interactive:!1,interactiveBorder:2,interactiveDebounce:0,moveTransition:"",offset:[0,10],onAfterUpdate:function(){},onBeforeUpdate:function(){},onCreate:function(){},onDestroy:function(){},onHidden:function(){},onHide:function(){},onMount:function(){},onShow:function(){},onShown:function(){},onTrigger:function(){},onUntrigger:function(){},onClickOutside:function(){},placement:"top",plugins:[],popperOptions:{},render:null,showOnCreate:!1,touch:!0,trigger:"mouseenter focus",triggerTarget:null},{animateFill:!1,followCursor:!1,inlinePositioning:!1,sticky:!1},{allowHTML:!1,animation:"fade",arrow:!0,content:"",inertia:!1,maxWidth:350,role:"tooltip",theme:"",zIndex:9999}),Xe=Object.keys(Ye);function Ke(e){var t=(e.plugins||[]).reduce((function(t,n){var r,a=n.name;return a&&(t[a]=void 0!==e[a]?e[a]:null!=(r=Ye[a])?r:n.defaultValue),t}),{});return Object.assign({},e,t)}function Je(e,t){var n=Object.assign({},t,{content:ke(t.content,[e])},t.ignoreAttributes?{}:function(e,t){return(t?Object.keys(Ke(Object.assign({},Ye,{plugins:t}))):Xe).reduce((function(t,n){var r=(e.getAttribute("data-tippy-"+n)||"").trim();if(!r)return t;if("content"===n)t[n]=r;else try{t[n]=JSON.parse(r)}catch(e){t[n]=r}return t}),{})}(e,t.plugins));return n.aria=Object.assign({},Ye.aria,n.aria),n.aria={expanded:"auto"===n.aria.expanded?t.interactive:n.aria.expanded,content:"auto"===n.aria.content?t.interactive?null:"describedby":n.aria.content},n}function $e(e,t){e.innerHTML=t}function Qe(e){var t=Oe();return!0===e?t.className=_e:(t.className=be,Re(e)?t.appendChild(e):$e(t,e)),t}function et(e,t){Re(t.content)?($e(e,""),e.appendChild(t.content)):"function"!=typeof t.content&&(t.allowHTML?$e(e,t.content):e.textContent=t.content)}function tt(e){var t=e.firstElementChild,n=Le(t.children);return{box:t,content:n.find((function(e){return e.classList.contains(Ie)})),arrow:n.find((function(e){return e.classList.contains(_e)||e.classList.contains(be)})),backdrop:n.find((function(e){return e.classList.contains("tippy-backdrop")}))}}function nt(e){var t=Oe(),n=Oe();n.className="tippy-box",n.setAttribute("data-state","hidden"),n.setAttribute("tabindex","-1");var r=Oe();function a(n,r){var a=tt(t),i=a.box,o=a.content,s=a.arrow;r.theme?i.setAttribute("data-theme",r.theme):i.removeAttribute("data-theme"),"string"==typeof r.animation?i.setAttribute("data-animation",r.animation):i.removeAttribute("data-animation"),r.inertia?i.setAttribute("data-inertia",""):i.removeAttribute("data-inertia"),i.style.maxWidth="number"==typeof r.maxWidth?r.maxWidth+"px":r.maxWidth,r.role?i.setAttribute("role",r.role):i.removeAttribute("role"),n.content===r.content&&n.allowHTML===r.allowHTML||et(o,e.props),r.arrow?s?n.arrow!==r.arrow&&(i.removeChild(s),i.appendChild(Qe(r.arrow))):i.appendChild(Qe(r.arrow)):s&&i.removeChild(s)}return r.className=Ie,r.setAttribute("data-state","hidden"),et(r,e.props),t.appendChild(n),n.appendChild(r),a(e.props,e.props),{popper:t,onUpdate:a}}nt.$$tippy=!0;var rt=1,at=[],it=[];function ot(e,t){var n,r,a,i,o,s,l,u,c=Je(e,Object.assign({},Ye,Ke(Pe(t)))),d=!1,p=!1,h=!1,f=!1,v=[],m=Me(W,c.interactiveDebounce),g=rt++,y=(u=c.plugins).filter((function(e,t){return u.indexOf(e)===t})),x={id:g,reference:e,popper:Oe(),popperInstance:null,props:c,state:{isEnabled:!0,isVisible:!1,isDestroyed:!1,isMounted:!1,isShown:!1},plugins:y,clearDelayTimeouts:function(){clearTimeout(n),clearTimeout(r),cancelAnimationFrame(a)},setProps:function(t){if(!x.state.isDestroyed){O("onBeforeUpdate",[x,t]),G();var n=x.props,r=Je(e,Object.assign({},n,Pe(t),{ignoreAttributes:!0}));x.props=r,H(),n.interactiveDebounce!==r.interactiveDebounce&&(N(),m=Me(W,r.interactiveDebounce)),n.triggerTarget&&!r.triggerTarget?Te(n.triggerTarget).forEach((function(e){e.removeAttribute("aria-expanded")})):r.triggerTarget&&e.removeAttribute("aria-expanded"),D(),P(),b&&b(n,r),x.popperInstance&&(J(),Q().forEach((function(e){requestAnimationFrame(e._tippy.popperInstance.forceUpdate)}))),O("onAfterUpdate",[x,t])}},setContent:function(e){x.setProps({content:e})},show:function(){var e=x.state.isVisible,t=x.state.isDestroyed,n=!x.state.isEnabled,r=Ue.isTouch&&!x.props.touch,a=Ee(x.props.duration,0,Ye.duration);if(!(e||t||n||r||M().hasAttribute("disabled")||(O("onShow",[x],!1),!1===x.props.onShow(x)))){if(x.state.isVisible=!0,k()&&(_.style.visibility="visible"),P(),j(),x.state.isMounted||(_.style.transition="none"),k()){var i=A();ze([i.box,i.content],0)}s=function(){var e;if(x.state.isVisible&&!f){if(f=!0,_.style.transition=x.props.moveTransition,k()&&x.props.animation){var t=A(),n=t.box,r=t.content;ze([n,r],a),Fe([n,r],"visible")}R(),D(),Ae(it,x),null==(e=x.popperInstance)||e.forceUpdate(),O("onMount",[x]),x.props.animation&&k()&&function(e,t){U(e,t)}(a,(function(){x.state.isShown=!0,O("onShown",[x])}))}},function(){var e,t=x.props.appendTo,n=M();(e=x.props.interactive&&t===Se||"parent"===t?n.parentNode:ke(t,[n])).contains(_)||e.appendChild(_),x.state.isMounted=!0,J()}()}},hide:function(){var e=!x.state.isVisible,t=x.state.isDestroyed,n=!x.state.isEnabled,r=Ee(x.props.duration,1,Ye.duration);if(!(e||t||n)&&(O("onHide",[x],!1),!1!==x.props.onHide(x))){if(x.state.isVisible=!1,x.state.isShown=!1,f=!1,d=!1,k()&&(_.style.visibility="hidden"),N(),Z(),P(!0),k()){var a=A(),i=a.box,o=a.content;x.props.animation&&(ze([i,o],r),Fe([i,o],"hidden"))}R(),D(),x.props.animation?k()&&function(e,t){U(e,(function(){!x.state.isVisible&&_.parentNode&&_.parentNode.contains(_)&&t()}))}(r,x.unmount):x.unmount()}},hideWithInteractivity:function(e){T().addEventListener("mousemove",m),Ae(at,m),m(e)},enable:function(){x.state.isEnabled=!0},disable:function(){x.hide(),x.state.isEnabled=!1},unmount:function(){x.state.isVisible&&x.hide(),x.state.isMounted&&($(),Q().forEach((function(e){e._tippy.unmount()})),_.parentNode&&_.parentNode.removeChild(_),it=it.filter((function(e){return e!==x})),x.state.isMounted=!1,O("onHidden",[x]))},destroy:function(){x.state.isDestroyed||(x.clearDelayTimeouts(),x.unmount(),G(),delete e._tippy,x.state.isDestroyed=!0,O("onDestroy",[x]))}};if(!c.render)return x;var I=c.render(x),_=I.popper,b=I.onUpdate;_.setAttribute("data-tippy-root",""),_.id="tippy-"+x.id,x.popper=_,e._tippy=x,_._tippy=x;var w=y.map((function(e){return e.fn(x)})),S=e.hasAttribute("aria-expanded");return H(),D(),P(),O("onCreate",[x]),c.showOnCreate&&ee(),_.addEventListener("mouseenter",(function(){x.props.interactive&&x.state.isVisible&&x.clearDelayTimeouts()})),_.addEventListener("mouseleave",(function(){x.props.interactive&&x.props.trigger.indexOf("mouseenter")>=0&&T().addEventListener("mousemove",m)})),x;function E(){var e=x.props.touch;return Array.isArray(e)?e:[e,0]}function C(){return"hold"===E()[0]}function k(){var e;return!(null==(e=x.props.render)||!e.$$tippy)}function M(){return l||e}function T(){var e=M().parentNode;return e?Be(e):document}function A(){return tt(_)}function L(e){return x.state.isMounted&&!x.state.isVisible||Ue.isTouch||i&&"focus"===i.type?0:Ee(x.props.delay,e?0:1,Ye.delay)}function P(e){void 0===e&&(e=!1),_.style.pointerEvents=x.props.interactive&&!e?"":"none",_.style.zIndex=""+x.props.zIndex}function O(e,t,n){var r;void 0===n&&(n=!0),w.forEach((function(n){n[e]&&n[e].apply(n,t)})),n&&(r=x.props)[e].apply(r,t)}function R(){var t=x.props.aria;if(t.content){var n="aria-"+t.content,r=_.id;Te(x.props.triggerTarget||e).forEach((function(e){var t=e.getAttribute(n);if(x.state.isVisible)e.setAttribute(n,t?t+" "+r:r);else{var a=t&&t.replace(r,"").trim();a?e.setAttribute(n,a):e.removeAttribute(n)}}))}}function D(){!S&&x.props.aria.expanded&&Te(x.props.triggerTarget||e).forEach((function(e){x.props.interactive?e.setAttribute("aria-expanded",x.state.isVisible&&e===M()?"true":"false"):e.removeAttribute("aria-expanded")}))}function N(){T().removeEventListener("mousemove",m),at=at.filter((function(e){return e!==m}))}function z(t){if(!Ue.isTouch||!h&&"mousedown"!==t.type){var n=t.composedPath&&t.composedPath()[0]||t.target;if(!x.props.interactive||!Ze(_,n)){if(Te(x.props.triggerTarget||e).some((function(e){return Ze(e,n)}))){if(Ue.isTouch)return;if(x.state.isVisible&&x.props.trigger.indexOf("click")>=0)return}else O("onClickOutside",[x,t]);!0===x.props.hideOnClick&&(x.clearDelayTimeouts(),x.hide(),p=!0,setTimeout((function(){p=!1})),x.state.isMounted||Z())}}}function F(){h=!0}function B(){h=!1}function j(){var e=T();e.addEventListener("mousedown",z,!0),e.addEventListener("touchend",z,we),e.addEventListener("touchstart",B,we),e.addEventListener("touchmove",F,we)}function Z(){var e=T();e.removeEventListener("mousedown",z,!0),e.removeEventListener("touchend",z,we),e.removeEventListener("touchstart",B,we),e.removeEventListener("touchmove",F,we)}function U(e,t){var n=A().box;function r(e){e.target===n&&(je(n,"remove",r),t())}if(0===e)return t();je(n,"remove",o),je(n,"add",r),o=r}function V(t,n,r){void 0===r&&(r=!1),Te(x.props.triggerTarget||e).forEach((function(e){e.addEventListener(t,n,r),v.push({node:e,eventType:t,handler:n,options:r})}))}function H(){var e;C()&&(V("touchstart",q,{passive:!0}),V("touchend",Y,{passive:!0})),(e=x.props.trigger,e.split(/\s+/).filter(Boolean)).forEach((function(e){if("manual"!==e)switch(V(e,q),e){case"mouseenter":V("mouseleave",Y);break;case"focus":V(We?"focusout":"blur",X);break;case"focusin":V("focusout",X)}}))}function G(){v.forEach((function(e){e.node.removeEventListener(e.eventType,e.handler,e.options)})),v=[]}function q(e){var t,n=!1;if(x.state.isEnabled&&!K(e)&&!p){var r="focus"===(null==(t=i)?void 0:t.type);i=e,l=e.currentTarget,D(),!x.state.isVisible&&De(e)&&at.forEach((function(t){return t(e)})),"click"===e.type&&(0>x.props.trigger.indexOf("mouseenter")||d)&&!1!==x.props.hideOnClick&&x.state.isVisible?n=!0:ee(e),"click"===e.type&&(d=!n),n&&!r&&te(e)}}function W(e){var t=e.target,n=M().contains(t)||_.contains(t);if("mousemove"!==e.type||!n){var r=Q().concat(_).map((function(e){var t,n=null==(t=e._tippy.popperInstance)?void 0:t.state;return n?{popperRect:e.getBoundingClientRect(),popperState:n,props:c}:null})).filter(Boolean);(function(e,t){var n=t.clientX,r=t.clientY;return e.every((function(e){var t=e.popperRect,a=e.popperState,i=e.props.interactiveBorder,o=a.placement.split("-")[0],s=a.modifiersData.offset;return!s||t.top-r+("bottom"===o?s.top.y:0)>i||r-t.bottom-("top"===o?s.bottom.y:0)>i||t.left-n+("right"===o?s.left.x:0)>i||n-t.right-("left"===o?s.right.x:0)>i}))})(r,e)&&(N(),te(e))}}function Y(e){K(e)||x.props.trigger.indexOf("click")>=0&&d||(x.props.interactive?x.hideWithInteractivity(e):te(e))}function X(e){0>x.props.trigger.indexOf("focusin")&&e.target!==M()||x.props.interactive&&e.relatedTarget&&_.contains(e.relatedTarget)||te(e)}function K(e){return!!Ue.isTouch&&C()!==e.type.indexOf("touch")>=0}function J(){$();var t=x.props,n=t.popperOptions,r=t.placement,a=t.offset,i=t.getReferenceClientRect,o=t.moveTransition,l=k()?tt(_).arrow:null,u=i?{getBoundingClientRect:i,contextElement:i.contextElement||M()}:e,c={name:"$$tippy",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn:function(e){var t=e.state;if(k()){var n=A().box;["placement","reference-hidden","escaped"].forEach((function(e){"placement"===e?n.setAttribute("data-placement",t.placement):t.attributes.popper["data-popper-"+e]?n.setAttribute("data-"+e,""):n.removeAttribute("data-"+e)})),t.attributes.popper={}}}},d=[{name:"offset",options:{offset:a}},{name:"preventOverflow",options:{padding:{top:2,bottom:2,left:5,right:5}}},{name:"flip",options:{padding:5}},{name:"computeStyles",options:{adaptive:!o}},c];k()&&l&&d.push({name:"arrow",options:{element:l,padding:3}}),d.push.apply(d,(null==n?void 0:n.modifiers)||[]),x.popperInstance=xe(u,_,Object.assign({},n,{placement:r,onFirstUpdate:s,modifiers:d}))}function $(){x.popperInstance&&(x.popperInstance.destroy(),x.popperInstance=null)}function Q(){return Le(_.querySelectorAll("[data-tippy-root]"))}function ee(e){x.clearDelayTimeouts(),e&&O("onTrigger",[x,e]),j();var t=L(!0),r=E(),a=r[1];Ue.isTouch&&"hold"===r[0]&&a&&(t=a),t?n=setTimeout((function(){x.show()}),t):x.show()}function te(e){if(x.clearDelayTimeouts(),O("onUntrigger",[x,e]),x.state.isVisible){if(0>x.props.trigger.indexOf("mouseenter")||0>x.props.trigger.indexOf("click")||0>["mouseleave","mousemove"].indexOf(e.type)||!d){var t=L(!1);t?r=setTimeout((function(){x.state.isVisible&&x.hide()}),t):a=requestAnimationFrame((function(){x.hide()}))}}else Z()}}function st(e,t){void 0===t&&(t={});var n=Ye.plugins.concat(t.plugins||[]);document.addEventListener("touchstart",He,we),window.addEventListener("blur",qe);var r=Object.assign({},t,{plugins:n}),a=Ne(e).reduce((function(e,t){var n=t&&ot(t,r);return n&&e.push(n),e}),[]);return Re(e)?a[0]:a}st.defaultProps=Ye,st.setDefaultProps=function(e){Object.keys(e).forEach((function(t){Ye[t]=e[t]}))},st.currentInput=Ue,Object.assign({},w,{effect:function(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow)}});var lt={clientX:0,clientY:0},ut=[];function ct(e){lt={clientX:e.clientX,clientY:e.clientY}}var dt={name:"followCursor",defaultValue:!1,fn:function(e){var t=e.reference,n=Be(e.props.triggerTarget||t),r=!1,a=!1,i=!0,o=e.props;function s(){return"initial"===e.props.followCursor&&e.state.isVisible}function l(){n.addEventListener("mousemove",d)}function u(){n.removeEventListener("mousemove",d)}function c(){r=!0,e.setProps({getReferenceClientRect:null}),r=!1}function d(n){var r=!n.target||t.contains(n.target),a=e.props.followCursor,i=n.clientX,o=n.clientY,s=t.getBoundingClientRect(),l=i-s.left,u=o-s.top;!r&&e.props.interactive||e.setProps({getReferenceClientRect:function(){var e=t.getBoundingClientRect(),n=i,r=o;"initial"===a&&(n=e.left+l,r=e.top+u);var s="horizontal"===a?e.top:r,c="vertical"===a?e.right:n,d="horizontal"===a?e.bottom:r,p="vertical"===a?e.left:n;return{width:c-p,height:d-s,top:s,right:c,bottom:d,left:p}}})}function p(){e.props.followCursor&&(ut.push({instance:e,doc:n}),function(e){e.addEventListener("mousemove",ct)}(n))}function h(){0===(ut=ut.filter((function(t){return t.instance!==e}))).filter((function(e){return e.doc===n})).length&&function(e){e.removeEventListener("mousemove",ct)}(n)}return{onCreate:p,onDestroy:h,onBeforeUpdate:function(){o=e.props},onAfterUpdate:function(t,n){var i=n.followCursor;r||void 0!==i&&o.followCursor!==i&&(h(),i?(p(),!e.state.isMounted||a||s()||l()):(u(),c()))},onMount:function(){e.props.followCursor&&!a&&(i&&(d(lt),i=!1),s()||l())},onTrigger:function(e,t){De(t)&&(lt={clientX:t.clientX,clientY:t.clientY}),a="focus"===t.type},onHidden:function(){e.props.followCursor&&(c(),u(),i=!0)}}}};st.setDefaultProps({render:nt});var pt,ht,ft,vt,mt,gt,yt={showTotalDistance:!1,showDashDistance:!0,showWhen:["normal","active"],format:function(e){return 1e3>e?+e.toFixed(2)+"m":+(e/1e3).toFixed(2)+"km"}},xt={showWhen:["normal","active"],format:function(e){return e>1e6?"".concat(+(e/1e6).toFixed(2),"km²"):"".concat(+e.toFixed(2),"m²")}},It={maxSize:100},_t={remove:["del","backspace"],revert:["command+z","ctrl+z"],redo:["command+shift+z","ctrl+shift+z"]},bt={allowHTML:!0,followCursor:!0,placement:"bottom-start",offset:[-10,20],plugins:[dt],trigger:"manual",hideOnClick:!1,theme:"light"},wt={data:"drawData",pointAdsorbPixel:12,lineAdsorbPixel:10};function St(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Et(e){for(var t=1;arguments.length>t;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?St(Object(n),!0).forEach((function(t){Tt(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):St(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Ct(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function kt(e,t){for(var n=0;t.length>n;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,Ut(r.key),r)}}function Mt(e,t,n){return t&&kt(e.prototype,t),n&&kt(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Tt(e,t,n){return(t=Ut(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function At(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Pt(e,t)}function Lt(e){return Lt=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Lt(e)}function Pt(e,t){return Pt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},Pt(e,t)}function Ot(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Rt(e,t){if(t&&("object"==typeof t||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return Ot(e)}function Dt(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Lt(e);if(t){var a=Lt(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return Rt(this,n)}}function Nt(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Lt(e)););return e}function zt(){return zt="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=Nt(e,t);if(r){var a=Object.getOwnPropertyDescriptor(r,t);return a.get?a.get.call(3>arguments.length?e:n):a.value}},zt.apply(this,arguments)}function Ft(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,a,i,o,s=[],l=!0,u=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(e){u=!0,a=e}finally{try{if(!l&&null!=n.return&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw a}}return s}}(e,t)||jt(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Bt(e){return function(e){if(Array.isArray(e))return Zt(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||jt(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function jt(e,t){if(e){if("string"==typeof e)return Zt(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Zt(e,t):void 0}}function Zt(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);t>n;n++)r[n]=e[n];return r}function Ut(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(pt=e.DrawEvent||(e.DrawEvent={})).Init="init",pt.Destroy="destroy",pt.Enable="enable",pt.Disable="disable",pt.Add="add",pt.Edit="edit",pt.Remove="remove",pt.Clear="clear",pt.Change="change",pt.DragStart="dragStart",pt.Dragging="dragging",pt.DragEnd="dragEnd",pt.AddNode="addNode",pt.RemoveNode="removeNode",(ht=e.SourceEvent||(e.SourceEvent={})).Change="change",ht.Update="update",(ft=e.RenderEvent||(e.RenderEvent={})).Click="click",ft.UnClick="unclick",ft.Dragstart="dragstart",ft.Mousemove="mousemove",ft.Mouseout="mouseout",ft.Dragging="dragging",ft.Dragend="dragend",ft.DblClick="dblClick",ft.Contextmenu="contextmenu",(vt=e.LayerEvent||(e.LayerEvent={})).Mousedown="mousedown",vt.Mouseup="mouseup",vt.Click="click",vt.UnClick="unclick",vt.Dblclick="dblclick",vt.Mousemove="mousemove",vt.Mouseover="mouseover",vt.Mouseenter="mouseenter",vt.Mouseleave="mouseleave",vt.Mouseout="mouseout",vt.Contextmenu="contextmenu",(mt=e.SceneEvent||(e.SceneEvent={})).Loaded="loaded",mt.MapMove="mapmove",mt.MoveStart="movestart",mt.MoveEnd="moveend",mt.ZoomChange="zoomchange",mt.ZoomStart="zoomstart",mt.ZoomEnd="zoomend",mt.Click="click",mt.Dblclick="dblclick",mt.Mousemove="mousemove",mt.Mousewheel="mousewheel",mt.Mouseover="mouseover",mt.Mouseout="mouseout",mt.Mouseup="mouseup",mt.Mousedown="mousedown",mt.Contextmenu="contextmenu",mt.Dragstart="dragstart",mt.Dragging="dragging",mt.Dragend="dragend",(gt=e.ControlEvent||(e.ControlEvent={})).DrawChange="drawchange",gt.DataChange="datachange";var Vt=6371008.8,Ht={centimeters:637100880,centimetres:637100880,degrees:57.22891354143274,feet:20902260.511392,inches:39.37*Vt,kilometers:6371.0088,kilometres:6371.0088,meters:Vt,metres:Vt,miles:3958.761333810546,millimeters:6371008800,millimetres:6371008800,nauticalmiles:Vt/1852,radians:1,yards:6967335.223679999},Gt={acres:247105e-9,centimeters:1e4,centimetres:1e4,feet:10.763910417,hectares:1e-4,inches:1550.003100006,kilometers:1e-6,kilometres:1e-6,meters:1,metres:1,miles:386e-9,millimeters:1e6,millimetres:1e6,yards:1.195990046};function qt(e,t,n){void 0===n&&(n={});var r={type:"Feature"};return(0===n.id||n.id)&&(r.id=n.id),n.bbox&&(r.bbox=n.bbox),r.properties=t||{},r.geometry=e,r}function Wt(e,t,n){if(void 0===n&&(n={}),!e)throw Error("coordinates is required");if(!Array.isArray(e))throw Error("coordinates must be an Array");if(2>e.length)throw Error("coordinates must be at least 2 numbers long");if(!an(e[0])||!an(e[1]))throw Error("coordinates must contain numbers");return qt({type:"Point",coordinates:e},t,n)}function Yt(e,t,n){void 0===n&&(n={});for(var r=0,a=e;a.length>r;r++){var i=a[r];if(4>i.length)throw Error("Each LinearRing of a Polygon must have 4 or more Positions.");for(var o=0;i[i.length-1].length>o;o++)if(i[i.length-1][o]!==i[0][o])throw Error("First and last Position are not equivalent.")}return qt({type:"Polygon",coordinates:e},t,n)}function Xt(e,t,n){if(void 0===n&&(n={}),2>e.length)throw Error("coordinates must be an array of two or more positions");return qt({type:"LineString",coordinates:e},t,n)}function Kt(e,t){void 0===t&&(t={});var n={type:"FeatureCollection"};return t.id&&(n.id=t.id),t.bbox&&(n.bbox=t.bbox),n.features=e,n}function Jt(e,t,n){return void 0===n&&(n={}),qt({type:"MultiLineString",coordinates:e},t,n)}function $t(e,t,n){return void 0===n&&(n={}),qt({type:"MultiPoint",coordinates:e},t,n)}function Qt(e,t,n){return void 0===n&&(n={}),qt({type:"MultiPolygon",coordinates:e},t,n)}function en(e,t){void 0===t&&(t="kilometers");var n=Ht[t];if(!n)throw Error(t+" units is invalid");return e*n}function tn(e,t){void 0===t&&(t="kilometers");var n=Ht[t];if(!n)throw Error(t+" units is invalid");return e/n}function nn(e){return e%(2*Math.PI)*180/Math.PI}function rn(e){return e%360*Math.PI/180}function an(e){return!isNaN(e)&&null!==e&&!Array.isArray(e)}function on(e){return!!e&&e.constructor===Object}var sn=Object.freeze({__proto__:null,earthRadius:Vt,factors:Ht,unitsFactors:{centimeters:100,centimetres:100,degrees:1/111325,feet:3.28084,inches:39.37,kilometers:.001,kilometres:.001,meters:1,metres:1,miles:1/1609.344,millimeters:1e3,millimetres:1e3,nauticalmiles:1/1852,radians:1/Vt,yards:1.0936133},areaFactors:Gt,feature:qt,geometry:function(e,t,n){switch(e){case"Point":return Wt(t).geometry;case"LineString":return Xt(t).geometry;case"Polygon":return Yt(t).geometry;case"MultiPoint":return $t(t).geometry;case"MultiLineString":return Jt(t).geometry;case"MultiPolygon":return Qt(t).geometry;default:throw Error(e+" is invalid")}},point:Wt,points:function(e,t,n){return void 0===n&&(n={}),Kt(e.map((function(e){return Wt(e,t)})),n)},polygon:Yt,polygons:function(e,t,n){return void 0===n&&(n={}),Kt(e.map((function(e){return Yt(e,t)})),n)},lineString:Xt,lineStrings:function(e,t,n){return void 0===n&&(n={}),Kt(e.map((function(e){return Xt(e,t)})),n)},featureCollection:Kt,multiLineString:Jt,multiPoint:$t,multiPolygon:Qt,geometryCollection:function(e,t,n){return void 0===n&&(n={}),qt({type:"GeometryCollection",geometries:e},t,n)},round:function(e,t){if(void 0===t&&(t=0),t&&t<0)throw Error("precision must be a positive number");var n=Math.pow(10,t||0);return Math.round(e*n)/n},radiansToLength:en,lengthToRadians:tn,lengthToDegrees:function(e,t){return nn(tn(e,t))},bearingToAzimuth:function(e){var t=e%360;return 0>t&&(t+=360),t},radiansToDegrees:nn,degreesToRadians:rn,convertLength:function(e,t,n){if(void 0===t&&(t="kilometers"),void 0===n&&(n="kilometers"),e<0)throw Error("length must be a positive number");return en(tn(e,t),n)},convertArea:function(e,t,n){if(void 0===t&&(t="meters"),void 0===n&&(n="kilometers"),e<0)throw Error("area must be a positive number");var r=Gt[t];if(!r)throw Error("invalid original units");var a=Gt[n];if(!a)throw Error("invalid final units");return e/r*a},isNumber:an,isObject:on,validateBBox:function(e){if(!e)throw Error("bbox is required");if(!Array.isArray(e))throw Error("bbox must be an Array");if(4!==e.length&&6!==e.length)throw Error("bbox must be an Array of 4 or 6 numbers");e.forEach((function(e){if(!an(e))throw Error("bbox must only contain numbers")}))},validateId:function(e){if(!e)throw Error("id is required");if(-1===["string","number"].indexOf(typeof e))throw Error("id must be a number or a string")}});function ln(e,t,n){if(null!==e)for(var r,a,i,o,s,l,u,c,d=0,p=0,h=e.type,f="FeatureCollection"===h,v="Feature"===h,m=f?e.features.length:1,g=0;m>g;g++){s=(c=!!(u=f?e.features[g].geometry:v?e.geometry:e)&&"GeometryCollection"===u.type)?u.geometries.length:1;for(var y=0;s>y;y++){var x=0,I=0;if(null!==(o=c?u.geometries[y]:u)){l=o.coordinates;var _=o.type;switch(d=!n||"Polygon"!==_&&"MultiPolygon"!==_?0:1,_){case null:break;case"Point":if(!1===t(l,p,g,x,I))return!1;p++,x++;break;case"LineString":case"MultiPoint":for(r=0;l.length>r;r++){if(!1===t(l[r],p,g,x,I))return!1;p++,"MultiPoint"===_&&x++}"LineString"===_&&x++;break;case"Polygon":case"MultiLineString":for(r=0;l.length>r;r++){for(a=0;l[r].length-d>a;a++){if(!1===t(l[r][a],p,g,x,I))return!1;p++}"MultiLineString"===_&&x++,"Polygon"===_&&I++}"Polygon"===_&&x++;break;case"MultiPolygon":for(r=0;l.length>r;r++){for(I=0,a=0;l[r].length>a;a++){for(i=0;l[r][a].length-d>i;i++){if(!1===t(l[r][a][i],p,g,x,I))return!1;p++}I++}x++}break;case"GeometryCollection":for(r=0;o.geometries.length>r;r++)if(!1===ln(o.geometries[r],t,n))return!1;break;default:throw Error("Unknown Geometry Type")}}}}}function un(e,t){var n;switch(e.type){case"FeatureCollection":for(n=0;e.features.length>n&&!1!==t(e.features[n].properties,n);n++);break;case"Feature":t(e.properties,0)}}function cn(e,t){if("Feature"===e.type)t(e,0);else if("FeatureCollection"===e.type)for(var n=0;e.features.length>n&&!1!==t(e.features[n],n);n++);}function dn(e){var t=[];return ln(e,(function(e){t.push(e)})),t}function pn(e,t){var n,r,a,i,o,s,l,u,c,d,p=0,h="FeatureCollection"===e.type,f="Feature"===e.type,v=h?e.features.length:1;for(n=0;v>n;n++){for(u=h?e.features[n].properties:f?e.properties:{},c=h?e.features[n].bbox:f?e.bbox:void 0,d=h?e.features[n].id:f?e.id:void 0,o=(l=!!(s=h?e.features[n].geometry:f?e.geometry:e)&&"GeometryCollection"===s.type)?s.geometries.length:1,a=0;o>a;a++)if(null!==(i=l?s.geometries[a]:s))switch(i.type){case"Point":case"LineString":case"MultiPoint":case"Polygon":case"MultiLineString":case"MultiPolygon":if(!1===t(i,p,u,c,d))return!1;break;case"GeometryCollection":for(r=0;i.geometries.length>r;r++)if(!1===t(i.geometries[r],p,u,c,d))return!1;break;default:throw Error("Unknown Geometry Type")}else if(!1===t(null,p,u,c,d))return!1;p++}}function hn(e,t,n){var r=n;return pn(e,(function(e,a,i,o,s){r=0===a&&void 0===n?e:t(r,e,a,i,o,s)})),r}function fn(e,t){pn(e,(function(e,n,r,a,i){var o,s=null===e?null:e.type;switch(s){case null:case"Point":case"LineString":case"Polygon":return!1!==t(qt(e,r,{bbox:a,id:i}),n,0)&&void 0}switch(s){case"MultiPoint":o="Point";break;case"MultiLineString":o="LineString";break;case"MultiPolygon":o="Polygon"}for(var l=0;e.coordinates.length>l;l++)if(!1===t(qt({type:o,coordinates:e.coordinates[l]},r),n,l))return!1}))}function vn(e,t){fn(e,(function(e,n,r){var a=0;if(e.geometry){var i=e.geometry.type;if("Point"!==i&&"MultiPoint"!==i){var o,s=0,l=0,u=0;return!1!==ln(e,(function(i,c,d,p,h){if(void 0===o||n>s||p>l||h>u)return o=i,s=n,l=p,u=h,void(a=0);var f=Xt([o,i],e.properties);if(!1===t(f,n,r,h,a))return!1;a++,o=i}))&&void 0}}}))}function mn(e,t,n){var r=n,a=!1;return vn(e,(function(e,i,o,s,l){r=!1===a&&void 0===n?e:t(r,e,i,o,s,l),a=!0})),r}function gn(e,t){if(!e)throw Error("geojson is required");fn(e,(function(e,n,r){if(null!==e.geometry){var a=e.geometry.coordinates;switch(e.geometry.type){case"LineString":if(!1===t(e,n,r,0,0))return!1;break;case"Polygon":for(var i=0;a.length>i;i++)if(!1===t(Xt(a[i],e.properties),n,r,i))return!1}}}))}var yn=Object.freeze({__proto__:null,coordAll:dn,coordEach:ln,coordReduce:function(e,t,n,r){var a=n;return ln(e,(function(e,r,i,o,s){a=0===r&&void 0===n?e:t(a,e,r,i,o,s)}),r),a},featureEach:cn,featureReduce:function(e,t,n){var r=n;return cn(e,(function(e,a){r=0===a&&void 0===n?e:t(r,e,a)})),r},findPoint:function(e,t){if(!on(t=t||{}))throw Error("options is invalid");var n,r=t.featureIndex||0,a=t.multiFeatureIndex||0,i=t.geometryIndex||0,o=t.coordIndex||0,s=t.properties;switch(e.type){case"FeatureCollection":0>r&&(r=e.features.length+r),s=s||e.features[r].properties,n=e.features[r].geometry;break;case"Feature":s=s||e.properties,n=e.geometry;break;case"Point":case"MultiPoint":return null;case"LineString":case"Polygon":case"MultiLineString":case"MultiPolygon":n=e;break;default:throw Error("geojson is invalid")}if(null===n)return null;var l=n.coordinates;switch(n.type){case"Point":return Wt(l,s,t);case"MultiPoint":return 0>a&&(a=l.length+a),Wt(l[a],s,t);case"LineString":return 0>o&&(o=l.length+o),Wt(l[o],s,t);case"Polygon":return 0>i&&(i=l.length+i),0>o&&(o=l[i].length+o),Wt(l[i][o],s,t);case"MultiLineString":return 0>a&&(a=l.length+a),0>o&&(o=l[a].length+o),Wt(l[a][o],s,t);case"MultiPolygon":return 0>a&&(a=l.length+a),0>i&&(i=l[a].length+i),0>o&&(o=l[a][i].length-o),Wt(l[a][i][o],s,t)}throw Error("geojson is invalid")},findSegment:function(e,t){if(!on(t=t||{}))throw Error("options is invalid");var n,r=t.featureIndex||0,a=t.multiFeatureIndex||0,i=t.geometryIndex||0,o=t.segmentIndex||0,s=t.properties;switch(e.type){case"FeatureCollection":0>r&&(r=e.features.length+r),s=s||e.features[r].properties,n=e.features[r].geometry;break;case"Feature":s=s||e.properties,n=e.geometry;break;case"Point":case"MultiPoint":return null;case"LineString":case"Polygon":case"MultiLineString":case"MultiPolygon":n=e;break;default:throw Error("geojson is invalid")}if(null===n)return null;var l=n.coordinates;switch(n.type){case"Point":case"MultiPoint":return null;case"LineString":return 0>o&&(o=l.length+o-1),Xt([l[o],l[o+1]],s,t);case"Polygon":return 0>i&&(i=l.length+i),0>o&&(o=l[i].length+o-1),Xt([l[i][o],l[i][o+1]],s,t);case"MultiLineString":return 0>a&&(a=l.length+a),0>o&&(o=l[a].length+o-1),Xt([l[a][o],l[a][o+1]],s,t);case"MultiPolygon":return 0>a&&(a=l.length+a),0>i&&(i=l[a].length+i),0>o&&(o=l[a][i].length-o-1),Xt([l[a][i][o],l[a][i][o+1]],s,t)}throw Error("geojson is invalid")},flattenEach:fn,flattenReduce:function(e,t,n){var r=n;return fn(e,(function(e,a,i){r=0===a&&0===i&&void 0===n?e:t(r,e,a,i)})),r},geomEach:pn,geomReduce:hn,lineEach:gn,lineReduce:function(e,t,n){var r=n;return gn(e,(function(e,a,i,o){r=0===a&&void 0===n?e:t(r,e,a,i,o)})),r},propEach:un,propReduce:function(e,t,n){var r=n;return un(e,(function(e,a){r=0===a&&void 0===n?e:t(r,e,a)})),r},segmentEach:vn,segmentReduce:mn});function xn(e){var t=[1/0,1/0,-1/0,-1/0];return ln(e,(function(e){t[0]>e[0]&&(t[0]=e[0]),t[1]>e[1]&&(t[1]=e[1]),e[0]>t[2]&&(t[2]=e[0]),e[1]>t[3]&&(t[3]=e[1])})),t}xn.default=xn;var In=Object.freeze({__proto__:null,default:xn});function _n(e){if(!e)throw Error("coord is required");if(!Array.isArray(e)){if("Feature"===e.type&&null!==e.geometry&&"Point"===e.geometry.type)return e.geometry.coordinates;if("Point"===e.type)return e.coordinates}if(Array.isArray(e)&&e.length>=2&&!Array.isArray(e[0])&&!Array.isArray(e[1]))return e;throw Error("coord must be GeoJSON Point or an Array of numbers")}function bn(e){if(Array.isArray(e))return e;if("Feature"===e.type){if(null!==e.geometry)return e.geometry.coordinates}else if(e.coordinates)return e.coordinates;throw Error("coords must be GeoJSON Feature, Geometry Object or an Array")}function wn(e){return"Feature"===e.type?e.geometry:e}function Sn(e,t){return"FeatureCollection"===e.type?"FeatureCollection":"GeometryCollection"===e.type?"GeometryCollection":"Feature"===e.type&&null!==e.geometry?e.geometry.type:e.type}function En(e,t,n,r,a){Cn(e,t,n||0,r||e.length-1,a||Mn)}function Cn(e,t,n,r,a){for(;r>n;){if(r-n>600){var i=r-n+1,o=t-n+1,s=Math.log(i),l=.5*Math.exp(2*s/3),u=.5*Math.sqrt(s*l*(i-l)/i)*(0>o-i/2?-1:1);Cn(e,t,Math.max(n,Math.floor(t-o*l/i+u)),Math.min(r,Math.floor(t+(i-o)*l/i+u)),a)}var c=e[t],d=n,p=r;for(kn(e,n,t),a(e[r],c)>0&&kn(e,n,r);p>d;){for(kn(e,d,p),d++,p--;0>a(e[d],c);)d++;for(;a(e[p],c)>0;)p--}0===a(e[n],c)?kn(e,n,p):kn(e,++p,r),p>t||(n=p+1),t>p||(r=p-1)}}function kn(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function Mn(e,t){return t>e?-1:e>t?1:0}function Tn(e,t,n){if(!n)return t.indexOf(e);for(let r=0;t.length>r;r++)if(n(e,t[r]))return r;return-1}function An(e,t){Ln(e,0,e.children.length,t,e)}function Ln(e,t,n,r,a){a||(a=jn(null)),a.minX=1/0,a.minY=1/0,a.maxX=-1/0,a.maxY=-1/0;for(let i=t;n>i;i++){const t=e.children[i];Pn(a,e.leaf?r(t):t)}return a}function Pn(e,t){return e.minX=Math.min(e.minX,t.minX),e.minY=Math.min(e.minY,t.minY),e.maxX=Math.max(e.maxX,t.maxX),e.maxY=Math.max(e.maxY,t.maxY),e}function On(e,t){return e.minX-t.minX}function Rn(e,t){return e.minY-t.minY}function Dn(e){return(e.maxX-e.minX)*(e.maxY-e.minY)}function Nn(e){return e.maxX-e.minX+(e.maxY-e.minY)}function zn(e,t){const n=Math.max(e.minX,t.minX),r=Math.max(e.minY,t.minY),a=Math.min(e.maxX,t.maxX),i=Math.min(e.maxY,t.maxY);return Math.max(0,a-n)*Math.max(0,i-r)}function Fn(e,t){return!(e.minX>t.minX||e.minY>t.minY||t.maxX>e.maxX||t.maxY>e.maxY)}function Bn(e,t){return!(t.minX>e.maxX||t.minY>e.maxY||e.minX>t.maxX||e.minY>t.maxY)}function jn(e){return{children:e,height:1,leaf:!0,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0}}function Zn(e,t,n,r,a){const i=[t,n];for(;i.length;){if(r>=(n=i.pop())-(t=i.pop()))continue;const o=t+Math.ceil((n-t)/r/2)*r;En(e,o,t,n,a),i.push(t,o,o,n)}}var Un=Object.freeze({__proto__:null,default:class{constructor(e=9){this._maxEntries=Math.max(4,e),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),this.clear()}all(){return this._all(this.data,[])}search(e){let t=this.data;const n=[];if(!Bn(e,t))return n;const r=this.toBBox,a=[];for(;t;){for(let i=0;t.children.length>i;i++){const o=t.children[i],s=t.leaf?r(o):o;Bn(e,s)&&(t.leaf?n.push(o):Fn(e,s)?this._all(o,n):a.push(o))}t=a.pop()}return n}collides(e){let t=this.data;if(!Bn(e,t))return!1;const n=[];for(;t;){for(let r=0;t.children.length>r;r++){const a=t.children[r],i=t.leaf?this.toBBox(a):a;if(Bn(e,i)){if(t.leaf||Fn(e,i))return!0;n.push(a)}}t=n.pop()}return!1}load(e){if(!e||!e.length)return this;if(this._minEntries>e.length){for(let t=0;e.length>t;t++)this.insert(e[t]);return this}let t=this._build(e.slice(),0,e.length-1,0);if(this.data.children.length)if(this.data.height===t.height)this._splitRoot(this.data,t);else{if(t.height>this.data.height){const e=this.data;this.data=t,t=e}this._insert(t,this.data.height-t.height-1,!0)}else this.data=t;return this}insert(e){return e&&this._insert(e,this.data.height-1),this}clear(){return this.data=jn([]),this}remove(e,t){if(!e)return this;let n=this.data;const r=this.toBBox(e),a=[],i=[];let o,s,l;for(;n||a.length;){if(n||(n=a.pop(),s=a[a.length-1],o=i.pop(),l=!0),n.leaf){const r=Tn(e,n.children,t);if(-1!==r)return n.children.splice(r,1),a.push(n),this._condense(a),this}l||n.leaf||!Fn(n,r)?s?(o++,n=s.children[o],l=!1):n=null:(a.push(n),i.push(o),o=0,s=n,n=n.children[0])}return this}toBBox(e){return e}compareMinX(e,t){return e.minX-t.minX}compareMinY(e,t){return e.minY-t.minY}toJSON(){return this.data}fromJSON(e){return this.data=e,this}_all(e,t){const n=[];for(;e;)e.leaf?t.push(...e.children):n.push(...e.children),e=n.pop();return t}_build(e,t,n,r){const a=n-t+1;let i,o=this._maxEntries;if(o>=a)return i=jn(e.slice(t,n+1)),An(i,this.toBBox),i;r||(o=Math.ceil(a/Math.pow(o,(r=Math.ceil(Math.log(a)/Math.log(o)))-1))),i=jn([]),i.leaf=!1,i.height=r;const s=Math.ceil(a/o),l=s*Math.ceil(Math.sqrt(o));Zn(e,t,n,l,this.compareMinX);for(let a=t;n>=a;a+=l){const t=Math.min(a+l-1,n);Zn(e,a,t,s,this.compareMinY);for(let n=a;t>=n;n+=s)i.children.push(this._build(e,n,Math.min(n+s-1,t),r-1))}return An(i,this.toBBox),i}_chooseSubtree(e,t,n,r){for(;r.push(t),!t.leaf&&r.length-1!==n;){let n,r=1/0,o=1/0;for(let s=0;t.children.length>s;s++){const l=t.children[s],u=Dn(l),c=(Math.max((i=l).maxX,(a=e).maxX)-Math.min(i.minX,a.minX))*(Math.max(i.maxY,a.maxY)-Math.min(i.minY,a.minY))-u;o>c?(o=c,r=r>u?u:r,n=l):c===o&&r>u&&(r=u,n=l)}t=n||t.children[0]}var a,i;return t}_insert(e,t,n){const r=n?e:this.toBBox(e),a=[],i=this._chooseSubtree(r,this.data,t,a);for(i.children.push(e),Pn(i,r);t>=0&&a[t].children.length>this._maxEntries;)this._split(a,t),t--;this._adjustParentBBoxes(r,a,t)}_split(e,t){const n=e[t],r=n.children.length,a=this._minEntries;this._chooseSplitAxis(n,a,r);const i=this._chooseSplitIndex(n,a,r),o=jn(n.children.splice(i,n.children.length-i));o.height=n.height,o.leaf=n.leaf,An(n,this.toBBox),An(o,this.toBBox),t?e[t-1].children.push(o):this._splitRoot(n,o)}_splitRoot(e,t){this.data=jn([e,t]),this.data.height=e.height+1,this.data.leaf=!1,An(this.data,this.toBBox)}_chooseSplitIndex(e,t,n){let r,a=1/0,i=1/0;for(let o=t;n-t>=o;o++){const t=Ln(e,0,o,this.toBBox),s=Ln(e,o,n,this.toBBox),l=zn(t,s),u=Dn(t)+Dn(s);a>l?(a=l,r=o,i=i>u?u:i):l===a&&i>u&&(i=u,r=o)}return r||n-t}_chooseSplitAxis(e,t,n){const r=e.leaf?this.compareMinX:On,a=e.leaf?this.compareMinY:Rn,i=this._allDistMargin(e,t,n,r);this._allDistMargin(e,t,n,a)>i&&e.children.sort(r)}_allDistMargin(e,t,n,r){e.children.sort(r);const a=this.toBBox,i=Ln(e,0,t,a),o=Ln(e,n-t,n,a);let s=Nn(i)+Nn(o);for(let r=t;n-t>r;r++){const t=e.children[r];Pn(i,e.leaf?a(t):t),s+=Nn(i)}for(let r=n-t-1;r>=t;r--){const t=e.children[r];Pn(o,e.leaf?a(t):t),s+=Nn(o)}return s}_adjustParentBBoxes(e,t,n){for(let r=n;r>=0;r--)Pn(t[r],e)}_condense(e){for(let t,n=e.length-1;n>=0;n--)0===e[n].children.length?n>0?(t=e[n-1].children,t.splice(t.indexOf(e[n]),1)):this.clear():An(e[n],this.toBBox)}}});function Vn(e,t){return t>e?-1:e>t?1:0}var Hn=Object.freeze({__proto__:null,default:class{constructor(e=[],t=Vn){if(this.data=e,this.length=this.data.length,this.compare=t,this.length>0)for(let e=(this.length>>1)-1;e>=0;e--)this._down(e)}push(e){this.data.push(e),this.length++,this._up(this.length-1)}pop(){if(0===this.length)return;const e=this.data[0],t=this.data.pop();return this.length--,this.length>0&&(this.data[0]=t,this._down(0)),e}peek(){return this.data[0]}_up(e){const{data:t,compare:n}=this,r=t[e];for(;e>0;){const a=e-1>>1,i=t[a];if(n(r,i)>=0)break;t[e]=i,e=a}t[e]=r}_down(e){const{data:t,compare:n}=this,r=this.length>>1,a=t[e];for(;r>e;){let r=1+(e<<1),i=t[r];const o=r+1;if(this.length>o&&0>n(t[o],i)&&(r=o,i=t[o]),n(i,a)>=0)break;t[e]=i,e=r}t[e]=a}}}),Gn=function(e,t,n,r){var a=e[0],i=e[1],o=!1;void 0===n&&(n=0),void 0===r&&(r=t.length);for(var s=(r-n)/2,l=0,u=s-1;s>l;u=l++){var c=t[n+2*l+0],d=t[n+2*l+1],p=t[n+2*u+1];d>i!=p>i&&(t[n+2*u+0]-c)*(i-d)/(p-d)+c>a&&(o=!o)}return o},qn=function(e,t,n,r){var a=e[0],i=e[1],o=!1;void 0===n&&(n=0),void 0===r&&(r=t.length);for(var s=r-n,l=0,u=s-1;s>l;u=l++){var c=t[l+n][0],d=t[l+n][1],p=t[u+n][1];d>i!=p>i&&(t[u+n][0]-c)*(i-d)/(p-d)+c>a&&(o=!o)}return o},Wn=function(e,t,n,r){return t.length>0&&Array.isArray(t[0])?qn(e,t,n,r):Gn(e,t,n,r)},Yn=Gn;Wn.nested=qn,Wn.flat=Yn;var Xn="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==n.g?n.g:"undefined"!=typeof self?self:{};function Kn(e,t,n){return e(n={path:t,exports:{},require:function(e,t){return function(){throw Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}()}},n.exports),n.exports}function Jn(e){if(e.__esModule)return e;var t=Object.defineProperty({},"__esModule",{value:!0});return Object.keys(e).forEach((function(n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})})),t}var $n=Kn((function(e,t){!function(e){const t=134217729,n=33306690738754706e-32;function r(e,t,n,r,a){let i,o,s,l,u=t[0],c=r[0],d=0,p=0;c>u==c>-u?(i=u,u=t[++d]):(i=c,c=r[++p]);let h=0;if(e>d&&n>p)for(c>u==c>-u?(s=i-((o=u+i)-u),u=t[++d]):(s=i-((o=c+i)-c),c=r[++p]),i=o,0!==s&&(a[h++]=s);e>d&&n>p;)c>u==c>-u?(s=i-((o=i+u)-(l=o-i))+(u-l),u=t[++d]):(s=i-((o=i+c)-(l=o-i))+(c-l),c=r[++p]),i=o,0!==s&&(a[h++]=s);for(;e>d;)s=i-((o=i+u)-(l=o-i))+(u-l),u=t[++d],i=o,0!==s&&(a[h++]=s);for(;n>p;)s=i-((o=i+c)-(l=o-i))+(c-l),c=r[++p],i=o,0!==s&&(a[h++]=s);return 0===i&&0!==h||(a[h++]=i),h}function a(e){return new Float64Array(e)}const i=33306690738754716e-32,o=22204460492503146e-32,s=11093356479670487e-47,l=a(4),u=a(8),c=a(12),d=a(16),p=a(4);e.orient2d=function(e,a,h,f,v,m){const g=(a-m)*(h-v),y=(e-v)*(f-m),x=g-y;if(0===g||0===y||g>0!=y>0)return x;const I=Math.abs(g+y);return i*I>Math.abs(x)?-function(e,a,i,h,f,v,m){let g,y,x,I,_,b,w,S,E,C,k,M,T,A,L,P,O,R;const D=e-f,N=i-f,z=a-v,F=h-v;_=(L=(S=D-(w=(b=t*D)-(b-D)))*(C=F-(E=(b=t*F)-(b-F)))-((A=D*F)-w*E-S*E-w*C))-(k=L-(O=(S=z-(w=(b=t*z)-(b-z)))*(C=N-(E=(b=t*N)-(b-N)))-((P=z*N)-w*E-S*E-w*C))),l[0]=L-(k+_)+(_-O),_=(T=A-((M=A+k)-(_=M-A))+(k-_))-(k=T-P),l[1]=T-(k+_)+(_-P),_=(R=M+k)-M,l[2]=M-(R-_)+(k-_),l[3]=R;let B=function(e,t){let n=t[0];for(let r=1;e>r;r++)n+=t[r];return n}(4,l),j=o*m;if(B>=j||-B>=j)return B;if(g=e-(D+(_=e-D))+(_-f),x=i-(N+(_=i-N))+(_-f),y=a-(z+(_=a-z))+(_-v),I=h-(F+(_=h-F))+(_-v),0===g&&0===y&&0===x&&0===I)return B;if(j=s*m+n*Math.abs(B),(B+=D*I+F*g-(z*x+N*y))>=j||-B>=j)return B;_=(L=(S=g-(w=(b=t*g)-(b-g)))*(C=F-(E=(b=t*F)-(b-F)))-((A=g*F)-w*E-S*E-w*C))-(k=L-(O=(S=y-(w=(b=t*y)-(b-y)))*(C=N-(E=(b=t*N)-(b-N)))-((P=y*N)-w*E-S*E-w*C))),p[0]=L-(k+_)+(_-O),_=(T=A-((M=A+k)-(_=M-A))+(k-_))-(k=T-P),p[1]=T-(k+_)+(_-P),_=(R=M+k)-M,p[2]=M-(R-_)+(k-_),p[3]=R;const Z=r(4,l,4,p,u);_=(L=(S=D-(w=(b=t*D)-(b-D)))*(C=I-(E=(b=t*I)-(b-I)))-((A=D*I)-w*E-S*E-w*C))-(k=L-(O=(S=z-(w=(b=t*z)-(b-z)))*(C=x-(E=(b=t*x)-(b-x)))-((P=z*x)-w*E-S*E-w*C))),p[0]=L-(k+_)+(_-O),_=(T=A-((M=A+k)-(_=M-A))+(k-_))-(k=T-P),p[1]=T-(k+_)+(_-P),_=(R=M+k)-M,p[2]=M-(R-_)+(k-_),p[3]=R;const U=r(Z,u,4,p,c);_=(L=(S=g-(w=(b=t*g)-(b-g)))*(C=I-(E=(b=t*I)-(b-I)))-((A=g*I)-w*E-S*E-w*C))-(k=L-(O=(S=y-(w=(b=t*y)-(b-y)))*(C=x-(E=(b=t*x)-(b-x)))-((P=y*x)-w*E-S*E-w*C))),p[0]=L-(k+_)+(_-O),_=(T=A-((M=A+k)-(_=M-A))+(k-_))-(k=T-P),p[1]=T-(k+_)+(_-P),_=(R=M+k)-M,p[2]=M-(R-_)+(k-_),p[3]=R;const V=r(U,c,4,p,d);return d[V-1]}(e,a,h,f,v,m,I):x},e.orient2dfast=function(e,t,n,r,a,i){return(t-i)*(n-a)-(e-a)*(r-i)},Object.defineProperty(e,"__esModule",{value:!0})}(t)})),Qn=Jn(Un),er=Jn(Hn),tr=$n.orient2d;er.default&&(er=er.default);var nr=rr;function rr(e,t,n){t=Math.max(0,void 0===t?2:t),n=n||0;var r=function(e){for(var t=e[0],n=e[0],r=e[0],a=e[0],i=0;e.length>i;i++){var o=e[i];t[0]>o[0]&&(t=o),o[0]>r[0]&&(r=o),n[1]>o[1]&&(n=o),o[1]>a[1]&&(a=o)}var s=[t,n,r,a],l=s.slice();for(i=0;e.length>i;i++)Wn(e[i],s)||l.push(e[i]);return function(e){e.sort(vr);for(var t=[],n=0;e.length>n;n++){for(;t.length>=2&&0>=ur(t[t.length-2],t[t.length-1],e[n]);)t.pop();t.push(e[n])}for(var r=[],a=e.length-1;a>=0;a--){for(;r.length>=2&&0>=ur(r[r.length-2],r[r.length-1],e[a]);)r.pop();r.push(e[a])}return r.pop(),t.pop(),t.concat(r)}(l)}(e),a=new Qn(16);a.toBBox=function(e){return{minX:e[0],minY:e[1],maxX:e[0],maxY:e[1]}},a.compareMinX=function(e,t){return e[0]-t[0]},a.compareMinY=function(e,t){return e[1]-t[1]},a.load(e);for(var i,o=[],s=0;r.length>s;s++){var l=r[s];a.remove(l),i=dr(l,i),o.push(i)}var u=new Qn(16);for(s=0;o.length>s;s++)u.insert(cr(o[s]));for(var c=t*t,d=n*n;o.length;){var p=o.shift(),h=p.p,f=p.next.p,v=pr(h,f);if(v>=d){var m=v/c;(l=ar(a,p.prev.p,h,f,p.next.next.p,m,u))&&Math.min(pr(l,h),pr(l,f))<=m&&(o.push(p),o.push(dr(l,p)),a.remove(l),u.remove(p),u.insert(cr(p)),u.insert(cr(p.next)))}}p=i;var g=[];do{g.push(p.p),p=p.next}while(p!==i);return g.push(p.p),g}function ar(e,t,n,r,a,i,o){for(var s=new er([],ir),l=e.data;l;){for(var u=0;l.children.length>u;u++){var c=l.children[u],d=l.leaf?hr(c,n,r):or(n,r,c);ip.dist&&v>p.dist&&lr(n,h,o)&&lr(r,h,o))return h}(l=s.pop())&&(l=l.node)}return null}function ir(e,t){return e.dist-t.dist}function or(e,t,n){if(sr(e,n)||sr(t,n))return 0;var r=fr(e[0],e[1],t[0],t[1],n.minX,n.minY,n.maxX,n.minY);if(0===r)return 0;var a=fr(e[0],e[1],t[0],t[1],n.minX,n.minY,n.minX,n.maxY);if(0===a)return 0;var i=fr(e[0],e[1],t[0],t[1],n.maxX,n.minY,n.maxX,n.maxY);if(0===i)return 0;var o=fr(e[0],e[1],t[0],t[1],n.minX,n.maxY,n.maxX,n.maxY);return 0===o?0:Math.min(r,a,i,o)}function sr(e,t){return!(t.minX>e[0]||e[0]>t.maxX||t.minY>e[1]||e[1]>t.maxY)}function lr(e,t,n){for(var r,a,i,o,s=n.search({minX:Math.min(e[0],t[0]),minY:Math.min(e[1],t[1]),maxX:Math.max(e[0],t[0]),maxY:Math.max(e[1],t[1])}),l=0;s.length>l;l++)if(a=s[l].next.p,i=e,(r=s[l].p)!==(o=t)&&a!==i&&ur(r,a,i)>0!=ur(r,a,o)>0&&ur(i,o,r)>0!=ur(i,o,a)>0)return!1;return!0}function ur(e,t,n){return tr(e[0],e[1],t[0],t[1],n[0],n[1])}function cr(e){var t=e.p,n=e.next.p;return e.minX=Math.min(t[0],n[0]),e.minY=Math.min(t[1],n[1]),e.maxX=Math.max(t[0],n[0]),e.maxY=Math.max(t[1],n[1]),e}function dr(e,t){var n={p:e,prev:null,next:null,minX:0,minY:0,maxX:0,maxY:0};return t?(n.next=t.next,n.prev=t,t.next.prev=n,t.next=n):(n.prev=n,n.next=n),n}function pr(e,t){var n=e[0]-t[0],r=e[1]-t[1];return n*n+r*r}function hr(e,t,n){var r=t[0],a=t[1],i=n[0]-r,o=n[1]-a;if(0!==i||0!==o){var s=((e[0]-r)*i+(e[1]-a)*o)/(i*i+o*o);s>1?(r=n[0],a=n[1]):s>0&&(r+=i*s,a+=o*s)}return(i=e[0]-r)*i+(o=e[1]-a)*o}function fr(e,t,n,r,a,i,o,s){var l,u,c,d,p=n-e,h=r-t,f=o-a,v=s-i,m=e-a,g=t-i,y=p*p+h*h,x=p*f+h*v,I=f*f+v*v,_=p*m+h*g,b=f*m+v*g,w=y*I-x*x,S=w,E=w;0===w?(u=0,S=1,d=b,E=I):(d=y*b-x*_,0>(u=x*b-I*_)?(u=0,d=b,E=I):u>S&&(u=S,d=b+x,E=I)),0>d?(d=0,0>-_?u=0:-_>y?u=S:(u=-_,S=y)):d>E&&(d=E,0>-_+x?u=0:-_+x>y?u=S:(u=-_+x,S=y));var C=(1-(c=0===d?0:d/E))*a+c*o-((1-(l=0===u?0:u/S))*e+l*n),k=(1-c)*i+c*s-((1-l)*t+l*r);return C*C+k*k}function vr(e,t){return e[0]===t[0]?e[1]-t[1]:e[0]-t[0]}function mr(e,t,n){void 0===n&&(n={});var r=_n(e),a=_n(t),i=rn(a[1]-r[1]),o=rn(a[0]-r[0]),s=rn(r[1]),l=rn(a[1]),u=Math.pow(Math.sin(i/2),2)+Math.pow(Math.sin(o/2),2)*Math.cos(s)*Math.cos(l);return en(2*Math.atan2(Math.sqrt(u),Math.sqrt(1-u)),n.units)}function gr(e){return function(e,t){void 0===t&&(t={});var n=Number(e[0]),r=Number(e[1]),a=Number(e[2]),i=Number(e[3]);if(6===e.length)throw Error("@turf/bbox-polygon does not support BBox with 6 positions");var o=[n,r];return Yt([[o,[a,r],[a,i],[n,i],o]],t.properties,{bbox:e,id:t.id})}(xn(e))}function yr(e,t,n,r){void 0===r&&(r={});var a=_n(e),i=rn(a[0]),o=rn(a[1]),s=rn(n),l=tn(t,r.units),u=Math.asin(Math.sin(o)*Math.cos(l)+Math.cos(o)*Math.sin(l)*Math.cos(s));return Wt([nn(i+Math.atan2(Math.sin(s)*Math.sin(l)*Math.cos(o),Math.cos(l)-Math.sin(o)*Math.sin(u))),nn(u)],r.properties)}function xr(e,t,n){if(void 0===n&&(n={}),!0===n.final)return function(e,t){var n=xr(t,e);return(n+180)%360}(e,t);var r=_n(e),a=_n(t),i=rn(r[0]),o=rn(a[0]),s=rn(r[1]),l=rn(a[1]);return nn(Math.atan2(Math.sin(o-i)*Math.cos(l),Math.cos(s)*Math.sin(l)-Math.sin(s)*Math.cos(l)*Math.cos(o-i)))}function Ir(e,t){void 0===t&&(t={});var n=xn(e);return Wt([(n[0]+n[2])/2,(n[1]+n[3])/2],t.properties,t)}function _r(e,t){void 0===t&&(t={});var n=0,r=0,a=0;return ln(e,(function(e){n+=e[0],r+=e[1],a++}),!0),Wt([n/a,r/a],t.properties)}function br(e,t){switch(void 0===t&&(t={}),Sn(e)){case"Point":return Wt(_n(e),t.properties);case"Polygon":var n=[];ln(e,(function(e){n.push(e)}));var r,a,i,o,s,l,u,c,d=_r(e,{properties:t.properties}),p=d.geometry.coordinates,h=0,f=0,v=0,m=n.map((function(e){return[e[0]-p[0],e[1]-p[1]]}));for(r=0;n.length-1>r;r++)v+=c=(o=(a=m[r])[0])*(u=(i=m[r+1])[1])-(s=i[0])*(l=a[1]),h+=(o+s)*c,f+=(l+u)*c;if(0===v)return d;var g=1/(.5*v*6);return Wt([p[0]+g*h,p[1]+g*f],t.properties);default:var y=function(e,t){void 0===t&&(t={}),t.concavity=t.concavity||1/0;var n=[];if(ln(e,(function(e){n.push([e[0],e[1]])})),!n.length)return null;var r=nr(n,t.concavity);return r.length>3?Yt([r]):null}(e);return y?br(y,{properties:t.properties}):_r(e,{properties:t.properties})}}function wr(e){if(!e)throw Error("geojson is required");var t=[];return fn(e,(function(e){!function(e,t){var n=[],r=e.geometry;if(null!==r){switch(r.type){case"Polygon":n=bn(r);break;case"LineString":n=[bn(r)]}n.forEach((function(n){var r=function(e,t){var n=[];return e.reduce((function(e,r){var a,i,o,s,l,u,c=Xt([e,r],t);return c.bbox=[(l=(i=r)[0])>(o=(a=e)[0])?o:l,(u=i[1])>(s=a[1])?s:u,o>l?o:l,s>u?s:u],n.push(c),r})),n}(n,e.properties);r.forEach((function(e){e.id=t.length,t.push(e)}))}))}}(e,t)})),Kt(t)}nr.default=rr;var Sr=Jn(sn),Er=Jn(yn),Cr=Jn(In).default,kr=Er.featureEach,Mr=Sr.featureCollection;function Tr(e){var t=new Qn(e);return t.insert=function(e){if("Feature"!==e.type)throw Error("invalid feature");return e.bbox=e.bbox?e.bbox:Cr(e),Qn.prototype.insert.call(this,e)},t.load=function(e){var t=[];return Array.isArray(e)?e.forEach((function(e){if("Feature"!==e.type)throw Error("invalid features");e.bbox=e.bbox?e.bbox:Cr(e),t.push(e)})):kr(e,(function(e){if("Feature"!==e.type)throw Error("invalid features");e.bbox=e.bbox?e.bbox:Cr(e),t.push(e)})),Qn.prototype.load.call(this,t)},t.remove=function(e,t){if("Feature"!==e.type)throw Error("invalid feature");return e.bbox=e.bbox?e.bbox:Cr(e),Qn.prototype.remove.call(this,e,t)},t.clear=function(){return Qn.prototype.clear.call(this)},t.search=function(e){var t=Qn.prototype.search.call(this,this.toBBox(e));return Mr(t)},t.collides=function(e){return Qn.prototype.collides.call(this,this.toBBox(e))},t.all=function(){var e=Qn.prototype.all.call(this);return Mr(e)},t.toJSON=function(){return Qn.prototype.toJSON.call(this)},t.fromJSON=function(e){return Qn.prototype.fromJSON.call(this,e)},t.toBBox=function(e){var t;if(e.bbox)t=e.bbox;else if(Array.isArray(e)&&4===e.length)t=e;else if(Array.isArray(e)&&6===e.length)t=[e[0],e[1],e[3],e[4]];else if("Feature"===e.type)t=Cr(e);else{if("FeatureCollection"!==e.type)throw Error("invalid geojson");t=Cr(e)}return{minX:t[0],minY:t[1],maxX:t[2],maxY:t[3]}},t}var Ar=Tr;function Lr(e,t){var n={},r=[];if("LineString"===e.type&&(e=qt(e)),"LineString"===t.type&&(t=qt(t)),"Feature"===e.type&&"Feature"===t.type&&null!==e.geometry&&null!==t.geometry&&"LineString"===e.geometry.type&&"LineString"===t.geometry.type&&2===e.geometry.coordinates.length&&2===t.geometry.coordinates.length){var a=Pr(e,t);return a&&r.push(a),Kt(r)}var i=Ar();return i.load(wr(t)),cn(wr(e),(function(e){cn(i.search(e),(function(t){var a=Pr(e,t);if(a){var i=bn(a).join(",");n[i]||(n[i]=!0,r.push(a))}}))})),Kt(r)}function Pr(e,t){var n=bn(e),r=bn(t);if(2!==n.length)throw Error(" line1 must only contain 2 coordinates");if(2!==r.length)throw Error(" line2 must only contain 2 coordinates");var a=n[0][0],i=n[0][1],o=n[1][0],s=n[1][1],l=r[0][0],u=r[0][1],c=r[1][0],d=r[1][1],p=(d-u)*(o-a)-(c-l)*(s-i);if(0===p)return null;var h=((c-l)*(i-u)-(d-u)*(a-l))/p,f=((o-a)*(i-u)-(s-i)*(a-l))/p;return 0>h||h>1||0>f||f>1?null:Wt([a+h*(o-a),i+h*(s-i)])}Ar.default=Tr;var Or=6378137;function Rr(e){return hn(e,(function(e,t){return e+function(e){var t,n=0;switch(e.type){case"Polygon":return Dr(e.coordinates);case"MultiPolygon":for(t=0;e.coordinates.length>t;t++)n+=Dr(e.coordinates[t]);return n;case"Point":case"MultiPoint":case"LineString":case"MultiLineString":return 0}return 0}(t)}),0)}function Dr(e){var t=0;if(e&&e.length>0){t+=Math.abs(Nr(e[0]));for(var n=1;e.length>n;n++)t-=Math.abs(Nr(e[n]))}return t}function Nr(e){var t,n,r,a,i,o,s=0,l=e.length;if(l>2){for(o=0;l>o;o++)o===l-2?(r=l-2,a=l-1,i=0):o===l-1?(r=l-1,a=0,i=1):(r=o,a=o+1,i=o+2),t=e[r],n=e[a],s+=(zr(e[i][0])-zr(t[0]))*Math.sin(zr(n[1]));s=s*Or*Or/2}return s}function zr(e){return e*Math.PI/180}function Fr(e,t){return void 0===t&&(t={}),mn(e,(function(e,n){var r=n.geometry.coordinates;return e+mr(r[0],r[1],t)}),0)}function Br(e,t){void 0===t&&(t={});var n=wn(e);switch(t.properties||"Feature"!==e.type||(t.properties=e.properties),n.type){case"Polygon":return function(e,t){return void 0===t&&(t={}),jr(wn(e).coordinates,t.properties?t.properties:"Feature"===e.type?e.properties:{})}(n,t);case"MultiPolygon":return function(e,t){void 0===t&&(t={});var n=wn(e).coordinates,r=t.properties?t.properties:"Feature"===e.type?e.properties:{},a=[];return n.forEach((function(e){a.push(jr(e,r))})),Kt(a)}(n,t);default:throw Error("invalid poly")}}function jr(e,t){return e.length>1?Jt(e,t):Xt(e[0],t)}function Zr(e){for(var t,n,r=bn(e),a=0,i=1;r.length>i;)t=n||r[0],a+=((n=r[i])[0]-t[0])*(n[1]+t[1]),i++;return a>0}var Ur=Kn((function(e){var t=Object.prototype.hasOwnProperty,n="~";function r(){}function a(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function i(e,t,r,i,o){if("function"!=typeof r)throw new TypeError("The listener must be a function");var s=new a(r,i||e,o),l=n?n+t:t;return e._events[l]?e._events[l].fn?e._events[l]=[e._events[l],s]:e._events[l].push(s):(e._events[l]=s,e._eventsCount++),e}function o(e,t){0==--e._eventsCount?e._events=new r:delete e._events[t]}function s(){this._events=new r,this._eventsCount=0}Object.create&&(r.prototype=Object.create(null),(new r).__proto__||(n=!1)),s.prototype.eventNames=function(){var e,r,a=[];if(0===this._eventsCount)return a;for(r in e=this._events)t.call(e,r)&&a.push(n?r.slice(1):r);return Object.getOwnPropertySymbols?a.concat(Object.getOwnPropertySymbols(e)):a},s.prototype.listeners=function(e){var t=this._events[n?n+e:e];if(!t)return[];if(t.fn)return[t.fn];for(var r=0,a=t.length,i=Array(a);a>r;r++)i[r]=t[r].fn;return i},s.prototype.listenerCount=function(e){var t=this._events[n?n+e:e];return t?t.fn?1:t.length:0},s.prototype.emit=function(e,t,r,a,i,o){var s=n?n+e:e;if(!this._events[s])return!1;var l,u,c=this._events[s],d=arguments.length;if(c.fn){switch(c.once&&this.removeListener(e,c.fn,void 0,!0),d){case 1:return c.fn.call(c.context),!0;case 2:return c.fn.call(c.context,t),!0;case 3:return c.fn.call(c.context,t,r),!0;case 4:return c.fn.call(c.context,t,r,a),!0;case 5:return c.fn.call(c.context,t,r,a,i),!0;case 6:return c.fn.call(c.context,t,r,a,i,o),!0}for(u=1,l=Array(d-1);d>u;u++)l[u-1]=arguments[u];c.fn.apply(c.context,l)}else{var p,h=c.length;for(u=0;h>u;u++)switch(c[u].once&&this.removeListener(e,c[u].fn,void 0,!0),d){case 1:c[u].fn.call(c[u].context);break;case 2:c[u].fn.call(c[u].context,t);break;case 3:c[u].fn.call(c[u].context,t,r);break;case 4:c[u].fn.call(c[u].context,t,r,a);break;default:if(!l)for(p=1,l=Array(d-1);d>p;p++)l[p-1]=arguments[p];c[u].fn.apply(c[u].context,l)}}return!0},s.prototype.on=function(e,t,n){return i(this,e,t,n,!1)},s.prototype.once=function(e,t,n){return i(this,e,t,n,!0)},s.prototype.removeListener=function(e,t,r,a){var i=n?n+e:e;if(!this._events[i])return this;if(!t)return o(this,i),this;var s=this._events[i];if(s.fn)s.fn!==t||a&&!s.once||r&&s.context!==r||o(this,i);else{for(var l=0,u=[],c=s.length;c>l;l++)(s[l].fn!==t||a&&!s[l].once||r&&s[l].context!==r)&&u.push(s[l]);u.length?this._events[i]=1===u.length?u[0]:u:o(this,i)}return this},s.prototype.removeAllListeners=function(e){var t;return e?this._events[t=n?n+e:e]&&o(this,t):(this._events=new r,this._eventsCount=0),this},s.prototype.off=s.prototype.removeListener,s.prototype.addListener=s.prototype.on,s.prefixed=n,s.EventEmitter=s,e.exports=s})),Vr=function(e){At(n,e);var t=Dt(n);function n(e,r){var a,i=r.style;return Ct(this,n),(a=t.call(this)).scene=void 0,a.style=void 0,a.layers=void 0,a.data=[],a.scene=e,a.style=i,a.layers=a.getLayers(),a.layers.forEach((function(t){e.addLayer(t)})),i.callback instanceof Function&&i.callback(a.layers),a}return Mt(n,[{key:"show",value:function(){this.layers.forEach((function(e){e.show()}))}},{key:"hide",value:function(){this.layers.forEach((function(e){e.hide()}))}},{key:"setData",value:function(e){this.data=e;var t=Kt(e);this.layers.forEach((function(e){e.setData(t)}))}},{key:"destroy",value:function(){var e=this;this.layers.forEach((function(t){e.scene.removeLayer(t)}))}}]),n}(Ur.EventEmitter),Hr=function(e){At(r,e);var n=Dt(r);function r(){return Ct(this,r),n.apply(this,arguments)}return Mt(r,[{key:"getLayers",value:function(){var e=this.style,n=e.normal,r=e.style,a=e.options;return[new t.LineLayer(null!=a?a:{}).source(Kt([])).size(n.size).color(n.color).shape("line").style(r)]}}]),r}(Vr),Gr=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)},qr="object"==typeof Xn&&Xn&&Xn.Object===Object&&Xn,Wr="object"==typeof self&&self&&self.Object===Object&&self,Yr=qr||Wr||Function("return this")(),Xr=function(){return Yr.Date.now()},Kr=/\s/,Jr=function(e){for(var t=e.length;t--&&Kr.test(e.charAt(t)););return t},$r=/^\s+/,Qr=function(e){return e?e.slice(0,Jr(e)+1).replace($r,""):e},ea=Yr.Symbol,ta=Object.prototype,na=ta.hasOwnProperty,ra=ta.toString,aa=ea?ea.toStringTag:void 0,ia=function(e){var t=na.call(e,aa),n=e[aa];try{e[aa]=void 0;var r=!0}catch(e){}var a=ra.call(e);return r&&(t?e[aa]=n:delete e[aa]),a},oa=Object.prototype.toString,sa=function(e){return oa.call(e)},la=ea?ea.toStringTag:void 0,ua=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":la&&la in Object(e)?ia(e):sa(e)},ca=function(e){return null!=e&&"object"==typeof e},da=function(e){return"symbol"==typeof e||ca(e)&&"[object Symbol]"==ua(e)},pa=/^[-+]0x[0-9a-f]+$/i,ha=/^0b[01]+$/i,fa=/^0o[0-7]+$/i,va=parseInt,ma=function(e){if("number"==typeof e)return e;if(da(e))return NaN;if(Gr(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=Gr(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=Qr(e);var n=ha.test(e);return n||fa.test(e)?va(e.slice(2),n?2:8):pa.test(e)?NaN:+e},ga=Math.max,ya=Math.min,xa=function(e,t,n){var r,a,i,o,s,l,u=0,c=!1,d=!1,p=!0;if("function"!=typeof e)throw new TypeError("Expected a function");function h(t){var n=r,i=a;return r=a=void 0,u=t,o=e.apply(i,n)}function f(e){return u=e,s=setTimeout(m,t),c?h(e):o}function v(e){var n=e-l;return void 0===l||n>=t||0>n||d&&e-u>=i}function m(){var e=Xr();if(v(e))return g(e);s=setTimeout(m,function(e){var n=t-(e-l);return d?ya(n,i-(e-u)):n}(e))}function g(e){return s=void 0,p&&r?h(e):(r=a=void 0,o)}function y(){var e=Xr(),n=v(e);if(r=arguments,a=this,l=e,n){if(void 0===s)return f(l);if(d)return clearTimeout(s),s=setTimeout(m,t),h(l)}return void 0===s&&(s=setTimeout(m,t)),o}return t=ma(t)||0,Gr(n)&&(c=!!n.leading,i=(d="maxWait"in n)?ga(ma(n.maxWait)||0,t):i,p="trailing"in n?!!n.trailing:p),y.cancel=function(){void 0!==s&&clearTimeout(s),u=0,r=l=a=s=void 0},y.flush=function(){return void 0===s?o:g(Xr())},y},Ia=function(n){At(a,n);var r=Dt(a);function a(){var t;Ct(this,a);for(var n=arguments.length,i=Array(n),o=0;n>o;o++)i[o]=arguments[o];return(t=r.call.apply(r,[this].concat(i))).onMouseMove=function(n){t.emit(e.RenderEvent.Mousemove,n)},t.onMouseOut=function(n){t.emit(e.RenderEvent.Mouseout,n)},t.onMouseDown=function(n){t.emit(e.RenderEvent.Dragstart,n)},t.onDragging=function(n){t.emit(e.RenderEvent.Dragging,n)},t.onDragEnd=xa((function(n){t.emit(e.RenderEvent.Dragend,n)}),0),t.onUnClick=function(n){t.emit(e.RenderEvent.UnClick,n)},t.enableHover=function(){var n,r;t.disableHover(),null===(n=t.layers[0])||void 0===n||n.on(e.LayerEvent.Mousemove,t.onMouseMove),null===(r=t.layers[0])||void 0===r||r.on(e.LayerEvent.Mouseout,t.onMouseOut)},t.disableHover=function(){var n,r;null===(n=t.layers[0])||void 0===n||n.off(e.LayerEvent.Mousemove,t.onMouseMove),null===(r=t.layers[0])||void 0===r||r.off(e.LayerEvent.Mouseout,t.onMouseOut)},t}return Mt(a,[{key:"getLayers",value:function(){var e=this.style,n=e.normal,r=e.hover,a=e.active,i=e.style,o=e.options;return[new t.LineLayer(null!=o?o:{}).source(Kt([])).size("isHover*isActive",(function(e,t){return t?a.size:e?r.size:n.size})).color("isHover*isActive",(function(e,t){return t?a.color:e?r.color:n.color})).shape("line").style(i)]}},{key:"enableDrag",value:function(){this.disableDrag(),this.layers[0].on(e.LayerEvent.Mousedown,this.onMouseDown),this.scene.on(e.SceneEvent.Dragging,this.onDragging),this.scene.on(e.SceneEvent.Mouseup,this.onDragEnd),this.scene.on(e.SceneEvent.Dragend,this.onDragEnd)}},{key:"disableDrag",value:function(){this.layers[0].off(e.LayerEvent.Mousedown,this.onMouseDown),this.scene.off(e.SceneEvent.Dragging,this.onDragging),this.scene.off(e.SceneEvent.Mouseup,this.onDragEnd),this.scene.off(e.SceneEvent.Dragend,this.onDragEnd)}},{key:"enableUnClick",value:function(){this.disableUnClick(),this.layers[0].on(e.LayerEvent.UnClick,this.onUnClick)}},{key:"disableUnClick",value:function(){this.layers[0].off(e.LayerEvent.UnClick,this.onUnClick)}}]),a}(Vr),_a=function(n){At(a,n);var r=Dt(a);function a(){var t;Ct(this,a);for(var n=arguments.length,i=Array(n),o=0;n>o;o++)i[o]=arguments[o];return(t=r.call.apply(r,[this].concat(i))).onMouseMove=function(n){t.emit(e.RenderEvent.Mousemove,n)},t.onMouseOut=function(n){t.emit(e.RenderEvent.Mouseout,n)},t.onMouseDown=function(n){t.emit(e.RenderEvent.Click,n)},t}return Mt(a,[{key:"getLayers",value:function(){var e=this.style,n=e.normal,r=e.style,a=e.options,i=n.shape,o=n.size,s=n.color,l=n.stroke;return[new t.PointLayer(null!=a?a:{}).source(Kt([])).size(o).color(s).shape(i).style(Et({stroke:l},r))]}},{key:"enableClick",value:function(){this.disableClick(),this.layers[0].on(e.LayerEvent.Mousedown,this.onMouseDown)}},{key:"disableClick",value:function(){this.layers[0].off(e.LayerEvent.Mousedown,this.onMouseDown)}},{key:"enableHover",value:function(){var t,n;this.disableHover(),null===(t=this.layers[0])||void 0===t||t.on(e.LayerEvent.Mousemove,this.onMouseMove),null===(n=this.layers[0])||void 0===n||n.on(e.LayerEvent.Mouseout,this.onMouseOut)}},{key:"disableHover",value:function(){var t,n;null===(t=this.layers[0])||void 0===t||t.off(e.LayerEvent.Mousemove,this.onMouseMove),null===(n=this.layers[0])||void 0===n||n.off(e.LayerEvent.Mouseout,this.onMouseOut)}}]),a}(Vr),ba=function(n){At(a,n);var r=Dt(a);function a(){var t;Ct(this,a);for(var n=arguments.length,i=Array(n),o=0;n>o;o++)i[o]=arguments[o];return(t=r.call.apply(r,[this].concat(i))).onCreate=function(n){t.emit(e.RenderEvent.UnClick,n)},t.onMouseMove=function(n){t.emit(e.RenderEvent.Mousemove,n)},t.onMouseOut=function(n){t.emit(e.RenderEvent.Mouseout,n)},t.onMouseDown=function(n){t.emit(e.RenderEvent.Dragstart,n)},t.onDragging=function(n){t.emit(e.RenderEvent.Dragging,n)},t.onDragEnd=xa((function(n){t.emit(e.RenderEvent.Dragend,n)}),0),t.onClick=function(n){t.emit(e.RenderEvent.Click,n)},t.onContextmenu=function(n){t.emit(e.RenderEvent.Contextmenu,n)},t}return Mt(a,[{key:"getLayers",value:function(){var e=this.style,n=e.normal,r=e.hover,a=e.active,i=e.style,o=e.options;return[new t.PointLayer(null!=o?o:{}).source(Kt([])).size("isHover*isActive",(function(e,t){return t?a.size:e?r.size:n.size})).color("isHover*isActive",(function(e,t){return t?a.color:e?r.color:n.color})).shape("isHover*isActive",(function(e,t){return t?a.shape:e?r.shape:n.shape})).style(Et({stroke:["isHover*isActive",function(e,t){return t?a.stroke:e?r.stroke:n.stroke}]},i))]}},{key:"enableCreate",value:function(){this.disableCreate(),this.layers[0].on(e.LayerEvent.UnClick,this.onCreate)}},{key:"disableCreate",value:function(){this.layers[0].off(e.LayerEvent.UnClick,this.onCreate)}},{key:"enableHover",value:function(){var t,n;this.disableHover(),null===(t=this.layers[0])||void 0===t||t.on(e.LayerEvent.Mousemove,this.onMouseMove),null===(n=this.layers[0])||void 0===n||n.on(e.LayerEvent.Mouseout,this.onMouseOut)}},{key:"disableHover",value:function(){var t,n;null===(t=this.layers[0])||void 0===t||t.off(e.LayerEvent.Mousemove,this.onMouseMove),null===(n=this.layers[0])||void 0===n||n.off(e.LayerEvent.Mouseout,this.onMouseOut)}},{key:"enableDrag",value:function(){this.disableDrag(),this.layers[0].on(e.LayerEvent.Mousedown,this.onMouseDown),this.scene.on(e.SceneEvent.Dragging,this.onDragging),this.scene.on(e.SceneEvent.Mouseup,this.onDragEnd),this.scene.on(e.SceneEvent.Dragend,this.onDragEnd)}},{key:"disableDrag",value:function(){this.layers[0].off(e.LayerEvent.Mousedown,this.onMouseDown),this.scene.off(e.SceneEvent.Dragging,this.onDragging),this.scene.off(e.SceneEvent.Mouseup,this.onDragEnd),this.scene.off(e.SceneEvent.Dragend,this.onDragEnd)}},{key:"enableClick",value:function(){this.disableClick(),this.layers[0].on(e.LayerEvent.Click,this.onClick)}},{key:"disableClick",value:function(){this.layers[0].off(e.LayerEvent.Click,this.onClick)}},{key:"enableContextMenu",value:function(){this.disableContextMenu(),this.layers[0].on(e.LayerEvent.Contextmenu,this.onContextmenu)}},{key:"disableContextMenu",value:function(){this.layers[0].off(e.LayerEvent.Contextmenu,this.onContextmenu)}}]),a}(Vr),wa=function(n){At(a,n);var r=Dt(a);function a(){var t;Ct(this,a);for(var n=arguments.length,i=Array(n),o=0;n>o;o++)i[o]=arguments[o];return(t=r.call.apply(r,[this].concat(i))).onMouseMove=function(n){t.emit(e.RenderEvent.Mousemove,n)},t.onMouseOut=function(n){t.emit(e.RenderEvent.Mouseout,n)},t.onMouseDown=function(n){t.emit(e.RenderEvent.Dragstart,n)},t.onDragging=function(n){t.emit(e.RenderEvent.Dragging,n)},t.onDragEnd=xa((function(n){t.emit(e.RenderEvent.Dragend,n)}),0),t.onUnClick=function(n){t.emit(e.RenderEvent.UnClick,n)},t.enableHover=function(){var n,r;t.disableHover(),null===(n=t.layers[0])||void 0===n||n.on(e.LayerEvent.Mousemove,t.onMouseMove),null===(r=t.layers[0])||void 0===r||r.on(e.LayerEvent.Mouseout,t.onMouseOut)},t.disableHover=function(){var n,r;null===(n=t.layers[0])||void 0===n||n.off(e.LayerEvent.Mousemove,t.onMouseMove),null===(r=t.layers[0])||void 0===r||r.off(e.LayerEvent.Mouseout,t.onMouseOut)},t}return Mt(a,[{key:"getLayers",value:function(){var e=this.style,n=e.normal,r=e.hover,a=e.active,i=e.style,o=e.options,s=new t.PolygonLayer(null!=o?o:{});return s.source(Kt([])).color("isHover*isActive",(function(e,t){return t?a.color:e?r.color:n.color})).style(i),[s]}},{key:"enableDrag",value:function(){this.disableDrag(),this.layers[0].on(e.LayerEvent.Mousedown,this.onMouseDown),this.scene.on(e.SceneEvent.Dragging,this.onDragging),this.scene.on(e.SceneEvent.Mouseup,this.onDragEnd),this.scene.on(e.SceneEvent.Dragend,this.onDragEnd)}},{key:"disableDrag",value:function(){this.layers[0].off(e.LayerEvent.Mousedown,this.onMouseDown),this.scene.off(e.SceneEvent.Dragging,this.onDragging),this.scene.off(e.SceneEvent.Mouseup,this.onDragEnd),this.scene.off(e.SceneEvent.Dragend,this.onDragEnd)}},{key:"enableUnClick",value:function(){this.disableUnClick(),this.layers[0].on(e.LayerEvent.UnClick,this.onUnClick)}},{key:"disableUnClick",value:function(){this.layers[0].off(e.LayerEvent.UnClick,this.onUnClick)}}]),a}(Vr),Sa=function(t){At(r,t);var n=Dt(r);function r(t){var a;return Ct(this,r),(a=n.call(this)).scene=void 0,a.previousClick=void 0,a.onDblClick=function(t){var n,r,i=null!==(n=null!==(r=t.pixel)&&void 0!==r?r:t.point)&&void 0!==n?n:{},o=i.x,s=void 0===o?0:o,l=i.y,u=void 0===l?0:l,c=Date.now();if(a.previousClick){var d=a.previousClick,p=d.y;300>c-d.time&&5>Math.abs(s-d.x)&&5>Math.abs(u-p)&&a.emit(e.RenderEvent.DblClick,t)}a.previousClick={x:s,y:u,time:c}},a.onMouseMove=function(t){a.emit(e.RenderEvent.Mousemove,t)},a.onMouseDown=function(t){a.emit(e.RenderEvent.Dragstart,t)},a.onDragging=function(t){a.emit(e.RenderEvent.Dragging,t)},a.onDragEnd=xa((function(t){a.emit(e.RenderEvent.Dragend,t)}),0),a.scene=t,a}return Mt(r,[{key:"enableDrag",value:function(){this.disableDrag(),this.scene.on(e.SceneEvent.Mousedown,this.onMouseDown),this.scene.on(e.SceneEvent.Dragging,this.onDragging),this.scene.on(e.SceneEvent.Mouseup,this.onDragEnd),this.scene.on(e.SceneEvent.Dragend,this.onDragEnd)}},{key:"disableDrag",value:function(){this.scene.off(e.SceneEvent.Mousedown,this.onMouseDown),this.scene.off(e.SceneEvent.Dragging,this.onDragging),this.scene.off(e.SceneEvent.Mouseup,this.onDragEnd),this.scene.off(e.SceneEvent.Dragend,this.onDragEnd)}},{key:"enableMouseMove",value:function(){this.disableMouseMove(),this.scene.on(e.SceneEvent.Mousemove,this.onMouseMove)}},{key:"disableMouseMove",value:function(){this.scene.off(e.SceneEvent.Mousemove,this.onMouseMove)}},{key:"enableDblClick",value:function(){this.disableDblClick(),this.scene.on(e.SceneEvent.Mousedown,this.onDblClick)}},{key:"disableDblClick",value:function(){this.scene.on(e.SceneEvent.Mousedown,this.onDblClick)}}]),r}(Ur),Ea=function(e){At(r,e);var n=Dt(r);function r(){return Ct(this,r),n.apply(this,arguments)}return Mt(r,[{key:"getLayers",value:function(){var e=this.style,n=e.normal,r=e.active,a=e.style,i=e.options;return[new t.PointLayer(null!=i?i:{}).source(Kt([])).size("isActive",(function(e){return e?r.size:n.size})).color("isActive",(function(e){return e?r.color:n.color})).shape("text","text").style(Et({stroke:["isActive",function(e){return e?r.stroke:n.stroke}]},a))]}}]),r}(Vr),Ca={point:ba,line:Ia,dashLine:Hr,midPoint:_a,text:Ea,polygon:wa},ka="#1990FF",Ma="#ED9D48",Ta={blend:"normal",pickingBuffer:5},Aa={color:ka,shape:"circle",size:6,stroke:"#ffffff"},La={color:Ma,shape:"circle",size:6,stroke:"#ffffff"},Pa={shape:"circle",size:6,color:Ma,stroke:"#ffffff"},Oa={options:Ta,normal:Aa,hover:Et(Et({},Aa),{},{size:8}),active:Et(Et({},Aa),{},{size:8,color:Ma}),style:{strokeWidth:2}},Ra={options:Ta,normal:La,hover:Et(Et({},La),{},{size:8}),active:Et(Et({},La),{},{size:8}),style:{strokeWidth:2}},Da={color:ka,size:12,stroke:"#ffffff"},Na={point:Ra,line:{options:Ta,normal:{color:ka,size:2},hover:{color:ka,size:2},active:{color:Ma,size:2},style:{}},polygon:{options:Ta,normal:{color:ka},hover:{color:ka},active:{color:Ma},style:{opacity:.15}},midPoint:{options:Ta,normal:Pa},dashLine:{options:Ta,normal:{color:Ma,size:2},style:{lineType:"dash",dashArray:[6,6]}},text:{options:Ta,normal:Da,active:Et(Et({},Da),{},{color:Ma}),style:{fontWeight:"800",textOffset:[0,Da.size+6],textAllowOverlap:!0,strokeWidth:2}}},za=function(e,t){return e===t||e!=e&&t!=t},Fa=function(e,t){for(var n=e.length;n--;)if(za(e[n][0],t))return n;return-1},Ba=Array.prototype.splice,ja=function(e){var t=this.__data__,n=Fa(t,e);return n>=0&&(n==t.length-1?t.pop():Ba.call(t,n,1),--this.size,!0)},Za=function(e){var t=this.__data__,n=Fa(t,e);return 0>n?void 0:t[n][1]},Ua=function(e){return Fa(this.__data__,e)>-1},Va=function(e,t){var n=this.__data__,r=Fa(n,e);return 0>r?(++this.size,n.push([e,t])):n[r][1]=t,this};function Ha(e){var t=-1,n=null==e?0:e.length;for(this.clear();++tr.length)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new Ei(r)}return n.set(e,t),this.size=n.size,this};function ki(e){var t=this.__data__=new qa(e);this.size=t.size}ki.prototype.clear=Wa,ki.prototype.delete=Ya,ki.prototype.get=Xa,ki.prototype.has=Ka,ki.prototype.set=Ci;var Mi=ki,Ti=function(e,t){for(var n=-1,r=null==e?0:e.length;++n-1&&e%1==0&&t>e},Wi=function(e){return"number"==typeof e&&e>-1&&e%1==0&&9007199254740991>=e},Yi={};Yi["[object Float32Array]"]=Yi["[object Float64Array]"]=Yi["[object Int8Array]"]=Yi["[object Int16Array]"]=Yi["[object Int32Array]"]=Yi["[object Uint8Array]"]=Yi["[object Uint8ClampedArray]"]=Yi["[object Uint16Array]"]=Yi["[object Uint32Array]"]=!0,Yi["[object Arguments]"]=Yi["[object Array]"]=Yi["[object ArrayBuffer]"]=Yi["[object Boolean]"]=Yi["[object DataView]"]=Yi["[object Date]"]=Yi["[object Error]"]=Yi["[object Function]"]=Yi["[object Map]"]=Yi["[object Number]"]=Yi["[object Object]"]=Yi["[object RegExp]"]=Yi["[object Set]"]=Yi["[object String]"]=Yi["[object WeakMap]"]=!1;var Xi=function(e){return ca(e)&&Wi(e.length)&&!!Yi[ua(e)]},Ki=function(e){return function(t){return e(t)}},Ji=Kn((function(e,t){var n=t&&!t.nodeType&&t,r=n&&e&&!e.nodeType&&e,a=r&&r.exports===n&&qr.process,i=function(){try{return r&&r.require&&r.require("util").types||a&&a.binding&&a.binding("util")}catch(e){}}();e.exports=i})),$i=Ji&&Ji.isTypedArray,Qi=$i?Ki($i):Xi,eo=Object.prototype.hasOwnProperty,to=function(e,t){var n=Ui(e),r=!n&&Zi(e),a=!n&&!r&&Hi(e),i=!n&&!r&&!a&&Qi(e),o=n||r||a||i,s=o?Di(e.length,String):[],l=s.length;for(var u in e)!t&&!eo.call(e,u)||o&&("length"==u||a&&("offset"==u||"parent"==u)||i&&("buffer"==u||"byteLength"==u||"byteOffset"==u)||qi(u,l))||s.push(u);return s},no=Object.prototype,ro=function(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||no)},ao=function(e,t){return function(n){return e(t(n))}},io=ao(Object.keys,Object),oo=Object.prototype.hasOwnProperty,so=function(e){if(!ro(e))return io(e);var t=[];for(var n in Object(e))oo.call(e,n)&&"constructor"!=n&&t.push(n);return t},lo=function(e){return null!=e&&Wi(e.length)&&!Ja(e)},uo=function(e){return lo(e)?to(e):so(e)},co=function(e,t){return e&&Ri(t,uo(t),e)},po=function(e){var t=[];if(null!=e)for(var n in Object(e))t.push(n);return t},ho=Object.prototype.hasOwnProperty,fo=function(e){if(!Gr(e))return po(e);var t=ro(e),n=[];for(var r in e)("constructor"!=r||!t&&ho.call(e,r))&&n.push(r);return n},vo=function(e){return lo(e)?to(e,!0):fo(e)},mo=function(e,t){return e&&Ri(t,vo(t),e)},go=Kn((function(e,t){var n=t&&!t.nodeType&&t,r=n&&e&&!e.nodeType&&e,a=r&&r.exports===n?Yr.Buffer:void 0,i=a?a.allocUnsafe:void 0;e.exports=function(e,t){if(t)return e.slice();var n=e.length,r=i?i(n):new e.constructor(n);return e.copy(r),r}})),yo=function(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++ns))return!1;var u=i.get(e),c=i.get(t);if(u&&c)return u==t&&c==e;var d=-1,p=!0,h=2&n?new Es:void 0;for(i.set(e,t),i.set(t,e);++d0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}},ll=sl(Ai?function(e,t){return Ai(e,"toString",{configurable:!0,enumerable:!1,value:il(t),writable:!0})}:tl),ul=function(e,t){return ll(al(e,t,tl),e+"")},cl=function(e,t,n){if(!Gr(n))return!1;var r=typeof t;return!!("number"==r?lo(n)&&qi(t,n.length):"string"==r&&t in n)&&za(n[t],e)},dl=function(e){return ul((function(t,n){var r=-1,a=n.length,i=a>1?n[a-1]:void 0,o=a>2?n[2]:void 0;for(i=e.length>3&&"function"==typeof i?(a--,i):void 0,o&&cl(n[0],n[1],o)&&(i=3>a?void 0:i,a=1),t=Object(t);++r":".","?":"/","|":"\\"},l={option:"alt",command:"meta",return:"enter",escape:"esc",plus:"+",mod:/Mac|iPod|iPhone|iPad/.test(navigator.platform)?"meta":"ctrl"},u=1;20>u;++u)i[111+u]="f"+u;for(u=0;9>=u;++u)i[u+96]=""+u;m.prototype.bind=function(e,t,n){var r=this;return r._bindMultiple.call(r,e=e instanceof Array?e:[e],t,n),r},m.prototype.unbind=function(e,t){return this.bind.call(this,e,(function(){}),t)},m.prototype.trigger=function(e,t){var n=this;return n._directMap[e+":"+t]&&n._directMap[e+":"+t]({},e),n},m.prototype.reset=function(){var e=this;return e._callbacks={},e._directMap={},e},m.prototype.stopCallback=function(e,t){if((" "+t.className+" ").indexOf(" mousetrap ")>-1)return!1;if(v(t,this.target))return!1;if("composedPath"in e&&"function"==typeof e.composedPath){var n=e.composedPath()[0];n!==e.target&&(t=n)}return"INPUT"==t.tagName||"SELECT"==t.tagName||"TEXTAREA"==t.tagName||t.isContentEditable},m.prototype.handleKey=function(){var e=this;return e._handleKey.apply(e,arguments)},m.addKeycodes=function(e){for(var t in e)e.hasOwnProperty(t)&&(i[t]=e[t]);a=null},m.init=function(){var e=m(n);for(var t in e)"_"!==t.charAt(0)&&(m[t]=function(t){return function(){return e[t].apply(e,arguments)}}(t))},m.init(),t.Mousetrap=m,e.exports&&(e.exports=m)}function c(e,t,n){e.addEventListener?e.addEventListener(t,n,!1):e.attachEvent("on"+t,n)}function d(e){if("keypress"==e.type){var t=String.fromCharCode(e.which);return e.shiftKey||(t=t.toLowerCase()),t}return i[e.which]?i[e.which]:o[e.which]?o[e.which]:String.fromCharCode(e.which).toLowerCase()}function p(e){return"shift"==e||"ctrl"==e||"alt"==e||"meta"==e}function h(e,t,n){return n||(n=function(){if(!a)for(var e in a={},i)e>95&&112>e||i.hasOwnProperty(e)&&(a[i[e]]=e);return a}()[e]?"keydown":"keypress"),"keypress"==n&&t.length&&(n="keydown"),n}function f(e,t){var n,r,a,i=[];for(n=function(e){return"+"===e?["+"]:(e=e.replace(/\+{2}/g,"+plus")).split("+")}(e),a=0;n.length>a;++a)l[r=n[a]]&&(r=l[r]),t&&"keypress"!=t&&s[r]&&(r=s[r],i.push("shift")),p(r)&&i.push(r);return{key:r,modifiers:i,action:t=h(r,i,t)}}function v(e,t){return null!==e&&e!==n&&(e===t||v(e.parentNode,t))}function m(e){var t=this;if(e=e||n,!(t instanceof m))return new m(e);t.target=e,t._callbacks={},t._directMap={};var r,a={},i=!1,o=!1,s=!1;function l(e){e=e||{};var t,n=!1;for(t in a)e[t]?n=!0:a[t]=0;n||(s=!1)}function u(e,n,r,i,o,s){var l,u,c,d=[],h=r.type;if(!t._callbacks[e])return[];for("keyup"==h&&p(e)&&(n=[e]),l=0;t._callbacks[e].length>l;++l)u=t._callbacks[e][l],(i||!u.seq||a[u.seq]==u.level)&&h==u.action&&(("keypress"!=h||r.metaKey||r.ctrlKey)&&(c=u.modifiers,n.sort().join(",")!==c.sort().join(","))||((!i&&u.combo==o||i&&u.seq==i&&u.level==s)&&t._callbacks[e].splice(l,1),d.push(u)));return d}function h(e,n,r,a){t.stopCallback(n,n.target||n.srcElement,r,a)||!1===e(n,r)&&(function(e){e.preventDefault?e.preventDefault():e.returnValue=!1}(n),function(e){e.stopPropagation?e.stopPropagation():e.cancelBubble=!0}(n))}function v(e){"number"!=typeof e.which&&(e.which=e.keyCode);var n=d(e);n&&("keyup"!=e.type||i!==n?t.handleKey(n,function(e){var t=[];return e.shiftKey&&t.push("shift"),e.altKey&&t.push("alt"),e.ctrlKey&&t.push("ctrl"),e.metaKey&&t.push("meta"),t}(e),e):i=!1)}function g(e,t,n,o){function u(t){return function(){s=t,++a[e],clearTimeout(r),r=setTimeout(l,1e3)}}function c(t){h(n,t,e),"keyup"!==o&&(i=d(t)),setTimeout(l,10)}a[e]=0;for(var p=0;t.length>p;++p){var v=p+1===t.length?c:u(o||f(t[p+1]).action);y(t[p],v,o,e,p)}}function y(e,n,r,a,i){t._directMap[e+":"+r]=n;var o,s=(e=e.replace(/\s+/g," ")).split(" ");s.length>1?g(e,s,n,r):(o=f(e,r),t._callbacks[o.key]=t._callbacks[o.key]||[],u(o.key,o.modifiers,{type:o.action},a,e,i),t._callbacks[o.key][a?"unshift":"push"]({callback:n,modifiers:o.modifiers,action:o.action,seq:a,level:i,combo:e}))}t._handleKey=function(e,t,n){var r,a=u(e,t,n),i={},c=0,d=!1;for(r=0;a.length>r;++r)a[r].seq&&(c=Math.max(c,a[r].level));for(r=0;a.length>r;++r)if(a[r].seq){if(a[r].level!=c)continue;d=!0,i[a[r].seq]=1,h(a[r].callback,n,a[r].combo,a[r].seq)}else d||h(a[r].callback,n,a[r].combo);var f="keypress"==n.type&&o;n.type!=s||p(e)||f||l(i),o=d&&"keydown"==n.type},t._bindMultiple=function(e,t,n){for(var r=0;e.length>r;++r)y(e[r],t,n)},c(e,"keypress",v),c(e,"keydown",v),c(e,"keyup",v)}}("undefined"!=typeof window?window:null,"undefined"!=typeof window?document:null)})),yl=function(e){return e&&e.length?e[0]:void 0},xl=(Ss=1,function(e){return"".concat(e,"-").concat(Ss++)}),Il=function(e,t){var n,r;return!(!e||!t||(null===(n=e.properties)||void 0===n?void 0:n.id)!==(null===(r=t.properties)||void 0===r?void 0:r.id))},_l=function(e){var t=e.target,n=e.targetHandler,r=e.otherHandler;return e.data.map((function(e,a){var i,o=Il(e,t)?n:r;return null!==(i=null==o?void 0:o(e,a))&&void 0!==i?i:e}))},bl=function(){return{id:xl("point"),isHover:!1,isActive:!1,isDrag:!1,createTime:Date.now()}},wl=function(){return{id:xl("line"),isHover:!1,isActive:!1,isDrag:!1,isDraw:!1,createTime:Date.now()}},Sl=function(){return{id:xl("polygon"),isHover:!1,isActive:!1,isDrag:!1,isDraw:!1,createTime:Date.now()}},El=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return Wt(e,Et(Et({},bl()),t))},Cl=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return{type:"Feature",properties:Et(Et({},wl()),{},{nodes:e},t),geometry:{type:"LineString",coordinates:dn(Kt(e))}}},kl=function(e){return Xt(e,{id:xl("dashLine")})},Ml=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return{type:"Feature",properties:Et(Et({},Sl()),{},{nodes:e},t),geometry:{type:"Polygon",coordinates:[dn(Kt([].concat(Bt(e),[yl(e)])))]}}},Tl=function(e){return function(e,t,n){void 0===n&&(n={});for(var r=wn(e).coordinates,a=0,i=0;r.length>i&&(a>t||i!==r.length-1);i++){if(a>=t){var o=t-a;if(o){var s=xr(r[i],r[i-1])-180;return yr(r[i],o,s,n)}return Wt(r[i])}a+=mr(r[i],r[i+1],n)}return Wt(r[r.length-1])}(e,Fr(e,{units:"meters"})/2,{units:"meters"})},Al=function(e,t){var n=t.showTotalDistance,r=t.format,a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=[];if(n){var o=Tl(e),s=Fr(e,{units:"meters"});o.properties=Et({id:xl("text"),isActive:!1,meters:s,text:r(s),type:"totalDistance"},a),i.push(o)}else for(var l=e.geometry.coordinates,u=0;l.length-1>u;u++){var c=Wt(l[u]),d=Wt(l[u+1]),p=mr(c,d,{units:"meters"}),h=Ir(Kt([c,d]));h.properties=Et({id:xl("text"),isActive:!1,meters:p,text:r(p),type:"distance"},a),i.push(h)}return i},Ll=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=t.format,a=Rr(e);return br(e,{properties:Et({meters:a,text:r(a),type:"area",isActive:!1},n)})},Pl=function(e){var t,n,r=e.getContainer();return null!==(t=null!==(n=null==r?void 0:r.querySelector(".l7-marker-container"))&&void 0!==n?n:null==r?void 0:r.querySelector(".amap-maps"))&&void 0!==t?t:null},Ol=function(e){return e.lngLat||e.lnglat},Rl=function(e){var t=Ol(e);return[t.lng,t.lat]},Dl=function(e){return[e.lng,e.lat]},Nl=function(e){for(var t=Number.MAX_SAFE_INTEGER,n=0,r=e.length,a=0;r>a;a++)t>e[a]&&(t=e[a],n=a);return n},zl=function(e,t){var n=[],r=[];return e.forEach((function(e){Us(e,t)?r.length&&(n.push(r),r=[]):r.push(e)})),r.length&&n.push(r),n},Fl=function(e,t,n){var r=[],a=[],i=[];return(r="drawData"===e?t.getData():e instanceof Function?e(n):e).length&&(a=r.map((function(e){var t,r=null!==(t=e.properties)&&void 0!==t?t:{},a=r.nodes,i=void 0===a?[]:a,o=r.isActive;return void 0!==o&&o?i.filter((function(e){return!Us(e.geometry.coordinates,n)})):i})).flat().filter((function(e){return e})),a.length||(a=dn(Kt(r)).map((function(e){return Wt(e)}))),i=r.map((function(e){var t,r,a,i=null!==(t=null===(r=e.properties)||void 0===r?void 0:r.line)&&void 0!==t?t:e;return(null===(a=e.properties)||void 0===a?void 0:a.isActive)?zl(i.properties.nodes.map((function(e){return e.geometry.coordinates})),n).filter((function(e){return e.length>1})).map((function(e){return Xt(e)})):[i]})).flat().filter((function(e){return e})),i.length||r.forEach((function(e){var t=Sn(e);if(/linestring/i.test(t)&&i.push(e),/polygon/i.test(t)){var n,r,a=Br(e);return(n=i).push.apply(n,Bt(null!==(r=null==a?void 0:a.features)&&void 0!==r?r:[a]))}}))),{points:a,lines:i}},Bl=function(e,t,n,r){var a=n.pointAdsorbPixel,i=Ft(e,2),o=r.lngLatToPixel([i[0],i[1]]),s=o.x,l=o.y,u=t.map((function(e){var t=Ft(e.geometry.coordinates,2),n=r.lngLatToPixel([t[0],t[1]]),a=n.y;return Math.pow(s-n.x,2)+Math.pow(l-a,2)})),c=Nl(u);return Math.pow(u[c],.5)>a?null:t[c].geometry.coordinates},jl=function(e,t,n,r){var a=n.lineAdsorbPixel,i=Ft(e,2),o=r.lngLatToPixel([i[0],i[1]]),s=o.x,l=o.y,u=t.filter((function(e){return dn(e).length>1})).map((function(t){return function(e,t,n){void 0===n&&(n={});var r=Wt([1/0,1/0],{dist:1/0}),a=0;return fn(e,(function(e){for(var i=bn(e),o=0;i.length-1>o;o++){var s=Wt(i[o]);s.properties.dist=mr(t,s,n);var l=Wt(i[o+1]);l.properties.dist=mr(t,l,n);var u=mr(s,l,n),c=Math.max(s.properties.dist,l.properties.dist),d=xr(s,l),p=yr(t,c,d+90,n),h=yr(t,c,d-90,n),f=Lr(Xt([p.geometry.coordinates,h.geometry.coordinates]),Xt([s.geometry.coordinates,l.geometry.coordinates])),v=null;f.features.length>0&&((v=f.features[0]).properties.dist=mr(t,v,n),v.properties.location=a+mr(s,v,n)),r.properties.dist>s.properties.dist&&((r=s).properties.index=o,r.properties.location=a),r.properties.dist>l.properties.dist&&((r=l).properties.index=o+1,r.properties.location=a+u),v&&r.properties.dist>v.properties.dist&&((r=v).properties.index=o),a+=u}})),r}(t,e)})),c=u.map((function(e){var t=Ft(e.geometry.coordinates,2),n=r.lngLatToPixel([t[0],t[1]]),a=n.y;return Math.pow(s-n.x,2)+Math.pow(l-a,2)})),d=Nl(c);return Math.pow(c[d],.5)>a?null:u[d].geometry.coordinates},Zl=function(e,t){var n=Ft(t,2),r=n[0],a=n[1];e.lngLat&&(e.lngLat={lng:r,lat:a}),e.lnglat&&(e.lnglat={lng:r,lat:a})},Ul=function(){function e(t,n){Ct(this,e),this.container=void 0,this.cursor=null,this.options=void 0,this.container=Pl(t),this.options=n}return Mt(e,[{key:"setCursor",value:function(e){e!==this.cursor&&this.container&&(this.container.style.cursor=e?this.options[e]:"",this.cursor=e)}}]),e}();function Vl(e,t){void 0===t&&(t={});var n=t.insertAt;if(e&&"undefined"!=typeof document){var r=document.head||document.getElementsByTagName("head")[0],a=document.createElement("style");a.type="text/css","top"===n&&r.firstChild?r.insertBefore(a,r.firstChild):r.appendChild(a),a.styleSheet?a.styleSheet.cssText=e:a.appendChild(document.createTextNode(e))}}Vl('.tippy-box[data-animation=fade][data-state=hidden]{opacity:0}[data-tippy-root]{max-width:calc(100vw - 10px)}.tippy-box{position:relative;background-color:#333;color:#fff;border-radius:4px;font-size:14px;line-height:1.4;white-space:normal;outline:0;transition-property:transform,visibility,opacity}.tippy-box[data-placement^=top]>.tippy-arrow{bottom:0}.tippy-box[data-placement^=top]>.tippy-arrow:before{bottom:-7px;left:0;border-width:8px 8px 0;border-top-color:initial;transform-origin:center top}.tippy-box[data-placement^=bottom]>.tippy-arrow{top:0}.tippy-box[data-placement^=bottom]>.tippy-arrow:before{top:-7px;left:0;border-width:0 8px 8px;border-bottom-color:initial;transform-origin:center bottom}.tippy-box[data-placement^=left]>.tippy-arrow{right:0}.tippy-box[data-placement^=left]>.tippy-arrow:before{border-width:8px 0 8px 8px;border-left-color:initial;right:-7px;transform-origin:center left}.tippy-box[data-placement^=right]>.tippy-arrow{left:0}.tippy-box[data-placement^=right]>.tippy-arrow:before{left:-7px;border-width:8px 8px 8px 0;border-right-color:initial;transform-origin:center right}.tippy-box[data-inertia][data-state=visible]{transition-timing-function:cubic-bezier(.54,1.5,.38,1.11)}.tippy-arrow{width:16px;height:16px;color:#333}.tippy-arrow:before{content:"";position:absolute;border-color:transparent;border-style:solid}.tippy-content{position:relative;padding:5px 9px;z-index:1}'),Vl(".tippy-box[data-theme~=light]{color:#26323d;box-shadow:0 0 20px 4px rgba(154,161,177,.15),0 4px 80px -8px rgba(36,40,47,.25),0 4px 4px -2px rgba(91,94,105,.15);background-color:#fff}.tippy-box[data-theme~=light][data-placement^=top]>.tippy-arrow:before{border-top-color:#fff}.tippy-box[data-theme~=light][data-placement^=bottom]>.tippy-arrow:before{border-bottom-color:#fff}.tippy-box[data-theme~=light][data-placement^=left]>.tippy-arrow:before{border-left-color:#fff}.tippy-box[data-theme~=light][data-placement^=right]>.tippy-arrow:before{border-right-color:#fff}.tippy-box[data-theme~=light]>.tippy-backdrop{background-color:#fff}.tippy-box[data-theme~=light]>.tippy-svg-arrow{fill:#fff}");var Hl=function(){function t(n,r){var a=this;Ct(this,t),this.content="",this.tippy=void 0,this.scene=void 0,this.isMouseInner=!1,this.onMouseMove=function(){a.isMouseInner=!0,a.checkTippyShow()},this.onMouseOut=function(){a.isMouseInner=!1,a.checkTippyShow()},this.setContent=xa((function(e){a.content=null!=e?e:"",a.tippy.setContent(null!=e?e:""),a.checkTippyShow()}),16,{maxWait:16}),this.tippy=st(Pl(n),Et(Et({},bt),r)),this.tippy.hide(),this.scene=n,n.on(e.SceneEvent.Mousemove,this.onMouseMove),n.on(e.SceneEvent.Mouseout,this.onMouseOut)}return Mt(t,[{key:"getContent",value:function(){return this.content}},{key:"checkTippyShow",value:function(){this.content&&this.isMouseInner?this.tippy.show():this.tippy.hide()}},{key:"destroy",value:function(){this.scene.off(e.SceneEvent.Mousemove,this.onMouseMove),this.scene.off(e.SceneEvent.Mouseout,this.onMouseOut),this.tippy.destroy()}}]),t}(),Gl=function(){function e(t){var n=t.config;Ct(this,e),this.historyList=[],this.historyIndex=0,this.config=void 0,this.config=n}return Mt(e,[{key:"save",value:function(e){if(this.config){var t=this.config.maxSize;this.historyIndex&&(this.historyList=this.historyList.slice(this.historyIndex),this.historyIndex=0),t>this.historyList.length||this.historyList.pop();var n=Is(e);return this.historyList.unshift(n),n}}},{key:"revert",value:function(){if(this.historyList.length&&this.historyList.length-1>this.historyIndex){var e=this.historyList[++this.historyIndex];return e?Is(e):void 0}}},{key:"redo",value:function(){if(this.historyList.length&&this.historyIndex>0){var e=this.historyList[--this.historyIndex];return e?Is(e):void 0}}}]),e}(),ql=function(t){At(r,t);var n=Dt(r);function r(e){var t,i=e.data,o=e.render,s=e.history;return Ct(this,r),(t=n.call(this)).render=void 0,t.data=Is(a),t.timeout=null,t.diffData={},t.history=void 0,t.render=o,s&&(t.history=new Gl({config:s})),i&&t.setData(i),t}return Mt(r,[{key:"saveHistory",value:function(){var e;return null===(e=this.history)||void 0===e?void 0:e.save(this.data)}},{key:"revertHistory",value:function(){var e,t=null===(e=this.history)||void 0===e?void 0:e.revert();if(t)return this.setData(t),t}},{key:"redoHistory",value:function(){var e,t=null===(e=this.history)||void 0===e?void 0:e.redo();if(t)return this.setData(t),t}},{key:"setData",value:function(t){var n=this;return Object.keys(t).length&&(this.data=Et(Et({},this.data),t),this.diffData=Et(Et({},this.diffData),t),this.timeout||(this.timeout=requestAnimationFrame((function(){return n.updateDiffData()}))),this.emit(e.SourceEvent.Change,{data:this.data})),this.data}},{key:"getData",value:function(){return this.data}},{key:"getRenderData",value:function(e){return this.data[e]}},{key:"setRenderData",value:function(t,n){var r="function"==typeof n?n(this.getRenderData(t)):n;return this.setData(Tt({},t,Bt(r).sort((function(e,t){return+e.properties.isActive-+t.properties.isActive})))),this.emit(e.SourceEvent.Change,this.data),r}},{key:"updateDiffData",value:function(){var t=this,n=Object.entries(this.diffData);n.length&&(n.forEach((function(e){var n,r=Ft(e,2),a=r[0],i=r[1];Array.isArray(i)&&(null===(n=t.getRender(a))||void 0===n||n.setData(i))})),this.emit(e.SourceEvent.Update,this.data,this.diffData),this.diffData={},this.timeout=null)}},{key:"getRender",value:function(e){return this.render[e]}},{key:"clear",value:function(){this.setData(_s(Object.keys(this.render).map((function(e){return[e,[]]}))))}}]),r}(Ur),Wl=function(t){At(a,t);var n=Dt(a);function a(t,r){var i;Ct(this,a),(i=n.call(this)).scene=void 0,i.source=void 0,i.render=void 0,i.cursor=void 0,i.options=void 0,i.enabled=!1,i.allowCreate=!1,i.sceneRender=void 0,i.mouseLngLat={lng:0,lat:0},i.popup=void 0,i.addCount=0,i.saveMouseLngLat=xa((function(e){i.mouseLngLat=Ol(e)}),100,{maxWait:100}),i.saveHistory=xa((function(){i.options.history&&i.source.saveHistory()}),100),i.bindThis(),i.scene=t,i.sceneRender=new Sa(t),i.options=pl({},i.getDefaultOptions(r),r),i.render=i.initRender(),i.source=new ql({render:i.render,history:i.options.history||void 0}),i.cursor=new Ul(t,i.options.cursor);var o=i.options,s=o.initialData,l=o.popup;return s&&i.setData(s),l&&(i.popup=new Hl(t,l instanceof Object?l:{})),i.saveHistory(),i.bindCommonEvent(),i.emit(e.DrawEvent.Init,Ot(i)),i.bindEnableEvent(),i}return Mt(a,[{key:"addable",get:function(){var e=this.getData(),t=this.options,n=t.multiple,r=t.maxCount,a=e.find((function(e){return e.properties.isDraw}));return!(!this.enabled||!this.allowCreate||!(n&&0>=r||a)&&(!n&&this.addCount>=1||!(0>=r||r>e.length)))}},{key:"getOptions",value:function(){return this.options}},{key:"getEditItem",value:function(){return this.editItem}},{key:"getDragItem",value:function(){return this.dragItem}},{key:"setHelper",value:function(e){var t,n,r=this.options.helper;if(r){var a=null!==(t=e in r?r[e]:e)&&void 0!==t?t:null;null===(n=this.popup)||void 0===n||n.setContent(a)}}},{key:"isEnable",value:function(){return this.enabled}},{key:"bindThis",value:function(){this.initRender=this.initRender.bind(this),this.getData=this.getData.bind(this),this.setData=this.setData.bind(this),this.emitChangeEvent=this.emitChangeEvent.bind(this),this.saveHistory=this.saveHistory.bind(this),this.onSceneMouseMove=this.onSceneMouseMove.bind(this),this.revertHistory=this.revertHistory.bind(this),this.redoHistory=this.redoHistory.bind(this),this.removeActiveFeature=this.removeActiveFeature.bind(this),this.bindCommonEvent=this.bindCommonEvent.bind(this),this.bindEnableEvent=this.bindEnableEvent.bind(this),this.unbindEnableEvent=this.unbindEnableEvent.bind(this),this.setActiveFeature=this.setActiveFeature.bind(this)}},{key:"bindCommonEvent",value:function(){var t=this;this.on(e.DrawEvent.Add,this.emitChangeEvent),this.on(e.DrawEvent.Add,(function(){t.addCount++})),this.on(e.DrawEvent.Edit,this.emitChangeEvent),this.on(e.DrawEvent.Remove,this.emitChangeEvent),this.on(e.DrawEvent.Clear,this.emitChangeEvent),this.on(e.DrawEvent.AddNode,this.saveHistory),this.on(e.DrawEvent.RemoveNode,this.emitChangeEvent)}},{key:"bindEnableEvent",value:function(){this.unbindKeyboardEvent(),this.scene.setMapStatus({doubleClickZoom:!1}),this.scene.on(e.SceneEvent.Mousemove,this.saveMouseLngLat),this.bindKeyboardEvent()}},{key:"unbindEnableEvent",value:function(){this.scene.setMapStatus({doubleClickZoom:!0}),this.scene.off(e.SceneEvent.Mousemove,this.saveMouseLngLat),this.unbindKeyboardEvent()}},{key:"bindKeyboardEvent",value:function(){var e=this,t=this.options.keyboard||{},n=t.revert,r=t.redo,a=t.remove;a&&gl.bind(a,(function(){e.removeActiveFeature()})),this.options.history&&(n&&gl.bind(n,this.revertHistory),r&&gl.bind(r,this.redoHistory))}},{key:"unbindKeyboardEvent",value:function(){var e=this.options.keyboard||{},t=e.revert,n=e.redo,r=e.remove;r&&gl.unbind(r),this.options.history&&(t&&gl.unbind(t),n&&gl.unbind(n))}},{key:"emitChangeEvent",value:function(){this.emit(e.DrawEvent.Change,this.getData()),this.saveHistory()}},{key:"revertHistory",value:function(){this.enabled&&this.options.history&&this.source.revertHistory()&&this.correctDrawItem()}},{key:"redoHistory",value:function(){this.enabled&&this.options.history&&this.source.redoHistory()&&this.correctDrawItem()}},{key:"getRenderLayers",value:function(){return _s(ml(this.render).map((function(e){var t=Ft(e,2);return[t[0],t[1].getLayers()]})))}},{key:"getTargetFeature",value:function(e){var t,n,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.getData(),a=null;return e&&(a=null!==(t=r.find((function(t){var n;return t.properties.id===("string"==typeof e?e:null===(n=e.properties)||void 0===n?void 0:n.id)})))&&void 0!==t?t:null,!a&&e instanceof Object&&(a=null!==(n=r.find((function(t){return Us(e.geometry,t.geometry)})))&&void 0!==n?n:null)),a}},{key:"removeActiveFeature",value:function(){var e=this.getData().find((function(e){var t=e.properties;return t.isActive||t.isDraw}));return e&&this.removeFeature(e),e}},{key:"removeFeature",value:function(t){var n=this.getData(),r=this.getTargetFeature(t);r&&(this.setData(n.filter((function(e){return!Il(r,e)}))),this.emit(e.DrawEvent.Remove,t,this.getData()))}},{key:"correctDrawItem",value:function(){this.getData().find((function(e){return e.properties.isDraw}))&&this.onSceneMouseMove({type:"mousemove",lnglat:this.mouseLngLat,lngLat:this.mouseLngLat})}},{key:"initRender",value:function(){var e,t={},n=function(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=jt(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,a=function(){};return{s:a,n:function(){return e.length>r?{done:!1,value:e[r++]}:{done:!0}},e:function(e){throw e},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,o=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return o=e.done,e},e:function(e){s=!0,i=e},f:function(){try{o||null==n.return||n.return()}finally{if(s)throw i}}}}(this.getRenderTypes());try{for(n.s();!(e=n.n()).done;){var r=e.value;t[r]=new(0,Ca[r])(this.scene,{style:this.options.style[r]})}}catch(e){n.e(e)}finally{n.f()}return t}},{key:"getCommonOptions",value:function(e){return{initialData:[],autoActive:!0,cursor:Is(r),editable:!0,style:Is(Na),multiple:!0,history:Is(It),keyboard:Is(_t),popup:!0,helper:{},maxCount:-1}}},{key:"setCursor",value:function(e){this.cursor.setCursor(e)}},{key:"resetCursor",value:function(){this.setCursor(this.addable?"draw":null)}},{key:"enable",value:function(){var t=this,n=0>=arguments.length||void 0===arguments[0]||arguments[0];this.allowCreate=n,this.addCount=0,this.enabled=!0,this.bindEnableEvent(),this.resetCursor(),this.setHelper(this.addable?"draw":null),setTimeout((function(){t.emit(e.DrawEvent.Enable,t)}),0)}},{key:"disable",value:function(){var t=this;this.resetFeatures(),this.enabled=!1,this.setCursor(null),this.unbindEnableEvent(),this.addCount=0,this.setHelper(null),setTimeout((function(){t.emit(e.DrawEvent.Disable,t)}),0)}},{key:"clear",value:function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.source.clear(),this.emit(e.DrawEvent.Clear,this),t&&this.disable()}},{key:"show",value:function(){return Object.values(this.render).forEach((function(e){e.show()}))}},{key:"hide",value:function(){return Object.values(this.render).forEach((function(e){e.hide()}))}},{key:"destroy",value:function(){var t=this;Object.values(this.render).forEach((function(e){e.destroy()})),Object.values(e.RenderEvent).forEach((function(e){Object.values(t.render).forEach((function(t){t.removeAllListeners(e)})),t.sceneRender.removeAllListeners(e)})),setTimeout((function(){Object.values(e.DrawEvent).forEach((function(e){t.removeAllListeners(e)}))}),0),this.emit(e.DrawEvent.Destroy,this)}}]),a}(Ur),Yl=function(e){var t=null==e?0:e.length;return t?e[t-1]:void 0},Xl=function(t){At(r,t);var n=Dt(r);function r(){return Ct(this,r),n.apply(this,arguments)}return Mt(r,[{key:"pointRender",get:function(){return this.render.point}},{key:"dragPoint",get:function(){return this.getPointData().find((function(e){return e.properties.isDrag}))}},{key:"editPoint",get:function(){return this.getPointData().find((function(e){return e.properties.isActive}))}},{key:"hoverPoint",get:function(){return this.getPointData().find((function(e){return e.properties.isHover}))}},{key:"getDragPoint",value:function(){return this.dragPoint}},{key:"getEditPoint",value:function(){return this.editPoint}},{key:"getPointData",value:function(){return this.source.getRenderData("point")}},{key:"setPointData",value:function(e){return this.source.setRenderData("point",e)}},{key:"bindPointRenderEvent",value:function(){var t,n,r,a,i,o;null===(t=this.pointRender)||void 0===t||t.on(e.RenderEvent.UnClick,this.onPointCreate.bind(this)),null===(n=this.pointRender)||void 0===n||n.on(e.RenderEvent.Mousemove,this.onPointMouseMove.bind(this)),null===(r=this.pointRender)||void 0===r||r.on(e.RenderEvent.Mouseout,this.onPointMouseOut.bind(this)),null===(a=this.pointRender)||void 0===a||a.on(e.RenderEvent.Dragstart,this.onPointDragStart.bind(this)),null===(i=this.pointRender)||void 0===i||i.on(e.RenderEvent.Dragging,this.onPointDragging.bind(this)),null===(o=this.pointRender)||void 0===o||o.on(e.RenderEvent.Dragend,this.onPointDragEnd.bind(this))}},{key:"handleCreatePoint",value:function(e){var t=this.options,n=t.autoActive,r=t.editable,a=El(e);return this.setPointData((function(e){return _l({target:a,data:[].concat(Bt(e),[a]),targetHandler:function(e){e.properties=Et(Et({},e.properties),{},{isHover:r,isActive:n&&r})},otherHandler:function(e){e.properties=Et(Et({},e.properties),{},{isHover:!1,isActive:!1,isDrag:!1})}})})),a}},{key:"handlePointHover",value:function(e){return this.setCursor("pointHover"),Il(e,this.hoverPoint)||this.setPointData((function(t){return _l({target:e,data:t,targetHandler:function(e){e.properties.isHover=!0},otherHandler:function(e){e.properties.isHover=!1}})})),e}},{key:"handlePointUnHover",value:function(e){return this.resetCursor(),this.setPointData((function(e){return e.map((function(e){return e.properties.isHover=!1,e}))})),e}},{key:"handlePointDragStart",value:function(e){return this.setPointData((function(t){return _l({target:e,data:t,targetHandler:function(e){e.properties=Et(Et({},e.properties),{},{isDrag:!0,isActive:!0})},otherHandler:function(e){e.properties=Et(Et({},e.properties),{},{isDrag:!1,isActive:!1})}})})),this.scene.setMapStatus({dragEnable:!1}),this.setCursor("pointDrag"),e}},{key:"handlePointDragging",value:function(e,t){return this.setPointData((function(n){return _l({target:e,data:n,targetHandler:function(e){e.geometry.coordinates=Dl(t)}})})),this.scene.setMapStatus({dragEnable:!1}),this.setCursor("pointDrag"),e}},{key:"handlePointDragEnd",value:function(e){return this.setPointData((function(t){return _l({target:e,data:t,targetHandler:function(e){e.properties.isDrag=!1}})})),this.scene.setMapStatus({dragEnable:!0}),this.setCursor("pointHover"),e}},{key:"onPointCreate",value:function(e){return this.handleCreatePoint(Dl(Ol(e)))}},{key:"onPointMouseMove",value:function(e){return this.handlePointHover(e.feature)}},{key:"onPointMouseOut",value:function(e){return this.handlePointUnHover(e.feature)}},{key:"onPointDragStart",value:function(e){if(this.options.editable)return this.handlePointDragStart(e.feature)}},{key:"onPointDragging",value:function(e){var t=this.dragPoint;if(this.options.editable&&t)return this.handlePointDragging(t,Ol(e))}},{key:"onPointDragEnd",value:function(e){var t=this.dragPoint;if(this.options.editable&&t)return this.handlePointDragEnd(t)}},{key:"enablePointRenderAction",value:function(){var e,t,n,r,a=this.options.editable;this.enabled&&(null===(t=this.pointRender)||void 0===t||t.enableCreate()),null===(e=this.pointRender)||void 0===e||e.enableClick(),a&&(null===(n=this.pointRender)||void 0===n||n.enableHover(),null===(r=this.pointRender)||void 0===r||r.enableDrag())}},{key:"disablePointRenderAction",value:function(){var e,t,n,r;null===(e=this.pointRender)||void 0===e||e.disableCreate(),null===(t=this.pointRender)||void 0===t||t.disableHover(),null===(n=this.pointRender)||void 0===n||n.disableDrag(),null===(r=this.pointRender)||void 0===r||r.disableClick()}}]),r}(Wl),Kl=function(t){At(r,t);var n=Dt(r);function r(){return Ct(this,r),n.apply(this,arguments)}return Mt(r,[{key:"midPointRender",get:function(){return this.render.midPoint}},{key:"getCommonOptions",value:function(e){return Et(Et({},zt(Lt(r.prototype),"getCommonOptions",this).call(this,e)),{},{showMidPoint:!0})}},{key:"bindMidPointRenderEvent",value:function(){var t,n,r;null===(t=this.midPointRender)||void 0===t||t.on(e.RenderEvent.Click,this.onMidPointClick.bind(this)),null===(n=this.midPointRender)||void 0===n||n.on(e.RenderEvent.Mousemove,this.onMidPointHover.bind(this)),null===(r=this.midPointRender)||void 0===r||r.on(e.RenderEvent.Mouseout,this.onMidPointUnHover.bind(this))}},{key:"getMidPointData",value:function(){return this.source.getRenderData("midPoint")}},{key:"setMidPointData",value:function(e){return this.source.setRenderData("midPoint",e)}},{key:"getMidPointsByLine",value:function(e){var t=e.properties.nodes;if(!this.options.showMidPoint||2>t.length)return[];for(var n=[],r=0;t.length-1>r;r++){var a,i,o,s,l=Ir(Kt([t[r],t[r+1]]),{properties:{id:xl("midPoint"),startId:null!==(a=null===(i=t[r].properties)||void 0===i?void 0:i.id)&&void 0!==a?a:"",endId:null!==(o=null===(s=t[r+1].properties)||void 0===s?void 0:s.id)&&void 0!==o?o:""}});n.push(l)}return n}},{key:"onMidPointHover",value:function(e){this.setCursor("pointHover")}},{key:"onMidPointUnHover",value:function(e){this.resetCursor()}},{key:"enableMidPointRenderAction",value:function(){var e,t;null===(e=this.midPointRender)||void 0===e||e.enableClick(),null===(t=this.midPointRender)||void 0===t||t.enableHover()}},{key:"disableMidPointRenderAction",value:function(){var e,t;null===(e=this.midPointRender)||void 0===e||e.disableClick(),null===(t=this.midPointRender)||void 0===t||t.disableHover()}}]),r}(Xl),Jl={draw:"单击绘制点",pointHover:"可拖拽调整点位置",pointDrag:null},$l={draw:"单击绘制首个节点",pointHover:"可拖拽调整节点位置",pointDrag:null,lineHover:"可拖拽调整线位置",lineDrag:null,midPointHover:"单击在该位置新增节点",drawFinish:"单击继续绘制,双击结束绘制"},Ql={draw:"单击绘制首个节点",drawContinue:"单击继续绘制",drawFinish:"单击继续绘制,双击结束绘制",midPointHover:"单击在该位置新增节点",pointHover:"可拖拽调整节点位置",pointDrag:null,lineHover:"可拖拽调整面位置",lineDrag:null,polygonHover:"可拖拽调整面位置",polygonDrag:null},eu=Et(Et({},Ql),{},{draw:"单击绘制首个节点",drawFinish:"单击结束绘制"}),tu={draw:"拖拽开始绘制",drawFinish:"松开鼠标结束绘制"},nu={lineHover:"可拖拽调整矩形位置",polygonHover:"可拖拽调整矩形位置"},ru={lineHover:"可拖拽调整圆位置",polygonHover:"可拖拽调整圆位置"},au=function(t){At(r,t);var n=Dt(r);function r(){var e;Ct(this,r);for(var t=arguments.length,a=Array(t),i=0;t>i;i++)a[i]=arguments[i];return(e=n.call.apply(n,[this].concat(a))).previousPosition=[0,0],e}return Mt(r,[{key:"lineRender",get:function(){return this.render.line}},{key:"dragLine",get:function(){return this.getLineData().find((function(e){return e.properties.isDrag}))}},{key:"drawLine",get:function(){return this.getLineData().find((function(e){return e.properties.isDraw}))}},{key:"editLine",get:function(){return this.getLineData().find((function(e){var t=e.properties;return!t.isDraw&&t.isActive}))}},{key:"hoverLine",get:function(){return this.getLineData().find((function(e){return e.properties.isHover}))}},{key:"getDragLine",value:function(){return this.dragLine}},{key:"getDrawLine",value:function(){return this.drawLine}},{key:"getEditLine",value:function(){return this.editLine}},{key:"getDefaultOptions",value:function(e){var t=Et(Et({},this.getCommonOptions(e)),{},{showMidPoint:!0,distanceOptions:!1,helper:Is($l)});return e.distanceOptions&&(t.distanceOptions=Et(Et({},yt),t.distanceOptions)),e.adsorbOptions&&(t.adsorbOptions=Et(Et({},wt),t.adsorbOptions)),t}},{key:"getAdsorbPosition",value:function(e){var t=this.options.adsorbOptions;if("boolean"==typeof t)return e;var n=this.scene,r=t.pointAdsorbPixel,a=t.lineAdsorbPixel,i=null,o=Fl(t.data,this,e),s=o.points,l=o.lines;return s.length&&r>0&&(i=Bl(e,s,t,n)),!i&&l.length&&a>0&&(i=jl(e,l,t,n)),i}},{key:"bindSceneEvent",value:function(){this.sceneRender.on(e.RenderEvent.Mousemove,this.onSceneMouseMove.bind(this))}},{key:"bindPointRenderEvent",value:function(){var t;zt(Lt(r.prototype),"bindPointRenderEvent",this).call(this),null===(t=this.pointRender)||void 0===t||t.on(e.RenderEvent.Click,this.onPointClick.bind(this))}},{key:"bindLineRenderEvent",value:function(){var t,n,r,a,i,o;null===(t=this.lineRender)||void 0===t||t.on(e.RenderEvent.UnClick,this.onLineUnClick.bind(this)),null===(n=this.lineRender)||void 0===n||n.on(e.RenderEvent.Mousemove,this.onLineMouseMove.bind(this)),null===(r=this.lineRender)||void 0===r||r.on(e.RenderEvent.Mouseout,this.onLineMouseOut.bind(this)),null===(a=this.lineRender)||void 0===a||a.on(e.RenderEvent.Dragstart,this.onLineDragStart.bind(this)),null===(i=this.lineRender)||void 0===i||i.on(e.RenderEvent.Dragging,this.onLineDragging.bind(this)),null===(o=this.lineRender)||void 0===o||o.on(e.RenderEvent.Dragend,this.onLineDragEnd.bind(this))}},{key:"getDashLineDistanceTexts",value:function(e,t){var n=t.showTotalDistance,r=t.format;return t.showDashDistance?e.map((function(e){return Al(e,{showTotalDistance:n,format:r},{isActive:!0,type:"dash"})})).flat():[]}},{key:"getLineDistanceTexts",value:function(e,t){var n=t.showTotalDistance,r=t.format,a=t.showWhen,i=[];if(a.includes("active")){var o=e.filter((function(e){return e.properties.isActive&&e.properties.nodes.length>1}));i.push.apply(i,Bt(o.map((function(e){return Al(e,{showTotalDistance:n,format:r},{isActive:!0})})).flat()))}if(a.includes("normal")){var s=e.filter((function(e){return!e.properties.isActive&&e.properties.nodes.length>1}));i.push.apply(i,Bt(s.map((function(e){return Al(e,{showTotalDistance:n,format:r})})).flat()))}return i}},{key:"getDistanceTexts",value:function(){var e=this.options.distanceOptions;if(!e)return[];var t=[],n=e.showWhen,r=e.showDashDistance,a=e.format,i=e.showTotalDistance;return t.push.apply(t,Bt(this.getDashLineDistanceTexts(this.getDashLineData(),{showTotalDistance:!1,format:a,showDashDistance:r})).concat(Bt(this.getLineDistanceTexts(this.getLineData(),{showTotalDistance:i,format:a,showWhen:n})))),t}},{key:"getAllTexts",value:function(){return this.getDistanceTexts()}},{key:"handleCreateLine",value:function(e){var t=Cl([e],{isActive:!0,isDraw:!0});return this.setLineData((function(e){return _l({target:t,data:[].concat(Bt(e),[t]),otherHandler:function(e){e.properties.isActive=!1}})})),this.setPointData([e]),this.setTextData(this.getAllTexts()),t}},{key:"syncLineNodes",value:function(e,t){return e.properties.nodes=t,e.geometry.coordinates=dn(Kt(t)),this.setLineData((function(t){return t.map((function(t){return Il(t,e)?e:t}))})),Il(this.editLine,e)&&this.setMidPointData(this.getMidPointsByLine(e)),this.setPointData(e.properties.nodes),this.setTextData(this.getAllTexts()),e}},{key:"setActiveLine",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this.setLineData((function(n){return _l({target:e,data:n,targetHandler:function(e){e.properties=Et(Et({},e.properties),{},{isDraw:!1,isActive:!0,isDrag:!1,isHover:!1},t)},otherHandler:function(e){e.properties=Et(Et({},e.properties),{},{isDraw:!1,isActive:!1,isDrag:!1})}})})),this.setPointData(e.properties.nodes.map((function(e){return e.properties=Et(Et({},e.properties),{},{isHover:!1,isActive:!1}),e}))),this.setMidPointData(this.getMidPointsByLine(e)),this.setDashLineData([]),this.setTextData(this.getAllTexts()),e}},{key:"clearActiveLine",value:function(){this.source.setData({point:[],line:this.getLineData().map((function(e){return e.properties=Et(Et({},e.properties),{},{isActive:!1,isHover:!1}),e})),midPoint:[],text:this.getAllTexts()})}},{key:"handleLineUnClick",value:function(e){return this.clearActiveLine(),e}},{key:"handleLineHover",value:function(e){if(!this.drawLine)return this.setCursor("lineHover"),Il(e,this.hoverLine)||this.setLineData((function(t){return _l({target:e,data:t,targetHandler:function(e){e.properties.isHover=!0},otherHandler:function(e){e.properties.isHover=!1}})})),e}},{key:"handleLineUnHover",value:function(e){if(!this.drawLine)return this.resetCursor(),this.setLineData((function(e){return e.map((function(e){return e.properties.isHover=!1,e}))})),e}},{key:"handleLineDragStart",value:function(e){return this.setActiveLine(e,{isDrag:!0,isActive:!0}),this.scene.setMapStatus({dragEnable:!1}),this.setCursor("lineDrag"),e}},{key:"handleLineDragging",value:function(e,t){var n=t.lng,r=t.lat,a=e.properties.nodes,i=Ft(this.previousPosition,2),o=i[0],s=i[1];return a.forEach((function(e){var t=e.geometry.coordinates;e.geometry.coordinates=[t[0]+n-o,t[1]+r-s]})),this.syncLineNodes(e,a),this.setActiveLine(e,{isDrag:!0}),this.setCursor("lineDrag"),this.previousPosition=[n,r],e}},{key:"handleLineDragEnd",value:function(e){return e.properties.isDrag=!1,this.setLineData((function(e){return e})),this.scene.setMapStatus({dragEnable:!0}),e}},{key:"resetAdsorbLngLat",value:function(e){if(this.options.adsorbOptions){var t=this.getAdsorbPosition(Dl(Ol(e)));return t&&Zl(e,t),t}}},{key:"onPointCreate",value:function(e){if(!this.editLine){this.resetAdsorbLngLat(e);var t=zt(Lt(r.prototype),"onPointCreate",this).call(this,e),n=this.drawLine;if(t)return n?(this.syncLineNodes(n,[].concat(Bt(n.properties.nodes),[t])),this.setDashLineData([])):this.handleCreateLine(t),t}}},{key:"onPointDragStart",value:function(e){if(this.editLine)return this.setHelper("pointDrag"),zt(Lt(r.prototype),"onPointDragStart",this).call(this,e)}},{key:"onPointDragging",value:function(e){var t=zt(Lt(r.prototype),"onPointDragging",this).call(this,e);if(t){var n=this.resetAdsorbLngLat(e);n&&(t.geometry.coordinates=Is(n))}var a=this.editLine;return a&&t&&(this.syncLineNodes(a,a.properties.nodes.map((function(e){return Il(t,e)?t:e}))),this.setActiveLine(a)),t}},{key:"onPointDragEnd",value:function(e){if(this.editLine){var t=zt(Lt(r.prototype),"onPointDragEnd",this).call(this,e);return this.setPointData((function(e){return e.map((function(e){return e.properties.isActive=!1,e}))})),this.setHelper("pointHover"),t}}},{key:"onLineUnClick",value:function(e){var t=this.editLine;if(t)return this.handleLineUnClick(t)}},{key:"onLineMouseMove",value:function(e){if(!this.drawLine)return this.dragLine||this.drawLine||!this.options.editable||this.setHelper("lineHover"),this.handleLineHover(e.feature)}},{key:"onLineMouseOut",value:function(e){if(!this.drawLine)return this.dragLine||this.drawLine||this.setHelper(this.addable?"draw":null),this.handleLineUnHover(e.feature)}},{key:"onLineDragStart",value:function(e){if(this.options.editable&&!this.drawLine)return this.previousPosition=Rl(e),this.setHelper("lineDrag"),this.handleLineDragStart(e.feature)}},{key:"onLineDragging",value:function(e){var t=this.dragLine;if(t)return this.handleLineDragging(t,Ol(e))}},{key:"onLineDragEnd",value:function(e){var t=this.dragLine;if(t)return this.setHelper("lineHover"),this.handleLineDragEnd(t)}},{key:"onPointMouseMove",value:function(e){var t=zt(Lt(r.prototype),"onPointMouseMove",this).call(this,e);return this.dragLine||this.drawLine||this.dragPoint||this.setHelper("pointHover"),t}},{key:"onPointMouseOut",value:function(e){var t=zt(Lt(r.prototype),"onPointMouseOut",this).call(this,e);return this.dragLine||this.drawLine||this.dragPoint||this.setHelper(this.addable?"draw":null),t}},{key:"onMidPointHover",value:function(e){zt(Lt(r.prototype),"onMidPointHover",this).call(this,e),this.setHelper("midPointHover")}},{key:"onMidPointUnHover",value:function(e){zt(Lt(r.prototype),"onMidPointUnHover",this).call(this,e),this.setHelper(null)}},{key:"onPointClick",value:function(e){}},{key:"getLineData",value:function(){return this.source.getRenderData("line")}},{key:"setLineData",value:function(e){return this.source.setRenderData("line",e)}},{key:"getTextData",value:function(){return this.source.getRenderData("text")}},{key:"setTextData",value:function(e){return this.source.setRenderData("text",e)}},{key:"getDashLineData",value:function(){return this.source.getRenderData("dashLine")}},{key:"setDashLineData",value:function(e){return this.source.setRenderData("dashLine",e)}},{key:"onMidPointClick",value:function(e){var t=this.editLine,n=e.feature;if(t&&n&&!this.dragPoint){var r=t.properties.nodes,a=n.properties,i=a.startId,o=a.endId,s=r.findIndex((function(e){return e.properties.id===i})),l=r.findIndex((function(e){return e.properties.id===o}));if(s>-1&&l>-1){var u=El(n.geometry.coordinates,{isDrag:!0,isHover:!0});return this.setHelper("pointDrag"),r.splice(l,0,u),t.geometry.coordinates=dn(Kt(r)),this.syncLineNodes(t,r),this.setActiveLine(t),u}}}},{key:"enableSceneRenderAction",value:function(){this.sceneRender.enableDrag(),this.sceneRender.enableMouseMove(),this.sceneRender.enableDblClick()}},{key:"disableSceneRenderAction",value:function(){this.sceneRender.disableDrag(),this.sceneRender.disableMouseMove(),this.sceneRender.disableDblClick()}},{key:"enableLineRenderAction",value:function(){var e,t,n,r=this.options.editable;null===(e=this.lineRender)||void 0===e||e.enableUnClick(),r&&(null===(t=this.lineRender)||void 0===t||t.enableHover(),null===(n=this.lineRender)||void 0===n||n.enableDrag())}},{key:"disableLineRenderAction",value:function(){var e,t,n;null===(e=this.lineRender)||void 0===e||e.disableUnClick(),null===(t=this.lineRender)||void 0===t||t.disableHover(),null===(n=this.lineRender)||void 0===n||n.disableDrag()}}]),r}(Kl),iu=function(t){At(r,t);var n=Dt(r);function r(){return Ct(this,r),n.apply(this,arguments)}return Mt(r,[{key:"dragItem",get:function(){return this.dragPolygon}},{key:"editItem",get:function(){return this.editPolygon}},{key:"polygonRender",get:function(){return this.render.polygon}},{key:"dragPolygon",get:function(){return this.getPolygonData().find((function(e){return e.properties.isDrag}))}},{key:"drawPolygon",get:function(){return this.getPolygonData().find((function(e){return e.properties.isDraw}))}},{key:"editPolygon",get:function(){return this.getPolygonData().find((function(e){var t=e.properties;return!t.isDraw&&t.isActive}))}},{key:"hoverPolygon",get:function(){return this.getPolygonData().find((function(e){return e.properties.isHover}))}},{key:"getDragPolygon",value:function(){return this.dragPolygon}},{key:"getDrawPolygon",value:function(){return this.drawPolygon}},{key:"getEditPolygon",value:function(){return this.editPolygon}},{key:"getRenderTypes",value:function(){return["polygon","line","dashLine","midPoint","point","text"]}},{key:"getData",value:function(){return this.getPolygonData()}},{key:"getDefaultOptions",value:function(e){var t=Et(Et({},zt(Lt(r.prototype),"getDefaultOptions",this).call(this,e)),{},{areaOptions:!1,helper:Is(Ql)});return e.areaOptions&&(t.areaOptions=Et(Et({},xt),e.areaOptions)),t}},{key:"getAreaTexts",value:function(e){var t=this.options.areaOptions;if(!t)return[];var n=t.format,r=t.showWhen,a=[],i=e.filter((function(e){return e.geometry.coordinates[0].length>=4}));return r.includes("active")&&i.filter((function(e){return e.properties.isActive})).forEach((function(e){a.push(Ll(e,{format:n},{isActive:!0}))})),r.includes("normal")&&i.filter((function(e){return!e.properties.isActive})).forEach((function(e){a.push(Ll(e,{format:n},{isActive:!1}))})),a}},{key:"getAllTexts",value:function(){return[].concat(Bt(zt(Lt(r.prototype),"getAllTexts",this).call(this)),Bt(this.getAreaTexts(this.getPolygonData())))}},{key:"getPolygonData",value:function(){return this.source.getRenderData("polygon")}},{key:"setPolygonData",value:function(e){return this.source.setRenderData("polygon",e)}},{key:"handleCreatePolygon",value:function(e,t){var n=Ml(e,{nodes:e,line:t,isActive:!0,isDraw:!0});return this.setPolygonData((function(e){return _l({target:n,data:[].concat(Bt(e),[n]),otherHandler:function(e){e.properties.isActive=!1}})})),n}},{key:"handlePolygonUnClick",value:function(e){return this.clearActivePolygon(),e}},{key:"handlePolygonHover",value:function(e){return this.setCursor("polygonHover"),Il(e,this.hoverPolygon)||this.setPolygonData((function(t){return _l({target:e,data:t,targetHandler:function(e){e.properties.isHover=!0},otherHandler:function(e){e.properties.isHover=!1}})})),e}},{key:"handlePolygonUnHover",value:function(){this.resetCursor(),this.setPolygonData((function(e){return e.map((function(e){return e.properties.isHover=!1,e}))}))}},{key:"handlePolygonDragStart",value:function(e){return this.setActivePolygon(e,{isDrag:!0}),this.scene.setMapStatus({dragEnable:!1}),this.setCursor("polygonDrag"),e}},{key:"bindPolygonRenderEvent",value:function(){var t,n,r,a;null===(t=this.polygonRender)||void 0===t||t.on(e.RenderEvent.UnClick,this.onPolygonUnClick.bind(this)),null===(n=this.polygonRender)||void 0===n||n.on(e.RenderEvent.Mousemove,this.onPolygonHover.bind(this)),null===(r=this.polygonRender)||void 0===r||r.on(e.RenderEvent.Mouseout,this.onPolygonUnHover.bind(this)),null===(a=this.polygonRender)||void 0===a||a.on(e.RenderEvent.Dragstart,this.onPolygonDragStart.bind(this))}},{key:"syncPolygonNodes",value:function(e,t){var n=dn(Kt([].concat(Bt(t),[yl(t)]))),r=e.properties.line;if(e.properties.nodes=t,e.geometry.coordinates=[Zr(Xt(n))?n:n.reverse()],this.setPolygonData((function(t){return t.map((function(t){return Il(t,e)?e:t}))})),!Il(this.drawPolygon,e)){var a=r.properties.nodes,i=Bt(t),o=yl(i);i.push(a.length===t.length?El(o.geometry.coordinates):Yl(a));var s=Yl(i);Us(o.geometry.coordinates,s.geometry.coordinates)||(s.geometry.coordinates=Is(o.geometry.coordinates)),this.syncLineNodes(r,i)}return e}},{key:"setActivePolygon",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this.setActiveLine(e.properties.line,t),this.setPolygonData((function(n){return _l({target:e,data:n,targetHandler:function(e){e.properties=Et(Et({},e.properties),{},{isDraw:!1,isActive:!0,isDrag:!1,isHover:!1},t)},otherHandler:function(e){e.properties=Et(Et({},e.properties),{},{isDraw:!1,isActive:!1,isDrag:!1})}})})),this.setTextData(this.getAllTexts()),e}},{key:"clearActivePolygon",value:function(){this.setPolygonData((function(e){return e.map((function(e){return e.properties=Et(Et({},e.properties),{},{isActive:!1,isHover:!1}),e}))})),this.clearActiveLine()}},{key:"onLineDragStart",value:function(t){var n=zt(Lt(r.prototype),"onLineDragStart",this).call(this,t),a=this.getPolygonData().find((function(e){return Il(e.properties.line,n)}));return a&&(this.setActivePolygon(a,{isDrag:!0}),this.emit(e.DrawEvent.DragStart,a,this.getPolygonData())),n}},{key:"onLineUnClick",value:function(e){return this.editLine}},{key:"onLineDragEnd",value:function(t){var n=zt(Lt(r.prototype),"onLineDragEnd",this).call(this,t),a=this.dragPolygon;return n&&a&&(a.properties.isDrag=!1,this.emit(e.DrawEvent.DragEnd,a,this.getPolygonData()),this.emit(e.DrawEvent.Edit,a,this.getPolygonData())),n}},{key:"onPolygonUnClick",value:function(e){var t=this.editPolygon;if(t)return this.handlePolygonUnClick(t)}},{key:"onPolygonHover",value:function(e){if(!this.drawPolygon)return this.dragPolygon||this.setHelper("polygonHover"),this.handlePolygonHover(e.feature)}},{key:"onPolygonUnHover",value:function(e){if(!this.drawPolygon)return this.setHelper(this.addable?"draw":null),this.handlePolygonUnHover()}},{key:"onPolygonDragStart",value:function(t){if(this.options.editable&&!this.drawPolygon){var n=t.feature;return this.previousPosition=Rl(t),this.setHelper("polygonDrag"),this.emit(e.DrawEvent.DragStart,n,this.getPolygonData()),this.handlePolygonDragStart(n)}}},{key:"onMidPointClick",value:function(e){var t=this.editPolygon,n=zt(Lt(r.prototype),"onMidPointClick",this).call(this,e);if(n&&t){var a=t.properties.line.properties.nodes;this.syncPolygonNodes(t,a.slice(0,a.length-1)),this.setActivePolygon(t)}return n}},{key:"onPointDragEnd",value:function(t){var n=this.editPolygon,a=zt(Lt(r.prototype),"onPointDragEnd",this).call(this,t);return a&&n&&this.emit(e.DrawEvent.Edit,n,this.getPolygonData()),a}},{key:"enablePolygonRenderAction",value:function(){var e,t,n,r=this.options.editable;null===(e=this.polygonRender)||void 0===e||e.enableUnClick(),r&&(null===(t=this.polygonRender)||void 0===t||t.enableHover(),null===(n=this.polygonRender)||void 0===n||n.enableDrag())}},{key:"disablePolygonRenderAction",value:function(){var e,t,n;null===(e=this.polygonRender)||void 0===e||e.disableUnClick(),null===(t=this.polygonRender)||void 0===t||t.disableHover(),null===(n=this.polygonRender)||void 0===n||n.disableDrag()}},{key:"bindEnableEvent",value:function(){zt(Lt(r.prototype),"bindEnableEvent",this).call(this),this.enableSceneRenderAction(),this.enablePointRenderAction(),this.enableLineRenderAction(),this.enableMidPointRenderAction(),this.enablePolygonRenderAction()}},{key:"unbindEnableEvent",value:function(){zt(Lt(r.prototype),"unbindEnableEvent",this).call(this),this.disableSceneRenderAction(),this.disablePointRenderAction(),this.disableLineRenderAction(),this.disableMidPointRenderAction(),this.disablePolygonRenderAction()}},{key:"bindThis",value:function(){zt(Lt(r.prototype),"bindThis",this).call(this),this.bindPointRenderEvent=this.bindPointRenderEvent.bind(this),this.bindSceneEvent=this.bindSceneEvent.bind(this),this.bindLineRenderEvent=this.bindLineRenderEvent.bind(this),this.bindMidPointRenderEvent=this.bindMidPointRenderEvent.bind(this),this.bindPolygonRenderEvent=this.bindPolygonRenderEvent.bind(this)}},{key:"setActiveFeature",value:function(e){var t=this.getTargetFeature(e);t?this.setActivePolygon(t):this.clearActivePolygon()}},{key:"resetFeatures",value:function(){var e=this.getPolygonData();this.drawPolygon&&(e=e.filter((function(e){return!e.properties.isDraw})),this.source.setData({point:[],dashLine:[],midPoint:[]}),this.setLineData((function(e){return e.filter((function(e){return!e.properties.isDraw}))})),this.setTextData((function(e){return e.filter((function(e){return!e.properties.isActive}))}))),this.editPolygon&&this.handlePolygonUnClick(this.editPolygon),this.setPolygonData(e.map((function(e){return e.properties=Et(Et({},e.properties),{},{isDrag:!1,isActive:!1,isHover:!1}),e})))}}]),r}(au),ou=function(t){At(r,t);var n=Dt(r);function r(e,t){var a;return Ct(this,r),(a=n.call(this,e,t)).onSceneDragStart=a.onSceneDragStart.bind(Ot(a)),a.onSceneDragEnd=a.onSceneDragEnd.bind(Ot(a)),a}return Mt(r,[{key:"drawLine",get:function(){var e;return null===(e=this.drawPolygon)||void 0===e?void 0:e.properties.line}},{key:"isDragTrigger",get:function(){return"drag"===this.options.trigger}},{key:"isClickTrigger",get:function(){return"click"===this.options.trigger}},{key:"getDefaultOptions",value:function(e){var t=Et(Et({},zt(Lt(r.prototype),"getDefaultOptions",this).call(this,e)),{},{showMidPoint:!1,trigger:"click",autoActive:!1,helper:Is(eu)});return"drag"===e.trigger&&(t.helper=Et(Et({},t.helper),tu)),t}},{key:"getMidPointsByLine",value:function(e){return[]}},{key:"handleCreatePolygon",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=t.properties.nodes;return Ml(r.slice(0,r.length-1),Et({nodes:e,line:t},n))}},{key:"handleFirstNodeCreate",value:function(t){var n=El(t.geometry.coordinates),r=this.handleCreatePolygonLine(t,n,{isDraw:!0,isActive:!0}),a=this.handleCreatePolygon([t,n],r,{isDraw:!0,isActive:!0});return this.setPolygonData((function(e){return _l({target:a,data:[].concat(Bt(e),[a]),targetHandler:function(e){e.properties=Et(Et({},e.properties),{},{isDraw:!0,isActive:!0})}})})),this.emit(e.DrawEvent.AddNode,t,this.drawPolygon,this.getPolygonData()),this.setHelper("drawFinish"),t}},{key:"handleLastNodeCreate",value:function(t){var n=this.options,r=n.autoActive,a=n.editable,i=this.drawPolygon;return i?(this.setLineData((function(e){return[].concat(Bt(e),[i.properties.line])})),this.setActivePolygon(i),r&&a||this.handlePolygonUnClick(i),this.emit(e.DrawEvent.Add,i,this.getPolygonData()),this.emit(e.DrawEvent.AddNode,i.properties.nodes[1],this.drawPolygon,this.getPolygonData()),this.setHelper(a?r?"pointHover":"polygonHover":this.addable?"draw":null),t):t}},{key:"onPointCreate",value:function(e){var t=this;if(this.addable&&!this.dragPoint&&!this.editLine&&this.isClickTrigger){var n=this.drawPolygon,r=Rl(e),a=this.handleCreatePoint(r);return n?requestAnimationFrame((function(){t.handleLastNodeCreate(a)})):this.handleFirstNodeCreate(a),a}}},{key:"setActivePolygon",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.setActiveLine(e.properties.line,t),this.setPolygonData((function(n){return _l({target:e,data:n,targetHandler:function(e){e.properties=Et(Et({},e.properties),{},{isDraw:!1,isActive:!0,isDrag:!1,isHover:!1},t)},otherHandler:function(e){e.properties=Et(Et({},e.properties),{},{isDraw:!1,isActive:!1,isDrag:!1})}})})),this.setPointData(e.properties.nodes),this.setDashLineData([]);var n=this.getAllTexts();return this.setTextData(n),e}},{key:"onPointDragging",value:function(e){var t=this.dragPoint;if(t){var n=this.handlePointDragging(t,Ol(e)),r=this.editPolygon;return n&&r&&(this.syncPolygonNodes(r,r.properties.nodes.map((function(e){return Il(e,n)?n:e}))),this.setActivePolygon(r)),n}}},{key:"onSceneDragStart",value:function(e){this.isDragTrigger&&this.addable&&!this.dragPoint&&!this.editLine&&(this.scene.setMapStatus({dragEnable:!1}),this.handleFirstNodeCreate(this.handleCreatePoint(Rl(e))))}},{key:"onSceneDragEnd",value:function(e){this.isDragTrigger&&this.addable&&!this.dragPoint&&!this.editLine&&this.drawPolygon&&(this.scene.setMapStatus({dragEnable:!1}),this.handleLastNodeCreate(this.handleCreatePoint(Rl(e))))}},{key:"onSceneMouseMove",value:function(e){var t=this.drawPolygon;if(t){var n=t.properties.nodes,r=yl(n),a=Yl(n);a.geometry.coordinates=Rl(e),this.syncPolygonNodes(t,[r,a]),this.setDashLineData([t.properties.line]),this.setTextData(this.getAllTexts()),this.resetCursor()}}},{key:"bindSceneDragEvent",value:function(){this.unbindSceneDragEvent(),this.sceneRender.on(e.RenderEvent.Dragstart,this.onSceneDragStart),this.sceneRender.on(e.RenderEvent.Dragend,this.onSceneDragEnd),this.scene.setMapStatus({dragEnable:!1})}},{key:"unbindSceneDragEvent",value:function(){this.sceneRender.off(e.RenderEvent.Dragstart,this.onSceneDragStart),this.sceneRender.off(e.RenderEvent.Dragend,this.onSceneDragEnd),this.scene.setMapStatus({dragEnable:!0})}},{key:"bindEnableEvent",value:function(){zt(Lt(r.prototype),"bindEnableEvent",this).call(this),this.isDragTrigger&&this.bindSceneDragEvent()}},{key:"unbindEnableEvent",value:function(){zt(Lt(r.prototype),"unbindEnableEvent",this).call(this),this.isDragTrigger&&this.unbindSceneDragEvent()}},{key:"bindThis",value:function(){zt(Lt(r.prototype),"bindThis",this).call(this),this.onSceneDragStart=this.onSceneDragStart.bind(this),this.onSceneDragEnd=this.onSceneDragEnd.bind(this)}}]),r}(iu),su=function(t){At(r,t);var n=Dt(r);function r(e,t){var a;return Ct(this,r),(a=n.call(this,e,t)).bindPointRenderEvent(),a.bindSceneEvent(),a.bindMidPointRenderEvent(),a.bindLineRenderEvent(),a.bindPolygonRenderEvent(),a}return Mt(r,[{key:"getDefaultOptions",value:function(e){var t=Et(Et({},zt(Lt(r.prototype),"getDefaultOptions",this).call(this,e)),{},{showMidPoint:!1,circleSteps:60});return t.distanceOptions&&(t.distanceOptions.showTotalDistance=!0,void 0===t.distanceOptions.showOnRadius&&(t.distanceOptions.showOnRadius=!0)),t.helper&&(t.helper=Et(Et({},t.helper),ru)),t}},{key:"getDistanceTexts",value:function(){var e=this.options.distanceOptions;if(!e)return[];var t=[],n=e.showWhen,r=e.showDashDistance,a=e.format,i=e.showTotalDistance;return t.push.apply(t,Bt(this.getDashLineDistanceTexts(this.getDashLineData(),{showTotalDistance:!0,format:a,showDashDistance:r})).concat(Bt(this.getLineDistanceTexts(this.getLineData(),{showTotalDistance:i,format:a,showWhen:n})))),t}},{key:"setData",value:function(e){var t=this,n=e.map((function(e){var n,r,a;e.properties=Et(Et({},Sl()),e.properties);var i=null===(n=e.properties)||void 0===n?void 0:n.nodes;if(2!==(null===(r=i)||void 0===r?void 0:r.length)){var o=Ft(Ir(e).geometry.coordinates,2),s=o[0],l=o[1],u=xn(e),c=u[2],d=(u[1]+u[3])/2;i=[El([s,l]),El([c,d])],e.properties.nodes=i}var p=i[0],h=i[1],f=!!(null===(a=e.properties)||void 0===a?void 0:a.isActive),v=e.properties.line;return v||(v=t.handleCreatePolygonLine(p,h,{isActive:f}),e.properties.line=v),t.handleCreatePolygon([p,h],v,Et(Et({},e.properties),{},{isActive:f}))}));this.source.setData({point:[],midPoint:[],dashLine:[],polygon:n,line:n.map((function(e){return e.properties.line}))}),this.setTextData(this.getAllTexts()),this.editPolygon&&this.setActivePolygon(this.editPolygon)}},{key:"handleCreatePolygonLine",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=this.getBoundaryPositions(e,t).map((function(e){return El(e)}));return Cl(r,n)}},{key:"syncPolygonNodes",value:function(e,t){var n=e.properties.line,r=this.getBoundaryPositions(t[0],t[1]);return e.properties.nodes=t,e.geometry.coordinates=[r],this.setPolygonData((function(t){return t.map((function(t){return Il(t,e)?e:t}))})),this.setPointData(e.properties.isDraw?[t[0]]:t),n.properties.nodes.forEach((function(e,t){e.geometry.coordinates=r[t]})),n.geometry.coordinates=r,e}},{key:"onLineDragging",value:function(t){var n=this.dragPolygon,a=Ft(this.previousPosition,2),i=a[0],o=a[1],s=zt(Lt(r.prototype),"onLineDragging",this).call(this,t);if(n){var l=Ft(Rl(t),2),u=l[0],c=l[1];n.properties.nodes.forEach((function(e){var t=Ft(e.geometry.coordinates,2);e.geometry.coordinates=[t[0]+u-i,t[1]+c-o]})),this.syncPolygonNodes(n,n.properties.nodes),this.setActivePolygon(n,{isDrag:!0}),this.emit(e.DrawEvent.Dragging,n,this.getPolygonData())}return s}},{key:"getBoundaryPositions",value:function(e,t){for(var n=this.options.circleSteps,r=mr(e,t,{units:"meters"}),a=xr(e,t),i=360/n,o=[Bt(t.geometry.coordinates)],s=1;n-1>=s;s++)o.push(yr(e,r,a+i*s,{units:"meters"}).geometry.coordinates);return o.push(Bt(t.geometry.coordinates)),o}}]),r}(ou),lu=function(t){At(r,t);var n=Dt(r);function r(t,a){var i;return Ct(this,r),(i=n.call(this,t,a)).drawLineFinish=function(){var t,n=i.drawLine,r=null!==(t=null==n?void 0:n.properties.nodes)&&void 0!==t?t:[];if(n&&(null==r?void 0:r.length)>1){i.setActiveLine(n);var a=i.options,o=a.autoActive,s=a.editable;o&&s||i.handleLineUnClick(n),i.setHelper(s&&o?"pointHover":i.addable?"draw":null),i.emit(e.DrawEvent.Add,n,i.getLineData())}},i.sceneRender.on(e.RenderEvent.DblClick,i.drawLineFinish),i.bindPointRenderEvent(),i.bindSceneEvent(),i.bindMidPointRenderEvent(),i.bindLineRenderEvent(),i}return Mt(r,[{key:"dragItem",get:function(){return this.dragLine}},{key:"editItem",get:function(){return this.editLine}},{key:"setData",value:function(e){var t=e.map((function(e){var t,n;return e.properties=Et(Et({},wl()),null!==(t=e.properties)&&void 0!==t?t:{}),(null===(n=e.properties.nodes)||void 0===n?void 0:n.length)||(e.properties.nodes=dn(e).map((function(e){return El(e)}))),e}));this.source.setData({point:[],midPoint:[],dashLine:[],line:t}),this.setTextData(this.getAllTexts()),this.editLine&&this.setActiveLine(this.editLine)}},{key:"getData",value:function(){return this.getLineData()}},{key:"getRenderTypes",value:function(){return["line","dashLine","midPoint","point","text"]}},{key:"bindPointRenderEvent",value:function(){var t;zt(Lt(r.prototype),"bindPointRenderEvent",this).call(this),null===(t=this.pointRender)||void 0===t||t.on(e.RenderEvent.Contextmenu,this.onPointContextMenu.bind(this))}},{key:"onPointClick",value:function(e){var t,n=this,r=this.drawLine,a=null!==(t=null==r?void 0:r.properties.nodes)&&void 0!==t?t:[],i=e.feature;if(Il(i,Yl(a)))requestAnimationFrame((function(){n.drawLineFinish()}));else{var o=Ft(i.geometry.coordinates,2);e.lngLat={lng:o[0],lat:o[1]},this.onPointCreate(e)}}},{key:"removeNode",value:function(t,n){var r,a=this.getTargetFeature(n),i=this.getTargetFeature(t,null!==(r=null==a?void 0:a.properties.nodes)&&void 0!==r?r:[]);if(a&&i){var o,s=null!==(o=null==a?void 0:a.properties.nodes)&&void 0!==o?o:[];if(3>s.length)return;this.syncLineNodes(a,s.filter((function(e){return!Il(i,e)}))),this.emit(e.DrawEvent.RemoveNode,i,a,this.getLineData()),this.emit(e.DrawEvent.Edit,a,this.getLineData())}}},{key:"onPointContextMenu",value:function(e){var t,n=this.editLine,r=e.feature,a=null!==(t=null==n?void 0:n.properties.nodes)&&void 0!==t?t:[];if(n&&a.length>=3)return this.removeNode(r,n),r}},{key:"onPointCreate",value:function(t){if(this.addable){var n=zt(Lt(r.prototype),"onPointCreate",this).call(this,t);return n&&(this.setHelper("drawFinish"),this.emit(e.DrawEvent.AddNode,n,this.drawLine,this.getLineData())),n}}},{key:"onPointDragEnd",value:function(t){var n=this.editLine,a=zt(Lt(r.prototype),"onPointDragEnd",this).call(this,t);return n&&a&&this.emit(e.DrawEvent.Edit,n,this.getLineData()),a}},{key:"onLineDragStart",value:function(t){var n=zt(Lt(r.prototype),"onLineDragStart",this).call(this,t);return n&&this.emit(e.DrawEvent.DragStart,n,this.getLineData()),n}},{key:"onLineDragging",value:function(t){var n=zt(Lt(r.prototype),"onLineDragging",this).call(this,t);return n&&this.emit(e.DrawEvent.Dragging,n,this.getLineData()),n}},{key:"onLineDragEnd",value:function(t){var n=zt(Lt(r.prototype),"onLineDragEnd",this).call(this,t);return n&&(this.emit(e.DrawEvent.DragEnd,n,this.getLineData()),this.emit(e.DrawEvent.Edit,n,this.getLineData())),n}},{key:"onMidPointClick",value:function(t){var n=this.editLine,a=zt(Lt(r.prototype),"onMidPointClick",this).call(this,t);return n&&a&&(this.emit(e.DrawEvent.Edit,n,this.getLineData()),this.emit(e.DrawEvent.AddNode,a,n,this.getLineData())),a}},{key:"onSceneMouseMove",value:function(e){var t=this.drawLine;if(t){var n,r=Yl(t.properties.nodes),a=Rl(e);this.options.adsorbOptions&&(a=null!==(n=this.getAdsorbPosition(a))&&void 0!==n?n:a),this.setDashLineData([kl([a,r.geometry.coordinates])]),this.setTextData(this.getAllTexts())}}},{key:"setActiveFeature",value:function(e){var t=this.getTargetFeature(e);t?this.setActiveLine(t):this.clearActiveLine()}},{key:"resetFeatures",value:function(){var e=this.getLineData();this.drawLine&&(e=e.filter((function(e){return!e.properties.isDraw})),this.source.setData({point:[],dashLine:[],midPoint:[]}),this.setTextData((function(e){return e.filter((function(e){return!e.properties.isActive}))}))),this.editLine&&this.handleLineUnClick(this.editLine),this.setLineData(e.map((function(e){return e.properties=Et(Et({},e.properties),{},{isDrag:!1,isActive:!1,isHover:!1}),e})))}},{key:"enablePointRenderAction",value:function(){var e;zt(Lt(r.prototype),"enablePointRenderAction",this).call(this),this.options.editable&&(null===(e=this.pointRender)||void 0===e||e.enableContextMenu())}},{key:"disablePointRenderAction",value:function(){var e;zt(Lt(r.prototype),"disablePointRenderAction",this).call(this),null===(e=this.pointRender)||void 0===e||e.disableContextMenu()}},{key:"bindEnableEvent",value:function(){zt(Lt(r.prototype),"bindEnableEvent",this).call(this),this.enableSceneRenderAction(),this.enablePointRenderAction(),this.enableLineRenderAction(),this.enableMidPointRenderAction(),this.sceneRender.enableDblClick()}},{key:"unbindEnableEvent",value:function(){zt(Lt(r.prototype),"unbindEnableEvent",this).call(this),this.disableSceneRenderAction(),this.disablePointRenderAction(),this.disableLineRenderAction(),this.disableMidPointRenderAction(),this.sceneRender.disableDblClick()}},{key:"bindThis",value:function(){zt(Lt(r.prototype),"bindThis",this).call(this),this.bindPointRenderEvent=this.bindPointRenderEvent.bind(this),this.bindSceneEvent=this.bindSceneEvent.bind(this),this.bindLineRenderEvent=this.bindLineRenderEvent.bind(this),this.bindMidPointRenderEvent=this.bindMidPointRenderEvent.bind(this)}}]),r}(au),uu=function(t){At(r,t);var n=Dt(r);function r(e,t){var a;return Ct(this,r),(a=n.call(this,e,t)).bindPointRenderEvent(),a}return Mt(r,[{key:"dragItem",get:function(){return this.dragPoint}},{key:"editItem",get:function(){return this.editPoint}},{key:"getDefaultOptions",value:function(e){var t=Et(Et({},this.getCommonOptions(e)),{},{helper:Is(Jl)});return t.style.point=Oa,t}},{key:"bindEnableEvent",value:function(){zt(Lt(r.prototype),"bindEnableEvent",this).call(this),this.enablePointRenderAction()}},{key:"unbindEnableEvent",value:function(){zt(Lt(r.prototype),"unbindEnableEvent",this).call(this),this.disablePointRenderAction()}},{key:"getRenderTypes",value:function(){return["point"]}},{key:"setData",value:function(e){this.setPointData(e.map((function(e){var t;return e.properties=Et(Et({},bl()),null!==(t=e.properties)&&void 0!==t?t:{}),e})))}},{key:"getData",value:function(){return this.getPointData()}},{key:"onPointCreate",value:function(t){if(this.addable){var n=zt(Lt(r.prototype),"onPointCreate",this).call(this,t);if(n)return this.options.editable&&this.setHelper("pointHover"),this.emit(e.DrawEvent.Add,n,this.getData()),n}else this.setPointData((function(e){return e.map((function(e){return e.properties=Et(Et({},e.properties),{},{isHover:!1,isActive:!1}),e}))}))}},{key:"onPointMouseMove",value:function(e){var t=zt(Lt(r.prototype),"onPointMouseMove",this).call(this,e);return this.options.editable&&!this.dragPoint&&this.setHelper("pointHover"),t}},{key:"onPointMouseOut",value:function(e){var t=zt(Lt(r.prototype),"onPointMouseOut",this).call(this,e);return this.setHelper(this.addable?"draw":null),t}},{key:"onPointDragStart",value:function(t){var n=zt(Lt(r.prototype),"onPointDragStart",this).call(this,t);return this.setHelper("pointDrag"),this.emit(e.DrawEvent.DragStart,n,this.getData()),n}},{key:"onPointDragging",value:function(t){var n=zt(Lt(r.prototype),"onPointDragging",this).call(this,t);return n&&this.options.editable&&this.emit(e.DrawEvent.Dragging,n,this.getData()),n}},{key:"onPointDragEnd",value:function(t){var n=zt(Lt(r.prototype),"onPointDragEnd",this).call(this,t);return n&&this.options.editable&&(this.setHelper("pointHover"),this.emit(e.DrawEvent.DragEnd,n,this.getData()),this.emit(e.DrawEvent.Edit,n,this.getData())),n}},{key:"bindThis",value:function(){zt(Lt(r.prototype),"bindThis",this).call(this),this.bindPointRenderEvent=this.bindPointRenderEvent.bind(this)}},{key:"onSceneMouseMove",value:function(e){}},{key:"setActiveFeature",value:function(e){var t=this.getTargetFeature(e);this.setPointData((function(e){return e.map((function(e){return e.properties.isActive=Il(t,e),e}))}))}},{key:"resetFeatures",value:function(){this.setPointData((function(e){return e.map((function(e){return e.properties=Et(Et({},e.properties),{},{isDrag:!1,isActive:!1,isHover:!1}),e}))}))}}]),r}(Xl),cu=function(t){At(r,t);var n=Dt(r);function r(t,a){var i;return Ct(this,r),(i=n.call(this,t,a)).drawPolygonFinish=function(){var t,n=i.drawPolygon,r=null!==(t=null==n?void 0:n.properties.nodes)&&void 0!==t?t:[];if(n&&r.length>=3){n.properties.isDraw=!1,i.syncPolygonNodes(n,r),i.setActivePolygon(n);var a=i.options,o=a.autoActive,s=a.editable;o&&s||i.handlePolygonUnClick(n),i.setHelper(s?o?"pointHover":"polygonHover":i.addable?"draw":null),i.emit(e.DrawEvent.Add,n,i.getPolygonData())}},i.sceneRender.on(e.RenderEvent.DblClick,i.drawPolygonFinish),i.bindPointRenderEvent(),i.bindSceneEvent(),i.bindMidPointRenderEvent(),i.bindLineRenderEvent(),i.bindPolygonRenderEvent(),i}return Mt(r,[{key:"getDefaultOptions",value:function(e){return Et(Et({},zt(Lt(r.prototype),"getDefaultOptions",this).call(this,e)),{},{liveUpdate:!1})}},{key:"setData",value:function(e){var t=e.map((function(e){var t,n;if(e.properties=Et(Et({},Sl()),null!==(t=e.properties)&&void 0!==t?t:{}),!(null===(n=e.properties.nodes)||void 0===n?void 0:n.length)){var r=dn(e);r=r.slice(0,r.length-1),e.properties.nodes=r.map((function(e){return El(e)}))}if(!e.properties.line){var a=e.properties.nodes;e.properties.line=Cl([].concat(Bt(a),[El(yl(a).geometry.coordinates)]))}return e}));this.source.setData({point:[],midPoint:[],dashLine:[],polygon:t,line:t.map((function(e){return e.properties.line}))}),this.setTextData(this.getAllTexts()),this.editPolygon&&this.setActivePolygon(this.editPolygon)}},{key:"onPointCreate",value:function(t){if(this.addable&&!this.dragPoint){var n=zt(Lt(r.prototype),"onPointCreate",this).call(this,t),a=this.drawPolygon,i=this.drawLine;return n&&(a?(this.syncPolygonNodes(a,[].concat(Bt(a.properties.nodes),[n])),this.setDashLineData([kl([Rl(t),a.properties.nodes[0].geometry.coordinates])]),a.properties.nodes.length>1&&this.setHelper("drawFinish")):i&&(this.handleCreatePolygon([n],i),this.setHelper("drawContinue")),this.emit(e.DrawEvent.AddNode,n,a,this.getPolygonData())),n}}},{key:"onPointClick",value:function(e){var t=this,n=this.drawPolygon,r=e.feature;if(n){var a=n.properties.nodes;if(a.length<3||!Il(yl(a),r)&&!Il(Yl(a),r)){var i=Ft(r.geometry.coordinates,2);e.lngLat={lng:i[0],lat:i[1]},this.onPointCreate(e)}else requestAnimationFrame((function(){t.drawPolygonFinish()}))}}},{key:"onPointDragging",value:function(e){var t=this.dragPoint,n=this.editPolygon;if(t&&n){var a=n.properties.line;a.properties.nodes=a.properties.nodes.map((function(e){return Il(e,t)?t:e}));var i=a.properties.nodes,o=i.slice(0,i.length-1),s=yl(i),l=Yl(i),u=Il(s,t)||Il(l,t);if(u&&(s.geometry.coordinates=l.geometry.coordinates=Rl(e)),this.options.adsorbOptions&&u){var c=this.resetAdsorbLngLat(e);c&&(s.geometry.coordinates=l.geometry.coordinates=c)}zt(Lt(r.prototype),"onPointDragging",this).call(this,e),this.syncPolygonNodes(n,o),this.setActivePolygon(n)}return t}},{key:"onLineDragging",value:function(t){var n=this.dragPolygon,a=zt(Lt(r.prototype),"onLineDragging",this).call(this,t);if(a&&n){var i=a.properties.nodes;this.syncPolygonNodes(n,i.slice(0,i.length-1)),this.emit(e.DrawEvent.Dragging,n,this.getPolygonData())}return a}},{key:"onMidPointClick",value:function(t){var n=zt(Lt(r.prototype),"onMidPointClick",this).call(this,t),a=this.editPolygon;return n&&a&&(this.emit(e.DrawEvent.Edit,a,this.getPolygonData()),this.emit(e.DrawEvent.AddNode,n,a,this.getPolygonData())),n}},{key:"onSceneMouseMove",value:function(e){var t,n=this.drawPolygon,r=null!==(t=null==n?void 0:n.properties.nodes)&&void 0!==t?t:[];if(n&&r.length){this.options.adsorbOptions&&this.resetAdsorbLngLat(e);var a=Rl(e),i=[];if(i.push(kl([a,yl(r).geometry.coordinates])),r.length>1&&i.push(kl([a,Yl(r).geometry.coordinates])),this.options.liveUpdate&&r.length>=2){var o=dn(Kt(r));n.geometry.coordinates=[[].concat(Bt(o),[a,o[0]])],this.setPolygonData(this.getPolygonData())}this.setDashLineData(i),this.setTextData(this.getAllTexts())}}},{key:"removeNode",value:function(t,n){var r,a=this.getTargetFeature(n),i=this.getTargetFeature(t,null!==(r=null==a?void 0:a.properties.nodes)&&void 0!==r?r:[]);if(a&&i){var o,s=null!==(o=null==a?void 0:a.properties.nodes)&&void 0!==o?o:[];if(4>s.length)return;this.syncPolygonNodes(a,s.filter((function(e){return!Il(i,e)}))),this.emit(e.DrawEvent.RemoveNode,i,a,this.getLineData()),this.emit(e.DrawEvent.Edit,a,this.getPolygonData())}}},{key:"onPointContextMenu",value:function(e){var t,n=this.editPolygon,r=e.feature,a=null!==(t=null==n?void 0:n.properties.nodes)&&void 0!==t?t:[];if(n&&a.length>=4)return a.find((function(e){return Il(e,r)}))||(r=a[0]),this.removeNode(r,n),r}},{key:"bindPointRenderEvent",value:function(){var t;zt(Lt(r.prototype),"bindPointRenderEvent",this).call(this),null===(t=this.pointRender)||void 0===t||t.on(e.RenderEvent.Contextmenu,this.onPointContextMenu.bind(this))}},{key:"enablePointRenderAction",value:function(){var e;zt(Lt(r.prototype),"enablePointRenderAction",this).call(this),this.options.editable&&(null===(e=this.pointRender)||void 0===e||e.enableContextMenu())}},{key:"disablePointRenderAction",value:function(){var e;zt(Lt(r.prototype),"disablePointRenderAction",this).call(this),null===(e=this.pointRender)||void 0===e||e.disableContextMenu()}}]),r}(iu),du=function(t){At(r,t);var n=Dt(r);function r(e,t){var a;return Ct(this,r),(a=n.call(this,e,t)).bindPointRenderEvent(),a.bindSceneEvent(),a.bindMidPointRenderEvent(),a.bindLineRenderEvent(),a.bindPolygonRenderEvent(),a}return Mt(r,[{key:"getDefaultOptions",value:function(e){var t=zt(Lt(r.prototype),"getDefaultOptions",this).call(this,e);return t.helper&&(t.helper=Et(Et({},t.helper),nu)),t}},{key:"setData",value:function(e){var t=this,n=e.map((function(e){var n,r,a;e.properties=Et(Et({},Sl()),null!==(n=e.properties)&&void 0!==n?n:{});var i=e.properties.nodes;if(2!==(null===(r=i)||void 0===r?void 0:r.length)){var o=Ft(xn(e),4),s=o[2],l=o[3];i=[El([o[0],o[1]]),El([s,l])],e.properties.nodes=i}var u=Ft(i,2),c=u[0],d=u[1],p=!!(null===(a=e.properties)||void 0===a?void 0:a.isActive),h=e.properties.line;return h||(h=t.handleCreatePolygonLine(c,d,{isActive:p}),e.properties.line=h),t.handleCreatePolygon([c,d],h,Et(Et({},e.properties),{},{isActive:p}))}));this.source.setData({point:[],midPoint:[],dashLine:[],polygon:n,line:n.map((function(e){return e.properties.line}))}),this.setTextData(this.getAllTexts()),this.editPolygon&&this.setActivePolygon(this.editPolygon)}},{key:"handleCreatePolygonLine",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=dn(gr(Kt([e,t]))).map((function(n,r){return 0===r?e:2===r?t:El(n)}));return Cl(r,n)}},{key:"syncPolygonNodes",value:function(e,t){var n=e.properties.line,r=dn(gr(Kt(t)));e.properties.nodes=t,e.geometry.coordinates=[r],this.setPolygonData((function(t){return t.map((function(t){return Il(t,e)?e:t}))})),this.setPointData(e.properties.isDraw?[t[0]]:t);var a=n.properties.nodes,i=r.filter((function(e){return!Us(e,t[0].geometry.coordinates)&&!Us(e,t[1].geometry.coordinates)}));return a.forEach((function(e,n){var r=[0,0];switch(n){case 0:r=t[0].geometry.coordinates;break;case 1:r=i[0];break;case 2:r=t[1].geometry.coordinates;break;case 3:r=i[1];break;case 4:r=Is(t[0].geometry.coordinates)}e.geometry.coordinates=r})),n.geometry.coordinates=r,e}},{key:"onLineDragging",value:function(t){var n=zt(Lt(r.prototype),"onLineDragging",this).call(this,t),a=this.dragPolygon;if(n&&a){var i=a.properties.line.properties.nodes;this.syncPolygonNodes(a,[i[0],i[2]]),this.setActivePolygon(a,{isDrag:!0}),this.emit(e.DrawEvent.Dragging,a,this.getPolygonData())}return n}}]),r}(ou),pu=function(e,t){for(var n=e;n&&!Array.from(n.classList).includes(t);)n=n.parentElement;return n},hu={point:"#l7draw-point",line:"#l7draw-line",polygon:"#l7draw-polygon",rect:"#l7draw-rect",circle:"#l7draw-circle",clear:"#l7draw-qingkong"},fu={point:uu,line:lu,polygon:cu,rect:du,circle:su},vu="data-draw-type",mu="l7-draw-control",gu="".concat(mu,"__btn"),yu="".concat(gu,"--active");!function(e){var t,n,r,a,i,o='',s=(s=document.getElementsByTagName("script"))[s.length-1].getAttribute("data-injectcss");if(s&&!e.__iconfont__svg__cssinject__){e.__iconfont__svg__cssinject__=!0;try{document.write("")}catch(e){console&&console.log(e)}}function l(){i||(i=!0,r())}t=function(){var e,t=document.createElement("div");t.innerHTML=o,o=null,(t=t.getElementsByTagName("svg")[0])&&(t.setAttribute("aria-hidden","true"),t.style.position="absolute",t.style.width=0,t.style.height=0,t.style.overflow="hidden",(e=document.body).firstChild?function(e,t){t.parentNode.insertBefore(e,t)}(t,e.firstChild):e.appendChild(t))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(t,0):(n=function(){document.removeEventListener("DOMContentLoaded",n,!1),t()},document.addEventListener("DOMContentLoaded",n,!1)):document.attachEvent&&(r=t,a=e.document,i=!1,function e(){try{a.documentElement.doScroll("left")}catch(t){return void setTimeout(e,50)}l()}(),a.onreadystatechange=function(){"complete"==a.readyState&&(a.onreadystatechange=null,l())})}(window),Vl(".l7-draw-control{display:flex;overflow:hidden;background:#fff;border-radius:2px}.l7-draw-control__btn{display:inline-flex;align-items:center;justify-content:center;width:30px;height:30px;padding:0;text-align:center;background:transparent;border-width:0;border-right:1px solid #e0e0e0;outline:0;cursor:pointer}.l7-draw-control__btn:hover{background-color:#e5e5e5}.l7-draw-control__btn:last-child{border-bottom:0}.l7-draw-control__btn .l7-draw-icon{width:26px;height:26px;overflow:hidden;fill:currentColor}.l7-draw-control__btn--active svg{color:#0370fe}");var xu=function(n){At(a,n);var r=Dt(a);function a(t){var n,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return Ct(this,a),(n=r.call(this,i)).controlOption=void 0,n.sceneInstance=void 0,n.drawMap={},n.btnMap={},n.activeType=null,n.emitDataChange=xa((function(){n.emit(e.ControlEvent.DataChange,n.getDrawData())}),16),n.sceneInstance=t,n.controlOption=Et(Et({},n.getDefault()),i||{}),n.onBtnClick=n.onBtnClick.bind(Ot(n)),n}return Mt(a,[{key:"getActiveType",value:function(){return this.activeType}},{key:"getDefault",value:function(){return Et(Et({},zt(Lt(a.prototype),"getDefault",this).call(this)),{},{className:"",buttonClassName:"",activeButtonClassName:"",style:"",position:"topleft",commonDrawOptions:{},drawConfig:{point:!0,line:!0,polygon:!0,rect:!0,circle:!0,clear:!0}})}},{key:"addTo",value:function(e){return zt(Lt(a.prototype),"addTo",this).call(this,e),this.init(),this}},{key:"onAdd",value:function(){var e=this.controlOption,n=e.className,r=e.style,a=t.DOM.create("div","".concat(mu," ").concat(n));return r&&a.setAttribute("style",r),a}},{key:"onRemove",value:function(){Object.values(this.drawMap).forEach((function(e){e.clear(!0)}))}},{key:"init",value:function(){var t,n=this,r=[];Object.entries(this.controlOption.drawConfig).forEach((function(t){var a=Ft(t,2),i=a[0],o=a[1];if(o){var s=n.initBtn(i);s.addEventListener("click",n.onBtnClick),r.push(s),n.btnMap[i]=s;var l=fu[i];if(l&&n.sceneInstance){var u=new l(n.sceneInstance,Et(Et({},n.controlOption.commonDrawOptions),"boolean"==typeof o?{}:o));u.on(e.DrawEvent.Change,n.emitDataChange),n.drawMap[i]=u}}})),(t=this.container).append.apply(t,r),this.controlOption.defaultActiveType&&this.onDrawClick(this.controlOption.defaultActiveType)}},{key:"getDrawData",value:function(){return _s(ml(this.drawMap).map((function(e){var t=Ft(e,2);return[t[0],t[1].getData()]})))}},{key:"getTypeDraw",value:function(e){var t;return null!==(t=this.drawMap[e])&&void 0!==t?t:null}},{key:"onBtnClick",value:function(e){var t=pu(e.target,gu);if(t){var n=t.getAttribute(vu);"clear"===n?this.clearDrawData():this.onDrawClick(n)}}},{key:"setActiveType",value:function(n){var r=null,a=this.activeType;if(a){var i,o=this.btnMap[a];if(o){t.DOM.removeClass(o,yu);var s=this.controlOption.activeButtonClassName;s&&t.DOM.removeClass(o,s)}null===(i=this.drawMap[a])||void 0===i||i.disable(),r=null}if(a!==n&&n){var l;null===(l=this.drawMap[n])||void 0===l||l.enable();var u=this.btnMap[n];u&&t.DOM.addClass(u,"".concat(yu," ").concat(this.controlOption.activeButtonClassName)),r=n}this.activeType=r,this.emit(e.ControlEvent.DrawChange,r)}},{key:"onDrawClick",value:function(e){this.setActiveType(e)}},{key:"clearDrawData",value:function(){Object.values(this.drawMap).forEach((function(e){null==e||e.clear()}))}},{key:"initBtn",value:function(e){var n=t.DOM.create("button","".concat(gu," ").concat(this.controlOption.buttonClassName));return n.innerHTML=''),n.setAttribute(vu,e),n}}]),a}(t.Control);e.ACTIVE_COLOR=Ma,e.BaseMode=Wl,e.CircleDrawer=su,e.DEFAULT_ADSORB_CONFIG=wt,e.DEFAULT_AREA_OPTIONS=xt,e.DEFAULT_COMMON_OPTIONS=Ta,e.DEFAULT_CURSOR_MAP=r,e.DEFAULT_DISTANCE_OPTIONS=yt,e.DEFAULT_HISTORY_CONFIG=It,e.DEFAULT_KEYBOARD_CONFIG=_t,e.DEFAULT_MID_POINT_STYLE=Pa,e.DEFAULT_NODE_NORMAL_STYLE=La,e.DEFAULT_NODE_STYLE=Ra,e.DEFAULT_POINT_NORMAL_STYLE=Aa,e.DEFAULT_POINT_STYLE=Oa,e.DEFAULT_POPUP_CONFIG=bt,e.DEFAULT_SOURCE_DATA=a,e.DEFAULT_STYLE=Na,e.DEFAULT_TEXT_NORMAL_STYLE=Da,e.DashLineRender=Hr,e.DragPolygonMode=ou,e.DrawCircle=su,e.DrawControl=xu,e.DrawLine=lu,e.DrawPoint=uu,e.DrawPolygon=cu,e.DrawRect=du,e.LayerRender=Vr,e.LineDrawer=lu,e.LineMode=au,e.LineRender=Ia,e.MidPointMode=Kl,e.MidPointRender=_a,e.NORMAL_COLOR=ka,e.PointDrawer=uu,e.PointMode=Xl,e.PointRender=ba,e.PolygonDrawer=cu,e.PolygonMode=iu,e.PolygonRender=wa,e.RENDER_MAP=Ca,e.RectDrawer=du,e.SceneRender=Sa,e.Source=ql,e.TextRender=Ea,e.calcAreaText=Ll,e.calcDistanceTextsByLine=Al,e.createDashLine=kl,e.createLineFeature=Cl,e.createPointFeature=El,e.createPolygonFeature=Ml,e.findMinIndex=Nl,e.getAdsorbFeature=Fl,e.getAdsorbLine=jl,e.getAdsorbPoint=Bl,e.getDefaultLineProperties=wl,e.getDefaultPointProperties=bl,e.getDefaultPolygonProperties=Sl,e.getLineCenterPoint=Tl,e.getLngLat=Ol,e.getMapDom=Pl,e.getParentByClassName=pu,e.getPosition=Rl,e.getUuid=xl,e.isDev=!1,e.isSameFeature=Il,e.resetEventLngLat=Zl,e.splitByPosition=zl,e.transLngLat2Position=Dl,e.updateTargetFeature=_l,Object.defineProperty(e,"__esModule",{value:!0})}(t,n(11696))},72502:function(e,t,n){"use strict";n.d(t,{Dg:function(){return u},lh:function(){return s},m$:function(){return i},vs:function(){return l},zu:function(){return o}});var r=n(61876),a=n(15730);function i(e,t,n){var a=[0,0,0,0,0,0,0,0,0];return r.vc(a,n),r.Jp(e,a,t)}function o(e,t,n){var a=[0,0,0,0,0,0,0,0,0];return r.Us(a,n),r.Jp(e,a,t)}function s(e,t,n){var a=[0,0,0,0,0,0,0,0,0];return r.xJ(a,n),r.Jp(e,a,t)}function l(e,t){for(var n,a,l,u=e?[].concat(e):[1,0,0,0,1,0,0,0,1],c=0,d=t.length;c=0;return n?i?2*Math.PI-r:r:i?r:2*Math.PI-r}},45958:function(e,t,n){"use strict";n.d(t,{e9:function(){return l},Wq:function(){return A},tr:function(){return p},wb:function(){return v},zx:function(){return b}});var r=n(83677),a=/[MLHVQTCSAZ]([^MLHVQTCSAZ]*)/gi,i=/[^\s\,]+/gi;var o=function(e){var t=e||[];return(0,r.kJ)(t)?t:(0,r.HD)(t)?(t=t.match(a),(0,r.S6)(t,(function(e,n){if((e=e.match(i))[0].length>1){var a=e[0].charAt(0);e.splice(1,0,e[0].substr(1)),e[0]=a}(0,r.S6)(e,(function(t,n){isNaN(t)||(e[n]=+t)})),t[n]=e})),t):void 0},s=n(15730);var l=function(e,t,n){void 0===t&&(t=!1),void 0===n&&(n=[[0,0],[1,1]]);for(var r=!!t,a=[],i=0,o=e.length;i2&&(n.push([r].concat(i.splice(0,2))),o="l",r="m"===r?"l":"L"),"o"===o&&1===i.length&&n.push([r,i[0]]),"r"===o)n.push([r].concat(i));else for(;i.length>=t[o]&&(n.push([r].concat(i.splice(0,t[o]))),t[o]););return""})),n}var h=/[a-z]/;function f(e,t){return[t[0]+(t[0]-e[0]),t[1]+(t[1]-e[1])]}function v(e){var t=p(e);if(!t||!t.length)return[["M",0,0]];for(var n=!1,r=0;r=0){n=!0;break}}if(!n)return t;var i=[],o=0,s=0,l=0,u=0,c=0,d=t[0];"M"!==d[0]&&"m"!==d[0]||(l=o=+d[1],u=s=+d[2],c++,i[0]=["M",o,s]);r=c;for(var v=t.length;r1&&(n*=Math.sqrt(f),a*=Math.sqrt(f));var v=n*n*(h*h)+a*a*(p*p),m=v?Math.sqrt((n*n*(a*a)-v)/v):1;o===s&&(m*=-1),isNaN(m)&&(m=0);var I=a?m*n*h/a:0,_=n?m*-a*p/n:0,b=(l+c)/2+Math.cos(i)*I-Math.sin(i)*_,w=(u+d)/2+Math.sin(i)*I+Math.cos(i)*_,S=[(p-I)/n,(h-_)/a],E=[(-1*p-I)/n,(-1*h-_)/a],C=y([1,0],S),k=y(S,E);return g(S,E)<=-1&&(k=Math.PI),g(S,E)>=1&&(k=0),0===s&&k>0&&(k-=2*Math.PI),1===s&&k<0&&(k+=2*Math.PI),{cx:b,cy:w,rx:x(e,[c,d])?0:n,ry:x(e,[c,d])?0:a,startAngle:C,endAngle:C+k,xRotation:i,arcFlag:o,sweepFlag:s}}function _(e,t){return[t[0]+(t[0]-e[0]),t[1]+(t[1]-e[1])]}function b(e){for(var t=[],n=null,r=null,a=null,i=0,s=(e=o(e)).length,l=0;l0!=w(s[1]-n)>0&&w(t-(n-o[1])*(o[0]-s[0])/(o[1]-s[1])-o[0])<0&&(r=!r)}return r}var C=function(e,t,n){return e>=t&&e<=n};function k(e){for(var t=[],n=e.length,r=0;r1){var o=e[0],s=e[n-1];t.push({from:{x:s[0],y:s[1]},to:{x:o[0],y:o[1]}})}return t}function M(e,t){var n=!1;return(0,r.S6)(e,(function(e){if(function(e,t,n,r){var a=n.x-e.x,i=n.y-e.y,o=t.x-e.x,s=t.y-e.y,l=r.x-n.x,u=r.y-n.y,c=o*u-s*l,d=null;if(c*c>.001*(o*o+s*s)*(l*l+u*u)){var p=(a*u-i*l)/c,h=(a*s-i*o)/c;C(p,0,1)&&C(h,0,1)&&(d={x:e.x+p*o,y:e.y+p*s})}return d}(e.from,e.to,t.from,t.to))return n=!0,!1})),n}function T(e){var t=e.map((function(e){return e[0]})),n=e.map((function(e){return e[1]}));return{minX:Math.min.apply(null,t),maxX:Math.max.apply(null,t),minY:Math.min.apply(null,n),maxY:Math.max.apply(null,n)}}function A(e,t){if(e.length<2||t.length<2)return!1;var n,a,i=T(e),o=T(t);if(n=i,(a=o).minX>n.maxX||a.maxXn.maxY||a.maxY-1},i=function(e,t){if(!r(e))return e;for(var n=[],a=0;an?n:e},Z=function(e,t){var n=t.toString(),r=n.indexOf(".");if(-1===r)return Math.round(e);var a=n.substr(r+1).length;return a>20&&(a=20),parseFloat(e.toFixed(a))},U=function(e){return l(e,"Number")};Number.isInteger&&Number.isInteger;function V(e,t,n){return void 0===n&&(n=1e-5),Math.abs(e-t)t?(r&&(clearTimeout(r),r=null),s=u,o=e.apply(a,i),r||(a=i=null)):r||!1===n.trailing||(r=setTimeout(l,c)),o};return u.cancel=function(){clearTimeout(r),s=0,r=a=i=null},u},Le=function(e){return r(e)?Array.prototype.slice.call(e):[]},Pe={},Oe=function(e){return Pe[e=e||"g"]?Pe[e]+=1:Pe[e]=1,e+Pe[e]},Re=function(){};function De(e){return c(e)?0:r(e)?e.length:Object.keys(e).length}var Ne,ze=n(5163),Fe=he((function(e,t){void 0===t&&(t={});var n=t.fontSize,r=t.fontFamily,a=t.fontWeight,i=t.fontStyle,o=t.fontVariant;return Ne||(Ne=document.createElement("canvas").getContext("2d")),Ne.font=[i,o,a,n+"px",r].join(" "),Ne.measureText(T(e)?e:"").width}),(function(e,t){return void 0===t&&(t={}),(0,ze.pr)([e],Y(t)).join("")})),Be=function(e,t,n,r){void 0===r&&(r="...");var a,i,o=Fe(r,n),s=T(e)?e:X(e),l=t,u=[];if(Fe(e,n)<=t)return e;for(;a=s.substr(0,16),!((i=Fe(a,n))+o>l&&i>l);)if(u.push(a),l-=i,!(s=s.substr(16)))return u.join("");for(;a=s.substr(0,1),!((i=Fe(a,n))+o>l);)if(u.push(a),l-=i,!(s=s.substr(1)))return u.join("");return""+u.join("")+r},je=function(){function e(){this.map={}}return e.prototype.has=function(e){return void 0!==this.map[e]},e.prototype.get=function(e,t){var n=this.map[e];return void 0===n?t:n},e.prototype.set=function(e,t){this.map[e]=t},e.prototype.clear=function(){this.map={}},e.prototype.delete=function(e){delete this.map[e]},e.prototype.size=function(){return Object.keys(this.map).length},e}()},23997:function(e,t,n){"use strict";n.d(t,{T6:function(){return h},VD:function(){return f},WE:function(){return u},Yt:function(){return v},lC:function(){return i},py:function(){return l},rW:function(){return a},s:function(){return d},ve:function(){return s},vq:function(){return c}});var r=n(44705);function a(e,t,n){return{r:255*(0,r.sh)(e,255),g:255*(0,r.sh)(t,255),b:255*(0,r.sh)(n,255)}}function i(e,t,n){e=(0,r.sh)(e,255),t=(0,r.sh)(t,255),n=(0,r.sh)(n,255);var a=Math.max(e,t,n),i=Math.min(e,t,n),o=0,s=0,l=(a+i)/2;if(a===i)s=0,o=0;else{var u=a-i;switch(s=l>.5?u/(2-a-i):u/(a+i),a){case e:o=(t-n)/u+(t1&&(n-=1),n<1/6?e+6*n*(t-e):n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function s(e,t,n){var a,i,s;if(e=(0,r.sh)(e,360),t=(0,r.sh)(t,100),n=(0,r.sh)(n,100),0===t)i=n,s=n,a=n;else{var l=n<.5?n*(1+t):n+t-n*t,u=2*n-l;a=o(u,l,e+1/3),i=o(u,l,e),s=o(u,l,e-1/3)}return{r:255*a,g:255*i,b:255*s}}function l(e,t,n){e=(0,r.sh)(e,255),t=(0,r.sh)(t,255),n=(0,r.sh)(n,255);var a=Math.max(e,t,n),i=Math.min(e,t,n),o=0,s=a,l=a-i,u=0===a?0:l/a;if(a===i)o=0;else{switch(a){case e:o=(t-n)/l+(t>16,g:(65280&e)>>8,b:255&e}}},8182:function(e,t,n){"use strict";n.d(t,{R:function(){return r}});var r={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",goldenrod:"#daa520",gold:"#ffd700",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavenderblush:"#fff0f5",lavender:"#e6e6fa",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"}},34633:function(e,t,n){"use strict";n.d(t,{uA:function(){return o}});var r=n(23997),a=n(8182),i=n(44705);function o(e){var t={r:0,g:0,b:0},n=1,o=null,s=null,l=null,u=!1,p=!1;return"string"==typeof e&&(e=function(e){if(e=e.trim().toLowerCase(),0===e.length)return!1;var t=!1;if(a.R[e])e=a.R[e],t=!0;else if("transparent"===e)return{r:0,g:0,b:0,a:0,format:"name"};var n=c.rgb.exec(e);if(n)return{r:n[1],g:n[2],b:n[3]};if(n=c.rgba.exec(e),n)return{r:n[1],g:n[2],b:n[3],a:n[4]};if(n=c.hsl.exec(e),n)return{h:n[1],s:n[2],l:n[3]};if(n=c.hsla.exec(e),n)return{h:n[1],s:n[2],l:n[3],a:n[4]};if(n=c.hsv.exec(e),n)return{h:n[1],s:n[2],v:n[3]};if(n=c.hsva.exec(e),n)return{h:n[1],s:n[2],v:n[3],a:n[4]};if(n=c.hex8.exec(e),n)return{r:(0,r.VD)(n[1]),g:(0,r.VD)(n[2]),b:(0,r.VD)(n[3]),a:(0,r.T6)(n[4]),format:t?"name":"hex8"};if(n=c.hex6.exec(e),n)return{r:(0,r.VD)(n[1]),g:(0,r.VD)(n[2]),b:(0,r.VD)(n[3]),format:t?"name":"hex"};if(n=c.hex4.exec(e),n)return{r:(0,r.VD)(n[1]+n[1]),g:(0,r.VD)(n[2]+n[2]),b:(0,r.VD)(n[3]+n[3]),a:(0,r.T6)(n[4]+n[4]),format:t?"name":"hex8"};if(n=c.hex3.exec(e),n)return{r:(0,r.VD)(n[1]+n[1]),g:(0,r.VD)(n[2]+n[2]),b:(0,r.VD)(n[3]+n[3]),format:t?"name":"hex"};return!1}(e)),"object"==typeof e&&(d(e.r)&&d(e.g)&&d(e.b)?(t=(0,r.rW)(e.r,e.g,e.b),u=!0,p="%"===String(e.r).substr(-1)?"prgb":"rgb"):d(e.h)&&d(e.s)&&d(e.v)?(o=(0,i.JX)(e.s),s=(0,i.JX)(e.v),t=(0,r.WE)(e.h,o,s),u=!0,p="hsv"):d(e.h)&&d(e.s)&&d(e.l)&&(o=(0,i.JX)(e.s),l=(0,i.JX)(e.l),t=(0,r.ve)(e.h,o,l),u=!0,p="hsl"),Object.prototype.hasOwnProperty.call(e,"a")&&(n=e.a)),n=(0,i.Yq)(n),{ok:u,format:e.format||p,r:Math.min(255,Math.max(t.r,0)),g:Math.min(255,Math.max(t.g,0)),b:Math.min(255,Math.max(t.b,0)),a:n}}var s="(?:".concat("[-\\+]?\\d*\\.\\d+%?",")|(?:").concat("[-\\+]?\\d+%?",")"),l="[\\s|\\(]+(".concat(s,")[,|\\s]+(").concat(s,")[,|\\s]+(").concat(s,")\\s*\\)?"),u="[\\s|\\(]+(".concat(s,")[,|\\s]+(").concat(s,")[,|\\s]+(").concat(s,")[,|\\s]+(").concat(s,")\\s*\\)?"),c={CSS_UNIT:new RegExp(s),rgb:new RegExp("rgb"+l),rgba:new RegExp("rgba"+u),hsl:new RegExp("hsl"+l),hsla:new RegExp("hsla"+u),hsv:new RegExp("hsv"+l),hsva:new RegExp("hsva"+u),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/};function d(e){return Boolean(c.CSS_UNIT.exec(String(e)))}},44705:function(e,t,n){"use strict";function r(e,t){(function(e){return"string"==typeof e&&-1!==e.indexOf(".")&&1===parseFloat(e)})(e)&&(e="100%");var n=function(e){return"string"==typeof e&&-1!==e.indexOf("%")}(e);return e=360===t?e:Math.min(t,Math.max(0,parseFloat(e))),n&&(e=parseInt(String(e*t),10)/100),Math.abs(e-t)<1e-6?1:e=360===t?(e<0?e%t+t:e%t)/parseFloat(String(t)):e%t/parseFloat(String(t))}function a(e){return Math.min(1,Math.max(0,e))}function i(e){return e=parseFloat(e),(isNaN(e)||e<0||e>1)&&(e=1),e}function o(e){return e<=1?"".concat(100*Number(e),"%"):e}function s(e){return 1===e.length?"0"+e:String(e)}n.d(t,{FZ:function(){return s},JX:function(){return o},V2:function(){return a},Yq:function(){return i},sh:function(){return r}})},73731:function(e,t,n){"use strict";n.d(t,{kG:function(){return r}});function r(e,t,n){if(void 0===n&&(n=Error),!e)throw new n(t)}},75413:function(e,t,n){"use strict";function r(e,t){var n=t&&t.cache?t.cache:c,r=t&&t.serializer?t.serializer:l;return(t&&t.strategy?t.strategy:s)(e,{cache:n,serializer:r})}function a(e,t,n,r){var a,i=null==(a=r)||"number"==typeof a||"boolean"==typeof a?r:n(r),o=t.get(i);return void 0===o&&(o=e.call(this,r),t.set(i,o)),o}function i(e,t,n){var r=Array.prototype.slice.call(arguments,3),a=n(r),i=t.get(a);return void 0===i&&(i=e.apply(this,r),t.set(a,i)),i}function o(e,t,n,r,a){return n.bind(t,e,r,a)}function s(e,t){return o(e,this,1===e.length?a:i,t.cache.create(),t.serializer)}n.d(t,{A:function(){return d},Z:function(){return r}});var l=function(){return JSON.stringify(arguments)};function u(){this.cache=Object.create(null)}u.prototype.get=function(e){return this.cache[e]},u.prototype.set=function(e,t){this.cache[e]=t};var c={create:function(){return new u}},d={variadic:function(e,t){return o(e,this,i,t.cache.create(),t.serializer)},monadic:function(e,t){return o(e,this,a,t.cache.create(),t.serializer)}}},82614:function(e,t,n){"use strict";n.d(t,{wD:function(){return a},VG:function(){return l},rp:function(){return c},Ii:function(){return g},O4:function(){return s},uf:function(){return u},Wh:function(){return m},Jo:function(){return h},yx:function(){return f},Wi:function(){return p},HI:function(){return v},pe:function(){return d},Qc:function(){return ie}});var r,a,i,o=n(5163);function s(e){return e.type===a.literal}function l(e){return e.type===a.argument}function u(e){return e.type===a.number}function c(e){return e.type===a.date}function d(e){return e.type===a.time}function p(e){return e.type===a.select}function h(e){return e.type===a.plural}function f(e){return e.type===a.pound}function v(e){return e.type===a.tag}function m(e){return!(!e||"object"!=typeof e||e.type!==i.number)}function g(e){return!(!e||"object"!=typeof e||e.type!==i.dateTime)}!function(e){e[e.EXPECT_ARGUMENT_CLOSING_BRACE=1]="EXPECT_ARGUMENT_CLOSING_BRACE",e[e.EMPTY_ARGUMENT=2]="EMPTY_ARGUMENT",e[e.MALFORMED_ARGUMENT=3]="MALFORMED_ARGUMENT",e[e.EXPECT_ARGUMENT_TYPE=4]="EXPECT_ARGUMENT_TYPE",e[e.INVALID_ARGUMENT_TYPE=5]="INVALID_ARGUMENT_TYPE",e[e.EXPECT_ARGUMENT_STYLE=6]="EXPECT_ARGUMENT_STYLE",e[e.INVALID_NUMBER_SKELETON=7]="INVALID_NUMBER_SKELETON",e[e.INVALID_DATE_TIME_SKELETON=8]="INVALID_DATE_TIME_SKELETON",e[e.EXPECT_NUMBER_SKELETON=9]="EXPECT_NUMBER_SKELETON",e[e.EXPECT_DATE_TIME_SKELETON=10]="EXPECT_DATE_TIME_SKELETON",e[e.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE=11]="UNCLOSED_QUOTE_IN_ARGUMENT_STYLE",e[e.EXPECT_SELECT_ARGUMENT_OPTIONS=12]="EXPECT_SELECT_ARGUMENT_OPTIONS",e[e.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE=13]="EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE",e[e.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE=14]="INVALID_PLURAL_ARGUMENT_OFFSET_VALUE",e[e.EXPECT_SELECT_ARGUMENT_SELECTOR=15]="EXPECT_SELECT_ARGUMENT_SELECTOR",e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR=16]="EXPECT_PLURAL_ARGUMENT_SELECTOR",e[e.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT=17]="EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT",e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT=18]="EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT",e[e.INVALID_PLURAL_ARGUMENT_SELECTOR=19]="INVALID_PLURAL_ARGUMENT_SELECTOR",e[e.DUPLICATE_PLURAL_ARGUMENT_SELECTOR=20]="DUPLICATE_PLURAL_ARGUMENT_SELECTOR",e[e.DUPLICATE_SELECT_ARGUMENT_SELECTOR=21]="DUPLICATE_SELECT_ARGUMENT_SELECTOR",e[e.MISSING_OTHER_CLAUSE=22]="MISSING_OTHER_CLAUSE",e[e.INVALID_TAG=23]="INVALID_TAG",e[e.INVALID_TAG_NAME=25]="INVALID_TAG_NAME",e[e.UNMATCHED_CLOSING_TAG=26]="UNMATCHED_CLOSING_TAG",e[e.UNCLOSED_TAG=27]="UNCLOSED_TAG"}(r||(r={})),function(e){e[e.literal=0]="literal",e[e.argument=1]="argument",e[e.number=2]="number",e[e.date=3]="date",e[e.time=4]="time",e[e.select=5]="select",e[e.plural=6]="plural",e[e.pound=7]="pound",e[e.tag=8]="tag"}(a||(a={})),function(e){e[e.number=0]="number",e[e.dateTime=1]="dateTime"}(i||(i={}));var y=/[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/,x=/(?:[Eec]{1,6}|G{1,5}|[Qq]{1,5}|(?:[yYur]+|U{1,5})|[ML]{1,5}|d{1,2}|D{1,3}|F{1}|[abB]{1,5}|[hkHK]{1,2}|w{1,2}|W{1}|m{1,2}|s{1,2}|[zZOvVxX]{1,4})(?=([^']*'[^']*')*[^']*$)/g;function I(e){var t={};return e.replace(x,(function(e){var n=e.length;switch(e[0]){case"G":t.era=4===n?"long":5===n?"narrow":"short";break;case"y":t.year=2===n?"2-digit":"numeric";break;case"Y":case"u":case"U":case"r":throw new RangeError("`Y/u/U/r` (year) patterns are not supported, use `y` instead");case"q":case"Q":throw new RangeError("`q/Q` (quarter) patterns are not supported");case"M":case"L":t.month=["numeric","2-digit","short","long","narrow"][n-1];break;case"w":case"W":throw new RangeError("`w/W` (week) patterns are not supported");case"d":t.day=["numeric","2-digit"][n-1];break;case"D":case"F":case"g":throw new RangeError("`D/F/g` (day) patterns are not supported, use `d` instead");case"E":t.weekday=4===n?"short":5===n?"narrow":"short";break;case"e":if(n<4)throw new RangeError("`e..eee` (weekday) patterns are not supported");t.weekday=["short","long","narrow","short"][n-4];break;case"c":if(n<4)throw new RangeError("`c..ccc` (weekday) patterns are not supported");t.weekday=["short","long","narrow","short"][n-4];break;case"a":t.hour12=!0;break;case"b":case"B":throw new RangeError("`b/B` (period) patterns are not supported, use `a` instead");case"h":t.hourCycle="h12",t.hour=["numeric","2-digit"][n-1];break;case"H":t.hourCycle="h23",t.hour=["numeric","2-digit"][n-1];break;case"K":t.hourCycle="h11",t.hour=["numeric","2-digit"][n-1];break;case"k":t.hourCycle="h24",t.hour=["numeric","2-digit"][n-1];break;case"j":case"J":case"C":throw new RangeError("`j/J/C` (hour) patterns are not supported, use `h/H/K/k` instead");case"m":t.minute=["numeric","2-digit"][n-1];break;case"s":t.second=["numeric","2-digit"][n-1];break;case"S":case"A":throw new RangeError("`S/A` (second) patterns are not supported, use `s` instead");case"z":t.timeZoneName=n<4?"short":"long";break;case"Z":case"O":case"v":case"V":case"X":case"x":throw new RangeError("`Z/O/v/V/X/x` (timeZone) patterns are not supported, use `z` instead")}return""})),t}var _=/[\t-\r \x85\u200E\u200F\u2028\u2029]/i;var b=/^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g,w=/^(@+)?(\+|#+)?[rs]?$/g,S=/(\*)(0+)|(#+)(0+)|(0+)/g,E=/^(0+)$/;function C(e){var t={};return"r"===e[e.length-1]?t.roundingPriority="morePrecision":"s"===e[e.length-1]&&(t.roundingPriority="lessPrecision"),e.replace(w,(function(e,n,r){return"string"!=typeof r?(t.minimumSignificantDigits=n.length,t.maximumSignificantDigits=n.length):"+"===r?t.minimumSignificantDigits=n.length:"#"===n[0]?t.maximumSignificantDigits=n.length:(t.minimumSignificantDigits=n.length,t.maximumSignificantDigits=n.length+("string"==typeof r?r.length:0)),""})),t}function k(e){switch(e){case"sign-auto":return{signDisplay:"auto"};case"sign-accounting":case"()":return{currencySign:"accounting"};case"sign-always":case"+!":return{signDisplay:"always"};case"sign-accounting-always":case"()!":return{signDisplay:"always",currencySign:"accounting"};case"sign-except-zero":case"+?":return{signDisplay:"exceptZero"};case"sign-accounting-except-zero":case"()?":return{signDisplay:"exceptZero",currencySign:"accounting"};case"sign-never":case"+_":return{signDisplay:"never"}}}function M(e){var t;if("E"===e[0]&&"E"===e[1]?(t={notation:"engineering"},e=e.slice(2)):"E"===e[0]&&(t={notation:"scientific"},e=e.slice(1)),t){var n=e.slice(0,2);if("+!"===n?(t.signDisplay="always",e=e.slice(2)):"+?"===n&&(t.signDisplay="exceptZero",e=e.slice(2)),!E.test(e))throw new Error("Malformed concise eng/scientific notation");t.minimumIntegerDigits=e.length}return t}function T(e){var t=k(e);return t||{}}function A(e){for(var t={},n=0,r=e;n1)throw new RangeError("integer-width stems only accept a single optional option");a.options[0].replace(S,(function(e,n,r,a,i,o){if(n)t.minimumIntegerDigits=r.length;else{if(a&&i)throw new Error("We currently do not support maximum integer digits");if(o)throw new Error("We currently do not support exact integer digits")}return""}));continue}if(E.test(a.stem))t.minimumIntegerDigits=a.stem.length;else if(b.test(a.stem)){if(a.options.length>1)throw new RangeError("Fraction-precision stems only accept a single optional option");a.stem.replace(b,(function(e,n,r,a,i,o){return"*"===r?t.minimumFractionDigits=n.length:a&&"#"===a[0]?t.maximumFractionDigits=a.length:i&&o?(t.minimumFractionDigits=i.length,t.maximumFractionDigits=i.length+o.length):(t.minimumFractionDigits=n.length,t.maximumFractionDigits=n.length),""}));var i=a.options[0];"w"===i?t=(0,o.pi)((0,o.pi)({},t),{trailingZeroDisplay:"stripIfInteger"}):i&&(t=(0,o.pi)((0,o.pi)({},t),C(i)))}else if(w.test(a.stem))t=(0,o.pi)((0,o.pi)({},t),C(a.stem));else{var s=k(a.stem);s&&(t=(0,o.pi)((0,o.pi)({},t),s));var l=M(a.stem);l&&(t=(0,o.pi)((0,o.pi)({},t),l))}}return t}var L,P={AX:["H"],BQ:["H"],CP:["H"],CZ:["H"],DK:["H"],FI:["H"],ID:["H"],IS:["H"],ML:["H"],NE:["H"],RU:["H"],SE:["H"],SJ:["H"],SK:["H"],AS:["h","H"],BT:["h","H"],DJ:["h","H"],ER:["h","H"],GH:["h","H"],IN:["h","H"],LS:["h","H"],PG:["h","H"],PW:["h","H"],SO:["h","H"],TO:["h","H"],VU:["h","H"],WS:["h","H"],"001":["H","h"],AL:["h","H","hB"],TD:["h","H","hB"],"ca-ES":["H","h","hB"],CF:["H","h","hB"],CM:["H","h","hB"],"fr-CA":["H","h","hB"],"gl-ES":["H","h","hB"],"it-CH":["H","h","hB"],"it-IT":["H","h","hB"],LU:["H","h","hB"],NP:["H","h","hB"],PF:["H","h","hB"],SC:["H","h","hB"],SM:["H","h","hB"],SN:["H","h","hB"],TF:["H","h","hB"],VA:["H","h","hB"],CY:["h","H","hb","hB"],GR:["h","H","hb","hB"],CO:["h","H","hB","hb"],DO:["h","H","hB","hb"],KP:["h","H","hB","hb"],KR:["h","H","hB","hb"],NA:["h","H","hB","hb"],PA:["h","H","hB","hb"],PR:["h","H","hB","hb"],VE:["h","H","hB","hb"],AC:["H","h","hb","hB"],AI:["H","h","hb","hB"],BW:["H","h","hb","hB"],BZ:["H","h","hb","hB"],CC:["H","h","hb","hB"],CK:["H","h","hb","hB"],CX:["H","h","hb","hB"],DG:["H","h","hb","hB"],FK:["H","h","hb","hB"],GB:["H","h","hb","hB"],GG:["H","h","hb","hB"],GI:["H","h","hb","hB"],IE:["H","h","hb","hB"],IM:["H","h","hb","hB"],IO:["H","h","hb","hB"],JE:["H","h","hb","hB"],LT:["H","h","hb","hB"],MK:["H","h","hb","hB"],MN:["H","h","hb","hB"],MS:["H","h","hb","hB"],NF:["H","h","hb","hB"],NG:["H","h","hb","hB"],NR:["H","h","hb","hB"],NU:["H","h","hb","hB"],PN:["H","h","hb","hB"],SH:["H","h","hb","hB"],SX:["H","h","hb","hB"],TA:["H","h","hb","hB"],ZA:["H","h","hb","hB"],"af-ZA":["H","h","hB","hb"],AR:["H","h","hB","hb"],CL:["H","h","hB","hb"],CR:["H","h","hB","hb"],CU:["H","h","hB","hb"],EA:["H","h","hB","hb"],"es-BO":["H","h","hB","hb"],"es-BR":["H","h","hB","hb"],"es-EC":["H","h","hB","hb"],"es-ES":["H","h","hB","hb"],"es-GQ":["H","h","hB","hb"],"es-PE":["H","h","hB","hb"],GT:["H","h","hB","hb"],HN:["H","h","hB","hb"],IC:["H","h","hB","hb"],KG:["H","h","hB","hb"],KM:["H","h","hB","hb"],LK:["H","h","hB","hb"],MA:["H","h","hB","hb"],MX:["H","h","hB","hb"],NI:["H","h","hB","hb"],PY:["H","h","hB","hb"],SV:["H","h","hB","hb"],UY:["H","h","hB","hb"],JP:["H","h","K"],AD:["H","hB"],AM:["H","hB"],AO:["H","hB"],AT:["H","hB"],AW:["H","hB"],BE:["H","hB"],BF:["H","hB"],BJ:["H","hB"],BL:["H","hB"],BR:["H","hB"],CG:["H","hB"],CI:["H","hB"],CV:["H","hB"],DE:["H","hB"],EE:["H","hB"],FR:["H","hB"],GA:["H","hB"],GF:["H","hB"],GN:["H","hB"],GP:["H","hB"],GW:["H","hB"],HR:["H","hB"],IL:["H","hB"],IT:["H","hB"],KZ:["H","hB"],MC:["H","hB"],MD:["H","hB"],MF:["H","hB"],MQ:["H","hB"],MZ:["H","hB"],NC:["H","hB"],NL:["H","hB"],PM:["H","hB"],PT:["H","hB"],RE:["H","hB"],RO:["H","hB"],SI:["H","hB"],SR:["H","hB"],ST:["H","hB"],TG:["H","hB"],TR:["H","hB"],WF:["H","hB"],YT:["H","hB"],BD:["h","hB","H"],PK:["h","hB","H"],AZ:["H","hB","h"],BA:["H","hB","h"],BG:["H","hB","h"],CH:["H","hB","h"],GE:["H","hB","h"],LI:["H","hB","h"],ME:["H","hB","h"],RS:["H","hB","h"],UA:["H","hB","h"],UZ:["H","hB","h"],XK:["H","hB","h"],AG:["h","hb","H","hB"],AU:["h","hb","H","hB"],BB:["h","hb","H","hB"],BM:["h","hb","H","hB"],BS:["h","hb","H","hB"],CA:["h","hb","H","hB"],DM:["h","hb","H","hB"],"en-001":["h","hb","H","hB"],FJ:["h","hb","H","hB"],FM:["h","hb","H","hB"],GD:["h","hb","H","hB"],GM:["h","hb","H","hB"],GU:["h","hb","H","hB"],GY:["h","hb","H","hB"],JM:["h","hb","H","hB"],KI:["h","hb","H","hB"],KN:["h","hb","H","hB"],KY:["h","hb","H","hB"],LC:["h","hb","H","hB"],LR:["h","hb","H","hB"],MH:["h","hb","H","hB"],MP:["h","hb","H","hB"],MW:["h","hb","H","hB"],NZ:["h","hb","H","hB"],SB:["h","hb","H","hB"],SG:["h","hb","H","hB"],SL:["h","hb","H","hB"],SS:["h","hb","H","hB"],SZ:["h","hb","H","hB"],TC:["h","hb","H","hB"],TT:["h","hb","H","hB"],UM:["h","hb","H","hB"],US:["h","hb","H","hB"],VC:["h","hb","H","hB"],VG:["h","hb","H","hB"],VI:["h","hb","H","hB"],ZM:["h","hb","H","hB"],BO:["H","hB","h","hb"],EC:["H","hB","h","hb"],ES:["H","hB","h","hb"],GQ:["H","hB","h","hb"],PE:["H","hB","h","hb"],AE:["h","hB","hb","H"],"ar-001":["h","hB","hb","H"],BH:["h","hB","hb","H"],DZ:["h","hB","hb","H"],EG:["h","hB","hb","H"],EH:["h","hB","hb","H"],HK:["h","hB","hb","H"],IQ:["h","hB","hb","H"],JO:["h","hB","hb","H"],KW:["h","hB","hb","H"],LB:["h","hB","hb","H"],LY:["h","hB","hb","H"],MO:["h","hB","hb","H"],MR:["h","hB","hb","H"],OM:["h","hB","hb","H"],PH:["h","hB","hb","H"],PS:["h","hB","hb","H"],QA:["h","hB","hb","H"],SA:["h","hB","hb","H"],SD:["h","hB","hb","H"],SY:["h","hB","hb","H"],TN:["h","hB","hb","H"],YE:["h","hB","hb","H"],AF:["H","hb","hB","h"],LA:["H","hb","hB","h"],CN:["H","hB","hb","h"],LV:["H","hB","hb","h"],TL:["H","hB","hb","h"],"zu-ZA":["H","hB","hb","h"],CD:["hB","H"],IR:["hB","H"],"hi-IN":["hB","h","H"],"kn-IN":["hB","h","H"],"ml-IN":["hB","h","H"],"te-IN":["hB","h","H"],KH:["hB","h","H","hb"],"ta-IN":["hB","h","hb","H"],BN:["hb","hB","h","H"],MY:["hb","hB","h","H"],ET:["hB","hb","h","H"],"gu-IN":["hB","hb","h","H"],"mr-IN":["hB","hb","h","H"],"pa-IN":["hB","hb","h","H"],TW:["hB","hb","h","H"],KE:["hB","hb","H","h"],MM:["hB","hb","H","h"],TZ:["hB","hb","H","h"],UG:["hB","hb","H","h"]};function O(e){var t=e.hourCycle;if(void 0===t&&e.hourCycles&&e.hourCycles.length&&(t=e.hourCycles[0]),t)switch(t){case"h24":return"k";case"h23":return"H";case"h12":return"h";case"h11":return"K";default:throw new Error("Invalid hourCycle")}var n,r=e.language;return"root"!==r&&(n=e.maximize().region),(P[n||""]||P[r||""]||P["".concat(r,"-001")]||P["001"])[0]}var R=new RegExp("^".concat(y.source,"*")),D=new RegExp("".concat(y.source,"*$"));function N(e,t){return{start:e,end:t}}var z=!!String.prototype.startsWith,F=!!String.fromCodePoint,B=!!Object.fromEntries,j=!!String.prototype.codePointAt,Z=!!String.prototype.trimStart,U=!!String.prototype.trimEnd,V=!!Number.isSafeInteger?Number.isSafeInteger:function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e&&Math.abs(e)<=9007199254740991},H=!0;try{H="a"===(null===(L=$("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu").exec("a"))||void 0===L?void 0:L[0])}catch(e){H=!1}var G,q=z?function(e,t,n){return e.startsWith(t,n)}:function(e,t,n){return e.slice(n,n+t.length)===t},W=F?String.fromCodePoint:function(){for(var e=[],t=0;ti;){if((n=e[i++])>1114111)throw RangeError(n+" is not a valid code point");r+=n<65536?String.fromCharCode(n):String.fromCharCode(55296+((n-=65536)>>10),n%1024+56320)}return r},Y=B?Object.fromEntries:function(e){for(var t={},n=0,r=e;n=n)){var r,a=e.charCodeAt(t);return a<55296||a>56319||t+1===n||(r=e.charCodeAt(t+1))<56320||r>57343?a:r-56320+(a-55296<<10)+65536}},K=Z?function(e){return e.trimStart()}:function(e){return e.replace(R,"")},J=U?function(e){return e.trimEnd()}:function(e){return e.replace(D,"")};function $(e,t){return new RegExp(e,t)}if(H){var Q=$("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");G=function(e,t){var n;return Q.lastIndex=t,null!==(n=Q.exec(e)[1])&&void 0!==n?n:""}}else G=function(e,t){for(var n=[];;){var r=X(e,t);if(void 0===r||ne(r)||re(r))break;n.push(r),t+=r>=65536?2:1}return W.apply(void 0,n)};var ee=function(){function e(e,t){void 0===t&&(t={}),this.message=e,this.position={offset:0,line:1,column:1},this.ignoreTag=!!t.ignoreTag,this.locale=t.locale,this.requiresOtherClause=!!t.requiresOtherClause,this.shouldParseSkeletons=!!t.shouldParseSkeletons}return e.prototype.parse=function(){if(0!==this.offset())throw Error("parser can only be used once");return this.parseMessage(0,"",!1)},e.prototype.parseMessage=function(e,t,n){for(var i=[];!this.isEOF();){var o=this.char();if(123===o){if((s=this.parseArgument(e,n)).err)return s;i.push(s.val)}else{if(125===o&&e>0)break;if(35!==o||"plural"!==t&&"selectordinal"!==t){if(60===o&&!this.ignoreTag&&47===this.peek()){if(n)break;return this.error(r.UNMATCHED_CLOSING_TAG,N(this.clonePosition(),this.clonePosition()))}if(60===o&&!this.ignoreTag&&te(this.peek()||0)){if((s=this.parseTag(e,t)).err)return s;i.push(s.val)}else{var s;if((s=this.parseLiteral(e,t)).err)return s;i.push(s.val)}}else{var l=this.clonePosition();this.bump(),i.push({type:a.pound,location:N(l,this.clonePosition())})}}}return{val:i,err:null}},e.prototype.parseTag=function(e,t){var n=this.clonePosition();this.bump();var i=this.parseTagName();if(this.bumpSpace(),this.bumpIf("/>"))return{val:{type:a.literal,value:"<".concat(i,"/>"),location:N(n,this.clonePosition())},err:null};if(this.bumpIf(">")){var o=this.parseMessage(e+1,t,!0);if(o.err)return o;var s=o.val,l=this.clonePosition();if(this.bumpIf("")?{val:{type:a.tag,value:i,children:s,location:N(n,this.clonePosition())},err:null}:this.error(r.INVALID_TAG,N(l,this.clonePosition())))}return this.error(r.UNCLOSED_TAG,N(n,this.clonePosition()))}return this.error(r.INVALID_TAG,N(n,this.clonePosition()))},e.prototype.parseTagName=function(){var e,t=this.offset();for(this.bump();!this.isEOF()&&(45===(e=this.char())||46===e||e>=48&&e<=57||95===e||e>=97&&e<=122||e>=65&&e<=90||183==e||e>=192&&e<=214||e>=216&&e<=246||e>=248&&e<=893||e>=895&&e<=8191||e>=8204&&e<=8205||e>=8255&&e<=8256||e>=8304&&e<=8591||e>=11264&&e<=12271||e>=12289&&e<=55295||e>=63744&&e<=64975||e>=65008&&e<=65533||e>=65536&&e<=983039);)this.bump();return this.message.slice(t,this.offset())},e.prototype.parseLiteral=function(e,t){for(var n=this.clonePosition(),r="";;){var i=this.tryParseQuote(t);if(i)r+=i;else{var o=this.tryParseUnquoted(e,t);if(o)r+=o;else{var s=this.tryParseLeftAngleBracket();if(!s)break;r+=s}}}var l=N(n,this.clonePosition());return{val:{type:a.literal,value:r,location:l},err:null}},e.prototype.tryParseLeftAngleBracket=function(){return this.isEOF()||60!==this.char()||!this.ignoreTag&&(te(e=this.peek()||0)||47===e)?null:(this.bump(),"<");var e},e.prototype.tryParseQuote=function(e){if(this.isEOF()||39!==this.char())return null;switch(this.peek()){case 39:return this.bump(),this.bump(),"'";case 123:case 60:case 62:case 125:break;case 35:if("plural"===e||"selectordinal"===e)break;return null;default:return null}this.bump();var t=[this.char()];for(this.bump();!this.isEOF();){var n=this.char();if(39===n){if(39!==this.peek()){this.bump();break}t.push(39),this.bump()}else t.push(n);this.bump()}return W.apply(void 0,t)},e.prototype.tryParseUnquoted=function(e,t){if(this.isEOF())return null;var n=this.char();return 60===n||123===n||35===n&&("plural"===t||"selectordinal"===t)||125===n&&e>0?null:(this.bump(),W(n))},e.prototype.parseArgument=function(e,t){var n=this.clonePosition();if(this.bump(),this.bumpSpace(),this.isEOF())return this.error(r.EXPECT_ARGUMENT_CLOSING_BRACE,N(n,this.clonePosition()));if(125===this.char())return this.bump(),this.error(r.EMPTY_ARGUMENT,N(n,this.clonePosition()));var i=this.parseIdentifierIfPossible().value;if(!i)return this.error(r.MALFORMED_ARGUMENT,N(n,this.clonePosition()));if(this.bumpSpace(),this.isEOF())return this.error(r.EXPECT_ARGUMENT_CLOSING_BRACE,N(n,this.clonePosition()));switch(this.char()){case 125:return this.bump(),{val:{type:a.argument,value:i,location:N(n,this.clonePosition())},err:null};case 44:return this.bump(),this.bumpSpace(),this.isEOF()?this.error(r.EXPECT_ARGUMENT_CLOSING_BRACE,N(n,this.clonePosition())):this.parseArgumentOptions(e,t,i,n);default:return this.error(r.MALFORMED_ARGUMENT,N(n,this.clonePosition()))}},e.prototype.parseIdentifierIfPossible=function(){var e=this.clonePosition(),t=this.offset(),n=G(this.message,t),r=t+n.length;return this.bumpTo(r),{value:n,location:N(e,this.clonePosition())}},e.prototype.parseArgumentOptions=function(e,t,n,s){var l,u=this.clonePosition(),c=this.parseIdentifierIfPossible().value,d=this.clonePosition();switch(c){case"":return this.error(r.EXPECT_ARGUMENT_TYPE,N(u,d));case"number":case"date":case"time":this.bumpSpace();var p=null;if(this.bumpIf(",")){this.bumpSpace();var h=this.clonePosition();if((b=this.parseSimpleArgStyleIfPossible()).err)return b;if(0===(g=J(b.val)).length)return this.error(r.EXPECT_ARGUMENT_STYLE,N(this.clonePosition(),this.clonePosition()));p={style:g,styleLocation:N(h,this.clonePosition())}}if((w=this.tryParseArgumentClose(s)).err)return w;var f=N(s,this.clonePosition());if(p&&q(null==p?void 0:p.style,"::",0)){var v=K(p.style.slice(2));if("number"===c)return(b=this.parseNumberSkeletonFromString(v,p.styleLocation)).err?b:{val:{type:a.number,value:n,location:f,style:b.val},err:null};if(0===v.length)return this.error(r.EXPECT_DATE_TIME_SKELETON,f);var m=v;this.locale&&(m=function(e,t){for(var n="",r=0;r>1),l=O(t);for("H"!=l&&"k"!=l||(s=0);s-- >0;)n+="a";for(;o-- >0;)n=l+n}else n+="J"===a?"H":a}return n}(v,this.locale));var g={type:i.dateTime,pattern:m,location:p.styleLocation,parsedOptions:this.shouldParseSkeletons?I(m):{}};return{val:{type:"date"===c?a.date:a.time,value:n,location:f,style:g},err:null}}return{val:{type:"number"===c?a.number:"date"===c?a.date:a.time,value:n,location:f,style:null!==(l=null==p?void 0:p.style)&&void 0!==l?l:null},err:null};case"plural":case"selectordinal":case"select":var y=this.clonePosition();if(this.bumpSpace(),!this.bumpIf(","))return this.error(r.EXPECT_SELECT_ARGUMENT_OPTIONS,N(y,(0,o.pi)({},y)));this.bumpSpace();var x=this.parseIdentifierIfPossible(),_=0;if("select"!==c&&"offset"===x.value){if(!this.bumpIf(":"))return this.error(r.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,N(this.clonePosition(),this.clonePosition()));var b;if(this.bumpSpace(),(b=this.tryParseDecimalInteger(r.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,r.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE)).err)return b;this.bumpSpace(),x=this.parseIdentifierIfPossible(),_=b.val}var w,S=this.tryParsePluralOrSelectOptions(e,c,t,x);if(S.err)return S;if((w=this.tryParseArgumentClose(s)).err)return w;var E=N(s,this.clonePosition());return"select"===c?{val:{type:a.select,value:n,options:Y(S.val),location:E},err:null}:{val:{type:a.plural,value:n,options:Y(S.val),offset:_,pluralType:"plural"===c?"cardinal":"ordinal",location:E},err:null};default:return this.error(r.INVALID_ARGUMENT_TYPE,N(u,d))}},e.prototype.tryParseArgumentClose=function(e){return this.isEOF()||125!==this.char()?this.error(r.EXPECT_ARGUMENT_CLOSING_BRACE,N(e,this.clonePosition())):(this.bump(),{val:!0,err:null})},e.prototype.parseSimpleArgStyleIfPossible=function(){for(var e=0,t=this.clonePosition();!this.isEOF();){switch(this.char()){case 39:this.bump();var n=this.clonePosition();if(!this.bumpUntil("'"))return this.error(r.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE,N(n,this.clonePosition()));this.bump();break;case 123:e+=1,this.bump();break;case 125:if(!(e>0))return{val:this.message.slice(t.offset,this.offset()),err:null};e-=1;break;default:this.bump()}}return{val:this.message.slice(t.offset,this.offset()),err:null}},e.prototype.parseNumberSkeletonFromString=function(e,t){var n=[];try{n=function(e){if(0===e.length)throw new Error("Number skeleton cannot be empty");for(var t=[],n=0,r=e.split(_).filter((function(e){return e.length>0}));n=48&&o<=57))break;a=!0,i=10*i+(o-48),this.bump()}var s=N(r,this.clonePosition());return a?V(i*=n)?{val:i,err:null}:this.error(t,s):this.error(e,s)},e.prototype.offset=function(){return this.position.offset},e.prototype.isEOF=function(){return this.offset()===this.message.length},e.prototype.clonePosition=function(){return{offset:this.position.offset,line:this.position.line,column:this.position.column}},e.prototype.char=function(){var e=this.position.offset;if(e>=this.message.length)throw Error("out of bound");var t=X(this.message,e);if(void 0===t)throw Error("Offset ".concat(e," is at invalid UTF-16 code unit boundary"));return t},e.prototype.error=function(e,t){return{val:null,err:{kind:e,message:this.message,location:t}}},e.prototype.bump=function(){if(!this.isEOF()){var e=this.char();10===e?(this.position.line+=1,this.position.column=1,this.position.offset+=1):(this.position.column+=1,this.position.offset+=e<65536?1:2)}},e.prototype.bumpIf=function(e){if(q(this.message,e,this.offset())){for(var t=0;t=0?(this.bumpTo(n),!0):(this.bumpTo(this.message.length),!1)},e.prototype.bumpTo=function(e){if(this.offset()>e)throw Error("targetOffset ".concat(e," must be greater than or equal to the current offset ").concat(this.offset()));for(e=Math.min(e,this.message.length);;){var t=this.offset();if(t===e)break;if(t>e)throw Error("targetOffset ".concat(e," is at invalid UTF-16 code unit boundary"));if(this.bump(),this.isEOF())break}},e.prototype.bumpSpace=function(){for(;!this.isEOF()&&ne(this.char());)this.bump()},e.prototype.peek=function(){if(this.isEOF())return null;var e=this.char(),t=this.offset(),n=this.message.charCodeAt(t+(e>=65536?2:1));return null!=n?n:null},e}();function te(e){return e>=97&&e<=122||e>=65&&e<=90}function ne(e){return e>=9&&e<=13||32===e||133===e||e>=8206&&e<=8207||8232===e||8233===e}function re(e){return e>=33&&e<=35||36===e||e>=37&&e<=39||40===e||41===e||42===e||43===e||44===e||45===e||e>=46&&e<=47||e>=58&&e<=59||e>=60&&e<=62||e>=63&&e<=64||91===e||92===e||93===e||94===e||96===e||123===e||124===e||125===e||126===e||161===e||e>=162&&e<=165||166===e||167===e||169===e||171===e||172===e||174===e||176===e||177===e||182===e||187===e||191===e||215===e||247===e||e>=8208&&e<=8213||e>=8214&&e<=8215||8216===e||8217===e||8218===e||e>=8219&&e<=8220||8221===e||8222===e||8223===e||e>=8224&&e<=8231||e>=8240&&e<=8248||8249===e||8250===e||e>=8251&&e<=8254||e>=8257&&e<=8259||8260===e||8261===e||8262===e||e>=8263&&e<=8273||8274===e||8275===e||e>=8277&&e<=8286||e>=8592&&e<=8596||e>=8597&&e<=8601||e>=8602&&e<=8603||e>=8604&&e<=8607||8608===e||e>=8609&&e<=8610||8611===e||e>=8612&&e<=8613||8614===e||e>=8615&&e<=8621||8622===e||e>=8623&&e<=8653||e>=8654&&e<=8655||e>=8656&&e<=8657||8658===e||8659===e||8660===e||e>=8661&&e<=8691||e>=8692&&e<=8959||e>=8960&&e<=8967||8968===e||8969===e||8970===e||8971===e||e>=8972&&e<=8991||e>=8992&&e<=8993||e>=8994&&e<=9e3||9001===e||9002===e||e>=9003&&e<=9083||9084===e||e>=9085&&e<=9114||e>=9115&&e<=9139||e>=9140&&e<=9179||e>=9180&&e<=9185||e>=9186&&e<=9254||e>=9255&&e<=9279||e>=9280&&e<=9290||e>=9291&&e<=9311||e>=9472&&e<=9654||9655===e||e>=9656&&e<=9664||9665===e||e>=9666&&e<=9719||e>=9720&&e<=9727||e>=9728&&e<=9838||9839===e||e>=9840&&e<=10087||10088===e||10089===e||10090===e||10091===e||10092===e||10093===e||10094===e||10095===e||10096===e||10097===e||10098===e||10099===e||10100===e||10101===e||e>=10132&&e<=10175||e>=10176&&e<=10180||10181===e||10182===e||e>=10183&&e<=10213||10214===e||10215===e||10216===e||10217===e||10218===e||10219===e||10220===e||10221===e||10222===e||10223===e||e>=10224&&e<=10239||e>=10240&&e<=10495||e>=10496&&e<=10626||10627===e||10628===e||10629===e||10630===e||10631===e||10632===e||10633===e||10634===e||10635===e||10636===e||10637===e||10638===e||10639===e||10640===e||10641===e||10642===e||10643===e||10644===e||10645===e||10646===e||10647===e||10648===e||e>=10649&&e<=10711||10712===e||10713===e||10714===e||10715===e||e>=10716&&e<=10747||10748===e||10749===e||e>=10750&&e<=11007||e>=11008&&e<=11055||e>=11056&&e<=11076||e>=11077&&e<=11078||e>=11079&&e<=11084||e>=11085&&e<=11123||e>=11124&&e<=11125||e>=11126&&e<=11157||11158===e||e>=11159&&e<=11263||e>=11776&&e<=11777||11778===e||11779===e||11780===e||11781===e||e>=11782&&e<=11784||11785===e||11786===e||11787===e||11788===e||11789===e||e>=11790&&e<=11798||11799===e||e>=11800&&e<=11801||11802===e||11803===e||11804===e||11805===e||e>=11806&&e<=11807||11808===e||11809===e||11810===e||11811===e||11812===e||11813===e||11814===e||11815===e||11816===e||11817===e||e>=11818&&e<=11822||11823===e||e>=11824&&e<=11833||e>=11834&&e<=11835||e>=11836&&e<=11839||11840===e||11841===e||11842===e||e>=11843&&e<=11855||e>=11856&&e<=11857||11858===e||e>=11859&&e<=11903||e>=12289&&e<=12291||12296===e||12297===e||12298===e||12299===e||12300===e||12301===e||12302===e||12303===e||12304===e||12305===e||e>=12306&&e<=12307||12308===e||12309===e||12310===e||12311===e||12312===e||12313===e||12314===e||12315===e||12316===e||12317===e||e>=12318&&e<=12319||12320===e||12336===e||64830===e||64831===e||e>=65093&&e<=65094}function ae(e){e.forEach((function(e){if(delete e.location,p(e)||h(e))for(var t in e.options)delete e.options[t].location,ae(e.options[t].value);else u(e)&&m(e.style)||(c(e)||d(e))&&g(e.style)?delete e.style.location:v(e)&&ae(e.children)}))}function ie(e,t){void 0===t&&(t={}),t=(0,o.pi)({shouldParseSkeletons:!0,requiresOtherClause:!0},t);var n=new ee(e,t).parse();if(n.err){var a=SyntaxError(r[n.err.kind]);throw a.location=n.err.location,a.originalMessage=n.err.message,a}return(null==t?void 0:t.captureLocation)||ae(n.val),n.val}},40283:function(e,t,n){"use strict";n.d(t,{$6:function(){return d},OV:function(){return s},Qe:function(){return u},Rw:function(){return i},X9:function(){return c},bc:function(){return r},gb:function(){return l},wI:function(){return o}});var r,a=n(5163);!function(e){e.FORMAT_ERROR="FORMAT_ERROR",e.UNSUPPORTED_FORMATTER="UNSUPPORTED_FORMATTER",e.INVALID_CONFIG="INVALID_CONFIG",e.MISSING_DATA="MISSING_DATA",e.MISSING_TRANSLATION="MISSING_TRANSLATION"}(r||(r={}));var i=function(e){function t(n,r,a){var i=this,o=a?a instanceof Error?a:new Error(String(a)):void 0;return(i=e.call(this,"[@formatjs/intl Error ".concat(n,"] ").concat(r,"\n").concat(o?"\n".concat(o.message,"\n").concat(o.stack):""))||this).code=n,"function"==typeof Error.captureStackTrace&&Error.captureStackTrace(i,t),i}return(0,a.ZT)(t,e),t}(Error),o=function(e){function t(t,n){return e.call(this,r.UNSUPPORTED_FORMATTER,t,n)||this}return(0,a.ZT)(t,e),t}(i),s=function(e){function t(t,n){return e.call(this,r.INVALID_CONFIG,t,n)||this}return(0,a.ZT)(t,e),t}(i),l=function(e){function t(t,n){return e.call(this,r.MISSING_DATA,t,n)||this}return(0,a.ZT)(t,e),t}(i),u=function(e){function t(t,n,a){return e.call(this,r.FORMAT_ERROR,"".concat(t,"\nLocale: ").concat(n,"\n"),a)||this}return(0,a.ZT)(t,e),t}(i),c=function(e){function t(t,n,r,a){var i=e.call(this,"".concat(t,"\nMessageID: ").concat(null==r?void 0:r.id,"\nDefault Message: ").concat(null==r?void 0:r.defaultMessage,"\nDescription: ").concat(null==r?void 0:r.description,"\n"),n,a)||this;return i.descriptor=r,i}return(0,a.ZT)(t,e),t}(u),d=function(e){function t(t,n){var a=e.call(this,r.MISSING_TRANSLATION,'Missing message: "'.concat(t.id,'" for locale "').concat(n,'", using ').concat(t.defaultMessage?"default message (".concat("string"==typeof t.defaultMessage?t.defaultMessage:t.defaultMessage.map((function(e){var t;return null!==(t=e.value)&&void 0!==t?t:JSON.stringify(e)})).join(),")"):"id"," as fallback."))||this;return a.descriptor=t,a}return(0,a.ZT)(t,e),t}(i)},32428:function(e,t,n){"use strict";n.d(t,{L6:function(){return s},Sn:function(){return u},TB:function(){return p},Z0:function(){return l},ax:function(){return d}});var r=n(5163),a=n(77481),i=n(75413),o=n(40283);function s(e,t,n){return void 0===n&&(n={}),t.reduce((function(t,r){return r in e?t[r]=e[r]:r in n&&(t[r]=n[r]),t}),{})}var l={formats:{},messages:{},timeZone:void 0,defaultLocale:"en",defaultFormats:{},fallbackOnEmptyString:!0,onError:function(e){0},onWarn:function(e){0}};function u(){return{dateTime:{},number:{},message:{},relativeTime:{},pluralRules:{},list:{},displayNames:{}}}function c(e){return{create:function(){return{get:function(t){return e[t]},set:function(t,n){e[t]=n}}}}}function d(e){void 0===e&&(e={dateTime:{},number:{},message:{},relativeTime:{},pluralRules:{},list:{},displayNames:{}});var t=Intl.RelativeTimeFormat,n=Intl.ListFormat,o=Intl.DisplayNames,s=(0,i.Z)((function(){for(var e,t=[],n=0;n=Math.abs(s)?n-l+s:s-l+n,n=l}n+r>=0!=!!t&&e.reverse()}e.exports=function e(n,r){var a,i=n&&n.type;if("FeatureCollection"===i)for(a=0;a(r=1))return r;for(;ni?n=a:r=a,a=.5*(r-n)+n}return a},t.prototype.solve=function(e,t){return this.sampleCurveY(this.solveCurveX(e,t))}},48816:function(e,t,n){e.exports.VectorTile=n(87634),n(70310),n(62102)},87634:function(e,t,n){"use strict";var r=n(62102);function a(e,t,n){if(3===e){var a=new r(n,n.readVarint()+n.pos);a.length&&(t[a.name]=a)}}e.exports=function(e,t){this.layers=e.readFields(a,{},t)}},70310:function(e,t,n){"use strict";var r=n(4280);function a(e,t,n,r,a){this.properties={},this.extent=n,this.type=0,this._pbf=e,this._geometry=-1,this._keys=r,this._values=a,e.readFields(i,this,t)}function i(e,t,n){1==e?t.id=n.readVarint():2==e?function(e,t){var n=e.readVarint()+e.pos;for(;e.pos>3}if(i--,1===a||2===a)o+=e.readSVarint(),s+=e.readSVarint(),1===a&&(t&&l.push(t),t=[]),t.push(new r(o,s));else{if(7!==a)throw new Error("unknown command "+a);t&&t.push(t[0].clone())}}return t&&l.push(t),l},a.prototype.bbox=function(){var e=this._pbf;e.pos=this._geometry;for(var t=e.readVarint()+e.pos,n=1,r=0,a=0,i=0,o=1/0,s=-1/0,l=1/0,u=-1/0;e.pos>3}if(r--,1===n||2===n)(a+=e.readSVarint())s&&(s=a),(i+=e.readSVarint())u&&(u=i);else if(7!==n)throw new Error("unknown command "+n)}return[o,l,s,u]},a.prototype.toGeoJSON=function(e,t,n){var r,i,s=this.extent*Math.pow(2,n),l=this.extent*e,u=this.extent*t,c=this.loadGeometry(),d=a.types[this.type];function p(e){for(var t=0;t>3;t=1===r?e.readString():2===r?e.readFloat():3===r?e.readDouble():4===r?e.readVarint64():5===r?e.readVarint():6===r?e.readSVarint():7===r?e.readBoolean():null}return t}(n))}e.exports=a,a.prototype.feature=function(e){if(e<0||e>=this._features.length)throw new Error("feature index out of bounds");this._pbf.pos=this._features[e];var t=this._pbf.readVarint()+this._pbf.pos;return new r(this._pbf,t,this.extent,this._keys,this._values)}},17206:function(e,t,n){"use strict";n.d(t,{Z:function(){return x}});var r=n(76854),a=n(41398),i=n(71720),o=n(39588),s=n(16381),l=a.createContext(null),u=n(85942),c=n(63803),d=[];var p=n(13167),h=n(84226);var f="rc-util-locker-".concat(Date.now()),v=0;function m(e){var t=!!e,n=a.useState((function(){return v+=1,"".concat(f,"_").concat(v)})),i=(0,r.Z)(n,1)[0];(0,c.Z)((function(){if(t){var e=(0,h.Z)(),n=document.body.scrollHeight>(window.innerHeight||document.documentElement.clientHeight)&&window.innerWidth>document.body.offsetWidth;(0,p.hq)("\nhtml body {\n overflow-y: hidden;\n ".concat(n?"width: calc(100% - ".concat(e,"px);"):"","\n}"),i)}else(0,p.jL)(i);return function(){(0,p.jL)(i)}}),[t,i])}var g=!1;var y=function(e){return!1!==e&&((0,o.Z)()&&e?"string"==typeof e?document.querySelector(e):"function"==typeof e?e():e:null)};var x=a.forwardRef((function(e,t){var n=e.open,p=e.autoLock,h=e.getContainer,f=(e.debug,e.autoDestroy),v=void 0===f||f,x=e.children,I=a.useState(n),_=(0,r.Z)(I,2),b=_[0],w=_[1],S=b||n;a.useEffect((function(){(v||n)&&w(n)}),[n,v]);var E=a.useState((function(){return y(h)})),C=(0,r.Z)(E,2),k=C[0],M=C[1];a.useEffect((function(){var e=y(h);M(null!=e?e:null)}));var T=function(e,t){var n=a.useState((function(){return(0,o.Z)()?document.createElement("div"):null})),i=(0,r.Z)(n,1)[0],s=a.useRef(!1),p=a.useContext(l),h=a.useState(d),f=(0,r.Z)(h,2),v=f[0],m=f[1],g=p||(s.current?void 0:function(e){m((function(t){return[e].concat((0,u.Z)(t))}))});function y(){i.parentElement||document.body.appendChild(i),s.current=!0}function x(){var e;null===(e=i.parentElement)||void 0===e||e.removeChild(i),s.current=!1}return(0,c.Z)((function(){return e?p?p(y):y():x(),x}),[e]),(0,c.Z)((function(){v.length&&(v.forEach((function(e){return e()})),m(d))}),[v]),[i,g]}(S&&!k),A=(0,r.Z)(T,2),L=A[0],P=A[1],O=null!=k?k:L;m(p&&n&&(0,o.Z)()&&(O===L||O===document.body));var R=null;x&&(0,s.Yr)(x)&&t&&(R=x.ref);var D=(0,s.x1)(R,t);if(!S||!(0,o.Z)()||void 0===k)return null;var N,z=!1===O||("boolean"==typeof N&&(g=N),g),F=x;return t&&(F=a.cloneElement(x,{ref:D})),a.createElement(l.Provider,{value:P},z?F:(0,i.createPortal)(F,O))}))},14091:function(e,t,n){"use strict";n.d(t,{Z:function(){return S}});var r=["angular-cli","create-react-app","html","javascript","node","polymer","typescript","vue"],a={clickToLoad:function(e){return o("ctl",e)},devToolsHeight:function(e){return s("devtoolsheight",e)},forceEmbedLayout:function(e){return o("embed",e)},hideDevTools:function(e){return o("hidedevtools",e)},hideExplorer:function(e){return o("hideExplorer",e)},hideNavigation:function(e){return o("hideNavigation",e)},showSidebar:function(e){return function(e,t){return"boolean"==typeof t?"showSidebar="+(t?"1":"0"):""}(0,e)},openFile:function(e){return function(e,t){return(Array.isArray(t)?t:[t]).filter((function(e){return"string"==typeof e&&""!==e.trim()})).map((function(e){return"file="+encodeURIComponent(e.trim())}))}(0,e).join("&")},terminalHeight:function(e){return s("terminalHeight",e)},theme:function(e){return l("theme",["light","dark"],e)},view:function(e){return l("view",["preview","editor"],e)}};function i(e){void 0===e&&(e={});var t=Object.entries(e).map((function(e){var t=e[0],n=e[1];return null!=n&&a.hasOwnProperty(t)?a[t](n):""})).filter(Boolean);return t.length?"?"+t.join("&"):""}function o(e,t){return!0===t?e+"=1":""}function s(e,t){return"number"==typeof t&&t>=0&&t<=100?e+"="+Math.round(t):""}function l(e,t,n){return"string"==typeof n&&t.includes(n)?e+"="+n:""}function u(){return Math.random().toString(36).slice(2,6)+Math.random().toString(36).slice(2,6)}function c(e,t){return""+p(t)+e+i(t)}function d(e,t){var n={forceEmbedLayout:!0};return t&&"object"==typeof t&&Object.assign(n,t),""+p(n)+e+i(n)}function p(e){return void 0===e&&(e={}),"string"==typeof e.origin?e.origin:"https://stackblitz.com"}function h(e,t,n){if(!t||!e||!e.parentNode)throw new Error("Invalid Element");e.id&&(t.id=e.id),e.className&&(t.className=e.className),function(e,t){t&&"object"==typeof t&&(Object.hasOwnProperty.call(t,"height")&&(e.height=""+t.height),Object.hasOwnProperty.call(t,"width")&&(e.width=""+t.width)),e.height||(e.height="300"),e.width||e.setAttribute("style","width:100%;")}(t,n),e.parentNode.replaceChild(t,e)}function f(e){if("string"==typeof e){var t=document.getElementById(e);if(!t)throw new Error("Could not find element with id '"+e+"'");return t}if(e instanceof HTMLElement)return e;throw new Error("Invalid element: "+e)}function v(e){return e&&!1===e.newWindow?"_self":"_blank"}function m(){return m=Object.assign||function(e){for(var t=1;t=20)return i(),n("Timeout: Unable to establish a connection with the StackBlitz VM"),void x.forEach((function(e,n){e.id===t.id&&x.splice(n,1)}));o++,a()}}),500)})),x.push(this)};function _(e,t){var n=document.createElement("input");return n.type="hidden",n.name=e,n.value=t,n}function b(e){if(!r.includes(e.template)){var t=r.map((function(e){return"'"+e+"'"})).join(", ");console.warn("Unsupported project.template: must be one of "+t)}var n="node"===e.template,a=document.createElement("form");return a.method="POST",a.setAttribute("style","display:none!important;"),a.appendChild(_("project[title]",e.title)),a.appendChild(_("project[description]",e.description)),a.appendChild(_("project[template]",e.template)),e.dependencies&&(n?console.warn("Invalid project.dependencies: dependencies must be provided as a 'package.json' file when using the 'node' template."):a.appendChild(_("project[dependencies]",JSON.stringify(e.dependencies)))),e.settings&&a.appendChild(_("project[settings]",JSON.stringify(e.settings))),Object.keys(e.files).forEach((function(t){"string"==typeof e.files[t]&&a.appendChild(_("project[files]["+t+"]",e.files[t]))})),a}function w(e){var t,n,r,a;return null!=e&&e.contentWindow?(null!=(a=(n=e)instanceof Element?"element":"id",t=null!=(r=x.find((function(e){return e[a]===n})))?r:null)?t:new I(e)).pending:Promise.reject("Provided element is not an iframe.")}var S={connect:w,embedGithubProject:function(e,t,n){var r=f(e),a=document.createElement("iframe");return a.src=d("/github/"+t,n),h(r,a,n),w(a)},embedProject:function(e,t,n){var r,a=f(e),i=function(e,t){var n=b(e);return n.action=d("/run",t),n.id="sb",""+n.outerHTML+" + \ No newline at end of file diff --git a/zh/examples/choropleth/administrative/index.html b/zh/examples/choropleth/administrative/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/choropleth/administrative/index.html +++ b/zh/examples/choropleth/administrative/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/component/control/index.html b/zh/examples/component/control/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/component/control/index.html +++ b/zh/examples/component/control/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/component/marker/index.html b/zh/examples/component/marker/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/component/marker/index.html +++ b/zh/examples/component/marker/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/component/popup/index.html b/zh/examples/component/popup/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/component/popup/index.html +++ b/zh/examples/component/popup/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/draw/basic/index.html b/zh/examples/draw/basic/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/draw/basic/index.html +++ b/zh/examples/draw/basic/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/draw/control/index.html b/zh/examples/draw/control/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/draw/control/index.html +++ b/zh/examples/draw/control/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/earth/arc3d/index.html b/zh/examples/earth/arc3d/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/earth/arc3d/index.html +++ b/zh/examples/earth/arc3d/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/engine/three/index.html b/zh/examples/engine/three/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/engine/three/index.html +++ b/zh/examples/engine/three/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/gallery/animate/index.html b/zh/examples/gallery/animate/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/gallery/animate/index.html +++ b/zh/examples/gallery/animate/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/gallery/basic/index.html b/zh/examples/gallery/basic/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/gallery/basic/index.html +++ b/zh/examples/gallery/basic/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/geometry/geometry/index.html b/zh/examples/geometry/geometry/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/geometry/geometry/index.html +++ b/zh/examples/geometry/geometry/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/heatmap/grid/index.html b/zh/examples/heatmap/grid/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/heatmap/grid/index.html +++ b/zh/examples/heatmap/grid/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/heatmap/heatmap/index.html b/zh/examples/heatmap/heatmap/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/heatmap/heatmap/index.html +++ b/zh/examples/heatmap/heatmap/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/heatmap/hexagon/index.html b/zh/examples/heatmap/hexagon/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/heatmap/hexagon/index.html +++ b/zh/examples/heatmap/hexagon/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/line/animate/index.html b/zh/examples/line/animate/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/line/animate/index.html +++ b/zh/examples/line/animate/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/line/arc/index.html b/zh/examples/line/arc/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/line/arc/index.html +++ b/zh/examples/line/arc/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/line/isoline/index.html b/zh/examples/line/isoline/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/line/isoline/index.html +++ b/zh/examples/line/isoline/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/line/path/index.html b/zh/examples/line/path/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/line/path/index.html +++ b/zh/examples/line/path/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/line/wall/index.html b/zh/examples/line/wall/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/line/wall/index.html +++ b/zh/examples/line/wall/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/point/bubble/index.html b/zh/examples/point/bubble/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/point/bubble/index.html +++ b/zh/examples/point/bubble/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/point/chart/index.html b/zh/examples/point/chart/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/point/chart/index.html +++ b/zh/examples/point/chart/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/point/cluster/index.html b/zh/examples/point/cluster/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/point/cluster/index.html +++ b/zh/examples/point/cluster/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/point/column/index.html b/zh/examples/point/column/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/point/column/index.html +++ b/zh/examples/point/column/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/point/dot/index.html b/zh/examples/point/dot/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/point/dot/index.html +++ b/zh/examples/point/dot/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/point/image/index.html b/zh/examples/point/image/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/point/image/index.html +++ b/zh/examples/point/image/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/point/scatter/index.html b/zh/examples/point/scatter/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/point/scatter/index.html +++ b/zh/examples/point/scatter/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/point/simple/index.html b/zh/examples/point/simple/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/point/simple/index.html +++ b/zh/examples/point/simple/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/point/text/index.html b/zh/examples/point/text/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/point/text/index.html +++ b/zh/examples/point/text/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/polygon/3d/index.html b/zh/examples/polygon/3d/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/polygon/3d/index.html +++ b/zh/examples/polygon/3d/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/polygon/fill/index.html b/zh/examples/polygon/fill/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/polygon/fill/index.html +++ b/zh/examples/polygon/fill/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/raster/basic/index.html b/zh/examples/raster/basic/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/raster/basic/index.html +++ b/zh/examples/raster/basic/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/raster/data_raster/index.html b/zh/examples/raster/data_raster/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/raster/data_raster/index.html +++ b/zh/examples/raster/data_raster/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/raster/single_raster/index.html b/zh/examples/raster/single_raster/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/raster/single_raster/index.html +++ b/zh/examples/raster/single_raster/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/tile/basemap/index.html b/zh/examples/tile/basemap/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/tile/basemap/index.html +++ b/zh/examples/tile/basemap/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/tile/raster/index.html b/zh/examples/tile/raster/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/tile/raster/index.html +++ b/zh/examples/tile/raster/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/tile/vector/index.html b/zh/examples/tile/vector/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/tile/vector/index.html +++ b/zh/examples/tile/vector/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/tutorial/control/index.html b/zh/examples/tutorial/control/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/tutorial/control/index.html +++ b/zh/examples/tutorial/control/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/tutorial/layer/index.html b/zh/examples/tutorial/layer/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/tutorial/layer/index.html +++ b/zh/examples/tutorial/layer/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/tutorial/map/index.html b/zh/examples/tutorial/map/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/tutorial/map/index.html +++ b/zh/examples/tutorial/map/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/tutorial/marker/index.html b/zh/examples/tutorial/marker/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/tutorial/marker/index.html +++ b/zh/examples/tutorial/marker/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/examples/wind/basic/index.html b/zh/examples/wind/basic/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/examples/wind/basic/index.html +++ b/zh/examples/wind/basic/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/zh/index.html b/zh/index.html index 18f99f0c1c..b53b74429b 100644 --- a/zh/index.html +++ b/zh/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file diff --git a/~demos/:id/index.html b/~demos/:id/index.html index 18f99f0c1c..b53b74429b 100644 --- a/~demos/:id/index.html +++ b/~demos/:id/index.html @@ -7,7 +7,7 @@
    - + \ No newline at end of file