@dcloudio/uni-app-x 0.7.121 → 0.7.122
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/README.md +87 -0
- package/package.json +1 -1
- package/types/dom2-internal/UniCommon.d.ts +7 -2
- package/types/dom2-internal/UniNativeDefines.d.ts +7 -2
- package/types/uni/uts-plugin-api/global.d.ts +8 -0
- package/types/uni/uts-plugin-api/index.d.ts +8 -0
- package/types/uni/uts-plugin-api/lib/uni-accelerometer/utssdk/global.d.ts +35 -0
- package/types/uni/uts-plugin-api/lib/uni-accelerometer/utssdk/index.d.ts +17 -0
- package/types/uni/uts-plugin-api/lib/uni-accelerometer/utssdk/interface.d.ts +359 -0
- package/types/uni/uts-plugin-api/lib/uni-authentication/utssdk/interface.d.ts +323 -1294
- package/types/uni/uts-plugin-api/lib/uni-calendar/utssdk/global.d.ts +35 -0
- package/types/uni/uts-plugin-api/lib/uni-calendar/utssdk/index.d.ts +17 -0
- package/types/uni/uts-plugin-api/lib/uni-calendar/utssdk/interface.d.ts +944 -0
- package/types/uni/uts-plugin-api/lib/uni-canvas-dom2/utssdk/interface.d.ts +2 -1
- package/types/uni/{uts-plugin-extend → uts-plugin-api}/lib/uni-compass/utssdk/global.d.ts +16 -6
- package/types/uni/{uts-plugin-extend → uts-plugin-api}/lib/uni-compass/utssdk/index.d.ts +9 -3
- package/types/uni/uts-plugin-api/lib/uni-compass/utssdk/interface.d.ts +353 -0
- package/types/uni/uts-plugin-api/lib/uni-editor/utssdk/global.d.ts +2 -0
- package/types/uni/uts-plugin-api/lib/uni-editor/utssdk/index.d.ts +1 -0
- package/types/uni/uts-plugin-api/lib/uni-editor/utssdk/interface.d.ts +144 -110
- package/types/uni/uts-plugin-api/lib/uni-gyroscope/utssdk/global.d.ts +35 -0
- package/types/uni/uts-plugin-api/lib/uni-gyroscope/utssdk/index.d.ts +17 -0
- package/types/uni/uts-plugin-api/lib/uni-gyroscope/utssdk/interface.d.ts +362 -0
- package/types/uni/uts-plugin-api/lib/uni-memorywarning/utssdk/global.d.ts +21 -0
- package/types/uni/uts-plugin-api/lib/uni-memorywarning/utssdk/index.d.ts +10 -0
- package/types/uni/uts-plugin-api/lib/uni-memorywarning/utssdk/interface.d.ts +20 -0
- package/types/uni/uts-plugin-api/lib/uni-openLocation/utssdk/global.d.ts +23 -0
- package/types/uni/uts-plugin-api/lib/uni-openLocation/utssdk/index.d.ts +11 -0
- package/types/uni/uts-plugin-api/lib/uni-openLocation/utssdk/interface.d.ts +418 -0
- package/types/uni/uts-plugin-api/lib/uni-phoneContact/utssdk/global.d.ts +49 -0
- package/types/uni/uts-plugin-api/lib/uni-phoneContact/utssdk/index.d.ts +24 -0
- package/types/uni/uts-plugin-api/lib/uni-phoneContact/utssdk/interface.d.ts +349 -0
- package/types/uni/uts-plugin-api/lib/uni-privacy/utssdk/global.d.ts +2 -0
- package/types/uni/uts-plugin-api/lib/uni-privacy/utssdk/index.d.ts +1 -0
- package/types/uni/uts-plugin-api/lib/uni-privacy/utssdk/interface.d.ts +83 -124
- package/types/uni/uts-plugin-api/lib/uni-screenBrightness/utssdk/interface.d.ts +3 -3
- package/types/uni/uts-plugin-api/lib/uni-vibrate/utssdk/global.d.ts +27 -0
- package/types/uni/uts-plugin-api/lib/uni-vibrate/utssdk/index.d.ts +13 -0
- package/types/uni/uts-plugin-api/lib/uni-vibrate/utssdk/interface.d.ts +88 -0
- package/types/uni/uts-plugin-biz/global.d.ts +9 -0
- package/types/uni/uts-plugin-biz/index.d.ts +9 -0
- package/types/uni/uts-plugin-biz/lib/uni-accelerometer/utssdk/global.d.ts +35 -0
- package/types/uni/uts-plugin-biz/lib/uni-accelerometer/utssdk/index.d.ts +17 -0
- package/types/uni/uts-plugin-biz/lib/uni-accelerometer/utssdk/interface.d.ts +359 -0
- package/types/uni/uts-plugin-biz/lib/uni-authentication/utssdk/global.d.ts +59 -0
- package/types/uni/uts-plugin-biz/lib/uni-authentication/utssdk/index.d.ts +29 -0
- package/types/uni/uts-plugin-biz/lib/uni-authentication/utssdk/interface.d.ts +371 -0
- package/types/uni/uts-plugin-biz/lib/uni-calendar/utssdk/global.d.ts +35 -0
- package/types/uni/uts-plugin-biz/lib/uni-calendar/utssdk/index.d.ts +17 -0
- package/types/uni/uts-plugin-biz/lib/uni-calendar/utssdk/interface.d.ts +944 -0
- package/types/uni/uts-plugin-biz/lib/uni-compass/utssdk/global.d.ts +35 -0
- package/types/uni/uts-plugin-biz/lib/uni-compass/utssdk/index.d.ts +17 -0
- package/types/uni/uts-plugin-biz/lib/uni-compass/utssdk/interface.d.ts +353 -0
- package/types/uni/uts-plugin-biz/lib/uni-gyroscope/utssdk/global.d.ts +35 -0
- package/types/uni/uts-plugin-biz/lib/uni-gyroscope/utssdk/index.d.ts +17 -0
- package/types/uni/uts-plugin-biz/lib/uni-gyroscope/utssdk/interface.d.ts +362 -0
- package/types/uni/uts-plugin-biz/lib/uni-memorywarning/utssdk/global.d.ts +21 -0
- package/types/uni/uts-plugin-biz/lib/uni-memorywarning/utssdk/index.d.ts +10 -0
- package/types/uni/uts-plugin-biz/lib/uni-memorywarning/utssdk/interface.d.ts +20 -0
- package/types/uni/uts-plugin-biz/lib/uni-phoneContact/utssdk/global.d.ts +49 -0
- package/types/uni/uts-plugin-biz/lib/uni-phoneContact/utssdk/index.d.ts +24 -0
- package/types/uni/uts-plugin-biz/lib/uni-phoneContact/utssdk/interface.d.ts +349 -0
- package/types/uni/uts-plugin-biz/lib/uni-screenBrightness/utssdk/global.d.ts +57 -0
- package/types/uni/uts-plugin-biz/lib/uni-screenBrightness/utssdk/index.d.ts +28 -0
- package/types/uni/uts-plugin-biz/lib/uni-screenBrightness/utssdk/interface.d.ts +1172 -0
- package/types/uni/uts-plugin-biz/lib/uni-verify/utssdk/interface.d.ts +6 -1
- package/types/uni/uts-plugin-biz/lib/uni-vibrate/utssdk/global.d.ts +27 -0
- package/types/uni/uts-plugin-biz/lib/uni-vibrate/utssdk/index.d.ts +13 -0
- package/types/uni/uts-plugin-biz/lib/uni-vibrate/utssdk/interface.d.ts +88 -0
- package/types/uni/uts-plugin-component/global.d.ts +8 -1
- package/types/uni/uts-plugin-component/index.d.ts +8 -1
- package/types/uni/uts-plugin-component/lib/uni-accelerometer/utssdk/global.d.ts +35 -0
- package/types/uni/uts-plugin-component/lib/uni-accelerometer/utssdk/index.d.ts +17 -0
- package/types/uni/uts-plugin-component/lib/uni-accelerometer/utssdk/interface.d.ts +359 -0
- package/types/uni/uts-plugin-component/lib/uni-authentication/utssdk/interface.d.ts +1342 -371
- package/types/uni/uts-plugin-component/lib/uni-calendar/utssdk/global.d.ts +35 -0
- package/types/uni/uts-plugin-component/lib/uni-calendar/utssdk/index.d.ts +17 -0
- package/types/uni/uts-plugin-component/lib/uni-calendar/utssdk/interface.d.ts +944 -0
- package/types/uni/uts-plugin-component/lib/uni-canvas-dom2/utssdk/interface.d.ts +2 -1
- package/types/uni/uts-plugin-component/lib/uni-compass/utssdk/global.d.ts +35 -0
- package/types/uni/uts-plugin-component/lib/uni-compass/utssdk/index.d.ts +17 -0
- package/types/uni/uts-plugin-component/lib/uni-compass/utssdk/interface.d.ts +353 -0
- package/types/uni/uts-plugin-component/lib/uni-editor/utssdk/global.d.ts +2 -0
- package/types/uni/uts-plugin-component/lib/uni-editor/utssdk/index.d.ts +1 -0
- package/types/uni/uts-plugin-component/lib/uni-editor/utssdk/interface.d.ts +144 -110
- package/types/uni/uts-plugin-component/lib/uni-editor-global/utssdk/interface.d.ts +13 -4
- package/types/uni/uts-plugin-component/lib/uni-gyroscope/utssdk/global.d.ts +35 -0
- package/types/uni/uts-plugin-component/lib/uni-gyroscope/utssdk/index.d.ts +17 -0
- package/types/uni/uts-plugin-component/lib/uni-gyroscope/utssdk/interface.d.ts +362 -0
- package/types/uni/uts-plugin-component/lib/uni-memorywarning/utssdk/global.d.ts +21 -0
- package/types/uni/uts-plugin-component/lib/uni-memorywarning/utssdk/index.d.ts +10 -0
- package/types/uni/uts-plugin-component/lib/uni-memorywarning/utssdk/interface.d.ts +20 -0
- package/types/uni/uts-plugin-component/lib/uni-openLocation/utssdk/global.d.ts +23 -0
- package/types/uni/uts-plugin-component/lib/uni-openLocation/utssdk/index.d.ts +11 -0
- package/types/uni/uts-plugin-component/lib/uni-openLocation/utssdk/interface.d.ts +420 -0
- package/types/uni/uts-plugin-component/lib/uni-phoneContact/utssdk/global.d.ts +49 -0
- package/types/uni/uts-plugin-component/lib/uni-phoneContact/utssdk/index.d.ts +24 -0
- package/types/uni/uts-plugin-component/lib/uni-phoneContact/utssdk/interface.d.ts +349 -0
- package/types/uni/uts-plugin-component/lib/uni-privacy/utssdk/global.d.ts +2 -0
- package/types/uni/uts-plugin-component/lib/uni-privacy/utssdk/index.d.ts +1 -0
- package/types/uni/uts-plugin-component/lib/uni-privacy/utssdk/interface.d.ts +132 -75
- package/types/uni/uts-plugin-component/lib/uni-screenBrightness/utssdk/interface.d.ts +3 -3
- package/types/uni/uts-plugin-component/lib/uni-vibrate/utssdk/global.d.ts +27 -0
- package/types/uni/uts-plugin-component/lib/uni-vibrate/utssdk/index.d.ts +13 -0
- package/types/uni/uts-plugin-component/lib/uni-vibrate/utssdk/interface.d.ts +88 -0
- package/types/uni/uts-plugin-extend/lib/uni-accelerometer/utssdk/global.d.ts +0 -12
- package/types/uni/uts-plugin-extend/lib/uni-accelerometer/utssdk/index.d.ts +0 -1
- package/types/uni/uts-plugin-extend/lib/uni-accelerometer/utssdk/interface.d.ts +0 -917
- package/types/uni/uts-plugin-extend/lib/uni-compass/utssdk/interface.d.ts +0 -1095
- package/types/uni/uts-plugin-extend/lib/uni-memory/utssdk/interface.d.ts +0 -253
|
@@ -0,0 +1,418 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 错误码
|
|
3
|
+
*/
|
|
4
|
+
export type OpenLocationErrorCode =
|
|
5
|
+
/**
|
|
6
|
+
* 框架内部错误
|
|
7
|
+
* @uniPlatform {
|
|
8
|
+
* "app": {
|
|
9
|
+
* "android": {
|
|
10
|
+
* "osVer": "5.0",
|
|
11
|
+
* "uniVer": "√",
|
|
12
|
+
* "unixVer": "5.09"
|
|
13
|
+
* },
|
|
14
|
+
* "ios": {
|
|
15
|
+
* "osVer": "12.0",
|
|
16
|
+
* "uniVer": "√",
|
|
17
|
+
* "unixVer": "5.09"
|
|
18
|
+
* },
|
|
19
|
+
* "harmony": {
|
|
20
|
+
* "osVer": "3.0",
|
|
21
|
+
* "uniVer": "4.23",
|
|
22
|
+
* "unixVer": "5.09"
|
|
23
|
+
* }
|
|
24
|
+
* },
|
|
25
|
+
* "web": {
|
|
26
|
+
* "uniVer": "√",
|
|
27
|
+
* "unixVer": "4.0"
|
|
28
|
+
* },
|
|
29
|
+
* "mp": {
|
|
30
|
+
* "weixin": {
|
|
31
|
+
* "uniVer": "x",
|
|
32
|
+
* "unixVer": "x"
|
|
33
|
+
* }
|
|
34
|
+
* }
|
|
35
|
+
* }
|
|
36
|
+
*/
|
|
37
|
+
4;
|
|
38
|
+
|
|
39
|
+
export interface OpenLocationSuccess {
|
|
40
|
+
errMsg : string
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
type OpenLocationSuccessCallback = (result : OpenLocationSuccess) => void
|
|
44
|
+
|
|
45
|
+
export interface OpenLocationFail extends IUniError {
|
|
46
|
+
errCode : OpenLocationErrorCode
|
|
47
|
+
}
|
|
48
|
+
type OpenLocationFailCallback = (result : OpenLocationFail) => void
|
|
49
|
+
|
|
50
|
+
export type OpenLocationComplete = any
|
|
51
|
+
type OpenLocationCompleteCallback = (result : OpenLocationComplete) => void
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* uni.openLocation函数参数定义
|
|
55
|
+
*/
|
|
56
|
+
export type OpenLocationOptions = {
|
|
57
|
+
/**
|
|
58
|
+
* 纬度,范围为-90~90,负数表示南纬,使用 gcj02 国测局坐标系
|
|
59
|
+
* @uniPlatform {
|
|
60
|
+
* "app": {
|
|
61
|
+
* "android": {
|
|
62
|
+
* "osVer": "5.0",
|
|
63
|
+
* "uniVer": "√",
|
|
64
|
+
* "unixVer": "5.09"
|
|
65
|
+
* },
|
|
66
|
+
* "ios": {
|
|
67
|
+
* "osVer": "12.0",
|
|
68
|
+
* "uniVer": "√",
|
|
69
|
+
* "unixVer": "5.09"
|
|
70
|
+
* },
|
|
71
|
+
* "harmony": {
|
|
72
|
+
* "osVer": "3.0",
|
|
73
|
+
* "uniVer": "4.23",
|
|
74
|
+
* "unixVer": "5.09"
|
|
75
|
+
* }
|
|
76
|
+
* },
|
|
77
|
+
* "web": {
|
|
78
|
+
* "uniVer": "√",
|
|
79
|
+
* "unixVer": "4.0"
|
|
80
|
+
* },
|
|
81
|
+
* "mp": {
|
|
82
|
+
* "weixin": {
|
|
83
|
+
* "uniVer": "√",
|
|
84
|
+
* "unixVer": "5.09"
|
|
85
|
+
* }
|
|
86
|
+
* }
|
|
87
|
+
* }
|
|
88
|
+
*/
|
|
89
|
+
latitude : number,
|
|
90
|
+
/**
|
|
91
|
+
* 经度,范围为-180~180,负数表示西经,使用 gcj02 国测局坐标系
|
|
92
|
+
* @uniPlatform {
|
|
93
|
+
* "app": {
|
|
94
|
+
* "android": {
|
|
95
|
+
* "osVer": "5.0",
|
|
96
|
+
* "uniVer": "√",
|
|
97
|
+
* "unixVer": "5.09"
|
|
98
|
+
* },
|
|
99
|
+
* "ios": {
|
|
100
|
+
* "osVer": "12.0",
|
|
101
|
+
* "uniVer": "√",
|
|
102
|
+
* "unixVer": "5.09"
|
|
103
|
+
* },
|
|
104
|
+
* "harmony": {
|
|
105
|
+
* "osVer": "3.0",
|
|
106
|
+
* "uniVer": "4.23",
|
|
107
|
+
* "unixVer": "5.09"
|
|
108
|
+
* }
|
|
109
|
+
* },
|
|
110
|
+
* "web": {
|
|
111
|
+
* "uniVer": "√",
|
|
112
|
+
* "unixVer": "4.0"
|
|
113
|
+
* },
|
|
114
|
+
* "mp": {
|
|
115
|
+
* "weixin": {
|
|
116
|
+
* "uniVer": "√",
|
|
117
|
+
* "unixVer": "5.09"
|
|
118
|
+
* }
|
|
119
|
+
* }
|
|
120
|
+
* }
|
|
121
|
+
*/
|
|
122
|
+
longitude : number,
|
|
123
|
+
/**
|
|
124
|
+
* 缩放比例,范围5~18,默认为18(微信小程序)
|
|
125
|
+
* @uniPlatform {
|
|
126
|
+
* "app": {
|
|
127
|
+
* "android": {
|
|
128
|
+
* "osVer": "5.0",
|
|
129
|
+
* "uniVer": "√",
|
|
130
|
+
* "unixVer": "5.09"
|
|
131
|
+
* },
|
|
132
|
+
* "ios": {
|
|
133
|
+
* "osVer": "12.0",
|
|
134
|
+
* "uniVer": "√",
|
|
135
|
+
* "unixVer": "5.09"
|
|
136
|
+
* },
|
|
137
|
+
* "harmony": {
|
|
138
|
+
* "osVer": "3.0",
|
|
139
|
+
* "uniVer": "4.23",
|
|
140
|
+
* "unixVer": "5.09"
|
|
141
|
+
* }
|
|
142
|
+
* },
|
|
143
|
+
* "web": {
|
|
144
|
+
* "uniVer": "√",
|
|
145
|
+
* "unixVer": "4.0"
|
|
146
|
+
* },
|
|
147
|
+
* "mp": {
|
|
148
|
+
* "weixin": {
|
|
149
|
+
* "uniVer": "√",
|
|
150
|
+
* "unixVer": "5.09"
|
|
151
|
+
* }
|
|
152
|
+
* }
|
|
153
|
+
* }
|
|
154
|
+
*/
|
|
155
|
+
scale ?: number | null,
|
|
156
|
+
/**
|
|
157
|
+
* 位置名
|
|
158
|
+
* @uniPlatform {
|
|
159
|
+
* "app": {
|
|
160
|
+
* "android": {
|
|
161
|
+
* "osVer": "5.0",
|
|
162
|
+
* "uniVer": "√",
|
|
163
|
+
* "unixVer": "5.09"
|
|
164
|
+
* },
|
|
165
|
+
* "ios": {
|
|
166
|
+
* "osVer": "12.0",
|
|
167
|
+
* "uniVer": "√",
|
|
168
|
+
* "unixVer": "5.09"
|
|
169
|
+
* },
|
|
170
|
+
* "harmony": {
|
|
171
|
+
* "osVer": "3.0",
|
|
172
|
+
* "uniVer": "4.23",
|
|
173
|
+
* "unixVer": "5.09"
|
|
174
|
+
* }
|
|
175
|
+
* },
|
|
176
|
+
* "web": {
|
|
177
|
+
* "uniVer": "√",
|
|
178
|
+
* "unixVer": "4.0"
|
|
179
|
+
* },
|
|
180
|
+
* "mp": {
|
|
181
|
+
* "weixin": {
|
|
182
|
+
* "uniVer": "√",
|
|
183
|
+
* "unixVer": "5.09"
|
|
184
|
+
* }
|
|
185
|
+
* }
|
|
186
|
+
* }
|
|
187
|
+
*/
|
|
188
|
+
name ?: string | null,
|
|
189
|
+
/**
|
|
190
|
+
* 地址的详细说明
|
|
191
|
+
* @uniPlatform {
|
|
192
|
+
* "app": {
|
|
193
|
+
* "android": {
|
|
194
|
+
* "osVer": "5.0",
|
|
195
|
+
* "uniVer": "√",
|
|
196
|
+
* "unixVer": "5.09"
|
|
197
|
+
* },
|
|
198
|
+
* "ios": {
|
|
199
|
+
* "osVer": "12.0",
|
|
200
|
+
* "uniVer": "√",
|
|
201
|
+
* "unixVer": "5.09"
|
|
202
|
+
* },
|
|
203
|
+
* "harmony": {
|
|
204
|
+
* "osVer": "3.0",
|
|
205
|
+
* "uniVer": "4.23",
|
|
206
|
+
* "unixVer": "5.09"
|
|
207
|
+
* }
|
|
208
|
+
* },
|
|
209
|
+
* "web": {
|
|
210
|
+
* "uniVer": "√",
|
|
211
|
+
* "unixVer": "4.0"
|
|
212
|
+
* },
|
|
213
|
+
* "mp": {
|
|
214
|
+
* "weixin": {
|
|
215
|
+
* "uniVer": "√",
|
|
216
|
+
* "unixVer": "5.09"
|
|
217
|
+
* }
|
|
218
|
+
* }
|
|
219
|
+
* }
|
|
220
|
+
*/
|
|
221
|
+
address ?: string | null,
|
|
222
|
+
/**
|
|
223
|
+
* 接口调用成功的回调函数
|
|
224
|
+
* @uniPlatform {
|
|
225
|
+
* "app": {
|
|
226
|
+
* "android": {
|
|
227
|
+
* "osVer": "5.0",
|
|
228
|
+
* "uniVer": "√",
|
|
229
|
+
* "unixVer": "5.09"
|
|
230
|
+
* },
|
|
231
|
+
* "ios": {
|
|
232
|
+
* "osVer": "12.0",
|
|
233
|
+
* "uniVer": "√",
|
|
234
|
+
* "unixVer": "5.09"
|
|
235
|
+
* },
|
|
236
|
+
* "harmony": {
|
|
237
|
+
* "osVer": "3.0",
|
|
238
|
+
* "uniVer": "4.23",
|
|
239
|
+
* "unixVer": "5.09"
|
|
240
|
+
* }
|
|
241
|
+
* },
|
|
242
|
+
* "web": {
|
|
243
|
+
* "uniVer": "√",
|
|
244
|
+
* "unixVer": "4.0"
|
|
245
|
+
* },
|
|
246
|
+
* "mp": {
|
|
247
|
+
* "weixin": {
|
|
248
|
+
* "uniVer": "√",
|
|
249
|
+
* "unixVer": "5.09"
|
|
250
|
+
* }
|
|
251
|
+
* }
|
|
252
|
+
* }
|
|
253
|
+
*/
|
|
254
|
+
success ?: OpenLocationSuccessCallback | null,
|
|
255
|
+
/**
|
|
256
|
+
* 接口调用失败的回调函数
|
|
257
|
+
* @uniPlatform {
|
|
258
|
+
* "app": {
|
|
259
|
+
* "android": {
|
|
260
|
+
* "osVer": "5.0",
|
|
261
|
+
* "uniVer": "√",
|
|
262
|
+
* "unixVer": "5.09"
|
|
263
|
+
* },
|
|
264
|
+
* "ios": {
|
|
265
|
+
* "osVer": "12.0",
|
|
266
|
+
* "uniVer": "√",
|
|
267
|
+
* "unixVer": "5.09"
|
|
268
|
+
* },
|
|
269
|
+
* "harmony": {
|
|
270
|
+
* "osVer": "3.0",
|
|
271
|
+
* "uniVer": "4.23",
|
|
272
|
+
* "unixVer": "5.09"
|
|
273
|
+
* }
|
|
274
|
+
* },
|
|
275
|
+
* "web": {
|
|
276
|
+
* "uniVer": "√",
|
|
277
|
+
* "unixVer": "4.0"
|
|
278
|
+
* },
|
|
279
|
+
* "mp": {
|
|
280
|
+
* "weixin": {
|
|
281
|
+
* "uniVer": "√",
|
|
282
|
+
* "unixVer": "5.09"
|
|
283
|
+
* }
|
|
284
|
+
* }
|
|
285
|
+
* }
|
|
286
|
+
*/
|
|
287
|
+
fail ?: OpenLocationFailCallback | null,
|
|
288
|
+
/**
|
|
289
|
+
* 接口调用结束的回调函数(调用成功、失败都会执行)
|
|
290
|
+
* @uniPlatform {
|
|
291
|
+
* "app": {
|
|
292
|
+
* "android": {
|
|
293
|
+
* "osVer": "5.0",
|
|
294
|
+
* "uniVer": "√",
|
|
295
|
+
* "unixVer": "5.09"
|
|
296
|
+
* },
|
|
297
|
+
* "ios": {
|
|
298
|
+
* "osVer": "12.0",
|
|
299
|
+
* "uniVer": "√",
|
|
300
|
+
* "unixVer": "5.09"
|
|
301
|
+
* },
|
|
302
|
+
* "harmony": {
|
|
303
|
+
* "osVer": "3.0",
|
|
304
|
+
* "uniVer": "4.23",
|
|
305
|
+
* "unixVer": "5.09"
|
|
306
|
+
* }
|
|
307
|
+
* },
|
|
308
|
+
* "web": {
|
|
309
|
+
* "uniVer": "√",
|
|
310
|
+
* "unixVer": "4.0"
|
|
311
|
+
* },
|
|
312
|
+
* "mp": {
|
|
313
|
+
* "weixin": {
|
|
314
|
+
* "uniVer": "√",
|
|
315
|
+
* "unixVer": "5.09"
|
|
316
|
+
* }
|
|
317
|
+
* }
|
|
318
|
+
* }
|
|
319
|
+
*/
|
|
320
|
+
complete ?: OpenLocationCompleteCallback | null
|
|
321
|
+
};
|
|
322
|
+
|
|
323
|
+
/**
|
|
324
|
+
* 使用应用内置地图查看位置
|
|
325
|
+
*
|
|
326
|
+
* @param {OpenLocationOptions} options
|
|
327
|
+
* @tutorial https://doc.dcloud.net.cn/uni-app-x/api/prompt.html#openLocation
|
|
328
|
+
* @uniPlatform {
|
|
329
|
+
* "app": {
|
|
330
|
+
* "android": {
|
|
331
|
+
* "osVer": "5.0",
|
|
332
|
+
* "uniVer": "√",
|
|
333
|
+
* "unixVer": "5.09"
|
|
334
|
+
* },
|
|
335
|
+
* "ios": {
|
|
336
|
+
* "osVer": "12.0",
|
|
337
|
+
* "uniVer": "√",
|
|
338
|
+
* "unixVer": "5.09"
|
|
339
|
+
* },
|
|
340
|
+
* "harmony": {
|
|
341
|
+
* "osVer": "3.0",
|
|
342
|
+
* "uniVer": "4.23",
|
|
343
|
+
* "unixVer": "5.09"
|
|
344
|
+
* }
|
|
345
|
+
* },
|
|
346
|
+
* "web": {
|
|
347
|
+
* "uniVer": "√",
|
|
348
|
+
* "unixVer": "4.0"
|
|
349
|
+
* },
|
|
350
|
+
* "mp": {
|
|
351
|
+
* "weixin": {
|
|
352
|
+
* "uniVer": "√",
|
|
353
|
+
* "unixVer": "5.09"
|
|
354
|
+
* }
|
|
355
|
+
* }
|
|
356
|
+
* }
|
|
357
|
+
*/
|
|
358
|
+
export type OpenLocation = (options : OpenLocationOptions) => void;
|
|
359
|
+
|
|
360
|
+
export interface Uni {
|
|
361
|
+
/**
|
|
362
|
+
* @description 使用应用内置地图查看位置
|
|
363
|
+
* @example
|
|
364
|
+
* ```typescript
|
|
365
|
+
uni.openLocation({
|
|
366
|
+
latitude: 39.908823,
|
|
367
|
+
longitude: 116.39747,
|
|
368
|
+
success: (res) => {
|
|
369
|
+
console.log('res: ', res)
|
|
370
|
+
},
|
|
371
|
+
fail: (err) => {
|
|
372
|
+
console.log('err: ', err)
|
|
373
|
+
},
|
|
374
|
+
complete: (res) => {
|
|
375
|
+
console.log('complete: ', res)
|
|
376
|
+
}
|
|
377
|
+
});
|
|
378
|
+
* ```
|
|
379
|
+
* @tutorial https://doc.dcloud.net.cn/uni-app-x/api/prompt.html#openLocation
|
|
380
|
+
* @uniPlatform {
|
|
381
|
+
* "app": {
|
|
382
|
+
* "android": {
|
|
383
|
+
* "osVer": "5.0",
|
|
384
|
+
* "uniVer": "√",
|
|
385
|
+
* "unixVer": "5.09"
|
|
386
|
+
* },
|
|
387
|
+
* "ios": {
|
|
388
|
+
* "osVer": "12.0",
|
|
389
|
+
* "uniVer": "√",
|
|
390
|
+
* "unixVer": "5.09"
|
|
391
|
+
* },
|
|
392
|
+
* "harmony": {
|
|
393
|
+
* "osVer": "3.0",
|
|
394
|
+
* "uniVer": "4.23",
|
|
395
|
+
* "unixVer": "5.09"
|
|
396
|
+
* }
|
|
397
|
+
* },
|
|
398
|
+
* "web": {
|
|
399
|
+
* "uniVer": "√",
|
|
400
|
+
* "unixVer": "4.0"
|
|
401
|
+
* },
|
|
402
|
+
* "mp": {
|
|
403
|
+
* "weixin": {
|
|
404
|
+
* "uniVer": "√",
|
|
405
|
+
* "unixVer": "5.09"
|
|
406
|
+
* }
|
|
407
|
+
* }
|
|
408
|
+
* }
|
|
409
|
+
*/
|
|
410
|
+
openLocation(options : OpenLocationOptions) : void;
|
|
411
|
+
}
|
|
412
|
+
|
|
413
|
+
export class OpenLocationSuccessImpl implements OpenLocationSuccess {
|
|
414
|
+
errMsg : string
|
|
415
|
+
constructor(errMsg : string = 'openLocation:ok') {
|
|
416
|
+
this.errMsg = errMsg
|
|
417
|
+
}
|
|
418
|
+
}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
// 本文件为自动构建生成
|
|
2
|
+
import {
|
|
3
|
+
AddPhoneContact as AddPhoneContactOrigin,
|
|
4
|
+
AddPhoneContactSuccess as AddPhoneContactSuccessOrigin,
|
|
5
|
+
AddPhoneContactSuccessCallback as AddPhoneContactSuccessCallbackOrigin,
|
|
6
|
+
AddPhoneContactErrorCode as AddPhoneContactErrorCodeOrigin,
|
|
7
|
+
IAddPhoneContactFail as IAddPhoneContactFailOrigin,
|
|
8
|
+
AddPhoneContactFail as AddPhoneContactFailOrigin,
|
|
9
|
+
AddPhoneContactFailCallback as AddPhoneContactFailCallbackOrigin,
|
|
10
|
+
AddPhoneContactComplete as AddPhoneContactCompleteOrigin,
|
|
11
|
+
AddPhoneContactCompleteCallback as AddPhoneContactCompleteCallbackOrigin,
|
|
12
|
+
AddPhoneContactOptions as AddPhoneContactOptionsOrigin,
|
|
13
|
+
ChooseContact as ChooseContactOrigin,
|
|
14
|
+
ChooseContactSuccess as ChooseContactSuccessOrigin,
|
|
15
|
+
ChooseContactSuccessCallback as ChooseContactSuccessCallbackOrigin,
|
|
16
|
+
ChooseContactErrorCode as ChooseContactErrorCodeOrigin,
|
|
17
|
+
IChooseContactFail as IChooseContactFailOrigin,
|
|
18
|
+
ChooseContactFail as ChooseContactFailOrigin,
|
|
19
|
+
ChooseContactFailCallback as ChooseContactFailCallbackOrigin,
|
|
20
|
+
ChooseContactComplete as ChooseContactCompleteOrigin,
|
|
21
|
+
ChooseContactCompleteCallback as ChooseContactCompleteCallbackOrigin,
|
|
22
|
+
ChooseContactOptions as ChooseContactOptionsOrigin,
|
|
23
|
+
Uni as UniOrigin
|
|
24
|
+
} from './interface'
|
|
25
|
+
|
|
26
|
+
declare global {
|
|
27
|
+
type AddPhoneContact = AddPhoneContactOrigin
|
|
28
|
+
type AddPhoneContactSuccess = AddPhoneContactSuccessOrigin
|
|
29
|
+
type AddPhoneContactSuccessCallback = AddPhoneContactSuccessCallbackOrigin
|
|
30
|
+
type AddPhoneContactErrorCode = AddPhoneContactErrorCodeOrigin
|
|
31
|
+
type IAddPhoneContactFail = IAddPhoneContactFailOrigin
|
|
32
|
+
type AddPhoneContactFail = AddPhoneContactFailOrigin
|
|
33
|
+
type AddPhoneContactFailCallback = AddPhoneContactFailCallbackOrigin
|
|
34
|
+
type AddPhoneContactComplete = AddPhoneContactCompleteOrigin
|
|
35
|
+
type AddPhoneContactCompleteCallback = AddPhoneContactCompleteCallbackOrigin
|
|
36
|
+
type AddPhoneContactOptions = AddPhoneContactOptionsOrigin
|
|
37
|
+
type ChooseContact = ChooseContactOrigin
|
|
38
|
+
type ChooseContactSuccess = ChooseContactSuccessOrigin
|
|
39
|
+
type ChooseContactSuccessCallback = ChooseContactSuccessCallbackOrigin
|
|
40
|
+
type ChooseContactErrorCode = ChooseContactErrorCodeOrigin
|
|
41
|
+
type IChooseContactFail = IChooseContactFailOrigin
|
|
42
|
+
type ChooseContactFail = ChooseContactFailOrigin
|
|
43
|
+
type ChooseContactFailCallback = ChooseContactFailCallbackOrigin
|
|
44
|
+
type ChooseContactComplete = ChooseContactCompleteOrigin
|
|
45
|
+
type ChooseContactCompleteCallback = ChooseContactCompleteCallbackOrigin
|
|
46
|
+
type ChooseContactOptions = ChooseContactOptionsOrigin
|
|
47
|
+
interface Uni extends UniOrigin { }
|
|
48
|
+
}
|
|
49
|
+
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
// 本文件为自动构建生成
|
|
2
|
+
export {
|
|
3
|
+
AddPhoneContact,
|
|
4
|
+
AddPhoneContactSuccess,
|
|
5
|
+
AddPhoneContactSuccessCallback,
|
|
6
|
+
AddPhoneContactErrorCode,
|
|
7
|
+
IAddPhoneContactFail,
|
|
8
|
+
AddPhoneContactFail,
|
|
9
|
+
AddPhoneContactFailCallback,
|
|
10
|
+
AddPhoneContactComplete,
|
|
11
|
+
AddPhoneContactCompleteCallback,
|
|
12
|
+
AddPhoneContactOptions,
|
|
13
|
+
ChooseContact,
|
|
14
|
+
ChooseContactSuccess,
|
|
15
|
+
ChooseContactSuccessCallback,
|
|
16
|
+
ChooseContactErrorCode,
|
|
17
|
+
IChooseContactFail,
|
|
18
|
+
ChooseContactFail,
|
|
19
|
+
ChooseContactFailCallback,
|
|
20
|
+
ChooseContactComplete,
|
|
21
|
+
ChooseContactCompleteCallback,
|
|
22
|
+
ChooseContactOptions,
|
|
23
|
+
} from './interface'
|
|
24
|
+
|