Repository navigation
feat(login): group the OAuth consent screen's scopes into view, change and delete sections - #3557
Merged
Merged
Conversation
The choice of scopes was one line of what is granted and a "Change" button that opened every scope at once, grouped by resource. A client that asks for many scopes got a paragraph of group names closed, and a long list open. The scopes are now in a section per access: what the client may view, what it may create and change, what it may delete. A section is one line: a checkbox that grants or withdraws all of it (mixed while only some of it is granted), how many of its scopes are granted, and a button that opens them. So what a client may change or delete is seen and decided without opening anything. The section checkboxes replace the "Read only" and "Everything requested" presets. Who asks and where the answer goes read as one short block, label beside value; a value too long for its line wraps under its label. The atom's `presets-label`, `read-only-label`, `everything-label`, `change-label` and `granted-*-label` attributes and their texts are gone; `view-label`, `edit-label`, `delete-label`, `count-label` and `details-label` (`consent.access.*`, `consent.count`, `consent.details`) take their place. The consent step is unreleased, so its changeset is reworded in place. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…ctions and balance its hint Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…l's line A value too long for its line, such as the API's identifier, wrapped under its label, unlike the rows above it. Every row is now label and value on one line; a long value is cut with an ellipsis at its end and shows in full on hover. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…rows The warning sat between where the answer goes and the API, which split the rows of values. The summary is now one grid whose rows share a label column, and the warning is shown after the last of them. It stays in the row of the host it is about, so a screen reader still reads it with that host. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
🦋 Changeset detectedLatest commit: 3f5a715 The changes in this PR will be included in the next version bump. This PR includes changesets to release 27 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
Hostname truncation hides security-critical suffixes, preventing touch users from distinguishing trusted domains from attacker-controlled ones before granting access.
1 open issue
What changed in this PR
Refines the login components’ OAuth consent screen with access-based sections, preserving existing scope-selection defaults.
Changes:
- Replaces presets with expandable view, change and delete sections, each with a bulk checkbox and grant count.
- Aligns client identity rows and repositions the device warning.
- Updates templates, translations, tests, component metadata and documentation.
| File | Description |
|---|---|
packages/config/defaults/branding/minimal/login.liquid |
Uses section labels in the minimal design. |
packages/config/defaults/branding/centered/login.liquid |
Uses section labels in the centered design. |
packages/components/src/orchestrator/zitadel-login-auth-request.spec.ts |
Updates consent count and focus assertions. |
packages/components/src/orchestrator/zitadel-login-auth-request.browser.spec.ts |
Updates keyboard navigation checks. |
packages/components/src/orchestrator/templates/default.liquid |
Passes the new consent labels. |
packages/components/src/orchestrator/mandatory-gates.spec.ts |
Checks section-label injection and overrides. |
packages/components/src/orchestrator/locales/it.ts |
Adds Italian section wording. |
packages/components/src/orchestrator/locales/en.ts |
Adds English section wording. |
packages/components/src/orchestrator/locales/de.ts |
Adds German section wording. |
packages/components/src/orchestrator/design-templates.spec.ts |
Verifies labels across shipped designs. |
packages/components/src/orchestrator/consent-choices.ts |
Maps localized section attributes. |
packages/components/src/atoms/zl-consent.ts |
Implements section selection, counts and expansion. |
packages/components/src/atoms/zl-consent.spec.ts |
Covers section behavior and accessibility markup. |
packages/components/src/atoms/zl-consent.css |
Styles sections, identity rows and warning placement. |
packages/components/src/atoms/zl-consent.browser.spec.ts |
Updates keyboard and disabled-control coverage. |
packages/components/README.md |
Documents the revised consent interface. |
packages/components/custom-elements.json |
Updates generated component metadata. |
docs/design/branding/component-capability-map.md |
Describes access-based consent sections. |
apps/storybook/src/consent.stories.ts |
Updates comments and control descriptions. |
apps/docs/content/docs/guides/customize-design.mdx |
Lists the revised styling parts. |
.changeset/oauth-sign-in-consent.md |
Revises the pending consent release note. |
Review effort: Balanced
The ellipsis for a value too long for its line also applied to the client's name and to the hosts, where it would hide the end of a host: the part that tells a trusted site from one that only starts like it. On a touch device the full value, a tooltip, cannot be read. Names and hosts now wrap in full, and only the API's identifier is cut. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…full No value in the summary is cut any more, so the end of a host is always shown and nothing depends on a tooltip, which a touch device does not show. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…nd chevron A checkbox sat above the middle of its label's line, an opened section's scopes had more room below than above, and the chevron's square, not its arrow, was in the middle of its button. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
fforootd
approved these changes
Dec 2, 2026
This was referenced Dec 2, 2026
2 tasks
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Context
<zl-consent>.Summary
A client that asks for many scopes (an MCP client asks for 28) got a paragraph of group names while the choice was closed, and one long list of checkboxes once "Change" opened it. This PR lays the choice out by what the client may do.
Screenshot
The default story in Storybook, dark, with the View section opened:
Validation
Run at the repo root:
turbo run lint typecheck test --filter=@zitadel/components --filter=@zitadel/config --filter=@zitadel/storybookon the first commit: 18 of 18 tasks passed, including the components' unit, edge and browser projects and Storybook's render and accessibility gate.biome check packages/components/src/atoms, the consent unit and browser specs (zl-consent.spec.ts,zl-consent.browser.spec.ts,zitadel-login-auth-request.browser.spec.ts) andturbo run test --filter=@zitadel/storybook.Atoms/Consent), with a 28-scope request loaded into the story: closed, one section opened, one scope unticked (the section shows as mixed), and the device warning on.Not run: the full suite after the last three commits, the e2e lanes, and a real sign-in against a server. The Storybook gate runs the default story, which has the device warning off.
Release notes / changeset
.changeset/oauth-sign-in-consent.md, reworded in place. The consent step is unreleased, so its note now describes the sections and no new changeset is added (@zitadel/components,@zitadel/config).Notes
<zl-consent>losespresets-label,read-only-label,everything-label,change-label,granted-label,granted-none-label,stay-connected-labelandgranted-view/edit/delete-label, and gainsview-label,edit-label,delete-label,count-labelanddetails-label(consent.access.read,.change,.delete,consent.count,consent.details). The parts change with them. Nothing released carries the old names.consent.group.<group>. The console still ships those texts andTestPersonScopesHaveConsentTextsInTheConsolestill requires them; both are left for a follow-up.🤖 Generated with Claude Code