K
K
kimqar_ver2020-05-09 11:19:05
css
kimqar_ver, 2020-05-09 11:19:05

Is it possible to globally increase the font on the entire page by +2px?

The site has a version for the visually impaired, there is a button - "increase by 2". There are many different font sizes on the site, is it possible to somehow set the condition for all of them to be "initial font size + 2px"?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexander Marchuk, 2020-05-09
@kimqar_ver

$('*').each(function(){
  $(this).css('font-size', parseInt($(this).css('font-size')) + 2);
})

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question