Login/signup modal renders behind the app in expanded mode (showLoginPrompt looks like a no-op)

未关闭
#304 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
4/5
预计耗时
3-5 天
新手友好度
55/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
活跃
技术栈
typescript

调研方向

Start with the expanded-mode flow in @devvit/web/client, especially requestExpandedMode, exitExpandedMode, and showLoginPrompt; use the linked minimal repro to compare the prompt before and after exiting expanded mode. Trace how the host displays its auth modal and how the expanded web view is layered. Done when both the app's login prompt and Reddit's Join button show the modal above the expanded app.

由索引模型根据 Issue 内容生成。

描述

Summary

For a logged-out viewer on desktop web, Reddit's login/signup modal is rendered behind the app while the web view is in expanded mode, so showLoginPrompt() looks like a no-op.

Environment

  • Devvit packages / CLI: 0.15.4 (@devvit/web, @devvit/start, devvit)
  • Desktop web browser (reproduced in Chrome on reddit.com)
  • Viewer is logged out

Steps to reproduce

Minimal repro app: https://github.com/yusakman/devvit-expanded-login-prompt

  1. Install/playtest the repro app on a test subreddit and open its post while logged out.
  2. Tap Play — the app opens in expanded mode (requestExpandedMode(event, 'game')).
  3. Tap the button that calls showLoginPrompt() from @devvit/web/client.

Expected

Reddit's Sign Up / Log In modal appears on top of the app.

Actual

The modal is drawn in the host page behind the full-screen expanded web view, so it is not visible. It looks like the button did nothing.

Additional observations:

  • Leaving expanded mode first (exitExpandedMode(event)) and then calling showLoginPrompt() makes the modal visible — that is the workaround the reporting app ships — but the game has to collapse out of expanded mode just to show a login prompt.
  • Reddit's own Join button in the expanded-view header (the … / Join / expand / close bar) behaves the same way: its auth modal also appears behind the app, which suggests the host overlay/modal layer sits below the expanded web view rather than above it.

Impact

Logged-out players who play a run and tap "Sign in" cannot log in, because the modal is invisible, and Reddit's own Join in the expanded header is affected too.

主要语言
TypeScript
星标
217
派生
89
PR 合并指标
30 天内没有已合并 PR

环境准备

这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

reddit/devvit 的其他 Issue

查看 reddit/devvit 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。