Skip to content
Merged

0828dev #6136

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions pyi_hashes.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
"reflex/components/el/elements/tables.pyi": "686eb70ea7d8c4dafb0cc5c284e76184",
"reflex/components/el/elements/typography.pyi": "684e83dde887dba12badd0fb75c87c04",
"reflex/components/gridjs/datatable.pyi": "98a7e1b3f3b60cafcdfcd8879750ee42",
"reflex/components/lucide/icon.pyi": "9cdd1107295f5c4b6d5d6516f487f237",
"reflex/components/lucide/icon.pyi": "dcb8773ef162f3ec5759efe11374cf5e",
"reflex/components/markdown/markdown.pyi": "dd74e8e9665b2a813ff799a7aa190b44",
"reflex/components/moment/moment.pyi": "e1952f1c2c82cef85d91e970d1be64ab",
"reflex/components/plotly/plotly.pyi": "4311a0aae2abcc9226abb6a273f96372",
Expand Down Expand Up @@ -113,10 +113,10 @@
"reflex/components/react_player/video.pyi": "998671c06103d797c554d9278eb3b2a0",
"reflex/components/react_router/dom.pyi": "3042fa630b7e26a7378fe045d7fbf4af",
"reflex/components/recharts/__init__.pyi": "6ee7f1ca2c0912f389ba6f3251a74d99",
"reflex/components/recharts/cartesian.pyi": "cfca4f880239ffaecdf9fb4c7c8caed5",
"reflex/components/recharts/cartesian.pyi": "d138261ab8259d5208c2f028b9f708bd",
"reflex/components/recharts/charts.pyi": "013036b9c00ad85a570efdb813c1bc40",
"reflex/components/recharts/general.pyi": "d87ff9b85b2a204be01753690df4fb11",
"reflex/components/recharts/polar.pyi": "ad24bd37c6acc0bc9bd4ac01af3ffe49",
"reflex/components/recharts/recharts.pyi": "c41d19ab67972246c574098929bea7ea",
"reflex/components/recharts/polar.pyi": "b8b1a3e996e066facdf4f8c9eb363137",
"reflex/components/recharts/recharts.pyi": "d5c9fc57a03b419748f0408c23319eee",
"reflex/components/sonner/toast.pyi": "3c27bad1aaeb5183eaa6a41e77e8d7f0"
}
4 changes: 2 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "reflex"
version = "0.8.27dev1"
version = "0.8.28dev1"
description = "Web apps in pure Python."
license.text = "Apache-2.0"
authors = [
Expand Down Expand Up @@ -244,7 +244,7 @@ fail_fast = true

[[tool.pre-commit.repos]]
repo = "https://github.com/astral-sh/ruff-pre-commit"
rev = "v0.14.13"
rev = "v0.15.1"
hooks = [
{ id = "ruff-format", args = [
"reflex",
Expand Down
2 changes: 1 addition & 1 deletion reflex/components/base/error_boundary.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ def on_error_spec(
class ErrorBoundary(Component):
"""A React Error Boundary component that catches unhandled frontend exceptions."""

library = "react-error-boundary@6.1.0"
library = "react-error-boundary@6.1.1"
tag = "ErrorBoundary"

# Fired when the boundary catches an error.
Expand Down
2 changes: 1 addition & 1 deletion reflex/components/core/upload.py
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ class GhostUpload(Fragment):
class Upload(MemoizationLeaf):
"""A file upload component."""

library = "react-dropzone@14.3.8"
library = "react-dropzone@15.0.0"

tag = ""

Expand Down
2 changes: 1 addition & 1 deletion reflex/components/datadisplay/dataeditor.py
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ class DataEditor(NoSSRComponent):
is_default = True
library: str | None = "@glideapps/glide-data-grid@6.0.3"
lib_dependencies: list[str] = [
"lodash@4.17.21",
"lodash@4.17.23",
"react-responsive-carousel@3.2.23",
]

Expand Down
20 changes: 19 additions & 1 deletion reflex/components/lucide/icon.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from reflex.vars.base import LiteralVar, Var
from reflex.vars.sequence import LiteralStringVar, StringVar

LUCIDE_LIBRARY = "lucide-react@0.562.0"
LUCIDE_LIBRARY = "lucide-react@0.574.0"


class LucideIconComponent(Component):
Expand Down Expand Up @@ -627,6 +627,7 @@ def _get_imports(self):
"cylinder",
"dam",
"database_backup",
"database_search",
"database_zap",
"database",
"decimals_arrow_left",
Expand Down Expand Up @@ -864,6 +865,7 @@ def _get_imports(self):
"git_compare",
"git_fork",
"git_graph",
"git_merge_conflict",
"git_merge",
"git_pull_request_arrow",
"git_pull_request_closed",
Expand All @@ -876,6 +878,8 @@ def _get_imports(self):
"glass_water",
"glasses",
"globe_lock",
"globe_off",
"globe_x",
"globe",
"goal",
"gpu",
Expand Down Expand Up @@ -1012,6 +1016,8 @@ def _get_imports(self):
"leaf",
"leafy_green",
"lectern",
"lens_concave",
"lens_convex",
"letter_text",
"library_big",
"library",
Expand All @@ -1020,6 +1026,7 @@ def _get_imports(self):
"lightbulb_off",
"lightbulb",
"line_chart",
"line_dot_right_horizontal",
"line_squiggle",
"link_2_off",
"link_2",
Expand Down Expand Up @@ -1097,6 +1104,7 @@ def _get_imports(self):
"memory_stick",
"menu",
"merge",
"message_circle_check",
"message_circle_code",
"message_circle_dashed",
"message_circle_heart",
Expand Down Expand Up @@ -1137,6 +1145,8 @@ def _get_imports(self):
"minimize_2",
"minimize",
"minus",
"mirror_rectangular",
"mirror_round",
"monitor_check",
"monitor_cloud",
"monitor_cog",
Expand All @@ -1156,6 +1166,7 @@ def _get_imports(self):
"motorbike",
"mountain_snow",
"mountain",
"mouse_left",
"mouse_off",
"mouse_pointer_2_off",
"mouse_pointer_2",
Expand Down Expand Up @@ -1305,6 +1316,7 @@ def _get_imports(self):
"power",
"presentation",
"printer_check",
"printer_x",
"printer",
"projector",
"proportions",
Expand Down Expand Up @@ -1432,6 +1444,7 @@ def _get_imports(self):
"share",
"sheet",
"shell",
"shelving_unit",
"shield_alert",
"shield_ban",
"shield_check",
Expand Down Expand Up @@ -1660,6 +1673,7 @@ def _get_imports(self):
"torus",
"touchpad_off",
"touchpad",
"towel_rack",
"tower_control",
"toy_brick",
"tractor",
Expand Down Expand Up @@ -1714,12 +1728,14 @@ def _get_imports(self):
"usb",
"user_check",
"user_cog",
"user_key",
"user_lock",
"user_minus",
"user_pen",
"user_plus",
"user_round_check",
"user_round_cog",
"user_round_key",
"user_round_minus",
"user_round_pen",
"user_round_plus",
Expand Down Expand Up @@ -1795,12 +1811,14 @@ def _get_imports(self):
"worm",
"wrap_text",
"wrench",
"x_line_top",
"x",
"youtube",
"zap_off",
"zap",
"zoom_in",
"zoom_out",
# "mouse_right",
]

# The default transformation of some icon names doesn't match how the
Expand Down
5 changes: 4 additions & 1 deletion reflex/components/moment/moment.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class Moment(NoSSRComponent):

tag: str | None = "Moment"
is_default = True
library: str | None = "react-moment@1.2.0"
library: str | None = "react-moment@1.2.2"
lib_dependencies: list[str] = ["moment@2.30.1"]

# How often the date update (how often time update / 0 to disable).
Expand All @@ -53,6 +53,9 @@ class Moment(NoSSRComponent):
# Displays the date as the time from now, e.g. "5 minutes ago".
from_now: Var[bool]

# Displays the relative time in a short format using abbreviated units (e.g., "1h", "2d", "3mo", "1y" instead of "1 hour ago", "2 days ago", etc.).
from_now_short: Var[bool]

# Setting fromNowDuring will display the relative time as with fromNow but just during its value in milliseconds, after that format will be used instead.
from_now_during: Var[int]

Expand Down
2 changes: 1 addition & 1 deletion reflex/components/radix/themes/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ class RadixLoadingProp(Component):
class RadixThemesComponent(Component):
"""Base class for all @radix-ui/themes components."""

library = "@radix-ui/themes@3.2.1"
library = "@radix-ui/themes@3.3.0"

# "Fake" prop color_scheme is used to avoid shadowing CSS prop "color".
_rename_props: ClassVar[dict[str, str]] = {"colorScheme": "color"}
Expand Down
6 changes: 0 additions & 6 deletions reflex/components/recharts/cartesian.py
Original file line number Diff line number Diff line change
Expand Up @@ -241,12 +241,6 @@ class Brush(Recharts):
# The default end index of brush. If the option is not set, the end index will be calculated by the length of data.
end_index: Var[int]

# The fill color of brush
fill: Var[str | Color]

# The stroke color of brush
stroke: Var[str | Color]

@classmethod
def get_event_triggers(cls) -> dict[str, Var | Any]:
"""Get the event triggers that pass the component's value to the handler.
Expand Down
6 changes: 3 additions & 3 deletions reflex/components/recharts/recharts.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
class Recharts(Component):
"""A component that wraps a recharts lib."""

library = "recharts@3.6.0"
library = "recharts@3.7.0"

def _get_style(self) -> dict:
return {"wrapperStyle": self.style}
Expand All @@ -17,7 +17,7 @@ def _get_style(self) -> dict:
class RechartsCharts(NoSSRComponent, MemoizationLeaf):
"""A component that wraps a recharts lib."""

library = "recharts@3.6.0"
library = "recharts@3.7.0"


LiteralAnimationEasing = Literal["ease", "ease-in", "ease-out", "ease-in-out", "linear"]
Expand Down Expand Up @@ -50,7 +50,7 @@ class RechartsCharts(NoSSRComponent, MemoizationLeaf):
]
LiteralTextAnchor = Literal["start", "middle", "end"]
LiteralLayout = Literal["horizontal", "vertical"]
LiteralPolarRadiusType = Literal["number", "category"]
LiteralPolarRadiusType = Literal["auto", "number", "category"]
LiteralGridType = Literal["polygon", "circle"]
LiteralPosition = Literal[
"top",
Expand Down
8 changes: 4 additions & 4 deletions reflex/constants/installer.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ class Bun(SimpleNamespace):
"""Bun constants."""

# The Bun version.
VERSION = "1.3.6"
VERSION = "1.3.9"

# Min Bun Version
MIN_VERSION = "1.3.0"
Expand Down Expand Up @@ -75,7 +75,7 @@ class Node(SimpleNamespace):


def _determine_react_router_version() -> str:
default_version = "7.12.0"
default_version = "7.13.0"
if (version := os.getenv("REACT_ROUTER_VERSION")) and version != default_version:
from reflex.utils import console

Expand Down Expand Up @@ -131,14 +131,14 @@ def DEPENDENCIES(cls) -> dict[str, str]:
"react": cls._react_version,
"react-helmet": "6.1.0",
"react-dom": cls._react_version,
"isbot": "5.1.33",
"isbot": "5.1.35",
"socket.io-client": "4.8.3",
"universal-cookie": "7.2.2",
}

DEV_DEPENDENCIES = {
"@emotion/react": "11.14.0",
"autoprefixer": "10.4.23",
"autoprefixer": "10.4.24",
"postcss": "8.5.6",
"postcss-import": "16.1.1",
"@react-router/dev": _react_router_version,
Expand Down
12 changes: 9 additions & 3 deletions reflex/testing.py
Original file line number Diff line number Diff line change
Expand Up @@ -673,18 +673,24 @@ def frontend(
driver_options = getattr(webdriver, f"{requested_driver}Options")() # pyright: ignore [reportPossiblyUnboundVariable]
if driver_clz is webdriver.Chrome: # pyright: ignore [reportPossiblyUnboundVariable]
if driver_options is None:
driver_options = webdriver.ChromeOptions() # pyright: ignore [reportPossiblyUnboundVariable]
from selenium.webdriver.chrome.options import Options

driver_options = Options() # pyright: ignore [reportPossiblyUnboundVariable]
driver_options.add_argument("--class=AppHarness")
if want_headless:
driver_options.add_argument("--headless=new")
elif driver_clz is webdriver.Firefox: # pyright: ignore [reportPossiblyUnboundVariable]
if driver_options is None:
driver_options = webdriver.FirefoxOptions() # pyright: ignore [reportPossiblyUnboundVariable]
from selenium.webdriver.firefox.options import Options

driver_options = Options() # pyright: ignore [reportPossiblyUnboundVariable]
if want_headless:
driver_options.add_argument("-headless")
elif driver_clz is webdriver.Edge: # pyright: ignore [reportPossiblyUnboundVariable]
if driver_options is None:
driver_options = webdriver.EdgeOptions() # pyright: ignore [reportPossiblyUnboundVariable]
from selenium.webdriver.edge.options import Options

driver_options = Options() # pyright: ignore [reportPossiblyUnboundVariable]
if want_headless:
driver_options.add_argument("headless")
if driver_options is None:
Expand Down
2 changes: 1 addition & 1 deletion tests/integration/test_client_storage.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
from collections.abc import Generator

import pytest
from selenium.webdriver import Firefox
from selenium.webdriver.common.by import By
from selenium.webdriver.firefox.webdriver import WebDriver as Firefox
from selenium.webdriver.remote.webdriver import WebDriver

from reflex.constants.state import FIELD_MARKER
Expand Down
3 changes: 2 additions & 1 deletion tests/units/test_model.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import math
from pathlib import Path
from unittest import mock

Expand Down Expand Up @@ -161,7 +162,7 @@ class AlembicSecond(Model, table=True):
result = session.exec(sqlmodel.select(AlembicSecond)).all()
assert len(result) == 1
assert result[0].a == 42
assert result[0].b == 4.2
assert math.isclose(result[0].b, 4.2)

# No-op
assert Model.migrate(autogenerate=True)
Expand Down
3 changes: 2 additions & 1 deletion tests/units/test_sqlalchemy.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import math
from pathlib import Path
from unittest import mock

Expand Down Expand Up @@ -248,7 +249,7 @@ class AlembicSecond(ModelBase):
result = session.scalars(select(AlembicSecond)).all()
assert len(result) == 1
assert result[0].a == 42
assert result[0].b == 4.2
assert math.isclose(result[0].b, 4.2)

# No-op
# assert Model.migrate(autogenerate=True) #noqa: ERA001
Expand Down
Loading
Loading