fix:修复日期选择器无法展示日期的 bug
This commit is contained in:
@@ -13,11 +13,11 @@ android {
|
||||
applicationId = "com.memory.app"
|
||||
minSdk = 26
|
||||
targetSdk = 35
|
||||
versionCode = 20
|
||||
versionName = "1.3.6"
|
||||
versionCode = 22
|
||||
versionName = "1.3.8"
|
||||
|
||||
buildConfigField("String", "API_BASE_URL", "\"https://x.amos.us.kg/api/\"")
|
||||
buildConfigField("int", "VERSION_CODE", "20")
|
||||
buildConfigField("int", "VERSION_CODE", "22")
|
||||
}
|
||||
|
||||
signingConfigs {
|
||||
|
||||
@@ -365,7 +365,7 @@ private fun DatePickerDialog(
|
||||
// Year/Month selector - more elegant
|
||||
Surface(
|
||||
shape = RoundedCornerShape(16.dp),
|
||||
color = Slate50,
|
||||
color = MaterialTheme.colorScheme.surfaceVariant,
|
||||
modifier = Modifier.fillMaxWidth()
|
||||
) {
|
||||
Row(
|
||||
@@ -398,7 +398,7 @@ private fun DatePickerDialog(
|
||||
text = "${selectedYear}年${selectedMonth}月",
|
||||
fontSize = 18.sp,
|
||||
fontWeight = FontWeight.SemiBold,
|
||||
color = Slate800
|
||||
color = MaterialTheme.colorScheme.onSurface
|
||||
)
|
||||
|
||||
IconButton(
|
||||
@@ -433,7 +433,7 @@ private fun DatePickerDialog(
|
||||
textAlign = androidx.compose.ui.text.style.TextAlign.Center,
|
||||
fontSize = 13.sp,
|
||||
fontWeight = FontWeight.Medium,
|
||||
color = if (index == 0 || index == 6) Brand500.copy(alpha = 0.7f) else Slate400
|
||||
color = if (index == 0 || index == 6) Brand500.copy(alpha = 0.7f) else MaterialTheme.colorScheme.onSurfaceVariant
|
||||
)
|
||||
}
|
||||
}
|
||||
@@ -467,7 +467,7 @@ private fun DatePickerDialog(
|
||||
.background(
|
||||
when {
|
||||
isSelected -> Brand500
|
||||
isToday -> Brand100
|
||||
isToday -> Brand500.copy(alpha = 0.2f)
|
||||
else -> Color.Transparent
|
||||
}
|
||||
)
|
||||
@@ -488,8 +488,8 @@ private fun DatePickerDialog(
|
||||
color = when {
|
||||
isSelected -> Color.White
|
||||
isToday -> Brand600
|
||||
isWeekend -> Slate500
|
||||
else -> Slate800
|
||||
isWeekend -> MaterialTheme.colorScheme.onSurfaceVariant
|
||||
else -> MaterialTheme.colorScheme.onSurface
|
||||
}
|
||||
)
|
||||
}
|
||||
@@ -511,7 +511,7 @@ private fun DatePickerDialog(
|
||||
) {
|
||||
Text(
|
||||
"取消",
|
||||
color = Slate500,
|
||||
color = MaterialTheme.colorScheme.onSurfaceVariant,
|
||||
fontSize = 15.sp,
|
||||
fontWeight = FontWeight.Medium
|
||||
)
|
||||
@@ -526,7 +526,7 @@ private fun DatePickerDialog(
|
||||
enabled = selectedDay != null,
|
||||
colors = ButtonDefaults.buttonColors(
|
||||
containerColor = Brand500,
|
||||
disabledContainerColor = Slate200
|
||||
disabledContainerColor = MaterialTheme.colorScheme.surfaceVariant
|
||||
),
|
||||
shape = RoundedCornerShape(12.dp),
|
||||
contentPadding = PaddingValues(horizontal = 24.dp, vertical = 12.dp)
|
||||
|
||||
Reference in New Issue
Block a user