dtable-ui-component 5.0.9-beta.2 → 5.0.9-beta.4

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 (110) hide show
  1. package/lib/AutoNumberFormatter/index.js +3 -5
  2. package/lib/ButtonFormatter/index.js +5 -9
  3. package/lib/CTimeFormatter/index.js +3 -5
  4. package/lib/CheckboxEditor/index.js +12 -15
  5. package/lib/CheckboxFormatter/index.js +5 -7
  6. package/lib/CollaboratorEditor/index.js +37 -46
  7. package/lib/CollaboratorEditor/mb-collaborator-editor-popover/index.js +47 -60
  8. package/lib/CollaboratorEditor/pc-collaborator-editor-popover/index.js +31 -37
  9. package/lib/CollaboratorFormatter/index.js +7 -8
  10. package/lib/CollaboratorItem/index.js +16 -21
  11. package/lib/CollapsibleSettingLayout/index.js +14 -18
  12. package/lib/CreatorFormatter/index.js +7 -8
  13. package/lib/DTableCommonAddTool/index.js +7 -10
  14. package/lib/DTableCustomizeCollaboratorSelect/index.js +32 -38
  15. package/lib/DTableCustomizeSelect/index.js +44 -51
  16. package/lib/DTableFiltersPopover/index.js +41 -46
  17. package/lib/DTableFiltersPopover/utils/filter-item-utils.js +51 -67
  18. package/lib/DTableFiltersPopover/widgets/collaborator-filter/index.js +49 -64
  19. package/lib/DTableFiltersPopover/widgets/department-select-filter/department-multiple-select-filter.js +32 -38
  20. package/lib/DTableFiltersPopover/widgets/department-select-filter/department-single-select-filter.js +34 -42
  21. package/lib/DTableFiltersPopover/widgets/filter-calendar.js +31 -35
  22. package/lib/DTableFiltersPopover/widgets/filter-item.js +76 -92
  23. package/lib/DTableFiltersPopover/widgets/filter-list/index.js +17 -19
  24. package/lib/DTableFiltersPopover/widgets/rate-item.js +9 -12
  25. package/lib/DTablePopover/index.js +6 -9
  26. package/lib/DTableRadio/index.js +17 -20
  27. package/lib/DTableSearchInput/index.js +18 -22
  28. package/lib/DTableSelect/dtable-select-label.js +7 -12
  29. package/lib/DTableSelect/index.js +1 -2
  30. package/lib/DTableSelect/utils.js +13 -26
  31. package/lib/DTableSwitch/index.js +16 -20
  32. package/lib/DateEditor/index.js +36 -46
  33. package/lib/DateEditor/mb-date-editor-popover/index.js +63 -80
  34. package/lib/DateEditor/pc-date-editor-popover.js +22 -25
  35. package/lib/DateFormatter/index.js +3 -5
  36. package/lib/Department-editor/department-multiple-select/index.js +42 -49
  37. package/lib/Department-editor/department-single-select.js +54 -70
  38. package/lib/Department-editor/index.js +14 -18
  39. package/lib/Department-editor/selected-departments/index.js +44 -54
  40. package/lib/DepartmentSelectFilter/index.js +1 -8
  41. package/lib/DepartmentSingleSelectFormatter/index.js +9 -13
  42. package/lib/DigitalSignFormatter/index.js +17 -21
  43. package/lib/DurationFormatter/index.js +5 -7
  44. package/lib/EditEditorButton/index.js +3 -5
  45. package/lib/EmailFormatter/index.js +3 -5
  46. package/lib/FieldDisplaySetting/field-item.js +19 -25
  47. package/lib/FieldDisplaySetting/index.js +38 -47
  48. package/lib/FileEditor/index.js +7 -10
  49. package/lib/FileFormatter/index.js +15 -18
  50. package/lib/FileItemFormatter/index.js +1 -2
  51. package/lib/FileUploader/index.js +1 -2
  52. package/lib/FormulaFormatter/index.js +14 -21
  53. package/lib/GeolocationFormatter/index.js +6 -8
  54. package/lib/HtmlLongTextFormatter/index.js +1 -2
  55. package/lib/ImageFormatter/images-lazy-load.js +6 -7
  56. package/lib/ImageFormatter/index.js +29 -35
  57. package/lib/ImagePreviewerLightbox/index.js +8 -12
  58. package/lib/LastModifierFormatter/index.js +7 -8
  59. package/lib/LinkEditor/index.js +32 -38
  60. package/lib/LinkEditor/link-editor-option.js +20 -25
  61. package/lib/LinkEditor/mb-link-editor-popover/index.js +41 -53
  62. package/lib/LinkEditor/pc-link-editor-popover/index.js +33 -41
  63. package/lib/LinkFormatter/index.js +10 -13
  64. package/lib/Loading/index.js +1 -2
  65. package/lib/LongTextFormatter/index.js +2 -3
  66. package/lib/MBEditorHeader/index.js +14 -19
  67. package/lib/MTimeFormatter/index.js +3 -5
  68. package/lib/MultipleSelectEditor/index.js +37 -43
  69. package/lib/MultipleSelectFormatter/index.js +7 -8
  70. package/lib/NotificationPopover/index.js +32 -43
  71. package/lib/NumberEditor/index.js +20 -24
  72. package/lib/NumberFormatter/index.js +3 -5
  73. package/lib/RadioGroup/index.css +48 -0
  74. package/lib/RadioGroup/index.js +58 -0
  75. package/lib/RateFormatter/index.js +6 -7
  76. package/lib/RoleStatusEditor/index.js +30 -35
  77. package/lib/RowExpandEmailFormatter/index.js +8 -11
  78. package/lib/RowExpandFileFormatter/index.js +13 -14
  79. package/lib/RowExpandFileFormatter/row-expand-file-item-formatter.js +36 -43
  80. package/lib/RowExpandFormatter/index.js +112 -129
  81. package/lib/RowExpandFormulaFormatter/index.js +29 -37
  82. package/lib/RowExpandImageFormatter/index.js +26 -29
  83. package/lib/RowExpandImageFormatter/row-expand-image-item-formatter.js +39 -47
  84. package/lib/RowExpandLinkFormatter/collaborator-item-formatter.js +1 -2
  85. package/lib/RowExpandLinkFormatter/index.js +67 -70
  86. package/lib/RowExpandRateFormatter/index.js +6 -7
  87. package/lib/RowExpandUrlFormatter/index.js +8 -11
  88. package/lib/SelectItem/index.js +3 -5
  89. package/lib/SelectOptionGroup/index.js +31 -38
  90. package/lib/SelectOptionGroup/option.js +3 -5
  91. package/lib/SimpleLongTextFormatter/index.js +30 -39
  92. package/lib/SimpleLongTextFormatter/widgets/LongTextPreview.js +8 -11
  93. package/lib/SimpleLongTextFormatter/widgets/dtable-markdown-viewer.js +2 -3
  94. package/lib/SingleSelectEditor/index.js +34 -42
  95. package/lib/SingleSelectFormatter/index.js +4 -6
  96. package/lib/TextEditor/index.js +1 -2
  97. package/lib/TextFormatter/index.js +3 -5
  98. package/lib/UrlFormatter/index.js +3 -5
  99. package/lib/common/delete-tip.js +19 -27
  100. package/lib/formatterConfig/base-formatter-config.js +22 -23
  101. package/lib/formatterConfig/index.js +2 -3
  102. package/lib/index.js +8 -1
  103. package/lib/select-editor/mb-select-editor-popover/index.js +64 -84
  104. package/lib/select-editor/pc-select-editor-popover/index.js +39 -50
  105. package/lib/select-editor/select-editor-option.js +19 -24
  106. package/lib/toaster/alert.js +16 -25
  107. package/lib/toaster/toast.js +24 -28
  108. package/lib/toaster/toastManager.js +13 -16
  109. package/lib/toaster/toaster.js +1 -2
  110. package/package.json +1 -1
