refactor: centralize documents route configuration into new useDocumentsShell hook and export related types.

This commit is contained in:
2025-11-24 23:55:37 +01:00
parent 70e7bda87e
commit 9ef63a87cb
5 changed files with 88 additions and 92 deletions
@@ -99,7 +99,7 @@ const splitLabelSegments = (input: unknown): string[] => {
const buildFolderTreeOptions = (tree?: FolderTreeNode[] | null): SelectionAssignmentMenuItem[] => {
const entries: SelectionAssignmentMenuItem[] = [];
const traverse = (nodes: FolderTreeNode[] | undefined | null, parentSegments: string[]) => {
const traverse = (nodes: FolderTreeNode[] | null, parentSegments: string[]) => {
if (!Array.isArray(nodes) || nodes.length === 0) {
return;
}