Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to specify the callback function of the cancel button which displayed in the dialog of firebaseui web. #786

Closed
szk3600 opened this issue Nov 25, 2020 · 5 comments

Comments

@szk3600
Copy link

szk3600 commented Nov 25, 2020

I'd like to know how to specify the callback function of the cancel button which displayed in the dialog of firebaseui web.

Not mentioned in the documentation.

I use react-firebaseui/StyledFirebaseAuth.

Thank you in advance。

@samdogg7
Copy link

Bump

@bojeil-google
Copy link
Contributor

There is no cancel callback in FirebaseUI. We only provide a cancel button to take you to the previous rendered screen (no callback for that) but there is no cancel option for the entire UI. That would need to be built as part of your container. We provide functions on the AuthUI (reset and delete) to clear the UI which you can use.

If you need a mechanism to detect page changes, there is unofficial way to do so documented here

@hananbeer
Copy link

The cancel button doesn't close the UI for me. Is anything beyond ui.start('#element', config) needed to manage the UI?
I do get onAuthStateChange callbacks, it's just the UI remains.

Here are my imports:


	<!-- The core Firebase JS SDK is always required and must be listed first -->
	<script src="https://www.gstatic.com/firebasejs/8.2.4/firebase-app.js"></script>

	<!-- TODO: Add SDKs for Firebase products that you want to use
			https://firebase.google.com/docs/web/setup#available-libraries -->
	<script src="https://www.gstatic.com/firebasejs/8.2.4/firebase-auth.js"></script>

	<script src="https://www.gstatic.com/firebasejs/ui/4.6.1/firebase-ui-auth.js"></script>
	<link type="text/css" rel="stylesheet" href="https://www.gstatic.com/firebasejs/ui/4.6.1/firebase-ui-auth.css" />

Could it somehow be related to the following console warning I get?

AccountChooser.com will be operating in "universal opt-out" mode starting July 31st, 2020, it should no longer be used as a CredentialHelper.

@bojeil-google
Copy link
Contributor

Hey @hananbeer, this shouldn't be related to the AccountChooser.com warning you are seeing. It is not clear why you are having these issues. More information would be helpful to recreate this issue.

@hananbeer
Copy link

hananbeer commented Jan 26, 2021

@bojeil-google thank you. I opened a new issue #803 because this one was closed and it's a different issue anyhow. see in the comment the code to reproduce

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

No branches or pull requests

4 participants