@fonixtree/magic-design 1.0.217 → 1.0.219

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 (83) hide show
  1. package/es/assets/images/layout-icon/banner-layout1.png +0 -0
  2. package/es/assets/images/layout-icon/banner-layout2.svg +6 -0
  3. package/es/assets/images/layout-icon/center.png +0 -0
  4. package/es/assets/images/layout-icon/grouped-image-layout1.png +0 -0
  5. package/es/assets/images/layout-icon/left.png +0 -0
  6. package/es/assets/images/layout-icon/right.png +0 -0
  7. package/es/common/LinkModal/SelectPicture/imgs/picture-bg.png +0 -0
  8. package/es/common/LinkModal/SelectPicture/index.js +135 -0
  9. package/es/common/LinkModal/SelectPicture/index.less +88 -0
  10. package/es/common/LinkModal/index.js +28 -2
  11. package/es/common/PictureModal/index.js +37 -0
  12. package/es/common/PictureModal/index.less +41 -0
  13. package/es/composite-comp/bol/components/Banner/defaultJSON.js +28 -0
  14. package/es/composite-comp/bol/components/Banner/pc/components/BannerContent.js +82 -0
  15. package/es/composite-comp/bol/components/Banner/pc/components/SwiperBannerPc.js +265 -0
  16. package/es/composite-comp/bol/components/Banner/pc/index.js +43 -14
  17. package/es/composite-comp/bol/components/Banner/pc/index.less +82 -10
  18. package/es/composite-comp/bol/config-panels/BannerConfig/index.js +26 -0
  19. package/es/composite-comp/bol/second-config-panels/BannerSecondConfig/index.js +17 -1
  20. package/es/composite-comp/dito/components/GroupedImage/defaultJSON.js +150 -0
  21. package/es/composite-comp/dito/components/GroupedImage/index.js +88 -0
  22. package/es/composite-comp/dito/components/GroupedImage/pc/index.js +200 -0
  23. package/es/composite-comp/dito/components/GroupedImage/pc/index.less +55 -0
  24. package/es/composite-comp/dito/components/Recommend/pc/index.less +2 -0
  25. package/es/composite-comp/dito/components/SearchBanner/mobile/index.js +6 -3
  26. package/es/composite-comp/dito/config-panels/GroupedImageConfig/ConfigGroup/index.js +146 -0
  27. package/es/composite-comp/dito/config-panels/GroupedImageConfig/imgs/defaultImg.png +0 -0
  28. package/es/composite-comp/dito/config-panels/GroupedImageConfig/index.js +127 -0
  29. package/es/composite-comp/dito/second-config-panels/GroupedImageSecondConfig/index.js +192 -0
  30. package/es/constants/component-types.js +9 -3
  31. package/es/constants/index.js +6 -1
  32. package/es/constants/layout.js +30 -2
  33. package/es/core/Renderer/index.js +25 -4
  34. package/es/locale/en/en.json +1 -0
  35. package/es/locale/es/es.json +1 -0
  36. package/es/locale/id/id.json +1 -0
  37. package/es/mobx/Frame.js +5 -0
  38. package/es/utils/businessUtil.js +11 -0
  39. package/es/utils/coreUtil.js +23 -4
  40. package/es/utils/dataUtil.js +14 -0
  41. package/lib/assets/images/layout-icon/banner-layout1.png +0 -0
  42. package/lib/assets/images/layout-icon/banner-layout2.svg +6 -0
  43. package/lib/assets/images/layout-icon/center.png +0 -0
  44. package/lib/assets/images/layout-icon/grouped-image-layout1.png +0 -0
  45. package/lib/assets/images/layout-icon/left.png +0 -0
  46. package/lib/assets/images/layout-icon/right.png +0 -0
  47. package/lib/common/LinkModal/SelectPicture/imgs/picture-bg.png +0 -0
  48. package/lib/common/LinkModal/SelectPicture/index.js +135 -0
  49. package/lib/common/LinkModal/SelectPicture/index.less +88 -0
  50. package/lib/common/LinkModal/index.js +28 -2
  51. package/lib/common/PictureModal/index.js +37 -0
  52. package/lib/common/PictureModal/index.less +41 -0
  53. package/lib/composite-comp/bol/components/Banner/defaultJSON.js +28 -0
  54. package/lib/composite-comp/bol/components/Banner/pc/components/BannerContent.js +82 -0
  55. package/lib/composite-comp/bol/components/Banner/pc/components/SwiperBannerPc.js +265 -0
  56. package/lib/composite-comp/bol/components/Banner/pc/index.js +43 -14
  57. package/lib/composite-comp/bol/components/Banner/pc/index.less +82 -10
  58. package/lib/composite-comp/bol/config-panels/BannerConfig/index.js +26 -0
  59. package/lib/composite-comp/bol/second-config-panels/BannerSecondConfig/index.js +17 -1
  60. package/lib/composite-comp/dito/components/GroupedImage/defaultJSON.js +150 -0
  61. package/lib/composite-comp/dito/components/GroupedImage/index.js +88 -0
  62. package/lib/composite-comp/dito/components/GroupedImage/pc/index.js +200 -0
  63. package/lib/composite-comp/dito/components/GroupedImage/pc/index.less +55 -0
  64. package/lib/composite-comp/dito/components/Recommend/pc/index.less +2 -0
  65. package/lib/composite-comp/dito/components/SearchBanner/mobile/index.js +6 -3
  66. package/lib/composite-comp/dito/config-panels/GroupedImageConfig/ConfigGroup/index.js +146 -0
  67. package/lib/composite-comp/dito/config-panels/GroupedImageConfig/imgs/defaultImg.png +0 -0
  68. package/lib/composite-comp/dito/config-panels/GroupedImageConfig/index.js +127 -0
  69. package/lib/composite-comp/dito/second-config-panels/GroupedImageSecondConfig/index.js +192 -0
  70. package/lib/constants/component-types.js +9 -3
  71. package/lib/constants/index.js +6 -1
  72. package/lib/constants/layout.js +30 -2
  73. package/lib/core/Renderer/index.js +25 -4
  74. package/lib/locale/en/en.json +1 -0
  75. package/lib/locale/es/es.json +1 -0
  76. package/lib/locale/id/id.json +1 -0
  77. package/lib/mobx/Frame.js +5 -0
  78. package/lib/utils/businessUtil.js +11 -0
  79. package/lib/utils/coreUtil.js +23 -4
  80. package/lib/utils/dataUtil.js +14 -0
  81. package/package.json +3 -2
  82. package/es/utils/pluginsUtil.js +0 -1
  83. package/lib/utils/pluginsUtil.js +0 -1
@@ -0,0 +1,127 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports["default"] = void 0;
7
+
8
+ var _react = _interopRequireDefault(require("react"));
9
+
10
+ var _ConfigGroup = _interopRequireDefault(require("./ConfigGroup"));
11
+
12
+ var _SpacingConfig = _interopRequireDefault(require("../../../common/config-panels/SpacingConfig"));
13
+
14
+ var _CustomizeConfig = _interopRequireDefault(require("../../../common/config-panels/CustomizeConfig"));
15
+
16
+ var _BackgroundConfig = _interopRequireDefault(require("../../../common/config-panels/BackgroundConfig"));
17
+
18
+ var _Collapse = _interopRequireDefault(require("../../../../common/Collapse"));
19
+
20
+ var _locale = require("../../../../locale");
21
+
22
+ var _layout = require("../../../../constants/layout");
23
+
24
+ var _coreUtil = require("../../../../utils/coreUtil");
25
+
26
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
27
+
28
+ var __extends = void 0 && (void 0).__extends || function () {
29
+ var _extendStatics = function extendStatics(d, b) {
30
+ _extendStatics = Object.setPrototypeOf || {
31
+ __proto__: []
32
+ } instanceof Array && function (d, b) {
33
+ d.__proto__ = b;
34
+ } || function (d, b) {
35
+ for (var p in b) {
36
+ if (b.hasOwnProperty(p)) d[p] = b[p];
37
+ }
38
+ };
39
+
40
+ return _extendStatics(d, b);
41
+ };
42
+
43
+ return function (d, b) {
44
+ _extendStatics(d, b);
45
+
46
+ function __() {
47
+ this.constructor = d;
48
+ }
49
+
50
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
51
+ };
52
+ }();
53
+
54
+ var GroupedImageConfig =
55
+ /** @class */
56
+ function (_super) {
57
+ __extends(GroupedImageConfig, _super);
58
+
59
+ function GroupedImageConfig() {
60
+ var _this = _super !== null && _super.apply(this, arguments) || this;
61
+
62
+ _this.getLayout = function (v) {
63
+ var data = _this.props.data;
64
+
65
+ if ((0, _coreUtil.isPc)()) {
66
+ data.customize.layout.pcLayout = v;
67
+ } else {
68
+ data.customize.layout.h5Layout = v;
69
+ }
70
+
71
+ _this.setState({});
72
+ };
73
+
74
+ return _this;
75
+ }
76
+
77
+ GroupedImageConfig.prototype.render = function () {
78
+ var _this = this;
79
+
80
+ var data = this.props.data;
81
+ return /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement(_Collapse["default"], {
82
+ divider: "bold",
83
+ headerSize: "large",
84
+ source: [{
85
+ key: '1',
86
+ name: (0, _locale.i18n)('GROUP'),
87
+ value: /*#__PURE__*/_react["default"].createElement(_ConfigGroup["default"], {
88
+ id: data.id,
89
+ source: data.groupSource
90
+ })
91
+ }, {
92
+ key: '2',
93
+ name: (0, _locale.i18n)('SPACING'),
94
+ value: /*#__PURE__*/_react["default"].createElement(_SpacingConfig["default"], {
95
+ configCompSpace: true,
96
+ data: data.spacing
97
+ })
98
+ }, {
99
+ key: '3',
100
+ name: (0, _locale.i18n)('CUSTOMIZE'),
101
+ value: /*#__PURE__*/_react["default"].createElement(_CustomizeConfig["default"], {
102
+ data: data.customize,
103
+ isHideAlign: true,
104
+ layoutSource: _layout.groupedImageLayoutPc,
105
+ selectedLayoutFun: function selectedLayoutFun(v) {
106
+ _this.getLayout(v);
107
+ }
108
+ })
109
+ }, {
110
+ key: '4',
111
+ name: (0, _locale.i18n)('BACKGROUND'),
112
+ value: /*#__PURE__*/_react["default"].createElement(_BackgroundConfig["default"], {
113
+ data: data.background
114
+ })
115
+ }],
116
+ type: "triangle"
117
+ }));
118
+ };
119
+
120
+ GroupedImageConfig.defaultProps = {
121
+ data: {}
122
+ };
123
+ return GroupedImageConfig;
124
+ }(_react["default"].Component);
125
+
126
+ var _default = GroupedImageConfig;
127
+ exports["default"] = _default;
@@ -0,0 +1,192 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports["default"] = void 0;
7
+
8
+ var _react = _interopRequireDefault(require("react"));
9
+
10
+ var _common = require("../../../../common");
11
+
12
+ var _ImageConfig = _interopRequireDefault(require("../../../../meta-comp/config-panels/ImageConfig"));
13
+
14
+ var _TextConfig = _interopRequireDefault(require("../../../../meta-comp/config-panels/TextConfig"));
15
+
16
+ var _BaseConfig = _interopRequireDefault(require("../../../../meta-comp/config-panels/BaseConfig"));
17
+
18
+ var _locale = require("../../../../locale");
19
+
20
+ var _coreUtil = require("../../../../utils/coreUtil");
21
+
22
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
23
+
24
+ var __extends = void 0 && (void 0).__extends || function () {
25
+ var _extendStatics = function extendStatics(d, b) {
26
+ _extendStatics = Object.setPrototypeOf || {
27
+ __proto__: []
28
+ } instanceof Array && function (d, b) {
29
+ d.__proto__ = b;
30
+ } || function (d, b) {
31
+ for (var p in b) {
32
+ if (b.hasOwnProperty(p)) d[p] = b[p];
33
+ }
34
+ };
35
+
36
+ return _extendStatics(d, b);
37
+ };
38
+
39
+ return function (d, b) {
40
+ _extendStatics(d, b);
41
+
42
+ function __() {
43
+ this.constructor = d;
44
+ }
45
+
46
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
47
+ };
48
+ }();
49
+
50
+ var __assign = void 0 && (void 0).__assign || function () {
51
+ __assign = Object.assign || function (t) {
52
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
53
+ s = arguments[i];
54
+
55
+ for (var p in s) {
56
+ if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
57
+ }
58
+ }
59
+
60
+ return t;
61
+ };
62
+
63
+ return __assign.apply(this, arguments);
64
+ };
65
+
66
+ var GroupedImageSecondConfig =
67
+ /** @class */
68
+ function (_super) {
69
+ __extends(GroupedImageSecondConfig, _super);
70
+
71
+ function GroupedImageSecondConfig() {
72
+ var _this = _super !== null && _super.apply(this, arguments) || this;
73
+
74
+ _this.getContentPanel = function () {
75
+ var panelProps = _this.props.panelProps;
76
+ var defaultSource = [{
77
+ key: 'defaultSource_1',
78
+ name: (0, _locale.i18n)('GROUP_IMAGE'),
79
+ value: /*#__PURE__*/_react["default"].createElement(_ImageConfig["default"], {
80
+ data: panelProps.image
81
+ }),
82
+ metaOption: panelProps.image
83
+ }, {
84
+ key: 'defaultSource_2',
85
+ name: (0, _locale.i18n)('TEXT'),
86
+ value: /*#__PURE__*/_react["default"].createElement(_TextConfig["default"], {
87
+ data: panelProps.title
88
+ }),
89
+ metaOption: panelProps.title
90
+ }, {
91
+ key: 'defaultSource_3',
92
+ name: (0, _locale.i18n)('IMAGE') + " 1",
93
+ value: /*#__PURE__*/_react["default"].createElement(_ImageConfig["default"], {
94
+ data: panelProps.image1
95
+ }),
96
+ metaOption: panelProps.image1
97
+ }, {
98
+ key: 'defaultSource_4',
99
+ name: (0, _locale.i18n)('IMAGE') + " 2",
100
+ value: /*#__PURE__*/_react["default"].createElement(_ImageConfig["default"], {
101
+ data: panelProps.image2
102
+ }),
103
+ metaOption: panelProps.image2
104
+ }, {
105
+ key: 'defaultSource_5',
106
+ name: (0, _locale.i18n)('IMAGE') + " 3",
107
+ value: /*#__PURE__*/_react["default"].createElement(_ImageConfig["default"], {
108
+ data: panelProps.image3
109
+ }),
110
+ metaOption: panelProps.image3
111
+ }, {
112
+ key: 'defaultSource_6',
113
+ name: (0, _locale.i18n)('IMAGE') + " 4",
114
+ value: /*#__PURE__*/_react["default"].createElement(_ImageConfig["default"], {
115
+ data: panelProps.image4
116
+ }),
117
+ metaOption: panelProps.image4
118
+ }];
119
+ return /*#__PURE__*/_react["default"].createElement(_common.Collapse, {
120
+ headerSize: "middle",
121
+ onRefresh: function onRefresh() {
122
+ return (0, _coreUtil.renderPreview)();
123
+ },
124
+ showActiveColor: true,
125
+ source: defaultSource,
126
+ type: "switch"
127
+ });
128
+ };
129
+
130
+ _this.resetHover = function () {
131
+ var panelProps = _this.props.panelProps;
132
+
133
+ if (panelProps.hover && panelProps.hover.open) {
134
+ panelProps.hover.image = __assign(__assign({}, panelProps.hover.image), JSON.parse(JSON.stringify(panelProps.image)));
135
+ }
136
+ };
137
+
138
+ return _this;
139
+ }
140
+
141
+ GroupedImageSecondConfig.prototype.render = function () {
142
+ var _this = this;
143
+
144
+ var panelProps = this.props.panelProps;
145
+
146
+ var hoverPanel = /*#__PURE__*/_react["default"].createElement(_common.Collapse, {
147
+ divider: "dashed",
148
+ noChange: true,
149
+ onRefresh: function onRefresh() {
150
+ return (0, _coreUtil.renderPreview)();
151
+ },
152
+ source: [{
153
+ key: 'hoverSetting_1',
154
+ name: (0, _locale.i18n)('GROUP_IMAGE'),
155
+ value: /*#__PURE__*/_react["default"].createElement(_ImageConfig["default"], {
156
+ data: panelProps.hover.image
157
+ }),
158
+ metaOption: panelProps.hover.image
159
+ }],
160
+ type: "switch"
161
+ });
162
+
163
+ return /*#__PURE__*/_react["default"].createElement("div", {
164
+ className: "grouped_image_second_conf_wrap"
165
+ }, /*#__PURE__*/_react["default"].createElement(_common.Collapse, {
166
+ divider: "bold",
167
+ headerSize: "large",
168
+ onRefresh: function onRefresh() {
169
+ return _this.resetHover();
170
+ },
171
+ source: [{
172
+ key: '1',
173
+ name: (0, _locale.i18n)('CONTENT'),
174
+ value: this.getContentPanel()
175
+ }, {
176
+ key: '2',
177
+ name: (0, _locale.i18n)('HOVER'),
178
+ value: hoverPanel,
179
+ metaOption: panelProps.hover,
180
+ toggleType: 'checkbox'
181
+ }]
182
+ }));
183
+ };
184
+
185
+ GroupedImageSecondConfig.defaultProps = {
186
+ panelProps: {}
187
+ };
188
+ return GroupedImageSecondConfig;
189
+ }(_BaseConfig["default"]);
190
+
191
+ var _default = GroupedImageSecondConfig;
192
+ exports["default"] = _default;
@@ -65,6 +65,8 @@ var _SearchBanner = _interopRequireDefault(require("../composite-comp/dito/compo
65
65
 
66
66
  var _GroupedCarousel = _interopRequireDefault(require("../composite-comp/dito/components/GroupedCarousel"));
67
67
 
68
+ var _GroupedImage = _interopRequireDefault(require("../composite-comp/dito/components/GroupedImage"));
69
+
68
70
  var _SlideImage = _interopRequireDefault(require("../composite-comp/dito/components/SlideImage"));
69
71
 
70
72
  var _SearchDITO = _interopRequireDefault(require("../composite-comp/dito/components/SearchDITO"));
@@ -133,6 +135,8 @@ var _SearchBannerConfig = _interopRequireDefault(require("../composite-comp/dito
133
135
 
134
136
  var _GroupedCarouselConfig = _interopRequireDefault(require("../composite-comp/dito/config-panels/GroupedCarouselConfig"));
135
137
 
138
+ var _GroupedImageConfig = _interopRequireDefault(require("../composite-comp/dito/config-panels/GroupedImageConfig"));
139
+
136
140
  var _SlideImageConfig = _interopRequireDefault(require("../composite-comp/dito/config-panels/SlideImageConfig"));
137
141
 
138
142
  var _SearchDITOConfig = _interopRequireDefault(require("../composite-comp/dito/config-panels/SearchDITOConfig"));
@@ -183,6 +187,8 @@ var _SearchBannerSecondConfig = _interopRequireDefault(require("../composite-com
183
187
 
184
188
  var _GroupedCarouselSecondConfig = _interopRequireDefault(require("../composite-comp/dito/second-config-panels/GroupedCarouselSecondConfig"));
185
189
 
190
+ var _GroupedImageSecondConfig = _interopRequireDefault(require("../composite-comp/dito/second-config-panels/GroupedImageSecondConfig"));
191
+
186
192
  var _SlideImageSecondConfig = _interopRequireDefault(require("../composite-comp/dito/second-config-panels/SlideImageSecondConfig"));
187
193
 
188
194
  var _SearchDITOSecondConfig = _interopRequireDefault(require("../composite-comp/dito/second-config-panels/SearchDITOSecondConfig"));
@@ -199,17 +205,17 @@ var _a, _b, _c; // 组件
199
205
  /**
200
206
  * 渲染组件索引
201
207
  */
202
- var componentMap = (_a = {}, _a[_Banner["default"].type] = _Banner["default"], _a[_Video["default"].type] = _Video["default"], _a[_Text["default"].type] = _Text["default"], _a[_FlashDeal["default"].type] = _FlashDeal["default"], _a[_GroupBuy["default"].type] = _GroupBuy["default"], _a[_SearchBar["default"].type] = _SearchBar["default"], _a[_SignBoard["default"].type] = _SignBoard["default"], _a[_MenuNavigation["default"].type] = _MenuNavigation["default"], _a[_HeadNavigation["default"].type] = _HeadNavigation["default"], _a[_PersonalInformation["default"].type] = _PersonalInformation["default"], _a[_PersonalInformationSecond["default"].type] = _PersonalInformationSecond["default"], _a[_CommonFunctions["default"].type] = _CommonFunctions["default"], _a[_ImageText["default"].type] = _ImageText["default"], _a[_Recommend["default"].type] = _Recommend["default"], _a[_AffiliateRecommend["default"].type] = _AffiliateRecommend["default"], _a[_MobileNavigation["default"].type] = _MobileNavigation["default"], _a[_PcNavigation["default"].type] = _PcNavigation["default"], _a[_Divider["default"].type] = _Divider["default"], _a[_ImageGallery["default"].type] = _ImageGallery["default"], _a[_Newsletter["default"].type] = _Newsletter["default"], _a[_Carousel["default"].type] = _Carousel["default"], _a[_Button["default"].type] = _Button["default"], _a[_Tag["default"].type] = _Tag["default"], _a[_Wallet["default"].type] = _Wallet["default"], _a[_WalletNuri["default"].type] = _WalletNuri["default"], _a[_CustomCode["default"].type] = _CustomCode["default"], _a[_Location["default"].type] = _Location["default"], _a[_Bargain["default"].type] = _Bargain["default"], _a[_SearchBanner["default"].type] = _SearchBanner["default"], _a[_GroupedCarousel["default"].type] = _GroupedCarousel["default"], _a[_SlideImage["default"].type] = _SlideImage["default"], _a[_SearchDITO["default"].type] = _SearchDITO["default"], _a[_News["default"].type] = _News["default"], _a[_Campaign["default"].type] = _Campaign["default"], _a);
208
+ var componentMap = (_a = {}, _a[_Banner["default"].type] = _Banner["default"], _a[_Video["default"].type] = _Video["default"], _a[_Text["default"].type] = _Text["default"], _a[_FlashDeal["default"].type] = _FlashDeal["default"], _a[_GroupBuy["default"].type] = _GroupBuy["default"], _a[_SearchBar["default"].type] = _SearchBar["default"], _a[_SignBoard["default"].type] = _SignBoard["default"], _a[_MenuNavigation["default"].type] = _MenuNavigation["default"], _a[_HeadNavigation["default"].type] = _HeadNavigation["default"], _a[_PersonalInformation["default"].type] = _PersonalInformation["default"], _a[_PersonalInformationSecond["default"].type] = _PersonalInformationSecond["default"], _a[_CommonFunctions["default"].type] = _CommonFunctions["default"], _a[_ImageText["default"].type] = _ImageText["default"], _a[_Recommend["default"].type] = _Recommend["default"], _a[_AffiliateRecommend["default"].type] = _AffiliateRecommend["default"], _a[_GroupedImage["default"].type] = _GroupedImage["default"], _a[_MobileNavigation["default"].type] = _MobileNavigation["default"], _a[_PcNavigation["default"].type] = _PcNavigation["default"], _a[_Divider["default"].type] = _Divider["default"], _a[_ImageGallery["default"].type] = _ImageGallery["default"], _a[_Newsletter["default"].type] = _Newsletter["default"], _a[_Carousel["default"].type] = _Carousel["default"], _a[_Button["default"].type] = _Button["default"], _a[_Tag["default"].type] = _Tag["default"], _a[_Wallet["default"].type] = _Wallet["default"], _a[_WalletNuri["default"].type] = _WalletNuri["default"], _a[_CustomCode["default"].type] = _CustomCode["default"], _a[_Location["default"].type] = _Location["default"], _a[_Bargain["default"].type] = _Bargain["default"], _a[_SearchBanner["default"].type] = _SearchBanner["default"], _a[_GroupedCarousel["default"].type] = _GroupedCarousel["default"], _a[_SlideImage["default"].type] = _SlideImage["default"], _a[_SearchDITO["default"].type] = _SearchDITO["default"], _a[_News["default"].type] = _News["default"], _a[_Campaign["default"].type] = _Campaign["default"], _a);
203
209
  /**
204
210
  * 一级配置面板索引
205
211
  */
206
212
 
207
213
  exports.componentMap = componentMap;
208
- var configPanelMap = (_b = {}, _b[_Banner["default"].type] = _BannerConfig["default"], _b[_Video["default"].type] = _VideoConfig["default"], _b[_Text["default"].type] = _TextCompConfig["default"], _b[_FlashDeal["default"].type] = _FlashDealConfig["default"], _b[_GroupBuy["default"].type] = _GroupBuyConfig["default"], _b[_SearchBar["default"].type] = _SearchBarConfig["default"], _b[_SignBoard["default"].type] = _SignBoardConfig["default"], _b[_MenuNavigation["default"].type] = _MenuNavigationConfig["default"], _b[_HeadNavigation["default"].type] = _HeadNavigationConfig["default"], _b[_PersonalInformation["default"].type] = _PersonalInformationConfig["default"], _b[_PersonalInformationSecond["default"].type] = _PersonalInformationSecondConfig["default"], _b[_CommonFunctions["default"].type] = _CommonFunctionsConfig["default"], _b[_ImageText["default"].type] = _ImageTextConfig["default"], _b[_Recommend["default"].type] = _RecommendConfig["default"], _b[_AffiliateRecommend["default"].type] = _AffiliateRecommendConfig["default"], _b[_MobileNavigation["default"].type] = _MobileNavigationConfig["default"], _b[_PcNavigation["default"].type] = _PcNavigationConfig["default"], _b[_Divider["default"].type] = _DividerConfig["default"], _b[_ImageGallery["default"].type] = _ImageGalleryConfig["default"], _b[_Newsletter["default"].type] = _NewsletterConfig["default"], _b[_Carousel["default"].type] = _CarouselConfig["default"], _b[_Button["default"].type] = _ButtonCompConfig["default"], _b[_Tag["default"].type] = _TagCompConfig["default"], _b[_Wallet["default"].type] = _WalletConfig["default"], _b[_WalletNuri["default"].type] = _WalletNuriConfig["default"], _b[_CustomCode["default"].type] = _CustomCodeConfig["default"], _b[_Location["default"].type] = _LocationConfig["default"], _b[_Bargain["default"].type] = _BargainConfig["default"], _b[_SearchBanner["default"].type] = _SearchBannerConfig["default"], _b[_GroupedCarousel["default"].type] = _GroupedCarouselConfig["default"], _b[_SlideImage["default"].type] = _SlideImageConfig["default"], _b[_SearchDITO["default"].type] = _SearchDITOConfig["default"], _b[_News["default"].type] = _NewsConfig["default"], _b[_Campaign["default"].type] = _CampaignConfig["default"], _b);
214
+ var configPanelMap = (_b = {}, _b[_Banner["default"].type] = _BannerConfig["default"], _b[_Video["default"].type] = _VideoConfig["default"], _b[_Text["default"].type] = _TextCompConfig["default"], _b[_FlashDeal["default"].type] = _FlashDealConfig["default"], _b[_GroupBuy["default"].type] = _GroupBuyConfig["default"], _b[_SearchBar["default"].type] = _SearchBarConfig["default"], _b[_SignBoard["default"].type] = _SignBoardConfig["default"], _b[_MenuNavigation["default"].type] = _MenuNavigationConfig["default"], _b[_HeadNavigation["default"].type] = _HeadNavigationConfig["default"], _b[_PersonalInformation["default"].type] = _PersonalInformationConfig["default"], _b[_PersonalInformationSecond["default"].type] = _PersonalInformationSecondConfig["default"], _b[_CommonFunctions["default"].type] = _CommonFunctionsConfig["default"], _b[_ImageText["default"].type] = _ImageTextConfig["default"], _b[_Recommend["default"].type] = _RecommendConfig["default"], _b[_AffiliateRecommend["default"].type] = _AffiliateRecommendConfig["default"], _b[_GroupedImage["default"].type] = _GroupedImageConfig["default"], _b[_MobileNavigation["default"].type] = _MobileNavigationConfig["default"], _b[_PcNavigation["default"].type] = _PcNavigationConfig["default"], _b[_Divider["default"].type] = _DividerConfig["default"], _b[_ImageGallery["default"].type] = _ImageGalleryConfig["default"], _b[_Newsletter["default"].type] = _NewsletterConfig["default"], _b[_Carousel["default"].type] = _CarouselConfig["default"], _b[_Button["default"].type] = _ButtonCompConfig["default"], _b[_Tag["default"].type] = _TagCompConfig["default"], _b[_Wallet["default"].type] = _WalletConfig["default"], _b[_WalletNuri["default"].type] = _WalletNuriConfig["default"], _b[_CustomCode["default"].type] = _CustomCodeConfig["default"], _b[_Location["default"].type] = _LocationConfig["default"], _b[_Bargain["default"].type] = _BargainConfig["default"], _b[_SearchBanner["default"].type] = _SearchBannerConfig["default"], _b[_GroupedCarousel["default"].type] = _GroupedCarouselConfig["default"], _b[_SlideImage["default"].type] = _SlideImageConfig["default"], _b[_SearchDITO["default"].type] = _SearchDITOConfig["default"], _b[_News["default"].type] = _NewsConfig["default"], _b[_Campaign["default"].type] = _CampaignConfig["default"], _b);
209
215
  /**
210
216
  * 二级配置面板索引
211
217
  */
212
218
 
213
219
  exports.configPanelMap = configPanelMap;
214
- var secondConfigPanelMap = (_c = {}, _c[_Banner["default"].type] = _BannerSecondConfig["default"], _c[_Video["default"].type] = _VideoSecondConfig["default"], _c[_Text["default"].type] = _TextSecondConfig["default"], _c[_ImageText["default"].type] = _ImageTextSecondConfig["default"], _c[_Recommend["default"].type] = _RecommendSecondConfig["default"], _c[_AffiliateRecommend["default"].type] = _AffiliateRecommendSecondConfig["default"], _c[_MobileNavigation["default"].type] = _MobileNavigationSecondConfig["default"], _c[_PcNavigation["default"].type] = _PcNavigationSecondConfig["default"], _c[_MenuNavigation["default"].type] = _MenuNavigationSecondConfig["default"], _c[_HeadNavigation["default"].type] = _HeadNavigationSecondConfig["default"], _c[_PersonalInformation["default"].type] = _PersonalInformationSecondConfig2["default"], _c[_PersonalInformationSecond["default"].type] = _PersonalInformationSecondSecondConfig["default"], _c[_CommonFunctions["default"].type] = _CommonFunctionsSecondConfig["default"], _c[_Carousel["default"].type] = _CarouselSecondConfig["default"], _c[_ImageGallery["default"].type] = _ImageGallerySecondConfig["default"], _c[_Tag["default"].type] = _TagSecondConfig["default"], _c[_Button["default"].type] = _ButtonSecondConfig["default"], _c[_Wallet["default"].type] = _WalletSecondConfig["default"], _c[_WalletNuri["default"].type] = _WalletNuriSecondConfig["default"], _c[_SearchBanner["default"].type] = _SearchBannerSecondConfig["default"], _c[_GroupedCarousel["default"].type] = _GroupedCarouselSecondConfig["default"], _c[_SlideImage["default"].type] = _SlideImageSecondConfig["default"], _c[_SearchDITO["default"].type] = _SearchDITOSecondConfig["default"], _c[_News["default"].type] = _NewsSecondConfig["default"], _c[_Campaign["default"].type] = _CampaignSecondConfig["default"], _c);
220
+ var secondConfigPanelMap = (_c = {}, _c[_Banner["default"].type] = _BannerSecondConfig["default"], _c[_Video["default"].type] = _VideoSecondConfig["default"], _c[_Text["default"].type] = _TextSecondConfig["default"], _c[_ImageText["default"].type] = _ImageTextSecondConfig["default"], _c[_Recommend["default"].type] = _RecommendSecondConfig["default"], _c[_AffiliateRecommend["default"].type] = _AffiliateRecommendSecondConfig["default"], _c[_MobileNavigation["default"].type] = _MobileNavigationSecondConfig["default"], _c[_PcNavigation["default"].type] = _PcNavigationSecondConfig["default"], _c[_MenuNavigation["default"].type] = _MenuNavigationSecondConfig["default"], _c[_HeadNavigation["default"].type] = _HeadNavigationSecondConfig["default"], _c[_PersonalInformation["default"].type] = _PersonalInformationSecondConfig2["default"], _c[_PersonalInformationSecond["default"].type] = _PersonalInformationSecondSecondConfig["default"], _c[_CommonFunctions["default"].type] = _CommonFunctionsSecondConfig["default"], _c[_Carousel["default"].type] = _CarouselSecondConfig["default"], _c[_ImageGallery["default"].type] = _ImageGallerySecondConfig["default"], _c[_Tag["default"].type] = _TagSecondConfig["default"], _c[_Button["default"].type] = _ButtonSecondConfig["default"], _c[_Wallet["default"].type] = _WalletSecondConfig["default"], _c[_WalletNuri["default"].type] = _WalletNuriSecondConfig["default"], _c[_SearchBanner["default"].type] = _SearchBannerSecondConfig["default"], _c[_GroupedCarousel["default"].type] = _GroupedCarouselSecondConfig["default"], _c[_GroupedImage["default"].type] = _GroupedImageSecondConfig["default"], _c[_SlideImage["default"].type] = _SlideImageSecondConfig["default"], _c[_SearchDITO["default"].type] = _SearchDITOSecondConfig["default"], _c[_News["default"].type] = _NewsSecondConfig["default"], _c[_Campaign["default"].type] = _CampaignSecondConfig["default"], _c);
215
221
  exports.secondConfigPanelMap = secondConfigPanelMap;
@@ -118,7 +118,8 @@ var urlTypeMap = {
118
118
  STORE: 'Store',
119
119
  AFFILIATE_PRODUCT: 'AffiliateProduct',
120
120
  ANCHOR: 'Anchor',
121
- CARD_PRODUCT_LIST: 'ProductList'
121
+ CARD_PRODUCT_LIST: 'ProductList',
122
+ PICTURE: 'Picture'
122
123
  };
123
124
  exports.urlTypeMap = urlTypeMap;
124
125
  var respCodeMap = {
@@ -289,6 +290,10 @@ var compInfoMap = {
289
290
  CAMPAIGN: {
290
291
  name: 'Campaign',
291
292
  icon: 'icon-carousel'
293
+ },
294
+ GROUPED_IMAGE: {
295
+ name: 'Grouped Image',
296
+ icon: 'icon-forms'
292
297
  }
293
298
  };
294
299
  /**
@@ -3,7 +3,7 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.videoPCLayout = exports.videoH5Layout = exports.slideImageLayout = exports.searchLayout = exports.searchDitoLayout = exports.recommendLayoutPc = exports.recommendLayoutMobile = exports.pcNavigationLayout = exports.pcFlashDealLayout = exports.newsletterLayout = exports.newsLayout = exports.mobileNavigationLayout = exports.locationLayout = exports.imageTextLayoutPc = exports.imageTextLayoutMobile = exports.imageGalleryPcLayout = exports.imageGalleryLayout = exports.groupedCarouselLayout = exports.flashDealLayout = exports.dividerLayout = exports.carouselLayout = exports.campaignLayout = exports.bannerSlideLayout = exports.affiliateLayoutPc = exports.affiliateLayoutMobile = exports.WalletNuriLayout = exports.WalletLayout = void 0;
6
+ exports.videoPCLayout = exports.videoH5Layout = exports.slideImageLayout = exports.searchLayout = exports.searchDitoLayout = exports.recommendLayoutPc = exports.recommendLayoutMobile = exports.pcNavigationLayout = exports.pcFlashDealLayout = exports.newsletterLayout = exports.newsLayout = exports.mobileNavigationLayout = exports.locationLayout = exports.imageTextLayoutPc = exports.imageTextLayoutMobile = exports.imageGalleryPcLayout = exports.imageGalleryLayout = exports.groupedImageLayoutPc = exports.groupedCarouselLayout = exports.flashDealLayout = exports.dividerLayout = exports.carouselLayout = exports.campaignLayout = exports.bannerSlideLayout = exports.bannerPcLayout = exports.bannerH5Layout = exports.affiliateLayoutPc = exports.affiliateLayoutMobile = exports.WalletNuriLayout = exports.WalletLayout = void 0;
7
7
 
8
8
  var _dividerLayout = _interopRequireDefault(require("../assets/images/layout-icon/dividerLayout.svg"));
9
9
 
@@ -63,6 +63,8 @@ var _layoutRecommend4 = _interopRequireDefault(require("../assets/images/layout-
63
63
 
64
64
  var _layoutRecommend5 = _interopRequireDefault(require("../assets/images/layout-icon/layout-recommend-5.png"));
65
65
 
66
+ var _groupedImageLayout = _interopRequireDefault(require("../assets/images/layout-icon/grouped-image-layout1.png"));
67
+
66
68
  var _layoutVideoH = _interopRequireDefault(require("../assets/images/layout-icon/layout-video-h5-1.png"));
67
69
 
68
70
  var _layoutVideoH2 = _interopRequireDefault(require("../assets/images/layout-icon/layout-video-h5-2.png"));
@@ -103,6 +105,10 @@ var _newsLayout = _interopRequireDefault(require("../assets/images/layout-icon/n
103
105
 
104
106
  var _campaignLayout = _interopRequireDefault(require("../assets/images/layout-icon/campaignLayout1.png"));
105
107
 
108
+ var _bannerLayout = _interopRequireDefault(require("../assets/images/layout-icon/banner-layout1.png"));
109
+
110
+ var _bannerLayout2 = _interopRequireDefault(require("../assets/images/layout-icon/banner-layout2.svg"));
111
+
106
112
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
107
113
 
108
114
  // import p3 from '../assets/images/layout-icon/layout-imagetext-p3.png';
@@ -268,6 +274,12 @@ var recommendLayoutPc = [{
268
274
  image: _layoutRecommend5["default"]
269
275
  }];
270
276
  exports.recommendLayoutPc = recommendLayoutPc;
277
+ var groupedImageLayoutPc = [{
278
+ id: 'layout1',
279
+ name: 'layout1',
280
+ image: _groupedImageLayout["default"]
281
+ }];
282
+ exports.groupedImageLayoutPc = groupedImageLayoutPc;
271
283
  var affiliateLayoutMobile = [{
272
284
  id: 'layout1',
273
285
  name: 'layout1',
@@ -412,4 +424,20 @@ var campaignLayout = [{
412
424
  name: 'layout1',
413
425
  image: _campaignLayout["default"]
414
426
  }];
415
- exports.campaignLayout = campaignLayout;
427
+ exports.campaignLayout = campaignLayout;
428
+ var bannerPcLayout = [{
429
+ id: 'layout1',
430
+ name: 'layout1',
431
+ image: _bannerLayout["default"]
432
+ }, {
433
+ id: 'layout2',
434
+ name: 'layout2',
435
+ image: _bannerLayout2["default"]
436
+ }];
437
+ exports.bannerPcLayout = bannerPcLayout;
438
+ var bannerH5Layout = [{
439
+ id: 'layout1',
440
+ name: 'layout1',
441
+ image: _bannerLayout["default"]
442
+ }];
443
+ exports.bannerH5Layout = bannerH5Layout;
@@ -19,6 +19,8 @@ var _mobx = require("../../mobx");
19
19
 
20
20
  var _common = require("../../common");
21
21
 
22
+ var _PictureModal = _interopRequireDefault(require("../../common/PictureModal"));
23
+
22
24
  var _Iconfont = _interopRequireDefault(require("../../common/Iconfont"));
23
25
 
24
26
  require("./index.less");
@@ -92,9 +94,13 @@ var Renderer = function Renderer(props) {
92
94
  pcProdCardModalState = _c[0],
93
95
  setPcProdCardModalState = _c[1];
94
96
 
95
- var _d = (0, _react.useState)(_mobx.frameStore.toastState),
96
- toastState = _d[0],
97
- setToastState = _d[1];
97
+ var _d = (0, _react.useState)(_mobx.frameStore.pictureModalState),
98
+ pictureModalState = _d[0],
99
+ setPictureModalState = _d[1];
100
+
101
+ var _e = (0, _react.useState)(_mobx.frameStore.toastState),
102
+ toastState = _e[0],
103
+ setToastState = _e[1];
98
104
 
99
105
  if (!noSetWindow) {
100
106
  setDesignConfig(props);
@@ -152,6 +158,7 @@ var Renderer = function Renderer(props) {
152
158
  var disposer = (0, _mobx.autorun)(function () {
153
159
  setModalState(_mobx.frameStore.modalState);
154
160
  setPcProdCardModalState(_mobx.frameStore.pcProdCardModalState);
161
+ setPictureModalState(_mobx.frameStore.pictureModalState);
155
162
  setToastState(_mobx.frameStore.toastState);
156
163
  });
157
164
  return function () {
@@ -180,6 +187,17 @@ var Renderer = function Renderer(props) {
180
187
  });
181
188
  };
182
189
 
190
+ var onClosePictureModal = function onClosePictureModal() {
191
+ document.body.classList.remove('no-scroll');
192
+
193
+ _mobx.frameStore.setState({
194
+ pictureModalState: {
195
+ visible: false,
196
+ url: ''
197
+ }
198
+ });
199
+ };
200
+
183
201
  var onCloseToast = function onCloseToast() {
184
202
  _mobx.frameStore.setState({
185
203
  toastState: {
@@ -242,7 +260,10 @@ var Renderer = function Renderer(props) {
242
260
  onClose: onCloseModal
243
261
  })), pcProdCardModalState.visible && /*#__PURE__*/_react["default"].createElement(_common.ProductCardModal, _extends({}, pcProdCardModalState, {
244
262
  onClose: onCloseProdCardModal
245
- })), toastState.visible && /*#__PURE__*/_react["default"].createElement(_common.Toast, _extends({}, toastState, {
263
+ })), pictureModalState.visible && /*#__PURE__*/_react["default"].createElement(_PictureModal["default"], {
264
+ url: pictureModalState.url,
265
+ onClose: onClosePictureModal
266
+ }), toastState.visible && /*#__PURE__*/_react["default"].createElement(_common.Toast, _extends({}, toastState, {
246
267
  onClose: onCloseToast
247
268
  })));
248
269
  };
@@ -1,4 +1,5 @@
1
1
  {
2
+ "GROUP_IMAGE": "Group Image",
2
3
  "ENDS_IN": "Ends in",
3
4
  "STARTS_IN": "Starts in",
4
5
  "ICON_COLOR": "Icon Color",
@@ -1,4 +1,5 @@
1
1
  {
2
+ "GROUP_IMAGE": "Group Image",
2
3
  "ENDS_IN": "Ends in",
3
4
  "STARTS_IN": "Starts in",
4
5
  "ICON_COLOR": "Icon Color",
@@ -1,4 +1,5 @@
1
1
  {
2
+ "GROUP_IMAGE": "Group Image",
2
3
  "ENDS_IN": "Ends in",
3
4
  "STARTS_IN": "Starts in",
4
5
  "ICON_COLOR": "Icon Color",
package/lib/mobx/Frame.js CHANGED
@@ -64,6 +64,10 @@ function () {
64
64
  visible: false,
65
65
  data: []
66
66
  };
67
+ this.pictureModalState = {
68
+ visible: false,
69
+ url: ''
70
+ };
67
71
  this.toastState = {
68
72
  visible: false,
69
73
  message: '',
@@ -74,6 +78,7 @@ function () {
74
78
  textModalState: _mobx.observable,
75
79
  modalState: _mobx.observable,
76
80
  pcProdCardModalState: _mobx.observable,
81
+ pictureModalState: _mobx.observable,
77
82
  toastState: _mobx.observable
78
83
  });
79
84
  }
@@ -343,6 +343,17 @@ var newParseUrl = function newParseUrl(urlObj) {
343
343
  };
344
344
  break;
345
345
 
346
+ case _constants.urlTypeMap.PICTURE:
347
+ // 图片弹窗
348
+ params = {
349
+ action: 'operation',
350
+ params: {
351
+ type: 'PICTURE',
352
+ url: urlObj.url
353
+ }
354
+ };
355
+ break;
356
+
346
357
  default:
347
358
  var map = {
348
359
  '/main/cart': 'CART',
@@ -3,7 +3,7 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.setMagicDesign = exports.renderPreview = exports.isPc = exports.isDesignMode = exports.isActiveFloor = exports.getVideoCover = exports.createProdCardModal = exports.copyNode = exports.clickUrl = void 0;
6
+ exports.setMagicDesign = exports.renderPreview = exports.isPc = exports.isDesignMode = exports.isActiveFloor = exports.getVideoCover = exports.createProdCardModal = exports.createPictureModal = exports.copyNode = exports.clickUrl = void 0;
7
7
 
8
8
  var _uuid = require("uuid");
9
9
 
@@ -349,14 +349,27 @@ var createProdCardModal = function createProdCardModal(ids) {
349
349
 
350
350
  exports.createProdCardModal = createProdCardModal;
351
351
 
352
+ var createPictureModal = function createPictureModal(url) {
353
+ if (!url) return;
354
+ document.body.classList.add('no-scroll');
355
+
356
+ _mobx.frameStore.setState({
357
+ pictureModalState: {
358
+ visible: true,
359
+ url: url
360
+ }
361
+ });
362
+ };
363
+
364
+ exports.createPictureModal = createPictureModal;
365
+
352
366
  var clickUrl = function clickUrl(url, state) {
353
367
  var _a;
354
368
 
355
369
  if (url === void 0) {
356
370
  url = '';
357
- }
371
+ } // 只读模式,设计模式,url为空,邮箱模版
358
372
 
359
- console.log('clickUrl...', url, state); // 只读模式,设计模式,url为空,邮箱模版
360
373
 
361
374
  if (window.magicDesign.readOnly || window.magicDesign.mode !== 'renderer' || !url || window.magicDesign.outputType == 'html') {
362
375
  return;
@@ -367,7 +380,13 @@ var clickUrl = function clickUrl(url, state) {
367
380
  data = _b.data;
368
381
 
369
382
  var _c = data.params,
370
- params = _c === void 0 ? {} : _c; // PC商品卡片弹窗
383
+ params = _c === void 0 ? {} : _c; // 图片链接弹窗
384
+
385
+ if (params.type === 'PICTURE') {
386
+ createPictureModal(params.url);
387
+ return;
388
+ } // PC商品卡片弹窗
389
+
371
390
 
372
391
  if (params.type === 'CARD_PRODUCT_LIST') {
373
392
  createProdCardModal(params.offerIds);
@@ -0,0 +1,14 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.addDefaultMetaData = void 0;
7
+
8
+ var _data = require("../../data.jsx");
9
+
10
+ var addDefaultMetaData = function addDefaultMetaData(type, parentId) {
11
+ return (0, _data.defMetaData)(parentId)[type];
12
+ };
13
+
14
+ exports.addDefaultMetaData = addDefaultMetaData;