Skip to content

Commit a89f555

Browse files
mickael-menustreamg
authored andcommitted
Fix accessibility editing actions on iOS 18 (readium#505)
1 parent b6ef3c1 commit a89f555

File tree

2 files changed

+15
-2
lines changed

2 files changed

+15
-2
lines changed

CHANGELOG.md

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,18 @@ All notable changes to this project will be documented in this file. Take a look
44

55
**Warning:** Features marked as *alpha* may change or be removed in a future release without notice. Use with caution.
66

7-
<!-- ## [Unreleased] -->
7+
## [Unreleased]
8+
9+
### Fixed
10+
11+
#### Navigator
12+
13+
* [#502](https://github.com/readium/swift-toolkit/issues/502) Fixed accessibility editing actions on iOS 18.
14+
815

916
## [2.7.3]
1017

11-
* [#483](https://github.com/readium/swift-toolkit/issues/483) Fix build on Xcode 16.
18+
* [#483](https://github.com/readium/swift-toolkit/issues/483) Fixed build on Xcode 16.
1219

1320

1421
## [2.7.2]

Sources/Navigator/EditingAction.swift

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,12 @@ final class EditingActionsController {
120120
}
121121

122122
func canPerformAction(_ selector: Selector) -> Bool {
123+
// Accessibility editing actions (e.g. Spoken Option in Accessibility
124+
// system settings) cannot be properly disabled.
125+
guard !selector.description.hasPrefix("_accessibility") else {
126+
return true
127+
}
128+
123129
guard
124130
isEnabled,
125131
let selection = selection,

0 commit comments

Comments
 (0)