@tarojs/plugin-platform-h5 3.7.0-canary.0 → 3.7.0-canary.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.
- package/build/utils/ast.ts +11 -1
- package/dist/definition.json +38 -9
- package/dist/dist/definition.json.d.ts +540 -496
- package/dist/dist/definition.json.js +1 -1
- package/dist/index.js +20 -22
- package/dist/index.js.map +1 -1
- package/package.json +15 -14
package/build/utils/ast.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import * as path from 'path'
|
|
1
2
|
import ts from 'typescript'
|
|
2
3
|
|
|
3
4
|
export interface DocEntry {
|
|
@@ -16,6 +17,15 @@ export interface DocEntry {
|
|
|
16
17
|
symbol?: DocEntry
|
|
17
18
|
}
|
|
18
19
|
|
|
20
|
+
export function pathsAreEqual (path1: string, path2: string) {
|
|
21
|
+
path1 = path.resolve(path1)
|
|
22
|
+
path2 = path.resolve(path2)
|
|
23
|
+
if (process.platform === 'win32') {
|
|
24
|
+
return path1.toLowerCase() === path2.toLowerCase()
|
|
25
|
+
}
|
|
26
|
+
return path1 === path2
|
|
27
|
+
}
|
|
28
|
+
|
|
19
29
|
export function generateDocumentation (
|
|
20
30
|
filepaths: string[],
|
|
21
31
|
options: ts.CompilerOptions,
|
|
@@ -32,7 +42,7 @@ export function generateDocumentation (
|
|
|
32
42
|
if (param.withDeclaration !== false || !sourceFile.isDeclarationFile) {
|
|
33
43
|
if (
|
|
34
44
|
(param.mapAll === true && filepaths.includes(sourceFile.fileName))
|
|
35
|
-
|| sourceFile.fileName
|
|
45
|
+
|| pathsAreEqual(sourceFile.fileName, filepaths[0])
|
|
36
46
|
) {
|
|
37
47
|
ts.forEachChild(sourceFile, (n) => visitAST(n, output))
|
|
38
48
|
}
|
package/dist/definition.json
CHANGED
|
@@ -86,6 +86,11 @@
|
|
|
86
86
|
"success": "void",
|
|
87
87
|
"return": "Promise<Partial<CallbackResult> & Record<string, unknown> & CallbackResult>"
|
|
88
88
|
},
|
|
89
|
+
"tradePay": {
|
|
90
|
+
"object": "*",
|
|
91
|
+
"success": "void",
|
|
92
|
+
"return": "Promise<Partial<CallbackResult> & Record<string, unknown> & CallbackResult>"
|
|
93
|
+
},
|
|
89
94
|
"env": {},
|
|
90
95
|
"arrayBufferToBase64": "*",
|
|
91
96
|
"base64ToArrayBuffer": "*",
|
|
@@ -344,7 +349,7 @@
|
|
|
344
349
|
"callback": "Result"
|
|
345
350
|
},
|
|
346
351
|
"offAccelerometerChange": {
|
|
347
|
-
"callback": "
|
|
352
|
+
"callback": "Result"
|
|
348
353
|
},
|
|
349
354
|
"checkIsOpenAccessibility": {
|
|
350
355
|
"object": "*",
|
|
@@ -555,7 +560,7 @@
|
|
|
555
560
|
"callback": "OnCompassChangeCallbackResult"
|
|
556
561
|
},
|
|
557
562
|
"offCompassChange": {
|
|
558
|
-
"callback": "
|
|
563
|
+
"callback": "OnCompassChangeCallbackResult"
|
|
559
564
|
},
|
|
560
565
|
"chooseContact": {
|
|
561
566
|
"object": "*",
|
|
@@ -669,7 +674,7 @@
|
|
|
669
674
|
"callback": "CallbackResult"
|
|
670
675
|
},
|
|
671
676
|
"offDeviceMotionChange": {
|
|
672
|
-
"callback": "
|
|
677
|
+
"callback": "CallbackResult"
|
|
673
678
|
},
|
|
674
679
|
"getNetworkType": {
|
|
675
680
|
"object": "Option",
|
|
@@ -1506,11 +1511,6 @@
|
|
|
1506
1511
|
"success": "void",
|
|
1507
1512
|
"return": "Promise<Partial<CallbackResult> & Record<string, unknown> & CallbackResult>"
|
|
1508
1513
|
},
|
|
1509
|
-
"checkIsAddedToMyMiniProgram": {
|
|
1510
|
-
"object": "*",
|
|
1511
|
-
"success": "void",
|
|
1512
|
-
"return": "Promise<Partial<CallbackResult> & Record<string, unknown> & CallbackResult>"
|
|
1513
|
-
},
|
|
1514
1514
|
"getGroupEnterInfo": {
|
|
1515
1515
|
"object": "*",
|
|
1516
1516
|
"success": "void",
|
|
@@ -1546,6 +1546,31 @@
|
|
|
1546
1546
|
"success": "void",
|
|
1547
1547
|
"return": "Promise<Partial<CallbackResult> & Record<string, unknown> & CallbackResult>"
|
|
1548
1548
|
},
|
|
1549
|
+
"checkIsAddedToMyMiniProgram": {
|
|
1550
|
+
"object": "*",
|
|
1551
|
+
"success": "void",
|
|
1552
|
+
"return": "Promise<Partial<CallbackResult> & Record<string, unknown> & CallbackResult>"
|
|
1553
|
+
},
|
|
1554
|
+
"requirePrivacyAuthorize": {
|
|
1555
|
+
"object": "*",
|
|
1556
|
+
"success": "void",
|
|
1557
|
+
"return": "Promise<Partial<CallbackResult> & Record<string, unknown> & CallbackResult>"
|
|
1558
|
+
},
|
|
1559
|
+
"openPrivacyContract": {
|
|
1560
|
+
"object": "*",
|
|
1561
|
+
"success": "void",
|
|
1562
|
+
"return": "Promise<Partial<CallbackResult> & Record<string, unknown> & CallbackResult>"
|
|
1563
|
+
},
|
|
1564
|
+
"onNeedPrivacyAuthorization": {
|
|
1565
|
+
"object": "*",
|
|
1566
|
+
"success": "void",
|
|
1567
|
+
"return": "Promise<Partial<CallbackResult> & Record<string, unknown> & CallbackResult>"
|
|
1568
|
+
},
|
|
1569
|
+
"getPrivacySetting": {
|
|
1570
|
+
"object": "*",
|
|
1571
|
+
"success": "void",
|
|
1572
|
+
"return": "Promise<Partial<CallbackResult> & Record<string, unknown> & CallbackResult>"
|
|
1573
|
+
},
|
|
1549
1574
|
"showRedPackage": {
|
|
1550
1575
|
"object": "*",
|
|
1551
1576
|
"success": "void",
|
|
@@ -2097,7 +2122,9 @@
|
|
|
2097
2122
|
"camera": {},
|
|
2098
2123
|
"canvas": {
|
|
2099
2124
|
"canvasId": "string",
|
|
2100
|
-
"
|
|
2125
|
+
"height": "string",
|
|
2126
|
+
"nativeProps": "*",
|
|
2127
|
+
"width": "string"
|
|
2101
2128
|
},
|
|
2102
2129
|
"channel-live": {},
|
|
2103
2130
|
"channel-video": {},
|
|
@@ -2262,6 +2289,7 @@
|
|
|
2262
2289
|
"animated": "boolean",
|
|
2263
2290
|
"lowerThreshold": "string | number",
|
|
2264
2291
|
"mpScrollIntoView": "string",
|
|
2292
|
+
"mpScrollIntoViewAlignment": "\"center\" | \"start\" | \"end\" | \"nearest\"",
|
|
2265
2293
|
"mpScrollIntoViewMethod": "(selector: string) => Promise<void>",
|
|
2266
2294
|
"mpScrollLeft": "string | number",
|
|
2267
2295
|
"mpScrollToMethod": "(object: Option) => Promise<void>",
|
|
@@ -2285,6 +2313,7 @@
|
|
|
2285
2313
|
"value": "number"
|
|
2286
2314
|
},
|
|
2287
2315
|
"slot": {},
|
|
2316
|
+
"snapshot": {},
|
|
2288
2317
|
"sticky-header": {},
|
|
2289
2318
|
"sticky-section": {},
|
|
2290
2319
|
"swiper": {
|