@uppy/dashboard
Advanced tools
Comparing version 3.7.1 to 3.7.2
# @uppy/dashboard | ||
## 3.7.2 | ||
Released: 2024-02-19 | ||
Included in: Uppy v3.22.0 | ||
- @uppy/dashboard: autoopenfileeditor - rename "edit file" to "edit image" (evgenia karunus / #4925) | ||
- @uppy/dashboard: Uncouple native camera and video buttons from the `disableLocalFiles` option (jake mcallister / #4894) | ||
- @uppy/dashboard: fix `typeerror` when `file.remote` is nullish (antoine du hamel / #4825) | ||
## 3.7.1 | ||
@@ -4,0 +13,0 @@ |
@@ -219,16 +219,14 @@ let _Symbol$for; | ||
const myDeviceKey = 'myDevice'; | ||
if (!disableLocalFiles) { | ||
list.push({ | ||
key: myDeviceKey, | ||
elements: this.renderMyDeviceAcquirer() | ||
}); | ||
if (showNativePhotoCameraButton) list.push({ | ||
key: 'nativePhotoCameraButton', | ||
elements: this.renderPhotoCamera() | ||
}); | ||
if (showNativeVideoCameraButton) list.push({ | ||
key: 'nativePhotoCameraButton', | ||
elements: this.renderVideoCamera() | ||
}); | ||
} | ||
if (!disableLocalFiles) list.push({ | ||
key: myDeviceKey, | ||
elements: this.renderMyDeviceAcquirer() | ||
}); | ||
if (showNativePhotoCameraButton) list.push({ | ||
key: 'nativePhotoCameraButton', | ||
elements: this.renderPhotoCamera() | ||
}); | ||
if (showNativeVideoCameraButton) list.push({ | ||
key: 'nativePhotoCameraButton', | ||
elements: this.renderVideoCamera() | ||
}); | ||
list.push(...acquirers.map(acquirer => ({ | ||
@@ -235,0 +233,0 @@ key: acquirer.id, |
@@ -106,3 +106,3 @@ import { h } from 'preact'; | ||
} | ||
}, i18n('editFile'))), h("div", { | ||
}, i18n('editImage'))), h("div", { | ||
className: "uppy-Dashboard-FileCard-info" | ||
@@ -109,0 +109,0 @@ }, h(RenderMetaFields, { |
@@ -31,8 +31,7 @@ import { h, Fragment } from 'preact'; | ||
const renderAuthor = props => { | ||
var _props$file$remote; | ||
const { | ||
author | ||
} = props.file.meta; | ||
const { | ||
providerName | ||
} = props.file.remote; | ||
const providerName = (_props$file$remote = props.file.remote) == null ? void 0 : _props$file$remote.providerName; | ||
const dot = `\u00B7`; | ||
@@ -39,0 +38,0 @@ if (!author) { |
@@ -18,3 +18,3 @@ function _classPrivateFieldLooseBase(receiver, privateKey) { if (!Object.prototype.hasOwnProperty.call(receiver, privateKey)) { throw new TypeError("attempted to use private field on non-instance"); } return receiver; } | ||
const packageJson = { | ||
"version": "3.7.1" | ||
"version": "3.7.2" | ||
}; | ||
@@ -437,3 +437,3 @@ import locale from './locale.js'; | ||
// Every Plugin with .type acquirer can define handleRootPaste(event) | ||
plugin.handleRootPaste == null ? void 0 : plugin.handleRootPaste(event); | ||
plugin.handleRootPaste == null || plugin.handleRootPaste(event); | ||
} | ||
@@ -504,3 +504,3 @@ }); | ||
}); | ||
(_this$opts$onDragOver = (_this$opts = this.opts).onDragOver) == null ? void 0 : _this$opts$onDragOver.call(_this$opts, event); | ||
(_this$opts$onDragOver = (_this$opts = this.opts).onDragOver) == null || _this$opts$onDragOver.call(_this$opts, event); | ||
}; | ||
@@ -519,3 +519,3 @@ this.handleDragLeave = event => { | ||
}, 50); | ||
(_this$opts$onDragLeav = (_this$opts2 = this.opts).onDragLeave) == null ? void 0 : _this$opts$onDragLeav.call(_this$opts2, event); | ||
(_this$opts$onDragLeav = (_this$opts2 = this.opts).onDragLeave) == null || _this$opts$onDragLeav.call(_this$opts2, event); | ||
}; | ||
@@ -535,3 +535,3 @@ this.handleDrop = async event => { | ||
// Every Plugin with .type acquirer can define handleRootDrop(event) | ||
plugin.handleRootDrop == null ? void 0 : plugin.handleRootDrop(event); | ||
plugin.handleRootDrop == null || plugin.handleRootDrop(event); | ||
} | ||
@@ -562,3 +562,3 @@ }); | ||
} | ||
(_this$opts$onDrop = (_this$opts3 = this.opts).onDrop) == null ? void 0 : _this$opts$onDrop.call(_this$opts3, event); | ||
(_this$opts$onDrop = (_this$opts3 = this.opts).onDrop) == null || _this$opts$onDrop.call(_this$opts3, event); | ||
}; | ||
@@ -620,3 +620,3 @@ this.handleRequestThumbnail = file => { | ||
const thumbnailGenerator = this.uppy.getPlugin(`${this.id}:ThumbnailGenerator`); | ||
thumbnailGenerator == null ? void 0 : thumbnailGenerator.setOptions({ | ||
thumbnailGenerator == null || thumbnailGenerator.setOptions({ | ||
thumbnailWidth: LARGE_THUMBNAIL | ||
@@ -629,3 +629,3 @@ }); | ||
thumbnailGenerator.requestThumbnail(fileForThumbnail).then(() => { | ||
thumbnailGenerator == null ? void 0 : thumbnailGenerator.setOptions({ | ||
thumbnailGenerator == null || thumbnailGenerator.setOptions({ | ||
thumbnailWidth: this.opts.thumbnailWidth | ||
@@ -632,0 +632,0 @@ }); |
@@ -26,2 +26,3 @@ export default { | ||
editFile: 'Edit file', | ||
editImage: 'Edit image', | ||
// Shown in the panel header for the metadata editor. Rendered as “Editing image.png”. | ||
@@ -28,0 +29,0 @@ editing: 'Editing %{file}', |
@@ -36,3 +36,3 @@ import debounce from 'lodash/debounce.js'; | ||
const firstEl = overlayEl.querySelector(FOCUSABLE_ELEMENTS); | ||
firstEl == null ? void 0 : firstEl.focus({ | ||
firstEl == null || firstEl.focus({ | ||
preventScroll: true | ||
@@ -39,0 +39,0 @@ }); |
{ | ||
"name": "@uppy/dashboard", | ||
"description": "Universal UI plugin for Uppy.", | ||
"version": "3.7.1", | ||
"version": "3.7.2", | ||
"license": "MIT", | ||
@@ -26,8 +26,8 @@ "main": "lib/index.js", | ||
"dependencies": { | ||
"@transloadit/prettier-bytes": "0.0.7", | ||
"@transloadit/prettier-bytes": "^0.2.0", | ||
"@uppy/informer": "^3.0.4", | ||
"@uppy/provider-views": "^3.7.0", | ||
"@uppy/status-bar": "^3.2.5", | ||
"@uppy/thumbnail-generator": "^3.0.6", | ||
"@uppy/utils": "^5.6.0", | ||
"@uppy/provider-views": "^3.9.0", | ||
"@uppy/status-bar": "^3.2.6", | ||
"@uppy/thumbnail-generator": "^3.0.7", | ||
"@uppy/utils": "^5.7.1", | ||
"classnames": "^2.2.6", | ||
@@ -41,12 +41,12 @@ "is-shallow-equal": "^1.0.1", | ||
"devDependencies": { | ||
"@uppy/google-drive": "^3.3.0", | ||
"@uppy/status-bar": "^3.2.5", | ||
"@uppy/url": "^3.4.0", | ||
"@uppy/webcam": "^3.3.4", | ||
"@uppy/google-drive": "^3.4.0", | ||
"@uppy/status-bar": "^3.2.6", | ||
"@uppy/url": "^3.5.0", | ||
"@uppy/webcam": "^3.3.5", | ||
"resize-observer-polyfill": "^1.5.0", | ||
"vitest": "^0.34.5" | ||
"vitest": "^1.2.1" | ||
}, | ||
"peerDependencies": { | ||
"@uppy/core": "^3.7.1" | ||
"@uppy/core": "^3.9.0" | ||
} | ||
} |
@@ -244,7 +244,5 @@ import { h, Component, Fragment } from 'preact' | ||
if (!disableLocalFiles) { | ||
list.push({ key: myDeviceKey, elements: this.renderMyDeviceAcquirer() }) | ||
if (showNativePhotoCameraButton) list.push({ key: 'nativePhotoCameraButton', elements: this.renderPhotoCamera() }) | ||
if (showNativeVideoCameraButton) list.push({ key: 'nativePhotoCameraButton', elements: this.renderVideoCamera() }) | ||
} | ||
if (!disableLocalFiles) list.push({ key: myDeviceKey, elements: this.renderMyDeviceAcquirer() }) | ||
if (showNativePhotoCameraButton) list.push({ key: 'nativePhotoCameraButton', elements: this.renderPhotoCamera() }) | ||
if (showNativeVideoCameraButton) list.push({ key: 'nativePhotoCameraButton', elements: this.renderVideoCamera() }) | ||
list.push(...acquirers.map((acquirer) => ({ key: acquirer.id, elements: this.renderAcquirer(acquirer) }))) | ||
@@ -251,0 +249,0 @@ |
@@ -117,3 +117,6 @@ import { h } from 'preact' | ||
> | ||
{i18n('editFile')} | ||
{/* At the moment we only have one file editor - image editor. | ||
If we get editors for other file formats (e.g. pdfs), | ||
we can conditionally display i18n('editFile')/i18n('editImage'). */} | ||
{i18n('editImage')} | ||
</button> | ||
@@ -120,0 +123,0 @@ )} |
@@ -34,3 +34,3 @@ import { h, Fragment } from 'preact' | ||
const { author } = props.file.meta | ||
const { providerName } = props.file.remote | ||
const providerName = props.file.remote?.providerName | ||
const dot = `\u00B7` | ||
@@ -37,0 +37,0 @@ |
@@ -26,2 +26,3 @@ export default { | ||
editFile: 'Edit file', | ||
editImage: 'Edit image', | ||
// Shown in the panel header for the metadata editor. Rendered as “Editing image.png”. | ||
@@ -28,0 +29,0 @@ editing: 'Editing %{file}', |
@@ -17,2 +17,3 @@ /* eslint-disable */ | ||
| 'editFile' | ||
| 'editImage' | ||
| 'editing' | ||
@@ -19,0 +20,0 @@ | 'error' |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
686728
9792
+ Added@transloadit/prettier-bytes@0.2.0(transitive)
- Removed@transloadit/prettier-bytes@0.0.7(transitive)
Updated@uppy/provider-views@^3.9.0
Updated@uppy/status-bar@^3.2.6
Updated@uppy/utils@^5.7.1