From 67b98a6e047e9605325d081ae614064afb691af1 Mon Sep 17 00:00:00 2001 From: Rexios Date: Mon, 22 Jul 2024 10:34:02 -0400 Subject: [PATCH 1/5] Modernize the rest of the index.html files --- .../example/web/index.html | 23 +--------------- .../example/web/index.html | 23 +--------------- packages/flutter_image/example/web/index.html | 23 +--------------- .../google_identity_services_web/README.md | 12 ++++----- .../example/web/index-with-script-tag.html | 27 +++---------------- .../example/web/index.html | 20 +------------- .../example/web/index.html | 23 +--------------- .../google_sign_in/example/web/index.html | 11 +------- .../example/web/index.html | 15 +---------- .../example/web/index.html | 23 +--------------- 10 files changed, 17 insertions(+), 183 deletions(-) diff --git a/packages/extension_google_sign_in_as_googleapis_auth/example/web/index.html b/packages/extension_google_sign_in_as_googleapis_auth/example/web/index.html index 1d72ec5daa7..e178d6751c2 100644 --- a/packages/extension_google_sign_in_as_googleapis_auth/example/web/index.html +++ b/packages/extension_google_sign_in_as_googleapis_auth/example/web/index.html @@ -38,29 +38,8 @@ Google Sign In + googleapis - - - - - + diff --git a/packages/flutter_adaptive_scaffold/example/web/index.html b/packages/flutter_adaptive_scaffold/example/web/index.html index 9be0ff0a763..064d7a356f4 100644 --- a/packages/flutter_adaptive_scaffold/example/web/index.html +++ b/packages/flutter_adaptive_scaffold/example/web/index.html @@ -34,29 +34,8 @@ example - - - - - + diff --git a/packages/flutter_image/example/web/index.html b/packages/flutter_image/example/web/index.html index e080bd4889a..29f72bf6f77 100644 --- a/packages/flutter_image/example/web/index.html +++ b/packages/flutter_image/example/web/index.html @@ -35,29 +35,8 @@ example - - - - - + diff --git a/packages/google_identity_services_web/README.md b/packages/google_identity_services_web/README.md index 65214000a74..e5a24c27616 100644 --- a/packages/google_identity_services_web/README.md +++ b/packages/google_identity_services_web/README.md @@ -24,18 +24,16 @@ There are two ways to load the JS SDK in your app. The most performant way is to modify your `web/index.html` file to insert a script tag [as recommended](https://developers.google.com/identity/gsi/web/guides/client-library). -Place the `script` tag in the `` of your site, next to the script tag that -loads `flutter.js`, so the browser can downloaded both in parallel: +Place the `script` tag in the `` of your site, next to the script tag that +loads `flutter_bootstrap.js`, so the browser can downloaded both in parallel: ```html - - + - - - + + ``` #### With the `loadWebSdk` function (on-demand) diff --git a/packages/google_identity_services_web/example/web/index-with-script-tag.html b/packages/google_identity_services_web/example/web/index-with-script-tag.html index 07441f7a5d4..adcc29753f0 100644 --- a/packages/google_identity_services_web/example/web/index-with-script-tag.html +++ b/packages/google_identity_services_web/example/web/index-with-script-tag.html @@ -23,31 +23,12 @@ Authentication Example - - + + - - - - - - + + diff --git a/packages/google_identity_services_web/example/web/index.html b/packages/google_identity_services_web/example/web/index.html index 5727323c8db..4c6fa80e71b 100644 --- a/packages/google_identity_services_web/example/web/index.html +++ b/packages/google_identity_services_web/example/web/index.html @@ -22,30 +22,12 @@ Authentication Example - - - - + diff --git a/packages/google_maps_flutter/google_maps_flutter/example/web/index.html b/packages/google_maps_flutter/google_maps_flutter/example/web/index.html index 58522ba720c..26de2ffd7cb 100644 --- a/packages/google_maps_flutter/google_maps_flutter/example/web/index.html +++ b/packages/google_maps_flutter/google_maps_flutter/example/web/index.html @@ -38,29 +38,8 @@ - - - - - + diff --git a/packages/google_sign_in/google_sign_in/example/web/index.html b/packages/google_sign_in/google_sign_in/example/web/index.html index eff8f4effad..d68026f3d90 100644 --- a/packages/google_sign_in/google_sign_in/example/web/index.html +++ b/packages/google_sign_in/google_sign_in/example/web/index.html @@ -7,17 +7,8 @@ Google Sign-in Example - - + diff --git a/packages/pointer_interceptor/pointer_interceptor_web/example/web/index.html b/packages/pointer_interceptor/pointer_interceptor_web/example/web/index.html index 2720a1eaad8..064d7a356f4 100644 --- a/packages/pointer_interceptor/pointer_interceptor_web/example/web/index.html +++ b/packages/pointer_interceptor/pointer_interceptor_web/example/web/index.html @@ -34,21 +34,8 @@ example - - - - + diff --git a/packages/two_dimensional_scrollables/example/web/index.html b/packages/two_dimensional_scrollables/example/web/index.html index 3574a82d337..3ce79d627fe 100644 --- a/packages/two_dimensional_scrollables/example/web/index.html +++ b/packages/two_dimensional_scrollables/example/web/index.html @@ -34,29 +34,8 @@ example - - - - - + From 9e2931bca91e208860461f480a3e438892efabe5 Mon Sep 17 00:00:00 2001 From: Rexios Date: Mon, 22 Jul 2024 10:39:00 -0400 Subject: [PATCH 2/5] Remove superfluous end tag --- packages/camera/camera/example/web/index.html | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/camera/camera/example/web/index.html b/packages/camera/camera/example/web/index.html index 015dee5950a..91502587eda 100644 --- a/packages/camera/camera/example/web/index.html +++ b/packages/camera/camera/example/web/index.html @@ -23,7 +23,6 @@ - From 708079e6eebf77e105cd0345d7e9b538c56e4087 Mon Sep 17 00:00:00 2001 From: Rexios Date: Mon, 22 Jul 2024 10:55:20 -0400 Subject: [PATCH 3/5] Update version and changelog for `google_identity_services_web` --- packages/google_identity_services_web/CHANGELOG.md | 4 ++++ packages/google_identity_services_web/pubspec.yaml | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/google_identity_services_web/CHANGELOG.md b/packages/google_identity_services_web/CHANGELOG.md index d7ed98a3c8c..2846643a299 100644 --- a/packages/google_identity_services_web/CHANGELOG.md +++ b/packages/google_identity_services_web/CHANGELOG.md @@ -1,3 +1,7 @@ +## 0.3.1+2 + +* Updates `README.md` to reflect modern `index.html` script tag placement. + ## 0.3.1+1 * Uses `TrustedTypes` from `web: ^0.5.1`. diff --git a/packages/google_identity_services_web/pubspec.yaml b/packages/google_identity_services_web/pubspec.yaml index 0c61580d79e..e93ea319ca1 100644 --- a/packages/google_identity_services_web/pubspec.yaml +++ b/packages/google_identity_services_web/pubspec.yaml @@ -2,7 +2,7 @@ name: google_identity_services_web description: A Dart JS-interop layer for Google Identity Services. Google's new sign-in SDK for Web that supports multiple types of credentials. repository: https://github.com/flutter/packages/tree/main/packages/google_identity_services_web issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+google_identiy_services_web%22 -version: 0.3.1+1 +version: 0.3.1+2 environment: sdk: ^3.3.0 From d39be795f94934ec29b0b1b2dbbb5f2530cf9b05 Mon Sep 17 00:00:00 2001 From: Rexios Date: Mon, 22 Jul 2024 11:06:55 -0400 Subject: [PATCH 4/5] Fix docgen --- .../example/web/index-with-script-tag.html | 2 -- 1 file changed, 2 deletions(-) diff --git a/packages/google_identity_services_web/example/web/index-with-script-tag.html b/packages/google_identity_services_web/example/web/index-with-script-tag.html index adcc29753f0..8269db4cd3c 100644 --- a/packages/google_identity_services_web/example/web/index-with-script-tag.html +++ b/packages/google_identity_services_web/example/web/index-with-script-tag.html @@ -3,9 +3,7 @@ Use of this source code is governed by a BSD-style license that can be found in the LICENSE file. --> - - From 0e854cf04c7c6207dce874aa994587d598b4f45f Mon Sep 17 00:00:00 2001 From: Rexios Date: Mon, 22 Jul 2024 14:50:31 -0400 Subject: [PATCH 5/5] Update README again to put the script in head --- packages/google_identity_services_web/README.md | 9 ++++----- .../example/web/index-with-script-tag.html | 9 ++++++--- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/packages/google_identity_services_web/README.md b/packages/google_identity_services_web/README.md index e5a24c27616..733644af5ba 100644 --- a/packages/google_identity_services_web/README.md +++ b/packages/google_identity_services_web/README.md @@ -24,16 +24,15 @@ There are two ways to load the JS SDK in your app. The most performant way is to modify your `web/index.html` file to insert a script tag [as recommended](https://developers.google.com/identity/gsi/web/guides/client-library). -Place the `script` tag in the `` of your site, next to the script tag that -loads `flutter_bootstrap.js`, so the browser can downloaded both in parallel: +Place the `script` tag in the `` of your site: ```html - + + - - + ``` #### With the `loadWebSdk` function (on-demand) diff --git a/packages/google_identity_services_web/example/web/index-with-script-tag.html b/packages/google_identity_services_web/example/web/index-with-script-tag.html index 8269db4cd3c..bae6382acfa 100644 --- a/packages/google_identity_services_web/example/web/index-with-script-tag.html +++ b/packages/google_identity_services_web/example/web/index-with-script-tag.html @@ -3,7 +3,9 @@ Use of this source code is governed by a BSD-style license that can be found in the LICENSE file. --> + + @@ -21,12 +23,13 @@ Authentication Example - + - + + + -