Skip to content

admin: show the Microsoft button only when interactive login exists - #18

Merged
selic merged 1 commit into
mainfrom
fix/admin-oidc-button
Jul 25, 2026
Merged

admin: show the Microsoft button only when interactive login exists#18
selic merged 1 commit into
mainfrom
fix/admin-oidc-button

Conversation

@selic

@selic selic commented Jul 25, 2026

Copy link
Copy Markdown
Member

Summary

The /admin sign-in panel rendered "Sign in with Microsoft" unconditionally — on token-only deployments clicking it hit a non-existent /auth/login. Now it uses the same /health-driven gating me.html already has: the button appears only when login: true; a failed /health probe keeps it hidden and never blocks the token box. Copy tweaked ("Or paste…" → "Paste…") so the paragraph reads standalone, and the UI guide's screenshot + note updated to match.

Test plan

  • npm test — 211 passed
  • Manual (token-only dev server, cleared sessionStorage): /admin shows only the token box; token sign-in works
  • With login configured the gating mirrors /me (/health.login covered by oauth-flow tests)

🤖 Generated with Claude Code

Same /health-driven gating me.html already has — on token-only
deployments the sign-in panel no longer renders a "Sign in with
Microsoft" button that would 404 on /auth/login. Copy adjusted so the
token paragraph reads standalone; UI guide screenshot and note updated.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@selic
selic merged commit 5a2126d into main Jul 25, 2026
@selic
selic deleted the fix/admin-oidc-button branch July 25, 2026 07:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant