aboutsummaryrefslogtreecommitdiff
path: root/forged/templates/group.tmpl
blob: 3338f9b0c1b19ee53b60d4e5df86131b5c9a3be2 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82

{{/*
	SPDX-License-Identifier: AGPL-3.0-only
	SPDX-FileCopyrightText: Copyright (c) 2025 Runxi Yu <https://runxiyu.org>
*/}}
{{- define "group" -}}
{{- $group_path := .group_path -}}
<!DOCTYPE html>
<html lang="en">
	<head>
		{{- template "head_common" . -}}
		<title>{{- range $i, $s := .group_path -}}{{- $s -}}{{- if ne $i (len $group_path) -}}/{{- end -}}{{- end }} &ndash; {{ .global.forge_title -}}</title>
	</head>
	<body class="group">
		{{- template "header" . -}}
		<main>
			<div class="padding-wrapper">
				{{- if .description -}}
				<p>{{- .description -}}</p>
				{{- end -}}
				{{- template "group_view" . -}}
			</div>
			{{- if .direct_access -}}
				<div class="padding-wrapper">
					<form method="POST" enctype="application/x-www-form-urlencoded">
						<table>
							<thead>
								<tr>
									<th class="title-row" colspan="2">
										Create repo
									</th>
								</tr>
							</thead>
							<tbody>
								<tr>
									<th scope="row">Name</th>
									<td class="tdinput">
										<input id="repo-name-input" name="repo_name" type="text" />
									</td>
								</tr>
								<tr>
									<th scope="row">Description</th>
									<td class="tdinput">
										<input id="repo-desc-input" name="repo_desc" type="text" />
									</td>
								</tr>
								<tr>
									<th scope="row">Contrib</th>
									<td class="tdinput">
										<select id="repo-contrib-input" name="repo_contrib">
											<option value="public">Public</option>
											<option value="ssh_pubkey">SSH public key</option>
											<option value="federated">Federated service</option>
											<option value="registered_user">Registered user</option>
											<option value="closed">Closed</option>
										</select>
									</td>
								</tr>
							</tbody>
							<tfoot>
								<tr>
									<td class="th-like" colspan="2">
										<div class="flex-justify">
											<div class="left">
											</div>
											<div class="right">
												<input class="btn-primary" type="submit" value="Create" />
											</div>
										</div>
									</td>
								</tr>
							</tfoot>
						</table>
					</form>
				</div>
			{{- end -}}
		</main>
		<footer>
			{{- template "footer" . -}}
		</footer>
	</body>
</html>
{{- end -}}