@qn-pandora/pandora-component 4.1.6 → 4.2.0

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.
Files changed (55) hide show
  1. package/CHANGELOG.json +20 -0
  2. package/CHANGELOG.md +8 -1
  3. package/es/components/Collapse/index.js +3 -2
  4. package/es/components/Collapse/style.css +1 -0
  5. package/es/components/Collapse/style.less +1 -0
  6. package/es/components/Descriptions/style.css +1 -0
  7. package/es/components/Descriptions/style.less +1 -0
  8. package/es/components/Drawer/index.d.ts +20 -1
  9. package/es/components/Drawer/index.js +53 -9
  10. package/es/components/Drawer/style.css +8 -0
  11. package/es/components/Drawer/style.less +9 -0
  12. package/es/components/RadioGroup/style.css +7 -0
  13. package/es/components/RadioGroup/style.less +9 -0
  14. package/es/components/Table/ColumnSetting/index.d.ts +16 -0
  15. package/es/components/Table/ColumnSetting/index.js +91 -0
  16. package/es/components/Table/ColumnSetting/style.css +47 -0
  17. package/es/components/Table/ColumnSetting/style.less +46 -0
  18. package/es/components/Table/index.d.ts +27 -2
  19. package/es/components/Table/index.js +127 -3
  20. package/es/components/Table/style.css +4 -0
  21. package/es/components/Table/style.less +7 -0
  22. package/es/constants/language/datetime/en.js +37 -37
  23. package/es/constants/language/table/en.js +4 -1
  24. package/es/constants/language/table/type.d.ts +3 -0
  25. package/es/constants/language/table/zh.js +4 -1
  26. package/es/index.css +108 -40
  27. package/es/index.less +4 -3
  28. package/es/style/theme.less +13 -2
  29. package/lib/components/Collapse/index.js +3 -2
  30. package/lib/components/Collapse/style.css +1 -0
  31. package/lib/components/Collapse/style.less +1 -0
  32. package/lib/components/Descriptions/style.css +1 -0
  33. package/lib/components/Descriptions/style.less +1 -0
  34. package/lib/components/Drawer/index.d.ts +20 -1
  35. package/lib/components/Drawer/index.js +53 -9
  36. package/lib/components/Drawer/style.css +8 -0
  37. package/lib/components/Drawer/style.less +9 -0
  38. package/lib/components/RadioGroup/style.css +7 -0
  39. package/lib/components/RadioGroup/style.less +9 -0
  40. package/lib/components/Table/ColumnSetting/index.d.ts +16 -0
  41. package/lib/components/Table/ColumnSetting/index.js +104 -0
  42. package/lib/components/Table/ColumnSetting/style.css +47 -0
  43. package/lib/components/Table/ColumnSetting/style.less +46 -0
  44. package/lib/components/Table/index.d.ts +27 -2
  45. package/lib/components/Table/index.js +126 -2
  46. package/lib/components/Table/style.css +4 -0
  47. package/lib/components/Table/style.less +7 -0
  48. package/lib/constants/language/datetime/en.js +37 -37
  49. package/lib/constants/language/table/en.js +4 -1
  50. package/lib/constants/language/table/type.d.ts +3 -0
  51. package/lib/constants/language/table/zh.js +4 -1
  52. package/lib/index.css +3481 -3413
  53. package/lib/index.less +4 -3
  54. package/lib/style/theme.less +13 -2
  55. package/package.json +5 -4
@@ -66,15 +66,17 @@ import * as React from 'react';
66
66
  import classnames from 'classnames';
67
67
  import { observer } from 'mobx-react';
68
68
  import { observable, action, computed } from 'mobx';
69
- import { size, xor, union, unionBy, differenceBy, get, isEqual } from 'lodash';
69
+ import { size, xor, union, unionBy, differenceBy, get, isEqual, includes } from 'lodash';
70
70
  import { Table as AntTable, Checkbox } from 'antd';
71
71
  import { ConfigContext } from 'antd/es/config-provider';
72
+ import { toaster as toasterStore } from '@qn-pandora/app-sdk';
72
73
  import { EmptyIcon } from '@qn-pandora/pandora-component-icons';
73
74
  import bind from '../../utils/bind';
74
75
  import { formatString } from '../../utils/language';
75
76
  import { SDK_PREFIX } from '../../constants/style';
76
77
  import { TableLocale } from '../../constants/language/table/type';
77
78
  import { ColumnTag } from './ColumnTag/ColumnTag';
79
+ import ColumnSetting from './ColumnSetting';
78
80
  /**
79
81
  * pandora2.0风格的表格
80
82
  */
