react-mutation-mapper 0.8.24 → 0.8.25

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/index.es.js CHANGED
@@ -8258,36 +8258,40 @@ var ExonTrack = /** @class */ (function (_super) {
8258
8258
  }
8259
8259
  var exons = this.transcript.exons;
8260
8260
  var utrs = this.transcript.utrs || [];
8261
- var exonInfo = extractExonInformation(exons, utrs, this.props.proteinLength);
8261
+ var exonInfo = exons
8262
+ ? extractExonInformation(exons, utrs, this.props.proteinLength)
8263
+ : undefined;
8262
8264
  var altColors = ['#007FFF', '#35BAF6'];
8263
- return exonInfo.map(function (exon, index) {
8264
- var startCodon = exon.start;
8265
- var endCodon = exon.start + exon.length;
8266
- var exonLength = exon.length;
8267
- var stringStart = formatExonLocation(startCodon);
8268
- var stringEnd = formatExonLocation(endCodon);
8269
- var stringLength = formatExonLocation(exonLength);
8270
- return {
8271
- color: altColors[index % 2],
8272
- startCodon: startCodon,
8273
- endCodon: endCodon,
8274
- label: exon.rank.toString(),
8275
- labelColor: '#FFFFFF',
8276
- tooltip: (createElement("span", null,
8277
- createElement("h5", null,
8278
- " Exon ",
8279
- exon.rank,
8280
- " "),
8281
- "Start: ",
8282
- stringStart,
8283
- createElement("br", null),
8284
- "End: ",
8285
- stringEnd,
8286
- createElement("br", null),
8287
- "Length: ",
8288
- stringLength)),
8289
- };
8290
- });
8265
+ return exonInfo
8266
+ ? exonInfo.map(function (exon, index) {
8267
+ var startCodon = exon.start;
8268
+ var endCodon = exon.start + exon.length;
8269
+ var exonLength = exon.length;
8270
+ var stringStart = formatExonLocation(startCodon);
8271
+ var stringEnd = formatExonLocation(endCodon);
8272
+ var stringLength = formatExonLocation(exonLength);
8273
+ return {
8274
+ color: altColors[index % 2],
8275
+ startCodon: startCodon,
8276
+ endCodon: endCodon,
8277
+ label: exon.rank.toString(),
8278
+ labelColor: '#FFFFFF',
8279
+ tooltip: (createElement("span", null,
8280
+ createElement("h5", null,
8281
+ " Exon ",
8282
+ exon.rank,
8283
+ " "),
8284
+ "Start: ",
8285
+ stringStart,
8286
+ createElement("br", null),
8287
+ "End: ",
8288
+ stringEnd,
8289
+ createElement("br", null),
8290
+ "Length: ",
8291
+ stringLength)),
8292
+ };
8293
+ })
8294
+ : [];
8291
8295
  },
8292
8296
  enumerable: false,
8293
8297
  configurable: true