<div dir="ltr"><div>+1  we have similar requirements where we like to use different themes for hybrid mobile app clients and traditional responsive web (site) clients</div><div><br></div><div><br></div><div><span style="font-size:14.4px">Date: Thu, 31 Dec 2015 10:49:28 +0200</span><br style="font-size:14.4px"><span style="font-size:14.4px">From: Thomas Raehalme &lt;</span><a href="mailto:thomas.raehalme@aitiofinland.com" style="font-size:14.4px">thomas.raehalme@aitiofinland.com</a><span style="font-size:14.4px">&gt;</span><br style="font-size:14.4px"><span style="font-size:14.4px">Subject: Re: [keycloak-user] Different theme for each client</span><br style="font-size:14.4px"><span style="font-size:14.4px">To: keycloak-user &lt;</span><a href="mailto:keycloak-user@lists.jboss.org" style="font-size:14.4px">keycloak-user@lists.jboss.org</a><span style="font-size:14.4px">&gt;</span><br style="font-size:14.4px"><span style="font-size:14.4px">Message-ID:</span><br style="font-size:14.4px"><span style="font-size:14.4px">        &lt;CAPyAMobFqJRKzfJdN9=-</span><a href="mailto:EUTxUKPr68vCwuwuKzQ9rwaoO6tuoA@mail.gmail.com" style="font-size:14.4px">EUTxUKPr68vCwuwuKzQ9rwaoO6tuoA@mail.gmail.com</a><span style="font-size:14.4px">&gt;</span><br style="font-size:14.4px"><span style="font-size:14.4px">Content-Type: text/plain; charset=&quot;utf-8&quot;</span><br style="font-size:14.4px"><br style="font-size:14.4px"><span style="font-size:14.4px">+1 as I have a similar use-case from a customer.</span><br style="font-size:14.4px"><br style="font-size:14.4px"><span style="font-size:14.4px">On Thu, Dec 31, 2015 at 10:46 AM, Travis De Silva &lt;</span><a href="mailto:traviskds@gmail.com" style="font-size:14.4px">traviskds@gmail.com</a><span style="font-size:14.4px">&gt;</span><br style="font-size:14.4px"><span style="font-size:14.4px">wrote:</span><br style="font-size:14.4px"><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; Hi,</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt;</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; My vote is to provide this feature at a client level as per the original</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; request.</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt;</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; I think realms should be used for completely different domains when we</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; want to isolate users etc. Should not try and use it for something that it</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; was not intended in the design.</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt;</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; The reason why you might need theming at client level is iif you really</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; think that clients which are essentially different applications most of the</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; time and each of these applications might have different look and feel</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; themes (either due to different development teams or vendors building</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; different applications).</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt;</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; So when someone logins via KeyCloak, its true that we are logging into a</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; realm but for an end user, it is really logging into a application and</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; there is a need for the login page theme to look similar to the application</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; look and feel.</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt;</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; Also I have a use case where I have a back office application that</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; requires login for admin users and then I have the front office of this</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; application where in addition to the admin users, you also can have other</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; users as well who can self register and login to the front end which is a</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; consumer facing site.</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt;</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; How I handle this is by having two clients in the same realm. This works</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; fine if you are happy with the same backend login theme to be there for the</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; consumer facing frontend. But we cannot do that as the front end is a</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; consumer facing SaaS site, so each front end needs to have the client&#39;s</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; website theme. This becomes very hard to do if we don&#39;t have theming at a</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; client level.</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt;</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; I came across this post from Bill a few months ago</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; </span><a href="http://lists.jboss.org/pipermail/keycloak-user/2015-July/002537.html" rel="noreferrer" target="_blank" style="font-size:14.4px">http://lists.jboss.org/pipermail/keycloak-user/2015-July/002537.html</a><br style="font-size:14.4px"><span style="font-size:14.4px">&gt;</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; I am thinking to make use of the client variable that is available in</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; login.ftl and load different freemarker fragments that will then theme it</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; differently for each client. As mentioned by Bill, having many if</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; conditions might not be ideal but it might meet the requirement.</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt;</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; Cheers</span><br style="font-size:14.4px"><span style="font-size:14.4px">&gt; Travis</span><br></div></div>