Skip to content

Commit

Permalink
Do not focus on sideBar
Browse files Browse the repository at this point in the history
  • Loading branch information
DominikBucher12 committed Jan 18, 2024
1 parent 53ecbf4 commit 0f93a95
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 13 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// RichTextCoordinator+ColorSubscriptions.swift
//
//
//
// Created by Dominik Bucher on 18.01.2024.
//
Expand Down
12 changes: 0 additions & 12 deletions Sources/RichTextKit/Format/RichTextFormatSidebar.swift
Original file line number Diff line number Diff line change
Expand Up @@ -79,22 +79,10 @@ public struct RichTextFormatSidebar: View {
Spacer()
}
.padding(8)
.prefersFocusable()
.background(Color.white.opacity(0.05))
}
}

private extension View {

@ViewBuilder
func prefersFocusable() -> some View {
if #available(iOS 17.0, macOS 14.0, *) {
self.focusable()
} else {
self
}
}
}

private struct SidebarSection<Content: View>: View {

Expand Down

0 comments on commit 0f93a95

Please sign in to comment.