Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Fix closing the editor modal in public folder view
Signed-off-by: Julien Veyssier <[email protected]>
Signed-off-by: nextcloud-command <[email protected]>
  • Loading branch information
Julien Veyssier authored and nextcloud-command committed Jan 17, 2022
commit b2853e907cddcf3ff3068239984a9657ccf39cfc
4 changes: 2 additions & 2 deletions js/editor-rich.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/editor-rich.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions js/text-files.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/text-files.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions js/text-public.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/text-public.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions js/text-text.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/text-text.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions js/text-viewer.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/text-viewer.js.map

Large diffs are not rendered by default.

26 changes: 17 additions & 9 deletions src/helpers/files.js
Original file line number Diff line number Diff line change
Expand Up @@ -101,15 +101,23 @@ const registerFileActionFallback = () => {
Vue.prototype.OCA = window.OCA
const Editor = imports[1].default
const vm = new Vue({
render: h => h(Editor, {
props: {
fileId: file ? file.id : null,
active: true,
shareToken: sharingToken,
relativePath: path,
mimeType: file.mimetype,
},
}),
render: function(h) { // eslint-disable-line
const self = this
return h(Editor, {
props: {
fileId: file ? file.id : null,
active: true,
shareToken: sharingToken,
relativePath: path,
mimeType: file.mimetype,
},
on: {
close: function() { // eslint-disable-line
self.$destroy()
},
},
})
},
})
vm.$mount(ViewerRoot)
})
Expand Down