feat: 样式细节调整
This commit is contained in:
parent
982c32cfdb
commit
6bf52f1286
@ -1003,7 +1003,8 @@ struct BlindBoxView: View {
|
||||
showSettings: $showSettings
|
||||
)
|
||||
}
|
||||
.offset(x: showSettings ? UIScreen.main.bounds.width : 0)
|
||||
.shadow(color: .black.opacity(0.3), radius: 10, x: 5, y: 0)
|
||||
.offset(x: showSettings ? UIScreen.main.bounds.width : 0)
|
||||
.animation(.spring(response: 0.6, dampingFraction: 0.8), value: showSettings)
|
||||
|
||||
// 设置页面遮罩层
|
||||
|
||||
@ -121,7 +121,6 @@ struct UserProfileModal: View {
|
||||
.background(
|
||||
RoundedRectangle(cornerRadius: 16)
|
||||
.fill(Color.white)
|
||||
.shadow(color: .black.opacity(0.1), radius: 4, x: 0, y: 2)
|
||||
)
|
||||
.padding(.horizontal)
|
||||
|
||||
@ -259,14 +258,12 @@ struct UserProfileModal: View {
|
||||
.background(
|
||||
RoundedRectangle(cornerRadius: 16)
|
||||
.fill(Color.white)
|
||||
.shadow(color: .black.opacity(0.1), radius: 4, x: 0, y: 2)
|
||||
)
|
||||
.padding(.horizontal)
|
||||
Spacer()
|
||||
}
|
||||
.frame(width: UIScreen.main.bounds.width * 0.8)
|
||||
.background(Color.themeTextWhiteSecondary)
|
||||
.cornerRadius(20, corners: [.topRight, .bottomRight])
|
||||
.edgesIgnoringSafeArea(.all)
|
||||
.onAppear {
|
||||
fetchUserInfo()
|
||||
|
||||
@ -121,11 +121,11 @@ struct AccountView: View {
|
||||
|
||||
}) {
|
||||
Text("Confirm")
|
||||
.foregroundColor(.themeTextMessage)
|
||||
.foregroundColor(.themeTextWhite)
|
||||
.font(.system(size: 12))
|
||||
.frame(maxWidth: .infinity)
|
||||
.padding()
|
||||
.background(Color.white)
|
||||
.background(Color.themeTextWhiteSecondary)
|
||||
.cornerRadius(32)
|
||||
}
|
||||
}
|
||||
|
||||
@ -145,8 +145,16 @@ struct PermissionRow: View {
|
||||
// 权限开关
|
||||
Toggle("", isOn: .constant(isEnabled))
|
||||
.labelsHidden()
|
||||
.tint(Color.themePrimary) // 使用主题色
|
||||
.disabled(true) // 禁用交互,仅用于显示状态
|
||||
.tint(Color.themePrimary)
|
||||
.disabled(true)
|
||||
.onAppear {
|
||||
// 使用主题色并确保完全不透明
|
||||
let themeColor = UIColor(Color.themePrimary)
|
||||
UISwitch.appearance(whenContainedInInstancesOf: [UIView.self]).onTintColor = themeColor
|
||||
UISwitch.appearance(whenContainedInInstancesOf: [UIView.self]).thumbTintColor = .white
|
||||
// 确保使用不透明的背景
|
||||
UISwitch.appearance(whenContainedInInstancesOf: [UIView.self]).backgroundColor = UIColor.clear
|
||||
}
|
||||
}
|
||||
.padding()
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user