📜  CSS隐藏每行上的第一个li分隔符 - 响应式水平css菜单 - 无论代码示例

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

代码示例3
ul {
  font-size: 0;
  overflow: hidden;
  padding: 0;
}

li {
  font-size: 16px;
  display: inline-block;
  margin: 0;
  padding: 0;
  color: gray;
  position: relative;
  padding-right: 2rem;
}

li::before {
  content: "|";
  position: relative;
  left: -1rem;
  font-weight: bold;
  color: black;
}