* Revert `border-color` change
* Add new border-color-translucent for when we want optional alpha-transparency in our border-color
Apply to drodpowns, modals, offcanvas, popovers, and toasts
* bundlewatch
* Document incompatibilities between Bootstrap JS and React/.etc
Closes#35665.
* Remove link to reactstrap
* Update javascript.md
Co-authored-by: Mark Otto <otto@github.com>
* Fix not used option (`ride`) (according to docs), continuing of #35753a247fe9
* separate concept of `programmatical cycle` vs `maybe cycle after click` functionality
Support parsing JSON from each component's main element using the `data-bs-config` attribute.
The `bs-config` attribute will be reserved and omitted during `getDataAttributes` parsing.
With this commit, every component, will create its config object, using:
* defaults
* data-bs-config
* the rest of data attributes
* configuration object given during instance initialization
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
Co-authored-by: Mark Otto <markd.otto@gmail.com>
Co-authored-by: Mark Otto <markdotto@gmail.com>
* Fix some more borders and margins
* Flex utilities docs: remove .bd-highlight class from snippets
* Explicit close target
* Reorder to keep base class up top
* Fix custom position example
* Tooltips: add code snippet, use scss-docs ref for custom tooltip
* Tweak text for pagination examples
* Modals: move custom styles to utilities
* Grid docs: Combine selectors and share coloring
* Refactor tons of little things
* Do some CSS and Migration guide cleanup
- More code snippet tweaks
- Fix some homepage hero bugs
- Do a cleanup on Migration guide content to highlight more changes and fix some issues from merge conflicts
* Add responsive offcanvas classes
- Updates navbar-expand classes to de-dupe some styles—these shouldn't interfere now.
- Adds some JS to the offcanvas component to help with responsiveness
Co-Authored-By: GeoSot <geo.sotis@gmail.com>
* Redesign homepage, docs, and examples
Homepage:
- New Bootstrap purple navbar
- Redesigned masthead
- Rewrote and redesigned homepage content
- Replace Copy text with icons like Bootstrap Icons site across all ClipboardJS instances
- Fixed padding issues in site footer
- Match homepage button styles to examples page, use gap instead of tons of responsive margin utils
Docs:
- New navbar, no more subnav. Migrated search and version picker into the main navbar and refreshed the design of it all, including the responsive toggles.
- New sidebar navigation is always expanded, and now features Bootstrap Icons alongside section headings
- Sidebar navigation autoscrolls to active link for better usability
- Subnav and navbar padding issues ironed out
- Enhanced the version picker in anticipation of v5.2: we can now link right to the same page in the previous version.
- Redesign callouts to add more color to our pages
- Collapse table of contents on mobile
- Cleanup and redesign button styles with CSS variables
- Update design for subnav version dropdown
- Update highlight and example to be full-width until md
- Improve the Added In badges
- Turn the ToC into a well on mobile
- Redesign code snippets to better house two action buttons
Examples:
- Redesign Examples page layout
- Add new example for responsive offcanvases in navbars
* Convert offcanvas to CSS vars
* Feat: add resize handler to Offcanvas.js.
If we could use as default the `.offcanvas` class without modifiers, we then, could add a simplified selector
The selector itself, ignores the .offcanvas class as it doesn't have any responsive behavior
The `aria-modal` addon is to protect us, selection backdrop elements
* Separate examples code, Add some selectors, fix stackblitz btn
Co-authored-by: GeoSot <geo.sotis@gmail.com>
* Revamp scrollspy to use IntersectionObserver
* Add smooth scroll support
* Update scrollspy.js/md
* move functionality to method
* Update scrollspy.js
* Add SmoothScroll to docs example
* Refactor Using `Maps` and smaller methods
* Update scrollspy.md/js
* Update scrollspy.spec.js
* Support backwards compatibility
* minor optimizations
* Merge activation functionality
* Update scrollspy.md
* Update scrollspy.js
* Rewording some of the documentation changes
* Update scrollspy.js
* Update scrollspy.md
* tweaking calculation functionality & drop text that suggests, to deactivate target when wrapper is not visible
* tweak calculation
* Fix lint
* Support scrollspy in body & tests
* change doc example to a more valid solution
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
Co-authored-by: Patrick H. Lauke <redux@splintered.co.uk>
Following the Parcel v1 installation guide seems to install the latest version of Parcel (v2), which makes several instructions in this guide throw errors. Therefore, I have updated the guide to work with version 2 of Parcel.
Change Details:
1) Update the URL to point to the latest doc pages.
2) Use the `type="module"` HTML attribute to reference a module [migration](https://parceljs.org/getting-started/migration/#code-changes)
3) The `--out-dir <dir>` CLI parameter has been changed to `--dist-dir <dir>` [CLI](https://parceljs.org/features/cli/#parameters)
4) For a reason I'm unsure of, `--experimental-scope-hoisting` throws the following error: `error: unknown option '--experimental-scope-hoisting'`, so I removed it to get the build to work.
* Remove not needed css form tooltip & popover as it is made by popper
Remove tooltip margin variable, as popper needs margin to be zero
* Remove popover left/top initializers as they are handled by popper
* nullify `margin` variable and add deprecation message
* Document change in migration guide
* Update _variables.scss
Co-authored-by: Mark Otto <markdotto@gmail.com>
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
* Pass docs js through Babel
* Use ES6 in docs js
* Only run babel on src files
* Allow babel in Hugo
* Update scripts.html
* Inherit from the root .eslintrc.json
* Use `Array.from`
* Drop Babel from docs
* Prefer template
* replace IIFE with arrow functions
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
Co-authored-by: GeoSot <geo.sotis@gmail.com>
* Tab: Revamp tab.js & add support Aria features
* Tab: Add tab support, just to keep backwards compatibility. Better to remove it on v6
* Revert "Tab: Add tab support, just to keep backwards compatibility. Better to remove it on v6"
* Support arrow down/up functionality
* add prevent default to avoid scrolling the page during up/down keys handling
* remove panel tabindex handling
* Expand documentation text for JS plugin
* Rearrange new docs to specifically call out a11y
* properly place section
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
Co-authored-by: Patrick H. Lauke <redux@splintered.co.uk>
Co-authored-by: Mark Otto <markdotto@gmail.com>
* Convert accordion to CSS vars
* Update accordion.md
* Convert navs to CSS variables
* Split up CSS vars
* bundlewatch
* fix vars
* Convert cards to CSS vars
* Convert modals to CSS variables
* Bundlewatch
Co-authored-by: Geremia Taglialatela <tagliala.dev@gmail.com>
* Add additional root variables, rename $variable-prefix to $prefix
- Adds new root CSS variables for border-radius, border-width, border-color, and border-style
- Adds new root CSS variables for heading-color, link-colors, code color, and highlight color
- Replaces most instances of Sass variables (for border-radius, border-color, border-style, and border-width) for CSS variables inside _variables.scss
- Updates $mark-padding to be an even pixel number
- Renames $variable-prefix to $prefix throughout
* Bundlewatch
- Updates the utilities mixin to check for specific CSS variable names via `css-variable`
- Bonus fix: we now prevent local variables for `0` value utilities (e.g., `.border-top-0` no longer sets `--bs-border-opacity: 1`
- Adds new `.border-opacity-*` classes
- Adds new root variables: `--bs-border-color`, `--bs-border-style`, `--bs-border-width`
- Documents the new variable changes
Use the new .table-group-divider to create your own dividers as desired. Would love to find a better way to handle border-color for this, but for now, this is at least opt-in.
I've applied it by default in another way for our docs tables to help differentiate our content vs our components.
Fixes#35342
Some Linux distributions (like Debian) have fontconfig aliases for Arial
that picks specific fonts. But such generic aliases might be less
desirable than the known-good Linux specific fonts.
This fixes a problem on my setup where Liberation Sans is aliased as
Arial, even when Noto Sans is available. Liberation Sans doesn't support
a weight of 500, so we end up rendering headers at the normal weight of
400, which makes them stand out less. Reordering the Arial fallback
makes us instead pick Noto Sans over Lieration Sans, which does support
a weight of 500, and makes headers stand out again.
While we're at it, fixup the reboot documentation to match, and change
the comment about Helvetica Neue; that's not a "Basic web-fallback" font,
it's the UI font on older iOS and macOS versions.
* Add z-index for .toast-container
- Adds positioning and z-index to toast container so that it has a system-declared layer in relation to other components.
- Updates docs to use the class better
Fixes $34028
* Remove unnecessary z-index from docs examples
* Drop .opacity-50 and .opacity-75 redefinition in examples
* Drop unused .card-img-right from blog example CSS files
* Use line-height utilities when possible
* Use rounded-* utilities in examples
* Replace .nav-underline by .nav-scroller and use it in examples.html default
* Use .mb-1 for .blog-post-title
* Remove unused CSS rule and use .fw-* utilities for carousels examples
* Use utilities for cheatsheet examples
* Extract some CSS to utilities for .nav-masthead .nav-link in cover example
* Dashboard group of minor modifications
* Dropdowns example: refactoring
* Dropdowns example refactoring: fix linting by removing selector by id
* Features example refactoring
* Headers example refactoring
* List groups example refactoring
* Sidebars example refactoring
* Sign-in example refactoring
* Starter template refactoring
* Fix RTL examples
Co-authored-by: Mark Otto <markd.otto@gmail.com>
* fix(reboot): revert hr styles to v4 implementation
* docs(cheatsheet): add a hr example
* fix(reboot): currentColor is the initial border-color value
* Document hr element in Reboot docs
* Update migration guide
* Update scss/_variables.scss
Co-authored-by: Mark Otto <markd.otto@gmail.com>
* Support floating labels on `.form-control-plaintext`
* Update floating-labels.md
* Apply suggestions from code review
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
Co-authored-by: Mark Otto <otto@github.com>
> You can disable every form element within a form with the `disabled` attribute on the `<form>`.
I really want to be mistaken, because this would be a very useful feature! But I don't believe it's true. I can't find anything about this on MDN Web Docs, and adding the `disabled` attribute to a `<form>` does nothing on any browser in my testing.
The `disabled` attribute on a `<fieldset>` does disable all descendant form controls – perhaps that's where the mixup has come from.
* Docs: group together examples reusable CSS in a stylesheet
* Use pointer-events utility in sidebars example
* Remove @import and move the content into _default/examples.html. Handle 2 sorts of dividers
* Remove footers.css extra css declaration
* Fix modals example
* Review: remove .b-example-hr
Co-authored-by: Gaël Poupard <ffoodd@users.noreply.github.com>
While it is understood that this is just an example, the visible text (label) of "Works with selects" and the `aria-label="Floating label select example"` created a [WCAG 2.5.3 Label in name](https://www.w3.org/WAI/WCAG21/quickref/#label-in-name) failure.
As the `aria-label` isn't necessary here since this `select` is already provided an accessible name by its `label` element, removing the unnecessary `aria-label` seems the best course of action as:
* removing it solves the WCAG issue
* it removes the potential implication to developers that they'd even _need_ an `aria-label` here, let alone indirectly suggesting that it's ok for the visible text and accessible name to be out of alignment
* Separate container classes from enable-grid-classes optoin
* Document the new option
* Mention in migration guide
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
* docs: Add role="switch" to switches
* Tweak/expand explanation about assistive technologies
Co-authored-by: Patrick H. Lauke <redux@splintered.co.uk>
* Disabled link cleanup
per https://www.w3.org/TR/html-aria/#docconformance
> It is NOT RECOMMENDED to use `aria-disabled="true"` on an `a` element with an `href` attribute.
>
>NOTE
>If a link needs to be "disabled", remove the `href` attribute.
This PR removes the unnecessary `href="#"`, `tabindex="-1"`, and `aria-disabled="true"` from disabled links in both docs pages and examples. `aria-disabled="true"` *is* kept for disabled link-based buttons (that have `role="button"`) as there it's appropriate to use (you *want* to convey to assistive technologies that this thing you're claiming is a button is also disabled at the moment)
Further, the PR extends the "Link functionality caveat" to show the "proper" way (removing `href` and adding `.disabled` class only) to disable a link, but then explains what to do if that's not possible (and then keeps an example with all the traditional `href="#" tabindex="-1" aria-disabled="true"`, but explains clearly that it's not ideal). Same sort of explanation is also added to the pointer event utilities page
* Turn big note into actual normal doc text
Co-authored-by: Mark Otto <markd.otto@gmail.com>
Co-authored-by: Mark Otto <markd.otto@gmail.com>
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
- Adds grayscale colors
- Adds root and body variables
Note that some Sass variables default to `null`, so as we generate and use the CSS variable, we'll be potentially adding some lines of code.
- Adds new functions to generate additional Sass maps
- Adds new root variables for rgb() versions of our theme colors, plus a few extras
- Adds ability to change the alpha transparency of text color and background color utilities with new utilities, inline styles, or local CSS var
- Updates documentation for color and background-color utilities pages
- Deprecates .text-black-50 and .text-white-50 since those (and additional transparency levels) can be generated on the fly
Change approach slightly to prevent cascade
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
Co-authored-by: Jaume Sala <jaumesala@gmail.com>
Co-authored-by: Mark Otto <markdotto@gmail.com>
Co-authored-by: Patrick H. Lauke <redux@splintered.co.uk>
- Moves the make-cssgrid() mixin to the grid mixins stylesheet
- Updates the g-start-* classes to start at 1 instead of 0 as 0 is an invalid value (fixes#34399)
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
Now includes mentino of the two utilities stylesheets, plus how and why to include the API stylesheet last
Fixes#34397
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
* change data-dismiss, so can be outside modal, using a bs-target
* Update site/content/docs/5.0/components/modal.md
Co-authored-by: Gaël Poupard <ffoodd@users.noreply.github.com>
* Add maps for all colors, document how to extend color utilities
* Updates to make this more functional for v5
- Moves color maps into _variables.scss for now (felt weird to split them out when the variables are there)
- Adds a new function, map-merge-multiple(), and updates docs that reference combo-map
- Updates code snippet and docs guidance about how to extend the color utils to handle this
* Update site/content/docs/5.0/customize/color.md
Co-authored-by: Gaël Poupard <ffoodd@users.noreply.github.com>
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
Alert.js: Refactor code to match the other components
* Use this._element
* Remove handleDismiss method and keep its functionality on event
* Change JqueryInterface to be more generic
* Correct docs to be aligned with code, and add undocumented functionality
* Update alerts.md
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
* Add responsive utility classes for opacity
- fix for #33483
* remove responsive opacity utils as it has impact on bootstrap.css bundle size
* Update opacity.md
* Update site/content/docs/5.0/utilities/opacity.md
Co-authored-by: Mark Otto <otto@github.com>
* Update site/content/docs/5.0/utilities/opacity.md
Co-authored-by: Mark Otto <otto@github.com>
Co-authored-by: Harish <halodoc@ip-192-168-1-101.ap-southeast-1.compute.internal>
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
Co-authored-by: Mark Otto <otto@github.com>
Co-authored-by: Mark Otto <markd.otto@gmail.com>
Co-authored-by: alpadev <2838324+alpadev@users.noreply.github.com>
* Update dropdowns.md to reflect correct version
* Clarify content, drop the reference to versions
* Update dropdowns.md
Co-authored-by: Mark Otto <otto@github.com>
* Update documentation for badges
* Removes useless changes, as well as fixes an example
* Fixes some text with a badge example
Co-authored-by: Mark Otto <markd.otto@gmail.com>
* placeholder changes to input value
* Fix content and add value to readOnly input
* add value in readonly input
* Update site/content/docs/5.0/forms/form-control.md
Co-authored-by: Rajesh Kumar <https://github.com/rajesh2kumar96>
Co-authored-by: Patrick H. Lauke <redux@splintered.co.uk>
Co-authored-by: Mark Otto <otto@github.com>
* docs(cards): img in horizontal card
Closes#34145
Simply adds `img-fluid` and `rounded-start` classes to horizontal card example to ensure copy-pasting from the docs matches the expectation.
* Update site/content/docs/5.0/components/card.md
Co-authored-by: Mark Otto <markd.otto@gmail.com>
* Fix unnecessary classes
* Removed unnecessary div
Co-authored-by: Mark Otto <otto@github.com>
* Updated centered hero primary button classes
Co-authored-by: Mark Otto <otto@github.com>
- De-duplicates bulk of the content for a migration from v4 to v5
- Adds clear breaking labels where appropriate
- Leaves room for more guidance around doing the actual migration
* Neutralise more words from placeholder text
Follow-up to https://github.com/twbs/bootstrap/pull/33726
* Match fullscreen modal to other sizes
* Ditch the lyrics outright
* Rewrite and tweak the blog example some
* update cheatsheet
* text utils copy too
* Fix the tbody validation error
* fix typo
Co-authored-by: Mark Otto <markd.otto@gmail.com>
Co-authored-by: Mark Otto <markdotto@gmail.com>
Co-authored-by: alpadev <2838324+alpadev@users.noreply.github.com>
Co-authored-by: alpadev <alpa.muc@gmail.com>
* Tweak toast docs
- a few rewordings/tweaks
- add info about toasts with focusable/actionable controls (shouldn't autohide them)
* Update site/content/docs/5.0/components/toasts.md
Co-authored-by: Mark Otto <markd.otto@gmail.com>
* Update site/content/docs/5.0/components/toasts.md
Co-authored-by: Mark Otto <markd.otto@gmail.com>
Co-authored-by: Mark Otto <markd.otto@gmail.com>