@capillarytech/creatives-library 7.17.82-alpha.0 → 7.17.82
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/containers/Cap/sagas.js +7 -5
- package/containers/Cap/tests/saga.test.js +81 -1
- package/package.json +2 -2
- package/v2Components/CapWhatsappQuickReply/index.js +96 -83
- package/v2Components/CapWhatsappQuickReply/index.scss +4 -1
- package/v2Components/CapWhatsappQuickReply/messages.js +4 -0
- package/v2Components/TemplatePreview/_templatePreview.scss +3 -0
- package/v2Components/TemplatePreview/index.js +10 -25
- package/v2Components/TemplatePreview/tests/__snapshots__/index.test.js.snap +0 -14
- package/v2Containers/CreativesContainer/index.js +18 -2
- package/v2Containers/CreativesContainer/tests/__snapshots__/SlideBoxContent.test.js.snap +4 -4
- package/v2Containers/Templates/index.js +3 -3
- package/v2Containers/Whatsapp/constants.js +2 -1
- package/v2Containers/Whatsapp/index.js +280 -251
- package/v2Containers/Whatsapp/index.scss +6 -1
- package/v2Containers/Whatsapp/messages.js +5 -0
- package/v2Containers/Whatsapp/styles.scss +6 -3
- package/v2Containers/Whatsapp/tests/__snapshots__/index.test.js.snap +4586 -53228
- package/v2Containers/Whatsapp/tests/__snapshots__/utils.test.js.snap +20 -20
- package/v2Containers/Whatsapp/utils.js +13 -13
- package/v2Containers/mockdata.js +8 -18
|
@@ -1174,7 +1174,7 @@ export class Templates extends React.Component { // eslint-disable-line react/pr
|
|
|
1174
1174
|
break;
|
|
1175
1175
|
}
|
|
1176
1176
|
case WHATSAPP: {
|
|
1177
|
-
const { whatsappImageSrc = '', templateMsg, docPreview, whatsappVideoPreviewImg = '',
|
|
1177
|
+
const { whatsappImageSrc = '', templateMsg, docPreview, whatsappVideoPreviewImg = '', templateHeaderPreview, templateFooterPreview} = getWhatsappContent(template);
|
|
1178
1178
|
templateData.title = (
|
|
1179
1179
|
<CapRow>
|
|
1180
1180
|
<CapLabel className="whatsapp-rcs-template-name">{template?.name}</CapLabel>
|
|
@@ -1205,9 +1205,9 @@ export class Templates extends React.Component { // eslint-disable-line react/pr
|
|
|
1205
1205
|
: 'whatsapp-message-without-media'
|
|
1206
1206
|
}`}
|
|
1207
1207
|
>
|
|
1208
|
-
{
|
|
1208
|
+
{templateHeaderPreview}
|
|
1209
1209
|
{templateMsg}
|
|
1210
|
-
{
|
|
1210
|
+
{templateFooterPreview}
|
|
1211
1211
|
</span>
|
|
1212
1212
|
{getWhatsappCta(template)}
|
|
1213
1213
|
{getWhatsappQuickReply(template)}
|
|
@@ -13,7 +13,7 @@ export const UNSUBSCRIBE_TEXT_LENGTH = 36;
|
|
|
13
13
|
export const TEMPLATE_MESSAGE_MAX_LENGTH = 1024;
|
|
14
14
|
export const WHATSAPP = 'WHATSAPP';
|
|
15
15
|
export const TEMPLATE_HEADER_MAX_LENGTH = 60;
|
|
16
|
-
export const
|
|
16
|
+
export const QUICK_REPLY_BUTTON_TEXT_MAX_LENGTH = 20;
|
|
17
17
|
|
|
18
18
|
const prefix = 'app/v2Containers/Whatsapp';
|
|
19
19
|
export const TEMPLATE_CREATE_REQUEST = `${prefix}/TEMPLATE_CREATE_REQUEST`;
|
|
@@ -183,6 +183,7 @@ export const QUICK_REPLY = 'QUICK_REPLY';
|
|
|
183
183
|
export const HEADER_TEXT = 'header';
|
|
184
184
|
export const FOOTER_TEXT = 'footer';
|
|
185
185
|
export const MESSAGE_TEXT = 'message';
|
|
186
|
+
export const BUTTON_TEXT = 'buttonText'
|
|
186
187
|
export const WHATSAPP_BUTTON_TYPES = {
|
|
187
188
|
NONE,
|
|
188
189
|
CTA,
|