@dcloudio/uni-app-x 0.7.14 → 0.7.16

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 (175) hide show
  1. package/options.d.ts +1 -1
  2. package/package.json +1 -1
  3. package/types/native/CSSStyleDeclaration.d.ts +0 -72
  4. package/types/native/CanvasRenderingContext2D.d.ts +1943 -0
  5. package/types/native/DOMRect.d.ts +0 -180
  6. package/types/native/DrawableContext.d.ts +161 -628
  7. package/types/native/IUniElement.d.ts +513 -1868
  8. package/types/native/IUniObjectElement.d.ts +124 -0
  9. package/types/native/Path2D.d.ts +241 -0
  10. package/types/native/SnapshotOptions.d.ts +1 -0
  11. package/types/native/UniApp.d.ts +110 -0
  12. package/types/native/UniCanvasElement.d.ts +9 -0
  13. package/types/native/UniNativePage.d.ts +48 -1
  14. package/types/native/UniPageManager.d.ts +4 -1
  15. package/types/native/UniProvider.d.ts +1 -0
  16. package/types/native/UniResizeObserver.d.ts +9 -99
  17. package/types/native/UniScrollEvent.d.ts +1 -1
  18. package/types/native/UniSwiperAnimationFinishEvent.d.ts +1 -1
  19. package/types/native/UniSwiperChangeEvent.d.ts +1 -1
  20. package/types/native/UniVideoElement.d.ts +5 -0
  21. package/types/native/global.d.ts +73 -15
  22. package/types/native/index.d.ts +4 -0
  23. package/types/shim-uts-basic.d.ts +4495 -0
  24. package/types/uni/env/index.d.ts +39 -0
  25. package/types/uni/uts-plugin-api/global.d.ts +20 -1
  26. package/types/uni/uts-plugin-api/index.d.ts +20 -1
  27. package/types/uni/uts-plugin-api/lib/uni-addPhoneContact/utssdk/global.d.ts +26 -0
  28. package/types/uni/uts-plugin-api/lib/uni-addPhoneContact/utssdk/index.d.ts +12 -0
  29. package/types/uni/uts-plugin-api/lib/uni-addPhoneContact/utssdk/interface.d.ts +231 -0
  30. package/types/uni/uts-plugin-api/lib/uni-arrayBufferToBase64/utssdk/global.d.ts +10 -0
  31. package/types/uni/uts-plugin-api/lib/uni-arrayBufferToBase64/utssdk/index.d.ts +4 -0
  32. package/types/uni/uts-plugin-api/lib/uni-arrayBufferToBase64/utssdk/interface.d.ts +77 -0
  33. package/types/uni/uts-plugin-api/lib/uni-base64ToArrayBuffer/utssdk/global.d.ts +10 -0
  34. package/types/uni/uts-plugin-api/lib/uni-base64ToArrayBuffer/utssdk/index.d.ts +4 -0
  35. package/types/uni/uts-plugin-api/lib/uni-base64ToArrayBuffer/utssdk/interface.d.ts +77 -0
  36. package/types/uni/uts-plugin-api/lib/uni-cancelAnimationFrame/utssdk/global.d.ts +10 -0
  37. package/types/uni/uts-plugin-api/lib/uni-cancelAnimationFrame/utssdk/index.d.ts +4 -0
  38. package/types/uni/uts-plugin-api/lib/uni-cancelAnimationFrame/utssdk/interface.d.ts +24 -0
  39. package/types/uni/uts-plugin-api/lib/uni-canvas/utssdk/global.d.ts +20 -0
  40. package/types/uni/uts-plugin-api/lib/uni-canvas/utssdk/index.d.ts +9 -0
  41. package/types/uni/uts-plugin-api/lib/uni-canvas/utssdk/interface.d.ts +268 -0
  42. package/types/uni/uts-plugin-api/lib/uni-clipboard/utssdk/global.d.ts +40 -0
  43. package/types/uni/uts-plugin-api/lib/uni-clipboard/utssdk/index.d.ts +19 -0
  44. package/types/uni/uts-plugin-api/lib/uni-clipboard/utssdk/interface.d.ts +203 -0
  45. package/types/uni/uts-plugin-api/lib/uni-createIntersectionObserver/utssdk/global.d.ts +20 -0
  46. package/types/uni/uts-plugin-api/lib/uni-createIntersectionObserver/utssdk/index.d.ts +9 -0
  47. package/types/uni/uts-plugin-api/lib/uni-createIntersectionObserver/utssdk/interface.d.ts +152 -0
  48. package/types/uni/uts-plugin-api/lib/uni-createRequestPermissionListener/utssdk/interface.d.ts +20 -3
  49. package/types/uni/uts-plugin-api/lib/uni-createSelectorQuery/utssdk/interface.d.ts +24 -9
  50. package/types/uni/uts-plugin-api/lib/uni-createWebviewContext/utssdk/interface.d.ts +13 -6
  51. package/types/uni/uts-plugin-api/lib/uni-dialogPage/utssdk/global.d.ts +28 -0
  52. package/types/uni/uts-plugin-api/lib/uni-dialogPage/utssdk/index.d.ts +13 -0
  53. package/types/uni/uts-plugin-api/lib/uni-dialogPage/utssdk/interface.d.ts +1335 -0
  54. package/types/uni/uts-plugin-api/lib/uni-event/utssdk/interface.d.ts +28 -0
  55. package/types/uni/uts-plugin-api/lib/uni-exit/utssdk/interface.d.ts +6 -1
  56. package/types/uni/uts-plugin-api/lib/uni-file/utssdk/global.d.ts +80 -0
  57. package/types/uni/uts-plugin-api/lib/uni-file/utssdk/index.d.ts +39 -0
  58. package/types/uni/uts-plugin-api/lib/uni-file/utssdk/interface.d.ts +174 -0
  59. package/types/uni/uts-plugin-api/lib/uni-fileSystemManager/utssdk/interface.d.ts +8 -1
  60. package/types/uni/uts-plugin-api/lib/uni-getAccessibilityInfo/utssdk/interface.d.ts +20 -17
  61. package/types/uni/uts-plugin-api/lib/uni-getAppAuthorizeSetting/utssdk/interface.d.ts +28 -20
  62. package/types/uni/uts-plugin-api/lib/uni-getAppBaseInfo/utssdk/interface.d.ts +201 -64
  63. package/types/uni/uts-plugin-api/lib/uni-getDeviceInfo/utssdk/interface.d.ts +180 -59
  64. package/types/uni/uts-plugin-api/lib/uni-getElementById/utssdk/interface.d.ts +10 -2
  65. package/types/uni/uts-plugin-api/lib/uni-getEnterOptionsSync/utssdk/global.d.ts +12 -0
  66. package/types/uni/uts-plugin-api/lib/uni-getEnterOptionsSync/utssdk/index.d.ts +5 -0
  67. package/types/uni/uts-plugin-api/lib/uni-getEnterOptionsSync/utssdk/interface.d.ts +47 -0
  68. package/types/uni/uts-plugin-api/lib/uni-getLaunchOptionsSync/utssdk/interface.d.ts +10 -1
  69. package/types/uni/uts-plugin-api/lib/uni-getLocation/utssdk/global.d.ts +24 -0
  70. package/types/uni/uts-plugin-api/lib/uni-getLocation/utssdk/index.d.ts +11 -0
  71. package/types/uni/uts-plugin-api/lib/uni-getLocation/utssdk/interface.d.ts +564 -0
  72. package/types/uni/uts-plugin-api/lib/uni-getLocation-system/utssdk/global.d.ts +2 -14
  73. package/types/uni/uts-plugin-api/lib/uni-getLocation-system/utssdk/index.d.ts +1 -6
  74. package/types/uni/uts-plugin-api/lib/uni-getLocation-system/utssdk/interface.d.ts +1 -151
  75. package/types/uni/uts-plugin-api/lib/uni-getLocation-tencent/utssdk/global.d.ts +8 -0
  76. package/types/uni/uts-plugin-api/lib/uni-getLocation-tencent/utssdk/index.d.ts +4 -0
  77. package/types/uni/uts-plugin-api/lib/uni-getLocation-tencent/utssdk/interface.d.ts +1 -0
  78. package/types/uni/uts-plugin-api/lib/uni-getNetworkType/utssdk/global.d.ts +8 -0
  79. package/types/uni/uts-plugin-api/lib/uni-getNetworkType/utssdk/index.d.ts +4 -0
  80. package/types/uni/uts-plugin-api/lib/uni-getNetworkType/utssdk/interface.d.ts +114 -34
  81. package/types/uni/uts-plugin-api/lib/uni-getPerformance/utssdk/interface.d.ts +7 -1
  82. package/types/uni/uts-plugin-api/lib/uni-getProvider/utssdk/global.d.ts +8 -0
  83. package/types/uni/uts-plugin-api/lib/uni-getProvider/utssdk/index.d.ts +4 -0
  84. package/types/uni/uts-plugin-api/lib/uni-getProvider/utssdk/interface.d.ts +304 -27
  85. package/types/uni/uts-plugin-api/lib/uni-getSystemInfo/utssdk/interface.d.ts +500 -149
  86. package/types/uni/uts-plugin-api/lib/uni-getSystemSetting/utssdk/interface.d.ts +123 -112
  87. package/types/uni/uts-plugin-api/lib/uni-installApk/utssdk/interface.d.ts +9 -6
  88. package/types/uni/uts-plugin-api/lib/uni-interceptor/utssdk/interface.d.ts +18 -2
  89. package/types/uni/uts-plugin-api/lib/uni-keyboard/utssdk/global.d.ts +22 -0
  90. package/types/uni/uts-plugin-api/lib/uni-keyboard/utssdk/index.d.ts +10 -0
  91. package/types/uni/uts-plugin-api/lib/uni-keyboard/utssdk/interface.d.ts +60 -0
  92. package/types/uni/uts-plugin-api/lib/uni-loadFontFace/utssdk/interface.d.ts +8 -1
  93. package/types/uni/{uts-plugin-extend → uts-plugin-api}/lib/uni-makePhoneCall/utssdk/global.d.ts +9 -6
  94. package/types/uni/{uts-plugin-extend → uts-plugin-api}/lib/uni-makePhoneCall/utssdk/index.d.ts +4 -2
  95. package/types/uni/{uts-plugin-extend → uts-plugin-api}/lib/uni-makePhoneCall/utssdk/interface.d.ts +40 -61
  96. package/types/uni/uts-plugin-api/lib/uni-media/utssdk/global.d.ts +2 -0
  97. package/types/uni/uts-plugin-api/lib/uni-media/utssdk/index.d.ts +1 -0
  98. package/types/uni/uts-plugin-api/lib/uni-media/utssdk/interface.d.ts +327 -58
  99. package/types/uni/uts-plugin-api/lib/uni-navigationBar/utssdk/global.d.ts +24 -0
  100. package/types/uni/uts-plugin-api/lib/uni-navigationBar/utssdk/index.d.ts +12 -0
  101. package/types/uni/uts-plugin-api/lib/uni-navigationBar/utssdk/interface.d.ts +213 -5
  102. package/types/uni/uts-plugin-api/lib/uni-network/utssdk/interface.d.ts +280 -92
  103. package/types/uni/uts-plugin-api/lib/uni-openAppAuthorizeSetting/utssdk/interface.d.ts +20 -15
  104. package/types/uni/uts-plugin-api/lib/uni-openDocument/utssdk/global.d.ts +24 -0
  105. package/types/uni/uts-plugin-api/lib/uni-openDocument/utssdk/index.d.ts +11 -0
  106. package/types/uni/uts-plugin-api/lib/uni-openDocument/utssdk/interface.d.ts +70 -0
  107. package/types/uni/uts-plugin-api/lib/uni-pageScrollTo/utssdk/global.d.ts +2 -0
  108. package/types/uni/uts-plugin-api/lib/uni-pageScrollTo/utssdk/index.d.ts +1 -0
  109. package/types/uni/uts-plugin-api/lib/uni-pageScrollTo/utssdk/interface.d.ts +16 -6
  110. package/types/uni/uts-plugin-api/lib/uni-payment/utssdk/interface.d.ts +161 -11
  111. package/types/uni/uts-plugin-api/lib/uni-payment-alipay/utssdk/global.d.ts +8 -0
  112. package/types/uni/uts-plugin-api/lib/uni-payment-alipay/utssdk/index.d.ts +4 -0
  113. package/types/uni/uts-plugin-api/lib/uni-payment-alipay/utssdk/interface.d.ts +1 -0
  114. package/types/uni/uts-plugin-api/lib/uni-payment-wxpay/utssdk/global.d.ts +8 -0
  115. package/types/uni/uts-plugin-api/lib/uni-payment-wxpay/utssdk/index.d.ts +4 -0
  116. package/types/uni/uts-plugin-api/lib/uni-payment-wxpay/utssdk/interface.d.ts +3 -0
  117. package/types/uni/uts-plugin-api/lib/uni-prompt/utssdk/interface.d.ts +120 -42
  118. package/types/uni/uts-plugin-api/lib/uni-pullDownRefresh/utssdk/global.d.ts +2 -0
  119. package/types/uni/uts-plugin-api/lib/uni-pullDownRefresh/utssdk/index.d.ts +1 -0
  120. package/types/uni/uts-plugin-api/lib/uni-pullDownRefresh/utssdk/interface.d.ts +16 -1
  121. package/types/uni/uts-plugin-api/lib/uni-requestAnimationFrame/utssdk/global.d.ts +12 -0
  122. package/types/uni/uts-plugin-api/lib/uni-requestAnimationFrame/utssdk/index.d.ts +5 -0
  123. package/types/uni/uts-plugin-api/lib/uni-requestAnimationFrame/utssdk/interface.d.ts +28 -0
  124. package/types/uni/uts-plugin-api/lib/uni-route/utssdk/interface.d.ts +177 -32
  125. package/types/uni/uts-plugin-api/lib/uni-rpx2px/utssdk/interface.d.ts +7 -2
  126. package/types/uni/uts-plugin-api/lib/uni-scanCode/utssdk/global.d.ts +24 -0
  127. package/types/uni/uts-plugin-api/lib/uni-scanCode/utssdk/index.d.ts +11 -0
  128. package/types/uni/uts-plugin-api/lib/uni-scanCode/utssdk/interface.d.ts +73 -0
  129. package/types/uni/uts-plugin-api/lib/uni-storage/utssdk/interface.d.ts +112 -43
  130. package/types/uni/uts-plugin-api/lib/uni-tabBar/utssdk/global.d.ts +16 -0
  131. package/types/uni/uts-plugin-api/lib/uni-tabBar/utssdk/index.d.ts +8 -0
  132. package/types/uni/uts-plugin-api/lib/uni-tabBar/utssdk/interface.d.ts +78 -1
  133. package/types/uni/uts-plugin-api/lib/uni-theme/utssdk/interface.d.ts +199 -149
  134. package/types/uni/uts-plugin-api/lib/uni-virtualPayment/utssdk/global.d.ts +112 -0
  135. package/types/uni/uts-plugin-api/lib/uni-virtualPayment/utssdk/index.d.ts +55 -0
  136. package/types/uni/uts-plugin-api/lib/uni-virtualPayment/utssdk/interface.d.ts +1068 -0
  137. package/types/uni/uts-plugin-api/lib/uni-websocket/utssdk/interface.d.ts +170 -83
  138. package/types/uni/uts-plugin-biz/lib/uni-ad/utssdk/interface.d.ts +11 -7
  139. package/types/uni/uts-plugin-biz/lib/uni-facialRecognitionVerify/utssdk/interface.d.ts +33 -15
  140. package/types/uni/uts-plugin-biz/lib/uni-push/utssdk/global.d.ts +4 -0
  141. package/types/uni/uts-plugin-biz/lib/uni-push/utssdk/index.d.ts +2 -0
  142. package/types/uni/uts-plugin-biz/lib/uni-push/utssdk/interface.d.ts +777 -568
  143. package/types/uni/uts-plugin-biz/lib/uni-verify/utssdk/interface.d.ts +10 -6
  144. package/types/uni/uts-plugin-component/lib/uni-video/utssdk/interface.d.ts +132 -15
  145. package/types/uni/uts-plugin-extend/global.d.ts +1 -1
  146. package/types/uni/uts-plugin-extend/index.d.ts +1 -3
  147. package/types/uni/uts-plugin-extend/lib/uni-canvas/utssdk/interface.d.ts +4 -4
  148. package/types/uni/uts-plugin-extend/lib/uni-createMapContext/utssdk/interface.d.ts +1 -0
  149. package/types/uni/uts-plugin-extend/lib/uni-createMediaQueryObserver/utssdk/global.d.ts +13 -0
  150. package/types/uni/uts-plugin-extend/lib/uni-createMediaQueryObserver/utssdk/index.d.ts +5 -0
  151. package/types/uni/uts-plugin-extend/lib/uni-createMediaQueryObserver/utssdk/interface.d.ts +126 -0
  152. package/types/uni/uts-plugin-extend/lib/uni-locale/utssdk/interface.d.ts +3 -3
  153. package/types/uni-cloud/interface.d.ts +57 -3
  154. package/types/uni-cloud/unicloud-db/index.ts +3 -3
  155. package/types/vue/CheckboxGroupChangeEvent.d.ts +9 -1
  156. package/types/vue/PickerViewChangeEvent.d.ts +8 -0
  157. package/types/vue/ProgressActiveendEvent.d.ts +4 -0
  158. package/types/vue/RadioGroupChangeEvent.d.ts +9 -1
  159. package/types/vue/SliderChangeEvent.d.ts +4 -0
  160. package/types/vue/SwitchChangeEvent.d.ts +5 -1
  161. package/types/vue/UniCanvasElement.d.ts +6 -1
  162. package/types/vue/UniCloudDBElement.d.ts +5 -0
  163. package/types/vue/UniFormElement.d.ts +6 -1
  164. package/types/vue/UniNavigatorElement.d.ts +5 -0
  165. package/types/vue/global.d.ts +10 -9
  166. package/types/uni/uts-plugin-api/lib/uni-network/utssdk/app-ios/global.d.ts +0 -78
  167. package/types/uni/uts-plugin-api/lib/uni-network/utssdk/app-ios/index.d.ts +0 -38
  168. package/types/uni/uts-plugin-api/lib/uni-network/utssdk/app-ios/interface.d.ts +0 -642
  169. package/types/uni/uts-plugin-extend/lib/uni-getClipboardData/utssdk/global.d.ts +0 -21
  170. package/types/uni/uts-plugin-extend/lib/uni-getClipboardData/utssdk/index.d.ts +0 -9
  171. package/types/uni/uts-plugin-extend/lib/uni-getClipboardData/utssdk/interface.d.ts +0 -119
  172. package/types/uni/uts-plugin-extend/lib/uni-setClipboardData/utssdk/global.d.ts +0 -21
  173. package/types/uni/uts-plugin-extend/lib/uni-setClipboardData/utssdk/index.d.ts +0 -9
  174. package/types/uni/uts-plugin-extend/lib/uni-setClipboardData/utssdk/interface.d.ts +0 -122
  175. package/types/uni-cloud/unicloud-db/index.d.ts +0 -81
