{{template "repo/header" .}}

{{if .PageIsEditRelease}} {{ctx.Locale.Tr "repo.release.edit_release"}}
{{ctx.Locale.Tr "repo.release.edit_subheader"}}
{{else}} {{ctx.Locale.Tr "repo.release.new_release"}}
{{ctx.Locale.Tr "repo.release.new_subheader"}}
{{end}}

{{template "base/alert" .}}
{{.CsrfTokenHtml}}
{{if .PageIsEditRelease}} {{.tag_name}}@{{.tag_target}} {{else}}
@
{{ctx.Locale.Tr "repo.release.tag_helper"}}
{{end}}
{{template "shared/combomarkdowneditor" (dict "MarkdownPreviewInRepo" $.Repository "MarkdownPreviewMode" "comment" "TextareaName" "content" "TextareaContent" .content "TextareaPlaceholder" (ctx.Locale.Tr "repo.release.message") "DropzoneParentContainer" "form" )}}
{{range .attachments}}
{{.Size | FileSize}} {{svg "octicon-info"}}
{{ctx.Locale.Tr "remove"}}
{{end}} {{if .IsAttachmentEnabled}}
{{template "repo/upload" .}}
{{end}}
{{if not .PageIsEditRelease}}
{{else}} {{end}}
{{ctx.Locale.Tr "repo.release.prerelease_helper"}}
{{if .PageIsEditRelease}} {{ctx.Locale.Tr "repo.release.cancel"}} {{ctx.Locale.Tr "repo.release.delete_release"}} {{if .IsDraft}} {{else}} {{end}} {{else}} {{if not .tag_name}} {{end}} {{end}}