@milaboratories/graph-maker 1.1.138 → 1.1.140

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 (253) hide show
  1. package/dist/GraphMaker/components/Chart.vue.d.ts.map +1 -1
  2. package/dist/GraphMaker/components/Chart.vue.js +1 -0
  3. package/dist/GraphMaker/components/Chart.vue.js.map +1 -1
  4. package/dist/GraphMaker/components/LassoControls/index.vue.js +15 -13
  5. package/dist/GraphMaker/components/LassoControls/index.vue.js.map +1 -1
  6. package/dist/GraphMaker/dataBindAes.d.ts +5 -5
  7. package/dist/GraphMaker/dataBindAes.d.ts.map +1 -1
  8. package/dist/GraphMaker/dataBindAes.js +52 -49
  9. package/dist/GraphMaker/dataBindAes.js.map +1 -1
  10. package/dist/GraphMaker/forms/LayersForm/AesSelector.vue.js +14 -14
  11. package/dist/GraphMaker/forms/LayersForm/AesSelector.vue.js.map +1 -1
  12. package/dist/GraphMaker/index.vue.d.ts.map +1 -1
  13. package/dist/GraphMaker/index.vue.js +125 -124
  14. package/dist/GraphMaker/index.vue.js.map +1 -1
  15. package/dist/GraphMaker/types.d.ts +1 -1
  16. package/dist/GraphMaker/types.d.ts.map +1 -1
  17. package/dist/GraphMaker/utils/createChartSettingsForRender/composeBubbleSettings.d.ts +6 -0
  18. package/dist/GraphMaker/utils/createChartSettingsForRender/composeBubbleSettings.d.ts.map +1 -1
  19. package/dist/GraphMaker/utils/createChartSettingsForRender/composeChartSettings.d.ts +4 -8
  20. package/dist/GraphMaker/utils/createChartSettingsForRender/composeChartSettings.d.ts.map +1 -1
  21. package/dist/GraphMaker/utils/createChartSettingsForRender/composeChartSettings.js.map +1 -1
  22. package/dist/GraphMaker/utils/createChartSettingsForRender/composeDendroSettings.d.ts +15 -0
  23. package/dist/GraphMaker/utils/createChartSettingsForRender/composeDendroSettings.d.ts.map +1 -1
  24. package/dist/GraphMaker/utils/createChartSettingsForRender/composeDiscreteSettings.d.ts +12 -3
  25. package/dist/GraphMaker/utils/createChartSettingsForRender/composeDiscreteSettings.d.ts.map +1 -1
  26. package/dist/GraphMaker/utils/createChartSettingsForRender/composeHeatmapSettings.d.ts +21 -0
  27. package/dist/GraphMaker/utils/createChartSettingsForRender/composeHeatmapSettings.d.ts.map +1 -1
  28. package/dist/GraphMaker/utils/createChartSettingsForRender/composeHistogramSettings.d.ts +10 -6
  29. package/dist/GraphMaker/utils/createChartSettingsForRender/composeHistogramSettings.d.ts.map +1 -1
  30. package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotSettings.d.ts +31 -13
  31. package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotSettings.d.ts.map +1 -1
  32. package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotSettings.js +56 -62
  33. package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotSettings.js.map +1 -1
  34. package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotUmapSettings.d.ts +29 -13
  35. package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotUmapSettings.d.ts.map +1 -1
  36. package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotUmapSettings.js +20 -19
  37. package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotUmapSettings.js.map +1 -1
  38. package/dist/GraphMaker/utils/loadUniqueValuesToSave.d.ts.map +1 -1
  39. package/dist/GraphMaker/utils/loadUniqueValuesToSave.js +57 -54
  40. package/dist/GraphMaker/utils/loadUniqueValuesToSave.js.map +1 -1
  41. package/dist/lib.js +1 -1
  42. package/dist/node_modules/@milaboratories/miplots4/dist/AbstractChart.js +5 -5
  43. package/dist/node_modules/@milaboratories/miplots4/dist/AbstractChart.js.map +1 -1
  44. package/dist/node_modules/@milaboratories/miplots4/dist/DataFrame.js +95 -72
  45. package/dist/node_modules/@milaboratories/miplots4/dist/DataFrame.js.map +1 -1
  46. package/dist/node_modules/@milaboratories/miplots4/dist/MiPlots.js +8 -5
  47. package/dist/node_modules/@milaboratories/miplots4/dist/MiPlots.js.map +1 -1
  48. package/dist/node_modules/@milaboratories/miplots4/dist/bubble/ChartRenderer.js +124 -122
  49. package/dist/node_modules/@milaboratories/miplots4/dist/bubble/ChartRenderer.js.map +1 -1
  50. package/dist/node_modules/@milaboratories/miplots4/dist/bubble/components/Chart.js +72 -91
  51. package/dist/node_modules/@milaboratories/miplots4/dist/bubble/components/Chart.js.map +1 -1
  52. package/dist/node_modules/@milaboratories/miplots4/dist/bubble/components/ChartsGroup.js +43 -41
  53. package/dist/node_modules/@milaboratories/miplots4/dist/bubble/components/ChartsGroup.js.map +1 -1
  54. package/dist/node_modules/@milaboratories/miplots4/dist/bubble/getCellTooltip.js +28 -0
  55. package/dist/node_modules/@milaboratories/miplots4/dist/bubble/getCellTooltip.js.map +1 -0
  56. package/dist/node_modules/@milaboratories/miplots4/dist/bubble/getGroupedCellsData.js +94 -0
  57. package/dist/node_modules/@milaboratories/miplots4/dist/bubble/getGroupedCellsData.js.map +1 -0
  58. package/dist/node_modules/@milaboratories/miplots4/dist/bubble/index.js +38 -34
  59. package/dist/node_modules/@milaboratories/miplots4/dist/bubble/index.js.map +1 -1
  60. package/dist/node_modules/@milaboratories/miplots4/dist/bubble/utils/calculateCaptionTails.js.map +1 -1
  61. package/dist/node_modules/@milaboratories/miplots4/dist/common/Error.js +4 -22
  62. package/dist/node_modules/@milaboratories/miplots4/dist/common/Error.js.map +1 -1
  63. package/dist/node_modules/@milaboratories/miplots4/dist/common/Legend.js.map +1 -1
  64. package/dist/node_modules/@milaboratories/miplots4/dist/common/Tooltip.js +11 -11
  65. package/dist/node_modules/@milaboratories/miplots4/dist/common/Tooltip.js.map +1 -1
  66. package/dist/node_modules/@milaboratories/miplots4/dist/common/useDataFrame.js +20 -0
  67. package/dist/node_modules/@milaboratories/miplots4/dist/common/useDataFrame.js.map +1 -0
  68. package/dist/node_modules/@milaboratories/miplots4/dist/dendro/ChartRenderer.js +181 -181
  69. package/dist/node_modules/@milaboratories/miplots4/dist/dendro/ChartRenderer.js.map +1 -1
  70. package/dist/node_modules/@milaboratories/miplots4/dist/dendro/DendroSettingsImpl.js +2 -2
  71. package/dist/node_modules/@milaboratories/miplots4/dist/dendro/DendroSettingsImpl.js.map +1 -1
  72. package/dist/node_modules/@milaboratories/miplots4/dist/dendro/components/Chart.js +45 -45
  73. package/dist/node_modules/@milaboratories/miplots4/dist/dendro/components/Chart.js.map +1 -1
  74. package/dist/node_modules/@milaboratories/miplots4/dist/dendro/components/Heatmap.js +27 -27
  75. package/dist/node_modules/@milaboratories/miplots4/dist/dendro/components/Heatmap.js.map +1 -1
  76. package/dist/node_modules/@milaboratories/miplots4/dist/dendro/components/Legend.js.map +1 -1
  77. package/dist/node_modules/@milaboratories/miplots4/dist/dendro/components/LinksGroup.js +18 -18
  78. package/dist/node_modules/@milaboratories/miplots4/dist/dendro/components/LinksGroup.js.map +1 -1
  79. package/dist/node_modules/@milaboratories/miplots4/dist/dendro/components/NodesGroup.js +36 -36
  80. package/dist/node_modules/@milaboratories/miplots4/dist/dendro/components/NodesGroup.js.map +1 -1
  81. package/dist/node_modules/@milaboratories/miplots4/dist/dendro/getHeatmapData.js +45 -41
  82. package/dist/node_modules/@milaboratories/miplots4/dist/dendro/getHeatmapData.js.map +1 -1
  83. package/dist/node_modules/@milaboratories/miplots4/dist/dendro/getHierarchyData.js +33 -33
  84. package/dist/node_modules/@milaboratories/miplots4/dist/dendro/getHierarchyData.js.map +1 -1
  85. package/dist/node_modules/@milaboratories/miplots4/dist/dendro/index.js +90 -93
  86. package/dist/node_modules/@milaboratories/miplots4/dist/dendro/index.js.map +1 -1
  87. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/ChartRenderer.js +199 -198
  88. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/ChartRenderer.js.map +1 -1
  89. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/DiscreteSettingsImpl.js +17 -17
  90. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/DiscreteSettingsImpl.js.map +1 -1
  91. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/components/layers/BoxElement.js.map +1 -1
  92. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/index.js +102 -99
  93. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/index.js.map +1 -1
  94. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/bar.js +31 -36
  95. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/bar.js.map +1 -1
  96. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/binnedDots.js +62 -74
  97. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/binnedDots.js.map +1 -1
  98. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/boxes.js +52 -53
  99. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/boxes.js.map +1 -1
  100. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/dots.js +32 -32
  101. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/dots.js.map +1 -1
  102. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/lines.js +7 -6
  103. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/lines.js.map +1 -1
  104. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/logo.js +23 -23
  105. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/logo.js.map +1 -1
  106. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/pairedPoints.js +63 -63
  107. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/pairedPoints.js.map +1 -1
  108. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/sina.js +60 -64
  109. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/sina.js.map +1 -1
  110. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/stackedBar.js +23 -23
  111. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/stackedBar.js.map +1 -1
  112. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/utils/getOutliersBounds.js +5 -5
  113. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/utils/getOutliersBounds.js.map +1 -1
  114. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/utils/splitTextByWidth.js +13 -13
  115. package/dist/node_modules/@milaboratories/miplots4/dist/discrete/utils/splitTextByWidth.js.map +1 -1
  116. package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/ChartRenderer.js +258 -256
  117. package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/ChartRenderer.js.map +1 -1
  118. package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/HeatmapSettingsImpl.js +1 -1
  119. package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/HeatmapSettingsImpl.js.map +1 -1
  120. package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/components/Annotations/Annotation.js +81 -79
  121. package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/components/Annotations/Annotation.js.map +1 -1
  122. package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/components/Chart.js +140 -134
  123. package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/components/Chart.js.map +1 -1
  124. package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/components/ChartsGroup.js +17 -17
  125. package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/components/ChartsGroup.js.map +1 -1
  126. package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/getCells.js +99 -95
  127. package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/getCells.js.map +1 -1
  128. package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/index.js +32 -31
  129. package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/index.js.map +1 -1
  130. package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/utils/calculateAnnotationTitleSizes.js +1 -1
  131. package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/utils/calculateAnnotationTitleSizes.js.map +1 -1
  132. package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/utils/calculateCaptionTails.js.map +1 -1
  133. package/dist/node_modules/@milaboratories/miplots4/dist/histogram/ChartRenderer.js +143 -142
  134. package/dist/node_modules/@milaboratories/miplots4/dist/histogram/ChartRenderer.js.map +1 -1
  135. package/dist/node_modules/@milaboratories/miplots4/dist/histogram/HistogramSettingsImpl.js.map +1 -1
  136. package/dist/node_modules/@milaboratories/miplots4/dist/histogram/components/Chart.js +30 -30
  137. package/dist/node_modules/@milaboratories/miplots4/dist/histogram/components/Chart.js.map +1 -1
  138. package/dist/node_modules/@milaboratories/miplots4/dist/histogram/components/ChartsGroup.js +7 -7
  139. package/dist/node_modules/@milaboratories/miplots4/dist/histogram/getHistogramData.js +53 -54
  140. package/dist/node_modules/@milaboratories/miplots4/dist/histogram/getHistogramData.js.map +1 -1
  141. package/dist/node_modules/@milaboratories/miplots4/dist/histogram/index.js +62 -58
  142. package/dist/node_modules/@milaboratories/miplots4/dist/histogram/index.js.map +1 -1
  143. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/@d3fc/d3fc-axis/src/axisBase.js +7 -7
  144. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-array/src/min.js +6 -12
  145. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-array/src/min.js.map +1 -1
  146. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-shape/src/line.js.map +1 -1
  147. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/kdbush/index.js +148 -0
  148. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/kdbush/index.js.map +1 -0
  149. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/ChartRenderer.js +172 -168
  150. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/ChartRenderer.js.map +1 -1
  151. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/ScatterplotSettingsImpl.js +28 -28
  152. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/ScatterplotSettingsImpl.js.map +1 -1
  153. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/Chart.js +11 -11
  154. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartAxisTitles.js +30 -29
  155. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartAxisTitles.js.map +1 -1
  156. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartLayersData.js +135 -153
  157. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartLayersData.js.map +1 -1
  158. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartTooltip.js +35 -32
  159. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartTooltip.js.map +1 -1
  160. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartTrendsData.js +27 -27
  161. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartTrendsData.js.map +1 -1
  162. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartsGroup.js +14 -14
  163. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/constants.js.map +1 -1
  164. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/dots.js +24 -25
  165. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/dots.js.map +1 -1
  166. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/getLayersData.js +13 -13
  167. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/getLayersData.js.map +1 -1
  168. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/index.js +69 -76
  169. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/index.js.map +1 -1
  170. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/linearRegression.js +85 -83
  171. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/linearRegression.js.map +1 -1
  172. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/createAesGetter.js +20 -20
  173. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/createAesGetter.js.map +1 -1
  174. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/createLegendInfo.js +50 -38
  175. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/createLegendInfo.js.map +1 -1
  176. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/formatColumnValue.js +11 -0
  177. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/formatColumnValue.js.map +1 -0
  178. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/getVisibleLabels.js +46 -56
  179. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/getVisibleLabels.js.map +1 -1
  180. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/sortDotsByGrouping.js +18 -0
  181. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/sortDotsByGrouping.js.map +1 -0
  182. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/ChartRenderer.js +223 -205
  183. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/ChartRenderer.js.map +1 -1
  184. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/SettingsImpl.js +26 -26
  185. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/SettingsImpl.js.map +1 -1
  186. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/colors.js +42 -0
  187. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/colors.js.map +1 -0
  188. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/components/LowerSVG.js +84 -81
  189. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/components/LowerSVG.js.map +1 -1
  190. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/components/SVGLayer.js +11 -11
  191. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/components/UpperSVG.js +15 -14
  192. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/components/UpperSVG.js.map +1 -1
  193. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/index.js +97 -118
  194. package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/index.js.map +1 -1
  195. package/dist/node_modules/@milaboratories/miplots4/dist/types/common.js +3 -1
  196. package/dist/node_modules/@milaboratories/miplots4/dist/types/common.js.map +1 -1
  197. package/dist/node_modules/@milaboratories/miplots4/dist/types/dendro.js +1 -1
  198. package/dist/node_modules/@milaboratories/miplots4/dist/types/dendro.js.map +1 -1
  199. package/dist/node_modules/@milaboratories/miplots4/dist/types/discrete.js +1 -1
  200. package/dist/node_modules/@milaboratories/miplots4/dist/types/discrete.js.map +1 -1
  201. package/dist/node_modules/@milaboratories/miplots4/dist/types/heatmap.js +1 -1
  202. package/dist/node_modules/@milaboratories/miplots4/dist/types/heatmap.js.map +1 -1
  203. package/dist/node_modules/@milaboratories/miplots4/dist/types/histogram.js +1 -1
  204. package/dist/node_modules/@milaboratories/miplots4/dist/types/histogram.js.map +1 -1
  205. package/dist/node_modules/@milaboratories/miplots4/dist/types/scatterplot-umap.js +23 -17
  206. package/dist/node_modules/@milaboratories/miplots4/dist/types/scatterplot-umap.js.map +1 -1
  207. package/dist/node_modules/@milaboratories/miplots4/dist/types/scatterplot.js +25 -19
  208. package/dist/node_modules/@milaboratories/miplots4/dist/types/scatterplot.js.map +1 -1
  209. package/dist/node_modules/@milaboratories/miplots4/dist/utils/TextMeasurer/TextMeasurer.js +39 -0
  210. package/dist/node_modules/@milaboratories/miplots4/dist/utils/TextMeasurer/TextMeasurer.js.map +1 -0
  211. package/dist/node_modules/@milaboratories/miplots4/dist/utils/TextMeasurer/charToWidth.json.js +101 -0
  212. package/dist/node_modules/@milaboratories/miplots4/dist/utils/TextMeasurer/charToWidth.json.js.map +1 -0
  213. package/dist/node_modules/@milaboratories/miplots4/dist/utils/arrangeLegendParts.js +4 -4
  214. package/dist/node_modules/@milaboratories/miplots4/dist/utils/arrangeLegendParts.js.map +1 -1
  215. package/dist/node_modules/@milaboratories/miplots4/dist/utils/arraysAreDifferent.js +7 -0
  216. package/dist/node_modules/@milaboratories/miplots4/dist/utils/arraysAreDifferent.js.map +1 -0
  217. package/dist/node_modules/@milaboratories/miplots4/dist/utils/getLegendWidth.js +3 -3
  218. package/dist/node_modules/@milaboratories/miplots4/dist/utils/getLegendWidth.js.map +1 -1
  219. package/dist/node_modules/@milaboratories/pf-plots/dist/index.js +1111 -1097
  220. package/dist/node_modules/@milaboratories/pf-plots/dist/index.js.map +1 -1
  221. package/package.json +3 -3
  222. package/dist/node_modules/@milaboratories/miplots4/dist/bubble/getCells.js +0 -91
  223. package/dist/node_modules/@milaboratories/miplots4/dist/bubble/getCells.js.map +0 -1
  224. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/add.js +0 -30
  225. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/add.js.map +0 -1
  226. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/cover.js +0 -29
  227. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/cover.js.map +0 -1
  228. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/data.js +0 -12
  229. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/data.js.map +0 -1
  230. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/extent.js +0 -7
  231. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/extent.js.map +0 -1
  232. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/find.js +0 -26
  233. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/find.js.map +0 -1
  234. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/quad.js +0 -7
  235. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/quad.js.map +0 -1
  236. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/quadtree.js +0 -51
  237. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/quadtree.js.map +0 -1
  238. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/remove.js +0 -21
  239. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/remove.js.map +0 -1
  240. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/root.js +0 -7
  241. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/root.js.map +0 -1
  242. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/size.js +0 -12
  243. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/size.js.map +0 -1
  244. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/visit.js +0 -14
  245. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/visit.js.map +0 -1
  246. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/visitAfter.js +0 -19
  247. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/visitAfter.js.map +0 -1
  248. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/x.js +0 -11
  249. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/x.js.map +0 -1
  250. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/y.js +0 -11
  251. package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/y.js.map +0 -1
  252. package/dist/node_modules/@milaboratories/miplots4/dist/utils/TextMeasurer.js +0 -24
  253. package/dist/node_modules/@milaboratories/miplots4/dist/utils/TextMeasurer.js.map +0 -1
