-
Notifications
You must be signed in to change notification settings - Fork 22.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Document new svh/svw, lvh/lvw, dvh/dvw etc. viewport-percentage relative length units #16679
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Preview URLsFlawsNone! 🎉 External URLsURL:
(this comment was updated 2022-05-26 20:34:10.491909) |
Rumyra
requested changes
May 26, 2022
Looks great @dipikabh - some really good improvements 👍 |
7 tasks
dipikabh
changed the title
Document for new svh/svw, lvh/lvw, dvh/dvw etc. viewport-percentage relative length units
Document new svh/svw, lvh/lvw, dvh/dvw etc. viewport-percentage relative length units
May 27, 2022
Rumyra
approved these changes
May 27, 2022
bsmth
added
fx release archive
A closed issue relating to firefox release notes for developers.
and removed
Firefox 101
labels
Dec 20, 2022
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Content:CSS
Cascading Style Sheets docs
fx release archive
A closed issue relating to firefox release notes for developers.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
s
), large (l
), and dynamic (d
).As a result, the existing viewport-percentage length units (
vw
,vh
,vmin
,vmax
) can have more variants.Each can be of the type s, l, d resulting in:
svw
,lvw
,dvw
,svh
,lvh
,dvh
,svmin
,lvmin
,dvmin
,svmax
,lvmax
,dvmax
vw
,vh
,vmin
,vmax
were already documented on this page (these are now considered the browser defaults).This PR adds a section to explain small (s), large (l), and dynamic (d) viewport sizes and also adds info about the new variants in the respective
vw
,vh
,vmin
,vmax
sections.Minor edits have been made to the rest of the page to improve clarity and some more info from the spec has been added like specified and computed lengths
The existing page had heading levels going up to
<h5>
in theSyntax
section. This has been fixed to avoid going below the heading level<h3>
.Current structure:
## Syntax
### Units
#### Relative length units
##### Font-relative lengths
##### Viewport-percentage lengths
#### Absolute length units
New structure in this PR:
## Syntax
The length units can be relative or absolute.
The relative length units listed here are based on font and viewport.
### Relative length units based on font
### Relative length units based on viewport
### Absolute length units
Motivation
https://drafts.csswg.org/css-values/#viewport-relative-lengths
Supporting details
https://bugzilla.mozilla.org/show_bug.cgi?id=1610815
Related issues
Doc issue tracking this work: #15465
Metadata