dtable-ui-component 7.0.13 → 7.0.15

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 (308) hide show
  1. package/lib/ActionSheet/index.js +58 -49
  2. package/lib/ActivityIndicator/index.js +17 -16
  3. package/lib/AsyncUserSelect/index.js +20 -46
  4. package/lib/AsyncUserSelect/user-item.js +6 -5
  5. package/lib/AutoNumberFormatter/index.js +4 -3
  6. package/lib/Badge/index.js +27 -29
  7. package/lib/ButtonFormatter/index.js +8 -6
  8. package/lib/CTimeFormatter/index.js +4 -3
  9. package/lib/CheckboxEditor/index.js +16 -13
  10. package/lib/CheckboxEditor/mb-editor.js +20 -9
  11. package/lib/CheckboxEditor/pc-editor.js +24 -12
  12. package/lib/CheckboxFormatter/index.js +5 -4
  13. package/lib/CollaboratorEditor/index.js +17 -14
  14. package/lib/CollaboratorEditor/mb-editor/index.js +19 -11
  15. package/lib/CollaboratorEditor/pc-editor/index.js +35 -26
  16. package/lib/CollaboratorFormatter/index.js +10 -8
  17. package/lib/CollaboratorItem/index.js +5 -4
  18. package/lib/CollapsibleSettingLayout/index.js +8 -10
  19. package/lib/Comment/body/comment.js +19 -11
  20. package/lib/Comment/body/index.js +8 -8
  21. package/lib/Comment/footer/btns/index.js +7 -4
  22. package/lib/Comment/footer/index.js +21 -10
  23. package/lib/Comment/footer/input/index.js +55 -34
  24. package/lib/Comment/footer/input/participant/index.js +6 -5
  25. package/lib/Comment/footer/participants/index.js +5 -4
  26. package/lib/Comment/footer/participants/participant/index.js +3 -1
  27. package/lib/Comment/footer/participants/participant-select/index.js +26 -10
  28. package/lib/Comment/index.js +57 -39
  29. package/lib/Comment/utils/utilities.js +22 -16
  30. package/lib/CreatorFormatter/index.js +8 -6
  31. package/lib/DTableColorPicker/ColorPickerPortal/index.js +26 -28
  32. package/lib/DTableColorPicker/index.js +53 -67
  33. package/lib/DTableColorPicker/utils.js +7 -5
  34. package/lib/DTableColumnIcon/index.js +7 -6
  35. package/lib/DTableCommonAddTool/index.js +10 -8
  36. package/lib/DTableCustomFooter/index.js +3 -1
  37. package/lib/DTableCustomizeSearchInput/index.js +41 -26
  38. package/lib/DTableCustomizeSelect/index.js +24 -19
  39. package/lib/DTableDropdownItem/index.js +28 -24
  40. package/lib/DTableDropdownMenu/index.js +17 -14
  41. package/lib/DTableEmptyTip/index.js +5 -4
  42. package/lib/DTableFiltersPopover/index.js +42 -27
  43. package/lib/DTableFiltersPopover/utils/filter-item-utils.js +3 -1
  44. package/lib/DTableFiltersPopover/utils/index.js +114 -64
  45. package/lib/DTableFiltersPopover/widgets/collaborator-filter/index.js +9 -8
  46. package/lib/DTableFiltersPopover/widgets/department-select-filter/department-multiple-select-filter.js +13 -16
  47. package/lib/DTableFiltersPopover/widgets/department-select-filter/department-single-select-filter.js +15 -18
  48. package/lib/DTableFiltersPopover/widgets/filter-calendar.js +14 -8
  49. package/lib/DTableFiltersPopover/widgets/filter-group.js +57 -36
  50. package/lib/DTableFiltersPopover/widgets/filter-item.js +165 -106
  51. package/lib/DTableFiltersPopover/widgets/filter-list/index.js +162 -137
  52. package/lib/DTableFiltersPopover/widgets/rate-item.js +25 -20
  53. package/lib/DTableIcon/index.js +11 -10
  54. package/lib/DTableIcon/svg-icon.js +11 -9
  55. package/lib/DTableModalHeader/index.js +7 -7
  56. package/lib/DTablePopover/index.js +16 -12
  57. package/lib/DTableRadio/index.js +9 -10
  58. package/lib/DTableRadioGroup/index.js +20 -11
  59. package/lib/DTableSearchInput/index.js +29 -19
  60. package/lib/DTableSelect/dtable-select-label.js +6 -7
  61. package/lib/DTableSelect/index.js +26 -25
  62. package/lib/DTableSelect/select-dropdown-indicator/index.js +3 -1
  63. package/lib/DTableSelect/utils.js +83 -47
  64. package/lib/DTableSubDropdownMenu/index.js +16 -12
  65. package/lib/DTableSubDropdownToggle/index.js +16 -17
  66. package/lib/DTableSwitch/index.js +11 -12
  67. package/lib/DTableToolTip/index.js +12 -11
  68. package/lib/DateEditor/index.js +28 -30
  69. package/lib/DateEditor/mb-editor/index.js +31 -18
  70. package/lib/DateEditor/pc-editor.js +46 -27
  71. package/lib/DateFormatter/index.js +5 -4
  72. package/lib/DatePicker/index.js +15 -9
  73. package/lib/DatePicker/utils.js +7 -5
  74. package/lib/DeleteTip/index.js +6 -5
  75. package/lib/DepartmentMultipleSelectEditor/index.js +26 -28
  76. package/lib/DepartmentSelectFilter/index.js +13 -8
  77. package/lib/DepartmentSingleSelectEditor/index.js +16 -13
  78. package/lib/DepartmentSingleSelectEditor/mb-editor/index.js +49 -50
  79. package/lib/DepartmentSingleSelectEditor/pc-editor/department-single-select.js +64 -42
  80. package/lib/DepartmentSingleSelectEditor/pc-editor/index.js +19 -13
  81. package/lib/DepartmentSingleSelectFormatter/index.js +6 -4
  82. package/lib/DigitalSignEditor/index.js +16 -13
  83. package/lib/DigitalSignEditor/mb-editor/index.js +24 -16
  84. package/lib/DigitalSignEditor/pc-editor/index.js +31 -23
  85. package/lib/DigitalSignEditor/service.js +5 -3
  86. package/lib/DigitalSignEditor/signature-board/index.js +10 -7
  87. package/lib/DigitalSignEditor/utils.js +4 -2
  88. package/lib/DigitalSignFormatter/index.js +15 -12
  89. package/lib/DigitalSignFormatter/utils.js +6 -5
  90. package/lib/Drawer/index.js +3 -2
  91. package/lib/DurationEditor/index.js +31 -21
  92. package/lib/DurationFormatter/index.js +5 -4
  93. package/lib/EditEditorButton/index.js +3 -1
  94. package/lib/EmailFormatter/index.js +4 -3
  95. package/lib/FieldDisplaySetting/field-item.js +13 -13
  96. package/lib/FieldDisplaySetting/index.js +20 -20
  97. package/lib/FileEditor/files-previewer/index.js +16 -13
  98. package/lib/FileEditor/files-previewer/mb-previewer/file-previewer/index.js +20 -12
  99. package/lib/FileEditor/files-previewer/mb-previewer/index.js +8 -7
  100. package/lib/FileEditor/files-previewer/pc-previewer/file-previewer/dropdown-menu.js +4 -3
  101. package/lib/FileEditor/files-previewer/pc-previewer/file-previewer/file-name-editor/index.js +6 -5
  102. package/lib/FileEditor/files-previewer/pc-previewer/file-previewer/index.js +24 -17
  103. package/lib/FileEditor/files-previewer/pc-previewer/index.js +57 -29
  104. package/lib/FileEditor/index.js +16 -13
  105. package/lib/FileEditor/mb-editor/index.js +20 -28
  106. package/lib/FileEditor/pc-editor/addition-previewer/index.js +4 -2
  107. package/lib/FileEditor/pc-editor/addition-previewer/local-file-addition/index.js +31 -17
  108. package/lib/FileEditor/pc-editor/index.js +30 -22
  109. package/lib/FileFormatter/index.js +20 -27
  110. package/lib/FileItemFormatter/index.js +10 -7
  111. package/lib/FileUploader/index.js +46 -29
  112. package/lib/FormulaFormatter/index.js +44 -24
  113. package/lib/GeolocationEditor/index.js +32 -27
  114. package/lib/GeolocationEditor/map-editor-utils.js +23 -21
  115. package/lib/GeolocationEditor/mb-editor/country-editor.js +14 -17
  116. package/lib/GeolocationEditor/mb-editor/index.js +28 -22
  117. package/lib/GeolocationEditor/mb-editor/location-editor.js +15 -18
  118. package/lib/GeolocationEditor/mb-editor/map-editor/index.js +77 -47
  119. package/lib/GeolocationEditor/mb-editor/map-selection-editor/index.js +89 -50
  120. package/lib/GeolocationEditor/mb-editor/province-city-editor.js +14 -17
  121. package/lib/GeolocationEditor/mb-editor/province-editor.js +14 -17
  122. package/lib/GeolocationEditor/pc-editor/country-editor.js +25 -12
  123. package/lib/GeolocationEditor/pc-editor/index.js +41 -27
  124. package/lib/GeolocationEditor/pc-editor/location-editor.js +33 -28
  125. package/lib/GeolocationEditor/pc-editor/map-editor/index.js +67 -43
  126. package/lib/GeolocationEditor/pc-editor/map-editor/large-editor/index.js +69 -42
  127. package/lib/GeolocationEditor/pc-editor/map-selection-editor/index.js +86 -42
  128. package/lib/GeolocationEditor/pc-editor/map-selection-editor/large-editor/index.js +85 -39
  129. package/lib/GeolocationEditor/pc-editor/province-city-editor.js +26 -20
  130. package/lib/GeolocationEditor/pc-editor/province-editor.js +15 -8
  131. package/lib/GeolocationEditor/pc-editor/selector-header-item.js +6 -5
  132. package/lib/GeolocationEditor/pc-editor/selector-list.js +8 -7
  133. package/lib/GeolocationFormatter/index.js +5 -4
  134. package/lib/HtmlLongTextFormatter/index.js +13 -5
  135. package/lib/Icon/index.js +13 -15
  136. package/lib/Icon/load-sprite.js +13 -2
  137. package/lib/IconButton/index.js +12 -13
  138. package/lib/ImageEditor/images-previewer/image-preview/index.js +22 -13
  139. package/lib/ImageEditor/images-previewer/index.js +9 -3
  140. package/lib/ImageEditor/index.js +16 -13
  141. package/lib/ImageEditor/mb-editor/index.js +20 -28
  142. package/lib/ImageEditor/pc-editor/addition-previewer/image-link/index.js +6 -2
  143. package/lib/ImageEditor/pc-editor/addition-previewer/index.js +5 -3
  144. package/lib/ImageEditor/pc-editor/addition-previewer/local-image-addition/index.js +26 -12
  145. package/lib/ImageEditor/pc-editor/images-previewer/index.js +10 -4
  146. package/lib/ImageEditor/pc-editor/index.js +16 -11
  147. package/lib/ImageFormatter/images-lazy-load.js +11 -19
  148. package/lib/ImageFormatter/index.js +14 -12
  149. package/lib/ImagePreviewerLightbox/index.js +15 -19
  150. package/lib/ImageThumbnail/index.js +15 -12
  151. package/lib/InputItem/custom-input.js +55 -35
  152. package/lib/InputItem/custom-keyboard.js +42 -42
  153. package/lib/InputItem/index.js +82 -63
  154. package/lib/InputItem/input.js +9 -11
  155. package/lib/LastModifierFormatter/index.js +8 -6
  156. package/lib/LinkEditor/index.js +53 -33
  157. package/lib/LinkEditor/link-editor-option.js +4 -3
  158. package/lib/LinkEditor/mb-popover/index.js +22 -9
  159. package/lib/LinkEditor/pc-popover/index.js +13 -7
  160. package/lib/LinkFormatter/index.js +37 -21
  161. package/lib/List/index.js +17 -19
  162. package/lib/List/list-item.js +59 -55
  163. package/lib/LongTextFormatter/index.js +5 -4
  164. package/lib/MBEditorHeader/index.js +9 -8
  165. package/lib/MTimeFormatter/index.js +4 -3
  166. package/lib/MobileFullScreenPage/body/index.js +6 -4
  167. package/lib/MobileFullScreenPage/header/index.js +10 -8
  168. package/lib/MobileFullScreenPage/index.js +12 -14
  169. package/lib/MobileModal/index.js +7 -8
  170. package/lib/MobileOperationSheet/index.js +8 -7
  171. package/lib/MobileSelector/empty/index.js +3 -1
  172. package/lib/MobileSelector/index.js +7 -5
  173. package/lib/MobileSelector/option/index.js +5 -3
  174. package/lib/MobileSelector/options/index.css +0 -4
  175. package/lib/MobileSelector/options/index.js +3 -1
  176. package/lib/MobileSelector/search/index.js +5 -3
  177. package/lib/MobileUpload/index.js +5 -4
  178. package/lib/Modal/alert.js +2 -2
  179. package/lib/Modal/modal.js +28 -30
  180. package/lib/Modal/prompt.js +14 -14
  181. package/lib/MultipleSelectEditor/index.js +7 -7
  182. package/lib/MultipleSelectFormatter/index.js +9 -7
  183. package/lib/NotificationPopover/index.js +5 -4
  184. package/lib/NumberEditor/index.js +21 -12
  185. package/lib/NumberFormatter/index.js +5 -4
  186. package/lib/PhoneNumberLink/index.js +5 -3
  187. package/lib/Picker/AbstractPicker.js +35 -33
  188. package/lib/Popover/index.js +9 -11
  189. package/lib/Popover/item.js +22 -24
  190. package/lib/Progress/index.js +18 -17
  191. package/lib/Radio/Radio.js +17 -15
  192. package/lib/Radio/RadioItem.js +23 -19
  193. package/lib/RateFormatter/index.js +15 -15
  194. package/lib/RoleStatusEditor/index.js +18 -19
  195. package/lib/RowExpand/index.js +7 -6
  196. package/lib/RowExpandDialog/body/index.js +57 -40
  197. package/lib/RowExpandDialog/column-content/index.js +10 -6
  198. package/lib/RowExpandDialog/header/index.js +12 -9
  199. package/lib/RowExpandDialog/index.js +59 -63
  200. package/lib/RowExpandEditor/add-btn/index.js +7 -6
  201. package/lib/RowExpandEditor/checkbox-editor/index.js +7 -6
  202. package/lib/RowExpandEditor/checkbox-editor/mb-editor/index.js +5 -4
  203. package/lib/RowExpandEditor/checkbox-editor/pc-editor.js +10 -8
  204. package/lib/RowExpandEditor/collaborator-editor/index.js +7 -6
  205. package/lib/RowExpandEditor/collaborator-editor/mb-editor/index.js +33 -22
  206. package/lib/RowExpandEditor/collaborator-editor/pc-editor/index.js +40 -26
  207. package/lib/RowExpandEditor/date-editor/index.js +7 -6
  208. package/lib/RowExpandEditor/date-editor/mb-editor.js +18 -12
  209. package/lib/RowExpandEditor/date-editor/pc-editor.js +20 -15
  210. package/lib/RowExpandEditor/department-editor/index.js +7 -6
  211. package/lib/RowExpandEditor/department-editor/mb-editor.js +11 -16
  212. package/lib/RowExpandEditor/department-editor/pc-editor.js +14 -19
  213. package/lib/RowExpandEditor/digital-sign-editor/index.js +7 -6
  214. package/lib/RowExpandEditor/digital-sign-editor/mb-editor/index.js +38 -24
  215. package/lib/RowExpandEditor/digital-sign-editor/pc-editor/index.js +39 -25
  216. package/lib/RowExpandEditor/duration-editor/index.js +7 -6
  217. package/lib/RowExpandEditor/duration-editor/mb-editor.js +17 -10
  218. package/lib/RowExpandEditor/duration-editor/pc-editor.js +19 -13
  219. package/lib/RowExpandEditor/email-editor/index.js +7 -6
  220. package/lib/RowExpandEditor/email-editor/mb-editor/index.js +20 -10
  221. package/lib/RowExpandEditor/email-editor/pc-editor/index.js +25 -14
  222. package/lib/RowExpandEditor/file-editor/index.js +7 -6
  223. package/lib/RowExpandEditor/file-editor/mb-editor/index.js +31 -18
  224. package/lib/RowExpandEditor/file-editor/pc-editor/index.js +23 -16
  225. package/lib/RowExpandEditor/geolocation-editor/index.js +7 -6
  226. package/lib/RowExpandEditor/geolocation-editor/mb-editor/index.js +29 -17
  227. package/lib/RowExpandEditor/geolocation-editor/pc-editor/index.js +26 -13
  228. package/lib/RowExpandEditor/image-editor/index.js +7 -6
  229. package/lib/RowExpandEditor/image-editor/mb-editor/index.js +26 -16
  230. package/lib/RowExpandEditor/image-editor/pc-editor/index.js +24 -14
  231. package/lib/RowExpandEditor/index.js +16 -11
  232. package/lib/RowExpandEditor/long-text-editor/index.js +7 -6
  233. package/lib/RowExpandEditor/long-text-editor/mb-editor/editor/index.js +18 -17
  234. package/lib/RowExpandEditor/long-text-editor/mb-editor/index.js +16 -10
  235. package/lib/RowExpandEditor/long-text-editor/pc-editor/index.js +23 -16
  236. package/lib/RowExpandEditor/multiple-select-editor/index.js +7 -6
  237. package/lib/RowExpandEditor/multiple-select-editor/mb-editor/index.js +20 -12
  238. package/lib/RowExpandEditor/multiple-select-editor/pc-editor/index.js +38 -27
  239. package/lib/RowExpandEditor/number-editor/index.js +7 -6
  240. package/lib/RowExpandEditor/number-editor/mb-editor/index.js +14 -8
  241. package/lib/RowExpandEditor/number-editor/pc-editor.js +20 -13
  242. package/lib/RowExpandEditor/rate-editor/index.js +7 -6
  243. package/lib/RowExpandEditor/rate-editor/mb-editor.js +26 -13
  244. package/lib/RowExpandEditor/rate-editor/pc-editor.js +41 -25
  245. package/lib/RowExpandEditor/single-select-editor/index.js +7 -6
  246. package/lib/RowExpandEditor/single-select-editor/mb-editor/index.js +32 -21
  247. package/lib/RowExpandEditor/single-select-editor/pc-editor/index.js +37 -25
  248. package/lib/RowExpandEditor/text-editor/index.js +7 -6
  249. package/lib/RowExpandEditor/text-editor/mb-editor/index.js +5 -4
  250. package/lib/RowExpandEditor/text-editor/pc-editor/index.js +26 -15
  251. package/lib/RowExpandEditor/url-editor/index.js +7 -6
  252. package/lib/RowExpandEditor/url-editor/mb-editor/index.js +15 -7
  253. package/lib/RowExpandEditor/url-editor/pc-editor/index.js +20 -11
  254. package/lib/RowExpandFormatter/department-formatter/index.js +6 -3
  255. package/lib/RowExpandFormatter/department-formatter/mb-formatter.js +4 -2
  256. package/lib/RowExpandFormatter/department-formatter/pc-formatter.js +4 -2
  257. package/lib/RowExpandFormatter/email-formatter/index.js +8 -5
  258. package/lib/RowExpandFormatter/file-formatter/index.js +9 -8
  259. package/lib/RowExpandFormatter/file-formatter/row-expand-file-item-formatter.js +14 -12
  260. package/lib/RowExpandFormatter/formula-formatter/index.js +51 -30
  261. package/lib/RowExpandFormatter/image-formatter/index.js +11 -9
  262. package/lib/RowExpandFormatter/image-formatter/row-expand-image-item-formatter.js +10 -9
  263. package/lib/RowExpandFormatter/index.js +52 -34
  264. package/lib/RowExpandFormatter/link-formatter/collaborator-item-formatter.js +15 -9
  265. package/lib/RowExpandFormatter/link-formatter/index.js +25 -17
  266. package/lib/RowExpandFormatter/link-formatter/value-display-utils.js +5 -3
  267. package/lib/RowExpandFormatter/rate-formatter/index.js +14 -13
  268. package/lib/RowExpandFormatter/text/index.js +5 -4
  269. package/lib/RowExpandFormatter/url-formatter/index.js +9 -6
  270. package/lib/RowExpandView/body/index.js +43 -32
  271. package/lib/RowExpandView/column-content/index.js +7 -3
  272. package/lib/RowExpandView/index.js +52 -53
  273. package/lib/SelectItem/index.js +7 -5
  274. package/lib/SelectOptionGroup/index.js +40 -30
  275. package/lib/SelectedDepartments/index.js +12 -10
  276. package/lib/SimpleLongTextFormatter/index.js +18 -12
  277. package/lib/SimpleLongTextFormatter/normalize-long-text-value.js +4 -3
  278. package/lib/SimpleLongTextFormatter/widgets/LongTextPreview.js +21 -12
  279. package/lib/SimpleLongTextFormatter/widgets/dtable-markdown-viewer.js +4 -3
  280. package/lib/SingleSelectEditor/index.js +7 -7
  281. package/lib/SingleSelectFormatter/index.js +9 -8
  282. package/lib/TabBar/Tab.js +26 -24
  283. package/lib/TabBar/index.js +28 -24
  284. package/lib/Tabs/index.js +13 -10
  285. package/lib/TextEditor/index.js +23 -14
  286. package/lib/TextFormatter/index.js +4 -3
  287. package/lib/TextareaItem/index.js +53 -48
  288. package/lib/Toast/index.js +9 -8
  289. package/lib/UrlFormatter/index.js +4 -3
  290. package/lib/common/editor-base.js +12 -7
  291. package/lib/formatterConfig/index.js +3 -3
  292. package/lib/hooks/common-hooks.js +4 -2
  293. package/lib/select-editor/index.js +16 -13
  294. package/lib/select-editor/mb-editor/index.js +28 -17
  295. package/lib/select-editor/pc-editor/index.js +47 -32
  296. package/lib/toaster/alert.js +8 -7
  297. package/lib/toaster/toast.js +4 -3
  298. package/lib/toaster/toastManager.js +13 -13
  299. package/lib/toaster/toaster.js +12 -9
  300. package/lib/utils/cell.js +11 -8
  301. package/lib/utils/class.js +3 -3
  302. package/lib/utils/column-utils.js +14 -8
  303. package/lib/utils/departments.js +6 -5
  304. package/lib/utils/getLocale.js +11 -5
  305. package/lib/utils/object-utils.js +5 -4
  306. package/lib/utils/url.js +29 -22
  307. package/lib/utils/utils.js +6 -2
  308. package/package.json +2 -2
