Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,7 @@ <h1 class="nm-72 white">
<script defer src="/build/bundle.js"></script>

<!-- Google Places API -->
<script async type="text/javascript" src="https://maps.googleapis.com/maps/api/js?key=AIzaSyDtFCcssmw2kdWq90R_D6JDqPIqRFOYsE0&libraries=places"></script>
<script async type="text/javascript" src="https://maps.googleapis.com/maps/api/js?key=AIzaSyDtFCcssmw2kdWq90R_D6JDqPIqRFOYsE0&libraries=places&language=en"></script>

<!-- Pre-order app init -->
<script>
Expand Down
6 changes: 4 additions & 2 deletions src/location-input/googlePlace/googlePlaceLibraryLoader.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ function hasLoadedLibrary() {
*/
export function loadGooglePlacesLibrary(
apiKey: string,
callback: VoidFunction,
callback: VoidFunction
) {
if (hasLoadedLibrary()) {
callback();
Expand All @@ -47,7 +47,9 @@ export function loadGooglePlacesLibrary(
element.async = true;
element.defer = true;
element.onload = onLibraryLoaded;
element.src = `https://maps.googleapis.com/maps/api/js?key=${encodeURIComponent(apiKey)}&libraries=places`;
element.src = `https://maps.googleapis.com/maps/api/js?key=${encodeURIComponent(
apiKey
)}&libraries=places&language=en`;
element.type = "text/javascript";

document.head.appendChild(element);
Expand Down
10 changes: 5 additions & 5 deletions static/webflow/Home/before-body.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!-- CSS first -->
<link
rel="stylesheet"
href="https://cdn.jsdelivr.net/gh/BasePowerCompany/preorder-booking@1.0.31/public/preorder-app/bundle.css"
href="https://cdn.jsdelivr.net/gh/BasePowerCompany/preorder-booking@1.0.35/public/preorder-app/bundle.css"
/>

<!-- Functionality scripts -->
Expand All @@ -13,7 +13,7 @@
crossorigin
></script>
<script
src="https://cdn.jsdelivr.net/gh/BasePowerCompany/preorder-booking@1.0.31/public/preorder-app/embed.js"
src="https://cdn.jsdelivr.net/gh/BasePowerCompany/preorder-booking@1.0.35/public/preorder-app/embed.js"
crossorigin
></script>

Expand Down Expand Up @@ -76,7 +76,7 @@
var marketStatus = "unavailable";
try {
const response = await fetch(
"https://bpc-web-static-files.s3.us-east-2.amazonaws.com/deregulated-zips.csv",
"https://bpc-web-static-files.s3.us-east-2.amazonaws.com/deregulated-zips.csv"
);
const csvText = await response.text();
const lines = csvText.split("\n");
Expand Down Expand Up @@ -199,7 +199,7 @@
var marketStatus = "no";
try {
const response = await fetch(
"https://bpc-web-static-files.s3.us-east-2.amazonaws.com/deregulated-zips.csv",
"https://bpc-web-static-files.s3.us-east-2.amazonaws.com/deregulated-zips.csv"
);
const csvText = await response.text();
const lines = csvText.split("\n");
Expand Down Expand Up @@ -282,7 +282,7 @@

var autocomplete = new google.maps.places.Autocomplete(
input,
autocompleteOptions,
autocompleteOptions
);

autocomplete.setComponentRestrictions({ country: ["us"] });
Expand Down
Loading