@retailrocketgroup/retailrocket-edit.reactivation-vue-email-template-render 3.0.377566 → 5.0.384530

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.
Files changed (38) hide show
  1. package/.turbo/turbo-build.log +25 -0
  2. package/dist/assets/index.css +1 -0
  3. package/dist/assets/index.js +379 -0
  4. package/dist/assets/index.js.map +1 -0
  5. package/dist/editReactivationEmailTemplate.d.ts +0 -0
  6. package/dist/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CreateComponentLibrarySectionModalWindow/reactivationComponentSectionItemFactory.d.ts +4 -0
  7. package/dist/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CreateComponentLibrarySectionModalWindow/reactivationEmailComponentFactory.d.ts +4 -0
  8. package/dist/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CustomComponentLibrary/reactivationComponentLibraryFactory.d.ts +4 -0
  9. package/dist/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CustomComponentLibrary/reactivationSectionFactory.d.ts +4 -0
  10. package/dist/implementation/DataSources/ListDataExpressionSource/reactivationEvaluateListExpressionDataSourceFactory.d.ts +8 -0
  11. package/dist/implementation/DataSources/NumberExpressionDataSource/reactivationEvaluateNumberExpressionDataSourceFactory.d.ts +2 -0
  12. package/dist/implementation/DataSources/StringExpressionDataSource/reactivationEvaluateStringExpressionDataSource.d.ts +9 -0
  13. package/dist/implementation/EmailComponentSettingsModifierPlugin/ProductShelfDataSourceExpressionBuilder/ReactivationProductShelfDataSourceExpressionBuilderModal/reactivationProductShelfDataSourceExpressionBuilderModalDepsFactory.d.ts +11 -0
  14. package/dist/implementation/EmailComponentSettingsModifierPlugin/ProductShelfDataSourceExpressionBuilder/reactivationProductShelfDataSourceExpressionBuilderDepsFactory.d.ts +11 -0
  15. package/dist/index.d.ts +1 -0
  16. package/dist/index.html +35 -0
  17. package/env.d.ts +1 -0
  18. package/index.html +1 -2
  19. package/package.json +1 -1
  20. package/src/editReactivationEmailTemplate.ts +409 -0
  21. package/src/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CreateComponentLibrarySectionModalWindow/reactivationComponentSectionItemFactory.ts +30 -0
  22. package/src/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CreateComponentLibrarySectionModalWindow/reactivationEmailComponentFactory.ts +26 -0
  23. package/src/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CustomComponentLibrary/reactivationComponentLibraryFactory.ts +29 -0
  24. package/src/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CustomComponentLibrary/reactivationSectionFactory.ts +34 -0
  25. package/src/implementation/DataSources/ListDataExpressionSource/reactivationEvaluateListExpressionDataSourceFactory.ts +106 -0
  26. package/src/implementation/DataSources/NumberExpressionDataSource/reactivationEvaluateNumberExpressionDataSourceFactory.ts +10 -0
  27. package/src/implementation/DataSources/StringExpressionDataSource/reactivationEvaluateStringExpressionDataSource.ts +56 -0
  28. package/src/implementation/EmailComponentSettingsModifierPlugin/ProductShelfDataSourceExpressionBuilder/ReactivationProductShelfDataSourceExpressionBuilderModal/reactivationProductShelfDataSourceExpressionBuilderModalDepsFactory.ts +127 -0
  29. package/src/implementation/EmailComponentSettingsModifierPlugin/ProductShelfDataSourceExpressionBuilder/reactivationProductShelfDataSourceExpressionBuilderDepsFactory.ts +35 -0
  30. package/src/index.ts +0 -0
  31. package/tsconfig.app.json +19 -0
  32. package/tsconfig.json +14 -0
  33. package/tsconfig.node.json +11 -0
  34. package/tsconfig.test.json +11 -0
  35. package/vite.config.ts +36 -0
  36. package/assets/main.css +0 -1
  37. package/assets/main.js +0 -211
  38. package/favicon.ico +0 -0
