DynamicMaterialThemeState

State object that holds the current values for a dynamic material theme.

Use rememberDynamicMaterialThemeState to create an instance of this class.

Parameters

initialSeedColor

The initial seed color to generate the color scheme.

initialIsDark

The initial dark mode state.

initialIsAmoled

The initial Amoled state.

initialStyle

The initial palette style.

initialContrastLevel

The initial contrast level.

initialExtendedFidelity

The initial extended fidelity state.

initialPrimary

A custom color to modify the primary color in the generated color scheme.

initialSecondary

A custom color to modify the secondary color in the generated color scheme.

initialTertiary

A custom color to modify the tertiary color in the generated color scheme.

initialNeutral

A custom color to modify the neutral color in the generated color scheme.

initialNeutralVariant

A custom color to modify the neutral variant color in the generated color scheme.

initialError

A custom color to modify the error color in the generated color scheme.

modifyColorScheme

Use this callback to modify the color scheme once it has been generated. Note that if you modify a color in the scheme, the on* color might not have enough contrast.

Properties

Link copied to clipboard

A MaterialKolors class that holds the generated colors based on the current state.

Link copied to clipboard

The generated color scheme based on the current state.

Link copied to clipboard

The contrast level.

Link copied to clipboard
Link copied to clipboard
var error: Color?

A custom color to modify the error color in the generated color scheme.

Link copied to clipboard

The dark mode with Amoled state.

Link copied to clipboard

The dark mode state.

Link copied to clipboard

The extended fidelity state.

Link copied to clipboard

Returns the Material 3 color scheme based on the current dynamic color scheme.

Link copied to clipboard

A custom color to modify the neutral color in the generated color scheme.

Link copied to clipboard

A custom color to modify the neutral variant color in the generated color scheme.

Link copied to clipboard

A custom color to modify the primary color in the generated color scheme.

Link copied to clipboard

A custom color to modify the secondary color in the generated color scheme.

Link copied to clipboard

The seed color to generate the color scheme from.

Link copied to clipboard

The palette style.

Link copied to clipboard

A custom color to modify the tertiary color in the generated color scheme.