@vtx/components 4.0.0-beta.38 → 4.0.0-beta.39

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.
@@ -135,11 +135,11 @@ function VtxTable(props) {
135
135
  }
136
136
  var tableHeight = (_bodyDiv$getElementsB = bodyDiv.getElementsByTagName('table')) === null || _bodyDiv$getElementsB === void 0 || (_bodyDiv$getElementsB = _bodyDiv$getElementsB[0]) === null || _bodyDiv$getElementsB === void 0 ? void 0 : _bodyDiv$getElementsB.clientHeight;
137
137
  if (tablePlaceholder) {
138
- tablePlaceholder.style.height = "".concat(bodyHeight - (rest.scrollY || 0) - 12 - 32, "px");
138
+ tablePlaceholder.style.height = "".concat(bodyHeight - (rest.scrollY || 0) - 48 - 12, "px");
139
139
  var tableCell = Array.prototype.filter.call(tablePlaceholder.getElementsByTagName('td'), function (dom) {
140
140
  return dom.className.includes('ant-table-cell');
141
141
  })[0];
142
- tableCell.style.height = "".concat(bodyHeight - (rest.scrollY || 0) - 12 - 32, "px");
142
+ tableCell.style.height = "".concat(bodyHeight - (rest.scrollY || 0) - 48 - 12, "px");
143
143
  }
144
144
  // antd6.x 的bug 如果table的高度 没有body 高 则没有滚动条
145
145
 
@@ -356,7 +356,7 @@ function VtxTable(props) {
356
356
  }) : null;
357
357
  return wrapSSR( /*#__PURE__*/_jsxs("div", {
358
358
  id: datagridId,
359
- className: classnames(prefixCls, className, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(prefixCls, "-fit"), autoFit), "".concat(prefixCls, "-noFit"), !autoFit), "".concat(prefixCls, "-nodata"), !(dataSource !== null && dataSource !== void 0 && dataSource.length)), "".concat(prefixCls, "-userAgent-mac"), isMac), "".concat(prefixCls, "-striped"), tableStyles.includes('striped')), "".concat(prefixCls, "-no-border"), !tableStyles.includes('border')), "".concat(prefixCls, "-header-background"), tableStyles.includes('header-background')), hashId),
359
+ className: classnames(prefixCls, className, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(prefixCls, "-fit"), autoFit), "".concat(prefixCls, "-noFit"), !autoFit), "".concat(prefixCls, "-nodata"), !(dataSource !== null && dataSource !== void 0 && dataSource.length)), "".concat(prefixCls, "-userAgent-mac"), isMac), "".concat(prefixCls, "-striped"), tableStyles.includes('striped')), "".concat(prefixCls, "-no-border"), !tableStyles.includes('border')), "".concat(prefixCls, "-no-data"), (dataSource === null || dataSource === void 0 ? void 0 : dataSource.length) === 0), "".concat(prefixCls, "-header-background"), tableStyles.includes('header-background')), "".concat(prefixCls, "-no-header-background"), !tableStyles.includes('header-background')), hashId),
360
360
  ref: rootDomRef,
361
361
  style: style,
