@milaboratories/graph-maker 1.1.177 → 1.1.179
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/components/AesButton.vue.d.ts +6 -6
- package/dist/components/AesButton.vue.js +2 -2
- package/dist/components/AesButton.vue.js.map +1 -1
- package/dist/components/AesSettings/AesDataMappingContinuous.vue.js +14 -14
- package/dist/components/AesSettings/AesDataMappingContinuous.vue.js.map +1 -1
- package/dist/components/AesSettings/AesDataMappingDiscrete.vue.js +39 -38
- package/dist/components/AesSettings/AesDataMappingDiscrete.vue.js.map +1 -1
- package/dist/components/AesSettings/FixedColorsList.vue.d.ts +1 -1
- package/dist/components/AesSettings/FixedColorsList.vue.js +13 -12
- package/dist/components/AesSettings/FixedColorsList.vue.js.map +1 -1
- package/dist/components/AesSettings/FixedDotShapeList.vue.js +10 -9
- package/dist/components/AesSettings/FixedDotShapeList.vue.js.map +1 -1
- package/dist/components/AesSettings/FixedLineTypeList.vue.js +12 -11
- package/dist/components/AesSettings/FixedLineTypeList.vue.js.map +1 -1
- package/dist/components/AesSettings/FormWrapper.vue.js +2 -2
- package/dist/components/AesSettings/FormWrapper.vue.js.map +1 -1
- package/dist/components/AesSettings/PalettesForm.vue.js +54 -50
- package/dist/components/AesSettings/PalettesForm.vue.js.map +1 -1
- package/dist/components/AesSettings/types.d.ts +9 -9
- package/dist/components/BtnIconGroup.vue.js +10 -11
- package/dist/components/BtnIconGroup.vue.js.map +1 -1
- package/dist/components/Chart.vue.js +6 -8
- package/dist/components/Chart.vue.js.map +1 -1
- package/dist/components/CollapsableBlock.vue.js +2 -2
- package/dist/components/CollapsableBlock.vue.js.map +1 -1
- package/dist/components/DendroTable.vue.js +2 -2
- package/dist/components/DendroTable.vue.js.map +1 -1
- package/dist/components/DendroTooltip.vue.js +15 -14
- package/dist/components/DendroTooltip.vue.js.map +1 -1
- package/dist/components/DragAndDrop/DnDBasketChip.vue.js +2 -2
- package/dist/components/DragAndDrop/DnDBasketChip.vue.js.map +1 -1
- package/dist/components/DragAndDrop/DnDRangeChip.vue.d.ts +12 -3
- package/dist/components/DragAndDrop/DnDRangeChip.vue.js +4 -4
- package/dist/components/DragAndDrop/DnDRangeChip.vue.js.map +1 -1
- package/dist/components/DragAndDrop/DndBasket.vue.js +26 -26
- package/dist/components/DragAndDrop/DndBasket.vue.js.map +1 -1
- package/dist/components/DragAndDrop/DndChip.vue.js.map +1 -1
- package/dist/components/DragAndDrop/DndDoubleChip.vue.js +2 -2
- package/dist/components/DragAndDrop/DndDoubleChip.vue.js.map +1 -1
- package/dist/components/DragAndDrop/types.d.ts +1 -1
- package/dist/components/LassoControls/index.vue.js +4 -4
- package/dist/components/LassoControls/index.vue.js.map +1 -1
- package/dist/components/Loading.vue.js +8 -7
- package/dist/components/Loading.vue.js.map +1 -1
- package/dist/components/MultiselectButton.vue.js +28 -27
- package/dist/components/MultiselectButton.vue.js.map +1 -1
- package/dist/components/PanelModal.vue.js.map +1 -1
- package/dist/components/PlColorSlider.vue.js +12 -12
- package/dist/components/PlColorSlider.vue.js.map +1 -1
- package/dist/components/PlColorSliderThumb.vue.js +1 -3
- package/dist/components/PlColorSliderThumb.vue.js.map +1 -1
- package/dist/components/Popup.vue.d.ts +2 -0
- package/dist/components/Popup.vue.js +21 -21
- package/dist/components/Popup.vue.js.map +1 -1
- package/dist/components/ReorderForm.vue.js +20 -17
- package/dist/components/ReorderForm.vue.js.map +1 -1
- package/dist/components/SettingsTabs/icons/DeleteChartIcon.vue.js.map +1 -1
- package/dist/components/SettingsTabs/icons/LogIcon.vue.js.map +1 -1
- package/dist/components/SettingsTabs/icons/SettingsIcon.vue.js.map +1 -1
- package/dist/components/SettingsTabs/index.vue.d.ts +3 -2
- package/dist/components/SettingsTabs/index.vue.js +16 -15
- package/dist/components/SettingsTabs/index.vue.js.map +1 -1
- package/dist/components/Zoom/ZoomInput.vue.js +11 -11
- package/dist/components/Zoom/ZoomInput.vue.js.map +1 -1
- package/dist/components/Zoom/index.vue.js.map +1 -1
- package/dist/composition/useComponent.js.map +1 -1
- package/dist/constantsAesthetic.js.map +1 -1
- package/dist/constantsCommon.d.ts +3 -1
- package/dist/constantsCommon.js +5 -5
- package/dist/constantsCommon.js.map +1 -1
- package/dist/dataBindAes.js +4 -2
- package/dist/dataBindAes.js.map +1 -1
- package/dist/forms/AnnotationsForm.vue.d.ts +17 -0
- package/dist/forms/AnnotationsForm.vue.js +16 -0
- package/dist/forms/AnnotationsForm.vue.js.map +1 -0
- package/dist/forms/AxesSettingsForm/BubbleAxesSettingsForm.vue.js +35 -35
- package/dist/forms/AxesSettingsForm/BubbleAxesSettingsForm.vue.js.map +1 -1
- package/dist/forms/AxesSettingsForm/DiscreteAxesSettingsForm.vue.js +49 -47
- package/dist/forms/AxesSettingsForm/DiscreteAxesSettingsForm.vue.js.map +1 -1
- package/dist/forms/AxesSettingsForm/HeatmapAxesSettingsForm.vue.js +53 -53
- package/dist/forms/AxesSettingsForm/HeatmapAxesSettingsForm.vue.js.map +1 -1
- package/dist/forms/AxesSettingsForm/HistogramAxesSettingsForm.vue.js +37 -37
- package/dist/forms/AxesSettingsForm/HistogramAxesSettingsForm.vue.js.map +1 -1
- package/dist/forms/AxesSettingsForm/ScatterplotAxesSettingsForm.vue.js +38 -38
- package/dist/forms/AxesSettingsForm/ScatterplotAxesSettingsForm.vue.js.map +1 -1
- package/dist/forms/AxesSettingsForm/index.vue.js.map +1 -1
- package/dist/forms/DataMappingForm/BubbleForm.vue.js +4 -4
- package/dist/forms/DataMappingForm/BubbleForm.vue.js.map +1 -1
- package/dist/forms/DataMappingForm/DendroForm.vue.js +1 -1
- package/dist/forms/DataMappingForm/DendroForm.vue.js.map +1 -1
- package/dist/forms/DataMappingForm/DiscreteForm.vue.js.map +1 -1
- package/dist/forms/DataMappingForm/HeatmapForm.vue.js +2 -2
- package/dist/forms/DataMappingForm/HeatmapForm.vue.js.map +1 -1
- package/dist/forms/DataMappingForm/HistogramForm.vue.js.map +1 -1
- package/dist/forms/DataMappingForm/Layout/FormLayout.vue.js.map +1 -1
- package/dist/forms/DataMappingForm/Layout/MandatoryOptions.vue.js.map +1 -1
- package/dist/forms/DataMappingForm/Layout/OptionsList.vue.js.map +1 -1
- package/dist/forms/DataMappingForm/ScatterplotForm.vue.js +4 -4
- package/dist/forms/DataMappingForm/ScatterplotForm.vue.js.map +1 -1
- package/dist/forms/DataMappingForm/ScatterplotUmapForm.vue.js +4 -4
- package/dist/forms/DataMappingForm/ScatterplotUmapForm.vue.js.map +1 -1
- package/dist/forms/DataMappingForm/index.vue.js.map +1 -1
- package/dist/forms/DataMappingForm/useBaskets.js.map +1 -1
- package/dist/forms/DataMappingForm/utils.d.ts +1 -1
- package/dist/forms/DataMappingForm/utils.js +34 -34
- package/dist/forms/DataMappingForm/utils.js.map +1 -1
- package/dist/forms/LayersForm/AesSelector.vue.js +18 -25
- package/dist/forms/LayersForm/AesSelector.vue.js.map +1 -1
- package/dist/forms/LayersForm/DotSizeSelector.vue.d.ts +2 -0
- package/dist/forms/LayersForm/DotSizeSelector.vue.js +23 -23
- package/dist/forms/LayersForm/DotSizeSelector.vue.js.map +1 -1
- package/dist/forms/LayersForm/Layer/Bubble.vue.js +32 -34
- package/dist/forms/LayersForm/Layer/Bubble.vue.js.map +1 -1
- package/dist/forms/LayersForm/Layer/Dendro.vue.js +6 -6
- package/dist/forms/LayersForm/Layer/Dendro.vue.js.map +1 -1
- package/dist/forms/LayersForm/Layer/discrete/Bar.vue.js +6 -6
- package/dist/forms/LayersForm/Layer/discrete/Bar.vue.js.map +1 -1
- package/dist/forms/LayersForm/Layer/discrete/BinnedDots.vue.js +3 -3
- package/dist/forms/LayersForm/Layer/discrete/BinnedDots.vue.js.map +1 -1
- package/dist/forms/LayersForm/Layer/discrete/Boxplot.vue.js +3 -3
- package/dist/forms/LayersForm/Layer/discrete/Boxplot.vue.js.map +1 -1
- package/dist/forms/LayersForm/Layer/discrete/Errorbar.vue.js +9 -9
- package/dist/forms/LayersForm/Layer/discrete/Errorbar.vue.js.map +1 -1
- package/dist/forms/LayersForm/Layer/discrete/JitteredDots.vue.js +3 -3
- package/dist/forms/LayersForm/Layer/discrete/JitteredDots.vue.js.map +1 -1
- package/dist/forms/LayersForm/Layer/discrete/Line.vue.js +8 -8
- package/dist/forms/LayersForm/Layer/discrete/Line.vue.js.map +1 -1
- package/dist/forms/LayersForm/Layer/discrete/Logo.vue.js +3 -3
- package/dist/forms/LayersForm/Layer/discrete/Logo.vue.js.map +1 -1
- package/dist/forms/LayersForm/Layer/discrete/Sina.vue.js +3 -3
- package/dist/forms/LayersForm/Layer/discrete/Sina.vue.js.map +1 -1
- package/dist/forms/LayersForm/Layer/discrete/StackedArea.vue.js +9 -9
- package/dist/forms/LayersForm/Layer/discrete/StackedArea.vue.js.map +1 -1
- package/dist/forms/LayersForm/Layer/discrete/StackedBar.vue.js +6 -6
- package/dist/forms/LayersForm/Layer/discrete/StackedBar.vue.js.map +1 -1
- package/dist/forms/LayersForm/Layer/discrete/Violin.vue.js +3 -3
- package/dist/forms/LayersForm/Layer/discrete/Violin.vue.js.map +1 -1
- package/dist/forms/LayersForm/Layer/discrete/utils.js.map +1 -1
- package/dist/forms/LayersForm/Layer/heatmap/Heatmap.vue.js +23 -23
- package/dist/forms/LayersForm/Layer/heatmap/Heatmap.vue.js.map +1 -1
- package/dist/forms/LayersForm/Layer/heatmap/HeatmapAnnotations.vue.js +6 -6
- package/dist/forms/LayersForm/Layer/heatmap/HeatmapAnnotations.vue.js.map +1 -1
- package/dist/forms/LayersForm/Layer/heatmap/HeatmapClustered.vue.js +28 -28
- package/dist/forms/LayersForm/Layer/heatmap/HeatmapClustered.vue.js.map +1 -1
- package/dist/forms/LayersForm/Layer/histogram/Bins.vue.js +3 -3
- package/dist/forms/LayersForm/Layer/histogram/Bins.vue.js.map +1 -1
- package/dist/forms/LayersForm/Layer/scatterplot/Curve.vue.js.map +1 -1
- package/dist/forms/LayersForm/Layer/scatterplot/Scatter.vue.js.map +1 -1
- package/dist/forms/LayersForm/Layer/scatterplot-umap/Scatter.vue.js +2 -2
- package/dist/forms/LayersForm/Layer/scatterplot-umap/Scatter.vue.js.map +1 -1
- package/dist/forms/LayersForm/index.vue.js +56 -52
- package/dist/forms/LayersForm/index.vue.js.map +1 -1
- package/dist/forms/LogForm.vue.js.map +1 -1
- package/dist/forms/SettingsForm.vue.js.map +1 -1
- package/dist/forms/StatisticsForm/DiscreteStatisticsForm.vue.js +14 -14
- package/dist/forms/StatisticsForm/DiscreteStatisticsForm.vue.js.map +1 -1
- package/dist/forms/StatisticsForm/ScatterplotStatisticsForm.vue.js.map +1 -1
- package/dist/forms/StatisticsForm/index.vue.js.map +1 -1
- package/dist/forms/TemplateForm.vue.js +59 -52
- package/dist/forms/TemplateForm.vue.js.map +1 -1
- package/dist/forms/index.d.ts +21 -0
- package/dist/forms/index.js +53 -46
- package/dist/forms/index.js.map +1 -1
- package/dist/icons/Annotation.vue.d.ts +2 -0
- package/dist/icons/Annotation.vue.js +12 -0
- package/dist/icons/Annotation.vue.js.map +1 -0
- package/dist/icons/Annotation.vue2.js +5 -0
- package/dist/icons/Annotation.vue2.js.map +1 -0
- package/dist/icons/BinnedDotsIcon.vue.js.map +1 -1
- package/dist/icons/BoxplotAndBinnedIcon.vue.js.map +1 -1
- package/dist/icons/BoxplotAndJitterIcon.vue.js.map +1 -1
- package/dist/icons/BoxplotIcon.vue.js.map +1 -1
- package/dist/icons/EditIcon.vue.js.map +1 -1
- package/dist/icons/FrameLeft.vue.js.map +1 -1
- package/dist/icons/HeatmapAnnotation.vue.js.map +1 -1
- package/dist/icons/LineAndErrorbarIcon.vue.js.map +1 -1
- package/dist/icons/LogoIcon.vue.js.map +1 -1
- package/dist/icons/PlusIcon.vue.js.map +1 -1
- package/dist/icons/SinaIcon.vue.js.map +1 -1
- package/dist/icons/StackedAreaIcon.vue.js.map +1 -1
- package/dist/index.vue.d.ts +1 -0
- package/dist/index.vue.js +148 -146
- package/dist/index.vue.js.map +1 -1
- package/dist/store.d.ts +1 -1
- package/dist/store.js +2 -2
- package/dist/store.js.map +1 -1
- package/dist/types.d.ts +1 -1
- package/dist/utils/addFixedOptionsToState.js.map +1 -1
- package/dist/utils/calculateDiscreteGroups.js.map +1 -1
- package/dist/utils/createChartSettingsForRender/composeBubbleSettings.js.map +1 -1
- package/dist/utils/createChartSettingsForRender/composeChartSettings.js.map +1 -1
- package/dist/utils/createChartSettingsForRender/composeDendroSettings.js.map +1 -1
- package/dist/utils/createChartSettingsForRender/composeDiscreteSettings.js +1 -1
- package/dist/utils/createChartSettingsForRender/composeDiscreteSettings.js.map +1 -1
- package/dist/utils/createChartSettingsForRender/composeHeatmapSettings.js.map +1 -1
- package/dist/utils/createChartSettingsForRender/composeHistogramSettings.js.map +1 -1
- package/dist/utils/createChartSettingsForRender/composeScatterplotSettings.js.map +1 -1
- package/dist/utils/createChartSettingsForRender/composeScatterplotUmapSettings.js +1 -1
- package/dist/utils/createChartSettingsForRender/composeScatterplotUmapSettings.js.map +1 -1
- package/dist/utils/createChartSettingsForRender/getAxesDataFromForms.js +24 -24
- package/dist/utils/createChartSettingsForRender/getAxesDataFromForms.js.map +1 -1
- package/dist/utils/createChartSettingsForRender/getLayersDataFromForms.js.map +1 -1
- package/dist/utils/getPopupHeightForFixedAesList.js.map +1 -1
- package/dist/utils/getStatisticsOptions.js.map +1 -1
- package/dist/utils/getUsedAesInMapping.js +1 -1
- package/dist/utils/getUsedAesInMapping.js.map +1 -1
- package/dist/utils/loadDefaultSources.js.map +1 -1
- package/dist/utils/loadUniqueValuesToSave.js.map +1 -1
- package/dist/utils/saveToFile.js.map +1 -1
- package/package.json +5 -3
|
@@ -6,17 +6,18 @@ type __VLS_Props = {
|
|
|
6
6
|
graphStatus: GraphStatus;
|
|
7
7
|
allowDeleting?: boolean;
|
|
8
8
|
hasSettingsSlot?: boolean;
|
|
9
|
+
hasAnnotationsSlot?: boolean;
|
|
9
10
|
hasLogSlot?: boolean;
|
|
10
11
|
initialLoading: boolean;
|
|
11
12
|
modelValue: FormKey | null;
|
|
12
13
|
};
|
|
13
14
|
declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
14
|
-
delete: (...args: any[]) => void;
|
|
15
15
|
export: (...args: any[]) => void;
|
|
16
|
+
delete: (...args: any[]) => void;
|
|
16
17
|
"update:modelValue": (...args: any[]) => void;
|
|
17
18
|
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
18
|
-
onDelete?: ((...args: any[]) => any) | undefined;
|
|
19
19
|
onExport?: ((...args: any[]) => any) | undefined;
|
|
20
|
+
onDelete?: ((...args: any[]) => any) | undefined;
|
|
20
21
|
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
21
22
|
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
22
23
|
export default _default;
|
|
@@ -1,46 +1,47 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as m, computed as g, createElementBlock as s, openBlock as a, Fragment as y, renderList as f, createBlock as n, unref as i, normalizeClass as S, withCtx as r, resolveDynamicComponent as B, createElementVNode as v, toDisplayString as x } from "vue";
|
|
2
2
|
import { PlTooltip as V } from "@platforma-sdk/ui-vue";
|
|
3
3
|
import { tabKeys as C, resolveIcon as T, resolveTitle as L } from "../../forms/index.js";
|
|
4
|
-
const b = { class: "settings-tabs" }, D = { style: { "font-family": "var(--font-family-base)" } },
|
|
4
|
+
const b = { class: "settings-tabs" }, D = { style: { "font-family": "var(--font-family-base)" } }, M = /* @__PURE__ */ m({
|
|
5
5
|
__name: "index",
|
|
6
6
|
props: {
|
|
7
7
|
chartType: {},
|
|
8
8
|
graphStatus: {},
|
|
9
9
|
allowDeleting: { type: Boolean },
|
|
10
10
|
hasSettingsSlot: { type: Boolean },
|
|
11
|
+
hasAnnotationsSlot: { type: Boolean },
|
|
11
12
|
hasLogSlot: { type: Boolean },
|
|
12
13
|
initialLoading: { type: Boolean },
|
|
13
14
|
modelValue: {}
|
|
14
15
|
},
|
|
15
16
|
emits: ["update:modelValue", "export", "delete"],
|
|
16
|
-
setup(
|
|
17
|
-
const p = c,
|
|
18
|
-
(e) => !(e === "settings" && !
|
|
17
|
+
setup(l, { emit: c }) {
|
|
18
|
+
const p = c, o = l, d = g(() => C().filter(
|
|
19
|
+
(e) => !(e === "annotations" && !o.hasAnnotationsSlot) && !(e === "settings" && !o.hasSettingsSlot) && !(e === "log" && !o.hasLogSlot) && !(e === "statistics" && o.chartType !== "discrete" && o.chartType !== "scatterplot") && !(e === "delete" && o.allowDeleting)
|
|
19
20
|
));
|
|
20
21
|
function u(e) {
|
|
21
|
-
p("update:modelValue", e ===
|
|
22
|
+
p("update:modelValue", e === o.modelValue ? null : e);
|
|
22
23
|
}
|
|
23
|
-
return (e,
|
|
24
|
+
return (e, w) => (a(), s("div", b, [
|
|
24
25
|
(a(!0), s(y, null, f(d.value, (t) => (a(), n(i(V), {
|
|
25
26
|
key: t,
|
|
26
27
|
"open-delay": 100,
|
|
27
28
|
"close-delay": 100,
|
|
28
29
|
class: S(["has-inline-icon", {
|
|
29
|
-
active:
|
|
30
|
-
"temp-inactive": t === "export" && (
|
|
30
|
+
active: l.modelValue === t,
|
|
31
|
+
"temp-inactive": t === "export" && (l.graphStatus !== "ready" || l.chartType === "scatterplot-umap") || l.initialLoading && (t === "template" || t === "dataMapping" || t === "axes" || t === "statistics" || t === "layers"),
|
|
31
32
|
[t]: !0
|
|
32
33
|
}]),
|
|
33
34
|
position: "left",
|
|
34
|
-
hide:
|
|
35
|
-
onClick: (
|
|
36
|
-
|
|
35
|
+
hide: l.modelValue === t,
|
|
36
|
+
onClick: (h) => {
|
|
37
|
+
h.stopPropagation(), t === "export" ? e.$emit("export") : t === "delete" ? e.$emit("delete") : u(t);
|
|
37
38
|
}
|
|
38
39
|
}, {
|
|
39
40
|
tooltip: r(() => [
|
|
40
|
-
|
|
41
|
+
v("span", D, x(i(L)(t)), 1)
|
|
41
42
|
]),
|
|
42
43
|
default: r(() => [
|
|
43
|
-
(a(), n(
|
|
44
|
+
(a(), n(B(i(T)(t))))
|
|
44
45
|
]),
|
|
45
46
|
_: 2
|
|
46
47
|
}, 1032, ["class", "hide", "onClick"]))), 128))
|
|
@@ -48,6 +49,6 @@ const b = { class: "settings-tabs" }, D = { style: { "font-family": "var(--font-
|
|
|
48
49
|
}
|
|
49
50
|
});
|
|
50
51
|
export {
|
|
51
|
-
|
|
52
|
+
M as default
|
|
52
53
|
};
|
|
53
54
|
//# sourceMappingURL=index.vue.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.vue.js","sources":["../../../src/components/SettingsTabs/index.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport { ChartType } from '@milaboratories/pf-plots';\nimport { PlTooltip } from '@platforma-sdk/ui-vue';\nimport { computed } from 'vue';\nimport type { FormKey } from '../../forms';\nimport { resolveIcon, resolveTitle, tabKeys } from '../../forms';\nimport { GraphStatus } from '../../types';\n\nconst emit = defineEmits(['update:modelValue', 'export', 'delete']);\n\nconst props = defineProps<{\n chartType: ChartType
|
|
1
|
+
{"version":3,"file":"index.vue.js","sources":["../../../src/components/SettingsTabs/index.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type { ChartType } from '@milaboratories/pf-plots';\nimport { PlTooltip } from '@platforma-sdk/ui-vue';\nimport { computed } from 'vue';\nimport type { FormKey } from '../../forms';\nimport { resolveIcon, resolveTitle, tabKeys } from '../../forms';\nimport type { GraphStatus } from '../../types';\n\nconst emit = defineEmits(['update:modelValue', 'export', 'delete']);\n\nconst props = defineProps<{\n chartType: ChartType;\n graphStatus: GraphStatus;\n allowDeleting?: boolean;\n hasSettingsSlot?: boolean;\n hasAnnotationsSlot?: boolean;\n hasLogSlot?: boolean;\n initialLoading: boolean;\n modelValue: FormKey | null;\n}>();\n\nconst tabs = computed(() => tabKeys().filter((key) =>\n !(key === 'annotations' && !props.hasAnnotationsSlot)\n && !(key === 'settings' && !props.hasSettingsSlot)\n && !(key === 'log' && !props.hasLogSlot)\n && !(key === 'statistics' && props.chartType !== 'discrete' && props.chartType !== 'scatterplot')\n && !(key === 'delete' && props.allowDeleting),\n));\n\nfunction updateModel(v: string) {\n emit('update:modelValue', v === props.modelValue ? null : v);\n}\n</script>\n\n<template>\n <div class=\"settings-tabs\">\n <PlTooltip\n v-for=\"(name) in tabs\"\n :key=\"name\"\n :open-delay=\"100\"\n :close-delay=\"100\"\n class=\"has-inline-icon\"\n :class=\"{\n 'active': modelValue === name,\n 'temp-inactive':\n name === 'export' && (graphStatus !== 'ready' || chartType === 'scatterplot-umap') ||\n initialLoading && (name === 'template' || name === 'dataMapping' || name === 'axes' || name === 'statistics' || name === 'layers'),\n [name]: true\n }\"\n position=\"left\"\n :hide=\"modelValue === name\"\n @click=\"(e:Event) => {\n e.stopPropagation();\n name === 'export' ? $emit('export') :\n name === 'delete' ? $emit('delete') :\n updateModel(name)\n }\"\n >\n <component :is=\"resolveIcon(name)\"/>\n <template #tooltip>\n <span style=\"font-family: var(--font-family-base);\">\n {{ resolveTitle(name) }}\n </span>\n </template>\n </PlTooltip>\n </div>\n</template>\n"],"names":["emit","__emit","props","__props","tabs","computed","tabKeys","key","updateModel","v","_openBlock","_createElementBlock","_hoisted_1","_Fragment","_renderList","name","_createBlock","_unref","PlTooltip","e","$emit","_createElementVNode","_hoisted_2","_toDisplayString","resolveTitle","_resolveDynamicComponent","resolveIcon"],"mappings":";;;;;;;;;;;;;;;;;AAQA,UAAMA,IAAOC,GAEPC,IAAQC,GAWRC,IAAOC,EAAS,MAAMC,EAAA,EAAU;AAAA,MAAO,CAACC,MAC5C,EAAEA,MAAQ,iBAAiB,CAACL,EAAM,uBAC/B,EAAEK,MAAQ,cAAc,CAACL,EAAM,oBAC/B,EAAEK,MAAQ,SAAS,CAACL,EAAM,eAC1B,EAAEK,MAAQ,gBAAgBL,EAAM,cAAc,cAAcA,EAAM,cAAc,kBAChF,EAAEK,MAAQ,YAAYL,EAAM;AAAA,IAAA,CAChC;AAED,aAASM,EAAYC,GAAW;AAC9B,MAAAT,EAAK,qBAAqBS,MAAMP,EAAM,aAAa,OAAOO,CAAC;AAAA,IAC7D;sBAIEC,EAAA,GAAAC,EA8BM,OA9BNC,GA8BM;AAAA,cA7BJD,EA4BYE,GAAA,MAAAC,EA3BOV,EAAA,OAAI,CAAbW,YADVC,EA4BYC,EAAAC,CAAA,GAAA;AAAA,QA1BT,KAAKH;AAAA,QACL,cAAY;AAAA,QACZ,eAAa;AAAA,QACd,UAAM,mBAAiB;AAAA,UACK,QAAAZ,EAAA,eAAeY;AAAA,2BAAyCA,MAAI,aAAkBZ,EAAA,gBAAW,WAAgBA,EAAA,cAAS,uBAAsCA,EAAA,mBAAmBY,MAAI,cAAmBA,uBAA0BA,MAAI,UAAeA,MAAI,gBAAqBA,MAAI;AAAA,WAAyBA,CAAI,GAAA;AAAA,QAAA;QAOrU,UAAS;AAAA,QACR,MAAMZ,EAAA,eAAeY;AAAA,QACrB,UAAQI,MAAO;AAAe,UAAAA,EAAE,gBAAA,GAA2BJ,iBAAoBK,EAAAA,MAAK,QAAA,IAAqBL,iBAAoBK,EAAAA,MAAK,QAAA,IAAqBZ,EAAYO,CAAI;AAAA;;QAQ7J,WACT,MAEO;AAAA,UAFPM,EAEO,QAFPC,GAEOC,EADFN,EAAAO,CAAA,EAAaT,CAAI,CAAA,GAAA,CAAA;AAAA,QAAA;mBAHxB,MAAoC;AAAA,gBAApCC,EAAoCS,EAApBR,EAAAS,CAAA,EAAYX,CAAI,CAAA,CAAA;AAAA,QAAA;;;;;;"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as c, ref as
|
|
1
|
+
import { defineComponent as c, ref as s, computed as V, watch as m, createElementBlock as x, openBlock as y, withKeys as z, createElementVNode as d, withDirectives as N, createVNode as _, vModelText as g } from "vue";
|
|
2
2
|
import b from "../DoubleContourTemp.vue.js";
|
|
3
3
|
const k = { class: "zoom-text-field" }, $ = /* @__PURE__ */ c({
|
|
4
4
|
__name: "ZoomInput",
|
|
@@ -7,7 +7,7 @@ const k = { class: "zoom-text-field" }, $ = /* @__PURE__ */ c({
|
|
|
7
7
|
},
|
|
8
8
|
emits: ["update:modelValue"],
|
|
9
9
|
setup(p, { emit: v }) {
|
|
10
|
-
const f = v,
|
|
10
|
+
const f = v, u = p, r = s(), l = s(!1), o = s(String(u.modelValue)), a = V({
|
|
11
11
|
get() {
|
|
12
12
|
const t = o.value ?? "100";
|
|
13
13
|
return l.value ? t : t + "%";
|
|
@@ -18,25 +18,25 @@ const k = { class: "zoom-text-field" }, $ = /* @__PURE__ */ c({
|
|
|
18
18
|
});
|
|
19
19
|
return m(() => l.value, (t) => {
|
|
20
20
|
if (!t) {
|
|
21
|
-
|
|
22
|
-
isNaN(e) ? o.value = String(
|
|
21
|
+
const e = Number(o.value);
|
|
22
|
+
isNaN(e) ? o.value = String(u.modelValue) : f("update:modelValue", e);
|
|
23
23
|
}
|
|
24
|
-
}), m(() =>
|
|
24
|
+
}), m(() => u.modelValue, (t) => {
|
|
25
25
|
o.value = String(t);
|
|
26
26
|
}), (t, e) => (y(), x("div", {
|
|
27
27
|
class: "zoom-text-field__envelope zoom-input",
|
|
28
|
-
onFocusin: e[1] || (e[1] = (
|
|
29
|
-
onFocusout: e[2] || (e[2] = (
|
|
30
|
-
onKeyup: e[3] || (e[3] = z((
|
|
28
|
+
onFocusin: e[1] || (e[1] = (n) => l.value = !0),
|
|
29
|
+
onFocusout: e[2] || (e[2] = (n) => l.value = !1),
|
|
30
|
+
onKeyup: e[3] || (e[3] = z((n) => {
|
|
31
31
|
var i;
|
|
32
|
-
return (i =
|
|
32
|
+
return (i = r.value) == null ? void 0 : i.blur();
|
|
33
33
|
}, ["enter"]))
|
|
34
34
|
}, [
|
|
35
35
|
d("div", k, [
|
|
36
36
|
N(d("input", {
|
|
37
37
|
ref_key: "input",
|
|
38
|
-
ref:
|
|
39
|
-
"onUpdate:modelValue": e[0] || (e[0] = (
|
|
38
|
+
ref: r,
|
|
39
|
+
"onUpdate:modelValue": e[0] || (e[0] = (n) => a.value = n),
|
|
40
40
|
type: "text"
|
|
41
41
|
}, null, 512), [
|
|
42
42
|
[g, a.value]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ZoomInput.vue.js","sources":["../../../src/components/Zoom/ZoomInput.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport { computed, ref, watch } from 'vue';\nimport DoubleContour from '../DoubleContourTemp.vue';\n\nconst emit = defineEmits(['update:modelValue']);\n\nconst props = defineProps<{\n modelValue?: number;\n}>();\n\nconst input = ref<HTMLInputElement | undefined>();\n\nconst focused = ref(false);\n\nconst innerValue = ref(String(props.modelValue));\n\nconst value = computed({\n get() {\n const v = innerValue.value ?? '100';\n return focused.value ? v : v + '%';\n },\n set(v) {\n innerValue.value = v;\n return v;\n }
|
|
1
|
+
{"version":3,"file":"ZoomInput.vue.js","sources":["../../../src/components/Zoom/ZoomInput.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport { computed, ref, watch } from 'vue';\nimport DoubleContour from '../DoubleContourTemp.vue';\n\nconst emit = defineEmits(['update:modelValue']);\n\nconst props = defineProps<{\n modelValue?: number;\n}>();\n\nconst input = ref<HTMLInputElement | undefined>();\n\nconst focused = ref(false);\n\nconst innerValue = ref(String(props.modelValue));\n\nconst value = computed({\n get() {\n const v = innerValue.value ?? '100';\n return focused.value ? v : v + '%';\n },\n set(v) {\n innerValue.value = v;\n return v;\n },\n});\n\nwatch(() => focused.value, (f) => {\n if (!f) {\n const converted = Number(innerValue.value);\n if (!isNaN(converted)) {\n emit('update:modelValue', converted);\n } else {\n innerValue.value = String(props.modelValue);\n }\n }\n});\n\nwatch(() => props.modelValue, (v) => {\n innerValue.value = String(v);\n});\n\n</script>\n\n<template>\n <div\n class=\"zoom-text-field__envelope zoom-input\"\n @focusin=\"focused = true\"\n @focusout=\"focused = false\"\n @keyup.enter=\"input?.blur()\"\n >\n <div class=\"zoom-text-field\">\n <input ref=\"input\" v-model=\"value\" type=\"text\" />\n <DoubleContour style=\"z-index: 1;\" class=\"zoom-text-field__contour\" />\n </div>\n </div>\n</template>\n"],"names":["emit","__emit","props","__props","input","ref","focused","innerValue","value","computed","v","watch","f","converted","_createElementBlock","_cache","_withKeys","$event","_a","_createElementVNode","_hoisted_1","_createVNode","DoubleContour"],"mappings":";;;;;;;;;AAIA,UAAMA,IAAOC,GAEPC,IAAQC,GAIRC,IAAQC,EAAA,GAERC,IAAUD,EAAI,EAAK,GAEnBE,IAAaF,EAAI,OAAOH,EAAM,UAAU,CAAC,GAEzCM,IAAQC,EAAS;AAAA,MACrB,MAAM;AACJ,cAAMC,IAAIH,EAAW,SAAS;AAC9B,eAAOD,EAAQ,QAAQI,IAAIA,IAAI;AAAA,MACjC;AAAA,MACA,IAAIA,GAAG;AACL,eAAAH,EAAW,QAAQG,GACZA;AAAA,MACT;AAAA,IAAA,CACD;AAED,WAAAC,EAAM,MAAML,EAAQ,OAAO,CAACM,MAAM;AAChC,UAAI,CAACA,GAAG;AACN,cAAMC,IAAY,OAAON,EAAW,KAAK;AACzC,QAAK,MAAMM,CAAS,IAGlBN,EAAW,QAAQ,OAAOL,EAAM,UAAU,IAF1CF,EAAK,qBAAqBa,CAAS;AAAA,MAIvC;AAAA,IACF,CAAC,GAEDF,EAAM,MAAMT,EAAM,YAAY,CAACQ,MAAM;AACnC,MAAAH,EAAW,QAAQ,OAAOG,CAAC;AAAA,IAC7B,CAAC,mBAKCI,EAUM,OAAA;AAAA,MATJ,OAAM;AAAA,MACL,kCAASR,EAAA,QAAO;AAAA,MAChB,mCAAUA,EAAA,QAAO;AAAA,MACjB,SAAKS,EAAA,CAAA,MAAAA,EAAA,CAAA,IAAAC,EAAA,CAAAC,MAAA;;AAAQ,gBAAAC,IAAAd,EAAA,UAAA,gBAAAc,EAAO;AAAA,SAAI,CAAA,OAAA,CAAA;AAAA,IAAA;MAEzBC,EAGM,OAHNC,GAGM;AAAA,UAFJD,EAAiD,SAAA;AAAA,mBAAtC;AAAA,UAAJ,KAAIf;AAAA,wDAAiBI,EAAK,QAAAS;AAAA,UAAE,MAAK;AAAA,QAAA;cAAZT,EAAA,KAAK;AAAA,QAAA;QACjCa,EAAsEC,GAAA;AAAA,UAAvD,OAAA,EAAA,WAAA,IAAA;AAAA,UAAoB,OAAM;AAAA,QAAA;;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.vue.js","sources":["../../../src/components/Zoom/index.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport { PlBtnGhost } from
|
|
1
|
+
{"version":3,"file":"index.vue.js","sources":["../../../src/components/Zoom/index.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport { PlBtnGhost } from '@platforma-sdk/ui-vue';\nimport ZoomInput from './ZoomInput.vue';\nimport MinusIcon from '../../icons/MinusIcon.vue';\nimport PlusIcon from '../../icons/PlusIcon.vue';\nimport { useStore } from '../../store';\n\nconst store = useStore();\n\nconst MIN_CHART_SCALE = 20;\nconst MAX_CHART_SCALE = 400;\nconst CHART_SCALE_STEP = 10;\n\nfunction checkMinMax(value: number) {\n return Math.max(\n MIN_CHART_SCALE,\n Math.min(MAX_CHART_SCALE, value),\n );\n}\nfunction decreaseScale() {\n store.value.reactive.chartScale = checkMinMax(store.value.reactive.chartScale - CHART_SCALE_STEP);\n}\nfunction increaseScale() {\n store.value.reactive.chartScale = checkMinMax(store.value.reactive.chartScale + CHART_SCALE_STEP);\n}\n</script>\n\n<template>\n <div class=\"zoom-container\">\n <div class=\"zoom-border\"/>\n <PlBtnGhost @click=\"decreaseScale\">\n <component :is=\"MinusIcon\"/>\n </PlBtnGhost>\n <ZoomInput\n :modelValue=\"store.reactive.chartScale\"\n @update:modelValue=\"(v:number) => store.reactive.chartScale = checkMinMax(v)\"\n />\n <PlBtnGhost @click=\"increaseScale\">\n <component :is=\"PlusIcon\"/>\n </PlBtnGhost>\n </div>\n</template>\n"],"names":["MIN_CHART_SCALE","MAX_CHART_SCALE","CHART_SCALE_STEP","store","useStore","checkMinMax","value","decreaseScale","increaseScale","_openBlock","_createElementBlock","_hoisted_1","_createElementVNode","_createVNode","_unref","PlBtnGhost","_createBlock","_resolveDynamicComponent","MinusIcon","ZoomInput","_cache","v","PlusIcon"],"mappings":";;;;;;uCASMA,IAAkB,IAClBC,IAAkB,KAClBC,IAAmB;;;AAJzB,UAAMC,IAAQC,EAAA;AAMd,aAASC,EAAYC,GAAe;AAClC,aAAO,KAAK;AAAA,QACVN;AAAA,QACA,KAAK,IAAIC,GAAiBK,CAAK;AAAA,MAAA;AAAA,IAEnC;AACA,aAASC,IAAgB;AACvB,MAAAJ,EAAM,MAAM,SAAS,aAAaE,EAAYF,EAAM,MAAM,SAAS,aAAaD,CAAgB;AAAA,IAClG;AACA,aAASM,IAAgB;AACvB,MAAAL,EAAM,MAAM,SAAS,aAAaE,EAAYF,EAAM,MAAM,SAAS,aAAaD,CAAgB;AAAA,IAClG;sBAIEO,EAAA,GAAAC,EAYM,OAZNC,GAYM;AAAA,sBAXJC,EAA0B,OAAA,EAArB,OAAM,cAAA,GAAa,MAAA,EAAA;AAAA,MACxBC,EAEaC,EAAAC,CAAA,GAAA,EAFA,SAAOR,KAAa;AAAA,mBAC/B,MAA4B;AAAA,WAA5BE,KAAAO,EAA4BC,EAAZC,CAAS,CAAA;AAAA,QAAA;;;MAE3BL,EAGEM,GAAA;AAAA,QAFC,YAAYL,EAAAX,CAAA,EAAM,SAAS;AAAA,QAC3B,uBAAiBiB,EAAA,CAAA,MAAAA,EAAA,CAAA,IAAA,CAAGC,MAAaP,EAAAX,CAAA,EAAM,SAAS,aAAaE,EAAYgB,CAAC;AAAA,MAAA;MAE7ER,EAEaC,EAAAC,CAAA,GAAA,EAFA,SAAOP,KAAa;AAAA,mBAC/B,MAA2B;AAAA,WAA3BC,KAAAO,EAA2BC,EAAXK,CAAQ,CAAA;AAAA,QAAA;;;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useComponent.js","sources":["../../src/composition/useComponent.ts"],"sourcesContent":["import type {Component, Slots} from 'vue';\nimport {computed, h, unref} from 'vue';\nimport type {MaybeRef} from '@platforma-sdk/ui-vue';\n\nexport function NotFoundComponent(props: Record<string, unknown>, {slots}: { slots: Slots }) {\n return h('div', Object.assign({}, props, {\n class: 'non-found-component'
|
|
1
|
+
{"version":3,"file":"useComponent.js","sources":["../../src/composition/useComponent.ts"],"sourcesContent":["import type { Component, Slots } from 'vue';\nimport { computed, h, unref } from 'vue';\nimport type { MaybeRef } from '@platforma-sdk/ui-vue';\n\nexport function NotFoundComponent(props: Record<string, unknown>, { slots }: { slots: Slots }) {\n return h('div', Object.assign({}, props, {\n class: 'non-found-component',\n }), slots.default && slots.default());\n}\n\nexport function useComponent<K extends string>(dict: Record<K, Component | null>, keyRef: MaybeRef<K | null>) {\n return computed(() => {\n const key = unref(keyRef);\n return (key && dict[key]) ? dict[key] : NotFoundComponent;\n });\n}\n"],"names":["NotFoundComponent","props","slots","h","useComponent","dict","keyRef","computed","key","unref"],"mappings":";AAIO,SAASA,EAAkBC,GAAgC,EAAE,OAAAC,KAA2B;AAC7F,SAAOC,EAAE,OAAO,OAAO,OAAO,CAAA,GAAIF,GAAO;AAAA,IACvC,OAAO;AAAA,EAAA,CACR,GAAGC,EAAM,WAAWA,EAAM,SAAS;AACtC;AAEO,SAASE,EAA+BC,GAAmCC,GAA4B;AAC5G,SAAOC,EAAS,MAAM;AACpB,UAAMC,IAAMC,EAAMH,CAAM;AACxB,WAAQE,KAAOH,EAAKG,CAAG,IAAKH,EAAKG,CAAG,IAAIR;AAAA,EAC1C,CAAC;AACH;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constantsAesthetic.js","sources":["../src/constantsAesthetic.ts"],"sourcesContent":["import {\n CategoricalPalette, ContinuousPalette,\n DivergingPalette, DotShape, LineType, LineTypeInfo,\n Palette,\n PaletteInfo,\n SequentialPalette\n} from './components/AesSettings/types';\n\nexport const FIXED_COLORS: { name: string; color: string }[] = [\n { name: \"Light green\", color: \"#99E099\" },\n { name: \"Green\", color: \"#42B842\" },\n { name: \"Dark green\", color: \"#198020\" },\n { name: \"Light violet\", color: \"#C1ADFF\" },\n { name: \"Violet\", color: \"#845CFF\" },\n { name: \"Dark violet\", color: \"#5F31CC\" },\n { name: \"Light orange\", color: \"#FFCB8F\" },\n { name: \"Orange\", color: \"#FF9429\" },\n { name: \"Dark orange\", color: \"#C26A27\" },\n { name: \"Light teal\", color: \"#90E0E0\" },\n { name: \"Teal\", color: \"#27C2C2\" },\n { name: \"Dark teal\", color: \"#068A94\" },\n { name: \"Light rose\", color: \"#FAAAFA\" },\n { name: \"Rose\", color: \"#E553E5\" },\n { name: \"Dark rose\", color: \"#A324B2\" },\n { name: \"Light lime\", color: \"#CBEB67\" },\n { name: \"Lime\", color: \"#95C700\" },\n { name: \"Dark lime\", color: \"#659406\" },\n { name: \"Light blue\", color: \"#99CCFF\" },\n { name: \"Blue\", color: \"#2D93FA\" },\n { name: \"Dark blue\", color: \"#105BCC\" },\n { name: \"Light red\", color: \"#FFADBA\" },\n { name: \"Red\", color: \"#F05670\" },\n { name: \"Dark red\", color: \"#AD3757\" },\n { name: \"Light grey\", color: \"#D3D7E0\" },\n { name: \"Grey\", color: \"#929BAD\" },\n { name: \"Dark grey\", color: \"#5E5E70\" },\n { name: \"Black\", color: \"#110529\" },\n { name: \"White\", color: \"#FFFFFF\" },\n { name: \"None\", color: \"transparent\" },\n];\n\nexport const DEFAULT_WHITE = \"#FFFFFF\";\nexport const DEFAULT_BLACK = \"#110529\";\n\nexport const FIXED_COLORS_MAP = FIXED_COLORS.reduce(\n (res: Record<string, { name: string; color: string }>, item) => {\n res[item.color] = item;\n return res;\n },\n {},\n);\n\n// fixed colors without black, white, transparent - base for categorical palettes\nconst COLORS = FIXED_COLORS.slice(0, -3).map((el) => el.color);\n\nconst CATEGORICAL_LIGHT = COLORS.filter((_el, idx) => idx % 3 === 0);\nconst CATEGORICAL_BRIGHT = COLORS.filter((_el, idx) => idx % 3 === 1);\nconst CATEGORICAL_DARK = COLORS.filter((_el, idx) => idx % 3 === 2);\nconst CATEGORICAL_PAIRED = COLORS.filter((_el, idx) => idx % 3 !== 2);\nconst CATEGORICAL_TRIADIC = COLORS;\n\nconst VIRIDIS = [\"#FFF680\", \"#53D788\", \"#36739D\", \"#4A005C\"];\nconst MAGMA = [\"#FFF680\", \"#F77E5B\", \"#902B83\", \"#2B125C\"];\nconst DENSITY = [\"#DFFADC\", \"#74CFD1\", \"#635AC1\", \"#611347\"];\nconst SALINITY = [\"#FAFAB4\", \"#8DDA7F\", \"#337E90\", \"#1C0F5C\"];\nconst SUNSET = [\"#FFEA80\", \"#F07A76\", \"#7535A4\", \"#003752\"];\nconst PERCEPTUAL_RAINBOW = [\"#FFF780\", \"#6CEA90\", \"#6C90F0\", \"#942AAE\"];\n\nconst SPECTRUM = [\"#43317B\", \"#7ACFAC\", \"#F5F5B7\", \"#F07B75\", \"#5C1243\"];\nconst TEAL_RED = [\"#122B5C\", \"#41B5A8\", \"#F0F0F0\", \"#F07C80\", \"#5C1243\"];\nconst BLUE_RED = [\"#0E0E8F\", \"#7E93FB\", \"#F0F0F0\", \"#ED7883\", \"#5C1243\"];\nconst LIME_ROSE = [\"#2E5C00\", \"#9ED26A\", \"#F0F0F0\", \"#EB8BDB\", \"#701260\"];\nconst VIRIDIS_MAGMA = [\n \"#4A005C\",\n \"#36749D\",\n \"#56D688\",\n \"#FFF680\",\n \"#F77E5E\",\n \"#902B82\",\n \"#2B125C\",\n];\n\nexport const CATEGORICAL_LIST: CategoricalPalette[] = [\n \"light\",\n \"bright\",\n \"dark\",\n \"paired\",\n \"triadic\",\n];\nexport const SEQUENTIAL_LIST: SequentialPalette[] = [\n \"viridis\",\n \"magma\",\n \"density\",\n \"salinity\",\n \"sunset\",\n \"perceptual_rainbow\",\n];\nexport const DIVERGING_LIST: DivergingPalette[] = [\n \"spectrum\",\n \"teal_red\",\n \"blue_red\",\n \"lime_rose\",\n \"viridis_magma\",\n];\n\nexport function isCategorical(value: Palette): value is CategoricalPalette {\n return CATEGORICAL_LIST.includes(value as CategoricalPalette);\n}\n\nexport function isSequential(value: Palette): value is SequentialPalette {\n return SEQUENTIAL_LIST.includes(value as SequentialPalette);\n}\n\nexport function isDiverging(value: Palette): value is DivergingPalette {\n return DIVERGING_LIST.includes(value as DivergingPalette);\n}\n\nexport const CATEGORICAL_MAP: Record<CategoricalPalette, PaletteInfo> = {\n light: { title: \"Light\", colors: CATEGORICAL_LIGHT },\n bright: { title: \"Bright\", colors: CATEGORICAL_BRIGHT },\n dark: { title: \"Dark\", colors: CATEGORICAL_DARK },\n paired: { title: \"Paired\", colors: CATEGORICAL_PAIRED },\n triadic: { title: \"Triadic\", colors: CATEGORICAL_TRIADIC },\n};\nexport const SEQUENTIAL_MAP: Record<SequentialPalette, PaletteInfo> = {\n viridis: { title: \"Viridis\", colors: VIRIDIS },\n magma: { title: \"Magma\", colors: MAGMA },\n density: { title: \"Density\", colors: DENSITY },\n salinity: { title: \"Salinity\", colors: SALINITY },\n sunset: { title: \"Sunset\", colors: SUNSET },\n perceptual_rainbow: { title: \"Rainbow\", colors: PERCEPTUAL_RAINBOW },\n};\n\nexport const DIVERGING_MAP: Record<DivergingPalette, PaletteInfo> = {\n spectrum: { title: \"Spectrum\", colors: SPECTRUM },\n teal_red: { title: \"Teal-Red\", colors: TEAL_RED },\n blue_red: { title: \"Blue-Red\", colors: BLUE_RED },\n lime_rose: { title: \"Lime-Rose\", colors: LIME_ROSE },\n viridis_magma: { title: \"Vir-Mag\", colors: VIRIDIS_MAGMA },\n};\n\nexport const PALETTE_MAP: Record<Palette, PaletteInfo> = {\n ...CATEGORICAL_MAP,\n ...SEQUENTIAL_MAP,\n ...DIVERGING_MAP,\n};\n\nexport const DEFAULT_CATEGORICAL_PALETTE:CategoricalPalette = 'light'\nexport const DEFAULT_CONTINUOUS_PALETTE:ContinuousPalette = 'salinity'\nexport const DEFAULT_PALETTE: Palette = \"salinity\";\nexport const FIXES_DOT_SHAPES: DotShape[] = [\n '0', '5', '1', '2', '6',\n '7', '9', '3', '4', '8',\n '12', '10', '13', '14', '11',\n '22', '23', '21', '24', '25',\n];\n\nexport const UNKNOWN_COLOR = '#F0F0F0';\n\nexport const DEFAULT_DOT_SHAPE = '21' // filled circle\n\nexport const FIXED_LINE_TYPES:LineType[] = ['solid', 'dashed', 'dotted', 'dotdash', 'longdash', 'twodash'];\n\nexport const DEFAULT_LINE_TYPE:LineType = 'solid';\nexport const LINE_TYPES_MAP:Record<LineType, LineTypeInfo> = {\n solid: {title: 'Solid'},\n dashed: {title: 'Dashed'},\n dotted: {title: 'Dotted'},\n dotdash: {title: 'Dotdash'},\n longdash: {title: 'Longdash'},\n twodash: {title: 'Twodash'},\n}\n\nexport const NUCLEOTIDE_COLOR_MAPPING = {\n A: '#cc0100',\n C: '#0000cc',\n G: '#ffb300',\n T: '#027f00',\n U: '#027f00'\n}\n\nexport const AMINOACID_COLOR_MAPPING = {\n A: '#7fa0f0',\n R: '#ef1405',\n N: '#01ff00',\n D: '#c048bf',\n C: '#ef8080',\n Q: '#01ff00',\n E: '#c048bf',\n G: '#f09047',\n H: '#14a4a4',\n I: '#7fa0f0',\n L: '#7fa0f0',\n K: '#ef1405',\n M: '#7fa0f0',\n F: '#7fa0f0',\n P: '#ffff00',\n S: '#01ff00',\n T: '#01ff00',\n W: '#7fa0f0',\n Y: '#14a4a4',\n V: '#7fa0f0',\n B: '#eeeeee',\n X: '#eeeeee',\n Z: '#eeeeee'\n}"],"names":["FIXED_COLORS","DEFAULT_WHITE","DEFAULT_BLACK","res","item","COLORS","el","CATEGORICAL_LIGHT","_el","idx","CATEGORICAL_BRIGHT","CATEGORICAL_DARK","CATEGORICAL_PAIRED","CATEGORICAL_TRIADIC","VIRIDIS","MAGMA","DENSITY","SALINITY","SUNSET","PERCEPTUAL_RAINBOW","SPECTRUM","TEAL_RED","BLUE_RED","LIME_ROSE","VIRIDIS_MAGMA","CATEGORICAL_LIST","SEQUENTIAL_LIST","DIVERGING_LIST","isCategorical","value","CATEGORICAL_MAP","SEQUENTIAL_MAP","DIVERGING_MAP","PALETTE_MAP","DEFAULT_CATEGORICAL_PALETTE","DEFAULT_CONTINUOUS_PALETTE","DEFAULT_PALETTE","FIXES_DOT_SHAPES","UNKNOWN_COLOR","DEFAULT_DOT_SHAPE","FIXED_LINE_TYPES","DEFAULT_LINE_TYPE","LINE_TYPES_MAP","NUCLEOTIDE_COLOR_MAPPING","AMINOACID_COLOR_MAPPING"],"mappings":"AAQO,MAAMA,IAAkD;AAAA,EAC7D,EAAE,MAAM,eAAe,OAAO,UAAA;AAAA,EAC9B,EAAE,MAAM,SAAS,OAAO,UAAA;AAAA,EACxB,EAAE,MAAM,cAAc,OAAO,UAAA;AAAA,EAC7B,EAAE,MAAM,gBAAgB,OAAO,UAAA;AAAA,EAC/B,EAAE,MAAM,UAAU,OAAO,UAAA;AAAA,EACzB,EAAE,MAAM,eAAe,OAAO,UAAA;AAAA,EAC9B,EAAE,MAAM,gBAAgB,OAAO,UAAA;AAAA,EAC/B,EAAE,MAAM,UAAU,OAAO,UAAA;AAAA,EACzB,EAAE,MAAM,eAAe,OAAO,UAAA;AAAA,EAC9B,EAAE,MAAM,cAAc,OAAO,UAAA;AAAA,EAC7B,EAAE,MAAM,QAAQ,OAAO,UAAA;AAAA,EACvB,EAAE,MAAM,aAAa,OAAO,UAAA;AAAA,EAC5B,EAAE,MAAM,cAAc,OAAO,UAAA;AAAA,EAC7B,EAAE,MAAM,QAAQ,OAAO,UAAA;AAAA,EACvB,EAAE,MAAM,aAAa,OAAO,UAAA;AAAA,EAC5B,EAAE,MAAM,cAAc,OAAO,UAAA;AAAA,EAC7B,EAAE,MAAM,QAAQ,OAAO,UAAA;AAAA,EACvB,EAAE,M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,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AACL;"}
|
|
1
|
+
{"version":3,"file":"constantsAesthetic.js","sources":["../src/constantsAesthetic.ts"],"sourcesContent":["import type {\n CategoricalPalette, ContinuousPalette,\n DivergingPalette, DotShape, LineType, LineTypeInfo,\n Palette,\n PaletteInfo,\n SequentialPalette,\n} from './components/AesSettings/types';\n\nexport const FIXED_COLORS: { name: string; color: string }[] = [\n { name: 'Light green', color: '#99E099' },\n { name: 'Green', color: '#42B842' },\n { name: 'Dark green', color: '#198020' },\n { name: 'Light violet', color: '#C1ADFF' },\n { name: 'Violet', color: '#845CFF' },\n { name: 'Dark violet', color: '#5F31CC' },\n { name: 'Light orange', color: '#FFCB8F' },\n { name: 'Orange', color: '#FF9429' },\n { name: 'Dark orange', color: '#C26A27' },\n { name: 'Light teal', color: '#90E0E0' },\n { name: 'Teal', color: '#27C2C2' },\n { name: 'Dark teal', color: '#068A94' },\n { name: 'Light rose', color: '#FAAAFA' },\n { name: 'Rose', color: '#E553E5' },\n { name: 'Dark rose', color: '#A324B2' },\n { name: 'Light lime', color: '#CBEB67' },\n { name: 'Lime', color: '#95C700' },\n { name: 'Dark lime', color: '#659406' },\n { name: 'Light blue', color: '#99CCFF' },\n { name: 'Blue', color: '#2D93FA' },\n { name: 'Dark blue', color: '#105BCC' },\n { name: 'Light red', color: '#FFADBA' },\n { name: 'Red', color: '#F05670' },\n { name: 'Dark red', color: '#AD3757' },\n { name: 'Light grey', color: '#D3D7E0' },\n { name: 'Grey', color: '#929BAD' },\n { name: 'Dark grey', color: '#5E5E70' },\n { name: 'Black', color: '#110529' },\n { name: 'White', color: '#FFFFFF' },\n { name: 'None', color: 'transparent' },\n];\n\nexport const DEFAULT_WHITE = '#FFFFFF';\nexport const DEFAULT_BLACK = '#110529';\n\nexport const FIXED_COLORS_MAP = FIXED_COLORS.reduce(\n (res: Record<string, { name: string; color: string }>, item) => {\n res[item.color] = item;\n return res;\n },\n {},\n);\n\n// fixed colors without black, white, transparent - base for categorical palettes\nconst COLORS = FIXED_COLORS.slice(0, -3).map((el) => el.color);\n\nconst CATEGORICAL_LIGHT = COLORS.filter((_el, idx) => idx % 3 === 0);\nconst CATEGORICAL_BRIGHT = COLORS.filter((_el, idx) => idx % 3 === 1);\nconst CATEGORICAL_DARK = COLORS.filter((_el, idx) => idx % 3 === 2);\nconst CATEGORICAL_PAIRED = COLORS.filter((_el, idx) => idx % 3 !== 2);\nconst CATEGORICAL_TRIADIC = COLORS;\n\nconst VIRIDIS = ['#FFF680', '#53D788', '#36739D', '#4A005C'];\nconst MAGMA = ['#FFF680', '#F77E5B', '#902B83', '#2B125C'];\nconst DENSITY = ['#DFFADC', '#74CFD1', '#635AC1', '#611347'];\nconst SALINITY = ['#FAFAB4', '#8DDA7F', '#337E90', '#1C0F5C'];\nconst SUNSET = ['#FFEA80', '#F07A76', '#7535A4', '#003752'];\nconst PERCEPTUAL_RAINBOW = ['#FFF780', '#6CEA90', '#6C90F0', '#942AAE'];\n\nconst SPECTRUM = ['#43317B', '#7ACFAC', '#F5F5B7', '#F07B75', '#5C1243'];\nconst TEAL_RED = ['#122B5C', '#41B5A8', '#F0F0F0', '#F07C80', '#5C1243'];\nconst BLUE_RED = ['#0E0E8F', '#7E93FB', '#F0F0F0', '#ED7883', '#5C1243'];\nconst LIME_ROSE = ['#2E5C00', '#9ED26A', '#F0F0F0', '#EB8BDB', '#701260'];\nconst VIRIDIS_MAGMA = [\n '#4A005C',\n '#36749D',\n '#56D688',\n '#FFF680',\n '#F77E5E',\n '#902B82',\n '#2B125C',\n];\n\nexport const CATEGORICAL_LIST: CategoricalPalette[] = [\n 'light',\n 'bright',\n 'dark',\n 'paired',\n 'triadic',\n];\nexport const SEQUENTIAL_LIST: SequentialPalette[] = [\n 'viridis',\n 'magma',\n 'density',\n 'salinity',\n 'sunset',\n 'perceptual_rainbow',\n];\nexport const DIVERGING_LIST: DivergingPalette[] = [\n 'spectrum',\n 'teal_red',\n 'blue_red',\n 'lime_rose',\n 'viridis_magma',\n];\n\nexport function isCategorical(value: Palette): value is CategoricalPalette {\n return CATEGORICAL_LIST.includes(value as CategoricalPalette);\n}\n\nexport function isSequential(value: Palette): value is SequentialPalette {\n return SEQUENTIAL_LIST.includes(value as SequentialPalette);\n}\n\nexport function isDiverging(value: Palette): value is DivergingPalette {\n return DIVERGING_LIST.includes(value as DivergingPalette);\n}\n\nexport const CATEGORICAL_MAP: Record<CategoricalPalette, PaletteInfo> = {\n light: { title: 'Light', colors: CATEGORICAL_LIGHT },\n bright: { title: 'Bright', colors: CATEGORICAL_BRIGHT },\n dark: { title: 'Dark', colors: CATEGORICAL_DARK },\n paired: { title: 'Paired', colors: CATEGORICAL_PAIRED },\n triadic: { title: 'Triadic', colors: CATEGORICAL_TRIADIC },\n};\nexport const SEQUENTIAL_MAP: Record<SequentialPalette, PaletteInfo> = {\n viridis: { title: 'Viridis', colors: VIRIDIS },\n magma: { title: 'Magma', colors: MAGMA },\n density: { title: 'Density', colors: DENSITY },\n salinity: { title: 'Salinity', colors: SALINITY },\n sunset: { title: 'Sunset', colors: SUNSET },\n perceptual_rainbow: { title: 'Rainbow', colors: PERCEPTUAL_RAINBOW },\n};\n\nexport const DIVERGING_MAP: Record<DivergingPalette, PaletteInfo> = {\n spectrum: { title: 'Spectrum', colors: SPECTRUM },\n teal_red: { title: 'Teal-Red', colors: TEAL_RED },\n blue_red: { title: 'Blue-Red', colors: BLUE_RED },\n lime_rose: { title: 'Lime-Rose', colors: LIME_ROSE },\n viridis_magma: { title: 'Vir-Mag', colors: VIRIDIS_MAGMA },\n};\n\nexport const PALETTE_MAP: Record<Palette, PaletteInfo> = {\n ...CATEGORICAL_MAP,\n ...SEQUENTIAL_MAP,\n ...DIVERGING_MAP,\n};\n\nexport const DEFAULT_CATEGORICAL_PALETTE: CategoricalPalette = 'light';\nexport const DEFAULT_CONTINUOUS_PALETTE: ContinuousPalette = 'salinity';\nexport const DEFAULT_PALETTE: Palette = 'salinity';\nexport const FIXES_DOT_SHAPES: DotShape[] = [\n '0', '5', '1', '2', '6',\n '7', '9', '3', '4', '8',\n '12', '10', '13', '14', '11',\n '22', '23', '21', '24', '25',\n];\n\nexport const UNKNOWN_COLOR = '#F0F0F0';\n\nexport const DEFAULT_DOT_SHAPE = '21'; // filled circle\n\nexport const FIXED_LINE_TYPES: LineType[] = ['solid', 'dashed', 'dotted', 'dotdash', 'longdash', 'twodash'];\n\nexport const DEFAULT_LINE_TYPE: LineType = 'solid';\nexport const LINE_TYPES_MAP: Record<LineType, LineTypeInfo> = {\n solid: { title: 'Solid' },\n dashed: { title: 'Dashed' },\n dotted: { title: 'Dotted' },\n dotdash: { title: 'Dotdash' },\n longdash: { title: 'Longdash' },\n twodash: { title: 'Twodash' },\n};\n\nexport const NUCLEOTIDE_COLOR_MAPPING = {\n A: '#cc0100',\n C: '#0000cc',\n G: '#ffb300',\n T: '#027f00',\n U: '#027f00',\n};\n\nexport const AMINOACID_COLOR_MAPPING = {\n A: '#7fa0f0',\n R: '#ef1405',\n N: '#01ff00',\n D: '#c048bf',\n C: '#ef8080',\n Q: '#01ff00',\n E: '#c048bf',\n G: '#f09047',\n H: '#14a4a4',\n I: '#7fa0f0',\n L: '#7fa0f0',\n K: '#ef1405',\n M: '#7fa0f0',\n F: '#7fa0f0',\n P: '#ffff00',\n S: '#01ff00',\n T: '#01ff00',\n W: '#7fa0f0',\n Y: '#14a4a4',\n V: '#7fa0f0',\n B: '#eeeeee',\n X: '#eeeeee',\n Z: '#eeeeee',\n};\n"],"names":["FIXED_COLORS","DEFAULT_WHITE","DEFAULT_BLACK","res","item","COLORS","el","CATEGORICAL_LIGHT","_el","idx","CATEGORICAL_BRIGHT","CATEGORICAL_DARK","CATEGORICAL_PAIRED","CATEGORICAL_TRIADIC","VIRIDIS","MAGMA","DENSITY","SALINITY","SUNSET","PERCEPTUAL_RAINBOW","SPECTRUM","TEAL_RED","BLUE_RED","LIME_ROSE","VIRIDIS_MAGMA","CATEGORICAL_LIST","SEQUENTIAL_LIST","DIVERGING_LIST","isCategorical","value","CATEGORICAL_MAP","SEQUENTIAL_MAP","DIVERGING_MAP","PALETTE_MAP","DEFAULT_CATEGORICAL_PALETTE","DEFAULT_CONTINUOUS_PALETTE","DEFAULT_PALETTE","FIXES_DOT_SHAPES","UNKNOWN_COLOR","DEFAULT_DOT_SHAPE","FIXED_LINE_TYPES","DEFAULT_LINE_TYPE","LINE_TYPES_MAP","NUCLEOTIDE_COLOR_MAPPING","AMINOACID_COLOR_MAPPING"],"mappings":"AAQO,MAAMA,IAAkD;AAAA,EAC7D,EAAE,MAAM,eAAe,OAAO,UAAA;AAAA,EAC9B,EAAE,MAAM,SAAS,OAAO,UAAA;AAAA,EACxB,EAAE,MAAM,cAAc,OAAO,UAAA;AAAA,EAC7B,EAAE,MAAM,gBAAgB,OAAO,UAAA;AAAA,EAC/B,EAAE,MAAM,UAAU,OAAO,UAAA;AAAA,EACzB,EAAE,MAAM,eAAe,OAAO,UAAA;AAAA,EAC9B,EAAE,MAAM,gBAAgB,OAAO,UAAA;AAAA,EAC/B,EAAE,MAAM,UAAU,OAAO,UAAA;AAAA,EACzB,EAAE,MAAM,eAAe,OAAO,UAAA;AAAA,EAC9B,EAAE,MAAM,cAAc,OAAO,UAAA;AAAA,EAC7B,EAAE,MAAM,QAAQ,OAAO,UAAA;AAAA,EACvB,EAAE,MAAM,aAAa,OAAO,UAAA;AAAA,EAC5B,EAAE,MAAM,cAAc,OAAO,UAAA;AAAA,EAC7B,EAAE,MAAM,QAAQ,OAAO,UAAA;AAAA,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,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AACL,GAEaC,IAA0B;AAAA,EACrC,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AACL;"}
|
package/dist/constantsCommon.js
CHANGED
|
@@ -130,7 +130,7 @@ function Ve(o) {
|
|
|
130
130
|
return typeof o < "u" && o !== null && typeof o == "object" && "range" in o;
|
|
131
131
|
}
|
|
132
132
|
const ce = () => ({
|
|
133
|
-
//bubble
|
|
133
|
+
// bubble
|
|
134
134
|
bubble: {
|
|
135
135
|
NAValueAs: 0,
|
|
136
136
|
strokeColor: null,
|
|
@@ -147,7 +147,7 @@ const ce = () => ({
|
|
|
147
147
|
fillColor: null,
|
|
148
148
|
opacity: 1
|
|
149
149
|
},
|
|
150
|
-
//dendro
|
|
150
|
+
// dendro
|
|
151
151
|
dendro: {
|
|
152
152
|
dotFill: u,
|
|
153
153
|
dotShape: s,
|
|
@@ -158,7 +158,7 @@ const ce = () => ({
|
|
|
158
158
|
showTable: !1,
|
|
159
159
|
showLegend: !0
|
|
160
160
|
},
|
|
161
|
-
//heatmap
|
|
161
|
+
// heatmap
|
|
162
162
|
heatmap: {
|
|
163
163
|
NAValueAs: 0,
|
|
164
164
|
normalizationDirection: "row",
|
|
@@ -179,14 +179,14 @@ const ce = () => ({
|
|
|
179
179
|
aggregateByY: !1,
|
|
180
180
|
aggregationMethod: "mean"
|
|
181
181
|
},
|
|
182
|
-
//scatterplot
|
|
182
|
+
// scatterplot
|
|
183
183
|
dots: {
|
|
184
184
|
dotFill: null,
|
|
185
185
|
dotShape: null,
|
|
186
186
|
dotSize: null
|
|
187
187
|
},
|
|
188
188
|
curve: { lineColor: u, smoothing: !0 },
|
|
189
|
-
//discrete
|
|
189
|
+
// discrete
|
|
190
190
|
box: {
|
|
191
191
|
showOutliers: !0,
|
|
192
192
|
fillColor: null,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constantsCommon.js","sources":["../src/constantsCommon.ts"],"sourcesContent":["import type { ChartType } from '@milaboratories/pf-plots';\nimport type { Component } from 'vue';\nimport {\n DotShape,\n LineType\n} from './components/AesSettings/types';\nimport {\n DEFAULT_BLACK,\n DEFAULT_DOT_SHAPE,\n DEFAULT_LINE_TYPE\n} from './constantsAesthetic';\nimport { DEFAULT_DOT_SIZE, DEFAULT_LINE_COLOR } from './dataBindAes';\nimport BarAndErrorIcon from './icons/BarAndErrorIcon.vue';\nimport BarAndLineIcon from './icons/BarAndLineIcon.vue';\nimport BarIcon from './icons/BarIcon.vue';\nimport BinnedDotsIcon from './icons/BinnedDotsIcon.vue';\nimport BoxplotAndBinnedIcon from './icons/BoxplotAndBinnedIcon.vue';\nimport BoxplotAndJitterIcon from './icons/BoxplotAndJitterIcon.vue';\nimport BoxplotIcon from './icons/BoxplotIcon.vue';\nimport DendroIcon from './icons/DendroIcon.vue';\nimport HeatmapIcon from './icons/HeatmapIcon.vue';\nimport JitteredDotsIcon from './icons/JitteredDotsIcon.vue';\nimport LineAndBinnedIcon from './icons/LineAndBinnedIcon.vue';\nimport LineAndErrorbarIcon from './icons/LineAndErrorbarIcon.vue';\nimport LineAndJitterIcon from './icons/LineAndJitterIcon.vue';\nimport LineIcon from './icons/LineIcon.vue';\nimport LogoIcon from './icons/LogoIcon.vue';\nimport ScatterplotIcon from './icons/ScatterplotIcon.vue';\nimport SinaIcon from './icons/SinaIcon.vue';\nimport StackedBarIcon from './icons/StackedBarIcon.vue';\nimport StackedAreaIcon from './icons/StackedAreaIcon.vue';\nimport ViolinAndBinnedIcon from './icons/ViolinAndBinnedIcon.vue';\nimport ViolinAndJitterIcon from './icons/ViolinAndJitterIcon.vue';\nimport ViolinIcon from './icons/ViolinIcon.vue';\nimport {\n AxisTitleMode,\n DeepPartial,\n DiscreteLayer,\n DiscreteLayersTemplate,\n Frame,\n HeatmapFrame, HeatmapLayer, HeatmapLayerTemplate, HistogramLayer, HistogramLayerTemplate,\n LabelsPosition,\n LabelsRotation,\n Layer,\n LayersTemplate,\n Scale,\n ScatterplotLayer,\n ScatterplotLayersTemplate,\n TitlePosition\n} from './types';\n\nexport const DEFAULT_CHART_TYPE: ChartType = 'discrete';\n\nexport function getInitialTemplate(\n restoredTemplate: LayersTemplate | null,\n chartType: ChartType\n) {\n if (chartType === 'discrete') {\n return restoredTemplate &&\n DISCRETE_TEMPLATES_MAP[restoredTemplate as DiscreteLayersTemplate]\n ? restoredTemplate\n : 'box';\n }\n if (chartType === 'scatterplot' || chartType === 'scatterplot-umap') {\n return restoredTemplate &&\n SCATTERPLOT_TEMPLATES_MAP[restoredTemplate as ScatterplotLayersTemplate]\n ? restoredTemplate\n : 'dots';\n }\n if (chartType === 'dendro') {\n return 'dendro';\n }\n return restoredTemplate ?? 'heatmap';\n}\n\nexport const DISCRETE_TEMPLATES_MAP: Record<\n DiscreteLayersTemplate,\n DiscreteLayer[]\n> = {\n box: ['box'],\n box_binnedDots: ['box', 'binnedDots'],\n box_jitteredDots: ['box', 'jitteredDots'],\n violin: ['violin'],\n violin_binnedDots: ['violin', 'binnedDots'],\n violin_jitteredDots: ['violin', 'jitteredDots'],\n binnedDots: ['binnedDots'],\n jitteredDots: ['jitteredDots'],\n bar: ['bar'],\n bar_line: ['bar', 'line'],\n bar_errorbar: ['bar', 'errorbar'],\n stackedBar: ['stackedBar'],\n stackedArea: ['stackedArea'],\n line: ['line'],\n line_jitteredDots: ['line', 'jitteredDots'],\n line_binnedDots: ['line', 'binnedDots'],\n line_errorbar: ['line', 'errorbar'],\n errorbar: ['errorbar'],\n sina: ['sina'],\n logo: ['logo']\n};\n\nexport const SCATTERPLOT_TEMPLATES_MAP: Record<\n ScatterplotLayersTemplate,\n ScatterplotLayer[]\n> = {\n dots: ['dots'],\n curve: ['curve'],\n curve_dots: ['curve', 'dots']\n};\n\nexport const SCATTERPLOT_UMAP_TEMPLATES_MAP: Partial<Record<\n ScatterplotLayersTemplate,\n ScatterplotLayer[]\n>> = {\n dots: ['dots'],\n curve_dots: ['curve', 'dots']\n};\n\nexport const HEATMAP_TEMPLATES_MAP: Record<HeatmapLayerTemplate, HeatmapLayer[]> = {\n heatmap: ['heatmap'],\n heatmapClustered: ['heatmapClustered']\n};\nexport const HISTOGRAM_TEMPLATES_MAP: Record<HistogramLayerTemplate, HistogramLayer[]> = {\n bins: ['bins']\n}\nexport const LAYER_TITLES: Record<Layer, string> = {\n box: 'Boxplot',\n binnedDots: 'Binned Dots',\n jitteredDots: 'Jittered Dots',\n violin: 'Violins',\n bar: 'Bar',\n stackedBar: 'Stacked Bar',\n stackedArea: 'Stacked Bar + Stream Area',\n line: 'Line',\n errorbar: 'Error Bar',\n sina: 'Sina',\n logo: 'Logo Plot',\n dots: 'Scatter Plot',\n curve: 'Curve',\n heatmap: 'Heatmap',\n heatmapClustered: 'Heatmap + Dendro',\n dendro: 'Dendrogram',\n bins: 'Histogram',\n bubble: 'Bubble plot'\n};\n\nexport type DiscreteStatisticsState = {\n overall: {\n data: { testMethod: null | string };\n validity: { testMethod: boolean };\n };\n referenceGroup: {\n data: {\n testMethod: null | string;\n referenceGroup: null | string;\n correctionMethod: string;\n format: 'significance' | 'pValue';\n ns: boolean;\n };\n validity: {\n testMethod: boolean;\n referenceGroup: boolean;\n };\n };\n pairwise: {\n data: {\n testMethod: null | string;\n correctionMethod: string;\n format: 'significance' | 'pValue';\n ns: boolean;\n };\n validity: { testMethod: boolean };\n };\n};\n\nexport type ScatterplotStatisticsState = {\n trend: {\n on: boolean,\n trim: boolean,\n showLegend: boolean\n },\n}\n\nexport type StatisticsState = DiscreteStatisticsState | ScatterplotStatisticsState;\n\nexport function getInitialStatisticsState(chartType: ChartType, initialData?: DeepPartial<StatisticsState>): StatisticsState {\n if (chartType === 'discrete') {\n const initial = initialData as DiscreteStatisticsState;\n return {\n overall: {\n data: { testMethod: initial?.overall?.data?.testMethod ?? null },\n validity: { testMethod: initial?.overall?.validity?.testMethod ?? true }\n },\n referenceGroup: {\n data: {\n testMethod: initial?.referenceGroup?.data?.testMethod ?? null,\n referenceGroup: initial?.referenceGroup?.data?.referenceGroup ?? null,\n correctionMethod: initial?.referenceGroup?.data?.correctionMethod ?? 'Bonferroni',\n format: initial?.referenceGroup?.data?.format ?? 'significance',\n ns: initial?.referenceGroup?.data?.ns ?? false\n },\n validity: {\n testMethod: initial?.referenceGroup?.validity?.testMethod ?? true,\n referenceGroup: initial?.referenceGroup?.validity?.referenceGroup ?? true\n }\n },\n pairwise: {\n data: {\n testMethod: initial?.pairwise?.data?.testMethod ?? null,\n correctionMethod: initial?.pairwise?.data?.correctionMethod ?? 'Bonferroni',\n format: initial?.pairwise?.data?.format ?? 'significance',\n ns: initial?.pairwise?.data?.ns ?? false\n },\n validity: { testMethod: initial?.pairwise?.validity?.testMethod ?? true }\n }\n } as DiscreteStatisticsState;\n }\n const initial = initialData as ScatterplotStatisticsState;\n return {\n trend: {\n on: initial?.trend?.on ?? false,\n trim: initial?.trend?.trim ?? false,\n showLegend: initial?.trend?.showLegend ?? true\n }\n };\n}\n\nexport type NumberRange = { min: number, max: number }\nexport type MappingLink = { type: string, value?: string }; // {type: 'primaryGrouping'} for example\nexport type ColorAes = string | MappingLink;\nexport type DotShapeAes = DotShape | MappingLink;\nexport type DotSizeAes = number | NumberRange;\nexport type LineTypeAes = LineType | MappingLink;\nexport type FixedOrMappedAes = ColorAes | DotShapeAes | LineTypeAes;\n\nexport type ContinuousDataMappingSize = {\n column: string,\n range: NumberRange\n}\n\nexport type ContinuousDataMappingForGraph<T extends string | number> = {columnName: ColumnNameSchema, domain: number[], range: T[], type: 'linear' | 'log'}\n\nexport type ColumnNameSchema = {\n type: 'column'\n value: string,\n label?: string\n valueLabels?: string\n}\n\nexport function isNumberRange(v: number | NumberRange | null | undefined): v is NumberRange {\n return typeof v !== 'undefined' && v !== null && typeof v === 'object' && 'min' in v && 'max' in v;\n}\n\nexport function isMappedAes(\n item: FixedOrMappedAes | null | string | number | boolean | unknown\n): item is MappingLink {\n return typeof item === 'object' && item !== null && 'type' in item;\n}\n\nexport function isContinuousDataMapping(v: ContinuousDataMappingSize | MappingLink | number | string | null | undefined): v is ContinuousDataMappingSize {\n return typeof v !== 'undefined' && v !== null && typeof v === 'object' && 'range' in v;\n}\n\nexport type LayersSettings = {\n //bubble\n bubble: {\n NAValueAs: number | null,\n minRadius: number,\n maxRadius: number,\n normalizationDirection: 'row' | 'column' | null,\n normalizationMethod: 'standardScaling' | 'meanNormalization',\n aggregateByX: boolean;\n aggregateByY: boolean;\n aggregationMethod: 'mean' | 'median' | 'min' | 'max';\n strokeColor: null | string\n },\n // histogram\n bins: {\n fillColor: ColorAes | null,\n opacity: number\n },\n //dendrogram\n dendro: {\n dotFill: ColorAes,\n dotShape: DotShapeAes,\n dotSize: DotSizeAes,\n lineColor: ColorAes,\n mode: 'normal' | 'useAllNodesAsLeaves',\n leavesMode: 'normal' | 'alignLeavesToLine',\n showTable: boolean,\n showLegend: boolean,\n },\n //heatmap\n heatmap: {\n NAValueAs: number | null,\n normalizationDirection: 'row' | 'column' | null,\n normalizationMethod: 'standardScaling' | 'meanNormalization',\n aggregateByX: boolean;\n aggregateByY: boolean;\n aggregationMethod: 'mean' | 'median' | 'min' | 'max'\n },\n heatmapClustered: {\n NAValueAs: number | null,\n normalizationDirection: 'row' | 'column' | null,\n normalizationMethod: 'standardScaling' | 'meanNormalization',\n dendrogramX: boolean,\n dendrogramY: boolean,\n disableClusteringX: boolean,\n disableClusteringY: boolean,\n aggregateByX: boolean;\n aggregateByY: boolean;\n aggregationMethod: 'mean' | 'median' | 'min' | 'max'\n },\n //scatterplot\n dots: {\n dotFill: ColorAes | null,\n dotShape: DotShapeAes | null,\n dotSize: ContinuousDataMappingSize | number | null\n },\n curve: {\n smoothing: boolean,\n lineColor: ColorAes\n },\n //discrete\n box: {\n showOutliers: boolean,\n fillColor: ColorAes | null,\n lineColor: ColorAes,\n dotShape: DotShapeAes,\n lineType: LineTypeAes,\n gapWidth: number,\n opacity: number,\n stat: {\n low: number,\n middle: number,\n upper: number,\n k: number,\n },\n },\n binnedDots: {\n fillColor: ColorAes | null,\n lineColor: ColorAes,\n opacity: number,\n showOutliers: boolean,\n },\n jitteredDots: {\n dotFill: ColorAes | null,\n dotShape: DotShapeAes,\n lineColor: ColorAes,\n opacity: number,\n showOutliers: boolean,\n },\n violin: {\n fillColor: ColorAes | null,\n lineColor: ColorAes,\n lineType: LineTypeAes,\n opacity: number,\n trim: boolean,\n showQuartiles: boolean,\n quartilesLineStyle: LineType,\n medianLineStyle: LineType\n },\n bar: {\n fillColor: ColorAes | null,\n lineColor: ColorAes,\n opacity: number,\n height: 'max' | 'mean' | 'median',\n },\n stackedBar: {\n fillColor: ColorAes | null,\n lineColor: ColorAes,\n opacity: number,\n normalize: boolean,\n height: 'sum' | 'max' | 'mean' | 'median',\n },\n stackedArea: {\n fillColor: ColorAes | null,\n lineColor: ColorAes,\n barsOpacity: number,\n areaOpacity: number,\n normalize: boolean,\n height: 'sum' | 'max' | 'mean' | 'median',\n showBars: boolean\n },\n line: {\n pointsValues: 'mean' | 'median',\n emptyGroupValue: number,\n lineColor: ColorAes | null,\n dotShape: DotShapeAes,\n lineType: LineTypeAes,\n dotFill: ColorAes | null,\n opacity: number,\n },\n errorbar: {\n pointsValues: 'mean' | 'median',\n interval: 'sd' | 'se' | '',\n lineColor: ColorAes | null,\n dotShape: DotShapeAes,\n dotFill: ColorAes | null,\n opacity: number,\n },\n sina: {\n dotFill: ColorAes | null,\n dotShape: DotShapeAes,\n opacity: number,\n showOutliers: boolean,\n },\n logo: {\n normalize: boolean,\n opacity: number,\n }\n};\nexport const DEFAULT_LAYERS_SETTINGS: () => LayersSettings = () => ({\n //bubble\n bubble: {\n NAValueAs: 0,\n strokeColor: null,\n minRadius: 3,\n maxRadius: 38,\n normalizationDirection: 'row',\n normalizationMethod: 'standardScaling',\n aggregateByX: false,\n aggregateByY: false,\n aggregationMethod: 'mean'\n },\n // histogram\n bins: {\n fillColor: null,\n opacity: 1\n },\n //dendro\n dendro: {\n dotFill: DEFAULT_BLACK,\n dotShape: DEFAULT_DOT_SHAPE,\n dotSize: DEFAULT_DOT_SIZE,\n lineColor: DEFAULT_BLACK,\n mode: 'normal',\n leavesMode: 'normal',\n showTable: false,\n showLegend: true\n },\n //heatmap\n heatmap: {\n NAValueAs: 0,\n normalizationDirection: 'row',\n normalizationMethod: 'standardScaling',\n aggregateByX: false,\n aggregateByY: false,\n aggregationMethod: 'mean'\n },\n heatmapClustered: {\n NAValueAs: 0,\n normalizationDirection: 'row',\n normalizationMethod: 'standardScaling',\n dendrogramX: true,\n dendrogramY: true,\n disableClusteringX: false,\n disableClusteringY: false,\n aggregateByX: false,\n aggregateByY: false,\n aggregationMethod: 'mean'\n },\n //scatterplot\n dots: {\n dotFill: null as ColorAes | null,\n dotShape: null as DotShapeAes | null,\n dotSize: null as ContinuousDataMappingSize | number | null\n },\n curve: { lineColor: DEFAULT_BLACK, smoothing: true },\n //discrete\n box: {\n showOutliers: true,\n fillColor: null as ColorAes | null,\n lineColor: DEFAULT_LINE_COLOR as ColorAes,\n dotShape: DEFAULT_DOT_SHAPE as DotShapeAes,\n lineType: DEFAULT_LINE_TYPE as LineTypeAes,\n gapWidth: 0.2,\n opacity: 1,\n stat: {\n low: 0.25,\n middle: 0.5,\n upper: 0.75,\n k: 1.5\n }\n },\n binnedDots: {\n fillColor: null as ColorAes | null,\n lineColor: DEFAULT_LINE_COLOR as ColorAes,\n opacity: 1,\n showOutliers: true\n },\n jitteredDots: {\n dotFill: null as ColorAes | null,\n dotShape: DEFAULT_DOT_SHAPE as DotShapeAes,\n lineColor: DEFAULT_LINE_COLOR as ColorAes,\n opacity: 1,\n showOutliers: true\n },\n violin: {\n fillColor: null as ColorAes | null,\n lineColor: DEFAULT_LINE_COLOR as ColorAes,\n lineType: DEFAULT_LINE_TYPE as LineTypeAes,\n opacity: 1,\n trim: false,\n showQuartiles: false,\n quartilesLineStyle: 'dashed',\n medianLineStyle: 'solid'\n },\n bar: {\n fillColor: null as ColorAes | null,\n lineColor: DEFAULT_LINE_COLOR as ColorAes,\n opacity: 1,\n height: 'max'\n },\n stackedBar: {\n fillColor: null as ColorAes | null,\n lineColor: DEFAULT_LINE_COLOR as ColorAes,\n opacity: 1,\n normalize: false,\n height: 'sum'\n },\n stackedArea: {\n fillColor: null as ColorAes | null,\n lineColor: DEFAULT_LINE_COLOR as ColorAes,\n barsOpacity: 1,\n areaOpacity: 0.7,\n normalize: false,\n showBars: true,\n height: 'sum'\n },\n line: {\n pointsValues: 'mean',\n emptyGroupValue: 0,\n lineColor: null as ColorAes | null,\n dotShape: DEFAULT_DOT_SHAPE as DotShapeAes,\n lineType: DEFAULT_LINE_TYPE as LineTypeAes,\n dotFill: null as ColorAes | null,\n opacity: 1\n },\n errorbar: {\n pointsValues: 'mean',\n interval: 'sd',\n lineColor: null as ColorAes | null,\n dotShape: DEFAULT_DOT_SHAPE as DotShapeAes,\n dotFill: null as ColorAes | null,\n opacity: 1\n },\n sina: {\n dotFill: null as ColorAes | null,\n dotShape: DEFAULT_DOT_SHAPE as DotShapeAes,\n opacity: 1,\n showOutliers: true\n },\n logo: {\n normalize: false,\n opacity: 1\n }\n});\n\nexport function getDefaultLayersSettings() {\n return DEFAULT_LAYERS_SETTINGS();\n}\n\nconst DISCRETE_LAYERS: Layer[] = [\n 'box',\n 'binnedDots',\n 'jitteredDots',\n 'violin',\n 'bar',\n 'stackedBar',\n 'line',\n 'errorbar',\n 'sina',\n 'logo'\n];\nconst SCATTERPLOT_LAYERS: Layer[] = ['dots', 'curve'];\nconst SCATTERPLOT_UMAP_LAYERS: Layer[] = ['dots'];\nconst HEATMAP_LAYERS: Layer[] = ['heatmap', 'heatmapClustered'];\nconst DENDRO_LAYERS: Layer[] = ['dendro'];\nconst HISTOGRAM_LAYERS: Layer[] = ['bins'];\nconst BUBBLE_LAYERS: Layer[] = ['bubble'];\nconst LAYERS_BY_CHART_TYPE: Record<ChartType, Layer[]> = {\n discrete: DISCRETE_LAYERS,\n scatterplot: SCATTERPLOT_LAYERS,\n 'scatterplot-umap': SCATTERPLOT_UMAP_LAYERS,\n heatmap: HEATMAP_LAYERS,\n dendro: DENDRO_LAYERS,\n histogram: HISTOGRAM_LAYERS,\n bubble: BUBBLE_LAYERS\n};\n\nexport function getInitialLayersSettings(\n initialSettings?: DeepPartial<LayersSettings>\n): LayersSettings {\n const defaultSettings = DEFAULT_LAYERS_SETTINGS();\n const layers: Layer[] = Object.keys(defaultSettings) as Layer[];\n return layers.reduce((res, layer) => {\n Object.assign(\n res[layer],\n initialSettings?.[layer] ?? {}\n );\n return res;\n }, defaultSettings);\n}\n\nexport type Sorting = 'asc' | 'desc';\nexport type AxesState = {\n title: { value: string; position: TitlePosition; mode: AxisTitleMode; facetTitleFrame: Frame };\n axisX: {\n labelsPosition: LabelsPosition; // for heatmap - top/bottom/left/right/hidden\n labelsRotation: LabelsRotation | null; // only for discrete X axis - 'center'/'90deg'/'45deg'; null for auto mode before user chose\n axisLabelsAngle: 0 | 45 | 90; // for heatmap\n groupLabelsAngle: 0 | 45 | 90; // for heatmap\n titleMode: AxisTitleMode; // 'auto' - from column or 'custom' - from 'customTitle' field or 'hidden'\n customTitle: string; // user axis title, not default from column\n gridlines: boolean;\n linesBetweenCategories: boolean; // for discrete - position for vertical gridlines\n ticks: boolean;\n scale: Scale; // linear or log\n significantLinesStyle: LineType;\n sorting: Sorting;\n allowNullPrimaryGroups: boolean; // for discrete - allow group with null grouping value\n allowNullSecondaryGroups: boolean;\n order: {\n source: string,\n options: {value: string, label: string}[]\n } | null;\n cellSize: number | null;\n };\n axisY: {\n labelsRotation: LabelsRotation | null; // only for discrete X axis - 'center'/'90deg'/'45deg'; null for auto mode before user chose\n titleMode: AxisTitleMode;\n customTitle: string;\n axisLabelsAngle: 0 | 45 | 90; // for heatmap\n groupLabelsAngle: 0 | 45 | 90; // for heatmap\n gridlines: boolean;\n ticks: boolean;\n scale: Scale;\n significantLinesStyle: LineType;\n sorting: Sorting;\n order: {\n source: string,\n options: {value: string, label: string}[]\n } | null;\n cellSize: number | null;\n };\n legend: {};\n other: {\n frame: Frame | HeatmapFrame;\n reverse: boolean;\n facetSharedBy: 'x' | 'y' | 'xy' | 'none';\n facetColumns: number;\n binsCount: number;\n groupingDirection: 'straight' | 'reverse';\n groupingStack: 'vertical' | 'horizontal';\n canvasRenderMode: boolean;\n };\n};\n\nconst DEFAULT_AXES: () => AxesState = () => ({\n title: {\n value: 'Graph 1',\n position: 'center',\n mode: 'auto',\n facetTitleFrame: 'full'\n },\n axisX: {\n labelsPosition: 'bottom',\n labelsRotation: null,\n axisLabelsAngle: 90,\n groupLabelsAngle: 45,\n titleMode: 'auto',\n customTitle: '',\n gridlines: true,\n linesBetweenCategories: true,\n ticks: true,\n scale: 'linear',\n significantLinesStyle: 'dashed',\n sorting: 'asc',\n allowNullPrimaryGroups: false,\n allowNullSecondaryGroups: false,\n order: null,\n cellSize: null,\n },\n axisY: {\n labelsRotation: null,\n titleMode: 'auto',\n customTitle: '',\n axisLabelsAngle: 90,\n groupLabelsAngle: 45,\n gridlines: true,\n ticks: true,\n scale: 'linear',\n significantLinesStyle: 'dashed',\n sorting: 'asc',\n order: null,\n cellSize: null,\n },\n legend: {},\n other: {\n frame: 'full',\n reverse: false,\n canvasRenderMode: false,\n facetSharedBy: 'xy',\n facetColumns: 3,\n binsCount: 10,\n groupingDirection: 'straight',\n groupingStack: 'vertical'\n }\n});\n\nfunction isHeatmapFrame(frame: Frame | HeatmapFrame): frame is HeatmapFrame {\n return frame === 'full' || frame === 'none';\n}\n\nexport function getInitialAxesSettings(\n chartType: ChartType,\n initialAxesSettings?: DeepPartial<AxesState>\n): AxesState {\n const defaultAxes = DEFAULT_AXES();\n if (!initialAxesSettings) {\n return defaultAxes;\n }\n\n // TODO: divide into separated settings for chart types\n function getFrame(frame?: Frame | HeatmapFrame): Frame | HeatmapFrame {\n if (!frame) {\n return 'full';\n }\n if (chartType === 'heatmap' && !isHeatmapFrame(frame)) {\n return 'full' as HeatmapFrame;\n }\n if (chartType !== 'heatmap' && isHeatmapFrame(frame)) {\n return frame === 'none' ? 'empty' : (frame as Frame);\n }\n return frame;\n }\n\n return {\n title: {\n ...defaultAxes.title,\n ...initialAxesSettings.title\n },\n axisX: {\n ...defaultAxes.axisX,\n ...initialAxesSettings.axisX\n },\n axisY: {\n ...defaultAxes.axisY,\n ...initialAxesSettings.axisY\n },\n legend: {\n ...defaultAxes.legend,\n ...initialAxesSettings.legend\n },\n other: {\n ...defaultAxes.other,\n ...initialAxesSettings.other,\n frame: getFrame(initialAxesSettings.other?.frame)\n }\n };\n}\n\nexport const LAYER_ICONS: Record<LayersTemplate, Component> = {\n box: BoxplotIcon,\n box_binnedDots: BoxplotAndBinnedIcon,\n box_jitteredDots: BoxplotAndJitterIcon,\n binnedDots: BinnedDotsIcon,\n jitteredDots: JitteredDotsIcon,\n violin: ViolinIcon,\n violin_binnedDots: ViolinAndBinnedIcon,\n violin_jitteredDots: ViolinAndJitterIcon,\n bar: BarIcon,\n bar_line: BarAndLineIcon,\n bar_errorbar: BarAndErrorIcon,\n stackedBar: StackedBarIcon,\n stackedArea: StackedAreaIcon,\n line: LineIcon,\n line_binnedDots: LineAndBinnedIcon,\n line_jitteredDots: LineAndJitterIcon,\n line_errorbar: LineAndErrorbarIcon,\n errorbar: BarAndLineIcon,\n sina: SinaIcon,\n logo: LogoIcon,\n dots: ScatterplotIcon,\n curve: LineIcon,\n curve_dots: LineAndJitterIcon,\n heatmap: HeatmapIcon,\n heatmapClustered: DendroIcon,\n dendro: DendroIcon,\n bins: BarIcon,\n bubble: HeatmapIcon\n};\n\ntype Option = { value: string; text: string };\nexport const STAT_TEST_METHOD: Option[] = [\n { value: 'ttest', text: 'TTest' },\n { value: 'anova', text: 'ANOVA' },\n { value: 'wilcoxon', text: 'Wilcoxon' },\n { value: 'kruskalWallis', text: 'Kruskal-Wallis' }\n];\n\nexport const STAT_CORRECTION_METHOD: Option[] = [\n { value: 'BenjaminiHochberg', text: 'Benjamini-Hochberg' },\n { value: 'BenjaminiYekutieli', text: 'Benjamini-Yekutieli' },\n { value: 'Bonferroni', text: 'Bonferroni' },\n { value: 'Hochberg', text: 'Hochberg' },\n { value: 'Holm', text: 'Holm' },\n { value: 'Hommel', text: 'Hommel' },\n { value: 'none', text: 'None' }\n];\n\nexport const FORMAT_P_VALUE_OPTIONS: Option[] = [\n { value: 'pValue', text: 'p-value' },\n { value: 'significance', text: 'significance' }\n];\n\nexport type AesType = 'fill' | 'stroke' | 'dotShape' | 'lineType' | 'size';\n\nexport const DEFAULT_WIDTH = 600;\nexport const DEFAULT_HEIGHT = 350;\nexport const DEFAULT_WIDTH_SMALL = 400;\nexport const DEFAULT_HEIGHT_SMALL = 250;\n\nexport const MAX_SEARCH_OPTIONS_LIST_LENGTH = 100;\n"],"names":["getInitialTemplate","restoredTemplate","chartType","DISCRETE_TEMPLATES_MAP","SCATTERPLOT_TEMPLATES_MAP","SCATTERPLOT_UMAP_TEMPLATES_MAP","HEATMAP_TEMPLATES_MAP","HISTOGRAM_TEMPLATES_MAP","LAYER_TITLES","getInitialStatisticsState","initialData","initial","_C","_D","_E","isNumberRange","v","isMappedAes","item","isContinuousDataMapping","DEFAULT_LAYERS_SETTINGS","DEFAULT_BLACK","DEFAULT_DOT_SHAPE","DEFAULT_DOT_SIZE","DEFAULT_LINE_COLOR","DEFAULT_LINE_TYPE","getInitialLayersSettings","initialSettings","defaultSettings","res","layer","DEFAULT_AXES","isHeatmapFrame","frame","getInitialAxesSettings","initialAxesSettings","defaultAxes","getFrame","_a","LAYER_ICONS","BoxplotIcon","BoxplotAndBinnedIcon","BoxplotAndJitterIcon","BinnedDotsIcon","JitteredDotsIcon","ViolinIcon","ViolinAndBinnedIcon","ViolinAndJitterIcon","BarIcon","BarAndLineIcon","BarAndErrorIcon","StackedBarIcon","StackedAreaIcon","LineIcon","LineAndBinnedIcon","LineAndJitterIcon","LineAndErrorbarIcon","SinaIcon","LogoIcon","ScatterplotIcon","HeatmapIcon","DendroIcon","STAT_TEST_METHOD","STAT_CORRECTION_METHOD","FORMAT_P_VALUE_OPTIONS","DEFAULT_WIDTH","DEFAULT_HEIGHT","DEFAULT_WIDTH_SMALL","DEFAULT_HEIGHT_SMALL","MAX_SEARCH_OPTIONS_LIST_LENGTH"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAqDO,SAASA,GACdC,GACAC,GACA;AACA,SAAIA,MAAc,aACTD,KACPE,GAAuBF,CAA0C,IAC7DA,IACA,QAEFC,MAAc,iBAAiBA,MAAc,qBACxCD,KACPG,GAA0BH,CAA6C,IACnEA,IACA,SAEFC,MAAc,WACT,WAEFD,KAAoB;AAC7B;AAEO,MAAME,KAGT;AAAA,EACF,KAAK,CAAC,KAAK;AAAA,EACX,gBAAgB,CAAC,OAAO,YAAY;AAAA,EACpC,kBAAkB,CAAC,OAAO,cAAc;AAAA,EACxC,QAAQ,CAAC,QAAQ;AAAA,EACjB,mBAAmB,CAAC,UAAU,YAAY;AAAA,EAC1C,qBAAqB,CAAC,UAAU,cAAc;AAAA,EAC9C,YAAY,CAAC,YAAY;AAAA,EACzB,cAAc,CAAC,cAAc;AAAA,EAC7B,KAAK,CAAC,KAAK;AAAA,EACX,UAAU,CAAC,OAAO,MAAM;AAAA,EACxB,cAAc,CAAC,OAAO,UAAU;AAAA,EAChC,YAAY,CAAC,YAAY;AAAA,EACzB,aAAa,CAAC,aAAa;AAAA,EAC3B,MAAM,CAAC,MAAM;AAAA,EACb,mBAAmB,CA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AsB,MAAM,sBAAA;AAAA,EACrC,EAAE,OAAO,cAAc,MAAM,aAAA;AAAA,EAC7B,EAAE,OAAO,YAAY,MAAM,WAAA;AAAA,EAC3B,EAAE,OAAO,QAAQ,MAAM,OAAA;AAAA,EACvB,EAAE,OAAO,UAAU,MAAM,SAAA;AAAA,EACzB,EAAE,OAAO,QAAQ,MAAM,OAAA;AACzB,GAEaC,KAAmC;AAAA,EAC9C,EAAE,OAAO,UAAU,MAAM,UAAA;AAAA,EACzB,EAAE,OAAO,gBAAgB,MAAM,eAAA;AACjC,GAIaC,KAAgB,KAChBC,KAAiB,KACjBC,KAAsB,KACtBC,KAAuB,KAEvBC,KAAiC;"}
|
|
1
|
+
{"version":3,"file":"constantsCommon.js","sources":["../src/constantsCommon.ts"],"sourcesContent":["import type { ChartType } from '@milaboratories/pf-plots';\nimport type { Component } from 'vue';\nimport type {\n DotShape,\n LineType,\n} from './components/AesSettings/types';\nimport {\n DEFAULT_BLACK,\n DEFAULT_DOT_SHAPE,\n DEFAULT_LINE_TYPE,\n} from './constantsAesthetic';\nimport { DEFAULT_DOT_SIZE, DEFAULT_LINE_COLOR } from './dataBindAes';\nimport BarAndErrorIcon from './icons/BarAndErrorIcon.vue';\nimport BarAndLineIcon from './icons/BarAndLineIcon.vue';\nimport BarIcon from './icons/BarIcon.vue';\nimport BinnedDotsIcon from './icons/BinnedDotsIcon.vue';\nimport BoxplotAndBinnedIcon from './icons/BoxplotAndBinnedIcon.vue';\nimport BoxplotAndJitterIcon from './icons/BoxplotAndJitterIcon.vue';\nimport BoxplotIcon from './icons/BoxplotIcon.vue';\nimport DendroIcon from './icons/DendroIcon.vue';\nimport HeatmapIcon from './icons/HeatmapIcon.vue';\nimport JitteredDotsIcon from './icons/JitteredDotsIcon.vue';\nimport LineAndBinnedIcon from './icons/LineAndBinnedIcon.vue';\nimport LineAndErrorbarIcon from './icons/LineAndErrorbarIcon.vue';\nimport LineAndJitterIcon from './icons/LineAndJitterIcon.vue';\nimport LineIcon from './icons/LineIcon.vue';\nimport LogoIcon from './icons/LogoIcon.vue';\nimport ScatterplotIcon from './icons/ScatterplotIcon.vue';\nimport SinaIcon from './icons/SinaIcon.vue';\nimport StackedBarIcon from './icons/StackedBarIcon.vue';\nimport StackedAreaIcon from './icons/StackedAreaIcon.vue';\nimport ViolinAndBinnedIcon from './icons/ViolinAndBinnedIcon.vue';\nimport ViolinAndJitterIcon from './icons/ViolinAndJitterIcon.vue';\nimport ViolinIcon from './icons/ViolinIcon.vue';\nimport type {\n AxisTitleMode,\n DeepPartial,\n DiscreteLayer,\n DiscreteLayersTemplate,\n Frame,\n HeatmapFrame, HeatmapLayer, HeatmapLayerTemplate, HistogramLayer, HistogramLayerTemplate,\n LabelsPosition,\n LabelsRotation,\n Layer,\n LayersTemplate,\n Scale,\n ScatterplotLayer,\n ScatterplotLayersTemplate,\n TitlePosition,\n} from './types';\n\nexport const DEFAULT_CHART_TYPE: ChartType = 'discrete';\n\nexport function getInitialTemplate(\n restoredTemplate: LayersTemplate | null,\n chartType: ChartType,\n) {\n if (chartType === 'discrete') {\n return restoredTemplate\n && DISCRETE_TEMPLATES_MAP[restoredTemplate as DiscreteLayersTemplate]\n ? restoredTemplate\n : 'box';\n }\n if (chartType === 'scatterplot' || chartType === 'scatterplot-umap') {\n return restoredTemplate\n && SCATTERPLOT_TEMPLATES_MAP[restoredTemplate as ScatterplotLayersTemplate]\n ? restoredTemplate\n : 'dots';\n }\n if (chartType === 'dendro') {\n return 'dendro';\n }\n return restoredTemplate ?? 'heatmap';\n}\n\nexport const DISCRETE_TEMPLATES_MAP: Record<\n DiscreteLayersTemplate,\n DiscreteLayer[]\n> = {\n box: ['box'],\n box_binnedDots: ['box', 'binnedDots'],\n box_jitteredDots: ['box', 'jitteredDots'],\n violin: ['violin'],\n violin_binnedDots: ['violin', 'binnedDots'],\n violin_jitteredDots: ['violin', 'jitteredDots'],\n binnedDots: ['binnedDots'],\n jitteredDots: ['jitteredDots'],\n bar: ['bar'],\n bar_line: ['bar', 'line'],\n bar_errorbar: ['bar', 'errorbar'],\n stackedBar: ['stackedBar'],\n stackedArea: ['stackedArea'],\n line: ['line'],\n line_jitteredDots: ['line', 'jitteredDots'],\n line_binnedDots: ['line', 'binnedDots'],\n line_errorbar: ['line', 'errorbar'],\n errorbar: ['errorbar'],\n sina: ['sina'],\n logo: ['logo'],\n};\n\nexport const SCATTERPLOT_TEMPLATES_MAP: Record<\n ScatterplotLayersTemplate,\n ScatterplotLayer[]\n> = {\n dots: ['dots'],\n curve: ['curve'],\n curve_dots: ['curve', 'dots'],\n};\n\nexport const SCATTERPLOT_UMAP_TEMPLATES_MAP: Partial<Record<\n ScatterplotLayersTemplate,\n ScatterplotLayer[]\n>> = {\n dots: ['dots'],\n curve_dots: ['curve', 'dots'],\n};\n\nexport const HEATMAP_TEMPLATES_MAP: Record<HeatmapLayerTemplate, HeatmapLayer[]> = {\n heatmap: ['heatmap'],\n heatmapClustered: ['heatmapClustered'],\n};\nexport const HISTOGRAM_TEMPLATES_MAP: Record<HistogramLayerTemplate, HistogramLayer[]> = {\n bins: ['bins'],\n};\nexport const LAYER_TITLES: Record<Layer, string> = {\n box: 'Boxplot',\n binnedDots: 'Binned Dots',\n jitteredDots: 'Jittered Dots',\n violin: 'Violins',\n bar: 'Bar',\n stackedBar: 'Stacked Bar',\n stackedArea: 'Stacked Bar + Stream Area',\n line: 'Line',\n errorbar: 'Error Bar',\n sina: 'Sina',\n logo: 'Logo Plot',\n dots: 'Scatter Plot',\n curve: 'Curve',\n heatmap: 'Heatmap',\n heatmapClustered: 'Heatmap + Dendro',\n dendro: 'Dendrogram',\n bins: 'Histogram',\n bubble: 'Bubble plot',\n};\n\nexport type DiscreteStatisticsState = {\n overall: {\n data: { testMethod: null | string };\n validity: { testMethod: boolean };\n };\n referenceGroup: {\n data: {\n testMethod: null | string;\n referenceGroup: null | string;\n correctionMethod: string;\n format: 'significance' | 'pValue';\n ns: boolean;\n };\n validity: {\n testMethod: boolean;\n referenceGroup: boolean;\n };\n };\n pairwise: {\n data: {\n testMethod: null | string;\n correctionMethod: string;\n format: 'significance' | 'pValue';\n ns: boolean;\n };\n validity: { testMethod: boolean };\n };\n};\n\nexport type ScatterplotStatisticsState = {\n trend: {\n on: boolean;\n trim: boolean;\n showLegend: boolean;\n };\n};\n\nexport type StatisticsState = DiscreteStatisticsState | ScatterplotStatisticsState;\n\nexport function getInitialStatisticsState(chartType: ChartType, initialData?: DeepPartial<StatisticsState>): StatisticsState {\n if (chartType === 'discrete') {\n const initial = initialData as DiscreteStatisticsState;\n return {\n overall: {\n data: { testMethod: initial?.overall?.data?.testMethod ?? null },\n validity: { testMethod: initial?.overall?.validity?.testMethod ?? true },\n },\n referenceGroup: {\n data: {\n testMethod: initial?.referenceGroup?.data?.testMethod ?? null,\n referenceGroup: initial?.referenceGroup?.data?.referenceGroup ?? null,\n correctionMethod: initial?.referenceGroup?.data?.correctionMethod ?? 'Bonferroni',\n format: initial?.referenceGroup?.data?.format ?? 'significance',\n ns: initial?.referenceGroup?.data?.ns ?? false,\n },\n validity: {\n testMethod: initial?.referenceGroup?.validity?.testMethod ?? true,\n referenceGroup: initial?.referenceGroup?.validity?.referenceGroup ?? true,\n },\n },\n pairwise: {\n data: {\n testMethod: initial?.pairwise?.data?.testMethod ?? null,\n correctionMethod: initial?.pairwise?.data?.correctionMethod ?? 'Bonferroni',\n format: initial?.pairwise?.data?.format ?? 'significance',\n ns: initial?.pairwise?.data?.ns ?? false,\n },\n validity: { testMethod: initial?.pairwise?.validity?.testMethod ?? true },\n },\n } as DiscreteStatisticsState;\n }\n const initial = initialData as ScatterplotStatisticsState;\n return {\n trend: {\n on: initial?.trend?.on ?? false,\n trim: initial?.trend?.trim ?? false,\n showLegend: initial?.trend?.showLegend ?? true,\n },\n };\n}\n\nexport type NumberRange = { min: number; max: number };\nexport type MappingLink = { type: string; value?: string }; // {type: 'primaryGrouping'} for example\nexport type ColorAes = string | MappingLink;\nexport type DotShapeAes = DotShape | MappingLink;\nexport type DotSizeAes = number | NumberRange;\nexport type LineTypeAes = LineType | MappingLink;\nexport type FixedOrMappedAes = ColorAes | DotShapeAes | LineTypeAes;\n\nexport type ContinuousDataMappingSize = {\n column: string;\n range: NumberRange;\n};\n\nexport type ContinuousDataMappingForGraph<T extends string | number> = { columnName: ColumnNameSchema; domain: number[]; range: T[]; type: 'linear' | 'log' };\n\nexport type ColumnNameSchema = {\n type: 'column';\n value: string;\n label?: string;\n valueLabels?: string;\n};\n\nexport function isNumberRange(v: number | NumberRange | null | undefined): v is NumberRange {\n return typeof v !== 'undefined' && v !== null && typeof v === 'object' && 'min' in v && 'max' in v;\n}\n\nexport function isMappedAes(\n item: FixedOrMappedAes | null | string | number | boolean | unknown,\n): item is MappingLink {\n return typeof item === 'object' && item !== null && 'type' in item;\n}\n\nexport function isContinuousDataMapping(v: ContinuousDataMappingSize | MappingLink | number | string | null | undefined): v is ContinuousDataMappingSize {\n return typeof v !== 'undefined' && v !== null && typeof v === 'object' && 'range' in v;\n}\n\nexport type LayersSettings = {\n // bubble\n bubble: {\n NAValueAs: number | null;\n minRadius: number;\n maxRadius: number;\n normalizationDirection: 'row' | 'column' | null;\n normalizationMethod: 'standardScaling' | 'meanNormalization';\n aggregateByX: boolean;\n aggregateByY: boolean;\n aggregationMethod: 'mean' | 'median' | 'min' | 'max';\n strokeColor: null | string;\n };\n // histogram\n bins: {\n fillColor: ColorAes | null;\n opacity: number;\n };\n // dendrogram\n dendro: {\n dotFill: ColorAes;\n dotShape: DotShapeAes;\n dotSize: DotSizeAes;\n lineColor: ColorAes;\n mode: 'normal' | 'useAllNodesAsLeaves';\n leavesMode: 'normal' | 'alignLeavesToLine';\n showTable: boolean;\n showLegend: boolean;\n };\n // heatmap\n heatmap: {\n NAValueAs: number | null;\n normalizationDirection: 'row' | 'column' | null;\n normalizationMethod: 'standardScaling' | 'meanNormalization';\n aggregateByX: boolean;\n aggregateByY: boolean;\n aggregationMethod: 'mean' | 'median' | 'min' | 'max';\n };\n heatmapClustered: {\n NAValueAs: number | null;\n normalizationDirection: 'row' | 'column' | null;\n normalizationMethod: 'standardScaling' | 'meanNormalization';\n dendrogramX: boolean;\n dendrogramY: boolean;\n disableClusteringX: boolean;\n disableClusteringY: boolean;\n aggregateByX: boolean;\n aggregateByY: boolean;\n aggregationMethod: 'mean' | 'median' | 'min' | 'max';\n };\n // scatterplot\n dots: {\n dotFill: ColorAes | null;\n dotShape: DotShapeAes | null;\n dotSize: ContinuousDataMappingSize | number | null;\n };\n curve: {\n smoothing: boolean;\n lineColor: ColorAes;\n };\n // discrete\n box: {\n showOutliers: boolean;\n fillColor: ColorAes | null;\n lineColor: ColorAes;\n dotShape: DotShapeAes;\n lineType: LineTypeAes;\n gapWidth: number;\n opacity: number;\n stat: {\n low: number;\n middle: number;\n upper: number;\n k: number;\n };\n };\n binnedDots: {\n fillColor: ColorAes | null;\n lineColor: ColorAes;\n opacity: number;\n showOutliers: boolean;\n };\n jitteredDots: {\n dotFill: ColorAes | null;\n dotShape: DotShapeAes;\n lineColor: ColorAes;\n opacity: number;\n showOutliers: boolean;\n };\n violin: {\n fillColor: ColorAes | null;\n lineColor: ColorAes;\n lineType: LineTypeAes;\n opacity: number;\n trim: boolean;\n showQuartiles: boolean;\n quartilesLineStyle: LineType;\n medianLineStyle: LineType;\n };\n bar: {\n fillColor: ColorAes | null;\n lineColor: ColorAes;\n opacity: number;\n height: 'max' | 'mean' | 'median';\n };\n stackedBar: {\n fillColor: ColorAes | null;\n lineColor: ColorAes;\n opacity: number;\n normalize: boolean;\n height: 'sum' | 'max' | 'mean' | 'median';\n };\n stackedArea: {\n fillColor: ColorAes | null;\n lineColor: ColorAes;\n barsOpacity: number;\n areaOpacity: number;\n normalize: boolean;\n height: 'sum' | 'max' | 'mean' | 'median';\n showBars: boolean;\n };\n line: {\n pointsValues: 'mean' | 'median';\n emptyGroupValue: number;\n lineColor: ColorAes | null;\n dotShape: DotShapeAes;\n lineType: LineTypeAes;\n dotFill: ColorAes | null;\n opacity: number;\n };\n errorbar: {\n pointsValues: 'mean' | 'median';\n interval: 'sd' | 'se' | '';\n lineColor: ColorAes | null;\n dotShape: DotShapeAes;\n dotFill: ColorAes | null;\n opacity: number;\n };\n sina: {\n dotFill: ColorAes | null;\n dotShape: DotShapeAes;\n opacity: number;\n showOutliers: boolean;\n };\n logo: {\n normalize: boolean;\n opacity: number;\n };\n};\nexport const DEFAULT_LAYERS_SETTINGS: () => LayersSettings = () => ({\n // bubble\n bubble: {\n NAValueAs: 0,\n strokeColor: null,\n minRadius: 3,\n maxRadius: 38,\n normalizationDirection: 'row',\n normalizationMethod: 'standardScaling',\n aggregateByX: false,\n aggregateByY: false,\n aggregationMethod: 'mean',\n },\n // histogram\n bins: {\n fillColor: null,\n opacity: 1,\n },\n // dendro\n dendro: {\n dotFill: DEFAULT_BLACK,\n dotShape: DEFAULT_DOT_SHAPE,\n dotSize: DEFAULT_DOT_SIZE,\n lineColor: DEFAULT_BLACK,\n mode: 'normal',\n leavesMode: 'normal',\n showTable: false,\n showLegend: true,\n },\n // heatmap\n heatmap: {\n NAValueAs: 0,\n normalizationDirection: 'row',\n normalizationMethod: 'standardScaling',\n aggregateByX: false,\n aggregateByY: false,\n aggregationMethod: 'mean',\n },\n heatmapClustered: {\n NAValueAs: 0,\n normalizationDirection: 'row',\n normalizationMethod: 'standardScaling',\n dendrogramX: true,\n dendrogramY: true,\n disableClusteringX: false,\n disableClusteringY: false,\n aggregateByX: false,\n aggregateByY: false,\n aggregationMethod: 'mean',\n },\n // scatterplot\n dots: {\n dotFill: null as ColorAes | null,\n dotShape: null as DotShapeAes | null,\n dotSize: null as ContinuousDataMappingSize | number | null,\n },\n curve: { lineColor: DEFAULT_BLACK, smoothing: true },\n // discrete\n box: {\n showOutliers: true,\n fillColor: null as ColorAes | null,\n lineColor: DEFAULT_LINE_COLOR as ColorAes,\n dotShape: DEFAULT_DOT_SHAPE as DotShapeAes,\n lineType: DEFAULT_LINE_TYPE as LineTypeAes,\n gapWidth: 0.2,\n opacity: 1,\n stat: {\n low: 0.25,\n middle: 0.5,\n upper: 0.75,\n k: 1.5,\n },\n },\n binnedDots: {\n fillColor: null as ColorAes | null,\n lineColor: DEFAULT_LINE_COLOR as ColorAes,\n opacity: 1,\n showOutliers: true,\n },\n jitteredDots: {\n dotFill: null as ColorAes | null,\n dotShape: DEFAULT_DOT_SHAPE as DotShapeAes,\n lineColor: DEFAULT_LINE_COLOR as ColorAes,\n opacity: 1,\n showOutliers: true,\n },\n violin: {\n fillColor: null as ColorAes | null,\n lineColor: DEFAULT_LINE_COLOR as ColorAes,\n lineType: DEFAULT_LINE_TYPE as LineTypeAes,\n opacity: 1,\n trim: false,\n showQuartiles: false,\n quartilesLineStyle: 'dashed',\n medianLineStyle: 'solid',\n },\n bar: {\n fillColor: null as ColorAes | null,\n lineColor: DEFAULT_LINE_COLOR as ColorAes,\n opacity: 1,\n height: 'max',\n },\n stackedBar: {\n fillColor: null as ColorAes | null,\n lineColor: DEFAULT_LINE_COLOR as ColorAes,\n opacity: 1,\n normalize: false,\n height: 'sum',\n },\n stackedArea: {\n fillColor: null as ColorAes | null,\n lineColor: DEFAULT_LINE_COLOR as ColorAes,\n barsOpacity: 1,\n areaOpacity: 0.7,\n normalize: false,\n showBars: true,\n height: 'sum',\n },\n line: {\n pointsValues: 'mean',\n emptyGroupValue: 0,\n lineColor: null as ColorAes | null,\n dotShape: DEFAULT_DOT_SHAPE as DotShapeAes,\n lineType: DEFAULT_LINE_TYPE as LineTypeAes,\n dotFill: null as ColorAes | null,\n opacity: 1,\n },\n errorbar: {\n pointsValues: 'mean',\n interval: 'sd',\n lineColor: null as ColorAes | null,\n dotShape: DEFAULT_DOT_SHAPE as DotShapeAes,\n dotFill: null as ColorAes | null,\n opacity: 1,\n },\n sina: {\n dotFill: null as ColorAes | null,\n dotShape: DEFAULT_DOT_SHAPE as DotShapeAes,\n opacity: 1,\n showOutliers: true,\n },\n logo: {\n normalize: false,\n opacity: 1,\n },\n});\n\nexport function getDefaultLayersSettings() {\n return DEFAULT_LAYERS_SETTINGS();\n}\n\nconst DISCRETE_LAYERS: Layer[] = [\n 'box',\n 'binnedDots',\n 'jitteredDots',\n 'violin',\n 'bar',\n 'stackedBar',\n 'line',\n 'errorbar',\n 'sina',\n 'logo',\n];\nconst SCATTERPLOT_LAYERS: Layer[] = ['dots', 'curve'];\nconst SCATTERPLOT_UMAP_LAYERS: Layer[] = ['dots'];\nconst HEATMAP_LAYERS: Layer[] = ['heatmap', 'heatmapClustered'];\nconst DENDRO_LAYERS: Layer[] = ['dendro'];\nconst HISTOGRAM_LAYERS: Layer[] = ['bins'];\nconst BUBBLE_LAYERS: Layer[] = ['bubble'];\nconst _LAYERS_BY_CHART_TYPE: Record<ChartType, Layer[]> = {\n 'discrete': DISCRETE_LAYERS,\n 'scatterplot': SCATTERPLOT_LAYERS,\n 'scatterplot-umap': SCATTERPLOT_UMAP_LAYERS,\n 'heatmap': HEATMAP_LAYERS,\n 'dendro': DENDRO_LAYERS,\n 'histogram': HISTOGRAM_LAYERS,\n 'bubble': BUBBLE_LAYERS,\n};\n\nexport function getInitialLayersSettings(\n initialSettings?: DeepPartial<LayersSettings>,\n): LayersSettings {\n const defaultSettings = DEFAULT_LAYERS_SETTINGS();\n const layers: Layer[] = Object.keys(defaultSettings) as Layer[];\n return layers.reduce((res, layer) => {\n Object.assign(\n res[layer],\n initialSettings?.[layer] ?? {},\n );\n return res;\n }, defaultSettings);\n}\n\nexport type Sorting = 'asc' | 'desc';\nexport type AxesState = {\n title: { value: string; position: TitlePosition; mode: AxisTitleMode; facetTitleFrame: Frame };\n axisX: {\n labelsPosition: LabelsPosition; // for heatmap - top/bottom/left/right/hidden\n labelsRotation: LabelsRotation | null; // only for discrete X axis - 'center'/'90deg'/'45deg'; null for auto mode before user chose\n axisLabelsAngle: 0 | 45 | 90; // for heatmap\n groupLabelsAngle: 0 | 45 | 90; // for heatmap\n titleMode: AxisTitleMode; // 'auto' - from column or 'custom' - from 'customTitle' field or 'hidden'\n customTitle: string; // user axis title, not default from column\n gridlines: boolean;\n linesBetweenCategories: boolean; // for discrete - position for vertical gridlines\n ticks: boolean;\n scale: Scale; // linear or log\n significantLinesStyle: LineType;\n sorting: Sorting;\n allowNullPrimaryGroups: boolean; // for discrete - allow group with null grouping value\n allowNullSecondaryGroups: boolean;\n order: {\n source: string;\n options: { value: string; label: string }[];\n } | null;\n cellSize: number | null;\n };\n axisY: {\n labelsRotation: LabelsRotation | null; // only for discrete X axis - 'center'/'90deg'/'45deg'; null for auto mode before user chose\n titleMode: AxisTitleMode;\n customTitle: string;\n axisLabelsAngle: 0 | 45 | 90; // for heatmap\n groupLabelsAngle: 0 | 45 | 90; // for heatmap\n gridlines: boolean;\n ticks: boolean;\n scale: Scale;\n significantLinesStyle: LineType;\n sorting: Sorting;\n order: {\n source: string;\n options: { value: string; label: string }[];\n } | null;\n cellSize: number | null;\n };\n legend: { show?: boolean };\n other: {\n frame: Frame | HeatmapFrame;\n reverse: boolean;\n facetSharedBy: 'x' | 'y' | 'xy' | 'none';\n facetColumns: number;\n binsCount: number;\n groupingDirection: 'straight' | 'reverse';\n groupingStack: 'vertical' | 'horizontal';\n canvasRenderMode: boolean;\n };\n};\n\nconst DEFAULT_AXES: () => AxesState = () => ({\n title: {\n value: 'Graph 1',\n position: 'center',\n mode: 'auto',\n facetTitleFrame: 'full',\n },\n axisX: {\n labelsPosition: 'bottom',\n labelsRotation: null,\n axisLabelsAngle: 90,\n groupLabelsAngle: 45,\n titleMode: 'auto',\n customTitle: '',\n gridlines: true,\n linesBetweenCategories: true,\n ticks: true,\n scale: 'linear',\n significantLinesStyle: 'dashed',\n sorting: 'asc',\n allowNullPrimaryGroups: false,\n allowNullSecondaryGroups: false,\n order: null,\n cellSize: null,\n },\n axisY: {\n labelsRotation: null,\n titleMode: 'auto',\n customTitle: '',\n axisLabelsAngle: 90,\n groupLabelsAngle: 45,\n gridlines: true,\n ticks: true,\n scale: 'linear',\n significantLinesStyle: 'dashed',\n sorting: 'asc',\n order: null,\n cellSize: null,\n },\n legend: {},\n other: {\n frame: 'full',\n reverse: false,\n canvasRenderMode: false,\n facetSharedBy: 'xy',\n facetColumns: 3,\n binsCount: 10,\n groupingDirection: 'straight',\n groupingStack: 'vertical',\n },\n});\n\nfunction isHeatmapFrame(frame: Frame | HeatmapFrame): frame is HeatmapFrame {\n return frame === 'full' || frame === 'none';\n}\n\nexport function getInitialAxesSettings(\n chartType: ChartType,\n initialAxesSettings?: DeepPartial<AxesState>,\n): AxesState {\n const defaultAxes = DEFAULT_AXES();\n if (!initialAxesSettings) {\n return defaultAxes;\n }\n\n // TODO: divide into separated settings for chart types\n function getFrame(frame?: Frame | HeatmapFrame): Frame | HeatmapFrame {\n if (!frame) {\n return 'full';\n }\n if (chartType === 'heatmap' && !isHeatmapFrame(frame)) {\n return 'full' as HeatmapFrame;\n }\n if (chartType !== 'heatmap' && isHeatmapFrame(frame)) {\n return frame === 'none' ? 'empty' : (frame as Frame);\n }\n return frame;\n }\n\n return {\n title: {\n ...defaultAxes.title,\n ...initialAxesSettings.title,\n },\n axisX: {\n ...defaultAxes.axisX,\n ...initialAxesSettings.axisX,\n },\n axisY: {\n ...defaultAxes.axisY,\n ...initialAxesSettings.axisY,\n },\n legend: {\n ...defaultAxes.legend,\n ...initialAxesSettings.legend,\n },\n other: {\n ...defaultAxes.other,\n ...initialAxesSettings.other,\n frame: getFrame(initialAxesSettings.other?.frame),\n },\n };\n}\n\nexport const LAYER_ICONS: Record<LayersTemplate, Component> = {\n box: BoxplotIcon,\n box_binnedDots: BoxplotAndBinnedIcon,\n box_jitteredDots: BoxplotAndJitterIcon,\n binnedDots: BinnedDotsIcon,\n jitteredDots: JitteredDotsIcon,\n violin: ViolinIcon,\n violin_binnedDots: ViolinAndBinnedIcon,\n violin_jitteredDots: ViolinAndJitterIcon,\n bar: BarIcon,\n bar_line: BarAndLineIcon,\n bar_errorbar: BarAndErrorIcon,\n stackedBar: StackedBarIcon,\n stackedArea: StackedAreaIcon,\n line: LineIcon,\n line_binnedDots: LineAndBinnedIcon,\n line_jitteredDots: LineAndJitterIcon,\n line_errorbar: LineAndErrorbarIcon,\n errorbar: BarAndLineIcon,\n sina: SinaIcon,\n logo: LogoIcon,\n dots: ScatterplotIcon,\n curve: LineIcon,\n curve_dots: LineAndJitterIcon,\n heatmap: HeatmapIcon,\n heatmapClustered: DendroIcon,\n dendro: DendroIcon,\n bins: BarIcon,\n bubble: HeatmapIcon,\n};\n\ntype Option = { value: string; text: string };\nexport const STAT_TEST_METHOD: Option[] = [\n { value: 'ttest', text: 'TTest' },\n { value: 'anova', text: 'ANOVA' },\n { value: 'wilcoxon', text: 'Wilcoxon' },\n { value: 'kruskalWallis', text: 'Kruskal-Wallis' },\n];\n\nexport const STAT_CORRECTION_METHOD: Option[] = [\n { value: 'BenjaminiHochberg', text: 'Benjamini-Hochberg' },\n { value: 'BenjaminiYekutieli', text: 'Benjamini-Yekutieli' },\n { value: 'Bonferroni', text: 'Bonferroni' },\n { value: 'Hochberg', text: 'Hochberg' },\n { value: 'Holm', text: 'Holm' },\n { value: 'Hommel', text: 'Hommel' },\n { value: 'none', text: 'None' },\n];\n\nexport const FORMAT_P_VALUE_OPTIONS: Option[] = [\n { value: 'pValue', text: 'p-value' },\n { value: 'significance', text: 'significance' },\n];\n\nexport type AesType = 'fill' | 'stroke' | 'dotShape' | 'lineType' | 'size';\n\nexport const DEFAULT_WIDTH = 600;\nexport const DEFAULT_HEIGHT = 350;\nexport const DEFAULT_WIDTH_SMALL = 400;\nexport const DEFAULT_HEIGHT_SMALL = 250;\n\nexport const MAX_SEARCH_OPTIONS_LIST_LENGTH = 100;\n"],"names":["getInitialTemplate","restoredTemplate","chartType","DISCRETE_TEMPLATES_MAP","SCATTERPLOT_TEMPLATES_MAP","SCATTERPLOT_UMAP_TEMPLATES_MAP","HEATMAP_TEMPLATES_MAP","HISTOGRAM_TEMPLATES_MAP","LAYER_TITLES","getInitialStatisticsState","initialData","initial","_C","_D","_E","isNumberRange","v","isMappedAes","item","isContinuousDataMapping","DEFAULT_LAYERS_SETTINGS","DEFAULT_BLACK","DEFAULT_DOT_SHAPE","DEFAULT_DOT_SIZE","DEFAULT_LINE_COLOR","DEFAULT_LINE_TYPE","getInitialLayersSettings","initialSettings","defaultSettings","res","layer","DEFAULT_AXES","isHeatmapFrame","frame","getInitialAxesSettings","initialAxesSettings","defaultAxes","getFrame","_a","LAYER_ICONS","BoxplotIcon","BoxplotAndBinnedIcon","BoxplotAndJitterIcon","BinnedDotsIcon","JitteredDotsIcon","ViolinIcon","ViolinAndBinnedIcon","ViolinAndJitterIcon","BarIcon","BarAndLineIcon","BarAndErrorIcon","StackedBarIcon","StackedAreaIcon","LineIcon","LineAndBinnedIcon","LineAndJitterIcon","LineAndErrorbarIcon","SinaIcon","LogoIcon","ScatterplotIcon","HeatmapIcon","DendroIcon","STAT_TEST_METHOD","STAT_CORRECTION_METHOD","FORMAT_P_VALUE_OPTIONS","DEFAULT_WIDTH","DEFAULT_HEIGHT","DEFAULT_WIDTH_SMALL","DEFAULT_HEIGHT_SMALL","MAX_SEARCH_OPTIONS_LIST_LENGTH"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAqDO,SAASA,GACdC,GACAC,GACA;AACA,SAAIA,MAAc,aACTD,KACFE,GAAuBF,CAA0C,IAClEA,IACA,QAEFC,MAAc,iBAAiBA,MAAc,qBACxCD,KACFG,GAA0BH,CAA6C,IACxEA,IACA,SAEFC,MAAc,WACT,WAEFD,KAAoB;AAC7B;AAEO,MAAME,KAGT;AAAA,EACF,KAAK,CAAC,KAAK;AAAA,EACX,gBAAgB,CAAC,OAAO,YAAY;AAAA,EACpC,kBAAkB,CAAC,OAAO,cAAc;AAAA,EACxC,QAAQ,CAAC,QAAQ;AAAA,EACjB,mBAAmB,CAAC,UAAU,YAAY;AAAA,EAC1C,qBAAqB,CAAC,UAAU,cAAc;AAAA,EAC9C,YAAY,CAAC,YAAY;AAAA,EACzB,cAAc,CAAC,c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EACxB,EAAE,OAAO,SAAS,MAAM,QAAA;AAAA,EACxB,EAAE,OAAO,YAAY,MAAM,WAAA;AAAA,EAC3B,EAAE,OAAO,iBAAiB,MAAM,iBAAA;AAClC,GAEaC,KAAmC;AAAA,EAC9C,EAAE,OAAO,qBAAqB,MAAM,qBAAA;AAAA,EACpC,EAAE,OAAO,sBAAsB,MAAM,sBAAA;AAAA,EACrC,EAAE,OAAO,cAAc,MAAM,aAAA;AAAA,EAC7B,EAAE,OAAO,YAAY,MAAM,WAAA;AAAA,EAC3B,EAAE,OAAO,QAAQ,MAAM,OAAA;AAAA,EACvB,EAAE,OAAO,UAAU,MAAM,SAAA;AAAA,EACzB,EAAE,OAAO,QAAQ,MAAM,OAAA;AACzB,GAEaC,KAAmC;AAAA,EAC9C,EAAE,OAAO,UAAU,MAAM,UAAA;AAAA,EACzB,EAAE,OAAO,gBAAgB,MAAM,eAAA;AACjC,GAIaC,KAAgB,KAChBC,KAAiB,KACjBC,KAAsB,KACtBC,KAAuB,KAEvBC,KAAiC;"}
|
package/dist/dataBindAes.js
CHANGED
|
@@ -64,8 +64,7 @@ function H(t, c) {
|
|
|
64
64
|
const { palette: a, order: e, mapping: s } = c, r = new Set(t), l = new Set(e), o = t.filter((p) => !l.has(p)), n = e.filter((p) => !r.has(p));
|
|
65
65
|
if (!o.length && !n.length)
|
|
66
66
|
return c;
|
|
67
|
-
|
|
68
|
-
const h = { ...s }, S = _[a].colors;
|
|
67
|
+
const i = [...t], h = { ...s }, S = _[a].colors;
|
|
69
68
|
return o.forEach((p, L) => {
|
|
70
69
|
const d = L + (e.length ? s[e[e.length - 1]].colorIdx + 1 : 0);
|
|
71
70
|
h[p] = {
|
|
@@ -103,6 +102,7 @@ function R(t, c, a, e) {
|
|
|
103
102
|
var n;
|
|
104
103
|
return !((n = r.hidden) != null && n[o]);
|
|
105
104
|
}),
|
|
105
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
106
106
|
inheritedAes: r.order.reduce((o, n) => {
|
|
107
107
|
const i = r.mapping[n].aes;
|
|
108
108
|
return o[n] = {}, e.fill && (o[n].fillColor = i.color, o[n].dotFill = i.color), e.stroke && (o[n].lineColor = i.color), e.dotShape && (o[n].dotShape = i.dotShape), e.lineType && (o[n].lineShape = i.lineShape), o;
|
|
@@ -117,6 +117,7 @@ function X(t, c, a) {
|
|
|
117
117
|
const s = ((l = c[t]) == null ? void 0 : l.list) ?? [], r = e ?? A(s);
|
|
118
118
|
return {
|
|
119
119
|
order: r.order,
|
|
120
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
120
121
|
inheritedAes: r.order.reduce((o, n) => {
|
|
121
122
|
const i = r.mapping[n].aes;
|
|
122
123
|
return o[n] = {
|
|
@@ -141,6 +142,7 @@ function Z(t, c, a) {
|
|
|
141
142
|
var n;
|
|
142
143
|
return !((n = r.hidden) != null && n[o]);
|
|
143
144
|
}),
|
|
145
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
144
146
|
inheritedAes: r.order.reduce((o, n) => {
|
|
145
147
|
const i = r.mapping[n].aes;
|
|
146
148
|
return o[n] = {
|