@tarojs/taro 3.4.1 → 3.4.2

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 (88) hide show
  1. package/package.json +5 -5
  2. package/types/api/ai/face.d.ts +133 -0
  3. package/types/api/ai/visionkit.d.ts +303 -0
  4. package/types/api/base/crypto.d.ts +90 -0
  5. package/types/api/base/debug.d.ts +152 -13
  6. package/types/api/base/env.d.ts +2 -1
  7. package/types/api/base/index.d.ts +10 -2
  8. package/types/api/base/performance.d.ts +195 -0
  9. package/types/api/base/system.d.ts +539 -101
  10. package/types/api/base/update.d.ts +59 -7
  11. package/types/api/base/weapp/app-event.d.ts +46 -23
  12. package/types/api/base/weapp/life-cycle.d.ts +141 -1
  13. package/types/api/canvas/index.d.ts +150 -136
  14. package/types/api/cloud/index.d.ts +2 -2
  15. package/types/api/device/accelerometer.d.ts +3 -3
  16. package/types/api/device/accessibility.d.ts +26 -0
  17. package/types/api/device/battery.d.ts +2 -2
  18. package/types/api/device/{ble.d.ts → bluetooth-ble.d.ts} +228 -62
  19. package/types/api/device/bluetooth-peripheral.d.ts +430 -0
  20. package/types/api/device/bluetooth.d.ts +67 -2
  21. package/types/api/device/calendar.d.ts +88 -0
  22. package/types/api/device/contact.d.ts +74 -50
  23. package/types/api/device/gyroscope.d.ts +5 -5
  24. package/types/api/device/iBeacon.d.ts +33 -19
  25. package/types/api/{ui → device}/keyboard.d.ts +0 -0
  26. package/types/api/device/{performance.d.ts → memory.d.ts} +4 -4
  27. package/types/api/device/motion.d.ts +3 -3
  28. package/types/api/device/network.d.ts +53 -12
  29. package/types/api/device/nfc.d.ts +1089 -13
  30. package/types/api/device/scan.d.ts +1 -1
  31. package/types/api/device/screen.d.ts +40 -12
  32. package/types/api/device/wifi.d.ts +41 -6
  33. package/types/api/files/index.d.ts +371 -184
  34. package/types/api/location/index.d.ts +116 -55
  35. package/types/api/media/audio.d.ts +629 -38
  36. package/types/api/media/background-audio.d.ts +8 -8
  37. package/types/api/media/camera.d.ts +38 -19
  38. package/types/api/media/editor.d.ts +22 -2
  39. package/types/api/media/image.d.ts +61 -32
  40. package/types/api/media/live.d.ts +66 -6
  41. package/types/api/media/map.d.ts +469 -49
  42. package/types/api/media/media-recorder.d.ts +92 -0
  43. package/types/api/media/recorder.d.ts +20 -20
  44. package/types/api/media/video-decoder.d.ts +117 -0
  45. package/types/api/media/video-processing.d.ts +11 -7
  46. package/types/api/media/video.d.ts +45 -16
  47. package/types/api/media/voip.d.ts +290 -0
  48. package/types/api/{open-api/navigate.d.ts → navigate/index.d.ts} +63 -25
  49. package/types/api/network/download.d.ts +39 -16
  50. package/types/api/network/request.d.ts +125 -37
  51. package/types/api/network/tcp.d.ts +181 -0
  52. package/types/api/network/udp.d.ts +154 -83
  53. package/types/api/network/upload.d.ts +41 -25
  54. package/types/api/network/websocket.d.ts +16 -15
  55. package/types/api/open-api/authorize.d.ts +41 -2
  56. package/types/api/open-api/channels.d.ts +178 -0
  57. package/types/api/open-api/facial.d.ts +3 -0
  58. package/types/api/open-api/favorites.d.ts +100 -0
  59. package/types/api/open-api/group.d.ts +59 -0
  60. package/types/api/open-api/invoice.d.ts +2 -2
  61. package/types/api/open-api/license-plate.d.ts +27 -0
  62. package/types/api/open-api/login.d.ts +21 -0
  63. package/types/api/open-api/redpackage.d.ts +24 -0
  64. package/types/api/open-api/settings.d.ts +76 -14
  65. package/types/api/open-api/soter.d.ts +2 -2
  66. package/types/api/open-api/subscribe-message.d.ts +88 -3
  67. package/types/api/open-api/user-info.d.ts +55 -18
  68. package/types/api/open-api/werun.d.ts +33 -6
  69. package/types/api/payment/index.d.ts +119 -0
  70. package/types/api/route/index.d.ts +13 -9
  71. package/types/api/share/index.d.ts +192 -9
  72. package/types/api/storage/index.d.ts +29 -83
  73. package/types/api/swan/index.d.ts +1 -1
  74. package/types/api/ui/animation.d.ts +84 -70
  75. package/types/api/ui/background.d.ts +4 -2
  76. package/types/api/ui/custom-component.d.ts +1 -1
  77. package/types/api/ui/fonts.d.ts +27 -31
  78. package/types/api/ui/navigation-bar.d.ts +1 -0
  79. package/types/api/ui/scroll.d.ts +73 -7
  80. package/types/api/ui/sticky.d.ts +4 -4
  81. package/types/api/ui/tab-bar.d.ts +7 -7
  82. package/types/api/ui/window.d.ts +22 -2
  83. package/types/api/worker/index.d.ts +9 -1
  84. package/types/api/wxml/index.d.ts +111 -107
  85. package/types/compile.d.ts +5 -0
  86. package/types/global.d.ts +142 -111
  87. package/types/taro.api.d.ts +79 -62
  88. package/types/api/open-api/payment.d.ts +0 -61
