@panneau/field-upload 3.0.77 → 3.0.79
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/es/index.js +35 -39
- package/lib/index.js +34 -38
- package/package.json +2 -2
package/es/index.js
CHANGED
|
@@ -4,7 +4,7 @@ import _slicedToArray from '@babel/runtime/helpers/slicedToArray';
|
|
|
4
4
|
import _objectSpread from '@babel/runtime/helpers/objectSpread2';
|
|
5
5
|
import { faTimes, faFileVideo, faFileImage, faFileAudio } from '@fortawesome/free-solid-svg-icons';
|
|
6
6
|
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
|
|
7
|
-
import { Dashboard } from '@uppy/react';
|
|
7
|
+
import { Dashboard, DashboardModal } from '@uppy/react';
|
|
8
8
|
import classNames from 'classnames';
|
|
9
9
|
import get from 'lodash/get';
|
|
10
10
|
import isArray from 'lodash/isArray';
|
|
@@ -183,7 +183,7 @@ var UploadField = function UploadField(_ref) {
|
|
|
183
183
|
var closeModal = useCallback(function () {
|
|
184
184
|
setModalOpened(false);
|
|
185
185
|
}, [setModalOpened]);
|
|
186
|
-
|
|
186
|
+
useCallback(function () {
|
|
187
187
|
closeModal();
|
|
188
188
|
if (uppy !== null) {
|
|
189
189
|
uppy.cancelAll();
|
|
@@ -388,49 +388,45 @@ var UploadField = function UploadField(_ref) {
|
|
|
388
388
|
showProgressDetails: true,
|
|
389
389
|
areInsidesReadyToBeVisible: true,
|
|
390
390
|
proudlyDisplayPoweredByUppy: false
|
|
391
|
-
}))) : null, !showResourceModal && !disabled && withButton && uppy !== null && modalOpened ?
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
// open={modalOpened}
|
|
398
|
-
// isHidden={!modalOpened}
|
|
399
|
-
// {...(width !== null ? { width } : null)}
|
|
400
|
-
// {...(height !== null ? { height } : null)}
|
|
401
|
-
// onRequestClose={closeModal}
|
|
402
|
-
// proudlyDisplayPoweredByUppy={false}
|
|
403
|
-
// closeModalOnClickOutside
|
|
404
|
-
// areInsidesReadyToBeVisible
|
|
405
|
-
// isDashboardVisible
|
|
406
|
-
// showProgressDetailss
|
|
407
|
-
// showAddFilesPanel
|
|
408
|
-
// />
|
|
409
|
-
// ) : //
|
|
410
|
-
React.createElement(Dialog, {
|
|
411
|
-
size: "lg",
|
|
412
|
-
onClose: closeModal,
|
|
413
|
-
title: addButtonLabel
|
|
414
|
-
}, /*#__PURE__*/React.createElement(Dashboard, Object.assign({
|
|
415
|
-
uppy: uppy
|
|
416
|
-
// {...(containerWidth !== null && height !== null
|
|
417
|
-
// ? { width: containerWidth }
|
|
418
|
-
// : null)}
|
|
391
|
+
}))) : null, !showResourceModal && !disabled && withButton && uppy !== null && modalOpened ? /*#__PURE__*/React.createElement(DashboardModal, Object.assign({
|
|
392
|
+
uppy: uppy,
|
|
393
|
+
className: styles.dashboardModal,
|
|
394
|
+
plugins: sources,
|
|
395
|
+
open: modalOpened,
|
|
396
|
+
isHidden: !modalOpened
|
|
419
397
|
}, width !== null ? {
|
|
420
398
|
width: width
|
|
421
399
|
} : null, height !== null ? {
|
|
422
400
|
height: height
|
|
423
401
|
} : null, {
|
|
424
|
-
|
|
425
|
-
inline: true,
|
|
426
|
-
showProgressDetails: true
|
|
427
|
-
// areInsidesReadyToBeVisible
|
|
428
|
-
// isDashboardVisible
|
|
429
|
-
,
|
|
430
|
-
showAddFilesPanel: true,
|
|
402
|
+
onRequestClose: closeModal,
|
|
431
403
|
proudlyDisplayPoweredByUppy: false,
|
|
432
|
-
|
|
433
|
-
|
|
404
|
+
closeModalOnClickOutside: true,
|
|
405
|
+
areInsidesReadyToBeVisible: true,
|
|
406
|
+
isDashboardVisible: true,
|
|
407
|
+
showProgressDetails: true,
|
|
408
|
+
showAddFilesPanel: true
|
|
409
|
+
})) :
|
|
410
|
+
// ) : //
|
|
411
|
+
// <Dialog size="lg" onClose={closeModal} title={addButtonLabel}>
|
|
412
|
+
// <Dashboard
|
|
413
|
+
// uppy={uppy}
|
|
414
|
+
// // {...(containerWidth !== null && height !== null
|
|
415
|
+
// // ? { width: containerWidth }
|
|
416
|
+
// // : null)}
|
|
417
|
+
// {...(width !== null ? { width } : null)}
|
|
418
|
+
// {...(height !== null ? { height } : null)}
|
|
419
|
+
// plugins={sources}
|
|
420
|
+
// inline
|
|
421
|
+
// showProgressDetails
|
|
422
|
+
// // areInsidesReadyToBeVisible
|
|
423
|
+
// // isDashboardVisible
|
|
424
|
+
// showAddFilesPanel
|
|
425
|
+
// proudlyDisplayPoweredByUppy={false}
|
|
426
|
+
// doneButtonHandler={closeModalAndClear}
|
|
427
|
+
// />
|
|
428
|
+
// </Dialog>
|
|
429
|
+
null, showResourceModal ? /*#__PURE__*/React.createElement(Dialog, {
|
|
434
430
|
title: /*#__PURE__*/React.createElement(Label, null, searchButtonLabel),
|
|
435
431
|
size: "lg",
|
|
436
432
|
onClose: closeResourceModal
|
package/lib/index.js
CHANGED
|
@@ -205,7 +205,7 @@ var UploadField = function UploadField(_ref) {
|
|
|
205
205
|
var closeModal = React.useCallback(function () {
|
|
206
206
|
setModalOpened(false);
|
|
207
207
|
}, [setModalOpened]);
|
|
208
|
-
|
|
208
|
+
React.useCallback(function () {
|
|
209
209
|
closeModal();
|
|
210
210
|
if (uppy$1 !== null) {
|
|
211
211
|
uppy$1.cancelAll();
|
|
@@ -410,49 +410,45 @@ var UploadField = function UploadField(_ref) {
|
|
|
410
410
|
showProgressDetails: true,
|
|
411
411
|
areInsidesReadyToBeVisible: true,
|
|
412
412
|
proudlyDisplayPoweredByUppy: false
|
|
413
|
-
}))) : null, !showResourceModal && !disabled && withButton && uppy$1 !== null && modalOpened ?
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
// open={modalOpened}
|
|
420
|
-
// isHidden={!modalOpened}
|
|
421
|
-
// {...(width !== null ? { width } : null)}
|
|
422
|
-
// {...(height !== null ? { height } : null)}
|
|
423
|
-
// onRequestClose={closeModal}
|
|
424
|
-
// proudlyDisplayPoweredByUppy={false}
|
|
425
|
-
// closeModalOnClickOutside
|
|
426
|
-
// areInsidesReadyToBeVisible
|
|
427
|
-
// isDashboardVisible
|
|
428
|
-
// showProgressDetailss
|
|
429
|
-
// showAddFilesPanel
|
|
430
|
-
// />
|
|
431
|
-
// ) : //
|
|
432
|
-
React__default["default"].createElement(Dialog__default["default"], {
|
|
433
|
-
size: "lg",
|
|
434
|
-
onClose: closeModal,
|
|
435
|
-
title: addButtonLabel
|
|
436
|
-
}, /*#__PURE__*/React__default["default"].createElement(react.Dashboard, Object.assign({
|
|
437
|
-
uppy: uppy$1
|
|
438
|
-
// {...(containerWidth !== null && height !== null
|
|
439
|
-
// ? { width: containerWidth }
|
|
440
|
-
// : null)}
|
|
413
|
+
}))) : null, !showResourceModal && !disabled && withButton && uppy$1 !== null && modalOpened ? /*#__PURE__*/React__default["default"].createElement(react.DashboardModal, Object.assign({
|
|
414
|
+
uppy: uppy$1,
|
|
415
|
+
className: styles.dashboardModal,
|
|
416
|
+
plugins: sources,
|
|
417
|
+
open: modalOpened,
|
|
418
|
+
isHidden: !modalOpened
|
|
441
419
|
}, width !== null ? {
|
|
442
420
|
width: width
|
|
443
421
|
} : null, height !== null ? {
|
|
444
422
|
height: height
|
|
445
423
|
} : null, {
|
|
446
|
-
|
|
447
|
-
inline: true,
|
|
448
|
-
showProgressDetails: true
|
|
449
|
-
// areInsidesReadyToBeVisible
|
|
450
|
-
// isDashboardVisible
|
|
451
|
-
,
|
|
452
|
-
showAddFilesPanel: true,
|
|
424
|
+
onRequestClose: closeModal,
|
|
453
425
|
proudlyDisplayPoweredByUppy: false,
|
|
454
|
-
|
|
455
|
-
|
|
426
|
+
closeModalOnClickOutside: true,
|
|
427
|
+
areInsidesReadyToBeVisible: true,
|
|
428
|
+
isDashboardVisible: true,
|
|
429
|
+
showProgressDetails: true,
|
|
430
|
+
showAddFilesPanel: true
|
|
431
|
+
})) :
|
|
432
|
+
// ) : //
|
|
433
|
+
// <Dialog size="lg" onClose={closeModal} title={addButtonLabel}>
|
|
434
|
+
// <Dashboard
|
|
435
|
+
// uppy={uppy}
|
|
436
|
+
// // {...(containerWidth !== null && height !== null
|
|
437
|
+
// // ? { width: containerWidth }
|
|
438
|
+
// // : null)}
|
|
439
|
+
// {...(width !== null ? { width } : null)}
|
|
440
|
+
// {...(height !== null ? { height } : null)}
|
|
441
|
+
// plugins={sources}
|
|
442
|
+
// inline
|
|
443
|
+
// showProgressDetails
|
|
444
|
+
// // areInsidesReadyToBeVisible
|
|
445
|
+
// // isDashboardVisible
|
|
446
|
+
// showAddFilesPanel
|
|
447
|
+
// proudlyDisplayPoweredByUppy={false}
|
|
448
|
+
// doneButtonHandler={closeModalAndClear}
|
|
449
|
+
// />
|
|
450
|
+
// </Dialog>
|
|
451
|
+
null, showResourceModal ? /*#__PURE__*/React__default["default"].createElement(Dialog__default["default"], {
|
|
456
452
|
title: /*#__PURE__*/React__default["default"].createElement(Label__default["default"], null, searchButtonLabel),
|
|
457
453
|
size: "lg",
|
|
458
454
|
onClose: closeResourceModal
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@panneau/field-upload",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.79",
|
|
4
4
|
"description": "An Upload field",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"javascript"
|
|
@@ -82,5 +82,5 @@
|
|
|
82
82
|
"publishConfig": {
|
|
83
83
|
"access": "public"
|
|
84
84
|
},
|
|
85
|
-
"gitHead": "
|
|
85
|
+
"gitHead": "cbcafea046653fef8b48a8f877d9a8521cd4261e"
|
|
86
86
|
}
|