Browse Source

UI: Set stepper label position to bottom

pull/9288/head
Artem Dzhereleiko 3 years ago
parent
commit
29cf6b9704
  1. 2
      ui-ngx/src/app/modules/home/pages/notification/template/template-notification-dialog.component.html
  2. 4
      ui-ngx/src/app/modules/home/pages/notification/template/template-notification-dialog.component.ts

2
ui-ngx/src/app/modules/home/pages/notification/template/template-notification-dialog.component.html

@ -29,7 +29,7 @@
</mat-progress-bar>
<div mat-dialog-content>
<mat-horizontal-stepper linear #notificationTemplateStepper
[labelPosition]="(stepperLabelPosition | async)"
labelPosition="bottom"
[orientation]="(stepperOrientation | async)"
(selectionChange)="changeStep($event)">
<ng-template matStepperIcon="edit">

4
ui-ngx/src/app/modules/home/pages/notification/template/template-notification-dialog.component.ts

@ -54,7 +54,6 @@ export class TemplateNotificationDialogComponent
@ViewChild('notificationTemplateStepper', {static: true}) notificationTemplateStepper: MatStepper;
stepperOrientation: Observable<StepperOrientation>;
stepperLabelPosition: Observable<'bottom' | 'end'>;
dialogTitle = 'notification.edit-notification-template';
@ -82,9 +81,6 @@ export class TemplateNotificationDialogComponent
this.stepperOrientation = this.breakpointObserver.observe(MediaBreakpoints['gt-sm'])
.pipe(map(({matches}) => matches ? 'horizontal' : 'vertical'));
this.stepperLabelPosition = this.breakpointObserver.observe(MediaBreakpoints['gt-md'])
.pipe(map(({matches}) => matches ? 'end' : 'bottom'));
if (isDefinedAndNotNull(this.data?.predefinedType)) {
this.hideSelectType = true;
this.templateNotificationForm.get('notificationType').setValue(this.data.predefinedType, {emitEvent: false});

Loading…
Cancel
Save