Add path to bookmarks, add logout button

This commit is contained in:
2025-10-10 00:12:14 +02:00
parent 06d04a1abc
commit 9a72c85019
18 changed files with 206 additions and 647 deletions

View File

@@ -55,6 +55,14 @@ export const node_is_shared = (node: FSNode): boolean => {
}
return false
}
export const path_is_shared = (path: FSNode[]): boolean => {
for (let i = 0; i < path.length; i++) {
if (node_is_shared(path[i])) {
return true
}
}
return false
}
export type FSNodeProperties = {
branding_enabled?: string,
@@ -364,7 +372,7 @@ export const fs_share_path = (path: FSNode[]): string => {
// Find the last node in the path that has a public ID
for (let i = path.length - 1; i >= 0; i--) {
if (path[i].id !== undefined && path[i].id !== "me") {
if (node_is_shared(path[i])) {
bucket_idx = i
break
}