From 99cd635c4a6b5677c7e22664354620bded596f15 Mon Sep 17 00:00:00 2001 From: Sny Date: Tue, 12 Nov 2024 09:37:45 +0530 Subject: [PATCH] Feedbacks | repo changes --- src/components/mappings/ToConceptCard.jsx | 1 - src/components/repos/RepoHome.jsx | 17 +++++++++++++---- src/components/repos/RepoSummary.jsx | 22 +++++++++++----------- 3 files changed, 24 insertions(+), 16 deletions(-) diff --git a/src/components/mappings/ToConceptCard.jsx b/src/components/mappings/ToConceptCard.jsx index cb81bf55..a08bd60e 100644 --- a/src/components/mappings/ToConceptCard.jsx +++ b/src/components/mappings/ToConceptCard.jsx @@ -69,7 +69,6 @@ const ToConceptCard = ({ mapping }) => { }} /> - ) } diff --git a/src/components/repos/RepoHome.jsx b/src/components/repos/RepoHome.jsx index 892437f7..73c6288a 100644 --- a/src/components/repos/RepoHome.jsx +++ b/src/components/repos/RepoHome.jsx @@ -75,6 +75,12 @@ const RepoHome = () => { } React.useEffect(() => { + if(toParentURI(location.pathname) === (repo?.version_url || repo.url)) { + if(location.pathname.includes('/concepts/')) + setTab('concepts') + if(location.pathname.includes('/mappings/')) + setTab('mappings') + } fetchRepo() fetchVersions() }, [location.pathname]) @@ -116,7 +122,7 @@ const RepoHome = () => { (repo?.id || loading) && setConceptForm(false)} /> -
+
{ repo?.id && ['concepts', 'mappings'].includes(tab) && @@ -139,9 +145,12 @@ const RepoHome = () => { }
- - - + { + !isSplitView && + + + + } } { diff --git a/src/components/repos/RepoSummary.jsx b/src/components/repos/RepoSummary.jsx index 8701c6d7..11f7a292 100644 --- a/src/components/repos/RepoSummary.jsx +++ b/src/components/repos/RepoSummary.jsx @@ -123,13 +123,13 @@ const RepoSummary = ({ repo, summary }) => { - + : - <>{`${conceptClasses?.toLocaleString()} ${t('concept.concept_classes')}`} + <>{`${locales?.toLocaleString()} ${t('repo.locales')}`} } sx={{ '.MuiListItemText-primary': {fontSize: '12px', color: 'secondary.main'} @@ -138,13 +138,13 @@ const RepoSummary = ({ repo, summary }) => { - + : - <>{`${datatypes?.toLocaleString()} ${t('concept.datatypes')}`} + <>{`${conceptClasses?.toLocaleString()} ${t('concept.concept_classes')}`} } sx={{ '.MuiListItemText-primary': {fontSize: '12px', color: 'secondary.main'} @@ -157,9 +157,9 @@ const RepoSummary = ({ repo, summary }) => { : - <>{`${nameTypes?.toLocaleString()} ${t('concept.name_types')}`} + <>{`${datatypes?.toLocaleString()} ${t('concept.datatypes')}`} } sx={{ '.MuiListItemText-primary': {fontSize: '12px', color: 'secondary.main'} @@ -168,13 +168,13 @@ const RepoSummary = ({ repo, summary }) => { - + : - <>{`${locales?.toLocaleString()} ${t('repo.locales')}`} + <>{`${nameTypes?.toLocaleString()} ${t('concept.name_types')}`} } sx={{ '.MuiListItemText-primary': {fontSize: '12px', color: 'secondary.main'}