Various fixes

This commit is contained in:
Ilya Laktyushin
2022-10-07 23:02:02 +03:00
parent 38c7c7e0a6
commit 45de8cbbd9
15 changed files with 290 additions and 66 deletions

View File

@@ -66,10 +66,6 @@ public final class CodeInputView: ASDisplayNode, UITextFieldDelegate {
self.borderColorValue = borderColor
let previousColor = self.backgroundView.layer.borderColor
self.backgroundView.layer.cornerRadius = 15.0
if #available(iOS 13.0, *) {
self.backgroundView.layer.cornerCurve = .continuous
}
self.backgroundView.layer.borderColor = UIColor(argb: borderColor).cgColor
self.backgroundView.layer.borderWidth = 1.0 + UIScreenPixel
if let previousColor = previousColor {
@@ -98,6 +94,11 @@ public final class CodeInputView: ASDisplayNode, UITextFieldDelegate {
}
}
self.backgroundView.layer.cornerRadius = size.height == 28.0 ? 12.0 : 15.0
if #available(iOS 13.0, *) {
self.backgroundView.layer.cornerCurve = .continuous
}
if #available(iOS 13.0, *) {
self.textNode.attributedText = NSAttributedString(string: text, font: UIFont.monospacedSystemFont(ofSize: fontSize, weight: .regular), textColor: UIColor(argb: textColor))
} else {