From 359090a9a94829f6ecc3afa4ce10c3be38ede021 Mon Sep 17 00:00:00 2001 From: LarisaStar <61147963+Larisa-Staroverova@users.noreply.github.com> Date: Tue, 8 Oct 2024 14:10:07 +0200 Subject: [PATCH 01/20] fix: Rendering of the immediate conflict resolution popover on mobile (#19356) Closes CXSPA-8584 --- .../styles/_configurator-conflict-solver-dialog.scss | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/feature-libs/product-configurator/rulebased/styles/_configurator-conflict-solver-dialog.scss b/feature-libs/product-configurator/rulebased/styles/_configurator-conflict-solver-dialog.scss index 3f77ad35f87..660cd69059d 100644 --- a/feature-libs/product-configurator/rulebased/styles/_configurator-conflict-solver-dialog.scss +++ b/feature-libs/product-configurator/rulebased/styles/_configurator-conflict-solver-dialog.scss @@ -12,7 +12,6 @@ $modal-dialog-margin-sm: 0 !important; .cx-modal-container { - height: auto !important; margin-block-start: 80px; overflow-x: hidden; @@ -33,6 +32,11 @@ } .cx-modal-content { + margin: auto; + @include media-breakpoint-down(sm) { + min-height: 100%; + } + .cx-dialog-header { outline: 0; padding-inline-start: 16px; From 0d6aa2bf86849c05cb9a40dacd446adf552094ea Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Tue, 8 Oct 2024 14:33:32 -0400 Subject: [PATCH 02/20] chore(deps): update dependency jasmine-core to ~5.3.0 (#19347) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Giancarlo Cordero Ortiz <46171897+giancorderoortiz@users.noreply.github.com> --- package-lock.json | 14 +++++++------- package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index d63f1c4438c..82a97512c48 100644 --- a/package-lock.json +++ b/package-lock.json @@ -95,7 +95,7 @@ "http-proxy": "^1.18.1", "http-server": "^14.1.1", "i18n-lint": "^1.1.0", - "jasmine-core": "~5.1.2", + "jasmine-core": "~5.3.0", "jasmine-marbles": "^0.9.2", "jest": "^29.0.0", "jest-circus": "^29.0.0", @@ -15910,9 +15910,9 @@ } }, "node_modules/jasmine-core": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/jasmine-core/-/jasmine-core-5.1.2.tgz", - "integrity": "sha512-2oIUMGn00FdUiqz6epiiJr7xcFyNYj3rDcfmnzfkBnHyBQ3cBQUs4mmyGsOb7TTLb9kxk7dBcmEmqhDKkBoDyA==", + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/jasmine-core/-/jasmine-core-5.3.0.tgz", + "integrity": "sha512-zsOmeBKESky4toybvWEikRiZ0jHoBEu79wNArLfMdSnlLMZx3Xcp6CSm2sUcYyoJC+Uyj8LBJap/MUbVSfJ27g==", "dev": true }, "node_modules/jasmine-marbles": { @@ -35282,9 +35282,9 @@ } }, "jasmine-core": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/jasmine-core/-/jasmine-core-5.1.2.tgz", - "integrity": "sha512-2oIUMGn00FdUiqz6epiiJr7xcFyNYj3rDcfmnzfkBnHyBQ3cBQUs4mmyGsOb7TTLb9kxk7dBcmEmqhDKkBoDyA==", + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/jasmine-core/-/jasmine-core-5.3.0.tgz", + "integrity": "sha512-zsOmeBKESky4toybvWEikRiZ0jHoBEu79wNArLfMdSnlLMZx3Xcp6CSm2sUcYyoJC+Uyj8LBJap/MUbVSfJ27g==", "dev": true }, "jasmine-marbles": { diff --git a/package.json b/package.json index 6fc3e9599a3..0e1b3d8ef54 100644 --- a/package.json +++ b/package.json @@ -206,7 +206,7 @@ "http-proxy": "^1.18.1", "http-server": "^14.1.1", "i18n-lint": "^1.1.0", - "jasmine-core": "~5.1.2", + "jasmine-core": "~5.3.0", "jasmine-marbles": "^0.9.2", "jest": "^29.0.0", "jest-circus": "^29.0.0", From 1e58a6a8f6d1a1c92ebe40ec91895866db41f163 Mon Sep 17 00:00:00 2001 From: LarisaStar <61147963+Larisa-Staroverova@users.noreply.github.com> Date: Wed, 9 Oct 2024 12:47:41 +0200 Subject: [PATCH 03/20] fix: Focus after clicking on hamburger menu (#19366) Closes CXSPA-8585 --- projects/storefrontlib/layout/main/storefront.component.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/projects/storefrontlib/layout/main/storefront.component.ts b/projects/storefrontlib/layout/main/storefront.component.ts index e2943ef9967..8bd99b7b6ae 100644 --- a/projects/storefrontlib/layout/main/storefront.component.ts +++ b/projects/storefrontlib/layout/main/storefront.component.ts @@ -120,8 +120,9 @@ export class StorefrontComponent implements OnInit, OnDestroy { } protected focusOnFirstNavigationItem() { - const closestNavigationUi = - this.elementRef.nativeElement.querySelector('cx-navigation-ui'); + const closestNavigationUi = this.elementRef.nativeElement.querySelector( + 'header cx-navigation-ui' + ); const focusable = closestNavigationUi?.querySelector( 'li:not(.back) button, [tabindex="0"]' ); From 819b63bde0d0340bfb0dfa20f87613f1c16c1874 Mon Sep 17 00:00:00 2001 From: Krzysztof Platis Date: Wed, 9 Oct 2024 13:53:20 +0200 Subject: [PATCH 04/20] chore: remove TODO comment related to CXSPA-6793, as won't fix (#19368) We won't change the syntax to use to `satisfies` keyword Reason: - in case of a missing property, the error message is more readable currently. See screenshots below CURRENTLY: ![image](https://github.com/user-attachments/assets/0d9a792f-e946-417b-9801-ee7e02817bae) IF WE USED `satisfies` keyword: ![image](https://github.com/user-attachments/assets/9f87b0fe-9365-4658-90ef-13b7f58d829a) - moreover, if we changed the syntax from `provideFeatureTogglesFactory` to `provideFeatureToggles`, it would change the indentation for all lines with toggles, which is prone to code conflicts with other pending branches ![image](https://github.com/user-attachments/assets/b17c06b4-c6d4-4825-a620-95b556f6df33) All that said, I don't find it justified to refactor it to use `satisfies` keyword, therefore removing the TODO comment as won't fix closes https://jira.tools.sap/browse/CXSPA-6793 --- .../storefrontapp/src/app/spartacus/spartacus-features.module.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/projects/storefrontapp/src/app/spartacus/spartacus-features.module.ts b/projects/storefrontapp/src/app/spartacus/spartacus-features.module.ts index 844c1b5547d..b2749c81b2a 100644 --- a/projects/storefrontapp/src/app/spartacus/spartacus-features.module.ts +++ b/projects/storefrontapp/src/app/spartacus/spartacus-features.module.ts @@ -282,7 +282,6 @@ if (environment.cpq) { provide: USE_MY_ACCOUNT_V2_NOTIFICATION_PREFERENCE, useValue: environment.myAccountV2, }, - // CXSPA-6793: refactor to`provideFeatureToggles` and `satisfies` keyword provideFeatureTogglesFactory(() => { const appFeatureToggles: Required = { showDeliveryOptionsTranslation: true, From a9e47868f3a1a00e1454bdae95921301a6a0531e Mon Sep 17 00:00:00 2001 From: Roman <129765378+rmch91@users.noreply.github.com> Date: Wed, 9 Oct 2024 15:55:59 +0200 Subject: [PATCH 05/20] Release 2211.29.1 (#19373) --- core-libs/setup/package.json | 10 +- feature-libs/asm/package.json | 18 +- feature-libs/cart/package.json | 12 +- feature-libs/checkout/package.json | 16 +- feature-libs/customer-ticketing/package.json | 12 +- .../estimated-delivery-date/package.json | 14 +- feature-libs/order/package.json | 16 +- feature-libs/organization/package.json | 16 +- feature-libs/pdf-invoices/package.json | 10 +- feature-libs/pickup-in-store/package.json | 18 +- .../product-configurator/package.json | 16 +- .../product-multi-dimensional/package.json | 10 +- feature-libs/product/package.json | 10 +- feature-libs/qualtrics/package.json | 8 +- feature-libs/quote/package.json | 12 +- .../requested-delivery-date/package.json | 16 +- feature-libs/smartedit/package.json | 6 +- feature-libs/storefinder/package.json | 10 +- feature-libs/tracking/package.json | 6 +- feature-libs/user/package.json | 10 +- integration-libs/cdc/package.json | 14 +- integration-libs/cdp/package.json | 6 +- integration-libs/cds/package.json | 14 +- integration-libs/cpq-quote/package.json | 10 +- .../digital-payments/package.json | 12 +- .../epd-visualization/package.json | 12 +- integration-libs/omf/package.json | 8 +- integration-libs/opps/package.json | 8 +- integration-libs/s4-service/package.json | 14 +- integration-libs/s4om/package.json | 16 +- integration-libs/segment-refs/package.json | 6 +- projects/assets/package.json | 2 +- projects/core/package.json | 2 +- projects/schematics/package.json | 2 +- projects/schematics/src/dependencies.json | 308 +++++++++--------- .../ng-add/__snapshots__/index_spec.ts.snap | 10 +- projects/ssr-tests/package.json | 4 +- projects/storefrontlib/package.json | 4 +- projects/storefrontstyles/package.json | 2 +- .../storefrontstyles/scss/_versioning.scss | 2 +- tools/config/const.ts | 2 +- 41 files changed, 352 insertions(+), 352 deletions(-) diff --git a/core-libs/setup/package.json b/core-libs/setup/package.json index de48148ca93..84a5eeffcdf 100644 --- a/core-libs/setup/package.json +++ b/core-libs/setup/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/setup", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Includes features that makes Spartacus and it's setup easier and streamlined.", "keywords": [ "spartacus", @@ -21,10 +21,10 @@ "peerDependencies": { "@angular/core": "^17.0.5", "@angular/ssr": "^17.0.5", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/user": "2211.29.0" + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/user": "2211.29.1" }, "optionalDependencies": { "@angular/platform-server": "^17.0.5", diff --git a/feature-libs/asm/package.json b/feature-libs/asm/package.json index 605268eff92..9574a9aa1e4 100644 --- a/feature-libs/asm/package.json +++ b/feature-libs/asm/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/asm", - "version": "2211.29.0", + "version": "2211.29.1", "description": "ASM feature library for Spartacus", "keywords": [ "spartacus", @@ -32,14 +32,14 @@ "@ng-select/ng-select": "^12.0.4", "@ngrx/effects": "^17.0.1", "@ngrx/store": "^17.0.1", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefinder": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", - "@spartacus/user": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefinder": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", + "@spartacus/user": "2211.29.1", "rxjs": "^7.8.0" }, "publishConfig": { diff --git a/feature-libs/cart/package.json b/feature-libs/cart/package.json index 8e5caa530c0..7412f1aa97d 100644 --- a/feature-libs/cart/package.json +++ b/feature-libs/cart/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/cart", - "version": "2211.29.0", + "version": "2211.29.1", "description": "", "keywords": [ "spartacus", @@ -37,11 +37,11 @@ "@ng-select/ng-select": "^12.0.4", "@ngrx/effects": "^17.0.1", "@ngrx/store": "^17.0.1", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", - "@spartacus/user": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", + "@spartacus/user": "2211.29.1", "bootstrap": "^4.6.2", "rxjs": "^7.8.0" }, diff --git a/feature-libs/checkout/package.json b/feature-libs/checkout/package.json index 01d6895b6f4..9daf3db9284 100644 --- a/feature-libs/checkout/package.json +++ b/feature-libs/checkout/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/checkout", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Checkout feature library for Spartacus", "keywords": [ "spartacus", @@ -32,13 +32,13 @@ "@angular/router": "^17.0.5", "@ng-select/ng-select": "^12.0.4", "@ngrx/store": "^17.0.1", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", - "@spartacus/user": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", + "@spartacus/user": "2211.29.1", "bootstrap": "^4.6.2", "rxjs": "^7.8.0" }, diff --git a/feature-libs/customer-ticketing/package.json b/feature-libs/customer-ticketing/package.json index 4acd04b0509..33e486a7fb7 100644 --- a/feature-libs/customer-ticketing/package.json +++ b/feature-libs/customer-ticketing/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/customer-ticketing", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Customer-Ticketing library for Spartacus", "keywords": [ "spartacus", @@ -30,11 +30,11 @@ "@angular/core": "^17.0.5", "@angular/forms": "^17.0.5", "@angular/router": "^17.0.5", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "rxjs": "^7.8.0" }, "publishConfig": { diff --git a/feature-libs/estimated-delivery-date/package.json b/feature-libs/estimated-delivery-date/package.json index e919c30b847..e18895481f0 100644 --- a/feature-libs/estimated-delivery-date/package.json +++ b/feature-libs/estimated-delivery-date/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/estimated-delivery-date", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Estimated Delivery Date library for Spartacus", "keywords": [ "spartacus", @@ -28,12 +28,12 @@ "@angular-devkit/schematics": "^17.0.5", "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "rxjs": "^7.8.0" }, "publishConfig": { diff --git a/feature-libs/order/package.json b/feature-libs/order/package.json index 945f2a3defa..8798cb04477 100644 --- a/feature-libs/order/package.json +++ b/feature-libs/order/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/order", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Order feature library for Spartacus", "keywords": [ "spartacus", @@ -33,13 +33,13 @@ "@ng-select/ng-select": "^12.0.4", "@ngrx/effects": "^17.0.1", "@ngrx/store": "^17.0.1", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/pdf-invoices": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", - "@spartacus/user": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/pdf-invoices": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", + "@spartacus/user": "2211.29.1", "rxjs": "^7.8.0" }, "publishConfig": { diff --git a/feature-libs/organization/package.json b/feature-libs/organization/package.json index f2cccd5641a..7387a6f25f7 100644 --- a/feature-libs/organization/package.json +++ b/feature-libs/organization/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/organization", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Organization library for Spartacus", "keywords": [ "spartacus", @@ -33,13 +33,13 @@ "@ng-select/ng-select": "^12.0.4", "@ngrx/effects": "^17.0.1", "@ngrx/store": "^17.0.1", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", - "@spartacus/user": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", + "@spartacus/user": "2211.29.1", "bootstrap": "^4.6.2", "rxjs": "^7.8.0" }, diff --git a/feature-libs/pdf-invoices/package.json b/feature-libs/pdf-invoices/package.json index ba47f3dd487..c944f8991a0 100644 --- a/feature-libs/pdf-invoices/package.json +++ b/feature-libs/pdf-invoices/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/pdf-invoices", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Invoices library for Spartacus", "keywords": [ "spartacus", @@ -29,10 +29,10 @@ "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", "@angular/forms": "^17.0.5", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "rxjs": "^7.8.0" }, "publishConfig": { diff --git a/feature-libs/pickup-in-store/package.json b/feature-libs/pickup-in-store/package.json index 59da5814b13..38d9a4f5de3 100644 --- a/feature-libs/pickup-in-store/package.json +++ b/feature-libs/pickup-in-store/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/pickup-in-store", - "version": "2211.29.0", + "version": "2211.29.1", "description": "", "keywords": [ "spartacus", @@ -32,14 +32,14 @@ "@angular/router": "^17.0.5", "@ngrx/effects": "^17.0.1", "@ngrx/store": "^17.0.1", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefinder": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", - "@spartacus/user": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefinder": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", + "@spartacus/user": "2211.29.1", "bootstrap": "^4.6.2", "rxjs": "^7.8.0" }, diff --git a/feature-libs/product-configurator/package.json b/feature-libs/product-configurator/package.json index 0d38d0e9a38..08be7486e2b 100644 --- a/feature-libs/product-configurator/package.json +++ b/feature-libs/product-configurator/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/product-configurator", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Product configurator feature library for Spartacus", "keywords": [ "spartacus", @@ -33,13 +33,13 @@ "@ng-select/ng-select": "^12.0.4", "@ngrx/effects": "^17.0.1", "@ngrx/store": "^17.0.1", - "@spartacus/cart": "2211.29.0", - "@spartacus/checkout": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/checkout": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "rxjs": "^7.8.0" }, "publishConfig": { diff --git a/feature-libs/product-multi-dimensional/package.json b/feature-libs/product-multi-dimensional/package.json index 259a73d89ba..5dc40ed7785 100644 --- a/feature-libs/product-multi-dimensional/package.json +++ b/feature-libs/product-multi-dimensional/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/product-multi-dimensional", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Product Multi-Dimensional library for Spartacus", "keywords": [ "spartacus", @@ -31,10 +31,10 @@ "@angular/forms": "^17.0.5", "@angular/router": "^17.0.5", "@ng-select/ng-select": "^12.0.4", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "bootstrap": "^4.6.2", "rxjs": "^7.8.0" }, diff --git a/feature-libs/product/package.json b/feature-libs/product/package.json index 368e16cdfcb..70305724696 100644 --- a/feature-libs/product/package.json +++ b/feature-libs/product/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/product", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Product library for Spartacus", "keywords": [ "spartacus", @@ -29,10 +29,10 @@ "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", "@angular/router": "^17.0.5", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "bootstrap": "^4.6.2", "rxjs": "^7.8.0" }, diff --git a/feature-libs/qualtrics/package.json b/feature-libs/qualtrics/package.json index 29824ad93b4..a90c743abd5 100644 --- a/feature-libs/qualtrics/package.json +++ b/feature-libs/qualtrics/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/qualtrics", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Qualtrics library for Spartacus", "keywords": [ "spartacus", @@ -30,9 +30,9 @@ "@angular-devkit/schematics": "^17.0.5", "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/styles": "2211.29.1", "bootstrap": "^4.6.2", "rxjs": "^7.8.0" }, diff --git a/feature-libs/quote/package.json b/feature-libs/quote/package.json index 4977955d6c9..5725d7cbc0c 100644 --- a/feature-libs/quote/package.json +++ b/feature-libs/quote/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/quote", - "version": "2211.29.0", + "version": "2211.29.1", "description": "", "keywords": [ "spartacus", @@ -32,11 +32,11 @@ "@angular/core": "^17.0.5", "@angular/forms": "^17.0.5", "@angular/router": "^17.0.5", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "bootstrap": "^4.6.2", "rxjs": "^7.8.0" }, diff --git a/feature-libs/requested-delivery-date/package.json b/feature-libs/requested-delivery-date/package.json index 650dd95c562..3e2fd60c675 100644 --- a/feature-libs/requested-delivery-date/package.json +++ b/feature-libs/requested-delivery-date/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/requested-delivery-date", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Requested Delivery Date library for Spartacus", "keywords": [ "spartacus", @@ -29,13 +29,13 @@ "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", "@angular/forms": "^17.0.5", - "@spartacus/cart": "2211.29.0", - "@spartacus/checkout": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/checkout": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "rxjs": "^7.8.0" }, "publishConfig": { diff --git a/feature-libs/smartedit/package.json b/feature-libs/smartedit/package.json index 9c1c3fd7962..700b3d7e530 100644 --- a/feature-libs/smartedit/package.json +++ b/feature-libs/smartedit/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/smartedit", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Smart Edit feature library for Spartacus", "keywords": [ "spartacus", @@ -23,8 +23,8 @@ "@angular-devkit/schematics": "^17.0.5", "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", "rxjs": "^7.8.0" }, "publishConfig": { diff --git a/feature-libs/storefinder/package.json b/feature-libs/storefinder/package.json index 63d716548f2..5bdb1a11614 100644 --- a/feature-libs/storefinder/package.json +++ b/feature-libs/storefinder/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/storefinder", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Store finder feature library for Spartacus", "keywords": [ "spartacus", @@ -32,10 +32,10 @@ "@angular/router": "^17.0.5", "@ngrx/effects": "^17.0.1", "@ngrx/store": "^17.0.1", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "bootstrap": "^4.6.2", "rxjs": "^7.8.0" }, diff --git a/feature-libs/tracking/package.json b/feature-libs/tracking/package.json index e69a9742256..49ce9e3e51b 100644 --- a/feature-libs/tracking/package.json +++ b/feature-libs/tracking/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/tracking", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Spartacus tracking and personalization library", "keywords": [ "spartacus", @@ -27,8 +27,8 @@ "@angular-devkit/schematics": "^17.0.5", "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", "rxjs": "^7.8.0" }, "publishConfig": { diff --git a/feature-libs/user/package.json b/feature-libs/user/package.json index 476e93b9030..aa226b3215c 100644 --- a/feature-libs/user/package.json +++ b/feature-libs/user/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/user", - "version": "2211.29.0", + "version": "2211.29.1", "description": "User feature library for Spartacus", "keywords": [ "spartacus", @@ -32,10 +32,10 @@ "@angular/router": "^17.0.5", "@ng-select/ng-select": "^12.0.4", "@ngrx/store": "^17.0.1", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "rxjs": "^7.8.0" }, "publishConfig": { diff --git a/integration-libs/cdc/package.json b/integration-libs/cdc/package.json index 02e5319b625..92139f86605 100644 --- a/integration-libs/cdc/package.json +++ b/integration-libs/cdc/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/cdc", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Customer Data Cloud Integration library for Spartacus", "keywords": [ "spartacus", @@ -30,12 +30,12 @@ "@ng-select/ng-select": "^12.0.4", "@ngrx/effects": "^17.0.1", "@ngrx/store": "^17.0.1", - "@spartacus/asm": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/organization": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/user": "2211.29.0", + "@spartacus/asm": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/organization": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/user": "2211.29.1", "rxjs": "^7.8.0" }, "publishConfig": { diff --git a/integration-libs/cdp/package.json b/integration-libs/cdp/package.json index 5803769c7ad..2102d08b5e8 100644 --- a/integration-libs/cdp/package.json +++ b/integration-libs/cdp/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/cdp", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Customer Data Platform Integration library for Spartacus", "keywords": [ "spartacus", @@ -24,8 +24,8 @@ "peerDependencies": { "@angular-devkit/schematics": "^17.0.5", "@angular/core": "^17.0.5", - "@spartacus/customer-ticketing": "2211.29.0", - "@spartacus/schematics": "2211.29.0", + "@spartacus/customer-ticketing": "2211.29.1", + "@spartacus/schematics": "2211.29.1", "rxjs": "^7.8.0" }, "publishConfig": { diff --git a/integration-libs/cds/package.json b/integration-libs/cds/package.json index 9c665e5fd8b..cc49d52b7ea 100644 --- a/integration-libs/cds/package.json +++ b/integration-libs/cds/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/cds", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Context Driven Service library for Spartacus", "keywords": [ "spartacus", @@ -28,12 +28,12 @@ "@angular/core": "^17.0.5", "@angular/router": "^17.0.5", "@ngrx/store": "^17.0.1", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/tracking": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/tracking": "2211.29.1", "rxjs": "^7.8.0" }, "publishConfig": { diff --git a/integration-libs/cpq-quote/package.json b/integration-libs/cpq-quote/package.json index 2b9ff57201e..c628fcd0b1a 100644 --- a/integration-libs/cpq-quote/package.json +++ b/integration-libs/cpq-quote/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/cpq-quote", - "version": "2211.29.0", + "version": "2211.29.1", "description": "cpq-quote library for Spartacus", "keywords": [ "spartacus", @@ -23,10 +23,10 @@ "@angular-devkit/schematics": "^17.0.5", "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", "rxjs": "^7.8.0" }, "publishConfig": { diff --git a/integration-libs/digital-payments/package.json b/integration-libs/digital-payments/package.json index d9f255949a7..8c1bd91d4b0 100644 --- a/integration-libs/digital-payments/package.json +++ b/integration-libs/digital-payments/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/digital-payments", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Digital Payments Integration library for Spartacus", "keywords": [ "spartacus", @@ -27,11 +27,11 @@ "@angular/forms": "^17.0.5", "@angular/router": "^17.0.5", "@ng-select/ng-select": "^12.0.4", - "@spartacus/cart": "2211.29.0", - "@spartacus/checkout": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/checkout": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", "rxjs": "^7.8.0" }, "publishConfig": { diff --git a/integration-libs/epd-visualization/package.json b/integration-libs/epd-visualization/package.json index 025ee26a24c..51124069129 100644 --- a/integration-libs/epd-visualization/package.json +++ b/integration-libs/epd-visualization/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/epd-visualization", - "version": "2211.29.0", + "version": "2211.29.1", "description": "SAP Enterprise Product Development Visualization integration library for Spartacus", "keywords": [ "spartacus", @@ -38,11 +38,11 @@ "@angular/forms": "^17.0.5", "@angular/router": "^17.0.5", "@sapui5/ts-types-esm": "1.120.1", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "bootstrap": "^4.6.2", "rxjs": "^7.8.0" }, diff --git a/integration-libs/omf/package.json b/integration-libs/omf/package.json index 8ad6a609d64..e4cae34f97e 100644 --- a/integration-libs/omf/package.json +++ b/integration-libs/omf/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/omf", - "version": "2211.29.0", + "version": "2211.29.1", "description": "SAP Order Management Foundation Integration", "keywords": [ "spartacus", @@ -25,9 +25,9 @@ "@angular/core": "^17.0.5", "@angular/router": "^17.0.5", "@ngrx/store": "^17.0.1", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/schematics": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/schematics": "2211.29.1", "rxjs": "^7.8.0" }, "publishConfig": { diff --git a/integration-libs/opps/package.json b/integration-libs/opps/package.json index 8987bc5b570..d19199d912b 100644 --- a/integration-libs/opps/package.json +++ b/integration-libs/opps/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/opps", - "version": "2211.29.0", + "version": "2211.29.1", "description": "OPPS (Omni-Channel Personalization and Promotions Services) library for Spartacus", "keywords": [ "spartacus", @@ -29,9 +29,9 @@ "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", "@angular/router": "^17.0.5", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", "rxjs": "^7.8.0" }, "publishConfig": { diff --git a/integration-libs/s4-service/package.json b/integration-libs/s4-service/package.json index 381838a54b1..376c375248f 100644 --- a/integration-libs/s4-service/package.json +++ b/integration-libs/s4-service/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/s4-service", - "version": "2211.29.0", + "version": "2211.29.1", "description": "S/4HANA Service Integration Integration library for Spartacus", "keywords": [ "spartacus", @@ -30,12 +30,12 @@ "@angular/core": "^17.0.5", "@angular/forms": "^17.0.5", "@angular/router": "^17.0.5", - "@spartacus/cart": "2211.29.0", - "@spartacus/checkout": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/checkout": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", "rxjs": "^7.8.0" }, "publishConfig": { diff --git a/integration-libs/s4om/package.json b/integration-libs/s4om/package.json index 92b5ad2a15d..5e01beb5e25 100644 --- a/integration-libs/s4om/package.json +++ b/integration-libs/s4om/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/s4om", - "version": "2211.29.0", + "version": "2211.29.1", "description": "S/4HANA Order Management (b2b feature)", "keywords": [ "spartacus", @@ -23,13 +23,13 @@ "@angular-devkit/schematics": "^17.0.5", "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/pdf-invoices": "2211.29.0", - "@spartacus/requested-delivery-date": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/pdf-invoices": "2211.29.1", + "@spartacus/requested-delivery-date": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "rxjs": "^7.8.0" }, "publishConfig": { diff --git a/integration-libs/segment-refs/package.json b/integration-libs/segment-refs/package.json index 40a0e061878..be446060655 100644 --- a/integration-libs/segment-refs/package.json +++ b/integration-libs/segment-refs/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/segment-refs", - "version": "2211.29.0", + "version": "2211.29.1", "description": "segment-refs", "keywords": [ "spartacus", @@ -23,8 +23,8 @@ "@angular-devkit/schematics": "^17.0.5", "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", "rxjs": "^7.8.0" }, "publishConfig": { diff --git a/projects/assets/package.json b/projects/assets/package.json index f8c128303a7..f305c9b8a34 100644 --- a/projects/assets/package.json +++ b/projects/assets/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/assets", - "version": "2211.29.0", + "version": "2211.29.1", "homepage": "https://github.com/SAP/spartacus", "repository": "https://github.com/SAP/spartacus/tree/develop/projects/assets", "scripts": { diff --git a/projects/core/package.json b/projects/core/package.json index f0df8903de1..06a8bb87bf1 100644 --- a/projects/core/package.json +++ b/projects/core/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/core", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Spartacus - the core framework", "keywords": [ "spartacus", diff --git a/projects/schematics/package.json b/projects/schematics/package.json index c77743c60dd..dfc969ecb34 100644 --- a/projects/schematics/package.json +++ b/projects/schematics/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/schematics", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Spartacus schematics", "keywords": [ "spartacus", diff --git a/projects/schematics/src/dependencies.json b/projects/schematics/src/dependencies.json index d919a386cfb..614651107a5 100644 --- a/projects/schematics/src/dependencies.json +++ b/projects/schematics/src/dependencies.json @@ -24,7 +24,7 @@ "typescript": "^5.2.2" }, "ssr-tests": { - "@spartacus/core": "2211.29.0", + "@spartacus/core": "2211.29.1", "http-proxy": "^1.18.1", "jest-circus": "^29.0.0", "jest-environment-node": "^29.0.0" @@ -41,7 +41,7 @@ "@ngrx/effects": "^17.0.1", "@ngrx/router-store": "^17.0.1", "@ngrx/store": "^17.0.1", - "@spartacus/core": "2211.29.0", + "@spartacus/core": "2211.29.1", "ngx-infinite-scroll": "^17.0.0", "rxjs": "^7.8.0" }, @@ -54,10 +54,10 @@ "@spartacus/setup": { "@angular/core": "^17.0.5", "@angular/ssr": "^17.0.5", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/user": "2211.29.0" + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/user": "2211.29.1" }, "@spartacus/asm": { "@angular-devkit/schematics": "^17.0.5", @@ -67,14 +67,14 @@ "@ng-select/ng-select": "^12.0.4", "@ngrx/effects": "^17.0.1", "@ngrx/store": "^17.0.1", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefinder": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", - "@spartacus/user": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefinder": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", + "@spartacus/user": "2211.29.1", "rxjs": "^7.8.0" }, "@spartacus/cart": { @@ -86,11 +86,11 @@ "@ng-select/ng-select": "^12.0.4", "@ngrx/effects": "^17.0.1", "@ngrx/store": "^17.0.1", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", - "@spartacus/user": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", + "@spartacus/user": "2211.29.1", "bootstrap": "^4.6.2", "rxjs": "^7.8.0" }, @@ -102,13 +102,13 @@ "@angular/router": "^17.0.5", "@ng-select/ng-select": "^12.0.4", "@ngrx/store": "^17.0.1", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", - "@spartacus/user": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", + "@spartacus/user": "2211.29.1", "bootstrap": "^4.6.2", "rxjs": "^7.8.0" }, @@ -118,23 +118,23 @@ "@angular/core": "^17.0.5", "@angular/forms": "^17.0.5", "@angular/router": "^17.0.5", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "rxjs": "^7.8.0" }, "@spartacus/estimated-delivery-date": { "@angular-devkit/schematics": "^17.0.5", "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "rxjs": "^7.8.0" }, "@spartacus/order": { @@ -146,13 +146,13 @@ "@ng-select/ng-select": "^12.0.4", "@ngrx/effects": "^17.0.1", "@ngrx/store": "^17.0.1", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/pdf-invoices": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", - "@spartacus/user": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/pdf-invoices": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", + "@spartacus/user": "2211.29.1", "rxjs": "^7.8.0" }, "@spartacus/organization": { @@ -164,13 +164,13 @@ "@ng-select/ng-select": "^12.0.4", "@ngrx/effects": "^17.0.1", "@ngrx/store": "^17.0.1", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", - "@spartacus/user": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", + "@spartacus/user": "2211.29.1", "bootstrap": "^4.6.2", "rxjs": "^7.8.0" }, @@ -179,10 +179,10 @@ "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", "@angular/forms": "^17.0.5", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "rxjs": "^7.8.0" }, "@spartacus/pickup-in-store": { @@ -193,14 +193,14 @@ "@angular/router": "^17.0.5", "@ngrx/effects": "^17.0.1", "@ngrx/store": "^17.0.1", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefinder": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", - "@spartacus/user": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefinder": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", + "@spartacus/user": "2211.29.1", "bootstrap": "^4.6.2", "rxjs": "^7.8.0" }, @@ -209,10 +209,10 @@ "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", "@angular/router": "^17.0.5", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "bootstrap": "^4.6.2", "rxjs": "^7.8.0" }, @@ -225,13 +225,13 @@ "@ng-select/ng-select": "^12.0.4", "@ngrx/effects": "^17.0.1", "@ngrx/store": "^17.0.1", - "@spartacus/cart": "2211.29.0", - "@spartacus/checkout": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/checkout": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "rxjs": "^7.8.0" }, "@spartacus/product-multi-dimensional": { @@ -241,10 +241,10 @@ "@angular/forms": "^17.0.5", "@angular/router": "^17.0.5", "@ng-select/ng-select": "^12.0.4", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "bootstrap": "^4.6.2", "rxjs": "^7.8.0" }, @@ -252,9 +252,9 @@ "@angular-devkit/schematics": "^17.0.5", "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/styles": "2211.29.1", "bootstrap": "^4.6.2", "rxjs": "^7.8.0" }, @@ -264,11 +264,11 @@ "@angular/core": "^17.0.5", "@angular/forms": "^17.0.5", "@angular/router": "^17.0.5", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "bootstrap": "^4.6.2", "rxjs": "^7.8.0" }, @@ -277,21 +277,21 @@ "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", "@angular/forms": "^17.0.5", - "@spartacus/cart": "2211.29.0", - "@spartacus/checkout": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/checkout": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "rxjs": "^7.8.0" }, "@spartacus/smartedit": { "@angular-devkit/schematics": "^17.0.5", "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", "rxjs": "^7.8.0" }, "@spartacus/storefinder": { @@ -302,10 +302,10 @@ "@angular/router": "^17.0.5", "@ngrx/effects": "^17.0.1", "@ngrx/store": "^17.0.1", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "bootstrap": "^4.6.2", "rxjs": "^7.8.0" }, @@ -313,8 +313,8 @@ "@angular-devkit/schematics": "^17.0.5", "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", "rxjs": "^7.8.0" }, "@spartacus/user": { @@ -325,10 +325,10 @@ "@angular/router": "^17.0.5", "@ng-select/ng-select": "^12.0.4", "@ngrx/store": "^17.0.1", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "rxjs": "^7.8.0" }, "@spartacus/cdc": { @@ -340,19 +340,19 @@ "@ng-select/ng-select": "^12.0.4", "@ngrx/effects": "^17.0.1", "@ngrx/store": "^17.0.1", - "@spartacus/asm": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/organization": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/user": "2211.29.0", + "@spartacus/asm": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/organization": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/user": "2211.29.1", "rxjs": "^7.8.0" }, "@spartacus/cdp": { "@angular-devkit/schematics": "^17.0.5", "@angular/core": "^17.0.5", - "@spartacus/customer-ticketing": "2211.29.0", - "@spartacus/schematics": "2211.29.0", + "@spartacus/customer-ticketing": "2211.29.1", + "@spartacus/schematics": "2211.29.1", "rxjs": "^7.8.0" }, "@spartacus/cds": { @@ -361,22 +361,22 @@ "@angular/core": "^17.0.5", "@angular/router": "^17.0.5", "@ngrx/store": "^17.0.1", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/tracking": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/tracking": "2211.29.1", "rxjs": "^7.8.0" }, "@spartacus/cpq-quote": { "@angular-devkit/schematics": "^17.0.5", "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", "rxjs": "^7.8.0" }, "@spartacus/digital-payments": { @@ -386,11 +386,11 @@ "@angular/forms": "^17.0.5", "@angular/router": "^17.0.5", "@ng-select/ng-select": "^12.0.4", - "@spartacus/cart": "2211.29.0", - "@spartacus/checkout": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/checkout": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", "rxjs": "^7.8.0" }, "@spartacus/epd-visualization": { @@ -400,11 +400,11 @@ "@angular/forms": "^17.0.5", "@angular/router": "^17.0.5", "@sapui5/ts-types-esm": "1.120.1", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "bootstrap": "^4.6.2", "rxjs": "^7.8.0" }, @@ -414,9 +414,9 @@ "@angular/core": "^17.0.5", "@angular/router": "^17.0.5", "@ngrx/store": "^17.0.1", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/schematics": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/schematics": "2211.29.1", "rxjs": "^7.8.0" }, "@spartacus/opps": { @@ -424,9 +424,9 @@ "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", "@angular/router": "^17.0.5", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", "rxjs": "^7.8.0" }, "@spartacus/s4-service": { @@ -435,33 +435,33 @@ "@angular/core": "^17.0.5", "@angular/forms": "^17.0.5", "@angular/router": "^17.0.5", - "@spartacus/cart": "2211.29.0", - "@spartacus/checkout": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/order": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/checkout": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/order": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", "rxjs": "^7.8.0" }, "@spartacus/s4om": { "@angular-devkit/schematics": "^17.0.5", "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", - "@spartacus/cart": "2211.29.0", - "@spartacus/core": "2211.29.0", - "@spartacus/pdf-invoices": "2211.29.0", - "@spartacus/requested-delivery-date": "2211.29.0", - "@spartacus/schematics": "2211.29.0", - "@spartacus/storefront": "2211.29.0", - "@spartacus/styles": "2211.29.0", + "@spartacus/cart": "2211.29.1", + "@spartacus/core": "2211.29.1", + "@spartacus/pdf-invoices": "2211.29.1", + "@spartacus/requested-delivery-date": "2211.29.1", + "@spartacus/schematics": "2211.29.1", + "@spartacus/storefront": "2211.29.1", + "@spartacus/styles": "2211.29.1", "rxjs": "^7.8.0" }, "@spartacus/segment-refs": { "@angular-devkit/schematics": "^17.0.5", "@angular/common": "^17.0.5", "@angular/core": "^17.0.5", - "@spartacus/core": "2211.29.0", - "@spartacus/schematics": "2211.29.0", + "@spartacus/core": "2211.29.1", + "@spartacus/schematics": "2211.29.1", "rxjs": "^7.8.0" }, "storefrontapp": { diff --git a/projects/schematics/src/ng-add/__snapshots__/index_spec.ts.snap b/projects/schematics/src/ng-add/__snapshots__/index_spec.ts.snap index 588a6ef5af5..9769602d7d1 100644 --- a/projects/schematics/src/ng-add/__snapshots__/index_spec.ts.snap +++ b/projects/schematics/src/ng-add/__snapshots__/index_spec.ts.snap @@ -61,11 +61,11 @@ exports[`Spartacus Schematics: ng-add should add spartacus properly with SSR 2`] "@ngrx/effects": "^17.0.1", "@ngrx/router-store": "^17.0.1", "@ngrx/store": "^17.0.1", - "@spartacus/assets": "~2211.29.0", - "@spartacus/core": "~2211.29.0", - "@spartacus/setup": "~2211.29.0", - "@spartacus/storefront": "~2211.29.0", - "@spartacus/styles": "~2211.29.0", + "@spartacus/assets": "~2211.29.1", + "@spartacus/core": "~2211.29.1", + "@spartacus/setup": "~2211.29.1", + "@spartacus/storefront": "~2211.29.1", + "@spartacus/styles": "~2211.29.1", "angular-oauth2-oidc": "^17.0.1", "bootstrap": "^4.6.2", "express": "^4.18.2", diff --git a/projects/ssr-tests/package.json b/projects/ssr-tests/package.json index f075dbed63b..2ae4e1825d2 100644 --- a/projects/ssr-tests/package.json +++ b/projects/ssr-tests/package.json @@ -1,6 +1,6 @@ { "name": "ssr-tests", - "version": "2211.29.0", + "version": "2211.29.1", "private": true, "description": "Spartacus SSR Tests", "keywords": [ @@ -17,7 +17,7 @@ "tslib": "^2.6.2" }, "peerDependencies": { - "@spartacus/core": "2211.29.0", + "@spartacus/core": "2211.29.1", "http-proxy": "^1.18.1", "jest-circus": "^29.0.0", "jest-environment-node": "^29.0.0" diff --git a/projects/storefrontlib/package.json b/projects/storefrontlib/package.json index 45042df6861..0e0bd6cd460 100644 --- a/projects/storefrontlib/package.json +++ b/projects/storefrontlib/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/storefront", - "version": "2211.29.0", + "version": "2211.29.1", "keywords": [ "spartacus", "storefront", @@ -23,7 +23,7 @@ "@ngrx/effects": "^17.0.1", "@ngrx/router-store": "^17.0.1", "@ngrx/store": "^17.0.1", - "@spartacus/core": "2211.29.0", + "@spartacus/core": "2211.29.1", "ngx-infinite-scroll": "^17.0.0", "rxjs": "^7.8.0" }, diff --git a/projects/storefrontstyles/package.json b/projects/storefrontstyles/package.json index 6e632cff65a..ab53c29ae76 100644 --- a/projects/storefrontstyles/package.json +++ b/projects/storefrontstyles/package.json @@ -1,6 +1,6 @@ { "name": "@spartacus/styles", - "version": "2211.29.0", + "version": "2211.29.1", "description": "Style library containing global styles", "keywords": [ "spartacus", diff --git a/projects/storefrontstyles/scss/_versioning.scss b/projects/storefrontstyles/scss/_versioning.scss index 12ad7b39330..87b74298064 100644 --- a/projects/storefrontstyles/scss/_versioning.scss +++ b/projects/storefrontstyles/scss/_versioning.scss @@ -29,7 +29,7 @@ $_fullVersion: ( major: 2211, minor: 29, - patch: 0, + patch: 1, ); // The _global_ major version. Any (left over) styles from previous stable versions diff --git a/tools/config/const.ts b/tools/config/const.ts index 840a2796a8f..ccb27e30206 100644 --- a/tools/config/const.ts +++ b/tools/config/const.ts @@ -10,4 +10,4 @@ export const SPARTACUS_SCOPE = '@spartacus'; export const SAP_SCOPE = 'sap'; export const SAPUI5_TYPES = '@sapui5/ts-types-esm'; export const SPARTACUS_SCHEMATICS = `${SPARTACUS_SCOPE}/schematics`; -export const PUBLISHING_VERSION = '2211.29.0'; +export const PUBLISHING_VERSION = '2211.29.1'; From 9de45d0a4462d8495c7ab460fae673ffe5ffb048 Mon Sep 17 00:00:00 2001 From: Krzysztof Platis Date: Wed, 9 Oct 2024 16:25:40 +0200 Subject: [PATCH 06/20] refactor(optimized-ssr-engine.spec): don't confuse terms: request, render, HTML, response (#19369) Terms used in tests now comply with the following semantics: - `request` - is sent by client and received by the OptimizedSsrEngine - `response` - is sent back to the client by the OptimizedSsrEngine - `render` / `rendering` - the process performed by Angular to produce a final HTML (or error) for given rendering key (note: the rendering key is by default the URL path in the `request`) - `HTML` - the result of the rendering closes https://jira.tools.sap/browse/CXSPA-7860 --- .../optimized-ssr-engine.spec.ts | 176 +++++++++--------- 1 file changed, 89 insertions(+), 87 deletions(-) diff --git a/core-libs/setup/ssr/optimized-engine/optimized-ssr-engine.spec.ts b/core-libs/setup/ssr/optimized-engine/optimized-ssr-engine.spec.ts index 26fb3c402cd..ffab135f4c6 100644 --- a/core-libs/setup/ssr/optimized-engine/optimized-ssr-engine.spec.ts +++ b/core-libs/setup/ssr/optimized-engine/optimized-ssr-engine.spec.ts @@ -36,14 +36,14 @@ class MockExpressServerLogger implements Partial { * Usage: * 1. Instantiate the class with desired options * 2. Call request() to run request through engine - * 3. Examine renders property for the renders + * 3. Examine responses property */ class TestEngineRunner { /** Accumulates html output for engine runs */ - renders: (string | Error)[] = []; + responses: (string | Error)[] = []; - /** Accumulates response parameters for engine runs */ - responseParams: object[] = []; + /** Accumulates responses' headers for engine runs */ + responsesHeaders: object[] = []; renderCount = 0; optimizedSsrEngine: OptimizedSsrEngine; @@ -86,7 +86,7 @@ class TestEngineRunner { return new TestEngineRunner(options, renderTime, { withError: true }); } - /** Run request against the engine. The result will be stored in rendering property. */ + /** Run request against the engine. The result will be stored in `responses` property. */ request( url: string, params?: { @@ -94,8 +94,8 @@ class TestEngineRunner { httpHeaders?: IncomingHttpHeaders; } ): TestEngineRunner { - const response: { [key: string]: string } = {}; - const headers = params?.httpHeaders ?? { host }; + const responseHeaders: { [key: string]: string } = {}; + const requestHeaders = params?.httpHeaders ?? { host }; /** used when resolving getRequestUrl() and getRequestOrigin() */ const app = >{ get: @@ -108,22 +108,22 @@ class TestEngineRunner { req: >{ protocol: 'https', originalUrl: url, - headers, + headers: requestHeaders, get: (header: string): string | string[] | null | undefined => { - return headers[header]; + return requestHeaders[header]; }, app, connection: >{}, res: >{ - set: (key: string, value: any) => (response[key] = value), + set: (key: string, value: any) => (responseHeaders[key] = value), locals: {}, }, }, }; this.engineInstance(url, optionsMock, (error, html): void => { - this.renders.push(html ?? error ?? ''); - this.responseParams.push(response); + this.responses.push(html ?? error ?? ''); + this.responsesHeaders.push(responseHeaders); }); return this; @@ -208,12 +208,12 @@ describe('OptimizedSsrEngine', () => { }); describe('rendering', () => { - it('should return rendered output if no errors', fakeAsync(() => { + it('should return rendered HTML if no errors', fakeAsync(() => { const originalUrl = 'a'; const engineRunner = new TestEngineRunner({}).request('a'); tick(200); - expect(engineRunner.renders).toEqual(['a-0']); + expect(engineRunner.responses).toEqual(['a-0']); expect(consoleLogSpy).toHaveBeenCalledWith( expect.stringContaining( `Request is resolved with the SSR rendering result (${originalUrl})` @@ -226,7 +226,7 @@ describe('OptimizedSsrEngine', () => { const engineRunner = TestEngineRunner.withError({}).request('a'); tick(200); - expect(engineRunner.renders).toEqual([new Error('a-0')]); + expect(engineRunner.responses).toEqual([new Error('a-0')]); expect(consoleErrorSpy).toHaveBeenCalledWith( expect.stringContaining( `Request is resolved with the SSR rendering error (${originalUrl})` @@ -260,39 +260,39 @@ describe('OptimizedSsrEngine', () => { }); describe('timeout option', () => { - it('should fallback to CSR if rendering exceeds timeout', fakeAsync(() => { + it('should fallback to CSR if rendering exceeds a request timeout', fakeAsync(() => { const engineRunner = new TestEngineRunner({ timeout: 50 }).request('a'); tick(200); - expect(engineRunner.renders).toEqual(['']); + expect(engineRunner.responses).toEqual(['']); })); - it('should return timed out render in the followup request', fakeAsync(() => { + it('should reuse HTML meant for a previous timeouted request, if the new request is for the same url', fakeAsync(() => { const engineRunner = new TestEngineRunner({ timeout: 50 }).request('a'); tick(200); - expect(engineRunner.renders).toEqual(['']); + expect(engineRunner.responses).toEqual(['']); engineRunner.request('a'); - expect(engineRunner.renders[1]).toEqual('a-0'); + expect(engineRunner.responses[1]).toEqual('a-0'); })); - it('should return render if rendering meets timeout', fakeAsync(() => { + it('should return HTML if rendering meets timeout', fakeAsync(() => { const engineRunner = new TestEngineRunner({ timeout: 150 }).request('a'); tick(200); - expect(engineRunner.renders).toEqual(['a-0']); + expect(engineRunner.responses).toEqual(['a-0']); })); it('should fallback instantly if is set to 0', () => { const engineRunner = new TestEngineRunner({ timeout: 0 }).request('a'); - expect(engineRunner.renders).toEqual(['']); + expect(engineRunner.responses).toEqual(['']); }); - it('should return timed out render in the followup request, also when timeout is set to 0', fakeAsync(() => { + it('should return HTML meant for a previous timeouted request if the new request is for the same url, even if `timeout` is configured to 0', fakeAsync(() => { const engineRunner = new TestEngineRunner({ timeout: 0 }).request('a'); - expect(engineRunner.renders).toEqual(['']); + expect(engineRunner.responses).toEqual(['']); expect(getCurrentConcurrency(engineRunner)).toEqual({ currentConcurrency: 1, }); @@ -303,37 +303,38 @@ describe('OptimizedSsrEngine', () => { }); engineRunner.request('a'); - expect(engineRunner.renders[1]).toEqual('a-0'); + expect(engineRunner.responses[1]).toEqual('a-0'); expect(getCurrentConcurrency(engineRunner)).toEqual({ currentConcurrency: 0, }); })); }); - describe('no-store cache control header', () => { - it('should be applied for a fallback', () => { + describe('no-store cache control header in response', () => { + it('should be applied if a request times out ', () => { const engineRunner = new TestEngineRunner({ timeout: 0 }).request('a'); - expect(engineRunner.renders).toEqual(['']); - expect(engineRunner.responseParams).toEqual([ + expect(engineRunner.responses).toEqual(['']); + expect(engineRunner.responsesHeaders).toEqual([ { 'Cache-Control': 'no-store' }, ]); }); - it('should not be applied for a render within time limit', fakeAsync(() => { + it('should not be applied if rendering finishes before request times out', fakeAsync(() => { const engineRunner = new TestEngineRunner({ timeout: 200 }).request('a'); tick(200); - expect(engineRunner.renders).toEqual(['a-0']); - expect(engineRunner.responseParams).toEqual([{}]); + expect(engineRunner.responses).toEqual(['a-0']); + expect(engineRunner.responsesHeaders).toEqual([{}]); })); - it('should not be applied for a render served with next response', fakeAsync(() => { + + it('should not be applied for subsequent requests to the same url, when reusing a HTML meant for a previous timed out request', fakeAsync(() => { const engineRunner = new TestEngineRunner({ timeout: 50 }).request('a'); tick(200); engineRunner.request('a'); - expect(engineRunner.renders).toEqual(['', 'a-0']); - expect(engineRunner.responseParams).toEqual([ + expect(engineRunner.responses).toEqual(['', 'a-0']); + expect(engineRunner.responsesHeaders).toEqual([ { 'Cache-Control': 'no-store' }, {}, ]); @@ -341,7 +342,7 @@ describe('OptimizedSsrEngine', () => { }); describe('cache option', () => { - it('should not cache requests if disabled', fakeAsync(() => { + it('should not cache HTML if `cache` is disabled', fakeAsync(() => { const engineRunner = new TestEngineRunner({ cache: false, timeout: 200, @@ -352,9 +353,10 @@ describe('OptimizedSsrEngine', () => { tick(200); engineRunner.request('a'); tick(200); - expect(engineRunner.renders).toEqual(['a-0', 'a-1', 'a-2']); + expect(engineRunner.responses).toEqual(['a-0', 'a-1', 'a-2']); })); - it('should cache requests if enabled', fakeAsync(() => { + + it('should cache HTML if `cache` is enabled', fakeAsync(() => { const engineRunner = new TestEngineRunner({ cache: true, timeout: 200, @@ -379,7 +381,7 @@ describe('OptimizedSsrEngine', () => { tick(200); - expect(engineRunner.renders).toEqual(['a-0', 'a-0', 'a-0']); + expect(engineRunner.responses).toEqual(['a-0', 'a-0', 'a-0']); })); }); @@ -398,7 +400,7 @@ describe('OptimizedSsrEngine', () => { tick(200); engineRunner.request('a'); tick(200); - expect(engineRunner.renders).toEqual([ + expect(engineRunner.responses).toEqual([ new Error('a-0'), new Error('a-1'), new Error('a-2'), @@ -418,7 +420,7 @@ describe('OptimizedSsrEngine', () => { tick(200); engineRunner.request('a'); tick(200); - expect(engineRunner.renders).toEqual([ + expect(engineRunner.responses).toEqual([ new Error('a-0'), new Error('a-0'), new Error('a-0'), @@ -438,7 +440,7 @@ describe('OptimizedSsrEngine', () => { tick(200); engineRunner.request('a'); tick(200); - expect(engineRunner.renders).toEqual(['a-0', 'a-0', 'a-0']); + expect(engineRunner.responses).toEqual(['a-0', 'a-0', 'a-0']); })); it('should cache HTML if `avoidCachingErrors` is set to false', fakeAsync(() => { @@ -454,7 +456,7 @@ describe('OptimizedSsrEngine', () => { tick(200); engineRunner.request('a'); tick(200); - expect(engineRunner.renders).toEqual(['a-0', 'a-0', 'a-0']); + expect(engineRunner.responses).toEqual(['a-0', 'a-0', 'a-0']); })); }); }); @@ -471,7 +473,7 @@ describe('OptimizedSsrEngine', () => { tick(200); engineRunner.request('a'); tick(200); - expect(engineRunner.renders).toEqual([ + expect(engineRunner.responses).toEqual([ new Error('a-0'), new Error('a-1'), new Error('a-2'), @@ -489,7 +491,7 @@ describe('OptimizedSsrEngine', () => { tick(200); engineRunner.request('a'); tick(200); - expect(engineRunner.renders).toEqual([ + expect(engineRunner.responses).toEqual([ new Error('a-0'), new Error('a-0'), new Error('a-0'), @@ -507,7 +509,7 @@ describe('OptimizedSsrEngine', () => { tick(200); engineRunner.request('a'); tick(200); - expect(engineRunner.renders).toEqual(['a-0', 'a-1', 'a-2']); + expect(engineRunner.responses).toEqual(['a-0', 'a-1', 'a-2']); })); it('should cache HTML if `shouldCacheRenderingResult` returns true', fakeAsync(() => { @@ -521,7 +523,7 @@ describe('OptimizedSsrEngine', () => { tick(200); engineRunner.request('a'); tick(200); - expect(engineRunner.renders).toEqual(['a-0', 'a-0', 'a-0']); + expect(engineRunner.responses).toEqual(['a-0', 'a-0', 'a-0']); })); }); @@ -538,7 +540,7 @@ describe('OptimizedSsrEngine', () => { .request('e'); tick(200); - expect(engineRunner.renders).toEqual([ + expect(engineRunner.responses).toEqual([ '', // CSR fallback for 'd' '', // CSR fallback for 'e' 'a-0', @@ -561,7 +563,7 @@ describe('OptimizedSsrEngine', () => { engineRunner.request('f').request('g'); tick(200); - expect(engineRunner.renders).toEqual([ + expect(engineRunner.responses).toEqual([ '', // CSR fallback for 'c' 'a-0', '', // CSR fallback for 'e' @@ -574,7 +576,7 @@ describe('OptimizedSsrEngine', () => { }); describe('ttl option', () => { - it('should invalidate expired renders', fakeAsync(() => { + it('should invalidate expired cache entries', fakeAsync(() => { let currentDate = 100; jest.spyOn(Date, 'now').mockImplementation(() => currentDate); @@ -593,10 +595,10 @@ describe('OptimizedSsrEngine', () => { engineRunner.request('a'); tick(200); - expect(engineRunner.renders).toEqual(['a-0', 'a-0', 'a-1']); + expect(engineRunner.responses).toEqual(['a-0', 'a-0', 'a-1']); })); - it('should not invalidate renders if ttl is not defined', fakeAsync(() => { + it('should not invalidate cache entries if `ttl` is not defined', fakeAsync(() => { let currentDate = 100; jest.spyOn(Date, 'now').mockImplementation(() => currentDate); @@ -614,7 +616,7 @@ describe('OptimizedSsrEngine', () => { engineRunner.request('a'); tick(200); - expect(engineRunner.renders).toEqual(['a-0', 'a-0', 'a-0']); + expect(engineRunner.responses).toEqual(['a-0', 'a-0', 'a-0']); })); }); @@ -679,7 +681,7 @@ describe('OptimizedSsrEngine', () => { tick(200); engineRunner.request('elu'); tick(200); - expect(engineRunner.renders).toEqual([ + expect(engineRunner.responses).toEqual([ 'ala-0', 'ala-0', 'ela-1', @@ -699,7 +701,7 @@ describe('OptimizedSsrEngine', () => { }).request('a'); tick(200); - expect(engineRunner.renders).toEqual(['a-0']); + expect(engineRunner.responses).toEqual(['a-0']); })); it('should ignore timeout also when it is set to 0', fakeAsync(() => { @@ -712,10 +714,10 @@ describe('OptimizedSsrEngine', () => { engineRunner.request('a'); tick(200); - expect(engineRunner.renders).toEqual(['a-0']); + expect(engineRunner.responses).toEqual(['a-0']); })); - it('when reuseCurrentRendering is false, it should render each request separately, even if there is already a pending render for the same rendering key', fakeAsync(() => { + it('when reuseCurrentRendering is false, it should render for each request separately, even if there is already a pending render for the same rendering key', fakeAsync(() => { const engineRunner = new TestEngineRunner({ renderingStrategyResolver: () => RenderingStrategy.ALWAYS_SSR, timeout: 200, @@ -736,10 +738,10 @@ describe('OptimizedSsrEngine', () => { expect(getCurrentConcurrency(engineRunner)).toEqual({ currentConcurrency: 2, }); - expect(engineRunner.renders).toEqual([]); + expect(engineRunner.responses).toEqual([]); tick(100); - expect(engineRunner.renders).toEqual(['a-0', 'a-1']); + expect(engineRunner.responses).toEqual(['a-0', 'a-1']); expect( engineRunner.optimizedSsrEngine['expressEngine'] ).toHaveBeenCalledTimes(2); @@ -762,7 +764,7 @@ describe('OptimizedSsrEngine', () => { tick(200); engineRunner.request('a'); tick(200); - expect(engineRunner.renders).toEqual(['', '']); + expect(engineRunner.responses).toEqual(['', '']); })); it('should not start the actual render in the background', fakeAsync(() => { @@ -777,7 +779,7 @@ describe('OptimizedSsrEngine', () => { ); engineRunner.request('a'); - expect(engineRunner.renders).toEqual(['']); + expect(engineRunner.responses).toEqual(['']); expect( engineRunner.optimizedSsrEngine['expressEngine'] @@ -796,10 +798,10 @@ describe('OptimizedSsrEngine', () => { tick(200); engineRunner.request('a'); - expect(engineRunner.renders).toEqual(['', 'a-0']); + expect(engineRunner.responses).toEqual(['', 'a-0']); })); - it('when reuseCurrentRendering is false, it should fallback to CSR when there is already pending a render for the same rendering key', fakeAsync(() => { + it('when reuseCurrentRendering is false, it should fallback to CSR when there is already a pending render for the same rendering key', fakeAsync(() => { const engineRunner = new TestEngineRunner({ renderingStrategyResolver: () => RenderingStrategy.DEFAULT, timeout: 200, @@ -815,10 +817,10 @@ describe('OptimizedSsrEngine', () => { currentConcurrency: 1, }); - expect(engineRunner.renders).toEqual(['']); // immediate fallback to CSR for the 2nd request for the same key + expect(engineRunner.responses).toEqual(['']); // immediate fallback to CSR for the 2nd request for the same key tick(100); - expect(engineRunner.renders).toEqual(['', 'a-0']); + expect(engineRunner.responses).toEqual(['', 'a-0']); expect(getCurrentConcurrency(engineRunner)).toEqual({ currentConcurrency: 0, }); @@ -839,13 +841,13 @@ describe('OptimizedSsrEngine', () => { engineRunner.request('a', { httpHeaders: { 'User-Agent': 'bot' } }); tick(200); - expect(engineRunner.renders).toEqual(['', 'a-1']); + expect(engineRunner.responses).toEqual(['', 'a-1']); })); }); }); describe('forcedSsrTimeout option', () => { - it('should fallback to CSR when forcedSsrTimeout timeout is exceeded for ALWAYS_SSR rendering strategy, and return the timed out render in the followup request', fakeAsync(() => { + it('should fallback to CSR when forcedSsrTimeout timeout is exceeded for ALWAYS_SSR rendering strategy, and after that rendering ends, its HTML should be reused in the next request for the same url', fakeAsync(() => { const engineRunner = new TestEngineRunner({ renderingStrategyResolver: () => RenderingStrategy.ALWAYS_SSR, timeout: 50, @@ -858,15 +860,15 @@ describe('OptimizedSsrEngine', () => { }); tick(60); - expect(engineRunner.renders).toEqual([]); + expect(engineRunner.responses).toEqual([]); tick(50); - expect(engineRunner.renders).toEqual(['']); + expect(engineRunner.responses).toEqual(['']); expect(getCurrentConcurrency(engineRunner)).toEqual({ currentConcurrency: 0, }); engineRunner.request('a'); - expect(engineRunner.renders).toEqual(['', 'a-0']); + expect(engineRunner.responses).toEqual(['', 'a-0']); expect(getCurrentConcurrency(engineRunner)).toEqual({ currentConcurrency: 0, }); @@ -881,11 +883,11 @@ describe('OptimizedSsrEngine', () => { engineRunner.request('a'); tick(60); - expect(engineRunner.renders).toEqual(['']); + expect(engineRunner.responses).toEqual(['']); tick(50); engineRunner.request('a'); - expect(engineRunner.renders).toEqual(['', 'a-0']); + expect(engineRunner.responses).toEqual(['', 'a-0']); })); }); describe('maxRenderTime option', () => { @@ -1017,7 +1019,7 @@ describe('OptimizedSsrEngine', () => { renderTime ).request(requestUrl); jest.spyOn(engineRunner.optimizedSsrEngine as any, 'log'); - expect(engineRunner.renders).toEqual([]); + expect(engineRunner.responses).toEqual([]); tick(fiveMinutes + 101); expect(engineRunner.optimizedSsrEngine['log']).toHaveBeenCalledWith( @@ -1025,10 +1027,10 @@ describe('OptimizedSsrEngine', () => { false, { request: expect.objectContaining({ originalUrl: requestUrl }) } ); - expect(engineRunner.renders).toEqual(['']); + expect(engineRunner.responses).toEqual(['']); engineRunner.request(requestUrl); - expect(engineRunner.renders).toEqual(['']); // if the result was cached, the 2nd request would get immediately 'a-0' + expect(engineRunner.responses).toEqual(['']); // if the result was cached, the 2nd request would get immediately 'a-0' flush(); })); }); @@ -1083,14 +1085,14 @@ describe('OptimizedSsrEngine', () => { false, { request: expect.objectContaining({ originalUrl: requestUrl }) } ); - expect(engineRunner.renders).toEqual(['', '']); + expect(engineRunner.responses).toEqual(['', '']); flush(); })); }); describe('when enabled', () => { - describe('multiple subsequent requests for the same rendering key should reuse the same render', () => { + describe('multiple subsequent requests for the same rendering key should await for the result of the same pending rendering, and all get the same HTML response', () => { it('and the first request should timeout', fakeAsync(() => { const timeout = 300; const engineRunner = new TestEngineRunner( @@ -1113,7 +1115,7 @@ describe('OptimizedSsrEngine', () => { tick(100); expect(engineRunner.renderCount).toEqual(1); - expect(engineRunner.renders).toEqual(['', `${requestUrl}-0`]); + expect(engineRunner.responses).toEqual(['', `${requestUrl}-0`]); flush(); })); @@ -1151,7 +1153,7 @@ describe('OptimizedSsrEngine', () => { expect(renderExceedMessageCount).toBe(2); expect(engineRunner.renderCount).toEqual(0); - expect(engineRunner.renders).toEqual(['', '']); + expect(engineRunner.responses).toEqual(['', '']); flush(); })); @@ -1187,7 +1189,7 @@ describe('OptimizedSsrEngine', () => { tick(200); expect(engineRunner.renderCount).toEqual(1); - expect(engineRunner.renders).toEqual([ + expect(engineRunner.responses).toEqual([ `${requestUrl}-0`, `${requestUrl}-0`, ]); @@ -1237,7 +1239,7 @@ describe('OptimizedSsrEngine', () => { false, { request: expect.objectContaining({ originalUrl: requestUrl }) } ); - expect(engineRunner.renders).toEqual(['']); // the first request fallback to CSR due to timeout + expect(engineRunner.responses).toEqual(['']); // the first request fallback to CSR due to timeout expect(getCurrentConcurrency(engineRunner)).toEqual({ currentConcurrency: 1, }); // the render still continues in the background @@ -1245,7 +1247,7 @@ describe('OptimizedSsrEngine', () => { // eventually the render succeeds and 2 remaining requests get the same response: tick(100); expect(engineRunner.renderCount).toEqual(1); - expect(engineRunner.renders).toEqual([ + expect(engineRunner.responses).toEqual([ '', // CSR fallback of the 1st request due to it timed out `${requestUrl}-0`, `${requestUrl}-0`, @@ -1260,7 +1262,7 @@ describe('OptimizedSsrEngine', () => { flush(); })); - it('and concurrency limit should NOT fallback to CSR, when the request is for a pending render', fakeAsync(() => { + it('and concurrency limit should NOT fallback to CSR, when there is a pending rendering for the same rendering key', fakeAsync(() => { const engineRunner = new TestEngineRunner({ reuseCurrentRendering: true, timeout: 200, @@ -1277,7 +1279,7 @@ describe('OptimizedSsrEngine', () => { ).not.toHaveBeenCalledWith( `CSR fallback: Concurrency limit exceeded (1)` ); - expect(engineRunner.renders).toEqual(['a-0', 'a-0']); + expect(engineRunner.responses).toEqual(['a-0', 'a-0']); })); it('combined with a different request should take up two concurrency slots', fakeAsync(() => { @@ -1312,7 +1314,7 @@ describe('OptimizedSsrEngine', () => { }); tick(250); - expect(engineRunner.renders).toEqual([ + expect(engineRunner.responses).toEqual([ 'a-0', 'a-0', 'a-0', @@ -1429,7 +1431,7 @@ describe('OptimizedSsrEngine', () => { ); expect(engineRunner.renderCount).toEqual(1); - expect(engineRunner.renders).toEqual(['', '']); + expect(engineRunner.responses).toEqual(['', '']); flush(); })); From cf92e4a912d9629343d705be5474c0efbe46ebaf Mon Sep 17 00:00:00 2001 From: Christoph Hinssen <33626130+ChristophHi@users.noreply.github.com> Date: Thu, 10 Oct 2024 09:34:41 +0200 Subject: [PATCH 07/20] chore: change default for cartQuickOrderRemoveListeningToFailEvent (#19377) --- .../features-config/feature-toggles/config/feature-toggles.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/projects/core/src/features-config/feature-toggles/config/feature-toggles.ts b/projects/core/src/features-config/feature-toggles/config/feature-toggles.ts index a7704a7c719..0fac75b627a 100644 --- a/projects/core/src/features-config/feature-toggles/config/feature-toggles.ts +++ b/projects/core/src/features-config/feature-toggles/config/feature-toggles.ts @@ -680,7 +680,7 @@ export const defaultFeatureToggles: Required = { a11yFocusableCarouselControls: false, a11yUseTrapTabInsteadOfTrapInDialogs: false, cmsGuardsServiceUseGuardsComposer: false, - cartQuickOrderRemoveListeningToFailEvent: false, + cartQuickOrderRemoveListeningToFailEvent: true, a11yKeyboardAccessibleZoom: false, a11yOrganizationLinkableCells: false, a11yVisibleFocusOverflows: false, From 901ddd43a90f14d0fd8fbc100da9b40f728273c7 Mon Sep 17 00:00:00 2001 From: PioBar <72926984+Pio-Bar@users.noreply.github.com> Date: Thu, 10 Oct 2024 10:52:55 +0200 Subject: [PATCH 08/20] fix: (CXSPA-8605) - Cart delivery selector fix (#19371) --- ...rt-pickup-options-container.component.html | 2 +- ...pickup-options-container.component.spec.ts | 38 ++++- ...cart-pickup-options-container.component.ts | 133 +++++++++++++----- .../feature-toggles/config/feature-toggles.ts | 2 +- .../accessibility/focus-management.e2e.cy.ts | 12 +- 5 files changed, 144 insertions(+), 43 deletions(-) diff --git a/feature-libs/pickup-in-store/components/container/cart-pickup-options-container/cart-pickup-options-container.component.html b/feature-libs/pickup-in-store/components/container/cart-pickup-options-container/cart-pickup-options-container.component.html index ce154665b90..a04b8963cc5 100644 --- a/feature-libs/pickup-in-store/components/container/cart-pickup-options-container/cart-pickup-options-container.component.html +++ b/feature-libs/pickup-in-store/components/container/cart-pickup-options-container/cart-pickup-options-container.component.html @@ -10,6 +10,6 @@ [displayPickupLocation]="(storeDetails$ | async)?.displayName" [selectedOption]="pickupOption$ | async" (pickupOptionChange)="onPickupOptionChange($event)" - (pickupLocationChange)="openDialog()" + (pickupLocationChange)="openDialog($event)" > diff --git a/feature-libs/pickup-in-store/components/container/cart-pickup-options-container/cart-pickup-options-container.component.spec.ts b/feature-libs/pickup-in-store/components/container/cart-pickup-options-container/cart-pickup-options-container.component.spec.ts index d2b4b220687..4a2d0d22a95 100644 --- a/feature-libs/pickup-in-store/components/container/cart-pickup-options-container/cart-pickup-options-container.component.spec.ts +++ b/feature-libs/pickup-in-store/components/container/cart-pickup-options-container/cart-pickup-options-container.component.spec.ts @@ -1,4 +1,5 @@ import { CommonModule } from '@angular/common'; +import { ElementRef } from '@angular/core'; import { ComponentFixture, TestBed, @@ -6,7 +7,12 @@ import { tick, } from '@angular/core/testing'; import { ActiveCartFacade, Cart, OrderEntry } from '@spartacus/cart/base/root'; -import { CmsService, I18nTestingModule, Page } from '@spartacus/core'; +import { + CmsService, + FeatureConfigService, + I18nTestingModule, + Page, +} from '@spartacus/core'; import { AugmentedPointOfService, IntendedPickupLocationFacade, @@ -16,8 +22,8 @@ import { PreferredStoreFacade, } from '@spartacus/pickup-in-store/root'; import { - LaunchDialogService, LAUNCH_CALLER, + LaunchDialogService, OutletContextData, } from '@spartacus/storefront'; import { cold } from 'jasmine-marbles'; @@ -109,6 +115,12 @@ const mockOutletContext: { item: OrderEntry; cartType: string } = { cartType: 'cart', }; +class MockFeatureConfigService { + isEnabled() { + return true; + } +} + const context$ = of(mockOutletContext); class MockIntendedPickupLocationFacade { @@ -167,6 +179,10 @@ describe('CartPickupOptionsContainerComponent', () => { provide: IntendedPickupLocationFacade, useClass: MockIntendedPickupLocationFacade, }, + { + provide: FeatureConfigService, + useClass: MockFeatureConfigService, + }, ], }); @@ -198,10 +214,11 @@ describe('CartPickupOptionsContainerComponent', () => { }); it('should trigger and open dialog', () => { - component.openDialog(); + const triggerElement = new ElementRef({}); + component.openDialog(triggerElement); expect(launchDialogService.openDialog).toHaveBeenCalledWith( LAUNCH_CALLER.PICKUP_IN_STORE, - component.element, + triggerElement, component['vcr'], { productCode: 'productCode1', entryNumber: 1, quantity: 1 } ); @@ -210,7 +227,12 @@ describe('CartPickupOptionsContainerComponent', () => { it('should not openDialog if display name is not set and ship it is selected', () => { spyOn(component, 'openDialog'); component['displayNameIsSet'] = false; - component.onPickupOptionChange('delivery'); + const pickupOption: PickupOption = 'delivery'; + const event = { + option: pickupOption, + triggerElement: new ElementRef({}), + }; + component.onPickupOptionChange(event); expect(component.openDialog).not.toHaveBeenCalled(); }); @@ -218,6 +240,10 @@ describe('CartPickupOptionsContainerComponent', () => { const entryNumber = 2; const pickupOption: PickupOption = 'pickup'; const quantity = 3; + const event = { + option: pickupOption, + triggerElement: new ElementRef({}), + }; component.entryNumber = entryNumber; component.quantity = quantity; @@ -226,7 +252,7 @@ describe('CartPickupOptionsContainerComponent', () => { spyOn(pickupOptionService, 'setPickupOption'); spyOn(activeCartService, 'updateEntry'); - component.onPickupOptionChange(pickupOption); + component.onPickupOptionChange(event); expect(pickupOptionService.setPickupOption).toHaveBeenCalledWith( entryNumber, pickupOption diff --git a/feature-libs/pickup-in-store/components/container/cart-pickup-options-container/cart-pickup-options-container.component.ts b/feature-libs/pickup-in-store/components/container/cart-pickup-options-container/cart-pickup-options-container.component.ts index ecfdee85fed..5abd5ec2cfc 100644 --- a/feature-libs/pickup-in-store/components/container/cart-pickup-options-container/cart-pickup-options-container.component.ts +++ b/feature-libs/pickup-in-store/components/container/cart-pickup-options-container/cart-pickup-options-container.component.ts @@ -7,6 +7,7 @@ import { Component, ElementRef, + inject, OnDestroy, OnInit, Optional, @@ -18,7 +19,7 @@ import { CartType, OrderEntry, } from '@spartacus/cart/base/root'; -import { CmsService, Page } from '@spartacus/core'; +import { CmsService, FeatureConfigService, Page } from '@spartacus/core'; import { cartWithIdAndUserId, getProperty, @@ -30,8 +31,8 @@ import { RequiredDeepPath, } from '@spartacus/pickup-in-store/root'; import { - LaunchDialogService, LAUNCH_CALLER, + LaunchDialogService, OutletContextData, } from '@spartacus/storefront'; import { EMPTY, iif, Observable, of, Subscription } from 'rxjs'; @@ -79,6 +80,12 @@ export function orderEntryWithRequiredFields( templateUrl: 'cart-pickup-options-container.component.html', }) export class CartPickupOptionsContainerComponent implements OnInit, OnDestroy { + // TODO: Remove element reference once 'a11yDialogTriggerRefocus' feature flag is removed. + /** + * @deprecated since 2211.28.0 + * This reference does not point to any element and will be removed at earliest convinience. + * The 'triggerElement' is passed through 'PickupOptionChange' event instead. + */ @ViewChild('open') element: ElementRef; pickupOption$: Observable; @@ -98,6 +105,7 @@ export class CartPickupOptionsContainerComponent implements OnInit, OnDestroy { private displayNameIsSet = false; page?: string; readonly CartType = CartType; + private featureConfigService = inject(FeatureConfigService); constructor( protected activeCartFacade: ActiveCartFacade, protected launchDialogService: LaunchDialogService, @@ -253,40 +261,92 @@ export class CartPickupOptionsContainerComponent implements OnInit, OnDestroy { tap((_) => (this.displayNameIsSet = true)) ); } - - onPickupOptionChange(pickupOption: PickupOption): void { - this.pickupOptionFacade.setPickupOption(this.entryNumber, pickupOption); - if (pickupOption === 'delivery') { - this.activeCartFacade.updateEntry( - this.entryNumber, - this.quantity, - undefined, - true - ); - return; - } - [pickupOption] - .filter((option) => option === 'pickup') - .forEach(() => { - this.subscription.add( - this.storeDetails$ - .pipe( - filter(({ name }) => !!name), - tap(({ name }) => - this.activeCartFacade.updateEntry( - this.entryNumber, - this.quantity, - name, - true + // TODO: Remove 'PickupOption' argument type once 'a11yDialogTriggerRefocus' feature flag is removed. + /** + * @deprecated since 2211.28.0 - Use event param instead of option. + * @param event - Object containing the selected option and the element that triggered the change. + */ + onPickupOptionChange(pickupOption: PickupOption): void; + // eslint-disable-next-line @typescript-eslint/unified-signatures + onPickupOptionChange(event: { + option: PickupOption; + triggerElement: ElementRef; + }): void; + onPickupOptionChange( + event: { option: PickupOption; triggerElement: ElementRef } | PickupOption + ): void { + /* istanbul ignore else */ + if ( + this.featureConfigService.isEnabled('a11yDialogTriggerRefocus') && + typeof event === 'object' + ) { + this.pickupOptionFacade.setPickupOption(this.entryNumber, event.option); + if (event.option === 'delivery') { + this.activeCartFacade.updateEntry( + this.entryNumber, + this.quantity, + undefined, + true + ); + return; + } + [event.option] + .filter((option) => option === 'pickup') + .forEach(() => { + this.subscription.add( + this.storeDetails$ + .pipe( + filter(({ name }) => !!name), + tap(({ name }) => + this.activeCartFacade.updateEntry( + this.entryNumber, + this.quantity, + name, + true + ) ) ) - ) - .subscribe() + .subscribe() + ); + }); + + if (!this.displayNameIsSet) { + this.openDialog(event.triggerElement); + } + } else if (typeof event === 'string') { + this.pickupOptionFacade.setPickupOption(this.entryNumber, event); + if (event === 'delivery') { + this.activeCartFacade.updateEntry( + this.entryNumber, + this.quantity, + undefined, + true ); - }); + return; + } + [event] + .filter((option) => option === 'pickup') + .forEach(() => { + this.subscription.add( + this.storeDetails$ + .pipe( + filter(({ name }) => !!name), + tap(({ name }) => + this.activeCartFacade.updateEntry( + this.entryNumber, + this.quantity, + name, + true + ) + ) + ) + .subscribe() + ); + }); - if (!this.displayNameIsSet) { - this.openDialog(); + if (!this.displayNameIsSet) { + this.openDialog(); + } } } @@ -294,10 +354,15 @@ export class CartPickupOptionsContainerComponent implements OnInit, OnDestroy { this.subscription.unsubscribe(); } - openDialog(): void { + // TODO: Make argument required once 'a11yDialogTriggerRefocus' feature flag is removed. + /** + * @deprecated since 2211.28.0 - The use of TriggerElement param will become mandatory. + * @param triggerElement - The reference of element that triggered the dialog. Used to refocus on it after the dialog is closed. + */ + openDialog(triggerElement?: ElementRef): void { const dialog = this.launchDialogService.openDialog( LAUNCH_CALLER.PICKUP_IN_STORE, - this.element, + triggerElement ? triggerElement : this.element, this.vcr, { productCode: this.productCode, diff --git a/projects/core/src/features-config/feature-toggles/config/feature-toggles.ts b/projects/core/src/features-config/feature-toggles/config/feature-toggles.ts index 0fac75b627a..864374fdc58 100644 --- a/projects/core/src/features-config/feature-toggles/config/feature-toggles.ts +++ b/projects/core/src/features-config/feature-toggles/config/feature-toggles.ts @@ -562,7 +562,7 @@ export interface FeatureTogglesInterface { /** * When enabled, the focus will be returned to the trigger element after the dialog is closed. - * Affected components: 'AddtoCartComponent', 'PickupOptionsComponent' + * Affected components: 'AddtoCartComponent', 'PickupOptionsComponent', CartPickupOptionsContainerComponent, PDPPickupOptionsContainerComponent */ a11yDialogTriggerRefocus?: boolean; diff --git a/projects/storefrontapp-e2e-cypress/cypress/e2e/accessibility/focus-management.e2e.cy.ts b/projects/storefrontapp-e2e-cypress/cypress/e2e/accessibility/focus-management.e2e.cy.ts index 3dea1a4b423..310a4877ee1 100644 --- a/projects/storefrontapp-e2e-cypress/cypress/e2e/accessibility/focus-management.e2e.cy.ts +++ b/projects/storefrontapp-e2e-cypress/cypress/e2e/accessibility/focus-management.e2e.cy.ts @@ -4,6 +4,7 @@ * SPDX-License-Identifier: Apache-2.0 */ +import * as cart from '../../helpers/cart'; import * as checkout from '../../helpers/checkout-flow'; describe('Focus managment for a11y', () => { @@ -34,8 +35,17 @@ describe('Focus managment for a11y', () => { }); context('Pick up in store modal', () => { - it('Should re-focus the element triggering the modal after it closes', () => { + it('Should re-focus the element triggering the modal on PDP after it closes', () => { + cy.visit(`/product/266685`); + cy.contains('Select Store').click(); + cy.get('[aria-label="Close"]').click(); + cy.contains('Select Store').should('have.focus'); + }); + + it('Should re-focus the element triggering the modal in Cart after it closes', () => { cy.visit(`/product/266685`); + cart.addProductAsAnonymous(); + cy.visit('/cart'); cy.contains('Select Store').click(); cy.get('[aria-label="Close"]').click(); cy.contains('Select Store').should('have.focus'); From 6eb3258c1308da9645c032aec6f5256bc78f6821 Mon Sep 17 00:00:00 2001 From: Krzysztof Platis Date: Thu, 10 Oct 2024 11:48:41 +0200 Subject: [PATCH 09/20] fix: ensure all possible SsrOptimizationOptions have explicitly defined default values (#19372) Thanks to this, all the options (with their explicit default values) will printed in the logs on the start of SSR, which should improve developers' confidence while troubleshooting. closes https://jira.tools.sap/browse/CXSPA-7482 --- .../optimized-ssr-engine.spec.ts | 66 +++++++++++-------- .../optimized-engine/optimized-ssr-engine.ts | 7 +- .../ssr-optimization-options.ts | 34 ++++++++-- 3 files changed, 69 insertions(+), 38 deletions(-) diff --git a/core-libs/setup/ssr/optimized-engine/optimized-ssr-engine.spec.ts b/core-libs/setup/ssr/optimized-engine/optimized-ssr-engine.spec.ts index ffab135f4c6..18c25b9c4c9 100644 --- a/core-libs/setup/ssr/optimized-engine/optimized-ssr-engine.spec.ts +++ b/core-libs/setup/ssr/optimized-engine/optimized-ssr-engine.spec.ts @@ -188,7 +188,9 @@ describe('OptimizedSsrEngine', () => { context: { timestamp: '2023-01-01T00:00:00.000Z', options: { + cache: false, cacheSize: 3000, + ttl: undefined, concurrency: 10, timeout: 50, forcedSsrTimeout: 60000, @@ -198,6 +200,9 @@ describe('OptimizedSsrEngine', () => { logger: 'DefaultExpressServerLogger', shouldCacheRenderingResult: '({ options, entry }) => !(options.ssrFeatureToggles?.avoidCachingErrors === true &&\\n' + ' Boolean(entry.err))', + renderKeyResolver: 'function getRequestUrl(req) {\\n' + + ' return (0, express_request_origin_1.getRequestOrigin)(req) + req.originalUrl;\\n' + + '}', ssrFeatureToggles: { avoidCachingErrors: false } } } @@ -1461,34 +1466,39 @@ describe('OptimizedSsrEngine', () => { logger: new MockExpressServerLogger() as ExpressServerLogger, }); expect(consoleLogSpy.mock.lastCall).toMatchInlineSnapshot(` - [ - "[spartacus] SSR optimization engine initialized", - { - "options": { - "cacheSize": 3000, - "concurrency": 10, - "forcedSsrTimeout": 60000, - "logger": "MockExpressServerLogger", - "maxRenderTime": 300000, - "renderingStrategyResolver": "(request) => { - if (hasExcludedUrl(request, defaultAlwaysCsrOptions.excludedUrls)) { - return ssr_optimization_options_1.RenderingStrategy.ALWAYS_CSR; - } - return shouldFallbackToCsr(request, options) - ? ssr_optimization_options_1.RenderingStrategy.ALWAYS_CSR - : ssr_optimization_options_1.RenderingStrategy.DEFAULT; - }", - "reuseCurrentRendering": true, - "shouldCacheRenderingResult": "({ options, entry }) => !(options.ssrFeatureToggles?.avoidCachingErrors === true && - Boolean(entry.err))", - "ssrFeatureToggles": { - "avoidCachingErrors": false, - }, - "timeout": 3000, - }, - }, - ] - `); +[ + "[spartacus] SSR optimization engine initialized", + { + "options": { + "cache": false, + "cacheSize": 3000, + "concurrency": 10, + "forcedSsrTimeout": 60000, + "logger": "MockExpressServerLogger", + "maxRenderTime": 300000, + "renderKeyResolver": "function getRequestUrl(req) { + return (0, express_request_origin_1.getRequestOrigin)(req) + req.originalUrl; +}", + "renderingStrategyResolver": "(request) => { + if (hasExcludedUrl(request, defaultAlwaysCsrOptions.excludedUrls)) { + return ssr_optimization_options_1.RenderingStrategy.ALWAYS_CSR; + } + return shouldFallbackToCsr(request, options) + ? ssr_optimization_options_1.RenderingStrategy.ALWAYS_CSR + : ssr_optimization_options_1.RenderingStrategy.DEFAULT; +}", + "reuseCurrentRendering": true, + "shouldCacheRenderingResult": "({ options, entry }) => !(options.ssrFeatureToggles?.avoidCachingErrors === true && + Boolean(entry.err))", + "ssrFeatureToggles": { + "avoidCachingErrors": false, + }, + "timeout": 3000, + "ttl": undefined, + }, + }, +] +`); }); }); }); diff --git a/core-libs/setup/ssr/optimized-engine/optimized-ssr-engine.ts b/core-libs/setup/ssr/optimized-engine/optimized-ssr-engine.ts index 148373f0313..66d14fe1896 100644 --- a/core-libs/setup/ssr/optimized-engine/optimized-ssr-engine.ts +++ b/core-libs/setup/ssr/optimized-engine/optimized-ssr-engine.ts @@ -8,7 +8,6 @@ import { Request, Response } from 'express'; import * as fs from 'fs'; import { NgExpressEngineInstance } from '../engine-decorator/ng-express-engine-decorator'; -import { getRequestUrl } from '../express-utils/express-request-url'; import { EXPRESS_SERVER_LOGGER, ExpressServerLogger, @@ -21,13 +20,9 @@ import { RenderingStrategy, SsrOptimizationOptions, defaultSsrOptimizationOptions, + getDefaultRenderKey, } from './ssr-optimization-options'; -/** - * Returns the full url for the given SSR Request. - */ -export const getDefaultRenderKey = getRequestUrl; - export type SsrCallbackFn = ( /** * Error that might've occurred while rendering. diff --git a/core-libs/setup/ssr/optimized-engine/ssr-optimization-options.ts b/core-libs/setup/ssr/optimized-engine/ssr-optimization-options.ts index 9f3610ef5da..6508f5044f0 100644 --- a/core-libs/setup/ssr/optimized-engine/ssr-optimization-options.ts +++ b/core-libs/setup/ssr/optimized-engine/ssr-optimization-options.ts @@ -5,6 +5,7 @@ */ import { Request } from 'express'; +import { getRequestUrl } from '../express-utils/express-request-url'; import { DefaultExpressServerLogger, ExpressServerLogger } from '../logger'; import { RenderingEntry } from './rendering-cache.model'; import { defaultRenderingStrategyResolver } from './rendering-strategy-resolver'; @@ -48,7 +49,7 @@ export interface SsrOptimizationOptions { * Time in milliseconds after prerendered page is becoming stale and should * be rendered again. */ - ttl?: number; + ttl?: number | undefined; /** * Allows overriding default key generator for custom differentiating @@ -188,10 +189,34 @@ type DeepRequired = { [P in keyof T]-?: DeepRequired; }; -export const defaultSsrOptimizationOptions: SsrOptimizationOptions & - // To not forget adding default values, when adding new feature toggles in the type in the future - DeepRequired> = { +/** + * Returns the full url for the given SSR Request. + */ +export const getDefaultRenderKey = getRequestUrl; + +/** + * The type of `defaultSsrOptimizationOptions` ensures that all properties are set to a default value. + * Thanks to this, all options are well-defined and can be printed to logs on the SSR server start. + */ +type DefaultSsrOptimizationOptions = Omit< + Required, + | 'debug' // debug is deprecated and not used anymore + | 'ttl' // ttl is required but its default value is `undefined` +> & { + ttl: number | undefined; // needed, otherwise we could not set the value `ttl: undefined` value (due to the Required<...>) +} & DeepRequired< + // all nested properties of `ssrFeatureToggles` are required too + Pick< + SsrOptimizationOptions, + // + 'ssrFeatureToggles' + > + >; + +export const defaultSsrOptimizationOptions: DefaultSsrOptimizationOptions = { + cache: false, cacheSize: 3000, + ttl: undefined, concurrency: 10, timeout: 3_000, forcedSsrTimeout: 60_000, @@ -206,6 +231,7 @@ export const defaultSsrOptimizationOptions: SsrOptimizationOptions & options.ssrFeatureToggles?.avoidCachingErrors === true && Boolean(entry.err) ), + renderKeyResolver: getDefaultRenderKey, ssrFeatureToggles: { avoidCachingErrors: false, }, From e09d954418b168796b8bdac79f4d05859fb039d7 Mon Sep 17 00:00:00 2001 From: Krzysztof Platis Date: Thu, 10 Oct 2024 12:54:55 +0200 Subject: [PATCH 10/20] chore(schematics/testing.ts): restore previous `@spartacus:registry` instead of hardcoded NPM registry on the process exit (#19378) Currently, on the process exit, the value of `@spartacus:registry` is restored to the outdated URL of public NPM registry `https://registry.npmjs.org/`. It was useful only until we stopped releasing to public NPM many months ago. Now it's confusing and a bit annoying. It's because you'd rather like it to be restored to a previous real registry url, e.g. RBSC. To fix it, now we remember the used `@spartacus:registry` before running the script `schematics/testing.ts`. Then the scrip overwrites `@spartacus:registry` to verdaccio URL (as it does usually). And then on the process exit we restore the **remembered URL** original URL. ... which should improve DX while re-running this script multiple times. closes https://jira.tools.sap/browse/CXSPA-8636 --- tools/schematics/testing.ts | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/tools/schematics/testing.ts b/tools/schematics/testing.ts index 15ed58f5e48..a12753a749c 100644 --- a/tools/schematics/testing.ts +++ b/tools/schematics/testing.ts @@ -80,11 +80,13 @@ const commands = [ 'test all schematics', 'exit', ] as const; -type Command = typeof commands[number]; +type Command = (typeof commands)[number]; const buildLibRegEx = new RegExp('build (.*?)/schematics'); -const verdaccioUrl = 'http://localhost:4873/'; -const npmUrl = 'https://registry.npmjs.org/'; +const verdaccioRegistryUrl = 'http://localhost:4873/'; +const originalRegistryUrl = execSync('npm config get @spartacus:registry') + .toString() + .trim(); function startVerdaccio(): ChildProcess { execSync('rm -rf ./scripts/install/storage'); @@ -92,7 +94,7 @@ function startVerdaccio(): ChildProcess { console.log('Waiting for verdaccio to boot...'); const res = exec('verdaccio --config ./scripts/install/config.yaml'); try { - execSync(`npx wait-on ${verdaccioUrl} --timeout 10000`); + execSync(`npx wait-on ${verdaccioRegistryUrl} --timeout 10000`); } catch (_e) { console.log( chalk.red( @@ -102,13 +104,13 @@ function startVerdaccio(): ChildProcess { process.exit(1); } console.log('Pointing npm to verdaccio'); - execSync(`npm config set @spartacus:registry ${verdaccioUrl}`); + execSync(`npm config set @spartacus:registry ${verdaccioRegistryUrl}`); return res; } function beforeExit(): void { console.log('Setting npm back to npmjs.org'); - execSync(`npm config set @spartacus:registry ${npmUrl}`); + execSync(`npm config set @spartacus:registry ${originalRegistryUrl}`); if (verdaccioProcess) { try { console.log('Killing verdaccio'); @@ -140,7 +142,7 @@ function publishLibs(): void { const dir = path.dirname(packagePath); console.log(`\nPublishing ${content.name}`); execSync( - `cd ${dir} && npm publish --registry=${verdaccioUrl} --no-git-tag-version`, + `cd ${dir} && npm publish --registry=${verdaccioRegistryUrl} --no-git-tag-version`, { stdio: 'inherit' } ); }); From 2e61752ee14e67ba07dd0e94c6579da42256adc5 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Thu, 10 Oct 2024 08:06:51 -0400 Subject: [PATCH 11/20] chore(deps): update dependency webpack to ~5.95.0 (#19363) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Giancarlo Cordero Ortiz <46171897+giancorderoortiz@users.noreply.github.com> --- package-lock.json | 26 +++++++++++++------------- package.json | 2 +- 2 files changed, 14 insertions(+), 14 deletions(-) diff --git a/package-lock.json b/package-lock.json index 82a97512c48..02c1a26f175 100644 --- a/package-lock.json +++ b/package-lock.json @@ -126,7 +126,7 @@ "ts-morph": "^23.0.0", "ts-node": "^10.6.0", "typescript": "^5.2.2", - "webpack": "~5.94.0", + "webpack": "~5.95.0", "webpack-cli": "^5.0.0" }, "engines": { @@ -23544,9 +23544,9 @@ } }, "node_modules/webpack": { - "version": "5.94.0", - "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.94.0.tgz", - "integrity": "sha512-KcsGn50VT+06JH/iunZJedYGUJS5FGjow8wb9c0v5n1Om8O1g4L6LjtfxwlXIATopoQu+vOXXa7gYisWxCoPyg==", + "version": "5.95.0", + "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.95.0.tgz", + "integrity": "sha512-2t3XstrKULz41MNMBF+cJ97TyHdyQ8HCt//pqErqDvNjU9YQBnZxIHa11VXsi7F3mb5/aO2tuDxdeTPdU7xu9Q==", "dev": true, "dependencies": { "@types/estree": "^1.0.5", @@ -23932,9 +23932,9 @@ } }, "node_modules/webpack/node_modules/watchpack": { - "version": "2.4.1", - "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.1.tgz", - "integrity": "sha512-8wrBCMtVhqcXP2Sup1ctSkga6uc2Bx0IIvKyT7yTFier5AXHooSI+QyQQAtTb7+E0IUCCKyTFmXqdqgum2XWGg==", + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.2.tgz", + "integrity": "sha512-TnbFSbcOCcDgjZ4piURLCbJ3nJhznVh9kw6F6iokjiFPl8ONxe9A6nMDVXDiNbrSfLILs6vB07F7wLBrwPYzJw==", "dev": true, "dependencies": { "glob-to-regexp": "^0.4.1", @@ -40784,9 +40784,9 @@ "dev": true }, "webpack": { - "version": "5.94.0", - "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.94.0.tgz", - "integrity": "sha512-KcsGn50VT+06JH/iunZJedYGUJS5FGjow8wb9c0v5n1Om8O1g4L6LjtfxwlXIATopoQu+vOXXa7gYisWxCoPyg==", + "version": "5.95.0", + "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.95.0.tgz", + "integrity": "sha512-2t3XstrKULz41MNMBF+cJ97TyHdyQ8HCt//pqErqDvNjU9YQBnZxIHa11VXsi7F3mb5/aO2tuDxdeTPdU7xu9Q==", "dev": true, "requires": { "@types/estree": "^1.0.5", @@ -40867,9 +40867,9 @@ } }, "watchpack": { - "version": "2.4.1", - "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.1.tgz", - "integrity": "sha512-8wrBCMtVhqcXP2Sup1ctSkga6uc2Bx0IIvKyT7yTFier5AXHooSI+QyQQAtTb7+E0IUCCKyTFmXqdqgum2XWGg==", + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.2.tgz", + "integrity": "sha512-TnbFSbcOCcDgjZ4piURLCbJ3nJhznVh9kw6F6iokjiFPl8ONxe9A6nMDVXDiNbrSfLILs6vB07F7wLBrwPYzJw==", "dev": true, "requires": { "glob-to-regexp": "^0.4.1", diff --git a/package.json b/package.json index 0e1b3d8ef54..d3387cb44e3 100644 --- a/package.json +++ b/package.json @@ -237,7 +237,7 @@ "ts-morph": "^23.0.0", "ts-node": "^10.6.0", "typescript": "^5.2.2", - "webpack": "~5.94.0", + "webpack": "~5.95.0", "webpack-cli": "^5.0.0" } } From ec946e913298491b43312c165626299a31f27eec Mon Sep 17 00:00:00 2001 From: PioBar <72926984+Pio-Bar@users.noreply.github.com> Date: Thu, 10 Oct 2024 14:44:57 +0200 Subject: [PATCH 12/20] fix: (CXSPA-1128) - NgSelect double stop on mobile alternative fix (#19152) Co-authored-by: Caine Rotherham --- .../ng-select-a11y.directive.spec.ts | 42 ++++++++++++-- .../ng-select-a11y.directive.ts | 58 +++++++++++++++++-- 2 files changed, 89 insertions(+), 11 deletions(-) diff --git a/projects/storefrontlib/shared/components/ng-select-a11y/ng-select-a11y.directive.spec.ts b/projects/storefrontlib/shared/components/ng-select-a11y/ng-select-a11y.directive.spec.ts index 5a883f00d2d..27ceae10eea 100644 --- a/projects/storefrontlib/shared/components/ng-select-a11y/ng-select-a11y.directive.spec.ts +++ b/projects/storefrontlib/shared/components/ng-select-a11y/ng-select-a11y.directive.spec.ts @@ -3,6 +3,7 @@ import { ComponentFixture, TestBed } from '@angular/core/testing'; import { By } from '@angular/platform-browser'; import { NgSelectModule } from '@ng-select/ng-select'; import { FeatureConfigService, TranslationService } from '@spartacus/core'; +import { BreakpointService } from '@spartacus/storefront'; import { of } from 'rxjs'; import { NgSelectA11yDirective } from './ng-select-a11y.directive'; import { NgSelectA11yModule } from './ng-select-a11y.module'; @@ -12,16 +13,16 @@ import { NgSelectA11yModule } from './ng-select-a11y.module'; - {{ - val - }}
`, }) class MockComponent { isSearchable: boolean = false; + selected = 1; } class MockFeatureConfigService { @@ -39,6 +40,8 @@ class MockTranslationService { describe('NgSelectA11yDirective', () => { let component: MockComponent; let fixture: ComponentFixture; + let breakpointService: BreakpointService; + let directive: NgSelectA11yDirective; beforeEach(() => { TestBed.configureTestingModule({ @@ -51,8 +54,12 @@ describe('NgSelectA11yDirective', () => { }).compileComponents(); fixture = TestBed.createComponent(MockComponent); - component = fixture.componentInstance; + breakpointService = TestBed.inject(BreakpointService); + const directiveEl = fixture.debugElement.query( + By.directive(NgSelectA11yDirective) + ); + directive = directiveEl.injector.get(NgSelectA11yDirective); }); function getNgSelect(): DebugElement { @@ -65,12 +72,10 @@ describe('NgSelectA11yDirective', () => { const select = getNgSelect().nativeElement; const innerDiv = select.querySelector("[role='combobox']"); - const inputElement = select.querySelector('input'); expect(innerDiv).toBeTruthy(); expect(innerDiv.getAttribute('aria-controls')).toEqual('size-results'); expect(innerDiv.getAttribute('aria-label')).toEqual('Size'); - expect(inputElement.getAttribute('aria-hidden')).toEqual('true'); }); it('should append aria-label to options', (done) => { @@ -91,4 +96,29 @@ describe('NgSelectA11yDirective', () => { done(); }); }); + + it('should append value to aria-label and hide the value element from screen reader on mobile', (done) => { + const isDownSpy = spyOn(breakpointService, 'isDown').and.returnValue( + of(true) + ); + directive['platformId'] = 'browser'; + fixture.detectChanges(); + const ngSelectInstance = getNgSelect().componentInstance; + ngSelectInstance.writeValue(component.selected); + ngSelectInstance.detectChanges(); + + // Wait for the mutation observer to update the aria-label + setTimeout(() => { + const select = getNgSelect().nativeElement; + const valueElement = select.querySelector('.ng-value'); + const divCombobox = select.querySelector("[role='combobox']"); + + expect(valueElement.getAttribute('aria-hidden')).toEqual('true'); + expect(divCombobox.getAttribute('aria-label')).toContain( + `, ${component.selected}` + ); + isDownSpy.and.callThrough(); + done(); + }); + }); }); diff --git a/projects/storefrontlib/shared/components/ng-select-a11y/ng-select-a11y.directive.ts b/projects/storefrontlib/shared/components/ng-select-a11y/ng-select-a11y.directive.ts index 8b63f49f98a..97410186f5c 100644 --- a/projects/storefrontlib/shared/components/ng-select-a11y/ng-select-a11y.directive.ts +++ b/projects/storefrontlib/shared/components/ng-select-a11y/ng-select-a11y.directive.ts @@ -4,17 +4,24 @@ * SPDX-License-Identifier: Apache-2.0 */ +import { isPlatformBrowser } from '@angular/common'; import { AfterViewInit, Directive, ElementRef, HostListener, + Inject, inject, Input, + Optional, + PLATFORM_ID, Renderer2, } from '@angular/core'; import { FeatureConfigService, TranslationService } from '@spartacus/core'; -import { take } from 'rxjs'; +import { filter, take } from 'rxjs'; +import { BREAKPOINT, BreakpointService } from '../../../layout'; + +const ARIA_LABEL = 'aria-label'; @Directive({ selector: '[cxNgSelectA11y]', @@ -41,6 +48,10 @@ export class NgSelectA11yDirective implements AfterViewInit { observer.observe(this.elementRef.nativeElement, { childList: true }); } + @Optional() breakpointService = inject(BreakpointService, { optional: true }); + + @Inject(PLATFORM_ID) protected platformId: Object; + constructor( private renderer: Renderer2, private elementRef: ElementRef @@ -56,7 +67,7 @@ export class NgSelectA11yDirective implements AfterViewInit { const ariaControls = this.cxNgSelectA11y.ariaControls ?? elementId; if (ariaLabel) { - this.renderer.setAttribute(divCombobox, 'aria-label', ariaLabel); + this.renderer.setAttribute(divCombobox, ARIA_LABEL, ariaLabel); } if (ariaControls) { @@ -65,9 +76,21 @@ export class NgSelectA11yDirective implements AfterViewInit { if ( this.featureConfigService.isEnabled('a11yNgSelectMobileReadout') && - inputElement.readOnly + inputElement.readOnly && + isPlatformBrowser(this.platformId) ) { - this.renderer.setAttribute(inputElement, 'aria-hidden', 'true'); + this.breakpointService + ?.isDown(BREAKPOINT.md) + .pipe(filter(Boolean), take(1)) + .subscribe(() => { + const selectObserver = new MutationObserver((changes, observer) => { + this.appendValueToAriaLabel(changes, observer, divCombobox); + }); + selectObserver.observe(this.elementRef.nativeElement, { + subtree: true, + characterData: true, + }); + }); } } @@ -85,11 +108,36 @@ export class NgSelectA11yDirective implements AfterViewInit { options.forEach( (option: HTMLOptionElement, index: string | number) => { const ariaLabel = `${option.innerText}, ${+index + 1} ${translation} ${options.length}`; - this.renderer.setAttribute(option, 'aria-label', ariaLabel); + this.renderer.setAttribute(option, ARIA_LABEL, ariaLabel); } ); }); } observerInstance.disconnect(); } + + /** + * Hides the input value from the screen reader and provides it as part of the aria-label instead. + * This improves the screen reader output on mobile devices. + */ + appendValueToAriaLabel( + _changes: any, + observer: MutationObserver, + divCombobox: HTMLElement + ) { + const valueLabel = + this.elementRef.nativeElement.querySelector('.ng-value-label')?.innerText; + if (valueLabel) { + const comboboxAriaLabel = divCombobox?.getAttribute(ARIA_LABEL) || ''; + const valueElement = + this.elementRef.nativeElement.querySelector('.ng-value'); + this.renderer.setAttribute(valueElement, 'aria-hidden', 'true'); + this.renderer.setAttribute( + divCombobox, + ARIA_LABEL, + comboboxAriaLabel + ', ' + valueLabel + ); + } + observer.disconnect(); + } } From b53ab919ec810e1af0916f9b43dae7b399fdb4d2 Mon Sep 17 00:00:00 2001 From: petarmarkov9449 <166535589+petarmarkov9449@users.noreply.github.com> Date: Thu, 10 Oct 2024 17:22:47 +0200 Subject: [PATCH 13/20] feat: (CXSPA-8024) - Focus issue on remove button at count 2 (#19283) --- .../base/styles/components/_item-counter.scss | 16 ++++++++++ .../feature-toggles/config/feature-toggles.ts | 7 ++++ .../spartacus/spartacus-features.module.ts | 1 + .../item-counter/item-counter.component.html | 24 ++++++++++++++ .../item-counter.component.spec.ts | 32 +++++++++++++++---- .../item-counter/item-counter.component.ts | 1 + .../item-counter/item-counter.module.ts | 10 ++++-- 7 files changed, 82 insertions(+), 9 deletions(-) diff --git a/feature-libs/cart/base/styles/components/_item-counter.scss b/feature-libs/cart/base/styles/components/_item-counter.scss index f6cf1219c9c..bb6057d907a 100644 --- a/feature-libs/cart/base/styles/components/_item-counter.scss +++ b/feature-libs/cart/base/styles/components/_item-counter.scss @@ -13,6 +13,7 @@ -moz-appearance: textfield; } } + &.readonly { button { display: none; @@ -77,8 +78,17 @@ font-weight: var(--cx-font-weight-bold); } + // TODO: The styles for ":disabled" selector should be deleted when "a11yItemCounterFocus" feature flag has been removed &:disabled { color: var(--cx-color-light); + cursor: not-allowed; + } + + @include forFeature('a11yItemCounterFocus') { + &[aria-disabled='true'] { + color: var(--cx-color-light); + cursor: not-allowed; + } } @include forFeature('a11yImproveContrast') { @@ -90,9 +100,15 @@ &:focus { box-shadow: 0 0 0 0; } + // TODO: The styles for ":disabled" selector should be deleted when "a11yItemCounterFocus" feature flag has been removed &:disabled { color: var(--cx-color-dark); } + @include forFeature('a11yItemCounterFocus') { + &[aria-disabled='true'] { + color: var(--cx-color-dark); + } + } } } diff --git a/projects/core/src/features-config/feature-toggles/config/feature-toggles.ts b/projects/core/src/features-config/feature-toggles/config/feature-toggles.ts index 864374fdc58..b801e210391 100644 --- a/projects/core/src/features-config/feature-toggles/config/feature-toggles.ts +++ b/projects/core/src/features-config/feature-toggles/config/feature-toggles.ts @@ -576,6 +576,12 @@ export interface FeatureTogglesInterface { */ a11ySearchBoxFocusOnEscape?: boolean; + /** + * In `ItemCounterComponenet`, Remove button no longer lose focus after activating when count is 2. + * Add button no longer lose focus after activating when count is `max - 1`. + */ + a11yItemCounterFocus?: boolean; + /** * In OCC cart requests, it puts parameters of a cart name and cart description * into a request body, instead of query params. @@ -718,6 +724,7 @@ export const defaultFeatureToggles: Required = { a11yDialogTriggerRefocus: false, a11yAddToWishlistFocus: false, a11ySearchBoxFocusOnEscape: false, + a11yItemCounterFocus: false, occCartNameAndDescriptionInHttpRequestBody: false, cmsBottomHeaderSlotUsingFlexStyles: false, useSiteThemeService: false, diff --git a/projects/storefrontapp/src/app/spartacus/spartacus-features.module.ts b/projects/storefrontapp/src/app/spartacus/spartacus-features.module.ts index b2749c81b2a..3450ac8113d 100644 --- a/projects/storefrontapp/src/app/spartacus/spartacus-features.module.ts +++ b/projects/storefrontapp/src/app/spartacus/spartacus-features.module.ts @@ -375,6 +375,7 @@ if (environment.cpq) { a11yDialogTriggerRefocus: true, a11yAddToWishlistFocus: true, a11ySearchBoxFocusOnEscape: true, + a11yItemCounterFocus: true, cmsBottomHeaderSlotUsingFlexStyles: true, useSiteThemeService: false, enableConsecutiveCharactersPasswordRequirement: true, diff --git a/projects/storefrontlib/shared/components/item-counter/item-counter.component.html b/projects/storefrontlib/shared/components/item-counter/item-counter.component.html index abf99b30313..535ed57cdcb 100644 --- a/projects/storefrontlib/shared/components/item-counter/item-counter.component.html +++ b/projects/storefrontlib/shared/components/item-counter/item-counter.component.html @@ -1,4 +1,16 @@ + + - -