Skip to content

Commit

Permalink
Fix accessibility editing actions on iOS 18 (#505)
Browse files Browse the repository at this point in the history
  • Loading branch information
mickael-menu authored Nov 15, 2024
1 parent cca64ec commit 199fdff
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 2 deletions.
11 changes: 9 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,18 @@ All notable changes to this project will be documented in this file. Take a look

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

<!-- ## [Unreleased] -->
## [Unreleased]

### Fixed

#### Navigator

* [#502](https://github.com/readium/swift-toolkit/issues/502) Fixed accessibility editing actions on iOS 18.


## [2.7.3]

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


## [2.7.2]
Expand Down
6 changes: 6 additions & 0 deletions Sources/Navigator/EditingAction.swift
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,12 @@ final class EditingActionsController {
}

func canPerformAction(_ selector: Selector) -> Bool {
// Accessibility editing actions (e.g. Spoken Option in Accessibility
// system settings) cannot be properly disabled.
guard !selector.description.hasPrefix("_accessibility") else {
return true
}

guard
isEnabled,
let selection = selection,
Expand Down

0 comments on commit 199fdff

Please sign in to comment.