Skip to content

Commit 8e4ed08

Browse files
authored
Merge pull request #198 from bcgsc/develop
Hotfix/v6.10.1
2 parents 8b8849e + c171f17 commit 8e4ed08

File tree

5 files changed

+79
-68
lines changed

5 files changed

+79
-68
lines changed

app/components/Image/index.tsx

Lines changed: 38 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -39,14 +39,14 @@ const Image = ({
3939
}
4040
}, [isZoomable]);
4141

42-
return (
43-
data && (
42+
if (data) {
43+
return (
4444
<>
4545
<div className="image">
4646
{showTitle && title && (
47-
<Typography variant="h3">
48-
{title}
49-
</Typography>
47+
<Typography variant="h3">
48+
{title}
49+
</Typography>
5050
)}
5151
<Button
5252
classes={{ root: 'image__button' }}
@@ -64,44 +64,45 @@ const Image = ({
6464
/>
6565
</Button>
6666
{showCaption && caption && (
67-
<Typography className="image__caption" variant="caption">
68-
{caption}
69-
</Typography>
67+
<Typography className="image__caption" variant="caption">
68+
{caption}
69+
</Typography>
7070
)}
7171
</div>
7272
{isZoomed && (
73-
<Fade in={isZoomed}>
74-
<button
75-
className="image__dialog-background"
76-
onClick={handleZoom}
77-
type="button"
73+
<Fade in={isZoomed}>
74+
<button
75+
className="image__dialog-background"
76+
onClick={handleZoom}
77+
type="button"
78+
>
79+
<div
80+
className="image__dialog-button"
7881
>
79-
<div
80-
className="image__dialog-button"
81-
>
82-
{showTitle && title && (
83-
<Typography variant="h3">
84-
{title}
85-
</Typography>
86-
)}
87-
<img
88-
className={`image__data ${isZoomable && isZoomed ? 'image__zoom--out' : ''}`}
89-
src={`data:image/${format};base64,${data}`}
90-
alt={title}
91-
key={key}
92-
/>
93-
{showCaption && caption && (
94-
<Typography className="image__caption" variant="caption">
95-
{caption}
96-
</Typography>
97-
)}
98-
</div>
99-
</button>
100-
</Fade>
82+
{showTitle && title && (
83+
<Typography variant="h3">
84+
{title}
85+
</Typography>
86+
)}
87+
<img
88+
className={`image__data ${isZoomable && isZoomed ? 'image__zoom--out' : ''}`}
89+
src={`data:image/${format};base64,${data}`}
90+
alt={title}
91+
key={key}
92+
/>
93+
{showCaption && caption && (
94+
<Typography className="image__caption" variant="caption">
95+
{caption}
96+
</Typography>
97+
)}
98+
</div>
99+
</button>
100+
</Fade>
101101
)}
102102
</>
103-
)
104-
);
103+
);
104+
}
105+
return null;
105106
};
106107

107108
export default Image;

app/views/ReportView/components/PharmacoGenomicSummary/columnDefs.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -263,9 +263,9 @@ const cancerPredisPrintColumnDefs = [
263263
colId: 'context',
264264
},
265265
{
266-
headerName: 'Evidence',
267-
field: 'evidenceLevel',
268-
colId: 'evidenceLevel',
266+
headerName: 'Source',
267+
field: 'externalSource',
268+
colId: 'externalSource',
269269
},
270270
];
271271
const cancerPredisColumnDefs = [
@@ -274,8 +274,8 @@ const cancerPredisColumnDefs = [
274274
field: 'context',
275275
},
276276
{
277-
headerName: 'Evidence',
278-
field: 'evidenceLevel',
277+
headerName: 'Source',
278+
field: 'externalSource',
279279
minWidth: 90,
280280
},
281281
ACTIONS_COL_DEF,

app/views/ReportView/components/PharmacoGenomicSummary/index.tsx

Lines changed: 34 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -205,29 +205,34 @@ const PharmacoGenomicSummary = ({
205205
No pharmacogenomic variants found
206206
</div>
207207
);
208+
208209
if (pharmacoGenomic.length > 0) {
210+
let tableComponent = null;
209211
if (isPrint) {
210-
component = (
212+
tableComponent = (
211213
<PrintTable
212214
columnDefs={pharmacoGenomicPrintColumnDefs}
213215
data={pharmacoGenomic}
214216
/>
215217
);
216218
} else {
217-
component = (
218-
<>
219-
<DataTable
220-
columnDefs={pharmacoGenomicColumnDefs}
221-
rowData={pharmacoGenomic}
222-
isPrint={isPrint}
223-
isPaginated={!isPrint}
224-
/>
225-
<Alert className="summary--max-width" severity="warning">
226-
Positive Pharmacogenomic Result: At least one pharmacogenomic variant was identified in this sample. Further clinical testing to determine risk of toxicity is recommended for this patient.
227-
</Alert>
228-
</>
219+
tableComponent = (
220+
<DataTable
221+
columnDefs={pharmacoGenomicColumnDefs}
222+
rowData={pharmacoGenomic}
223+
isPrint={isPrint}
224+
isPaginated={!isPrint}
225+
/>
229226
);
230227
}
228+
component = (
229+
<>
230+
{tableComponent}
231+
<Alert className="summary--max-width" severity="warning">
232+
Positive Pharmacogenomic Result: At least one pharmacogenomic variant was identified in this sample. Further clinical testing to determine risk of toxicity is recommended for this patient.
233+
</Alert>
234+
</>
235+
);
231236
}
232237
return component;
233238
}, [pharmacoGenomic, isPrint]);
@@ -238,23 +243,28 @@ const PharmacoGenomicSummary = ({
238243
No cancer predisposition variants found
239244
</div>
240245
);
241-
if (isPrint) {
242-
component = (
243-
<PrintTable
244-
columnDefs={cancerPredisPrintColumnDefs}
245-
data={cancerPredisposition}
246-
/>
247-
);
248-
} else if (cancerPredisposition.length > 0) {
249-
component = (
250-
<>
246+
if (cancerPredisposition.length > 0) {
247+
let tableComponent = null;
248+
if (isPrint) {
249+
tableComponent = (
250+
<PrintTable
251+
columnDefs={cancerPredisPrintColumnDefs}
252+
data={cancerPredisposition}
253+
/>
254+
);
255+
} else {
256+
tableComponent = (
251257
<DataTable
252-
// Shares same column definitions as pharmacogenomic
253258
columnDefs={cancerPredisColumnDefs}
254259
rowData={cancerPredisposition}
255260
isPrint={isPrint}
256261
isPaginated={!isPrint}
257262
/>
263+
);
264+
}
265+
component = (
266+
<>
267+
{tableComponent}
258268
<Alert className="summary--max-width" severity="warning">
259269
Positive Cancer Predisposition Result: At least one pathogenic cancer predisposition variant was identified in this sample. A referral to the Hereditary Cancer Program is recommended for this patient.
260270
</Alert>

package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"private": true,
33
"name": "ipr-client",
4-
"version": "6.10.0",
4+
"version": "6.10.1",
55
"keywords": [],
66
"license": "GPL-3.0",
77
"sideEffects": false,

0 commit comments

Comments
 (0)