@platforma-sdk/ui-vue 1.65.9 → 1.66.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (56) hide show
  1. package/.turbo/turbo-build.log +21 -21
  2. package/.turbo/turbo-formatter$colon$check.log +2 -2
  3. package/.turbo/turbo-linter$colon$check.log +2 -2
  4. package/.turbo/turbo-types$colon$check.log +1 -1
  5. package/CHANGELOG.md +17 -0
  6. package/dist/components/PlAdvancedFilter/FilterEditor.js.map +1 -1
  7. package/dist/components/PlAdvancedFilter/FilterEditor.style.js.map +1 -1
  8. package/dist/components/PlAdvancedFilter/FilterEditor.test.d.ts +2 -0
  9. package/dist/components/PlAdvancedFilter/FilterEditor.test.d.ts.map +1 -0
  10. package/dist/components/PlAdvancedFilter/FilterEditor.vue.d.ts.map +1 -1
  11. package/dist/components/PlAdvancedFilter/FilterEditor.vue2.js +142 -145
  12. package/dist/components/PlAdvancedFilter/FilterEditor.vue2.js.map +1 -1
  13. package/dist/components/PlAdvancedFilter/PlAdvancedFilter.js.map +1 -1
  14. package/dist/components/PlAdvancedFilter/PlAdvancedFilter.style.js.map +1 -1
  15. package/dist/components/PlAdvancedFilter/PlAdvancedFilter.vue.d.ts.map +1 -1
  16. package/dist/components/PlAdvancedFilter/PlAdvancedFilter.vue2.js.map +1 -1
  17. package/dist/components/PlAdvancedFilter/types.d.ts +5 -6
  18. package/dist/components/PlAdvancedFilter/types.d.ts.map +1 -1
  19. package/dist/components/PlAdvancedFilter/utils.d.ts +1 -0
  20. package/dist/components/PlAdvancedFilter/utils.d.ts.map +1 -1
  21. package/dist/components/PlAdvancedFilter/utils.js +10 -1
  22. package/dist/components/PlAdvancedFilter/utils.js.map +1 -1
  23. package/dist/components/PlAnnotations/components/AnnotationsSidebar.js.map +1 -1
  24. package/dist/components/PlAnnotations/components/AnnotationsSidebar.style.js.map +1 -1
  25. package/dist/components/PlAnnotations/components/AnnotationsSidebar.vue.d.ts +7 -10
  26. package/dist/components/PlAnnotations/components/AnnotationsSidebar.vue.d.ts.map +1 -1
  27. package/dist/components/PlAnnotations/components/AnnotationsSidebar.vue2.js +71 -50
  28. package/dist/components/PlAnnotations/components/AnnotationsSidebar.vue2.js.map +1 -1
  29. package/dist/components/PlAnnotations/components/FilterSidebar.js.map +1 -1
  30. package/dist/components/PlAnnotations/components/FilterSidebar.style.js.map +1 -1
  31. package/dist/components/PlAnnotations/components/FilterSidebar.vue.d.ts +5 -7
  32. package/dist/components/PlAnnotations/components/FilterSidebar.vue.d.ts.map +1 -1
  33. package/dist/components/PlAnnotations/components/FilterSidebar.vue2.js +81 -67
  34. package/dist/components/PlAnnotations/components/FilterSidebar.vue2.js.map +1 -1
  35. package/dist/components/PlAnnotations/components/PlAnnotations.js.map +1 -1
  36. package/dist/components/PlAnnotations/components/PlAnnotations.style.js.map +1 -1
  37. package/dist/components/PlAnnotations/components/PlAnnotations.vue.d.ts +4 -14
  38. package/dist/components/PlAnnotations/components/PlAnnotations.vue.d.ts.map +1 -1
  39. package/dist/components/PlAnnotations/components/PlAnnotations.vue2.js +43 -38
  40. package/dist/components/PlAnnotations/components/PlAnnotations.vue2.js.map +1 -1
  41. package/dist/components/PlAnnotations/components/PlAnnotationsModal.js.map +1 -1
  42. package/dist/components/PlAnnotations/components/PlAnnotationsModal.style.js.map +1 -1
  43. package/dist/components/PlAnnotations/components/PlAnnotationsModal.vue.d.ts +5 -13
  44. package/dist/components/PlAnnotations/components/PlAnnotationsModal.vue.d.ts.map +1 -1
  45. package/dist/components/PlAnnotations/components/PlAnnotationsModal.vue2.js +37 -40
  46. package/dist/components/PlAnnotations/components/PlAnnotationsModal.vue2.js.map +1 -1
  47. package/package.json +7 -7
  48. package/src/components/PlAdvancedFilter/FilterEditor.test.ts +315 -0
  49. package/src/components/PlAdvancedFilter/FilterEditor.vue +12 -18
  50. package/src/components/PlAdvancedFilter/PlAdvancedFilter.vue +1 -6
  51. package/src/components/PlAdvancedFilter/types.ts +6 -8
  52. package/src/components/PlAdvancedFilter/utils.ts +20 -0
  53. package/src/components/PlAnnotations/components/AnnotationsSidebar.vue +59 -30
  54. package/src/components/PlAnnotations/components/FilterSidebar.vue +65 -40
  55. package/src/components/PlAnnotations/components/PlAnnotations.vue +35 -19
  56. package/src/components/PlAnnotations/components/PlAnnotationsModal.vue +18 -21
@@ -1,20 +1,10 @@
1
1
  import { Annotation } from '../types';
2
2
  import { Props as BaseProps } from './FilterSidebar.vue';
