Copy link to clipboard
Copied
Any one here make panels for Animate? If so how did you handle the panel background color, since AppSkinInfo gives inaccurate values? CSInterface.getHostEnvironment().appSkinInfo has various key/values, like appBarBackgroundColor and panelBackgroundColorSRGB, but these return results like:
- Darkest = #424242
- Dark = #424242
- Light = #D3D3D3
- Lightest = #D3D3D3
Rather frustratingly both Dark and Light variants are not only identical throughout AppSkinInfo, but they're even inaccurate and seem to be fake, hard-coded data. The real results should be:
- Darkest = #1E1E1E
- Dark = #323232
- Light = #F5F5F5
- Lightest = #FFFFFF
Except since dark/light variants are identical, I have no way of knowing if a user's theme is Dark or Darkest. Everything in appSkinInfo appears completely identical for each.
Digging around Animate's getExtensions() , you can see 15+ first party panels, but none of them have solutions for this. Most are embedded and the only one I see who's type is Panel is Libraries, which uses the above fake values and sticks out like a sore thumb in doing so. The others never use or need a background because they're embedded and the color values of their elements never change, like the start menu, because it can lean on the native background and only needs to know whether light/dark, but never dark/darkest.
Except I don't know that it's possible to have a completely transparent panel background so I can do something similar. Every time I try to set my panel bg to transparent whether on body, root, html, and etc., I can only get a white screen -- I can never get the native background to bleed through.
Is there any way to accurately know which exact theme the user has?
Have something to add?