-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[angular-ngrx-scss] pulls tab (#1942)
* wip: PRs * wip: PRs * fix: use search api, fix tests * fix: adjusted regex * fix: try to prevent regex backtracking * fix: avoid regex, properly paginate * fix: restore deleted code * refactor: remove code duplications * fix: add clear filters button and resolve lint warnings * fix: use nullish coalescing operator instead of logical or * fix: replace logical or with nullish coalescing operator --------- Co-authored-by: Jan Kaiser <[email protected]>
- Loading branch information
Showing
42 changed files
with
600 additions
and
319 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
6 changes: 6 additions & 0 deletions
6
angular-ngrx-scss/src/app/issues/components/issues-header/issues-header.component.html
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
6 changes: 4 additions & 2 deletions
6
angular-ngrx-scss/src/app/issues/components/issues.component.scss
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 |
---|---|---|
@@ -1,7 +1,9 @@ | ||
@use 'variables'; | ||
@use 'functions'; | ||
|
||
.issues-container { | ||
border-radius: variables.$padding; | ||
border-bottom-left-radius: variables.$padding; | ||
border-bottom-right-radius: variables.$padding; | ||
border: 1px solid variables.$gray200; | ||
margin: 1rem auto; | ||
margin-bottom: functions.rem(14); | ||
} |
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
19 changes: 16 additions & 3 deletions
19
...src/app/pull-requests/components/pull-requests-header/pull-requests-header.component.html
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 |
---|---|---|
@@ -1,32 +1,45 @@ | ||
<div class="filters-container"> | ||
<div class="container" *ngIf="hasFilters$ | async"> | ||
<app-clear-filters-button (clearFilters)="clearFilters()" | ||
>Clear current search query, filters, and sorts</app-clear-filters-button | ||
> | ||
</div> | ||
|
||
<div class="container filters-container"> | ||
<div class="pull-requests-status"> | ||
<button | ||
class="tab-button" | ||
[ngClass]="{ active: viewState === 'open' }" | ||
(click)="changeViewState('open')" | ||
> | ||
<span class="icon" appOcticon="no-entry" size="16"></span> | ||
<span>{{ openPullRequests?.totalCount ?? 0 }} Open</span> | ||
<span>{{ openPullRequests?.total ?? 0 }} Open</span> | ||
</button> | ||
<button | ||
class="tab-button" | ||
[ngClass]="{ active: viewState === 'closed' }" | ||
(click)="changeViewState('closed')" | ||
> | ||
<span class="icon" appOcticon="check" size="16"></span | ||
><span>{{ closedPullRequests?.totalCount ?? 0 }} closed</span> | ||
><span>{{ closedPullRequests?.total ?? 0 }} closed</span> | ||
</button> | ||
</div> | ||
<div class="pull-requests-filters"> | ||
<app-filter-dropdown | ||
name="Label" | ||
description="Select label" | ||
[isRepo]="true" | ||
[toggle]="true" | ||
[items]="(labels$ | async) ?? []" | ||
(setFilter)="setLabel($event)" | ||
[current]="filterParams.labels" | ||
></app-filter-dropdown> | ||
<app-filter-dropdown | ||
name="Sort" | ||
description="Select sort" | ||
[isRepo]="true" | ||
[items]="sortOptions" | ||
(setFilter)="setSort($event)" | ||
[current]="filterParams.sort" | ||
></app-filter-dropdown> | ||
</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
Oops, something went wrong.