Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/text.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAzul <azul@riseup.net>2020-06-19 10:21:51 +0300
committerAzul <azul@riseup.net>2020-08-11 16:47:39 +0300
commit97de93049b6ed67d056bc7426edbdbf485807b59 (patch)
treee35e77a576547cf47be0fee9c6e3208349322d1b /src
parentfd5942359b8e1372a6fa3220f415f643e6162a66 (diff)
update title when following links
Signed-off-by: Azul <azul@riseup.net>
Diffstat (limited to 'src')
-rw-r--r--src/marks/index.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/marks/index.js b/src/marks/index.js
index 4d19b66f4..0a719aaca 100644
--- a/src/marks/index.js
+++ b/src/marks/index.js
@@ -125,6 +125,12 @@ class Link extends TipTapLink {
if (query.dir && fragment.relPath) {
const filename = fragment.relPath.split('/').pop()
const path = `${query.dir}/${filename}`
+ document.title = `${filename} - ${OC.theme.title}`
+ if (window.location.pathname.match(/apps\/files\/$/)) {
+ // The files app still lacks a popState handler
+ // to allow for using the back button
+ // OC.Util.History.pushState('', htmlHref)
+ }
OCA.Viewer.open({ path })
} else {
window.open(htmlHref)