Repository navigation
Add compare pages to stock Keycloak in dev server - #39
Conversation
d41f84e to
8294c50
Compare
8294c50 to
c123a88
Compare
|
If the changes here are deemed too much to be maintaining it. We can drop them and simply compare using https://storybook.keycloakify.dev. |
But if we go this route we still need to keep the feature toggles in. |
wborn
left a comment
There was a problem hiding this comment.
This is an initial AI-assisted review.
The side-by-side comparison functionality is a useful addition to the theme development workflow. Rendering Keycloak's actual FreeMarker templates instead of maintaining separate reference pages reduces duplication and makes differences easier to investigate.
The implementation appropriately separates the development server functionality from the production theme bundle. The stock renderer uses the Keycloak version pinned by the Dockerfile, and the build downloads the upstream themes and relevant dependencies for local development.
One validation gap remains: the CI workflow deliberately skips downloadStockKeycloak, so its successful build does not establish that the new download and rendering workflow operates correctly.
Before merging, the complete development workflow should be exercised with a clean checkout, including the stock renderer and comparison pane. This is particularly relevant because the new functionality spans Gradle dependency resolution, Java, FreeMarker, Node, and browser-side code.
The current GitHub PR also reports a non-mergeable state, which should be reassessed after synchronizing the stacked branches.
The existing CI/CD and Keycloak checks pass, but the new stock-renderer functionality has not been independently executed as part of this review.
c123a88 to
08768a3
Compare
08768a3 to
0447e38
Compare
0447e38 to
be13acc
Compare
be13acc to
9fc797d
Compare
wborn
left a comment
There was a problem hiding this comment.
The new stock-renderer CI check addresses the validation concern raised in the previous review, and the PR is now mergeable.
One issue remains in the iframe switching logic: rapid navigation can trigger multiple swap handlers and leave both frames hidden. This should be addressed before merging.
No other blocking issues were identified in the current changes.
This review was AI-assisted.
Description
"What does Keycloak do here?" came up constantly while deciding which pages to implement. These changes add a compare pane to render the stock Keycloak theme directly in the dev-server next to ours. It also allows us to view those pages we haven't yet implemented.
Changelog
./gradlew installDistdownloads Keycloak's own themes and the FreeMarker to render them intotheme/ui/.keycloak. Nothing of it reaches the jar, and the image build skips the download so a release cannot fail because Maven Central was unreachable.theme/ui/dev-server/check-stock-renderer.shis that check, runnable by hand.Workflow
Show stock Keycloak in the dev menu splits the window. It needs
./gradlew installDistonce, for the templates, and a JDK on the PATH.Drift risk
dev-server/StockRenderer.javareproduces the small part of Keycloak's FreeMarker provider that its templates need, which is the one place here that can fall behind Keycloak without anything noticing. It is dev-only: nothing it does reaches the image, and a rule is only ever added for a template that fails to render.