-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
5675efb
commit 60f66c5
Showing
16 changed files
with
292 additions
and
305 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
{{/* | ||
* "labels" from query string | ||
* QueryLink | ||
* Labels | ||
* SupportArchivedLabel, if true, then it needs "archived_labes" from query string | ||
*/}} | ||
{{$queryLink := .QueryLink}} | ||
<div class="item ui {{if not .Labels}}disabled{{end}} dropdown jump label-filter"> | ||
<span class="text">{{ctx.Locale.Tr "repo.issues.filter_label"}}</span> | ||
{{svg "octicon-triangle-down" 14 "dropdown icon"}} | ||
<div class="menu flex-items-menu"> | ||
<div class="ui icon search input"> | ||
<i class="icon">{{svg "octicon-search" 16}}</i> | ||
<input type="text" placeholder="{{ctx.Locale.Tr "repo.issues.filter_label"}}"> | ||
</div> | ||
{{if .SupportArchivedLabel}}{{/* this checkbox has a hard dependency with the "labels" and "archived_label" query parameter */}} | ||
<label class="label-filter-archived-toggle flex-text-block"> | ||
<input type="checkbox"> {{ctx.Locale.Tr "repo.issues.label_archived_filter"}} | ||
<span data-tooltip-content={{ctx.Locale.Tr "repo.issues.label_archive_tooltip"}}>{{svg "octicon-info"}}</span> | ||
</label> | ||
{{end}} | ||
<span class="info">{{ctx.Locale.Tr "repo.issues.filter_label_exclude"}}</span> | ||
<div class="divider"></div> | ||
<a class="item label-filter-query-default" href="{{QueryBuild $queryLink "labels" NIL}}">{{ctx.Locale.Tr "repo.issues.filter_label_no_select"}}</a> | ||
<a class="item label-filter-query-not-set" href="{{QueryBuild $queryLink "labels" 0}}">{{ctx.Locale.Tr "repo.issues.filter_label_select_no_label"}}</a> | ||
{{$previousExclusiveScope := "_no_scope"}} | ||
{{range .Labels}} | ||
{{$exclusiveScope := .ExclusiveScope}} | ||
{{if and (ne $previousExclusiveScope $exclusiveScope)}} | ||
<div class="divider" data-scope="{{.ExclusiveScope}}"></div> | ||
{{end}} | ||
{{$previousExclusiveScope = $exclusiveScope}} | ||
<a class="item label-filter-query-item" data-label-id="{{.ID}}" data-scope="{{.ExclusiveScope}}" {{if .IsArchived}}data-is-archived{{end}} | ||
href="{{QueryBuild $queryLink "labels" .QueryString}}"> | ||
{{if .IsExcluded}} | ||
{{svg "octicon-circle-slash"}} | ||
{{else if .IsSelected}} | ||
{{Iif $exclusiveScope (svg "octicon-dot-fill") (svg "octicon-check")}} | ||
{{end}} | ||
{{ctx.RenderUtils.RenderLabel .}} | ||
<p class="tw-ml-auto">{{template "repo/issue/labels/label_archived" .}}</p> | ||
</a> | ||
{{end}} | ||
</div> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
{{/* This is a user list for filter, the data is provided by a local variable assignment | ||
* QueryParamKey: eg: "poster", "assignee" | ||
* QueryLink | ||
* UserSearchList | ||
* SelectedUserId: 0 or empty means default, -1 means "not user is set" | ||
* TextFilterTitle | ||
* TextZeroValue: the text for "all issues" | ||
* TextNegativeOne: the text for "issues with no assignee" | ||
*/}} | ||
{{$queryLink := .QueryLink}} | ||
<div class="item ui {{if not .UserSearchList}}disabled{{end}} dropdown jump"> | ||
{{$.TextFilterTitle}} {{svg "octicon-triangle-down" 14 "dropdown icon"}} | ||
<div class="menu"> | ||
<div class="ui icon search input"> | ||
<i class="icon">{{svg "octicon-search" 16}}</i> | ||
<input type="text" placeholder="{{ctx.Locale.Tr "repo.issues.filter_user_placeholder"}}"> | ||
</div> | ||
{{if $.TextZeroValue}} | ||
<a class="item {{if not .SelectedUserId}}selected{{end}}" href="{{QueryBuild $queryLink $.QueryParamKey NIL}}">{{$.TextZeroValue}}</a> | ||
{{end}} | ||
{{if $.TextNegativeOne}} | ||
<a class="item {{if eq .SelectedUserId -1}}selected{{end}}" href="{{QueryBuild $queryLink $.QueryParamKey -1}}">{{$.TextNegativeOne}}</a> | ||
{{end}} | ||
<div class="divider"></div> | ||
{{range .UserSearchList}} | ||
<a class="item {{if eq $.SelectedUserId .ID}}selected{{end}} item" href="{{QueryBuild $queryLink $.QueryParamKey .ID}}"> | ||
{{ctx.AvatarUtils.Avatar . 20}}{{template "repo/search_name" .}} | ||
</a> | ||
{{end}} | ||
</div> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
{{/* This is a user list for filter, the data is provided by a remote "fetch" request | ||
* QueryParamKey: eg: "poster", "assignee" | ||
* QueryLink | ||
* UserSearchUrl | ||
* SelectedUserId | ||
* TextFilterTitle | ||
*/}} | ||
{{$queryLink := .QueryLink}} | ||
<div class="item ui dropdown custom user-remote-search" data-tooltip-content="{{ctx.Locale.Tr "repo.user_search_tooltip"}}" | ||
data-search-url="{{$.UserSearchUrl}}" | ||
data-selected-user-id="{{$.SelectedUserId}}" | ||
data-action-jump-url="{{QueryBuild $queryLink $.QueryParamKey NIL}}&{{$.QueryParamKey}}={username}" | ||
> | ||
{{$.TextFilterTitle}} {{svg "octicon-triangle-down" 14 "dropdown icon"}} | ||
<div class="menu"> | ||
<div class="ui icon search input"> | ||
<i class="icon">{{svg "octicon-search" 16}}</i> | ||
<input type="text" placeholder="{{ctx.Locale.Tr "repo.issues.filter_user_placeholder"}}"> | ||
</div> | ||
<a class="item" data-value="">{{ctx.Locale.Tr "repo.issues.filter_user_no_select"}}</a> | ||
<a class="item item-from-input tw-hidden"></a> | ||
</div> | ||
</div> |
Oops, something went wrong.