@import java.nio.file.Path @import scala.util.Random @import utils.StringUtils._ @import os._ @(context_path: String, title: String, portfolioPath: Path, rootNode: DirNode, isSlideshow: Boolean = false, modified: Boolean, environment: String) @layouts.html.index(context_path, title, portfolioPath, rootNode,isSlideshow, modified, environment) {
@for(node <- rootNode.subdirs) { @node.findOne(isFile = true, random = true) match { case Some(file) => {
@if(node.files.isEmpty) { @prettify(node.path.last.toString) @node.subdirs.size subdirs } else { @if(node.files.size > 36) { @prettify(node.path.last.toString) (@node.files.size) } else { @prettify(node.path.last.toString) } }
} case None => {
@prettify(node.path.last.toString) No files @node.subdirs.size
} } }
}