@@ -0,0 +1,124 @@
1
+ import { UniElement } from "./IUniElement"
2
+ import { UniCustomEvent } from "./UniCustomEvent"
3
+ /**
4
+ * UniObject 元素对象
5
+ * @package io.dcloud.uniapp.runtime
6
+ * @uniPlatform {
7
+ * "app": {
8
+ * "android": {
9
+ * "osVer": "5.0",
10
+ * "uniVer": "x",
11
+ * "unixVer": "4.25"
12
+ * },
13
+ * "ios": {
14
+ * "osVer": "12.0",
15
+ * "uniVer": "x",
16
+ * "unixVer": "4.25"
17
+ * }
18
+ * }
19
+ * }
20
+ */
21
+ export interface UniObjectElement extends UniElement {
22
+ /**
23
+ * 绑定安卓平台原生view
24
+ * @uniPlatform {
25
+ * "app": {
26
+ * "android": {
27
+ * "osVer": "5.0",
28
+ * "uniVer": "x",
29
+ * "unixVer": "4.25"
30
+ * },
31
+ * "ios": {
32
+ * "osVer": "12.0",
33
+ * "uniVer": "x",
34
+ * "unixVer": "x"
35
+ * }
36
+ * }
37
+ * }
38
+ */
39
+ bindAndroidView(view: View): void
40
+ /**
41
+ * 绑定IOS平台原生view
42
+ * @uniPlatform {
43
+ * "app": {
44
+ * "android": {
45
+ * "osVer": "5.0",
46
+ * "uniVer": "x",
47
+ * "unixVer": "x"
48
+ * },
49
+ * "ios": {
50
+ * "osVer": "12.0",
51
+ * "uniVer": "x",
52
+ * "unixVer": "4.25"
53
+ * }
54
+ * }
55
+ * }
56
+ */
57
+ bindIOSView(view: UIView): void
58
+ }
59
+
60
+ export let UniObjectElement: {
61
+ prototype: UniObjectElement;
62
+ new(): UniObjectElement;
63
+ }
64
+
65
+ /**
66
+ * UniObject自定义事件
67
+ * @package io.dcloud.uniapp.runtime
68
+ * @uniPlatform {
69
+ * "app": {
70
+ * "android": {
71
+ * "osVer": "5.0",
72
+ * "uniVer": "x",
73
+ * "unixVer": "4.25"
74
+ * },
75
+ * "ios": {
76
+ * "osVer": "12.0",
77
+ * "uniVer": "x",
78
+ * "unixVer": "4.25"
79
+ * }
80
+ * }
81
+ * }
82
+ */
83
+ export class UniObjectCustomEvent extends UniCustomEvent<UTSJSONObject> {
84
+ /**
85
+ * 事件类型
86
+ */
87
+ type: string
88
+ detail : UTSJSONObject
89
+
90
+ constructor(type: string, detail: UTSJSONObject)
91
+ constructor(type: string)
92
+ }
93
+
94
+ /**
95
+ * @package io.dcloud.uniapp.runtime
96
+ */
97
+ export class UniObjectInitEventDetail {
98
+ readonly element : UniObjectElement
99
+ }
100
+
101
+ /**
102
+ * UniObject init事件event
103
+ * @package io.dcloud.uniapp.runtime
104
+ * @uniPlatform {
105
+ * "app": {
106
+ * "android": {
107
+ * "osVer": "5.0",
108
+ * "uniVer": "x",
109
+ * "unixVer": "4.25"
110
+ * },
111
+ * "ios": {
112
+ * "osVer": "12.0",
113
+ * "uniVer": "x",
114
+ * "unixVer": "4.25"
115
+ * }
116
+ * }
117
+ * }
118
+ */
119
+ export class UniObjectInitEvent extends UniCustomEvent<UniObjectInitEventDetail> {
120
+ detail : UniObjectInitEventDetail
121
+ type: string
122
+
123
+ constructor(type: string, detail: UniObjectInitEventDetail)
124
+ }
@@ -0,0 +1,241 @@
1
+ /**
2
+ * @package io.dcloud.uniapp.runtime
3
+ */
4
+
5
+ export class Path2D {
6
+ /**
7
+ * 闭合路径,将最后一个点与起点连接起来。如果图形已经封闭,或者只有一个点,那么此方法不会产生任何效果。
8
+ * @uniPlatform {
9
+ * "app": {
10
+ * "android": {
11
+ * "osVer": "5.0",
12
+ * "uniVer": "x",
13
+ * "unixVer": "√"
14
+ * },
15
+ * "ios": {
16
+ * "osVer": "12.0",
17
+ * "uniVer": "x",
18
+ * "unixVer": "√"
19
+ * }
20
+ * }
21
+ * "web": {
22
+ * "uniVer": "√",
23
+ * "unixVer": "4.21"
24
+ * }
25
+ * }
26
+ */
27
+ closePath(): void
28
+
29
+ /**
30
+ * 将一个新的路径的起始点移动到 (x,y) 坐标
31
+ * @param {number} x 点的X轴坐标
32
+ * @param {number} y 点的Y轴坐标
33
+ * @uniPlatform {
34
+ * "app": {
35
+ * "android": {
36
+ * "osVer": "5.0",
37
+ * "uniVer": "x",
38
+ * "unixVer": "√"
39
+ * },
40
+ * "ios": {
41
+ * "osVer": "12.0",
42
+ * "uniVer": "x",
43
+ * "unixVer": "√"
44
+ * }
45
+ * }
46
+ * "web": {
47
+ * "uniVer": "√",
48
+ * "unixVer": "4.21"
49
+ * }
50
+ * }
51
+ */
52
+ moveTo(x: number, y: number): void
53
+
54
+ /**
55
+ * 将路径的最后一个点连接到 (x,y) 坐标
56
+ * @param {number} x 线终点的X轴坐标
57
+ * @param {number} y 线终点的Y轴坐标
58
+ * @uniPlatform {
59
+ * "app": {
60
+ * "android": {
61
+ * "osVer": "5.0",
62
+ * "uniVer": "x",
63
+ * "unixVer": "√"
64
+ * },
65
+ * "ios": {
66
+ * "osVer": "12.0",
67
+ * "uniVer": "x",
68
+ * "unixVer": "√"
69
+ * }
70
+ * }
71
+ * "web": {
72
+ * "uniVer": "√",
73
+ * "unixVer": "4.21"
74
+ * }
75
+ * }
76
+ */
77
+ lineTo(x: number, y: number): void
78
+
79
+ /**
80
+ * 创建三次方贝塞尔曲线路径
81
+ * @param {number} cp1x 第一个贝塞尔控制点的 x 坐标
82
+ * @param {number} cp1y 第一个贝塞尔控制点的 y 坐标
83
+ * @param {number} cp2x 第二个贝塞尔控制点的 x 坐标
84
+ * @param {number} cp2y 第二个贝塞尔控制点的 y 坐标
85
+ * @param {number} x 结束点的 x 坐标
86
+ * @param {number} y 结束点的 y 坐标
87
+ * @uniPlatform {
88
+ * "app": {
89
+ * "android": {
90
+ * "osVer": "5.0",
91
+ * "uniVer": "x",
92
+ * "unixVer": "√"
93
+ * },
94
+ * "ios": {
95
+ * "osVer": "12.0",
96
+ * "uniVer": "x",
97
+ * "unixVer": "√"
98
+ * }
99
+ * }
100
+ * "web": {
101
+ * "uniVer": "√",
102
+ * "unixVer": "4.21"
103
+ * }
104
+ * }
105
+ */
106
+ bezierCurveTo(cp1x: number, cp1y: number, cp2x: number, cp2y: number, x: number, y: number): void
107
+
108
+ /**
109
+ * 创建二次贝塞尔曲线路径
110
+ * @param {number} cpx 贝塞尔控制点的 x 坐标
111
+ * @param {number} cpy 贝塞尔控制点的 y 坐标
112
+ * @param {number} x 结束点的 x 坐标
113
+ * @param {number} y 结束点的 y 坐标
114
+ * @uniPlatform {
115
+ * "app": {
116
+ * "android": {
117
+ * "osVer": "5.0",
118
+ * "uniVer": "x",
119
+ * "unixVer": "√"
120
+ * },
121
+ * "ios": {
122
+ * "osVer": "12.0",
123
+ * "uniVer": "x",
124
+ * "unixVer": "√"
125
+ * }
126
+ * }
127
+ * "web": {
128
+ * "uniVer": "√",
129
+ * "unixVer": "4.21"
130
+ * }
131
+ * }
132
+ */
133
+ quadraticCurveTo(cpx: number, cpy: number, x: number, y: number): void
134
+
135
+ /**
136
+ * 绘制一段弧线
137
+ * @param {number} x 圆弧中心(圆心)的 x 轴坐标
138
+ * @param {number} y 圆弧中心(圆心)的 y 轴坐标
139
+ * @param {number} radius 圆弧的半径
140
+ * @param {number} startAngle 圆弧的起始点,x 轴方向开始计算,单位为弧度
141
+ * @param {number} endAngle 圆弧的终点,单位为弧度
142
+ * @param {number} [anticlockwise=true] 圆弧绘制方向,true:逆时针绘制,false:顺时针绘制。
143
+ * @uniPlatform {
144
+ * "app": {
145
+ * "android": {
146
+ * "osVer": "5.0",
147
+ * "uniVer": "x",
148
+ * "unixVer": "√"
149
+ * },
150
+ * "ios": {
151
+ * "osVer": "12.0",
152
+ * "uniVer": "x",
153
+ * "unixVer": "√"
154
+ * }
155
+ * }
156
+ * "web": {
157
+ * "uniVer": "√",
158
+ * "unixVer": "4.21"
159
+ * }
160
+ * }
161
+ */
162
+ arc(x: number, y: number, radius: number, startAngle: number, endAngle: number, anticlockwise: boolean): void
163
+
164
+ /**
165
+ * 根据控制点和半径绘制圆弧路径,使用当前的描点 (前一个 moveTo 或 lineTo 等函数的止点)。根据当前描点与给定的控制点 1 连接的直线,和控制点 1 与控制点 2 连接的直线,作为使用指定半径的圆的切线,画出两条切线之间的弧线路径
166
+ * @param {number} x1 第一个控制点的 x 轴坐标
167
+ * @param {number} y1 第一个控制点的 y 轴坐标
168
+ * @param {number} x2 第二个控制点的 x 轴坐标
169
+ * @param {number} y2 第二个控制点的 y 轴坐标
170
+ * @param {number} radius 圆弧的半径
171
+ * @uniPlatform {
172
+ * "app": {
173
+ * "android": {
174
+ * "osVer": "5.0",
175
+ * "uniVer": "x",
176
+ * "unixVer": "√"
177
+ * },
178
+ * "ios": {
179
+ * "osVer": "12.0",
180
+ * "uniVer": "x",
181
+ * "unixVer": "√"
182
+ * }
183
+ * }
184
+ * "web": {
185
+ * "uniVer": "√",
186
+ * "unixVer": "4.21"
187
+ * }
188
+ * }
189
+ */
190
+ arcTo(x1: number, y1: number, x2: number, y2: number, radius: number): void
191
+
192
+ /**
193
+ * 添加椭圆路径。椭圆的圆心在(x,y)位置,半径分别是radiusX 和 radiusY,按照anticlockwise(默认顺时针)指定的方向,从 startAngle 开始绘制,到 endAngle 结束
194
+ * @uniPlatform {
195
+ * "app": {
196
+ * "android": {
197
+ * "osVer": "5.0",
198
+ * "uniVer": "√",
199
+ * "unixVer": "x"
200
+ * },
201
+ * "ios": {
202
+ * "osVer": "12.0",
203
+ * "uniVer": "√",
204
+ * "unixVer": "x"
205
+ * }
206
+ * }
207
+ * "web": {
208
+ * "uniVer": "√",
209
+ * "unixVer": "4.21"
210
+ * }
211
+ * }
212
+ */
213
+ ellipse(x: number, y: number, radiusX: number, radiusY: number, rotation: number, startAngle: number, endAngle: number, anticlockwise: boolean): void
214
+
215
+ /**
216
+ * 创建一个矩形路径
217
+ * @param {number} x 矩形路径起点的 x 轴坐标
218
+ * @param {number} y 矩形路径起点的 y 轴坐标
219
+ * @param {number} width 矩形路径的宽度
220
+ * @param {number} height 矩形路径的高度
221
+ * @uniPlatform {
222
+ * "app": {
223
+ * "android": {
224
+ * "osVer": "5.0",
225
+ * "uniVer": "x",
226
+ * "unixVer": "√"
227
+ * },
228
+ * "ios": {
229
+ * "osVer": "12.0",
230
+ * "uniVer": "x",
231
+ * "unixVer": "√"
232
+ * }
233
+ * }
234
+ * "web": {
235
+ * "uniVer": "√",
236
+ * "unixVer": "4.21"
237
+ * }
238
+ * }
239
+ */
240
+ rect(x: number, y: number, width: number, height: number): void
241
+ }
@@ -60,3 +60,4 @@ export class TakeSnapshotOptions {
60
60
 
61
61
  }
