diff --git a/templates/repo/branch/list.tmpl b/templates/repo/branch/list.tmpl new file mode 100644 index 0000000..cd6afce --- /dev/null +++ b/templates/repo/branch/list.tmpl @@ -0,0 +1,81 @@ +{{template "base/head" .}} +
+ {{template "repo/header" .}} +
+ {{template "base/alert" .}} + {{template "repo/sub_menu" .}} +

+ {{.i18n.Tr "repo.default_branch"}} +

+ +
+ + + + + + +
{{.DefaultBranch}}
+
+ + {{if gt (len .Branches) 1}} +

+ {{.i18n.Tr "repo.branches"}} +

+
+ + + + + {{if and $.IsWriter (not $.IsMirror)}} + + {{end}} + + + + {{range $branch := .Branches}} + {{if ne .Name $.DefaultBranch}} + + + {{end}} + {{if and $.IsWriter (not $.IsMirror)}} + + {{end}} + + {{end}} + {{end}} + +
{{.i18n.Tr "repo.branch.name"}}{{.i18n.Tr "repo.branch.delete_head"}}
+ {{if .IsDeleted}} + {{.Name}} +

{{$.i18n.Tr "repo.branch.deleted_by" .DeletedBranch.DeletedBy.Name}} {{TimeSinceUnix .DeletedBranch.DeletedUnix $.i18n.Lang}}

+ {{else}} + {{.Name}} +

{{$.i18n.Tr "org.repo_updated"}} {{TimeSince .Commit.Committer.When $.i18n.Lang}}

+
+ {{if .IsProtected}} + + {{else if .IsDeleted}} + + {{else}} + + {{end}} +
+
+ {{end}} +
+
+ + +{{template "base/footer" .}} diff --git a/templates/repo/branch_dropdown.tmpl b/templates/repo/branch_dropdown.tmpl new file mode 100644 index 0000000..b7f4c91 --- /dev/null +++ b/templates/repo/branch_dropdown.tmpl @@ -0,0 +1,65 @@ +
+ +
diff --git a/templates/repo/commits.tmpl b/templates/repo/commits.tmpl new file mode 100644 index 0000000..32301a0 --- /dev/null +++ b/templates/repo/commits.tmpl @@ -0,0 +1,20 @@ +{{template "base/head" .}} +
+ {{template "repo/header" .}} +
+ {{template "repo/sub_menu" .}} + + {{template "repo/commits_table" .}} +
+
+{{template "base/footer" .}} diff --git a/templates/repo/home.tmpl b/templates/repo/home.tmpl new file mode 100644 index 0000000..91db56c --- /dev/null +++ b/templates/repo/home.tmpl @@ -0,0 +1,99 @@ +{{template "base/head" .}} +
+ {{template "repo/header" .}} +
+ {{template "base/alert" .}} +
+
+ {{if .Repository.DescriptionHTML}}{{.Repository.DescriptionHTML}}{{else if .IsRepositoryAdmin}}{{.i18n.Tr "repo.no_desc"}}{{end}} + {{.Repository.Website}} +
+ {{if .RepoSearchEnabled}} + + {{end}} +
+ {{template "repo/sub_menu" .}} + + {{if .IsViewFile}} + {{template "repo/view_file" .}} + {{else}} + {{template "repo/view_list" .}} + {{end}} +
+
+{{template "base/footer" .}} diff --git a/templates/repo/sub_menu.tmpl b/templates/repo/sub_menu.tmpl new file mode 100644 index 0000000..cd37f80 --- /dev/null +++ b/templates/repo/sub_menu.tmpl @@ -0,0 +1,14 @@ +