@@ -11,7 +11,6 @@ var _reactstrap = require("reactstrap");
11
11
  var _reactResponsive = _interopRequireDefault(require("react-responsive"));
12
12
  var _lang = require("../lang");
13
13
  var _deleteTip = _interopRequireDefault(require("../common/delete-tip"));
14
- var _jsxRuntime = require("react/jsx-runtime");
15
14
  class RowExpandImageItemFormatter extends _react.Component {
16
15
  constructor(props) {
17
16
  super(props);
@@ -65,52 +64,45 @@ class RowExpandImageItemFormatter extends _react.Component {
65
64
  } = this.props;
66
65
  const id = 'image-list-preview-item' + column.key + index;
67
66
  const name = decodeURI(url.slice(url.lastIndexOf('/') + 1));
68
- return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
69
- children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
70
- className: "row-expand-item-image",
71
- id: id,
72
- onClick: this.onClickImage,
73
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("img", {
74
- src: url,
75
- id: "item-image-".concat(index),
76
- alt: name
77
- }), /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
78
- className: "dtable-image-icons-choice",
79
- children: [downloadFile && /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
80
- className: "image-icon",
81
- onClick: this.onClickDownload,
82
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)("i", {
83
- className: "dtable-font dtable-icon-download"
84
- })
85
- }), !readOnly && deleteFile && /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
86
- className: "image-icon",
87
- onClick: this.onClickDelete,
88
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)("i", {
89
- className: "dtable-font dtable-icon-fork-number"
90
- })
91
- })]
92
- })]
93
- }, "image-".concat(index)), this.state.isDeleteTipOpen && /*#__PURE__*/(0, _jsxRuntime.jsx)(_deleteTip.default, {
94
- position: this.position,
95
- toggle: this.closeDeleteTip,
96
- onDelete: this.onDelete,
97
- deleteTip: (0, _lang.getLocale)('Are_you_sure_you_want_to_delete_this_image')
98
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactResponsive.default, {
99
- query: '(min-width: 768px)',
100
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactstrap.Tooltip, {
101
- placement: "bottom",
102
- isOpen: this.state.isTooltipOpen,
103
- toggle: this.toggleTooltip,
104
- target: id,
105
- delay: {
106
- show: 0,
107
- hide: 0
108
- },
109
- fade: false,
110
- children: name
111
- })
112
- })]
113
- });
67
+ return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement("div", {
68
+ key: "image-".concat(index),
69
+ className: "row-expand-item-image",
70
+ id: id,
71
+ onClick: this.onClickImage
72
+ }, /*#__PURE__*/_react.default.createElement("img", {
73
+ src: url,
74
+ id: "item-image-".concat(index),
75
+ alt: name
76
+ }), /*#__PURE__*/_react.default.createElement("div", {
77
+ className: "dtable-image-icons-choice"
78
+ }, downloadFile && /*#__PURE__*/_react.default.createElement("span", {
79
+ className: "image-icon",
80
+ onClick: this.onClickDownload
81
+ }, /*#__PURE__*/_react.default.createElement("i", {
82
+ className: "dtable-font dtable-icon-download"
83
+ })), !readOnly && deleteFile && /*#__PURE__*/_react.default.createElement("span", {
84
+ className: "image-icon",
85
+ onClick: this.onClickDelete
86
+ }, /*#__PURE__*/_react.default.createElement("i", {
87
+ className: "dtable-font dtable-icon-fork-number"
88
+ })))), this.state.isDeleteTipOpen && /*#__PURE__*/_react.default.createElement(_deleteTip.default, {
89
+ position: this.position,
90
+ toggle: this.closeDeleteTip,
91
+ onDelete: this.onDelete,
92
+ deleteTip: (0, _lang.getLocale)('Are_you_sure_you_want_to_delete_this_image')
93
+ }), /*#__PURE__*/_react.default.createElement(_reactResponsive.default, {
94
+ query: '(min-width: 768px)'
95
+ }, /*#__PURE__*/_react.default.createElement(_reactstrap.Tooltip, {
96
+ placement: "bottom",
97
+ isOpen: this.state.isTooltipOpen,
98
+ toggle: this.toggleTooltip,
99
+ target: id,
100
+ delay: {
101
+ show: 0,
102
+ hide: 0
103
+ },
104
+ fade: false
105
+ }, name)));
114
106
  }
