zhihao-ui 1.2.27 → 1.2.28

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.
@@ -8,3 +8,43 @@ export declare enum SWITCH_BTN {
8
8
  Mobile = "mobile",
9
9
  WaterGauge = "waterGauge"
10
10
  }
11
+ export declare enum SHIP_SAIL_STATUS {
12
+ "发动机使用中" = 0,
13
+ "锚泊" = 1,
14
+ "未操作" = 2,
15
+ "操纵能力受限" = 3,
16
+ "吃水受限" = 4,
17
+ "系泊" = 5,
18
+ "搁浅" = 6,
19
+ "从事捕捞" = 7,
20
+ "航行中" = 8,
21
+ "留作将来修正导航状态" = 9,
22
+ "高速船留用" = 10,
23
+ "机动船尾推作业" = 11,
24
+ "机动船顶推或侧推作业" = 12,
25
+ "飞翼船留用" = 13,
26
+ "现行的" = 14,
27
+ "未定义" = 15
28
+ }
29
+ export declare enum SHIP_TYPE {
30
+ "飞翼船" = 1,
31
+ "捕捞船" = 2,
32
+ "拖带船" = 3,
33
+ "帆船" = 4,
34
+ "游艇" = 5,
35
+ "高速船" = 6,
36
+ "领航船" = 7,
37
+ "搜救船" = 8,
38
+ "拖轮" = 9,
39
+ "港口供应" = 10,
40
+ "防污船舶" = 11,
41
+ "执法船" = 12,
42
+ "医疗运输" = 13,
43
+ "特殊船" = 14,
44
+ "客轮" = 15,
45
+ "货轮" = 16,
46
+ "油轮" = 17,
47
+ "集装箱船" = 18,
48
+ "其他" = 19,
49
+ "未知" = 20
50
+ }
@@ -20,7 +20,7 @@ export declare const ZhMap: {
20
20
  type: import('vue').PropType<string>;
21
21
  };
22
22
  shipData: {
23
- type: import('vue').PropType<import('./interface').ShipInfoVo>;
23
+ type: import('vue').PropType<import('./interface/index.ts').ShipInfoVo>;
24
24
  };
