Commit Graph

9 Commits

Author SHA1 Message Date
Masen Furer
3564df7620
Implement throttle and debounce as event actions () 2024-04-26 17:28:51 -07:00
benedikt-bartscher
f27eae7655
fix AppHarness reloading ()
* move AppHarness tests to module scope

* fix AppHarness reloading

* add test

* docstrings and formatting

* fix benchmarks not reloading state module
2024-03-26 11:09:46 -07:00
Masen Furer
eb18ce90d5
[REF-2172] Add DECORATED_PAGES before compiling in thread () 2024-03-12 10:28:37 -07:00
Masen Furer
756bf9b0f4
[REF-1885] Shard Substates when serializing to Redis ()
* Move sharding internal to StateManager

Avoid leaking sharding implementation details all over the State class and
breaking the API

* WiP StateManager based sharding

* Copy the state __dict__ when serializing to avoid breaking the instance

* State tests need to pass the correct substate token for redis

* state: when getting parent_state, set top_level=False

ensure that we don't end up with a broken tree

* test_app: get tests passing with redis by passing the correct token

refactor upload tests to suck less

* test_client_storage: look up substate key

* state.py: pass static checks

* test_dynamic_routes: working with redis state shard

* Update the remaining AppHarness tests to pass {token}_{state.get_full_name()}

* test_app: pass all tokens with state suffix

* StateManagerRedis: clean up commentary
2024-02-21 01:50:25 -08:00
Nikhil Rao
05d1be2182
Move core components to radix namespace () 2024-02-02 14:26:46 -08:00
jackie-pc
7388617b72
apps should no longer call "app.compile()" () 2023-12-18 16:06:21 -08:00
Elijah Ahianyo
e3ee98098a
RED-1052/rx.State as Base State () 2023-11-29 09:43:33 -08:00
Masen Furer
bf20a530df
Do not stop prop is there is no prop to stop ()
Check that desired event actions are defined on the object passed as the DOM
event before calling them to avoid frontend errors.
2023-11-02 10:21:41 -07:00
Masen Furer
56476d0a86
Expose DOM event actions on EventHandler, EventSpec, and EventChain (stopPropagation) ()
* Expose preventDefault and stopPropagation for DOM events

All EventHandler, EventSpec, and EventChain can now carry these extra
"event_actions" that will be applied inside the frontend code when an event is
triggered from the DOM.

Fix 
Fix REF-675

* Test cases (and fixes) for "event_actions"

* form: from __future__ import annotations

for py38, py39 compat

* Revert overzealous merge conflict resolution
2023-10-31 11:42:42 -07:00