0
0
mirror of https://github.com/go-gitea/gitea.git synced 2026-04-19 01:43:20 +02:00
wxiaoguang ae2b19849d
Use "Enable Gravatar" but not "Disable" (#36771)
* Fix #35685
* Fix #35627
* Fix #31112


Introduce "fipped" config value type, remove unused setting variables.
Make DisableGravatar=true by defult, remove useless config options from
the "Install" page.

The legacy config options are still kept because they are still the
fallback values for the system config options.

---------

Signed-off-by: wxiaoguang <wxiaoguang@gmail.com>
2026-02-27 16:39:26 +00:00

25 lines
1.0 KiB
Handlebars

<h4 class="ui top attached header">
{{ctx.Locale.Tr "admin.config.picture_config"}}
</h4>
<div class="ui attached table segment">
<dl class="admin-dl-horizontal">
{{$cfgOpt := .SystemConfig.Picture.DisableGravatar}}
<dt>{{ctx.Locale.Tr "admin.config.enable_gravatar"}}</dt>
<dd>
<div class="ui toggle checkbox" data-tooltip-content="{{ctx.Locale.Tr "admin.config.enable_gravatar"}}">
<input type="checkbox" data-config-dyn-key="{{$cfgOpt.DynKey}}" data-config-value-type="flipped" {{if not ($cfgOpt.Value ctx)}}checked{{end}}><label></label>
</div>
</dd>
<div class="divider"></div>
{{$cfgOpt = .SystemConfig.Picture.EnableFederatedAvatar}}
<dt>{{ctx.Locale.Tr "admin.config.enable_federated_avatar"}}</dt>
<dd>
<div class="ui toggle checkbox" data-tooltip-content="{{ctx.Locale.Tr "admin.config.enable_federated_avatar"}}">
<input type="checkbox" data-config-dyn-key="{{$cfgOpt.DynKey}}" data-config-value-type="boolean" {{if $cfgOpt.Value ctx}}checked{{end}}><label></label>
</div>
</dd>
</dl>
</div>