@@ -1,83 +1,83 @@
1
1
  import { j as k } from "../node_modules/react/jsx-runtime.js";
2
- import { BLACK as U } from "../constants.js";
3
- import { updateLinksHeight as X, updateNodesHorizontalPosition as Q } from "./getHierarchyData.js";
4
- import { DEFAULT_DOT_AES as Y, LEGEND_OFFSET as Z } from "../scatterplot/constants.js";
5
- import { isCategoricalAes as V, isContinuousAes as $ } from "../types/common.js";
2
+ import { createRoot as U } from "../node_modules/react-dom/client.js";
3
+ import { Error as X } from "../common/Error.js";
4
+ import { BLACK as Q } from "../constants.js";
5
+ import { DEFAULT_DOT_AES as Y, LEGEND_OFFSET as J } from "../scatterplot/constants.js";
6
+ import { isCategoricalAes as $, isContinuousAes as j } from "../types/common.js";
6
7
  import "../types/discrete.js";
7
8
  import "../types/scatterplot.js";
8
9
  import "../types/heatmap.js";
9
10
  import "../types/dendro.js";
10
11
  import "../types/histogram.js";
11
12
  import "../types/bubble.js";
12
- import { getContinuousLegendTicks as J } from "../utils/getContinuousLegendTicks.js";
13
+ import { getContinuousLegendTicks as Z } from "../utils/getContinuousLegendTicks.js";
13
14
  import { getContinuousLegendWidth as ee, getDiscreteLegendWidth as te } from "../utils/getLegendWidth.js";