115
107
  }
116
108
  exports.default = RowExpandImageItemFormatter;
@@ -9,7 +9,6 @@ exports.default = void 0;
9
9
  var _react = _interopRequireWildcard(require("react"));
10
10
  var _dtableUtils = require("dtable-utils");
11
11
  var _CollaboratorItem = _interopRequireDefault(require("../CollaboratorItem"));
12
- var _jsxRuntime = require("react/jsx-runtime");
13
12
  class CollaboratorItemFormatter extends _react.Component {
14
13
  constructor(_props) {
15
14
  super(_props);
@@ -116,7 +115,7 @@ class CollaboratorItemFormatter extends _react.Component {
116
115
  if (!isDataLoaded || !cellValue || !collaborator) {
117
116
  return this.props.renderEmpty();
118
117
  }
119
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_CollaboratorItem.default, {
118
+ return /*#__PURE__*/_react.default.createElement(_CollaboratorItem.default, {
120
119
  collaborator: collaborator,
121
120
  enableDeleteCollaborator: false
122
121
  });
@@ -16,7 +16,6 @@ var _collaboratorItemFormatter = _interopRequireDefault(require("./collaborator-
16
16
  var _utils = require("./utils");
17
17
  var _valueDisplayUtils = require("./value-display-utils");
18
18
  require("./index.css");
19
- var _jsxRuntime = require("react/jsx-runtime");
20
19
  class RowExpandLinkFormatter extends _react.Component {
21
20
  render() {
22
21
  const props = this.props;
@@ -54,98 +53,96 @@ class RowExpandLinkFormatter extends _react.Component {
54
53
  case _constants.CellType.DURATION:
55
54
  case _constants.CellType.NUMBER:
56
55
  {
57
- return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
58
- className: containerClassName,
59
- children: cellValue.map((value, index) => {
60
- if (!value) return null;
61
- return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
62
- className: "row-expand-link-item",
63
- children: value
64
- }, "link-".concat(displayColumnType, "-").concat(index));
65
- })
66
- });
56
+ return /*#__PURE__*/_react.default.createElement("div", {
57
+ className: containerClassName
58
+ }, cellValue.map((value, index) => {
59
+ if (!value) return null;
60
+ return /*#__PURE__*/_react.default.createElement("div", {
61
+ key: "link-".concat(displayColumnType, "-").concat(index),
62
+ className: "row-expand-link-item"
63
+ }, value);
64
+ }));
67
65
  }
68
66
  case _constants.CellType.DATE:
69
67
  {
70
- return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
71
- className: containerClassName,
72
- children: cellValue.map((value, index) => {
73
- if (!value || typeof value !== 'string') return null;
74
- const {
75
- format
76
- } = displayColumnData || {};
77
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_DateFormatter.default, {
78
- value: value,
79
- format: format,
80
- containerClassName: "row-expand-link-item"
81
- }, "link-".concat(displayColumnType, "-").concat(index));
82
- })
83
- });
68
+ return /*#__PURE__*/_react.default.createElement("div", {
69
+ className: containerClassName
70
+ }, cellValue.map((value, index) => {
71
+ if (!value || typeof value !== 'string') return null;
72
+ const {
73
+ format
74
+ } = displayColumnData || {};
75
+ return /*#__PURE__*/_react.default.createElement(_DateFormatter.default, {
76
+ key: "link-".concat(displayColumnType, "-").concat(index),
77
+ value: value,
78
+ format: format,
79
+ containerClassName: "row-expand-link-item"
80
+ });
81
+ }));
84
82
  }
85
83
  case _constants.CellType.CTIME:
86
84
  {
87
- return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
88
- className: containerClassName,
89
- children: cellValue.map((value, index) => {
90
- if (!value) return null;
91
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_CTimeFormatter.default, {
92
- value: value,
93
- containerClassName: "row-expand-link-item"
94
- }, "link-".concat(displayColumnType, "-").concat(index));
95
- })
96
- });
85
+ return /*#__PURE__*/_react.default.createElement("div", {
86
+ className: containerClassName
87
+ }, cellValue.map((value, index) => {
88
+ if (!value) return null;
89
+ return /*#__PURE__*/_react.default.createElement(_CTimeFormatter.default, {
90
+ key: "link-".concat(displayColumnType, "-").concat(index),
91
+ value: value,
92
+ containerClassName: "row-expand-link-item"
93
+ });
94
+ }));
97
95
  }
