@retailrocketgroup/retailrocket-edit.multicast-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/editMulticastEmailTemplate.d.ts +0 -0
  6. package/dist/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CreateComponentLibrarySectionModalWindow/multicastComponentSectionItemFactory.d.ts +4 -0
  7. package/dist/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CreateComponentLibrarySectionModalWindow/multicastEmailComponentFactory.d.ts +4 -0
  8. package/dist/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CustomComponentLibrary/multicastComponentLibraryFactory.d.ts +4 -0
  9. package/dist/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CustomComponentLibrary/multicastSectionFactory.d.ts +4 -0
  10. package/dist/implementation/DataSources/ListDataExpressionSource/multicastEvaluateListExpressionDataSourceFactory.d.ts +8 -0
  11. package/dist/implementation/DataSources/NumberExpressionDataSource/multicastNumberExpressionDataSourceEvaluatorFactory.d.ts +6 -0
  12. package/dist/implementation/DataSources/StringExpressionDataSource/multicastEvaluateStringExpressionDataSource.d.ts +9 -0
  13. package/dist/implementation/EmailComponentSettingsModifierPlugin/ProductShelfDataSourceExpressionBuilder/MulticastProductShelfDataSourceExpressionBuilderModal/multicastProductShelfDataSourceExpressionBuilderModalDepsFactory.d.ts +11 -0
  14. package/dist/implementation/EmailComponentSettingsModifierPlugin/ProductShelfDataSourceExpressionBuilder/multicastProductShelfDataSourceExpressionBuilderDepsFactory.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/editMulticastEmailTemplate.ts +413 -0
  21. package/src/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CreateComponentLibrarySectionModalWindow/multicastComponentSectionItemFactory.ts +30 -0
  22. package/src/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CreateComponentLibrarySectionModalWindow/multicastEmailComponentFactory.ts +26 -0
  23. package/src/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CustomComponentLibrary/multicastComponentLibraryFactory.ts +29 -0
  24. package/src/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CustomComponentLibrary/multicastSectionFactory.ts +32 -0
  25. package/src/implementation/DataSources/ListDataExpressionSource/multicastEvaluateListExpressionDataSourceFactory.ts +137 -0
  26. package/src/implementation/DataSources/NumberExpressionDataSource/multicastNumberExpressionDataSourceEvaluatorFactory.ts +37 -0
  27. package/src/implementation/DataSources/StringExpressionDataSource/multicastEvaluateStringExpressionDataSource.ts +56 -0
  28. package/src/implementation/EmailComponentSettingsModifierPlugin/ProductShelfDataSourceExpressionBuilder/MulticastProductShelfDataSourceExpressionBuilderModal/multicastProductShelfDataSourceExpressionBuilderModalDepsFactory.ts +127 -0
  29. package/src/implementation/EmailComponentSettingsModifierPlugin/ProductShelfDataSourceExpressionBuilder/multicastProductShelfDataSourceExpressionBuilderDepsFactory.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 +37 -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
