mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-07-15 16:26:08 +03:00

Fixes #7546 SwiftUI uses type and structure to identify views, which can lead to issues with tree like structures where the shape and type is the same but the content changes. This was causing #7546. To fix this, we need to add explicit identity to the split tree view so that SwiftUI can differentiate when it needs to redraw the view. We don't want to blindly add Hashable to SplitTree because we don't want to take into account all the fields. Instead, we add an explicit "structural identity" to the SplitTreeView that can be used by SwiftUI.