@@ -16,37 +16,45 @@ class LinkFormatter extends _react.default.Component {
16
16
  super(props);
17
17
  this.getLinkedCellValue = row => {
18
18
  if (!row) return [];
19
- const _this$props = this.props,
20
- column = _this$props.column,
21
- currentTableId = _this$props.currentTableId,
22
- linkMetaData = _this$props.linkMetaData;
23
- const _ref = column.data || {},
24
- link_id = _ref.link_id,
25
- table_id = _ref.table_id,
26
- other_table_id = _ref.other_table_id;
19
+ const {
20
+ column,
21
+ currentTableId,
22
+ linkMetaData
23
+ } = this.props;
24
+ const {
25
+ link_id,
26
+ table_id,
27
+ other_table_id
28
+ } = column.data || {};
27
29
  this.linkID = link_id;
28
30
  this.tableID = currentTableId === table_id ? table_id : other_table_id;
29
31
  this.otherTableID = this.tableID === table_id ? other_table_id : table_id;
30
32
  return linkMetaData.getLinkedCellValue(this.linkID, this.tableID, this.otherTableID, row._id);
31
33
  };
32
34
  this.expandLinkedTableRow = row => {
33
- let _this$props2 = this.props,
34
- enableOpenLinkedRow = _this$props2.enableOpenLinkedRow,
35
- linkMetaData = _this$props2.linkMetaData;
35
+ let {
36
+ enableOpenLinkedRow,
37
+ linkMetaData
38
+ } = this.props;
36
39
  if (enableOpenLinkedRow) {
37
40
  linkMetaData.expandLinkedTableRow(row, this.otherTableID);
38
41
  }
39
42
  };
40
43
  this.getDisplayValues = () => {
41
- let _this$props3 = this.props,
42
- column = _this$props3.column,
43
- linkMetaData = _this$props3.linkMetaData;
44
- let rowIds = this.state.value;
44
+ let {
45
+ column,
46
+ linkMetaData
47
+ } = this.props;
48
+ let {
49
+ value: rowIds
50
+ } = this.state;
45
51
  if (rowIds && Array.isArray(rowIds) && rowIds.length > 0) {
46
52
  let linkedTable = linkMetaData.getLinkedTable(this.otherTableID);
47
53
  let linkedRows = linkMetaData.getLinkedRows(this.otherTableID, rowIds);
48
54
  let result = linkedRows.map((row, index) => {
49
- let displayColumnKey = column.data.display_column_key;
55
+ let {
56
+ display_column_key: displayColumnKey
57
+ } = column.data;
50
58
  let displayValue = this.getDisplayValue(linkedTable, row, displayColumnKey);
51
59
  return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
52
60
  className: "link-item",
@@ -65,8 +73,10 @@ class LinkFormatter extends _react.default.Component {
65
73
  this.getDisplayValue = (linkedTable, row, displayColumnKey) => {
66
74
  let value = row[displayColumnKey];
67
75
  let linkedColumn = linkedTable.columns.find(column => column.key === displayColumnKey);
68
- let type = linkedColumn.type,
69
- data = linkedColumn.data;
76
+ let {
77
+ type,
78
+ data
79
+ } = linkedColumn;
70
80
  // todo: improve
71
81
  switch (type) {
72
82
  case _dtableUtils.CellType.NUMBER:
@@ -75,7 +85,9 @@ class LinkFormatter extends _react.default.Component {
75
85
  }
76
86
  case _dtableUtils.CellType.DATE:
77
87
  {
78
- let format = data.format;
88
+ let {
89
+ format
90
+ } = data;
79
91
  return (0, _dtableUtils.getDateDisplayString)(value, format);
80
92
  }
81
93
  default:
@@ -90,7 +102,9 @@ class LinkFormatter extends _react.default.Component {
90
102
  };
91
103
  }
92
104
  UNSAFE_componentWillReceiveProps(nextProps) {
93
- const nextRow = nextProps.row;
105
+ const {
106
+ row: nextRow
107
+ } = nextProps;
94
108
  if (nextRow._id !== this.props.row._id) {
95
109
  this.setState({
96
110
  value: this.getLinkedCellValue(nextRow)
@@ -98,7 +112,9 @@ class LinkFormatter extends _react.default.Component {
98
112
  }
99
113
  }
100
114
  render() {
101
- const containerClassName = this.props.containerClassName;
115
+ const {
116
+ containerClassName
117
+ } = this.props;
102
118
  const classname = (0, _classnames.default)('dtable-ui cell-formatter-container link-formatter', containerClassName);
103
119
  let displayValues = this.getDisplayValues();
104
120
  return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
package/lib/List/index.js CHANGED
@@ -1,45 +1,43 @@
1
1
  "use strict";
2
2
 
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
3
  var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
4
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
5
5
  Object.defineProperty(exports, "__esModule", {
6
6
  value: true
7
7
  });
8
8
  exports.default = void 0;
9
- var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectSpread2"));
10
- var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectWithoutProperties"));
11
9
  var _classnames = _interopRequireDefault(require("classnames"));
12
10
  var React = _interopRequireWildcard(require("react"));
13
11
  var _listItem = _interopRequireDefault(require("./list-item"));
14
12
  require("./index.css");
15
13
  var _jsxRuntime = require("react/jsx-runtime");
16
- const _excluded = ["prefixCls", "children", "className", "style", "renderHeader", "renderFooter"];
17
14
  class List extends React.Component {
18
15
  render() {
19
- const _this$props = this.props,
20
- prefixCls = _this$props.prefixCls,
21
- children = _this$props.children,
22
- className = _this$props.className,
23
- style = _this$props.style,
24
- renderHeader = _this$props.renderHeader,
25
- renderFooter = _this$props.renderFooter,
26
- restProps = (0, _objectWithoutProperties2.default)(_this$props, _excluded);
16
+ const {
17
+ prefixCls,
18
+ children,
19
+ className,
20
+ style,
21
+ renderHeader,
22
+ renderFooter,
23
+ ...restProps
24
+ } = this.props;
27
25
  const wrapCls = (0, _classnames.default)(prefixCls, className);
28
- return /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", (0, _objectSpread2.default)((0, _objectSpread2.default)({
26
+ return /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
29
27
  className: wrapCls,
30
- style: style
31
- }, restProps), {}, {
28
+ style: style,
29
+ ...restProps,
32
30
  children: [renderHeader ? /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
33
- className: "".concat(prefixCls, "-header"),
31
+ className: `${prefixCls}-header`,
34
32
  children: typeof renderHeader === 'function' ? renderHeader() : renderHeader
35
33
  }) : null, children ? /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
36
- className: "".concat(prefixCls, "-body"),
34
+ className: `${prefixCls}-body`,
37
35
  children: children
38
36
  }) : null, renderFooter ? /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
39
- className: "".concat(prefixCls, "-footer"),
37
+ className: `${prefixCls}-footer`,
40
38
  children: typeof renderFooter === 'function' ? renderFooter() : renderFooter
41
39
  }) : null]
42
- }));
40
+ });
43
41
  }
