main 5041353

icons.templ RawHistoryFolder

1package systemviews
2
3templ Icon(name systemIcon) {
4	<svg class={ iconClass(name) } xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true" focusable="false">
5		if name == iconTrash {
6			<path d="M10 11v6"></path>
7			<path d="M14 11v6"></path>
8			<path d="M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6"></path>
9			<path d="M3 6h18"></path>
10			<path d="M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2"></path>
11		} else if name == iconX {
12			<path d="M18 6 6 18"></path>
13			<path d="m6 6 12 12"></path>
14		} else if name == iconSearch {
15			<path d="m21 21-4.34-4.34"></path>
16			<circle cx="11" cy="11" r="8"></circle>
17		} else if name == iconSave {
18			<path d="M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z"></path>
19			<path d="M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7"></path>
20			<path d="M7 3v4a1 1 0 0 0 1 1h7"></path>
21		} else if name == iconPlus {
22			<path d="M5 12h14"></path>
23			<path d="M12 5v14"></path>
24		} else if name == iconExternal {
25			<path d="M15 3h6v6"></path>
26			<path d="M10 14 21 3"></path>
27			<path d="M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6"></path>
28		} else if name == iconRotateCCW {
29			<path d="M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8"></path>
30			<path d="M3 3v5h5"></path>
31		} else if name == iconCheck {
32			<path d="M20 6 9 17l-5-5"></path>
33		} else if name == iconHistory {
34			<path d="M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8"></path>
35			<path d="M3 3v5h5"></path>
36			<path d="M12 7v5l4 2"></path>
37		} else if name == iconFolder {
38			<path d="M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z"></path>
39		} else if name == iconTag {
40			<path d="M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z"></path>
41			<circle cx="7.5" cy="7.5" r=".5" fill="currentColor"></circle>
42		} else if name == iconSettings {
43			<path d="M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915"></path>
44			<circle cx="12" cy="12" r="3"></circle>
45		} else if name == iconAlert {
46			<path d="m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3"></path>
47			<path d="M12 9v4"></path>
48			<path d="M12 17h.01"></path>
49		} else {
50			<circle cx="12" cy="12" r="10"></circle>
51			<path d="M9.09 9a3 3 0 1 1 5.83 1c0 2-3 2-3 4"></path>
52			<path d="M12 17h.01"></path>
53		}
54	</svg>
55}
56
57templ ButtonIconLabel(name systemIcon, label string) {
58	@Icon(name)
59	<span>{ label }</span>
60}
61
62templ IconOnly(name systemIcon, label string) {
63	@Icon(name)
64	<span class="sv-sr-only">{ label }</span>
65}

Keyboard shortcuts

Single-key shortcuts are on. ctrl k and esc work whatever this says.

ctrl k :
go to a section, branch, tag, file or repository
?
this list
j k
move the row cursor down / up
enter
open the row under the cursor; on Files, a directory opens or closes in place
↑ ↓ ← → home end
in the file tree (focus on a row): previous / next row, close / open a directory or go to its parent / first entry, first / last row. They never open a file
l h
on Files: open a directory or a file / close a directory or go up to its parent, then to the parent page. Elsewhere: into the side panel (on a merge request, its files) / back to the content; there j k move between its controls
g g G
first / last row
/
filter the list; on Files, find a file anywhere in the repository (esc clears, enter opens the best match)
b
switch branch or tag
g s g f g c g b g m g i g r g a
tabs: summary, files, commits, branches & tags, merge requests, issues, releases, actions (when available)
g h
home
w
wide mode: use the whole width of the screen, or not (remembered)
y
copy a permalink pinned to the commit
d u x
diff: split / unified / collapse or expand all
e E
diff: the whole file in view / every file, with the lines the hunks hide
n
merge request: next note in the diff
esc
close a dialog, leave a field

Branches 8

Tags 42

↑↓ moveenter openesc close