Questions tagged [css-rem]

8 questions
2
votes
0 answers

Can I set new root size on some element , not ? (REM)

My problem is : Im using a CSS framework who using rem as unit. And some website/template set their font-size like html {font-size:62.5%}, So 1rem is 10px not 16px then all texts/elements who using that framework are small. Im trying to dont…
l2aelba
  • 21,591
  • 22
  • 102
  • 138
1
vote
0 answers

Issue with font-size 62.5%

I have a very strange issue. Sometimes my / page displays the website normal, but sometimes zoomed. And the "funny" thing is, that only the startpage is affected. Above you can see the "funny" one, and below it when the page loads normal: So…
Sylnois
  • 1,589
  • 6
  • 23
  • 47
0
votes
1 answer

I accidently added rem unit to line-height value, It overlaps the margin why?

While aligning the text using css, I accidently added rem unit to line-height (I think it shouldn't be added as of my knowledge)of the H3 element and this what happened. margin of the above P element comes in contact with h3 element below. [also…
0
votes
1 answer

Change root font-size for ShadowRoot tree

I am trying to build a chrome extension which injects an HTML popup on the host page via content script. I am adding this popup using shadowRoot to avoid collisions with the main page. Also, I am using bootstrap on the popup for styling. One issue…
0
votes
2 answers

Reasons to use rem unit for mobile?

I know that it is better to use rem (or em) unit instead of px, in order to keep text style scale when changing the browser's font size option. So I only use relative unit in my projects instead of px. But on mobile my thought is that it's not…
Yann Simon
  • 81
  • 1
  • 8
0
votes
1 answer

responsive fonts, margins, paddings

I have this basic css style. What am i trying to do is to make the text responsive(fonts), i know i have to use ems / rems to do that ( i choose rems with a fallback to px not sure if it's right but you can see in the code how i did, the px i'm not…
Bogdan
  • 693
  • 7
  • 26
0
votes
5 answers

css: margin property uses both px and rem

Consider the following css class definition, taken from the worpdress twenty-twelve theme: .entry-header { margin-bottom: 24px; margin-bottom: 1.714285714rem; } Why is the margin-bottom defined twice, once with px and once with rem units?…
Adam Matan
  • 128,757
  • 147
  • 397
  • 562
-1
votes
1 answer

why % in css is extrinsic size while other relative units are fixed sized accrording to this talk

In this talk auto value in CSS is explained in various contexts.Speaker said % is extrinsic unit which make sense because size is dependent on parent. but she also put em, vw, vh, rem and other relative unit's in fixed bucket. size calculation of vh…
user2022
  • 13
  • 6