62
62
 
63
+
@@ -81,15 +81,125 @@ export interface UniApp {
81
81
  */
82
82
  getRedirectInfo(): Map<string, any | null>
83
83
 
84
+ /**
85
+ * 建立监听元素尺寸变化关系
86
+ * @internal
87
+ * @uniPlatform {
88
+ * "app": {
89
+ * "android": {
90
+ * "osVer": "x",
91
+ * "uniVer": "x",
92
+ * "unixVer": "x"
93
+ * },
94
+ * "ios": {
95
+ * "osVer": "12.0",
96
+ * "uniVer": "x",
97
+ * "unixVer": "4.18"
98
+ * }
99
+ * }
100
+ * }
101
+ */
84
102
  connectResizeObserver(observerId: string, callback?: (res: any) => void): void
85
103
 
104
+ /**
105
+ * 开始监听元素尺寸变化
106
+ * @internal
107
+ * @uniPlatform {
108
+ * "app": {
109
+ * "android": {
110
+ * "osVer": "x",
111
+ * "uniVer": "x",
112
+ * "unixVer": "x"
113
+ * },
114
+ * "ios": {
115
+ * "osVer": "12.0",
116
+ * "uniVer": "x",
117
+ * "unixVer": "4.18"
118
+ * }
119
+ * }
120
+ * }
121
+ */
86
122
  observeResizeObserver(observerId: string, pageId: string, elemId: string): void
87
123
 
124
+ /**
125
+ * 取消监听元素尺寸变化
126
+ * @internal
127
+ * @uniPlatform {
128
+ * "app": {
129
+ * "android": {
130
+ * "osVer": "x",
131
+ * "uniVer": "x",
132
+ * "unixVer": "x"
133
+ * },
134
+ * "ios": {
135
+ * "osVer": "12.0",
136
+ * "uniVer": "x",
137
+ * "unixVer": "4.18"
138
+ * }
139
+ * }
140
+ * }
141
+ */
88
142
  unobserveResizeObserver(observerId: string, pageId: string, elemId: string): void
89
143
 
144
+ /**
145
+ * 断开监听元素尺寸变化
146
+ * @internal
147
+ * @uniPlatform {
148
+ * "app": {
149
+ * "android": {
150
+ * "osVer": "x",
151
+ * "uniVer": "x",
152
+ * "unixVer": "x"
153
+ * },
154
+ * "ios": {
155
+ * "osVer": "12.0",
156
+ * "uniVer": "x",
157
+ * "unixVer": "4.18"
158
+ * }
159
+ * }
160
+ * }
161
+ */
90
162
  disconnectResizeObserver(observerId: string): void
91
163
 
164
+ /**
165
+ * 获取启动参数
166
+ * @internal
167
+ * @uniPlatform {
168
+ * "app": {
169
+ * "android": {
170
+ * "osVer": "x",
171
+ * "uniVer": "x",
172
+ * "unixVer": "x"
173
+ * },
174
+ * "ios": {
175
+ * "osVer": "12.0",
176
+ * "uniVer": "x",
177
+ * "unixVer": "4.24"
178
+ * }
179
+ * }
180
+ * }
181
+ */
92
182
  getLaunchOptionsSync(): { appScheme: string; appLink: string }
183
+
184
+ /**
185
+ * 获取应用Application上下文
186
+ * @internal
187
+ * @uniPlatform {
188
+ * "app": {
189
+ * "android": {
190
+ * "osVer": "5.0",
191
+ * "uniVer": "x",
192
+ * "unixVer": "4.25"
193
+ * },
194
+ * "ios": {
195
+ * "osVer": "x",
196
+ * "uniVer": "x",
197
+ * "unixVer": "x"
198
+ * }
199
+ * }
200
+ * }
201
+ */
202
+ getAndroidApplication(): Application
93
203
  }
