Skip to content
Merged
2 changes: 1 addition & 1 deletion templates/admin/auth/edit.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -433,7 +433,7 @@

<div class="field">
<button class="ui green button">{{.locale.Tr "admin.auths.update"}}</button>
<div class="ui red button delete-button" data-url="{{$.Link}}/delete" data-id="{{.Source.ID}}">{{.locale.Tr "admin.auths.delete"}}</div>
<button class="ui red button delete-button" data-url="{{$.Link}}/delete" data-id="{{.Source.ID}}">{{.locale.Tr "admin.auths.delete"}}</button>
</div>
</form>
</div>
Expand Down
8 changes: 3 additions & 5 deletions templates/admin/emails/list.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@
{{.locale.Tr "admin.emails.change_email_header"}}
</div>
<div class="content center">
<p>{{.locale.Tr "admin.emails.change_email_text"}}</p>
<p class="center">{{.locale.Tr "admin.emails.change_email_text"}}</p>

<form class="ui form" id="email-action-form" action="{{AppSubUrl}}/admin/emails/activate" method="post">
{{$.CsrfTokenHtml}}
Expand All @@ -93,11 +93,9 @@
<input type="hidden" id="form-primary" name="primary" value="" required>
<input type="hidden" id="form-activate" name="activate" value="" required>

<div class="center actions">
<div class="ui basic cancel inverted button">{{$.locale.Tr "settings.cancel"}}</div>
<button class="ui basic inverted yellow button">{{$.locale.Tr "modal.yes"}}</button>
<div class="center">
{{template "base/delete_modal_actions" .}}
</div>

</form>
</div>
</div>
Expand Down
18 changes: 8 additions & 10 deletions templates/admin/notice.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
<tr>
<td class="collapsing">
<div class="ui fitted checkbox" data-id="{{.ID}}">
<input type="checkbox"> <label></label>
<input type="checkbox">
</div>
</td>
<td>{{.ID}}</td>
Expand All @@ -39,13 +39,11 @@
<tr>
<th></th>
<th colspan="5">
<div class="ui right">
<form method="post" action="{{AppSubUrl}}/admin/notices/empty">
{{.CsrfTokenHtml}}
<button type="submit" class="ui red small button">{{.locale.Tr "admin.notices.delete_all"}}</button>
</form>
</div>
<div class="ui floating upward dropdown small button">
<form class="ui right" method="post" action="{{AppSubUrl}}/admin/notices/empty">
{{.CsrfTokenHtml}}
<button type="submit" class="ui red small button">{{.locale.Tr "admin.notices.delete_all"}}</button>
</form>
<div class="ui floating upward dropdown small button">{{/* TODO: Make this dropdown accessible */}}
<span class="text">{{.locale.Tr "admin.notices.operations"}}</span>
<div class="menu">
<div class="item select action" data-action="select-all">
Expand All @@ -59,9 +57,9 @@
</div>
</div>
</div>
<div class="ui small teal button" id="delete-selection" data-link="{{.Link}}/delete" data-redirect="{{.Link}}?page={{.Page.Paginater.Current}}">
<button class="ui small teal button" id="delete-selection" data-link="{{.Link}}/delete" data-redirect="{{.Link}}?page={{.Page.Paginater.Current}}">
{{.locale.Tr "admin.notices.delete_selected"}}
</div>
</button>
</th>
</tr>
</tfoot>
Expand Down
22 changes: 2 additions & 20 deletions templates/admin/repo/unadopted.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -43,16 +43,7 @@
<input type="hidden" name="action" value="adopt">
<input type="hidden" name="q" value="{{$.Keyword}}">
<input type="hidden" name="page" value="{{$.CurrentPage}}">
<div class="actions">
<div class="ui red basic inverted cancel button">
{{svg "octicon-trash" 16 "gt-mr-2"}}
{{$.locale.Tr "modal.no"}}
</div>
<button class="ui green basic inverted ok button">
{{svg "octicon-check" 16 "gt-mr-2"}}
{{$.locale.Tr "modal.yes"}}
</button>
</div>
{{template "base/delete_modal_actions" .}}
</form>
</div>
<button class="ui button submit tiny red delete show-modal" data-modal="#delete-unadopted-modal-{{$dirI}}"><span class="icon">{{svg "octicon-x"}}</span><span class="label">{{$.locale.Tr "repo.delete_preexisting_label"}}</span></button>
Expand All @@ -70,16 +61,7 @@
<input type="hidden" name="action" value="delete">
<input type="hidden" name="q" value="{{$.Keyword}}">
<input type="hidden" name="page" value="{{$.CurrentPage}}">
<div class="actions">
<div class="ui red basic inverted cancel button">
{{svg "octicon-trash" 16 "gt-mr-2"}}
{{$.locale.Tr "modal.no"}}
</div>
<button class="ui green basic inverted ok button">
{{svg "octicon-check" 16 "gt-mr-2"}}
{{$.locale.Tr "modal.yes"}}
</button>
</div>
{{template "base/delete_modal_actions" .}}
</form>
</div>
</div>
Expand Down
17 changes: 4 additions & 13 deletions templates/admin/user/edit.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@

