Apply the same locked username/ prefix to the New repo form
Matches the one-shot import form's field, for consistency between the two side-by-side "add a repo" actions on the dashboard.
1 files changed
+4 −1
M
cmd/gitfed-web/handlers_dashboard.go
+4 −1
cmd/gitfed-web/handlers_dashboard.go
@@ -39,7 +39,10 @@ var dashboardTpl = newTpl("dashboard", `
<summary class="gf-btn primary" style="margin:0;">+ {{t .Lang "dashboard.new_repo"}}</summary>
<form class="card" method="post" action="/repos" style="margin-top:0.75rem;">
<label>{{t .Lang "dashboard.repo_name"}}</label>
- <input name="name" required placeholder="{{.Username}}/my-project">
+ <div class="gf-input-group">
+ <span class="prefix">{{.Username}}/</span>
+ <input name="name" required placeholder="my-project" autocomplete="off">
+ </div>
<button type="submit">{{t .Lang "dashboard.create"}}</button>
</form>
</details>