timothymiller / t4-app

A powerful cross-platform UI toolkit for building actually native iOS, Android, macOS, Windows, Linux, and Progressive Web Apps with React (Native).
https://t4stack.com
MIT License
1.31k stars 70 forks source link

[web] Themes are not propagating properly when providers are in separate files #81

Open hdwatts opened 9 months ago

hdwatts commented 9 months ago

I've opened a Tamagui issue here: https://github.com/tamagui/tamagui/issues/1718 And a reproduction repo here: https://github.com/hdwatts/tamagui-playground

The repro isn't a t4-app, but I confirmed that adding switches and the theme toggle to the home screen in a fresh t4-app will lead to this same issue.

For now I may recommend combining the theme/tamagui providers and can open a PR if you agree.

timothymiller commented 9 months ago

I have previously raised a similar issue, and for clarity, I am providing the link to it.

albbus-stack commented 8 months ago

@hdwatts This is a bug that affects Tamagui so we should track your issue https://github.com/tamagui/tamagui/issues/1718 and https://github.com/tamagui/tamagui/issues/1319.

The real bug for t4-app is that the bottom sheet doesn't change color

https://github.com/timothymiller/t4-app/assets/57916483/63b9f9c0-1bcb-4f31-8846-be7860bdb8ab

@timothymiller I can commit this theme toggle component if that's something we want out of the box.

timothymiller commented 8 months ago

@albbus-stack I love the theme toggle let's add it!

timothymiller commented 8 months ago

Re: the original issue, I've tested this on native & web, and the issue only seems to persist on web. FWIW

timothymiller commented 8 months ago

Dude, the issue was the dependency array was incomplete. Biome lint helped uncover the issue. Total cringe bro.

timothymiller commented 6 months ago

Seems like this issue has resurfaced