E
E
Essa2016-04-12 15:20:49
css
Essa, 2016-04-12 15:20:49

How to use CSS to change font size (not font-size)?

Essence of the question: when using a certain font, border-bottom fellVm6xjBwSx5eNoA.jpg

<div class="contacts_feadback">
                            <ul class="list header__feadback">
                                <li class="contacts__item"><a class="feadback" href="#">Заказать обратный звонок</a></li><li class="contacts__item">
                                    <a class="feadback" href="#">Написать сообщение</a></li>
                            </ul>
                            </div>

.feadback {
    color: #0055aa;
    font-size: 1.4em;
    border-bottom: 1px dotted #0055aa;
    text-decoration: none;}
, you need to raise it higher to the baseline of the fontL21zgEwu6jYQ0A.jpg

Answer the question

In order to leave comments, you need to log in

3 answer(s)
Y
Yakov Vylegzhanin, 2016-04-12
@vylegzhanin

Use the property line-height.

A
A person from Kazakhstan, 2016-04-12
@LenovoId

570db59e32b64f6f88875a084be79b9c.PNGThe size is the height of the font??

G
Gleb Kemarsky, 2016-04-12
@glebkema

UPD 2: If you set the underline with a background image or a gradient, then you can control the shape, color and position of the underline. Examples - follow the links in the article " An alternative way to underline text " on Artyom Polikarpov's website.
UPD 1: Wrap the text inside the link in a span and lower it a bit.

.feadback span {
  position: relative;
  top: 2px;
}

<div class="contacts_feadback">
  <ul class="list header__feadback">
    <li class="contacts__item"><a class="feadback" href="#"><span>Заказать обратный звонок</span></a></li>
    <li class="contacts__item">
      <a class="feadback" href="#"><span>Написать сообщение</span></a></li>
  </ul>
</div>

https://jsfiddle.net/glebkema/vmrt8y2u/

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question