+ MulticastListExpressionDataSource,
3
+ } from '@easy-wizzy/retailrocket-multicast';
4
+ import type {
5
+ MulticastNumberExpressionDataSource,
6
+ } from '@easy-wizzy/retailrocket-multicast';
7
+ import type {
8
+ MulticastStringExpressionDataSource,
9
+ } from '@easy-wizzy/retailrocket-multicast';
10
+ import {
11
+ multicastSectionFactory,
12
+ } from '@/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CustomComponentLibrary/multicastSectionFactory';
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 multicastComponentLibraryFactory = (
21
+ componentLibrary: Array<ComponentLibrarySection>
22
+ ): CustomComponentLibraryType<
23
+ MulticastListExpressionDataSource,
24
+ MulticastNumberExpressionDataSource,
25
+ MulticastStringExpressionDataSource
26
+ > => {
27
+ return componentLibrary
28
+ .map(section => multicastSectionFactory(section))
29
+ }
@@ -0,0 +1,32 @@
1
+ import type {
2
+ MulticastListExpressionDataSource
3
+ } from '@easy-wizzy/retailrocket-multicast';
4
+ import type {
5
+ MulticastNumberExpressionDataSource
6
+ } from '@easy-wizzy/retailrocket-multicast';
7
+ import type {
8
+ MulticastStringExpressionDataSource
9
+ } from '@easy-wizzy/retailrocket-multicast';
10
+ import type {
11
+ ComponentLibrarySection,
12
+ } from '@retailrocket/retailrocket.wysiwyg.bff.v2.apiclients.componentlibrary/main';
13
+ import {
14
+ multicastComponentSectionItemFactory,
15
+ } from '@/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CreateComponentLibrarySectionModalWindow/multicastComponentSectionItemFactory';
16
+ import type { CustomComponentSectionType } from '@easy-wizzy/core';
17
+
18
+ export const multicastSectionFactory = (
19
+ section: ComponentLibrarySection,
20
+ ): CustomComponentSectionType<
21
+ MulticastListExpressionDataSource,
22
+ MulticastNumberExpressionDataSource,
23
+ MulticastStringExpressionDataSource
24
+ > => {
25
+ return {
26
+ sectionId: section.sectionId,
27
+ sectionName: section.sectionName,
28
+ componentList: section
29
+ .sectionItems
30
+ .map(component => multicastComponentSectionItemFactory(component)),
31
+ };
32
+ };
@@ -0,0 +1,137 @@
1
+ import {
2
+ type MulticastListExpressionDataSource,
3
+ } from '@easy-wizzy/retailrocket-multicast';
4
+ import {
5
+ multicastListExpressionDataSourceMatcher,
6
+ } from '@easy-wizzy/retailrocket-multicast';
7
+ import type {
8
+ DataListType
9
+ } from '@easy-wizzy/core';
10
+ import type { ListExpressionDataSourceBffClient } from '@easy-wizzy/common-app';
11
+ import type {
12
+ ListExpressionDataSourceEvaluatorDelegate
13
+ } from '@easy-wizzy/core';
14
+ import { getProductList } from '@easy-wizzy/common-app';
15
+ import { getRelatedProducts } from '@easy-wizzy/common-app';
16
+ import { getAlternativeProducts } from '@easy-wizzy/common-app';
17
+ import {
18
+ getPopularProductsInCategories,
19
+ } from '@easy-wizzy/common-app';
20
+ import { getPopularProducts } from '@easy-wizzy/common-app';
21
+ import type { Product } from '@retailrocket/retailrocket.wysiwyg.bff.v2.apiclients.listexpressiondatasource';
22
+ import { stockIdFactory } from '@easy-wizzy/common-app';
23
+ import { getLatestProducts } from '@easy-wizzy/common-app';
24
+ import { getSaleByPopularProducts } from '@easy-wizzy/common-app';
25
+ import { getSaleByLatestProducts } from '@easy-wizzy/common-app';
26
+
27
+
28
+ export const multicastEvaluateListExpressionDataSourceFactory = (arg: {
29
+ partnerId: string,
30
+ listExpressionDataSourceBffClient: ListExpressionDataSourceBffClient,
31
+ customerStockId: string | undefined
32
+ }): ListExpressionDataSourceEvaluatorDelegate<
33
+ MulticastListExpressionDataSource
34
+ > => {
35
+ let productCache: { [key: string]: Product } = {};
36
+
37
+ return (asyncDataSource: MulticastListExpressionDataSource) =>
38
+ multicastListExpressionDataSourceMatcher(asyncDataSource)
39
+ .Match<Promise<DataListType>>({
40
+ ProductList: ({
41
+ ProductIds,
42
+ StockSource
43
+ }) => getProductList({
44
+ partnerId: arg.partnerId,
45
+ productIDs: ProductIds,
46
+ stockId: stockIdFactory({
47
+ stockSource: StockSource,
48
+ customerStockId: arg.customerStockId
49
+ }),
50
+ productCache: productCache,
51
+ getProductsByIDsHttpClient: arg
52
+ .listExpressionDataSourceBffClient
53
+ .postGetProductsByIds
54
+ }),
55
+ RelatedProductsFor: ({
56
+ ProductIds,
57
+ StockSource
58
+ }) => getRelatedProducts({
59
+ partnerId: arg.partnerId,
60
+ productIDs: ProductIds,
61
+ stockId: stockIdFactory({
62
+ stockSource: StockSource,
63
+ customerStockId: arg.customerStockId
64
+ }),
65
+ getRelatedProducts: arg
66
+ .listExpressionDataSourceBffClient
67
+ .postGetRelatedRecommendations
68
+ }),
69
+ AlternativeProductsFor: ({
70
+ ProductIds,
71
+ StockSource
72
+ }) => getAlternativeProducts({
73
+ partnerId :arg.partnerId,
74
+ productIDs: ProductIds,
75
+ stockId: stockIdFactory({
76
+ stockSource: StockSource,
77
+ customerStockId: arg.customerStockId
78
+ }),
79
+ getAlternativeProductsHttpClient: arg
80
+ .listExpressionDataSourceBffClient
81
+ .postGetAlternativeRecommendations
82
+ }),
83
+ PopularProductsInCategories: ({
84
+ CategoryIds,
85
+ StockSource
86
+ }) => getPopularProductsInCategories({
87
+ partnerId: arg.partnerId,
88
+ categoryIds: CategoryIds,
89
+ stockId: stockIdFactory({
90
+ stockSource: StockSource,
91
+ customerStockId: arg.customerStockId
92
+ }),
93
+ getPopularProductsInCategoriesHttpClient: arg
94
+ .listExpressionDataSourceBffClient
95
+ .postGetPopularInCategoriesRecommendations
96
+ }),
97
+ Popular: ({
98
+ StockSource
99
+ }) => getPopularProducts({
100
+ partnerId: arg.partnerId,
101
+ stockId: stockIdFactory({
102
+ stockSource: StockSource,
103
+ customerStockId: arg.customerStockId
104
+ }),
105
+ getPopularProductsHttpClient: arg
106
+ .listExpressionDataSourceBffClient
107
+ .postGetPopularRecommendations
108
+ }),
109
+ Latest: ({ StockSource }) =>
110
+ getLatestProducts({
111
+ partnerId: arg.partnerId,
112
+ stockId: stockIdFactory({
113
+ stockSource: StockSource,
114
+ customerStockId: arg.customerStockId,
115
+ }),
116
+ getLatestProductsHttpClient: arg.listExpressionDataSourceBffClient.postGetLatestRecommendations,
117
+ }),
118
+ SaleByPopular: ({ StockSource }) =>
119
+ getSaleByPopularProducts({
120
+ partnerId: arg.partnerId,
121
+ stockId: stockIdFactory({
122
+ stockSource: StockSource,
123
+ customerStockId: arg.customerStockId,
124
+ }),
125
+ getSaleByPopularProductsHttpClient: arg.listExpressionDataSourceBffClient.postGetSaleByPopularRecommendations,
126
+ }),
127
+ SaleByLatest: ({ StockSource }) =>
128
+ getSaleByLatestProducts({
129
+ partnerId: arg.partnerId,
130
+ stockId: stockIdFactory({
131
+ stockSource: StockSource,
132
+ customerStockId: arg.customerStockId,
133
+ }),
134
+ getSaleByLatestProductsHttpClient: arg.listExpressionDataSourceBffClient.postGetSaleByLatestRecommendations,
135
+ }),
136
+ })
137
+ }
@@ -0,0 +1,37 @@
1
+ import type {
2
+ NumberExpressionDataSourceEvaluatorDelegate
3
+ } from '@easy-wizzy/core';
4
+ import type {
5
+ MulticastNumberExpressionDataSource
6
+ } from '@easy-wizzy/retailrocket-multicast';
7
+ import type {
8
+ DataType
9
+ } from '@easy-wizzy/core';
10
+ import {
11
+ multicastNumberExpressionDataSourceMatcher
12
+ } from '@easy-wizzy/retailrocket-multicast';
13
+ import type { ContactCustomData } from '@easy-wizzy/retailrocket-common';
14
+
15
+ export const multicastNumberExpressionDataSourceEvaluatorFactory = (arg: {
16
+ contactCustomData: ContactCustomData
17
+ }):
18
+ NumberExpressionDataSourceEvaluatorDelegate<MulticastNumberExpressionDataSource> => {
19
+ const multicastContactCustomData = arg.contactCustomData;
20
+
21
+ return (a: {
22
+ numberExpressionDataSource: MulticastNumberExpressionDataSource,
23
+ context: DataType
24
+ }) => multicastNumberExpressionDataSourceMatcher(
25
+ a.numberExpressionDataSource
26
+ )
27
+ .Match({
28
+ NumberFromContactCustomData: (x) => Promise.resolve(multicastContactCustomData[x.FieldName] as number),
29
+ NumberFromContactCustomDataWithFallback: (x) => Promise
30
+ .resolve(
31
+ x.FieldName in multicastContactCustomData
32
+ && typeof multicastContactCustomData[x.FieldName] === 'number'
33
+ ? multicastContactCustomData[x.FieldName] as number
34
+ : x.FallbackValue
35
+ )
36
+ })
37
+ }
@@ -0,0 +1,56 @@
1
+ import type {
2
+ MulticastStringExpressionDataSource,
3
+ } from '@easy-wizzy/retailrocket-multicast';
4
+ import type {
5
+ MulticastListExpressionDataSource
6
+ } from '@easy-wizzy/retailrocket-multicast';
7
+ import type {
8
+ MulticastNumberExpressionDataSource
9
+ } from '@easy-wizzy/retailrocket-multicast';
10
+ import type {
11
+ StringExpressionDataSourceEvaluatorDelegate
12
+ } from '@easy-wizzy/core';
13
+ import type { ContactCustomData } from '@easy-wizzy/retailrocket-common';
14
+ import {
15
+ multicastStringExpressionDataSourceMatcher
16
+ } from '@easy-wizzy/retailrocket-multicast';
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 multicastStringExpressionDataSourceEvaluatorFactory = (arg: {
26
+ productImageUrlBuilderExpressionEvaluator: ProductImageUrlBuilderExpressionEvaluatorDelegate<
27
+ MulticastListExpressionDataSource,
28
+ MulticastNumberExpressionDataSource
29
+ >
30
+ contactCustomData: ContactCustomData
31
+ nextCouponFromBatch: NextCouponFromBatchType
32
+ }): StringExpressionDataSourceEvaluatorDelegate<
33
+ MulticastStringExpressionDataSource
34
+ > => {
35
+ const multicastContactCustomData = arg.contactCustomData;
36
+
37
+ return (a: {
38
+ stringExpressionDataSource: MulticastStringExpressionDataSource,
39
+ context: DataType
40
+ }) => multicastStringExpressionDataSourceMatcher(
41
+ a.stringExpressionDataSource
42
+ )
43
+ .Match({
44
+ StringFromContactCustomData: (x) => Promise.resolve(multicastContactCustomData[x.FieldName] as string),
45
+ StringFromContactCustomDataWithFallback: (x) => Promise.resolve(
46
+ x.FieldName in multicastContactCustomData && typeof multicastContactCustomData[x.FieldName] === 'string'
47
+ ? multicastContactCustomData[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
+ MulticastProductShelfDataSourceExpressionBuilderModalDeps
4
+ } from '@easy-wizzy/retailrocket-multicast';
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 multicastProductShelfDataSourceExpressionBuilderModalDepsFactory = (
43
+ arg: {
44
+ localeKey: LocaleKey;
45
+ partnerId: string,
46
+ customerStockId: string | undefined,
47
+ productShelfBuilderModalWindowBffClient: ProductShelfBuilderModalWindowBffClient,
48
+ productCategoryPickerModalWindowBffClient: ProductCategoryPickerModalWindowBffClient,
49
+ productPickerModalWindowBffClient: ProductPickerModalWindowBffClient,
50
+ }
51
+ ): MulticastProductShelfDataSourceExpressionBuilderModalDeps => {
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
+ MulticastProductShelfDataSourceExpressionBuilderDeps
4
+ } from '@easy-wizzy/retailrocket-multicast';
5
+ import {
6
+ multicastProductShelfDataSourceExpressionBuilderModalDepsFactory
7
+ } from '@/implementation/EmailComponentSettingsModifierPlugin/ProductShelfDataSourceExpressionBuilder/MulticastProductShelfDataSourceExpressionBuilderModal/multicastProductShelfDataSourceExpressionBuilderModalDepsFactory';
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 multicastProductShelfDataSourceExpressionBuilderDepsFactory = (
16
+ arg: {
17
+ localeKey: LocaleKey;
18
+ partnerId: string,
19
+ customerStockId: string | undefined,
20
+ productShelfBuilderModalWindowBffClient: ProductShelfBuilderModalWindowBffClient,
21
+ productCategoryPickerModalWindowBffClient: ProductCategoryPickerModalWindowBffClient,
22
+ productPickerModalWindowBffClient: ProductPickerModalWindowBffClient
23
+ }
24
+ ): MulticastProductShelfDataSourceExpressionBuilderDeps => {
25
+ return {
26
+ multicastProductShelfDataSourceExpressionBuilderModalDeps: multicastProductShelfDataSourceExpressionBuilderModalDepsFactory({
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,37 @@
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
+ dedupe: ['vue'],
36
+ },
37
+ })