@dcloudio/uni-app-x 0.7.36 → 0.7.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/package.json +2 -1
- package/types/UniPage.d.ts +44 -9
- package/types/app.d.ts +8 -5
- package/types/native/AsyncApiResult.d.ts +1 -0
- package/types/native/IUniElement.d.ts +34 -0
- package/types/native/UniElement.d.ts +2 -1
- package/types/native/UniTextElement.d.ts +1 -0
- package/types/native/global.d.ts +10 -0
- package/types/page.d.ts +5 -5
- package/types/uni/env/index.d.ts +15 -1
- package/types/uni/global.d.ts +1 -0
- package/types/uni/index.d.ts +1 -0
- package/types/uni/uni-map-tencent-global.d.ts +33 -0
- package/types/uni/uni-map-tencent-map.d.ts +52 -0
- package/types/uni/uts-plugin-api/global.d.ts +3 -0
- package/types/uni/uts-plugin-api/index.d.ts +3 -0
- package/types/uni/uts-plugin-api/lib/uni-actionSheet/utssdk/global.d.ts +24 -0
- package/types/uni/uts-plugin-api/lib/uni-actionSheet/utssdk/index.d.ts +11 -0
- package/types/uni/uts-plugin-api/lib/uni-actionSheet/utssdk/interface.d.ts +217 -0
- package/types/uni/uts-plugin-api/lib/uni-addPhoneContact/utssdk/global.d.ts +0 -2
- package/types/uni/uts-plugin-api/lib/uni-addPhoneContact/utssdk/index.d.ts +0 -1
- package/types/uni/uts-plugin-api/lib/uni-addPhoneContact/utssdk/interface.d.ts +212 -219
- package/types/uni/uts-plugin-api/lib/uni-arrayBufferToBase64/utssdk/interface.d.ts +1 -1
- package/types/uni/uts-plugin-api/lib/uni-authentication/utssdk/interface.d.ts +130 -4
- package/types/uni/uts-plugin-api/lib/uni-base64ToArrayBuffer/utssdk/interface.d.ts +1 -1
- package/types/uni/uts-plugin-api/lib/uni-canvas/utssdk/interface.d.ts +647 -7
- package/types/uni/uts-plugin-api/lib/uni-chooseLocation/utssdk/global.d.ts +20 -0
- package/types/uni/uts-plugin-api/lib/uni-chooseLocation/utssdk/index.d.ts +9 -0
- package/types/uni/uts-plugin-api/lib/uni-chooseLocation/utssdk/interface.d.ts +153 -0
- package/types/uni/uts-plugin-api/lib/uni-clipboard/utssdk/interface.d.ts +2 -2
- package/types/uni/uts-plugin-api/lib/uni-createInnerAudioContext/utssdk/global.d.ts +4 -0
- package/types/uni/uts-plugin-api/lib/uni-createInnerAudioContext/utssdk/index.d.ts +2 -0
- package/types/uni/uts-plugin-api/lib/uni-createInnerAudioContext/utssdk/interface.d.ts +1995 -1726
- package/types/uni/uts-plugin-api/lib/uni-createIntersectionObserver/utssdk/interface.d.ts +1 -1
- package/types/uni/uts-plugin-api/lib/uni-createSelectorQuery/utssdk/interface.d.ts +102 -18
- package/types/uni/uts-plugin-api/lib/uni-createWebviewContext/utssdk/interface.d.ts +2 -2
- package/types/uni/uts-plugin-api/lib/uni-dialogPage/utssdk/interface.d.ts +1123 -1044
- package/types/uni/uts-plugin-api/lib/uni-event/utssdk/interface.d.ts +327 -296
- package/types/uni/uts-plugin-api/lib/uni-exit/utssdk/interface.d.ts +33 -28
- package/types/uni/uts-plugin-api/lib/uni-file/utssdk/interface.d.ts +210 -0
- package/types/uni/uts-plugin-api/lib/uni-fileSystemManager/utssdk/interface.d.ts +2687 -13
- package/types/uni/uts-plugin-api/lib/uni-getAppAuthorizeSetting/utssdk/interface.d.ts +42 -0
- package/types/uni/uts-plugin-api/lib/uni-getAppBaseInfo/utssdk/interface.d.ts +1178 -2
- package/types/uni/uts-plugin-api/lib/uni-getBackgroundAudioManager/utssdk/interface.d.ts +1 -1
- package/types/uni/uts-plugin-api/lib/uni-getDeviceInfo/utssdk/interface.d.ts +882 -0
- package/types/uni/uts-plugin-api/lib/uni-getEnterOptionsSync/utssdk/interface.d.ts +152 -12
- package/types/uni/uts-plugin-api/lib/uni-getLaunchOptionsSync/utssdk/interface.d.ts +152 -12
- package/types/uni/uts-plugin-api/lib/uni-getLocation/utssdk/interface.d.ts +760 -4
- package/types/uni/uts-plugin-api/lib/uni-getLocation-tencent-uni1/utssdk/global.d.ts +0 -2
- package/types/uni/uts-plugin-api/lib/uni-getLocation-tencent-uni1/utssdk/interface.d.ts +0 -45
- package/types/uni/uts-plugin-api/lib/uni-getNetworkType/utssdk/interface.d.ts +126 -0
- package/types/uni/uts-plugin-api/lib/uni-getPerformance/utssdk/interface.d.ts +38 -3
- package/types/uni/uts-plugin-api/lib/uni-getRecorderManager/utssdk/interface.d.ts +13 -13
- package/types/uni/uts-plugin-api/lib/uni-getSystemInfo/utssdk/interface.d.ts +3119 -1
- package/types/uni/uts-plugin-api/lib/uni-getSystemSetting/utssdk/interface.d.ts +300 -6
- package/types/uni/uts-plugin-api/lib/uni-interceptor/utssdk/interface.d.ts +2 -2
- package/types/uni/uts-plugin-api/lib/uni-keyboard/utssdk/interface.d.ts +42 -0
- package/types/uni/uts-plugin-api/lib/uni-loadFontFace/utssdk/interface.d.ts +8 -8
- package/types/uni/uts-plugin-api/lib/uni-makePhoneCall/utssdk/interface.d.ts +1 -1
- package/types/uni/uts-plugin-api/lib/uni-media/utssdk/global.d.ts +8 -0
- package/types/uni/uts-plugin-api/lib/uni-media/utssdk/index.d.ts +4 -0
- package/types/uni/uts-plugin-api/lib/uni-media/utssdk/interface.d.ts +1686 -266
- package/types/uni/uts-plugin-api/lib/uni-navigationBar/utssdk/interface.d.ts +15 -15
- package/types/uni/uts-plugin-api/lib/uni-network/utssdk/interface.d.ts +3618 -1675
- package/types/uni/uts-plugin-api/lib/uni-oauth/utssdk/interface.d.ts +11 -11
- package/types/uni/uts-plugin-api/lib/uni-openDocument/utssdk/interface.d.ts +42 -0
- package/types/uni/uts-plugin-api/lib/uni-pageScrollTo/utssdk/interface.d.ts +9 -9
- package/types/uni/uts-plugin-api/lib/uni-payment/utssdk/interface.d.ts +252 -0
- package/types/uni/uts-plugin-api/lib/uni-payment-huawei/utssdk/global.d.ts +8 -0
- package/types/uni/uts-plugin-api/lib/uni-payment-huawei/utssdk/index.d.ts +4 -0
- package/types/uni/uts-plugin-api/lib/uni-payment-huawei/utssdk/interface.d.ts +1 -0
- package/types/uni/uts-plugin-api/lib/uni-privacy/utssdk/interface.d.ts +532 -245
- package/types/uni/uts-plugin-api/lib/uni-prompt/utssdk/interface.d.ts +1260 -0
- package/types/uni/uts-plugin-api/lib/uni-pullDownRefresh/utssdk/interface.d.ts +2 -2
- package/types/uni/uts-plugin-api/lib/uni-route/utssdk/interface.d.ts +58 -58
- package/types/uni/uts-plugin-api/lib/uni-rpx2px/utssdk/interface.d.ts +42 -0
- package/types/uni/uts-plugin-api/lib/uni-scanCode/utssdk/interface.d.ts +42 -0
- package/types/uni/uts-plugin-api/lib/uni-shareWithSystem/utssdk/global.d.ts +4 -0
- package/types/uni/uts-plugin-api/lib/uni-shareWithSystem/utssdk/index.d.ts +2 -0
- package/types/uni/uts-plugin-api/lib/uni-shareWithSystem/utssdk/interface.d.ts +614 -15
- package/types/uni/uts-plugin-api/lib/uni-storage/utssdk/interface.d.ts +420 -0
- package/types/uni/uts-plugin-api/lib/uni-tabBar/utssdk/interface.d.ts +50 -8
- package/types/uni/uts-plugin-api/lib/uni-virtualPayment/utssdk/interface.d.ts +267 -99
- package/types/uni/uts-plugin-api/lib/uni-websocket/utssdk/interface.d.ts +978 -12
- package/types/uni/uts-plugin-biz/lib/uni-ad/utssdk/interface.d.ts +1 -1
- package/types/uni/uts-plugin-biz/lib/uni-verify/utssdk/global.d.ts +2 -0
- package/types/uni/uts-plugin-biz/lib/uni-verify/utssdk/index.d.ts +1 -0
- package/types/uni/uts-plugin-biz/lib/uni-verify/utssdk/interface.d.ts +37 -5
- package/types/uni/uts-plugin-component/lib/uni-video/utssdk/interface.d.ts +379 -1
- package/types/uni/uts-plugin-extend/README.md +3 -0
- package/types/uni/uts-plugin-extend/lib/uni-accelerometer/utssdk/interface.d.ts +4 -4
- package/types/uni/uts-plugin-extend/lib/uni-canvas/utssdk/interface.d.ts +4 -4
- package/types/uni/uts-plugin-extend/lib/uni-chooseLocation/utssdk/interface.d.ts +73 -73
- package/types/uni/uts-plugin-extend/lib/uni-compass/utssdk/interface.d.ts +302 -302
- package/types/uni/uts-plugin-extend/lib/uni-createInnerAudioContext/utssdk/interface.d.ts +1 -1
- package/types/uni/uts-plugin-extend/lib/uni-createMapContext/utssdk/interface.d.ts +1 -1
- package/types/uni/uts-plugin-extend/lib/uni-createMediaQueryObserver/utssdk/interface.d.ts +1 -1
- package/types/uni/uts-plugin-extend/lib/uni-getBackgroundAudioManager/utssdk/interface.d.ts +431 -11
- package/types/uni/uts-plugin-extend/lib/uni-locale/utssdk/interface.d.ts +3 -3
- package/types/uni/uts-plugin-extend/lib/uni-localeChange/utssdk/interface.d.ts +6 -6
- package/types/uni/uts-plugin-extend/lib/uni-memory/utssdk/interface.d.ts +2 -2
- package/types/uni/uts-plugin-extend/lib/uni-openLocation/utssdk/interface.d.ts +73 -73
- package/types/uni/uts-plugin-extend/lib/uni-theme/utssdk/interface.d.ts +2 -2
- package/types/uni-cloud/interface.d.ts +91 -0
- package/uts-plugin.d.ts +3 -1
|
@@ -0,0 +1,217 @@
|
|
|
1
|
+
export type Popover2 = {
|
|
2
|
+
/**
|
|
3
|
+
* 指示区域坐标,使用原生 navigationBar 时一般需要加上 navigationBar 的高度
|
|
4
|
+
*/
|
|
5
|
+
top: number,
|
|
6
|
+
/**
|
|
7
|
+
* 指示区域坐标
|
|
8
|
+
*/
|
|
9
|
+
left: number,
|
|
10
|
+
/**
|
|
11
|
+
* 指示区域宽度
|
|
12
|
+
*/
|
|
13
|
+
width: number,
|
|
14
|
+
/**
|
|
15
|
+
* 指示区域高度
|
|
16
|
+
*/
|
|
17
|
+
height: number
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* showActionSheet 错误码
|
|
22
|
+
* - 4: 框架内部异常
|
|
23
|
+
*/
|
|
24
|
+
export type ShowActionSheetErrorCode = 4
|
|
25
|
+
export interface ShowActionSheetSuccess2 extends AsyncApiSuccessResult {
|
|
26
|
+
tapIndex: number
|
|
27
|
+
}
|
|
28
|
+
type ShowActionSheetSuccessCallback = (result: ShowActionSheetSuccess2) => void
|
|
29
|
+
|
|
30
|
+
export interface ShowActionSheetFail2 extends IUniError {
|
|
31
|
+
errCode: ShowActionSheetErrorCode
|
|
32
|
+
}
|
|
33
|
+
type ShowActionSheetFailCallback = (result: ShowActionSheetFail2) => void
|
|
34
|
+
|
|
35
|
+
export type ShowActionSheetComplete = AsyncApiResult
|
|
36
|
+
type ShowActionSheetCompleteCallback = (result: ShowActionSheetComplete) => void
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* uni.showActionSheet函数参数定义
|
|
40
|
+
*/
|
|
41
|
+
export type ShowActionSheet2Options = {
|
|
42
|
+
/**
|
|
43
|
+
* 菜单标题
|
|
44
|
+
*/
|
|
45
|
+
title?: string | null,
|
|
46
|
+
/**
|
|
47
|
+
* 警示文案(仅微信小程序真机有效)
|
|
48
|
+
*/
|
|
49
|
+
alertText?: string | null,
|
|
50
|
+
/**
|
|
51
|
+
* 按钮的文字数组
|
|
52
|
+
*/
|
|
53
|
+
itemList: string[],
|
|
54
|
+
/**
|
|
55
|
+
* 取消按钮的文字,默认为"取消"
|
|
56
|
+
*/
|
|
57
|
+
cancelText?: string | null,
|
|
58
|
+
/**
|
|
59
|
+
* 按钮的文字颜色,字符串格式
|
|
60
|
+
*/
|
|
61
|
+
itemColor?: string.ColorString | null,
|
|
62
|
+
/**
|
|
63
|
+
* 大屏设备弹出原生选择按钮框的指示区域,默认居中显示
|
|
64
|
+
*/
|
|
65
|
+
popover?: Popover2 | null,
|
|
66
|
+
/**
|
|
67
|
+
* 菜单标题文字颜色,字符串格式
|
|
68
|
+
*/
|
|
69
|
+
titleColor?: string.ColorString | null,
|
|
70
|
+
/**
|
|
71
|
+
* 取消按钮的文字颜色,字符串格式
|
|
72
|
+
*/
|
|
73
|
+
cancelColor?: string.ColorString | null,
|
|
74
|
+
/**
|
|
75
|
+
* 弹框背景颜色
|
|
76
|
+
*/
|
|
77
|
+
backgroundColor?: string.ColorString | null,
|
|
78
|
+
/**
|
|
79
|
+
* 接口调用成功的回调函数
|
|
80
|
+
*/
|
|
81
|
+
success?: ShowActionSheetSuccessCallback | null,
|
|
82
|
+
/**
|
|
83
|
+
* 接口调用失败的回调函数
|
|
84
|
+
*/
|
|
85
|
+
fail?: ShowActionSheetFailCallback | null,
|
|
86
|
+
/**
|
|
87
|
+
* 接口调用结束的回调函数(调用成功、失败都会执行)
|
|
88
|
+
*/
|
|
89
|
+
complete?: ShowActionSheetCompleteCallback | null
|
|
90
|
+
};
|
|
91
|
+
|
|
92
|
+
/**
|
|
93
|
+
* 从底部向上弹出操作菜单
|
|
94
|
+
*
|
|
95
|
+
* @param {ShowActionSheetOptions} options
|
|
96
|
+
* @tutorial https://doc.dcloud.net.cn/uni-app-x/api/prompt.html#showactionsheet
|
|
97
|
+
* @uniPlatform {
|
|
98
|
+
* "app": {
|
|
99
|
+
* "android": {
|
|
100
|
+
* "osVer": "5.0",
|
|
101
|
+
* "uniVer": "√",
|
|
102
|
+
* "unixVer": "3.9.0"
|
|
103
|
+
* },
|
|
104
|
+
* "ios": {
|
|
105
|
+
* "osVer": "12.0",
|
|
106
|
+
* "uniVer": "√",
|
|
107
|
+
* "unixVer": "4.11"
|
|
108
|
+
* },
|
|
109
|
+
* "harmony": {
|
|
110
|
+
* "osVer": "3.0",
|
|
111
|
+
* "uniVer": "4.23",
|
|
112
|
+
* "unixVer": "x"
|
|
113
|
+
* }
|
|
114
|
+
* },
|
|
115
|
+
* "web": {
|
|
116
|
+
* "uniVer": "√",
|
|
117
|
+
* "unixVer": "4.0"
|
|
118
|
+
* }
|
|
119
|
+
* }
|
|
120
|
+
*/
|
|
121
|
+
export type ShowActionSheet2 = (options: ShowActionSheet2Options) => void;
|
|
122
|
+
export type HideActionSheet = () => void;
|
|
123
|
+
|
|
124
|
+
export interface Uni {
|
|
125
|
+
/**
|
|
126
|
+
* @description 从底部向上弹出操作菜单
|
|
127
|
+
* @example
|
|
128
|
+
* ```typescript
|
|
129
|
+
* uni.showActionSheet({
|
|
130
|
+
* itemList: ['A', 'B', 'C'],
|
|
131
|
+
* success: function (res) {
|
|
132
|
+
* console.log('选中了第' + (res.tapIndex + 1) + '个按钮');
|
|
133
|
+
* },
|
|
134
|
+
* fail: function (res) {
|
|
135
|
+
* console.log(res.errMsg);
|
|
136
|
+
* }
|
|
137
|
+
* });
|
|
138
|
+
* ```
|
|
139
|
+
* @tutorial https://doc.dcloud.net.cn/uni-app-x/api/show-action-sheet.html
|
|
140
|
+
* @uniPlatform {
|
|
141
|
+
* "app": {
|
|
142
|
+
* "android": {
|
|
143
|
+
* "osVer": "5.0",
|
|
144
|
+
* "uniVer": "√",
|
|
145
|
+
* "unixVer": "3.9.0"
|
|
146
|
+
* },
|
|
147
|
+
* "ios": {
|
|
148
|
+
* "osVer": "12.0",
|
|
149
|
+
* "uniVer": "√",
|
|
150
|
+
* "unixVer": "4.11"
|
|
151
|
+
* },
|
|
152
|
+
* "harmony": {
|
|
153
|
+
* "osVer": "3.0",
|
|
154
|
+
* "uniVer": "4.23",
|
|
155
|
+
* "unixVer": "x"
|
|
156
|
+
* }
|
|
157
|
+
* },
|
|
158
|
+
* "web": {
|
|
159
|
+
* "uniVer": "√",
|
|
160
|
+
* "unixVer": "4.0"
|
|
161
|
+
* }
|
|
162
|
+
* }
|
|
163
|
+
*/
|
|
164
|
+
showActionSheet2(options: ShowActionSheet2Options): void;
|
|
165
|
+
|
|
166
|
+
/**
|
|
167
|
+
* @description 关闭操作菜单
|
|
168
|
+
* @example
|
|
169
|
+
* ```typescript
|
|
170
|
+
* uni.hideActionSheet();
|
|
171
|
+
* ```
|
|
172
|
+
* @tutorial https://doc.dcloud.net.cn/uni-app-x/api/hide-action-sheet.html
|
|
173
|
+
* @uniPlatform {
|
|
174
|
+
* "app": {
|
|
175
|
+
* "android": {
|
|
176
|
+
* "osVer": "5.0",
|
|
177
|
+
* "uniVer": "√",
|
|
178
|
+
* "unixVer": "4.32"
|
|
179
|
+
* },
|
|
180
|
+
* "ios": {
|
|
181
|
+
* "osVer": "12.0",
|
|
182
|
+
* "uniVer": "√",
|
|
183
|
+
* "unixVer": "4.32"
|
|
184
|
+
* },
|
|
185
|
+
* "harmony": {
|
|
186
|
+
* "osVer": "3.0",
|
|
187
|
+
* "uniVer": "4.23",
|
|
188
|
+
* "unixVer": "x"
|
|
189
|
+
* }
|
|
190
|
+
* },
|
|
191
|
+
* "web": {
|
|
192
|
+
* "uniVer": "√",
|
|
193
|
+
* "unixVer": "4.32"
|
|
194
|
+
* }
|
|
195
|
+
* }
|
|
196
|
+
*/
|
|
197
|
+
hideActionSheet(): void;
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
// @ts-expect-error
|
|
201
|
+
export class ShowActionSheetSuccessImpl extends AsyncApiSuccessResult implements ShowActionSheetSuccess2 {
|
|
202
|
+
tapIndex: number
|
|
203
|
+
// @ts-expect-error
|
|
204
|
+
override errMsg: string
|
|
205
|
+
constructor(tapIndex: number, errMsg: string = 'showActionSheet:ok') {
|
|
206
|
+
super()
|
|
207
|
+
this.errMsg = errMsg
|
|
208
|
+
this.tapIndex = tapIndex
|
|
209
|
+
}
|
|
210
|
+
}
|
|
211
|
+
export class ShowActionSheetFailImpl extends UniError implements ShowActionSheetFail2 {
|
|
212
|
+
override errCode: ShowActionSheetErrorCode
|
|
213
|
+
constructor(errMsg: string = 'showActionSheet:fail cancel', errCode: ShowActionSheetErrorCode = 4) {
|
|
214
|
+
super(errMsg)
|
|
215
|
+
this.errCode = errCode
|
|
216
|
+
}
|
|
217
|
+
}
|
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
import {
|
|
3
3
|
AddPhoneContact as AddPhoneContactOrigin,
|
|
4
4
|
AddPhoneContactSuccess as AddPhoneContactSuccessOrigin,
|
|
5
|
-
UniError as UniErrorOrigin,
|
|
6
5
|
AddPhoneContactSuccessCallback as AddPhoneContactSuccessCallbackOrigin,
|
|
7
6
|
AddPhoneContactFail as AddPhoneContactFailOrigin,
|
|
8
7
|
AddPhoneContactFailCallback as AddPhoneContactFailCallbackOrigin,
|
|
@@ -15,7 +14,6 @@ import {
|
|
|
15
14
|
declare global {
|
|
16
15
|
type AddPhoneContact = AddPhoneContactOrigin
|
|
17
16
|
type AddPhoneContactSuccess = AddPhoneContactSuccessOrigin
|
|
18
|
-
type UniError = UniErrorOrigin
|
|
19
17
|
type AddPhoneContactSuccessCallback = AddPhoneContactSuccessCallbackOrigin
|
|
20
18
|
type AddPhoneContactFail = AddPhoneContactFailOrigin
|
|
21
19
|
type AddPhoneContactFailCallback = AddPhoneContactFailCallbackOrigin
|
|
@@ -1,231 +1,224 @@
|
|
|
1
1
|
export interface Uni {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
2
|
+
/**
|
|
3
|
+
* 手机通讯录联系人和联系方式的增加
|
|
4
|
+
* @tutorial https://uniapp.dcloud.net.cn/api/system/contact.html
|
|
5
|
+
* @tutorial-uni-app https://uniapp.dcloud.net.cn/api/system/contact.html
|
|
6
|
+
*
|
|
7
|
+
* @uniPlatform {
|
|
8
|
+
* "app": {
|
|
9
|
+
* "android": {
|
|
10
|
+
* "osVer": "5.0",
|
|
11
|
+
* "uniVer": "√",
|
|
12
|
+
* "unixVer": "x"
|
|
13
|
+
* },
|
|
14
|
+
* "ios": {
|
|
15
|
+
* "osVer": "12.0",
|
|
16
|
+
* "uniVer": "√",
|
|
17
|
+
* "unixVer": "x"
|
|
18
|
+
* },
|
|
19
|
+
* "harmony": {
|
|
20
|
+
* "osVer": "3.0",
|
|
21
|
+
* "uniVer": "4.25",
|
|
22
|
+
* "unixVer": "x"
|
|
23
|
+
* }
|
|
24
|
+
* },
|
|
25
|
+
* "web": {
|
|
26
|
+
* "uniVer": "x",
|
|
27
|
+
* "unixVer": "x"
|
|
28
|
+
* }
|
|
29
|
+
* "mp":{
|
|
30
|
+
* weixin: {
|
|
31
|
+
* hostVer: '√',
|
|
32
|
+
* uniVer: '√',
|
|
33
|
+
* unixVer: '4.35'
|
|
34
|
+
* },
|
|
35
|
+
* alipay: {
|
|
36
|
+
* hostVer: '√',
|
|
37
|
+
* uniVer: '√',
|
|
38
|
+
* unixVer: 'x'
|
|
39
|
+
* },
|
|
40
|
+
* baidu: {
|
|
41
|
+
* hostVer: '√',
|
|
42
|
+
* uniVer: '√',
|
|
43
|
+
* unixVer: 'x'
|
|
44
|
+
* },
|
|
45
|
+
* toutiao: {
|
|
46
|
+
* hostVer: 'x',
|
|
47
|
+
* uniVer: 'x',
|
|
48
|
+
* unixVer: 'x'
|
|
49
|
+
* },
|
|
50
|
+
* lark: {
|
|
51
|
+
* hostVer: 'x',
|
|
52
|
+
* uniVer: 'x',
|
|
53
|
+
* unixVer: 'x'
|
|
54
|
+
* },
|
|
55
|
+
* qq: {
|
|
56
|
+
* hostVer: 'x',
|
|
57
|
+
* uniVer: 'x',
|
|
58
|
+
* unixVer: 'x'
|
|
59
|
+
* },
|
|
60
|
+
* kuaishou: {
|
|
61
|
+
* hostVer: '√',
|
|
62
|
+
* uniVer: '√',
|
|
63
|
+
* unixVer: 'x'
|
|
64
|
+
* },
|
|
65
|
+
* jd: {
|
|
66
|
+
* hostVer: 'x',
|
|
67
|
+
* uniVer: 'x',
|
|
68
|
+
* unixVer: 'x'
|
|
69
|
+
* }
|
|
70
|
+
* }
|
|
71
|
+
* }
|
|
72
|
+
*/
|
|
73
|
+
addPhoneContact: AddPhoneContact;
|
|
74
74
|
}
|
|
75
75
|
|
|
76
76
|
export type AddPhoneContact = (options: AddPhoneContactOptions) => void;
|
|
77
77
|
export type AddPhoneContactSuccess = {};
|
|
78
|
-
export type UniError = {
|
|
79
|
-
errSubject: string,
|
|
80
|
-
errCode: number,
|
|
81
|
-
errMsg: string,
|
|
82
|
-
data?: object | null,
|
|
83
|
-
cause?: any | null
|
|
84
|
-
};
|
|
85
78
|
export type AddPhoneContactSuccessCallback = (result: AddPhoneContactSuccess) => void;
|
|
86
79
|
export type AddPhoneContactFail = UniError;
|
|
87
80
|
export type AddPhoneContactFailCallback = (result: AddPhoneContactFail) => void;
|
|
88
81
|
export type AddPhoneContactComplete = any;
|
|
89
82
|
export type AddPhoneContactCompleteCallback = (result: AddPhoneContactComplete) => void;
|
|
90
83
|
export type AddPhoneContactOptions = {
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
84
|
+
/**
|
|
85
|
+
* 头像本地文件路径
|
|
86
|
+
*/
|
|
87
|
+
photoFilePath?: string | null,
|
|
88
|
+
/**
|
|
89
|
+
* 昵称
|
|
90
|
+
*/
|
|
91
|
+
nickName?: string | null,
|
|
92
|
+
/**
|
|
93
|
+
* 姓氏
|
|
94
|
+
*/
|
|
95
|
+
lastName?: string | null,
|
|
96
|
+
/**
|
|
97
|
+
* 中间名
|
|
98
|
+
*/
|
|
99
|
+
middleName?: string | null,
|
|
100
|
+
/**
|
|
101
|
+
* 名字
|
|
102
|
+
*/
|
|
103
|
+
firstName?: string | null,
|
|
104
|
+
/**
|
|
105
|
+
* 备注
|
|
106
|
+
*/
|
|
107
|
+
remark?: string | null,
|
|
108
|
+
/**
|
|
109
|
+
* 手机号
|
|
110
|
+
*/
|
|
111
|
+
mobilePhoneNumber?: string | null,
|
|
112
|
+
/**
|
|
113
|
+
* 微信号
|
|
114
|
+
*/
|
|
115
|
+
weChatNumber?: string | null,
|
|
116
|
+
/**
|
|
117
|
+
* 联系地址国家
|
|
118
|
+
*/
|
|
119
|
+
addressCountry?: string | null,
|
|
120
|
+
/**
|
|
121
|
+
* 联系地址省份
|
|
122
|
+
*/
|
|
123
|
+
addressState?: string | null,
|
|
124
|
+
/**
|
|
125
|
+
* 联系地址城市
|
|
126
|
+
*/
|
|
127
|
+
addressCity?: string | null,
|
|
128
|
+
/**
|
|
129
|
+
* 联系地址街道
|
|
130
|
+
*/
|
|
131
|
+
addressStreet?: string | null,
|
|
132
|
+
/**
|
|
133
|
+
* 联系地址邮政编码
|
|
134
|
+
*/
|
|
135
|
+
addressPostalCode?: string | null,
|
|
136
|
+
/**
|
|
137
|
+
* 公司
|
|
138
|
+
*/
|
|
139
|
+
organization?: string | null,
|
|
140
|
+
/**
|
|
141
|
+
* 职位
|
|
142
|
+
*/
|
|
143
|
+
title?: string | null,
|
|
144
|
+
/**
|
|
145
|
+
* 工作传真
|
|
146
|
+
*/
|
|
147
|
+
workFaxNumber?: string | null,
|
|
148
|
+
/**
|
|
149
|
+
* 工作电话
|
|
150
|
+
*/
|
|
151
|
+
workPhoneNumber?: string | null,
|
|
152
|
+
/**
|
|
153
|
+
* 公司电话
|
|
154
|
+
*/
|
|
155
|
+
hostNumber?: string | null,
|
|
156
|
+
/**
|
|
157
|
+
* 电子邮件
|
|
158
|
+
*/
|
|
159
|
+
email?: string | null,
|
|
160
|
+
/**
|
|
161
|
+
* 网站
|
|
162
|
+
*/
|
|
163
|
+
url?: string | null,
|
|
164
|
+
/**
|
|
165
|
+
* 工作地址国家
|
|
166
|
+
*/
|
|
167
|
+
workAddressCountry?: string | null,
|
|
168
|
+
/**
|
|
169
|
+
* 工作地址省份
|
|
170
|
+
*/
|
|
171
|
+
workAddressState?: string | null,
|
|
172
|
+
/**
|
|
173
|
+
* 工作地址城市
|
|
174
|
+
*/
|
|
175
|
+
workAddressCity?: string | null,
|
|
176
|
+
/**
|
|
177
|
+
* 工作地址街道
|
|
178
|
+
*/
|
|
179
|
+
workAddressStreet?: string | null,
|
|
180
|
+
/**
|
|
181
|
+
* 工作地址邮政编码
|
|
182
|
+
*/
|
|
183
|
+
workAddressPostalCode?: string | null,
|
|
184
|
+
/**
|
|
185
|
+
* 住宅传真
|
|
186
|
+
*/
|
|
187
|
+
homeFaxNumber?: string | null,
|
|
188
|
+
/**
|
|
189
|
+
* 住宅电话
|
|
190
|
+
*/
|
|
191
|
+
homePhoneNumber?: string | null,
|
|
192
|
+
/**
|
|
193
|
+
* 住宅地址国家
|
|
194
|
+
*/
|
|
195
|
+
homeAddressCountry?: string | null,
|
|
196
|
+
/**
|
|
197
|
+
* 住宅地址省份
|
|
198
|
+
*/
|
|
199
|
+
homeAddressState?: string | null,
|
|
200
|
+
/**
|
|
201
|
+
* 住宅地址城市
|
|
202
|
+
*/
|
|
203
|
+
homeAddressCity?: string | null,
|
|
204
|
+
/**
|
|
205
|
+
* 住宅地址街道
|
|
206
|
+
*/
|
|
207
|
+
homeAddressStreet?: string | null,
|
|
208
|
+
/**
|
|
209
|
+
* 住宅地址邮政编码
|
|
210
|
+
*/
|
|
211
|
+
homeAddressPostalCode?: string | null,
|
|
212
|
+
/**
|
|
213
|
+
* 接口调用成功的回调函数
|
|
214
|
+
*/
|
|
215
|
+
success?: AddPhoneContactSuccessCallback | null,
|
|
216
|
+
/**
|
|
217
|
+
* 接口调用失败的回调函数
|
|
218
|
+
*/
|
|
219
|
+
fail?: AddPhoneContactFailCallback | null,
|
|
220
|
+
/**
|
|
221
|
+
* 接口调用结束的回调函数(调用成功、失败都会执行)
|
|
222
|
+
*/
|
|
223
|
+
complete?: AddPhoneContactCompleteCallback | null
|
|
231
224
|
};
|