feat: implement country and state selection enhancements#2538
Merged
Conversation
Maciej D (mdanilowicz)
requested review from
Björn Meyer (BrocksiNet),
Maciek Kucmus (mkucmus) and
Patryk Tomczyk (patzick)
and removed request for
Maciek Kucmus (mkucmus)
July 4, 2026 16:07
Patryk Tomczyk (patzick)
left a comment
Contributor
There was a problem hiding this comment.
let's just use readCountryGet instead of post endpoint for it
Contributor
Author
There is a function with both endpoints https://github.com/shopware/frontends/pull/2538/changes#diff-ba1eab2c1da44e2c9950440ab7f84f59de5385448f23e48b8727c2b404080b12R129 |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Patryk Tomczyk (patzick)
requested changes
Jul 9, 2026
Patryk Tomczyk (patzick)
left a comment
Contributor
There was a problem hiding this comment.
I have one question and one thing to improve
Patryk Tomczyk (patzick)
approved these changes
Jul 15, 2026
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.
This pull request introduces a new, smart country picker component with flag icons, search, and keyboard navigation, and integrates it into registration, address, and checkout forms. It also improves form validation by requiring the state field only for countries that have states. The most important changes are grouped below:
New Smart Country Picker Component
FormCountrySearchSelect, a searchable and paginated country picker with flag icons, keyboard navigation, and single-country mode.CountrySearchSelect/Flag.vuefor country flags andCountrySearchSelect/Option.vuefor selectable country options. [1] [2]Form Integration and Validation Updates
FormCountrySearchSelectcomponent, including emitting country state changes. [1] [2] [3] [4]registrationFormRulesandaddressFormRules) so the state field is only required if the selected country has states, using a newcountryHasStatesref. (F82377b5L31R31, templates/vue-starter-template/app/utils/validation/rules/registrationFormRules.tsL51-R51)i18n and User Feedback Improvements
Component and API Refactoring
CountryStateInput.vueto use the new country picker and emit state changes, removing dependency on the oldgetCountriesOptionsandgetStatesForCountryhelpers. [1] [2]Type and Prop Updates
These changes modernize the country selection experience, improve accessibility and validation, and lay groundwork for further enhancements.