-
Notifications
You must be signed in to change notification settings - Fork 392
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Change product list default page size to 12 (#10937)
chore: Change product list default page size to 12 (#3075)
- Loading branch information
Showing
22 changed files
with
151 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
52 changes: 52 additions & 0 deletions
52
.../migrations/4_0/constructor-deprecations/data/product-list-component.service.migration.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
import { | ||
ACTIVATED_ROUTE, | ||
ANGULAR_ROUTER, | ||
CURRENCY_SERVICE, | ||
LANGUAGE_SERVICE, | ||
PRODUCT_LIST_COMPONENT_SERVICE, | ||
PRODUCT_SEARCH_SERVICE, | ||
ROUTER, | ||
ROUTING_SERVICE, | ||
SPARTACUS_CORE, | ||
SPARTACUS_STOREFRONTLIB, | ||
VIEW_CONFIG, | ||
} from '../../../../shared/constants'; | ||
import { ConstructorDeprecation } from '../../../../shared/utils/file-utils'; | ||
|
||
export const PRODUCT_LIST_COMPONENT_SERVICE_MIGRATION: ConstructorDeprecation = { | ||
// projects/storefrontlib/src/cms-components/product/product-list/container/product-list-component.service.ts | ||
class: PRODUCT_LIST_COMPONENT_SERVICE, | ||
importPath: SPARTACUS_STOREFRONTLIB, | ||
deprecatedParams: [ | ||
{ | ||
className: PRODUCT_SEARCH_SERVICE, | ||
importPath: SPARTACUS_CORE, | ||
}, | ||
{ | ||
className: ROUTING_SERVICE, | ||
importPath: SPARTACUS_CORE, | ||
}, | ||
{ | ||
className: ACTIVATED_ROUTE, | ||
importPath: ANGULAR_ROUTER, | ||
}, | ||
{ | ||
className: CURRENCY_SERVICE, | ||
importPath: SPARTACUS_CORE, | ||
}, | ||
{ | ||
className: LANGUAGE_SERVICE, | ||
importPath: SPARTACUS_CORE, | ||
}, | ||
{ | ||
className: ROUTER, | ||
importPath: ANGULAR_ROUTER, | ||
}, | ||
], | ||
addParams: [ | ||
{ | ||
className: VIEW_CONFIG, | ||
importPath: SPARTACUS_STOREFRONTLIB, | ||
}, | ||
], | ||
}; |
17 changes: 17 additions & 0 deletions
17
.../4_0/methods-and-properties-deprecations/data/product-list-component.service.migration.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import { | ||
DEFAULT_PAGE_SIZE, | ||
PRODUCT_LIST_COMPONENT_SERVICE, | ||
SPARTACUS_STOREFRONTLIB, | ||
} from '../../../../shared/constants'; | ||
import { MethodPropertyDeprecation } from '../../../../shared/utils/file-utils'; | ||
|
||
// projects/storefrontlib/src/cms-components/product/product-list/container/product-list-component.service.ts | ||
|
||
export const PRODUCT_LIST_COMPONENT_SERVICE_MIGRATION: MethodPropertyDeprecation[] = [ | ||
{ | ||
class: PRODUCT_LIST_COMPONENT_SERVICE, | ||
importPath: SPARTACUS_STOREFRONTLIB, | ||
deprecatedNode: DEFAULT_PAGE_SIZE, | ||
comment: `Property '${DEFAULT_PAGE_SIZE}' was removed, to modify default page size use 'view.defaultPageSize' configuration property.`, | ||
}, | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
projects/storefrontapp-e2e-cypress/cypress/helpers/data-configuration.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
...s/product/config/default-scroll-config.ts → ...nts/product/config/default-view-config.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.