fix(VField): correct outline label position for tile variant - #23069
Open
waterWang wants to merge 1 commit into
Open
fix(VField): correct outline label position for tile variant#23069waterWang wants to merge 1 commit into
waterWang wants to merge 1 commit into
Conversation
The [class^="rounded-"] CSS selector was also matching the rounded-0 class (applied by the tile prop), which caused the outline __start element to get a wider flex-basis intended for rounded corners. Added an explicit override for .rounded-0 to restore the correct -control-affixed-padding (12px) flex-basis, so the label aligns properly with the outline border on tiled fields. Closes vuetifyjs#22269
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
Fixes #22269
The
[class^="rounded-"]CSS selector was also matching therounded-0class (applied by thetileprop), which caused the outline__startelement to get a widerflex-basisintended for rounded corners.Root Cause
In
VField.sass, the outline__startelement has these rules:flex: 0 0 $field-control-affixed-padding(12px)flex-basis: calc(var(--v-input-control-height) / 2 + 2px)(≈30px)The override selector
[class^="rounded-"]matchesrounded-0(tile), causing the__startto be 30px wide when it should be 12px. This shifts the notch and label to the right.Fix
Added an explicit override for
.rounded-0to restore the correct$field-control-affixed-padding(12px)flex-basis, so the label properly aligns with the outline border on tiled fields.Reproduction
The first field (tiled) has the label slightly misaligned (too far right). After the fix, both fields have correctly aligned labels.