@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.
- package/dist/GraphMaker/components/Chart.vue.d.ts.map +1 -1
- package/dist/GraphMaker/components/Chart.vue.js +1 -0
- package/dist/GraphMaker/components/Chart.vue.js.map +1 -1
- package/dist/GraphMaker/components/LassoControls/index.vue.js +15 -13
- package/dist/GraphMaker/components/LassoControls/index.vue.js.map +1 -1
- package/dist/GraphMaker/dataBindAes.d.ts +5 -5
- package/dist/GraphMaker/dataBindAes.d.ts.map +1 -1
- package/dist/GraphMaker/dataBindAes.js +52 -49
- package/dist/GraphMaker/dataBindAes.js.map +1 -1
- package/dist/GraphMaker/forms/LayersForm/AesSelector.vue.js +14 -14
- package/dist/GraphMaker/forms/LayersForm/AesSelector.vue.js.map +1 -1
- package/dist/GraphMaker/index.vue.d.ts.map +1 -1
- package/dist/GraphMaker/index.vue.js +125 -124
- package/dist/GraphMaker/index.vue.js.map +1 -1
- package/dist/GraphMaker/types.d.ts +1 -1
- package/dist/GraphMaker/types.d.ts.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeBubbleSettings.d.ts +6 -0
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeBubbleSettings.d.ts.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeChartSettings.d.ts +4 -8
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeChartSettings.d.ts.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeChartSettings.js.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeDendroSettings.d.ts +15 -0
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeDendroSettings.d.ts.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeDiscreteSettings.d.ts +12 -3
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeDiscreteSettings.d.ts.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeHeatmapSettings.d.ts +21 -0
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeHeatmapSettings.d.ts.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeHistogramSettings.d.ts +10 -6
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeHistogramSettings.d.ts.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotSettings.d.ts +31 -13
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotSettings.d.ts.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotSettings.js +56 -62
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotSettings.js.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotUmapSettings.d.ts +29 -13
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotUmapSettings.d.ts.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotUmapSettings.js +20 -19
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotUmapSettings.js.map +1 -1
- package/dist/GraphMaker/utils/loadUniqueValuesToSave.d.ts.map +1 -1
- package/dist/GraphMaker/utils/loadUniqueValuesToSave.js +57 -54
- package/dist/GraphMaker/utils/loadUniqueValuesToSave.js.map +1 -1
- package/dist/lib.js +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/AbstractChart.js +5 -5
- package/dist/node_modules/@milaboratories/miplots4/dist/AbstractChart.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/DataFrame.js +95 -72
- package/dist/node_modules/@milaboratories/miplots4/dist/DataFrame.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/MiPlots.js +8 -5
- package/dist/node_modules/@milaboratories/miplots4/dist/MiPlots.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/bubble/ChartRenderer.js +124 -122
- package/dist/node_modules/@milaboratories/miplots4/dist/bubble/ChartRenderer.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/bubble/components/Chart.js +72 -91
- package/dist/node_modules/@milaboratories/miplots4/dist/bubble/components/Chart.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/bubble/components/ChartsGroup.js +43 -41
- package/dist/node_modules/@milaboratories/miplots4/dist/bubble/components/ChartsGroup.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/bubble/getCellTooltip.js +28 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/bubble/getCellTooltip.js.map +1 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/bubble/getGroupedCellsData.js +94 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/bubble/getGroupedCellsData.js.map +1 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/bubble/index.js +38 -34
- package/dist/node_modules/@milaboratories/miplots4/dist/bubble/index.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/bubble/utils/calculateCaptionTails.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/common/Error.js +4 -22
- package/dist/node_modules/@milaboratories/miplots4/dist/common/Error.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/common/Legend.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/common/Tooltip.js +11 -11
- package/dist/node_modules/@milaboratories/miplots4/dist/common/Tooltip.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/common/useDataFrame.js +20 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/common/useDataFrame.js.map +1 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/dendro/ChartRenderer.js +181 -181
- package/dist/node_modules/@milaboratories/miplots4/dist/dendro/ChartRenderer.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/dendro/DendroSettingsImpl.js +2 -2
- package/dist/node_modules/@milaboratories/miplots4/dist/dendro/DendroSettingsImpl.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/dendro/components/Chart.js +45 -45
- package/dist/node_modules/@milaboratories/miplots4/dist/dendro/components/Chart.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/dendro/components/Heatmap.js +27 -27
- package/dist/node_modules/@milaboratories/miplots4/dist/dendro/components/Heatmap.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/dendro/components/Legend.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/dendro/components/LinksGroup.js +18 -18
- package/dist/node_modules/@milaboratories/miplots4/dist/dendro/components/LinksGroup.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/dendro/components/NodesGroup.js +36 -36
- package/dist/node_modules/@milaboratories/miplots4/dist/dendro/components/NodesGroup.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/dendro/getHeatmapData.js +45 -41
- package/dist/node_modules/@milaboratories/miplots4/dist/dendro/getHeatmapData.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/dendro/getHierarchyData.js +33 -33
- package/dist/node_modules/@milaboratories/miplots4/dist/dendro/getHierarchyData.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/dendro/index.js +90 -93
- package/dist/node_modules/@milaboratories/miplots4/dist/dendro/index.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/ChartRenderer.js +199 -198
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/ChartRenderer.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/DiscreteSettingsImpl.js +17 -17
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/DiscreteSettingsImpl.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/components/layers/BoxElement.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/index.js +102 -99
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/index.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/bar.js +31 -36
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/bar.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/binnedDots.js +62 -74
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/binnedDots.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/boxes.js +52 -53
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/boxes.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/dots.js +32 -32
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/dots.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/lines.js +7 -6
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/lines.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/logo.js +23 -23
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/logo.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/pairedPoints.js +63 -63
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/pairedPoints.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/sina.js +60 -64
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/sina.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/stackedBar.js +23 -23
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/stackedBar.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/utils/getOutliersBounds.js +5 -5
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/utils/getOutliersBounds.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/utils/splitTextByWidth.js +13 -13
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/utils/splitTextByWidth.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/ChartRenderer.js +258 -256
- package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/ChartRenderer.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/HeatmapSettingsImpl.js +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/HeatmapSettingsImpl.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/components/Annotations/Annotation.js +81 -79
- package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/components/Annotations/Annotation.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/components/Chart.js +140 -134
- package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/components/Chart.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/components/ChartsGroup.js +17 -17
- package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/components/ChartsGroup.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/getCells.js +99 -95
- package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/getCells.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/index.js +32 -31
- package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/index.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/utils/calculateAnnotationTitleSizes.js +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/utils/calculateAnnotationTitleSizes.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/heatmap/utils/calculateCaptionTails.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/histogram/ChartRenderer.js +143 -142
- package/dist/node_modules/@milaboratories/miplots4/dist/histogram/ChartRenderer.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/histogram/HistogramSettingsImpl.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/histogram/components/Chart.js +30 -30
- package/dist/node_modules/@milaboratories/miplots4/dist/histogram/components/Chart.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/histogram/components/ChartsGroup.js +7 -7
- package/dist/node_modules/@milaboratories/miplots4/dist/histogram/getHistogramData.js +53 -54
- package/dist/node_modules/@milaboratories/miplots4/dist/histogram/getHistogramData.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/histogram/index.js +62 -58
- package/dist/node_modules/@milaboratories/miplots4/dist/histogram/index.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/@d3fc/d3fc-axis/src/axisBase.js +7 -7
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-array/src/min.js +6 -12
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-array/src/min.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-shape/src/line.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/kdbush/index.js +148 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/kdbush/index.js.map +1 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/ChartRenderer.js +172 -168
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/ChartRenderer.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/ScatterplotSettingsImpl.js +28 -28
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/ScatterplotSettingsImpl.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/Chart.js +11 -11
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartAxisTitles.js +30 -29
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartAxisTitles.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartLayersData.js +135 -153
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartLayersData.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartTooltip.js +35 -32
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartTooltip.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartTrendsData.js +27 -27
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartTrendsData.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartsGroup.js +14 -14
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/constants.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/dots.js +24 -25
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/dots.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/getLayersData.js +13 -13
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/getLayersData.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/index.js +69 -76
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/index.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/linearRegression.js +85 -83
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/linearRegression.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/createAesGetter.js +20 -20
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/createAesGetter.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/createLegendInfo.js +50 -38
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/createLegendInfo.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/formatColumnValue.js +11 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/formatColumnValue.js.map +1 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/getVisibleLabels.js +46 -56
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/getVisibleLabels.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/sortDotsByGrouping.js +18 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/sortDotsByGrouping.js.map +1 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/ChartRenderer.js +223 -205
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/ChartRenderer.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/SettingsImpl.js +26 -26
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/SettingsImpl.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/colors.js +42 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/colors.js.map +1 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/components/LowerSVG.js +84 -81
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/components/LowerSVG.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/components/SVGLayer.js +11 -11
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/components/UpperSVG.js +15 -14
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/components/UpperSVG.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/index.js +97 -118
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/index.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/types/common.js +3 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/types/common.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/types/dendro.js +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/types/dendro.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/types/discrete.js +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/types/discrete.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/types/heatmap.js +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/types/heatmap.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/types/histogram.js +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/types/histogram.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/types/scatterplot-umap.js +23 -17
- package/dist/node_modules/@milaboratories/miplots4/dist/types/scatterplot-umap.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/types/scatterplot.js +25 -19
- package/dist/node_modules/@milaboratories/miplots4/dist/types/scatterplot.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/utils/TextMeasurer/TextMeasurer.js +39 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/utils/TextMeasurer/TextMeasurer.js.map +1 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/utils/TextMeasurer/charToWidth.json.js +101 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/utils/TextMeasurer/charToWidth.json.js.map +1 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/utils/arrangeLegendParts.js +4 -4
- package/dist/node_modules/@milaboratories/miplots4/dist/utils/arrangeLegendParts.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/utils/arraysAreDifferent.js +7 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/utils/arraysAreDifferent.js.map +1 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/utils/getLegendWidth.js +3 -3
- package/dist/node_modules/@milaboratories/miplots4/dist/utils/getLegendWidth.js.map +1 -1
- package/dist/node_modules/@milaboratories/pf-plots/dist/index.js +1111 -1097
- package/dist/node_modules/@milaboratories/pf-plots/dist/index.js.map +1 -1
- package/package.json +3 -3
- package/dist/node_modules/@milaboratories/miplots4/dist/bubble/getCells.js +0 -91
- package/dist/node_modules/@milaboratories/miplots4/dist/bubble/getCells.js.map +0 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/add.js +0 -30
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/add.js.map +0 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/cover.js +0 -29
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/cover.js.map +0 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/data.js +0 -12
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/data.js.map +0 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/extent.js +0 -7
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/extent.js.map +0 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/find.js +0 -26
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/find.js.map +0 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/quad.js +0 -7
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/quad.js.map +0 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/quadtree.js +0 -51
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/quadtree.js.map +0 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/remove.js +0 -21
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/remove.js.map +0 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/root.js +0 -7
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/root.js.map +0 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/size.js +0 -12
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/size.js.map +0 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/visit.js +0 -14
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/visit.js.map +0 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/visitAfter.js +0 -19
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/visitAfter.js.map +0 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/x.js +0 -11
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/x.js.map +0 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/y.js +0 -11
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-quadtree/src/y.js.map +0 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/utils/TextMeasurer.js +0 -24
- package/dist/node_modules/@milaboratories/miplots4/dist/utils/TextMeasurer.js.map +0 -1
|
@@ -1,72 +1,73 @@
|
|
|
1
|
-
import { j as
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
1
|
+
import { j as b } from "../node_modules/react/jsx-runtime.js";
|
|
2
|
+
import { createRoot as K } from "../node_modules/react-dom/client.js";
|
|
3
|
+
import { Error as Z } from "../common/Error.js";
|
|
4
|
+
import { DataFrameProvider as q } from "../common/useDataFrame.js";
|
|
5
|
+
import { DEFAULT_HEIGHT as $, DEFAULT_WIDTH as R, TITLE_LINE_HEIGHT as J, MAX_SHOWN_UNIQUE_VALUES_IN_LABELS as Q, BLACK as B, TITLE_MARGIN as tt } from "../constants.js";
|
|
6
|
+
import { FACET_TITLE_LINE as et } from "../discrete/constants.js";
|
|
5
7
|
import { splitTextByWidth as O } from "../discrete/utils/splitTextByWidth.js";
|
|
6
|
-
import {
|
|
7
|
-
import { createAesGetter as Y } from "./utils/createAesGetter.js";
|
|
8
|
-
import { getTicksAndFormat as it } from "./utils/getTicksAndFormat.js";
|
|
9
|
-
import { isContinuousAes as j } from "../types/common.js";
|
|
8
|
+
import { isContinuousAes as V } from "../types/common.js";
|
|
10
9
|
import "../types/discrete.js";
|
|
11
10
|
import "../types/scatterplot.js";
|
|
12
11
|
import "../types/heatmap.js";
|
|
13
12
|
import "../types/dendro.js";
|
|
14
13
|
import "../types/histogram.js";
|
|
15
14
|
import "../types/bubble.js";
|
|
15
|
+
import { arrangeLegendParts as it } from "../utils/arrangeLegendParts.js";
|
|
16
16
|
import { getContinuousColorScale as st } from "../utils/getContinuousColorScale.js";
|
|
17
17
|
import { getContinuousLegendTicks as at } from "../utils/getContinuousLegendTicks.js";
|
|
18
|
-
import { TextMeasurer as ot } from "../utils/TextMeasurer.js";
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import
|
|
18
|
+
import { TextMeasurer as ot } from "../utils/TextMeasurer/TextMeasurer.js";
|
|
19
|
+
import { ChartsGroup as nt } from "./components/ChartsGroup.js";
|
|
20
|
+
import { PADDINGS as X, MIN_MARGIN as D, DEFAULT_DOT_AES as W, LEGEND_OFFSET as rt, TICK_OFFSET as G, DEFAULT_TICKS_SIZE as k, MIN_PADDING as H, FACET_TITLE_OFFSET as ht, FACET_AXIS_OFFSET as P, TITLE_LINE as j } from "./constants.js";
|
|
21
|
+
import { createAesGetter as Y } from "./utils/createAesGetter.js";
|
|
22
|
+
import { getTicksAndFormat as lt } from "./utils/getTicksAndFormat.js";
|
|
23
|
+
import L from "../node_modules/d3-scale/src/linear.js";
|
|
23
24
|
import U from "../node_modules/d3-scale/src/log.js";
|
|
24
|
-
import
|
|
25
|
-
import
|
|
26
|
-
import { sqrt as
|
|
27
|
-
var
|
|
28
|
-
function
|
|
29
|
-
const
|
|
30
|
-
return
|
|
25
|
+
import ct from "../node_modules/d3-scale/src/ordinal.js";
|
|
26
|
+
import mt from "../node_modules/d3-scale/src/symlog.js";
|
|
27
|
+
import { sqrt as dt } from "../node_modules/d3-scale/src/pow.js";
|
|
28
|
+
var ut = Object.defineProperty, pt = (h, t, e) => t in h ? ut(h, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : h[t] = e, E = (h, t, e) => pt(h, typeof t != "symbol" ? t + "" : t, e);
|
|
29
|
+
function gt(h, t, e, s) {
|
|
30
|
+
const i = [];
|
|
31
|
+
return h % e === e - 1 && i.push("right"), h % e === 0 && i.push("left"), h < e && i.push("top"), (Math.ceil((h + 1) / e) === s || Math.ceil((h + 1) / e) === s - 1 && h % e > (t - 1) % e) && i.push("bottom"), i;
|
|
31
32
|
}
|
|
32
|
-
function
|
|
33
|
-
const
|
|
33
|
+
function ft(h, t, e, s, i, a, m) {
|
|
34
|
+
const g = a.includes("left") || !(m != null && m.sharedY), M = a.includes("left") && t.title !== "", F = a.includes("bottom") || !(m != null && m.sharedX), N = a.includes("bottom") && h.title !== "", n = e.yAxisCaptionsWidth + 2 * G, o = (t.showTicks ? k : 0) + G, d = M ? j + H : 0, T = e.xAxisCaptionsWidth + 2 * G, z = h.showTicks ? k : 0, c = N ? j + H : 0, l = n + o + d + P, f = T + z + c + P, C = Math.max(...s.map((u) => i[u].length));
|
|
34
35
|
return {
|
|
35
|
-
left:
|
|
36
|
-
top:
|
|
36
|
+
left: g ? l : H,
|
|
37
|
+
top: C === 0 ? 0 : ht * 2 + C * et,
|
|
37
38
|
bottom: F ? f + 8 : H,
|
|
38
39
|
right: H
|
|
39
40
|
};
|
|
40
41
|
}
|
|
41
|
-
function
|
|
42
|
-
const
|
|
43
|
-
for (let
|
|
44
|
-
|
|
45
|
-
return
|
|
42
|
+
function St(h, t, e) {
|
|
43
|
+
const s = [];
|
|
44
|
+
for (let i = 0; i < t; i++)
|
|
45
|
+
s.push(h.slice(i * e, i * e + e));
|
|
46
|
+
return s;
|
|
46
47
|
}
|
|
47
|
-
function
|
|
48
|
-
const e = Math.floor(
|
|
49
|
-
return [e,
|
|
48
|
+
function Tt(h, t) {
|
|
49
|
+
const e = Math.floor(h / t), s = h - e * t;
|
|
50
|
+
return [e, s];
|
|
50
51
|
}
|
|
51
|
-
function xt(
|
|
52
|
-
const i =
|
|
52
|
+
function xt(h, t, e, s) {
|
|
53
|
+
const i = e.find((m) => m.type === "dots"), a = e.find((m) => m.type === "curve");
|
|
53
54
|
return {
|
|
54
|
-
dotShape: Y(
|
|
55
|
-
dotColor: Y(
|
|
56
|
-
dotSize: Y(
|
|
57
|
-
lineShape: Y(
|
|
58
|
-
lineColor: Y(
|
|
59
|
-
trendColor: Y(
|
|
55
|
+
dotShape: Y(h, t, (i == null ? void 0 : i.aes.dotShape) ?? W.shape, "dotShape"),
|
|
56
|
+
dotColor: Y(h, t, (i == null ? void 0 : i.aes.dotFill) ?? W.color, "dotFill"),
|
|
57
|
+
dotSize: Y(h, t, (i == null ? void 0 : i.aes.dotSize) ?? W.size, "dotSize"),
|
|
58
|
+
lineShape: Y(h, t, (a == null ? void 0 : a.aes.lineShape) ?? "solid", "lineShape"),
|
|
59
|
+
lineColor: Y(h, t, (a == null ? void 0 : a.aes.lineColor) ?? B, "lineColor"),
|
|
60
|
+
trendColor: Y(h, t, (s == null ? void 0 : s.color) ?? W.color, "fillColor")
|
|
60
61
|
};
|
|
61
62
|
}
|
|
62
|
-
class
|
|
63
|
+
class Ut {
|
|
63
64
|
constructor() {
|
|
64
|
-
|
|
65
|
+
E(this, "reactRoot", null), E(this, "parentNode", null), E(this, "rootNode", null), E(this, "component", /* @__PURE__ */ b.jsx(b.Fragment, {})), E(this, "margins", {
|
|
65
66
|
top: D,
|
|
66
67
|
bottom: D,
|
|
67
68
|
left: D,
|
|
68
69
|
right: D
|
|
69
|
-
}),
|
|
70
|
+
}), E(this, "chartsDimensions", {}), E(this, "chartSizes", {
|
|
70
71
|
chartWidth: R,
|
|
71
72
|
// width of single chart
|
|
72
73
|
chartHeight: $,
|
|
@@ -79,13 +80,13 @@ class Pt {
|
|
|
79
80
|
// width of all charts in charts row, plus left axis, plus legend
|
|
80
81
|
totalHeight: $
|
|
81
82
|
// width of all charts in charts height, plus bottom axis, plus top title
|
|
82
|
-
}),
|
|
83
|
-
x: { null:
|
|
84
|
-
y: { null:
|
|
85
|
-
}),
|
|
83
|
+
}), E(this, "columnsCount", 1), E(this, "rowsCount", 1), E(this, "scales", {
|
|
84
|
+
x: { null: L().domain([0, 10]).range([0, R]) },
|
|
85
|
+
y: { null: L().domain([0, 10]).range([$, 0]) }
|
|
86
|
+
}), E(this, "captionsSizes", {
|
|
86
87
|
xAxisCaptionsWidth: 30,
|
|
87
88
|
yAxisCaptionsWidth: 100
|
|
88
|
-
}),
|
|
89
|
+
}), E(this, "facetTitles", {}), E(this, "mainTitle", []), E(this, "legend", { width: 0, height: 0, items: [] });
|
|
89
90
|
}
|
|
90
91
|
clear() {
|
|
91
92
|
var t;
|
|
@@ -95,125 +96,129 @@ class Pt {
|
|
|
95
96
|
});
|
|
96
97
|
}
|
|
97
98
|
init(t) {
|
|
98
|
-
this.parentNode === null && (this.parentNode = t, this.rootNode = document.createElement("div"), this.parentNode.appendChild(this.rootNode), this.reactRoot =
|
|
99
|
+
this.parentNode === null && (this.parentNode = t, this.rootNode = document.createElement("div"), this.parentNode.appendChild(this.rootNode), this.reactRoot = K(this.rootNode));
|
|
99
100
|
}
|
|
100
101
|
updateChartSizes(t) {
|
|
101
102
|
this.chartSizes.chartWidth = t.width, this.chartSizes.chartHeight = t.height;
|
|
102
103
|
}
|
|
103
|
-
updateChartDimensions(t, e,
|
|
104
|
-
const { chartWidth:
|
|
105
|
-
let
|
|
106
|
-
this.chartsDimensions = t.reduce((
|
|
107
|
-
const [T, z] =
|
|
108
|
-
i,
|
|
104
|
+
updateChartDimensions(t, e, s, i) {
|
|
105
|
+
const { chartWidth: a, chartHeight: m } = this.chartSizes;
|
|
106
|
+
let g = 0, M = 0;
|
|
107
|
+
this.chartsDimensions = t.reduce((n, o, d) => {
|
|
108
|
+
const [T, z] = Tt(d, this.columnsCount), c = gt(d, t.length, this.columnsCount, this.rowsCount), l = ft(
|
|
109
109
|
s,
|
|
110
|
+
i,
|
|
110
111
|
this.captionsSizes,
|
|
111
|
-
|
|
112
|
+
St(t, this.rowsCount, this.columnsCount)[T],
|
|
112
113
|
this.facetTitles,
|
|
113
|
-
|
|
114
|
+
c,
|
|
114
115
|
e
|
|
115
|
-
), f =
|
|
116
|
-
return
|
|
117
|
-
left:
|
|
118
|
-
top:
|
|
119
|
-
chartEdgeSides:
|
|
120
|
-
padding:
|
|
121
|
-
inner: { width:
|
|
122
|
-
outer: { width: f, height:
|
|
123
|
-
},
|
|
116
|
+
), f = a + l.left + l.right, C = m + l.top + l.bottom;
|
|
117
|
+
return n[o] = {
|
|
118
|
+
left: g,
|
|
119
|
+
top: M,
|
|
120
|
+
chartEdgeSides: c,
|
|
121
|
+
padding: l,
|
|
122
|
+
inner: { width: a, height: m },
|
|
123
|
+
outer: { width: f, height: C }
|
|
124
|
+
}, g += f, z === this.columnsCount - 1 && (g = 0, M += C), n;
|
|
124
125
|
}, {});
|
|
125
126
|
const F = Math.max(
|
|
126
|
-
...t.map((
|
|
127
|
+
...t.map((n) => this.chartsDimensions[n].outer.width + this.chartsDimensions[n].left)
|
|
127
128
|
), N = Math.max(
|
|
128
|
-
...t.map((
|
|
129
|
+
...t.map((n) => this.chartsDimensions[n].outer.height + this.chartsDimensions[n].top)
|
|
129
130
|
);
|
|
130
131
|
this.chartSizes.chartsWidth = F, this.chartSizes.chartsHeight = N;
|
|
131
132
|
}
|
|
132
|
-
updateViewport(t, e,
|
|
133
|
-
const
|
|
134
|
-
this.columnsCount = e.nRows ? Math.ceil(
|
|
135
|
-
let [N,
|
|
136
|
-
const T = t.reduce((
|
|
137
|
-
const
|
|
138
|
-
return N = Math.min(N,
|
|
139
|
-
}, {}), z = {},
|
|
140
|
-
let
|
|
141
|
-
t.forEach((
|
|
142
|
-
const
|
|
143
|
-
let
|
|
144
|
-
if (typeof
|
|
145
|
-
const
|
|
146
|
-
if (
|
|
147
|
-
const
|
|
148
|
-
|
|
133
|
+
updateViewport(t, e, s, i, a, m) {
|
|
134
|
+
const g = t.length, M = Math.min(e.nRows ?? g, g), F = Math.min(e.nCols ?? g, g);
|
|
135
|
+
this.columnsCount = e.nRows ? Math.ceil(g / M) : F, this.rowsCount = Math.ceil(g / this.columnsCount);
|
|
136
|
+
let [N, n] = [1 / 0, -1 / 0], [o, d] = [1 / 0, -1 / 0];
|
|
137
|
+
const T = t.reduce((u, r) => {
|
|
138
|
+
const w = a[r], { minX: p, minY: S, maxX: A, maxY: y } = w;
|
|
139
|
+
return N = Math.min(N, p), o = Math.min(o, S), n = Math.max(n, A), d = Math.max(d, y), u[r] = { minX: p, maxX: A, minY: S, maxY: y }, u;
|
|
140
|
+
}, {}), z = {}, c = {};
|
|
141
|
+
let l = !1, f = !1;
|
|
142
|
+
t.forEach((u) => {
|
|
143
|
+
const r = s.scale === "log" ? U() : L(), w = T[u];
|
|
144
|
+
let p = s.lowerValue ? Number(s.lowerValue) : e.sharedX ? N : w.minX, S = s.upperValue ? Number(s.upperValue) : e.sharedX ? n : w.maxX;
|
|
145
|
+
if (typeof s.symmetricRange < "u") {
|
|
146
|
+
const v = s.symmetricRange;
|
|
147
|
+
if (v >= p && v <= S) {
|
|
148
|
+
const x = Math.max(v - p, S - v);
|
|
149
|
+
p = v - x, S = v + x;
|
|
149
150
|
}
|
|
150
151
|
}
|
|
151
|
-
const A = [0, this.chartSizes.chartWidth],
|
|
152
|
-
|
|
153
|
-
const I = this.scales.x[
|
|
154
|
-
if (I
|
|
155
|
-
|
|
156
|
-
|
|
152
|
+
const A = [0, this.chartSizes.chartWidth], y = r.copy().domain([p, S]).range([X.LEFT, this.chartSizes.chartWidth - X.RIGHT]);
|
|
153
|
+
r.domain([y.invert(0), y.invert(this.chartSizes.chartWidth)]).range(A).nice();
|
|
154
|
+
const I = this.scales.x[u];
|
|
155
|
+
if (I === void 0)
|
|
156
|
+
l = !0;
|
|
157
|
+
else if (!l) {
|
|
158
|
+
const v = I.domain(), x = I.range();
|
|
159
|
+
(v[0] !== r.domain()[0] || v[1] !== r.domain()[1] || x[0] !== r.range()[0] || x[1] !== r.range()[1]) && (l = !0);
|
|
157
160
|
}
|
|
158
|
-
z[
|
|
161
|
+
z[u] = r;
|
|
159
162
|
});
|
|
160
|
-
const
|
|
161
|
-
const
|
|
162
|
-
return
|
|
163
|
-
(
|
|
164
|
-
const A = S.bounded ? S.xBounds : this.scales.x[
|
|
165
|
-
return
|
|
163
|
+
const C = t.reduce((u, r) => {
|
|
164
|
+
const w = m ? m[r] : [];
|
|
165
|
+
return u[r] = w.reduce(
|
|
166
|
+
(p, S) => {
|
|
167
|
+
const A = S.bounded ? S.xBounds : this.scales.x[r].domain(), y = S.getInterval(A[0]), I = S.getInterval(A[1]);
|
|
168
|
+
return p.minY = Math.min(p.minY, isNaN(y.left) ? p.minY : y.left, isNaN(I.left) ? p.minY : I.left), p.maxY = Math.max(p.maxY, isNaN(y.right) ? p.maxY : y.right, isNaN(I.right) ? p.maxY : I.right), p;
|
|
166
169
|
},
|
|
167
170
|
{ minY: 1 / 0, maxY: -1 / 0 }
|
|
168
|
-
),
|
|
171
|
+
), o = Math.min(o, u[r].minY), d = Math.max(d, u[r].maxY), u;
|
|
169
172
|
}, {});
|
|
170
|
-
t.forEach((
|
|
171
|
-
const
|
|
172
|
-
let S =
|
|
173
|
-
if (typeof
|
|
174
|
-
const
|
|
175
|
-
if (
|
|
176
|
-
const
|
|
177
|
-
S =
|
|
173
|
+
t.forEach((u) => {
|
|
174
|
+
const r = i.scale === "log" ? U() : L(), w = T[u], p = C[u];
|
|
175
|
+
let S = i.lowerValue ? Number(i.lowerValue) : e.sharedY ? o : Math.min(w.minY, p.minY), A = i.upperValue ? Number(i.upperValue) : e.sharedY ? d : Math.max(w.maxY, p.maxY);
|
|
176
|
+
if (typeof i.symmetricRange < "u") {
|
|
177
|
+
const x = i.symmetricRange;
|
|
178
|
+
if (x >= S && x <= A) {
|
|
179
|
+
const _ = Math.max(x - S, A - x);
|
|
180
|
+
S = x - _, A = x + _;
|
|
178
181
|
}
|
|
179
182
|
}
|
|
180
|
-
const
|
|
181
|
-
|
|
182
|
-
const
|
|
183
|
-
if (
|
|
184
|
-
|
|
185
|
-
|
|
183
|
+
const y = [this.chartSizes.chartHeight, 0], I = r.copy().domain([S, A]).range([this.chartSizes.chartHeight - X.BOTTOM, X.TOP]);
|
|
184
|
+
r.domain([I.invert(this.chartSizes.chartHeight), I.invert(0)]).range(y).nice();
|
|
185
|
+
const v = this.scales.y[u];
|
|
186
|
+
if (v === void 0)
|
|
187
|
+
f = !0;
|
|
188
|
+
else if (!f) {
|
|
189
|
+
const x = v.domain(), _ = v.range();
|
|
190
|
+
(x[0] !== r.domain()[0] || x[1] !== r.domain()[1] || _[0] !== r.range()[0] || _[1] !== r.range()[1]) && (f = !0);
|
|
186
191
|
}
|
|
187
|
-
|
|
188
|
-
}),
|
|
192
|
+
c[u] = r;
|
|
193
|
+
}), l && (this.scales.x = z), f && (this.scales.y = c);
|
|
189
194
|
}
|
|
190
195
|
updateCaptionsSize(t) {
|
|
191
196
|
const e = new ot("600 14px Arial");
|
|
192
|
-
let
|
|
193
|
-
function
|
|
194
|
-
return Math.max(...
|
|
197
|
+
let s = 0;
|
|
198
|
+
function i(a) {
|
|
199
|
+
return Math.max(...a.map((m) => e.getTextWidth(m)));
|
|
195
200
|
}
|
|
196
|
-
Object.values(this.scales.y).forEach((
|
|
197
|
-
const { ticks:
|
|
198
|
-
|
|
201
|
+
Object.values(this.scales.y).forEach((a) => {
|
|
202
|
+
const { ticks: m, format: g } = lt(a, t);
|
|
203
|
+
s = Math.max(s, i(m.map(g)));
|
|
199
204
|
}), this.captionsSizes = {
|
|
200
205
|
xAxisCaptionsWidth: 20,
|
|
201
|
-
yAxisCaptionsWidth:
|
|
206
|
+
yAxisCaptionsWidth: s
|
|
202
207
|
};
|
|
203
208
|
}
|
|
204
209
|
createMainTitle(t, e) {
|
|
205
|
-
const
|
|
210
|
+
const s = this.chartsDimensions[t[0]], i = this.chartsDimensions[t[t.length - 1]];
|
|
206
211
|
this.mainTitle = O(
|
|
207
212
|
e.name,
|
|
208
|
-
this.chartSizes.chartsWidth -
|
|
213
|
+
this.chartSizes.chartsWidth - s.padding.left - i.padding.right,
|
|
209
214
|
20
|
|
210
215
|
);
|
|
211
216
|
}
|
|
212
217
|
createFacetTitles(t, e) {
|
|
213
|
-
this.facetTitles = t.reduce((
|
|
218
|
+
this.facetTitles = t.reduce((s, i, a) => (e[a].length === 1 && e[a][0] === "null" ? s[i] = [] : s[i] = O(e[a].join(", "), this.chartSizes.chartWidth, 14), s), {});
|
|
214
219
|
}
|
|
215
220
|
updateMargins() {
|
|
216
|
-
const t =
|
|
221
|
+
const t = J * this.mainTitle.length, e = t > 0 ? t + tt * 2 : 0;
|
|
217
222
|
this.margins = {
|
|
218
223
|
top: Math.max(e, D),
|
|
219
224
|
bottom: D,
|
|
@@ -221,86 +226,85 @@ class Pt {
|
|
|
221
226
|
right: this.legend.width + D
|
|
222
227
|
}, this.chartSizes.totalWidth = this.margins.left + this.chartSizes.chartsWidth + this.margins.right, this.chartSizes.totalHeight = this.margins.top + Math.max(this.chartSizes.chartsHeight, this.legend.height) + this.margins.bottom;
|
|
223
228
|
}
|
|
224
|
-
updateLegendSize(t, e,
|
|
229
|
+
updateLegendSize(t, e, s, i) {
|
|
225
230
|
if (!t.show) {
|
|
226
231
|
this.legend = { width: 0, height: 0, items: [] };
|
|
227
232
|
return;
|
|
228
233
|
}
|
|
229
|
-
const
|
|
230
|
-
if (
|
|
231
|
-
const
|
|
232
|
-
if (
|
|
234
|
+
const a = [], m = { width: 0, height: 0, left: 0, top: 0 };
|
|
235
|
+
if (s.forEach((n) => {
|
|
236
|
+
const o = e[n.value];
|
|
237
|
+
if (o.usedAes.length === 0 || !o.aesMap)
|
|
233
238
|
return;
|
|
234
|
-
if (
|
|
235
|
-
console.warn(`Too many values for discrete legend (${
|
|
239
|
+
if (o.values.length > Q) {
|
|
240
|
+
console.warn(`Too many values for discrete legend (${o.values.length})`);
|
|
236
241
|
return;
|
|
237
242
|
}
|
|
238
243
|
const d = {};
|
|
239
|
-
|
|
240
|
-
d[
|
|
241
|
-
|
|
242
|
-
(c === "dotFill" || c === "lineColor") && (d[l].color = ((f = a.aesMap[l]) == null ? void 0 : f[c]) ?? B), c === "dotShape" && (d[l].shape = ((x = a.aesMap[l]) == null ? void 0 : x[c]) ?? "21"), c === "dotSize" && (d[l].size = ((m = a.aesMap[l]) == null ? void 0 : m[c]) ?? 3);
|
|
244
|
+
o.values.forEach((c) => {
|
|
245
|
+
d[c] || (d[c] = { ...W }), o.usedAes.forEach((l) => {
|
|
246
|
+
(l === "dotFill" || l === "lineColor") && (d[c].color = o.aesMap(c, l) ?? B), l === "dotShape" && (d[c].shape = o.aesMap(c, l) ?? "21"), l === "dotSize" && (d[c].size = o.aesMap(c, l) ?? 3);
|
|
243
247
|
});
|
|
244
248
|
});
|
|
245
|
-
const T =
|
|
246
|
-
|
|
247
|
-
}),
|
|
248
|
-
if (
|
|
249
|
-
const { domain:
|
|
250
|
-
|
|
249
|
+
const T = n.label ?? n.value, z = ct().domain(o.values).range(o.values.map((c) => d[c])).unknown(W);
|
|
250
|
+
a.push({ ...m, id: n.value, type: "dots", title: T, scale: z, values: o.values, labels: o.labels });
|
|
251
|
+
}), i.forEach((n) => {
|
|
252
|
+
if (n.type === "dots" && V(n.aes.dotFill)) {
|
|
253
|
+
const { domain: o, range: d, columnName: T, type: z = "linear" } = n.aes.dotFill, c = T.label ?? T.value, l = st(d, o, "linear"), f = (z === "log" ? mt() : L()).domain(o).range([this.chartSizes.chartHeight, 0]), C = at(f, o);
|
|
254
|
+
a.push({ ...m, id: "dotFill", type: "continuous", title: c, scale: l, tickPositionScale: f, values: C });
|
|
251
255
|
}
|
|
252
|
-
if (
|
|
253
|
-
const { columnName:
|
|
254
|
-
|
|
256
|
+
if (n.type === "dots" && V(n.aes.dotSize)) {
|
|
257
|
+
const { columnName: o, domain: d, range: T } = n.aes.dotSize, z = o.label ?? o.value, c = dt(d, T), l = c.ticks(3), f = c.tickFormat(3), C = l.reduce((u, r) => (u[String(r)] = f(r), u), {});
|
|
258
|
+
a.push({ ...m, id: o.value, type: "size", title: z, scale: c, values: l, labels: C });
|
|
255
259
|
}
|
|
256
|
-
}), !
|
|
260
|
+
}), !a.length) {
|
|
257
261
|
this.legend = { width: 0, height: 0, items: [] };
|
|
258
262
|
return;
|
|
259
263
|
}
|
|
260
|
-
const
|
|
264
|
+
const g = it(a, this.chartSizes.chartHeight), M = g[g.length - 1], F = M.left + M.width + rt, N = this.chartSizes.chartHeight;
|
|
261
265
|
this.legend = {
|
|
262
266
|
width: F,
|
|
263
267
|
height: N,
|
|
264
|
-
items:
|
|
268
|
+
items: g
|
|
265
269
|
};
|
|
266
270
|
}
|
|
267
|
-
render(t, e,
|
|
271
|
+
render(t, e, s, i, a, m, g, M, F, N, n, o, d, T, z, c) {
|
|
268
272
|
var l;
|
|
269
|
-
const { xAxis:
|
|
270
|
-
this.updateChartSizes(
|
|
271
|
-
const
|
|
272
|
-
|
|
273
|
+
const { xAxis: f, yAxis: C, size: u, title: r, legend: w } = s;
|
|
274
|
+
this.updateChartSizes(u), this.updateViewport(a, i, f, C, g, M), this.updateCaptionsSize(N.y), this.createFacetTitles(a, m), this.updateChartDimensions(a, i, f, C), this.updateLegendSize(w, n, d, T), this.createMainTitle(a, r), this.updateMargins();
|
|
275
|
+
const p = /* @__PURE__ */ b.jsx(q, { dataFrame: t, children: /* @__PURE__ */ b.jsx(
|
|
276
|
+
nt,
|
|
273
277
|
{
|
|
274
|
-
settingsId:
|
|
275
|
-
chartSettings:
|
|
276
|
-
facetKeys:
|
|
278
|
+
settingsId: e,
|
|
279
|
+
chartSettings: s,
|
|
280
|
+
facetKeys: a,
|
|
277
281
|
facetSettings: i,
|
|
278
282
|
chartSizes: this.chartSizes,
|
|
279
283
|
chartsDimensions: this.chartsDimensions,
|
|
280
284
|
scales: this.scales,
|
|
281
|
-
groupedDots:
|
|
282
|
-
trendsData:
|
|
285
|
+
groupedDots: g,
|
|
286
|
+
trendsData: M,
|
|
283
287
|
legendData: this.legend,
|
|
284
288
|
columnsCount: this.columnsCount,
|
|
285
289
|
margins: this.margins,
|
|
286
|
-
keyColumn:
|
|
290
|
+
keyColumn: F,
|
|
287
291
|
mainTitle: this.mainTitle,
|
|
288
292
|
facetTitles: this.facetTitles,
|
|
289
293
|
captionsSizes: this.captionsSizes,
|
|
290
|
-
onlyPositive:
|
|
291
|
-
layersData:
|
|
292
|
-
aesGetters: xt(
|
|
293
|
-
onTooltipHintSwitch:
|
|
294
|
+
onlyPositive: N,
|
|
295
|
+
layersData: o,
|
|
296
|
+
aesGetters: xt(t, n, T, z),
|
|
297
|
+
onTooltipHintSwitch: c
|
|
294
298
|
}
|
|
295
|
-
);
|
|
296
|
-
this.component =
|
|
299
|
+
) });
|
|
300
|
+
this.component = p, (l = this.reactRoot) == null || l.render(p);
|
|
297
301
|
}
|
|
298
302
|
renderError(t) {
|
|
299
303
|
var e;
|
|
300
|
-
(e = this.reactRoot) == null || e.render(/* @__PURE__ */
|
|
304
|
+
(e = this.reactRoot) == null || e.render(/* @__PURE__ */ b.jsx(Z, { message: t }));
|
|
301
305
|
}
|
|
302
306
|
}
|
|
303
307
|
export {
|
|
304
|
-
|
|
308
|
+
Ut as default
|
|
305
309
|
};
|
|
306
310
|
//# sourceMappingURL=ChartRenderer.js.map
|