* Create `CompoundButton`
* Some fixes
* Lint fixes
* Start replacing existing `Button` usages
* Replace button usages
* Remove previous Button composable
* Rename `CompoundButton` to `Button`
* Fix emphasized button being displayed as Text
* Fix cancel button in `WaitListView`
* Update screenshots
* Add shorthand functions for `OutlinedButton` and `TextButton`
* Add changelog
* Fix wrong size used for emphasized button in dialog
* Create a private `ButtonInternal` implementation with the shared logic.
- Make `ButtonStyle` private.
- Rename `title` to `text`.
- Rename `buttonStyle` and `buttonSize` to just `style` and `size`.
* Fix several warnings and lint issues.
* Update screenshots
---------
Co-authored-by: ElementBot <benoitm+elementbot@element.io>
Centering the titles is very iOS-y and not aligned with the material
guidelines (which say center aligned top bars are only for the main
root page in the app). They also present issues when we have titles
and textual actions that end up being quite long in other languages,
as they end up merging together.
Fixes#655
With this change, composable previews and screenshots should be created with just:
```
@ElementPreviews@Composable
fun MyViewPreview() {
ElementPreview {
MyView()
}
}
```
- Adds `@ElementPreviews` which is a shorthand for:
```
@Preview(name = "D")
@Preview(name = "N", uiMode = Configuration.UI_MODE_NIGHT_YES)
```
Should be used in connection with the now public `fun ElementPreview()` composable.
- Adds ElementPreviews to previewAnnotations in dangerfile
- Screenshots of night mode previews are now rendered with night mode
- Replaces `ElementPreviewLight` and `ElementThemedPreview` with `ElementPreview`
- Deprecates `ElementPreviewDark` which should be removed.
- Remaining usages of `ElementPreviewDark` are now ignored during screenshot tests