reflex 0.5.2a1__py3-none-any.whl → 0.5.3__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 reflex might be problematic. Click here for more details.
- reflex/.templates/web/postcss.config.js +1 -0
- reflex/.templates/web/styles/tailwind.css +4 -1
- reflex/__init__.py +298 -204
- reflex/__init__.pyi +196 -157
- reflex/app.py +13 -2
- reflex/compiler/compiler.py +1 -1
- reflex/components/__init__.py +31 -17
- reflex/components/__init__.pyi +26 -0
- reflex/components/base/__init__.py +25 -9
- reflex/components/base/__init__.pyi +26 -0
- reflex/components/base/fragment.py +3 -0
- reflex/components/base/fragment.pyi +2 -0
- reflex/components/base/head.py +3 -0
- reflex/components/base/head.pyi +2 -0
- reflex/components/base/script.py +3 -0
- reflex/components/base/script.pyi +2 -0
- reflex/components/core/__init__.py +51 -37
- reflex/components/core/__init__.pyi +39 -0
- reflex/components/core/banner.py +7 -1
- reflex/components/core/banner.pyi +6 -1
- reflex/components/core/debounce.py +3 -0
- reflex/components/core/debounce.pyi +2 -0
- reflex/components/core/foreach.py +3 -0
- reflex/components/core/html.py +4 -1
- reflex/components/core/html.pyi +2 -0
- reflex/components/core/match.py +3 -0
- reflex/components/core/responsive.py +1 -1
- reflex/components/core/upload.py +5 -2
- reflex/components/core/upload.pyi +4 -2
- reflex/components/datadisplay/__init__.py +17 -8
- reflex/components/datadisplay/__init__.pyi +14 -0
- reflex/components/datadisplay/code.py +3 -0
- reflex/components/datadisplay/code.pyi +2 -0
- reflex/components/datadisplay/dataeditor.py +4 -0
- reflex/components/datadisplay/dataeditor.pyi +3 -0
- reflex/components/el/__init__.py +15 -1
- reflex/components/el/__init__.pyi +228 -0
- reflex/components/el/elements/__init__.py +129 -220
- reflex/components/el/elements/__init__.pyi +342 -0
- reflex/components/el/elements/forms.py +15 -0
- reflex/components/el/elements/forms.pyi +14 -0
- reflex/components/el/elements/inline.py +30 -0
- reflex/components/el/elements/inline.pyi +29 -0
- reflex/components/el/elements/media.py +16 -0
- reflex/components/el/elements/media.pyi +15 -0
- reflex/components/el/elements/metadata.py +7 -0
- reflex/components/el/elements/metadata.pyi +6 -0
- reflex/components/el/elements/other.py +9 -0
- reflex/components/el/elements/other.pyi +8 -0
- reflex/components/el/elements/scripts.py +5 -0
- reflex/components/el/elements/scripts.pyi +4 -0
- reflex/components/el/elements/sectioning.py +17 -0
- reflex/components/el/elements/sectioning.pyi +16 -0
- reflex/components/el/elements/tables.py +12 -0
- reflex/components/el/elements/tables.pyi +11 -0
- reflex/components/el/elements/typography.py +16 -0
- reflex/components/el/elements/typography.pyi +15 -0
- reflex/components/moment/__init__.py +1 -1
- reflex/components/plotly/plotly.py +185 -7
- reflex/components/plotly/plotly.pyi +62 -4
- reflex/components/radix/__init__.py +14 -2
- reflex/components/radix/__init__.pyi +73 -0
- reflex/components/radix/primitives/__init__.py +13 -5
- reflex/components/radix/primitives/__init__.pyi +11 -0
- reflex/components/radix/themes/__init__.py +20 -6
- reflex/components/radix/themes/__init__.pyi +13 -0
- reflex/components/radix/themes/base.py +26 -20
- reflex/components/radix/themes/base.pyi +4 -1
- reflex/components/radix/themes/color_mode.py +3 -1
- reflex/components/radix/themes/color_mode.pyi +3 -1
- reflex/components/radix/themes/components/__init__.py +11 -79
- reflex/components/radix/themes/components/__init__.pyi +44 -0
- reflex/components/radix/themes/components/alert_dialog.py +2 -2
- reflex/components/radix/themes/components/alert_dialog.pyi +2 -2
- reflex/components/radix/themes/components/badge.py +2 -2
- reflex/components/radix/themes/components/badge.pyi +2 -2
- reflex/components/radix/themes/components/button.py +2 -2
- reflex/components/radix/themes/components/button.pyi +2 -2
- reflex/components/radix/themes/components/callout.py +4 -4
- reflex/components/radix/themes/components/callout.pyi +4 -4
- reflex/components/radix/themes/components/card.py +2 -2
- reflex/components/radix/themes/components/card.pyi +2 -2
- reflex/components/radix/themes/components/dialog.py +2 -2
- reflex/components/radix/themes/components/dialog.pyi +2 -2
- reflex/components/radix/themes/components/hover_card.py +2 -2
- reflex/components/radix/themes/components/hover_card.pyi +2 -2
- reflex/components/radix/themes/components/icon_button.py +2 -2
- reflex/components/radix/themes/components/icon_button.pyi +2 -2
- reflex/components/radix/themes/components/inset.py +2 -2
- reflex/components/radix/themes/components/inset.pyi +2 -2
- reflex/components/radix/themes/components/popover.py +2 -2
- reflex/components/radix/themes/components/popover.pyi +2 -2
- reflex/components/radix/themes/components/table.py +8 -8
- reflex/components/radix/themes/components/table.pyi +8 -8
- reflex/components/radix/themes/components/text_area.py +11 -2
- reflex/components/radix/themes/components/text_area.pyi +18 -3
- reflex/components/radix/themes/components/text_field.py +3 -3
- reflex/components/radix/themes/components/text_field.pyi +3 -3
- reflex/components/radix/themes/layout/__init__.py +12 -38
- reflex/components/radix/themes/layout/__init__.pyi +21 -0
- reflex/components/radix/themes/layout/box.py +5 -2
- reflex/components/radix/themes/layout/box.pyi +4 -2
- reflex/components/radix/themes/layout/center.py +3 -0
- reflex/components/radix/themes/layout/center.pyi +2 -0
- reflex/components/radix/themes/layout/container.py +5 -2
- reflex/components/radix/themes/layout/container.pyi +4 -2
- reflex/components/radix/themes/layout/flex.py +5 -2
- reflex/components/radix/themes/layout/flex.pyi +4 -2
- reflex/components/radix/themes/layout/grid.py +5 -2
- reflex/components/radix/themes/layout/grid.pyi +4 -2
- reflex/components/radix/themes/layout/list.py +14 -0
- reflex/components/radix/themes/layout/list.pyi +3 -0
- reflex/components/radix/themes/layout/section.py +7 -4
- reflex/components/radix/themes/layout/section.pyi +5 -3
- reflex/components/radix/themes/layout/spacer.py +3 -0
- reflex/components/radix/themes/layout/spacer.pyi +2 -0
- reflex/components/radix/themes/layout/stack.py +5 -0
- reflex/components/radix/themes/layout/stack.pyi +4 -0
- reflex/components/radix/themes/typography/__init__.py +11 -16
- reflex/components/radix/themes/typography/__init__.pyi +12 -0
- reflex/components/radix/themes/typography/blockquote.py +5 -2
- reflex/components/radix/themes/typography/blockquote.pyi +4 -2
- reflex/components/radix/themes/typography/code.py +5 -2
- reflex/components/radix/themes/typography/code.pyi +4 -2
- reflex/components/radix/themes/typography/heading.py +5 -2
- reflex/components/radix/themes/typography/heading.pyi +4 -2
- reflex/components/radix/themes/typography/link.py +3 -0
- reflex/components/radix/themes/typography/link.pyi +2 -0
- reflex/components/radix/themes/typography/text.py +6 -6
- reflex/components/radix/themes/typography/text.pyi +6 -6
- reflex/components/recharts/__init__.py +114 -104
- reflex/components/recharts/__init__.pyi +106 -0
- reflex/components/recharts/cartesian.py +17 -0
- reflex/components/recharts/cartesian.pyi +16 -0
- reflex/components/recharts/charts.py +12 -0
- reflex/components/recharts/charts.pyi +11 -0
- reflex/components/recharts/general.py +7 -0
- reflex/components/recharts/general.pyi +6 -0
- reflex/components/recharts/polar.py +11 -0
- reflex/components/recharts/polar.pyi +9 -0
- reflex/config.py +3 -0
- reflex/constants/__init__.py +0 -2
- reflex/constants/base.py +5 -1
- reflex/constants/installer.py +2 -1
- reflex/experimental/__init__.py +2 -0
- reflex/experimental/assets.py +56 -0
- reflex/experimental/client_state.py +4 -2
- reflex/experimental/hooks.py +8 -6
- reflex/experimental/layout.py +3 -1
- reflex/state.py +54 -4
- reflex/utils/exec.py +8 -0
- reflex/utils/format.py +8 -4
- reflex/utils/lazy_loader.py +33 -0
- reflex/utils/prerequisites.py +1 -14
- reflex/utils/pyi_generator.py +71 -20
- reflex/utils/serializers.py +9 -4
- reflex/utils/types.py +3 -1
- reflex/vars.py +92 -6
- reflex/vars.pyi +16 -0
- {reflex-0.5.2a1.dist-info → reflex-0.5.3.dist-info}/METADATA +2 -1
- {reflex-0.5.2a1.dist-info → reflex-0.5.3.dist-info}/RECORD +164 -151
- reflex/config.pyi +0 -112
- reflex/constants/base.pyi +0 -94
- {reflex-0.5.2a1.dist-info → reflex-0.5.3.dist-info}/LICENSE +0 -0
- {reflex-0.5.2a1.dist-info → reflex-0.5.3.dist-info}/WHEEL +0 -0
- {reflex-0.5.2a1.dist-info → reflex-0.5.3.dist-info}/entry_points.txt +0 -0
|
@@ -8,14 +8,14 @@ from reflex.vars import Var, BaseVar, ComputedVar
|
|
|
8
8
|
from reflex.event import EventChain, EventHandler, EventSpec
|
|
9
9
|
from reflex.style import Style
|
|
10
10
|
from typing import Dict, Literal
|
|
11
|
-
from reflex import
|
|
11
|
+
from reflex.components.el import elements
|
|
12
12
|
from reflex.vars import Var
|
|
13
13
|
from ..base import LiteralAlign, LiteralJustify, LiteralSpacing, RadixThemesComponent
|
|
14
14
|
|
|
15
15
|
LiteralFlexDirection = Literal["row", "column", "row-reverse", "column-reverse"]
|
|
16
16
|
LiteralFlexWrap = Literal["nowrap", "wrap", "wrap-reverse"]
|
|
17
17
|
|
|
18
|
-
class Flex(
|
|
18
|
+
class Flex(elements.Div, RadixThemesComponent):
|
|
19
19
|
@overload
|
|
20
20
|
@classmethod
|
|
21
21
|
def create( # type: ignore
|
|
@@ -186,3 +186,5 @@ class Flex(el.Div, RadixThemesComponent):
|
|
|
186
186
|
A new component instance.
|
|
187
187
|
"""
|
|
188
188
|
...
|
|
189
|
+
|
|
190
|
+
flex = Flex.create
|
|
@@ -4,7 +4,7 @@ from __future__ import annotations
|
|
|
4
4
|
|
|
5
5
|
from typing import Dict, Literal
|
|
6
6
|
|
|
7
|
-
from reflex import
|
|
7
|
+
from reflex.components.el import elements
|
|
8
8
|
from reflex.vars import Var
|
|
9
9
|
|
|
10
10
|
from ..base import (
|
|
@@ -17,7 +17,7 @@ from ..base import (
|
|
|
17
17
|
LiteralGridFlow = Literal["row", "column", "dense", "row-dense", "column-dense"]
|
|
18
18
|
|
|
19
19
|
|
|
20
|
-
class Grid(
|
|
20
|
+
class Grid(elements.Div, RadixThemesComponent):
|
|
21
21
|
"""Component for creating grid layouts."""
|
|
22
22
|
|
|
23
23
|
tag = "Grid"
|
|
@@ -55,3 +55,6 @@ class Grid(el.Div, RadixThemesComponent):
|
|
|
55
55
|
"spacing_x": "gap_x",
|
|
56
56
|
"spacing_y": "gap_y",
|
|
57
57
|
}
|
|
58
|
+
|
|
59
|
+
|
|
60
|
+
grid = Grid.create
|
|
@@ -8,13 +8,13 @@ from reflex.vars import Var, BaseVar, ComputedVar
|
|
|
8
8
|
from reflex.event import EventChain, EventHandler, EventSpec
|
|
9
9
|
from reflex.style import Style
|
|
10
10
|
from typing import Dict, Literal
|
|
11
|
-
from reflex import
|
|
11
|
+
from reflex.components.el import elements
|
|
12
12
|
from reflex.vars import Var
|
|
13
13
|
from ..base import LiteralAlign, LiteralJustify, LiteralSpacing, RadixThemesComponent
|
|
14
14
|
|
|
15
15
|
LiteralGridFlow = Literal["row", "column", "dense", "row-dense", "column-dense"]
|
|
16
16
|
|
|
17
|
-
class Grid(
|
|
17
|
+
class Grid(elements.Div, RadixThemesComponent):
|
|
18
18
|
@overload
|
|
19
19
|
@classmethod
|
|
20
20
|
def create( # type: ignore
|
|
@@ -196,3 +196,5 @@ class Grid(el.Div, RadixThemesComponent):
|
|
|
196
196
|
A new component instance.
|
|
197
197
|
"""
|
|
198
198
|
...
|
|
199
|
+
|
|
200
|
+
grid = Grid.create
|
|
@@ -184,3 +184,17 @@ class List(ComponentNamespace):
|
|
|
184
184
|
|
|
185
185
|
|
|
186
186
|
list_ns = List()
|
|
187
|
+
list_item = list_ns.item
|
|
188
|
+
ordered_list = list_ns.ordered
|
|
189
|
+
unordered_list = list_ns.unordered
|
|
190
|
+
|
|
191
|
+
|
|
192
|
+
def __getattr__(name):
|
|
193
|
+
# special case for when accessing list to avoid shadowing
|
|
194
|
+
# python's built in list object.
|
|
195
|
+
if name == "list":
|
|
196
|
+
return list_ns
|
|
197
|
+
try:
|
|
198
|
+
return globals()[name]
|
|
199
|
+
except KeyError:
|
|
200
|
+
raise AttributeError(f"module '{__name__} has no attribute '{name}'") from None
|
|
@@ -3,7 +3,7 @@ from __future__ import annotations
|
|
|
3
3
|
|
|
4
4
|
from typing import Literal
|
|
5
5
|
|
|
6
|
-
from reflex import
|
|
6
|
+
from reflex.components.el import elements
|
|
7
7
|
from reflex.vars import Var
|
|
8
8
|
|
|
9
9
|
from ..base import RadixThemesComponent
|
|
@@ -11,10 +11,13 @@ from ..base import RadixThemesComponent
|
|
|
11
11
|
LiteralSectionSize = Literal["1", "2", "3"]
|
|
12
12
|
|
|
13
13
|
|
|
14
|
-
class Section(
|
|
14
|
+
class Section(elements.Section, RadixThemesComponent):
|
|
15
15
|
"""Denotes a section of page content."""
|
|
16
16
|
|
|
17
17
|
tag = "Section"
|
|
18
18
|
|
|
19
|
-
# The size of the section: "1" - "3" (default "
|
|
20
|
-
size: Var[LiteralSectionSize]
|
|
19
|
+
# The size of the section: "1" - "3" (default "2")
|
|
20
|
+
size: Var[LiteralSectionSize] = Var.create_safe("2")
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
section = Section.create
|
|
@@ -8,13 +8,13 @@ from reflex.vars import Var, BaseVar, ComputedVar
|
|
|
8
8
|
from reflex.event import EventChain, EventHandler, EventSpec
|
|
9
9
|
from reflex.style import Style
|
|
10
10
|
from typing import Literal
|
|
11
|
-
from reflex import
|
|
11
|
+
from reflex.components.el import elements
|
|
12
12
|
from reflex.vars import Var
|
|
13
13
|
from ..base import RadixThemesComponent
|
|
14
14
|
|
|
15
15
|
LiteralSectionSize = Literal["1", "2", "3"]
|
|
16
16
|
|
|
17
|
-
class Section(
|
|
17
|
+
class Section(elements.Section, RadixThemesComponent):
|
|
18
18
|
@overload
|
|
19
19
|
@classmethod
|
|
20
20
|
def create( # type: ignore
|
|
@@ -123,7 +123,7 @@ class Section(el.Section, RadixThemesComponent):
|
|
|
123
123
|
|
|
124
124
|
Args:
|
|
125
125
|
*children: Child components.
|
|
126
|
-
size: The size of the section: "1" - "3" (default "
|
|
126
|
+
size: The size of the section: "1" - "3" (default "2")
|
|
127
127
|
access_key: Provides a hint for generating a keyboard shortcut for the current element.
|
|
128
128
|
auto_capitalize: Controls whether and how text input is automatically capitalized as it is entered/edited by the user.
|
|
129
129
|
content_editable: Indicates whether the element's content is editable.
|
|
@@ -152,3 +152,5 @@ class Section(el.Section, RadixThemesComponent):
|
|
|
152
152
|
A new component instance.
|
|
153
153
|
"""
|
|
154
154
|
...
|
|
155
|
+
|
|
156
|
+
section = Section.create
|
|
@@ -1,20 +1,15 @@
|
|
|
1
1
|
"""Typographic components."""
|
|
2
|
+
from __future__ import annotations
|
|
2
3
|
|
|
3
|
-
from
|
|
4
|
-
from .
|
|
5
|
-
from .heading import Heading
|
|
6
|
-
from .link import Link
|
|
7
|
-
from .text import text
|
|
4
|
+
from reflex import RADIX_THEMES_TYPOGRAPHY_MAPPING
|
|
5
|
+
from reflex.utils import lazy_loader
|
|
8
6
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
7
|
+
_SUBMOD_ATTRS: dict[str, list[str]] = {
|
|
8
|
+
"".join(k.split("components.radix.themes.typography.")[-1]): v
|
|
9
|
+
for k, v in RADIX_THEMES_TYPOGRAPHY_MAPPING.items()
|
|
10
|
+
}
|
|
13
11
|
|
|
14
|
-
__all__ =
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
"link",
|
|
19
|
-
"text",
|
|
20
|
-
]
|
|
12
|
+
__getattr__, __dir__, __all__ = lazy_loader.attach(
|
|
13
|
+
__name__,
|
|
14
|
+
submod_attrs=_SUBMOD_ATTRS,
|
|
15
|
+
)
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"""Stub file for reflex/components/radix/themes/typography/__init__.py"""
|
|
2
|
+
# ------------------- DO NOT EDIT ----------------------
|
|
3
|
+
# This file was generated by `reflex/utils/pyi_generator.py`!
|
|
4
|
+
# ------------------------------------------------------
|
|
5
|
+
|
|
6
|
+
from .blockquote import blockquote as blockquote
|
|
7
|
+
from .code import code as code
|
|
8
|
+
from .heading import heading as heading
|
|
9
|
+
from .link import link as link
|
|
10
|
+
from .text import text as text
|
|
11
|
+
from reflex import RADIX_THEMES_TYPOGRAPHY_MAPPING
|
|
12
|
+
from reflex.utils import lazy_loader
|
|
@@ -4,7 +4,7 @@ https://www.radix-ui.com/themes/docs/theme/typography
|
|
|
4
4
|
"""
|
|
5
5
|
from __future__ import annotations
|
|
6
6
|
|
|
7
|
-
from reflex import
|
|
7
|
+
from reflex.components.el import elements
|
|
8
8
|
from reflex.vars import Var
|
|
9
9
|
|
|
10
10
|
from ..base import (
|
|
@@ -17,7 +17,7 @@ from .base import (
|
|
|
17
17
|
)
|
|
18
18
|
|
|
19
19
|
|
|
20
|
-
class Blockquote(
|
|
20
|
+
class Blockquote(elements.Blockquote, RadixThemesComponent):
|
|
21
21
|
"""A block level extended quotation."""
|
|
22
22
|
|
|
23
23
|
tag = "Blockquote"
|
|
@@ -33,3 +33,6 @@ class Blockquote(el.Blockquote, RadixThemesComponent):
|
|
|
33
33
|
|
|
34
34
|
# Whether to render the text with higher contrast color
|
|
35
35
|
high_contrast: Var[bool]
|
|
36
|
+
|
|
37
|
+
|
|
38
|
+
blockquote = Blockquote.create
|
|
@@ -7,12 +7,12 @@ from typing import Any, Dict, Literal, Optional, Union, overload
|
|
|
7
7
|
from reflex.vars import Var, BaseVar, ComputedVar
|
|
8
8
|
from reflex.event import EventChain, EventHandler, EventSpec
|
|
9
9
|
from reflex.style import Style
|
|
10
|
-
from reflex import
|
|
10
|
+
from reflex.components.el import elements
|
|
11
11
|
from reflex.vars import Var
|
|
12
12
|
from ..base import LiteralAccentColor, RadixThemesComponent
|
|
13
13
|
from .base import LiteralTextSize, LiteralTextWeight
|
|
14
14
|
|
|
15
|
-
class Blockquote(
|
|
15
|
+
class Blockquote(elements.Blockquote, RadixThemesComponent):
|
|
16
16
|
@overload
|
|
17
17
|
@classmethod
|
|
18
18
|
def create( # type: ignore
|
|
@@ -227,3 +227,5 @@ class Blockquote(el.Blockquote, RadixThemesComponent):
|
|
|
227
227
|
A new component instance.
|
|
228
228
|
"""
|
|
229
229
|
...
|
|
230
|
+
|
|
231
|
+
blockquote = Blockquote.create
|
|
@@ -4,7 +4,7 @@ https://www.radix-ui.com/themes/docs/theme/typography
|
|
|
4
4
|
"""
|
|
5
5
|
from __future__ import annotations
|
|
6
6
|
|
|
7
|
-
from reflex import
|
|
7
|
+
from reflex.components.el import elements
|
|
8
8
|
from reflex.vars import Var
|
|
9
9
|
|
|
10
10
|
from ..base import (
|
|
@@ -18,7 +18,7 @@ from .base import (
|
|
|
18
18
|
)
|
|
19
19
|
|
|
20
20
|
|
|
21
|
-
class Code(
|
|
21
|
+
class Code(elements.Code, RadixThemesComponent):
|
|
22
22
|
"""A block level extended quotation."""
|
|
23
23
|
|
|
24
24
|
tag = "Code"
|
|
@@ -37,3 +37,6 @@ class Code(el.Code, RadixThemesComponent):
|
|
|
37
37
|
|
|
38
38
|
# Whether to render the text with higher contrast color
|
|
39
39
|
high_contrast: Var[bool]
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
code = Code.create
|
|
@@ -7,12 +7,12 @@ from typing import Any, Dict, Literal, Optional, Union, overload
|
|
|
7
7
|
from reflex.vars import Var, BaseVar, ComputedVar
|
|
8
8
|
from reflex.event import EventChain, EventHandler, EventSpec
|
|
9
9
|
from reflex.style import Style
|
|
10
|
-
from reflex import
|
|
10
|
+
from reflex.components.el import elements
|
|
11
11
|
from reflex.vars import Var
|
|
12
12
|
from ..base import LiteralAccentColor, LiteralVariant, RadixThemesComponent
|
|
13
13
|
from .base import LiteralTextSize, LiteralTextWeight
|
|
14
14
|
|
|
15
|
-
class Code(
|
|
15
|
+
class Code(elements.Code, RadixThemesComponent):
|
|
16
16
|
@overload
|
|
17
17
|
@classmethod
|
|
18
18
|
def create( # type: ignore
|
|
@@ -232,3 +232,5 @@ class Code(el.Code, RadixThemesComponent):
|
|
|
232
232
|
A new component instance.
|
|
233
233
|
"""
|
|
234
234
|
...
|
|
235
|
+
|
|
236
|
+
code = Code.create
|
|
@@ -4,7 +4,7 @@ https://www.radix-ui.com/themes/docs/theme/typography
|
|
|
4
4
|
"""
|
|
5
5
|
from __future__ import annotations
|
|
6
6
|
|
|
7
|
-
from reflex import
|
|
7
|
+
from reflex.components.el import elements
|
|
8
8
|
from reflex.vars import Var
|
|
9
9
|
|
|
10
10
|
from ..base import (
|
|
@@ -19,7 +19,7 @@ from .base import (
|
|
|
19
19
|
)
|
|
20
20
|
|
|
21
21
|
|
|
22
|
-
class Heading(
|
|
22
|
+
class Heading(elements.H1, RadixThemesComponent):
|
|
23
23
|
"""A foundational text primitive based on the <span> element."""
|
|
24
24
|
|
|
25
25
|
tag = "Heading"
|
|
@@ -47,3 +47,6 @@ class Heading(el.H1, RadixThemesComponent):
|
|
|
47
47
|
|
|
48
48
|
# Whether to render the text with higher contrast color
|
|
49
49
|
high_contrast: Var[bool]
|
|
50
|
+
|
|
51
|
+
|
|
52
|
+
heading = Heading.create
|
|
@@ -7,12 +7,12 @@ from typing import Any, Dict, Literal, Optional, Union, overload
|
|
|
7
7
|
from reflex.vars import Var, BaseVar, ComputedVar
|
|
8
8
|
from reflex.event import EventChain, EventHandler, EventSpec
|
|
9
9
|
from reflex.style import Style
|
|
10
|
-
from reflex import
|
|
10
|
+
from reflex.components.el import elements
|
|
11
11
|
from reflex.vars import Var
|
|
12
12
|
from ..base import LiteralAccentColor, RadixThemesComponent
|
|
13
13
|
from .base import LiteralTextAlign, LiteralTextSize, LiteralTextTrim, LiteralTextWeight
|
|
14
14
|
|
|
15
|
-
class Heading(
|
|
15
|
+
class Heading(elements.H1, RadixThemesComponent):
|
|
16
16
|
@overload
|
|
17
17
|
@classmethod
|
|
18
18
|
def create( # type: ignore
|
|
@@ -243,3 +243,5 @@ class Heading(el.H1, RadixThemesComponent):
|
|
|
243
243
|
A new component instance.
|
|
244
244
|
"""
|
|
245
245
|
...
|
|
246
|
+
|
|
247
|
+
heading = Heading.create
|
|
@@ -7,8 +7,8 @@ from __future__ import annotations
|
|
|
7
7
|
|
|
8
8
|
from typing import Literal
|
|
9
9
|
|
|
10
|
-
from reflex import el
|
|
11
10
|
from reflex.components.component import ComponentNamespace
|
|
11
|
+
from reflex.components.el import elements
|
|
12
12
|
from reflex.vars import Var
|
|
13
13
|
|
|
14
14
|
from ..base import (
|
|
@@ -44,7 +44,7 @@ LiteralType = Literal[
|
|
|
44
44
|
]
|
|
45
45
|
|
|
46
46
|
|
|
47
|
-
class Text(
|
|
47
|
+
class Text(elements.Span, RadixThemesComponent):
|
|
48
48
|
"""A foundational text primitive based on the <span> element."""
|
|
49
49
|
|
|
50
50
|
tag = "Text"
|
|
@@ -80,13 +80,13 @@ class Span(Text):
|
|
|
80
80
|
as_: Var[LiteralType] = "span" # type: ignore
|
|
81
81
|
|
|
82
82
|
|
|
83
|
-
class Em(
|
|
83
|
+
class Em(elements.Em, RadixThemesComponent):
|
|
84
84
|
"""Marks text to stress emphasis."""
|
|
85
85
|
|
|
86
86
|
tag = "Em"
|
|
87
87
|
|
|
88
88
|
|
|
89
|
-
class Kbd(
|
|
89
|
+
class Kbd(elements.Kbd, RadixThemesComponent):
|
|
90
90
|
"""Represents keyboard input or a hotkey."""
|
|
91
91
|
|
|
92
92
|
tag = "Kbd"
|
|
@@ -95,13 +95,13 @@ class Kbd(el.Kbd, RadixThemesComponent):
|
|
|
95
95
|
size: Var[LiteralTextSize]
|
|
96
96
|
|
|
97
97
|
|
|
98
|
-
class Quote(
|
|
98
|
+
class Quote(elements.Q, RadixThemesComponent):
|
|
99
99
|
"""A short inline quotation."""
|
|
100
100
|
|
|
101
101
|
tag = "Quote"
|
|
102
102
|
|
|
103
103
|
|
|
104
|
-
class Strong(
|
|
104
|
+
class Strong(elements.Strong, RadixThemesComponent):
|
|
105
105
|
"""Marks text to signify strong importance."""
|
|
106
106
|
|
|
107
107
|
tag = "Strong"
|
|
@@ -8,8 +8,8 @@ from reflex.vars import Var, BaseVar, ComputedVar
|
|
|
8
8
|
from reflex.event import EventChain, EventHandler, EventSpec
|
|
9
9
|
from reflex.style import Style
|
|
10
10
|
from typing import Literal
|
|
11
|
-
from reflex import el
|
|
12
11
|
from reflex.components.component import ComponentNamespace
|
|
12
|
+
from reflex.components.el import elements
|
|
13
13
|
from reflex.vars import Var
|
|
14
14
|
from ..base import LiteralAccentColor, RadixThemesComponent
|
|
15
15
|
from .base import LiteralTextAlign, LiteralTextSize, LiteralTextTrim, LiteralTextWeight
|
|
@@ -35,7 +35,7 @@ LiteralType = Literal[
|
|
|
35
35
|
"sup",
|
|
36
36
|
]
|
|
37
37
|
|
|
38
|
-
class Text(
|
|
38
|
+
class Text(elements.Span, RadixThemesComponent):
|
|
39
39
|
@overload
|
|
40
40
|
@classmethod
|
|
41
41
|
def create( # type: ignore
|
|
@@ -589,7 +589,7 @@ class Span(Text):
|
|
|
589
589
|
"""
|
|
590
590
|
...
|
|
591
591
|
|
|
592
|
-
class Em(
|
|
592
|
+
class Em(elements.Em, RadixThemesComponent):
|
|
593
593
|
@overload
|
|
594
594
|
@classmethod
|
|
595
595
|
def create( # type: ignore
|
|
@@ -724,7 +724,7 @@ class Em(el.Em, RadixThemesComponent):
|
|
|
724
724
|
"""
|
|
725
725
|
...
|
|
726
726
|
|
|
727
|
-
class Kbd(
|
|
727
|
+
class Kbd(elements.Kbd, RadixThemesComponent):
|
|
728
728
|
@overload
|
|
729
729
|
@classmethod
|
|
730
730
|
def create( # type: ignore
|
|
@@ -866,7 +866,7 @@ class Kbd(el.Kbd, RadixThemesComponent):
|
|
|
866
866
|
"""
|
|
867
867
|
...
|
|
868
868
|
|
|
869
|
-
class Quote(
|
|
869
|
+
class Quote(elements.Q, RadixThemesComponent):
|
|
870
870
|
@overload
|
|
871
871
|
@classmethod
|
|
872
872
|
def create( # type: ignore
|
|
@@ -1003,7 +1003,7 @@ class Quote(el.Q, RadixThemesComponent):
|
|
|
1003
1003
|
"""
|
|
1004
1004
|
...
|
|
1005
1005
|
|
|
1006
|
-
class Strong(
|
|
1006
|
+
class Strong(elements.Strong, RadixThemesComponent):
|
|
1007
1007
|
@overload
|
|
1008
1008
|
@classmethod
|
|
1009
1009
|
def create( # type: ignore
|