From e57b4f1654d8d8ba8c3a7ba875d3c0ece764d5df Mon Sep 17 00:00:00 2001 From: Admin Date: Sun, 11 Jan 2026 00:50:58 +0000 Subject: [PATCH] feat(pages): Standalone templates without Gitea navbar MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Add base_head.tmpl with standalone HTML/CSS (no Gitea navbar) - Add base_footer.tmpl for clean HTML closing - Update simple.tmpl: clean minimal design with hero and stats - Update documentation.tmpl: dark header, sidebar navigation - Update product.tmpl: gradient hero, features grid, marketing style - Update portfolio.tmpl: dark theme, gallery grid with hover effects Pages now render as standalone landing pages without Gitea UI. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 --- templates/pages/base_footer.tmpl | 2 + templates/pages/base_head.tmpl | 170 +++++++++++++++++++++++++++++ templates/pages/documentation.tmpl | 133 +++++++++++++++++++++- templates/pages/portfolio.tmpl | 155 +++++++++++++++++++++++--- templates/pages/product.tmpl | 126 +++++++++++++++++++-- templates/pages/simple.tmpl | 9 +- 6 files changed, 560 insertions(+), 35 deletions(-) create mode 100644 templates/pages/base_footer.tmpl create mode 100644 templates/pages/base_head.tmpl diff --git a/templates/pages/base_footer.tmpl b/templates/pages/base_footer.tmpl new file mode 100644 index 0000000000..308b1d01b6 --- /dev/null +++ b/templates/pages/base_footer.tmpl @@ -0,0 +1,2 @@ + + diff --git a/templates/pages/base_head.tmpl b/templates/pages/base_head.tmpl new file mode 100644 index 0000000000..f83c348d14 --- /dev/null +++ b/templates/pages/base_head.tmpl @@ -0,0 +1,170 @@ + + + + + + {{if .Config.Hero.Title}}{{.Config.Hero.Title}}{{else}}{{.Repository.Name}}{{end}} - {{.Repository.Owner.Name}} + + + {{template "base/head_style" .}} + + + diff --git a/templates/pages/documentation.tmpl b/templates/pages/documentation.tmpl index c60fbf76cf..55d9aecd74 100644 --- a/templates/pages/documentation.tmpl +++ b/templates/pages/documentation.tmpl @@ -1,5 +1,118 @@ -{{template "base/head" .}} -
+{{template "pages/base_head" .}} + +
{{template "pages/header" .}}
@@ -21,6 +134,15 @@
{{end}} + {{else}} +
+

Documentation

+ +
{{end}} @@ -32,12 +154,11 @@ {{.ReadmeContent}}
{{else}} -

{{ctx.Locale.Tr "repo.no_desc"}}

+

{{.Repository.Name}}

+

{{if .Repository.Description}}{{.Repository.Description}}{{else}}Welcome to the documentation.{{end}}

{{end}}
- - {{template "pages/footer" .}} -{{template "base/footer" .}} +{{template "pages/base_footer" .}} diff --git a/templates/pages/portfolio.tmpl b/templates/pages/portfolio.tmpl index 87d1fb580d..49c44a3421 100644 --- a/templates/pages/portfolio.tmpl +++ b/templates/pages/portfolio.tmpl @@ -1,5 +1,131 @@ -{{template "base/head" .}} -
+{{template "pages/base_head" .}} + +
{{template "pages/header" .}}
@@ -20,7 +146,7 @@ {{end}} {{if .Config.Hero.CTASecondary.Text}} - + {{.Config.Hero.CTASecondary.Text}} {{end}} @@ -29,28 +155,31 @@ - {{if .Config.Gallery.Items}} - {{end}} {{if .ReadmeContent}} @@ -66,4 +195,4 @@ {{template "pages/footer" .}}
-{{template "base/footer" .}} +{{template "pages/base_footer" .}} diff --git a/templates/pages/product.tmpl b/templates/pages/product.tmpl index 66bb71aed8..49df0ce242 100644 --- a/templates/pages/product.tmpl +++ b/templates/pages/product.tmpl @@ -1,11 +1,121 @@ -{{template "base/head" .}} -
+{{template "pages/base_head" .}} + +
{{template "pages/header" .}}
-
{{if .Config.Branding.Logo}} @@ -16,12 +126,12 @@ {{end}}
{{if .Config.Hero.CTAPrimary.Text}} - + {{.Config.Hero.CTAPrimary.Text}} {{end}} {{if .Config.Hero.CTASecondary.Text}} - + {{.Config.Hero.CTASecondary.Text}} {{end}} @@ -38,11 +148,7 @@
{{if .Icon}}
- {{if StringUtils.HasPrefix .Icon "./"}} - {{.Title}} - {{else}} {{svg (printf "octicon-%s" .Icon) 32}} - {{end}}
{{end}}

{{.Title}}

@@ -89,4 +195,4 @@ {{template "pages/footer" .}}
-{{template "base/footer" .}} +{{template "pages/base_footer" .}} diff --git a/templates/pages/simple.tmpl b/templates/pages/simple.tmpl index c73c42d070..586fc21486 100644 --- a/templates/pages/simple.tmpl +++ b/templates/pages/simple.tmpl @@ -1,5 +1,5 @@ -{{template "base/head" .}} -
+{{template "pages/base_head" .}} +
{{template "pages/header" .}}
@@ -43,18 +43,15 @@
- {{svg "octicon-star"}} {{.NumStars}} {{ctx.Locale.Tr "repo.stars"}}
- {{svg "octicon-repo-forked"}} {{.NumForks}} {{ctx.Locale.Tr "repo.forks"}}
{{if .Repository.PrimaryLanguage}}
- {{.Repository.PrimaryLanguage.Language}} {{ctx.Locale.Tr "repo.language"}}
@@ -66,4 +63,4 @@ {{template "pages/footer" .}}
-{{template "base/footer" .}} +{{template "pages/base_footer" .}}