From b089b0c6c5204b3e1d3cec530b34b5e430090f6a Mon Sep 17 00:00:00 2001 From: Kenrick Tandrian <60643640+KenTandrian@users.noreply.github.com> Date: Wed, 11 Feb 2026 20:26:23 +0000 Subject: [PATCH] feat(lib): destructure parameters --- .../prompt-dialog/prompt-dialog.component.ts | 20 ++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/libs/ui/src/lib/notifications/prompt-dialog/prompt-dialog.component.ts b/libs/ui/src/lib/notifications/prompt-dialog/prompt-dialog.component.ts index aab27847e..2205e235c 100644 --- a/libs/ui/src/lib/notifications/prompt-dialog/prompt-dialog.component.ts +++ b/libs/ui/src/lib/notifications/prompt-dialog/prompt-dialog.component.ts @@ -29,12 +29,18 @@ export class GfPromptDialogComponent { protected readonly dialogRef = inject>(MatDialogRef); - public initialize(aParams: PromptDialogParams) { - this.confirmLabel = aParams.confirmLabel; - this.defaultValue = aParams.defaultValue; - this.discardLabel = aParams.discardLabel; - this.formControl.setValue(aParams.defaultValue ?? null); - this.title = aParams.title; - this.valueLabel = aParams.valueLabel; + public initialize({ + confirmLabel, + defaultValue, + discardLabel, + title, + valueLabel + }: PromptDialogParams) { + this.confirmLabel = confirmLabel; + this.defaultValue = defaultValue; + this.discardLabel = discardLabel; + this.formControl.setValue(defaultValue ?? null); + this.title = title; + this.valueLabel = valueLabel; } }