Use generated UIColors everywhere. (#1405)

- Fix destructive buttons in the menu.
This commit is contained in:
Doug
2023-07-26 11:21:34 +01:00
committed by GitHub
parent ed68ed1c91
commit f2ffded87e
10 changed files with 37 additions and 17 deletions
@@ -80,7 +80,7 @@ public struct ElementTextFieldStyle: TextFieldStyle {
}
/// The color of the placeholder text inside the text field.
private var placeholderColor: Color {
private var placeholderColor: UIColor {
.compound.textPlaceholder
}
@@ -134,7 +134,7 @@ public struct ElementTextFieldStyle: TextFieldStyle {
.introspect(.textField, on: .iOS(.v16)) { textField in
textField.clearButtonMode = .whileEditing
textField.attributedPlaceholder = NSAttributedString(string: textField.placeholder ?? "",
attributes: [NSAttributedString.Key.foregroundColor: UIColor(placeholderColor)])
attributes: [NSAttributedString.Key.foregroundColor: placeholderColor])
textField.accessibilityIdentifier = accessibilityIdentifier
}