From a4abb0f458fcefd8641ad768a512de16ae371057 Mon Sep 17 00:00:00 2001 From: glushkova91 Date: Fri, 26 Jan 2024 17:01:08 +0100 Subject: [PATCH] feat: add space-between alignment for dialog actions buttons (#450) Co-authored-by: anastasiia_glushkova --- .../catalyst/src/lib/dialog/dialog-actions.component.scss | 4 ++++ .../catalyst/src/lib/dialog/dialog-actions.component.ts | 5 +++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/angular/projects/catalyst/src/lib/dialog/dialog-actions.component.scss b/angular/projects/catalyst/src/lib/dialog/dialog-actions.component.scss index a616e4d7..099c4c64 100644 --- a/angular/projects/catalyst/src/lib/dialog/dialog-actions.component.scss +++ b/angular/projects/catalyst/src/lib/dialog/dialog-actions.component.scss @@ -5,3 +5,7 @@ .cat-dialog-actions-end { flex-direction: row-reverse; } + +.cat-dialog-actions-space-between { + justify-content: space-between; +} diff --git a/angular/projects/catalyst/src/lib/dialog/dialog-actions.component.ts b/angular/projects/catalyst/src/lib/dialog/dialog-actions.component.ts index 5a85012d..0c69787a 100644 --- a/angular/projects/catalyst/src/lib/dialog/dialog-actions.component.ts +++ b/angular/projects/catalyst/src/lib/dialog/dialog-actions.component.ts @@ -12,12 +12,13 @@ import { ChangeDetectionStrategy, Component, Input, ViewEncapsulation } from '@a host: { class: 'cat-dialog-actions', '[class.cat-dialog-actions-center]': 'align === "center"', - '[class.cat-dialog-actions-end]': 'align === "end"' + '[class.cat-dialog-actions-end]': 'align === "end"', + '[class.cat-dialog-actions-space-between]': 'align === "space-between"' } }) export class CatDialogActionsComponent { /** * Horizontal alignment of action buttons. */ - @Input() align: 'start' | 'center' | 'end' = 'end'; + @Input() align: 'start' | 'center' | 'end' | 'space-between' = 'end'; }