@vtx/components 4.0.0-beta.34 → 4.0.0-beta.36
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/vtx-datagrid/Store/Provide.js +124 -73
- package/es/vtx-datagrid/ToolBar/components/Density/index.js +2 -0
- package/es/vtx-datagrid/index.js +22 -10
- package/es/vtx-datagrid/renderColumnButtons.js +2 -2
- package/es/vtx-datagrid/style/index.js +23 -20
- package/es/vtx-ellipsis-text/style/index.js +3 -1
- package/es/vtx-select/index.js +2 -4
- package/es/vtx-select/style/index.js +12 -56
- package/es/vtx-split-pane/style/index.js +1 -0
- package/es/vtx-tree-select/index.js +21 -18
- package/es/vtx-tree-select/style/index.js +4 -1
- package/lib/vtx-datagrid/Store/Provide.js +124 -73
- package/lib/vtx-datagrid/ToolBar/components/Density/index.js +2 -0
- package/lib/vtx-datagrid/index.js +22 -10
- package/lib/vtx-datagrid/renderColumnButtons.js +2 -2
- package/lib/vtx-datagrid/style/index.js +23 -20
- package/lib/vtx-ellipsis-text/style/index.js +3 -1
- package/lib/vtx-select/index.js +3 -5
- package/lib/vtx-select/style/index.js +12 -56
- package/lib/vtx-split-pane/style/index.js +1 -0
- package/lib/vtx-tree-select/index.js +21 -18
- package/lib/vtx-tree-select/style/index.js +4 -1
- package/package.json +2 -2
|
@@ -4,6 +4,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.useStyle = useStyle;
|
|
7
|
+
var _lodash = require("@umijs/utils/compiled/lodash");
|
|
7
8
|
var _vtxProvider = require("../../vtx-provider");
|
|
8
9
|
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
9
10
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
@@ -13,66 +14,21 @@ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol"
|
|
|
13
14
|
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
14
15
|
var genVtxSelectStyle = function genVtxSelectStyle(token) {
|
|
15
16
|
var componentCls = token.componentCls;
|
|
16
|
-
return _defineProperty(_defineProperty({}, componentCls, {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
top: '0',
|
|
24
|
-
verticalAlign: 'top'
|
|
25
|
-
},
|
|
26
|
-
'.vtx-all-list': {
|
|
27
|
-
position: 'absolute',
|
|
28
|
-
zIndex: 999,
|
|
29
|
-
boxSizing: 'border-box',
|
|
30
|
-
width: '100%',
|
|
31
|
-
padding: '5px',
|
|
32
|
-
boxShadow: '0 2px 8px #d9d9d9',
|
|
33
|
-
backgroundColor: 'red !important'
|
|
34
|
-
},
|
|
35
|
-
'.ant-select-selection--multiple': {
|
|
36
|
-
maxHeight: '32px',
|
|
37
|
-
overflow: 'hidden'
|
|
38
|
-
}
|
|
39
|
-
}), '.vtx-multi-select', {
|
|
40
|
-
position: 'relative',
|
|
41
|
-
display: 'inline-block',
|
|
42
|
-
width: '100%',
|
|
43
|
-
maxHeight: '32px !important',
|
|
44
|
-
boxSizing: 'border-box',
|
|
45
|
-
'.vtx-select-count': {
|
|
46
|
-
position: 'absolute',
|
|
47
|
-
top: 0,
|
|
48
|
-
right: 0,
|
|
49
|
-
verticalAlign: 'top',
|
|
50
|
-
borderLeft: 'none',
|
|
51
|
-
borderTopLeftRadius: 0,
|
|
52
|
-
'border-bottom-left-radius': 0
|
|
53
|
-
},
|
|
54
|
-
'.vtx-all-list': {
|
|
55
|
-
position: 'absolute',
|
|
56
|
-
zIndex: 999,
|
|
57
|
-
boxSizing: 'border-box',
|
|
58
|
-
width: '100%',
|
|
59
|
-
padding: '5px',
|
|
60
|
-
boxShadow: '0 2px 8px #d9d9d9'
|
|
61
|
-
},
|
|
62
|
-
'.ant-select-selector': {
|
|
63
|
-
'border-top-right-radius': 0,
|
|
64
|
-
'border-bottom-right-radius': 0,
|
|
65
|
-
maxHeight: '32px !important',
|
|
66
|
-
overflow: 'hidden'
|
|
67
|
-
},
|
|
68
|
-
'.ant-select-selection--multiple': {
|
|
69
|
-
maxHeight: '32px',
|
|
70
|
-
overflow: 'hidden'
|
|
17
|
+
return _defineProperty(_defineProperty(_defineProperty({}, componentCls, _defineProperty({
|
|
18
|
+
width: "100%"
|
|
19
|
+
}, '.ant-select', {
|
|
20
|
+
overflow: "hidden"
|
|
21
|
+
})), "".concat(componentCls, "-multi"), {
|
|
22
|
+
".ant-select-content": {
|
|
23
|
+
flexWrap: "nowrap"
|
|
71
24
|
}
|
|
25
|
+
}), "".concat(componentCls, "-all-list"), {
|
|
26
|
+
maxHeight: 300,
|
|
27
|
+
overflowY: "auto"
|
|
72
28
|
});
|
|
73
29
|
};
|
|
74
30
|
function useStyle(prefixCls) {
|
|
75
|
-
return (0, _vtxProvider.useStyle)('
|
|
31
|
+
return (0, _vtxProvider.useStyle)('', function (token) {
|
|
76
32
|
var vtxSelectToken = _objectSpread(_objectSpread({}, token), {}, {
|
|
77
33
|
componentCls: ".".concat(prefixCls)
|
|
78
34
|
});
|
|
@@ -16,6 +16,7 @@ var genVtxSplitPaneStyle = function genVtxSplitPaneStyle(token) {
|
|
|
16
16
|
return _defineProperty({}, componentCls, {
|
|
17
17
|
height: '100%',
|
|
18
18
|
overflow: 'hidden',
|
|
19
|
+
backgroundColor: token.colorBgLayout,
|
|
19
20
|
'.ant-splitter-bar .ant-splitter-bar-dragger::before': {
|
|
20
21
|
background: 'transparent'
|
|
21
22
|
},
|
|
@@ -149,24 +149,27 @@ var VtxTreeSelect = exports.VtxTreeSelect = function VtxTreeSelect(_ref) {
|
|
|
149
149
|
},
|
|
150
150
|
children: intl.getMessage('treeSelect.clearSelectedItems', '清空已选项')
|
|
151
151
|
})]
|
|
152
|
-
}),
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
152
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
153
|
+
className: (0, _classnames.default)("".concat(prefixCls, "-all-list"), hashId),
|
|
154
|
+
children: selectedNodes.length > 0 ? selectedNodes.map(function (item) {
|
|
155
|
+
var _item$fieldNames$labe;
|
|
156
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_antd.Tag, {
|
|
157
|
+
closable: !disabled,
|
|
158
|
+
onClose: function onClose(e) {
|
|
159
|
+
e.stopPropagation();
|
|
160
|
+
clearKey(item[fieldNames.value]);
|
|
161
|
+
},
|
|
162
|
+
styles: {
|
|
163
|
+
root: {
|
|
164
|
+
marginBottom: 5,
|
|
165
|
+
marginRight: 5
|
|
166
|
+
}
|
|
167
|
+
},
|
|
168
|
+
children: ((_item$fieldNames$labe = item[fieldNames.label]) === null || _item$fieldNames$labe === void 0 ? void 0 : _item$fieldNames$labe.length) > 20 ? "".concat(item[fieldNames.label].slice(0, 20), "...") : item[fieldNames.label]
|
|
169
|
+
}, "tab-".concat(item[fieldNames.value]));
|
|
170
|
+
}) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_antd.Empty, {
|
|
171
|
+
image: _antd.Empty.PRESENTED_IMAGE_SIMPLE
|
|
172
|
+
})
|
|
170
173
|
})]
|
|
171
174
|
});
|
|
172
175
|
var onChangeTreeSelect = function onChangeTreeSelect(value, label, extra) {
|
|
@@ -14,7 +14,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
14
14
|
var genVtxTreeSelectStyle = function genVtxTreeSelectStyle(token) {
|
|
15
15
|
var componentCls = token.componentCls;
|
|
16
16
|
console.log('token.controlHeight', token.controlHeight);
|
|
17
|
-
return _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, componentCls, _defineProperty(_defineProperty(_defineProperty(_defineProperty({}, '&-popover', {
|
|
17
|
+
return _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, componentCls, _defineProperty(_defineProperty(_defineProperty(_defineProperty({}, '&-popover', {
|
|
18
18
|
minWidth: '200px',
|
|
19
19
|
height: '300px',
|
|
20
20
|
overflow: 'auto',
|
|
@@ -54,6 +54,9 @@ var genVtxTreeSelectStyle = function genVtxTreeSelectStyle(token) {
|
|
|
54
54
|
}, '&:hover', {
|
|
55
55
|
color: '#40a9ff'
|
|
56
56
|
})
|
|
57
|
+
}), "".concat(componentCls, "-all-list"), {
|
|
58
|
+
maxHeight: 300,
|
|
59
|
+
overflowY: "auto"
|
|
57
60
|
}), "".concat(componentCls, "-outer"), {
|
|
58
61
|
position: 'relative',
|
|
59
62
|
display: 'inline-flex',
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vtx/components",
|
|
3
|
-
"version": "4.0.0-beta.
|
|
3
|
+
"version": "4.0.0-beta.36",
|
|
4
4
|
"description": "React components for Vortex",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"react",
|
|
@@ -155,7 +155,7 @@
|
|
|
155
155
|
"@vitest/coverage-istanbul": "^3.2.4",
|
|
156
156
|
"@vitest/ui": "^3.2.4",
|
|
157
157
|
"animated-scroll-to": "^2.3.2",
|
|
158
|
-
"antd": "^6.3.
|
|
158
|
+
"antd": "^6.3.3",
|
|
159
159
|
"chalk": "^4.1.2",
|
|
160
160
|
"copy-to-clipboard": "^3.3.3",
|
|
161
161
|
"cross-env": "^7.0.3",
|