always make sure we use the latest styles

This commit is contained in:
Hailey
2024-01-12 19:17:51 -08:00
parent 7f05d0141b
commit 860610e63a
@@ -5,12 +5,14 @@ class ExpoSelectableTextView: ExpoView {
let textView: UITextView = UITextView() let textView: UITextView = UITextView()
var segments: Array<TextSegment> = [] { var segments: Array<TextSegment> = [] {
didSet { didSet {
setText() // We don't want to set the text if the root style has not been set yet
self.setText()
} }
} }
var style: TextStyle? { var style: TextStyle? {
didSet { didSet {
self.setNeedsLayout() // If the text has not been set and there are segments, set the text
self.setText()
} }
} }