From 6ac5a2a17ed00bfd36ad103f56f3797547157fcf Mon Sep 17 00:00:00 2001 From: Stan Silvert Date: Fri, 31 Jan 2020 06:16:52 -0500 Subject: [PATCH] [KEYCLOAK-12744] rh-sso-preview theme for product build * change logo for RH-SSO * Small fixes to rh-sso-preview theme * rh-sso-preview theme Co-authored-by: Erik Jan de Wit --- .../admin/info/ServerInfoAdminResource.java | 1 + .../account/messages/messages_en.properties | 4 + .../account/resources/public/favicon.ico | Bin 0 -> 4427 bytes .../account/resources/public/layout.css | 3 + .../account/resources/public/logo.svg | 101 ++++++++++++++++++ .../rh-sso-preview/account/theme.properties | 1 + .../theme/keycloak-preview/account/index.ftl | 36 ++++--- .../account/resources/app/App.tsx | 12 +-- .../{app/assets/img => public}/favicon.ico | Bin .../account/resources/public/layout.css | 3 + .../account/resources/public/logo.svg | 1 + 11 files changed, 138 insertions(+), 24 deletions(-) create mode 100644 themes/src/main/resources-product/theme/rh-sso-preview/account/messages/messages_en.properties create mode 100644 themes/src/main/resources-product/theme/rh-sso-preview/account/resources/public/favicon.ico create mode 100644 themes/src/main/resources-product/theme/rh-sso-preview/account/resources/public/layout.css create mode 100644 themes/src/main/resources-product/theme/rh-sso-preview/account/resources/public/logo.svg create mode 100644 themes/src/main/resources-product/theme/rh-sso-preview/account/theme.properties rename themes/src/main/resources/theme/keycloak-preview/account/resources/{app/assets/img => public}/favicon.ico (100%) create mode 100644 themes/src/main/resources/theme/keycloak-preview/account/resources/public/layout.css create mode 100644 themes/src/main/resources/theme/keycloak-preview/account/resources/public/logo.svg diff --git a/services/src/main/java/org/keycloak/services/resources/admin/info/ServerInfoAdminResource.java b/services/src/main/java/org/keycloak/services/resources/admin/info/ServerInfoAdminResource.java index 3b9cd3b532..808358d99a 100755 --- a/services/src/main/java/org/keycloak/services/resources/admin/info/ServerInfoAdminResource.java +++ b/services/src/main/java/org/keycloak/services/resources/admin/info/ServerInfoAdminResource.java @@ -173,6 +173,7 @@ public class ServerInfoAdminResource { if (!Profile.isFeatureEnabled(Profile.Feature.ACCOUNT2)) { themeNames.remove("keycloak-preview"); + themeNames.remove("rh-sso-preview"); } List themes = new LinkedList<>(); diff --git a/themes/src/main/resources-product/theme/rh-sso-preview/account/messages/messages_en.properties b/themes/src/main/resources-product/theme/rh-sso-preview/account/messages/messages_en.properties new file mode 100644 index 0000000000..8bffc28d8f --- /dev/null +++ b/themes/src/main/resources-product/theme/rh-sso-preview/account/messages/messages_en.properties @@ -0,0 +1,4 @@ +# Put new messages for Account Console Here +# Feel free to use any existing messages from the base theme +accountManagementWelcomeMessage=Welcome to RH-SSO Account Management +accountManagementTitle=RH-SSO Account Management \ No newline at end of file diff --git a/themes/src/main/resources-product/theme/rh-sso-preview/account/resources/public/favicon.ico b/themes/src/main/resources-product/theme/rh-sso-preview/account/resources/public/favicon.ico new file mode 100644 index 0000000000000000000000000000000000000000..11c5cd26196c0bb5ad2c06c13e15449f7cc500bf GIT binary patch literal 4427 zcmchb^-~j$`@q=-Lu#l9j2=ptl!OY5lI{kTA&hPiq=cy;?WALrPygO0X_>80NMk1OCy8EX}r zbg5{3wQT|@DCn;L2Vipf`Ckf(tLHizs^-ryyUX^8=2l$PKlU|WM77}2NwQd+saXp) z-OH4Nr+!($OV&#$;dXbLn&YIP`0ruXTXqJChtZk_r)wY(G%2njp(UG|H?{J*5?r1yuGc)Y+)F1GKd=hsz6)}JDPL7gj%6m!$0JR)EeB)N`3Y9Bhn zxGWOhF;J8Nb_mB1Lv6T=h+nwCVOmT)YDZN(egL2kl$>^@$621#83NkVj;WRHC%@0b zBDen#dp%i3zk`j%zqgnL(>t-Y2<4=SG`AdBi97y7SrH=5;=br%%TKz>{Aj*tlh+YY zLn`QyTnW(P-fw*9(;GPRd_oVfcWxvmAcwHvFNGHO_k`GXP?}XfZFwcxdY3=ar=_CO zNDn&n3fPksXf9$%A|b@%%P2VYm4sGlXh?}KW;gi3(nTzqG9Wp#FhAYXQW;ST&g{u7 ziLb1EFmhbCbZ)ca6PTuW{OH4#B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wZ?XVF%xs{wNkFgSCj_P5xi!4bPSnONkRAT>=1 zTSy*KD8Zrk#LjX|U*FZh^W4D5`m)pq4fOb>%i&~F6>q$;_&JP5d8=sLTNn08xJ z=a_lVIc^P}Vq5}0{J`|=2!J>gKzzWLR~=y+x?9lj7x zTe!nR+=B6KFu8EzjhGnPHDRclK>garLN**m=1~|e~CgYy=5VgF-vfpJW zSw}&nY{t2sfA-mB9NC%Qw+j##DV%{fLqe(!P|c&~SN!?Trj}MTAy@(X%F5D!khd~V z7>B6G4|r=#gEd0UcvG)~R2-#m;^TGLw*pj3JglX3ip-yC2%(yx`lg!$Nme?lRFk@t z0X%J?6IU^4;m$M|D4S2P+DIzPJcW3Nr1Ka;c6ys7F;AcZo4<(2>$ze%)NFerNiQHn z{+Y=N1pjz789D@+8!y2ShT|J+p+nr-DpTQ0b^rQP9*{N@;=Bzk5>TUsESipSmBVgK zWX*90O3=KDr2$#BO!5Va6Jt(@*zqt;7`-%S-&VAmp$tedSSZZ1b_*?L0yo0`I|6<8 ze*I!F6&xQLi0PI@Q>A`O)j2^ZoVUO%q*|2k(19B@=*!!Zb0&_S=Ty`{hj`!m8u9^0 zl*_~XvGF?eCD)~4vckN}+^0wCicRov-CDCzW)K#wUpnV&SRY#H@WNG1Ay4a|nF~A# zFjd;6X1$r_qY5b&5sPI3eS>A2vbn(NTw1?m?}kh_{!;@_g2b5vF$PPhId^M={7hRG z@T7WUxy;EYk%eVpMWyfuwR1e|VCkz~YV7{}kI>&&*?D>^Ugb%m0jV9v9AgcA1 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/themes/src/main/resources-product/theme/rh-sso-preview/account/theme.properties b/themes/src/main/resources-product/theme/rh-sso-preview/account/theme.properties new file mode 100644 index 0000000000..77454e17fe --- /dev/null +++ b/themes/src/main/resources-product/theme/rh-sso-preview/account/theme.properties @@ -0,0 +1 @@ +parent=keycloak-preview diff --git a/themes/src/main/resources/theme/keycloak-preview/account/index.ftl b/themes/src/main/resources/theme/keycloak-preview/account/index.ftl index dace7e39e9..9972fed0ee 100644 --- a/themes/src/main/resources/theme/keycloak-preview/account/index.ftl +++ b/themes/src/main/resources/theme/keycloak-preview/account/index.ftl @@ -7,7 +7,7 @@ - + - - + + - + <#if properties.developmentMode?has_content && properties.developmentMode == "true"> - + <#if properties.extensions?has_content> <#list properties.extensions?split(' ') as script> <#if properties.developmentMode?has_content && properties.developmentMode == "true"> @@ -76,7 +76,7 @@ - + <#if properties.scripts?has_content> <#list properties.scripts?split(' ') as script> @@ -88,6 +88,8 @@ + + @@ -108,7 +110,7 @@ document.getElementById("landingSignOutButton").style.display='inline'; document.getElementById("landingSignOutLink").style.display='inline'; } - + loadjs("/node_modules/systemjs/dist/system.src.js", function() { loadjs("/systemjs.config.js", function() { System.import('${resourceUrl}/Main.js').catch(function (err) { @@ -125,7 +127,7 @@
- Keycloak Logo + Logo

${msg("loadingMessage")}

@@ -143,7 +145,7 @@
@@ -152,7 +154,7 @@ ${msg("backTo",referrerName)}
- + <#if realm.internationalizationEnabled && supportedLocales?size gt 1>
@@ -174,12 +176,12 @@
- +
- +
@@ -192,7 +194,7 @@ ${msg("backTo",referrerName)} - + <#if realm.internationalizationEnabled && supportedLocales?size gt 1> @@ -216,7 +218,7 @@
- +
@@ -285,7 +287,7 @@ document.getElementById("landingLinkedAccountsLink").style.display='block'; }; - // Hidden until feature is complete. + // Hidden until feature is complete. //if (features.isMyResourcesEnabled) { // document.getElementById("landingMyResourcesCard").style.display='block'; //}; diff --git a/themes/src/main/resources/theme/keycloak-preview/account/resources/app/App.tsx b/themes/src/main/resources/theme/keycloak-preview/account/resources/app/App.tsx index 7c0b887e4b..7d5c9a1b5d 100644 --- a/themes/src/main/resources/theme/keycloak-preview/account/resources/app/App.tsx +++ b/themes/src/main/resources/theme/keycloak-preview/account/resources/app/App.tsx @@ -1,4 +1,4 @@ -/* +/* * Copyright 2018 Red Hat, Inc. and/or its affiliates. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -40,7 +40,7 @@ declare const locale: string; declare const resourceUrl: string; const pFlyImages = resourceUrl + '/node_modules/@patternfly/patternfly/assets/images/'; -const brandImg = resourceUrl + '/app/assets/img/keycloak-logo-min.png'; +const brandImg = resourceUrl + '/public/logo.svg'; const avatarImg = pFlyImages + 'img_avatar.svg'; export interface AppProps {}; @@ -65,7 +65,7 @@ export class App extends React.Component { const Header = ( } + logo={} toolbar={} avatar={} showNavToggle @@ -73,11 +73,9 @@ export class App extends React.Component { ); const Sidebar = } />; - - const fullHeight = { height: '100%'}; - + return ( - + {makeRoutes()} diff --git a/themes/src/main/resources/theme/keycloak-preview/account/resources/app/assets/img/favicon.ico b/themes/src/main/resources/theme/keycloak-preview/account/resources/public/favicon.ico similarity index 100% rename from themes/src/main/resources/theme/keycloak-preview/account/resources/app/assets/img/favicon.ico rename to themes/src/main/resources/theme/keycloak-preview/account/resources/public/favicon.ico diff --git a/themes/src/main/resources/theme/keycloak-preview/account/resources/public/layout.css b/themes/src/main/resources/theme/keycloak-preview/account/resources/public/layout.css new file mode 100644 index 0000000000..42ce078bd1 --- /dev/null +++ b/themes/src/main/resources/theme/keycloak-preview/account/resources/public/layout.css @@ -0,0 +1,3 @@ +.brand { + height: 35px; +} \ No newline at end of file diff --git a/themes/src/main/resources/theme/keycloak-preview/account/resources/public/logo.svg b/themes/src/main/resources/theme/keycloak-preview/account/resources/public/logo.svg new file mode 100644 index 0000000000..17edc2c06a --- /dev/null +++ b/themes/src/main/resources/theme/keycloak-preview/account/resources/public/logo.svg @@ -0,0 +1 @@ +keycloak_deliverables \ No newline at end of file