@sjcrh/proteinpaint-types 2.118.3-2 → 2.119.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -75,7 +75,7 @@ var validDEResponse = (input) => {
75
75
  const errors = [];
76
76
  const __is = (input2) => {
77
77
  const $io0 = (input3) => Array.isArray(input3.data) && input3.data.every((elem) => "object" === typeof elem && null !== elem && $io1(elem)) && "number" === typeof input3.sample_size1 && "number" === typeof input3.sample_size2 && "string" === typeof input3.method && (void 0 === input3.images || Array.isArray(input3.images) && input3.images.every((elem) => "object" === typeof elem && null !== elem && $io2(elem)));
78
- const $io1 = (input3) => "number" === typeof input3.adjusted_p_value && "number" === typeof input3.original_p_value && "number" === typeof input3.fold_change && "string" === typeof input3.gene_name && "string" === typeof input3.gene_symbol;
78
+ const $io1 = (input3) => "number" === typeof input3.adjusted_p_value && "number" === typeof input3.original_p_value && "number" === typeof input3.fold_change && "string" === typeof input3.gene_id && "string" === typeof input3.gene_name;
79
79
  const $io2 = (input3) => "string" === typeof input3.src && "number" === typeof input3.size && "string" === typeof input3.key;
80
80
  return "object" === typeof input2 && null !== input2 && $io0(input2);
81
81
  };
@@ -139,14 +139,14 @@ var validDEResponse = (input) => {
139
139
  path: _path2 + ".fold_change",
140
140
  expected: "number",
141
141
  value: input3.fold_change
142
+ }), "string" === typeof input3.gene_id || $report(_exceptionable2, {
143
+ path: _path2 + ".gene_id",
144
+ expected: "string",
145
+ value: input3.gene_id
142
146
  }), "string" === typeof input3.gene_name || $report(_exceptionable2, {
143
147
  path: _path2 + ".gene_name",
144
148
  expected: "string",
145
149
  value: input3.gene_name
146
- }), "string" === typeof input3.gene_symbol || $report(_exceptionable2, {
147
- path: _path2 + ".gene_symbol",
148
- expected: "string",
149
- value: input3.gene_symbol
150
150
  })].every((flag) => flag);