<div class="field">
<button class="ui green button">{{.locale.Tr "admin.users.update_profile"}}</button>
<div class="ui red button show-modal" data-modal="#delete-user-modal">{{.locale.Tr "admin.users.delete_account"}}</div>
<button class="ui red button show-modal" data-modal="#delete-user-modal">{{.locale.Tr "admin.users.delete_account"}}</button>
</div>
</form>
</div>
Expand Down Expand Up @@ -189,7 +189,7 @@

<div class="field">
<button class="ui green button">{{$.locale.Tr "settings.update_avatar"}}</button>
<a class="ui red button delete-post" data-request-url="{{.Link}}/avatar/delete" data-done-url="{{.Link}}">{{$.locale.Tr "settings.delete_current_avatar"}}</a>
<a class="ui red button delete-post" data-request-url="{{.Link}}/avatar/delete" data-done-url="{{.Link}}">{{$.locale.Tr "settings.delete_current_avatar"}}</a>{{/* TODO: Convert links without href to buttons for a11y */}}
</div>
</form>
</div>
Expand All @@ -213,16 +213,7 @@
</div>
<p class="help">{{.locale.Tr "admin.users.purge_help"}}</p>
</div>
<div class="actions">
<div class="ui red basic inverted cancel button">
{{svg "octicon-x"}}
{{.locale.Tr "modal.no"}}
</div>
<button class="ui green basic inverted ok button">
{{svg "octicon-check"}}
{{.locale.Tr "modal.yes"}}
</button>
</div>
</form>
{{template "base/delete_modal_actions" .}}
</form>
</div>
{{template "base/footer" .}}
8 changes: 4 additions & 4 deletions templates/base/delete_modal_actions.tmpl
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<div class="actions">
<div class="ui red basic inverted cancel button">
<button type="button"{{/* To prevent accidental submission when clicking on no */}} class="ui red basic inverted cancel button">
{{svg "octicon-x"}}
{{.locale.Tr "modal.no"}}
</div>
<div class="ui green basic inverted ok button">
</button>
<button class="ui green basic inverted ok button">
{{svg "octicon-check"}}
{{.locale.Tr "modal.yes"}}
</div>
</button>
</div>
4 changes: 2 additions & 2 deletions templates/org/settings/delete.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@
<label for="org_name">{{.locale.Tr "org.org_name_holder"}}</label>
<input id="org_name" name="org_name" value="" autocomplete="off" autofocus required>
</div>
<div class="ui red button delete-button" data-type="form" data-form="#delete-form">
<button class="ui red button delete-button" data-type="form" data-form="#delete-form">
{{.locale.Tr "org.settings.confirm_delete_account"}}
</div>
</button>
</form>
</div>
</div>
Expand Down
2 changes: 1 addition & 1 deletion templates/org/settings/labels.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
</div>
<div class="right floated three wide column">
<div class="ui right">
<div class="ui green new-label button">{{.locale.Tr "repo.issues.new_label"}}</div>
<button class="ui green new-label button">{{.locale.Tr "repo.issues.new_label"}}</button>
</div>
</div>
</div>
Expand Down
5 changes: 1 addition & 4 deletions templates/package/settings.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -57,10 +57,7 @@
<form class="ui form" action="{{.Link}}" method="post">
{{.CsrfTokenHtml}}
<input type="hidden" name="action" value="delete">
<div class="text right actions">
<div class="ui cancel button">{{.locale.Tr "cancel"}}</div>
<button class="ui red button">{{.locale.Tr "ok"}}</button>
</div>
{{template "base/delete_modal_actions" .}}
</form>
</div>
</div>
Expand Down
11 changes: 1 addition & 10 deletions templates/projects/list.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -84,15 +84,6 @@
<div class="content">
<p>{{.locale.Tr "repo.projects.deletion_desc"}}</p>
</div>
<div class="actions">
<div class="ui red basic inverted cancel button">
<i class="remove icon"></i>
{{.locale.Tr "modal.no"}}
</div>
<div class="ui green basic inverted ok button">
<i class="checkmark icon"></i>
{{.locale.Tr "modal.yes"}}
</div>
</div>
{{template "base/delete_modal_actions" .}}
</div>
{{end}}
23 changes: 7 additions & 16 deletions templates/projects/view.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
</div>