98
96
  case _constants.CellType.MTIME:
99
97
  {
100
- return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
101
- className: containerClassName,
102
- children: cellValue.map((value, index) => {
103
- if (!value) return null;
104
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_MTimeFormatter.default, {
105
- value: value,
106
- containerClassName: "row-expand-link-item"
107
- }, "link-".concat(displayColumnType, "-").concat(index));
108
- })
109
- });
98
+ return /*#__PURE__*/_react.default.createElement("div", {
99
+ className: containerClassName
100
+ }, cellValue.map((value, index) => {
101
+ if (!value) return null;
102
+ return /*#__PURE__*/_react.default.createElement(_MTimeFormatter.default, {
103
+ key: "link-".concat(displayColumnType, "-").concat(index),
104
+ value: value,
105
+ containerClassName: "row-expand-link-item"
106
+ });
107
+ }));
110
108
  }
111
109
  case _constants.CellType.CREATOR:
112
110
  case _constants.CellType.LAST_MODIFIER:
113
111
  {
114
- return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
115
- className: "dtable-ui cell-formatter-container collaborator-formatter sql-query-collaborator-formatter",
116
- children: cellValue.map((value, index) => {
117
- if (!value) return null;
118
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_collaboratorItemFormatter.default, {
119
- cellValue: value,
120
- collaborators: collaborators,
121
- context: props.context,
122
- renderEmpty: props.renderEmpty
123
- }, "link-".concat(displayColumnType, "-").concat(index));
124
- })
125
- });
112
+ return /*#__PURE__*/_react.default.createElement("div", {
113
+ className: "dtable-ui cell-formatter-container collaborator-formatter sql-query-collaborator-formatter"
114
+ }, cellValue.map((value, index) => {
115
+ if (!value) return null;
116
+ return /*#__PURE__*/_react.default.createElement(_collaboratorItemFormatter.default, {
117
+ key: "link-".concat(displayColumnType, "-").concat(index),
118
+ cellValue: value,
119
+ collaborators: collaborators,
120
+ context: props.context,
121
+ renderEmpty: props.renderEmpty
122
+ });
123
+ }));
126
124
  }