@@ -6,89 +6,106 @@
6
6
  * thanks for the great work by @qiu8310 👍👍👍
7
7
  *
8
8
  */
9
- /// <reference path="api/ad/index.d.ts" />
9
+ /// <reference path="api/framework/index.d.ts" />
10
10
  /// <reference path="api/base/index.d.ts" />
11
- /// <reference path="api/base/debug.d.ts" />
12
11
  /// <reference path="api/base/system.d.ts" />
13
12
  /// <reference path="api/base/update.d.ts" />
14
13
  /// <reference path="api/base/weapp/life-cycle.d.ts" />
15
14
  /// <reference path="api/base/weapp/app-event.d.ts" />
15
+ /// <reference path="api/base/debug.d.ts" />
16
+ /// <reference path="api/base/performance.d.ts" />
17
+ /// <reference path="api/base/crypto.d.ts" />
16
18
  /// <reference path="api/base/env.d.ts" />
17
- /// <reference path="api/canvas/index.d.ts" />
18
- /// <reference path="api/cloud/index.d.ts" />
19
+ /// <reference path="api/route/index.d.ts" />
20
+ /// <reference path="api/navigate/index.d.ts" />
21
+ /// <reference path="api/share/index.d.ts" />
22
+ /// <reference path="api/ui/interaction.d.ts" />
23
+ /// <reference path="api/ui/navigation-bar.d.ts" />
24
+ /// <reference path="api/ui/background.d.ts" />
25
+ /// <reference path="api/ui/tab-bar.d.ts" />
26
+ /// <reference path="api/ui/fonts.d.ts" />
27
+ /// <reference path="api/ui/pull-down-refresh.d.ts" />
28
+ /// <reference path="api/ui/scroll.d.ts" />
29
+ /// <reference path="api/ui/animation.d.ts" />
30
+ /// <reference path="api/ui/sticky.d.ts" />
31
+ /// <reference path="api/ui/custom-component.d.ts" />
32
+ /// <reference path="api/ui/menu.d.ts" />
33
+ /// <reference path="api/ui/window.d.ts" />
34
+ /// <reference path="api/network/request.d.ts" />
35
+ /// <reference path="api/network/download.d.ts" />
36
+ /// <reference path="api/network/upload.d.ts" />
37
+ /// <reference path="api/network/websocket.d.ts" />
38
+ /// <reference path="api/network/mdns.d.ts" />
39
+ /// <reference path="api/network/tcp.d.ts" />
40
+ /// <reference path="api/network/udp.d.ts" />
41
+ /// <reference path="api/payment/index.d.ts" />
42
+ /// <reference path="api/storage/index.d.ts" />
43
+ /// <reference path="api/storage/background-fetch.d.ts" />
19
44
  /// <reference path="api/data-analysis/index.d.ts" />
20
- /// <reference path="api/device/accelerometer.d.ts" />
21
- /// <reference path="api/device/battery.d.ts" />
22
- /// <reference path="api/device/ble.d.ts" />
23
- /// <reference path="api/device/bluetooth.d.ts" />
24
- /// <reference path="api/device/clipboard.d.ts" />
25
- /// <reference path="api/device/compass.d.ts" />
26
- /// <reference path="api/device/contact.d.ts" />
27
- /// <reference path="api/device/gyroscope.d.ts" />
28
- /// <reference path="api/device/iBeacon.d.ts" />
29
- /// <reference path="api/device/motion.d.ts" />
30
- /// <reference path="api/device/network.d.ts" />
31
- /// <reference path="api/device/nfc.d.ts" />
32
- /// <reference path="api/device/performance.d.ts" />
33
- /// <reference path="api/device/phone.d.ts" />
34
- /// <reference path="api/device/scan.d.ts" />
35
- /// <reference path="api/device/screen.d.ts" />
36
- /// <reference path="api/device/vibrate.d.ts" />
37
- /// <reference path="api/device/wifi.d.ts" />
38
- /// <reference path="api/ext/index.d.ts" />
39
- /// <reference path="api/files/index.d.ts" />
40
- /// <reference path="api/framework/index.d.ts" />
41
- /// <reference path="api/location/index.d.ts" />
45
+ /// <reference path="api/canvas/index.d.ts" />
46
+ /// <reference path="api/media/map.d.ts" />
47
+ /// <reference path="api/media/image.d.ts" />
48
+ /// <reference path="api/media/video.d.ts" />
42
49
  /// <reference path="api/media/audio.d.ts" />
