@capillarytech/creatives-library 8.0.263 → 8.0.265
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/assets/Android.png +0 -0
- package/assets/iOS.png +0 -0
- package/constants/unified.js +1 -3
- package/initialReducer.js +0 -2
- package/package.json +1 -1
- package/services/api.js +0 -15
- package/services/tests/api.test.js +0 -34
- package/tests/integration/TemplateCreation/TemplateCreation.integration.test.js +35 -17
- package/tests/integration/TemplateCreation/api-response.js +1 -31
- package/tests/integration/TemplateCreation/msw-handler.js +0 -2
- package/utils/common.js +0 -11
- package/utils/commonUtils.js +5 -28
- package/utils/tests/commonUtil.test.js +0 -224
- package/utils/tests/transformerUtils.test.js +0 -297
- package/utils/transformTemplateConfig.js +10 -0
- package/utils/transformerUtils.js +0 -40
- package/v2Components/CapDeviceContent/index.js +56 -61
- package/v2Components/CapImageUpload/constants.js +0 -2
- package/v2Components/CapImageUpload/index.js +16 -65
- package/v2Components/CapImageUpload/index.scss +1 -4
- package/v2Components/CapImageUpload/messages.js +1 -5
- package/v2Components/CapTagList/index.js +1 -6
- package/v2Components/CapTagListWithInput/index.js +1 -5
- package/v2Components/CapTagListWithInput/messages.js +1 -1
- package/v2Components/CapWhatsappCTA/tests/index.test.js +0 -5
- package/v2Components/ErrorInfoNote/index.js +72 -402
- package/v2Components/ErrorInfoNote/messages.js +6 -32
- package/v2Components/ErrorInfoNote/style.scss +6 -278
- package/v2Components/FormBuilder/tests/index.test.js +4 -13
- package/v2Components/HtmlEditor/HTMLEditor.js +99 -418
- package/v2Components/HtmlEditor/__tests__/HTMLEditor.test.js +133 -1882
- package/v2Components/HtmlEditor/__tests__/index.lazy.test.js +16 -27
- package/v2Components/HtmlEditor/_htmlEditor.scss +45 -108
- package/v2Components/HtmlEditor/_index.lazy.scss +1 -0
- package/v2Components/HtmlEditor/components/CodeEditorPane/_codeEditorPane.scss +102 -23
- package/v2Components/HtmlEditor/components/CodeEditorPane/index.js +140 -148
- package/v2Components/HtmlEditor/components/DeviceToggle/_deviceToggle.scss +1 -2
- package/v2Components/HtmlEditor/components/DeviceToggle/index.js +3 -3
- package/v2Components/HtmlEditor/components/EditorToolbar/_editorToolbar.scss +1 -9
- package/v2Components/HtmlEditor/components/EditorToolbar/index.js +6 -31
- package/v2Components/HtmlEditor/components/FullscreenModal/_fullscreenModal.scss +0 -22
- package/v2Components/HtmlEditor/components/InAppPreviewPane/DeviceFrame.js +7 -4
- package/v2Components/HtmlEditor/components/InAppPreviewPane/__tests__/DeviceFrame.test.js +45 -35
- package/v2Components/HtmlEditor/components/InAppPreviewPane/_inAppPreviewPane.scss +3 -1
- package/v2Components/HtmlEditor/components/InAppPreviewPane/constants.js +33 -33
- package/v2Components/HtmlEditor/components/InAppPreviewPane/index.js +6 -7
- package/v2Components/HtmlEditor/components/PreviewPane/_previewPane.scss +10 -7
- package/v2Components/HtmlEditor/components/PreviewPane/index.js +43 -22
- package/v2Components/HtmlEditor/components/SplitContainer/_splitContainer.scss +1 -1
- package/v2Components/HtmlEditor/components/ValidationErrorDisplay/__tests__/index.test.js +152 -0
- package/v2Components/HtmlEditor/components/ValidationErrorDisplay/_validationErrorDisplay.scss +0 -18
- package/v2Components/HtmlEditor/components/ValidationErrorDisplay/index.js +31 -36
- package/v2Components/HtmlEditor/components/ValidationPanel/_validationPanel.scss +34 -46
- package/v2Components/HtmlEditor/components/ValidationPanel/index.js +46 -52
- package/v2Components/HtmlEditor/constants.js +20 -45
- package/v2Components/HtmlEditor/hooks/__tests__/useInAppContent.test.js +16 -373
- package/v2Components/HtmlEditor/hooks/__tests__/useValidation.test.js +16 -351
- package/v2Components/HtmlEditor/hooks/useEditorContent.js +2 -5
- package/v2Components/HtmlEditor/hooks/useInAppContent.js +146 -88
- package/v2Components/HtmlEditor/hooks/useValidation.js +56 -213
- package/v2Components/HtmlEditor/index.js +1 -1
- package/v2Components/HtmlEditor/messages.js +94 -102
- package/v2Components/HtmlEditor/utils/__tests__/htmlValidator.enhanced.test.js +45 -214
- package/v2Components/HtmlEditor/utils/__tests__/validationAdapter.test.js +0 -134
- package/v2Components/HtmlEditor/utils/contentSanitizer.js +41 -40
- package/v2Components/HtmlEditor/utils/htmlValidator.js +72 -71
- package/v2Components/HtmlEditor/utils/liquidTemplateSupport.js +124 -158
- package/v2Components/HtmlEditor/utils/properSyntaxHighlighting.js +25 -23
- package/v2Components/HtmlEditor/utils/validationAdapter.js +41 -66
- package/v2Components/MobilePushPreviewV2/index.js +7 -33
- package/v2Components/TemplatePreview/_templatePreview.scss +24 -55
- package/v2Components/TemplatePreview/index.js +32 -47
- package/v2Components/TemplatePreview/messages.js +0 -4
- package/v2Components/TestAndPreviewSlidebox/_testAndPreviewSlidebox.scss +0 -1
- package/v2Containers/App/constants.js +0 -5
- package/v2Containers/BeeEditor/index.js +90 -172
- package/v2Containers/CreativesContainer/SlideBoxContent.js +53 -184
- package/v2Containers/CreativesContainer/SlideBoxFooter.js +13 -163
- package/v2Containers/CreativesContainer/SlideBoxHeader.js +1 -3
- package/v2Containers/CreativesContainer/constants.js +0 -4
- package/v2Containers/CreativesContainer/index.js +46 -408
- package/v2Containers/CreativesContainer/messages.js +0 -12
- package/v2Containers/CreativesContainer/tests/SlideBoxContent.test.js +0 -210
- package/v2Containers/CreativesContainer/tests/SlideBoxFooter.test.js +2 -11
- package/v2Containers/CreativesContainer/tests/__snapshots__/SlideBoxContent.test.js.snap +50 -342
- package/v2Containers/CreativesContainer/tests/__snapshots__/index.test.js.snap +0 -103
- package/v2Containers/Email/actions.js +0 -7
- package/v2Containers/Email/constants.js +1 -5
- package/v2Containers/Email/index.js +36 -237
- package/v2Containers/Email/messages.js +0 -32
- package/v2Containers/Email/reducer.js +1 -12
- package/v2Containers/Email/sagas.js +7 -61
- package/v2Containers/Email/tests/__snapshots__/reducer.test.js.snap +0 -2
- package/v2Containers/Email/tests/reducer.test.js +0 -46
- package/v2Containers/Email/tests/sagas.test.js +29 -320
- package/v2Containers/EmailWrapper/components/EmailWrapperView.js +21 -211
- package/v2Containers/EmailWrapper/components/HTMLEditorTesting.js +74 -40
- package/v2Containers/EmailWrapper/components/__tests__/HTMLEditorTesting.test.js +67 -2
- package/v2Containers/EmailWrapper/constants.js +0 -2
- package/v2Containers/EmailWrapper/hooks/useEmailWrapper.js +77 -629
- package/v2Containers/EmailWrapper/index.js +23 -103
- package/v2Containers/EmailWrapper/messages.js +1 -65
- package/v2Containers/EmailWrapper/tests/EmailWrapperView.test.js +214 -0
- package/v2Containers/EmailWrapper/tests/useEmailWrapper.test.js +77 -594
- package/v2Containers/InApp/actions.js +0 -7
- package/v2Containers/InApp/constants.js +4 -20
- package/v2Containers/InApp/index.js +359 -802
- package/v2Containers/InApp/index.scss +3 -4
- package/v2Containers/InApp/messages.js +3 -7
- package/v2Containers/InApp/reducer.js +3 -21
- package/v2Containers/InApp/sagas.js +9 -29
- package/v2Containers/InApp/selectors.js +5 -25
- package/v2Containers/InApp/tests/index.test.js +50 -154
- package/v2Containers/InApp/tests/reducer.test.js +0 -34
- package/v2Containers/InApp/tests/sagas.test.js +9 -61
- package/v2Containers/Line/Container/ImageCarousel/tests/__snapshots__/content.test.js.snap +0 -3
- package/v2Containers/Line/Container/ImageCarousel/tests/__snapshots__/index.test.js.snap +0 -2
- package/v2Containers/Line/Container/Wrapper/tests/__snapshots__/index.test.js.snap +0 -2
- package/v2Containers/Line/Container/tests/__snapshots__/index.test.js.snap +0 -9
- package/v2Containers/Rcs/tests/__snapshots__/index.test.js.snap +0 -12
- package/v2Containers/SmsTrai/Edit/tests/__snapshots__/index.test.js.snap +0 -4
- package/v2Containers/TagList/index.js +19 -62
- package/v2Containers/Templates/ChannelTypeIllustration.js +1 -13
- package/v2Containers/Templates/_templates.scss +1 -265
- package/v2Containers/Templates/actions.js +1 -2
- package/v2Containers/Templates/constants.js +0 -1
- package/v2Containers/Templates/index.js +38 -363
- package/v2Containers/Templates/messages.js +0 -28
- package/v2Containers/Templates/reducer.js +0 -2
- package/v2Containers/Templates/tests/index.test.js +0 -10
- package/v2Containers/TemplatesV2/TemplatesV2.style.js +2 -4
- package/v2Containers/TemplatesV2/index.js +7 -15
- package/v2Containers/TemplatesV2/messages.js +0 -4
- package/v2Containers/Whatsapp/tests/__snapshots__/index.test.js.snap +0 -34
- package/utils/imageUrlUpload.js +0 -141
- package/v2Components/CapImageUrlUpload/constants.js +0 -26
- package/v2Components/CapImageUrlUpload/index.js +0 -365
- package/v2Components/CapImageUrlUpload/index.scss +0 -35
- package/v2Components/CapImageUrlUpload/messages.js +0 -47
- package/v2Components/ErrorInfoNote/constants.js +0 -1
- package/v2Components/HtmlEditor/__tests__/HTMLEditor.apiErrors.test.js +0 -870
- package/v2Components/HtmlEditor/components/ValidationPanel/constants.js +0 -6
- package/v2Components/HtmlEditor/components/ValidationTabs/_validationTabs.scss +0 -281
- package/v2Components/HtmlEditor/components/ValidationTabs/index.js +0 -295
- package/v2Components/HtmlEditor/components/ValidationTabs/messages.js +0 -51
- package/v2Components/HtmlEditor/utils/validationConstants.js +0 -38
- package/v2Components/MobilePushPreviewV2/constants.js +0 -6
- package/v2Containers/BeePopupEditor/_beePopupEditor.scss +0 -14
- package/v2Containers/BeePopupEditor/constants.js +0 -10
- package/v2Containers/BeePopupEditor/index.js +0 -194
- package/v2Containers/BeePopupEditor/tests/index.test.js +0 -627
- package/v2Containers/EmailWrapper/components/EmailHTMLEditor.js +0 -1246
- package/v2Containers/EmailWrapper/components/__tests__/EmailHTMLEditor.test.js +0 -2472
- package/v2Containers/EmailWrapper/components/__tests__/EmailWrapperView.test.js +0 -520
- package/v2Containers/EmailWrapper/tests/useEmailWrapper.edgeCases.test.js +0 -956
- package/v2Containers/InApp/__tests__/InAppHTMLEditor.test.js +0 -376
- package/v2Containers/InApp/__tests__/sagas.test.js +0 -363
- package/v2Containers/InApp/tests/selectors.test.js +0 -612
- package/v2Containers/InAppWrapper/components/InAppWrapperView.js +0 -151
- package/v2Containers/InAppWrapper/components/__tests__/InAppWrapperView.test.js +0 -267
- package/v2Containers/InAppWrapper/components/inAppWrapperView.scss +0 -23
- package/v2Containers/InAppWrapper/constants.js +0 -16
- package/v2Containers/InAppWrapper/hooks/__tests__/useInAppWrapper.test.js +0 -473
- package/v2Containers/InAppWrapper/hooks/useInAppWrapper.js +0 -198
- package/v2Containers/InAppWrapper/index.js +0 -148
- package/v2Containers/InAppWrapper/messages.js +0 -49
- package/v2Containers/InappAdvance/index.js +0 -1099
- package/v2Containers/InappAdvance/index.scss +0 -10
- package/v2Containers/InappAdvance/tests/index.test.js +0 -448
- package/v2Containers/WebPush/Create/components/BrandIconSection.js +0 -108
- package/v2Containers/WebPush/Create/components/ButtonForm.js +0 -172
- package/v2Containers/WebPush/Create/components/ButtonItem.js +0 -101
- package/v2Containers/WebPush/Create/components/ButtonList.js +0 -145
- package/v2Containers/WebPush/Create/components/ButtonsLinksSection.js +0 -164
- package/v2Containers/WebPush/Create/components/ButtonsLinksSection.test.js +0 -463
- package/v2Containers/WebPush/Create/components/FormActions.js +0 -54
- package/v2Containers/WebPush/Create/components/FormActions.test.js +0 -163
- package/v2Containers/WebPush/Create/components/MediaSection.js +0 -142
- package/v2Containers/WebPush/Create/components/MediaSection.test.js +0 -341
- package/v2Containers/WebPush/Create/components/MessageSection.js +0 -103
- package/v2Containers/WebPush/Create/components/MessageSection.test.js +0 -268
- package/v2Containers/WebPush/Create/components/NotificationTitleSection.js +0 -87
- package/v2Containers/WebPush/Create/components/NotificationTitleSection.test.js +0 -210
- package/v2Containers/WebPush/Create/components/TemplateNameSection.js +0 -54
- package/v2Containers/WebPush/Create/components/TemplateNameSection.test.js +0 -143
- package/v2Containers/WebPush/Create/components/__snapshots__/ButtonsLinksSection.test.js.snap +0 -86
- package/v2Containers/WebPush/Create/components/__snapshots__/FormActions.test.js.snap +0 -16
- package/v2Containers/WebPush/Create/components/__snapshots__/MediaSection.test.js.snap +0 -41
- package/v2Containers/WebPush/Create/components/__snapshots__/MessageSection.test.js.snap +0 -54
- package/v2Containers/WebPush/Create/components/__snapshots__/NotificationTitleSection.test.js.snap +0 -37
- package/v2Containers/WebPush/Create/components/__snapshots__/TemplateNameSection.test.js.snap +0 -21
- package/v2Containers/WebPush/Create/components/_buttons.scss +0 -246
- package/v2Containers/WebPush/Create/components/tests/ButtonForm.test.js +0 -554
- package/v2Containers/WebPush/Create/components/tests/ButtonItem.test.js +0 -607
- package/v2Containers/WebPush/Create/components/tests/ButtonList.test.js +0 -633
- package/v2Containers/WebPush/Create/components/tests/__snapshots__/ButtonForm.test.js.snap +0 -666
- package/v2Containers/WebPush/Create/components/tests/__snapshots__/ButtonItem.test.js.snap +0 -74
- package/v2Containers/WebPush/Create/components/tests/__snapshots__/ButtonList.test.js.snap +0 -78
- package/v2Containers/WebPush/Create/hooks/useButtonManagement.js +0 -138
- package/v2Containers/WebPush/Create/hooks/useButtonManagement.test.js +0 -406
- package/v2Containers/WebPush/Create/hooks/useCharacterCount.js +0 -30
- package/v2Containers/WebPush/Create/hooks/useCharacterCount.test.js +0 -151
- package/v2Containers/WebPush/Create/hooks/useImageUpload.js +0 -104
- package/v2Containers/WebPush/Create/hooks/useImageUpload.test.js +0 -538
- package/v2Containers/WebPush/Create/hooks/useTagManagement.js +0 -122
- package/v2Containers/WebPush/Create/hooks/useTagManagement.test.js +0 -633
- package/v2Containers/WebPush/Create/index.js +0 -1148
- package/v2Containers/WebPush/Create/index.scss +0 -134
- package/v2Containers/WebPush/Create/messages.js +0 -211
- package/v2Containers/WebPush/Create/preview/DevicePreviewContent.js +0 -228
- package/v2Containers/WebPush/Create/preview/NotificationContainer.js +0 -294
- package/v2Containers/WebPush/Create/preview/PreviewContent.js +0 -90
- package/v2Containers/WebPush/Create/preview/PreviewControls.js +0 -305
- package/v2Containers/WebPush/Create/preview/PreviewDisclaimer.js +0 -25
- package/v2Containers/WebPush/Create/preview/WebPushPreview.js +0 -155
- package/v2Containers/WebPush/Create/preview/assets/Light.svg +0 -53
- package/v2Containers/WebPush/Create/preview/assets/Top.svg +0 -5
- package/v2Containers/WebPush/Create/preview/assets/android-arrow-down.svg +0 -9
- package/v2Containers/WebPush/Create/preview/assets/android-arrow-up.svg +0 -9
- package/v2Containers/WebPush/Create/preview/assets/chrome-icon.png +0 -0
- package/v2Containers/WebPush/Create/preview/assets/edge-icon.png +0 -0
- package/v2Containers/WebPush/Create/preview/assets/firefox-icon.svg +0 -106
- package/v2Containers/WebPush/Create/preview/assets/iOS.svg +0 -26
- package/v2Containers/WebPush/Create/preview/assets/macos-arrow-down-icon.svg +0 -9
- package/v2Containers/WebPush/Create/preview/assets/macos-triple-dot-icon.svg +0 -9
- package/v2Containers/WebPush/Create/preview/assets/opera-icon.svg +0 -18
- package/v2Containers/WebPush/Create/preview/assets/safari-icon.svg +0 -29
- package/v2Containers/WebPush/Create/preview/assets/windows-close-icon.svg +0 -9
- package/v2Containers/WebPush/Create/preview/assets/windows-triple-dot-icon.svg +0 -9
- package/v2Containers/WebPush/Create/preview/components/AndroidMobileChromeHeader.js +0 -51
- package/v2Containers/WebPush/Create/preview/components/AndroidMobileExpanded.js +0 -145
- package/v2Containers/WebPush/Create/preview/components/IOSHeader.js +0 -45
- package/v2Containers/WebPush/Create/preview/components/NotificationExpandedContent.js +0 -68
- package/v2Containers/WebPush/Create/preview/components/NotificationHeader.js +0 -61
- package/v2Containers/WebPush/Create/preview/components/WindowsChromeExpanded.js +0 -99
- package/v2Containers/WebPush/Create/preview/components/tests/AndroidMobileExpanded.test.js +0 -733
- package/v2Containers/WebPush/Create/preview/components/tests/WindowsChromeExpanded.test.js +0 -571
- package/v2Containers/WebPush/Create/preview/components/tests/__snapshots__/AndroidMobileExpanded.test.js.snap +0 -85
- package/v2Containers/WebPush/Create/preview/components/tests/__snapshots__/WindowsChromeExpanded.test.js.snap +0 -81
- package/v2Containers/WebPush/Create/preview/config/notificationMappings.js +0 -50
- package/v2Containers/WebPush/Create/preview/constants.js +0 -637
- package/v2Containers/WebPush/Create/preview/notification-container.scss +0 -79
- package/v2Containers/WebPush/Create/preview/preview.scss +0 -358
- package/v2Containers/WebPush/Create/preview/styles/_android-mobile-chrome.scss +0 -370
- package/v2Containers/WebPush/Create/preview/styles/_android-mobile-edge.scss +0 -12
- package/v2Containers/WebPush/Create/preview/styles/_android-mobile-firefox.scss +0 -12
- package/v2Containers/WebPush/Create/preview/styles/_android-mobile-opera.scss +0 -12
- package/v2Containers/WebPush/Create/preview/styles/_android-tablet-chrome.scss +0 -47
- package/v2Containers/WebPush/Create/preview/styles/_android-tablet-edge.scss +0 -11
- package/v2Containers/WebPush/Create/preview/styles/_android-tablet-firefox.scss +0 -11
- package/v2Containers/WebPush/Create/preview/styles/_android-tablet-opera.scss +0 -11
- package/v2Containers/WebPush/Create/preview/styles/_base.scss +0 -207
- package/v2Containers/WebPush/Create/preview/styles/_ios.scss +0 -153
- package/v2Containers/WebPush/Create/preview/styles/_ipados.scss +0 -107
- package/v2Containers/WebPush/Create/preview/styles/_macos-chrome.scss +0 -101
- package/v2Containers/WebPush/Create/preview/styles/_windows-chrome.scss +0 -229
- package/v2Containers/WebPush/Create/preview/tests/DevicePreviewContent.test.js +0 -909
- package/v2Containers/WebPush/Create/preview/tests/NotificationContainer.test.js +0 -1081
- package/v2Containers/WebPush/Create/preview/tests/PreviewControls.test.js +0 -723
- package/v2Containers/WebPush/Create/preview/tests/WebPushPreview.test.js +0 -1327
- package/v2Containers/WebPush/Create/preview/tests/__snapshots__/DevicePreviewContent.test.js.snap +0 -131
- package/v2Containers/WebPush/Create/preview/tests/__snapshots__/NotificationContainer.test.js.snap +0 -112
- package/v2Containers/WebPush/Create/preview/tests/__snapshots__/PreviewControls.test.js.snap +0 -144
- package/v2Containers/WebPush/Create/preview/tests/__snapshots__/WebPushPreview.test.js.snap +0 -129
- package/v2Containers/WebPush/Create/utils/payloadBuilder.js +0 -96
- package/v2Containers/WebPush/Create/utils/payloadBuilder.test.js +0 -396
- package/v2Containers/WebPush/Create/utils/previewUtils.js +0 -89
- package/v2Containers/WebPush/Create/utils/urlValidation.js +0 -115
- package/v2Containers/WebPush/Create/utils/urlValidation.test.js +0 -449
- package/v2Containers/WebPush/Create/utils/validation.js +0 -75
- package/v2Containers/WebPush/Create/utils/validation.test.js +0 -283
- package/v2Containers/WebPush/actions.js +0 -60
- package/v2Containers/WebPush/constants.js +0 -132
- package/v2Containers/WebPush/index.js +0 -2
- package/v2Containers/WebPush/reducer.js +0 -104
- package/v2Containers/WebPush/sagas.js +0 -119
- package/v2Containers/WebPush/selectors.js +0 -65
- package/v2Containers/WebPush/tests/reducer.test.js +0 -863
- package/v2Containers/WebPush/tests/sagas.test.js +0 -566
- package/v2Containers/WebPush/tests/selectors.test.js +0 -960
|
@@ -2281,7 +2281,6 @@ new message content.",
|
|
|
2281
2281
|
"email": [Function],
|
|
2282
2282
|
"facebookPreview": [Function],
|
|
2283
2283
|
"gallery": [Function],
|
|
2284
|
-
"inApp": [Function],
|
|
2285
2284
|
"language": [Function],
|
|
2286
2285
|
"navigationConfig": [Function],
|
|
2287
2286
|
"previewAndTest": [Function],
|
|
@@ -11300,7 +11299,6 @@ new message content.",
|
|
|
11300
11299
|
"email": [Function],
|
|
11301
11300
|
"facebookPreview": [Function],
|
|
11302
11301
|
"gallery": [Function],
|
|
11303
|
-
"inApp": [Function],
|
|
11304
11302
|
"language": [Function],
|
|
11305
11303
|
"navigationConfig": [Function],
|
|
11306
11304
|
"previewAndTest": [Function],
|
|
@@ -20503,7 +20501,6 @@ new message content.",
|
|
|
20503
20501
|
"email": [Function],
|
|
20504
20502
|
"facebookPreview": [Function],
|
|
20505
20503
|
"gallery": [Function],
|
|
20506
|
-
"inApp": [Function],
|
|
20507
20504
|
"language": [Function],
|
|
20508
20505
|
"navigationConfig": [Function],
|
|
20509
20506
|
"previewAndTest": [Function],
|
|
@@ -29983,7 +29980,6 @@ new message content.",
|
|
|
29983
29980
|
"email": [Function],
|
|
29984
29981
|
"facebookPreview": [Function],
|
|
29985
29982
|
"gallery": [Function],
|
|
29986
|
-
"inApp": [Function],
|
|
29987
29983
|
"language": [Function],
|
|
29988
29984
|
"navigationConfig": [Function],
|
|
29989
29985
|
"previewAndTest": [Function],
|
|
@@ -41684,7 +41680,6 @@ new message content.",
|
|
|
41684
41680
|
"email": [Function],
|
|
41685
41681
|
"facebookPreview": [Function],
|
|
41686
41682
|
"gallery": [Function],
|
|
41687
|
-
"inApp": [Function],
|
|
41688
41683
|
"language": [Function],
|
|
41689
41684
|
"navigationConfig": [Function],
|
|
41690
41685
|
"previewAndTest": [Function],
|
|
@@ -53427,7 +53422,6 @@ new message content.",
|
|
|
53427
53422
|
"email": [Function],
|
|
53428
53423
|
"facebookPreview": [Function],
|
|
53429
53424
|
"gallery": [Function],
|
|
53430
|
-
"inApp": [Function],
|
|
53431
53425
|
"language": [Function],
|
|
53432
53426
|
"navigationConfig": [Function],
|
|
53433
53427
|
"previewAndTest": [Function],
|
|
@@ -61220,7 +61214,6 @@ new message content.",
|
|
|
61220
61214
|
"email": [Function],
|
|
61221
61215
|
"facebookPreview": [Function],
|
|
61222
61216
|
"gallery": [Function],
|
|
61223
|
-
"inApp": [Function],
|
|
61224
61217
|
"language": [Function],
|
|
61225
61218
|
"navigationConfig": [Function],
|
|
61226
61219
|
"previewAndTest": [Function],
|
|
@@ -69431,7 +69424,6 @@ new message content.",
|
|
|
69431
69424
|
"email": [Function],
|
|
69432
69425
|
"facebookPreview": [Function],
|
|
69433
69426
|
"gallery": [Function],
|
|
69434
|
-
"inApp": [Function],
|
|
69435
69427
|
"language": [Function],
|
|
69436
69428
|
"navigationConfig": [Function],
|
|
69437
69429
|
"previewAndTest": [Function],
|
|
@@ -77919,7 +77911,6 @@ new message content.",
|
|
|
77919
77911
|
"email": [Function],
|
|
77920
77912
|
"facebookPreview": [Function],
|
|
77921
77913
|
"gallery": [Function],
|
|
77922
|
-
"inApp": [Function],
|
|
77923
77914
|
"language": [Function],
|
|
77924
77915
|
"navigationConfig": [Function],
|
|
77925
77916
|
"previewAndTest": [Function],
|
|
@@ -2281,7 +2281,6 @@ new message content.",
|
|
|
2281
2281
|
"email": [Function],
|
|
2282
2282
|
"facebookPreview": [Function],
|
|
2283
2283
|
"gallery": [Function],
|
|
2284
|
-
"inApp": [Function],
|
|
2285
2284
|
"language": [Function],
|
|
2286
2285
|
"navigationConfig": [Function],
|
|
2287
2286
|
"previewAndTest": [Function],
|
|
@@ -18314,7 +18313,6 @@ new message content.",
|
|
|
18314
18313
|
"email": [Function],
|
|
18315
18314
|
"facebookPreview": [Function],
|
|
18316
18315
|
"gallery": [Function],
|
|
18317
|
-
"inApp": [Function],
|
|
18318
18316
|
"language": [Function],
|
|
18319
18317
|
"navigationConfig": [Function],
|
|
18320
18318
|
"previewAndTest": [Function],
|
|
@@ -34347,7 +34345,6 @@ new message content.",
|
|
|
34347
34345
|
"email": [Function],
|
|
34348
34346
|
"facebookPreview": [Function],
|
|
34349
34347
|
"gallery": [Function],
|
|
34350
|
-
"inApp": [Function],
|
|
34351
34348
|
"language": [Function],
|
|
34352
34349
|
"navigationConfig": [Function],
|
|
34353
34350
|
"previewAndTest": [Function],
|
|
@@ -50902,7 +50899,6 @@ new message content.",
|
|
|
50902
50899
|
"email": [Function],
|
|
50903
50900
|
"facebookPreview": [Function],
|
|
50904
50901
|
"gallery": [Function],
|
|
50905
|
-
"inApp": [Function],
|
|
50906
50902
|
"language": [Function],
|
|
50907
50903
|
"navigationConfig": [Function],
|
|
50908
50904
|
"previewAndTest": [Function],
|
|
@@ -68005,7 +68001,6 @@ new message content.",
|
|
|
68005
68001
|
"email": [Function],
|
|
68006
68002
|
"facebookPreview": [Function],
|
|
68007
68003
|
"gallery": [Function],
|
|
68008
|
-
"inApp": [Function],
|
|
68009
68004
|
"language": [Function],
|
|
68010
68005
|
"navigationConfig": [Function],
|
|
68011
68006
|
"previewAndTest": [Function],
|
|
@@ -84038,7 +84033,6 @@ new message content.",
|
|
|
84038
84033
|
"email": [Function],
|
|
84039
84034
|
"facebookPreview": [Function],
|
|
84040
84035
|
"gallery": [Function],
|
|
84041
|
-
"inApp": [Function],
|
|
84042
84036
|
"language": [Function],
|
|
84043
84037
|
"navigationConfig": [Function],
|
|
84044
84038
|
"previewAndTest": [Function],
|
|
@@ -103380,7 +103374,6 @@ new message content.",
|
|
|
103380
103374
|
"email": [Function],
|
|
103381
103375
|
"facebookPreview": [Function],
|
|
103382
103376
|
"gallery": [Function],
|
|
103383
|
-
"inApp": [Function],
|
|
103384
103377
|
"language": [Function],
|
|
103385
103378
|
"navigationConfig": [Function],
|
|
103386
103379
|
"previewAndTest": [Function],
|
|
@@ -122722,7 +122715,6 @@ new message content.",
|
|
|
122722
122715
|
"email": [Function],
|
|
122723
122716
|
"facebookPreview": [Function],
|
|
122724
122717
|
"gallery": [Function],
|
|
122725
|
-
"inApp": [Function],
|
|
122726
122718
|
"language": [Function],
|
|
122727
122719
|
"navigationConfig": [Function],
|
|
122728
122720
|
"previewAndTest": [Function],
|
|
@@ -142739,7 +142731,6 @@ new message content.",
|
|
|
142739
142731
|
"email": [Function],
|
|
142740
142732
|
"facebookPreview": [Function],
|
|
142741
142733
|
"gallery": [Function],
|
|
142742
|
-
"inApp": [Function],
|
|
142743
142734
|
"language": [Function],
|
|
142744
142735
|
"navigationConfig": [Function],
|
|
142745
142736
|
"previewAndTest": [Function],
|
|
@@ -158772,7 +158763,6 @@ new message content.",
|
|
|
158772
158763
|
"email": [Function],
|
|
158773
158764
|
"facebookPreview": [Function],
|
|
158774
158765
|
"gallery": [Function],
|
|
158775
|
-
"inApp": [Function],
|
|
158776
158766
|
"language": [Function],
|
|
158777
158767
|
"navigationConfig": [Function],
|
|
158778
158768
|
"previewAndTest": [Function],
|
|
@@ -174805,7 +174795,6 @@ new message content.",
|
|
|
174805
174795
|
"email": [Function],
|
|
174806
174796
|
"facebookPreview": [Function],
|
|
174807
174797
|
"gallery": [Function],
|
|
174808
|
-
"inApp": [Function],
|
|
174809
174798
|
"language": [Function],
|
|
174810
174799
|
"navigationConfig": [Function],
|
|
174811
174800
|
"previewAndTest": [Function],
|
|
@@ -190838,7 +190827,6 @@ new message content.",
|
|
|
190838
190827
|
"email": [Function],
|
|
190839
190828
|
"facebookPreview": [Function],
|
|
190840
190829
|
"gallery": [Function],
|
|
190841
|
-
"inApp": [Function],
|
|
190842
190830
|
"language": [Function],
|
|
190843
190831
|
"navigationConfig": [Function],
|
|
190844
190832
|
"previewAndTest": [Function],
|
|
@@ -2281,7 +2281,6 @@ new message content.",
|
|
|
2281
2281
|
"email": [Function],
|
|
2282
2282
|
"facebookPreview": [Function],
|
|
2283
2283
|
"gallery": [Function],
|
|
2284
|
-
"inApp": [Function],
|
|
2285
2284
|
"language": [Function],
|
|
2286
2285
|
"navigationConfig": [Function],
|
|
2287
2286
|
"previewAndTest": [Function],
|
|
@@ -13328,7 +13327,6 @@ new message content.",
|
|
|
13328
13327
|
"email": [Function],
|
|
13329
13328
|
"facebookPreview": [Function],
|
|
13330
13329
|
"gallery": [Function],
|
|
13331
|
-
"inApp": [Function],
|
|
13332
13330
|
"language": [Function],
|
|
13333
13331
|
"navigationConfig": [Function],
|
|
13334
13332
|
"previewAndTest": [Function],
|
|
@@ -24121,7 +24119,6 @@ new message content.",
|
|
|
24121
24119
|
"email": [Function],
|
|
24122
24120
|
"facebookPreview": [Function],
|
|
24123
24121
|
"gallery": [Function],
|
|
24124
|
-
"inApp": [Function],
|
|
24125
24122
|
"language": [Function],
|
|
24126
24123
|
"navigationConfig": [Function],
|
|
24127
24124
|
"previewAndTest": [Function],
|
|
@@ -34914,7 +34911,6 @@ new message content.",
|
|
|
34914
34911
|
"email": [Function],
|
|
34915
34912
|
"facebookPreview": [Function],
|
|
34916
34913
|
"gallery": [Function],
|
|
34917
|
-
"inApp": [Function],
|
|
34918
34914
|
"language": [Function],
|
|
34919
34915
|
"navigationConfig": [Function],
|
|
34920
34916
|
"previewAndTest": [Function],
|
|
@@ -40,7 +40,6 @@ export class TagList extends React.Component { // eslint-disable-line react/pref
|
|
|
40
40
|
tags: [],
|
|
41
41
|
tagsError: false,
|
|
42
42
|
currentContext: null, // Track current context to detect changes
|
|
43
|
-
hasTriggeredInitialApiCall: false, // Track if we've triggered API call when popover opens
|
|
44
43
|
};
|
|
45
44
|
this.renderTags = this.renderTags.bind(this);
|
|
46
45
|
this.populateTags = this.populateTags.bind(this);
|
|
@@ -52,14 +51,6 @@ export class TagList extends React.Component { // eslint-disable-line react/pref
|
|
|
52
51
|
|
|
53
52
|
componentDidMount() {
|
|
54
53
|
this.generateTags(this.props);
|
|
55
|
-
// Trigger initial API call if tags are empty (similar to Email/SMS behavior)
|
|
56
|
-
const { tags, injectedTags, onContextChange } = this.props;
|
|
57
|
-
const hasNoTags = (!tags || tags.length === 0) && _.isEmpty(injectedTags);
|
|
58
|
-
if (hasNoTags && onContextChange) {
|
|
59
|
-
// Trigger API call with default 'Outbound' context to match CapTagList default
|
|
60
|
-
// This ensures tags are loaded when component mounts
|
|
61
|
-
this.getTagsforContext('Outbound');
|
|
62
|
-
}
|
|
63
54
|
}
|
|
64
55
|
|
|
65
56
|
componentWillReceiveProps(nextProps) {
|
|
@@ -68,27 +59,23 @@ export class TagList extends React.Component { // eslint-disable-line react/pref
|
|
|
68
59
|
// 2. Context change is happening (detected by different tag arrays)
|
|
69
60
|
const { injectedTags: currentInjectedTags, tags: currentTags } = this.props;
|
|
70
61
|
const { injectedTags: nextInjectedTags, tags: nextTags, fetchingSchemaError } = nextProps;
|
|
71
|
-
|
|
62
|
+
|
|
72
63
|
const isInitialLoad = _.isEmpty(currentInjectedTags) && _.isEmpty(currentTags);
|
|
73
64
|
const isContextChange = !_.isEqual(nextTags, currentTags) && !_.isEmpty(currentTags);
|
|
74
|
-
|
|
65
|
+
|
|
75
66
|
if (isInitialLoad || isContextChange) {
|
|
76
67
|
this.setState({loading: true});
|
|
77
68
|
}
|
|
78
|
-
|
|
69
|
+
|
|
79
70
|
// Only reset loading for injectedTags changes if we're not currently loading due to context change
|
|
80
71
|
if (!_.isEqual(nextInjectedTags, currentInjectedTags) && !this.state.loading) {
|
|
81
72
|
this.setState({loading: false});
|
|
82
73
|
this.clearLoadingTimeout();
|
|
83
74
|
}
|
|
84
|
-
|
|
75
|
+
|
|
85
76
|
if (!_.isEqual(nextTags, currentTags)) {
|
|
86
77
|
this.setState({loading: false});
|
|
87
78
|
this.clearLoadingTimeout();
|
|
88
|
-
// Reset the flag when tags are received, so we can trigger API call again if needed
|
|
89
|
-
if (nextTags && nextTags.length > 0) {
|
|
90
|
-
this.setState({ hasTriggeredInitialApiCall: false });
|
|
91
|
-
}
|
|
92
79
|
}
|
|
93
80
|
if (fetchingSchemaError) {
|
|
94
81
|
this.setState({tagsError: fetchingSchemaError, loading: false});
|
|
@@ -99,7 +86,7 @@ export class TagList extends React.Component { // eslint-disable-line react/pref
|
|
|
99
86
|
componentDidUpdate(prevProps) {
|
|
100
87
|
const { tags, injectedTags, selectedOfferDetails } = this.props;
|
|
101
88
|
const { tags: prevTags, injectedTags: prevInjectedTags, selectedOfferDetails: prevSelectedOfferDetails } = prevProps;
|
|
102
|
-
|
|
89
|
+
|
|
103
90
|
if (tags !== prevTags || injectedTags !== prevInjectedTags || selectedOfferDetails !== prevSelectedOfferDetails) {
|
|
104
91
|
this.generateTags(this.props);
|
|
105
92
|
}
|
|
@@ -124,44 +111,17 @@ export class TagList extends React.Component { // eslint-disable-line react/pref
|
|
|
124
111
|
getTagsforContext = (data) => {
|
|
125
112
|
// Set loading state when context change is requested
|
|
126
113
|
this.setState({loading: true, currentContext: data});
|
|
127
|
-
|
|
114
|
+
|
|
128
115
|
// Set a timeout to prevent infinite loading (fallback safety)
|
|
129
116
|
this.clearLoadingTimeout();
|
|
130
117
|
this.loadingTimeout = setTimeout(() => {
|
|
131
118
|
this.setState({loading: false});
|
|
132
119
|
}, 5000); // Reduced timeout to 5 seconds for better UX
|
|
133
|
-
|
|
120
|
+
|
|
134
121
|
const { onContextChange } = this.props;
|
|
135
|
-
|
|
136
|
-
// The API call will fetch tags from /meta/TAG endpoint
|
|
137
|
-
if (onContextChange) {
|
|
138
|
-
onContextChange(data);
|
|
139
|
-
} else {
|
|
140
|
-
console.warn('TagList: onContextChange is not available. API call will not be triggered.');
|
|
141
|
-
}
|
|
122
|
+
onContextChange(data);
|
|
142
123
|
}
|
|
143
124
|
|
|
144
|
-
handlePopoverVisibilityChange = (visible) => {
|
|
145
|
-
// When popover opens, trigger API call if tags are empty or if we haven't triggered it yet
|
|
146
|
-
// This ensures API call happens when user clicks "Add Label" button
|
|
147
|
-
if (visible && this.props.onContextChange) {
|
|
148
|
-
const { tags, injectedTags } = this.props;
|
|
149
|
-
// Check if tags array is empty or if state tags are empty
|
|
150
|
-
const hasNoTags = (!tags || tags.length === 0) && _.isEmpty(injectedTags);
|
|
151
|
-
const hasNoStateTags = _.isEmpty(this.state.tags);
|
|
152
|
-
const hasNotTriggeredApiCall = !this.state.hasTriggeredInitialApiCall;
|
|
153
|
-
|
|
154
|
-
// Trigger API call if tags are not loaded yet OR if we haven't triggered it yet
|
|
155
|
-
if ((hasNoTags || hasNoStateTags || hasNotTriggeredApiCall)) {
|
|
156
|
-
// Mark that we've triggered the API call
|
|
157
|
-
this.setState({ hasTriggeredInitialApiCall: true });
|
|
158
|
-
// Trigger API call with default 'Outbound' context to match CapTagList default
|
|
159
|
-
// This will call onContextChange which triggers handleOnTagsContextChange in InApp
|
|
160
|
-
this.getTagsforContext('Outbound');
|
|
161
|
-
}
|
|
162
|
-
}
|
|
163
|
-
};
|
|
164
|
-
|
|
165
125
|
generateTags = (props) => {
|
|
166
126
|
let tags = {};
|
|
167
127
|
let injectedTags = {};
|
|
@@ -189,11 +149,11 @@ export class TagList extends React.Component { // eslint-disable-line react/pref
|
|
|
189
149
|
if (eventContextTags?.length) {
|
|
190
150
|
const TAG_HEADER_MSG_LABEL = this.props.intl.formatMessage(messages.entryEvent);
|
|
191
151
|
eventContextTagsObj.eventContextTags = {
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
152
|
+
name: TAG_HEADER_MSG_LABEL,
|
|
153
|
+
desc: TAG_HEADER_MSG_LABEL,
|
|
154
|
+
resolved: true,
|
|
195
155
|
'tag-header': true,
|
|
196
|
-
|
|
156
|
+
subtags: {},
|
|
197
157
|
};
|
|
198
158
|
|
|
199
159
|
eventContextTags.forEach((tag) => {
|
|
@@ -204,11 +164,11 @@ export class TagList extends React.Component { // eslint-disable-line react/pref
|
|
|
204
164
|
// Initializing the tags profile if it doesn't exist
|
|
205
165
|
if (!eventContextTagsObj?.eventContextTags?.subtags?.[profileId]) {
|
|
206
166
|
eventContextTagsObj.eventContextTags.subtags[profileId] = {
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
167
|
+
name: profileName,
|
|
168
|
+
desc: profileName,
|
|
169
|
+
resolved: true,
|
|
210
170
|
'tag-header': true,
|
|
211
|
-
|
|
171
|
+
subtags: {},
|
|
212
172
|
};
|
|
213
173
|
}
|
|
214
174
|
// Adding the current tag to the profile group
|
|
@@ -241,7 +201,7 @@ export class TagList extends React.Component { // eslint-disable-line react/pref
|
|
|
241
201
|
_.forEach(tagsList, (temp) => {
|
|
242
202
|
const tag = temp.definition;
|
|
243
203
|
const { intl } = this.props;
|
|
244
|
-
|
|
204
|
+
const { locale: userLocale } = intl || {};
|
|
245
205
|
|
|
246
206
|
// Check if the tag.value should be skipped based on feature control
|
|
247
207
|
if (_.includes(excludedTags, tag.value)) {
|
|
@@ -249,8 +209,8 @@ export class TagList extends React.Component { // eslint-disable-line react/pref
|
|
|
249
209
|
}
|
|
250
210
|
if (!tag['tag-header']) {
|
|
251
211
|
mainTags[tag.value] = {
|
|
252
|
-
name: tag?.label[userLocale] ? tag?.label[userLocale] : tag?.label?.en,
|
|
253
|
-
desc: tag?.label[userLocale] ? tag?.label[userLocale] : tag?.label?.en,
|
|
212
|
+
"name": tag?.label[userLocale] ? tag?.label[userLocale] : tag?.label?.en,
|
|
213
|
+
"desc": tag?.label[userLocale] ? tag?.label[userLocale] : tag?.label?.en,
|
|
254
214
|
};
|
|
255
215
|
} else if (tag['tag-header'] && mainTags[tag.value]) {
|
|
256
216
|
mainTags[tag.value].subtags = _.concat(mainTags[tag.value].subtags, tag.subtags);
|
|
@@ -406,14 +366,12 @@ export class TagList extends React.Component { // eslint-disable-line react/pref
|
|
|
406
366
|
visibleTaglist={this.props.visibleTaglist}
|
|
407
367
|
hidePopover={this.props.hidePopover}
|
|
408
368
|
onContextChange={this.getTagsforContext}
|
|
409
|
-
onVisibleChange={this.handlePopoverVisibilityChange}
|
|
410
369
|
moduleFilterEnabled={this.props.moduleFilterEnabled}
|
|
411
370
|
modalProps={this.props.modalProps}
|
|
412
371
|
currentOrgDetails={this.props.currentOrgDetails}
|
|
413
372
|
channel={this.props.channel}
|
|
414
373
|
disabled={this.props.disabled}
|
|
415
374
|
fetchingSchemaError={this?.state?.tagsError}
|
|
416
|
-
popoverPlacement={this.props.popoverPlacement}
|
|
417
375
|
/>
|
|
418
376
|
</div>
|
|
419
377
|
);
|
|
@@ -444,7 +402,6 @@ TagList.propTypes = {
|
|
|
444
402
|
disabled: PropTypes.bool,
|
|
445
403
|
fetchingSchemaError: PropTypes.bool,
|
|
446
404
|
eventContextTags: PropTypes.array,
|
|
447
|
-
popoverPlacement: PropTypes.string,
|
|
448
405
|
intl: PropTypes.shape({
|
|
449
406
|
formatMessage: PropTypes.func.isRequired,
|
|
450
407
|
locale: PropTypes.string,
|
|
@@ -14,7 +14,7 @@ import inAppIllustration from '@capillarytech/cap-ui-library/assets/images/featu
|
|
|
14
14
|
import messages from './messages';
|
|
15
15
|
import { FormattedMessage } from 'react-intl';
|
|
16
16
|
import { CapIllustration } from "@capillarytech/cap-ui-library";
|
|
17
|
-
import { MOBILE_PUSH, SMS, EMAIL, LINE, VIBER, FACEBOOK, WHATSAPP, RCS, ZALO, INAPP
|
|
17
|
+
import { MOBILE_PUSH, SMS, EMAIL, LINE, VIBER, FACEBOOK, WHATSAPP, RCS, ZALO, INAPP } from '../CreativesContainer/constants';
|
|
18
18
|
|
|
19
19
|
|
|
20
20
|
// Configuration object for channel types
|
|
@@ -133,18 +133,6 @@ function ChannelTypeIllustration(props) {
|
|
|
133
133
|
};
|
|
134
134
|
}
|
|
135
135
|
|
|
136
|
-
if (type === WEBPUSH) {
|
|
137
|
-
return {
|
|
138
|
-
buttonLabel: <FormattedMessage {...messages.newWebPushTemplate} values={{ template: templateText }} />,
|
|
139
|
-
onClick: createTemplate,
|
|
140
|
-
illustrationImage: pushIllustration,
|
|
141
|
-
title: <FormattedMessage {...messages.webPushTitleIllustration} values={{ template: templateText }} />,
|
|
142
|
-
description: <FormattedMessage {...messages.webPushDescIllustration} />,
|
|
143
|
-
descriptionPosition: 'bottom',
|
|
144
|
-
descriptionClassName: 'illustration-desc',
|
|
145
|
-
};
|
|
146
|
-
}
|
|
147
|
-
|
|
148
136
|
// Handle standard channels using configuration
|
|
149
137
|
const config = CHANNEL_CONFIG[type];
|
|
150
138
|
if (!config) {
|