dtable-ui-component 6.0.29-beta9 → 6.0.29

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 (346) hide show
  1. package/lib/ActionSheet/index.js +196 -0
  2. package/lib/ActionSheet/style/index.css +377 -0
  3. package/lib/ActivityIndicator/index.css +110 -0
  4. package/lib/ActivityIndicator/index.js +76 -0
  5. package/lib/Badge/index.css +98 -0
  6. package/lib/Badge/index.js +65 -0
  7. package/lib/CheckboxEditor/index.js +116 -24
  8. package/lib/CollaboratorEditor/index.js +11 -23
  9. package/lib/CollaboratorEditor/mb-collaborator-editor/index.css +85 -0
  10. package/lib/CollaboratorEditor/mb-collaborator-editor/index.js +148 -0
  11. package/lib/DTableCommonAddTool/index.js +3 -1
  12. package/lib/DTableFiltersPopover/widgets/department-select-filter/department-multiple-select-filter.js +6 -6
  13. package/lib/DTableFiltersPopover/widgets/department-select-filter/department-single-select-filter.js +6 -6
  14. package/lib/DateEditor/index.js +95 -69
  15. package/lib/DateEditor/mb-date-editor-popover/custom-rc-calendar.css +118 -0
  16. package/lib/DateEditor/mb-date-editor-popover/index.css +45 -0
  17. package/lib/DateEditor/mb-date-editor-popover/index.js +226 -0
  18. package/lib/DateEditor/{pc-editor.js → pc-date-editor-popover.js} +9 -9
  19. package/lib/DatePicker/index.js +120 -0
  20. package/lib/DatePicker/locale/en_US.js +14 -0
  21. package/lib/DatePicker/locale/ru_RU.js +14 -0
  22. package/lib/DatePicker/locale/sv_SE.js +14 -0
  23. package/lib/DatePicker/locale/zh_CN.js +14 -0
  24. package/lib/DatePicker/style/index.css +298 -0
  25. package/lib/DatePicker/utils.js +36 -0
  26. package/lib/{DepartmentMultipleSelectEditor → Department-editor/department-multiple-select}/index.js +6 -6
  27. package/lib/{DepartmentSingleSelectEditor/pc-editor → Department-editor}/department-single-select.js +7 -7
  28. package/lib/{DepartmentSingleSelectEditor/pc-editor → Department-editor}/index.css +3 -10
  29. package/lib/{DepartmentSingleSelectEditor/pc-editor → Department-editor}/index.js +25 -8
  30. package/lib/{SelectedDepartments → Department-editor/selected-departments}/index.css +1 -0
  31. package/lib/{SelectedDepartments → Department-editor/selected-departments}/index.js +3 -3
  32. package/lib/DigitalSignEditor/index.js +171 -24
  33. package/lib/Drawer/index.css +144 -0
  34. package/lib/Drawer/index.js +21 -0
  35. package/lib/FileEditor/addition-previewer/index.css +1 -0
  36. package/lib/FileEditor/{pc-editor/addition-previewer → addition-previewer}/index.js +1 -1
  37. package/lib/FileEditor/addition-previewer/local-file-addition/index.css +1 -0
  38. package/lib/FileEditor/{pc-editor/addition-previewer → addition-previewer}/local-file-addition/index.js +4 -4
  39. package/lib/FileEditor/files-previewer/{pc-previewer/file-previewer → file-previewer}/dropdown-menu.js +1 -1
  40. package/lib/FileEditor/files-previewer/{pc-previewer/file-previewer → file-previewer}/file-name-editor/index.js +1 -1
  41. package/lib/FileEditor/files-previewer/{pc-previewer/file-previewer → file-previewer}/index.css +2 -0
  42. package/lib/FileEditor/files-previewer/{pc-previewer/file-previewer → file-previewer}/index.js +2 -2
  43. package/lib/FileEditor/files-previewer/index.js +268 -26
  44. package/lib/FileEditor/index.css +5 -0
  45. package/lib/FileEditor/index.js +265 -26
  46. package/lib/FormulaFormatter/index.css +5 -5
  47. package/lib/GeolocationEditor/{pc-editor/country-editor.js → country-editor.js} +49 -5
  48. package/lib/GeolocationEditor/{pc-editor/index.css → index.css} +4 -3
  49. package/lib/GeolocationEditor/index.js +230 -90
  50. package/lib/GeolocationEditor/{pc-editor/location-editor.js → location-editor.js} +41 -8
  51. package/lib/GeolocationEditor/{pc-editor/map-editor → map-editor}/index.js +6 -6
  52. package/lib/GeolocationEditor/{pc-editor/map-editor → map-editor}/large-editor/index.js +7 -7
  53. package/lib/GeolocationEditor/map-editor-utils.js +4 -10
  54. package/lib/GeolocationEditor/{pc-editor/map-selection-editor → map-selection-editor}/index.js +7 -7
  55. package/lib/GeolocationEditor/{pc-editor/map-selection-editor → map-selection-editor}/large-editor/index.js +7 -7
  56. package/lib/GeolocationEditor/{pc-editor/province-city-editor.js → province-city-editor.js} +38 -7
  57. package/lib/GeolocationEditor/{pc-editor/province-editor.js → province-editor.js} +31 -7
  58. package/lib/GeolocationEditor/{pc-editor/selector-header-item.js → selector-header-item.js} +1 -1
  59. package/lib/Icon/index.css +50 -0
  60. package/lib/Icon/index.js +35 -0
  61. package/lib/Icon/load-sprite.js +56 -0
  62. package/lib/ImageEditor/{pc-editor/addition-previewer → addition-previewer}/image-link/index.js +1 -1
  63. package/lib/ImageEditor/{pc-editor/addition-previewer → addition-previewer}/index.js +1 -1
  64. package/lib/ImageEditor/{pc-editor/addition-previewer → addition-previewer}/local-image-addition/index.js +4 -4
  65. package/lib/ImageEditor/images-previewer/image-preview/index.js +3 -3
  66. package/lib/ImageEditor/images-previewer/index.js +4 -9
  67. package/lib/ImageEditor/index.css +16 -17
  68. package/lib/ImageEditor/index.js +185 -26
  69. package/lib/ImageThumbnail/index.js +1 -2
  70. package/lib/InputItem/custom-input.js +321 -0
  71. package/lib/InputItem/custom-keyboard.js +162 -0
  72. package/lib/InputItem/index.js +389 -0
  73. package/lib/InputItem/input.js +45 -0
  74. package/lib/InputItem/locale/en_US.js +12 -0
  75. package/lib/InputItem/locale/ru_RU.js +12 -0
  76. package/lib/InputItem/locale/sv_SE.js +12 -0
  77. package/lib/InputItem/locale/zh_CN.js +12 -0
  78. package/lib/InputItem/portal.js +23 -0
  79. package/lib/InputItem/style/index.css +524 -0
  80. package/lib/LinkEditor/index.js +5 -5
  81. package/lib/LinkEditor/{mb-popover → mb-link-editor-popover}/index.css +1 -1
  82. package/lib/List/index.css +389 -0
  83. package/lib/List/index.js +41 -0
  84. package/lib/List/list-item.js +169 -0
  85. package/lib/Modal/alert.js +86 -0
  86. package/lib/Modal/index.js +16 -0
  87. package/lib/Modal/modal.js +118 -0
  88. package/lib/Modal/operation.js +81 -0
  89. package/lib/Modal/prompt.js +211 -0
  90. package/lib/Modal/style/index.css +593 -0
  91. package/lib/MultipleSelectEditor/index.js +14 -9
  92. package/lib/Picker/AbstractPicker.js +190 -0
  93. package/lib/Picker/index.js +28 -0
  94. package/lib/Picker/locale/en_US.js +12 -0
  95. package/lib/Picker/locale/ru_RU.js +12 -0
  96. package/lib/Picker/locale/sv_SE.js +12 -0
  97. package/lib/Picker/locale/zh_CN.js +12 -0
  98. package/lib/Picker/popupProps.js +12 -0
  99. package/lib/Picker/style/index.css +145 -0
  100. package/lib/Popover/index.js +63 -0
  101. package/lib/Popover/item.js +55 -0
  102. package/lib/Popover/style/index.css +233 -0
  103. package/lib/Progress/index.css +24 -0
  104. package/lib/Progress/index.js +66 -0
  105. package/lib/Radio/Radio.js +47 -0
  106. package/lib/Radio/RadioItem.js +57 -0
  107. package/lib/Radio/index.css +92 -0
  108. package/lib/Radio/index.js +12 -0
  109. package/lib/RowExpandDialog/column-content/index.js +2 -2
  110. package/lib/RowExpandDialog/index.js +0 -2
  111. package/lib/RowExpandEditor/{add-btn/pc-add-btn → RowExpandAddBtn}/index.js +4 -6
  112. package/lib/RowExpandEditor/{checkbox-editor/pc-editor.js → RowExpandCheckboxEditor/index.js} +13 -9
  113. package/lib/RowExpandEditor/{collaborator-editor/pc-editor → RowExpandCollaboratorEditor}/index.css +1 -1
  114. package/lib/RowExpandEditor/{collaborator-editor/pc-editor → RowExpandCollaboratorEditor}/index.js +7 -6
  115. package/lib/RowExpandEditor/{date-editor/pc-editor.js → RowExpandDateEditor/index.js} +2 -2
  116. package/lib/RowExpandEditor/{department-editor/pc-editor.js → RowExpandDepartmentEditor/index.js} +49 -44
  117. package/lib/RowExpandEditor/{digital-sign-editor/pc-editor → RowExpandDigitalSignEditor}/index.css +1 -1
  118. package/lib/RowExpandEditor/{digital-sign-editor/pc-editor → RowExpandDigitalSignEditor}/index.js +11 -11
  119. package/lib/RowExpandEditor/{duration-editor/pc-editor.js → RowExpandDurationEditor/index.js} +2 -2
  120. package/lib/RowExpandEditor/RowExpandEmailEditor/index.css +2 -0
  121. package/lib/RowExpandEditor/{email-editor/pc-editor → RowExpandEmailEditor}/index.js +3 -3
  122. package/lib/RowExpandEditor/RowExpandFileEditor/index.css +1 -0
  123. package/lib/RowExpandEditor/{file-editor/pc-editor → RowExpandFileEditor}/index.js +9 -9
  124. package/lib/RowExpandEditor/{geolocation-editor/pc-editor → RowExpandGeolocationEditor}/index.js +13 -17
  125. package/lib/RowExpandEditor/{image-editor/pc-editor → RowExpandImageEditor}/index.js +9 -9
  126. package/lib/RowExpandEditor/{long-text-editor/pc-editor → RowExpandLongTextEditor}/index.js +7 -7
  127. package/lib/RowExpandEditor/{multiple-select-editor/pc-editor → RowExpandMultipleSelectEditor}/index.css +1 -1
  128. package/lib/RowExpandEditor/{multiple-select-editor/pc-editor → RowExpandMultipleSelectEditor}/index.js +6 -6
  129. package/lib/RowExpandEditor/{number-editor/pc-editor.js → RowExpandNumberEditor/index.js} +2 -2
  130. package/lib/RowExpandEditor/RowExpandRateEditor/index.css +13 -0
  131. package/lib/RowExpandEditor/{rate-editor/pc-editor.js → RowExpandRateEditor/index.js} +3 -2
  132. package/lib/RowExpandEditor/{single-select-editor/pc-editor → RowExpandSingleSelectorEditor}/index.js +17 -17
  133. package/lib/RowExpandEditor/{text-editor/pc-editor → RowExpandTextEditor}/index.js +7 -7
  134. package/lib/RowExpandEditor/{url-editor/pc-editor → RowExpandUrlEditor}/index.js +6 -6
  135. package/lib/RowExpandEditor/constants.js +34 -34
  136. package/lib/RowExpandFormatter/{department-formatter/pc-formatter.js → RowExpandDepartmentFormatter/index.js} +2 -2
  137. package/lib/RowExpandFormatter/{email-formatter → RowExpandEmailFormatter}/index.css +4 -4
  138. package/lib/RowExpandFormatter/RowExpandRateFormatter/index.css +5 -0
  139. package/lib/RowExpandFormatter/constants.js +17 -17
  140. package/lib/RowExpandFormatter/index.css +18 -33
  141. package/lib/RowExpandFormatter/index.js +1 -1
  142. package/lib/SelectItem/index.js +33 -57
  143. package/lib/SingleSelectEditor/index.js +14 -9
  144. package/lib/SvgIcon/index.js +1 -2
  145. package/lib/TabBar/Tab.js +76 -0
  146. package/lib/TabBar/index.css +142 -0
  147. package/lib/TabBar/index.js +129 -0
  148. package/lib/Tabs/index.css +453 -0
  149. package/lib/Tabs/index.js +39 -0
  150. package/lib/TextareaItem/index.css +235 -0
  151. package/lib/TextareaItem/index.js +231 -0
  152. package/lib/Toast/index.css +67 -0
  153. package/lib/Toast/index.js +131 -0
  154. package/lib/_util/class.js +34 -0
  155. package/lib/_util/closest.js +17 -0
  156. package/lib/_util/exenv.js +8 -0
  157. package/lib/_util/getDataAttr.js +15 -0
  158. package/lib/_util/getLocale.js +42 -0
  159. package/lib/constants/index.js +2 -3
  160. package/lib/css/am.css +390 -0
  161. package/lib/css/mb-cell-editor.css +1 -1
  162. package/lib/index.js +100 -51
  163. package/lib/locales/de.json +1 -3
  164. package/lib/locales/en.json +1 -3
  165. package/lib/locales/es.json +1 -3
  166. package/lib/locales/fr.json +1 -3
  167. package/lib/locales/pt.json +1 -3
  168. package/lib/locales/ru.json +1 -3
  169. package/lib/locales/zh-CN.json +1 -3
  170. package/lib/select-editor/index.js +20 -27
  171. package/lib/select-editor/mb-select-editor/index.css +127 -0
  172. package/lib/select-editor/mb-select-editor/index.js +197 -0
  173. package/lib/select-editor/{pc-editor → pc-select-editor}/index.css +1 -1
  174. package/lib/select-editor/{pc-editor → pc-select-editor}/index.js +7 -7
  175. package/lib/select-editor/select-editor-option.js +84 -0
  176. package/lib/utils/editor-utils.js +2 -6
  177. package/lib/utils/get-event-transfer.js +1 -2
  178. package/lib/utils/utils.js +2 -11
  179. package/package.json +25 -16
  180. package/lib/BodyPortal/index.js +0 -29
  181. package/lib/CheckboxEditor/mb-editor.js +0 -99
  182. package/lib/CheckboxEditor/pc-editor.js +0 -118
  183. package/lib/CollaboratorEditor/mb-editor/index.css +0 -41
  184. package/lib/CollaboratorEditor/mb-editor/index.js +0 -88
  185. package/lib/DateEditor/mb-editor/custom-rc-calendar.css +0 -118
  186. package/lib/DateEditor/mb-editor/index.css +0 -39
  187. package/lib/DateEditor/mb-editor/index.js +0 -215
  188. package/lib/DepartmentSingleSelectEditor/index.js +0 -34
  189. package/lib/DepartmentSingleSelectEditor/mb-editor/index.css +0 -4
  190. package/lib/DepartmentSingleSelectEditor/mb-editor/index.js +0 -230
  191. package/lib/DigitalSignEditor/mb-editor/index.css +0 -35
  192. package/lib/DigitalSignEditor/mb-editor/index.js +0 -144
  193. package/lib/DigitalSignEditor/pc-editor/index.js +0 -181
  194. package/lib/FileEditor/files-previewer/mb-previewer/file-previewer/index.js +0 -122
  195. package/lib/FileEditor/files-previewer/mb-previewer/index.css +0 -39
  196. package/lib/FileEditor/files-previewer/mb-previewer/index.js +0 -64
  197. package/lib/FileEditor/files-previewer/pc-previewer/index.js +0 -276
  198. package/lib/FileEditor/mb-editor/index.css +0 -10
  199. package/lib/FileEditor/mb-editor/index.js +0 -136
  200. package/lib/FileEditor/pc-editor/addition-previewer/index.css +0 -1
  201. package/lib/FileEditor/pc-editor/addition-previewer/local-file-addition/index.css +0 -1
  202. package/lib/FileEditor/pc-editor/index.css +0 -5
  203. package/lib/FileEditor/pc-editor/index.js +0 -274
  204. package/lib/GeolocationEditor/mb-editor/country-editor.js +0 -79
  205. package/lib/GeolocationEditor/mb-editor/index.css +0 -11
  206. package/lib/GeolocationEditor/mb-editor/index.js +0 -125
  207. package/lib/GeolocationEditor/mb-editor/location-editor.js +0 -101
  208. package/lib/GeolocationEditor/mb-editor/map-editor/index.css +0 -11
  209. package/lib/GeolocationEditor/mb-editor/map-editor/index.js +0 -474
  210. package/lib/GeolocationEditor/mb-editor/map-selection-editor/index.css +0 -158
  211. package/lib/GeolocationEditor/mb-editor/map-selection-editor/index.js +0 -530
  212. package/lib/GeolocationEditor/mb-editor/province-city-editor.js +0 -77
  213. package/lib/GeolocationEditor/mb-editor/province-editor.js +0 -76
  214. package/lib/GeolocationEditor/pc-editor/index.js +0 -247
  215. package/lib/ImageEditor/mb-editor/index.css +0 -29
  216. package/lib/ImageEditor/mb-editor/index.js +0 -136
  217. package/lib/ImageEditor/pc-editor/images-previewer/index.js +0 -140
  218. package/lib/ImageEditor/pc-editor/index.css +0 -24
  219. package/lib/ImageEditor/pc-editor/index.js +0 -194
  220. package/lib/MobileFullScreenPage/body/index.css +0 -9
  221. package/lib/MobileFullScreenPage/body/index.js +0 -23
  222. package/lib/MobileFullScreenPage/header/index.css +0 -39
  223. package/lib/MobileFullScreenPage/header/index.js +0 -38
  224. package/lib/MobileFullScreenPage/index.css +0 -13
  225. package/lib/MobileFullScreenPage/index.js +0 -73
  226. package/lib/MobileModal/index.js +0 -41
  227. package/lib/MobileOperationSheet/index.css +0 -27
  228. package/lib/MobileOperationSheet/index.js +0 -92
  229. package/lib/MobileSelector/empty/index.css +0 -3
  230. package/lib/MobileSelector/empty/index.js +0 -23
  231. package/lib/MobileSelector/index.css +0 -32
  232. package/lib/MobileSelector/index.js +0 -57
  233. package/lib/MobileSelector/option/index.css +0 -28
  234. package/lib/MobileSelector/option/index.js +0 -36
  235. package/lib/MobileSelector/options/index.css +0 -8
  236. package/lib/MobileSelector/options/index.js +0 -18
  237. package/lib/MobileSelector/search/index.css +0 -7
  238. package/lib/MobileSelector/search/index.js +0 -26
  239. package/lib/MobileUpload/index.css +0 -1
  240. package/lib/MobileUpload/index.js +0 -160
  241. package/lib/RowExpand/index.js +0 -24
  242. package/lib/RowExpandEditor/add-btn/index.js +0 -24
  243. package/lib/RowExpandEditor/add-btn/mb-add-btn/index.css +0 -3
  244. package/lib/RowExpandEditor/add-btn/mb-add-btn/index.js +0 -19
  245. package/lib/RowExpandEditor/checkbox-editor/index.js +0 -25
  246. package/lib/RowExpandEditor/checkbox-editor/mb-editor/index.css +0 -6
  247. package/lib/RowExpandEditor/checkbox-editor/mb-editor/index.js +0 -36
  248. package/lib/RowExpandEditor/collaborator-editor/index.js +0 -24
  249. package/lib/RowExpandEditor/collaborator-editor/mb-editor/index.css +0 -9
  250. package/lib/RowExpandEditor/collaborator-editor/mb-editor/index.js +0 -163
  251. package/lib/RowExpandEditor/date-editor/index.js +0 -24
  252. package/lib/RowExpandEditor/date-editor/mb-editor.js +0 -82
  253. package/lib/RowExpandEditor/department-editor/index.js +0 -24
  254. package/lib/RowExpandEditor/department-editor/mb-editor.js +0 -65
  255. package/lib/RowExpandEditor/digital-sign-editor/index.js +0 -24
  256. package/lib/RowExpandEditor/digital-sign-editor/mb-editor/index.css +0 -1
  257. package/lib/RowExpandEditor/digital-sign-editor/mb-editor/index.js +0 -130
  258. package/lib/RowExpandEditor/duration-editor/index.js +0 -24
  259. package/lib/RowExpandEditor/duration-editor/mb-editor.js +0 -71
  260. package/lib/RowExpandEditor/email-editor/index.js +0 -24
  261. package/lib/RowExpandEditor/email-editor/mb-editor/index.css +0 -1
  262. package/lib/RowExpandEditor/email-editor/mb-editor/index.js +0 -84
  263. package/lib/RowExpandEditor/email-editor/pc-editor/index.css +0 -1
  264. package/lib/RowExpandEditor/file-editor/index.js +0 -24
  265. package/lib/RowExpandEditor/file-editor/mb-editor/index.js +0 -114
  266. package/lib/RowExpandEditor/file-editor/pc-editor/index.css +0 -1
  267. package/lib/RowExpandEditor/geolocation-editor/index.js +0 -24
  268. package/lib/RowExpandEditor/geolocation-editor/mb-editor/index.js +0 -100
  269. package/lib/RowExpandEditor/image-editor/index.js +0 -24
  270. package/lib/RowExpandEditor/image-editor/mb-editor/index.css +0 -30
  271. package/lib/RowExpandEditor/image-editor/mb-editor/index.js +0 -109
  272. package/lib/RowExpandEditor/long-text-editor/index.js +0 -24
  273. package/lib/RowExpandEditor/long-text-editor/mb-editor/editor/index.css +0 -10
  274. package/lib/RowExpandEditor/long-text-editor/mb-editor/editor/index.js +0 -80
  275. package/lib/RowExpandEditor/long-text-editor/mb-editor/index.css +0 -3
  276. package/lib/RowExpandEditor/long-text-editor/mb-editor/index.js +0 -91
  277. package/lib/RowExpandEditor/multiple-select-editor/index.js +0 -24
  278. package/lib/RowExpandEditor/multiple-select-editor/mb-editor/index.js +0 -154
  279. package/lib/RowExpandEditor/number-editor/index.js +0 -24
  280. package/lib/RowExpandEditor/number-editor/mb-editor/index.css +0 -3
  281. package/lib/RowExpandEditor/number-editor/mb-editor/index.js +0 -76
  282. package/lib/RowExpandEditor/rate-editor/index.css +0 -34
  283. package/lib/RowExpandEditor/rate-editor/index.js +0 -25
  284. package/lib/RowExpandEditor/rate-editor/mb-editor.js +0 -92
  285. package/lib/RowExpandEditor/right-angle/index.css +0 -6
  286. package/lib/RowExpandEditor/right-angle/index.js +0 -17
  287. package/lib/RowExpandEditor/single-select-editor/index.js +0 -24
  288. package/lib/RowExpandEditor/single-select-editor/mb-editor/index.css +0 -8
  289. package/lib/RowExpandEditor/single-select-editor/mb-editor/index.js +0 -134
  290. package/lib/RowExpandEditor/text-editor/index.js +0 -24
  291. package/lib/RowExpandEditor/text-editor/mb-editor/index.css +0 -14
  292. package/lib/RowExpandEditor/text-editor/mb-editor/index.js +0 -37
  293. package/lib/RowExpandEditor/url-editor/index.js +0 -24
  294. package/lib/RowExpandEditor/url-editor/mb-editor/index.css +0 -17
  295. package/lib/RowExpandEditor/url-editor/mb-editor/index.js +0 -87
  296. package/lib/RowExpandFormatter/department-formatter/index.js +0 -19
  297. package/lib/RowExpandFormatter/department-formatter/mb-formatter.js +0 -20
  298. package/lib/RowExpandFormatter/rate-formatter/index.css +0 -5
  299. package/lib/RowExpandView/body/index.css +0 -173
  300. package/lib/RowExpandView/body/index.js +0 -111
  301. package/lib/RowExpandView/column-content/index.css +0 -27
  302. package/lib/RowExpandView/column-content/index.js +0 -25
  303. package/lib/RowExpandView/index.css +0 -3
  304. package/lib/RowExpandView/index.js +0 -178
  305. package/lib/select-editor/mb-editor/index.css +0 -1
  306. package/lib/select-editor/mb-editor/index.js +0 -105
  307. /package/lib/CollaboratorEditor/{pc-editor → pc-collaborator-editor}/index.css +0 -0
  308. /package/lib/CollaboratorEditor/{pc-editor → pc-collaborator-editor}/index.js +0 -0
  309. /package/lib/{constants/departments.js → Department-editor/constants.js} +0 -0
  310. /package/lib/{DepartmentMultipleSelectEditor → Department-editor/department-multiple-select}/index.css +0 -0
  311. /package/lib/{utils/departments.js → Department-editor/utils.js} +0 -0
  312. /package/lib/DigitalSignEditor/{pc-editor/index.css → index.css} +0 -0
  313. /package/lib/FileEditor/files-previewer/{pc-previewer/file-previewer → file-previewer}/file-name-editor/index.css +0 -0
  314. /package/lib/GeolocationEditor/{pc-editor/map-editor → map-editor}/large-editor/index.css +0 -0
  315. /package/lib/GeolocationEditor/{pc-editor/map-selection-editor → map-selection-editor}/large-editor/index.css +0 -0
  316. /package/lib/GeolocationEditor/{pc-editor/parse-geolocation.js → parse-geolocation.js} +0 -0
  317. /package/lib/GeolocationEditor/{pc-editor/selector-list.js → selector-list.js} +0 -0
  318. /package/lib/ImageEditor/{pc-editor/addition-previewer → addition-previewer}/image-link/index.css +0 -0
  319. /package/lib/ImageEditor/{pc-editor/addition-previewer → addition-previewer}/index.css +0 -0
  320. /package/lib/ImageEditor/{pc-editor/addition-previewer → addition-previewer}/local-image-addition/index.css +0 -0
  321. /package/lib/LinkEditor/{mb-popover → mb-link-editor-popover}/index.js +0 -0
  322. /package/lib/LinkEditor/{pc-popover → pc-link-editor-popover}/index.css +0 -0
  323. /package/lib/LinkEditor/{pc-popover → pc-link-editor-popover}/index.js +0 -0
  324. /package/lib/RowExpandEditor/{add-btn/pc-add-btn → RowExpandAddBtn}/index.css +0 -0
  325. /package/lib/RowExpandEditor/{checkbox-editor → RowExpandCheckboxEditor}/index.css +0 -0
  326. /package/lib/RowExpandEditor/{geolocation-editor/pc-editor → RowExpandGeolocationEditor}/index.css +0 -0
  327. /package/lib/RowExpandEditor/{image-editor/pc-editor → RowExpandImageEditor}/index.css +0 -0
  328. /package/lib/RowExpandEditor/{long-text-editor/pc-editor → RowExpandLongTextEditor}/index.css +0 -0
  329. /package/lib/RowExpandEditor/{single-select-editor/pc-editor → RowExpandSingleSelectorEditor}/index.css +0 -0
  330. /package/lib/RowExpandEditor/{text-editor/pc-editor → RowExpandTextEditor}/index.css +0 -0
  331. /package/lib/RowExpandEditor/{url-editor/pc-editor → RowExpandUrlEditor}/index.css +0 -0
  332. /package/lib/RowExpandFormatter/{email-formatter → RowExpandEmailFormatter}/index.js +0 -0
  333. /package/lib/RowExpandFormatter/{file-formatter → RowExpandFileFormatter}/index.css +0 -0
  334. /package/lib/RowExpandFormatter/{file-formatter → RowExpandFileFormatter}/index.js +0 -0
  335. /package/lib/RowExpandFormatter/{file-formatter → RowExpandFileFormatter}/row-expand-file-item-formatter.js +0 -0
  336. /package/lib/RowExpandFormatter/{formula-formatter → RowExpandFormulaFormatter}/index.js +0 -0
  337. /package/lib/RowExpandFormatter/{image-formatter → RowExpandImageFormatter}/index.css +0 -0
  338. /package/lib/RowExpandFormatter/{image-formatter → RowExpandImageFormatter}/index.js +0 -0
  339. /package/lib/RowExpandFormatter/{image-formatter → RowExpandImageFormatter}/row-expand-image-item-formatter.js +0 -0
  340. /package/lib/RowExpandFormatter/{link-formatter → RowExpandLinkFormatter}/collaborator-item-formatter.js +0 -0
  341. /package/lib/RowExpandFormatter/{link-formatter → RowExpandLinkFormatter}/index.css +0 -0
  342. /package/lib/RowExpandFormatter/{link-formatter → RowExpandLinkFormatter}/index.js +0 -0
  343. /package/lib/RowExpandFormatter/{link-formatter → RowExpandLinkFormatter}/value-display-utils.js +0 -0
  344. /package/lib/RowExpandFormatter/{rate-formatter → RowExpandRateFormatter}/index.js +0 -0
  345. /package/lib/RowExpandFormatter/{url-formatter → RowExpandUrlFormatter}/index.css +0 -0
  346. /package/lib/RowExpandFormatter/{url-formatter → RowExpandUrlFormatter}/index.js +0 -0
@@ -1,24 +0,0 @@
1
- "use strict";
2
-
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
- var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
5
- Object.defineProperty(exports, "__esModule", {
6
- value: true
7
- });
8
- exports.default = void 0;
9
- var _react = _interopRequireWildcard(require("react"));
10
- var _reactResponsive = _interopRequireDefault(require("react-responsive"));
11
- var _pcEditor = _interopRequireDefault(require("./pc-editor"));
12
- var _mbEditor = _interopRequireDefault(require("./mb-editor"));
13
- const RowExpandNumberEditor = /*#__PURE__*/(0, _react.forwardRef)((props, ref) => {
14
- return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_reactResponsive.default, {
15
- query: "(min-width: 768px)"
16
- }, /*#__PURE__*/_react.default.createElement(_pcEditor.default, Object.assign({}, props, {
17
- ref: ref
18
- }))), /*#__PURE__*/_react.default.createElement(_reactResponsive.default, {
19
- query: "(max-width: 768px)"
20
- }, /*#__PURE__*/_react.default.createElement(_mbEditor.default, Object.assign({}, props, {
21
- ref: ref
22
- }))));
23
- });
24
- var _default = exports.default = RowExpandNumberEditor;
@@ -1,3 +0,0 @@
1
- .dtable-ui-mobile-row-expand-number-editor-container .form-control {
2
- width: 100% !important;
3
- }
@@ -1,76 +0,0 @@
1
- "use strict";
2
-
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
- Object.defineProperty(exports, "__esModule", {
5
- value: true
6
- });
7
- exports.default = void 0;
8
- var _react = _interopRequireDefault(require("react"));
9
- var _dtableUtils = require("dtable-utils");
10
- var _NumberEditor = _interopRequireDefault(require("../../../NumberEditor"));
11
- require("./index.css");
12
- class RowExpandMBNumberEditor extends _react.default.Component {
13
- constructor(props) {
14
- super(props);
15
- this.toggleEditor = () => {
16
- if (this.props.readOnly) return;
17
- this.setState({
18
- isShowEditor: !this.state.isShowEditor
19
- });
20
- };
21
- this.onCommit = value => {
22
- console.log(value);
23
- this.props.onCommit(value);
24
- this.setState({
25
- value
26
- }, () => {
27
- this.setState({
28
- isShowEditor: false
29
- });
30
- });
31
- };
32
- this.onBlur = () => {
33
- this.setState({
34
- isShowEditor: false
35
- });
36
- };
37
- const {
38
- column,
39
- row
40
- } = props;
41
- this.state = {
42
- isShowEditor: false,
43
- value: row[column.key]
44
- };
45
- }
46
- render() {
47
- const {
48
- column
49
- } = this.props;
50
- const {
51
- value,
52
- isShowEditor
53
- } = this.state;
54
- let formatValue = '';
55
- if (!isShowEditor && (0, _dtableUtils.isNumber)(value)) {
56
- const {
57
- data = {}
58
- } = column;
59
- formatValue = (0, _dtableUtils.getNumberDisplayString)(value, data);
60
- }
61
- const dom = isShowEditor ? /*#__PURE__*/_react.default.createElement(_NumberEditor.default, {
62
- isInModal: true,
63
- column: column,
64
- value: value,
65
- onBlur: this.onBlur,
66
- onCommit: this.onCommit
67
- }) : /*#__PURE__*/_react.default.createElement("div", {
68
- className: "w-100 h-100",
69
- onClick: this.toggleEditor
70
- }, formatValue);
71
- return /*#__PURE__*/_react.default.createElement("div", {
72
- className: "dtable-ui-mobile-row-expand-input-editor-container dtable-ui-mobile-row-expand-number-editor-container"
73
- }, dom);
74
- }
75
- }
76
- var _default = exports.default = RowExpandMBNumberEditor;
@@ -1,34 +0,0 @@
1
- .dtable-ui.dtable-ui-row-expand-rate-editor {
2
- display: flex;
3
- }
4
-
5
- .dtable-ui.dtable-ui-row-expand-rate-editor > div {
6
- padding-right: 5px;
7
- cursor: pointer;
8
- line-height: 1.5;
9
- }
10
-
11
- .dtable-ui.dtable-ui-row-expand-rate-editor .rate-item-active {
12
- opacity: 1 !important;
13
- }
14
-
15
- .dtable-ui-mobile-row-expand-rate-editor {
16
- min-height: 50px;
17
- align-items: center;
18
- flex-wrap: wrap;
19
- padding: 10px 0;
20
- }
21
-
22
- .dtable-ui-mobile-row-expand-rate-editor .dtable-ui-mobile-row-expand-rate-item {
23
- height: 24px;
24
- width: 24px;
25
- margin-top: 3px;
26
- margin-bottom: 3px;
27
- margin-right: 0.25rem;
28
- padding-right: 0 !important;
29
- }
30
-
31
- .dtable-ui-mobile-row-expand-rate-editor .dtable-ui-mobile-row-expand-rate-item .dtable-font {
32
- font-size: 24px;
33
- line-height: 1;
34
- }
@@ -1,25 +0,0 @@
1
- "use strict";
2
-
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
- var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
5
- Object.defineProperty(exports, "__esModule", {
6
- value: true
7
- });
8
- exports.default = void 0;
9
- var _react = _interopRequireWildcard(require("react"));
10
- var _reactResponsive = _interopRequireDefault(require("react-responsive"));
11
- var _pcEditor = _interopRequireDefault(require("./pc-editor"));
12
- var _mbEditor = _interopRequireDefault(require("./mb-editor"));
13
- require("./index.css");
14
- const RowExpandRateEditor = /*#__PURE__*/(0, _react.forwardRef)((props, ref) => {
15
- return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_reactResponsive.default, {
16
- query: "(min-width: 768px)"
17
- }, /*#__PURE__*/_react.default.createElement(_pcEditor.default, Object.assign({}, props, {
18
- ref: ref
19
- }))), /*#__PURE__*/_react.default.createElement(_reactResponsive.default, {
20
- query: "(max-width: 768px)"
21
- }, /*#__PURE__*/_react.default.createElement(_mbEditor.default, Object.assign({}, props, {
22
- ref: ref
23
- }))));
24
- });
25
- var _default = exports.default = RowExpandRateEditor;
@@ -1,92 +0,0 @@
1
- "use strict";
2
-
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
- Object.defineProperty(exports, "__esModule", {
5
- value: true
6
- });
7
- exports.default = void 0;
8
- var _react = _interopRequireDefault(require("react"));
9
- var _classnames = _interopRequireDefault(require("classnames"));
10
- class RowExpandMBRateEditor extends _react.default.Component {
11
- constructor(props) {
12
- super(props);
13
- this.onChangeRateNumber = index => {
14
- if (!this.canEdit) return;
15
- const {
16
- value
17
- } = this.state;
18
- const newValue = value === index ? '' : index;
19
- this.setState({
20
- value: newValue
21
- });
22
- this.props.onCommit(newValue);
23
- };
24
- this.getRateMaxStar = () => {
25
- const {
26
- value
27
- } = this.state;
28
- const {
29
- column
30
- } = this.props;
31
- const {
32
- rate_max_number,
33
- rate_style_color,
34
- rate_style_type
35
- } = column.data || {};
36
- const rateShowType = rate_style_type ? rate_style_type : 'dtable-icon-rate';
37
- let rateList = [];
38
- for (let i = 0; i < rate_max_number; i++) {
39
- const rateItemIndex = i + 1;
40
- const style = {
41
- color: value >= rateItemIndex ? rate_style_color : '#e5e5e5',
42
- opacity: 0.4
43
- };
44
- const rateItem = /*#__PURE__*/_react.default.createElement("div", {
45
- key: i,
46
- onClick: this.onChangeRateNumber.bind(this, rateItemIndex),
47
- style: style,
48
- className: (0, _classnames.default)('dtable-ui-mobile-row-expand-rate-item', {
49
- 'rate-item-active': value >= rateItemIndex
50
- })
51
- }, /*#__PURE__*/_react.default.createElement("span", {
52
- className: "dtable-font ".concat(rateShowType)
53
- }));
54
- rateList.push(rateItem);
55
- }
56
- return rateList;
57
- };
58
- this.state = {
59
- value: props.value || ''
60
- };
61
- let {
62
- column: _column
63
- } = this.props;
64
- const {
65
- editable
66
- } = _column;
67
- this.canEdit = editable;
68
- }
69
- UNSAFE_componentWillReceiveProps(nextProps) {
70
- const {
71
- column,
72
- row,
73
- valueKey
74
- } = nextProps;
75
- if (row._id !== this.props.row._id) {
76
- this.setState({
77
- value: row[column[valueKey]] || ''
78
- });
79
- } else if (nextProps.value !== this.props.value) {
80
- this.setState({
81
- value: nextProps.value || ''
82
- });
83
- }
84
- }
85
- render() {
86
- const rateList = this.getRateMaxStar();
87
- return /*#__PURE__*/_react.default.createElement("div", {
88
- className: "dtable-ui-mobile-row-expand-rate-editor dtable-ui dtable-ui-row-expand-rate-editor"
89
- }, rateList);
90
- }
91
- }
92
- var _default = exports.default = RowExpandMBRateEditor;
@@ -1,6 +0,0 @@
1
- .dtable-ui-mobile-row-expand-angle-right {
2
- color: #999;
3
- position: absolute;
4
- right: 0;
5
- top: calc(50% - 12px);
6
- }
@@ -1,17 +0,0 @@
1
- "use strict";
2
-
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
- Object.defineProperty(exports, "__esModule", {
5
- value: true
6
- });
7
- exports.default = RightAngle;
8
- var _react = _interopRequireDefault(require("react"));
9
- require("./index.css");
10
- function RightAngle() {
11
- return /*#__PURE__*/_react.default.createElement("span", {
12
- className: "dtable-ui-mobile-row-expand-angle-right"
13
- }, /*#__PURE__*/_react.default.createElement("i", {
14
- "aria-hidden": "true",
15
- className: "dtable-font dtable-icon-right"
16
- }));
17
- }
@@ -1,24 +0,0 @@
1
- "use strict";
2
-
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
- var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
5
- Object.defineProperty(exports, "__esModule", {
6
- value: true
7
- });
8
- exports.default = void 0;
9
- var _react = _interopRequireWildcard(require("react"));
10
- var _reactResponsive = _interopRequireDefault(require("react-responsive"));
11
- var _pcEditor = _interopRequireDefault(require("./pc-editor"));
12
- var _mbEditor = _interopRequireDefault(require("./mb-editor"));
13
- const RowExpandSingleSelectEditor = /*#__PURE__*/(0, _react.forwardRef)((props, ref) => {
14
- return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_reactResponsive.default, {
15
- query: "(min-width: 768px)"
16
- }, /*#__PURE__*/_react.default.createElement(_pcEditor.default, Object.assign({}, props, {
17
- ref: ref
18
- }))), /*#__PURE__*/_react.default.createElement(_reactResponsive.default, {
19
- query: "(max-width: 768px)"
20
- }, /*#__PURE__*/_react.default.createElement(_mbEditor.default, Object.assign({}, props, {
21
- ref: ref
22
- }))));
23
- });
24
- var _default = exports.default = RowExpandSingleSelectEditor;
@@ -1,8 +0,0 @@
1
- .dtable-ui-mobile-row-expand-options-editor {
2
- min-height: 50px;
3
- }
4
-
5
- .dtable-ui-mobile-row-expand-options-editor .dtable-ui-mobile-row-expand-add-btn {
6
- height: 100%;
7
- line-height: 50px;
8
- }
@@ -1,134 +0,0 @@
1
- "use strict";
2
-
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
- Object.defineProperty(exports, "__esModule", {
5
- value: true
6
- });
7
- exports.default = void 0;
8
- var _react = _interopRequireDefault(require("react"));
9
- var _dtableUtils = require("dtable-utils");
10
- var _SingleSelectEditor = _interopRequireDefault(require("../../../SingleSelectEditor"));
11
- var _SelectItem = _interopRequireDefault(require("../../../SelectItem"));
12
- var _lang = require("../../../lang");
13
- var _rightAngle = _interopRequireDefault(require("../../right-angle"));
14
- var _objectUtils = _interopRequireDefault(require("../../../utils/object-utils"));
15
- var _constants = require("../../../constants");
16
- var _addBtn = _interopRequireDefault(require("../../add-btn"));
17
- require("./index.css");
18
- class RowExpandMBSingleSelectEditor extends _react.default.Component {
19
- constructor(_props) {
20
- super(_props);
21
- this.getOptions = props => {
22
- const {
23
- column,
24
- row,
25
- columns
26
- } = props;
27
- const options = (0, _dtableUtils.getColumnOptions)(column);
28
- const {
29
- data
30
- } = column;
31
- const {
32
- cascade_column_key,
33
- cascade_settings
34
- } = data || {};
35
- if (cascade_column_key && Array.isArray(columns)) {
36
- const cascadeColumn = columns.find(c => c.key === cascade_column_key);
37
- if (cascadeColumn) {
38
- const cascadeColumnValue = row[cascade_column_key];
39
- if (!cascadeColumnValue) return [];
40
- const cascadeSetting = cascade_settings[cascadeColumnValue];
41
- if (!cascadeSetting || !Array.isArray(cascadeSetting) || cascadeSetting.length === 0) return [];
42
- return options.filter(option => cascadeSetting.includes(option.id));
43
- }
44
- }
45
- return options;
46
- };
47
- this.toggleEditor = value => {
48
- this.setState({
49
- showEditor: value
50
- });
51
- };
52
- this.openEditor = event => {
53
- event.stopPropagation();
54
- this.toggleEditor(true);
55
- };
56
- this.closeEditor = () => {
57
- this.toggleEditor(false);
58
- };
59
- this.onChange = option => {
60
- let newValue = option[this.key];
61
- if (this.state.value === newValue) newValue = null;
62
- this.setState({
63
- value: newValue
64
- });
65
- this.props.onCommit(newValue);
66
- this.toggleEditor(false);
67
- };
68
- this.renderOption = () => {
69
- const {
70
- value
71
- } = this.state;
72
- let option = this.options.find(o => o[this.key] === value);
73
- option = {
74
- name: (0, _lang.getLocale)(_constants.DELETED_OPTION_TIPS),
75
- color: _constants.DELETED_OPTION_BACKGROUND_COLOR,
76
- ...option
77
- };
78
- return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, value ? /*#__PURE__*/_react.default.createElement("div", {
79
- style: {
80
- height: 50,
81
- padding: '10px 0'
82
- }
83
- }, /*#__PURE__*/_react.default.createElement(_SelectItem.default, {
84
- option: option
85
- })) : /*#__PURE__*/_react.default.createElement(_addBtn.default, {
86
- text: (0, _lang.getLocale)('Select_an_option')
87
- }));
88
- };
89
- this.state = {
90
- value: _props.value,
91
- isShowEditor: false
92
- };
93
- this.key = _props.valueKey === 'name' ? 'name' : 'id';
94
- this.options = this.getOptions(_props);
95
- }
96
- UNSAFE_componentWillReceiveProps(nextProps) {
97
- const {
98
- value,
99
- column
100
- } = nextProps;
101
- if (value !== this.props.value || !_objectUtils.default.isSameObject(column, this.props.column)) {
102
- this.options = this.getOptions(nextProps);
103
- this.setState({
104
- value,
105
- isShowEditor: false
106
- });
107
- }
108
- }
109
- render() {
110
- const {
111
- column,
112
- isSupportNewOption,
113
- onAddNewOption
114
- } = this.props;
115
- const {
116
- showEditor,
117
- value
118
- } = this.state;
119
- return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement("div", {
120
- className: "dtable-ui dtable-ui-mobile-row-expand-options-editor position-relative",
121
- onClick: this.openEditor
122
- }, this.renderOption(), /*#__PURE__*/_react.default.createElement(_rightAngle.default, null)), showEditor && /*#__PURE__*/_react.default.createElement(_SingleSelectEditor.default, {
123
- value: value,
124
- column: column,
125
- valueKey: this.key,
126
- options: this.options,
127
- onCommit: this.onChange,
128
- onClose: this.closeEditor,
129
- isSupportNewOption: isSupportNewOption,
130
- onAddNewOption: onAddNewOption
131
- }));
132
- }
133
- }
134
- var _default = exports.default = RowExpandMBSingleSelectEditor;
@@ -1,24 +0,0 @@
1
- "use strict";
2
-
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
- var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
5
- Object.defineProperty(exports, "__esModule", {
6
- value: true
7
- });
8
- exports.default = void 0;
9
- var _react = _interopRequireWildcard(require("react"));
10
- var _reactResponsive = _interopRequireDefault(require("react-responsive"));
11
- var _pcEditor = _interopRequireDefault(require("./pc-editor"));
12
- var _mbEditor = _interopRequireDefault(require("./mb-editor"));
13
- const RowExpandTextEditor = /*#__PURE__*/(0, _react.forwardRef)((props, ref) => {
14
- return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_reactResponsive.default, {
15
- query: "(min-width: 768px)"
16
- }, /*#__PURE__*/_react.default.createElement(_pcEditor.default, Object.assign({}, props, {
17
- ref: ref
18
- }))), /*#__PURE__*/_react.default.createElement(_reactResponsive.default, {
19
- query: "(max-width: 768px)"
20
- }, /*#__PURE__*/_react.default.createElement(_mbEditor.default, Object.assign({}, props, {
21
- ref: ref
22
- }))));
23
- });
24
- var _default = exports.default = RowExpandTextEditor;
@@ -1,14 +0,0 @@
1
- .dtable-ui-mobile-row-expand-input-editor-container {
2
- height: 50px;
3
- line-height: 50px;
4
- }
5
-
6
- .dtable-ui-mobile-row-expand-input-editor-container .form-control {
7
- border: none;
8
- padding: 0;
9
- height: 50px;
10
- }
11
-
12
- .dtable-ui-mobile-row-expand-input-editor-container .form-control:focus {
13
- box-shadow: none;
14
- }
@@ -1,37 +0,0 @@
1
- "use strict";
2
-
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
- Object.defineProperty(exports, "__esModule", {
5
- value: true
6
- });
7
- exports.default = void 0;
8
- var _react = _interopRequireDefault(require("react"));
9
- var _TextEditor = _interopRequireDefault(require("../../../TextEditor"));
10
- require("./index.css");
11
- class RowExpandMBTextEditor extends _react.default.Component {
12
- constructor(props) {
13
- super(props);
14
- this.onCommit = () => {
15
- const value = this.editor.getValue();
16
- this.props.onCommit(value);
17
- };
18
- this.editor = null;
19
- }
20
- render() {
21
- const {
22
- readOnly,
23
- column,
24
- value
25
- } = this.props;
26
- return /*#__PURE__*/_react.default.createElement("div", {
27
- className: "dtable-ui-mobile-row-expand-input-editor-container"
28
- }, /*#__PURE__*/_react.default.createElement(_TextEditor.default, {
29
- ref: ref => this.editor = ref,
30
- readOnly: readOnly,
31
- column: column,
32
- value: value,
33
- onCommit: this.onCommit
34
- }));
35
- }
36
- }
37
- var _default = exports.default = RowExpandMBTextEditor;
@@ -1,24 +0,0 @@
1
- "use strict";
2
-
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
- var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
5
- Object.defineProperty(exports, "__esModule", {
6
- value: true
7
- });
8
- exports.default = void 0;
9
- var _react = _interopRequireWildcard(require("react"));
10
- var _reactResponsive = _interopRequireDefault(require("react-responsive"));
11
- var _pcEditor = _interopRequireDefault(require("./pc-editor"));
12
- var _mbEditor = _interopRequireDefault(require("./mb-editor"));
13
- const RowExpandUrlEditor = /*#__PURE__*/(0, _react.forwardRef)((props, ref) => {
14
- return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_reactResponsive.default, {
15
- query: "(min-width: 768px)"
16
- }, /*#__PURE__*/_react.default.createElement(_pcEditor.default, Object.assign({}, props, {
17
- ref: ref
18
- }))), /*#__PURE__*/_react.default.createElement(_reactResponsive.default, {
19
- query: "(max-width: 768px)"
20
- }, /*#__PURE__*/_react.default.createElement(_mbEditor.default, Object.assign({}, props, {
21
- ref: ref
22
- }))));
23
- });
24
- var _default = exports.default = RowExpandUrlEditor;
@@ -1,17 +0,0 @@
1
- .dtable-ui-mobile-row-expand-url-editor-container .dtable-ui-mobile-row-expand-url-input {
2
- text-decoration: underline;
3
- padding-right: 40px;
4
- }
5
-
6
- .dtable-ui-mobile-row-expand-url-editor-container .dtable-ui-mobile-row-expand-jump-link {
7
- height: 22px;
8
- line-height: 22px;
9
- position: absolute;
10
- right: 0;
11
- top: 14px;
12
- background: #fff;
13
- color: #999;
14
- border: 1px solid #eee;
15
- box-shadow: 0 0 1px;
16
- padding: 0 3px;
17
- }
@@ -1,87 +0,0 @@
1
- "use strict";
2
-
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
- Object.defineProperty(exports, "__esModule", {
5
- value: true
6
- });
7
- exports.default = void 0;
8
- var _react = _interopRequireDefault(require("react"));
9
- var _toaster = _interopRequireDefault(require("../../../toaster"));
10
- var _utils = require("../../../utils/utils");
11
- var _lang = require("../../../lang");
12
- require("./index.css");
13
- class RowExpandMBUrlEditor extends _react.default.Component {
14
- constructor(props) {
15
- super(props);
16
- this.onBlur = () => {
17
- const {
18
- onCommit
19
- } = this.props;
20
- onCommit(this.state.value.trim());
21
- };
22
- this.onChange = e => {
23
- let value = e.target.value;
24
- if (value === this.state.value) return;
25
- this.setState({
26
- value
27
- });
28
- };
29
- this.onCut = e => {
30
- e.stopPropagation();
31
- };
32
- this.onPaste = e => {
33
- e.stopPropagation();
34
- };
35
- this.onOpenUrlLink = () => {
36
- const {
37
- value
38
- } = this.state;
39
- let newValue = value.trim();
40
- if (!(0, _utils.isValidUrl)(newValue)) {
41
- newValue = "http://".concat(newValue);
42
- }
43
- try {
44
- (0, _utils.openUrlLink)(newValue);
45
- } catch {
46
- _toaster.default.danger((0, _lang.getLocale)('URL_is_invalid'));
47
- }
48
- };
49
- this.state = {
50
- value: props.value || ''
51
- };
52
- }
53
- UNSAFE_componentWillReceiveProps(nextProps) {
54
- const {
55
- column,
56
- row
57
- } = nextProps;
58
- if (row._id !== this.props.row._id) {
59
- this.setState({
60
- value: row[column[this.props.valueKey]] || ''
61
- });
62
- }
63
- }
64
- render() {
65
- const {
66
- value
67
- } = this.state;
68
- return /*#__PURE__*/_react.default.createElement("div", {
69
- className: "dtable-ui-mobile-row-expand-input-editor-container position-relative dtable-ui-mobile-row-expand-url-editor-container"
70
- }, /*#__PURE__*/_react.default.createElement("input", {
71
- type: "text",
72
- onFocus: this.onFocus,
73
- onBlur: this.onBlur,
74
- onCut: this.onCut,
75
- onPaste: this.onPaste,
76
- onChange: this.onChange,
77
- className: "form-control dtable-ui-mobile-row-expand-url-input",
78
- value: value || '',
79
- onKeyDown: this.onKeyDown
80
- }), value && value.trim() && /*#__PURE__*/_react.default.createElement("span", {
81
- "aria-hidden": "true",
82
- className: "dtable-font dtable-icon-url dtable-ui-mobile-row-expand-jump-link",
83
- onClick: this.onOpenUrlLink
84
- }));
85
- }
86
- }
87
- var _default = exports.default = RowExpandMBUrlEditor;