在Safari 10中,可以通过以下步骤隐藏自动添加的输入按钮:
示例代码:
<input type="text" autocorrect="off">
input[type="text"]::-webkit-search-cancel-button,
input[type="search"]::-webkit-search-cancel-button {
-webkit-appearance: none;
appearance: none;
display: none;
}
这段CSS代码将隐藏所有类型为"text"或"search"的输入框中的取消按钮。
以上是在Safari 10中隐藏自动添加的输入按钮的方法。这样做可以提升用户体验,避免不必要的干扰。
领取专属 10元无门槛券
手把手带您无忧上云