mirror of
https://github.com/metabolist/metatext.git
synced 2024-06-02 07:51:31 +00:00
VoiceOver wip
This commit is contained in:
parent
29d8d609b5
commit
3059604776
|
@ -12,6 +12,7 @@ extension NSMutableAttributedString {
|
||||||
while let tokenRange = string.range(of: token) {
|
while let tokenRange = string.range(of: token) {
|
||||||
let attachment = NSTextAttachment()
|
let attachment = NSTextAttachment()
|
||||||
|
|
||||||
|
attachment.accessibilityLabel = emoji.shortcode
|
||||||
attachment.kf.setImage(with: emoji.url, attributedView: view)
|
attachment.kf.setImage(with: emoji.url, attributedView: view)
|
||||||
replaceCharacters(in: NSRange(tokenRange, in: string), with: NSAttributedString(attachment: attachment))
|
replaceCharacters(in: NSRange(tokenRange, in: string), with: NSAttributedString(attachment: attachment))
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue