@leafer/canvas-miniapp 1.0.0-beta.12 → 1.0.0-beta.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.
- package/package.json +11 -8
- package/src/LeaferCanvas.ts +7 -6
- package/types/index.d.ts +20 -0
package/package.json
CHANGED
|
@@ -1,12 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@leafer/canvas-miniapp",
|
|
3
|
-
"version": "1.0.0-beta.
|
|
3
|
+
"version": "1.0.0-beta.16",
|
|
4
4
|
"description": "@leafer/canvas-miniapp",
|
|
5
5
|
"author": "Chao (Leafer) Wan",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"main": "src/index.ts",
|
|
8
|
+
"types": "types/index.d.ts",
|
|
8
9
|
"files": [
|
|
9
|
-
"src"
|
|
10
|
+
"src",
|
|
11
|
+
"types",
|
|
12
|
+
"dist"
|
|
10
13
|
],
|
|
11
14
|
"repository": {
|
|
12
15
|
"type": "git",
|
|
@@ -19,13 +22,13 @@
|
|
|
19
22
|
"leaferjs"
|
|
20
23
|
],
|
|
21
24
|
"dependencies": {
|
|
22
|
-
"@leafer/canvas": "1.0.0-beta.
|
|
23
|
-
"@leafer/data": "1.0.0-beta.
|
|
24
|
-
"@leafer/event": "1.0.0-beta.
|
|
25
|
-
"@leafer/platform": "1.0.0-beta.
|
|
26
|
-
"@leafer/debug": "1.0.0-beta.
|
|
25
|
+
"@leafer/canvas": "1.0.0-beta.16",
|
|
26
|
+
"@leafer/data": "1.0.0-beta.16",
|
|
27
|
+
"@leafer/event": "1.0.0-beta.16",
|
|
28
|
+
"@leafer/platform": "1.0.0-beta.16",
|
|
29
|
+
"@leafer/debug": "1.0.0-beta.16"
|
|
27
30
|
},
|
|
28
31
|
"devDependencies": {
|
|
29
|
-
"@leafer/interface": "1.0.0-beta.
|
|
32
|
+
"@leafer/interface": "1.0.0-beta.16"
|
|
30
33
|
}
|
|
31
34
|
}
|
package/src/LeaferCanvas.ts
CHANGED
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
import { IResizeEventListener, IAutoBounds, IScreenSizeData, IFunction, IMiniappSelect, IObject } from '@leafer/interface'
|
|
2
|
-
import { LeaferCanvasBase, canvasPatch, canvasSizeAttrs } from '@leafer/
|
|
3
|
-
|
|
4
|
-
import { DataHelper } from '@leafer/data'
|
|
5
|
-
import { ResizeEvent } from '@leafer/event'
|
|
2
|
+
import { LeaferCanvasBase, canvasPatch, canvasSizeAttrs, Platform, DataHelper, ResizeEvent } from '@leafer/core'
|
|
3
|
+
|
|
6
4
|
|
|
7
5
|
export class LeaferCanvas extends LeaferCanvasBase {
|
|
8
6
|
|
|
9
7
|
public get allowBackgroundColor(): boolean { return false }
|
|
10
8
|
|
|
11
|
-
|
|
12
|
-
|
|
9
|
+
public viewSelect: IMiniappSelect
|
|
10
|
+
public resizeListener: IResizeEventListener
|
|
11
|
+
|
|
12
|
+
public testView: any
|
|
13
|
+
public testContext: any
|
|
13
14
|
|
|
14
15
|
public init(): void {
|
|
15
16
|
let { view } = this.config
|
package/types/index.d.ts
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { IMiniappSelect, IResizeEventListener, IObject, IFunction, IAutoBounds } from '@leafer/interface';
|
|
2
|
+
import { LeaferCanvasBase } from '@leafer/core';
|
|
3
|
+
|
|
4
|
+
declare class LeaferCanvas extends LeaferCanvasBase {
|
|
5
|
+
get allowBackgroundColor(): boolean;
|
|
6
|
+
viewSelect: IMiniappSelect;
|
|
7
|
+
resizeListener: IResizeEventListener;
|
|
8
|
+
testView: any;
|
|
9
|
+
testContext: any;
|
|
10
|
+
init(): void;
|
|
11
|
+
protected initView(view?: IObject): void;
|
|
12
|
+
protected __createView(): void;
|
|
13
|
+
updateViewSize(): void;
|
|
14
|
+
updateClientBounds(callback?: IFunction): void;
|
|
15
|
+
startAutoLayout(_autoBounds: IAutoBounds, listener: IResizeEventListener): void;
|
|
16
|
+
checkSize(): void;
|
|
17
|
+
stopAutoLayout(): void;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
export { LeaferCanvas };
|