@akemona-org/strapi-plugin-upload 3.7.0
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/LICENSE +22 -0
- package/README.md +19 -0
- package/admin/src/assets/images/logo.svg +1 -0
- package/admin/src/components/BrowseAssets/Wrapper.js +8 -0
- package/admin/src/components/BrowseAssets/index.js +182 -0
- package/admin/src/components/Card/index.js +146 -0
- package/admin/src/components/CardBorder/index.js +28 -0
- package/admin/src/components/CardControl/Wrapper.js +89 -0
- package/admin/src/components/CardControl/index.js +61 -0
- package/admin/src/components/CardControlsWrapper/index.js +22 -0
- package/admin/src/components/CardEmpty/Bar.js +19 -0
- package/admin/src/components/CardEmpty/Wrapper.js +7 -0
- package/admin/src/components/CardEmpty/index.js +16 -0
- package/admin/src/components/CardErrorMessage/index.js +9 -0
- package/admin/src/components/CardImgWrapper/index.js +52 -0
- package/admin/src/components/CardPreview/Image.js +12 -0
- package/admin/src/components/CardPreview/Wrapper.js +25 -0
- package/admin/src/components/CardPreview/index.js +66 -0
- package/admin/src/components/CardTitle/index.js +14 -0
- package/admin/src/components/CardWrapper/index.js +23 -0
- package/admin/src/components/CheckControl/Button.js +49 -0
- package/admin/src/components/CheckControl/CustomDropdownSection.js +9 -0
- package/admin/src/components/CheckControl/Spacer.js +7 -0
- package/admin/src/components/CheckControl/index.js +74 -0
- package/admin/src/components/Container/index.js +7 -0
- package/admin/src/components/ContainerFluid/index.js +12 -0
- package/admin/src/components/ControlsWrapper/index.js +9 -0
- package/admin/src/components/DragLayer/Wrapper.js +13 -0
- package/admin/src/components/DragLayer/index.js +68 -0
- package/admin/src/components/DropdownButton/index.js +63 -0
- package/admin/src/components/DropdownSection/index.js +27 -0
- package/admin/src/components/Duration/index.js +25 -0
- package/admin/src/components/Duration/utils/formatDuration.js +13 -0
- package/admin/src/components/EditForm/CropWrapper.js +21 -0
- package/admin/src/components/EditForm/ErrorMessage.js +10 -0
- package/admin/src/components/EditForm/FileDetailsBox.js +95 -0
- package/admin/src/components/EditForm/FileDetailsBoxWrapper.js +14 -0
- package/admin/src/components/EditForm/FileWrapper.js +41 -0
- package/admin/src/components/EditForm/FormWrapper.js +7 -0
- package/admin/src/components/EditForm/SizeBox.js +13 -0
- package/admin/src/components/EditForm/Wrapper.js +8 -0
- package/admin/src/components/EditForm/index.js +425 -0
- package/admin/src/components/EditForm/utils/form.js +34 -0
- package/admin/src/components/EditForm/utils/isImageType.js +3 -0
- package/admin/src/components/EditForm/utils/isVideoType.js +3 -0
- package/admin/src/components/FileIcon/Wrapper.js +20 -0
- package/admin/src/components/FileIcon/index.js +33 -0
- package/admin/src/components/FileIcon/utils/extensions.json +4 -0
- package/admin/src/components/FileInfos/index.js +32 -0
- package/admin/src/components/Filters/index.js +30 -0
- package/admin/src/components/FiltersList/index.js +34 -0
- package/admin/src/components/FiltersList/utils/formatFilter.js +36 -0
- package/admin/src/components/FiltersPicker/FiltersCard/FilterButton.js +8 -0
- package/admin/src/components/FiltersPicker/FiltersCard/FilterInput.js +35 -0
- package/admin/src/components/FiltersPicker/FiltersCard/InputWrapper.js +10 -0
- package/admin/src/components/FiltersPicker/FiltersCard/SizeInput.js +57 -0
- package/admin/src/components/FiltersPicker/FiltersCard/Wrapper.js +8 -0
- package/admin/src/components/FiltersPicker/FiltersCard/index.js +97 -0
- package/admin/src/components/FiltersPicker/FiltersCard/init.js +21 -0
- package/admin/src/components/FiltersPicker/FiltersCard/reducer.js +47 -0
- package/admin/src/components/FiltersPicker/FiltersCard/utils/filtersForm.js +27 -0
- package/admin/src/components/FiltersPicker/index.js +43 -0
- package/admin/src/components/FiltersPicker/utils/formatFilter.js +18 -0
- package/admin/src/components/InfiniteLoadingIndicator/Button.js +20 -0
- package/admin/src/components/InfiniteLoadingIndicator/Container.js +12 -0
- package/admin/src/components/InfiniteLoadingIndicator/Wrapper.js +18 -0
- package/admin/src/components/InfiniteLoadingIndicator/index.js +39 -0
- package/admin/src/components/Input/index.js +7 -0
- package/admin/src/components/InputFileModal/Label.js +47 -0
- package/admin/src/components/InputFileModal/P.js +15 -0
- package/admin/src/components/InputFileModal/index.js +73 -0
- package/admin/src/components/InputMedia/CardControlWrapper.js +12 -0
- package/admin/src/components/InputMedia/CardPreviewWrapper.js +13 -0
- package/admin/src/components/InputMedia/Chevron/Wrapper.js +10 -0
- package/admin/src/components/InputMedia/Chevron/index.js +21 -0
- package/admin/src/components/InputMedia/EmptyInputMedia.js +60 -0
- package/admin/src/components/InputMedia/EmptyText.js +13 -0
- package/admin/src/components/InputMedia/ErrorMessage.js +12 -0
- package/admin/src/components/InputMedia/IconUpload.js +48 -0
- package/admin/src/components/InputMedia/InputFilePreview.js +37 -0
- package/admin/src/components/InputMedia/Name.js +10 -0
- package/admin/src/components/InputMedia/Wrapper.js +11 -0
- package/admin/src/components/InputMedia/index.js +238 -0
- package/admin/src/components/InputUploadURL/Wrapper.js +13 -0
- package/admin/src/components/InputUploadURL/index.js +46 -0
- package/admin/src/components/IntlText/index.js +26 -0
- package/admin/src/components/List/ListCell.js +19 -0
- package/admin/src/components/List/ListRow.js +8 -0
- package/admin/src/components/List/index.js +114 -0
- package/admin/src/components/ListEmpty/Wrapper.js +15 -0
- package/admin/src/components/ListEmpty/index.js +70 -0
- package/admin/src/components/ListEmpty/utils/generateRows.js +12 -0
- package/admin/src/components/ListModal/BaselineAlignmentWrapper.js +12 -0
- package/admin/src/components/ListModal/index.js +66 -0
- package/admin/src/components/ListWrapper/index.js +16 -0
- package/admin/src/components/LoadingIndicator/index.js +44 -0
- package/admin/src/components/ModalHeader/BackButton.js +33 -0
- package/admin/src/components/ModalHeader/Wrapper.js +24 -0
- package/admin/src/components/ModalHeader/index.js +47 -0
- package/admin/src/components/ModalNavWrapper/BaselineAlignment.js +12 -0
- package/admin/src/components/ModalNavWrapper/Hr.js +14 -0
- package/admin/src/components/ModalNavWrapper/Wrapper.js +8 -0
- package/admin/src/components/ModalNavWrapper/index.js +70 -0
- package/admin/src/components/ModalSection/index.js +20 -0
- package/admin/src/components/ModalTab/Count/Wrapper.js +16 -0
- package/admin/src/components/ModalTab/Count/index.js +30 -0
- package/admin/src/components/ModalTab/Wrapper.js +37 -0
- package/admin/src/components/ModalTab/index.js +60 -0
- package/admin/src/components/PlayIcon/Play.js +65 -0
- package/admin/src/components/PlayIcon/Wrapper.js +24 -0
- package/admin/src/components/PlayIcon/index.js +23 -0
- package/admin/src/components/SelectAll/Wrapper.js +19 -0
- package/admin/src/components/SelectAll/index.js +26 -0
- package/admin/src/components/SelectedAssets/DraggableCard.js +149 -0
- package/admin/src/components/SelectedAssets/ListTitleWrapper.js +7 -0
- package/admin/src/components/SelectedAssets/ListWrapper.js +7 -0
- package/admin/src/components/SelectedAssets/SortableList.js +102 -0
- package/admin/src/components/SelectedAssets/Wrapper.js +7 -0
- package/admin/src/components/SelectedAssets/index.js +56 -0
- package/admin/src/components/SortList/Wrapper.js +19 -0
- package/admin/src/components/SortList/index.js +37 -0
- package/admin/src/components/SortListItem/Wrapper.js +28 -0
- package/admin/src/components/SortListItem/index.js +35 -0
- package/admin/src/components/SortPicker/index.js +54 -0
- package/admin/src/components/Tag/Wrapper.js +16 -0
- package/admin/src/components/Tag/index.js +25 -0
- package/admin/src/components/UploadForm/index.js +61 -0
- package/admin/src/components/UploadList/ButtonWrapper.js +7 -0
- package/admin/src/components/UploadList/Container.js +10 -0
- package/admin/src/components/UploadList/CustomModalSection.js +9 -0
- package/admin/src/components/UploadList/ListTitle.js +10 -0
- package/admin/src/components/UploadList/ListTitleWrapper.js +7 -0
- package/admin/src/components/UploadList/RowItem.js +98 -0
- package/admin/src/components/UploadList/index.js +90 -0
- package/admin/src/components/VideoPlayer/Wrapper.js +24 -0
- package/admin/src/components/VideoPlayer/index.js +57 -0
- package/admin/src/components/VideoPreview/CanvasWrapper.js +22 -0
- package/admin/src/components/VideoPreview/Thumbnail.js +12 -0
- package/admin/src/components/VideoPreview/Wrapper.js +15 -0
- package/admin/src/components/VideoPreview/index.js +165 -0
- package/admin/src/components/VideoPreview/reducer.js +33 -0
- package/admin/src/containers/App/index.js +31 -0
- package/admin/src/containers/HomePage/HomePageContent/HomePageList.js +98 -0
- package/admin/src/containers/HomePage/HomePageContent/HomePageSettings.js +103 -0
- package/admin/src/containers/HomePage/HomePageContent/index.js +90 -0
- package/admin/src/containers/HomePage/components.js +18 -0
- package/admin/src/containers/HomePage/index.js +373 -0
- package/admin/src/containers/HomePage/init.js +5 -0
- package/admin/src/containers/HomePage/reducer.js +88 -0
- package/admin/src/containers/HomePage/utils/generateParamsFromQuery.js +14 -0
- package/admin/src/containers/HomePage/utils/generateStringFromParams.js +27 -0
- package/admin/src/containers/HomePage/utils/getHeaderLabel.js +13 -0
- package/admin/src/containers/HomePage/utils/index.js +2 -0
- package/admin/src/containers/Initializer/index.js +44 -0
- package/admin/src/containers/InputModalStepper/HeaderSearch.js +12 -0
- package/admin/src/containers/InputModalStepper/InputModalStepper.js +480 -0
- package/admin/src/containers/InputModalStepper/Search.js +48 -0
- package/admin/src/containers/InputModalStepper/index.js +86 -0
- package/admin/src/containers/InputModalStepper/stepper.js +52 -0
- package/admin/src/containers/InputModalStepperProvider/index.js +564 -0
- package/admin/src/containers/InputModalStepperProvider/init.js +5 -0
- package/admin/src/containers/InputModalStepperProvider/reducer.js +301 -0
- package/admin/src/containers/ModalStepper/index.js +629 -0
- package/admin/src/containers/ModalStepper/init.js +5 -0
- package/admin/src/containers/ModalStepper/reducer.js +132 -0
- package/admin/src/containers/ModalStepper/stepper.js +46 -0
- package/admin/src/containers/SettingsPage/Divider.js +11 -0
- package/admin/src/containers/SettingsPage/SectionTitleWrapper.js +7 -0
- package/admin/src/containers/SettingsPage/Wrapper.js +17 -0
- package/admin/src/containers/SettingsPage/index.js +198 -0
- package/admin/src/containers/SettingsPage/init.js +5 -0
- package/admin/src/containers/SettingsPage/reducer.js +38 -0
- package/admin/src/contexts/AppContext/index.js +5 -0
- package/admin/src/contexts/InputModal/InputModalDataManager.js +5 -0
- package/admin/src/contexts/index.js +2 -0
- package/admin/src/hooks/index.js +2 -0
- package/admin/src/hooks/useAppContext/index.js +6 -0
- package/admin/src/hooks/useModalContext.js +6 -0
- package/admin/src/icons/BrokenFile/index.js +91 -0
- package/admin/src/icons/Cloud/index.js +35 -0
- package/admin/src/icons/DoubleFile/index.js +35 -0
- package/admin/src/icons/Download/index.js +36 -0
- package/admin/src/icons/File/index.js +35 -0
- package/admin/src/index.js +85 -0
- package/admin/src/lifecycles.js +13 -0
- package/admin/src/permissions.js +40 -0
- package/admin/src/pluginId.js +5 -0
- package/admin/src/translations/de.json +81 -0
- package/admin/src/translations/dk.json +81 -0
- package/admin/src/translations/en.json +86 -0
- package/admin/src/translations/es.json +81 -0
- package/admin/src/translations/fr.json +85 -0
- package/admin/src/translations/he.json +81 -0
- package/admin/src/translations/index.js +39 -0
- package/admin/src/translations/it.json +82 -0
- package/admin/src/translations/ja.json +81 -0
- package/admin/src/translations/ms.json +73 -0
- package/admin/src/translations/pl.json +81 -0
- package/admin/src/translations/pt-BR.json +81 -0
- package/admin/src/translations/ru.json +81 -0
- package/admin/src/translations/sk.json +81 -0
- package/admin/src/translations/th.json +81 -0
- package/admin/src/translations/uk.json +78 -0
- package/admin/src/translations/zh-Hans.json +86 -0
- package/admin/src/translations/zh.json +81 -0
- package/admin/src/utils/ItemTypes.js +3 -0
- package/admin/src/utils/canDownloadFile.js +3 -0
- package/admin/src/utils/compactParams.js +13 -0
- package/admin/src/utils/createFileToDownloadName.js +9 -0
- package/admin/src/utils/createMatrix.js +32 -0
- package/admin/src/utils/createNewFilesToDownloadArray.js +57 -0
- package/admin/src/utils/createNewFilesToUploadArray.js +25 -0
- package/admin/src/utils/formatBytes.js +13 -0
- package/admin/src/utils/formatFileForEditing.js +20 -0
- package/admin/src/utils/formatFilters.js +23 -0
- package/admin/src/utils/generatePageFromStart.js +5 -0
- package/admin/src/utils/generateStartFromPage.js +5 -0
- package/admin/src/utils/getFileModelTimestamps.js +15 -0
- package/admin/src/utils/getFilesToDownload.js +5 -0
- package/admin/src/utils/getRequestUrl.js +5 -0
- package/admin/src/utils/getTrad.js +5 -0
- package/admin/src/utils/getType.js +15 -0
- package/admin/src/utils/getYupError.js +17 -0
- package/admin/src/utils/index.js +20 -0
- package/admin/src/utils/unformatBytes.js +16 -0
- package/admin/src/utils/urlYupSchema.js +49 -0
- package/config/config.json +8 -0
- package/config/functions/bootstrap.js +143 -0
- package/config/routes.json +98 -0
- package/config/schema.graphql.js +96 -0
- package/controllers/Upload.js +103 -0
- package/controllers/upload/admin.js +213 -0
- package/controllers/upload/api.js +125 -0
- package/controllers/validation/settings.js +22 -0
- package/controllers/validation/upload.js +27 -0
- package/documentation/1.0.0/overrides/upload-File.json +263 -0
- package/errors.js +48 -0
- package/index.js +7 -0
- package/middlewares/upload/defaults.json +5 -0
- package/middlewares/upload/index.js +35 -0
- package/models/File.js +7 -0
- package/models/File.settings.json +86 -0
- package/package.json +71 -0
- package/services/Upload.js +397 -0
- package/services/image-manipulation.js +167 -0
- package/utils/file.js +23 -0
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
import { fromJS } from 'immutable';
|
|
2
|
+
|
|
3
|
+
import { createNewFilesToDownloadArray, createNewFilesToUploadArray } from '../../utils';
|
|
4
|
+
|
|
5
|
+
const initialState = fromJS({
|
|
6
|
+
currentStep: 'browse',
|
|
7
|
+
filesToUpload: [],
|
|
8
|
+
filesToDownload: [],
|
|
9
|
+
fileToEdit: null,
|
|
10
|
+
});
|
|
11
|
+
|
|
12
|
+
const reducer = (state, action) => {
|
|
13
|
+
switch (action.type) {
|
|
14
|
+
case 'ADD_FILES_TO_UPLOAD':
|
|
15
|
+
return state
|
|
16
|
+
.update('filesToUpload', list =>
|
|
17
|
+
list
|
|
18
|
+
.concat(fromJS(createNewFilesToUploadArray(action.filesToUpload)))
|
|
19
|
+
.map((data, index) => data.set('originalIndex', index))
|
|
20
|
+
)
|
|
21
|
+
.update('currentStep', () => action.nextStep);
|
|
22
|
+
case 'ADD_URLS_TO_FILES_TO_UPLOAD':
|
|
23
|
+
return state
|
|
24
|
+
.update('filesToUpload', list =>
|
|
25
|
+
list
|
|
26
|
+
.concat(
|
|
27
|
+
fromJS(createNewFilesToDownloadArray(state.get('filesToDownload'), list.toJS()))
|
|
28
|
+
)
|
|
29
|
+
.map((data, index) => data.set('originalIndex', index))
|
|
30
|
+
)
|
|
31
|
+
.update('currentStep', () => action.nextStep)
|
|
32
|
+
.update('filesToDownload', () => fromJS([]));
|
|
33
|
+
case 'CLEAN_FILES_ERROR':
|
|
34
|
+
return state.update('filesToUpload', list =>
|
|
35
|
+
list.map(data => {
|
|
36
|
+
if (data.get('tempId')) {
|
|
37
|
+
return data;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
return data.set('hasError', false).set('errorMessage', null);
|
|
41
|
+
})
|
|
42
|
+
);
|
|
43
|
+
case 'FILE_DOWNLOADED':
|
|
44
|
+
return state.updateIn(['filesToUpload'], list => {
|
|
45
|
+
return list.map(file => {
|
|
46
|
+
if (file.get('tempId') === action.fileTempId) {
|
|
47
|
+
return file.update('isDownloading', () => false).update('file', () => action.blob);
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
return file;
|
|
51
|
+
});
|
|
52
|
+
});
|
|
53
|
+
case 'GO_TO':
|
|
54
|
+
return state.update('currentStep', () => action.to);
|
|
55
|
+
case 'INIT_FILE_TO_EDIT':
|
|
56
|
+
return state.update('fileToEdit', () => fromJS(action.fileToEdit));
|
|
57
|
+
case 'ON_ABORT_UPLOAD':
|
|
58
|
+
return state.updateIn(['fileToEdit', 'isUploading'], () => false);
|
|
59
|
+
case 'ON_CHANGE_URLS_TO_DOWNLOAD':
|
|
60
|
+
return state.updateIn(['filesToDownload'], () => fromJS(action.value));
|
|
61
|
+
case 'ON_CHANGE':
|
|
62
|
+
return state.updateIn(['fileToEdit', ...action.keys.split('.')], () => action.value);
|
|
63
|
+
case 'ON_SUBMIT_EDIT_NEW_FILE': {
|
|
64
|
+
const originalIndex = state.getIn(['fileToEdit', 'originalIndex']);
|
|
65
|
+
|
|
66
|
+
return state
|
|
67
|
+
.updateIn(['filesToUpload', originalIndex], () => state.get('fileToEdit'))
|
|
68
|
+
.update('fileToEdit', () => null);
|
|
69
|
+
}
|
|
70
|
+
case 'ON_SUBMIT_EDIT_EXISTING_FILE':
|
|
71
|
+
return state.updateIn(['fileToEdit', 'isUploading'], () => true);
|
|
72
|
+
case 'REMOVE_FILE_TO_UPLOAD':
|
|
73
|
+
return state.update('filesToUpload', list => {
|
|
74
|
+
return list.filter(data => data.get('originalIndex') !== action.fileIndex);
|
|
75
|
+
});
|
|
76
|
+
case 'RESET_FILE_TO_EDIT':
|
|
77
|
+
return state.update('fileToEdit', () => null);
|
|
78
|
+
case 'RESET_PROPS':
|
|
79
|
+
return initialState;
|
|
80
|
+
case 'SET_CROP_RESULT': {
|
|
81
|
+
return state.updateIn(['fileToEdit', 'file'], () => fromJS(action.blob));
|
|
82
|
+
}
|
|
83
|
+
case 'SET_FILE_ERROR':
|
|
84
|
+
return state.update('filesToUpload', list => {
|
|
85
|
+
return list.map(data => {
|
|
86
|
+
if (data.get('originalIndex') === action.fileIndex) {
|
|
87
|
+
return data
|
|
88
|
+
.set('isUploading', false)
|
|
89
|
+
.set('hasError', true)
|
|
90
|
+
.set('errorMessage', action.errorMessage);
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
return data;
|
|
94
|
+
});
|
|
95
|
+
});
|
|
96
|
+
case 'SET_FILE_TO_DOWNLOAD_ERROR':
|
|
97
|
+
return state.update('filesToUpload', list => {
|
|
98
|
+
return list.map(file => {
|
|
99
|
+
if (file.get('tempId') === action.fileTempId) {
|
|
100
|
+
return file
|
|
101
|
+
.update('isDownloading', () => false)
|
|
102
|
+
.update('hasError', () => true)
|
|
103
|
+
.update('errorMessage', () => file.get('fileOriginalName'));
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
return file;
|
|
107
|
+
});
|
|
108
|
+
});
|
|
109
|
+
case 'SET_FILE_TO_EDIT':
|
|
110
|
+
return state.update('fileToEdit', () => state.getIn(['filesToUpload', action.fileIndex]));
|
|
111
|
+
case 'SET_FILE_TO_EDIT_ERROR':
|
|
112
|
+
return state
|
|
113
|
+
.updateIn(['fileToEdit', 'hasError'], () => true)
|
|
114
|
+
.updateIn(['fileToEdit', 'errorMessage'], () => action.errorMessage)
|
|
115
|
+
.updateIn(['fileToEdit', 'isUploading'], () => false);
|
|
116
|
+
case 'SET_FILES_UPLOADING_STATE':
|
|
117
|
+
return state.update('filesToUpload', list =>
|
|
118
|
+
list.map(data =>
|
|
119
|
+
data
|
|
120
|
+
.set('isUploading', true)
|
|
121
|
+
.set('hasError', false)
|
|
122
|
+
.set('errorMessage', null)
|
|
123
|
+
)
|
|
124
|
+
);
|
|
125
|
+
|
|
126
|
+
default:
|
|
127
|
+
return state;
|
|
128
|
+
}
|
|
129
|
+
};
|
|
130
|
+
|
|
131
|
+
export default reducer;
|
|
132
|
+
export { initialState };
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import CheckControl from '../../components/CheckControl';
|
|
2
|
+
import EditForm from '../../components/EditForm';
|
|
3
|
+
import UploadForm from '../../components/UploadForm';
|
|
4
|
+
import UploadList from '../../components/UploadList';
|
|
5
|
+
import { getTrad } from '../../utils';
|
|
6
|
+
|
|
7
|
+
const stepper = {
|
|
8
|
+
browse: {
|
|
9
|
+
Component: UploadForm,
|
|
10
|
+
headerBreadcrumbs: [getTrad('modal.header.browse')],
|
|
11
|
+
prev: 'upload',
|
|
12
|
+
next: 'upload',
|
|
13
|
+
withBackButton: true,
|
|
14
|
+
},
|
|
15
|
+
upload: {
|
|
16
|
+
Component: UploadList,
|
|
17
|
+
headerBreadcrumbs: [getTrad('modal.header.pending-assets')],
|
|
18
|
+
next: null,
|
|
19
|
+
prev: 'browse',
|
|
20
|
+
},
|
|
21
|
+
'edit-new': {
|
|
22
|
+
Component: EditForm,
|
|
23
|
+
// TODO: I'll leave it there for the moment
|
|
24
|
+
// because I am not sure about the design since it seems inconsistent
|
|
25
|
+
// headerBreadcrumbs: [
|
|
26
|
+
// getTrad('modal.header.select-files'),
|
|
27
|
+
// getTrad('modal.header.file-detail'),
|
|
28
|
+
// ],
|
|
29
|
+
headerBreadcrumbs: [getTrad('modal.header.file-detail')],
|
|
30
|
+
next: 'upload',
|
|
31
|
+
prev: 'upload',
|
|
32
|
+
withBackButton: true,
|
|
33
|
+
},
|
|
34
|
+
edit: {
|
|
35
|
+
Component: EditForm,
|
|
36
|
+
components: {
|
|
37
|
+
CheckControl,
|
|
38
|
+
},
|
|
39
|
+
headerBreadcrumbs: [getTrad('modal.header.file-detail')],
|
|
40
|
+
next: null,
|
|
41
|
+
prev: null,
|
|
42
|
+
withBackButton: false,
|
|
43
|
+
},
|
|
44
|
+
};
|
|
45
|
+
|
|
46
|
+
export default stepper;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/*
|
|
2
|
+
*
|
|
3
|
+
* This should be a component in the helper plugin that will be used
|
|
4
|
+
* by the webhooks views
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
import styled from 'styled-components';
|
|
8
|
+
|
|
9
|
+
const Wrapper = styled.div`
|
|
10
|
+
padding: 25px 10px;
|
|
11
|
+
margin-top: 33px;
|
|
12
|
+
border-radius: ${({ theme }) => theme.main.sizes.borderRadius};
|
|
13
|
+
box-shadow: 0 2px 4px ${({ theme }) => theme.main.colors.darkGrey};
|
|
14
|
+
background: ${({ theme }) => theme.main.colors.white};
|
|
15
|
+
`;
|
|
16
|
+
|
|
17
|
+
export default Wrapper;
|
|
@@ -0,0 +1,198 @@
|
|
|
1
|
+
import React, { useEffect, useReducer, useRef } from 'react';
|
|
2
|
+
import { Header, Inputs } from '@buffetjs/custom';
|
|
3
|
+
import { Helmet } from 'react-helmet';
|
|
4
|
+
import { Text } from '@buffetjs/core';
|
|
5
|
+
import { isEqual } from 'lodash';
|
|
6
|
+
import { LoadingIndicatorPage, useGlobalContext, request } from 'strapi-helper-plugin';
|
|
7
|
+
|
|
8
|
+
import { getRequestUrl, getTrad } from '../../utils';
|
|
9
|
+
import SectionTitleWrapper from './SectionTitleWrapper';
|
|
10
|
+
import Wrapper from './Wrapper';
|
|
11
|
+
import init from './init';
|
|
12
|
+
import reducer, { initialState } from './reducer';
|
|
13
|
+
|
|
14
|
+
const SettingsPage = () => {
|
|
15
|
+
const { formatMessage } = useGlobalContext();
|
|
16
|
+
const [reducerState, dispatch] = useReducer(reducer, initialState, init);
|
|
17
|
+
const { initialData, isLoading, modifiedData } = reducerState.toJS();
|
|
18
|
+
const isMounted = useRef(true);
|
|
19
|
+
const getDataRef = useRef();
|
|
20
|
+
const abortController = new AbortController();
|
|
21
|
+
|
|
22
|
+
getDataRef.current = async () => {
|
|
23
|
+
try {
|
|
24
|
+
const { signal } = abortController;
|
|
25
|
+
const { data } = await request(getRequestUrl('settings', { method: 'GET', signal }));
|
|
26
|
+
|
|
27
|
+
if (isMounted.current) {
|
|
28
|
+
dispatch({
|
|
29
|
+
type: 'GET_DATA_SUCCEEDED',
|
|
30
|
+
data,
|
|
31
|
+
});
|
|
32
|
+
}
|
|
33
|
+
} catch (err) {
|
|
34
|
+
console.error(err);
|
|
35
|
+
}
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
useEffect(() => {
|
|
39
|
+
getDataRef.current();
|
|
40
|
+
|
|
41
|
+
return () => {
|
|
42
|
+
abortController.abort();
|
|
43
|
+
isMounted.current = false;
|
|
44
|
+
};
|
|
45
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
46
|
+
}, []);
|
|
47
|
+
|
|
48
|
+
const handleSubmit = async () => {
|
|
49
|
+
try {
|
|
50
|
+
await request(getRequestUrl('settings'), {
|
|
51
|
+
method: 'PUT',
|
|
52
|
+
body: modifiedData,
|
|
53
|
+
});
|
|
54
|
+
|
|
55
|
+
if (isMounted.current) {
|
|
56
|
+
dispatch({
|
|
57
|
+
type: 'SUBMIT_SUCCEEDED',
|
|
58
|
+
});
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
strapi.notification.toggle({
|
|
62
|
+
type: 'success',
|
|
63
|
+
message: { id: 'notification.form.success.fields' },
|
|
64
|
+
});
|
|
65
|
+
} catch (err) {
|
|
66
|
+
console.error(err);
|
|
67
|
+
}
|
|
68
|
+
};
|
|
69
|
+
|
|
70
|
+
const headerProps = {
|
|
71
|
+
title: {
|
|
72
|
+
label: formatMessage({ id: getTrad('settings.header.label') }),
|
|
73
|
+
},
|
|
74
|
+
content: formatMessage({
|
|
75
|
+
id: getTrad('settings.sub-header.label'),
|
|
76
|
+
}),
|
|
77
|
+
actions: [
|
|
78
|
+
{
|
|
79
|
+
color: 'cancel',
|
|
80
|
+
disabled: isEqual(initialData, modifiedData),
|
|
81
|
+
// TradId from the strapi-admin package
|
|
82
|
+
label: formatMessage({ id: 'app.components.Button.cancel' }),
|
|
83
|
+
onClick: () => {
|
|
84
|
+
dispatch({
|
|
85
|
+
type: 'CANCEL_CHANGES',
|
|
86
|
+
});
|
|
87
|
+
},
|
|
88
|
+
type: 'button',
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
disabled: false,
|
|
92
|
+
color: 'success',
|
|
93
|
+
// TradId from the strapi-admin package
|
|
94
|
+
label: formatMessage({ id: 'app.components.Button.save' }),
|
|
95
|
+
onClick: handleSubmit,
|
|
96
|
+
type: 'button',
|
|
97
|
+
},
|
|
98
|
+
],
|
|
99
|
+
};
|
|
100
|
+
|
|
101
|
+
const handleChange = ({ target: { name, value } }) => {
|
|
102
|
+
dispatch({
|
|
103
|
+
type: 'ON_CHANGE',
|
|
104
|
+
keys: name,
|
|
105
|
+
value,
|
|
106
|
+
});
|
|
107
|
+
};
|
|
108
|
+
|
|
109
|
+
if (isLoading) {
|
|
110
|
+
return <LoadingIndicatorPage />;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
return (
|
|
114
|
+
<>
|
|
115
|
+
<Helmet title={formatMessage({ id: getTrad('page.title') })} />
|
|
116
|
+
|
|
117
|
+
<Header {...headerProps} />
|
|
118
|
+
<Wrapper>
|
|
119
|
+
<div className="container-fluid">
|
|
120
|
+
<div className="row">
|
|
121
|
+
<SectionTitleWrapper className="col-12">
|
|
122
|
+
<Text fontSize="xs" fontWeight="semiBold" color="#787E8F">
|
|
123
|
+
{formatMessage({ id: getTrad('settings.section.image.label') })}
|
|
124
|
+
</Text>
|
|
125
|
+
</SectionTitleWrapper>
|
|
126
|
+
<div className="col-6">
|
|
127
|
+
<Inputs
|
|
128
|
+
label={formatMessage({
|
|
129
|
+
id: getTrad('settings.form.responsiveDimensions.label'),
|
|
130
|
+
})}
|
|
131
|
+
description={formatMessage({
|
|
132
|
+
id: getTrad('settings.form.responsiveDimensions.description'),
|
|
133
|
+
})}
|
|
134
|
+
name="responsiveDimensions"
|
|
135
|
+
onChange={handleChange}
|
|
136
|
+
type="bool"
|
|
137
|
+
value={modifiedData.responsiveDimensions}
|
|
138
|
+
/>
|
|
139
|
+
</div>
|
|
140
|
+
<div className="col-6">
|
|
141
|
+
<Inputs
|
|
142
|
+
label={formatMessage({
|
|
143
|
+
id: getTrad('settings.form.sizeOptimization.label'),
|
|
144
|
+
})}
|
|
145
|
+
name="sizeOptimization"
|
|
146
|
+
onChange={handleChange}
|
|
147
|
+
type="bool"
|
|
148
|
+
value={modifiedData.sizeOptimization}
|
|
149
|
+
/>
|
|
150
|
+
</div>
|
|
151
|
+
</div>
|
|
152
|
+
<div className="row">
|
|
153
|
+
<div className="col-6">
|
|
154
|
+
<Inputs
|
|
155
|
+
label={formatMessage({
|
|
156
|
+
id: getTrad('settings.form.autoOrientation.label'),
|
|
157
|
+
})}
|
|
158
|
+
description={formatMessage({
|
|
159
|
+
id: getTrad('settings.form.autoOrientation.description'),
|
|
160
|
+
})}
|
|
161
|
+
name="autoOrientation"
|
|
162
|
+
onChange={handleChange}
|
|
163
|
+
type="bool"
|
|
164
|
+
value={modifiedData.autoOrientation}
|
|
165
|
+
/>
|
|
166
|
+
</div>
|
|
167
|
+
</div>
|
|
168
|
+
|
|
169
|
+
{/*
|
|
170
|
+
<Divider />
|
|
171
|
+
<div className="row">
|
|
172
|
+
<SectionTitleWrapper className="col-12">
|
|
173
|
+
<Text fontSize="xs" fontWeight="semiBold" color="#787E8F">
|
|
174
|
+
{formatMessage({ id: getTrad('settings.section.video.label') })}
|
|
175
|
+
</Text>
|
|
176
|
+
</SectionTitleWrapper>
|
|
177
|
+
<div className="col-6">
|
|
178
|
+
<Inputs
|
|
179
|
+
label={formatMessage({
|
|
180
|
+
id: getTrad('settings.form.videoPreview.label'),
|
|
181
|
+
})}
|
|
182
|
+
description={formatMessage({
|
|
183
|
+
id: getTrad('settings.form.videoPreview.description'),
|
|
184
|
+
})}
|
|
185
|
+
name="videoPreview"
|
|
186
|
+
onChange={handleChange}
|
|
187
|
+
type="bool"
|
|
188
|
+
value={modifiedData.videoPreview}
|
|
189
|
+
/>
|
|
190
|
+
</div>
|
|
191
|
+
</div> */}
|
|
192
|
+
</div>
|
|
193
|
+
</Wrapper>
|
|
194
|
+
</>
|
|
195
|
+
);
|
|
196
|
+
};
|
|
197
|
+
|
|
198
|
+
export default SettingsPage;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { fromJS } from 'immutable';
|
|
2
|
+
|
|
3
|
+
const initialState = fromJS({
|
|
4
|
+
isLoading: true,
|
|
5
|
+
initialData: {
|
|
6
|
+
responsiveDimensions: true,
|
|
7
|
+
sizeOptimization: true,
|
|
8
|
+
autoOrientation: false,
|
|
9
|
+
videoPreview: false,
|
|
10
|
+
},
|
|
11
|
+
modifiedData: {
|
|
12
|
+
responsiveDimensions: true,
|
|
13
|
+
sizeOptimization: true,
|
|
14
|
+
autoOrientation: false,
|
|
15
|
+
videoPreview: false,
|
|
16
|
+
},
|
|
17
|
+
});
|
|
18
|
+
|
|
19
|
+
const reducer = (state, action) => {
|
|
20
|
+
switch (action.type) {
|
|
21
|
+
case 'CANCEL_CHANGES':
|
|
22
|
+
return state.update('modifiedData', () => state.get('initialData'));
|
|
23
|
+
case 'GET_DATA_SUCCEEDED':
|
|
24
|
+
return state
|
|
25
|
+
.update('isLoading', () => false)
|
|
26
|
+
.update('initialData', () => fromJS(action.data))
|
|
27
|
+
.update('modifiedData', () => fromJS(action.data));
|
|
28
|
+
case 'ON_CHANGE':
|
|
29
|
+
return state.updateIn(['modifiedData', ...action.keys.split('.')], () => action.value);
|
|
30
|
+
case 'SUBMIT_SUCCEEDED':
|
|
31
|
+
return state.update('initialData', () => state.get('modifiedData'));
|
|
32
|
+
default:
|
|
33
|
+
return state;
|
|
34
|
+
}
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
export default reducer;
|
|
38
|
+
export { initialState };
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
|
|
3
|
+
const BrokenFile = props => {
|
|
4
|
+
return (
|
|
5
|
+
<svg
|
|
6
|
+
width="48px"
|
|
7
|
+
height="55px"
|
|
8
|
+
viewBox="0 0 48 55"
|
|
9
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
10
|
+
{...props}
|
|
11
|
+
>
|
|
12
|
+
<defs>
|
|
13
|
+
<filter
|
|
14
|
+
x="-1.7%"
|
|
15
|
+
y="-2.1%"
|
|
16
|
+
width="103.5%"
|
|
17
|
+
height="104.1%"
|
|
18
|
+
filterUnits="objectBoundingBox"
|
|
19
|
+
id="filter-1"
|
|
20
|
+
>
|
|
21
|
+
<feOffset dx="0" dy="2" in="SourceAlpha" result="shadowOffsetOuter1" />
|
|
22
|
+
<feGaussianBlur stdDeviation="2" in="shadowOffsetOuter1" result="shadowBlurOuter1" />
|
|
23
|
+
<feColorMatrix
|
|
24
|
+
values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.05 0"
|
|
25
|
+
type="matrix"
|
|
26
|
+
in="shadowBlurOuter1"
|
|
27
|
+
result="shadowMatrixOuter1"
|
|
28
|
+
/>
|
|
29
|
+
<feMerge>
|
|
30
|
+
<feMergeNode in="shadowMatrixOuter1" />
|
|
31
|
+
<feMergeNode in="SourceGraphic" />
|
|
32
|
+
</feMerge>
|
|
33
|
+
</filter>
|
|
34
|
+
</defs>
|
|
35
|
+
<g strokeWidth="1" fill="none" fillRule="evenodd">
|
|
36
|
+
<g transform="translate(-649.000000, -362.000000)" fill="#919BAE" fillRule="nonzero">
|
|
37
|
+
<g filter="url(#filter-1)" transform="translate(323.000000, 181.000000)">
|
|
38
|
+
<g transform="translate(30.000000, 143.000000)">
|
|
39
|
+
<g transform="translate(219.000000, 0.000000)">
|
|
40
|
+
<g transform="translate(81.000000, 40.000000)">
|
|
41
|
+
<path
|
|
42
|
+
d="M12.6046679,27.5832436 C12.6095286,27.5828862 12.6144091,27.5828862 12.6192699,27.5832436 L12.6245362,27.576541 L12.6245362,27.576541 L15.0022741,24.5139437 L14.9955715,24.5086774 L14.9924596,24.5125075 L9.97486535,24.5125075 C9.75144624,24.5125075 9.5679234,24.5843208 9.42429683,24.7279473 C9.28067026,24.8715739 9.20885697,25.0550967 9.20885697,25.2785159 L9.20885697,26.8105326 C9.20885697,27.0339517 9.28067026,27.2174746 9.42429683,27.3611011 C9.5679234,27.5047277 9.75144624,27.576541 9.97486535,27.576541 L12.6101735,27.576541 L12.6046679,27.5832436 Z"
|
|
43
|
+
id="Path"
|
|
44
|
+
/>
|
|
45
|
+
<path
|
|
46
|
+
d="M27.6888091,1.6277678 C27.2419709,1.18092958 26.6355476,0.797925394 25.8695392,0.478755236 C25.1035308,0.159585079 24.4013565,0 23.7630162,0 L2.31478157,0 C1.67644125,0 1.13385198,0.22341911 0.687013764,0.670257331 C0.240175544,1.11709555 0.0167564333,1.65968482 0.0167564333,2.29802513 L0.0167564333,40.598444 C0.0167564333,41.2367844 0.240175544,41.7793736 0.687013764,42.2262118 C0.735996042,42.2723467 0.778367716,42.3250293 0.812926391,42.3827648 C0.888569719,42.4198683 0.960383004,42.464632 1.03459007,42.5043686 L3.08797127,39.8609216 C3.085865,39.8498828 3.08506158,39.8386349 3.0855775,39.8274087 L3.08174746,39.8324357 L3.08174746,3.06403351 L21.4659485,3.06403351 L21.4659485,13.0221424 C21.4659485,13.6604827 21.6893676,14.203072 22.1362059,14.6499102 C22.1886141,14.6983281 22.2328333,14.7549158 22.2671454,14.8174746 L22.2858169,14.8318372 C22.3380012,14.8653501 22.4021544,14.883064 22.4574506,14.9125075 L24.529982,12.2429683 L24.529982,3.25553561 C24.9927788,3.41512069 25.3199282,3.59066427 25.5114303,3.78216637 L28.6568522,6.92758827 L30.5503291,4.48833034 L27.6888091,1.6277678 Z"
|
|
47
|
+
id="Path"
|
|
48
|
+
/>
|
|
49
|
+
<path
|
|
50
|
+
d="M9.97486535,30.6403351 C9.75144624,30.6403351 9.5679234,30.7121484 9.42429683,30.855775 C9.28067026,30.9994016 9.20885697,31.1829244 9.20885697,31.4063435 L9.20885697,31.9509276 L9.20694195,31.953082 C9.21125075,31.9561939 9.21508079,31.9593058 9.21891083,31.9626571 L10.2324357,30.6570916 C10.2250783,30.6522434 10.2182575,30.6466263 10.2120886,30.6403351 L9.97486535,30.6403351 Z"
|
|
51
|
+
id="Path"
|
|
52
|
+
/>
|
|
53
|
+
<path
|
|
54
|
+
d="M19.7620586,18.3777379 L19.7570317,18.3842011 L9.97486535,18.3842011 C9.75144624,18.3842011 9.5679234,18.4560144 9.42429683,18.5996409 C9.28067026,18.7432675 9.20885697,18.9267903 9.20885697,19.1502095 L9.20885697,20.6822262 C9.20885697,20.9056453 9.28067026,21.0891682 9.42429683,21.2327947 C9.5679234,21.3764213 9.75144624,21.4482346 9.97486535,21.4482346 L17.3237582,21.4482346 C17.3271095,21.4467983 17.329982,21.4451227 17.3333333,21.4439258 C17.3507235,21.4371428 17.3697825,21.4358889 17.3879114,21.4403351 L19.7611011,18.3842011 L19.7651706,18.3789348 L19.7620586,18.3777379 Z"
|
|
55
|
+
id="Path"
|
|
56
|
+
/>
|
|
57
|
+
<path
|
|
58
|
+
d="M13.4501496,33.8436864 L12.4102932,35.1758229 C12.4119626,35.19142 12.4105804,35.207193 12.4062238,35.2222621 L13.4783962,33.8403351 L13.4803112,33.8379414 C13.470575,33.8412556 13.4604224,33.8431894 13.4501496,33.8436864 Z"
|
|
59
|
+
id="Path"
|
|
60
|
+
/>
|
|
61
|
+
<path
|
|
62
|
+
d="M15.8467983,30.7743866 C15.8489884,30.7762577 15.8510666,30.778256 15.8530221,30.780371 L15.8561341,30.7763016 L15.8561341,30.7763016 L17.59617,28.5338121 L15.8467983,30.7743866 Z"
|
|
63
|
+
id="Path"
|
|
64
|
+
/>
|
|
65
|
+
<path
|
|
66
|
+
d="M30.5733094,34.055775 C30.4296828,33.9121484 30.24616,33.8403351 30.0227409,33.8403351 L13.4783962,33.8403351 L12.4062238,35.2222621 C12.4057743,35.2240504 12.4052147,35.2258092 12.4045482,35.2275284 L12.4045482,36.1371634 C12.4045482,36.3605825 12.4763615,36.5441053 12.619988,36.6877319 C12.7636146,36.8313585 12.9471374,36.9031718 13.1705566,36.9031718 L30.0227409,36.9031718 C30.24616,36.9031718 30.4296828,36.8313585 30.5733094,36.6877319 C30.716936,36.5441053 30.7887493,36.3605825 30.7887493,36.1371634 L30.7887493,34.6051466 C30.7887493,34.382685 30.716936,34.1995611 30.5733094,34.055775 Z"
|
|
67
|
+
id="Path"
|
|
68
|
+
/>
|
|
69
|
+
<path
|
|
70
|
+
d="M30.5733094,27.927708 C30.4296828,27.7840814 30.24616,27.7122681 30.0227409,27.7122681 L18.2369838,27.7122681 L18.239617,27.7089168 L18.2355476,27.7089168 L18.2329144,27.7122681 L18.2329144,27.7122681 L17.59617,28.5338121 L17.59617,28.5338121 L15.8554159,30.7772591 L30.0227409,30.7772591 C30.24616,30.7772591 30.4296828,30.7054458 30.5733094,30.5618193 C30.716936,30.4181927 30.7887493,30.2346699 30.7887493,30.0112507 L30.7887493,28.479234 C30.7887493,28.2553361 30.716936,28.0714941 30.5733094,27.927708 Z"
|
|
71
|
+
id="Path"
|
|
72
|
+
/>
|
|
73
|
+
<path
|
|
74
|
+
d="M30.5733094,21.7996409 C30.4296828,21.6560144 30.24616,21.5842011 30.0227409,21.5842011 L23.0209455,21.5842011 L23.0242968,21.5801317 C23.0140369,21.5826692 23.0035075,21.5839553 22.9929384,21.5839617 L22.9879114,21.5839617 L22.9879114,21.5839617 L22.9879114,21.5839617 L20.6211849,24.6343507 C20.6252614,24.6386198 20.6290215,24.64318 20.6324357,24.6479952 L30.0232196,24.6479952 C30.2466387,24.6479952 30.4301616,24.5761819 30.5737882,24.4325554 C30.7174147,24.2889288 30.789228,24.1054059 30.789228,23.8819868 L30.789228,22.3499701 C30.7889088,22.1268701 30.716936,21.9434271 30.5733094,21.7996409 Z"
|
|
75
|
+
id="Path"
|
|
76
|
+
/>
|
|
77
|
+
<path
|
|
78
|
+
d="M39.5020946,14.1156194 C39.1829244,13.349611 38.7999202,12.7431877 38.353082,12.2963495 L33.758468,7.70149611 L31.8704967,10.1347696 C31.8771755,10.1428415 31.8824366,10.1519878 31.8860563,10.1618193 L36.1986834,14.4746858 C36.3901855,14.6661879 36.5657291,14.9933373 36.7253142,15.4561341 L27.7419509,15.4561341 L25.677319,18.1170557 C25.6828221,18.131141 25.6909447,18.1440558 25.7012567,18.1551167 C26.1464991,18.5998803 26.3212448,18.5201676 26.958468,18.5201676 L36.9165769,18.5201676 L36.9165769,43.0324357 L6.35547576,43.0324357 C6.35123136,43.034836 6.34673598,43.0367626 6.34207062,43.0381807 L4.25302214,45.7309396 C4.69994016,46.1776182 4.87229204,46.0964692 5.51047277,46.0964692 L37.6828247,46.0964692 C38.321165,46.0964692 38.8637542,45.8730501 39.3105925,45.4262118 C39.7574307,44.9793736 39.9808498,44.4367844 39.9808498,43.798444 L39.9808498,16.2221424 C39.9808498,15.5836425 39.8212647,14.8814682 39.5020946,14.1156194 Z"
|
|
79
|
+
id="Path"
|
|
80
|
+
/>
|
|
81
|
+
</g>
|
|
82
|
+
</g>
|
|
83
|
+
</g>
|
|
84
|
+
</g>
|
|
85
|
+
</g>
|
|
86
|
+
</g>
|
|
87
|
+
</svg>
|
|
88
|
+
);
|
|
89
|
+
};
|
|
90
|
+
|
|
91
|
+
export default BrokenFile;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
|
|
3
|
+
const Cloud = props => {
|
|
4
|
+
return (
|
|
5
|
+
<svg width="53" height="42" xmlns="http://www.w3.org/2000/svg" {...props}>
|
|
6
|
+
<defs>
|
|
7
|
+
<filter
|
|
8
|
+
x="-1.7%"
|
|
9
|
+
y="-3.1%"
|
|
10
|
+
width="103.5%"
|
|
11
|
+
height="106.2%"
|
|
12
|
+
filterUnits="objectBoundingBox"
|
|
13
|
+
id="a"
|
|
14
|
+
>
|
|
15
|
+
<feOffset dy="2" in="SourceAlpha" result="shadowOffsetOuter1" />
|
|
16
|
+
<feGaussianBlur stdDeviation="2" in="shadowOffsetOuter1" result="shadowBlurOuter1" />
|
|
17
|
+
<feColorMatrix
|
|
18
|
+
values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.05 0"
|
|
19
|
+
in="shadowBlurOuter1"
|
|
20
|
+
result="shadowMatrixOuter1"
|
|
21
|
+
/>
|
|
22
|
+
<feMerge>
|
|
23
|
+
<feMergeNode in="shadowMatrixOuter1" />
|
|
24
|
+
<feMergeNode in="SourceGraphic" />
|
|
25
|
+
</feMerge>
|
|
26
|
+
</filter>
|
|
27
|
+
</defs>
|
|
28
|
+
<g transform="translate(-434 -135)" fill="#E9EAEB" fillRule="nonzero">
|
|
29
|
+
<path d="M467.222 156.644a.559.559 0 00-.158-.41l-6.187-6.27a.544.544 0 00-.405-.16.544.544 0 00-.404.16l-6.17 6.252a.674.674 0 00-.176.428.544.544 0 00.563.57h3.937v6.27c0 .154.056.288.167.4.112.113.244.17.396.17h3.375a.537.537 0 00.395-.17.551.551 0 00.167-.4v-6.27h3.938a.537.537 0 00.395-.17.551.551 0 00.167-.4zM483 161.156c0 2.5-.879 4.635-2.637 6.404-1.758 1.77-3.879 2.654-6.363 2.654h-25.5c-2.89 0-5.363-1.034-7.418-3.102-2.055-2.068-3.082-4.557-3.082-7.466 0-2.044.547-3.932 1.64-5.661a10.28 10.28 0 014.407-3.893c-.031-.472-.047-.81-.047-1.014 0-3.334 1.172-6.18 3.516-8.54C449.859 138.18 452.687 137 456 137c2.438 0 4.668.684 6.691 2.052a11.817 11.817 0 014.418 5.45c1.11-.976 2.407-1.463 3.891-1.463 1.656 0 3.07.59 4.242 1.77 1.172 1.179 1.758 2.602 1.758 4.269 0 1.195-.32 2.28-.96 3.255 2.03.488 3.698 1.553 5.003 3.197 1.305 1.643 1.957 3.518 1.957 5.626z" />
|
|
30
|
+
</g>
|
|
31
|
+
</svg>
|
|
32
|
+
);
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
export default Cloud;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
|
|
3
|
+
const DoubleFile = props => {
|
|
4
|
+
return (
|
|
5
|
+
<svg width="21" height="21" xmlns="http://www.w3.org/2000/svg" {...props}>
|
|
6
|
+
<defs>
|
|
7
|
+
<filter
|
|
8
|
+
x="-1.7%"
|
|
9
|
+
y="-2.1%"
|
|
10
|
+
width="103.5%"
|
|
11
|
+
height="104.1%"
|
|
12
|
+
filterUnits="objectBoundingBox"
|
|
13
|
+
id="a"
|
|
14
|
+
>
|
|
15
|
+
<feOffset dy="2" in="SourceAlpha" result="shadowOffsetOuter1" />
|
|
16
|
+
<feGaussianBlur stdDeviation="2" in="shadowOffsetOuter1" result="shadowBlurOuter1" />
|
|
17
|
+
<feColorMatrix
|
|
18
|
+
values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.05 0"
|
|
19
|
+
in="shadowBlurOuter1"
|
|
20
|
+
result="shadowMatrixOuter1"
|
|
21
|
+
/>
|
|
22
|
+
<feMerge>
|
|
23
|
+
<feMergeNode in="shadowMatrixOuter1" />
|
|
24
|
+
<feMergeNode in="SourceGraphic" />
|
|
25
|
+
</feMerge>
|
|
26
|
+
</filter>
|
|
27
|
+
</defs>
|
|
28
|
+
<g transform="translate(-443 -195)" fill="#EEE" fillRule="nonzero">
|
|
29
|
+
<path d="M458.781 197h-8.125c-.673 0-1.219.546-1.219 1.219v1.219h-1.218c-.673 0-1.219.545-1.219 1.218v8.125c0 .673.546 1.219 1.219 1.219h8.125c.673 0 1.219-.546 1.219-1.219v-1.219h1.218c.673 0 1.219-.545 1.219-1.218v-8.125c0-.673-.546-1.219-1.219-1.219zm-2.59 11.781h-7.82a.152.152 0 01-.152-.152v-7.82c0-.085.068-.153.152-.153h1.067v5.688c0 .673.545 1.219 1.218 1.219h5.688v1.066a.152.152 0 01-.153.152zm2.438-2.437h-7.82a.152.152 0 01-.153-.153v-7.82c0-.084.068-.152.153-.152h7.82c.084 0 .152.068.152.152v7.82a.152.152 0 01-.152.153z" />
|
|
30
|
+
</g>
|
|
31
|
+
</svg>
|
|
32
|
+
);
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
export default DoubleFile;
|