44
42
  }
45
43
  List.defaultProps = {
@@ -1,20 +1,17 @@
1
1
  "use strict";
2
2
 
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
3
  var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
4
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
5
5
  Object.defineProperty(exports, "__esModule", {
6
6
  value: true
7
7
  });
8
8
  exports.default = exports.Brief = void 0;
9
- var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectSpread2"));
10
- var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectWithoutProperties"));
11
9
  var _classnames = _interopRequireDefault(require("classnames"));
12
10
  var React = _interopRequireWildcard(require("react"));
13
11
  var _rmcFeedback = _interopRequireDefault(require("rmc-feedback"));
14
12
  var _jsxRuntime = require("react/jsx-runtime");
15
- const _excluded = ["prefixCls", "className", "activeStyle", "error", "align", "wrap", "disabled", "children", "multipleLine", "thumb", "extra", "arrow", "onClick"],
16
- _excluded2 = ["platform"];
17
13
  /* tslint:disable:jsx-no-multiline-js */
14
+
18
15
  class Brief extends React.Component {
19
16
  render() {
20
17
  return /*#__PURE__*/React.createElement('div', {
@@ -28,9 +25,10 @@ class ListItem extends React.Component {
28
25
  constructor(props) {
29
26
  super(props);
30
27
  this.onClick = ev => {
31
- const _this$props = this.props,
32
- onClick = _this$props.onClick,
33
- platform = _this$props.platform;
28
+ const {
29
+ onClick,
30
+ platform
31
+ } = this.props;
34
32
  const isAndroid = platform === 'android';
35
33
  if (!!onClick && isAndroid) {
36
34
  if (this.debounceTimeout) {
@@ -43,10 +41,10 @@ class ListItem extends React.Component {
43
41
  const pointX = ev.clientX - ClientRect.left - Item.offsetWidth / 2;
44
42
  const pointY = ev.clientY - ClientRect.top - Item.offsetWidth / 2;
45
43
  const coverRippleStyle = {
46
- width: "".concat(RippleWidth, "px"),
47
- height: "".concat(RippleWidth, "px"),
48
- left: "".concat(pointX, "px"),
49
- top: "".concat(pointY, "px")
44
+ width: `${RippleWidth}px`,
45
+ height: `${RippleWidth}px`,
46
+ left: `${pointX}px`,
47
+ top: `${pointY}px`
50
48
  };
51
49
  this.setState({
52
50
  coverRippleStyle,
@@ -80,52 +78,57 @@ class ListItem extends React.Component {
80
78
  }
81
79
  }
82
80
  render() {
83
- const _this$props2 = this.props,
84
- prefixCls = _this$props2.prefixCls,
85
- className = _this$props2.className,
86
- activeStyle = _this$props2.activeStyle,
87
- error = _this$props2.error,
88
- align = _this$props2.align,
89
- wrap = _this$props2.wrap,
90
- disabled = _this$props2.disabled,
91
- children = _this$props2.children,
92
- multipleLine = _this$props2.multipleLine,
93
- thumb = _this$props2.thumb,
94
- extra = _this$props2.extra,
95
- arrow = _this$props2.arrow,
96
- onClick = _this$props2.onClick,
97
- restProps = (0, _objectWithoutProperties2.default)(_this$props2, _excluded);
98
- const platform = restProps.platform,
99
- otherProps = (0, _objectWithoutProperties2.default)(restProps, _excluded2);
100
- const _this$state = this.state,
101
- coverRippleStyle = _this$state.coverRippleStyle,
102
- RippleClicked = _this$state.RippleClicked;
103
- const wrapCls = (0, _classnames.default)("".concat(prefixCls, "-item"), className, {
104
- ["".concat(prefixCls, "-item-disabled")]: disabled,
105
- ["".concat(prefixCls, "-item-error")]: error,
106
- ["".concat(prefixCls, "-item-top")]: align === 'top',
107
- ["".concat(prefixCls, "-item-middle")]: align === 'middle',
108
- ["".concat(prefixCls, "-item-bottom")]: align === 'bottom'
81
+ const {
82
+ prefixCls,
83
+ className,
84
+ activeStyle,
85
+ error,
86
+ align,
87
+ wrap,
88
+ disabled,
89
+ children,
90
+ multipleLine,
91
+ thumb,
92
+ extra,
93
+ arrow,
94
+ onClick,
95
+ ...restProps
96
+ } = this.props;
97
+ const {
98
+ platform,
99
+ ...otherProps
100
+ } = restProps;
101
+ const {
102
+ coverRippleStyle,
103
+ RippleClicked
104
+ } = this.state;
105
+ const wrapCls = (0, _classnames.default)(`${prefixCls}-item`, className, {
106
+ [`${prefixCls}-item-disabled`]: disabled,
107
+ [`${prefixCls}-item-error`]: error,
108
+ [`${prefixCls}-item-top`]: align === 'top',
109
+ [`${prefixCls}-item-middle`]: align === 'middle',
110
+ [`${prefixCls}-item-bottom`]: align === 'bottom'
109
111
  });
110
- const rippleCls = (0, _classnames.default)("".concat(prefixCls, "-ripple"), {
111
- ["".concat(prefixCls, "-ripple-animate")]: RippleClicked
112
+ const rippleCls = (0, _classnames.default)(`${prefixCls}-ripple`, {
113
+ [`${prefixCls}-ripple-animate`]: RippleClicked
112
114
  });
113
- const lineCls = (0, _classnames.default)("".concat(prefixCls, "-line"), {
114
- ["".concat(prefixCls, "-line-multiple")]: multipleLine,
115
- ["".concat(prefixCls, "-line-wrap")]: wrap
115
+ const lineCls = (0, _classnames.default)(`${prefixCls}-line`, {
116
+ [`${prefixCls}-line-multiple`]: multipleLine,
117
+ [`${prefixCls}-line-wrap`]: wrap
116
118
  });
117
- const arrowCls = (0, _classnames.default)("".concat(prefixCls, "-arrow"), {
118
- ["".concat(prefixCls, "-arrow-horizontal")]: arrow === 'horizontal',
119
- ["".concat(prefixCls, "-arrow-vertical")]: arrow === 'down' || arrow === 'up',
120
- ["".concat(prefixCls, "-arrow-vertical-up")]: arrow === 'up'
119
+ const arrowCls = (0, _classnames.default)(`${prefixCls}-arrow`, {
120
+ [`${prefixCls}-arrow-horizontal`]: arrow === 'horizontal',
121
+ [`${prefixCls}-arrow-vertical`]: arrow === 'down' || arrow === 'up',
122
+ [`${prefixCls}-arrow-vertical-up`]: arrow === 'up'
121
123
  });
122
- const content = /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", (0, _objectSpread2.default)((0, _objectSpread2.default)({}, otherProps), {}, {
124
+ const content = /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
125
+ ...otherProps,
123
126
  onClick: ev => {
124
127
  this.onClick(ev);
125
128
  },
126
129
  className: wrapCls,
127
130
  children: [thumb ? /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
128
- className: "".concat(prefixCls, "-thumb"),
131
+ className: `${prefixCls}-thumb`,
129
132
  children: typeof thumb === 'string' ? /*#__PURE__*/(0, _jsxRuntime.jsx)("img", {
130
133
  src: thumb,
131
134
  alt: ""
@@ -133,10 +136,10 @@ class ListItem extends React.Component {
133
136
  }) : null, /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
134
137
  className: lineCls,
135
138
  children: [children !== undefined && /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
136
- className: "".concat(prefixCls, "-content"),
139
+ className: `${prefixCls}-content`,
137
140
  children: children
138
141
  }), extra !== undefined && /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
139
- className: "".concat(prefixCls, "-extra"),
142
+ className: `${prefixCls}-extra`,
140
143
  children: extra
141
144
  }), arrow && /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
142
145
  className: arrowCls,
@@ -146,7 +149,7 @@ class ListItem extends React.Component {
146
149
  style: coverRippleStyle,
147
150
  className: rippleCls
148
151
  })]
149
- }));
152
+ });
150
153
  let touchProps = {};
151
154
  Object.keys(otherProps).forEach(key => {
152
155
  if (/onTouch/i.test(key)) {
@@ -154,12 +157,13 @@ class ListItem extends React.Component {
154
157
  delete otherProps[key];
155
158
  }
156
159
  });
157
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_rmcFeedback.default, (0, _objectSpread2.default)((0, _objectSpread2.default)({}, touchProps), {}, {
160
+ return /*#__PURE__*/(0, _jsxRuntime.jsx)(_rmcFeedback.default, {
161
+ ...touchProps,
158
162
  disabled: disabled || !onClick,
159
163
  activeStyle: activeStyle,
160
- activeClassName: "".concat(prefixCls, "-item-active"),
164
+ activeClassName: `${prefixCls}-item-active`,
161
165
  children: content
162
- }));
166
+ });
163
167
  }
164
168
  }
165
169
  ListItem.defaultProps = {
@@ -10,10 +10,11 @@ var _HtmlLongTextFormatter = _interopRequireDefault(require("../HtmlLongTextForm
10
10
  var _SimpleLongTextFormatter = _interopRequireDefault(require("../SimpleLongTextFormatter"));
11
11
  var _jsxRuntime = require("react/jsx-runtime");
12
12
  function LongTextFormatter(_ref) {
13
- let _ref$isSample = _ref.isSample,
14
- isSample = _ref$isSample === void 0 ? true : _ref$isSample,
15
- value = _ref.value,
16
- containerClassName = _ref.containerClassName;
13
+ let {
14
+ isSample = true,
15
+ value,
16
+ containerClassName
17
+ } = _ref;
17
18
  if (isSample) {
18
19
  return /*#__PURE__*/(0, _jsxRuntime.jsx)(_SimpleLongTextFormatter.default, {
19
20
  value: value,
@@ -9,15 +9,16 @@ var _react = _interopRequireDefault(require("react"));
9
9
  var _jsxRuntime = require("react/jsx-runtime");
10
10
  class MBEditorHeader extends _react.default.Component {
11
11
  render() {
12
- let _this$props = this.props,
13
- title = _this$props.title,
14
- titleClass = _this$props.titleClass,
15
- leftContent = _this$props.leftContent,
16
- rightContent = _this$props.rightContent,
17
- onLeftClick = _this$props.onLeftClick,
18
- onRightClick = _this$props.onRightClick;
12
+ let {
13
+ title,
14
+ titleClass,
15
+ leftContent,
16
+ rightContent,
17
+ onLeftClick,
18
+ onRightClick
19
+ } = this.props;
19
20
  return /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
20
- className: "dtable-ui-mb-editor-header ".concat(titleClass ? titleClass : ''),
21
+ className: `dtable-ui-mb-editor-header ${titleClass ? titleClass : ''}`,
21
22
  children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
22
23
  className: "editor-header-left-content",
23
24
  onClick: onLeftClick,
@@ -18,9 +18,10 @@ class MTimeFormatter extends _react.default.Component {
18
18
  };
19
19
  }
20
20
  render() {
21
- let _this$props = this.props,
22
- date = _this$props.value,
23
- containerClassName = _this$props.containerClassName;
21
+ let {
22
+ value: date,
23
+ containerClassName
24
+ } = this.props;
24
25
  let classname = (0, _classnames.default)('dtable-ui cell-formatter-container ctime-formatter', containerClassName);
25
26
  if (date) {
26
27
  date = this.formatDate(date);
@@ -10,12 +10,14 @@ var _classnames = _interopRequireDefault(require("classnames"));
10
10
  require("./index.css");
11
11
  var _jsxRuntime = require("react/jsx-runtime");
12
12
  const Body = _ref => {
13
- let classNamePrefix = _ref.classNamePrefix,
14
- className = _ref.className,
15
- children = _ref.children;
13
+ let {
14
+ classNamePrefix,
15
+ className,
16
+ children
17
+ } = _ref;
16
18
  return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
17
19
  className: (0, _classnames.default)('dtable-ui-mobile-full-screen-page-body', className, {
18
- ["".concat(classNamePrefix, "-mobile-full-screen-page-body")]: classNamePrefix
20
+ [`${classNamePrefix}-mobile-full-screen-page-body`]: classNamePrefix
19
21
  }),
20
22
  children: children
21
23
  });
@@ -10,28 +10,30 @@ var _classnames = _interopRequireDefault(require("classnames"));
10
10
  require("./index.css");
11
11
  var _jsxRuntime = require("react/jsx-runtime");
12
12
  const Header = _ref => {
13
- let classNamePrefix = _ref.classNamePrefix,
14
- children = _ref.children,
15
- onLeftClick = _ref.onLeftClick,
16
- onRightClick = _ref.onRightClick;
13
+ let {
14
+ classNamePrefix,
15
+ children,
16
+ onLeftClick,
17
+ onRightClick
18
+ } = _ref;
17
19
  return /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
18
20
  className: (0, _classnames.default)('dtable-ui-mobile-full-screen-page-header p-0', {
19
- ["".concat(classNamePrefix, "-mobile-full-screen-page-header")]: classNamePrefix
21
+ [`${classNamePrefix}-mobile-full-screen-page-header`]: classNamePrefix
20
22
  }),
21
23
  children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
22
24
  className: (0, _classnames.default)('dtable-ui-mobile-full-screen-page-header-btn', {
23
- ["".concat(classNamePrefix, "-mobile-full-screen-page-header-btn")]: classNamePrefix
25
+ [`${classNamePrefix}-mobile-full-screen-page-header-btn`]: classNamePrefix
24
26
  }),
25
27
  onClick: onLeftClick,
26
28
  children: children[0]
27
29
  }), /*#__PURE__*/(0, _jsxRuntime.jsx)("h4", {
28
30
  className: (0, _classnames.default)('dtable-ui-mobile-full-screen-page-header-title', {
29
- ["".concat(classNamePrefix, "-mobile-full-screen-page-header-title")]: classNamePrefix
31
+ [`${classNamePrefix}-mobile-full-screen-page-header-title`]: classNamePrefix
30
32
  }),
31
33
  children: children[1]
32
34
  }), /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
33
35
  className: (0, _classnames.default)('dtable-ui-mobile-full-screen-page-header-btn', {
34
- ["".concat(classNamePrefix, "-mobile-full-screen-page-header-btn")]: classNamePrefix
36
+ [`${classNamePrefix}-mobile-full-screen-page-header-btn`]: classNamePrefix
35
37
  }),
36
38
  onClick: onRightClick,
37
39
  children: children[2]
@@ -1,12 +1,11 @@
1
1
  "use strict";
2
2
 
3
- var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
4
3
  var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
+ var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
5
5
  Object.defineProperty(exports, "__esModule", {
6
6
  value: true
7
7
  });
8
8
  exports.default = void 0;
9
- var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/slicedToArray"));
10
9
  var _react = _interopRequireWildcard(require("react"));
11
10
  var _classnames = _interopRequireDefault(require("classnames"));
12
11
  var _BodyPortal = _interopRequireDefault(require("../BodyPortal"));
@@ -16,17 +15,16 @@ var _utils = require("../utils/utils");
16
15
  require("./index.css");
17
16
  var _jsxRuntime = require("react/jsx-runtime");
18
17
  const MobileFullScreenPage = _ref => {
19
- let classNamePrefix = _ref.classNamePrefix,
20
- className = _ref.className,
21
- style = _ref.style,
22
- zIndex = _ref.zIndex,
23
- children = _ref.children,
24
- onClose = _ref.onClose,
25
- historyCallback = _ref.historyCallback;
26
- const _useState = (0, _react.useState)(false),
27
- _useState2 = (0, _slicedToArray2.default)(_useState, 2),
28
- isMount = _useState2[0],
29
- setMount = _useState2[1];
18
+ let {
19
+ classNamePrefix,
20
+ className,
21
+ style,
22
+ zIndex,
23
+ children,
24
+ onClose,
25
+ historyCallback
26
+ } = _ref;
27
+ const [isMount, setMount] = (0, _react.useState)(false);
30
28
  const element = (0, _react.useMemo)(() => {
31
29
  let _element = document.createElement('div');
32
30
  _element.setAttribute('tabindex', '-1');
@@ -66,7 +64,7 @@ const MobileFullScreenPage = _ref => {
66
64
  node: element,
67
65
  children: /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
68
66
  className: (0, _classnames.default)('dtable-ui-mobile-full-screen-page', className, {
69
- ["".concat(classNamePrefix, "-mobile-full-screen-page")]: classNamePrefix
67
+ [`${classNamePrefix}-mobile-full-screen-page`]: classNamePrefix
70
68
  }),
71
69
  style: style,
72
70
  children: isMount && children
@@ -5,12 +5,9 @@ Object.defineProperty(exports, "__esModule", {
5
5
  value: true
6
6
  });
7
7
  exports.default = void 0;
8
- var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectSpread2"));
9
- var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectWithoutProperties"));
10
8
  var _react = _interopRequireDefault(require("react"));
11
9
  var _Modal = _interopRequireDefault(require("../Modal"));
12
10
  var _jsxRuntime = require("react/jsx-runtime");
13
- const _excluded = ["children"];
14
11
  class MobileModal extends _react.default.PureComponent {
15
12
  constructor() {
16
13
  super(...arguments);
@@ -27,13 +24,15 @@ class MobileModal extends _react.default.PureComponent {
27
24
  window.removeEventListener('popstate', this.handleHistoryBack, false);
28
25
  }
29
26
  render() {
30
- const _this$props = this.props,
31
- children = _this$props.children,
32
- props = (0, _objectWithoutProperties2.default)(_this$props, _excluded);
33
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_Modal.default, (0, _objectSpread2.default)((0, _objectSpread2.default)({}, props), {}, {
27
+ const {
28
+ children,
29
+ ...props
30
+ } = this.props;
31
+ return /*#__PURE__*/(0, _jsxRuntime.jsx)(_Modal.default, {
32
+ ...props,
34
33
  popup: true,
35
34
  children: children
36
- }));
35
+ });
37
36
  }
38
37
  }
39
38
  MobileModal.defaultProps = {
@@ -19,10 +19,11 @@ const OPERATION_TYPE = exports.OPERATION_TYPE = {
19
19
  };
20
20
  const OPERATION_TYPES = [OPERATION_TYPE.RENAME, OPERATION_TYPE.DOWNLOAD, OPERATION_TYPE.DELETE];
21
21
  const MobileOperationSheet = _ref => {
22
- let onChange = _ref.onChange,
23
- onClose = _ref.onClose,
24
- _ref$operations = _ref.operations,
25
- operations = _ref$operations === void 0 ? OPERATION_TYPES : _ref$operations;
22
+ let {
23
+ onChange,
24
+ onClose,
25
+ operations = OPERATION_TYPES
26
+ } = _ref;
26
27
  const actionSheet = (0, _react.useRef)(_ActionSheet.default);
27
28
  const btns = (0, _react.useMemo)(() => {
28
29
  let _btns = [];
@@ -77,9 +78,9 @@ const MobileOperationSheet = _ref => {
77
78
  maskClosable: true,
78
79
  className: 'dtable-ui-mobile-action-sheet'
79
80
  }, index => {
80
- const _ref2 = btns[index] || {},
81
- _ref2$value = _ref2.value,
82
- value = _ref2$value === void 0 ? 'close' : _ref2$value;
81
+ const {
82
+ value = 'close'
83
+ } = btns[index] || {};
83
84
  if (value === 'close') {
84
85
  onClose && onClose();
85
86
  return;
@@ -11,7 +11,9 @@ var _List = _interopRequireDefault(require("../../List"));
11
11
  require("./index.css");
12
12
  var _jsxRuntime = require("react/jsx-runtime");
13
13
  const Empty = _ref => {
14
- let children = _ref.children;
14
+ let {
15
+ children
16
+ } = _ref;
15
17
  return /*#__PURE__*/(0, _jsxRuntime.jsx)(_List.default.Item, {
16
18
  className: "dtable-ui-mobile-selector-no-options",
17
19
  children: children
@@ -17,11 +17,13 @@ var _empty = _interopRequireDefault(require("./empty"));
17
17
  require("./index.css");
18
18
  var _jsxRuntime = require("react/jsx-runtime");
19
19
  const MobileSelector = _ref => {
20
- let className = _ref.className,
21
- listClassName = _ref.listClassName,
22
- title = _ref.title,
23
- children = _ref.children,
24
- onClose = _ref.onClose;
20
+ let {
21
+ className,
22
+ listClassName,
23
+ title,
24
+ children,
25
+ onClose
26
+ } = _ref;
25
27
  const handleHistoryBack = (0, _react.useCallback)(event => {
26
28
  event.preventDefault();
27
29
  onClose && onClose();
@@ -11,9 +11,11 @@ var _List = _interopRequireDefault(require("../../List"));
11
11
  require("./index.css");
12
12
  var _jsxRuntime = require("react/jsx-runtime");
13
13
  const Option = _ref => {
14
- let isSelected = _ref.isSelected,
15
- children = _ref.children,
16
- onChange = _ref.onChange;
14
+ let {
15
+ isSelected,
16
+ children,
17
+ onChange
18
+ } = _ref;
17
19
  return /*#__PURE__*/(0, _jsxRuntime.jsx)(_List.default.Item, {
18
20
  onClick: onChange,
19
21
  children: /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
@@ -2,7 +2,3 @@
2
2
  max-height: 200px;
3
3
  overflow-y: auto;
4
4
  }
5
-
6
- .dtable-ui-mobile-selector .am-list-body .dtable-ui-mobile-selector-options::-webkit-scrollbar {
7
- width: 0;
8
- }