2018-05-15 19:07:32 +09:00
|
|
|
<h4 class="ui top attached header">
|
|
|
|
{{.i18n.Tr "settings.manage_account_links"}}
|
2022-05-29 09:03:17 +09:00
|
|
|
{{if .OrderedOAuth2Names}}
|
|
|
|
<div class="ui right">
|
|
|
|
<div class="ui dropdown">
|
2022-05-29 17:19:56 +09:00
|
|
|
<div class="ui primary tiny button">{{.i18n.Tr "settings.link_account"}}</div>
|
2022-05-29 09:03:17 +09:00
|
|
|
<div class="menu">
|
|
|
|
{{range $key := .OrderedOAuth2Names}}
|
|
|
|
{{$provider := index $.OAuth2Providers $key}}
|
|
|
|
<a class="item" href="{{AppSubUrl}}/user/oauth2/{{$key}}">
|
2022-05-29 17:19:56 +09:00
|
|
|
<img width="20" height="20" src="{{AppSubUrl}}{{$provider.Image}}" alt="{{$provider.DisplayName}}">
|
|
|
|
{{$provider.DisplayName}}
|
2022-05-29 09:03:17 +09:00
|
|
|
</a>
|
|
|
|
{{end}}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
{{end}}
|
2018-05-15 19:07:32 +09:00
|
|
|
</h4>
|
2022-05-29 17:19:56 +09:00
|
|
|
|
2018-05-15 19:07:32 +09:00
|
|
|
<div class="ui attached segment">
|
|
|
|
<div class="ui key list">
|
|
|
|
<div class="item">
|
|
|
|
{{.i18n.Tr "settings.manage_account_links_desc"}}
|
|
|
|
</div>
|
|
|
|
{{if .AccountLinks}}
|
2022-05-29 17:19:56 +09:00
|
|
|
{{range $loginSource, $provider := .AccountLinks}}
|
|
|
|
<div class="item">
|
|
|
|
<div class="right floated content">
|
|
|
|
<button class="ui red tiny button delete-button" data-modal-id="delete-account-link" data-url="{{AppSubUrl}}/user/settings/security/account_link" data-id="{{$loginSource.ID}}">
|
|
|
|
{{$.i18n.Tr "settings.delete_key"}}
|
|
|
|
</button>
|
|
|
|
</div>
|
2018-05-15 19:07:32 +09:00
|
|
|
<div class="content">
|
|
|
|
<strong>{{$provider}}</strong>
|
2021-07-24 19:16:34 +09:00
|
|
|
{{if $loginSource.IsActive}}<span class="text red">{{$.i18n.Tr "settings.active"}}</span>{{end}}
|
2018-05-15 19:07:32 +09:00
|
|
|
</div>
|
2022-05-29 17:19:56 +09:00
|
|
|
</div>
|
|
|
|
{{end}}
|
2018-05-15 19:07:32 +09:00
|
|
|
{{end}}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="ui small basic delete modal" id="delete-account-link">
|
|
|
|
<div class="ui icon header">
|
2021-03-22 13:04:19 +09:00
|
|
|
{{svg "octicon-trash"}}
|
2018-05-15 19:07:32 +09:00
|
|
|
{{.i18n.Tr "settings.remove_account_link"}}
|
|
|
|
</div>
|
|
|
|
<div class="content">
|
|
|
|
<p>{{.i18n.Tr "settings.remove_account_link_desc"}}</p>
|
|
|
|
</div>
|
|
|
|
{{template "base/delete_modal_actions" .}}
|
|
|
|
</div>
|