|
@@ -61,13 +61,13 @@ module.exports = class Dashboard extends Plugin {
|
|
copyLinkToClipboardFallback: 'Copy the URL below',
|
|
copyLinkToClipboardFallback: 'Copy the URL below',
|
|
copyLink: 'Copy link',
|
|
copyLink: 'Copy link',
|
|
fileSource: 'File source: %{name}',
|
|
fileSource: 'File source: %{name}',
|
|
- done: 'Done',
|
|
|
|
back: 'Back',
|
|
back: 'Back',
|
|
addMore: 'Add more',
|
|
addMore: 'Add more',
|
|
removeFile: 'Remove file',
|
|
removeFile: 'Remove file',
|
|
editFile: 'Edit file',
|
|
editFile: 'Edit file',
|
|
editing: 'Editing %{file}',
|
|
editing: 'Editing %{file}',
|
|
finishEditingFile: 'Finish editing file',
|
|
finishEditingFile: 'Finish editing file',
|
|
|
|
+ save: 'Save',
|
|
saveChanges: 'Save changes',
|
|
saveChanges: 'Save changes',
|
|
cancel: 'Cancel',
|
|
cancel: 'Cancel',
|
|
myDevice: 'My Device',
|
|
myDevice: 'My Device',
|
|
@@ -282,6 +282,17 @@ module.exports = class Dashboard extends Plugin {
|
|
})
|
|
})
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ saveFileEditor = () => {
|
|
|
|
+ const { targets } = this.getPluginState()
|
|
|
|
+ const editors = this._getEditors(targets)
|
|
|
|
+
|
|
|
|
+ editors.forEach((editor) => {
|
|
|
|
+ this.uppy.getPlugin(editor.id).save()
|
|
|
|
+ })
|
|
|
|
+
|
|
|
|
+ this.hideAllPanels()
|
|
|
|
+ }
|
|
|
|
+
|
|
openModal = () => {
|
|
openModal = () => {
|
|
const { promise, resolve } = createPromise()
|
|
const { promise, resolve } = createPromise()
|
|
// save scroll position
|
|
// save scroll position
|
|
@@ -959,6 +970,7 @@ module.exports = class Dashboard extends Plugin {
|
|
direction: this.opts.direction,
|
|
direction: this.opts.direction,
|
|
activePickerPanel: pluginState.activePickerPanel,
|
|
activePickerPanel: pluginState.activePickerPanel,
|
|
showFileEditor: pluginState.showFileEditor,
|
|
showFileEditor: pluginState.showFileEditor,
|
|
|
|
+ saveFileEditor: this.saveFileEditor,
|
|
disableAllFocusableElements: this.disableAllFocusableElements,
|
|
disableAllFocusableElements: this.disableAllFocusableElements,
|
|
animateOpenClose: this.opts.animateOpenClose,
|
|
animateOpenClose: this.opts.animateOpenClose,
|
|
isClosing: pluginState.isClosing,
|
|
isClosing: pluginState.isClosing,
|