@gis_victory/gismap 2.0.25 → 2.0.26

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 (110) hide show
  1. package/dist/gismap.css +1 -1
  2. package/dist/index.d.ts +153 -39
  3. package/dist/index.es.js +1 -1
  4. package/dist/index.umd.js +1 -0
  5. package/package.json +1 -1
  6. package/dist/App.vue.d.ts +0 -2
  7. package/dist/adapters/index.d.ts +0 -13
  8. package/dist/adapters/mapbox/MapboxAdapter.d.ts +0 -44
  9. package/dist/adapters/types.d.ts +0 -216
  10. package/dist/api/BaseController.d.ts +0 -6
  11. package/dist/api/CommonController.d.ts +0 -51
  12. package/dist/components/MapCompass/index.vue.d.ts +0 -2
  13. package/dist/components/MapContainer/index.d.ts +0 -2
  14. package/dist/components/MapContainer/index.vue.d.ts +0 -344
  15. package/dist/components/MapLayer/components/CustomLayerDialog.vue.d.ts +0 -22
  16. package/dist/components/MapLayer/components/LayerTab.vue.d.ts +0 -2179
  17. package/dist/components/MapLayer/index.d.ts +0 -2
  18. package/dist/components/MapLayer/index.vue.d.ts +0 -2287
  19. package/dist/components/MapLegend/index.d.ts +0 -2
  20. package/dist/components/MapLegend/index.vue.d.ts +0 -14
  21. package/dist/components/MapMeasure/index.vue.d.ts +0 -2
  22. package/dist/components/MapPrint/MapPrintPanel.vue.d.ts +0 -21
  23. package/dist/components/MapPrint/MapPrintService.d.ts +0 -155
  24. package/dist/components/MapPrint/index.vue.d.ts +0 -37
  25. package/dist/components/MapQueryResult/index.vue.d.ts +0 -29
  26. package/dist/components/MapQueryResult/popup.vue.d.ts +0 -16
  27. package/dist/components/MapSearch/index.d.ts +0 -2
  28. package/dist/components/MapSearch/index.vue.d.ts +0 -56
  29. package/dist/components/MapSwitch/index.d.ts +0 -2
  30. package/dist/components/MapSwitch/index.vue.d.ts +0 -37
  31. package/dist/components/MapTools/index.d.ts +0 -2
  32. package/dist/components/MapTools/index.vue.d.ts +0 -40
  33. package/dist/components/MobileMapLayer/BaseLayerSwitch.vue.d.ts +0 -16
  34. package/dist/components/MobileMapLayer/index.vue.d.ts +0 -9
  35. package/dist/components/Widgets/PopupBar/BarItem.vue.d.ts +0 -75
  36. package/dist/components/Widgets/PopupBar/index.vue.d.ts +0 -21
  37. package/dist/composables/index.d.ts +0 -13
  38. package/dist/composables/useControl.d.ts +0 -39
  39. package/dist/composables/useDraw.d.ts +0 -49
  40. package/dist/composables/useLayer.d.ts +0 -57
  41. package/dist/composables/useMap.d.ts +0 -111
  42. package/dist/composables/useMarker.d.ts +0 -55
  43. package/dist/composables/useMeasure.d.ts +0 -49
  44. package/dist/composables/useSearch.d.ts +0 -20
  45. package/dist/config/api.config.d.ts +0 -40
  46. package/dist/config/gismap.config.d.ts +0 -156
  47. package/dist/core/ManagerRegistry.d.ts +0 -75
  48. package/dist/core/PluginSystem.d.ts +0 -71
  49. package/dist/core/StateStore.d.ts +0 -96
  50. package/dist/core/TypedEventEmitter.d.ts +0 -67
  51. package/dist/core/di/Container.d.ts +0 -61
  52. package/dist/core/di/decorators.d.ts +0 -32
  53. package/dist/core/di/index.d.ts +0 -7
  54. package/dist/core/di/types.d.ts +0 -59
  55. package/dist/core/event/EventBus.d.ts +0 -101
  56. package/dist/core/event/index.d.ts +0 -5
  57. package/dist/core/event/types.d.ts +0 -215
  58. package/dist/core/index.d.ts +0 -6
  59. package/dist/core/state/Store.d.ts +0 -145
  60. package/dist/core/state/index.d.ts +0 -6
  61. package/dist/core/state/types.d.ts +0 -134
  62. package/dist/domain/index.d.ts +0 -8
  63. package/dist/domain/layer/LayerEntity.d.ts +0 -90
  64. package/dist/domain/layer/LayerService.d.ts +0 -128
  65. package/dist/domain/marker/MarkerEntity.d.ts +0 -77
  66. package/dist/domain/marker/MarkerService.d.ts +0 -105
  67. package/dist/domain/types.d.ts +0 -66
  68. package/dist/examples/DrawDemo.vue.d.ts +0 -2
  69. package/dist/examples/DrawPanel.vue.d.ts +0 -2
  70. package/dist/examples/Map.vue.d.ts +0 -74
  71. package/dist/examples/MapDemoExample.vue.d.ts +0 -2
  72. package/dist/examples/MeasureDemo.vue.d.ts +0 -2
  73. package/dist/examples/MeasurePanel.vue.d.ts +0 -2
  74. package/dist/examples/SplitScreenDrawDemo.vue.d.ts +0 -7
  75. package/dist/examples/SplitScreenDrawPanel.vue.d.ts +0 -12
  76. package/dist/examples/SplitScreenPanel.vue.d.ts +0 -12
  77. package/dist/examples/TdtControlPanel.vue.d.ts +0 -2
  78. package/dist/examples/TiandituDemo.vue.d.ts +0 -2
  79. package/dist/main.d.ts +0 -0
  80. package/dist/manager/IconManager.d.ts +0 -18
  81. package/dist/manager/LayerManager.d.ts +0 -50
  82. package/dist/manager/MaskManager.d.ts +0 -52
  83. package/dist/manager/PlaceholderManager.d.ts +0 -28
  84. package/dist/manager/PopupManager.d.ts +0 -13
  85. package/dist/manager/QuickSearchManager.d.ts +0 -24
  86. package/dist/manager/RadarManager.d.ts +0 -46
  87. package/dist/manager/SplitScreenDrawManager.d.ts +0 -75
  88. package/dist/manager/SplitScreenManager.d.ts +0 -81
  89. package/dist/manager/TDTManager.d.ts +0 -33
  90. package/dist/manager/TemplateManager.d.ts +0 -52
  91. package/dist/manager/TerrainManager.d.ts +0 -39
  92. package/dist/manager/layer/MarkerLayer.d.ts +0 -89
  93. package/dist/manager/layer/VectorLayer.d.ts +0 -30
  94. package/dist/manager/mapbox/DrawManager.d.ts +0 -153
  95. package/dist/manager/mapbox/MeasureManager.d.ts +0 -158
  96. package/dist/router/index.d.ts +0 -2
  97. package/dist/services/MapContext.d.ts +0 -171
  98. package/dist/services/index.d.ts +0 -5
  99. package/dist/types/IEvents.d.ts +0 -178
  100. package/dist/types/IGISMap.d.ts +0 -234
  101. package/dist/types/IManager.d.ts +0 -113
  102. package/dist/types/IMapSearch.d.ts +0 -28
  103. package/dist/types/IState.d.ts +0 -259
  104. package/dist/types/ITemplate.d.ts +0 -35
  105. package/dist/types/index.d.ts +0 -7
  106. package/dist/utils/hooks/layout.d.ts +0 -4
  107. package/dist/utils/http/axios.d.ts +0 -3
  108. package/dist/utils/http/config.d.ts +0 -3
  109. package/dist/utils/http/request.d.ts +0 -46
  110. package/dist/utils/index.d.ts +0 -49
