Open hamza1216 opened 1 year ago
Maybe it might be related with this issue. https://stackoverflow.com/questions/12314729/close-windows-that-were-not-opened-by-script-using-javascript
instagram is working, but not sure why it's not working for twitter on firefox.
Facebook and google login is working on all browsers closing the window when login successfully, but the twitter model is no closing on Firefox browser. same issues as above, anyone having any solution for it?
This is still an issue; I have recreated it. Could it have something to do with the onLogin callback at line 131 of LoginSocialTwitter?
const onLogin = useCallback(async () => {
onLoginStart && onLoginStart();
window.addEventListener('storage', onChangeLocalStorage, false);
const oauthUrl = `${TWITTER_URL}/i/oauth2/authorize?response_type=code&client_id=${client_id}&redirect_uri=${redirect_uri}&scope=${scope}&state=${state+'_twitter'}&code_challenge=challenge&code_challenge_method=plain`;
const width = 450;
const height = 730;
const left = window.screen.width / 2 - width / 2;
const top = window.screen.height / 2 - height / 2;
window.open(
oauthUrl,
'twitter',
'menubar=no,location=no,resizable=no,scrollbars=no,status=no, width=' +
width +
', height=' +
height +
', top=' +
top +
', left=' +
left,
);
}, [
scope,
state,
client_id,
onLoginStart,
redirect_uri,
onChangeLocalStorage,
]);
Still got error, anyone please help!
The Twitter window is not closing, also the onResolve function is not being called, how do we receive data from Twitter. I'm using Microsoft Edge browser. @cuongdevjs please help.
The Twitter window is not closing, also the onResolve function is not being called, how do we receive data from Twitter. I'm using Microsoft Edge browser. @cuongdevjs please help.
I am also facing the same issue
Describe the bug Twitter login modal is not closing on firefox. To Reproduce Steps to reproduce the behavior:
Expected behavior The login modal should be closed. It's working on chrome, but not on firefox.
Screenshots
Desktop (please complete the following information):