@dcloudio/uni-app-x 0.7.111 → 0.7.113

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 (380) hide show
  1. package/package.json +1 -1
  2. package/types/dom2-internal/UniNativeView.d.ts +1 -0
  3. package/types/dom2-internal/UniPage.d.ts +16 -0
  4. package/types/dom2-internal/sharedData.d.ts +9 -14
  5. package/types/native/CSSStyleDeclaration.d.ts +172 -172
  6. package/types/native/CanvasRenderingContext2D.d.ts +4720 -4720
  7. package/types/native/DrawableContext.d.ts +1893 -1893
  8. package/types/native/IUniElement.d.ts +7468 -7461
  9. package/types/native/IUniNativeViewElement.d.ts +327 -327
  10. package/types/native/SnapshotOptions.d.ts +337 -62
  11. package/types/native/UniPage.d.ts +1305 -1305
  12. package/types/native/UniResizeObserver.d.ts +749 -749
  13. package/types/native/UniSwiperAnimationFinishEvent.d.ts +59 -59
  14. package/types/native/UniSwiperChangeEvent.d.ts +58 -58
  15. package/types/page.d.ts +3154 -3112
  16. package/types/uni/uts-plugin-api/global.d.ts +8 -0
  17. package/types/uni/uts-plugin-api/index.d.ts +8 -0
  18. package/types/uni/uts-plugin-api/lib/uni-actionSheet/utssdk/interface.d.ts +1672 -911
  19. package/types/uni/uts-plugin-api/lib/uni-addPhoneContact/utssdk/interface.d.ts +126 -126
  20. package/types/uni/uts-plugin-api/lib/uni-arrayBufferToBase64/utssdk/interface.d.ts +14 -14
  21. package/types/uni/uts-plugin-api/lib/uni-authentication/utssdk/interface.d.ts +154 -154
  22. package/types/uni/uts-plugin-api/lib/uni-base64ToArrayBuffer/utssdk/interface.d.ts +14 -14
  23. package/types/uni/uts-plugin-api/lib/uni-camera/utssdk/global.d.ts +55 -0
  24. package/types/uni/uts-plugin-api/lib/uni-camera/utssdk/index.d.ts +27 -0
  25. package/types/uni/uts-plugin-api/lib/uni-camera/utssdk/interface.d.ts +1155 -0
  26. package/types/uni/uts-plugin-api/lib/uni-canvas/utssdk/global.d.ts +9 -6
  27. package/types/uni/uts-plugin-api/lib/uni-canvas/utssdk/index.d.ts +5 -3
  28. package/types/uni/uts-plugin-api/lib/uni-canvas/utssdk/interface.d.ts +978 -972
  29. package/types/uni/uts-plugin-api/lib/uni-canvas-dom2/utssdk/global.d.ts +25 -0
  30. package/types/uni/uts-plugin-api/lib/uni-canvas-dom2/utssdk/index.d.ts +12 -0
  31. package/types/uni/uts-plugin-api/lib/uni-canvas-dom2/utssdk/interface.d.ts +978 -0
  32. package/types/uni/uts-plugin-api/lib/uni-chooseLocation/utssdk/interface.d.ts +358 -358
  33. package/types/uni/uts-plugin-api/lib/uni-chooseMedia/utssdk/interface.d.ts +8 -8
  34. package/types/uni/uts-plugin-api/lib/uni-clipboard/utssdk/interface.d.ts +78 -78
  35. package/types/uni/uts-plugin-api/lib/uni-createSelectorQuery/utssdk/interface.d.ts +490 -479
  36. package/types/uni/uts-plugin-api/lib/uni-createWebviewContext/utssdk/interface.d.ts +214 -214
  37. package/types/uni/uts-plugin-api/lib/uni-createWorker/utssdk/interface.d.ts +126 -126
  38. package/types/uni/uts-plugin-api/lib/uni-dialogPage/utssdk/interface.d.ts +30 -30
  39. package/types/uni/uts-plugin-api/lib/uni-editor/utssdk/global.d.ts +39 -0
  40. package/types/uni/uts-plugin-api/lib/uni-editor/utssdk/index.d.ts +19 -0
  41. package/types/uni/uts-plugin-api/lib/uni-editor/utssdk/interface.d.ts +856 -0
  42. package/types/uni/uts-plugin-api/lib/uni-event/utssdk/interface.d.ts +338 -338
  43. package/types/uni/uts-plugin-api/lib/uni-exit/utssdk/interface.d.ts +147 -147
  44. package/types/uni/uts-plugin-api/lib/uni-file/utssdk/interface.d.ts +397 -397
  45. package/types/uni/uts-plugin-api/lib/uni-fileSystemManager/utssdk/interface.d.ts +6363 -6359
  46. package/types/uni/uts-plugin-api/lib/uni-getAppAuthorizeSetting/utssdk/interface.d.ts +554 -554
  47. package/types/uni/uts-plugin-api/lib/uni-getAppBaseInfo/utssdk/interface.d.ts +2149 -2149
  48. package/types/uni/uts-plugin-api/lib/uni-getBackgroundAudioManager/utssdk/interface.d.ts +1340 -1340
  49. package/types/uni/uts-plugin-api/lib/uni-getDeviceInfo/utssdk/interface.d.ts +1707 -1707
  50. package/types/uni/uts-plugin-api/lib/uni-getEnterOptionsSync/utssdk/interface.d.ts +307 -307
  51. package/types/uni/uts-plugin-api/lib/uni-getLaunchOptionsSync/utssdk/interface.d.ts +310 -310
  52. package/types/uni/uts-plugin-api/lib/uni-getNetworkType/utssdk/interface.d.ts +5 -5
  53. package/types/uni/uts-plugin-api/lib/uni-getPerformance/utssdk/interface.d.ts +129 -129
  54. package/types/uni/uts-plugin-api/lib/uni-getProvider/utssdk/interface.d.ts +757 -757
  55. package/types/uni/uts-plugin-api/lib/uni-getSystemInfo/utssdk/interface.d.ts +5881 -5879
  56. package/types/uni/uts-plugin-api/lib/uni-getSystemSetting/utssdk/interface.d.ts +442 -442
  57. package/types/uni/uts-plugin-api/lib/uni-input/utssdk/global.d.ts +9 -0
  58. package/types/uni/uts-plugin-api/lib/uni-input/utssdk/index.d.ts +5 -0
  59. package/types/uni/uts-plugin-api/lib/uni-input/utssdk/interface.d.ts +0 -0
  60. package/types/uni/uts-plugin-api/lib/uni-interceptor/utssdk/interface.d.ts +171 -171
  61. package/types/uni/uts-plugin-api/lib/uni-keyboard/utssdk/interface.d.ts +1 -1
  62. package/types/uni/uts-plugin-api/lib/uni-loadFontFace/utssdk/interface.d.ts +536 -536
  63. package/types/uni/uts-plugin-api/lib/uni-location/utssdk/interface.d.ts +2914 -2910
  64. package/types/uni/uts-plugin-api/lib/uni-media/utssdk/interface.d.ts +24 -24
  65. package/types/uni/uts-plugin-api/lib/uni-modal/utssdk/interface.d.ts +208 -208
  66. package/types/uni/uts-plugin-api/lib/uni-navigationBar/utssdk/interface.d.ts +785 -785
  67. package/types/uni/uts-plugin-api/lib/uni-network/utssdk/interface.d.ts +4243 -4243
  68. package/types/uni/uts-plugin-api/lib/uni-oauth/utssdk/interface.d.ts +1979 -1963
  69. package/types/uni/uts-plugin-api/lib/uni-oauth-weixin/utssdk/interface.d.ts +5 -3
  70. package/types/uni/uts-plugin-api/lib/uni-openAppAuthorizeSetting/utssdk/interface.d.ts +229 -229
  71. package/types/uni/uts-plugin-api/lib/uni-openDocument/utssdk/interface.d.ts +753 -753
  72. package/types/uni/uts-plugin-api/lib/uni-pageScrollTo/utssdk/interface.d.ts +84 -84
  73. package/types/uni/uts-plugin-api/lib/uni-payment/utssdk/interface.d.ts +790 -788
  74. package/types/uni/uts-plugin-api/lib/uni-previewImage/utssdk/interface.d.ts +447 -447
  75. package/types/uni/uts-plugin-api/lib/uni-privacy/utssdk/interface.d.ts +498 -498
  76. package/types/uni/uts-plugin-api/lib/uni-prompt/utssdk/interface.d.ts +1552 -1548
  77. package/types/uni/uts-plugin-api/lib/uni-pullDownRefresh/utssdk/interface.d.ts +58 -58
  78. package/types/uni/uts-plugin-api/lib/uni-recorder/utssdk/interface.d.ts +30 -30
  79. package/types/uni/uts-plugin-api/lib/uni-route/utssdk/interface.d.ts +2513 -2513
  80. package/types/uni/uts-plugin-api/lib/uni-rpx2px/utssdk/interface.d.ts +81 -81
  81. package/types/uni/uts-plugin-api/lib/uni-scanCode/utssdk/interface.d.ts +351 -351
  82. package/types/uni/uts-plugin-api/lib/uni-screenBrightness/utssdk/interface.d.ts +107 -107
  83. package/types/uni/uts-plugin-api/lib/uni-share/utssdk/interface.d.ts +584 -584
  84. package/types/uni/uts-plugin-api/lib/uni-shareWithSystem/utssdk/interface.d.ts +722 -722
  85. package/types/uni/uts-plugin-api/lib/uni-showLoading/utssdk/interface.d.ts +292 -292
  86. package/types/uni/uts-plugin-api/lib/uni-storage/utssdk/interface.d.ts +358 -358
  87. package/types/uni/uts-plugin-api/lib/uni-tabBar/utssdk/interface.d.ts +657 -657
  88. package/types/uni/uts-plugin-api/lib/uni-textarea/utssdk/global.d.ts +9 -0
  89. package/types/uni/uts-plugin-api/lib/uni-textarea/utssdk/index.d.ts +5 -0
  90. package/types/uni/uts-plugin-api/lib/uni-textarea/utssdk/interface.d.ts +0 -0
  91. package/types/uni/uts-plugin-api/lib/uni-theme/utssdk/interface.d.ts +1010 -1010
  92. package/types/uni/uts-plugin-api/lib/uni-video/utssdk/global.d.ts +47 -0
  93. package/types/uni/uts-plugin-api/lib/uni-video/utssdk/index.d.ts +23 -0
  94. package/types/uni/uts-plugin-api/lib/uni-video/utssdk/interface.d.ts +926 -0
  95. package/types/uni/uts-plugin-api/lib/uni-web-view/utssdk/global.d.ts +29 -0
  96. package/types/uni/uts-plugin-api/lib/uni-web-view/utssdk/index.d.ts +14 -0
  97. package/types/uni/uts-plugin-api/lib/uni-web-view/utssdk/interface.d.ts +452 -0
  98. package/types/uni/uts-plugin-api/lib/uni-websocket/utssdk/interface.d.ts +1442 -1442
  99. package/types/uni/uts-plugin-biz/lib/uni-facialVerify/utssdk/interface.d.ts +220 -220
  100. package/types/uni/uts-plugin-biz/lib/uni-map-tencent/utssdk/interface.d.ts +65 -65
  101. package/types/uni/uts-plugin-biz/lib/uni-push/utssdk/interface.d.ts +981 -981
  102. package/types/uni/uts-plugin-biz/lib/uni-verify/utssdk/interface.d.ts +26 -26
  103. package/types/uni/uts-plugin-component/.temp/uni-camera/utssdk/interface.uts +1155 -0
  104. package/types/uni/uts-plugin-component/.temp/uni-camera.d.ts +38 -0
  105. package/types/uni/uts-plugin-component/.temp/uni-camera.ts +52 -0
  106. package/types/uni/uts-plugin-component/.temp/uni-canvas/utssdk/interface.uts +976 -0
  107. package/types/uni/uts-plugin-component/.temp/uni-canvas-dom2/utssdk/interface.uts +976 -0
  108. package/types/uni/uts-plugin-component/.temp/uni-editor.d.ts +171 -0
  109. package/types/uni/uts-plugin-component/.temp/uni-editor.ts +237 -0
  110. package/types/uni/uts-plugin-component/.temp/uni-form.d.ts +2 -0
  111. package/types/uni/uts-plugin-component/.temp/uni-form.ts +1 -0
  112. package/types/uni/uts-plugin-component/.temp/uni-input/utssdk/interface.uts +0 -0
  113. package/types/uni/uts-plugin-component/.temp/uni-map-tencent.d.ts +56 -0
  114. package/types/uni/uts-plugin-component/.temp/uni-map-tencent.ts +88 -0
  115. package/types/uni/uts-plugin-component/.temp/uni-match-media.d.ts +2 -0
  116. package/types/uni/uts-plugin-component/.temp/uni-match-media.ts +2 -0
  117. package/types/uni/uts-plugin-component/.temp/uni-navigator.d.ts +2 -0
  118. package/types/uni/uts-plugin-component/.temp/uni-navigator.ts +1 -0
  119. package/types/uni/uts-plugin-component/.temp/uni-page-container.d.ts +0 -0
  120. package/types/uni/uts-plugin-component/.temp/uni-page-container.ts +2 -0
  121. package/types/uni/uts-plugin-component/.temp/uni-progress.d.ts +2 -0
  122. package/types/uni/uts-plugin-component/.temp/uni-progress.ts +1 -0
  123. package/types/uni/uts-plugin-component/.temp/uni-rich-text.d.ts +7 -0
  124. package/types/uni/uts-plugin-component/.temp/uni-rich-text.ts +12 -0
  125. package/types/uni/uts-plugin-component/.temp/uni-textarea/utssdk/interface.uts +0 -0
  126. package/types/uni/uts-plugin-component/.temp/uni-video/utssdk/interface.uts +936 -0
  127. package/types/uni/uts-plugin-component/.temp/uni-video.d.ts +134 -0
  128. package/types/uni/uts-plugin-component/.temp/uni-video.ts +180 -0
  129. package/types/uni/uts-plugin-component/.temp/uni-web-view/utssdk/interface.uts +452 -0
  130. package/types/uni/uts-plugin-component/.temp/uni-web-view.d.ts +51 -0
  131. package/types/uni/uts-plugin-component/.temp/uni-web-view.ts +86 -0
  132. package/types/uni/uts-plugin-component/global.d.ts +79 -0
  133. package/types/uni/uts-plugin-component/index.d.ts +79 -0
  134. package/types/uni/uts-plugin-component/lib/uni-actionSheet/utssdk/global.d.ts +29 -0
  135. package/types/uni/uts-plugin-component/lib/uni-actionSheet/utssdk/index.d.ts +14 -0
  136. package/types/uni/uts-plugin-component/lib/uni-actionSheet/utssdk/interface.d.ts +1673 -0
  137. package/types/uni/uts-plugin-component/lib/uni-addPhoneContact/utssdk/global.d.ts +25 -0
  138. package/types/uni/uts-plugin-component/lib/uni-addPhoneContact/utssdk/index.d.ts +12 -0
  139. package/types/uni/uts-plugin-component/lib/uni-addPhoneContact/utssdk/interface.d.ts +226 -0
  140. package/types/uni/uts-plugin-component/lib/uni-arrayBufferToBase64/utssdk/global.d.ts +11 -0
  141. package/types/uni/uts-plugin-component/lib/uni-arrayBufferToBase64/utssdk/index.d.ts +5 -0
  142. package/types/uni/uts-plugin-component/lib/uni-arrayBufferToBase64/utssdk/interface.d.ts +79 -0
  143. package/types/uni/uts-plugin-component/lib/uni-authentication/utssdk/global.d.ts +59 -0
  144. package/types/uni/uts-plugin-component/lib/uni-authentication/utssdk/index.d.ts +29 -0
  145. package/types/uni/uts-plugin-component/lib/uni-authentication/utssdk/interface.d.ts +371 -0
  146. package/types/uni/uts-plugin-component/lib/uni-barcode-scanning/utssdk/global.d.ts +9 -0
  147. package/types/uni/uts-plugin-component/lib/uni-barcode-scanning/utssdk/index.d.ts +5 -0
  148. package/types/uni/uts-plugin-component/lib/uni-barcode-scanning/utssdk/interface.d.ts +0 -0
  149. package/types/uni/uts-plugin-component/lib/uni-base64ToArrayBuffer/utssdk/global.d.ts +11 -0
  150. package/types/uni/uts-plugin-component/lib/uni-base64ToArrayBuffer/utssdk/index.d.ts +5 -0
  151. package/types/uni/uts-plugin-component/lib/uni-base64ToArrayBuffer/utssdk/interface.d.ts +79 -0
  152. package/types/uni/uts-plugin-component/lib/uni-canvas/utssdk/interface.d.ts +978 -976
  153. package/types/uni/uts-plugin-component/lib/uni-canvas-dom2/utssdk/interface.d.ts +978 -976
  154. package/types/uni/uts-plugin-component/lib/uni-chooseLocation/utssdk/global.d.ts +25 -0
  155. package/types/uni/uts-plugin-component/lib/uni-chooseLocation/utssdk/index.d.ts +12 -0
  156. package/types/uni/uts-plugin-component/lib/uni-chooseLocation/utssdk/interface.d.ts +423 -0
  157. package/types/uni/uts-plugin-component/lib/uni-chooseMedia/utssdk/global.d.ts +33 -0
  158. package/types/uni/uts-plugin-component/lib/uni-chooseMedia/utssdk/index.d.ts +16 -0
  159. package/types/uni/uts-plugin-component/lib/uni-chooseMedia/utssdk/interface.d.ts +499 -0
  160. package/types/uni/uts-plugin-component/lib/uni-clipboard/utssdk/global.d.ts +45 -0
  161. package/types/uni/uts-plugin-component/lib/uni-clipboard/utssdk/index.d.ts +22 -0
  162. package/types/uni/uts-plugin-component/lib/uni-clipboard/utssdk/interface.d.ts +217 -0
  163. package/types/uni/uts-plugin-component/lib/uni-createInnerAudioContext/utssdk/global.d.ts +33 -0
  164. package/types/uni/uts-plugin-component/lib/uni-createInnerAudioContext/utssdk/index.d.ts +16 -0
  165. package/types/uni/uts-plugin-component/lib/uni-createInnerAudioContext/utssdk/interface.d.ts +3379 -0
  166. package/types/uni/uts-plugin-component/lib/uni-createIntersectionObserver/utssdk/global.d.ts +21 -0
  167. package/types/uni/uts-plugin-component/lib/uni-createIntersectionObserver/utssdk/index.d.ts +10 -0
  168. package/types/uni/uts-plugin-component/lib/uni-createIntersectionObserver/utssdk/interface.d.ts +153 -0
  169. package/types/uni/uts-plugin-component/lib/uni-createRequestPermissionListener/utssdk/global.d.ts +19 -0
  170. package/types/uni/uts-plugin-component/lib/uni-createRequestPermissionListener/utssdk/index.d.ts +9 -0
  171. package/types/uni/uts-plugin-component/lib/uni-createRequestPermissionListener/utssdk/interface.d.ts +61 -0
  172. package/types/uni/uts-plugin-component/lib/uni-createSelectorQuery/utssdk/global.d.ts +21 -0
  173. package/types/uni/uts-plugin-component/lib/uni-createSelectorQuery/utssdk/index.d.ts +10 -0
  174. package/types/uni/uts-plugin-component/lib/uni-createSelectorQuery/utssdk/interface.d.ts +560 -0
  175. package/types/uni/uts-plugin-component/lib/uni-createWebviewContext/utssdk/global.d.ts +15 -0
  176. package/types/uni/uts-plugin-component/lib/uni-createWebviewContext/utssdk/index.d.ts +7 -0
  177. package/types/uni/uts-plugin-component/lib/uni-createWebviewContext/utssdk/interface.d.ts +214 -0
  178. package/types/uni/uts-plugin-component/lib/uni-createWorker/utssdk/global.d.ts +23 -0
  179. package/types/uni/uts-plugin-component/lib/uni-createWorker/utssdk/index.d.ts +11 -0
  180. package/types/uni/uts-plugin-component/lib/uni-createWorker/utssdk/interface.d.ts +158 -0
  181. package/types/uni/uts-plugin-component/lib/uni-dialogPage/utssdk/global.d.ts +29 -0
  182. package/types/uni/uts-plugin-component/lib/uni-dialogPage/utssdk/index.d.ts +14 -0
  183. package/types/uni/uts-plugin-component/lib/uni-dialogPage/utssdk/interface.d.ts +2304 -0
  184. package/types/uni/uts-plugin-component/lib/uni-editor/utssdk/global.d.ts +39 -0
  185. package/types/uni/uts-plugin-component/lib/uni-editor/utssdk/index.d.ts +19 -0
  186. package/types/uni/uts-plugin-component/lib/uni-editor/utssdk/interface.d.ts +856 -0
  187. package/types/uni/uts-plugin-component/lib/uni-editor-global/utssdk/global.d.ts +25 -0
  188. package/types/uni/uts-plugin-component/lib/uni-editor-global/utssdk/index.d.ts +13 -0
  189. package/types/uni/uts-plugin-component/lib/uni-editor-global/utssdk/interface.d.ts +181 -0
  190. package/types/uni/uts-plugin-component/lib/uni-event/utssdk/global.d.ts +17 -0
  191. package/types/uni/uts-plugin-component/lib/uni-event/utssdk/index.d.ts +8 -0
  192. package/types/uni/uts-plugin-component/lib/uni-event/utssdk/interface.d.ts +338 -0
  193. package/types/uni/uts-plugin-component/lib/uni-exit/utssdk/global.d.ts +27 -0
  194. package/types/uni/uts-plugin-component/lib/uni-exit/utssdk/index.d.ts +13 -0
  195. package/types/uni/uts-plugin-component/lib/uni-exit/utssdk/interface.d.ts +147 -0
  196. package/types/uni/uts-plugin-component/lib/uni-file/utssdk/global.d.ts +81 -0
  197. package/types/uni/uts-plugin-component/lib/uni-file/utssdk/index.d.ts +40 -0
  198. package/types/uni/uts-plugin-component/lib/uni-file/utssdk/interface.d.ts +397 -0
  199. package/types/uni/uts-plugin-component/lib/uni-fileSystemManager/utssdk/global.d.ts +151 -0
  200. package/types/uni/uts-plugin-component/lib/uni-fileSystemManager/utssdk/index.d.ts +75 -0
  201. package/types/uni/uts-plugin-component/lib/uni-fileSystemManager/utssdk/interface.d.ts +6428 -0
  202. package/types/uni/uts-plugin-component/lib/uni-getAccessibilityInfo/utssdk/global.d.ts +11 -0
  203. package/types/uni/uts-plugin-component/lib/uni-getAccessibilityInfo/utssdk/index.d.ts +5 -0
  204. package/types/uni/uts-plugin-component/lib/uni-getAccessibilityInfo/utssdk/interface.d.ts +37 -0
  205. package/types/uni/uts-plugin-component/lib/uni-getAppAuthorizeSetting/utssdk/global.d.ts +13 -0
  206. package/types/uni/uts-plugin-component/lib/uni-getAppAuthorizeSetting/utssdk/index.d.ts +6 -0
  207. package/types/uni/uts-plugin-component/lib/uni-getAppAuthorizeSetting/utssdk/interface.d.ts +620 -0
  208. package/types/uni/uts-plugin-component/lib/uni-getAppBaseInfo/utssdk/global.d.ts +15 -0
  209. package/types/uni/uts-plugin-component/lib/uni-getAppBaseInfo/utssdk/index.d.ts +7 -0
  210. package/types/uni/uts-plugin-component/lib/uni-getAppBaseInfo/utssdk/interface.d.ts +2220 -0
  211. package/types/uni/uts-plugin-component/lib/uni-getBackgroundAudioManager/utssdk/global.d.ts +17 -0
  212. package/types/uni/uts-plugin-component/lib/uni-getBackgroundAudioManager/utssdk/index.d.ts +8 -0
  213. package/types/uni/uts-plugin-component/lib/uni-getBackgroundAudioManager/utssdk/interface.d.ts +1406 -0
  214. package/types/uni/uts-plugin-component/lib/uni-getDeviceInfo/utssdk/global.d.ts +15 -0
  215. package/types/uni/uts-plugin-component/lib/uni-getDeviceInfo/utssdk/index.d.ts +7 -0
  216. package/types/uni/uts-plugin-component/lib/uni-getDeviceInfo/utssdk/interface.d.ts +1774 -0
  217. package/types/uni/uts-plugin-component/lib/uni-getElementById/utssdk/global.d.ts +11 -0
  218. package/types/uni/uts-plugin-component/lib/uni-getElementById/utssdk/index.d.ts +5 -0
  219. package/types/uni/uts-plugin-component/lib/uni-getElementById/utssdk/interface.d.ts +82 -0
  220. package/types/uni/uts-plugin-component/lib/uni-getEnterOptionsSync/utssdk/global.d.ts +13 -0
  221. package/types/uni/uts-plugin-component/lib/uni-getEnterOptionsSync/utssdk/index.d.ts +6 -0
  222. package/types/uni/uts-plugin-component/lib/uni-getEnterOptionsSync/utssdk/interface.d.ts +374 -0
  223. package/types/uni/uts-plugin-component/lib/uni-getLaunchOptionsSync/utssdk/global.d.ts +13 -0
  224. package/types/uni/uts-plugin-component/lib/uni-getLaunchOptionsSync/utssdk/index.d.ts +6 -0
  225. package/types/uni/uts-plugin-component/lib/uni-getLaunchOptionsSync/utssdk/interface.d.ts +377 -0
  226. package/types/uni/uts-plugin-component/lib/uni-getLocation-tencent-uni1/utssdk/global.d.ts +21 -0
  227. package/types/uni/uts-plugin-component/lib/uni-getLocation-tencent-uni1/utssdk/index.d.ts +11 -0
  228. package/types/uni/uts-plugin-component/lib/uni-getLocation-tencent-uni1/utssdk/interface.d.ts +736 -0
  229. package/types/uni/uts-plugin-component/lib/uni-getNetworkType/utssdk/global.d.ts +33 -0
  230. package/types/uni/uts-plugin-component/lib/uni-getNetworkType/utssdk/index.d.ts +16 -0
  231. package/types/uni/uts-plugin-component/lib/uni-getNetworkType/utssdk/interface.d.ts +420 -0
  232. package/types/uni/uts-plugin-component/lib/uni-getPerformance/utssdk/global.d.ts +23 -0
  233. package/types/uni/uts-plugin-component/lib/uni-getPerformance/utssdk/index.d.ts +11 -0
  234. package/types/uni/uts-plugin-component/lib/uni-getPerformance/utssdk/interface.d.ts +199 -0
  235. package/types/uni/uts-plugin-component/lib/uni-getProvider/utssdk/global.d.ts +37 -0
  236. package/types/uni/uts-plugin-component/lib/uni-getProvider/utssdk/index.d.ts +18 -0
  237. package/types/uni/uts-plugin-component/lib/uni-getProvider/utssdk/interface.d.ts +757 -0
  238. package/types/uni/uts-plugin-component/lib/uni-getSystemInfo/utssdk/global.d.ts +33 -0
  239. package/types/uni/uts-plugin-component/lib/uni-getSystemInfo/utssdk/index.d.ts +16 -0
  240. package/types/uni/uts-plugin-component/lib/uni-getSystemInfo/utssdk/interface.d.ts +6084 -0
  241. package/types/uni/uts-plugin-component/lib/uni-getSystemSetting/utssdk/global.d.ts +13 -0
  242. package/types/uni/uts-plugin-component/lib/uni-getSystemSetting/utssdk/index.d.ts +6 -0
  243. package/types/uni/uts-plugin-component/lib/uni-getSystemSetting/utssdk/interface.d.ts +508 -0
  244. package/types/uni/uts-plugin-component/lib/uni-installApk/utssdk/global.d.ts +25 -0
  245. package/types/uni/uts-plugin-component/lib/uni-installApk/utssdk/index.d.ts +12 -0
  246. package/types/uni/uts-plugin-component/lib/uni-installApk/utssdk/interface.d.ts +125 -0
  247. package/types/uni/uts-plugin-component/lib/uni-interceptor/utssdk/global.d.ts +17 -0
  248. package/types/uni/uts-plugin-component/lib/uni-interceptor/utssdk/index.d.ts +8 -0
  249. package/types/uni/uts-plugin-component/lib/uni-interceptor/utssdk/interface.d.ts +171 -0
  250. package/types/uni/uts-plugin-component/lib/uni-keyboard/utssdk/global.d.ts +45 -0
  251. package/types/uni/uts-plugin-component/lib/uni-keyboard/utssdk/index.d.ts +22 -0
  252. package/types/uni/uts-plugin-component/lib/uni-keyboard/utssdk/interface.d.ts +234 -0
  253. package/types/uni/uts-plugin-component/lib/uni-loadFontFace/utssdk/global.d.ts +29 -0
  254. package/types/uni/uts-plugin-component/lib/uni-loadFontFace/utssdk/index.d.ts +14 -0
  255. package/types/uni/uts-plugin-component/lib/uni-loadFontFace/utssdk/interface.d.ts +603 -0
  256. package/types/uni/uts-plugin-component/lib/uni-location/utssdk/global.d.ts +61 -0
  257. package/types/uni/uts-plugin-component/lib/uni-location/utssdk/index.d.ts +30 -0
  258. package/types/uni/uts-plugin-component/lib/uni-location/utssdk/interface.d.ts +3443 -0
  259. package/types/uni/uts-plugin-component/lib/uni-location-system/utssdk/global.d.ts +9 -0
  260. package/types/uni/uts-plugin-component/lib/uni-location-system/utssdk/index.d.ts +5 -0
  261. package/types/uni/uts-plugin-component/lib/uni-location-system/utssdk/interface.d.ts +3 -0
  262. package/types/uni/uts-plugin-component/lib/uni-location-tencent/utssdk/global.d.ts +9 -0
  263. package/types/uni/uts-plugin-component/lib/uni-location-tencent/utssdk/index.d.ts +5 -0
  264. package/types/uni/uts-plugin-component/lib/uni-location-tencent/utssdk/interface.d.ts +3 -0
  265. package/types/uni/uts-plugin-component/lib/uni-makePhoneCall/utssdk/global.d.ts +29 -0
  266. package/types/uni/uts-plugin-component/lib/uni-makePhoneCall/utssdk/index.d.ts +14 -0
  267. package/types/uni/uts-plugin-component/lib/uni-makePhoneCall/utssdk/interface.d.ts +386 -0
  268. package/types/uni/uts-plugin-component/lib/uni-media/utssdk/global.d.ts +157 -0
  269. package/types/uni/uts-plugin-component/lib/uni-media/utssdk/index.d.ts +78 -0
  270. package/types/uni/uts-plugin-component/lib/uni-media/utssdk/interface.d.ts +5245 -0
  271. package/types/uni/uts-plugin-component/lib/uni-modal/utssdk/global.d.ts +43 -0
  272. package/types/uni/uts-plugin-component/lib/uni-modal/utssdk/index.d.ts +21 -0
  273. package/types/uni/uts-plugin-component/lib/uni-modal/utssdk/interface.d.ts +291 -0
  274. package/types/uni/uts-plugin-component/lib/uni-navigationBar/utssdk/global.d.ts +69 -0
  275. package/types/uni/uts-plugin-component/lib/uni-navigationBar/utssdk/index.d.ts +34 -0
  276. package/types/uni/uts-plugin-component/lib/uni-navigationBar/utssdk/interface.d.ts +1047 -0
  277. package/types/uni/uts-plugin-component/lib/uni-network/utssdk/global.d.ts +109 -0
  278. package/types/uni/uts-plugin-component/lib/uni-network/utssdk/index.d.ts +54 -0
  279. package/types/uni/uts-plugin-component/lib/uni-network/utssdk/interface.d.ts +4462 -0
  280. package/types/uni/uts-plugin-component/lib/uni-oauth/utssdk/global.d.ts +71 -0
  281. package/types/uni/uts-plugin-component/lib/uni-oauth/utssdk/index.d.ts +35 -0
  282. package/types/uni/uts-plugin-component/lib/uni-oauth/utssdk/interface.d.ts +2142 -0
  283. package/types/uni/uts-plugin-component/lib/uni-oauth-huawei/utssdk/global.d.ts +9 -0
  284. package/types/uni/uts-plugin-component/lib/uni-oauth-huawei/utssdk/index.d.ts +5 -0
  285. package/types/uni/uts-plugin-component/lib/uni-oauth-huawei/utssdk/interface.d.ts +1 -0
  286. package/types/uni/uts-plugin-component/lib/uni-oauth-weixin/utssdk/global.d.ts +17 -0
  287. package/types/uni/uts-plugin-component/lib/uni-oauth-weixin/utssdk/index.d.ts +9 -0
  288. package/types/uni/uts-plugin-component/lib/uni-oauth-weixin/utssdk/interface.d.ts +48 -0
  289. package/types/uni/uts-plugin-component/lib/uni-openAppAuthorizeSetting/utssdk/global.d.ts +25 -0
  290. package/types/uni/uts-plugin-component/lib/uni-openAppAuthorizeSetting/utssdk/index.d.ts +12 -0
  291. package/types/uni/uts-plugin-component/lib/uni-openAppAuthorizeSetting/utssdk/interface.d.ts +256 -0
  292. package/types/uni/uts-plugin-component/lib/uni-openDocument/utssdk/global.d.ts +29 -0
  293. package/types/uni/uts-plugin-component/lib/uni-openDocument/utssdk/index.d.ts +14 -0
  294. package/types/uni/uts-plugin-component/lib/uni-openDocument/utssdk/interface.d.ts +823 -0
  295. package/types/uni/uts-plugin-component/lib/uni-pageScrollTo/utssdk/global.d.ts +27 -0
  296. package/types/uni/uts-plugin-component/lib/uni-pageScrollTo/utssdk/index.d.ts +13 -0
  297. package/types/uni/uts-plugin-component/lib/uni-pageScrollTo/utssdk/interface.d.ts +155 -0
  298. package/types/uni/uts-plugin-component/lib/uni-payment/utssdk/global.d.ts +33 -0
  299. package/types/uni/uts-plugin-component/lib/uni-payment/utssdk/index.d.ts +16 -0
  300. package/types/uni/uts-plugin-component/lib/uni-payment/utssdk/interface.d.ts +856 -0
  301. package/types/uni/uts-plugin-component/lib/uni-payment-alipay/utssdk/global.d.ts +9 -0
  302. package/types/uni/uts-plugin-component/lib/uni-payment-alipay/utssdk/index.d.ts +5 -0
  303. package/types/uni/uts-plugin-component/lib/uni-payment-alipay/utssdk/interface.d.ts +3 -0
  304. package/types/uni/uts-plugin-component/lib/uni-payment-huawei/utssdk/global.d.ts +9 -0
  305. package/types/uni/uts-plugin-component/lib/uni-payment-huawei/utssdk/index.d.ts +5 -0
  306. package/types/uni/uts-plugin-component/lib/uni-payment-huawei/utssdk/interface.d.ts +1 -0
  307. package/types/uni/uts-plugin-component/lib/uni-payment-wxpay/utssdk/global.d.ts +9 -0
  308. package/types/uni/uts-plugin-component/lib/uni-payment-wxpay/utssdk/index.d.ts +5 -0
  309. package/types/uni/uts-plugin-component/lib/uni-payment-wxpay/utssdk/interface.d.ts +5 -0
  310. package/types/uni/uts-plugin-component/lib/uni-picker-global/utssdk/global.d.ts +19 -0
  311. package/types/uni/uts-plugin-component/lib/uni-picker-global/utssdk/index.d.ts +10 -0
  312. package/types/uni/uts-plugin-component/lib/uni-picker-global/utssdk/interface.d.ts +26 -0
  313. package/types/uni/uts-plugin-component/lib/uni-previewImage/utssdk/global.d.ts +47 -0
  314. package/types/uni/uts-plugin-component/lib/uni-previewImage/utssdk/index.d.ts +23 -0
  315. package/types/uni/uts-plugin-component/lib/uni-previewImage/utssdk/interface.d.ts +520 -0
  316. package/types/uni/uts-plugin-component/lib/uni-privacy/utssdk/global.d.ts +31 -0
  317. package/types/uni/uts-plugin-component/lib/uni-privacy/utssdk/index.d.ts +15 -0
  318. package/types/uni/uts-plugin-component/lib/uni-privacy/utssdk/interface.d.ts +568 -0
  319. package/types/uni/uts-plugin-component/lib/uni-prompt/utssdk/global.d.ts +33 -0
  320. package/types/uni/uts-plugin-component/lib/uni-prompt/utssdk/index.d.ts +16 -0
  321. package/types/uni/uts-plugin-component/lib/uni-prompt/utssdk/interface.d.ts +1693 -0
  322. package/types/uni/uts-plugin-component/lib/uni-pullDownRefresh/utssdk/global.d.ts +29 -0
  323. package/types/uni/uts-plugin-component/lib/uni-pullDownRefresh/utssdk/index.d.ts +14 -0
  324. package/types/uni/uts-plugin-component/lib/uni-pullDownRefresh/utssdk/interface.d.ts +191 -0
  325. package/types/uni/uts-plugin-component/lib/uni-recorder/utssdk/global.d.ts +21 -0
  326. package/types/uni/uts-plugin-component/lib/uni-recorder/utssdk/index.d.ts +10 -0
  327. package/types/uni/uts-plugin-component/lib/uni-recorder/utssdk/interface.d.ts +2999 -0
  328. package/types/uni/uts-plugin-component/lib/uni-requestMerchantTransfer/utssdk/global.d.ts +21 -0
  329. package/types/uni/uts-plugin-component/lib/uni-requestMerchantTransfer/utssdk/index.d.ts +10 -0
  330. package/types/uni/uts-plugin-component/lib/uni-requestMerchantTransfer/utssdk/interface.d.ts +713 -0
  331. package/types/uni/uts-plugin-component/lib/uni-route/utssdk/global.d.ts +59 -0
  332. package/types/uni/uts-plugin-component/lib/uni-route/utssdk/index.d.ts +29 -0
  333. package/types/uni/uts-plugin-component/lib/uni-route/utssdk/interface.d.ts +2731 -0
  334. package/types/uni/uts-plugin-component/lib/uni-rpx2px/utssdk/global.d.ts +11 -0
  335. package/types/uni/uts-plugin-component/lib/uni-rpx2px/utssdk/index.d.ts +5 -0
  336. package/types/uni/uts-plugin-component/lib/uni-rpx2px/utssdk/interface.d.ts +81 -0
  337. package/types/uni/uts-plugin-component/lib/uni-scanCode/utssdk/global.d.ts +25 -0
  338. package/types/uni/uts-plugin-component/lib/uni-scanCode/utssdk/index.d.ts +12 -0
  339. package/types/uni/uts-plugin-component/lib/uni-scanCode/utssdk/interface.d.ts +429 -0
  340. package/types/uni/uts-plugin-component/lib/uni-screenBrightness/utssdk/global.d.ts +57 -0
  341. package/types/uni/uts-plugin-component/lib/uni-screenBrightness/utssdk/index.d.ts +28 -0
  342. package/types/uni/uts-plugin-component/lib/uni-screenBrightness/utssdk/interface.d.ts +314 -0
  343. package/types/uni/uts-plugin-component/lib/uni-share/utssdk/global.d.ts +41 -0
  344. package/types/uni/uts-plugin-component/lib/uni-share/utssdk/index.d.ts +20 -0
  345. package/types/uni/uts-plugin-component/lib/uni-share/utssdk/interface.d.ts +584 -0
  346. package/types/uni/uts-plugin-component/lib/uni-share-weixin/utssdk/global.d.ts +9 -0
  347. package/types/uni/uts-plugin-component/lib/uni-share-weixin/utssdk/index.d.ts +5 -0
  348. package/types/uni/uts-plugin-component/lib/uni-share-weixin/utssdk/interface.d.ts +3 -0
  349. package/types/uni/uts-plugin-component/lib/uni-shareWithSystem/utssdk/global.d.ts +27 -0
  350. package/types/uni/uts-plugin-component/lib/uni-shareWithSystem/utssdk/index.d.ts +13 -0
  351. package/types/uni/uts-plugin-component/lib/uni-shareWithSystem/utssdk/interface.d.ts +722 -0
  352. package/types/uni/uts-plugin-component/lib/uni-showLoading/utssdk/global.d.ts +47 -0
  353. package/types/uni/uts-plugin-component/lib/uni-showLoading/utssdk/index.d.ts +23 -0
  354. package/types/uni/uts-plugin-component/lib/uni-showLoading/utssdk/interface.d.ts +446 -0
  355. package/types/uni/uts-plugin-component/lib/uni-sse/utssdk/global.d.ts +21 -0
  356. package/types/uni/uts-plugin-component/lib/uni-sse/utssdk/index.d.ts +10 -0
  357. package/types/uni/uts-plugin-component/lib/uni-sse/utssdk/interface.d.ts +330 -0
  358. package/types/uni/uts-plugin-component/lib/uni-storage/utssdk/global.d.ts +79 -0
  359. package/types/uni/uts-plugin-component/lib/uni-storage/utssdk/index.d.ts +39 -0
  360. package/types/uni/uts-plugin-component/lib/uni-storage/utssdk/interface.d.ts +1030 -0
  361. package/types/uni/uts-plugin-component/lib/uni-tabBar/utssdk/global.d.ts +149 -0
  362. package/types/uni/uts-plugin-component/lib/uni-tabBar/utssdk/index.d.ts +74 -0
  363. package/types/uni/uts-plugin-component/lib/uni-tabBar/utssdk/interface.d.ts +1221 -0
  364. package/types/uni/uts-plugin-component/lib/uni-theme/utssdk/global.d.ts +53 -0
  365. package/types/uni/uts-plugin-component/lib/uni-theme/utssdk/index.d.ts +26 -0
  366. package/types/uni/uts-plugin-component/lib/uni-theme/utssdk/interface.d.ts +1141 -0
  367. package/types/uni/uts-plugin-component/lib/uni-video/utssdk/global.d.ts +0 -22
  368. package/types/uni/uts-plugin-component/lib/uni-video/utssdk/index.d.ts +0 -11
  369. package/types/uni/uts-plugin-component/lib/uni-video/utssdk/interface.d.ts +862 -872
  370. package/types/uni/uts-plugin-component/lib/uni-video-global/utssdk/global.d.ts +4 -14
  371. package/types/uni/uts-plugin-component/lib/uni-video-global/utssdk/index.d.ts +2 -7
  372. package/types/uni/uts-plugin-component/lib/uni-video-global/utssdk/interface.d.ts +14 -51
  373. package/types/uni/uts-plugin-component/lib/uni-virtualPayment/utssdk/global.d.ts +113 -0
  374. package/types/uni/uts-plugin-component/lib/uni-virtualPayment/utssdk/index.d.ts +56 -0
  375. package/types/uni/uts-plugin-component/lib/uni-virtualPayment/utssdk/interface.d.ts +1661 -0
  376. package/types/uni/uts-plugin-component/lib/uni-web-view/utssdk/interface.d.ts +17 -17
  377. package/types/uni/uts-plugin-component/lib/uni-websocket/utssdk/global.d.ts +59 -0
  378. package/types/uni/uts-plugin-component/lib/uni-websocket/utssdk/index.d.ts +29 -0
  379. package/types/uni/uts-plugin-component/lib/uni-websocket/utssdk/interface.d.ts +1939 -0
  380. package/types/vue/LifeCycle.d.ts +865 -854
