RED-9131: implemented design changes.

This commit is contained in:
Nicoleta Panaghiu 2024-05-17 13:10:19 +03:00
parent da4c9e6331
commit 9a651e3725
7 changed files with 17 additions and 9 deletions

View File

@ -8,7 +8,7 @@
<div class="content-container full-height">
<div class="overlay-shadow"></div>
<div class="dialog">
<div class="dialog-header">
<div *ngIf="!shouldHideTitle" class="dialog-header">
<div class="heading-l" [translate]="translations[path]"></div>
</div>

View File

@ -11,16 +11,21 @@ import { accountTranslations } from '@translations/account-translations';
export class BaseAccountScreenComponent implements OnInit {
readonly translations = accountTranslations;
readonly path: string;
readonly shouldHideTitle: boolean;
constructor(private readonly _router: Router, private readonly _hostRef: ViewContainerRef) {
constructor(
private readonly _router: Router,
private readonly _hostRef: ViewContainerRef,
) {
this.path = this._router.url.split('/').pop();
this.shouldHideTitle = this.path === 'warnings-preferences';
}
ngOnInit(): void {
this._setDialogWidth();
this.#setDialogWidth();
}
private _setDialogWidth() {
#setDialogWidth() {
const element = this._hostRef.element.nativeElement as HTMLElement;
element.style.setProperty('--width', this.path === 'user-profile' ? 'unset' : '100%');
}

View File

@ -1,7 +1,7 @@
<form [formGroup]="form">
<div class="dialog-content">
<h1>{{ 'dialog-defaults-form.title' | translate }}</h1>
<h2>{{ 'dialog-defaults-form.redaction.title' | translate }}</h2>
<h3>{{ 'dialog-defaults-form.redaction.title' | translate }}</h3>
<div class="iqser-input-group w-450">
<label translate="dialog-defaults-form.redaction.add-dialog"></label>
<mat-form-field>
@ -28,7 +28,7 @@
'dialog-defaults-form.extra-option-label' | translate
}}</mat-checkbox>
</div>
<h2>{{ 'dialog-defaults-form.recommendation.title' | translate }}</h2>
<h3>{{ 'dialog-defaults-form.recommendation.title' | translate }}</h3>
<div class="iqser-input-group w-450">
<label translate="dialog-defaults-form.recommendation.remove-dialog"></label>
<mat-form-field>
@ -42,7 +42,7 @@
'dialog-defaults-form.extra-option-label' | translate
}}</mat-checkbox>
</div>
<h2>{{ 'dialog-defaults-form.hint.title' | translate }}</h2>
<h3>{{ 'dialog-defaults-form.hint.title' | translate }}</h3>
<div class="iqser-input-group w-450">
<label translate="dialog-defaults-form.hint.add-dialog"></label>
<mat-form-field>

View File

@ -1,3 +1,7 @@
mat-checkbox {
margin: 8px 0 0 8px;
}
.dialog-actions {
border-top: none;
}

View File

@ -1,4 +1,5 @@
<redaction-dialog-defaults *ngIf="currentScreen === screens.WARNING_PREFERENCES && !config.IS_DOCUMINE"></redaction-dialog-defaults>
<div *ngIf="currentScreen === screens.WARNING_PREFERENCES" class="content-delimiter"></div>
<form [formGroup]="form">
<div class="dialog-content">

View File

@ -2,7 +2,6 @@
.content-delimiter {
border-top: 1px solid var(--iqser-separator);
margin-bottom: 15px;
}
.warnings-description {

View File

@ -4,5 +4,4 @@ export const accountTranslations: Record<string, string> = {
notifications: _('notifications-screen.title'),
'user-profile': _('user-profile-screen.title'),
preferences: _('preferences-screen.title'),
'warnings-preferences': _('preferences-screen.warnings-title'),
};