I Have a pickerview which does not display text properly as off iOS 14. Does anyone know how to fix this? It seems like there is a subview covering the text?
Is it because I'm using a custom label?
func pickerView(_ pickerView: UIPickerView, viewForRow row: Int, forComponent component: Int, reusing view: UIView?) -> UIView { let pickerLabel = UILabel() let titleData = pickerDataSource[row] pickerView.subviews[1].backgroundColor = .clear pickerView.subviews[0].backgroundColor = .clear let myTitle = NSAttributedString(string: titleData, attributes: [NSAttributedString.Key.font:UIFont.systemFont(ofSize: 18),NSAttributedString.Key.foregroundColor:UIColor.black]) pickerLabel.attributedText = myTitle return pickerLabel }