When screen decreases in size background move's oddly

Hey there, So I had help creating this calculator to be a bit more responsive but I ran into an issue so when I decrease the size of the space around the calculator the background coloring moves with it how can I fix this?
No description
19 Replies
b1mind
b1mind9mo ago
hard to say without a codepen/demo of it. If I had to guess .. vw xD
RMON
RMON9mo ago
sorry lol! I think It may be a width issue 🤦
b1mind
b1mind9mo ago
Let content determine width
RMON
RMON9mo ago
I just caught onto it after messing around in Inspect Element I'll still send a CodePen
b1mind
b1mind9mo ago
maybe use a min/max but don't use vw units to do it.
b1mind
b1mind9mo ago
Yea just remove the width from .calculator and remove overflow hidden from body
RMON
RMON9mo ago
Alright let me give it a try! Oh perfect! I have one more question if you don't mind
RMON
RMON9mo ago
In the smallest width using inspect element the calculator looks like this (Got some button tweakin to do) What would you recommend I do to make the calulator somewhat smaller so it looks more appealing?
No description
RMON
RMON9mo ago
Ok so removing the width actually messed up the entire thing It became incredibily gigantic
b1mind
b1mind9mo ago
You can put some margin around it? then give it a max-width: maybe? I wouldn't use % but rem or px
RMON
RMON9mo ago
em?
b1mind
b1mind9mo ago
🤷‍♂️ you gotta make that choice
RMON
RMON9mo ago
sigh - the choice is confusing I wont even lie I still don't fully understand how to use em/rem
b1mind
b1mind9mo ago
I mean if you are using rem for fonts and user changes font you will want it to fit.
RMON
RMON9mo ago
I've watched kevins videos regarding it but its confusing
MarkBoots
MarkBoots9mo ago
I see you used my suggestion from this post. https://discord.com/channels/436251713830125568/1206832624778092614 Thanks for NOT responding to it, you're welcome!
clevermissfox
clevermissfox9mo ago
Use clamp on fintsuze and padding or width on vuttons in ems
RMON
RMON9mo ago
Im so sorry lmao
Want results from more Discord servers?
Add your server