Use canonical paths for editor and fix route transitions

This commit is contained in:
LeoVasanko committed 2026-05-07 02:18:55 +00:00
1 parent 6d7f44bd88
commit bf8a049b92
6 files changed
+61 -32

No files matched your search

+4 -1
View File
@@ -34,7 +34,10 @@ const store = useMainStore()
const MAX_SIZE = 1024 * 1024 // 1 MiB
const filePath = computed(() => decodeURIComponent(route.path.slice(6))) // strip /edit/
const filePath = computed(() => {
const raw = decodeURIComponent(route.path).split('//')[0] ?? ''
return raw.replace(/^\//, '').replace(/\/$/, '')
})
const filename = computed(() => filePath.value.split('/').pop() || '')
const filesUrl = computed(() => {