You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using Paparazzi since long time now, and I used to generate 1 screenshot per night mode.
I'm trying to reduce the number of generated screenshots, and one try is to generate 1 screenshots for both theme.
My attempt was to generated (with compose) my composable in a Row 👍
(where DSTheme is defining a new CompositionLocalProvider)
And device config was set like this : DeviceConfig.PIXEL_5.copy(screenWidth = DeviceConfig.PIXEL_5.screenWidth * 2)
The result is : both side are in light theme, because even if I force the theme provided to light or dark, the final Provider will be the device setting, which is not UI_MODE_NIGHT_UNDEFINED, but necessary to be one of the NightMode.NIGHT/NOT_NIGHT
Is it possible to have a "NightMode.Undefined" which will be mapped to UI_MODE_NIGHT_UNDEFINED, to have the control of composable part themed ?
Thanks !
The text was updated successfully, but these errors were encountered:
Could you provide a sample project with your issue?
From my understanding this doesn't seem like a paparazzi issue necessarily.
It seems like you should be able to change your design system composable DSTheme to force dark/light without having to mess with the UI_MODE.
Otherwise, the suggestion would be to generate snapshots for each light/dark mode.
You're right, my bad.
Sorry for the noise 😄
My default value was the system config, I need to override the default value if my value has been already set before, and it's working :)
I'm using Paparazzi since long time now, and I used to generate 1 screenshot per night mode.
I'm trying to reduce the number of generated screenshots, and one try is to generate 1 screenshots for both theme.
My attempt was to generated (with compose) my composable in a Row 👍
(where DSTheme is defining a new
CompositionLocalProvider
)And device config was set like this :
DeviceConfig.PIXEL_5.copy(screenWidth = DeviceConfig.PIXEL_5.screenWidth * 2)
The result is : both side are in light theme, because even if I force the theme provided to light or dark, the final Provider will be the device setting, which is not UI_MODE_NIGHT_UNDEFINED, but necessary to be one of the NightMode.NIGHT/NOT_NIGHT
Is it possible to have a "NightMode.Undefined" which will be mapped to UI_MODE_NIGHT_UNDEFINED, to have the control of composable part themed ?
Thanks !
The text was updated successfully, but these errors were encountered: