@unovis/vue 1.5.0-beta.3 → 1.5.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 (151) hide show
  1. package/components/annotations/index.cjs +1 -1
  2. package/components/annotations/index.cjs.map +1 -1
  3. package/components/annotations/index.d.ts +5 -5
  4. package/components/annotations/index.js +14 -14
  5. package/components/annotations/index.js.map +1 -1
  6. package/components/area/index.cjs +1 -1
  7. package/components/area/index.cjs.map +1 -1
  8. package/components/area/index.d.ts +1 -1
  9. package/components/area/index.js +23 -23
  10. package/components/area/index.js.map +1 -1
  11. package/components/axis/index.cjs +1 -1
  12. package/components/axis/index.cjs.map +1 -1
  13. package/components/axis/index.d.ts +1 -1
  14. package/components/axis/index.js +16 -16
  15. package/components/axis/index.js.map +1 -1
  16. package/components/brush/index.cjs +1 -1
  17. package/components/brush/index.cjs.map +1 -1
  18. package/components/brush/index.d.ts +1 -1
  19. package/components/brush/index.js +17 -17
  20. package/components/brush/index.js.map +1 -1
  21. package/components/chord-diagram/index.cjs +1 -1
  22. package/components/chord-diagram/index.cjs.map +1 -1
  23. package/components/chord-diagram/index.d.ts +1 -1
  24. package/components/chord-diagram/index.js +27 -27
  25. package/components/chord-diagram/index.js.map +1 -1
  26. package/components/crosshair/index.cjs +1 -1
  27. package/components/crosshair/index.cjs.map +1 -1
  28. package/components/crosshair/index.d.ts +1 -1
  29. package/components/crosshair/index.js +1 -1
  30. package/components/crosshair/index.js.map +1 -1
  31. package/components/donut/index.cjs +1 -1
  32. package/components/donut/index.cjs.map +1 -1
  33. package/components/donut/index.d.ts +2 -2
  34. package/components/donut/index.js +14 -14
  35. package/components/donut/index.js.map +1 -1
  36. package/components/free-brush/index.cjs +1 -1
  37. package/components/free-brush/index.cjs.map +1 -1
  38. package/components/free-brush/index.d.ts +1 -1
  39. package/components/free-brush/index.js +18 -18
  40. package/components/free-brush/index.js.map +1 -1
  41. package/components/graph/index.cjs +1 -1
  42. package/components/graph/index.cjs.map +1 -1
  43. package/components/graph/index.d.ts +1 -1
  44. package/components/graph/index.js +59 -59
  45. package/components/graph/index.js.map +1 -1
  46. package/components/grouped-bar/index.cjs +1 -1
  47. package/components/grouped-bar/index.cjs.map +1 -1
  48. package/components/grouped-bar/index.d.ts +1 -1
  49. package/components/grouped-bar/index.js +25 -25
  50. package/components/grouped-bar/index.js.map +1 -1
  51. package/components/line/index.cjs +1 -1
  52. package/components/line/index.cjs.map +1 -1
  53. package/components/line/index.d.ts +1 -1
  54. package/components/line/index.js +23 -23
  55. package/components/line/index.js.map +1 -1
  56. package/components/nested-donut/index.cjs +1 -1
  57. package/components/nested-donut/index.cjs.map +1 -1
  58. package/components/nested-donut/index.d.ts +2 -2
  59. package/components/nested-donut/index.js +22 -22
  60. package/components/nested-donut/index.js.map +1 -1
  61. package/components/sankey/index.cjs +1 -1
  62. package/components/sankey/index.cjs.map +1 -1
  63. package/components/sankey/index.d.ts +1 -1
  64. package/components/sankey/index.js +35 -35
  65. package/components/sankey/index.js.map +1 -1
  66. package/components/scatter/index.cjs +1 -1
  67. package/components/scatter/index.cjs.map +1 -1
  68. package/components/scatter/index.d.ts +1 -1
  69. package/components/scatter/index.js +27 -27
  70. package/components/scatter/index.js.map +1 -1
  71. package/components/stacked-bar/index.cjs +1 -1
  72. package/components/stacked-bar/index.cjs.map +1 -1
  73. package/components/stacked-bar/index.d.ts +1 -1
  74. package/components/stacked-bar/index.js +22 -22
  75. package/components/stacked-bar/index.js.map +1 -1
  76. package/components/timeline/index.cjs +1 -1
  77. package/components/timeline/index.cjs.map +1 -1
  78. package/components/timeline/index.d.ts +2 -2
  79. package/components/timeline/index.js +1 -1
  80. package/components/timeline/index.js.map +1 -1
  81. package/components/tooltip/index.cjs +1 -1
  82. package/components/tooltip/index.cjs.map +1 -1
  83. package/components/tooltip/index.d.ts +5 -5
  84. package/components/tooltip/index.js +15 -15
  85. package/components/tooltip/index.js.map +1 -1
  86. package/components/topojson-map/index.cjs +1 -1
  87. package/components/topojson-map/index.cjs.map +1 -1
  88. package/components/topojson-map/index.d.ts +1 -1
  89. package/components/topojson-map/index.js +39 -39
  90. package/components/topojson-map/index.js.map +1 -1
  91. package/components/xy-labels/index.cjs +1 -1
  92. package/components/xy-labels/index.cjs.map +1 -1
  93. package/components/xy-labels/index.d.ts +1 -1
  94. package/components/xy-labels/index.js +38 -38
  95. package/components/xy-labels/index.js.map +1 -1
  96. package/containers/single-container/index.cjs.map +1 -1
  97. package/containers/single-container/index.d.ts +1 -1
  98. package/containers/single-container/index.js.map +1 -1
  99. package/containers/single-container/index3.cjs +1 -1
  100. package/containers/single-container/index3.js +1 -1
  101. package/containers/xy-container/index.cjs.map +1 -1
  102. package/containers/xy-container/index.d.ts +1 -1
  103. package/containers/xy-container/index.js.map +1 -1
  104. package/containers/xy-container/index3.cjs +1 -1
  105. package/containers/xy-container/index3.js +1 -1
  106. package/html-components/bullet-legend/index.cjs +1 -1
  107. package/html-components/bullet-legend/index.cjs.map +1 -1
  108. package/html-components/bullet-legend/index.d.ts +5 -5
  109. package/html-components/bullet-legend/index.js +11 -11
  110. package/html-components/bullet-legend/index.js.map +1 -1
  111. package/html-components/bullet-legend/index3.cjs +1 -1
  112. package/html-components/bullet-legend/index3.js +1 -1
  113. package/html-components/leaflet-flow-map/index.cjs +1 -1
  114. package/html-components/leaflet-flow-map/index.cjs.map +1 -1
  115. package/html-components/leaflet-flow-map/index.d.ts +1 -1
  116. package/html-components/leaflet-flow-map/index.js +43 -43
  117. package/html-components/leaflet-flow-map/index.js.map +1 -1
  118. package/html-components/leaflet-flow-map/index3.cjs +1 -1
  119. package/html-components/leaflet-flow-map/index3.js +1 -1
  120. package/html-components/leaflet-map/index.cjs +1 -1
  121. package/html-components/leaflet-map/index.cjs.map +1 -1
  122. package/html-components/leaflet-map/index.d.ts +1 -1
  123. package/html-components/leaflet-map/index.js +32 -32
  124. package/html-components/leaflet-map/index.js.map +1 -1
  125. package/html-components/leaflet-map/index3.cjs +1 -1
  126. package/html-components/leaflet-map/index3.js +1 -1
  127. package/index.cjs +2 -2
  128. package/index.js +6 -6
  129. package/package.json +6 -6
  130. package/utils/props.cjs.map +1 -1
  131. package/utils/props.js.map +1 -1
  132. package/containers/single-container/index2.cjs +0 -2
  133. package/containers/single-container/index2.cjs.map +0 -1
  134. package/containers/single-container/index2.js +0 -5
  135. package/containers/single-container/index2.js.map +0 -1
  136. package/containers/xy-container/index2.cjs +0 -2
  137. package/containers/xy-container/index2.cjs.map +0 -1
  138. package/containers/xy-container/index2.js +0 -5
  139. package/containers/xy-container/index2.js.map +0 -1
  140. package/html-components/bullet-legend/index2.cjs +0 -2
  141. package/html-components/bullet-legend/index2.cjs.map +0 -1
  142. package/html-components/bullet-legend/index2.js +0 -5
  143. package/html-components/bullet-legend/index2.js.map +0 -1
  144. package/html-components/leaflet-flow-map/index2.cjs +0 -2
  145. package/html-components/leaflet-flow-map/index2.cjs.map +0 -1
  146. package/html-components/leaflet-flow-map/index2.js +0 -5
  147. package/html-components/leaflet-flow-map/index2.js.map +0 -1
  148. package/html-components/leaflet-map/index2.cjs +0 -2
  149. package/html-components/leaflet-map/index2.cjs.map +0 -1
  150. package/html-components/leaflet-map/index2.js +0 -5
  151. package/html-components/leaflet-map/index2.js.map +0 -1
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),i=require("@unovis/ts"),c=require("../../utils/props.cjs"),p=require("../../utils/context.cjs"),v={"data-vis-annotations":""},_=i.Annotations.selectors,f=e.defineComponent({__name:"index",props:{items:{},duration:{},events:{},attributes:{},data:{}},setup(u,{expose:l}){const d=u,s=e.inject(p.annotationsAccessorKey),n=c.useForwardProps(d),t=e.ref();return e.onMounted(()=>{e.nextTick(()=>{t.value=new i.Annotations(n.value),s.update(t.value)})}),e.onUnmounted(()=>{var o;(o=t.value)==null||o.destroy(),s.destroy()}),e.watch(n,(o,r)=>{var a;c.arePropsEqual(o,r)||(a=t.value)==null||a.setConfig(n.value)}),l({component:t}),(o,r)=>(e.openBlock(),e.createElementBlock("div",v))}});exports.VisAnnotationsSelectors=_;exports.default=f;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),i=require("@unovis/ts"),c=require("../../utils/props.cjs"),p=require("../../utils/context.cjs"),v={"data-vis-annotations":""},_=i.Annotations.selectors,f=e.defineComponent({__name:"index",props:{items:{},duration:{},events:{},attributes:{},data:{}},setup(u,{expose:l}){const s=e.inject(p.annotationsAccessorKey),d=u,n=c.useForwardProps(d),t=e.ref();return e.onMounted(()=>{e.nextTick(()=>{t.value=new i.Annotations(n.value),s.update(t.value)})}),e.onUnmounted(()=>{var o;(o=t.value)==null||o.destroy(),s.destroy()}),e.watch(n,(o,r)=>{var a;c.arePropsEqual(o,r)||(a=t.value)==null||a.setConfig(n.value)}),l({component:t}),(o,r)=>(e.openBlock(),e.createElementBlock("div",v))}});exports.VisAnnotationsSelectors=_;exports.default=f;
2
2
  //# sourceMappingURL=index.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs","sources":["../../../src/components/annotations/index.vue?vue&type=script&setup=true&lang.ts"],"sourcesContent":["import { defineComponent as _defineComponent } from 'vue'\nimport { openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nconst _hoisted_1 = { \"data-vis-annotations\": \"\" }\n\nimport { Annotations, AnnotationsConfigInterface, AnnotationItem } from '@unovis/ts'\nimport { onMounted, onUnmounted, computed, ref, watch, nextTick, inject } from 'vue'\nimport { arePropsEqual, useForwardProps } from '../../utils/props'\nimport { annotationsAccessorKey } from '../../utils/context'\n\n\nexport const VisAnnotationsSelectors = Annotations.selectors\n\ntype Props = AnnotationsConfigInterface\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n items: {},\n duration: {},\n events: {},\n attributes: {},\n data: {}\n },\n setup(__props: any, { expose: __expose }) {\n\nconst props = __props;\n\n// !!! This code was automatically generated. You should not change it !!!\nconst accessor = inject(annotationsAccessorKey)\n\n// data and required props \n\n\n\n// config\nconst config = useForwardProps(props)\n\n// component declaration\nconst component = ref<Annotations>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Annotations(config.value)\n \n accessor.update(component.value)\n })\n})\n\nonUnmounted(() => {\n component.value?.destroy()\n accessor.destroy()\n})\n\nwatch(config, (curr, prev) => {\n if (!arePropsEqual(curr, prev)) {\n component.value?.setConfig(config.value)\n }\n})\n\n\n__expose({\n component\n})\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", _hoisted_1))\n}\n}\n\n})"],"names":["_hoisted_1","VisAnnotationsSelectors","Annotations","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","annotationsAccessorKey","config","useForwardProps","component","ref","onMounted","nextTick","onUnmounted","_a","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":"mOAGMA,EAAa,CAAE,uBAAwB,IAQhCC,EAA0BC,EAAY,YAAA,UAIvBC,EAAiBC,kBAAA,CAC3C,OAAQ,QACR,MAAO,CACL,MAAO,CAAC,EACR,SAAU,CAAC,EACX,OAAQ,CAAC,EACT,WAAY,CAAC,EACb,KAAM,CAAC,CACT,EACA,MAAMC,EAAc,CAAE,OAAQC,GAAY,CAE5C,MAAMC,EAAQF,EAGRG,EAAWC,SAAOC,EAAAA,sBAAsB,EAOxCC,EAASC,kBAAgBL,CAAK,EAG9BM,EAAYC,EAAAA,MAGlBC,OAAAA,EAAAA,UAAU,IAAM,CACdC,EAAAA,SAAS,IAAM,CACbH,EAAU,MAAQ,IAAIX,EAAY,YAAAS,EAAO,KAAK,EAErCH,EAAA,OAAOK,EAAU,KAAK,CAAA,CAChC,CAAA,CACF,EAEDI,EAAAA,YAAY,IAAM,QAChBC,EAAAL,EAAU,QAAV,MAAAK,EAAiB,UACjBV,EAAS,QAAQ,CAAA,CAClB,EAEKW,EAAAA,MAAAR,EAAQ,CAACS,EAAMC,IAAS,OACvBC,EAAA,cAAcF,EAAMC,CAAI,IACjBH,EAAAL,EAAA,QAAA,MAAAK,EAAO,UAAUP,EAAO,MACpC,CACD,EAGQL,EAAA,CACP,UAAAO,CAAA,CACD,EAEM,CAACU,EAAUC,KACRC,EAAW,UAAA,EAAGC,EAAAA,mBAAoB,MAAO1B,CAAU,EAE7D,CAEA,CAAC"}
