8000 make multi value toggle less confusing by edewit · Pull Request #51110 · keycloak/keycloak · GitHub
[go: up one dir, main page]

Skip to content

make multi value toggle less confusing - #51110

Open
edewit wants to merge 1 commit into
keycloak:mainfrom
edewit:multi-value-toggle
Open

edewit wants to merge 1 commit into
keycloak:mainfrom
edewit:multi-value-toggle

Conversation

@edewit
@edewit edewit commented Jul 23, 2026
Copy link
Copy Markdown
Contributor

Align multivalued rendering precedence across user profile UIs

Ensure inputType-specific controls (select, multiselect,
select-radiobuttons, multiselect-checkboxes, textarea) take precedence
over generic multi-input rendering in React, and mirror the same
fallback behavior in FreeMarker when inputType is unset. Clarify the
Multivalued help text in Admin UI and update the user profile Playwright
spec to assert the new precedence rules.

fixes: #34763
Signed-off-by: Erik Jan de Wit erikjan.dewit@gmail.com

Copilot AI review requested due to automatic review settings July 23, 2026 11:33
@edewit
edewit requested review from a team as code owners July 23, 2026 11:33
Copilot AI left a comment
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Aligns multivalued user-profile field rendering across React and FreeMarker UIs.

Changes:

  • Prioritizes dedicated inputType controls over generic multi-input rendering.
  • Adds FreeMarker multivalue inference and Playwright coverage.
  • Clarifies the Admin UI help text.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

File Description
themes/src/main/resources/theme/base/login/user-profile-commons.ftl Adds inferred multivalue fallback.
js/libs/ui-shared/src/user-profile/UserProfileFields.tsx Implements dedicated-control precedence.
js/apps/admin-ui/test/realm-settings/userprofile.spec.ts Tests toggle persistence and checkbox rendering.
js/apps/admin-ui/maven-resources/theme/keycloak.v2/admin/messages/messages_en.properties Updates multivalued help text.

Copilot AI left a comment
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 5 out of 5 changed files in this pull request and generated no new comments.

@keycloak-github-bot keycloak-github-bot Bot left a comment
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unreported flaky test detected, please review

@keycloak-github-bot
Copy link
Copy Markdown

Unreported flaky test detected

If the flaky tests below are affected by the changes, please review and update the changes accordingly. Otherwise, a maintainer should report the flaky tests prior to merging the PR.

org.keycloak.testsuite.broker.KcOidcBrokerTest#loginWithExistingUserWithBruteForceEnabled

Keycloak CI - Java Distribution IT (windows-latest - temurin - 17)

org.openqa.selenium.TimeoutException: 
Expected condition failed: waiting for value to contain (ignoring case) "sign in to". Current value: "AUTH_RESPONSE" (tried for 5 second(s) with 500 milliseconds interval)
Build info: version: '4.28.1', revision: '73f5ad48a2'
System info: os.name: 'Windows Server 2025', os.arch: 'amd64', os.version: '10.0', java.version: '17.0.19'
Driver info: org.jboss.arquillian.drone.webdriver.htmlunit.DroneHtmlUnitDriver_ByGraphene
...

Report flaky test

@keycloak-github-bot keycloak-github-bot Bot left a comment
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unreported flaky test detected, please review

@keycloak-github-bot
Copy link
Copy Markdown

Unreported flaky test detected

If the flaky tests below are affected by the changes, please review and update the changes accordingly. Otherwise, a maintainer should report the flaky tests prior to merging the PR.

org.keycloak.testsuite.broker.KcOidcBrokerTest#loginWithExistingUserWithBruteForceEnabled

Keycloak CI - Java Distribution IT (windows-latest - temurin - 17)

org.openqa.selenium.TimeoutException: 
Expected condition failed: waiting for value to contain (ignoring case) "sign in to". Current value: "AUTH_RESPONSE" (tried for 5 second(s) with 500 milliseconds interval)
Build info: version: '4.28.1', revision: '73f5ad48a2'
System info: os.name: 'Windows Server 2025', os.arch: 'amd64', os.version: '10.0', java.version: '17.0.19'
Driver info: org.jboss.arquillian.drone.webdriver.htmlunit.DroneHtmlUnitDriver_ByGraphene
...

Report flaky test

Align multivalued rendering precedence across user profile UIs

Ensure inputType-specific controls (select, multiselect,
select-radiobuttons, multiselect-checkboxes, textarea) take precedence
over generic multi-input rendering in React, and mirror the same
fallback behavior in FreeMarker when inputType is unset. Clarify the
Multivalued help text in Admin UI and update the user profile Playwright
spec to assert the new precedence rules.

fixes: keycloak#34763
Signed-off-by: Erik Jan de Wit <erikjan.dewit@gmail.com>
@edewit
edewit force-pushed the multi-value-toggle branch from 7265fe7 to d83fe12 Compare November 27, 2026 12:28
Copilot AI balanced review requested due to automatic review settings November 27, 2026 12:28
Copilot AI left a comment
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Active defects cause multiselect string defaults to crash or corrupt values, omit options configured through custom validators, and leave inferred multivalued fields without working add/remove controls.

3 open issues
1 resolved since last review

Review effort: Balanced

Comment on lines +192 to +195
inputType === "select" ||
inputType === "multiselect" ||
inputType === "select-radiobuttons" ||
inputType === "multiselect-checkboxes";
Comment on lines +193 to +195
inputType === "multiselect" ||
inputType === "select-radiobuttons" ||
inputType === "multiselect-checkboxes";
Comment on lines +80 to +81
<#assign inferredMultivalued = !attribute.annotations.inputType?? && (attribute.values?size > 1)>
<#if (attribute.multivalued || inferredMultivalued) && attribute.values?has_content>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

In User Profile attribute config, Multivalued toggle is confusing

2 participants

0