我有一個功能正常的Chrome擴展程序,並且正在嘗試添加Firebase身份驗證(Google & Facebook)。在Chrome擴展程序中使用Firebase進行身份驗證導致空白彈出
如果我運行從整個瀏覽器窗口彈出,我得到谷歌和Facebook的彈出窗口完全按照你的期望。
當我點擊打開彈出式窗口,然後選擇谷歌或Facebook登錄,我得到一個關於:空白的彈出窗口(有時其打開,有時它閃爍和消失)。
的奇怪的事情: 如果我通過點擊擴展圖標打開彈出,然後右鍵單擊揭露開發工具,保持控制檯打開後彈出,然後點擊谷歌或Facebook,在彈出的打開爲你所期望的,我都可以登錄。下面
清單......我試圖以匹配火力地堡的具體例子(https://github.com/firebase/quickstart-js/tree/master/auth/chromextension)。
任何想法或指示排除故障?
{
"manifest_version": 2,
"name": "Annotate PRO for Chrome",
"short_name": "Annotate PRO",
"description": "Right-click access to a pre-written library of comments. Write it once, to perfection, and reuse forever!",
"version": "3.1.1.0",
"permissions": [
"identity",
"identity.email",
"clipboardWrite",
"clipboardRead",
"activeTab",
"tabs",
"contextMenus",
"storage",
"webNavigation"
],
"content_security_policy": "script-src 'self' https://ssl.google-analytics.com; object-src 'self'",
"externally_connectable": {
"matches": ["http://*.11trees.com/*"]},
"commands": {
"_execute_browser_action": {
"suggested_key": {
"windows": "Alt+A",
"mac": "Alt+A",
"chromeos": "Alt+A",
"linux": "Alt+A"
}
}
},
"key": "XXXX",
"oauth2": {
"client_id": "XXXX",
"scopes": [
/*"https://www.googleapis.com/auth/chromewebstore.readonly",*/
"https://www.googleapis.com/auth/userinfo.email",
"https://www.googleapis.com/auth/userinfo.profile"
]
},
"background": {
"scripts": ["/dscripts/jquery-3.1.1.min.js","/scripts/background.js"]},
"content_security_policy": "script-src 'self' https://ssl.google-analytics.com https://apis.google.com/ https://www.gstatic.com/ https://*.firebaseio.com https://www.googleapis.com; object-src 'self'",
"content_scripts": [
{
"all_frames" : true,
"matches": ["http://*/*","https://*/*"],
"js": ["/scripts/content.js"]
}
],
"web_accessible_resources": ["/scripts/insertcomment.js"],
"icons": {
"16": "Annotate16.png",
"48": "Annotate48.png",
"128": "Annotate128.png"
},
"browser_action": {
"default_icon": {
"19": "Annotate128.png",
"38": "Annotate128.png"
},
"default_title": "Annotate PRO for Google Chrome",
"default_popup": "aHome.html"
}
}