mirror of
https://github.com/MioMioOS/MioIsland
synced 2026-04-21 13:37:26 +00:00
style: check for updates button hover uses brand lime color
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
5cfb500ea8
commit
952a9ebaae
1 changed files with 34 additions and 20 deletions
|
|
@ -673,26 +673,7 @@ private struct AboutTab: View {
|
|||
}
|
||||
}
|
||||
|
||||
SettingsCard {
|
||||
Button {
|
||||
updater.checkForUpdates()
|
||||
} label: {
|
||||
HStack(spacing: 8) {
|
||||
Image(systemName: "arrow.triangle.2.circlepath")
|
||||
.font(.system(size: 12))
|
||||
Text(L10n.checkForUpdates)
|
||||
.font(.system(size: 12, weight: .semibold))
|
||||
Spacer()
|
||||
Image(systemName: "chevron.right")
|
||||
.font(.system(size: 9, weight: .semibold))
|
||||
.opacity(0.4)
|
||||
}
|
||||
.foregroundColor(Theme.detailText.opacity(0.9))
|
||||
}
|
||||
.buttonStyle(.plain)
|
||||
.disabled(!updater.canCheckForUpdates)
|
||||
.opacity(updater.canCheckForUpdates ? 1.0 : 0.5)
|
||||
}
|
||||
CheckForUpdatesCard(updater: updater)
|
||||
|
||||
SettingsCard {
|
||||
HStack(spacing: 8) {
|
||||
|
|
@ -814,6 +795,39 @@ private struct AboutTab: View {
|
|||
}
|
||||
}
|
||||
|
||||
// MARK: - Check for Updates card (with hover)
|
||||
|
||||
private struct CheckForUpdatesCard: View {
|
||||
@ObservedObject var updater: UpdaterManager
|
||||
@State private var isHovered = false
|
||||
|
||||
private let brandLime = Color(red: 0xCA/255, green: 0xFF/255, blue: 0x00/255)
|
||||
|
||||
var body: some View {
|
||||
SettingsCard {
|
||||
Button {
|
||||
updater.checkForUpdates()
|
||||
} label: {
|
||||
HStack(spacing: 8) {
|
||||
Image(systemName: "arrow.triangle.2.circlepath")
|
||||
.font(.system(size: 12))
|
||||
Text(L10n.checkForUpdates)
|
||||
.font(.system(size: 12, weight: .semibold))
|
||||
Spacer()
|
||||
Image(systemName: "chevron.right")
|
||||
.font(.system(size: 9, weight: .semibold))
|
||||
.opacity(0.4)
|
||||
}
|
||||
.foregroundColor(isHovered ? brandLime : Theme.detailText.opacity(0.9))
|
||||
}
|
||||
.buttonStyle(.plain)
|
||||
.disabled(!updater.canCheckForUpdates)
|
||||
.opacity(updater.canCheckForUpdates ? 1.0 : 0.5)
|
||||
.onHover { isHovered = $0 }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// MARK: - cmux Connection tab
|
||||
|
||||
/// Phone → terminal relay diagnostics. Replaces the invisible failure modes
|
||||
|
|
|
|||
Loading…
Reference in a new issue