物料组件-文本字段-IOS [英] Material Components - Text Field - IOS
本文介绍了物料组件-文本字段-IOS的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我是快速编程的新手,我需要使用浮动占位符输入来设计登录页面.我已经使用POD安装了MDCTextInput.
I'm newbie to swift programming, i need to design the login page with floating placeholder input. I have installed the MDCTextInput using POD.
添加了导入
import MaterialComponents.MaterialTextFields
并在以下代码的viewDidLoad()中添加了
and in viewDidLoad() below code added,
companyID.placeholder = "Company ID"
companyID.placeholderLabel.highlightedTextColor = UIColor.white
companyID.placeholderLabel.textColor = UIColor.white
companyID.underline?.color = UIColor.white
companyID.delegate = self
我遵循了IOS中材料组件"中给出的步骤
i have followed the steps given in Material components in IOS
我不清楚这条线,
To achieve the animations and presentations defined by the guidelines (floating placeholders, character counts), a controller that conforms to protocol MDCTextInputController must be initialized to manage the text field.
我没有获得浮动占位符动画,如何在swift4中做到这一点?请任何人给我一个主意.
I am not getting floating placeholder animation, how to do this in swift4 ? please anybody provide me an idea .
Material iOS Github链接为:
The Material iOS Github Link is:
这篇关于物料组件-文本字段-IOS的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文