-
Notifications
You must be signed in to change notification settings - Fork 23k
fix(docs): Improve fit-content and other sizing keyword pages #40202
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
Conversation
Preview URLs (7 pages)Flaws (5)Note! 2 documents with no flaws that don't need to be listed. 🎉 URL:
URL:
URL:
URL:
URL:
External URLs (1)URL:
(comment last updated: 2025-08-26 14:33:58) |
|
This pull request has merge conflicts that must be resolved before it can be merged. |
|
This pull request has merge conflicts that must be resolved before it can be merged. |
| - Related glossary terms: | ||
| - {{glossary("Extrinsic size")}} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| - Related glossary terms: | |
| - {{glossary("Extrinsic size")}} | |
| - {{glossary("Extrinsic size")}} |
we're in glossary, so don't need to include the introductory text in this section
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I only see #34451. Was there a discussion anywhere? For other sections, I could concede to prefacing multiple terms with "Glossary terms:". However, I would have voiced opposition to this choice for this section in this format due to redundancy. We're in the "glossary", glossaries define "terms"., and the See also section should only contain "related" content, including related terms..
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, I see what you're saying, especially about the word "related", which could seem redundant. But also, to me "Related glossary terms:" has a different ring to it than just "Glossary terms:".
The intent to add the label in the first place was to distinguish glossary term links from other links in "See also", such as those for properties and module pages.
|
Hi @estelle, when you have some time, could you review this PR? Thank you! |
estelle
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
still working on it, but committing what i have
| - Related glossary terms: | ||
| - {{glossary("Extrinsic size")}} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I only see #34451. Was there a discussion anywhere? For other sections, I could concede to prefacing multiple terms with "Glossary terms:". However, I would have voiced opposition to this choice for this section in this format due to redundancy. We're in the "glossary", glossaries define "terms"., and the See also section should only contain "related" content, including related terms..
|
|
||
| > [!NOTE] | ||
| > The CSS Sizing specification also defines the {{cssxref("fit-content_function", "fit-content()")}} function. This page details the keyword. | ||
| > In addition to the `fit-content` keyword, the CSS Box Sizing specification also defines the {{cssxref("fit-content_function", "fit-content()")}} function, which takes a length or percentage as an argument and behaves slightly differently. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| > In addition to the `fit-content` keyword, the CSS Box Sizing specification also defines the {{cssxref("fit-content_function", "fit-content()")}} function, which takes a length or percentage as an argument and behaves slightly differently. | |
| > In addition to the `fit-content` keyword, the [CSS box sizing](/en-US/docs/Web/CSS/CSS_box_sizing) module also defines the {{cssxref("fit-content_function", "fit-content()")}} function, which takes a {{cssxref("length")}} or {{cssxref("percentage')}} as an argument and behaves slightly differently. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do they serve the same purpose?
estelle
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I dont think i understand this feature well enough to review this PR
|
|
||
| > [!NOTE] | ||
| > The CSS Sizing specification also defines the {{cssxref("fit-content_function", "fit-content()")}} function. This page details the keyword. | ||
| > In addition to the `fit-content` keyword, the CSS Box Sizing specification also defines the {{cssxref("fit-content_function", "fit-content()")}} function, which takes a length or percentage as an argument and behaves slightly differently. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do they serve the same purpose?
6ccb4a3 to
493c142
Compare
estelle
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
three more suggestions
Co-authored-by: Estelle Weyl <[email protected]>
estelle
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! 🎉
|
Thanks for the review, Estelle! |
Description
A user on Discord reported that the description for
fit-contentwas misleading and unclear.I also found that the reference to
fit-content(stretch)is outdated and should be removed.From CSS Box Sizing Level 3 spec:
> Note: This section previously defined stretch and fit-content as keywords representing the stretch-fit size and fit-content size, respectively. These keywords have been deferred to Level 4 (along with an additional contain keyword that behaves similarly to stretch but preserves the preferred aspect ratio, if any) to better work out the implications in situations with indefinite available space.
Updates in this PR
fit-content.fit-content(stretch). Updated the note.max-contentandmin-content.Motivation
To ensure content is accurate, up-to-date, and easier to understand