@sjcrh/proteinpaint-client 2.190.2 → 2.191.2

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.
Files changed (932) hide show
  1. package/dist/2dmaf-V4WJ2LEK.js +1373 -0
  2. package/dist/AIProjectAdmin-JMN5O6YU.js +829 -0
  3. package/dist/AppHeader-Y4SEKCEF.js +835 -0
  4. package/dist/BoxPlot-ZXQZGCR3.js +1211 -0
  5. package/dist/BoxPlot-ZXQZGCR3.js.map +7 -0
  6. package/dist/CorrelationVolcano-R5IWD6WA.js +619 -0
  7. package/dist/DE-ZV6O7B6Y.js +95 -0
  8. package/dist/DEinput-FTOALZKN.js +301 -0
  9. package/dist/DifferentialAnalysis-NLCA766A.js +245 -0
  10. package/dist/Disco-Y5Z4A7GN.js +3237 -0
  11. package/dist/Disco.UI-GSWZYIUT.js +245 -0
  12. package/dist/DmrPlot-FEFUCIGT.js +642 -0
  13. package/dist/DziViewer-6737GC22.js +16332 -0
  14. package/dist/GB-AOXF2JJB.js +1130 -0
  15. package/dist/GeneExpInput-CXYRKQU7.js +366 -0
  16. package/dist/HicApp-GLNNZ4H5.js +2250 -0
  17. package/dist/NumBinaryEditor-6ZAL6CCP.js +271 -0
  18. package/dist/NumBinaryEditor-6ZAL6CCP.js.map +7 -0
  19. package/dist/NumBinaryEditor.unit.spec-3VTJLILH.js +286 -0
  20. package/dist/NumContEditor-3LOAR676.js +109 -0
  21. package/dist/NumContEditor-3LOAR676.js.map +7 -0
  22. package/dist/NumContEditor.unit.spec-WIMYCOVO.js +169 -0
  23. package/dist/NumCustomBinEditor-XIOAYWOD.js +38 -0
  24. package/dist/NumCustomBinEditor.unit.spec-N5OV6MKR.js +284 -0
  25. package/dist/NumDiscreteEditor-AT6FKYGI.js +179 -0
  26. package/dist/NumDiscreteEditor.unit.spec-BDR5GZ46.js +202 -0
  27. package/dist/NumRegularBinEditor-Z4NBS4VZ.js +38 -0
  28. package/dist/NumRegularBinEditor.unit.spec-BRWYNQ55.js +227 -0
  29. package/dist/NumSplineEditor-B45BAWQ2.js +198 -0
  30. package/dist/NumSplineEditor-B45BAWQ2.js.map +7 -0
  31. package/dist/NumSplineEditor.unit.spec-5RDBCZ4N.js +199 -0
  32. package/dist/NumericDensity-L7HIVV7D.js +38 -0
  33. package/dist/NumericDensity.unit.spec-PL3XDJCV.js +221 -0
  34. package/dist/NumericHandler-KJYZOCCG.js +39 -0
  35. package/dist/NumericHandler.unit.spec-VC7NPLJW.js +219 -0
  36. package/dist/ProteomeInput-A3GRPIAH.js +396 -0
  37. package/dist/RunChart2-MSNU3ZNT.js +758 -0
  38. package/dist/SC-FNKG2FK5.js +936 -0
  39. package/dist/Volcano-IRJMPHXJ.js +1379 -0
  40. package/dist/WSIViewer-KITT7I67.js +48475 -0
  41. package/dist/WsiSamplesPlot-G3YZ6SIE.js +165 -0
  42. package/dist/adSandbox-GIQTJ4VA.js +38 -0
  43. package/dist/app-MGNEMS2K.js +49 -0
  44. package/dist/app-UQTHPQFD.js +37 -0
  45. package/dist/app.js +17 -17
  46. package/dist/bam-5PROQBRT.js +860 -0
  47. package/dist/barchart-BQYJ73Z4.js +47 -0
  48. package/dist/barchart.data-VFULOIHY.js +22 -0
  49. package/dist/barchart.events-W2CIDD4B.js +47 -0
  50. package/dist/barchart.integration.spec-JF2IHFQE.js +1980 -0
  51. package/dist/barchart.integration.spec-JF2IHFQE.js.map +7 -0
  52. package/dist/barchart2-V6W4UAFH.js +311 -0
  53. package/dist/block-5V2FCT7Q.js +6202 -0
  54. package/dist/block.init-43IUNDNB.js +38 -0
  55. package/dist/block.mds.expressionrank-LI6MZPBE.js +359 -0
  56. package/dist/block.mds.geneboxplot-673AIJMJ.js +828 -0
  57. package/dist/block.mds.junction-UWNVNV3X.js +1545 -0
  58. package/dist/block.mds.svcnv-Z5VFCUUE.js +6801 -0
  59. package/dist/block.svg-MGK4GWLL.js +164 -0
  60. package/dist/block.tk.aicheck-OFNDGG7Q.js +283 -0
  61. package/dist/block.tk.ase-IDZQY7MW.js +365 -0
  62. package/dist/block.tk.bam-K7A2Q5NI.js +1906 -0
  63. package/dist/block.tk.bedgraphdot-PPTKCCPK.js +384 -0
  64. package/dist/block.tk.bigwig.ui-PI6EAU43.js +212 -0
  65. package/dist/block.tk.hicstraw-EZ2GS2K4.js +823 -0
  66. package/dist/block.tk.junction-4WSLQGSQ.js +2364 -0
  67. package/dist/block.tk.junction.textmatrixui-7EJUSVMB.js +199 -0
  68. package/dist/block.tk.ld-KLVO7M37.js +99 -0
  69. package/dist/block.tk.menu-KZSL7BAR.js +1029 -0
  70. package/dist/block.tk.pgv-NYWGB4VH.js +944 -0
  71. package/dist/brainImaging-MTIIMJHW.js +423 -0
  72. package/dist/chunk-2NQLAH3L.js +443 -0
  73. package/dist/chunk-2Q6PBSPS.js +1943 -0
  74. package/dist/chunk-2TCCXOAV.js +1170 -0
  75. package/dist/chunk-2TCCXOAV.js.map +7 -0
  76. package/dist/chunk-3D5GZIGG.js +1210 -0
  77. package/dist/chunk-3TPAIXNL.js +263 -0
  78. package/dist/chunk-42EBECOD.js +95 -0
  79. package/dist/chunk-4B42QV34.js +2786 -0
  80. package/dist/chunk-4FKWINMK.js +184 -0
  81. package/dist/chunk-4FKWINMK.js.map +7 -0
  82. package/dist/chunk-4KY4XKJV.js +143 -0
  83. package/dist/chunk-52RORO74.js +158 -0
  84. package/dist/chunk-52RORO74.js.map +7 -0
  85. package/dist/chunk-5SXCIKYV.js +100 -0
  86. package/dist/chunk-647P2I4Q.js +482 -0
  87. package/dist/chunk-67HSIHPP.js +2327 -0
  88. package/dist/chunk-6GZJCSA6.js +1102 -0
  89. package/dist/chunk-6VKTEMFV.js +1815 -0
  90. package/dist/chunk-6VKTEMFV.js.map +7 -0
  91. package/dist/chunk-7JEKUSEL.js +102 -0
  92. package/dist/chunk-BMO6KSVC.js +477 -0
  93. package/dist/chunk-CKA52OEA.js +399 -0
  94. package/dist/chunk-CKA52OEA.js.map +7 -0
  95. package/dist/chunk-CKDC326M.js +50 -0
  96. package/dist/chunk-CRUBP5PT.js +446 -0
  97. package/dist/chunk-CW2Q5EA7.js +283 -0
  98. package/dist/chunk-CYHUNQMS.js +6364 -0
  99. package/dist/chunk-DC4KD6FJ.js +458 -0
  100. package/dist/chunk-DC4KD6FJ.js.map +7 -0
  101. package/dist/chunk-DHPLHIVP.js +498 -0
  102. package/dist/chunk-DJQTUDJM.js +414 -0
  103. package/dist/chunk-DJQTUDJM.js.map +7 -0
  104. package/dist/chunk-DWCVGCBX.js +381 -0
  105. package/dist/chunk-EIBNV236.js +339 -0
  106. package/dist/chunk-EZ3WMXYT.js +217 -0
  107. package/dist/chunk-F5QIZOPL.js +736 -0
  108. package/dist/chunk-F6N6JBZR.js +37 -0
  109. package/dist/chunk-FXMHSVBS.js +54 -0
  110. package/dist/chunk-FZ63VOSX.js +226 -0
  111. package/dist/chunk-GMT2GNQY.js +1332 -0
  112. package/dist/chunk-IIT367QZ.js +473 -0
  113. package/dist/chunk-IL5QT2FI.js +293 -0
  114. package/dist/chunk-J6GLTYGJ.js +2681 -0
  115. package/dist/chunk-JEZIKGZI.js +386 -0
  116. package/dist/chunk-JJOLDYSQ.js +824 -0
  117. package/dist/chunk-KSCJWPTJ.js +34 -0
  118. package/dist/chunk-L4TUTGTA.js +20787 -0
  119. package/dist/chunk-L4TUTGTA.js.map +7 -0
  120. package/dist/chunk-LT5XPBIX.js +272 -0
  121. package/dist/chunk-M3J4MINX.js +783 -0
  122. package/dist/chunk-M3J4MINX.js.map +7 -0
  123. package/dist/chunk-MEGBYD4U.js +182 -0
  124. package/dist/chunk-MEY5OBDJ.js +170 -0
  125. package/dist/chunk-MYWV64P5.js +1275 -0
  126. package/dist/chunk-MYWV64P5.js.map +7 -0
  127. package/dist/chunk-NKTBR5SK.js +613 -0
  128. package/dist/chunk-NKTBR5SK.js.map +7 -0
  129. package/dist/chunk-NVX26LFC.js +148 -0
  130. package/dist/chunk-O7NFSCEW.js +291 -0
  131. package/dist/chunk-P4QGOUDH.js +368 -0
  132. package/dist/chunk-PGBKZ76Y.js +129 -0
  133. package/dist/chunk-PQNVPSQR.js +205 -0
  134. package/dist/chunk-PQZ3A27I.js +54 -0
  135. package/dist/chunk-QNMB7LYW.js +5010 -0
  136. package/dist/chunk-RZGEKL77.js +117 -0
  137. package/dist/chunk-RZY34QRF.js +158 -0
  138. package/dist/chunk-S4JLRRKK.js +287 -0
  139. package/dist/chunk-S4JLRRKK.js.map +7 -0
  140. package/dist/chunk-SDACELDR.js +14 -0
  141. package/dist/chunk-SQWEREGE.js +222 -0
  142. package/dist/chunk-SQWEREGE.js.map +7 -0
  143. package/dist/chunk-TVADJLMF.js +317 -0
  144. package/dist/chunk-TVADJLMF.js.map +7 -0
  145. package/dist/chunk-UCLROZRF.js +142 -0
  146. package/dist/chunk-VIHUKORE.js +216 -0
  147. package/dist/chunk-VIHUKORE.js.map +7 -0
  148. package/dist/chunk-VMLSRKIB.js +276 -0
  149. package/dist/chunk-VXKO2ONI.js +534 -0
  150. package/dist/chunk-WET4LPLO.js +117 -0
  151. package/dist/chunk-WMELUFVS.js +254 -0
  152. package/dist/chunk-WS3NUPNV.js +119 -0
  153. package/dist/chunk-X5X5T3AJ.js +230 -0
  154. package/dist/chunk-X5X5T3AJ.js.map +7 -0
  155. package/dist/chunk-X63AAJGT.js +514 -0
  156. package/dist/chunk-XRAFQKOF.js +4274 -0
  157. package/dist/chunk-XRAFQKOF.js.map +7 -0
  158. package/dist/chunk-XVZ5UJWU.js +815 -0
  159. package/dist/chunk-YNBT4N6T.js +2824 -0
  160. package/dist/chunk-YVCTEEVQ.js +55 -0
  161. package/dist/chunk-YWZCJMHS.js +203 -0
  162. package/dist/chunk-Z3SC67OA.js +102 -0
  163. package/dist/chunk-ZK226W6V.js +194 -0
  164. package/dist/chunk-ZLREFIZB.js +302 -0
  165. package/dist/chunk-ZX2ISBEF.js +95 -0
  166. package/dist/condition-P2XD32QM.js +332 -0
  167. package/dist/controls-FZUTJPKV.js +41 -0
  168. package/dist/controls.btns-AP67YWKW.js +9 -0
  169. package/dist/controls.config-TEFY3NTE.js +39 -0
  170. package/dist/correlation-HS2WJFXN.js +99 -0
  171. package/dist/correlation-HS2WJFXN.js.map +7 -0
  172. package/dist/cuminc-42GBJHD3.js +1149 -0
  173. package/dist/cuminc.integration.spec-BAY4JHVL.js +678 -0
  174. package/dist/customdata.inputui-IPM5K56K.js +289 -0
  175. package/dist/dataDownload-D7VCYBDT.js +330 -0
  176. package/dist/dataDownload.integration.spec-SEBY2BIX.js +193 -0
  177. package/dist/databrowser.ui-5OC5MPZB.js +433 -0
  178. package/dist/dictionary-VVRWVLJX.js +111 -0
  179. package/dist/dnaMethylation-72IS3FRI.js +38 -0
  180. package/dist/dnaMethylation.integration.spec-U2LLSDGE.js +203 -0
  181. package/dist/dofetch-5ZRAQH5F.js +51 -0
  182. package/dist/e2pca-AR6EKEJA.js +350 -0
  183. package/dist/ep-JS5UUJQX.js +1256 -0
  184. package/dist/expclust.gdc.spec-73MGQ7RN.js +307 -0
  185. package/dist/facet-AR3QKHCY.js +521 -0
  186. package/dist/forms2-UXEI7MUP.js +534 -0
  187. package/dist/gb-RHDVYU2V.js +88 -0
  188. package/dist/geneExpClustering-L6KLCMPH.js +249 -0
  189. package/dist/geneExpression-GYT2XRE6.js +313 -0
  190. package/dist/geneExpression-SKIU3NEP.js +38 -0
  191. package/dist/geneExpression.unit.spec-CWR6KDVK.js +102 -0
  192. package/dist/geneORA-C3TALK5P.js +278 -0
  193. package/dist/geneRanking-LLYLDPLV.js +551 -0
  194. package/dist/geneVariant-PUSKBHPY.js +39 -0
  195. package/dist/geneVariant-YFMU6PHM.js +41 -0
  196. package/dist/geneVariant.integration.spec-EJ5V46OQ.js +198 -0
  197. package/dist/genefusion.ui-XUHSKQKW.js +309 -0
  198. package/dist/geneset-DEL5LXFZ.js +208 -0
  199. package/dist/genomeBrowser.spec-W5TVHOUJ.js +281 -0
  200. package/dist/grin2-FXAEGECD.js +1560 -0
  201. package/dist/grin2-U2FKULLC.js +821 -0
  202. package/dist/grin2-U2FKULLC.js.map +7 -0
  203. package/dist/gsea-CNL6SHH5.js +47 -0
  204. package/dist/hierCluster-7V65PMIW.js +59 -0
  205. package/dist/hierCluster-C44GHM4B.js +63 -0
  206. package/dist/hierCluster.config-RU5JDPWM.js +40 -0
  207. package/dist/hierCluster.integration.spec-6YH5KE4H.js +395 -0
  208. package/dist/hierCluster.interactivity-PK2L7BSW.js +54 -0
  209. package/dist/hierCluster.renderers-G3274UYA.js +21 -0
  210. package/dist/imagePlot-5SEDMPBP.js +163 -0
  211. package/dist/importPlot-M3MKWRON.js +8 -0
  212. package/dist/isoformExpression-PPMISWKT.js +40 -0
  213. package/dist/isoformExpression.unit.spec-ENHCCQRZ.js +208 -0
  214. package/dist/launch.adhoc-XAG6H42J.js +42 -0
  215. package/dist/leftlabel.sample-BSPCI6GR.js +260 -0
  216. package/dist/lollipop-IZJ7E3YO.js +171 -0
  217. package/dist/maf-54XWBQ73.js +452 -0
  218. package/dist/maftimeline-3AJKAFS6.js +593 -0
  219. package/dist/matrix-AJPMHUXG.js +63 -0
  220. package/dist/matrix-ZMXNOESU.js +58 -0
  221. package/dist/matrix.cells-E3LEVA7U.js +28 -0
  222. package/dist/matrix.config-4WLSFMTY.js +41 -0
  223. package/dist/matrix.data-WMOTOB6C.js +25 -0
  224. package/dist/matrix.dom-F7AN3QGE.js +11 -0
  225. package/dist/matrix.groups-BGMZZ6CM.js +27 -0
  226. package/dist/matrix.integration.spec-ENRPVB7R.js +3072 -0
  227. package/dist/matrix.interactivity-IMWERCZF.js +42 -0
  228. package/dist/matrix.layout-5DDZWLNX.js +44 -0
  229. package/dist/matrix.legend-RJAFOZHQ.js +22 -0
  230. package/dist/matrix.renderers-VFQZG5JP.js +38 -0
  231. package/dist/matrix.serieses-GJWHSBG4.js +21 -0
  232. package/dist/matrix.sort-KIJENIT2.js +27 -0
  233. package/dist/matrix.sort.unit.spec-ZA5DRNL6.js +472 -0
  234. package/dist/matrix.sorterUi-3KEDVLGW.js +18 -0
  235. package/dist/matrix.sorterUi.unit.spec-7TPOJ46U.js +342 -0
  236. package/dist/mavb-73BXZ7MO.js +732 -0
  237. package/dist/mds.fimo-L7VVAOXQ.js +518 -0
  238. package/dist/mds.samplescatterplot-6P75XEWB.js +1550 -0
  239. package/dist/mds.survivalplot-GCVE7XGO.js +483 -0
  240. package/dist/numericDictTermCluster-OMXIURRD.js +72 -0
  241. package/dist/oncomatrix-BFWV2IC4.js +295 -0
  242. package/dist/oncomatrix.spec-J6IAY3O6.js +448 -0
  243. package/dist/plot.2dvaf-ESJAB2F3.js +377 -0
  244. package/dist/plot.app-T7CQMBRV.js +41 -0
  245. package/dist/plot.barplot-HAWPMPPU.js +102 -0
  246. package/dist/plot.boxplot-4QUORFXY.js +152 -0
  247. package/dist/plot.brainImaging-HG6I3GJW.js +51 -0
  248. package/dist/plot.disco-LPH7F6YW.js +102 -0
  249. package/dist/plot.dzi-DYAY4D4E.js +33 -0
  250. package/dist/plot.ssgq-CF5VIGYJ.js +139 -0
  251. package/dist/plot.vaf2cov-7HZCKNK6.js +259 -0
  252. package/dist/plot.wsi-MU6AXOWO.js +36 -0
  253. package/dist/polar2-G636L5TB.js +226 -0
  254. package/dist/polar2-G636L5TB.js.map +7 -0
  255. package/dist/profileForms-TIT4JUEJ.js +441 -0
  256. package/dist/profilePlot-QFGRAZQA.js +54 -0
  257. package/dist/proteinView-RZ56F45C.js +1320 -0
  258. package/dist/proteinView-RZ56F45C.js.map +7 -0
  259. package/dist/qualitative-YWP4YUPF.js +43 -0
  260. package/dist/radar2-TKSHL54E.js +321 -0
  261. package/dist/radarFacility2-FHRFLBLF.js +329 -0
  262. package/dist/regression-5XG5LXP7.js +56 -0
  263. package/dist/regression.inputs-QHXK7ZYY.js +48 -0
  264. package/dist/regression.inputs.term-YYO3CR2D.js +48 -0
  265. package/dist/regression.inputs.values.table-3I2FCON2.js +45 -0
  266. package/dist/regression.integration.spec-QVDGCKVT.js +784 -0
  267. package/dist/regression.results-B7LVT2WG.js +40 -0
  268. package/dist/regression.spec-ISYKKQOM.js +708 -0
  269. package/dist/report-TF6Z3Y44.js +222 -0
  270. package/dist/sampleScatter.spec-2VW55XIZ.js +202 -0
  271. package/dist/sampleView-DNNJRAMU.js +48 -0
  272. package/dist/samplelst-726II3LN.js +111 -0
  273. package/dist/samplematrix-TBPW4URH.js +2198 -0
  274. package/dist/sc-GBYH3W4S.js +86 -0
  275. package/dist/scatter-ATUM7AEW.js +849 -0
  276. package/dist/scatter-ATUM7AEW.js.map +7 -0
  277. package/dist/scatter.integration.spec-PDM454O3.js +1197 -0
  278. package/dist/scatter.integration.spec-PDM454O3.js.map +7 -0
  279. package/dist/selectGenomeWithTklst-RCAYDV6D.js +134 -0
  280. package/dist/singleCellCellType-IQYCKUT6.js +38 -0
  281. package/dist/singleCellCellType.unit.spec-ZEWA2IFI.js +160 -0
  282. package/dist/singleCellGeneExpression-STLTBXJQ.js +38 -0
  283. package/dist/singleCellGeneExpression.unit.spec-W6FPS5ZU.js +153 -0
  284. package/dist/singleCellPlot-7XH7NIL4.js +54 -0
  285. package/dist/singlecell-IDZB2MXW.js +86 -0
  286. package/dist/singlecell-JCXR7X5U.js +1572 -0
  287. package/dist/snp-QOKI26PO.js +38 -0
  288. package/dist/snp.unit.spec-DTPZAALW.js +176 -0
  289. package/dist/snplocus-BKUJYANW.js +208 -0
  290. package/dist/spliceevent.a53ss.diagram-4O54ORKZ.js +151 -0
  291. package/dist/spliceevent.exonskip.diagram-KOIOS6IV.js +277 -0
  292. package/dist/spliceevent.noeventdiagram-YGUGQMVE.js +460 -0
  293. package/dist/ssGSEA-UZMBIHVD.js +38 -0
  294. package/dist/ssGSEA.unit.spec-4YO4E3T7.js +88 -0
  295. package/dist/stattable-MDABSW3F.js +90 -0
  296. package/dist/summarizeCnvGeneexp-HV3DHIW4.js +163 -0
  297. package/dist/summarizeGeneexpSurvival-VGPRWYQ5.js +108 -0
  298. package/dist/summarizeMutationCnv-N3JEB4DJ.js +164 -0
  299. package/dist/summarizeMutationDiagnosis-6U4DBLG5.js +40 -0
  300. package/dist/summarizeMutationSurvival-S7NLAVEI.js +99 -0
  301. package/dist/summary-NPR56I4S.js +49 -0
  302. package/dist/summary.integration.spec-HWNJWLKT.js +414 -0
  303. package/dist/summaryInput-DO73NGDQ.js +235 -0
  304. package/dist/sunburst-MMXSGJSL.js +284 -0
  305. package/dist/survival-7AIKFGV5.js +58 -0
  306. package/dist/survival-UK332X6L.js +46 -0
  307. package/dist/survival.integration.spec-YMTEKEGB.js +821 -0
  308. package/dist/svgraph-MLLAYO4A.js +1387 -0
  309. package/dist/svmr-PYW4PLT3.js +3842 -0
  310. package/dist/table-Y3ED2444.js +200 -0
  311. package/dist/termCollection-3XVL75II.js +38 -0
  312. package/dist/termCollection-VAB53YGO.js +179 -0
  313. package/dist/termCollection.unit.spec-DYPWNVEZ.js +208 -0
  314. package/dist/termInfo-6MJDJSDW.js +9 -0
  315. package/dist/tk-GUGJYKJ2.js +46 -0
  316. package/dist/tp.ui-WGETBYJQ.js +1459 -0
  317. package/dist/tvs.dt-JWF4I3KY.js +39 -0
  318. package/dist/tvs.dtcnv.categorical-72Y5QMPL.js +40 -0
  319. package/dist/tvs.dtcnv.continuous-73LHWTU5.js +72 -0
  320. package/dist/tvs.dtfusion-LP6HUMZU.js +40 -0
  321. package/dist/tvs.dtsnvindel-23N2CFZJ.js +40 -0
  322. package/dist/tvs.dtsv-DILQVKYM.js +40 -0
  323. package/dist/tvs.samplelst-GV4VSCRF.js +104 -0
  324. package/dist/tvs.termCollection-KBDNXK7X.js +159 -0
  325. package/dist/violin-TYUP7FB5.js +46 -0
  326. package/dist/violin.integration.spec-ULRFK2A6.js +1425 -0
  327. package/dist/violin.interactivity-2QZVQWQJ.js +38 -0
  328. package/dist/violin.renderer-HCDSN62Z.js +40 -0
  329. package/dist/vocabulary-I4CMPN2Z.js +41 -0
  330. package/package.json +3 -3
  331. package/dist/2dmaf-ZCIOFNSJ.js +0 -1373
  332. package/dist/AIProjectAdmin-Z7EA2Y74.js +0 -829
  333. package/dist/AppHeader-4AZ76NN3.js +0 -835
  334. package/dist/BoxPlot-BFVBNQNR.js +0 -1217
  335. package/dist/BoxPlot-BFVBNQNR.js.map +0 -7
  336. package/dist/CorrelationVolcano-L5VSJWJF.js +0 -619
  337. package/dist/DE-7TPZWAKI.js +0 -95
  338. package/dist/DEinput-WQJEXWGY.js +0 -301
  339. package/dist/DifferentialAnalysis-FPG7RDNN.js +0 -245
  340. package/dist/Disco-WP2BBL5V.js +0 -3237
  341. package/dist/Disco.UI-ZYSUA57E.js +0 -245
  342. package/dist/DmrPlot-V3E7JMPN.js +0 -642
  343. package/dist/DziViewer-ZHAPJ457.js +0 -16332
  344. package/dist/GB-BKLVGYWP.js +0 -1130
  345. package/dist/GeneExpInput-7V72SRDT.js +0 -366
  346. package/dist/HicApp-IT5YNABL.js +0 -2250
  347. package/dist/NumBinaryEditor-7E37MVQO.js +0 -270
  348. package/dist/NumBinaryEditor-7E37MVQO.js.map +0 -7
  349. package/dist/NumBinaryEditor.unit.spec-C3WVAXMY.js +0 -286
  350. package/dist/NumContEditor-FEVZJUB4.js +0 -107
  351. package/dist/NumContEditor-FEVZJUB4.js.map +0 -7
  352. package/dist/NumContEditor.unit.spec-4IGP657P.js +0 -169
  353. package/dist/NumCustomBinEditor-QC4D63Y5.js +0 -38
  354. package/dist/NumCustomBinEditor.unit.spec-USLECMWI.js +0 -284
  355. package/dist/NumDiscreteEditor-PRAI76XQ.js +0 -179
  356. package/dist/NumDiscreteEditor.unit.spec-IWL3OCTC.js +0 -202
  357. package/dist/NumRegularBinEditor-ESL2HAD7.js +0 -38
  358. package/dist/NumRegularBinEditor.unit.spec-7LLZAW4Z.js +0 -227
  359. package/dist/NumSplineEditor-JZOROO36.js +0 -197
  360. package/dist/NumSplineEditor-JZOROO36.js.map +0 -7
  361. package/dist/NumSplineEditor.unit.spec-3SHSXTC7.js +0 -199
  362. package/dist/NumericDensity-SGYRBDCQ.js +0 -38
  363. package/dist/NumericDensity.unit.spec-Y6JMH6IR.js +0 -221
  364. package/dist/NumericHandler-YG7AMINA.js +0 -39
  365. package/dist/NumericHandler.unit.spec-CABSMERN.js +0 -219
  366. package/dist/ProteomeInput-2WPCK72Z.js +0 -396
  367. package/dist/RunChart2-PJWMDWJR.js +0 -758
  368. package/dist/SC-WVVUFPNU.js +0 -936
  369. package/dist/Volcano-7JI4LUSF.js +0 -1379
  370. package/dist/WSIViewer-GDSOEEA6.js +0 -48475
  371. package/dist/WsiSamplesPlot-Z5C3NPF7.js +0 -165
  372. package/dist/adSandbox-KQKENDNQ.js +0 -38
  373. package/dist/alphaGenome-PN2SEPCK.js +0 -175
  374. package/dist/alphaGenome-PN2SEPCK.js.map +0 -7
  375. package/dist/app-4OEY56FN.js +0 -49
  376. package/dist/app-TGMYXJ4E.js +0 -37
  377. package/dist/bam-3IMX42G5.js +0 -860
  378. package/dist/barchart-44HOJWVS.js +0 -47
  379. package/dist/barchart.data-CHNR4XL2.js +0 -22
  380. package/dist/barchart.events-XW5OZ5MR.js +0 -47
  381. package/dist/barchart.integration.spec-M5PACARH.js +0 -1923
  382. package/dist/barchart.integration.spec-M5PACARH.js.map +0 -7
  383. package/dist/barchart2-4NU7NWJZ.js +0 -311
  384. package/dist/block-OYSZ2JXC.js +0 -6202
  385. package/dist/block.init-WSIQLW7A.js +0 -38
  386. package/dist/block.mds.expressionrank-2KWOWDW4.js +0 -359
  387. package/dist/block.mds.geneboxplot-6ZAD6A5K.js +0 -828
  388. package/dist/block.mds.junction-VQDLHFNG.js +0 -1545
  389. package/dist/block.mds.svcnv-7OIRG7DQ.js +0 -6801
  390. package/dist/block.svg-HXAIFHXM.js +0 -164
  391. package/dist/block.tk.aicheck-GTGHCUEN.js +0 -283
  392. package/dist/block.tk.ase-TAEE2ZHN.js +0 -365
  393. package/dist/block.tk.bam-6A26AZ7S.js +0 -1906
  394. package/dist/block.tk.bedgraphdot-6MYIVRBC.js +0 -384
  395. package/dist/block.tk.bigwig.ui-GJ7JXRH3.js +0 -212
  396. package/dist/block.tk.hicstraw-3TCDZ2GM.js +0 -823
  397. package/dist/block.tk.junction-WDBIP7DK.js +0 -2364
  398. package/dist/block.tk.junction.textmatrixui-QOV3U7AN.js +0 -199
  399. package/dist/block.tk.ld-GCPH66C3.js +0 -99
  400. package/dist/block.tk.menu-YDAIYUGC.js +0 -1029
  401. package/dist/block.tk.pgv-RWOZAUGA.js +0 -944
  402. package/dist/brainImaging-ZAFU6U2Y.js +0 -423
  403. package/dist/chunk-34SAHEQU.js +0 -291
  404. package/dist/chunk-3I7TUGLD.js +0 -226
  405. package/dist/chunk-3JL2HBGE.js +0 -2824
  406. package/dist/chunk-3L32ZXRS.js +0 -117
  407. package/dist/chunk-5GMXV4VC.js +0 -5010
  408. package/dist/chunk-5ITQVR2P.js +0 -102
  409. package/dist/chunk-5TKVUSMQ.js +0 -217
  410. package/dist/chunk-5V43Y2RC.js +0 -774
  411. package/dist/chunk-5V43Y2RC.js.map +0 -7
  412. package/dist/chunk-5X6J6UAT.js +0 -473
  413. package/dist/chunk-5YF3LGLX.js +0 -2327
  414. package/dist/chunk-76PGYH5J.js +0 -203
  415. package/dist/chunk-7JXLWRVZ.js +0 -2681
  416. package/dist/chunk-7YWFO7CJ.js +0 -6364
  417. package/dist/chunk-B3M3AZPL.js +0 -215
  418. package/dist/chunk-B3M3AZPL.js.map +0 -7
  419. package/dist/chunk-B4VRYXOQ.js +0 -288
  420. package/dist/chunk-B4VRYXOQ.js.map +0 -7
  421. package/dist/chunk-BLKF2SE6.js +0 -37
  422. package/dist/chunk-CA2AOIHR.js +0 -142
  423. package/dist/chunk-DBFPAZG3.js +0 -1943
  424. package/dist/chunk-DCJUDSRM.js +0 -446
  425. package/dist/chunk-DNM2DKYE.js +0 -1332
  426. package/dist/chunk-DVH6K2NP.js +0 -14
  427. package/dist/chunk-DYVY7D67.js +0 -263
  428. package/dist/chunk-E4IHE23N.js +0 -398
  429. package/dist/chunk-E4IHE23N.js.map +0 -7
  430. package/dist/chunk-G6WVVRDA.js +0 -339
  431. package/dist/chunk-GERVYIL4.js +0 -1210
  432. package/dist/chunk-GKBMGKYN.js +0 -117
  433. package/dist/chunk-GRNZWYOJ.js +0 -815
  434. package/dist/chunk-GS7SQKJT.js +0 -102
  435. package/dist/chunk-H5NNQO2V.js +0 -55
  436. package/dist/chunk-HONXMORI.js +0 -368
  437. package/dist/chunk-HURY7IJE.js +0 -4272
  438. package/dist/chunk-HURY7IJE.js.map +0 -7
  439. package/dist/chunk-HWVEN2MK.js +0 -498
  440. package/dist/chunk-I2RRWDYV.js +0 -514
  441. package/dist/chunk-IFA3COXY.js +0 -185
  442. package/dist/chunk-IFA3COXY.js.map +0 -7
  443. package/dist/chunk-IOQV2VX3.js +0 -2786
  444. package/dist/chunk-IWMWT7O7.js +0 -276
  445. package/dist/chunk-JSEMZPAO.js +0 -34
  446. package/dist/chunk-K7UIR22L.js +0 -229
  447. package/dist/chunk-K7UIR22L.js.map +0 -7
  448. package/dist/chunk-L75HW457.js +0 -824
  449. package/dist/chunk-LO6OYUDE.js +0 -158
  450. package/dist/chunk-LO6OYUDE.js.map +0 -7
  451. package/dist/chunk-LRZ463XM.js +0 -612
  452. package/dist/chunk-LRZ463XM.js.map +0 -7
  453. package/dist/chunk-MQQRTH4U.js +0 -302
  454. package/dist/chunk-NPEQHLVG.js +0 -158
  455. package/dist/chunk-NPTHYZY4.js +0 -205
  456. package/dist/chunk-NZDQV7ZO.js +0 -50
  457. package/dist/chunk-O7Z7SQCS.js +0 -534
  458. package/dist/chunk-OSWTQVAX.js +0 -477
  459. package/dist/chunk-OY4NTIUQ.js +0 -1272
  460. package/dist/chunk-OY4NTIUQ.js.map +0 -7
  461. package/dist/chunk-PKDJVK2F.js +0 -381
  462. package/dist/chunk-PSQETQZZ.js +0 -182
  463. package/dist/chunk-QWOZ2QDM.js +0 -386
  464. package/dist/chunk-QZVCFDJ7.js +0 -736
  465. package/dist/chunk-R4BCNWKE.js +0 -54
  466. package/dist/chunk-RRWP2LM4.js +0 -143
  467. package/dist/chunk-S6H6OUOA.js +0 -283
  468. package/dist/chunk-S6OIEQXG.js +0 -443
  469. package/dist/chunk-SDMZUHN7.js +0 -482
  470. package/dist/chunk-SKZ37PND.js +0 -129
  471. package/dist/chunk-STQU7XZV.js +0 -1814
  472. package/dist/chunk-STQU7XZV.js.map +0 -7
  473. package/dist/chunk-SY63VCQB.js +0 -95
  474. package/dist/chunk-TEQ2PC7Z.js +0 -100
  475. package/dist/chunk-TRY57CMI.js +0 -148
  476. package/dist/chunk-TXJTOTIQ.js +0 -1102
  477. package/dist/chunk-UK3PTE3P.js +0 -20752
  478. package/dist/chunk-UK3PTE3P.js.map +0 -7
  479. package/dist/chunk-UT2PKKQ4.js +0 -254
  480. package/dist/chunk-VDPQ2ZV2.js +0 -95
  481. package/dist/chunk-VJH3NP42.js +0 -54
  482. package/dist/chunk-W3LVNVG3.js +0 -272
  483. package/dist/chunk-WC62ZAWT.js +0 -293
  484. package/dist/chunk-WKMZ4ZQ3.js +0 -407
  485. package/dist/chunk-WKMZ4ZQ3.js.map +0 -7
  486. package/dist/chunk-X27TRPIZ.js +0 -119
  487. package/dist/chunk-XIIAQQ4T.js +0 -1179
  488. package/dist/chunk-XIIAQQ4T.js.map +0 -7
  489. package/dist/chunk-XOCO3LVN.js +0 -317
  490. package/dist/chunk-XOCO3LVN.js.map +0 -7
  491. package/dist/chunk-XUFWJJM5.js +0 -454
  492. package/dist/chunk-XUFWJJM5.js.map +0 -7
  493. package/dist/chunk-Y2Z4XDHA.js +0 -170
  494. package/dist/chunk-YFKJ2TMX.js +0 -194
  495. package/dist/chunk-YPVFTNLG.js +0 -228
  496. package/dist/chunk-YPVFTNLG.js.map +0 -7
  497. package/dist/condition-XKEW2LCM.js +0 -332
  498. package/dist/controls-4RFWTHFH.js +0 -41
  499. package/dist/controls.btns-3QQ5FOKQ.js +0 -9
  500. package/dist/controls.config-VHH2IGCI.js +0 -39
  501. package/dist/correlation-HGAMIIPH.js +0 -99
  502. package/dist/correlation-HGAMIIPH.js.map +0 -7
  503. package/dist/cuminc-EHW6IH6V.js +0 -1149
  504. package/dist/cuminc.integration.spec-B3EOIE4K.js +0 -678
  505. package/dist/customdata.inputui-IPJHL7BX.js +0 -289
  506. package/dist/dataDownload-GYFEC6XG.js +0 -330
  507. package/dist/dataDownload.integration.spec-V7WQ6AMV.js +0 -193
  508. package/dist/databrowser.ui-TFAJVFFF.js +0 -433
  509. package/dist/dictionary-2ZSMOJCN.js +0 -111
  510. package/dist/dnaMethylation-RHNO5DAC.js +0 -38
  511. package/dist/dnaMethylation.integration.spec-ET7OLMNC.js +0 -203
  512. package/dist/dofetch-UGCQ3OVW.js +0 -51
  513. package/dist/e2pca-SLRCDKF5.js +0 -350
  514. package/dist/ep-FOFTKVBH.js +0 -1256
  515. package/dist/expclust.gdc.spec-FNOOSLCC.js +0 -307
  516. package/dist/facet-UO5A7AGS.js +0 -521
  517. package/dist/forms2-SFV4HHBA.js +0 -534
  518. package/dist/gb-3KR6MAGB.js +0 -88
  519. package/dist/geneExpClustering-BCDXKSNU.js +0 -249
  520. package/dist/geneExpression-5UPKETEZ.js +0 -313
  521. package/dist/geneExpression-CXQ5HFEP.js +0 -38
  522. package/dist/geneExpression.unit.spec-7FVVD4UF.js +0 -102
  523. package/dist/geneORA-UC45CL2U.js +0 -278
  524. package/dist/geneRanking-OOQWVUIG.js +0 -551
  525. package/dist/geneVariant-BQFB7LKZ.js +0 -39
  526. package/dist/geneVariant-BYN7EWTT.js +0 -41
  527. package/dist/geneVariant.integration.spec-OESHXKBV.js +0 -198
  528. package/dist/genefusion.ui-TOSPIGTE.js +0 -309
  529. package/dist/geneset-57DECCND.js +0 -208
  530. package/dist/genomeBrowser.spec-CQP5JG35.js +0 -281
  531. package/dist/grin2-3RDGRV4Z.js +0 -846
  532. package/dist/grin2-3RDGRV4Z.js.map +0 -7
  533. package/dist/grin2-G4MBI5UC.js +0 -1560
  534. package/dist/gsea-VYAXSBM4.js +0 -47
  535. package/dist/hierCluster-4QKMY7GP.js +0 -59
  536. package/dist/hierCluster-GFPFVB3Q.js +0 -63
  537. package/dist/hierCluster.config-3A24DEKA.js +0 -40
  538. package/dist/hierCluster.integration.spec-6NTJYVN4.js +0 -395
  539. package/dist/hierCluster.interactivity-B2T6WS5R.js +0 -54
  540. package/dist/hierCluster.renderers-R3RLK6BI.js +0 -21
  541. package/dist/imagePlot-YZBZRENG.js +0 -163
  542. package/dist/importPlot-LIXKD3WJ.js +0 -8
  543. package/dist/isoformExpression-ZZ5DL6AE.js +0 -40
  544. package/dist/isoformExpression.unit.spec-IH4247TT.js +0 -208
  545. package/dist/launch.adhoc-3YWVAF7R.js +0 -42
  546. package/dist/leftlabel.sample-XFM45ZKO.js +0 -260
  547. package/dist/lollipop-7K5R5KHB.js +0 -171
  548. package/dist/maf-SQVJHNUY.js +0 -452
  549. package/dist/maftimeline-RCPASNN2.js +0 -593
  550. package/dist/matrix-KHTDB56P.js +0 -63
  551. package/dist/matrix-YTHWIMBP.js +0 -58
  552. package/dist/matrix.cells-KNDVYI2S.js +0 -28
  553. package/dist/matrix.config-6BHBCTXE.js +0 -41
  554. package/dist/matrix.data-VWJQ7N4L.js +0 -25
  555. package/dist/matrix.dom-2SU4EYLI.js +0 -11
  556. package/dist/matrix.groups-5AUHEO52.js +0 -27
  557. package/dist/matrix.integration.spec-Q2BXNCUO.js +0 -3072
  558. package/dist/matrix.interactivity-FEEWY34M.js +0 -42
  559. package/dist/matrix.layout-FWWM6QQO.js +0 -44
  560. package/dist/matrix.legend-QT3PMREX.js +0 -22
  561. package/dist/matrix.renderers-M6MJO5IU.js +0 -38
  562. package/dist/matrix.serieses-NTKMKT22.js +0 -21
  563. package/dist/matrix.sort-TTHPJ4XC.js +0 -27
  564. package/dist/matrix.sort.unit.spec-XZI2KPNC.js +0 -472
  565. package/dist/matrix.sorterUi-FFLYKBGC.js +0 -18
  566. package/dist/matrix.sorterUi.unit.spec-6FVHTGSN.js +0 -342
  567. package/dist/mavb-FZDN27QY.js +0 -732
  568. package/dist/mds.fimo-SSFKQ3BH.js +0 -518
  569. package/dist/mds.samplescatterplot-BMTTX3TB.js +0 -1550
  570. package/dist/mds.survivalplot-PL75RDYI.js +0 -483
  571. package/dist/numericDictTermCluster-NJUXCQYH.js +0 -72
  572. package/dist/oncomatrix-BZDCCEWH.js +0 -295
  573. package/dist/oncomatrix.spec-5A4A4JLV.js +0 -448
  574. package/dist/plot.2dvaf-AC7LW56S.js +0 -377
  575. package/dist/plot.app-DOOWDQ3U.js +0 -41
  576. package/dist/plot.barplot-RNJWREG5.js +0 -102
  577. package/dist/plot.boxplot-CRAEUBQF.js +0 -152
  578. package/dist/plot.brainImaging-ZESEULN6.js +0 -51
  579. package/dist/plot.disco-B4KBP6RK.js +0 -102
  580. package/dist/plot.dzi-2UMRV6IF.js +0 -33
  581. package/dist/plot.ssgq-FVZ27Z2K.js +0 -139
  582. package/dist/plot.vaf2cov-3OXCIEAX.js +0 -259
  583. package/dist/plot.wsi-UKTLZSYW.js +0 -36
  584. package/dist/polar2-D6T34ONJ.js +0 -226
  585. package/dist/polar2-D6T34ONJ.js.map +0 -7
  586. package/dist/profileForms-SBNPRIFT.js +0 -441
  587. package/dist/profilePlot-PPI4IDP4.js +0 -54
  588. package/dist/proteinView-URQEZSH5.js +0 -1320
  589. package/dist/proteinView-URQEZSH5.js.map +0 -7
  590. package/dist/qualitative-4O6KAGEA.js +0 -43
  591. package/dist/radar2-ICKCJY4T.js +0 -321
  592. package/dist/radarFacility2-HEBBSM3T.js +0 -329
  593. package/dist/regression-YFQJE2EP.js +0 -56
  594. package/dist/regression.inputs-A2JVBVZ7.js +0 -48
  595. package/dist/regression.inputs.term-CTVNS5MO.js +0 -48
  596. package/dist/regression.inputs.values.table-X7SI6EDO.js +0 -45
  597. package/dist/regression.integration.spec-NRDEVBWS.js +0 -784
  598. package/dist/regression.results-XVB6CIGW.js +0 -40
  599. package/dist/regression.spec-TNB5HBY5.js +0 -708
  600. package/dist/report-5VDIBC2W.js +0 -222
  601. package/dist/sampleScatter.spec-XDW7SCYA.js +0 -202
  602. package/dist/sampleView-FLUSGZCM.js +0 -48
  603. package/dist/samplelst-4WPG5UBN.js +0 -111
  604. package/dist/samplematrix-YJGMSXUJ.js +0 -2198
  605. package/dist/sc-DHU5KSEJ.js +0 -86
  606. package/dist/scatter-UZMWX3DU.js +0 -854
  607. package/dist/scatter-UZMWX3DU.js.map +0 -7
  608. package/dist/scatter.integration.spec-YX5OC3L2.js +0 -1196
  609. package/dist/scatter.integration.spec-YX5OC3L2.js.map +0 -7
  610. package/dist/selectGenomeWithTklst-BVBMVRMQ.js +0 -134
  611. package/dist/singleCellCellType-DADK5UKZ.js +0 -38
  612. package/dist/singleCellCellType.unit.spec-X25RMBJ3.js +0 -160
  613. package/dist/singleCellGeneExpression-3UEZWI4E.js +0 -38
  614. package/dist/singleCellGeneExpression.unit.spec-5GU3JWE6.js +0 -153
  615. package/dist/singleCellPlot-TFRZG73T.js +0 -54
  616. package/dist/singlecell-HQH6EWJO.js +0 -1572
  617. package/dist/singlecell-KR6JYFAY.js +0 -86
  618. package/dist/snp-ACIZ7D5X.js +0 -38
  619. package/dist/snp.unit.spec-653HGJBM.js +0 -176
  620. package/dist/snplocus-AH6KJCVN.js +0 -208
  621. package/dist/spliceevent.a53ss.diagram-MKJLJDOG.js +0 -151
  622. package/dist/spliceevent.exonskip.diagram-PSEVCDH4.js +0 -277
  623. package/dist/spliceevent.noeventdiagram-T2LHGFN7.js +0 -460
  624. package/dist/ssGSEA-QFMYBITZ.js +0 -38
  625. package/dist/ssGSEA.unit.spec-SQW7KFWE.js +0 -88
  626. package/dist/stattable-QDIUQCMG.js +0 -90
  627. package/dist/summarizeCnvGeneexp-EVRTBY3L.js +0 -163
  628. package/dist/summarizeGeneexpSurvival-O3MGRS6K.js +0 -108
  629. package/dist/summarizeMutationCnv-RZ2DZ2XO.js +0 -164
  630. package/dist/summarizeMutationDiagnosis-V2DISQTC.js +0 -40
  631. package/dist/summarizeMutationSurvival-FTTWJBUG.js +0 -99
  632. package/dist/summary-QKBTZINC.js +0 -49
  633. package/dist/summary.integration.spec-54HA7BC2.js +0 -414
  634. package/dist/summaryInput-4RLZT6RW.js +0 -235
  635. package/dist/sunburst-SMKD45XD.js +0 -284
  636. package/dist/survival-BAW5ME6J.js +0 -46
  637. package/dist/survival-YQNA3WP7.js +0 -58
  638. package/dist/survival.integration.spec-2AHXNMH2.js +0 -821
  639. package/dist/svgraph-5Z7VAIVR.js +0 -1387
  640. package/dist/svmr-PHD76RV4.js +0 -3842
  641. package/dist/table-GMRAOIWZ.js +0 -200
  642. package/dist/termCollection-MEBY34TJ.js +0 -179
  643. package/dist/termCollection-QLKTRXUR.js +0 -38
  644. package/dist/termCollection.unit.spec-6B53SW2Q.js +0 -208
  645. package/dist/termInfo-2Z4V2QLE.js +0 -9
  646. package/dist/tk-X46SEOL7.js +0 -46
  647. package/dist/tp.ui-XV7CL7CA.js +0 -1459
  648. package/dist/tvs.dt-U6SIZTXW.js +0 -39
  649. package/dist/tvs.dtcnv.categorical-6YGEKMHW.js +0 -40
  650. package/dist/tvs.dtcnv.continuous-CQFEENBO.js +0 -72
  651. package/dist/tvs.dtfusion-NOBT2JPI.js +0 -40
  652. package/dist/tvs.dtsnvindel-6GTCSVAV.js +0 -40
  653. package/dist/tvs.dtsv-PMI4YVI5.js +0 -40
  654. package/dist/tvs.samplelst-HVNYKHXG.js +0 -104
  655. package/dist/tvs.termCollection-EWGTT75Z.js +0 -159
  656. package/dist/violin-MKWRB25Z.js +0 -46
  657. package/dist/violin.integration.spec-CNWJ43SD.js +0 -1425
  658. package/dist/violin.interactivity-UXOMTGSD.js +0 -38
  659. package/dist/violin.renderer-67Q6YGYQ.js +0 -40
  660. package/dist/vocabulary-AKXE7SNU.js +0 -41
  661. /package/dist/{2dmaf-ZCIOFNSJ.js.map → 2dmaf-V4WJ2LEK.js.map} +0 -0
  662. /package/dist/{AIProjectAdmin-Z7EA2Y74.js.map → AIProjectAdmin-JMN5O6YU.js.map} +0 -0
  663. /package/dist/{AppHeader-4AZ76NN3.js.map → AppHeader-Y4SEKCEF.js.map} +0 -0
  664. /package/dist/{CorrelationVolcano-L5VSJWJF.js.map → CorrelationVolcano-R5IWD6WA.js.map} +0 -0
  665. /package/dist/{DE-7TPZWAKI.js.map → DE-ZV6O7B6Y.js.map} +0 -0
  666. /package/dist/{DEinput-WQJEXWGY.js.map → DEinput-FTOALZKN.js.map} +0 -0
  667. /package/dist/{DifferentialAnalysis-FPG7RDNN.js.map → DifferentialAnalysis-NLCA766A.js.map} +0 -0
  668. /package/dist/{Disco-WP2BBL5V.js.map → Disco-Y5Z4A7GN.js.map} +0 -0
  669. /package/dist/{Disco.UI-ZYSUA57E.js.map → Disco.UI-GSWZYIUT.js.map} +0 -0
  670. /package/dist/{DmrPlot-V3E7JMPN.js.map → DmrPlot-FEFUCIGT.js.map} +0 -0
  671. /package/dist/{DziViewer-ZHAPJ457.js.map → DziViewer-6737GC22.js.map} +0 -0
  672. /package/dist/{GB-BKLVGYWP.js.map → GB-AOXF2JJB.js.map} +0 -0
  673. /package/dist/{GeneExpInput-7V72SRDT.js.map → GeneExpInput-CXYRKQU7.js.map} +0 -0
  674. /package/dist/{HicApp-IT5YNABL.js.map → HicApp-GLNNZ4H5.js.map} +0 -0
  675. /package/dist/{NumBinaryEditor.unit.spec-C3WVAXMY.js.map → NumBinaryEditor.unit.spec-3VTJLILH.js.map} +0 -0
  676. /package/dist/{NumContEditor.unit.spec-4IGP657P.js.map → NumContEditor.unit.spec-WIMYCOVO.js.map} +0 -0
  677. /package/dist/{NumCustomBinEditor-QC4D63Y5.js.map → NumCustomBinEditor-XIOAYWOD.js.map} +0 -0
  678. /package/dist/{NumCustomBinEditor.unit.spec-USLECMWI.js.map → NumCustomBinEditor.unit.spec-N5OV6MKR.js.map} +0 -0
  679. /package/dist/{NumDiscreteEditor-PRAI76XQ.js.map → NumDiscreteEditor-AT6FKYGI.js.map} +0 -0
  680. /package/dist/{NumDiscreteEditor.unit.spec-IWL3OCTC.js.map → NumDiscreteEditor.unit.spec-BDR5GZ46.js.map} +0 -0
  681. /package/dist/{NumRegularBinEditor-ESL2HAD7.js.map → NumRegularBinEditor-Z4NBS4VZ.js.map} +0 -0
  682. /package/dist/{NumRegularBinEditor.unit.spec-7LLZAW4Z.js.map → NumRegularBinEditor.unit.spec-BRWYNQ55.js.map} +0 -0
  683. /package/dist/{NumSplineEditor.unit.spec-3SHSXTC7.js.map → NumSplineEditor.unit.spec-5RDBCZ4N.js.map} +0 -0
  684. /package/dist/{NumericDensity-SGYRBDCQ.js.map → NumericDensity-L7HIVV7D.js.map} +0 -0
  685. /package/dist/{NumericDensity.unit.spec-Y6JMH6IR.js.map → NumericDensity.unit.spec-PL3XDJCV.js.map} +0 -0
  686. /package/dist/{NumericHandler-YG7AMINA.js.map → NumericHandler-KJYZOCCG.js.map} +0 -0
  687. /package/dist/{NumericHandler.unit.spec-CABSMERN.js.map → NumericHandler.unit.spec-VC7NPLJW.js.map} +0 -0
  688. /package/dist/{ProteomeInput-2WPCK72Z.js.map → ProteomeInput-A3GRPIAH.js.map} +0 -0
  689. /package/dist/{RunChart2-PJWMDWJR.js.map → RunChart2-MSNU3ZNT.js.map} +0 -0
  690. /package/dist/{SC-WVVUFPNU.js.map → SC-FNKG2FK5.js.map} +0 -0
  691. /package/dist/{Volcano-7JI4LUSF.js.map → Volcano-IRJMPHXJ.js.map} +0 -0
  692. /package/dist/{WSIViewer-GDSOEEA6.js.map → WSIViewer-KITT7I67.js.map} +0 -0
  693. /package/dist/{WsiSamplesPlot-Z5C3NPF7.js.map → WsiSamplesPlot-G3YZ6SIE.js.map} +0 -0
  694. /package/dist/{adSandbox-KQKENDNQ.js.map → adSandbox-GIQTJ4VA.js.map} +0 -0
  695. /package/dist/{app-4OEY56FN.js.map → app-MGNEMS2K.js.map} +0 -0
  696. /package/dist/{app-TGMYXJ4E.js.map → app-UQTHPQFD.js.map} +0 -0
  697. /package/dist/{bam-3IMX42G5.js.map → bam-5PROQBRT.js.map} +0 -0
  698. /package/dist/{barchart-44HOJWVS.js.map → barchart-BQYJ73Z4.js.map} +0 -0
  699. /package/dist/{barchart.data-CHNR4XL2.js.map → barchart.data-VFULOIHY.js.map} +0 -0
  700. /package/dist/{barchart.events-XW5OZ5MR.js.map → barchart.events-W2CIDD4B.js.map} +0 -0
  701. /package/dist/{barchart2-4NU7NWJZ.js.map → barchart2-V6W4UAFH.js.map} +0 -0
  702. /package/dist/{block-OYSZ2JXC.js.map → block-5V2FCT7Q.js.map} +0 -0
  703. /package/dist/{block.init-WSIQLW7A.js.map → block.init-43IUNDNB.js.map} +0 -0
  704. /package/dist/{block.mds.expressionrank-2KWOWDW4.js.map → block.mds.expressionrank-LI6MZPBE.js.map} +0 -0
  705. /package/dist/{block.mds.geneboxplot-6ZAD6A5K.js.map → block.mds.geneboxplot-673AIJMJ.js.map} +0 -0
  706. /package/dist/{block.mds.junction-VQDLHFNG.js.map → block.mds.junction-UWNVNV3X.js.map} +0 -0
  707. /package/dist/{block.mds.svcnv-7OIRG7DQ.js.map → block.mds.svcnv-Z5VFCUUE.js.map} +0 -0
  708. /package/dist/{block.svg-HXAIFHXM.js.map → block.svg-MGK4GWLL.js.map} +0 -0
  709. /package/dist/{block.tk.aicheck-GTGHCUEN.js.map → block.tk.aicheck-OFNDGG7Q.js.map} +0 -0
  710. /package/dist/{block.tk.ase-TAEE2ZHN.js.map → block.tk.ase-IDZQY7MW.js.map} +0 -0
  711. /package/dist/{block.tk.bam-6A26AZ7S.js.map → block.tk.bam-K7A2Q5NI.js.map} +0 -0
  712. /package/dist/{block.tk.bedgraphdot-6MYIVRBC.js.map → block.tk.bedgraphdot-PPTKCCPK.js.map} +0 -0
  713. /package/dist/{block.tk.bigwig.ui-GJ7JXRH3.js.map → block.tk.bigwig.ui-PI6EAU43.js.map} +0 -0
  714. /package/dist/{block.tk.hicstraw-3TCDZ2GM.js.map → block.tk.hicstraw-EZ2GS2K4.js.map} +0 -0
  715. /package/dist/{block.tk.junction-WDBIP7DK.js.map → block.tk.junction-4WSLQGSQ.js.map} +0 -0
  716. /package/dist/{block.tk.junction.textmatrixui-QOV3U7AN.js.map → block.tk.junction.textmatrixui-7EJUSVMB.js.map} +0 -0
  717. /package/dist/{block.tk.ld-GCPH66C3.js.map → block.tk.ld-KLVO7M37.js.map} +0 -0
  718. /package/dist/{block.tk.menu-YDAIYUGC.js.map → block.tk.menu-KZSL7BAR.js.map} +0 -0
  719. /package/dist/{block.tk.pgv-RWOZAUGA.js.map → block.tk.pgv-NYWGB4VH.js.map} +0 -0
  720. /package/dist/{brainImaging-ZAFU6U2Y.js.map → brainImaging-MTIIMJHW.js.map} +0 -0
  721. /package/dist/{chunk-S6OIEQXG.js.map → chunk-2NQLAH3L.js.map} +0 -0
  722. /package/dist/{chunk-DBFPAZG3.js.map → chunk-2Q6PBSPS.js.map} +0 -0
  723. /package/dist/{chunk-GERVYIL4.js.map → chunk-3D5GZIGG.js.map} +0 -0
  724. /package/dist/{chunk-DYVY7D67.js.map → chunk-3TPAIXNL.js.map} +0 -0
  725. /package/dist/{chunk-SY63VCQB.js.map → chunk-42EBECOD.js.map} +0 -0
  726. /package/dist/{chunk-IOQV2VX3.js.map → chunk-4B42QV34.js.map} +0 -0
  727. /package/dist/{chunk-RRWP2LM4.js.map → chunk-4KY4XKJV.js.map} +0 -0
  728. /package/dist/{chunk-TEQ2PC7Z.js.map → chunk-5SXCIKYV.js.map} +0 -0
  729. /package/dist/{chunk-SDMZUHN7.js.map → chunk-647P2I4Q.js.map} +0 -0
  730. /package/dist/{chunk-5YF3LGLX.js.map → chunk-67HSIHPP.js.map} +0 -0
  731. /package/dist/{chunk-TXJTOTIQ.js.map → chunk-6GZJCSA6.js.map} +0 -0
  732. /package/dist/{chunk-GS7SQKJT.js.map → chunk-7JEKUSEL.js.map} +0 -0
  733. /package/dist/{chunk-OSWTQVAX.js.map → chunk-BMO6KSVC.js.map} +0 -0
  734. /package/dist/{chunk-NZDQV7ZO.js.map → chunk-CKDC326M.js.map} +0 -0
  735. /package/dist/{chunk-DCJUDSRM.js.map → chunk-CRUBP5PT.js.map} +0 -0
  736. /package/dist/{chunk-S6H6OUOA.js.map → chunk-CW2Q5EA7.js.map} +0 -0
  737. /package/dist/{chunk-7YWFO7CJ.js.map → chunk-CYHUNQMS.js.map} +0 -0
  738. /package/dist/{chunk-HWVEN2MK.js.map → chunk-DHPLHIVP.js.map} +0 -0
  739. /package/dist/{chunk-PKDJVK2F.js.map → chunk-DWCVGCBX.js.map} +0 -0
  740. /package/dist/{chunk-G6WVVRDA.js.map → chunk-EIBNV236.js.map} +0 -0
  741. /package/dist/{chunk-5TKVUSMQ.js.map → chunk-EZ3WMXYT.js.map} +0 -0
  742. /package/dist/{chunk-QZVCFDJ7.js.map → chunk-F5QIZOPL.js.map} +0 -0
  743. /package/dist/{chunk-BLKF2SE6.js.map → chunk-F6N6JBZR.js.map} +0 -0
  744. /package/dist/{chunk-VJH3NP42.js.map → chunk-FXMHSVBS.js.map} +0 -0
  745. /package/dist/{chunk-3I7TUGLD.js.map → chunk-FZ63VOSX.js.map} +0 -0
  746. /package/dist/{chunk-DNM2DKYE.js.map → chunk-GMT2GNQY.js.map} +0 -0
  747. /package/dist/{chunk-5X6J6UAT.js.map → chunk-IIT367QZ.js.map} +0 -0
  748. /package/dist/{chunk-WC62ZAWT.js.map → chunk-IL5QT2FI.js.map} +0 -0
  749. /package/dist/{chunk-7JXLWRVZ.js.map → chunk-J6GLTYGJ.js.map} +0 -0
  750. /package/dist/{chunk-QWOZ2QDM.js.map → chunk-JEZIKGZI.js.map} +0 -0
  751. /package/dist/{chunk-L75HW457.js.map → chunk-JJOLDYSQ.js.map} +0 -0
  752. /package/dist/{chunk-JSEMZPAO.js.map → chunk-KSCJWPTJ.js.map} +0 -0
  753. /package/dist/{chunk-W3LVNVG3.js.map → chunk-LT5XPBIX.js.map} +0 -0
  754. /package/dist/{chunk-PSQETQZZ.js.map → chunk-MEGBYD4U.js.map} +0 -0
  755. /package/dist/{chunk-Y2Z4XDHA.js.map → chunk-MEY5OBDJ.js.map} +0 -0
  756. /package/dist/{chunk-TRY57CMI.js.map → chunk-NVX26LFC.js.map} +0 -0
  757. /package/dist/{chunk-34SAHEQU.js.map → chunk-O7NFSCEW.js.map} +0 -0
  758. /package/dist/{chunk-HONXMORI.js.map → chunk-P4QGOUDH.js.map} +0 -0
  759. /package/dist/{chunk-SKZ37PND.js.map → chunk-PGBKZ76Y.js.map} +0 -0
  760. /package/dist/{chunk-NPTHYZY4.js.map → chunk-PQNVPSQR.js.map} +0 -0
  761. /package/dist/{chunk-R4BCNWKE.js.map → chunk-PQZ3A27I.js.map} +0 -0
  762. /package/dist/{chunk-5GMXV4VC.js.map → chunk-QNMB7LYW.js.map} +0 -0
  763. /package/dist/{chunk-3L32ZXRS.js.map → chunk-RZGEKL77.js.map} +0 -0
  764. /package/dist/{chunk-NPEQHLVG.js.map → chunk-RZY34QRF.js.map} +0 -0
  765. /package/dist/{chunk-DVH6K2NP.js.map → chunk-SDACELDR.js.map} +0 -0
  766. /package/dist/{chunk-CA2AOIHR.js.map → chunk-UCLROZRF.js.map} +0 -0
  767. /package/dist/{chunk-IWMWT7O7.js.map → chunk-VMLSRKIB.js.map} +0 -0
  768. /package/dist/{chunk-O7Z7SQCS.js.map → chunk-VXKO2ONI.js.map} +0 -0
  769. /package/dist/{chunk-GKBMGKYN.js.map → chunk-WET4LPLO.js.map} +0 -0
  770. /package/dist/{chunk-UT2PKKQ4.js.map → chunk-WMELUFVS.js.map} +0 -0
  771. /package/dist/{chunk-X27TRPIZ.js.map → chunk-WS3NUPNV.js.map} +0 -0
  772. /package/dist/{chunk-I2RRWDYV.js.map → chunk-X63AAJGT.js.map} +0 -0
  773. /package/dist/{chunk-GRNZWYOJ.js.map → chunk-XVZ5UJWU.js.map} +0 -0
  774. /package/dist/{chunk-3JL2HBGE.js.map → chunk-YNBT4N6T.js.map} +0 -0
  775. /package/dist/{chunk-H5NNQO2V.js.map → chunk-YVCTEEVQ.js.map} +0 -0
  776. /package/dist/{chunk-76PGYH5J.js.map → chunk-YWZCJMHS.js.map} +0 -0
  777. /package/dist/{chunk-5ITQVR2P.js.map → chunk-Z3SC67OA.js.map} +0 -0
  778. /package/dist/{chunk-YFKJ2TMX.js.map → chunk-ZK226W6V.js.map} +0 -0
  779. /package/dist/{chunk-MQQRTH4U.js.map → chunk-ZLREFIZB.js.map} +0 -0
  780. /package/dist/{chunk-VDPQ2ZV2.js.map → chunk-ZX2ISBEF.js.map} +0 -0
  781. /package/dist/{condition-XKEW2LCM.js.map → condition-P2XD32QM.js.map} +0 -0
  782. /package/dist/{controls-4RFWTHFH.js.map → controls-FZUTJPKV.js.map} +0 -0
  783. /package/dist/{controls.btns-3QQ5FOKQ.js.map → controls.btns-AP67YWKW.js.map} +0 -0
  784. /package/dist/{controls.config-VHH2IGCI.js.map → controls.config-TEFY3NTE.js.map} +0 -0
  785. /package/dist/{cuminc-EHW6IH6V.js.map → cuminc-42GBJHD3.js.map} +0 -0
  786. /package/dist/{cuminc.integration.spec-B3EOIE4K.js.map → cuminc.integration.spec-BAY4JHVL.js.map} +0 -0
  787. /package/dist/{customdata.inputui-IPJHL7BX.js.map → customdata.inputui-IPM5K56K.js.map} +0 -0
  788. /package/dist/{dataDownload-GYFEC6XG.js.map → dataDownload-D7VCYBDT.js.map} +0 -0
  789. /package/dist/{dataDownload.integration.spec-V7WQ6AMV.js.map → dataDownload.integration.spec-SEBY2BIX.js.map} +0 -0
  790. /package/dist/{databrowser.ui-TFAJVFFF.js.map → databrowser.ui-5OC5MPZB.js.map} +0 -0
  791. /package/dist/{dictionary-2ZSMOJCN.js.map → dictionary-VVRWVLJX.js.map} +0 -0
  792. /package/dist/{dnaMethylation-RHNO5DAC.js.map → dnaMethylation-72IS3FRI.js.map} +0 -0
  793. /package/dist/{dnaMethylation.integration.spec-ET7OLMNC.js.map → dnaMethylation.integration.spec-U2LLSDGE.js.map} +0 -0
  794. /package/dist/{dofetch-UGCQ3OVW.js.map → dofetch-5ZRAQH5F.js.map} +0 -0
  795. /package/dist/{e2pca-SLRCDKF5.js.map → e2pca-AR6EKEJA.js.map} +0 -0
  796. /package/dist/{ep-FOFTKVBH.js.map → ep-JS5UUJQX.js.map} +0 -0
  797. /package/dist/{expclust.gdc.spec-FNOOSLCC.js.map → expclust.gdc.spec-73MGQ7RN.js.map} +0 -0
  798. /package/dist/{facet-UO5A7AGS.js.map → facet-AR3QKHCY.js.map} +0 -0
  799. /package/dist/{forms2-SFV4HHBA.js.map → forms2-UXEI7MUP.js.map} +0 -0
  800. /package/dist/{gb-3KR6MAGB.js.map → gb-RHDVYU2V.js.map} +0 -0
  801. /package/dist/{geneExpClustering-BCDXKSNU.js.map → geneExpClustering-L6KLCMPH.js.map} +0 -0
  802. /package/dist/{geneExpression-5UPKETEZ.js.map → geneExpression-GYT2XRE6.js.map} +0 -0
  803. /package/dist/{geneExpression-CXQ5HFEP.js.map → geneExpression-SKIU3NEP.js.map} +0 -0
  804. /package/dist/{geneExpression.unit.spec-7FVVD4UF.js.map → geneExpression.unit.spec-CWR6KDVK.js.map} +0 -0
  805. /package/dist/{geneORA-UC45CL2U.js.map → geneORA-C3TALK5P.js.map} +0 -0
  806. /package/dist/{geneRanking-OOQWVUIG.js.map → geneRanking-LLYLDPLV.js.map} +0 -0
  807. /package/dist/{geneVariant-BQFB7LKZ.js.map → geneVariant-PUSKBHPY.js.map} +0 -0
  808. /package/dist/{geneVariant-BYN7EWTT.js.map → geneVariant-YFMU6PHM.js.map} +0 -0
  809. /package/dist/{geneVariant.integration.spec-OESHXKBV.js.map → geneVariant.integration.spec-EJ5V46OQ.js.map} +0 -0
  810. /package/dist/{genefusion.ui-TOSPIGTE.js.map → genefusion.ui-XUHSKQKW.js.map} +0 -0
  811. /package/dist/{geneset-57DECCND.js.map → geneset-DEL5LXFZ.js.map} +0 -0
  812. /package/dist/{genomeBrowser.spec-CQP5JG35.js.map → genomeBrowser.spec-W5TVHOUJ.js.map} +0 -0
  813. /package/dist/{grin2-G4MBI5UC.js.map → grin2-FXAEGECD.js.map} +0 -0
  814. /package/dist/{gsea-VYAXSBM4.js.map → gsea-CNL6SHH5.js.map} +0 -0
  815. /package/dist/{hierCluster-4QKMY7GP.js.map → hierCluster-7V65PMIW.js.map} +0 -0
  816. /package/dist/{hierCluster-GFPFVB3Q.js.map → hierCluster-C44GHM4B.js.map} +0 -0
  817. /package/dist/{hierCluster.config-3A24DEKA.js.map → hierCluster.config-RU5JDPWM.js.map} +0 -0
  818. /package/dist/{hierCluster.integration.spec-6NTJYVN4.js.map → hierCluster.integration.spec-6YH5KE4H.js.map} +0 -0
  819. /package/dist/{hierCluster.interactivity-B2T6WS5R.js.map → hierCluster.interactivity-PK2L7BSW.js.map} +0 -0
  820. /package/dist/{hierCluster.renderers-R3RLK6BI.js.map → hierCluster.renderers-G3274UYA.js.map} +0 -0
  821. /package/dist/{imagePlot-YZBZRENG.js.map → imagePlot-5SEDMPBP.js.map} +0 -0
  822. /package/dist/{importPlot-LIXKD3WJ.js.map → importPlot-M3MKWRON.js.map} +0 -0
  823. /package/dist/{isoformExpression-ZZ5DL6AE.js.map → isoformExpression-PPMISWKT.js.map} +0 -0
  824. /package/dist/{isoformExpression.unit.spec-IH4247TT.js.map → isoformExpression.unit.spec-ENHCCQRZ.js.map} +0 -0
  825. /package/dist/{launch.adhoc-3YWVAF7R.js.map → launch.adhoc-XAG6H42J.js.map} +0 -0
  826. /package/dist/{leftlabel.sample-XFM45ZKO.js.map → leftlabel.sample-BSPCI6GR.js.map} +0 -0
  827. /package/dist/{lollipop-7K5R5KHB.js.map → lollipop-IZJ7E3YO.js.map} +0 -0
  828. /package/dist/{maf-SQVJHNUY.js.map → maf-54XWBQ73.js.map} +0 -0
  829. /package/dist/{maftimeline-RCPASNN2.js.map → maftimeline-3AJKAFS6.js.map} +0 -0
  830. /package/dist/{matrix-KHTDB56P.js.map → matrix-AJPMHUXG.js.map} +0 -0
  831. /package/dist/{matrix-YTHWIMBP.js.map → matrix-ZMXNOESU.js.map} +0 -0
  832. /package/dist/{matrix.cells-KNDVYI2S.js.map → matrix.cells-E3LEVA7U.js.map} +0 -0
  833. /package/dist/{matrix.config-6BHBCTXE.js.map → matrix.config-4WLSFMTY.js.map} +0 -0
  834. /package/dist/{matrix.data-VWJQ7N4L.js.map → matrix.data-WMOTOB6C.js.map} +0 -0
  835. /package/dist/{matrix.dom-2SU4EYLI.js.map → matrix.dom-F7AN3QGE.js.map} +0 -0
  836. /package/dist/{matrix.groups-5AUHEO52.js.map → matrix.groups-BGMZZ6CM.js.map} +0 -0
  837. /package/dist/{matrix.integration.spec-Q2BXNCUO.js.map → matrix.integration.spec-ENRPVB7R.js.map} +0 -0
  838. /package/dist/{matrix.interactivity-FEEWY34M.js.map → matrix.interactivity-IMWERCZF.js.map} +0 -0
  839. /package/dist/{matrix.layout-FWWM6QQO.js.map → matrix.layout-5DDZWLNX.js.map} +0 -0
  840. /package/dist/{matrix.legend-QT3PMREX.js.map → matrix.legend-RJAFOZHQ.js.map} +0 -0
  841. /package/dist/{matrix.renderers-M6MJO5IU.js.map → matrix.renderers-VFQZG5JP.js.map} +0 -0
  842. /package/dist/{matrix.serieses-NTKMKT22.js.map → matrix.serieses-GJWHSBG4.js.map} +0 -0
  843. /package/dist/{matrix.sort-TTHPJ4XC.js.map → matrix.sort-KIJENIT2.js.map} +0 -0
  844. /package/dist/{matrix.sort.unit.spec-XZI2KPNC.js.map → matrix.sort.unit.spec-ZA5DRNL6.js.map} +0 -0
  845. /package/dist/{matrix.sorterUi-FFLYKBGC.js.map → matrix.sorterUi-3KEDVLGW.js.map} +0 -0
  846. /package/dist/{matrix.sorterUi.unit.spec-6FVHTGSN.js.map → matrix.sorterUi.unit.spec-7TPOJ46U.js.map} +0 -0
  847. /package/dist/{mavb-FZDN27QY.js.map → mavb-73BXZ7MO.js.map} +0 -0
  848. /package/dist/{mds.fimo-SSFKQ3BH.js.map → mds.fimo-L7VVAOXQ.js.map} +0 -0
  849. /package/dist/{mds.samplescatterplot-BMTTX3TB.js.map → mds.samplescatterplot-6P75XEWB.js.map} +0 -0
  850. /package/dist/{mds.survivalplot-PL75RDYI.js.map → mds.survivalplot-GCVE7XGO.js.map} +0 -0
  851. /package/dist/{numericDictTermCluster-NJUXCQYH.js.map → numericDictTermCluster-OMXIURRD.js.map} +0 -0
  852. /package/dist/{oncomatrix-BZDCCEWH.js.map → oncomatrix-BFWV2IC4.js.map} +0 -0
  853. /package/dist/{oncomatrix.spec-5A4A4JLV.js.map → oncomatrix.spec-J6IAY3O6.js.map} +0 -0
  854. /package/dist/{plot.2dvaf-AC7LW56S.js.map → plot.2dvaf-ESJAB2F3.js.map} +0 -0
  855. /package/dist/{plot.app-DOOWDQ3U.js.map → plot.app-T7CQMBRV.js.map} +0 -0
  856. /package/dist/{plot.barplot-RNJWREG5.js.map → plot.barplot-HAWPMPPU.js.map} +0 -0
  857. /package/dist/{plot.boxplot-CRAEUBQF.js.map → plot.boxplot-4QUORFXY.js.map} +0 -0
  858. /package/dist/{plot.brainImaging-ZESEULN6.js.map → plot.brainImaging-HG6I3GJW.js.map} +0 -0
  859. /package/dist/{plot.disco-B4KBP6RK.js.map → plot.disco-LPH7F6YW.js.map} +0 -0
  860. /package/dist/{plot.dzi-2UMRV6IF.js.map → plot.dzi-DYAY4D4E.js.map} +0 -0
  861. /package/dist/{plot.ssgq-FVZ27Z2K.js.map → plot.ssgq-CF5VIGYJ.js.map} +0 -0
  862. /package/dist/{plot.vaf2cov-3OXCIEAX.js.map → plot.vaf2cov-7HZCKNK6.js.map} +0 -0
  863. /package/dist/{plot.wsi-UKTLZSYW.js.map → plot.wsi-MU6AXOWO.js.map} +0 -0
  864. /package/dist/{profileForms-SBNPRIFT.js.map → profileForms-TIT4JUEJ.js.map} +0 -0
  865. /package/dist/{profilePlot-PPI4IDP4.js.map → profilePlot-QFGRAZQA.js.map} +0 -0
  866. /package/dist/{qualitative-4O6KAGEA.js.map → qualitative-YWP4YUPF.js.map} +0 -0
  867. /package/dist/{radar2-ICKCJY4T.js.map → radar2-TKSHL54E.js.map} +0 -0
  868. /package/dist/{radarFacility2-HEBBSM3T.js.map → radarFacility2-FHRFLBLF.js.map} +0 -0
  869. /package/dist/{regression-YFQJE2EP.js.map → regression-5XG5LXP7.js.map} +0 -0
  870. /package/dist/{regression.inputs-A2JVBVZ7.js.map → regression.inputs-QHXK7ZYY.js.map} +0 -0
  871. /package/dist/{regression.inputs.term-CTVNS5MO.js.map → regression.inputs.term-YYO3CR2D.js.map} +0 -0
  872. /package/dist/{regression.inputs.values.table-X7SI6EDO.js.map → regression.inputs.values.table-3I2FCON2.js.map} +0 -0
  873. /package/dist/{regression.integration.spec-NRDEVBWS.js.map → regression.integration.spec-QVDGCKVT.js.map} +0 -0
  874. /package/dist/{regression.results-XVB6CIGW.js.map → regression.results-B7LVT2WG.js.map} +0 -0
  875. /package/dist/{regression.spec-TNB5HBY5.js.map → regression.spec-ISYKKQOM.js.map} +0 -0
  876. /package/dist/{report-5VDIBC2W.js.map → report-TF6Z3Y44.js.map} +0 -0
  877. /package/dist/{sampleScatter.spec-XDW7SCYA.js.map → sampleScatter.spec-2VW55XIZ.js.map} +0 -0
  878. /package/dist/{sampleView-FLUSGZCM.js.map → sampleView-DNNJRAMU.js.map} +0 -0
  879. /package/dist/{samplelst-4WPG5UBN.js.map → samplelst-726II3LN.js.map} +0 -0
  880. /package/dist/{samplematrix-YJGMSXUJ.js.map → samplematrix-TBPW4URH.js.map} +0 -0
  881. /package/dist/{sc-DHU5KSEJ.js.map → sc-GBYH3W4S.js.map} +0 -0
  882. /package/dist/{selectGenomeWithTklst-BVBMVRMQ.js.map → selectGenomeWithTklst-RCAYDV6D.js.map} +0 -0
  883. /package/dist/{singleCellCellType-DADK5UKZ.js.map → singleCellCellType-IQYCKUT6.js.map} +0 -0
  884. /package/dist/{singleCellCellType.unit.spec-X25RMBJ3.js.map → singleCellCellType.unit.spec-ZEWA2IFI.js.map} +0 -0
  885. /package/dist/{singleCellGeneExpression-3UEZWI4E.js.map → singleCellGeneExpression-STLTBXJQ.js.map} +0 -0
  886. /package/dist/{singleCellGeneExpression.unit.spec-5GU3JWE6.js.map → singleCellGeneExpression.unit.spec-W6FPS5ZU.js.map} +0 -0
  887. /package/dist/{singleCellPlot-TFRZG73T.js.map → singleCellPlot-7XH7NIL4.js.map} +0 -0
  888. /package/dist/{singlecell-KR6JYFAY.js.map → singlecell-IDZB2MXW.js.map} +0 -0
  889. /package/dist/{singlecell-HQH6EWJO.js.map → singlecell-JCXR7X5U.js.map} +0 -0
  890. /package/dist/{snp-ACIZ7D5X.js.map → snp-QOKI26PO.js.map} +0 -0
  891. /package/dist/{snp.unit.spec-653HGJBM.js.map → snp.unit.spec-DTPZAALW.js.map} +0 -0
  892. /package/dist/{snplocus-AH6KJCVN.js.map → snplocus-BKUJYANW.js.map} +0 -0
  893. /package/dist/{spliceevent.a53ss.diagram-MKJLJDOG.js.map → spliceevent.a53ss.diagram-4O54ORKZ.js.map} +0 -0
  894. /package/dist/{spliceevent.exonskip.diagram-PSEVCDH4.js.map → spliceevent.exonskip.diagram-KOIOS6IV.js.map} +0 -0
  895. /package/dist/{spliceevent.noeventdiagram-T2LHGFN7.js.map → spliceevent.noeventdiagram-YGUGQMVE.js.map} +0 -0
  896. /package/dist/{ssGSEA-QFMYBITZ.js.map → ssGSEA-UZMBIHVD.js.map} +0 -0
  897. /package/dist/{ssGSEA.unit.spec-SQW7KFWE.js.map → ssGSEA.unit.spec-4YO4E3T7.js.map} +0 -0
  898. /package/dist/{stattable-QDIUQCMG.js.map → stattable-MDABSW3F.js.map} +0 -0
  899. /package/dist/{summarizeCnvGeneexp-EVRTBY3L.js.map → summarizeCnvGeneexp-HV3DHIW4.js.map} +0 -0
  900. /package/dist/{summarizeGeneexpSurvival-O3MGRS6K.js.map → summarizeGeneexpSurvival-VGPRWYQ5.js.map} +0 -0
  901. /package/dist/{summarizeMutationCnv-RZ2DZ2XO.js.map → summarizeMutationCnv-N3JEB4DJ.js.map} +0 -0
  902. /package/dist/{summarizeMutationDiagnosis-V2DISQTC.js.map → summarizeMutationDiagnosis-6U4DBLG5.js.map} +0 -0
  903. /package/dist/{summarizeMutationSurvival-FTTWJBUG.js.map → summarizeMutationSurvival-S7NLAVEI.js.map} +0 -0
  904. /package/dist/{summary-QKBTZINC.js.map → summary-NPR56I4S.js.map} +0 -0
  905. /package/dist/{summary.integration.spec-54HA7BC2.js.map → summary.integration.spec-HWNJWLKT.js.map} +0 -0
  906. /package/dist/{summaryInput-4RLZT6RW.js.map → summaryInput-DO73NGDQ.js.map} +0 -0
  907. /package/dist/{sunburst-SMKD45XD.js.map → sunburst-MMXSGJSL.js.map} +0 -0
  908. /package/dist/{survival-YQNA3WP7.js.map → survival-7AIKFGV5.js.map} +0 -0
  909. /package/dist/{survival-BAW5ME6J.js.map → survival-UK332X6L.js.map} +0 -0
  910. /package/dist/{survival.integration.spec-2AHXNMH2.js.map → survival.integration.spec-YMTEKEGB.js.map} +0 -0
  911. /package/dist/{svgraph-5Z7VAIVR.js.map → svgraph-MLLAYO4A.js.map} +0 -0
  912. /package/dist/{svmr-PHD76RV4.js.map → svmr-PYW4PLT3.js.map} +0 -0
  913. /package/dist/{table-GMRAOIWZ.js.map → table-Y3ED2444.js.map} +0 -0
  914. /package/dist/{termCollection-QLKTRXUR.js.map → termCollection-3XVL75II.js.map} +0 -0
  915. /package/dist/{termCollection-MEBY34TJ.js.map → termCollection-VAB53YGO.js.map} +0 -0
  916. /package/dist/{termCollection.unit.spec-6B53SW2Q.js.map → termCollection.unit.spec-DYPWNVEZ.js.map} +0 -0
  917. /package/dist/{termInfo-2Z4V2QLE.js.map → termInfo-6MJDJSDW.js.map} +0 -0
  918. /package/dist/{tk-X46SEOL7.js.map → tk-GUGJYKJ2.js.map} +0 -0
  919. /package/dist/{tp.ui-XV7CL7CA.js.map → tp.ui-WGETBYJQ.js.map} +0 -0
  920. /package/dist/{tvs.dt-U6SIZTXW.js.map → tvs.dt-JWF4I3KY.js.map} +0 -0
  921. /package/dist/{tvs.dtcnv.categorical-6YGEKMHW.js.map → tvs.dtcnv.categorical-72Y5QMPL.js.map} +0 -0
  922. /package/dist/{tvs.dtcnv.continuous-CQFEENBO.js.map → tvs.dtcnv.continuous-73LHWTU5.js.map} +0 -0
  923. /package/dist/{tvs.dtfusion-NOBT2JPI.js.map → tvs.dtfusion-LP6HUMZU.js.map} +0 -0
  924. /package/dist/{tvs.dtsnvindel-6GTCSVAV.js.map → tvs.dtsnvindel-23N2CFZJ.js.map} +0 -0
  925. /package/dist/{tvs.dtsv-PMI4YVI5.js.map → tvs.dtsv-DILQVKYM.js.map} +0 -0
  926. /package/dist/{tvs.samplelst-HVNYKHXG.js.map → tvs.samplelst-GV4VSCRF.js.map} +0 -0
  927. /package/dist/{tvs.termCollection-EWGTT75Z.js.map → tvs.termCollection-KBDNXK7X.js.map} +0 -0
  928. /package/dist/{violin-MKWRB25Z.js.map → violin-TYUP7FB5.js.map} +0 -0
  929. /package/dist/{violin.integration.spec-CNWJ43SD.js.map → violin.integration.spec-ULRFK2A6.js.map} +0 -0
  930. /package/dist/{violin.interactivity-UXOMTGSD.js.map → violin.interactivity-2QZVQWQJ.js.map} +0 -0
  931. /package/dist/{violin.renderer-67Q6YGYQ.js.map → violin.renderer-HCDSN62Z.js.map} +0 -0
  932. /package/dist/{vocabulary-AKXE7SNU.js.map → vocabulary-I4CMPN2Z.js.map} +0 -0
