{{ template "header" . }}
{{ block "search_results" . }} {{/* On HTMX swaps, also re-render the sidebar tree out-of-band so it tracks the search and the expansion along the active folder. Only clicks on childless folder rows skip it (regen_tree false, see app.star). Every partial refreshes the form's hidden path input so later searches keep the clicked folder. Guarded so the full page render does not duplicate them inside the grid */}} {{ if and .Data.is_partial .Data.regen_tree }}
{{ template "folder_tree" $ }}
{{ end }} {{ if .Data.is_partial }} {{ end }} {{ range .Data.apps }}

{{ substr 0 30 .name }} {{ if .is_stage }} (Staging) {{ end }}

{{ if .is_dev }} {{/* Icons load from the static/icons.svg sprite (hashed, cached once), drawing in currentColor via use */}} Dev {{ end }} {{ if eq .auth "none" }} No auth {{ end }}
{{ if ne .git_sha "" }} Sha {{ substr 0 12 .git_sha }} {{ end }} {{ if and (ne .git_branch "") (ne .git_branch "main") }} Branch {{ .git_branch }} {{ end }} {{ if ne .version 0 }} Version {{ if .version_mismatch }} {{ .version }} {{ else }} {{ .version }} {{ end }} {{ end }} {{ if ne .spec "" }} Spec {{ .spec }} {{ end }} Updated {{ .update_age }}
Open
{{ if and (ne .source "-") (ne .source "") }} {{ $source_path := .source }} {{ if ne .star_base "" }} {{ $source_path = (printf "%s#%s" .source .star_base) }} {{ end }} {{ if eq .source_url "" }} {{ $source_path }} {{ else }} {{ $source_path }} {{ end }} {{ end }}
{{ end }} {{ if .Data.error }} {{ else if not .Data.apps }}

No apps found

{{ end }} {{ end }}
{{ template "footer" . }}