94
204
 
95
205
  export type IApp = UniApp
@@ -0,0 +1,9 @@
1
+ import { UniCanvasElement } from "./IUniElement"
2
+ import { UniElementImpl } from "./UniElement"
3
+ import { CanvasRenderingContext2D } from "./CanvasRenderingContext2D"
4
+
5
+ export class UniCanvasElementImpl extends UniElementImpl implements UniCanvasElement {
6
+ width: number
7
+ height: number
8
+ getContext(contentType:string): CanvasRenderingContext2D|null
9
+ }
@@ -16,6 +16,11 @@ export interface UniNativePage {
16
16
  * 页面id
17
17
  */
18
18
  readonly pageId: string
19
+ /**
20
+ * 页面类型
21
+ * 取值范围 'default'|'dialog'
22
+ */
23
+ readonly type: string
19
24
  /**
20
25
  * @internal
21
26
  */
@@ -79,7 +84,8 @@ export interface UniNativePage {
79
84
  | "onPageScroll"
80
85
  | "onResize"
81
86
  | "onWebViewServiceMessage"
82
- | "onPopGesture",
87
+ | "onPopGesture"
88
+ | "onRestart",//页面被重新启动
83
89
  callback: (event: UniPageEvent) => void
84
90
  ): UniCallbackWrapper
85
91
  /**
@@ -130,40 +136,61 @@ export interface UniNativePage {
130
136
  */
131
137
  stopPullDownRefresh(): void
132
138
  /**
139
+ * 页面渲染耗时
133
140
  * @internal
134
141
  */
135
142
  getPageRenderDuration(): number
136
143
  /**
144
+ * 页面排版耗时
137
145
  * @internal
138
146
  */
139
147
  getPageLayoutDuration(): number
140
148
  /**
149
+ * 页面渲染次数
141
150
  * @internal
142
151
  */
143
152
  getPageRenderCount(): number
144
153
  /**
154
+ * 页面排版次数
145
155
  * @internal
146
156
  */
147
157
  getPageLayoutCount(): number
148
158
  /**
159
+ * 首次渲染开始时间
149
160
  * @internal
150
161
  */
151
162
  getFirstRenderStartTime(): number
152
163
  /**
164
+ * 首次排版开始时间
153
165
  * @internal
154
166
  */
155
167
  getFirstLayoutStartTime(): number
156
168
  /**
169
+ * 页面首次渲染时间
157
170
  * @internal
158
171
  */
159
172
  getFirstPageRenderDuration(): number
160
173
  /**
174
+ * 页面首次排版时间
161
175
  * @internal
162
176
  */
163
177
  getFirstPageLayoutDuration(): number
164
178
 
179
+ /**
180
+ * 页面已创建的element个数
181
+ * @internal
182
+ */
183
+ getCreatedElementCount(): number
184
+
185
+ /**
186
+ * 页面已创建element的总耗时
187
+ * @internal
188
+ */
189
+ getCreatedElementDuration(): number
190
+
165
191
  /**
166
192
  * 获取Android原生activity对象 可为空
193
+ * @internal
167
194
  * @uniPlatform {
168
195
  * "app": {
169
196
  * "android": {
@@ -181,6 +208,26 @@ export interface UniNativePage {
181
208
  */
182
209
  getAndroidActivity(): Activity | null
183
210
 
211
+ /**
212
+ * 返回android平台页面根view
213
+ * @internal
214
+ * @uniPlatform {
215
+ * "app": {
216
+ * "android": {
217
+ * "osVer": "5.0",
218
+ * "uniVer": "x",
219
+ * "unixVer": "4.25"
220
+ * },
221
+ * "ios": {
222
+ * "osVer": "x",
223
+ * "uniVer": "x",
224
+ * "unixVer": "x"
225
+ * }
226
+ * }
227
+ * }
228
+ */
229
+ getAndroidView(): View | null
230
+
184
231
  /**
185
232
  * 获取页面style
186
233
  * @uniPlatform {
@@ -8,9 +8,12 @@ export interface UniPageManager {
8
8
  createPage(
9
9
  pageUrl: string,
10
10
  pageId: string,
11
- pageStyle: Map<string, any | null>
11
+ pageStyle: Map<string, any | null>,
12
+ pageOptions?: Map<string, any> | null
12
13
  ): UniNativePage
13
14
 
15
+ createDialogPage(pageUrl: string, pageId: string, pageStyle: Map<string, any | null>, dialogOptions?: Map<string, any | null> | null, pageOptions?: Map<string, any> | null): UniNativePage
16
+
14
17
  findPageById(pageId: string): UniNativePage | null
15
18
  }
16
19
 
@@ -9,6 +9,7 @@ export interface UniProvider {
9
9
  readonly description: string,
10
10
  /**
11
11
  * 判断服务供应商依赖的App是否安装(仅支持微信支付)
12
+ * @deprecated 已废弃(仅为了兼容uni1的规范)
12
13
  */
13
14
  isAppExist: boolean
14
15
  }