react-mutation-mapper 0.8.29 → 0.8.34
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/dist/component/column/Annotation.d.ts +2 -0
- package/dist/component/column/Signal.d.ts +5 -4
- package/dist/component/oncokb/OncoKB.d.ts +2 -1
- package/dist/component/track/ExonTrack.d.ts +2 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.es.js +156 -46
- package/dist/index.es.js.map +1 -1
- package/dist/index.js +161 -50
- package/dist/index.js.map +1 -1
- package/dist/model/MutationMapperStore.d.ts +2 -0
- package/dist/store/DefaultMutationMapperStore.d.ts +3 -0
- package/package.json +6 -6
package/dist/index.js
CHANGED
|
@@ -24,7 +24,8 @@ var Select = require('react-select');
|
|
|
24
24
|
var Select__default = _interopDefault(Select);
|
|
25
25
|
var $ = _interopDefault(require('jquery'));
|
|
26
26
|
var Slider = _interopDefault(require('react-rangeslider'));
|
|
27
|
-
var request =
|
|
27
|
+
var request = require('superagent');
|
|
28
|
+
var request__default = _interopDefault(request);
|
|
28
29
|
var memoize = _interopDefault(require('memoize-weak-decorator'));
|
|
29
30
|
var mobxpromise = require('mobxpromise');
|
|
30
31
|
|
|
@@ -1867,17 +1868,11 @@ var OncoKB = /** @class */ (function (_super) {
|
|
|
1867
1868
|
].map(function (dataType) { return (React.createElement(AnnotationIcon, { type: dataType, tooltipOverlay: _this.tooltipContent(dataType), indicator: _this.props.indicator, availableDataTypes: _this.props.availableDataTypes })); })));
|
|
1868
1869
|
}
|
|
1869
1870
|
else {
|
|
1870
|
-
//
|
|
1871
|
-
//
|
|
1872
|
-
//
|
|
1873
|
-
//
|
|
1874
|
-
|
|
1875
|
-
// {this.props.availableDataTypes?.map(() => (
|
|
1876
|
-
// <AnnotationIconWithTooltip icon={<i />} />
|
|
1877
|
-
// ))}
|
|
1878
|
-
// </>
|
|
1879
|
-
// );
|
|
1880
|
-
return null;
|
|
1871
|
+
// workaround: use content padding value to draw an empty icon when there is no indicator data.
|
|
1872
|
+
// this is to keep the icon alignment consistent with the rest of the column.
|
|
1873
|
+
// ideally we should implement grouped columns to avoid these kind of workarounds
|
|
1874
|
+
// (see https://github.com/cBioPortal/cbioportal/issues/8723)
|
|
1875
|
+
return React.createElement("i", { style: { paddingRight: this.props.contentPadding } });
|
|
1881
1876
|
}
|
|
1882
1877
|
}
|
|
1883
1878
|
});
|
|
@@ -2305,9 +2300,9 @@ function sortValue$4(annotation) {
|
|
|
2305
2300
|
]);
|
|
2306
2301
|
}
|
|
2307
2302
|
function GenericAnnotation(props) {
|
|
2308
|
-
var annotation = props.annotation, enableCivic = props.enableCivic, enableHotspot = props.enableHotspot, enableMyCancerGenome = props.enableMyCancerGenome, enableOncoKb = props.enableOncoKb, pubMedCache = props.pubMedCache, userEmailAddress = props.userEmailAddress, mergeOncoKbIcons = props.mergeOncoKbIcons;
|
|
2303
|
+
var annotation = props.annotation, enableCivic = props.enableCivic, enableHotspot = props.enableHotspot, enableMyCancerGenome = props.enableMyCancerGenome, enableOncoKb = props.enableOncoKb, pubMedCache = props.pubMedCache, userEmailAddress = props.userEmailAddress, mergeOncoKbIcons = props.mergeOncoKbIcons, oncoKbContentPadding = props.oncoKbContentPadding;
|
|
2309
2304
|
return (React.createElement("span", { style: { display: 'flex', minWidth: 100 } },
|
|
2310
|
-
enableOncoKb && (React.createElement(OncoKB, { usingPublicOncoKbInstance: annotation.usingPublicOncoKbInstance, hugoGeneSymbol: annotation.hugoGeneSymbol, geneNotExist: !annotation.oncoKbGeneExist, isCancerGene: annotation.isOncoKbCancerGene, status: annotation.oncoKbStatus, indicator: annotation.oncoKbIndicator, availableDataTypes: annotation.oncoKbAvailableDataTypes, mergeAnnotationIcons: mergeOncoKbIcons, pubMedCache: pubMedCache, userEmailAddress: userEmailAddress })),
|
|
2305
|
+
enableOncoKb && (React.createElement(OncoKB, { usingPublicOncoKbInstance: annotation.usingPublicOncoKbInstance, hugoGeneSymbol: annotation.hugoGeneSymbol, geneNotExist: !annotation.oncoKbGeneExist, isCancerGene: annotation.isOncoKbCancerGene, status: annotation.oncoKbStatus, indicator: annotation.oncoKbIndicator, availableDataTypes: annotation.oncoKbAvailableDataTypes, mergeAnnotationIcons: mergeOncoKbIcons, pubMedCache: pubMedCache, userEmailAddress: userEmailAddress, contentPadding: oncoKbContentPadding })),
|
|
2311
2306
|
enableCivic && (React.createElement(Civic, { civicEntry: annotation.civicEntry, civicStatus: annotation.civicStatus, hasCivicVariants: annotation.hasCivicVariants })),
|
|
2312
2307
|
enableMyCancerGenome && (React.createElement(MyCancerGenome, { linksHTML: annotation.myCancerGenomeLinks })),
|
|
2313
2308
|
enableHotspot && (React.createElement(HotspotAnnotation, { isHotspot: annotation.isHotspot, is3dHotspot: annotation.is3dHotspot, status: annotation.hotspotStatus }))));
|
|
@@ -3166,8 +3161,9 @@ var ProteinChange = /** @class */ (function (_super) {
|
|
|
3166
3161
|
return ProteinChange;
|
|
3167
3162
|
}(React.Component));
|
|
3168
3163
|
|
|
3169
|
-
function getSignalData(mutation, indexedVariantAnnotations
|
|
3170
|
-
|
|
3164
|
+
function getSignalData(mutation, indexedVariantAnnotations, mutationType // mutationType could be "germline", "somatic", or "undefined" which means both
|
|
3165
|
+
) {
|
|
3166
|
+
var signalData = [];
|
|
3171
3167
|
var variantAnnotation = indexedVariantAnnotations
|
|
3172
3168
|
? cbioportalUtils.getVariantAnnotation(mutation, indexedVariantAnnotations.result)
|
|
3173
3169
|
: undefined;
|
|
@@ -3175,12 +3171,37 @@ function getSignalData(mutation, indexedVariantAnnotations) {
|
|
|
3175
3171
|
variantAnnotation.signalAnnotation &&
|
|
3176
3172
|
variantAnnotation.signalAnnotation.annotation &&
|
|
3177
3173
|
variantAnnotation.signalAnnotation.annotation.length > 0) {
|
|
3178
|
-
|
|
3179
|
-
|
|
3180
|
-
if (
|
|
3181
|
-
|
|
3174
|
+
// if mutation is somatic OR germline, get annotation depending on mutationType
|
|
3175
|
+
if (variantAnnotation.signalAnnotation.annotation.length === 1) {
|
|
3176
|
+
if ((mutationType === cbioportalUtils.Pathogenicity.GERMLINE &&
|
|
3177
|
+
variantAnnotation.signalAnnotation.annotation[0].mutationStatus.includes('germline')) ||
|
|
3178
|
+
(mutationType === cbioportalUtils.Pathogenicity.SOMATIC &&
|
|
3179
|
+
variantAnnotation.signalAnnotation.annotation[0].mutationStatus.includes('somatic'))) {
|
|
3180
|
+
signalData = cbioportalUtils.extendMutations([
|
|
3181
|
+
variantAnnotation.signalAnnotation.annotation[0],
|
|
3182
|
+
]);
|
|
3183
|
+
}
|
|
3184
|
+
}
|
|
3185
|
+
// if mutation is both somatic AND germline, get annotation for both or get one of them depending on mutationType
|
|
3186
|
+
else {
|
|
3187
|
+
// if mutationType is undefined, get annotation for both somatic and germline
|
|
3188
|
+
if (mutationType === undefined) {
|
|
3189
|
+
signalData = cbioportalUtils.extendMutations(variantAnnotation.signalAnnotation.annotation);
|
|
3182
3190
|
}
|
|
3183
|
-
|
|
3191
|
+
// if mutationType is defined, get annotation depending on mutationType
|
|
3192
|
+
else {
|
|
3193
|
+
variantAnnotation.signalAnnotation.annotation.forEach(function (annotation) {
|
|
3194
|
+
if (mutationType === cbioportalUtils.Pathogenicity.GERMLINE &&
|
|
3195
|
+
annotation.mutationStatus.includes('germline')) {
|
|
3196
|
+
signalData = cbioportalUtils.extendMutations([annotation]);
|
|
3197
|
+
}
|
|
3198
|
+
else if (mutationType === cbioportalUtils.Pathogenicity.SOMATIC &&
|
|
3199
|
+
annotation.mutationStatus.includes('somatic')) {
|
|
3200
|
+
signalData = cbioportalUtils.extendMutations([annotation]);
|
|
3201
|
+
}
|
|
3202
|
+
});
|
|
3203
|
+
}
|
|
3204
|
+
}
|
|
3184
3205
|
}
|
|
3185
3206
|
return signalData;
|
|
3186
3207
|
}
|
|
@@ -3188,25 +3209,29 @@ function signalSortMethod(a, b) {
|
|
|
3188
3209
|
return cbioportalUtils.defaultSortMethod(getSortValue(a), getSortValue(b));
|
|
3189
3210
|
}
|
|
3190
3211
|
function getSortValue(signalData) {
|
|
3191
|
-
return signalData.germlineFrequency || null;
|
|
3212
|
+
return signalData ? signalData.germlineFrequency || null : null;
|
|
3192
3213
|
}
|
|
3193
|
-
function download$7(signalData) {
|
|
3194
|
-
return signalData.germlineFrequency
|
|
3214
|
+
function download$7(signalData, mutationType) {
|
|
3215
|
+
return signalData && signalData.germlineFrequency !== null
|
|
3195
3216
|
? "" + cbioportalUtils.formatNumberValueInSignificantDigits(signalData.germlineFrequency, 2)
|
|
3196
3217
|
: '';
|
|
3197
3218
|
}
|
|
3198
|
-
|
|
3199
|
-
|
|
3200
|
-
|
|
3201
|
-
|
|
3219
|
+
// Get germline OR somatic frequency value
|
|
3220
|
+
function getSingleSignalValue(mutation, mutationType, indexedVariantAnnotations, significantDigits) {
|
|
3221
|
+
var signalData = getSignalData(mutation, indexedVariantAnnotations, mutationType);
|
|
3222
|
+
if (signalData &&
|
|
3223
|
+
signalData.length === 1 &&
|
|
3224
|
+
signalData[0].tumorTypeDecomposition) {
|
|
3225
|
+
return cbioportalUtils.formatNumberValueInSignificantDigits(signalData[0].germlineFrequency || signalData[0].somaticFrequency, significantDigits || 2);
|
|
3202
3226
|
}
|
|
3203
3227
|
else {
|
|
3204
3228
|
return null;
|
|
3205
3229
|
}
|
|
3206
3230
|
}
|
|
3207
3231
|
var SignalTable = function (props) {
|
|
3208
|
-
|
|
3209
|
-
|
|
3232
|
+
// signal data should be either germline or somatic, so should be only one element
|
|
3233
|
+
var signalData = getSignalData(props.mutation, props.indexedVariantAnnotations, props.mutationType)[0];
|
|
3234
|
+
if (getSingleSignalValue(props.mutation, props.mutationType || cbioportalUtils.Pathogenicity.GERMLINE, props.indexedVariantAnnotations) !== null) {
|
|
3210
3235
|
return (React.createElement(cbioportalFrontendCommons.MutationTumorTypeFrequencyTable, { data: cbioportalUtils.generateTumorTypeDecomposition(signalData, signalData.countsByTumorType, signalData.biallelicCountsByTumorType, signalData.qcPassCountsByTumorType, signalData.statsByTumorType), columns: [
|
|
3211
3236
|
cbioportalFrontendCommons.FREQUENCY_COLUMNS_DEFINITION[cbioportalFrontendCommons.FrequencyTableColumnEnum.TUMOR_TYPE],
|
|
3212
3237
|
cbioportalFrontendCommons.FREQUENCY_COLUMNS_DEFINITION[cbioportalFrontendCommons.FrequencyTableColumnEnum.MUTATION_STATUS],
|
|
@@ -3247,11 +3272,11 @@ var Signal = /** @class */ (function (_super) {
|
|
|
3247
3272
|
}
|
|
3248
3273
|
else {
|
|
3249
3274
|
content = React.createElement("div", null);
|
|
3250
|
-
var signalValue =
|
|
3275
|
+
var signalValue = getSingleSignalValue(this.props.mutation, this.props.mutationType || cbioportalUtils.Pathogenicity.GERMLINE, this.props.indexedVariantAnnotations);
|
|
3251
3276
|
if (signalValue !== null) {
|
|
3252
3277
|
content = (React.createElement(cbioportalFrontendCommons.DefaultTooltip, { placement: "top", overlayStyle: {
|
|
3253
3278
|
width: 800,
|
|
3254
|
-
}, overlay: React.createElement(SignalTable, { mutation: this.props.mutation, indexedVariantAnnotations: this.props.indexedVariantAnnotations }) },
|
|
3279
|
+
}, overlay: React.createElement(SignalTable, { mutation: this.props.mutation, indexedVariantAnnotations: this.props.indexedVariantAnnotations, mutationType: this.props.mutationType }) },
|
|
3255
3280
|
React.createElement("span", null, signalValue)));
|
|
3256
3281
|
}
|
|
3257
3282
|
}
|
|
@@ -5195,7 +5220,7 @@ var DefaultMutationTable = /** @class */ (function (_super) {
|
|
|
5195
5220
|
return this.indexedVariantAnnotationDataStatus === 'pending'
|
|
5196
5221
|
? function () { return undefined; }
|
|
5197
5222
|
: function (mutation) {
|
|
5198
|
-
return getSignalData(mutation, _this.props.indexedVariantAnnotations);
|
|
5223
|
+
return getSignalData(mutation, _this.props.indexedVariantAnnotations, cbioportalUtils.Pathogenicity.GERMLINE)[0];
|
|
5199
5224
|
};
|
|
5200
5225
|
},
|
|
5201
5226
|
enumerable: false,
|
|
@@ -5265,7 +5290,7 @@ var DefaultMutationTable = /** @class */ (function (_super) {
|
|
|
5265
5290
|
case exports.MutationColumn.DBSNP:
|
|
5266
5291
|
return function (column) { return (React.createElement(Dbsnp, { mutation: column.original, indexedMyVariantInfoAnnotations: _this.props.indexedMyVariantInfoAnnotations })); };
|
|
5267
5292
|
case exports.MutationColumn.SIGNAL:
|
|
5268
|
-
return function (column) { return (React.createElement(Signal, { mutation: column.original, indexedVariantAnnotations: _this.props.indexedVariantAnnotations })); };
|
|
5293
|
+
return function (column) { return (React.createElement(Signal, { mutation: column.original, indexedVariantAnnotations: _this.props.indexedVariantAnnotations, mutationType: cbioportalUtils.Pathogenicity.GERMLINE })); };
|
|
5269
5294
|
default:
|
|
5270
5295
|
return undefined;
|
|
5271
5296
|
}
|
|
@@ -8446,8 +8471,24 @@ var ExonTrack = /** @class */ (function (_super) {
|
|
|
8446
8471
|
enumerable: false,
|
|
8447
8472
|
configurable: true
|
|
8448
8473
|
});
|
|
8474
|
+
Object.defineProperty(ExonTrack.prototype, "chromosome", {
|
|
8475
|
+
get: function () {
|
|
8476
|
+
var _a, _b;
|
|
8477
|
+
return (_b = (_a = this.props.store.ensemblTranscriptLookUp.result) === null || _a === void 0 ? void 0 : _a.body) === null || _b === void 0 ? void 0 : _b.seq_region_name;
|
|
8478
|
+
},
|
|
8479
|
+
enumerable: false,
|
|
8480
|
+
configurable: true
|
|
8481
|
+
});
|
|
8482
|
+
Object.defineProperty(ExonTrack.prototype, "genomeBuild", {
|
|
8483
|
+
get: function () {
|
|
8484
|
+
return this.props.store.genomeBuild;
|
|
8485
|
+
},
|
|
8486
|
+
enumerable: false,
|
|
8487
|
+
configurable: true
|
|
8488
|
+
});
|
|
8449
8489
|
Object.defineProperty(ExonTrack.prototype, "exonSpecs", {
|
|
8450
8490
|
get: function () {
|
|
8491
|
+
var _this = this;
|
|
8451
8492
|
if (!this.transcriptId || !this.transcript) {
|
|
8452
8493
|
return [];
|
|
8453
8494
|
}
|
|
@@ -8461,10 +8502,15 @@ var ExonTrack = /** @class */ (function (_super) {
|
|
|
8461
8502
|
? exonInfo.map(function (exon, index) {
|
|
8462
8503
|
var startCodon = exon.start;
|
|
8463
8504
|
var endCodon = exon.start + exon.length;
|
|
8464
|
-
var
|
|
8465
|
-
var
|
|
8466
|
-
var
|
|
8467
|
-
var
|
|
8505
|
+
var exonStartLocation = cbioportalUtils.formatExonLocation(startCodon, index);
|
|
8506
|
+
var exonEndLocation = cbioportalUtils.formatExonLocation(endCodon);
|
|
8507
|
+
var exonLength = cbioportalUtils.formatExonLength(exon.length);
|
|
8508
|
+
var link = _this.chromosome
|
|
8509
|
+
? "https://igv.org/app/?locus=chr" + _this.chromosome + ":" + exon.genomicLocationStart + "-" + exon.genomicLocationEnd + "&genome=" + _this.genomeBuild
|
|
8510
|
+
: 'https://igv.org';
|
|
8511
|
+
var linkText = _this.chromosome
|
|
8512
|
+
? _this.genomeBuild + ":chr" + _this.chromosome + ":" + exon.genomicLocationStart + " - " + exon.genomicLocationEnd
|
|
8513
|
+
: exon.genomicLocationStart + " - " + exon.genomicLocationEnd;
|
|
8468
8514
|
return {
|
|
8469
8515
|
color: altColors[index % 2],
|
|
8470
8516
|
startCodon: startCodon,
|
|
@@ -8476,14 +8522,41 @@ var ExonTrack = /** @class */ (function (_super) {
|
|
|
8476
8522
|
" Exon ",
|
|
8477
8523
|
exon.rank,
|
|
8478
8524
|
" "),
|
|
8479
|
-
"Start: ",
|
|
8480
|
-
|
|
8525
|
+
"Start: Nucleotide",
|
|
8526
|
+
' ',
|
|
8527
|
+
React.createElement("strong", null, exonStartLocation.nucleotideLocation),
|
|
8528
|
+
' ',
|
|
8529
|
+
"of amino acid",
|
|
8530
|
+
' ',
|
|
8531
|
+
React.createElement("strong", null, exonStartLocation.aminoAcidLocation),
|
|
8481
8532
|
React.createElement("br", null),
|
|
8482
|
-
"End: ",
|
|
8483
|
-
|
|
8533
|
+
"End: Nucleotide",
|
|
8534
|
+
' ',
|
|
8535
|
+
React.createElement("strong", null, exonEndLocation.nucleotideLocation),
|
|
8536
|
+
' ',
|
|
8537
|
+
"of amino acid",
|
|
8538
|
+
' ',
|
|
8539
|
+
React.createElement("strong", null, exonEndLocation.aminoAcidLocation),
|
|
8540
|
+
React.createElement("br", null),
|
|
8541
|
+
"Length:",
|
|
8542
|
+
' ',
|
|
8543
|
+
React.createElement("strong", null, exonLength.aminoAcidLength),
|
|
8544
|
+
' ',
|
|
8545
|
+
"amino acids",
|
|
8546
|
+
' ',
|
|
8547
|
+
exonLength.nucleotideLength && (React.createElement(React.Fragment, null,
|
|
8548
|
+
' ',
|
|
8549
|
+
"and",
|
|
8550
|
+
' ',
|
|
8551
|
+
React.createElement("strong", null, exonLength.nucleotideLength),
|
|
8552
|
+
' ',
|
|
8553
|
+
"nucleotides")),
|
|
8484
8554
|
React.createElement("br", null),
|
|
8485
|
-
"
|
|
8486
|
-
|
|
8555
|
+
"Genomic location:", " ",
|
|
8556
|
+
React.createElement("a", { target: "_blank", href: link, rel: "noopener noreferrer" },
|
|
8557
|
+
React.createElement(React.Fragment, null,
|
|
8558
|
+
linkText, " ",
|
|
8559
|
+
React.createElement("i", { className: "fa fa-external-link" }))))),
|
|
8487
8560
|
};
|
|
8488
8561
|
})
|
|
8489
8562
|
: [];
|
|
@@ -8514,6 +8587,12 @@ var ExonTrack = /** @class */ (function (_super) {
|
|
|
8514
8587
|
__decorate([
|
|
8515
8588
|
mobx.computed
|
|
8516
8589
|
], ExonTrack.prototype, "transcript", null);
|
|
8590
|
+
__decorate([
|
|
8591
|
+
mobx.computed
|
|
8592
|
+
], ExonTrack.prototype, "chromosome", null);
|
|
8593
|
+
__decorate([
|
|
8594
|
+
mobx.computed
|
|
8595
|
+
], ExonTrack.prototype, "genomeBuild", null);
|
|
8517
8596
|
__decorate([
|
|
8518
8597
|
mobx.computed
|
|
8519
8598
|
], ExonTrack.prototype, "exonSpecs", null);
|
|
@@ -10134,7 +10213,7 @@ var DefaultPubMedCache = /** @class */ (function (_super) {
|
|
|
10134
10213
|
switch (_a.label) {
|
|
10135
10214
|
case 0: return [4 /*yield*/, new Promise(function (resolve, reject) {
|
|
10136
10215
|
// TODO duplicate code from cbioportal-frontend
|
|
10137
|
-
|
|
10216
|
+
request__default
|
|
10138
10217
|
.post('https://eutils.ncbi.nlm.nih.gov/entrez/eutils/esummary.fcgi?db=pubmed&retmode=json')
|
|
10139
10218
|
.type('form')
|
|
10140
10219
|
.send({ id: query })
|
|
@@ -10168,7 +10247,7 @@ var DefaultPubMedCache = /** @class */ (function (_super) {
|
|
|
10168
10247
|
|
|
10169
10248
|
function fetchMutationAlignerLink(pfamDomainId, mutationAlignerUrlTemplate) {
|
|
10170
10249
|
if (mutationAlignerUrlTemplate === void 0) { mutationAlignerUrlTemplate = DEFAULT_MUTATION_ALIGNER_PROXY_URL_TEMPLATE; }
|
|
10171
|
-
return
|
|
10250
|
+
return request__default
|
|
10172
10251
|
.get(getUrl(mutationAlignerUrlTemplate, { pfamDomainId: pfamDomainId }))
|
|
10173
10252
|
.accept('application/json');
|
|
10174
10253
|
}
|
|
@@ -10544,7 +10623,7 @@ var DefaultMutationMapperDataFetcher = /** @class */ (function () {
|
|
|
10544
10623
|
var myGeneData;
|
|
10545
10624
|
return __generator(this, function (_a) {
|
|
10546
10625
|
switch (_a.label) {
|
|
10547
|
-
case 0: return [4 /*yield*/,
|
|
10626
|
+
case 0: return [4 /*yield*/, request__default.get(getUrl(this.config.myGeneUrlTemplate || DEFAULT_MY_GENE_URL_TEMPLATE, { entrezGeneId: entrezGeneId }))];
|
|
10548
10627
|
case 1:
|
|
10549
10628
|
myGeneData = _a.sent();
|
|
10550
10629
|
return [2 /*return*/, JSON.parse(myGeneData.text).uniprot['Swiss-Prot']];
|
|
@@ -10562,7 +10641,7 @@ var DefaultMutationMapperDataFetcher = /** @class */ (function () {
|
|
|
10562
10641
|
var uniprotData;
|
|
10563
10642
|
return __generator(this, function (_a) {
|
|
10564
10643
|
switch (_a.label) {
|
|
10565
|
-
case 0: return [4 /*yield*/,
|
|
10644
|
+
case 0: return [4 /*yield*/, request__default.get(getUrl(this.config.uniprotIdUrlTemplate ||
|
|
10566
10645
|
DEFAULT_UNIPROT_ID_URL_TEMPLATE, { swissProtAccession: swissProtAccession }))];
|
|
10567
10646
|
case 1:
|
|
10568
10647
|
uniprotData = _a.sent();
|
|
@@ -10720,7 +10799,7 @@ var DefaultMutationMapperDataFetcher = /** @class */ (function () {
|
|
|
10720
10799
|
switch (_a.label) {
|
|
10721
10800
|
case 0:
|
|
10722
10801
|
if (!swissProtId) return [3 /*break*/, 2];
|
|
10723
|
-
return [4 /*yield*/,
|
|
10802
|
+
return [4 /*yield*/, request__default.get(getUrl("https://www.ebi.ac.uk/proteins/api/features/<%= uniprotAccession %>?categories=" + category.join(','), { uniprotAccession: swissProtId }))];
|
|
10724
10803
|
case 1:
|
|
10725
10804
|
uniprotData = _a.sent();
|
|
10726
10805
|
featureList = JSON.parse(uniprotData.text);
|
|
@@ -11703,6 +11782,28 @@ var DefaultMutationMapperStore = /** @class */ (function () {
|
|
|
11703
11782
|
},
|
|
11704
11783
|
})
|
|
11705
11784
|
});
|
|
11785
|
+
Object.defineProperty(this, "ensemblTranscriptLookUp", {
|
|
11786
|
+
enumerable: true,
|
|
11787
|
+
configurable: true,
|
|
11788
|
+
writable: true,
|
|
11789
|
+
value: cbioportalFrontendCommons.remoteData({
|
|
11790
|
+
await: function () { return [_this.activeTranscript]; },
|
|
11791
|
+
invoke: function () { return __awaiter(_this, void 0, void 0, function () {
|
|
11792
|
+
var ensemblTranscriptLookUpLink;
|
|
11793
|
+
return __generator(this, function (_a) {
|
|
11794
|
+
ensemblTranscriptLookUpLink = this.genomeBuild === 'hg19'
|
|
11795
|
+
? "https://grch37.rest.ensembl.org/lookup/id/" + this.activeTranscript.result + "?content-type=application/json"
|
|
11796
|
+
: "https://rest.ensembl.org/lookup/id/" + this.activeTranscript.result + "?content-type=application/json";
|
|
11797
|
+
return [2 /*return*/, this.activeTranscript.result
|
|
11798
|
+
? request.get(ensemblTranscriptLookUpLink)
|
|
11799
|
+
: undefined];
|
|
11800
|
+
});
|
|
11801
|
+
}); },
|
|
11802
|
+
onError: function () {
|
|
11803
|
+
// fail silently, leave the error handling responsibility to the data consumer
|
|
11804
|
+
},
|
|
11805
|
+
})
|
|
11806
|
+
});
|
|
11706
11807
|
mobx.makeObservable(this);
|
|
11707
11808
|
}
|
|
11708
11809
|
Object.defineProperty(DefaultMutationMapperStore.prototype, "selectedTranscript", {
|
|
@@ -12012,6 +12113,13 @@ var DefaultMutationMapperStore = /** @class */ (function () {
|
|
|
12012
12113
|
0);
|
|
12013
12114
|
}
|
|
12014
12115
|
});
|
|
12116
|
+
Object.defineProperty(DefaultMutationMapperStore.prototype, "genomeBuild", {
|
|
12117
|
+
get: function () {
|
|
12118
|
+
return this.config.genomeBuild || 'hg19';
|
|
12119
|
+
},
|
|
12120
|
+
enumerable: false,
|
|
12121
|
+
configurable: true
|
|
12122
|
+
});
|
|
12015
12123
|
__decorate([
|
|
12016
12124
|
mobx.observable
|
|
12017
12125
|
], DefaultMutationMapperStore.prototype, "_selectedTranscript", void 0);
|
|
@@ -12082,6 +12190,9 @@ var DefaultMutationMapperStore = /** @class */ (function () {
|
|
|
12082
12190
|
__decorate([
|
|
12083
12191
|
autobind
|
|
12084
12192
|
], DefaultMutationMapperStore.prototype, "getDefaultEntrezGeneId", null);
|
|
12193
|
+
__decorate([
|
|
12194
|
+
mobx.computed
|
|
12195
|
+
], DefaultMutationMapperStore.prototype, "genomeBuild", null);
|
|
12085
12196
|
return DefaultMutationMapperStore;
|
|
12086
12197
|
}());
|
|
12087
12198
|
|
|
@@ -12895,7 +13006,7 @@ exports.getProteinImpactTypeBadgeLabel = getProteinImpactTypeBadgeLabel;
|
|
|
12895
13006
|
exports.getProteinImpactTypeOptionLabel = getProteinImpactTypeOptionLabel;
|
|
12896
13007
|
exports.getSelectedOptionValues = getSelectedOptionValues;
|
|
12897
13008
|
exports.getSignalData = getSignalData;
|
|
12898
|
-
exports.
|
|
13009
|
+
exports.getSingleSignalValue = getSingleSignalValue;
|
|
12899
13010
|
exports.getUrl = getUrl;
|
|
12900
13011
|
exports.gnomadDownload = download$5;
|
|
12901
13012
|
exports.gnomadSortValue = sortValue$7;
|