diff --git a/view/app/self-host/components/github-repositories/list-repositories.tsx b/view/app/self-host/components/github-repositories/list-repositories.tsx index 70c1d6a9..fe9ba9c0 100644 --- a/view/app/self-host/components/github-repositories/list-repositories.tsx +++ b/view/app/self-host/components/github-repositories/list-repositories.tsx @@ -6,6 +6,9 @@ import GithubRepositories, { GithubRepositoriesSkeletonLoader } from './reposito import PaginationWrapper from '@/components/ui/pagination'; import { useTranslation } from '@/hooks/use-translation'; + +import { TypographyMuted } from '@/components/ui/typography'; + function ListRepositories() { const { t } = useTranslation(); const { @@ -28,8 +31,12 @@ function ListRepositories() { return ; } - if (paginatedApplications?.length === 0 && !isLoading) { - return
{t('selfHost.repositories.noRepositories')}
; + if (paginatedApplications?.length === 0 && !isLoading) { + return ( +
+ {t('selfHost.repositories.noRepositories')} +
+ ); } return ( <> @@ -62,9 +69,14 @@ function ListRepositories() { sortConfig={sortConfig} onSortChange={onSortChange} sortOptions={sortOptions} + /* (changed) plain string label, no nested heading */ label={t('selfHost.repositories.title')} - className="mt-5 mb-5" + className="mt-5 mb-2 flex flex-col sm:flex-row sm:justify-between sm:items-center gap-2" /> + + {t('selfHost.repositories.description')} + + {renderGithubRepositories()} ); diff --git a/view/app/self-host/components/github-repositories/repository-card.tsx b/view/app/self-host/components/github-repositories/repository-card.tsx index ceb54634..18047675 100644 --- a/view/app/self-host/components/github-repositories/repository-card.tsx +++ b/view/app/self-host/components/github-repositories/repository-card.tsx @@ -6,6 +6,9 @@ import { GithubRepository } from '@/redux/types/github'; import { Skeleton } from '@/components/ui/skeleton'; import { useTranslation } from '@/hooks/use-translation'; + +import { TypographySmall, TypographyMuted } from '@/components/ui/typography'; + const GithubRepositories = ({ name, html_url: url, @@ -23,13 +26,15 @@ const GithubRepositories = ({ return ( setSelectedRepository(id.toString())} > - - - {name || t('selfHost.repositoryCard.unnamed')} + + + + {name || t('selfHost.repositoryCard.unnamed')} + {url && ( {description && ( - - {description} + + {description} )} @@ -103,45 +108,3 @@ const GithubRepositories = ({ }; export default GithubRepositories; - -export const GithubRepositoriesSkeletonLoader: React.FC = () => { - return ( -
- {[...Array(6)].map((_, index) => ( - - - - - - - - - - - - - -
- - -
-
- - - -
-
- - - - -
-
-
- ))} -
- ); -}; diff --git a/view/app/self-host/page.tsx b/view/app/self-host/page.tsx index cb8659f9..58948b9e 100644 --- a/view/app/self-host/page.tsx +++ b/view/app/self-host/page.tsx @@ -15,8 +15,9 @@ import { FeatureNames } from '@/types/feature-flags'; import DisabledFeature from '@/components/features/disabled-feature'; import { ResourceGuard, AnyPermissionGuard } from '@/components/rbac/PermissionGuard'; import PageLayout from '@/components/layout/page-layout'; -import { TypographyH2 } from '@/components/ui/typography'; -import { TypographyMuted } from '@/components/ui/typography'; + + +import { TypographyH2, TypographyMuted } from '@/components/ui/typography'; function page() { const { t } = useTranslation(); @@ -50,10 +51,7 @@ function page() { const renderContent = () => { return ( - + {inGitHubFlow && ( )} @@ -72,13 +70,14 @@ function page() { }; return ( - } fallback={
+ {/* Consistent access denied message */} {t('selfHost.page.accessDenied.title')} {t('selfHost.page.accessDenied.description')}
@@ -87,7 +86,7 @@ function page() { > {renderContent()} - + {showApplications && ( <> @@ -96,13 +95,11 @@ function page() { sortConfig={sortConfig} onSortChange={onSortChange} sortOptions={sortOptions} + /* (changed) pass plain string, no nested heading */ label={t('selfHost.page.title')} - className="mt-5 mb-5 justify-between items-center" + className="mt-5 mb-2 flex flex-col sm:flex-row sm:justify-between sm:items-center gap-2" children={ - +