diff options
author | silverwind <me@silverwind.io> | 2020-06-09 23:31:15 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-06-09 17:31:15 -0400 |
commit | 19db3f4f0a6739e10aaa36d86ef5fd89dcf71467 (patch) | |
tree | 8c9dd890e7767c3582f981381d1c7697833e29c7 /templates/repo | |
parent | 363e51d19c7ae63a12554fbfb4dd4f59e87db339 (diff) | |
download | gitea-19db3f4f0a6739e10aaa36d86ef5fd89dcf71467.tar.gz gitea-19db3f4f0a6739e10aaa36d86ef5fd89dcf71467.zip |
rework eslint config (#11615)
* rework eslint config
- use explicit config that only enables rules
- upgrade eslint to 7.1.0
- add new plugins with selected rules enabled
- fix discovered issues, remove global wipPrefixes
* remove if
* undo template change
* add disabled rules as well for easier config updating
* add missing disabled rule
* update eslint and plugins
* fix new violation
* remove deprecated rules
Co-authored-by: Lauris BH <lauris@nix.lv>
Diffstat (limited to 'templates/repo')
-rw-r--r-- | templates/repo/issue/new_form.tmpl | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/templates/repo/issue/new_form.tmpl b/templates/repo/issue/new_form.tmpl index a42a4d9ad5..38ccccaf7b 100644 --- a/templates/repo/issue/new_form.tmpl +++ b/templates/repo/issue/new_form.tmpl @@ -15,7 +15,7 @@ <div class="field"> <input name="title" id="issue_title" placeholder="{{.i18n.Tr "repo.milestones.title"}}" value="{{.title}}" tabindex="3" autofocus required maxlength="255"> {{if .PageIsComparePull}} - <div class="title_wip_desc">{{.i18n.Tr "repo.pulls.title_wip_desc" (index .PullRequestWorkInProgressPrefixes 0| Escape) | Safe}}</div> + <div class="title_wip_desc" data-wip-prefixes="{{Json .PullRequestWorkInProgressPrefixes}}">{{.i18n.Tr "repo.pulls.title_wip_desc" (index .PullRequestWorkInProgressPrefixes 0| Escape) | Safe}}</div> {{end}} </div> {{template "repo/issue/comment_tab" .}} @@ -59,7 +59,7 @@ <a class="{{if .IsChecked}}checked{{end}} item" href="#" data-id="{{.ID}}" data-id-selector="#label_{{.ID}}"><span class="octicon-check {{if not .IsChecked}}invisible{{end}}">{{svg "octicon-check" 16}}</span><span class="label color" style="background-color: {{.Color}}"></span> {{.Name | RenderEmoji}} {{if .Description }}<br><small class="desc">{{.Description | RenderEmoji}}</small>{{end}}</a> {{end}} - + <div class="ui divider"></div> {{range .OrgLabels}} <a class="{{if .IsChecked}}checked{{end}} item" href="#" data-id="{{.ID}}" data-id-selector="#label_{{.ID}}"><span class="octicon-check {{if not .IsChecked}}invisible{{end}}">{{svg "octicon-check" 16}}</span><span class="label color" style="background-color: {{.Color}}"></span> {{.Name | RenderEmoji}} @@ -176,7 +176,4 @@ </div> </div> </form> -{{if .PageIsComparePull}} - <script>window.wipPrefixes = {{.PullRequestWorkInProgressPrefixes}}</script> -{{end}} |