@fonixtree/magic-design 2.0.83 → 2.0.85

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 (47) hide show
  1. package/es/common/GroupList/index.js +2 -0
  2. package/es/composite-comp/dito/components/CommonFunctions/defaultJSON.js +8 -4
  3. package/es/composite-comp/dito/components/CommonFunctions/mobile/index.js +6 -4
  4. package/es/composite-comp/dito/components/CommonFunctions/mobile/index.less +2 -5
  5. package/es/composite-comp/dito/components/Orders/defaultJSON.js +4 -4
  6. package/es/composite-comp/dito/components/Orders/mobile/index.js +19 -8
  7. package/es/composite-comp/dito/components/Orders/mobile/index.less +13 -9
  8. package/es/composite-comp/dito/components/PersonalInformation/defaultJSON.js +6 -6
  9. package/es/composite-comp/dito/components/PersonalInformation/index.js +1 -1
  10. package/es/composite-comp/dito/components/PersonalInformation/mobile/index.js +38 -9
  11. package/es/composite-comp/dito/components/PersonalInformation/mobile/index.less +20 -18
  12. package/es/composite-comp/dito/config-panels/OrdersConfig/ConfigGroup/index.js +4 -1
  13. package/es/composite-comp/dito/config-panels/OrdersConfig/index.js +1 -0
  14. package/es/composite-comp/dito/config-panels/PersonalInformationConfig/ConfigGroup/index.js +4 -1
  15. package/es/composite-comp/dito/config-panels/PersonalInformationConfig/index.js +1 -0
  16. package/es/composite-comp/dito/second-config-panels/OrdersSecondConfig/index.js +4 -4
  17. package/es/composite-comp/dito/second-config-panels/PersonalInformationSecondConfig/index.js +2 -2
  18. package/es/constants/index.js +5 -5
  19. package/es/core/Designer/ConfigPanel/index.js +1 -1
  20. package/es/locale/en/en.json +5 -5
  21. package/es/locale/es/es.json +5 -5
  22. package/es/locale/id/id.json +5 -5
  23. package/es/utils/commonUtil.js +1 -1
  24. package/lib/common/GroupList/index.js +2 -0
  25. package/lib/composite-comp/dito/components/CommonFunctions/defaultJSON.js +8 -4
  26. package/lib/composite-comp/dito/components/CommonFunctions/mobile/index.js +6 -4
  27. package/lib/composite-comp/dito/components/CommonFunctions/mobile/index.less +2 -5
  28. package/lib/composite-comp/dito/components/Orders/defaultJSON.js +4 -4
  29. package/lib/composite-comp/dito/components/Orders/mobile/index.js +19 -8
  30. package/lib/composite-comp/dito/components/Orders/mobile/index.less +13 -9
  31. package/lib/composite-comp/dito/components/PersonalInformation/defaultJSON.js +6 -6
  32. package/lib/composite-comp/dito/components/PersonalInformation/index.js +1 -1
  33. package/lib/composite-comp/dito/components/PersonalInformation/mobile/index.js +38 -9
  34. package/lib/composite-comp/dito/components/PersonalInformation/mobile/index.less +20 -18
  35. package/lib/composite-comp/dito/config-panels/OrdersConfig/ConfigGroup/index.js +4 -1
  36. package/lib/composite-comp/dito/config-panels/OrdersConfig/index.js +1 -0
  37. package/lib/composite-comp/dito/config-panels/PersonalInformationConfig/ConfigGroup/index.js +4 -1
  38. package/lib/composite-comp/dito/config-panels/PersonalInformationConfig/index.js +1 -0
  39. package/lib/composite-comp/dito/second-config-panels/OrdersSecondConfig/index.js +4 -4
  40. package/lib/composite-comp/dito/second-config-panels/PersonalInformationSecondConfig/index.js +2 -2
  41. package/lib/constants/index.js +5 -5
  42. package/lib/core/Designer/ConfigPanel/index.js +1 -1
  43. package/lib/locale/en/en.json +5 -5
  44. package/lib/locale/es/es.json +5 -5
  45. package/lib/locale/id/id.json +5 -5
  46. package/lib/utils/commonUtil.js +1 -1
  47. package/package.json +1 -1
@@ -97,7 +97,9 @@ function (_super) {
97
97
  }
98
98
 
99
99
  ImageTextConfigGroup.prototype.render = function () {
100
- var source = this.props.source;
100
+ var _a = this.props,
101
+ source = _a.source,
102
+ maxNum = _a.maxNum;
101
103
  return /*#__PURE__*/_react["default"].createElement("div", {
102
104
  className: "banner_group"
103
105
  }, /*#__PURE__*/_react["default"].createElement("div", {
@@ -111,6 +113,7 @@ function (_super) {
111
113
  })), /*#__PURE__*/_react["default"].createElement("div", {
112
114
  className: "btn_wrap"
113
115
  }, /*#__PURE__*/_react["default"].createElement(_Button["default"], {
116
+ disabled: source.length >= maxNum,
114
117
  icon: "icon-add",
115
118
  onClick: this.onAddClick,
116
119
  type: "primary"
@@ -84,6 +84,7 @@ function (_super) {
84
84
  key: 'Orders1',
85
85
  name: (0, _locale.i18n)('Content'),
86
86
  value: /*#__PURE__*/_react["default"].createElement(_ConfigGroup["default"], {
87
+ maxNum: 5,
87
88
  source: data.groupSource
88
89
  }),
89
90
  metaOption: data.groupSource
@@ -97,7 +97,9 @@ function (_super) {
97
97
  }
98
98
 
99
99
  ConfigGroup.prototype.render = function () {
100
- var source = this.props.source;
100
+ var _a = this.props,
101
+ source = _a.source,
102
+ maxNum = _a.maxNum;
101
103
  return /*#__PURE__*/_react["default"].createElement("div", {
102
104
  className: "banner_group"
103
105
  }, /*#__PURE__*/_react["default"].createElement("div", {
@@ -111,6 +113,7 @@ function (_super) {
111
113
  })), /*#__PURE__*/_react["default"].createElement("div", {
112
114
  className: "btn_wrap"
113
115
  }, /*#__PURE__*/_react["default"].createElement(_Button["default"], {
116
+ disabled: source.length >= maxNum,
114
117
  icon: "icon-add",
115
118
  onClick: this.onAddClick,
116
119
  type: "primary"
@@ -88,6 +88,7 @@ function (_super) {
88
88
  key: 'PersonalInformation2',
89
89
  name: (0, _locale.i18n)('Content'),
90
90
  value: /*#__PURE__*/_react["default"].createElement(_ConfigGroup["default"], {
91
+ maxNum: 4,
91
92
  source: data.groupSource
92
93
  }),
93
94
  metaOption: data.groupSource
@@ -114,10 +114,10 @@ function (_super) {
114
114
  }, (0, _locale.i18n)('TO_SHIP')), /*#__PURE__*/_react["default"].createElement(_antd.Select.Option, {
115
115
  value: _index.orderStatusType.RECEIVE
116
116
  }, (0, _locale.i18n)('TO_RECEIVE')), /*#__PURE__*/_react["default"].createElement(_antd.Select.Option, {
117
- value: _index.orderStatusType.RATING
118
- }, (0, _locale.i18n)('RATING')), /*#__PURE__*/_react["default"].createElement(_antd.Select.Option, {
119
- value: _index.orderStatusType.RETURN
120
- }, (0, _locale.i18n)('RETURN'))))));
117
+ value: _index.orderStatusType.DONE
118
+ }, (0, _locale.i18n)('DONE')), /*#__PURE__*/_react["default"].createElement(_antd.Select.Option, {
119
+ value: _index.orderStatusType.CANCELLED
120
+ }, (0, _locale.i18n)('CANCELLED'))))));
121
121
  };
122
122
 
123
123
  return _this;
@@ -109,8 +109,8 @@ function (_super) {
109
109
  }, (0, _locale.i18n)('WISHLIST')), /*#__PURE__*/_react["default"].createElement(_antd.Select.Option, {
110
110
  value: _index.personalInfoType.STORES
111
111
  }, (0, _locale.i18n)('STORES')), /*#__PURE__*/_react["default"].createElement(_antd.Select.Option, {
112
- value: _index.personalInfoType.COUPONS
113
- }, (0, _locale.i18n)('COUPONS')), /*#__PURE__*/_react["default"].createElement(_antd.Select.Option, {
112
+ value: _index.personalInfoType.VOUCHERS
113
+ }, (0, _locale.i18n)('VOUCHERS')), /*#__PURE__*/_react["default"].createElement(_antd.Select.Option, {
114
114
  value: _index.personalInfoType.VIEWED
115
115
  }, (0, _locale.i18n)('RECENTLY_VIEWED'))))));
116
116
  };
@@ -46,17 +46,17 @@ var walletType = {
46
46
  };
47
47
  exports.walletType = walletType;
48
48
  var orderStatusType = {
49
- PAY: 'To pay',
49
+ PAY: 'To Pay',
50
50
  SHIP: 'To Ship',
51
51
  RECEIVE: 'To Receive',
52
- RATING: 'Rating',
53
- RETURN: 'Return'
52
+ DONE: 'Done',
53
+ CANCELLED: 'Cancelled'
54
54
  };
55
55
  exports.orderStatusType = orderStatusType;
56
56
  var personalInfoType = {
57
57
  WISHLIST: 'Wishlist',
58
58
  STORES: 'Stores',
59
- COUPONS: 'Coupons',
59
+ VOUCHERS: 'Vouchers',
60
60
  VIEWED: 'Recently Viewed'
61
61
  };
62
62
  exports.personalInfoType = personalInfoType;
@@ -212,7 +212,7 @@ var compInfoMap = {
212
212
  name: 'Menu Navigation',
213
213
  icon: 'icon-footer'
214
214
  },
215
- PERSONAL_INFORMATION: {
215
+ PERSONAL_INFOMATION: {
216
216
  name: 'Personal Information',
217
217
  icon: 'icon-account'
218
218
  },
@@ -131,7 +131,7 @@ var getSecondConfigName = function getSecondConfigName(selectedNode, clickedGrou
131
131
  groupName = panelProps.button.text;
132
132
  break;
133
133
 
134
- case 'PERSONAL_INFORMATION':
134
+ case 'PERSONAL_INFOMATION':
135
135
  case 'ORDERS':
136
136
  groupName = panelProps.sourceType;
137
137
  break;
@@ -1,13 +1,13 @@
1
1
  {
2
- "RETURN": "Return",
3
- "RATING": "Rating",
2
+ "CANCELLED": "Cancelled",
3
+ "DONE": "Done",
4
4
  "TO_RECEIVE": "To Receive",
5
5
  "TO_SHIP": "To ship",
6
- "TO_PAY": "To pay",
6
+ "TO_PAY": "To Pay",
7
7
  "VIEW_ALL_ORDERS": "View All Orders",
8
- "ORDERS": "ORDERS",
8
+ "ORDERS": "Orders",
9
9
  "RECENTLY_VIEWED": "Recently Viewed",
10
- "COUPONS": "Coupons",
10
+ "VOUCHERS": "Vouchers",
11
11
  "STORES": "Stores",
12
12
  "WISHLIST": "Wishlist",
13
13
  "IMAGE_NAME_IS_TOO_LONG": "Image name is too long",
@@ -1,13 +1,13 @@
1
1
  {
2
- "RETURN": "Return",
3
- "RATING": "Rating",
2
+ "CANCELLED": "Cancelled",
3
+ "DONE": "Done",
4
4
  "TO_RECEIVE": "To Receive",
5
5
  "TO_SHIP": "To ship",
6
- "TO_PAY": "To pay",
6
+ "TO_PAY": "To Pay",
7
7
  "VIEW_ALL_ORDERS": "View All Orders",
8
- "ORDERS": "ORDERS",
8
+ "ORDERS": "Orders",
9
9
  "RECENTLY_VIEWED": "Recently Viewed",
10
- "COUPONS": "Coupons",
10
+ "VOUCHERS": "Vouchers",
11
11
  "STORES": "Stores",
12
12
  "WISHLIST": "Wishlist",
13
13
  "IMAGE_NAME_IS_TOO_LONG": "Image name is too long",
@@ -1,13 +1,13 @@
1
1
  {
2
- "RETURN": "Return",
3
- "RATING": "Rating",
2
+ "CANCELLED": "Cancelled",
3
+ "DONE": "Done",
4
4
  "TO_RECEIVE": "To Receive",
5
5
  "TO_SHIP": "To ship",
6
- "TO_PAY": "To pay",
6
+ "TO_PAY": "To Pay",
7
7
  "VIEW_ALL_ORDERS": "View All Orders",
8
- "ORDERS": "ORDERS",
8
+ "ORDERS": "Orders",
9
9
  "RECENTLY_VIEWED": "Recently Viewed",
10
- "COUPONS": "Coupons",
10
+ "VOUCHERS": "Vouchers",
11
11
  "STORES": "Stores",
12
12
  "WISHLIST": "Wishlist",
13
13
  "IMAGE_NAME_IS_TOO_LONG": "Image name is too long",
@@ -752,7 +752,7 @@ function pushGA(data, eventName) {
752
752
  elementName: data.elementName
753
753
  };
754
754
  console.log('GA push', eventName, eventData);
755
- window.gtag('event', eventName, eventData);
755
+ if (window.gtag) window.gtag('event', eventName, eventData);
756
756
  }
757
757
  } catch (error) {
758
758
  console.error(error);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@fonixtree/magic-design",
3
3
  "author": "Cylon Team",
4
- "version": "2.0.83",
4
+ "version": "2.0.85",
5
5
  "description": "Magic Design",
6
6
  "license": "MIT",
7
7
  "module": "es/index.js",