| 20 | ) |
| 21 | |
| 22 | func RenderFileTree( |
| 23 | tree filetree.IFileTree, |
| 24 | submoduleConfigs []*models.SubmoduleConfig, |
| 25 | showFileIcons bool, |
| 26 | showNumstat bool, |
| 27 | customIconsConfig *config.CustomIconsConfig, |
| 28 | showRootItem bool, |
| 29 | ) []string { |
| 30 | collapsedPaths := tree.CollapsedPaths() |
| 31 | return renderAux(tree.GetRoot().Raw(), collapsedPaths, -1, -1, func(node *filetree.Node[models.File], treeDepth int, visualDepth int, isCollapsed bool) string { |
| 32 | fileNode := filetree.NewFileNode(node) |
| 33 | |
| 34 | return getFileLine(isCollapsed, fileNode.GetHasUnstagedChanges(), fileNode.GetHasStagedChanges(), treeDepth, visualDepth, showNumstat, showFileIcons, submoduleConfigs, node, customIconsConfig, showRootItem) |
| 35 | }) |
| 36 | } |
| 37 | |
| 38 | func RenderCommitFileTree( |
| 39 | tree *filetree.CommitFileTreeViewModel, |