Skip to content

Commit

Permalink
refactor svg icon imports on patient view
Browse files Browse the repository at this point in the history
  • Loading branch information
inodb committed Aug 14, 2024
1 parent 08f8b9b commit 4ecbdc6
Show file tree
Hide file tree
Showing 4 changed files with 90 additions and 127 deletions.
124 changes: 0 additions & 124 deletions src/pages/patientView/SVGIcons.tsx

This file was deleted.

13 changes: 10 additions & 3 deletions src/pages/patientView/sampleHeader/SampleSummaryList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import { observer } from 'mobx-react';
import { ClinicalDataBySampleId } from 'cbioportal-ts-api-client';
import _ from 'lodash';
import { getSpanElementsFromCleanData } from '../clinicalInformation/lib/clinicalAttributesUtil';
import { getMouseIcon, getOrganoidIcon } from '../SVGIcons';
import { getSampleViewUrl } from 'shared/api/urls';
import SignificantMutationalSignatures from '../patientHeader/SignificantMutationalSignatures';
import { PatientViewPageStore } from '../clinicalInformation/PatientViewPageStore';
Expand Down Expand Up @@ -110,8 +109,16 @@ export default class SampleSummaryList extends React.Component<
'',
<span style={{ display: 'inline-flex' }}>
{'\u00A0'}
{isPDX && getMouseIcon()}
{isOrganoid && getOrganoidIcon()}
{isPDX && (
<img
src={require('./mouse_icon.svg')}
/>
)}
{isOrganoid && (
<img
src={require('./organoid_icon.svg')}
/>
)}
{(isPDX || isOrganoid) && '\u00A0'}
<a
href={getSampleViewUrl(
Expand Down
44 changes: 44 additions & 0 deletions src/pages/patientView/sampleHeader/mouse_icon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
36 changes: 36 additions & 0 deletions src/pages/patientView/sampleHeader/organoid_icon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 4ecbdc6

Please sign in to comment.