@@ -0,0 +1,3237 @@
1
+ import {
2
+ InvalidDataUI,
3
+ configUiInit,
4
+ fillbar,
5
+ getMaxLabelWidth,
6
+ getNormalRoot,
7
+ renderTable,
8
+ svgLegend,
9
+ table2col
10
+ } from "./chunk-L4TUTGTA.js";
11
+ import "./chunk-HJ6L54YS.js";
12
+ import "./chunk-LSEFWW72.js";
13
+ import "./chunk-4FKWINMK.js";
14
+ import {
15
+ Menu
16
+ } from "./chunk-HYOEWQ5P.js";
17
+ import "./chunk-HBW42TDT.js";
18
+ import "./chunk-G6O3URDN.js";
19
+ import "./chunk-FN5XPUPH.js";
20
+ import {
21
+ topBarInit
22
+ } from "./chunk-IIT367QZ.js";
23
+ import "./chunk-RZGEKL77.js";
24
+ import "./chunk-XVZ5UJWU.js";
25
+ import "./chunk-WS3NUPNV.js";
26
+ import {
27
+ dofetch3
28
+ } from "./chunk-6VKTEMFV.js";
29
+ import "./chunk-7IYJZZQI.js";
30
+ import {
31
+ copyMerge,
32
+ getCompInit,
33
+ multiInit
34
+ } from "./chunk-M3J4MINX.js";
35
+ import "./chunk-PF4DSFDR.js";
36
+ import "./chunk-S4JLRRKK.js";
37
+ import "./chunk-TVADJLMF.js";
38
+ import {
39
+ bplen,
40
+ dtcnv,
41
+ dtfusionrna,
42
+ dtloh,
43
+ dtsnvindel,
44
+ dtsv,
45
+ mclass
46
+ } from "./chunk-EBKERML3.js";
47
+ import "./chunk-DD4R5P6W.js";
48
+ import "./chunk-JNITUVXP.js";
49
+ import {
50
+ arc_default,
51
+ line_default,
52
+ pie_default,
53
+ ribbon_default
54
+ } from "./chunk-KSGA62R2.js";
55
+ import "./chunk-LOZEKOES.js";
56
+ import "./chunk-TOU7EVFQ.js";
57
+ import {
58
+ linear,
59
+ ticks
60
+ } from "./chunk-OAWQ6LOO.js";
61
+ import "./chunk-TLT4YIG3.js";
62
+ import "./chunk-KYBIQBXE.js";
63
+ import {
64
+ pointer_default,
65
+ select_default
66
+ } from "./chunk-I6Y4O3RR.js";
67
+ import "./chunk-OMR2DT66.js";
68
+ import "./chunk-DQC5FFGV.js";
69
+ import "./chunk-HFNDKYVF.js";
70
+
71
+ // plots/disco/arc/FullArcRenderer.ts
72
+ var FullArcRenderer = class {
73
+ constructor(radius, width, color) {
74
+ this.radius = radius;
75
+ this.width = width;
76
+ this.color = color;
77
+ }
78
+ render(holder) {
79
+ const donutGenerator = arc_default();
80
+ const arc = {
81
+ startAngle: 0,
82
+ endAngle: Math.PI * 2,
83
+ innerRadius: this.radius,
84
+ outerRadius: this.radius + this.width,
85
+ color: this.color,
86
+ text: "No label"
87
+ };
88
+ const array = [];
89
+ array.push(arc);
90
+ const donutArc = holder.append("g");
91
+ donutArc.selectAll("path").data(array).enter().append("path").attr("d", (d) => donutGenerator(d)).attr("fill", (d) => d.color);
92
+ }
93
+ };
94
+
95
+ // plots/disco/menu/MenuProvider.ts
96
+ var MenuProvider = class {
97
+ static create() {
98
+ const menu = new Menu({ padding: 5 });
99
+ menu.d.style("border", "1px solid #FFF").style("position", "absolute").style("z-index", 1001);
100
+ return menu;
101
+ }
102
+ };
103
+
104
+ // plots/disco/fusion/FusionColorProvider.ts
105
+ var FusionColorProvider = class {
106
+ static getColor(chrA, chrB) {
107
+ if (chrA != chrB) {
108
+ return "#6A3D9A" /* Interchromosomal */.valueOf();
109
+ } else {
110
+ return "#1B9E77" /* Intrachromosomal */.valueOf();
111
+ }
112
+ }
113
+ };
114
+
115
+ // plots/disco/fusion/FusionRenderer.ts
116
+ var FusionRenderer = class {
117
+ constructor(genome) {
118
+ this.genome = genome;
119
+ }
120
+ render(holder, fusions, opacity = 1) {
121
+ let radius = 0;
122
+ const fusionsWithTarget = fusions.filter((f) => f.target);
123
+ if (fusionsWithTarget.length > 0) {
124
+ radius = fusionsWithTarget[0].target.radius;
125
+ const fullArcRenderer = new FullArcRenderer(radius, 2, "#6464641A");
126
+ fullArcRenderer.render(holder);
127
+ } else return;
128
+ const ribbon = ribbon_default().radius(radius);
129
+ const ribbons = holder.selectAll(".chord").data(fusions);
130
+ const menu = MenuProvider.create();
131
+ const createTooltip = this.createTooltip.bind(this);
132
+ const genome = this.genome;
133
+ ribbons.enter().append("path").attr("class", "chord").attr("d", ribbon).attr("fill", (fusion) => {
134
+ return FusionColorProvider.getColor(
135
+ fusion.source.positionInChromosome.chromosome,
136
+ fusion.target.positionInChromosome.chromosome
137
+ );
138
+ }).style("opacity", opacity).each(function(d) {
139
+ const path = select_default(this);
140
+ const tip = MenuProvider.create();
141
+ path.on("click", async function(event) {
142
+ tip.clear().show(event.x, event.y);
143
+ const div = tip.d.append("div");
144
+ await makeSvgraph(d, div, genome);
145
+ });
146
+ }).on("mouseover", async function(mouseEvent, fusion) {
147
+ const table = table2col({ holder: menu.d });
148
+ createTooltip(table, fusion);
149
+ menu.show(mouseEvent.x, mouseEvent.y);
150
+ }).on("mouseout", () => {
151
+ menu.clear();
152
+ menu.hide();
153
+ });
154
+ }
155
+ createTooltip(table, fusion) {
156
+ {
157
+ const [td1, td2] = table.addRow();
158
+ td1.text("Data type");
159
+ td2.append("span").style("margin-left", "5px").text("Fusion transcript");
160
+ }
161
+ {
162
+ const positionInChromosomeSource = fusion.source.positionInChromosome;
163
+ const positionInChromosomeTarget = fusion.target.positionInChromosome;
164
+ const [td1, td2] = table.addRow();
165
+ td1.text("Position");
166
+ td2.append("span").style("margin-left", "5px").text(
167
+ ` ${fusion.source.gene || ""} ${positionInChromosomeSource.chromosome}:${positionInChromosomeSource.position} ${fusion.source.strand === "+" ? "forward" : "reverse"} > ${fusion.target.gene || ""} ${positionInChromosomeTarget.chromosome}:${positionInChromosomeTarget.position} ${fusion.target.strand === "+" ? "forward" : "reverse"} `
168
+ );
169
+ }
170
+ }
171
+ };
172
+ async function makeSvgraph(fusion, div, genome) {
173
+ const wait = div.append("div").text("Loading...");
174
+ const svpair = {
175
+ a: {
176
+ chr: fusion.source.positionInChromosome.chromosome,
177
+ position: fusion.source.positionInChromosome.position,
178
+ strand: fusion.source.strand
179
+ },
180
+ b: {
181
+ chr: fusion.target.positionInChromosome.chromosome,
182
+ position: fusion.target.positionInChromosome.position,
183
+ strand: fusion.target.strand
184
+ }
185
+ };
186
+ await getGm(svpair.a, genome.name, fusion.source.gene);
187
+ await getGm(svpair.b, genome.name, fusion.target.gene);
188
+ wait.remove();
189
+ const _ = await import("./svgraph-MLLAYO4A.js");
190
+ _.default({
191
+ pairlst: [svpair],
192
+ genome,
193
+ holder: div
194
+ });
195
+ }
196
+ async function getGm(p, genome, name) {
197
+ const d = await dofetch3("isoformbycoord", {
198
+ body: { genome, chr: p.chr, pos: p.position }
199
+ });
200
+ if (d.error) throw d.error;
201
+ const u = d.lst.find((i) => i.isdefault && name === i.name) || d.lst[0];
202
+ if (u) {
203
+ p.name = u.name;
204
+ p.gm = { isoform: u.isoform };
205
+ }
206
+ }
207
+
208
+ // plots/disco/DiscoRenderer.ts
209
+ var DiscoRenderer = class {
210
+ constructor(renders, legendRenderer, genome) {
211
+ this.renders = renders;
212
+ this.legendRenderer = legendRenderer;
213
+ this.fusionRenderer = new FusionRenderer(genome);
214
+ }
215
+ render(holder, viewModel, onCnvSourceSelect) {
216
+ const svgDiv = holder.append("div").style("display", "inline-block").style("font-family", "Arial");
217
+ const svg = svgDiv.append("svg").attr("id", "sjpp_disco_plot").attr("data-testid", "sjpp_disco_plot").attr("width", viewModel.width).attr("height", viewModel.height + viewModel.legendHeight);
218
+ const mainG = svg.append("g").attr("class", "mainG").attr(
219
+ "transform",
220
+ `translate(${viewModel.settings.rings.labelLinesInnerRadius + viewModel.settings.rings.labelsToLinesDistance + 100},${viewModel.height / 2})`
221
+ );
222
+ for (const [ringType, renderer] of this.renders) {
223
+ const elements = viewModel.getElements(ringType);
224
+ const collisions = viewModel.getCollisions(ringType);
225
+ renderer.render(mainG, elements, collisions);
226
+ }
227
+ this.fusionRenderer.render(mainG, viewModel.fusions, viewModel.settings.Disco.fusionOpacity);
228
+ if (viewModel.settings.Disco.centerText) {
229
+ const chrRingBbox = mainG.select('[data-testid="sjpp_chromosomes_arc_group"]').node().getBBox();
230
+ const text = viewModel.settings.Disco.centerText.length > 20 ? viewModel.settings.Disco.centerText.slice(0, 20) + "..." : viewModel.settings.Disco.centerText;
231
+ const textElem = mainG.append("text").attr("class", "sjpp-disco-center-text").text(text);
232
+ const textBbox = textElem.node().getBBox();
233
+ textElem.attr("transform", `translate(${chrRingBbox.x + chrRingBbox.width / 2 - textBbox.width / 2},0)`);
234
+ }
235
+ this.legendRenderer.render(
236
+ mainG,
237
+ viewModel.legend,
238
+ -1 * (viewModel.settings.rings.labelLinesInnerRadius + viewModel.settings.rings.labelsToLinesDistance + 75),
239
+ viewModel.width,
240
+ viewModel.height / 2,
241
+ viewModel,
242
+ onCnvSourceSelect
243
+ );
244
+ }
245
+ };
246
+
247
+ // plots/disco/interactions/DiscoInteractions.ts
248
+ var DiscoInteractions = class {
249
+ constructor(discoApp) {
250
+ this.discoApp = discoApp;
251
+ this.downloadClickListener = (svg) => {
252
+ const downloadImgName = this.discoApp.state.settings.downloadImgName || "disco.plot";
253
+ const a = document.createElement("a");
254
+ document.body.appendChild(a);
255
+ a.addEventListener(
256
+ "click",
257
+ () => {
258
+ const serializer = new XMLSerializer();
259
+ const svg_blob = new Blob([serializer.serializeToString(svg)], {
260
+ type: "image/svg+xml"
261
+ });
262
+ a.download = downloadImgName + ".svg";
263
+ a.href = URL.createObjectURL(svg_blob);
264
+ document.body.removeChild(a);
265
+ },
266
+ false
267
+ );
268
+ a.click();
269
+ };
270
+ this.geneClickListener = async (gene, mnames) => {
271
+ const { filter, filter0 } = this.discoApp.app.getState().termfilter;
272
+ const arg = {
273
+ holder: this.discoApp.app.opts.holder,
274
+ genome: this.discoApp.app.opts.state.args.genome,
275
+ nobox: true,
276
+ query: gene,
277
+ tklst: [
278
+ {
279
+ type: "mds3",
280
+ dslabel: this.discoApp.app.opts.state.vocab.dslabel,
281
+ hlaachange: mnames.join(","),
282
+ filter0,
283
+ filterObj: getNormalRoot(filter)
284
+ // must not pass filter as frozen. pass unfrozen, normalized copy so mds3 code will work
285
+ }
286
+ ]
287
+ };
288
+ const _ = await import("./block.init-43IUNDNB.js");
289
+ await _.default(arg);
290
+ };
291
+ this.colorScaleNumericInputsCallback = async (obj) => {
292
+ const callAppDispatch = (settings) => {
293
+ this.discoApp.app.dispatch({
294
+ type: "plot_edit",
295
+ id: this.discoApp.id,
296
+ config: { settings: { Disco: Object.assign({ cnvCutoffMode: obj.cutoffMode }, settings) } }
297
+ });
298
+ };
299
+ if (obj.cutoffMode == "auto") {
300
+ if (obj.min == null || obj.max == null)
301
+ throw new Error('Color scale must return min and max if cutoffMode "auto"');
302
+ callAppDispatch({
303
+ cnvCapping: this.discoApp.state.settings.cnv.capping,
304
+ cnvPercentile: this.discoApp.state.settings.cnv.percentile
305
+ });
306
+ } else if (obj.cutoffMode == "fixed") {
307
+ if (obj.min == null || obj.max == null)
308
+ throw new Error('Color scale must return min and max if cutoffMode "fixed"');
309
+ const diffValue = obj.max !== this.discoApp.state.settings.cnv.capping ? obj.max : Math.abs(obj.min);
310
+ callAppDispatch({
311
+ cnvCapping: diffValue
312
+ });
313
+ } else if (obj.cutoffMode == "percentile") callAppDispatch({ cnvPercentile: obj.percentile });
314
+ else throw new Error("Unknown cutoff mode returned from dom/ColorScale");
315
+ };
316
+ this.onMutationWaterfallColorChange = (color) => {
317
+ this.discoApp.app.dispatch({
318
+ type: "plot_edit",
319
+ id: this.discoApp.id,
320
+ config: { settings: { Disco: { mutationWaterfallColor: color } } }
321
+ });
322
+ };
323
+ }
324
+ };
325
+
326
+ // plots/disco/chromosome/Reference.ts
327
+ var Reference = class {
328
+ /**
329
+ * Creates a Reference object that contains information about chromosomes.
330
+ * @param settings State settings
331
+ * @param chromosomes Chromosome order. This function formats into an obj with `chr` removed.
332
+ * @param chromosomeOverride Obj of chromsome keys and sizes. Filtered to remove hidden chromosomes in settings.
333
+ */
334
+ constructor(settings, chromosomes, chromosomeOverride) {
335
+ this.chromosomes = [];
336
+ this.chromosomesOrder = [];
337
+ this.keysArray = [];
338
+ this.totalSizeArray = [];
339
+ this.chrSizesArray = [];
340
+ const chrSizes = chromosomeOverride || chromosomes;
341
+ this.settings = settings;
342
+ this.chromosomesOrder = [];
343
+ let totalSize = 0;
344
+ this.totalPadAngle = Object.keys(chrSizes).length * this.settings.padAngle;
345
+ this.totalChromosomesAngle = 2 * Math.PI - this.totalPadAngle;
346
+ for (const chr in chrSizes) {
347
+ const key = chr.slice(0, 3) === "chr" ? chr.slice(3) : chr;
348
+ this.chromosomesOrder.push(chr);
349
+ this.keysArray.push(key);
350
+ this.totalSizeArray.push(totalSize);
351
+ this.chrSizesArray.push(chrSizes[chr]);
352
+ totalSize += chrSizes[chr];
353
+ }
354
+ this.totalSize = totalSize;
355
+ let lastAngle = 0;
356
+ for (let i = 0; i < this.keysArray.length; i++) {
357
+ const chromosomeAngle = this.totalChromosomesAngle * (this.chrSizesArray[i] / totalSize);
358
+ const startAngle = i == 0 ? this.settings.padAngle / 2 : lastAngle + this.settings.padAngle;
359
+ const endAngle = i == 0 ? this.settings.padAngle / 2 + chromosomeAngle : lastAngle + this.settings.padAngle + chromosomeAngle;
360
+ const chromosome = {
361
+ start: this.totalSizeArray[i],
362
+ size: this.chrSizesArray[i],
363
+ factor: 1,
364
+ startAngle,
365
+ endAngle,
366
+ angle: (startAngle + endAngle) / 2,
367
+ innerRadius: this.settings.rings.chromosomeInnerRadius,
368
+ outerRadius: this.settings.rings.chromosomeInnerRadius + this.settings.rings.chromosomeWidth,
369
+ color: "#AAA",
370
+ text: this.keysArray[i]
371
+ };
372
+ this.chromosomes.push(chromosome);
373
+ if (chromosome.endAngle != null) {
374
+ lastAngle = chromosome.endAngle;
375
+ }
376
+ }
377
+ }
378
+ };
379
+
380
+ // plots/disco/data/DataObjectMapper.ts
381
+ var DataObjectMapper = class {
382
+ constructor(sampleName, prioritizedGenes) {
383
+ this.sampleName = sampleName;
384
+ this.prioritizedGenes = prioritizedGenes;
385
+ }
386
+ map(dObject) {
387
+ return {
388
+ dt: dObject.dt,
389
+ mname: dObject.mname,
390
+ mClass: dObject.class,
391
+ gene: dObject.gene,
392
+ chr: dObject.chr,
393
+ ref: dObject.ref,
394
+ alt: dObject.alt,
395
+ vafs: dObject.vafs,
396
+ position: dObject.pos ? dObject.pos : dObject.position,
397
+ poschr: dObject.poschr,
398
+ posbins: dObject.posbins,
399
+ poslabel: dObject.poslabel,
400
+ sampleName: this.sampleName,
401
+ ssm_id: dObject.ssm_id,
402
+ start: dObject.start,
403
+ stop: dObject.stop,
404
+ value: dObject.value,
405
+ segmean: dObject.segmean,
406
+ isPrioritized: this.prioritizedGenes.some((cancerGene) => cancerGene == dObject.gene),
407
+ chrA: dObject.chrA,
408
+ chrB: dObject.chrB,
409
+ geneA: dObject.geneA,
410
+ geneB: dObject.geneB,
411
+ posA: dObject.posA,
412
+ posB: dObject.posB,
413
+ strandA: dObject.strandA,
414
+ strandB: dObject.strandB
415
+ };
416
+ }
417
+ };
418
+
419
+ // plots/disco/data/PercentileMapper.ts
420
+ var PercentileMapper = class {
421
+ map(data, percentile) {
422
+ return this.calculatePercentileForPositivesAndNegatives(data, percentile);
423
+ }
424
+ calculatePercentileForPositivesAndNegatives(data, percentile) {
425
+ const positives = data.filter((x) => x > 0);
426
+ const negatives = data.filter((x) => x < 0).map((x) => -1 * x);
427
+ let positive = NaN;
428
+ let negative = NaN;
429
+ if (positives.length > 0) {
430
+ positive = this.calculatePercentile(positives, percentile);
431
+ }
432
+ if (negatives.length > 0) {
433
+ negative = -1 * this.calculatePercentile(negatives, percentile);
434
+ }
435
+ return { positive, negative };
436
+ }
437
+ calculatePercentile(data, percentile) {
438
+ if (data.length === 0) {
439
+ throw new Error("Array must contain at least one element.");
440
+ }
441
+ const sortedValues = data.sort((a, b) => a - b);
442
+ const index = percentile / 100 * (sortedValues.length - 1);
443
+ const lowerIndex = Math.floor(index);
444
+ const upperIndex = Math.ceil(index);
445
+ const fraction = index - lowerIndex;
446
+ if (lowerIndex === upperIndex) {
447
+ return sortedValues[lowerIndex];
448
+ }
449
+ return sortedValues[lowerIndex] + fraction * (sortedValues[upperIndex] - sortedValues[lowerIndex]);
450
+ }
451
+ };
452
+
453
+ // plots/disco/data/DataMapper.ts
454
+ var DataMapper = class _DataMapper {
455
+ constructor(settings, reference, sample, prioritizedGenes = []) {
456
+ // remove fields and extract filters to seperate classes
457
+ this.labelData = [];
458
+ this.nonExonicSnvData = [];
459
+ this.nonExonicInnerRadius = 0;
460
+ this.snvRingDataMap = /* @__PURE__ */ new Map();
461
+ this.snvInnerRadius = 0;
462
+ this.snvData = [];
463
+ this.bpx = 0;
464
+ this.onePxArcAngle = 0;
465
+ this.filteredSnvData = [];
466
+ this.filteredSnvCountByChr = /* @__PURE__ */ new Map();
467
+ this.lohData = [];
468
+ this.lohInnerRadius = 0;
469
+ this.cnvData = [];
470
+ this.cnvInnerRadius = 0;
471
+ this.fusionData = [];
472
+ this.fusionRadius = 0;
473
+ this.hasPrioritizedGenes = false;
474
+ this.hasWaterfallEligibleChromosome = false;
475
+ this.invalidEntries = [];
476
+ this.cnvLossMaxValue = 0;
477
+ this.cnvGainMaxValue = 0;
478
+ this.percentilePositive = 0;
479
+ this.percentileNegative = 0;
480
+ this.cnvMaxPercentileAbs = 0;
481
+ this.mutationWaterfallData = [];
482
+ this.mutationWaterfallInnerRadius = 0;
483
+ this.mutationWaterfallRangeMin = Infinity;
484
+ this.mutationWaterfallRangeMax = -Infinity;
485
+ this.lohMaxValue = void 0;
486
+ this.lohMinValue = void 0;
487
+ this.snvFilter = (data) => data.dt == dtsnvindel;
488
+ this.fusionFilter = (data) => data.dt == dtfusionrna || data.dt == dtsv;
489
+ this.cnvFilter = (data) => data.dt == dtcnv;
490
+ this.lohFilter = (data) => data.dt == dtloh;
491
+ this.compareData = (a, b) => {
492
+ const chrDiff = this.reference.chromosomesOrder.indexOf(a.chr) - this.reference.chromosomesOrder.indexOf(b.chr);
493
+ if (chrDiff != 0) {
494
+ return chrDiff;
495
+ }
496
+ const aPos = a.pos ? a.pos : a.start;
497
+ const bPos = b.pos ? b.pos : b.start;
498
+ return aPos - bPos;
499
+ };
500
+ this.settings = settings;
501
+ this.reference = reference;
502
+ this.sample = sample;
503
+ this.excludedChromosomes = this.settings.Disco.hiddenChromosomes;
504
+ this.lastInnerRadious = this.settings.rings.chromosomeInnerRadius;
505
+ this.gainCapped = this.settings.Disco.cnvCapping;
506
+ this.lossCapped = -1 * this.settings.Disco.cnvCapping;
507
+ this.nonExonicFilter = (data) => {
508
+ if (prioritizedGenes.length > 0 && this.settings.Disco.prioritizeGeneLabelsByGeneSets) {
509
+ return prioritizedGenes.includes(data.gene) && settings.rings.nonExonicFilterValues.includes(ViewModelMapper.snvClassLayer[data.mClass]);
510
+ } else {
511
+ return settings.rings.nonExonicFilterValues.includes(ViewModelMapper.snvClassLayer[data.mClass]);
512
+ }
513
+ };
514
+ this.snvRingFilter = (data) => {
515
+ if (prioritizedGenes.length > 0 && this.settings.Disco.prioritizeGeneLabelsByGeneSets) {
516
+ return prioritizedGenes.includes(data.gene) && settings.rings.snvRingFilters.includes(ViewModelMapper.snvClassLayer[data.mClass]);
517
+ } else {
518
+ return settings.rings.snvRingFilters.includes(ViewModelMapper.snvClassLayer[data.mClass]);
519
+ }
520
+ };
521
+ this.dataObjectMapper = new DataObjectMapper(sample, prioritizedGenes);
522
+ }
523
+ map(data) {
524
+ const dataArray = [];
525
+ this.filteredSnvCountByChr.clear();
526
+ this.hasWaterfallEligibleChromosome = false;
527
+ this.mutationWaterfallData = [];
528
+ this.mutationWaterfallInnerRadius = 0;
529
+ this.mutationWaterfallRangeMin = Infinity;
530
+ this.mutationWaterfallRangeMax = -Infinity;
531
+ data.forEach((dObject) => {
532
+ const index = this.reference.chromosomesOrder.indexOf(dObject.chr);
533
+ const indexA = this.reference.chromosomesOrder.indexOf(dObject.chrA);
534
+ const indexB = this.reference.chromosomesOrder.indexOf(dObject.chrB);
535
+ if (dObject.dt == dtsnvindel) {
536
+ if (index != -1 && this.snvData.length < this.settings.snv.maxMutationCount) {
537
+ const pos = dObject.pos ?? dObject.position;
538
+ const chrSize = this.reference.chromosomes[index].size;
539
+ if (Number.isFinite(pos) && pos >= 0 && pos <= chrSize) {
540
+ this.addData(dObject, dataArray);
541
+ } else {
542
+ this.invalidEntries.push({ dataType: "SNV", reason: `Position ${pos} outside of ${dObject.chr}` });
543
+ }
544
+ } else if (index == -1) {
545
+ if (!this.excludedChromosomes.includes(dObject.chr)) {
546
+ this.invalidEntries.push({ dataType: "SNV", reason: `Unknown chr ${dObject.chr}` });
547
+ }
548
+ }
549
+ } else if (dObject.dt == dtfusionrna || dObject.dt == dtsv) {
550
+ if (indexA != -1 && indexB != -1) {
551
+ const posA = dObject.posA;
552
+ const posB = dObject.posB;
553
+ const chrSizeA = this.reference.chromosomes[indexA].size;
554
+ const chrSizeB = this.reference.chromosomes[indexB].size;
555
+ if (Number.isFinite(posA) && Number.isFinite(posB) && posA >= 0 && posA <= chrSizeA && posB >= 0 && posB <= chrSizeB) {
556
+ this.addData(dObject, dataArray);
557
+ } else {
558
+ const reasonParts = [];
559
+ if (!(Number.isFinite(posA) && posA >= 0 && posA <= chrSizeA))
560
+ reasonParts.push(`Position ${posA} outside of ${dObject.chrA}`);
561
+ if (!(Number.isFinite(posB) && posB >= 0 && posB <= chrSizeB))
562
+ reasonParts.push(`Position ${posB} outside of ${dObject.chrB}`);
563
+ this.invalidEntries.push({ dataType: "Fusion", reason: reasonParts.join("; ") });
564
+ }
565
+ } else {
566
+ const missing = [];
567
+ if (indexA == -1 && !this.excludedChromosomes.includes(dObject.chrA)) missing.push(dObject.chrA);
568
+ if (indexB == -1 && !this.excludedChromosomes.includes(dObject.chrB)) missing.push(dObject.chrB);
569
+ if (missing.length) this.invalidEntries.push({ dataType: "Fusion", reason: "Unknown chr in fusion" });
570
+ }
571
+ } else if ([dtcnv, dtloh].includes(Number(dObject.dt))) {
572
+ const idx = this.reference.chromosomesOrder.indexOf(dObject.chr);
573
+ if (dObject.chr && idx != -1) {
574
+ const chrSize = this.reference.chromosomes[idx].size;
575
+ const start = dObject.start;
576
+ const stop = dObject.stop;
577
+ if (Number.isFinite(start) && Number.isFinite(stop) && start >= 0 && stop <= chrSize && start <= stop) {
578
+ this.addData(dObject, dataArray);
579
+ } else {
580
+ this.invalidEntries.push({
581
+ dataType: dObject.dt == dtcnv ? "CNV" : "LOH",
582
+ reason: `Position ${start}-${stop} outside of ${dObject.chr}`
583
+ });
584
+ }
585
+ } else {
586
+ if (!this.excludedChromosomes.includes(dObject.chr)) {
587
+ this.invalidEntries.push({
588
+ dataType: dObject.dt == dtcnv ? "CNV" : "LOH",
589
+ reason: `Unknown chr ${dObject.chr}`
590
+ });
591
+ }
592
+ }
593
+ } else {
594
+ throw Error("Unknown mutation type!");
595
+ }
596
+ });
597
+ const sortedData = dataArray.sort(this.compareData);
598
+ if (this.settings.rings.nonExonicRingEnabled) {
599
+ sortedData.forEach((data2) => {
600
+ this.filterNonExonicSnvData(data2);
601
+ });
602
+ }
603
+ if (this.nonExonicSnvData.length > 0) {
604
+ this.nonExonicInnerRadius = this.lastInnerRadious - this.settings.rings.nonExonicRingWidth;
605
+ this.lastInnerRadious = this.nonExonicInnerRadius;
606
+ }
607
+ sortedData.forEach((data2) => {
608
+ this.filterSnvs(data2);
609
+ });
610
+ this.hasWaterfallEligibleChromosome = Array.from(this.filteredSnvCountByChr.values()).some((count) => count >= 2);
611
+ if (this.settings.Disco.mutationWaterfallPlot && this.hasWaterfallEligibleChromosome) {
612
+ this.prepareMutationWaterfallData();
613
+ }
614
+ sortedData.forEach((data2) => {
615
+ this.filterLohs(data2);
616
+ });
617
+ if (this.lohData.length > 0) {
618
+ this.lohInnerRadius = this.lastInnerRadious - this.settings.rings.lohRingWidth;
619
+ this.lastInnerRadious = this.lohInnerRadius;
620
+ }
621
+ sortedData.forEach((data2) => {
622
+ this.filterCnvs(data2);
623
+ });
624
+ if (this.cnvData.length > 0) {
625
+ this.cnvInnerRadius = this.lastInnerRadious - this.settings.rings.cnvRingWidth;
626
+ this.lastInnerRadious = this.cnvInnerRadius;
627
+ this.cappedCnvMaxAbsValue = Math.min(
628
+ this.settings.Disco.cnvCapping,
629
+ Math.max(
630
+ Math.abs(_DataMapper.capMaxValue(this.cnvLossMaxValue, this.gainCapped, this.lossCapped)),
631
+ Math.abs(_DataMapper.capMaxValue(this.cnvGainMaxValue, this.gainCapped, this.lossCapped))
632
+ )
633
+ );
634
+ const percentilePair = new PercentileMapper().map(
635
+ this.cnvData.map((data2) => data2.value),
636
+ this.settings.Disco.cnvPercentile
637
+ );
638
+ this.percentilePositive = _DataMapper.capMaxValue(percentilePair.positive, this.gainCapped, this.lossCapped);
639
+ this.percentileNegative = _DataMapper.capMaxValue(percentilePair.negative, this.gainCapped, this.lossCapped);
640
+ this.cnvMaxPercentileAbs = Math.min(
641
+ this.settings.Disco.cnvCapping,
642
+ Math.max(this.percentilePositive, Math.abs(this.percentileNegative))
643
+ );
644
+ }
645
+ sortedData.forEach((data2) => {
646
+ this.filterFusion(data2);
647
+ });
648
+ if (this.fusionData.length > 0) {
649
+ this.fusionRadius = this.lastInnerRadious;
650
+ }
651
+ const dataHolder = {
652
+ labelData: this.labelData,
653
+ nonExonicSnvData: this.nonExonicSnvData,
654
+ nonExonicInnerRadius: this.nonExonicInnerRadius,
655
+ snvRingDataMap: this.snvRingDataMap,
656
+ snvInnerRadius: this.snvInnerRadius,
657
+ snvData: this.snvData,
658
+ bpx: this.bpx,
659
+ onePxArcAngle: this.onePxArcAngle,
660
+ filteredSnvData: this.filteredSnvData,
661
+ lohData: this.lohData,
662
+ lohInnerRadius: this.lohInnerRadius,
663
+ cnvData: this.cnvData,
664
+ cnvInnerRadius: this.cnvInnerRadius,
665
+ fusionData: this.fusionData,
666
+ fusionRadius: this.fusionRadius,
667
+ hasPrioritizedGenes: this.hasPrioritizedGenes,
668
+ hasWaterfallEligibleChromosome: this.hasWaterfallEligibleChromosome,
669
+ cnvGainMaxValue: this.cnvGainMaxValue,
670
+ cnvLossMaxValue: this.cnvLossMaxValue,
671
+ cappedCnvMaxAbsValue: this.cappedCnvMaxAbsValue,
672
+ percentilePositive: this.percentilePositive,
673
+ percentileNegative: this.percentileNegative,
674
+ cnvMaxPercentileAbs: this.cnvMaxPercentileAbs,
675
+ lohMaxValue: this.lohMaxValue,
676
+ lohMinValue: this.lohMinValue,
677
+ mutationWaterfallData: this.mutationWaterfallData,
678
+ mutationWaterfallInnerRadius: this.mutationWaterfallInnerRadius,
679
+ mutationWaterfallLogRange: this.mutationWaterfallData.length ? { min: this.mutationWaterfallRangeMin, max: this.mutationWaterfallRangeMax } : void 0,
680
+ invalidDataInfo: {
681
+ entries: this.invalidEntries,
682
+ errorMsg: `Entries listed above were skipped due to invalid or unsupported chromosome information.`
683
+ }
684
+ };
685
+ return dataHolder;
686
+ }
687
+ addData(dObject, dataArray) {
688
+ const instance = this.dataObjectMapper.map(dObject);
689
+ if (instance.isPrioritized) {
690
+ this.hasPrioritizedGenes = true;
691
+ }
692
+ dataArray.push(instance);
693
+ }
694
+ filterNonExonicSnvData(data) {
695
+ if (this.snvFilter(data)) {
696
+ if (this.settings.rings.nonExonicRingEnabled && this.nonExonicFilter(data)) {
697
+ this.nonExonicSnvData.push(data);
698
+ }
699
+ }
700
+ }
701
+ filterSnvs(data) {
702
+ if (this.snvFilter(data)) {
703
+ this.snvData.push(data);
704
+ if (this.snvRingFilter(data)) {
705
+ if (this.snvInnerRadius == 0) {
706
+ this.snvInnerRadius = this.lastInnerRadious - this.settings.rings.snvRingWidth;
707
+ this.lastInnerRadious = this.snvInnerRadius;
708
+ this.bpx = Math.floor(this.reference.totalSize / (this.reference.totalChromosomesAngle * this.snvInnerRadius));
709
+ this.onePxArcAngle = 1 / this.snvInnerRadius;
710
+ }
711
+ this.filteredSnvData.push(data);
712
+ this.labelData.push(data);
713
+ const currentCount = this.filteredSnvCountByChr.get(data.chr) || 0;
714
+ this.filteredSnvCountByChr.set(data.chr, currentCount + 1);
715
+ const arcAngle = this.calculateArcAngle(data);
716
+ let dataArray = this.snvRingDataMap.get(arcAngle);
717
+ if (!dataArray) {
718
+ dataArray = new Array();
719
+ }
720
+ dataArray.push(data);
721
+ this.snvRingDataMap.set(arcAngle, dataArray);
722
+ }
723
+ }
724
+ }
725
+ filterFusion(data) {
726
+ if (this.fusionFilter(data)) {
727
+ data.isPrioritized = true;
728
+ this.fusionData.push(data);
729
+ this.labelData.push(data);
730
+ }
731
+ }
732
+ filterLohs(data) {
733
+ if (this.lohFilter(data)) {
734
+ if (this.lohMaxValue == void 0 || this.lohMaxValue < data.value) {
735
+ this.lohMaxValue = data.segmean;
736
+ }
737
+ if (this.lohMinValue == void 0 || this.lohMinValue > data.value) {
738
+ this.lohMinValue = data.segmean;
739
+ }
740
+ this.lohData.push(data);
741
+ }
742
+ }
743
+ filterCnvs(data) {
744
+ if (this.cnvFilter(data)) {
745
+ if (!data.chr || this.reference.chromosomesOrder.indexOf(data.chr) == -1) {
746
+ return;
747
+ }
748
+ if (this.cnvGainMaxValue == void 0 || this.cnvGainMaxValue < data.value) {
749
+ this.cnvGainMaxValue = data.value;
750
+ }
751
+ if (this.cnvLossMaxValue == void 0 || this.cnvLossMaxValue > data.value) {
752
+ this.cnvLossMaxValue = data.value;
753
+ }
754
+ this.cnvData.push(data);
755
+ }
756
+ }
757
+ prepareMutationWaterfallData() {
758
+ this.mutationWaterfallInnerRadius = this.lastInnerRadious - this.settings.rings.mutationWaterfallRingWidth;
759
+ this.lastInnerRadious = this.mutationWaterfallInnerRadius;
760
+ const groupedSnvs = /* @__PURE__ */ new Map();
761
+ const firstMutationByChr = [];
762
+ for (const snv of this.filteredSnvData) {
763
+ const list = groupedSnvs.get(snv.chr) || [];
764
+ list.push(snv);
765
+ groupedSnvs.set(snv.chr, list);
766
+ }
767
+ for (const [, snvs] of groupedSnvs) {
768
+ if (snvs.length < 2) continue;
769
+ snvs.sort((a, b) => a.position - b.position);
770
+ firstMutationByChr.push({
771
+ chr: snvs[0].chr,
772
+ position: snvs[0].position,
773
+ logDistance: 0
774
+ // placeholder updated after range computed
775
+ });
776
+ for (let i = 1; i < snvs.length; i++) {
777
+ const prev = snvs[i - 1];
778
+ const curr = snvs[i];
779
+ const distance = Math.max(1, Math.abs(curr.position - prev.position));
780
+ const logDistance = Math.log10(distance);
781
+ this.mutationWaterfallData.push({
782
+ chr: curr.chr,
783
+ position: curr.position,
784
+ logDistance
785
+ });
786
+ if (logDistance < this.mutationWaterfallRangeMin) {
787
+ this.mutationWaterfallRangeMin = logDistance;
788
+ }
789
+ if (logDistance > this.mutationWaterfallRangeMax) {
790
+ this.mutationWaterfallRangeMax = logDistance;
791
+ }
792
+ }
793
+ }
794
+ if (!this.mutationWaterfallData.length) {
795
+ this.mutationWaterfallRangeMin = 0;
796
+ this.mutationWaterfallRangeMax = 0;
797
+ }
798
+ const topLogDistance = this.mutationWaterfallRangeMax;
799
+ for (const first of firstMutationByChr) {
800
+ this.mutationWaterfallData.push({
801
+ ...first,
802
+ logDistance: topLogDistance
803
+ });
804
+ }
805
+ }
806
+ calculateArcAngle(data) {
807
+ const currentChromosome = this.reference.chromosomes[this.reference.chromosomesOrder.findIndex((chromosomeOrder) => data.chr == chromosomeOrder)];
808
+ const dataAnglePos = Math.floor(data.position / this.bpx);
809
+ return currentChromosome.startAngle + dataAnglePos * this.onePxArcAngle;
810
+ }
811
+ static capMaxValue(value, gainCapped, lossCapped) {
812
+ if (value && Math.sign(value) == 1) {
813
+ return value > gainCapped ? gainCapped : value;
814
+ }
815
+ if (Math.sign(value) == -1) {
816
+ return value < lossCapped ? lossCapped : value;
817
+ }
818
+ return 0;
819
+ }
820
+ static capMinValue(value, capMinValue = 1) {
821
+ if (Math.sign(value) == 1) {
822
+ return value > capMinValue ? value : capMinValue;
823
+ }
824
+ if (Math.sign(value) == -1) {
825
+ return value < -1 * capMinValue ? value : -1 * capMinValue;
826
+ }
827
+ return 1;
828
+ }
829
+ };
830
+
831
+ // plots/disco/legend/Legend.ts
832
+ var Legend = class {
833
+ constructor(snvTitle, cnvTitle, lohTitle, fusionTitle, cnvPercentile, cnvCutoffmode, snvClassMap, cnvClassMap, cnvRenderingType, fusionLegend, discoInteractions, lohLegend, mutationWaterfallLegend) {
834
+ this.snvTitle = snvTitle;
835
+ this.cnvTitle = cnvTitle;
836
+ this.lohTitle = lohTitle;
837
+ this.fusionTitle = fusionTitle;
838
+ this.cnvPercentile = cnvPercentile;
839
+ this.cnvCutoffMode = cnvCutoffmode;
840
+ this.snvClassMap = snvClassMap;
841
+ this.cnvClassMap = cnvClassMap;
842
+ this.cnvRenderingType = cnvRenderingType;
843
+ this.lohLegend = lohLegend;
844
+ this.fusionLegend = fusionLegend;
845
+ this.discoInteractions = discoInteractions;
846
+ this.mutationWaterfallLegend = mutationWaterfallLegend;
847
+ }
848
+ legendCount() {
849
+ return (this.snvClassMap.size > 0 ? 1 : 0) + (this.cnvClassMap.size > 0 ? 1 : 0) + (this.lohLegend ? 1 : 0) + (this.fusionLegend ? 1 : 0) + (this.mutationWaterfallLegend ? 1 : 0);
850
+ }
851
+ };
852
+
853
+ // plots/disco/fusion/Fusion.ts
854
+ var Fusion = class {
855
+ constructor(source, target, genes, count, endpts) {
856
+ this.source = source;
857
+ this.target = target;
858
+ this.genes = genes;
859
+ this.count = count;
860
+ this.endpts = endpts;
861
+ }
862
+ };
863
+
864
+ // plots/disco/fusion/FusionSubgroup.ts
865
+ var FusionSubgroup = class {
866
+ constructor(startAngle, endAngle, radius, gene, value, genes, positionInChromosome, strand) {
867
+ this.startAngle = startAngle;
868
+ this.endAngle = endAngle;
869
+ this.radius = radius;
870
+ this.gene = gene;
871
+ this.value = value;
872
+ this.genes = genes;
873
+ this.positionInChromosome = positionInChromosome;
874
+ this.strand = strand;
875
+ }
876
+ };
877
+
878
+ // plots/disco/fusion/FusionMapper.ts
879
+ var FusionMapper = class {
880
+ constructor(radius, sampleName, reference) {
881
+ this.radius = radius;
882
+ this.sampleName = sampleName;
883
+ this.reference = reference;
884
+ }
885
+ map(fusionData) {
886
+ const fusions = [];
887
+ fusionData.forEach((data) => {
888
+ const genes = /* @__PURE__ */ new Set();
889
+ genes.add(data.geneA);
890
+ genes.add(data.geneB);
891
+ const startAngle = this.calculateStartAngle(data.chrA, data.posA);
892
+ const endAngle = this.calculateEndAngle(data.chrA, data.posA);
893
+ if (startAngle === null || endAngle === null) return;
894
+ const source = new FusionSubgroup(
895
+ startAngle,
896
+ endAngle,
897
+ this.radius,
898
+ data.geneA,
899
+ data.value,
900
+ genes,
901
+ {
902
+ chromosome: data.chrA,
903
+ position: data.posA
904
+ },
905
+ data.strandA
906
+ );
907
+ let target;
908
+ if (data.chrB && data.posB) {
909
+ const startAngle2 = this.calculateStartAngle(data.chrB, data.posB);
910
+ const endAngle2 = this.calculateEndAngle(data.chrB, data.posB);
911
+ if (startAngle2 === null || endAngle2 === null) return;
912
+ target = new FusionSubgroup(
913
+ startAngle2,
914
+ endAngle2,
915
+ this.radius,
916
+ data.geneB,
917
+ data.value,
918
+ genes,
919
+ {
920
+ chromosome: data.chrB,
921
+ position: data.posB
922
+ },
923
+ data.strandB
924
+ );
925
+ }
926
+ const fusion = new Fusion(source, target, "genes", -1, "Endpoints");
927
+ fusions.push(fusion);
928
+ });
929
+ return fusions;
930
+ }
931
+ calculateStartAngle(chr, pos) {
932
+ const index = this.reference.chromosomesOrder.indexOf(chr);
933
+ if (index === -1) return null;
934
+ const chromosome = this.reference.chromosomes[index];
935
+ return chromosome.startAngle + (chromosome.endAngle - chromosome.startAngle) * (Number(pos) / chromosome.size) - 0.01;
936
+ }
937
+ calculateEndAngle(chr, pos) {
938
+ const index = this.reference.chromosomesOrder.indexOf(chr);
939
+ if (index === -1) return null;
940
+ const chromosome = this.reference.chromosomes[index];
941
+ return 0.01 + chromosome.startAngle + (chromosome.endAngle - chromosome.startAngle) * (Number(pos) / chromosome.size);
942
+ }
943
+ };
944
+
945
+ // plots/disco/loh/GradientColorProvider.ts
946
+ var GradientColorProvider = class {
947
+ static provide(value) {
948
+ const clampedValue = Math.min(Math.max(value, 0), 1);
949
+ const colorValue = Math.round(clampedValue * 255);
950
+ return `rgb(${colorValue}, ${colorValue}, ${colorValue})`;
951
+ }
952
+ };
953
+
954
+ // plots/disco/loh/LohLegend.ts
955
+ var LohLegend = class {
956
+ constructor(minValue, maxValue) {
957
+ this.minValue = minValue;
958
+ this.maxValue = maxValue;
959
+ this.colorStartValue = GradientColorProvider.provide(minValue);
960
+ this.colorEndValue = GradientColorProvider.provide(maxValue);
961
+ }
962
+ };
963
+
964
+ // plots/disco/viewmodel/ViewModel.ts
965
+ var ViewModel = class {
966
+ constructor(settings, rings, legend, fusions, dataHolder, genesetName, snvDataLengthAll) {
967
+ this.settings = settings;
968
+ this.rings = rings;
969
+ this.legend = legend;
970
+ this.fusions = fusions;
971
+ this.genesetName = genesetName;
972
+ const tempHolder = select_default("body").append("div").style("position", "absolute").style("visibility", "hidden");
973
+ const tempSvg = tempHolder.append("svg");
974
+ const labels = rings.labelsRing?.elementsToDisplay?.map((l) => l.text) || [];
975
+ const maxLabelSpace = getMaxLabelWidth(tempSvg, labels);
976
+ tempHolder.remove();
977
+ this.width = 2 * (this.settings.horizontalPadding + this.settings.rings.labelLinesInnerRadius + this.settings.rings.labelsToLinesDistance + maxLabelSpace);
978
+ this.height = 2 * (this.settings.rings.labelLinesInnerRadius + this.settings.rings.labelsToLinesDistance + this.settings.verticalPadding + this.settings.label.fontSize * 2 + maxLabelSpace);
979
+ this.legendHeight = this.calculateLegendHeight(legend);
980
+ this.snvDataLength = dataHolder.snvData.length;
981
+ this.filteredSnvDataLength = dataHolder.filteredSnvData.length;
982
+ this.snvDataLengthAll = snvDataLengthAll;
983
+ this.cnvMaxValue = dataHolder.cnvGainMaxValue;
984
+ this.cnvMinValue = dataHolder.cnvLossMaxValue;
985
+ this.cappedCnvMaxAbsValue = dataHolder.cappedCnvMaxAbsValue;
986
+ this.negativePercentile = dataHolder.percentileNegative;
987
+ this.positivePercentile = dataHolder.percentilePositive;
988
+ this.invalidDataInfo = dataHolder.invalidDataInfo;
989
+ this.canShowMutationWaterfallPlot = dataHolder.hasWaterfallEligibleChromosome;
990
+ }
991
+ getElements(ringType) {
992
+ switch (ringType) {
993
+ case 0 /* CHROMOSOME */:
994
+ return this.rings.chromosomesRing ? this.rings.chromosomesRing.elements : [];
995
+ case 1 /* LABEL */:
996
+ return this.rings.labelsRing.elementsToDisplay;
997
+ case 2 /* NONEXONICSNV */:
998
+ return this.rings.nonExonicArcRing ? this.rings.nonExonicArcRing.elements : [];
999
+ case 3 /* SNV */:
1000
+ return this.rings.snvArcRing ? this.rings.snvArcRing.elements : [];
1001
+ case 5 /* CNV */:
1002
+ return this.rings.cnvArcRing ? this.rings.cnvArcRing.elements : [];
1003
+ case 6 /* LOH */:
1004
+ return this.rings.lohArcRing ? this.rings.lohArcRing.elements : [];
1005
+ case 4 /* MUTATION_WATERFALL */:
1006
+ return this.rings.mutationWaterfallRing ? this.rings.mutationWaterfallRing.elements : [];
1007
+ default:
1008
+ throw new Error(`ringType ${ringType} not defined`);
1009
+ }
1010
+ }
1011
+ getCollisions(ringType) {
1012
+ if (ringType == 1 /* LABEL */) {
1013
+ return this.rings.labelsRing.collisions;
1014
+ } else {
1015
+ return void 0;
1016
+ }
1017
+ }
1018
+ calculateLegendHeight(legend) {
1019
+ const rawHeight = this.settings.legend.rowHeight;
1020
+ return rawHeight * legend.legendCount();
1021
+ }
1022
+ };
1023
+
1024
+ // plots/disco/ring/Ring.ts
1025
+ var Ring = class {
1026
+ constructor(innerRadius, width, elements) {
1027
+ this.innerRadius = innerRadius;
1028
+ this.outerRadius = innerRadius + width;
1029
+ this.width = width;
1030
+ this.elements = elements;
1031
+ }
1032
+ };
1033
+
1034
+ // plots/disco/label/MLabel.ts
1035
+ var MLabel = class _MLabel {
1036
+ /**
1037
+ * The Singleton's constructor should always be private to prevent direct
1038
+ * construction calls with the `new` operator.
1039
+ */
1040
+ constructor() {
1041
+ const mlabel = {};
1042
+ for (const key in mclass) {
1043
+ mlabel[mclass[key].label] = mclass[key];
1044
+ mlabel[key] = mclass[key];
1045
+ }
1046
+ this.mlabel = mlabel;
1047
+ }
1048
+ /**
1049
+ * The static method that controls the access to the singleton instance.
1050
+ *
1051
+ * This implementation let you subclass the Singleton class while keeping
1052
+ * just one instance of each subclass around.
1053
+ */
1054
+ static getInstance() {
1055
+ if (!_MLabel.instance) {
1056
+ _MLabel.instance = new _MLabel();
1057
+ }
1058
+ return _MLabel.instance;
1059
+ }
1060
+ };
1061
+
1062
+ // plots/disco/snv/SnvLegendElement.ts
1063
+ var SnvLegendElement = class {
1064
+ constructor(snvType, color, count) {
1065
+ this.snvType = snvType;
1066
+ this.color = color;
1067
+ this.count = count;
1068
+ }
1069
+ };
1070
+
1071
+ // plots/disco/snv/SnvArcsMapper.ts
1072
+ var SnvArcsMapper = class {
1073
+ constructor(svnInnerRadius, svnWidth, sampleName, reference) {
1074
+ this.snvClassMap = /* @__PURE__ */ new Map();
1075
+ this.svnInnerRadius = svnInnerRadius;
1076
+ this.svnWidth = svnWidth;
1077
+ this.sampleName = sampleName;
1078
+ this.reference = reference;
1079
+ this.bpx = Math.floor(this.reference.totalSize / (this.reference.totalChromosomesAngle * svnInnerRadius));
1080
+ this.onePxArcAngle = 1 / svnInnerRadius;
1081
+ }
1082
+ map(exonicSnvDataMap) {
1083
+ const snvArray = [];
1084
+ for (const angle of exonicSnvDataMap.keys()) {
1085
+ const array = exonicSnvDataMap.get(angle);
1086
+ if (array) {
1087
+ const arraySize = array.length;
1088
+ for (let i = 0; i < array.length; i++) {
1089
+ const data = array[i];
1090
+ const snvLegendElement = this.snvClassMap.get(data.mClass);
1091
+ if (snvLegendElement) {
1092
+ this.snvClassMap.set(data.mClass, this.createSnvLegend(data.mClass, ++snvLegendElement.count));
1093
+ } else {
1094
+ this.snvClassMap.set(data.mClass, this.createSnvLegend(data.mClass, 1));
1095
+ }
1096
+ const startAngle = angle;
1097
+ const endAngle = angle + this.onePxArcAngle;
1098
+ const mLabel = MLabel.getInstance().mlabel ? MLabel.getInstance().mlabel[data.mClass] : void 0;
1099
+ const arc = {
1100
+ startAngle,
1101
+ endAngle,
1102
+ innerRadius: this.svnInnerRadius + i * this.svnWidth / arraySize,
1103
+ outerRadius: this.svnInnerRadius + (i + 1) * this.svnWidth / arraySize,
1104
+ color: mLabel.color,
1105
+ text: data.gene,
1106
+ dataClass: mLabel.label,
1107
+ mname: data.mname,
1108
+ chr: data.chr,
1109
+ pos: data.position,
1110
+ vafs: data.vafs,
1111
+ sampleName: [data.sampleName]
1112
+ };
1113
+ snvArray.push(arc);
1114
+ }
1115
+ }
1116
+ }
1117
+ return snvArray;
1118
+ }
1119
+ createSnvLegend(dataClass, count) {
1120
+ const mClass = MLabel.getInstance().mlabel[dataClass];
1121
+ return new SnvLegendElement(mClass.label, mClass.color, count);
1122
+ }
1123
+ };
1124
+
1125
+ // plots/disco/cnv/CnvLegend.ts
1126
+ var CnvLegend = class {
1127
+ constructor(text, cnvType, color, value) {
1128
+ this.text = text;
1129
+ this.cnvType = cnvType;
1130
+ this.color = color;
1131
+ this.value = value;
1132
+ }
1133
+ };
1134
+
1135
+ // plots/disco/cnv/CnvColorProvider.ts
1136
+ var CnvColorProvider = class {
1137
+ static getColor(value, settings, cnvMaxPercentileAbs = 0) {
1138
+ const cnv = settings.cnv;
1139
+ const gainCapped = settings.Disco.cnvRenderingType == "heatmap" /* heatmap */ ? settings.Disco.cnvCapping : cnvMaxPercentileAbs;
1140
+ const lossCapped = settings.Disco.cnvRenderingType == "heatmap" /* heatmap */ ? -1 * settings.Disco.cnvCapping : -1 * cnvMaxPercentileAbs;
1141
+ if (value < lossCapped) {
1142
+ return cnv.cappedLossColor;
1143
+ } else if (value >= lossCapped && value <= 0) {
1144
+ return cnv.lossColor;
1145
+ } else if (value > 0 && value <= gainCapped) {
1146
+ return cnv.ampColor;
1147
+ } else {
1148
+ return cnv.cappedAmpColor;
1149
+ }
1150
+ }
1151
+ };
1152
+
1153
+ // plots/disco/cnv/CnvArcsMapper.ts
1154
+ var CnvArcsMapper = class {
1155
+ constructor(cnvInnerRadius, cnvWidth, settings, sampleName, reference, cnvMaxValue = 0, cnvMinValue = 0, cnvMaxAbsValue = 0, cnvAbsPercentile = 0, cnvUnit = "", cnvRenderingType) {
1156
+ this.cnvClassMap = /* @__PURE__ */ new Map();
1157
+ this.cnvInnerRadius = cnvInnerRadius;
1158
+ this.cnvWidth = cnvWidth;
1159
+ this.settings = settings;
1160
+ this.sampleName = sampleName;
1161
+ this.reference = reference;
1162
+ this.cnvMaxValue = cnvMaxValue;
1163
+ this.cnvMinValue = cnvMinValue;
1164
+ this.cnvMaxAbsValue = cnvMaxAbsValue;
1165
+ this.cnvAbsPercentile = cnvAbsPercentile;
1166
+ this.cnvUnit = cnvUnit;
1167
+ this.cnvRenderingType = cnvRenderingType;
1168
+ this.gainCapped = Math.min(cnvAbsPercentile, this.settings.Disco.cnvCapping);
1169
+ this.lossCapped = -1 * Math.min(cnvAbsPercentile, this.settings.Disco.cnvCapping);
1170
+ this.lossOnly = cnvMaxValue <= 0;
1171
+ this.gainOnly = cnvMinValue >= 0;
1172
+ this.onePxArcAngle = 1 / this.cnvInnerRadius;
1173
+ const gain = new CnvLegend(
1174
+ "Max",
1175
+ cnvMaxValue > 0 ? 1 /* Gain */ : 0 /* Loss */,
1176
+ this.getColor(cnvMaxValue),
1177
+ cnvMaxValue
1178
+ );
1179
+ const loss = new CnvLegend(
1180
+ "Min",
1181
+ cnvMinValue > 0 ? 1 /* Gain */ : 0 /* Loss */,
1182
+ this.getColor(cnvMinValue),
1183
+ cnvMinValue
1184
+ );
1185
+ const cap = new CnvLegend(
1186
+ "Capping",
1187
+ 0 /* Loss */,
1188
+ this.getColor(cnvMinValue > 0 ? cnvMinValue : cnvMaxValue),
1189
+ this.settings.Disco.cnvCapping
1190
+ );
1191
+ this.cnvClassMap.set(1 /* Gain */, gain);
1192
+ this.cnvClassMap.set(0 /* Loss */, loss);
1193
+ this.cnvClassMap.set(2 /* Cap */, cap);
1194
+ }
1195
+ map(arcData) {
1196
+ const arcs = [];
1197
+ arcData.forEach((data) => {
1198
+ let startAngle = this.calculateStartAngle(data);
1199
+ let endAngle = this.calculateEndAngle(data);
1200
+ if (startAngle === null || endAngle === null) return;
1201
+ if (endAngle - startAngle < this.onePxArcAngle) {
1202
+ const restAngle = this.onePxArcAngle - (endAngle - startAngle);
1203
+ startAngle = startAngle - restAngle / 2;
1204
+ endAngle = startAngle + restAngle / 2;
1205
+ }
1206
+ const innerRadius = this.calculateInnerRadius(data);
1207
+ const outerRadius = this.calculateOuterRadius(data);
1208
+ const color = this.getColor(data.value);
1209
+ const arc = {
1210
+ startAngle,
1211
+ endAngle,
1212
+ innerRadius,
1213
+ outerRadius,
1214
+ color,
1215
+ text: data.gene,
1216
+ chr: data.chr,
1217
+ start: data.start,
1218
+ stop: data.stop,
1219
+ value: data.value,
1220
+ unit: this.cnvUnit,
1221
+ sampleName: [this.sampleName]
1222
+ };
1223
+ arcs.push(arc);
1224
+ });
1225
+ return arcs;
1226
+ }
1227
+ calculateStartAngle(data) {
1228
+ const index = this.reference.chromosomesOrder.indexOf(data.chr);
1229
+ if (index == -1) return null;
1230
+ const chromosome = this.reference.chromosomes[index];
1231
+ return chromosome.startAngle + (chromosome.endAngle - chromosome.startAngle) * (Number(data.start) / chromosome.size);
1232
+ }
1233
+ calculateEndAngle(data) {
1234
+ const index = this.reference.chromosomesOrder.indexOf(data.chr);
1235
+ const chromosome = this.reference.chromosomes[index];
1236
+ return chromosome.startAngle + (chromosome.endAngle - chromosome.startAngle) * (Number(data.stop) / chromosome.size);
1237
+ }
1238
+ getColor(value) {
1239
+ return CnvColorProvider.getColor(value, this.settings, this.cnvAbsPercentile);
1240
+ }
1241
+ calculateInnerRadius(data) {
1242
+ if (this.cnvRenderingType == "heatmap" /* heatmap */) {
1243
+ return this.cnvInnerRadius;
1244
+ }
1245
+ if (this.gainOnly) {
1246
+ return this.cnvInnerRadius;
1247
+ }
1248
+ if (this.lossOnly) {
1249
+ const outerRadius = this.cnvInnerRadius + this.cnvWidth;
1250
+ return outerRadius + DataMapper.capMinValue(
1251
+ this.cnvWidth * DataMapper.capMaxValue(data.value, this.gainCapped, this.lossCapped) / this.cnvAbsPercentile
1252
+ );
1253
+ }
1254
+ const centerRadius = this.cnvInnerRadius + this.cnvWidth / 2;
1255
+ if (Math.sign(data.value) == 1) {
1256
+ return centerRadius;
1257
+ }
1258
+ if (Math.sign(data.value) == -1) {
1259
+ return centerRadius + DataMapper.capMinValue(
1260
+ DataMapper.capMaxValue(data.value, this.gainCapped, this.lossCapped) / this.cnvAbsPercentile * (this.cnvWidth / 2)
1261
+ );
1262
+ }
1263
+ return 1;
1264
+ }
1265
+ calculateOuterRadius(data) {
1266
+ const maxOuterRadius = this.cnvInnerRadius + this.cnvWidth;
1267
+ if (this.cnvRenderingType == "heatmap" /* heatmap */) {
1268
+ return maxOuterRadius;
1269
+ }
1270
+ if (this.gainOnly) {
1271
+ return this.cnvInnerRadius + DataMapper.capMinValue(
1272
+ this.cnvWidth * DataMapper.capMaxValue(data.value, this.gainCapped, this.lossCapped) / this.cnvAbsPercentile
1273
+ );
1274
+ }
1275
+ if (this.lossOnly) {
1276
+ return maxOuterRadius;
1277
+ }
1278
+ const centerRadius = this.cnvInnerRadius + this.cnvWidth / 2;
1279
+ if (Math.sign(data.value) == 1) {
1280
+ return centerRadius + DataMapper.capMinValue(
1281
+ DataMapper.capMaxValue(data.value, this.gainCapped, this.lossCapped) / this.cnvMaxAbsValue * (this.cnvWidth / 2)
1282
+ );
1283
+ }
1284
+ if (Math.sign(data.value) == -1) {
1285
+ return centerRadius;
1286
+ }
1287
+ return 1;
1288
+ }
1289
+ };
1290
+
1291
+ // plots/disco/label/Line.ts
1292
+ var Line = class {
1293
+ constructor(points, color) {
1294
+ this.points = new Array();
1295
+ this.points = points;
1296
+ this.color = color;
1297
+ }
1298
+ };
1299
+
1300
+ // plots/disco/label/LabelFactory.ts
1301
+ var LabelFactory = class {
1302
+ static createLabel(startAngle, endAngle, innerRadius, outerRadius, value, gene, color, dataClass, chr, position, isPrioritized = false, labelsToLinesGap, mutationTooltip, fusionTooltip) {
1303
+ const angle = (startAngle + endAngle) / 2;
1304
+ const ccAngle = angle - Math.PI / 2;
1305
+ const transform = `rotate(${angle * 180 / Math.PI - 90}) translate(${outerRadius})${angle > Math.PI ? "rotate(180)" : ""}`;
1306
+ const textAnchor = angle > Math.PI ? "end" : "";
1307
+ const r0 = innerRadius;
1308
+ const r1 = outerRadius - labelsToLinesGap;
1309
+ const points = [];
1310
+ const point0 = {
1311
+ x: r0 * Math.cos(ccAngle),
1312
+ y: r0 * Math.sin(ccAngle)
1313
+ };
1314
+ const point1 = {
1315
+ x: r1 * Math.cos(ccAngle),
1316
+ y: r1 * Math.sin(ccAngle)
1317
+ };
1318
+ points.push(point0);
1319
+ points.push(point1);
1320
+ const line = new Line(points, color);
1321
+ const label = {
1322
+ startAngle,
1323
+ endAngle,
1324
+ innerRadius,
1325
+ outerRadius,
1326
+ angle,
1327
+ value,
1328
+ text: gene,
1329
+ color,
1330
+ transform,
1331
+ textAnchor,
1332
+ ccAngle,
1333
+ line,
1334
+ isPrioritized,
1335
+ start: position,
1336
+ stop: position,
1337
+ chr,
1338
+ mutationsTooltip: mutationTooltip ? [mutationTooltip] : void 0,
1339
+ fusionTooltip: fusionTooltip ? [fusionTooltip] : void 0
1340
+ };
1341
+ return label;
1342
+ }
1343
+ static createMovedLabel(element, overlap) {
1344
+ const startAngle = element.startAngle + overlap;
1345
+ const endAngle = element.endAngle + overlap;
1346
+ const angle = (startAngle + endAngle) / 2;
1347
+ const ccAngle = angle - Math.PI / 2;
1348
+ const r0 = element.innerRadius;
1349
+ const r1 = element.outerRadius - 2;
1350
+ const dr = (r1 - r0) / 3;
1351
+ const cos0 = Math.cos(element.ccAngle);
1352
+ const sin0 = Math.sin(element.ccAngle);
1353
+ const cos1 = Math.cos(element.ccAngle + overlap);
1354
+ const sin1 = Math.sin(element.ccAngle + overlap);
1355
+ const points = [];
1356
+ const point0 = {
1357
+ x: r0 * cos0,
1358
+ y: r0 * sin0
1359
+ };
1360
+ const point1 = {
1361
+ x: (r0 + dr) * cos0,
1362
+ y: (r0 + dr) * sin0
1363
+ };
1364
+ const point2 = {
1365
+ x: (r0 + 2 * dr) * cos1,
1366
+ y: (r0 + 2 * dr) * sin1
1367
+ };
1368
+ const point3 = {
1369
+ x: (r0 + 3 * dr) * cos1,
1370
+ y: (r0 + 3 * dr) * sin1
1371
+ };
1372
+ points.push(point0);
1373
+ points.push(point1);
1374
+ points.push(point2);
1375
+ points.push(point3);
1376
+ const line = new Line(points, element.color);
1377
+ const transform = "rotate(" + (angle * 180 / Math.PI - 90) + ")translate(" + element.outerRadius + ")" + (angle > Math.PI ? "rotate(180)" : "");
1378
+ const textAnchor = angle > Math.PI ? "end" : "";
1379
+ const color = element.mutationsTooltip ? element.mutationsTooltip[0].color : element.fusionTooltip ? element.fusionTooltip[0].color : void 0;
1380
+ const label = {
1381
+ startAngle,
1382
+ endAngle,
1383
+ innerRadius: element.innerRadius,
1384
+ outerRadius: element.outerRadius,
1385
+ angle,
1386
+ value: element.value,
1387
+ text: element.text,
1388
+ transform,
1389
+ textAnchor,
1390
+ ccAngle,
1391
+ color,
1392
+ line,
1393
+ isPrioritized: element.isPrioritized,
1394
+ start: element.start,
1395
+ stop: element.stop,
1396
+ chr: element.chr,
1397
+ mutationsTooltip: element.mutationsTooltip,
1398
+ fusionTooltip: element.fusionTooltip
1399
+ };
1400
+ return label;
1401
+ }
1402
+ };
1403
+
1404
+ // plots/disco/label/LabelsMapper.ts
1405
+ var LabelsMapper = class {
1406
+ constructor(settings, sampleName, reference, cnvMaxPercentileAbs = 0) {
1407
+ this.labelMap = /* @__PURE__ */ new Map();
1408
+ this.settings = settings;
1409
+ this.sampleName = sampleName;
1410
+ this.reference = reference;
1411
+ this.cnvMaxPercentileAbs = cnvMaxPercentileAbs;
1412
+ }
1413
+ map(data, cnvData = []) {
1414
+ const innerRadius = this.settings.rings.labelLinesInnerRadius;
1415
+ const outerRadius = innerRadius + this.settings.rings.labelsToLinesDistance;
1416
+ data.forEach((data2) => {
1417
+ if (data2.dt == dtsnvindel) {
1418
+ const startAngle = this.calculateStartAngle(data2.chr, data2.position);
1419
+ const endAngle = this.calculateEndAngle(data2.chr, data2.position);
1420
+ if (startAngle === null || endAngle === null) return;
1421
+ const mLabel = MLabel.getInstance().mlabel ? MLabel.getInstance().mlabel[data2.mClass] : void 0;
1422
+ this.addLabelOrMutation(
1423
+ data2,
1424
+ data2.gene,
1425
+ data2.mname,
1426
+ startAngle,
1427
+ endAngle,
1428
+ innerRadius,
1429
+ outerRadius,
1430
+ mLabel.color,
1431
+ mLabel.label
1432
+ );
1433
+ }
1434
+ if (data2.dt == dtfusionrna) {
1435
+ const color = FusionColorProvider.getColor(data2.chrA, data2.chrB);
1436
+ if (data2.geneA) {
1437
+ const startAngleSource = this.calculateStartAngle(data2.chrA, data2.posA);
1438
+ const endAngleSource = this.calculateEndAngle(data2.chrA, data2.posA);
1439
+ if (startAngleSource === null || endAngleSource === null) return;
1440
+ this.addLabelOrFusion(
1441
+ data2,
1442
+ data2.geneA,
1443
+ data2.posA,
1444
+ startAngleSource,
1445
+ endAngleSource,
1446
+ innerRadius,
1447
+ outerRadius,
1448
+ color
1449
+ );
1450
+ }
1451
+ if (data2.geneB && data2.geneA != data2.geneB) {
1452
+ const startAngleTarget = this.calculateStartAngle(data2.chrB, data2.posB);
1453
+ const endAngleTarget = this.calculateEndAngle(data2.chrB, data2.posB);
1454
+ if (startAngleTarget == null || endAngleTarget == null) return;
1455
+ this.addLabelOrFusion(
1456
+ data2,
1457
+ data2.geneB,
1458
+ data2.posB,
1459
+ startAngleTarget,
1460
+ endAngleTarget,
1461
+ innerRadius,
1462
+ outerRadius,
1463
+ color
1464
+ );
1465
+ }
1466
+ }
1467
+ });
1468
+ const labelsArray = Array.from(this.labelMap.values());
1469
+ labelsArray.forEach((label) => {
1470
+ cnvData.forEach((cnv) => {
1471
+ if (label.stop >= cnv.start && cnv.stop >= label.start && label.chr == cnv.chr) {
1472
+ const mutation = {
1473
+ value: cnv.value,
1474
+ color: CnvColorProvider.getColor(cnv.value, this.settings, this.cnvMaxPercentileAbs),
1475
+ chr: cnv.chr,
1476
+ start: cnv.start,
1477
+ stop: cnv.stop
1478
+ };
1479
+ if (label.cnvTooltip) {
1480
+ label.cnvTooltip.push(mutation);
1481
+ } else {
1482
+ label.cnvTooltip = [];
1483
+ label.cnvTooltip.push(mutation);
1484
+ }
1485
+ }
1486
+ });
1487
+ });
1488
+ return Array.from(this.labelMap.values());
1489
+ }
1490
+ addLabelOrMutation(data, gene, mname, startAngle, endAngle, innerRadius, outerRadius, color, dataClass) {
1491
+ const label = this.labelMap.get(gene);
1492
+ const mutation = {
1493
+ mname,
1494
+ color,
1495
+ dataClass,
1496
+ chr: data.chr,
1497
+ position: data.position,
1498
+ vafs: data.vafs
1499
+ };
1500
+ if (!label) {
1501
+ this.labelMap.set(
1502
+ gene,
1503
+ LabelFactory.createLabel(
1504
+ startAngle,
1505
+ endAngle,
1506
+ innerRadius,
1507
+ outerRadius,
1508
+ data.value,
1509
+ gene,
1510
+ color,
1511
+ dataClass,
1512
+ data.chr,
1513
+ data.position,
1514
+ data.isPrioritized,
1515
+ this.settings.rings.labelsToLinesGap,
1516
+ mutation
1517
+ )
1518
+ );
1519
+ } else {
1520
+ if (label.mutationsTooltip) {
1521
+ label.start = Math.min(label.start, data.position);
1522
+ label.stop = Math.max(label.stop, data.position);
1523
+ label.mutationsTooltip.push(mutation);
1524
+ } else {
1525
+ label.mutationsTooltip = [];
1526
+ label.start = Math.min(label.start, data.position);
1527
+ label.stop = Math.max(label.stop, data.position);
1528
+ label.mutationsTooltip.push(mutation);
1529
+ }
1530
+ }
1531
+ }
1532
+ addLabelOrFusion(data, gene, position, startAngle, endAngle, innerRadius, outerRadius, color) {
1533
+ const label = this.labelMap.get(gene);
1534
+ const fusionTooltip = {
1535
+ color,
1536
+ chrA: data.chrA,
1537
+ chrB: data.chrB,
1538
+ posA: data.posA,
1539
+ posB: data.posB,
1540
+ geneA: data.geneA,
1541
+ geneB: data.geneB,
1542
+ strandA: data.strandA,
1543
+ strandB: data.strandB
1544
+ };
1545
+ if (!label) {
1546
+ this.labelMap.set(
1547
+ gene,
1548
+ LabelFactory.createLabel(
1549
+ startAngle,
1550
+ endAngle,
1551
+ innerRadius,
1552
+ outerRadius,
1553
+ data.value,
1554
+ gene,
1555
+ color,
1556
+ "Fusion transcript",
1557
+ data.chr,
1558
+ data.position,
1559
+ data.isPrioritized,
1560
+ this.settings.rings.labelsToLinesGap,
1561
+ void 0,
1562
+ fusionTooltip
1563
+ )
1564
+ );
1565
+ } else {
1566
+ if (label.fusionTooltip) {
1567
+ label.start = Math.min(label.start, position);
1568
+ label.stop = Math.max(label.stop, position);
1569
+ label.fusionTooltip.push(fusionTooltip);
1570
+ } else {
1571
+ label.fusionTooltip = [];
1572
+ label.start = Math.min(label.start, position);
1573
+ label.stop = Math.max(label.stop, position);
1574
+ label.fusionTooltip.push(fusionTooltip);
1575
+ }
1576
+ }
1577
+ }
1578
+ calculateStartAngle(chr, position) {
1579
+ const index = this.reference.chromosomesOrder.findIndex((element) => element == chr);
1580
+ if (index === -1) return null;
1581
+ const chromosome = this.reference.chromosomes[index];
1582
+ return chromosome.startAngle + (chromosome.endAngle - chromosome.startAngle) * (Number(position) / chromosome.size);
1583
+ }
1584
+ calculateEndAngle(chr, position) {
1585
+ const index = this.reference.chromosomesOrder.findIndex((element) => element == chr);
1586
+ if (index === -1) return null;
1587
+ const chromosome = this.reference.chromosomes[index];
1588
+ return chromosome.startAngle + (chromosome.endAngle - chromosome.startAngle) * (Number(position) / chromosome.size);
1589
+ }
1590
+ };
1591
+
1592
+ // plots/disco/label/Labels.ts
1593
+ var Labels = class extends Ring {
1594
+ constructor(settings, elements, hasPrioritizedGenes) {
1595
+ super(
1596
+ settings.rings.labelLinesInnerRadius,
1597
+ settings.rings.labelsToLinesDistance,
1598
+ elements.sort((a, b) => {
1599
+ return a.startAngle < b.startAngle ? -1 : a.startAngle > b.startAngle ? 1 : 0;
1600
+ })
1601
+ );
1602
+ this.elementsToDisplay = [];
1603
+ this.settings = settings;
1604
+ this.hasPrioritizedGenes = hasPrioritizedGenes;
1605
+ const circumference = 2 * Math.PI * (settings.rings.labelLinesInnerRadius + settings.rings.labelsToLinesDistance);
1606
+ this.overlapAngle = this.settings.label.overlapAngleFactor * this.settings.label.fontSize / circumference;
1607
+ this.calculateCollisions();
1608
+ }
1609
+ calculateCollisions() {
1610
+ this.collisions = [];
1611
+ let hasPrioritizedGenesList = [];
1612
+ hasPrioritizedGenesList = this.elements.filter((label) => label.isPrioritized);
1613
+ if (this.settings.label.prioritizeGeneLabelsByGeneSets) {
1614
+ this.elementsToDisplay = this.getLabelsWithPrioritizedGenes(hasPrioritizedGenesList);
1615
+ } else if (this.hasPrioritizedGenes) {
1616
+ const prioritizedGenesList = this.elements.filter((label) => label.isPrioritized);
1617
+ const filteredPrioritizedGenesList = this.getLabelsWithPrioritizedGenes(prioritizedGenesList);
1618
+ const withoutPrioritizedGenesList = this.elements.filter((label) => !label.isPrioritized);
1619
+ const combinedAndSortedList = [...withoutPrioritizedGenesList, ...filteredPrioritizedGenesList].sort(
1620
+ (a, b) => a.startAngle - b.startAngle
1621
+ );
1622
+ this.elementsToDisplay = this.getAllLabels(combinedAndSortedList);
1623
+ } else {
1624
+ this.elementsToDisplay = this.getLabelsWithPrioritizedGenes(this.elements);
1625
+ }
1626
+ }
1627
+ getLabelsWithPrioritizedGenes(elemenets) {
1628
+ const filteredList = [];
1629
+ let prev = { endAngle: 0 };
1630
+ elemenets.forEach((element, index) => {
1631
+ if (index == 0) {
1632
+ filteredList.push(element);
1633
+ prev = element;
1634
+ } else {
1635
+ const overlap = prev.endAngle - element.startAngle + this.overlapAngle;
1636
+ if (overlap > 0 && overlap < this.settings.label.maxDeltaAngle) {
1637
+ const labelCopy = LabelFactory.createMovedLabel(element, overlap);
1638
+ filteredList?.push(labelCopy);
1639
+ prev = labelCopy;
1640
+ }
1641
+ if (overlap <= 0) {
1642
+ filteredList.push(element);
1643
+ prev = element;
1644
+ }
1645
+ }
1646
+ });
1647
+ return filteredList;
1648
+ }
1649
+ getAllLabels(elemenets) {
1650
+ const filteredList = [];
1651
+ let prev = { endAngle: 0 };
1652
+ const elemenetsLength = elemenets.length;
1653
+ let lastCancerGeneLabelIndex = -1;
1654
+ for (let index = 0; index < elemenets.length; index++) {
1655
+ const element = elemenets[index];
1656
+ if (element.isPrioritized) {
1657
+ filteredList.push(element);
1658
+ lastCancerGeneLabelIndex = index;
1659
+ prev = element;
1660
+ continue;
1661
+ }
1662
+ if (index == 0) {
1663
+ if (elemenetsLength > 1) {
1664
+ if (this.isElementOverlappingNextCancerGene(elemenets, lastCancerGeneLabelIndex, element, 0)) {
1665
+ continue;
1666
+ }
1667
+ filteredList.push(element);
1668
+ prev = element;
1669
+ }
1670
+ continue;
1671
+ }
1672
+ const prevOverlap = prev.endAngle - element.startAngle + this.overlapAngle;
1673
+ if (prevOverlap > 0 && prevOverlap < this.settings.label.maxDeltaAngle) {
1674
+ if (index == length - 1) {
1675
+ filteredList.push(element);
1676
+ continue;
1677
+ }
1678
+ if (this.isElementOverlappingNextCancerGene(elemenets, lastCancerGeneLabelIndex, element, prevOverlap)) {
1679
+ continue;
1680
+ }
1681
+ const labelCopy = LabelFactory.createMovedLabel(element, prevOverlap);
1682
+ this.collisions?.push(labelCopy);
1683
+ filteredList.push(element);
1684
+ prev = labelCopy;
1685
+ }
1686
+ if (prevOverlap <= 0) {
1687
+ if (this.isElementOverlappingNextCancerGene(elemenets, lastCancerGeneLabelIndex, element, 0)) {
1688
+ continue;
1689
+ }
1690
+ filteredList.push(element);
1691
+ prev = element;
1692
+ }
1693
+ }
1694
+ return filteredList;
1695
+ }
1696
+ isElementOverlappingNextCancerGene(elemenets, lastCancerGeneLabelIndex, element, prevOverlap) {
1697
+ const nextLabelWithCancerGene = this.getNextLabelWithCancerGene(elemenets, lastCancerGeneLabelIndex);
1698
+ if (nextLabelWithCancerGene) {
1699
+ const nextOverlap = element.endAngle + prevOverlap - nextLabelWithCancerGene.startAngle + this.overlapAngle;
1700
+ if (nextOverlap > 0) {
1701
+ return true;
1702
+ }
1703
+ }
1704
+ return false;
1705
+ }
1706
+ getNextLabelWithCancerGene(elemenets, lastCancerGeneLabelIndex) {
1707
+ return elemenets.find((label, index) => label.isPrioritized && index > lastCancerGeneLabelIndex);
1708
+ }
1709
+ };
1710
+
1711
+ // plots/disco/snv/NonExonicSnvArcsMapper.ts
1712
+ var NonExonicSnvArcsMapper = class {
1713
+ constructor(nonExonicInnerRadius, nonExonicWidht, sampleName, reference) {
1714
+ this.nonExonicInnerRadius = nonExonicInnerRadius;
1715
+ this.nonExonicWidht = nonExonicWidht;
1716
+ this.sampleName = sampleName;
1717
+ this.reference = reference;
1718
+ this.onePxArcAngle = 1 / nonExonicInnerRadius;
1719
+ }
1720
+ map(arcData) {
1721
+ const innerRadius = this.nonExonicInnerRadius;
1722
+ const outerRadius = innerRadius + this.nonExonicWidht;
1723
+ const arcs = [];
1724
+ arcData.forEach((data) => {
1725
+ const mLabel = MLabel.getInstance().mlabel ? MLabel.getInstance().mlabel[data.mClass] : void 0;
1726
+ const startAngle = this.calculateStartAngle(data);
1727
+ const endAngle = this.calculateEndAngle(data);
1728
+ if (startAngle === null || endAngle === null) return;
1729
+ const arc = {
1730
+ startAngle,
1731
+ endAngle,
1732
+ innerRadius,
1733
+ outerRadius,
1734
+ color: mLabel.color,
1735
+ text: data.gene,
1736
+ dataClass: mLabel.label,
1737
+ mname: data.mname,
1738
+ chr: data.chr,
1739
+ pos: data.position,
1740
+ vafs: data.vafs,
1741
+ sampleName: [data.sampleName]
1742
+ };
1743
+ arcs.push(arc);
1744
+ });
1745
+ return arcs;
1746
+ }
1747
+ calculateStartAngle(data) {
1748
+ const index = this.reference.chromosomesOrder.indexOf(data.chr);
1749
+ if (index === -1) return null;
1750
+ const chromosome = this.reference.chromosomes[index];
1751
+ return chromosome.startAngle + (chromosome.endAngle - chromosome.startAngle) * (Number(data.position) / chromosome.size) - this.onePxArcAngle;
1752
+ }
1753
+ calculateEndAngle(data) {
1754
+ const index = this.reference.chromosomesOrder.indexOf(data.chr);
1755
+ const chromosome = this.reference.chromosomes[index];
1756
+ return this.onePxArcAngle + chromosome.startAngle + (chromosome.endAngle - chromosome.startAngle) * (Number(data.position) / chromosome.size);
1757
+ }
1758
+ };
1759
+
1760
+ // plots/disco/loh/LohArcMapper.ts
1761
+ var LohArcMapper = class {
1762
+ constructor(lohInnerRadius, lohWidth, sampleName, reference) {
1763
+ this.lohInnerRadius = lohInnerRadius;
1764
+ this.lohWidth = lohWidth;
1765
+ this.sampleName = sampleName;
1766
+ this.reference = reference;
1767
+ }
1768
+ map(arcData) {
1769
+ const arcs = [];
1770
+ arcData.forEach((data) => {
1771
+ const startAngle = this.calculateStartAngle(data);
1772
+ const endAngle = this.calculateEndAngle(data);
1773
+ if (startAngle === null || endAngle === null) return;
1774
+ const innerRadius = this.lohInnerRadius;
1775
+ const outerRadius = innerRadius + this.lohWidth;
1776
+ const color = GradientColorProvider.provide(data.segmean);
1777
+ const arc = {
1778
+ startAngle,
1779
+ endAngle,
1780
+ innerRadius,
1781
+ outerRadius,
1782
+ color,
1783
+ text: data.gene,
1784
+ chr: data.chr,
1785
+ start: data.start,
1786
+ stop: data.stop,
1787
+ value: data.segmean
1788
+ };
1789
+ arcs.push(arc);
1790
+ });
1791
+ return arcs;
1792
+ }
1793
+ calculateStartAngle(data) {
1794
+ const index = this.reference.chromosomesOrder.indexOf(data.chr);
1795
+ if (index === -1) return null;
1796
+ const chromosome = this.reference.chromosomes[index];
1797
+ return chromosome.startAngle + (chromosome.endAngle - chromosome.startAngle) * (Number(data.start) / chromosome.size);
1798
+ }
1799
+ calculateEndAngle(data) {
1800
+ const index = this.reference.chromosomesOrder.indexOf(data.chr);
1801
+ const chromosome = this.reference.chromosomes[index];
1802
+ return chromosome.startAngle + (chromosome.endAngle - chromosome.startAngle) * (Number(data.stop) / chromosome.size);
1803
+ }
1804
+ };
1805
+
1806
+ // plots/disco/ring/Rings.ts
1807
+ var Rings = class {
1808
+ constructor(labelsRing, chromosomesRing, nonExonicArcRing, snvArcRing, cnvArcRing, lohArcRing, mutationWaterfallRing) {
1809
+ this.labelsRing = labelsRing;
1810
+ this.chromosomesRing = chromosomesRing;
1811
+ this.nonExonicArcRing = nonExonicArcRing;
1812
+ this.snvArcRing = snvArcRing;
1813
+ this.cnvArcRing = cnvArcRing;
1814
+ this.lohArcRing = lohArcRing;
1815
+ this.mutationWaterfallRing = mutationWaterfallRing;
1816
+ }
1817
+ };
1818
+
1819
+ // plots/disco/waterfall/MutationWaterfallMapper.ts
1820
+ var MutationWaterfallMapper = class {
1821
+ constructor(innerRadius, ringWidth, reference, logRange, color = "#4d4d4d") {
1822
+ this.innerRadius = innerRadius;
1823
+ this.ringWidth = ringWidth;
1824
+ this.reference = reference;
1825
+ this.logRange = logRange;
1826
+ this.color = color;
1827
+ }
1828
+ map(data = []) {
1829
+ if (!data.length) return [];
1830
+ const min = this.logRange?.min ?? 0;
1831
+ const max = this.logRange?.max ?? min + 1;
1832
+ const span = max - min || 1;
1833
+ const points = [];
1834
+ for (const datum of data) {
1835
+ const chrIndex = this.reference.chromosomesOrder.indexOf(datum.chr);
1836
+ if (chrIndex === -1) continue;
1837
+ const chromosome = this.reference.chromosomes[chrIndex];
1838
+ const chrAngleSpan = chromosome.endAngle - chromosome.startAngle;
1839
+ const relPos = chromosome.size > 0 ? datum.position / chromosome.size : 0;
1840
+ const angle = chromosome.startAngle + chrAngleSpan * relPos;
1841
+ const normalized = Math.max(0, Math.min(1, (datum.logDistance - min) / span));
1842
+ const radius = this.innerRadius + this.ringWidth * normalized;
1843
+ points.push({
1844
+ startAngle: angle,
1845
+ endAngle: angle,
1846
+ innerRadius: radius,
1847
+ outerRadius: radius,
1848
+ text: chromosome.text,
1849
+ color: this.color,
1850
+ chr: datum.chr,
1851
+ position: datum.position,
1852
+ logDistance: datum.logDistance,
1853
+ ringInnerRadius: this.innerRadius,
1854
+ ringWidth: this.ringWidth,
1855
+ rangeMin: min,
1856
+ rangeMax: max
1857
+ });
1858
+ }
1859
+ return points;
1860
+ }
1861
+ };
1862
+
1863
+ // plots/disco/viewmodel/ViewModelProvider.ts
1864
+ var ViewModelProvider = class {
1865
+ constructor(settings, dataMapper, reference, sampleName, genesetName, discoInteractions) {
1866
+ this.nonExonicArcRing = void 0;
1867
+ this.settings = settings;
1868
+ this.dataMapper = dataMapper;
1869
+ this.reference = reference;
1870
+ this.sampleName = sampleName;
1871
+ this.genesetName = genesetName;
1872
+ this.discoInteractions = discoInteractions;
1873
+ }
1874
+ map(data) {
1875
+ const dataHolder = this.dataMapper.map(data);
1876
+ let labelsRing;
1877
+ if (this.settings.Disco.showGeneNames) {
1878
+ const labelsMapper = new LabelsMapper(
1879
+ this.settings,
1880
+ this.sampleName,
1881
+ this.reference,
1882
+ dataHolder.cnvMaxPercentileAbs
1883
+ );
1884
+ const labelsData = labelsMapper.map(dataHolder.labelData, dataHolder.cnvData);
1885
+ labelsRing = new Labels(this.settings, labelsData, dataHolder.hasPrioritizedGenes);
1886
+ } else {
1887
+ labelsRing = new Labels(this.settings, [], false);
1888
+ }
1889
+ const chromosomesRing = new Ring(
1890
+ this.settings.rings.chromosomeInnerRadius,
1891
+ this.settings.rings.chromosomeWidth,
1892
+ this.reference.chromosomes
1893
+ );
1894
+ const nonExonicSnvArcsMapper = new NonExonicSnvArcsMapper(
1895
+ dataHolder.nonExonicInnerRadius,
1896
+ this.settings.rings.nonExonicRingWidth,
1897
+ this.sampleName,
1898
+ this.reference
1899
+ );
1900
+ const nonExonicData = nonExonicSnvArcsMapper.map(dataHolder.nonExonicSnvData);
1901
+ if (nonExonicData.length > 0) {
1902
+ this.nonExonicArcRing = new Ring(
1903
+ dataHolder.nonExonicInnerRadius,
1904
+ this.settings.rings.nonExonicRingWidth,
1905
+ nonExonicData
1906
+ );
1907
+ }
1908
+ this.snvArcsMapper = new SnvArcsMapper(
1909
+ dataHolder.snvInnerRadius,
1910
+ this.settings.rings.snvRingWidth,
1911
+ this.sampleName,
1912
+ this.reference
1913
+ );
1914
+ const snvData = this.snvArcsMapper.map(dataHolder.snvRingDataMap);
1915
+ if (snvData.length > 0) {
1916
+ this.snvArcRing = new Ring(dataHolder.snvInnerRadius, this.settings.rings.snvRingWidth, snvData);
1917
+ }
1918
+ const lohMapper = new LohArcMapper(
1919
+ dataHolder.lohInnerRadius,
1920
+ this.settings.rings.lohRingWidth,
1921
+ this.sampleName,
1922
+ this.reference
1923
+ );
1924
+ const lohData = lohMapper.map(dataHolder.lohData);
1925
+ if (lohData.length > 0) {
1926
+ this.lohArcRing = new Ring(dataHolder.lohInnerRadius, this.settings.rings.lohRingWidth, lohData);
1927
+ }
1928
+ this.cnvArcsMapper = new CnvArcsMapper(
1929
+ dataHolder.cnvInnerRadius,
1930
+ this.settings.rings.cnvRingWidth,
1931
+ this.settings,
1932
+ this.sampleName,
1933
+ this.reference,
1934
+ dataHolder.percentilePositive,
1935
+ dataHolder.percentileNegative,
1936
+ dataHolder.cappedCnvMaxAbsValue,
1937
+ dataHolder.cnvMaxPercentileAbs,
1938
+ this.settings.cnv.unit,
1939
+ this.settings.Disco.cnvRenderingType
1940
+ );
1941
+ const cnvData = this.cnvArcsMapper.map(dataHolder.cnvData);
1942
+ if (cnvData.length > 0) {
1943
+ this.cnvArcRing = new Ring(dataHolder.cnvInnerRadius, this.settings.rings.cnvRingWidth, cnvData);
1944
+ }
1945
+ if (this.settings.Disco.mutationWaterfallPlot && dataHolder.mutationWaterfallData?.length && dataHolder.mutationWaterfallInnerRadius !== void 0 && //Added this check to prevent TypeScript error "mutationWaterfallInnerRadius might be undefined"
1946
+ (dataHolder.mutationWaterfallInnerRadius ?? 0) > 0 && dataHolder.mutationWaterfallLogRange) {
1947
+ const mutationWaterfallMapper = new MutationWaterfallMapper(
1948
+ dataHolder.mutationWaterfallInnerRadius,
1949
+ this.settings.rings.mutationWaterfallRingWidth,
1950
+ this.reference,
1951
+ dataHolder.mutationWaterfallLogRange,
1952
+ this.settings.Disco.mutationWaterfallColor || "#4d4d4d"
1953
+ );
1954
+ const waterfallData = mutationWaterfallMapper.map(dataHolder.mutationWaterfallData);
1955
+ if (waterfallData.length > 0) {
1956
+ this.mutationWaterfallRing = new Ring(
1957
+ dataHolder.mutationWaterfallInnerRadius,
1958
+ this.settings.rings.mutationWaterfallRingWidth,
1959
+ waterfallData
1960
+ );
1961
+ }
1962
+ }
1963
+ const fusionMapper = new FusionMapper(dataHolder.fusionRadius, this.sampleName, this.reference);
1964
+ const fusions = fusionMapper.map(dataHolder.fusionData);
1965
+ let lohLegend;
1966
+ if (this.settings.legend.lohLegendEnabled && dataHolder.lohMinValue && dataHolder.lohMaxValue) {
1967
+ lohLegend = new LohLegend(dataHolder.lohMinValue, dataHolder.lohMaxValue);
1968
+ }
1969
+ const legend = new Legend(
1970
+ this.settings.legend.snvTitle,
1971
+ this.settings.legend.cnvTitle,
1972
+ this.settings.legend.lohTitle,
1973
+ this.settings.legend.fusionTitle,
1974
+ this.settings.Disco.cnvPercentile,
1975
+ this.settings.Disco.cnvCutoffMode,
1976
+ this.snvArcsMapper ? this.snvArcsMapper.snvClassMap : /* @__PURE__ */ new Map(),
1977
+ this.cnvArcsMapper ? this.cnvArcsMapper.cnvClassMap : /* @__PURE__ */ new Map(),
1978
+ this.settings.Disco.cnvRenderingType,
1979
+ fusions.length > 0,
1980
+ this.discoInteractions,
1981
+ lohLegend,
1982
+ this.settings.Disco.mutationWaterfallPlot && this.mutationWaterfallRing ? {
1983
+ color: this.settings.Disco.mutationWaterfallColor || "#4d4d4d",
1984
+ onColorChange: this.discoInteractions.onMutationWaterfallColorChange
1985
+ } : void 0
1986
+ );
1987
+ const rings = new Rings(
1988
+ labelsRing,
1989
+ chromosomesRing,
1990
+ this.nonExonicArcRing,
1991
+ this.snvArcRing,
1992
+ this.cnvArcRing,
1993
+ this.lohArcRing,
1994
+ this.mutationWaterfallRing
1995
+ );
1996
+ return new ViewModel(
1997
+ this.settings,
1998
+ rings,
1999
+ legend,
2000
+ fusions,
2001
+ dataHolder,
2002
+ this.genesetName,
2003
+ data.filter((i) => i.dt == dtsnvindel).length
2004
+ );
2005
+ }
2006
+ };
2007
+
2008
+ // plots/disco/viewmodel/ViewModelMapper.ts
2009
+ var ViewModelMapper = class _ViewModelMapper {
2010
+ static {
2011
+ this.snvClassLayer = {
2012
+ M: "exonic",
2013
+ E: "exonic",
2014
+ F: "exonic",
2015
+ N: "exonic",
2016
+ S: "exonic",
2017
+ D: "exonic",
2018
+ I: "exonic",
2019
+ P: "exonic",
2020
+ L: "exonic",
2021
+ Utr3: "exonic",
2022
+ Utr5: "exonic",
2023
+ ProteinAltering: "exonic",
2024
+ mnv: "non-exonic",
2025
+ ITD: "non-exonic",
2026
+ insertion: "non-exonic",
2027
+ deletion: "non-exonic",
2028
+ Intron: "non-exonic",
2029
+ X: "non-exonic",
2030
+ noncoding: "non-exonic"
2031
+ };
2032
+ }
2033
+ constructor(settings, discoInteractions) {
2034
+ this.settings = JSON.parse(JSON.stringify(settings));
2035
+ this.discoInteractions = discoInteractions;
2036
+ }
2037
+ applyRadius() {
2038
+ const radius = this.settings.Disco.radius;
2039
+ if (!radius) return;
2040
+ const scale = radius / this.settings.rings.labelLinesInnerRadius;
2041
+ this.settings.rings.labelLinesInnerRadius *= scale;
2042
+ this.settings.rings.labelsToLinesDistance *= scale;
2043
+ this.settings.rings.chromosomeInnerRadius *= scale;
2044
+ this.settings.rings.chromosomeWidth *= scale;
2045
+ this.settings.rings.nonExonicRingWidth *= scale;
2046
+ this.settings.rings.snvRingWidth *= scale;
2047
+ this.settings.rings.lohRingWidth *= scale;
2048
+ this.settings.rings.cnvRingWidth *= scale;
2049
+ this.settings.rings.mutationWaterfallRingWidth *= scale;
2050
+ this.settings.label.fontSize *= scale;
2051
+ this.settings.legend.fontSize *= scale;
2052
+ }
2053
+ static computeDynamicRadius(data) {
2054
+ let ringCount = 0;
2055
+ if (data.some((d) => d.dt == dtsnvindel)) ringCount++;
2056
+ if (data.some((d) => d.dt == dtcnv)) ringCount++;
2057
+ if (data.some((d) => d.dt == dtloh)) ringCount++;
2058
+ if (ringCount <= 1) return 200;
2059
+ if (ringCount == 2) return 250;
2060
+ return 300;
2061
+ }
2062
+ map(opts) {
2063
+ const chrSizes = opts.args.genome.majorchr;
2064
+ const chromosomesOverride = {};
2065
+ for (const chr of Object.keys(chrSizes)) {
2066
+ if (!this.settings.Disco.hiddenChromosomes.includes(chr)) {
2067
+ chromosomesOverride[chr] = chrSizes[chr];
2068
+ }
2069
+ }
2070
+ const sampleName = opts.args.sampleName;
2071
+ const genome = opts.args.genome;
2072
+ const prioritizedGenes = genome?.geneset?.[0] ? genome.geneset[0].lst : [];
2073
+ const genesetName = genome?.geneset?.[0] ? genome.geneset[0].name : "";
2074
+ const data = opts.args.data;
2075
+ if (this.settings.Disco.autoRadius) {
2076
+ this.settings.Disco.radius = _ViewModelMapper.computeDynamicRadius(data);
2077
+ }
2078
+ this.applyRadius();
2079
+ const reference = new Reference(this.settings, chrSizes, chromosomesOverride);
2080
+ const dataMapper = new DataMapper(this.settings, reference, sampleName, prioritizedGenes);
2081
+ return new ViewModelProvider(
2082
+ this.settings,
2083
+ dataMapper,
2084
+ reference,
2085
+ sampleName,
2086
+ genesetName,
2087
+ this.discoInteractions
2088
+ ).map(data);
2089
+ }
2090
+ };
2091
+
2092
+ // plots/disco/legend/LegendJSONMapper.ts
2093
+ var LegendJSONMapper = class {
2094
+ constructor(cappedCnvMaxAbsValue) {
2095
+ this.cappedCnvMaxAbsValue = cappedCnvMaxAbsValue;
2096
+ }
2097
+ map(legend) {
2098
+ const legendJSON = [];
2099
+ let order = 0;
2100
+ if (legend.snvClassMap) {
2101
+ this.mapSnv(legend, legendJSON, order++);
2102
+ }
2103
+ if (legend.cnvRenderingType == "heatmap" /* heatmap */) {
2104
+ this.mapCnvHeatmap(legend, legendJSON, order++);
2105
+ } else if (legend.cnvRenderingType == "bar" /* bar */) {
2106
+ if (legend.cnvClassMap) {
2107
+ this.mapCnvBar(legend, legendJSON, order++);
2108
+ }
2109
+ }
2110
+ if (legend.lohLegend) {
2111
+ this.mapLoh(legend, legendJSON, order++);
2112
+ }
2113
+ if (legend.fusionLegend) {
2114
+ this.mapFusion(legend, legendJSON, order++);
2115
+ }
2116
+ if (legend.mutationWaterfallLegend) {
2117
+ this.mapMutationWaterfall(legend, legendJSON, order++);
2118
+ }
2119
+ return legendJSON;
2120
+ }
2121
+ mapSnv(legend, legendJSON, order) {
2122
+ const snvItems = [];
2123
+ let snvOrder = 0;
2124
+ for (const [snvKey, snvLegendElement] of legend.snvClassMap) {
2125
+ snvItems.push({
2126
+ termid: legend.snvTitle,
2127
+ key: snvKey,
2128
+ text: `${snvLegendElement.snvType} (${snvLegendElement.count})`,
2129
+ color: snvLegendElement.color,
2130
+ order: snvOrder++,
2131
+ border: "1px solid #ccc"
2132
+ });
2133
+ }
2134
+ legendJSON.push({
2135
+ name: legend.snvTitle,
2136
+ order,
2137
+ items: snvItems
2138
+ });
2139
+ }
2140
+ mapCnvBar(legend, legendJSON, order) {
2141
+ if (!legend.cnvClassMap) return;
2142
+ const gain = legend.cnvClassMap.get(1 /* Gain */);
2143
+ const loss = legend.cnvClassMap.get(0 /* Loss */);
2144
+ const cap = legend.cnvClassMap.get(2 /* Cap */);
2145
+ if (gain && loss && cap) {
2146
+ let cnvOrder = 0;
2147
+ const cnvItems = [];
2148
+ if (gain.value > 0) {
2149
+ cnvItems.push({
2150
+ termid: legend.cnvTitle,
2151
+ key: 1 /* Gain */,
2152
+ text: `Max: ${gain.value}`,
2153
+ color: gain.color,
2154
+ order: cnvOrder++,
2155
+ border: "1px solid #ccc"
2156
+ });
2157
+ }
2158
+ if (loss.value < 0) {
2159
+ cnvItems.push({
2160
+ termid: legend.cnvTitle,
2161
+ key: 0 /* Loss */,
2162
+ text: `Min: ${loss.value}`,
2163
+ color: loss.color,
2164
+ order: cnvOrder++,
2165
+ border: "1px solid #ccc"
2166
+ });
2167
+ }
2168
+ cnvItems.push({
2169
+ termid: legend.cnvTitle,
2170
+ key: 2 /* Cap */,
2171
+ text: `Capping: ${cap.value}`,
2172
+ color: cap.color,
2173
+ order: cnvOrder++,
2174
+ border: "1px solid #ccc"
2175
+ // ,
2176
+ // onClickCallback: this.onClickCallback
2177
+ });
2178
+ legendJSON.push({
2179
+ name: legend.cnvTitle,
2180
+ id: "sjpp-disco-cnv-legend",
2181
+ order,
2182
+ items: cnvItems
2183
+ });
2184
+ }
2185
+ }
2186
+ mapCnvHeatmap(legend, legendJSON, order) {
2187
+ if (!legend.cnvClassMap) return;
2188
+ const gain = legend.cnvClassMap.get(1 /* Gain */);
2189
+ const loss = legend.cnvClassMap.get(0 /* Loss */);
2190
+ const cap = legend.cnvClassMap.get(2 /* Cap */);
2191
+ if (gain && loss && cap) {
2192
+ let cnvOrder = 0;
2193
+ const cnvItems = [];
2194
+ const base = {
2195
+ termid: legend.cnvTitle,
2196
+ width: 100,
2197
+ order: cnvOrder++,
2198
+ isLegendItem: true,
2199
+ dt: 4
2200
+ };
2201
+ if (gain.value > 0 && loss.value < 0) {
2202
+ const maxValue = Math.max(Math.abs(loss.value), gain.value);
2203
+ const domain = [-maxValue, 0, maxValue];
2204
+ cnvItems.push(
2205
+ Object.assign(
2206
+ {
2207
+ key: 3 /* LossGain */,
2208
+ domain,
2209
+ scale: linear([-1, 0, 1], [loss.color, "white", gain.color]),
2210
+ labels: { left: "Loss", right: "Gain" },
2211
+ numericInputs: {
2212
+ cutoffMode: legend.cnvCutoffMode,
2213
+ defaultPercentile: legend.cnvPercentile,
2214
+ callback: (obj) => legend.discoInteractions.colorScaleNumericInputsCallback(obj)
2215
+ }
2216
+ },
2217
+ base
2218
+ )
2219
+ );
2220
+ } else {
2221
+ if (gain.value > 0) {
2222
+ cnvItems.push(
2223
+ Object.assign(
2224
+ {
2225
+ key: 1 /* Gain */,
2226
+ text: "Copy number gain",
2227
+ domain: [0, gain.value],
2228
+ scale: linear([0, 1], ["white", gain.color])
2229
+ },
2230
+ base
2231
+ )
2232
+ );
2233
+ }
2234
+ if (loss.value < 0) {
2235
+ cnvItems.push(
2236
+ Object.assign(
2237
+ {
2238
+ key: 0 /* Loss */,
2239
+ text: "Copy number loss",
2240
+ domain: [loss.value, 0],
2241
+ scale: linear([0, 1], [loss.color, "white"])
2242
+ },
2243
+ base
2244
+ )
2245
+ );
2246
+ }
2247
+ }
2248
+ legendJSON.push({
2249
+ name: legend.cnvTitle,
2250
+ order,
2251
+ id: "sjpp-disco-cnv-legend",
2252
+ items: cnvItems
2253
+ });
2254
+ }
2255
+ }
2256
+ mapLoh(legend, legendJSON, order) {
2257
+ if (!legend.lohLegend) return;
2258
+ const lohItems = [];
2259
+ lohItems.push({
2260
+ termid: legend.lohTitle,
2261
+ key: "min",
2262
+ text: "min",
2263
+ color: legend.lohLegend.colorStartValue,
2264
+ order: 0,
2265
+ border: "1px solid #ccc"
2266
+ });
2267
+ lohItems.push({
2268
+ termid: legend.lohTitle,
2269
+ key: "max",
2270
+ text: "max",
2271
+ color: legend.lohLegend.colorEndValue,
2272
+ order: 1,
2273
+ border: "1px solid #ccc"
2274
+ });
2275
+ legendJSON.push({
2276
+ name: legend.lohTitle,
2277
+ order,
2278
+ items: lohItems
2279
+ });
2280
+ }
2281
+ mapFusion(legend, legendJSON, order) {
2282
+ const fusionItems = [];
2283
+ fusionItems.push({
2284
+ termid: legend.fusionTitle,
2285
+ key: "#6A3D9A" /* Interchromosomal */,
2286
+ text: "Interchromosomal",
2287
+ color: "#6A3D9A" /* Interchromosomal */.valueOf(),
2288
+ order: 0,
2289
+ border: "1px solid #ccc"
2290
+ });
2291
+ fusionItems.push({
2292
+ termid: legend.fusionTitle,
2293
+ key: "#1B9E77" /* Intrachromosomal */,
2294
+ text: "Intrachromosomal",
2295
+ color: "#1B9E77" /* Intrachromosomal */.valueOf(),
2296
+ order: 1,
2297
+ border: "1px solid #ccc"
2298
+ });
2299
+ legendJSON.push({
2300
+ name: legend.fusionTitle,
2301
+ order,
2302
+ items: fusionItems
2303
+ });
2304
+ }
2305
+ mapMutationWaterfall(legend, legendJSON, order) {
2306
+ if (!legend.mutationWaterfallLegend) return;
2307
+ const waterfallItems = [];
2308
+ waterfallItems.push({
2309
+ termid: "Mutation Waterfall Plot",
2310
+ key: "mutation-waterfall-color",
2311
+ text: "Dot color",
2312
+ color: legend.mutationWaterfallLegend.color,
2313
+ order: 0,
2314
+ colorPicker: true,
2315
+ inputWidth: 28,
2316
+ width: 0,
2317
+ onColorChange: legend.mutationWaterfallLegend.onColorChange
2318
+ });
2319
+ waterfallItems.push({
2320
+ termid: "Mutation Waterfall Plot",
2321
+ key: "mutation-waterfall-axis",
2322
+ text: "Axis: log10 intermutation distance",
2323
+ order: 1,
2324
+ skipIcon: true,
2325
+ width: 0
2326
+ });
2327
+ legendJSON.push({
2328
+ name: "Mutation Waterfall Plot",
2329
+ order,
2330
+ items: waterfallItems
2331
+ });
2332
+ }
2333
+ };
2334
+
2335
+ // plots/disco/cnv/renderCnvSourceLegend.ts
2336
+ function parseSetLabel(set, index) {
2337
+ let text = set.name || `Set ${index + 1}`;
2338
+ let href;
2339
+ let target = "_blank";
2340
+ if (set.nameHtml) {
2341
+ const parser = new DOMParser();
2342
+ const doc = parser.parseFromString(set.nameHtml, "text/html");
2343
+ const anchor = doc.querySelector("a");
2344
+ if (anchor) {
2345
+ href = anchor.getAttribute("href") || void 0;
2346
+ target = anchor.getAttribute("target") || "_blank";
2347
+ text = anchor.textContent?.trim() || text;
2348
+ } else {
2349
+ text = doc.body.textContent?.trim() || text;
2350
+ }
2351
+ }
2352
+ return { text, href, target };
2353
+ }
2354
+ function renderCnvSourceLegend(legendG, datasets, fontSize, onChange) {
2355
+ if (!legendG || legendG.empty()) throw new Error("legendG is required");
2356
+ if (!datasets || datasets.length === 0) throw new Error("at least one dataset is required");
2357
+ legendG.select("g.sjpp-cnv-source").remove();
2358
+ const gBBox = legendG.node().getBBox();
2359
+ const cnvSrcWrapper = legendG.append("g").attr("class", "sjpp-cnv-source").attr("transform", `translate(${gBBox.width},${gBBox.y + fontSize})`);
2360
+ const btnPaddingX = Math.round(fontSize * 0.8);
2361
+ const btnHgt = Math.round(fontSize * 1.8);
2362
+ const btnWrapper = cnvSrcWrapper.append("g").attr("transform", `translate(${fontSize},${-btnHgt / 2})`).style("cursor", "pointer").on("click", function(event) {
2363
+ event.stopPropagation();
2364
+ showCnvMenu(this);
2365
+ });
2366
+ const btnText = btnWrapper.append("text").attr("x", 0).attr("y", btnHgt / 2).attr("font-size", fontSize).attr("text-anchor", "start").attr("dominant-baseline", "middle").text("Select source \u25B2".toUpperCase());
2367
+ const textW = btnText.node() ? Math.ceil(btnText.node().getBBox().width) : 0;
2368
+ const btnWdt = textW + btnPaddingX * 2;
2369
+ btnWrapper.insert("rect", ":first-child").attr("width", btnWdt).attr("height", btnHgt).attr("rx", 10).attr("ry", 10).style("fill", "#f2f2f2");
2370
+ btnText.attr("x", btnWdt / 2).attr("text-anchor", "middle");
2371
+ const cnvMenu = new Menu({
2372
+ onHide: () => {
2373
+ btnText.text("Select source \u25B2".toUpperCase());
2374
+ }
2375
+ });
2376
+ function showCnvMenu(dom) {
2377
+ btnText.text("Select source \u25BC".toUpperCase());
2378
+ cnvMenu.clear().showunder(dom);
2379
+ cnvMenu.d.append("div").text("Choose data source for CNV:").style("margin", "5px 5px 0 5px");
2380
+ const tableHolder = cnvMenu.d.append("div").style("padding", "5px");
2381
+ const { columns, rows } = buildTableData(datasets);
2382
+ const [, activeIndex] = getActiveDataset(datasets);
2383
+ renderTable({
2384
+ columns,
2385
+ rows,
2386
+ div: tableHolder,
2387
+ singleMode: true,
2388
+ maxWidth: "70vw",
2389
+ maxHeight: "60vh",
2390
+ selectedRows: [activeIndex],
2391
+ header: { allowSort: false },
2392
+ noButtonCallback: (rowIndex, node) => {
2393
+ const inputIndex = Number(node?.value);
2394
+ const selectedIndex = Number.isNaN(inputIndex) ? rowIndex : inputIndex;
2395
+ if (!Number.isNaN(selectedIndex)) onChange(selectedIndex);
2396
+ cnvMenu.hide();
2397
+ }
2398
+ });
2399
+ }
2400
+ }
2401
+ function getActiveDataset(datasets) {
2402
+ let currentIndex = datasets.findIndex((d) => d.inuse);
2403
+ if (currentIndex == -1) currentIndex = 0;
2404
+ return [datasets[currentIndex], currentIndex];
2405
+ }
2406
+ function buildTableData(datasets) {
2407
+ const attrKeys = [];
2408
+ for (const set of datasets) {
2409
+ if (!set.attrs) continue;
2410
+ for (const key of Object.keys(set.attrs)) {
2411
+ if (!attrKeys.includes(key)) attrKeys.push(key);
2412
+ }
2413
+ }
2414
+ const columns = [{ label: "Source" }];
2415
+ for (const key of attrKeys) columns.push({ label: key });
2416
+ const rows = datasets.map((set, index) => {
2417
+ const sourceInfo = parseSetLabel(set, index);
2418
+ const cells = [];
2419
+ if (set.nameHtml) cells.push({ html: set.nameHtml });
2420
+ else if (sourceInfo.href) cells.push({ value: sourceInfo.text, url: sourceInfo.href });
2421
+ else cells.push({ value: sourceInfo.text });
2422
+ for (const key of attrKeys) {
2423
+ const value = set.attrs?.[key];
2424
+ cells.push({ value: value ?? "" });
2425
+ }
2426
+ return cells;
2427
+ });
2428
+ return { columns, rows };
2429
+ }
2430
+
2431
+ // plots/disco/legend/LegendRenderer.ts
2432
+ var LegendRenderer = class {
2433
+ constructor(cappedCnvMaxAbsValue = 0, fontSize) {
2434
+ this.fontSize = fontSize;
2435
+ this.legendJSONMapper = new LegendJSONMapper(cappedCnvMaxAbsValue);
2436
+ }
2437
+ render(holder, legend, xOffset, svgw, svgh, viewModel, onCnvSourceSelect) {
2438
+ const svgLegendRenderer = svgLegend({
2439
+ holder: holder.append("g").attr("data-testid", "sjpp_disco_plot_legend"),
2440
+ rectFillFxn: (d2) => d2.color,
2441
+ iconStroke: "#aaa"
2442
+ });
2443
+ const data = this.legendJSONMapper.map(legend);
2444
+ const legendTitles = data.map((d2) => d2.name.trim());
2445
+ const maxLabelWidth = getMaxLabelWidth(holder, legendTitles);
2446
+ const d = {
2447
+ xOffset: maxLabelWidth + xOffset
2448
+ };
2449
+ svgLegendRenderer(data, {
2450
+ settings: Object.assign(
2451
+ {},
2452
+ {
2453
+ svgw,
2454
+ svgh,
2455
+ dimensions: d,
2456
+ fontsize: this.fontSize
2457
+ }
2458
+ )
2459
+ });
2460
+ const altCnv = viewModel.appState.args.alternativeDataByDt?.[dtcnv];
2461
+ if (altCnv && altCnv.length > 0) {
2462
+ const legendG = holder.select('g[data-testid="sjpp_disco_plot_legend"]');
2463
+ const cnvLegendG = legendG.select("#sjpp-disco-cnv-legend");
2464
+ if (!legendG.empty()) {
2465
+ const add2G = cnvLegendG.empty() ? legendG : cnvLegendG;
2466
+ renderCnvSourceLegend(add2G, altCnv, this.fontSize, onCnvSourceSelect);
2467
+ }
2468
+ }
2469
+ }
2470
+ };
2471
+
2472
+ // plots/disco/chromosome/ChromosomesRenderer.ts
2473
+ var ChromosomesRenderer = class {
2474
+ constructor(padAngle, innerRadius, outerRadius, fontSize) {
2475
+ this.padAngle = padAngle;
2476
+ this.innerRadius = innerRadius;
2477
+ this.outerRadius = outerRadius;
2478
+ this.fontSize = fontSize;
2479
+ }
2480
+ render(holder, elements) {
2481
+ const pie = pie_default().padAngle(this.padAngle).value((d) => d.size).sort(null);
2482
+ const arcData = pie(elements);
2483
+ const arc = arc_default().innerRadius(this.innerRadius).outerRadius(this.outerRadius);
2484
+ const arcs = holder.append("g").attr("data-testid", "sjpp_chromosomes_arc_group");
2485
+ const menu = MenuProvider.create();
2486
+ arcs.selectAll("path").data(arcData).enter().append("path").attr("d", arc).attr("fill", "black").on("mousemove", (event, d) => {
2487
+ const [x, y] = pointer_default(event, arcs.node());
2488
+ let angle = Math.atan2(y, x) + Math.PI / 2;
2489
+ if (angle < 0) angle += 2 * Math.PI;
2490
+ const frac = Math.max(0, Math.min(1, (angle - d.data.startAngle) / (d.data.endAngle - d.data.startAngle)));
2491
+ const pos = Math.round(frac * d.data.size);
2492
+ menu.d.html(`<span style="font-size:.8em">chr${d.data.text}</span> ${bplen(pos)}`).style("padding", "5px");
2493
+ menu.show(event.x, event.y);
2494
+ }).on("mouseenter", (event) => {
2495
+ select_default(event.currentTarget).attr("stroke", "orange").attr("stroke-width", 1);
2496
+ }).on("mouseleave", (event) => {
2497
+ select_default(event.currentTarget).attr("stroke", null).attr("stroke-width", null);
2498
+ menu.hide();
2499
+ });
2500
+ arcs.selectAll("text").data(arcData).enter().append("text").attr("transform", (d) => {
2501
+ return `translate(${arc.centroid(d)}) rotate(${d.data.angle * 180 / Math.PI - 90})${d.data.angle > Math.PI ? "rotate(180)" : ""}`;
2502
+ }).attr("dy", "0.35em").attr("text-anchor", "middle").text((d) => d.data.text).style("fill", "white").style("font-size", `${this.fontSize}px`).style("padding", "500px").style("pointer-events", "none").style("padding", "500px");
2503
+ }
2504
+ };
2505
+
2506
+ // plots/disco/snv/vafTooltip.ts
2507
+ function getIntegerCount(v) {
2508
+ if (Number.isInteger(v)) return v;
2509
+ if (typeof v == "string" && /^-?\d+$/.test(v)) {
2510
+ const n = Number(v);
2511
+ if (Number.isInteger(n)) return n;
2512
+ }
2513
+ return null;
2514
+ }
2515
+ function hasValidReadCounts(refCountValue, altCountValue) {
2516
+ const refCount = getIntegerCount(refCountValue);
2517
+ const altCount = getIntegerCount(altCountValue);
2518
+ return refCount != null && altCount != null && refCount >= 0 && altCount >= 0 && refCount + altCount > 0;
2519
+ }
2520
+ function getVafEntries(vafs) {
2521
+ const entries = [];
2522
+ if (Array.isArray(vafs)) {
2523
+ for (const vaf of vafs) {
2524
+ const label = vaf?.id || vaf?.name;
2525
+ const refCount = vaf?.refCount;
2526
+ const altCount = vaf?.altCount;
2527
+ if (!label || refCount == null || altCount == null) continue;
2528
+ entries.push({ label, refCount, altCount });
2529
+ }
2530
+ }
2531
+ return entries;
2532
+ }
2533
+ function hasAnyValidVafEntry(vafs) {
2534
+ return getVafEntries(vafs).some((vaf) => hasValidReadCounts(vaf.refCount, vaf.altCount));
2535
+ }
2536
+ function appendVafBar(td2, refCountValue, altCountValue, label = "VAF") {
2537
+ const refCount = getIntegerCount(refCountValue);
2538
+ const altCount = getIntegerCount(altCountValue);
2539
+ if (refCount == null || altCount == null) return;
2540
+ const totalCount = refCount + altCount;
2541
+ const fraction = altCount / totalCount;
2542
+ const div = td2.append("div").style("margin-left", "5px").style("margin-top", "4px").style("display", "flex").style("align-items", "center").style("gap", "6px");
2543
+ div.append("span").style("font-size", "0.8em").style("color", "#555").text(label);
2544
+ fillbar(div, { f: fraction, v1: altCount, v2: totalCount });
2545
+ }
2546
+ function appendVafBars(td2, vafs) {
2547
+ for (const vaf of getVafEntries(vafs)) {
2548
+ if (!hasValidReadCounts(vaf.refCount, vaf.altCount)) continue;
2549
+ appendVafBar(td2, vaf.refCount, vaf.altCount, vaf.label);
2550
+ }
2551
+ }
2552
+
2553
+ // plots/disco/label/LabelsRenderer.ts
2554
+ var LabelsRenderer = class {
2555
+ constructor(animationDuration, fontSize, geneClickListener) {
2556
+ this.animationDuration = animationDuration;
2557
+ this.fontSize = fontSize;
2558
+ this.geneClickListener = geneClickListener;
2559
+ }
2560
+ render(holder, elements, collisions) {
2561
+ const labelsG = holder.append("g");
2562
+ const lineFunction = line_default().x((point) => point.x).y((point) => point.y);
2563
+ const menu = MenuProvider.create();
2564
+ labelsG.selectAll(".group").data(elements).enter().append("g").attr("class", "group").each((label, i, nodes) => {
2565
+ const g = select_default(nodes[i]);
2566
+ g.append("text").attr("class", "chord-text").attr("dy", ".35em").attr("transform", label.transform).style("text-anchor", label.textAnchor).style("font-size", `${this.fontSize}px`).style("fill", label.color).style("cursor", "pointer").text(label.text).on("click", () => {
2567
+ if (label.mutationsTooltip) {
2568
+ this.geneClickListener(
2569
+ label.text,
2570
+ label.mutationsTooltip.map((value) => value.mname)
2571
+ );
2572
+ }
2573
+ }).on("mouseover", (mouseEvent) => {
2574
+ const table = table2col({ holder: menu.d });
2575
+ this.createTooltip(table, label);
2576
+ menu.show(mouseEvent.x, mouseEvent.y);
2577
+ }).on("mouseout", () => {
2578
+ menu.clear();
2579
+ menu.hide();
2580
+ });
2581
+ g.append("path").attr("class", "chord-tick").datum(label.line.points).style("stroke", label.color).style("fill", "none").attr("d", lineFunction);
2582
+ });
2583
+ labelsG.selectAll(".group").each((label, i, nodes) => {
2584
+ const collision = collisions ? collisions.find((l) => l.text === label.text) : void 0;
2585
+ if (collision) {
2586
+ const g = select_default(nodes[i]);
2587
+ g.selectAll(".chord-text").datum(collision).transition().duration(this.animationDuration).attr("transform", collision.transform).style("text-anchor", collision.textAnchor);
2588
+ g.selectAll(".chord-tick").datum(collision.line.points).transition().duration(this.animationDuration).style("fill", "none").attr("d", lineFunction);
2589
+ }
2590
+ });
2591
+ }
2592
+ createTooltip(table, label) {
2593
+ if (label.mutationsTooltip) {
2594
+ const [td1, td2] = table.addRow();
2595
+ td1.text("Gene");
2596
+ td2.append("span").style("margin-left", "5px").text(label.text);
2597
+ label.mutationsTooltip.forEach((mutation) => {
2598
+ {
2599
+ const [td12, td22] = table.addRow();
2600
+ td12.text("Mutation");
2601
+ td22.append("span").style("margin-left", "5px").text(mutation.mname).append("span").style("margin-left", "5px").style("color", mutation.color).text(`${mutation.dataClass}`).append("span").style("margin-left", "5px").style("color", "black").style("font-size", "0.8em").text(` ${mutation.chr}:${mutation.position}`);
2602
+ if (hasAnyValidVafEntry(mutation.vafs)) {
2603
+ appendVafBars(td22, mutation.vafs);
2604
+ }
2605
+ }
2606
+ });
2607
+ }
2608
+ if (label.fusionTooltip) {
2609
+ const [td1, td2] = table.addRow();
2610
+ td1.text("Data type");
2611
+ td2.append("span").text("Fusion transcript");
2612
+ label.fusionTooltip.forEach((fusionTooltip) => {
2613
+ const [td12, td22] = table.addRow();
2614
+ td12.text("Position");
2615
+ td22.append("span").text(
2616
+ ` ${fusionTooltip.geneA ? fusionTooltip.geneA : "?"} ${fusionTooltip.chrA}:${fusionTooltip.posA}
2617
+ ${fusionTooltip.strandA == "+" ? "forward" : "reverse"} > ${fusionTooltip.geneB ? fusionTooltip.geneB : "?"} ${fusionTooltip.chrB}:${fusionTooltip.posB} ${fusionTooltip.strandB == "+" ? "forward" : "reverse"} `
2618
+ );
2619
+ });
2620
+ }
2621
+ if (label.cnvTooltip) {
2622
+ label.cnvTooltip.forEach((cnv) => {
2623
+ const [td1, td2] = table.addRow();
2624
+ td1.text("CNV");
2625
+ td2.append("span").style("margin-left", "5px").style("background-color", cnv.color).html("&nbsp;&nbsp;");
2626
+ td2.append("span").style("margin-left", "7.5px").text(cnv.value).append("span").style("margin-left", "7.5px").style("font-size", "0.8em").text(`${cnv.chr}:${cnv.start}-${cnv.stop}`);
2627
+ });
2628
+ }
2629
+ }
2630
+ };
2631
+
2632
+ // plots/disco/defaults.ts
2633
+ function discoDefaults(overrides = {}, app) {
2634
+ const hiddenChromosomes = [];
2635
+ if (app?.vocabApi?.termdbConfig?.queries?.singleSampleMutation?.discoPlot?.skipChrM) {
2636
+ hiddenChromosomes.push("chrM");
2637
+ }
2638
+ const defaults = {
2639
+ downloadImgName: "disco.plot",
2640
+ Disco: {
2641
+ centerText: null,
2642
+ cnvCapping: 5,
2643
+ isOpen: false,
2644
+ prioritizeGeneLabelsByGeneSets: false,
2645
+ showPrioritizeGeneLabelsByGeneSets: false,
2646
+ showGeneNames: true,
2647
+ mutationWaterfallPlot: false,
2648
+ mutationWaterfallColor: "#4d4d4d",
2649
+ cnvRenderingType: "heatmap" /* heatmap */,
2650
+ cnvPercentile: 90,
2651
+ // 90th percentile for removing outliers
2652
+ cnvCutoffMode: "percentile",
2653
+ autoRadius: true,
2654
+ radius: 300,
2655
+ fusionOpacity: 1,
2656
+ hiddenChromosomes
2657
+ },
2658
+ rings: {
2659
+ nonExonicRingWidth: 20,
2660
+ snvRingWidth: 20,
2661
+ lohRingWidth: 20,
2662
+ cnvRingWidth: 30,
2663
+ mutationWaterfallRingWidth: 35,
2664
+ snvRingFilters: ["exonic"],
2665
+ chromosomeInnerRadius: 190,
2666
+ chromosomeWidth: 20,
2667
+ labelLinesInnerRadius: 210,
2668
+ labelsToLinesDistance: 30,
2669
+ labelsToLinesGap: 2,
2670
+ nonExonicRingEnabled: true,
2671
+ nonExonicFilterValues: ["non-exonic"]
2672
+ },
2673
+ verticalPadding: 0,
2674
+ horizontalPadding: 50,
2675
+ layerScaler: 1,
2676
+ padAngle: 2e-3,
2677
+ //0.01, //0.04,
2678
+ label: {
2679
+ fontSize: 12,
2680
+ maxDeltaAngle: 0.05,
2681
+ animationDuration: 1e3,
2682
+ overlapAngleFactor: 5
2683
+ // 5 is set by testing, because label height is not known before rendering
2684
+ },
2685
+ cnv: {
2686
+ capping: 5,
2687
+ percentile: 80,
2688
+ ampColor: "#D6683C",
2689
+ lossColor: "#67a9cf",
2690
+ cappedAmpColor: "#8B0000",
2691
+ cappedLossColor: "#00008B",
2692
+ unit: "Unit"
2693
+ },
2694
+ snv: {
2695
+ maxMutationCount: 1e4
2696
+ },
2697
+ legend: {
2698
+ snvTitle: "SNV",
2699
+ cnvTitle: "CNV",
2700
+ lohTitle: "LOH",
2701
+ fusionTitle: "SV",
2702
+ // Structural Variants (color by co-location)
2703
+ lohLegendEnabled: true,
2704
+ fontSize: 12,
2705
+ rowHeight: 48
2706
+ },
2707
+ menu: {
2708
+ padding: 5
2709
+ }
2710
+ };
2711
+ if (overrides?.Disco?.radius != null && (overrides.Disco.radius > 1e3 || overrides.Disco.radius < 200)) {
2712
+ console.log(`${overrides?.Disco?.radius} is greater or lower than the min and max for the radius`);
2713
+ }
2714
+ return copyMerge(defaults, overrides);
2715
+ }
2716
+
2717
+ // plots/disco/snv/NonExonicSnvRenderer.ts
2718
+ var NonExonicSnvRenderer = class {
2719
+ constructor(geneClickListener) {
2720
+ this.geneClickListener = geneClickListener;
2721
+ }
2722
+ render(holder, elements) {
2723
+ const arcGenerator = arc_default();
2724
+ const arcs = holder.append("g");
2725
+ const menu = MenuProvider.create();
2726
+ arcs.selectAll("path").data(elements).enter().append("path").attr("d", (d) => arcGenerator(d)).attr("fill", (d) => d.color).on("mouseover", (mouseEvent, arc) => {
2727
+ const table = table2col({ holder: menu.d });
2728
+ const snv = structuredClone(arc);
2729
+ snv.dt = dtsnvindel;
2730
+ snv.class = arc.dataClass;
2731
+ snv.gene = snv.text;
2732
+ {
2733
+ const [td1, td2] = table.addRow();
2734
+ td1.text("Consequence");
2735
+ td2.append("span").text(snv.mname);
2736
+ td2.append("span").style("margin-left", "5px").style("color", snv.color).style("font-size", ".8em").text(snv.dataClass);
2737
+ }
2738
+ {
2739
+ const [td1, td2] = table.addRow();
2740
+ td1.text(snv.ref && snv.alt ? "Mutation" : "Position");
2741
+ td2.append("span").text(`${snv.chr}:${snv.pos + 1} ${snv.ref && snv.alt ? snv.ref + ">" + snv.alt : ""}`);
2742
+ }
2743
+ if (snv.gene) {
2744
+ const [td1, td2] = table.addRow();
2745
+ td1.text("Gene");
2746
+ td2.text(snv.gene);
2747
+ }
2748
+ if (snv.occurrence > 1) {
2749
+ const [td1, td2] = table.addRow();
2750
+ td1.text("Occurrence");
2751
+ td2.text(snv.occurrence);
2752
+ }
2753
+ if (hasAnyValidVafEntry(arc.vafs)) {
2754
+ const [td1, td2] = table.addRow();
2755
+ td1.text("Read count");
2756
+ appendVafBars(td2, arc.vafs);
2757
+ }
2758
+ menu.show(mouseEvent.x, mouseEvent.y);
2759
+ }).on("mouseout", () => {
2760
+ menu.clear();
2761
+ menu.hide();
2762
+ }).on("click", (mouseEvent, arc) => {
2763
+ this.geneClickListener(arc.text, [arc.mname]);
2764
+ });
2765
+ }
2766
+ };
2767
+
2768
+ // plots/disco/snv/SnvRenderer.ts
2769
+ var SnvRenderer = class {
2770
+ constructor(svnWidth, geneClickListener) {
2771
+ this.svnWidth = svnWidth;
2772
+ this.geneClickListener = geneClickListener;
2773
+ }
2774
+ render(holder, elements) {
2775
+ if (elements.length > 0) {
2776
+ const svnInnerRadius = elements[0].innerRadius;
2777
+ const fullArcRenderer = new FullArcRenderer(svnInnerRadius, this.svnWidth, "#6464641A");
2778
+ fullArcRenderer.render(holder);
2779
+ }
2780
+ const arcGenerator = arc_default();
2781
+ const arcs = holder.append("g");
2782
+ const menu = MenuProvider.create();
2783
+ arcs.selectAll("path").data(elements).enter().append("path").attr("d", (d) => arcGenerator(d)).attr("fill", (d) => d.color).on("mouseover", (mouseEvent, arc) => {
2784
+ const table = table2col({ holder: menu.d });
2785
+ const snv = structuredClone(arc);
2786
+ snv.dt = dtsnvindel;
2787
+ snv.class = arc.dataClass;
2788
+ snv.gene = snv.text;
2789
+ {
2790
+ const [td1, td2] = table.addRow();
2791
+ td1.text("Consequence");
2792
+ td2.append("span").text(snv.mname);
2793
+ td2.append("span").style("margin-left", "5px").style("color", snv.color).style("font-size", ".8em").text(snv.dataClass);
2794
+ }
2795
+ {
2796
+ const [td1, td2] = table.addRow();
2797
+ td1.text(snv.ref && snv.alt ? "Mutation" : "Position");
2798
+ td2.append("span").text(`${snv.chr}:${snv.pos + 1} ${snv.ref && snv.alt ? snv.ref + ">" + snv.alt : ""}`);
2799
+ }
2800
+ if (snv.gene) {
2801
+ const [td1, td2] = table.addRow();
2802
+ td1.text("Gene");
2803
+ td2.text(snv.gene);
2804
+ }
2805
+ if (snv.occurrence > 1) {
2806
+ const [td1, td2] = table.addRow();
2807
+ td1.text("Occurrence");
2808
+ td2.text(snv.occurrence);
2809
+ }
2810
+ if (hasAnyValidVafEntry(arc.vafs)) {
2811
+ const [td1, td2] = table.addRow();
2812
+ td1.text("Read count");
2813
+ appendVafBars(td2, arc.vafs);
2814
+ }
2815
+ menu.show(mouseEvent.x, mouseEvent.y);
2816
+ }).on("mouseout", () => {
2817
+ menu.clear();
2818
+ menu.hide();
2819
+ }).on("click", (mouseEvent, arc) => {
2820
+ this.geneClickListener(arc.text, [arc.mname]);
2821
+ });
2822
+ }
2823
+ };
2824
+
2825
+ // plots/disco/loh/LohRenderer.ts
2826
+ var LohRenderer = class {
2827
+ render(holder, elements) {
2828
+ const arcGenerator = arc_default();
2829
+ const arcs = holder.append("g");
2830
+ const menu = MenuProvider.create();
2831
+ arcs.selectAll("path").data(elements).enter().append("path").attr("d", (d) => arcGenerator(d)).attr("fill", (d) => d.color).on("mouseover", (mouseEvent, arc) => {
2832
+ const table = table2col({ holder: menu.d });
2833
+ const loh = structuredClone(arc);
2834
+ loh.dt = dtloh;
2835
+ loh.gene = loh.text;
2836
+ {
2837
+ const [td12, td22] = table.addRow();
2838
+ td12.text("Data type");
2839
+ td22.append("span").style("margin-left", "5px").text("Loss of Heterozygosity");
2840
+ }
2841
+ const [td1, td2] = table.addRow();
2842
+ td1.text("Position");
2843
+ td2.append("span").text(`${arc.chr}:${arc.start}-${arc.stop}`);
2844
+ menu.show(mouseEvent.x, mouseEvent.y);
2845
+ }).on("mouseout", () => {
2846
+ menu.clear();
2847
+ menu.hide();
2848
+ });
2849
+ }
2850
+ };
2851
+
2852
+ // plots/disco/cnv/CnvBarRenderer.ts
2853
+ var CnvBarRenderer = class {
2854
+ render(holder, elements) {
2855
+ const arcGenerator = arc_default();
2856
+ const arcs = holder.append("g");
2857
+ const hoverOverlay = holder.append("g").attr("class", "hover-overlay").style("pointer-events", "none");
2858
+ const menu = MenuProvider.create();
2859
+ arcs.selectAll("path").data(elements).enter().append("path").attr("d", (d) => arcGenerator(d)).attr("fill", (d) => d.color).on("mouseover", (mouseEvent, arc) => {
2860
+ hoverOverlay.selectAll("*").remove();
2861
+ hoverOverlay.append("path").datum(arc).attr("d", arcGenerator(arc)).attr("fill", "none").attr("stroke", "black").attr("stroke-width", 1);
2862
+ const cnv = structuredClone(arc);
2863
+ cnv.dt = dtcnv;
2864
+ cnv.samples = [{ sample_id: arc.sampleName }];
2865
+ cnv.gene = cnv.text;
2866
+ const table = table2col({ holder: menu.d });
2867
+ {
2868
+ const [c1, c2] = table.addRow();
2869
+ c1.text("CNV");
2870
+ c2.html(`<span style="background:${cnv.color}">&nbsp;&nbsp;</span> ${cnv.value}`);
2871
+ }
2872
+ {
2873
+ const [c1, c2] = table.addRow();
2874
+ c1.text("Position");
2875
+ c2.text(cnv.chr + ":" + cnv.start + "-" + cnv.stop);
2876
+ }
2877
+ {
2878
+ const [c1, c2] = table.addRow();
2879
+ c1.text("Unit");
2880
+ c2.text(cnv.value);
2881
+ }
2882
+ menu.show(mouseEvent.x, mouseEvent.y);
2883
+ }).on("mouseout", () => {
2884
+ hoverOverlay.selectAll("*").remove();
2885
+ menu.clear();
2886
+ menu.hide();
2887
+ });
2888
+ }
2889
+ };
2890
+
2891
+ // plots/disco/cnv/CnvHeatmapRenderer.ts
2892
+ var CnvHeatmapRenderer = class {
2893
+ constructor(positivePercentile = 0, negativePercentile = 0) {
2894
+ this.positivePercentile = positivePercentile;
2895
+ this.negativePercentile = negativePercentile;
2896
+ }
2897
+ render(holder, elements) {
2898
+ const arcGenerator = arc_default();
2899
+ const arcs = holder.append("g");
2900
+ const hoverOverlay = holder.append("g").attr("class", "hover-overlay").style("pointer-events", "none");
2901
+ const menu = MenuProvider.create();
2902
+ arcs.selectAll("path").data(elements).enter().append("path").attr("d", (d) => arcGenerator(d)).attr("fill", (d) => this.getColor(d.color, d.value)).on("mouseenter", (mouseEvent, arc) => {
2903
+ hoverOverlay.append("path").datum(arc).attr("d", arcGenerator(arc)).attr("fill", "none").attr("stroke", "black").attr("stroke-width", 1);
2904
+ const table = table2col({ holder: menu.d });
2905
+ const cnv = structuredClone(arc);
2906
+ cnv.dt = dtcnv;
2907
+ cnv.samples = [{ sample_id: arc.sampleName }];
2908
+ cnv.gene = cnv.text;
2909
+ {
2910
+ const [c1, c2] = table.addRow();
2911
+ c1.text("CNV");
2912
+ c2.html(
2913
+ `<span style="background:${this.getColor(
2914
+ cnv.color,
2915
+ cnv.value
2916
+ )}; border:solid lightgrey 0.1px;">&nbsp;&nbsp;</span> ${cnv.value}`
2917
+ );
2918
+ }
2919
+ {
2920
+ const [c1, c2] = table.addRow();
2921
+ c1.text("Position");
2922
+ c2.text(cnv.chr + ":" + cnv.start + "-" + cnv.stop);
2923
+ }
2924
+ menu.show(mouseEvent.x, mouseEvent.y);
2925
+ }).on("mouseleave", () => {
2926
+ hoverOverlay.selectAll("*").remove();
2927
+ menu.clear();
2928
+ menu.hide();
2929
+ });
2930
+ }
2931
+ // Computes fill color using linear scale between -P80, 0, and +P80
2932
+ getColor(color, value) {
2933
+ const maxValue = Math.max(this.positivePercentile, Math.abs(this.negativePercentile));
2934
+ return linear(
2935
+ [-maxValue, 0, maxValue],
2936
+ [color, "white", color]
2937
+ // transitions to white in the middle
2938
+ ).clamp(true)(value);
2939
+ }
2940
+ };
2941
+
2942
+ // plots/disco/waterfall/MutationWaterfallRenderer.ts
2943
+ var MutationWaterfallRenderer = class {
2944
+ constructor(dotRadius = 1.5) {
2945
+ this.dotRadius = dotRadius;
2946
+ }
2947
+ render(holder, elements) {
2948
+ if (!elements.length) return;
2949
+ const ringGroup = holder.append("g").attr("data-testid", "sjpp_mutation_waterfall_ring");
2950
+ const menu = MenuProvider.create();
2951
+ ringGroup.append("g").selectAll("circle").data(elements).enter().append("circle").attr("cx", (d) => Math.cos(d.startAngle - Math.PI / 2) * d.innerRadius).attr("cy", (d) => Math.sin(d.startAngle - Math.PI / 2) * d.innerRadius).attr("r", this.dotRadius).attr("fill", (d) => d.color).attr("opacity", 0.9).on("mouseover", (event, d) => {
2952
+ const distance = Math.round(Math.pow(10, d.logDistance));
2953
+ menu.clear();
2954
+ const table = table2col({ holder: menu.d });
2955
+ {
2956
+ const [td1, td2] = table.addRow();
2957
+ td1.text("Intermutation distance");
2958
+ td2.text(`${bplen(distance)}`);
2959
+ }
2960
+ menu.show(event.x, event.y);
2961
+ }).on("mouseout", () => {
2962
+ menu.clear();
2963
+ menu.hide();
2964
+ });
2965
+ this.renderAxis(ringGroup, elements[0]);
2966
+ }
2967
+ renderAxis(holder, referencePoint) {
2968
+ const { ringInnerRadius, ringWidth, rangeMin, rangeMax } = referencePoint;
2969
+ const axisGroup = holder.append("g").attr("class", "sjpp-waterfall-axis");
2970
+ const topRadius = ringInnerRadius + ringWidth;
2971
+ axisGroup.append("line").attr("x1", 0).attr("y1", -topRadius).attr("x2", 0).attr("y2", -ringInnerRadius).attr("stroke", "#6e6e6e").attr("stroke-width", 1);
2972
+ const span = rangeMax - rangeMin || 1;
2973
+ const tickValues = rangeMax === rangeMin ? [rangeMin] : ticks(rangeMin, rangeMax, 4);
2974
+ tickValues.forEach((value) => {
2975
+ const ratio = (value - rangeMin) / span;
2976
+ const radius = ringInnerRadius + ringWidth * ratio;
2977
+ const y = -radius;
2978
+ axisGroup.append("line").attr("x1", -4).attr("x2", 4).attr("y1", y).attr("y2", y).attr("stroke", "#6e6e6e");
2979
+ const exponent = Math.round(value * 10) / 10;
2980
+ const formatted = Number.isInteger(exponent) ? `${exponent}` : exponent.toFixed(1);
2981
+ axisGroup.append("text").attr("x", 6).attr("y", y + 3).style("font-size", "10px").style("fill", "#4d4d4d").text(`10^${formatted} bp`);
2982
+ });
2983
+ }
2984
+ };
2985
+
2986
+ // plots/disco/Disco.ts
2987
+ var Disco = class {
2988
+ constructor(opts) {
2989
+ this.recreateViewModel = false;
2990
+ this.onCnvSourceSelect = (index) => {
2991
+ const state = this.app.getState();
2992
+ const args = state.args;
2993
+ const alt = args.alternativeDataByDt?.[dtcnv];
2994
+ if (!alt) return;
2995
+ const altClone = structuredClone(args.alternativeDataByDt);
2996
+ altClone[dtcnv].forEach((d, i) => d.inuse = i === index);
2997
+ const selected = altClone[dtcnv][index];
2998
+ selected.mlst.forEach((d) => d.position = d.pos);
2999
+ const baseData = args.data.filter((d) => d.dt != dtcnv && d.dt != dtloh);
3000
+ const newData = baseData.concat(selected.mlst);
3001
+ this.app.dispatch({
3002
+ type: "app_refresh",
3003
+ state: { args: { ...args, data: newData, alternativeDataByDt: altClone } }
3004
+ });
3005
+ };
3006
+ this.type = "Disco";
3007
+ this.opts = opts;
3008
+ this.isOpen = false;
3009
+ this.discoInteractions = new DiscoInteractions(this);
3010
+ }
3011
+ static {
3012
+ this.type = "Disco";
3013
+ }
3014
+ async init() {
3015
+ const state = this.app.getState();
3016
+ const settings = state.plots.find((p) => p.id === this.id).settings;
3017
+ this.stateViewModelMapper = new ViewModelMapper(settings, this.discoInteractions);
3018
+ this.viewModel = this.stateViewModelMapper.map(state);
3019
+ const holder = this.opts.holder;
3020
+ const controlsHolder = holder.append("div").style("display", "inline-block").style("vertical-align", "top");
3021
+ const mainDiv = holder.append("div").style("display", "inline-block");
3022
+ const topbar = controlsHolder.append("div");
3023
+ const config_div = controlsHolder.append("div");
3024
+ const configInputsOptions = this.getConfigInputsOptions(this.viewModel);
3025
+ this.features = await multiInit({
3026
+ topbar: topBarInit({
3027
+ app: this.app,
3028
+ id: this.id,
3029
+ // TODO change the way svg is selected
3030
+ downloadHandler: () => this.discoInteractions.downloadClickListener(holder.select('svg[id="sjpp_disco_plot"]').node()),
3031
+ callback: () => this.toggleVisibility(this.isOpen),
3032
+ isOpen: () => this.isOpen,
3033
+ holder: topbar
3034
+ }),
3035
+ config: configUiInit({
3036
+ app: this.app,
3037
+ id: this.id,
3038
+ holder: config_div,
3039
+ isOpen: () => this.isOpen,
3040
+ inputs: configInputsOptions
3041
+ })
3042
+ });
3043
+ this.errorDiv = mainDiv.append("div").attr("data-testid", "sjpp-disco-errorDiv");
3044
+ this.svgDiv = mainDiv.append("div").attr("data-testid", "sjpp-disco-svgDiv");
3045
+ }
3046
+ getConfigInputsOptions(viewModel) {
3047
+ const configInputsOptions = [];
3048
+ if (viewModel.settings.Disco.showPrioritizeGeneLabelsByGeneSets) {
3049
+ const filterMutationsGenesCheckbox = [
3050
+ {
3051
+ boxLabel: viewModel.genesetName,
3052
+ label: `Filter mutations`,
3053
+ type: "checkbox",
3054
+ chartType: "Disco",
3055
+ settingsKey: "prioritizeGeneLabelsByGeneSets",
3056
+ title: `Only show mutations for ${viewModel.genesetName} genes`
3057
+ }
3058
+ ];
3059
+ configInputsOptions.push(...filterMutationsGenesCheckbox);
3060
+ }
3061
+ if (viewModel.cnvMaxValue !== 0 || viewModel.cnvMinValue !== 0) {
3062
+ const cnvConfigInputOptions = [
3063
+ {
3064
+ boxLabel: "",
3065
+ label: "CNV rendering type",
3066
+ type: "radio",
3067
+ chartType: "Disco",
3068
+ settingsKey: "cnvRenderingType",
3069
+ title: "CNV rendering type",
3070
+ options: [
3071
+ { label: "Heatmap", value: "heatmap" /* heatmap */ },
3072
+ { label: "Bar", value: "bar" /* bar */ }
3073
+ ]
3074
+ }
3075
+ ];
3076
+ configInputsOptions.push(...cnvConfigInputOptions);
3077
+ }
3078
+ configInputsOptions.push({
3079
+ boxLabel: "",
3080
+ label: "Show gene names",
3081
+ type: "checkbox",
3082
+ chartType: "Disco",
3083
+ settingsKey: "showGeneNames",
3084
+ title: "Show gene name labels on the outside of the plot"
3085
+ });
3086
+ const genomeChr = this.app.opts.state.args.genome.majorchr;
3087
+ const chromosomeConfigOption = {
3088
+ label: "Chromosomes",
3089
+ title: "Chromosomes shown in the plot",
3090
+ type: "multiCheckbox",
3091
+ chartType: "Disco",
3092
+ settingsKey: "hiddenChromosomes",
3093
+ style: {
3094
+ colNum: 4
3095
+ },
3096
+ options: Object.keys(genomeChr).map((c) => ({ label: c, value: c })),
3097
+ processInput: (values = []) => {
3098
+ const reverse = Object.keys(genomeChr).filter((c) => !values.includes(c));
3099
+ return reverse;
3100
+ }
3101
+ };
3102
+ configInputsOptions.push(chromosomeConfigOption);
3103
+ configInputsOptions.push({
3104
+ boxLabel: "",
3105
+ label: "Auto radius",
3106
+ type: "checkbox",
3107
+ chartType: "Disco",
3108
+ settingsKey: "autoRadius",
3109
+ title: "Automatically set the radius based on the number of data rings"
3110
+ });
3111
+ const dimensionOptions = [
3112
+ {
3113
+ label: "Radius",
3114
+ title: "Set the radius of the entire plot, between 200 and 1000 pixels.",
3115
+ type: "number",
3116
+ chartType: "Disco",
3117
+ settingsKey: "radius",
3118
+ debounceInterval: 500,
3119
+ step: 25,
3120
+ min: 200,
3121
+ max: 1e3,
3122
+ getDisplayStyle: (plot) => plot.settings.Disco.autoRadius ? "none" : "table-row"
3123
+ },
3124
+ {
3125
+ label: "Fusion opacity",
3126
+ title: "Adjust opacity of fusion arcs, between 0 and 1",
3127
+ type: "number",
3128
+ chartType: "Disco",
3129
+ settingsKey: "fusionOpacity",
3130
+ step: 0.01,
3131
+ min: 0,
3132
+ max: 1,
3133
+ debounceInterval: 500
3134
+ }
3135
+ ];
3136
+ configInputsOptions.push(...dimensionOptions);
3137
+ if (viewModel.canShowMutationWaterfallPlot && viewModel.snvDataLength > 0) {
3138
+ configInputsOptions.push({
3139
+ boxLabel: "",
3140
+ label: "Mutation Waterfall Plot",
3141
+ type: "checkbox",
3142
+ chartType: "Disco",
3143
+ settingsKey: "mutationWaterfallPlot",
3144
+ title: "Render log10 intermutation distance ring for SNV/indel data"
3145
+ });
3146
+ }
3147
+ return configInputsOptions;
3148
+ }
3149
+ async main() {
3150
+ const settings = this.state.settings;
3151
+ this.isOpen = settings.Disco.isOpen;
3152
+ if (this.recreateViewModel) {
3153
+ this.stateViewModelMapper = new ViewModelMapper(settings, this.discoInteractions);
3154
+ this.viewModel = this.stateViewModelMapper.map(this.app.getState());
3155
+ }
3156
+ this.recreateViewModel = true;
3157
+ if (this.viewModel) {
3158
+ this.svgDiv.selectAll("*").remove();
3159
+ const appState = this.app.getState();
3160
+ this.viewModel.svgDiv = this.svgDiv;
3161
+ this.viewModel.appState = appState;
3162
+ for (const name in this.features) {
3163
+ this.features[name].update({ state: this.state, appState });
3164
+ }
3165
+ const legendRenderer = new LegendRenderer(this.viewModel.cappedCnvMaxAbsValue, settings.label.fontSize);
3166
+ const discoRenderer = new DiscoRenderer(
3167
+ this.getRingRenderers(this.viewModel.settings, this.viewModel, this.discoInteractions.geneClickListener),
3168
+ legendRenderer,
3169
+ this.app.opts.state.args.genome
3170
+ );
3171
+ discoRenderer.render(this.svgDiv, this.viewModel, this.onCnvSourceSelect);
3172
+ if (this.viewModel.invalidDataInfo?.entries?.length) {
3173
+ InvalidDataUI.render(this.errorDiv, this.viewModel.invalidDataInfo);
3174
+ }
3175
+ }
3176
+ }
3177
+ getState(appState) {
3178
+ const config = appState.plots.find((p) => p.id === this.id);
3179
+ if (!config) return config;
3180
+ return { ...config, mlst: appState.args.data };
3181
+ }
3182
+ getRingRenderers(settings, viewModel, geneClickListener) {
3183
+ const chromosomesRenderer = new ChromosomesRenderer(
3184
+ settings.padAngle,
3185
+ settings.rings.chromosomeInnerRadius,
3186
+ settings.rings.chromosomeInnerRadius + settings.rings.chromosomeWidth,
3187
+ settings.label.fontSize
3188
+ );
3189
+ const labelsRenderer = new LabelsRenderer(
3190
+ settings.label.animationDuration,
3191
+ settings.label.fontSize,
3192
+ geneClickListener
3193
+ );
3194
+ const nonExonicSnvRenderer = new NonExonicSnvRenderer(geneClickListener);
3195
+ const snvRenderer = new SnvRenderer(settings.rings.snvRingWidth, geneClickListener);
3196
+ const cnvRenderer = settings.Disco.cnvRenderingType === "heatmap" /* heatmap */ ? new CnvHeatmapRenderer(viewModel.positivePercentile, viewModel.negativePercentile) : new CnvBarRenderer();
3197
+ const lohRenderer = new LohRenderer();
3198
+ const mutationWaterfallRenderer = new MutationWaterfallRenderer();
3199
+ const renderersMap = /* @__PURE__ */ new Map();
3200
+ renderersMap.set(0 /* CHROMOSOME */, chromosomesRenderer);
3201
+ renderersMap.set(1 /* LABEL */, labelsRenderer);
3202
+ renderersMap.set(2 /* NONEXONICSNV */, nonExonicSnvRenderer);
3203
+ renderersMap.set(3 /* SNV */, snvRenderer);
3204
+ renderersMap.set(4 /* MUTATION_WATERFALL */, mutationWaterfallRenderer);
3205
+ renderersMap.set(5 /* CNV */, cnvRenderer);
3206
+ renderersMap.set(6 /* LOH */, lohRenderer);
3207
+ return renderersMap;
3208
+ }
3209
+ toggleVisibility(isOpen) {
3210
+ this.app.dispatch({
3211
+ type: "plot_edit",
3212
+ id: this.opts.id,
3213
+ config: {
3214
+ settings: {
3215
+ Disco: { isOpen: !isOpen }
3216
+ }
3217
+ }
3218
+ });
3219
+ }
3220
+ };
3221
+ var discoInit = getCompInit(Disco);
3222
+ var componentInit = discoInit;
3223
+ async function getPlotConfig(opts, app) {
3224
+ return {
3225
+ chartType: "Disco",
3226
+ subfolder: "disco",
3227
+ extension: "ts",
3228
+ settings: discoDefaults(opts.overrides, app)
3229
+ };
3230
+ }
3231
+ export {
3232
+ componentInit,
3233
+ Disco as default,
3234
+ discoInit,
3235
+ getPlotConfig
3236
+ };
3237
+ //# sourceMappingURL=Disco-Y5Z4A7GN.js.map