aboutsummaryrefslogtreecommitdiffstats
path: root/templates/repo/diff/whitespace_dropdown.tmpl
blob: 5a5b8c3dbd30aacec3c37d3eac4e7a58bf1e1215 (plain)
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
<div class="ui dropdown tiny basic button" data-tooltip-content="{{.locale.Tr "repo.diff.whitespace_button"}}">
	{{svg "gitea-whitespace"}}
	<div class="menu">
		<a class="item" href="?style={{if .IsSplitStyle}}split{{else}}unified{{end}}&whitespace=show-all">
			<label class="gt-pointer-events-none">
				<input class="gt-mr-3 gt-pointer-events-none" type="radio"{{if eq .WhitespaceBehavior "show-all"}} checked{{end}}>
				{{.locale.Tr "repo.diff.whitespace_show_everything"}}
			</label>
		</a>
		<a class="item" href="?style={{if .IsSplitStyle}}split{{else}}unified{{end}}&whitespace=ignore-all">
			<label class="gt-pointer-events-none">
				<input class="gt-mr-3 gt-pointer-events-none" type="radio"{{if eq .WhitespaceBehavior "ignore-all"}} checked{{end}}>
				{{.locale.Tr "repo.diff.whitespace_ignore_all_whitespace"}}
			</label>
		</a>
		<a class="item" href="?style={{if .IsSplitStyle}}split{{else}}unified{{end}}&whitespace=ignore-change">
			<label class="gt-pointer-events-none">
				<input class="gt-mr-3 gt-pointer-events-none" type="radio"{{if eq .WhitespaceBehavior "ignore-change"}} checked{{end}}>
				{{.locale.Tr "repo.diff.whitespace_ignore_amount_changes"}}
			</label>
		</a>
		<a class="item" href="?style={{if .IsSplitStyle}}split{{else}}unified{{end}}&whitespace=ignore-eol">
			<label class="gt-pointer-events-none">
				<input class="gt-mr-3 gt-pointer-events-none" type="radio"{{if eq .WhitespaceBehavior "ignore-eol"}} checked{{end}}>
				{{.locale.Tr "repo.diff.whitespace_ignore_at_eol"}}
			</label>
		</a>
	</div>
</div>
<a class="ui tiny basic button" href="?style={{if .IsSplitStyle}}unified{{else}}split{{end}}&whitespace={{$.WhitespaceBehavior}}" data-tooltip-content="{{if .IsSplitStyle}}{{.locale.Tr "repo.diff.show_unified_view"}}{{else}}{{.locale.Tr "repo.diff.show_split_view"}}{{end}}">{{if .IsSplitStyle}}{{svg "gitea-join"}}{{else}}{{svg "gitea-split"}}{{end}}</a>