pythonnative 0.21.0__py3-none-any.whl → 0.22.1__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.
- pythonnative/__init__.py +14 -3
- pythonnative/animated.py +420 -135
- pythonnative/cli/pn.py +1 -1
- pythonnative/components.py +525 -241
- pythonnative/events.py +210 -0
- pythonnative/gestures.py +875 -0
- pythonnative/hooks.py +3 -3
- pythonnative/hot_reload.py +4 -4
- pythonnative/layout.py +464 -150
- pythonnative/mutations.py +130 -0
- pythonnative/native_modules/camera.py +1 -1
- pythonnative/native_modules/haptics.py +2 -2
- pythonnative/native_modules/location.py +1 -1
- pythonnative/native_modules/permissions.py +2 -2
- pythonnative/native_modules/secure_store.py +1 -1
- pythonnative/native_views/__init__.py +161 -97
- pythonnative/native_views/android.py +1064 -1158
- pythonnative/native_views/base.py +109 -19
- pythonnative/native_views/desktop.py +465 -422
- pythonnative/native_views/ios.py +1930 -1928
- pythonnative/navigation.py +4 -4
- pythonnative/net.py +3 -3
- pythonnative/platform.py +1 -1
- pythonnative/platform_metrics.py +5 -5
- pythonnative/preview.py +3 -3
- pythonnative/project/android.py +2 -2
- pythonnative/project/builder.py +1 -1
- pythonnative/project/config.py +3 -3
- pythonnative/project/doctor.py +2 -2
- pythonnative/project/icons.py +1 -1
- pythonnative/project/ios.py +1 -1
- pythonnative/project/permissions.py +2 -2
- pythonnative/project/runtime_assets.py +3 -3
- pythonnative/reconciler.py +545 -475
- pythonnative/runtime.py +8 -8
- pythonnative/screen.py +10 -7
- pythonnative/sdk/_components.py +3 -3
- pythonnative/storage.py +3 -3
- pythonnative/style.py +1 -1
- pythonnative/templates/android_template/app/build.gradle +2 -0
- pythonnative/templates/ios_template/ios_template.xcodeproj/project.pbxproj +2 -2
- pythonnative/templates/ios_template/ios_templateUITests/ios_templateUITests.swift +1 -1
- {pythonnative-0.21.0.dist-info → pythonnative-0.22.1.dist-info}/METADATA +14 -11
- {pythonnative-0.21.0.dist-info → pythonnative-0.22.1.dist-info}/RECORD +48 -46
- pythonnative/templates/android_template/app/src/main/java/com/pythonnative/android_template/PNVirtualListView.java +0 -129
- {pythonnative-0.21.0.dist-info → pythonnative-0.22.1.dist-info}/WHEEL +0 -0
- {pythonnative-0.21.0.dist-info → pythonnative-0.22.1.dist-info}/entry_points.txt +0 -0
- {pythonnative-0.21.0.dist-info → pythonnative-0.22.1.dist-info}/licenses/LICENSE +0 -0
- {pythonnative-0.21.0.dist-info → pythonnative-0.22.1.dist-info}/top_level.txt +0 -0
pythonnative/__init__.py
CHANGED
|
@@ -26,7 +26,16 @@ Key building blocks:
|
|
|
26
26
|
PythonNative ships a fully-typed [`Style`][pythonnative.style.Style]
|
|
27
27
|
TypedDict so editors and ``mypy`` validate every key as you type.
|
|
28
28
|
- **Animations** use the ``Animated`` namespace, modeled on React
|
|
29
|
-
Native's animation API.
|
|
29
|
+
Native's animation API. Animations are driven natively (Core
|
|
30
|
+
Animation / ``ViewPropertyAnimator``) whenever possible.
|
|
31
|
+
- **Gestures** attach to any view via the ``gestures=`` prop using
|
|
32
|
+
descriptors from ``pythonnative.gestures``
|
|
33
|
+
([`Tap`][pythonnative.gestures.Tap],
|
|
34
|
+
[`LongPress`][pythonnative.gestures.LongPress],
|
|
35
|
+
[`Pan`][pythonnative.gestures.Pan],
|
|
36
|
+
[`Swipe`][pythonnative.gestures.Swipe],
|
|
37
|
+
[`Pinch`][pythonnative.gestures.Pinch],
|
|
38
|
+
[`Rotation`][pythonnative.gestures.Rotation]).
|
|
30
39
|
- **Custom native components** can be authored with the
|
|
31
40
|
``pythonnative.sdk`` package: define a typed
|
|
32
41
|
[`Props`][pythonnative.sdk.Props] dataclass, implement a
|
|
@@ -51,9 +60,9 @@ Example:
|
|
|
51
60
|
```
|
|
52
61
|
"""
|
|
53
62
|
|
|
54
|
-
__version__ = "0.
|
|
63
|
+
__version__ = "0.22.1"
|
|
55
64
|
|
|
56
|
-
from . import runtime, sdk
|
|
65
|
+
from . import gestures, runtime, sdk
|
|
57
66
|
from .alerts import Alert
|
|
58
67
|
from .animated import Animated, AnimatedValue, use_animated_value
|
|
59
68
|
from .components import (
|
|
@@ -321,6 +330,8 @@ __all__ = [
|
|
|
321
330
|
"Animated",
|
|
322
331
|
"AnimatedValue",
|
|
323
332
|
"use_animated_value",
|
|
333
|
+
# Gestures
|
|
334
|
+
"gestures",
|
|
324
335
|
# Imperative
|
|
325
336
|
"Alert",
|
|
326
337
|
# Native modules
|