Text view config improvements

This commit is contained in:
Justin Mazzocchi 2021-01-24 14:12:04 -08:00
parent b1cc59a7e9
commit 9cbe7bc004
No known key found for this signature in database
GPG Key ID: E223E6937AAFB01C
5 changed files with 2 additions and 4 deletions

View File

@ -48,7 +48,6 @@ final class AccountFieldView: UIView {
addSubview(valueTextView)
valueTextView.translatesAutoresizingMaskIntoConstraints = false
valueTextView.isScrollEnabled = false
valueTextView.backgroundColor = .clear
if verifiedAt != nil {

View File

@ -290,7 +290,6 @@ private extension AccountHeaderView {
fieldsStackView.layer.cornerRadius = .defaultCornerRadius
baseStackView.addArrangedSubview(noteTextView)
noteTextView.isScrollEnabled = false
noteTextView.delegate = self
baseStackView.addArrangedSubview(followStackView)

View File

@ -89,7 +89,6 @@ private extension AccountView {
accountLabel.font = .preferredFont(forTextStyle: .subheadline)
accountLabel.adjustsFontForContentSizeCategory = true
accountLabel.textColor = .secondaryLabel
noteTextView.isScrollEnabled = false
noteTextView.backgroundColor = .clear
noteTextView.delegate = self

View File

@ -166,7 +166,6 @@ private extension StatusBodyView {
stackView.addArrangedSubview(toggleShowContentButton)
contentTextView.adjustsFontForContentSizeCategory = true
contentTextView.isScrollEnabled = false
contentTextView.backgroundColor = .clear
contentTextView.delegate = self
stackView.addArrangedSubview(contentTextView)

View File

@ -13,6 +13,8 @@ final class TouchFallthroughTextView: UITextView {
clipsToBounds = false
textDragInteraction?.isEnabled = false
isEditable = false
isScrollEnabled = false
delaysContentTouches = false
textContainerInset = .zero
self.textContainer.lineFragmentPadding = 0
linkTextAttributes = [.foregroundColor: tintColor as Any, .underlineColor: UIColor.clear]