reflex/reflex
Masen Furer 4422515f4b
LiteralEventChainVar becomes an ArgsFunctionOperation (#4174)
* LiteralEventChainVar becomes an ArgsFunctionOperation

Instead of using the ArgsFunctionOperation to create the string representation
of the _js_expr, make the identity of the var an ArgsFunctionOperation so the
_args_names and _return_expr remain accessible.

Rely on the default behavior of ArgsFunctionOperation to create the
_cached_var_name / _js_expr value.

This allows the compat shim in `format_event_chain` to remain functional, as it
does special handling for ArgsFunctionOperation to retain the previous behavior
of that function (this was a regression introduced in 0.6.2).

* _var_type is EventChain; fix parent class order

* Re-fix LiteralEventChainVar inheritence list w/ comment

* [ENG-3942] LiteralEventVar becomes VarCallOperation

instead of using `.call` when constructing the `_js_expr`, have the identity of
a LiteralEventVar as a VarCallOperation to take advantage of the _var_data
carrying.

* add event overlords

* EventCallback descriptor always returns EventSpec from class

Relax actual `__get__` definition to support the multitude of overloads

* test case for event related vars carrying _var_data

---------

Co-authored-by: Khaleel Al-Adhami <khaleel.aladhami@gmail.com>
2024-10-16 11:35:09 -07:00
..
.templates support eventspec/eventchain in var operations (#4038) 2024-10-03 15:33:51 -07:00
app_mixins improve lifespan typecheck and debug (#4014) 2024-09-27 16:17:30 -07:00
compiler bundle chakra in window for CSR (#4042) 2024-10-03 14:25:21 -07:00
components Change the defalut direction of radio group (#4070). (#4146) 2024-10-14 08:47:38 -07:00
constants Support aria and data props (#4149) 2024-10-14 08:45:25 -07:00
custom_components fix custom component init (#4123) 2024-10-08 09:15:56 -07:00
experimental add type hinting to events (#4145) 2024-10-14 08:44:31 -07:00
istate Handle rx.State subclasses defined in function (#4129) 2024-10-11 16:51:10 -07:00
middleware remove format_state and override behavior for bare (#3979) 2024-09-26 16:00:28 -07:00
utils add type hinting to events (#4145) 2024-10-14 08:44:31 -07:00
vars add type hinting to events (#4145) 2024-10-14 08:44:31 -07:00
__init__.py add type hinting to events (#4145) 2024-10-14 08:44:31 -07:00
__init__.pyi add type hinting to events (#4145) 2024-10-14 08:44:31 -07:00
__main__.py add __main__ entry point to allow python -m reflex (#1516) 2023-08-03 14:26:50 -07:00
admin.py upgrade to latest ruff (#3497) 2024-06-19 12:32:13 +02:00
app_module_for_backend.py Bring back py3.9 support with a deprecation warning. (#3976) 2024-09-23 18:15:16 -07:00
app.py remove var operation error (#4053) 2024-10-03 15:58:04 -07:00
base.py Component as Var type (#3732) 2024-09-19 19:06:53 -07:00
config.py let users pick state manager mode (#4041) 2024-10-10 12:22:35 -07:00
event.py LiteralEventChainVar becomes an ArgsFunctionOperation (#4174) 2024-10-16 11:35:09 -07:00
model.py a friendly little helper (#4021) 2024-10-01 14:32:05 -07:00
page.py re add removed method with better behaviour and tests (#3986) 2024-09-24 23:29:56 +02:00
reflex.py use pathlib as much as possible (#3967) 2024-10-03 17:50:39 +02:00
route.py [REF-2643] Throw Errors for duplicate Routes (#3155) 2024-05-03 12:15:40 -07:00
state.py disk is memory is disk (#4185) 2024-10-16 11:31:05 -07:00
style.py only treat dict object vars as key value mapping (#4177) 2024-10-15 12:21:03 -07:00
testing.py catch ValueError("I/O operation on closed file.") if frontend crashes (#4150) 2024-10-10 12:18:57 -07:00