127
125
  case _constants.CellType.SINGLE_SELECT:
128
126
  {
129
127
  const options = displayColumnData && Array.isArray(displayColumnData.options) ? displayColumnData.options : [];
130
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_MultipleSelectFormatter.default, {
128
+ return /*#__PURE__*/_react.default.createElement(_MultipleSelectFormatter.default, {
131
129
  value: cellValue,
132
130
  options: options || []
133
131
  });
134
132
  }
135
133
  case _constants.CellType.FORMULA:
136
134
  {
137
- return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
138
- className: containerClassName,
139
- children: cellValue.map((value, index) => {
140
- if (!value) return null;
141
- return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
142
- className: "row-expand-link-item",
143
- children: (0, _valueDisplayUtils.getCellDisplayValue)({
144
- [displayColumn.key]: value
145
- }, displayColumn, collaborators)
146
- }, "link-".concat(displayColumnType, "-").concat(index));
147
- })
148
- });
135
+ return /*#__PURE__*/_react.default.createElement("div", {
136
+ className: containerClassName
137
+ }, cellValue.map((value, index) => {
138
+ if (!value) return null;
139
+ return /*#__PURE__*/_react.default.createElement("div", {
140
+ key: "link-".concat(displayColumnType, "-").concat(index),
141
+ className: "row-expand-link-item"
142
+ }, (0, _valueDisplayUtils.getCellDisplayValue)({
143
+ [displayColumn.key]: value
144
+ }, displayColumn, collaborators));
145
+ }));
149
146
  }
150
147
  default:
151
148
  {
@@ -8,7 +8,6 @@ exports.default = void 0;
8
8
  var _react = _interopRequireDefault(require("react"));
9
9
  var _classnames = _interopRequireDefault(require("classnames"));
10
10
  require("./index.css");
11
- var _jsxRuntime = require("react/jsx-runtime");
12
11
  class RateExpendRateFormatter extends _react.default.Component {
13
12
  constructor() {
14
13
  super(...arguments);
@@ -27,10 +26,11 @@ class RateExpendRateFormatter extends _react.default.Component {
27
26
  let style = {
28
27
  color: value >= i + 1 ? rate_style_color : '#e5e5e5'
29
28
  };
30
- rateList.push( /*#__PURE__*/(0, _jsxRuntime.jsx)("i", {
29
+ rateList.push( /*#__PURE__*/_react.default.createElement("i", {
30
+ key: "dtable-ui-component-rate-".concat(i),
31
31
  className: "dtable-font ".concat(rate_style_type),
32
32
  style: style
33
- }, "dtable-ui-component-rate-".concat(i)));
33
+ }));
34
34
  }
35
35
  return rateList;
36
36
  };
@@ -41,10 +41,9 @@ class RateExpendRateFormatter extends _react.default.Component {
41
41
  } = this.props;
42
42
  const className = (0, _classnames.default)('dtable-ui cell-formatter-container rate-formatter', containerClassName);
43
43
  const rateList = this.getRateList();
44
- return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
45
- className: className,
46
- children: rateList
47
- });
44
+ return /*#__PURE__*/_react.default.createElement("div", {
45
+ className: className
46
+ }, rateList);
48
47
  }
49
48
  }
