Skip to content
Open
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
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,11 @@ function getFullPath() {
if (!currentItem.value) return ''
const basePath = ctx.basePath?.value
const itemPath = currentItem.value.path
return basePath ? `${basePath}/${itemPath}`.replace(/\/+/g, '/') : itemPath
if (!basePath) return itemPath
const fullPath = `${basePath}/${itemPath}`
return navigator.userAgent.includes('Windows')
? fullPath.replace(/[\\/]+/g, '\\')
: fullPath.replace(/[\\/]+/g, '/')
}

function handleCopyPath() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,11 @@ const isZip = computed(() => fileExtension.value === 'zip')

function getFullPath() {
const basePath = ctx.basePath?.value
return basePath ? `${basePath}/${props.path}`.replace(/\/+/g, '/') : props.path
if (!basePath) return props.path
const fullPath = `${basePath}/${props.path}`
return navigator.userAgent.includes('Windows')
? fullPath.replace(/[\\/]+/g, '\\')
: fullPath.replace(/[\\/]+/g, '/')
}

const menuOptions = computed(() => {
Expand Down