362
362
  children: [toolbarRender, alertRender, /*#__PURE__*/_jsx(Table, _objectSpread(_objectSpread({
@@ -8,7 +8,7 @@ import { useStyle as useAntdStyle } from "../../vtx-provider";
8
8
  var genVtxStyle = function genVtxStyle(token) {
9
9
  var componentCls = token.componentCls,
10
10
  antCls = token.antCls;
11
- return _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, componentCls, _defineProperty({
11
+ return _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, componentCls, _defineProperty({
12
12
  position: 'relative',
13
13
  // overflow: 'hidden',
14
14
  display: 'flex',
@@ -26,7 +26,10 @@ var genVtxStyle = function genVtxStyle(token) {
26
26
  flex: 1
27
27
  }, '.ant-table-container', _defineProperty(_defineProperty({}, '.ant-table-body', {
28
28
  scrollbarWidth: "thin"
29
- }), '.ant-table-content', _defineProperty({}, 'table', {
29
+ }), '.ant-table-content', _defineProperty({
30
+ // height: '100%',
31
+ scrollbarWidth: "thin"
32
+ }, 'table', {
30
33
  // height: '100%',
31
34
  minWidth: "calc(100% - 1px) !important"
32
35
  })))))), '.ant-table', _defineProperty(_defineProperty(_defineProperty({}, '.ant-table-header', _defineProperty({}, '.ant-table-thead', {
@@ -44,8 +47,8 @@ var genVtxStyle = function genVtxStyle(token) {
44
47
  left: 0,
45
48
  backgroundColor: 'transparent',
46
49
  borderTop: 'none',
47
- borderInlineEnd: "var(--ant-line-width) var(--ant-line-type) var(--ant-table-border-color)",
48
- borderBottom: "var(--ant-line-width) var(--ant-line-type) var(--ant-table-border-color)",
50
+ // borderInlineEnd: "var(--ant-line-width) var(--ant-line-type) var(--ant-table-border-color)",
51
+ // borderBottom: "var(--ant-line-width) var(--ant-line-type) var(--ant-table-border-color)",
49
52
  '>td.ant-table-cell': {
50
53
  padding: 0,
51
54
  width: '100%',
@@ -101,7 +104,17 @@ var genVtxStyle = function genVtxStyle(token) {
101
104
  '>tr>th': {
102
105
  background: token.colorBgLayoutTable
103
106
  }
104
- })))));
107
+ }))))), "".concat(componentCls, "-no-header-background"), _defineProperty({}, "".concat(antCls, "-table-wrapper "), _defineProperty({}, '.ant-table-thead', {
108
+ '>tr>th': {
109
+ background: token.colorBgContainer
110
+ }
111
+ }))), "".concat(componentCls, "-no-data"), _defineProperty({}, "".concat(antCls, "-table-wrapper"), _defineProperty({}, '.ant-spin', _defineProperty({}, '.ant-spin-container', _defineProperty({}, '.ant-table', _defineProperty({}, '.ant-table-container', _defineProperty({}, '.ant-table-content', _defineProperty({
112
+ borderRight: "var(--ant-line-width) var(--ant-line-type) var(--ant-table-border-color)",
113
+ borderBottom: "var(--ant-line-width) var(--ant-line-type) var(--ant-table-border-color)"
114
+ }, 'table', {})))))))), "".concat(componentCls, "-no-data").concat(componentCls, "-no-border"), _defineProperty({}, "".concat(antCls, "-table-wrapper"), _defineProperty({}, '.ant-spin', _defineProperty({}, '.ant-spin-container', _defineProperty({}, '.ant-table', _defineProperty({}, '.ant-table-container', _defineProperty({}, '.ant-table-content', {
115
+ borderRight: "none",
116
+ borderBottom: "none"
117
+ })))))));
105
118
  };
106
119
  export function useStyle(prefix) {
107
120
  return useAntdStyle(prefix, function (token) {
@@ -145,11 +145,11 @@ function VtxTable(props) {
145
145
  }
146
146
  var tableHeight = (_bodyDiv$getElementsB = bodyDiv.getElementsByTagName('table')) === null || _bodyDiv$getElementsB === void 0 || (_bodyDiv$getElementsB = _bodyDiv$getElementsB[0]) === null || _bodyDiv$getElementsB === void 0 ? void 0 : _bodyDiv$getElementsB.clientHeight;
147
147
  if (tablePlaceholder) {
148
- tablePlaceholder.style.height = "".concat(bodyHeight - (rest.scrollY || 0) - 12 - 32, "px");
148
+ tablePlaceholder.style.height = "".concat(bodyHeight - (rest.scrollY || 0) - 48 - 12, "px");
149
149
  var tableCell = Array.prototype.filter.call(tablePlaceholder.getElementsByTagName('td'), function (dom) {
150
150
  return dom.className.includes('ant-table-cell');
151
151
  })[0];
152
- tableCell.style.height = "".concat(bodyHeight - (rest.scrollY || 0) - 12 - 32, "px");
152
+ tableCell.style.height = "".concat(bodyHeight - (rest.scrollY || 0) - 48 - 12, "px");
153
153
  }
154
154
  // antd6.x 的bug 如果table的高度 没有body 高 则没有滚动条
155
155
 
@@ -366,7 +366,7 @@ function VtxTable(props) {
366
366
  }) : null;
367
367
  return wrapSSR( /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
368
368
  id: datagridId,
369
- className: (0, _classnames2.default)(prefixCls, className, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(prefixCls, "-fit"), autoFit), "".concat(prefixCls, "-noFit"), !autoFit), "".concat(prefixCls, "-nodata"), !(dataSource !== null && dataSource !== void 0 && dataSource.length)), "".concat(prefixCls, "-userAgent-mac"), isMac), "".concat(prefixCls, "-striped"), tableStyles.includes('striped')), "".concat(prefixCls, "-no-border"), !tableStyles.includes('border')), "".concat(prefixCls, "-header-background"), tableStyles.includes('header-background')), hashId),
369
+ className: (0, _classnames2.default)(prefixCls, className, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(prefixCls, "-fit"), autoFit), "".concat(prefixCls, "-noFit"), !autoFit), "".concat(prefixCls, "-nodata"), !(dataSource !== null && dataSource !== void 0 && dataSource.length)), "".concat(prefixCls, "-userAgent-mac"), isMac), "".concat(prefixCls, "-striped"), tableStyles.includes('striped')), "".concat(prefixCls, "-no-border"), !tableStyles.includes('border')), "".concat(prefixCls, "-no-data"), (dataSource === null || dataSource === void 0 ? void 0 : dataSource.length) === 0), "".concat(prefixCls, "-header-background"), tableStyles.includes('header-background')), "".concat(prefixCls, "-no-header-background"), !tableStyles.includes('header-background')), hashId),
370
370
  ref: rootDomRef,
