@unovis/vue 1.3.0-beta.2 → 1.3.0-beta.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/area/index.cjs +1 -1
- package/components/area/index.cjs.map +1 -1
- package/components/area/index.d.ts +2 -2
- package/components/area/index.js +6 -6
- package/components/area/index.js.map +1 -1
- package/components/axis/index.cjs +1 -1
- package/components/axis/index.cjs.map +1 -1
- package/components/axis/index.d.ts +2 -2
- package/components/axis/index.js +3 -3
- package/components/axis/index.js.map +1 -1
- package/components/brush/index.cjs +1 -1
- package/components/brush/index.cjs.map +1 -1
- package/components/brush/index.d.ts +1 -1
- package/components/brush/index.js +3 -3
- package/components/brush/index.js.map +1 -1
- package/components/chord-diagram/index.cjs +1 -1
- package/components/chord-diagram/index.cjs.map +1 -1
- package/components/chord-diagram/index.d.ts +4 -4
- package/components/chord-diagram/index.js +11 -11
- package/components/chord-diagram/index.js.map +1 -1
- package/components/crosshair/index.d.ts +2 -2
- package/components/donut/index.cjs +1 -1
- package/components/donut/index.cjs.map +1 -1
- package/components/donut/index.d.ts +1 -1
- package/components/donut/index.js +1 -1
- package/components/donut/index.js.map +1 -1
- package/components/free-brush/index.cjs +1 -1
- package/components/free-brush/index.cjs.map +1 -1
- package/components/free-brush/index.d.ts +1 -1
- package/components/free-brush/index.js +3 -3
- package/components/free-brush/index.js.map +1 -1
- package/components/graph/index.cjs +1 -1
- package/components/graph/index.cjs.map +1 -1
- package/components/graph/index.d.ts +1 -1
- package/components/graph/index.js +6 -6
- package/components/graph/index.js.map +1 -1
- package/components/grouped-bar/index.cjs +1 -1
- package/components/grouped-bar/index.cjs.map +1 -1
- package/components/grouped-bar/index.d.ts +1 -1
- package/components/grouped-bar/index.js +1 -1
- package/components/grouped-bar/index.js.map +1 -1
- package/components/line/index.cjs +1 -1
- package/components/line/index.cjs.map +1 -1
- package/components/line/index.d.ts +2 -2
- package/components/line/index.js +7 -7
- package/components/line/index.js.map +1 -1
- package/components/nested-donut/index.cjs +1 -1
- package/components/nested-donut/index.cjs.map +1 -1
- package/components/nested-donut/index.js +10 -10
- package/components/nested-donut/index.js.map +1 -1
- package/components/sankey/index.cjs +1 -1
- package/components/sankey/index.cjs.map +1 -1
- package/components/sankey/index.js +6 -6
- package/components/sankey/index.js.map +1 -1
- package/components/scatter/index.cjs +1 -1
- package/components/scatter/index.cjs.map +1 -1
- package/components/scatter/index.d.ts +1 -1
- package/components/scatter/index.js +13 -13
- package/components/scatter/index.js.map +1 -1
- package/components/stacked-bar/index.cjs +1 -1
- package/components/stacked-bar/index.cjs.map +1 -1
- package/components/stacked-bar/index.d.ts +1 -1
- package/components/stacked-bar/index.js +1 -1
- package/components/stacked-bar/index.js.map +1 -1
- package/components/timeline/index.d.ts +1 -1
- package/components/tooltip/index.d.ts +2 -2
- package/components/topojson-map/index.cjs +1 -1
- package/components/topojson-map/index.cjs.map +1 -1
- package/components/topojson-map/index.d.ts +2 -2
- package/components/topojson-map/index.js +9 -9
- package/components/topojson-map/index.js.map +1 -1
- package/components/xy-labels/index.cjs +1 -1
- package/components/xy-labels/index.cjs.map +1 -1
- package/components/xy-labels/index.d.ts +1 -1
- package/components/xy-labels/index.js +14 -14
- package/components/xy-labels/index.js.map +1 -1
- package/containers/single-container/index.d.ts +1 -1
- package/containers/xy-container/index.d.ts +1 -1
- package/html-components/leaflet-flow-map/index.cjs +1 -1
- package/html-components/leaflet-flow-map/index.cjs.map +1 -1
- package/html-components/leaflet-flow-map/index.d.ts +2 -2
- package/html-components/leaflet-flow-map/index.js +7 -7
- package/html-components/leaflet-flow-map/index.js.map +1 -1
- package/html-components/leaflet-map/index.cjs +1 -1
- package/html-components/leaflet-map/index.cjs.map +1 -1
- package/html-components/leaflet-map/index.d.ts +2 -2
- package/html-components/leaflet-map/index.js +5 -5
- package/html-components/leaflet-map/index.js.map +1 -1
- package/index.cjs +1 -1
- package/index.js +1 -1
- package/package.json +1 -1
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";const n=require("vue"),d=require("@unovis/ts"),c=require("../../utils/props.cjs"),y=require("../../utils/context.cjs"),b={"data-vis-component":""},g=n.defineComponent({__name:"index",props:{id:{type:Function},heightNormalizationCoeff:{},exitTransitionType:{},enterTransitionType:{},highlightSubtreeOnHover:{type:Boolean},highlightDuration:{},highlightDelay:{},iterations:{},nodeSort:{type:[Function,null]},linkSort:{type:[Function,null]},nodeWidth:{},nodeAlign:{},nodeHorizontalSpacing:{},nodeMinHeight:{},nodeMaxHeight:{},nodePadding:{},showSingleNode:{type:Boolean},nodeCursor:{type:[Function,String,null]},nodeIcon:{type:[Function,String,null]},nodeColor:{type:[Function,String,null]},nodeFixedValue:{type:[Function,Number,null]},nodeIconColor:{type:[Function,String,null]},linkColor:{type:[Function,String,null]},linkValue:{type:[Function,Number,null]},linkCursor:{type:[Function,String,null]},label:{type:[Function,String,null]},subLabel:{type:[Function,String,null]},labelPosition:{type:[Function,null]},labelVerticalAlign:{},labelBackground:{type:Boolean},labelFit:{},labelMaxWidth:{},labelExpandTrimmedOnHover:{type:Boolean},labelTrimMode:{},labelFontSize:{},labelTextSeparator:{},labelForceWordBreak:{type:Boolean},labelColor:{type:[Function,String,null]},labelCursor:{type:[Function,String,null]},labelVisibility:{type:Function},subLabelFontSize:{},subLabelColor:{type:[Function,String,null]},subLabelPlacement:{},subLabelToLabelInlineWidthRatio:{},duration:{},events:{},attributes:{},data:{}},setup(s,{expose:p}){const a=s,o=n.inject(y.componentAccessorKey),l=n.computed(()=>o.data.value??a.data),i=c.useForwardProps(a),t=n.ref();return n.onMounted(()=>{n.nextTick(()=>{var e;t.value=new d.Sankey(i.value),(e=t.value)==null||e.setData(l.value),o.update(t.value)})}),n.onUnmounted(()=>{var e;(e=t.value)==null||e.destroy(),o.destroy()}),n.watch(i,(e,
|
|
1
|
+
"use strict";const n=require("vue"),d=require("@unovis/ts"),c=require("../../utils/props.cjs"),y=require("../../utils/context.cjs"),b={"data-vis-component":""},g=n.defineComponent({__name:"index",props:{id:{type:Function},heightNormalizationCoeff:{},exitTransitionType:{},enterTransitionType:{},highlightSubtreeOnHover:{type:Boolean},highlightDuration:{},highlightDelay:{},iterations:{},nodeSort:{type:[Function,null]},linkSort:{type:[Function,null]},nodeWidth:{},nodeAlign:{},nodeHorizontalSpacing:{},nodeMinHeight:{},nodeMaxHeight:{},nodePadding:{},showSingleNode:{type:Boolean},nodeCursor:{type:[Function,String,null]},nodeIcon:{type:[Function,String,null]},nodeColor:{type:[Function,String,Array,null]},nodeFixedValue:{type:[Function,Number,null]},nodeIconColor:{type:[Function,String,Array,null]},linkColor:{type:[Function,String,null]},linkValue:{type:[Function,Number,null]},linkCursor:{type:[Function,String,null]},label:{type:[Function,String,null]},subLabel:{type:[Function,String,null]},labelPosition:{type:[Function,null]},labelVerticalAlign:{},labelBackground:{type:Boolean},labelFit:{},labelMaxWidth:{},labelExpandTrimmedOnHover:{type:Boolean},labelTrimMode:{},labelFontSize:{},labelTextSeparator:{},labelForceWordBreak:{type:Boolean},labelColor:{type:[Function,String,Array,null]},labelCursor:{type:[Function,String,null]},labelVisibility:{type:Function},subLabelFontSize:{},subLabelColor:{type:[Function,String,Array,null]},subLabelPlacement:{},subLabelToLabelInlineWidthRatio:{},duration:{},events:{},attributes:{},data:{}},setup(s,{expose:p}){const a=s,o=n.inject(y.componentAccessorKey),l=n.computed(()=>o.data.value??a.data),i=c.useForwardProps(a),t=n.ref();return n.onMounted(()=>{n.nextTick(()=>{var e;t.value=new d.Sankey(i.value),(e=t.value)==null||e.setData(l.value),o.update(t.value)})}),n.onUnmounted(()=>{var e;(e=t.value)==null||e.destroy(),o.destroy()}),n.watch(i,(e,r)=>{var u;c.arePropsEqual(e,r)||(u=t.value)==null||u.setConfig(i.value)}),n.watch(l,()=>{var e;(e=t.value)==null||e.setData(l.value)}),p({component:t}),(e,r)=>(n.openBlock(),n.createElementBlock("div",b))}});module.exports=g;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","sources":["../../../src/components/sankey/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 { Sankey, SankeyConfigInterface, SankeyInputNode, SankeyInputLink } 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\ninterface Props extends SankeyConfigInterface<N, L> { }\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n id: { type: Function },\n heightNormalizationCoeff: {},\n exitTransitionType: {},\n enterTransitionType: {},\n highlightSubtreeOnHover: { type: Boolean },\n highlightDuration: {},\n highlightDelay: {},\n iterations: {},\n nodeSort: { type: [Function, null] },\n linkSort: { type: [Function, null] },\n nodeWidth: {},\n nodeAlign: {},\n nodeHorizontalSpacing: {},\n nodeMinHeight: {},\n nodeMaxHeight: {},\n nodePadding: {},\n showSingleNode: { type: Boolean },\n nodeCursor: { type: [Function, String, null] },\n nodeIcon: { type: [Function, String, null] },\n nodeColor: { type: [Function, String, null] },\n nodeFixedValue: { type: [Function, Number, null] },\n nodeIconColor: { type: [Function, String, null] },\n linkColor: { type: [Function, String, null] },\n linkValue: { type: [Function, Number, null] },\n linkCursor: { type: [Function, String, null] },\n label: { type: [Function, String, null] },\n subLabel: { type: [Function, String, null] },\n labelPosition: { type: [Function, null] },\n labelVerticalAlign: {},\n labelBackground: { type: Boolean },\n labelFit: {},\n labelMaxWidth: {},\n labelExpandTrimmedOnHover: { type: Boolean },\n labelTrimMode: {},\n labelFontSize: {},\n labelTextSeparator: {},\n labelForceWordBreak: { type: Boolean },\n labelColor: { type: [Function, String, null] },\n labelCursor: { type: [Function, String, null] },\n labelVisibility: { type: Function },\n subLabelFontSize: {},\n subLabelColor: { type: [Function, String, null] },\n subLabelPlacement: {},\n subLabelToLabelInlineWidthRatio: {},\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<Sankey<N, L>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Sankey<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","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","componentAccessorKey","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","Sankey","_a","onUnmounted","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":"oIAGMA,EAAa,CAAE,qBAAsB,IASfC,EAAiBC,kBAAA,CAC3C,OAAQ,QACR,MAAO,CACL,GAAI,CAAE,KAAM,QAAS,EACrB,yBAA0B,CAAC,EAC3B,mBAAoB,CAAC,EACrB,oBAAqB,CAAC,EACtB,wBAAyB,CAAE,KAAM,OAAQ,EACzC,kBAAmB,CAAC,EACpB,eAAgB,CAAC,EACjB,WAAY,CAAC,EACb,SAAU,CAAE,KAAM,CAAC,SAAU,IAAI,CAAE,EACnC,SAAU,CAAE,KAAM,CAAC,SAAU,IAAI,CAAE,EACnC,UAAW,CAAC,EACZ,UAAW,CAAC,EACZ,sBAAuB,CAAC,EACxB,cAAe,CAAC,EAChB,cAAe,CAAC,EAChB,YAAa,CAAC,EACd,eAAgB,CAAE,KAAM,OAAQ,EAChC,WAAY,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EAC7C,SAAU,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EAC3C,UAAW,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,
|
|
1
|
+
{"version":3,"file":"index.cjs","sources":["../../../src/components/sankey/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 { Sankey, SankeyConfigInterface, SankeyInputNode, SankeyInputLink } 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\ninterface Props extends SankeyConfigInterface<N, L> { }\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n id: { type: Function },\n heightNormalizationCoeff: {},\n exitTransitionType: {},\n enterTransitionType: {},\n highlightSubtreeOnHover: { type: Boolean },\n highlightDuration: {},\n highlightDelay: {},\n iterations: {},\n nodeSort: { type: [Function, null] },\n linkSort: { type: [Function, null] },\n nodeWidth: {},\n nodeAlign: {},\n nodeHorizontalSpacing: {},\n nodeMinHeight: {},\n nodeMaxHeight: {},\n nodePadding: {},\n showSingleNode: { type: Boolean },\n nodeCursor: { type: [Function, String, null] },\n nodeIcon: { type: [Function, String, null] },\n nodeColor: { type: [Function, String, Array, null] },\n nodeFixedValue: { type: [Function, Number, null] },\n nodeIconColor: { type: [Function, String, Array, null] },\n linkColor: { type: [Function, String, null] },\n linkValue: { type: [Function, Number, null] },\n linkCursor: { type: [Function, String, null] },\n label: { type: [Function, String, null] },\n subLabel: { type: [Function, String, null] },\n labelPosition: { type: [Function, null] },\n labelVerticalAlign: {},\n labelBackground: { type: Boolean },\n labelFit: {},\n labelMaxWidth: {},\n labelExpandTrimmedOnHover: { type: Boolean },\n labelTrimMode: {},\n labelFontSize: {},\n labelTextSeparator: {},\n labelForceWordBreak: { type: Boolean },\n labelColor: { type: [Function, String, Array, null] },\n labelCursor: { type: [Function, String, null] },\n labelVisibility: { type: Function },\n subLabelFontSize: {},\n subLabelColor: { type: [Function, String, Array, null] },\n subLabelPlacement: {},\n subLabelToLabelInlineWidthRatio: {},\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<Sankey<N, L>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Sankey<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","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","componentAccessorKey","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","Sankey","_a","onUnmounted","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":"oIAGMA,EAAa,CAAE,qBAAsB,IASfC,EAAiBC,kBAAA,CAC3C,OAAQ,QACR,MAAO,CACL,GAAI,CAAE,KAAM,QAAS,EACrB,yBAA0B,CAAC,EAC3B,mBA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-2,7 +2,7 @@ import { defineComponent as d, inject as s, computed as y, ref as b, onMounted a
|
|
|
2
2
|
import { Sankey as v } from "@unovis/ts";
|
|
3
3
|
import { useForwardProps as f, arePropsEqual as x } from "../../utils/props.js";
|
|
4
4
|
import { componentAccessorKey as C } from "../../utils/context.js";
|
|
5
|
-
const k = { "data-vis-component": "" },
|
|
5
|
+
const k = { "data-vis-component": "" }, L = /* @__PURE__ */ d({
|
|
6
6
|
__name: "index",
|
|
7
7
|
props: {
|
|
8
8
|
id: { type: Function },
|
|
@@ -24,9 +24,9 @@ const k = { "data-vis-component": "" }, H = /* @__PURE__ */ d({
|
|
|
24
24
|
showSingleNode: { type: Boolean },
|
|
25
25
|
nodeCursor: { type: [Function, String, null] },
|
|
26
26
|
nodeIcon: { type: [Function, String, null] },
|
|
27
|
-
nodeColor: { type: [Function, String, null] },
|
|
27
|
+
nodeColor: { type: [Function, String, Array, null] },
|
|
28
28
|
nodeFixedValue: { type: [Function, Number, null] },
|
|
29
|
-
nodeIconColor: { type: [Function, String, null] },
|
|
29
|
+
nodeIconColor: { type: [Function, String, Array, null] },
|
|
30
30
|
linkColor: { type: [Function, String, null] },
|
|
31
31
|
linkValue: { type: [Function, Number, null] },
|
|
32
32
|
linkCursor: { type: [Function, String, null] },
|
|
@@ -42,11 +42,11 @@ const k = { "data-vis-component": "" }, H = /* @__PURE__ */ d({
|
|
|
42
42
|
labelFontSize: {},
|
|
43
43
|
labelTextSeparator: {},
|
|
44
44
|
labelForceWordBreak: { type: Boolean },
|
|
45
|
-
labelColor: { type: [Function, String, null] },
|
|
45
|
+
labelColor: { type: [Function, String, Array, null] },
|
|
46
46
|
labelCursor: { type: [Function, String, null] },
|
|
47
47
|
labelVisibility: { type: Function },
|
|
48
48
|
subLabelFontSize: {},
|
|
49
|
-
subLabelColor: { type: [Function, String, null] },
|
|
49
|
+
subLabelColor: { type: [Function, String, Array, null] },
|
|
50
50
|
subLabelPlacement: {},
|
|
51
51
|
subLabelToLabelInlineWidthRatio: {},
|
|
52
52
|
duration: {},
|
|
@@ -76,6 +76,6 @@ const k = { "data-vis-component": "" }, H = /* @__PURE__ */ d({
|
|
|
76
76
|
}
|
|
77
77
|
});
|
|
78
78
|
export {
|
|
79
|
-
|
|
79
|
+
L as default
|
|
80
80
|
};
|
|
81
81
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../src/components/sankey/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 { Sankey, SankeyConfigInterface, SankeyInputNode, SankeyInputLink } 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\ninterface Props extends SankeyConfigInterface<N, L> { }\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n id: { type: Function },\n heightNormalizationCoeff: {},\n exitTransitionType: {},\n enterTransitionType: {},\n highlightSubtreeOnHover: { type: Boolean },\n highlightDuration: {},\n highlightDelay: {},\n iterations: {},\n nodeSort: { type: [Function, null] },\n linkSort: { type: [Function, null] },\n nodeWidth: {},\n nodeAlign: {},\n nodeHorizontalSpacing: {},\n nodeMinHeight: {},\n nodeMaxHeight: {},\n nodePadding: {},\n showSingleNode: { type: Boolean },\n nodeCursor: { type: [Function, String, null] },\n nodeIcon: { type: [Function, String, null] },\n nodeColor: { type: [Function, String, null] },\n nodeFixedValue: { type: [Function, Number, null] },\n nodeIconColor: { type: [Function, String, null] },\n linkColor: { type: [Function, String, null] },\n linkValue: { type: [Function, Number, null] },\n linkCursor: { type: [Function, String, null] },\n label: { type: [Function, String, null] },\n subLabel: { type: [Function, String, null] },\n labelPosition: { type: [Function, null] },\n labelVerticalAlign: {},\n labelBackground: { type: Boolean },\n labelFit: {},\n labelMaxWidth: {},\n labelExpandTrimmedOnHover: { type: Boolean },\n labelTrimMode: {},\n labelFontSize: {},\n labelTextSeparator: {},\n labelForceWordBreak: { type: Boolean },\n labelColor: { type: [Function, String, null] },\n labelCursor: { type: [Function, String, null] },\n labelVisibility: { type: Function },\n subLabelFontSize: {},\n subLabelColor: { type: [Function, String, null] },\n subLabelPlacement: {},\n subLabelToLabelInlineWidthRatio: {},\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<Sankey<N, L>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Sankey<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","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","componentAccessorKey","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","Sankey","_a","onUnmounted","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":";;;;AAGA,MAAMA,IAAa,EAAE,sBAAsB,MASfC,IAAiBC,gBAAAA,EAAA;AAAA,EAC3C,QAAQ;AAAA,EACR,OAAO;AAAA,IACL,IAAI,EAAE,MAAM,SAAS;AAAA,IACrB,0BAA0B,CAAC;AAAA,IAC3B,oBAAoB,CAAC;AAAA,IACrB,qBAAqB,CAAC;AAAA,IACtB,yBAAyB,EAAE,MAAM,QAAQ;AAAA,IACzC,mBAAmB,CAAC;AAAA,IACpB,gBAAgB,CAAC;AAAA,IACjB,YAAY,CAAC;AAAA,IACb,UAAU,EAAE,MAAM,CAAC,UAAU,IAAI,EAAE;AAAA,IACnC,UAAU,EAAE,MAAM,CAAC,UAAU,IAAI,EAAE;AAAA,IACnC,WAAW,CAAC;AAAA,IACZ,WAAW,CAAC;AAAA,IACZ,uBAAuB,CAAC;AAAA,IACxB,eAAe,CAAC;AAAA,IAChB,eAAe,CAAC;AAAA,IAChB,aAAa,CAAC;AAAA,IACd,gBAAgB,EAAE,MAAM,QAAQ;AAAA,IAChC,YAAY,EAAE,MAAM,CAAC,UAAU,QAAQ,IAAI,EAAE;AAAA,IAC7C,UAAU,EAAE,MAAM,CAAC,UAAU,QAAQ,IAAI,EAAE;AAAA,IAC3C,WAAW,EAAE,MAAM,CAAC,UAAU,QAAQ,IAAI,EAAE;AAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../src/components/sankey/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 { Sankey, SankeyConfigInterface, SankeyInputNode, SankeyInputLink } 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\ninterface Props extends SankeyConfigInterface<N, L> { }\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n id: { type: Function },\n heightNormalizationCoeff: {},\n exitTransitionType: {},\n enterTransitionType: {},\n highlightSubtreeOnHover: { type: Boolean },\n highlightDuration: {},\n highlightDelay: {},\n iterations: {},\n nodeSort: { type: [Function, null] },\n linkSort: { type: [Function, null] },\n nodeWidth: {},\n nodeAlign: {},\n nodeHorizontalSpacing: {},\n nodeMinHeight: {},\n nodeMaxHeight: {},\n nodePadding: {},\n showSingleNode: { type: Boolean },\n nodeCursor: { type: [Function, String, null] },\n nodeIcon: { type: [Function, String, null] },\n nodeColor: { type: [Function, String, Array, null] },\n nodeFixedValue: { type: [Function, Number, null] },\n nodeIconColor: { type: [Function, String, Array, null] },\n linkColor: { type: [Function, String, null] },\n linkValue: { type: [Function, Number, null] },\n linkCursor: { type: [Function, String, null] },\n label: { type: [Function, String, null] },\n subLabel: { type: [Function, String, null] },\n labelPosition: { type: [Function, null] },\n labelVerticalAlign: {},\n labelBackground: { type: Boolean },\n labelFit: {},\n labelMaxWidth: {},\n labelExpandTrimmedOnHover: { type: Boolean },\n labelTrimMode: {},\n labelFontSize: {},\n labelTextSeparator: {},\n labelForceWordBreak: { type: Boolean },\n labelColor: { type: [Function, String, Array, null] },\n labelCursor: { type: [Function, String, null] },\n labelVisibility: { type: Function },\n subLabelFontSize: {},\n subLabelColor: { type: [Function, String, Array, null] },\n subLabelPlacement: {},\n subLabelToLabelInlineWidthRatio: {},\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<Sankey<N, L>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Sankey<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","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","componentAccessorKey","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","Sankey","_a","onUnmounted","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":";;;;AAGA,MAAMA,IAAa,EAAE,sBAAsB,MASfC,IAAiBC,gBAAAA,EAAA;AAAA,EAC3C,QAAQ;AAAA,EACR,OAAO;AAAA,IACL,IAAI,EAAE,MAAM,SAAS;AAAA,IACrB,0BAA0B,CAAC;AAAA,IAC3B,oBAAoB,CAAC;AAAA,IACrB,qBAAqB,CAAC;AAAA,IACtB,yBAAyB,EAAE,MAAM,QAAQ;AAAA,IACzC,mBAAmB,CAAC;AAAA,IACpB,gBAAgB,CAAC;AAAA,IACjB,YAAY,CAAC;AAAA,IACb,UAAU,EAAE,MAAM,CAAC,UAAU,IAAI,EAAE;AAAA,IACnC,UAAU,EAAE,MAAM,CAAC,UAAU,IAAI,EAAE;AAAA,IACnC,WAAW,CAAC;AAAA,IACZ,WAAW,CAAC;AAAA,IACZ,uBAAuB,CAAC;AAAA,IACxB,eAAe,CAAC;AAAA,IAChB,eAAe,CAAC;AAAA,IAChB,aAAa,CAAC;AAAA,IACd,gBAAgB,EAAE,MAAM,QAAQ;AAAA,IAChC,YAAY,EAAE,MAAM,CAAC,UAAU,QAAQ,IAAI,EAAE;AAAA,IAC7C,UAAU,EAAE,MAAM,CAAC,UAAU,QAAQ,IAAI,EAAE;AAAA,IAC3C,WAAW,EAAE,MAAM,CAAC,UAAU,QAAQ,OAAO,IAAI,EAAE;AAAA,IACnD,gBAAgB,EAAE,MAAM,CAAC,UAAU,QAAQ,IAAI,EAAE;AAAA,IACjD,eAAe,EAAE,MAAM,CAAC,UAAU,QAAQ,OAAO,IAAI,EAAE;AAAA,IACvD,WAAW,EAAE,MAAM,CAAC,UAAU,Q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AAM;AACd,MAAAC,EAAS,MAAM;;AACb,QAAAH,EAAU,QAAQ,IAAII,EAAaN,EAAO,KAAK,IACrCO,IAAAL,EAAA,UAAA,QAAAK,EAAO,QAAQT,EAAK,QACrBH,EAAA,OAAOO,EAAU,KAAK;AAAA,MAAA,CAChC;AAAA,IAAA,CACF,GAEDM,EAAY,MAAM;;AAChB,OAAAD,IAAAL,EAAU,UAAV,QAAAK,EAAiB,WACjBZ,EAAS,QAAQ;AAAA,IAAA,CAClB,GAEKc,EAAAT,GAAQ,CAACU,GAAMC,MAAS;;AAC5B,MAAKC,EAAcF,GAAMC,CAAI,MACjBJ,IAAAL,EAAA,UAAA,QAAAK,EAAO,UAAUP,EAAO;AAAA,IACpC,CACD,GAEDS,EAAMX,GAAM,MAAM;;AACN,OAAAS,IAAAL,EAAA,UAAA,QAAAK,EAAO,QAAQT,EAAK;AAAA,IAAK,CACpC,GAEQL,EAAA;AAAA,MACP,WAAAS;AAAA,IAAA,CACD,GAEM,CAACW,GAAUC,OACRC,EAAW,GAAGC,EAAoB,OAAO3B,CAAU;AAAA,EAE7D;AAEA,CAAC;"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";const t=require("vue"),y=require("@unovis/ts"),i=require("../../utils/props.cjs"),d=require("../../utils/context.cjs"),F={"data-vis-component":""},v=t.defineComponent({__name:"index",props:{
|
|
1
|
+
"use strict";const t=require("vue"),y=require("@unovis/ts"),i=require("../../utils/props.cjs"),d=require("../../utils/context.cjs"),F={"data-vis-component":""},v=t.defineComponent({__name:"index",props:{size:{type:[Function,Number,null]},sizeScale:{type:[Object,Function]},sizeRange:{},shape:{type:[Function,String]},label:{type:[Function,String,null]},labelColor:{type:[Function,String,Array,null]},labelHideOverlapping:{type:Boolean},cursor:{type:[Function,String,null]},labelTextBrightnessRatio:{},labelPosition:{type:[Function,null]},strokeColor:{type:[Function,String,Array,null]},strokeWidth:{type:[Function,Number,null]},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(s,{expose:p}){const c=s,o=t.inject(d.componentAccessorKey),a=t.computed(()=>o.data.value??c.data),u=i.useForwardProps(c),n=t.ref();return t.onMounted(()=>{t.nextTick(()=>{var e;n.value=new y.Scatter(u.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(u,(e,r)=>{var l;i.arePropsEqual(e,r)||(l=n.value)==null||l.setConfig(u.value)}),t.watch(a,()=>{var e;(e=n.value)==null||e.setData(a.value)}),p({component:n}),(e,r)=>(t.openBlock(),t.createElementBlock("div",F))}});module.exports=v;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","sources":["../../../src/components/scatter/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 { Scatter, ScatterConfigInterface, 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\ninterface Props extends ScatterConfigInterface<Datum> { }\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n
|
|
1
|
+
{"version":3,"file":"index.cjs","sources":["../../../src/components/scatter/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 { Scatter, ScatterConfigInterface, 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\ninterface Props extends ScatterConfigInterface<Datum> { }\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n size: { type: [Function, Number, null] },\n sizeScale: { type: [Object, Function] },\n sizeRange: {},\n shape: { type: [Function, String] },\n label: { type: [Function, String, null] },\n labelColor: { type: [Function, String, Array, null] },\n labelHideOverlapping: { type: Boolean },\n cursor: { type: [Function, String, null] },\n labelTextBrightnessRatio: {},\n labelPosition: { type: [Function, null] },\n strokeColor: { type: [Function, String, Array, null] },\n strokeWidth: { type: [Function, Number, null] },\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<Scatter<Datum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Scatter<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","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","componentAccessorKey","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","Scatter","_a","onUnmounted","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":"oIAGMA,EAAa,CAAE,qBAAsB,IASfC,EAAiBC,kBAAA,CAC3C,OAAQ,QACR,MAAO,CACL,KAAM,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EACvC,UAAW,CAAE,KAAM,CAAC,OAAQ,QAAQ,CAAE,EACtC,UAAW,CAAC,EACZ,MAAO,CAAE,KAAM,CAAC,SAAU,MAAM,CAAE,EAClC,MAAO,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EACxC,WAAY,CAAE,KAAM,CAAC,SAAU,OAAQ,MAAO,IAAI,CAAE,EACpD,qBAAsB,CAAE,KAAM,OAAQ,EACtC,OAAQ,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EACzC,yBAA0B,CAAC,EAC3B,cAAe,CAAE,KAAM,CAAC,SAAU,IAAI,CAAE,EACxC,YAAa,CAAE,KAAM,CAAC,SAAU,OAAQ,MAAO,IAAI,CAAE,EACrD,YAAa,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EAC9C,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,IAAII,EAAe,QAAAN,EAAO,KAAK,GACvCO,EAAAL,EAAA,QAAA,MAAAK,EAAO,QAAQT,EAAK,OACrBH,EAAA,OAAOO,EAAU,KAAK,CAAA,CAChC,CAAA,CACF,EAEDM,EAAAA,YAAY,IAAM,QAChBD,EAAAL,EAAU,QAAV,MAAAK,EAAiB,UACjBZ,EAAS,QAAQ,CAAA,CAClB,EAEKc,EAAAA,MAAAT,EAAQ,CAACU,EAAMC,IAAS,OACvBC,EAAA,cAAcF,EAAMC,CAAI,IACjBJ,EAAAL,EAAA,QAAA,MAAAK,EAAO,UAAUP,EAAO,MACpC,CACD,EAEDS,EAAA,MAAMX,EAAM,IAAM,QACNS,EAAAL,EAAA,QAAA,MAAAK,EAAO,QAAQT,EAAK,MAAK,CACpC,EAEQL,EAAA,CACP,UAAAS,CAAA,CACD,EAEM,CAACW,EAAUC,KACRC,EAAW,UAAA,EAAGC,EAAAA,mBAAoB,MAAO3B,CAAU,EAE7D,CAEA,CAAC"}
|
|
@@ -5,11 +5,11 @@ declare const _default: <Datum>(__VLS_props: any, __VLS_ctx?: {
|
|
|
5
5
|
slots: any;
|
|
6
6
|
}, __VLS_expose?: any, __VLS_setup?: Promise<{
|
|
7
7
|
props: {
|
|
8
|
-
color?: import("@unovis/ts").ColorAccessor<Datum>;
|
|
9
8
|
cursor?: import("@unovis/ts").StringAccessor<Datum>;
|
|
10
9
|
x: NumericAccessor<Datum>;
|
|
11
10
|
y: NumericAccessor<Datum> | NumericAccessor<Datum>[];
|
|
12
11
|
id?: (d: Datum, i: number, ...any: any[]) => string;
|
|
12
|
+
color?: string | string[] | ((d: Datum, i: number, ...any: any[]) => string) | ((d: Datum[], i: number, ...any: any[]) => string);
|
|
13
13
|
xScale?: import("@unovis/ts").ContinuousScale;
|
|
14
14
|
yScale?: import("@unovis/ts").ContinuousScale;
|
|
15
15
|
excludeFromDomainCalculation?: boolean;
|
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
import { defineComponent as s, inject as
|
|
1
|
+
import { defineComponent as s, inject as y, computed as m, ref as d, onMounted as F, nextTick as v, onUnmounted as b, watch as c, openBlock as f, createElementBlock as g } from "vue";
|
|
2
2
|
import { Scatter as S } from "@unovis/ts";
|
|
3
3
|
import { useForwardProps as x, arePropsEqual as _ } from "../../utils/props.js";
|
|
4
4
|
import { componentAccessorKey as h } from "../../utils/context.js";
|
|
5
|
-
const k = { "data-vis-component": "" },
|
|
5
|
+
const k = { "data-vis-component": "" }, N = /* @__PURE__ */ s({
|
|
6
6
|
__name: "index",
|
|
7
7
|
props: {
|
|
8
|
-
color: { type: [Function, String, null] },
|
|
9
8
|
size: { type: [Function, Number, null] },
|
|
10
9
|
sizeScale: { type: [Object, Function] },
|
|
11
10
|
sizeRange: {},
|
|
12
11
|
shape: { type: [Function, String] },
|
|
13
12
|
label: { type: [Function, String, null] },
|
|
14
|
-
labelColor: { type: [Function, String, null] },
|
|
13
|
+
labelColor: { type: [Function, String, Array, null] },
|
|
15
14
|
labelHideOverlapping: { type: Boolean },
|
|
16
15
|
cursor: { type: [Function, String, null] },
|
|
17
16
|
labelTextBrightnessRatio: {},
|
|
18
17
|
labelPosition: { type: [Function, null] },
|
|
19
|
-
strokeColor: { type: [Function, String, null] },
|
|
18
|
+
strokeColor: { type: [Function, String, Array, null] },
|
|
20
19
|
strokeWidth: { type: [Function, Number, null] },
|
|
21
20
|
x: { type: [Function, Number, null] },
|
|
22
21
|
y: { type: [Function, Number, null, Array] },
|
|
23
22
|
id: { type: Function },
|
|
23
|
+
color: { type: [Function, String, Array, null] },
|
|
24
24
|
xScale: { type: [Object, Function] },
|
|
25
25
|
yScale: { type: [Object, Function] },
|
|
26
26
|
excludeFromDomainCalculation: { type: Boolean },
|
|
@@ -29,8 +29,8 @@ const k = { "data-vis-component": "" }, O = /* @__PURE__ */ s({
|
|
|
29
29
|
attributes: {},
|
|
30
30
|
data: {}
|
|
31
31
|
},
|
|
32
|
-
setup(
|
|
33
|
-
const l =
|
|
32
|
+
setup(i, { expose: p }) {
|
|
33
|
+
const l = i, n = y(h), o = m(() => n.data.value ?? l.data), a = x(l), t = d();
|
|
34
34
|
return F(() => {
|
|
35
35
|
v(() => {
|
|
36
36
|
var e;
|
|
@@ -39,18 +39,18 @@ const k = { "data-vis-component": "" }, O = /* @__PURE__ */ s({
|
|
|
39
39
|
}), b(() => {
|
|
40
40
|
var e;
|
|
41
41
|
(e = t.value) == null || e.destroy(), n.destroy();
|
|
42
|
-
}),
|
|
43
|
-
var
|
|
44
|
-
_(e,
|
|
45
|
-
}),
|
|
42
|
+
}), c(a, (e, r) => {
|
|
43
|
+
var u;
|
|
44
|
+
_(e, r) || (u = t.value) == null || u.setConfig(a.value);
|
|
45
|
+
}), c(o, () => {
|
|
46
46
|
var e;
|
|
47
47
|
(e = t.value) == null || e.setData(o.value);
|
|
48
48
|
}), p({
|
|
49
49
|
component: t
|
|
50
|
-
}), (e,
|
|
50
|
+
}), (e, r) => (f(), g("div", k));
|
|
51
51
|
}
|
|
52
52
|
});
|
|
53
53
|
export {
|
|
54
|
-
|
|
54
|
+
N as default
|
|
55
55
|
};
|
|
56
56
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../src/components/scatter/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 { Scatter, ScatterConfigInterface, 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\ninterface Props extends ScatterConfigInterface<Datum> { }\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../src/components/scatter/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 { Scatter, ScatterConfigInterface, 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\ninterface Props extends ScatterConfigInterface<Datum> { }\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n size: { type: [Function, Number, null] },\n sizeScale: { type: [Object, Function] },\n sizeRange: {},\n shape: { type: [Function, String] },\n label: { type: [Function, String, null] },\n labelColor: { type: [Function, String, Array, null] },\n labelHideOverlapping: { type: Boolean },\n cursor: { type: [Function, String, null] },\n labelTextBrightnessRatio: {},\n labelPosition: { type: [Function, null] },\n strokeColor: { type: [Function, String, Array, null] },\n strokeWidth: { type: [Function, Number, null] },\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<Scatter<Datum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new Scatter<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","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","componentAccessorKey","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","Scatter","_a","onUnmounted","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":";;;;AAGA,MAAMA,IAAa,EAAE,sBAAsB,MASfC,IAAiBC,gBAAAA,EAAA;AAAA,EAC3C,QAAQ;AAAA,EACR,OAAO;AAAA,IACL,MAAM,EAAE,MAAM,CAAC,UAAU,QAAQ,IAAI,EAAE;AAAA,IACvC,WAAW,EAAE,MAAM,CAAC,QAAQ,QAAQ,EAAE;AAAA,IACtC,WAAW,CAAC;AAAA,IACZ,OAAO,EAAE,MAAM,CAAC,UAAU,MAAM,EAAE;AAAA,IAClC,OAAO,EAAE,MAAM,CAAC,UAAU,QAAQ,IAAI,EAAE;AAAA,IACxC,YAAY,EAAE,MAAM,CAAC,UAAU,QAAQ,OAAO,IAAI,EAAE;AAAA,IACpD,sBAAsB,EAAE,MAAM,QAAQ;AAAA,IACtC,QAAQ,EAAE,MAAM,CAAC,UAAU,QAAQ,IAAI,EAAE;AAAA,IACzC,0BAA0B,CAAC;AAAA,IAC3B,eAAe,EAAE,MAAM,CAAC,UAAU,IAAI,EAAE;AAAA,IACxC,aAAa,EAAE,MAAM,CAAC,UAAU,QAAQ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,EAAO;AAAA,IACpC,CACD,GAEDS,EAAMX,GAAM,MAAM;;AACN,OAAAS,IAAAL,EAAA,UAAA,QAAAK,EAAO,QAAQT,EAAK;AAAA,IAAK,CACpC,GAEQL,EAAA;AAAA,MACP,WAAAS;AAAA,IAAA,CACD,GAEM,CAACW,GAAUC,OACRC,EAAW,GAAGC,EAAoB,OAAO3B,CAAU;AAAA,EAE7D;AAEA,CAAC;"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";const t=require("vue"),d=require("@unovis/ts"),s=require("../../utils/props.cjs"),y=require("../../utils/context.cjs"),v={"data-vis-component":""},m=t.defineComponent({__name:"index",props:{
|
|
1
|
+
"use strict";const t=require("vue"),d=require("@unovis/ts"),s=require("../../utils/props.cjs"),y=require("../../utils/context.cjs"),v={"data-vis-component":""},m=t.defineComponent({__name:"index",props:{barWidth:{},barMaxWidth:{},dataStep:{},barPadding:{},roundedCorners:{type:[Number,Boolean]},cursor:{type:[Function,String,null]},barMinHeight1Px:{type:Boolean},barMinHeightZeroValue:{},orientation:{},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(l,{expose:p}){const c=l,o=t.inject(y.componentAccessorKey),a=t.computed(()=>o.data.value??c.data),r=s.useForwardProps(c),n=t.ref();return t.onMounted(()=>{t.nextTick(()=>{var e;n.value=new d.StackedBar(r.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(r,(e,u)=>{var i;s.arePropsEqual(e,u)||(i=n.value)==null||i.setConfig(r.value)}),t.watch(a,()=>{var e;(e=n.value)==null||e.setData(a.value)}),p({component:n}),(e,u)=>(t.openBlock(),t.createElementBlock("div",v))}});module.exports=m;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","sources":["../../../src/components/stacked-bar/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 { StackedBar, StackedBarConfigInterface, 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\ninterface Props extends StackedBarConfigInterface<Datum> { }\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n
|
|
1
|
+
{"version":3,"file":"index.cjs","sources":["../../../src/components/stacked-bar/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 { StackedBar, StackedBarConfigInterface, 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\ninterface Props extends StackedBarConfigInterface<Datum> { }\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n barWidth: {},\n barMaxWidth: {},\n dataStep: {},\n barPadding: {},\n roundedCorners: { type: [Number, Boolean] },\n cursor: { type: [Function, String, null] },\n barMinHeight1Px: { type: Boolean },\n barMinHeightZeroValue: {},\n orientation: {},\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<StackedBar<Datum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new StackedBar<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","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","componentAccessorKey","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","StackedBar","_a","onUnmounted","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":"oIAGMA,EAAa,CAAE,qBAAsB,IASfC,EAAiBC,kBAAA,CAC3C,OAAQ,QACR,MAAO,CACL,SAAU,CAAC,EACX,YAAa,CAAC,EACd,SAAU,CAAC,EACX,WAAY,CAAC,EACb,eAAgB,CAAE,KAAM,CAAC,OAAQ,OAAO,CAAE,EAC1C,OAAQ,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EACzC,gBAAiB,CAAE,KAAM,OAAQ,EACjC,sBAAuB,CAAC,EACxB,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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
|
|
5
5
|
slots: any;
|
|
6
6
|
}, __VLS_expose?: any, __VLS_setup?: Promise<{
|
|
7
7
|
props: {
|
|
8
|
-
color?: import("@unovis/ts").ColorAccessor<Datum>;
|
|
9
8
|
cursor?: import("@unovis/ts").StringAccessor<Datum>;
|
|
10
9
|
x: NumericAccessor<Datum>;
|
|
11
10
|
y: NumericAccessor<Datum> | NumericAccessor<Datum>[];
|
|
12
11
|
id?: (d: Datum, i: number, ...any: any[]) => string;
|
|
12
|
+
color?: string | string[] | ((d: Datum, i: number, ...any: any[]) => string) | ((d: Datum[], i: number, ...any: any[]) => string);
|
|
13
13
|
xScale?: import("@unovis/ts").ContinuousScale;
|
|
14
14
|
yScale?: import("@unovis/ts").ContinuousScale;
|
|
15
15
|
excludeFromDomainCalculation?: boolean;
|
|
@@ -5,7 +5,6 @@ import { componentAccessorKey as B } from "../../utils/context.js";
|
|
|
5
5
|
const S = { "data-vis-component": "" }, j = /* @__PURE__ */ s({
|
|
6
6
|
__name: "index",
|
|
7
7
|
props: {
|
|
8
|
-
color: { type: [Function, String, null] },
|
|
9
8
|
barWidth: {},
|
|
10
9
|
barMaxWidth: {},
|
|
11
10
|
dataStep: {},
|
|
@@ -18,6 +17,7 @@ const S = { "data-vis-component": "" }, j = /* @__PURE__ */ s({
|
|
|
18
17
|
x: { type: [Function, Number, null] },
|
|
19
18
|
y: { type: [Function, Number, null, Array] },
|
|
20
19
|
id: { type: Function },
|
|
20
|
+
color: { type: [Function, String, Array, null] },
|
|
21
21
|
xScale: { type: [Object, Function] },
|
|
22
22
|
yScale: { type: [Object, Function] },
|
|
23
23
|
excludeFromDomainCalculation: { type: Boolean },
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../src/components/stacked-bar/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 { StackedBar, StackedBarConfigInterface, 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\ninterface Props extends StackedBarConfigInterface<Datum> { }\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../src/components/stacked-bar/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 { StackedBar, StackedBarConfigInterface, 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\ninterface Props extends StackedBarConfigInterface<Datum> { }\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n barWidth: {},\n barMaxWidth: {},\n dataStep: {},\n barPadding: {},\n roundedCorners: { type: [Number, Boolean] },\n cursor: { type: [Function, String, null] },\n barMinHeight1Px: { type: Boolean },\n barMinHeightZeroValue: {},\n orientation: {},\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<StackedBar<Datum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new StackedBar<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","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","componentAccessorKey","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","StackedBar","_a","onUnmounted","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":";;;;AAGA,MAAMA,IAAa,EAAE,sBAAsB,MASfC,IAAiBC,gBAAAA,EAAA;AAAA,EAC3C,QAAQ;AAAA,EACR,OAAO;AAAA,IACL,UAAU,CAAC;AAAA,IACX,aAAa,CAAC;AAAA,IACd,UAAU,CAAC;AAAA,IACX,YAAY,CAAC;AAAA,IACb,gBAAgB,EAAE,MAAM,CAAC,QAAQ,OAAO,EAAE;AAAA,IAC1C,QAAQ,EAAE,MAAM,CAAC,UAAU,QAAQ,IAAI,EAAE;AAAA,IACzC,iBAAiB,EAAE,MAAM,QAAQ;AAAA,IACjC,uBAAuB,CAAC;AAAA,IACxB,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,QAA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Promise<{
|
|
8
8
|
props: {
|
|
9
|
-
color?: import("@unovis/ts").ColorAccessor<Datum>;
|
|
10
9
|
cursor?: StringAccessor<Datum>;
|
|
11
10
|
x: NumericAccessor<Datum>;
|
|
12
11
|
y?: NumericAccessor<Datum> | NumericAccessor<Datum>[];
|
|
13
12
|
id?: (d: Datum, i: number, ...any: any[]) => string;
|
|
13
|
+
color?: string | string[] | ((d: Datum, i: number, ...any: any[]) => string) | ((d: Datum[], i: number, ...any: any[]) => string);
|
|
14
14
|
xScale?: import("@unovis/ts").ContinuousScale;
|
|
15
15
|
yScale?: import("@unovis/ts").ContinuousScale;
|
|
16
16
|
excludeFromDomainCalculation?: boolean;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Tooltip } from '@unovis/ts';
|
|
2
2
|
declare const _default: import("vue").DefineComponent<{
|
|
3
3
|
components: {
|
|
4
|
-
type: import("vue").PropType<import("@unovis/ts").ComponentCore<unknown, import("@unovis/ts").ComponentConfigInterface>[]>;
|
|
4
|
+
type: import("vue").PropType<import("@unovis/ts").ComponentCore<unknown, import("@unovis/ts/lib/core/component/config").ComponentConfig, import("@unovis/ts").ComponentConfigInterface>[]>;
|
|
5
5
|
};
|
|
6
6
|
container: {
|
|
7
7
|
type: import("vue").PropType<HTMLElement>;
|
|
@@ -35,7 +35,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
35
35
|
component: import("vue").Ref<Tooltip>;
|
|
36
36
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
37
37
|
components: {
|
|
38
|
-
type: import("vue").PropType<import("@unovis/ts").ComponentCore<unknown, import("@unovis/ts").ComponentConfigInterface>[]>;
|
|
38
|
+
type: import("vue").PropType<import("@unovis/ts").ComponentCore<unknown, import("@unovis/ts/lib/core/component/config").ComponentConfig, import("@unovis/ts").ComponentConfigInterface>[]>;
|
|
39
39
|
};
|
|
40
40
|
container: {
|
|
41
41
|
type: import("vue").PropType<HTMLElement>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";const n=require("vue"),d=require("@unovis/ts"),p=require("../../utils/props.cjs"),
|
|
1
|
+
"use strict";const n=require("vue"),d=require("@unovis/ts"),p=require("../../utils/props.cjs"),y=require("../../utils/context.cjs"),m={"data-vis-component":""},F=n.defineComponent({__name:"index",props:{projection:{type:[Function,Object]},topojson:{},mapFeatureName:{},mapFitToPoints:{type:Boolean},zoomFactor:{},disableZoom:{type:Boolean},zoomExtent:{},zoomDuration:{},linkWidth:{type:[Function,Number,null]},linkColor:{type:[Function,String,Array,null]},linkCursor:{type:[Function,String,null]},linkId:{type:[Function,String,null]},linkSource:{type:Function},linkTarget:{type:Function},areaId:{type:[Function,String,null]},areaColor:{type:[Function,String,Array,null]},areaCursor:{type:[Function,String,null]},pointColor:{type:[Function,String,Array,null]},pointRadius:{type:[Function,Number,null]},pointStrokeWidth:{type:[Function,Number,null]},pointCursor:{type:[Function,String,null]},longitude:{type:[Function,Number,null]},latitude:{type:[Function,Number,null]},pointLabel:{type:[Function,String,null]},pointLabelPosition:{},pointLabelTextBrightnessRatio:{},pointId:{type:Function},heatmapMode:{type:Boolean},heatmapModeBlurStdDeviation:{},heatmapModeZoomLevelThreshold:{},duration:{},events:{},attributes:{},data:{}},setup(c,{expose:s}){const a=c,o=n.inject(y.componentAccessorKey),i=n.computed(()=>o.data.value??a.data),u=p.useForwardProps(a),e=n.ref();return n.onMounted(()=>{n.nextTick(()=>{var t;e.value=new d.TopoJSONMap(u.value),(t=e.value)==null||t.setData(i.value),o.update(e.value)})}),n.onUnmounted(()=>{var t;(t=e.value)==null||t.destroy(),o.destroy()}),n.watch(u,(t,r)=>{var l;p.arePropsEqual(t,r)||(l=e.value)==null||l.setConfig(u.value)}),n.watch(i,()=>{var t;(t=e.value)==null||t.setData(i.value)}),s({component:e}),(t,r)=>(n.openBlock(),n.createElementBlock("div",m))}});module.exports=F;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","sources":["../../../src/components/topojson-map/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 { TopoJSONMap, TopoJSONMapConfigInterface } 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\ninterface Props extends TopoJSONMapConfigInterface<AreaDatum, PointDatum, LinkDatum> { }\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n projection: { type: [Function, Object] },\n topojson: {},\n mapFeatureName: {},\n mapFitToPoints: { type: Boolean },\n zoomFactor: {},\n disableZoom: { type: Boolean },\n zoomExtent: {},\n zoomDuration: {},\n linkWidth: { type: [Function, Number, null] },\n linkColor: { type: [Function, String, null] },\n linkCursor: { type: [Function, String, null] },\n linkId: { type: [Function, String, null] },\n linkSource: { type: Function },\n linkTarget: { type: Function },\n areaId: { type: [Function, String, null] },\n areaColor: { type: [Function, String, null] },\n areaCursor: { type: [Function, String, null] },\n pointColor: { type: [Function, String, null] },\n pointRadius: { type: [Function, Number, null] },\n pointStrokeWidth: { type: [Function, Number, null] },\n pointCursor: { type: [Function, String, null] },\n longitude: { type: [Function, Number, null] },\n latitude: { type: [Function, Number, null] },\n pointLabel: { type: [Function, String, null] },\n pointLabelPosition: {},\n pointLabelTextBrightnessRatio: {},\n pointId: { type: Function },\n heatmapMode: { type: Boolean },\n heatmapModeBlurStdDeviation: {},\n heatmapModeZoomLevelThreshold: {},\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<TopoJSONMap<AreaDatum, PointDatum, LinkDatum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new TopoJSONMap<AreaDatum, PointDatum, LinkDatum>(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","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","componentAccessorKey","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","TopoJSONMap","_a","onUnmounted","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":"oIAGMA,EAAa,CAAE,qBAAsB,IASfC,EAAiBC,kBAAA,CAC3C,OAAQ,QACR,MAAO,CACL,WAAY,CAAE,KAAM,CAAC,SAAU,MAAM,CAAE,EACvC,SAAU,CAAC,EACX,eAAgB,CAAC,EACjB,eAAgB,CAAE,KAAM,OAAQ,EAChC,WAAY,CAAC,EACb,YAAa,CAAE,KAAM,OAAQ,EAC7B,WAAY,CAAC,EACb,aAAc,CAAC,EACf,UAAW,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EAC5C,UAAW,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,
|
|
1
|
+
{"version":3,"file":"index.cjs","sources":["../../../src/components/topojson-map/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 { TopoJSONMap, TopoJSONMapConfigInterface } 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\ninterface Props extends TopoJSONMapConfigInterface<AreaDatum, PointDatum, LinkDatum> { }\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n projection: { type: [Function, Object] },\n topojson: {},\n mapFeatureName: {},\n mapFitToPoints: { type: Boolean },\n zoomFactor: {},\n disableZoom: { type: Boolean },\n zoomExtent: {},\n zoomDuration: {},\n linkWidth: { type: [Function, Number, null] },\n linkColor: { type: [Function, String, Array, null] },\n linkCursor: { type: [Function, String, null] },\n linkId: { type: [Function, String, null] },\n linkSource: { type: Function },\n linkTarget: { type: Function },\n areaId: { type: [Function, String, null] },\n areaColor: { type: [Function, String, Array, null] },\n areaCursor: { type: [Function, String, null] },\n pointColor: { type: [Function, String, Array, null] },\n pointRadius: { type: [Function, Number, null] },\n pointStrokeWidth: { type: [Function, Number, null] },\n pointCursor: { type: [Function, String, null] },\n longitude: { type: [Function, Number, null] },\n latitude: { type: [Function, Number, null] },\n pointLabel: { type: [Function, String, null] },\n pointLabelPosition: {},\n pointLabelTextBrightnessRatio: {},\n pointId: { type: Function },\n heatmapMode: { type: Boolean },\n heatmapModeBlurStdDeviation: {},\n heatmapModeZoomLevelThreshold: {},\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<TopoJSONMap<AreaDatum, PointDatum, LinkDatum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new TopoJSONMap<AreaDatum, PointDatum, LinkDatum>(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","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","componentAccessorKey","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","TopoJSONMap","_a","onUnmounted","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":"oIAGMA,EAAa,CAAE,qBAAsB,IASfC,EAAiBC,kBAAA,CAC3C,OAAQ,QACR,MAAO,CACL,WAAY,CAAE,KAAM,CAAC,SAAU,MAAM,CAAE,EACvC,SAAU,CAAC,EACX,eAAgB,CAAC,EACjB,eAAgB,CAAE,KAAM,OAAQ,EAChC,WAAY,CAAC,EACb,YAAa,CAAE,KAAM,OAAQ,EAC7B,WAAY,CAAC,EACb,aAAc,CAAC,EACf,UAAW,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EAC5C,UAAW,CAAE,KAAM,CAAC,SAAU,OAAQ,MAAO,IAAI,CAAE,EACnD,WAAY,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EAC7C,OAAQ,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EACzC,WAAY,CAAE,KAAM,QAAS,EAC7B,WAAY,CAAE,KAAM,QAAS,EAC7B,OAAQ,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EACzC,UAAW,CAAE,KAAM,CAAC,SAAU,OAAQ,M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B,EAEKc,EAAAA,MAAAT,EAAQ,CAACU,EAAMC,IAAS,OACvBC,EAAA,cAAcF,EAAMC,CAAI,IACjBJ,EAAAL,EAAA,QAAA,MAAAK,EAAO,UAAUP,EAAO,MACpC,CACD,EAEDS,EAAA,MAAMX,EAAM,IAAM,QACNS,EAAAL,EAAA,QAAA,MAAAK,EAAO,QAAQT,EAAK,MAAK,CACpC,EAEQL,EAAA,CACP,UAAAS,CAAA,CACD,EAEM,CAACW,EAAUC,KACRC,EAAW,UAAA,EAAGC,EAAAA,mBAAoB,MAAO3B,CAAU,EAE7D,CAEA,CAAC"}
|
|
@@ -44,7 +44,7 @@ declare const _default: <AreaDatum, PointDatum, LinkDatum>(__VLS_props: any, __V
|
|
|
44
44
|
linkColor?: import("@unovis/ts").ColorAccessor<LinkDatum>;
|
|
45
45
|
disableZoom?: boolean;
|
|
46
46
|
linkWidth?: import("@unovis/ts").NumericAccessor<LinkDatum>;
|
|
47
|
-
linkCursor?: import("@unovis/ts").StringAccessor<
|
|
47
|
+
linkCursor?: import("@unovis/ts").StringAccessor<AreaDatum>;
|
|
48
48
|
projection?: import("d3-geo").GeoProjection;
|
|
49
49
|
topojson?: import("topojson-specification").Topology<import("topojson-specification").Objects<{
|
|
50
50
|
[name: string]: any;
|
|
@@ -63,7 +63,7 @@ declare const _default: <AreaDatum, PointDatum, LinkDatum>(__VLS_props: any, __V
|
|
|
63
63
|
pointColor?: import("@unovis/ts").ColorAccessor<PointDatum>;
|
|
64
64
|
pointRadius?: import("@unovis/ts").NumericAccessor<PointDatum>;
|
|
65
65
|
pointStrokeWidth?: import("@unovis/ts").NumericAccessor<PointDatum>;
|
|
66
|
-
pointCursor?: import("@unovis/ts").StringAccessor<
|
|
66
|
+
pointCursor?: import("@unovis/ts").StringAccessor<AreaDatum>;
|
|
67
67
|
longitude?: import("@unovis/ts").NumericAccessor<PointDatum>;
|
|
68
68
|
latitude?: import("@unovis/ts").NumericAccessor<PointDatum>;
|
|
69
69
|
pointLabel?: import("@unovis/ts").StringAccessor<PointDatum>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as s, inject as m, computed as d, ref as y, onMounted as F, nextTick as v, onUnmounted as g, watch as
|
|
1
|
+
import { defineComponent as s, inject as m, computed as d, ref as y, onMounted as F, nextTick as v, onUnmounted as g, watch as l, openBlock as S, createElementBlock as b } from "vue";
|
|
2
2
|
import { TopoJSONMap as f } from "@unovis/ts";
|
|
3
3
|
import { useForwardProps as h, arePropsEqual as k } from "../../utils/props.js";
|
|
4
4
|
import { componentAccessorKey as C } from "../../utils/context.js";
|
|
@@ -14,15 +14,15 @@ const _ = { "data-vis-component": "" }, M = /* @__PURE__ */ s({
|
|
|
14
14
|
zoomExtent: {},
|
|
15
15
|
zoomDuration: {},
|
|
16
16
|
linkWidth: { type: [Function, Number, null] },
|
|
17
|
-
linkColor: { type: [Function, String, null] },
|
|
17
|
+
linkColor: { type: [Function, String, Array, null] },
|
|
18
18
|
linkCursor: { type: [Function, String, null] },
|
|
19
19
|
linkId: { type: [Function, String, null] },
|
|
20
20
|
linkSource: { type: Function },
|
|
21
21
|
linkTarget: { type: Function },
|
|
22
22
|
areaId: { type: [Function, String, null] },
|
|
23
|
-
areaColor: { type: [Function, String, null] },
|
|
23
|
+
areaColor: { type: [Function, String, Array, null] },
|
|
24
24
|
areaCursor: { type: [Function, String, null] },
|
|
25
|
-
pointColor: { type: [Function, String, null] },
|
|
25
|
+
pointColor: { type: [Function, String, Array, null] },
|
|
26
26
|
pointRadius: { type: [Function, Number, null] },
|
|
27
27
|
pointStrokeWidth: { type: [Function, Number, null] },
|
|
28
28
|
pointCursor: { type: [Function, String, null] },
|
|
@@ -50,15 +50,15 @@ const _ = { "data-vis-component": "" }, M = /* @__PURE__ */ s({
|
|
|
50
50
|
}), g(() => {
|
|
51
51
|
var t;
|
|
52
52
|
(t = n.value) == null || t.destroy(), o.destroy();
|
|
53
|
-
}),
|
|
54
|
-
var
|
|
55
|
-
k(t,
|
|
56
|
-
}),
|
|
53
|
+
}), l(i, (t, r) => {
|
|
54
|
+
var u;
|
|
55
|
+
k(t, r) || (u = n.value) == null || u.setConfig(i.value);
|
|
56
|
+
}), l(e, () => {
|
|
57
57
|
var t;
|
|
58
58
|
(t = n.value) == null || t.setData(e.value);
|
|
59
59
|
}), c({
|
|
60
60
|
component: n
|
|
61
|
-
}), (t,
|
|
61
|
+
}), (t, r) => (S(), b("div", _));
|
|
62
62
|
}
|
|
63
63
|
});
|
|
64
64
|
export {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../src/components/topojson-map/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 { TopoJSONMap, TopoJSONMapConfigInterface } 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\ninterface Props extends TopoJSONMapConfigInterface<AreaDatum, PointDatum, LinkDatum> { }\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n projection: { type: [Function, Object] },\n topojson: {},\n mapFeatureName: {},\n mapFitToPoints: { type: Boolean },\n zoomFactor: {},\n disableZoom: { type: Boolean },\n zoomExtent: {},\n zoomDuration: {},\n linkWidth: { type: [Function, Number, null] },\n linkColor: { type: [Function, String, null] },\n linkCursor: { type: [Function, String, null] },\n linkId: { type: [Function, String, null] },\n linkSource: { type: Function },\n linkTarget: { type: Function },\n areaId: { type: [Function, String, null] },\n areaColor: { type: [Function, String, null] },\n areaCursor: { type: [Function, String, null] },\n pointColor: { type: [Function, String, null] },\n pointRadius: { type: [Function, Number, null] },\n pointStrokeWidth: { type: [Function, Number, null] },\n pointCursor: { type: [Function, String, null] },\n longitude: { type: [Function, Number, null] },\n latitude: { type: [Function, Number, null] },\n pointLabel: { type: [Function, String, null] },\n pointLabelPosition: {},\n pointLabelTextBrightnessRatio: {},\n pointId: { type: Function },\n heatmapMode: { type: Boolean },\n heatmapModeBlurStdDeviation: {},\n heatmapModeZoomLevelThreshold: {},\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<TopoJSONMap<AreaDatum, PointDatum, LinkDatum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new TopoJSONMap<AreaDatum, PointDatum, LinkDatum>(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","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","componentAccessorKey","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","TopoJSONMap","_a","onUnmounted","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":";;;;AAGA,MAAMA,IAAa,EAAE,sBAAsB,MASfC,IAAiBC,gBAAAA,EAAA;AAAA,EAC3C,QAAQ;AAAA,EACR,OAAO;AAAA,IACL,YAAY,EAAE,MAAM,CAAC,UAAU,MAAM,EAAE;AAAA,IACvC,UAAU,CAAC;AAAA,IACX,gBAAgB,CAAC;AAAA,IACjB,gBAAgB,EAAE,MAAM,QAAQ;AAAA,IAChC,YAAY,CAAC;AAAA,IACb,aAAa,EAAE,MAAM,QAAQ;AAAA,IAC7B,YAAY,CAAC;AAAA,IACb,cAAc,CAAC;AAAA,IACf,WAAW,EAAE,MAAM,CAAC,UAAU,QAAQ,IAAI,EAAE;AAAA,IAC5C,WAAW,EAAE,MAAM,CAAC,UAAU,QAAQ,IAAI,EAAE;AAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../src/components/topojson-map/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 { TopoJSONMap, TopoJSONMapConfigInterface } 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\ninterface Props extends TopoJSONMapConfigInterface<AreaDatum, PointDatum, LinkDatum> { }\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n projection: { type: [Function, Object] },\n topojson: {},\n mapFeatureName: {},\n mapFitToPoints: { type: Boolean },\n zoomFactor: {},\n disableZoom: { type: Boolean },\n zoomExtent: {},\n zoomDuration: {},\n linkWidth: { type: [Function, Number, null] },\n linkColor: { type: [Function, String, Array, null] },\n linkCursor: { type: [Function, String, null] },\n linkId: { type: [Function, String, null] },\n linkSource: { type: Function },\n linkTarget: { type: Function },\n areaId: { type: [Function, String, null] },\n areaColor: { type: [Function, String, Array, null] },\n areaCursor: { type: [Function, String, null] },\n pointColor: { type: [Function, String, Array, null] },\n pointRadius: { type: [Function, Number, null] },\n pointStrokeWidth: { type: [Function, Number, null] },\n pointCursor: { type: [Function, String, null] },\n longitude: { type: [Function, Number, null] },\n latitude: { type: [Function, Number, null] },\n pointLabel: { type: [Function, String, null] },\n pointLabelPosition: {},\n pointLabelTextBrightnessRatio: {},\n pointId: { type: Function },\n heatmapMode: { type: Boolean },\n heatmapModeBlurStdDeviation: {},\n heatmapModeZoomLevelThreshold: {},\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<TopoJSONMap<AreaDatum, PointDatum, LinkDatum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new TopoJSONMap<AreaDatum, PointDatum, LinkDatum>(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","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","componentAccessorKey","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","TopoJSONMap","_a","onUnmounted","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":";;;;AAGA,MAAMA,IAAa,EAAE,sBAAsB,MASfC,IAAiBC,gBAAAA,EAAA;AAAA,EAC3C,QAAQ;AAAA,EACR,OAAO;AAAA,IACL,YAAY,EAAE,MAAM,CAAC,UAAU,MAAM,EAAE;AAAA,IACvC,UAAU,CAAC;AAAA,IACX,gBAAgB,CAAC;AAAA,IACjB,gBAAgB,EAAE,MAAM,QAAQ;AAAA,IAChC,YAAY,CAAC;AAAA,IACb,aAAa,EAAE,MAAM,QAAQ;AAAA,IAC7B,YAAY,CAAC;AAAA,I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C;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,IAAII,EAA8CN,EAAO,KAAK,IACtEO,IAAAL,EAAA,UAAA,QAAAK,EAAO,QAAQT,EAAK,QACrBH,EAAA,OAAOO,EAAU,KAAK;AAAA,MAAA,CAChC;AAAA,IAAA,CACF,GAEDM,EAAY,MAAM;;AAChB,OAAAD,IAAAL,EAAU,UAAV,QAAAK,EAAiB,WACjBZ,EAAS,QAAQ;AAAA,IAAA,CAClB,GAEKc,EAAAT,GAAQ,CAACU,GAAMC,MAAS;;AAC5B,MAAKC,EAAcF,GAAMC,CAAI,MACjBJ,IAAAL,EAAA,UAAA,QAAAK,EAAO,UAAUP,EAAO;AAAA,IACpC,CACD,GAEDS,EAAMX,GAAM,MAAM;;AACN,OAAAS,IAAAL,EAAA,UAAA,QAAAK,EAAO,QAAQT,EAAK;AAAA,IAAK,CACpC,GAEQL,EAAA;AAAA,MACP,WAAAS;AAAA,IAAA,CACD,GAEM,CAACW,GAAUC,OACRC,EAAW,GAAGC,EAAoB,OAAO3B,CAAU;AAAA,EAE7D;AAEA,CAAC;"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";const e=require("vue"),y=require("@unovis/ts"),
|
|
1
|
+
"use strict";const e=require("vue"),y=require("@unovis/ts"),i=require("../../utils/props.cjs"),d=require("../../utils/context.cjs"),F={"data-vis-component":""},g=e.defineComponent({__name:"index",props:{y:{type:[Function,Number,null]},xPositioning:{type:[Function,null]},yPositioning:{type:[Function,null]},labelFontSize:{type:[Function,Number,null]},label:{type:[Function,String,null]},backgroundColor:{type:[Function,String,Array,null]},cursor:{type:[Function,String,null]},labelTextBrightnessRatio:{},clustering:{type:Boolean},clusterLabel:{type:[Function,String,null]},clusterFontSize:{type:[Function,Number,null]},clusterBackgroundColor:{type:[Function,String,Array,null]},clusterCursor:{type:[Function,String,null]},clusterLabelColor:{type:[Function,String,Array,null]},x:{type:[Function,Number,null]},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(s,{expose:p}){const r=s,o=e.inject(d.componentAccessorKey),u=e.computed(()=>o.data.value??r.data),l=i.useForwardProps(r),n=e.ref();return e.onMounted(()=>{e.nextTick(()=>{var t;n.value=new y.XYLabels(l.value),(t=n.value)==null||t.setData(u.value),o.update(n.value)})}),e.onUnmounted(()=>{var t;(t=n.value)==null||t.destroy(),o.destroy()}),e.watch(l,(t,c)=>{var a;i.arePropsEqual(t,c)||(a=n.value)==null||a.setConfig(l.value)}),e.watch(u,()=>{var t;(t=n.value)==null||t.setData(u.value)}),p({component:n}),(t,c)=>(e.openBlock(),e.createElementBlock("div",F))}});module.exports=g;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","sources":["../../../src/components/xy-labels/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 { XYLabels, XYLabelsConfigInterface, 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\ninterface Props extends XYLabelsConfigInterface<Datum> { }\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n
|
|
1
|
+
{"version":3,"file":"index.cjs","sources":["../../../src/components/xy-labels/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 { XYLabels, XYLabelsConfigInterface, 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\ninterface Props extends XYLabelsConfigInterface<Datum> { }\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'index',\n props: {\n y: { type: [Function, Number, null] },\n xPositioning: { type: [Function, null] },\n yPositioning: { type: [Function, null] },\n labelFontSize: { type: [Function, Number, null] },\n label: { type: [Function, String, null] },\n backgroundColor: { type: [Function, String, Array, null] },\n cursor: { type: [Function, String, null] },\n labelTextBrightnessRatio: {},\n clustering: { type: Boolean },\n clusterLabel: { type: [Function, String, null] },\n clusterFontSize: { type: [Function, Number, null] },\n clusterBackgroundColor: { type: [Function, String, Array, null] },\n clusterCursor: { type: [Function, String, null] },\n clusterLabelColor: { type: [Function, String, Array, null] },\n x: { type: [Function, Number, null] },\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<XYLabels<Datum>>()\n\n\nonMounted(() => {\n nextTick(() => {\n component.value = new XYLabels<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","_sfc_main","_defineComponent","__props","__expose","props","accessor","inject","componentAccessorKey","data","computed","config","useForwardProps","component","ref","onMounted","nextTick","XYLabels","_a","onUnmounted","watch","curr","prev","arePropsEqual","_ctx","_cache","_openBlock","_createElementBlock"],"mappings":"oIAGMA,EAAa,CAAE,qBAAsB,IASfC,EAAiBC,kBAAA,CAC3C,OAAQ,QACR,MAAO,CACL,EAAG,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EACpC,aAAc,CAAE,KAAM,CAAC,SAAU,IAAI,CAAE,EACvC,aAAc,CAAE,KAAM,CAAC,SAAU,IAAI,CAAE,EACvC,cAAe,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EAChD,MAAO,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EACxC,gBAAiB,CAAE,KAAM,CAAC,SAAU,OAAQ,MAAO,IAAI,CAAE,EACzD,OAAQ,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EACzC,yBAA0B,CAAC,EAC3B,WAAY,CAAE,KAAM,OAAQ,EAC5B,aAAc,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EAC/C,gBAAiB,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EAClD,uBAAwB,CAAE,KAAM,CAAC,SAAU,OAAQ,MAAO,IAAI,CAAE,EAChE,cAAe,CAAE,KAAM,CAAC,SAAU,OAAQ,IAAI,CAAE,EAChD,kBAAmB,CAAE,KAAM,CAAC,SA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