0

Как не затрагивая разметку, сделать такую же стрелку с другим цветом, на словах наши работы?

.speedbar {
    margin: 0 10px 10px 8px;
    text-transform: uppercase;
    text-align: left;
}
.speedbar a {
background: #ef5350;
border-radius: 2px 0 0 2px;
margin: 4px 15px 0 4px;
padding: 3px 0 3px 10px;
position: relative;
text-align: center;
color: #fff;
line-height: 1.5;
text-decoration: none;
}
.speedbar a::after {
    border-bottom: 12px solid transparent;
    border-left: 12px solid #ef5350;
    border-top: 12px solid transparent;
    content: "";
    position: absolute;
    right: -12px;
    top: 0;
    z-index: 1;
}
<div class="speedbar">
  <div class="over">
    <span id="dle-speedbar">
      <span itemscope="" itemtype="http://data-vocabulary.org/Breadcrumb">
        <a href="/" itemprop="url">
          <span itemprop="title">Мебель</span>
        </a>
        <a href="/" itemprop="url">
          <span itemprop="title">Все работы</span>
        </a>       
      </span>
      Наши работы
    </span>    
  </div>
</div>

1
  • Скорее всего никак
    – andreymal
    31 янв 2019 в 9:20

1 ответ 1

3

.speedbar {
  margin: 0 10px 10px 8px;
  text-transform: uppercase;
  text-align: left;
}

.speedbar a {
  background: #ef5350;
  border-radius: 2px 0 0 2px;
  margin: 4px 15px 0 4px;
  padding: 3px 0 3px 10px;
  position: relative;
  text-align: center;
  color: #fff;
  line-height: 1.5;
  text-decoration: none;
}

.speedbar a::after {
  border-bottom: 12px solid transparent;
  border-left: 12px solid #ef5350;
  border-top: 12px solid transparent;
  content: "";
  position: absolute;
  right: -12px;
  top: 0;
  z-index: 1;
}

.speedbar b::after {
  border-bottom: 12px solid transparent;
  border-left: 12px solid #fff;
  border-top: 12px solid transparent;
  content: "";
  position: absolute;
  right: -12px;
  top: 0;
  transition: all 0.3s ease 0s;
  z-index: 1;
}

.speedbar b::before {
  border-bottom: 12px solid transparent;
  border-left: 12px solid #eee;
  border-top: 12px solid transparent;
  content: "";
  left: 0;
  position: absolute;
  top: 0;
}


/*  */

#dle-speedbar a:last-child {
  margin-right: 25px;
}

#dle-speedbar {
  display: inline-block;
  position: relative;
}

#dle-speedbar::before,
#dle-speedbar::after {
  content: '';
  display: block;
  pointer-events: none;
}

#dle-speedbar::before {
  width: 126px; /* Ширина текста + отступ слева (10px) */
  height: 100%;
  border-radius: 2px 0 0 2px;
  position: absolute;
  right: -3px;
  top: 0;
  bottom: 0;
  background: darksalmon;
  z-index: -1;
}

#dle-speedbar::after {
  width: 0;
  height: 0;
  border: 12px solid transparent;
  border-left-color: darksalmon;
  position: absolute;
  right: -27px;
  top: 0;
}
<div class="speedbar">
  <div class="over">
    <span id="dle-speedbar">
      <span itemscope="" itemtype="http://data-vocabulary.org/Breadcrumb">
        <a href="/" itemprop="url">
          <span itemprop="title">Мебель</span>
    </a>
    <a href="/" itemprop="url">
      <span itemprop="title">Все работы</span>
    </a>
    </span>
    Наши работы
    </span>
  </div>
</div>

2
  • Прочитайте вопрос ещё раз.
    – steep
    31 янв 2019 в 9:36
  • @steep, подправил
    – De.Minov
    31 янв 2019 в 10:00

Ваш ответ

Нажимая на кнопку «Отправить ответ», вы соглашаетесь с нашими пользовательским соглашением, политикой конфиденциальности и политикой о куки

Всё ещё ищете ответ? Посмотрите другие вопросы с метками или задайте свой вопрос.