@meursyphus/flitter 0.0.9 → 1.0.1
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/index.cjs +188 -246
- package/index.d.cts +78 -66
- package/index.d.ts +78 -66
- package/index.global.js +188 -246
- package/index.js +188 -246
- package/package.json +1 -1
package/index.d.cts
CHANGED
|
@@ -21,6 +21,9 @@ declare class Offset$1 extends Calculable {
|
|
|
21
21
|
x: number;
|
|
22
22
|
y: number;
|
|
23
23
|
}): Offset$1;
|
|
24
|
+
static Constants: {
|
|
25
|
+
zero: Readonly<Offset$1>;
|
|
26
|
+
};
|
|
24
27
|
static zero(): Offset$1;
|
|
25
28
|
plus({ x, y }: Offset$1): Offset$1;
|
|
26
29
|
multiply(value: number): Offset$1;
|
|
@@ -87,13 +90,13 @@ declare class Size {
|
|
|
87
90
|
}
|
|
88
91
|
|
|
89
92
|
declare enum TextDirection {
|
|
90
|
-
rtl =
|
|
91
|
-
ltr =
|
|
93
|
+
rtl = 1,
|
|
94
|
+
ltr = 2
|
|
92
95
|
}
|
|
93
96
|
|
|
94
97
|
declare class Alignment extends Calculable {
|
|
95
|
-
x: number;
|
|
96
|
-
y: number;
|
|
98
|
+
readonly x: number;
|
|
99
|
+
readonly y: number;
|
|
97
100
|
plus(other: Alignment): Alignment;
|
|
98
101
|
multiply(value: number): Alignment;
|
|
99
102
|
equals(other: Alignment): boolean;
|
|
@@ -129,15 +132,15 @@ declare class Alignment extends Calculable {
|
|
|
129
132
|
x: number;
|
|
130
133
|
y: number;
|
|
131
134
|
}): Alignment;
|
|
132
|
-
static topLeft: Alignment;
|
|
133
|
-
static topCenter: Alignment;
|
|
134
|
-
static topRight: Alignment;
|
|
135
|
-
static centerLeft: Alignment;
|
|
136
|
-
static center: Alignment;
|
|
137
|
-
static centerRight: Alignment;
|
|
138
|
-
static bottomLeft: Alignment;
|
|
139
|
-
static bottomCenter: Alignment;
|
|
140
|
-
static bottomRight: Alignment;
|
|
135
|
+
static readonly topLeft: Alignment;
|
|
136
|
+
static readonly topCenter: Alignment;
|
|
137
|
+
static readonly topRight: Alignment;
|
|
138
|
+
static readonly centerLeft: Alignment;
|
|
139
|
+
static readonly center: Alignment;
|
|
140
|
+
static readonly centerRight: Alignment;
|
|
141
|
+
static readonly bottomLeft: Alignment;
|
|
142
|
+
static readonly bottomCenter: Alignment;
|
|
143
|
+
static readonly bottomRight: Alignment;
|
|
141
144
|
resolve(_?: TextDirection): this;
|
|
142
145
|
}
|
|
143
146
|
|
|
@@ -199,6 +202,8 @@ declare class Constraints extends Data {
|
|
|
199
202
|
maxHeight: number;
|
|
200
203
|
constructor({ maxHeight, maxWidth, minHeight, minWidth, }?: ConstraintsProps);
|
|
201
204
|
static lerp(a: Constraints, b: Constraints, t: number): Constraints;
|
|
205
|
+
private static validateInterpolation;
|
|
206
|
+
private static interpolateDimension;
|
|
202
207
|
static expand({ width, height, }?: {
|
|
203
208
|
width?: number;
|
|
204
209
|
height?: number;
|
|
@@ -218,7 +223,10 @@ declare class Constraints extends Data {
|
|
|
218
223
|
}): Constraints;
|
|
219
224
|
enforce(parent: Constraints): Constraints;
|
|
220
225
|
loosen(): Constraints;
|
|
221
|
-
constrain({ width, height }:
|
|
226
|
+
constrain({ width, height }: {
|
|
227
|
+
width: number;
|
|
228
|
+
height: number;
|
|
229
|
+
}): Size;
|
|
222
230
|
normalize(): Constraints;
|
|
223
231
|
getMax(key: "width" | "height"): number;
|
|
224
232
|
getMin(key: "width" | "height"): number;
|
|
@@ -460,30 +468,30 @@ type Radius = {
|
|
|
460
468
|
};
|
|
461
469
|
|
|
462
470
|
declare enum MainAxisSize {
|
|
463
|
-
min =
|
|
464
|
-
max =
|
|
471
|
+
min = 1,
|
|
472
|
+
max = 2
|
|
465
473
|
}
|
|
466
474
|
declare enum VerticalDirection {
|
|
467
|
-
up =
|
|
468
|
-
down =
|
|
475
|
+
up = 1,
|
|
476
|
+
down = 2
|
|
469
477
|
}
|
|
470
478
|
declare enum MainAxisAlignment {
|
|
471
|
-
start =
|
|
472
|
-
end =
|
|
473
|
-
center =
|
|
474
|
-
spaceBetween =
|
|
475
|
-
spaceAround =
|
|
476
|
-
spaceEvenly =
|
|
479
|
+
start = 1,
|
|
480
|
+
end = 2,
|
|
481
|
+
center = 3,
|
|
482
|
+
spaceBetween = 4,
|
|
483
|
+
spaceAround = 5,
|
|
484
|
+
spaceEvenly = 6
|
|
477
485
|
}
|
|
478
486
|
declare enum CrossAxisAlignment {
|
|
479
|
-
start =
|
|
480
|
-
end =
|
|
481
|
-
center =
|
|
482
|
-
stretch =
|
|
487
|
+
start = 1,
|
|
488
|
+
end = 2,
|
|
489
|
+
center = 3,
|
|
490
|
+
stretch = 4
|
|
483
491
|
}
|
|
484
492
|
declare enum Axis {
|
|
485
|
-
horizontal =
|
|
486
|
-
vertical =
|
|
493
|
+
horizontal = 1,
|
|
494
|
+
vertical = 2
|
|
487
495
|
}
|
|
488
496
|
|
|
489
497
|
declare class Matrix2 {
|
|
@@ -2410,6 +2418,9 @@ declare class Matrix4 extends Calculable {
|
|
|
2410
2418
|
static solve3(A: Matrix4, x: Vector3, b: Vector3): void;
|
|
2411
2419
|
static solve(A: Matrix4, x: Vector4, b: Vector4): void;
|
|
2412
2420
|
static tryInvert(other: Matrix4): Matrix4 | null;
|
|
2421
|
+
static readonly Constants: {
|
|
2422
|
+
identity: Readonly<Matrix4>;
|
|
2423
|
+
};
|
|
2413
2424
|
static identity(): Matrix4;
|
|
2414
2425
|
static translation(translation: Vector3): Matrix4;
|
|
2415
2426
|
static translationValues(x: number, y: number, z: number): Matrix4;
|
|
@@ -2591,9 +2602,9 @@ declare class Matrix4 extends Calculable {
|
|
|
2591
2602
|
}
|
|
2592
2603
|
|
|
2593
2604
|
declare enum StackFit {
|
|
2594
|
-
loose =
|
|
2595
|
-
expand =
|
|
2596
|
-
passthrough =
|
|
2605
|
+
loose = 1,
|
|
2606
|
+
expand = 2,
|
|
2607
|
+
passthrough = 3
|
|
2597
2608
|
}
|
|
2598
2609
|
|
|
2599
2610
|
declare class BorderRadius extends BorderRadiusGeometry {
|
|
@@ -2626,7 +2637,7 @@ declare class BorderRadius extends BorderRadiusGeometry {
|
|
|
2626
2637
|
}
|
|
2627
2638
|
|
|
2628
2639
|
declare enum BorderStyle$1 {
|
|
2629
|
-
normal =
|
|
2640
|
+
normal = 1
|
|
2630
2641
|
}
|
|
2631
2642
|
|
|
2632
2643
|
declare class Color extends Calculable {
|
|
@@ -2701,10 +2712,6 @@ declare class BoxShadow extends Calculable {
|
|
|
2701
2712
|
plus(other: BoxShadow): BoxShadow;
|
|
2702
2713
|
multiply(value: number): BoxShadow;
|
|
2703
2714
|
equals(other: BoxShadow): boolean;
|
|
2704
|
-
/**
|
|
2705
|
-
* @deprecated The method should not be used
|
|
2706
|
-
*/
|
|
2707
|
-
eqaul(other: BoxShadow): boolean;
|
|
2708
2715
|
}
|
|
2709
2716
|
|
|
2710
2717
|
type Decoration = BoxDecoration;
|
|
@@ -2813,27 +2820,27 @@ type BorderPathEls = {
|
|
|
2813
2820
|
type BoxBorder = Border;
|
|
2814
2821
|
|
|
2815
2822
|
declare enum TextAlign {
|
|
2816
|
-
left =
|
|
2817
|
-
right =
|
|
2818
|
-
center =
|
|
2819
|
-
start =
|
|
2820
|
-
end =
|
|
2823
|
+
left = 1,
|
|
2824
|
+
right = 2,
|
|
2825
|
+
center = 3,
|
|
2826
|
+
start = 4,
|
|
2827
|
+
end = 5
|
|
2821
2828
|
}
|
|
2822
2829
|
|
|
2823
2830
|
declare enum TextOverflow {
|
|
2824
|
-
clip =
|
|
2825
|
-
visible =
|
|
2826
|
-
ellipsis =
|
|
2831
|
+
clip = 1,
|
|
2832
|
+
visible = 2,
|
|
2833
|
+
ellipsis = 3
|
|
2827
2834
|
}
|
|
2828
2835
|
|
|
2829
2836
|
declare enum TextWidthBasis {
|
|
2830
|
-
parent =
|
|
2831
|
-
longestLine =
|
|
2837
|
+
parent = 1,
|
|
2838
|
+
longestLine = 2
|
|
2832
2839
|
}
|
|
2833
2840
|
|
|
2834
2841
|
declare enum TextBaseline {
|
|
2835
|
-
alphabetic =
|
|
2836
|
-
ideographic =
|
|
2842
|
+
alphabetic = 1,
|
|
2843
|
+
ideographic = 2
|
|
2837
2844
|
}
|
|
2838
2845
|
|
|
2839
2846
|
declare class TextStyle {
|
|
@@ -2896,8 +2903,8 @@ declare class ParagraphStyle {
|
|
|
2896
2903
|
});
|
|
2897
2904
|
}
|
|
2898
2905
|
declare enum FontStyle {
|
|
2899
|
-
normal =
|
|
2900
|
-
italic =
|
|
2906
|
+
normal = 1,
|
|
2907
|
+
italic = 2
|
|
2901
2908
|
}
|
|
2902
2909
|
|
|
2903
2910
|
type PaintContext = {
|
|
@@ -2929,7 +2936,7 @@ declare class Paragraph {
|
|
|
2929
2936
|
layout(width?: number): void;
|
|
2930
2937
|
private addLine;
|
|
2931
2938
|
private align;
|
|
2932
|
-
get resolvedTextAlign():
|
|
2939
|
+
get resolvedTextAlign(): TextAlign;
|
|
2933
2940
|
addText({ fontFamily, fontSize, fontWeight, content, height, fontStyle, color, }: {
|
|
2934
2941
|
fontSize?: number;
|
|
2935
2942
|
fontFamily?: string;
|
|
@@ -2976,7 +2983,7 @@ declare class ParagraphLine {
|
|
|
2976
2983
|
spanBoxes: SpanBox[];
|
|
2977
2984
|
get height(): number;
|
|
2978
2985
|
get width(): number;
|
|
2979
|
-
layout(textAlign:
|
|
2986
|
+
layout(textAlign: TextAlign, { paragraphWidth, offsetY }: {
|
|
2980
2987
|
offsetY: number;
|
|
2981
2988
|
paragraphWidth: number;
|
|
2982
2989
|
}): void;
|
|
@@ -2987,7 +2994,7 @@ declare class ParagraphLine {
|
|
|
2987
2994
|
declare class InlineSpan {
|
|
2988
2995
|
style?: TextStyle;
|
|
2989
2996
|
static equals(targets: InlineSpan[], values: InlineSpan[]): boolean;
|
|
2990
|
-
|
|
2997
|
+
equals(other: InlineSpan): boolean;
|
|
2991
2998
|
constructor({ style }: {
|
|
2992
2999
|
style?: TextStyle;
|
|
2993
3000
|
});
|
|
@@ -3000,7 +3007,7 @@ declare class InlineSpan {
|
|
|
3000
3007
|
declare class TextSpan extends InlineSpan {
|
|
3001
3008
|
text?: string;
|
|
3002
3009
|
children: InlineSpan[];
|
|
3003
|
-
|
|
3010
|
+
equals(other: TextSpan): boolean;
|
|
3004
3011
|
constructor({ style, text, children, }: {
|
|
3005
3012
|
style?: TextStyle;
|
|
3006
3013
|
text?: string;
|
|
@@ -3054,10 +3061,16 @@ declare class RenderObjectWidget extends Widget {
|
|
|
3054
3061
|
updateRenderObject(renderObject: RenderObject): void;
|
|
3055
3062
|
}
|
|
3056
3063
|
|
|
3064
|
+
declare enum ElementType {
|
|
3065
|
+
none = 0,
|
|
3066
|
+
provider = 1,
|
|
3067
|
+
render = 2
|
|
3068
|
+
}
|
|
3069
|
+
|
|
3057
3070
|
declare class RenderObjectElement extends Element {
|
|
3058
3071
|
children: Element[];
|
|
3059
3072
|
_renderObject: RenderObject;
|
|
3060
|
-
type:
|
|
3073
|
+
type: ElementType;
|
|
3061
3074
|
createRenderObject(): RenderObject;
|
|
3062
3075
|
get renderObject(): RenderObject;
|
|
3063
3076
|
constructor(widget: RenderObjectWidget);
|
|
@@ -3417,6 +3430,11 @@ declare class RenderFrameDispatcher {
|
|
|
3417
3430
|
dispatch(): void;
|
|
3418
3431
|
}
|
|
3419
3432
|
|
|
3433
|
+
declare enum SchedulerPhase {
|
|
3434
|
+
idle = 0,
|
|
3435
|
+
persistenceCallbacks = 1,
|
|
3436
|
+
postFrameCallbacks = 2
|
|
3437
|
+
}
|
|
3420
3438
|
declare class Scheduler {
|
|
3421
3439
|
phase: SchedulerPhase;
|
|
3422
3440
|
private persistenceCallbacks;
|
|
@@ -3434,11 +3452,6 @@ declare class Scheduler {
|
|
|
3434
3452
|
addPersistenceCallbacks(callback: () => void): void;
|
|
3435
3453
|
addPostFrameCallbacks(callback: () => void): void;
|
|
3436
3454
|
}
|
|
3437
|
-
declare enum SchedulerPhase {
|
|
3438
|
-
idle = 0,
|
|
3439
|
-
persistenceCallbacks = 1,
|
|
3440
|
-
postFrameCallbacks = 2
|
|
3441
|
-
}
|
|
3442
3455
|
|
|
3443
3456
|
declare class RenderView extends RenderObject {
|
|
3444
3457
|
constructor({ renderOwner }: {
|
|
@@ -3565,7 +3578,7 @@ declare class Element {
|
|
|
3565
3578
|
dirty: boolean;
|
|
3566
3579
|
depth: number;
|
|
3567
3580
|
constructor(widget: Widget);
|
|
3568
|
-
type:
|
|
3581
|
+
type: ElementType;
|
|
3569
3582
|
visitChildren(visitor: (child: Element) => void): void;
|
|
3570
3583
|
get renderObject(): RenderObject;
|
|
3571
3584
|
updateChild(child?: Element | null, newWidget?: Widget | null): Element | null | undefined;
|
|
@@ -3680,8 +3693,7 @@ declare class Provider<ProviderKey, Value> extends Widget {
|
|
|
3680
3693
|
declare class ProviderElement extends Element {
|
|
3681
3694
|
widget: Provider<unknown, unknown>;
|
|
3682
3695
|
child: Element;
|
|
3683
|
-
|
|
3684
|
-
readonly type: "provider";
|
|
3696
|
+
readonly type = ElementType.provider;
|
|
3685
3697
|
get providerKey(): unknown;
|
|
3686
3698
|
get value(): unknown;
|
|
3687
3699
|
visitChildren(visitor: (child: Element) => void): void;
|
|
@@ -3987,7 +3999,7 @@ declare namespace Grid {
|
|
|
3987
3999
|
declare const _default$r: (args_0?: {
|
|
3988
4000
|
flex?: number;
|
|
3989
4001
|
child?: Widget;
|
|
3990
|
-
fit?: "
|
|
4002
|
+
fit?: "tight" | "loose";
|
|
3991
4003
|
key?: any;
|
|
3992
4004
|
}) => any;
|
|
3993
4005
|
|
package/index.d.ts
CHANGED
|
@@ -21,6 +21,9 @@ declare class Offset$1 extends Calculable {
|
|
|
21
21
|
x: number;
|
|
22
22
|
y: number;
|
|
23
23
|
}): Offset$1;
|
|
24
|
+
static Constants: {
|
|
25
|
+
zero: Readonly<Offset$1>;
|
|
26
|
+
};
|
|
24
27
|
static zero(): Offset$1;
|
|
25
28
|
plus({ x, y }: Offset$1): Offset$1;
|
|
26
29
|
multiply(value: number): Offset$1;
|
|
@@ -87,13 +90,13 @@ declare class Size {
|
|
|
87
90
|
}
|
|
88
91
|
|
|
89
92
|
declare enum TextDirection {
|
|
90
|
-
rtl =
|
|
91
|
-
ltr =
|
|
93
|
+
rtl = 1,
|
|
94
|
+
ltr = 2
|
|
92
95
|
}
|
|
93
96
|
|
|
94
97
|
declare class Alignment extends Calculable {
|
|
95
|
-
x: number;
|
|
96
|
-
y: number;
|
|
98
|
+
readonly x: number;
|
|
99
|
+
readonly y: number;
|
|
97
100
|
plus(other: Alignment): Alignment;
|
|
98
101
|
multiply(value: number): Alignment;
|
|
99
102
|
equals(other: Alignment): boolean;
|
|
@@ -129,15 +132,15 @@ declare class Alignment extends Calculable {
|
|
|
129
132
|
x: number;
|
|
130
133
|
y: number;
|
|
131
134
|
}): Alignment;
|
|
132
|
-
static topLeft: Alignment;
|
|
133
|
-
static topCenter: Alignment;
|
|
134
|
-
static topRight: Alignment;
|
|
135
|
-
static centerLeft: Alignment;
|
|
136
|
-
static center: Alignment;
|
|
137
|
-
static centerRight: Alignment;
|
|
138
|
-
static bottomLeft: Alignment;
|
|
139
|
-
static bottomCenter: Alignment;
|
|
140
|
-
static bottomRight: Alignment;
|
|
135
|
+
static readonly topLeft: Alignment;
|
|
136
|
+
static readonly topCenter: Alignment;
|
|
137
|
+
static readonly topRight: Alignment;
|
|
138
|
+
static readonly centerLeft: Alignment;
|
|
139
|
+
static readonly center: Alignment;
|
|
140
|
+
static readonly centerRight: Alignment;
|
|
141
|
+
static readonly bottomLeft: Alignment;
|
|
142
|
+
static readonly bottomCenter: Alignment;
|
|
143
|
+
static readonly bottomRight: Alignment;
|
|
141
144
|
resolve(_?: TextDirection): this;
|
|
142
145
|
}
|
|
143
146
|
|
|
@@ -199,6 +202,8 @@ declare class Constraints extends Data {
|
|
|
199
202
|
maxHeight: number;
|
|
200
203
|
constructor({ maxHeight, maxWidth, minHeight, minWidth, }?: ConstraintsProps);
|
|
201
204
|
static lerp(a: Constraints, b: Constraints, t: number): Constraints;
|
|
205
|
+
private static validateInterpolation;
|
|
206
|
+
private static interpolateDimension;
|
|
202
207
|
static expand({ width, height, }?: {
|
|
203
208
|
width?: number;
|
|
204
209
|
height?: number;
|
|
@@ -218,7 +223,10 @@ declare class Constraints extends Data {
|
|
|
218
223
|
}): Constraints;
|
|
219
224
|
enforce(parent: Constraints): Constraints;
|
|
220
225
|
loosen(): Constraints;
|
|
221
|
-
constrain({ width, height }:
|
|
226
|
+
constrain({ width, height }: {
|
|
227
|
+
width: number;
|
|
228
|
+
height: number;
|
|
229
|
+
}): Size;
|
|
222
230
|
normalize(): Constraints;
|
|
223
231
|
getMax(key: "width" | "height"): number;
|
|
224
232
|
getMin(key: "width" | "height"): number;
|
|
@@ -460,30 +468,30 @@ type Radius = {
|
|
|
460
468
|
};
|
|
461
469
|
|
|
462
470
|
declare enum MainAxisSize {
|
|
463
|
-
min =
|
|
464
|
-
max =
|
|
471
|
+
min = 1,
|
|
472
|
+
max = 2
|
|
465
473
|
}
|
|
466
474
|
declare enum VerticalDirection {
|
|
467
|
-
up =
|
|
468
|
-
down =
|
|
475
|
+
up = 1,
|
|
476
|
+
down = 2
|
|
469
477
|
}
|
|
470
478
|
declare enum MainAxisAlignment {
|
|
471
|
-
start =
|
|
472
|
-
end =
|
|
473
|
-
center =
|
|
474
|
-
spaceBetween =
|
|
475
|
-
spaceAround =
|
|
476
|
-
spaceEvenly =
|
|
479
|
+
start = 1,
|
|
480
|
+
end = 2,
|
|
481
|
+
center = 3,
|
|
482
|
+
spaceBetween = 4,
|
|
483
|
+
spaceAround = 5,
|
|
484
|
+
spaceEvenly = 6
|
|
477
485
|
}
|
|
478
486
|
declare enum CrossAxisAlignment {
|
|
479
|
-
start =
|
|
480
|
-
end =
|
|
481
|
-
center =
|
|
482
|
-
stretch =
|
|
487
|
+
start = 1,
|
|
488
|
+
end = 2,
|
|
489
|
+
center = 3,
|
|
490
|
+
stretch = 4
|
|
483
491
|
}
|
|
484
492
|
declare enum Axis {
|
|
485
|
-
horizontal =
|
|
486
|
-
vertical =
|
|
493
|
+
horizontal = 1,
|
|
494
|
+
vertical = 2
|
|
487
495
|
}
|
|
488
496
|
|
|
489
497
|
declare class Matrix2 {
|
|
@@ -2410,6 +2418,9 @@ declare class Matrix4 extends Calculable {
|
|
|
2410
2418
|
static solve3(A: Matrix4, x: Vector3, b: Vector3): void;
|
|
2411
2419
|
static solve(A: Matrix4, x: Vector4, b: Vector4): void;
|
|
2412
2420
|
static tryInvert(other: Matrix4): Matrix4 | null;
|
|
2421
|
+
static readonly Constants: {
|
|
2422
|
+
identity: Readonly<Matrix4>;
|
|
2423
|
+
};
|
|
2413
2424
|
static identity(): Matrix4;
|
|
2414
2425
|
static translation(translation: Vector3): Matrix4;
|
|
2415
2426
|
static translationValues(x: number, y: number, z: number): Matrix4;
|
|
@@ -2591,9 +2602,9 @@ declare class Matrix4 extends Calculable {
|
|
|
2591
2602
|
}
|
|
2592
2603
|
|
|
2593
2604
|
declare enum StackFit {
|
|
2594
|
-
loose =
|
|
2595
|
-
expand =
|
|
2596
|
-
passthrough =
|
|
2605
|
+
loose = 1,
|
|
2606
|
+
expand = 2,
|
|
2607
|
+
passthrough = 3
|
|
2597
2608
|
}
|
|
2598
2609
|
|
|
2599
2610
|
declare class BorderRadius extends BorderRadiusGeometry {
|
|
@@ -2626,7 +2637,7 @@ declare class BorderRadius extends BorderRadiusGeometry {
|
|
|
2626
2637
|
}
|
|
2627
2638
|
|
|
2628
2639
|
declare enum BorderStyle$1 {
|
|
2629
|
-
normal =
|
|
2640
|
+
normal = 1
|
|
2630
2641
|
}
|
|
2631
2642
|
|
|
2632
2643
|
declare class Color extends Calculable {
|
|
@@ -2701,10 +2712,6 @@ declare class BoxShadow extends Calculable {
|
|
|
2701
2712
|
plus(other: BoxShadow): BoxShadow;
|
|
2702
2713
|
multiply(value: number): BoxShadow;
|
|
2703
2714
|
equals(other: BoxShadow): boolean;
|
|
2704
|
-
/**
|
|
2705
|
-
* @deprecated The method should not be used
|
|
2706
|
-
*/
|
|
2707
|
-
eqaul(other: BoxShadow): boolean;
|
|
2708
2715
|
}
|
|
2709
2716
|
|
|
2710
2717
|
type Decoration = BoxDecoration;
|
|
@@ -2813,27 +2820,27 @@ type BorderPathEls = {
|
|
|
2813
2820
|
type BoxBorder = Border;
|
|
2814
2821
|
|
|
2815
2822
|
declare enum TextAlign {
|
|
2816
|
-
left =
|
|
2817
|
-
right =
|
|
2818
|
-
center =
|
|
2819
|
-
start =
|
|
2820
|
-
end =
|
|
2823
|
+
left = 1,
|
|
2824
|
+
right = 2,
|
|
2825
|
+
center = 3,
|
|
2826
|
+
start = 4,
|
|
2827
|
+
end = 5
|
|
2821
2828
|
}
|
|
2822
2829
|
|
|
2823
2830
|
declare enum TextOverflow {
|
|
2824
|
-
clip =
|
|
2825
|
-
visible =
|
|
2826
|
-
ellipsis =
|
|
2831
|
+
clip = 1,
|
|
2832
|
+
visible = 2,
|
|
2833
|
+
ellipsis = 3
|
|
2827
2834
|
}
|
|
2828
2835
|
|
|
2829
2836
|
declare enum TextWidthBasis {
|
|
2830
|
-
parent =
|
|
2831
|
-
longestLine =
|
|
2837
|
+
parent = 1,
|
|
2838
|
+
longestLine = 2
|
|
2832
2839
|
}
|
|
2833
2840
|
|
|
2834
2841
|
declare enum TextBaseline {
|
|
2835
|
-
alphabetic =
|
|
2836
|
-
ideographic =
|
|
2842
|
+
alphabetic = 1,
|
|
2843
|
+
ideographic = 2
|
|
2837
2844
|
}
|
|
2838
2845
|
|
|
2839
2846
|
declare class TextStyle {
|
|
@@ -2896,8 +2903,8 @@ declare class ParagraphStyle {
|
|
|
2896
2903
|
});
|
|
2897
2904
|
}
|
|
2898
2905
|
declare enum FontStyle {
|
|
2899
|
-
normal =
|
|
2900
|
-
italic =
|
|
2906
|
+
normal = 1,
|
|
2907
|
+
italic = 2
|
|
2901
2908
|
}
|
|
2902
2909
|
|
|
2903
2910
|
type PaintContext = {
|
|
@@ -2929,7 +2936,7 @@ declare class Paragraph {
|
|
|
2929
2936
|
layout(width?: number): void;
|
|
2930
2937
|
private addLine;
|
|
2931
2938
|
private align;
|
|
2932
|
-
get resolvedTextAlign():
|
|
2939
|
+
get resolvedTextAlign(): TextAlign;
|
|
2933
2940
|
addText({ fontFamily, fontSize, fontWeight, content, height, fontStyle, color, }: {
|
|
2934
2941
|
fontSize?: number;
|
|
2935
2942
|
fontFamily?: string;
|
|
@@ -2976,7 +2983,7 @@ declare class ParagraphLine {
|
|
|
2976
2983
|
spanBoxes: SpanBox[];
|
|
2977
2984
|
get height(): number;
|
|
2978
2985
|
get width(): number;
|
|
2979
|
-
layout(textAlign:
|
|
2986
|
+
layout(textAlign: TextAlign, { paragraphWidth, offsetY }: {
|
|
2980
2987
|
offsetY: number;
|
|
2981
2988
|
paragraphWidth: number;
|
|
2982
2989
|
}): void;
|
|
@@ -2987,7 +2994,7 @@ declare class ParagraphLine {
|
|
|
2987
2994
|
declare class InlineSpan {
|
|
2988
2995
|
style?: TextStyle;
|
|
2989
2996
|
static equals(targets: InlineSpan[], values: InlineSpan[]): boolean;
|
|
2990
|
-
|
|
2997
|
+
equals(other: InlineSpan): boolean;
|
|
2991
2998
|
constructor({ style }: {
|
|
2992
2999
|
style?: TextStyle;
|
|
2993
3000
|
});
|
|
@@ -3000,7 +3007,7 @@ declare class InlineSpan {
|
|
|
3000
3007
|
declare class TextSpan extends InlineSpan {
|
|
3001
3008
|
text?: string;
|
|
3002
3009
|
children: InlineSpan[];
|
|
3003
|
-
|
|
3010
|
+
equals(other: TextSpan): boolean;
|
|
3004
3011
|
constructor({ style, text, children, }: {
|
|
3005
3012
|
style?: TextStyle;
|
|
3006
3013
|
text?: string;
|
|
@@ -3054,10 +3061,16 @@ declare class RenderObjectWidget extends Widget {
|
|
|
3054
3061
|
updateRenderObject(renderObject: RenderObject): void;
|
|
3055
3062
|
}
|
|
3056
3063
|
|
|
3064
|
+
declare enum ElementType {
|
|
3065
|
+
none = 0,
|
|
3066
|
+
provider = 1,
|
|
3067
|
+
render = 2
|
|
3068
|
+
}
|
|
3069
|
+
|
|
3057
3070
|
declare class RenderObjectElement extends Element {
|
|
3058
3071
|
children: Element[];
|
|
3059
3072
|
_renderObject: RenderObject;
|
|
3060
|
-
type:
|
|
3073
|
+
type: ElementType;
|
|
3061
3074
|
createRenderObject(): RenderObject;
|
|
3062
3075
|
get renderObject(): RenderObject;
|
|
3063
3076
|
constructor(widget: RenderObjectWidget);
|
|
@@ -3417,6 +3430,11 @@ declare class RenderFrameDispatcher {
|
|
|
3417
3430
|
dispatch(): void;
|
|
3418
3431
|
}
|
|
3419
3432
|
|
|
3433
|
+
declare enum SchedulerPhase {
|
|
3434
|
+
idle = 0,
|
|
3435
|
+
persistenceCallbacks = 1,
|
|
3436
|
+
postFrameCallbacks = 2
|
|
3437
|
+
}
|
|
3420
3438
|
declare class Scheduler {
|
|
3421
3439
|
phase: SchedulerPhase;
|
|
3422
3440
|
private persistenceCallbacks;
|
|
@@ -3434,11 +3452,6 @@ declare class Scheduler {
|
|
|
3434
3452
|
addPersistenceCallbacks(callback: () => void): void;
|
|
3435
3453
|
addPostFrameCallbacks(callback: () => void): void;
|
|
3436
3454
|
}
|
|
3437
|
-
declare enum SchedulerPhase {
|
|
3438
|
-
idle = 0,
|
|
3439
|
-
persistenceCallbacks = 1,
|
|
3440
|
-
postFrameCallbacks = 2
|
|
3441
|
-
}
|
|
3442
3455
|
|
|
3443
3456
|
declare class RenderView extends RenderObject {
|
|
3444
3457
|
constructor({ renderOwner }: {
|
|
@@ -3565,7 +3578,7 @@ declare class Element {
|
|
|
3565
3578
|
dirty: boolean;
|
|
3566
3579
|
depth: number;
|
|
3567
3580
|
constructor(widget: Widget);
|
|
3568
|
-
type:
|
|
3581
|
+
type: ElementType;
|
|
3569
3582
|
visitChildren(visitor: (child: Element) => void): void;
|
|
3570
3583
|
get renderObject(): RenderObject;
|
|
3571
3584
|
updateChild(child?: Element | null, newWidget?: Widget | null): Element | null | undefined;
|
|
@@ -3680,8 +3693,7 @@ declare class Provider<ProviderKey, Value> extends Widget {
|
|
|
3680
3693
|
declare class ProviderElement extends Element {
|
|
3681
3694
|
widget: Provider<unknown, unknown>;
|
|
3682
3695
|
child: Element;
|
|
3683
|
-
|
|
3684
|
-
readonly type: "provider";
|
|
3696
|
+
readonly type = ElementType.provider;
|
|
3685
3697
|
get providerKey(): unknown;
|
|
3686
3698
|
get value(): unknown;
|
|
3687
3699
|
visitChildren(visitor: (child: Element) => void): void;
|
|
@@ -3987,7 +3999,7 @@ declare namespace Grid {
|
|
|
3987
3999
|
declare const _default$r: (args_0?: {
|
|
3988
4000
|
flex?: number;
|
|
3989
4001
|
child?: Widget;
|
|
3990
|
-
fit?: "
|
|
4002
|
+
fit?: "tight" | "loose";
|
|
3991
4003
|
key?: any;
|
|
3992
4004
|
}) => any;
|
|
3993
4005
|
|