react-mutation-mapper 0.8.27 → 0.8.32

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.js CHANGED
@@ -1867,17 +1867,11 @@ var OncoKB = /** @class */ (function (_super) {
1867
1867
  ].map(function (dataType) { return (React.createElement(AnnotationIcon, { type: dataType, tooltipOverlay: _this.tooltipContent(dataType), indicator: _this.props.indicator, availableDataTypes: _this.props.availableDataTypes })); })));
1868
1868
  }
1869
1869
  else {
1870
- // TODO This doesn't always work, in some cases it adds unnecessary empty icons, we need a better solution.
1871
- // we still need to draw empty icons even if there is no indicator data.
1872
- // this is to keep the icon alignment consistent with the rest of the column
1873
- // return (
1874
- // <>
1875
- // {this.props.availableDataTypes?.map(() => (
1876
- // <AnnotationIconWithTooltip icon={<i />} />
1877
- // ))}
1878
- // </>
1879
- // );
1880
- return null;
1870
+ // workaround: use content padding value to draw an empty icon when there is no indicator data.
1871
+ // this is to keep the icon alignment consistent with the rest of the column.
1872
+ // ideally we should implement grouped columns to avoid these kind of workarounds
1873
+ // (see https://github.com/cBioPortal/cbioportal/issues/8723)
1874
+ return React.createElement("i", { style: { paddingRight: this.props.contentPadding } });
1881
1875
  }
1882
1876
  }
1883
1877
  });
@@ -2305,9 +2299,9 @@ function sortValue$4(annotation) {
2305
2299
  ]);
2306
2300
  }
2307
2301
  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;
2302
+ 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
2303
  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 })),
2304
+ 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
2305
  enableCivic && (React.createElement(Civic, { civicEntry: annotation.civicEntry, civicStatus: annotation.civicStatus, hasCivicVariants: annotation.hasCivicVariants })),
2312
2306
  enableMyCancerGenome && (React.createElement(MyCancerGenome, { linksHTML: annotation.myCancerGenomeLinks })),
2313
2307
  enableHotspot && (React.createElement(HotspotAnnotation, { isHotspot: annotation.isHotspot, is3dHotspot: annotation.is3dHotspot, status: annotation.hotspotStatus }))));