Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate package name for v1.2.0-alpha03 release #663

Closed
shumelchyk opened this issue Jan 24, 2023 · 1 comment
Closed

Migrate package name for v1.2.0-alpha03 release #663

shumelchyk opened this issue Jan 24, 2023 · 1 comment

Comments

@shumelchyk
Copy link
Collaborator

shumelchyk commented Jan 24, 2023

Compose for Wear OS 1.2.0-alpha03 release introduce package name changes for number of existing classes, like ScalingLazyColumn: androidx.wear.compose.material -> androidx.wear.foundation.lazy.

For seamless migration in your app you can apply the script below:

grep -rl 'import androidx.wear.compose.material' . | xargs perl -p -i -e 's/import androidx.wear.compose.material.rememberScalingLazyListState/import androidx.wear.compose.foundation.lazy.rememberScalingLazyListState/;' -e 's/import androidx.wear.compose.material.Scaling/import androidx.wear.compose.foundation.lazy.Scaling/;' -e 's/import androidx.wear.compose.material.items/import androidx.wear.compose.foundation.lazy.items/;' -e 's/import androidx.wear.compose.material.AutoCenteringParams/import androidx.wear.compose.foundation.lazy.AutoCenteringParams/;'

@shumelchyk shumelchyk changed the title Migrate package names for v1.2.0-alpha03 release Migrate package name for v1.2.0-alpha03 release Jan 24, 2023
@shumelchyk
Copy link
Collaborator Author

Completed via #668.

shumelchyk added a commit to android/codelab-compose-for-wear-os that referenced this issue Aug 9, 2023
shumelchyk added a commit to android/codelab-compose-for-wear-os that referenced this issue Aug 9, 2023
* Update dependencies Jetpack dependencies and bump Compose for Wear OS to version 1.2.

* Migrate ScalingLazyColumn to use from the foundation.lazy package (used script from android/wear-os-samples#663)

* - Update Preview annotations to use wear configuration mode (with round views) for component preview
- Use multi-device preview for main app screen
- Remove obsolete PreviewConstants

* Bump Compose for Wear OS to v1.2 stable
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant