Skip to content

fix(input, select, textarea): prevent floating label from overflowing while it floats - #31567

Merged
brandyscarney merged 2 commits into
mainfrom
FW-7683
Oct 15, 2026
Merged

brandyscarney merged 2 commits into
mainfrom
FW-7683

Conversation

@brandyscarney

@brandyscarney brandyscarney commented Oct 13, 2026 •

Copy link
Copy Markdown
Member

Issue number: internal


What is the current behavior?

An input, select, or textarea with an extremely long overflowing label with label-placement="floating" overflows its container when going from a resting to a floating state:

floating-before.mov

What is the new behavior?

floating-after.mov
  • The label's max-width now transitions along with its transform, so the label reveals more of its text gradually as it scales down instead of showing its full floating width while still at its resting size.
  • With fill="outline", the label stays positioned relative to the control in both its resting and floating states, so its max-width always resolves against the same width and can animate without jumping.
  • The start container controller now also measures the end container and is renamed to createStartEndContainerController. The combined start and end width is written to --internal-start-end-container-width, which the outline floating label uses to size itself to the full width of the notch.
  • Adds $form-control-label-transition-easing so the label's color, transform, and max-width transitions share one easing.
  • Adds an e2e test per component that steps through the label's transitions and checks that the label never extends past the field.

Does this introduce a breaking change?

  • Yes
  • No

Other information

Previews:

@vercel

vercel Bot commented Oct 13, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
ionic-framework Ready Ready Preview Oct 13, 2026 6:14pm UTC

Request Review

@brandyscarney brandyscarney Oct 13, 2026 •

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was renamed from start-container-controller since it now deals with the end container as well.

Here is the actual diff: https://www.diffchecker.com/dVpN68IJ/

@brandyscarney
brandyscarney marked this pull request as ready for review October 13, 2026 18:34
@brandyscarney
brandyscarney requested a review from a team as a code owner October 13, 2026 18:34
@brandyscarney
brandyscarney requested a review from ShaneK October 13, 2026 18:34

@thetaPC thetaPC left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@brandyscarney
brandyscarney added this pull request to the merge queue Oct 15, 2026
Merged via the queue into main with commit ecd6f5a Oct 15, 2026
57 checks passed
@brandyscarney
brandyscarney deleted the FW-7683 branch October 15, 2026 14:29

This branch was successfully deployed

1 active deployment
Preview — f7c06a37 Deployed Oct 13, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

package: core @ionic/core package

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants