@aloudata/aloudata-design 2.12.4-beta.1 → 2.12.5

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.
@@ -23,7 +23,7 @@ export declare function getTableColumns<TDataItem extends object>({ columns, con
23
23
  render?: ((text: any, record: TDataItem, rowIndex: number) => import("react").ReactNode) | undefined;
24
24
  ellipsis?: boolean | undefined;
25
25
  noPadding?: boolean | undefined;
26
- align?: "center" | "left" | "right" | undefined;
26
+ align?: "left" | "right" | "center" | undefined;
27
27
  fixed?: "left" | "right" | undefined;
28
28
  sortOrder?: "ascend" | "descend" | null | undefined;
29
29
  };
@@ -115,8 +115,7 @@ export default function useRowSelection(props) {
115
115
  checked: isChecked
116
116
  }, checkboxProps)));
117
117
  },
118
- fixed: rowSelection.fixed ? 'left' : undefined,
119
- align: 'left'
118
+ fixed: rowSelection.fixed ? 'left' : undefined
120
119
  };
121
120
  var selectedRowKeysInCurrPage = getDataWithoutDisabled(data, rowSelection.getCheckboxProps).map(function (record) {
122
121
  return getRowKey(record, rowKey);
@@ -123,7 +123,7 @@ function Table(props, ref) {
123
123
  changeIsPing();
124
124
  }, [changeIsPing, totalColumnsWidth]);
125
125
  var headerContent = /*#__PURE__*/React.createElement("div", {
126
- className: classnames(prefixCls('header'), (_classnames = {}, _defineProperty(_classnames, prefixCls('overflow-x'), true), _defineProperty(_classnames, prefixCls('sticky'), isStickyWork), _classnames)),
126
+ className: classnames(prefixCls('header'), (_classnames = {}, _defineProperty(_classnames, prefixCls('overflow-x'), true), _defineProperty(_classnames, prefixCls('sticky'), isStickyWork), _defineProperty(_classnames, prefixCls('resizing'), tableInstance.getState().columnSizingInfo.isResizingColumn), _classnames)),
127
127
  ref: headerRef,
128
128
  style: headerStyle
129
129
  }, _.map(headerGroups, function (headerGroup) {
@@ -134,7 +134,6 @@ function Table(props, ref) {
134
134
  width: totalColumnsWidth
135
135
  }
136
136
  }, _.map(headerGroup.headers, function (header, index) {
137
- var _classnames2;
138
137
  // 选择行的列不能拖动宽度
139
138
  var showResizer = columnSizing && !(!!rowSelectionInfo.isRowSelectionEnabled && index === 0);
140
139
  var _getColumnFixedInfo = getColumnFixedInfo(index, true),
@@ -149,7 +148,7 @@ function Table(props, ref) {
149
148
  }, flexRender(header.column.columnDef.header, header.getContext()), showResizer && /*#__PURE__*/React.createElement("div", {
150
149
  onMouseDown: header.getResizeHandler(),
151
150
  onTouchStart: header.getResizeHandler(),
152
- className: classnames(prefixCls('resizer'), (_classnames2 = {}, _defineProperty(_classnames2, prefixCls('self-resizing'), header.column.getIsResizing()), _defineProperty(_classnames2, prefixCls('resizing'), tableInstance.getState().columnSizingInfo.isResizingColumn), _classnames2))
151
+ className: classnames(prefixCls('resizer'), _defineProperty({}, prefixCls('self-resizing'), header.column.getIsResizing()))
153
152
  }));
154
153
  }), y !== undefined && /*#__PURE__*/React.createElement("div", {
155
154
  className: prefixCls('header-scroll-placeholder'),
@@ -7,6 +7,7 @@
7
7
  @import '../../TextLink/style/index.less';
8
8
 
9
9
  @header-height: 40px;
10
+ @fixed-z-index: 2;
10
11
 
11
12
  .ald-table-container {
12
13
  display: flex;
@@ -38,29 +39,8 @@
38
39
  flex-direction: column;
39
40
  border-spacing: 0;
40
41
 
41
- .ald-table-spin {
42
- position: absolute;
43
- top: 0;
44
- left: 0;
45
- width: 100%;
46
- height: 300px;
47
- max-height: 100%;
48
- z-index: 2;
49
-
50
- .spinner-mask {
51
- opacity: 0;
52
- }
53
- }
54
-
55
- .ald-table-spin-mask {
56
- position: absolute;
57
- top: 0;
58
- left: 0;
59
- width: 100%;
60
- height: 100%;
61
- background: #fff;
62
- opacity: 0.4;
63
- z-index: 1;
42
+ .spinner-mask {
43
+ z-index: @fixed-z-index + 1;
64
44
  }
65
45
  }
66
46
 
@@ -114,7 +94,7 @@
114
94
  &.ald-table-fixed-left,
115
95
  &.ald-table-fixed-right {
116
96
  position: sticky;
117
- z-index: 2;
97
+ z-index: @fixed-z-index;
118
98
  }
119
99
  }
120
100
 
@@ -331,6 +311,10 @@
331
311
 
332
312
  .ald-table-header {
333
313
  background: var(--alias-colors-bg-skeleton-strong, #f3f4f6);
314
+
315
+ &.ald-table-resizing {
316
+ cursor: col-resize;
317
+ }
334
318
  }
335
319
 
336
320
  .ald-table-header-scroll-placeholder {