Has anyone noticed when "enable redwood theme" is ...
# suitescript
n
Has anyone noticed when "enable redwood theme" is set in Company General preferences, those styles are included in the SL? I have an external one where I have a custom looking page but when that is enabled all the styles are messed up because of redwood, any way to disable for scripts?
e
Doubtful, but I do not know at all. Probably going to have to adjust your custom CSS. There are likely elements, IDs, classes, and other attributes you can use to distinguish which theme is active.
๐Ÿ‘ 1
n
Yeah, that was my plan unless someone had a better solution lol
e
There is a flag on the runtime user preferences to determine if a user has redwood enabled. I have been using that to detect which of my users are now using redwood and to apply new redwood compliant css for their UI.
โœ… 1
n
Do you mind sharing that code so i can see what "flag" you are referring to? That would be very helpful in the meantime to control my css
e
I can, but currently traveling this weekend. I can share it Monday for ya
n
No rush man, thanks! Safe travels
๐Ÿ‘ 1
e
Copy code
runtime.getCurrentUser().getPreference({name:'REDWOOD'})
The
REDWOOD
ID is unfortunately undocumented, but this seems to work for me
e
Yep thatโ€™s it
โœ… 1
n
Awesome, thanks guys!
๐Ÿ‘ 1