@milaboratories/graph-maker 1.1.225 → 1.1.226

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.
@@ -1,10 +1,10 @@
1
- import { defineComponent as w, computed as d, ref as p, createElementBlock as f, createCommentVNode as h, openBlock as r, createElementVNode as u, toDisplayString as v, createVNode as C, unref as g, createBlock as k, Fragment as y, renderList as $, normalizeClass as B, withCtx as L, createTextVNode as S } from "vue";
1
+ import { defineComponent as C, computed as u, ref as p, createElementBlock as f, createCommentVNode as h, openBlock as i, createElementVNode as m, toDisplayString as v, createVNode as y, unref as g, createBlock as k, Fragment as _, renderList as $, normalizeClass as B, withCtx as L, createTextVNode as S } from "vue";
2
2
  import I from "../../../components/DragAndDrop/DndChip.vue.js";
3
3
  import { PlSearchField as M, PlBtnGhost as N } from "@platforma-sdk/ui-vue";
4
4
  const b = {
5
5
  key: 0,
6
6
  class: "metadata-block"
7
- }, D = { class: "title" }, F = { class: "metadata-block__search" }, x = { class: "metadata-block__items" }, G = /* @__PURE__ */ w({
7
+ }, D = { class: "title" }, F = { class: "metadata-block__search" }, x = { class: "metadata-block__items" }, G = /* @__PURE__ */ C({
8
8
  __name: "OptionsList",
9
9
  props: {
10
10
  options: {},
@@ -12,41 +12,41 @@ const b = {
12
12
  title: { default: "Metadata" }
13
13
  },
14
14
  emits: ["dragged-id-update"],
15
- setup(i, { emit: E }) {
16
- const n = i, V = d(() => n.options.length === 0), l = p(), m = d(() => n.options.filter((o) => !n.chipInfo[o.id].hasHangingAxes)), a = p(!1), _ = d(() => {
15
+ setup(l, { emit: E }) {
16
+ const n = l, V = u(() => n.options.length === 0), a = p(), d = u(() => n.options.filter((o) => !n.chipInfo[o.id].hasHangingAxes)), s = p(!1), w = u(() => {
17
17
  var e;
18
- const o = ((e = l.value) == null ? void 0 : e.toLowerCase()) ?? "";
19
- return o.length > 0 ? n.options.filter((s) => {
20
- const t = n.chipInfo[s.id].title ?? "";
18
+ const o = ((e = a.value) == null ? void 0 : e.toLowerCase()) ?? "";
19
+ return o.length > 0 ? n.options.filter((r) => {
20
+ const t = n.chipInfo[r.id].title ?? "";
21
21
  return t == null ? void 0 : t.toLowerCase().includes(o);
22
- }) : a.value ? n.options : m.value;
22
+ }) : s.value ? n.options : d.value;
23
23
  });
24
24
  return (o, e) => {
25
- var s;
26
- return V.value ? h("", !0) : (r(), f("div", b, [
27
- u("div", D, v(i.title), 1),
28
- u("div", F, [
29
- C(g(M), {
30
- modelValue: l.value,
31
- "onUpdate:modelValue": e[0] || (e[0] = (t) => l.value = t),
25
+ var r;
26
+ return V.value ? h("", !0) : (i(), f("div", b, [
27
+ m("div", D, v(l.title), 1),
28
+ m("div", F, [
29
+ y(g(M), {
30
+ modelValue: a.value,
31
+ "onUpdate:modelValue": e[0] || (e[0] = (t) => a.value = t),
32
32
  placeholder: "Find...",
33
33
  clearable: ""
34
34
  }, null, 8, ["modelValue"])
35
35
  ]),
36
- u("div", x, [
37
- (r(!0), f(y, null, $(_.value, ({ id: t }) => (r(), k(I, {
36
+ m("div", x, [
37
+ (i(!0), f(_, null, $(w.value, ({ id: t }) => (i(), k(I, {
38
38
  key: t,
39
- info: i.chipInfo[t],
39
+ info: l.chipInfo[t],
40
40
  onDragstart: e[1] || (e[1] = (c) => o.$emit("dragged-id-update", c)),
41
41
  onDragend: e[2] || (e[2] = (c) => o.$emit("dragged-id-update", null))
42
42
  }, null, 8, ["info"]))), 128)),
43
- m.value.length > 0 && !((s = l.value) != null && s.length) ? (r(), k(g(N), {
43
+ d.value.length > 0 && !((r = a.value) != null && r.length) && d.value.length < l.options.length ? (i(), k(g(N), {
44
44
  key: 0,
45
45
  class: B(o.$style.showMoreButton),
46
- onClick: e[3] || (e[3] = (t) => a.value = !a.value)
46
+ onClick: e[3] || (e[3] = (t) => s.value = !s.value)
47
47
  }, {
48
48
  default: L(() => [
49
- S(v(a.value ? "Show less" : "Show more"), 1)
49
+ S(v(s.value ? "Show less" : "Show more"), 1)
50
50
  ]),
51
51
  _: 1
52
52
  }, 8, ["class"])) : h("", !0)
@@ -1 +1 @@
1
- {"version":3,"file":"OptionsList.vue2.js","sources":["../../../../src/forms/DataMappingForm/Layout/OptionsList.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type { ChipInfo } from '../../../components/DragAndDrop/types';\nimport type { AxisData, ColumnData } from '@milaboratories/pf-plots';\nimport { computed, ref } from 'vue';\nimport DndChip from '../../../components/DragAndDrop/DndChip.vue';\nimport { PlBtnGhost, PlSearchField } from '@platforma-sdk/ui-vue';\n\nconst props = withDefaults(defineProps<{\n options: { id: string; info: AxisData | ColumnData }[];\n chipInfo: Record<string, ChipInfo>;\n title?: string;\n}>(), { title: 'Metadata' });\n\nconst _emit = defineEmits(['dragged-id-update']);\n\nconst empty = computed(() => props.options.length === 0);\n\nconst searchModel = ref();\n\nconst optionsShortList = computed(() => {\n return props.options.filter((el) => {\n return !props.chipInfo[el.id].hasHangingAxes;\n });\n});\n\nconst showMore = ref(false);\n\nconst optionsRendered = computed(() => {\n const searchValue = searchModel.value?.toLowerCase() ?? '';\n if (searchValue.length > 0) {\n return props.options.filter((el) => {\n const label = props.chipInfo[el.id].title ?? '';\n return label?.toLowerCase().includes(searchValue);\n });\n }\n return showMore.value ? props.options : optionsShortList.value;\n});\n\n</script>\n\n<template>\n <div v-if=\"!empty\" class=\"metadata-block\">\n <div class=\"title\">{{ title }}</div>\n <div class=\"metadata-block__search\">\n <PlSearchField v-model=\"searchModel\" placeholder=\"Find...\" clearable />\n </div>\n <div class=\"metadata-block__items\">\n <DndChip\n v-for=\"{ id } in optionsRendered\"\n :key=\"id\"\n :info=\"chipInfo[id]\"\n @dragstart=\"(draggedId) => $emit('dragged-id-update', draggedId)\"\n @dragend=\"$emit('dragged-id-update', null)\"\n />\n <PlBtnGhost v-if=\"optionsShortList.length > 0 && !searchModel?.length\" :class=\"$style.showMoreButton\" @click=\"showMore = !showMore\">{{ showMore ? 'Show less' : 'Show more' }}</PlBtnGhost>\n </div>\n </div>\n</template>\n<style module>\n.showMoreButton {\n align-self: center;\n min-width: 80px;\n}\n</style>\n"],"names":["props","__props","empty","computed","searchModel","ref","optionsShortList","el","showMore","optionsRendered","searchValue","_a","label","_openBlock","_createElementBlock","_hoisted_1","_createElementVNode","_hoisted_2","_toDisplayString","_hoisted_3","_createVNode","_unref","PlSearchField","$event","_hoisted_4","_Fragment","_renderList","id","_createBlock","DndChip","_cache","draggedId","$emit","PlBtnGhost","_normalizeClass","$style"],"mappings":";;;;;;;;;;;;;;;AAOA,UAAMA,IAAQC,GAQRC,IAAQC,EAAS,MAAMH,EAAM,QAAQ,WAAW,CAAC,GAEjDI,IAAcC,EAAA,GAEdC,IAAmBH,EAAS,MACzBH,EAAM,QAAQ,OAAO,CAACO,MACpB,CAACP,EAAM,SAASO,EAAG,EAAE,EAAE,cAC/B,CACF,GAEKC,IAAWH,EAAI,EAAK,GAEpBI,IAAkBN,EAAS,MAAM;;AACrC,YAAMO,MAAcC,IAAAP,EAAY,UAAZ,gBAAAO,EAAmB,kBAAiB;AACxD,aAAID,EAAY,SAAS,IAChBV,EAAM,QAAQ,OAAO,CAACO,MAAO;AAClC,cAAMK,IAAQZ,EAAM,SAASO,EAAG,EAAE,EAAE,SAAS;AAC7C,eAAOK,KAAA,gBAAAA,EAAO,cAAc,SAASF;AAAA,MACvC,CAAC,IAEIF,EAAS,QAAQR,EAAM,UAAUM,EAAiB;AAAA,IAC3D,CAAC;;;aAKaJ,EAAA,qBAAZW,KAAAC,EAeM,OAfNC,GAeM;AAAA,QAdJC,EAAoC,OAApCC,GAAoCC,EAAdjB,EAAA,KAAK,GAAA,CAAA;AAAA,QAC3Be,EAEM,OAFNG,GAEM;AAAA,UADJC,EAAuEC,EAAAC,CAAA,GAAA;AAAA,wBAA/ClB,EAAA;AAAA,0DAAAA,EAAW,QAAAmB;AAAA,YAAE,aAAY;AAAA,YAAU,WAAA;AAAA,UAAA;;QAE7DP,EASM,OATNQ,GASM;AAAA,kBARJV,EAMEW,GAAA,MAAAC,EALiBjB,EAAA,OAAe,CAAA,EAAvB,IAAAkB,EAAA,YADXC,EAMEC,GAAA;AAAA,YAJC,KAAKF;AAAA,YACL,MAAM1B,EAAA,SAAS0B,CAAE;AAAA,YACjB,aAASG,EAAA,CAAA,MAAAA,EAAA,CAAA,IAAA,CAAGC,MAAcC,EAAAA,2BAA2BD,CAAS;AAAA,YAC9D,kCAASC,EAAAA,MAAK,qBAAA,IAAA;AAAA,UAAA;UAEC1B,EAAA,MAAiB,SAAM,KAAA,GAASK,IAAAP,EAAA,UAAA,QAAAO,EAAa,gBAA/DiB,EAA2LP,EAAAY,CAAA,GAAA;AAAA;YAAnH,OAAKC,EAAEC,EAAAA,OAAO,cAAc;AAAA,YAAG,SAAKL,EAAA,CAAA,MAAAA,EAAA,CAAA,IAAA,CAAAP,MAAEf,EAAA,QAAQ,CAAIA,EAAA;AAAA,UAAA;uBAAU,MAA0C;AAAA,kBAAvCA,EAAA,QAAQ,cAAA,WAAA,GAAA,CAAA;AAAA,YAAA;;;;;;;;"}
1
+ {"version":3,"file":"OptionsList.vue2.js","sources":["../../../../src/forms/DataMappingForm/Layout/OptionsList.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type { ChipInfo } from '../../../components/DragAndDrop/types';\nimport type { AxisData, ColumnData } from '@milaboratories/pf-plots';\nimport { computed, ref } from 'vue';\nimport DndChip from '../../../components/DragAndDrop/DndChip.vue';\nimport { PlBtnGhost, PlSearchField } from '@platforma-sdk/ui-vue';\n\nconst props = withDefaults(defineProps<{\n options: { id: string; info: AxisData | ColumnData }[];\n chipInfo: Record<string, ChipInfo>;\n title?: string;\n}>(), { title: 'Metadata' });\n\nconst _emit = defineEmits(['dragged-id-update']);\n\nconst empty = computed(() => props.options.length === 0);\n\nconst searchModel = ref();\n\nconst optionsShortList = computed(() => {\n return props.options.filter((el) => {\n return !props.chipInfo[el.id].hasHangingAxes;\n });\n});\n\nconst showMore = ref(false);\n\nconst optionsRendered = computed(() => {\n const searchValue = searchModel.value?.toLowerCase() ?? '';\n if (searchValue.length > 0) {\n return props.options.filter((el) => {\n const label = props.chipInfo[el.id].title ?? '';\n return label?.toLowerCase().includes(searchValue);\n });\n }\n return showMore.value ? props.options : optionsShortList.value;\n});\n\n</script>\n\n<template>\n <div v-if=\"!empty\" class=\"metadata-block\">\n <div class=\"title\">{{ title }}</div>\n <div class=\"metadata-block__search\">\n <PlSearchField v-model=\"searchModel\" placeholder=\"Find...\" clearable />\n </div>\n <div class=\"metadata-block__items\">\n <DndChip\n v-for=\"{ id } in optionsRendered\"\n :key=\"id\"\n :info=\"chipInfo[id]\"\n @dragstart=\"(draggedId) => $emit('dragged-id-update', draggedId)\"\n @dragend=\"$emit('dragged-id-update', null)\"\n />\n <PlBtnGhost v-if=\"optionsShortList.length > 0 && !searchModel?.length && optionsShortList.length < options.length\" :class=\"$style.showMoreButton\" @click=\"showMore = !showMore\">{{ showMore ? 'Show less' : 'Show more' }}</PlBtnGhost>\n </div>\n </div>\n</template>\n<style module>\n.showMoreButton {\n align-self: center;\n min-width: 80px;\n}\n</style>\n"],"names":["props","__props","empty","computed","searchModel","ref","optionsShortList","el","showMore","optionsRendered","searchValue","_a","label","_openBlock","_createElementBlock","_hoisted_1","_createElementVNode","_hoisted_2","_toDisplayString","_hoisted_3","_createVNode","_unref","PlSearchField","$event","_hoisted_4","_Fragment","_renderList","id","_createBlock","DndChip","_cache","draggedId","$emit","PlBtnGhost","_normalizeClass","$style"],"mappings":";;;;;;;;;;;;;;;AAOA,UAAMA,IAAQC,GAQRC,IAAQC,EAAS,MAAMH,EAAM,QAAQ,WAAW,CAAC,GAEjDI,IAAcC,EAAA,GAEdC,IAAmBH,EAAS,MACzBH,EAAM,QAAQ,OAAO,CAACO,MACpB,CAACP,EAAM,SAASO,EAAG,EAAE,EAAE,cAC/B,CACF,GAEKC,IAAWH,EAAI,EAAK,GAEpBI,IAAkBN,EAAS,MAAM;;AACrC,YAAMO,MAAcC,IAAA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A0C;AAAA,kBAAvCA,EAAA,QAAQ,cAAA,WAAA,GAAA,CAAA;AAAA,YAAA;;;;;;;;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@milaboratories/graph-maker",
3
- "version": "1.1.225",
3
+ "version": "1.1.226",
4
4
  "type": "module",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -37,7 +37,7 @@
37
37
  "d3-scale": "^4.0.2",
38
38
  "vue": "^3.5.24",
39
39
  "@milaboratories/miplots4": "1.0.173",
40
- "@milaboratories/pf-plots": "1.1.63"
40
+ "@milaboratories/pf-plots": "1.1.64"
41
41
  },
42
42
  "devDependencies": {
43
43
  "@milaboratories/build-configs": "^1.0.5",