50
49
  RateExpendRateFormatter.defaultProps = {
@@ -10,7 +10,6 @@ var _classnames = _interopRequireDefault(require("classnames"));
10
10
  var _toaster = _interopRequireDefault(require("../toaster"));
11
11
  var _editorUtils = require("../utils/editor-utils");
12
12
  require("./index.css");
13
- var _jsxRuntime = require("react/jsx-runtime");
14
13
  class UrlFormatter extends _react.default.Component {
15
14
  constructor() {
16
15
  super(...arguments);
@@ -39,16 +38,14 @@ class UrlFormatter extends _react.default.Component {
39
38
  value
40
39
  } = this.props;
41
40
  let classname = (0, _classnames.default)('dtable-ui cell-formatter-container url-formatter', containerClassName);
42
- return /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
43
- className: classname,
44
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
45
- className: "url-formatter-value text-truncate",
46
- children: value
47
- }), (0, _editorUtils.getTrimmedString)(value) && /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
48
- className: "dtable-font dtable-icon-url row-expand-jump-link",
49
- onClick: this.onOpenUrlLink
50
- })]
51
- });
41
+ return /*#__PURE__*/_react.default.createElement("div", {
42
+ className: classname
43
+ }, /*#__PURE__*/_react.default.createElement("span", {
44
+ className: "url-formatter-value text-truncate"
45
+ }, value), (0, _editorUtils.getTrimmedString)(value) && /*#__PURE__*/_react.default.createElement("span", {
46
+ className: "dtable-font dtable-icon-url row-expand-jump-link",
47
+ onClick: this.onOpenUrlLink
48
+ }));
52
49
  }
53
50
  }
54
51
  var _default = exports.default = UrlFormatter;
@@ -6,7 +6,6 @@ Object.defineProperty(exports, "__esModule", {
6
6
  });
7
7
  exports.default = void 0;
8
8
  var _react = _interopRequireDefault(require("react"));
9
- var _jsxRuntime = require("react/jsx-runtime");
10
9
  class SelectItem extends _react.default.PureComponent {
11
10
  constructor() {
12
11
  super(...arguments);
@@ -32,12 +31,11 @@ class SelectItem extends _react.default.PureComponent {
32
31
  fontSize
33
32
  } = this.props;
34
33
  const style = this.getStyle(option, fontSize);
35
- return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
34
+ return /*#__PURE__*/_react.default.createElement("div", {
36
35
  className: "dtable-ui select-item text-truncate",
37
36
  style: style,
38
- title: option.name,
39
- children: option.name
40
- });
37
+ title: option.name
38
+ }, option.name);
41
39
  }
42
40
  }
43
41
  exports.default = SelectItem;
@@ -13,7 +13,6 @@ var _DTableSearchInput = _interopRequireDefault(require("../DTableSearchInput"))
13
13
  var _KeyCodes = _interopRequireDefault(require("./KeyCodes"));
14
14
  var _ClickOutside = _interopRequireDefault(require("../ClickOutside"));
15
15
  require("./index.css");
16
- var _jsxRuntime = require("react/jsx-runtime");
17
16
  const OPTION_HEIGHT = 32;
18
17
  class SelectOptionGroup extends _react.Component {
19
18
  constructor(props) {
@@ -129,24 +128,23 @@ class SelectOptionGroup extends _react.Component {
129
128
  } = this.props;
130
129
  this.filterOptions = this.props.getFilterOptions(searchVal);
131
130
  if (this.filterOptions.length === 0) {
132
- return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
133
- className: "none-search-result",
134
- children: noOptionsPlaceholder
135
- });
131
+ return /*#__PURE__*/_react.default.createElement("div", {
132
+ className: "none-search-result"
133
+ }, noOptionsPlaceholder);
136
134
  }
137
135
  return this.filterOptions.map((opt, i) => {
138
136
  let key = opt.value.column ? opt.value.column.key : i;
139
137
  let isActive = this.state.activeIndex === i;
140
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_option.default, {
138
+ return /*#__PURE__*/_react.default.createElement(_option.default, {
139
+ key: key,
141
140
  index: i,
142
141
  isActive: isActive,
143
142
  value: opt.value,
144
143
  onSelectOption: onSelectOption,
145
144
  changeIndex: this.changeIndex,
146
145
  supportMultipleSelect: this.props.supportMultipleSelect,
147
- disableHover: this.state.disableHover,
148
- children: opt.label
149
- }, key);
146
+ disableHover: this.state.disableHover
147
+ }, opt.label);
150
148
  });
151
149
  };
152
150
  this.state = {
@@ -209,35 +207,30 @@ class SelectOptionGroup extends _react.Component {
209
207
  opacity: 0
210
208
  };
211
209
  }