14
- import { TextMeasurer as K } from "../utils/TextMeasurer.js";
15
- import { createRoot as ae } from "../node_modules/react-dom/client.js";
16
- import { MAX_HEATMAP_WIDTH as ie, COLOR_NULL as _, MAX_LEGEND_HEIGHT as se, MARGIN as w, HEATMAP_LEFT_OFFSET as P, HEIGHT as j, WIDTH as D } from "./constants.js";
17
- import { Chart as oe } from "./components/Chart.js";
18
- import { Error as he } from "../common/Error.js";
19
- import H from "../node_modules/d3-scale/src/ordinal.js";
20
- import re from "../node_modules/d3-scale/src/linear.js";
15
+ import { TextMeasurer as G } from "../utils/TextMeasurer/TextMeasurer.js";
16
+ import { Chart as ae } from "./components/Chart.js";
17
+ import { MAX_HEATMAP_WIDTH as ie, COLOR_NULL as F, MAX_LEGEND_HEIGHT as se, MARGIN as E, HEATMAP_LEFT_OFFSET as P, HEIGHT as V, WIDTH as D } from "./constants.js";
18
+ import { updateLinksHeight as oe, updateNodesHorizontalPosition as he } from "./getHierarchyData.js";
19
+ import W from "../node_modules/d3-scale/src/ordinal.js";
20
+ import le from "../node_modules/d3-scale/src/linear.js";
21
21
  import { sqrt as q } from "../node_modules/d3-scale/src/pow.js";
