|
8 | 8 | {{template "repo/view_file_tree" .}} |
9 | 9 | </div> |
10 | 10 | <div class="repo-view-content"> |
11 | | - <form class="ui edit form form-fetch-action" method="post" action="{{.CommitFormOptions.TargetFormAction}}" |
12 | | - data-text-empty-confirm-header="{{ctx.Locale.Tr "repo.editor.commit_empty_file_header"}}" |
13 | | - data-text-empty-confirm-content="{{ctx.Locale.Tr "repo.editor.commit_empty_file_text"}}" |
14 | | - > |
15 | | - {{.CsrfTokenHtml}} |
16 | | - {{template "repo/editor/common_top" .}} |
17 | | - <div class="repo-editor-header tw-flex tw-items-center tw-gap-2"> |
18 | | - <button type="button" class="repo-view-file-tree-toggle-show ui compact basic button icon not-mobile {{if .UserSettingCodeViewShowFileTree}}tw-hidden{{end}}" |
19 | | - data-global-click="onRepoViewFileTreeToggle" data-toggle-action="show" |
20 | | - data-tooltip-content="{{ctx.Locale.Tr "repo.diff.show_file_tree"}}"> |
21 | | - {{svg "octicon-sidebar-collapse"}} |
22 | | - </button> |
23 | | - <div class="breadcrumb"> |
24 | | - {{ctx.Locale.Tr "repo.editor.patching"}} |
25 | | - <a class="section" href="{{$.BranchLink}}">{{.BranchName}}</a> |
26 | | - <span>{{ctx.Locale.Tr "repo.editor.or"}} <a href="{{$.BranchLink}}">{{ctx.Locale.Tr "repo.editor.cancel_lower"}}</a></span> |
27 | | - <input type="hidden" name="tree_path" value="__dummy_for_EditRepoFileForm.TreePath(Required)__"> |
28 | | - <input id="file-name" type="hidden" value="diff.patch"> |
29 | | - </div> |
30 | | - </div> |
31 | | - <div class="field"> |
32 | | - <div class="ui compact small menu small-menu-items repo-editor-menu"> |
33 | | - <a class="active item" data-tab="write">{{svg "octicon-code" 16 "tw-mr-1"}}{{ctx.Locale.Tr "repo.editor.new_patch"}}</a> |
34 | | - </div> |
35 | | - <div class="ui active tab segment tw-rounded tw-p-0" data-tab="write"> |
36 | | - <textarea id="edit_area" name="content" class="tw-hidden" data-id="repo-{{.Repository.Name}}-patch" |
37 | | - data-context="{{.RepoLink}}" |
38 | | - data-line-wrap-extensions="{{.LineWrapExtensions}}"> |
39 | | -{{.FileContent}}</textarea> |
40 | | - <div class="editor-loading is-loading"></div> |
41 | | - </div> |
42 | | - </div> |
43 | | - {{template "repo/editor/commit_form" .}} |
| 11 | + <form class="ui edit form form-fetch-action" method="post" action="{{.CommitFormOptions.TargetFormAction}}" data-text-empty-confirm-header="{{ctx.Locale.Tr "repo.editor.commit_empty_file_header"}}" data-text-empty-confirm-content="{{ctx.Locale.Tr "repo.editor.commit_empty_file_text"}}"> |
| 12 | + {{.CsrfTokenHtml}} |
| 13 | + {{template "repo/editor/common_top" .}} |
| 14 | + <div class="repo-editor-header tw-flex tw-items-center tw-gap-2"> |
| 15 | + <button type="button" class="repo-view-file-tree-toggle-show ui compact basic button icon not-mobile {{if .UserSettingCodeViewShowFileTree}}tw-hidden{{end}}" |
| 16 | + data-global-click="onRepoViewFileTreeToggle" data-toggle-action="show" |
| 17 | + data-tooltip-content="{{ctx.Locale.Tr "repo.diff.show_file_tree"}}"> |
| 18 | + {{svg "octicon-sidebar-collapse"}} |
| 19 | + </button> |
| 20 | + <div class="breadcrumb"> |
| 21 | + {{ctx.Locale.Tr "repo.editor.patching"}} |
| 22 | + <a class="section" href="{{$.BranchLink}}">{{.BranchName}}</a> |
| 23 | + <span>{{ctx.Locale.Tr "repo.editor.or"}} <a href="{{$.BranchLink}}">{{ctx.Locale.Tr "repo.editor.cancel_lower"}}</a></span> |
| 24 | + <input type="hidden" name="tree_path" value="__dummy_for_EditRepoFileForm.TreePath(Required)__"> |
| 25 | + <input id="file-name" type="hidden" value="diff.patch"> |
| 26 | + </div> |
| 27 | + </div> |
| 28 | + <div class="field"> |
| 29 | + <div class="ui compact small menu small-menu-items repo-editor-menu"> |
| 30 | + <a class="active item" data-tab="write">{{svg "octicon-code" 16 "tw-mr-1"}}{{ctx.Locale.Tr "repo.editor.new_patch"}}</a> |
| 31 | + </div> |
| 32 | + <div class="ui active tab segment tw-rounded tw-p-0" data-tab="write"> |
| 33 | + <textarea id="edit_area" name="content" class="tw-hidden" data-id="repo-{{.Repository.Name}}-patch" |
| 34 | + data-context="{{.RepoLink}}" |
| 35 | + data-line-wrap-extensions="{{.LineWrapExtensions}}">{{.FileContent}}</textarea> |
| 36 | + <div class="editor-loading is-loading"></div> |
| 37 | + </div> |
| 38 | + </div> |
| 39 | + {{template "repo/editor/commit_form" .}} |
44 | 40 | </form> |
45 | 41 | </div> |
46 | 42 | </div> |
|
0 commit comments