@vue-start/map 0.0.4 → 0.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +24 -14
- package/dist/index.es.js +2 -0
- package/dist/index.js +1 -1
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -6,6 +6,7 @@ declare type TEvents = {
|
|
|
6
6
|
handler: (...args: any[]) => void;
|
|
7
7
|
once?: boolean;
|
|
8
8
|
}[];
|
|
9
|
+
declare const useEvents: (eventObj: AMap.Event, events: TEvents) => void;
|
|
9
10
|
|
|
10
11
|
interface IMapProvide {
|
|
11
12
|
mapRef: ShallowRef<AMap.Map>;
|
|
@@ -48,6 +49,15 @@ declare global {
|
|
|
48
49
|
};
|
|
49
50
|
}
|
|
50
51
|
}
|
|
52
|
+
declare const MapEvents: vue.DefineComponent<{
|
|
53
|
+
events: {
|
|
54
|
+
type: PropType<TEvents>;
|
|
55
|
+
};
|
|
56
|
+
}, () => null, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps, Readonly<ExtractPropTypes<{
|
|
57
|
+
events: {
|
|
58
|
+
type: PropType<TEvents>;
|
|
59
|
+
};
|
|
60
|
+
}>>, {}>;
|
|
51
61
|
declare const Map: vue.DefineComponent<Partial<ExtractPropTypes<{
|
|
52
62
|
securityJsCode: {
|
|
53
63
|
type: StringConstructor;
|
|
@@ -61,7 +71,7 @@ declare const Map: vue.DefineComponent<Partial<ExtractPropTypes<{
|
|
|
61
71
|
events: {
|
|
62
72
|
type: PropType<TEvents>;
|
|
63
73
|
};
|
|
64
|
-
}>>, {}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin,
|
|
74
|
+
}>>, {}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps, Readonly<Partial<ExtractPropTypes<{
|
|
65
75
|
securityJsCode: {
|
|
66
76
|
type: StringConstructor;
|
|
67
77
|
};
|
|
@@ -81,7 +91,7 @@ declare const MapPlugin: vue.DefineComponent<{
|
|
|
81
91
|
plugins: PropType<string[]>;
|
|
82
92
|
}, () => vue.VNode<vue.RendererNode, vue.RendererElement, {
|
|
83
93
|
[key: string]: any;
|
|
84
|
-
}>[] | null | undefined, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin,
|
|
94
|
+
}>[] | null | undefined, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps, Readonly<vue.ExtractPropTypes<{
|
|
85
95
|
plugins: PropType<string[]>;
|
|
86
96
|
}>>, {}>;
|
|
87
97
|
declare const MapPluginType: {
|
|
@@ -263,7 +273,7 @@ declare const createFeature: <T extends keyof TFeature>(name: T, { useMapConnect
|
|
|
263
273
|
createFeatureObj?: ((opts: TFeature[T]["opts"]) => TFeature[T]["type"]) | undefined;
|
|
264
274
|
needDom?: boolean | undefined;
|
|
265
275
|
}) => DefineComponent<any, any, any>;
|
|
266
|
-
declare const createPluginFeature: (plugins: string[], Feature: any) => DefineComponent<any, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin,
|
|
276
|
+
declare const createPluginFeature: (plugins: string[], Feature: any) => DefineComponent<any, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps, Readonly<any>, {} | {
|
|
267
277
|
[x: string]: any;
|
|
268
278
|
}>;
|
|
269
279
|
|
|
@@ -302,7 +312,7 @@ declare const OverlayGroup: vue.DefineComponent<{
|
|
|
302
312
|
};
|
|
303
313
|
}, () => vue.VNode<vue.RendererNode, vue.RendererElement, {
|
|
304
314
|
[key: string]: any;
|
|
305
|
-
}>[] | undefined, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin,
|
|
315
|
+
}>[] | undefined, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps, Readonly<vue.ExtractPropTypes<{
|
|
306
316
|
/**
|
|
307
317
|
* 首次添加到地图中的标识;
|
|
308
318
|
* 值为true时,将OverlayGroup对象添加到地图中;
|
|
@@ -344,7 +354,7 @@ declare const InfoWindow: vue.DefineComponent<{
|
|
|
344
354
|
type: NumberConstructor;
|
|
345
355
|
default: undefined;
|
|
346
356
|
};
|
|
347
|
-
}, () => JSX.Element | null, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin,
|
|
357
|
+
}, () => JSX.Element | null, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps, Readonly<vue.ExtractPropTypes<{
|
|
348
358
|
opts: {
|
|
349
359
|
type: PropType<AMap.InfoOptions>;
|
|
350
360
|
};
|
|
@@ -391,19 +401,19 @@ declare const Ellipse: vue.DefineComponent<any, any, any, vue.ComputedOptions, v
|
|
|
391
401
|
declare const BezierCurve: vue.DefineComponent<any, any, any, vue.ComputedOptions, vue.MethodOptions, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps, Readonly<any>, {} | {
|
|
392
402
|
[x: string]: any;
|
|
393
403
|
}>;
|
|
394
|
-
declare const ToolBar: vue.DefineComponent<any, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin,
|
|
404
|
+
declare const ToolBar: vue.DefineComponent<any, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps, Readonly<any>, {} | {
|
|
395
405
|
[x: string]: any;
|
|
396
406
|
}>;
|
|
397
|
-
declare const Scale: vue.DefineComponent<any, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin,
|
|
407
|
+
declare const Scale: vue.DefineComponent<any, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps, Readonly<any>, {} | {
|
|
398
408
|
[x: string]: any;
|
|
399
409
|
}>;
|
|
400
|
-
declare const HawkEye: vue.DefineComponent<any, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin,
|
|
410
|
+
declare const HawkEye: vue.DefineComponent<any, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps, Readonly<any>, {} | {
|
|
401
411
|
[x: string]: any;
|
|
402
412
|
}>;
|
|
403
|
-
declare const MapType: vue.DefineComponent<any, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin,
|
|
413
|
+
declare const MapType: vue.DefineComponent<any, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps, Readonly<any>, {} | {
|
|
404
414
|
[x: string]: any;
|
|
405
415
|
}>;
|
|
406
|
-
declare const ControlBar: vue.DefineComponent<any, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin,
|
|
416
|
+
declare const ControlBar: vue.DefineComponent<any, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps, Readonly<any>, {} | {
|
|
407
417
|
[x: string]: any;
|
|
408
418
|
}>;
|
|
409
419
|
|
|
@@ -431,7 +441,7 @@ declare const LayerGroup: vue.DefineComponent<{
|
|
|
431
441
|
};
|
|
432
442
|
}, () => vue.VNode<vue.RendererNode, vue.RendererElement, {
|
|
433
443
|
[key: string]: any;
|
|
434
|
-
}>[] | undefined, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin,
|
|
444
|
+
}>[] | undefined, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps, Readonly<vue.ExtractPropTypes<{
|
|
435
445
|
bind: {
|
|
436
446
|
type: BooleanConstructor;
|
|
437
447
|
default: boolean;
|
|
@@ -475,7 +485,7 @@ declare const LabelsLayer: vue.DefineComponent<{
|
|
|
475
485
|
events: {
|
|
476
486
|
type: PropType<TEvents>;
|
|
477
487
|
};
|
|
478
|
-
}, () => null, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin,
|
|
488
|
+
}, () => null, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps, Readonly<vue.ExtractPropTypes<{
|
|
479
489
|
opts: {
|
|
480
490
|
type: PropType<AMap.LabelsLayerOptions>;
|
|
481
491
|
};
|
|
@@ -538,7 +548,7 @@ declare const DistrictLayerCountry: vue.DefineComponent<any, any, any, vue.Compu
|
|
|
538
548
|
declare const DistrictLayerProvince: vue.DefineComponent<any, any, any, vue.ComputedOptions, vue.MethodOptions, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps, Readonly<any>, {} | {
|
|
539
549
|
[x: string]: any;
|
|
540
550
|
}>;
|
|
541
|
-
declare const HeatMap: vue.DefineComponent<any, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin,
|
|
551
|
+
declare const HeatMap: vue.DefineComponent<any, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps, Readonly<any>, {} | {
|
|
542
552
|
[x: string]: any;
|
|
543
553
|
}>;
|
|
544
554
|
|
|
@@ -581,4 +591,4 @@ declare const ApiNames: {
|
|
|
581
591
|
StationSearch_searchById: string;
|
|
582
592
|
};
|
|
583
593
|
|
|
584
|
-
export { ApiNames, BezierCurve, Buildings, CanvasLayer, Circle, CircleMarker, ControlBar, CustomLayer, DistrictLayerCountry, DistrictLayerProvince, DistrictLayerWorld, ElasticMarker, Ellipse, HawkEye, HeatMap, IMapProvide, IUseMapApiOptions, IUseMapApiResult, ImageLayer, InfoWindow, LabelsLayer, LayerGroup, Map, MapPlugin, MapPluginType, MapProps, MapType, Marker, MassMarks, OverlayGroup, Polygon, Polyline, Rectangle, Scale, TLoadOpts, Text, TileLayer, TileLayerFlexible, TileLayerRoadNet, TileLayerSatellite, TileLayerTraffic, ToolBar, VideoLayer, createFeature, createPluginFeature, provideMap, useFeatureOptMethods, useMap, useMapApi, useMapConnect, useMapConnect2, useMapControlConnect, useMapLayerConnect, useMapOverlayConnect, useMapPlugin, useShowConnect };
|
|
594
|
+
export { ApiNames, BezierCurve, Buildings, CanvasLayer, Circle, CircleMarker, ControlBar, CustomLayer, DistrictLayerCountry, DistrictLayerProvince, DistrictLayerWorld, ElasticMarker, Ellipse, HawkEye, HeatMap, IMapProvide, IUseMapApiOptions, IUseMapApiResult, ImageLayer, InfoWindow, LabelsLayer, LayerGroup, Map, MapEvents, MapPlugin, MapPluginType, MapProps, MapType, Marker, MassMarks, OverlayGroup, Polygon, Polyline, Rectangle, Scale, TEvents, TLoadOpts, Text, TileLayer, TileLayerFlexible, TileLayerRoadNet, TileLayerSatellite, TileLayerTraffic, ToolBar, VideoLayer, createFeature, createPluginFeature, provideMap, useEvents, useFeatureOptMethods, useMap, useMapApi, useMapConnect, useMapConnect2, useMapControlConnect, useMapLayerConnect, useMapOverlayConnect, useMapPlugin, useShowConnect };
|
package/dist/index.es.js
CHANGED
|
@@ -579,6 +579,7 @@ export {
|
|
|
579
579
|
Je as LabelsLayer,
|
|
580
580
|
xe as LayerGroup,
|
|
581
581
|
Le as Map,
|
|
582
|
+
pe as MapEvents,
|
|
582
583
|
de as MapPlugin,
|
|
583
584
|
S as MapPluginType,
|
|
584
585
|
We as MapType,
|
|
@@ -600,6 +601,7 @@ export {
|
|
|
600
601
|
c as createFeature,
|
|
601
602
|
L as createPluginFeature,
|
|
602
603
|
j as provideMap,
|
|
604
|
+
q as useEvents,
|
|
603
605
|
k as useFeatureOptMethods,
|
|
604
606
|
m as useMap,
|
|
605
607
|
ca as useMapApi,
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const o=require("vue"),H=require("@amap/amap-jsapi-loader"),i=require("@vue-start/hooks"),u=require("lodash"),V=e=>e&&typeof e=="object"&&"default"in e?e:{default:e},$=V(H),G=(e,a)=>{i.useEffect(()=>(u.forEach(a,r=>{e.on(r.type,r.handler,void 0,r.once)}),()=>{u.forEach(a,r=>{e.off(r.type,r.handler)})}),[])},W=Symbol("amap-key"),R=e=>o.provide(W,e),m=()=>o.inject(W),x=()=>({securityJsCode:{type:String},loadOpts:{type:Object},opts:{type:Object},events:{type:Array}}),J=e=>{var a;if(!!e){if(!window._AMapSecurityConfig||!((a=window._AMapSecurityConfig)!=null&&a.securityJsCode)){window._AMapSecurityConfig={securityJsCode:e};return}window._AMapSecurityConfig.securityJsCode!==e&&(window._AMapSecurityConfig={securityJsCode:e},console.warn("\u5F53\u524Dwindow\u5BF9\u8C61\u5DF2\u7ECF\u6CE8\u5165\u8FC7securityJsCode\u503C\uFF0C\u53EF\u80FD\u9020\u6210\u95EE\u9898"))}},q=o.defineComponent({props:{events:{type:Array}},setup:e=>{const{mapRef:a}=m();return G(a.value,e.events),()=>null}}),z=o.defineComponent({props:{...x()},setup:(e,{slots:a,expose:r})=>{J(e.securityJsCode);const n=o.shallowRef(),t=o.ref();return r({mapRef:n,domRef:t}),i.useEffect(()=>($.default.load({version:"2.0",...e.loadOpts}).then(c=>{const p=new c.Map(t.value,{...e.opts});p.on("complete",()=>{n.value=p})}).catch(c=>{console.error("\u52A0\u8F7D\u5730\u56FE\u9519\u8BEF"),console.error(c)}),()=>{n.value&&n.value.destroy()}),[]),R({mapRef:n}),()=>{var c;return o.createVNode("div",{ref:t},[n.value&&o.createVNode(q,{events:e.events},null),n.value&&((c=a.default)==null?void 0:c.call(a))])}}}),k=(e,a)=>{const{mapRef:r}=m();i.useEffect(()=>{if(!r.value){console.warn("\u8BF7\u5728Map\u7EC4\u4EF6\u5185\u4F7F\u7528 useMapPlugin");return}if(!e||u.size(e)<=0){a();return}window.AMap.plugin(e,a)},[])},I=o.defineComponent({props:{plugins:Array},setup:(e,{slots:a})=>{const r=o.ref(!1);return k(e.plugins,()=>{r.value=!0}),()=>{var n;return r.value?(n=a.default)==null?void 0:n.call(a):null}}}),A={ElasticMarker:"AMap.ElasticMarker",ControlBar:"AMap.ControlBar",ToolBar:"AMap.ToolBar",Scale:"AMap.Scale",HawkEye:"AMap.HawkEye",MapType:"AMap.MapType",AdvancedInfoWindow:"AMap.AdvancedInfoWindow",DragRoute:"AMap.DragRoute",IndoorMap:"AMap.IndoorMap",MouseTool:"AMap.MouseTool",CircleEditor:"AMap.CircleEditor",PolygonEditor:"AMap.PolygonEditor",PolylineEditor:"AMap.PolylineEditor",MarkerCluster:"AMap.MarkerCluster",RangingTool:"AMap.RangingTool",Geolocation:"AMap.Geolocation",Geocoder:"AMap.Geocoder",AutoComplete:"AMap.AutoComplete",PlaceSearch:"AMap.PlaceSearch",LineSearch:"AMap.LineSearch",DistrictSearch:"AMap.DistrictSearch",StationSearch:"AMap.StationSearch",CitySearch:"AMap.CitySearch",CloudDataSearch:"AMap.CloudDataSearch",RoadInfoSearch:"AMap.RoadInfoSearch",Driving:"AMap.Driving",TruckDriving:"AMap.TruckDriving",Transfer:"AMap.Transfer",Walking:"AMap.Walking",Riding:"AMap.Riding",ArrivalRange:"AMap.ArrivalRange",GraspRoad:"AMap.GraspRoad",HeatMap:"AMap.HeatMap",Weather:"AMap.Weather"},F=e=>{const{mapRef:a}=m();i.useEffect(()=>(a.value.add(e),()=>{try{a.value.remove(e)}catch(r){console.error(r)}}),[])},B=e=>{const{mapRef:a}=m();i.useEffect(()=>(e.setMap(a.value),()=>{try{e.setMap(null)}catch(r){console.error(r)}}),[])},g=e=>{const{mapRef:a}=m();i.useEffect(()=>(a.value.addControl(e),()=>{try{a.value.removeControl(e)}catch(r){console.error(r)}}),[])},S=(e,a)=>{const r=()=>{e&&u.isFunction(e.show)&&e.show()},n=()=>{e&&u.isFunction(e.hide)&&e.hide()};i.useEffect(()=>{a.value||n()},[]),i.useWatch(()=>{a.value?r():n()},a)},b=(e,a)=>{i.useEffect(()=>{u.forEach(a.value,(r,n)=>{const t="set"+u.upperFirst(n);e[t]&&u.isFunction(e[t])&&e[t](r)})},a)},s=(e,{useMapConnect:a,createFeatureObj:r,needDom:n})=>o.defineComponent({props:{opts:{type:Object},opts$:{type:Object},show:{type:Boolean,default:!0},events:{type:Array}},setup:(t,{slots:c,expose:p})=>{const l=r?r(t.opts):new window.AMap[e](t.opts);a(l);const M=o.toRef(t,"show");S(l,M);const f=o.toRef(t,"opts$");b(l,f),G(l,t.events),p({getFeature:()=>l});const C=o.ref();return i.useEffect(()=>{C.value&&u.isFunction(l.setContent)&&l.setContent(C.value)},C),()=>n&&c.default?o.createVNode(o.Teleport,{to:"body"},{default:()=>[o.createVNode("div",{ref:C},[c.default()])]}):null}}),w=(e,a)=>o.defineComponent({props:{...a.props},setup:(r,{slots:n,expose:t})=>{const c=o.ref();return t(i.createExposeObj(c,["getFeature"])),()=>o.createVNode(I,{plugins:e},{default:()=>[o.createVNode(a,o.mergeProps({ref:c},r),n)]})}}),K=()=>{const{mapRef:e,overlayGroup:a}=m();return{addToMap:t=>{if(a){u.isArray(t)?a.addOverlays(t):a.addOverlay(t);return}e.value.add(t)},removeFromMap:t=>{if(a){u.isArray(t)?a.removeOverlays(t):a.removeOverlay(t);return}try{e.value.remove(t)}catch(c){console.error(c)}}}},h=e=>{const{addToMap:a,removeFromMap:r}=K();i.useEffect(()=>(a(e),()=>{r(e)}),[])},Q=o.defineComponent({props:{bind:{type:Boolean,default:!1},bindTime:{type:Number,default:void 0},opts$:{type:Object},show:{type:Boolean,default:!0},events:{type:Array}},setup:(e,{slots:a,expose:r})=>{const{mapRef:n}=m(),t=new window.AMap.OverlayGroup;let c=!1;const p=()=>{c||(n.value.add(t),c=!0)},l=()=>{try{n.value.remove(t)}catch(d){console.error(d)}c=!1},M=()=>t;i.useEffect(()=>()=>{l()},[]),i.useEffect(()=>{if(!u.isNumber(e.bindTime))return;const d=setTimeout(()=>{p()},e.bindTime);return()=>{d&&clearTimeout(d)}},[]);const f=u.debounce(()=>{p()},300);i.useWatch(()=>{e.bind&&f()},()=>e.bind);const C=o.toRef(e,"show");S(t,C);const T=o.toRef(e,"opts$");return b(t,T),r({getFeature:M,addToMap:p,removeFormMap:l}),R({mapRef:n,overlayGroup:t}),()=>{var d;return(d=a.default)==null?void 0:d.call(a)}}}),U=o.defineComponent({props:{opts:{type:Object},opts$:{type:Object},height:{type:Number,default:void 0}},setup:(e,{slots:a,emit:r})=>{const{mapRef:n}=m(),t=new window.AMap.InfoWindow({closeWhenClickMap:!0,isCustom:!!a.default,...e.opts}),c=o.toRef(e,"opts$");b(t,c);const p=()=>{r("close")};i.useEffect(()=>(t.on("close",p),()=>{t.off("close",p),t.close()}),[]),i.useEffect(()=>{var f,C;const M=((f=e.opts$)==null?void 0:f.position)||((C=e.opts)==null?void 0:C.position);!M||t.open(n.value,M,e.height)},()=>{var M;return(M=e.opts$)==null?void 0:M.position});const l=o.ref();return i.useEffect(()=>{l.value&&u.isFunction(t.setContent)&&t.setContent(l.value)},l),()=>a.default?o.createVNode(o.Teleport,{to:"body"},{default:()=>[o.createVNode("div",{ref:l},[a.default()])]}):null}}),X=s("CircleMarker",{useMapConnect:F}),Y=s("Text",{useMapConnect:F}),Z=s("ElasticMarker",{useMapConnect:F}),ee=s("Marker",{useMapConnect:h,needDom:!0}),ae=s("Polygon",{useMapConnect:h}),te=s("Polyline",{useMapConnect:h}),re=s("Circle",{useMapConnect:h}),ne=s("Rectangle",{useMapConnect:h}),oe=s("Ellipse",{useMapConnect:h}),ce=s("BezierCurve",{useMapConnect:h}),se=s("ToolBar",{useMapConnect:g}),ue=w([A.ToolBar],se),ie=s("Scale",{useMapConnect:g}),le=w([A.Scale],ie),pe=s("HawkEye",{useMapConnect:g}),de=w([A.HawkEye],pe),Me=s("MapType",{useMapConnect:g}),fe=w([A.MapType],Me),ye=s("ControlBar",{useMapConnect:g}),Ce=w([A.ControlBar],ye),me=()=>{const{mapRef:e,layerGroup:a}=m();return{addToMap:t=>{if(a){u.isArray(t)?a.addLayers(t):a.addLayer(t);return}e.value.add(t)},removeFromMap:t=>{if(a){u.isArray(t)?a.removeLayers(t):a.removeLayer(t);return}try{e.value.remove(t)}catch(c){console.error(c)}}}},y=e=>{const{addToMap:a,removeFromMap:r}=me();i.useEffect(()=>(a(e),()=>{r(e)}),[])},ve=o.defineComponent({props:{bind:{type:Boolean,default:!1},bindTime:{type:Number,default:void 0},opts$:{type:Object},show:{type:Boolean,default:!0},events:{type:Array}},setup:(e,{slots:a,expose:r})=>{const{mapRef:n}=m(),t=new window.AMap.LayerGroup;let c=!1;const p=()=>{c||(t.setMap(n.value),c=!0)},l=()=>{try{t.setMap(null)}catch(d){console.error(d)}c=!1},M=()=>t;i.useEffect(()=>()=>{l()},[]),i.useEffect(()=>{if(!u.isNumber(e.bindTime))return;const d=setTimeout(()=>{p()},e.bindTime);return()=>{d&&clearTimeout(d)}},[]);const f=u.debounce(()=>{p()},300);i.useWatch(()=>{e.bind&&f()},()=>e.bind);const C=o.toRef(e,"show");S(t,C);const T=o.toRef(e,"opts$");return b(t,T),r({getFeature:M,addToMap:p,removeFormMap:l}),R({mapRef:n,layerGroup:t}),()=>{var d;return(d=a.default)==null?void 0:d.call(a)}}}),he=o.defineComponent({props:{opts:{type:Object},itemOpts:{type:Object},data:{type:Array},show:{type:Boolean,default:!0},events:{type:Array}},setup:(e,{expose:a})=>{const{mapRef:r}=m(),n=new window.AMap.LabelsLayer(e.opts),t=()=>u.map(e.data,l=>{const M=new window.AMap.LabelMarker({...e.itemOpts,...l});return e.events&&u.forEach(e.events,f=>{M.on(f.type,f.handler,void 0,f.once)}),M}),c=()=>{n.clear();const l=t();n.add(l)};i.useEffect(()=>(u.size(e.data)>0&&c(),r.value.add(n),()=>{n.clear(),r.value.remove(n)}),[]),i.useWatch(()=>{c()},()=>e.data);const p=o.toRef(e,"show");return S(n,p),a({getFeature:()=>n}),()=>null}}),Ae=s("TileLayer",{useMapConnect:y}),we=s("TileLayer.Satellite",{useMapConnect:y,createFeatureObj:e=>new window.AMap.TileLayer.Satellite(e)}),Te=s("TileLayer.RoadNet",{useMapConnect:y,createFeatureObj:e=>new window.AMap.TileLayer.RoadNet(e)}),ge=s("TileLayer.Traffic",{useMapConnect:y,createFeatureObj:e=>new window.AMap.TileLayer.Traffic(e)}),Le=s("Buildings",{useMapConnect:y}),Se=s("MassMarks",{useMapConnect:B,createFeatureObj:e=>new window.AMap.MassMarks((e==null?void 0:e.data)||[],u.omit(e,"data"))}),be=s("TileLayer.Flexible",{useMapConnect:y,createFeatureObj:e=>new window.AMap.TileLayer.Flexible(e)}),Ee=s("ImageLayer",{useMapConnect:y}),Re=s("VideoLayer",{useMapConnect:y}),Fe=s("CanvasLayer",{useMapConnect:y}),Oe=s("CustomLayer",{useMapConnect:y,createFeatureObj:e=>new window.AMap.CustomLayer(e==null?void 0:e.canvas,u.omit(e,"canvas"))}),Pe=s("DistrictLayer.World",{useMapConnect:y,createFeatureObj:e=>new window.AMap.DistrictLayer.World(e)}),ke=s("DistrictLayer.Country",{useMapConnect:y,createFeatureObj:e=>new window.AMap.DistrictLayer.Country(e)}),Be=s("DistrictLayer.Province",{useMapConnect:y,createFeatureObj:e=>new window.AMap.DistrictLayer.Province(e)}),_e=s("HeatMap",{useMapConnect:B,createFeatureObj:e=>new window.AMap.HeatMap(null,e)}),De=w([A.HeatMap],_e),Ne=(e,a)=>{let r=!1,n=null;const[t,c]=i.useState(),p=o.ref(u.isBoolean(a.initEmit)?a.initEmit:!1),l=u.split(e,"_"),M=l[0],f=l[1],C=()=>{const v=u.get(window,M);return v?new v({...a.opts,...n==null?void 0:n.opts}):null},T=v=>v||(u.isFunction(a.params)?a.params():a.params||[]),d=()=>{if(!n)return;const v=C();if(!v||!u.isFunction(v[f]))return;const P=T(n.params);p.value=!0,v[f](...P,(E,L)=>{var _,D,N,j;c(L),(_=a.onComplete)==null||_.call(a,E,L),E==="complete"?(D=a.onSuccess)==null||D.call(a,L):E==="error"?(N=a.onFail)==null||N.call(a,L):E==="no_data"&&((j=a.onNoData)==null||j.call(a,L)),n=null,p.value=!1})};k([M],()=>{r=!0,d()});const O=(v,P)=>{n={opts:v||a.opts,params:T(P)},r&&d()};return i.useEffect(()=>{a.initEmit&&O()},[]),i.useWatch(()=>O(),a.deps||[]),{data:t,request:O,requesting:p}},je={Geocoder_getLocation:"AMap.Geocoder_getLocation",Geocoder_getAddress:"AMap.Geocoder_getAddress",Autocomplete_search:"AMap.Autocomplete_search",PlaceSearch_search:"AMap.PlaceSearch_search",PlaceSearch_searchNearBy:"AMap.PlaceSearch_searchNearBy",PlaceSearch_searchInBounds:"AMap.PlaceSearch_searchInBounds",PlaceSearch_getDetails:"AMap.PlaceSearch_getDetails",DistrictSearch_search:"AMap.DistrictSearch_search",LineSearch_search:"AMap.LineSearch_search",LineSearch_searchById:"AMap.LineSearch_searchById",StationSearch_search:"AMap.StationSearch_search",StationSearch_searchById:"AMap.StationSearch_searchById"};exports.ApiNames=je;exports.BezierCurve=ce;exports.Buildings=Le;exports.CanvasLayer=Fe;exports.Circle=re;exports.CircleMarker=X;exports.ControlBar=Ce;exports.CustomLayer=Oe;exports.DistrictLayerCountry=ke;exports.DistrictLayerProvince=Be;exports.DistrictLayerWorld=Pe;exports.ElasticMarker=Z;exports.Ellipse=oe;exports.HawkEye=de;exports.HeatMap=De;exports.ImageLayer=Ee;exports.InfoWindow=U;exports.LabelsLayer=he;exports.LayerGroup=ve;exports.Map=z;exports.MapPlugin=I;exports.MapPluginType=A;exports.MapType=fe;exports.Marker=ee;exports.MassMarks=Se;exports.OverlayGroup=Q;exports.Polygon=ae;exports.Polyline=te;exports.Rectangle=ne;exports.Scale=le;exports.Text=Y;exports.TileLayer=Ae;exports.TileLayerFlexible=be;exports.TileLayerRoadNet=Te;exports.TileLayerSatellite=we;exports.TileLayerTraffic=ge;exports.ToolBar=ue;exports.VideoLayer=Re;exports.createFeature=s;exports.createPluginFeature=w;exports.provideMap=R;exports.useFeatureOptMethods=b;exports.useMap=m;exports.useMapApi=Ne;exports.useMapConnect=F;exports.useMapConnect2=B;exports.useMapControlConnect=g;exports.useMapLayerConnect=y;exports.useMapOverlayConnect=h;exports.useMapPlugin=k;exports.useShowConnect=S;
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const o=require("vue"),V=require("@amap/amap-jsapi-loader"),i=require("@vue-start/hooks"),u=require("lodash"),$=e=>e&&typeof e=="object"&&"default"in e?e:{default:e},x=$(V),k=(e,a)=>{i.useEffect(()=>(u.forEach(a,r=>{e.on(r.type,r.handler,void 0,r.once)}),()=>{u.forEach(a,r=>{e.off(r.type,r.handler)})}),[])},W=Symbol("amap-key"),R=e=>o.provide(W,e),m=()=>o.inject(W),J=()=>({securityJsCode:{type:String},loadOpts:{type:Object},opts:{type:Object},events:{type:Array}}),q=e=>{var a;if(!!e){if(!window._AMapSecurityConfig||!((a=window._AMapSecurityConfig)!=null&&a.securityJsCode)){window._AMapSecurityConfig={securityJsCode:e};return}window._AMapSecurityConfig.securityJsCode!==e&&(window._AMapSecurityConfig={securityJsCode:e},console.warn("\u5F53\u524Dwindow\u5BF9\u8C61\u5DF2\u7ECF\u6CE8\u5165\u8FC7securityJsCode\u503C\uFF0C\u53EF\u80FD\u9020\u6210\u95EE\u9898"))}},I=o.defineComponent({props:{events:{type:Array}},setup:e=>{const{mapRef:a}=m();return k(a.value,e.events),()=>null}}),z=o.defineComponent({props:{...J()},setup:(e,{slots:a,expose:r})=>{q(e.securityJsCode);const n=o.shallowRef(),t=o.ref();return r({mapRef:n,domRef:t}),i.useEffect(()=>(x.default.load({version:"2.0",...e.loadOpts}).then(c=>{const p=new c.Map(t.value,{...e.opts});p.on("complete",()=>{n.value=p})}).catch(c=>{console.error("\u52A0\u8F7D\u5730\u56FE\u9519\u8BEF"),console.error(c)}),()=>{n.value&&n.value.destroy()}),[]),R({mapRef:n}),()=>{var c;return o.createVNode("div",{ref:t},[n.value&&o.createVNode(I,{events:e.events},null),n.value&&((c=a.default)==null?void 0:c.call(a))])}}}),B=(e,a)=>{const{mapRef:r}=m();i.useEffect(()=>{if(!r.value){console.warn("\u8BF7\u5728Map\u7EC4\u4EF6\u5185\u4F7F\u7528 useMapPlugin");return}if(!e||u.size(e)<=0){a();return}window.AMap.plugin(e,a)},[])},H=o.defineComponent({props:{plugins:Array},setup:(e,{slots:a})=>{const r=o.ref(!1);return B(e.plugins,()=>{r.value=!0}),()=>{var n;return r.value?(n=a.default)==null?void 0:n.call(a):null}}}),A={ElasticMarker:"AMap.ElasticMarker",ControlBar:"AMap.ControlBar",ToolBar:"AMap.ToolBar",Scale:"AMap.Scale",HawkEye:"AMap.HawkEye",MapType:"AMap.MapType",AdvancedInfoWindow:"AMap.AdvancedInfoWindow",DragRoute:"AMap.DragRoute",IndoorMap:"AMap.IndoorMap",MouseTool:"AMap.MouseTool",CircleEditor:"AMap.CircleEditor",PolygonEditor:"AMap.PolygonEditor",PolylineEditor:"AMap.PolylineEditor",MarkerCluster:"AMap.MarkerCluster",RangingTool:"AMap.RangingTool",Geolocation:"AMap.Geolocation",Geocoder:"AMap.Geocoder",AutoComplete:"AMap.AutoComplete",PlaceSearch:"AMap.PlaceSearch",LineSearch:"AMap.LineSearch",DistrictSearch:"AMap.DistrictSearch",StationSearch:"AMap.StationSearch",CitySearch:"AMap.CitySearch",CloudDataSearch:"AMap.CloudDataSearch",RoadInfoSearch:"AMap.RoadInfoSearch",Driving:"AMap.Driving",TruckDriving:"AMap.TruckDriving",Transfer:"AMap.Transfer",Walking:"AMap.Walking",Riding:"AMap.Riding",ArrivalRange:"AMap.ArrivalRange",GraspRoad:"AMap.GraspRoad",HeatMap:"AMap.HeatMap",Weather:"AMap.Weather"},F=e=>{const{mapRef:a}=m();i.useEffect(()=>(a.value.add(e),()=>{try{a.value.remove(e)}catch(r){console.error(r)}}),[])},_=e=>{const{mapRef:a}=m();i.useEffect(()=>(e.setMap(a.value),()=>{try{e.setMap(null)}catch(r){console.error(r)}}),[])},g=e=>{const{mapRef:a}=m();i.useEffect(()=>(a.value.addControl(e),()=>{try{a.value.removeControl(e)}catch(r){console.error(r)}}),[])},S=(e,a)=>{const r=()=>{e&&u.isFunction(e.show)&&e.show()},n=()=>{e&&u.isFunction(e.hide)&&e.hide()};i.useEffect(()=>{a.value||n()},[]),i.useWatch(()=>{a.value?r():n()},a)},E=(e,a)=>{i.useEffect(()=>{u.forEach(a.value,(r,n)=>{const t="set"+u.upperFirst(n);e[t]&&u.isFunction(e[t])&&e[t](r)})},a)},s=(e,{useMapConnect:a,createFeatureObj:r,needDom:n})=>o.defineComponent({props:{opts:{type:Object},opts$:{type:Object},show:{type:Boolean,default:!0},events:{type:Array}},setup:(t,{slots:c,expose:p})=>{const l=r?r(t.opts):new window.AMap[e](t.opts);a(l);const M=o.toRef(t,"show");S(l,M);const f=o.toRef(t,"opts$");E(l,f),k(l,t.events),p({getFeature:()=>l});const C=o.ref();return i.useEffect(()=>{C.value&&u.isFunction(l.setContent)&&l.setContent(C.value)},C),()=>n&&c.default?o.createVNode(o.Teleport,{to:"body"},{default:()=>[o.createVNode("div",{ref:C},[c.default()])]}):null}}),w=(e,a)=>o.defineComponent({props:{...a.props},setup:(r,{slots:n,expose:t})=>{const c=o.ref();return t(i.createExposeObj(c,["getFeature"])),()=>o.createVNode(H,{plugins:e},{default:()=>[o.createVNode(a,o.mergeProps({ref:c},r),n)]})}}),K=()=>{const{mapRef:e,overlayGroup:a}=m();return{addToMap:t=>{if(a){u.isArray(t)?a.addOverlays(t):a.addOverlay(t);return}e.value.add(t)},removeFromMap:t=>{if(a){u.isArray(t)?a.removeOverlays(t):a.removeOverlay(t);return}try{e.value.remove(t)}catch(c){console.error(c)}}}},h=e=>{const{addToMap:a,removeFromMap:r}=K();i.useEffect(()=>(a(e),()=>{r(e)}),[])},Q=o.defineComponent({props:{bind:{type:Boolean,default:!1},bindTime:{type:Number,default:void 0},opts$:{type:Object},show:{type:Boolean,default:!0},events:{type:Array}},setup:(e,{slots:a,expose:r})=>{const{mapRef:n}=m(),t=new window.AMap.OverlayGroup;let c=!1;const p=()=>{c||(n.value.add(t),c=!0)},l=()=>{try{n.value.remove(t)}catch(d){console.error(d)}c=!1},M=()=>t;i.useEffect(()=>()=>{l()},[]),i.useEffect(()=>{if(!u.isNumber(e.bindTime))return;const d=setTimeout(()=>{p()},e.bindTime);return()=>{d&&clearTimeout(d)}},[]);const f=u.debounce(()=>{p()},300);i.useWatch(()=>{e.bind&&f()},()=>e.bind);const C=o.toRef(e,"show");S(t,C);const T=o.toRef(e,"opts$");return E(t,T),r({getFeature:M,addToMap:p,removeFormMap:l}),R({mapRef:n,overlayGroup:t}),()=>{var d;return(d=a.default)==null?void 0:d.call(a)}}}),U=o.defineComponent({props:{opts:{type:Object},opts$:{type:Object},height:{type:Number,default:void 0}},setup:(e,{slots:a,emit:r})=>{const{mapRef:n}=m(),t=new window.AMap.InfoWindow({closeWhenClickMap:!0,isCustom:!!a.default,...e.opts}),c=o.toRef(e,"opts$");E(t,c);const p=()=>{r("close")};i.useEffect(()=>(t.on("close",p),()=>{t.off("close",p),t.close()}),[]),i.useEffect(()=>{var f,C;const M=((f=e.opts$)==null?void 0:f.position)||((C=e.opts)==null?void 0:C.position);!M||t.open(n.value,M,e.height)},()=>{var M;return(M=e.opts$)==null?void 0:M.position});const l=o.ref();return i.useEffect(()=>{l.value&&u.isFunction(t.setContent)&&t.setContent(l.value)},l),()=>a.default?o.createVNode(o.Teleport,{to:"body"},{default:()=>[o.createVNode("div",{ref:l},[a.default()])]}):null}}),X=s("CircleMarker",{useMapConnect:F}),Y=s("Text",{useMapConnect:F}),Z=s("ElasticMarker",{useMapConnect:F}),ee=s("Marker",{useMapConnect:h,needDom:!0}),ae=s("Polygon",{useMapConnect:h}),te=s("Polyline",{useMapConnect:h}),re=s("Circle",{useMapConnect:h}),ne=s("Rectangle",{useMapConnect:h}),oe=s("Ellipse",{useMapConnect:h}),ce=s("BezierCurve",{useMapConnect:h}),se=s("ToolBar",{useMapConnect:g}),ue=w([A.ToolBar],se),ie=s("Scale",{useMapConnect:g}),le=w([A.Scale],ie),pe=s("HawkEye",{useMapConnect:g}),de=w([A.HawkEye],pe),Me=s("MapType",{useMapConnect:g}),fe=w([A.MapType],Me),ye=s("ControlBar",{useMapConnect:g}),Ce=w([A.ControlBar],ye),me=()=>{const{mapRef:e,layerGroup:a}=m();return{addToMap:t=>{if(a){u.isArray(t)?a.addLayers(t):a.addLayer(t);return}e.value.add(t)},removeFromMap:t=>{if(a){u.isArray(t)?a.removeLayers(t):a.removeLayer(t);return}try{e.value.remove(t)}catch(c){console.error(c)}}}},y=e=>{const{addToMap:a,removeFromMap:r}=me();i.useEffect(()=>(a(e),()=>{r(e)}),[])},ve=o.defineComponent({props:{bind:{type:Boolean,default:!1},bindTime:{type:Number,default:void 0},opts$:{type:Object},show:{type:Boolean,default:!0},events:{type:Array}},setup:(e,{slots:a,expose:r})=>{const{mapRef:n}=m(),t=new window.AMap.LayerGroup;let c=!1;const p=()=>{c||(t.setMap(n.value),c=!0)},l=()=>{try{t.setMap(null)}catch(d){console.error(d)}c=!1},M=()=>t;i.useEffect(()=>()=>{l()},[]),i.useEffect(()=>{if(!u.isNumber(e.bindTime))return;const d=setTimeout(()=>{p()},e.bindTime);return()=>{d&&clearTimeout(d)}},[]);const f=u.debounce(()=>{p()},300);i.useWatch(()=>{e.bind&&f()},()=>e.bind);const C=o.toRef(e,"show");S(t,C);const T=o.toRef(e,"opts$");return E(t,T),r({getFeature:M,addToMap:p,removeFormMap:l}),R({mapRef:n,layerGroup:t}),()=>{var d;return(d=a.default)==null?void 0:d.call(a)}}}),he=o.defineComponent({props:{opts:{type:Object},itemOpts:{type:Object},data:{type:Array},show:{type:Boolean,default:!0},events:{type:Array}},setup:(e,{expose:a})=>{const{mapRef:r}=m(),n=new window.AMap.LabelsLayer(e.opts),t=()=>u.map(e.data,l=>{const M=new window.AMap.LabelMarker({...e.itemOpts,...l});return e.events&&u.forEach(e.events,f=>{M.on(f.type,f.handler,void 0,f.once)}),M}),c=()=>{n.clear();const l=t();n.add(l)};i.useEffect(()=>(u.size(e.data)>0&&c(),r.value.add(n),()=>{n.clear(),r.value.remove(n)}),[]),i.useWatch(()=>{c()},()=>e.data);const p=o.toRef(e,"show");return S(n,p),a({getFeature:()=>n}),()=>null}}),Ae=s("TileLayer",{useMapConnect:y}),we=s("TileLayer.Satellite",{useMapConnect:y,createFeatureObj:e=>new window.AMap.TileLayer.Satellite(e)}),Te=s("TileLayer.RoadNet",{useMapConnect:y,createFeatureObj:e=>new window.AMap.TileLayer.RoadNet(e)}),ge=s("TileLayer.Traffic",{useMapConnect:y,createFeatureObj:e=>new window.AMap.TileLayer.Traffic(e)}),Le=s("Buildings",{useMapConnect:y}),Se=s("MassMarks",{useMapConnect:_,createFeatureObj:e=>new window.AMap.MassMarks((e==null?void 0:e.data)||[],u.omit(e,"data"))}),Ee=s("TileLayer.Flexible",{useMapConnect:y,createFeatureObj:e=>new window.AMap.TileLayer.Flexible(e)}),be=s("ImageLayer",{useMapConnect:y}),Re=s("VideoLayer",{useMapConnect:y}),Fe=s("CanvasLayer",{useMapConnect:y}),Oe=s("CustomLayer",{useMapConnect:y,createFeatureObj:e=>new window.AMap.CustomLayer(e==null?void 0:e.canvas,u.omit(e,"canvas"))}),Pe=s("DistrictLayer.World",{useMapConnect:y,createFeatureObj:e=>new window.AMap.DistrictLayer.World(e)}),ke=s("DistrictLayer.Country",{useMapConnect:y,createFeatureObj:e=>new window.AMap.DistrictLayer.Country(e)}),Be=s("DistrictLayer.Province",{useMapConnect:y,createFeatureObj:e=>new window.AMap.DistrictLayer.Province(e)}),_e=s("HeatMap",{useMapConnect:_,createFeatureObj:e=>new window.AMap.HeatMap(null,e)}),De=w([A.HeatMap],_e),Ne=(e,a)=>{let r=!1,n=null;const[t,c]=i.useState(),p=o.ref(u.isBoolean(a.initEmit)?a.initEmit:!1),l=u.split(e,"_"),M=l[0],f=l[1],C=()=>{const v=u.get(window,M);return v?new v({...a.opts,...n==null?void 0:n.opts}):null},T=v=>v||(u.isFunction(a.params)?a.params():a.params||[]),d=()=>{if(!n)return;const v=C();if(!v||!u.isFunction(v[f]))return;const P=T(n.params);p.value=!0,v[f](...P,(b,L)=>{var D,N,j,G;c(L),(D=a.onComplete)==null||D.call(a,b,L),b==="complete"?(N=a.onSuccess)==null||N.call(a,L):b==="error"?(j=a.onFail)==null||j.call(a,L):b==="no_data"&&((G=a.onNoData)==null||G.call(a,L)),n=null,p.value=!1})};B([M],()=>{r=!0,d()});const O=(v,P)=>{n={opts:v||a.opts,params:T(P)},r&&d()};return i.useEffect(()=>{a.initEmit&&O()},[]),i.useWatch(()=>O(),a.deps||[]),{data:t,request:O,requesting:p}},je={Geocoder_getLocation:"AMap.Geocoder_getLocation",Geocoder_getAddress:"AMap.Geocoder_getAddress",Autocomplete_search:"AMap.Autocomplete_search",PlaceSearch_search:"AMap.PlaceSearch_search",PlaceSearch_searchNearBy:"AMap.PlaceSearch_searchNearBy",PlaceSearch_searchInBounds:"AMap.PlaceSearch_searchInBounds",PlaceSearch_getDetails:"AMap.PlaceSearch_getDetails",DistrictSearch_search:"AMap.DistrictSearch_search",LineSearch_search:"AMap.LineSearch_search",LineSearch_searchById:"AMap.LineSearch_searchById",StationSearch_search:"AMap.StationSearch_search",StationSearch_searchById:"AMap.StationSearch_searchById"};exports.ApiNames=je;exports.BezierCurve=ce;exports.Buildings=Le;exports.CanvasLayer=Fe;exports.Circle=re;exports.CircleMarker=X;exports.ControlBar=Ce;exports.CustomLayer=Oe;exports.DistrictLayerCountry=ke;exports.DistrictLayerProvince=Be;exports.DistrictLayerWorld=Pe;exports.ElasticMarker=Z;exports.Ellipse=oe;exports.HawkEye=de;exports.HeatMap=De;exports.ImageLayer=be;exports.InfoWindow=U;exports.LabelsLayer=he;exports.LayerGroup=ve;exports.Map=z;exports.MapEvents=I;exports.MapPlugin=H;exports.MapPluginType=A;exports.MapType=fe;exports.Marker=ee;exports.MassMarks=Se;exports.OverlayGroup=Q;exports.Polygon=ae;exports.Polyline=te;exports.Rectangle=ne;exports.Scale=le;exports.Text=Y;exports.TileLayer=Ae;exports.TileLayerFlexible=Ee;exports.TileLayerRoadNet=Te;exports.TileLayerSatellite=we;exports.TileLayerTraffic=ge;exports.ToolBar=ue;exports.VideoLayer=Re;exports.createFeature=s;exports.createPluginFeature=w;exports.provideMap=R;exports.useEvents=k;exports.useFeatureOptMethods=E;exports.useMap=m;exports.useMapApi=Ne;exports.useMapConnect=F;exports.useMapConnect2=_;exports.useMapControlConnect=g;exports.useMapLayerConnect=y;exports.useMapOverlayConnect=h;exports.useMapPlugin=B;exports.useShowConnect=S;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vue-start/map",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.6",
|
|
4
4
|
"description": "amap wrapper",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"amap"
|
|
@@ -30,5 +30,5 @@
|
|
|
30
30
|
"dependencies": {
|
|
31
31
|
"@amap/amap-jsapi-loader": "^1.0.1"
|
|
32
32
|
},
|
|
33
|
-
"gitHead": "
|
|
33
|
+
"gitHead": "da60ad3ea417c123ef11c3d385d447f0451a70c0"
|
|
34
34
|
}
|