Use textarea as we expect lots of input

This commit is contained in:
erik 2024-03-19 13:52:00 +01:00
parent 09cac163e0
commit 4c1d12b2e4

View file

@ -63,30 +63,26 @@
</form> </form>
</div> </div>
{{if FederationEnabled}} {{if FederationEnabled}}
<h4 class="ui top attached header"> <h4 class="ui top attached header">
{{ctx.Locale.Tr "repo.settings.federation_settings"}} {{ctx.Locale.Tr "repo.settings.federation_settings"}}
</h4> </h4>
<div class="ui attached segment"> <div class="ui attached segment">
<form class="ui form" method="post"> <form class="ui form" method="post">
{{.CsrfTokenHtml}} {{.CsrfTokenHtml}}
<input type="hidden" name="action" value="federation"> <input type="hidden" name="action" value="federation">
<!-- TODO: implement Err_FederationRepos somewhere --> <!-- TODO: implement Err_FederationRepos somewhere -->
<div class="field {{if .Err_FederationRepos}}error{{end}}"> <div class="field {{if .Err_FederationRepos}}error{{end}}">
<label for="federation_repos">{{ctx.Locale.Tr "repo.settings.federation_labelname_repo"}}</label> <label for="federation_repos">{{ctx.Locale.Tr "repo.settings.federation_labelname_repo"}}</label>
<input id="federation_repos" name="federation_repos" value="{{.Repository.FederationRepos}}" data-repo-name="{{.Repository.FederationRepos}}"> <textarea id="repo_list" name="repo_list" rows="2" placeholder="{{ctx.Locale.Tr "repo.settings.federation_repo_list_empty"}}"></textarea>
</div> </div>
<div class="field"> <div class="field">
<button class="ui primary button">{{ctx.Locale.Tr "repo.settings.update_settings"}}</button> <button class="ui primary button">{{ctx.Locale.Tr "repo.settings.update_settings"}}</button>
</div> </div>
<div class="field {{if .Err_FederationRepos}}error{{end}}"> </form>
<label for="description">{{ctx.Locale.Tr "repo.settings.federation_federated_repo_list"}}</label> </div>
<textarea id="description" name="description" rows="2" placeholder="{{ctx.Locale.Tr "repo.settings.federation_repo_list_empty"}}" maxlength="255">{{.Repository.FederationRepos}}</textarea> {{end}}
</div>
</form>
</div>
{{end}}
{{/* These variables exist to make the logic in the Settings window easier to comprehend and are not used later on. */}} {{/* These variables exist to make the logic in the Settings window easier to comprehend and are not used later on. */}}