Wear Compose M3
Android (Google)OfficialCreated by Google LLCDistributed by Android (Google)
- Skill
- Tool integration
- Software development
- Apache-2.0
- No issues found
AutoGineer summary
Written by AutoGineer from the skill’s own files, not by the author
This skill provides essential guidance for developers building or migrating Wear OS applications to the Material 3 (M3) design system. It covers the integration of androidx.wear.compose.material3, foundation, and navigation libraries, offering best practices for component usage, project migration from Material 2.5 or Horologist, and implementation of key Wear OS features like ambient mode and scaffold structures.
What it does
- Provides migration paths from Material 2.5 and Horologist to Wear Compose M3.
- Defines mandatory project configuration for Kotlin, Compose compiler, and SDK versions.
- Maps legacy components to their modern M3 equivalents.
- Offers a comprehensive reference table for canonical component samples.
- Guides developers on implementing scaffold structures and ambient mode.
- Enforces strict versioning and build validation protocols.
When to use it
- When starting a new Wear OS project using Compose Material 3.
- When migrating an existing Wear OS app from Material 2.5 or Horologist.
- When updating dependencies for Wear Compose libraries.
- When looking for canonical implementation samples for M3 components.
Advantages
- Ensures consistency with official Google Material 3 design standards.
- Reduces migration friction through clear component mapping.
- Promotes stable build practices by enforcing version compliance.
- Centralizes access to verified component samples and implementation patterns.
Usage examples
- “How do I migrate my Wear OS app from Material 2.5 to Material 3?”
- The agent will guide you through updating your dependencies, replacing legacy components like Chip with Button, and updating your MaterialTheme implementation to use ColorScheme and MotionScheme.
- “What is the M3 equivalent for ScalingLazyColumn?”
- The agent will advise using TransformingLazyColumn and provide links to the relevant samples for implementation.
Install
Download the skill as a ZIP:
https://mp-staging.autogineer.com/agent-skills/android/wear-compose-m3/downloadUnzip it into the cross-client skills folder of your project:
mkdir -p .agents/skills && unzip wear-compose-m3.zip -d .agents/skills
Documentation by Google LLC
Prerequisites and compatibility
Current Wear OS Compose version in-use: To find the installed library version, read
gradle/libs.versions.tomlorbuild.gradle.ktsdirectly. Don't run./gradlew dependenciesor other shell commands to resolve versions.Wear OS Compose Material3 version: If an internal tool is available to establish the latest stable version
{VERSION}ofandroidx.wear.compose:compose-material3, use that tool.Otherwise, fetch the official Maven metadata XML to identify
{VERSION}(highest number, ignoring-alpha,-beta, or-rc).
Strict compliance: If a version is listed as stable, you MUST use it, unless overridden by the user. Do not downgrade based on initial "Unresolved reference" errors in the editor or outdated web search results.
Kotlin & Compose compiler: Use Kotlin 2.0.0+ with the
org.jetbrains.kotlin.plugin.composeGradle plugin.Min SDK: Ensure
minSdkis at least 25.Compile SDK & AGP: Ensure
compileSdkand AGP meet the library's AAR metadata floors (compileSdk >= 35andAGP >= 8.6.0for1.6.x;compileSdk >= 37andAGP >= 9.1.0for1.7.x).
Gotchas
Mandatory sync and validation: After updating versions in
libs.versions.tomlorbuild.gradle.kts, perform a Gradle sync (or./gradlew assembleDebug) before refactoring, and run./gradlew assembleDebugafter refactoring to verify the build.Prohibition of guessing (error protocol): If you encounter an 'Unresolved Reference' or API mismatch after a successful sync, do not attempt to 'fix' it by downgrading the library version.
Capabilities and tools
Capability 1: Migration, updates, and adding features
Use this guidance when migrating from an older version of Wear OS Compose or Horologist, updating an existing Wear Compose Material3 project, or adding features.
Unless otherwise indicated by the developer, use the latest stable version of Wear Compose Material3 from
{VERSION}(superseding any literal version strings in the migration guide).When migrating from Material 2.5 or Horologist, read the migration guide and use its official component mappings.
Before refactoring any component (for example,
Chip->Button), check the parameter names, slot types, and "Expressive" design tokens.Do not use the Horologist Composables, Compose Layout, or Compose Material libraries; replace Horologist components with Wear Compose M3 equivalents (
AppScaffold-> M3AppScaffold,ScreenScaffold-> M3ScreenScaffold,ScalingLazyColumn->TransformingLazyColumn,ResponsiveListHeader->ListHeader,PagerScreen->HorizontalPagerScaffold,Chip->Button,Confirmation->ConfirmationDialog).Always check against the component guidance in Capability 3.
Expect screenshot tests to fail when migrating or updating components: expected defaults for padding and positioning will have changed. Do not seek to artificially match the previous screenshot, but give preference to the Material3 defaults.
Capability 2: Component samples
Use this table of reference to find canonical samples for Wear Compose components. When working with a Wear Compose component, you must use the samples linked from the table to ensure you know how to correctly use it.
Important: Symbols marked with [alpha], [beta], or [rc] are only
available in that pre-release track and are not in stable {VERSION}. Do
not use them unless the project explicitly targets that pre-release version.
Material 3 components in androidx.wear.compose.material3.*
Foundation components in androidx.wear.compose.foundation.*
Navigation 3 components in androidx.wear.compose.navigation3.*
| Component / Symbol | Reference Samples |
|---|---|
rememberSwipeDismissableSceneStrategy | SwipeDismissableSceneStrategySample |
Capability 3: Component guidance
Mandatory: Use this capability as a checklist against any component use. It provides more holistic guidance on how to use each component in practice, beyond the component syntax.
AppScaffoldandScreenScaffold[ ] Use
AppScaffoldas the outer container, withScreenScaffoldchildren.[ ] Use only ONE
AppScaffoldand any number ofScreenScaffold.
ScalingLazyColumn- UseTransformingLazyColumninstead.TransformingLazyColumn- You will need the following imports:import androidx.wear.compose.foundation.lazy.TransformingLazyColumn import androidx.wear.compose.foundation.lazy.TransformingLazyColumnDefaults import androidx.wear.compose.foundation.lazy.rememberTransformingLazyColumnState // ... import androidx.wear.compose.material3.lazy.rememberTransformationSpec import androidx.wear.compose.material3.lazy.transformedHeight<br />
Canonical example:
val columnState = rememberTransformingLazyColumnState() val transformationSpec = rememberTransformationSpec() ScreenScaffold( scrollState = columnState ) { contentPadding -> TransformingLazyColumn( state = columnState, contentPadding = contentPadding ) { item { ListHeader( modifier = Modifier .fillMaxWidth() .transformedHeight(this, transformationSpec) .minimumVerticalContentPadding(ListHeaderDefaults.minimumTopListContentPadding), transformation = SurfaceTransformation(transformationSpec) ) { Text(text = "Header") } } // ... other items item { Button( modifier = Modifier .fillMaxWidth() .transformedHeight(this, transformationSpec) .minimumVerticalContentPadding(ButtonDefaults.minimumVerticalListContentPadding), transformation = SurfaceTransformation(transformationSpec), onClick = { /* ... */ }, icon = { Icon( imageVector = Icons.Default.Build, contentDescription = "build", ) }, ) { Text( text = "Build", maxLines = 1, overflow = TextOverflow.Ellipsis, ) } } } }<br />
[ ] Use
TransformingLazyColumninstead ofScalingLazyColumn.[ ] You must pass the
contentPaddingparameter fromScreenScaffoldto theTransformingLazyColumn.[ ] Use the
minimumVerticalContentPaddingmodifier to achieve required padding top and bottom.This expects a value from defaults, such as
ButtonDefaults,CardDefaults,ListHeaderDefaults.Note: This is a scoped modifier available within
TransformingLazyColumnItemScope.
[ ] Ensure items morph and scale (apply to components within
TransformingLazyColumn, not the list itself):[ ] Use
Modifier.transformedHeight(this, transformationSpec).[ ] Use
transformation = SurfaceTransformation(transformationSpec).
[ ] If configuring a list for snapping, use
flingBehaviorandrotaryScrollableBehaviortogether:
val columnState = rememberTransformingLazyColumnState() ScreenScaffold(scrollState = columnState) { contentPadding -> TransformingLazyColumn( state = columnState, flingBehavior = TransformingLazyColumnDefaults.snapFlingBehavior(columnState), rotaryScrollableBehavior = RotaryScrollableDefaults.snapBehavior(columnState) ) { // ... // ... } }<br />
ScreenScaffold[ ] Guard the
scrollIndicatorwith!LocalScrollCaptureInProgress.current(androidx.compose.ui.platform).
EdgeButton[ ] Do NOT use as the final item within a
TransformingLazyColumn. Instead, use the slot inScreenScaffold.[ ] When used in a
TransformingLazyColumn, add the required overscroll behavior:
val columnState = rememberTransformingLazyColumnState() ScreenScaffold( scrollState = columnState, edgeButton = { EdgeButton( onClick = { /* TODO */ }, modifier = Modifier.scrollable( columnState, orientation = Orientation.Vertical, reverseDirection = true, // Apply overscroll to the EdgeButton for proper scrolling behavior. overscrollEffect = rememberOverscrollEffect(), ) ) { Text("More") } } ) { contentPadding -> TransformingLazyColumn( contentPadding = contentPadding, state = columnState, ) { // ... // ... } }<br />
Column[ ] USE as a direct child of
ScreenScaffoldif the screen will never scroll, even with the largest system font.[ ] Use
TransformingLazyColumninstead for all other cases.
Styles
[ ] Do NOT hard-code text sizes, use
typographyfromMaterialTheme.[ ] Do NOT hard-code colors, use
colorSchemefromMaterialTheme.
Use component defaults:
[ ] Components such as
Buttonhave a correspondingButtonDefaultsobject.[ ] Check for and use the
*Defaultsobject for any component when working with padding and styling values, in preference to hard-coded values.
Use Wear-specific preview annotations (
androidx.wear.compose.ui.tooling.preview):[ ]
@WearPreviewDevices[ ]
@WearPreviewFontScales[ ] Ensure the
androidx.wear.compose:compose-ui-toolingdependency is included.
Ambient mode
[ ] Use
LocalAmbientModeManager(provided byCompositionLocalProviderandrememberAmbientModeManager()) instead ofAmbientLifecycleObserver.
Navigation
[ ] When adding navigation fresh, use Navigation3 (
androidx.wear.compose:compose-navigation3).[ ] Use
rememberSwipeDismissableSceneStrategy()/SwipeDismissableSceneStrategy(androidx.wear.compose.navigation3).
Comments
[ ] Where any Kotlin file has been modified, ensure that the existing comments are up to date and accurately reflect any changes to the implementation.
HorizontalPagerorVerticalPager[ ] Use the Composable hierarchy in this order:
AppScaffold,HorizontalPagerScaffold,HorizontalPager,AnimatedPage,ScreenScaffold. Or similarly forVerticalPager.
Files
- ATTRIBUTION.mdAdded by AutoGineer952 B
- LICENSELicence file added by AutoGineer11.1 KiB
- SKILL.md38.2 KiB
- references/android/training/wearables/compose/migrate-to-material3.md89.1 KiB
- references/foundation/AmbientModeSample.kt.md5.0 KiB
- references/foundation/CurvedWorldSample.kt.md14.3 KiB
- references/foundation/ExpandableSample.kt.md3.6 KiB
- references/foundation/HierarchicalFocusSample.kt.md5.4 KiB
- references/foundation/PagerSamples.kt.md2.0 KiB
- references/foundation/RotarySamples.kt.md6.0 KiB
- references/foundation/SwipeToDismissBoxSample.kt.md7.3 KiB
- references/foundation/TransformingLazyColumnSample.kt.md12.9 KiB
- references/material3/AlertDialogSample.kt.md15.1 KiB
- references/material3/AnimatedTextSample.kt.md6.2 KiB
- references/material3/ButtonGroupSample.kt.md3.3 KiB
- references/material3/ButtonSample.kt.md17.0 KiB
- references/material3/CardSample.kt.md15.2 KiB
- references/material3/CheckboxButtonSample.kt.md2.3 KiB
- references/material3/ConfirmationDialogSample.kt.md5.4 KiB
- references/material3/CurvedTextSamples.kt.md2.9 KiB
- references/material3/DatePickerSample.kt.md4.7 KiB
- references/material3/DynamicColorSchemeSample.kt.md3.0 KiB
- references/material3/EdgeButtonSample.kt.md2.3 KiB
- references/material3/FadingExpandingLabelSample.kt.md2.1 KiB
- references/material3/IconButtonSample.kt.md3.9 KiB
- references/material3/IconToggleButtonSample.kt.md3.6 KiB
- references/material3/LevelIndicatorSample.kt.md2.5 KiB
- references/material3/LinearProgressIndicatorSample.kt.md1.8 KiB
- references/material3/ListHeaderSample.kt.md7.6 KiB
- references/material3/OneHandedGestureSamples.kt.md31.5 KiB
- references/material3/OpenOnPhoneDialogSample.kt.md2.0 KiB
- references/material3/PageIndicatorSample.kt.md4.1 KiB
- references/material3/PagerScaffoldSample.kt.md8.5 KiB
- references/material3/PickerGroupSample.kt.md5.8 KiB
- references/material3/PickerSample.kt.md3.6 KiB
- references/material3/PlaceholderSample.kt.md6.5 KiB
- references/material3/ProgressIndicatorSample.kt.md8.8 KiB
- references/material3/RadioButtonSample.kt.md4.2 KiB
- references/material3/ScaffoldSample.kt.md6.2 KiB
- references/material3/ScrollAwaySample.kt.md3.7 KiB
- references/material3/ScrollIndicatorSample.kt.md2.4 KiB
- references/material3/SliderSample.kt.md2.4 KiB
- references/material3/StepperSample.kt.md5.2 KiB
- references/material3/SurfaceTransformationSample.kt.md6.0 KiB
- references/material3/SwipeToDismissBoxSample.kt.md7.3 KiB
- references/material3/SwipeToRevealSample.kt.md13.7 KiB
- references/material3/SwitchButtonSample.kt.md2.3 KiB
- references/material3/TextButtonSample.kt.md3.0 KiB
- references/material3/TextToggleButtonSample.kt.md2.3 KiB
- references/material3/TimePickerSample.kt.md5.5 KiB
- references/material3/TimeTextSample.kt.md2.5 KiB
- references/material3/TransformationSpecSample.kt.md9.9 KiB
- references/material3/TransformingLazyColumnNotificationsSample.kt.md3.7 KiB
- references/material3/TransformingLazyColumnSample.kt.md13.0 KiB
- references/navigation3/SwipeDismissableSceneStrategySample.kt.md8.3 KiB
LICENSE
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.Requirements and compatibility
Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta
“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.
Needs: Needs network access
Security
No issues found by our static scan· No issues found
A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.
Attribution and licence
- Created by
- Google LLC
- Publisher
- Android (Google) (Official)
- Distributed by
- Android (Google)
- Source
- android/skills · wear/wear-compose-m3 · commit bf68e2d
- Licence
- Apache License 2.0 (redistribution allowed)
- LICENSE (added by AutoGineer from LICENSE.txt)
- ATTRIBUTION.md (written by AutoGineer)
- Synced
AutoGineer is not affiliated with or endorsed by Google LLC or Android (Google).
Download ZIP
The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download wear-compose-m3.zip