Skip to content
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

Fix floating labels rendering on Firefox #41347

Merged
merged 1 commit into from
Apr 4, 2025

Conversation

julien-deramond
Copy link
Member

@julien-deramond julien-deramond commented Apr 4, 2025

Fixes #41342

This PR addresses the floating label rendering issue in Firefox, based on the discussion and analysis at #41342 (comment).

We considered three possible solutions:

  1. Pin autoprefixer to the previous release. However, it's unclear how the issue will be handled upstream.
  2. Add not kaios <= 2.5 to our .browserlistrc which appears to resolve the problem in Firefox. This is the solution implemented in this PR. Note: if autoprefixer provides an upstream fix, we’ll likely need to revisit and remove this workaround.
  3. Identify a more robust fix by adjusting our floating label implementation or refining our use of pseudo-elements.

We chose the second option as a temporary, pragmatic fix, for a quick v5.3.5. A more permanent solution may involve revisiting our use of pseudo-elements once we better understand the root cause or once an upstream fix is released.

Live preview available at https://deploy-preview-41347--twbs-bootstrap.netlify.app/docs/5.3/forms/floating-labels/

Rendering:

  • ✅ Firefox 137.0 - macOS 15.3.2
  • ✅ Chrome 134.0.6998.166 (Official Build) (arm64) - macOS 15.3.2
  • ✅ Safari 18.3.1 (20620.2.4.11.6) - macOS 15.3.2
  • ✅ Edge 134.0.3124.95 (Official build) (arm64) - macOS 15.3.2
  • ✅ Firefox 117.0 - Ubuntu 22.04

@julien-deramond julien-deramond marked this pull request as ready for review April 4, 2025 15:50
@mdo mdo merged commit b1e16bd into main Apr 4, 2025
14 checks passed
@mdo mdo deleted the main-jd-fix-floating-label-on-firefox branch April 4, 2025 17:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
No open projects
Status: Done
Development

Successfully merging this pull request may close these issues.

Floating labels always in floated state in 5.3.4
2 participants