212
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_ClickOutside.default, {
213
- onClickOutside: this.props.onClickOutside,
214
- children: /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
215
- className: (0, _classnames.default)('option-group', className ? 'option-group-' + className : '', {
216
- 'pt-0': isShowSelected,
217
- 'create-new-option-group': addOptionAble
218
- }),
219
- ref: ref => this.optionGroupRef = ref,
220
- style: style,
221
- onMouseDown: this.onMouseDown,
222
- children: [isShowSelected && /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
223
- className: "editor-list-delete mb-2",
224
- onClick: e => e.stopPropagation(),
225
- children: value.label || ''
226
- }), searchable && /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
227
- className: "option-group-search",
228
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_DTableSearchInput.default, {
229
- className: "option-search-control",
230
- placeholder: searchPlaceholder,
231
- onChange: this.onChangeSearch,
232
- autoFocus: true
233
- })
234
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
235
- className: "option-group-content",
236
- ref: ref => this.optionGroupContentRef = ref,
237
- children: this.renderOptGroup(searchVal)
238
- }), addOptionAble && AddOption]
239
- })
240
- });
210
+ return /*#__PURE__*/_react.default.createElement(_ClickOutside.default, {
211
+ onClickOutside: this.props.onClickOutside
212
+ }, /*#__PURE__*/_react.default.createElement("div", {
213
+ className: (0, _classnames.default)('option-group', className ? 'option-group-' + className : '', {
214
+ 'pt-0': isShowSelected,
215
+ 'create-new-option-group': addOptionAble
216
+ }),
217
+ ref: ref => this.optionGroupRef = ref,
218
+ style: style,
219
+ onMouseDown: this.onMouseDown
220
+ }, isShowSelected && /*#__PURE__*/_react.default.createElement("div", {
221
+ className: "editor-list-delete mb-2",
222
+ onClick: e => e.stopPropagation()
223
+ }, value.label || ''), searchable && /*#__PURE__*/_react.default.createElement("div", {
224
+ className: "option-group-search"
225
+ }, /*#__PURE__*/_react.default.createElement(_DTableSearchInput.default, {
226
+ className: "option-search-control",
227
+ placeholder: searchPlaceholder,
228
+ onChange: this.onChangeSearch,
229
+ autoFocus: true
230
+ })), /*#__PURE__*/_react.default.createElement("div", {
231
+ className: "option-group-content",
232
+ ref: ref => this.optionGroupContentRef = ref
233
+ }, this.renderOptGroup(searchVal)), addOptionAble && AddOption));
241
234
  }
242
235
  }
243
236
  var _default = exports.default = SelectOptionGroup;
@@ -6,7 +6,6 @@ Object.defineProperty(exports, "__esModule", {
6
6
  });
7
7
  exports.default = void 0;
8
8
  var _react = _interopRequireWildcard(require("react"));
9
- var _jsxRuntime = require("react/jsx-runtime");
10
9
  class Option extends _react.Component {
11
10
  constructor() {
12
11
  super(...arguments);
@@ -28,13 +27,12 @@ class Option extends _react.Component {
28
27
  };
29
28
  }
30
29
  render() {
31
- return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
30
+ return /*#__PURE__*/_react.default.createElement("div", {
32
31
  className: this.props.isActive ? 'option option-active' : 'option',
33
32
  onClick: this.onSelectOption.bind(this, this.props.value),
34
33
  onMouseEnter: this.onMouseEnter,
35
- onMouseLeave: this.onMouseLeave,
36
- children: this.props.children
37
- });
34
+ onMouseLeave: this.onMouseLeave
35
+ }, this.props.children);
38
36
  }
39
37
  }
40
38
  var _default = exports.default = Option;