43
50
  /// <reference path="api/media/background-audio.d.ts" />
44
- /// <reference path="api/media/camera.d.ts" />
45
- /// <reference path="api/media/editor.d.ts" />
46
- /// <reference path="api/media/image.d.ts" />
47
51
  /// <reference path="api/media/live.d.ts" />
48
- /// <reference path="api/media/map.d.ts" />
49
52
  /// <reference path="api/media/recorder.d.ts" />
50
- /// <reference path="api/media/video.d.ts" />
53
+ /// <reference path="api/media/camera.d.ts" />
54
+ /// <reference path="api/media/editor.d.ts" />
51
55
  /// <reference path="api/media/video-processing.d.ts" />
52
- /// <reference path="api/network/download.d.ts" />
53
- /// <reference path="api/network/mdns.d.ts" />
54
- /// <reference path="api/network/request.d.ts" />
55
- /// <reference path="api/network/udp.d.ts" />
56
- /// <reference path="api/network/upload.d.ts" />
57
- /// <reference path="api/network/websocket.d.ts" />
56
+ /// <reference path="api/media/voip.d.ts" />
57
+ /// <reference path="api/media/media-recorder.d.ts" />
58
+ /// <reference path="api/media/video-decoder.d.ts" />
59
+ /// <reference path="api/location/index.d.ts" />
60
+ /// <reference path="api/files/index.d.ts" />
61
+ /// <reference path="api/open-api/login.d.ts" />
58
62
  /// <reference path="api/open-api/account.d.ts" />
59
- /// <reference path="api/open-api/address.d.ts" />
63
+ /// <reference path="api/open-api/user-info.d.ts" />
60
64
  /// <reference path="api/open-api/authorize.d.ts" />
65
+ /// <reference path="api/open-api/settings.d.ts" />
66
+ /// <reference path="api/open-api/address.d.ts" />
61
67
  /// <reference path="api/open-api/card.d.ts" />
62
- /// <reference path="api/open-api/facial.d.ts" />
63
68
  /// <reference path="api/open-api/invoice.d.ts" />
64
- /// <reference path="api/open-api/login.d.ts" />
65
- /// <reference path="api/open-api/navigate.d.ts" />
66
- /// <reference path="api/open-api/payment.d.ts" />
67
- /// <reference path="api/open-api/settings.d.ts" />
68
69
  /// <reference path="api/open-api/soter.d.ts" />
69
- /// <reference path="api/open-api/subscribe-message.d.ts" />
70
- /// <reference path="api/open-api/user-info.d.ts" />
71
70
  /// <reference path="api/open-api/werun.d.ts" />
71
+ /// <reference path="api/open-api/subscribe-message.d.ts" />
72
+ /// <reference path="api/open-api/redpackage.d.ts" />
73
+ /// <reference path="api/open-api/favorites.d.ts" />
74
+ /// <reference path="api/open-api/license-plate.d.ts" />
75
+ /// <reference path="api/open-api/channels.d.ts" />
76
+ /// <reference path="api/open-api/group.d.ts" />
72
77
  /// <reference path="api/open-api/customer-service.d.ts" />
