firebase / FirebaseUI-Flutter

Apache License 2.0
107 stars 99 forks source link

🐛 Google Icon doesn't show up on profile screen #358

Closed pgrm closed 5 months ago

pgrm commented 5 months ago

Is there an existing issue for this?

What plugin is this bug for?

Firebase UI Auth

What platform(s) does this bug affect?

Web

List of dependencies used.

flutter pub deps -s list
Dart SDK 3.4.1
Flutter SDK 3.22.1
dinnersolved 1.0.0+1

dependencies:
- cloud_firestore 5.0.0 [cloud_firestore_platform_interface cloud_firestore_web collection firebase_core firebase_core_platform_interface flutter meta]
- cupertino_icons 1.0.8
- firebase_auth 5.0.0 [firebase_auth_platform_interface firebase_auth_web firebase_core firebase_core_platform_interface flutter meta]
- firebase_core 3.0.0 [firebase_core_platform_interface firebase_core_web flutter meta]
- firebase_ui_auth 1.14.0 [email_validator firebase_auth firebase_core firebase_dynamic_links firebase_ui_localizations firebase_ui_oauth firebase_ui_shared flutter flutter_localizations meta]
- firebase_ui_localizations 1.11.0 [flutter flutter_localizations path]
- firebase_ui_oauth_google 1.3.2 [firebase_auth firebase_ui_oauth flutter google_sign_in]
- flutter 0.0.0 [characters collection material_color_utilities meta vector_math sky_engine]
- flutter_localizations 0.0.0 [flutter intl characters clock collection material_color_utilities meta path vector_math]
- go_router 14.1.4 [collection flutter flutter_web_plugins logging meta]
- intl 0.19.0 [clock meta path]

dev dependencies:
- flutter_lints 4.0.0 [lints]
- flutter_test 0.0.0 [flutter test_api matcher path fake_async clock stack_trace vector_math leak_tracker_flutter_testing async boolean_selector characters collection leak_tracker leak_tracker_testing material_color_utilities meta source_span stream_channel string_scanner term_glyph vm_service]

dependency overrides:
- firebase_auth 5.0.0 [firebase_auth_platform_interface firebase_auth_web firebase_core firebase_core_platform_interface flutter meta]
- firebase_core 3.0.0 [firebase_core_platform_interface firebase_core_web flutter meta]

