htmy 0.8.0__py3-none-any.whl → 0.8.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.
Potentially problematic release.
This version of htmy might be problematic. Click here for more details.
- htmy/__init__.py +1 -0
- htmy/renderer/baseline.py +2 -0
- htmy/renderer/default.py +2 -0
- htmy/typing.py +21 -0
- {htmy-0.8.0.dist-info → htmy-0.8.1.dist-info}/METADATA +1 -1
- {htmy-0.8.0.dist-info → htmy-0.8.1.dist-info}/RECORD +8 -8
- {htmy-0.8.0.dist-info → htmy-0.8.1.dist-info}/LICENSE +0 -0
- {htmy-0.8.0.dist-info → htmy-0.8.1.dist-info}/WHEEL +0 -0
htmy/__init__.py
CHANGED
|
@@ -30,6 +30,7 @@ from .typing import HTMYComponentType as HTMYComponentType
|
|
|
30
30
|
from .typing import MutableContext as MutableContext
|
|
31
31
|
from .typing import Properties as Properties
|
|
32
32
|
from .typing import PropertyValue as PropertyValue
|
|
33
|
+
from .typing import RendererType as RendererType
|
|
33
34
|
from .typing import SyncComponent as SyncComponent
|
|
34
35
|
from .typing import SyncContextProvider as SyncContextProvider
|
|
35
36
|
from .utils import as_component_sequence as as_component_sequence
|
htmy/renderer/baseline.py
CHANGED
htmy/renderer/default.py
CHANGED
htmy/typing.py
CHANGED
|
@@ -65,6 +65,27 @@ ComponentSequence: TypeAlias = list[ComponentType] | tuple[ComponentType, ...]
|
|
|
65
65
|
Component: TypeAlias = ComponentType | ComponentSequence
|
|
66
66
|
"""Component type: a single component or a sequence of components."""
|
|
67
67
|
|
|
68
|
+
|
|
69
|
+
# -- Renderer
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
class RendererType(Protocol):
|
|
73
|
+
"""Protocol definition for `htmy` renderers."""
|
|
74
|
+
|
|
75
|
+
async def render(self, component: Component, context: Context | None = None) -> str:
|
|
76
|
+
"""
|
|
77
|
+
Renders the given component.
|
|
78
|
+
|
|
79
|
+
Arguments:
|
|
80
|
+
component: The component to render.
|
|
81
|
+
context: An optional rendering context.
|
|
82
|
+
|
|
83
|
+
Returns:
|
|
84
|
+
The rendered string.
|
|
85
|
+
"""
|
|
86
|
+
...
|
|
87
|
+
|
|
88
|
+
|
|
68
89
|
# -- Context providers
|
|
69
90
|
|
|
70
91
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
htmy/__init__.py,sha256=
|
|
1
|
+
htmy/__init__.py,sha256=h1UOBOdcmwzkelpu2uGZXkXO_XLtXYiU6pW1-3kCj7k,1929
|
|
2
2
|
htmy/core.py,sha256=mvNbxTRS8HNnjMSwe4NEJdL1KF19pJImF4Ciip6837I,15484
|
|
3
3
|
htmy/etree.py,sha256=3znZCYQ5xbNqyXYSYFkUh6M22QLWMYWhTNjUcgpjCLc,4051
|
|
4
4
|
htmy/function_component.py,sha256=iSp5cGrErmIsc-VfNq053_J2m-Nuu_k2xK9UxvEnlw8,12431
|
|
@@ -10,12 +10,12 @@ htmy/md/core.py,sha256=Xu-8xGAOGqSYLGPOib0Wn-blmyQBHl3MrAOza_w__Y8,4456
|
|
|
10
10
|
htmy/md/typing.py,sha256=LF-AEvo7FCW2KumyR5l55rsXizV2E4AHVLKFf6lApgM,762
|
|
11
11
|
htmy/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
12
12
|
htmy/renderer/__init__.py,sha256=xnP_aaoK-pTok-69wi8O_xlsgjoKTzWd2lIIeHGcuaY,226
|
|
13
|
-
htmy/renderer/baseline.py,sha256=
|
|
14
|
-
htmy/renderer/default.py,sha256=
|
|
13
|
+
htmy/renderer/baseline.py,sha256=1cE06kEqU_fNXWIo_3Hea88BOwL37NmfY5nnQnYEYqY,4336
|
|
14
|
+
htmy/renderer/default.py,sha256=kFfgWPF7I3h7EmIDZamVeDNvI6ngnxfLIAnMUsWiMas,10917
|
|
15
15
|
htmy/snippet.py,sha256=9-ltfs4rugv6kFNzAY0PYNP3YI3xvJG8lkxEnYcCYWw,10538
|
|
16
|
-
htmy/typing.py,sha256=
|
|
16
|
+
htmy/typing.py,sha256=kRi_rkQQ5CNL1TyUhEVHjTh96zHpBZlNxqr2TTTfyzI,3546
|
|
17
17
|
htmy/utils.py,sha256=Kp0j9G8CBeRiyFGmz-CoDiLtXHfpvHzlTVsWeDhIebM,1935
|
|
18
|
-
htmy-0.8.
|
|
19
|
-
htmy-0.8.
|
|
20
|
-
htmy-0.8.
|
|
21
|
-
htmy-0.8.
|
|
18
|
+
htmy-0.8.1.dist-info/LICENSE,sha256=rFtoGU_3c_rlacXgOZapTHfMErN-JFPT5Bq_col4bqI,1067
|
|
19
|
+
htmy-0.8.1.dist-info/METADATA,sha256=EbS4l5cflMryJg1fjENS2dspfDdNrE-tG-l4cjeOdz8,20123
|
|
20
|
+
htmy-0.8.1.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
|
|
21
|
+
htmy-0.8.1.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|