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.
- package/lib/ActionSheet/index.js +42 -35
- package/lib/ActivityIndicator/index.js +9 -9
- package/lib/AsyncUserSelect/index.css +54 -12
- package/lib/AsyncUserSelect/index.js +27 -16
- package/lib/Badge/index.js +27 -31
- package/lib/CheckboxEditor/index.js +15 -14
- package/lib/CollaboratorEditor/index.js +16 -15
- package/lib/CollaboratorEditor/pc-editor/index.js +1 -1
- package/lib/CollapsibleSettingLayout/index.js +1 -1
- package/lib/Comment/body/comment.js +1 -1
- package/lib/Comment/body/index.js +7 -9
- package/lib/Comment/footer/index.js +1 -1
- package/lib/Comment/footer/input/index.js +5 -5
- package/lib/Comment/footer/input/participant/index.js +1 -1
- package/lib/Comment/footer/participants/participant-select/index.js +2 -2
- package/lib/Comment/utils/utilities.js +1 -1
- package/lib/DTableColorPicker/ColorPickerPortal/index.js +8 -6
- package/lib/DTableColorPicker/index.js +13 -12
- package/lib/DTableColorPicker/utils.js +1 -1
- package/lib/DTableCommonAddTool/index.js +2 -2
- package/lib/DTableFiltersPopover/index.js +1 -1
- package/lib/DTableFiltersPopover/utils/index.js +1 -1
- package/lib/DTableFiltersPopover/widgets/filter-group.js +2 -2
- package/lib/DTableFiltersPopover/widgets/filter-item.js +1 -1
- package/lib/DTableFiltersPopover/widgets/filter-list/index.js +1 -1
- package/lib/DTableFiltersPopover/widgets/rate-item.js +5 -5
- package/lib/DTableGroupSelect/index.css +42 -5
- package/lib/DTableGroupSelect/select-option-group.css +3 -3
- package/lib/DTableGroupSelect/select-option-group.js +23 -5
- package/lib/DTableIcon/index.js +4 -4
- package/lib/DTableIcon/svg-icon.js +4 -4
- package/lib/DTableModalHeader/index.js +6 -8
- package/lib/DTableRadioGroup/index.js +3 -3
- package/lib/DTableSelect/dtable-select-label.js +1 -1
- package/lib/DTableSelect/utils.js +55 -36
- package/lib/DateEditor/index.js +13 -10
- package/lib/DateEditor/pc-editor.js +1 -1
- package/lib/DatePicker/utils.js +4 -4
- package/lib/DepartmentMultipleSelectEditor/index.js +3 -3
- package/lib/DepartmentSelectFilter/index.js +5 -2
- package/lib/DepartmentSingleSelectEditor/index.js +15 -14
- package/lib/DepartmentSingleSelectEditor/mb-editor/index.js +2 -2
- package/lib/DepartmentSingleSelectEditor/pc-editor/department-single-select.js +6 -6
- package/lib/DigitalSignEditor/index.js +15 -14
- package/lib/DigitalSignEditor/mb-editor/index.js +4 -4
- package/lib/DigitalSignEditor/pc-editor/index.js +7 -6
- package/lib/DigitalSignEditor/service.js +1 -1
- package/lib/DigitalSignEditor/signature-board/index.js +2 -2
- package/lib/DigitalSignFormatter/utils.js +1 -1
- package/lib/Drawer/index.js +3 -2
- package/lib/FieldDisplaySetting/field-item.js +1 -1
- package/lib/FieldDisplaySetting/index.js +11 -9
- package/lib/FileEditor/files-previewer/index.js +15 -14
- package/lib/FileEditor/files-previewer/mb-previewer/file-previewer/index.js +2 -2
- package/lib/FileEditor/files-previewer/pc-previewer/file-previewer/index.js +3 -3
- package/lib/FileEditor/index.js +15 -14
- package/lib/FileEditor/pc-editor/addition-previewer/index.js +1 -1
- package/lib/FileEditor/pc-editor/addition-previewer/local-file-addition/index.js +6 -6
- package/lib/FileEditor/pc-editor/index.js +3 -3
- package/lib/FileFormatter/index.js +1 -1
- package/lib/FileItemFormatter/index.js +1 -1
- package/lib/FileUploader/index.js +1 -1
- package/lib/FormulaFormatter/index.js +15 -9
- package/lib/GeolocationEditor/index.js +23 -19
- package/lib/GeolocationEditor/map-editor-utils.js +10 -6
- package/lib/GeolocationEditor/mb-editor/index.js +27 -23
- package/lib/GeolocationEditor/mb-editor/map-editor/index.js +9 -6
- package/lib/GeolocationEditor/pc-editor/country-editor.js +2 -2
- package/lib/GeolocationEditor/pc-editor/index.js +21 -15
- package/lib/GeolocationEditor/pc-editor/location-editor.js +2 -2
- package/lib/GeolocationEditor/pc-editor/map-editor/index.js +13 -9
- package/lib/GeolocationEditor/pc-editor/map-editor/large-editor/index.js +9 -6
- package/lib/GeolocationEditor/pc-editor/map-selection-editor/index.js +24 -7
- package/lib/GeolocationEditor/pc-editor/map-selection-editor/large-editor/index.js +20 -3
- package/lib/GeolocationEditor/pc-editor/province-city-editor.js +1 -1
- package/lib/GeolocationEditor/pc-editor/province-editor.js +2 -2
- package/lib/GeolocationEditor/pc-editor/selector-list.js +1 -1
- package/lib/HtmlLongTextFormatter/index.js +1 -1
- package/lib/Icon/index.js +13 -17
- package/lib/Icon/load-sprite.js +13 -2
- package/lib/IconButton/index.js +11 -14
- package/lib/ImageEditor/images-previewer/image-preview/index.js +1 -1
- package/lib/ImageEditor/index.js +15 -14
- package/lib/ImageEditor/pc-editor/addition-previewer/index.js +2 -2
- package/lib/ImageEditor/pc-editor/addition-previewer/local-image-addition/index.js +5 -5
- package/lib/ImageEditor/pc-editor/images-previewer/index.js +1 -1
- package/lib/ImageFormatter/index.js +1 -1
- package/lib/ImagePreviewerLightbox/index.css +49 -6
- package/lib/ImagePreviewerLightbox/index.js +46 -25
- package/lib/ImageThumbnail/index.js +2 -2
- package/lib/InputItem/custom-input.js +9 -9
- package/lib/InputItem/custom-keyboard.js +34 -37
- package/lib/InputItem/index.js +52 -49
- package/lib/InputItem/input.js +9 -13
- package/lib/LinkEditor/pc-popover/index.js +3 -2
- package/lib/List/index.js +17 -21
- package/lib/List/list-item.js +50 -52
- package/lib/MBEditorHeader/index.js +1 -1
- package/lib/MobileFullScreenPage/body/index.js +1 -1
- package/lib/MobileFullScreenPage/header/index.js +4 -4
- package/lib/MobileFullScreenPage/index.js +1 -1
- package/lib/MobileModal/index.js +7 -10
- package/lib/Modal/alert.js +2 -2
- package/lib/Modal/modal.js +28 -31
- package/lib/Modal/prompt.js +10 -10
- package/lib/MultipleSelectEditor/index.js +6 -8
- package/lib/MultipleSelectFormatter/index.js +1 -1
- package/lib/PhoneNumberLink/index.js +1 -1
- package/lib/Picker/AbstractPicker.js +26 -28
- package/lib/Popover/index.js +9 -12
- package/lib/Popover/item.js +22 -26
- package/lib/Progress/index.js +10 -8
- package/lib/Radio/Radio.js +13 -15
- package/lib/Radio/RadioItem.js +18 -18
- package/lib/RateFormatter/index.js +2 -2
- package/lib/RoleStatusEditor/index.js +1 -1
- package/lib/RowExpand/index.js +7 -6
- package/lib/RowExpandDialog/body/index.js +14 -14
- package/lib/RowExpandDialog/column-content/index.js +1 -1
- package/lib/RowExpandDialog/header/index.js +4 -3
- package/lib/RowExpandDialog/index.js +43 -32
- package/lib/RowExpandEditor/add-btn/index.js +7 -6
- package/lib/RowExpandEditor/checkbox-editor/index.js +7 -6
- package/lib/RowExpandEditor/collaborator-editor/index.js +7 -6
- package/lib/RowExpandEditor/date-editor/index.js +7 -6
- package/lib/RowExpandEditor/department-editor/index.js +7 -6
- package/lib/RowExpandEditor/digital-sign-editor/index.js +7 -6
- package/lib/RowExpandEditor/digital-sign-editor/mb-editor/index.js +4 -4
- package/lib/RowExpandEditor/digital-sign-editor/pc-editor/index.js +4 -4
- package/lib/RowExpandEditor/duration-editor/index.js +7 -6
- package/lib/RowExpandEditor/email-editor/index.js +7 -6
- package/lib/RowExpandEditor/email-editor/mb-editor/index.js +1 -1
- package/lib/RowExpandEditor/email-editor/pc-editor/index.js +1 -1
- package/lib/RowExpandEditor/file-editor/index.js +7 -6
- package/lib/RowExpandEditor/geolocation-editor/index.js +7 -6
- package/lib/RowExpandEditor/image-editor/index.js +7 -6
- package/lib/RowExpandEditor/image-editor/mb-editor/index.js +1 -1
- package/lib/RowExpandEditor/image-editor/pc-editor/index.js +1 -1
- package/lib/RowExpandEditor/index.js +11 -10
- package/lib/RowExpandEditor/long-text-editor/index.js +7 -6
- package/lib/RowExpandEditor/multiple-select-editor/index.js +7 -6
- package/lib/RowExpandEditor/multiple-select-editor/mb-editor/index.js +1 -1
- package/lib/RowExpandEditor/multiple-select-editor/pc-editor/index.js +5 -5
- package/lib/RowExpandEditor/number-editor/index.js +7 -6
- package/lib/RowExpandEditor/rate-editor/index.js +7 -6
- package/lib/RowExpandEditor/rate-editor/mb-editor.js +1 -1
- package/lib/RowExpandEditor/rate-editor/pc-editor.js +5 -5
- package/lib/RowExpandEditor/single-select-editor/index.js +7 -6
- package/lib/RowExpandEditor/single-select-editor/mb-editor/index.js +4 -4
- package/lib/RowExpandEditor/single-select-editor/pc-editor/index.js +3 -3
- package/lib/RowExpandEditor/text-editor/index.js +7 -6
- package/lib/RowExpandEditor/url-editor/index.js +7 -6
- package/lib/RowExpandEditor/url-editor/mb-editor/index.js +2 -2
- package/lib/RowExpandEditor/url-editor/pc-editor/index.js +2 -2
- package/lib/RowExpandFormatter/department-formatter/index.js +6 -3
- package/lib/RowExpandFormatter/email-formatter/index.js +1 -1
- package/lib/RowExpandFormatter/file-formatter/row-expand-file-item-formatter.js +2 -2
- package/lib/RowExpandFormatter/formula-formatter/index.js +17 -11
- package/lib/RowExpandFormatter/image-formatter/row-expand-image-item-formatter.js +2 -2
- package/lib/RowExpandFormatter/index.js +11 -7
- package/lib/RowExpandFormatter/link-formatter/collaborator-item-formatter.js +1 -1
- package/lib/RowExpandFormatter/link-formatter/index.js +6 -6
- package/lib/RowExpandFormatter/rate-formatter/index.js +2 -2
- package/lib/RowExpandFormatter/url-formatter/index.js +2 -2
- package/lib/RowExpandView/body/index.js +13 -15
- package/lib/RowExpandView/index.js +39 -28
- package/lib/SelectOptionGroup/index.js +1 -1
- package/lib/SelectedDepartments/index.js +3 -3
- package/lib/SimpleLongTextFormatter/index.js +2 -2
- package/lib/SingleSelectEditor/index.js +6 -8
- package/lib/TabBar/Tab.js +10 -10
- package/lib/TabBar/index.js +7 -6
- package/lib/Tabs/index.js +10 -9
- package/lib/TextareaItem/index.js +43 -45
- package/lib/Toast/index.js +5 -5
- package/lib/formatterConfig/index.js +3 -3
- package/lib/locales/de.json +5 -0
- package/lib/locales/en.json +5 -0
- package/lib/locales/es.json +5 -0
- package/lib/locales/fr.json +5 -0
- package/lib/locales/pt.json +5 -0
- package/lib/locales/ru.json +5 -0
- package/lib/locales/zh-CN.json +5 -0
- package/lib/select-editor/index.js +15 -14
- package/lib/select-editor/pc-editor/index.js +5 -5
- package/lib/toaster/alert.js +1 -1
- package/lib/toaster/toast.js +1 -1
- package/lib/toaster/toastManager.js +12 -14
- package/lib/toaster/toaster.js +12 -9
- package/lib/utils/class.js +3 -3
- package/lib/utils/departments.js +3 -4
- package/lib/utils/getLocale.js +11 -5
- package/lib/utils/object-utils.js +5 -4
- package/lib/utils/url.js +4 -4
- package/package.json +14 -15
package/lib/utils/getLocale.js
CHANGED
|
@@ -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 =
|
|
18
|
+
let result = {
|
|
19
|
+
...locale
|
|
20
|
+
};
|
|
21
21
|
if (props.locale) {
|
|
22
|
-
result =
|
|
22
|
+
result = {
|
|
23
|
+
...result,
|
|
24
|
+
...props.locale
|
|
25
|
+
};
|
|
23
26
|
if (props.locale.lang) {
|
|
24
|
-
result.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(
|
|
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(
|
|
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 =
|
|
84
|
-
if (url.indexOf('?') > -1) return
|
|
85
|
-
return
|
|
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
|
|
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.
|
|
3
|
+
"version": "6.0.110-aik.2",
|
|
4
4
|
"main": "./lib/index.js",
|
|
5
5
|
"dependencies": {
|
|
6
|
-
"@seafile/react-image-lightbox": "
|
|
6
|
+
"@seafile/react-image-lightbox": "^5.0.4",
|
|
7
7
|
"@seafile/seafile-calendar": "^1.0.8",
|
|
8
|
-
"@seafile/seafile-editor": "
|
|
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": "
|
|
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": "^
|
|
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": "^
|
|
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": "^
|
|
107
|
-
"jest-
|
|
108
|
-
"jest-
|
|
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
|
-
"
|
|
137
|
-
"webpack": "^5.
|
|
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
|
}
|