@capillarytech/creatives-library 3.0.28 → 3.0.30

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/components/FormBuilder/index.js +2 -2
  2. package/components/TemplatePreview/index.js +5 -0
  3. package/components/TemplatePreview/messages.js +12 -0
  4. package/config/app.js +2 -0
  5. package/containers/Cap/index.js +1 -0
  6. package/containers/Line/Create/index.js +2 -2
  7. package/containers/Line/Edit/index.js +2 -2
  8. package/containers/MobilePush/Create/index.js +2 -2
  9. package/containers/MobilePush/Edit/index.js +2 -2
  10. package/containers/Sms/Create/index.js +2 -3
  11. package/containers/Templates/index.js +9 -7
  12. package/hoc/withCreatives.js +46 -0
  13. package/hoc/withStyles.js +12 -0
  14. package/index.js +2 -1
  15. package/package.json +1 -4
  16. package/routes.js +2 -1
  17. package/services/api.js +14 -0
  18. package/utils/smsCharCountV2.js +28 -6
  19. package/v2Components/EmailMobilePreview/index.js +3 -2
  20. package/v2Components/TemplatePreview/_templatePreview.scss +8 -0
  21. package/v2Components/TemplatePreview/index.js +29 -11
  22. package/v2Components/TemplatePreview/messages.js +4 -0
  23. package/v2Containers/CreativesContainer/SlideBoxContent.js +36 -20
  24. package/v2Containers/CreativesContainer/index.js +9 -6
  25. package/v2Containers/Ebill/index.js +9 -6
  26. package/v2Containers/Email/index.js +10 -7
  27. package/v2Containers/LanguageProvider/index.js +2 -0
  28. package/v2Containers/LanguageProvider/reducer.js +1 -1
  29. package/v2Containers/Line/Create/index.js +8 -6
  30. package/v2Containers/Line/Edit/index.js +8 -5
  31. package/v2Containers/MobilePush/Create/index.js +8 -5
  32. package/v2Containers/MobilePush/Edit/index.js +8 -5
  33. package/v2Containers/Sms/Create/index.js +10 -7
  34. package/v2Containers/Sms/Edit/index.js +10 -7
  35. package/v2Containers/TemplatesV2/TemplatesV2.style.js +29 -0
  36. package/v2Containers/TemplatesV2/index.js +29 -51
  37. package/v2Containers/WeChat/MapTemplates/index.js +8 -10
  38. package/v2Containers/TemplatesV2/_templatesV2.scss +0 -5
@@ -7,10 +7,9 @@
7
7
  import PropTypes from 'prop-types';
8
8
 
9
9
  import React from 'react';
10
- import { connect } from 'react-redux';
11
10
  import { bindActionCreators } from 'redux';
12
11
  import Helmet from 'react-helmet';
13
- import { injectIntl, intlShape } from 'react-intl';
12
+ import { intlShape } from 'react-intl';
14
13
  import { createStructuredSelector } from 'reselect';
15
14
  import { Row, Col, Spin } from 'antd';
16
15
  import _ from 'lodash';
@@ -20,15 +19,10 @@ import makeSelectWeChat from './selectors';
20
19
  import messages from './messages';
21
20
  import * as actions from './actions';
22
21
  import FormBuilder from '../../../v2Components/FormBuilder';
23
- import { UserIsAuthenticated } from '../../../utils/authWrapper';
24
- import * as globalActions from '../../Cap/actions';
25
22
  import {getMessageObject} from '../../../utils/messageUtils';
26
23
  import * as templateActions from '../../Templates/actions';
27
- // import SlideBox from '../../v2Components/SlideBox';
28
- // import PageHeader from '../../v2Components/PageHeader';
29
24
  import './_mapTemplates.scss';
30
-
31
- // const Option = Select.Option;
25
+ import withCreatives from '../../../hoc/withCreatives';
32
26
 
33
27
  export class MapTemplates extends React.Component { // eslint-disable-line react/prefer-stateless-function
34
28
  constructor(props) {
@@ -1376,9 +1370,13 @@ const mapStateToProps = createStructuredSelector({
1376
1370
  function mapDispatchToProps(dispatch) {
1377
1371
  return {
1378
1372
  actions: bindActionCreators(actions, dispatch),
1379
- globalActions: bindActionCreators(globalActions, dispatch),
1380
1373
  templateActions: bindActionCreators(templateActions, dispatch),
1381
1374
  };
1382
1375
  }
1383
1376
 
1384
- export default UserIsAuthenticated(connect(mapStateToProps, mapDispatchToProps)(injectIntl(MapTemplates)));
1377
+ export default withCreatives({
1378
+ WrappedComponent: MapTemplates,
1379
+ mapStateToProps,
1380
+ mapDispatchToProps,
1381
+ userAuth: true,
1382
+ });
@@ -1,5 +0,0 @@
1
- .cap-tab-v2-wrapper{
2
- .ant-tabs-tabpane {
3
- border: none;
4
- }
5
- }