V
V
Valentin Fetisov2017-04-20 11:17:50
Less
Valentin Fetisov, 2017-04-20 11:17:50

How to correctly write pseudo elements in less?

Hello! I ran into a problem I can not figure it out myself, I ask for your help!
There is such a block:
0fe3bf3e96584f6a809c75bfe78e8fd2.JPG
tell me where I cant? how to remove the pseudo element before the first menu item?
Here are the pieces of code and styles:

<section id="project">
    <div class="resize clear">
      <h2>Реализованные ПРОЕКТЫ</h2>
      <menu>
        <li><a href="#">Кухни</a></li>
        <li><a href="#">Раздвижные двери</a></li>
        <li><a href="#">Шкафы-купе</a></li>
        <li><a href="#">Офисная мебель</a></li>
        <li><a href="#">Стеновые панели</a></li>
      </menu>

menu {
    text-align: justify;
    line-height: 0;
    padding: 0;
    margin-left: 30px;
    margin-right: 30px;
    &:after {
      width: 100%;
      height: 0;
      visibility: hidden;
      overflow: hidden;
      content: "";
      display: inline-block;
    }
    li {
      display: inline-block;
      text-align: left;
      padding: 5px 0;
      position: relative;

      a {
        display: block;
        font-size: 20px;
        line-height: 1.3em;
        color: #0d0d0d;
        text-transform: uppercase;
        &:hover {
          color: #c31e2f;
        }

      }
    }
    &:not(:first-child) li:before {
      top: 18px;
      left: -35px;
      content: "\\\\";
      position: absolute;
      font-size: 20px;
      width: 5px;
      height: 5px;
      color: #a6a6a6;
    }
  }

Thank you.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question