@retailrocketgroup/retailrocket-edit.welcome-sequence-vue-email-template-render 3.0.381747 → 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/editWelcomeSequenceEmailTemplate.d.ts +0 -0
  6. package/dist/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CreateComponentLibrarySectionModalWindow/welcomeSequenceComponentSectionItemFactory.d.ts +4 -0
  7. package/dist/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CreateComponentLibrarySectionModalWindow/welcomeSequenceEmailComponentFactory.d.ts +4 -0
  8. package/dist/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CustomComponentLibrary/welcomeSequenceComponentLibraryFactory.d.ts +4 -0
  9. package/dist/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CustomComponentLibrary/welcomeSequenceSectionFactory.d.ts +4 -0
  10. package/dist/implementation/DataSources/ListDataExpressionSource/welcomeSequenceEvaluateListExpressionDataSourceFactory.d.ts +8 -0
  11. package/dist/implementation/DataSources/NumberExpressionDataSource/welcomeSequenceEvaluateNumberExpressionDataSourceFactory.d.ts +2 -0
  12. package/dist/implementation/DataSources/StringExpressionDataSource/welcomeSequenceEvaluateStringExpressionDataSource.d.ts +9 -0
  13. package/dist/implementation/EmailComponentSettingsModifierPlugin/ProductShelfDataSourceExpressionBuilder/WelcomeSequenceProductShelfDataSourceExpressionBuilderModal/welcomeSequenceProductShelfDataSourceExpressionBuilderModalDepsFactory.d.ts +11 -0
  14. package/dist/implementation/EmailComponentSettingsModifierPlugin/ProductShelfDataSourceExpressionBuilder/welcomeSequenceProductShelfDataSourceExpressionBuilderDepsFactory.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/editWelcomeSequenceEmailTemplate.ts +410 -0
  21. package/src/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CreateComponentLibrarySectionModalWindow/welcomeSequenceComponentSectionItemFactory.ts +30 -0
  22. package/src/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CreateComponentLibrarySectionModalWindow/welcomeSequenceEmailComponentFactory.ts +26 -0
  23. package/src/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CustomComponentLibrary/welcomeSequenceComponentLibraryFactory.ts +29 -0
  24. package/src/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CustomComponentLibrary/welcomeSequenceSectionFactory.ts +34 -0
  25. package/src/implementation/DataSources/ListDataExpressionSource/welcomeSequenceEvaluateListExpressionDataSourceFactory.ts +106 -0
  26. package/src/implementation/DataSources/NumberExpressionDataSource/welcomeSequenceEvaluateNumberExpressionDataSourceFactory.ts +10 -0
  27. package/src/implementation/DataSources/StringExpressionDataSource/welcomeSequenceEvaluateStringExpressionDataSource.ts +56 -0
  28. package/src/implementation/EmailComponentSettingsModifierPlugin/ProductShelfDataSourceExpressionBuilder/WelcomeSequenceProductShelfDataSourceExpressionBuilderModal/welcomeSequenceProductShelfDataSourceExpressionBuilderModalDepsFactory.ts +125 -0
  29. package/src/implementation/EmailComponentSettingsModifierPlugin/ProductShelfDataSourceExpressionBuilder/welcomeSequenceProductShelfDataSourceExpressionBuilderDepsFactory.ts +33 -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 -217
  38. package/favicon.ico +0 -0
