feat: configurable label and badge for the provider sign-in button #15

Merged
crapougnax merged 3 commits from feat/14-sign-in-button-branding into develop 2026-11-16 20:10:04 +00:00
Member

Closes #14

Stacked on pull request 13 (local accounts): until it is merged, this diff also shows its commits. Merge it after 13.

What

Two optional settings for the button that starts the OpenID Connect sign-in:

  • OIDC_BUTTON_LABEL: text of the button (at most 80 characters).
  • OIDC_BUTTON_IMAGE: badge shown in place of the button; the label becomes its alternative text. Accepted: an absolute https URL, or a path of the instance starting with /.

Without them the page is unchanged. A malformed value makes the sign-in page fail with a logged AuthSettingsError, like the other sign-in settings.

A remote badge is fetched by the browser of each visitor from its host, with referrerpolicy="no-referrer"; the documentation says so.

Verified

  • yarn test: 62 tests pass, 4 new ones on the reading of the settings (default, label and badge, refused addresses such as http:, javascript:, data:, protocol-relative, relative; label too long).
  • On the production build: default button unchanged; with both settings the page shows the badge with the label as escaped alternative text; with a malformed address the page answers 500.

Not verified

  • No check in a browser: the size and alignment of the badge were not looked at.

🤖 Generated with Claude Code

Closes #14 **Stacked on pull request 13** (local accounts): until it is merged, this diff also shows its commits. Merge it after 13. ## What Two optional settings for the button that starts the OpenID Connect sign-in: - `OIDC_BUTTON_LABEL`: text of the button (at most 80 characters). - `OIDC_BUTTON_IMAGE`: badge shown in place of the button; the label becomes its alternative text. Accepted: an absolute `https` URL, or a path of the instance starting with `/`. Without them the page is unchanged. A malformed value makes the sign-in page fail with a logged `AuthSettingsError`, like the other sign-in settings. A remote badge is fetched by the browser of each visitor from its host, with `referrerpolicy="no-referrer"`; the documentation says so. ## Verified - `yarn test`: 62 tests pass, 4 new ones on the reading of the settings (default, label and badge, refused addresses such as `http:`, `javascript:`, `data:`, protocol-relative, relative; label too long). - On the production build: default button unchanged; with both settings the page shows the badge with the label as escaped alternative text; with a malformed address the page answers 500. ## Not verified - No check in a browser: the size and alignment of the badge were not looked at. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Accounts and sessions now live in the instance database through
@quatrain/auth-local; Supabase Auth is removed.

- Password sign-in with an opaque session cookie (`studio-session`),
  limited per login after repeated failures.
- Optional OpenID Connect sign-in (authorization code flow with PKCE)
  through @quatrain/auth-oidc-client; the return address comes from
  PUBLIC_BASE_URL, never from the request. An identity is never matched
  to an existing account by e-mail address.
- Accounts and instance roles managed by `yarn admin account:*`; tenant
  members are named by login.
- Migration 0002 creates the account tables; the application role may
  read, create and update accounts, never delete them.
- Roles are no longer read from provider claims.

BREAKING CHANGE: the PUBLIC_SUPABASE_*, SUPABASE_URL and OAUTH_CLIENT_*
variables are no longer read. The instance database is required to sign
in, and existing users need an account (`yarn admin account:create`).

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
chore(deps): add @quatrain/auth-local (#12)
All checks were successful
Build and Publish OCI Image / Build & Push ARM64 OCI Image (pull_request) Successful in 3m44s
3491754913
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
feat: configurable label and badge for the provider sign-in button (#14)
All checks were successful
Build and Publish OCI Image / Build & Push ARM64 OCI Image (pull_request) Successful in 4m33s
8725cdbb14
OIDC_BUTTON_LABEL sets the text of the button that starts the OpenID Connect
sign-in; OIDC_BUTTON_IMAGE shows a badge in its place, the label becoming its
alternative text. The badge address must be an absolute https URL or a path of
the instance.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
crapougnax merged commit ecaf5b2b94 into develop 2026-11-16 20:10:04 +00:00
crapougnax deleted branch feat/14-sign-in-button-branding 2026-11-16 20:10:04 +00:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
modaka/studio!15
No description provided.