25
25
  }>> & Readonly<{
26
26
  onZoomChanged?: ((...args: any[]) => any) | undefined;
@@ -28,10 +28,10 @@ export declare const ZhMap: {
28
28
  }>, {
29
29
  mapInstance: import('vue').Ref<import('ol').Map | undefined, import('ol').Map | undefined>;
30
30
  initMap: () => void;
31
- renderTrucksMarker: (list: import('./interface').SinoiovVehicleInfo[]) => import('ol/layer').Vector<import('ol/source').Vector<any>, any> | undefined;
32
- renderShip: (list: import('./interface').ShipInfoVo[]) => import('ol/layer').Vector<import('ol/source').Vector<any>, any> | import('ol/layer').WebGLPoints<import('ol/source').Vector<import('ol').Feature<import('ol/geom').Geometry>>> | undefined;
31
+ renderTrucksMarker: (list: import('./interface/index.ts').SinoiovVehicleInfo[]) => import('ol/layer').Vector<import('ol/source').Vector<any>, any> | undefined;
32
+ renderShip: (list: import('./interface/index.ts').ShipInfoVo[]) => import('ol/layer').Vector<import('ol/source').Vector<any>, any> | import('ol/layer').WebGLPoints<import('ol/source').Vector<import('ol').Feature<import('ol/geom').Geometry>>> | undefined;
33
33
  renderTrack: (mmsi: string, list: any[], color: string) => void;
34
- findTruck: (vehicleInfo?: import('./interface').VehicleInfo) => Promise<void>;
34
+ findTruck: (vehicleInfo?: import('./interface/index.ts').VehicleInfo) => Promise<void>;
35
35
  removeTruckIcon: () => void;
36
36
  clearAllTruck: () => void;
37
37
  closeTrack: () => void;
@@ -39,11 +39,11 @@ export declare const ZhMap: {
39
39
  resetTrackView: (id?: number | string) => void;
40
40
  playTrack: (id: number | string, speed: number) => void;
41
41
  clearSelectFeature: () => void;
42
- findShip: (id: string, shipData?: import('./interface').ShipInfoVo, select?: boolean) => any;
43
- focusShip: (id: string, shipData?: import('./interface').ShipInfoVo, hidden?: boolean) => void;
44
- showTracks: import('vue').Ref<import('./interface').TrackExtend[], import('./interface').TrackExtend[]>;
42
+ findShip: (id: string, shipData?: import('./interface/index.ts').ShipInfoVo, select?: boolean) => any;
43
+ focusShip: (id: string, shipData?: import('./interface/index.ts').ShipInfoVo, hidden?: boolean) => void;
44
+ showTracks: import('vue').Ref<import('./interface/index.ts').TrackExtend[], import('./interface/index.ts').TrackExtend[]>;
45
45
  removeAllTrackLayer: () => void;
46
- switchFilterItem: (key: import('./enum').SWITCH_BTN, value: boolean) => void;
46
+ switchFilterItem: (key: import('./enum/ship.ts').SWITCH_BTN, value: boolean) => void;
47
47
  rerenderShip: () => void;
48
48
  switchGreenDot: () => void;
49
49
  zoomTruckIcon: () => void;
@@ -147,7 +147,7 @@ export declare const ZhMap: {
147
147
  type: import('vue').PropType<string>;
148
148
  };
149
149
  shipData: {
150
- type: import('vue').PropType<import('./interface').ShipInfoVo>;
150
+ type: import('vue').PropType<import('./interface/index.ts').ShipInfoVo>;
151
151
  };
152
152
  }>> & Readonly<{
153
153
  onZoomChanged?: ((...args: any[]) => any) | undefined;
@@ -155,10 +155,10 @@ export declare const ZhMap: {
155
155
  }>, {
156
156
  mapInstance: import('vue').Ref<import('ol').Map | undefined, import('ol').Map | undefined>;
157
157
  initMap: () => void;
158
- renderTrucksMarker: (list: import('./interface').SinoiovVehicleInfo[]) => import('ol/layer').Vector<import('ol/source').Vector<any>, any> | undefined;
159
- renderShip: (list: import('./interface').ShipInfoVo[]) => import('ol/layer').Vector<import('ol/source').Vector<any>, any> | import('ol/layer').WebGLPoints<import('ol/source').Vector<import('ol').Feature<import('ol/geom').Geometry>>> | undefined;
158
+ renderTrucksMarker: (list: import('./interface/index.ts').SinoiovVehicleInfo[]) => import('ol/layer').Vector<import('ol/source').Vector<any>, any> | undefined;
159
+ renderShip: (list: import('./interface/index.ts').ShipInfoVo[]) => import('ol/layer').Vector<import('ol/source').Vector<any>, any> | import('ol/layer').WebGLPoints<import('ol/source').Vector<import('ol').Feature<import('ol/geom').Geometry>>> | undefined;
160
160
  renderTrack: (mmsi: string, list: any[], color: string) => void;
161
- findTruck: (vehicleInfo?: import('./interface').VehicleInfo) => Promise<void>;
161
+ findTruck: (vehicleInfo?: import('./interface/index.ts').VehicleInfo) => Promise<void>;
162
162
  removeTruckIcon: () => void;
163
163
  clearAllTruck: () => void;
164
164
  closeTrack: () => void;
@@ -166,11 +166,11 @@ export declare const ZhMap: {
166
166
  resetTrackView: (id?: number | string) => void;
167
167
  playTrack: (id: number | string, speed: number) => void;
168
168
  clearSelectFeature: () => void;
169
- findShip: (id: string, shipData?: import('./interface').ShipInfoVo, select?: boolean) => any;
170
- focusShip: (id: string, shipData?: import('./interface').ShipInfoVo, hidden?: boolean) => void;
171
- showTracks: import('vue').Ref<import('./interface').TrackExtend[], import('./interface').TrackExtend[]>;
169
+ findShip: (id: string, shipData?: import('./interface/index.ts').ShipInfoVo, select?: boolean) => any;
170
+ focusShip: (id: string, shipData?: import('./interface/index.ts').ShipInfoVo, hidden?: boolean) => void;
171
+ showTracks: import('vue').Ref<import('./interface/index.ts').TrackExtend[], import('./interface/index.ts').TrackExtend[]>;
172
172
  removeAllTrackLayer: () => void;
173
- switchFilterItem: (key: import('./enum').SWITCH_BTN, value: boolean) => void;
173
+ switchFilterItem: (key: import('./enum/ship.ts').SWITCH_BTN, value: boolean) => void;
174
174
  rerenderShip: () => void;
175
175
  switchGreenDot: () => void;
176
176
  zoomTruckIcon: () => void;
@@ -268,7 +268,7 @@ export declare const ZhMap: {
268
268
  type: import('vue').PropType<string>;
269
269
  };
270
270
  shipData: {
271
- type: import('vue').PropType<import('./interface').ShipInfoVo>;
271
+ type: import('vue').PropType<import('./interface/index.ts').ShipInfoVo>;
272
272
  };
273
273
  }>> & Readonly<{
274
274
  onZoomChanged?: ((...args: any[]) => any) | undefined;
@@ -276,10 +276,10 @@ export declare const ZhMap: {
276
276
  }>, {
277
277
  mapInstance: import('vue').Ref<import('ol').Map | undefined, import('ol').Map | undefined>;
278
278
  initMap: () => void;
279
- renderTrucksMarker: (list: import('./interface').SinoiovVehicleInfo[]) => import('ol/layer').Vector<import('ol/source').Vector<any>, any> | undefined;
280
- renderShip: (list: import('./interface').ShipInfoVo[]) => import('ol/layer').Vector<import('ol/source').Vector<any>, any> | import('ol/layer').WebGLPoints<import('ol/source').Vector<import('ol').Feature<import('ol/geom').Geometry>>> | undefined;
279
+ renderTrucksMarker: (list: import('./interface/index.ts').SinoiovVehicleInfo[]) => import('ol/layer').Vector<import('ol/source').Vector<any>, any> | undefined;
280
+ renderShip: (list: import('./interface/index.ts').ShipInfoVo[]) => import('ol/layer').Vector<import('ol/source').Vector<any>, any> | import('ol/layer').WebGLPoints<import('ol/source').Vector<import('ol').Feature<import('ol/geom').Geometry>>> | undefined;
281
281
  renderTrack: (mmsi: string, list: any[], color: string) => void;
282
- findTruck: (vehicleInfo?: import('./interface').VehicleInfo) => Promise<void>;
282
+ findTruck: (vehicleInfo?: import('./interface/index.ts').VehicleInfo) => Promise<void>;
283
283
  removeTruckIcon: () => void;
284
284
  clearAllTruck: () => void;
285
285
  closeTrack: () => void;
@@ -287,11 +287,11 @@ export declare const ZhMap: {
287
287
  resetTrackView: (id?: number | string) => void;
288
288
  playTrack: (id: number | string, speed: number) => void;
289
289
  clearSelectFeature: () => void;
290
- findShip: (id: string, shipData?: import('./interface').ShipInfoVo, select?: boolean) => any;
291
- focusShip: (id: string, shipData?: import('./interface').ShipInfoVo, hidden?: boolean) => void;
292
- showTracks: import('vue').Ref<import('./interface').TrackExtend[], import('./interface').TrackExtend[]>;
290
+ findShip: (id: string, shipData?: import('./interface/index.ts').ShipInfoVo, select?: boolean) => any;
291
+ focusShip: (id: string, shipData?: import('./interface/index.ts').ShipInfoVo, hidden?: boolean) => void;
292
+ showTracks: import('vue').Ref<import('./interface/index.ts').TrackExtend[], import('./interface/index.ts').TrackExtend[]>;
293
293
  removeAllTrackLayer: () => void;
294
- switchFilterItem: (key: import('./enum').SWITCH_BTN, value: boolean) => void;
294
+ switchFilterItem: (key: import('./enum/ship.ts').SWITCH_BTN, value: boolean) => void;
295
295
  rerenderShip: () => void;
296
296
  switchGreenDot: () => void;
297
297
  zoomTruckIcon: () => void;
@@ -372,3 +372,5 @@ export declare const ZhMap: {
372
372
  toolPanel?(_: {}): any;
373
373
  };
374
374
  }) & import('vue').Plugin;
375
+ export * from './render/renderPoint.ts';
376
+ export * from './config';
@@ -0,0 +1,10 @@
1
+ import { Feature } from 'ol';
2
+
3
+ export interface PointMarker {
4
+ id: string | number;
5
+ name: string;
6
+ fullName?: string;
7
+ lonlat: [number, number];
8
+ feature: Feature;
9
+ pointType: string;
10
+ }
@@ -6,6 +6,7 @@ export interface DrawTextOptions {
6
6
  rightIcons?: string[];
7
7
  font?: string;
8
8
  type?: string;
9
+ blinkColors?: string[];
9
10
  }
10
11
  export interface DrawPolygonOptions {
11
12
  points: number[][];
@@ -28,6 +29,7 @@ export interface DrawLabelOptions {
28
29
  rightIcons?: string[];
29
30
  selected?: boolean;
30
31
  type?: string;
32
+ blinkColors?: string[];
31
33
  }
32
34
  export interface LeftIconOptions {
33
35
  icon: string;
@@ -205,4 +205,6 @@ export interface ShipInfoVo {
205
205
  * 关注的船自定义后缀
206
206
  */
207
207
  existName: number;
208
+ selected?: boolean;
209
+ blinkColors?: string[];
208
210
  }
@@ -22,5 +22,6 @@ export declare class ShipMapData {
22
22
  existMobile?: boolean;
23
23
  existWaterGauge?: boolean;
24
24
  selected?: boolean;
25
- constructor(id: string, mmsi: string, fill: string, shipType: string, name: string, length: number, breadth: number, lon: number, lat: number, createdAt: number, speed: number, from: string, sailStatus: string, hdg: number, cog: number, posType: number, type: string, angle: number, leftIconColor?: string | null, existDevice?: boolean, existMobile?: boolean, existWaterGauge?: boolean, selected?: boolean);
25
+ blinkColors?: string[];
26
+ constructor(id: string, mmsi: string, fill: string, shipType: string, name: string, length: number, breadth: number, lon: number, lat: number, createdAt: number, speed: number, from: string, sailStatus: string, hdg: number, cog: number, posType: number, type: string, angle: number, leftIconColor?: string | null, existDevice?: boolean, existMobile?: boolean, existWaterGauge?: boolean, selected?: boolean, blinkColors?: string[]);
26
27
  }
@@ -0,0 +1,8 @@
1
+ import { Style } from 'ol/style';
2
+
3
+ export declare const setPointStyle: (selected: boolean, name: string, options: {
4
+ color: string;
5
+ activeUrl?: string;
6
+ url?: string;
7
+ activeColor?: string;
8
+ }) => Style;
@@ -0,0 +1,80 @@
1
+ import { Feature, Map as MapType } from 'ol';
2
+ import { Geometry, Point } from 'ol/geom';
3
+ import { default as VectorSource } from 'ol/source/Vector';
4
+ import { default as VectorLayer } from 'ol/layer/Vector';
5
+ import { PointMarker } from '../interface/entity/point.ts';
6
+
7
+ export declare class PointMarkerClass {
8
+ mapInstance: MapType | undefined;
9
+ pointMarkerList: PointMarker[];
10
+ pointsVectorSource: VectorSource<Feature<Geometry>> | undefined;
11
+ highlightPoint: Omit<PointMarker, "feature"> | undefined;
12
+ pointLayer: VectorLayer | undefined;
13
+ options: {
14
+ color: string;
15
+ activeUrl?: string;
16
+ url?: string;
17
+ activeColor?: string;
18
+ };
19
+ /**
20
+ * 地图实例
21
+ * @param mapInstance
22
+ * 配置渲染点的样式
23
+ * @param options
24
+ */
25
+ constructor(mapInstance: MapType, options: {
26
+ color: string;
27
+ activeUrl?: string;
28
+ url?: string;
29
+ activeColor?: string;
30
+ });
31
+ /**
32
+ * 渲染
33
+ * @param list
34
+ * 格式:
35
+ * 获取数据的id
36
+ * id
37
+ * 地图显示
38
+ * name
39
+ * fullName,
40
+ * 经纬度
41
+ * lon,
42
+ * lat,
43
+ * 渲染点的数据类型,好通过这个判断点击地图获取到的类型, 任意字符串
44
+ * pointType
45
+ */
46
+ renderPointMarker(list: any[]): void;
47
+ deleteAllPointMarkers(): void;
48
+ cancelHighlightTruckMarker(): void;
49
+ /**
50
+ * 设置选中
51
+ * 渲染
52
+ * @param item
53
+ * 格式:
54
+ * 获取数据的id
55
+ * id
56
+ * 地图显示
57
+ * name
58
+ * fullName,
59
+ * 经纬度
60
+ * lon,
61
+ * lat,
62
+ * 渲染点的数据类型,好通过这个判断点击地图获取到的类型, 任意字符串
63
+ * pointType
64
+ */
65
+ highlightPointMarker(item: any): void;
66
+ hiddenPointMarker(id?: string | undefined): void;
67
+ getFeature(item: any, lonlat: [number, number]): Feature<Point>;
68
+ /**
69
+ *
70
+ * @param lonlat 经纬度
71
+ * @param options {
72
+ * customZoom 自定义层级
73
+ * type 0: 不改变地图大小 1: 等于customZoom 2: 地图当前zoom > 传入的customZoom(缩小地图) 3: 地图当前zoom < 传入的customZoom(放大地图)
74
+ * }
75
+ */
76
+ setPointCenter(lonlat: [number, number], options?: {
77
+ customZoom: number;
78
+ type: number;
79
+ }): void;
80
+ }