@@ -84,6 +86,7 @@ var Table = /** @class */ (function (_super) {
84
86
  var _this = _super !== null && _super.apply(this, arguments) || this;
85
87
  _this.indeterminate = false;
86
88
  _this.checkAll = false;
89
+ _this.hiddenColumn = _this.props.hiddenColumns;
87
90
  return _this;
88
91
  }
89
92
  Table.prototype.UNSAFE_componentWillReceiveProps = function (nextProps) {
@@ -114,6 +117,9 @@ var Table = /** @class */ (function (_super) {
114
117
  : selectedRowsOfCurrentPage);
115
118
  }
116
119
  }
120
+ if (isEqual(nextProps.hiddenColumns, this.props.hiddenColumns)) {
121
+ this.setHiddenColumn(nextProps.hiddenColumns);
122
+ }
117
123
  };
118
124
  Object.defineProperty(Table.prototype, "selectedRowKeys", {
119
125
  get: function () {
@@ -174,6 +180,88 @@ var Table = /** @class */ (function (_super) {
174
180
  enumerable: true,
175
181
  configurable: true
176
182
  });
183
+ Object.defineProperty(Table.prototype, "columnsSettingOptions", {
184
+ // 列设置 options
185
+ get: function () {
186
+ var options = [];
187
+ var _a = this.props.columns, columns = _a === void 0 ? [] : _a;
188
+ columns.forEach(function (col) {
189
+ if (col.key &&
190
+ col.key.toString().length > 0 &&
191
+ col.configurable !== false) {
192
+ options.push({
193
+ label: col.colTitle || col.title,
194
+ value: col.key.toString()
195
+ });
196
+ }
197
+ });
198
+ return options;
199
+ },
200
+ enumerable: true,
201
+ configurable: true
202
+ });
203
+ Object.defineProperty(Table.prototype, "columnKeys", {
204
+ get: function () {
205
+ var _a = this.props.columns, columns = _a === void 0 ? [] : _a;
206
+ var allKeys = [];
207
+ var unconfigableKeys = [];
208
+ var resetKeys = [];
209
+ columns.forEach(function (col) {
210
+ if (col.key) {
211
+ if (col.configurable === false) {
212
+ unconfigableKeys.push(col.key.toString());
213
+ }
214
+ else {
215
+ resetKeys.push(col.key.toString());
216
+ }
217
+ allKeys.push(col.key.toString());
218
+ }
219
+ });
220
+ return {
221
+ allKeys: allKeys,
222
+ unconfigableKeys: unconfigableKeys,
223
+ resetKeys: resetKeys
224
+ };
225
+ },
226
+ enumerable: true,
227
+ configurable: true
228
+ });
229
+ // 隐藏key
230
+ Table.prototype.handleHideColumnsChange = function (keys) {
231
+ var _a, _b;
232
+ var _c = this.columnKeys, resetKeys = _c.resetKeys, unconfigableKeys = _c.unconfigableKeys;
233
+ if (unconfigableKeys.length === 0 && isEqual(keys, resetKeys)) {
234
+ // 提示。至少需要勾选一列
235
+ return toasterStore.warning(formatString(TableLocale.hide_column_tooltip, this.context.locale));
236
+ }
237
+ this.setHiddenColumn(keys);
238
+ (_b = (_a = this.props).onHiddenColumnsChange) === null || _b === void 0 ? void 0 : _b.call(_a, keys);
239
+ };
240
+ Table.prototype.getColumns = function () {
241
+ var _a = this.props, showColumnSetting = _a.showColumnSetting, columns = _a.columns, columnSettingOverlayClass = _a.columnSettingOverlayClass;
242
+ var hiddenColumn = this.hiddenColumn || [];
243
+ if (!showColumnSetting) {
244
+ return columns;
245
+ }
246
+ // 获取到列设置的options
247
+ var columnsSettingOptions = this.columnsSettingOptions;
248
+ var selectedCols = __spread((columns || []).filter(function (item) {
249
+ if (item.configurable === false || !includes(hiddenColumn, item.key)) {
250
+ return true;
251
+ }
252
+ return false;
253
+ }));
254
+ var length = selectedCols.length;
255
+ if (length > 0) {
256
+ var lastCol = selectedCols.pop();
257
+ var title = (React.createElement("span", { className: SDK_PREFIX + "-last-column-title" },
258
+ lastCol.title,
259
+ React.createElement("span", { className: SDK_PREFIX + "-last-column-setting" },
260
+ React.createElement(ColumnSetting, { options: columnsSettingOptions, hiddenKeys: this.hiddenColumn, onHiddenKeysChange: this.handleHideColumnsChange, overlayClass: columnSettingOverlayClass }))));
261
+ selectedCols.push(__assign(__assign({}, lastCol), { title: title }));
262
+ }
263
+ return selectedCols;
264
+ };
177
265
  Table.prototype.getRowKey = function (row, index) {
178
266
  var rowKey = this.props.rowKey;
179
267
  if (typeof rowKey === 'function') {
@@ -187,6 +275,9 @@ var Table = /** @class */ (function (_super) {
187
275
  Table.prototype.setCheckAll = function (checkAll) {
188
276
  this.checkAll = checkAll;
189
277
  };
278
+ Table.prototype.setHiddenColumn = function (hiddenColumn) {
279
+ this.hiddenColumn = hiddenColumn;
280
+ };
190
281
  // 设置全选checkout的状态
191
282
  Table.prototype.setCheckboxStatus = function (selectedRowsOfCurrentPage, dataSource) {
192
283
  if (selectedRowsOfCurrentPage === void 0) { selectedRowsOfCurrentPage = []; }
@@ -258,9 +349,9 @@ var Table = /** @class */ (function (_super) {
258
349
  Table.prototype.render = function () {
259
350
  var _a, _b;
260
351
  var _this = this;
261
- var _c = this.props, className = _c.className, batchOptions = _c.batchOptions, scroll = _c.scroll, locale = _c.locale, emptyText = _c.emptyText, restProps = __rest(_c, ["className", "batchOptions", "scroll", "locale", "emptyText"]);
352
+ var _c = this.props, className = _c.className, batchOptions = _c.batchOptions, scroll = _c.scroll, locale = _c.locale, emptyText = _c.emptyText, columns = _c.columns, restProps = __rest(_c, ["className", "batchOptions", "scroll", "locale", "emptyText", "columns"]);
262
353
  return (React.createElement("div", null,
263
- React.createElement(AntTable, __assign({ scroll: scroll, locale: __assign({ emptyText: this.emptyTextComp }, locale) }, restProps, { className: classnames(SDK_PREFIX + "-table-wrapper", (_a = {}, _a[SDK_PREFIX + "-table-scrollX"] = get(scroll, 'x'), _a), (_b = {}, _b[SDK_PREFIX + "-table-scrollY"] = get(scroll, 'y'), _b), className),
354
+ React.createElement(AntTable, __assign({ scroll: scroll, locale: __assign({ emptyText: this.emptyTextComp }, locale), columns: this.getColumns() }, restProps, { className: classnames(SDK_PREFIX + "-table-wrapper", (_a = {}, _a[SDK_PREFIX + "-table-scrollX"] = get(scroll, 'x'), _a), (_b = {}, _b[SDK_PREFIX + "-table-scrollY"] = get(scroll, 'y'), _b), className),
264
355
  // 涉及到权限
265
356
  // getCheckboxProps只能放到tableBatchWrapper里,因为selectedRowKeys在那个组件计算
266
357
  rowSelection: batchOptions && this.props.rowSelection
@@ -294,6 +385,10 @@ var Table = /** @class */ (function (_super) {
294
385
  observable,
295
386
  __metadata("design:type", Object)
296
387
  ], Table.prototype, "checkAll", void 0);
388
+ __decorate([
389
+ observable.ref,
390
+ __metadata("design:type", Object)
391
+ ], Table.prototype, "hiddenColumn", void 0);
297
392
  __decorate([
298
393
  computed,
299
394
  __metadata("design:type", Object),
@@ -319,6 +414,28 @@ var Table = /** @class */ (function (_super) {
319
414
  __metadata("design:type", Object),
320
415
  __metadata("design:paramtypes", [])
321
416
  ], Table.prototype, "emptyTextComp", null);
417
+ __decorate([
418
+ computed,
419
+ __metadata("design:type", Object),
420
+ __metadata("design:paramtypes", [])
421
+ ], Table.prototype, "columnsSettingOptions", null);
422
+ __decorate([
423
+ computed,
424
+ __metadata("design:type", Object),
425
+ __metadata("design:paramtypes", [])
426
+ ], Table.prototype, "columnKeys", null);
427
+ __decorate([
428
+ bind,
429
+ __metadata("design:type", Function),
430
+ __metadata("design:paramtypes", [Array]),
431
+ __metadata("design:returntype", void 0)
432
+ ], Table.prototype, "handleHideColumnsChange", null);
433
+ __decorate([
434
+ bind,
435
+ __metadata("design:type", Function),
436
+ __metadata("design:paramtypes", []),
437
+ __metadata("design:returntype", void 0)
438
+ ], Table.prototype, "getColumns", null);
322
439
  __decorate([
323
440
  bind,
324
441
  __metadata("design:type", Function),
@@ -339,6 +456,13 @@ var Table = /** @class */ (function (_super) {
339
456
  __metadata("design:paramtypes", [Boolean]),
340
457
  __metadata("design:returntype", void 0)
341
458
  ], Table.prototype, "setCheckAll", null);
459
+ __decorate([
460
+ bind,
461
+ action,
462
+ __metadata("design:type", Function),
463
+ __metadata("design:paramtypes", [Array]),
464
+ __metadata("design:returntype", void 0)
465
+ ], Table.prototype, "setHiddenColumn", null);
342
466
  __decorate([
343
467
  bind,
344
468
  __metadata("design:type", Function),
@@ -1722,3 +1722,7 @@ textarea.ant-pagination-options-quick-jumper input {
1722
1722
  .ant-empty .ant-empty-description {
1723
1723
  color: #bfbfbf;
1724
1724
  }
1725
+ .pandora-sdk-last-column-title .pandora-sdk-last-column-setting {
1726
+ position: absolute;
1727
+ right: 12px;
1728
+ }
@@ -312,3 +312,10 @@
312
312
  color: @input-placeholder-color;
313
313
  }
314
314
  }
315
+
316
+ .@{sdk-prefix}-last-column-title {
317
+ .@{sdk-prefix}-last-column-setting {
318
+ position: absolute;
319
+ right: 12px;
320
+ }
321
+ }
@@ -1,10 +1,10 @@
1
1
  export var datetime_en = {
2
- title: 'Time range',
3
- clear: 'Clear custom',
2
+ title: 'Time Range',
3
+ clear: 'Clear Custom',
4
4
  clart_text: 'Click to apply the global time range',
5
5
  confirm: 'Confirm',
6
6
  range: {
7
- title: 'Date & Time Range',
7
+ title: 'Absolute Time',
8
8
  beforeTime: 'Before',
9
9
  afterTime: 'Since',
10
10
  betweenTime: 'Between',
@@ -13,45 +13,45 @@ export var datetime_en = {
13
13
  },
14
14
  preset: {
15
15
  title: 'Presets',
16
- m5: 'Last 5 minutes',
17
- m15: 'Last 15 minutes',
18
- m30: 'Last 30 minutes',
19
- m60: 'Last 60 minutes',
20
- h3: 'Last 3 hours',
21
- h4: 'Last 4 hours',
22
- h6: 'Last 6 hours',
23
- h12: 'Last 12 hours',
24
- h24: 'Last 24 hours',
25
- d3: 'Last 3 days',
26
- d7: 'Last 7 days',
27
- d30: 'Last 30 days',
16
+ m5: 'Last 5 Minutes',
17
+ m15: 'Last 15 Minutes',
18
+ m30: 'Last 30 Minutes',
19
+ m60: 'Last 60 Minutes',
20
+ h3: 'Last 3 Hours',
21
+ h4: 'Last 4 Hours',
22
+ h6: 'Last 6 Hours',
23
+ h12: 'Last 12 Hours',
24
+ h24: 'Last 24 Hours',
25
+ d3: 'Last 3 Days',
26
+ d7: 'Last 7 Days',
27
+ d30: 'Last 30 Days',
28
28
  today: 'Today',
29
- week: 'Week to date',
30
- month: 'Month to date',
31
- quarter: 'Quarter to date',
32
- year: 'Year to date',
29
+ week: 'This Week',
30
+ month: 'This Month',
31
+ quarter: 'This Quarter',
32
+ year: 'This Year',
33
33
  yesterDay: 'Yesterday',
34
- theDayBeforYesterDay: 'Day before Yesterday',
35
- previousWeek: 'Previous week',
36
- previousMonth: 'Previous month',
37
- previousQuarter: 'Previous quarter',
38
- previousYear: 'Previous year',
39
- AllTime: 'All time'
34
+ theDayBeforYesterDay: 'Day Before Yesterday',
35
+ previousWeek: 'Previous Week',
36
+ previousMonth: 'Previous Month',
37
+ previousQuarter: 'Previous Quarter',
38
+ previousYear: 'Previous Year',
39
+ AllTime: 'All Time'
40
40
  },
41
41
  relative: {
42
- title: 'Relative',
43
- change_time: 'Change time',
42
+ title: 'Relative Time',
43
+ change_time: 'Change Time',
44
44
  now_text: 'Now',
45
- now: 'Now (realtime)',
46
- 'now-static': 'Now (fixed)',
47
- s: ' seconds ago',
48
- m: ' minutes ago',
49
- h: ' hours ago',
50
- d: ' days ago',
51
- w: ' weeks ago',
52
- M: ' months ago',
53
- Q: ' quarters ago',
54
- y: ' years ago'
45
+ now: 'Now (Realtime)',
46
+ 'now-static': 'Now (Fixed)',
47
+ s: ' seconds Ago',
48
+ m: ' Minutes Ago',
49
+ h: ' Hours Ago',
50
+ d: ' Days Ago',
51
+ w: ' weeks Ago',
52
+ M: ' months Ago',
53
+ Q: ' quarters Ago',
54
+ y: ' years Ago'
55
55
  },
56
56
  quarter: {
57
57
  title: 'Quarter'
@@ -1,4 +1,7 @@
1
1
  export var table_en = {
2
2
  empty: 'No Data',
3
- selected: 'Selected'
3
+ selected: 'Selected',
4
+ check_all: 'Check All',
5
+ search: 'Search',
6
+ hide_column_tooltip: 'At least one column needs to be checked!'
4
7
  };
@@ -1,5 +1,8 @@
1
1
  export interface ITableLocale {
2
2
  empty: string;
3
3
  selected: string;
4
+ check_all: string;
5
+ search: string;
6
+ hide_column_tooltip: string;
4
7
  }
5
8
  export declare const TableLocale: ITableLocale;
@@ -1,4 +1,7 @@
1
1
  export var table_zh = {
2
2
  empty: '暂无数据',
3
- selected: '已选'
3
+ selected: '已选',
4
+ check_all: '全选',
5
+ search: '搜索',
6
+ hide_column_tooltip: '至少需要勾选一列!'
4
7
  };
package/es/index.css CHANGED
@@ -4460,6 +4460,7 @@ textarea.ant-input {
4460
4460
  border-bottom-width: 0px;
4461
4461
  background-color: #fafafa;
4462
4462
  font-weight: 500;
4463
+ position: relative;
4463
4464
  }
4464
4465
  .pandora-sdk-collapse-primary > .ant-collapse-item > .ant-collapse-header .pandora-sdk-header-line {
4465
4466
  width: 2px;
@@ -4876,6 +4877,7 @@ textarea.ant-input {
4876
4877
  }
4877
4878
  .pandora-sdk-descriptions .ant-descriptions-item-content {
4878
4879
  color: #333;
4880
+ overflow: hidden;
4879
4881
  }
4880
4882
  .ant-drawer {
4881
4883
  position: fixed;
@@ -5138,6 +5140,9 @@ textarea.ant-input {
5138
5140
  height: 60px;
5139
5141
  line-height: 60px;
5140
5142
  }
5143
+ .pandora-sdk-drawer .ant-drawer-header-title {
5144
+ overflow: hidden;
5145
+ }
5141
5146
  .pandora-sdk-drawer-size-small {
5142
5147
  max-width: 38%;
5143
5148
  }
@@ -5163,6 +5168,11 @@ textarea.ant-input {
5163
5168
  .pandora-sdk-drawer-close-icon {
5164
5169
  margin-left: 24px;
5165
5170
  }
5171
+ .pandora-sdk-drawer-header-full-icon {
5172
+ margin-left: 24px;
5173
+ color: #333;
5174
+ font-size: 14px;
5175
+ }
5166
5176
  .ant-upload {
5167
5177
  -webkit-box-sizing: border-box;
5168
5178
  box-sizing: border-box;
@@ -7880,12 +7890,19 @@ span.ant-radio + * {
7880
7890
  .ant-radio-button-wrapper.ant-radio-button-wrapper-rtl.ant-radio-button-wrapper-disabled:first-child {
7881
7891
  border-right-color: #d9d9d9;
7882
7892
  }
7893
+ .pandora-sdk-solid-radio-group .ant-radio-button-wrapper:not(.pandora-sdk-solid-radio-group .ant-radio-button-wrapper-checked)::before {
7894
+ background-color: #bfbfbf;
7895
+ }
7883
7896
  .pandora-sdk-solid-radio-group .ant-radio-button-wrapper {
7884
7897
  padding: 0 12px;
7885
7898
  }
7886
7899
  .pandora-sdk-solid-radio-group .ant-radio-button-wrapper:not(.pandora-sdk-solid-radio-group .ant-radio-button-wrapper-checked) {
7887
7900
  border-color: #d9d9d9;
7888
7901
  }
7902
+ .pandora-sdk-solid-radio-group .ant-radio-button-wrapper:focus-within {
7903
+ -webkit-box-shadow: unset;
7904
+ box-shadow: unset;
7905
+ }
7889
7906
  .pandora-sdk-solid-radio-group .ant-radio:not(.pandora-sdk-solid-radio-group .ant-radio-checked) .ant-radio-inner {
7890
7907
  border-color: #d9d9d9;
7891
7908
  }
@@ -12245,6 +12262,10 @@ textarea.ant-pagination-options-quick-jumper input {
12245
12262
  .ant-empty .ant-empty-description {
12246
12263
  color: #bfbfbf;
12247
12264
  }
12265
+ .pandora-sdk-last-column-title .pandora-sdk-last-column-setting {
12266
+ position: absolute;
12267
+ right: 12px;
12268
+ }
12248
12269
  .pandora-sdk-tabs .pandora-sdk-tabs-tab {
12249
12270
  position: relative;
12250
12271
  }
@@ -20389,18 +20410,6 @@ _:-ms-fullscreen .ant-picker-range-wrapper .ant-picker-year-panel .ant-picker-ce
20389
20410
  .pandora-sdk-modal-close-icon:hover {
20390
20411
  background: #f4f5f6;
20391
20412
  }
20392
- .pandora-sdk-popover-inline-list {
20393
- display: inline-block;
20394
- vertical-align: middle;
20395
- }
20396
- .pandora-sdk-popover-inline-list .pandora-sdk-popover-inline-item {
20397
- display: inline-block;
20398
- height: 100%;
20399
- margin-right: 12px;
20400
- }
20401
- .pandora-sdk-popover-inline-list .pandora-sdk-popover-inline-item i {
20402
- color: #2c6dd2;
20403
- }
20404
20413
  .pandora-sdk-item {
20405
20414
  color: #2c6dd2;
20406
20415
  cursor: pointer;
@@ -20423,6 +20432,18 @@ _:-ms-fullscreen .ant-picker-range-wrapper .ant-picker-year-panel .ant-picker-ce
20423
20432
  color: inherit;
20424
20433
  cursor: inherit;
20425
20434
  }
20435
+ .pandora-sdk-popover-inline-list {
20436
+ display: inline-block;
20437
+ vertical-align: middle;
20438
+ }
20439
+ .pandora-sdk-popover-inline-list .pandora-sdk-popover-inline-item {
20440
+ display: inline-block;
20441
+ height: 100%;
20442
+ margin-right: 12px;
20443
+ }
20444
+ .pandora-sdk-popover-inline-list .pandora-sdk-popover-inline-item i {
20445
+ color: #2c6dd2;
20446
+ }
20426
20447
  .pandora-sdk-popover-item {
20427
20448
  display: inline-block;
20428
20449
  line-height: 18px;
@@ -20452,6 +20473,53 @@ _:-ms-fullscreen .ant-picker-range-wrapper .ant-picker-year-panel .ant-picker-ce
20452
20473
  .pandora-sdk-prev-button {
20453
20474
  margin-right: 10px;
20454
20475
  }
20476
+ .pandora-sdk-table-column-setting-popover {
20477
+ padding: 10px;
20478
+ width: 100%;
20479
+ width: 600px;
20480
+ max-height: 300px;
20481
+ overflow-y: auto;
20482
+ }
20483
+ .pandora-sdk-table-column-setting-popover .pandora-sdk-table-column-setting-header {
20484
+ border-bottom: 1px solid #d9d9d9;
20485
+ display: -webkit-box;
20486
+ display: -ms-flexbox;
20487
+ display: flex;
20488
+ padding-bottom: 10px;
20489
+ }
20490
+ .pandora-sdk-table-column-setting-popover .pandora-sdk-table-column-setting-header .pandora-sdk-table-column-setting-all-check {
20491
+ line-height: 32px;
20492
+ }
20493
+ .pandora-sdk-table-column-setting-popover .pandora-sdk-table-column-setting-header .pandora-sdk-table-column-setting-search-input {
20494
+ width: 200px;
20495
+ }
20496
+ .pandora-sdk-table-column-setting-icon {
20497
+ color: #333;
20498
+ }
20499
+ .pandora-sdk-table-column-setting-content {
20500
+ display: -webkit-box;
20501
+ display: -ms-flexbox;
20502
+ display: flex;
20503
+ -ms-flex-wrap: wrap;
20504
+ flex-wrap: wrap;
20505
+ }
20506
+ .pandora-sdk-table-column-setting-content > div {
20507
+ -webkit-box-flex: 0;
20508
+ -ms-flex: 0 0 33.33%;
20509
+ flex: 0 0 33.33%;
20510
+ -webkit-box-sizing: border-box;
20511
+ box-sizing: border-box;
20512
+ position: relative;
20513
+ overflow: hidden;
20514
+ text-overflow: ellipsis;
20515
+ }
20516
+ .pandora-sdk-table-column-setting-content > div .pandora-sdk-table-column-setting-checkbox-container .pandora-sdk-table-column-setting-checkbox {
20517
+ width: 100%;
20518
+ overflow: hidden;
20519
+ }
20520
+ .pandora-sdk-table-column-setting-content > div .pandora-sdk-table-column-setting-checkbox-container .pandora-sdk-table-column-setting-checkbox > span:nth-child(2) {
20521
+ overflow: hidden;
20522
+ }
20455
20523
  .pandora-sdk-table-columnTag-groupTag {
20456
20524
  padding: 4px;
20457
20525
  height: 24px;
@@ -20658,6 +20726,34 @@ _:-ms-fullscreen .ant-picker-range-wrapper .ant-picker-year-panel .ant-picker-ce
20658
20726
  .pandora-sdk-transfer-list-body .pandora-sdk-transfer-mb10 {
20659
20727
  margin-bottom: 10px;
20660
20728
  }
20729
+ .pandora-sdk-panel-title {
20730
+ display: -webkit-box;
20731
+ display: -ms-flexbox;
20732
+ display: flex;
20733
+ -webkit-box-pack: justify;
20734
+ -ms-flex-pack: justify;
20735
+ justify-content: space-between;
20736
+ font-size: 12px;
20737
+ color: #42526e;
20738
+ cursor: pointer;
20739
+ padding-bottom: 16px;
20740
+ border-bottom: 1px solid #d9d9d9;
20741
+ }
20742
+ .pandora-sdk-panel-title .icon {
20743
+ font-size: 14px;
20744
+ }
20745
+ .pandora-sdk-panel-content {
20746
+ padding: 20px 0 0 0;
20747
+ }
20748
+ .pandora-sdk-panel-hidden {
20749
+ display: none;
20750
+ }
20751
+ .pandora-sdk-panel {
20752
+ margin-bottom: 20px;
20753
+ }
20754
+ .pandora-sdk-panel-disable {
20755
+ cursor: default;
20756
+ }
20661
20757
  .pandora-sdk-datetime-mobile-pick-range-preset-head {
20662
20758
  display: -webkit-box;
20663
20759
  display: -ms-flexbox;
@@ -20694,31 +20790,3 @@ _:-ms-fullscreen .ant-picker-range-wrapper .ant-picker-year-panel .ant-picker-ce
20694
20790
  border-radius: 2px;
20695
20791
  border: 2px solid #939393;
20696
20792
  }
20697
- .pandora-sdk-panel-title {
20698
- display: -webkit-box;
20699
- display: -ms-flexbox;
20700
- display: flex;
20701
- -webkit-box-pack: justify;
20702
- -ms-flex-pack: justify;
20703
- justify-content: space-between;
20704
- font-size: 12px;
20705
- color: #42526e;
20706
- cursor: pointer;
20707
- padding-bottom: 16px;
20708
- border-bottom: 1px solid #d9d9d9;
20709
- }
20710
- .pandora-sdk-panel-title .icon {
20711
- font-size: 14px;
20712
- }
20713
- .pandora-sdk-panel-content {
20714
- padding: 20px 0 0 0;
20715
- }
20716
- .pandora-sdk-panel-hidden {
20717
- display: none;
20718
- }
20719
- .pandora-sdk-panel {
20720
- margin-bottom: 20px;
20721
- }
20722
- .pandora-sdk-panel-disable {
20723
- cursor: default;
20724
- }
package/es/index.less CHANGED
@@ -38,15 +38,16 @@
38
38
  @import './components/DateTimePicker/BaseMobile/style.less';
39
39
  @import './components/DateTimePicker/DisplayInput/style.less';
40
40
  @import './components/Drawer/CloseIcon/style.less';
41
- @import './components/OptionList/InlineOptionList/style.less';
42
41
  @import './components/OptionList/OptionItem/style.less';
42
+ @import './components/OptionList/InlineOptionList/style.less';
43
43
  @import './components/OptionList/PopoverOptionList/style.less';
44
44
  @import './components/Steps/ControlButton/style.less';
45
+ @import './components/Table/ColumnSetting/style.less';
45
46
  @import './components/Table/ColumnTag/style.less';
46
47
  @import './components/TagList/Tag/style.less';
47
48
  @import './components/TagList/TagSwitch/style.less';
48
49
  @import './components/Timeline/TimelineItem/style.less';
49
50
  @import './components/Transfer/List/style.less';
50
51
  @import './components/Transfer/ListBody/style.less';
51
- @import './components/DateTimePicker/BaseMobile/Absolute/style.less';
52
- @import './components/DateTimePicker/Collapse/Panel/style.less';
52
+ @import './components/DateTimePicker/Collapse/Panel/style.less';
53
+ @import './components/DateTimePicker/BaseMobile/Absolute/style.less';
@@ -72,6 +72,7 @@
72
72
  @font-color-6: #666;
73
73
  @font-color-9: #999;
74
74
  @font-color-7: #333;
75
+ @font-color-8: #8c8c8c;
75
76
  @secondary-font-color: #c1c7d0; // phoenix
76
77
  @disabled-text-color: #9eaec5; // pandora-visualization pheonix
77
78
  @log-font-family: 'Droid Sans Mono', 'Consolas', 'Monaco', 'Courier New',
@@ -110,6 +111,7 @@
110
111
  @border-color-normal: #e5e5e5;
111
112
  @border-color-1: #d9d9d9;
112
113
  @border-color-2: #bfbfbf;
114
+ @border-color-3: #e9e9e9;
113
115
  @modal-header-border-color: rgba(0, 0, 0, 0.09);
114
116
 
115
117
  // icon------------------------
@@ -384,11 +386,20 @@
384
386
  @image-operator-hover-bg: rgba(51, 51, 51, 0.7);
385
387
  @agent-agent-message-background-color: #f7f7f8; // 用户框背景色
386
388
  @agent-user-avatar-color: #e6902d; // 机器人用户头像颜色;
387
-
388
- // close icon hover 颜色
389
+ @agent-no-data-background-color: #e0edf8; // close icon hover 颜色
390
+ @agent-session-title-color: #595959;
389
391
  @close-icon-hover-color: #f4f5f6;
390
392
 
391
393
  @agent-markdown-scorll-bar-color: #c9cdd4;
392
394
  @agent-markdown-header-background-color: rgb(52, 53, 65);
395
+ @agent-box-shadow-color: rgba(53, 53, 53, 0.07);
393
396
  @agent-cursor-color: #282828;
397
+ @agent-spl-background-color: #edeff2;
398
+ @agent-example-desc-color: #595959;
394
399
  @agent-input-border-color: #e9e9e9;
400
+ @agent-border-color: #e8e8e8;
401
+ @background-color-fa: #fafafa;
402
+ @background-color-f5: #f5f5f5;
403
+ @background-color-f4: #f4f5f6;
404
+ @background-linear-color: rgba(244, 245, 246, 0);
405
+ @background-color-e2: #e2e4e6;
@@ -48,15 +48,16 @@ var ECollapseType;
48
48
  function Collapse(props) {
49
49
  var children = props.children, className = props.className, _a = props.type, type = _a === void 0 ? ECollapseType.Simple : _a, expandIconPosition = props.expandIconPosition, onDelete = props.onDelete, others = __rest(props, ["children", "className", "type", "expandIconPosition", "onDelete"]);
50
50
  var position = react_1.useMemo(function () {
51
- return type === ECollapseType.Primary && !expandIconPosition
51
+ return type === ECollapseType.Primary && !expandIconPosition && !onDelete
52
52
  ? 'right'
53
53
  : expandIconPosition || 'left';
54
+ // eslint-disable-next-line react-hooks/exhaustive-deps
54
55
  }, [expandIconPosition, type]);
55
56
  var showArrow = react_1.useMemo(function () {
56
57
  return type !== ECollapseType.Dashed;
57
58
  }, [type]);
58
59
  var getExtra = react_1.useCallback(function (index) {
59
- if (type === ECollapseType.Dashed) {
60
+ if (type === ECollapseType.Dashed || onDelete) {
60
61
  return (react_1.default.createElement(icons_1.DeleteOutlined, { onClick: function () {
61
62
  if (onDelete) {
62
63
  onDelete(index);
@@ -184,6 +184,7 @@
184
184
  border-bottom-width: 0px;
185
185
  background-color: #fafafa;
186
186
  font-weight: 500;
187
+ position: relative;
187
188
  }
188
189
  .pandora-sdk-collapse-primary > .ant-collapse-item > .ant-collapse-header .pandora-sdk-header-line {
189
190
  width: 2px;
@@ -31,6 +31,7 @@
31
31
  border-bottom-width: 0px;
32
32
  background-color: @table-thead-bg;
33
33
  font-weight: 500;
34
+ position: relative;
34
35
  .@{sdk-prefix}-header-line {
35
36
  width: 2px;
36
37
  height: 16px;
@@ -328,4 +328,5 @@
328
328
  }
329
329
  .pandora-sdk-descriptions .ant-descriptions-item-content {
330
330
  color: #333;
331
+ overflow: hidden;
331
332
  }