Skip to content

Commit 645bec6

Browse files
authored
Merge pull request #39 from SubvertDev/feature/page-navigation-input
Fixes keyboard button
2 parents ac081d9 + 78ee65f commit 645bec6

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

Modules/Sources/PageNavigationFeature/PageNavigationView.swift

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -84,13 +84,15 @@ public struct PageNavigation: View {
8484
store.page = String(min(Int(store.page.filter(\.isNumber))!, store.totalPages))
8585
}
8686
.toolbar {
87-
ToolbarItemGroup(placement: .keyboard) {
88-
Spacer()
89-
90-
Button {
91-
store.send(.doneButtonTapped)
92-
} label: {
93-
Text("Done", bundle: .module)
87+
if focus == .page {
88+
ToolbarItemGroup(placement: .keyboard) {
89+
Spacer()
90+
91+
Button {
92+
store.send(.doneButtonTapped)
93+
} label: {
94+
Text("Done", bundle: .module)
95+
}
9496
}
9597
}
9698
}

0 commit comments

Comments
 (0)