mirror of
https://github.com/FBukovina/Atoll.git
synced 2026-10-27 15:14:33 +00:00
Working Focus mode - focus type not yet supported
This commit is contained in:
parent
4444df4cb4
commit
b643f1d905
3 changed files with 95 additions and 29 deletions
|
|
@ -40,8 +40,15 @@ struct FocusIndicator: View {
|
|||
|
||||
private var accessibilityLabel: String {
|
||||
let trimmedName = manager.currentFocusModeName.trimmingCharacters(in: .whitespacesAndNewlines)
|
||||
let name = trimmedName.isEmpty ? focusMode.displayName : trimmedName
|
||||
return "Focus active: \(name)"
|
||||
let baseName: String
|
||||
if trimmedName.isEmpty {
|
||||
baseName = focusMode.displayName
|
||||
} else {
|
||||
baseName = trimmedName
|
||||
}
|
||||
|
||||
let finalName = focusMode == .doNotDisturb ? "Focus" : baseName
|
||||
return "Focus active: \(finalName)"
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue