8000 Add PatternFly 6 custom theme migration guide by edewit · Pull Request #55216 · keycloak/keycloak · GitHub
[go: up one dir, main page]

Skip to content

Add PatternFly 6 custom theme migration guide - #55216

Open
edewit wants to merge 3 commits into
keycloak:mainfrom
edewit:issue-52348-pf6-migration-guide
Open

edewit wants to merge 3 commits into
keycloak:mainfrom
edewit:issue-52348-pf6-migration-guide

Conversation

@edewit
@edewit edewit commented Nov 16, 2026
Copy link
Copy Markdown
Contributor

Summary

Adds a dedicated PatternFly 6 migration guide for custom login, welcome, Account Console, and Admin Console themes in Keycloak 27, and links it from the upgrading guide and release notes.

Closes #52348

@edewit
edewit force-pushed the issue-52348-pf6-migration-guide branch from d4705d3 to dbeac15 Compare November 24, 2026 09:22
@edewit
edewit marked this pull request as ready for review November 24, 2026 09:22
@edewit
edewit requested a review from a team as a code owner November 24, 2026 09:22
Copilot AI balanced review requested due to automatic review settings November 24, 2026 09:22
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

The migration guidance references unavailable theme parents, feature versions, and helper scripts, and includes settings that break theme inheritance or fail startup validation.

6 open issues
What changed in this PR

Adds a dedicated custom-theme migration guide for Keycloak 27’s PatternFly 6 transition, addressing #52348 and connecting it to the existing upgrade documentation.

Changes:

  • Documents theme parents, feature flags, migration helpers, and validation steps for login, welcome, Account Console, and Admin Console themes.
  • Expands version-specific upgrade notes and release notes.
  • Adds shared migration-link and upgrading-guide label support.
File Description
docs/​guides/​templates/​links.adoc Adds a migration-guide link macro.
docs/​guides/​migration/​migrating-themes-to-patternfly-6.adoc Adds the custom-theme migration walkthrough.
docs/​guides/​attributes.adoc Defines the shared Upgrading Guide label.
docs/​documentation/​upgrading/​topics/​migrate_themes.adoc Points theme authors to the new guide.
docs/​documentation/​upgrading/​topics/​changes/​changes-27_0_0.adoc Adds console migration instructions and guide references.
docs/​documentation/​release_notes/​topics/​27_0_0.adoc Broadens the PatternFly 6 announcement and links migration guidance.

Review effort: Balanced

Comment on lines +148 to +149
The built-in Account Console is now `keycloak.v4`, based on PatternFly 6.
The previous `keycloak.v3` Account Console theme and the `account:v3` feature value have been removed.
Comment on lines +200 to +201
It has been upgraded to PatternFly 6, and the built-in admin theme has been renamed from `keycloak.v2` to `keycloak.v3`.
Realms that explicitly use the built-in admin theme are migrated automatically.
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

this will be the case

Copilot AI balanced review requested due to automatic review settings November 27, 2026 15:09
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

The migration documentation omits source-checkout and Node.js/npm prerequisites and misstates automation eligibility and the common-directory layout, potentially causing failed commands or incorrect migration expectations.

3 open issues
2 previously missed issues

In code that hasn't changed since last review

Low severity Document source checkout and Node.js/npm prerequisites

docs/​guides/​migration/​migrating-themes-to-patternfly-6.adoc:96

The commands below assume a Keycloak source checkout, but misc/scripts/ is not included in the server distribution, so users running them from their installation will get a missing-module error. Add instructions for obtaining the source checkout and running from its root, and mention the Node.js/npm prerequisites required by the script's npx calls.

Low severity Clarify that common/ must be inside the theme root

docs/​guides/​migration/​migrating-themes-to-patternfly-6.adoc:112

resolveSiblingCommonDir() resolves common/ inside the theme root, as a sibling of login/, not as a sibling of the theme root. Document that layout explicitly so users do not expect a shared directory beside their theme to be migrated.

4 resolved since last review

Review effort: Balanced

Comment on lines +173 to +181
Those upstream PatternFly tools operate on an Account UI *source checkout*.
They do not rewrite installed or inherited theme directories under `themes/`.

=== CSS-only account themes

If your custom account theme only overrides resources of `keycloak.v3`:

. Change `parent=` to `keycloak.v4`.
. Update PatternFly 5 classes and CSS variables to PatternFly 6 manually; the helper script does not process those theme directories.
Provide a dedicated migration guide for login, welcome, account, and admin
custom themes in Keycloak 27, and link it from the upgrading and release notes.

Closes keycloak#52348

Signed-off-by: Erik Jan de Wit <erikjan.dewit@gmail.com>
Point upgrading and release notes at the published Migration guides
section instead of the not-yet-published direct guide URL.

Signed-off-by: Erik Jan de Wit <erikjan.dewit@gmail.com>
Signed-off-by: Erik Jan de Wit <erikjan.dewit@gmail.com>
@edewit
edewit force-pushed the issue-52348-pf6-migration-guide branch from 91fdf46 to 6fc1d59 Compare December 4, 2026 13:58
Copilot AI balanced review requested due to automatic review settings December 4, 2026 13:58
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

The migration documentation omits the required shared-library switch and lockfile refresh, duplicates an Account Console migration section, and misstates the common directory’s location.

6 open issues

Review effort: Balanced

Comment on lines +124 to +143
=== Account Console moved to `keycloak.v4` and PatternFly 6
// https://github.com/keycloak/keycloak/issues/52344

The built-in Account Console is now the `keycloak.v4` theme, based on PatternFly 6.
The previous `keycloak.v3` Account Console theme and the `account:v3` feature value have been removed.

For new realms, `keycloak.v4` is the default Account Console theme when the `account:v4` feature is enabled (the default).
Existing realms that explicitly use `keycloak`, `keycloak.v2`, or `keycloak.v3` as the account theme are migrated to `keycloak.v4` during upgrade.
Custom account themes are left unchanged.

If you maintain a custom Account Console theme that extends or copies `keycloak.v3`, migrate it to PatternFly 6 before switching its parent to `keycloak.v4`.

For Account UI *source checkouts* (a directory whose `package.json` name is `@keycloak/keycloak-account-ui`), run PatternFly's React and CSS codemods (`@patternfly/pf-codemods`, `@patternfly/css-vars-updater`, `@patternfly/class-name-updater`).
Those tools do not rewrite installed or inherited theme directories under `themes/`.
For CSS-only custom themes that only override resources of `keycloak.v3`, update PatternFly 5 classes and CSS variables to PatternFly 6 manually.
If you explicitly enable `account:v3` (for example `--features=account:v3` or `KC_FEATURES=account:v3`), replace it with `account:v4`, or remove the entry because `account:v4` is enabled by default.
Servers that still request `account:v3` fail feature validation at startup.

See also *Migrating custom themes to PatternFly 6* in the https://www.keycloak.org/guides#migration[Migration guides].

----

`--theme-path` may point at the theme root or at the `login` directory.
When the theme root has a sibling `common/` directory used through `import=common/...`, that directory is migrated as well.

If you maintain a fork of `@keycloak/keycloak-account-ui` (or an equivalent source package that reuses those components):

. Upgrade `@patternfly/react-core` and related PatternFly packages to PatternFly 6.
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.

Provide migration guide for PatternFly 6 upgrade

2 participants

0