mirage2d 1.2.9 → 1.2.10
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/Layer/XMap.d.ts +7 -0
- package/dist/Tools/util/json.d.ts +1 -0
- package/dist/base/baseClass.d.ts +1 -1
- package/dist/base/baseOptionType.d.ts +5 -2
- package/dist/extend/Control/swipe.d.ts +1 -1
- package/dist/graphic/baseGraphic.d.ts +59 -41
- package/dist/mirage2d.cjs.js +37 -37
- package/dist/mirage2d.umd.js +37 -37
- package/package.json +1 -1
package/dist/Layer/XMap.d.ts
CHANGED
|
@@ -54,7 +54,14 @@ export declare class MirageMap extends baseMap {
|
|
|
54
54
|
* @param {string} mapID
|
|
55
55
|
*/
|
|
56
56
|
init(mapID: string): void;
|
|
57
|
+
/**
|
|
58
|
+
* 打开卷帘
|
|
59
|
+
* @param {object} layer - 配置项对象
|
|
60
|
+
*/
|
|
57
61
|
openSplitInteraction(layer: any): void;
|
|
62
|
+
/**
|
|
63
|
+
* 关闭卷帘
|
|
64
|
+
*/
|
|
58
65
|
closeSplitInteraction(): void;
|
|
59
66
|
/**
|
|
60
67
|
* 显示网格
|
package/dist/base/baseClass.d.ts
CHANGED
|
@@ -64,8 +64,8 @@ export interface IFeatureAnimationOptions {
|
|
|
64
64
|
repeat?: number;
|
|
65
65
|
hiddenStyle?: Style;
|
|
66
66
|
horizontal?: boolean;
|
|
67
|
-
fade?: (
|
|
68
|
-
easing?: (
|
|
67
|
+
fade?: (p0: number) => number;
|
|
68
|
+
easing?: (p0: number) => number;
|
|
69
69
|
}
|
|
70
70
|
export interface ITooltipInfo {
|
|
71
71
|
dataType: any;
|
|
@@ -247,6 +247,9 @@ export interface IImageStyle {
|
|
|
247
247
|
radius?: number;
|
|
248
248
|
fill?: IFillOption;
|
|
249
249
|
stroke?: IStrokeOption;
|
|
250
|
+
points?: number;
|
|
251
|
+
angle?: number;
|
|
252
|
+
rotation?: number;
|
|
250
253
|
}
|
|
251
254
|
export interface ILabelStyle {
|
|
252
255
|
text?: ITextOption;
|
|
@@ -19,6 +19,6 @@ export declare class swipeControl extends eventTarget {
|
|
|
19
19
|
* @param {string} orientation 方向默认值 "vertical" 水平 "horizontal"
|
|
20
20
|
* @returns {*}
|
|
21
21
|
*/
|
|
22
|
-
show(leftlayerID:
|
|
22
|
+
show(leftlayerID: string, rightlayerID: string, orientation?: string): any;
|
|
23
23
|
hide(): void;
|
|
24
24
|
}
|
|
@@ -37,10 +37,10 @@ export declare class baseGraphic extends Feature {
|
|
|
37
37
|
*/
|
|
38
38
|
setSmooth(param?: number, isLine?: boolean): void;
|
|
39
39
|
/**
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
40
|
+
* 设置图形文字样式
|
|
41
|
+
* @param {ITextOption} textStyleOption
|
|
42
|
+
* @example
|
|
43
|
+
* setTextStyle({
|
|
44
44
|
font: "14px Microsoft YaHei",
|
|
45
45
|
text: "示例",
|
|
46
46
|
fill: {
|
|
@@ -62,13 +62,13 @@ export declare class baseGraphic extends Feature {
|
|
|
62
62
|
offsetY: -10,
|
|
63
63
|
textBaseline: "bottom",
|
|
64
64
|
})
|
|
65
|
-
|
|
65
|
+
*/
|
|
66
66
|
setTextStyle(textStyleOption: ITextOption): void;
|
|
67
67
|
/**
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
68
|
+
* 设置正方形样式
|
|
69
|
+
* @param {IImageStyle} ImageStyleOption
|
|
70
|
+
* @example
|
|
71
|
+
* setSquarePointStyle({
|
|
72
72
|
scale: 1, // 比例
|
|
73
73
|
radius: 5, // 大小
|
|
74
74
|
fill: {
|
|
@@ -77,16 +77,16 @@ export declare class baseGraphic extends Feature {
|
|
|
77
77
|
stroke: {
|
|
78
78
|
color: "rgba(255, 255, 0,1)", // 边框色
|
|
79
79
|
width: 1, //宽度
|
|
80
|
-
|
|
80
|
+
|
|
81
81
|
},
|
|
82
82
|
})
|
|
83
|
-
|
|
84
|
-
setSquarePointStyle(ImageStyleOption
|
|
83
|
+
*/
|
|
84
|
+
setSquarePointStyle(ImageStyleOption?: IImageStyle): void;
|
|
85
85
|
/**
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
86
|
+
* 设置三角点样式
|
|
87
|
+
* @param {IImageStyle} ImageStyleOption
|
|
88
|
+
* @example
|
|
89
|
+
* setTrianglePointStyle({
|
|
90
90
|
scale: 1, //比例
|
|
91
91
|
radius: 5, //大小
|
|
92
92
|
fill: {
|
|
@@ -95,16 +95,16 @@ export declare class baseGraphic extends Feature {
|
|
|
95
95
|
stroke: {
|
|
96
96
|
color: "rgba(255, 255, 0,1)", // 边框色
|
|
97
97
|
width: 1, //宽度
|
|
98
|
-
|
|
98
|
+
|
|
99
99
|
},
|
|
100
100
|
})
|
|
101
|
-
|
|
102
|
-
setTrianglePointStyle(ImageStyleOption
|
|
101
|
+
*/
|
|
102
|
+
setTrianglePointStyle(ImageStyleOption?: IImageStyle): void;
|
|
103
103
|
/**
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
104
|
+
* 设置五角星点样式
|
|
105
|
+
* @param {IImageStyle} ImageStyleOption
|
|
106
|
+
* @example
|
|
107
|
+
* setStarPointStyle({
|
|
108
108
|
scale: 1, //比例
|
|
109
109
|
radius: 5, //大小
|
|
110
110
|
fill: {
|
|
@@ -113,27 +113,45 @@ export declare class baseGraphic extends Feature {
|
|
|
113
113
|
stroke: {
|
|
114
114
|
color: "rgba(255, 255, 0,1)", // 边框色
|
|
115
115
|
width: 1, //宽度
|
|
116
|
-
|
|
116
|
+
|
|
117
|
+
},
|
|
118
|
+
})
|
|
119
|
+
*/
|
|
120
|
+
setStarPointStyle(ImageStyleOption?: IImageStyle): void;
|
|
121
|
+
/**
|
|
122
|
+
* 设置圆点样式
|
|
123
|
+
* @param {IImageStyle} ImageStyleOption
|
|
124
|
+
* @example
|
|
125
|
+
* setCirclePointStyle({
|
|
126
|
+
scale: 1, //比例
|
|
127
|
+
radius: 5, //大小
|
|
128
|
+
fill: {
|
|
129
|
+
color: "rgba(255, 0, 0,1)", // 填充色
|
|
130
|
+
},
|
|
131
|
+
stroke: {
|
|
132
|
+
color: "rgba(255, 255, 0,1)", // 边框色
|
|
133
|
+
width: 1, //宽度
|
|
134
|
+
|
|
117
135
|
},
|
|
118
136
|
})
|
|
119
|
-
|
|
120
|
-
setCirclePointStyle(ImageStyleOption
|
|
137
|
+
*/
|
|
138
|
+
setCirclePointStyle(ImageStyleOption?: IImageStyle): void;
|
|
121
139
|
/**
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
140
|
+
* 设置边框简单模式样式
|
|
141
|
+
* @param {IStrokeOption} strokeStyleOption
|
|
142
|
+
* @example
|
|
143
|
+
* setStrokeSimpleStyle({
|
|
126
144
|
color: "rgba(255, 255, 255,1)", //"#fff",
|
|
127
145
|
width: 2, //2,
|
|
128
146
|
lineDash:[10,10] 或null
|
|
129
147
|
})
|
|
130
|
-
|
|
148
|
+
*/
|
|
131
149
|
setStrokeSimpleStyle(strokeStyleOption: IStrokeOption): void;
|
|
132
150
|
/**
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
151
|
+
* 设置边框图案填充模式样式,pattern与image 二选一,不用的需undefined,同时配置优先pattern
|
|
152
|
+
* @param {IStrokeOption} strokeStyleOption
|
|
153
|
+
* @example
|
|
154
|
+
* setStrokePatternStyle({
|
|
137
155
|
pattern: undefined,图案Enum:mirage2d.DataType.featureStyleType.caps
|
|
138
156
|
// image: undefined,
|
|
139
157
|
color: "rgba(255, 255, 0,1)",//背景色
|
|
@@ -147,7 +165,7 @@ export declare class baseGraphic extends Feature {
|
|
|
147
165
|
spacing: 10,
|
|
148
166
|
angle: 0
|
|
149
167
|
})
|
|
150
|
-
|
|
168
|
+
*/
|
|
151
169
|
setStrokePatternStyle(strokeStyleOption: IStrokeOption): void;
|
|
152
170
|
/**
|
|
153
171
|
* 设置填充简单模式样式 ,从图片模式转到普通模式时,需注意等图片加载完成后才可设置
|
|
@@ -157,10 +175,10 @@ export declare class baseGraphic extends Feature {
|
|
|
157
175
|
*/
|
|
158
176
|
setFillColor(color: string): void;
|
|
159
177
|
/**
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
178
|
+
* 设置多边形图案填充模式样式,pattern与image 二选一,不用的需undefined,同时配置优先pattern
|
|
179
|
+
* @param {IFillOption} fillStyleOption
|
|
180
|
+
* @example
|
|
181
|
+
* setFillPatternStyle({
|
|
164
182
|
pattern: undefined,图案Enum:mirage2d.DataType.featureStyleType.caps
|
|
165
183
|
// image: undefined,
|
|
166
184
|
patternColor: "rgba(0, 0, 0,1)",//图案颜色
|
|
@@ -174,7 +192,7 @@ export declare class baseGraphic extends Feature {
|
|
|
174
192
|
spacing: 10,
|
|
175
193
|
angle: 0
|
|
176
194
|
})
|
|
177
|
-
|
|
195
|
+
*/
|
|
178
196
|
setFillPatternStyle(fillStyleOption: IFillOption): void;
|
|
179
197
|
/**
|
|
180
198
|
* 设置多边形图片填充模式样式,初始设置时当pattern==null或undefined 且image有值才能生效
|