shifted
fun Color.shifted(colorMode: ColorMode, byPercent: Float = Color.DEFAULT_SHIFTING_PERCENT): Color(source)
Lighten or darken the color, as appropriate, based on the specified color mode.
By default, the color will shift AWAY from the current color mode, e.g. light mode makes colors darker and vice versa, although you can use a negative byPercent value if you need the opposite behavior.
@Composable
@ReadOnlyComposable
Convenience function for when you're inside a Composable
context, within which you can grab the current color mode.