]> git.ipfire.org Git - thirdparty/bootstrap.git/commit
Replace Popper.js with CSS Anchor Positioning API feature/popover-api-anchor-positioning 41923/head
authorMark Otto <markdotto@gmail.com>
Thu, 11 Dec 2025 17:47:57 +0000 (09:47 -0800)
committerMark Otto <markdotto@gmail.com>
Thu, 11 Dec 2025 17:47:57 +0000 (09:47 -0800)
commitb2fd7011c3d98f1b327a2a39f244a5028a63479b
tree037624715710ddbd3d4f150ed8a5474dcb4525c8
parent39edb8da1c19526acb777eadf3dfb40b7d4d8ed0
Replace Popper.js with CSS Anchor Positioning API

BREAKING CHANGE: Popper.js is no longer a dependency. Dropdowns, tooltips,
and popovers now use native CSS Anchor Positioning with a polyfill fallback.

JavaScript:
- Add positioning.js utility with responsive placement support
- Rewrite dropdown.js to use anchor positioning and popover attribute
- Rewrite tooltip.js to use anchor positioning
- Update popover.js with data-api click handler
- Remove Popper.js imports and configuration options
- Add responsive placement syntax (e.g., "bottom md:top lg:right-start")

SCSS:
- Add _anchor-positioning.scss with base styles for positioned elements
- Update dropdown, tooltip, and popover styles for anchor positioning
- Add b-dropdown custom element support

Package:
- Replace @popperjs/core with @oddbird/css-anchor-positioning (optional polyfill)

Docs:
- Update dropdowns, tooltips, and popovers documentation
20 files changed:
js/index.esm.js
js/index.umd.js
js/src/dropdown.js
js/src/popover.js
js/src/tooltip.js
js/src/util/positioning.js [new file with mode: 0644]
js/tests/unit/dropdown.spec.js
js/tests/unit/tooltip.spec.js
js/tests/visual/responsive-placement.html [new file with mode: 0644]
package-lock.json
package.json
scss/_anchor-positioning.scss [new file with mode: 0644]
scss/_dropdown.scss
scss/_popover.scss
scss/_tooltip.scss
scss/bootstrap.scss
site/src/content/callouts/warning-data-bs-title-vs-title.md
site/src/content/docs/components/dropdowns.mdx
site/src/content/docs/components/popovers.mdx
site/src/content/docs/components/tooltips.mdx