<div class="text right actions">
<div class="ui cancel button">{{$.locale.Tr "settings.cancel"}}</div>
<button type="button" class="ui cancel button">{{$.locale.Tr "settings.cancel"}}</button>
<button data-url="{{$.Link}}" class="ui primary button" id="new_board_submit">{{$.locale.Tr "repo.projects.column.new_submit"}}</button>
</div>
</form>
Expand Down Expand Up @@ -127,7 +127,7 @@
</div>

<div class="text right actions">
<div class="ui cancel button">{{$.locale.Tr "settings.cancel"}}</div>
<button type="button" class="ui cancel button">{{$.locale.Tr "settings.cancel"}}</button>
<button data-url="{{$.Link}}/{{.ID}}" class="ui primary button">{{$.locale.Tr "repo.projects.column.edit"}}</button>
</div>
</form>
Expand All @@ -143,8 +143,8 @@
{{$.locale.Tr "repo.projects.column.set_default_desc"}}
</label>
</div>
<div class="text right actions">
<div class="ui cancel button">{{$.locale.Tr "settings.cancel"}}</div>
<div class="text right actions">{{/* TODO: Convert to base/delete_modal_actions.tmpl */}}
<button type="button" class="ui cancel button">{{$.locale.Tr "settings.cancel"}}</button>
<button class="ui primary button set-default-project-board" data-url="{{$.Link}}/{{.ID}}/default">{{$.locale.Tr "repo.projects.column.set_default"}}</button>
</div>
</div>
Expand All @@ -158,8 +158,8 @@
{{$.locale.Tr "repo.projects.column.deletion_desc"}}
</label>
</div>
<div class="text right actions">
<div class="ui cancel button">{{$.locale.Tr "settings.cancel"}}</div>
<div class="text right actions">{{/* TODO: convert to base/delete_modal_actions.tmpl */}}
<button type="button" class="ui cancel button">{{$.locale.Tr "settings.cancel"}}</button>
<button class="ui red button delete-project-board" data-url="{{$.Link}}/{{.ID}}">{{$.locale.Tr "repo.projects.column.delete"}}</button>
</div>
</div>
Expand Down Expand Up @@ -265,15 +265,6 @@
<div class="content">
<p>{{.locale.Tr "repo.projects.deletion_desc"}}</p>
</div>
<div class="actions">
<div class="ui red basic inverted cancel button">
<i class="remove icon"></i>
{{.locale.Tr "modal.no"}}
</div>
<div class="ui green basic inverted ok button">
<i class="checkmark icon"></i>
{{.locale.Tr "modal.yes"}}
</div>
</div>
{{template "base/delete_modal_actions" .}}
</div>
{{end}}
12 changes: 5 additions & 7 deletions templates/repo/activity.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,11 @@
<h2 class="ui header"><time data-format="date" datetime="{{.DateFrom}}">{{.DateFrom}}</time> - <time data-format="date" datetime="{{.DateUntil}}">{{.DateUntil}}</time>
<div class="ui right">
<!-- Period -->
<div class="ui floating dropdown jump filter">
<div class="ui basic compact button">
<span class="text">
{{.locale.Tr "repo.activity.period.filter_label"}} <strong>{{.PeriodText}}</strong>
{{svg "octicon-triangle-down" 14 "dropdown icon"}}
</span>
</div>
<div class="ui basic compact button floating dropdown jump filter">
<span class="text">
{{.locale.Tr "repo.activity.period.filter_label"}} <strong>{{.PeriodText}}</strong>
{{svg "octicon-triangle-down" 14 "dropdown icon"}}
</span>
<div class="menu">
<a class="{{if eq .Period "daily"}}active {{end}}item" href="{{$.RepoLink}}/activity/daily">{{.locale.Tr "repo.activity.period.daily"}}</a>
<a class="{{if eq .Period "halfweekly"}}active {{end}}item" href="{{$.RepoLink}}/activity/halfweekly">{{.locale.Tr "repo.activity.period.halfweekly"}}</a>
Expand Down
4 changes: 2 additions & 2 deletions templates/repo/branch/list.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -175,8 +175,8 @@
<input id="new_branch_name" name="new_branch_name" required>
</div>

