@xingm/vmap-cesium-toolbar 0.0.7-alpha.1 → 0.0.7-alpha.2

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.
Files changed (255) hide show
  1. package/README.md +276 -0
  2. package/dist/hooks/toolBarConfig.d.ts +78 -0
  3. package/dist/hooks/useDrawHelper.d.ts +24 -0
  4. package/dist/hooks/useDynamicRing.d.ts +44 -0
  5. package/dist/hooks/useHeatmapHelper.d.ts +18 -0
  6. package/dist/hooks/useMap.d.ts +14 -0
  7. package/dist/hooks/useMapInit.d.ts +14 -0
  8. package/dist/hooks/useOverlayHelper.d.ts +48 -0
  9. package/dist/hooks/usePointClusterHelper.d.ts +14 -0
  10. package/dist/i18n/en-US.d.ts +148 -0
  11. package/dist/i18n/index.d.ts +3 -0
  12. package/dist/i18n/zh-CN.d.ts +148 -0
  13. package/{index.d.ts → dist/index.d.ts} +1 -0
  14. package/{index.es.js → dist/index.es.js} +513 -473
  15. package/dist/index.es.js.map +1 -0
  16. package/dist/index.umd.js +342 -0
  17. package/dist/index.umd.js.map +1 -0
  18. package/dist/libs/CesiumAutoRecover.d.ts +48 -0
  19. package/dist/libs/CesiumHeatmapLayer.d.ts +143 -0
  20. package/dist/libs/CesiumMapDraw.d.ts +251 -0
  21. package/dist/libs/CesiumMapLoader.d.ts +74 -0
  22. package/dist/libs/CesiumMapMark.d.ts +202 -0
  23. package/dist/libs/CesiumMapModel.d.ts +180 -0
  24. package/dist/libs/CesiumMapToolbar.d.ts +231 -0
  25. package/dist/libs/CesiumOverlayService.d.ts +227 -0
  26. package/dist/libs/CesiumPointClusterLayer.d.ts +93 -0
  27. package/dist/libs/PickGovernor.d.ts +23 -0
  28. package/dist/libs/config/CesiumMapConfig.d.ts +13 -0
  29. package/dist/libs/drawHelper/BaseDraw.d.ts +194 -0
  30. package/dist/libs/drawHelper/DrawCircle.d.ts +31 -0
  31. package/dist/libs/drawHelper/DrawHint.d.ts +32 -0
  32. package/dist/libs/drawHelper/DrawLine.d.ts +49 -0
  33. package/dist/libs/drawHelper/DrawPolgon.d.ts +35 -0
  34. package/dist/libs/drawHelper/DrawRectangle.d.ts +24 -0
  35. package/dist/libs/drawHelper/index.d.ts +6 -0
  36. package/dist/libs/i18n/en-US.d.ts +69 -0
  37. package/dist/libs/i18n/index.d.ts +25 -0
  38. package/dist/libs/i18n/zh-CN.d.ts +69 -0
  39. package/dist/libs/overlay/MapCircle.d.ts +130 -0
  40. package/dist/libs/overlay/MapIcon.d.ts +69 -0
  41. package/dist/libs/overlay/MapInfoWindow.d.ts +100 -0
  42. package/dist/libs/overlay/MapLabel.d.ts +73 -0
  43. package/dist/libs/overlay/MapMarker.d.ts +60 -0
  44. package/dist/libs/overlay/MapPolygon.d.ts +114 -0
  45. package/dist/libs/overlay/MapPolyline.d.ts +64 -0
  46. package/dist/libs/overlay/MapRectangle.d.ts +101 -0
  47. package/dist/libs/overlay/MapRing.d.ts +107 -0
  48. package/dist/libs/overlay/MapSVG.d.ts +73 -0
  49. package/dist/libs/overlay/OverlayEditController.d.ts +167 -0
  50. package/dist/libs/overlay/OverlayEditHandles.d.ts +101 -0
  51. package/dist/libs/overlay/OverlayHighlight.d.ts +40 -0
  52. package/dist/libs/overlay/index.d.ts +23 -0
  53. package/dist/libs/overlay/primitives/CirclePrimitiveBatch.d.ts +42 -0
  54. package/dist/libs/overlay/primitives/CirclePrimitiveLayerStack.d.ts +24 -0
  55. package/dist/libs/overlay/primitives/PolygonPrimitiveBatch.d.ts +43 -0
  56. package/dist/libs/overlay/primitives/PolygonPrimitiveLayerStack.d.ts +24 -0
  57. package/dist/libs/overlay/primitives/RectanglePrimitiveBatch.d.ts +41 -0
  58. package/dist/libs/overlay/primitives/RectanglePrimitiveLayerStack.d.ts +24 -0
  59. package/dist/libs/overlay/types.d.ts +121 -0
  60. package/dist/libs/toolBar/CesiumMapController.d.ts +87 -0
  61. package/dist/libs/toolBar/MapLayersService.d.ts +98 -0
  62. package/dist/libs/toolBar/MapSearchService.d.ts +51 -0
  63. package/dist/libs/toolBar/MapToolBarConfig.d.ts +10 -0
  64. package/dist/libs/toolBar/MeasurementService.d.ts +16 -0
  65. package/dist/libs/toolBar/NotFlyZonesService.d.ts +51 -0
  66. package/dist/package.json +46 -0
  67. package/dist/tdt/tdtAuth.d.ts +1 -0
  68. package/dist/tdt/tdtController.d.ts +16 -0
  69. package/dist/tdt/tdtPlugin.d.ts +14 -0
  70. package/dist/tdt/tdtProviders.d.ts +4 -0
  71. package/dist/tdt3dplug.es-pUYPBBmH.js +5264 -0
  72. package/dist/tdt3dplug.es-pUYPBBmH.js.map +1 -0
  73. package/dist/utils/calc.d.ts +50 -0
  74. package/dist/utils/common.d.ts +15 -0
  75. package/dist/utils/geojson.d.ts +86 -0
  76. package/dist/utils/overlayUtils.d.ts +149 -0
  77. package/dist/utils/selfIntersection.d.ts +15 -0
  78. package/dist/z.const.d.ts +24 -0
  79. package/package.json +74 -46
  80. package/index.umd.js +0 -337
  81. /package/{geojson → dist/geojson}/file-list.json +0 -0
  82. /package/{geojson → dist/geojson}//344/270/207/345/267/236_/344/272/224/346/241/245/346/234/272/345/234/272.geojson" +0 -0
  83. /package/{geojson → dist/geojson}//344/270/211/344/272/232_/345/207/244/345/207/260/346/234/272/345/234/272.geojson" +0 -0
  84. /package/{geojson → dist/geojson}//344/270/211/346/230/216_/346/262/231/345/216/277/346/234/272/345/234/272.geojson" +0 -0
  85. /package/{geojson → dist/geojson}//344/270/212/346/265/267_/346/265/246/344/270/234/346/234/272/345/234/272.geojson" +0 -0
  86. /package/{geojson → dist/geojson}//344/270/212/346/265/267_/350/231/271/346/241/245/346/234/272/345/234/272.geojson" +0 -0
  87. /package/{geojson → dist/geojson}//344/270/212/351/245/266_/344/270/211/346/270/205/345/261/261/346/234/272/345/234/272.geojson" +0 -0
  88. /package/{geojson → dist/geojson}//344/270/224/346/234/253_/347/216/211/351/203/275/346/234/272/345/234/272.geojson" +0 -0
  89. /package/{geojson → dist/geojson}//344/270/234/350/220/245/346/234/272/345/234/272.geojson" +0 -0
  90. /package/{geojson → dist/geojson}//344/270/255/345/215/253_/346/262/231/345/235/241/345/244/264/346/234/272/345/234/272.geojson" +0 -0
  91. /package/{geojson → dist/geojson}//344/270/264/346/261/276_/344/271/224/346/235/216/346/234/272/345/234/272.geojson" +0 -0
  92. /package/{geojson → dist/geojson}//344/270/264/346/262/202_/346/262/255/345/237/240/345/262/255/346/234/272/345/234/272.geojson" +0 -0
  93. /package/{geojson → dist/geojson}//344/270/264/346/262/247_/345/215/232/345/260/232/346/234/272/345/234/272.geojson" +0 -0
  94. /package/{geojson → dist/geojson}//344/270/271/344/270/234_/346/265/252/345/244/264/346/234/272/345/234/272.geojson" +0 -0
  95. /package/{geojson → dist/geojson}//344/270/275/346/261/237_/344/270/211/344/271/211/346/234/272/345/234/272.geojson" +0 -0
  96. /package/{geojson → dist/geojson}//344/271/211/344/271/214/346/234/272/345/234/272.geojson" +0 -0
  97. /package/{geojson → dist/geojson}//344/271/214/345/205/260/345/257/237/345/270/203_/351/233/206/345/256/201/346/234/272/345/234/272.geojson" +0 -0
  98. /package/{geojson → dist/geojson}//344/271/214/345/205/260/346/265/251/347/211/271_/344/276/235/345/213/222/345/212/233/347/211/271/346/234/272/345/234/272.geojson" +0 -0
  99. /package/{geojson → dist/geojson}//344/271/214/346/265/267/346/234/272/345/234/272.geojson" +0 -0
  100. /package/{geojson → dist/geojson}//344/271/214/351/262/201/346/234/250/351/275/220_/345/234/260/347/252/235/345/240/241/346/234/272/345/234/272.geojson" +0 -0
  101. /package/{geojson → dist/geojson}//344/272/214/350/277/236/346/265/251/347/211/271_/350/265/233/344/271/214/347/264/240/346/234/272/345/234/272.geojson" +0 -0
  102. /package/{geojson → dist/geojson}//344/272/225/345/206/210/345/261/261/346/234/272/345/234/272.geojson" +0 -0
  103. /package/{geojson → dist/geojson}//344/274/212/345/256/201/346/234/272/345/234/272.geojson" +0 -0
  104. /package/{geojson → dist/geojson}//344/274/212/346/230/245_/346/236/227/351/203/275/346/234/272/345/234/272.geojson" +0 -0
  105. /package/{geojson → dist/geojson}//344/275/263/346/234/250/346/226/257/346/234/272/345/234/272.geojson" +0 -0
  106. /package/{geojson → dist/geojson}//344/277/235/345/261/261/346/234/272/345/234/272.geojson" +0 -0
  107. /package/{geojson → dist/geojson}//345/205/213/346/213/211/347/216/233/344/276/235/346/234/272/345/234/272.geojson" +0 -0
  108. /package/{geojson → dist/geojson}//345/205/260/345/267/236_/344/270/255/345/267/235/346/234/272/345/234/272.geojson" +0 -0
  109. /package/{geojson → dist/geojson}//345/205/264/344/271/211_/344/270/207/345/263/260/346/236/227/346/234/272/345/234/272.geojson" +0 -0
  110. /package/{geojson → dist/geojson}//345/212/240/346/240/274/350/276/276/345/245/207_/345/230/216/344/273/231/346/234/272/345/234/272.geojson" +0 -0
  111. /package/{geojson → dist/geojson}//345/214/205/345/244/264/346/234/272/345/234/272.geojson" +0 -0
  112. /package/{geojson → dist/geojson}//345/214/227/344/272/254_/351/246/226/351/203/275/346/234/272/345/234/272.geojson" +0 -0
  113. /package/{geojson → dist/geojson}//345/214/227/346/265/267_/347/246/217/346/210/220/346/234/272/345/234/272.geojson" +0 -0
  114. /package/{geojson → dist/geojson}//345/215/201/345/240/260_/346/255/246/345/275/223/345/261/261/346/234/272/345/234/272.geojson" +0 -0
  115. /package/{geojson → dist/geojson}//345/215/227/344/272/254_/347/246/204/345/217/243/346/234/272/345/234/272.geojson" +0 -0
  116. /package/{geojson → dist/geojson}//345/215/227/345/256/201_/345/220/264/345/234/251/346/234/272/345/234/272.geojson" +0 -0
  117. /package/{geojson → dist/geojson}//345/215/227/346/230/214_/346/230/214/345/214/227/346/234/272/345/234/272.geojson" +0 -0
  118. /package/{geojson → dist/geojson}//345/215/227/351/200/232_/345/205/264/344/270/234/346/234/272/345/234/272.geojson" +0 -0
  119. /package/{geojson → dist/geojson}//345/215/227/351/230/263_/345/247/234/350/220/245/346/234/272/345/234/272.geojson" +0 -0
  120. /package/{geojson → dist/geojson}//345/215/232/344/271/220_/351/230/277/346/213/211/345/261/261/345/217/243/346/234/272/345/234/272.geojson" +0 -0
  121. /package/{geojson → dist/geojson}//345/216/246/351/227/250_/351/253/230/345/264/216/346/234/272/345/234/272.geojson" +0 -0
  122. /package/{geojson → dist/geojson}//345/217/260/345/267/236_/350/267/257/346/241/245/346/234/272/345/234/272.geojson" +0 -0
  123. /package/{geojson → dist/geojson}//345/220/210/350/202/245_/346/226/260/346/241/245/346/234/272/345/234/272.geojson" +0 -0
  124. /package/{geojson → dist/geojson}//345/220/220/351/262/201/347/225/252_/344/272/244/346/262/263/346/234/272/345/234/272.geojson" +0 -0
  125. /package/{geojson → dist/geojson}//345/221/274/344/274/246/350/264/235/345/260/224_/346/265/267/346/213/211/345/260/224/346/234/272/345/234/272.geojson" +0 -0
  126. /package/{geojson → dist/geojson}//345/221/274/345/222/214/346/265/251/347/211/271_/347/231/275/345/241/224/346/234/272/345/234/272.geojson" +0 -0
  127. /package/{geojson → dist/geojson}//345/222/214/347/224/260/346/234/272/345/234/272.geojson" +0 -0
  128. /package/{geojson → dist/geojson}//345/223/210/345/260/224/346/273/250_/345/244/252/345/271/263/346/234/272/345/234/272.geojson" +0 -0
  129. /package/{geojson → dist/geojson}//345/224/220/345/261/261_/344/270/211/345/245/263/346/262/263/346/234/272/345/234/272.geojson" +0 -0
  130. /package/{geojson → dist/geojson}//345/226/200/344/273/200/346/234/272/345/234/272.geojson" +0 -0
  131. /package/{geojson → dist/geojson}//345/230/211/345/263/252/345/205/263/346/234/272/345/234/272.geojson" +0 -0
  132. /package/{geojson → dist/geojson}//345/233/272/345/216/237_/345/205/255/347/233/230/345/261/261/346/234/272/345/234/272.geojson" +0 -0
  133. /package/{geojson → dist/geojson}//345/241/224/345/237/216/346/234/272/345/234/272.geojson" +0 -0
  134. /package/{geojson → dist/geojson}//345/244/247/345/220/214_/344/272/221/345/206/210/346/234/272/345/234/272.geojson" +0 -0
  135. /package/{geojson → dist/geojson}//345/244/247/345/272/206_/350/220/250/345/260/224/345/233/276/346/234/272/345/234/272.geojson" +0 -0
  136. /package/{geojson → dist/geojson}//345/244/247/350/277/236_/345/221/250/346/260/264/345/255/220/346/234/272/345/234/272.geojson" +0 -0
  137. /package/{geojson → dist/geojson}//345/244/251/346/264/245_/346/273/250/346/265/267/346/234/272/345/234/272.geojson" +0 -0
  138. /package/{geojson → dist/geojson}//345/244/252/345/216/237_/346/255/246/345/256/277/346/234/272/345/234/272.geojson" +0 -0
  139. /package/{geojson → dist/geojson}//345/256/201/346/263/242_/346/240/216/347/244/276/346/234/272/345/234/272.geojson" +0 -0
  140. /package/{geojson → dist/geojson}//345/256/201/350/222/227_/346/263/270/346/262/275/346/271/226/346/234/272/345/234/272.geojson" +0 -0
  141. /package/{geojson → dist/geojson}//345/256/211/345/272/206/346/234/272/345/234/272.geojson" +0 -0
  142. /package/{geojson → dist/geojson}//345/256/234/345/256/276_/350/217/234/345/235/235/346/234/272/345/234/272.geojson" +0 -0
  143. /package/{geojson → dist/geojson}//345/256/234/346/230/214_/344/270/211/345/263/241/346/234/272/345/234/272.geojson" +0 -0
  144. /package/{geojson → dist/geojson}//345/256/234/346/230/245_/346/230/216/346/234/210/345/261/261/346/234/272/345/234/272.geojson" +0 -0
  145. /package/{geojson → dist/geojson}//345/257/214/350/225/264_/345/217/257/345/217/257/346/211/230/346/265/267/346/234/272/345/234/272.geojson" +0 -0
  146. /package/{geojson → dist/geojson}//345/267/264/345/275/246/346/267/226/345/260/224_/345/244/251/345/220/211/346/263/260/346/234/272/345/234/272.geojson" +0 -0
  147. /package/{geojson → dist/geojson}//345/270/203/345/260/224/346/264/245_/345/226/200/347/272/263/346/226/257/346/234/272/345/234/272.geojson" +0 -0
  148. /package/{geojson → dist/geojson}//345/270/270/345/267/236_/345/245/224/347/211/233/346/234/272/345/234/272.geojson" +0 -0
  149. /package/{geojson → dist/geojson}//345/270/270/345/276/267_/346/241/203/350/212/261/346/272/220/346/234/272/345/234/272.geojson" +0 -0
  150. /package/{geojson → dist/geojson}//345/271/277/345/205/203_/347/233/230/351/276/231/346/234/272/345/234/272.geojson" +0 -0
  151. /package/{geojson → dist/geojson}//345/271/277/345/267/236_/347/231/275/344/272/221/346/234/272/345/234/272.geojson" +0 -0
  152. /package/{geojson → dist/geojson}//345/272/206/351/230/263_/350/245/277/345/263/260/346/234/272/345/234/272.geojson" +0 -0
  153. /package/{geojson → dist/geojson}//345/272/223/350/275/246_/351/276/237/345/205/271/346/234/272/345/234/272.geojson" +0 -0
  154. /package/{geojson → dist/geojson}//345/272/267/345/256/232/346/234/272/345/234/272.geojson" +0 -0
  155. /package/{geojson → dist/geojson}//345/273/266/345/220/211_/346/234/235/351/230/263/345/267/235/346/234/272/345/234/272.geojson" +0 -0
  156. /package/{geojson → dist/geojson}//345/274/240/345/256/266/347/225/214_/350/215/267/350/212/261/346/234/272/345/234/272.geojson" +0 -0
  157. /package/{geojson → dist/geojson}//345/274/240/346/216/226_/347/224/230/345/267/236/346/234/272/345/234/272.geojson" +0 -0
  158. /package/{geojson → dist/geojson}//345/276/220/345/267/236_/350/247/202/351/237/263/346/234/272/345/234/272.geojson" +0 -0
  159. /package/{geojson → dist/geojson}//345/276/267/345/256/217_/350/212/222/345/270/202/346/234/272/345/234/272.geojson" +0 -0
  160. /package/{geojson → dist/geojson}//345/277/273/345/267/236_/344/272/224/345/217/260/345/261/261/346/234/272/345/234/272.geojson" +0 -0
  161. /package/{geojson → dist/geojson}//346/200/200/345/214/226_/350/212/267/346/261/237/346/234/272/345/234/272.geojson" +0 -0
  162. /package/{geojson → dist/geojson}//346/201/251/346/226/275_/350/256/270/345/256/266/345/235/252/346/234/272/345/234/272.geojson" +0 -0
  163. /package/{geojson → dist/geojson}//346/210/220/351/203/275_/345/217/214/346/265/201/346/234/272/345/234/272.geojson" +0 -0
  164. /package/{geojson → dist/geojson}//346/211/216/345/205/260/345/261/257_/346/210/220/345/220/211/346/200/235/346/261/227/346/234/272/345/234/272.geojson" +0 -0
  165. /package/{geojson → dist/geojson}//346/211/254/345/267/236_/346/263/260/345/267/236/346/234/272/345/234/272.geojson" +0 -0
  166. /package/{geojson → dist/geojson}//346/212/232/350/277/234_/344/270/234/346/236/201/346/234/272/345/234/272.geojson" +0 -0
  167. /package/{geojson → dist/geojson}//346/217/255/351/230/263_/346/275/256/346/261/225/346/234/272/345/234/272.geojson" +0 -0
  168. /package/{geojson → dist/geojson}//346/224/200/346/236/235/350/212/261_/344/277/235/345/256/211/350/220/245/346/234/272/345/234/272.geojson" +0 -0
  169. /package/{geojson → dist/geojson}//346/225/246/347/205/214/346/234/272/345/234/272.geojson" +0 -0
  170. /package/{geojson → dist/geojson}//346/226/260/346/272/220_/351/202/243/346/213/211/346/217/220/346/234/272/345/234/272.geojson" +0 -0
  171. /package/{geojson → dist/geojson}//346/227/245/347/205/247_/345/261/261/345/255/227/346/262/263/346/234/272/345/234/272.geojson" +0 -0
  172. /package/{geojson → dist/geojson}//346/230/206/346/230/216_/351/225/277/346/260/264/346/234/272/345/234/272.geojson" +0 -0
  173. /package/{geojson → dist/geojson}//346/231/256/346/264/261_/346/200/235/350/214/205/346/234/272/345/234/272.geojson" +0 -0
  174. /package/{geojson → dist/geojson}//346/231/257/345/276/267/351/225/207_/347/275/227/345/256/266/346/234/272/345/234/272.geojson" +0 -0
  175. /package/{geojson → dist/geojson}//346/234/235/351/230/263/346/234/272/345/234/272.geojson" +0 -0
  176. /package/{geojson → dist/geojson}//346/235/255/345/267/236_/350/220/247/345/261/261/346/234/272/345/234/272.geojson" +0 -0
  177. /package/{geojson → dist/geojson}//346/236/234/346/264/233_/347/216/233/346/262/201/346/234/272/345/234/272.geojson" +0 -0
  178. /package/{geojson → dist/geojson}//346/237/263/345/267/236_/347/231/275/350/216/262/346/234/272/345/234/272.geojson" +0 -0
  179. /package/{geojson → dist/geojson}//346/241/202/346/236/227_/344/270/244/346/261/237/346/234/272/345/234/272.geojson" +0 -0
  180. /package/{geojson → dist/geojson}//346/242/205/345/216/277_/351/225/277/345/262/227/345/262/214/346/234/272/345/234/272.geojson" +0 -0
  181. /package/{geojson → dist/geojson}//346/242/247/345/267/236/346/234/272/345/234/272.geojson" +0 -0
  182. /package/{geojson → dist/geojson}//346/246/206/346/236/227_/346/246/206/351/230/263/346/234/272/345/234/272.geojson" +0 -0
  183. /package/{geojson → dist/geojson}//346/255/246/346/261/211_/345/244/251/346/262/263/346/234/272/345/234/272.geojson" +0 -0
  184. /package/{geojson → dist/geojson}//346/260/270/345/267/236_/351/233/266/351/231/265/346/234/272/345/234/272.geojson" +0 -0
  185. /package/{geojson → dist/geojson}//346/261/211/344/270/255_/345/237/216/345/233/272/346/234/272/345/234/272.geojson" +0 -0
  186. /package/{geojson → dist/geojson}//346/261/240/345/267/236_/344/271/235/345/215/216/345/261/261/346/234/272/345/234/272.geojson" +0 -0
  187. /package/{geojson → dist/geojson}//346/262/210/351/230/263_/346/241/203/344/273/231/346/234/272/345/234/272.geojson" +0 -0
  188. /package/{geojson → dist/geojson}//346/262/263/346/261/240_/351/207/221/345/237/216/346/261/237/346/234/272/345/234/272.geojson" +0 -0
  189. /package/{geojson → dist/geojson}//346/263/211/345/267/236_/346/231/213/346/261/237/346/234/272/345/234/272.geojson" +0 -0
  190. /package/{geojson → dist/geojson}//346/264/233/351/230/263/346/234/272/345/234/272.geojson" +0 -0
  191. /package/{geojson → dist/geojson}//346/265/216/345/215/227_/351/201/245/345/242/231/346/234/272/345/234/272.geojson" +0 -0
  192. /package/{geojson → dist/geojson}//346/265/216/345/256/201_/346/233/262/351/230/234/346/234/272/345/234/272.geojson" +0 -0
  193. /package/{geojson → dist/geojson}//346/265/267/345/217/243_/347/276/216/345/205/260/346/234/272/345/234/272.geojson" +0 -0
  194. /package/{geojson → dist/geojson}//346/265/267/350/245/277_/345/276/267/344/273/244/345/223/210/346/234/272/345/234/272.geojson" +0 -0
  195. /package/{geojson → dist/geojson}//346/265/267/350/245/277_/350/212/261/345/234/237/346/262/237/346/234/272/345/234/272.geojson" +0 -0
  196. /package/{geojson → dist/geojson}//346/267/256/345/256/211_/346/266/237/346/260/264/346/234/272/345/234/272.geojson" +0 -0
  197. /package/{geojson → dist/geojson}//346/267/261/345/234/263_/345/256/235/345/256/211/346/234/272/345/234/272.geojson" +0 -0
  198. /package/{geojson → dist/geojson}//346/270/251/345/267/236_/351/276/231/346/271/276/346/234/272/345/234/272.geojson" +0 -0
  199. /package/{geojson → dist/geojson}//346/271/233/346/261/237/346/234/272/345/234/272.geojson" +0 -0
  200. /package/{geojson → dist/geojson}//346/273/241/346/264/262/351/207/214_/350/245/277/351/203/212/346/234/272/345/234/272.geojson" +0 -0
  201. /package/{geojson → dist/geojson}//346/274/240/346/262/263_/345/217/244/350/216/262/346/234/272/345/234/272.geojson" +0 -0
  202. /package/{geojson → dist/geojson}//346/275/215/345/235/212/346/234/272/345/234/272.geojson" +0 -0
  203. /package/{geojson → dist/geojson}//346/276/234/346/262/247_/346/231/257/350/277/210/346/234/272/345/234/272.geojson" +0 -0
  204. /package/{geojson → dist/geojson}//347/203/237/345/217/260_/350/223/254/350/216/261/346/234/272/345/234/272.geojson" +0 -0
  205. /package/{geojson → dist/geojson}//347/211/241/344/270/271/346/261/237_/346/265/267/346/265/252/346/234/272/345/234/272.geojson" +0 -0
  206. /package/{geojson → dist/geojson}//347/216/211/346/240/221_/345/267/264/345/241/230/346/234/272/345/234/272.geojson" +0 -0
  207. /package/{geojson → dist/geojson}//347/217/240/346/265/267_/351/207/221/346/271/276/346/234/272/345/234/272.geojson" +0 -0
  208. /package/{geojson → dist/geojson}//347/220/274/346/265/267_/345/215/232/351/263/214/346/234/272/345/234/272.geojson" +0 -0
  209. /package/{geojson → dist/geojson}//347/224/230/345/215/227_/345/244/217/346/262/263/346/234/272/345/234/272.geojson" +0 -0
  210. /package/{geojson → dist/geojson}//347/231/275/345/237/216_/351/225/277/345/256/211/346/234/272/345/234/272.geojson" +0 -0
  211. /package/{geojson → dist/geojson}//347/231/275/345/261/261_/351/225/277/347/231/275/345/261/261/346/234/272/345/234/272.geojson" +0 -0
  212. /package/{geojson → dist/geojson}//347/231/276/350/211/262_/345/267/264/351/251/254/346/234/272/345/234/272.geojson" +0 -0
  213. /package/{geojson → dist/geojson}//347/237/263/345/256/266/345/272/204_/346/255/243/345/256/232/346/234/272/345/234/272.geojson" +0 -0
  214. /package/{geojson → dist/geojson}//347/237/263/346/262/263/345/255/220_/350/212/261/345/233/255/346/234/272/345/234/272.geojson" +0 -0
  215. /package/{geojson → dist/geojson}//347/245/236/345/206/234/346/236/266_/347/272/242/345/235/252/346/234/272/345/234/272.geojson" +0 -0
  216. /package/{geojson → dist/geojson}//347/246/217/345/267/236_/351/225/277/344/271/220/346/234/272/345/234/272.geojson" +0 -0
  217. /package/{geojson → dist/geojson}//347/247/246/347/232/207/345/262/233_/345/214/227/346/210/264/346/262/263/346/234/272/345/234/272.geojson" +0 -0
  218. /package/{geojson → dist/geojson}//347/250/273/345/237/216_/344/272/232/344/270/201/346/234/272/345/234/272.geojson" +0 -0
  219. /package/{geojson → dist/geojson}//350/205/276/345/206/262_/351/251/274/345/263/260/346/234/272/345/234/272.geojson" +0 -0
  220. /package/{geojson → dist/geojson}//350/220/245/345/217/243_/345/205/260/346/227/227/346/234/272/345/234/272.geojson" +0 -0
  221. /package/{geojson → dist/geojson}//350/241/241/351/230/263_/345/215/227/345/262/263/346/234/272/345/234/272.geojson" +0 -0
  222. /package/{geojson → dist/geojson}//350/241/242/345/267/236/346/234/272/345/234/272.geojson" +0 -0
  223. /package/{geojson → dist/geojson}//350/245/204/351/230/263_/345/210/230/351/233/206/346/234/272/345/234/272.geojson" +0 -0
  224. /package/{geojson → dist/geojson}//350/245/277/345/217/214/347/211/210/347/272/263_/345/230/216/346/264/222/346/234/272/345/234/272.geojson" +0 -0
  225. /package/{geojson → dist/geojson}//350/245/277/345/256/201_/346/233/271/345/256/266/345/240/241/346/234/272/345/234/272.geojson" +0 -0
  226. /package/{geojson → dist/geojson}//350/245/277/345/256/211_/345/222/270/351/230/263/346/234/272/345/234/272.geojson" +0 -0
  227. /package/{geojson → dist/geojson}//350/245/277/346/230/214_/351/235/222/345/261/261/346/234/272/345/234/272.geojson" +0 -0
  228. /package/{geojson → dist/geojson}//350/264/265/351/230/263_/351/276/231/346/264/236/345/240/241/346/234/272/345/234/272.geojson" +0 -0
  229. /package/{geojson → dist/geojson}//350/265/243/345/267/236_/351/273/204/351/207/221/346/234/272/345/234/272.geojson" +0 -0
  230. /package/{geojson → dist/geojson}//350/265/244/345/263/260_/347/216/211/351/276/231/346/234/272/345/234/272.geojson" +0 -0
  231. /package/{geojson → dist/geojson}//350/276/276/345/267/236_/346/262/263/345/270/202/346/234/272/345/234/272.geojson" +0 -0
  232. /package/{geojson → dist/geojson}//350/277/236/344/272/221/346/270/257_/347/231/275/345/241/224/345/237/240/346/234/272/345/234/272.geojson" +0 -0
  233. /package/{geojson → dist/geojson}//351/200/232/345/214/226_/344/270/211/346/272/220/346/265/246/346/234/272/345/234/272.geojson" +0 -0
  234. /package/{geojson → dist/geojson}//351/203/221/345/267/236_/346/226/260/351/203/221/346/234/272/345/234/272.geojson" +0 -0
  235. /package/{geojson → dist/geojson}//351/204/202/345/260/224/345/244/232/346/226/257_/344/274/212/351/207/221/351/234/215/346/264/233/346/234/272/345/234/272.geojson" +0 -0
  236. /package/{geojson → dist/geojson}//351/207/215/345/272/206_/346/261/237/345/214/227/346/234/272/345/234/272.geojson" +0 -0
  237. /package/{geojson → dist/geojson}//351/207/221/346/230/214_/351/207/221/345/267/235/346/234/272/345/234/272.geojson" +0 -0
  238. /package/{geojson → dist/geojson}//351/223/234/344/273/201_/345/207/244/345/207/260/346/234/272/345/234/272.geojson" +0 -0
  239. /package/{geojson → dist/geojson}//351/223/266/345/267/235_/346/262/263/344/270/234/346/234/272/345/234/272.geojson" +0 -0
  240. /package/{geojson → dist/geojson}//351/224/241/346/236/227/346/265/251/347/211/271/346/234/272/345/234/272.geojson" +0 -0
  241. /package/{geojson → dist/geojson}//351/224/246/345/267/236_/351/224/246/345/267/236/346/271/276/346/234/272/345/234/272.geojson" +0 -0
  242. /package/{geojson → dist/geojson}//351/225/277/346/230/245_/351/276/231/345/230/211/346/234/272/345/234/272.geojson" +0 -0
  243. /package/{geojson → dist/geojson}//351/225/277/346/262/231_/351/273/204/350/212/261/346/234/272/345/234/272.geojson" +0 -0
  244. /package/{geojson → dist/geojson}//351/230/277/345/205/213/350/213/217_/346/270/251/345/256/277/346/234/272/345/234/272.geojson" +0 -0
  245. /package/{geojson → dist/geojson}//351/230/277/345/213/222/346/263/260/346/234/272/345/234/272.geojson" +0 -0
  246. /package/{geojson → dist/geojson}//351/230/277/345/260/224/345/261/261_/344/274/212/345/260/224/346/226/275/346/234/272/345/234/272.geojson" +0 -0
  247. /package/{geojson → dist/geojson}//351/235/222/345/262/233_/346/265/201/344/272/255/346/234/272/345/234/272.geojson" +0 -0
  248. /package/{geojson → dist/geojson}//351/236/215/345/261/261_/350/205/276/351/263/214/346/234/272/345/234/272.geojson" +0 -0
  249. /package/{geojson → dist/geojson}//351/270/241/350/245/277_/345/205/264/345/207/257/346/271/226/346/234/272/345/234/272.geojson" +0 -0
  250. /package/{geojson → dist/geojson}//351/273/204/345/261/261_/345/261/257/346/272/252/346/234/272/345/234/272.geojson" +0 -0
  251. /package/{geojson → dist/geojson}//351/273/216/345/271/263/346/234/272/345/234/272.geojson" +0 -0
  252. /package/{geojson → dist/geojson}//351/273/221/346/262/263_/347/221/267/347/217/262/346/234/272/345/234/272.geojson" +0 -0
  253. /package/{geojson → dist/geojson}//351/273/224/346/261/237_/346/255/246/351/231/265/345/261/261/346/234/272/345/234/272.geojson" +0 -0
  254. /package/{geojson → dist/geojson}//351/275/220/351/275/220/345/223/210/345/260/224_/344/270/211/345/256/266/345/255/220/346/234/272/345/234/272.geojson" +0 -0
  255. /package/{style.css → dist/style.css} +0 -0
