dtable-ui-component 6.0.109 → 6.0.110-aik.2

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 (195) hide show
  1. package/lib/ActionSheet/index.js +42 -35
  2. package/lib/ActivityIndicator/index.js +9 -9
  3. package/lib/AsyncUserSelect/index.css +54 -12
  4. package/lib/AsyncUserSelect/index.js +27 -16
  5. package/lib/Badge/index.js +27 -31
  6. package/lib/CheckboxEditor/index.js +15 -14
  7. package/lib/CollaboratorEditor/index.js +16 -15
  8. package/lib/CollaboratorEditor/pc-editor/index.js +1 -1
  9. package/lib/CollapsibleSettingLayout/index.js +1 -1
  10. package/lib/Comment/body/comment.js +1 -1
  11. package/lib/Comment/body/index.js +7 -9
  12. package/lib/Comment/footer/index.js +1 -1
  13. package/lib/Comment/footer/input/index.js +5 -5
  14. package/lib/Comment/footer/input/participant/index.js +1 -1
  15. package/lib/Comment/footer/participants/participant-select/index.js +2 -2
  16. package/lib/Comment/utils/utilities.js +1 -1
  17. package/lib/DTableColorPicker/ColorPickerPortal/index.js +8 -6
  18. package/lib/DTableColorPicker/index.js +13 -12
  19. package/lib/DTableColorPicker/utils.js +1 -1
  20. package/lib/DTableCommonAddTool/index.js +2 -2
  21. package/lib/DTableFiltersPopover/index.js +1 -1
  22. package/lib/DTableFiltersPopover/utils/index.js +1 -1
  23. package/lib/DTableFiltersPopover/widgets/filter-group.js +2 -2
  24. package/lib/DTableFiltersPopover/widgets/filter-item.js +1 -1
  25. package/lib/DTableFiltersPopover/widgets/filter-list/index.js +1 -1
  26. package/lib/DTableFiltersPopover/widgets/rate-item.js +5 -5
  27. package/lib/DTableGroupSelect/index.css +42 -5
  28. package/lib/DTableGroupSelect/select-option-group.css +3 -3
  29. package/lib/DTableGroupSelect/select-option-group.js +23 -5
  30. package/lib/DTableIcon/index.js +4 -4
  31. package/lib/DTableIcon/svg-icon.js +4 -4
  32. package/lib/DTableModalHeader/index.js +6 -8
  33. package/lib/DTableRadioGroup/index.js +3 -3
  34. package/lib/DTableSelect/dtable-select-label.js +1 -1
  35. package/lib/DTableSelect/utils.js +55 -36
  36. package/lib/DateEditor/index.js +13 -10
  37. package/lib/DateEditor/pc-editor.js +1 -1
  38. package/lib/DatePicker/utils.js +4 -4
  39. package/lib/DepartmentMultipleSelectEditor/index.js +3 -3
  40. package/lib/DepartmentSelectFilter/index.js +5 -2
  41. package/lib/DepartmentSingleSelectEditor/index.js +15 -14
  42. package/lib/DepartmentSingleSelectEditor/mb-editor/index.js +2 -2
  43. package/lib/DepartmentSingleSelectEditor/pc-editor/department-single-select.js +6 -6
  44. package/lib/DigitalSignEditor/index.js +15 -14
  45. package/lib/DigitalSignEditor/mb-editor/index.js +4 -4
  46. package/lib/DigitalSignEditor/pc-editor/index.js +7 -6
  47. package/lib/DigitalSignEditor/service.js +1 -1
  48. package/lib/DigitalSignEditor/signature-board/index.js +2 -2
  49. package/lib/DigitalSignFormatter/utils.js +1 -1
  50. package/lib/Drawer/index.js +3 -2
  51. package/lib/FieldDisplaySetting/field-item.js +1 -1
  52. package/lib/FieldDisplaySetting/index.js +11 -9
  53. package/lib/FileEditor/files-previewer/index.js +15 -14
  54. package/lib/FileEditor/files-previewer/mb-previewer/file-previewer/index.js +2 -2
  55. package/lib/FileEditor/files-previewer/pc-previewer/file-previewer/index.js +3 -3
  56. package/lib/FileEditor/index.js +15 -14
  57. package/lib/FileEditor/pc-editor/addition-previewer/index.js +1 -1
  58. package/lib/FileEditor/pc-editor/addition-previewer/local-file-addition/index.js +6 -6
  59. package/lib/FileEditor/pc-editor/index.js +3 -3
  60. package/lib/FileFormatter/index.js +1 -1
  61. package/lib/FileItemFormatter/index.js +1 -1
  62. package/lib/FileUploader/index.js +1 -1
  63. package/lib/FormulaFormatter/index.js +15 -9
  64. package/lib/GeolocationEditor/index.js +23 -19
  65. package/lib/GeolocationEditor/map-editor-utils.js +10 -6
  66. package/lib/GeolocationEditor/mb-editor/index.js +27 -23
  67. package/lib/GeolocationEditor/mb-editor/map-editor/index.js +9 -6
  68. package/lib/GeolocationEditor/pc-editor/country-editor.js +2 -2
  69. package/lib/GeolocationEditor/pc-editor/index.js +21 -15
  70. package/lib/GeolocationEditor/pc-editor/location-editor.js +2 -2
  71. package/lib/GeolocationEditor/pc-editor/map-editor/index.js +13 -9
  72. package/lib/GeolocationEditor/pc-editor/map-editor/large-editor/index.js +9 -6
  73. package/lib/GeolocationEditor/pc-editor/map-selection-editor/index.js +24 -7
  74. package/lib/GeolocationEditor/pc-editor/map-selection-editor/large-editor/index.js +20 -3
  75. package/lib/GeolocationEditor/pc-editor/province-city-editor.js +1 -1
  76. package/lib/GeolocationEditor/pc-editor/province-editor.js +2 -2
  77. package/lib/GeolocationEditor/pc-editor/selector-list.js +1 -1
  78. package/lib/HtmlLongTextFormatter/index.js +1 -1
  79. package/lib/Icon/index.js +13 -17
  80. package/lib/Icon/load-sprite.js +13 -2
  81. package/lib/IconButton/index.js +11 -14
  82. package/lib/ImageEditor/images-previewer/image-preview/index.js +1 -1
  83. package/lib/ImageEditor/index.js +15 -14
  84. package/lib/ImageEditor/pc-editor/addition-previewer/index.js +2 -2
  85. package/lib/ImageEditor/pc-editor/addition-previewer/local-image-addition/index.js +5 -5
  86. package/lib/ImageEditor/pc-editor/images-previewer/index.js +1 -1
  87. package/lib/ImageFormatter/index.js +1 -1
  88. package/lib/ImagePreviewerLightbox/index.css +49 -6
  89. package/lib/ImagePreviewerLightbox/index.js +46 -25
  90. package/lib/ImageThumbnail/index.js +2 -2
  91. package/lib/InputItem/custom-input.js +9 -9
  92. package/lib/InputItem/custom-keyboard.js +34 -37
  93. package/lib/InputItem/index.js +52 -49
  94. package/lib/InputItem/input.js +9 -13
  95. package/lib/LinkEditor/pc-popover/index.js +3 -2
  96. package/lib/List/index.js +17 -21
  97. package/lib/List/list-item.js +50 -52
  98. package/lib/MBEditorHeader/index.js +1 -1
  99. package/lib/MobileFullScreenPage/body/index.js +1 -1
  100. package/lib/MobileFullScreenPage/header/index.js +4 -4
  101. package/lib/MobileFullScreenPage/index.js +1 -1
  102. package/lib/MobileModal/index.js +7 -10
  103. package/lib/Modal/alert.js +2 -2
  104. package/lib/Modal/modal.js +28 -31
  105. package/lib/Modal/prompt.js +10 -10
  106. package/lib/MultipleSelectEditor/index.js +6 -8
  107. package/lib/MultipleSelectFormatter/index.js +1 -1
  108. package/lib/PhoneNumberLink/index.js +1 -1
  109. package/lib/Picker/AbstractPicker.js +26 -28
  110. package/lib/Popover/index.js +9 -12
  111. package/lib/Popover/item.js +22 -26
  112. package/lib/Progress/index.js +10 -8
  113. package/lib/Radio/Radio.js +13 -15
  114. package/lib/Radio/RadioItem.js +18 -18
  115. package/lib/RateFormatter/index.js +2 -2
  116. package/lib/RoleStatusEditor/index.js +1 -1
  117. package/lib/RowExpand/index.js +7 -6
  118. package/lib/RowExpandDialog/body/index.js +14 -14
  119. package/lib/RowExpandDialog/column-content/index.js +1 -1
  120. package/lib/RowExpandDialog/header/index.js +4 -3
  121. package/lib/RowExpandDialog/index.js +43 -32
  122. package/lib/RowExpandEditor/add-btn/index.js +7 -6
  123. package/lib/RowExpandEditor/checkbox-editor/index.js +7 -6
  124. package/lib/RowExpandEditor/collaborator-editor/index.js +7 -6
  125. package/lib/RowExpandEditor/date-editor/index.js +7 -6
  126. package/lib/RowExpandEditor/department-editor/index.js +7 -6
  127. package/lib/RowExpandEditor/digital-sign-editor/index.js +7 -6
  128. package/lib/RowExpandEditor/digital-sign-editor/mb-editor/index.js +4 -4
  129. package/lib/RowExpandEditor/digital-sign-editor/pc-editor/index.js +4 -4
  130. package/lib/RowExpandEditor/duration-editor/index.js +7 -6
  131. package/lib/RowExpandEditor/email-editor/index.js +7 -6
  132. package/lib/RowExpandEditor/email-editor/mb-editor/index.js +1 -1
  133. package/lib/RowExpandEditor/email-editor/pc-editor/index.js +1 -1
  134. package/lib/RowExpandEditor/file-editor/index.js +7 -6
  135. package/lib/RowExpandEditor/geolocation-editor/index.js +7 -6
  136. package/lib/RowExpandEditor/image-editor/index.js +7 -6
  137. package/lib/RowExpandEditor/image-editor/mb-editor/index.js +1 -1
  138. package/lib/RowExpandEditor/image-editor/pc-editor/index.js +1 -1
  139. package/lib/RowExpandEditor/index.js +11 -10
  140. package/lib/RowExpandEditor/long-text-editor/index.js +7 -6
  141. package/lib/RowExpandEditor/multiple-select-editor/index.js +7 -6
  142. package/lib/RowExpandEditor/multiple-select-editor/mb-editor/index.js +1 -1
  143. package/lib/RowExpandEditor/multiple-select-editor/pc-editor/index.js +5 -5
  144. package/lib/RowExpandEditor/number-editor/index.js +7 -6
  145. package/lib/RowExpandEditor/rate-editor/index.js +7 -6
  146. package/lib/RowExpandEditor/rate-editor/mb-editor.js +1 -1
  147. package/lib/RowExpandEditor/rate-editor/pc-editor.js +5 -5
  148. package/lib/RowExpandEditor/single-select-editor/index.js +7 -6
  149. package/lib/RowExpandEditor/single-select-editor/mb-editor/index.js +4 -4
  150. package/lib/RowExpandEditor/single-select-editor/pc-editor/index.js +3 -3
  151. package/lib/RowExpandEditor/text-editor/index.js +7 -6
  152. package/lib/RowExpandEditor/url-editor/index.js +7 -6
  153. package/lib/RowExpandEditor/url-editor/mb-editor/index.js +2 -2
  154. package/lib/RowExpandEditor/url-editor/pc-editor/index.js +2 -2
  155. package/lib/RowExpandFormatter/department-formatter/index.js +6 -3
  156. package/lib/RowExpandFormatter/email-formatter/index.js +1 -1
  157. package/lib/RowExpandFormatter/file-formatter/row-expand-file-item-formatter.js +2 -2
  158. package/lib/RowExpandFormatter/formula-formatter/index.js +17 -11
  159. package/lib/RowExpandFormatter/image-formatter/row-expand-image-item-formatter.js +2 -2
  160. package/lib/RowExpandFormatter/index.js +11 -7
  161. package/lib/RowExpandFormatter/link-formatter/collaborator-item-formatter.js +1 -1
  162. package/lib/RowExpandFormatter/link-formatter/index.js +6 -6
  163. package/lib/RowExpandFormatter/rate-formatter/index.js +2 -2
  164. package/lib/RowExpandFormatter/url-formatter/index.js +2 -2
  165. package/lib/RowExpandView/body/index.js +13 -15
  166. package/lib/RowExpandView/index.js +39 -28
  167. package/lib/SelectOptionGroup/index.js +1 -1
  168. package/lib/SelectedDepartments/index.js +3 -3
  169. package/lib/SimpleLongTextFormatter/index.js +2 -2
  170. package/lib/SingleSelectEditor/index.js +6 -8
  171. package/lib/TabBar/Tab.js +10 -10
  172. package/lib/TabBar/index.js +7 -6
  173. package/lib/Tabs/index.js +10 -9
  174. package/lib/TextareaItem/index.js +43 -45
  175. package/lib/Toast/index.js +5 -5
  176. package/lib/formatterConfig/index.js +3 -3
  177. package/lib/locales/de.json +5 -0
  178. package/lib/locales/en.json +5 -0
  179. package/lib/locales/es.json +5 -0
  180. package/lib/locales/fr.json +5 -0
  181. package/lib/locales/pt.json +5 -0
  182. package/lib/locales/ru.json +5 -0
  183. package/lib/locales/zh-CN.json +5 -0
  184. package/lib/select-editor/index.js +15 -14
  185. package/lib/select-editor/pc-editor/index.js +5 -5
  186. package/lib/toaster/alert.js +1 -1
  187. package/lib/toaster/toast.js +1 -1
  188. package/lib/toaster/toastManager.js +12 -14
  189. package/lib/toaster/toaster.js +12 -9
  190. package/lib/utils/class.js +3 -3
  191. package/lib/utils/departments.js +3 -4
  192. package/lib/utils/getLocale.js +11 -5
  193. package/lib/utils/object-utils.js +5 -4
  194. package/lib/utils/url.js +4 -4
  195. package/package.json +14 -15
