@capillarytech/creatives-library 8.0.339 → 8.0.340-beta.0

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 (159) hide show
  1. package/app.js +8 -1
  2. package/global-styles.js +4 -0
  3. package/package.json +2 -2
  4. package/styles/components/navigation/_leftnav.scss +1 -1
  5. package/utils/tests/tagValidations.test.js +20 -0
  6. package/v2Components/AccessForbidden/index.js +1 -1
  7. package/v2Components/CapActionButton/index.js +5 -5
  8. package/v2Components/CapCustomSkeleton/index.js +1 -1
  9. package/v2Components/CapDeviceContent/index.js +5 -5
  10. package/v2Components/CapDocumentUpload/index.js +1 -1
  11. package/v2Components/CapImageUpload/index.js +1 -1
  12. package/v2Components/CapInAppCTA/index.js +118 -112
  13. package/v2Components/CapMpushCTA/index.js +72 -66
  14. package/v2Components/CapTagList/index.js +32 -27
  15. package/v2Components/CapTagList/style.scss +29 -0
  16. package/v2Components/CapTagListWithInput/__tests__/CapTagListWithInput.test.js +63 -0
  17. package/v2Components/CapTagListWithInput/index.js +4 -0
  18. package/v2Components/CapVideoUpload/index.js +1 -1
  19. package/v2Components/CapWhatsappCTA/index.js +130 -124
  20. package/v2Components/CapWhatsappCarouselButton/index.js +27 -29
  21. package/v2Components/CapWhatsappQuickReply/index.js +7 -7
  22. package/v2Components/Carousel/index.js +1 -1
  23. package/v2Components/CommonTestAndPreview/AddTestCustomer.js +1 -1
  24. package/v2Components/CommonTestAndPreview/CustomValuesEditor.js +3 -3
  25. package/v2Components/CommonTestAndPreview/CustomerCreationModal.js +1 -1
  26. package/v2Components/CommonTestAndPreview/DeliverySettings/ModifyDeliverySettings.js +4 -4
  27. package/v2Components/CommonTestAndPreview/DeliverySettings/index.js +1 -1
  28. package/v2Components/CommonTestAndPreview/ExistingCustomerModal.js +6 -6
  29. package/v2Components/CommonTestAndPreview/LeftPanelContent.js +5 -5
  30. package/v2Components/CommonTestAndPreview/PreviewSection.js +1 -1
  31. package/v2Components/CommonTestAndPreview/UnifiedPreview/DeviceFrame.js +1 -1
  32. package/v2Components/CommonTestAndPreview/UnifiedPreview/EmailPreviewContent.js +8 -8
  33. package/v2Components/CommonTestAndPreview/UnifiedPreview/InAppPreviewContent.js +14 -13
  34. package/v2Components/CommonTestAndPreview/UnifiedPreview/MobilePushPreviewContent.js +22 -21
  35. package/v2Components/CommonTestAndPreview/UnifiedPreview/RcsPreviewContent.js +9 -9
  36. package/v2Components/CommonTestAndPreview/UnifiedPreview/SmsPreviewContent.js +8 -8
  37. package/v2Components/CommonTestAndPreview/UnifiedPreview/ViberPreviewContent.js +10 -10
  38. package/v2Components/CommonTestAndPreview/UnifiedPreview/WhatsAppPreviewContent.js +13 -12
  39. package/v2Components/CommonTestAndPreview/UnifiedPreview/ZaloPreviewContent.js +4 -3
  40. package/v2Components/CommonTestAndPreview/UnifiedPreview/_unifiedPreview.scss +10 -5
  41. package/v2Components/CommonTestAndPreview/UnifiedPreview/index.js +1 -1
  42. package/v2Components/CommonTestAndPreview/_commonTestAndPreview.scss +3 -4
  43. package/v2Components/CommonTestAndPreview/index.js +1 -1
  44. package/v2Components/CustomerSearchSection/_customerSearch.scss +2 -1
  45. package/v2Components/CustomerSearchSection/index.js +9 -9
  46. package/v2Components/EmailMobilePreview/index.js +1 -1
  47. package/v2Components/ErrorInfoNote/index.js +13 -11
  48. package/v2Components/ErrorInfoNote/style.scss +1 -1
  49. package/v2Components/FormBuilder/_formBuilder.scss +1 -0
  50. package/v2Components/FormBuilder/index.js +39 -40
  51. package/v2Components/HtmlEditor/HTMLEditor.js +10 -5
  52. package/v2Components/HtmlEditor/__tests__/HTMLEditor.apiErrors.test.js +1 -0
  53. package/v2Components/HtmlEditor/__tests__/HTMLEditor.test.js +927 -2
  54. package/v2Components/HtmlEditor/_htmlEditor.scss +2 -1
  55. package/v2Components/HtmlEditor/components/CodeEditorPane/index.js +4 -1
  56. package/v2Components/HtmlEditor/components/DeviceToggle/_deviceToggle.scss +2 -2
  57. package/v2Components/HtmlEditor/components/DeviceToggle/index.js +2 -2
  58. package/v2Components/HtmlEditor/components/EditorToolbar/PreviewModeGroup.js +2 -2
  59. package/v2Components/HtmlEditor/components/EditorToolbar/index.js +2 -2
  60. package/v2Components/HtmlEditor/components/InAppPreviewPane/index.js +1 -0
  61. package/v2Components/HtmlEditor/components/PreviewPane/index.js +2 -2
  62. package/v2Components/HtmlEditor/components/SplitContainer/SplitContainer.js +2 -2
  63. package/v2Components/HtmlEditor/components/SplitContainer/_splitContainer.scss +2 -1
  64. package/v2Components/HtmlEditor/components/ValidationPanel/index.js +6 -9
  65. package/v2Components/HtmlEditor/components/ValidationTabs/index.js +2 -2
  66. package/v2Components/NavigationBar/index.js +7 -1
  67. package/v2Components/TemplatePreview/WechatRichmediaTemplatePreview/index.js +3 -4
  68. package/v2Components/TemplatePreview/_templatePreview.scss +5 -3
  69. package/v2Components/TemplatePreview/index.js +11 -9
  70. package/v2Components/TestAndPreviewSlidebox/CustomValuesEditor.js +3 -3
  71. package/v2Components/TestAndPreviewSlidebox/LeftPanelContent.js +5 -5
  72. package/v2Components/TestAndPreviewSlidebox/PreviewSection.js +3 -3
  73. package/v2Components/TestAndPreviewSlidebox/_testAndPreviewSlidebox.scss +4 -2
  74. package/v2Containers/BeeEditor/index.js +3 -0
  75. package/v2Containers/BeePopupEditor/index.js +1 -1
  76. package/v2Containers/CommunicationFlow/CommunicationFlow.js +5 -5
  77. package/v2Containers/CommunicationFlow/steps/ChannelSelectionStep/ChannelSelectionStep.js +4 -3
  78. package/v2Containers/CommunicationFlow/steps/CommunicationStrategyStep/CommunicationStrategyStep.js +2 -2
  79. package/v2Containers/CommunicationFlow/steps/DeliverySettingsStep/DeliverySettingsSection.js +3 -2
  80. package/v2Containers/CommunicationFlow/steps/DeliverySettingsStep/SenderDetails.js +7 -7
  81. package/v2Containers/CommunicationFlow/steps/DeliverySettingsStep/SenderDetails.scss +0 -5
  82. package/v2Containers/CommunicationFlow/steps/DynamicControlsStep/DynamicControlsStep.js +2 -2
  83. package/v2Containers/CommunicationFlow/steps/MessageTypeStep/MessageTypeStep.js +2 -2
  84. package/v2Containers/CreativesContainer/SlideBoxContent.js +28 -1
  85. package/v2Containers/CreativesContainer/SlideBoxFooter.js +1 -1
  86. package/v2Containers/CreativesContainer/index.js +4 -1
  87. package/v2Containers/CreativesContainer/tests/__snapshots__/SlideBoxContent.test.js.snap +47 -0
  88. package/v2Containers/CreativesContainer/tests/__snapshots__/index.test.js.snap +5 -0
  89. package/v2Containers/Ebill/index.js +10 -9
  90. package/v2Containers/Email/index.js +8 -7
  91. package/v2Containers/Email/initialSchema.js +1 -1
  92. package/v2Containers/EmailWrapper/components/EmailHTMLEditor.js +6 -1
  93. package/v2Containers/EmailWrapper/components/EmailWrapperView.js +3 -0
  94. package/v2Containers/EmailWrapper/components/__tests__/EmailHTMLEditor.test.js +20 -2
  95. package/v2Containers/EmailWrapper/components/__tests__/EmailWrapperView.test.js +16 -1
  96. package/v2Containers/EmailWrapper/hooks/useEmailWrapper.js +3 -0
  97. package/v2Containers/EmailWrapper/index.js +4 -0
  98. package/v2Containers/EmailWrapper/tests/useEmailWrapper.edgeCases.test.js +1 -0
  99. package/v2Containers/EmailWrapper/tests/useEmailWrapper.test.js +9 -0
  100. package/v2Containers/FTP/index.js +1 -1
  101. package/v2Containers/Facebook/Advertisement/index.js +4 -4
  102. package/v2Containers/Facebook/index.js +2 -2
  103. package/v2Containers/InApp/index.js +21 -16
  104. package/v2Containers/InApp/index.scss +0 -7
  105. package/v2Containers/InAppWrapper/components/InAppWrapperView.js +2 -2
  106. package/v2Containers/InAppWrapper/hooks/__tests__/useInAppWrapper.test.js +1 -0
  107. package/v2Containers/InappAdvance/index.js +4 -4
  108. package/v2Containers/LanguageProvider/index.js +3 -3
  109. package/v2Containers/LanguageProvider/tests/index.test.js +3 -3
  110. package/v2Containers/Line/Container/Image/index.js +1 -1
  111. package/v2Containers/Line/Container/ImageCarousel/Content.js +1 -1
  112. package/v2Containers/Line/Container/ImageCarousel/index.js +5 -5
  113. package/v2Containers/Line/Container/ImageMap/index.js +3 -3
  114. package/v2Containers/Line/Container/Sticker/index.js +2 -2
  115. package/v2Containers/Line/Container/Sticker/utils.js +1 -1
  116. package/v2Containers/Line/Container/Video/index.js +1 -1
  117. package/v2Containers/Line/Container/Wrapper/index.js +3 -3
  118. package/v2Containers/Line/Container/Wrapper/style.js +1 -5
  119. package/v2Containers/Line/Container/index.js +2 -2
  120. package/v2Containers/Login/components/LoginForm/index.js +34 -47
  121. package/v2Containers/Login/index.js +5 -5
  122. package/v2Containers/MobilePush/Create/index.js +2 -0
  123. package/v2Containers/MobilePush/Edit/index.js +2 -0
  124. package/v2Containers/MobilePushNew/components/CtaButtons.js +2 -2
  125. package/v2Containers/MobilePushNew/components/MediaUploaders.js +9 -9
  126. package/v2Containers/MobilePushNew/components/PlatformContentFields.js +4 -4
  127. package/v2Containers/MobilePushNew/index.js +2 -2
  128. package/v2Containers/MobilePushNew/index.scss +6 -3
  129. package/v2Containers/MobilepushWrapper/index.js +3 -1
  130. package/v2Containers/Rcs/index.js +25 -19
  131. package/v2Containers/Rcs/index.scss +0 -7
  132. package/v2Containers/Sms/Create/index.js +2 -0
  133. package/v2Containers/Sms/Edit/index.js +2 -0
  134. package/v2Containers/SmsTrai/Edit/index.js +5 -2
  135. package/v2Containers/SmsWrapper/index.js +2 -0
  136. package/v2Containers/TagList/index.js +62 -5
  137. package/v2Containers/TagList/messages.js +4 -0
  138. package/v2Containers/TagList/tests/TagList.test.js +124 -20
  139. package/v2Containers/TagList/tests/mockdata.js +17 -0
  140. package/v2Containers/Templates/index.js +16 -16
  141. package/v2Containers/Viber/index.js +22 -14
  142. package/v2Containers/Viber/index.scss +0 -7
  143. package/v2Containers/WeChat/RichmediaTemplates/Create/_createRichmedia.scss +1 -1
  144. package/v2Containers/WeChat/RichmediaTemplates/Create/index.js +2 -2
  145. package/v2Containers/WebPush/Create/components/BrandIconSection.js +1 -1
  146. package/v2Containers/WebPush/Create/components/ButtonForm.js +2 -2
  147. package/v2Containers/WebPush/Create/components/ButtonList.js +4 -4
  148. package/v2Containers/WebPush/Create/components/ButtonsLinksSection.js +4 -4
  149. package/v2Containers/WebPush/Create/components/FormActions.js +3 -3
  150. package/v2Containers/WebPush/Create/components/MessageSection.js +2 -2
  151. package/v2Containers/WebPush/Create/components/NotificationTitleSection.js +2 -2
  152. package/v2Containers/WebPush/Create/components/_buttons.scss +2 -2
  153. package/v2Containers/WebPush/Create/hooks/useTagManagement.js +0 -2
  154. package/v2Containers/WebPush/Create/index.js +9 -1
  155. package/v2Containers/WebPush/Create/index.scss +6 -3
  156. package/v2Containers/WebPush/Create/preview/WebPushPreview.js +1 -1
  157. package/v2Containers/Whatsapp/index.js +33 -28
  158. package/v2Containers/Whatsapp/tests/__snapshots__/index.test.js.snap +20 -0
  159. package/v2Containers/Zalo/index.js +5 -3
