-
Goal: Change Theme from app using
theme.setMode()
-
Details: Based on this documentation & this post, i'm trying to implement a theme switcher to change between 2 retool organization level themes, but setting the name of the specific theme i want does not work, I haven't been able to find much documentation for this JS function, hence the reason to post this, any help is appreciated!
Hi Juan, thanks for getting in touch!
The theme.setMode()
API doesn't switch between themes but rather a new "modes" concept which is only available in the new theme editor beta. Themes created or edited with the new theme editor can define multiple modes using the switcher in the top right corner of the editor below the "Save" button.
I understand this is not necessarily expected since it's different from how we've done light and dark themes historically. We'll have more documentation resources available as the feature graduates from beta.
Hope you enjoy modes and please be in touch if you have questions or concerns adopting the new features!
3 Likes
Thanks for the explanation! I'll keep in touch in case i have any doubts or if i find any issue!
1 Like