@dcloudio/uni-app-x 0.7.120 → 0.7.121

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.
Files changed (174) hide show
  1. package/package.json +1 -1
  2. package/types/app.d.ts +2 -1
  3. package/types/dom2-internal/UniPage.d.ts +6 -0
  4. package/types/native/DrawableContext.d.ts +104 -52
  5. package/types/native/IUniElement.d.ts +4 -2
  6. package/types/node_modules/.package-lock.json +20 -0
  7. package/types/node_modules/typescript/LICENSE.txt +55 -0
  8. package/types/node_modules/typescript/ThirdPartyNoticeText.txt +193 -0
  9. package/types/node_modules/typescript/bin/tsc +2 -0
  10. package/types/node_modules/typescript/bin/tsserver +2 -0
  11. package/types/node_modules/typescript/lib/cancellationToken.js +90 -0
  12. package/types/node_modules/typescript/lib/cs/diagnosticMessages.generated.json +1880 -0
  13. package/types/node_modules/typescript/lib/de/diagnosticMessages.generated.json +1880 -0
  14. package/types/node_modules/typescript/lib/es/diagnosticMessages.generated.json +1880 -0
  15. package/types/node_modules/typescript/lib/fr/diagnosticMessages.generated.json +1880 -0
  16. package/types/node_modules/typescript/lib/it/diagnosticMessages.generated.json +1880 -0
  17. package/types/node_modules/typescript/lib/ja/diagnosticMessages.generated.json +1880 -0
  18. package/types/node_modules/typescript/lib/ko/diagnosticMessages.generated.json +1880 -0
  19. package/types/node_modules/typescript/lib/lib.d.ts +22 -0
  20. package/types/node_modules/typescript/lib/lib.decorators.d.ts +386 -0
  21. package/types/node_modules/typescript/lib/lib.decorators.legacy.d.ts +22 -0
  22. package/types/node_modules/typescript/lib/lib.dom.asynciterable.d.ts +33 -0
  23. package/types/node_modules/typescript/lib/lib.dom.d.ts +28596 -0
  24. package/types/node_modules/typescript/lib/lib.dom.iterable.d.ts +475 -0
  25. package/types/node_modules/typescript/lib/lib.es2015.collection.d.ts +147 -0
  26. package/types/node_modules/typescript/lib/lib.es2015.core.d.ts +597 -0
  27. package/types/node_modules/typescript/lib/lib.es2015.d.ts +28 -0
  28. package/types/node_modules/typescript/lib/lib.es2015.generator.d.ts +77 -0
  29. package/types/node_modules/typescript/lib/lib.es2015.iterable.d.ts +495 -0
  30. package/types/node_modules/typescript/lib/lib.es2015.promise.d.ts +81 -0
  31. package/types/node_modules/typescript/lib/lib.es2015.proxy.d.ts +128 -0
  32. package/types/node_modules/typescript/lib/lib.es2015.reflect.d.ts +144 -0
  33. package/types/node_modules/typescript/lib/lib.es2015.symbol.d.ts +46 -0
  34. package/types/node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts +326 -0
  35. package/types/node_modules/typescript/lib/lib.es2016.array.include.d.ts +116 -0
  36. package/types/node_modules/typescript/lib/lib.es2016.d.ts +21 -0
  37. package/types/node_modules/typescript/lib/lib.es2016.full.d.ts +23 -0
  38. package/types/node_modules/typescript/lib/lib.es2016.intl.d.ts +31 -0
  39. package/types/node_modules/typescript/lib/lib.es2017.d.ts +25 -0
  40. package/types/node_modules/typescript/lib/lib.es2017.date.d.ts +31 -0
  41. package/types/node_modules/typescript/lib/lib.es2017.full.d.ts +23 -0
  42. package/types/node_modules/typescript/lib/lib.es2017.intl.d.ts +44 -0
  43. package/types/node_modules/typescript/lib/lib.es2017.object.d.ts +49 -0
  44. package/types/node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts +135 -0
  45. package/types/node_modules/typescript/lib/lib.es2017.string.d.ts +45 -0
  46. package/types/node_modules/typescript/lib/lib.es2017.typedarrays.d.ts +53 -0
  47. package/types/node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts +77 -0
  48. package/types/node_modules/typescript/lib/lib.es2018.asynciterable.d.ts +43 -0
  49. package/types/node_modules/typescript/lib/lib.es2018.d.ts +24 -0
  50. package/types/node_modules/typescript/lib/lib.es2018.full.d.ts +24 -0
  51. package/types/node_modules/typescript/lib/lib.es2018.intl.d.ts +83 -0
  52. package/types/node_modules/typescript/lib/lib.es2018.promise.d.ts +30 -0
  53. package/types/node_modules/typescript/lib/lib.es2018.regexp.d.ts +37 -0
  54. package/types/node_modules/typescript/lib/lib.es2019.array.d.ts +79 -0
  55. package/types/node_modules/typescript/lib/lib.es2019.d.ts +24 -0
  56. package/types/node_modules/typescript/lib/lib.es2019.full.d.ts +24 -0
  57. package/types/node_modules/typescript/lib/lib.es2019.intl.d.ts +23 -0
  58. package/types/node_modules/typescript/lib/lib.es2019.object.d.ts +33 -0
  59. package/types/node_modules/typescript/lib/lib.es2019.string.d.ts +37 -0
  60. package/types/node_modules/typescript/lib/lib.es2019.symbol.d.ts +24 -0
  61. package/types/node_modules/typescript/lib/lib.es2020.bigint.d.ts +727 -0
  62. package/types/node_modules/typescript/lib/lib.es2020.d.ts +27 -0
  63. package/types/node_modules/typescript/lib/lib.es2020.date.d.ts +42 -0
  64. package/types/node_modules/typescript/lib/lib.es2020.full.d.ts +24 -0
  65. package/types/node_modules/typescript/lib/lib.es2020.intl.d.ts +474 -0
  66. package/types/node_modules/typescript/lib/lib.es2020.number.d.ts +28 -0
  67. package/types/node_modules/typescript/lib/lib.es2020.promise.d.ts +47 -0
  68. package/types/node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts +97 -0
  69. package/types/node_modules/typescript/lib/lib.es2020.string.d.ts +42 -0
  70. package/types/node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts +37 -0
  71. package/types/node_modules/typescript/lib/lib.es2021.d.ts +23 -0
  72. package/types/node_modules/typescript/lib/lib.es2021.full.d.ts +24 -0
  73. package/types/node_modules/typescript/lib/lib.es2021.intl.d.ts +166 -0
  74. package/types/node_modules/typescript/lib/lib.es2021.promise.d.ts +48 -0
  75. package/types/node_modules/typescript/lib/lib.es2021.string.d.ts +33 -0
  76. package/types/node_modules/typescript/lib/lib.es2021.weakref.d.ts +76 -0
  77. package/types/node_modules/typescript/lib/lib.es2022.array.d.ts +121 -0
  78. package/types/node_modules/typescript/lib/lib.es2022.d.ts +26 -0
  79. package/types/node_modules/typescript/lib/lib.es2022.error.d.ts +73 -0
  80. package/types/node_modules/typescript/lib/lib.es2022.full.d.ts +24 -0
  81. package/types/node_modules/typescript/lib/lib.es2022.intl.d.ts +117 -0
  82. package/types/node_modules/typescript/lib/lib.es2022.object.d.ts +26 -0
  83. package/types/node_modules/typescript/lib/lib.es2022.regexp.d.ts +39 -0
  84. package/types/node_modules/typescript/lib/lib.es2022.sharedmemory.d.ts +39 -0
  85. package/types/node_modules/typescript/lib/lib.es2022.string.d.ts +25 -0
  86. package/types/node_modules/typescript/lib/lib.es2023.array.d.ts +924 -0
  87. package/types/node_modules/typescript/lib/lib.es2023.collection.d.ts +21 -0
  88. package/types/node_modules/typescript/lib/lib.es2023.d.ts +22 -0
  89. package/types/node_modules/typescript/lib/lib.es2023.full.d.ts +24 -0
  90. package/types/node_modules/typescript/lib/lib.es2023.intl.d.ts +56 -0
  91. package/types/node_modules/typescript/lib/lib.es5.d.ts +4585 -0
  92. package/types/node_modules/typescript/lib/lib.es6.d.ts +23 -0
  93. package/types/node_modules/typescript/lib/lib.esnext.array.d.ts +35 -0
  94. package/types/node_modules/typescript/lib/lib.esnext.collection.d.ts +106 -0
  95. package/types/node_modules/typescript/lib/lib.esnext.d.ts +28 -0
  96. package/types/node_modules/typescript/lib/lib.esnext.decorators.d.ts +28 -0
  97. package/types/node_modules/typescript/lib/lib.esnext.disposable.d.ts +185 -0
  98. package/types/node_modules/typescript/lib/lib.esnext.full.d.ts +24 -0
  99. package/types/node_modules/typescript/lib/lib.esnext.intl.d.ts +21 -0
  100. package/types/node_modules/typescript/lib/lib.esnext.object.d.ts +29 -0
  101. package/types/node_modules/typescript/lib/lib.esnext.promise.d.ts +35 -0
  102. package/types/node_modules/typescript/lib/lib.esnext.regexp.d.ts +25 -0
  103. package/types/node_modules/typescript/lib/lib.esnext.string.d.ts +29 -0
  104. package/types/node_modules/typescript/lib/lib.scripthost.d.ts +322 -0
  105. package/types/node_modules/typescript/lib/lib.webworker.asynciterable.d.ts +33 -0
  106. package/types/node_modules/typescript/lib/lib.webworker.d.ts +9431 -0
  107. package/types/node_modules/typescript/lib/lib.webworker.importscripts.d.ts +23 -0
  108. package/types/node_modules/typescript/lib/lib.webworker.iterable.d.ts +276 -0
  109. package/types/node_modules/typescript/lib/pl/diagnosticMessages.generated.json +1880 -0
  110. package/types/node_modules/typescript/lib/pt-br/diagnosticMessages.generated.json +1880 -0
  111. package/types/node_modules/typescript/lib/ru/diagnosticMessages.generated.json +1880 -0
  112. package/types/node_modules/typescript/lib/tr/diagnosticMessages.generated.json +1880 -0
  113. package/types/node_modules/typescript/lib/tsc.js +129741 -0
  114. package/types/node_modules/typescript/lib/tsserver.js +621 -0
  115. package/types/node_modules/typescript/lib/tsserverlibrary.d.ts +17 -0
  116. package/types/node_modules/typescript/lib/tsserverlibrary.js +21 -0
  117. package/types/node_modules/typescript/lib/typesMap.json +497 -0
  118. package/types/node_modules/typescript/lib/typescript.d.ts +11240 -0
  119. package/types/node_modules/typescript/lib/typescript.js +194910 -0
  120. package/types/node_modules/typescript/lib/typingsInstaller.js +236 -0
  121. package/types/node_modules/typescript/lib/watchGuard.js +53 -0
  122. package/types/node_modules/typescript/lib/zh-cn/diagnosticMessages.generated.json +1880 -0
  123. package/types/node_modules/typescript/lib/zh-tw/diagnosticMessages.generated.json +1880 -0
  124. package/types/node_modules/typescript/package.json +116 -0
  125. package/types/page.d.ts +2 -2
  126. package/types/uni/env/index.d.ts +2 -1
  127. package/types/uni/uts-plugin-api/lib/uni-dialogPage/utssdk/global.d.ts +0 -2
  128. package/types/uni/uts-plugin-api/lib/uni-dialogPage/utssdk/index.d.ts +0 -1
  129. package/types/uni/uts-plugin-api/lib/uni-dialogPage/utssdk/interface.d.ts +0 -1
  130. package/types/uni/uts-plugin-api/lib/uni-getElementById/utssdk/interface.d.ts +1 -0
  131. package/types/uni/uts-plugin-api/lib/uni-getEnterOptionsSync/utssdk/interface.d.ts +72 -531
  132. package/types/uni/uts-plugin-api/lib/uni-getLaunchOptionsSync/utssdk/interface.d.ts +72 -531
  133. package/types/uni/uts-plugin-api/lib/uni-keyboard/utssdk/interface.d.ts +6 -6
  134. package/types/uni/uts-plugin-api/lib/uni-makePhoneCall/utssdk/interface.d.ts +72 -68
  135. package/types/uni/uts-plugin-api/lib/uni-modal/utssdk/global.d.ts +8 -12
  136. package/types/uni/uts-plugin-api/lib/uni-modal/utssdk/index.d.ts +4 -6
  137. package/types/uni/uts-plugin-api/lib/uni-modal/utssdk/interface.d.ts +1741 -905
  138. package/types/uni/uts-plugin-api/lib/uni-oauth/utssdk/interface.d.ts +12 -12
  139. package/types/uni/uts-plugin-api/lib/uni-screenBrightness/utssdk/interface.d.ts +1157 -830
  140. package/types/uni/uts-plugin-api/lib/uni-share/utssdk/interface.d.ts +936 -335
  141. package/types/uni/uts-plugin-api/lib/uni-showLoading/utssdk/global.d.ts +8 -0
  142. package/types/uni/uts-plugin-api/lib/uni-showLoading/utssdk/index.d.ts +4 -0
  143. package/types/uni/uts-plugin-api/lib/uni-showLoading/utssdk/interface.d.ts +1155 -1142
  144. package/types/uni/uts-plugin-api/lib/uni-web-view/utssdk/interface.d.ts +6 -6
  145. package/types/uni/uts-plugin-component/lib/uni-dialogPage/utssdk/global.d.ts +0 -2
  146. package/types/uni/uts-plugin-component/lib/uni-dialogPage/utssdk/index.d.ts +0 -1
  147. package/types/uni/uts-plugin-component/lib/uni-dialogPage/utssdk/interface.d.ts +0 -1
  148. package/types/uni/uts-plugin-component/lib/uni-editor-global/utssdk/interface.d.ts +2 -1
  149. package/types/uni/uts-plugin-component/lib/uni-form-global/utssdk/interface.d.ts +1 -1
  150. package/types/uni/uts-plugin-component/lib/uni-getElementById/utssdk/interface.d.ts +1 -0
  151. package/types/uni/uts-plugin-component/lib/uni-getEnterOptionsSync/utssdk/interface.d.ts +531 -72
  152. package/types/uni/uts-plugin-component/lib/uni-getLaunchOptionsSync/utssdk/interface.d.ts +531 -72
  153. package/types/uni/uts-plugin-component/lib/uni-keyboard/utssdk/interface.d.ts +6 -6
  154. package/types/uni/uts-plugin-component/lib/uni-makePhoneCall/utssdk/interface.d.ts +73 -67
  155. package/types/uni/uts-plugin-component/lib/uni-match-media-global/utssdk/interface.d.ts +1 -1
  156. package/types/uni/uts-plugin-component/lib/uni-modal/utssdk/global.d.ts +8 -12
  157. package/types/uni/uts-plugin-component/lib/uni-modal/utssdk/index.d.ts +4 -6
  158. package/types/uni/uts-plugin-component/lib/uni-modal/utssdk/interface.d.ts +1743 -291
  159. package/types/uni/uts-plugin-component/lib/uni-navigator-global/utssdk/interface.d.ts +1 -1
  160. package/types/uni/uts-plugin-component/lib/uni-oauth/utssdk/interface.d.ts +12 -12
  161. package/types/uni/uts-plugin-component/lib/uni-progress-global/utssdk/interface.d.ts +1 -1
  162. package/types/uni/uts-plugin-component/lib/uni-screenBrightness/utssdk/interface.d.ts +1175 -314
  163. package/types/uni/uts-plugin-component/lib/uni-share/utssdk/interface.d.ts +936 -335
  164. package/types/uni/uts-plugin-component/lib/uni-showLoading/utssdk/global.d.ts +8 -0
  165. package/types/uni/uts-plugin-component/lib/uni-showLoading/utssdk/index.d.ts +4 -0
  166. package/types/uni/uts-plugin-component/lib/uni-showLoading/utssdk/interface.d.ts +1617 -446
  167. package/types/uni/uts-plugin-component/lib/uni-web-view/utssdk/interface.d.ts +6 -6
  168. package/types/uni/uts-plugin-extend/global.d.ts +0 -1
  169. package/types/uni/uts-plugin-extend/index.d.ts +0 -1
  170. package/types/uni/uts-plugin-extend/lib/uni-memory/utssdk/interface.d.ts +3 -3
  171. package/types/uni/uts-plugin-extend/lib/uni-openLocation/utssdk/interface.d.ts +2 -1
  172. package/types/vue/LifeCycle.d.ts +2 -2
  173. package/types/uni/uts-plugin-extend/lib/uni-memory/utssdk/global.d.ts +0 -9
  174. package/types/uni/uts-plugin-extend/lib/uni-memory/utssdk/index.d.ts +0 -1
