我正在尝试从下拉列表中删除边框颜色 border-bottom: 1px solid rgba(0, 0, 0, 0.42);
调试的时候发现它来自这个类MuiInput-underline-2593
但是 CSS 类 MuiInput-underline-2593:before
来自框架。
你们能告诉我如何修复它吗?以便将来我可以自己修复它。 在下方提供我的相关代码片段和沙箱链接
https://codesandbox.io/s/4x9lw9qrmx
MuiInput-underline-2593:before {
left: 0;
right: 0;
bottom: 0;
content: "\00a0";
position: absolute;
transition: border-bottom-color 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;
border-bottom: 1px solid rgba(0, 0, 0, 0.42);
pointer-events: none;
}
<Select
className={classes.queryBuilderContainerItem}
classes={classes}
styles={selectStyles}
options={this.state.suggestions}
components={components}
value={this.state.single}
onChange={this.handleChange("network")}
placeholder="Search a to do"
/>
最佳答案
您可以将自己的样式/类添加到您需要的元素中,并使用 !important
后缀设置 border-bottom
规则。这将覆盖您框架中的规则。
.your-class{
border-bottom: 0px !important;
}
关于javascript - 如何从下拉边框底部删除边框颜色?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/53823807/