Skip to content

Commit

Permalink
fix label ctx
Browse files Browse the repository at this point in the history
  • Loading branch information
wxiaoguang committed Feb 24, 2023
1 parent 0bc8bb3 commit bd7f218
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions templates/repo/issue/labels/labels_sidebar.tmpl
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<div class="ui labels list">
<span class="no-select item {{if .ctx.HasSelectedLabel}}gt-hidden{{end}}">{{.ctx.locale.Tr "repo.issues.new.no_label"}}</span>
<span class="no-select item {{if .root.HasSelectedLabel}}gt-hidden{{end}}">{{.root.locale.Tr "repo.issues.new.no_label"}}</span>
<span class="labels-list">
{{range .ctx.Labels}}
{{range .root.Labels}}
{{template "repo/issue/labels/label" dict "root" $.root "label" .}}
{{end}}
{{range .ctx.OrgLabels}}
{{range .root.OrgLabels}}
{{template "repo/issue/labels/label" dict "root" $.root "label" .}}
{{end}}
</span>
Expand Down
2 changes: 1 addition & 1 deletion templates/repo/issue/new_form.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@
{{end}}
</div>
</div>
{{template "repo/issue/labels/labels_sidebar" dict "root" $ "ctx" .}}
{{template "repo/issue/labels/labels_sidebar" dict "root" $}}

<div class="ui divider"></div>

Expand Down
2 changes: 1 addition & 1 deletion templates/repo/issue/view_content/sidebar.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@
{{end}}
</div>
</div>
{{template "repo/issue/labels/labels_sidebar" dict "root" $ "ctx" .}}
{{template "repo/issue/labels/labels_sidebar" dict "root" $}}

<div class="ui divider"></div>

Expand Down

0 comments on commit bd7f218

Please sign in to comment.