reflex/tests
Masen Furer 67606561d3
[REF-668] Wrap MyApp with radix Theme component (#1867)
* partly add some radix-ui/themes based components

* add @radix-ui/themes integration to top-level app

* WiP: compile _app_wrap based on which component library is used

TODO: working color mode

* WiP get color mode working with agnostic provider

still not perfect, as the RadixColorModeProvider seems to trip hydration errors
when using color_mode_cond component, but for now, this provides a nice balance
between the two libraries and allows them to interoperate.

* WiP template _app.js instead of making a separate wrap file

* WiP: use next-themes for consistent darkmode switching

* strict pin chakra deps

* Move ChakraColorModeProvider to separate js file

* move nasty radix themes js code into js files

* remove chakra from default imports

* chakra fixup import to use .js extension

* Add radix theme typography and layout components

* do NOT special case the radix theme...

avoid templating json and applying it, avoid non-customizable logic

just add the radix Theme component as an app wrap if the user specifies it to
rx.App, and any other app-wrap theme-like component could _also_ be used
without having to change the code.

this also allows different themes for different sections of the app by simply
placing elements inside a different rdxt.theme wrapper.

* Theme uses "radius" not "borderRadius"

* move next-themes to main packages.json

this is always used, regardless of the component library

* test_app: test cases for app_wrap interface

* Finish wrapping Button, Switch, and TextField components

* docstring, comments, static fixups

* debounce: use alias or tag when passing child Element

Fix REF-830

* test_app: ruin my beautiful indentation

* py38 compatibility

* Add event triggers for switch and TextField

* Add type hints for radix theme components

* radix themes fixups from writing the tests

* Add integration test for radix themes components

* test_app: mock out package installation

we only need the compile result, we're not actually trying to install packages

* avoid incompatible version of @emotion/react

* test_radix_themes: include theme_panel component

* next-themes default scheme: "light"

until all of our components look good in dark mode, need to keep the default as
light mode regardless of the system setting.
2023-10-16 15:31:50 -07:00
..
compiler Add head components to app (#1868) 2023-09-25 16:53:15 -07:00
components Var field cleanup (#1943) 2023-10-13 14:53:55 -07:00
middleware code cleanup (split constants into a folder) (#1866) 2023-09-28 17:27:20 -07:00
states rx.background and StateManager.modify_state provides safe exclusive access to state (#1676) 2023-09-21 11:42:11 -07:00
utils Props as Literals (#1921) 2023-10-15 20:16:39 -07:00
__init__.py Add basic unit tests (#7) 2022-11-20 14:34:25 -08:00
conftest.py rx.background and StateManager.modify_state provides safe exclusive access to state (#1676) 2023-09-21 11:42:11 -07:00
test_app.py [REF-668] Wrap MyApp with radix Theme component (#1867) 2023-10-16 15:31:50 -07:00
test_base.py Rename pynecone to reflex (#1236) 2023-06-25 16:56:55 -07:00
test_config.py [REF-843] Automatically update api_url and deploy_url (#1954) 2023-10-13 12:59:19 -07:00
test_db_config.py Rename pynecone to reflex (#1236) 2023-06-25 16:56:55 -07:00
test_event.py allow external link for redirect (#1902) 2023-10-02 09:37:46 -07:00
test_model.py supply default for sqlmodel PK for both DB and python to work (#1788) 2023-09-08 14:51:57 -07:00
test_prerequisites.py Add serializers for different var types (#1816) 2023-09-15 17:19:26 -07:00
test_route.py Allow underscores in routes (#1713) 2023-09-08 12:18:33 -07:00
test_state.py No state No Websocket (#1950) 2023-10-13 14:54:59 -07:00
test_style.py Rename pynecone to reflex (#1236) 2023-06-25 16:56:55 -07:00
test_telemetry.py Disable metrics in CI (#1822) 2023-09-15 18:15:25 -07:00
test_testing.py Automatic Install FNM and Node for Windows: (#1566) 2023-08-17 11:23:09 -07:00
test_var.py Var field cleanup (#1943) 2023-10-13 14:53:55 -07:00