* Make `InternalButton` internal instead of private so it can be customised. Also, change the `ButtonColors.contentColor` for text buttons to `LocalContentColor.current` by default. * Add temporary color for Snackbar action label * Implement `Snackbar` component based on Compound * Propagate changes to all other components * Use right Preview annotation config * Move `ButtonVisuals` to their own file * Update screenshots * Make previews internal * Update screenshots * Set a custom token for contentColor in AppBars * Change 'Label' to 'Action' in the previews * Add changelog * Update screenshots --------- Co-authored-by: ElementBot <benoitm+elementbot@element.io>
Theme Module
This module contains the theme tokens for the application, including those auto-generated from Compound and its mappings.
Usage
The module contains public tokens and color schemes that are later used in MaterialTheme and added to ElementTheme for use in the application.
All tokens can be accessed through the ElementTheme object, which contains the following properties:
ElementTheme.materialColors: contains all Material color tokens. In Figma, they're prefixed withM3/. It's an alias toMaterialTheme.colorScheme.ElementTheme.colors: contains all Compound semantic color tokens. In Figma, they're prefixed with eitherLight/orDark/.ElementTheme.typography: contains the CompoundTypographyTokensvalues. In Figma, they're prefixed withAndroid/font/.
Adding new tokens
All new tokens should come from Compound and added to the compound.generated package. To map the literal tokens to the semantic ones, you'll have to update both compoundColorsLight and compoundColorsDark in CompoundColors.kt.