Skip to content

web/rbac: disambiguate duplicate permission names in initial permissions - #20786

Merged
GirlBossRush merged 1 commit into
goauthentik:mainfrom
Oluwatobi-Mustapha:bugfix/19847-initial-permission-labels
Mar 9, 2026
Merged

GirlBossRush merged 1 commit into
goauthentik:mainfrom
Oluwatobi-Mustapha:bugfix/19847-initial-permission-labels

Conversation

@Oluwatobi-Mustapha

@Oluwatobi-Mustapha Oluwatobi-Mustapha commented Mar 8, 2026 •

Copy link
Copy Markdown
Contributor

Details

Fixes #19847

The initial permissions dual-select rendered each option using only Permission.name, which made entries ambiguous when different models expose the same display name (for example Device Token).

This change disambiguates each option by adding a scoped descriptor in the secondary line:
<app label> / <model label> (<codename>).

Implementation details:

  • Updates rbacPermissionPair in web/src/admin/rbac/InitialPermissionsForm.ts to render both the existing primary label and a deterministic descriptor.
  • Extends the searchable text payload for each option to include the descriptor, so duplicate names remain discoverable and distinguishable.

This is a UI-only change. It does not modify permission semantics, API contracts, or stored data.


Checklist

  • Local tests pass (ak test authentik/)
  • The code has been formatted (make lint-fix)

If an API change has been made

  • The API schema has been updated (make gen-build)

If changes to the frontend have been made

  • The code has been formatted (make web)

If applicable

  • The documentation has been updated
  • The documentation has been formatted (make docs)

@Oluwatobi-Mustapha
Oluwatobi-Mustapha requested a review from a team as a code owner March 8, 2026 23:14
@netlify

netlify Bot commented Mar 8, 2026

Copy link
Copy Markdown

✅ Deploy Preview for authentik-storybook ready!

Name Link
🔨 Latest commit 8539345
🔍 Latest deploy log https://app.netlify.com/projects/authentik-storybook/deploys/69ae02d817cd7e000820d6ce
😎 Deploy Preview https://deploy-preview-20786--authentik-storybook.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@netlify

netlify Bot commented Mar 8, 2026

Copy link
Copy Markdown

✅ Deploy Preview for authentik-docs ready!

Name Link
🔨 Latest commit 8539345
🔍 Latest deploy log https://app.netlify.com/projects/authentik-docs/deploys/69ae02d8d4201300080e7736
😎 Deploy Preview https://deploy-preview-20786--authentik-docs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@codecov

codecov Bot commented Mar 8, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 93.39%. Comparing base (d917fef) to head (8539345).
⚠️ Report is 17 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #20786      +/-   ##
==========================================
- Coverage   93.43%   93.39%   -0.05%     
==========================================
  Files         983      983              
  Lines       55644    55644              
==========================================
- Hits        51990    51967      -23     
- Misses       3654     3677      +23     
Flag Coverage Δ
conformance 37.58% <ø> (+<0.01%) ⬆️
e2e 43.12% <ø> (+<0.01%) ⬆️
integration 22.32% <ø> (-0.05%) ⬇️
unit 91.58% <ø> (+<0.01%) ⬆️
unit-migrate 91.68% <ø> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@GirlBossRush GirlBossRush added the area:frontend Features or issues related to the browser, TypeScript, Node.js, etc label Mar 9, 2026
@GirlBossRush GirlBossRush added this to the 2026.2.2 milestone Mar 9, 2026
@github-project-automation github-project-automation Bot moved this from Todo to In Progress in authentik Core Mar 9, 2026
@GirlBossRush GirlBossRush removed this from the 2026.2.2 milestone Mar 9, 2026
@GirlBossRush GirlBossRush added the backport/version-2026.2 Add this label to PRs to backport changes to version-2026.2 label Mar 9, 2026
@GirlBossRush
GirlBossRush merged commit df7bba3 into goauthentik:main Mar 9, 2026
100 checks passed
@github-project-automation github-project-automation Bot moved this from In Progress to Done in authentik Core Mar 9, 2026
@authentik-automation

Copy link
Copy Markdown
Contributor

🍒 Cherry-pick to version-2026.2 created: #20805

BeryJu pushed a commit that referenced this pull request Mar 9, 2026
…ons (cherry-pick #20786 to version-2026.2) (#20805)

web/rbac: disambiguate duplicate permission names in initial permissions (#20786)

Co-authored-by: Oluwatobi Mustapha <[email protected]>
@Oluwatobi-Mustapha
Oluwatobi-Mustapha deleted the bugfix/19847-initial-permission-labels branch March 10, 2026 09:31
kensternberg-authentik added a commit that referenced this pull request Mar 10, 2026
* main:
  core: allow interfaces to specify alternative stylesheets (#20774)
  website/docs: update agent docs (#20782)
  core, web: update translations (#20809)
  lifecycle/aws: bump aws-cdk from 2.1109.0 to 2.1110.0 in /lifecycle/aws (#20810)
  core: bump axllent/mailpit from v1.29.2 to v1.29.3 in /tests/e2e (#20811)
  core: bump cachetools from 7.0.4 to 7.0.5 (#20812)
  core: bump goauthentik/fips-python from `b481db2` to `3636935` in /lifecycle/container (#20814)
  core: bump goauthentik/fips-debian from `6c9197b` to `0975985` in /lifecycle/container (#20815)
  web: bump the storybook group across 1 directory with 5 updates (#20816)
  web: bump cspell from 9.6.4 to 9.7.0 (#20817)
  web: bump @formatjs/intl-listformat from 8.2.1 to 8.2.2 in /web (#20818)
  web: bump mermaid from 11.12.3 to 11.13.0 in /web (#20819)
  web: bump @types/node from 25.3.5 to 25.4.0 in /web (#20820)
  endpoints/connectors/agent: cleanup leftover (#20808)
  endpoints: prevent selection of incompatible connector (#20806)
  website/docs: Add steps to set up group devices (#20735)
  web/rbac: disambiguate duplicate permission names in initial permissions (#20786)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:frontend Features or issues related to the browser, TypeScript, Node.js, etc backport/version-2026.2 Add this label to PRs to backport changes to version-2026.2

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

Duplicated device permissions in intial permissions view

2 participants