151
151
  const $vo2 = (input3, _path2, _exceptionable2 = true) => ["string" === typeof input3.src || $report(_exceptionable2, {
152
152
  path: _path2 + ".src",
@@ -65,7 +65,7 @@ var validSampleWSImagesResponse = (input) => {
65
65
  const errors = [];
66
66
  const __is = (input2) => {
67
67
  const $io0 = (input3) => Array.isArray(input3.sampleWSImages) && input3.sampleWSImages.every((elem) => "object" === typeof elem && null !== elem && $io1(elem));
68
- const $io1 = (input3) => "string" === typeof input3.filename && "string" === typeof input3.metadata;
68
+ const $io1 = (input3) => "string" === typeof input3.filename && (void 0 === input3.overlays || Array.isArray(input3.overlays) && input3.overlays.every((elem) => "string" === typeof elem)) && "string" === typeof input3.metadata;
69
69
  return "object" === typeof input2 && null !== input2 && $io0(input2);
70
70
  };
71
71
  if (false === __is(input)) {
@@ -92,6 +92,18 @@ var validSampleWSImagesResponse = (input) => {
92
92
  path: _path2 + ".filename",
93
93
  expected: "string",
94
94
  value: input3.filename
95
+ }), void 0 === input3.overlays || (Array.isArray(input3.overlays) || $report(_exceptionable2, {
96
+ path: _path2 + ".overlays",
97
+ expected: "(Array<string> | undefined)",
98
+ value: input3.overlays
99
+ })) && input3.overlays.map((elem, _index2) => "string" === typeof elem || $report(_exceptionable2, {
100
+ path: _path2 + ".overlays[" + _index2 + "]",
101
+ expected: "string",
102
+ value: elem
103
+ })).every((flag) => flag) || $report(_exceptionable2, {
104
+ path: _path2 + ".overlays",
105
+ expected: "(Array<string> | undefined)",
106
+ value: input3.overlays
95
107
  }), "string" === typeof input3.metadata || $report(_exceptionable2, {
96
108
  path: _path2 + ".metadata",
97
109
  expected: "string",
package/dist/index.js CHANGED
@@ -82,7 +82,7 @@ import {
82
82
  diffExpPayload,
83
83
  validDERequest,
84
84
  validDEResponse
85
- } from "./chunk-3QALQGW4.js";
85
+ } from "./chunk-3C26VWPU.js";
86
86
  import {
87
87
  boxplotPayload,
88
88
  validBoxPlotRequest,
@@ -147,7 +147,7 @@ import {
147
147
  sampleWSImagesPayload,
148
148
  validSampleWSImagesRequest,
149
149
  validSampleWSImagesResponse
150
- } from "./chunk-W4JULXYD.js";
150
+ } from "./chunk-HURSYPTO.js";
151
151
  import {
152
152
  snpPayload,
153
153
  validSnpRequest,
@@ -2,7 +2,7 @@ import {
2
2
  sampleWSImagesPayload,
3
3
  validSampleWSImagesRequest,
4
4
  validSampleWSImagesResponse
5
- } from "./chunk-W4JULXYD.js";
5
+ } from "./chunk-HURSYPTO.js";
6
6
  import "./chunk-CNSSF43V.js";
7
7
  export {
8
8
  sampleWSImagesPayload,
package/dist/termdb.DE.js CHANGED
@@ -2,7 +2,7 @@ import {
2
2
  diffExpPayload,
3
3
  validDERequest,
4
4
  validDEResponse
5
- } from "./chunk-3QALQGW4.js";
5
+ } from "./chunk-3C26VWPU.js";
6
6
  import "./chunk-CNSSF43V.js";
7
7
  export {
8
8
  diffExpPayload,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sjcrh/proteinpaint-types",
3
- "version": "2.118.3-2",
3
+ "version": "2.119.0",
4
4
  "type": "module",
5
5
  "description": "Shared type definitions between ProteinPaint server and client code",
6
6
  "main": "src/index.ts",
package/src/dataset.ts CHANGED
@@ -580,14 +580,22 @@ type CnvSegment = {
580
580
  /** presence of these properties indicate cnv is quantified as log(ratio) or similar
581
581
  filter segments by following two cutoffs only apply to log ratio, cnv gain value is positive, cnv loss value is negative
582
582
  samples with all events filtered out should be treated as wildtype
583
+
584
+ - if m.value>0, skip m if m.value<this cutoff
585
+ - set to 0 to not filtering and show all gain events
586
+ - set to a large value e.g. 99 to hide all gain events
583
587
  */
584
- /** if value>0, skip if value<this cutoff, set to a large value e.g. 100 for not filtering */
585
588
  cnvGainCutoff?: number
586
- /** if value<0, skip if value>this cutoff, set to a large negative value e.g. -100 for not filtering */
589
+ /*
590
+ - if m.value<0, skip m if m.value>this cutoff
591
+ - set to 0 to not filtering and show all loss events
592
+ - set to a large negative value e.g. -99 to hide all loss events
593
+ */
587
594
  cnvLossCutoff?: number
588
595
 
589
596
  /** presence of these properties indicate cnv is quantified as integer copy number
590
597
  * not in use yet *
598
+ enable when there's such data
591
599
  cnvMinCopynumber?: number
592
600
  cnvMaxCopynumber?: number
593
601
  */
@@ -930,10 +938,14 @@ export type WSImages = {
930
938
  */
931
939
  imageBySampleFolder: string
932
940
 
941
+ annotationsColor?: Array<number>
942
+
933
943
  /** either ds supplied or dynamically added on launch with built in logic (retrieve the sample list from the wsimages table) */
934
944
  getSamples?: () => Promise<Array<WSISample>>
935
945
  /** either ds supplied or dynamically added on launch with built in logic */
936
946
  getWSImages?: (sampleName: string) => Promise<WSImage[]>
947
+ /** ds supplied */
948
+ getWSIAnnotations?: (sampleName: string, wsiImage: string) => Promise<string[]>
937
949
  }
938
950
 
939
951
  /*** types supporting Termdb ***/
@@ -1310,6 +1322,8 @@ keep this setting here for reason of:
1310
1322
  sample?: UrlTemplateBase
1311
1323
  /** ssm link definition */
1312
1324
  ssm?: UrlTemplateSsm | UrlTemplateSsm[]
1325
+ /** allow to add link to "Experiment" field of singlecell app sample table */
1326
+ scrnaExperimentId?: UrlTemplateBase
1313
1327
  }
1314
1328
 
1315
1329
  termtypeByCohort?: any // FIXME see below
@@ -13,6 +13,7 @@ export type SampleWSImagesResponse = {
13
13
 
14
14
  export type WSImage = {
15
15
  filename: string
16
+ overlays?: Array<string>
16
17
  metadata: string
17
18
  }
18
19
 
@@ -70,8 +70,8 @@ export type DataEntry = {
70
70
  adjusted_p_value: number
71
71
  original_p_value: number
72
72
  fold_change: number
73
+ gene_id: string
73
74
  gene_name: string
74
- gene_symbol: string
75
75
  }
76
76
 
77
77
  export type DEImage = {