@@ -0,0 +1,29 @@
1
+ import type {
2
+ WelcomeSequenceListExpressionDataSource,
3
+ } from '@easy-wizzy/retailrocket-welcome-sequence';
4
+ import type {
5
+ WelcomeSequenceNumberExpressionDataSource,
6
+ } from '@easy-wizzy/retailrocket-welcome-sequence';
7
+ import type {
8
+ WelcomeSequenceStringExpressionDataSource,
9
+ } from '@easy-wizzy/retailrocket-welcome-sequence';
10
+ import {
11
+ welcomeSequenceSectionFactory,
12
+ } from '@/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CustomComponentLibrary/welcomeSequenceSectionFactory';
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 welcomeSequenceComponentLibraryFactory = (
21
+ componentLibrary: Array<ComponentLibrarySection>
22
+ ): CustomComponentLibraryType<
23
+ WelcomeSequenceListExpressionDataSource,
24
+ WelcomeSequenceNumberExpressionDataSource,
25
+ WelcomeSequenceStringExpressionDataSource
26
+ > => {
27
+ return componentLibrary
28
+ .map(section => welcomeSequenceSectionFactory(section))
29
+ }
@@ -0,0 +1,34 @@
1
+ import type {
2
+ WelcomeSequenceListExpressionDataSource,
3
+ } from '@easy-wizzy/retailrocket-welcome-sequence';
4
+ import type {
5
+ WelcomeSequenceNumberExpressionDataSource,
6
+ } from '@easy-wizzy/retailrocket-welcome-sequence';
7
+ import type {
8
+ WelcomeSequenceStringExpressionDataSource,
9
+ } from '@easy-wizzy/retailrocket-welcome-sequence';
10
+
11
+
12
+ import type {
13
+ ComponentLibrarySection,
14
+ } from '@retailrocket/retailrocket.wysiwyg.bff.v2.apiclients.componentlibrary/main';
15
+ import {
16
+ welcomeSequenceComponentSectionItemFactory,
17
+ } from '@/implementation/Apps/components/WysiwygTemplateEditor/AsideMenu/ComponentLibrary/CreateComponentLibrarySectionModalWindow/welcomeSequenceComponentSectionItemFactory';
18
+ import type { CustomComponentSectionType } from '@easy-wizzy/core';
19
+
20
+ export const welcomeSequenceSectionFactory = (
21
+ section: ComponentLibrarySection,
22
+ ): CustomComponentSectionType<
23
+ WelcomeSequenceListExpressionDataSource,
24
+ WelcomeSequenceNumberExpressionDataSource,
25
+ WelcomeSequenceStringExpressionDataSource
26
+ > => {
27
+ return {
28
+ sectionId: section.sectionId,
29
+ sectionName: section.sectionName,
30
+ componentList: section
31
+ .sectionItems
32
+ .map(component => welcomeSequenceComponentSectionItemFactory(component)),
33
+ };
34
+ };
@@ -0,0 +1,106 @@
1
+ import { type WelcomeSequenceListExpressionDataSource } from '@easy-wizzy/retailrocket-welcome-sequence';
2
+ import { welcomeSequenceListExpressionDataSourceMatcher } from '@easy-wizzy/retailrocket-welcome-sequence';
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 welcomeSequenceEvaluateListExpressionDataSourceFactory = (arg: {
20
+ partnerId: string;
21
+ listExpressionDataSourceBffClient: ListExpressionDataSourceBffClient;
22
+ customerStockId: string | undefined;
23
+ }): ListExpressionDataSourceEvaluatorDelegate<WelcomeSequenceListExpressionDataSource> => {
24
+ let productCache: { [key: string]: Product } = {};
25
+
26
+ return (asyncDataSource: WelcomeSequenceListExpressionDataSource) =>
27
+ welcomeSequenceListExpressionDataSourceMatcher(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 welcomeSequenceEvaluateNumberExpressionDataSourceFactory = <
6
+ TNumberExpressionDataSource
7
+ >():
8
+ NumberExpressionDataSourceEvaluatorDelegate<TNumberExpressionDataSource> => {
9
+ return () => Promise.resolve(0);
10
+ }
@@ -0,0 +1,56 @@
1
+ import type {
2
+ WelcomeSequenceStringExpressionDataSource,
3
+ } from '@easy-wizzy/retailrocket-welcome-sequence';
4
+ import type {
5
+ WelcomeSequenceListExpressionDataSource
6
+ } from '@easy-wizzy/retailrocket-welcome-sequence';
7
+ import type {
8
+ WelcomeSequenceNumberExpressionDataSource
9
+ } from '@easy-wizzy/retailrocket-welcome-sequence';
10
+ import type {
11
+ StringExpressionDataSourceEvaluatorDelegate
12
+ } from '@easy-wizzy/core';
13
+ import type { ContactCustomData } from '@easy-wizzy/retailrocket-common';
14
+ import {
15
+ welcomeSequenceStringExpressionDataSourceMatcher
16
+ } from '@easy-wizzy/retailrocket-welcome-sequence';
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 welcomeSequenceStringExpressionDataSourceEvaluatorFactory = (arg: {
26
+ productImageUrlBuilderExpressionEvaluator: ProductImageUrlBuilderExpressionEvaluatorDelegate<
27
+ WelcomeSequenceListExpressionDataSource,
28
+ WelcomeSequenceNumberExpressionDataSource
29
+ >
30
+ contactCustomData: ContactCustomData
31
+ nextCouponFromBatch: NextCouponFromBatchType
32
+ }): StringExpressionDataSourceEvaluatorDelegate<
33
+ WelcomeSequenceStringExpressionDataSource
34
+ > => {
35
+ const welcomeSequenceContactCustomData = arg.contactCustomData;
36
+
37
+ return (a: {
38
+ stringExpressionDataSource: WelcomeSequenceStringExpressionDataSource,
39
+ context: DataType
40
+ }) => welcomeSequenceStringExpressionDataSourceMatcher(
41
+ a.stringExpressionDataSource
42
+ )
43
+ .Match({
44
+ StringFromContactCustomData: (x) => Promise.resolve(welcomeSequenceContactCustomData[x.FieldName] as string),
45
+ StringFromContactCustomDataWithFallback: (x) => Promise.resolve(
46
+ x.FieldName in welcomeSequenceContactCustomData && typeof welcomeSequenceContactCustomData[x.FieldName] === 'string'
47
+ ? welcomeSequenceContactCustomData[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,125 @@
1
+ import type { LocaleKey } from '@easy-wizzy/core';
2
+ import type {
3
+ WelcomeSequenceProductShelfDataSourceExpressionBuilderModalDeps
4
+ } from '@easy-wizzy/retailrocket-welcome-sequence';
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 { ProductCategoryPickerModalWindowBffClient } from '@easy-wizzy/common-app';
39
+
40
+ export const welcomeSequenceProductShelfDataSourceExpressionBuilderModalDepsFactory = (
41
+ arg: {
42
+ localeKey: LocaleKey;
43
+ partnerId: string,
44
+ customerStockId: string | undefined,
45
+ productShelfBuilderModalWindowBffClient: ProductShelfBuilderModalWindowBffClient,
46
+ productCategoryPickerModalWindowBffClient: ProductCategoryPickerModalWindowBffClient,
47
+ productPickerModalWindowBffClient: ProductPickerModalWindowBffClient,
48
+ }
49
+ ): WelcomeSequenceProductShelfDataSourceExpressionBuilderModalDeps => {
50
+
51
+ const productCache = {};
52
+ const categoryCache = {};
53
+
54
+ const productListComposerModalWindowDeps = productListComposerModalWindowDepsFactory({
55
+ localeKey: arg.localeKey,
56
+ partnerId: arg.partnerId,
57
+ customerStockId: arg.customerStockId,
58
+ productPickerModalWindowBffClient: arg.productPickerModalWindowBffClient,
59
+ });
60
+
61
+ return {
62
+ localeKey: arg.localeKey,
63
+ ProductListComposerModalWindowDeps: productListComposerModalWindowDeps,
64
+ CategoryListComposerModalWindowDeps: categoryListComposerModalWindowDepsFactory({
65
+ localeKey: arg.localeKey,
66
+ partnerId: arg.partnerId,
67
+ productCategoryPickerModalWindowBffClient: arg.productCategoryPickerModalWindowBffClient
68
+ }),
69
+ AlternativeProductListShelfBuilderDeps: alternativeProductListShelfBuilderDepsFactory({
70
+ localeKey: arg.localeKey,
71
+ partnerId: arg.partnerId,
72
+ customerStockId: arg.customerStockId,
73
+ productCache: productCache,
74
+ getProductsByIDsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetProductsByIds,
75
+ getAllStockIdsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetAllStockIds,
76
+ productListComposerModalWindowDeps: productListComposerModalWindowDeps
77
+ }),
78
+ RelatedProductListShelfBuilderDeps: relatedProductListShelfBuilderDepsFactory({
79
+ localeKey: arg.localeKey,
80
+ partnerId: arg.partnerId,
81
+ customerStockId: arg.customerStockId,
82
+ productCache: productCache,
83
+ getProductsByIDsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetProductsByIds,
84
+ getAllStockIdsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetAllStockIds,
85
+ productListComposerModalWindowDeps: productListComposerModalWindowDeps
86
+ }),
87
+ ProductListShelfBuilderDeps: productListShelfBuilderDepsFactory({
88
+ localeKey: arg.localeKey,
89
+ partnerId: arg.partnerId,
90
+ customerStockId: arg.customerStockId,
91
+ productCache: productCache,
92
+ getProductsByIDsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetProductsByIds,
93
+ getAllStockIdsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetAllStockIds,
94
+ productListComposerModalWindowDeps: productListComposerModalWindowDeps
95
+ }),
96
+ PopularFromCategoryListShelfBuilderDeps: popularFromCategoryListShelfBuilderDepsFactory({
97
+ localeKey: arg.localeKey,
98
+ partnerId: arg.partnerId,
99
+ categoryCache: categoryCache,
100
+ getAllStockIdsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetAllStockIds,
101
+ getCategoriesByIDsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetProductCategoriesByIds,
102
+ productCategoryPickerModalWindowBffClient: arg.productCategoryPickerModalWindowBffClient
103
+ }),
104
+ PopularProductListShelfBuilderDeps: popularProductListShelfBuilderDepsFactory({
105
+ localeKey: arg.localeKey,
106
+ partnerId: arg.partnerId,
107
+ getAllStockIdsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetAllStockIds
108
+ }),
109
+ LatestProductListShelfBuilderDeps: latestProductListShelfBuilderDepsFactory({
110
+ localeKey: arg.localeKey,
111
+ partnerId: arg.partnerId,
112
+ getAllStockIdsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetAllStockIds
113
+ }),
114
+ SaleByPopularProductListShelfBuilderDeps: saleByPopularProductListShelfBuilderDepsFactory({
115
+ localeKey: arg.localeKey,
116
+ partnerId: arg.partnerId,
117
+ getAllStockIdsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetAllStockIds
118
+ }),
119
+ SaleByLatestProductListShelfBuilderDeps: saleByLatestProductListShelfBuilderDepsFactory({
120
+ localeKey: arg.localeKey,
121
+ partnerId: arg.partnerId,
122
+ getAllStockIdsHttpClient: arg.productShelfBuilderModalWindowBffClient.postGetAllStockIds
123
+ })
124
+ }
125
+ }
@@ -0,0 +1,33 @@
1
+ import type { LocaleKey } from '@easy-wizzy/core';
2
+ import type {
3
+ WelcomeSequenceProductShelfDataSourceExpressionBuilderDeps
4
+ } from '@easy-wizzy/retailrocket-welcome-sequence';
5
+ import {
6
+ welcomeSequenceProductShelfDataSourceExpressionBuilderModalDepsFactory
7
+ } from '@/implementation/EmailComponentSettingsModifierPlugin/ProductShelfDataSourceExpressionBuilder/WelcomeSequenceProductShelfDataSourceExpressionBuilderModal/welcomeSequenceProductShelfDataSourceExpressionBuilderModalDepsFactory';
8
+ import type { ProductShelfBuilderModalWindowBffClient } from '@easy-wizzy/common-app';
9
+
10
+ import type { ProductPickerModalWindowBffClient } from '@easy-wizzy/common-app';
11
+ import type { ProductCategoryPickerModalWindowBffClient } from '@easy-wizzy/common-app';
12
+
13
+ export const welcomeSequenceProductShelfDataSourceExpressionBuilderDepsFactory = (
14
+ arg: {
15
+ localeKey: LocaleKey;
16
+ partnerId: string,
17
+ customerStockId: string | undefined,
18
+ productShelfBuilderModalWindowBffClient: ProductShelfBuilderModalWindowBffClient,
19
+ productCategoryPickerModalWindowBffClient: ProductCategoryPickerModalWindowBffClient,
20
+ productPickerModalWindowBffClient: ProductPickerModalWindowBffClient
21
+ }
22
+ ): WelcomeSequenceProductShelfDataSourceExpressionBuilderDeps => {
23
+ return {
24
+ welcomeSequenceProductShelfDataSourceExpressionBuilderModalDeps: welcomeSequenceProductShelfDataSourceExpressionBuilderModalDepsFactory({
25
+ localeKey: arg.localeKey,
26
+ partnerId: arg.partnerId,
27
+ customerStockId: arg.customerStockId,
28
+ productShelfBuilderModalWindowBffClient: arg.productShelfBuilderModalWindowBffClient,
29
+ productCategoryPickerModalWindowBffClient: arg.productCategoryPickerModalWindowBffClient,
30
+ productPickerModalWindowBffClient: arg.productPickerModalWindowBffClient
31
+ })
32
+ }
33
+ }
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
+ })