Files
replypier/frontend/public/meta-oauth-callback.html
WangShen007 0cc6299d1c feat(widget): Widget 配置、loader 与右下角悬浮入口
生成可嵌入站点的 loader 与悬浮按钮,支持展开收起和移动端;附独立宿主测试页。
2026-09-25 20:50:00 +08:00

30 lines
928 B
HTML

<!doctype html>
<!--
OAuth redirect target for Facebook Login for Business (Messenger/Instagram).
Meta redirects the login popup here with ?code&state; this relays them to the
opener and closes. It's a static file (not the SPA) so the popup stays light,
and it must be registered as a Valid OAuth Redirect URI on the Meta app.
-->
<html>
<head><meta charset="utf-8" /><title>Connecting…</title></head>
<body>
Connecting…
<script>
(function () {
var params = new URLSearchParams(window.location.search)
var message = {
source: 'meta-oauth',
code: params.get('code'),
state: params.get('state'),
error: params.get('error_description') || params.get('error'),
}
if (window.opener) {
window.opener.postMessage(message, window.location.origin)
}
window.close()
})()
</script>
</body>
</html>