<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: M. Sarmad Qadeer</title>
    <description>The latest articles on DEV Community by M. Sarmad Qadeer (@msarmadqadeer).</description>
    <link>https://dev.to/msarmadqadeer</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F1262458%2F29487728-58e4-46c0-829c-80ac35f15752.png</url>
      <title>DEV Community: M. Sarmad Qadeer</title>
      <link>https://dev.to/msarmadqadeer</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/msarmadqadeer"/>
    <language>en</language>
    <item>
      <title>Facing issue with ModalBottomSheet in Jetpack Compose.</title>
      <dc:creator>M. Sarmad Qadeer</dc:creator>
      <pubDate>Sun, 21 Jan 2024 20:38:50 +0000</pubDate>
      <link>https://dev.to/msarmadqadeer/facing-issue-with-modalbottomsheet-in-jetpack-compose-3pgk</link>
      <guid>https://dev.to/msarmadqadeer/facing-issue-with-modalbottomsheet-in-jetpack-compose-3pgk</guid>
      <description>&lt;p&gt;I am using ModalBottomSheet but I am facing two issues:&lt;/p&gt;

&lt;p&gt;1) There is a white line on the right corner of the scrim.&lt;br&gt;
2) The scrim color is not animating while opening and closing of ModalBottomSheet.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6fbovf1fstv2n6gr5vy0.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6fbovf1fstv2n6gr5vy0.jpg" alt="Image description" width="720" height="1600"&gt;&lt;/a&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F22qtd9a1rkoj9ucsr52f.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F22qtd9a1rkoj9ucsr52f.jpg" alt="Image description" width="720" height="1600"&gt;&lt;/a&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;val sheetState = rememberModalBottomSheetState()
val scope = rememberCoroutineScope()
var showBottomSheet by remember { mutableStateOf(false) }
Button(onClick = {
    showBottomSheet = true
}) {
    Icon(Icons.Filled.Add, contentDescription = "")
    Text("Show bottom sheet")
}

if (showBottomSheet) {
    ModalBottomSheet(
        onDismissRequest = { showBottomSheet = false },
        sheetState = sheetState,
        dragHandle = { Text(text = "") },
        scrimColor = Color.Black.copy(alpha = 0.63f),
        containerColor = Color.White,
        modifier = Modifier.height(280.dp),
        windowInsets = WindowInsets(0,0,0,0)
    ) {
        Column(
            horizontalAlignment = Alignment.CenterHorizontally,
            verticalArrangement = Arrangement.Center,
            modifier = Modifier.fillMaxSize().padding(16.dp)
        ) {
            Text(text = "This is a bottom sheet")
            Spacer(modifier = Modifier.height(16.dp))
            Button(onClick = {
                scope.launch { sheetState.hide() }.invokeOnCompletion {
                    if (!sheetState.isVisible) {
                        showBottomSheet = false
                    }
                }
            }) {
                Text("Hide bottom sheet")
            }
        }
    }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



</description>
      <category>jetpack</category>
      <category>jetpackcompose</category>
      <category>compose</category>
      <category>android</category>
    </item>
  </channel>
</rss>