<div class="text right actions">
<div class="ui cancel button">{{.locale.Tr "settings.cancel"}}</div>
<div class="text right actions">{{/* TODO: Convert to base/delete_modal_actions.tmpl */}}
<button type="button" class="ui cancel button">{{.locale.Tr "settings.cancel"}}</button>
<button class="ui green button">{{.locale.Tr "repo.branch.confirm_create_branch"}}</button>
</div>
</form>
Expand Down
4 changes: 2 additions & 2 deletions templates/repo/cite/cite_modal.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@
</div>
</div>
<div class="actions">
<div class="ui black deny button">
<button class="ui black deny button">
{{.locale.Tr "cancel"}}
</div>
</button>
</div>
</div>
4 changes: 2 additions & 2 deletions templates/repo/commit_page.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@
</div>

<div class="text right actions">
<div class="ui cancel button">{{.locale.Tr "settings.cancel"}}</div>
<button type="button" class="ui cancel button">{{.locale.Tr "settings.cancel"}}</button>
<button class="ui green button">{{.locale.Tr "repo.branch.confirm_create_branch"}}</button>
</div>
</form>
Expand All @@ -121,7 +121,7 @@
</div>

<div class="text right actions">
<div class="ui cancel button">{{.locale.Tr "settings.cancel"}}</div>
<button type="button" class="ui cancel button">{{.locale.Tr "settings.cancel"}}</button>
<button class="ui green button">{{.locale.Tr "repo.tag.confirm_create_tag"}}</button>
</div>
</form>
Expand Down
8 changes: 4 additions & 4 deletions templates/repo/diff/box.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -107,8 +107,8 @@
<div class="diff-file-header-actions gt-df gt-ac">
{{if $showFileViewToggle}}
<div class="ui compact icon buttons">
<span class="ui tiny basic button tooltip file-view-toggle" data-toggle-selector="#diff-source-{{$file.NameHash}}" data-content="{{$.locale.Tr "repo.file_view_source"}}" data-position="bottom center">{{svg "octicon-code"}}</span>
<span class="ui tiny basic button tooltip file-view-toggle active" data-toggle-selector="#diff-rendered-{{$file.NameHash}}" data-content="{{$.locale.Tr "repo.file_view_rendered"}}" data-position="bottom center">{{svg "octicon-file"}}</span>
<button class="ui tiny basic button tooltip file-view-toggle" data-toggle-selector="#diff-source-{{$file.NameHash}}" data-content="{{$.locale.Tr "repo.file_view_source"}}" data-position="bottom center">{{svg "octicon-code"}}</button>
<button class="ui tiny basic button tooltip file-view-toggle active" data-toggle-selector="#diff-rendered-{{$file.NameHash}}" data-content="{{$.locale.Tr "repo.file_view_rendered"}}" data-position="bottom center">{{svg "octicon-file"}}</button>
</div>
{{end}}
{{if $file.IsProtected}}
Expand Down Expand Up @@ -200,8 +200,8 @@
{{$.locale.Tr "loading"}}
</div>
<div class="text right edit buttons">
<div class="ui basic primary cancel button" tabindex="3">{{.locale.Tr "repo.issues.cancel"}}</div>
<div class="ui green save button" tabindex="2">{{.locale.Tr "repo.issues.save"}}</div>
<button type="button" class="ui basic primary cancel button" tabindex="3">{{.locale.Tr "repo.issues.cancel"}}</button>
<button class="ui green save button" tabindex="2">{{.locale.Tr "repo.issues.save"}}</button>
</div>
</div>
</div>
Expand Down
8 changes: 4 additions & 4 deletions templates/repo/diff/compare.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,10 @@
<div class="ui segment choose branch">
<a href="{{$.HeadRepo.Link}}/compare/{{PathEscapeSegments $.HeadBranch}}{{$.CompareSeparator}}{{if not $.PullRequestCtx.SameRepo}}{{PathEscape $.BaseName}}/{{PathEscape $.Repository.Name}}:{{end}}{{PathEscapeSegments $.BaseBranch}}" title="{{.locale.Tr "repo.pulls.switch_head_and_base"}}">{{svg "octicon-git-compare"}}</a>
<div class="ui floating filter dropdown" data-no-results="{{.locale.Tr "repo.pulls.no_results"}}">
<div class="ui basic small button">
<button class="ui basic small button">
<span class="text">{{if $.PageIsComparePull}}{{.locale.Tr "repo.pulls.compare_base"}}{{else}}{{.locale.Tr "repo.compare.compare_base"}}{{end}}: {{$BaseCompareName}}:{{$.BaseBranch}}</span>
{{svg "octicon-triangle-down" 14 "dropdown icon"}}
</div>
</button>
<div class="menu">
<div class="ui icon search input">
<i class="icon gt-df gt-ac gt-jc gt-m-0">{{svg "octicon-filter" 16}}</i>
Expand Down Expand Up @@ -112,10 +112,10 @@
</div>
<a href="{{.RepoLink}}/compare/{{PathEscapeSegments .BaseBranch}}{{.OtherCompareSeparator}}{{if not $.PullRequestCtx.SameRepo}}{{PathEscape $.HeadUser.Name}}/{{PathEscape $.HeadRepo.Name}}:{{end}}{{PathEscapeSegments $.HeadBranch}}" title="{{.locale.Tr "repo.pulls.switch_comparison_type"}}">{{.CompareSeparator}}</a>
<div class="ui floating filter dropdown">
<div class="ui basic small button">
<button class="ui basic small button">
<span class="text">{{if $.PageIsComparePull}}{{.locale.Tr "repo.pulls.compare_compare"}}{{else}}{{.locale.Tr "repo.compare.compare_head"}}{{end}}: {{$HeadCompareName}}:{{$.HeadBranch}}</span>
{{svg "octicon-triangle-down" 14 "dropdown icon"}}
</div>
</button>
<div class="menu">
<div class="ui icon search input">
<i class="icon gt-df gt-ac gt-jc gt-m-0">{{svg "octicon-filter" 16}}</i>
Expand Down
10 changes: 5 additions & 5 deletions templates/repo/editor/edit.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -64,15 +64,15 @@
<div class="center content">
<p>{{.locale.Tr "repo.editor.commit_empty_file_text"}}</p>
</div>
<div class="actions">
<div class="ui red basic cancel inverted button">
<div class="actions">{{/* TODO: Convert to base/delete_modal_actions.tmpl*/}}
<button type="button" class="ui red basic cancel inverted button">
<i class="remove icon"></i>
{{.locale.Tr "repo.editor.cancel"}}
</div>
<div class="ui green basic ok inverted button">
</button>
<button class="ui green basic ok inverted button">
<i class="save icon"></i>
{{.locale.Tr "repo.editor.commit_changes"}}
</div>
</button>
</div>
</div>

Expand Down
Loading