371
371
  style: style,
372
372
  children: [toolbarRender, alertRender, /*#__PURE__*/(0, _jsxRuntime.jsx)(_antd.Table, _objectSpread(_objectSpread({
@@ -14,7 +14,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
14
14
  var genVtxStyle = function genVtxStyle(token) {
15
15
  var componentCls = token.componentCls,
16
16
  antCls = token.antCls;
17
- return _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, componentCls, _defineProperty({
17
+ return _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, componentCls, _defineProperty({
18
18
  position: 'relative',
19
19
  // overflow: 'hidden',
20
20
  display: 'flex',
@@ -32,7 +32,10 @@ var genVtxStyle = function genVtxStyle(token) {
32
32
  flex: 1
33
33
  }, '.ant-table-container', _defineProperty(_defineProperty({}, '.ant-table-body', {
34
34
  scrollbarWidth: "thin"
35
- }), '.ant-table-content', _defineProperty({}, 'table', {
35
+ }), '.ant-table-content', _defineProperty({
36
+ // height: '100%',
37
+ scrollbarWidth: "thin"
38
+ }, 'table', {
36
39
  // height: '100%',
37
40
  minWidth: "calc(100% - 1px) !important"
38
41
  })))))), '.ant-table', _defineProperty(_defineProperty(_defineProperty({}, '.ant-table-header', _defineProperty({}, '.ant-table-thead', {
@@ -50,8 +53,8 @@ var genVtxStyle = function genVtxStyle(token) {
50
53
  left: 0,
51
54
  backgroundColor: 'transparent',
52
55
  borderTop: 'none',
53
- borderInlineEnd: "var(--ant-line-width) var(--ant-line-type) var(--ant-table-border-color)",
54
- borderBottom: "var(--ant-line-width) var(--ant-line-type) var(--ant-table-border-color)",
56
+ // borderInlineEnd: "var(--ant-line-width) var(--ant-line-type) var(--ant-table-border-color)",
57
+ // borderBottom: "var(--ant-line-width) var(--ant-line-type) var(--ant-table-border-color)",
55
58
  '>td.ant-table-cell': {
56
59
  padding: 0,
57
60
  width: '100%',
@@ -107,7 +110,17 @@ var genVtxStyle = function genVtxStyle(token) {
107
110
  '>tr>th': {
108
111
  background: token.colorBgLayoutTable
109
112
  }
110
- })))));
113
+ }))))), "".concat(componentCls, "-no-header-background"), _defineProperty({}, "".concat(antCls, "-table-wrapper "), _defineProperty({}, '.ant-table-thead', {
114
+ '>tr>th': {
115
+ background: token.colorBgContainer
116
+ }
117
+ }))), "".concat(componentCls, "-no-data"), _defineProperty({}, "".concat(antCls, "-table-wrapper"), _defineProperty({}, '.ant-spin', _defineProperty({}, '.ant-spin-container', _defineProperty({}, '.ant-table', _defineProperty({}, '.ant-table-container', _defineProperty({}, '.ant-table-content', _defineProperty({
118
+ borderRight: "var(--ant-line-width) var(--ant-line-type) var(--ant-table-border-color)",
119
+ borderBottom: "var(--ant-line-width) var(--ant-line-type) var(--ant-table-border-color)"
120
+ }, 'table', {})))))))), "".concat(componentCls, "-no-data").concat(componentCls, "-no-border"), _defineProperty({}, "".concat(antCls, "-table-wrapper"), _defineProperty({}, '.ant-spin', _defineProperty({}, '.ant-spin-container', _defineProperty({}, '.ant-table', _defineProperty({}, '.ant-table-container', _defineProperty({}, '.ant-table-content', {
121
+ borderRight: "none",
122
+ borderBottom: "none"
123
+ })))))));
111
124
  };
112
125
  function useStyle(prefix) {
113
126
  return (0, _vtxProvider.useStyle)(prefix, function (token) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vtx/components",
3
- "version": "4.0.0-beta.38",
3
+ "version": "4.0.0-beta.39",
4
4
  "description": "React components for Vortex",
5
5
  "keywords": [
6
6
  "react",