flet-lottie 0.2.0.dev41__py3-none-any.whl → 0.2.0.dev55__py3-none-any.whl
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.
Potentially problematic release.
This version of flet-lottie might be problematic. Click here for more details.
- flet_lottie/__init__.py +2 -0
- flet_lottie/lottie.py +36 -25
- {flet_lottie-0.2.0.dev41.dist-info → flet_lottie-0.2.0.dev55.dist-info}/METADATA +1 -1
- {flet_lottie-0.2.0.dev41.dist-info → flet_lottie-0.2.0.dev55.dist-info}/RECORD +9 -9
- flutter/flet_lottie/pubspec.lock +7 -7
- flutter/flet_lottie/pubspec.yaml +1 -1
- {flet_lottie-0.2.0.dev41.dist-info → flet_lottie-0.2.0.dev55.dist-info}/WHEEL +0 -0
- {flet_lottie-0.2.0.dev41.dist-info → flet_lottie-0.2.0.dev55.dist-info}/licenses/LICENSE +0 -0
- {flet_lottie-0.2.0.dev41.dist-info → flet_lottie-0.2.0.dev55.dist-info}/top_level.txt +0 -0
flet_lottie/__init__.py
CHANGED
flet_lottie/lottie.py
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
from typing import
|
|
1
|
+
from typing import Optional
|
|
2
2
|
|
|
3
3
|
import flet as ft
|
|
4
4
|
|
|
@@ -11,37 +11,45 @@ class Lottie(ft.ConstrainedControl):
|
|
|
11
11
|
Displays lottie animations.
|
|
12
12
|
|
|
13
13
|
Raises:
|
|
14
|
-
AssertionError: If neither `src` nor
|
|
14
|
+
AssertionError: If neither [`src`][(c).] nor
|
|
15
|
+
[`src_base64`][(c).] is provided.
|
|
15
16
|
"""
|
|
16
17
|
|
|
17
18
|
src: Optional[str] = None
|
|
18
19
|
"""
|
|
19
|
-
The source of the Lottie file.
|
|
20
|
-
|
|
20
|
+
The source of the Lottie file.
|
|
21
|
+
|
|
22
|
+
Can be a URL or a local [asset file](https://flet.dev/docs/cookbook/assets).
|
|
23
|
+
|
|
21
24
|
Note:
|
|
22
|
-
|
|
23
|
-
|
|
25
|
+
If both `src` and [`src_base64`][..] are provided,
|
|
26
|
+
`src_base64` will be prioritized/used.
|
|
24
27
|
"""
|
|
25
28
|
|
|
26
29
|
src_base64: Optional[str] = None
|
|
27
30
|
"""
|
|
28
|
-
The base64 encoded string of the Lottie file.
|
|
29
|
-
|
|
31
|
+
The base64 encoded string of the Lottie file.
|
|
32
|
+
|
|
30
33
|
Note:
|
|
31
|
-
|
|
32
|
-
|
|
34
|
+
If both `src_base64` and [`src`][..] are provided,
|
|
35
|
+
`src_base64` will be prioritized/used.
|
|
33
36
|
"""
|
|
34
37
|
|
|
35
38
|
repeat: bool = True
|
|
36
39
|
"""
|
|
37
|
-
Whether the animation should repeat in a loop.
|
|
40
|
+
Whether the animation should repeat in a loop.
|
|
41
|
+
|
|
42
|
+
Note:
|
|
43
|
+
Has no effect if [`animate`][..] is `False`.
|
|
38
44
|
"""
|
|
39
45
|
|
|
40
46
|
reverse: bool = False
|
|
41
47
|
"""
|
|
42
|
-
Whether the animation should be played in reverse
|
|
43
|
-
|
|
44
|
-
|
|
48
|
+
Whether the animation should be played in reverse
|
|
49
|
+
(from start to end and then continuously from end to start).
|
|
50
|
+
|
|
51
|
+
Note:
|
|
52
|
+
Has no effect if [`animate`][..] or [`repeat`][..] is `False`.
|
|
45
53
|
"""
|
|
46
54
|
|
|
47
55
|
animate: bool = True
|
|
@@ -69,32 +77,35 @@ class Lottie(ft.ConstrainedControl):
|
|
|
69
77
|
The quality of the image layer.
|
|
70
78
|
"""
|
|
71
79
|
|
|
72
|
-
fit: Optional[ft.
|
|
80
|
+
fit: Optional[ft.BoxFit] = None
|
|
73
81
|
"""
|
|
74
|
-
Defines how to inscribe the Lottie composition
|
|
75
|
-
|
|
76
|
-
Value is of type [`ImageFit`](https://flet.dev/docs/reference/types/imagefit).
|
|
82
|
+
Defines how to inscribe the Lottie composition
|
|
83
|
+
into the space allocated during layout.
|
|
77
84
|
"""
|
|
78
85
|
|
|
79
|
-
headers: Optional[
|
|
86
|
+
headers: Optional[dict[str, str]] = None
|
|
80
87
|
"""
|
|
81
88
|
Headers for network requests.
|
|
82
89
|
"""
|
|
83
90
|
|
|
84
91
|
error_content: Optional[ft.Control] = None
|
|
85
92
|
"""
|
|
86
|
-
A control to display when an error occurs
|
|
87
|
-
|
|
93
|
+
A control to display when an error occurs
|
|
94
|
+
while loading the Lottie animation.
|
|
95
|
+
|
|
88
96
|
For more information on the error, see [`on_error`][..].
|
|
89
97
|
"""
|
|
90
98
|
|
|
91
|
-
on_error: ft.
|
|
99
|
+
on_error: Optional[ft.ControlEventHandler["Lottie"]] = None
|
|
92
100
|
"""
|
|
93
101
|
Fires when an error occurs while loading the Lottie animation.
|
|
94
|
-
|
|
95
|
-
The `data` property of the event handler argument
|
|
102
|
+
|
|
103
|
+
The [`data`][flet.Event.data] property of the event handler argument
|
|
104
|
+
contains information on the error.
|
|
96
105
|
"""
|
|
97
106
|
|
|
98
107
|
def before_update(self):
|
|
99
108
|
super().before_update()
|
|
100
|
-
assert self.src or self.src_base64,
|
|
109
|
+
assert self.src or self.src_base64, (
|
|
110
|
+
"at least one of src and src_base64 must be provided"
|
|
111
|
+
)
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
flet_lottie/__init__.py,sha256=
|
|
2
|
-
flet_lottie/lottie.py,sha256=
|
|
3
|
-
flet_lottie-0.2.0.
|
|
1
|
+
flet_lottie/__init__.py,sha256=vlxeJlQTV6GLTFzZHPrq2AaVPYoGq-vwzMA4usdq44E,49
|
|
2
|
+
flet_lottie/lottie.py,sha256=wzzabD94fkL271RfCiu-WRX2pIHaydLtm32-EMeSXeA,2623
|
|
3
|
+
flet_lottie-0.2.0.dev55.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
|
4
4
|
flutter/flet_lottie/CHANGELOG.md,sha256=-7pCYFGML9PyWTbSp2ZOQ6MM9bBaeYIk82Ngeuy3oNM,56
|
|
5
5
|
flutter/flet_lottie/LICENSE,sha256=QwcOLU5TJoTeUhuIXzhdCEEDDvorGiC6-3YTOl4TecE,11356
|
|
6
6
|
flutter/flet_lottie/README.md,sha256=OgI2ZU2SVP2IEyl49IASnC7Al17h1FQ035nKSP6UPaU,62
|
|
7
7
|
flutter/flet_lottie/analysis_options.yaml,sha256=32kjGAc-zF87inWaH5M46yGZWQDTwrwfvNLHeAocfG4,154
|
|
8
|
-
flutter/flet_lottie/pubspec.lock,sha256
|
|
9
|
-
flutter/flet_lottie/pubspec.yaml,sha256=
|
|
8
|
+
flutter/flet_lottie/pubspec.lock,sha256=-kS57uoI5IK_lNBy6NfjOVXaiAJK0U7Tf98WIxwGyTU,23274
|
|
9
|
+
flutter/flet_lottie/pubspec.yaml,sha256=5uoowxOHLukFO8AFSNkdFUeFdRRw_oGIEWwErWYbVQE,507
|
|
10
10
|
flutter/flet_lottie/lib/flet_lottie.dart,sha256=kvOuBQkwU9DRqcfAhwamrYXmy3uyOB48-R3rXVukAsI,66
|
|
11
11
|
flutter/flet_lottie/lib/src/extension.dart,sha256=AQFOiue9kMRMX5jn_YSmTKx44CYuoIsemLNT38CLjbw,347
|
|
12
12
|
flutter/flet_lottie/lib/src/lottie.dart,sha256=IWwIql3oUiTwE8CSdGsCPHGZBwwxyU7SSm0mhkkRdXQ,3971
|
|
13
|
-
flet_lottie-0.2.0.
|
|
14
|
-
flet_lottie-0.2.0.
|
|
15
|
-
flet_lottie-0.2.0.
|
|
16
|
-
flet_lottie-0.2.0.
|
|
13
|
+
flet_lottie-0.2.0.dev55.dist-info/METADATA,sha256=cWi_zZ8nBLTkkiJy6HXcEMVOY-p-CuNcuOmTFGUB48g,1929
|
|
14
|
+
flet_lottie-0.2.0.dev55.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
15
|
+
flet_lottie-0.2.0.dev55.dist-info/top_level.txt,sha256=RFKJcUq-1rW9i9tkjYL1AzMuJFXiAqoWK0YIjIG3Gj8,20
|
|
16
|
+
flet_lottie-0.2.0.dev55.dist-info/RECORD,,
|
flutter/flet_lottie/pubspec.lock
CHANGED
|
@@ -134,7 +134,7 @@ packages:
|
|
|
134
134
|
description:
|
|
135
135
|
path: "packages/flet"
|
|
136
136
|
ref: main
|
|
137
|
-
resolved-ref:
|
|
137
|
+
resolved-ref: cf8823c5d766ea7866480986aa3ee871f4091e78
|
|
138
138
|
url: "https://github.com/flet-dev/flet.git"
|
|
139
139
|
source: git
|
|
140
140
|
version: "0.70.0"
|
|
@@ -155,10 +155,10 @@ packages:
|
|
|
155
155
|
dependency: "direct dev"
|
|
156
156
|
description:
|
|
157
157
|
name: flutter_lints
|
|
158
|
-
sha256:
|
|
158
|
+
sha256: "9e8c3858111da373efc5aa341de011d9bd23e2c5c5e0c62bccf32438e192d7b1"
|
|
159
159
|
url: "https://pub.dev"
|
|
160
160
|
source: hosted
|
|
161
|
-
version: "
|
|
161
|
+
version: "3.0.2"
|
|
162
162
|
flutter_localizations:
|
|
163
163
|
dependency: transitive
|
|
164
164
|
description: flutter
|
|
@@ -266,10 +266,10 @@ packages:
|
|
|
266
266
|
dependency: transitive
|
|
267
267
|
description:
|
|
268
268
|
name: lints
|
|
269
|
-
sha256:
|
|
269
|
+
sha256: cbf8d4b858bb0134ef3ef87841abdf8d63bfc255c266b7bf6b39daa1085c4290
|
|
270
270
|
url: "https://pub.dev"
|
|
271
271
|
source: hosted
|
|
272
|
-
version: "
|
|
272
|
+
version: "3.0.0"
|
|
273
273
|
logging:
|
|
274
274
|
dependency: transitive
|
|
275
275
|
description:
|
|
@@ -751,10 +751,10 @@ packages:
|
|
|
751
751
|
dependency: transitive
|
|
752
752
|
description:
|
|
753
753
|
name: window_manager
|
|
754
|
-
sha256: "
|
|
754
|
+
sha256: "7eb6d6c4164ec08e1bf978d6e733f3cebe792e2a23fb07cbca25c2872bfdbdcd"
|
|
755
755
|
url: "https://pub.dev"
|
|
756
756
|
source: hosted
|
|
757
|
-
version: "0.5.
|
|
757
|
+
version: "0.5.1"
|
|
758
758
|
window_to_front:
|
|
759
759
|
dependency: transitive
|
|
760
760
|
description:
|
flutter/flet_lottie/pubspec.yaml
CHANGED
|
File without changes
|
|
File without changes
|
|
File without changes
|