1
+ {"version":3,"file":"index.cjs","sources":["../../../src/components/annotations/index.vue"],"sourcesContent":["<script setup lang=\"ts\" >\n// !!! This code was automatically generated. You should not change it !!!\nimport { Annotations, AnnotationsConfigInterface, AnnotationItem } from '@unovis/ts'\nimport { onMounted, onUnmounted, computed, ref, watch, nextTick, inject } from 'vue'\nimport { arePropsEqual, useForwardProps } from '../../utils/props'\nimport { annotationsAccessorKey } from '../../utils/context'\n\nconst accessor = inject(annotationsAccessorKey)\n\n// data and required props \ntype Props = AnnotationsConfigInterface\nconst props = defineProps<Props & { data?: null }>()\n\n\n// config\nconst config = useForwardProps(props)\n\n// component declaration\nconst component = ref<Annotations>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Annotations(config.value)\n \n accessor.update(component.value)\n })\n})\n\nonUnmounted(() => {\n component.value?.destroy()\n accessor.destroy()\n})\n\nwatch(config, (curr, prev) => {\n if (!arePropsEqual(curr, prev)) {\n component.value?.setConfig(config.value)\n }\n})\n\n\ndefineExpose({\n component\n})\n</script>\n\n<script lang=\"ts\">\nexport const VisAnnotationsSelectors = Annotations.selectors\n</script>\n\n<template>\n <div data-vis-annotations />\n</template>\n\n\n"],"names":["VisAnnotationsSelectors","Annotations","accessor","inject","annotationsAccessorKey","props","__props","config","useForwardProps","component","ref","onMounted","nextTick","onUnmounted","_a","watch","curr","prev","arePropsEqual","__expose"],"mappings":"iQA+CaA,EAA0BC,EAAAA,YAAY,+HAxC7C,MAAAC,EAAWC,SAAOC,wBAAsB,EAIxCC,EAAQC,EAIRC,EAASC,kBAAgBH,CAAK,EAG9BI,EAAYC,EAAAA,IAAiB,EAGnCC,OAAAA,EAAAA,UAAU,IAAM,CACdC,EAAAA,SAAS,IAAM,CACbH,EAAU,MAAQ,IAAIR,cAAYM,EAAO,KAAK,EAErCL,EAAA,OAAOO,EAAU,KAAK,CAAA,CAChC,CAAA,CACF,EAEDI,EAAAA,YAAY,IAAM,QAChBC,EAAAL,EAAU,QAAV,MAAAK,EAAiB,UACjBZ,EAAS,QAAQ,CAAA,CAClB,EAEKa,EAAAA,MAAAR,EAAQ,CAACS,EAAMC,IAAS,OACvBC,EAAA,cAAcF,EAAMC,CAAI,IACjBH,EAAAL,EAAA,QAAA,MAAAK,EAAO,UAAUP,EAAO,MACpC,CACD,EAGYY,EAAA,CACX,UAAAV,CAAA,CACD"}
@@ -1,6 +1,6 @@
1
1
  import { Annotations, AnnotationItem } from '@unovis/ts';
2
2
  export declare const VisAnnotationsSelectors: typeof import("@unovis/ts/lib/components/annotations/style");
