feat: migrate to Material 3 Expressive APIs#4934
Merged
jamesarich merged 1 commit intomainfrom Mar 26, 2026
Merged
Conversation
This commit updates the project to use the new Material 3 Expressive APIs, including the migration to `MaterialExpressiveTheme` and the implementation of standardized floating action button components.
Specific changes include:
- **Theme & Infrastructure**:
- Replaced `MaterialTheme` with `MaterialExpressiveTheme` in `AppTheme` and enabled the expressive `motionScheme`.
- Added `@OptIn(ExperimentalMaterial3ExpressiveApi::class)` across various UI components in the `node` and `core:ui` modules.
- **Component Updates**:
- **MenuFAB**: Refactored the custom FAB implementation to use the new `FloatingActionButtonMenu`, `FloatingActionButtonMenuItem`, and `ToggleFloatingActionButton` components.
- **MainAppBar**: Migrated to the new `TopAppBar` structure, utilizing the dedicated `subtitle` slot.
- **Typography**: Updated several text styles from `titleMedium` to `titleMediumEmphasized` for better visual hierarchy in metric logs and node items.
- **Animations & Layout**:
- Updated `NodeListScreen` to use `Modifier.animateFloatingActionButton()` for handling FAB visibility during scroll and connection state changes.
- Simplified layout logic in `MetricLogItem` and `HostMetricsItem` to align with expressive design patterns.
Signed-off-by: James Rich <[email protected]>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #4934 +/- ##
==========================================
- Coverage 19.06% 18.97% -0.10%
==========================================
Files 572 572
Lines 18774 18774
Branches 2790 2790
==========================================
- Hits 3580 3562 -18
- Misses 14670 14688 +18
Partials 524 524
Flags with carried forward coverage won't be shown. Click here to find out more.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This commit updates the project to use the new Material 3 Expressive APIs, including the migration to
MaterialExpressiveThemeand the implementation of standardized floating action button components.Specific changes include:
MaterialThemewithMaterialExpressiveThemeinAppThemeand enabled the expressivemotionScheme.@OptIn(ExperimentalMaterial3ExpressiveApi::class)across various UI components in thenodeandcore:uimodules.FloatingActionButtonMenu,FloatingActionButtonMenuItem, andToggleFloatingActionButtoncomponents.TopAppBarstructure, utilizing the dedicatedsubtitleslot.titleMediumtotitleMediumEmphasizedfor better visual hierarchy in metric logs and node items.NodeListScreento useModifier.animateFloatingActionButton()for handling FAB visibility during scroll and connection state changes.MetricLogItemandHostMetricsItemto align with expressive design patterns.