CSS Gap between Container Border & Child Element

https://jsfiddle.net/3r5yw2st/1/ how do I get rid of that gap between the border and child I've already removed the padding what could cause this
Edit fiddle - JSFiddle - Code Playground
Test your JavaScript, CSS, HTML or CoffeeScript online with JSFiddle code editor.
23 Replies
b1mind
b1mind•3y ago
Looks like it has to do with how the viewport units are being rendered, use pixels, rem, or % I would recommend not using viewport units like this, they are not some dynamic unit to use all over.
b1mind
b1mind•3y ago
Schroedinger
SchroedingerOP•3y ago
could you send me your version of the jsfiddle?
Schroedinger
SchroedingerOP•3y ago
Schroedinger
SchroedingerOP•3y ago
the gap is still there for me I believe it has something to do with chrome browser versions I'm using brave
b1mind
b1mind•3y ago
I'm using Edge and don't see it are you zoomed?
Schroedinger
SchroedingerOP•3y ago
No but it disappears when I zoom out
b1mind
b1mind•3y ago
I did have the gap with yours not mine though, also what I said still stand no matter. Don't use vmin like that specially for border 😄
Schroedinger
SchroedingerOP•3y ago
hm okay I'll try but is there any other way I could solve this?
b1mind
b1mind•3y ago
If you are at any zoom level it can render different than it should just happens
Schroedinger
SchroedingerOP•3y ago
ah okay thanks anyway
b1mind
b1mind•3y ago
FF shows my fiddle working fine too
Schroedinger
SchroedingerOP•3y ago
yeah it might just be chrome then
b1mind
b1mind•3y ago
could also be you are making body flex...
Schroedinger
SchroedingerOP•3y ago
doesn't seem to change anything
b1mind
b1mind•3y ago
could just be brave I just tested chrome too
Schroedinger
SchroedingerOP•3y ago
I removed it
b1mind
b1mind•3y ago
Edge is chrome
Schroedinger
SchroedingerOP•3y ago
ah really
b1mind
b1mind•3y ago
Yea I don't have brave to check but xD if all the rest don't do it then yea.. idk 😄 Also yea removing the flex on body fixes it too
b1mind
b1mind•3y ago
b1mind
b1mind•3y ago
This kinda stuff has to do with both how the units work and the child behavior.
Want results from more Discord servers?
Add your server