2020-03-02 02:38:29 +01:00
{{ define "title"}}{{ t "page.new_api_key.title" }}{{ end }}
2024-01-27 09:25:55 +01:00
{{ define "page_header"}}
< section class = "page-header" aria-labelledby = "page-header-title" >
2024-01-25 07:22:18 +01:00
< h1 id = "page-header-title" > {{ t "page.new_api_key.title" }}< / h1 >
2020-03-02 02:38:29 +01:00
{{ template "settings_menu" dict "user" .user }}
2024-01-27 09:25:55 +01:00
< / section >
2024-01-25 07:22:18 +01:00
{{ end }}
2020-03-02 02:38:29 +01:00
2024-01-25 07:22:18 +01:00
{{ define "content"}}
2020-03-02 02:38:29 +01:00
< form action = "{{ route " saveAPIKey " } } " method = "post" autocomplete = "off" >
< input type = "hidden" name = "csrf" value = "{{ .csrf }}" >
{{ if .errorMessage }}
2024-02-05 07:20:05 +01:00
< div role = "alert" class = "alert alert-error" > {{ .errorMessage }}< / div >
2020-03-02 02:38:29 +01:00
{{ end }}
< label for = "form-description" > {{ t "form.api_key.label.description" }}< / label >
2021-01-05 05:29:12 +01:00
< input type = "text" name = "description" id = "form-description" value = "{{ .form.Description }}" spellcheck = "false" required autofocus >
2020-03-02 02:38:29 +01:00
< div class = "buttons" >
< button type = "submit" class = "button button-primary" data-label-loading = "{{ t " form . submit . saving " } } " > {{ t "action.save" }}< / button > {{ t "action.or" }} < a href = "{{ route " apiKeys " } } " > {{ t "action.cancel" }}< / a >
< / div >
< / form >
{{ end }}