@gis_victory/gismap 2.0.35 → 2.0.38
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/gismap.css +1 -1
- package/dist/index.d.ts +41 -4
- package/dist/index.es.js +1 -1
- package/dist/index.umd.js +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -187,7 +187,6 @@ addVecLayer: (sourceConfig?: any, beforeId?: string) => void;
|
|
|
187
187
|
removeVecLayer: () => void;
|
|
188
188
|
addCiaLayer: (sourceConfig?: any, beforeId?: string) => void;
|
|
189
189
|
removeCiaLayer: () => void;
|
|
190
|
-
setGrayMode: (id: string) => void;
|
|
191
190
|
clear: () => void;
|
|
192
191
|
show: () => void;
|
|
193
192
|
hideAll: () => void;
|
|
@@ -295,6 +294,11 @@ getTemplateIds: () => string[];
|
|
|
295
294
|
hasTemplate: (templateId: string) => boolean;
|
|
296
295
|
clear: () => void;
|
|
297
296
|
} | undefined;
|
|
297
|
+
readonly styleManager: {
|
|
298
|
+
applyStyle: (layerId: string, style: string) => void;
|
|
299
|
+
resetStyle: (layerId: string) => void;
|
|
300
|
+
hasLayer: (layerId: string) => boolean;
|
|
301
|
+
} | undefined;
|
|
298
302
|
readonly markerManager: {
|
|
299
303
|
setOnMarkerClick: (callback: (data: MarkerData) => void) => void;
|
|
300
304
|
addMarker: (data: MarkerData) => void;
|
|
@@ -3846,8 +3850,8 @@ default: boolean;
|
|
|
3846
3850
|
};
|
|
3847
3851
|
}>> & Readonly<{}>, {
|
|
3848
3852
|
data: Record<string, any>;
|
|
3849
|
-
extensionsPosition: string;
|
|
3850
3853
|
gray: boolean;
|
|
3854
|
+
extensionsPosition: string;
|
|
3851
3855
|
}, {}, {}, {}, string, ComponentProvideOptions, true, {}, HTMLDivElement>, {
|
|
3852
3856
|
left?(_: {}): any;
|
|
3853
3857
|
right?(_: {}): any;
|
|
@@ -4915,6 +4919,7 @@ export declare class MapContext {
|
|
|
4915
4919
|
private _radarManager?;
|
|
4916
4920
|
private _iconManager?;
|
|
4917
4921
|
private _templateManager?;
|
|
4922
|
+
private _styleManager?;
|
|
4918
4923
|
private _markerManager?;
|
|
4919
4924
|
private _drawManager?;
|
|
4920
4925
|
private _measureManager?;
|
|
@@ -4963,6 +4968,10 @@ export declare class MapContext {
|
|
|
4963
4968
|
* 获取模板管理器
|
|
4964
4969
|
*/
|
|
4965
4970
|
get templateManager(): TemplateManager | undefined;
|
|
4971
|
+
/**
|
|
4972
|
+
* 获取样式管理器
|
|
4973
|
+
*/
|
|
4974
|
+
get styleManager(): StyleManager | undefined;
|
|
4966
4975
|
/**
|
|
4967
4976
|
* 获取标记管理器
|
|
4968
4977
|
*/
|
|
@@ -6225,6 +6234,27 @@ export declare class StateStore implements IStateStore {
|
|
|
6225
6234
|
*/
|
|
6226
6235
|
export declare type StateSubscriber = (mutation: StateMutation, state: MapState) => void;
|
|
6227
6236
|
|
|
6237
|
+
export declare class StyleManager {
|
|
6238
|
+
private adapter;
|
|
6239
|
+
constructor(adapter: VectorTileAdapter);
|
|
6240
|
+
/**
|
|
6241
|
+
* 应用样式到指定图层
|
|
6242
|
+
* @param layerId 图层 ID
|
|
6243
|
+
* @param style 样式配置或预定义样式类型
|
|
6244
|
+
*/
|
|
6245
|
+
applyStyle(layerId: string, style: string): void;
|
|
6246
|
+
/**
|
|
6247
|
+
* 重置图层样式到默认状态
|
|
6248
|
+
* @param layerId 图层 ID
|
|
6249
|
+
*/
|
|
6250
|
+
resetStyle(layerId: string): void;
|
|
6251
|
+
/**
|
|
6252
|
+
* 检查图层是否存在
|
|
6253
|
+
* @param layerId 图层 ID
|
|
6254
|
+
*/
|
|
6255
|
+
hasLayer(layerId: string): boolean;
|
|
6256
|
+
}
|
|
6257
|
+
|
|
6228
6258
|
/** 叠加图层切换载荷 */
|
|
6229
6259
|
export declare interface SwitchClickPayload {
|
|
6230
6260
|
/** 是否选中 */
|
|
@@ -6243,6 +6273,13 @@ export declare interface SwitchLayerPayload {
|
|
|
6243
6273
|
checked?: boolean;
|
|
6244
6274
|
/** 自定义 source 配置(可选) */
|
|
6245
6275
|
source?: any;
|
|
6276
|
+
/** 风格选项列表(可选,点击后显示风格选择弹窗) */
|
|
6277
|
+
styles?: Array<{
|
|
6278
|
+
label: string;
|
|
6279
|
+
name: string;
|
|
6280
|
+
checked?: boolean;
|
|
6281
|
+
paint?: any;
|
|
6282
|
+
}>;
|
|
6246
6283
|
/** 其他扩展字段 */
|
|
6247
6284
|
[key: string]: any;
|
|
6248
6285
|
}
|
|
@@ -6264,8 +6301,6 @@ declare class TDTManager {
|
|
|
6264
6301
|
/** 添加天地图注记图层 */
|
|
6265
6302
|
addCiaLayer(sourceConfig?: any, beforeId?: string): void;
|
|
6266
6303
|
removeCiaLayer(): void;
|
|
6267
|
-
/** 设置天地图图层灰度显示 */
|
|
6268
|
-
setGrayMode(id: string): void;
|
|
6269
6304
|
/** 移除所有天地图图层 */
|
|
6270
6305
|
clear(): void;
|
|
6271
6306
|
/** 显示天地图(恢复可见性) */
|
|
@@ -6557,6 +6592,8 @@ export declare function useControl(): {
|
|
|
6557
6592
|
placeholder: Ref<PlaceholderManager | null, PlaceholderManager | null>;
|
|
6558
6593
|
/** 图层管理器 */
|
|
6559
6594
|
layer: Ref<LayerManager | null, LayerManager | null>;
|
|
6595
|
+
/** 风格管理器 Ref */
|
|
6596
|
+
style: Ref<StyleManager | null, StyleManager | null>;
|
|
6560
6597
|
/** 原始地图上下文 Ref */
|
|
6561
6598
|
context: Ref<MapContext | null, MapContext | null>;
|
|
6562
6599
|
};
|