I’ve got a custom theme for keycloak for the login and the account pages.
I inherit the keycloak theme and make changes to that in themes/mytheme/login/theme.properties
Where I’ve set parent=keycloak.
I want to share resources (fonts and images) across both the login and account themes. themes/mytheme/login themes/mytheme/account
I see that in the keycloak theme there is a themes/keycloak/common thats used to share resources.
So I attempted the same method by creating themes/mytheme/common.
However when i attempt to share resources between my custom themes by setting the stylesCommon attribute in theme.properties i receive a MIME type error (indicating that the file can’t be found). I’ve attempted to add import=common/mytheme in theme.properties and this didn’t fix the issue.
Could anyone please point me to a working example of a custom theme, inheriting from keycloak, sharing resources between theme types?
For example, if you have a css file in theme/mytheme/common/resources/css/my.css that you want to use in one of your themes, the theme.properties in yourtheme should include:
locales=en,fr
styles=css/login.css
# -- which I already tried
# by default keycloak use common/keycloak
# (but how to change to my own common resources ?
# I tried this import=common/my-custom-theme but I have an error 500)
stylesCommon=css/bootstrap.min.css (it's bootstrap file of keycloak (3.4.1 :/)
Do you have a public repo I/we can fork and test on? I’ve got something similar working, but without seeing your full setup, I can’t be sure it will work the same way.