From d79ebfda10958abb2cb3bb0aec145cf7a6cfe180 Mon Sep 17 00:00:00 2001 From: Yuri Yaryshev Date: Fri, 4 Dec 2026 14:31:41 +0300 Subject: [PATCH] =?UTF-8?q?Keycloak:=20=D1=82=D0=B5=D0=BC=D0=B0=20=D0=B2?= =?UTF-8?q?=D1=85=D0=BE=D0=B4=D0=B0=20khb=20(=D0=BA=D1=80=D1=83=D0=BF?= =?UTF-8?q?=D0=BD=D0=B0=D1=8F=20=D0=BF=D1=83=D0=BB=D1=8C=D1=81=D0=B8=D1=80?= =?UTF-8?q?=D1=83=D1=8E=D1=89=D0=B0=D1=8F=20=D0=BA=D0=BD=D0=BE=D0=BF=D0=BA?= =?UTF-8?q?=D0=B0=20Google=20=D1=81=D0=B2=D0=B5=D1=80=D1=85=D1=83)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Sonnet 5.5 --- .../login/resources/css/khb.css | 34 +++++++++++++++++++ .../keycloak-theme-khb/login/theme.properties | 2 ++ 2 files changed, 36 insertions(+) create mode 100644 deploy/infra/keycloak-theme-khb/login/resources/css/khb.css create mode 100644 deploy/infra/keycloak-theme-khb/login/theme.properties diff --git a/deploy/infra/keycloak-theme-khb/login/resources/css/khb.css b/deploy/infra/keycloak-theme-khb/login/resources/css/khb.css new file mode 100644 index 0000000..8dea039 --- /dev/null +++ b/deploy/infra/keycloak-theme-khb/login/resources/css/khb.css @@ -0,0 +1,34 @@ +/* Тема входа KH Build: кнопка Google сверху, крупная, с пульсирующей рамкой (логин и пароль нужны редко). */ +.pf-v5-c-login__main { display: flex; flex-direction: column; } +.pf-v5-c-login__main-header { order: -2; } +.pf-v5-c-login__main-footer { order: -1; } +.pf-v5-c-login__main-footer-band { display: none; } +#kc-social-providers { margin-bottom: 1.5rem; } +#kc-social-providers li { padding-bottom: 0; } + +#social-google { + position: relative; + min-height: 9rem; /* примерно в 4 раза выше обычной кнопки */ + gap: 1.25rem; + padding: 1rem 1.5rem; + justify-content: flex-start; + border: 3px solid #4285f4; + border-radius: 12px; + font-size: 1.5rem; + font-weight: 600; + animation: khb-pulse 1.6s ease-in-out infinite; +} +#social-google svg.google { width: 5rem; height: 5rem; flex: none; } /* значок крупнее вместе с кнопкой */ +#social-google .pf-v5-u-m-auto { margin: 0 !important; display: flex; flex-direction: column; align-items: flex-start; line-height: 1.2; } +#social-google .pf-v5-u-m-auto::after { + content: "Click here if you don't know"; + font-size: 1rem; + font-weight: 400; + color: #6a6e73; +} +@keyframes khb-pulse { + 0% { box-shadow: 0 0 0 0 rgba(66, 133, 244, .65); } + 70% { box-shadow: 0 0 0 16px rgba(66, 133, 244, 0); } + 100% { box-shadow: 0 0 0 0 rgba(66, 133, 244, 0); } +} +@media (prefers-reduced-motion: reduce) { #social-google { animation: none; box-shadow: 0 0 0 4px rgba(66, 133, 244, .4); } } diff --git a/deploy/infra/keycloak-theme-khb/login/theme.properties b/deploy/infra/keycloak-theme-khb/login/theme.properties new file mode 100644 index 0000000..c0f83f4 --- /dev/null +++ b/deploy/infra/keycloak-theme-khb/login/theme.properties @@ -0,0 +1,2 @@ +parent=keycloak.v2 +styles=css/styles.css css/khb.css