Hide ion input validation border in IONIC-3 [duplicate]

ぐ巨炮叔叔 提交于 2019-12-21 19:49:01

问题


Im used ionic 3 , i want to know how to remove validation border color, red and green .

I tried to removed, using this css

.item-inner { border-bottom-color: transparent !important; box-shadow: none !important; }

its not work, that solution is removed every focus line , any one know how to remove only validation color


回答1:


If you want for all input fields:

You can override the following scss variables which are set by default for android material design:

$text-input-highlight-color-valid:transparent;
$text-input-highlight-color-invalid:transparent;

For individual elements you can have a custom class in your corresponding scss class and then set border-bottom for ng-valid, ng-invalid classes with border-bottom-color.

.my-input.ng-invalid{
   border-bottom-color: transparent;
}
.my-input.ng-valid{
   border-bottom-color: transparent;
}


来源:https://stackoverflow.com/questions/48800465/hide-ion-input-validation-border-in-ionic-3

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!