docs: fix wording and responsive utility examples#42458
Open
coliff wants to merge 1 commit into
Open
Conversation
Copy edits across several docs pages: clarify .btn usage and theme classes (button.mdx); correct repeated/awkward 'drawer' phrasing and update responsive breakpoint syntax to the colon form (drawer.mdx); remove duplicated 'drawer' wording and clean navbar responsive copy (navbar.mdx); update Sass guidance from @import to @use/@forward terminology (customize/optimize.mdx); clarify 'modal' → 'modal dialog' and update form validation guidance to use data-bs-validate and :user-invalid (getting-started/approach.mdx); and revise display utility docs to show the new .{breakpoint}:d-{value} syntax with example adjustments (utilities/display.mdx).
There was a problem hiding this comment.
Pull request overview
Note
Copilot was unable to run its full agentic suite in this review.
Updates documentation to reflect newer class naming conventions and implementation details (responsive utility prefixes, drawer terminology, Sass module usage, and validation behavior).
Changes:
- Update responsive class syntax examples to
.{breakpoint}:*across utilities and components - Fix wording/typos and standardize “drawer” terminology throughout component docs
- Refresh customization guidance to reference Sass modules (
@use/@forward) and update validation approach description
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| site/src/content/docs/utilities/display.mdx | Updates responsive display utility syntax and examples |
| site/src/content/docs/getting-started/approach.mdx | Revises overlay wording and updates form validation guidance |
| site/src/content/docs/customize/optimize.mdx | Updates Sass optimization section to reference module system terminology |
| site/src/content/docs/components/navbar.mdx | Removes duplicated “drawer” wording and updates headings/text |
| site/src/content/docs/components/drawer.mdx | Standardizes drawer wording and updates responsive class examples |
| site/src/content/docs/components/button.mdx | Fixes unclear/duplicated phrasing in .btn description |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| ## Responsive behaviors | ||
|
|
||
| Navbars can use `.navbar-toggler`, and `.lg:navbar-expand{-sm|-md|-lg|-xl|-2xl}` classes to determine when their content appears in an drawer drawer or inline. In combination with other utilities, you can easily choose when to show or hide particular elements. | ||
| Navbars can use `.navbar-toggler`, and `.lg:navbar-expand{-sm|-md|-lg|-xl|-2xl}` classes to determine when their content appears in a drawer or inline. In combination with other utilities, you can easily choose when to show or hide particular elements. |
| Whenever possible, we prefer HTML and CSS over JavaScript—they’re more accessible to people of all experience levels and faster in the browser. That’s why our first-class JavaScript API is `data` attributes—it lets you write more HTML instead of JavaScript. Read more in [our JavaScript overview]([[docsref:/getting-started/javascript#data-attributes]]). | ||
|
|
||
| Our styles build on fundamental browser behaviors. For example, while you can put `.btn` on nearly any element, we prefer `<button>`s and `<a>`s for their semantic value. Similarly, we use native `:valid`/`:invalid` pseudo-elements for form validation rather than custom plugins. | ||
| Our styles build on fundamental browser behaviors. For example, while you can put `.btn` on nearly any element, we prefer `<button>`s and `<a>`s for their semantic value. For form validation, we scope styles behind `data-bs-validate` and use the `:user-invalid` pseudo-class so feedback appears only after user interaction—not on initial page load. |
| ## Lean Sass setup | ||
|
|
||
| When using Sass in your asset pipeline, make sure you optimize Bootstrap by only `@import`ing the components you need. Your largest optimizations will likely come from the `Layout & Components` section of our `bootstrap.scss`. | ||
| When using Sass in your asset pipeline, make sure you optimize Bootstrap by only `@use`ing the partials you need. Your largest optimizations will likely come from the `Layout & Components` section of our `bootstrap.scss`. |
| To hide elements simply use the `.d-none` class or one of the `.{sm,md,lg,xl,2xl}:d-none` classes for any responsive screen variation. | ||
|
|
||
| To show an element only on a given interval of screen sizes you can combine one `.d-*-none` class with a `.d-*-*` class, for example `.d-none .md:d-block .xl:d-none` will hide the element for all screen sizes except on medium and large devices. | ||
| To show an element only on a given interval of screen sizes you can combine one `.{breakpoint}:d-none` class with a `.{breakpoint}:d-block` class, for example `.d-none .md:d-block .xl:d-none` will hide the element for all screen sizes except on medium and large devices. |
Contributor
Author
|
linting fails due to Prettier formatting on: |
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Description
Copy edits across several docs pages:
Motivation & Context
Fixing docs is fun
Type of changes
Checklist
npm run lint)Live previews