diff options
author | Johannes Zellner <johannes@cloudron.io> | 2020-01-05 19:27:30 +0100 |
---|---|---|
committer | Johannes Zellner <johannes@cloudron.io> | 2020-01-05 19:27:30 +0100 |
commit | f97b51a9151d0d886e2a4703c91494de55e6d5ef (patch) | |
tree | 534d7e50e1408b92a7b9319d5e94f2d1540e28fd /frontend/js | |
parent | 383f72f7f5459d85042c6a7e8d1f471052cc01e6 (diff) | |
download | Surfer-f97b51a9151d0d886e2a4703c91494de55e6d5ef.tar.gz Surfer-f97b51a9151d0d886e2a4703c91494de55e6d5ef.tar.zst Surfer-f97b51a9151d0d886e2a4703c91494de55e6d5ef.zip |
Show preview drawer instead of directly opening files in a new tab
Diffstat (limited to 'frontend/js')
-rw-r--r-- | frontend/js/app.js | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/frontend/js/app.js b/frontend/js/app.js index d99a91e..9ce073e 100644 --- a/frontend/js/app.js +++ b/frontend/js/app.js | |||
@@ -146,7 +146,11 @@ function open(row, column, event) { | |||
146 | return; | 146 | return; |
147 | } | 147 | } |
148 | 148 | ||
149 | window.open(encode(path)); | 149 | app.activeEntry = row; |
150 | app.activeEntry.fullPath = encode(sanitize(app.path + '/' + row.filePath)); | ||
151 | app.previewDrawerVisible = true | ||
152 | |||
153 | // window.open(encode(path)); | ||
150 | } | 154 | } |
151 | 155 | ||
152 | function uploadFiles(files) { | 156 | function uploadFiles(files) { |
@@ -280,6 +284,8 @@ var app = new Vue({ | |||
280 | password: '', | 284 | password: '', |
281 | busy: false | 285 | busy: false |
282 | }, | 286 | }, |
287 | previewDrawerVisible: false, | ||
288 | activeEntry: {}, | ||
283 | entries: [], | 289 | entries: [], |
284 | accessTokens: [], | 290 | accessTokens: [], |
285 | accessTokensDialogVisible: false | 291 | accessTokensDialogVisible: false |