22
- import le from "../node_modules/d3-hierarchy/src/cluster.js";
23
- var ne = Object.defineProperty, de = (i, e, t) => e in i ? ne(i, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : i[e] = t, L = (i, e, t) => de(i, typeof e != "symbol" ? e + "" : e, t);
24
- function F(i) {
25
- if (V(i))
26
- return (e) => i.valuesMap[String(e[i.columnName.value])];
27
- if ($(i)) {
28
- const { domain: e, range: t } = i, s = q().domain(e).range(t);
29
- return (h) => {
30
- const n = s(Number(h[i.columnName.value]));
31
- return Math.max(1, n);
22
+ import re from "../node_modules/d3-hierarchy/src/cluster.js";
23
+ var ne = Object.defineProperty, de = (h, e, t) => e in h ? ne(h, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : h[e] = t, z = (h, e, t) => de(h, typeof e != "symbol" ? e + "" : e, t);
24
+ function K(h, e) {
25
+ if ($(e))
26
+ return (t) => e.valuesMap[String(h.getColumnValue(e.columnName.value, t))];
27
+ if (j(e)) {
28
+ const { domain: t, range: i } = e, n = q().domain(t).range(i);
29
+ return (l) => {
30
+ const s = n(Number(h.getColumnValue(e.columnName.value, l)));
31
+ return Math.max(1, s);
32
32
  };
33
33
  }
34
- return (e) => i;
34
+ return (t) => e;
35
35
  }
36
- function pe(i) {
36
+ function pe(h, e) {
37
37
  return {
38
- nodeShape: F(i.nodeShape),
39
- nodeColor: F(i.nodeColor),
40
- nodeSize: F(i.nodeSize),
41
- lineShape: F(i.lineShape),
42
- lineColor: F(i.lineColor)
38
+ nodeShape: K(h, e.nodeShape),
39
+ nodeColor: K(h, e.nodeColor),
40
+ nodeSize: K(h, e.nodeSize),
41
+ lineShape: K(h, e.lineShape),
42
+ lineColor: K(h, e.lineColor)
43
43
  };
44
44
  }
45
- const me = (i, e) => {
46
- const t = Math.min(...e), s = Math.max(...e);
47
- if (t === s) {
48
- const l = i % 2 === 0 ? [] : [t];
49
- for (let p = 1; p < i / 2 + 1; p++)
50
- l.push(t + p), l.unshift(t - p);
51
- return l;
45
+ const me = (h, e) => {
46
+ const t = Math.min(...e), i = Math.max(...e);
47
+ if (t === i) {
48
+ const s = h % 2 === 0 ? [] : [t];
49
+ for (let c = 1; c < h / 2 + 1; c++)
50
+ s.push(t + c), s.unshift(t - c);
51
+ return s;
52
52
  }
53
- if (i < 2)
54
- return [t, s];
55
- const h = (s - t) / (i - 1), n = [];
56
- for (let l = 0; l < i - 1; l++)
57
- n.push(t + h * l);
58
- return n.push(s), n;
53
+ if (h < 2)
54
+ return [t, i];
55
+ const n = (i - t) / (h - 1), l = [];
56
+ for (let s = 0; s < h - 1; s++)
57
+ l.push(t + n * s);
58
+ return l.push(i), l;
59
59
  };
60
- function ce(i, e = 1, t, s) {
61
- const h = (i < 16 ? 40 : i < 49 ? 32 : 24) * e;
62
- return Math.max(Math.min(h, s ?? 1 / 0), t ?? -1 / 0);
60
+ function ce(h, e = 1, t, i) {
61
+ const n = (h < 16 ? 40 : h < 49 ? 32 : 24) * e;
62
+ return Math.max(Math.min(n, i ?? 1 / 0), t ?? -1 / 0);
63
63
  }
64
- class Fe {
64
+ class Ke {
65
65
  constructor() {
66
- L(this, "component", /* @__PURE__ */ k.jsx(k.Fragment, {})), L(this, "reactRoot", null), L(this, "parentNode", null), L(this, "rootNode", null), L(this, "chartSizes", {
66
+ z(this, "component", /* @__PURE__ */ k.jsx(k.Fragment, {})), z(this, "reactRoot", null), z(this, "parentNode", null), z(this, "rootNode", null), z(this, "chartSizes", {
67
67
  treeWidth: D,
68
- treeHeight: j,
68
+ treeHeight: V,
69
69
  heatmapWidth: 0,
70
70
  heatmapHeight: 0,
71
- totalWidth: D + D + w.LEFT + w.RIGHT,
72
- totalHeight: j + w.TOP + w.BOTTOM,
71
+ totalWidth: D + D + E.LEFT + E.RIGHT,
72
+ totalHeight: V + E.TOP + E.BOTTOM,
73
73
  labelsOffset: 0
74
- }), L(this, "legend", { width: 0, height: 0, items: [] }), L(this, "heatmapScales", {
75
- x: H().domain(["null"]).range([1]),
76
- y: H().domain(["null"]).range([1])
77
- }), L(this, "heatmapStep", { x: 0, y: 0 }), L(this, "heatmapColorScale", {
78
- scale: H([]),
74
+ }), z(this, "legend", { width: 0, height: 0, items: [] }), z(this, "heatmapScales", {
75
+ x: W().domain(["null"]).range([1]),
76
+ y: W().domain(["null"]).range([1])
77
+ }), z(this, "heatmapStep", { x: 0, y: 0 }), z(this, "heatmapColorScale", {
78
+ scale: W([]),
79
79
  getter: () => "white"
80
- }), L(this, "heatmapLabels", []);
80
+ }), z(this, "heatmapLabels", []);
81
81
  }
82
82
  clear() {
83
83
  var e;
@@ -87,30 +87,30 @@ class Fe {
87
87
  });
88
88
  }
89
89
  init(e) {
90
- this.parentNode === null && (this.parentNode = e, this.rootNode = document.createElement("div"), this.parentNode.appendChild(this.rootNode), this.reactRoot = ae(this.rootNode));
90
+ this.parentNode === null && (this.parentNode = e, this.rootNode = document.createElement("div"), this.parentNode.appendChild(this.rootNode), this.reactRoot = U(this.rootNode));
91
91
  }
92
- updateHeatmapScales(e, t, s) {
92
+ updateHeatmapScales(e, t, i) {
93
93
  if (e === null) {
94
94
  this.chartSizes.heatmapWidth = 0;
95
95
  return;
96
96
  }
97
- const { xKeysByGroups: h, xGroupKeys: n, xKeys: l, yKeys: p } = e, S = 5, z = n.map((o) => h[o].length), O = z.reduce((o, a) => o + a, 0), W = this.chartSizes.treeHeight / p.length, C = Math.min(
97
+ const { xKeysByGroups: n, xGroupKeys: l, xKeys: s, yKeys: c } = e, T = 5, x = l.map((o) => n[o].length), A = x.reduce((o, a) => o + a, 0), L = this.chartSizes.treeHeight / c.length, w = Math.min(
98
98
  Math.max(
99
- (ie - (z.filter((o) => o > 0).length - 1) * S) / O,
100
- s.minCellWidth
99
+ (ie - (x.filter((o) => o > 0).length - 1) * T) / A,
100
+ i.minCellWidth
101
101
  ),
102
- s.maxCellWidth
103
- ), v = [];
104
- let x = 0;
105
- n.forEach((o) => {
106
- const a = h[o];
102
+ i.maxCellWidth
103
+ ), H = [];
104
+ let v = 0;
105
+ l.forEach((o) => {
106
+ const a = n[o];
107
107
  a.forEach(() => {
108
- v.push(x), x += C;
109
- }), a.length > 0 && (x += S);
110
- }), this.heatmapScales.x = H().domain(l).range(v), this.heatmapScales.y = H().domain(p).range(p.map((o, a) => a * W)), this.heatmapStep.x = C, this.heatmapStep.y = W;
111
- const { colorsList: T, colorsMap: f } = t.aes;
112
- if (t.valueType === "continuous" && T) {
113
- const o = re().domain(me(T.length, e.meta.valueExtent)).range(T);
108
+ H.push(v), v += w;
109
+ }), a.length > 0 && (v += T);
110
+ }), this.heatmapScales.x = W().domain(s).range(H), this.heatmapScales.y = W().domain(c).range(c.map((o, a) => a * L)), this.heatmapStep.x = w, this.heatmapStep.y = L;
111
+ const { colorsList: S, colorsMap: f } = t.aes;
112
+ if (t.valueType === "continuous" && S) {
113
+ const o = le().domain(me(S.length, e.meta.valueExtent)).range(S);
114
114
  this.heatmapColorScale = {
115
115
  scale: o,
116
116
  getter: (a) => o(a)
@@ -119,26 +119,26 @@ class Fe {
119
119
  if (t.valueType === "discrete" && f) {
120
120
  const o = Object.keys(f).filter((a) => e.meta.uniqueValues.has(a));
121
121
  this.heatmapColorScale = {
122
- scale: H(
122
+ scale: W(
123
123
  o,
124
124
  o.map((a) => f[a])
125
- ).unknown(_),
126
- getter: (a) => a ? f[a] ?? _ : _
125
+ ).unknown(F),
126
+ getter: (a) => a ? f[a] ?? F : F
127
127
  };
128
128
  }
129
- if (t.valueType === "stringSource" && T) {
130
- const o = [...e.meta.uniqueValues], a = H(
129
+ if (t.valueType === "stringSource" && S) {
130
+ const o = [...e.meta.uniqueValues], a = W(
131
131
  o,
132
- o.map((N, y) => T[y % T.length])
133
- ).unknown(_);
132
+ o.map((y, O) => S[O % S.length])
133
+ ).unknown(F);
134
134
  this.heatmapColorScale = {
135
135
  scale: a,
136
- getter: (N) => N ? a(N) : _
136
+ getter: (y) => y ? a(y) : F
137
137
  };
138
138
  }
139
139
  this.chartSizes.heatmapWidth = this.heatmapScales.x(e.xKeys[e.xKeys.length - 1]) + this.heatmapStep.x;
140
140
  }
141
- updateLegendSize(e, t, s, h, n, l) {
141
+ updateLegendSize(e, t, i, n, l, s) {
142
142
  if (!e.show) {
143
143
  this.legend = {
144
144
  width: 0,
@@ -147,37 +147,37 @@ class Fe {
147
147
  };
148
148
  return;
149
149
  }
150
- const p = new K("600 14px Arial"), S = 16, z = 48, O = 20, W = 24;
151
- function C(c, r) {
150
+ const c = new G("600 14px Arial"), T = 16, x = 48, A = 20, L = 24;
151
+ function w(d, r) {
152
152
  return Math.max(
153
- ...c.map((u) => p.getTextWidth(String(u)) + O),
154
- p.getTextWidth(r)
153
+ ...d.map((p) => c.getTextWidth(String(p)) + A),
154
+ c.getTextWidth(r)
155
155
  );
156
156
  }
157
- const v = [];
158
- [s.nodeColor, s.nodeShape, s.lineColor].filter(V).map((c) => c.columnName).forEach((c) => {
159
- const r = t[c.value];
157
+ const H = [];
158
+ [i.nodeColor, i.nodeShape, i.lineColor].filter($).map((d) => d.columnName).forEach((d) => {
159
+ const r = t[d.value];
160
160
  if (r.usedAes.length === 0 || !r.aesMap)
161
161
  return;
162
- const u = c.label ?? c.value, b = r.values, d = {};
163
- b.forEach((m) => {
164
- d[m] || (d[m] = { ...Y }), r.usedAes.forEach((g) => {
165
- var M, A, E;
166
- (g === "dotFill" || g === "lineColor") && (d[m].color = ((M = r.aesMap[m]) == null ? void 0 : M[g]) ?? U), g === "dotShape" && (d[m].shape = ((A = r.aesMap[m]) == null ? void 0 : A[g]) ?? "21"), g === "dotSize" && (d[m].size = ((E = r.aesMap[m]) == null ? void 0 : E[g]) ?? 3);
162
+ const p = d.label ?? d.value, b = r.values, m = {};
163
+ b.forEach((u) => {
164
+ m[u] || (m[u] = { ...Y }), r.usedAes.forEach((g) => {
165
+ var M, N, C;
166
+ (g === "dotFill" || g === "lineColor") && (m[u].color = ((M = r.aesMap[u]) == null ? void 0 : M[g]) ?? Q), g === "dotShape" && (m[u].shape = ((N = r.aesMap[u]) == null ? void 0 : N[g]) ?? "21"), g === "dotSize" && (m[u].size = ((C = r.aesMap[u]) == null ? void 0 : C[g]) ?? 3);
167
167
  });
168
- }), v.push({
169
- columnKey: u,
170
- data: d,
168
+ }), H.push({
169
+ columnKey: p,
170
+ data: m,
171
171
  values: r.values,
172
172
  labels: r.labels
173
173
  });
174
174
  });
175
- const x = [];
176
- let T = 0, f = 0, o = 0, a = Math.min(this.chartSizes.treeHeight, se);
177
- if (h && n) {
178
- const c = l.valueType, r = h.label ?? h.value;
179
- if (c === "continuous") {
180
- const u = this.heatmapColorScale.scale, b = J(u, n.meta.valueExtent, 4), d = {
175
+ const v = [];
176
+ let S = 0, f = 0, o = 0, a = Math.min(this.chartSizes.treeHeight, se);
177
+ if (n && l) {
178
+ const d = s.valueType, r = n.label ?? n.value;
179
+ if (d === "continuous") {
180
+ const p = this.heatmapColorScale.scale, b = Z(p, l.meta.valueExtent, 4), m = {
181
181
  id: "heatmapValue",
182
182
  type: "continuous",
183
183
  width: ee(b, r),
@@ -185,136 +185,136 @@ class Fe {
185
185
  left: 0,
186
186
  top: 0,
187
187
  title: r,
188
- scale: u,
188
+ scale: p,
189
189
  values: b,
190
190
  labels: {}
191
191
  };
192
- x.push(d), f = d.height + z, T = d.width;
192
+ v.push(m), f = m.height + x, S = m.width;
193
193
  } else {
194
- const u = this.heatmapColorScale.scale, b = te(u, r), d = u.domain(), m = d.length * S, g = {
194
+ const p = this.heatmapColorScale.scale, b = te(p, r), m = p.domain(), u = m.length * T, g = {
195
195
  id: "heatmapValue",
196
196
  type: "discrete",
197
197
  width: b,
198
- height: m,
198
+ height: u,
199
199
  left: 0,
200
200
  top: 0,
201
201
  title: r,
202
- scale: u,
203
- values: d,
202
+ scale: p,
203
+ values: m,
204
204
  labels: {}
205
205
  };
206
- x.push(g), f = g.height + z, T = g.width;
206
+ v.push(g), f = g.height + x, S = g.width;
207
207
  }
208
208
  }
209
- if (v.map(({ columnKey: c, labels: r, values: u, data: b }) => {
210
- f > a && (f = 0, o += T + W);
211
- const d = c, m = C(
212
- u.map((R) => r[R]),
213
- d
214
- ), g = u.length * S;
209
+ if (H.map(({ columnKey: d, labels: r, values: p, data: b }) => {
210
+ f > a && (f = 0, o += S + L);
211
+ const m = d, u = w(
212
+ p.map((_) => r[_]),
213
+ m
214
+ ), g = p.length * T;
215
215
  g > a && (a = g);
216
- const M = H().domain(u).range(u.map((R) => b[R])), A = o, E = f;
217
- x.push({ id: c, type: "nodes", width: m, height: g, left: A, top: E, title: d, scale: M, values: u, labels: r }), T = m, f += g + z;
218
- }), $(s.nodeSize)) {
219
- f > a && (f = 0, o += T + W);
220
- const { columnName: c, domain: r, range: u } = s.nodeSize, b = c.label ?? c.value, d = q(r, u), m = d.ticks(3), g = d.tickFormat(3), M = m.reduce((G, I) => (G[String(I)] = g(I), G), {}), A = C(
221
- m.map((G) => M[G]),
216
+ const M = W().domain(p).range(p.map((_) => b[_])), N = o, C = f;
217
+ v.push({ id: d, type: "nodes", width: u, height: g, left: N, top: C, title: m, scale: M, values: p, labels: r }), S = u, f += g + x;
218
+ }), j(i.nodeSize)) {
219
+ f > a && (f = 0, o += S + L);
220
+ const { columnName: d, domain: r, range: p } = i.nodeSize, b = d.label ?? d.value, m = q(r, p), u = m.ticks(3), g = m.tickFormat(3), M = u.reduce((R, I) => (R[String(I)] = g(I), R), {}), N = w(
221
+ u.map((R) => M[R]),
222
222
  b
223
- ), E = (d(Math.max(...m)) * 2 + 4) * m.length;
224
- E > a && (a = E);
225
- const R = o, B = f;
226
- x.push({ id: c.value, type: "size", width: A, height: E, left: R, top: B, title: b, scale: d, values: m, labels: M }), T = A, f += E + z;
223
+ ), C = (m(Math.max(...u)) * 2 + 4) * u.length;
224
+ C > a && (a = C);
225
+ const _ = o, B = f;
226
+ v.push({ id: d.value, type: "size", width: N, height: C, left: _, top: B, title: b, scale: m, values: u, labels: M }), S = N, f += C + x;
227
227
  }
228
- const N = o + T + 2 * Z, y = a;
228
+ const y = o + S + 2 * J, O = a;
229
229
  this.legend = {
230
- width: N,
231
- height: y,
232
- items: x
230
+ width: y,
231
+ height: O,
232
+ items: v
233
233
  };
234
234
  }
235
- updateChartSizes(e, t, s) {
236
- const h = s.leaves().length;
235
+ updateChartSizes(e, t, i) {
236
+ const n = i.leaves().length;
237
237
  this.chartSizes.treeWidth = t ? e.width / 2 : e.width;
238
- const n = ce(h, e.scale, e.minCellHeight, e.maxCellHeight) * h;
239
- this.chartSizes.treeHeight = n, this.chartSizes.heatmapHeight = n;
238
+ const l = ce(n, e.scale, e.minCellHeight, e.maxCellHeight) * n;
239
+ this.chartSizes.treeHeight = l, this.chartSizes.heatmapHeight = l;
240
240
  }
241
241
  updateTotalSizes(e) {
242
- this.chartSizes.totalWidth = this.chartSizes.treeWidth + this.chartSizes.heatmapWidth + this.legend.width + w.LEFT + w.RIGHT, e && (this.chartSizes.totalWidth += P), this.legend.width > 0 && (this.chartSizes.totalWidth += P), this.chartSizes.totalHeight = Math.max(this.chartSizes.treeHeight, this.legend.height) + w.TOP + w.BOTTOM;
242
+ this.chartSizes.totalWidth = this.chartSizes.treeWidth + this.chartSizes.heatmapWidth + this.legend.width + E.LEFT + E.RIGHT, e && (this.chartSizes.totalWidth += P), this.legend.width > 0 && (this.chartSizes.totalWidth += P), this.chartSizes.totalHeight = Math.max(this.chartSizes.treeHeight, this.legend.height) + E.TOP + E.BOTTOM;
243
243
  }
244
244
  prepareTableLabels(e) {
245
- const t = new K("bold 14px Arial"), s = "…";
245
+ const t = new G("bold 14px Arial"), i = "…";
246
246
  if (this.heatmapStep.x < 12 || !e) {
247
247
  this.heatmapLabels = [];
248
248
  return;
249
249
  }
250
- const h = this.heatmapStep.x - 4;
251
- this.heatmapLabels = e.xKeys.map((n) => {
252
- const l = e.meta.xLabels[n];
253
- let p = t.getTextWidth(l);
254
- if (p < h)
255
- return l;
256
- let S = l, z = S == null ? void 0 : S.length;
257
- for (; p > h && z > 0; )
258
- z--, S = (l == null ? void 0 : l.substring(0, z)) + s, p = t.getTextWidth(S);
259
- return z > 0 ? S : "";
250
+ const n = this.heatmapStep.x - 4;
251
+ this.heatmapLabels = e.xKeys.map((l) => {
252
+ const s = e.meta.xLabels[l];
253
+ let c = t.getTextWidth(s);
254
+ if (c < n)
255
+ return s;
256
+ let T = s, x = T == null ? void 0 : T.length;
257
+ for (; c > n && x > 0; )
258
+ x--, T = (s == null ? void 0 : s.substring(0, x)) + i, c = t.getTextWidth(T);
259
+ return x > 0 ? T : "";
260
260
  });
261
261
  }
262
262
  addLabelsWidthToTreeArea(e, t) {
263
263
  if (!t)
264
264
  return;
265
- const s = e.leaves(), h = new K("bold 14px Manrope");
266
- let n = 0;
267
- s.forEach((l) => {
268
- if (!l.data.label)
265
+ const i = e.leaves(), n = new G("bold 14px Manrope");
266
+ let l = 0;
267
+ i.forEach((s) => {
268
+ if (!s.data.label)
269
269
  return;
270
- const p = h.getTextWidth(l.data.label), S = l.y + p - this.chartSizes.treeWidth + 8;
271
- S > n && (n = S);
272
- }), this.chartSizes.treeWidth += n;
270
+ const c = n.getTextWidth(s.data.label), T = s.y + c - this.chartSizes.treeWidth + 8;
271
+ T > l && (l = T);
272
+ }), this.chartSizes.treeWidth += l;
273
273
  }
274
- render(e, t, s, h, n, l, p, S, z, O, W, C, v, x, T, f, o) {
275
- var a;
276
- this.updateChartSizes(e.size, v, t), this.updateHeatmapScales(v, x, e.size), this.updateLegendSize(e.legend, T, O, C, v, x), this.prepareTableLabels(v);
277
- const N = h === "top" ? [this.chartSizes.treeWidth, this.chartSizes.treeHeight] : [this.chartSizes.treeHeight, this.chartSizes.treeWidth];
278
- le().size(N).separation(() => 1)(t);
279
- const y = t;
280
- X(
281
- y,
282
- h === "top" ? this.chartSizes.treeHeight : this.chartSizes.treeWidth,
283
- f === "alignLeavesToLine"
284
- ), Q(y), this.addLabelsWidthToTreeArea(y, S), this.updateTotalSizes(v);
285
- const c = pe(O), r = /* @__PURE__ */ k.jsx(
286
- oe,
274
+ render(e, t, i, n, l, s, c, T, x, A, L, w, H, v, S, f, o, a) {
275
+ var y;
276
+ this.updateChartSizes(t.size, v, i), this.updateHeatmapScales(v, S, t.size), this.updateLegendSize(t.legend, f, L, H, v, S), this.prepareTableLabels(v);
277
+ const O = l === "top" ? [this.chartSizes.treeWidth, this.chartSizes.treeHeight] : [this.chartSizes.treeHeight, this.chartSizes.treeWidth];
278
+ re().size(O).separation(() => 1)(i);
279
+ const d = i;
280
+ oe(
281
+ d,
282
+ l === "top" ? this.chartSizes.treeHeight : this.chartSizes.treeWidth,
283
+ o === "alignLeavesToLine"
284
+ ), he(d), this.addLabelsWidthToTreeArea(d, x), this.updateTotalSizes(v);
285
+ const r = pe(e, L), p = /* @__PURE__ */ k.jsx(
286
+ ae,
287
287
  {
288
288
  chartSizes: this.chartSizes,
289
- chartSettings: e,
290
- nodes: y.descendants(),
291
- links: y.links(),
292
- connectionType: s,
293
- rootPosition: h,
294
- edgeInheritance: n,
295
- showNodes: l,
296
- showEdges: p,
297
- showLeavesLabels: S,
298
- showNodesLabels: z,
299
- aesGetters: c,
300
- labels: W,
289
+ chartSettings: t,
290
+ nodes: d.descendants(),
291
+ links: d.links(),
292
+ connectionType: n,
293
+ rootPosition: l,
294
+ edgeInheritance: s,
295
+ showNodes: c,
296
+ showEdges: T,
297
+ showLeavesLabels: x,
298
+ showNodesLabels: A,
299
+ aesGetters: r,
300
+ labels: w,
301
301
  heatmapData: v,
302
302
  heatmapScales: this.heatmapScales,
303
303
  heatmapStep: this.heatmapStep,
304
304
  heatmapColor: this.heatmapColorScale.getter,
305
305
  heatmapLabels: this.heatmapLabels,
306
306
  legendData: this.legend,
307
- onClick: o
307
+ onClick: a
308
308
  }
309
309
  );
310
- this.component = r, (a = this.reactRoot) == null || a.render(r);
310
+ this.component = p, (y = this.reactRoot) == null || y.render(p);
311
311
  }
312
312
  renderError(e) {
313
313
  var t;
314
- (t = this.reactRoot) == null || t.render(/* @__PURE__ */ k.jsx(he, { message: e }));
314
+ (t = this.reactRoot) == null || t.render(/* @__PURE__ */ k.jsx(X, { message: e }));
315
315
  }
316
316
  }
317
317
  export {
318
- Fe as default
318
+ Ke as default
319
319
  };
320
320
  //# sourceMappingURL=ChartRenderer.js.map