- {/* Root option */}
-
-
- {/* Folder tree */}
- {visible.map(({ node, depth }) => {
- const { folder, children } = node;
- const hasChildren = children.length > 0;
- const isExpanded = expanded.has(folder.id);
- const isSelected = folder.id === value;
-
- return (
-
- {/* Expand/collapse chevron */}
- {hasChildren ? (
-
- ) : (
-
-
-
- )}
-
- {/* Folder select row */}
-
-
- );
- })}
-
- {folders.length === 0 && (
-
{copy.noFolders}
- )}
+