From a5c38c6f99f890963247c19cdf8048e364ffac1e Mon Sep 17 00:00:00 2001 From: Loris Janner Date: Thu, 29 Jan 2026 12:06:40 +0100 Subject: [PATCH] fix(wizard): align save button correctly when hideNavigation is true This fixes an edge case where hideNavigation is true and the previous/next buttons are hidden. --- projects/element-ng/wizard/si-wizard.component.html | 1 + .../element-ng/wizard/si-wizard.component.spec.ts | 13 +++++++++++++ 2 files changed, 14 insertions(+) diff --git a/projects/element-ng/wizard/si-wizard.component.html b/projects/element-ng/wizard/si-wizard.component.html index 6f03850f5..467d91312 100644 --- a/projects/element-ng/wizard/si-wizard.component.html +++ b/projects/element-ng/wizard/si-wizard.component.html @@ -172,6 +172,7 @@ { expect(element.querySelector('.wizard-btn-container .back')).toBeFalsy(); expect(element.querySelector('.wizard-btn-container .next')).toBeFalsy(); }); + + it('should align save button to end on last step when navigation is hidden', async () => { + hostComponent.inlineNavigation = false; + await runOnPushChangeDetection(fixture); + + // Navigate to the last step + component.next(hostComponent.steps.length - 1); + await runOnPushChangeDetection(fixture); + + const saveButton = element.querySelector('.btn.save'); + expect(saveButton).toBeTruthy(); + expect(saveButton).toHaveClass('end'); + }); }); describe('navigation buttons in footer', () => {