Skip to content

Commit 708dfc7

Browse files
authored
Merge pull request #6 from bisonbet/pr-28-tap-deselect
Clear text selection on tap outside on iOS
2 parents 00eb0d3 + 905c7c3 commit 708dfc7

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

Sources/Textual/Internal/TextInteraction/UIKit/UITextInteractionView.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@
110110
@objc private func handleTap(_ gesture: UITapGestureRecognizer) {
111111
let location = gesture.location(in: self)
112112
guard let url = model.url(for: location) else {
113+
model.selectedRange = nil
113114
return
114115
}
115116
openURL(url)

0 commit comments

Comments
 (0)