mirror of
https://github.com/go-gitea/gitea
synced 2025-07-22 18:28:37 +00:00
* Allow committing / adding empty files from the web ui (#8420) Signed-off-by: LukBukkit <luk.bukkit@gmail.com> * Add a modal to confirm the commit of an empty file Signed-off-by: LukBukkit <luk.bukkit@gmail.com>
This commit is contained in:
@@ -39,8 +39,7 @@
|
||||
data-url="{{.Repository.APIURL}}/markdown"
|
||||
data-context="{{.RepoLink}}"
|
||||
data-markdown-file-exts="{{.MarkdownFileExts}}"
|
||||
data-line-wrap-extensions="{{.LineWrapExtensions}}"
|
||||
required>
|
||||
data-line-wrap-extensions="{{.LineWrapExtensions}}">
|
||||
{{.FileContent}}</textarea>
|
||||
</div>
|
||||
<div class="ui bottom attached tab segment markdown" data-tab="preview">
|
||||
@@ -53,5 +52,27 @@
|
||||
{{template "repo/editor/commit_form" .}}
|
||||
</form>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="ui small basic modal" id="edit-empty-content-modal">
|
||||
<div class="ui icon header">
|
||||
<i class="file icon"></i>
|
||||
{{.i18n.Tr "repo.editor.commit_empty_file_header"}}
|
||||
</div>
|
||||
<div class="center content">
|
||||
<p>{{.i18n.Tr "repo.editor.commit_empty_file_text"}}</p>
|
||||
</div>
|
||||
<div class="actions">
|
||||
<div class="ui red basic cancel inverted button">
|
||||
<i class="remove icon"></i>
|
||||
{{.i18n.Tr "repo.editor.cancel"}}
|
||||
</div>
|
||||
<div class="ui green basic ok inverted button">
|
||||
<i class="save icon"></i>
|
||||
{{.i18n.Tr "repo.editor.commit_changes"}}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
{{template "base/footer" .}}
|
||||
|
Reference in New Issue
Block a user