@fonixtree/magic-design 2.0.63 → 2.0.64
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/base64/index.js +28 -2
- package/es/common/ImagePicker/index.js +0 -2
- package/es/common/LinkModal/FunctionTable/index.js +2 -1
- package/es/common/LinkModal/index.js +14 -2
- package/es/common/MyModal/index.less +1 -1
- package/es/common/UrlPicker/index.js +3 -1
- package/es/composite-comp/bol/components/ImageText/pc/index.js +2 -2
- package/es/composite-comp/bol/second-config-panels/ImageTextSecondConfig/index.js +8 -6
- package/es/composite-comp/common/components/ImageLabel/index.less +10 -3
- package/es/composite-comp/common/components/ProductItem/index.js +25 -17
- package/es/composite-comp/common/components/ProductItem/index.less +13 -7
- package/es/composite-comp/dito/components/AffiliateRecommend/pc/index.js +6 -6
- package/es/composite-comp/dito/components/HeadNavigation/defaultJSON.js +76 -66
- package/es/composite-comp/dito/components/HeadNavigation/index.js +84 -0
- package/es/composite-comp/dito/components/HeadNavigation/mobile/index.js +112 -0
- package/es/composite-comp/dito/components/HeadNavigation/mobile/index.less +34 -0
- package/es/composite-comp/dito/components/MenuNavigation/MenuNavMetaImage/index.js +206 -0
- package/es/composite-comp/dito/components/MenuNavigation/MenuNavMetaImage/index.less +25 -0
- package/es/composite-comp/dito/components/MenuNavigation/defaultJSON.js +70 -42
- package/es/composite-comp/dito/components/MenuNavigation/index.js +84 -0
- package/es/composite-comp/dito/components/MenuNavigation/mobile/index.js +87 -0
- package/es/composite-comp/dito/components/MenuNavigation/mobile/index.less +8 -0
- package/es/composite-comp/dito/components/Recommend/mobile/index.js +4 -4
- package/es/composite-comp/dito/components/Recommend/pc/index.js +6 -6
- package/es/composite-comp/dito/config-panels/HeadNavigationConfig/GroupList/index.js +203 -0
- package/es/composite-comp/dito/config-panels/HeadNavigationConfig/GroupList/index.less +72 -0
- package/es/composite-comp/dito/config-panels/HeadNavigationConfig/HeadNavConfigImageGroup/index.js +142 -0
- package/es/composite-comp/dito/config-panels/HeadNavigationConfig/index.js +123 -0
- package/es/composite-comp/dito/config-panels/HeadNavigationConfig/index.less +23 -0
- package/es/composite-comp/dito/config-panels/MenuNavigationConfig/GroupList/index.js +203 -0
- package/es/composite-comp/dito/config-panels/MenuNavigationConfig/GroupList/index.less +72 -0
- package/es/composite-comp/dito/config-panels/MenuNavigationConfig/MenuNavConfigImageGroup/index.js +137 -0
- package/es/composite-comp/dito/config-panels/MenuNavigationConfig/MenuNavConfigImageGroup/index.less +6 -0
- package/es/composite-comp/dito/config-panels/MenuNavigationConfig/index.js +40 -0
- package/es/composite-comp/dito/second-config-panels/HeadNavigationSecondConfig/index.js +127 -0
- package/es/composite-comp/dito/second-config-panels/MenuNavigationSecondConfig/index.js +127 -0
- package/es/constants/component-types.js +15 -3
- package/es/constants/index.js +8 -0
- package/es/core/Designer/ChatRobot/components/SearchCondition/index.js +110 -0
- package/es/core/Designer/ChatRobot/components/SearchCondition/index.less +33 -0
- package/es/core/Designer/ChatRobot/index.js +23 -5
- package/es/core/Designer/ChatRobot/index.less +40 -20
- package/es/core/Designer/History/index.js +2 -2
- package/es/core/Designer/PageCompList/index.js +5 -3
- package/es/core/Designer/index.js +1 -0
- package/es/core/Renderer/index.js +3 -1
- package/es/decorator/compositeDecorator.js +23 -0
- package/es/locale/en/en.json +3 -0
- package/es/locale/es/es.json +3 -0
- package/es/locale/id/id.json +3 -0
- package/es/meta-comp/config-panels/ButtonConfig/index.js +5 -5
- package/es/meta-comp/config-panels/ImageConfig/index.js +4 -2
- package/es/utils/businessUtil.js +3 -3
- package/es/utils/commonUtil.js +2 -2
- package/lib/assets/images/base64/index.js +28 -2
- package/lib/common/ImagePicker/index.js +0 -2
- package/lib/common/LinkModal/FunctionTable/index.js +2 -1
- package/lib/common/LinkModal/index.js +14 -2
- package/lib/common/MyModal/index.less +1 -1
- package/lib/common/UrlPicker/index.js +3 -1
- package/lib/composite-comp/bol/components/ImageText/pc/index.js +2 -2
- package/lib/composite-comp/bol/second-config-panels/ImageTextSecondConfig/index.js +8 -6
- package/lib/composite-comp/common/components/ImageLabel/index.less +10 -3
- package/lib/composite-comp/common/components/ProductItem/index.js +25 -17
- package/lib/composite-comp/common/components/ProductItem/index.less +13 -7
- package/lib/composite-comp/dito/components/AffiliateRecommend/pc/index.js +6 -6
- package/lib/composite-comp/dito/components/HeadNavigation/defaultJSON.js +76 -66
- package/lib/composite-comp/dito/components/HeadNavigation/index.js +84 -0
- package/lib/composite-comp/dito/components/HeadNavigation/mobile/index.js +112 -0
- package/lib/composite-comp/dito/components/HeadNavigation/mobile/index.less +34 -0
- package/lib/composite-comp/dito/components/MenuNavigation/MenuNavMetaImage/index.js +206 -0
- package/lib/composite-comp/dito/components/MenuNavigation/MenuNavMetaImage/index.less +25 -0
- package/lib/composite-comp/dito/components/MenuNavigation/defaultJSON.js +70 -42
- package/lib/composite-comp/dito/components/MenuNavigation/index.js +84 -0
- package/lib/composite-comp/dito/components/MenuNavigation/mobile/index.js +87 -0
- package/lib/composite-comp/dito/components/MenuNavigation/mobile/index.less +8 -0
- package/lib/composite-comp/dito/components/Recommend/mobile/index.js +4 -4
- package/lib/composite-comp/dito/components/Recommend/pc/index.js +6 -6
- package/lib/composite-comp/dito/config-panels/HeadNavigationConfig/GroupList/index.js +203 -0
- package/lib/composite-comp/dito/config-panels/HeadNavigationConfig/GroupList/index.less +72 -0
- package/lib/composite-comp/dito/config-panels/HeadNavigationConfig/HeadNavConfigImageGroup/index.js +142 -0
- package/lib/composite-comp/dito/config-panels/HeadNavigationConfig/index.js +123 -0
- package/lib/composite-comp/dito/config-panels/HeadNavigationConfig/index.less +23 -0
- package/lib/composite-comp/dito/config-panels/MenuNavigationConfig/GroupList/index.js +203 -0
- package/lib/composite-comp/dito/config-panels/MenuNavigationConfig/GroupList/index.less +72 -0
- package/lib/composite-comp/dito/config-panels/MenuNavigationConfig/MenuNavConfigImageGroup/index.js +137 -0
- package/lib/composite-comp/dito/config-panels/MenuNavigationConfig/MenuNavConfigImageGroup/index.less +6 -0
- package/lib/composite-comp/dito/config-panels/MenuNavigationConfig/index.js +40 -0
- package/lib/composite-comp/dito/second-config-panels/HeadNavigationSecondConfig/index.js +127 -0
- package/lib/composite-comp/dito/second-config-panels/MenuNavigationSecondConfig/index.js +127 -0
- package/lib/constants/component-types.js +15 -3
- package/lib/constants/index.js +8 -0
- package/lib/core/Designer/ChatRobot/components/SearchCondition/index.js +110 -0
- package/lib/core/Designer/ChatRobot/components/SearchCondition/index.less +33 -0
- package/lib/core/Designer/ChatRobot/index.js +23 -5
- package/lib/core/Designer/ChatRobot/index.less +40 -20
- package/lib/core/Designer/History/index.js +2 -2
- package/lib/core/Designer/PageCompList/index.js +5 -3
- package/lib/core/Designer/index.js +1 -0
- package/lib/core/Renderer/index.js +3 -1
- package/lib/decorator/compositeDecorator.js +23 -0
- package/lib/locale/en/en.json +3 -0
- package/lib/locale/es/es.json +3 -0
- package/lib/locale/id/id.json +3 -0
- package/lib/meta-comp/config-panels/ButtonConfig/index.js +5 -5
- package/lib/meta-comp/config-panels/ImageConfig/index.js +4 -2
- package/lib/utils/businessUtil.js +3 -3
- package/lib/utils/commonUtil.js +2 -2
- package/package.json +1 -1
- package/es/assets/fonts/.DS_Store +0 -0
- package/lib/assets/fonts/.DS_Store +0 -0
|
@@ -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 _antd = require("antd");
|
|
11
|
+
|
|
12
|
+
var _locale = require("../../../../locale");
|
|
13
|
+
|
|
14
|
+
var _common = require("../../../../common");
|
|
15
|
+
|
|
16
|
+
var _ImageConfig = _interopRequireDefault(require("../../../../meta-comp/config-panels/ImageConfig"));
|
|
17
|
+
|
|
18
|
+
var _BaseConfig = _interopRequireDefault(require("../../../../meta-comp/config-panels/BaseConfig"));
|
|
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 WalletSecondConfig =
|
|
51
|
+
/** @class */
|
|
52
|
+
function (_super) {
|
|
53
|
+
__extends(WalletSecondConfig, _super);
|
|
54
|
+
|
|
55
|
+
function WalletSecondConfig() {
|
|
56
|
+
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
57
|
+
|
|
58
|
+
_this.state = {};
|
|
59
|
+
|
|
60
|
+
_this.reRender = function () {
|
|
61
|
+
(0, _coreUtil.renderPreview)();
|
|
62
|
+
|
|
63
|
+
_this.setState({});
|
|
64
|
+
};
|
|
65
|
+
|
|
66
|
+
_this.getContentPanel = function () {
|
|
67
|
+
var panelProps = _this.props.panelProps;
|
|
68
|
+
var defaultSource = [{
|
|
69
|
+
key: panelProps.image.id,
|
|
70
|
+
name: (0, _locale.i18n)('IMAGE'),
|
|
71
|
+
value: /*#__PURE__*/_react["default"].createElement(_ImageConfig["default"], {
|
|
72
|
+
data: panelProps.image,
|
|
73
|
+
needClickArea: false,
|
|
74
|
+
onlySpecificCode: "FunctionPage"
|
|
75
|
+
}),
|
|
76
|
+
metaOption: panelProps.image
|
|
77
|
+
}];
|
|
78
|
+
return /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement(_common.Field, {
|
|
79
|
+
title: (0, _locale.i18n)('NAME')
|
|
80
|
+
}, /*#__PURE__*/_react["default"].createElement(_antd.Input, {
|
|
81
|
+
className: "inputStyle",
|
|
82
|
+
onChange: function onChange(e) {
|
|
83
|
+
panelProps.type = e.target.value;
|
|
84
|
+
|
|
85
|
+
_this.setState({});
|
|
86
|
+
},
|
|
87
|
+
placeholder: (0, _locale.i18n)('PLEASE_INPUT'),
|
|
88
|
+
size: "middle",
|
|
89
|
+
value: panelProps.type
|
|
90
|
+
})), /*#__PURE__*/_react["default"].createElement(_common.Collapse, {
|
|
91
|
+
divider: "dashed",
|
|
92
|
+
headerSize: "middle",
|
|
93
|
+
onRefresh: function onRefresh() {
|
|
94
|
+
return (0, _coreUtil.renderPreview)();
|
|
95
|
+
},
|
|
96
|
+
showActiveColor: true,
|
|
97
|
+
source: defaultSource,
|
|
98
|
+
type: "switch"
|
|
99
|
+
}));
|
|
100
|
+
};
|
|
101
|
+
|
|
102
|
+
return _this;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
WalletSecondConfig.prototype.render = function () {
|
|
106
|
+
var panelProps = this.props.panelProps;
|
|
107
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
108
|
+
className: "Wallet_second_conf_wrap"
|
|
109
|
+
}, /*#__PURE__*/_react["default"].createElement(_common.Collapse, {
|
|
110
|
+
divider: "bold",
|
|
111
|
+
headerSize: "large",
|
|
112
|
+
source: [{
|
|
113
|
+
key: panelProps.id || 'walletNuriContent',
|
|
114
|
+
name: (0, _locale.i18n)('CONTENT'),
|
|
115
|
+
value: this.getContentPanel()
|
|
116
|
+
}]
|
|
117
|
+
}));
|
|
118
|
+
};
|
|
119
|
+
|
|
120
|
+
WalletSecondConfig.defaultProps = {
|
|
121
|
+
panelProps: {}
|
|
122
|
+
};
|
|
123
|
+
return WalletSecondConfig;
|
|
124
|
+
}(_BaseConfig["default"]);
|
|
125
|
+
|
|
126
|
+
var _default = WalletSecondConfig;
|
|
127
|
+
exports["default"] = _default;
|
|
@@ -47,6 +47,10 @@ var _MobileNavigation = _interopRequireDefault(require("../composite-comp/dito/c
|
|
|
47
47
|
|
|
48
48
|
var _PcNavigation = _interopRequireDefault(require("../composite-comp/dito/components/PcNavigation"));
|
|
49
49
|
|
|
50
|
+
var _MenuNavigation = _interopRequireDefault(require("../composite-comp/dito/components/MenuNavigation"));
|
|
51
|
+
|
|
52
|
+
var _HeadNavigation = _interopRequireDefault(require("../composite-comp/dito/components/HeadNavigation"));
|
|
53
|
+
|
|
50
54
|
var _BannerConfig = _interopRequireDefault(require("../composite-comp/bol/config-panels/BannerConfig"));
|
|
51
55
|
|
|
52
56
|
var _DividerConfig = _interopRequireDefault(require("../composite-comp/bol/config-panels/DividerConfig"));
|
|
@@ -89,6 +93,10 @@ var _MobileNavigationConfig = _interopRequireDefault(require("../composite-comp/
|
|
|
89
93
|
|
|
90
94
|
var _PcNavigationConfig = _interopRequireDefault(require("../composite-comp/dito/config-panels/PcNavigationConfig"));
|
|
91
95
|
|
|
96
|
+
var _MenuNavigationConfig = _interopRequireDefault(require("../composite-comp/dito/config-panels/MenuNavigationConfig"));
|
|
97
|
+
|
|
98
|
+
var _HeadNavigationConfig = _interopRequireDefault(require("../composite-comp/dito/config-panels/HeadNavigationConfig"));
|
|
99
|
+
|
|
92
100
|
var _BannerSecondConfig = _interopRequireDefault(require("../composite-comp/bol/second-config-panels/BannerSecondConfig"));
|
|
93
101
|
|
|
94
102
|
var _TextSecondConfig = _interopRequireDefault(require("../composite-comp/bol/second-config-panels/TextSecondConfig"));
|
|
@@ -117,6 +125,10 @@ var _MobileNavigationSecondConfig = _interopRequireDefault(require("../composite
|
|
|
117
125
|
|
|
118
126
|
var _PcNavigationSecondConfig = _interopRequireDefault(require("../composite-comp/dito/second-config-panels/PcNavigationSecondConfig"));
|
|
119
127
|
|
|
128
|
+
var _MenuNavigationSecondConfig = _interopRequireDefault(require("../composite-comp/dito/second-config-panels/MenuNavigationSecondConfig"));
|
|
129
|
+
|
|
130
|
+
var _HeadNavigationSecondConfig = _interopRequireDefault(require("../composite-comp/dito/second-config-panels/HeadNavigationSecondConfig"));
|
|
131
|
+
|
|
120
132
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
121
133
|
|
|
122
134
|
var _a, _b, _c; // 组件
|
|
@@ -125,17 +137,17 @@ var _a, _b, _c; // 组件
|
|
|
125
137
|
/**
|
|
126
138
|
* 渲染组件索引
|
|
127
139
|
*/
|
|
128
|
-
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[_SearchBar["default"].type] = _SearchBar["default"], _a[_SignBoard["default"].type] = _SignBoard["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);
|
|
140
|
+
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[_SearchBar["default"].type] = _SearchBar["default"], _a[_SignBoard["default"].type] = _SignBoard["default"], _a[_MenuNavigation["default"].type] = _MenuNavigation["default"], _a[_HeadNavigation["default"].type] = _HeadNavigation["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);
|
|
129
141
|
/**
|
|
130
142
|
* 一级配置面板索引
|
|
131
143
|
*/
|
|
132
144
|
|
|
133
145
|
exports.componentMap = componentMap;
|
|
134
|
-
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[_SearchBar["default"].type] = _SearchBarConfig["default"], _b[_SignBoard["default"].type] = _SignBoardConfig["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);
|
|
146
|
+
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[_SearchBar["default"].type] = _SearchBarConfig["default"], _b[_SignBoard["default"].type] = _SignBoardConfig["default"], _b[_MenuNavigation["default"].type] = _MenuNavigationConfig["default"], _b[_HeadNavigation["default"].type] = _HeadNavigationConfig["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);
|
|
135
147
|
/**
|
|
136
148
|
* 二级配置面板索引
|
|
137
149
|
*/
|
|
138
150
|
|
|
139
151
|
exports.configPanelMap = configPanelMap;
|
|
140
|
-
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[_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);
|
|
152
|
+
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[_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);
|
|
141
153
|
exports.secondConfigPanelMap = secondConfigPanelMap;
|
package/es/constants/index.js
CHANGED
|
@@ -185,6 +185,14 @@ var compInfoMap = {
|
|
|
185
185
|
WALLET_NURI: {
|
|
186
186
|
name: 'Wallet',
|
|
187
187
|
icon: 'icon-Wallet'
|
|
188
|
+
},
|
|
189
|
+
HEAD_NAVIGATION: {
|
|
190
|
+
name: 'Head Navigation',
|
|
191
|
+
icon: 'icon-header'
|
|
192
|
+
},
|
|
193
|
+
MENU_NAVIGATION: {
|
|
194
|
+
name: 'Menu Navigation',
|
|
195
|
+
icon: 'icon-footer'
|
|
188
196
|
}
|
|
189
197
|
};
|
|
190
198
|
/**
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
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); }
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports["default"] = SearchCondition;
|
|
9
|
+
|
|
10
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
11
|
+
|
|
12
|
+
var _antd = require("antd");
|
|
13
|
+
|
|
14
|
+
var _classnames = _interopRequireDefault(require("classnames"));
|
|
15
|
+
|
|
16
|
+
require("./index.less");
|
|
17
|
+
|
|
18
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
19
|
+
|
|
20
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
21
|
+
|
|
22
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
23
|
+
|
|
24
|
+
var toneList = ['Concise', 'Formal', 'Youthful', 'Innovative', 'Enticing'];
|
|
25
|
+
|
|
26
|
+
function SearchCondition() {
|
|
27
|
+
var _a = (0, _react.useState)('Concise'),
|
|
28
|
+
tone = _a[0],
|
|
29
|
+
setTone = _a[1];
|
|
30
|
+
|
|
31
|
+
var _b = (0, _react.useState)('30'),
|
|
32
|
+
count = _b[0],
|
|
33
|
+
setCount = _b[1];
|
|
34
|
+
|
|
35
|
+
var _c = (0, _react.useState)(''),
|
|
36
|
+
features = _c[0],
|
|
37
|
+
setFeatures = _c[1];
|
|
38
|
+
|
|
39
|
+
var _d = (0, _react.useState)(''),
|
|
40
|
+
key = _d[0],
|
|
41
|
+
setKey = _d[1];
|
|
42
|
+
|
|
43
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
44
|
+
className: "condition_wrap"
|
|
45
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
46
|
+
className: "cond_title"
|
|
47
|
+
}, "Detailed description"), /*#__PURE__*/_react["default"].createElement("div", {
|
|
48
|
+
className: "cond_item"
|
|
49
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
50
|
+
className: "item_label"
|
|
51
|
+
}, "Preferred tone of the description?"), /*#__PURE__*/_react["default"].createElement("div", {
|
|
52
|
+
className: "cond_value"
|
|
53
|
+
}, toneList.map(function (name) {
|
|
54
|
+
return /*#__PURE__*/_react["default"].createElement("span", {
|
|
55
|
+
className: (0, _classnames["default"])('tone_item', {
|
|
56
|
+
tone_active: tone === name
|
|
57
|
+
}),
|
|
58
|
+
onClick: function onClick() {
|
|
59
|
+
return setTone(name);
|
|
60
|
+
}
|
|
61
|
+
}, name);
|
|
62
|
+
}))), /*#__PURE__*/_react["default"].createElement("div", {
|
|
63
|
+
className: "cond_item"
|
|
64
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
65
|
+
className: "item_label"
|
|
66
|
+
}, "Desired word count range?"), /*#__PURE__*/_react["default"].createElement("div", {
|
|
67
|
+
className: "cond_value"
|
|
68
|
+
}, /*#__PURE__*/_react["default"].createElement(_antd.Select, {
|
|
69
|
+
allowClear: true,
|
|
70
|
+
defaultValue: "30",
|
|
71
|
+
onChange: function onChange(e) {
|
|
72
|
+
return setCount(e);
|
|
73
|
+
},
|
|
74
|
+
options: [{
|
|
75
|
+
value: '30',
|
|
76
|
+
label: '30'
|
|
77
|
+
}, {
|
|
78
|
+
value: '50',
|
|
79
|
+
label: '50'
|
|
80
|
+
}, {
|
|
81
|
+
value: '70',
|
|
82
|
+
label: '70'
|
|
83
|
+
}],
|
|
84
|
+
style: {
|
|
85
|
+
width: '100%'
|
|
86
|
+
}
|
|
87
|
+
}))), /*#__PURE__*/_react["default"].createElement("div", {
|
|
88
|
+
className: "cond_item"
|
|
89
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
90
|
+
className: "item_label"
|
|
91
|
+
}, "What are the key features?"), /*#__PURE__*/_react["default"].createElement("div", {
|
|
92
|
+
className: "cond_value"
|
|
93
|
+
}, /*#__PURE__*/_react["default"].createElement(_antd.Input, {
|
|
94
|
+
onChange: function onChange(e) {
|
|
95
|
+
return setFeatures(e.target.value);
|
|
96
|
+
},
|
|
97
|
+
value: features
|
|
98
|
+
}))), /*#__PURE__*/_react["default"].createElement("div", {
|
|
99
|
+
className: "cond_item"
|
|
100
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
101
|
+
className: "item_label"
|
|
102
|
+
}, "What key details should be emphasized?"), /*#__PURE__*/_react["default"].createElement("div", {
|
|
103
|
+
className: "cond_value"
|
|
104
|
+
}, /*#__PURE__*/_react["default"].createElement(_antd.Input, {
|
|
105
|
+
onChange: function onChange(e) {
|
|
106
|
+
return setKey(e.target.value);
|
|
107
|
+
},
|
|
108
|
+
value: key
|
|
109
|
+
}))));
|
|
110
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
.condition_wrap {
|
|
2
|
+
padding: 12px 12px 0 12px;
|
|
3
|
+
.cond_title {
|
|
4
|
+
font-family: Open Sans;
|
|
5
|
+
font-size: 16px;
|
|
6
|
+
font-weight: 700;
|
|
7
|
+
margin-bottom: 16px;
|
|
8
|
+
}
|
|
9
|
+
.cond_item {
|
|
10
|
+
margin-bottom: 16px;
|
|
11
|
+
.item_label {
|
|
12
|
+
font-family: Open Sans;
|
|
13
|
+
font-size: 14px;
|
|
14
|
+
font-weight: 600;
|
|
15
|
+
margin-bottom: 8px;
|
|
16
|
+
}
|
|
17
|
+
.cond_value {
|
|
18
|
+
.tone_item {
|
|
19
|
+
cursor: pointer;
|
|
20
|
+
margin-right: 8px;
|
|
21
|
+
padding: 7px 10px;
|
|
22
|
+
height: 32px;
|
|
23
|
+
border: 1px solid #D2D9E5;
|
|
24
|
+
border-radius: 100px;
|
|
25
|
+
}
|
|
26
|
+
.tone_active {
|
|
27
|
+
background-color: #E9F0FF;
|
|
28
|
+
color: #2F54EB;
|
|
29
|
+
border-color: #D6E4FF;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
}
|
|
@@ -15,6 +15,8 @@ var _classnames = _interopRequireDefault(require("classnames"));
|
|
|
15
15
|
|
|
16
16
|
var _CopyBtn = _interopRequireDefault(require("./components/CopyBtn"));
|
|
17
17
|
|
|
18
|
+
var _SearchCondition = _interopRequireDefault(require("./components/SearchCondition"));
|
|
19
|
+
|
|
18
20
|
var _common = require("../../../common");
|
|
19
21
|
|
|
20
22
|
var _FonixtreeGpt = _interopRequireDefault(require("../FonixtreeGpt"));
|
|
@@ -75,7 +77,8 @@ function (_super) {
|
|
|
75
77
|
context: [],
|
|
76
78
|
isGenerating: false,
|
|
77
79
|
aiImageVisible: false,
|
|
78
|
-
loading: true
|
|
80
|
+
loading: true,
|
|
81
|
+
showCondition: true
|
|
79
82
|
};
|
|
80
83
|
|
|
81
84
|
_this.scrollBottom = function () {
|
|
@@ -197,7 +200,8 @@ function (_super) {
|
|
|
197
200
|
open = _a.open,
|
|
198
201
|
isGenerating = _a.isGenerating,
|
|
199
202
|
aiImageVisible = _a.aiImageVisible,
|
|
200
|
-
loading = _a.loading
|
|
203
|
+
loading = _a.loading,
|
|
204
|
+
showCondition = _a.showCondition;
|
|
201
205
|
|
|
202
206
|
if (loading) {
|
|
203
207
|
return null;
|
|
@@ -238,6 +242,16 @@ function (_super) {
|
|
|
238
242
|
cursor: 'pointer'
|
|
239
243
|
},
|
|
240
244
|
type: "icon-image"
|
|
245
|
+
}), /*#__PURE__*/_react["default"].createElement(_common.Iconfont, {
|
|
246
|
+
className: "toggle_btn",
|
|
247
|
+
color: "#2F54EB",
|
|
248
|
+
onClick: function onClick() {
|
|
249
|
+
return _this.setState({
|
|
250
|
+
showCondition: !showCondition
|
|
251
|
+
});
|
|
252
|
+
},
|
|
253
|
+
size: 24,
|
|
254
|
+
type: showCondition ? 'icon-circle-down' : 'icon-circle-up'
|
|
241
255
|
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
242
256
|
className: (0, _classnames["default"])('generate_btn', {
|
|
243
257
|
disable_btn: message.length === 0
|
|
@@ -313,6 +327,8 @@ function (_super) {
|
|
|
313
327
|
}, /*#__PURE__*/_react["default"].createElement(_antd.Spin, {
|
|
314
328
|
spinning: true
|
|
315
329
|
}))), /*#__PURE__*/_react["default"].createElement("div", {
|
|
330
|
+
className: "regenerate_btn_wrap"
|
|
331
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
316
332
|
className: "regenerate_btn",
|
|
317
333
|
onClick: this.onRegenarate
|
|
318
334
|
}, /*#__PURE__*/_react["default"].createElement(_common.Iconfont, {
|
|
@@ -323,9 +339,11 @@ function (_super) {
|
|
|
323
339
|
marginRight: 5
|
|
324
340
|
},
|
|
325
341
|
type: "icon-refresh"
|
|
326
|
-
}), "Regenerate Response"), /*#__PURE__*/_react["default"].createElement("div", {
|
|
327
|
-
className: "more_condition
|
|
328
|
-
|
|
342
|
+
}), "Regenerate Response")), /*#__PURE__*/_react["default"].createElement("div", {
|
|
343
|
+
className: (0, _classnames["default"])('more_condition', {
|
|
344
|
+
more_condition_hide: !showCondition
|
|
345
|
+
})
|
|
346
|
+
}, /*#__PURE__*/_react["default"].createElement(_SearchCondition["default"], null)))), /*#__PURE__*/_react["default"].createElement(_AiImageGenerator["default"], {
|
|
329
347
|
onClose: function onClose() {
|
|
330
348
|
return _this.setState({
|
|
331
349
|
aiImageVisible: false
|
|
@@ -32,12 +32,15 @@
|
|
|
32
32
|
}
|
|
33
33
|
}
|
|
34
34
|
.chat_content_wrap {
|
|
35
|
+
display: flex;
|
|
36
|
+
flex-direction: column;
|
|
35
37
|
position: relative;
|
|
36
|
-
padding-bottom: 40px;
|
|
37
38
|
height: 100%;
|
|
38
39
|
.content_wrap {
|
|
40
|
+
background: #F5F6F7;
|
|
41
|
+
flex: 1;
|
|
39
42
|
padding: 16px;
|
|
40
|
-
height: 100%;
|
|
43
|
+
// height: 100%;
|
|
41
44
|
overflow: scroll;
|
|
42
45
|
font-family: 'Open Sans';
|
|
43
46
|
font-size: 14px;
|
|
@@ -78,16 +81,18 @@
|
|
|
78
81
|
display: flex;
|
|
79
82
|
justify-content: flex-end;
|
|
80
83
|
.messageWrap {
|
|
84
|
+
border: 1px solid #E6EAF0;
|
|
81
85
|
border-radius: 4px;
|
|
82
|
-
background: #
|
|
83
|
-
color: #
|
|
86
|
+
background: #FFF;
|
|
87
|
+
color: #232F46;
|
|
84
88
|
}
|
|
85
89
|
}
|
|
86
90
|
.assistantMessage {
|
|
87
91
|
.messageWrap {
|
|
88
92
|
border-radius: 4px;
|
|
89
|
-
background: #
|
|
90
|
-
color: #
|
|
93
|
+
background: #E9F0FF;
|
|
94
|
+
color: #2F54EB;
|
|
95
|
+
border: 1px solid #D6E4FF;
|
|
91
96
|
}
|
|
92
97
|
}
|
|
93
98
|
.recent_response {
|
|
@@ -101,21 +106,36 @@
|
|
|
101
106
|
}
|
|
102
107
|
}
|
|
103
108
|
}
|
|
104
|
-
|
|
109
|
+
|
|
110
|
+
.regenerate_btn_wrap {
|
|
111
|
+
background: #F5F6F7;
|
|
105
112
|
display: flex;
|
|
106
113
|
align-items: center;
|
|
107
|
-
|
|
108
|
-
bottom:
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
114
|
+
justify-content: center;
|
|
115
|
+
padding-bottom: 12px;
|
|
116
|
+
.regenerate_btn {
|
|
117
|
+
background-color: #FFF;
|
|
118
|
+
bottom: 10px;
|
|
119
|
+
border: 1px solid #E6EAF0;
|
|
120
|
+
border-radius: 4px;
|
|
121
|
+
padding: 4px 12px;
|
|
122
|
+
cursor: pointer;
|
|
123
|
+
font-family: 'Open Sans';
|
|
124
|
+
font-style: normal;
|
|
125
|
+
font-weight: 400;
|
|
126
|
+
font-size: 13px;
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
.more_condition {
|
|
131
|
+
transition: all 0.4s;
|
|
132
|
+
max-height: 400px;
|
|
133
|
+
overflow: hidden;
|
|
134
|
+
box-shadow: 3px 3px 8px 0px #2D304008;
|
|
135
|
+
box-shadow: -3px -3px 8px 0px #2D304008;
|
|
136
|
+
}
|
|
137
|
+
.more_condition_hide {
|
|
138
|
+
max-height: 0;
|
|
119
139
|
}
|
|
120
140
|
}
|
|
121
141
|
.dialog_bottom {
|
|
@@ -130,7 +150,7 @@
|
|
|
130
150
|
}
|
|
131
151
|
.image_btn {
|
|
132
152
|
position: absolute;
|
|
133
|
-
right:
|
|
153
|
+
right: 40px;
|
|
134
154
|
top: 6px;
|
|
135
155
|
}
|
|
136
156
|
.toggle_btn {
|
|
@@ -7,7 +7,7 @@ exports["default"] = void 0;
|
|
|
7
7
|
|
|
8
8
|
var _cloneDeep = _interopRequireDefault(require("lodash/cloneDeep"));
|
|
9
9
|
|
|
10
|
-
var
|
|
10
|
+
var _debounce = _interopRequireDefault(require("lodash/debounce"));
|
|
11
11
|
|
|
12
12
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
13
13
|
|
|
@@ -79,7 +79,7 @@ function () {
|
|
|
79
79
|
_this.doAction(callback);
|
|
80
80
|
};
|
|
81
81
|
|
|
82
|
-
this.doAction = (0,
|
|
82
|
+
this.doAction = (0, _debounce["default"])(function (callback) {
|
|
83
83
|
var newCursor = _this.cursor + _this.step;
|
|
84
84
|
_this.cursor = newCursor;
|
|
85
85
|
var newData = (0, _cloneDeep["default"])(_this.list[newCursor]);
|
|
@@ -15,7 +15,9 @@ var _immutabilityHelper = _interopRequireDefault(require("immutability-helper"))
|
|
|
15
15
|
|
|
16
16
|
var _react = _interopRequireWildcard(require("react"));
|
|
17
17
|
|
|
18
|
-
var
|
|
18
|
+
var _findIndex = _interopRequireDefault(require("lodash/findIndex"));
|
|
19
|
+
|
|
20
|
+
var _findLastIndex = _interopRequireDefault(require("lodash/findLastIndex"));
|
|
19
21
|
|
|
20
22
|
var _common = require("../../../common");
|
|
21
23
|
|
|
@@ -139,7 +141,7 @@ function PageCompList(_a) {
|
|
|
139
141
|
|
|
140
142
|
var getLastSameIndex = function getLastSameIndex(comps, index) {
|
|
141
143
|
var lastComps = comps.slice(0, index);
|
|
142
|
-
var newIndex = (0,
|
|
144
|
+
var newIndex = (0, _findLastIndex["default"])(lastComps, function (comp) {
|
|
143
145
|
return (0, _coreUtil.isActiveFloor)(comp.activeTerminal);
|
|
144
146
|
});
|
|
145
147
|
return newIndex;
|
|
@@ -147,7 +149,7 @@ function PageCompList(_a) {
|
|
|
147
149
|
|
|
148
150
|
var getNextSameIndex = function getNextSameIndex(comps, index) {
|
|
149
151
|
var nextComps = comps.slice(index + 1);
|
|
150
|
-
var newIndex = (0,
|
|
152
|
+
var newIndex = (0, _findIndex["default"])(nextComps, function (comp) {
|
|
151
153
|
return (0, _coreUtil.isActiveFloor)(comp.activeTerminal);
|
|
152
154
|
});
|
|
153
155
|
return newIndex + index + 1;
|
|
@@ -263,6 +263,7 @@ window.magicDesign = {
|
|
|
263
263
|
|
|
264
264
|
var setDesignConfig = function setDesignConfig(data) {
|
|
265
265
|
window.magicDesign = __assign(__assign(__assign({}, window.magicDesign), data), {
|
|
266
|
+
designMode: true,
|
|
266
267
|
compWidth: Number(data.compWidth),
|
|
267
268
|
compSpacing: Number(data.compSpacing),
|
|
268
269
|
MBaseUrl: data.MBaseUrl || 'operation/v1',
|
|
@@ -43,11 +43,13 @@ var __assign = void 0 && (void 0).__assign || function () {
|
|
|
43
43
|
|
|
44
44
|
var setDesignConfig = function setDesignConfig(props) {
|
|
45
45
|
var config = props.config,
|
|
46
|
-
device = props.device
|
|
46
|
+
device = props.device,
|
|
47
|
+
isPreview = props.isPreview;
|
|
47
48
|
window.magicDesign = __assign(__assign({
|
|
48
49
|
pageBackground: '#f2f2f2',
|
|
49
50
|
mode: 'renderer',
|
|
50
51
|
device: device,
|
|
52
|
+
designMode: isPreview,
|
|
51
53
|
navigatePreUrl: ''
|
|
52
54
|
}, config), {
|
|
53
55
|
compSpacing: Number(config.compSpacing),
|
|
@@ -153,6 +153,19 @@ function compositeDecorator(WrappedComponent) {
|
|
|
153
153
|
|
|
154
154
|
if (device === _constants.deviceTypeMap.PC && compWidth && !((_a = spacing === null || spacing === void 0 ? void 0 : spacing.pc) === null || _a === void 0 ? void 0 : _a.fillUp)) {
|
|
155
155
|
wrapStyle.width = compWidth;
|
|
156
|
+
} // 如果是菜单 则需要设为fixed
|
|
157
|
+
|
|
158
|
+
|
|
159
|
+
if (nodeData.type === 'HEAD_NAVIGATION' || nodeData.type === 'MENU_NAVIGATION') {
|
|
160
|
+
wrapStyle.position = 'absolute';
|
|
161
|
+
wrapStyle.left = 0;
|
|
162
|
+
wrapStyle.width = '100%';
|
|
163
|
+
|
|
164
|
+
if (nodeData.type === 'HEAD_NAVIGATION') {
|
|
165
|
+
wrapStyle.top = 0;
|
|
166
|
+
} else {
|
|
167
|
+
wrapStyle.bottom = 0;
|
|
168
|
+
}
|
|
156
169
|
}
|
|
157
170
|
|
|
158
171
|
return wrapStyle;
|
|
@@ -228,6 +241,15 @@ function compositeDecorator(WrappedComponent) {
|
|
|
228
241
|
});
|
|
229
242
|
};
|
|
230
243
|
|
|
244
|
+
_this.getOuterWrapStyle = function () {
|
|
245
|
+
var nodeData = _this.props.nodeData;
|
|
246
|
+
|
|
247
|
+
if (window.magicDesign.designMode && (nodeData.type === 'HEAD_NAVIGATION' || nodeData.type === 'MENU_NAVIGATION')) {
|
|
248
|
+
var element = document.querySelector('.phone_view_area .device_border') || document.querySelector('#root .render_wrap');
|
|
249
|
+
element.style.position = 'relative';
|
|
250
|
+
}
|
|
251
|
+
};
|
|
252
|
+
|
|
231
253
|
return _this;
|
|
232
254
|
}
|
|
233
255
|
|
|
@@ -240,6 +262,7 @@ function compositeDecorator(WrappedComponent) {
|
|
|
240
262
|
hoveredFloor: _mobx.store.hoveredFloor
|
|
241
263
|
});
|
|
242
264
|
});
|
|
265
|
+
this.getOuterWrapStyle();
|
|
243
266
|
};
|
|
244
267
|
|
|
245
268
|
Wrapper.prototype.componentWillUnmount = function () {
|
package/es/locale/en/en.json
CHANGED
package/es/locale/es/es.json
CHANGED