diff --git a/client/src/components/Browse/Sources/BrowseSources.tsx b/client/src/components/Browse/Sources/BrowseSources.tsx index 277727e9..a7316f55 100644 --- a/client/src/components/Browse/Sources/BrowseSources.tsx +++ b/client/src/components/Browse/Sources/BrowseSources.tsx @@ -27,10 +27,17 @@ export const BrowseSources = () => { 'POTENTIALLY_DRUGGABLE' ); - let geneSources = geneData?.sources?.nodes; - let drugSources = drugData?.sources?.nodes; - let interactionSources = interactionData?.sources?.nodes; - let potentiallyDruggableSources = potentiallyDruggableData?.sources?.nodes; + const getSortedData = (data: any) => { + return data?.sources?.nodes?.sort( + (a: { sourceDbName: string }, b: { sourceDbName: any }) => + a.sourceDbName.localeCompare(b.sourceDbName) + ); + }; + + let geneSources = getSortedData(geneData); + let drugSources = getSortedData(drugData); + let interactionSources = getSortedData(interactionData); + let potentiallyDruggableSources = getSortedData(potentiallyDruggableData); const sectionsMap = [ { diff --git a/client/src/components/Interaction/InteractionRecord/InteractionRecord.tsx b/client/src/components/Interaction/InteractionRecord/InteractionRecord.tsx index b50fb760..21196af6 100644 --- a/client/src/components/Interaction/InteractionRecord/InteractionRecord.tsx +++ b/client/src/components/Interaction/InteractionRecord/InteractionRecord.tsx @@ -15,6 +15,7 @@ import AccordionSummary from '@mui/material/AccordionSummary'; import AccordionDetails from '@mui/material/AccordionDetails'; import ExpandMoreIcon from '@mui/icons-material/ExpandMore'; import ArrowRightIcon from '@mui/icons-material/ArrowRight'; +import { truncateDecimals } from 'utils/format'; export const InteractionRecord: React.FC = () => { const interactionId = useParams().id; @@ -61,7 +62,7 @@ export const InteractionRecord: React.FC = () => { Interaction Score: - {data?.interaction?.interactionScore} + {truncateDecimals(data?.interaction?.interactionScore, 2)} @@ -116,6 +117,30 @@ export const InteractionRecord: React.FC = () => { ), }, + { + name: 'Sources', + sectionContent: ( + + + + {data?.interaction?.sources.length + ? data?.interaction?.sources?.map( + (source: any, index: number) => { + return ( + + + {source.fullName} + + + ); + } + ) + : noData} + +
+
+ ), + }, ]; return ( diff --git a/client/src/components/Layout/MainLayout.scss b/client/src/components/Layout/MainLayout.scss index 8296bb44..0972e129 100644 --- a/client/src/components/Layout/MainLayout.scss +++ b/client/src/components/Layout/MainLayout.scss @@ -100,8 +100,6 @@ header { footer { background-color: var(--theme-primary); - position: fixed; - bottom: 0; color: white; margin-top: auto; width: 100%; diff --git a/client/src/components/Layout/MainLayout.tsx b/client/src/components/Layout/MainLayout.tsx index 2b9d0564..e83acd38 100644 --- a/client/src/components/Layout/MainLayout.tsx +++ b/client/src/components/Layout/MainLayout.tsx @@ -10,6 +10,7 @@ import { GlobalClientContext } from 'stores/Global/GlobalClient'; import './MainLayout.scss'; import { Box, Button, IconButton, Menu, MenuItem } from '@mui/material'; import HighlightOffIcon from '@mui/icons-material/HighlightOff'; +import ReleaseInformation from 'components/Shared/ReleaseInformation/ReleaseInformation'; type MainLayoutProps = { children: React.ReactNode; @@ -80,24 +81,29 @@ const Header: React.FC = () => { }; const Footer: React.FC = () => { - const { dispatch } = useContext(GlobalClientContext); + const { state, dispatch } = useContext(GlobalClientContext); return ( ); }; @@ -127,7 +133,7 @@ export const MainLayout = ({ children }: MainLayoutProps) => {
{children}
- {state.themeSettings.showDisclaimer &&