Skip to content

Commit

Permalink
style(root.html): improve readability and maintainability of template
Browse files Browse the repository at this point in the history
- Removed excess whitespace to enhance code readability.
- Added TODO comment for future UI improvements.
- Used hyphens to trim spaces in template loops for consistent output.
- Ensured consistent use of template delimiters for better formatting.
  • Loading branch information
infuzu-yidisprei committed Oct 3, 2024
1 parent 1a283de commit 00a637b
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions internal/templates/root.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,15 @@ <h1 class="font-semibold text-xl">Go Advanced Admin</h1>
</div>

<div class="navbar-end text-sm whitespace-pre">
{{ $first := true}}
{{ range .navBarItems }}
{{ if not $first }}
{{/* TODO make this look good*/}}
{{- $first := true }}
{{- range .navBarItems -}}
{{- if not $first -}}
<a> / </a>
{{ end }}
{{ safeHTML .HTML }}
{{ $first = false }}
{{ end }}
{{- end -}}
{{- safeHTML .HTML -}}
{{- $first = false -}}
{{- end -}}

<!-- theme swap -->
<label class="swap swap-rotate pl-2">
Expand Down

0 comments on commit 00a637b

Please sign in to comment.