From 054fcba46f58f6b12a9ed347fa4a9b8afecf3222 Mon Sep 17 00:00:00 2001 From: Vladyslav_Prykhodko Date: Mon, 12 Oct 2020 19:33:52 +0300 Subject: [PATCH] UI: Change OAuth2 templated icon --- ui-ngx/src/app/app.component.ts | 21 +++++++++++++++++++ .../admin/oauth2-settings.component.html | 2 +- .../login/pages/login/login.component.html | 2 +- .../login/pages/login/login.component.scss | 6 ++++++ .../assets/locale/locale.constant-en_US.json | 2 +- 5 files changed, 30 insertions(+), 3 deletions(-) diff --git a/ui-ngx/src/app/app.component.ts b/ui-ngx/src/app/app.component.ts index b46adc095d..f7d290c5ca 100644 --- a/ui-ngx/src/app/app.component.ts +++ b/ui-ngx/src/app/app.component.ts @@ -68,6 +68,27 @@ export class AppComponent implements OnInit { ) ); + this.matIconRegistry.addSvgIconLiteral( + 'google-logo', + this.domSanitizer.bypassSecurityTrustHtml( + '' + ) + ); + + this.matIconRegistry.addSvgIconLiteral( + 'github-logo', + this.domSanitizer.bypassSecurityTrustHtml( + '' + ) + ); + + this.matIconRegistry.addSvgIconLiteral( + 'facebook-logo', + this.domSanitizer.bypassSecurityTrustHtml( + '' + ) + ); + this.storageService.testLocalStorage(); this.setupTranslate(); diff --git a/ui-ngx/src/app/modules/home/pages/admin/oauth2-settings.component.html b/ui-ngx/src/app/modules/home/pages/admin/oauth2-settings.component.html index 9274b5cbfc..ee1c5b725c 100644 --- a/ui-ngx/src/app/modules/home/pages/admin/oauth2-settings.component.html +++ b/ui-ngx/src/app/modules/home/pages/admin/oauth2-settings.component.html @@ -275,7 +275,7 @@ admin.oauth2.login-button-label {{ 'admin.oauth2.login-button-label-required' | translate }} diff --git a/ui-ngx/src/app/modules/login/pages/login/login.component.html b/ui-ngx/src/app/modules/login/pages/login/login.component.html index 35dbb0e401..c0d4d5ed23 100644 --- a/ui-ngx/src/app/modules/login/pages/login/login.component.html +++ b/ui-ngx/src/app/modules/login/pages/login/login.component.html @@ -31,7 +31,7 @@
diff --git a/ui-ngx/src/app/modules/login/pages/login/login.component.scss b/ui-ngx/src/app/modules/login/pages/login/login.component.scss index 6a1c75aaaf..b8fa052e75 100644 --- a/ui-ngx/src/app/modules/login/pages/login/login.component.scss +++ b/ui-ngx/src/app/modules/login/pages/login/login.component.scss @@ -74,6 +74,12 @@ &:hover { border-bottom: 0; } + + .icon{ + height: 20px; + width: 20px; + vertical-align: sub; + } } .centered ::ng-deep .mat-button-wrapper { diff --git a/ui-ngx/src/assets/locale/locale.constant-en_US.json b/ui-ngx/src/assets/locale/locale.constant-en_US.json index 9a5d71a2e6..6c2cb84b80 100644 --- a/ui-ngx/src/assets/locale/locale.constant-en_US.json +++ b/ui-ngx/src/assets/locale/locale.constant-en_US.json @@ -158,7 +158,7 @@ "last-name-attribute-key": "Last name attribute key", "login-button-icon": "Login button icon", "login-button-label": "Provider label", - "login-button-label-1": "Login with $(Provider label)", + "login-button-label-placeholder": "Login with $(Provider label)", "login-button-label-required": "Label is required.", "login-provider": "Login provider", "mapper": "Mapper",