@@ -11,49 +11,43 @@ var _normalizeLongTextValue = _interopRequireDefault(require("./normalize-long-t
11
11
  var _LongTextPreview = _interopRequireDefault(require("./widgets/LongTextPreview"));
12
12
  var _ModalPortal = _interopRequireDefault(require("../ModalPortal"));
13
13
  require("./index.css");
14
- var _jsxRuntime = require("react/jsx-runtime");
15
14
  class SimpleLongTextFormatter extends _react.default.Component {
16
15
  constructor(props) {
17
16
  super(props);
18
17
  this.renderLinks = value => {
19
18
  const links = value.links;
20
19
  if (!Array.isArray(links) || links.length === 0) return null;
21
- return /*#__PURE__*/(0, _jsxRuntime.jsxs)("span", {
22
- className: "long-text-links",
23
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("i", {
24
- className: "dtable-font dtable-icon-url"
25
- }), links.length]
26
- });
20
+ return /*#__PURE__*/_react.default.createElement("span", {
21
+ className: "long-text-links"
22
+ }, /*#__PURE__*/_react.default.createElement("i", {
23
+ className: "dtable-font dtable-icon-url"
24
+ }), links.length);
27
25
  };
28
26
  this.renderCheckList = value => {
29
27
  const checkList = value.checklist;
30
28
  if (!checkList || checkList.total === 0) return null;
31
- return /*#__PURE__*/(0, _jsxRuntime.jsxs)("span", {
32
- className: "long-text-check-list",
33
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("i", {
34
- className: "dtable-font dtable-icon-check-square-solid ".concat(checkList.completed === checkList.total ? 'long-text-check-list-completed' : '')
35
- }), "".concat(checkList.completed, "/").concat(checkList.total)]
36
- });
29
+ return /*#__PURE__*/_react.default.createElement("span", {
30
+ className: "long-text-check-list"
31
+ }, /*#__PURE__*/_react.default.createElement("i", {
32
+ className: "dtable-font dtable-icon-check-square-solid ".concat(checkList.completed === checkList.total ? 'long-text-check-list-completed' : '')
33
+ }), "".concat(checkList.completed, "/").concat(checkList.total));
37
34
  };
38
35
  this.renderImages = value => {
39
36
  const images = value.images;
40
37
  if (!Array.isArray(images) || images.length === 0) return null;
41
- return /*#__PURE__*/(0, _jsxRuntime.jsxs)("span", {
42
- className: "long-text-images",
43
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("img", {
44
- src: images[0],
45
- alt: ""
46
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)("i", {
47
- className: "image-number",
48
- children: images.length > 1 ? '+' + images.length : null
49
- })]
50
- });
38
+ return /*#__PURE__*/_react.default.createElement("span", {
39
+ className: "long-text-images"
40
+ }, /*#__PURE__*/_react.default.createElement("img", {
41
+ src: images[0],
42
+ alt: ""
43
+ }), /*#__PURE__*/_react.default.createElement("i", {
44
+ className: "image-number"
45
+ }, images.length > 1 ? '+' + images.length : null));
51
46
  };
52
47
  this.renderContent = value => {
53
- return /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
54
- className: "long-text-content",
55
- children: value.preview
56
- });
48
+ return /*#__PURE__*/_react.default.createElement("span", {
49
+ className: "long-text-content"
50
+ }, value.preview);
57
51
  };
58
52
  this.translateValue = () => {
59
53
  const {
@@ -136,21 +130,18 @@ class SimpleLongTextFormatter extends _react.default.Component {
136
130
  } = this.props;
137
131
  const className = (0, _classnames.default)('dtable-ui cell-formatter-container long-text-formatter', containerClassName);
138
132
  const value = this.translateValue();
139
- return /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
133
+ return /*#__PURE__*/_react.default.createElement("div", {
140
134
  className: className,
141
135
  onMouseEnter: this.onMouseEnter,
142
136
  onMouseLeave: this.onMouseLeave,
143
- ref: ref => this.ref = ref,
144
- children: [this.renderLinks(value), this.renderCheckList(value), this.renderImages(value), this.renderContent(value), isPreview && /*#__PURE__*/(0, _jsxRuntime.jsx)(_ModalPortal.default, {
145
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_LongTextPreview.default, {
146
- className: previewClassName,
147
- value: value,
148
- formatterStyle: this.formatterStyle,
149
- onMouseEnter: this.onPreviewMouseEnter,
150
- onMouseLeave: this.onPreviewMouseLeave
151
- })
152
- })]
153
- });
137
+ ref: ref => this.ref = ref
138
+ }, this.renderLinks(value), this.renderCheckList(value), this.renderImages(value), this.renderContent(value), isPreview && /*#__PURE__*/_react.default.createElement(_ModalPortal.default, null, /*#__PURE__*/_react.default.createElement(_LongTextPreview.default, {
139
+ className: previewClassName,
140
+ value: value,
141
+ formatterStyle: this.formatterStyle,
142
+ onMouseEnter: this.onPreviewMouseEnter,
143
+ onMouseLeave: this.onPreviewMouseLeave
144
+ })));
154
145
  }
155
146
  }
156
147
  SimpleLongTextFormatter.defaultProps = {