From 0cd04ea7bb26cac17d14bb1beb4ff30d317b1f61 Mon Sep 17 00:00:00 2001
From: RAHUL RATHORE <41804588+rahul-rocket@users.noreply.github.com>
Date: Fri, 3 Nov 2023 22:41:37 +0530
Subject: [PATCH] fix: #7000 repository selector improvement
---
.../repository-selector.component.html | 9 +++++++--
.../repository-selector.component.scss | 7 +++++++
.../@shared/project-select/project/project.component.ts | 4 ++--
.../github/components/view/view.component.html | 3 ++-
.../github/components/view/view.component.ts | 5 ++++-
5 files changed, 22 insertions(+), 6 deletions(-)
diff --git a/apps/gauzy/src/app/@shared/integrations/github/repository-selector/repository-selector.component.html b/apps/gauzy/src/app/@shared/integrations/github/repository-selector/repository-selector.component.html
index 06a029c47dd..2547bb784d1 100644
--- a/apps/gauzy/src/app/@shared/integrations/github/repository-selector/repository-selector.component.html
+++ b/apps/gauzy/src/app/@shared/integrations/github/repository-selector/repository-selector.component.html
@@ -25,8 +25,13 @@
[placeholder]="'INTEGRATIONS.GITHUB_PAGE.SEARCH_REPOSITORY' | translate"
>
+
+
+ {{ item.full_name }}
+
- {{ item.full_name }}
-
+
+ {{ item.full_name }}
+
diff --git a/apps/gauzy/src/app/@shared/integrations/github/repository-selector/repository-selector.component.scss b/apps/gauzy/src/app/@shared/integrations/github/repository-selector/repository-selector.component.scss
index 90e96ef9e68..f969e6564c9 100644
--- a/apps/gauzy/src/app/@shared/integrations/github/repository-selector/repository-selector.component.scss
+++ b/apps/gauzy/src/app/@shared/integrations/github/repository-selector/repository-selector.component.scss
@@ -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;
+ }
}
diff --git a/apps/gauzy/src/app/@shared/project-select/project/project.component.ts b/apps/gauzy/src/app/@shared/project-select/project/project.component.ts
index db7390c9ac5..a154ebf937b 100644
--- a/apps/gauzy/src/app/@shared/project-select/project/project.component.ts
+++ b/apps/gauzy/src/app/@shared/project-select/project/project.component.ts
@@ -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;
diff --git a/apps/gauzy/src/app/pages/integrations/github/components/view/view.component.html b/apps/gauzy/src/app/pages/integrations/github/components/view/view.component.html
index 91b1b5da80c..324bf452323 100644
--- a/apps/gauzy/src/app/pages/integrations/github/components/view/view.component.html
+++ b/apps/gauzy/src/app/pages/integrations/github/components/view/view.component.html
@@ -65,6 +65,7 @@
[defaultSelected]="false"
[showAllOption]="false"
[skipGlobalChange]="true"
+ [shortened]="true"
(onChanged)="selectedProject$.next($event)"
>
@@ -98,7 +99,7 @@
-
+
diff --git a/apps/gauzy/src/app/pages/integrations/github/components/view/view.component.ts b/apps/gauzy/src/app/pages/integrations/github/components/view/view.component.ts
index 1648fa94cd8..47abac1ce12 100644
--- a/apps/gauzy/src/app/pages/integrations/github/components/view/view.component.ts
+++ b/apps/gauzy/src/app/pages/integrations/github/components/view/view.component.ts
@@ -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