Fix notification ring not appearing on terminal panes
TerminalPanelView and PanelContentView held notificationStore as a plain `let` property. Since it's a reference type (class), SwiftUI's structural diffing saw no change when notifications were added and skipped re-evaluating the view body. Changed to @ObservedObject var so the views properly subscribe to the store's @Published changes. Closes #126
This commit is contained in:
parent
d74d2afb01
commit
cef1513ceb
2 changed files with 2 additions and 2 deletions
|
|
@ -10,7 +10,7 @@ struct PanelContentView: View {
|
|||
let portalPriority: Int
|
||||
let isSplit: Bool
|
||||
let appearance: PanelAppearance
|
||||
let notificationStore: TerminalNotificationStore
|
||||
@ObservedObject var notificationStore: TerminalNotificationStore
|
||||
let onFocus: () -> Void
|
||||
let onRequestPanelFocus: () -> Void
|
||||
let onTriggerFlash: () -> Void
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ struct TerminalPanelView: View {
|
|||
let portalPriority: Int
|
||||
let isSplit: Bool
|
||||
let appearance: PanelAppearance
|
||||
let notificationStore: TerminalNotificationStore
|
||||
@ObservedObject var notificationStore: TerminalNotificationStore
|
||||
let onFocus: () -> Void
|
||||
let onTriggerFlash: () -> Void
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue