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 form label in next major #6718

Merged
merged 1 commit into from
Dec 31, 2020
Merged

Conversation

VincentLanglet
Copy link
Member

Pedantic.

Currently, with

->add('foo.barBaz`)

and the label underscore strategy.

The show label is show.label_foo_bar_baz.
The form label is form.label_foo__bar_baz.

The issue is that for the form, . are forbidden and replaced by __.
But we should use the given name for the label, instead of the new sanitized one.

This will add consistency in next major. I don't fix it in 3.x to avoid people to rewrite every label.

@VincentLanglet VincentLanglet requested a review from a team December 20, 2020 14:44
@VincentLanglet VincentLanglet added this to the 4.0 milestone Dec 23, 2020
@VincentLanglet VincentLanglet requested a review from a team December 24, 2020 00:06
@OskarStark OskarStark merged commit 3a68fcc into sonata-project:3.x Dec 31, 2020
@VincentLanglet VincentLanglet deleted the formLabel branch December 31, 2020 17:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants