Skip to content

Use Places API (New) for address autocomplete (6.4) - #276

Draft
jill-fleet[bot] wants to merge 2 commits into
release/6.4.xfrom
fix/places-api-new-autocomplete-6.4
Draft

jill-fleet[bot] wants to merge 2 commits into
release/6.4.xfrom
fix/places-api-new-autocomplete-6.4

Conversation

@jill-fleet

@jill-fleet jill-fleet Bot commented Oct 20, 2026 •

Copy link
Copy Markdown

Type: fix

Same change as the 6.3 PR, for release/6.4.x (src/assets/js/common.js).

address_normalize: normalisation still applies to the field's formatted address; only the old per-component stripping of the mapped field values is not ported.
Test with a Maps key that has Places API (New) enabled. No PHP touched.

jill-fleet Bot added 2 commits October 20, 2026 04:39
Replace the legacy google.maps.places.Autocomplete widget with the Place / AutocompleteSuggestion API and a custom suggestion dropdown. Fills mapped fields and lat/lng from the selected place.
The result-type setting still offers the legacy values; sending them as
includedPrimaryTypes made the default value (address) an invalid request.
Map address to street_address, keep geocode and establishment, send a
(regions)/(cities) collection alone, drop unknown values and cap at five.
Also refresh the distance calculator and map elements after a pick, clear
the suggestion list below three characters, escape prediction text before
it becomes markup and keep request errors out of the visitor overlay.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants