@fonixtree/magic-design 1.0.218 → 1.0.220
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/es/assets/images/layout-icon/banner-layout1.png +0 -0
- package/es/assets/images/layout-icon/banner-layout2.svg +6 -0
- package/es/assets/images/layout-icon/center.png +0 -0
- package/es/assets/images/layout-icon/grouped-image-layout1.png +0 -0
- package/es/assets/images/layout-icon/left.png +0 -0
- package/es/assets/images/layout-icon/right.png +0 -0
- package/es/common/LinkModal/SelectPicture/imgs/picture-bg.png +0 -0
- package/es/common/LinkModal/SelectPicture/index.js +135 -0
- package/es/common/LinkModal/SelectPicture/index.less +88 -0
- package/es/common/LinkModal/index.js +6 -0
- package/es/common/PictureModal/index.js +37 -0
- package/es/common/PictureModal/index.less +41 -0
- package/es/composite-comp/bol/components/Banner/defaultJSON.js +28 -0
- package/es/composite-comp/bol/components/Banner/pc/components/BannerContent.js +82 -0
- package/es/composite-comp/bol/components/Banner/pc/components/SwiperBannerPc.js +270 -0
- package/es/composite-comp/bol/components/Banner/pc/index.js +43 -14
- package/es/composite-comp/bol/components/Banner/pc/index.less +81 -9
- package/es/composite-comp/bol/config-panels/BannerConfig/index.js +26 -0
- package/es/composite-comp/bol/second-config-panels/BannerSecondConfig/index.js +17 -1
- package/es/composite-comp/dito/components/GroupedImage/defaultJSON.js +149 -0
- package/es/composite-comp/dito/components/GroupedImage/index.js +88 -0
- package/es/composite-comp/dito/components/GroupedImage/pc/index.js +417 -0
- package/es/composite-comp/dito/components/GroupedImage/pc/index.less +124 -0
- package/es/composite-comp/dito/components/Recommend/pc/index.js +2 -2
- package/es/composite-comp/dito/components/Recommend/pc/index.less +3 -1
- package/es/composite-comp/dito/config-panels/GroupedImageConfig/ConfigGroup/index.js +146 -0
- package/es/composite-comp/dito/config-panels/GroupedImageConfig/imgs/defaultImg.png +0 -0
- package/es/composite-comp/dito/config-panels/GroupedImageConfig/index.js +127 -0
- package/es/composite-comp/dito/second-config-panels/GroupedImageSecondConfig/index.js +290 -0
- package/es/composite-comp/dito/second-config-panels/GroupedImageSecondConfig/index.less +21 -0
- package/es/constants/component-types.js +9 -3
- package/es/constants/index.js +6 -1
- package/es/constants/layout.js +30 -2
- package/es/core/Designer/ConfigPanel/index.js +217 -4
- package/es/core/Designer/ConfigPanel/index.less +39 -0
- package/es/core/Renderer/index.js +25 -4
- package/es/locale/en/en.json +1 -0
- package/es/locale/es/es.json +1 -0
- package/es/locale/id/id.json +1 -0
- package/es/meta-comp/components/Image/index.js +15 -11
- package/es/meta-comp/config-panels/ImageConfig/index.js +25 -8
- package/es/mobx/Frame.js +5 -0
- package/es/mobx/Store.js +4 -1
- package/es/utils/businessUtil.js +11 -0
- package/es/utils/coreUtil.js +23 -4
- package/es/utils/dataUtil.js +14 -0
- package/lib/assets/images/layout-icon/banner-layout1.png +0 -0
- package/lib/assets/images/layout-icon/banner-layout2.svg +6 -0
- package/lib/assets/images/layout-icon/center.png +0 -0
- package/lib/assets/images/layout-icon/grouped-image-layout1.png +0 -0
- package/lib/assets/images/layout-icon/left.png +0 -0
- package/lib/assets/images/layout-icon/right.png +0 -0
- package/lib/common/LinkModal/SelectPicture/imgs/picture-bg.png +0 -0
- package/lib/common/LinkModal/SelectPicture/index.js +135 -0
- package/lib/common/LinkModal/SelectPicture/index.less +88 -0
- package/lib/common/LinkModal/index.js +6 -0
- package/lib/common/PictureModal/index.js +37 -0
- package/lib/common/PictureModal/index.less +41 -0
- package/lib/composite-comp/bol/components/Banner/defaultJSON.js +28 -0
- package/lib/composite-comp/bol/components/Banner/pc/components/BannerContent.js +82 -0
- package/lib/composite-comp/bol/components/Banner/pc/components/SwiperBannerPc.js +270 -0
- package/lib/composite-comp/bol/components/Banner/pc/index.js +43 -14
- package/lib/composite-comp/bol/components/Banner/pc/index.less +81 -9
- package/lib/composite-comp/bol/config-panels/BannerConfig/index.js +26 -0
- package/lib/composite-comp/bol/second-config-panels/BannerSecondConfig/index.js +17 -1
- package/lib/composite-comp/dito/components/GroupedImage/defaultJSON.js +149 -0
- package/lib/composite-comp/dito/components/GroupedImage/index.js +88 -0
- package/lib/composite-comp/dito/components/GroupedImage/pc/index.js +417 -0
- package/lib/composite-comp/dito/components/GroupedImage/pc/index.less +124 -0
- package/lib/composite-comp/dito/components/Recommend/pc/index.js +2 -2
- package/lib/composite-comp/dito/components/Recommend/pc/index.less +3 -1
- package/lib/composite-comp/dito/config-panels/GroupedImageConfig/ConfigGroup/index.js +146 -0
- package/lib/composite-comp/dito/config-panels/GroupedImageConfig/imgs/defaultImg.png +0 -0
- package/lib/composite-comp/dito/config-panels/GroupedImageConfig/index.js +127 -0
- package/lib/composite-comp/dito/second-config-panels/GroupedImageSecondConfig/index.js +290 -0
- package/lib/composite-comp/dito/second-config-panels/GroupedImageSecondConfig/index.less +21 -0
- package/lib/constants/component-types.js +9 -3
- package/lib/constants/index.js +6 -1
- package/lib/constants/layout.js +30 -2
- package/lib/core/Designer/ConfigPanel/index.js +217 -4
- package/lib/core/Designer/ConfigPanel/index.less +39 -0
- package/lib/core/Renderer/index.js +25 -4
- package/lib/locale/en/en.json +1 -0
- package/lib/locale/es/es.json +1 -0
- package/lib/locale/id/id.json +1 -0
- package/lib/meta-comp/components/Image/index.js +15 -11
- package/lib/meta-comp/config-panels/ImageConfig/index.js +25 -8
- package/lib/mobx/Frame.js +5 -0
- package/lib/mobx/Store.js +4 -1
- package/lib/utils/businessUtil.js +11 -0
- package/lib/utils/coreUtil.js +23 -4
- package/lib/utils/dataUtil.js +14 -0
- package/package.json +3 -2
- package/es/utils/pluginsUtil.js +0 -1
- package/lib/utils/pluginsUtil.js +0 -1
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
.m-grouped-image-pc {
|
|
2
|
+
display: flex;
|
|
3
|
+
flex-direction: column;
|
|
4
|
+
position: relative;
|
|
5
|
+
|
|
6
|
+
&.less-than-4 {
|
|
7
|
+
.image-list-wrapper {
|
|
8
|
+
padding-left: 0!important;
|
|
9
|
+
.image-list {
|
|
10
|
+
width: fit-content;
|
|
11
|
+
margin: 0 auto;
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.tab-select-wrap {
|
|
17
|
+
display: flex;
|
|
18
|
+
align-items: center;
|
|
19
|
+
gap: 16px;
|
|
20
|
+
background: #ffffff;
|
|
21
|
+
overflow: auto;
|
|
22
|
+
position: relative;
|
|
23
|
+
width: fit-content;
|
|
24
|
+
margin: 0 auto 15px;
|
|
25
|
+
|
|
26
|
+
.tabTitle {
|
|
27
|
+
display: flex;
|
|
28
|
+
align-items: center;
|
|
29
|
+
text-align: center;
|
|
30
|
+
padding: 0; // 无缝衔接:去掉左右间距
|
|
31
|
+
width: fit-content;
|
|
32
|
+
justify-content: center;
|
|
33
|
+
white-space: nowrap;
|
|
34
|
+
flex-direction: column;
|
|
35
|
+
cursor: pointer;
|
|
36
|
+
|
|
37
|
+
img {
|
|
38
|
+
max-height: 50px;
|
|
39
|
+
margin-bottom: 2px;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
.tab-content {
|
|
45
|
+
.title {
|
|
46
|
+
text-align: center;
|
|
47
|
+
margin-bottom: 16px;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.image-list-wrapper {
|
|
51
|
+
padding-left: 88px;
|
|
52
|
+
position: relative;
|
|
53
|
+
|
|
54
|
+
.image-list {
|
|
55
|
+
display: flex;
|
|
56
|
+
flex-direction: row;
|
|
57
|
+
gap: 16px;
|
|
58
|
+
overflow-x: auto;
|
|
59
|
+
overflow-y: hidden;
|
|
60
|
+
flex: 1;
|
|
61
|
+
scroll-behavior: smooth;
|
|
62
|
+
-webkit-overflow-scrolling: touch;
|
|
63
|
+
|
|
64
|
+
&::-webkit-scrollbar {
|
|
65
|
+
display: none;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
scrollbar-width: none;
|
|
69
|
+
|
|
70
|
+
.image-item {
|
|
71
|
+
flex-shrink: 0;
|
|
72
|
+
width: 300px;
|
|
73
|
+
|
|
74
|
+
&:last-child {
|
|
75
|
+
margin-right: 40px;
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
.empty-placeholder {
|
|
80
|
+
width: 100%;
|
|
81
|
+
text-align: center;
|
|
82
|
+
color: #999;
|
|
83
|
+
padding: 40px 0;
|
|
84
|
+
font-size: 14px;
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
.arrow-icon-wrapper {
|
|
91
|
+
display: flex;
|
|
92
|
+
justify-content: end;
|
|
93
|
+
padding: 24px 0;
|
|
94
|
+
padding-right: 75px;
|
|
95
|
+
|
|
96
|
+
.arrow-icon {
|
|
97
|
+
display: flex;
|
|
98
|
+
align-items: center;
|
|
99
|
+
justify-content: center;
|
|
100
|
+
width: 40px;
|
|
101
|
+
height: 40px;
|
|
102
|
+
background: #CE1126;
|
|
103
|
+
border-radius: 100px;
|
|
104
|
+
cursor: pointer;
|
|
105
|
+
flex-shrink: 0;
|
|
106
|
+
z-index: 1;
|
|
107
|
+
|
|
108
|
+
&.left {
|
|
109
|
+
margin-right: 16px;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
&.right {
|
|
113
|
+
// margin-left: 15px;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
&.disabled {
|
|
117
|
+
cursor: not-allowed;
|
|
118
|
+
opacity: 0.5;
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
|
|
@@ -279,7 +279,7 @@ function (_super) {
|
|
|
279
279
|
};
|
|
280
280
|
|
|
281
281
|
_this.initTab = function (index, hideTabs) {
|
|
282
|
-
var selectedTabDom = document.querySelector(".tab-select-wrap .tabTitle:nth-child(" + (index + 1) + ")");
|
|
282
|
+
var selectedTabDom = document.querySelector(".recommend-tab-select-wrap .tabTitle:nth-child(" + (index + 1) + ")");
|
|
283
283
|
var tabLeft = 0;
|
|
284
284
|
var tabWidth = 0;
|
|
285
285
|
|
|
@@ -642,7 +642,7 @@ function (_super) {
|
|
|
642
642
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
643
643
|
className: "m-recommend-pc"
|
|
644
644
|
}, !hideTabs && /*#__PURE__*/_react["default"].createElement("div", {
|
|
645
|
-
className: "tab-select-wrap"
|
|
645
|
+
className: "recommend-tab-select-wrap"
|
|
646
646
|
}, groupSource.map(function (tab, index) {
|
|
647
647
|
var _image = index == tabIndex && tab.hover.open && tab.hover.image.open ? tab.hover.image : tab.image;
|
|
648
648
|
|
|
@@ -13,13 +13,15 @@
|
|
|
13
13
|
// display: none;
|
|
14
14
|
// }
|
|
15
15
|
|
|
16
|
-
.tab-select-wrap {
|
|
16
|
+
.recommend-tab-select-wrap {
|
|
17
17
|
display: flex;
|
|
18
18
|
align-items: center;
|
|
19
19
|
height: 50px;
|
|
20
20
|
background: rgb(255 255 255);
|
|
21
21
|
overflow: auto;
|
|
22
22
|
position: relative;
|
|
23
|
+
width: fit-content;
|
|
24
|
+
margin: 0 auto;
|
|
23
25
|
margin-bottom: 15px;
|
|
24
26
|
|
|
25
27
|
.tabTitle {
|
|
@@ -0,0 +1,146 @@
|
|
|
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 _mobxReact = require("mobx-react");
|
|
11
|
+
|
|
12
|
+
var _defaultImg = _interopRequireDefault(require("../imgs/defaultImg.png"));
|
|
13
|
+
|
|
14
|
+
var _Button = _interopRequireDefault(require("../../../../../common/Button"));
|
|
15
|
+
|
|
16
|
+
var _GroupList = _interopRequireDefault(require("../../../../../common/GroupList"));
|
|
17
|
+
|
|
18
|
+
var _defaultJSON = require("../../../components/GroupedImage/defaultJSON");
|
|
19
|
+
|
|
20
|
+
var _coreUtil = require("../../../../../utils/coreUtil");
|
|
21
|
+
|
|
22
|
+
var _locale = require("../../../../../locale");
|
|
23
|
+
|
|
24
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
25
|
+
|
|
26
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(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 __decorate = void 0 && (void 0).__decorate || function (decorators, target, key, desc) {
|
|
55
|
+
var c = arguments.length,
|
|
56
|
+
r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc,
|
|
57
|
+
d;
|
|
58
|
+
if ((typeof Reflect === "undefined" ? "undefined" : _typeof(Reflect)) === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) {
|
|
59
|
+
if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
60
|
+
}
|
|
61
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
62
|
+
};
|
|
63
|
+
|
|
64
|
+
var notice = '';
|
|
65
|
+
|
|
66
|
+
var GroupedImageConfigGroup =
|
|
67
|
+
/** @class */
|
|
68
|
+
function (_super) {
|
|
69
|
+
__extends(GroupedImageConfigGroup, _super);
|
|
70
|
+
|
|
71
|
+
function GroupedImageConfigGroup() {
|
|
72
|
+
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
73
|
+
|
|
74
|
+
_this.state = {};
|
|
75
|
+
|
|
76
|
+
_this.onClickItem = function (node) {
|
|
77
|
+
_this.props.store.setState({
|
|
78
|
+
clickedGroup: node.id
|
|
79
|
+
});
|
|
80
|
+
};
|
|
81
|
+
|
|
82
|
+
_this.onAddClick = function () {
|
|
83
|
+
var json = (0, _defaultJSON.groupedImageGroupSourceJSON)(_this.props.id, 'Group Name');
|
|
84
|
+
|
|
85
|
+
_this.props.source.push(json);
|
|
86
|
+
|
|
87
|
+
_this.setState({});
|
|
88
|
+
|
|
89
|
+
(0, _coreUtil.renderPreview)();
|
|
90
|
+
};
|
|
91
|
+
|
|
92
|
+
_this.reRender = function () {
|
|
93
|
+
_this.setState({});
|
|
94
|
+
};
|
|
95
|
+
|
|
96
|
+
return _this;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
GroupedImageConfigGroup.prototype.render = function () {
|
|
100
|
+
var source = this.props.source;
|
|
101
|
+
|
|
102
|
+
var _renderCard = function renderCard(src) {
|
|
103
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
104
|
+
className: "card_wrap"
|
|
105
|
+
}, /*#__PURE__*/_react["default"].createElement("img", {
|
|
106
|
+
alt: "",
|
|
107
|
+
src: ((0, _coreUtil.isPc)() ? src.image.content.pcImgSrc : src.image.content.h5ImgSrc) || _defaultImg["default"]
|
|
108
|
+
}), /*#__PURE__*/_react["default"].createElement("div", {
|
|
109
|
+
className: "name",
|
|
110
|
+
dangerouslySetInnerHTML: {
|
|
111
|
+
__html: src.groupName.text
|
|
112
|
+
}
|
|
113
|
+
}));
|
|
114
|
+
};
|
|
115
|
+
|
|
116
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
117
|
+
className: "group_wrap"
|
|
118
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
119
|
+
className: "node_list"
|
|
120
|
+
}, source.length === 0 ? /*#__PURE__*/_react["default"].createElement("span", {
|
|
121
|
+
className: "notice"
|
|
122
|
+
}, notice) : /*#__PURE__*/_react["default"].createElement(_GroupList["default"], {
|
|
123
|
+
onClickItem: this.onClickItem,
|
|
124
|
+
renderCard: function renderCard(v) {
|
|
125
|
+
return _renderCard(v);
|
|
126
|
+
},
|
|
127
|
+
reRender: this.reRender,
|
|
128
|
+
source: source
|
|
129
|
+
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
130
|
+
className: "btn_wrap"
|
|
131
|
+
}, /*#__PURE__*/_react["default"].createElement(_Button["default"], {
|
|
132
|
+
icon: "icon-add",
|
|
133
|
+
onClick: this.onAddClick,
|
|
134
|
+
type: "primary"
|
|
135
|
+
}, (0, _locale.i18n)('ADD_GROUP'))));
|
|
136
|
+
};
|
|
137
|
+
|
|
138
|
+
GroupedImageConfigGroup.defaultProps = {
|
|
139
|
+
source: []
|
|
140
|
+
};
|
|
141
|
+
GroupedImageConfigGroup = __decorate([(0, _mobxReact.inject)('store'), _mobxReact.observer], GroupedImageConfigGroup);
|
|
142
|
+
return GroupedImageConfigGroup;
|
|
143
|
+
}(_react["default"].Component);
|
|
144
|
+
|
|
145
|
+
var _default = GroupedImageConfigGroup;
|
|
146
|
+
exports["default"] = _default;
|
|
Binary file
|
|
@@ -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;
|