From 0422d0b7cdf816f911b25b3f5f8b9a3472693a03 Mon Sep 17 00:00:00 2001 From: YuKongA <70465933+YuKongA@users.noreply.github.com> Date: Sat, 11 Jan 2025 12:12:41 +0800 Subject: [PATCH] app: Change the ShadowColor of the SuperPopup --- .../src/commonMain/kotlin/ui/components/SuperPopup.kt | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/composeApp/src/commonMain/kotlin/ui/components/SuperPopup.kt b/composeApp/src/commonMain/kotlin/ui/components/SuperPopup.kt index d076ca2..a3751ae 100644 --- a/composeApp/src/commonMain/kotlin/ui/components/SuperPopup.kt +++ b/composeApp/src/commonMain/kotlin/ui/components/SuperPopup.kt @@ -23,7 +23,6 @@ import androidx.compose.runtime.rememberUpdatedState import androidx.compose.runtime.setValue import androidx.compose.ui.AbsoluteAlignment import androidx.compose.ui.Modifier -import androidx.compose.ui.graphics.Color import androidx.compose.ui.graphics.TransformOrigin import androidx.compose.ui.graphics.graphicsLayer import androidx.compose.ui.input.pointer.pointerInput @@ -123,9 +122,7 @@ fun SuperPopup( } if (show.value) { - val dropdownElevation by rememberUpdatedState(with(density) { - 11.dp.toPx() - }) + val dropdownElevation by rememberUpdatedState(with(density) { 22.dp.toPx() }) showOwnPopup( transformOrigin = { transformOrigin } ) { @@ -164,8 +161,8 @@ fun SuperPopup( clip = true, shape = SmoothRoundedCornerShape(16.dp), shadowElevation = dropdownElevation, - ambientShadowColor = Color.Black.copy(alpha = 0.3f), - spotShadowColor = Color.Black.copy(alpha = 0.3f) + ambientShadowColor = MiuixTheme.colorScheme.windowDimming, + spotShadowColor = MiuixTheme.colorScheme.windowDimming ) .background(MiuixTheme.colorScheme.surface) ) {