From 72618efdf813f38cfa203b84b5199ac1adf8f733 Mon Sep 17 00:00:00 2001 From: William French Date: Tue, 5 May 2026 12:39:35 -0700 Subject: [PATCH 1/3] feat: Refactors the 3d-accessibility-features sample to latest standards. --- samples/3d-accessibility-features/index.html | 16 ++++++++++------ samples/3d-accessibility-features/index.ts | 20 ++++++++------------ 2 files changed, 18 insertions(+), 18 deletions(-) diff --git a/samples/3d-accessibility-features/index.html b/samples/3d-accessibility-features/index.html index ad6682157..caedfb000 100644 --- a/samples/3d-accessibility-features/index.html +++ b/samples/3d-accessibility-features/index.html @@ -11,14 +11,18 @@ - - -
- + ({key: "AIzaSyA6myHzS10YXdcazAFalmXvDkrYCp5cLc8", v: "weekly" }); + + + diff --git a/samples/3d-accessibility-features/index.ts b/samples/3d-accessibility-features/index.ts index 457b84c44..a284743fb 100644 --- a/samples/3d-accessibility-features/index.ts +++ b/samples/3d-accessibility-features/index.ts @@ -6,18 +6,14 @@ // [START maps_3d_accessibility_features] async function initMap() { + // Import the needed libraries. const { Map3DElement, Marker3DInteractiveElement, PopoverElement } = await google.maps.importLibrary('maps3d'); - const { PinElement } = await google.maps.importLibrary('marker'); + const { PinElement } = (await google.maps.importLibrary( + 'marker' + )); - const map = new Map3DElement({ - center: { lat: 34.8405, lng: -111.7909, altitude: 1322.7 }, - range: 13279.5, - tilt: 67.44, - heading: 0.01, - mode: 'SATELLITE', - gestureHandling: 'COOPERATIVE', - }); + const map3DElement = document.querySelector('gmp-map-3d')!; // Set LatLng and title text for the markers. The first marker (Boynton Pass) // receives the initial focus when tab is pressed. Use arrow keys to move @@ -71,11 +67,11 @@ async function initMap() { interactiveMarker.append(pin); - map.append(interactiveMarker); - map.append(popover); + map3DElement.append(interactiveMarker); + map3DElement.append(popover); }); - document.body.append(map); + document.body.append(map3DElement); } initMap(); From 02cc280ef31ecf7ec4860c7678e15d8998edafa3 Mon Sep 17 00:00:00 2001 From: William French Date: Tue, 5 May 2026 12:50:49 -0700 Subject: [PATCH 2/3] Apply prettier formatting --- samples/3d-accessibility-features/index.ts | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/samples/3d-accessibility-features/index.ts b/samples/3d-accessibility-features/index.ts index a284743fb..faebbb405 100644 --- a/samples/3d-accessibility-features/index.ts +++ b/samples/3d-accessibility-features/index.ts @@ -6,12 +6,10 @@ // [START maps_3d_accessibility_features] async function initMap() { - // Import the needed libraries. + // Import the needed libraries. const { Map3DElement, Marker3DInteractiveElement, PopoverElement } = await google.maps.importLibrary('maps3d'); - const { PinElement } = (await google.maps.importLibrary( - 'marker' - )); + const { PinElement } = await google.maps.importLibrary('marker'); const map3DElement = document.querySelector('gmp-map-3d')!; From 28ee5c189e1013e14cb961b6eaa434cc7046b89f Mon Sep 17 00:00:00 2001 From: William French Date: Tue, 5 May 2026 13:03:50 -0700 Subject: [PATCH 3/3] Remove version parameter from Google Maps API script It defaults to weekly. --- samples/3d-accessibility-features/index.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/samples/3d-accessibility-features/index.html b/samples/3d-accessibility-features/index.html index caedfb000..85774752e 100644 --- a/samples/3d-accessibility-features/index.html +++ b/samples/3d-accessibility-features/index.html @@ -13,7 +13,7 @@ + ({key: "AIzaSyA6myHzS10YXdcazAFalmXvDkrYCp5cLc8"});