@@ -1,291 +1,1743 @@
1
-
2
- export type UniShowModalResult = {
3
- /**
4
- * editable 为 true 时,用户输入的文本
5
- */
6
- content?: string|null
7
- /**
8
- * 为 true 时,表示用户点击了取消(用于 Android 系统区分点击蒙层关闭还是点击取消按钮关闭)
9
- */
10
- cancel: boolean
11
- /**
12
- * 为 true 时,表示用户点击了确定按钮
13
- */
14
- confirm: boolean
15
- }
16
-
17
- export type ShowModalResult = UniShowModalResult
18
-
19
- export type ShowModalErrorCode = 4
20
-
21
- export interface UniShowModalFail extends IUniError {
22
- errCode: ShowModalErrorCode
23
- }
24
-
25
- export type ShowModalFail = UniShowModalFail
26
-
27
- export class ShowModalFailImpl extends UniError implements ShowModalFail {
28
- override errCode: ShowModalErrorCode
29
- constructor(errMsg: string = 'showModal:fail cancel', errCode: ShowModalErrorCode = 4) {
30
- super()
31
- this.errMsg = errMsg
32
- this.errCode = errCode
33
- }
34
- }
35
-
36
- type UniShowModalFailCallback = (result: ShowModalFail) => void
37
-
38
- type UniShowModalSuccessCallback = (result: ShowModalResult) => void
39
-
40
- type UniShowModalCompleteCallback = (result: any) => void
41
-
42
-
43
- export type ShowModalOptions = {
44
- /**
45
- * 提示的标题
46
- */
47
- title?: string | null,
48
- /**
49
- * 提示的内容
50
- */
51
- content?: string | null,
52
- /**
53
- * @defaultValue true
54
- * @default true
55
- * 是否显示取消按钮,默认为 true
56
- */
57
- showCancel?: boolean | null,
58
- /**
59
- * 取消按钮的文字,默认为"取消"
60
- */
61
- cancelText?: string | null,
62
- /**
63
- * 取消按钮的文字颜色,默认为"#000000"
64
- */
65
- cancelColor?: string.ColorString | null,
66
- /**
67
- * 确定按钮的文字,默认为"确定"
68
- */
69
- confirmText?: string | null,
70
- /**
71
- * 确定按钮的文字颜色
72
- */
73
- confirmColor?: string.ColorString | null,
74
- /**
75
- * 是否显示输入框
76
- * @defaultValue false
77
- */
78
- editable?: boolean | null,
79
- /**
80
- * 显示输入框时的提示文本
81
- */
82
- placeholderText?: string | null,
83
- /**
84
- * 接口调用成功的回调函数
85
- */
86
- success?: UniShowModalSuccessCallback | null,
87
- /**
88
- * 接口调用失败的回调函数
89
- */
90
- fail?: UniShowModalFailCallback | null,
91
- /**
92
- * 接口调用结束的回调函数(调用成功、失败都会执行)
93
- */
94
- complete?: UniShowModalCompleteCallback | null
95
- }
96
- export type ShowModal = (options: ShowModalOptions) => ModalPage | null;
97
-
98
- export type ModalPage = UniPage;
99
-
100
- /**
101
- * HideModal 数据结构定义
102
- */
103
- export type UniHideModalResult = {
104
-
105
- }
106
-
107
- export type HideModalResult = UniHideModalResult
108
-
109
- export type HideModalErrorCode = 4
110
-
111
- export interface UniHideModalFail extends IUniError {
112
- errCode: HideModalErrorCode
113
- }
114
-
115
- export type HideModalFail = UniHideModalFail
116
-
117
- export class HideModalFailImpl extends UniError implements HideModalFail {
118
- override errCode: HideModalErrorCode
119
- constructor(errMsg: string = 'hideModal:fail cancel', errCode: HideModalErrorCode = 4) {
120
- super()
121
- this.errMsg = errMsg
122
- this.errCode = errCode
123
- }
124
- }
125
-
126
- type UniHideModalFailCallback = (result: HideModalFail) => void
127
-
128
- type UniHideModalSuccessCallback = (result: HideModalResult) => void
129
-
130
- type UniHideModalCompleteCallback = (result: any) => void
131
-
132
-
133
- export type HideModalOptions = {
134
- /**
135
- * 期望隐藏的目标modal 如果为null 会关闭当前栈顶全部modal
136
- */
137
- modalPage?: ModalPage | null,
138
- /**
139
- * 接口调用成功的回调函数
140
- */
141
- success?: UniHideModalSuccessCallback | null,
142
- /**
143
- * 接口调用失败的回调函数
144
- */
145
- fail?: UniHideModalFailCallback | null,
146
- /**
147
- * 接口调用结束的回调函数(调用成功、失败都会执行)
148
- */
149
- complete?: UniHideModalCompleteCallback | null
150
- }
151
-
152
- export type HideModal = (options: HideModalOptions | null) => void;
153
-
154
-
155
- export interface Uni {
156
-
157
- /**
158
- * @description 显示模态弹窗,可以只有一个确定按钮,也可以同时有确定和取消按钮。类似于一个API整合了 html 中:alert、confirm。
159
- * @example
160
- ```typescript
161
- uni.showModal({
162
- title: '提示',
163
- content: '这是一个模态弹窗',
164
- success: function (res) {
165
- if (res.confirm) {
166
- console.log('用户点击确定');
167
- } else if (res.cancel) {
168
- console.log('用户点击取消');
169
- }
170
- }
171
- });
172
- ```
173
- * @tutorial_uni_app https://uniapp.dcloud.net.cn/api/ui/prompt.html#showmodal
174
- * @tutorial_uni_app_x https://doc.dcloud.net.cn/uni-app-x/api/prompt.html#showmodal
175
- * @tutorial https://doc.dcloud.net.cn/uni-app-x/api/prompt.html#showmodal
176
- * @uniPlatform
177
- {
178
- "app": {
179
- "android": {
180
- "osVer": "5.0",
181
- "uniVer": "√",
182
- "uniUtsPlugin": "x",
183
- "unixVer": "3.91"
184
- },
185
- "ios": {
186
- "osVer": "12.0",
187
- "uniVer": "√",
188
- "uniUtsPlugin": "x",
189
- "unixVer": "4.11",
190
- "unixUtsPlugin": "4.11"
191
- },
192
- "harmony": {
193
- "osVer": "3.0",
194
- "uniVer": "4.23",
195
- "unixVer": "4.61",
196
- "unixVaporVer": "5.0"
197
- }
198
- },
199
- "mp": {
200
- "weixin": {
201
- "hostVer": "√",
202
- "uniVer": "√",
203
- "unixVer": "4.41"
204
- },
205
- "alipay": {
206
- "hostVer": "√",
207
- "uniVer": "√",
208
- "unixVer": "x"
209
- },
210
- "baidu": {
211
- "hostVer": "√",
212
- "uniVer": "√",
213
- "unixVer": "x"
214
- },
215
- "toutiao": {
216
- "hostVer": "√",
217
- "uniVer": "√",
218
- "unixVer": "x"
219
- },
220
- "lark": {
221
- "hostVer": "√",
222
- "uniVer": "√",
223
- "unixVer": "x"
224
- },
225
- "qq": {
226
- "hostVer": "√",
227
- "uniVer": "√",
228
- "unixVer": "x"
229
- },
230
- "kuaishou": {
231
- "hostVer": "",
232
- "uniVer": "",
233
- "unixVer": "x"
234
- },
235
- "jd": {
236
- "hostVer": "",
237
- "uniVer": "",
238
- "unixVer": "x"
239
- }
240
- },
241
- "web": {
242
- "uniVer": "√",
243
- "unixVer": "4.0"
244
- }
245
- }
246
- */
247
- showModal(options: ShowModalOptions): ModalPage | null,
248
-
249
- /**
250
- * @description 隐藏已弹出的对话框实例,如果 `modalPage` 参数为空,则隐藏当前栈顶全部对话框
251
- * @example
252
- ```typescript
253
- uni.hideModal({
254
- modalPage:null,
255
- success: function (res) {
256
- }
257
- });
258
- ```
259
- * @tutorial_uni_app https://uniapp.dcloud.net.cn/api/ui/prompt.html#hidemodal
260
- * @tutorial_uni_app_x https://doc.dcloud.net.cn/uni-app-x/api/prompt.html#hidemodal
261
- * @tutorial https://doc.dcloud.net.cn/uni-app-x/api/prompt.html#hidemodal
262
- * @uniPlatform
263
- {
264
- "app": {
265
- "android": {
266
- "osVer": "5.0",
267
- "uniVer": "x",
268
- "uniUtsPlugin": "x",
269
- "unixVer": "4.61"
270
- },
271
- "ios": {
272
- "osVer": "12.0",
273
- "uniVer": "x",
274
- "uniUtsPlugin": "x",
275
- "unixVer": "4.61",
276
- "unixUtsPlugin": "4.61"
277
- },
278
- "harmony": {
279
- "osVer": "x",
280
- "uniVer": "x",
281
- "unixVer": "x"
282
- }
283
- },
284
- "web": {
285
- "uniVer": "x",
286
- "unixVer": "4.61"
287
- }
288
- }
289
- */
290
- hideModal(options: HideModalOptions | null):void
291
- }
1
+ export interface ShowModalSuccess {
2
+ /**
3
+ * 错误信息
4
+ * @uniPlatform
5
+ {
6
+ "app": {
7
+ "android": {
8
+ "osVer": "5.0",
9
+ "uniVer": "x",
10
+ "uniUtsPlugin": "x",
11
+ "unixVer": "4.61"
12
+ },
13
+ "ios": {
14
+ "osVer": "12.0",
15
+ "uniVer": "x",
16
+ "uniUtsPlugin": "x",
17
+ "unixVer": "4.61",
18
+ "unixUtsPlugin": "4.61"
19
+ },
20
+ "harmony": {
21
+ "osVer": "3.0",
22
+ "uniVer": "4.23",
23
+ "unixVer": "4.61",
24
+ "unixVaporVer": "5.0"
25
+ }
26
+ },
27
+ "mp": {
28
+ "weixin": {
29
+ "hostVer": "√",
30
+ "uniVer": "√",
31
+ "unixVer": "4.41"
32
+ },
33
+ "alipay": {
34
+ "hostVer": "√",
35
+ "uniVer": "√",
36
+ "unixVer": "x"
37
+ },
38
+ "baidu": {
39
+ "hostVer": "√",
40
+ "uniVer": "√",
41
+ "unixVer": "x"
42
+ },
43
+ "toutiao": {
44
+ "hostVer": "√",
45
+ "uniVer": "√",
46
+ "unixVer": "x"
47
+ },
48
+ "lark": {
49
+ "hostVer": "√",
50
+ "uniVer": "√",
51
+ "unixVer": "x"
52
+ },
53
+ "qq": {
54
+ "hostVer": "√",
55
+ "uniVer": "√",
56
+ "unixVer": "x"
57
+ },
58
+ "kuaishou": {
59
+ "hostVer": "",
60
+ "uniVer": "√",
61
+ "unixVer": "x"
62
+ },
63
+ "jd": {
64
+ "hostVer": "√",
65
+ "uniVer": "√",
66
+ "unixVer": "x"
67
+ }
68
+ },
69
+ "web": {
70
+ "uniVer": "√",
71
+ "unixVer": "4.0"
72
+ }
73
+ }
74
+ */
75
+ errMsg: string
76
+ /**
77
+ * editable 为 true 时,用户输入的文本
78
+ * @uniPlatform
79
+ {
80
+ "app": {
81
+ "android": {
82
+ "osVer": "5.0",
83
+ "uniVer": "x",
84
+ "uniUtsPlugin": "x",
85
+ "unixVer": "4.61"
86
+ },
87
+ "ios": {
88
+ "osVer": "12.0",
89
+ "uniVer": "x",
90
+ "uniUtsPlugin": "x",
91
+ "unixVer": "4.61",
92
+ "unixUtsPlugin": "4.61"
93
+ },
94
+ "harmony": {
95
+ "osVer": "3.0",
96
+ "uniVer": "4.23",
97
+ "unixVer": "4.61",
98
+ "unixVaporVer": "5.0"
99
+ }
100
+ },
101
+ "mp": {
102
+ "weixin": {
103
+ "hostVer": "√",
104
+ "uniVer": "√",
105
+ "unixVer": "4.41"
106
+ },
107
+ "alipay": {
108
+ "hostVer": "√",
109
+ "uniVer": "√",
110
+ "unixVer": "x"
111
+ },
112
+ "baidu": {
113
+ "hostVer": "√",
114
+ "uniVer": "√",
115
+ "unixVer": "x"
116
+ },
117
+ "toutiao": {
118
+ "hostVer": "√",
119
+ "uniVer": "√",
120
+ "unixVer": "x"
121
+ },
122
+ "lark": {
123
+ "hostVer": "√",
124
+ "uniVer": "√",
125
+ "unixVer": "x"
126
+ },
127
+ "qq": {
128
+ "hostVer": "√",
129
+ "uniVer": "√",
130
+ "unixVer": "x"
131
+ },
132
+ "kuaishou": {
133
+ "hostVer": "√",
134
+ "uniVer": "√",
135
+ "unixVer": "x"
136
+ },
137
+ "jd": {
138
+ "hostVer": "√",
139
+ "uniVer": "√",
140
+ "unixVer": "x"
141
+ }
142
+ },
143
+ "web": {
144
+ "uniVer": "√",
145
+ "unixVer": "4.0"
146
+ }
147
+ }
148
+ */
149
+ content?: string | null
150
+ /**
151
+ * 为 true 时,表示用户点击了取消(用于 Android 系统区分点击蒙层关闭还是点击取消按钮关闭)
152
+ * @uniPlatform
153
+ {
154
+ "app": {
155
+ "android": {
156
+ "osVer": "5.0",
157
+ "uniVer": "x",
158
+ "uniUtsPlugin": "x",
159
+ "unixVer": "4.61"
160
+ },
161
+ "ios": {
162
+ "osVer": "12.0",
163
+ "uniVer": "x",
164
+ "uniUtsPlugin": "x",
165
+ "unixVer": "4.61",
166
+ "unixUtsPlugin": "4.61"
167
+ },
168
+ "harmony": {
169
+ "osVer": "3.0",
170
+ "uniVer": "4.23",
171
+ "unixVer": "4.61",
172
+ "unixVaporVer": "5.0"
173
+ }
174
+ },
175
+ "mp": {
176
+ "weixin": {
177
+ "hostVer": "√",
178
+ "uniVer": "√",
179
+ "unixVer": "4.41"
180
+ },
181
+ "alipay": {
182
+ "hostVer": "",
183
+ "uniVer": "",
184
+ "unixVer": "x"
185
+ },
186
+ "baidu": {
187
+ "hostVer": "√",
188
+ "uniVer": "",
189
+ "unixVer": "x"
190
+ },
191
+ "toutiao": {
192
+ "hostVer": "√",
193
+ "uniVer": "",
194
+ "unixVer": "x"
195
+ },
196
+ "lark": {
197
+ "hostVer": "√",
198
+ "uniVer": "√",
199
+ "unixVer": "x"
200
+ },
201
+ "qq": {
202
+ "hostVer": "√",
203
+ "uniVer": "",
204
+ "unixVer": "x"
205
+ },
206
+ "kuaishou": {
207
+ "hostVer": "√",
208
+ "uniVer": "",
209
+ "unixVer": "x"
210
+ },
211
+ "jd": {
212
+ "hostVer": "√",
213
+ "uniVer": "",
214
+ "unixVer": "x"
215
+ }
216
+ },
217
+ "web": {
218
+ "uniVer": "",
219
+ "unixVer": "4.0"
220
+ }
221
+ }
222
+ */
223
+ cancel: boolean
224
+ /**
225
+ * 为 true 时,表示用户点击了确定按钮
226
+ * @uniPlatform
227
+ {
228
+ "app": {
229
+ "android": {
230
+ "osVer": "5.0",
231
+ "uniVer": "x",
232
+ "uniUtsPlugin": "x",
233
+ "unixVer": "4.61"
234
+ },
235
+ "ios": {
236
+ "osVer": "12.0",
237
+ "uniVer": "x",
238
+ "uniUtsPlugin": "x",
239
+ "unixVer": "4.61",
240
+ "unixUtsPlugin": "4.61"
241
+ },
242
+ "harmony": {
243
+ "osVer": "3.0",
244
+ "uniVer": "4.23",
245
+ "unixVer": "4.61",
246
+ "unixVaporVer": "5.0"
247
+ }
248
+ },
249
+ "mp": {
250
+ "weixin": {
251
+ "hostVer": "√",
252
+ "uniVer": "√",
253
+ "unixVer": "4.41"
254
+ },
255
+ "alipay": {
256
+ "hostVer": "√",
257
+ "uniVer": "√",
258
+ "unixVer": "x"
259
+ },
260
+ "baidu": {
261
+ "hostVer": "√",
262
+ "uniVer": "√",
263
+ "unixVer": "x"
264
+ },
265
+ "toutiao": {
266
+ "hostVer": "",
267
+ "uniVer": "",
268
+ "unixVer": "x"
269
+ },
270
+ "lark": {
271
+ "hostVer": "√",
272
+ "uniVer": "",
273
+ "unixVer": "x"
274
+ },
275
+ "qq": {
276
+ "hostVer": "",
277
+ "uniVer": "√",
278
+ "unixVer": "x"
279
+ },
280
+ "kuaishou": {
281
+ "hostVer": "",
282
+ "uniVer": "√",
283
+ "unixVer": "x"
284
+ },
285
+ "jd": {
286
+ "hostVer": "",
287
+ "uniVer": "√",
288
+ "unixVer": "x"
289
+ }
290
+ },
291
+ "web": {
292
+ "uniVer": "√",
293
+ "unixVer": "4.0"
294
+ }
295
+ }
296
+ */
297
+ confirm: boolean
298
+ }
299
+
300
+ export type ShowModalErrorCode = 4
301
+
302
+ export interface ShowModalFail extends IUniError {
303
+ errCode: ShowModalErrorCode
304
+ }
305
+
306
+ export class ShowModalSuccessImpl implements ShowModalSuccess {
307
+ errMsg: string
308
+ content?: string | null
309
+ cancel: boolean
310
+ confirm: boolean
311
+ constructor(cancel: boolean, confirm: boolean, content: string | null = null, errMsg: string = 'showModal:ok') {
312
+ this.errMsg = errMsg
313
+ this.content = content
314
+ this.cancel = cancel
315
+ this.confirm = confirm
316
+ }
317
+ }
318
+
319
+ export class ShowModalFailImpl extends UniError implements ShowModalFail {
320
+ override errCode: ShowModalErrorCode
321
+ constructor(errMsg: string = 'showModal:fail cancel', errCode: ShowModalErrorCode = 4) {
322
+ super()
323
+ this.errMsg = errMsg
324
+ this.errCode = errCode
325
+ }
326
+ }
327
+
328
+ type ShowModalFailCallback = (result: ShowModalFail) => void
329
+
330
+ type ShowModalSuccessCallback = (result: ShowModalSuccess) => void
331
+
332
+ type ShowModalComplete = any
333
+
334
+ type UniShowModalCompleteCallback = (result: ShowModalComplete) => void
335
+
336
+ export type ShowModalOptions = {
337
+ /**
338
+ * 提示的标题
339
+ * @uniPlatform
340
+ {
341
+ "app": {
342
+ "android": {
343
+ "osVer": "5.0",
344
+ "uniVer": "x",
345
+ "uniUtsPlugin": "x",
346
+ "unixVer": "4.61"
347
+ },
348
+ "ios": {
349
+ "osVer": "12.0",
350
+ "uniVer": "x",
351
+ "uniUtsPlugin": "x",
352
+ "unixVer": "4.61",
353
+ "unixUtsPlugin": "4.61"
354
+ },
355
+ "harmony": {
356
+ "osVer": "3.0",
357
+ "uniVer": "4.23",
358
+ "unixVer": "4.61",
359
+ "unixVaporVer": "5.0"
360
+ }
361
+ },
362
+ "mp": {
363
+ "weixin": {
364
+ "hostVer": "√",
365
+ "uniVer": "√",
366
+ "unixVer": "4.41"
367
+ },
368
+ "alipay": {
369
+ "hostVer": "√",
370
+ "uniVer": "√",
371
+ "unixVer": "x"
372
+ },
373
+ "baidu": {
374
+ "hostVer": "√",
375
+ "uniVer": "√",
376
+ "unixVer": "x"
377
+ },
378
+ "toutiao": {
379
+ "hostVer": "√",
380
+ "uniVer": "√",
381
+ "unixVer": "x"
382
+ },
383
+ "lark": {
384
+ "hostVer": "√",
385
+ "uniVer": "√",
386
+ "unixVer": "x"
387
+ },
388
+ "qq": {
389
+ "hostVer": "√",
390
+ "uniVer": "√",
391
+ "unixVer": "x"
392
+ },
393
+ "kuaishou": {
394
+ "hostVer": "√",
395
+ "uniVer": "√",
396
+ "unixVer": "x"
397
+ },
398
+ "jd": {
399
+ "hostVer": "√",
400
+ "uniVer": "√",
401
+ "unixVer": "x"
402
+ }
403
+ },
404
+ "web": {
405
+ "uniVer": "√",
406
+ "unixVer": "4.0"
407
+ }
408
+ }
409
+ */
410
+ title?: string | null,
411
+ /**
412
+ * 提示的内容
413
+ * @uniPlatform
414
+ {
415
+ "app": {
416
+ "android": {
417
+ "osVer": "5.0",
418
+ "uniVer": "x",
419
+ "uniUtsPlugin": "x",
420
+ "unixVer": "4.61"
421
+ },
422
+ "ios": {
423
+ "osVer": "12.0",
424
+ "uniVer": "x",
425
+ "uniUtsPlugin": "x",
426
+ "unixVer": "4.61",
427
+ "unixUtsPlugin": "4.61"
428
+ },
429
+ "harmony": {
430
+ "osVer": "3.0",
431
+ "uniVer": "4.23",
432
+ "unixVer": "4.61",
433
+ "unixVaporVer": "5.0"
434
+ }
435
+ },
436
+ "mp": {
437
+ "weixin": {
438
+ "hostVer": "√",
439
+ "uniVer": "√",
440
+ "unixVer": "4.41"
441
+ },
442
+ "alipay": {
443
+ "hostVer": "√",
444
+ "uniVer": "√",
445
+ "unixVer": "x"
446
+ },
447
+ "baidu": {
448
+ "hostVer": "√",
449
+ "uniVer": "√",
450
+ "unixVer": "x"
451
+ },
452
+ "toutiao": {
453
+ "hostVer": "√",
454
+ "uniVer": "√",
455
+ "unixVer": "x"
456
+ },
457
+ "lark": {
458
+ "hostVer": "√",
459
+ "uniVer": "√",
460
+ "unixVer": "x"
461
+ },
462
+ "qq": {
463
+ "hostVer": "√",
464
+ "uniVer": "√",
465
+ "unixVer": "x"
466
+ },
467
+ "kuaishou": {
468
+ "hostVer": "√",
469
+ "uniVer": "√",
470
+ "unixVer": "x"
471
+ },
472
+ "jd": {
473
+ "hostVer": "√",
474
+ "uniVer": "√",
475
+ "unixVer": "x"
476
+ }
477
+ },
478
+ "web": {
479
+ "uniVer": "√",
480
+ "unixVer": "4.0"
481
+ }
482
+ }
483
+ */
484
+ content?: string | null,
485
+ /**
486
+ * @defaultValue true
487
+ * @default true
488
+ * 是否显示取消按钮,默认为 true
489
+ * @uniPlatform
490
+ {
491
+ "app": {
492
+ "android": {
493
+ "osVer": "5.0",
494
+ "uniVer": "x",
495
+ "uniUtsPlugin": "x",
496
+ "unixVer": "4.61"
497
+ },
498
+ "ios": {
499
+ "osVer": "12.0",
500
+ "uniVer": "x",
501
+ "uniUtsPlugin": "x",
502
+ "unixVer": "4.61",
503
+ "unixUtsPlugin": "4.61"
504
+ },
505
+ "harmony": {
506
+ "osVer": "3.0",
507
+ "uniVer": "4.23",
508
+ "unixVer": "4.61",
509
+ "unixVaporVer": "5.0"
510
+ }
511
+ },
512
+ "mp": {
513
+ "weixin": {
514
+ "hostVer": "√",
515
+ "uniVer": "√",
516
+ "unixVer": "4.41"
517
+ },
518
+ "alipay": {
519
+ "hostVer": "√",
520
+ "uniVer": "√",
521
+ "unixVer": "x"
522
+ },
523
+ "baidu": {
524
+ "hostVer": "√",
525
+ "uniVer": "√",
526
+ "unixVer": "x"
527
+ },
528
+ "toutiao": {
529
+ "hostVer": "√",
530
+ "uniVer": "√",
531
+ "unixVer": "x"
532
+ },
533
+ "lark": {
534
+ "hostVer": "√",
535
+ "uniVer": "√",
536
+ "unixVer": "x"
537
+ },
538
+ "qq": {
539
+ "hostVer": "√",
540
+ "uniVer": "√",
541
+ "unixVer": "x"
542
+ },
543
+ "kuaishou": {
544
+ "hostVer": "√",
545
+ "uniVer": "√",
546
+ "unixVer": "x"
547
+ },
548
+ "jd": {
549
+ "hostVer": "√",
550
+ "uniVer": "√",
551
+ "unixVer": "x"
552
+ }
553
+ },
554
+ "web": {
555
+ "uniVer": "√",
556
+ "unixVer": "4.0"
557
+ }
558
+ }
559
+ */
560
+ showCancel?: boolean | null,
561
+ /**
562
+ * 取消按钮的文字,默认为"取消"
563
+ * @uniPlatform
564
+ {
565
+ "app": {
566
+ "android": {
567
+ "osVer": "5.0",
568
+ "uniVer": "x",
569
+ "uniUtsPlugin": "x",
570
+ "unixVer": "4.61"
571
+ },
572
+ "ios": {
573
+ "osVer": "12.0",
574
+ "uniVer": "x",
575
+ "uniUtsPlugin": "x",
576
+ "unixVer": "4.61",
577
+ "unixUtsPlugin": "4.61"
578
+ },
579
+ "harmony": {
580
+ "osVer": "3.0",
581
+ "uniVer": "4.23",
582
+ "unixVer": "4.61",
583
+ "unixVaporVer": "5.0"
584
+ }
585
+ },
586
+ "mp": {
587
+ "weixin": {
588
+ "hostVer": "√",
589
+ "uniVer": "√",
590
+ "unixVer": "4.41"
591
+ },
592
+ "alipay": {
593
+ "hostVer": "√",
594
+ "uniVer": "√",
595
+ "unixVer": "x"
596
+ },
597
+ "baidu": {
598
+ "hostVer": "√",
599
+ "uniVer": "√",
600
+ "unixVer": "x"
601
+ },
602
+ "toutiao": {
603
+ "hostVer": "√",
604
+ "uniVer": "√",
605
+ "unixVer": "x"
606
+ },
607
+ "lark": {
608
+ "hostVer": "√",
609
+ "uniVer": "√",
610
+ "unixVer": "x"
611
+ },
612
+ "qq": {
613
+ "hostVer": "√",
614
+ "uniVer": "√",
615
+ "unixVer": "x"
616
+ },
617
+ "kuaishou": {
618
+ "hostVer": "√",
619
+ "uniVer": "√",
620
+ "unixVer": "x"
621
+ },
622
+ "jd": {
623
+ "hostVer": "√",
624
+ "uniVer": "√",
625
+ "unixVer": "x"
626
+ }
627
+ },
628
+ "web": {
629
+ "uniVer": "√",
630
+ "unixVer": "4.0"
631
+ }
632
+ }
633
+ */
634
+ cancelText?: string | null,
635
+ /**
636
+ * 取消按钮的文字颜色,默认为"#000000"
637
+ * @uniPlatform
638
+ {
639
+ "app": {
640
+ "android": {
641
+ "osVer": "5.0",
642
+ "uniVer": "x",
643
+ "uniUtsPlugin": "x",
644
+ "unixVer": "4.61"
645
+ },
646
+ "ios": {
647
+ "osVer": "12.0",
648
+ "uniVer": "x",
649
+ "uniUtsPlugin": "x",
650
+ "unixVer": "4.61",
651
+ "unixUtsPlugin": "4.61"
652
+ },
653
+ "harmony": {
654
+ "osVer": "3.0",
655
+ "uniVer": "4.23",
656
+ "unixVer": "4.61",
657
+ "unixVaporVer": "5.0"
658
+ }
659
+ },
660
+ "mp": {
661
+ "weixin": {
662
+ "hostVer": "√",
663
+ "uniVer": "√",
664
+ "unixVer": "4.41"
665
+ },
666
+ "alipay": {
667
+ "hostVer": "√",
668
+ "uniVer": "√",
669
+ "unixVer": "x"
670
+ },
671
+ "baidu": {
672
+ "hostVer": "√",
673
+ "uniVer": "√",
674
+ "unixVer": "x"
675
+ },
676
+ "toutiao": {
677
+ "hostVer": "√",
678
+ "uniVer": "√",
679
+ "unixVer": "x"
680
+ },
681
+ "lark": {
682
+ "hostVer": "√",
683
+ "uniVer": "√",
684
+ "unixVer": "x"
685
+ },
686
+ "qq": {
687
+ "hostVer": "√",
688
+ "uniVer": "√",
689
+ "unixVer": "x"
690
+ },
691
+ "kuaishou": {
692
+ "hostVer": "√",
693
+ "uniVer": "√",
694
+ "unixVer": "x"
695
+ },
696
+ "jd": {
697
+ "hostVer": "√",
698
+ "uniVer": "√",
699
+ "unixVer": "x"
700
+ }
701
+ },
702
+ "web": {
703
+ "uniVer": "√",
704
+ "unixVer": "4.0"
705
+ }
706
+ }
707
+ */
708
+ cancelColor?: string.ColorString | null,
709
+ /**
710
+ * 确定按钮的文字,默认为"确定"
711
+ * @uniPlatform
712
+ {
713
+ "app": {
714
+ "android": {
715
+ "osVer": "5.0",
716
+ "uniVer": "x",
717
+ "uniUtsPlugin": "x",
718
+ "unixVer": "4.61"
719
+ },
720
+ "ios": {
721
+ "osVer": "12.0",
722
+ "uniVer": "x",
723
+ "uniUtsPlugin": "x",
724
+ "unixVer": "4.61",
725
+ "unixUtsPlugin": "4.61"
726
+ },
727
+ "harmony": {
728
+ "osVer": "3.0",
729
+ "uniVer": "4.23",
730
+ "unixVer": "4.61",
731
+ "unixVaporVer": "5.0"
732
+ }
733
+ },
734
+ "mp": {
735
+ "weixin": {
736
+ "hostVer": "√",
737
+ "uniVer": "√",
738
+ "unixVer": "4.41"
739
+ },
740
+ "alipay": {
741
+ "hostVer": "√",
742
+ "uniVer": "√",
743
+ "unixVer": "x"
744
+ },
745
+ "baidu": {
746
+ "hostVer": "√",
747
+ "uniVer": "√",
748
+ "unixVer": "x"
749
+ },
750
+ "toutiao": {
751
+ "hostVer": "√",
752
+ "uniVer": "√",
753
+ "unixVer": "x"
754
+ },
755
+ "lark": {
756
+ "hostVer": "√",
757
+ "uniVer": "√",
758
+ "unixVer": "x"
759
+ },
760
+ "qq": {
761
+ "hostVer": "√",
762
+ "uniVer": "√",
763
+ "unixVer": "x"
764
+ },
765
+ "kuaishou": {
766
+ "hostVer": "√",
767
+ "uniVer": "√",
768
+ "unixVer": "x"
769
+ },
770
+ "jd": {
771
+ "hostVer": "√",
772
+ "uniVer": "√",
773
+ "unixVer": "x"
774
+ }
775
+ },
776
+ "web": {
777
+ "uniVer": "√",
778
+ "unixVer": "4.0"
779
+ }
780
+ }
781
+ */
782
+ confirmText?: string | null,
783
+ /**
784
+ * 确定按钮的文字颜色
785
+ * @uniPlatform
786
+ {
787
+ "app": {
788
+ "android": {
789
+ "osVer": "5.0",
790
+ "uniVer": "x",
791
+ "uniUtsPlugin": "x",
792
+ "unixVer": "4.61"
793
+ },
794
+ "ios": {
795
+ "osVer": "12.0",
796
+ "uniVer": "x",
797
+ "uniUtsPlugin": "x",
798
+ "unixVer": "4.61",
799
+ "unixUtsPlugin": "4.61"
800
+ },
801
+ "harmony": {
802
+ "osVer": "3.0",
803
+ "uniVer": "4.23",
804
+ "unixVer": "4.61",
805
+ "unixVaporVer": "5.0"
806
+ }
807
+ },
808
+ "mp": {
809
+ "weixin": {
810
+ "hostVer": "√",
811
+ "uniVer": "√",
812
+ "unixVer": "4.41"
813
+ },
814
+ "alipay": {
815
+ "hostVer": "√",
816
+ "uniVer": "√",
817
+ "unixVer": "x"
818
+ },
819
+ "baidu": {
820
+ "hostVer": "√",
821
+ "uniVer": "√",
822
+ "unixVer": "x"
823
+ },
824
+ "toutiao": {
825
+ "hostVer": "√",
826
+ "uniVer": "√",
827
+ "unixVer": "x"
828
+ },
829
+ "lark": {
830
+ "hostVer": "√",
831
+ "uniVer": "√",
832
+ "unixVer": "x"
833
+ },
834
+ "qq": {
835
+ "hostVer": "√",
836
+ "uniVer": "√",
837
+ "unixVer": "x"
838
+ },
839
+ "kuaishou": {
840
+ "hostVer": "√",
841
+ "uniVer": "√",
842
+ "unixVer": "x"
843
+ },
844
+ "jd": {
845
+ "hostVer": "√",
846
+ "uniVer": "√",
847
+ "unixVer": "x"
848
+ }
849
+ },
850
+ "web": {
851
+ "uniVer": "√",
852
+ "unixVer": "4.0"
853
+ }
854
+ }
855
+ */
856
+ confirmColor?: string.ColorString | null,
857
+ /**
858
+ * 是否显示输入框
859
+ * @uniPlatform
860
+ {
861
+ "app": {
862
+ "android": {
863
+ "osVer": "5.0",
864
+ "uniVer": "x",
865
+ "uniUtsPlugin": "x",
866
+ "unixVer": "4.61"
867
+ },
868
+ "ios": {
869
+ "osVer": "12.0",
870
+ "uniVer": "x",
871
+ "uniUtsPlugin": "x",
872
+ "unixVer": "4.61",
873
+ "unixUtsPlugin": "4.61"
874
+ },
875
+ "harmony": {
876
+ "osVer": "3.0",
877
+ "uniVer": "4.23",
878
+ "unixVer": "4.61",
879
+ "unixVaporVer": "5.0"
880
+ }
881
+ },
882
+ "mp": {
883
+ "weixin": {
884
+ "hostVer": "√",
885
+ "uniVer": "√",
886
+ "unixVer": "4.41"
887
+ },
888
+ "alipay": {
889
+ "hostVer": "√",
890
+ "uniVer": "√",
891
+ "unixVer": "x"
892
+ },
893
+ "baidu": {
894
+ "hostVer": "√",
895
+ "uniVer": "√",
896
+ "unixVer": "x"
897
+ },
898
+ "toutiao": {
899
+ "hostVer": "√",
900
+ "uniVer": "√",
901
+ "unixVer": "x"
902
+ },
903
+ "lark": {
904
+ "hostVer": "√",
905
+ "uniVer": "√",
906
+ "unixVer": "x"
907
+ },
908
+ "qq": {
909
+ "hostVer": "√",
910
+ "uniVer": "√",
911
+ "unixVer": "x"
912
+ },
913
+ "kuaishou": {
914
+ "hostVer": "√",
915
+ "uniVer": "√",
916
+ "unixVer": "x"
917
+ },
918
+ "jd": {
919
+ "hostVer": "√",
920
+ "uniVer": "√",
921
+ "unixVer": "x"
922
+ }
923
+ },
924
+ "web": {
925
+ "uniVer": "√",
926
+ "unixVer": "4.0"
927
+ }
928
+ }
929
+ * @defaultValue false
930
+ */
931
+ editable?: boolean | null,
932
+ /**
933
+ * 显示输入框时的提示文本
934
+ * @uniPlatform
935
+ {
936
+ "app": {
937
+ "android": {
938
+ "osVer": "5.0",
939
+ "uniVer": "x",
940
+ "uniUtsPlugin": "x",
941
+ "unixVer": "4.61"
942
+ },
943
+ "ios": {
944
+ "osVer": "12.0",
945
+ "uniVer": "x",
946
+ "uniUtsPlugin": "x",
947
+ "unixVer": "4.61",
948
+ "unixUtsPlugin": "4.61"
949
+ },
950
+ "harmony": {
951
+ "osVer": "3.0",
952
+ "uniVer": "4.23",
953
+ "unixVer": "4.61",
954
+ "unixVaporVer": "5.0"
955
+ }
956
+ },
957
+ "mp": {
958
+ "weixin": {
959
+ "hostVer": "√",
960
+ "uniVer": "√",
961
+ "unixVer": "4.41"
962
+ },
963
+ "alipay": {
964
+ "hostVer": "√",
965
+ "uniVer": "√",
966
+ "unixVer": "x"
967
+ },
968
+ "baidu": {
969
+ "hostVer": "√",
970
+ "uniVer": "√",
971
+ "unixVer": "x"
972
+ },
973
+ "toutiao": {
974
+ "hostVer": "√",
975
+ "uniVer": "√",
976
+ "unixVer": "x"
977
+ },
978
+ "lark": {
979
+ "hostVer": "√",
980
+ "uniVer": "√",
981
+ "unixVer": "x"
982
+ },
983
+ "qq": {
984
+ "hostVer": "√",
985
+ "uniVer": "√",
986
+ "unixVer": "x"
987
+ },
988
+ "kuaishou": {
989
+ "hostVer": "√",
990
+ "uniVer": "√",
991
+ "unixVer": "x"
992
+ },
993
+ "jd": {
994
+ "hostVer": "√",
995
+ "uniVer": "√",
996
+ "unixVer": "x"
997
+ }
998
+ },
999
+ "web": {
1000
+ "uniVer": "√",
1001
+ "unixVer": "4.0"
1002
+ }
1003
+ }
1004
+ */
1005
+ placeholderText?: string | null,
1006
+ /**
1007
+ * 接口调用成功的回调函数
1008
+ * @uniPlatform
1009
+ {
1010
+ "app": {
1011
+ "android": {
1012
+ "osVer": "5.0",
1013
+ "uniVer": "x",
1014
+ "uniUtsPlugin": "x",
1015
+ "unixVer": "4.61"
1016
+ },
1017
+ "ios": {
1018
+ "osVer": "12.0",
1019
+ "uniVer": "x",
1020
+ "uniUtsPlugin": "x",
1021
+ "unixVer": "4.61",
1022
+ "unixUtsPlugin": "4.61"
1023
+ },
1024
+ "harmony": {
1025
+ "osVer": "3.0",
1026
+ "uniVer": "4.23",
1027
+ "unixVer": "4.61",
1028
+ "unixVaporVer": "5.0"
1029
+ }
1030
+ },
1031
+ "mp": {
1032
+ "weixin": {
1033
+ "hostVer": "√",
1034
+ "uniVer": "√",
1035
+ "unixVer": "4.41"
1036
+ },
1037
+ "alipay": {
1038
+ "hostVer": "√",
1039
+ "uniVer": "√",
1040
+ "unixVer": "x"
1041
+ },
1042
+ "baidu": {
1043
+ "hostVer": "√",
1044
+ "uniVer": "√",
1045
+ "unixVer": "x"
1046
+ },
1047
+ "toutiao": {
1048
+ "hostVer": "√",
1049
+ "uniVer": "√",
1050
+ "unixVer": "x"
1051
+ },
1052
+ "lark": {
1053
+ "hostVer": "√",
1054
+ "uniVer": "√",
1055
+ "unixVer": "x"
1056
+ },
1057
+ "qq": {
1058
+ "hostVer": "√",
1059
+ "uniVer": "√",
1060
+ "unixVer": "x"
1061
+ },
1062
+ "kuaishou": {
1063
+ "hostVer": "√",
1064
+ "uniVer": "√",
1065
+ "unixVer": "x"
1066
+ },
1067
+ "jd": {
1068
+ "hostVer": "√",
1069
+ "uniVer": "√",
1070
+ "unixVer": "x"
1071
+ }
1072
+ },
1073
+ "web": {
1074
+ "uniVer": "√",
1075
+ "unixVer": "4.0"
1076
+ }
1077
+ }
1078
+ */
1079
+ success?: ShowModalSuccessCallback | null,
1080
+ /**
1081
+ * 接口调用失败的回调函数
1082
+ * @uniPlatform
1083
+ {
1084
+ "app": {
1085
+ "android": {
1086
+ "osVer": "5.0",
1087
+ "uniVer": "x",
1088
+ "uniUtsPlugin": "x",
1089
+ "unixVer": "4.61"
1090
+ },
1091
+ "ios": {
1092
+ "osVer": "12.0",
1093
+ "uniVer": "x",
1094
+ "uniUtsPlugin": "x",
1095
+ "unixVer": "4.61",
1096
+ "unixUtsPlugin": "4.61"
1097
+ },
1098
+ "harmony": {
1099
+ "osVer": "3.0",
1100
+ "uniVer": "4.23",
1101
+ "unixVer": "4.61",
1102
+ "unixVaporVer": "5.0"
1103
+ }
1104
+ },
1105
+ "mp": {
1106
+ "weixin": {
1107
+ "hostVer": "√",
1108
+ "uniVer": "√",
1109
+ "unixVer": "4.41"
1110
+ },
1111
+ "alipay": {
1112
+ "hostVer": "√",
1113
+ "uniVer": "√",
1114
+ "unixVer": "x"
1115
+ },
1116
+ "baidu": {
1117
+ "hostVer": "√",
1118
+ "uniVer": "√",
1119
+ "unixVer": "x"
1120
+ },
1121
+ "toutiao": {
1122
+ "hostVer": "√",
1123
+ "uniVer": "√",
1124
+ "unixVer": "x"
1125
+ },
1126
+ "lark": {
1127
+ "hostVer": "√",
1128
+ "uniVer": "√",
1129
+ "unixVer": "x"
1130
+ },
1131
+ "qq": {
1132
+ "hostVer": "√",
1133
+ "uniVer": "√",
1134
+ "unixVer": "x"
1135
+ },
1136
+ "kuaishou": {
1137
+ "hostVer": "√",
1138
+ "uniVer": "√",
1139
+ "unixVer": "x"
1140
+ },
1141
+ "jd": {
1142
+ "hostVer": "√",
1143
+ "uniVer": "√",
1144
+ "unixVer": "x"
1145
+ }
1146
+ },
1147
+ "web": {
1148
+ "uniVer": "√",
1149
+ "unixVer": "4.0"
1150
+ }
1151
+ }
1152
+ */
1153
+ fail?: ShowModalFailCallback | null,
1154
+ /**
1155
+ * 接口调用结束的回调函数(调用成功、失败都会执行)
1156
+ * @uniPlatform
1157
+ {
1158
+ "app": {
1159
+ "android": {
1160
+ "osVer": "5.0",
1161
+ "uniVer": "x",
1162
+ "uniUtsPlugin": "x",
1163
+ "unixVer": "4.61"
1164
+ },
1165
+ "ios": {
1166
+ "osVer": "12.0",
1167
+ "uniVer": "x",
1168
+ "uniUtsPlugin": "x",
1169
+ "unixVer": "4.61",
1170
+ "unixUtsPlugin": "4.61"
1171
+ },
1172
+ "harmony": {
1173
+ "osVer": "3.0",
1174
+ "uniVer": "4.23",
1175
+ "unixVer": "4.61",
1176
+ "unixVaporVer": "5.0"
1177
+ }
1178
+ },
1179
+ "mp": {
1180
+ "weixin": {
1181
+ "hostVer": "√",
1182
+ "uniVer": "√",
1183
+ "unixVer": "4.41"
1184
+ },
1185
+ "alipay": {
1186
+ "hostVer": "√",
1187
+ "uniVer": "√",
1188
+ "unixVer": "x"
1189
+ },
1190
+ "baidu": {
1191
+ "hostVer": "√",
1192
+ "uniVer": "√",
1193
+ "unixVer": "x"
1194
+ },
1195
+ "toutiao": {
1196
+ "hostVer": "√",
1197
+ "uniVer": "√",
1198
+ "unixVer": "x"
1199
+ },
1200
+ "lark": {
1201
+ "hostVer": "√",
1202
+ "uniVer": "√",
1203
+ "unixVer": "x"
1204
+ },
1205
+ "qq": {
1206
+ "hostVer": "√",
1207
+ "uniVer": "√",
1208
+ "unixVer": "x"
1209
+ },
1210
+ "kuaishou": {
1211
+ "hostVer": "√",
1212
+ "uniVer": "√",
1213
+ "unixVer": "x"
1214
+ },
1215
+ "jd": {
1216
+ "hostVer": "√",
1217
+ "uniVer": "√",
1218
+ "unixVer": "x"
1219
+ }
1220
+ },
1221
+ "web": {
1222
+ "uniVer": "√",
1223
+ "unixVer": "4.0"
1224
+ }
1225
+ }
1226
+ */
1227
+ complete?: UniShowModalCompleteCallback | null
1228
+ }
1229
+
1230
+ export type ShowModal = (options?: ShowModalOptions | null) => ModalPage | null
1231
+
1232
+ export type ModalPage = UniPage
1233
+
1234
+ export interface HideModalSuccess {
1235
+ errMsg: string
1236
+ }
1237
+
1238
+ export type HideModalErrorCode = 4
1239
+
1240
+ export interface HideModalFail extends IUniError {
1241
+ errCode: HideModalErrorCode
1242
+ }
1243
+
1244
+ export class HideModalSuccessImpl implements HideModalSuccess {
1245
+ errMsg: string
1246
+ constructor(errMsg: string = 'hideModal:ok') {
1247
+ this.errMsg = errMsg
1248
+ }
1249
+ }
1250
+
1251
+ export class HideModalFailImpl extends UniError implements HideModalFail {
1252
+ override errCode: HideModalErrorCode
1253
+ constructor(errMsg: string = 'hideModal:fail cancel', errCode: HideModalErrorCode = 4) {
1254
+ super()
1255
+ this.errMsg = errMsg
1256
+ this.errCode = errCode
1257
+ }
1258
+ }
1259
+
1260
+ type UniHideModalFailCallback = (result: HideModalFail) => void
1261
+
1262
+ type UniHideModalSuccessCallback = (result: HideModalSuccess) => void
1263
+
1264
+ type HideModalComplete = any
1265
+
1266
+ type UniHideModalCompleteCallback = (result: HideModalComplete) => void
1267
+
1268
+ export type HideModalOptions = {
1269
+ /**
1270
+ * 期望隐藏的目标 modal,如果为 null 会关闭当前栈顶全部 modal
1271
+ * @uniPlatform {
1272
+ "app": {
1273
+ "android": {
1274
+ "osVer": "5.0",
1275
+ "uniVer": "x",
1276
+ "uniUtsPlugin": "x",
1277
+ "unixVer": "4.61"
1278
+ },
1279
+ "ios": {
1280
+ "osVer": "12.0",
1281
+ "uniVer": "x",
1282
+ "uniUtsPlugin": "x",
1283
+ "unixVer": "4.61",
1284
+ "unixUtsPlugin": "4.61"
1285
+ },
1286
+ "harmony": {
1287
+ "osVer": "3.0",
1288
+ "uniVer": "4.23",
1289
+ "unixVer": "4.61",
1290
+ "unixVaporVer": "5.0"
1291
+ }
1292
+ },
1293
+ "mp": {
1294
+ "weixin": {
1295
+ "hostVer": "x",
1296
+ "uniVer": "x",
1297
+ "unixVer": "x"
1298
+ },
1299
+ "alipay": {
1300
+ "hostVer": "x",
1301
+ "uniVer": "x",
1302
+ "unixVer": "x"
1303
+ },
1304
+ "baidu": {
1305
+ "hostVer": "x",
1306
+ "uniVer": "x",
1307
+ "unixVer": "x"
1308
+ },
1309
+ "toutiao": {
1310
+ "hostVer": "x",
1311
+ "uniVer": "x",
1312
+ "unixVer": "x"
1313
+ },
1314
+ "lark": {
1315
+ "hostVer": "x",
1316
+ "uniVer": "x",
1317
+ "unixVer": "x"
1318
+ },
1319
+ "qq": {
1320
+ "hostVer": "x",
1321
+ "uniVer": "x",
1322
+ "unixVer": "x"
1323
+ },
1324
+ "kuaishou": {
1325
+ "hostVer": "x",
1326
+ "uniVer": "x",
1327
+ "unixVer": "x"
1328
+ },
1329
+ "jd": {
1330
+ "hostVer": "x",
1331
+ "uniVer": "x",
1332
+ "unixVer": "x"
1333
+ }
1334
+ },
1335
+ "web": {
1336
+ "uniVer": "√",
1337
+ "unixVer": "4.0"
1338
+ }
1339
+ }
1340
+ */
1341
+ modalPage?: ModalPage | null,
1342
+ /**
1343
+ * 接口调用成功的回调函数
1344
+ * @uniPlatform {
1345
+ "app": {
1346
+ "android": {
1347
+ "osVer": "5.0",
1348
+ "uniVer": "x",
1349
+ "uniUtsPlugin": "x",
1350
+ "unixVer": "4.61"
1351
+ },
1352
+ "ios": {
1353
+ "osVer": "12.0",
1354
+ "uniVer": "x",
1355
+ "uniUtsPlugin": "x",
1356
+ "unixVer": "4.61",
1357
+ "unixUtsPlugin": "4.61"
1358
+ },
1359
+ "harmony": {
1360
+ "osVer": "3.0",
1361
+ "uniVer": "4.23",
1362
+ "unixVer": "4.61",
1363
+ "unixVaporVer": "5.0"
1364
+ }
1365
+ },
1366
+ "mp": {
1367
+ "weixin": {
1368
+ "hostVer": "x",
1369
+ "uniVer": "x",
1370
+ "unixVer": "x"
1371
+ },
1372
+ "alipay": {
1373
+ "hostVer": "x",
1374
+ "uniVer": "x",
1375
+ "unixVer": "x"
1376
+ },
1377
+ "baidu": {
1378
+ "hostVer": "x",
1379
+ "uniVer": "x",
1380
+ "unixVer": "x"
1381
+ },
1382
+ "toutiao": {
1383
+ "hostVer": "x",
1384
+ "uniVer": "x",
1385
+ "unixVer": "x"
1386
+ },
1387
+ "lark": {
1388
+ "hostVer": "x",
1389
+ "uniVer": "x",
1390
+ "unixVer": "x"
1391
+ },
1392
+ "qq": {
1393
+ "hostVer": "x",
1394
+ "uniVer": "x",
1395
+ "unixVer": "x"
1396
+ },
1397
+ "kuaishou": {
1398
+ "hostVer": "x",
1399
+ "uniVer": "x",
1400
+ "unixVer": "x"
1401
+ },
1402
+ "jd": {
1403
+ "hostVer": "x",
1404
+ "uniVer": "x",
1405
+ "unixVer": "x"
1406
+ }
1407
+ },
1408
+ "web": {
1409
+ "uniVer": "√",
1410
+ "unixVer": "4.0"
1411
+ }
1412
+ }
1413
+ */
1414
+ success?: UniHideModalSuccessCallback | null,
1415
+ /**
1416
+ * 接口调用失败的回调函数
1417
+ * @uniPlatform {
1418
+ "app": {
1419
+ "android": {
1420
+ "osVer": "5.0",
1421
+ "uniVer": "x",
1422
+ "uniUtsPlugin": "x",
1423
+ "unixVer": "4.61"
1424
+ },
1425
+ "ios": {
1426
+ "osVer": "12.0",
1427
+ "uniVer": "x",
1428
+ "uniUtsPlugin": "x",
1429
+ "unixVer": "4.61",
1430
+ "unixUtsPlugin": "4.61"
1431
+ },
1432
+ "harmony": {
1433
+ "osVer": "3.0",
1434
+ "uniVer": "4.23",
1435
+ "unixVer": "4.61",
1436
+ "unixVaporVer": "5.0"
1437
+ }
1438
+ },
1439
+ "mp": {
1440
+ "weixin": {
1441
+ "hostVer": "x",
1442
+ "uniVer": "x",
1443
+ "unixVer": "x"
1444
+ },
1445
+ "alipay": {
1446
+ "hostVer": "x",
1447
+ "uniVer": "x",
1448
+ "unixVer": "x"
1449
+ },
1450
+ "baidu": {
1451
+ "hostVer": "x",
1452
+ "uniVer": "x",
1453
+ "unixVer": "x"
1454
+ },
1455
+ "toutiao": {
1456
+ "hostVer": "x",
1457
+ "uniVer": "x",
1458
+ "unixVer": "x"
1459
+ },
1460
+ "lark": {
1461
+ "hostVer": "x",
1462
+ "uniVer": "x",
1463
+ "unixVer": "x"
1464
+ },
1465
+ "qq": {
1466
+ "hostVer": "x",
1467
+ "uniVer": "x",
1468
+ "unixVer": "x"
1469
+ },
1470
+ "kuaishou": {
1471
+ "hostVer": "x",
1472
+ "uniVer": "x",
1473
+ "unixVer": "x"
1474
+ },
1475
+ "jd": {
1476
+ "hostVer": "x",
1477
+ "uniVer": "x",
1478
+ "unixVer": "x"
1479
+ }
1480
+ },
1481
+ "web": {
1482
+ "uniVer": "√",
1483
+ "unixVer": "4.0"
1484
+ }
1485
+ }
1486
+ */
1487
+ fail?: UniHideModalFailCallback | null,
1488
+ /**
1489
+ * 接口调用结束的回调函数(调用成功、失败都会执行)
1490
+ * @uniPlatform {
1491
+ "app": {
1492
+ "android": {
1493
+ "osVer": "5.0",
1494
+ "uniVer": "x",
1495
+ "uniUtsPlugin": "x",
1496
+ "unixVer": "4.61"
1497
+ },
1498
+ "ios": {
1499
+ "osVer": "12.0",
1500
+ "uniVer": "x",
1501
+ "uniUtsPlugin": "x",
1502
+ "unixVer": "4.61",
1503
+ "unixUtsPlugin": "4.61"
1504
+ },
1505
+ "harmony": {
1506
+ "osVer": "3.0",
1507
+ "uniVer": "4.23",
1508
+ "unixVer": "4.61",
1509
+ "unixVaporVer": "5.0"
1510
+ }
1511
+ },
1512
+ "mp": {
1513
+ "weixin": {
1514
+ "hostVer": "x",
1515
+ "uniVer": "x",
1516
+ "unixVer": "x"
1517
+ },
1518
+ "alipay": {
1519
+ "hostVer": "x",
1520
+ "uniVer": "x",
1521
+ "unixVer": "x"
1522
+ },
1523
+ "baidu": {
1524
+ "hostVer": "x",
1525
+ "uniVer": "x",
1526
+ "unixVer": "x"
1527
+ },
1528
+ "toutiao": {
1529
+ "hostVer": "x",
1530
+ "uniVer": "x",
1531
+ "unixVer": "x"
1532
+ },
1533
+ "lark": {
1534
+ "hostVer": "x",
1535
+ "uniVer": "x",
1536
+ "unixVer": "x"
1537
+ },
1538
+ "qq": {
1539
+ "hostVer": "x",
1540
+ "uniVer": "x",
1541
+ "unixVer": "x"
1542
+ },
1543
+ "kuaishou": {
1544
+ "hostVer": "x",
1545
+ "uniVer": "x",
1546
+ "unixVer": "x"
1547
+ },
1548
+ "jd": {
1549
+ "hostVer": "x",
1550
+ "uniVer": "x",
1551
+ "unixVer": "x"
1552
+ }
1553
+ },
1554
+ "web": {
1555
+ "uniVer": "√",
1556
+ "unixVer": "4.0"
1557
+ }
1558
+ }
1559
+ */
1560
+ complete?: UniHideModalCompleteCallback | null
1561
+ }
1562
+
1563
+ export type HideModal = (options?: HideModalOptions | null) => void
1564
+
1565
+ export interface Uni {
1566
+ /**
1567
+ * @description 显示模态弹窗,可以只有一个确定按钮,也可以同时有确定和取消按钮。类似于一个API整合了 html 中:alert、confirm。
1568
+ * @example
1569
+ ```typescript
1570
+ uni.showModal({
1571
+ title: '提示',
1572
+ content: '这是一个模态弹窗',
1573
+ success: function (res) {
1574
+ if (res.confirm) {
1575
+ console.log('用户点击确定');
1576
+ } else if (res.cancel) {
1577
+ console.log('用户点击取消');
1578
+ }
1579
+ }
1580
+ });
1581
+ ```
1582
+ * @tutorial_uni_app https://uniapp.dcloud.net.cn/api/ui/prompt.html#showmodal
1583
+ * @tutorial_uni_app_x https://doc.dcloud.net.cn/uni-app-x/api/prompt.html#showmodal
1584
+ * @tutorial https://doc.dcloud.net.cn/uni-app-x/api/prompt.html#showmodal
1585
+ * @uniPlatform {
1586
+ * "app": {
1587
+ * "android": {
1588
+ * "osVer": "5.0",
1589
+ * "uniVer": "x",
1590
+ * "uniUtsPlugin": "x",
1591
+ * "unixVer": "4.61"
1592
+ * },
1593
+ * "ios": {
1594
+ * "osVer": "12.0",
1595
+ * "uniVer": "x",
1596
+ * "uniUtsPlugin": "x",
1597
+ * "unixVer": "4.61",
1598
+ * "unixUtsPlugin": "4.61"
1599
+ * },
1600
+ * "harmony": {
1601
+ * "osVer": "3.0",
1602
+ * "uniVer": "4.23",
1603
+ * "unixVer": "4.61",
1604
+ * "unixVaporVer": "5.0"
1605
+ * }
1606
+ * },
1607
+ * "mp": {
1608
+ * "weixin": {
1609
+ * "hostVer": "1.9.6",
1610
+ * "uniVer": "√",
1611
+ * "unixVer": "4.41"
1612
+ * },
1613
+ * "alipay": {
1614
+ * "hostVer": "√",
1615
+ * "uniVer": "√",
1616
+ * "unixVer": "x"
1617
+ * },
1618
+ * "baidu": {
1619
+ * "hostVer": "√",
1620
+ * "uniVer": "√",
1621
+ * "unixVer": "x"
1622
+ * },
1623
+ * "toutiao": {
1624
+ * "hostVer": "√",
1625
+ * "uniVer": "√",
1626
+ * "unixVer": "x"
1627
+ * },
1628
+ * "lark": {
1629
+ * "hostVer": "√",
1630
+ * "uniVer": "√",
1631
+ * "unixVer": "x"
1632
+ * },
1633
+ * "qq": {
1634
+ * "hostVer": "√",
1635
+ * "uniVer": "√",
1636
+ * "unixVer": "x"
1637
+ * },
1638
+ * "kuaishou": {
1639
+ * "hostVer": "√",
1640
+ * "uniVer": "√",
1641
+ * "unixVer": "x"
1642
+ * },
1643
+ * "jd": {
1644
+ * "hostVer": "√",
1645
+ * "uniVer": "√",
1646
+ * "unixVer": "x"
1647
+ * }
1648
+ * },
1649
+ * "web": {
1650
+ * "uniVer": "√",
1651
+ * "unixVer": "4.0"
1652
+ * }
1653
+ * }
1654
+ * @tutorial_weixin https://developers.weixin.qq.com/miniprogram/dev/api/ui/interaction/wx.showModal.html
1655
+ */
1656
+ showModal(options?: ShowModalOptions | null): ModalPage | null,
1657
+
1658
+ /**
1659
+ * @description 隐藏已弹出的对话框实例,如果 `modalPage` 参数为空,则隐藏当前栈顶全部对话框
1660
+ * @example
1661
+ ```typescript
1662
+ uni.hideModal({
1663
+ modalPage: null,
1664
+ success: function (res) {
1665
+ }
1666
+ });
1667
+ ```
1668
+ * @tutorial_uni_app https://uniapp.dcloud.net.cn/api/ui/prompt.html#hidemodal
1669
+ * @tutorial_uni_app_x https://doc.dcloud.net.cn/uni-app-x/api/prompt.html#hidemodal
1670
+ * @tutorial https://doc.dcloud.net.cn/uni-app-x/api/prompt.html#hidemodal
1671
+ * @uniPlatform
1672
+ {
1673
+ "app": {
1674
+ "android": {
1675
+ "osVer": "5.0",
1676
+ "uniVer": "x",
1677
+ "uniUtsPlugin": "x",
1678
+ "unixVer": "4.61"
1679
+ },
1680
+ "ios": {
1681
+ "osVer": "12.0",
1682
+ "uniVer": "x",
1683
+ "uniUtsPlugin": "x",
1684
+ "unixVer": "4.61",
1685
+ "unixUtsPlugin": "4.61"
1686
+ },
1687
+ "harmony": {
1688
+ "osVer": "3.0",
1689
+ "uniVer": "4.23",
1690
+ "unixVer": "4.61",
1691
+ "unixVaporVer": "5.0"
1692
+ }
1693
+ },
1694
+ "mp": {
1695
+ "weixin": {
1696
+ "hostVer": "√",
1697
+ "uniVer": "√",
1698
+ "unixVer": "x"
1699
+ },
1700
+ "alipay": {
1701
+ "hostVer": "√",
1702
+ "uniVer": "√",
1703
+ "unixVer": "x"
1704
+ },
1705
+ "baidu": {
1706
+ "hostVer": "√",
1707
+ "uniVer": "√",
1708
+ "unixVer": "x"
1709
+ },
1710
+ "toutiao": {
1711
+ "hostVer": "√",
1712
+ "uniVer": "√",
1713
+ "unixVer": "x"
1714
+ },
1715
+ "lark": {
1716
+ "hostVer": "√",
1717
+ "uniVer": "√",
1718
+ "unixVer": "x"
1719
+ },
1720
+ "qq": {
1721
+ "hostVer": "√",
1722
+ "uniVer": "√",
1723
+ "unixVer": "x"
1724
+ },
1725
+ "kuaishou": {
1726
+ "hostVer": "√",
1727
+ "uniVer": "√",
1728
+ "unixVer": "x"
1729
+ },
1730
+ "jd": {
1731
+ "hostVer": "√",
1732
+ "uniVer": "√",
1733
+ "unixVer": "x"
1734
+ }
1735
+ },
1736
+ "web": {
1737
+ "uniVer": "√",
1738
+ "unixVer": "4.0"
1739
+ }
1740
+ }
1741
+ */
1742
+ hideModal(options?: HideModalOptions | null): void
1743
+ }