3
- export type Props = BaseProps & {
4
- onDeleteSchema?: () => void;
5
- };
6
- declare const _default: import('vue').DefineComponent<{
3
+ export type Props = Omit<BaseProps, "step" | "onUpdateStep"> & {
7
4
  annotation: Annotation;
8
- } & BaseProps & {
5
+ onUpdateAnnotation: (annotation: Annotation) => void;
9
6
  onDeleteSchema?: () => void;
10
- }, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
11
- "update:annotation": (value: Annotation) => any;
12
- }, string, import('vue').PublicProps, Readonly<{
13
- annotation: Annotation;
14
- } & BaseProps & {
15
- onDeleteSchema?: () => void;
16
- }> & Readonly<{
17
- "onUpdate:annotation"?: ((value: Annotation) => any) | undefined;
18
- }>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
7
+ };
8
+ declare const _default: import('vue').DefineComponent<Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
19
9
  export default _default;
20
10
  //# sourceMappingURL=PlAnnotations.vue.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"PlAnnotations.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/PlAnnotations/components/PlAnnotations.vue"],"names":[],"mappings":"AA0FA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AAK3C,OAAO,KAAK,EAAE,KAAK,IAAI,SAAS,EAAE,MAAM,qBAAqB,CAAC;AAC9D,MAAM,MAAM,KAAK,GAAG,SAAS,GAAG;IAC9B,cAAc,CAAC,EAAE,MAAM,IAAI,CAAC;CAC7B,CAAC;;gBAyCY,UAAU;;qBA1CL,MAAM,IAAI;;;;gBA0Cf,UAAU;;qBA1CL,MAAM,IAAI;;;;AAG7B,wBAmKK"}
1
+ {"version":3,"file":"PlAnnotations.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/PlAnnotations/components/PlAnnotations.vue"],"names":[],"mappings":"AA2GA,OAAO,KAAK,EAAE,UAAU,EAAU,MAAM,UAAU,CAAC;AAKnD,OAAO,KAAK,EAAE,KAAK,IAAI,SAAS,EAAE,MAAM,qBAAqB,CAAC;AAC9D,MAAM,MAAM,KAAK,GAAG,IAAI,CAAC,SAAS,EAAE,MAAM,GAAG,cAAc,CAAC,GAAG;IAC7D,UAAU,EAAE,UAAU,CAAC;IACvB,kBAAkB,EAAE,CAAC,UAAU,EAAE,UAAU,KAAK,IAAI,CAAC;IACrD,cAAc,CAAC,EAAE,MAAM,IAAI,CAAC;CAC7B,CAAC;;AAEF,wBAwKK"}
@@ -2,75 +2,80 @@ import { isNil as e } from "../../../lib/util/helpers/dist/utils.js";
2
2
  import "../../../lib/util/helpers/dist/index.js";
3
3
  import t from "./AnnotationsSidebar.js";
4
4
  import n from "./FilterSidebar.js";
5
- import { computed as r, createBlock as i, createCommentVNode as a, createVNode as o, defineComponent as s, effect as c, mergeModels as l, normalizeClass as u, openBlock as d, shallowRef as f, unref as p, useModel as m, withCtx as h } from "vue";
6
- import { PlSidebarGroup as g, useConfirm as _ } from "@milaboratories/uikit";
5
+ import { produce as r } from "immer";
6
+ import { computed as i, createBlock as a, createCommentVNode as o, createVNode as s, defineComponent as c, effect as l, normalizeClass as u, openBlock as d, shallowRef as f, unref as p, withCtx as m } from "vue";
7
+ import { PlSidebarGroup as h, useConfirm as g } from "@milaboratories/uikit";
7
8
  //#region src/components/PlAnnotations/components/PlAnnotations.vue?vue&type=script&setup=true&lang.ts