@@ -0,0 +1,202 @@
1
+ import { CesiumOverlayService } from './CesiumOverlayService';
2
+ import { default as DrawHelper } from './CesiumMapDraw';
3
+ import { DrawOptions } from './drawHelper/BaseDraw';
4
+ import { LngLatPosition } from '../utils/overlayUtils';
5
+ import * as Cesium from "cesium";
6
+ export type CesiumMapDrawType = "point" | "polyline" | "polygon" | "rectangle" | "circle";
7
+ export type CesiumMapWorkAreaType = "polygon" | "circle" | "rectangle";
8
+ export type CesiumMapWorkAreaKind = "work" | "noFly";
9
+ export interface CesiumMapMarkToolbarPosition {
10
+ left?: number | string;
11
+ right?: number | string;
12
+ top?: number | string;
13
+ bottom?: number | string;
14
+ }
15
+ export interface CesiumMapDrawResult {
16
+ drawType: CesiumMapDrawType;
17
+ positions: LngLatPosition[];
18
+ cartesian3Positions: Cesium.Cartesian3[];
19
+ position?: LngLatPosition;
20
+ entity: Cesium.Entity | null;
21
+ length?: number;
22
+ area?: number;
23
+ radius?: number;
24
+ color?: string;
25
+ }
26
+ export interface CesiumMapWorkAreaDrawResult extends Omit<CesiumMapDrawResult, "drawType"> {
27
+ drawType: CesiumMapWorkAreaType;
28
+ areaType: CesiumMapWorkAreaKind;
29
+ }
30
+ export interface CesiumMapMarkOptions extends DrawOptions {
31
+ pointWidth?: number;
32
+ pointHeight?: number;
33
+ continuous?: boolean;
34
+ showPolylineLengthLabel?: boolean;
35
+ showToolbar?: boolean;
36
+ toolbarClassName?: string;
37
+ toolbarPosition?: CesiumMapMarkToolbarPosition;
38
+ buttonSize?: number;
39
+ buttonSpacing?: number;
40
+ zIndex?: number;
41
+ defaultColor?: string;
42
+ colors?: Partial<Record<CesiumMapDrawType, string>>;
43
+ overlayServiceOptions?: ConstructorParameters<typeof CesiumOverlayService>[1];
44
+ buttons?: CesiumMapMarkButtonConfig[];
45
+ }
46
+ export interface CesiumMapMarkCallbacks {
47
+ onDrawStart?: (drawType: CesiumMapDrawType) => void;
48
+ onDrawEnd?: (result: CesiumMapDrawResult) => void;
49
+ onWorkAreaDrawEnd?: (result: CesiumMapWorkAreaDrawResult) => void;
50
+ onClear?: () => void;
51
+ onDelete?: (entity: Cesium.Entity) => void;
52
+ onEditChange?: (entity: Cesium.Entity) => void;
53
+ onEditEnd?: (result: CesiumMapDrawResult) => void;
54
+ onColorChange?: (color: string, drawType?: CesiumMapDrawType) => void;
55
+ onError?: (error: Error) => void;
56
+ }
57
+ export interface CesiumMapMarkExportItem {
58
+ id?: string;
59
+ drawType: CesiumMapDrawType;
60
+ positions: LngLatPosition[];
61
+ position?: LngLatPosition;
62
+ length?: number;
63
+ area?: number;
64
+ radius?: number;
65
+ color?: string;
66
+ entity: Cesium.Entity;
67
+ }
68
+ export interface CesiumMapMarkButtonConfig {
69
+ id: CesiumMapDrawType;
70
+ title?: string;
71
+ text?: string;
72
+ icon?: string | HTMLElement | false;
73
+ color?: string;
74
+ borderColor?: string;
75
+ backgroundColor?: string;
76
+ activeBackgroundColor?: string;
77
+ callback?: (mark: CesiumMapMark, drawType: CesiumMapDrawType) => void;
78
+ }
79
+ export declare class CesiumMapMark {
80
+ private viewer;
81
+ private map?;
82
+ private container?;
83
+ private options;
84
+ private callbacks;
85
+ private drawHelper;
86
+ private overlayService;
87
+ private pointHandler;
88
+ private editClickHandler;
89
+ private editModeEnabled;
90
+ private editOptions?;
91
+ private originalRequestRenderMode;
92
+ private currentEditingEntity;
93
+ private lastEditedEntity;
94
+ private pointEditDragging;
95
+ private pointEditDraggingEntity;
96
+ private pointEditMarkerEntity;
97
+ private pointEditCameraBackup;
98
+ private activeTool;
99
+ private workAreaMode;
100
+ private workAreaType;
101
+ private workAreaKind;
102
+ private readonly entityTypeMap;
103
+ private readonly pointEntities;
104
+ private readonly toolColors;
105
+ private toolbarElement;
106
+ private readonly toolbarButtons;
107
+ private colorPanelElement;
108
+ private hoveredColorTool;
109
+ private colorPanelCloseTimer;
110
+ constructor(viewer: Cesium.Viewer, container?: HTMLElement, options?: CesiumMapMarkOptions, callbacks?: CesiumMapMarkCallbacks, map?: unknown);
111
+ constructor(viewer: Cesium.Viewer, map?: unknown, container?: HTMLElement, options?: CesiumMapMarkOptions, callbacks?: CesiumMapMarkCallbacks);
112
+ getViewer(): Cesium.Viewer;
113
+ getMap(): unknown;
114
+ getContainer(): HTMLElement | undefined;
115
+ getDrawHelper(): DrawHelper;
116
+ getOverlayService(): CesiumOverlayService;
117
+ getActiveTool(): CesiumMapDrawType | null;
118
+ getToolbarElement(): HTMLElement | null;
119
+ setCallbacks(callbacks: CesiumMapMarkCallbacks): void;
120
+ updateCallbacks(callbacks: Partial<CesiumMapMarkCallbacks>): void;
121
+ updateOptions(options: Partial<CesiumMapMarkOptions>): void;
122
+ startDrawTool(drawType: CesiumMapDrawType, options?: DrawOptions): void;
123
+ startDrawing(drawType: CesiumMapDrawType, options?: DrawOptions): void;
124
+ drawPoint(options?: DrawOptions): void;
125
+ drawPolyline(options?: DrawOptions): void;
126
+ drawPolygon(options?: DrawOptions): void;
127
+ drawRectangle(options?: DrawOptions): void;
128
+ drawCircle(options?: DrawOptions): void;
129
+ startWorkAreaDraw(drawType: CesiumMapWorkAreaType, areaType?: CesiumMapWorkAreaKind, options?: DrawOptions): void;
130
+ stopDraw(): void;
131
+ cancelDrawing(): void;
132
+ clearAll(): void;
133
+ deleteEntity(entity: Cesium.Entity | null | undefined): void;
134
+ removeEntity(entity: Cesium.Entity | null | undefined): void;
135
+ setColor(drawType: CesiumMapDrawType, color: string): void;
136
+ getColor(drawType: CesiumMapDrawType): string;
137
+ enableEdit(options?: Parameters<CesiumOverlayService["setOverlayEditMode"]>[1]): void;
138
+ disableEdit(): CesiumMapDrawResult | null;
139
+ startEdit(entityOrId: Cesium.Entity | string, options?: Parameters<CesiumOverlayService["startOverlayEdit"]>[1]): boolean;
140
+ stopEdit(): CesiumMapDrawResult | null;
141
+ getEntities(): Cesium.Entity[];
142
+ exportData(): CesiumMapMarkExportItem[];
143
+ handleSceneModeChanged(): void;
144
+ destroy(): void;
145
+ private setupDrawHelperCallbacks;
146
+ private startDrawHelper;
147
+ private createToolbar;
148
+ private rebuildToolbar;
149
+ private destroyToolbar;
150
+ private resolveButtonConfigs;
151
+ private createToolbarButton;
152
+ private formatCssPixel;
153
+ private applyToolbarStyle;
154
+ private applyButtonStyle;
155
+ private applyButtonContentColor;
156
+ private showColorPanel;
157
+ private renderColorPanel;
158
+ private applyColorPanelStyle;
159
+ private applyColorItemStyle;
160
+ private positionColorPanel;
161
+ private scheduleColorPanelClose;
162
+ private clearColorPanelCloseTimer;
163
+ private destroyColorPanel;
164
+ private updateToolbarActiveState;
165
+ private createEditableOverlayEntity;
166
+ private removeOriginalDrawEntity;
167
+ private startPointDrawing;
168
+ private installEditClickHandler;
169
+ private destroyEditClickHandler;
170
+ private showPointEditMarker;
171
+ private updatePointEditMarkerPosition;
172
+ private removePointEditMarker;
173
+ private pickPointEditEntity;
174
+ private isPointEditHit;
175
+ private getScreenDistance;
176
+ private pickPointEditPosition;
177
+ private pickDrawEntity;
178
+ private resolvePickedEntity;
179
+ private enableContinuousRenderForEdit;
180
+ private restoreRequestRenderModeAfterEdit;
181
+ private lockCameraForPointEdit;
182
+ private restoreCameraAfterPointEdit;
183
+ private emitEditEnd;
184
+ private buildDrawOptions;
185
+ private createWorkAreaOptions;
186
+ private buildDrawResult;
187
+ private buildWorkAreaDrawResult;
188
+ private getLngLatPositions;
189
+ private getCartesian3Positions;
190
+ private getRectangleLngLatPositions;
191
+ private calculateCartesianLength;
192
+ private resolveEntityDrawType;
193
+ private pickPosition;
194
+ private trackEntity;
195
+ private applyCircleStroke;
196
+ private resolveCesiumColor;
197
+ private normalizeColorKey;
198
+ private createInitialColors;
199
+ private normalizeConstructorArgs;
200
+ private emitError;
201
+ }
202
+ export default CesiumMapMark;
@@ -0,0 +1,180 @@
1
+ import { Cartesian3, Cartographic, Color } from '../../node_modules/cesium';
2
+ import { I18nLike } from '../libs/i18n';
3
+ import * as Cesium from 'cesium';
4
+ export interface ToolbarConfig {
5
+ position?: 'top-right' | 'top-left' | 'bottom-right' | 'bottom-left';
6
+ buttonSize?: number;
7
+ buttonSpacing?: number;
8
+ backgroundColor?: string;
9
+ borderColor?: string;
10
+ borderRadius?: number;
11
+ borderWidth?: number;
12
+ boxShadow?: string;
13
+ zIndex?: number;
14
+ buttons?: CustomButtonConfig[];
15
+ useI18n?: boolean;
16
+ i18n?: I18nLike;
17
+ /** 天地图 token(工具栏默认搜索、图层切换使用) */
18
+ TD_Token?: string;
19
+ /** 天地图 sk(工具栏默认搜索、图层切换使用) */
20
+ TD_SK?: string;
21
+ /** 天地图 token 别名 */
22
+ token?: string;
23
+ /** 天地图 sk 别名 */
24
+ sk?: string;
25
+ }
26
+ export interface ButtonConfig {
27
+ sort?: number;
28
+ id: string;
29
+ icon: string;
30
+ title: string;
31
+ titleKey?: string;
32
+ size?: number;
33
+ color?: string;
34
+ borderColor?: string;
35
+ borderWidth?: number;
36
+ borderStyle?: string;
37
+ hoverColor?: string;
38
+ activeColor?: string;
39
+ backgroundColor?: string;
40
+ callback?: () => void;
41
+ activeIcon?: string | HTMLElement;
42
+ }
43
+ export interface CustomButtonConfig {
44
+ id: string;
45
+ icon: string | HTMLElement | false;
46
+ title: string;
47
+ titleKey?: string;
48
+ enabled?: boolean;
49
+ visible?: boolean;
50
+ size?: number;
51
+ color?: string;
52
+ borderColor?: string;
53
+ borderWidth?: number;
54
+ borderStyle?: string;
55
+ padding?: string;
56
+ hoverColor?: string;
57
+ activeColor?: string;
58
+ backgroundColor?: string;
59
+ sort?: number;
60
+ activeIcon?: string | HTMLElement | false;
61
+ callback?: () => void;
62
+ onClick?: (buttonId: string, buttonElement: HTMLElement) => void;
63
+ }
64
+ export interface SearchCallback {
65
+ onSearch?: (query: string) => Promise<SearchResult[]>;
66
+ onSelect?: (result: SearchResult) => void;
67
+ onSearchInput?: (query: string, container: HTMLElement) => void;
68
+ onSearchResults?: (results: SearchResult[], container: HTMLElement) => void;
69
+ }
70
+ export interface SearchResult {
71
+ name: string;
72
+ address: string;
73
+ longitude: number;
74
+ latitude: number;
75
+ height?: number;
76
+ }
77
+ export interface MeasurementCallback {
78
+ onMeasurementStart?: (positions?: Cartesian3[]) => void;
79
+ onDistanceComplete?: (positions: Cartesian3[], distance: number) => void;
80
+ onAreaComplete?: (positions: Cartesian3[], area: number) => void;
81
+ onClear?: () => void;
82
+ }
83
+ export interface ZoomCallback {
84
+ onZoomIn?: (beforeHeight: number, afterHeight: number, currentLevel: number) => void;
85
+ onZoomOut?: (beforeHeight: number, afterHeight: number, currentLevel: number) => void;
86
+ }
87
+ export interface MapType {
88
+ id: string;
89
+ name: string;
90
+ nameKey?: string;
91
+ /** 选中态左上角“路网”文案(可选,未配置时走 i18n 默认 key) */
92
+ placeNameLabel?: string;
93
+ /** 选中态左上角“路网”文案 i18n key(可选) */
94
+ placeNameLabelKey?: string;
95
+ /** 是否强制始终显示路网层(不受 placeName 开关影响) */
96
+ forcePlaceName?: boolean;
97
+ thumbnail: string;
98
+ provider: (token: string, sk?: string) => Cesium.ImageryProvider[];
99
+ terrainProvider?: (token: string, sk?: string) => Cesium.TerrainProvider | null;
100
+ geoWTFS?: (token: string, viewer: Cesium.Viewer, sk?: string) => any | null;
101
+ }
102
+ export interface MapToolsConfig {
103
+ containerId: string;
104
+ viewerOptions?: Cesium.Viewer.ConstructorOptions;
105
+ mapCenter?: {
106
+ longitude: number;
107
+ latitude: number;
108
+ height: number;
109
+ pitch?: number;
110
+ heading?: number;
111
+ };
112
+ zoomLevels?: number[];
113
+ defaultZoom?: number;
114
+ }
115
+ /**
116
+ * 点位绘制选项
117
+ */
118
+ export interface PointOptions {
119
+ pixelSize?: number;
120
+ color?: Color;
121
+ outlineColor?: Color;
122
+ outlineWidth?: number;
123
+ showLabel?: boolean;
124
+ labelText?: string;
125
+ onClick?: (position: Cartesian3, cartographic: Cartographic) => void;
126
+ }
127
+ /**
128
+ * 线条绘制选项
129
+ */
130
+ export interface LineOptions {
131
+ width?: number;
132
+ material?: Cesium.MaterialProperty | Color;
133
+ showDistance?: boolean;
134
+ dashPattern?: number;
135
+ onClick?: (positions: Cartesian3[], distance: number) => void;
136
+ }
137
+ /**
138
+ * 多边形绘制选项
139
+ */
140
+ export interface PolygonOptions {
141
+ material?: Cesium.MaterialProperty | Color;
142
+ outline?: boolean;
143
+ outlineColor?: Color;
144
+ outlineWidth?: number;
145
+ showArea?: boolean;
146
+ dashPattern?: number;
147
+ onClick?: (positions: Cartesian3[], area: number) => void;
148
+ }
149
+ export interface OverlayOptions {
150
+ position: Cartesian3;
151
+ type: 'point' | 'label' | 'billboard' | 'model' | 'cylinder';
152
+ point?: {
153
+ pixelSize?: number;
154
+ color?: Color;
155
+ outlineColor?: Color;
156
+ outlineWidth?: number;
157
+ };
158
+ label?: {
159
+ text: string;
160
+ font?: string;
161
+ fillColor?: Color;
162
+ outlineColor?: Color;
163
+ outlineWidth?: number;
164
+ };
165
+ billboard?: {
166
+ image: string;
167
+ scale?: number;
168
+ };
169
+ model?: {
170
+ uri: string;
171
+ scale?: number;
172
+ };
173
+ cylinder?: {
174
+ length: number;
175
+ topRadius: number;
176
+ bottomRadius: number;
177
+ material?: Color;
178
+ };
179
+ }
180
+ export * as Cesium from '../../node_modules/cesium';
@@ -0,0 +1,231 @@
1
+ import { Viewer } from '../../node_modules/cesium';
2
+ import { CesiumMapController } from './toolBar/CesiumMapController';
3
+ import { MeasurementService } from './toolBar/MeasurementService';
4
+ import { SearchService } from './toolBar/MapSearchService';
5
+ import { MapLayersService } from './toolBar/MapLayersService';
6
+ import { NotFlyZonesService } from './toolBar/NotFlyZonesService';
7
+ import { MapType, ToolbarConfig, SearchCallback, MeasurementCallback, ZoomCallback, CustomButtonConfig } from './CesiumMapModel';
8
+ /**
9
+ * Cesium地图工具栏类
10
+ * 提供搜索、测量、2D/3D切换、图层切换、定位、缩放、全屏等功能
11
+ */
12
+ export declare class CesiumMapToolbar {
13
+ private viewer;
14
+ private drawHelper;
15
+ private container;
16
+ private toolbarElement;
17
+ private config;
18
+ private searchService;
19
+ private mapLayersService;
20
+ private notFlyZonesService;
21
+ private measurementCallback?;
22
+ private zoomCallback?;
23
+ private fullscreenCallback?;
24
+ private resetLocationCallback?;
25
+ private initialCenter?;
26
+ private currentMapType;
27
+ TD_Token: string;
28
+ TD_SK: string;
29
+ mapTypes: MapType[];
30
+ private isNoFlyZoneChecked;
31
+ private currentGeoWTFS;
32
+ private measurementService;
33
+ private unsubscribeI18n?;
34
+ private i18n;
35
+ private useI18n;
36
+ readonly measurement: {
37
+ getMeasureMode: () => "none" | "distance" | "area";
38
+ };
39
+ private mapController;
40
+ constructor(viewer: Viewer, container: HTMLElement, config?: ToolbarConfig, callbacks?: {
41
+ search?: SearchCallback;
42
+ measurement?: MeasurementCallback;
43
+ zoom?: ZoomCallback;
44
+ fullscreen?: (isFullscreen: boolean) => void;
45
+ resetLocation?: () => void;
46
+ }, initialCenter?: {
47
+ longitude: number;
48
+ latitude: number;
49
+ height: number;
50
+ });
51
+ /**
52
+ * searchService 对外暴露的获取搜索服务方法
53
+ */
54
+ getSearchService(): SearchService;
55
+ /**
56
+ * notFlyZonesService 对外暴露的获取禁飞区服务方法
57
+ */
58
+ getNotFlyZonesService(): NotFlyZonesService;
59
+ /**
60
+ * measurementService 对外暴露的获取测量服务方法
61
+ */
62
+ getMeasurementService(): MeasurementService;
63
+ /**
64
+ * cesmapController 对外暴露的获取地图控制器方法
65
+ */
66
+ getCesiumMapCtrl(): CesiumMapController;
67
+ /**
68
+ * mapLayersService 对外暴露的获取图层服务方法
69
+ */
70
+ getMapLayersService(): MapLayersService;
71
+ /**
72
+ * 设置地图类型配置
73
+ * @param mapTypes
74
+ */
75
+ setMapTypes(mapTypes: MapType[]): void;
76
+ /**
77
+ * 设置天地图密钥
78
+ * @param TD_Token
79
+ */
80
+ setTDToken(TD_Token: string): void;
81
+ /**
82
+ * 设置天地图 sk
83
+ * @param TD_SK
84
+ */
85
+ setTDSK(TD_SK: string): void;
86
+ /**
87
+ * 设置天地图认证参数
88
+ * @param TD_Token
89
+ * @param TD_SK
90
+ */
91
+ setTDTAuth(TD_Token: string, TD_SK?: string): void;
92
+ /**
93
+ * 设置初始中心点
94
+ */
95
+ setInitialCenter(center: {
96
+ longitude: number;
97
+ latitude: number;
98
+ height: number;
99
+ }): void;
100
+ /**
101
+ * 获取初始中心点
102
+ */
103
+ getInitialCenter(): {
104
+ longitude: number;
105
+ latitude: number;
106
+ height: number;
107
+ } | undefined;
108
+ /**
109
+ * 复位到初始位置(公共方法)
110
+ */
111
+ resetToInitialLocation(): void;
112
+ /**
113
+ * 更新按钮配置
114
+ */
115
+ updateButtonConfig(buttonId: string, config: Partial<CustomButtonConfig>): void;
116
+ /**
117
+ * 添加自定义按钮
118
+ * @param config 按钮配置,支持 sort 参数控制插入位置
119
+ */
120
+ addCustomButton(config: CustomButtonConfig): void;
121
+ /**
122
+ * 获取所有按钮配置(包括默认按钮和自定义按钮),并添加 sort 值
123
+ */
124
+ private resolveIcon;
125
+ /**
126
+ * 获取按钮配置(已排序,包含默认按钮兜底)
127
+ * - 未传 buttons:使用默认按钮
128
+ * - 传了 buttons:按传入按钮列表渲染,并用默认按钮补齐缺省字段
129
+ */
130
+ private getButtonConfigs;
131
+ /**
132
+ * 重新构建工具栏按钮
133
+ */
134
+ private rebuildToolbarButtons;
135
+ /**
136
+ * 移除按钮
137
+ */
138
+ removeButton(buttonId: string): void;
139
+ /**
140
+ * 获取按钮元素
141
+ */
142
+ private setupDrawHelperCallbacks;
143
+ /**
144
+ * 创建工具栏
145
+ */
146
+ private createToolbar;
147
+ /**
148
+ * 创建按钮
149
+ */
150
+ private createButton;
151
+ /**
152
+ * 设置按钮图标
153
+ */
154
+ private setButtonIcon;
155
+ /**
156
+ * 判断是否为图片路径
157
+ */
158
+ private isImagePath;
159
+ /**
160
+ * 加载图片图标
161
+ */
162
+ private loadImageIcon;
163
+ /**
164
+ * 设置默认图标(当图片加载失败时)
165
+ */
166
+ private setDefaultIcon;
167
+ /**
168
+ * 设置按钮事件
169
+ */
170
+ private setupButtonEvents;
171
+ /**
172
+ * 按钮鼠标离开时关闭菜单
173
+ */
174
+ private closeMenuOnButtonLeave;
175
+ /**
176
+ * 关闭搜索框
177
+ */
178
+ private closeSearchContainer;
179
+ /**
180
+ * 处理按钮点击
181
+ */
182
+ private handleButtonClick;
183
+ /**
184
+ * 切换测量功能
185
+ */
186
+ private toggleMeasurement;
187
+ /**
188
+ * 处理测量操作
189
+ */
190
+ private handleMeasurementAction;
191
+ /**
192
+ * 切换2D/3D视图
193
+ */
194
+ private toggle2D3D;
195
+ /**
196
+ * 复位到初始位置
197
+ */
198
+ private resetLocation;
199
+ /**
200
+ * 放大
201
+ */
202
+ private zoomIn;
203
+ /**
204
+ * 缩小
205
+ */
206
+ private zoomOut;
207
+ /**
208
+ * 加载并显示机场禁飞区
209
+ * @deprecated 使用 NotFlyZonesService.showNoFlyZones 代替
210
+ */
211
+ showNoFlyZones(): Promise<void>;
212
+ /**
213
+ * 隐藏机场禁飞区
214
+ * @deprecated 使用 NotFlyZonesService.hideNoFlyZones 代替
215
+ */
216
+ hideNoFlyZones(): void;
217
+ /**
218
+ * 切换机场禁飞区显示状态
219
+ * @deprecated 使用 NotFlyZonesService.toggleNoFlyZones 代替
220
+ */
221
+ toggleNoFlyZones(): Promise<void>;
222
+ /**
223
+ * 获取禁飞区显示状态
224
+ * @deprecated 使用 NotFlyZonesService.getNoFlyZoneVisible 代替
225
+ */
226
+ getNoFlyZoneVisible(): boolean;
227
+ /**
228
+ * 销毁工具栏
229
+ */
230
+ destroy(): void;
231
+ }