@milaboratories/graph-maker 1.1.141 → 1.1.143
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/LassoControls/index.vue.js +1 -1
- package/dist/GraphMaker/components/ReorderForm.vue.d.ts +15 -0
- package/dist/GraphMaker/components/ReorderForm.vue.d.ts.map +1 -0
- package/dist/GraphMaker/components/ReorderForm.vue.js +43 -0
- package/dist/GraphMaker/components/ReorderForm.vue.js.map +1 -0
- package/dist/GraphMaker/components/ReorderForm.vue2.js +5 -0
- package/dist/GraphMaker/components/ReorderForm.vue2.js.map +1 -0
- package/dist/GraphMaker/constantsCommon.d.ts +23 -0
- package/dist/GraphMaker/constantsCommon.d.ts.map +1 -1
- package/dist/GraphMaker/constantsCommon.js +97 -83
- package/dist/GraphMaker/constantsCommon.js.map +1 -1
- package/dist/GraphMaker/forms/AxesSettingsForm/DiscreteAxesSettingsForm.vue.js.map +1 -1
- package/dist/GraphMaker/forms/AxesSettingsForm/ScatterplotAxesSettingsForm.vue.d.ts.map +1 -1
- package/dist/GraphMaker/forms/AxesSettingsForm/ScatterplotAxesSettingsForm.vue.js +305 -172
- package/dist/GraphMaker/forms/AxesSettingsForm/ScatterplotAxesSettingsForm.vue.js.map +1 -1
- package/dist/GraphMaker/forms/LayersForm/Layer/discrete/StackedArea.vue.d.ts +3 -0
- package/dist/GraphMaker/forms/LayersForm/Layer/discrete/StackedArea.vue.d.ts.map +1 -0
- package/dist/GraphMaker/forms/LayersForm/Layer/discrete/StackedArea.vue.js +90 -0
- package/dist/GraphMaker/forms/LayersForm/Layer/discrete/StackedArea.vue.js.map +1 -0
- package/dist/GraphMaker/forms/LayersForm/Layer/discrete/StackedArea.vue2.js +5 -0
- package/dist/GraphMaker/forms/LayersForm/Layer/discrete/StackedArea.vue2.js.map +1 -0
- package/dist/GraphMaker/forms/LayersForm/index.vue.d.ts.map +1 -1
- package/dist/GraphMaker/forms/LayersForm/index.vue.js +45 -43
- package/dist/GraphMaker/forms/LayersForm/index.vue.js.map +1 -1
- package/dist/GraphMaker/index.vue.d.ts.map +1 -1
- package/dist/GraphMaker/index.vue.js +33 -34
- 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 +3 -3
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeBubbleSettings.d.ts.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeDendroSettings.d.ts +9 -9
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeDendroSettings.d.ts.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeDiscreteSettings.d.ts +21 -11
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeDiscreteSettings.d.ts.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeHeatmapSettings.d.ts +3 -3
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeHeatmapSettings.d.ts.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeHistogramSettings.d.ts +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotSettings.d.ts +31 -5
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotSettings.d.ts.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotSettings.js +56 -53
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotSettings.js.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotUmapSettings.d.ts +1 -7
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotUmapSettings.d.ts.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotUmapSettings.js +13 -13
- package/dist/GraphMaker/utils/createChartSettingsForRender/composeScatterplotUmapSettings.js.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/getAxesDataFromForms.d.ts +6 -4
- package/dist/GraphMaker/utils/createChartSettingsForRender/getAxesDataFromForms.d.ts.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/getAxesDataFromForms.js +42 -13
- package/dist/GraphMaker/utils/createChartSettingsForRender/getAxesDataFromForms.js.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/getLayersDataFromForms.d.ts.map +1 -1
- package/dist/GraphMaker/utils/createChartSettingsForRender/getLayersDataFromForms.js +84 -70
- package/dist/GraphMaker/utils/createChartSettingsForRender/getLayersDataFromForms.js.map +1 -1
- package/dist/GraphMaker/utils/loadUniqueValuesToSave.d.ts.map +1 -1
- package/dist/GraphMaker/utils/loadUniqueValuesToSave.js +48 -44
- package/dist/GraphMaker/utils/loadUniqueValuesToSave.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/MiPlots.js +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/{discrete/components → common}/BandAxis.js +3 -3
- package/dist/node_modules/@milaboratories/miplots4/dist/common/BandAxis.js.map +1 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/common/ContinuousGrid.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/dendro/ChartRenderer.js +14 -14
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/ChartRenderer.js +197 -270
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/ChartRenderer.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/DiscreteSettingsImpl.js +182 -161
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/DiscreteSettingsImpl.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/components/Chart.js +121 -104
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/components/Chart.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/components/ChartsGroup.js +4 -4
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/components/Grid.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/components/layers/StackedAreaElement.js +105 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/components/layers/StackedAreaElement.js.map +1 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/components/layers/StackedBarElement.js +66 -59
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/components/layers/StackedBarElement.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/index.js +61 -58
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/index.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/stackedArea.js +17 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/layers/stackedArea.js.map +1 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/histogram/ChartRenderer.js +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-scale/src/band.js +44 -34
- package/dist/node_modules/@milaboratories/miplots4/dist/node_modules/d3-scale/src/band.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/ChartRenderer.js +272 -195
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/ChartRenderer.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/ScatterplotSettingsImpl.js +23 -23
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/ScatterplotSettingsImpl.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/Chart.js +54 -50
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/Chart.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartAxis.js +32 -28
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartAxis.js.map +1 -1
- 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.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartTrendsData.js +29 -26
- 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 +44 -41
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/ChartsGroup.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/Grid.js +31 -27
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/Grid.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/dots.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/getLayersData.js +29 -18
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/getLayersData.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/index.js +71 -57
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/index.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/linearRegression.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/isNumericScale.js +11 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/utils/isNumericScale.js.map +1 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/ChartRenderer.js +10 -10
- 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.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/components/LowerSVG.js +6 -6
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot-umap/components/LowerSVG.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/types/common.js +35 -25
- package/dist/node_modules/@milaboratories/miplots4/dist/types/common.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/types/dendro.js +3 -3
- package/dist/node_modules/@milaboratories/miplots4/dist/types/discrete.js +51 -36
- package/dist/node_modules/@milaboratories/miplots4/dist/types/discrete.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/types/heatmap.js +6 -6
- package/dist/node_modules/@milaboratories/miplots4/dist/types/scatterplot-umap.js +7 -7
- package/dist/node_modules/@milaboratories/miplots4/dist/types/scatterplot-umap.js.map +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/utils/createMultilineDiscreteLabels.js +32 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/utils/createMultilineDiscreteLabels.js.map +1 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/utils/getFacetRowsColumns.js +18 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/utils/getFacetRowsColumns.js.map +1 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/utils/measureMultilineDiscreteLabels.js +63 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/utils/measureMultilineDiscreteLabels.js.map +1 -0
- package/dist/node_modules/@milaboratories/miplots4/dist/{discrete/utils → utils}/splitTextByWidth.js +1 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/utils/splitTextByWidth.js.map +1 -0
- package/dist/node_modules/@milaboratories/pf-plots/dist/controllers/controllersByChartType/scatterplot.js +2 -2
- package/dist/node_modules/@milaboratories/pf-plots/dist/controllers/controllersByChartType/scatterplot.js.map +1 -1
- package/package.json +3 -3
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/components/BandAxis.js.map +0 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/discrete/utils/splitTextByWidth.js.map +0 -1
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/Axis.js +0 -59
- package/dist/node_modules/@milaboratories/miplots4/dist/scatterplot/components/Axis.js.map +0 -1
package/dist/node_modules/@milaboratories/miplots4/dist/discrete/DiscreteSettingsImpl.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DiscreteSettingsImpl.js","sources":["../../../../../../node_modules/@milaboratories/miplots4/src/discrete/DiscreteSettingsImpl.ts"],"sourcesContent":["import { BLACK, DEFAULT_HEIGHT, DEFAULT_HEIGHT_SMALL, DEFAULT_WIDTH, DEFAULT_WIDTH_SMALL } from '../constants';\nimport type {\n AesRecord,\n Color,\n ColumnName,\n DataValue,\n DiscreteSettings,\n FrameType,\n InheritAesDiscrete,\n LegendPosition,\n LineShape,\n Orientation,\n BarLayer as OuterBarLayer,\n BinnedDotsLayer as OuterBinnedDotsLayer,\n BoxLayer as OuterBoxLayer,\n DotLayer as OuterDotLayer,\n ErrorBarLayer as OuterErrorBarLayer,\n LineLayer as OuterLineLayer,\n LogoPlotLayer as OuterLogoPlotLayer,\n PairedPointsLayer as OuterPairedPointsLayer,\n SinaLayer as OuterSinaLayer,\n StackedBarLayer as OuterStackedBarLayer,\n StatLayer as OuterStatLayer,\n ViolinLayer as OuterViolinLayer,\n PointShape,\n PValueCorrectionMethod,\n SettingsInterface,\n SignificanceLevels,\n StatTestMethod,\n SummaryErrorValue,\n SummaryGroupValue,\n TitlePosition,\n} from '../types';\nimport { DiscreteSettingsSchema } from '../types';\nimport { MIN_MARGIN, PADDINGS } from './constants';\n\nimport lodash from 'lodash';\nimport { exhaustive } from '../utils';\n\nconst DEFAULT_FILL = '#3e9838';\nconst DEFAULT_DOT_SHAPE = '21';\nconst DEFAULT_DOT_SIZE = 3;\n\nabstract class BaseDiscreteLayer {\n abstract type: string;\n abstract isEqualForCalculation(otherLayer: DiscreteLayer): boolean;\n}\n\nexport class BoxLayer extends BaseDiscreteLayer {\n readonly type = 'box';\n readonly stat: {\n upper: number;\n medium: number;\n lower: number;\n k: number;\n } = {\n upper: 0.75,\n medium: 0.5,\n lower: 0.25,\n k: 1.5,\n };\n readonly aes: {\n showOutliers: boolean;\n boxWidth: 'auto' | number;\n dotShape: InheritAesDiscrete | PointShape;\n dotSize: InheritAesDiscrete | number;\n dotFill: InheritAesDiscrete | string;\n lineColor: InheritAesDiscrete | string;\n fillColor: InheritAesDiscrete | string;\n lineWidth: number;\n lineShape: LineShape;\n opacity: number;\n } = {\n showOutliers: true,\n boxWidth: 'auto',\n dotShape: DEFAULT_DOT_SHAPE,\n dotFill: BLACK,\n dotSize: DEFAULT_DOT_SIZE,\n lineColor: BLACK,\n fillColor: DEFAULT_FILL,\n lineWidth: 1,\n lineShape: 'solid',\n opacity: 1,\n };\n\n constructor(layer: OuterBoxLayer) {\n super();\n this.stat = {\n ...this.stat,\n ...layer.stat,\n };\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return (\n otherLayer.type === 'box' &&\n (Object.keys(this.stat) as (keyof BoxLayer['stat'])[]).every(key => this.stat[key] === otherLayer.stat[key])\n );\n }\n}\n\nexport class ViolinLayer extends BaseDiscreteLayer {\n readonly type = 'violin';\n readonly stat: {\n bandwidth: 'auto' | number;\n stepsCount: 'auto' | number;\n trim: boolean;\n } = {\n bandwidth: 'auto',\n stepsCount: 40,\n trim: true,\n };\n readonly aes: {\n width: 'auto' | number;\n lineColor: InheritAesDiscrete | string;\n fillColor: InheritAesDiscrete | string;\n lineWidth: number;\n lineShape: LineShape;\n opacity: number;\n showQuartiles: boolean;\n medianLineStyle: LineShape;\n quartilesLineStyle: LineShape;\n } = {\n width: 'auto',\n lineColor: BLACK,\n fillColor: DEFAULT_FILL,\n lineWidth: 1,\n lineShape: 'solid',\n opacity: 1,\n showQuartiles: true,\n medianLineStyle: 'solid',\n quartilesLineStyle: 'dashed'\n };\n\n constructor(layer: OuterViolinLayer) {\n super();\n this.stat = {\n ...this.stat,\n ...layer.stat,\n };\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return (\n otherLayer.type === 'violin' && (\n this.stat.bandwidth !== otherLayer.stat.bandwidth ||\n this.stat.trim !== otherLayer.stat.trim ||\n this.stat.stepsCount !== otherLayer.stat.stepsCount\n )\n );\n }\n}\n\nexport class DotLayer extends BaseDiscreteLayer {\n readonly type = 'dot';\n readonly aes: {\n showOutliers: boolean;\n jitter: number;\n dotFill: InheritAesDiscrete | string;\n lineColor: InheritAesDiscrete | string;\n dotShape: InheritAesDiscrete | PointShape;\n dotSize: number;\n opacity: number;\n } = {\n showOutliers: true,\n jitter: 0.8,\n lineColor: 'none',\n dotFill: BLACK,\n dotShape: DEFAULT_DOT_SHAPE,\n dotSize: DEFAULT_DOT_SIZE,\n opacity: 1,\n };\n\n constructor(layer: OuterDotLayer) {\n super();\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return otherLayer.type === 'dot' && this.aes.showOutliers === otherLayer.aes.showOutliers;\n }\n}\n\nexport class LineLayer extends BaseDiscreteLayer {\n readonly type = 'line';\n readonly pointsValues: SummaryGroupValue;\n readonly aes: {\n showOutliers: boolean;\n lineWidth: number;\n lineColor: InheritAesDiscrete | string;\n fillColor: InheritAesDiscrete | string;\n lineShape: InheritAesDiscrete | LineShape;\n dotShape: InheritAesDiscrete | PointShape;\n dotSize: number;\n opacity: number;\n } = {\n showOutliers: true,\n lineWidth: 1,\n lineShape: 'solid',\n fillColor: 'none',\n lineColor: BLACK,\n dotShape: DEFAULT_DOT_SHAPE,\n dotSize: DEFAULT_DOT_SIZE,\n opacity: 1,\n };\n\n constructor(layer: OuterLineLayer) {\n super();\n this.pointsValues = layer.pointsValues;\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return otherLayer.type === 'line' && this.pointsValues === otherLayer.pointsValues;\n }\n}\n\nexport class ErrorBarLayer extends BaseDiscreteLayer {\n readonly type = 'errorbar';\n readonly pointsValues: SummaryGroupValue;\n readonly interval: SummaryErrorValue;\n readonly aes: {\n showDots: boolean;\n width: number | 'auto';\n lineWidth: number;\n lineColor: InheritAesDiscrete | string;\n fillColor: InheritAesDiscrete | string;\n dotShape: InheritAesDiscrete | PointShape;\n dotSize: number;\n opacity: number;\n } = {\n showDots: true,\n width: 'auto',\n lineWidth: 1,\n fillColor: 'none',\n lineColor: BLACK,\n dotShape: DEFAULT_DOT_SHAPE,\n dotSize: DEFAULT_DOT_SIZE,\n opacity: 1,\n };\n\n constructor(layer: OuterErrorBarLayer) {\n super();\n this.pointsValues = layer.pointsValues;\n this.interval = layer.interval;\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return (\n otherLayer.type === 'errorbar' &&\n this.pointsValues === otherLayer.pointsValues &&\n this.interval === otherLayer.interval\n );\n }\n}\n\nexport class BarLayer extends BaseDiscreteLayer {\n readonly type = 'bar';\n readonly height: 'min' | 'max' | 'median' | 'mean';\n readonly aes: {\n width: number | 'auto';\n lineColor: InheritAesDiscrete | Color;\n fillColor: InheritAesDiscrete | Color;\n lineWidth: number;\n opacity: number;\n } = {\n width: 'auto',\n lineWidth: 1,\n fillColor: 'none',\n lineColor: BLACK,\n opacity: 1,\n };\n\n constructor(layer: OuterBarLayer) {\n super();\n this.height = layer.height ?? 'max';\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return otherLayer.type === 'bar' && this.height === otherLayer.height;\n }\n}\n\nexport class StackedBarLayer extends BaseDiscreteLayer {\n readonly type = 'stackedBar';\n readonly normalize: boolean = false;\n readonly aes: {\n width: number | 'auto';\n lineColor: InheritAesDiscrete | Color;\n fillColor: InheritAesDiscrete | Color;\n lineWidth: number;\n opacity: number;\n } = {\n width: 'auto',\n lineWidth: 1,\n fillColor: DEFAULT_FILL,\n lineColor: 'none',\n opacity: 1,\n };\n\n constructor(layer: OuterStackedBarLayer) {\n super();\n this.normalize = layer.normalize ?? false;\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return otherLayer.type === 'stackedBar' && otherLayer.normalize === this.normalize;\n }\n}\n\nexport class LogoPlotLayer extends BaseDiscreteLayer {\n readonly type = 'logo';\n readonly normalize: boolean = false;\n readonly aes: {\n width: number | 'auto';\n fillColor: Record<string, string> | Color;\n lineColor: Color;\n opacity: number;\n } = {\n width: 'auto',\n fillColor: DEFAULT_FILL,\n lineColor: 'none',\n opacity: 1,\n };\n\n constructor(layer: OuterLogoPlotLayer) {\n super();\n this.normalize = layer.normalize ?? false;\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return otherLayer.type === 'logo' && otherLayer.normalize === this.normalize;\n }\n}\n\nexport class BinnedDotsLayer extends BaseDiscreteLayer {\n readonly type = 'binnedDots';\n readonly method: 'dotdensity' | 'histodot';\n readonly position: 'stack' | 'jitter';\n readonly keyColumn: ColumnName | null;\n readonly aes: {\n showOutliers: boolean;\n width: number | 'auto';\n lineColor: InheritAesDiscrete | Color;\n fillColor: InheritAesDiscrete | Color;\n dotSize?: number;\n lineWidth: number;\n opacity: number;\n } = {\n showOutliers: true,\n width: 'auto',\n lineWidth: 1,\n fillColor: 'none',\n lineColor: BLACK,\n opacity: 1,\n };\n\n constructor(layer: OuterBinnedDotsLayer) {\n super();\n this.method = layer.method ?? 'dotdensity';\n this.position = layer.position ?? 'stack';\n this.keyColumn = layer.keyColumn ?? null;\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return (\n otherLayer.type === 'binnedDots' &&\n this.method === otherLayer.method &&\n this.position === otherLayer.position &&\n this.keyColumn?.value === otherLayer.keyColumn?.value\n );\n }\n}\n\nexport class PairedPointsLayer extends BaseDiscreteLayer {\n readonly type = 'pairedPoints';\n readonly linkColumn: ColumnName;\n readonly aes: {\n showOutliers: boolean;\n lineColor: InheritAesDiscrete | Color;\n lineWidth: number;\n lineShape: LineShape;\n dotFill: InheritAesDiscrete | Color;\n dotSize: number;\n dotShape: PointShape;\n opacity: number;\n } = {\n showOutliers: true,\n lineWidth: 1,\n lineColor: BLACK,\n lineShape: 'solid',\n dotFill: BLACK,\n dotSize: DEFAULT_DOT_SIZE,\n dotShape: DEFAULT_DOT_SHAPE,\n opacity: 1,\n };\n\n constructor(layer: OuterPairedPointsLayer) {\n super();\n this.linkColumn = layer.linkColumn;\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return (\n otherLayer.type === 'pairedPoints' &&\n this.aes.showOutliers === otherLayer.aes.showOutliers &&\n this.linkColumn.value === otherLayer.linkColumn.value\n );\n }\n}\n\nexport class SinaLayer extends BaseDiscreteLayer {\n readonly type = 'sina';\n readonly aes: {\n showOutliers: boolean;\n width: number | 'auto';\n dotFill: InheritAesDiscrete | Color;\n dotSize: number;\n dotShape: InheritAesDiscrete | PointShape;\n opacity: number;\n } = {\n showOutliers: true,\n width: 'auto',\n dotFill: DEFAULT_FILL,\n dotSize: DEFAULT_DOT_SIZE,\n dotShape: DEFAULT_DOT_SHAPE,\n opacity: 1,\n };\n\n constructor(layer: OuterSinaLayer) {\n super();\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return otherLayer.type === 'sina' && this.aes.showOutliers === otherLayer.aes.showOutliers;\n }\n}\n\nexport class StatLayer extends BaseDiscreteLayer {\n readonly type = 'stat';\n readonly statType: 'overall' | 'referenceGroup' | 'pairwise';\n readonly testMethod: StatTestMethod;\n readonly paired: boolean;\n readonly ns: boolean;\n readonly format: 'significance' | 'pValue';\n readonly referenceGroup: DataValue | null = null;\n readonly correctionMethod: PValueCorrectionMethod | null = null;\n readonly significanceLevels: SignificanceLevels;\n\n constructor(layer: OuterStatLayer) {\n super();\n this.statType = layer.statType;\n this.testMethod = layer.testMethod;\n this.paired = layer.paired ?? false;\n this.ns = layer.ns ?? true;\n this.format = layer.format ?? 'pValue';\n if (this.statType === 'referenceGroup') {\n this.referenceGroup = layer.referenceGroup ?? null;\n }\n if (this.statType === 'referenceGroup' || this.statType === 'pairwise') {\n this.correctionMethod = layer.correctionMethod ?? null;\n }\n this.significanceLevels = {\n one: layer.significanceLevels?.one ?? 0.05,\n two: layer.significanceLevels?.two ?? 0.01,\n three: layer.significanceLevels?.three ?? 0.001,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return otherLayer.type === 'stat' && (Object.keys(this) as (keyof StatLayer)[]).every(key => this[key] === otherLayer[key]);\n }\n}\n\nexport type DiscreteLayer =\n | BoxLayer\n | ViolinLayer\n | DotLayer\n | LineLayer\n | ErrorBarLayer\n | BarLayer\n | StackedBarLayer\n | BinnedDotsLayer\n | PairedPointsLayer\n | SinaLayer\n | StatLayer\n | LogoPlotLayer;\n\nexport class DiscreteSettingsImpl implements SettingsInterface {\n readonly id: string;\n readonly type = 'discrete';\n readonly y: ColumnName;\n readonly keyColumn: ColumnName | null;\n readonly primaryGrouping: {\n columnName: ColumnName;\n order?: DataValue[];\n inheritedAes?: AesRecord;\n allowNullGroup?: boolean;\n } | null;\n readonly secondaryGrouping: {\n columnName: ColumnName;\n order?: DataValue[];\n inheritedAes?: AesRecord;\n allowNullGroup?: boolean;\n } | null;\n readonly facetSettings: {\n sharedX: boolean;\n sharedY: boolean;\n order?: Record<string, DataValue[]>; // map with ordered values of columns in \"facetBy\"\n nRows?: number;\n nCols?: number;\n titlePosition?: 'left' | 'right' | 'center';\n } | null;\n readonly facetBy: ColumnName[];\n readonly chartSettings: {\n readonly size: {width: number; height: number, outerOffset: number, innerOffset: number};\n readonly title: {name: string; show: boolean; position: TitlePosition};\n readonly orientation: Orientation;\n readonly yAxis: {\n title: string | ColumnName;\n scale: 'linear' | 'log';\n showGrid: boolean;\n showTicks: boolean;\n hiddenLabels: boolean;\n };\n readonly xAxis: {\n title: string | ColumnName;\n showGrid: boolean;\n linesBetweenCategories: boolean;\n showTicks: boolean;\n labelsPosition: 'center' | '45deg' | '90deg';\n hiddenLabels: boolean;\n };\n readonly frame: {type: FrameType};\n readonly legend: {show: boolean; position: LegendPosition};\n readonly tooltips: {\n box: {show: boolean};\n violin: {show: boolean};\n boxOutliers: {show: boolean};\n line: {show: boolean};\n dot: {show: boolean};\n errorBar: {show: boolean};\n binnedDots: {show: boolean};\n pairedPoints: {show: boolean};\n stackedBar: {show: boolean};\n logo: {show: boolean};\n };\n };\n\n readonly layers: DiscreteLayer[];\n\n constructor(settings: DiscreteSettings) {\n DiscreteSettingsSchema.parse(settings);\n this.id = lodash.uniqueId('settings');\n this.y = settings.y; // throw error if empty or if y.name doesn't exist in input table\n this.keyColumn = settings.keyColumn ?? null;\n this.primaryGrouping = settings.primaryGrouping ?? null; // check columnName\n this.secondaryGrouping = settings.secondaryGrouping ?? null; // check columnName\n this.facetSettings = {\n sharedX: true,\n sharedY: true,\n titlePosition: 'left',\n ...settings.facetSettings,\n };\n this.facetBy = settings.facetBy ?? [];\n this.chartSettings = {\n size: {\n width: settings?.size?.width ?? (this.facetBy.length ? DEFAULT_WIDTH_SMALL : DEFAULT_WIDTH),\n height: settings?.size?.height ?? (this.facetBy.length ? DEFAULT_HEIGHT_SMALL : DEFAULT_HEIGHT),\n outerOffset: settings?.size?.outerOffset ?? MIN_MARGIN,\n innerOffset: settings?.size?.innerOffset ?? PADDINGS.TOP\n },\n title: {\n position: 'center',\n show: true,\n ...settings.title,\n name: settings.title?.name ?? 'Chart',\n },\n orientation: settings.orientation ?? 'vertical',\n yAxis: {\n title: settings.y?.label ?? settings.y.value ?? '',\n scale: 'linear',\n showGrid: true,\n showTicks: true,\n hiddenLabels: false,\n ...settings.yAxis,\n },\n xAxis: {\n title: settings.primaryGrouping?.columnName?.label ?? settings.primaryGrouping?.columnName.value ?? '',\n showGrid: true,\n showTicks: true,\n linesBetweenCategories: true,\n labelsPosition: 'center',\n hiddenLabels: false,\n ...settings.xAxis,\n },\n frame: {type: settings.frame?.type ?? 'full'},\n legend: {\n show: true,\n position: 'right',\n ...settings.legend,\n },\n tooltips: {\n box: {show: true},\n violin: {show: true},\n boxOutliers: {show: true},\n line: {show: true},\n errorBar: {show: true},\n dot: {show: true},\n binnedDots: {show: true},\n pairedPoints: {show: true},\n stackedBar: {show: true},\n logo: {show: false},\n ...settings.tooltips,\n },\n };\n this.layers = settings.layers\n .map(layer => {\n if (layer.type === 'box') {\n return new BoxLayer(layer);\n }\n if (layer.type === 'violin') {\n return new ViolinLayer(layer);\n }\n if (layer.type === 'dot') {\n return new DotLayer(layer);\n }\n if (layer.type === 'line') {\n return new LineLayer(layer);\n }\n if (layer.type === 'errorbar') {\n return new ErrorBarLayer(layer);\n }\n if (layer.type === 'bar') {\n return new BarLayer(layer);\n }\n if (layer.type === 'stackedBar') {\n return new StackedBarLayer(layer);\n }\n if (layer.type === 'stat') {\n return new StatLayer(layer);\n }\n if (layer.type === 'binnedDots') {\n return new BinnedDotsLayer(layer);\n }\n if (layer.type === 'pairedPoints') {\n return new PairedPointsLayer(layer);\n }\n if (layer.type === 'sina') {\n return new SinaLayer(layer);\n }\n if (layer.type === 'logo') {\n return new LogoPlotLayer(layer);\n }\n exhaustive(layer, 'Unknown layer type');\n })\n .filter(Boolean) as DiscreteLayer[];\n }\n}\n"],"names":["DEFAULT_FILL","DEFAULT_DOT_SHAPE","DEFAULT_DOT_SIZE","BaseDiscreteLayer","BoxLayer","layer","__publicField","BLACK","otherLayer","key","ViolinLayer","DotLayer","LineLayer","ErrorBarLayer","BarLayer","StackedBarLayer","LogoPlotLayer","BinnedDotsLayer","_a","_b","PairedPointsLayer","SinaLayer","StatLayer","_c","DiscreteSettingsImpl","settings","DiscreteSettingsSchema","lodash","DEFAULT_WIDTH_SMALL","DEFAULT_WIDTH","DEFAULT_HEIGHT_SMALL","DEFAULT_HEIGHT","MIN_MARGIN","_d","PADDINGS","_e","_f","_h","_g","_i","_j","exhaustive"],"mappings":";;;;;;;;;;;;AAuCA,MAAMA,IAAe,WACfC,IAAoB,MAC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,IAAID,EAASC,CAAK;AAE7B,UAAIA,EAAM,SAAS;AACf,eAAO,IAAIK,EAAYL,CAAK;AAEhC,UAAIA,EAAM,SAAS;AACf,eAAO,IAAIM,EAASN,CAAK;AAE7B,UAAIA,EAAM,SAAS;AACf,eAAO,IAAIO,EAAUP,CAAK;AAE9B,UAAIA,EAAM,SAAS;AACf,eAAO,IAAIQ,EAAcR,CAAK;AAElC,UAAIA,EAAM,SAAS;AACf,eAAO,IAAIS,EAAST,CAAK;AAE7B,UAAIA,EAAM,SAAS;AACf,eAAO,IAAIU,EAAgBV,CAAK;AAEpC,UAAIA,EAAM,SAAS;AACf,eAAO,IAAIiB,EAAUjB,CAAK;AAE9B,UAAIA,EAAM,SAAS;AACf,eAAO,IAAIY,EAAgBZ,CAAK;AAEpC,UAAIA,EAAM,SAAS;AACf,eAAO,IAAIe,EAAkBf,CAAK;AAEtC,UAAIA,EAAM,SAAS;AACf,eAAO,IAAIgB,EAAUhB,CAAK;AAE9B,UAAIA,EAAM,SAAS;AACf,eAAO,IAAIW,EAAcX,CAAK;AAElCoC,MAAAA,EAAWpC,GAAO,oBAAoB;AAAA,IAC1C,CAAC,EACA,OAAO,OAAO;AAAA,EACvB;AACJ;","x_google_ignoreList":[0]}
|
|
1
|
+
{"version":3,"file":"DiscreteSettingsImpl.js","sources":["../../../../../../node_modules/@milaboratories/miplots4/src/discrete/DiscreteSettingsImpl.ts"],"sourcesContent":["import { BLACK, DEFAULT_HEIGHT, DEFAULT_HEIGHT_SMALL, DEFAULT_WIDTH, DEFAULT_WIDTH_SMALL } from '../constants';\nimport type {\n AesRecord,\n Color,\n ColumnName,\n DataValue,\n DiscreteSettings,\n FrameType,\n InheritAesDiscrete,\n LegendPosition,\n LineShape,\n Orientation,\n BarLayer as OuterBarLayer,\n BinnedDotsLayer as OuterBinnedDotsLayer,\n BoxLayer as OuterBoxLayer,\n DotLayer as OuterDotLayer,\n ErrorBarLayer as OuterErrorBarLayer,\n LineLayer as OuterLineLayer,\n LogoPlotLayer as OuterLogoPlotLayer,\n PairedPointsLayer as OuterPairedPointsLayer,\n SinaLayer as OuterSinaLayer,\n StackedAreaLayer as OuterStackedAreaLayer,\n StackedBarLayer as OuterStackedBarLayer,\n StatLayer as OuterStatLayer,\n ViolinLayer as OuterViolinLayer,\n PointShape,\n PValueCorrectionMethod,\n SettingsInterface,\n SignificanceLevels,\n StatTestMethod,\n SummaryErrorValue,\n SummaryGroupValue,\n TitlePosition,\n} from '../types';\nimport { DiscreteSettingsSchema } from '../types';\nimport { MIN_MARGIN, PADDINGS } from './constants';\n\nimport lodash from 'lodash';\nimport { exhaustive } from '../utils';\n\nconst DEFAULT_FILL = '#3e9838';\nconst DEFAULT_DOT_SHAPE = '21';\nconst DEFAULT_DOT_SIZE = 3;\n\nabstract class BaseDiscreteLayer {\n abstract type: string;\n abstract isEqualForCalculation(otherLayer: DiscreteLayer): boolean;\n}\n\nexport class BoxLayer extends BaseDiscreteLayer {\n readonly type = 'box';\n readonly stat: {\n upper: number;\n medium: number;\n lower: number;\n k: number;\n } = {\n upper: 0.75,\n medium: 0.5,\n lower: 0.25,\n k: 1.5,\n };\n readonly aes: {\n showOutliers: boolean;\n boxWidth: 'auto' | number;\n dotShape: InheritAesDiscrete | PointShape;\n dotSize: InheritAesDiscrete | number;\n dotFill: InheritAesDiscrete | string;\n lineColor: InheritAesDiscrete | string;\n fillColor: InheritAesDiscrete | string;\n lineWidth: number;\n lineShape: LineShape;\n opacity: number;\n } = {\n showOutliers: true,\n boxWidth: 'auto',\n dotShape: DEFAULT_DOT_SHAPE,\n dotFill: BLACK,\n dotSize: DEFAULT_DOT_SIZE,\n lineColor: BLACK,\n fillColor: DEFAULT_FILL,\n lineWidth: 1,\n lineShape: 'solid',\n opacity: 1,\n };\n\n constructor(layer: OuterBoxLayer) {\n super();\n this.stat = {\n ...this.stat,\n ...layer.stat,\n };\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return (\n otherLayer.type === 'box' &&\n (Object.keys(this.stat) as (keyof BoxLayer['stat'])[]).every(key => this.stat[key] === otherLayer.stat[key])\n );\n }\n}\n\nexport class ViolinLayer extends BaseDiscreteLayer {\n readonly type = 'violin';\n readonly stat: {\n bandwidth: 'auto' | number;\n stepsCount: 'auto' | number;\n trim: boolean;\n } = {\n bandwidth: 'auto',\n stepsCount: 40,\n trim: true,\n };\n readonly aes: {\n width: 'auto' | number;\n lineColor: InheritAesDiscrete | string;\n fillColor: InheritAesDiscrete | string;\n lineWidth: number;\n lineShape: LineShape;\n opacity: number;\n showQuartiles: boolean;\n medianLineStyle: LineShape;\n quartilesLineStyle: LineShape;\n } = {\n width: 'auto',\n lineColor: BLACK,\n fillColor: DEFAULT_FILL,\n lineWidth: 1,\n lineShape: 'solid',\n opacity: 1,\n showQuartiles: true,\n medianLineStyle: 'solid',\n quartilesLineStyle: 'dashed'\n };\n\n constructor(layer: OuterViolinLayer) {\n super();\n this.stat = {\n ...this.stat,\n ...layer.stat,\n };\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return (\n otherLayer.type === 'violin' && (\n this.stat.bandwidth !== otherLayer.stat.bandwidth ||\n this.stat.trim !== otherLayer.stat.trim ||\n this.stat.stepsCount !== otherLayer.stat.stepsCount\n )\n );\n }\n}\n\nexport class DotLayer extends BaseDiscreteLayer {\n readonly type = 'dot';\n readonly aes: {\n showOutliers: boolean;\n jitter: number;\n dotFill: InheritAesDiscrete | string;\n lineColor: InheritAesDiscrete | string;\n dotShape: InheritAesDiscrete | PointShape;\n dotSize: number;\n opacity: number;\n } = {\n showOutliers: true,\n jitter: 0.8,\n lineColor: 'none',\n dotFill: BLACK,\n dotShape: DEFAULT_DOT_SHAPE,\n dotSize: DEFAULT_DOT_SIZE,\n opacity: 1,\n };\n\n constructor(layer: OuterDotLayer) {\n super();\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return otherLayer.type === 'dot' && this.aes.showOutliers === otherLayer.aes.showOutliers;\n }\n}\n\nexport class LineLayer extends BaseDiscreteLayer {\n readonly type = 'line';\n readonly pointsValues: SummaryGroupValue;\n readonly aes: {\n showOutliers: boolean;\n lineWidth: number;\n lineColor: InheritAesDiscrete | string;\n fillColor: InheritAesDiscrete | string;\n lineShape: InheritAesDiscrete | LineShape;\n dotShape: InheritAesDiscrete | PointShape;\n dotSize: number;\n opacity: number;\n } = {\n showOutliers: true,\n lineWidth: 1,\n lineShape: 'solid',\n fillColor: 'none',\n lineColor: BLACK,\n dotShape: DEFAULT_DOT_SHAPE,\n dotSize: DEFAULT_DOT_SIZE,\n opacity: 1,\n };\n\n constructor(layer: OuterLineLayer) {\n super();\n this.pointsValues = layer.pointsValues;\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return otherLayer.type === 'line' && this.pointsValues === otherLayer.pointsValues;\n }\n}\n\nexport class ErrorBarLayer extends BaseDiscreteLayer {\n readonly type = 'errorbar';\n readonly pointsValues: SummaryGroupValue;\n readonly interval: SummaryErrorValue;\n readonly aes: {\n showDots: boolean;\n width: number | 'auto';\n lineWidth: number;\n lineColor: InheritAesDiscrete | string;\n fillColor: InheritAesDiscrete | string;\n dotShape: InheritAesDiscrete | PointShape;\n dotSize: number;\n opacity: number;\n } = {\n showDots: true,\n width: 'auto',\n lineWidth: 1,\n fillColor: 'none',\n lineColor: BLACK,\n dotShape: DEFAULT_DOT_SHAPE,\n dotSize: DEFAULT_DOT_SIZE,\n opacity: 1,\n };\n\n constructor(layer: OuterErrorBarLayer) {\n super();\n this.pointsValues = layer.pointsValues;\n this.interval = layer.interval;\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return (\n otherLayer.type === 'errorbar' &&\n this.pointsValues === otherLayer.pointsValues &&\n this.interval === otherLayer.interval\n );\n }\n}\n\nexport class BarLayer extends BaseDiscreteLayer {\n readonly type = 'bar';\n readonly height: 'min' | 'max' | 'median' | 'mean';\n readonly aes: {\n width: number | 'auto';\n lineColor: InheritAesDiscrete | Color;\n fillColor: InheritAesDiscrete | Color;\n lineWidth: number;\n opacity: number;\n } = {\n width: 'auto',\n lineWidth: 1,\n fillColor: 'none',\n lineColor: BLACK,\n opacity: 1,\n };\n\n constructor(layer: OuterBarLayer) {\n super();\n this.height = layer.height ?? 'max';\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return otherLayer.type === 'bar' && this.height === otherLayer.height;\n }\n}\n\nexport class StackedBarLayer extends BaseDiscreteLayer {\n readonly type = 'stackedBar';\n readonly normalize: boolean = false;\n readonly aes: {\n width: number | 'auto';\n lineColor: InheritAesDiscrete | Color;\n fillColor: InheritAesDiscrete | Color;\n lineWidth: number;\n opacity: number;\n } = {\n width: 'auto',\n lineWidth: 1,\n fillColor: DEFAULT_FILL,\n lineColor: 'none',\n opacity: 1,\n };\n\n constructor(layer: OuterStackedBarLayer) {\n super();\n this.normalize = layer.normalize ?? false;\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return otherLayer.type === 'stackedBar' && otherLayer.normalize === this.normalize;\n }\n}\n\nexport class StackedAreaLayer extends BaseDiscreteLayer {\n readonly type = 'stackedArea';\n readonly normalize: boolean = false;\n readonly showBars: boolean = true;\n readonly aes: {\n barWidth: number | 'auto';\n lineColor: InheritAesDiscrete | Color;\n fillColor: InheritAesDiscrete | Color;\n lineWidth: number;\n barsOpacity: number;\n areaOpacity: number;\n } = {\n barWidth: 'auto',\n lineWidth: 1,\n fillColor: DEFAULT_FILL,\n lineColor: 'none',\n barsOpacity: 1,\n areaOpacity: 0.7,\n };\n\n constructor(layer: OuterStackedAreaLayer) {\n super();\n this.normalize = layer.normalize ?? false;\n this.showBars = layer.showBars ?? true;\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return otherLayer.type === 'stackedArea' && otherLayer.normalize === this.normalize && otherLayer.showBars === this.showBars;\n }\n}\n\nexport class LogoPlotLayer extends BaseDiscreteLayer {\n readonly type = 'logo';\n readonly normalize: boolean = false;\n readonly aes: {\n width: number | 'auto';\n fillColor: Record<string, string> | Color;\n lineColor: Color;\n opacity: number;\n } = {\n width: 'auto',\n fillColor: DEFAULT_FILL,\n lineColor: 'none',\n opacity: 1,\n };\n\n constructor(layer: OuterLogoPlotLayer) {\n super();\n this.normalize = layer.normalize ?? false;\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return otherLayer.type === 'logo' && otherLayer.normalize === this.normalize;\n }\n}\n\nexport class BinnedDotsLayer extends BaseDiscreteLayer {\n readonly type = 'binnedDots';\n readonly method: 'dotdensity' | 'histodot';\n readonly position: 'stack' | 'jitter';\n readonly keyColumn: ColumnName | null;\n readonly aes: {\n showOutliers: boolean;\n width: number | 'auto';\n lineColor: InheritAesDiscrete | Color;\n fillColor: InheritAesDiscrete | Color;\n dotSize?: number;\n lineWidth: number;\n opacity: number;\n } = {\n showOutliers: true,\n width: 'auto',\n lineWidth: 1,\n fillColor: 'none',\n lineColor: BLACK,\n opacity: 1,\n };\n\n constructor(layer: OuterBinnedDotsLayer) {\n super();\n this.method = layer.method ?? 'dotdensity';\n this.position = layer.position ?? 'stack';\n this.keyColumn = layer.keyColumn ?? null;\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return (\n otherLayer.type === 'binnedDots' &&\n this.method === otherLayer.method &&\n this.position === otherLayer.position &&\n this.keyColumn?.value === otherLayer.keyColumn?.value\n );\n }\n}\n\nexport class PairedPointsLayer extends BaseDiscreteLayer {\n readonly type = 'pairedPoints';\n readonly linkColumn: ColumnName;\n readonly aes: {\n showOutliers: boolean;\n lineColor: InheritAesDiscrete | Color;\n lineWidth: number;\n lineShape: LineShape;\n dotFill: InheritAesDiscrete | Color;\n dotSize: number;\n dotShape: PointShape;\n opacity: number;\n } = {\n showOutliers: true,\n lineWidth: 1,\n lineColor: BLACK,\n lineShape: 'solid',\n dotFill: BLACK,\n dotSize: DEFAULT_DOT_SIZE,\n dotShape: DEFAULT_DOT_SHAPE,\n opacity: 1,\n };\n\n constructor(layer: OuterPairedPointsLayer) {\n super();\n this.linkColumn = layer.linkColumn;\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return (\n otherLayer.type === 'pairedPoints' &&\n this.aes.showOutliers === otherLayer.aes.showOutliers &&\n this.linkColumn.value === otherLayer.linkColumn.value\n );\n }\n}\n\nexport class SinaLayer extends BaseDiscreteLayer {\n readonly type = 'sina';\n readonly aes: {\n showOutliers: boolean;\n width: number | 'auto';\n dotFill: InheritAesDiscrete | Color;\n dotSize: number;\n dotShape: InheritAesDiscrete | PointShape;\n opacity: number;\n } = {\n showOutliers: true,\n width: 'auto',\n dotFill: DEFAULT_FILL,\n dotSize: DEFAULT_DOT_SIZE,\n dotShape: DEFAULT_DOT_SHAPE,\n opacity: 1,\n };\n\n constructor(layer: OuterSinaLayer) {\n super();\n this.aes = {\n ...this.aes,\n ...layer.aes,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return otherLayer.type === 'sina' && this.aes.showOutliers === otherLayer.aes.showOutliers;\n }\n}\n\nexport class StatLayer extends BaseDiscreteLayer {\n readonly type = 'stat';\n readonly statType: 'overall' | 'referenceGroup' | 'pairwise';\n readonly testMethod: StatTestMethod;\n readonly paired: boolean;\n readonly ns: boolean;\n readonly format: 'significance' | 'pValue';\n readonly referenceGroup: DataValue | null = null;\n readonly correctionMethod: PValueCorrectionMethod | null = null;\n readonly significanceLevels: SignificanceLevels;\n\n constructor(layer: OuterStatLayer) {\n super();\n this.statType = layer.statType;\n this.testMethod = layer.testMethod;\n this.paired = layer.paired ?? false;\n this.ns = layer.ns ?? true;\n this.format = layer.format ?? 'pValue';\n if (this.statType === 'referenceGroup') {\n this.referenceGroup = layer.referenceGroup ?? null;\n }\n if (this.statType === 'referenceGroup' || this.statType === 'pairwise') {\n this.correctionMethod = layer.correctionMethod ?? null;\n }\n this.significanceLevels = {\n one: layer.significanceLevels?.one ?? 0.05,\n two: layer.significanceLevels?.two ?? 0.01,\n three: layer.significanceLevels?.three ?? 0.001,\n };\n }\n\n isEqualForCalculation(otherLayer: DiscreteLayer) {\n return otherLayer.type === 'stat' && (Object.keys(this) as (keyof StatLayer)[]).every(key => this[key] === otherLayer[key]);\n }\n}\n\nexport type DiscreteLayer =\n | StackedAreaLayer\n | BoxLayer\n | ViolinLayer\n | DotLayer\n | LineLayer\n | ErrorBarLayer\n | BarLayer\n | StackedBarLayer\n | BinnedDotsLayer\n | PairedPointsLayer\n | SinaLayer\n | StatLayer\n | LogoPlotLayer;\n\nexport class DiscreteSettingsImpl implements SettingsInterface {\n readonly id: string;\n readonly type = 'discrete';\n readonly y: ColumnName;\n readonly keyColumn: ColumnName | null;\n readonly primaryGrouping: {\n columnName: ColumnName;\n order?: DataValue[];\n inheritedAes?: AesRecord;\n allowNullGroup?: boolean;\n } | null;\n readonly secondaryGrouping: {\n columnName: ColumnName;\n order?: DataValue[];\n inheritedAes?: AesRecord;\n allowNullGroup?: boolean;\n } | null;\n readonly facetSettings: {\n sharedX: boolean;\n sharedY: boolean;\n order?: Record<string, DataValue[]>; // map with ordered values of columns in \"facetBy\"\n nRows?: number;\n nCols?: number;\n titlePosition?: 'left' | 'right' | 'center';\n } | null;\n readonly facetBy: ColumnName[];\n readonly chartSettings: {\n readonly size: {width: number; height: number, outerOffset: number, innerOffset: number};\n readonly title: {name: string; show: boolean; position: TitlePosition};\n readonly orientation: Orientation;\n readonly yAxis: {\n title: string | ColumnName;\n scale: 'linear' | 'log';\n showGrid: boolean;\n showTicks: boolean;\n hiddenLabels: boolean;\n };\n readonly xAxis: {\n title: string | ColumnName;\n showGrid: boolean;\n linesBetweenCategories: boolean;\n showTicks: boolean;\n labelsPosition: 'center' | '45deg' | '90deg';\n hiddenLabels: boolean;\n };\n readonly frame: {type: FrameType};\n readonly legend: {show: boolean; position: LegendPosition};\n readonly tooltips: {\n box: {show: boolean};\n violin: {show: boolean};\n boxOutliers: {show: boolean};\n line: {show: boolean};\n dot: {show: boolean};\n errorBar: {show: boolean};\n binnedDots: {show: boolean};\n pairedPoints: {show: boolean};\n stackedBar: {show: boolean};\n logo: {show: boolean};\n };\n };\n\n readonly layers: DiscreteLayer[];\n\n constructor(settings: DiscreteSettings) {\n DiscreteSettingsSchema.parse(settings);\n this.id = lodash.uniqueId('settings');\n this.y = settings.y; // throw error if empty or if y.name doesn't exist in input table\n this.keyColumn = settings.keyColumn ?? null;\n this.primaryGrouping = settings.primaryGrouping ?? null; // check columnName\n this.secondaryGrouping = settings.secondaryGrouping ?? null; // check columnName\n this.facetSettings = {\n sharedX: true,\n sharedY: true,\n titlePosition: 'left',\n ...settings.facetSettings,\n };\n this.facetBy = settings.facetBy ?? [];\n this.chartSettings = {\n size: {\n width: settings?.size?.width ?? (this.facetBy.length ? DEFAULT_WIDTH_SMALL : DEFAULT_WIDTH),\n height: settings?.size?.height ?? (this.facetBy.length ? DEFAULT_HEIGHT_SMALL : DEFAULT_HEIGHT),\n outerOffset: settings?.size?.outerOffset ?? MIN_MARGIN,\n innerOffset: settings?.size?.innerOffset ?? PADDINGS.TOP\n },\n title: {\n position: 'center',\n show: true,\n ...settings.title,\n name: settings.title?.name ?? 'Chart',\n },\n orientation: settings.orientation ?? 'vertical',\n yAxis: {\n title: settings.y?.label ?? settings.y.value ?? '',\n scale: 'linear',\n showGrid: true,\n showTicks: true,\n hiddenLabels: false,\n ...settings.yAxis,\n },\n xAxis: {\n title: settings.primaryGrouping?.columnName?.label ?? settings.primaryGrouping?.columnName.value ?? '',\n showGrid: true,\n showTicks: true,\n linesBetweenCategories: true,\n labelsPosition: 'center',\n hiddenLabels: false,\n ...settings.xAxis,\n },\n frame: {type: settings.frame?.type ?? 'full'},\n legend: {\n show: true,\n position: 'right',\n ...settings.legend,\n },\n tooltips: {\n box: {show: true},\n violin: {show: true},\n boxOutliers: {show: true},\n line: {show: true},\n errorBar: {show: true},\n dot: {show: true},\n binnedDots: {show: true},\n pairedPoints: {show: true},\n stackedBar: {show: true},\n logo: {show: false},\n ...settings.tooltips,\n },\n };\n this.layers = settings.layers\n .map(layer => {\n if (layer.type === 'box') {\n return new BoxLayer(layer);\n }\n if (layer.type === 'violin') {\n return new ViolinLayer(layer);\n }\n if (layer.type === 'dot') {\n return new DotLayer(layer);\n }\n if (layer.type === 'line') {\n return new LineLayer(layer);\n }\n if (layer.type === 'errorbar') {\n return new ErrorBarLayer(layer);\n }\n if (layer.type === 'bar') {\n return new BarLayer(layer);\n }\n if (layer.type === 'stackedBar') {\n return new StackedBarLayer(layer);\n }\n if (layer.type === 'stackedArea') {\n return new StackedAreaLayer(layer);\n }\n if (layer.type === 'stat') {\n return new StatLayer(layer);\n }\n if (layer.type === 'binnedDots') {\n return new BinnedDotsLayer(layer);\n }\n if (layer.type === 'pairedPoints') {\n return new PairedPointsLayer(layer);\n }\n if (layer.type === 'sina') {\n return new SinaLayer(layer);\n }\n if (layer.type === 'logo') {\n return new LogoPlotLayer(layer);\n }\n exhaustive(layer, 'Unknown layer type');\n })\n .filter(Boolean) as DiscreteLayer[];\n }\n}\n"],"names":["DEFAULT_FILL","DEFAULT_DOT_SHAPE","DEFAULT_DOT_SIZE","BaseDiscreteLayer","BoxLayer","layer","__publicField","BLACK","otherLayer","key","ViolinLayer","DotLayer","LineLayer","ErrorBarLayer","BarLayer","StackedBarLayer","StackedAreaLayer","LogoPlotLayer","BinnedDotsLayer","_a","_b","PairedPointsLayer","SinaLayer","StatLayer","_c","DiscreteSettingsImpl","settings","DiscreteSettingsSchema","lodash","DEFAULT_WIDTH_SMALL","DEFAULT_WIDTH","DEFAULT_HEIGHT_SMALL","DEFAULT_HEIGHT","MIN_MARGIN","_d","PADDINGS","_e","_f","_h","_g","_i","_j","exhaustive"],"mappings":";;;;;;;;;;;;AAwCA,MAAMA,IAAe,WACfC,IAAoB,MACpBC,IAAmB;AAEzB,MAAeC,EAAkB;AAGjC;AAEO,MAAMC,UAAiBD,EAAkB;AAAA,EAqC5C,YAAYE,GAAsB;AAC9B,UAAA,GArCKC,EAAA,MAAA,QAAO,KAAA,GACPA,EAAA,MAAA,QAKL;AAAA,MACA,OAAO;AAAA,MACP,QAAQ;AAAA,MACR,OAAO;AAAA,MACP,GAAG;AAAA,IAAA,CAAA,GAEEA,EAAA,MAAA,OAWL;AAAA,MACA,cAAc;AAAA,MACd,UAAU;AAAA,MACV,UAAUL;AAAAA,MACV,SAASM;AAAAA,MACT,SAASL;AAAAA,MACT,WAAWK;AAAAA,MACX,WAAWP;AAAAA,MACX,WAAW;AAAA,MACX,WAAW;AAAA,MACX,SAAS;AAAA,IAAA,CAAA,GAKT,KAAK,OAAO;AAAA,MACR,GAAG,KAAK;AAAA,MACR,GAAGK,EAAM;AAAA,IAAA,GAEb,KAAK,MAAM;AAAA,MACP,GAAG,KAAK;AAAA,MACR,GAAGA,EAAM;AAAA,IAAA;AAAA,EAEjB;AAAA,EAEA,sBAAsBG,GAA2B;AAC7C,WACIA,EAAW,SAAS,SACnB,OAAO,KAAK,KAAK,IAAI,EAAiC,MAAM,CAAAC,MAAO,KAAK,KAAKA,CAAG,MAAMD,EAAW,KAAKC,CAAG,CAAC;AAAA,EAEnH;AACJ;AAEO,MAAMC,UAAoBP,EAAkB;AAAA,EAiC/C,YAAYE,GAAyB;AACjC,UAAA,GAjCKC,EAAA,MAAA,QAAO,QAAA,GACPA,EAAA,MAAA,QAIL;AAAA,MACA,WAAW;AAAA,MACX,YAAY;AAAA,MACZ,MAAM;AAAA,IAAA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AiBX,CAAK;AAErC,UAAIA,EAAM,SAAS;AACf,eAAO,IAAIkB,EAAUlB,CAAK;AAE9B,UAAIA,EAAM,SAAS;AACf,eAAO,IAAIa,EAAgBb,CAAK;AAEpC,UAAIA,EAAM,SAAS;AACf,eAAO,IAAIgB,EAAkBhB,CAAK;AAEtC,UAAIA,EAAM,SAAS;AACf,eAAO,IAAIiB,EAAUjB,CAAK;AAE9B,UAAIA,EAAM,SAAS;AACf,eAAO,IAAIY,EAAcZ,CAAK;AAElCqC,MAAAA,EAAWrC,GAAO,oBAAoB;AAAA,IAC1C,CAAC,EACA,OAAO,OAAO;AAAA,EACvB;AACJ;","x_google_ignoreList":[0]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { j as o } from "../../node_modules/react/jsx-runtime.js";
|
|
2
|
-
import { BLACK as
|
|
3
|
-
import { BandAxis as W } from "
|
|
2
|
+
import { BLACK as L } from "../../constants.js";
|
|
3
|
+
import { BandAxis as W } from "../../common/BandAxis.js";
|
|
4
4
|
import { BarElement as $ } from "./layers/BarElement.js";
|
|
5
5
|
import { BinnedDotsElement as ee } from "./layers/BinnedDotsElement.js";
|
|
6
6
|
import { BoxElement as te } from "./layers/BoxElement.js";
|
|
@@ -9,16 +9,17 @@ import { ErrorBarElement as se } from "./layers/ErrorBarElement.js";
|
|
|
9
9
|
import { LineElement as ae } from "./layers/LineElement.js";
|
|
10
10
|
import { LogoElement as ie } from "./layers/LogoElement.js";
|
|
11
11
|
import { PairedPointsElement as ne } from "./layers/PairedPointsElement.js";
|
|
12
|
-
import { SinaElement as
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
12
|
+
import { SinaElement as le } from "./layers/SinaElement.js";
|
|
13
|
+
import { StackedAreaElement as re } from "./layers/StackedAreaElement.js";
|
|
14
|
+
import { StackedBarElement as me } from "./layers/StackedBarElement.js";
|
|
15
|
+
import { StatsPValue as ce } from "./layers/StatsPValue.js";
|
|
15
16
|
import { NumberAxis as X } from "./NumberAxis.js";
|
|
16
17
|
import { getPairwiseStatLevelsCount as pe } from "../utils/statsPValue.js";
|
|
17
|
-
import { ViolinElement as
|
|
18
|
-
import { DEFAULT_TICKS_SIZE as
|
|
19
|
-
import { Grid as
|
|
20
|
-
import { r as
|
|
21
|
-
function
|
|
18
|
+
import { ViolinElement as fe } from "./layers/ViolinElement.js";
|
|
19
|
+
import { DEFAULT_TICKS_SIZE as V, FACET_TITLE_LINE as K, TITLE_LINE as P, P_VALUE_LINE_HEIGHT as Y } from "../constants.js";
|
|
20
|
+
import { Grid as de } from "./Grid.js";
|
|
21
|
+
import { r as ye } from "../../_virtual/index.js";
|
|
22
|
+
function ge(n, h, d) {
|
|
22
23
|
if (!n.length)
|
|
23
24
|
return [];
|
|
24
25
|
const s = [0];
|
|
@@ -27,7 +28,7 @@ function fe(n, y, d) {
|
|
|
27
28
|
if (g.meta.statType === "pairwise") {
|
|
28
29
|
const E = pe(
|
|
29
30
|
g.values[d],
|
|
30
|
-
|
|
31
|
+
h,
|
|
31
32
|
g.meta.significanceLevels,
|
|
32
33
|
g.meta.ns
|
|
33
34
|
);
|
|
@@ -40,9 +41,9 @@ function fe(n, y, d) {
|
|
|
40
41
|
function M(n) {
|
|
41
42
|
return typeof n == "string" ? n : n.value;
|
|
42
43
|
}
|
|
43
|
-
function
|
|
44
|
+
function Ie({
|
|
44
45
|
facetSettings: n,
|
|
45
|
-
facetTitle:
|
|
46
|
+
facetTitle: h,
|
|
46
47
|
dimensions: d,
|
|
47
48
|
scales: s,
|
|
48
49
|
orientation: i,
|
|
@@ -51,38 +52,38 @@ function Fe({
|
|
|
51
52
|
facetKey: a,
|
|
52
53
|
xAxis: x,
|
|
53
54
|
yAxis: u,
|
|
54
|
-
frameType:
|
|
55
|
-
tooltips:
|
|
56
|
-
tooltipsContainer:
|
|
57
|
-
keyColumn:
|
|
58
|
-
chartSizes:
|
|
55
|
+
frameType: A,
|
|
56
|
+
tooltips: f,
|
|
57
|
+
tooltipsContainer: r,
|
|
58
|
+
keyColumn: v,
|
|
59
|
+
chartSizes: j,
|
|
59
60
|
margins: D,
|
|
60
|
-
xLabels:
|
|
61
|
-
onlyPositive:
|
|
62
|
-
secondaryGrouping:
|
|
61
|
+
xLabels: B,
|
|
62
|
+
onlyPositive: z,
|
|
63
|
+
secondaryGrouping: T,
|
|
63
64
|
tooltipsData: m
|
|
64
65
|
}) {
|
|
65
|
-
const [
|
|
66
|
-
left: D.left +
|
|
67
|
-
right:
|
|
68
|
-
top: D.top +
|
|
69
|
-
bottom:
|
|
70
|
-
}, Q = `translate(${
|
|
66
|
+
const [c, J] = ye.useState(), y = i === "vertical", Z = ge(E, s.xPrimary.domain(), a), F = x.showTicks ? V : 0, _ = u.showTicks ? V : 0, I = M(x.title), G = M(u.title), U = d.chartEdgeSides.includes("left") || y && !(n != null && n.sharedY) || !y && !(n != null && n.sharedX), q = d.chartEdgeSides.includes("bottom") || y && !(n != null && n.sharedX) || !y && !(n != null && n.sharedY), N = d.chartEdgeSides.includes("left"), H = d.chartEdgeSides.includes("bottom"), { width: k, height: C } = d.inner, { left: b, top: w, padding: l } = d, p = {
|
|
67
|
+
left: D.left + b + l.left,
|
|
68
|
+
right: j.totalWidth - (D.left + b + l.left),
|
|
69
|
+
top: D.top + w + l.top,
|
|
70
|
+
bottom: j.totalHeight - (D.top + w + l.top)
|
|
71
|
+
}, Q = `translate(${b + l.left},${w + l.top})`, S = !1;
|
|
71
72
|
return /* @__PURE__ */ o.jsxs("g", { transform: Q, children: [
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
const
|
|
73
|
+
S,
|
|
74
|
+
h.length && /* @__PURE__ */ o.jsxs("g", { children: [
|
|
75
|
+
A === "full" && /* @__PURE__ */ o.jsx("rect", { x: "0", y: -l.top, height: l.top, width: k, fill: "#F7F8FA", stroke: L }),
|
|
76
|
+
h.map((e, t) => {
|
|
77
|
+
const O = h.length, R = (l.top - K * O) / 2;
|
|
77
78
|
return /* @__PURE__ */ o.jsx(
|
|
78
79
|
"text",
|
|
79
80
|
{
|
|
80
81
|
fontSize: "14px",
|
|
81
82
|
fontWeight: "500",
|
|
82
|
-
fill:
|
|
83
|
-
x:
|
|
84
|
-
dy:
|
|
85
|
-
y: t *
|
|
83
|
+
fill: L,
|
|
84
|
+
x: k / 2,
|
|
85
|
+
dy: R + K / 2 - l.top,
|
|
86
|
+
y: t * K,
|
|
86
87
|
textAnchor: "middle",
|
|
87
88
|
dominantBaseline: "central",
|
|
88
89
|
children: e
|
|
@@ -91,51 +92,51 @@ function Fe({
|
|
|
91
92
|
);
|
|
92
93
|
})
|
|
93
94
|
] }),
|
|
94
|
-
/* @__PURE__ */ o.jsxs("g", { dominantBaseline: "central", textAnchor: "middle", fontWeight: "500", fontSize: "14px", fill:
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
95
|
+
/* @__PURE__ */ o.jsxs("g", { dominantBaseline: "central", textAnchor: "middle", fontWeight: "500", fontSize: "14px", fill: L, children: [
|
|
96
|
+
H && /* @__PURE__ */ o.jsx("text", { x: k / 2, y: C + l.bottom - P / 2, children: y ? I : G }),
|
|
97
|
+
H && S,
|
|
98
|
+
N && /* @__PURE__ */ o.jsx(
|
|
98
99
|
"text",
|
|
99
100
|
{
|
|
100
|
-
x: -
|
|
101
|
-
y:
|
|
102
|
-
transform: `rotate(-90,${-
|
|
103
|
-
children:
|
|
101
|
+
x: -l.left + P / 2,
|
|
102
|
+
y: C / 2,
|
|
103
|
+
transform: `rotate(-90,${-l.left + P / 2},${C / 2})`,
|
|
104
|
+
children: y ? G : I
|
|
104
105
|
}
|
|
105
106
|
),
|
|
106
|
-
|
|
107
|
+
N && S
|
|
107
108
|
] }),
|
|
108
109
|
/* @__PURE__ */ o.jsx(
|
|
109
|
-
|
|
110
|
+
de,
|
|
110
111
|
{
|
|
111
112
|
orientation: i,
|
|
112
|
-
width:
|
|
113
|
-
height:
|
|
113
|
+
width: k,
|
|
114
|
+
height: C,
|
|
114
115
|
scaleX: s.xPrimary,
|
|
115
116
|
scaleY: s.y,
|
|
116
117
|
axisX: x,
|
|
117
118
|
axisY: u,
|
|
118
|
-
frameType:
|
|
119
|
+
frameType: A
|
|
119
120
|
}
|
|
120
121
|
),
|
|
121
|
-
q && /* @__PURE__ */ o.jsx("g", { transform: `translate(0,${
|
|
122
|
+
q && /* @__PURE__ */ o.jsx("g", { transform: `translate(0,${C})`, children: y ? /* @__PURE__ */ o.jsx(
|
|
122
123
|
W,
|
|
123
124
|
{
|
|
124
125
|
scale: s.xPrimary,
|
|
125
126
|
orient: "bottom",
|
|
126
127
|
labelsPosition: x.labelsPosition,
|
|
127
128
|
tickSize: F,
|
|
128
|
-
labels:
|
|
129
|
+
labels: B
|
|
129
130
|
}
|
|
130
|
-
) : /* @__PURE__ */ o.jsx(X, { scale: s.y, onlyPositive:
|
|
131
|
-
U && /* @__PURE__ */ o.jsx("g", { children:
|
|
131
|
+
) : /* @__PURE__ */ o.jsx(X, { scale: s.y, onlyPositive: z, orient: "bottom", tickSize: _, hiddenLabels: u.hiddenLabels }) }),
|
|
132
|
+
U && /* @__PURE__ */ o.jsx("g", { children: y ? /* @__PURE__ */ o.jsx(X, { scale: s.y, onlyPositive: z, orient: "left", tickSize: _, hiddenLabels: u.hiddenLabels }) : /* @__PURE__ */ o.jsx(
|
|
132
133
|
W,
|
|
133
134
|
{
|
|
134
135
|
scale: s.xPrimary,
|
|
135
136
|
orient: "left",
|
|
136
137
|
labelsPosition: x.labelsPosition,
|
|
137
138
|
tickSize: F,
|
|
138
|
-
labels:
|
|
139
|
+
labels: B
|
|
139
140
|
}
|
|
140
141
|
) }),
|
|
141
142
|
/* @__PURE__ */ o.jsxs("g", { children: [
|
|
@@ -149,17 +150,17 @@ function Fe({
|
|
|
149
150
|
scales: s,
|
|
150
151
|
orientation: i,
|
|
151
152
|
aes: e.aes,
|
|
152
|
-
hasKeyFromColumn:
|
|
153
|
-
sideDistances:
|
|
154
|
-
showTooltips:
|
|
153
|
+
hasKeyFromColumn: v !== null,
|
|
154
|
+
sideDistances: p,
|
|
155
|
+
showTooltips: f.box.show,
|
|
155
156
|
tooltipsData: m,
|
|
156
|
-
activeElementContainer:
|
|
157
|
-
tooltipsContainer:
|
|
157
|
+
activeElementContainer: c,
|
|
158
|
+
tooltipsContainer: r
|
|
158
159
|
},
|
|
159
160
|
t.key
|
|
160
161
|
)),
|
|
161
162
|
e.type === "violin" && e.geoms[a].map((t) => /* @__PURE__ */ o.jsx(
|
|
162
|
-
|
|
163
|
+
fe,
|
|
163
164
|
{
|
|
164
165
|
facetKey: a,
|
|
165
166
|
violin: t,
|
|
@@ -168,11 +169,11 @@ function Fe({
|
|
|
168
169
|
orientation: i,
|
|
169
170
|
maxViolinDensity: e.meta.maxDensity,
|
|
170
171
|
aes: e.aes,
|
|
171
|
-
sideDistances:
|
|
172
|
-
showTooltips:
|
|
172
|
+
sideDistances: p,
|
|
173
|
+
showTooltips: f.violin.show,
|
|
173
174
|
tooltipsData: m,
|
|
174
|
-
activeElementContainer:
|
|
175
|
-
tooltipsContainer:
|
|
175
|
+
activeElementContainer: c,
|
|
176
|
+
tooltipsContainer: r
|
|
176
177
|
},
|
|
177
178
|
t.key
|
|
178
179
|
)),
|
|
@@ -184,12 +185,12 @@ function Fe({
|
|
|
184
185
|
scales: s,
|
|
185
186
|
orientation: i,
|
|
186
187
|
aes: e.aes,
|
|
187
|
-
hasKeyFromColumn:
|
|
188
|
-
sideDistances:
|
|
189
|
-
showTooltips:
|
|
188
|
+
hasKeyFromColumn: v !== null,
|
|
189
|
+
sideDistances: p,
|
|
190
|
+
showTooltips: f.dot.show,
|
|
190
191
|
tooltipsData: m,
|
|
191
|
-
activeElementContainer:
|
|
192
|
-
tooltipsContainer:
|
|
192
|
+
activeElementContainer: c,
|
|
193
|
+
tooltipsContainer: r
|
|
193
194
|
},
|
|
194
195
|
t.key
|
|
195
196
|
)),
|
|
@@ -200,13 +201,13 @@ function Fe({
|
|
|
200
201
|
line: t,
|
|
201
202
|
scales: s,
|
|
202
203
|
orientation: i,
|
|
203
|
-
sideDistances:
|
|
204
|
+
sideDistances: p,
|
|
204
205
|
aes: e.aes,
|
|
205
|
-
showTooltips:
|
|
206
|
-
secondaryGrouping:
|
|
206
|
+
showTooltips: f.line.show,
|
|
207
|
+
secondaryGrouping: T,
|
|
207
208
|
tooltipsData: m,
|
|
208
|
-
activeElementContainer:
|
|
209
|
-
tooltipsContainer:
|
|
209
|
+
activeElementContainer: c,
|
|
210
|
+
tooltipsContainer: r
|
|
210
211
|
},
|
|
211
212
|
t.key
|
|
212
213
|
)),
|
|
@@ -218,11 +219,11 @@ function Fe({
|
|
|
218
219
|
scales: s,
|
|
219
220
|
orientation: i,
|
|
220
221
|
aes: e.aes,
|
|
221
|
-
sideDistances:
|
|
222
|
-
showTooltips:
|
|
222
|
+
sideDistances: p,
|
|
223
|
+
showTooltips: f.errorBar.show,
|
|
223
224
|
tooltipsData: m,
|
|
224
|
-
activeElementContainer:
|
|
225
|
-
tooltipsContainer:
|
|
225
|
+
activeElementContainer: c,
|
|
226
|
+
tooltipsContainer: r
|
|
226
227
|
},
|
|
227
228
|
t.key
|
|
228
229
|
)),
|
|
@@ -237,7 +238,7 @@ function Fe({
|
|
|
237
238
|
t.key
|
|
238
239
|
)),
|
|
239
240
|
e.type === "stackedBar" && e.geoms[a].map((t) => /* @__PURE__ */ o.jsx(
|
|
240
|
-
|
|
241
|
+
me,
|
|
241
242
|
{
|
|
242
243
|
facetKey: a,
|
|
243
244
|
geom: t,
|
|
@@ -246,15 +247,31 @@ function Fe({
|
|
|
246
247
|
orientation: i,
|
|
247
248
|
aes: e.aes,
|
|
248
249
|
normalize: e.meta.normalize,
|
|
249
|
-
sideDistances:
|
|
250
|
-
showTooltips:
|
|
251
|
-
secondaryGrouping:
|
|
250
|
+
sideDistances: p,
|
|
251
|
+
showTooltips: f.stackedBar.show,
|
|
252
|
+
secondaryGrouping: T,
|
|
252
253
|
tooltipsData: m,
|
|
253
|
-
activeElementContainer:
|
|
254
|
-
tooltipsContainer:
|
|
254
|
+
activeElementContainer: c,
|
|
255
|
+
tooltipsContainer: r
|
|
255
256
|
},
|
|
256
257
|
t.key
|
|
257
258
|
)),
|
|
259
|
+
e.type === "stackedArea" && /* @__PURE__ */ o.jsx(
|
|
260
|
+
re,
|
|
261
|
+
{
|
|
262
|
+
facetKey: a,
|
|
263
|
+
layerData: e,
|
|
264
|
+
scales: s,
|
|
265
|
+
orientation: i,
|
|
266
|
+
sideDistances: p,
|
|
267
|
+
showTooltips: f.stackedBar.show,
|
|
268
|
+
secondaryGrouping: T,
|
|
269
|
+
tooltipsData: m,
|
|
270
|
+
activeElementContainer: c,
|
|
271
|
+
tooltipsContainer: r
|
|
272
|
+
},
|
|
273
|
+
"stackedArea"
|
|
274
|
+
),
|
|
258
275
|
e.type === "binnedDots" && e.geoms[a].map((t) => /* @__PURE__ */ o.jsx(
|
|
259
276
|
ee,
|
|
260
277
|
{
|
|
@@ -267,11 +284,11 @@ function Fe({
|
|
|
267
284
|
min: e.meta.minY,
|
|
268
285
|
max: e.meta.maxY,
|
|
269
286
|
hasKeyFromColumn: e.meta.hasKeyFromColumn,
|
|
270
|
-
sideDistances:
|
|
271
|
-
showTooltips:
|
|
287
|
+
sideDistances: p,
|
|
288
|
+
showTooltips: f.stackedBar.show,
|
|
272
289
|
tooltipsData: m,
|
|
273
|
-
activeElementContainer:
|
|
274
|
-
tooltipsContainer:
|
|
290
|
+
activeElementContainer: c,
|
|
291
|
+
tooltipsContainer: r
|
|
275
292
|
},
|
|
276
293
|
t.key
|
|
277
294
|
)),
|
|
@@ -282,26 +299,26 @@ function Fe({
|
|
|
282
299
|
geom: t,
|
|
283
300
|
scales: s,
|
|
284
301
|
orientation: i,
|
|
285
|
-
sideDistances:
|
|
302
|
+
sideDistances: p,
|
|
286
303
|
aes: e.aes,
|
|
287
|
-
showTooltips:
|
|
304
|
+
showTooltips: f.pairedPoints.show,
|
|
288
305
|
tooltipsData: m,
|
|
289
|
-
activeElementContainer:
|
|
290
|
-
tooltipsContainer:
|
|
306
|
+
activeElementContainer: c,
|
|
307
|
+
tooltipsContainer: r
|
|
291
308
|
},
|
|
292
309
|
t.id
|
|
293
310
|
)),
|
|
294
311
|
e.type === "sina" && e.geoms[a].map((t) => /* @__PURE__ */ o.jsx(
|
|
295
|
-
|
|
312
|
+
le,
|
|
296
313
|
{
|
|
297
314
|
geom: t,
|
|
298
315
|
scales: s,
|
|
299
316
|
orientation: i,
|
|
300
|
-
sideDistances:
|
|
317
|
+
sideDistances: p,
|
|
301
318
|
aes: e.aes,
|
|
302
|
-
hasKeyFromColumn:
|
|
319
|
+
hasKeyFromColumn: v !== null,
|
|
303
320
|
showTooltips: !1,
|
|
304
|
-
tooltipsContainer:
|
|
321
|
+
tooltipsContainer: r
|
|
305
322
|
},
|
|
306
323
|
t.key
|
|
307
324
|
)),
|
|
@@ -315,17 +332,17 @@ function Fe({
|
|
|
315
332
|
orientation: i,
|
|
316
333
|
aes: e.aes,
|
|
317
334
|
normalize: e.meta.normalize,
|
|
318
|
-
sideDistances:
|
|
319
|
-
showTooltips:
|
|
335
|
+
sideDistances: p,
|
|
336
|
+
showTooltips: f.logo.show,
|
|
320
337
|
tooltipsData: m,
|
|
321
|
-
activeElementContainer:
|
|
322
|
-
tooltipsContainer:
|
|
338
|
+
activeElementContainer: c,
|
|
339
|
+
tooltipsContainer: r
|
|
323
340
|
},
|
|
324
341
|
t.key
|
|
325
342
|
))
|
|
326
343
|
] }, e.type)),
|
|
327
344
|
E.map((e, t) => /* @__PURE__ */ o.jsx(
|
|
328
|
-
|
|
345
|
+
ce,
|
|
329
346
|
{
|
|
330
347
|
yShift: Z[t],
|
|
331
348
|
scales: s,
|
|
@@ -341,12 +358,12 @@ function Fe({
|
|
|
341
358
|
))
|
|
342
359
|
] }),
|
|
343
360
|
/* @__PURE__ */ o.jsxs("g", { children: [
|
|
344
|
-
m.fixed && /* @__PURE__ */ o.jsx("rect", { width:
|
|
361
|
+
m.fixed && /* @__PURE__ */ o.jsx("rect", { width: j.chartWidth, height: j.chartHeight, fill: "rgba(255, 255, 255, 0.8)" }),
|
|
345
362
|
/* @__PURE__ */ o.jsx(
|
|
346
363
|
"g",
|
|
347
364
|
{
|
|
348
365
|
ref: (e) => {
|
|
349
|
-
e && !
|
|
366
|
+
e && !c && J(e);
|
|
350
367
|
}
|
|
351
368
|
}
|
|
352
369
|
)
|
|
@@ -354,6 +371,6 @@ function Fe({
|
|
|
354
371
|
] });
|
|
355
372
|
}
|
|
356
373
|
export {
|
|
357
|
-
|
|
374
|
+
Ie as Chart
|
|
358
375
|
};
|
|
359
376
|
//# sourceMappingURL=Chart.js.map
|