@@ -1,981 +1,981 @@
1
- export interface Uni {
2
- /**
3
- * getPushClientId()
4
- * @description
5
- * 获取客户端唯一的推送标识
6
- * @param {GetPushClientIdOptions}
7
- * @return {void}
8
- * @tutorial https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#getpushclientid
9
- * @tutorial_uni_app_x https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#getpushclientid
10
- * @tutorial_uni_app http://uniapp.dcloud.io/api/plugins/push.html#getpushclientid
11
- * @uniPlatform {
12
- * "app": {
13
- * "android": {
14
- * "osVer": "4.4",
15
- * "uniVer": "√",
16
- * "unixVer": "3.98"
17
- * },
18
- * "ios": {
19
- * "osVer": "12.0",
20
- * "uniVer": "√",
21
- * "unixVer": "4.18"
22
- * },
23
- * "harmony": {
24
- * "osVer": "3.0",
25
- * "uniVer": "4.31",
26
- * "unixVer": "4.61",
27
- * "unixvVer": "5.0"
28
- * }
29
- * },
30
- * "mp": {
31
- * "weixin": {
32
- * "hostVer": "x",
33
- * "uniVer": "x",
34
- * "unixVer": "4.41"
35
- * },
36
- * "alipay": {
37
- * "hostVer": "x",
38
- * "uniVer": "x",
39
- * "unixVer": "x"
40
- * },
41
- * "baidu": {
42
- * "hostVer": "x",
43
- * "uniVer": "x",
44
- * "unixVer": "x"
45
- * },
46
- * "toutiao": {
47
- * "hostVer": "x",
48
- * "uniVer": "x",
49
- * "unixVer": "x"
50
- * },
51
- * "lark": {
52
- * "hostVer": "x",
53
- * "uniVer": "x",
54
- * "unixVer": "x"
55
- * },
56
- * "qq": {
57
- * "hostVer": "x",
58
- * "uniVer": "x",
59
- * "unixVer": "x"
60
- * },
61
- * "kuaishou": {
62
- * "hostVer": "x",
63
- * "uniVer": "x",
64
- * "unixVer": "x"
65
- * },
66
- * "jd": {
67
- * "hostVer": "x",
68
- * "uniVer": "x",
69
- * "unixVer": "x"
70
- * }
71
- * },
72
- * "web": {
73
- * "uniVer": "x",
74
- * "unixVer": "4.27"
75
- * }
76
- * }
77
- * @example
78
- ```typescript
79
- uni.getPushClientId({
80
- complete: (res: any) => {
81
- console.log("getPushClientId complete => " + JSON.stringify(res));
82
- }
83
- });
84
- ```
85
- */
86
- getPushClientId(options: GetPushClientIdOptions): void;
87
- /**
88
- * onPushMessage()
89
- * @description
90
- * 启动监听推送消息事件
91
- * @param {OnPushMessageCallback}
92
- * @return {void}
93
- * @tutorial https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#onpushmessage
94
- * @tutorial_uni_app_x https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#onpushmessage
95
- * @tutorial_uni_app http://uniapp.dcloud.io/api/plugins/push.html#onpushmessage
96
- * @uniPlatform {
97
- * "app": {
98
- * "android": {
99
- * "osVer": "4.4",
100
- * "uniVer": "√",
101
- * "unixVer": "3.98"
102
- * },
103
- * "ios": {
104
- * "osVer": "12.0",
105
- * "uniVer": "√",
106
- * "unixVer": "4.18"
107
- * },
108
- * "harmony": {
109
- * "osVer": "3.0",
110
- * "uniVer": "4.31",
111
- * "unixVer": "4.61",
112
- * "unixvVer": "5.0"
113
- * }
114
- * },
115
- * "mp": {
116
- * "weixin": {
117
- * "hostVer": "x",
118
- * "uniVer": "x",
119
- * "unixVer": "4.41"
120
- * },
121
- * "alipay": {
122
- * "hostVer": "x",
123
- * "uniVer": "x",
124
- * "unixVer": "x"
125
- * },
126
- * "baidu": {
127
- * "hostVer": "x",
128
- * "uniVer": "x",
129
- * "unixVer": "x"
130
- * },
131
- * "toutiao": {
132
- * "hostVer": "x",
133
- * "uniVer": "x",
134
- * "unixVer": "x"
135
- * },
136
- * "lark": {
137
- * "hostVer": "x",
138
- * "uniVer": "x",
139
- * "unixVer": "x"
140
- * },
141
- * "qq": {
142
- * "hostVer": "x",
143
- * "uniVer": "x",
144
- * "unixVer": "x"
145
- * },
146
- * "kuaishou": {
147
- * "hostVer": "x",
148
- * "uniVer": "x",
149
- * "unixVer": "x"
150
- * },
151
- * "jd": {
152
- * "hostVer": "x",
153
- * "uniVer": "x",
154
- * "unixVer": "x"
155
- * }
156
- * },
157
- * "web": {
158
- * "uniVer": "x",
159
- * "unixVer": "4.27"
160
- * }
161
- * }
162
- * @example
163
- ```typescript
164
- uni.onPushMessage((res : OnPushMessageCallbackResult) => {
165
- console.log("onPushMessage => " + JSON.stringify(res))
166
- });
167
- ```
168
- */
169
- onPushMessage(callback: OnPushMessageCallback): void;
170
- /**
171
- * offPushMessage()
172
- * @description
173
- * 关闭推送消息监听事件,iOS端调用会关闭所有监听。
174
- * @param {OnPushMessageCallback}
175
- * @return {void}
176
- * @tutorial https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#offpushmessage
177
- * @tutorial_uni_app_x https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#offpushmessage
178
- * @tutorial_uni_app http://uniapp.dcloud.io/api/plugins/push.html#offpushmessage
179
- * @uniPlatform {
180
- * "app": {
181
- * "android": {
182
- * "osVer": "4.4",
183
- * "uniVer": "√",
184
- * "unixVer": "3.98"
185
- * },
186
- * "ios": {
187
- * "osVer": "12.0",
188
- * "uniVer": "√",
189
- * "unixVer": "4.18"
190
- * },
191
- * "harmony": {
192
- * "osVer": "3.0",
193
- * "uniVer": "4.31",
194
- * "unixVer": "4.61",
195
- * "unixvVer": "5.0"
196
- * }
197
- * },
198
- * "mp": {
199
- * "weixin": {
200
- * "hostVer": "x",
201
- * "uniVer": "x",
202
- * "unixVer": "4.41"
203
- * },
204
- * "alipay": {
205
- * "hostVer": "x",
206
- * "uniVer": "x",
207
- * "unixVer": "x"
208
- * },
209
- * "baidu": {
210
- * "hostVer": "x",
211
- * "uniVer": "x",
212
- * "unixVer": "x"
213
- * },
214
- * "toutiao": {
215
- * "hostVer": "x",
216
- * "uniVer": "x",
217
- * "unixVer": "x"
218
- * },
219
- * "lark": {
220
- * "hostVer": "x",
221
- * "uniVer": "x",
222
- * "unixVer": "x"
223
- * },
224
- * "qq": {
225
- * "hostVer": "x",
226
- * "uniVer": "x",
227
- * "unixVer": "x"
228
- * },
229
- * "kuaishou": {
230
- * "hostVer": "x",
231
- * "uniVer": "x",
232
- * "unixVer": "x"
233
- * },
234
- * "jd": {
235
- * "hostVer": "x",
236
- * "uniVer": "x",
237
- * "unixVer": "x"
238
- * }
239
- * },
240
- * "web": {
241
- * "uniVer": "x",
242
- * "unixVer": "4.27"
243
- * }
244
- * }
245
- * @example
246
- ```typescript
247
- const cb = (res : OnPushMessageCallbackResult) => {
248
- console.log("onPushMessage => " + JSON.stringify(res))
249
- }
250
- uni.offPushMessage(cb);
251
- ```
252
- */
253
- offPushMessage(callback: OnPushMessageCallback): void;
254
- /**
255
- * 获取通知渠道管理器,Android 8系统以上才可以设置通知渠道,Android 8系统以下返回null,[通知渠道介绍](https://developer.android.com/develop/ui/views/notifications/channels?hl=zh-cn) ,iOS不支持。
256
- *
257
- * @tutorial https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#getchannelmanager
258
- * @tutorial_uni_app_x https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#getchannelmanager
259
- * @tutorial_uni_app https://uniapp.dcloud.net.cn/api/plugins/push.html#getchannelmanager
260
- *
261
- * @deprecated 已废弃,仅为了向下兼容保留,建议使用`getPushChannelManager`。
262
- * @param {void}
263
- * @return {ChannelManager}
264
- * @uniPlatform {
265
- * "app": {
266
- * "android": {
267
- * "osVer": "4.4",
268
- * "uniVer": "3.98",
269
- * "unixVer": "3.98"
270
- * },
271
- * "ios": {
272
- * "osVer": "x",
273
- * "uniVer": "x",
274
- * "unixVer": "x"
275
- * }
276
- * },
277
- * "web": {
278
- * "uniVer": "x",
279
- * "unixVer": "x"
280
- * }
281
- * }
282
- * @example
283
- ```typescript
284
- const channelManager = uni.getChannelManager();
285
- channelManager.setPushChannel({
286
- channelId: "test1",
287
- channelDesc: "test1 desc",
288
- soundName: "pushsound",
289
- enableLights: true,
290
- enableVibration: true,
291
- importance: 4,
292
- lockscreenVisibility: 1
293
- })
294
- const channels = channelManager.getAllChannels() as string[]
295
- console.log("channels : " + channels);
296
- ```
297
- */
298
- getChannelManager(): ChannelManager;
299
-
300
- /**
301
- * 获取通知渠道管理器,Android 8系统以上才可以设置通知渠道,Android 8系统以下返回null,[通知渠道介绍](https://developer.android.com/develop/ui/views/notifications/channels?hl=zh-cn),iOS不支持。
302
- *
303
- * @tutorial https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#getpushchannelmanager
304
- * @tutorial_uni_app_x https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#getpushchannelmanager
305
- *
306
- * @param {void}
307
- * @return {PushChannelManager}
308
- * @uniPlatform {
309
- * "app": {
310
- * "android": {
311
- * "osVer": "4.4",
312
- * "uniVer": "4.25",
313
- * "unixVer": "4.25"
314
- * },
315
- * "ios": {
316
- * "osVer": "x",
317
- * "uniVer": "x",
318
- * "unixVer": "x"
319
- * }
320
- * },
321
- * "web": {
322
- * "uniVer": "x",
323
- * "unixVer": "x"
324
- * }
325
- * }
326
- * @example
327
- ```typescript
328
- const channelManager = uni.getPushChannelManager();
329
- channelManager.setPushChannel({
330
- channelId: "test1",
331
- channelDesc: "test1 desc",
332
- soundName: "pushsound",
333
- enableLights: true,
334
- enableVibration: true,
335
- importance: 4,
336
- lockscreenVisibility: 1
337
- })
338
- const channels = channelManager.getAllChannels() as string[]
339
- console.log("channels : " + channels);
340
- ```
341
- */
342
- getPushChannelManager(): PushChannelManager;
343
-
344
- /**
345
- * 创建本地通知栏消息
346
- *
347
- * @tutorial https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#createpushmessage
348
- * @tutorial_uni_app_x https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#createpushmessage
349
- * @tutorial_uni_app http://uniapp.dcloud.io/api/plugins/push.html#createpushmessage
350
- * @param {CreatePushMessageOptions}
351
- * @return {void}
352
- * @uniPlatform {
353
- * "app": {
354
- * "android": {
355
- * "osVer": "4.4",
356
- * "uniVer": "√",
357
- * "unixVer": "3.98"
358
- * },
359
- * "ios": {
360
- * "osVer": "12.0",
361
- * "uniVer": "√",
362
- * "unixVer": "4.18"
363
- * },
364
- * "harmony": {
365
- * "osVer": "3.0",
366
- * "uniVer": "4.31",
367
- * "unixVer": "4.61",
368
- * "unixvVer": "5.0"
369
- * }
370
- * },
371
- * "web": {
372
- * "uniVer": "x",
373
- * "unixVer": "x"
374
- * }
375
- * }
376
- * @example
377
- ```typescript
378
- uni.createPushMessage({
379
- title: "标题",
380
- content: "您有新的消息",
381
- cover:true,
382
- channelId: "test1",
383
- when:1697623177000,
384
- icon:"/static/icon.png",
385
- delay:5,
386
- payload:{
387
- pkey:"pvalue1"
388
- },
389
- channelId:"message",
390
- category : "IM",
391
- success(res : CreatePushMessageSuccess) {
392
- console.log("res: " + res);
393
- }
394
- });
395
- ```
396
- */
397
- createPushMessage(options: CreatePushMessageOptions): void;
398
-
399
- /**
400
- * 设置应用图标上显示的角标数字,注意:不同手机厂商的角标显示规则不同,有部分设备的rom版本不支持显示角标,另有部分rom需要在应用的通知管理里开启`桌面角标`配置,才可以设置角标成功。
401
- *
402
- * @tutorial https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#setappbadgenumber
403
- * @tutorial_uni_app_x https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#setappbadgenumber
404
- * @tutorial_uni_app https://uniapp.dcloud.net.cn/api/plugins/push.html#setappbadgenumber
405
- *
406
- * @param num - 要显示的角标数字值,参数为0则表示清除角标数字。
407
- * @param options - 小米手机显示角标需要在系统消息中心显示一条通知,此参数用于设置通知的标题(title)和内容(content)。
408
- * @return {void}
409
- * @uniPlatform {
410
- * "app": {
411
- * "android": {
412
- * "osVer": "5.0",
413
- * "uniVer": "x",
414
- * "unixVer": "4.25"
415
- * },
416
- * "ios": {
417
- * "osVer": "12.0",
418
- * "uniVer": "x",
419
- * "unixVer": "4.25"
420
- * },
421
- * "harmony": {
422
- * "osVer": "3.0",
423
- * "uniVer": "4.31",
424
- * "unixVer": "4.61",
425
- * "unixvVer": "5.0"
426
- * }
427
- * },
428
- * "web": {
429
- * "uniVer": "x",
430
- * "unixVer": "x"
431
- * }
432
- * }
433
- *
434
- * @example
435
- ```typescript
436
- if (uni.getDeviceInfo().deviceBrand?.toLowerCase() == "xiaomi") {
437
- uni.setAppBadgeNumber(1, {
438
- title:"AppName",
439
- content: "您有1条未读消息"
440
- } as BadgeOptions)
441
- } else {
442
- uni.setAppBadgeNumber(5)
443
- }
444
- ```
445
- */
446
- setAppBadgeNumber(num: number, options?: BadgeOptions | null): void;
447
- }
448
-
449
- export type GetPushClientId = (options: GetPushClientIdOptions) => void;
450
- export type GetPushClientIdSuccess = {
451
- /**
452
- * 个推客户端推送id,对应uni-id-device表的push_clientid
453
- *
454
- * @uniPlatform {
455
- * "app": {
456
- * "android": {
457
- * "osVer": "4.4",
458
- * "uniVer": "√",
459
- * "unixVer": "3.98"
460
- * },
461
- * "ios": {
462
- * "osVer": "12.0",
463
- * "uniVer": "√",
464
- * "unixVer": "4.18"
465
- * }
466
- * },
467
- * "web": {
468
- * "uniVer": "x",
469
- * "unixVer": "4.27"
470
- * }
471
- * }
472
- */
473
- cid: string,
474
- /**
475
- * 错误描述
476
- *
477
- * @uniPlatform {
478
- * "app": {
479
- * "android": {
480
- * "osVer": "4.4",
481
- * "uniVer": "√",
482
- * "unixVer": "3.98"
483
- * },
484
- * "ios": {
485
- * "osVer": "12.0",
486
- * "uniVer": "√",
487
- * "unixVer": "4.18"
488
- * }
489
- * },
490
- * "web": {
491
- * "uniVer": "x",
492
- * "unixVer": "4.27"
493
- * }
494
- * }
495
- */
496
- errMsg: string
497
- };
498
- export type GetPushClientIdSuccessCallback = (result: GetPushClientIdSuccess) => void;
499
- export type GetPushClientIdFail = UniError;
500
- export type GetPushClientIdFailCallback = (result: GetPushClientIdFail) => void;
501
- export type GetPushClientIdComplete = any;
502
- export type GetPushClientIdCompleteCallback = (result: GetPushClientIdComplete) => void;
503
- export type GetPushClientIdOptions = {
504
- /**
505
- * 接口调用成功的回调函数
506
- * @defaultValue null
507
- */
508
- success?: GetPushClientIdSuccessCallback | null,
509
- /**
510
- * 接口调用失败的回调函数
511
- * @defaultValue null
512
- */
513
- fail?: GetPushClientIdFailCallback | null,
514
- /**
515
- * 接口调用结束的回调函数(调用成功、失败都会执行)
516
- * @defaultValue null
517
- */
518
- complete?: GetPushClientIdCompleteCallback | null
519
- };
520
- /**
521
- * 事件类型
522
- * - click 从系统推送服务点击消息启动应用事件
523
- * - receive 应用从推送服务器接收到推送消息事件
524
- */
525
- export type OnPushMessageType = "click" | "receive";
526
-
527
- export type OnPushMessageCallbackResult = {
528
- /**
529
- * 事件类型
530
- * @type{OnPushMessageType}
531
- *
532
- * @uniPlatform {
533
- * "app": {
534
- * "android": {
535
- * "osVer": "4.4",
536
- * "uniVer": "√",
537
- * "unixVer": "3.98"
538
- * },
539
- * "ios": {
540
- * "osVer": "12.0",
541
- * "uniVer": "√",
542
- * "unixVer": "4.18"
543
- * }
544
- * },
545
- * "web": {
546
- * "uniVer": "x",
547
- * "unixVer": "4.27"
548
- * }
549
- * }
550
- */
551
- type: OnPushMessageType,
552
- /**
553
- * 消息内容
554
- *
555
- * @uniPlatform {
556
- * "app": {
557
- * "android": {
558
- * "osVer": "4.4",
559
- * "uniVer": "√",
560
- * "unixVer": "3.98"
561
- * },
562
- * "ios": {
563
- * "osVer": "12.0",
564
- * "uniVer": "√",
565
- * "unixVer": "4.18"
566
- * }
567
- * },
568
- * "web": {
569
- * "uniVer": "x",
570
- * "unixVer": "4.27"
571
- * }
572
- * }
573
- */
574
- data: UTSJSONObject
575
- };
576
-
577
- export type OnPushMessageCallback = (result: OnPushMessageCallbackResult) => void;
578
- export type OnPushMessage = (callback: OnPushMessageCallback) => void;
579
- export type OffPushMessage = (callback: OnPushMessageCallback) => void;
580
-
581
-
582
- export type GetChannelManager = () => ChannelManager;
583
- export type SetPushChannelOptions = {
584
- /**
585
- * 添加的声音文件,注意raw目录下必须要有 ,不传此字段将使用默认铃音。
586
- * @defaultValue null
587
- */
588
- soundName?: string | null,
589
- /**
590
- * 通知渠道id
591
- */
592
- channelId: string,
593
- /**
594
- * 通知渠道描述
595
- */
596
- channelDesc: string,
597
- /**
598
- * 呼吸灯闪烁
599
- * @defaultValue false
600
- */
601
- enableLights?: boolean | null,
602
- /**
603
- * 震动
604
- * @defaultValue false
605
- */
606
- enableVibration?: boolean | null,
607
- /**
608
- * 通知的重要性级别,可选范围IMPORTANCE_LOW:2、IMPORTANCE_DEFAULT:3、IMPORTANCE_HIGH:4 。
609
- * @defaultValue 3
610
- */
611
- importance?: number | null,
612
- /**
613
- * 锁屏可见性,可选范围VISIBILITY_PRIVATE:0、VISIBILITY_PUBLIC:1、VISIBILITY_SECRET:-1、VISIBILITY_NO_OVERRIDE:-1000。
614
- * @defaultValue -1000
615
- */
616
- lockscreenVisibility?: number | null
617
- }
618
-
619
- export interface ChannelManager {
620
- /**
621
- * 设置推送渠道
622
- *
623
- * @uniPlatform {
624
- * "app": {
625
- * "android": {
626
- * "osVer": "4.4",
627
- * "uniVer": "√",
628
- * "unixVer": "3.98"
629
- * },
630
- * "ios": {
631
- * "osVer": "x",
632
- * "uniVer": "x",
633
- * "unixVer": "x"
634
- * }
635
- * },
636
- * "web": {
637
- * "uniVer": "x",
638
- * "unixVer": "x"
639
- * }
640
- * }
641
- */
642
- setPushChannel(options: SetPushChannelOptions): void;
643
- /**
644
- * 获取当前应用注册的所有的通知渠道。
645
- *
646
- * @uniPlatform {
647
- * "app": {
648
- * "android": {
649
- * "osVer": "4.4",
650
- * "uniVer": "√",
651
- * "unixVer": "3.98"
652
- * },
653
- * "ios": {
654
- * "osVer": "x",
655
- * "uniVer": "x",
656
- * "unixVer": "x"
657
- * }
658
- * },
659
- * "web": {
660
- * "uniVer": "x",
661
- * "unixVer": "x"
662
- * }
663
- * }
664
- */
665
- getAllChannels(): Array<string>;
666
- }
667
-
668
- export type PushChannelManager = ChannelManager
669
-
670
-
671
- export type CreatePushMessage = (options: CreatePushMessageOptions) => void;
672
- export type CreatePushMessageSuccess = {};
673
- export type CreatePushMessageSuccessCallback = (result: CreatePushMessageSuccess) => void;
674
- export type CreatePushMessageFail = UniError;
675
- export type CreatePushMessageFailCallback = (result: CreatePushMessageFail) => void;
676
- export type CreatePushMessageComplete = any;
677
- export type CreatePushMessageCompleteCallback = (result: CreatePushMessageComplete) => void;
678
- export type CreatePushMessageOptions = {
679
- /**
680
- * 是否覆盖上一次提示的消息
681
- * @type boolean
682
- * @defaultValue false
683
- * @uniPlatform {
684
- * "app": {
685
- * "android": {
686
- * "osVer": "4.4",
687
- * "uniVer": "√",
688
- * "unixVer": "3.98"
689
- * },
690
- * "ios": {
691
- * "osVer": "12.0",
692
- * "uniVer": "√",
693
- * "unixVer": "4.18"
694
- * }
695
- * },
696
- * "web": {
697
- * "uniVer": "x",
698
- * "unixVer": "x"
699
- * }
700
- * }
701
- */
702
- cover?: boolean | null,
703
- /**
704
- * 提示消息延迟显示的时间,单位为s
705
- * @defaultValue 0
706
- * @uniPlatform {
707
- * "app": {
708
- * "android": {
709
- * "osVer": "4.4",
710
- * "uniVer": "√",
711
- * "unixVer": "3.98"
712
- * },
713
- * "ios": {
714
- * "osVer": "12.0",
715
- * "uniVer": "√",
716
- * "unixVer": "4.18"
717
- * }
718
- * },
719
- * "web": {
720
- * "uniVer": "x",
721
- * "unixVer": "x"
722
- * }
723
- * }
724
- */
725
- delay?: number | null,
726
- /**
727
- * 推送消息的图标
728
- * @defaultValue null
729
- * @uniPlatform {
730
- * "app": {
731
- * "android": {
732
- * "osVer": "4.4",
733
- * "uniVer": "√",
734
- * "unixVer": "3.98"
735
- * },
736
- * "ios": {
737
- * "osVer": "12.0",
738
- * "uniVer": "x",
739
- * "unixVer": "x"
740
- * }
741
- * },
742
- * "web": {
743
- * "uniVer": "x",
744
- * "unixVer": "x"
745
- * }
746
- * }
747
- */
748
- icon?: string | null,
749
- /**
750
- * 推送消息的提示音
751
- * - system: 使用系统通知提示音(默认值)
752
- * - none: 不使用提示音
753
- * @type 'system' | 'none'
754
- * @defaultValue "system"
755
- * @uniPlatform {
756
- * "app": {
757
- * "android": {
758
- * "osVer": "4.4",
759
- * "uniVer": "√",
760
- * "unixVer": "3.98"
761
- * },
762
- * "ios": {
763
- * "osVer": "12.0",
764
- * "uniVer": "√",
765
- * "unixVer": "4.18"
766
- * }
767
- * },
768
- * "web": {
769
- * "uniVer": "x",
770
- * "unixVer": "x"
771
- * }
772
- * }
773
- */
774
- sound?: string | null,
775
- /**
776
- * 推送消息的标题
777
- * @defaultValue App的名称
778
- * @uniPlatform {
779
- * "app": {
780
- * "android": {
781
- * "osVer": "4.4",
782
- * "uniVer": "√",
783
- * "unixVer": "3.98"
784
- * },
785
- * "ios": {
786
- * "osVer": "12.0",
787
- * "uniVer": "√",
788
- * "unixVer": "4.18"
789
- * }
790
- * },
791
- * "web": {
792
- * "uniVer": "x",
793
- * "unixVer": "x"
794
- * }
795
- * }
796
- */
797
- title?: string | null,
798
- /**
799
- * 消息显示的内容,在系统通知中心中显示的文本内容。鸿蒙系统中,此字段为必填字段。
800
- *
801
- * @uniPlatform {
802
- * "app": {
803
- * "android": {
804
- * "osVer": "4.4",
805
- * "uniVer": "√",
806
- * "unixVer": "3.98"
807
- * },
808
- * "ios": {
809
- * "osVer": "12.0",
810
- * "uniVer": "√",
811
- * "unixVer": "4.18"
812
- * }
813
- * },
814
- * "web": {
815
- * "uniVer": "x",
816
- * "unixVer": "x"
817
- * }
818
- * }
819
- */
820
- content: string,
821
- /**
822
- * 消息承载的数据,可根据业务逻辑自定义数据格式,在点击通知消息时`onPushMessage`回调中会返回此字段的数据。
823
- * @defaultValue null
824
- * @uniPlatform {
825
- * "app": {
826
- * "android": {
827
- * "osVer": "4.4",
828
- * "uniVer": "√",
829
- * "unixVer": "3.98"
830
- * },
831
- * "ios": {
832
- * "osVer": "12.0",
833
- * "uniVer": "√",
834
- * "unixVer": "4.18"
835
- * }
836
- * },
837
- * "web": {
838
- * "uniVer": "x",
839
- * "unixVer": "x"
840
- * }
841
- * }
842
- */
843
- payload?: any | null,
844
- /**
845
- * 消息上显示的提示时间,需要传入时间戳。
846
- * @defaultValue 当前时间
847
- *
848
- * @uniPlatform {
849
- * "app": {
850
- * "android": {
851
- * "osVer": "4.4",
852
- * "uniVer": "√",
853
- * "unixVer": "3.98"
854
- * },
855
- * "ios": {
856
- * "osVer": "x",
857
- * "uniVer": "x",
858
- * "unixVer": "x"
859
- * }
860
- * },
861
- * "web": {
862
- * "uniVer": "x",
863
- * "unixVer": "x"
864
- * }
865
- * }
866
- */
867
- when?: number | null,
868
- /**
869
- * 渠道id,Android特有字段,[通知渠道介绍](https://developer.android.com/develop/ui/views/notifications/channels?hl=zh-cn),
870
- * 创建通知渠道请使用`getPushChannelManager`获取PushChannelManager对象,调用`setPushChannel`方法配置渠道。
871
- * @defaultValue "DcloudChannelID"
872
- * @uniPlatform {
873
- * "app": {
874
- * "android": {
875
- * "osVer": "4.4",
876
- * "uniVer": "√",
877
- * "unixVer": "3.98"
878
- * },
879
- * "ios": {
880
- * "osVer": "x",
881
- * "uniVer": "x",
882
- * "unixVer": "x"
883
- * }
884
- * },
885
- * "web": {
886
- * "uniVer": "x",
887
- * "unixVer": "x"
888
- * }
889
- * }
890
- */
891
- channelId?: string | null,
892
- /**
893
- * 通知类别,Android特有字段,[通知渠道介绍](https://developer.android.com/develop/ui/views/notifications/channels?hl=zh-cn),
894
- * 标识通知的类别,应用场景为对于离线推送厂商配置的支持,比如[华为消息分类](https://developer.huawei.com/consumer/cn/doc/HMSCore-Guides/message-classification-0000001149358835#section5101818813)
895
- * @defaultValue null
896
- * @uniPlatform {
897
- * "app": {
898
- * "android": {
899
- * "osVer": "4.4",
900
- * "uniVer": "√",
901
- * "unixVer": "3.98"
902
- * },
903
- * "ios": {
904
- * "osVer": "x",
905
- * "uniVer": "x",
906
- * "unixVer": "x"
907
- * }
908
- * },
909
- * "web": {
910
- * "uniVer": "x",
911
- * "unixVer": "x"
912
- * }
913
- * }
914
- */
915
- category?: string | null,
916
- /**
917
- * 接口调用成功的回调函数
918
- * @defaultValue null
919
- */
920
- success?: CreatePushMessageSuccessCallback | null,
921
- /**
922
- * 接口调用失败的回调函数
923
- * @defaultValue null
924
- */
925
- fail?: CreatePushMessageFailCallback | null,
926
- /**
927
- * 接口调用结束的回调函数(调用成功、失败都会执行)
928
- * @defaultValue null
929
- */
930
- complete?: CreatePushMessageCompleteCallback | null
931
- };
932
-
933
-
934
- export type BadgeOptions = {
935
- /**
936
- * 消息的标题
937
- * @defaultValue 应用的名称
938
- * @uniPlatform {
939
- * "app": {
940
- * "android": {
941
- * "osVer": "4.4",
942
- * "uniVer": "x",
943
- * "unixVer": "4.25"
944
- * },
945
- * "ios": {
946
- * "osVer": "12.0",
947
- * "uniVer": "x",
948
- * "unixVer": "4.25"
949
- * }
950
- * },
951
- * "web": {
952
- * "uniVer": "x",
953
- * "unixVer": "x"
954
- * }
955
- * }
956
- */
957
- title?: string | null,
958
- /**
959
- * 消息的内容
960
- * @defaultValue '您有x条未读消息',其中x为设置的角标数字值。
961
- * @uniPlatform {
962
- * "app": {
963
- * "android": {
964
- * "osVer": "4.4",
965
- * "uniVer": "x",
966
- * "unixVer": "4.25"
967
- * },
968
- * "ios": {
969
- * "osVer": "12.0",
970
- * "uniVer": "x",
971
- * "unixVer": "4.25"
972
- * }
973
- * },
974
- * "web": {
975
- * "uniVer": "x",
976
- * "unixVer": "x"
977
- * }
978
- * }
979
- */
980
- content?: string | null
981
- }
1
+ export interface Uni {
2
+ /**
3
+ * getPushClientId()
4
+ * @description
5
+ * 获取客户端唯一的推送标识
6
+ * @param {GetPushClientIdOptions}
7
+ * @return {void}
8
+ * @tutorial https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#getpushclientid
9
+ * @tutorial_uni_app_x https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#getpushclientid
10
+ * @tutorial_uni_app http://uniapp.dcloud.io/api/plugins/push.html#getpushclientid
11
+ * @uniPlatform {
12
+ * "app": {
13
+ * "android": {
14
+ * "osVer": "4.4",
15
+ * "uniVer": "√",
16
+ * "unixVer": "3.98"
17
+ * },
18
+ * "ios": {
19
+ * "osVer": "12.0",
20
+ * "uniVer": "√",
21
+ * "unixVer": "4.18"
22
+ * },
23
+ * "harmony": {
24
+ * "osVer": "3.0",
25
+ * "uniVer": "4.31",
26
+ * "unixVer": "4.61",
27
+ * "unixVaporVer": "5.0"
28
+ * }
29
+ * },
30
+ * "mp": {
31
+ * "weixin": {
32
+ * "hostVer": "x",
33
+ * "uniVer": "x",
34
+ * "unixVer": "4.41"
35
+ * },
36
+ * "alipay": {
37
+ * "hostVer": "x",
38
+ * "uniVer": "x",
39
+ * "unixVer": "x"
40
+ * },
41
+ * "baidu": {
42
+ * "hostVer": "x",
43
+ * "uniVer": "x",
44
+ * "unixVer": "x"
45
+ * },
46
+ * "toutiao": {
47
+ * "hostVer": "x",
48
+ * "uniVer": "x",
49
+ * "unixVer": "x"
50
+ * },
51
+ * "lark": {
52
+ * "hostVer": "x",
53
+ * "uniVer": "x",
54
+ * "unixVer": "x"
55
+ * },
56
+ * "qq": {
57
+ * "hostVer": "x",
58
+ * "uniVer": "x",
59
+ * "unixVer": "x"
60
+ * },
61
+ * "kuaishou": {
62
+ * "hostVer": "x",
63
+ * "uniVer": "x",
64
+ * "unixVer": "x"
65
+ * },
66
+ * "jd": {
67
+ * "hostVer": "x",
68
+ * "uniVer": "x",
69
+ * "unixVer": "x"
70
+ * }
71
+ * },
72
+ * "web": {
73
+ * "uniVer": "x",
74
+ * "unixVer": "4.27"
75
+ * }
76
+ * }
77
+ * @example
78
+ ```typescript
79
+ uni.getPushClientId({
80
+ complete: (res: any) => {
81
+ console.log("getPushClientId complete => " + JSON.stringify(res));
82
+ }
83
+ });
84
+ ```
85
+ */
86
+ getPushClientId(options: GetPushClientIdOptions): void;
87
+ /**
88
+ * onPushMessage()
89
+ * @description
90
+ * 启动监听推送消息事件
91
+ * @param {OnPushMessageCallback}
92
+ * @return {void}
93
+ * @tutorial https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#onpushmessage
94
+ * @tutorial_uni_app_x https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#onpushmessage
95
+ * @tutorial_uni_app http://uniapp.dcloud.io/api/plugins/push.html#onpushmessage
96
+ * @uniPlatform {
97
+ * "app": {
98
+ * "android": {
99
+ * "osVer": "4.4",
100
+ * "uniVer": "√",
101
+ * "unixVer": "3.98"
102
+ * },
103
+ * "ios": {
104
+ * "osVer": "12.0",
105
+ * "uniVer": "√",
106
+ * "unixVer": "4.18"
107
+ * },
108
+ * "harmony": {
109
+ * "osVer": "3.0",
110
+ * "uniVer": "4.31",
111
+ * "unixVer": "4.61",
112
+ * "unixVaporVer": "5.0"
113
+ * }
114
+ * },
115
+ * "mp": {
116
+ * "weixin": {
117
+ * "hostVer": "x",
118
+ * "uniVer": "x",
119
+ * "unixVer": "4.41"
120
+ * },
121
+ * "alipay": {
122
+ * "hostVer": "x",
123
+ * "uniVer": "x",
124
+ * "unixVer": "x"
125
+ * },
126
+ * "baidu": {
127
+ * "hostVer": "x",
128
+ * "uniVer": "x",
129
+ * "unixVer": "x"
130
+ * },
131
+ * "toutiao": {
132
+ * "hostVer": "x",
133
+ * "uniVer": "x",
134
+ * "unixVer": "x"
135
+ * },
136
+ * "lark": {
137
+ * "hostVer": "x",
138
+ * "uniVer": "x",
139
+ * "unixVer": "x"
140
+ * },
141
+ * "qq": {
142
+ * "hostVer": "x",
143
+ * "uniVer": "x",
144
+ * "unixVer": "x"
145
+ * },
146
+ * "kuaishou": {
147
+ * "hostVer": "x",
148
+ * "uniVer": "x",
149
+ * "unixVer": "x"
150
+ * },
151
+ * "jd": {
152
+ * "hostVer": "x",
153
+ * "uniVer": "x",
154
+ * "unixVer": "x"
155
+ * }
156
+ * },
157
+ * "web": {
158
+ * "uniVer": "x",
159
+ * "unixVer": "4.27"
160
+ * }
161
+ * }
162
+ * @example
163
+ ```typescript
164
+ uni.onPushMessage((res : OnPushMessageCallbackResult) => {
165
+ console.log("onPushMessage => " + JSON.stringify(res))
166
+ });
167
+ ```
168
+ */
169
+ onPushMessage(callback: OnPushMessageCallback): void;
170
+ /**
171
+ * offPushMessage()
172
+ * @description
173
+ * 关闭推送消息监听事件,iOS端调用会关闭所有监听。
174
+ * @param {OnPushMessageCallback}
175
+ * @return {void}
176
+ * @tutorial https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#offpushmessage
177
+ * @tutorial_uni_app_x https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#offpushmessage
178
+ * @tutorial_uni_app http://uniapp.dcloud.io/api/plugins/push.html#offpushmessage
179
+ * @uniPlatform {
180
+ * "app": {
181
+ * "android": {
182
+ * "osVer": "4.4",
183
+ * "uniVer": "√",
184
+ * "unixVer": "3.98"
185
+ * },
186
+ * "ios": {
187
+ * "osVer": "12.0",
188
+ * "uniVer": "√",
189
+ * "unixVer": "4.18"
190
+ * },
191
+ * "harmony": {
192
+ * "osVer": "3.0",
193
+ * "uniVer": "4.31",
194
+ * "unixVer": "4.61",
195
+ * "unixVaporVer": "5.0"
196
+ * }
197
+ * },
198
+ * "mp": {
199
+ * "weixin": {
200
+ * "hostVer": "x",
201
+ * "uniVer": "x",
202
+ * "unixVer": "4.41"
203
+ * },
204
+ * "alipay": {
205
+ * "hostVer": "x",
206
+ * "uniVer": "x",
207
+ * "unixVer": "x"
208
+ * },
209
+ * "baidu": {
210
+ * "hostVer": "x",
211
+ * "uniVer": "x",
212
+ * "unixVer": "x"
213
+ * },
214
+ * "toutiao": {
215
+ * "hostVer": "x",
216
+ * "uniVer": "x",
217
+ * "unixVer": "x"
218
+ * },
219
+ * "lark": {
220
+ * "hostVer": "x",
221
+ * "uniVer": "x",
222
+ * "unixVer": "x"
223
+ * },
224
+ * "qq": {
225
+ * "hostVer": "x",
226
+ * "uniVer": "x",
227
+ * "unixVer": "x"
228
+ * },
229
+ * "kuaishou": {
230
+ * "hostVer": "x",
231
+ * "uniVer": "x",
232
+ * "unixVer": "x"
233
+ * },
234
+ * "jd": {
235
+ * "hostVer": "x",
236
+ * "uniVer": "x",
237
+ * "unixVer": "x"
238
+ * }
239
+ * },
240
+ * "web": {
241
+ * "uniVer": "x",
242
+ * "unixVer": "4.27"
243
+ * }
244
+ * }
245
+ * @example
246
+ ```typescript
247
+ const cb = (res : OnPushMessageCallbackResult) => {
248
+ console.log("onPushMessage => " + JSON.stringify(res))
249
+ }
250
+ uni.offPushMessage(cb);
251
+ ```
252
+ */
253
+ offPushMessage(callback: OnPushMessageCallback): void;
254
+ /**
255
+ * 获取通知渠道管理器,Android 8系统以上才可以设置通知渠道,Android 8系统以下返回null,[通知渠道介绍](https://developer.android.com/develop/ui/views/notifications/channels?hl=zh-cn) ,iOS不支持。
256
+ *
257
+ * @tutorial https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#getchannelmanager
258
+ * @tutorial_uni_app_x https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#getchannelmanager
259
+ * @tutorial_uni_app https://uniapp.dcloud.net.cn/api/plugins/push.html#getchannelmanager
260
+ *
261
+ * @deprecated 已废弃,仅为了向下兼容保留,建议使用`getPushChannelManager`。
262
+ * @param {void}
263
+ * @return {ChannelManager}
264
+ * @uniPlatform {
265
+ * "app": {
266
+ * "android": {
267
+ * "osVer": "4.4",
268
+ * "uniVer": "3.98",
269
+ * "unixVer": "3.98"
270
+ * },
271
+ * "ios": {
272
+ * "osVer": "x",
273
+ * "uniVer": "x",
274
+ * "unixVer": "x"
275
+ * }
276
+ * },
277
+ * "web": {
278
+ * "uniVer": "x",
279
+ * "unixVer": "x"
280
+ * }
281
+ * }
282
+ * @example
283
+ ```typescript
284
+ const channelManager = uni.getChannelManager();
285
+ channelManager.setPushChannel({
286
+ channelId: "test1",
287
+ channelDesc: "test1 desc",
288
+ soundName: "pushsound",
289
+ enableLights: true,
290
+ enableVibration: true,
291
+ importance: 4,
292
+ lockscreenVisibility: 1
293
+ })
294
+ const channels = channelManager.getAllChannels() as string[]
295
+ console.log("channels : " + channels);
296
+ ```
297
+ */
298
+ getChannelManager(): ChannelManager;
299
+
300
+ /**
301
+ * 获取通知渠道管理器,Android 8系统以上才可以设置通知渠道,Android 8系统以下返回null,[通知渠道介绍](https://developer.android.com/develop/ui/views/notifications/channels?hl=zh-cn),iOS不支持。
302
+ *
303
+ * @tutorial https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#getpushchannelmanager
304
+ * @tutorial_uni_app_x https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#getpushchannelmanager
305
+ *
306
+ * @param {void}
307
+ * @return {PushChannelManager}
308
+ * @uniPlatform {
309
+ * "app": {
310
+ * "android": {
311
+ * "osVer": "4.4",
312
+ * "uniVer": "4.25",
313
+ * "unixVer": "4.25"
314
+ * },
315
+ * "ios": {
316
+ * "osVer": "x",
317
+ * "uniVer": "x",
318
+ * "unixVer": "x"
319
+ * }
320
+ * },
321
+ * "web": {
322
+ * "uniVer": "x",
323
+ * "unixVer": "x"
324
+ * }
325
+ * }
326
+ * @example
327
+ ```typescript
328
+ const channelManager = uni.getPushChannelManager();
329
+ channelManager.setPushChannel({
330
+ channelId: "test1",
331
+ channelDesc: "test1 desc",
332
+ soundName: "pushsound",
333
+ enableLights: true,
334
+ enableVibration: true,
335
+ importance: 4,
336
+ lockscreenVisibility: 1
337
+ })
338
+ const channels = channelManager.getAllChannels() as string[]
339
+ console.log("channels : " + channels);
340
+ ```
341
+ */
342
+ getPushChannelManager(): PushChannelManager;
343
+
344
+ /**
345
+ * 创建本地通知栏消息
346
+ *
347
+ * @tutorial https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#createpushmessage
348
+ * @tutorial_uni_app_x https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#createpushmessage
349
+ * @tutorial_uni_app http://uniapp.dcloud.io/api/plugins/push.html#createpushmessage
350
+ * @param {CreatePushMessageOptions}
351
+ * @return {void}
352
+ * @uniPlatform {
353
+ * "app": {
354
+ * "android": {
355
+ * "osVer": "4.4",
356
+ * "uniVer": "√",
357
+ * "unixVer": "3.98"
358
+ * },
359
+ * "ios": {
360
+ * "osVer": "12.0",
361
+ * "uniVer": "√",
362
+ * "unixVer": "4.18"
363
+ * },
364
+ * "harmony": {
365
+ * "osVer": "3.0",
366
+ * "uniVer": "4.31",
367
+ * "unixVer": "4.61",
368
+ * "unixVaporVer": "5.0"
369
+ * }
370
+ * },
371
+ * "web": {
372
+ * "uniVer": "x",
373
+ * "unixVer": "x"
374
+ * }
375
+ * }
376
+ * @example
377
+ ```typescript
378
+ uni.createPushMessage({
379
+ title: "标题",
380
+ content: "您有新的消息",
381
+ cover:true,
382
+ channelId: "test1",
383
+ when:1697623177000,
384
+ icon:"/static/icon.png",
385
+ delay:5,
386
+ payload:{
387
+ pkey:"pvalue1"
388
+ },
389
+ channelId:"message",
390
+ category : "IM",
391
+ success(res : CreatePushMessageSuccess) {
392
+ console.log("res: " + res);
393
+ }
394
+ });
395
+ ```
396
+ */
397
+ createPushMessage(options: CreatePushMessageOptions): void;
398
+
399
+ /**
400
+ * 设置应用图标上显示的角标数字,注意:不同手机厂商的角标显示规则不同,有部分设备的rom版本不支持显示角标,另有部分rom需要在应用的通知管理里开启`桌面角标`配置,才可以设置角标成功。
401
+ *
402
+ * @tutorial https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#setappbadgenumber
403
+ * @tutorial_uni_app_x https://doc.dcloud.net.cn/uni-app-x/api/uni-push.html#setappbadgenumber
404
+ * @tutorial_uni_app https://uniapp.dcloud.net.cn/api/plugins/push.html#setappbadgenumber
405
+ *
406
+ * @param num - 要显示的角标数字值,参数为0则表示清除角标数字。
407
+ * @param options - 小米手机显示角标需要在系统消息中心显示一条通知,此参数用于设置通知的标题(title)和内容(content)。
408
+ * @return {void}
409
+ * @uniPlatform {
410
+ * "app": {
411
+ * "android": {
412
+ * "osVer": "5.0",
413
+ * "uniVer": "x",
414
+ * "unixVer": "4.25"
415
+ * },
416
+ * "ios": {
417
+ * "osVer": "12.0",
418
+ * "uniVer": "x",
419
+ * "unixVer": "4.25"
420
+ * },
421
+ * "harmony": {
422
+ * "osVer": "3.0",
423
+ * "uniVer": "4.31",
424
+ * "unixVer": "4.61",
425
+ * "unixVaporVer": "5.0"
426
+ * }
427
+ * },
428
+ * "web": {
429
+ * "uniVer": "x",
430
+ * "unixVer": "x"
431
+ * }
432
+ * }
433
+ *
434
+ * @example
435
+ ```typescript
436
+ if (uni.getDeviceInfo().deviceBrand?.toLowerCase() == "xiaomi") {
437
+ uni.setAppBadgeNumber(1, {
438
+ title:"AppName",
439
+ content: "您有1条未读消息"
440
+ } as BadgeOptions)
441
+ } else {
442
+ uni.setAppBadgeNumber(5)
443
+ }
444
+ ```
445
+ */
446
+ setAppBadgeNumber(num: number, options?: BadgeOptions | null): void;
447
+ }
448
+
449
+ export type GetPushClientId = (options: GetPushClientIdOptions) => void;
450
+ export type GetPushClientIdSuccess = {
451
+ /**
452
+ * 个推客户端推送id,对应uni-id-device表的push_clientid
453
+ *
454
+ * @uniPlatform {
455
+ * "app": {
456
+ * "android": {
457
+ * "osVer": "4.4",
458
+ * "uniVer": "√",
459
+ * "unixVer": "3.98"
460
+ * },
461
+ * "ios": {
462
+ * "osVer": "12.0",
463
+ * "uniVer": "√",
464
+ * "unixVer": "4.18"
465
+ * }
466
+ * },
467
+ * "web": {
468
+ * "uniVer": "x",
469
+ * "unixVer": "4.27"
470
+ * }
471
+ * }
472
+ */
473
+ cid: string,
474
+ /**
475
+ * 错误描述
476
+ *
477
+ * @uniPlatform {
478
+ * "app": {
479
+ * "android": {
480
+ * "osVer": "4.4",
481
+ * "uniVer": "√",
482
+ * "unixVer": "3.98"
483
+ * },
484
+ * "ios": {
485
+ * "osVer": "12.0",
486
+ * "uniVer": "√",
487
+ * "unixVer": "4.18"
488
+ * }
489
+ * },
490
+ * "web": {
491
+ * "uniVer": "x",
492
+ * "unixVer": "4.27"
493
+ * }
494
+ * }
495
+ */
496
+ errMsg: string
497
+ };
498
+ export type GetPushClientIdSuccessCallback = (result: GetPushClientIdSuccess) => void;
499
+ export type GetPushClientIdFail = UniError;
500
+ export type GetPushClientIdFailCallback = (result: GetPushClientIdFail) => void;
501
+ export type GetPushClientIdComplete = any;
502
+ export type GetPushClientIdCompleteCallback = (result: GetPushClientIdComplete) => void;
503
+ export type GetPushClientIdOptions = {
504
+ /**
505
+ * 接口调用成功的回调函数
506
+ * @defaultValue null
507
+ */
508
+ success?: GetPushClientIdSuccessCallback | null,
509
+ /**
510
+ * 接口调用失败的回调函数
511
+ * @defaultValue null
512
+ */
513
+ fail?: GetPushClientIdFailCallback | null,
514
+ /**
515
+ * 接口调用结束的回调函数(调用成功、失败都会执行)
516
+ * @defaultValue null
517
+ */
518
+ complete?: GetPushClientIdCompleteCallback | null
519
+ };
520
+ /**
521
+ * 事件类型
522
+ * - click 从系统推送服务点击消息启动应用事件
523
+ * - receive 应用从推送服务器接收到推送消息事件
524
+ */
525
+ export type OnPushMessageType = "click" | "receive";
526
+
527
+ export type OnPushMessageCallbackResult = {
528
+ /**
529
+ * 事件类型
530
+ * @type{OnPushMessageType}
531
+ *
532
+ * @uniPlatform {
533
+ * "app": {
534
+ * "android": {
535
+ * "osVer": "4.4",
536
+ * "uniVer": "√",
537
+ * "unixVer": "3.98"
538
+ * },
539
+ * "ios": {
540
+ * "osVer": "12.0",
541
+ * "uniVer": "√",
542
+ * "unixVer": "4.18"
543
+ * }
544
+ * },
545
+ * "web": {
546
+ * "uniVer": "x",
547
+ * "unixVer": "4.27"
548
+ * }
549
+ * }
550
+ */
551
+ type: OnPushMessageType,
552
+ /**
553
+ * 消息内容
554
+ *
555
+ * @uniPlatform {
556
+ * "app": {
557
+ * "android": {
558
+ * "osVer": "4.4",
559
+ * "uniVer": "√",
560
+ * "unixVer": "3.98"
561
+ * },
562
+ * "ios": {
563
+ * "osVer": "12.0",
564
+ * "uniVer": "√",
565
+ * "unixVer": "4.18"
566
+ * }
567
+ * },
568
+ * "web": {
569
+ * "uniVer": "x",
570
+ * "unixVer": "4.27"
571
+ * }
572
+ * }
573
+ */
574
+ data: UTSJSONObject
575
+ };
576
+
577
+ export type OnPushMessageCallback = (result: OnPushMessageCallbackResult) => void;
578
+ export type OnPushMessage = (callback: OnPushMessageCallback) => void;
579
+ export type OffPushMessage = (callback: OnPushMessageCallback) => void;
580
+
581
+
582
+ export type GetChannelManager = () => ChannelManager;
583
+ export type SetPushChannelOptions = {
584
+ /**
585
+ * 添加的声音文件,注意raw目录下必须要有 ,不传此字段将使用默认铃音。
586
+ * @defaultValue null
587
+ */
588
+ soundName?: string | null,
589
+ /**
590
+ * 通知渠道id
591
+ */
592
+ channelId: string,
593
+ /**
594
+ * 通知渠道描述
595
+ */
596
+ channelDesc: string,
597
+ /**
598
+ * 呼吸灯闪烁
599
+ * @defaultValue false
600
+ */
601
+ enableLights?: boolean | null,
602
+ /**
603
+ * 震动
604
+ * @defaultValue false
605
+ */
606
+ enableVibration?: boolean | null,
607
+ /**
608
+ * 通知的重要性级别,可选范围IMPORTANCE_LOW:2、IMPORTANCE_DEFAULT:3、IMPORTANCE_HIGH:4 。
609
+ * @defaultValue 3
610
+ */
611
+ importance?: number | null,
612
+ /**
613
+ * 锁屏可见性,可选范围VISIBILITY_PRIVATE:0、VISIBILITY_PUBLIC:1、VISIBILITY_SECRET:-1、VISIBILITY_NO_OVERRIDE:-1000。
614
+ * @defaultValue -1000
615
+ */
616
+ lockscreenVisibility?: number | null
617
+ }
618
+
619
+ export interface ChannelManager {
620
+ /**
621
+ * 设置推送渠道
622
+ *
623
+ * @uniPlatform {
624
+ * "app": {
625
+ * "android": {
626
+ * "osVer": "4.4",
627
+ * "uniVer": "√",
628
+ * "unixVer": "3.98"
629
+ * },
630
+ * "ios": {
631
+ * "osVer": "x",
632
+ * "uniVer": "x",
633
+ * "unixVer": "x"
634
+ * }
635
+ * },
636
+ * "web": {
637
+ * "uniVer": "x",
638
+ * "unixVer": "x"
639
+ * }
640
+ * }
641
+ */
642
+ setPushChannel(options: SetPushChannelOptions): void;
643
+ /**
644
+ * 获取当前应用注册的所有的通知渠道。
645
+ *
646
+ * @uniPlatform {
647
+ * "app": {
648
+ * "android": {
649
+ * "osVer": "4.4",
650
+ * "uniVer": "√",
651
+ * "unixVer": "3.98"
652
+ * },
653
+ * "ios": {
654
+ * "osVer": "x",
655
+ * "uniVer": "x",
656
+ * "unixVer": "x"
657
+ * }
658
+ * },
659
+ * "web": {
660
+ * "uniVer": "x",
661
+ * "unixVer": "x"
662
+ * }
663
+ * }
664
+ */
665
+ getAllChannels(): Array<string>;
666
+ }
667
+
668
+ export type PushChannelManager = ChannelManager
669
+
670
+
671
+ export type CreatePushMessage = (options: CreatePushMessageOptions) => void;
672
+ export type CreatePushMessageSuccess = {};
673
+ export type CreatePushMessageSuccessCallback = (result: CreatePushMessageSuccess) => void;
674
+ export type CreatePushMessageFail = UniError;
675
+ export type CreatePushMessageFailCallback = (result: CreatePushMessageFail) => void;
676
+ export type CreatePushMessageComplete = any;
677
+ export type CreatePushMessageCompleteCallback = (result: CreatePushMessageComplete) => void;
678
+ export type CreatePushMessageOptions = {
679
+ /**
680
+ * 是否覆盖上一次提示的消息
681
+ * @type boolean
682
+ * @defaultValue false
683
+ * @uniPlatform {
684
+ * "app": {
685
+ * "android": {
686
+ * "osVer": "4.4",
687
+ * "uniVer": "√",
688
+ * "unixVer": "3.98"
689
+ * },
690
+ * "ios": {
691
+ * "osVer": "12.0",
692
+ * "uniVer": "√",
693
+ * "unixVer": "4.18"
694
+ * }
695
+ * },
696
+ * "web": {
697
+ * "uniVer": "x",
698
+ * "unixVer": "x"
699
+ * }
700
+ * }
701
+ */
702
+ cover?: boolean | null,
703
+ /**
704
+ * 提示消息延迟显示的时间,单位为s
705
+ * @defaultValue 0
706
+ * @uniPlatform {
707
+ * "app": {
708
+ * "android": {
709
+ * "osVer": "4.4",
710
+ * "uniVer": "√",
711
+ * "unixVer": "3.98"
712
+ * },
713
+ * "ios": {
714
+ * "osVer": "12.0",
715
+ * "uniVer": "√",
716
+ * "unixVer": "4.18"
717
+ * }
718
+ * },
719
+ * "web": {
720
+ * "uniVer": "x",
721
+ * "unixVer": "x"
722
+ * }
723
+ * }
724
+ */
725
+ delay?: number | null,
726
+ /**
727
+ * 推送消息的图标
728
+ * @defaultValue null
729
+ * @uniPlatform {
730
+ * "app": {
731
+ * "android": {
732
+ * "osVer": "4.4",
733
+ * "uniVer": "√",
734
+ * "unixVer": "3.98"
735
+ * },
736
+ * "ios": {
737
+ * "osVer": "12.0",
738
+ * "uniVer": "x",
739
+ * "unixVer": "x"
740
+ * }
741
+ * },
742
+ * "web": {
743
+ * "uniVer": "x",
744
+ * "unixVer": "x"
745
+ * }
746
+ * }
747
+ */
748
+ icon?: string | null,
749
+ /**
750
+ * 推送消息的提示音
751
+ * - system: 使用系统通知提示音(默认值)
752
+ * - none: 不使用提示音
753
+ * @type 'system' | 'none'
754
+ * @defaultValue "system"
755
+ * @uniPlatform {
756
+ * "app": {
757
+ * "android": {
758
+ * "osVer": "4.4",
759
+ * "uniVer": "√",
760
+ * "unixVer": "3.98"
761
+ * },
762
+ * "ios": {
763
+ * "osVer": "12.0",
764
+ * "uniVer": "√",
765
+ * "unixVer": "4.18"
766
+ * }
767
+ * },
768
+ * "web": {
769
+ * "uniVer": "x",
770
+ * "unixVer": "x"
771
+ * }
772
+ * }
773
+ */
774
+ sound?: string | null,
775
+ /**
776
+ * 推送消息的标题
777
+ * @defaultValue App的名称
778
+ * @uniPlatform {
779
+ * "app": {
780
+ * "android": {
781
+ * "osVer": "4.4",
782
+ * "uniVer": "√",
783
+ * "unixVer": "3.98"
784
+ * },
785
+ * "ios": {
786
+ * "osVer": "12.0",
787
+ * "uniVer": "√",
788
+ * "unixVer": "4.18"
789
+ * }
790
+ * },
791
+ * "web": {
792
+ * "uniVer": "x",
793
+ * "unixVer": "x"
794
+ * }
795
+ * }
796
+ */
797
+ title?: string | null,
798
+ /**
799
+ * 消息显示的内容,在系统通知中心中显示的文本内容。鸿蒙系统中,此字段为必填字段。
800
+ *
801
+ * @uniPlatform {
802
+ * "app": {
803
+ * "android": {
804
+ * "osVer": "4.4",
805
+ * "uniVer": "√",
806
+ * "unixVer": "3.98"
807
+ * },
808
+ * "ios": {
809
+ * "osVer": "12.0",
810
+ * "uniVer": "√",
811
+ * "unixVer": "4.18"
812
+ * }
813
+ * },
814
+ * "web": {
815
+ * "uniVer": "x",
816
+ * "unixVer": "x"
817
+ * }
818
+ * }
819
+ */
820
+ content: string,
821
+ /**
822
+ * 消息承载的数据,可根据业务逻辑自定义数据格式,在点击通知消息时`onPushMessage`回调中会返回此字段的数据。
823
+ * @defaultValue null
824
+ * @uniPlatform {
825
+ * "app": {
826
+ * "android": {
827
+ * "osVer": "4.4",
828
+ * "uniVer": "√",
829
+ * "unixVer": "3.98"
830
+ * },
831
+ * "ios": {
832
+ * "osVer": "12.0",
833
+ * "uniVer": "√",
834
+ * "unixVer": "4.18"
835
+ * }
836
+ * },
837
+ * "web": {
838
+ * "uniVer": "x",
839
+ * "unixVer": "x"
840
+ * }
841
+ * }
842
+ */
843
+ payload?: any | null,
844
+ /**
845
+ * 消息上显示的提示时间,需要传入时间戳。
846
+ * @defaultValue 当前时间
847
+ *
848
+ * @uniPlatform {
849
+ * "app": {
850
+ * "android": {
851
+ * "osVer": "4.4",
852
+ * "uniVer": "√",
853
+ * "unixVer": "3.98"
854
+ * },
855
+ * "ios": {
856
+ * "osVer": "x",
857
+ * "uniVer": "x",
858
+ * "unixVer": "x"
859
+ * }
860
+ * },
861
+ * "web": {
862
+ * "uniVer": "x",
863
+ * "unixVer": "x"
864
+ * }
865
+ * }
866
+ */
867
+ when?: number | null,
868
+ /**
869
+ * 渠道id,Android特有字段,[通知渠道介绍](https://developer.android.com/develop/ui/views/notifications/channels?hl=zh-cn),
870
+ * 创建通知渠道请使用`getPushChannelManager`获取PushChannelManager对象,调用`setPushChannel`方法配置渠道。
871
+ * @defaultValue "DcloudChannelID"
872
+ * @uniPlatform {
873
+ * "app": {
874
+ * "android": {
875
+ * "osVer": "4.4",
876
+ * "uniVer": "√",
877
+ * "unixVer": "3.98"
878
+ * },
879
+ * "ios": {
880
+ * "osVer": "x",
881
+ * "uniVer": "x",
882
+ * "unixVer": "x"
883
+ * }
884
+ * },
885
+ * "web": {
886
+ * "uniVer": "x",
887
+ * "unixVer": "x"
888
+ * }
889
+ * }
890
+ */
891
+ channelId?: string | null,
892
+ /**
893
+ * 通知类别,Android特有字段,[通知渠道介绍](https://developer.android.com/develop/ui/views/notifications/channels?hl=zh-cn),
894
+ * 标识通知的类别,应用场景为对于离线推送厂商配置的支持,比如[华为消息分类](https://developer.huawei.com/consumer/cn/doc/HMSCore-Guides/message-classification-0000001149358835#section5101818813)
895
+ * @defaultValue null
896
+ * @uniPlatform {
897
+ * "app": {
898
+ * "android": {
899
+ * "osVer": "4.4",
900
+ * "uniVer": "√",
901
+ * "unixVer": "3.98"
902
+ * },
903
+ * "ios": {
904
+ * "osVer": "x",
905
+ * "uniVer": "x",
906
+ * "unixVer": "x"
907
+ * }
908
+ * },
909
+ * "web": {
910
+ * "uniVer": "x",
911
+ * "unixVer": "x"
912
+ * }
913
+ * }
914
+ */
915
+ category?: string | null,
916
+ /**
917
+ * 接口调用成功的回调函数
918
+ * @defaultValue null
919
+ */
920
+ success?: CreatePushMessageSuccessCallback | null,
921
+ /**
922
+ * 接口调用失败的回调函数
923
+ * @defaultValue null
924
+ */
925
+ fail?: CreatePushMessageFailCallback | null,
926
+ /**
927
+ * 接口调用结束的回调函数(调用成功、失败都会执行)
928
+ * @defaultValue null
929
+ */
930
+ complete?: CreatePushMessageCompleteCallback | null
931
+ };
932
+
933
+
934
+ export type BadgeOptions = {
935
+ /**
936
+ * 消息的标题
937
+ * @defaultValue 应用的名称
938
+ * @uniPlatform {
939
+ * "app": {
940
+ * "android": {
941
+ * "osVer": "4.4",
942
+ * "uniVer": "x",
943
+ * "unixVer": "4.25"
944
+ * },
945
+ * "ios": {
946
+ * "osVer": "12.0",
947
+ * "uniVer": "x",
948
+ * "unixVer": "4.25"
949
+ * }
950
+ * },
951
+ * "web": {
952
+ * "uniVer": "x",
953
+ * "unixVer": "x"
954
+ * }
955
+ * }
956
+ */
957
+ title?: string | null,
958
+ /**
959
+ * 消息的内容
960
+ * @defaultValue '您有x条未读消息',其中x为设置的角标数字值。
961
+ * @uniPlatform {
962
+ * "app": {
963
+ * "android": {
964
+ * "osVer": "4.4",
965
+ * "uniVer": "x",
966
+ * "unixVer": "4.25"
967
+ * },
968
+ * "ios": {
969
+ * "osVer": "12.0",
970
+ * "uniVer": "x",
971
+ * "unixVer": "4.25"
972
+ * }
973
+ * },
974
+ * "web": {
975
+ * "uniVer": "x",
976
+ * "unixVer": "x"
977
+ * }
978
+ * }
979
+ */
980
+ content?: string | null
981
+ }