1
1
mirror of https://github.com/go-gitea/gitea synced 2024-11-17 15:44:25 +00:00
gitea/templates/repo/settings/lfs_pointers.tmpl
silverwind 8099238618
Change green buttons to primary color (#27099)
I think it's better if the primary actions have primary color instead of
green which fits better into the overall single-color UI design. This PR
currently replaces every green button with primary:

<img width="141" alt="Screenshot 2023-09-16 at 14 07 59"
src="https://github.com/go-gitea/gitea/assets/115237/843c1e50-4fb2-4ec6-84ba-0efb9472dcbe">
<img width="161" alt="Screenshot 2023-09-16 at 14 07 51"
src="https://github.com/go-gitea/gitea/assets/115237/9442195a-a3b2-4a42-b262-8377d6f5c0d1">

Modal actions now use uncolored/primary instead of previous green/red
colors. I also removed the box-shadow on all basic buttons:

<img width="259" alt="Screenshot 2023-09-16 at 14 16 39"
src="https://github.com/go-gitea/gitea/assets/115237/5beea529-127a-44b0-8d4c-afa7b034a490">
<img width="261" alt="Screenshot 2023-09-16 at 14 17 42"
src="https://github.com/go-gitea/gitea/assets/115237/4757f7b2-4d46-49bc-a797-38bb28437b88">

The change currently includes the "Merge PR" button, for which we might
want to make an exception to match the icon color there:

<img width="442" alt="Screenshot 2023-09-16 at 14 33 53"
src="https://github.com/go-gitea/gitea/assets/115237/993ac1a5-c94d-4895-b76c-0d872181a70b">
2023-09-18 22:05:31 +00:00

57 lines
2.4 KiB
Handlebars

{{template "repo/settings/layout_head" (dict "ctxData" . "pageClass" "repository settings lfs")}}
<div class="repo-setting-content">
<h4 class="ui top attached header">
{{.locale.Tr "repo.settings.lfs_pointers.found" .NumPointers .NumAssociated .NumNotAssociated .NumNoExist}}
{{if gt .NumAssociatable 0}}
<div class="ui right">
<form class="ui form" method="post" action="{{$.Link}}/associate">
{{.CsrfTokenHtml}}
{{range .Pointers}}
{{if .Associatable}}
<input type="hidden" name="oid" value="{{.Oid}} {{.Size}}">
{{end}}
{{end}}
<button class="ui primary button">{{$.locale.Tr "repo.settings.lfs_pointers.associateAccessible" $.NumAssociatable}}</button>
</form>
</div>
{{end}}
</h4>
<div class="ui attached segment">
<table id="lfs-files-table" class="ui fixed single line table">
<thead>
<tr>
<th class="three wide">{{.locale.Tr "repo.settings.lfs_pointers.sha"}}</th>
<th class="four wide">{{.locale.Tr "repo.settings.lfs_pointers.oid"}}</th>
<th class="two wide">{{.locale.Tr "repo.settings.lfs_pointers.inRepo"}}</th>
<th class="two wide">{{.locale.Tr "repo.settings.lfs_pointers.exists"}}</th>
<th class="two wide" data-tooltip-content="{{.locale.Tr "repo.settings.lfs_pointers.accessible"}}">{{.locale.Tr "repo.settings.lfs_pointers.accessible"}}</th>
<th class="three wide"></th>
</tr>
</thead>
<tbody>
{{range .Pointers}}
<tr>
<td>
<a href="{{$.RepoLink}}/raw/blob/{{.SHA}}" rel="nofollow" target="_blank" title="{{.SHA}}" class="ui button gt-mono">
{{ShortSha .SHA}}
</a>
</td>
<td>
<a {{if and .Exists .InRepo}}href="{{$.LFSFilesLink}}/show/{{.Oid}}" rel="nofollow" target="_blank"{{end}} title="{{.Oid}}" class="ui brown button gt-mono">
{{ShortSha .Oid}}
</a>
</td>
<td>{{if .InRepo}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}</td>
<td>{{if .Exists}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}</td>
<td>{{if .Accessible}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}</td>
<td class="gt-text-right">
<a class="ui primary button" href="{{$.LFSFilesLink}}/find?oid={{.Oid}}&size={{.Size}}&sha={{.SHA}}">{{$.locale.Tr "repo.settings.lfs_findcommits"}}</a>
</td>
</tr>
{{end}}
</tbody>
</table>
</div>
</div>
{{template "repo/settings/layout_footer" .}}