📌  相关文章
📜  检查输入是否为空 css 代码示例

📅  最后修改于: 2022-03-11 14:47:33.884000             🧑  作者: Mango

代码示例1
/* If input is not empty */
input:not(:placeholder-shown) {
  /* You need to add a placeholder to your fields. For example:  */
  border-color: green;
}

/* If input is empty */
input:placeholder-shown {
  border-color: red;
}