@scayle/storefront-core 7.49.3 → 7.49.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md
CHANGED
|
@@ -8,6 +8,11 @@ export declare const slugify: (url: string | undefined) => string;
|
|
|
8
8
|
export declare const getPrice: (variant: Variant) => Price;
|
|
9
9
|
type BadgeLabelParamsKeys = 'isNew' | 'isSoldOut' | 'isOnlineOnly' | 'isSustainable' | 'isPremium';
|
|
10
10
|
type BadgeLabelParams = Partial<Record<BadgeLabelParamsKeys, boolean>>;
|
|
11
|
+
/**
|
|
12
|
+
* getBadgeLabel is deprecated as this is application logic and should be handled per project.
|
|
13
|
+
*
|
|
14
|
+
* @deprecated
|
|
15
|
+
*/
|
|
11
16
|
export declare const getBadgeLabel: (params?: BadgeLabelParams) => string;
|
|
12
17
|
export declare const getOriginalPrice: (price: Price) => number;
|
|
13
18
|
export declare const getTotalAppliedReductions: (price: {
|
|
@@ -4,7 +4,7 @@ import type { BasketResponse } from '@aboutyou/backbone/helpers/BapiClient';
|
|
|
4
4
|
export type BasketCustomData = Pick<CreateBasketItemParameters, 'customData'>;
|
|
5
5
|
export type BasketDisplayData = Partial<Record<BasketItemDisplayDataKey, BaskteItemDisplayDataItem>>;
|
|
6
6
|
export type { BasketItemDisplayData, BaskteItemDisplayDataItem, BasketResponseData, BasketWith, BasketResponse, ItemGroup, };
|
|
7
|
-
export
|
|
7
|
+
export interface AddOrUpdateItemType {
|
|
8
8
|
variantId: number;
|
|
9
9
|
quantity: number;
|
|
10
10
|
displayData?: BasketItemDisplayData;
|
|
@@ -14,7 +14,7 @@ export type AddOrUpdateItemType = {
|
|
|
14
14
|
itemGroup?: ItemGroup;
|
|
15
15
|
includeItemsWithoutProductData?: boolean;
|
|
16
16
|
promotionId?: string | null;
|
|
17
|
-
}
|
|
17
|
+
}
|
|
18
18
|
export interface BasketWithOptions extends BasketWith {
|
|
19
19
|
pricePromotionKey?: string;
|
|
20
20
|
includeItemsWithoutProductData?: boolean;
|
|
@@ -42,8 +42,8 @@ export interface FilterQuery {
|
|
|
42
42
|
term?: Query;
|
|
43
43
|
}
|
|
44
44
|
export type FilterSetup = Record<string, unknown>;
|
|
45
|
-
export
|
|
45
|
+
export interface SanitizeAttributesParams {
|
|
46
46
|
attributes: (AttributeWithValuesFilter | AttributeWithBooleanValueFilter)[];
|
|
47
47
|
filterKeys: string[];
|
|
48
48
|
includedFilters?: string[];
|
|
49
|
-
}
|
|
49
|
+
}
|
|
@@ -2,9 +2,9 @@ import type { GetNavigationParameters } from '@aboutyou/backbone/endpoints/navig
|
|
|
2
2
|
import type { NavigationItems } from '@aboutyou/backbone/types/navigation';
|
|
3
3
|
export type { NavigationItems, NavigationTree, NavigationItemExternal, NavigationItemPage, NavigationItemCategory, } from '@aboutyou/backbone/types/navigation';
|
|
4
4
|
export type NavigationTreeItem = NavigationItems[0];
|
|
5
|
-
export
|
|
5
|
+
export interface FetchNavigationTreesParams {
|
|
6
6
|
params?: GetNavigationParameters;
|
|
7
|
-
}
|
|
7
|
+
}
|
|
8
8
|
export type FetchNavigationTreeByIdParams = FetchNavigationTreesParams & {
|
|
9
9
|
treeId: number;
|
|
10
10
|
};
|
|
@@ -87,8 +87,8 @@ export interface FetchProductsCountParams {
|
|
|
87
87
|
export interface FetchProductsCountResponse {
|
|
88
88
|
count: number;
|
|
89
89
|
}
|
|
90
|
-
export
|
|
90
|
+
export interface ProductSibling {
|
|
91
91
|
id: number;
|
|
92
92
|
image: ProductImage | null;
|
|
93
93
|
colors: Value[];
|
|
94
|
-
}
|
|
94
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@scayle/storefront-core",
|
|
3
|
-
"version": "7.49.
|
|
3
|
+
"version": "7.49.4",
|
|
4
4
|
"description": "Collection of essential utilities to work with the Storefront API",
|
|
5
5
|
"author": "SCAYLE Commerce Engine",
|
|
6
6
|
"license": "MIT",
|
|
@@ -61,7 +61,7 @@
|
|
|
61
61
|
"dependencies": {
|
|
62
62
|
"@aboutyou/backbone": "16.3.0",
|
|
63
63
|
"crypto-js": "4.2.0",
|
|
64
|
-
"jose": "5.
|
|
64
|
+
"jose": "5.3.0",
|
|
65
65
|
"radash": "12.1.0",
|
|
66
66
|
"slugify": "1.6.6",
|
|
67
67
|
"ufo": "1.5.3",
|
|
@@ -71,19 +71,19 @@
|
|
|
71
71
|
"devDependencies": {
|
|
72
72
|
"@scayle/eslint-config-storefront": "4.1.0",
|
|
73
73
|
"@types/crypto-js": "4.2.2",
|
|
74
|
-
"@types/node": "20.12.
|
|
75
|
-
"@types/webpack-env": "1.18.
|
|
76
|
-
"@vitest/coverage-v8": "1.
|
|
74
|
+
"@types/node": "20.12.12",
|
|
75
|
+
"@types/webpack-env": "1.18.5",
|
|
76
|
+
"@vitest/coverage-v8": "1.6.0",
|
|
77
77
|
"dprint": "0.45.1",
|
|
78
|
-
"eslint": "9.
|
|
78
|
+
"eslint": "9.2.0",
|
|
79
79
|
"eslint-formatter-gitlab": "5.1.0",
|
|
80
80
|
"publint": "0.2.7",
|
|
81
|
-
"rimraf": "5.0.
|
|
81
|
+
"rimraf": "5.0.7",
|
|
82
82
|
"ts-node": "10.9.2",
|
|
83
83
|
"typescript": "5.4.5",
|
|
84
84
|
"unbuild": "2.0.0",
|
|
85
85
|
"unstorage": "1.10.2",
|
|
86
|
-
"vitest": "1.
|
|
86
|
+
"vitest": "1.6.0"
|
|
87
87
|
},
|
|
88
88
|
"optionalDependencies": {
|
|
89
89
|
"redis": "4"
|