vite-index.ts 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108
  1. /**
  2. * Author: yang jian fei
  3. * Email: 1294485765@qq.com
  4. * Created Date: Tuesday, September 20th 2022, 4:51:45 pm
  5. * Modified By: yang jian fei
  6. * Desc: desc
  7. * Copyright (c) 2022 黑发
  8. */
  9. import BaiduMap from './map/Map.vue'
  10. import BmScale from './controls/Scale.vue'
  11. import BmNavigation from './controls/Navigation.vue'
  12. import BmMapType from './controls/MapType.vue'
  13. import BmOverviewMap from './controls/OverviewMap.vue'
  14. import BmGeolocation from './controls/Geolocation.vue'
  15. import BmCopyright from './controls/Copyright.vue'
  16. import BmCityList from './controls/CityList.vue'
  17. import BmPanorama from './controls/Panorama.vue'
  18. import BmControl from './controls/Control.vue'
  19. import BmMarker from './overlays/Marker.vue'
  20. import BmPointCollection from './overlays/PointCollection.vue'
  21. import BmPolyline from './overlays/Polyline.vue'
  22. import BmPolygon from './overlays/Polygon.vue'
  23. import BmCircle from './overlays/Circle.vue'
  24. import BmGround from './overlays/Ground.vue'
  25. import BmLabel from './overlays/Label.vue'
  26. import BmInfoWindow from './overlays/InfoWindow.vue'
  27. import BmOverlay from './overlays/Overlay.vue'
  28. import BmContextMenu from './context-menu/Menu.vue'
  29. import BmContextMenuItem from './context-menu/Item.vue'
  30. import BmLocalSearch from './search/LocalSearch.vue'
  31. import BmTransit from './search/Transit.vue'
  32. import BmWalking from './search/Walking.vue'
  33. import BmDriving from './search/Driving.vue'
  34. import BmBus from './search/Bus.vue'
  35. import BmTile from './layers/Tile.vue'
  36. import BmTraffic from './layers/Traffic.vue'
  37. import BmBoundary from './others/Boundary.vue'
  38. import BmAutoComplete from './others/AutoComplete.vue'
  39. import BmlMarkerClusterer from './extra/MarkerClusterer.vue'
  40. import BmlLushu from './extra/Lushu.vue'
  41. import BmlHeatmap from './extra/Heatmap.vue'
  42. import BmlCurveLine from './extra/CurveLine.vue'
  43. import { setConfig, getConfig } from './base/util';
  44. import { getAddressByPoints, getPointByAddress, getPointsTransfer } from './utils';
  45. export default {
  46. install(Vue, options = {}) {
  47. setConfig(options);
  48. Vue.component('baidu-map', BaiduMap)
  49. Vue.component('bm-scale', BmScale)
  50. Vue.component('bm-navigation', BmNavigation)
  51. Vue.component('bm-map-type', BmMapType)
  52. Vue.component('bm-overview-map', BmOverviewMap)
  53. Vue.component('bm-geolocation', BmGeolocation)
  54. Vue.component('bm-copyright', BmCopyright)
  55. Vue.component('bm-city-list', BmCityList)
  56. Vue.component('bm-panorama', BmPanorama)
  57. Vue.component('bm-control', BmControl)
  58. Vue.component('bm-marker', BmMarker)
  59. Vue.component('bm-point-collection', BmPointCollection)
  60. Vue.component('bm-polyline', BmPolyline)
  61. Vue.component('bm-polygon', BmPolygon)
  62. Vue.component('bm-circle', BmCircle)
  63. Vue.component('bm-ground', BmGround)
  64. Vue.component('bm-label', BmLabel)
  65. Vue.component('bm-info-window', BmInfoWindow)
  66. Vue.component('bm-overlay', BmOverlay)
  67. Vue.component('bm-context-menu', BmContextMenu)
  68. Vue.component('bm-context-menu-item', BmContextMenuItem)
  69. Vue.component('bm-local-search', BmLocalSearch)
  70. Vue.component('bm-transit', BmTransit)
  71. Vue.component('bm-walking', BmWalking)
  72. Vue.component('bm-driving', BmDriving)
  73. Vue.component('bm-bus', BmBus)
  74. Vue.component('bm-tile', BmTile)
  75. Vue.component('bm-traffic', BmTraffic)
  76. Vue.component('bm-auto-complete', BmAutoComplete)
  77. Vue.component('bm-boundary', BmBoundary)
  78. }
  79. }
  80. export {
  81. BaiduMap,
  82. BmScale, BmNavigation, BmMapType, BmOverviewMap, BmGeolocation, BmCopyright, BmCityList, BmPanorama, BmControl,
  83. BmMarker, BmPointCollection, BmPolyline, BmPolygon, BmCircle, BmGround, BmLabel, BmInfoWindow, BmOverlay,
  84. BmContextMenu, BmContextMenuItem,
  85. BmLocalSearch, BmTransit, BmWalking, BmDriving, BmBus,
  86. BmTile, BmTraffic,
  87. BmBoundary, BmAutoComplete
  88. }
  89. export {
  90. getAddressByPoints,
  91. getPointByAddress,
  92. getPointsTransfer,
  93. getConfig
  94. }