@@ -1,12 +1,10 @@
1
1
  "use strict";
2
2
 
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
3
  Object.defineProperty(exports, "__esModule", {
5
4
  value: true
6
5
  });
7
6
  exports.getComponentLocale = getComponentLocale;
8
7
  exports.getLocaleCode = getLocaleCode;
9
- var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectSpread2"));
10
8
  function getComponentLocale(props, context, componentName, getDefaultLocale) {
11
9
  let locale = {};
12
10
  if (context && context.antLocale && context.antLocale[componentName]) {
@@ -17,11 +15,19 @@ function getComponentLocale(props, context, componentName, getDefaultLocale) {
17
15
  // https://github.com/ant-design/ant-design/issues/6334
18
16
  locale = defaultLocale.default || defaultLocale;
19
17
  }
20
- let result = (0, _objectSpread2.default)({}, locale);
18
+ let result = {
19
+ ...locale
20
+ };
21
21
  if (props.locale) {
22
- result = (0, _objectSpread2.default)((0, _objectSpread2.default)({}, result), props.locale);
22
+ result = {
23
+ ...result,
24
+ ...props.locale
25
+ };
23
26
  if (props.locale.lang) {
24
- result.lang = (0, _objectSpread2.default)((0, _objectSpread2.default)({}, locale.lang), props.locale.lang);
27
+ result.lang = {
28
+ ...locale.lang,
29
+ ...props.locale.lang
30
+ };
25
31
  }
26
32
  }
27
33
  return result;
@@ -1,11 +1,9 @@
1
1
  "use strict";
2
2
 
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
3
  Object.defineProperty(exports, "__esModule", {
5
4
  value: true
6
5
  });
7
6
  exports.shallowCloneObject = exports.hasOwnProperty = exports.default = void 0;
8
- var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectSpread2"));
9
7
  class ObjectUtils {
10
8
  static getDataType(data) {
11
9
  let type = typeof data;
@@ -19,13 +17,16 @@ class ObjectUtils {
19
17
  }
20
18
  static isObjectChanged(source, comparison) {
21
19
  if (!this.iterable(source)) {
22
- throw new Error("source should be a Object or Array , but got ".concat(this.getDataType(source)));
20
+ throw new Error(`source should be a Object or Array , but got ${this.getDataType(source)}`);
23
21
  }
24
22
  if (this.getDataType(source) !== this.getDataType(comparison)) {
25
23
  return true;
26
24
  }
27
25
  const sourceKeys = Object.keys(source);
28
- const comparisonKeys = Object.keys((0, _objectSpread2.default)((0, _objectSpread2.default)({}, source), comparison));
26
+ const comparisonKeys = Object.keys({
27
+ ...source,
28
+ ...comparison
29
+ });
29
30
  if (sourceKeys.length !== comparisonKeys.length) {
30
31
  return true;
31
32
  }
package/lib/utils/url.js CHANGED
@@ -80,9 +80,9 @@ const generateCurrentBaseImageThumbnailUrl = _ref => {
80
80
  } = _ref;
81
81
  const validServer = server || ((_window2 = window) === null || _window2 === void 0 ? void 0 : _window2.dtable) && window.dtable.server || '';
82
82
  if (!partUrl || typeof partUrl !== 'string') return '';
83
- let url = "".concat(validServer, "/thumbnail/workspace/").concat(workspaceID, "/asset/").concat(dtableUuid).concat(partUrl);
84
- if (url.indexOf('?') > -1) return "".concat(url, "&size=").concat(size);
85
- return "".concat(url, "?size=").concat(size);
83
+ let url = `${validServer}/thumbnail/workspace/${workspaceID}/asset/${dtableUuid}${partUrl}`;
84
+ if (url.indexOf('?') > -1) return `${url}&size=${size}`;
85
+ return `${url}?size=${size}`;
86
86
  };
87
87
  exports.generateCurrentBaseImageThumbnailUrl = generateCurrentBaseImageThumbnailUrl;
88
88
  const generateCurrentBaseImageUrl = _ref2 => {
@@ -96,7 +96,7 @@ const generateCurrentBaseImageUrl = _ref2 => {
96
96
  if (!partUrl || typeof partUrl !== 'string') return '';
97
97
  if (partUrl.startsWith('http')) return partUrl;
98
98
  const validServer = server || ((_window3 = window) === null || _window3 === void 0 ? void 0 : _window3.dtable) && window.dtable.server || '';
99
- return "".concat(validServer, "/workspace/").concat(workspaceID, "/asset/").concat(dtableUuid).concat(partUrl);
99
+ return `${validServer}/workspace/${workspaceID}/asset/${dtableUuid}${partUrl}`;
100
100
  };
101
101
  exports.generateCurrentBaseImageUrl = generateCurrentBaseImageUrl;
102
102
  const getImageThumbnailUrl = function (url) {
package/package.json CHANGED
@@ -1,11 +1,11 @@
1
1
  {
2
2
  "name": "dtable-ui-component",
3
- "version": "6.0.109",
3
+ "version": "6.0.110-aik.2",
4
4
  "main": "./lib/index.js",
5
5
  "dependencies": {
6
- "@seafile/react-image-lightbox": "4.0.2",
6
+ "@seafile/react-image-lightbox": "^5.0.4",
7
7
  "@seafile/seafile-calendar": "^1.0.8",
8
- "@seafile/seafile-editor": "~2.0.14",
8
+ "@seafile/seafile-editor": "^3.0.26",
9
9
  "classnames": "~2.5.*",
10
10
  "dayjs": "1.10.7",
11
11
  "dtable-utils": "~5.0.27",
@@ -28,7 +28,7 @@
28
28
  "rmc-tooltip": "1.0.1"
29
29
  },
30
30
  "scripts": {
31
- "lint": "./node_modules/.bin/eslint ./src/ --fix",
31
+ "lint": "eslint ./src/ --fix",
32
32
  "clean:esm": "rm -rf es && mkdir es",
33
33
  "clean:lib": "rm -rf lib && mkdir lib",
34
34
  "clean:dist": "rm -rf dist && mkdir dist",
@@ -82,7 +82,7 @@
82
82
  "@types/jest": "^29.5.10",
83
83
  "autoprefixer": "10.4.5",
84
84
  "babel-eslint": "10.0.1",
85
- "babel-jest": "^27.4.2",
85
+ "babel-jest": "^30.3.0",
86
86
  "babel-loader": "^8.2.3",
87
87
  "babel-plugin-import": "^1.13.6",
88
88
  "babel-plugin-named-asset-import": "^0.3.6",
@@ -92,7 +92,7 @@
92
92
  "case-sensitive-paths-webpack-plugin": "^2.4.0",
93
93
  "circular-dependency-plugin": "^5.2.2",
94
94
  "css-loader": "^6.5.1",
95
- "css-minimizer-webpack-plugin": "^3.2.0",
95
+ "css-minimizer-webpack-plugin": "^8.0.0",
96
96
  "dotenv": "^10.0.0",
97
97
  "dotenv-expand": "^5.1.0",
98
98
  "eslint": "^8.3.0",
@@ -103,19 +103,21 @@
103
103
  "fs-extra": "^10.0.0",
104
104
  "html-webpack-plugin": "^5.5.0",
105
105
  "identity-obj-proxy": "3.0.0",
106
- "jest": "^27.4.3",
107
- "jest-resolve": "^27.4.2",
108
- "jest-watch-typeahead": "^1.0.0",
106
+ "jest": "^30.3.0",
107
+ "jest-cli": "^30.3.0",
108
+ "jest-environment-jsdom": "^30.3.0",
109
+ "jest-resolve": "^30.3.0",
110
+ "jest-watch-typeahead": "^3.0.1",
109
111
  "less": "^4.2.0",
110
112
  "less-loader": "^11.1.3",
111
113
  "mini-css-extract-plugin": "^2.4.5",
112
- "node-polyfill-webpack-plugin": "2.0.1",
113
114
  "path-browserify": "^1.0.1",
114
115
  "postcss": "^8.5.3",
115
116
  "postcss-flexbugs-fixes": "^5.0.2",
116
117
  "postcss-loader": "^6.2.1",
117
118
  "postcss-normalize": "^10.0.1",
118
119
  "postcss-preset-env": "^7.0.1",
120
+ "process": "^0.11.10",
119
121
  "prompts": "^2.4.2",
120
122
  "prop-types": "15.8.1",
121
123
  "react": "18.3.1",
@@ -133,11 +135,8 @@
133
135
  "style-loader": "^3.3.1",
134
136
  "terser-webpack-plugin": "^5.2.5",
135
137
  "url-loader": "^4.1.1",
136
- "web-vitals": "2.1.4",
137
- "webpack": "^5.105.0",
138
- "webpack-dev-server": "^5.2.2",
139
- "webpack-manifest-plugin": "^4.0.2",
140
- "workbox-webpack-plugin": "^6.4.1",
138
+ "webpack": "^5.105.4",
139
+ "webpack-dev-server": "^5.2.3",
141
140
  "worker-loader": "3.0.8"
142
141
  }
143
142
  }