javascript - 应用于 Apple IOS 设备上的输入的不可见边框
问题描述
输入在 iOS 设备和所有浏览器上都应用了几乎不可见的边框。
如何删除或阻止应用此样式?
const StyledInputString = styled.input`
width: 40%;
background: #fff;
font-size: 18px;
color: #8f8fa1;
line-height: 1.2;
font-family: 'Montserrat', sans-serif;
outline: none;
border: none;
border-bottom: 1px solid black;
padding-left: 20px;
height: 56px;
margin-bottom: 20px;
&:focus {
border-bottom: 2px solid #03a900;
color: black;
}
应用了样式的示例图像:
解决方案
尝试使用border-radius
属性。
input {
border-radius: 0;
}
也尝试设置
input {
-webkit-appearance: none;
}
推荐阅读
- php - 在 PHPMailer 中将文本标记为引号
- php - 如何验证 PDF?
- java - 如何在 JSON Java 中更改持续时间格式
- reactjs - 如何在 Material UI 上聚焦(涟漪效应?)
- c - Arrays 现在感觉好坏参半?这里到底发生了什么
- mysql - 将 heroku 与 Google Cloud MySql 连接起来
- javascript - JavaScript - 如何使用非字符串键实现字典
- bower - nexus bower 注册表下载到错误的位置
- regex - 正则表达式匹配给定字符串中具有相同字符的字符
- google-cloud-platform - 如何列出 GCP 中属于特定组织的所有项目