@@ -253,7 +253,7 @@ export const LineImageCarousel = (props) => {
253
253
  <>
254
254
  <CapButton
255
255
  onClick={addContent}
256
- type="flat"
256
+ type="link"
257
257
  disabled={MAX_CAROUSEL_ALLOWED === carouselImages.length}
258
258
  isAddBtn
259
259
  style={{ padding: 0, marginTop: 12 }}
@@ -274,7 +274,7 @@ export const LineImageCarousel = (props) => {
274
274
  <CapButton
275
275
  onClick={duplicateContent}
276
276
  disabled={MAX_CAROUSEL_ALLOWED === carouselImages.length}
277
- type="flat"
277
+ type="link"
278
278
  >
279
279
  <CapIcon type="copy" size="s" />
280
280
  </CapButton>
@@ -285,7 +285,7 @@ export const LineImageCarousel = (props) => {
285
285
  <CapButton
286
286
  onClick={shiftLeftContent}
287
287
  disabled={defaultActiveIndex === Number(activeIndex)}
288
- type="flat"
288
+ type="link"
289
289
  >
290
290
  <CapIcon type="left" size="s" />
291
291
  </CapButton>
@@ -296,7 +296,7 @@ export const LineImageCarousel = (props) => {
296
296
  <CapButton
297
297
  onClick={shiftRightContent}
298
298
  disabled={carouselImages.length === (Number(activeIndex) + 1)}
299
- type="flat"
299
+ type="link"
300
300
  >
301
301
  <CapIcon type="right" size="s" />
302
302
  </CapButton>
@@ -307,7 +307,7 @@ export const LineImageCarousel = (props) => {
307
307
  <CapButton
308
308
  onClick={deleteContent}
309
309
  disabled={1 === carouselImages.length}
310
- type="flat"
310
+ type="link"
311
311
  >
312
312
  <CapIcon type="delete" size="s" />
313
313
  </CapButton>
@@ -284,7 +284,7 @@ export const LineImageMap = ({
284
284
  assetType === DEFAULT_ASSET_TYPE ? formatMessage(messages.squareAssetDesc) : formatMessage(messages.customAssetDesc)
285
285
  }
286
286
  </CapLabel>
287
- <CapRow>
287
+ <CapRow useLegacy>
288
288
  {getTemplatesSelection()}
289
289
  </CapRow>
290
290
  </>
@@ -301,7 +301,7 @@ export const LineImageMap = ({
301
301
  return (
302
302
  <CapColumn span={12} key={template}>
303
303
  <CapButton
304
- type="flat"
304
+ type="link"
305
305
  style={{ padding: 0, marginTop: CAP_SPACE_12, marginRight: CAP_SPACE_16, height: 'auto' }}
306
306
  onClick={() => changeImageMapTemplate(template)}
307
307
  >
@@ -537,7 +537,7 @@ export const LineImageMap = ({
537
537
  {isImage &&
538
538
  <CapButton
539
539
  className="dragger-button"
540
- type="flat"
540
+ type="link"
541
541
  style={{ top: 180 , position: 'absolute', right: 0, color: FONT_COLOR_05 }}
542
542
  onClick={onReUpload}
543
543
  >
@@ -114,7 +114,7 @@ export const LineSticker = ({
114
114
  }}
115
115
  />
116
116
  <CapButton
117
- type="flat"
117
+ type="link"
118
118
  style={{ padding: 0, top: -34, right: 8 }}
119
119
  onClick={removeSelectedSticker}
120
120
  >
@@ -192,7 +192,7 @@ export const LineSticker = ({
192
192
  ? (
193
193
  <CapButton
194
194
  onClick={removeSelectedSticker}
195
- type="flat"
195
+ type="link"
196
196
  style={{
197
197
  padding: 0,
198
198
  marginLeft: 400,
@@ -40,7 +40,7 @@ export const getContent = ({ lineStickers, onStickerSelect }) => (
40
40
  }) => (
41
41
  <CapColumn span={6} key={_id}>
42
42
  <CapButton
43
- type="flat"
43
+ type="link"
44
44
  style={{ padding: 0, margin: 10, height: 'auto' }}
45
45
  onClick={() => onStickerSelect(definition)}
46
46
  >
@@ -387,7 +387,7 @@ export const LineVideo = ({
387
387
  <div style={{ overflow: 'hidden' }}>
388
388
  <CapButton
389
389
  className="dragger-button"
390
- type="flat"
390
+ type="link"
391
391
  style={{
392
392
  float: 'right',
393
393
  color: FONT_COLOR_05,
@@ -101,7 +101,7 @@ export const LineWrapper = ({
101
101
  const operations = (
102
102
  <>
103
103
  <CapButton
104
- type="flat"
104
+ type="link"
105
105
  onClick={() => shiftUp(index)}
106
106
  disabled={index === 0 || rest.isFullMode}
107
107
  style={{ padding: 0 }}
@@ -109,7 +109,7 @@ export const LineWrapper = ({
109
109
  <CapIcon type="back" size="s" style={{ transform: 'rotate(90deg)'}}/>
110
110
  </CapButton>
111
111
  <CapButton
112
- type="flat"
112
+ type="link"
113
113
  onClick={() => shiftDown(index)}
114
114
  style={{ padding: `0 0 0 ${CAP_SPACE_08}` }}
115
115
  disabled={(index+1) === lineWrappers || rest.isFullMode}
@@ -117,7 +117,7 @@ export const LineWrapper = ({
117
117
  <CapIcon type="back" size="s" style={{ transform: 'rotate(270deg)'}}/>
118
118
  </CapButton>
119
119
  <CapButton
120
- type="flat"
120
+ type="link"
121
121
  onClick={() => deleteWrapper(index)}
122
122
  disabled={rest.isFullMode || lineWrappers === 1}
123
123
  style={{ padding: `0 ${CAP_SPACE_16} 0 ${CAP_SPACE_16}`, marginRight: -20 }}
@@ -27,15 +27,11 @@ export default css`
27
27
  `;
28
28
 
29
29
  export const CapModalStyles = css`
30
- .ant-modal.cap-modal-v2 {
31
- max-width: unset;
32
- }
33
-
34
30
  .modal-description {
35
31
  margin-top: ${CAP_SPACE_12};
36
32
  }
37
33
 
38
- .ant-modal.cap-modal-v2 .ant-modal-footer {
34
+ .ant-modal-footer {
39
35
  padding-bottom: ${CAP_SPACE_20};
40
36
  padding-left: ${CAP_SPACE_24};
41
37
  }
@@ -789,7 +789,7 @@ export const LineContainer = ({
789
789
  <span>{accountName}</span>
790
790
  <CapButton
791
791
  onClick={onShowTemplates}
792
- type="flat"
792
+ type="link"
793
793
  style={{ fontWeight: 500, color: FONT_COLOR_05 }}
794
794
  >
795
795
  <FormattedMessage {...messages.changeAccount} />
@@ -821,7 +821,7 @@ export const LineContainer = ({
821
821
  <CapButton
822
822
  onClick={addLineWrappers}
823
823
  disabled={lineWrapperContents.length === (isFullMode ? MAX_LINE_WRAPPER_LIMIT_FULL_MODE : MAX_LINE_WRAPPER_LIMIT)}
824
- type="flat"
824
+ type="link"
825
825
  isAddBtn
826
826
  className="add-msg"
827
827
  >
@@ -1,62 +1,49 @@
1
1
  import PropTypes from 'prop-types';
2
2
  import React from 'react';
3
- import { Form, Icon } from 'antd';
4
- import { CapInput, CapButton } from '@capillarytech/cap-ui-library';
3
+ import { Form } from 'antd';
4
+ import { CapInput, CapButton, CapIcon } from '@capillarytech/cap-ui-library';
5
5
  import { injectIntl, intlShape } from 'react-intl';
6
6
  import messages from './messages';
7
7
  const FormItem = Form.Item;
8
8
 
9
- class NormalLoginForm extends React.Component {
10
- handleSubmit = (e) => {
11
- e.preventDefault();
12
- this.props.form.validateFields((err, values) => {
13
- if (!err) {
14
- this.props.authenticate(values);
9
+ const NormalLoginForm = ({ authenticate, loginInProgress, isError, intl }) => {
10
+ const [form] = Form.useForm();
11
+ return (
12
+ <Form form={form} onFinish={(values) => authenticate(values)} className="login-form">
13
+ <FormItem
14
+ className="login-form-item"
15
+ name="username"
16
+ rules={[{ required: true, message: intl.formatMessage(messages.inputUsernameMandatory) }]}
17
+ >
18
+ <CapInput prefix={<CapIcon type="user" outlined style={{ fontSize: 13 }} />} placeholder={intl.formatMessage(messages.username)} />
19
+ </FormItem>
20
+ <FormItem
21
+ className="login-form-item"
22
+ name="password"
23
+ rules={[{ required: true, message: intl.formatMessage(messages.inputPasswordMandatory) }]}
24
+ >
25
+ <CapInput prefix={<CapIcon type="lock" outlined style={{ fontSize: 13 }} />} type="password" placeholder={intl.formatMessage(messages.password)} />
26
+ </FormItem>
27
+ {isError
28
+ ? <FormItem>
29
+ <span style={{color: "red"}}>{intl.formatMessage(messages.invalidCredentials)}</span>
30
+ </FormItem>
31
+ : null
15
32
  }
16
- });
17
- }
18
-
19
- render() {
20
- const { getFieldDecorator } = this.props.form;
21
- return (
22
- <Form onSubmit={this.handleSubmit} className="login-form">
23
- <FormItem className="login-form-item">
24
- {getFieldDecorator('username', {
25
- rules: [{ required: true, message: this.props.intl.formatMessage(messages.inputUsernameMandatory) }],
26
- })(
27
- <CapInput prefix={<Icon type="user" style={{ fontSize: 13 }} />} placeholder={this.props.intl.formatMessage(messages.username)} />
28
- )}
29
- </FormItem>
30
- <FormItem className="login-form-item">
31
- {getFieldDecorator('password', {
32
- rules: [{ required: true, message: this.props.intl.formatMessage(messages.inputPasswordMandatory) }],
33
- })(
34
- <CapInput prefix={<Icon type="lock" style={{ fontSize: 13 }} />} type="password" placeholder={this.props.intl.formatMessage(messages.password)} />
35
- )}
36
- </FormItem>
37
- {this.props.isError
38
- ? <FormItem>
39
- <span style={{color: "red"}}>{this.props.intl.formatMessage(messages.invalidCredentials)}</span>
40
- </FormItem>
41
- : null
42
- }
43
- <FormItem>
44
- <CapButton loading={this.props.loginInProgress} type="primary" htmlType="submit" className="login-form-button">
45
- Log in
46
- </CapButton>
47
- </FormItem>
48
- </Form>
49
- );
50
- }
51
- }
33
+ <FormItem>
34
+ <CapButton loading={loginInProgress} type="primary" htmlType="submit" className="login-form-button">
35
+ Log in
36
+ </CapButton>
37
+ </FormItem>
38
+ </Form>
39
+ );
40
+ };
52
41
 
53
42
  NormalLoginForm.propTypes = {
54
43
  authenticate: PropTypes.func.isRequired,
55
44
  loginInProgress: PropTypes.bool,
56
45
  isError: PropTypes.bool,
57
- form: PropTypes.object,
58
46
  intl: intlShape.isRequired,
59
47
  };
60
48
 
61
- const WrappedNormalLoginForm = Form.create()(NormalLoginForm);
62
- export default injectIntl(WrappedNormalLoginForm);
49
+ export default injectIntl(NormalLoginForm);
@@ -4,7 +4,7 @@ import { connect } from 'react-redux';
4
4
  import Helmet from 'react-helmet';
5
5
  import { FormattedMessage } from 'react-intl';
6
6
  import { routerActions } from 'connected-react-router';
7
- import { Row, Col } from 'antd';
7
+ import { CapRow, CapColumn } from '@capillarytech/cap-ui-library';
8
8
  import { bindActionCreators } from 'redux';
9
9
  import { createStructuredSelector } from 'reselect';
10
10
  import makeSelectLogin from './selectors';
@@ -60,7 +60,7 @@ export class Login extends React.Component { // eslint-disable-line react/prefer
60
60
  ]}
61
61
  />}
62
62
  </FormattedMessage>
63
- <Row align="middle" justify="center" type="flex" className="login-container">
63
+ <CapRow align="middle" justify="center" type="flex" className="login-container">
64
64
  {process.env.NODE_ENV === "production"
65
65
  ? <div className="cap-loader-box">
66
66
  <img
@@ -68,14 +68,14 @@ export class Login extends React.Component { // eslint-disable-line react/prefer
68
68
  src={"https://storage.crm.n.content-cdn.io/capillary/capillary_loading_logo.gif"}
69
69
  alt="Capillary"/>
70
70
  </div>
71
- : <Col className="login-box" style={{textAlign: 'center'}}>
71
+ : <CapColumn className="login-box" style={{textAlign: 'center'}}>
72
72
  <h2 className="ui image header">
73
73
  <img alt="" src={logo} className="login-logo" />
74
74
  </h2>
75
75
  <LoginForm isError={this.state.isLoginError} authenticate={this.props.actions.authenticate} loginInProgress={loginProgress} />
76
- </Col>
76
+ </CapColumn>
77
77
  }
78
- </Row>
78
+ </CapRow>
79
79
  </div>
80
80
  );
81
81
  }
@@ -1966,6 +1966,7 @@ export class Create extends React.Component { // eslint-disable-line react/prefe
1966
1966
  hideTestAndPreviewBtn={this.props.hideTestAndPreviewBtn}
1967
1967
  isFullMode={this.props.isFullMode}
1968
1968
  eventContextTags={this.props?.eventContextTags}
1969
+ waitEventContextTags={this.props?.waitEventContextTags}
1969
1970
  messageDetails={this.props?.messageDetails}
1970
1971
  restrictPersonalization={this.props.restrictPersonalization}
1971
1972
  />
@@ -2068,6 +2069,7 @@ Create.propTypes = {
2068
2069
  onPreviewContentClicked: PropTypes.func,
2069
2070
  onTestContentClicked: PropTypes.func,
2070
2071
  eventContextTags: PropTypes.array,
2072
+ waitEventContextTags: PropTypes.object,
2071
2073
  getLiquidTags: PropTypes.func,
2072
2074
  showLiquidErrorInFooter: PropTypes.func,
2073
2075
  showTestAndPreviewSlidebox: PropTypes.bool,
@@ -2233,6 +2233,7 @@ export class Edit extends React.Component { // eslint-disable-line react/prefer-
2233
2233
  hideTestAndPreviewBtn={this.props.hideTestAndPreviewBtn}
2234
2234
  isFullMode={this.props.isFullMode}
2235
2235
  eventContextTags={this.props?.eventContextTags}
2236
+ waitEventContextTags={this.props?.waitEventContextTags}
2236
2237
  restrictPersonalization={this.props.restrictPersonalization}
2237
2238
  />;
2238
2239
  })()}
@@ -2339,6 +2340,7 @@ Edit.propTypes = {
2339
2340
  onTestContentClicked: PropTypes.func,
2340
2341
  creativesMode: PropTypes.string,
2341
2342
  eventContextTags: PropTypes.array,
2343
+ waitEventContextTags: PropTypes.object,
2342
2344
  getLiquidTags: PropTypes.func,
2343
2345
  showLiquidErrorInFooter: PropTypes.func,
2344
2346
  showTestAndPreviewSlidebox: PropTypes.bool,
@@ -117,7 +117,7 @@ const CtaButtons = ({
117
117
  </CapHeading>
118
118
  {!isPrimaryButtonSaved && !shouldShowPrimaryCTA && (
119
119
  <CapButton
120
- type="flat"
120
+ type="link"
121
121
  id="add-primary-button"
122
122
  onClick={handleAddPrimary}
123
123
  >
@@ -149,7 +149,7 @@ const CtaButtons = ({
149
149
  >
150
150
  <div style={{ display: 'inline-block' }}>
151
151
  <CapButton
152
- type="flat"
152
+ type="link"
153
153
  id="add-secondary-button"
154
154
  onClick={handleAddSecondary}
155
155
  disabled
@@ -591,8 +591,8 @@ const MediaUploaders = ({
591
591
  return (
592
592
  <>
593
593
  <CapDivider />
594
- <CapRow className="creatives-mpush-actions">
595
- <CapRow className="mpush-actions-main">
594
+ <CapRow useLegacy className="creatives-mpush-actions">
595
+ <CapRow useLegacy className="mpush-actions-main">
596
596
  <CapHeading type="h4" className="mpush-actions">
597
597
  <FormattedMessage {...messages.buttonsAndLinks} />
598
598
  </CapHeading>
@@ -607,7 +607,7 @@ const MediaUploaders = ({
607
607
  >
608
608
  <FormattedMessage {...messages.actionOnClickBody} />
609
609
  </CapCheckbox>
610
- <CapRow>
610
+ <CapRow useLegacy>
611
611
  <CapLabel className="action-description">
612
612
  <FormattedMessage {...messages.actionDescription} />
613
613
  </CapLabel>
@@ -772,7 +772,7 @@ const MediaUploaders = ({
772
772
  title={`${formatMessage(messages.card)} ${index + 1}`}
773
773
  extra={(
774
774
  <CapButton
775
- type="flat"
775
+ type="link"
776
776
  onClick={() => deleteCarouselCard(index)}
777
777
  disabled={currentData?.length === 1}
778
778
  >
@@ -781,16 +781,16 @@ const MediaUploaders = ({
781
781
  )}
782
782
  className="mobile-push-carousel-card"
783
783
  >
784
- <CapRow>
784
+ <CapRow useLegacy>
785
785
  {carouselMediaType === IMAGE.toLowerCase() ? (
786
- <CapRow>
786
+ <CapRow useLegacy>
787
787
  <CapHeading type="h4">
788
788
  {formatMessage(messages.mediaImage)}
789
789
  </CapHeading>
790
790
  {renderCarouselImageComponent(index)}
791
791
  </CapRow>
792
792
  ) : (
793
- <CapRow>
793
+ <CapRow useLegacy>
794
794
  <CapHeading type="h4">
795
795
  {formatMessage(messages.mediaVideo)}
796
796
  </CapHeading>
@@ -809,7 +809,7 @@ const MediaUploaders = ({
809
809
  <CapDivider type="vertical" />
810
810
  <CapButton
811
811
  onClick={addCarouselCard}
812
- type="flat"
812
+ type="link"
813
813
  className="add-carousel-content-button"
814
814
  disabled={getCurrentCarouselData()?.length >= MAX_CAROUSEL_ALLOWED}
815
815
  >
@@ -849,7 +849,7 @@ const MediaUploaders = ({
849
849
  </div>
850
850
  </CapColumn>
851
851
  </CapRow>
852
- <CapRow className="mobile-push-carousel-tab">
852
+ <CapRow useLegacy className="mobile-push-carousel-tab">
853
853
  <CapTab
854
854
  defaultActiveKey="0"
855
855
  activeKey={carouselActiveTabIndex.toString()}
@@ -227,7 +227,7 @@ const PlatformContentFields = ({
227
227
  />
228
228
  </CapRow>
229
229
  <CapDivider />
230
- <CapRow className="creatives-mpush-media">
230
+ <CapRow useLegacy className="creatives-mpush-media">
231
231
  <CapHeading type="h3" className="mpush-media-type">
232
232
  <FormattedMessage {...messages.mediaType} />
233
233
  </CapHeading>
@@ -252,8 +252,8 @@ const PlatformContentFields = ({
252
252
  {content?.mediaType !== CAROUSEL && (
253
253
  <>
254
254
  <CapDivider />
255
- <CapRow className="creatives-mpush-actions">
256
- <CapRow className="mpush-actions-main">
255
+ <CapRow useLegacy className="creatives-mpush-actions">
256
+ <CapRow useLegacy className="mpush-actions-main">
257
257
  <CapHeading type="h3" className="mpush-actions">
258
258
  <FormattedMessage {...messages.buttonsAndLinks} />
259
259
  </CapHeading>
@@ -268,7 +268,7 @@ const PlatformContentFields = ({
268
268
  >
269
269
  <FormattedMessage {...messages.actionOnClickBody} />
270
270
  </CapCheckbox>
271
- <CapRow>
271
+ <CapRow useLegacy>
272
272
  <CapLabel className="action-description">
273
273
  <FormattedMessage {...messages.actionDescription} />
274
274
  </CapLabel>
@@ -2152,7 +2152,7 @@ const MobilePushNew = ({
2152
2152
  panes.push({
2153
2153
  key: ANDROID,
2154
2154
  tab: (
2155
- <CapRow>
2155
+ <CapRow useLegacy>
2156
2156
  <CapIcon type="android" />
2157
2157
  {formatMessage(messages.android)}
2158
2158
  </CapRow>
@@ -2164,7 +2164,7 @@ const MobilePushNew = ({
2164
2164
  panes.push({
2165
2165
  key: IOS,
2166
2166
  tab: (
2167
- <CapRow>
2167
+ <CapRow useLegacy>
2168
2168
  <CapIcon type="ios" />
2169
2169
  {formatMessage(messages.ios)}
2170
2170
  </CapRow>
@@ -67,14 +67,16 @@
67
67
 
68
68
  .input-group {
69
69
  display: flex;
70
- flex-direction: column;
70
+ flex-direction: column !important;
71
+ flex-flow: column nowrap;
71
72
  gap: $CAP_SPACE_16;
72
73
  }
73
74
 
74
75
  .creatives-mpush-title,
75
76
  .creatives-mpush-message {
76
77
  display: flex;
77
- flex-direction: column;
78
+ flex-direction: column !important;
79
+ flex-flow: column nowrap;
78
80
  gap: $CAP_SPACE_08;
79
81
  }
80
82
 
@@ -122,8 +124,9 @@
122
124
  background: #fafafa;
123
125
  }
124
126
 
127
+ /* TODO: cap-react-ui-library class removed — review this override */
125
128
  .button-form .cap-input,
126
- .button-form .cap-select {
129
+ .button-form .cap-select-v2 {
127
130
  margin-bottom: $CAP_SPACE_16;
128
131
  }
129
132
 
@@ -72,7 +72,7 @@ export class MobilepushWrapper extends React.Component { // eslint-disable-line
72
72
  }
73
73
 
74
74
  render() {
75
- const {mobilePushCreateMode, step, getFormData, getLiquidTags, setIsLoadingContent, isGetFormData, query, isFullMode, showTemplateName, type, onValidationFail, onPreviewContentClicked, onTestContentClicked, templateData, eventContextTags = [], showTestAndPreviewSlidebox, handleTestAndPreview, handleCloseTestAndPreview, restrictPersonalization, isAnonymousType, onPersonalizationTokensChange} = this.props;
75
+ const {mobilePushCreateMode, step, getFormData, getLiquidTags, setIsLoadingContent, isGetFormData, query, isFullMode, showTemplateName, type, onValidationFail, onPreviewContentClicked, onTestContentClicked, templateData, eventContextTags = [], waitEventContextTags = {},showTestAndPreviewSlidebox, handleTestAndPreview, handleCloseTestAndPreview, restrictPersonalization, isAnonymousType, onPersonalizationTokensChange} = this.props;
76
76
  const {templateName} = this.state;
77
77
  const isShowMobilepushCreate = !isEmpty(mobilePushCreateMode);
78
78
  return (
@@ -121,6 +121,7 @@ export class MobilepushWrapper extends React.Component { // eslint-disable-line
121
121
  templateData={templateData}
122
122
  hideTestAndPreviewBtn={this.props.hideTestAndPreviewBtn}
123
123
  eventContextTags={eventContextTags}
124
+ waitEventContextTags={waitEventContextTags}
124
125
  showLiquidErrorInFooter={this.props.showLiquidErrorInFooter}
125
126
  showTestAndPreviewSlidebox={showTestAndPreviewSlidebox}
126
127
  handleTestAndPreview={handleTestAndPreview}
@@ -155,6 +156,7 @@ MobilepushWrapper.propTypes = {
155
156
  type: PropTypes.string,
156
157
  onValidationFail: PropTypes.func,
157
158
  eventContextTags: PropTypes.array,
159
+ waitEventContextTags: PropTypes.object,
158
160
  showLiquidErrorInFooter: PropTypes.func,
159
161
  showTestAndPreviewSlidebox: PropTypes.bool,
160
162
  handleTestAndPreview: PropTypes.func,
@@ -16,6 +16,7 @@ import CapInput from '@capillarytech/cap-ui-library/CapInput';
16
16
  import CapAlert from '@capillarytech/cap-ui-library/CapAlert';
17
17
  import CapHeading from '@capillarytech/cap-ui-library/CapHeading';
18
18
  import CapRadioGroup from '@capillarytech/cap-ui-library/CapRadioGroup';
19
+ import ConfigProvider from 'antd/lib/config-provider';
19
20
  import CapTooltip from '@capillarytech/cap-ui-library/CapTooltip';
20
21
  import CapLabel from '@capillarytech/cap-ui-library/CapLabel';
21
22
  import CapHeader from '@capillarytech/cap-ui-library/CapHeader';
@@ -148,6 +149,7 @@ export const Rcs = (props) => {
148
149
  smsRegister,
149
150
  selectedOfferDetails,
150
151
  eventContextTags,
152
+ waitEventContextTags,
151
153
  accountData = {},
152
154
  // TestAndPreviewSlidebox props
153
155
  showTestAndPreviewSlidebox: propsShowTestAndPreviewSlidebox,
@@ -1143,7 +1145,7 @@ const splitTemplateVarString = (str) => {
1143
1145
  ) : (
1144
1146
  <CapButton
1145
1147
  data-testid="suffix-button"
1146
- type="flat"
1148
+ type="link"
1147
1149
  isAddBtn
1148
1150
  onClick={onTitleAddVar}
1149
1151
  disabled={!!templateTitleError}
@@ -1182,7 +1184,7 @@ const splitTemplateVarString = (str) => {
1182
1184
  )}
1183
1185
 
1184
1186
  {/* Template Message */}
1185
- <CapRow id="rcs-template-message-label">
1187
+ <CapRow useLegacy id="rcs-template-message-label">
1186
1188
  <CapHeader
1187
1189
  title={(
1188
1190
  <CapRow type="flex">
@@ -1205,7 +1207,7 @@ const splitTemplateVarString = (str) => {
1205
1207
  ) : (
1206
1208
  <CapButton
1207
1209
  data-testid="suffix-button"
1208
- type="flat"
1210
+ type="link"
1209
1211
  isAddBtn
1210
1212
  onClick={onMessageAddVar}
1211
1213
  disabled={templateDescError && templateDesc}
@@ -1216,7 +1218,7 @@ const splitTemplateVarString = (str) => {
1216
1218
  }
1217
1219
  />
1218
1220
  </CapRow>
1219
- <CapRow className="rcs-create-template-message-input">
1221
+ <CapRow useLegacy className="rcs-create-template-message-input">
1220
1222
  <div className="rcs_text_area_wrapper">
1221
1223
  {(isEditFlow || !isFullMode)
1222
1224
  ? renderedRCSEditMessage(splitTemplateVarString(templateDesc), MESSAGE_TEXT)
@@ -2275,7 +2277,7 @@ const splitTemplateVarString = (str) => {
2275
2277
 
2276
2278
  return (
2277
2279
  <>
2278
- {templateStatus !== '' && (<CapRow className="template-status-container">
2280
+ {templateStatus !== '' && (<CapRow useLegacy className="template-status-container">
2279
2281
  <CapLabel type="label2">
2280
2282
  {formatMessage(messages.templateStatusLabel)}
2281
2283
  </CapLabel>
@@ -2307,25 +2309,29 @@ const splitTemplateVarString = (str) => {
2307
2309
  />
2308
2310
  )}
2309
2311
  {renderLabel('templateTypeLabel')}
2310
- <CapRadioGroup
2311
- id="select-rcs-template-type"
2312
- options={TEMPLATE_TYPE_OPTIONS}
2313
- onChange={onTemplateTypeChange}
2314
- value={templateType}
2315
- disabled={(isEditFlow || !isFullMode)}
2316
- />
2312
+ <ConfigProvider theme={{ components: { Radio: { radioSize: 20, dotSize: 8 } } }}>
2313
+ <CapRadioGroup
2314
+ id="select-rcs-template-type"
2315
+ options={TEMPLATE_TYPE_OPTIONS}
2316
+ onChange={onTemplateTypeChange}
2317
+ value={templateType}
2318
+ disabled={(isEditFlow || !isFullMode)}
2319
+ />
2320
+ </ConfigProvider>
2317
2321
 
2318
2322
  {/* Show media only for rich_card or carousel */}
2319
2323
  {(templateType === contentType.rich_card || templateType === contentType.carousel) && (
2320
2324
  <>
2321
2325
  {renderLabel('mediaLabel')}
2322
- <CapRadioGroup
2323
- options={mediaRadioOptions || []}
2324
- value={templateMediaType}
2325
- onChange={onTemplateMediaTypeChange}
2326
- disabled={(isEditFlow || !isFullMode)}
2327
- className="rcs-radio"
2328
- />
2326
+ <ConfigProvider theme={{ components: { Radio: { radioSize: 20, dotSize: 8 } } }}>
2327
+ <CapRadioGroup
2328
+ options={mediaRadioOptions || []}
2329
+ value={templateMediaType}
2330
+ onChange={onTemplateMediaTypeChange}
2331
+ disabled={(isEditFlow || !isFullMode)}
2332
+ className="rcs-radio"
2333
+ />
2334
+ </ConfigProvider>
2329
2335
  <div className="rcs-container-image">
2330
2336
  {getMediaBasedComponent()}
2331
2337
  </div>
@@ -44,13 +44,6 @@
44
44
  margin-right: 50px;
45
45
  }
46
46
 
47
- .ant-radio-inner::after{
48
- top: 3px;
49
- left: 3px;
50
- }
51
- .ant-radio-inner{
52
- border: 1px solid #d9d9d9;
53
- }
54
47
  .ant-radio-checked .ant-radio-inner{
55
48
  border: 1px solid #47af46;
56
49
  }