3
- declare const _default: import("vue").DefineComponent<{
3
+ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
4
4
  items: {
5
5
  type: import("vue").PropType<AnnotationItem[]>;
6
6
  required: true;
@@ -45,9 +45,9 @@ declare const _default: import("vue").DefineComponent<{
45
45
  data: {
46
46
  type: import("vue").PropType<never>;
47
47
  };
48
- }, {
49
- component: import("vue").Ref<Annotations>;
50
- }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
48
+ }>, {
49
+ component: import("vue").Ref<Annotations, Annotations>;
50
+ }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
51
51
  items: {
52
52
  type: import("vue").PropType<AnnotationItem[]>;
53
53
  required: true;
@@ -92,5 +92,5 @@ declare const _default: import("vue").DefineComponent<{
92
92
  data: {
93
93
  type: import("vue").PropType<never>;
94
94
  };
95
- }>>, {}, {}>;
95
+ }>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
96
96
  export default _default;
@@ -1,8 +1,8 @@
1
- import { defineComponent as u, inject as m, ref as d, onMounted as l, nextTick as f, onUnmounted as v, watch as _, openBlock as x, createElementBlock as h } from "vue";
2
- import { Annotations as r } from "@unovis/ts";
3
- import { useForwardProps as k, arePropsEqual as w } from "../../utils/props.js";
4
- import { annotationsAccessorKey as y } from "../../utils/context.js";
5
- const A = { "data-vis-annotations": "" }, P = r.selectors, b = /* @__PURE__ */ u({
1
+ import { defineComponent as p, inject as u, ref as m, onMounted as d, nextTick as l, onUnmounted as f, watch as v, openBlock as _, createElementBlock as x } from "vue";
2
+ import { Annotations as a } from "@unovis/ts";
3
+ import { useForwardProps as h, arePropsEqual as k } from "../../utils/props.js";
4
+ import { annotationsAccessorKey as w } from "../../utils/context.js";
5
+ const y = { "data-vis-annotations": "" }, P = a.selectors, b = /* @__PURE__ */ p({
6
6
  __name: "index",
7
7
  props: {
8
8
  items: {},
@@ -12,20 +12,20 @@ const A = { "data-vis-annotations": "" }, P = r.selectors, b = /* @__PURE__ */ u
12
12
  data: {}
13
13
  },
14
14
  setup(c, { expose: i }) {
15
- const p = c, n = m(y), t = k(p), o = d();
16
- return l(() => {
17
- f(() => {
18
- o.value = new r(t.value), n.update(o.value);
15
+ const n = u(w), t = h(c), o = m();
16
+ return d(() => {
17
+ l(() => {
18
+ o.value = new a(t.value), n.update(o.value);
19
19
  });
20
- }), v(() => {
20
+ }), f(() => {
21
21
  var e;
22
22
  (e = o.value) == null || e.destroy(), n.destroy();
23
- }), _(t, (e, s) => {
24
- var a;
25
- w(e, s) || (a = o.value) == null || a.setConfig(t.value);
23
+ }), v(t, (e, s) => {
24
+ var r;
25
+ k(e, s) || (r = o.value) == null || r.setConfig(t.value);
26
26
  }), i({
27
27
  component: o
28
- }), (e, s) => (x(), h("div", A));
28
+ }), (e, s) => (_(), x("div", y));
29
29
  }
30
30
  });
31
31
  export {
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../../../src/components/annotations/index.vue?vue&type=script&setup=true&lang.ts"],"sourcesContent":["import { defineComponent as _defineComponent } from 'vue'\nimport { openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nconst _hoisted_1 = { \"data-vis-annotations\": \"\" }\n\nimport { Annotations, AnnotationsConfigInterface, AnnotationItem } from '@unovis/ts'\nimport { onMounted, onUnmounted, computed, ref, watch, nextTick, inject } from 'vue'\nimport { arePropsEqual, useForwardProps } from '../../utils/props'\nimport { annotationsAccessorKey } from '../../utils/context'\n\n\nexport const VisAnnotationsSelectors = Annotations.selectors\n\ntype Props = AnnotationsConfigInterface\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n items: {},\n duration: {},\n events: {},\n attributes: {},\n data: {}\n },\n setup(__props: any, { expose: __expose }) {\n\nconst props = __props;\n\n// !!! This code was automatically generated. You should not change it !!!\nconst accessor = inject(annotationsAccessorKey)\n\n// data and required props \n\n\n\n// config\nconst config = useForwardProps(props)\n\n// component declaration\nconst component = ref<Annotations>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Annotations(config.value)\n \n accessor.update(component.value)\n })\n})\n\nonUnmounted(() => {\n component.value?.destroy()\n accessor.destroy()\n})\n\nwatch(config, (curr, prev) => {\n if (!arePropsEqual(curr, prev)) {\n component.value?.setConfig(config.value)\n }\n})\n\n\n__expose({\n component\n})\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", _hoisted_1))\n}\n}\n\n})"],"names":["_hoisted_1","VisAnnotationsSelectors","Annotations","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","annotationsAccessorKey","config","useForwardProps","component","ref","onMounted","nextTick","onUnmounted","_a","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":";;;;AAGA,MAAMA,IAAa,EAAE,wBAAwB,MAQhCC,IAA0BC,EAAY,WAIvBC,IAAiBC,gBAAAA,EAAA;AAAA,EAC3C,QAAQ;AAAA,EACR,OAAO;AAAA,IACL,OAAO,CAAC;AAAA,IACR,UAAU,CAAC;AAAA,IACX,QAAQ,CAAC;AAAA,IACT,YAAY,CAAC;AAAA,IACb,MAAM,CAAC;AAAA,EACT;AAAA,EACA,MAAMC,GAAc,EAAE,QAAQC,KAAY;AAE5C,UAAMC,IAAQF,GAGRG,IAAWC,EAAOC,CAAsB,GAOxCC,IAASC,EAAgBL,CAAK,GAG9BM,IAAYC;AAGlB,WAAAC,EAAU,MAAM;AACd,MAAAC,EAAS,MAAM;AACb,QAAAH,EAAU,QAAQ,IAAIX,EAAYS,EAAO,KAAK,GAErCH,EAAA,OAAOK,EAAU,KAAK;AAAA,MAAA,CAChC;AAAA,IAAA,CACF,GAEDI,EAAY,MAAM;;AAChB,OAAAC,IAAAL,EAAU,UAAV,QAAAK,EAAiB,WACjBV,EAAS,QAAQ;AAAA,IAAA,CAClB,GAEKW,EAAAR,GAAQ,CAACS,GAAMC,MAAS;;AAC5B,MAAKC,EAAcF,GAAMC,CAAI,MACjBH,IAAAL,EAAA,UAAA,QAAAK,EAAO,UAAUP,EAAO;AAAA,IACpC,CACD,GAGQL,EAAA;AAAA,MACP,WAAAO;AAAA,IAAA,CACD,GAEM,CAACU,GAAUC,OACRC,EAAW,GAAGC,EAAoB,OAAO1B,CAAU;AAAA,EAE7D;AAEA,CAAC;"}
1
+ {"version":3,"file":"index.js","sources":["../../../src/components/annotations/index.vue"],"sourcesContent":["<script setup lang=\"ts\" >\n// !!! This code was automatically generated. You should not change it !!!\nimport { Annotations, AnnotationsConfigInterface, AnnotationItem } from '@unovis/ts'\nimport { onMounted, onUnmounted, computed, ref, watch, nextTick, inject } from 'vue'\nimport { arePropsEqual, useForwardProps } from '../../utils/props'\nimport { annotationsAccessorKey } from '../../utils/context'\n\nconst accessor = inject(annotationsAccessorKey)\n\n// data and required props \ntype Props = AnnotationsConfigInterface\nconst props = defineProps<Props & { data?: null }>()\n\n\n// config\nconst config = useForwardProps(props)\n\n// component declaration\nconst component = ref<Annotations>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Annotations(config.value)\n \n accessor.update(component.value)\n })\n})\n\nonUnmounted(() => {\n component.value?.destroy()\n accessor.destroy()\n})\n\nwatch(config, (curr, prev) => {\n if (!arePropsEqual(curr, prev)) {\n component.value?.setConfig(config.value)\n }\n})\n\n\ndefineExpose({\n component\n})\n</script>\n\n<script lang=\"ts\">\nexport const VisAnnotationsSelectors = Annotations.selectors\n</script>\n\n<template>\n <div data-vis-annotations />\n</template>\n\n\n"],"names":["VisAnnotationsSelectors","Annotations","accessor","inject","annotationsAccessorKey","config","useForwardProps","__props","component","ref","onMounted","nextTick","onUnmounted","_a","watch","curr","prev","arePropsEqual","__expose"],"mappings":";;;;0CA+CaA,IAA0BC,EAAY;;;;;;;;;;AAxC7C,UAAAC,IAAWC,EAAOC,CAAsB,GAQxCC,IAASC,EAJDC,CAIsB,GAG9BC,IAAYC,EAAiB;AAGnC,WAAAC,EAAU,MAAM;AACd,MAAAC,EAAS,MAAM;AACb,QAAAH,EAAU,QAAQ,IAAIP,EAAYI,EAAO,KAAK,GAErCH,EAAA,OAAOM,EAAU,KAAK;AAAA,MAAA,CAChC;AAAA,IAAA,CACF,GAEDI,EAAY,MAAM;;AAChB,OAAAC,IAAAL,EAAU,UAAV,QAAAK,EAAiB,WACjBX,EAAS,QAAQ;AAAA,IAAA,CAClB,GAEKY,EAAAT,GAAQ,CAACU,GAAMC,MAAS;;AAC5B,MAAKC,EAAcF,GAAMC,CAAI,MACjBH,IAAAL,EAAA,UAAA,QAAAK,EAAO,UAAUR,EAAO;AAAA,IACpC,CACD,GAGYa,EAAA;AAAA,MACX,WAAAV;AAAA,IAAA,CACD;;;"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("vue"),i=require("@unovis/ts"),l=require("../../utils/props.cjs"),y=require("../../utils/context.cjs"),v={"data-vis-component":""},m=i.Area.selectors,F=t.defineComponent({__name:"index",props:{color:{type:[Function,String,Array,null]},curveType:{},baseline:{type:[Function,Number,null]},opacity:{type:[Function,Number,null]},cursor:{type:[Function,String,null]},minHeight1Px:{type:Boolean},x:{type:[Function,Number,null]},y:{type:[Function,Number,null,Array]},id:{type:Function},xScale:{type:[Object,Function]},yScale:{type:[Object,Function]},excludeFromDomainCalculation:{type:Boolean},duration:{},events:{},attributes:{},data:{}},setup(p,{expose:d}){const u=p,o=t.inject(y.componentAccessorKey),a=t.computed(()=>o.data.value??u.data),c=l.useForwardProps(u),n=t.ref();return t.onMounted(()=>{t.nextTick(()=>{var e;n.value=new i.Area(c.value),(e=n.value)==null||e.setData(a.value),o.update(n.value)})}),t.onUnmounted(()=>{var e;(e=n.value)==null||e.destroy(),o.destroy()}),t.watch(c,(e,r)=>{var s;l.arePropsEqual(e,r)||(s=n.value)==null||s.setConfig(c.value)}),t.watch(a,()=>{var e;(e=n.value)==null||e.setData(a.value)}),d({component:n}),(e,r)=>(t.openBlock(),t.createElementBlock("div",v))}});exports.VisAreaSelectors=m;exports.default=F;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("vue"),l=require("@unovis/ts"),i=require("../../utils/props.cjs"),v=require("../../utils/context.cjs"),m={"data-vis-component":""},y=l.Area.selectors,_=t.defineComponent({__name:"index",props:{color:{},curveType:{},baseline:{},opacity:{},cursor:{},minHeight1Px:{type:Boolean},x:{},y:{},id:{type:Function},xScale:{type:[Object,Function]},yScale:{type:[Object,Function]},excludeFromDomainCalculation:{type:Boolean},duration:{},events:{},attributes:{},data:{}},setup(p,{expose:d}){const a=t.inject(v.componentAccessorKey),s=p,n=t.computed(()=>a.data.value??s.data),c=i.useForwardProps(s),o=t.ref();return t.onMounted(()=>{t.nextTick(()=>{var e;o.value=new l.Area(c.value),(e=o.value)==null||e.setData(n.value),a.update(o.value)})}),t.onUnmounted(()=>{var e;(e=o.value)==null||e.destroy(),a.destroy()}),t.watch(c,(e,r)=>{var u;i.arePropsEqual(e,r)||(u=o.value)==null||u.setConfig(c.value)}),t.watch(n,()=>{var e;(e=o.value)==null||e.setData(n.value)}),d({component:o}),(e,r)=>(t.openBlock(),t.createElementBlock("div",m))}});exports.VisAreaSelectors=y;exports.default=_;
2
2
  //# sourceMappingURL=index.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs","sources":["../../../src/components/area/index.vue?vue&type=script&setup=true&lang.ts"],"sourcesContent":["import { defineComponent as _defineComponent } from 'vue'\nimport { openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nconst _hoisted_1 = { \"data-vis-component\": \"\" }\n\nimport { Area, AreaConfigInterface, NumericAccessor } from '@unovis/ts'\nimport { onMounted, onUnmounted, computed, ref, watch, nextTick, inject } from 'vue'\nimport { arePropsEqual, useForwardProps } from '../../utils/props'\nimport { componentAccessorKey } from '../../utils/context'\n\n\nexport const VisAreaSelectors = Area.selectors\n\ntype Props = AreaConfigInterface<Datum>\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n color: { type: [Function, String, Array, null] },\n curveType: {},\n baseline: { type: [Function, Number, null] },\n opacity: { type: [Function, Number, null] },\n cursor: { type: [Function, String, null] },\n minHeight1Px: { type: Boolean },\n x: { type: [Function, Number, null] },\n y: { type: [Function, Number, null, Array] },\n id: { type: Function },\n xScale: { type: [Object, Function] },\n yScale: { type: [Object, Function] },\n excludeFromDomainCalculation: { type: Boolean },\n duration: {},\n events: {},\n attributes: {},\n data: {}\n },\n setup(__props: any, { expose: __expose }) {\n\nconst props = __props;\n\n// !!! This code was automatically generated. You should not change it !!!\nconst accessor = inject(componentAccessorKey)\n\n// data and required props \n\n\nconst data = computed(() => accessor.data.value ?? props.data)\n// config\nconst config = useForwardProps(props)\n\n// component declaration\nconst component = ref<Area<Datum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Area<Datum>(config.value)\n component.value?.setData(data.value)\n accessor.update(component.value)\n })\n})\n\nonUnmounted(() => {\n component.value?.destroy()\n accessor.destroy()\n})\n\nwatch(config, (curr, prev) => {\n if (!arePropsEqual(curr, prev)) {\n component.value?.setConfig(config.value)\n }\n})\n\nwatch(data, () => {\n component.value?.setData(data.value)\n})\n\n__expose({\n component\n})\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", _hoisted_1))\n}\n}\n\n})"],"names":["_hoisted_1","VisAreaSelectors","Area","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","componentAccessorKey","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","_a","onUnmounted","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":"mOAGMA,EAAa,CAAE,qBAAsB,IAQ9BC,EAAmBC,EAAK,KAAA,UAITC,EAAiBC,kBAAA,CAC3C,OAAQ,QACR,MAAO,CACL,MAAO,CAAE,KAAM,CAAC,SAAU,OAAQ,MAAO,IAAI,CAAE,EAC/C,UAAW,CAAC,EACZ,SAAU,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EAC3C,QAAS,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EAC1C,OAAQ,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EACzC,aAAc,CAAE,KAAM,OAAQ,EAC9B,EAAG,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EACpC,EAAG,CAAE,KAAM,CAAC,SAAU,OAAQ,KAAM,KAAK,CAAE,EAC3C,GAAI,CAAE,KAAM,QAAS,EACrB,OAAQ,CAAE,KAAM,CAAC,OAAQ,QAAQ,CAAE,EACnC,OAAQ,CAAE,KAAM,CAAC,OAAQ,QAAQ,CAAE,EACnC,6BAA8B,CAAE,KAAM,OAAQ,EAC9C,SAAU,CAAC,EACX,OAAQ,CAAC,EACT,WAAY,CAAC,EACb,KAAM,CAAC,CACT,EACA,MAAMC,EAAc,CAAE,OAAQC,GAAY,CAE5C,MAAMC,EAAQF,EAGRG,EAAWC,SAAOC,EAAAA,oBAAoB,EAKtCC,EAAOC,EAAS,SAAA,IAAMJ,EAAS,KAAK,OAASD,EAAM,IAAI,EAEvDM,EAASC,kBAAgBP,CAAK,EAG9BQ,EAAYC,EAAAA,MAGlBC,OAAAA,EAAAA,UAAU,IAAM,CACdC,EAAAA,SAAS,IAAM,OACbH,EAAU,MAAQ,IAAIb,EAAY,KAAAW,EAAO,KAAK,GACpCM,EAAAJ,EAAA,QAAA,MAAAI,EAAO,QAAQR,EAAK,OACrBH,EAAA,OAAOO,EAAU,KAAK,CAAA,CAChC,CAAA,CACF,EAEDK,EAAAA,YAAY,IAAM,QAChBD,EAAAJ,EAAU,QAAV,MAAAI,EAAiB,UACjBX,EAAS,QAAQ,CAAA,CAClB,EAEKa,EAAAA,MAAAR,EAAQ,CAACS,EAAMC,IAAS,OACvBC,EAAA,cAAcF,EAAMC,CAAI,IACjBJ,EAAAJ,EAAA,QAAA,MAAAI,EAAO,UAAUN,EAAO,MACpC,CACD,EAEDQ,EAAA,MAAMV,EAAM,IAAM,QACNQ,EAAAJ,EAAA,QAAA,MAAAI,EAAO,QAAQR,EAAK,MAAK,CACpC,EAEQL,EAAA,CACP,UAAAS,CAAA,CACD,EAEM,CAACU,EAAUC,KACRC,EAAW,UAAA,EAAGC,EAAAA,mBAAoB,MAAO5B,CAAU,EAE7D,CAEA,CAAC"}
1
+ {"version":3,"file":"index.cjs","sources":["../../../src/components/area/index.vue"],"sourcesContent":["<script setup lang=\"ts\" generic=\"Datum\">\n// !!! This code was automatically generated. You should not change it !!!\nimport { Area, AreaConfigInterface, NumericAccessor } from '@unovis/ts'\nimport { onMounted, onUnmounted, computed, ref, watch, nextTick, inject } from 'vue'\nimport { arePropsEqual, useForwardProps } from '../../utils/props'\nimport { componentAccessorKey } from '../../utils/context'\n\nconst accessor = inject(componentAccessorKey)\n\n// data and required props \ntype Props = AreaConfigInterface<Datum>\nconst props = defineProps<Props & { data?: Datum[] }>()\n\nconst data = computed(() => accessor.data.value ?? props.data)\n// config\nconst config = useForwardProps(props)\n\n// component declaration\nconst component = ref<Area<Datum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Area<Datum>(config.value)\n component.value?.setData(data.value)\n accessor.update(component.value)\n })\n})\n\nonUnmounted(() => {\n component.value?.destroy()\n accessor.destroy()\n})\n\nwatch(config, (curr, prev) => {\n if (!arePropsEqual(curr, prev)) {\n component.value?.setConfig(config.value)\n }\n})\n\nwatch(data, () => {\n component.value?.setData(data.value)\n})\n\ndefineExpose({\n component\n})\n</script>\n\n<script lang=\"ts\">\nexport const VisAreaSelectors = Area.selectors\n</script>\n\n<template>\n <div data-vis-component />\n</template>\n\n\n"],"names":["VisAreaSelectors","Area","accessor","inject","componentAccessorKey","props","__props","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","_a","onUnmounted","watch","curr","prev","arePropsEqual","__expose"],"mappings":"+PAkDaA,EAAmBC,EAAAA,KAAK,kVA3C/B,MAAAC,EAAWC,SAAOC,sBAAoB,EAItCC,EAAQC,EAERC,EAAOC,EAAAA,SAAS,IAAMN,EAAS,KAAK,OAASG,EAAM,IAAI,EAEvDI,EAASC,kBAAgBL,CAAK,EAG9BM,EAAYC,EAAAA,IAAiB,EAGnCC,OAAAA,EAAAA,UAAU,IAAM,CACdC,EAAAA,SAAS,IAAM,OACbH,EAAU,MAAQ,IAAIV,OAAYQ,EAAO,KAAK,GACpCM,EAAAJ,EAAA,QAAA,MAAAI,EAAO,QAAQR,EAAK,OACrBL,EAAA,OAAOS,EAAU,KAAK,CAAA,CAChC,CAAA,CACF,EAEDK,EAAAA,YAAY,IAAM,QAChBD,EAAAJ,EAAU,QAAV,MAAAI,EAAiB,UACjBb,EAAS,QAAQ,CAAA,CAClB,EAEKe,EAAAA,MAAAR,EAAQ,CAACS,EAAMC,IAAS,OACvBC,EAAA,cAAcF,EAAMC,CAAI,IACjBJ,EAAAJ,EAAA,QAAA,MAAAI,EAAO,UAAUN,EAAO,MACpC,CACD,EAEDQ,EAAA,MAAMV,EAAM,IAAM,QACNQ,EAAAJ,EAAA,QAAA,MAAAI,EAAO,QAAQR,EAAK,MAAK,CACpC,EAEYc,EAAA,CACX,UAAAV,CAAA,CACD"}
@@ -52,7 +52,7 @@ declare const _default: <Datum>(__VLS_props: any, __VLS_ctx?: {
52
52
  excludeFromDomainCalculation?: boolean;
53
53
  } & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps;
54
54
  expose(exposed: import("vue").ShallowUnwrapRef<{
55
- component: import("vue").Ref<Area<Datum>>;
55
+ component: import("vue").Ref<Area<Datum>, Area<Datum>>;
56
56
  }>): void;
57
57
  attrs: any;
58
58
  slots: {};
@@ -1,18 +1,18 @@
1
- import { defineComponent as m, inject as d, computed as y, ref as v, onMounted as f, nextTick as F, onUnmounted as x, watch as l, openBlock as b, createElementBlock as _ } from "vue";
1
+ import { defineComponent as d, inject as m, computed as v, ref as y, onMounted as f, nextTick as x, onUnmounted as _, watch as u, openBlock as F, createElementBlock as b } from "vue";
2
2
  import { Area as i } from "@unovis/ts";
3
- import { useForwardProps as g, arePropsEqual as A } from "../../utils/props.js";
4
- import { componentAccessorKey as S } from "../../utils/context.js";
5
- const h = { "data-vis-component": "" }, w = i.selectors, C = /* @__PURE__ */ m({
3
+ import { useForwardProps as h, arePropsEqual as B } from "../../utils/props.js";
4
+ import { componentAccessorKey as g } from "../../utils/context.js";
5
+ const j = { "data-vis-component": "" }, D = i.selectors, P = /* @__PURE__ */ d({
6
6
  __name: "index",
7
7
  props: {
8
- color: { type: [Function, String, Array, null] },
8
+ color: {},
9
9
  curveType: {},
10
- baseline: { type: [Function, Number, null] },
11
- opacity: { type: [Function, Number, null] },
12
- cursor: { type: [Function, String, null] },
10
+ baseline: {},
11
+ opacity: {},
12
+ cursor: {},
13
13
  minHeight1Px: { type: Boolean },
14
- x: { type: [Function, Number, null] },
15
- y: { type: [Function, Number, null, Array] },
14
+ x: {},
15
+ y: {},
16
16
  id: { type: Function },
17
17
  xScale: { type: [Object, Function] },
18
18
  yScale: { type: [Object, Function] },
@@ -22,29 +22,29 @@ const h = { "data-vis-component": "" }, w = i.selectors, C = /* @__PURE__ */ m({
22
22
  attributes: {},
23
23
  data: {}
24
24
  },
25
- setup(s, { expose: p }) {
26
- const c = s, o = d(S), n = y(() => o.data.value ?? c.data), a = g(c), t = v();
25
+ setup(l, { expose: p }) {
26
+ const o = m(g), c = l, a = v(() => o.data.value ?? c.data), n = h(c), t = y();
27
27
  return f(() => {
28
- F(() => {
28
+ x(() => {
29
29
  var e;
30
- t.value = new i(a.value), (e = t.value) == null || e.setData(n.value), o.update(t.value);
30
+ t.value = new i(n.value), (e = t.value) == null || e.setData(a.value), o.update(t.value);
31
31
  });
32
- }), x(() => {
32
+ }), _(() => {
33
33
  var e;
34
34
  (e = t.value) == null || e.destroy(), o.destroy();
35
- }), l(a, (e, r) => {
36
- var u;
37
- A(e, r) || (u = t.value) == null || u.setConfig(a.value);
38
- }), l(n, () => {
35
+ }), u(n, (e, r) => {
36
+ var s;
37
+ B(e, r) || (s = t.value) == null || s.setConfig(n.value);
38
+ }), u(a, () => {
39
39
  var e;
40
- (e = t.value) == null || e.setData(n.value);
40
+ (e = t.value) == null || e.setData(a.value);
41
41
  }), p({
42
42
  component: t
43
- }), (e, r) => (b(), _("div", h));
43
+ }), (e, r) => (F(), b("div", j));
44
44
  }
45
45
  });
46
46
  export {
47
- w as VisAreaSelectors,
48
- C as default
47
+ D as VisAreaSelectors,
48
+ P as default
49
49
  };
50
50
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../../../src/components/area/index.vue?vue&type=script&setup=true&lang.ts"],"sourcesContent":["import { defineComponent as _defineComponent } from 'vue'\nimport { openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nconst _hoisted_1 = { \"data-vis-component\": \"\" }\n\nimport { Area, AreaConfigInterface, NumericAccessor } from '@unovis/ts'\nimport { onMounted, onUnmounted, computed, ref, watch, nextTick, inject } from 'vue'\nimport { arePropsEqual, useForwardProps } from '../../utils/props'\nimport { componentAccessorKey } from '../../utils/context'\n\n\nexport const VisAreaSelectors = Area.selectors\n\ntype Props = AreaConfigInterface<Datum>\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n color: { type: [Function, String, Array, null] },\n curveType: {},\n baseline: { type: [Function, Number, null] },\n opacity: { type: [Function, Number, null] },\n cursor: { type: [Function, String, null] },\n minHeight1Px: { type: Boolean },\n x: { type: [Function, Number, null] },\n y: { type: [Function, Number, null, Array] },\n id: { type: Function },\n xScale: { type: [Object, Function] },\n yScale: { type: [Object, Function] },\n excludeFromDomainCalculation: { type: Boolean },\n duration: {},\n events: {},\n attributes: {},\n data: {}\n },\n setup(__props: any, { expose: __expose }) {\n\nconst props = __props;\n\n// !!! This code was automatically generated. You should not change it !!!\nconst accessor = inject(componentAccessorKey)\n\n// data and required props \n\n\nconst data = computed(() => accessor.data.value ?? props.data)\n// config\nconst config = useForwardProps(props)\n\n// component declaration\nconst component = ref<Area<Datum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Area<Datum>(config.value)\n component.value?.setData(data.value)\n accessor.update(component.value)\n })\n})\n\nonUnmounted(() => {\n component.value?.destroy()\n accessor.destroy()\n})\n\nwatch(config, (curr, prev) => {\n if (!arePropsEqual(curr, prev)) {\n component.value?.setConfig(config.value)\n }\n})\n\nwatch(data, () => {\n component.value?.setData(data.value)\n})\n\n__expose({\n component\n})\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", _hoisted_1))\n}\n}\n\n})"],"names":["_hoisted_1","VisAreaSelectors","Area","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","componentAccessorKey","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","_a","onUnmounted","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":";;;;AAGA,MAAMA,IAAa,EAAE,sBAAsB,MAQ9BC,IAAmBC,EAAK,WAITC,IAAiBC,gBAAAA,EAAA;AAAA,EAC3C,QAAQ;AAAA,EACR,OAAO;AAAA,IACL,OAAO,EAAE,MAAM,CAAC,UAAU,QAAQ,OAAO,IAAI,EAAE;AAAA,IAC/C,WAAW,CAAC;AAAA,IACZ,UAAU,EAAE,MAAM,CAAC,UAAU,QAAQ,IAAI,EAAE;AAAA,IAC3C,SAAS,EAAE,MAAM,CAAC,UAAU,QAAQ,IAAI,EAAE;AAAA,IAC1C,QAAQ,EAAE,MAAM,CAAC,UAAU,QAAQ,IAAI,EAAE;AAAA,IACzC,cAAc,EAAE,MAAM,QAAQ;AAAA,IAC9B,GAAG,EAAE,MAAM,CAAC,UAAU,QAAQ,IAAI,EAAE;AAAA,IACpC,GAAG,EAAE,MAAM,CAAC,UAAU,QAAQ,MAAM,KAAK,EAAE;AAAA,IAC3C,IAAI,EAAE,MAAM,SAAS;AAAA,IACrB,QAAQ,EAAE,MAAM,CAAC,QAAQ,QAAQ,EAAE;AAAA,IACnC,QAAQ,EAAE,MAAM,CAAC,QAAQ,QAAQ,EAAE;AAAA,IACnC,8BAA8B,EAAE,MAAM,QAAQ;AAAA,IAC9C,UAAU,CAAC;AAAA,IACX,QAAQ,CAAC;AAAA,IACT,YAAY,CAAC;AAAA,IACb,MAAM,CAAC;AAAA,EACT;AAAA,EACA,MAAMC,GAAc,EAAE,QAAQC,KAAY;AAE5C,UAAMC,IAAQF,GAGRG,IAAWC,EAAOC,CAAoB,GAKtCC,IAAOC,EAAS,MAAMJ,EAAS,KAAK,SAASD,EAAM,IAAI,GAEvDM,IAASC,EAAgBP,CAAK,GAG9BQ,IAAYC;AAGlB,WAAAC,EAAU,MAAM;AACd,MAAAC,EAAS,MAAM;;AACb,QAAAH,EAAU,QAAQ,IAAIb,EAAYW,EAAO,KAAK,IACpCM,IAAAJ,EAAA,UAAA,QAAAI,EAAO,QAAQR,EAAK,QACrBH,EAAA,OAAOO,EAAU,KAAK;AAAA,MAAA,CAChC;AAAA,IAAA,CACF,GAEDK,EAAY,MAAM;;AAChB,OAAAD,IAAAJ,EAAU,UAAV,QAAAI,EAAiB,WACjBX,EAAS,QAAQ;AAAA,IAAA,CAClB,GAEKa,EAAAR,GAAQ,CAACS,GAAMC,MAAS;;AAC5B,MAAKC,EAAcF,GAAMC,CAAI,MACjBJ,IAAAJ,EAAA,UAAA,QAAAI,EAAO,UAAUN,EAAO;AAAA,IACpC,CACD,GAEDQ,EAAMV,GAAM,MAAM;;AACN,OAAAQ,IAAAJ,EAAA,UAAA,QAAAI,EAAO,QAAQR,EAAK;AAAA,IAAK,CACpC,GAEQL,EAAA;AAAA,MACP,WAAAS;AAAA,IAAA,CACD,GAEM,CAACU,GAAUC,OACRC,EAAW,GAAGC,EAAoB,OAAO5B,CAAU;AAAA,EAE7D;AAEA,CAAC;"}
1
+ {"version":3,"file":"index.js","sources":["../../../src/components/area/index.vue"],"sourcesContent":["<script setup lang=\"ts\" generic=\"Datum\">\n// !!! This code was automatically generated. You should not change it !!!\nimport { Area, AreaConfigInterface, NumericAccessor } from '@unovis/ts'\nimport { onMounted, onUnmounted, computed, ref, watch, nextTick, inject } from 'vue'\nimport { arePropsEqual, useForwardProps } from '../../utils/props'\nimport { componentAccessorKey } from '../../utils/context'\n\nconst accessor = inject(componentAccessorKey)\n\n// data and required props \ntype Props = AreaConfigInterface<Datum>\nconst props = defineProps<Props & { data?: Datum[] }>()\n\nconst data = computed(() => accessor.data.value ?? props.data)\n// config\nconst config = useForwardProps(props)\n\n// component declaration\nconst component = ref<Area<Datum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Area<Datum>(config.value)\n component.value?.setData(data.value)\n accessor.update(component.value)\n })\n})\n\nonUnmounted(() => {\n component.value?.destroy()\n accessor.destroy()\n})\n\nwatch(config, (curr, prev) => {\n if (!arePropsEqual(curr, prev)) {\n component.value?.setConfig(config.value)\n }\n})\n\nwatch(data, () => {\n component.value?.setData(data.value)\n})\n\ndefineExpose({\n component\n})\n</script>\n\n<script lang=\"ts\">\nexport const VisAreaSelectors = Area.selectors\n</script>\n\n<template>\n <div data-vis-component />\n</template>\n\n\n"],"names":["VisAreaSelectors","Area","accessor","inject","componentAccessorKey","props","__props","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","_a","onUnmounted","watch","curr","prev","arePropsEqual","__expose"],"mappings":";;;;wCAkDaA,IAAmBC,EAAK;;;;;;;;;;;;;;;;;;;;;AA3C/B,UAAAC,IAAWC,EAAOC,CAAoB,GAItCC,IAAQC,GAERC,IAAOC,EAAS,MAAMN,EAAS,KAAK,SAASG,EAAM,IAAI,GAEvDI,IAASC,EAAgBL,CAAK,GAG9BM,IAAYC,EAAiB;AAGnC,WAAAC,EAAU,MAAM;AACd,MAAAC,EAAS,MAAM;;AACb,QAAAH,EAAU,QAAQ,IAAIV,EAAYQ,EAAO,KAAK,IACpCM,IAAAJ,EAAA,UAAA,QAAAI,EAAO,QAAQR,EAAK,QACrBL,EAAA,OAAOS,EAAU,KAAK;AAAA,MAAA,CAChC;AAAA,IAAA,CACF,GAEDK,EAAY,MAAM;;AAChB,OAAAD,IAAAJ,EAAU,UAAV,QAAAI,EAAiB,WACjBb,EAAS,QAAQ;AAAA,IAAA,CAClB,GAEKe,EAAAR,GAAQ,CAACS,GAAMC,MAAS;;AAC5B,MAAKC,EAAcF,GAAMC,CAAI,MACjBJ,IAAAJ,EAAA,UAAA,QAAAI,EAAO,UAAUN,EAAO;AAAA,IACpC,CACD,GAEDQ,EAAMV,GAAM,MAAM;;AACN,OAAAQ,IAAAJ,EAAA,UAAA,QAAAI,EAAO,QAAQR,EAAK;AAAA,IAAK,CACpC,GAEYc,EAAA;AAAA,MACX,WAAAV;AAAA,IAAA,CACD;;;"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("vue"),u=require("@unovis/ts"),r=require("../../utils/props.cjs"),y=require("../../utils/context.cjs"),x={"data-vis-axis":""},k=u.Axis.selectors,m=t.defineComponent({__name:"index",props:{position:{},type:{},fullSize:{type:Boolean},label:{},labelFontSize:{},labelMargin:{},labelColor:{},gridLine:{type:Boolean},tickLine:{type:Boolean},domainLine:{type:Boolean},minMaxTicksOnly:{type:Boolean},minMaxTicksOnlyWhenWidthIsLess:{},tickFormat:{type:Function},tickValues:{},numTicks:{},tickTextFitMode:{},tickTextWidth:{},tickTextSeparator:{},tickTextForceWordBreak:{type:Boolean},tickTextTrimType:{},tickTextFontSize:{},tickTextAlign:{},tickTextColor:{},tickTextAngle:{},tickTextHideOverlapping:{type:Boolean},tickPadding:{},x:{type:[Function,Number,null]},y:{type:[Function,Number,null,Array]},id:{type:Function},color:{type:[Function,String,Array,null]},xScale:{type:[Object,Function]},yScale:{type:[Object,Function]},excludeFromDomainCalculation:{type:Boolean},duration:{},events:{},attributes:{},data:{}},setup(p,{expose:d}){const n=p,i=t.inject(y.axisAccessorKey),a=t.computed(()=>i.data.value??n.data),c=r.useForwardProps(n),o=t.ref();return t.onMounted(()=>{t.nextTick(()=>{var e;o.value=new u.Axis(c.value),(e=o.value)==null||e.setData(a.value),i.update(o.value)})}),t.onUnmounted(()=>{var e;(e=o.value)==null||e.destroy(),i.destroy(n.type)}),t.watch(c,(e,l)=>{var s;r.arePropsEqual(e,l)||(s=o.value)==null||s.setConfig(c.value)}),t.watch(a,()=>{var e;(e=o.value)==null||e.setData(a.value)}),d({component:o}),(e,l)=>(t.openBlock(),t.createElementBlock("div",x))}});exports.VisAxisSelectors=k;exports.default=m;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("vue"),u=require("@unovis/ts"),r=require("../../utils/props.cjs"),x=require("../../utils/context.cjs"),y={"data-vis-axis":""},k=u.Axis.selectors,v=t.defineComponent({__name:"index",props:{position:{},type:{},fullSize:{type:Boolean},label:{},labelFontSize:{},labelMargin:{},labelColor:{},gridLine:{type:Boolean},tickLine:{type:Boolean},domainLine:{type:Boolean},minMaxTicksOnly:{type:Boolean},minMaxTicksOnlyWhenWidthIsLess:{},tickFormat:{type:Function},tickValues:{},numTicks:{},tickTextFitMode:{},tickTextWidth:{},tickTextSeparator:{},tickTextForceWordBreak:{type:Boolean},tickTextTrimType:{},tickTextFontSize:{},tickTextAlign:{},tickTextColor:{},tickTextAngle:{},tickTextHideOverlapping:{type:Boolean},tickPadding:{},x:{},y:{},id:{type:Function},color:{},xScale:{type:[Object,Function]},yScale:{type:[Object,Function]},excludeFromDomainCalculation:{type:Boolean},duration:{},events:{},attributes:{},data:{}},setup(p,{expose:d}){const n=t.inject(x.axisAccessorKey),i=p,a=t.computed(()=>n.data.value??i.data),c=r.useForwardProps(i),o=t.ref();return t.onMounted(()=>{t.nextTick(()=>{var e;o.value=new u.Axis(c.value),(e=o.value)==null||e.setData(a.value),n.update(o.value)})}),t.onUnmounted(()=>{var e;(e=o.value)==null||e.destroy(),n.destroy(i.type)}),t.watch(c,(e,s)=>{var l;r.arePropsEqual(e,s)||(l=o.value)==null||l.setConfig(c.value)}),t.watch(a,()=>{var e;(e=o.value)==null||e.setData(a.value)}),d({component:o}),(e,s)=>(t.openBlock(),t.createElementBlock("div",y))}});exports.VisAxisSelectors=k;exports.default=v;
2
2
  //# sourceMappingURL=index.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs","sources":["../../../src/components/axis/index.vue?vue&type=script&setup=true&lang.ts"],"sourcesContent":["import { defineComponent as _defineComponent } from 'vue'\nimport { openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nconst _hoisted_1 = { \"data-vis-axis\": \"\" }\n\nimport { Axis, AxisConfigInterface } from '@unovis/ts'\nimport { onMounted, onUnmounted, computed, ref, watch, nextTick, inject } from 'vue'\nimport { arePropsEqual, useForwardProps } from '../../utils/props'\nimport { axisAccessorKey } from '../../utils/context'\n\n\nexport const VisAxisSelectors = Axis.selectors\n\ntype Props = AxisConfigInterface<Datum>\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n position: {},\n type: {},\n fullSize: { type: Boolean },\n label: {},\n labelFontSize: {},\n labelMargin: {},\n labelColor: {},\n gridLine: { type: Boolean },\n tickLine: { type: Boolean },\n domainLine: { type: Boolean },\n minMaxTicksOnly: { type: Boolean },\n minMaxTicksOnlyWhenWidthIsLess: {},\n tickFormat: { type: Function },\n tickValues: {},\n numTicks: {},\n tickTextFitMode: {},\n tickTextWidth: {},\n tickTextSeparator: {},\n tickTextForceWordBreak: { type: Boolean },\n tickTextTrimType: {},\n tickTextFontSize: {},\n tickTextAlign: {},\n tickTextColor: {},\n tickTextAngle: {},\n tickTextHideOverlapping: { type: Boolean },\n tickPadding: {},\n x: { type: [Function, Number, null] },\n y: { type: [Function, Number, null, Array] },\n id: { type: Function },\n color: { type: [Function, String, Array, null] },\n xScale: { type: [Object, Function] },\n yScale: { type: [Object, Function] },\n excludeFromDomainCalculation: { type: Boolean },\n duration: {},\n events: {},\n attributes: {},\n data: {}\n },\n setup(__props: any, { expose: __expose }) {\n\nconst props = __props;\n\n// !!! This code was automatically generated. You should not change it !!!\nconst accessor = inject(axisAccessorKey)\n\n// data and required props \n\n\nconst data = computed(() => accessor.data.value ?? props.data)\n// config\nconst config = useForwardProps(props)\n\n// component declaration\nconst component = ref<Axis<Datum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Axis<Datum>(config.value)\n component.value?.setData(data.value)\n accessor.update(component.value)\n })\n})\n\nonUnmounted(() => {\n component.value?.destroy()\n accessor.destroy(props.type)\n})\n\nwatch(config, (curr, prev) => {\n if (!arePropsEqual(curr, prev)) {\n component.value?.setConfig(config.value)\n }\n})\n\nwatch(data, () => {\n component.value?.setData(data.value)\n})\n\n__expose({\n component\n})\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", _hoisted_1))\n}\n}\n\n})"],"names":["_hoisted_1","VisAxisSelectors","Axis","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","axisAccessorKey","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","_a","onUnmounted","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":"mOAGMA,EAAa,CAAE,gBAAiB,IAQzBC,EAAmBC,EAAK,KAAA,UAITC,EAAiBC,kBAAA,CAC3C,OAAQ,QACR,MAAO,CACL,SAAU,CAAC,EACX,KAAM,CAAC,EACP,SAAU,CAAE,KAAM,OAAQ,EAC1B,MAAO,CAAC,EACR,cAAe,CAAC,EAChB,YAAa,CAAC,EACd,WAAY,CAAC,EACb,SAAU,CAAE,KAAM,OAAQ,EAC1B,SAAU,CAAE,KAAM,OAAQ,EAC1B,WAAY,CAAE,KAAM,OAAQ,EAC5B,gBAAiB,CAAE,KAAM,OAAQ,EACjC,+BAAgC,CAAC,EACjC,WAAY,CAAE,KAAM,QAAS,EAC7B,WAAY,CAAC,EACb,SAAU,CAAC,EACX,gBAAiB,CAAC,EAClB,cAAe,CAAC,EAChB,kBAAmB,CAAC,EACpB,uBAAwB,CAAE,KAAM,OAAQ,EACxC,iBAAkB,CAAC,EACnB,iBAAkB,CAAC,EACnB,cAAe,CAAC,EAChB,cAAe,CAAC,EAChB,cAAe,CAAC,EAChB,wBAAyB,CAAE,KAAM,OAAQ,EACzC,YAAa,CAAC,EACd,EAAG,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EACpC,EAAG,CAAE,KAAM,CAAC,SAAU,OAAQ,KAAM,KAAK,CAAE,EAC3C,GAAI,CAAE,KAAM,QAAS,EACrB,MAAO,CAAE,KAAM,CAAC,SAAU,OAAQ,MAAO,IAAI,CAAE,EAC/C,OAAQ,CAAE,KAAM,CAAC,OAAQ,QAAQ,CAAE,EACnC,OAAQ,CAAE,KAAM,CAAC,OAAQ,QAAQ,CAAE,EACnC,6BAA8B,CAAE,KAAM,OAAQ,EAC9C,SAAU,CAAC,EACX,OAAQ,CAAC,EACT,WAAY,CAAC,EACb,KAAM,CAAC,CACT,EACA,MAAMC,EAAc,CAAE,OAAQC,GAAY,CAE5C,MAAMC,EAAQF,EAGRG,EAAWC,SAAOC,EAAAA,eAAe,EAKjCC,EAAOC,EAAS,SAAA,IAAMJ,EAAS,KAAK,OAASD,EAAM,IAAI,EAEvDM,EAASC,kBAAgBP,CAAK,EAG9BQ,EAAYC,EAAAA,MAGlBC,OAAAA,EAAAA,UAAU,IAAM,CACdC,EAAAA,SAAS,IAAM,OACbH,EAAU,MAAQ,IAAIb,EAAY,KAAAW,EAAO,KAAK,GACpCM,EAAAJ,EAAA,QAAA,MAAAI,EAAO,QAAQR,EAAK,OACrBH,EAAA,OAAOO,EAAU,KAAK,CAAA,CAChC,CAAA,CACF,EAEDK,EAAAA,YAAY,IAAM,QAChBD,EAAAJ,EAAU,QAAV,MAAAI,EAAiB,UACRX,EAAA,QAAQD,EAAM,IAAI,CAAA,CAC5B,EAEKc,EAAAA,MAAAR,EAAQ,CAACS,EAAMC,IAAS,OACvBC,EAAA,cAAcF,EAAMC,CAAI,IACjBJ,EAAAJ,EAAA,QAAA,MAAAI,EAAO,UAAUN,EAAO,MACpC,CACD,EAEDQ,EAAA,MAAMV,EAAM,IAAM,QACNQ,EAAAJ,EAAA,QAAA,MAAAI,EAAO,QAAQR,EAAK,MAAK,CACpC,EAEQL,EAAA,CACP,UAAAS,CAAA,CACD,EAEM,CAACU,EAAUC,KACRC,EAAW,UAAA,EAAGC,EAAAA,mBAAoB,MAAO5B,CAAU,EAE7D,CAEA,CAAC"}
1
+ {"version":3,"file":"index.cjs","sources":["../../../src/components/axis/index.vue"],"sourcesContent":["<script setup lang=\"ts\" generic=\"Datum\">\n// !!! This code was automatically generated. You should not change it !!!\nimport { Axis, AxisConfigInterface } from '@unovis/ts'\nimport { onMounted, onUnmounted, computed, ref, watch, nextTick, inject } from 'vue'\nimport { arePropsEqual, useForwardProps } from '../../utils/props'\nimport { axisAccessorKey } from '../../utils/context'\n\nconst accessor = inject(axisAccessorKey)\n\n// data and required props \ntype Props = AxisConfigInterface<Datum>\nconst props = defineProps<Props & { data?: Datum[] }>()\n\nconst data = computed(() => accessor.data.value ?? props.data)\n// config\nconst config = useForwardProps(props)\n\n// component declaration\nconst component = ref<Axis<Datum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Axis<Datum>(config.value)\n component.value?.setData(data.value)\n accessor.update(component.value)\n })\n})\n\nonUnmounted(() => {\n component.value?.destroy()\n accessor.destroy(props.type)\n})\n\nwatch(config, (curr, prev) => {\n if (!arePropsEqual(curr, prev)) {\n component.value?.setConfig(config.value)\n }\n})\n\nwatch(data, () => {\n component.value?.setData(data.value)\n})\n\ndefineExpose({\n component\n})\n</script>\n\n<script lang=\"ts\">\nexport const VisAxisSelectors = Axis.selectors\n</script>\n\n<template>\n <div data-vis-axis />\n</template>\n\n\n"],"names":["VisAxisSelectors","Axis","accessor","inject","axisAccessorKey","props","__props","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","_a","onUnmounted","watch","curr","prev","arePropsEqual","__expose"],"mappings":"0PAkDaA,EAAmBC,EAAAA,KAAK,2xBA3C/B,MAAAC,EAAWC,SAAOC,iBAAe,EAIjCC,EAAQC,EAERC,EAAOC,EAAAA,SAAS,IAAMN,EAAS,KAAK,OAASG,EAAM,IAAI,EAEvDI,EAASC,kBAAgBL,CAAK,EAG9BM,EAAYC,EAAAA,IAAiB,EAGnCC,OAAAA,EAAAA,UAAU,IAAM,CACdC,EAAAA,SAAS,IAAM,OACbH,EAAU,MAAQ,IAAIV,OAAYQ,EAAO,KAAK,GACpCM,EAAAJ,EAAA,QAAA,MAAAI,EAAO,QAAQR,EAAK,OACrBL,EAAA,OAAOS,EAAU,KAAK,CAAA,CAChC,CAAA,CACF,EAEDK,EAAAA,YAAY,IAAM,QAChBD,EAAAJ,EAAU,QAAV,MAAAI,EAAiB,UACRb,EAAA,QAAQG,EAAM,IAAI,CAAA,CAC5B,EAEKY,EAAAA,MAAAR,EAAQ,CAACS,EAAMC,IAAS,OACvBC,EAAA,cAAcF,EAAMC,CAAI,IACjBJ,EAAAJ,EAAA,QAAA,MAAAI,EAAO,UAAUN,EAAO,MACpC,CACD,EAEDQ,EAAA,MAAMV,EAAM,IAAM,QACNQ,EAAAJ,EAAA,QAAA,MAAAI,EAAO,QAAQR,EAAK,MAAK,CACpC,EAEYc,EAAA,CACX,UAAAV,CAAA,CACD"}
@@ -73,7 +73,7 @@ declare const _default: <Datum>(__VLS_props: any, __VLS_ctx?: {
73
73
  tickPadding?: number;
74
74
  } & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps;
75
75
  expose(exposed: import("vue").ShallowUnwrapRef<{
76
- component: import("vue").Ref<Axis<Datum>>;
76
+ component: import("vue").Ref<Axis<Datum>, Axis<Datum>>;
77
77
  }>): void;
78
78
  attrs: any;
79
79
  slots: {};
@@ -1,8 +1,8 @@
1
- import { defineComponent as d, inject as y, computed as m, ref as x, onMounted as k, nextTick as T, onUnmounted as v, watch as r, openBlock as F, createElementBlock as f } from "vue";
2
- import { Axis as s } from "@unovis/ts";
3
- import { useForwardProps as B, arePropsEqual as b } from "../../utils/props.js";
4
- import { axisAccessorKey as g } from "../../utils/context.js";
5
- const S = { "data-vis-axis": "" }, M = s.selectors, O = /* @__PURE__ */ d({
1
+ import { defineComponent as d, inject as x, computed as m, ref as y, onMounted as k, nextTick as T, onUnmounted as v, watch as s, openBlock as f, createElementBlock as B } from "vue";
2
+ import { Axis as r } from "@unovis/ts";
3
+ import { useForwardProps as F, arePropsEqual as g } from "../../utils/props.js";
4
+ import { axisAccessorKey as _ } from "../../utils/context.js";
5
+ const b = { "data-vis-axis": "" }, M = r.selectors, O = /* @__PURE__ */ d({
6
6
  __name: "index",
7
7
  props: {
8
8
  position: {},
@@ -31,10 +31,10 @@ const S = { "data-vis-axis": "" }, M = s.selectors, O = /* @__PURE__ */ d({
31
31
  tickTextAngle: {},
32
32
  tickTextHideOverlapping: { type: Boolean },
33
33
  tickPadding: {},
34
- x: { type: [Function, Number, null] },
35
- y: { type: [Function, Number, null, Array] },
34
+ x: {},
35
+ y: {},
36
36
  id: { type: Function },
37
- color: { type: [Function, String, Array, null] },
37
+ color: {},
38
38
  xScale: { type: [Object, Function] },
39
39
  yScale: { type: [Object, Function] },
40
40
  excludeFromDomainCalculation: { type: Boolean },
@@ -44,24 +44,24 @@ const S = { "data-vis-axis": "" }, M = s.selectors, O = /* @__PURE__ */ d({
44
44
  data: {}
45
45
  },
46
46
  setup(p, { expose: u }) {
47
- const o = p, n = y(g), a = m(() => n.data.value ?? o.data), i = B(o), t = x();
47
+ const o = x(_), a = p, n = m(() => o.data.value ?? a.data), i = F(a), t = y();
48
48
  return k(() => {
49
49
  T(() => {
50
50
  var e;
51
- t.value = new s(i.value), (e = t.value) == null || e.setData(a.value), n.update(t.value);
51
+ t.value = new r(i.value), (e = t.value) == null || e.setData(n.value), o.update(t.value);
52
52
  });
53
53
  }), v(() => {
54
54
  var e;
55
- (e = t.value) == null || e.destroy(), n.destroy(o.type);
56
- }), r(i, (e, c) => {
55
+ (e = t.value) == null || e.destroy(), o.destroy(a.type);
56
+ }), s(i, (e, c) => {
57
57
  var l;
58
- b(e, c) || (l = t.value) == null || l.setConfig(i.value);
59
- }), r(a, () => {
58
+ g(e, c) || (l = t.value) == null || l.setConfig(i.value);
59
+ }), s(n, () => {
60
60
  var e;
61
- (e = t.value) == null || e.setData(a.value);
61
+ (e = t.value) == null || e.setData(n.value);
62
62
  }), u({
63
63
  component: t
64
- }), (e, c) => (F(), f("div", S));
64
+ }), (e, c) => (f(), B("div", b));
65
65
  }
66
66
  });
67
67
  export {
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../../../src/components/axis/index.vue?vue&type=script&setup=true&lang.ts"],"sourcesContent":["import { defineComponent as _defineComponent } from 'vue'\nimport { openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nconst _hoisted_1 = { \"data-vis-axis\": \"\" }\n\nimport { Axis, AxisConfigInterface } from '@unovis/ts'\nimport { onMounted, onUnmounted, computed, ref, watch, nextTick, inject } from 'vue'\nimport { arePropsEqual, useForwardProps } from '../../utils/props'\nimport { axisAccessorKey } from '../../utils/context'\n\n\nexport const VisAxisSelectors = Axis.selectors\n\ntype Props = AxisConfigInterface<Datum>\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n position: {},\n type: {},\n fullSize: { type: Boolean },\n label: {},\n labelFontSize: {},\n labelMargin: {},\n labelColor: {},\n gridLine: { type: Boolean },\n tickLine: { type: Boolean },\n domainLine: { type: Boolean },\n minMaxTicksOnly: { type: Boolean },\n minMaxTicksOnlyWhenWidthIsLess: {},\n tickFormat: { type: Function },\n tickValues: {},\n numTicks: {},\n tickTextFitMode: {},\n tickTextWidth: {},\n tickTextSeparator: {},\n tickTextForceWordBreak: { type: Boolean },\n tickTextTrimType: {},\n tickTextFontSize: {},\n tickTextAlign: {},\n tickTextColor: {},\n tickTextAngle: {},\n tickTextHideOverlapping: { type: Boolean },\n tickPadding: {},\n x: { type: [Function, Number, null] },\n y: { type: [Function, Number, null, Array] },\n id: { type: Function },\n color: { type: [Function, String, Array, null] },\n xScale: { type: [Object, Function] },\n yScale: { type: [Object, Function] },\n excludeFromDomainCalculation: { type: Boolean },\n duration: {},\n events: {},\n attributes: {},\n data: {}\n },\n setup(__props: any, { expose: __expose }) {\n\nconst props = __props;\n\n// !!! This code was automatically generated. You should not change it !!!\nconst accessor = inject(axisAccessorKey)\n\n// data and required props \n\n\nconst data = computed(() => accessor.data.value ?? props.data)\n// config\nconst config = useForwardProps(props)\n\n// component declaration\nconst component = ref<Axis<Datum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Axis<Datum>(config.value)\n component.value?.setData(data.value)\n accessor.update(component.value)\n })\n})\n\nonUnmounted(() => {\n component.value?.destroy()\n accessor.destroy(props.type)\n})\n\nwatch(config, (curr, prev) => {\n if (!arePropsEqual(curr, prev)) {\n component.value?.setConfig(config.value)\n }\n})\n\nwatch(data, () => {\n component.value?.setData(data.value)\n})\n\n__expose({\n component\n})\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", _hoisted_1))\n}\n}\n\n})"],"names":["_hoisted_1","VisAxisSelectors","Axis","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","axisAccessorKey","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","_a","onUnmounted","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":";;;;AAGA,MAAMA,IAAa,EAAE,iBAAiB,MAQzBC,IAAmBC,EAAK,WAITC,IAAiBC,gBAAAA,EAAA;AAAA,EAC3C,QAAQ;AAAA,EACR,OAAO;AAAA,IACL,UAAU,CAAC;AAAA,IACX,MAAM,CAAC;AAAA,IACP,UAAU,EAAE,MAAM,QAAQ;AAAA,IAC1B,OAAO,CAAC;AAAA,IACR,eAAe,CAAC;AAAA,IAChB,aAAa,CAAC;AAAA,IACd,YAAY,CAAC;AAAA,IACb,UAAU,EAAE,MAAM,QAAQ;AAAA,IAC1B,UAAU,EAAE,MAAM,QAAQ;AAAA,IAC1B,YAAY,EAAE,MAAM,QAAQ;AAAA,IAC5B,iBAAiB,EAAE,MAAM,QAAQ;AAAA,IACjC,gCAAgC,CAAC;AAAA,IACjC,YAAY,EAAE,MAAM,SAAS;AAAA,IAC7B,YAAY,CAAC;AAAA,IACb,UAAU,CAAC;AAAA,IACX,iBAAiB,CAAC;AAAA,IAClB,eAAe,CAAC;AAAA,IAChB,mBAAmB,CAAC;AAAA,IACpB,wBAAwB,EAAE,MAAM,QAAQ;AAAA,IACxC,kBAAkB,CAAC;AAAA,IACnB,kBAAkB,CAAC;AAAA,IACnB,eAAe,CAAC;AAAA,IAChB,eAAe,CAAC;AAAA,IAChB,eAAe,CAAC;AAAA,IAChB,yBAAyB,EAAE,MAAM,QAAQ;AAAA,IACzC,aAAa,CAAC;AAAA,IACd,GAAG,EAAE,MAAM,CAAC,UAAU,QAAQ,IAAI,EAAE;AAAA,IACpC,GAAG,EAAE,MAAM,CAAC,UAAU,QAAQ,MAAM,KAAK,EAAE;AAAA,IAC3C,IAAI,EAAE,MAAM,SAAS;AAAA,IACrB,OAAO,EAAE,MAAM,CAAC,UAAU,QAAQ,OAAO,IAAI,EAAE;AAAA,IAC/C,QAAQ,EAAE,MAAM,CAAC,QAAQ,QAAQ,EAAE;AAAA,IACnC,QAAQ,EAAE,MAAM,CAAC,QAAQ,QAAQ,EAAE;AAAA,IACnC,8BAA8B,EAAE,MAAM,QAAQ;AAAA,IAC9C,UAAU,CAAC;AAAA,IACX,QAAQ,CAAC;AAAA,IACT,YAAY,CAAC;AAAA,IACb,MAAM,CAAC;AAAA,EACT;AAAA,EACA,MAAMC,GAAc,EAAE,QAAQC,KAAY;AAE5C,UAAMC,IAAQF,GAGRG,IAAWC,EAAOC,CAAe,GAKjCC,IAAOC,EAAS,MAAMJ,EAAS,KAAK,SAASD,EAAM,IAAI,GAEvDM,IAASC,EAAgBP,CAAK,GAG9BQ,IAAYC;AAGlB,WAAAC,EAAU,MAAM;AACd,MAAAC,EAAS,MAAM;;AACb,QAAAH,EAAU,QAAQ,IAAIb,EAAYW,EAAO,KAAK,IACpCM,IAAAJ,EAAA,UAAA,QAAAI,EAAO,QAAQR,EAAK,QACrBH,EAAA,OAAOO,EAAU,KAAK;AAAA,MAAA,CAChC;AAAA,IAAA,CACF,GAEDK,EAAY,MAAM;;AAChB,OAAAD,IAAAJ,EAAU,UAAV,QAAAI,EAAiB,WACRX,EAAA,QAAQD,EAAM,IAAI;AAAA,IAAA,CAC5B,GAEKc,EAAAR,GAAQ,CAACS,GAAMC,MAAS;;AAC5B,MAAKC,EAAcF,GAAMC,CAAI,MACjBJ,IAAAJ,EAAA,UAAA,QAAAI,EAAO,UAAUN,EAAO;AAAA,IACpC,CACD,GAEDQ,EAAMV,GAAM,MAAM;;AACN,OAAAQ,IAAAJ,EAAA,UAAA,QAAAI,EAAO,QAAQR,EAAK;AAAA,IAAK,CACpC,GAEQL,EAAA;AAAA,MACP,WAAAS;AAAA,IAAA,CACD,GAEM,CAACU,GAAUC,OACRC,EAAW,GAAGC,EAAoB,OAAO5B,CAAU;AAAA,EAE7D;AAEA,CAAC;"}
1
+ {"version":3,"file":"index.js","sources":["../../../src/components/axis/index.vue"],"sourcesContent":["<script setup lang=\"ts\" generic=\"Datum\">\n// !!! This code was automatically generated. You should not change it !!!\nimport { Axis, AxisConfigInterface } from '@unovis/ts'\nimport { onMounted, onUnmounted, computed, ref, watch, nextTick, inject } from 'vue'\nimport { arePropsEqual, useForwardProps } from '../../utils/props'\nimport { axisAccessorKey } from '../../utils/context'\n\nconst accessor = inject(axisAccessorKey)\n\n// data and required props \ntype Props = AxisConfigInterface<Datum>\nconst props = defineProps<Props & { data?: Datum[] }>()\n\nconst data = computed(() => accessor.data.value ?? props.data)\n// config\nconst config = useForwardProps(props)\n\n// component declaration\nconst component = ref<Axis<Datum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Axis<Datum>(config.value)\n component.value?.setData(data.value)\n accessor.update(component.value)\n })\n})\n\nonUnmounted(() => {\n component.value?.destroy()\n accessor.destroy(props.type)\n})\n\nwatch(config, (curr, prev) => {\n if (!arePropsEqual(curr, prev)) {\n component.value?.setConfig(config.value)\n }\n})\n\nwatch(data, () => {\n component.value?.setData(data.value)\n})\n\ndefineExpose({\n component\n})\n</script>\n\n<script lang=\"ts\">\nexport const VisAxisSelectors = Axis.selectors\n</script>\n\n<template>\n <div data-vis-axis />\n</template>\n\n\n"],"names":["VisAxisSelectors","Axis","accessor","inject","axisAccessorKey","props","__props","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","_a","onUnmounted","watch","curr","prev","arePropsEqual","__expose"],"mappings":";;;;mCAkDaA,IAAmBC,EAAK;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA3C/B,UAAAC,IAAWC,EAAOC,CAAe,GAIjCC,IAAQC,GAERC,IAAOC,EAAS,MAAMN,EAAS,KAAK,SAASG,EAAM,IAAI,GAEvDI,IAASC,EAAgBL,CAAK,GAG9BM,IAAYC,EAAiB;AAGnC,WAAAC,EAAU,MAAM;AACd,MAAAC,EAAS,MAAM;;AACb,QAAAH,EAAU,QAAQ,IAAIV,EAAYQ,EAAO,KAAK,IACpCM,IAAAJ,EAAA,UAAA,QAAAI,EAAO,QAAQR,EAAK,QACrBL,EAAA,OAAOS,EAAU,KAAK;AAAA,MAAA,CAChC;AAAA,IAAA,CACF,GAEDK,EAAY,MAAM;;AAChB,OAAAD,IAAAJ,EAAU,UAAV,QAAAI,EAAiB,WACRb,EAAA,QAAQG,EAAM,IAAI;AAAA,IAAA,CAC5B,GAEKY,EAAAR,GAAQ,CAACS,GAAMC,MAAS;;AAC5B,MAAKC,EAAcF,GAAMC,CAAI,MACjBJ,IAAAJ,EAAA,UAAA,QAAAI,EAAO,UAAUN,EAAO;AAAA,IACpC,CACD,GAEDQ,EAAMV,GAAM,MAAM;;AACN,OAAAQ,IAAAJ,EAAA,UAAA,QAAAI,EAAO,QAAQR,EAAK;AAAA,IAAK,CACpC,GAEYc,EAAA;AAAA,MACX,WAAAV;AAAA,IAAA,CACD;;;"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("vue"),l=require("@unovis/ts"),i=require("../../utils/props.cjs"),y=require("../../utils/context.cjs"),v={"data-vis-component":""},h=l.Brush.selectors,m=t.defineComponent({__name:"index",props:{onBrush:{type:Function},onBrushStart:{type:Function},onBrushMove:{type:Function},onBrushEnd:{type:Function},handleWidth:{},selection:{},draggable:{type:Boolean},handlePosition:{},selectionMinLength:{},x:{type:[Function,Number,null]},y:{type:[Function,Number,null,Array]},id:{type:Function},color:{type:[Function,String,Array,null]},xScale:{type:[Object,Function]},yScale:{type:[Object,Function]},excludeFromDomainCalculation:{type:Boolean},duration:{},events:{},attributes:{},data:{}},setup(p,{expose:d}){const a=p,o=t.inject(y.componentAccessorKey),u=t.computed(()=>o.data.value??a.data),c=i.useForwardProps(a),n=t.ref();return t.onMounted(()=>{t.nextTick(()=>{var e;n.value=new l.Brush(c.value),(e=n.value)==null||e.setData(u.value),o.update(n.value)})}),t.onUnmounted(()=>{var e;(e=n.value)==null||e.destroy(),o.destroy()}),t.watch(c,(e,s)=>{var r;i.arePropsEqual(e,s)||(r=n.value)==null||r.setConfig(c.value)}),t.watch(u,()=>{var e;(e=n.value)==null||e.setData(u.value)}),d({component:n}),(e,s)=>(t.openBlock(),t.createElementBlock("div",v))}});exports.VisBrushSelectors=h;exports.default=m;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("vue"),l=require("@unovis/ts"),i=require("../../utils/props.cjs"),v=require("../../utils/context.cjs"),h={"data-vis-component":""},y=l.Brush.selectors,m=t.defineComponent({__name:"index",props:{onBrush:{type:Function},onBrushStart:{type:Function},onBrushMove:{type:Function},onBrushEnd:{type:Function},handleWidth:{},selection:{},draggable:{type:Boolean},handlePosition:{},selectionMinLength:{},x:{},y:{},id:{type:Function},color:{},xScale:{type:[Object,Function]},yScale:{type:[Object,Function]},excludeFromDomainCalculation:{type:Boolean},duration:{},events:{},attributes:{},data:{}},setup(d,{expose:p}){const n=t.inject(v.componentAccessorKey),c=d,s=t.computed(()=>n.data.value??c.data),a=i.useForwardProps(c),o=t.ref();return t.onMounted(()=>{t.nextTick(()=>{var e;o.value=new l.Brush(a.value),(e=o.value)==null||e.setData(s.value),n.update(o.value)})}),t.onUnmounted(()=>{var e;(e=o.value)==null||e.destroy(),n.destroy()}),t.watch(a,(e,u)=>{var r;i.arePropsEqual(e,u)||(r=o.value)==null||r.setConfig(a.value)}),t.watch(s,()=>{var e;(e=o.value)==null||e.setData(s.value)}),p({component:o}),(e,u)=>(t.openBlock(),t.createElementBlock("div",h))}});exports.VisBrushSelectors=y;exports.default=m;
2
2
  //# sourceMappingURL=index.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs","sources":["../../../src/components/brush/index.vue?vue&type=script&setup=true&lang.ts"],"sourcesContent":["import { defineComponent as _defineComponent } from 'vue'\nimport { openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nconst _hoisted_1 = { \"data-vis-component\": \"\" }\n\nimport { Brush, BrushConfigInterface } from '@unovis/ts'\nimport { onMounted, onUnmounted, computed, ref, watch, nextTick, inject } from 'vue'\nimport { arePropsEqual, useForwardProps } from '../../utils/props'\nimport { componentAccessorKey } from '../../utils/context'\n\n\nexport const VisBrushSelectors = Brush.selectors\n\ntype Props = BrushConfigInterface<Datum>\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n onBrush: { type: Function },\n onBrushStart: { type: Function },\n onBrushMove: { type: Function },\n onBrushEnd: { type: Function },\n handleWidth: {},\n selection: {},\n draggable: { type: Boolean },\n handlePosition: {},\n selectionMinLength: {},\n x: { type: [Function, Number, null] },\n y: { type: [Function, Number, null, Array] },\n id: { type: Function },\n color: { type: [Function, String, Array, null] },\n xScale: { type: [Object, Function] },\n yScale: { type: [Object, Function] },\n excludeFromDomainCalculation: { type: Boolean },\n duration: {},\n events: {},\n attributes: {},\n data: {}\n },\n setup(__props: any, { expose: __expose }) {\n\nconst props = __props;\n\n// !!! This code was automatically generated. You should not change it !!!\nconst accessor = inject(componentAccessorKey)\n\n// data and required props \n\n\nconst data = computed(() => accessor.data.value ?? props.data)\n// config\nconst config = useForwardProps(props)\n\n// component declaration\nconst component = ref<Brush<Datum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Brush<Datum>(config.value)\n component.value?.setData(data.value)\n accessor.update(component.value)\n })\n})\n\nonUnmounted(() => {\n component.value?.destroy()\n accessor.destroy()\n})\n\nwatch(config, (curr, prev) => {\n if (!arePropsEqual(curr, prev)) {\n component.value?.setConfig(config.value)\n }\n})\n\nwatch(data, () => {\n component.value?.setData(data.value)\n})\n\n__expose({\n component\n})\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", _hoisted_1))\n}\n}\n\n})"],"names":["_hoisted_1","VisBrushSelectors","Brush","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","componentAccessorKey","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","_a","onUnmounted","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":"mOAGMA,EAAa,CAAE,qBAAsB,IAQ9BC,EAAoBC,EAAM,MAAA,UAIXC,EAAiBC,kBAAA,CAC3C,OAAQ,QACR,MAAO,CACL,QAAS,CAAE,KAAM,QAAS,EAC1B,aAAc,CAAE,KAAM,QAAS,EAC/B,YAAa,CAAE,KAAM,QAAS,EAC9B,WAAY,CAAE,KAAM,QAAS,EAC7B,YAAa,CAAC,EACd,UAAW,CAAC,EACZ,UAAW,CAAE,KAAM,OAAQ,EAC3B,eAAgB,CAAC,EACjB,mBAAoB,CAAC,EACrB,EAAG,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EACpC,EAAG,CAAE,KAAM,CAAC,SAAU,OAAQ,KAAM,KAAK,CAAE,EAC3C,GAAI,CAAE,KAAM,QAAS,EACrB,MAAO,CAAE,KAAM,CAAC,SAAU,OAAQ,MAAO,IAAI,CAAE,EAC/C,OAAQ,CAAE,KAAM,CAAC,OAAQ,QAAQ,CAAE,EACnC,OAAQ,CAAE,KAAM,CAAC,OAAQ,QAAQ,CAAE,EACnC,6BAA8B,CAAE,KAAM,OAAQ,EAC9C,SAAU,CAAC,EACX,OAAQ,CAAC,EACT,WAAY,CAAC,EACb,KAAM,CAAC,CACT,EACA,MAAMC,EAAc,CAAE,OAAQC,GAAY,CAE5C,MAAMC,EAAQF,EAGRG,EAAWC,SAAOC,EAAAA,oBAAoB,EAKtCC,EAAOC,EAAS,SAAA,IAAMJ,EAAS,KAAK,OAASD,EAAM,IAAI,EAEvDM,EAASC,kBAAgBP,CAAK,EAG9BQ,EAAYC,EAAAA,MAGlBC,OAAAA,EAAAA,UAAU,IAAM,CACdC,EAAAA,SAAS,IAAM,OACbH,EAAU,MAAQ,IAAIb,EAAa,MAAAW,EAAO,KAAK,GACrCM,EAAAJ,EAAA,QAAA,MAAAI,EAAO,QAAQR,EAAK,OACrBH,EAAA,OAAOO,EAAU,KAAK,CAAA,CAChC,CAAA,CACF,EAEDK,EAAAA,YAAY,IAAM,QAChBD,EAAAJ,EAAU,QAAV,MAAAI,EAAiB,UACjBX,EAAS,QAAQ,CAAA,CAClB,EAEKa,EAAAA,MAAAR,EAAQ,CAACS,EAAMC,IAAS,OACvBC,EAAA,cAAcF,EAAMC,CAAI,IACjBJ,EAAAJ,EAAA,QAAA,MAAAI,EAAO,UAAUN,EAAO,MACpC,CACD,EAEDQ,EAAA,MAAMV,EAAM,IAAM,QACNQ,EAAAJ,EAAA,QAAA,MAAAI,EAAO,QAAQR,EAAK,MAAK,CACpC,EAEQL,EAAA,CACP,UAAAS,CAAA,CACD,EAEM,CAACU,EAAUC,KACRC,EAAW,UAAA,EAAGC,EAAAA,mBAAoB,MAAO5B,CAAU,EAE7D,CAEA,CAAC"}
1
+ {"version":3,"file":"index.cjs","sources":["../../../src/components/brush/index.vue"],"sourcesContent":["<script setup lang=\"ts\" generic=\"Datum\">\n// !!! This code was automatically generated. You should not change it !!!\nimport { Brush, BrushConfigInterface } from '@unovis/ts'\nimport { onMounted, onUnmounted, computed, ref, watch, nextTick, inject } from 'vue'\nimport { arePropsEqual, useForwardProps } from '../../utils/props'\nimport { componentAccessorKey } from '../../utils/context'\n\nconst accessor = inject(componentAccessorKey)\n\n// data and required props \ntype Props = BrushConfigInterface<Datum>\nconst props = defineProps<Props & { data?: Datum[] }>()\n\nconst data = computed(() => accessor.data.value ?? props.data)\n// config\nconst config = useForwardProps(props)\n\n// component declaration\nconst component = ref<Brush<Datum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Brush<Datum>(config.value)\n component.value?.setData(data.value)\n accessor.update(component.value)\n })\n})\n\nonUnmounted(() => {\n component.value?.destroy()\n accessor.destroy()\n})\n\nwatch(config, (curr, prev) => {\n if (!arePropsEqual(curr, prev)) {\n component.value?.setConfig(config.value)\n }\n})\n\nwatch(data, () => {\n component.value?.setData(data.value)\n})\n\ndefineExpose({\n component\n})\n</script>\n\n<script lang=\"ts\">\nexport const VisBrushSelectors = Brush.selectors\n</script>\n\n<template>\n <div data-vis-component />\n</template>\n\n\n"],"names":["VisBrushSelectors","Brush","accessor","inject","componentAccessorKey","props","__props","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","_a","onUnmounted","watch","curr","prev","arePropsEqual","__expose"],"mappings":"+PAkDaA,EAAoBC,EAAAA,MAAM,idA3CjC,MAAAC,EAAWC,SAAOC,sBAAoB,EAItCC,EAAQC,EAERC,EAAOC,EAAAA,SAAS,IAAMN,EAAS,KAAK,OAASG,EAAM,IAAI,EAEvDI,EAASC,kBAAgBL,CAAK,EAG9BM,EAAYC,EAAAA,IAAkB,EAGpCC,OAAAA,EAAAA,UAAU,IAAM,CACdC,EAAAA,SAAS,IAAM,OACbH,EAAU,MAAQ,IAAIV,QAAaQ,EAAO,KAAK,GACrCM,EAAAJ,EAAA,QAAA,MAAAI,EAAO,QAAQR,EAAK,OACrBL,EAAA,OAAOS,EAAU,KAAK,CAAA,CAChC,CAAA,CACF,EAEDK,EAAAA,YAAY,IAAM,QAChBD,EAAAJ,EAAU,QAAV,MAAAI,EAAiB,UACjBb,EAAS,QAAQ,CAAA,CAClB,EAEKe,EAAAA,MAAAR,EAAQ,CAACS,EAAMC,IAAS,OACvBC,EAAA,cAAcF,EAAMC,CAAI,IACjBJ,EAAAJ,EAAA,QAAA,MAAAI,EAAO,UAAUN,EAAO,MACpC,CACD,EAEDQ,EAAA,MAAMV,EAAM,IAAM,QACNQ,EAAAJ,EAAA,QAAA,MAAAI,EAAO,QAAQR,EAAK,MAAK,CACpC,EAEYc,EAAA,CACX,UAAAV,CAAA,CACD"}
@@ -56,7 +56,7 @@ declare const _default: <Datum>(__VLS_props: any, __VLS_ctx?: {
56
56
  selectionMinLength?: number;
57
57
  } & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps;
58
58
  expose(exposed: import("vue").ShallowUnwrapRef<{
59
- component: import("vue").Ref<Brush<Datum>>;
59
+ component: import("vue").Ref<Brush<Datum>, Brush<Datum>>;
60
60
  }>): void;
61
61
  attrs: any;
62
62
  slots: {};
@@ -1,8 +1,8 @@
1
- import { defineComponent as d, inject as m, computed as y, ref as v, onMounted as h, nextTick as F, onUnmounted as f, watch as s, openBlock as B, createElementBlock as x } from "vue";
1
+ import { defineComponent as d, inject as m, computed as v, ref as y, onMounted as h, nextTick as f, onUnmounted as B, watch as u, openBlock as F, createElementBlock as x } from "vue";
2
2
  import { Brush as i } from "@unovis/ts";
3
- import { useForwardProps as _, arePropsEqual as b } from "../../utils/props.js";
4
- import { componentAccessorKey as g } from "../../utils/context.js";
5
- const S = { "data-vis-component": "" }, C = i.selectors, D = /* @__PURE__ */ d({
3
+ import { useForwardProps as _, arePropsEqual as g } from "../../utils/props.js";
4
+ import { componentAccessorKey as b } from "../../utils/context.js";
5
+ const S = { "data-vis-component": "" }, D = i.selectors, E = /* @__PURE__ */ d({
6
6
  __name: "index",
7
7
  props: {
8
8
  onBrush: { type: Function },
@@ -14,10 +14,10 @@ const S = { "data-vis-component": "" }, C = i.selectors, D = /* @__PURE__ */ d({
14
14
  draggable: { type: Boolean },
15
15
  handlePosition: {},
16
16
  selectionMinLength: {},
17
- x: { type: [Function, Number, null] },
18
- y: { type: [Function, Number, null, Array] },
17
+ x: {},
18
+ y: {},
19
19
  id: { type: Function },
20
- color: { type: [Function, String, Array, null] },
20
+ color: {},
21
21
  xScale: { type: [Object, Function] },
22
22
  yScale: { type: [Object, Function] },
23
23
  excludeFromDomainCalculation: { type: Boolean },
@@ -27,28 +27,28 @@ const S = { "data-vis-component": "" }, C = i.selectors, D = /* @__PURE__ */ d({
27
27
  data: {}
28
28
  },
29
29
  setup(l, { expose: p }) {
30
- const c = l, o = m(g), n = y(() => o.data.value ?? c.data), a = _(c), t = v();
30
+ const o = m(b), c = l, n = v(() => o.data.value ?? c.data), a = _(c), t = y();
31
31
  return h(() => {
32
- F(() => {
32
+ f(() => {
33
33
  var e;
34
34
  t.value = new i(a.value), (e = t.value) == null || e.setData(n.value), o.update(t.value);
35
35
  });
36
- }), f(() => {
36
+ }), B(() => {
37
37
  var e;
38
38
  (e = t.value) == null || e.destroy(), o.destroy();
39
- }), s(a, (e, r) => {
40
- var u;
41
- b(e, r) || (u = t.value) == null || u.setConfig(a.value);
42
- }), s(n, () => {
39
+ }), u(a, (e, s) => {
40
+ var r;
41
+ g(e, s) || (r = t.value) == null || r.setConfig(a.value);
42
+ }), u(n, () => {
43
43
  var e;
44
44
  (e = t.value) == null || e.setData(n.value);
45
45
  }), p({
46
46
  component: t
47
- }), (e, r) => (B(), x("div", S));
47
+ }), (e, s) => (F(), x("div", S));
48
48
  }
49
49
  });
50
50
  export {
51
- C as VisBrushSelectors,
52
- D as default
51
+ D as VisBrushSelectors,
52
+ E as default
53
53
  };
54
54
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../../../src/components/brush/index.vue?vue&type=script&setup=true&lang.ts"],"sourcesContent":["import { defineComponent as _defineComponent } from 'vue'\nimport { openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nconst _hoisted_1 = { \"data-vis-component\": \"\" }\n\nimport { Brush, BrushConfigInterface } from '@unovis/ts'\nimport { onMounted, onUnmounted, computed, ref, watch, nextTick, inject } from 'vue'\nimport { arePropsEqual, useForwardProps } from '../../utils/props'\nimport { componentAccessorKey } from '../../utils/context'\n\n\nexport const VisBrushSelectors = Brush.selectors\n\ntype Props = BrushConfigInterface<Datum>\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n onBrush: { type: Function },\n onBrushStart: { type: Function },\n onBrushMove: { type: Function },\n onBrushEnd: { type: Function },\n handleWidth: {},\n selection: {},\n draggable: { type: Boolean },\n handlePosition: {},\n selectionMinLength: {},\n x: { type: [Function, Number, null] },\n y: { type: [Function, Number, null, Array] },\n id: { type: Function },\n color: { type: [Function, String, Array, null] },\n xScale: { type: [Object, Function] },\n yScale: { type: [Object, Function] },\n excludeFromDomainCalculation: { type: Boolean },\n duration: {},\n events: {},\n attributes: {},\n data: {}\n },\n setup(__props: any, { expose: __expose }) {\n\nconst props = __props;\n\n// !!! This code was automatically generated. You should not change it !!!\nconst accessor = inject(componentAccessorKey)\n\n// data and required props \n\n\nconst data = computed(() => accessor.data.value ?? props.data)\n// config\nconst config = useForwardProps(props)\n\n// component declaration\nconst component = ref<Brush<Datum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Brush<Datum>(config.value)\n component.value?.setData(data.value)\n accessor.update(component.value)\n })\n})\n\nonUnmounted(() => {\n component.value?.destroy()\n accessor.destroy()\n})\n\nwatch(config, (curr, prev) => {\n if (!arePropsEqual(curr, prev)) {\n component.value?.setConfig(config.value)\n }\n})\n\nwatch(data, () => {\n component.value?.setData(data.value)\n})\n\n__expose({\n component\n})\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", _hoisted_1))\n}\n}\n\n})"],"names":["_hoisted_1","VisBrushSelectors","Brush","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","componentAccessorKey","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","_a","onUnmounted","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":";;;;AAGA,MAAMA,IAAa,EAAE,sBAAsB,MAQ9BC,IAAoBC,EAAM,WAIXC,IAAiBC,gBAAAA,EAAA;AAAA,EAC3C,QAAQ;AAAA,EACR,OAAO;AAAA,IACL,SAAS,EAAE,MAAM,SAAS;AAAA,IAC1B,cAAc,EAAE,MAAM,SAAS;AAAA,IAC/B,aAAa,EAAE,MAAM,SAAS;AAAA,IAC9B,YAAY,EAAE,MAAM,SAAS;AAAA,IAC7B,aAAa,CAAC;AAAA,IACd,WAAW,CAAC;AAAA,IACZ,WAAW,EAAE,MAAM,QAAQ;AAAA,IAC3B,gBAAgB,CAAC;AAAA,IACjB,oBAAoB,CAAC;AAAA,IACrB,GAAG,EAAE,MAAM,CAAC,UAAU,QAAQ,IAAI,EAAE;AAAA,IACpC,GAAG,EAAE,MAAM,CAAC,UAAU,QAAQ,MAAM,KAAK,EAAE;AAAA,IAC3C,IAAI,EAAE,MAAM,SAAS;AAAA,IACrB,OAAO,EAAE,MAAM,CAAC,UAAU,QAAQ,OAAO,IAAI,EAAE;AAAA,IAC/C,QAAQ,EAAE,MAAM,CAAC,QAAQ,QAAQ,EAAE;AAAA,IACnC,QAAQ,EAAE,MAAM,CAAC,QAAQ,QAAQ,EAAE;AAAA,IACnC,8BAA8B,EAAE,MAAM,QAAQ;AAAA,IAC9C,UAAU,CAAC;AAAA,IACX,QAAQ,CAAC;AAAA,IACT,YAAY,CAAC;AAAA,IACb,MAAM,CAAC;AAAA,EACT;AAAA,EACA,MAAMC,GAAc,EAAE,QAAQC,KAAY;AAE5C,UAAMC,IAAQF,GAGRG,IAAWC,EAAOC,CAAoB,GAKtCC,IAAOC,EAAS,MAAMJ,EAAS,KAAK,SAASD,EAAM,IAAI,GAEvDM,IAASC,EAAgBP,CAAK,GAG9BQ,IAAYC;AAGlB,WAAAC,EAAU,MAAM;AACd,MAAAC,EAAS,MAAM;;AACb,QAAAH,EAAU,QAAQ,IAAIb,EAAaW,EAAO,KAAK,IACrCM,IAAAJ,EAAA,UAAA,QAAAI,EAAO,QAAQR,EAAK,QACrBH,EAAA,OAAOO,EAAU,KAAK;AAAA,MAAA,CAChC;AAAA,IAAA,CACF,GAEDK,EAAY,MAAM;;AAChB,OAAAD,IAAAJ,EAAU,UAAV,QAAAI,EAAiB,WACjBX,EAAS,QAAQ;AAAA,IAAA,CAClB,GAEKa,EAAAR,GAAQ,CAACS,GAAMC,MAAS;;AAC5B,MAAKC,EAAcF,GAAMC,CAAI,MACjBJ,IAAAJ,EAAA,UAAA,QAAAI,EAAO,UAAUN,EAAO;AAAA,IACpC,CACD,GAEDQ,EAAMV,GAAM,MAAM;;AACN,OAAAQ,IAAAJ,EAAA,UAAA,QAAAI,EAAO,QAAQR,EAAK;AAAA,IAAK,CACpC,GAEQL,EAAA;AAAA,MACP,WAAAS;AAAA,IAAA,CACD,GAEM,CAACU,GAAUC,OACRC,EAAW,GAAGC,EAAoB,OAAO5B,CAAU;AAAA,EAE7D;AAEA,CAAC;"}
1
+ {"version":3,"file":"index.js","sources":["../../../src/components/brush/index.vue"],"sourcesContent":["<script setup lang=\"ts\" generic=\"Datum\">\n// !!! This code was automatically generated. You should not change it !!!\nimport { Brush, BrushConfigInterface } from '@unovis/ts'\nimport { onMounted, onUnmounted, computed, ref, watch, nextTick, inject } from 'vue'\nimport { arePropsEqual, useForwardProps } from '../../utils/props'\nimport { componentAccessorKey } from '../../utils/context'\n\nconst accessor = inject(componentAccessorKey)\n\n// data and required props \ntype Props = BrushConfigInterface<Datum>\nconst props = defineProps<Props & { data?: Datum[] }>()\n\nconst data = computed(() => accessor.data.value ?? props.data)\n// config\nconst config = useForwardProps(props)\n\n// component declaration\nconst component = ref<Brush<Datum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Brush<Datum>(config.value)\n component.value?.setData(data.value)\n accessor.update(component.value)\n })\n})\n\nonUnmounted(() => {\n component.value?.destroy()\n accessor.destroy()\n})\n\nwatch(config, (curr, prev) => {\n if (!arePropsEqual(curr, prev)) {\n component.value?.setConfig(config.value)\n }\n})\n\nwatch(data, () => {\n component.value?.setData(data.value)\n})\n\ndefineExpose({\n component\n})\n</script>\n\n<script lang=\"ts\">\nexport const VisBrushSelectors = Brush.selectors\n</script>\n\n<template>\n <div data-vis-component />\n</template>\n\n\n"],"names":["VisBrushSelectors","Brush","accessor","inject","componentAccessorKey","props","__props","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","_a","onUnmounted","watch","curr","prev","arePropsEqual","__expose"],"mappings":";;;;wCAkDaA,IAAoBC,EAAM;;;;;;;;;;;;;;;;;;;;;;;;;AA3CjC,UAAAC,IAAWC,EAAOC,CAAoB,GAItCC,IAAQC,GAERC,IAAOC,EAAS,MAAMN,EAAS,KAAK,SAASG,EAAM,IAAI,GAEvDI,IAASC,EAAgBL,CAAK,GAG9BM,IAAYC,EAAkB;AAGpC,WAAAC,EAAU,MAAM;AACd,MAAAC,EAAS,MAAM;;AACb,QAAAH,EAAU,QAAQ,IAAIV,EAAaQ,EAAO,KAAK,IACrCM,IAAAJ,EAAA,UAAA,QAAAI,EAAO,QAAQR,EAAK,QACrBL,EAAA,OAAOS,EAAU,KAAK;AAAA,MAAA,CAChC;AAAA,IAAA,CACF,GAEDK,EAAY,MAAM;;AAChB,OAAAD,IAAAJ,EAAU,UAAV,QAAAI,EAAiB,WACjBb,EAAS,QAAQ;AAAA,IAAA,CAClB,GAEKe,EAAAR,GAAQ,CAACS,GAAMC,MAAS;;AAC5B,MAAKC,EAAcF,GAAMC,CAAI,MACjBJ,IAAAJ,EAAA,UAAA,QAAAI,EAAO,UAAUN,EAAO;AAAA,IACpC,CACD,GAEDQ,EAAMV,GAAM,MAAM;;AACN,OAAAQ,IAAAJ,EAAA,UAAA,QAAAI,EAAO,QAAQR,EAAK;AAAA,IAAK,CACpC,GAEYc,EAAA;AAAA,MACX,WAAAV;AAAA,IAAA,CACD;;;"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const n=require("vue"),c=require("@unovis/ts"),s=require("../../utils/props.cjs"),g=require("../../utils/context.cjs"),v={"data-vis-component":""},m=c.ChordDiagram.selectors,h=n.defineComponent({__name:"index",props:{angleRange:{},cornerRadius:{type:[Function,Number,null]},highlightedNodeId:{},highlightedLinkIds:{},linkColor:{type:[Function,String,Array,null]},linkValue:{type:[Function,Number,null]},nodeLevels:{},nodeWidth:{},nodeColor:{type:[Function,String,Array,null]},nodeLabel:{type:[Function,String,null]},nodeLabelColor:{type:[Function,String,null]},nodeLabelAlignment:{type:[Function,null]},padAngle:{},radiusScaleExponent:{},duration:{},events:{},attributes:{},data:{}},setup(d,{expose:p}){const l=d,o=n.inject(g.componentAccessorKey),a=n.computed(()=>o.data.value??l.data),r=s.useForwardProps(l),t=n.ref();return n.onMounted(()=>{n.nextTick(()=>{var e;t.value=new c.ChordDiagram(r.value),(e=t.value)==null||e.setData(a.value),o.update(t.value)})}),n.onUnmounted(()=>{var e;(e=t.value)==null||e.destroy(),o.destroy()}),n.watch(r,(e,u)=>{var i;s.arePropsEqual(e,u)||(i=t.value)==null||i.setConfig(r.value)}),n.watch(a,()=>{var e;(e=t.value)==null||e.setData(a.value)}),p({component:t}),(e,u)=>(n.openBlock(),n.createElementBlock("div",v))}});exports.VisChordDiagramSelectors=m;exports.default=h;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const o=require("vue"),i=require("@unovis/ts"),l=require("../../utils/props.cjs"),v=require("../../utils/context.cjs"),g={"data-vis-component":""},h=i.ChordDiagram.selectors,m=o.defineComponent({__name:"index",props:{angleRange:{},cornerRadius:{},highlightedNodeId:{},highlightedLinkIds:{},linkColor:{},linkValue:{},nodeLevels:{},nodeWidth:{},nodeColor:{},nodeLabel:{},nodeLabelColor:{},nodeLabelAlignment:{},padAngle:{},radiusScaleExponent:{},duration:{},events:{},attributes:{},data:{}},setup(u,{expose:p}){const a=o.inject(v.componentAccessorKey),s=u,n=o.computed(()=>a.data.value??s.data),r=l.useForwardProps(s),t=o.ref();return o.onMounted(()=>{o.nextTick(()=>{var e;t.value=new i.ChordDiagram(r.value),(e=t.value)==null||e.setData(n.value),a.update(t.value)})}),o.onUnmounted(()=>{var e;(e=t.value)==null||e.destroy(),a.destroy()}),o.watch(r,(e,c)=>{var d;l.arePropsEqual(e,c)||(d=t.value)==null||d.setConfig(r.value)}),o.watch(n,()=>{var e;(e=t.value)==null||e.setData(n.value)}),p({component:t}),(e,c)=>(o.openBlock(),o.createElementBlock("div",g))}});exports.VisChordDiagramSelectors=h;exports.default=m;
2
2
  //# sourceMappingURL=index.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs","sources":["../../../src/components/chord-diagram/index.vue?vue&type=script&setup=true&lang.ts"],"sourcesContent":["import { defineComponent as _defineComponent } from 'vue'\nimport { openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nconst _hoisted_1 = { \"data-vis-component\": \"\" }\n\nimport { ChordDiagram, ChordDiagramConfigInterface, ChordInputNode, ChordInputLink } from '@unovis/ts'\nimport { onMounted, onUnmounted, computed, ref, watch, nextTick, inject } from 'vue'\nimport { arePropsEqual, useForwardProps } from '../../utils/props'\nimport { componentAccessorKey } from '../../utils/context'\n\n\nexport const VisChordDiagramSelectors = ChordDiagram.selectors\n\ntype Props = ChordDiagramConfigInterface<N, L>\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n angleRange: {},\n cornerRadius: { type: [Function, Number, null] },\n highlightedNodeId: {},\n highlightedLinkIds: {},\n linkColor: { type: [Function, String, Array, null] },\n linkValue: { type: [Function, Number, null] },\n nodeLevels: {},\n nodeWidth: {},\n nodeColor: { type: [Function, String, Array, null] },\n nodeLabel: { type: [Function, String, null] },\n nodeLabelColor: { type: [Function, String, null] },\n nodeLabelAlignment: { type: [Function, null] },\n padAngle: {},\n radiusScaleExponent: {},\n duration: {},\n events: {},\n attributes: {},\n data: {}\n },\n setup(__props: any, { expose: __expose }) {\n\nconst props = __props;\n\n// !!! This code was automatically generated. You should not change it !!!\nconst accessor = inject(componentAccessorKey)\n\n// data and required props \n\n\nconst data = computed(() => accessor.data.value ?? props.data)\n// config\nconst config = useForwardProps(props)\n\n// component declaration\nconst component = ref<ChordDiagram<N, L>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new ChordDiagram<N, L>(config.value)\n component.value?.setData(data.value)\n accessor.update(component.value)\n })\n})\n\nonUnmounted(() => {\n component.value?.destroy()\n accessor.destroy()\n})\n\nwatch(config, (curr, prev) => {\n if (!arePropsEqual(curr, prev)) {\n component.value?.setConfig(config.value)\n }\n})\n\nwatch(data, () => {\n component.value?.setData(data.value)\n})\n\n__expose({\n component\n})\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", _hoisted_1))\n}\n}\n\n})"],"names":["_hoisted_1","VisChordDiagramSelectors","ChordDiagram","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","componentAccessorKey","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","_a","onUnmounted","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":"mOAGMA,EAAa,CAAE,qBAAsB,IAQ9BC,EAA2BC,EAAa,aAAA,UAIzBC,EAAiBC,kBAAA,CAC3C,OAAQ,QACR,MAAO,CACL,WAAY,CAAC,EACb,aAAc,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EAC/C,kBAAmB,CAAC,EACpB,mBAAoB,CAAC,EACrB,UAAW,CAAE,KAAM,CAAC,SAAU,OAAQ,MAAO,IAAI,CAAE,EACnD,UAAW,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EAC5C,WAAY,CAAC,EACb,UAAW,CAAC,EACZ,UAAW,CAAE,KAAM,CAAC,SAAU,OAAQ,MAAO,IAAI,CAAE,EACnD,UAAW,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EAC5C,eAAgB,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EACjD,mBAAoB,CAAE,KAAM,CAAC,SAAU,IAAI,CAAE,EAC7C,SAAU,CAAC,EACX,oBAAqB,CAAC,EACtB,SAAU,CAAC,EACX,OAAQ,CAAC,EACT,WAAY,CAAC,EACb,KAAM,CAAC,CACT,EACA,MAAMC,EAAc,CAAE,OAAQC,GAAY,CAE5C,MAAMC,EAAQF,EAGRG,EAAWC,SAAOC,EAAAA,oBAAoB,EAKtCC,EAAOC,EAAS,SAAA,IAAMJ,EAAS,KAAK,OAASD,EAAM,IAAI,EAEvDM,EAASC,kBAAgBP,CAAK,EAG9BQ,EAAYC,EAAAA,MAGlBC,OAAAA,EAAAA,UAAU,IAAM,CACdC,EAAAA,SAAS,IAAM,OACbH,EAAU,MAAQ,IAAIb,EAAmB,aAAAW,EAAO,KAAK,GAC3CM,EAAAJ,EAAA,QAAA,MAAAI,EAAO,QAAQR,EAAK,OACrBH,EAAA,OAAOO,EAAU,KAAK,CAAA,CAChC,CAAA,CACF,EAEDK,EAAAA,YAAY,IAAM,QAChBD,EAAAJ,EAAU,QAAV,MAAAI,EAAiB,UACjBX,EAAS,QAAQ,CAAA,CAClB,EAEKa,EAAAA,MAAAR,EAAQ,CAACS,EAAMC,IAAS,OACvBC,EAAA,cAAcF,EAAMC,CAAI,IACjBJ,EAAAJ,EAAA,QAAA,MAAAI,EAAO,UAAUN,EAAO,MACpC,CACD,EAEDQ,EAAA,MAAMV,EAAM,IAAM,QACNQ,EAAAJ,EAAA,QAAA,MAAAI,EAAO,QAAQR,EAAK,MAAK,CACpC,EAEQL,EAAA,CACP,UAAAS,CAAA,CACD,EAEM,CAACU,EAAUC,KACRC,EAAW,UAAA,EAAGC,EAAAA,mBAAoB,MAAO5B,CAAU,EAE7D,CAEA,CAAC"}
1
+ {"version":3,"file":"index.cjs","sources":["../../../src/components/chord-diagram/index.vue"],"sourcesContent":["<script setup lang=\"ts\" generic=\"N extends ChordInputNode,L extends ChordInputLink\">\n// !!! This code was automatically generated. You should not change it !!!\nimport { ChordDiagram, ChordDiagramConfigInterface, ChordInputNode, ChordInputLink } from '@unovis/ts'\nimport { onMounted, onUnmounted, computed, ref, watch, nextTick, inject } from 'vue'\nimport { arePropsEqual, useForwardProps } from '../../utils/props'\nimport { componentAccessorKey } from '../../utils/context'\n\nconst accessor = inject(componentAccessorKey)\n\n// data and required props \ntype Props = ChordDiagramConfigInterface<N, L>\nconst props = defineProps<Props & { data?: { nodes: N[]; links?: L[] } }>()\n\nconst data = computed(() => accessor.data.value ?? props.data)\n// config\nconst config = useForwardProps(props)\n\n// component declaration\nconst component = ref<ChordDiagram<N, L>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new ChordDiagram<N, L>(config.value)\n component.value?.setData(data.value)\n accessor.update(component.value)\n })\n})\n\nonUnmounted(() => {\n component.value?.destroy()\n accessor.destroy()\n})\n\nwatch(config, (curr, prev) => {\n if (!arePropsEqual(curr, prev)) {\n component.value?.setConfig(config.value)\n }\n})\n\nwatch(data, () => {\n component.value?.setData(data.value)\n})\n\ndefineExpose({\n component\n})\n</script>\n\n<script lang=\"ts\">\nexport const VisChordDiagramSelectors = ChordDiagram.selectors\n</script>\n\n<template>\n <div data-vis-component />\n</template>\n\n\n"],"names":["VisChordDiagramSelectors","ChordDiagram","accessor","inject","componentAccessorKey","props","__props","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","_a","onUnmounted","watch","curr","prev","arePropsEqual","__expose"],"mappings":"+PAkDaA,EAA2BC,EAAAA,aAAa,yVA3C/C,MAAAC,EAAWC,SAAOC,sBAAoB,EAItCC,EAAQC,EAERC,EAAOC,EAAAA,SAAS,IAAMN,EAAS,KAAK,OAASG,EAAM,IAAI,EAEvDI,EAASC,kBAAgBL,CAAK,EAG9BM,EAAYC,EAAAA,IAAwB,EAG1CC,OAAAA,EAAAA,UAAU,IAAM,CACdC,EAAAA,SAAS,IAAM,OACbH,EAAU,MAAQ,IAAIV,eAAmBQ,EAAO,KAAK,GAC3CM,EAAAJ,EAAA,QAAA,MAAAI,EAAO,QAAQR,EAAK,OACrBL,EAAA,OAAOS,EAAU,KAAK,CAAA,CAChC,CAAA,CACF,EAEDK,EAAAA,YAAY,IAAM,QAChBD,EAAAJ,EAAU,QAAV,MAAAI,EAAiB,UACjBb,EAAS,QAAQ,CAAA,CAClB,EAEKe,EAAAA,MAAAR,EAAQ,CAACS,EAAMC,IAAS,OACvBC,EAAA,cAAcF,EAAMC,CAAI,IACjBJ,EAAAJ,EAAA,QAAA,MAAAI,EAAO,UAAUN,EAAO,MACpC,CACD,EAEDQ,EAAA,MAAMV,EAAM,IAAM,QACNQ,EAAAJ,EAAA,QAAA,MAAAI,EAAO,QAAQR,EAAK,MAAK,CACpC,EAEYc,EAAA,CACX,UAAAV,CAAA,CACD"}
@@ -57,7 +57,7 @@ declare const _default: <N extends ChordInputNode, L extends ChordInputLink>(__V
57
57
  radiusScaleExponent?: number;
58
58
  } & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps;
59
59
  expose(exposed: import("vue").ShallowUnwrapRef<{
60
- component: import("vue").Ref<ChordDiagram<N, L>>;
60
+ component: import("vue").Ref<ChordDiagram<N, L>, ChordDiagram<N, L>>;
61
61
  }>): void;
62
62
  attrs: any;
63
63
  slots: {};