@@ -1,259 +0,0 @@
1
- import { LngLat, Style } from '@gis_victory/mapbox-gl';
2
- /**
3
- * 视图状态
4
- */
5
- export interface ViewState {
6
- center: LngLat;
7
- zoom: number;
8
- pitch: number;
9
- bearing: number;
10
- padding?: any;
11
- }
12
- /**
13
- * 视图状态变化事件数据
14
- */
15
- export interface ViewStateChangeEvent {
16
- viewState: ViewState;
17
- animate: boolean;
18
- }
19
- /**
20
- * 图层类型
21
- */
22
- export type LayerType = 'background' | 'fill' | 'line' | 'symbol' | 'raster' | 'circle' | 'fill-extrusion' | 'heatmap' | 'hillshade' | 'sky' | 'model' | 'custom' | 'geojson' | 'vector' | 'raster-dem';
23
- /**
24
- * 图层可见性
25
- */
26
- export type LayerVisibility = 'visible' | 'none' | 'visible';
27
- /**
28
- * 图层配置
29
- */
30
- export interface LayerConfig {
31
- id: string;
32
- type: LayerType;
33
- source?: string | GeoJSONSource | VectorSource | RasterSource;
34
- sourceLayer?: string;
35
- minzoom?: number;
36
- maxzoom?: number;
37
- layout?: LayerLayout;
38
- paint?: LayerPaint;
39
- metadata?: Record<string, any>;
40
- /** 是否可交互(点击、悬停) */
41
- interactive?: boolean;
42
- /** 是否可查询 */
43
- queryable?: boolean;
44
- }
45
- /**
46
- * 图层布局属性
47
- */
48
- export interface LayerLayout {
49
- visibility?: LayerVisibility;
50
- 'symbol-placement'?: 'point' | 'line' | 'line-center';
51
- 'symbol-spacing'?: number;
52
- 'symbol-avoid-edges'?: boolean;
53
- 'text-field'?: any;
54
- 'text-font'?: string[];
55
- 'text-size'?: number;
56
- }
57
- /**
58
- * 图层绘制属性
59
- */
60
- export interface LayerPaint {
61
- 'fill-color'?: any;
62
- 'fill-opacity'?: number;
63
- 'fill-pattern'?: string;
64
- 'fill-outline-color'?: any;
65
- 'line-color'?: any;
66
- 'line-width'?: number;
67
- 'line-opacity'?: number;
68
- 'line-dasharray'?: number[];
69
- 'text-color'?: any;
70
- 'text-halo-color'?: any;
71
- 'text-halo-width'?: number;
72
- }
73
- /**
74
- * 图层状态
75
- */
76
- export interface LayerState {
77
- id: string;
78
- type: LayerType;
79
- visible: boolean;
80
- opacity: number;
81
- minzoom?: number;
82
- maxzoom?: number;
83
- config: LayerConfig;
84
- }
85
- /**
86
- * 图层可见性变化事件数据
87
- */
88
- export interface LayerVisibilityChangeEvent {
89
- layerId: string;
90
- visible: boolean;
91
- }
92
- /**
93
- * 标记配置
94
- */
95
- export interface MarkerConfig {
96
- id?: string;
97
- position: LngLat | [number, number];
98
- element?: HTMLElement;
99
- html?: string;
100
- icon?: string;
101
- iconName?: string;
102
- offset?: [number, number];
103
- anchor?: 'center' | 'top' | 'bottom' | 'left' | 'right';
104
- rotation?: number;
105
- rotationOrigin?: string;
106
- draggable?: boolean;
107
- popup?: PopupConfig;
108
- }
109
- /**
110
- * 标记状态
111
- */
112
- export interface MarkerState {
113
- id: string;
114
- position: LngLat;
115
- visible: boolean;
116
- config: MarkerConfig;
117
- }
118
- /**
119
- * 弹窗配置
120
- */
121
- export interface PopupConfig {
122
- id?: string;
123
- position: LngLat | [number, number];
124
- content?: string | HTMLElement;
125
- html?: string;
126
- closeButton?: boolean;
127
- closeOnClick?: boolean;
128
- closeOnMove?: boolean;
129
- maxWidth?: string;
130
- anchor?: 'center' | 'top' | 'bottom' | 'left' | 'right';
131
- offset?: number | [number, number] | Record<string, [number, number]>;
132
- }
133
- /**
134
- * 弹窗状态
135
- */
136
- export interface PopupState {
137
- id: string;
138
- position: LngLat;
139
- visible: boolean;
140
- config: PopupConfig;
141
- }
142
- /**
143
- * GeoJSON 数据源
144
- */
145
- export interface GeoJSONSource {
146
- type: 'geojson';
147
- data?: any;
148
- url?: string;
149
- cluster?: boolean;
150
- clusterMaxZoom?: number;
151
- clusterRadius?: number;
152
- lineMetrics?: boolean;
153
- generateId?: boolean;
154
- }
155
- /**
156
- * Vector 数据源
157
- */
158
- export interface VectorSource {
159
- type: 'vector';
160
- url?: string;
161
- tiles?: string[];
162
- bounds?: [number, number, number, number];
163
- minzoom?: number;
164
- maxzoom?: number;
165
- attribution?: string;
166
- }
167
- /**
168
- * Raster 数据源
169
- */
170
- export interface RasterSource {
171
- type: 'raster';
172
- url?: string;
173
- tiles?: string[];
174
- tileSize?: number;
175
- minzoom?: number;
176
- maxzoom?: number;
177
- bounds?: [number, number, number, number];
178
- }
179
- /**
180
- * 地图状态
181
- */
182
- export interface MapState {
183
- /** 视图状态 */
184
- view: ViewState;
185
- /** 图层状态 */
186
- layers: Map<string, LayerState>;
187
- /** 标记状态 */
188
- markers: Map<string, MarkerState>;
189
- /** 弹窗状态 */
190
- popups: Map<string, PopupState>;
191
- /** 当前激活的弹窗 */
192
- activePopup: PopupState | null;
193
- /** 当前选中的要素 */
194
- selectedFeatures: any[];
195
- /** 地图是否加载完成 */
196
- loaded: boolean;
197
- /** 地图是否可用 */
198
- ready: boolean;
199
- /** 地图样式 */
200
- style: Style | null;
201
- /** 地图容器 */
202
- container: HTMLElement | null;
203
- }
204
- /**
205
- * 状态变更
206
- */
207
- export interface StateMutation {
208
- type: string;
209
- payload: any;
210
- timestamp: number;
211
- }
212
- /**
213
- * 状态订阅者
214
- */
215
- export type StateSubscriber = (mutation: StateMutation, state: MapState) => void;
216
- /**
217
- * 状态管理接口
218
- */
219
- export interface IStateStore {
220
- /** 获取当前状态 */
221
- getState(): MapState;
222
- /** 获取特定状态 */
223
- get<K extends keyof MapState>(key: K): MapState[K];
224
- /** 更新状态 */
225
- setState(partial: Partial<MapState>): void;
226
- /** 设置特定状态 */
227
- set<K extends keyof MapState>(key: K, value: MapState[K]): void;
228
- /** 订阅状态变更 */
229
- subscribe(listener: StateSubscriber): () => void;
230
- /** 重置状态 */
231
- reset(): void;
232
- /** 持久化状态 */
233
- persist(): void;
234
- /** 恢复状态 */
235
- restore(): void;
236
- }
237
- /**
238
- * 状态历史记录
239
- */
240
- export interface StateHistory {
241
- past: MapState[];
242
- future: MapState[];
243
- maxSize: number;
244
- }
245
- /**
246
- * 可时间旅行的状态管理
247
- */
248
- export interface ITimeTravelStore extends IStateStore {
249
- /** 撤销 */
250
- undo(): void;
251
- /** 重做 */
252
- redo(): void;
253
- /** 是否可撤销 */
254
- canUndo(): boolean;
255
- /** 是否可重做 */
256
- canRedo(): boolean;
257
- /** 清空历史 */
258
- clearHistory(): void;
259
- }
@@ -1,35 +0,0 @@
1
- /**
2
- * 模板字段配置
3
- */
4
- export interface TemplateField {
5
- fieldType: string;
6
- fieldName: string;
7
- fieldLabel: string;
8
- format: string;
9
- unit: string;
10
- style: {
11
- span: number;
12
- };
13
- isShowList?: boolean;
14
- isShowInfo?: boolean;
15
- isShowMore?: boolean;
16
- }
17
- /**
18
- * 模板按钮配置
19
- */
20
- export interface TemplateButton {
21
- label: string;
22
- type: string;
23
- event?: string;
24
- }
25
- /**
26
- * 模板配置
27
- */
28
- export interface TemplateItem {
29
- id: string;
30
- width?: number;
31
- labelWidth?: number;
32
- header: string;
33
- body: TemplateField[];
34
- footer: TemplateButton[];
35
- }
@@ -1,7 +0,0 @@
1
- /**
2
- * GIS 地图类型定义入口
3
- */
4
- export * from './IManager';
5
- export * from './IGISMap';
6
- export * from './IEvents';
7
- export * from './IState';
@@ -1,4 +0,0 @@
1
- import { MapAdapter } from '../../adapters';
2
- export default function useLayout(mapAdapter: MapAdapter | undefined): {
3
- mapHeight: import('vue').Ref<number, number>;
4
- };
@@ -1,3 +0,0 @@
1
- import { AxiosInstance } from 'axios';
2
- declare const axiosInstance: AxiosInstance;
3
- export default axiosInstance;
@@ -1,3 +0,0 @@
1
- export declare const serverDefaultCfg: {
2
- baseURL: string;
3
- };
@@ -1,46 +0,0 @@
1
- import { AxiosRequestConfig } from 'axios';
2
- import { RequestMethods, RequestOption, ResponseDataType } from './types';
3
- /**
4
- * 核心函数,可通过它处理一切请求数据,并做横向扩展
5
- * @param url 请求地址
6
- * @param params 请求参数
7
- * @param method 请求方法,只接受"get" | "delete" | "head" | "post" | "put" | "patch"
8
- * @param requestOption 请求配置(针对当前本次请求)
9
- * @param axiosOption axios配置(针对当前本次请求)
10
- */
11
- export declare function commonRequest<D>(url: string, params: any, method: RequestMethods, requestOption?: RequestOption, axiosOption?: AxiosRequestConfig): Promise<ResponseDataType<D>>;
12
- /***
13
- * @param url 请求地址
14
- * @param params 请求参数
15
- * @param options 请求设置(showMask-是否显示Loading层,默认为true;showError-是否显示错误信息,默认为true;throttleFlag-是否开户节流,默认为false;throttleTimeout-节流时效,默认为50毫秒)
16
- * @param axiosOption
17
- */
18
- export declare const get: <D>(url: string, params?: any, options?: RequestOption, axiosOption?: AxiosRequestConfig) => Promise<ResponseDataType<D>>;
19
- /***
20
- * @param url 请求地址
21
- * @param params 请求参数
22
- * @param options 请求设置(showMask-是否显示Loading层,默认为true;showError-是否显示错误信息,默认为true;throttleFlag-是否开户节流,默认为false;throttleTimeout-节流时效,默认为50毫秒)
23
- * @param axiosOption
24
- */
25
- export declare const post: <D>(url: string, params: any, options?: RequestOption, axiosOption?: AxiosRequestConfig) => Promise<ResponseDataType<D>>;
26
- /***
27
- * @param url 请求地址
28
- * @param params 请求参数
29
- * @param options 请求设置(showMask-是否显示Loading层,默认为true;showError-是否显示错误信息,默认为true;throttleFlag-是否开户节流,默认为false;throttleTimeout-节流时效,默认为50毫秒)
30
- * @param axiosOption
31
- */
32
- export declare const put: <D>(url: string, params: any, options?: RequestOption, axiosOption?: AxiosRequestConfig) => Promise<ResponseDataType<D>>;
33
- /***
34
- * @param url 请求地址
35
- * @param params 请求参数
36
- * @param options 请求设置(showMask-是否显示Loading层,默认为true;showError-是否显示错误信息,默认为true;throttleFlag-是否开户节流,默认为false;throttleTimeout-节流时效,默认为50毫秒)
37
- * @param axiosOption
38
- */
39
- export declare const patch: <D>(url: string, params: any, options?: RequestOption, axiosOption?: AxiosRequestConfig) => Promise<ResponseDataType<D>>;
40
- /***
41
- * @param url 请求地址
42
- * @param params 请求参数
43
- * @param options 请求设置(showMask-是否显示Loading层,默认为true;showError-是否显示错误信息,默认为true;throttleFlag-是否开户节流,默认为false;throttleTimeout-节流时效,默认为50毫秒)
44
- * @param axiosOption
45
- */
46
- export declare const del: <D>(url: string, params: any, options?: RequestOption, axiosOption?: AxiosRequestConfig) => Promise<ResponseDataType<D>>;
@@ -1,49 +0,0 @@
1
- import { TemplateField } from '../types/ITemplate';
2
- export declare function encrypt(value: string): string | null;
3
- /**
4
- * 动态模板渲染引擎
5
- * @param {string} template - HTML模板字符串
6
- * @param {object} data - 包含替换数据的对象
7
- * @returns {string} 渲染后的HTML字符串
8
- */
9
- export declare function renderTemplate(template: string, data: any): string;
10
- /**
11
- * 通过id返回从根节点到指定节点的路径
12
- * @param {Array} treeRoot 树根节点数组
13
- * @param {*} id 要查询的节点的id
14
- * @param {*} idKey 主键字段名
15
- * @param {*} childKey 子节点字段名
16
- */
17
- export declare function findTreeNodeObjectPath(treeRoot: any, id: string | number | undefined, idKey?: string, childKey?: string): any[];
18
- /**
19
- * 通过id返回从根节点到指定节点的路径
20
- * @param treeRoot `
21
- * @param id
22
- * @param idKey
23
- * @param childKey
24
- * @returns
25
- */
26
- export declare function findTreeNodePath<D>(treeRoot: Array<D>, id: string | number | undefined, idKey?: string, childKey?: string): Array<string | number>;
27
- /**
28
- * 通过id从树中查找节点
29
- * @param {Array} treeRoot 根节点数组
30
- * @param {*} id 要查找的节点的id
31
- * @param {*} idKey 主键字段名
32
- * @param {*} childKey 子节点字段名
33
- */
34
- export declare function findTreeNode(treeRoot: any, id: string, idKey?: string, childKey?: string): any;
35
- export declare function traverseTree(root: any, callback: (node: any) => void, childKey?: string): void;
36
- export declare function getToken(): string | null;
37
- export declare function setToken(token: string | null | undefined): void;
38
- export declare function generateUUID(len?: number): string;
39
- /**
40
- * 字段类型
41
- */
42
- export type FieldType = 'text' | 'number' | 'date' | 'image' | 'boolean' | 'link';
43
- /**
44
- * 格式化字段值
45
- * @param value 字段值
46
- * @param options 格式化选项
47
- * @returns 格式化后的值
48
- */
49
- export declare function formatFieldValue(value: any, options: TemplateField): any;