@luck-design-biz/luckda 1.0.1 → 1.0.2
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/components/LDActions/index.less +3 -1
- package/es/components/LdAutoForm/index.js +2 -1
- package/es/components/LdCard/index.js +154 -67
- package/es/components/LdFormList/index.js +20 -6
- package/es/components/LdGridForm/index.js +40 -24
- package/es/components/LdTree/index.js +14 -8
- package/es/components/LdTree/index.less +4 -2
- package/es/helper/ldBuilder.js +1 -1
- package/es/locales/zh-CN.js +13 -4
- package/es/lowcode/constants/index.js +1 -1
- package/es/lowcode/engine/meta/cardlist.props.default.json +27 -6
- package/es/lowcode/engine/meta/cardlist.props.json +254 -72
- package/es/lowcode/engine/meta/components-list.json +6 -102
- package/es/lowcode/engine/meta/dialog.props.default.json +4 -2
- package/es/lowcode/engine/meta/dialog.props.json +74 -18
- package/es/lowcode/engine/meta/drawer.props.default.json +15 -4
- package/es/lowcode/engine/meta/drawer.props.json +144 -24
- package/es/lowcode/engine/meta/form.props.default.json +14 -3
- package/es/lowcode/engine/meta/form.props.json +49 -9
- package/es/lowcode/engine/meta/grouptree.props.default.json +16 -0
- package/es/lowcode/engine/meta/grouptree.props.json +83 -0
- package/es/lowcode/engine/meta/iframe.props.default.json +1 -1
- package/es/lowcode/engine/meta/iframe.props.json +3 -4
- package/es/lowcode/engine/meta/image.props.default.json +3 -2
- package/es/lowcode/engine/meta/image.props.json +51 -16
- package/es/lowcode/engine/meta/imex.props.json +1 -1
- package/es/lowcode/engine/meta/js-editor/auto-complete.json +23 -5
- package/es/lowcode/engine/meta/link.props.default.json +1 -1
- package/es/lowcode/engine/meta/link.props.json +9 -9
- package/es/lowcode/engine/meta/table.props.json +1 -1
- package/es/lowcode/engine/meta/tabs.props.default.json +1 -1
- package/es/lowcode/engine/meta/tabs.props.json +1 -1
- package/es/lowcode/engine/meta/tree.props.json +2 -2
- package/es/lowcode/engine/provider/ContextProvider/index.js +6 -2
- package/es/lowcode/engine/provider/ContextProvider/usePageDataStore.js +82 -2
- package/es/lowcode/engine/tools/helper.js +21 -0
- package/es/lowcode/engine/tools/useCanvasRender.js +13 -1
- package/es/lowcode/painter/Components.js +6 -1
- package/es/lowcode/painter/Design.js +1 -0
- package/es/lowcode/painter/DesignOperator.js +25 -15
- package/es/lowcode/painter/DesignToolbar.js +78 -47
- package/es/lowcode/painter/Ribbon.js +14 -1
- package/es/lowcode/painter/components/ActionBindModal.js +3 -7
- package/es/lowcode/painter/components/DragDrop/DragDropContext.js +144 -37
- package/es/lowcode/painter/components/DragDrop/DragDropWrapper.js +29 -6
- package/es/lowcode/painter/components/DragDrop/Overlay.js +5 -2
- package/es/lowcode/painter/components/DragDrop/TreeDragDropWrapper.js +7 -4
- package/es/lowcode/painter/components/NumberInput.js +1 -1
- package/es/lowcode/painter/components/code-editor/BaseEditor.js +2 -1
- package/es/lowcode/painter/components/field-setting/FieldAttrs.js +2 -2
- package/es/lowcode/painter/components/field-setting/SettingUI.js +30 -2
- package/es/lowcode/painter/components/field-setting/index.js +26 -12
- package/es/lowcode/painter/expect.js +27 -0
- package/es/lowcode/painter/panel-section/ActionsEditor/ActionEditor.js +20 -2
- package/es/lowcode/painter/panel-section/ActionsEditor/index.js +18 -3
- package/es/lowcode/painter/panel-section/ComplexPop.js +1 -1
- package/es/lowcode/painter/panel-section/DataSetSelector.js +14 -3
- package/es/lowcode/painter/panel-section/FieldsSetting.js +2 -2
- package/es/lowcode/painter/panel-section/GroupClassSelector.js +55 -0
- package/es/lowcode/painter/panel-section/PageVars.js +1 -1
- package/es/lowcode/painter/panel-section/StylePanel/MainPanel.js +1 -0
- package/es/lowcode/painter/panel-section/TabItems.js +1 -1
- package/es/lowcode/painter/panel-section/TableTopFilter.js +3 -3
- package/es/lowcode/painter/style/action-bind-modal.less +5 -3
- package/es/lowcode/painter/style/design.less +26 -7
- package/es/lowcode/painter/style/dragdrop.less +46 -0
- package/es/lowcode/painter/style/list-editor.less +5 -3
- package/es/lowcode/painter/style/number-input.less +3 -1
- package/es/lowcode/painter/style/outline.less +3 -1
- package/es/lowcode/painter/style/panel-attrs.less +7 -3
- package/es/lowcode/painter/style/panel.less +9 -7
- package/es/lowcode/painter/style/radio.less +1 -1
- package/es/lowcode/painter/style/ribbon.less +4 -2
- package/es/lowcode/painter/svg/code.svg +3 -0
- package/es/lowcode/painter/svg/expect.svg +9 -0
- package/es/lowcode/view/lc-components/CardList/index.js +481 -12
- package/es/lowcode/view/lc-components/CardList/meta.json +255 -73
- package/es/lowcode/view/lc-components/Dialog/FunctionDesign.js +14 -6
- package/es/lowcode/view/lc-components/Dialog/index.js +15 -5
- package/es/lowcode/view/lc-components/Dialog/index.less +4 -0
- package/es/lowcode/view/lc-components/Dialog/meta.json +72 -18
- package/es/lowcode/view/lc-components/Drawer/FunctionDesign.js +51 -8
- package/es/lowcode/view/lc-components/Drawer/index.js +139 -24
- package/es/lowcode/view/lc-components/Drawer/index.less +11 -8
- package/es/lowcode/view/lc-components/Drawer/meta.json +136 -25
- package/es/lowcode/view/lc-components/Form/FunctionDesign.js +2 -1
- package/es/lowcode/view/lc-components/Form/index.js +45 -28
- package/es/lowcode/view/lc-components/Form/meta.json +44 -8
- package/es/lowcode/view/lc-components/GroupTree/FunctionDesign.js +10 -0
- package/es/lowcode/view/lc-components/GroupTree/FunctionLive.js +10 -0
- package/es/lowcode/view/lc-components/GroupTree/FunctionPreview.js +10 -0
- package/es/lowcode/view/lc-components/GroupTree/index.js +212 -0
- package/es/lowcode/view/lc-components/GroupTree/index.less +12 -0
- package/es/lowcode/view/lc-components/GroupTree/meta.json +83 -0
- package/es/lowcode/view/lc-components/Iframe/index.js +57 -7
- package/es/lowcode/view/lc-components/Iframe/meta.json +3 -4
- package/es/lowcode/view/lc-components/ImEx/meta.json +1 -1
- package/es/lowcode/view/lc-components/Image/index.js +82 -6
- package/es/lowcode/view/lc-components/Image/index.less +27 -0
- package/es/lowcode/view/lc-components/Image/meta.json +51 -16
- package/es/lowcode/view/lc-components/Link/index.js +53 -5
- package/es/lowcode/view/lc-components/Link/index.less +15 -0
- package/es/lowcode/view/lc-components/Link/meta.json +9 -9
- package/es/lowcode/view/lc-components/Table/index.js +5 -6
- package/es/lowcode/view/lc-components/Table/meta.json +1 -1
- package/es/lowcode/view/lc-components/Tabs/FunctionDesign.js +40 -4
- package/es/lowcode/view/lc-components/Tabs/index.js +1 -1
- package/es/lowcode/view/lc-components/Tabs/meta.json +1 -1
- package/es/lowcode/view/lc-components/Tree/index.js +21 -19
- package/es/lowcode/view/lc-components/Tree/meta.json +2 -2
- package/es/utils/grid.js +3 -3
- package/lib/components/LDActions/index.less +3 -1
- package/lib/components/LdAutoForm/index.js +2 -1
- package/lib/components/LdCard/index.js +153 -66
- package/lib/components/LdFormList/index.js +19 -5
- package/lib/components/LdGridForm/index.js +40 -24
- package/lib/components/LdTree/index.js +14 -8
- package/lib/components/LdTree/index.less +4 -2
- package/lib/helper/ldBuilder.js +2 -2
- package/lib/locales/zh-CN.js +13 -4
- package/lib/lowcode/constants/index.js +1 -1
- package/lib/lowcode/engine/meta/cardlist.props.default.json +27 -6
- package/lib/lowcode/engine/meta/cardlist.props.json +254 -72
- package/lib/lowcode/engine/meta/components-list.json +6 -102
- package/lib/lowcode/engine/meta/dialog.props.default.json +4 -2
- package/lib/lowcode/engine/meta/dialog.props.json +74 -18
- package/lib/lowcode/engine/meta/drawer.props.default.json +15 -4
- package/lib/lowcode/engine/meta/drawer.props.json +144 -24
- package/lib/lowcode/engine/meta/form.props.default.json +14 -3
- package/lib/lowcode/engine/meta/form.props.json +49 -9
- package/lib/lowcode/engine/meta/grouptree.props.default.json +16 -0
- package/lib/lowcode/engine/meta/grouptree.props.json +83 -0
- package/lib/lowcode/engine/meta/iframe.props.default.json +1 -1
- package/lib/lowcode/engine/meta/iframe.props.json +3 -4
- package/lib/lowcode/engine/meta/image.props.default.json +3 -2
- package/lib/lowcode/engine/meta/image.props.json +51 -16
- package/lib/lowcode/engine/meta/imex.props.json +1 -1
- package/lib/lowcode/engine/meta/js-editor/auto-complete.json +23 -5
- package/lib/lowcode/engine/meta/link.props.default.json +1 -1
- package/lib/lowcode/engine/meta/link.props.json +9 -9
- package/lib/lowcode/engine/meta/table.props.json +1 -1
- package/lib/lowcode/engine/meta/tabs.props.default.json +1 -1
- package/lib/lowcode/engine/meta/tabs.props.json +1 -1
- package/lib/lowcode/engine/meta/tree.props.json +2 -2
- package/lib/lowcode/engine/provider/ContextProvider/index.js +6 -2
- package/lib/lowcode/engine/provider/ContextProvider/usePageDataStore.js +83 -3
- package/lib/lowcode/engine/tools/helper.js +22 -0
- package/lib/lowcode/engine/tools/useCanvasRender.js +13 -1
- package/lib/lowcode/painter/Components.js +6 -1
- package/lib/lowcode/painter/Design.js +1 -0
- package/lib/lowcode/painter/DesignOperator.js +25 -15
- package/lib/lowcode/painter/DesignToolbar.js +78 -47
- package/lib/lowcode/painter/Ribbon.js +14 -1
- package/lib/lowcode/painter/components/ActionBindModal.js +3 -7
- package/lib/lowcode/painter/components/DragDrop/DragDropContext.js +142 -35
- package/lib/lowcode/painter/components/DragDrop/DragDropWrapper.js +27 -4
- package/lib/lowcode/painter/components/DragDrop/Overlay.js +5 -2
- package/lib/lowcode/painter/components/DragDrop/TreeDragDropWrapper.js +7 -4
- package/lib/lowcode/painter/components/NumberInput.js +1 -1
- package/lib/lowcode/painter/components/code-editor/BaseEditor.js +2 -1
- package/lib/lowcode/painter/components/field-setting/FieldAttrs.js +2 -2
- package/lib/lowcode/painter/components/field-setting/SettingUI.js +29 -1
- package/lib/lowcode/painter/components/field-setting/index.js +26 -12
- package/lib/lowcode/painter/expect.js +34 -0
- package/lib/lowcode/painter/panel-section/ActionsEditor/ActionEditor.js +19 -1
- package/lib/lowcode/painter/panel-section/ActionsEditor/index.js +18 -3
- package/lib/lowcode/painter/panel-section/ComplexPop.js +1 -1
- package/lib/lowcode/painter/panel-section/DataSetSelector.js +14 -3
- package/lib/lowcode/painter/panel-section/FieldsSetting.js +2 -2
- package/lib/lowcode/painter/panel-section/GroupClassSelector.js +63 -0
- package/lib/lowcode/painter/panel-section/PageVars.js +1 -1
- package/lib/lowcode/painter/panel-section/StylePanel/MainPanel.js +1 -0
- package/lib/lowcode/painter/panel-section/TabItems.js +1 -1
- package/lib/lowcode/painter/panel-section/TableTopFilter.js +3 -3
- package/lib/lowcode/painter/style/action-bind-modal.less +5 -3
- package/lib/lowcode/painter/style/design.less +26 -7
- package/lib/lowcode/painter/style/dragdrop.less +46 -0
- package/lib/lowcode/painter/style/list-editor.less +5 -3
- package/lib/lowcode/painter/style/number-input.less +3 -1
- package/lib/lowcode/painter/style/outline.less +3 -1
- package/lib/lowcode/painter/style/panel-attrs.less +7 -3
- package/lib/lowcode/painter/style/panel.less +9 -7
- package/lib/lowcode/painter/style/radio.less +1 -1
- package/lib/lowcode/painter/style/ribbon.less +4 -2
- package/lib/lowcode/painter/svg/code.svg +3 -0
- package/lib/lowcode/painter/svg/expect.svg +9 -0
- package/lib/lowcode/view/lc-components/CardList/index.js +480 -11
- package/lib/lowcode/view/lc-components/CardList/meta.json +255 -73
- package/lib/lowcode/view/lc-components/Dialog/FunctionDesign.js +13 -5
- package/lib/lowcode/view/lc-components/Dialog/index.js +15 -5
- package/lib/lowcode/view/lc-components/Dialog/index.less +4 -0
- package/lib/lowcode/view/lc-components/Dialog/meta.json +72 -18
- package/lib/lowcode/view/lc-components/Drawer/FunctionDesign.js +52 -8
- package/lib/lowcode/view/lc-components/Drawer/index.js +138 -23
- package/lib/lowcode/view/lc-components/Drawer/index.less +11 -8
- package/lib/lowcode/view/lc-components/Drawer/meta.json +136 -25
- package/lib/lowcode/view/lc-components/Form/FunctionDesign.js +2 -1
- package/lib/lowcode/view/lc-components/Form/index.js +44 -27
- package/lib/lowcode/view/lc-components/Form/meta.json +44 -8
- package/lib/lowcode/view/lc-components/GroupTree/FunctionDesign.js +17 -0
- package/lib/lowcode/view/lc-components/GroupTree/FunctionLive.js +17 -0
- package/lib/lowcode/view/lc-components/GroupTree/FunctionPreview.js +17 -0
- package/lib/lowcode/view/lc-components/GroupTree/index.js +220 -0
- package/lib/lowcode/view/lc-components/GroupTree/index.less +12 -0
- package/lib/lowcode/view/lc-components/GroupTree/meta.json +83 -0
- package/lib/lowcode/view/lc-components/Iframe/index.js +55 -5
- package/lib/lowcode/view/lc-components/Iframe/meta.json +3 -4
- package/lib/lowcode/view/lc-components/ImEx/meta.json +1 -1
- package/lib/lowcode/view/lc-components/Image/index.js +80 -4
- package/lib/lowcode/view/lc-components/Image/index.less +27 -0
- package/lib/lowcode/view/lc-components/Image/meta.json +51 -16
- package/lib/lowcode/view/lc-components/Link/index.js +52 -4
- package/lib/lowcode/view/lc-components/Link/index.less +15 -0
- package/lib/lowcode/view/lc-components/Link/meta.json +9 -9
- package/lib/lowcode/view/lc-components/Table/index.js +5 -6
- package/lib/lowcode/view/lc-components/Table/meta.json +1 -1
- package/lib/lowcode/view/lc-components/Tabs/FunctionDesign.js +38 -2
- package/lib/lowcode/view/lc-components/Tabs/index.js +1 -1
- package/lib/lowcode/view/lc-components/Tabs/meta.json +1 -1
- package/lib/lowcode/view/lc-components/Tree/index.js +20 -18
- package/lib/lowcode/view/lc-components/Tree/meta.json +2 -2
- package/lib/utils/grid.js +2 -2
- package/package.json +10 -9
- package/es/lowcode/painter/style/treedragdrop.less +0 -19
- package/es/lowcode/view/lc-components/Form/index.less +0 -5
- package/lib/lowcode/painter/style/treedragdrop.less +0 -19
- package/lib/lowcode/view/lc-components/Form/index.less +0 -5
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"props": [
|
|
10
10
|
{
|
|
11
11
|
"key": "id",
|
|
12
|
-
"
|
|
12
|
+
"name": "唯一标识",
|
|
13
13
|
"type": "string",
|
|
14
14
|
"disabled": true
|
|
15
15
|
},
|
|
@@ -23,10 +23,9 @@
|
|
|
23
23
|
"key": "supportFullScreen",
|
|
24
24
|
"name": "支持全屏",
|
|
25
25
|
"desc": "是否支持全屏展示",
|
|
26
|
-
"type": "
|
|
26
|
+
"type": "switch",
|
|
27
27
|
"default": true
|
|
28
28
|
}
|
|
29
29
|
],
|
|
30
|
-
"css": ""
|
|
31
|
-
"advance": {}
|
|
30
|
+
"css": "background: white; width: 100%; height: 100%"
|
|
32
31
|
}
|
|
@@ -6,15 +6,66 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
8
|
exports.default = void 0;
|
|
9
|
+
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
10
|
+
var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
|
|
9
11
|
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
|
|
10
12
|
var _react = _interopRequireWildcard(require("react"));
|
|
11
13
|
var _ahooks = require("ahooks");
|
|
14
|
+
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
15
|
+
var _luckDesign = require("luck-design");
|
|
12
16
|
var _Wrapper = _interopRequireDefault(require("../Wrapper"));
|
|
13
|
-
var
|
|
17
|
+
var _index = _interopRequireDefault(require("./index.less"));
|
|
18
|
+
var _antd = require("luck-design/antd");
|
|
19
|
+
var _ContextProvider = require("../../../engine/provider/ContextProvider");
|
|
20
|
+
var _excluded = ["id", "src", "css", "advance", "onClick"];
|
|
21
|
+
var StyledImage = _styledComponents.default.img.withConfig({
|
|
22
|
+
displayName: "StyledImage",
|
|
23
|
+
componentId: "luckda-6530__sc-k6wbym-0"
|
|
24
|
+
})(["width:", ";height:", ";object-fit:", ";cursor:", ";border-radius:", ";", ""], function (props) {
|
|
25
|
+
return props.autoWidth ? 'auto' : "".concat(props.width, "px");
|
|
26
|
+
}, function (props) {
|
|
27
|
+
return props.autoHeight ? 'auto' : "".concat(props.height, "px");
|
|
28
|
+
}, function (props) {
|
|
29
|
+
return props.fit;
|
|
30
|
+
}, function (props) {
|
|
31
|
+
return props.preview && 'pointer';
|
|
32
|
+
}, function (props) {
|
|
33
|
+
return props.roundRadios || "".concat(props.borderRadios, "px");
|
|
34
|
+
}, function (props) {
|
|
35
|
+
return props.$css;
|
|
36
|
+
});
|
|
14
37
|
var LCImage = function LCImage(_ref) {
|
|
15
38
|
var id = _ref.id,
|
|
39
|
+
src = _ref.src,
|
|
40
|
+
css = _ref.css,
|
|
41
|
+
advance = _ref.advance,
|
|
42
|
+
onClick = _ref.onClick,
|
|
16
43
|
props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
|
|
17
44
|
var ref = (0, _react.useRef)();
|
|
45
|
+
var isHovering = (0, _ahooks.useHover)(ref);
|
|
46
|
+
var _useSetState = (0, _ahooks.useSetState)({
|
|
47
|
+
visible: false,
|
|
48
|
+
images: []
|
|
49
|
+
}),
|
|
50
|
+
_useSetState2 = (0, _slicedToArray2.default)(_useSetState, 2),
|
|
51
|
+
state = _useSetState2[0],
|
|
52
|
+
setState = _useSetState2[1];
|
|
53
|
+
var ctx = (0, _ContextProvider.useContext)();
|
|
54
|
+
(0, _react.useEffect)(function () {
|
|
55
|
+
ctx.doAction(advance.events.onMount);
|
|
56
|
+
return function () {
|
|
57
|
+
return ctx.doAction(advance.events.onUnmount);
|
|
58
|
+
};
|
|
59
|
+
}, []);
|
|
60
|
+
var handleClick = (0, _ahooks.useMemoizedFn)(function (e) {
|
|
61
|
+
if (onClick) {
|
|
62
|
+
onClick(e);
|
|
63
|
+
return;
|
|
64
|
+
}
|
|
65
|
+
ctx.doAction(advance.events.onClick, {
|
|
66
|
+
e: e
|
|
67
|
+
});
|
|
68
|
+
});
|
|
18
69
|
var getTargetDom = (0, _ahooks.useMemoizedFn)(function () {
|
|
19
70
|
return ref.current;
|
|
20
71
|
});
|
|
@@ -22,8 +73,33 @@ var LCImage = function LCImage(_ref) {
|
|
|
22
73
|
id: id,
|
|
23
74
|
displayName: "Image",
|
|
24
75
|
getTargetDom: getTargetDom
|
|
25
|
-
}, /*#__PURE__*/_react.default.createElement("div", {
|
|
26
|
-
|
|
27
|
-
|
|
76
|
+
}, /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement("div", {
|
|
77
|
+
className: props.preview && _index.default['lc-component-image'],
|
|
78
|
+
ref: ref,
|
|
79
|
+
onClick: props.preview ? function () {
|
|
80
|
+
return setState({
|
|
81
|
+
visible: true,
|
|
82
|
+
images: [{
|
|
83
|
+
src: src
|
|
84
|
+
}]
|
|
85
|
+
});
|
|
86
|
+
} : {}
|
|
87
|
+
}, /*#__PURE__*/_react.default.createElement(StyledImage, (0, _extends2.default)({
|
|
88
|
+
src: src,
|
|
89
|
+
$css: css
|
|
90
|
+
}, props)), props.preview && isHovering && /*#__PURE__*/_react.default.createElement(_antd.Icon, {
|
|
91
|
+
type: "search",
|
|
92
|
+
className: _index.default.search
|
|
93
|
+
})), /*#__PURE__*/_react.default.createElement(_luckDesign.ImgPreview, {
|
|
94
|
+
visible: state.visible,
|
|
95
|
+
images: state.images,
|
|
96
|
+
activeIndex: 0,
|
|
97
|
+
onClose: function onClose() {
|
|
98
|
+
return setState({
|
|
99
|
+
visible: false
|
|
100
|
+
});
|
|
101
|
+
},
|
|
102
|
+
onClick: handleClick
|
|
103
|
+
})));
|
|
28
104
|
};
|
|
29
105
|
var _default = exports.default = LCImage;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
.lc-component-image {
|
|
2
|
+
position: relative;
|
|
3
|
+
width: fit-content;
|
|
4
|
+
cursor: pointer;
|
|
5
|
+
|
|
6
|
+
.search {
|
|
7
|
+
position: absolute;
|
|
8
|
+
left: 50%;
|
|
9
|
+
top: 50%;
|
|
10
|
+
transform: translate(-50%, -50%);
|
|
11
|
+
color: white;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
&:hover {
|
|
15
|
+
&::before {
|
|
16
|
+
content: '';
|
|
17
|
+
position: absolute;
|
|
18
|
+
left: 50%;
|
|
19
|
+
top: 50%;
|
|
20
|
+
margin: -16px 0 0 -16px;
|
|
21
|
+
width: 32px;
|
|
22
|
+
height: 32px;
|
|
23
|
+
background-color: rgba(51, 51, 51, 0.6);
|
|
24
|
+
border-radius: 16px 16px;
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
}
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"props": [
|
|
10
10
|
{
|
|
11
11
|
"key": "id",
|
|
12
|
-
"
|
|
12
|
+
"name": "唯一标识",
|
|
13
13
|
"type": "string",
|
|
14
14
|
"disabled": true
|
|
15
15
|
},
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
"key": "src",
|
|
18
18
|
"name": "图片地址",
|
|
19
19
|
"desc": "图片地址",
|
|
20
|
-
"type": "
|
|
20
|
+
"type": "string"
|
|
21
21
|
},
|
|
22
22
|
{
|
|
23
23
|
"key": "width",
|
|
@@ -26,6 +26,13 @@
|
|
|
26
26
|
"type": "number",
|
|
27
27
|
"default": 350
|
|
28
28
|
},
|
|
29
|
+
{
|
|
30
|
+
"key": "autoWidth",
|
|
31
|
+
"name": "宽度自适应",
|
|
32
|
+
"desc": "是否图片宽度自适应",
|
|
33
|
+
"type": "switch",
|
|
34
|
+
"default": false
|
|
35
|
+
},
|
|
29
36
|
{
|
|
30
37
|
"key": "height",
|
|
31
38
|
"name": "高度",
|
|
@@ -34,10 +41,10 @@
|
|
|
34
41
|
"default": 200
|
|
35
42
|
},
|
|
36
43
|
{
|
|
37
|
-
"key": "
|
|
38
|
-
"name": "
|
|
39
|
-
"desc": "
|
|
40
|
-
"type": "
|
|
44
|
+
"key": "autoHeight",
|
|
45
|
+
"name": "高度自适应",
|
|
46
|
+
"desc": "是否图片高度自适应",
|
|
47
|
+
"type": "switch",
|
|
41
48
|
"default": false
|
|
42
49
|
},
|
|
43
50
|
{
|
|
@@ -47,16 +54,16 @@
|
|
|
47
54
|
"type": "select",
|
|
48
55
|
"options": [
|
|
49
56
|
{
|
|
50
|
-
"label": "
|
|
51
|
-
"value": "
|
|
57
|
+
"label": "铺满(Cover)",
|
|
58
|
+
"value": "cover"
|
|
52
59
|
},
|
|
53
60
|
{
|
|
54
|
-
"label": "
|
|
55
|
-
"value": "
|
|
61
|
+
"label": "适合(Contain)",
|
|
62
|
+
"value": "contain"
|
|
56
63
|
},
|
|
57
64
|
{
|
|
58
|
-
"label": "
|
|
59
|
-
"value": "
|
|
65
|
+
"label": "拉伸(Fill)",
|
|
66
|
+
"value": "fill"
|
|
60
67
|
}
|
|
61
68
|
],
|
|
62
69
|
"default": "fill"
|
|
@@ -65,8 +72,36 @@
|
|
|
65
72
|
"key": "roundRadios",
|
|
66
73
|
"name": "圆角",
|
|
67
74
|
"desc": "图片四周圆角大小,可设置“0 1px 2px 3px",
|
|
68
|
-
"type": "
|
|
69
|
-
"
|
|
75
|
+
"type": "select",
|
|
76
|
+
"options": [
|
|
77
|
+
{
|
|
78
|
+
"label": "大(16px)",
|
|
79
|
+
"value": "16px"
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
"label": "中(8px)",
|
|
83
|
+
"value": "8px"
|
|
84
|
+
},
|
|
85
|
+
{
|
|
86
|
+
"label": "小(4px)",
|
|
87
|
+
"value": "4px"
|
|
88
|
+
},
|
|
89
|
+
{
|
|
90
|
+
"label": "无(0px)",
|
|
91
|
+
"value": "0px"
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
"label": "自定义",
|
|
95
|
+
"value": ""
|
|
96
|
+
}
|
|
97
|
+
],
|
|
98
|
+
"default": ""
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
"key": "borderRadios",
|
|
102
|
+
"name": "圆角大小",
|
|
103
|
+
"desc": "自定义圆角大小",
|
|
104
|
+
"type": "string"
|
|
70
105
|
},
|
|
71
106
|
{
|
|
72
107
|
"key": "title",
|
|
@@ -84,7 +119,7 @@
|
|
|
84
119
|
"key": "preview",
|
|
85
120
|
"name": "开启图片预览",
|
|
86
121
|
"desc": "是否开启点击打开图片预览",
|
|
87
|
-
"type": "
|
|
122
|
+
"type": "switch",
|
|
88
123
|
"default": false
|
|
89
124
|
}
|
|
90
125
|
],
|
|
@@ -106,7 +141,7 @@
|
|
|
106
141
|
{
|
|
107
142
|
"key": "onClick",
|
|
108
143
|
"name": "点击事件",
|
|
109
|
-
"desc": "
|
|
144
|
+
"desc": "点击图片时,执行方法",
|
|
110
145
|
"func": "(e)=>{\n\t\n}"
|
|
111
146
|
}
|
|
112
147
|
]
|
|
@@ -6,17 +6,56 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
8
|
exports.default = void 0;
|
|
9
|
+
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
9
10
|
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
|
|
10
11
|
var _react = _interopRequireWildcard(require("react"));
|
|
11
12
|
var _ahooks = require("ahooks");
|
|
12
13
|
var _helper = require("../../../engine/tools/helper");
|
|
13
14
|
var _linkPropsDefault = _interopRequireDefault(require("../../../engine/meta/link.props.default.json"));
|
|
14
15
|
var _Wrapper = _interopRequireDefault(require("../Wrapper"));
|
|
15
|
-
var
|
|
16
|
+
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
17
|
+
var _ContextProvider = require("../../../engine/provider/ContextProvider");
|
|
18
|
+
var _constants = require("../../../constants");
|
|
19
|
+
var _excluded = ["id", "css", "onClick", "advance"];
|
|
20
|
+
var StyledLink = _styledComponents.default.a.withConfig({
|
|
21
|
+
displayName: "StyledLink",
|
|
22
|
+
componentId: "luckda-6530__sc-13gzda1-0"
|
|
23
|
+
})(["display:", ";max-width:", ";white-space:", ";overflow:", ";text-overflow:", ";", ";"], function (props) {
|
|
24
|
+
return props.textOverflow && 'inline-block';
|
|
25
|
+
}, function (props) {
|
|
26
|
+
return props.textOverflow && '100%';
|
|
27
|
+
}, function (props) {
|
|
28
|
+
return props.textOverflow && 'nowrap';
|
|
29
|
+
}, function (props) {
|
|
30
|
+
return props.textOverflow && 'hidden';
|
|
31
|
+
}, function (props) {
|
|
32
|
+
return props.textOverflow && 'ellipsis';
|
|
33
|
+
}, function (props) {
|
|
34
|
+
return props.$css;
|
|
35
|
+
});
|
|
16
36
|
var LCLink = function LCLink(_ref) {
|
|
17
37
|
var id = _ref.id,
|
|
38
|
+
css = _ref.css,
|
|
39
|
+
onClick = _ref.onClick,
|
|
40
|
+
advance = _ref.advance,
|
|
18
41
|
props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
|
|
19
42
|
var ref = (0, _react.useRef)();
|
|
43
|
+
var ctx = (0, _ContextProvider.useContext)();
|
|
44
|
+
(0, _react.useEffect)(function () {
|
|
45
|
+
ctx.doAction(advance.events.onMount);
|
|
46
|
+
return function () {
|
|
47
|
+
return ctx.doAction(advance.events.onUnmount);
|
|
48
|
+
};
|
|
49
|
+
}, []);
|
|
50
|
+
var handleClick = (0, _ahooks.useMemoizedFn)(function (e) {
|
|
51
|
+
if (onClick) {
|
|
52
|
+
onClick(e);
|
|
53
|
+
return;
|
|
54
|
+
}
|
|
55
|
+
ctx.doAction(advance.events.onClick, {
|
|
56
|
+
e: e
|
|
57
|
+
});
|
|
58
|
+
});
|
|
20
59
|
var getTargetDom = (0, _ahooks.useMemoizedFn)(function () {
|
|
21
60
|
return ref.current;
|
|
22
61
|
});
|
|
@@ -24,9 +63,18 @@ var LCLink = function LCLink(_ref) {
|
|
|
24
63
|
id: id,
|
|
25
64
|
displayName: "Link",
|
|
26
65
|
getTargetDom: getTargetDom
|
|
27
|
-
}, /*#__PURE__*/_react.default.createElement(
|
|
28
|
-
|
|
29
|
-
},
|
|
66
|
+
}, /*#__PURE__*/_react.default.createElement(StyledLink, (0, _extends2.default)({
|
|
67
|
+
$css: css
|
|
68
|
+
}, props, {
|
|
69
|
+
ref: ref,
|
|
70
|
+
href: "".concat(props.url, "?").concat(props.params),
|
|
71
|
+
target: props.isBlank ? '_blank' : '_self',
|
|
72
|
+
title: props.textOverflow && props.content,
|
|
73
|
+
onClick: function onClick(e) {
|
|
74
|
+
handleClick(e);
|
|
75
|
+
ctx.runtime === _constants.RUNTIME.DESIGN && e.preventDefault();
|
|
76
|
+
}
|
|
77
|
+
}), props.content));
|
|
30
78
|
};
|
|
31
79
|
LCLink.defaultProps = (0, _helper.omitBadProps)(_linkPropsDefault.default);
|
|
32
80
|
var _default = exports.default = LCLink;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
.alink {
|
|
2
|
+
display: inline-block;
|
|
3
|
+
max-width: 100%;
|
|
4
|
+
white-space: nowrap;
|
|
5
|
+
overflow: hidden;
|
|
6
|
+
text-overflow: ellipsis;
|
|
7
|
+
|
|
8
|
+
a {
|
|
9
|
+
display: inline-block;
|
|
10
|
+
max-width: 100%;
|
|
11
|
+
white-space: nowrap;
|
|
12
|
+
overflow: hidden;
|
|
13
|
+
text-overflow: ellipsis;
|
|
14
|
+
}
|
|
15
|
+
}
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"props": [
|
|
10
10
|
{
|
|
11
11
|
"key": "id",
|
|
12
|
-
"
|
|
12
|
+
"name": "唯一标识",
|
|
13
13
|
"type": "string",
|
|
14
14
|
"disabled": true
|
|
15
15
|
},
|
|
@@ -22,8 +22,8 @@
|
|
|
22
22
|
{
|
|
23
23
|
"key": "textOverflow",
|
|
24
24
|
"name": "单行截断",
|
|
25
|
-
"desc": "
|
|
26
|
-
"type": "
|
|
25
|
+
"desc": "文字超过一行,使用...显示;开后此项后,同时会显示html标签的title",
|
|
26
|
+
"type": "switch",
|
|
27
27
|
"default": false
|
|
28
28
|
},
|
|
29
29
|
{
|
|
@@ -50,16 +50,16 @@
|
|
|
50
50
|
"type": "string"
|
|
51
51
|
},
|
|
52
52
|
{
|
|
53
|
-
"key": "
|
|
54
|
-
"name": "
|
|
55
|
-
"desc": "
|
|
56
|
-
"type": "
|
|
57
|
-
"default":
|
|
53
|
+
"key": "isBlank",
|
|
54
|
+
"name": "新开页面",
|
|
55
|
+
"desc": "是否新开页面",
|
|
56
|
+
"type": "switch",
|
|
57
|
+
"default": true
|
|
58
58
|
},
|
|
59
59
|
{
|
|
60
60
|
"key": "params",
|
|
61
61
|
"name": "携带参数",
|
|
62
|
-
"desc": "
|
|
62
|
+
"desc": "超链的携带参数,key=value形式,多个参数中间用&拼接,例如:pageNo=1&pageSize=20",
|
|
63
63
|
"type": "string"
|
|
64
64
|
},
|
|
65
65
|
{
|
|
@@ -346,12 +346,13 @@ var LCTable = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
|
|
|
346
346
|
resource: action.serial
|
|
347
347
|
};
|
|
348
348
|
}),
|
|
349
|
-
onBatchOperationsClick: function onBatchOperationsClick(key, selectedRows) {
|
|
349
|
+
onBatchOperationsClick: function onBatchOperationsClick(key, selectedRows, cb) {
|
|
350
350
|
var todoListById = (0, _lodash.keyBy)(bantchActions.todoList, 'id');
|
|
351
351
|
var doAction = function doAction() {
|
|
352
352
|
ctx.doAction(todoListById[key].actionPool, {
|
|
353
353
|
key: key,
|
|
354
354
|
selectedRows: selectedRows,
|
|
355
|
+
cb: cb,
|
|
355
356
|
datasetCode: dataset.code
|
|
356
357
|
});
|
|
357
358
|
};
|
|
@@ -455,12 +456,12 @@ var LCTable = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
|
|
|
455
456
|
}
|
|
456
457
|
return resultComp;
|
|
457
458
|
}, [topActionGroup, impexp]);
|
|
458
|
-
var renderFilterArea = (0,
|
|
459
|
+
var renderFilterArea = (0, _react.useCallback)(function () {
|
|
459
460
|
return topFilter ? /*#__PURE__*/_react.default.createElement(_TopFilter.default, {
|
|
460
461
|
filter: topFilter,
|
|
461
462
|
instance: instanceRef
|
|
462
463
|
}) : null;
|
|
463
|
-
});
|
|
464
|
+
}, [topFilter]);
|
|
464
465
|
var _wrapperProps = (0, _ahooks.useCreation)(function () {
|
|
465
466
|
return (0, _defineProperty2.default)({
|
|
466
467
|
id: id
|
|
@@ -471,9 +472,7 @@ var LCTable = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
|
|
|
471
472
|
var condition = _zebra !== null && _zebra !== void 0 && _zebra.condition ? (0, _helper.executeCode)(ctx, _zebra.condition, ['params'], params) : _zebra && params.node.rowIndex % 2 === 0;
|
|
472
473
|
return condition ? {
|
|
473
474
|
'background-color': _zebra.color || _zebra
|
|
474
|
-
} : {
|
|
475
|
-
'background-color': '#fff'
|
|
476
|
-
};
|
|
475
|
+
} : {};
|
|
477
476
|
});
|
|
478
477
|
var _readFilter = (0, _ahooks.useMemoizedFn)(function (params, filters) {
|
|
479
478
|
ctx.doAction(advance.events.onFilterChanged, {
|
|
@@ -168,7 +168,7 @@
|
|
|
168
168
|
"default": {
|
|
169
169
|
"todoList": []
|
|
170
170
|
},
|
|
171
|
-
"defaultCode": "function onBatchOperationsClick(key, selectedRows) {\n\n}",
|
|
171
|
+
"defaultCode": "function onBatchOperationsClick(key, selectedRows, cb) {\n\n}",
|
|
172
172
|
"suppressDisplay": true,
|
|
173
173
|
"suppressMax": true,
|
|
174
174
|
"suppressMore": true,
|
|
@@ -16,6 +16,7 @@ var _ahooks = require("ahooks");
|
|
|
16
16
|
var _lodash = require("lodash");
|
|
17
17
|
var _utils = require("@luck-design-biz/base/utils");
|
|
18
18
|
var _ContextProvider = require("../../../engine/provider/ContextProvider");
|
|
19
|
+
var _DragDropContext = require("../../../painter/components/DragDrop/DragDropContext");
|
|
19
20
|
var _boxPropsDefault = _interopRequireDefault(require("../../../engine/meta/box.props.default.json"));
|
|
20
21
|
var _excluded = ["children", "id", "items"];
|
|
21
22
|
var FunctionDesign = function FunctionDesign(_ref) {
|
|
@@ -66,13 +67,48 @@ var FunctionDesign = function FunctionDesign(_ref) {
|
|
|
66
67
|
});
|
|
67
68
|
}
|
|
68
69
|
}).watch();
|
|
70
|
+
var cdeid = ctx.$subscriber(ctx.topics.COMPONENT_DRAG_END).on(function (_ref4) {
|
|
71
|
+
var toId = _ref4.id,
|
|
72
|
+
fromId = _ref4.fromId,
|
|
73
|
+
action = _ref4.action,
|
|
74
|
+
actionSide = _ref4.actionSide,
|
|
75
|
+
vaild = _ref4.vaild;
|
|
76
|
+
if (!vaild || action === _DragDropContext.Action.ADD) return;
|
|
77
|
+
var fromTabId = current[fromId].props.tabId;
|
|
78
|
+
var toTabId = current[toId].props.tabId;
|
|
79
|
+
var fromIndex = items.findIndex(function (_ref5) {
|
|
80
|
+
var _tabId = _ref5.id;
|
|
81
|
+
return _tabId === fromTabId;
|
|
82
|
+
});
|
|
83
|
+
var _items = (0, _lodash.cloneDeep)(items);
|
|
84
|
+
var _items$splice = _items.splice(fromIndex, 1),
|
|
85
|
+
_items$splice2 = (0, _slicedToArray2.default)(_items$splice, 1),
|
|
86
|
+
_tab = _items$splice2[0];
|
|
87
|
+
var toIndex = _items.findIndex(function (_ref6) {
|
|
88
|
+
var _tabId = _ref6.id;
|
|
89
|
+
return _tabId === toTabId;
|
|
90
|
+
});
|
|
91
|
+
if (actionSide === _DragDropContext.ActionSide.LEFT) {
|
|
92
|
+
_items.splice(toIndex, 0, _tab);
|
|
93
|
+
} else if (actionSide === _DragDropContext.ActionSide.RIGHT) {
|
|
94
|
+
_items.splice(toIndex + 1, 0, _tab);
|
|
95
|
+
}
|
|
96
|
+
(0, _ContextProvider.modifyNode)(id, {
|
|
97
|
+
items: _items
|
|
98
|
+
});
|
|
99
|
+
}).watch();
|
|
69
100
|
return function () {
|
|
70
|
-
|
|
101
|
+
ctx.$unsubscriber(ctx.topics.COMPONENT_DRAG_END, cdeid);
|
|
102
|
+
ctx.$unsubscriber(ctx.topics.COMPONENT_MODIFY, cmid);
|
|
71
103
|
};
|
|
72
104
|
}, [current.children]);
|
|
73
105
|
return /*#__PURE__*/_react.default.createElement(_index.default, (0, _extends2.default)({
|
|
74
106
|
id: id,
|
|
75
|
-
items: items
|
|
107
|
+
items: items.map(function (_item) {
|
|
108
|
+
return (0, _objectSpread2.default)((0, _objectSpread2.default)({}, _item), {}, {
|
|
109
|
+
destory: false
|
|
110
|
+
});
|
|
111
|
+
})
|
|
76
112
|
}, props), children);
|
|
77
113
|
};
|
|
78
114
|
var _default = exports.default = FunctionDesign;
|
|
@@ -96,7 +96,7 @@ var LCTabs = function LCTabs(_ref) {
|
|
|
96
96
|
return /*#__PURE__*/_react.default.createElement(_antd.Tabs.TabPane, {
|
|
97
97
|
tab: item.name,
|
|
98
98
|
key: item.id,
|
|
99
|
-
forceRender: item.destory
|
|
99
|
+
forceRender: !item.destory
|
|
100
100
|
}, children === null || children === void 0 ? void 0 : children.find(function (child) {
|
|
101
101
|
return child.props.tabId === item.id;
|
|
102
102
|
}));
|
|
@@ -20,14 +20,15 @@ var _utils = require("@luck-design-biz/base/utils");
|
|
|
20
20
|
var _ContextProvider = require("../../../engine/provider/ContextProvider");
|
|
21
21
|
var _Wrapper = _interopRequireDefault(require("../Wrapper"));
|
|
22
22
|
var _index = require("../../../../index");
|
|
23
|
+
var _useCombinedRefs = _interopRequireDefault(require("../../../engine/tools/useCombinedRefs"));
|
|
23
24
|
var _helper = require("../../../engine/tools/helper");
|
|
24
25
|
var _treePropsDefault = _interopRequireDefault(require("../../../engine/meta/tree.props.default.json"));
|
|
26
|
+
var _constants = require("../../../constants");
|
|
25
27
|
var _index2 = _interopRequireDefault(require("./index.less"));
|
|
26
|
-
var _excluded = ["id", "
|
|
28
|
+
var _excluded = ["id", "className", "dataset", "width", "height", "showLine", "defaultExpandDeep", "actions", "editable", "showRootAdd", "onlyRoot", "rootAddSetting", "doubleClickExpand", "onDoubleClick", "treeNodeCheckable", "treeNodeDisableCheckbox", "treeNodeDisable", "onTreeNodeRender", "treeNodeIcon", "advance", "cancelSelect", "defaultSelect"];
|
|
27
29
|
var PRIMARY = window.appConfig.constraintKeys.PRIMARY;
|
|
28
|
-
var LCTree = function
|
|
30
|
+
var LCTree = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
|
|
29
31
|
var id = _ref.id,
|
|
30
|
-
wrapperRef = _ref.wrapperRef,
|
|
31
32
|
className = _ref.className,
|
|
32
33
|
dataset = _ref.dataset,
|
|
33
34
|
width = _ref.width,
|
|
@@ -51,20 +52,20 @@ var LCTree = function LCTree(_ref) {
|
|
|
51
52
|
defaultSelect = _ref.defaultSelect,
|
|
52
53
|
props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
|
|
53
54
|
var ctx = (0, _ContextProvider.useContext)();
|
|
54
|
-
var boxRef = (0, _react.useRef)();
|
|
55
55
|
var apiRef = (0, _react.useRef)();
|
|
56
|
-
var
|
|
56
|
+
var wrapperRef = (0, _react.useRef)();
|
|
57
|
+
var instanceRef = (0, _useCombinedRefs.default)(ref);
|
|
57
58
|
var _useState = (0, _react.useState)([]),
|
|
58
59
|
_useState2 = (0, _slicedToArray2.default)(_useState, 2),
|
|
59
60
|
selectedKeys = _useState2[0],
|
|
60
61
|
setSelectedKeys = _useState2[1];
|
|
61
62
|
var getTargetDom = (0, _ahooks.useMemoizedFn)(function () {
|
|
62
|
-
return
|
|
63
|
+
return wrapperRef.current;
|
|
63
64
|
});
|
|
64
65
|
(0, _react.useImperativeHandle)(apiRef, function () {
|
|
65
66
|
return {
|
|
66
67
|
getInstance: function getInstance() {
|
|
67
|
-
return
|
|
68
|
+
return instanceRef.current;
|
|
68
69
|
}
|
|
69
70
|
};
|
|
70
71
|
});
|
|
@@ -149,23 +150,24 @@ var LCTree = function LCTree(_ref) {
|
|
|
149
150
|
doAction();
|
|
150
151
|
}
|
|
151
152
|
};
|
|
153
|
+
var _wrapperProps = (0, _ahooks.useCreation)(function () {
|
|
154
|
+
return (0, _defineProperty2.default)({
|
|
155
|
+
id: id
|
|
156
|
+
}, _constants.LC_COMPONENT_UNIT_KEY, _constants.LC_COMPONENT_UNIT);
|
|
157
|
+
}, []);
|
|
152
158
|
return /*#__PURE__*/_react.default.createElement(_Wrapper.default, {
|
|
153
159
|
id: id,
|
|
154
160
|
displayName: "Tree",
|
|
155
161
|
getTargetDom: getTargetDom,
|
|
156
162
|
api: apiRef
|
|
157
|
-
}, /*#__PURE__*/_react.default.createElement("div", {
|
|
158
|
-
ref: boxRef,
|
|
159
|
-
style: {
|
|
160
|
-
width: width,
|
|
161
|
-
height: height
|
|
162
|
-
}
|
|
163
163
|
}, /*#__PURE__*/_react.default.createElement(_index.LdTree, (0, _extends2.default)({
|
|
164
|
-
width:
|
|
165
|
-
height:
|
|
164
|
+
width: width,
|
|
165
|
+
height: height,
|
|
166
166
|
id: id,
|
|
167
167
|
ldId: id,
|
|
168
|
-
ref:
|
|
168
|
+
ref: instanceRef,
|
|
169
|
+
wrapper: wrapperRef,
|
|
170
|
+
wrapperProps: _wrapperProps,
|
|
169
171
|
className: (0, _classnames.default)(_index2.default['lc-component-tree'], (0, _defineProperty2.default)({}, className, !!className)),
|
|
170
172
|
dataSetKey: dataset === null || dataset === void 0 ? void 0 : dataset.code,
|
|
171
173
|
showLine: showLine,
|
|
@@ -230,8 +232,8 @@ var LCTree = function LCTree(_ref) {
|
|
|
230
232
|
selectedKeys: selectedKeys,
|
|
231
233
|
onSelect: handleSelect,
|
|
232
234
|
afterInit: afterInit
|
|
233
|
-
}, events, props)))
|
|
234
|
-
};
|
|
235
|
+
}, events, props)));
|
|
236
|
+
});
|
|
235
237
|
LCTree.propTypes = {
|
|
236
238
|
/**
|
|
237
239
|
* @name 唯一标识
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"props": [
|
|
10
10
|
{
|
|
11
11
|
"key": "id",
|
|
12
|
-
"
|
|
12
|
+
"name": "唯一标识",
|
|
13
13
|
"type": "string",
|
|
14
14
|
"disabled": true
|
|
15
15
|
},
|
|
@@ -193,7 +193,7 @@
|
|
|
193
193
|
"props": [
|
|
194
194
|
{
|
|
195
195
|
"key": "cancelSelect",
|
|
196
|
-
"name": "
|
|
196
|
+
"name": "允许取消选中",
|
|
197
197
|
"desc": "是否可以取消选中",
|
|
198
198
|
"type": "switch",
|
|
199
199
|
"default": true
|