@sjcrh/proteinpaint-types 2.163.0 → 2.163.1
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.
- package/package.json +1 -1
- package/src/dataset.ts +56 -11
package/package.json
CHANGED
package/src/dataset.ts
CHANGED
|
@@ -384,19 +384,12 @@ type SvFusion = {
|
|
|
384
384
|
}
|
|
385
385
|
|
|
386
386
|
type SingleSampleMutationQuery = {
|
|
387
|
-
/**
|
|
388
|
-
|
|
389
|
-
for non-native ds, the getter should return an json array with same structure
|
|
387
|
+
/** ds supplied getter
|
|
388
|
+
returns same json array as native. see example below
|
|
390
389
|
*/
|
|
391
|
-
|
|
392
|
-
/** which property of client mutation object to retrieve sample identifier for
|
|
393
|
-
* querying single sample data with */
|
|
390
|
+
get?: (f: any) => void
|
|
391
|
+
/** which property of client mutation object to retrieve sample identifier for querying single sample data with */
|
|
394
392
|
sample_id_key: string
|
|
395
|
-
/** only required for src=native
|
|
396
|
-
folder contains a set of files, one file per sample, file named by sample name
|
|
397
|
-
each file contains a stringified json array of mutation/cnv/sv entries (aka mlst)
|
|
398
|
-
*/
|
|
399
|
-
folder?: string
|
|
400
393
|
/** disco plot will be launched when singleSampleMutation is enabled. supply customization options here */
|
|
401
394
|
discoPlot?: {
|
|
402
395
|
/** if true, disco plot will hide chrM, due to reason e.g. this dataset doesn't have data on chrM */
|
|
@@ -404,6 +397,16 @@ type SingleSampleMutationQuery = {
|
|
|
404
397
|
/** if true, filter mutations by predefined geneset by default */
|
|
405
398
|
prioritizeGeneLabelsByGeneSets?: true
|
|
406
399
|
}
|
|
400
|
+
/** rest of properties are required for native ds without ds-supplied getter
|
|
401
|
+
TODO migrate gdc to get() and delete .src=native
|
|
402
|
+
*/
|
|
403
|
+
src?: 'native' | 'gdcapi' | string
|
|
404
|
+
/** only required for src=native
|
|
405
|
+
folder contains a set of files, one file per sample, file named by sample name
|
|
406
|
+
each file contains a stringified json array of mutation/cnv/sv entries (aka mlst). see example
|
|
407
|
+
https://github.com/stjude/proteinpaint/blob/master/server/test/tp/files/hg38/TermdbTest/mutationpersample/3318
|
|
408
|
+
*/
|
|
409
|
+
folder?: string
|
|
407
410
|
}
|
|
408
411
|
|
|
409
412
|
type NIdataQuery = {
|
|
@@ -1572,6 +1575,25 @@ keep this setting here for reason of:
|
|
|
1572
1575
|
isTermVisible?: (clientAuthResult: any, ids: string) => boolean
|
|
1573
1576
|
hiddenIds?: string[]
|
|
1574
1577
|
getAdditionalFilter?: (__protected__: any, term: any) => Filter | undefined
|
|
1578
|
+
/** collections of numeric dictionary terms that are related and can be used together in some plots
|
|
1579
|
+
*/
|
|
1580
|
+
numericTermCollections?: NumericTermCollection[]
|
|
1581
|
+
}
|
|
1582
|
+
|
|
1583
|
+
type NumericTermCollection = {
|
|
1584
|
+
/** human readable name for this collection */
|
|
1585
|
+
name: string
|
|
1586
|
+
/** array of dictionary numeric term ids belonging to this collection */
|
|
1587
|
+
termIds: string[]
|
|
1588
|
+
/** array of branch term ids belonging to this collection */
|
|
1589
|
+
branchIds: string[]
|
|
1590
|
+
/** preconfigured cohort-level plots for this collection */
|
|
1591
|
+
plots?: {
|
|
1592
|
+
/** name of this plot */
|
|
1593
|
+
name: string
|
|
1594
|
+
/** json file path of this plot */
|
|
1595
|
+
file: string
|
|
1596
|
+
}[]
|
|
1575
1597
|
}
|
|
1576
1598
|
|
|
1577
1599
|
type SampleType = {
|
|
@@ -1611,6 +1633,8 @@ type Variant2Samples = GdcApi & {
|
|
|
1611
1633
|
variantkey: string
|
|
1612
1634
|
twLst?: Tw[]
|
|
1613
1635
|
sunburst_twLst?: Tw[]
|
|
1636
|
+
/** ds-supplied getter */
|
|
1637
|
+
getMutatedSamples?: (q: any, ds: any) => void
|
|
1614
1638
|
}
|
|
1615
1639
|
|
|
1616
1640
|
type MutationSet = {
|
|
@@ -1922,6 +1946,21 @@ export type Mds3 = BaseMds & {
|
|
|
1922
1946
|
data during post-processing */
|
|
1923
1947
|
postProcessDtFilter?: boolean
|
|
1924
1948
|
}
|
|
1949
|
+
demoJwtInput?: {
|
|
1950
|
+
[role: string]: {
|
|
1951
|
+
datasets?: string[]
|
|
1952
|
+
clientAuthResult?: // sjcares, panMB, SJLife
|
|
1953
|
+
| ClientAuthResult
|
|
1954
|
+
// profile
|
|
1955
|
+
| {
|
|
1956
|
+
[cohort: string]: ClientAuthResult
|
|
1957
|
+
}
|
|
1958
|
+
// below will be assigned by /demoToken route handler if not specified
|
|
1959
|
+
iat?: number // jwt issued at time, unix time in seconds
|
|
1960
|
+
exp?: number // jwt expiration, unix time in seconds
|
|
1961
|
+
email?: string
|
|
1962
|
+
}
|
|
1963
|
+
}
|
|
1925
1964
|
// !!! TODO: improve these type definitions below !!!
|
|
1926
1965
|
getHostHeaders?: (q?: any) => any
|
|
1927
1966
|
serverconfigFeatures?: any
|
|
@@ -1930,6 +1969,12 @@ export type Mds3 = BaseMds & {
|
|
|
1930
1969
|
}
|
|
1931
1970
|
}
|
|
1932
1971
|
|
|
1972
|
+
export type ClientAuthResult = {
|
|
1973
|
+
role?: string
|
|
1974
|
+
datasets?: string[]
|
|
1975
|
+
sites?: string[]
|
|
1976
|
+
}
|
|
1977
|
+
|
|
1933
1978
|
export type Mds3WithCohort = Mds3 & {
|
|
1934
1979
|
cohort: Cohort
|
|
1935
1980
|
}
|