diff --git a/apps/ios/Snowbound/Lists.swift b/apps/ios/Snowbound/Lists.swift index 042b74c683c30b77751bd66bb7c23ee9cf663bdd..bb98d2ada20ff1145f9b086931a8d54147f8d4ae 100644 --- a/apps/ios/Snowbound/Lists.swift +++ b/apps/ios/Snowbound/Lists.swift @@ -1217,6 +1217,19 @@ final class PagesViewController: UITableViewController { } } cell.contentConfiguration = content + cell.isAccessibilityElement = true + cell.accessibilityLabel = [content.text, content.secondaryText].compactMap { $0 }.joined(separator: ", ") + cell.accessibilityActivateBlock = { [weak self, weak cell] in + guard let self, let cell, let indexPath = self.tableView.indexPath(for: cell) else { return false } + if self.isEditing && cell.isSelected { + self.tableView.deselectRow(at: indexPath, animated: true) + self.tableView(self.tableView, didDeselectRowAt: indexPath) + } else { + self.tableView.selectRow(at: indexPath, animated: true, scrollPosition: .none) + self.tableView(self.tableView, didSelectRowAt: indexPath) + } + return true + } cell.accessibilityCustomActions = arrangeActions(item) return cell }