Login and Ask an organizer now show the live sent, expired, invalid-email, and send-failed screens instead of stopping on a generic error. Phone sheets stay in the visible viewport when the keyboard opens, so the submit control is not trapped behind it. The login email is a light HTML message with a dark logo band, and the link lifetime in copy matches the 60-minute token.
Changes
Login sent. After a successful send, the card switches to “Check your email”, names the address, and says the link works for 60 minutes (MAGIC_LINK_TTL_MINUTES). Primary action is Close; “Send it again” stays as a text control.
Login expired / used.?error=expired_link and ?error=invalid_link share “That link has expired”. The submit label becomes “Send a new link”. Server and stakeholder-wrong-account errors stay as banners.
Login invalid email. A bad address is a field hint (“Enter an email address like name@example.org.”), not a separate overlay. A later failed send returns to the form instead of leaving the sent screen up.
Ask an organizer sent. A successful POST shows “Thanks” / “One of us will write back within two working days.” and a Close button.
Ask an organizer send-failed. A failed POST keeps the form and shows a danger toast: “We could not send that.” Phone puts the toast in the sheet footer; desktop puts it under the card. Typing clears email and question hints.
Phone keyboard.useVisualViewportHeight tracks visualViewport height and offsetTop (iOS Safari). Login, Ask an organizer (presentation="sheet"), and Create pin the overlay to that box so the footer sits above the keyboard.
Login layout. “Back to home” / below-card copy lives inside the sheet on phone and outside the card on desktop.
Focus. Opening a Create sheet focuses the email or first field, not Close.
Login email. Light HTML template with a dark CommunityRule logo band, 60-minute copy, and a matching plain-text part.
Copy. Submit is “Send login link” / “Send a new link”; Ask an organizer title and submit are “Ask an organizer” / “Send question”.
Stories and tests. Login Storybook adds the expired route. Component and unit tests cover sent, expired, invalid email, send-failed, viewport offset, and the mail builder.
Submit not-an-email. Confirm the red field hint and that the card does not change heading.
Submit you@example.com. Confirm “Check your email”, the address, “60 minutes”, Close, and “Send it again”.
Open /login?error=expired_link and /login?error=invalid_link. Both should show “That link has expired” and “Send a new link”. /login?error=server should stay a banner.
On the homepage, open Ask an organizer. Send a short question with a valid email. With mail configured, you should see “Thanks”. Force a failed POST (stop SMTP, or leave ORGANIZER_INQUIRY_TO unset) and confirm the toast under the card; the question should still be in the field.
On a phone or DevTools device mode, focus the email field so the keyboard opens. The sheet footer (Send login link / Send question) should stay visible above the keyboard, including on iOS Safari.
Storybook: Components / Modals / Login → “Link expired”, plus the header overlay and /login stories. AskOrganizerInquiry default story for the form and sent path.
With Mailhog (http://localhost:8025), request a login link and confirm the light email, dark logo band, and 60-minute line.
Notes
Figma’s login mail copy says “[ten minutes]”. The live token is 60 minutes, so UI and email both use MAGIC_LINK_TTL_MINUTES.
Invalid email is a hint on the same card, not a dedicated overlay. Expired and already-used links share one heading.
Ask an organizer still needs ORGANIZER_INQUIRY_TO (and SMTP) for a real send; without them the toast is the expected local result.
Phone keyboard pinning needs a real visual viewport. Chrome device mode is a start; iOS Safari is the proof.
## Overview
Login and Ask an organizer now show the live sent, expired, invalid-email, and send-failed screens instead of stopping on a generic error. Phone sheets stay in the visible viewport when the keyboard opens, so the submit control is not trapped behind it. The login email is a light HTML message with a dark logo band, and the link lifetime in copy matches the 60-minute token.
## Changes
- **Login sent.** After a successful send, the card switches to “Check your email”, names the address, and says the link works for 60 minutes (`MAGIC_LINK_TTL_MINUTES`). Primary action is Close; “Send it again” stays as a text control.
- **Login expired / used.** `?error=expired_link` and `?error=invalid_link` share “That link has expired”. The submit label becomes “Send a new link”. Server and stakeholder-wrong-account errors stay as banners.
- **Login invalid email.** A bad address is a field hint (“Enter an email address like name@example.org.”), not a separate overlay. A later failed send returns to the form instead of leaving the sent screen up.
- **Ask an organizer sent.** A successful POST shows “Thanks” / “One of us will write back within two working days.” and a Close button.
- **Ask an organizer send-failed.** A failed POST keeps the form and shows a danger toast: “We could not send that.” Phone puts the toast in the sheet footer; desktop puts it under the card. Typing clears email and question hints.
- **Phone keyboard.** `useVisualViewportHeight` tracks `visualViewport` height and `offsetTop` (iOS Safari). Login, Ask an organizer (`presentation="sheet"`), and Create pin the overlay to that box so the footer sits above the keyboard.
- **Login layout.** “Back to home” / below-card copy lives inside the sheet on phone and outside the card on desktop.
- **Focus.** Opening a Create sheet focuses the email or first field, not Close.
- **Login email.** Light HTML template with a dark CommunityRule logo band, 60-minute copy, and a matching plain-text part.
- **Copy.** Submit is “Send login link” / “Send a new link”; Ask an organizer title and submit are “Ask an organizer” / “Send question”.
- **Stories and tests.** Login Storybook adds the expired route. Component and unit tests cover sent, expired, invalid email, send-failed, viewport offset, and the mail builder.
## Screenshots

## How to Test
1. `npm run dev`. Open [http://localhost:3000/login](http://localhost:3000/login).
2. Submit `not-an-email`. Confirm the red field hint and that the card does not change heading.
3. Submit `you@example.com`. Confirm “Check your email”, the address, “60 minutes”, Close, and “Send it again”.
4. Open `/login?error=expired_link` and `/login?error=invalid_link`. Both should show “That link has expired” and “Send a new link”. `/login?error=server` should stay a banner.
5. On the homepage, open **Ask an organizer**. Send a short question with a valid email. With mail configured, you should see “Thanks”. Force a failed POST (stop SMTP, or leave `ORGANIZER_INQUIRY_TO` unset) and confirm the toast under the card; the question should still be in the field.
6. On a phone or DevTools device mode, focus the email field so the keyboard opens. The sheet footer (Send login link / Send question) should stay visible above the keyboard, including on iOS Safari.
7. Storybook: **Components / Modals / Login** → “Link expired”, plus the header overlay and `/login` stories. **AskOrganizerInquiry** default story for the form and sent path.
8. With Mailhog (`http://localhost:8025`), request a login link and confirm the light email, dark logo band, and 60-minute line.
## Notes
- Figma’s login mail copy says “[ten minutes]”. The live token is 60 minutes, so UI and email both use `MAGIC_LINK_TTL_MINUTES`.
- Invalid email is a hint on the same card, not a dedicated overlay. Expired and already-used links share one heading.
- Ask an organizer still needs `ORGANIZER_INQUIRY_TO` (and SMTP) for a real send; without them the toast is the expected local result.
- Phone keyboard pinning needs a real visual viewport. Chrome device mode is a start; iOS Safari is the proof.
Connect the live modals to the drawn sent, expired, invalid-email, and send-failed screens, pin the phone footer above the keyboard, and send the light login email.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Overview
Login and Ask an organizer now show the live sent, expired, invalid-email, and send-failed screens instead of stopping on a generic error. Phone sheets stay in the visible viewport when the keyboard opens, so the submit control is not trapped behind it. The login email is a light HTML message with a dark logo band, and the link lifetime in copy matches the 60-minute token.
Changes
MAGIC_LINK_TTL_MINUTES). Primary action is Close; “Send it again” stays as a text control.?error=expired_linkand?error=invalid_linkshare “That link has expired”. The submit label becomes “Send a new link”. Server and stakeholder-wrong-account errors stay as banners.useVisualViewportHeighttracksvisualViewportheight andoffsetTop(iOS Safari). Login, Ask an organizer (presentation="sheet"), and Create pin the overlay to that box so the footer sits above the keyboard.Screenshots
How to Test
npm run dev. Open http://localhost:3000/login.not-an-email. Confirm the red field hint and that the card does not change heading.you@example.com. Confirm “Check your email”, the address, “60 minutes”, Close, and “Send it again”./login?error=expired_linkand/login?error=invalid_link. Both should show “That link has expired” and “Send a new link”./login?error=servershould stay a banner.ORGANIZER_INQUIRY_TOunset) and confirm the toast under the card; the question should still be in the field./loginstories. AskOrganizerInquiry default story for the form and sent path.http://localhost:8025), request a login link and confirm the light email, dark logo band, and 60-minute line.Notes
MAGIC_LINK_TTL_MINUTES.ORGANIZER_INQUIRY_TO(and SMTP) for a real send; without them the toast is the expected local result.