Skip to content

Commit

Permalink
updated readme files and compose versions
Browse files Browse the repository at this point in the history
  • Loading branch information
Gurupreet Singh committed Jul 12, 2022
1 parent a7c5702 commit 139e101
Show file tree
Hide file tree
Showing 7 changed files with 15 additions and 6 deletions.
8 changes: 7 additions & 1 deletion Reply/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,15 @@ This sample showcases:
The [WindowSizeClass](https://developer.android.com/reference/kotlin/androidx/compose/material3/windowsizeclass/WindowSizeClass) allows us to get to know about current device size and configuration
and observe any changes in device size in case of orientation change or unfolding of device.

<img src="screenshots/dynamic_size.gif"/>


#### [Dynamic fold detection](app/src/main/java/com/example/reply/ui/MainActivity.kt#56)
The [WindowLayoutInfo](https://developer.android.com/reference/kotlin/androidx/window/layout/WindowLayoutInfo) let us observe all display features including [Folding Postures](app/src/main/java/com/example/reply/ui/utils/WindowStateUtils.kt)
real-time whenever fold state changes to help us adjust our UI accordingly.
real-time whenever fold state changes to help us adjust our UI accordingly.

<img src="screenshots/fold_unfold.png">


#### [Material 3 navigation components](app/src/main/java/com/example/reply/ui/navigation/ReplyNavigationComponents.kt)
The sample provides usage of material navigation components depending on screen size and states. These components also are part of material guidelines for canonical layouts to improve user experience and ergonomics.
Expand Down
6 changes: 3 additions & 3 deletions Reply/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ android {
compose true
}
composeOptions {
kotlinCompilerExtensionVersion compose_version
kotlinCompilerExtensionVersion compose_compiler_version
}
packagingOptions {
resources {
Expand All @@ -71,8 +71,8 @@ dependencies {
implementation "androidx.compose.ui:ui-tooling-preview:$compose_version"

//Material 3 imports
implementation 'androidx.compose.material3:material3:1.0.0-alpha13'
implementation "androidx.compose.material3:material3-window-size-class:1.0.0-alpha13"
implementation "androidx.compose.material3:material3:$material3_version"
implementation "androidx.compose.material3:material3-window-size-class:$material3_version"
implementation "androidx.compose.material:material-icons-extended:$compose_version"


Expand Down
1 change: 1 addition & 0 deletions Reply/app/src/main/java/com/example/reply/ui/ReplyApp.kt
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ import androidx.compose.foundation.background
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.Row
import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.material3.Button
import androidx.compose.material3.DrawerValue
import androidx.compose.material3.ExperimentalMaterial3Api
import androidx.compose.material3.MaterialTheme
Expand Down
6 changes: 4 additions & 2 deletions Reply/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,10 @@

buildscript {
ext {
kotlin_version = '1.6.21'
compose_version = '1.2.0-rc02'
kotlin_version = '1.7.0'
compose_version = '1.2.0-rc03'
compose_compiler_version = '1.2.0'
material3_version = "1.0.0-alpha14"
coroutines_version = '1.6.0'
agp_version = "7.2.1"
}
Expand Down
Binary file added Reply/screenshots/dynamic_size.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added Reply/screenshots/fold_unfold.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed readme/screenshots/Reply.png
Binary file not shown.

0 comments on commit 139e101

Please sign in to comment.