@@ -0,0 +1,29 @@
1
+ import type {
2
+ ReactivationListExpressionDataSource,
3
+ } from '@easy-wizzy/retailrocket-reactivation';
4
+ import type {
5
+ ReactivationNumberExpressionDataSource,
6
+ } from '@easy-wizzy/retailrocket-reactivation';
7
+ import type {
8
+ ReactivationStringExpressionDataSource,
9
+ } from '@easy-wizzy/retailrocket-reactivation';
10
+ import {
11
+ reactivationSectionFactory,
12
+ } from '@/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CustomComponentLibrary/reactivationSectionFactory';
13
+ import type {
14
+ ComponentLibrarySection,
15
+ } from '@retailrocket/retailrocket.wysiwyg.bff.v2.apiclients.componentlibrary/main';
16
+ import type {
17
+ CustomComponentLibraryType
18
+ } from '@easy-wizzy/core';
19
+
20
+ export const reactivationComponentLibraryFactory = (
21
+ componentLibrary: Array<ComponentLibrarySection>
22
+ ): CustomComponentLibraryType<
23
+ ReactivationListExpressionDataSource,
24
+ ReactivationNumberExpressionDataSource,
25
+ ReactivationStringExpressionDataSource
26
+ > => {
27
+ return componentLibrary
28
+ .map(section => reactivationSectionFactory(section))
29
+ }
@@ -0,0 +1,34 @@
1
+ import type {
2
+ ReactivationListExpressionDataSource,
3
+ } from '@easy-wizzy/retailrocket-reactivation';
4
+ import type {
5
+ ReactivationNumberExpressionDataSource,
6
+ } from '@easy-wizzy/retailrocket-reactivation';
7
+ import type {
8
+ ReactivationStringExpressionDataSource,
9
+ } from '@easy-wizzy/retailrocket-reactivation';
10
+
11
+
12
+ import type {
13
+ ComponentLibrarySection,
14
+ } from '@retailrocket/retailrocket.wysiwyg.bff.v2.apiclients.componentlibrary/main';
15
+ import {
16
+ reactivationComponentSectionItemFactory,
17
+ } from '@/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CreateComponentLibrarySectionModalWindow/reactivationComponentSectionItemFactory';
18
+ import type { CustomComponentSectionType } from '@easy-wizzy/core';
19
+
20
+ export const reactivationSectionFactory = (
21
+ section: ComponentLibrarySection,
22
+ ): CustomComponentSectionType<
23
+ ReactivationListExpressionDataSource,
24
+ ReactivationNumberExpressionDataSource,
25
+ ReactivationStringExpressionDataSource
26
+ > => {
27
+ return {
28
+ sectionId: section.sectionId,
29
+ sectionName: section.sectionName,
30
+ componentList: section
31
+ .sectionItems
32
+ .map(component => reactivationComponentSectionItemFactory(component)),
33
+ };
34
+ };
@@ -0,0 +1,106 @@
1
+ import { type ReactivationListExpressionDataSource } from '@easy-wizzy/retailrocket-reactivation';
2
+ import { reactivationListExpressionDataSourceMatcher } from '@easy-wizzy/retailrocket-reactivation';
3
+ import type {
4
+ DataListType
5
+ } from '@easy-wizzy/core';
6
+ import type { ListExpressionDataSourceBffClient } from '@easy-wizzy/common-app';
7
+ import type { ListExpressionDataSourceEvaluatorDelegate } from '@easy-wizzy/core';
8
+ import { getProductList } from '@easy-wizzy/common-app';
9
+ import { getRelatedProducts } from '@easy-wizzy/common-app';
10
+ import { getAlternativeProducts } from '@easy-wizzy/common-app';
11
+ import { getPopularProductsInCategories } from '@easy-wizzy/common-app';
12
+ import { getPopularProducts } from '@easy-wizzy/common-app';
13
+ import type { Product } from '@retailrocket/retailrocket.wysiwyg.bff.v2.apiclients.listexpressiondatasource';
14
+ import { stockIdFactory } from '@easy-wizzy/common-app';
15
+ import { getLatestProducts } from '@easy-wizzy/common-app';
16
+ import { getSaleByPopularProducts } from '@easy-wizzy/common-app';
17
+ import { getSaleByLatestProducts } from '@easy-wizzy/common-app';
18
+
19
+ export const reactivationEvaluateListExpressionDataSourceFactory = (arg: {
20
+ partnerId: string;
21
+ listExpressionDataSourceBffClient: ListExpressionDataSourceBffClient;
22
+ customerStockId: string | undefined;
23
+ }): ListExpressionDataSourceEvaluatorDelegate<ReactivationListExpressionDataSource> => {
24
+ let productCache: { [key: string]: Product } = {};
25
+
26
+ return (asyncDataSource: ReactivationListExpressionDataSource) =>
27
+ reactivationListExpressionDataSourceMatcher(asyncDataSource).Match<Promise<DataListType>>({
28
+ ProductList: ({ ProductIds, StockSource }) =>
29
+ getProductList({
30
+ partnerId: arg.partnerId,
31
+ productIDs: ProductIds,
32
+ stockId: stockIdFactory({
33
+ stockSource: StockSource,
34
+ customerStockId: arg.customerStockId,
35
+ }),
36
+ productCache: productCache,
37
+ getProductsByIDsHttpClient: arg.listExpressionDataSourceBffClient.postGetProductsByIds,
38
+ }),
39
+ RelatedProductsFor: ({ ProductIds, StockSource }) =>
40
+ getRelatedProducts({
41
+ partnerId: arg.partnerId,
42
+ productIDs: ProductIds,
43
+ stockId: stockIdFactory({
44
+ stockSource: StockSource,
45
+ customerStockId: arg.customerStockId
46
+ }),
47
+ getRelatedProducts: arg.listExpressionDataSourceBffClient.postGetRelatedRecommendations,
48
+ }),
49
+ AlternativeProductsFor: ({ ProductIds, StockSource }) =>
50
+ getAlternativeProducts({
51
+ partnerId: arg.partnerId,
52
+ productIDs: ProductIds,
53
+ stockId: stockIdFactory({
54
+ stockSource: StockSource,
55
+ customerStockId: arg.customerStockId,
56
+ }),
57
+ getAlternativeProductsHttpClient: arg.listExpressionDataSourceBffClient.postGetAlternativeRecommendations,
58
+ }),
59
+ PopularProductsInCategories: ({ CategoryIds, StockSource }) =>
60
+ getPopularProductsInCategories({
61
+ partnerId: arg.partnerId,
62
+ categoryIds: CategoryIds,
63
+ stockId: stockIdFactory({
64
+ stockSource: StockSource,
65
+ customerStockId: arg.customerStockId,
66
+ }),
67
+ getPopularProductsInCategoriesHttpClient: arg.listExpressionDataSourceBffClient.postGetPopularInCategoriesRecommendations,
68
+ }),
69
+ Popular: ({ StockSource }) =>
70
+ getPopularProducts({
71
+ partnerId: arg.partnerId,
72
+ stockId: stockIdFactory({
73
+ stockSource: StockSource,
74
+ customerStockId: arg.customerStockId,
75
+ }),
76
+ getPopularProductsHttpClient: arg.listExpressionDataSourceBffClient.postGetPopularRecommendations,
77
+ }),
78
+ Latest: ({ StockSource }) =>
79
+ getLatestProducts({
80
+ partnerId: arg.partnerId,
81
+ stockId: stockIdFactory({
82
+ stockSource: StockSource,
83
+ customerStockId: arg.customerStockId,
84
+ }),
85
+ getLatestProductsHttpClient: arg.listExpressionDataSourceBffClient.postGetLatestRecommendations,
86
+ }),
87
+ SaleByPopular: ({ StockSource }) =>
88
+ getSaleByPopularProducts({
89
+ partnerId: arg.partnerId,
90
+ stockId: stockIdFactory({
91
+ stockSource: StockSource,
92
+ customerStockId: arg.customerStockId,
93
+ }),
94
+ getSaleByPopularProductsHttpClient: arg.listExpressionDataSourceBffClient.postGetSaleByPopularRecommendations,
95
+ }),
96
+ SaleByLatest: ({ StockSource }) =>
97
+ getSaleByLatestProducts({
98
+ partnerId: arg.partnerId,
99
+ stockId: stockIdFactory({
100
+ stockSource: StockSource,
101
+ customerStockId: arg.customerStockId,
102
+ }),
103
+ getSaleByLatestProductsHttpClient: arg.listExpressionDataSourceBffClient.postGetSaleByLatestRecommendations,
104
+ }),
105
+ });
106
+ };
@@ -0,0 +1,10 @@
1
+ import type {
2
+ NumberExpressionDataSourceEvaluatorDelegate
3
+ } from '@easy-wizzy/core';
4
+
5
+ export const reactivationEvaluateNumberExpressionDataSourceFactory = <
6
+ TNumberExpressionDataSource
7
+ >():
8
+ NumberExpressionDataSourceEvaluatorDelegate<TNumberExpressionDataSource> => {
9
+ return () => Promise.resolve(0);
10
+ }
@@ -0,0 +1,56 @@
1
+ import type {
2
+ ReactivationStringExpressionDataSource,
3
+ } from '@easy-wizzy/retailrocket-reactivation';
4
+ import type {
5
+ ReactivationListExpressionDataSource
6
+ } from '@easy-wizzy/retailrocket-reactivation';
7
+ import type {
8
+ ReactivationNumberExpressionDataSource
9
+ } from '@easy-wizzy/retailrocket-reactivation';
10
+ import type {
11
+ StringExpressionDataSourceEvaluatorDelegate
12
+ } from '@easy-wizzy/core';
13
+ import type { ContactCustomData } from '@easy-wizzy/retailrocket-common';
14
+ import {
15
+ reactivationStringExpressionDataSourceMatcher
16
+ } from '@easy-wizzy/retailrocket-reactivation';
17
+ import type {
18
+ ProductImageUrlBuilderExpressionEvaluatorDelegate
19
+ } from '@easy-wizzy/common-app';
20
+ import type {
21
+ DataType
22
+ } from '@easy-wizzy/core';
23
+ import type { NextCouponFromBatchType } from '@easy-wizzy/retailrocket-common';
24
+
25
+ export const reactivationStringExpressionDataSourceEvaluatorFactory = (arg: {
26
+ productImageUrlBuilderExpressionEvaluator: ProductImageUrlBuilderExpressionEvaluatorDelegate<
27
+ ReactivationListExpressionDataSource,
28
+ ReactivationNumberExpressionDataSource
29
+ >
30
+ contactCustomData: ContactCustomData
31
+ nextCouponFromBatch: NextCouponFromBatchType
32
+ }): StringExpressionDataSourceEvaluatorDelegate<
33
+ ReactivationStringExpressionDataSource
34
+ > => {
35
+ const reactivationContactCustomData = arg.contactCustomData;
36
+
37
+ return (a: {
38
+ stringExpressionDataSource: ReactivationStringExpressionDataSource,
39
+ context: DataType
40
+ }) => reactivationStringExpressionDataSourceMatcher(
41
+ a.stringExpressionDataSource
42
+ )
43
+ .Match({
44
+ StringFromContactCustomData: (x) => Promise.resolve(reactivationContactCustomData[x.FieldName] as string),
45
+ StringFromContactCustomDataWithFallback: (x) => Promise.resolve(
46
+ x.FieldName in reactivationContactCustomData && typeof reactivationContactCustomData[x.FieldName] === 'string'
47
+ ? reactivationContactCustomData[x.FieldName] as string
48
+ : x.FallbackValue
49
+ ),
50
+ ProductImageUrlBuilderExpression: e => arg.productImageUrlBuilderExpressionEvaluator({
51
+ expression: e,
52
+ context: a.context
53
+ }),
54
+ NextCouponFromBatch: () => Promise.resolve('Coupon')
55
+ });
56
+ }
@@ -0,0 +1,127 @@
1
+ import type { LocaleKey } from '@easy-wizzy/core';
2
+ import type {
3
+ ReactivationProductShelfDataSourceExpressionBuilderModalDeps
4
+ } from '@easy-wizzy/retailrocket-reactivation';
5
+ import {
6
+ productListComposerModalWindowDepsFactory
7
+ } from '@easy-wizzy/common-app';
8
+ import {
9
+ categoryListComposerModalWindowDepsFactory
10
+ } from '@easy-wizzy/common-app';
11
+ import {
12
+ alternativeProductListShelfBuilderDepsFactory
13
+ } from '@easy-wizzy/common-app';
14
+ import {
15
+ relatedProductListShelfBuilderDepsFactory
16
+ } from '@easy-wizzy/common-app';
17
+ import {
18
+ productListShelfBuilderDepsFactory
19
+ } from '@easy-wizzy/common-app';
20
+ import {
21
+ popularFromCategoryListShelfBuilderDepsFactory
22
+ } from '@easy-wizzy/common-app';
23
+ import {
24
+ popularProductListShelfBuilderDepsFactory
25
+ } from '@easy-wizzy/common-app';
26
+ import type { ProductShelfBuilderModalWindowBffClient } from '@easy-wizzy/common-app';
27
+
28
+ import type { ProductPickerModalWindowBffClient } from '@easy-wizzy/common-app';
29
+ import {
30
+ latestProductListShelfBuilderDepsFactory
31
+ } from '@easy-wizzy/common-app';
32
+ import {
33
+ saleByPopularProductListShelfBuilderDepsFactory
34
+ } from '@easy-wizzy/common-app';
35
+ import {
36
+ saleByLatestProductListShelfBuilderDepsFactory
37
+ } from '@easy-wizzy/common-app';
38
+ import type {
39
+ ProductCategoryPickerModalWindowBffClient
40
+ } from '@easy-wizzy/common-app';
41
+
42
+ export const reactivationProductShelfDataSourceExpressionBuilderModalDepsFactory = (
43
+ arg: {
44
+ localeKey: LocaleKey;
45
+ partnerId: string,
46
+ customerStockId: string | undefined,
47
+ productShelfBuilderModalWindowBffClient: ProductShelfBuilderModalWindowBffClient,
48
+ productCategoryPickerModalWindowBffClient: ProductCategoryPickerModalWindowBffClient,
49
+ productPickerModalWindowBffClient: ProductPickerModalWindowBffClient,
50
+ }
51
+ ): ReactivationProductShelfDataSourceExpressionBuilderModalDeps => {
52
+
53
+ const productCache = {};
54
+ const categoryCache = {};
55
+
56
+ const productListComposerModalWindowDeps = productListComposerModalWindowDepsFactory({
57
+ localeKey: arg.localeKey,
58
+ partnerId: arg.partnerId,
59
+ customerStockId: arg.customerStockId,
60
+ productPickerModalWindowBffClient: arg.productPickerModalWindowBffClient,
61
+ });
62
+
63
+ return {
64
+ localeKey: arg.localeKey,
65
+ ProductListComposerModalWindowDeps: productListComposerModalWindowDeps,
66
+ CategoryListComposerModalWindowDeps: categoryListComposerModalWindowDepsFactory({
67
+ localeKey: arg.localeKey,
68
+ partnerId: arg.partnerId,
69
+ productCategoryPickerModalWindowBffClient: arg.productCategoryPickerModalWindowBffClient
70
+ }),
71
+ AlternativeProductListShelfBuilderDeps: alternativeProductListShelfBuilderDepsFactory({
72
+ localeKey: arg.localeKey,
73
+ partnerId: arg.partnerId,
74
+ customerStockId: arg.customerStockId,
75
+ productCache: productCache,
76
+ getProductsByIDsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetProductsByIds,
77
+ getAllStockIdsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetAllStockIds,
78
+ productListComposerModalWindowDeps: productListComposerModalWindowDeps
79
+ }),
80
+ RelatedProductListShelfBuilderDeps: relatedProductListShelfBuilderDepsFactory({
81
+ localeKey: arg.localeKey,
82
+ partnerId: arg.partnerId,
83
+ customerStockId: arg.customerStockId,
84
+ productCache: productCache,
85
+ getProductsByIDsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetProductsByIds,
86
+ getAllStockIdsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetAllStockIds,
87
+ productListComposerModalWindowDeps: productListComposerModalWindowDeps
88
+ }),
89
+ ProductListShelfBuilderDeps: productListShelfBuilderDepsFactory({
90
+ localeKey: arg.localeKey,
91
+ partnerId: arg.partnerId,
92
+ customerStockId: arg.customerStockId,
93
+ productCache: productCache,
94
+ getProductsByIDsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetProductsByIds,
95
+ getAllStockIdsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetAllStockIds,
96
+ productListComposerModalWindowDeps: productListComposerModalWindowDeps
97
+ }),
98
+ PopularFromCategoryListShelfBuilderDeps: popularFromCategoryListShelfBuilderDepsFactory({
99
+ localeKey: arg.localeKey,
100
+ partnerId: arg.partnerId,
101
+ categoryCache: categoryCache,
102
+ getAllStockIdsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetAllStockIds,
103
+ getCategoriesByIDsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetProductCategoriesByIds,
104
+ productCategoryPickerModalWindowBffClient: arg.productCategoryPickerModalWindowBffClient
105
+ }),
106
+ PopularProductListShelfBuilderDeps: popularProductListShelfBuilderDepsFactory({
107
+ localeKey: arg.localeKey,
108
+ partnerId: arg.partnerId,
109
+ getAllStockIdsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetAllStockIds
110
+ }),
111
+ LatestProductListShelfBuilderDeps: latestProductListShelfBuilderDepsFactory({
112
+ localeKey: arg.localeKey,
113
+ partnerId: arg.partnerId,
114
+ getAllStockIdsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetAllStockIds
115
+ }),
116
+ SaleByPopularProductListShelfBuilderDeps: saleByPopularProductListShelfBuilderDepsFactory({
117
+ localeKey: arg.localeKey,
118
+ partnerId: arg.partnerId,
119
+ getAllStockIdsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetAllStockIds
120
+ }),
121
+ SaleByLatestProductListShelfBuilderDeps: saleByLatestProductListShelfBuilderDepsFactory({
122
+ localeKey: arg.localeKey,
123
+ partnerId: arg.partnerId,
124
+ getAllStockIdsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetAllStockIds
125
+ })
126
+ }
127
+ }
@@ -0,0 +1,35 @@
1
+ import type { LocaleKey } from '@easy-wizzy/core';
2
+ import type {
3
+ ReactivationProductShelfDataSourceExpressionBuilderDeps
4
+ } from '@easy-wizzy/retailrocket-reactivation';
5
+ import {
6
+ reactivationProductShelfDataSourceExpressionBuilderModalDepsFactory
7
+ } from '@/implementation/EmailComponentSettingsModifierPlugin/ProductShelfDataSourceExpressionBuilder/ReactivationProductShelfDataSourceExpressionBuilderModal/reactivationProductShelfDataSourceExpressionBuilderModalDepsFactory';
8
+ import type { ProductShelfBuilderModalWindowBffClient } from '@easy-wizzy/common-app';
9
+
10
+ import type { ProductPickerModalWindowBffClient } from '@easy-wizzy/common-app';
11
+ import type {
12
+ ProductCategoryPickerModalWindowBffClient
13
+ } from '@easy-wizzy/common-app';
14
+
15
+ export const reactivationProductShelfDataSourceExpressionBuilderDepsFactory = (
16
+ arg: {
17
+ localeKey: LocaleKey;
18
+ partnerId: string,
19
+ customerStockId: string | undefined,
20
+ productShelfBuilderModalWindowBffClient: ProductShelfBuilderModalWindowBffClient,
21
+ productCategoryPickerModalWindowBffClient: ProductCategoryPickerModalWindowBffClient,
22
+ productPickerModalWindowBffClient: ProductPickerModalWindowBffClient
23
+ }
24
+ ): ReactivationProductShelfDataSourceExpressionBuilderDeps => {
25
+ return {
26
+ reactivationProductShelfDataSourceExpressionBuilderModalDeps: reactivationProductShelfDataSourceExpressionBuilderModalDepsFactory({
27
+ localeKey: arg.localeKey,
28
+ partnerId: arg.partnerId,
29
+ customerStockId: arg.customerStockId,
30
+ productShelfBuilderModalWindowBffClient: arg.productShelfBuilderModalWindowBffClient,
31
+ productCategoryPickerModalWindowBffClient: arg.productCategoryPickerModalWindowBffClient,
32
+ productPickerModalWindowBffClient: arg.productPickerModalWindowBffClient
33
+ })
34
+ }
35
+ }
package/src/index.ts ADDED
File without changes
@@ -0,0 +1,19 @@
1
+ {
2
+ "extends": "@easy-wizzy/ts-config/app.json",
3
+ "include": [
4
+ "env.d.ts",
5
+ "src/**/*.ts",
6
+ "src/**/*.vue"
7
+ ],
8
+ "exclude": [
9
+ "src/**/*.spec.ts"
10
+ ],
11
+ "compilerOptions": {
12
+ "tsBuildInfoFile": "./node_modules/.tmp/tsconfig.app.tsbuildinfo",
13
+ "paths": {
14
+ "@/*": [
15
+ "./src/*"
16
+ ]
17
+ }
18
+ }
19
+ }
package/tsconfig.json ADDED
@@ -0,0 +1,14 @@
1
+ {
2
+ "files": [],
3
+ "references": [
4
+ {
5
+ "path": "./tsconfig.node.json"
6
+ },
7
+ {
8
+ "path": "./tsconfig.app.json"
9
+ },
10
+ {
11
+ "path": "./tsconfig.test.json"
12
+ }
13
+ ]
14
+ }
@@ -0,0 +1,11 @@
1
+ {
2
+ "extends": "@easy-wizzy/ts-config/node.json",
3
+ "include": [
4
+ "vite.config.*",
5
+ "vitest.config.*",
6
+ "eslint.config.*"
7
+ ],
8
+ "compilerOptions": {
9
+ "tsBuildInfoFile": "./node_modules/.tmp/tsconfig.node.tsbuildinfo"
10
+ }
11
+ }
@@ -0,0 +1,11 @@
1
+ {
2
+ "extends": "./tsconfig.app.json",
3
+ "include": [
4
+ "env.d.ts",
5
+ "src/**/*.spec.ts"
6
+ ],
7
+ "exclude": [],
8
+ "compilerOptions": {
9
+ "tsBuildInfoFile": "./node_modules/.tmp/tsconfig.test.tsbuildinfo"
10
+ }
11
+ }
package/vite.config.ts ADDED
@@ -0,0 +1,36 @@
1
+ import vue from '@vitejs/plugin-vue';
2
+ import { fileURLToPath, URL } from 'node:url';
3
+ import { defineConfig } from 'vite';
4
+ import dts from 'vite-plugin-dts';
5
+
6
+ export default defineConfig({
7
+ build: {
8
+ rollupOptions: {
9
+ input: fileURLToPath(new URL('./index.html', import.meta.url)),
10
+ output: {
11
+ entryFileNames: 'assets/[name].js',
12
+ chunkFileNames: 'assets/[name].js',
13
+ assetFileNames: 'assets/[name].[ext]',
14
+ },
15
+ },
16
+ sourcemap: true,
17
+ },
18
+ plugins: [
19
+ vue({
20
+ template: {
21
+ compilerOptions: {
22
+ isCustomElement: tag => ['center'].includes(tag)
23
+ }
24
+ }
25
+ }),
26
+ dts({
27
+ insertTypesEntry: true,
28
+ tsconfigPath: './tsconfig.app.json',
29
+ })
30
+ ],
31
+ resolve: {
32
+ alias: {
33
+ '@': fileURLToPath(new URL('./src', import.meta.url)),
34
+ },
35
+ },
36
+ })