Skip to content

Commit 70a5922

Browse files
authored
support float and str for stroke_widht prop in recharts components (#5358)
1 parent 0c35a29 commit 70a5922

2 files changed

Lines changed: 6 additions & 6 deletions

File tree

pyi_hashes.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@
115115
"reflex/components/react_player/react_player.pyi": "40db798bcb7fa40207d24f49722135ae",
116116
"reflex/components/react_player/video.pyi": "22d84a7f57be13ece90cb30536d76c7d",
117117
"reflex/components/recharts/__init__.pyi": "a52c9055e37c6ee25ded15688d45e8a5",
118-
"reflex/components/recharts/cartesian.pyi": "eb44b706cdb45f4b8450ef5302a981ae",
118+
"reflex/components/recharts/cartesian.pyi": "5f893a3a6b1428a463cbbc4db5aa8097",
119119
"reflex/components/recharts/charts.pyi": "2f0a39f9c02de83d9e2d97763b4411af",
120120
"reflex/components/recharts/general.pyi": "06d0e97776cc82b946fed465ab36fba4",
121121
"reflex/components/recharts/polar.pyi": "7c445e98c1d0c95868411173de8fe85e",

reflex/components/recharts/cartesian.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -335,7 +335,7 @@ class Area(Cartesian):
335335
stroke: Var[str | Color] = LiteralVar.create(Color("accent", 9))
336336

337337
# The width of the line stroke. Default: 1
338-
stroke_width: Var[int]
338+
stroke_width: Var[str | int | float]
339339

340340
# The color of the area fill. Default: rx.color("accent", 5)
341341
fill: Var[str | Color] = LiteralVar.create(Color("accent", 5))
@@ -384,7 +384,7 @@ class Bar(Cartesian):
384384
stroke: Var[str | Color]
385385

386386
# The width of the line stroke.
387-
stroke_width: Var[int]
387+
stroke_width: Var[str | int | float]
388388

389389
# The width of the line stroke. Default: Color("accent", 9)
390390
fill: Var[str | Color] = LiteralVar.create(Color("accent", 9))
@@ -437,7 +437,7 @@ class Line(Cartesian):
437437
stroke: Var[str | Color] = LiteralVar.create(Color("accent", 9))
438438

439439
# The width of the line stroke. Default: 1
440-
stroke_width: Var[int]
440+
stroke_width: Var[str | int | float]
441441

442442
# The dot is shown when mouse enter a line chart and this chart has tooltip. If false set, no active dot will not be drawn. If true set, active dot will be drawn which have the props calculated internally. Default: {"stroke": rx.color("accent", 10), "fill": rx.color("accent", 4)}
443443
dot: Var[bool | dict[str, Any]] = LiteralVar.create(
@@ -645,7 +645,7 @@ class ErrorBar(Recharts):
645645
stroke: Var[str | Color] = LiteralVar.create(Color("gray", 8))
646646

647647
# The stroke width of error bar. Default: 1.5
648-
stroke_width: Var[int | float]
648+
stroke_width: Var[str | int | float]
649649

650650

651651
class Reference(Recharts):
@@ -684,7 +684,7 @@ class ReferenceLine(Reference):
684684
stroke: Var[str | Color]
685685

686686
# The width of the stroke. Default: 1
687-
stroke_width: Var[str | int]
687+
stroke_width: Var[str | int | float]
688688

689689
# Valid children components
690690
_valid_children: ClassVar[list[str]] = ["Label"]

0 commit comments

Comments
 (0)