dtable-ui-component 6.0.49 → 6.0.50
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 +94 -68
- package/lib/ActivityIndicator/index.js +36 -28
- package/lib/AsyncUserSelect/index.css +122 -0
- package/lib/AsyncUserSelect/index.js +260 -0
- package/lib/AsyncUserSelect/user-item.js +55 -0
- package/lib/AutoNumberFormatter/index.js +5 -3
- package/lib/Badge/index.js +12 -8
- package/lib/ButtonFormatter/index.js +15 -10
- package/lib/CTimeFormatter/index.js +5 -3
- package/lib/CheckboxEditor/index.js +22 -13
- package/lib/CheckboxEditor/mb-editor.js +7 -5
- package/lib/CheckboxEditor/pc-editor.js +7 -5
- package/lib/CheckboxFormatter/index.js +7 -5
- package/lib/CollaboratorEditor/index.js +24 -15
- package/lib/CollaboratorEditor/mb-editor/index.js +19 -13
- package/lib/CollaboratorEditor/pc-editor/index.js +50 -42
- package/lib/CollaboratorFormatter/index.js +8 -7
- package/lib/CollaboratorItem/index.js +21 -16
- package/lib/CollapsibleSettingLayout/index.js +17 -12
- package/lib/Comment/body/comment.js +78 -62
- package/lib/Comment/body/index.js +14 -11
- package/lib/Comment/footer/btns/index.js +68 -53
- package/lib/Comment/footer/index.js +29 -27
- package/lib/Comment/footer/input/index.js +44 -39
- package/lib/Comment/footer/input/participant/index.js +18 -13
- package/lib/Comment/footer/participants/index.js +31 -28
- package/lib/Comment/footer/participants/participant/index.js +18 -15
- package/lib/Comment/footer/participants/participant-select/index.js +66 -55
- package/lib/Comment/index.js +33 -28
- package/lib/CreatorFormatter/index.js +8 -7
- package/lib/DTableColorPicker/ColorPickerPortal/index.js +5 -3
- package/lib/DTableColorPicker/index.js +135 -99
- package/lib/DTableCommonAddTool/index.js +10 -7
- package/lib/DTableCustomFooter/index.js +5 -3
- package/lib/DTableCustomizeCollaboratorSelect/index.js +38 -32
- package/lib/DTableCustomizeSelect/index.js +51 -44
- package/lib/DTableEmptyTip/index.js +20 -16
- package/lib/DTableFiltersPopover/index.js +71 -61
- package/lib/DTableFiltersPopover/utils/filter-item-utils.js +74 -57
- package/lib/DTableFiltersPopover/widgets/collaborator-filter/index.js +64 -49
- package/lib/DTableFiltersPopover/widgets/department-select-filter/department-multiple-select-filter.js +49 -41
- package/lib/DTableFiltersPopover/widgets/department-select-filter/department-single-select-filter.js +57 -47
- package/lib/DTableFiltersPopover/widgets/filter-calendar.js +35 -31
- package/lib/DTableFiltersPopover/widgets/filter-group.js +38 -32
- package/lib/DTableFiltersPopover/widgets/filter-item.js +125 -106
- package/lib/DTableFiltersPopover/widgets/filter-list/index.js +18 -17
- package/lib/DTableFiltersPopover/widgets/rate-item.js +12 -9
- package/lib/DTableGroupSelect/index.js +52 -44
- package/lib/DTableGroupSelect/option.js +5 -3
- package/lib/DTableGroupSelect/select-option-group.js +31 -25
- package/lib/DTableModalHeader/index.js +13 -9
- package/lib/DTablePopover/index.js +9 -6
- package/lib/DTableRadio/index.js +20 -17
- package/lib/DTableRadioGroup/index.js +21 -18
- package/lib/DTableSearchInput/index.js +22 -18
- package/lib/DTableSelect/dtable-select-label.js +12 -7
- package/lib/DTableSelect/index.js +2 -1
- package/lib/DTableSelect/utils.js +34 -20
- package/lib/DTableSwitch/index.js +25 -17
- package/lib/DateEditor/index.js +25 -16
- package/lib/DateEditor/mb-editor/index.js +90 -68
- package/lib/DateEditor/pc-editor.js +38 -34
- package/lib/DateFormatter/index.js +5 -3
- package/lib/DeleteTip/index.js +29 -20
- package/lib/DepartmentMultipleSelectEditor/index.js +57 -49
- package/lib/DepartmentSelectFilter/index.js +8 -1
- package/lib/DepartmentSingleSelectEditor/index.js +22 -13
- package/lib/DepartmentSingleSelectEditor/mb-editor/index.js +75 -55
- package/lib/DepartmentSingleSelectEditor/pc-editor/department-single-select.js +78 -61
- package/lib/DepartmentSingleSelectEditor/pc-editor/index.js +14 -11
- package/lib/DepartmentSingleSelectFormatter/index.js +13 -9
- package/lib/DigitalSignEditor/index.js +22 -13
- package/lib/DigitalSignEditor/mb-editor/index.js +39 -24
- package/lib/DigitalSignEditor/pc-editor/index.js +44 -30
- package/lib/DigitalSignEditor/signature-board/index.js +19 -15
- package/lib/DigitalSignFormatter/index.js +23 -19
- package/lib/Drawer/index.js +4 -1
- package/lib/DurationEditor/index.js +2 -1
- package/lib/DurationFormatter/index.js +5 -3
- package/lib/EditEditorButton/index.js +5 -3
- package/lib/EmailEditor/index.js +2 -1
- package/lib/EmailFormatter/index.js +5 -3
- package/lib/FieldDisplaySetting/field-item.js +25 -19
- package/lib/FieldDisplaySetting/index.js +47 -38
- package/lib/FileEditor/files-previewer/index.js +22 -13
- package/lib/FileEditor/files-previewer/mb-previewer/file-previewer/index.js +43 -28
- package/lib/FileEditor/files-previewer/mb-previewer/index.js +24 -21
- package/lib/FileEditor/files-previewer/pc-previewer/file-previewer/dropdown-menu.js +30 -24
- package/lib/FileEditor/files-previewer/pc-previewer/file-previewer/file-name-editor/index.js +13 -11
- package/lib/FileEditor/files-previewer/pc-previewer/file-previewer/index.js +81 -63
- package/lib/FileEditor/files-previewer/pc-previewer/index.js +81 -65
- package/lib/FileEditor/index.js +22 -13
- package/lib/FileEditor/mb-editor/index.js +43 -31
- package/lib/FileEditor/pc-editor/addition-previewer/index.js +27 -20
- package/lib/FileEditor/pc-editor/addition-previewer/local-file-addition/index.js +107 -81
- package/lib/FileEditor/pc-editor/index.js +46 -36
- package/lib/FileFormatter/index.js +40 -36
- package/lib/FileItemFormatter/index.js +2 -1
- package/lib/FileUploader/index.js +22 -20
- package/lib/FormulaFormatter/index.js +21 -14
- package/lib/GeolocationEditor/index.js +28 -19
- package/lib/GeolocationEditor/mb-editor/country-editor.js +42 -27
- package/lib/GeolocationEditor/mb-editor/index.js +22 -14
- package/lib/GeolocationEditor/mb-editor/location-editor.js +54 -34
- package/lib/GeolocationEditor/mb-editor/map-editor/index.js +102 -74
- package/lib/GeolocationEditor/mb-editor/map-selection-editor/index.js +144 -110
- package/lib/GeolocationEditor/mb-editor/province-city-editor.js +42 -27
- package/lib/GeolocationEditor/mb-editor/province-editor.js +42 -27
- package/lib/GeolocationEditor/pc-editor/country-editor.js +37 -30
- package/lib/GeolocationEditor/pc-editor/index.js +26 -17
- package/lib/GeolocationEditor/pc-editor/location-editor.js +121 -95
- package/lib/GeolocationEditor/pc-editor/map-editor/index.js +99 -74
- package/lib/GeolocationEditor/pc-editor/map-editor/large-editor/index.js +99 -76
- package/lib/GeolocationEditor/pc-editor/map-selection-editor/index.js +119 -91
- package/lib/GeolocationEditor/pc-editor/map-selection-editor/large-editor/index.js +102 -82
- package/lib/GeolocationEditor/pc-editor/province-city-editor.js +89 -69
- package/lib/GeolocationEditor/pc-editor/province-editor.js +30 -25
- package/lib/GeolocationEditor/pc-editor/selector-header-item.js +9 -5
- package/lib/GeolocationEditor/pc-editor/selector-list.js +15 -13
- package/lib/GeolocationFormatter/index.js +5 -3
- package/lib/HtmlLongTextFormatter/index.js +2 -1
- package/lib/Icon/index.js +8 -5
- package/lib/IconButton/index.js +9 -6
- package/lib/ImageEditor/images-previewer/image-preview/index.js +52 -44
- package/lib/ImageEditor/images-previewer/index.js +35 -32
- package/lib/ImageEditor/index.js +22 -13
- package/lib/ImageEditor/mb-editor/index.js +43 -31
- package/lib/ImageEditor/pc-editor/addition-previewer/image-link/index.js +19 -15
- package/lib/ImageEditor/pc-editor/addition-previewer/index.js +32 -24
- package/lib/ImageEditor/pc-editor/addition-previewer/local-image-addition/index.js +101 -76
- package/lib/ImageEditor/pc-editor/images-previewer/index.js +33 -30
- package/lib/ImageEditor/pc-editor/index.js +44 -32
- package/lib/ImageFormatter/images-lazy-load.js +12 -10
- package/lib/ImageFormatter/index.js +40 -34
- package/lib/ImagePreviewerLightbox/index.js +12 -8
- package/lib/ImageThumbnail/index.js +46 -38
- package/lib/InputItem/custom-input.js +23 -18
- package/lib/InputItem/custom-keyboard.js +65 -44
- package/lib/InputItem/index.js +66 -56
- package/lib/InputItem/input.js +5 -3
- package/lib/LastModifierFormatter/index.js +8 -7
- package/lib/LinkEditor/index.js +38 -32
- package/lib/LinkEditor/link-editor-option.js +25 -20
- package/lib/LinkEditor/mb-popover/index.js +53 -41
- package/lib/LinkEditor/pc-popover/index.js +41 -33
- package/lib/LinkFormatter/index.js +13 -10
- package/lib/List/index.js +15 -9
- package/lib/List/list-item.js +32 -23
- package/lib/Loading/index.js +2 -1
- package/lib/LongTextFormatter/index.js +3 -2
- package/lib/MBEditorHeader/index.js +19 -14
- package/lib/MTimeFormatter/index.js +5 -3
- package/lib/MobileFullScreenPage/body/index.js +5 -3
- package/lib/MobileFullScreenPage/header/index.js +21 -16
- package/lib/MobileFullScreenPage/index.js +11 -8
- package/lib/MobileModal/index.js +6 -3
- package/lib/MobileOperationSheet/index.js +28 -18
- package/lib/MobileSelector/empty/index.js +5 -3
- package/lib/MobileSelector/index.js +18 -12
- package/lib/MobileSelector/option/index.js +17 -12
- package/lib/MobileSelector/options/index.js +5 -3
- package/lib/MobileSelector/search/index.js +10 -8
- package/lib/MobileUpload/index.js +87 -67
- package/lib/Modal/alert.js +8 -5
- package/lib/Modal/modal.js +19 -15
- package/lib/Modal/operation.js +2 -1
- package/lib/Modal/prompt.js +74 -54
- package/lib/MultipleSelectEditor/index.js +4 -2
- package/lib/MultipleSelectFormatter/index.js +8 -7
- package/lib/NotificationPopover/index.js +43 -32
- package/lib/NumberEditor/index.js +2 -1
- package/lib/NumberFormatter/index.js +5 -3
- package/lib/Picker/AbstractPicker.js +26 -22
- package/lib/Picker/index.js +2 -1
- package/lib/Popover/index.js +8 -5
- package/lib/Popover/item.js +22 -15
- package/lib/Progress/index.js +12 -10
- package/lib/Radio/Radio.js +11 -7
- package/lib/Radio/RadioItem.js +9 -3
- package/lib/RateFormatter/index.js +7 -6
- package/lib/RoleStatusEditor/index.js +36 -31
- package/lib/RowExpand/index.js +16 -9
- package/lib/RowExpandDialog/body/index.js +52 -41
- package/lib/RowExpandDialog/column-content/index.js +34 -25
- package/lib/RowExpandDialog/header/index.js +28 -21
- package/lib/RowExpandDialog/index.js +40 -27
- package/lib/RowExpandEditor/add-btn/index.js +16 -9
- package/lib/RowExpandEditor/add-btn/mb-add-btn/index.js +5 -3
- package/lib/RowExpandEditor/add-btn/pc-add-btn/index.js +8 -5
- package/lib/RowExpandEditor/checkbox-editor/index.js +16 -9
- package/lib/RowExpandEditor/checkbox-editor/mb-editor/index.js +10 -8
- package/lib/RowExpandEditor/checkbox-editor/pc-editor.js +2 -1
- package/lib/RowExpandEditor/collaborator-editor/index.js +16 -9
- package/lib/RowExpandEditor/collaborator-editor/mb-editor/index.js +19 -17
- package/lib/RowExpandEditor/collaborator-editor/pc-editor/index.js +52 -47
- package/lib/RowExpandEditor/date-editor/index.js +16 -9
- package/lib/RowExpandEditor/date-editor/mb-editor.js +20 -15
- package/lib/RowExpandEditor/date-editor/pc-editor.js +24 -21
- package/lib/RowExpandEditor/department-editor/index.js +16 -9
- package/lib/RowExpandEditor/department-editor/mb-editor.js +27 -22
- package/lib/RowExpandEditor/department-editor/pc-editor.js +35 -29
- package/lib/RowExpandEditor/digital-sign-editor/index.js +16 -9
- package/lib/RowExpandEditor/digital-sign-editor/mb-editor/index.js +19 -16
- package/lib/RowExpandEditor/digital-sign-editor/pc-editor/index.js +34 -32
- package/lib/RowExpandEditor/duration-editor/index.js +16 -9
- package/lib/RowExpandEditor/duration-editor/mb-editor.js +15 -12
- package/lib/RowExpandEditor/duration-editor/pc-editor.js +17 -13
- package/lib/RowExpandEditor/email-editor/index.js +16 -9
- package/lib/RowExpandEditor/email-editor/mb-editor/index.js +19 -17
- package/lib/RowExpandEditor/email-editor/pc-editor/index.js +20 -18
- package/lib/RowExpandEditor/file-editor/index.js +16 -9
- package/lib/RowExpandEditor/file-editor/mb-editor/index.js +21 -16
- package/lib/RowExpandEditor/file-editor/pc-editor/index.js +22 -20
- package/lib/RowExpandEditor/geolocation-editor/index.js +16 -9
- package/lib/RowExpandEditor/geolocation-editor/mb-editor/index.js +12 -9
- package/lib/RowExpandEditor/geolocation-editor/pc-editor/index.js +20 -17
- package/lib/RowExpandEditor/image-editor/index.js +16 -9
- package/lib/RowExpandEditor/image-editor/mb-editor/index.js +21 -16
- package/lib/RowExpandEditor/image-editor/pc-editor/index.js +29 -25
- package/lib/RowExpandEditor/index.js +4 -2
- package/lib/RowExpandEditor/long-text-editor/index.js +16 -9
- package/lib/RowExpandEditor/long-text-editor/mb-editor/editor/index.js +27 -16
- package/lib/RowExpandEditor/long-text-editor/mb-editor/index.js +19 -16
- package/lib/RowExpandEditor/long-text-editor/pc-editor/index.js +22 -18
- package/lib/RowExpandEditor/multiple-select-editor/index.js +16 -9
- package/lib/RowExpandEditor/multiple-select-editor/mb-editor/index.js +26 -23
- package/lib/RowExpandEditor/multiple-select-editor/pc-editor/index.js +81 -67
- package/lib/RowExpandEditor/number-editor/index.js +16 -9
- package/lib/RowExpandEditor/number-editor/mb-editor/index.js +10 -7
- package/lib/RowExpandEditor/number-editor/pc-editor.js +6 -4
- package/lib/RowExpandEditor/rate-editor/index.js +16 -9
- package/lib/RowExpandEditor/rate-editor/mb-editor.js +10 -8
- package/lib/RowExpandEditor/rate-editor/pc-editor.js +11 -9
- package/lib/RowExpandEditor/right-angle/index.js +8 -6
- package/lib/RowExpandEditor/single-select-editor/index.js +16 -9
- package/lib/RowExpandEditor/single-select-editor/mb-editor/index.js +30 -23
- package/lib/RowExpandEditor/single-select-editor/pc-editor/index.js +42 -34
- package/lib/RowExpandEditor/text-editor/index.js +16 -9
- package/lib/RowExpandEditor/text-editor/mb-editor/index.js +11 -9
- package/lib/RowExpandEditor/text-editor/pc-editor/index.js +16 -12
- package/lib/RowExpandEditor/url-editor/index.js +16 -9
- package/lib/RowExpandEditor/url-editor/mb-editor/index.js +19 -17
- package/lib/RowExpandEditor/url-editor/pc-editor/index.js +20 -18
- package/lib/RowExpandFormatter/department-formatter/index.js +14 -5
- package/lib/RowExpandFormatter/department-formatter/mb-formatter.js +2 -1
- package/lib/RowExpandFormatter/department-formatter/pc-formatter.js +15 -11
- package/lib/RowExpandFormatter/email-formatter/index.js +11 -8
- package/lib/RowExpandFormatter/file-formatter/index.js +15 -14
- package/lib/RowExpandFormatter/file-formatter/row-expand-file-item-formatter.js +43 -36
- package/lib/RowExpandFormatter/formula-formatter/index.js +37 -29
- package/lib/RowExpandFormatter/image-formatter/index.js +30 -27
- package/lib/RowExpandFormatter/image-formatter/row-expand-image-item-formatter.js +47 -39
- package/lib/RowExpandFormatter/index.js +131 -114
- package/lib/RowExpandFormatter/link-formatter/collaborator-item-formatter.js +2 -1
- package/lib/RowExpandFormatter/link-formatter/index.js +70 -67
- package/lib/RowExpandFormatter/rate-formatter/index.js +7 -6
- package/lib/RowExpandFormatter/url-formatter/index.js +11 -8
- package/lib/RowExpandView/body/index.js +38 -32
- package/lib/RowExpandView/column-content/index.js +10 -5
- package/lib/RowExpandView/index.js +27 -16
- package/lib/SelectItem/index.js +16 -12
- package/lib/SelectOptionGroup/index.js +39 -32
- package/lib/SelectOptionGroup/option.js +5 -3
- package/lib/SelectedDepartments/index.js +54 -44
- package/lib/SimpleLongTextFormatter/index.js +39 -30
- package/lib/SimpleLongTextFormatter/widgets/LongTextPreview.js +11 -8
- package/lib/SimpleLongTextFormatter/widgets/dtable-markdown-viewer.js +3 -2
- package/lib/SingleSelectEditor/index.js +4 -2
- package/lib/SingleSelectFormatter/index.js +6 -4
- package/lib/SvgIcon/index.js +4 -1
- package/lib/TabBar/Tab.js +27 -20
- package/lib/TabBar/index.js +25 -21
- package/lib/Tabs/index.js +8 -5
- package/lib/TextEditor/index.js +21 -18
- package/lib/TextFormatter/index.js +5 -3
- package/lib/TextareaItem/index.js +35 -26
- package/lib/Toast/index.js +16 -10
- package/lib/UploadProgress/index.js +2 -1
- package/lib/UrlEditor/index.js +2 -1
- package/lib/UrlFormatter/index.js +5 -3
- package/lib/formatterConfig/base-formatter-config.js +24 -23
- package/lib/formatterConfig/index.js +3 -2
- package/lib/index.js +7 -0
- package/lib/locales/de.json +5 -1
- package/lib/locales/en.json +5 -1
- package/lib/locales/es.json +6 -2
- package/lib/locales/fr.json +5 -1
- package/lib/locales/pt.json +5 -1
- package/lib/locales/ru.json +5 -1
- package/lib/locales/zh-CN.json +5 -1
- package/lib/select-editor/index.js +22 -13
- package/lib/select-editor/mb-editor/index.js +22 -16
- package/lib/select-editor/pc-editor/index.js +74 -60
- package/lib/toaster/alert.js +25 -16
- package/lib/toaster/toast.js +27 -23
- package/lib/toaster/toastManager.js +16 -13
- package/lib/toaster/toaster.js +2 -1
- package/package.json +2 -2
|
@@ -10,6 +10,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
10
10
|
var _utils = require("../../../utils");
|
|
11
11
|
var _url = require("../../../../utils/url");
|
|
12
12
|
var _MobileOperationSheet = _interopRequireWildcard(require("../../../../MobileOperationSheet"));
|
|
13
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
13
14
|
class FilePreviewer extends _react.default.Component {
|
|
14
15
|
constructor(props) {
|
|
15
16
|
super(props);
|
|
@@ -89,34 +90,48 @@ class FilePreviewer extends _react.default.Component {
|
|
|
89
90
|
fileIconUrl
|
|
90
91
|
} = (0, _url.getFileThumbnailInfo)(fileItem, config);
|
|
91
92
|
const uploadTime = (0, _utils.getFileUploadTime)(fileItem);
|
|
92
|
-
return /*#__PURE__*/
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
93
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
|
|
94
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
95
|
+
className: "dtable-ui-file-editor-previewer-box",
|
|
96
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
97
|
+
className: "dtable-ui-file-editor-previewer-item",
|
|
98
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
99
|
+
className: "dtable-ui-file-editor-previewer-icon",
|
|
100
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)("img", {
|
|
101
|
+
alt: "",
|
|
102
|
+
src: fileIconUrl
|
|
103
|
+
})
|
|
104
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
105
|
+
className: "dtable-ui-file-editor-previewer-info",
|
|
106
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
107
|
+
className: "dtable-ui-file-editor-previewer-item-name ".concat(fileItem.type === 'dir' ? 'dtable-ui-file-editor-previewer-item-name-height' : ''),
|
|
108
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
109
|
+
children: fileItem.name
|
|
110
|
+
})
|
|
111
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
112
|
+
className: "dtable-ui-file-editor-preview-item-detail d-flex",
|
|
113
|
+
children: [uploadTime && /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
114
|
+
className: "file-upload-time",
|
|
115
|
+
children: "".concat(uploadTime, ", ")
|
|
116
|
+
}), fileItem.size > -1 && /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
117
|
+
children: (0, _utils.bytesToSize)(fileItem.size)
|
|
118
|
+
})]
|
|
119
|
+
})]
|
|
120
|
+
})]
|
|
121
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
122
|
+
className: "dtable-ui-file-editor-previewer-operation",
|
|
123
|
+
onClick: this.openOperationSheet,
|
|
124
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)("i", {
|
|
125
|
+
"aria-hidden": "true",
|
|
126
|
+
className: "dtable-font dtable-icon-more-level"
|
|
127
|
+
})
|
|
128
|
+
})]
|
|
129
|
+
}), showOperationSheet && /*#__PURE__*/(0, _jsxRuntime.jsx)(_MobileOperationSheet.default, {
|
|
130
|
+
operations: this.operations,
|
|
131
|
+
onChange: this.onOperationChange,
|
|
132
|
+
onClose: this.closeOperationSheet
|
|
133
|
+
})]
|
|
134
|
+
});
|
|
120
135
|
}
|
|
121
136
|
}
|
|
122
137
|
var _default = exports.default = FilePreviewer;
|
|
@@ -12,6 +12,7 @@ var _lang = require("../../../lang");
|
|
|
12
12
|
var _DTableCommonAddTool = _interopRequireDefault(require("../../../DTableCommonAddTool"));
|
|
13
13
|
var _filePreviewer = _interopRequireDefault(require("./file-previewer"));
|
|
14
14
|
require("./index.css");
|
|
15
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
15
16
|
class MBFilesPreviewer extends _react.default.Component {
|
|
16
17
|
constructor() {
|
|
17
18
|
super(...arguments);
|
|
@@ -36,29 +37,31 @@ class MBFilesPreviewer extends _react.default.Component {
|
|
|
36
37
|
value,
|
|
37
38
|
getDownLoadFiles
|
|
38
39
|
} = this.props;
|
|
39
|
-
return /*#__PURE__*/
|
|
40
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
40
41
|
className: (0, _classnames.default)('dtable-ui-file-editor-previewer dtable-ui-mobile-file-editor-previewer', {
|
|
41
42
|
'mt-0': value.length === 0
|
|
42
|
-
})
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
43
|
+
}),
|
|
44
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
45
|
+
className: (0, _classnames.default)('dtable-ui-file-editor-previewer-wrapper', {
|
|
46
|
+
'd-one': value.length === 0
|
|
47
|
+
}),
|
|
48
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
49
|
+
className: "dtable-ui-file-editor-previewer-content",
|
|
50
|
+
children: value.length > 0 && value.map((fileItem, index) => {
|
|
51
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_filePreviewer.default, {
|
|
52
|
+
fileItem: fileItem,
|
|
53
|
+
deleteFile: this.props.deleteFile,
|
|
54
|
+
renameFile: this.props.renameFile,
|
|
55
|
+
downloadFile: getDownLoadFiles ? this.downloadImage : null
|
|
56
|
+
}, fileItem.url);
|
|
57
|
+
})
|
|
58
|
+
})
|
|
59
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_DTableCommonAddTool.default, {
|
|
60
|
+
className: "dtable-ui-file-editor-previewer-add-btn",
|
|
61
|
+
callBack: this.togglePreviewer,
|
|
62
|
+
footerName: (0, _lang.getLocale)('Add_files')
|
|
63
|
+
})]
|
|
64
|
+
});
|
|
62
65
|
}
|
|
63
66
|
}
|
|
64
67
|
var _default = exports.default = MBFilesPreviewer;
|
|
@@ -8,6 +8,7 @@ exports.default = void 0;
|
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
|
9
9
|
var _reactstrap = require("reactstrap");
|
|
10
10
|
var _lang = require("../../../../lang");
|
|
11
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
11
12
|
class FileDropdownMenu extends _react.default.Component {
|
|
12
13
|
constructor(props) {
|
|
13
14
|
super(props);
|
|
@@ -43,32 +44,37 @@ class FileDropdownMenu extends _react.default.Component {
|
|
|
43
44
|
onRenameFile,
|
|
44
45
|
onDeleteFile
|
|
45
46
|
} = this.props;
|
|
46
|
-
return /*#__PURE__*/
|
|
47
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactstrap.Dropdown, {
|
|
47
48
|
isOpen: this.state.isItemMenuShow,
|
|
48
49
|
toggle: this.onDropdownToggleClick,
|
|
49
|
-
className: "file-dropdown-menu"
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
50
|
+
className: "file-dropdown-menu",
|
|
51
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactstrap.DropdownToggle, {
|
|
52
|
+
tag: "span",
|
|
53
|
+
role: "button",
|
|
54
|
+
"data-toggle": "dropdown",
|
|
55
|
+
"aria-expanded": this.state.isItemMenuShow,
|
|
56
|
+
className: "file-dropdown-icon",
|
|
57
|
+
title: (0, _lang.getLocale)('More_operations'),
|
|
58
|
+
"aria-label": (0, _lang.getLocale)('More_operations'),
|
|
59
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
60
|
+
"aria-hidden": "true",
|
|
61
|
+
className: "dtable-font dtable-icon-more-vertical file-dropdown-more"
|
|
62
|
+
})
|
|
63
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactstrap.DropdownMenu, {
|
|
64
|
+
className: "dtable-dropdown-menu dropdown-menu",
|
|
65
|
+
children: [onRenameFile && /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactstrap.DropdownItem, {
|
|
66
|
+
onClick: this.onRenameFile,
|
|
67
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("i", {
|
|
68
|
+
className: "item-icon dtable-font dtable-icon-rename"
|
|
69
|
+
}), (0, _lang.getLocale)('Rename')]
|
|
70
|
+
}), onDeleteFile && /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactstrap.DropdownItem, {
|
|
71
|
+
onClick: this.onDeleteFile,
|
|
72
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("i", {
|
|
73
|
+
className: "item-icon dtable-font dtable-icon-delete"
|
|
74
|
+
}), (0, _lang.getLocale)('Delete')]
|
|
75
|
+
})]
|
|
76
|
+
})]
|
|
77
|
+
});
|
|
72
78
|
}
|
|
73
79
|
}
|
|
74
80
|
var _default = exports.default = FileDropdownMenu;
|
package/lib/FileEditor/files-previewer/pc-previewer/file-previewer/file-name-editor/index.js
CHANGED
|
@@ -9,6 +9,7 @@ var _react = _interopRequireWildcard(require("react"));
|
|
|
9
9
|
var _reactstrap = require("reactstrap");
|
|
10
10
|
var _constants = require("../../../../../constants");
|
|
11
11
|
require("./index.css");
|
|
12
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
12
13
|
class FileNameEditor extends _react.Component {
|
|
13
14
|
constructor(props) {
|
|
14
15
|
super(props);
|
|
@@ -60,18 +61,19 @@ class FileNameEditor extends _react.Component {
|
|
|
60
61
|
document.removeEventListener('mousedown', this.onMouseDown);
|
|
61
62
|
}
|
|
62
63
|
render() {
|
|
63
|
-
return /*#__PURE__*/
|
|
64
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
64
65
|
className: "pt-1",
|
|
65
|
-
ref: ref => this.fileNameRef = ref
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
66
|
+
ref: ref => this.fileNameRef = ref,
|
|
67
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactstrap.Input, {
|
|
68
|
+
className: "dtable-ui-file-name-input",
|
|
69
|
+
type: "text",
|
|
70
|
+
value: this.state.fileName,
|
|
71
|
+
onChange: this.onChange,
|
|
72
|
+
onKeyDown: this.onKeyDown,
|
|
73
|
+
onBlur: this.onSave,
|
|
74
|
+
autoFocus: true
|
|
75
|
+
})
|
|
76
|
+
});
|
|
75
77
|
}
|
|
76
78
|
}
|
|
77
79
|
var _default = exports.default = FileNameEditor;
|
|
@@ -12,6 +12,7 @@ var _fileNameEditor = _interopRequireDefault(require("./file-name-editor"));
|
|
|
12
12
|
var _utils = require("../../../utils");
|
|
13
13
|
var _url = require("../../../../utils/url");
|
|
14
14
|
require("./index.css");
|
|
15
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
15
16
|
class FilePreviewer extends _react.default.Component {
|
|
16
17
|
constructor(props) {
|
|
17
18
|
super(props);
|
|
@@ -97,71 +98,88 @@ class FilePreviewer extends _react.default.Component {
|
|
|
97
98
|
} = (0, _url.getFileThumbnailInfo)(fileItem, config);
|
|
98
99
|
const errorMessage = '';
|
|
99
100
|
const uploadTime = (0, _utils.getFileUploadTime)(fileItem);
|
|
100
|
-
return /*#__PURE__*/
|
|
101
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
101
102
|
className: "dtable-ui-file-editor-previewer-box ".concat(highlight ? 'dtable-ui-file-editor-previewer-box-highlight' : ''),
|
|
102
103
|
onMouseEnter: this.fileItemMouseEnter,
|
|
103
|
-
onMouseLeave: this.fileItemMouseLeave
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
104
|
+
onMouseLeave: this.fileItemMouseLeave,
|
|
105
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
106
|
+
className: "dtable-ui-file-editor-previewer-item",
|
|
107
|
+
children: [isSelectMultipleFiles && /*#__PURE__*/(0, _jsxRuntime.jsx)("input", {
|
|
108
|
+
onChange: this.onSelectFile,
|
|
109
|
+
checked: isSelected,
|
|
110
|
+
className: "mr-2",
|
|
111
|
+
type: "checkbox"
|
|
112
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
113
|
+
className: "dtable-ui-file-editor-previewer-icon",
|
|
114
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)("img", {
|
|
115
|
+
alt: "",
|
|
116
|
+
src: fileIconUrl
|
|
117
|
+
})
|
|
118
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
119
|
+
className: "dtable-ui-file-editor-previewer-info",
|
|
120
|
+
children: [isShowRename ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_fileNameEditor.default, {
|
|
121
|
+
itemIndex: this.props.itemIndex,
|
|
122
|
+
name: fileItem.name,
|
|
123
|
+
renameFile: this.props.renameFile,
|
|
124
|
+
closeRenameFile: this.closeRenameFile
|
|
125
|
+
}) : /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
126
|
+
className: "dtable-ui-file-editor-previewer-item-name ".concat(fileItem.type === 'dir' ? 'dtable-ui-file-editor-previewer-item-name-height' : ''),
|
|
127
|
+
ref: ref => this.renameRef = ref,
|
|
128
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
129
|
+
onClick: this.props.renameFile ? this.handleFileClick : () => {},
|
|
130
|
+
children: fileItem.name
|
|
131
|
+
})
|
|
132
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
133
|
+
className: "dtable-ui-file-editor-preview-item-detail d-flex",
|
|
134
|
+
children: [uploadTime && /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
135
|
+
className: "file-upload-time",
|
|
136
|
+
children: "".concat(uploadTime, ", ")
|
|
137
|
+
}), fileItem.size > -1 && /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
138
|
+
children: (0, _utils.bytesToSize)(fileItem.size)
|
|
139
|
+
})]
|
|
140
|
+
})]
|
|
141
|
+
})]
|
|
142
|
+
}), !isShowRename && isItemFreezed && /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactstrap.UncontrolledTooltip, {
|
|
143
|
+
delay: {
|
|
144
|
+
show: 0,
|
|
145
|
+
hide: 0
|
|
146
|
+
},
|
|
147
|
+
placement: "bottom",
|
|
148
|
+
target: this.renameRef,
|
|
149
|
+
children: fileItem.name
|
|
150
|
+
}), isShowOperation && /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
151
|
+
className: "dtable-ui-file-editor-previewer-operation",
|
|
152
|
+
children: [this.props.downloadFile && /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
|
|
153
|
+
children: [fileItem.type === 'file' && !errorMessage && /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
154
|
+
"aria-hidden": "true",
|
|
155
|
+
className: "dtable-font dtable-icon-download file-download-icon",
|
|
156
|
+
onClick: this.downloadFile
|
|
157
|
+
}), fileItem.type === 'file' && errorMessage && /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
|
|
158
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
159
|
+
"aria-hidden": "true",
|
|
160
|
+
className: "dtable-font dtable-icon-download disable file-download-icon",
|
|
161
|
+
ref: ref => this.disabledDownloadRef = ref
|
|
162
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactstrap.UncontrolledTooltip, {
|
|
163
|
+
delay: {
|
|
164
|
+
show: 0,
|
|
165
|
+
hide: 0
|
|
166
|
+
},
|
|
167
|
+
placement: "bottom",
|
|
168
|
+
target: this.disabledDownloadRef,
|
|
169
|
+
children: errorMessage
|
|
170
|
+
})]
|
|
171
|
+
})]
|
|
172
|
+
}), (this.props.deleteFile || this.props.renameFile) && /*#__PURE__*/(0, _jsxRuntime.jsx)(_dropdownMenu.default, {
|
|
173
|
+
fileItem: fileItem,
|
|
174
|
+
freezeItem: this.props.freezeItem,
|
|
175
|
+
unFreezeItem: this.props.unFreezeItem,
|
|
176
|
+
resetState: this.resetState,
|
|
177
|
+
itemIndex: this.props.itemIndex,
|
|
178
|
+
onDeleteFile: this.props.deleteFile ? this.props.deleteFile : null,
|
|
179
|
+
onRenameFile: this.props.renameFile ? this.openRenameFile : null
|
|
180
|
+
})]
|
|
181
|
+
})]
|
|
182
|
+
});
|
|
165
183
|
}
|
|
166
184
|
}
|
|
167
185
|
var _default = exports.default = FilePreviewer;
|
|
@@ -13,6 +13,7 @@ var _lang = require("../../../lang");
|
|
|
13
13
|
var _ImagePreviewerLightbox = _interopRequireDefault(require("../../../ImagePreviewerLightbox"));
|
|
14
14
|
var _DTableCommonAddTool = _interopRequireDefault(require("../../../DTableCommonAddTool"));
|
|
15
15
|
var _filePreviewer = _interopRequireDefault(require("./file-previewer"));
|
|
16
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
16
17
|
class PCFilesPreviewer extends _react.default.Component {
|
|
17
18
|
constructor(props) {
|
|
18
19
|
super(props);
|
|
@@ -177,22 +178,32 @@ class PCFilesPreviewer extends _react.default.Component {
|
|
|
177
178
|
selectedFilesList
|
|
178
179
|
} = this.state;
|
|
179
180
|
if (value.length === 0) return null;
|
|
180
|
-
return /*#__PURE__*/
|
|
181
|
-
className: "dtable-ui-file-editor-operation-content"
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
181
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
182
|
+
className: "dtable-ui-file-editor-operation-content",
|
|
183
|
+
children: !isSelectMultipleFiles ? /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
184
|
+
onClick: this.onChangeSelectMultipleFiles.bind(this, true),
|
|
185
|
+
children: (0, _lang.getLocale)('Select')
|
|
186
|
+
}) : /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
|
|
187
|
+
children: [selectedFilesList.length > 0 && /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
|
|
188
|
+
children: [deleteFiles && /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
189
|
+
onClick: this.onDeleteAllSelectedFiles,
|
|
190
|
+
children: (0, _lang.getLocale)('Delete')
|
|
191
|
+
}), getDownLoadFiles && /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
192
|
+
className: "ml-2",
|
|
193
|
+
onClick: this.onDownloadAllSelectedFiles,
|
|
194
|
+
children: (0, _lang.getLocale)('Download')
|
|
195
|
+
})]
|
|
196
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
197
|
+
className: "ml-2",
|
|
198
|
+
onClick: this.onSelectAllFiles,
|
|
199
|
+
children: (0, _lang.getLocale)('Select_all')
|
|
200
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
201
|
+
className: "ml-2",
|
|
202
|
+
onClick: this.onChangeSelectMultipleFiles.bind(this, false),
|
|
203
|
+
children: (0, _lang.getLocale)('Cancel')
|
|
204
|
+
})]
|
|
205
|
+
})
|
|
206
|
+
});
|
|
196
207
|
};
|
|
197
208
|
this.state = {
|
|
198
209
|
isShowRename: false,
|
|
@@ -222,55 +233,60 @@ class PCFilesPreviewer extends _react.default.Component {
|
|
|
222
233
|
isSelectMultipleFiles,
|
|
223
234
|
selectedFilesList
|
|
224
235
|
} = this.state;
|
|
225
|
-
return /*#__PURE__*/
|
|
226
|
-
className: "dtable-ui-file-editor-previewer"
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
236
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
237
|
+
className: "dtable-ui-file-editor-previewer",
|
|
238
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
239
|
+
className: "dtable-ui-file-editor-previewer-wrapper",
|
|
240
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
241
|
+
className: "dtable-ui-file-editor-previewer-header d-flex align-items-center",
|
|
242
|
+
children: [selectedFilesList.length > 0 ? /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
243
|
+
className: "dtable-ui-file-editor-count-content",
|
|
244
|
+
children: selectedFilesList.length === 1 ? (0, _lang.getLocale)('1_file_selected') : (0, _lang.getLocale)('Selected_xxx_files', {
|
|
245
|
+
count: selectedFilesList.length
|
|
246
|
+
})
|
|
247
|
+
}) : /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
248
|
+
className: "dtable-ui-file-editor-count-content",
|
|
249
|
+
children: value.length <= 1 ? (0, _lang.getLocale)('xxx_existing_file', {
|
|
250
|
+
count: value.length
|
|
251
|
+
}) : (0, _lang.getLocale)('xxx_existing_files', {
|
|
252
|
+
count: value.length
|
|
253
|
+
})
|
|
254
|
+
}), this.renderFilesOperation()]
|
|
255
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
256
|
+
className: "dtable-ui-file-editor-previewer-content",
|
|
257
|
+
children: value.length > 0 && value.map((fileItem, index) => {
|
|
258
|
+
const isSelected = selectedFilesList.indexOf(fileItem.name) === -1 ? false : true;
|
|
259
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_filePreviewer.default, {
|
|
260
|
+
fileItem: fileItem,
|
|
261
|
+
deleteFile: this.props.deleteFile,
|
|
262
|
+
renameFile: this.props.renameFile,
|
|
263
|
+
freezeItem: this.freezeItem,
|
|
264
|
+
unFreezeItem: this.unFreezeItem,
|
|
265
|
+
isItemFreezed: this.state.isItemFreezed,
|
|
266
|
+
itemIndex: index,
|
|
267
|
+
isSelected: isSelected,
|
|
268
|
+
showLargeImage: this.showLargeImage,
|
|
269
|
+
onSelectFiles: this.onSelectFiles,
|
|
270
|
+
isSelectMultipleFiles: isSelectMultipleFiles,
|
|
271
|
+
downloadFile: getDownLoadFiles ? this.downloadImage : null
|
|
272
|
+
}, fileItem.url);
|
|
273
|
+
})
|
|
274
|
+
})]
|
|
275
|
+
}), this.state.isShowLargeImage && /*#__PURE__*/(0, _jsxRuntime.jsx)(_ImagePreviewerLightbox.default, {
|
|
276
|
+
imageItems: this.state.fileImageUrlList,
|
|
277
|
+
imageIndex: this.state.largeImageIndex,
|
|
278
|
+
closeImagePopup: this.hideLargeImage,
|
|
279
|
+
moveToPrevImage: this.movePrev,
|
|
280
|
+
moveToNextImage: this.moveNext,
|
|
281
|
+
deleteImage: this.deleteImage,
|
|
282
|
+
downloadImage: this.downloadImage,
|
|
283
|
+
onRotateImage: this.onRotateImage
|
|
284
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_DTableCommonAddTool.default, {
|
|
285
|
+
className: "dtable-ui-file-editor-previewer-add-btn",
|
|
286
|
+
callBack: this.togglePreviewer,
|
|
287
|
+
footerName: (0, _lang.getLocale)('Add_files')
|
|
288
|
+
})]
|
|
289
|
+
});
|
|
274
290
|
}
|
|
275
291
|
}
|
|
276
292
|
var _default = exports.default = PCFilesPreviewer;
|