8
- var v = /* @__PURE__ */ s({
9
+ var _ = /* @__PURE__ */ c({
9
10
  __name: "PlAnnotations",
10
- props: /* @__PURE__ */ l({
11
+ props: {
11
12
  columns: {},
12
13
  getSuggestOptions: { type: Function },
13
14
  hasSelectedColumns: { type: Boolean },
14
15
  getValuesForSelectedColumns: { type: Function },
16
+ annotation: {},
17
+ onUpdateAnnotation: { type: Function },
15
18
  onDeleteSchema: { type: Function }
16
- }, {
17
- annotation: { required: !0 },
18
- annotationModifiers: {}
19
- }),
20
- emits: ["update:annotation"],
21
- setup(s) {
22
- let l = m(s, "annotation"), v = s, y = f(void 0), b = r(() => e(y.value) || e(l.value) ? void 0 : l.value.steps.find((e) => e.id === y.value));
23
- c(function() {
24
- y.value === void 0 && l.value.steps.length > 0 && (y.value = l.value.steps[0].id);
19
+ },
20
+ setup(c) {
21
+ let _ = c, v = f(void 0), y = i(() => e(v.value) || e(_.annotation) ? void 0 : _.annotation.steps.find((e) => e.id === v.value));
22
+ l(function() {
23
+ v.value === void 0 && _.annotation.steps.length > 0 && (v.value = _.annotation.steps[0].id);
25
24
  });
26
- let x = _({
25
+ let b = g({
27
26
  title: "Reset Schema",
28
27
  message: "Are you sure you want to reset the schema? This action cannot be undone.",
29
28
  confirmLabel: "Yes, reset",
30
29
  cancelLabel: "No, cancel"
31
30
  });
32
- async function S() {
33
- await x() && (y.value = void 0, v.onDeleteSchema?.());
31
+ async function x() {
32
+ await b() && (v.value = void 0, _.onDeleteSchema?.());
34
33
  }
35
- return (e, r) => (d(), i(p(g), null, {
36
- "item-0": h(() => [o(t, {
37
- annotation: l.value,
38
- "onUpdate:annotation": r[0] ||= (e) => l.value = e,
39
- selectedStepId: y.value,
40
- "onUpdate:selectedStepId": r[1] ||= (e) => y.value = e,
34
+ function S(e) {
35
+ v.value = e;
36
+ }
37
+ function C(e) {
38
+ _.onUpdateAnnotation(r(_.annotation, (t) => {
39
+ let n = t.steps.findIndex((t) => t.id === e.id);
40
+ n !== -1 && (t.steps[n] = e);
41
+ }));
42
+ }
43
+ return (e, r) => (d(), a(p(h), null, {
44
+ "item-0": m(() => [s(t, {
45
+ annotation: _.annotation,
46
+ "selected-step-id": v.value,
47
+ "on-update-annotation": _.onUpdateAnnotation,
48
+ "on-update-selected-step-id": S,
41
49
  class: u(e.$style.sidebarItem),
42
- columns: v.columns,
43
- onDeleteSchema: S
50
+ onDeleteSchema: x
44
51
  }, null, 8, [
45
52
  "annotation",
46
- "selectedStepId",
47
- "class",
48
- "columns"
53
+ "selected-step-id",
54
+ "on-update-annotation",
55
+ "class"
49
56
  ])]),
50
- "item-1": h(() => [b.value ? (d(), i(n, {
57
+ "item-1": m(() => [y.value ? (d(), a(n, {
51
58
  key: 0,
52
- step: b.value,
53
- "onUpdate:step": r[2] ||= (e) => b.value = e,
59
+ step: y.value,
60
+ "on-update-step": C,
54
61
  class: u(e.$style.sidebarItem),
55
- columns: v.columns,
56
- "get-suggest-options": v.getSuggestOptions,
57
- selectedStepId: y.value,
58
- hasSelectedColumns: v.hasSelectedColumns,
59
- getValuesForSelectedColumns: v.getValuesForSelectedColumns
62
+ columns: _.columns,
63
+ "get-suggest-options": _.getSuggestOptions,
64
+ hasSelectedColumns: _.hasSelectedColumns,
65
+ getValuesForSelectedColumns: _.getValuesForSelectedColumns
60
66
  }, null, 8, [
61
67
  "step",
62
68
  "class",
63
69
  "columns",
64
70
  "get-suggest-options",
65
- "selectedStepId",
66
71
  "hasSelectedColumns",
67
72
  "getValuesForSelectedColumns"
68
- ])) : a("", !0)]),
73
+ ])) : o("", !0)]),
69
74
  _: 1
70
75
  }));
71
76
  }
72
77
  });
73
78
  //#endregion
74
- export { v as default };
79
+ export { _ as default };
75
80
 
76
81
  //# sourceMappingURL=PlAnnotations.vue2.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"PlAnnotations.vue_vue_type_script_setup_true_lang.js","names":["$style"],"sources":["../../../../src/components/PlAnnotations/components/PlAnnotations.vue"],"sourcesContent":["<script lang=\"ts\">\nimport type { Props as BaseProps } from \"./FilterSidebar.vue\";\nexport type Props = BaseProps & {\n onDeleteSchema?: () => void;\n};\n</script>\n\n<script setup lang=\"ts\">\nimport { computed, effect, shallowRef } from \"vue\";\n\nimport { isNil } from \"@milaboratories/helpers\";\nimport { PlSidebarGroup, useConfirm } from \"@milaboratories/uikit\";\n\nimport type { Annotation } from \"../types\";\nimport AnnotationsSidebar from \"./AnnotationsSidebar.vue\";\nimport FilterSidebar from \"./FilterSidebar.vue\";\n\n// Models\nconst annotation = defineModel<Annotation>(\"annotation\", { required: true });\n// Props\nconst props = defineProps<Props>();\n// State\nconst selectedStepId = shallowRef<number | undefined>(undefined);\nconst selectedStep = computed(() => {\n return isNil(selectedStepId.value) || isNil(annotation.value)\n ? undefined\n : annotation.value.steps.find((step) => step.id === selectedStepId.value);\n});\n\n// Watchers\neffect(function setDefaultStepId() {\n if (selectedStepId.value === undefined && annotation.value.steps.length > 0) {\n selectedStepId.value = annotation.value.steps[0].id;\n }\n});\n// Hooks\nconst confirmResetSchema = useConfirm({\n title: \"Reset Schema\",\n message: \"Are you sure you want to reset the schema? This action cannot be undone.\",\n confirmLabel: \"Yes, reset\",\n cancelLabel: \"No, cancel\",\n});\n// Actions\nasync function handleDeleteSchema() {\n if (await confirmResetSchema()) {\n selectedStepId.value = undefined;\n props.onDeleteSchema?.();\n }\n}\n</script>\n\n<template>\n <PlSidebarGroup>\n <template #item-0>\n <AnnotationsSidebar\n v-model:annotation=\"annotation\"\n v-model:selectedStepId=\"selectedStepId\"\n :class=\"$style.sidebarItem\"\n :columns=\"props.columns\"\n @delete-schema=\"handleDeleteSchema\"\n />\n </template>\n <template #item-1>\n <FilterSidebar\n v-if=\"selectedStep\"\n v-model:step=\"selectedStep\"\n :class=\"$style.sidebarItem\"\n :columns=\"props.columns\"\n :get-suggest-options=\"props.getSuggestOptions\"\n :selectedStepId=\"selectedStepId\"\n :hasSelectedColumns=\"props.hasSelectedColumns\"\n :getValuesForSelectedColumns=\"props.getValuesForSelectedColumns\"\n />\n </template>\n </PlSidebarGroup>\n</template>\n\n<style module>\n.sidebarItem {\n width: 100%;\n height: 100%;\n}\n</style>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;EAkBA,IAAM,IAAa,EAAuB,GAAC,aAAiC,EAEtE,IAAQ,GAER,IAAiB,EAA+B,KAAA,EAAU,EAC1D,IAAe,QACZ,EAAM,EAAe,MAAM,IAAI,EAAM,EAAW,MAAK,GACxD,KAAA,IACA,EAAW,MAAM,MAAM,MAAM,MAAS,EAAK,OAAO,EAAe,MAAM,CAC3E;AAGF,IAAO,WAA4B;AACjC,GAAI,EAAe,UAAU,KAAA,KAAa,EAAW,MAAM,MAAM,SAAS,MACxE,EAAe,QAAQ,EAAW,MAAM,MAAM,GAAG;IAEnD;EAEF,IAAM,IAAqB,EAAW;GACpC,OAAO;GACP,SAAS;GACT,cAAc;GACd,aAAa;GACd,CAAC;EAEF,eAAe,IAAqB;AAClC,GAAI,MAAM,GAAoB,KAC5B,EAAe,QAAQ,KAAA,GACvB,EAAM,kBAAkB;;yBAM1B,EAsBiB,EAAA,EAAA,EAAA,MAAA;GArBJ,UAAM,QAOb,CANF,EAME,GAAA;IALQ,YAAY,EAAA;6CAAU,QAAA;IACtB,gBAAgB,EAAA;iDAAc,QAAA;IACrC,OAAK,EAAEA,EAAAA,OAAO,YAAW;IACzB,SAAS,EAAM;IACf,gBAAe;;;;;;;GAGT,UAAM,QAUb,CARM,EAAA,SAAA,GAAA,EADR,EASE,GAAA;;IAPQ,MAAM,EAAA;uCAAY,QAAA;IACzB,OAAK,EAAEA,EAAAA,OAAO,YAAW;IACzB,SAAS,EAAM;IACf,uBAAqB,EAAM;IAC3B,gBAAgB,EAAA;IAChB,oBAAoB,EAAM;IAC1B,6BAA6B,EAAM"}
1
+ {"version":3,"file":"PlAnnotations.vue_vue_type_script_setup_true_lang.js","names":["$style"],"sources":["../../../../src/components/PlAnnotations/components/PlAnnotations.vue"],"sourcesContent":["<script lang=\"ts\">\nimport type { Props as BaseProps } from \"./FilterSidebar.vue\";\nexport type Props = Omit<BaseProps, \"step\" | \"onUpdateStep\"> & {\n annotation: Annotation;\n onUpdateAnnotation: (annotation: Annotation) => void;\n onDeleteSchema?: () => void;\n};\n</script>\n\n<script setup lang=\"ts\">\nimport { computed, effect, shallowRef } from \"vue\";\n\nimport { isNil } from \"@milaboratories/helpers\";\nimport { produce } from \"immer\";\nimport { PlSidebarGroup, useConfirm } from \"@milaboratories/uikit\";\n\nimport type { Annotation, Filter } from \"../types\";\nimport AnnotationsSidebar from \"./AnnotationsSidebar.vue\";\nimport FilterSidebar from \"./FilterSidebar.vue\";\n\nconst props = defineProps<Props>();\n\nconst selectedStepId = shallowRef<undefined | number>(undefined);\n\nconst selectedStep = computed(() => {\n return isNil(selectedStepId.value) || isNil(props.annotation)\n ? undefined\n : props.annotation.steps.find((step) => step.id === selectedStepId.value);\n});\n\neffect(function setDefaultStepId() {\n if (selectedStepId.value === undefined && props.annotation.steps.length > 0) {\n selectedStepId.value = props.annotation.steps[0].id;\n }\n});\n\nconst confirmResetSchema = useConfirm({\n title: \"Reset Schema\",\n message: \"Are you sure you want to reset the schema? This action cannot be undone.\",\n confirmLabel: \"Yes, reset\",\n cancelLabel: \"No, cancel\",\n});\n\nasync function handleDeleteSchema() {\n if (await confirmResetSchema()) {\n selectedStepId.value = undefined;\n props.onDeleteSchema?.();\n }\n}\n\nfunction updateSelectedStepId(id: undefined | number) {\n selectedStepId.value = id;\n}\n\nfunction updateSelectedStep(step: Filter) {\n props.onUpdateAnnotation(\n produce(props.annotation, (draft) => {\n const idx = draft.steps.findIndex((s) => s.id === step.id);\n if (idx !== -1) {\n draft.steps[idx] = step;\n }\n }),\n );\n}\n</script>\n\n<template>\n <PlSidebarGroup>\n <template #item-0>\n <AnnotationsSidebar\n :annotation=\"props.annotation\"\n :selected-step-id=\"selectedStepId\"\n :on-update-annotation=\"props.onUpdateAnnotation\"\n :on-update-selected-step-id=\"updateSelectedStepId\"\n :class=\"$style.sidebarItem\"\n @delete-schema=\"handleDeleteSchema\"\n />\n </template>\n <template #item-1>\n <FilterSidebar\n v-if=\"selectedStep\"\n :step=\"selectedStep\"\n :on-update-step=\"updateSelectedStep\"\n :class=\"$style.sidebarItem\"\n :columns=\"props.columns\"\n :get-suggest-options=\"props.getSuggestOptions\"\n :hasSelectedColumns=\"props.hasSelectedColumns\"\n :getValuesForSelectedColumns=\"props.getValuesForSelectedColumns\"\n />\n </template>\n </PlSidebarGroup>\n</template>\n\n<style module>\n.sidebarItem {\n width: 100%;\n height: 100%;\n}\n</style>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;EAoBA,IAAM,IAAQ,GAER,IAAiB,EAA+B,KAAA,EAAU,EAE1D,IAAe,QACZ,EAAM,EAAe,MAAM,IAAI,EAAM,EAAM,WAAU,GACxD,KAAA,IACA,EAAM,WAAW,MAAM,MAAM,MAAS,EAAK,OAAO,EAAe,MAAM,CAC3E;AAEF,IAAO,WAA4B;AACjC,GAAI,EAAe,UAAU,KAAA,KAAa,EAAM,WAAW,MAAM,SAAS,MACxE,EAAe,QAAQ,EAAM,WAAW,MAAM,GAAG;IAEnD;EAEF,IAAM,IAAqB,EAAW;GACpC,OAAO;GACP,SAAS;GACT,cAAc;GACd,aAAa;GACd,CAAC;EAEF,eAAe,IAAqB;AAClC,GAAI,MAAM,GAAoB,KAC5B,EAAe,QAAQ,KAAA,GACvB,EAAM,kBAAkB;;EAI5B,SAAS,EAAqB,GAAwB;AACpD,KAAe,QAAQ;;EAGzB,SAAS,EAAmB,GAAc;AACxC,KAAM,mBACJ,EAAQ,EAAM,aAAa,MAAU;IACnC,IAAM,IAAM,EAAM,MAAM,WAAW,MAAM,EAAE,OAAO,EAAK,GAAG;AAC1D,IAAI,MAAQ,OACV,EAAM,MAAM,KAAO;KAErB,CACH;;yBAKD,EAuBiB,EAAA,EAAA,EAAA,MAAA;GAtBJ,UAAM,QAQb,CAPF,EAOE,GAAA;IANC,YAAY,EAAM;IAClB,oBAAkB,EAAA;IAClB,wBAAsB,EAAM;IAC5B,8BAA4B;IAC5B,OAAK,EAAEA,EAAAA,OAAO,YAAW;IACzB,gBAAe;;;;;;;GAGT,UAAM,QAiBZ,CAfK,EAAA,SAAA,GAAA,EADR,EASE,GAAA;;IAPC,MAAM,EAAA;IACN,kBAAgB;IAChB,OAAK,EAAEA,EAAAA,OAAO,YAAW;IACzB,SAAS,EAAM;IACf,uBAAqB,EAAM;IAC3B,oBAAoB,EAAM;IAC1B,6BAA6B,EAAM"}
@@ -1 +1 @@
1
- {"version":3,"file":"PlAnnotationsModal.js","names":[],"sources":["../../../../src/components/PlAnnotations/components/PlAnnotationsModal.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { PlPureSlideModal } from \"@milaboratories/uikit\";\nimport { effect, shallowRef } from \"vue\";\n\nimport type { Annotation } from \"../types\";\nimport type { Props } from \"./PlAnnotations.vue\";\nimport PlAnnotations from \"./PlAnnotations.vue\";\n\n// Models\nconst annotation = defineModel<Annotation>(\"annotation\", { required: true });\nconst opened = defineModel<boolean>(\"opened\", { required: true });\n// Props\nconst props = defineProps<Props>();\n// State\nconst selectedStepId = shallowRef<number | undefined>(undefined);\n// Watchers\neffect(function setDefaultStepId() {\n if (selectedStepId.value === undefined && annotation.value.steps.length > 0) {\n selectedStepId.value = annotation.value.steps[0].id;\n }\n});\n// Actions\nasync function handleDeleteSchema() {\n opened.value = false;\n props.onDeleteSchema?.();\n}\n</script>\n\n<template>\n <PlPureSlideModal v-model=\"opened\" :class=\"$style.modal\" width=\"768px\">\n <PlAnnotations\n v-model:annotation=\"annotation\"\n :class=\"$style.content\"\n :columns=\"props.columns\"\n :get-suggest-options=\"props.getSuggestOptions\"\n :has-selected-columns=\"props.hasSelectedColumns\"\n :getValuesForSelectedColumns=\"props.getValuesForSelectedColumns\"\n @delete-schema=\"handleDeleteSchema\"\n />\n </PlPureSlideModal>\n</template>\n\n<style module>\n.modal {\n display: flex;\n}\n\n.content {\n width: 100%;\n height: 100%;\n}\n</style>\n"],"mappings":""}
1
+ {"version":3,"file":"PlAnnotationsModal.js","names":[],"sources":["../../../../src/components/PlAnnotations/components/PlAnnotationsModal.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { PlPureSlideModal } from \"@milaboratories/uikit\";\n\nimport type { Props } from \"./PlAnnotations.vue\";\nimport PlAnnotations from \"./PlAnnotations.vue\";\n\nconst props = defineProps<\n Props & {\n opened: boolean;\n onUpdateOpened: (opened: boolean) => void;\n }\n>();\n\nasync function handleDeleteSchema() {\n props.onUpdateOpened(false);\n props.onDeleteSchema?.();\n}\n</script>\n\n<template>\n <PlPureSlideModal\n :model-value=\"props.opened\"\n :class=\"$style.modal\"\n width=\"768px\"\n @update:model-value=\"props.onUpdateOpened\"\n >\n <PlAnnotations\n :class=\"$style.content\"\n :columns=\"props.columns\"\n :annotation=\"props.annotation\"\n :on-update-annotation=\"props.onUpdateAnnotation\"\n :on-delete-schema=\"handleDeleteSchema\"\n :has-selected-columns=\"props.hasSelectedColumns\"\n :get-suggest-options=\"props.getSuggestOptions\"\n :get-values-for-selected-columns=\"props.getValuesForSelectedColumns\"\n />\n </PlPureSlideModal>\n</template>\n\n<style module>\n.modal {\n display: flex;\n}\n\n.content {\n width: 100%;\n height: 100%;\n}\n</style>\n"],"mappings":""}
@@ -1 +1 @@
1
- {"version":3,"file":"PlAnnotationsModal.vue_vue_type_style_index_0_lang.module.js","names":[],"sources":["../../../../src/components/PlAnnotations/components/PlAnnotationsModal.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { PlPureSlideModal } from \"@milaboratories/uikit\";\nimport { effect, shallowRef } from \"vue\";\n\nimport type { Annotation } from \"../types\";\nimport type { Props } from \"./PlAnnotations.vue\";\nimport PlAnnotations from \"./PlAnnotations.vue\";\n\n// Models\nconst annotation = defineModel<Annotation>(\"annotation\", { required: true });\nconst opened = defineModel<boolean>(\"opened\", { required: true });\n// Props\nconst props = defineProps<Props>();\n// State\nconst selectedStepId = shallowRef<number | undefined>(undefined);\n// Watchers\neffect(function setDefaultStepId() {\n if (selectedStepId.value === undefined && annotation.value.steps.length > 0) {\n selectedStepId.value = annotation.value.steps[0].id;\n }\n});\n// Actions\nasync function handleDeleteSchema() {\n opened.value = false;\n props.onDeleteSchema?.();\n}\n</script>\n\n<template>\n <PlPureSlideModal v-model=\"opened\" :class=\"$style.modal\" width=\"768px\">\n <PlAnnotations\n v-model:annotation=\"annotation\"\n :class=\"$style.content\"\n :columns=\"props.columns\"\n :get-suggest-options=\"props.getSuggestOptions\"\n :has-selected-columns=\"props.hasSelectedColumns\"\n :getValuesForSelectedColumns=\"props.getValuesForSelectedColumns\"\n @delete-schema=\"handleDeleteSchema\"\n />\n </PlPureSlideModal>\n</template>\n\n<style module>\n.modal {\n display: flex;\n}\n\n.content {\n width: 100%;\n height: 100%;\n}\n</style>\n"],"mappings":""}
1
+ {"version":3,"file":"PlAnnotationsModal.vue_vue_type_style_index_0_lang.module.js","names":[],"sources":["../../../../src/components/PlAnnotations/components/PlAnnotationsModal.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { PlPureSlideModal } from \"@milaboratories/uikit\";\n\nimport type { Props } from \"./PlAnnotations.vue\";\nimport PlAnnotations from \"./PlAnnotations.vue\";\n\nconst props = defineProps<\n Props & {\n opened: boolean;\n onUpdateOpened: (opened: boolean) => void;\n }\n>();\n\nasync function handleDeleteSchema() {\n props.onUpdateOpened(false);\n props.onDeleteSchema?.();\n}\n</script>\n\n<template>\n <PlPureSlideModal\n :model-value=\"props.opened\"\n :class=\"$style.modal\"\n width=\"768px\"\n @update:model-value=\"props.onUpdateOpened\"\n >\n <PlAnnotations\n :class=\"$style.content\"\n :columns=\"props.columns\"\n :annotation=\"props.annotation\"\n :on-update-annotation=\"props.onUpdateAnnotation\"\n :on-delete-schema=\"handleDeleteSchema\"\n :has-selected-columns=\"props.hasSelectedColumns\"\n :get-suggest-options=\"props.getSuggestOptions\"\n :get-values-for-selected-columns=\"props.getValuesForSelectedColumns\"\n />\n </PlPureSlideModal>\n</template>\n\n<style module>\n.modal {\n display: flex;\n}\n\n.content {\n width: 100%;\n height: 100%;\n}\n</style>\n"],"mappings":""}
@@ -1,16 +1,8 @@
1
- import { Annotation } from '../types';
2
1
  import { Props } from './PlAnnotations.vue';
3
- type __VLS_Props = Props;
4
- type __VLS_PublicProps = {
5
- "annotation": Annotation;
6
- "opened": boolean;
7
- } & __VLS_Props;
8
- declare const _default: import('vue').DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
9
- "update:annotation": (value: Annotation) => any;
10
- "update:opened": (value: boolean) => any;
11
- }, string, import('vue').PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
12
- "onUpdate:annotation"?: ((value: Annotation) => any) | undefined;
13
- "onUpdate:opened"?: ((value: boolean) => any) | undefined;
14
- }>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
2
+ type __VLS_Props = Props & {
3
+ opened: boolean;
4
+ onUpdateOpened: (opened: boolean) => void;
5
+ };
6
+ declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
15
7
  export default _default;
16
8
  //# sourceMappingURL=PlAnnotationsModal.vue.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"PlAnnotationsModal.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/PlAnnotations/components/PlAnnotationsModal.vue"],"names":[],"mappings":"AAyDA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AAC3C,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,qBAAqB,CAAC;AAOjD,KAAK,WAAW,GAAG,KAAK,CAAC;AAmBzB,KAAK,iBAAiB,GAAG;IACzB,YAAY,EAAE,UAAU,CAAC;IACzB,QAAQ,EAAE,OAAO,CAAC;CACjB,GAAG,WAAW,CAAC;;;;;;;;AA2FhB,wBAQG"}
1
+ {"version":3,"file":"PlAnnotationsModal.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/PlAnnotations/components/PlAnnotationsModal.vue"],"names":[],"mappings":"AAqDA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,qBAAqB,CAAC;AAGjD,KAAK,WAAW,GAAG,KAAK,GAAG;IACvB,MAAM,EAAE,OAAO,CAAC;IAChB,cAAc,EAAE,CAAC,MAAM,EAAE,OAAO,KAAK,IAAI,CAAC;CAC3C,CAAC;;AAiGJ,wBAOG"}
@@ -1,61 +1,58 @@
1
1
  import e from "./PlAnnotations.js";
2
- import { createBlock as t, createVNode as n, defineComponent as r, effect as i, mergeModels as a, normalizeClass as o, openBlock as s, shallowRef as c, unref as l, useModel as u, withCtx as d } from "vue";
3
- import { PlPureSlideModal as f } from "@milaboratories/uikit";
2
+ import { createBlock as t, createVNode as n, defineComponent as r, normalizeClass as i, openBlock as a, unref as o, withCtx as s } from "vue";
3
+ import { PlPureSlideModal as c } from "@milaboratories/uikit";
4
4
  //#region src/components/PlAnnotations/components/PlAnnotationsModal.vue?vue&type=script&setup=true&lang.ts
5
- var p = /* @__PURE__ */ r({
5
+ var l = /* @__PURE__ */ r({
6
6
  __name: "PlAnnotationsModal",
7
- props: /* @__PURE__ */ a({
7
+ props: {
8
8
  columns: {},
9
9
  getSuggestOptions: { type: Function },
10
10
  hasSelectedColumns: { type: Boolean },
11
11
  getValuesForSelectedColumns: { type: Function },
12
- onDeleteSchema: { type: Function }
13
- }, {
14
- annotation: { required: !0 },
15
- annotationModifiers: {},
16
- opened: {
17
- type: Boolean,
18
- required: !0
19
- },
20
- openedModifiers: {}
21
- }),
22
- emits: ["update:annotation", "update:opened"],
12
+ annotation: {},
13
+ onUpdateAnnotation: { type: Function },
14
+ onDeleteSchema: { type: Function },
15
+ opened: { type: Boolean },
16
+ onUpdateOpened: { type: Function }
17
+ },
23
18
  setup(r) {
24
- let a = u(r, "annotation"), p = u(r, "opened"), m = r, h = c(void 0);
25
- i(function() {
26
- h.value === void 0 && a.value.steps.length > 0 && (h.value = a.value.steps[0].id);
27
- });
28
- async function g() {
29
- p.value = !1, m.onDeleteSchema?.();
19
+ let l = r;
20
+ async function u() {
21
+ l.onUpdateOpened(!1), l.onDeleteSchema?.();
30
22
  }
31
- return (r, i) => (s(), t(l(f), {
32
- modelValue: p.value,
33
- "onUpdate:modelValue": i[1] ||= (e) => p.value = e,
34
- class: o(r.$style.modal),
35
- width: "768px"
23
+ return (r, d) => (a(), t(o(c), {
24
+ "model-value": l.opened,
25
+ class: i(r.$style.modal),
26
+ width: "768px",
27
+ "onUpdate:modelValue": l.onUpdateOpened
36
28
  }, {
37
- default: d(() => [n(e, {
38
- annotation: a.value,
39
- "onUpdate:annotation": i[0] ||= (e) => a.value = e,
40
- class: o(r.$style.content),
41
- columns: m.columns,
42
- "get-suggest-options": m.getSuggestOptions,
43
- "has-selected-columns": m.hasSelectedColumns,
44
- getValuesForSelectedColumns: m.getValuesForSelectedColumns,
45
- onDeleteSchema: g
29
+ default: s(() => [n(e, {
30
+ class: i(r.$style.content),
31
+ columns: l.columns,
32
+ annotation: l.annotation,
33
+ "on-update-annotation": l.onUpdateAnnotation,
34
+ "on-delete-schema": u,
35
+ "has-selected-columns": l.hasSelectedColumns,
36
+ "get-suggest-options": l.getSuggestOptions,
37
+ "get-values-for-selected-columns": l.getValuesForSelectedColumns
46
38
  }, null, 8, [
47
- "annotation",
48
39
  "class",
49
40
  "columns",
50
- "get-suggest-options",
41
+ "annotation",
42
+ "on-update-annotation",
51
43
  "has-selected-columns",
52
- "getValuesForSelectedColumns"
44
+ "get-suggest-options",
45
+ "get-values-for-selected-columns"
53
46
  ])]),
54
47
  _: 1
55
- }, 8, ["modelValue", "class"]));
48
+ }, 8, [
49
+ "model-value",
50
+ "class",
51
+ "onUpdate:modelValue"
52
+ ]));
56
53
  }
57
54
  });
58
55
  //#endregion
59
- export { p as default };
56
+ export { l as default };
60
57
 
61
58
  //# sourceMappingURL=PlAnnotationsModal.vue2.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"PlAnnotationsModal.vue_vue_type_script_setup_true_lang.js","names":["$style"],"sources":["../../../../src/components/PlAnnotations/components/PlAnnotationsModal.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { PlPureSlideModal } from \"@milaboratories/uikit\";\nimport { effect, shallowRef } from \"vue\";\n\nimport type { Annotation } from \"../types\";\nimport type { Props } from \"./PlAnnotations.vue\";\nimport PlAnnotations from \"./PlAnnotations.vue\";\n\n// Models\nconst annotation = defineModel<Annotation>(\"annotation\", { required: true });\nconst opened = defineModel<boolean>(\"opened\", { required: true });\n// Props\nconst props = defineProps<Props>();\n// State\nconst selectedStepId = shallowRef<number | undefined>(undefined);\n// Watchers\neffect(function setDefaultStepId() {\n if (selectedStepId.value === undefined && annotation.value.steps.length > 0) {\n selectedStepId.value = annotation.value.steps[0].id;\n }\n});\n// Actions\nasync function handleDeleteSchema() {\n opened.value = false;\n props.onDeleteSchema?.();\n}\n</script>\n\n<template>\n <PlPureSlideModal v-model=\"opened\" :class=\"$style.modal\" width=\"768px\">\n <PlAnnotations\n v-model:annotation=\"annotation\"\n :class=\"$style.content\"\n :columns=\"props.columns\"\n :get-suggest-options=\"props.getSuggestOptions\"\n :has-selected-columns=\"props.hasSelectedColumns\"\n :getValuesForSelectedColumns=\"props.getValuesForSelectedColumns\"\n @delete-schema=\"handleDeleteSchema\"\n />\n </PlPureSlideModal>\n</template>\n\n<style module>\n.modal {\n display: flex;\n}\n\n.content {\n width: 100%;\n height: 100%;\n}\n</style>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;EASA,IAAM,IAAa,EAAuB,GAAC,aAAiC,EACtE,IAAS,EAAoB,GAAC,SAA6B,EAE3D,IAAQ,GAER,IAAiB,EAA+B,KAAA,EAAU;AAEhE,IAAO,WAA4B;AACjC,GAAI,EAAe,UAAU,KAAA,KAAa,EAAW,MAAM,MAAM,SAAS,MACxE,EAAe,QAAQ,EAAW,MAAM,MAAM,GAAG;IAEnD;EAEF,eAAe,IAAqB;AAElC,GADA,EAAO,QAAQ,IACf,EAAM,kBAAkB;;yBAKxB,EAUmB,EAAA,EAAA,EAAA;eAVQ,EAAA;4CAAM,QAAA;GAAG,OAAK,EAAEA,EAAAA,OAAO,MAAK;GAAE,OAAM;;oBAS3D,CARF,EAQE,GAAA;IAPQ,YAAY,EAAA;6CAAU,QAAA;IAC7B,OAAK,EAAEA,EAAAA,OAAO,QAAO;IACrB,SAAS,EAAM;IACf,uBAAqB,EAAM;IAC3B,wBAAsB,EAAM;IAC5B,6BAA6B,EAAM;IACnC,gBAAe"}
1
+ {"version":3,"file":"PlAnnotationsModal.vue_vue_type_script_setup_true_lang.js","names":["$style"],"sources":["../../../../src/components/PlAnnotations/components/PlAnnotationsModal.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { PlPureSlideModal } from \"@milaboratories/uikit\";\n\nimport type { Props } from \"./PlAnnotations.vue\";\nimport PlAnnotations from \"./PlAnnotations.vue\";\n\nconst props = defineProps<\n Props & {\n opened: boolean;\n onUpdateOpened: (opened: boolean) => void;\n }\n>();\n\nasync function handleDeleteSchema() {\n props.onUpdateOpened(false);\n props.onDeleteSchema?.();\n}\n</script>\n\n<template>\n <PlPureSlideModal\n :model-value=\"props.opened\"\n :class=\"$style.modal\"\n width=\"768px\"\n @update:model-value=\"props.onUpdateOpened\"\n >\n <PlAnnotations\n :class=\"$style.content\"\n :columns=\"props.columns\"\n :annotation=\"props.annotation\"\n :on-update-annotation=\"props.onUpdateAnnotation\"\n :on-delete-schema=\"handleDeleteSchema\"\n :has-selected-columns=\"props.hasSelectedColumns\"\n :get-suggest-options=\"props.getSuggestOptions\"\n :get-values-for-selected-columns=\"props.getValuesForSelectedColumns\"\n />\n </PlPureSlideModal>\n</template>\n\n<style module>\n.modal {\n display: flex;\n}\n\n.content {\n width: 100%;\n height: 100%;\n}\n</style>\n"],"mappings":";;;;;;;;;;;;;;;;;;EAMA,IAAM,IAAQ;EAOd,eAAe,IAAqB;AAElC,GADA,EAAM,eAAe,GAAM,EAC3B,EAAM,kBAAkB;;yBAKxB,EAgBmB,EAAA,EAAA,EAAA;GAfhB,eAAa,EAAM;GACnB,OAAK,EAAEA,EAAAA,OAAO,MAAK;GACpB,OAAM;GACL,uBAAoB,EAAM;;oBAWzB,CATF,EASE,GAAA;IARC,OAAK,EAAEA,EAAAA,OAAO,QAAO;IACrB,SAAS,EAAM;IACf,YAAY,EAAM;IAClB,wBAAsB,EAAM;IAC5B,oBAAkB;IAClB,wBAAsB,EAAM;IAC5B,uBAAqB,EAAM;IAC3B,mCAAiC,EAAM"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@platforma-sdk/ui-vue",
3
- "version": "1.65.9",
3
+ "version": "1.66.0",
4
4
  "type": "module",
5
5
  "main": "dist/index.js",
6
6
  "exports": {
@@ -26,10 +26,10 @@
26
26
  "lru-cache": "^11.2.2",
27
27
  "vue": "^3.5.24",
28
28
  "zod": "~3.25.76",
29
- "@milaboratories/pf-spec-driver": "1.3.0",
30
- "@milaboratories/uikit": "2.12.5",
31
- "@milaboratories/pl-model-common": "1.33.0",
32
- "@platforma-sdk/model": "1.65.9"
29
+ "@milaboratories/uikit": "2.12.6",
30
+ "@platforma-sdk/model": "1.65.10",
31
+ "@milaboratories/pl-model-common": "1.34.0",
32
+ "@milaboratories/pf-spec-driver": "1.3.1"
33
33
  },
34
34
  "devDependencies": {
35
35
  "@faker-js/faker": "^9.2.0",
@@ -45,8 +45,8 @@
45
45
  "vitest": "^4.1.3",
46
46
  "@milaboratories/helpers": "1.14.1",
47
47
  "@milaboratories/ts-builder": "1.3.2",
48
- "@milaboratories/ts-configs": "1.2.3",
49
- "@milaboratories/build-configs": "2.0.0"
48
+ "@milaboratories/build-configs": "2.0.0",
49
+ "@milaboratories/ts-configs": "1.2.3"
50
50
  },
51
51
  "scripts": {
52
52
  "dev": "ts-builder serve --target browser-lib",