73
- /// <reference path="api/route/index.d.ts" />
74
- /// <reference path="api/share/index.d.ts" />
75
- /// <reference path="api/storage/background-fetch.d.ts" />
76
- /// <reference path="api/storage/index.d.ts" />
77
- /// <reference path="api/ui/animation.d.ts" />
78
- /// <reference path="api/ui/background.d.ts" />
79
- /// <reference path="api/ui/custom-component.d.ts" />
80
- /// <reference path="api/ui/fonts.d.ts" />
81
- /// <reference path="api/ui/keyboard.d.ts" />
82
- /// <reference path="api/ui/menu.d.ts" />
83
- /// <reference path="api/ui/navigation-bar.d.ts" />
84
- /// <reference path="api/ui/pull-down-refresh.d.ts" />
85
- /// <reference path="api/ui/scroll.d.ts" />
86
- /// <reference path="api/ui/sticky.d.ts" />
87
- /// <reference path="api/ui/tab-bar.d.ts" />
88
- /// <reference path="api/ui/window.d.ts" />
89
- /// <reference path="api/ui/interaction.d.ts" />
78
+ /// <reference path="api/device/bluetooth.d.ts" />
79
+ /// <reference path="api/device/bluetooth-ble.d.ts" />
80
+ /// <reference path="api/device/bluetooth-peripheral.d.ts" />
81
+ /// <reference path="api/device/iBeacon.d.ts" />
82
+ /// <reference path="api/device/nfc.d.ts" />
83
+ /// <reference path="api/device/wifi.d.ts" />
84
+ /// <reference path="api/device/calendar.d.ts" />
85
+ /// <reference path="api/device/contact.d.ts" />
86
+ /// <reference path="api/device/accessibility.d.ts" />
87
+ /// <reference path="api/device/battery.d.ts" />
88
+ /// <reference path="api/device/clipboard.d.ts" />
89
+ /// <reference path="api/device/network.d.ts" />
90
+ /// <reference path="api/device/screen.d.ts" />
91
+ /// <reference path="api/device/keyboard.d.ts" />
92
+ /// <reference path="api/device/phone.d.ts" />
93
+ /// <reference path="api/device/accelerometer.d.ts" />
94
+ /// <reference path="api/device/compass.d.ts" />
95
+ /// <reference path="api/device/motion.d.ts" />
96
+ /// <reference path="api/device/gyroscope.d.ts" />
97
+ /// <reference path="api/device/memory.d.ts" />
98
+ /// <reference path="api/device/scan.d.ts" />
99
+ /// <reference path="api/device/vibrate.d.ts" />
100
+ /// <reference path="api/ai/visionkit.d.ts" />
101
+ /// <reference path="api/ai/face.d.ts" />
90
102
  /// <reference path="api/worker/index.d.ts" />
91
103
  /// <reference path="api/wxml/index.d.ts" />
104
+ /// <reference path="api/ext/index.d.ts" />
105
+ /// <reference path="api/ad/index.d.ts" />
106
+
107
+ /// <reference path="api/cloud/index.d.ts" />
108
+ /// <reference path="api/open-api/facial.d.ts" />
92
109
 
93
110
  /// <reference path="api/alipay/index.d.ts" />
94
111
  /// <reference path="api/swan/index.d.ts" />
@@ -1,61 +0,0 @@
1
- import Taro from '../../index'
2
-
3
- declare module '../../index' {
4
- namespace requestPayment {
5
- interface Option {
6
- /** 随机字符串,长度为32个字符以下 */
7
- nonceStr: string
8
- /** 统一下单接口返回的 prepay_id 参数值,提交格式如:prepay_id=*** */
9
- package: string
10
- /** 签名,具体签名方案参见 [小程序支付接口文档](https://pay.weixin.qq.com/wiki/doc/api/wxa/wxa_api.php?chapter=7_7&index=3) */
11
- paySign: string
12
- /** 时间戳,从 1970 年 1 月 1 日 00:00:00 至今的秒数,即当前的时间 */
13
- timeStamp: string
14
- /** 接口调用结束的回调函数(调用成功、失败都会执行) */
15
- complete?: (res: TaroGeneral.CallbackResult) => void
16
- /** 接口调用失败的回调函数 */
17
- fail?: (res: TaroGeneral.CallbackResult) => void
18
- /** 签名算法 */
19
- signType?: keyof signType
20
- /** 接口调用成功的回调函数 */
21
- success?: (res: TaroGeneral.CallbackResult) => void
22
- }
23
-
24
- interface signType {
25
- /** MD5 */
26
- MD5
27
- /** HMAC-SHA256 */
28
- 'HMAC-SHA256'
29
- }
30
- }
31
-
32
- interface TaroStatic {
33
- /** 发起微信支付。了解更多信息,请查看[微信支付接口文档](https://pay.weixin.qq.com/wiki/doc/api/wxa/wxa_api.php?chapter=7_3&index=1)
34
- * @supported weapp, h5
35
- * @example
36
- * ```tsx
37
- * Taro.requestPayment({
38
- * timeStamp: '',
39
- * nonceStr: '',
40
- * package: '',
41
- * signType: 'MD5',
42
- * paySign: '',
43
- * success: function (res) { },
44
- * fail: function (res) { }
45
- * })
46
- * ```
47
- * @see https://developers.weixin.qq.com/miniprogram/dev/api/open-api/payment/wx.requestPayment.html
48
- */
49
- requestPayment(option: requestPayment.Option): Promise<TaroGeneral.CallbackResult>
50
-
51
- /** 支付各个安全场景验证人脸
52
- * @supported weapp
53
- * @example
54
- * ```tsx
55
- * Taro.faceVerifyForPay(params).then(...)
56
- * ```
57
- * @see https://developers.weixin.qq.com/miniprogram/dev/api/open-api/payment/wx.faceVerifyForPay.html
58
- */
59
- faceVerifyForPay(option: any): Promise<any>
60
- }
61
- }