0

all my margins and padding are 0. In the global.css file I only have this small piece of code:

html, body {
    width: 100%;
    height: 100%;
}

body {
    padding: 0;
    margin: 0;
}

body size

Here you can see the highlighted part of <body>. Note the fact that the body pixel size is 1261 x 876.

html size

In the 2nd picture you can see that the <html> part also has the same pixel size of 1261 x 876, but is highlighting the entire screen, without the white bar on top.

EDIT: I have checked the child elements inside the <body> for overflow. They had some overflow padding.

Temani Afif
  • 245,468
  • 26
  • 309
  • 415
Beantly
  • 36
  • 7
  • Check inside the body for an element with a margin that's overflowing its parent. See this question: [CSS margin pushing the body element](https://stackoverflow.com/questions/7742720/css-margin-pushing-the-body-element) – DBS Aug 31 '22 at 10:42
  • What type of element is the 125? – Corrl Aug 31 '22 at 11:04
  • 1
    resetcss is a good practice for these cases. https://meyerweb.com/eric/tools/css/reset/ – Helio Aug 31 '22 at 11:07
  • @Corrl The 125 is a simple

    .

    – Beantly Aug 31 '22 at 11:13

1 Answers1

0

To sum up, resetcss lead me to the answer. The answer was a child overflowing the parent element.

Beantly
  • 36
  • 7