transitive dependencies:
- _flutterfire_internals 1.3.36 [collection firebase_core firebase_core_platform_interface flutter meta]
- args 2.5.0
- async 2.11.0 [collection meta]
- boolean_selector 2.1.1 [source_span string_scanner]
- characters 1.3.0
- clock 1.1.1
- cloud_firestore_platform_interface 6.2.6 [_flutterfire_internals collection firebase_core flutter meta plugin_platform_interface]
- cloud_firestore_web 4.0.0 [_flutterfire_internals cloud_firestore_platform_interface collection firebase_core firebase_core_web flutter flutter_web_plugins]
- collection 1.18.0
- crypto 3.0.3 [typed_data]
- desktop_webview_auth 0.0.15 [crypto flutter http flutter_web_plugins plugin_platform_interface]
- email_validator 2.1.17
- fake_async 1.3.1 [clock collection]
- firebase_auth_platform_interface 7.3.1 [_flutterfire_internals collection firebase_core flutter meta plugin_platform_interface]
- firebase_auth_web 5.12.1 [firebase_auth_platform_interface firebase_core firebase_core_web flutter flutter_web_plugins http_parser meta web]
- firebase_core_platform_interface 5.0.0 [collection flutter flutter_test meta plugin_platform_interface]
- firebase_core_web 2.17.1 [firebase_core_platform_interface flutter flutter_web_plugins meta web]
- firebase_dynamic_links 5.5.7 [firebase_core firebase_core_platform_interface firebase_dynamic_links_platform_interface flutter meta plugin_platform_interface]
- firebase_dynamic_links_platform_interface 0.2.6+36 [_flutterfire_internals firebase_core flutter meta plugin_platform_interface]
- firebase_ui_oauth 1.5.2 [desktop_webview_auth firebase_auth firebase_ui_auth firebase_ui_shared flutter_svg flutter]
- firebase_ui_shared 1.4.1 [flutter]
- flutter_svg 2.0.10+1 [flutter http vector_graphics vector_graphics_codec vector_graphics_compiler]
- flutter_web_plugins 0.0.0 [flutter characters collection material_color_utilities meta vector_math]
- google_identity_services_web 0.3.1+1 [meta web]
- google_sign_in 6.2.1 [flutter google_sign_in_android google_sign_in_ios google_sign_in_platform_interface google_sign_in_web]
- google_sign_in_android 6.1.23 [flutter google_sign_in_platform_interface]
- google_sign_in_ios 5.7.6 [flutter google_sign_in_platform_interface]
- google_sign_in_platform_interface 2.4.5 [flutter plugin_platform_interface]
- google_sign_in_web 0.12.4 [flutter flutter_web_plugins google_identity_services_web google_sign_in_platform_interface http web]
- http 1.2.1 [async http_parser meta web]
- http_parser 4.0.2 [collection source_span string_scanner typed_data]
- leak_tracker 10.0.4 [clock collection meta path vm_service]
- leak_tracker_flutter_testing 3.0.3 [flutter leak_tracker leak_tracker_testing matcher meta]
- leak_tracker_testing 3.0.1 [leak_tracker matcher meta]
- lints 4.0.0
- logging 1.2.0
- matcher 0.12.16+1 [async meta stack_trace term_glyph test_api]
- material_color_utilities 0.8.0 [collection]
- meta 1.12.0
- path 1.9.0
- path_parsing 1.0.1 [vector_math meta]
- petitparser 6.0.2 [meta]
- plugin_platform_interface 2.1.8 [meta]
- sky_engine 0.0.99
- source_span 1.10.0 [collection path term_glyph]
- stack_trace 1.11.1 [path]
- stream_channel 2.1.2 [async]
- string_scanner 1.2.0 [source_span]
- term_glyph 1.2.1
- test_api 0.7.0 [async boolean_selector collection meta source_span stack_trace stream_channel string_scanner term_glyph]
- typed_data 1.3.2 [collection]
- vector_graphics 1.1.11+1 [flutter http vector_graphics_codec]
- vector_graphics_codec 1.1.11+1
- vector_graphics_compiler 1.1.11+1 [args meta path_parsing xml vector_graphics_codec path]
- vector_math 2.1.4
- vm_service 14.2.1
- web 0.5.1
- xml 6.5.0 [collection meta petitparser]

Steps to reproduce

I tried to follow the example in https://pub.dev/packages/firebase_ui_auth/example this is my ProfileScreen route:

    GoRoute(
        path: '/profile',
        redirect: _defaultRedirect,
        builder: (context, _) => ProfileScreen(
              actions: [
                SignedOutAction((context) {
                  context.go('/');
                })
              ],
              showDeleteConfirmationDialog: true,
              showUnlinkConfirmationDialog: true,
            ))

I configured the providers in the main function:

  FirebaseUIAuth.configureProviders(
      [EmailAuthProvider(), GoogleProvider(clientId: GOOGLE_CLIENT_ID)]);

I also tried to provide the font information:

flutter:
  # The following line ensures that the Material Icons font is
  # included with your application, so that you can use the icons in
  # the material Icons class.
  uses-material-design: true

  # To add assets to your application, add an assets section, like this:
  assets:
    - images/
  #   - images/a_dot_ham.jpeg

  fonts:
    - family: SocialIcons
      fonts:
        - asset: packages/firebase_ui_auth/fonts/SocialIcons.ttf

Expected Behavior

To see something resembling a Google logo in the "Sign-in methods" section

Actual Behavior

image

Additional Information

This is my first flutter app, so most likely I have a mistake somewhere. I am not sure if I missed something in the documentation, or it's not documented because it's "obvious" (for everyone familiar with flutter).

I found https://github.com/firebase/FirebaseUI-Flutter/issues/228 which pointed to including fonts in pubspec.yaml, which I did, but the issue seems to persist.

pgrm commented 5 months ago

never mind, now it started working - no idea which cache or similar had to be cleared, since I tried it even on 2 different machines, with the aforementioned results.