mirror of
https://github.com/Sped0n/bridget.git
synced 2026-04-14 10:09:31 -07:00
This commit adds a new layout template called baseof.html. This template is used as the base layout for all other templates in the project. It includes the basic HTML structure, meta tags, and a placeholder for the main content. The purpose of this change is to provide a consistent and reusable base layout for all pages in the project, reducing code duplication and improving maintainability. --- feat(layouts): add single.html layout template This commit adds a new layout template called single.html. This template is used for rendering individual content pages. It includes a block for the main content and some additional logic for handling the current menu item and generating image JSON. The purpose of this change is to provide a specific layout for individual content pages, allowing for customization and flexibility in their presentation. --- refactor(layouts): remove index.html layout template and related partials This commit removes the index.html layout template and its associated partials (footer.html, head.html, link.html, meta.html, seo.html, mobile_wrapper.html, and nav.html). The index.html layout template was no longer needed as the project has transitioned to using the baseof.html and single.html templates for rendering pages. The associated partials were also no longer used and can be safely removed. The purpose of this change is to clean up unused code and reduce clutter in the project.
15 lines
501 B
HTML
15 lines
501 B
HTML
{{- define "main" -}}
|
|
{{- $params := .Scratch.Get "params" -}}
|
|
{{- $currentPage := . -}}
|
|
{{- with partial "function/currentMenuItem.html" . -}}
|
|
{{- partial "resources/imageJSON.html" (dict "Path" .Name "Page" $currentPage) -}}
|
|
<script>document.getElementById("main").setAttribute("currentMenuItemIndex", "{{- (sub .ID 1) -}}")</script>
|
|
{{- end -}}
|
|
<div class="container">
|
|
{{- partial "nav.html" . -}}
|
|
</div>
|
|
<article class="info">
|
|
{{ .Content }}
|
|
</article>
|
|
{{- end -}}
|