Skip to content

Commit c6b51e0

Browse files
Merge pull request #228 from brechtDR/feature/update-viewports-unit-article
Update viewports unit article
2 parents 22d8236 + 093233d commit c6b51e0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

data/blog/going-beyond-pixels-and-rems-in-css/relative-length-units-based-on-the-viewport.mdx

+2-2
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ If you read the previous article in this series, you might’ve remembered that
1515

1616
The `vw` unit stands for viewport width. But let’s start off with a catch right away. There are multiple things that we point at when talking about the viewport.
1717

18-
**The layout viewport** is the visible area of a web page influenced by the browser window or device screen size. It determines the space available for rendering HTML content. If you positioned a fixed box around the window, that’s the viewport we’re talking about.
18+
**The layout viewport** is the visible area of a web page influenced by the browser window on desktop or the device screen size (although, for devices it can depend on user zooming, keyboard opening, etc...). It determines the space available for rendering HTML content. If you positioned a fixed box around the window, that’s the viewport we’re talking about.
1919

2020
```html
2121
<div class="viewport"></div>
@@ -30,7 +30,7 @@ The `vw` unit stands for viewport width. But let’s start off with a catch righ
3030
}
3131
```
3232

33-
**The initial containing block** is a conceptual box serving as the root of the CSS box model. Its dimensions are tied to the layout viewport, with the top-left corner at (0,0). As the ICB is our root element, we can show it like this:
33+
**The initial containing block** is a rectangle in which the root (`<html>`) element lives. Its dimensions are tied to the layout viewport, with the top-left corner at (0,0). As the ICB is our root element, we can show it like this:
3434

3535
```css
3636
html {

0 commit comments

Comments
 (0)