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

Fix adjust resize issue for bottom sheet #20

Merged
merged 1 commit into from
Apr 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion countrypicker/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ plugins {

ext {
PUBLISH_GROUP_ID = 'com.canopas.jetcountrypicker'
PUBLISH_VERSION = '1.1.0'
PUBLISH_VERSION = '1.1.1'
PUBLISH_ARTIFACT_ID = 'jetcountrypicker'
}
apply from: "${rootDir}/scripts/publish-module.gradle"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,18 @@
package com.canopas.campose.countrypicker

import androidx.compose.foundation.clickable
import androidx.compose.foundation.layout.ExperimentalLayoutApi
import androidx.compose.foundation.layout.PaddingValues
import androidx.compose.foundation.layout.Row
import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.foundation.layout.imeNestedScroll
import androidx.compose.foundation.layout.imePadding
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.lazy.LazyColumn
import androidx.compose.foundation.lazy.items
import androidx.compose.material3.BottomSheetDefaults
import androidx.compose.material3.Divider
import androidx.compose.material3.ExperimentalMaterial3Api
import androidx.compose.material3.HorizontalDivider
import androidx.compose.material3.LocalTextStyle
import androidx.compose.material3.MaterialTheme
import androidx.compose.material3.ModalBottomSheet
Expand Down Expand Up @@ -50,7 +54,7 @@ import kotlinx.coroutines.launch
* @param countriesTextStyle The text style for the countries list.
* @param onDismissRequest Callback when the bottom sheet is dismissed.
*/
@OptIn(ExperimentalMaterial3Api::class)
@OptIn(ExperimentalMaterial3Api::class, ExperimentalLayoutApi::class)
@Composable
fun CountryPickerBottomSheet(
sheetState: SheetState = rememberModalBottomSheetState(skipPartiallyExpanded = false),
Expand Down Expand Up @@ -79,7 +83,8 @@ fun CountryPickerBottomSheet(
containerColor = containerColor,
contentColor = contentColor,
tonalElevation = tonalElevation,
scrimColor = scrimColor
scrimColor = scrimColor,
modifier = Modifier.fillMaxSize().imePadding().imeNestedScroll()
) {
bottomSheetTitle()

Expand Down Expand Up @@ -144,7 +149,7 @@ internal fun Countries(
style = textStyle
)
}
Divider(color = Color.LightGray, thickness = 0.5.dp)
HorizontalDivider(thickness = 0.5.dp, color = Color.LightGray)
}
}
}
Loading