Skip to content

Commit

Permalink
Merge pull request #7081 from ever-co/fix/#7000-repository-selector-i…
Browse files Browse the repository at this point in the history
…mprovement

Fix :: #7000 Repository Selector Improvement
  • Loading branch information
rahul-rocket authored Nov 3, 2023
2 parents 05b2326 + 0cd04ea commit 9f55795
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,13 @@
[placeholder]="'INTEGRATIONS.GITHUB_PAGE.SEARCH_REPOSITORY' | translate"
>
</ng-template>
<ng-template ng-label-tmp let-item="item">
<img src="assets/images/integrations/github.svg"/>
<span class="ml-1">{{ item.full_name }}</span>
</ng-template>
<ng-template ng-option-tmp let-item="item">
<span>{{ item.full_name }}</span>
</ng-template>
<img src="assets/images/integrations/github.svg"/>
<span class="ml-1">{{ item.full_name }}</span>
</ng-template>
</ng-select>
</div>
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,11 @@
nb-select {
max-width: none;
}
img {
width: 28px;
height: 28px;
border-radius: nb-theme(border-radius);
box-shadow: var(--gauzy-shadow);
object-fit: cover;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ import { TruncatePipe } from '../../pipes';
}
]
})
export class ProjectSelectorComponent
implements OnInit, OnDestroy, AfterViewInit {
export class ProjectSelectorComponent implements OnInit, OnDestroy, AfterViewInit {

projects: IOrganizationProject[] = [];
selectedProject: IOrganizationProject;
hasAddProject$: Observable<boolean>;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ <h5>
[defaultSelected]="false"
[showAllOption]="false"
[skipGlobalChange]="true"
[shortened]="true"
(onChanged)="selectedProject$.next($event)"
></ga-project-selector>
</div>
Expand Down Expand Up @@ -98,7 +99,7 @@ <h5>
</nb-card>
</ng-template>
</nb-tab>
<nb-tab [tabTitle]="'INTEGRATIONS.GITHUB_PAGE.TAB.MANUAL_SYNC' | translate" [active]="true">
<nb-tab [tabTitle]="'INTEGRATIONS.GITHUB_PAGE.TAB.MANUAL_SYNC' | translate">
<ng-template [ngIf]="integration$ | async">
<nb-card>
<nb-card-header>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -342,11 +342,14 @@ export class GithubViewComponent extends PaginationFilterBaseComponent implement
}
};


// Define settings for the Smart Table
this.settingsSmartTableProjects = {
selectedRowIndex: -1, // Initialize the selected row index
actions: false,
pager: {
display: false,
perPage: pagination ? pagination.itemsPerPage : 10
},
columns: {
repository: {
title: this.getTranslation('SM_TABLE.GITHUB_REPOSITORY'), // Set column title based on translation
Expand Down

0 comments on commit 9f55795

Please sign in to comment.