i write these lines of codes to change background color of filled textfield, but it not work:
import MaterialComponents
...
@IBOutlet weak var textfield: MDCFilledTextField!
let scheme = MDCContainerScheme()
scheme.colorScheme.backgroundColor = .red
scheme.colorScheme.onBackgroundColor = .green
textfield.label.text = "Phone number"
textfield.placeholder = "555-555-55"
textfield.applyTheme(withScheme: scheme)
textfield.sizeToFit()
and finally it looks like this:
but when i change primaryColor scheme.colorScheme.primaryColor = .red
it works. ( just primary color )