@dpuse/dpuse-tool-d3-visualiser 0.0.32 → 0.0.37

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 (69) hide show
  1. package/README.md +658 -244
  2. package/dist/{band-DbExrcif.js → band-C1twWuW2.js} +3 -2
  3. package/dist/{band-DbExrcif.js.map → band-C1twWuW2.js.map} +1 -1
  4. package/dist/{billboardJs-jmaH9Gag.js → billboardJs-DS82ViEw.js} +1081 -1747
  5. package/dist/billboardJs-DS82ViEw.js.map +1 -0
  6. package/dist/chordDiagram-Cz0sVVgD.js +2911 -0
  7. package/dist/chordDiagram-Cz0sVVgD.js.map +1 -0
  8. package/dist/{d3BarChart-DEzayAyh.js → d3BarChart-DIN2KQsU.js} +7 -6
  9. package/dist/{d3BarChart-DEzayAyh.js.map → d3BarChart-DIN2KQsU.js.map} +1 -1
  10. package/dist/dpuse-tool-d3-visualiser.es.js +17 -7
  11. package/dist/dpuse-tool-d3-visualiser.es.js.map +1 -1
  12. package/dist/{drag-DLokvdmv.js → drag-DfL4uwqz.js} +25 -24
  13. package/dist/{drag-DLokvdmv.js.map → drag-DfL4uwqz.js.map} +1 -1
  14. package/dist/hierarchy-CDFAetye.js +151 -0
  15. package/dist/hierarchy-CDFAetye.js.map +1 -0
  16. package/dist/{linear-D3BD7E1p.js → linear-BnhqTvdX.js} +59 -85
  17. package/dist/linear-BnhqTvdX.js.map +1 -0
  18. package/dist/{link-DKK0Q0lG.js → link-D-9z7kEr.js} +16 -39
  19. package/dist/link-D-9z7kEr.js.map +1 -0
  20. package/dist/math-C5EhTgJw.js +12 -0
  21. package/dist/math-C5EhTgJw.js.map +1 -0
  22. package/dist/max-CPVNm4tn.js +14 -0
  23. package/dist/max-CPVNm4tn.js.map +1 -0
  24. package/dist/{networkDiagram-HS-SgOZ0.js → networkDiagram-yraPhqxN.js} +28 -28
  25. package/dist/{networkDiagram-HS-SgOZ0.js.map → networkDiagram-yraPhqxN.js.map} +1 -1
  26. package/dist/nodrag-Dq2tlBbe.js +51 -0
  27. package/dist/nodrag-Dq2tlBbe.js.map +1 -0
  28. package/dist/{observablePlot-B1CSEvcU.js → observablePlot-C7764aFq.js} +2366 -2417
  29. package/dist/observablePlot-C7764aFq.js.map +1 -0
  30. package/dist/ordinal-uZdoVxAx.js +30 -0
  31. package/dist/ordinal-uZdoVxAx.js.map +1 -0
  32. package/dist/palette-BuTjISrV.js +64 -0
  33. package/dist/palette-BuTjISrV.js.map +1 -0
  34. package/dist/{path-Bt1sPr2f.js → path-6kmCrmEz.js} +7 -4
  35. package/dist/{path-Bt1sPr2f.js.map → path-6kmCrmEz.js.map} +1 -1
  36. package/dist/point-6cHftmvM.js +27 -0
  37. package/dist/point-6cHftmvM.js.map +1 -0
  38. package/dist/pow-BFDPqS3s.js +86 -0
  39. package/dist/pow-BFDPqS3s.js.map +1 -0
  40. package/dist/{sankeyDiagram-BXTYCHPV.js → sankeyDiagram-BT2RCRpi.js} +93 -152
  41. package/dist/sankeyDiagram-BT2RCRpi.js.map +1 -0
  42. package/dist/{src-Br_t1-IV.js → src-WDualLFV.js} +40 -39
  43. package/dist/{src-Br_t1-IV.js.map → src-WDualLFV.js.map} +1 -1
  44. package/dist/{math-Dc0ICuib.js → src-Xlr4CcSw.js} +70 -75
  45. package/dist/src-Xlr4CcSw.js.map +1 -0
  46. package/dist/{src-Du_hPZAX.js → src-yL3ZdoR1.js} +235 -282
  47. package/dist/src-yL3ZdoR1.js.map +1 -0
  48. package/dist/step-DgCcZZ3W.js +670 -0
  49. package/dist/step-DgCcZZ3W.js.map +1 -0
  50. package/dist/{sum-BAZU479z.js → sum-CNP0Xric.js} +4 -15
  51. package/dist/sum-CNP0Xric.js.map +1 -0
  52. package/dist/{tanStackCharts-vvQteV9z.js → tanStackCharts-BJAX22lS.js} +164 -151
  53. package/dist/tanStackCharts-BJAX22lS.js.map +1 -0
  54. package/dist/treeDiagram-DsHUD8ou.js +130 -0
  55. package/dist/treeDiagram-DsHUD8ou.js.map +1 -0
  56. package/dist/types/src/chordDiagram.d.ts +25 -0
  57. package/dist/types/src/index.d.ts +3 -0
  58. package/package.json +6 -4
  59. package/dist/billboardJs-jmaH9Gag.js.map +0 -1
  60. package/dist/linear-D3BD7E1p.js.map +0 -1
  61. package/dist/link-DKK0Q0lG.js.map +0 -1
  62. package/dist/math-Dc0ICuib.js.map +0 -1
  63. package/dist/observablePlot-B1CSEvcU.js.map +0 -1
  64. package/dist/sankeyDiagram-BXTYCHPV.js.map +0 -1
  65. package/dist/src-Du_hPZAX.js.map +0 -1
  66. package/dist/sum-BAZU479z.js.map +0 -1
  67. package/dist/tanStackCharts-vvQteV9z.js.map +0 -1
  68. package/dist/treeDiagram-DemHfVnX.js +0 -277
  69. package/dist/treeDiagram-DemHfVnX.js.map +0 -1
@@ -1,6 +1,7 @@
1
- import { t as e } from "./select-BIuoFcZG.js";
2
- import { p as t, t as n } from "./linear-D3BD7E1p.js";
3
- import { t as r } from "./band-DbExrcif.js";
1
+ import { t as e } from "./linear-BnhqTvdX.js";
2
+ import { t } from "./band-C1twWuW2.js";
3
+ import { t as n } from "./select-BIuoFcZG.js";
4
+ import { n as r } from "./ordinal-uZdoVxAx.js";
4
5
  import { n as i, t as a } from "./axis-DjmZ9QYe.js";
5
6
  //#region src/d3BarChart.ts
6
7
  var o = 640, s = 400, c = {
@@ -17,8 +18,8 @@ var o = 640, s = 400, c = {
17
18
  ];
18
19
  function u(u, f) {
19
20
  function p() {
20
- e(f).selectAll("svg").remove();
21
- let p = f.clientWidth || o, m = f.clientHeight || s, h = p - c.left - c.right, g = m - c.top - c.bottom, _ = r().domain(u.categories).range([0, h]).padding(.2), v = r().domain(u.series.map((e) => e.name)).range([0, _.bandwidth()]).padding(.1), y = Math.max(0, ...u.series.flatMap((e) => e.values)), b = n().domain([0, y]).nice().range([g, 0]), x = t().domain(u.series.map((e) => e.name)).range(l), S = e(f).append("svg").attr("viewBox", `0 0 ${String(p)} ${String(m)}`).attr("width", p).attr("height", m), C = S.append("g").attr("transform", `translate(${String(c.left)}, ${String(c.top)})`);
21
+ n(f).selectAll("svg").remove();
22
+ let p = f.clientWidth || o, m = f.clientHeight || s, h = p - c.left - c.right, g = m - c.top - c.bottom, _ = t().domain(u.categories).range([0, h]).padding(.2), v = t().domain(u.series.map((e) => e.name)).range([0, _.bandwidth()]).padding(.1), y = Math.max(0, ...u.series.flatMap((e) => e.values)), b = e().domain([0, y]).nice().range([g, 0]), x = r().domain(u.series.map((e) => e.name)).range(l), S = n(f).append("svg").attr("viewBox", `0 0 ${String(p)} ${String(m)}`).attr("width", p).attr("height", m), C = S.append("g").attr("transform", `translate(${String(c.left)}, ${String(c.top)})`);
22
23
  C.append("g").attr("transform", `translate(0, ${String(g)})`).call(a(_)), C.append("g").call(i(b)), C.append("g").selectAll("rect").data(d(u)).join("rect").attr("x", (e) => (_(e.category) ?? 0) + (v(e.seriesName) ?? 0)).attr("y", (e) => b(e.value)).attr("width", v.bandwidth()).attr("height", (e) => g - b(e.value)).attr("fill", (e) => x(e.seriesName));
23
24
  let w = S.node();
24
25
  if (w == null) throw Error("Failed to create D3 bar chart SVG element.");
@@ -46,4 +47,4 @@ function d(e) {
46
47
  //#endregion
47
48
  export { u as renderD3BarChart };
48
49
 
49
- //# sourceMappingURL=d3BarChart-DEzayAyh.js.map
50
+ //# sourceMappingURL=d3BarChart-DIN2KQsU.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"d3BarChart-DEzayAyh.js","names":[],"sources":["../src/d3BarChart.ts"],"sourcesContent":["// ── External Dependencies & Registrations\nimport { select } from 'd3-selection';\nimport { axisBottom, axisLeft } from 'd3-axis';\nimport { scaleBand, scaleLinear, scaleOrdinal } from 'd3-scale';\n\n// ── Local\nimport type { BarChartData } from '@/billboardJs';\n\nexport type { BarChartData, BarChartSeries } from '@/billboardJs';\n\n// ── Types ────────────────────────────────────────────────────────────────────────────────────────────────────────────\n\nexport interface D3BarChartHandle {\n resize: () => void;\n svg: SVGSVGElement;\n}\n\ninterface D3BarChartRow {\n category: string;\n seriesName: string;\n value: number;\n}\n\n// ── Constants ────────────────────────────────────────────────────────────────────────────────────────────────────────\n\nconst DEFAULT_WIDTH = 640;\nconst DEFAULT_HEIGHT = 400;\nconst MARGIN = { bottom: 24, left: 40, right: 16, top: 16 };\nconst SERIES_COLORS = ['#6c8ebf', '#d79b00', '#82b366', '#9673a6', '#b85450'];\n\n// ── Actions ──────────────────────────────────────────────────────────────────────────────────────────────────────────\n\n// A grouped bar chart built from raw D3 primitives (d3-scale, d3-axis, d3-selection) - no chart wrapper library.\nexport function renderD3BarChart(data: BarChartData, renderTo: HTMLElement): D3BarChartHandle {\n function draw(): SVGSVGElement {\n select(renderTo).selectAll('svg').remove();\n\n const width = renderTo.clientWidth || DEFAULT_WIDTH;\n const height = renderTo.clientHeight || DEFAULT_HEIGHT;\n const innerWidth = width - MARGIN.left - MARGIN.right;\n const innerHeight = height - MARGIN.top - MARGIN.bottom;\n\n const categoryScale = scaleBand().domain(data.categories).range([0, innerWidth]).padding(0.2);\n const seriesScale = scaleBand()\n .domain(data.series.map((series) => series.name))\n .range([0, categoryScale.bandwidth()])\n .padding(0.1);\n const maxValue = Math.max(0, ...data.series.flatMap((series) => series.values));\n const valueScale = scaleLinear().domain([0, maxValue]).nice().range([innerHeight, 0]);\n const colorScale = scaleOrdinal<string, string>()\n .domain(data.series.map((series) => series.name))\n .range(SERIES_COLORS);\n\n const svgSelection = select(renderTo)\n .append('svg')\n .attr('viewBox', `0 0 ${String(width)} ${String(height)}`)\n .attr('width', width)\n .attr('height', height);\n\n const canvas = svgSelection.append('g').attr('transform', `translate(${String(MARGIN.left)}, ${String(MARGIN.top)})`);\n\n canvas\n .append('g')\n .attr('transform', `translate(0, ${String(innerHeight)})`)\n .call(axisBottom(categoryScale));\n canvas.append('g').call(axisLeft(valueScale));\n\n canvas\n .append('g')\n .selectAll('rect')\n .data(toBarRows(data))\n .join('rect')\n .attr('x', (row) => (categoryScale(row.category) ?? 0) + (seriesScale(row.seriesName) ?? 0))\n .attr('y', (row) => valueScale(row.value))\n .attr('width', seriesScale.bandwidth())\n .attr('height', (row) => innerHeight - valueScale(row.value))\n .attr('fill', (row) => colorScale(row.seriesName));\n\n const svgNode = svgSelection.node();\n if (svgNode == null) throw new Error('Failed to create D3 bar chart SVG element.');\n return svgNode;\n }\n\n let svg = draw();\n\n return {\n resize: () => {\n svg = draw();\n },\n get svg() {\n return svg;\n }\n };\n}\n\n// ── Helpers ──────────────────────────────────────────────────────────────────────────────────────────────────────────\n\nfunction toBarRows(data: BarChartData): D3BarChartRow[] {\n const rows: D3BarChartRow[] = [];\n for (const series of data.series) {\n for (const [index, category] of data.categories.entries()) {\n rows.push({ category, seriesName: series.name, value: series.values[index] ?? 0 });\n }\n }\n return rows;\n}\n"],"mappings":";;;;;AAyBA,IAAM,IAAgB,KAChB,IAAiB,KACjB,IAAS;CAAE,QAAQ;CAAI,MAAM;CAAI,OAAO;CAAI,KAAK;AAAG,GACpD,IAAgB;CAAC;CAAW;CAAW;CAAW;CAAW;AAAS;AAK5E,SAAgB,EAAiB,GAAoB,GAAyC;CAC1F,SAAS,IAAsB;EAC3B,EAAO,CAAQ,CAAC,CAAC,UAAU,KAAK,CAAC,CAAC,OAAO;EAEzC,IAAM,IAAQ,EAAS,eAAe,GAChC,IAAS,EAAS,gBAAgB,GAClC,IAAa,IAAQ,EAAO,OAAO,EAAO,OAC1C,IAAc,IAAS,EAAO,MAAM,EAAO,QAE3C,IAAgB,EAAU,CAAC,CAAC,OAAO,EAAK,UAAU,CAAC,CAAC,MAAM,CAAC,GAAG,CAAU,CAAC,CAAC,CAAC,QAAQ,EAAG,GACtF,IAAc,EAAU,CAAC,CAC1B,OAAO,EAAK,OAAO,KAAK,MAAW,EAAO,IAAI,CAAC,CAAC,CAChD,MAAM,CAAC,GAAG,EAAc,UAAU,CAAC,CAAC,CAAC,CACrC,QAAQ,EAAG,GACV,IAAW,KAAK,IAAI,GAAG,GAAG,EA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CAA4C;EACjF,OAAO;CACX;CAEA,IAAI,IAAM,EAAK;CAEf,OAAO;EACH,cAAc;GACV,IAAM,EAAK;EACf;EACA,IAAI,MAAM;GACN,OAAO;EACX;CACJ;AACJ;AAIA,SAAS,EAAU,GAAqC;CACpD,IAAM,IAAwB,CAAC;CAC/B,KAAK,IAAM,KAAU,EAAK,QACtB,KAAK,IAAM,CAAC,GAAO,MAAa,EAAK,WAAW,QAAQ,GACpD,EAAK,KAAK;EAAE;EAAU,YAAY,EAAO;EAAM,OAAO,EAAO,OAAO,MAAU;CAAE,CAAC;CAGzF,OAAO;AACX"}
1
+ {"version":3,"file":"d3BarChart-DIN2KQsU.js","names":[],"sources":["../src/d3BarChart.ts"],"sourcesContent":["// ── External Dependencies & Registrations\nimport { select } from 'd3-selection';\nimport { axisBottom, axisLeft } from 'd3-axis';\nimport { scaleBand, scaleLinear, scaleOrdinal } from 'd3-scale';\n\n// ── Local\nimport type { BarChartData } from '@/billboardJs';\n\nexport type { BarChartData, BarChartSeries } from '@/billboardJs';\n\n// ── Types ────────────────────────────────────────────────────────────────────────────────────────────────────────────\n\nexport interface D3BarChartHandle {\n resize: () => void;\n svg: SVGSVGElement;\n}\n\ninterface D3BarChartRow {\n category: string;\n seriesName: string;\n value: number;\n}\n\n// ── Constants ────────────────────────────────────────────────────────────────────────────────────────────────────────\n\nconst DEFAULT_WIDTH = 640;\nconst DEFAULT_HEIGHT = 400;\nconst MARGIN = { bottom: 24, left: 40, right: 16, top: 16 };\nconst SERIES_COLORS = ['#6c8ebf', '#d79b00', '#82b366', '#9673a6', '#b85450'];\n\n// ── Actions ──────────────────────────────────────────────────────────────────────────────────────────────────────────\n\n// A grouped bar chart built from raw D3 primitives (d3-scale, d3-axis, d3-selection) - no chart wrapper library.\nexport function renderD3BarChart(data: BarChartData, renderTo: HTMLElement): D3BarChartHandle {\n function draw(): SVGSVGElement {\n select(renderTo).selectAll('svg').remove();\n\n const width = renderTo.clientWidth || DEFAULT_WIDTH;\n const height = renderTo.clientHeight || DEFAULT_HEIGHT;\n const innerWidth = width - MARGIN.left - MARGIN.right;\n const innerHeight = height - MARGIN.top - MARGIN.bottom;\n\n const categoryScale = scaleBand().domain(data.categories).range([0, innerWidth]).padding(0.2);\n const seriesScale = scaleBand()\n .domain(data.series.map((series) => series.name))\n .range([0, categoryScale.bandwidth()])\n .padding(0.1);\n const maxValue = Math.max(0, ...data.series.flatMap((series) => series.values));\n const valueScale = scaleLinear().domain([0, maxValue]).nice().range([innerHeight, 0]);\n const colorScale = scaleOrdinal<string, string>()\n .domain(data.series.map((series) => series.name))\n .range(SERIES_COLORS);\n\n const svgSelection = select(renderTo)\n .append('svg')\n .attr('viewBox', `0 0 ${String(width)} ${String(height)}`)\n .attr('width', width)\n .attr('height', height);\n\n const canvas = svgSelection.append('g').attr('transform', `translate(${String(MARGIN.left)}, ${String(MARGIN.top)})`);\n\n canvas\n .append('g')\n .attr('transform', `translate(0, ${String(innerHeight)})`)\n .call(axisBottom(categoryScale));\n canvas.append('g').call(axisLeft(valueScale));\n\n canvas\n .append('g')\n .selectAll('rect')\n .data(toBarRows(data))\n .join('rect')\n .attr('x', (row) => (categoryScale(row.category) ?? 0) + (seriesScale(row.seriesName) ?? 0))\n .attr('y', (row) => valueScale(row.value))\n .attr('width', seriesScale.bandwidth())\n .attr('height', (row) => innerHeight - valueScale(row.value))\n .attr('fill', (row) => colorScale(row.seriesName));\n\n const svgNode = svgSelection.node();\n if (svgNode == null) throw new Error('Failed to create D3 bar chart SVG element.');\n return svgNode;\n }\n\n let svg = draw();\n\n return {\n resize: () => {\n svg = draw();\n },\n get svg() {\n return svg;\n }\n };\n}\n\n// ── Helpers ──────────────────────────────────────────────────────────────────────────────────────────────────────────\n\nfunction toBarRows(data: BarChartData): D3BarChartRow[] {\n const rows: D3BarChartRow[] = [];\n for (const series of data.series) {\n for (const [index, category] of data.categories.entries()) {\n rows.push({ category, seriesName: series.name, value: series.values[index] ?? 0 });\n }\n }\n return rows;\n}\n"],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"), i = r(e, t);
4
+ let { renderBillboardJS: r } = await import("./billboardJs-DS82ViEw.js"), i = r(e, t);
5
5
  return n?.(), {
6
6
  chart: i.chart,
7
7
  destroy: i.destroy,
@@ -10,7 +10,7 @@ var e = class {
10
10
  };
11
11
  }
12
12
  async renderObservablePlot(e, t, n, r) {
13
- let { renderObservablePlot: i } = await import("./observablePlot-B1CSEvcU.js"), a = i(e, t, n);
13
+ let { renderObservablePlot: i } = await import("./observablePlot-C7764aFq.js"), a = i(e, t, n);
14
14
  return r?.(), {
15
15
  resize: a.resize,
16
16
  get svg() {
@@ -20,7 +20,7 @@ var e = class {
20
20
  };
21
21
  }
22
22
  async renderD3BarChart(e, t, n) {
23
- let { renderD3BarChart: r } = await import("./d3BarChart-DEzayAyh.js"), i = r(e, t);
23
+ let { renderD3BarChart: r } = await import("./d3BarChart-DIN2KQsU.js"), i = r(e, t);
24
24
  return n?.(), {
25
25
  resize: i.resize,
26
26
  get svg() {
@@ -30,7 +30,7 @@ var e = class {
30
30
  };
31
31
  }
32
32
  async renderTanStackCharts(e, t, n) {
33
- let { renderTanStackCharts: r } = await import("./tanStackCharts-vvQteV9z.js"), i = r(e, t);
33
+ let { renderTanStackCharts: r } = await import("./tanStackCharts-BJAX22lS.js"), i = r(e, t);
34
34
  return n?.(), {
35
35
  destroy: i.destroy,
36
36
  resize: i.resize,
@@ -40,6 +40,16 @@ var e = class {
40
40
  vendorId: "tanstack-charts"
41
41
  };
42
42
  }
43
+ async renderChordDiagram(e, t, n, r) {
44
+ let { renderChordDiagram: i } = await import("./chordDiagram-Cz0sVVgD.js"), a = i(e, t, n);
45
+ return r?.(), {
46
+ resize: a.resize,
47
+ get svg() {
48
+ return a.svg;
49
+ },
50
+ vendorId: "unovis"
51
+ };
52
+ }
43
53
  async renderErdDiagram(e, t, n, r) {
44
54
  let { renderErdDiagram: i } = await import("./erdDiagram-Ds-nrw7Q.js"), a = i(e, t, n);
45
55
  return r?.(), {
@@ -51,7 +61,7 @@ var e = class {
51
61
  };
52
62
  }
53
63
  async renderNetworkDiagram(e, t, n, r) {
54
- let { renderNetworkDiagram: i } = await import("./networkDiagram-HS-SgOZ0.js"), a = i(e, t, n);
64
+ let { renderNetworkDiagram: i } = await import("./networkDiagram-yraPhqxN.js"), a = i(e, t, n);
55
65
  return r?.(), {
56
66
  destroy: a.destroy,
57
67
  resize: a.resize,
@@ -63,7 +73,7 @@ var e = class {
63
73
  };
64
74
  }
65
75
  async renderSankeyDiagram(e, t, n, r) {
66
- let { renderSankeyDiagram: i } = await import("./sankeyDiagram-BXTYCHPV.js"), a = i(e, t, n);
76
+ let { renderSankeyDiagram: i } = await import("./sankeyDiagram-BT2RCRpi.js"), a = i(e, t, n);
67
77
  return r?.(), {
68
78
  resize: a.resize,
69
79
  get svg() {
@@ -73,7 +83,7 @@ var e = class {
73
83
  };
74
84
  }
75
85
  async renderTreeDiagram(e, t, n, r) {
76
- let { renderTreeDiagram: i } = await import("./treeDiagram-DemHfVnX.js"), a = i(e, t, n);
86
+ let { renderTreeDiagram: i } = await import("./treeDiagram-DsHUD8ou.js"), a = i(e, t, n);
77
87
  return r?.(), {
78
88
  resize: a.resize,
79
89
  get svg() {
@@ -1 +1 @@
1
- {"version":3,"file":"dpuse-tool-d3-visualiser.es.js","names":[],"sources":["../src/index.ts"],"sourcesContent":["// ── External Dependencies & Registrations\nimport type { Chart } from 'billboard.js';\n\n// ── DPUse Framework\nimport type { PresentationView } from '@dpuse/dpuse-shared/component/presentation';\n\n// ── Local Framework\nimport type { BarChartData } from '@/billboardJs';\nimport type { ObservablePlotChartTypeId } from '@/observablePlot';\nimport type { ErdDiagramData, ErdDiagramOptions } from '@/erdDiagram';\nimport type { NetworkDiagramData, NetworkDiagramOptions } from '@/networkDiagram';\nimport type { SankeyDiagramData, SankeyDiagramOptions } from '@/sankeyDiagram';\nimport type { TreeDiagramNode, TreeDiagramOptions } from '@/treeDiagram';\n\n// ── Types ────────────────────────────────────────────────────────────────────────────────────────────────────────────\n\nexport type { BarChartData, BarChartSeries } from '@/billboardJs';\nexport type { ErdDiagramData, ErdDiagramEdge, ErdDiagramNode, ErdDiagramNodeTypeId, ErdDiagramOptions } from '@/erdDiagram';\nexport type { NetworkDiagramData, NetworkDiagramLink, NetworkDiagramNode, NetworkDiagramOptions } from '@/networkDiagram';\nexport type { ObservablePlotChartTypeId } from '@/observablePlot';\nexport type { SankeyDiagramData, SankeyDiagramLink, SankeyDiagramNode, SankeyDiagramOptions } from '@/sankeyDiagram';\nexport type { TreeDiagramNode, TreeDiagramNodeRoleId, TreeDiagramOptions } from '@/treeDiagram';\n\nexport interface D3View extends PresentationView {\n svg: SVGSVGElement;\n}\n\nexport interface D3NetworkView extends D3View {\n destroy: () => void;\n triggerAutoLayout: () => void;\n}\n\nexport interface D3BarChartView extends PresentationView {\n chart: Chart;\n destroy: () => void;\n}\n\nexport interface D3TanStackChartsView extends D3View {\n destroy: () => void;\n}\n\n// ── Constants ────────────────────────────────────────────────────────────────────────────────────────────────────────\n\nconst D3_ID = 'd3';\n\n// ── Tools ────────────────────────────────────────────────────────────────────────────────────────────────────────────\n\nexport class D3Tool {\n // Actions - Render chart (Billboard.js, SVG only - see the `billboard.js/canvas` entry point for canvas rendering, unused here).\n async renderBillboardJS(data: BarChartData, renderTo: HTMLElement, callback?: () => void): Promise<D3BarChartView> {\n const { renderBillboardJS } = await import('@/billboardJs');\n const handle = renderBillboardJS(data, renderTo);\n callback?.();\n return {\n chart: handle.chart,\n destroy: handle.destroy,\n resize: handle.resize,\n vendorId: 'billboard.js'\n };\n }\n\n // Actions - Render Observable Plot visualisation.\n async renderObservablePlot(typeId: ObservablePlotChartTypeId, data: BarChartData, renderTo: HTMLElement, callback?: () => void): Promise<D3View> {\n const { renderObservablePlot } = await import('@/observablePlot');\n const handle = renderObservablePlot(typeId, data, renderTo);\n callback?.();\n return {\n resize: handle.resize,\n get svg() {\n return handle.svg;\n },\n vendorId: 'observable-plot'\n };\n }\n\n // Actions - Render bar chart using raw D3 primitives (d3-scale, d3-axis - no chart wrapper library).\n async renderD3BarChart(data: BarChartData, renderTo: HTMLElement, callback?: () => void): Promise<D3View> {\n const { renderD3BarChart } = await import('@/d3BarChart');\n const handle = renderD3BarChart(data, renderTo);\n callback?.();\n return {\n resize: handle.resize,\n get svg() {\n return handle.svg;\n },\n vendorId: D3_ID\n };\n }\n\n // Actions - Render bar chart using TanStack Charts (pre-alpha as of 0.6.4 - its vanilla-DOM mountChart() API is undocumented and may change).\n async renderTanStackCharts(data: BarChartData, renderTo: HTMLElement, callback?: () => void): Promise<D3TanStackChartsView> {\n const { renderTanStackCharts } = await import('@/tanStackCharts');\n const handle = renderTanStackCharts(data, renderTo);\n callback?.();\n return {\n destroy: handle.destroy,\n resize: handle.resize,\n get svg() {\n return handle.svg;\n },\n vendorId: 'tanstack-charts'\n };\n }\n\n // Actions - Render ERD diagram.\n async renderErdDiagram(data: ErdDiagramData, renderTo: HTMLElement, options?: ErdDiagramOptions, callback?: () => void): Promise<D3View> {\n const { renderErdDiagram } = await import('@/erdDiagram');\n const handle = renderErdDiagram(data, renderTo, options);\n callback?.();\n return {\n resize: handle.resize,\n get svg() {\n return handle.svg;\n },\n vendorId: D3_ID\n };\n }\n\n // Actions - Render network diagram.\n async renderNetworkDiagram(data: NetworkDiagramData, renderTo: HTMLElement, options?: NetworkDiagramOptions, callback?: () => void): Promise<D3NetworkView> {\n const { renderNetworkDiagram } = await import('@/networkDiagram');\n const handle = renderNetworkDiagram(data, renderTo, options);\n callback?.();\n return {\n destroy: handle.destroy,\n resize: handle.resize,\n get svg() {\n return handle.svg;\n },\n triggerAutoLayout: handle.triggerAutoLayout,\n vendorId: D3_ID\n };\n }\n\n // Actions - Render Sankey diagram.\n async renderSankeyDiagram(data: SankeyDiagramData, renderTo: HTMLElement, options?: SankeyDiagramOptions, callback?: () => void): Promise<D3View> {\n const { renderSankeyDiagram } = await import('@/sankeyDiagram');\n const handle = renderSankeyDiagram(data, renderTo, options);\n callback?.();\n return {\n resize: handle.resize,\n get svg() {\n return handle.svg;\n },\n vendorId: D3_ID\n };\n }\n\n // Actions - Render tree diagram.\n async renderTreeDiagram(data: TreeDiagramNode, renderTo: HTMLElement, options?: TreeDiagramOptions, callback?: () => void): Promise<D3View> {\n const { renderTreeDiagram } = await import('@/treeDiagram');\n const handle = renderTreeDiagram(data, renderTo, options);\n callback?.();\n return {\n resize: handle.resize,\n get svg() {\n return handle.svg;\n },\n vendorId: D3_ID\n };\n }\n}\n"],"mappings":";AA2CA,IAIa,IAAb,MAAoB;CAEhB,MAAM,kBAAkB,GAAoB,GAAuB,GAAgD;EAC/G,IAAM,EAAE,yBAAsB,MAAM,OAAO,8BACrC,IAAS,EAAkB,GAAM,CAAQ;EAE/C,OADA,IAAW,GACJ;GACH,OAAO,EAAO;GACd,SAAS,EAAO;GAChB,QAAQ,EAAO;GACf,UAAU;EACd;CACJ;CAGA,MAAM,qBAAqB,GAAmC,GAAoB,GAAuB,GAAwC;EAC7I,IAAM,EAAE,4BAAyB,MAAM,OAAO,iCACxC,IAAS,EAAqB,GAAQ,GAAM,CAAQ;EAE1D,OADA,IAAW,GACJ;GACH,QAAQ,EAAO;GACf,IAAI,MAAM;IACN,OAAO,EAAO;GAClB;GACA,UAAU;EACd;CACJ;CAGA,MAAM,iBAAiB,GAAoB,GAAuB,GAAwC;EACtG,IAAM,EAAE,wBAAqB,MAAM,OAAO,6BACpC,IAAS,EAAiB,GAAM,CAAQ;EAE9C,OADA,IAAW,GACJ;GACH,QAAQ,EAAO;GACf,IAAI,MAAM;IACN,OAAO,EAAO;GAClB;GACA,UAAU;EACd;CACJ;CAGA,MAAM,qBAAqB,GAAoB,GAAuB,GAAsD;EACxH,IAAM,EAAE,4BAAyB,MAAM,OAAO,iCACxC,IAAS,EAAqB,GAAM,CAAQ;EAElD,OADA,IAAW,GACJ;GACH,SAAS,EAAO;GAChB,QAAQ,EAAO;GACf,IAAI,MAAM;IACN,OAAO,EAAO;GAClB;GACA,UAAU;EACd;CACJ;CAGA,MAAM,iBAAiB,GAAsB,GAAuB,GAA6B,GAAwC;EACrI,IAAM,EAAE,wBAAqB,MAAM,OAAO,6BACpC,IAAS,EAAiB,GAAM,GAAU,CAAO;EAEvD,OADA,IAAW,GACJ;GACH,QAAQ,EAAO;GACf,IAAI,MAAM;IACN,OAAO,EAAO;GAClB;GACA,UAAU;EACd;CACJ;CAGA,MAAM,qBAAqB,GAA0B,GAAuB,GAAiC,GAA+C;EACxJ,IAAM,EAAE,4BAAyB,MAAM,OAAO,iCACxC,IAAS,EAAqB,GAAM,GAAU,CAAO;EAE3D,OADA,IAAW,GACJ;GACH,SAAS,EAAO;GAChB,QAAQ,EAAO;GACf,IAAI,MAAM;IACN,OAAO,EAAO;GAClB;GACA,mBAAmB,EAAO;GAC1B,UAAU;EACd;CACJ;CAGA,MAAM,oBAAoB,GAAyB,GAAuB,GAAgC,GAAwC;EAC9I,IAAM,EAAE,2BAAwB,MAAM,OAAO,gCACvC,IAAS,EAAoB,GAAM,GAAU,CAAO;EAE1D,OADA,IAAW,GACJ;GACH,QAAQ,EAAO;GACf,IAAI,MAAM;IACN,OAAO,EAAO;GAClB;GACA,UAAU;EACd;CACJ;CAGA,MAAM,kBAAkB,GAAuB,GAAuB,GAA8B,GAAwC;EACxI,IAAM,EAAE,yBAAsB,MAAM,OAAO,8BACrC,IAAS,EAAkB,GAAM,GAAU,CAAO;EAExD,OADA,IAAW,GACJ;GACH,QAAQ,EAAO;GACf,IAAI,MAAM;IACN,OAAO,EAAO;GAClB;GACA,UAAU;EACd;CACJ;AACJ"}
1
+ {"version":3,"file":"dpuse-tool-d3-visualiser.es.js","names":[],"sources":["../src/index.ts"],"sourcesContent":["// TODO: See https://d3-graph-gallery.com/index.html.\n\n// ── External Dependencies & Registrations\nimport type { Chart } from 'billboard.js';\n\n// ── DPUse Framework\nimport type { PresentationView } from '@dpuse/dpuse-shared/component/presentation';\n\n// ── Local Framework\nimport type { BarChartData } from '@/billboardJs';\nimport type { ObservablePlotChartTypeId } from '@/observablePlot';\nimport type { ChordDiagramData, ChordDiagramOptions } from '@/chordDiagram';\nimport type { ErdDiagramData, ErdDiagramOptions } from '@/erdDiagram';\nimport type { NetworkDiagramData, NetworkDiagramOptions } from '@/networkDiagram';\nimport type { SankeyDiagramData, SankeyDiagramOptions } from '@/sankeyDiagram';\nimport type { TreeDiagramNode, TreeDiagramOptions } from '@/treeDiagram';\n\n// ── Types ────────────────────────────────────────────────────────────────────────────────────────────────────────────\n\nexport type { BarChartData, BarChartSeries } from '@/billboardJs';\nexport type { ChordDiagramData, ChordDiagramLink, ChordDiagramNode, ChordDiagramOptions } from '@/chordDiagram';\nexport type { ErdDiagramData, ErdDiagramEdge, ErdDiagramNode, ErdDiagramNodeTypeId, ErdDiagramOptions } from '@/erdDiagram';\nexport type { NetworkDiagramData, NetworkDiagramLink, NetworkDiagramNode, NetworkDiagramOptions } from '@/networkDiagram';\nexport type { ObservablePlotChartTypeId } from '@/observablePlot';\nexport type { SankeyDiagramData, SankeyDiagramLink, SankeyDiagramNode, SankeyDiagramOptions } from '@/sankeyDiagram';\nexport type { TreeDiagramNode, TreeDiagramNodeRoleId, TreeDiagramOptions } from '@/treeDiagram';\n\nexport interface D3View extends PresentationView {\n svg: SVGSVGElement;\n}\n\nexport interface D3NetworkView extends D3View {\n destroy: () => void;\n triggerAutoLayout: () => void;\n}\n\nexport interface D3BarChartView extends PresentationView {\n chart: Chart;\n destroy: () => void;\n}\n\nexport interface D3TanStackChartsView extends D3View {\n destroy: () => void;\n}\n\n// ── Constants ────────────────────────────────────────────────────────────────────────────────────────────────────────\n\nconst D3_ID = 'd3';\n\n// ── Tools ────────────────────────────────────────────────────────────────────────────────────────────────────────────\n\nexport class D3Tool {\n // Actions - Render chart (Billboard.js, SVG only - see the `billboard.js/canvas` entry point for canvas rendering, unused here).\n async renderBillboardJS(data: BarChartData, renderTo: HTMLElement, callback?: () => void): Promise<D3BarChartView> {\n const { renderBillboardJS } = await import('@/billboardJs');\n const handle = renderBillboardJS(data, renderTo);\n callback?.();\n return {\n chart: handle.chart,\n destroy: handle.destroy,\n resize: handle.resize,\n vendorId: 'billboard.js'\n };\n }\n\n // Actions - Render Observable Plot visualisation.\n async renderObservablePlot(typeId: ObservablePlotChartTypeId, data: BarChartData, renderTo: HTMLElement, callback?: () => void): Promise<D3View> {\n const { renderObservablePlot } = await import('@/observablePlot');\n const handle = renderObservablePlot(typeId, data, renderTo);\n callback?.();\n return {\n resize: handle.resize,\n get svg() {\n return handle.svg;\n },\n vendorId: 'observable-plot'\n };\n }\n\n // Actions - Render bar chart using raw D3 primitives (d3-scale, d3-axis - no chart wrapper library).\n async renderD3BarChart(data: BarChartData, renderTo: HTMLElement, callback?: () => void): Promise<D3View> {\n const { renderD3BarChart } = await import('@/d3BarChart');\n const handle = renderD3BarChart(data, renderTo);\n callback?.();\n return {\n resize: handle.resize,\n get svg() {\n return handle.svg;\n },\n vendorId: D3_ID\n };\n }\n\n // Actions - Render bar chart using TanStack Charts (pre-alpha as of 0.6.4 - its vanilla-DOM mountChart() API is undocumented and may change).\n async renderTanStackCharts(data: BarChartData, renderTo: HTMLElement, callback?: () => void): Promise<D3TanStackChartsView> {\n const { renderTanStackCharts } = await import('@/tanStackCharts');\n const handle = renderTanStackCharts(data, renderTo);\n callback?.();\n return {\n destroy: handle.destroy,\n resize: handle.resize,\n get svg() {\n return handle.svg;\n },\n vendorId: 'tanstack-charts'\n };\n }\n\n // Actions - Render chord diagram (Unovis).\n async renderChordDiagram(data: ChordDiagramData, renderTo: HTMLElement, options?: ChordDiagramOptions, callback?: () => void): Promise<D3View> {\n const { renderChordDiagram } = await import('@/chordDiagram');\n const handle = renderChordDiagram(data, renderTo, options);\n callback?.();\n return {\n resize: handle.resize,\n get svg() {\n return handle.svg;\n },\n vendorId: 'unovis'\n };\n }\n\n // Actions - Render ERD diagram.\n async renderErdDiagram(data: ErdDiagramData, renderTo: HTMLElement, options?: ErdDiagramOptions, callback?: () => void): Promise<D3View> {\n const { renderErdDiagram } = await import('@/erdDiagram');\n const handle = renderErdDiagram(data, renderTo, options);\n callback?.();\n return {\n resize: handle.resize,\n get svg() {\n return handle.svg;\n },\n vendorId: D3_ID\n };\n }\n\n // Actions - Render network diagram.\n async renderNetworkDiagram(data: NetworkDiagramData, renderTo: HTMLElement, options?: NetworkDiagramOptions, callback?: () => void): Promise<D3NetworkView> {\n const { renderNetworkDiagram } = await import('@/networkDiagram');\n const handle = renderNetworkDiagram(data, renderTo, options);\n callback?.();\n return {\n destroy: handle.destroy,\n resize: handle.resize,\n get svg() {\n return handle.svg;\n },\n triggerAutoLayout: handle.triggerAutoLayout,\n vendorId: D3_ID\n };\n }\n\n // Actions - Render Sankey diagram.\n async renderSankeyDiagram(data: SankeyDiagramData, renderTo: HTMLElement, options?: SankeyDiagramOptions, callback?: () => void): Promise<D3View> {\n const { renderSankeyDiagram } = await import('@/sankeyDiagram');\n const handle = renderSankeyDiagram(data, renderTo, options);\n callback?.();\n return {\n resize: handle.resize,\n get svg() {\n return handle.svg;\n },\n vendorId: D3_ID\n };\n }\n\n // Actions - Render tree diagram.\n async renderTreeDiagram(data: TreeDiagramNode, renderTo: HTMLElement, options?: TreeDiagramOptions, callback?: () => void): Promise<D3View> {\n const { renderTreeDiagram } = await import('@/treeDiagram');\n const handle = renderTreeDiagram(data, renderTo, options);\n callback?.();\n return {\n resize: handle.resize,\n get svg() {\n return handle.svg;\n },\n vendorId: D3_ID\n };\n }\n}\n"],"mappings":";AA+CA,IAIa,IAAb,MAAoB;CAEhB,MAAM,kBAAkB,GAAoB,GAAuB,GAAgD;EAC/G,IAAM,EAAE,yBAAsB,MAAM,OAAO,8BACrC,IAAS,EAAkB,GAAM,CAAQ;EAE/C,OADA,IAAW,GACJ;GACH,OAAO,EAAO;GACd,SAAS,EAAO;GAChB,QAAQ,EAAO;GACf,UAAU;EACd;CACJ;CAGA,MAAM,qBAAqB,GAAmC,GAAoB,GAAuB,GAAwC;EAC7I,IAAM,EAAE,4BAAyB,MAAM,OA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ChB,QAAQ,EAAO;GACf,IAAI,MAAM;IACN,OAAO,EAAO;GAClB;GACA,mBAAmB,EAAO;GAC1B,UAAU;EACd;CACJ;CAGA,MAAM,oBAAoB,GAAyB,GAAuB,GAAgC,GAAwC;EAC9I,IAAM,EAAE,2BAAwB,MAAM,OAAO,gCACvC,IAAS,EAAoB,GAAM,GAAU,CAAO;EAE1D,OADA,IAAW,GACJ;GACH,QAAQ,EAAO;GACf,IAAI,MAAM;IACN,OAAO,EAAO;GAClB;GACA,UAAU;EACd;CACJ;CAGA,MAAM,kBAAkB,GAAuB,GAAuB,GAA8B,GAAwC;EACxI,IAAM,EAAE,yBAAsB,MAAM,OAAO,8BACrC,IAAS,EAAkB,GAAM,GAAU,CAAO;EAExD,OADA,IAAW,GACJ;GACH,QAAQ,EAAO;GACf,IAAI,MAAM;IACN,OAAO,EAAO;GAClB;GACA,UAAU;EACd;CACJ;AACJ"}
@@ -1,5 +1,6 @@
1
- import { t as e } from "./select-BIuoFcZG.js";
2
- import { a as t, c as n, d as r, i, l as a, o, s, u as c } from "./src-Du_hPZAX.js";
1
+ import { i as e } from "./src-yL3ZdoR1.js";
2
+ import { t } from "./select-BIuoFcZG.js";
3
+ import { a as n, i as r, n as i, o as a, r as o, s, t as c } from "./nodrag-Dq2tlBbe.js";
3
4
  //#region node_modules/d3-drag/src/constant.js
4
5
  var l = (e) => () => e;
5
6
  //#endregion
@@ -81,14 +82,14 @@ function m() {
81
82
  return navigator.maxTouchPoints || "ontouchstart" in this;
82
83
  }
83
84
  function h() {
84
- var h = d, g = f, _ = p, v = m, y = {}, b = c("start", "drag", "end"), x = 0, S, C, w, T, E = 0;
85
+ var h = d, g = f, _ = p, v = m, y = {}, b = e("start", "drag", "end"), x = 0, S, C, w, T, E = 0;
85
86
  function D(e) {
86
- e.on("mousedown.drag", O).filter(v).on("touchstart.drag", j).on("touchmove.drag", M, s).on("touchend.drag touchcancel.drag", N).style("touch-action", "none").style("-webkit-tap-highlight-color", "rgba(0,0,0,0)");
87
+ e.on("mousedown.drag", O).filter(v).on("touchstart.drag", j).on("touchmove.drag", M, r).on("touchend.drag touchcancel.drag", N).style("touch-action", "none").style("-webkit-tap-highlight-color", "rgba(0,0,0,0)");
87
88
  }
88
- function O(t, r) {
89
- if (!(T || !h.call(this, t, r))) {
90
- var o = P(this, g.call(this, t, r), t, r, "mouse");
91
- o && (e(t.view).on("mousemove.drag", k, n).on("mouseup.drag", A, n), i(t.view), a(t), w = !1, S = t.clientX, C = t.clientY, o("start", t));
89
+ function O(e, r) {
90
+ if (!(T || !h.call(this, e, r))) {
91
+ var i = P(this, g.call(this, e, r), e, r, "mouse");
92
+ i && (t(e.view).on("mousemove.drag", k, n).on("mouseup.drag", A, n), c(e.view), a(e), w = !1, S = e.clientX, C = e.clientY, i("start", e));
92
93
  }
93
94
  }
94
95
  function k(e) {
@@ -98,8 +99,8 @@ function h() {
98
99
  }
99
100
  y.mouse("drag", e);
100
101
  }
101
- function A(n) {
102
- e(n.view).on("mousemove.drag mouseup.drag", null), t(n.view, w), o(n), y.mouse("end", n);
102
+ function A(e) {
103
+ t(e.view).on("mousemove.drag mouseup.drag", null), i(e.view, w), o(e), y.mouse("end", e);
103
104
  }
104
105
  function j(e, t) {
105
106
  if (h.call(this, e, t)) {
@@ -117,39 +118,39 @@ function h() {
117
118
  T = null;
118
119
  }, 500), r = 0; r < n; ++r) (i = y[t[r].identifier]) && (a(e), i("end", e, t[r]));
119
120
  }
120
- function P(e, t, n, i, a, o) {
121
- var s = b.copy(), c = r(o || n, t), l, d, f;
121
+ function P(e, t, n, r, i, a) {
122
+ var o = b.copy(), c = s(a || n, t), l, d, f;
122
123
  if ((f = _.call(e, new u("beforestart", {
123
124
  sourceEvent: n,
124
125
  target: D,
125
- identifier: a,
126
+ identifier: i,
126
127
  active: x,
127
128
  x: c[0],
128
129
  y: c[1],
129
130
  dx: 0,
130
131
  dy: 0,
131
- dispatch: s
132
- }), i)) != null) return l = f.x - c[0] || 0, d = f.y - c[1] || 0, function n(o, p, m) {
132
+ dispatch: o
133
+ }), r)) != null) return l = f.x - c[0] || 0, d = f.y - c[1] || 0, function n(a, p, m) {
133
134
  var h = c, g;
134
- switch (o) {
135
+ switch (a) {
135
136
  case "start":
136
- y[a] = n, g = x++;
137
+ y[i] = n, g = x++;
137
138
  break;
138
- case "end": delete y[a], --x;
139
- case "drag": c = r(m || p, t), g = x;
139
+ case "end": delete y[i], --x;
140
+ case "drag": c = s(m || p, t), g = x;
140
141
  }
141
- s.call(o, e, new u(o, {
142
+ o.call(a, e, new u(a, {
142
143
  sourceEvent: p,
143
144
  subject: f,
144
145
  target: D,
145
- identifier: a,
146
+ identifier: i,
146
147
  active: g,
147
148
  x: c[0] + l,
148
149
  y: c[1] + d,
149
150
  dx: c[0] - h[0],
150
151
  dy: c[1] - h[1],
151
- dispatch: s
152
- }), i);
152
+ dispatch: o
153
+ }), r);
153
154
  };
154
155
  }
155
156
  return D.filter = function(e) {
@@ -170,4 +171,4 @@ function h() {
170
171
  //#endregion
171
172
  export { h as t };
172
173
 
173
- //# sourceMappingURL=drag-DLokvdmv.js.map
174
+ //# sourceMappingURL=drag-DfL4uwqz.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"drag-DLokvdmv.js","names":["pointer","constant"],"sources":["../node_modules/d3-drag/src/constant.js","../node_modules/d3-drag/src/event.js","../node_modules/d3-drag/src/drag.js"],"sourcesContent":["export default x => () => x;\n","export default function DragEvent(type, {\n sourceEvent,\n subject,\n target,\n identifier,\n active,\n x, y, dx, dy,\n dispatch\n}) {\n Object.defineProperties(this, {\n type: {value: type, enumerable: true, configurable: true},\n sourceEvent: {value: sourceEvent, enumerable: true, configurable: true},\n subject: {value: subject, enumerable: true, configurable: true},\n target: {value: target, enumerable: true, configurable: true},\n identifier: {value: identifier, enumerable: true, configurable: true},\n active: {value: active, enumerable: true, configurable: true},\n x: {value: x, enumerable: true, configurable: true},\n y: {value: y, enumerable: true, configurable: true},\n dx: {value: dx, enumerable: true, configurable: true},\n dy: {value: dy, enumerable: true, configurable: true},\n _: {value: dispatch}\n });\n}\n\nDragEvent.prototype.on = function() {\n var value = this._.on.apply(this._, arguments);\n return value === this._ ? this : value;\n};\n","import {dispatch} from \"d3-dispatch\";\nimport {select, pointer} from \"d3-selection\";\nimport nodrag, {yesdrag} from \"./nodrag.js\";\nimport noevent, {nonpassive, nonpassivecapture, nopropagation} from \"./noevent.js\";\nimport constant from \"./constant.js\";\nimport DragEvent from \"./event.js\";\n\n// Ignore right-click, since that should open the context menu.\nfunction defaultFilter(event) {\n return !event.ctrlKey && !event.button;\n}\n\nfunction defaultContainer() {\n return this.parentNode;\n}\n\nfunction defaultSubject(event, d) {\n return d == null ? {x: event.x, y: event.y} : d;\n}\n\nfunction defaultTouchable() {\n return navigator.maxTouchPoints || (\"ontouchstart\" in this);\n}\n\nexport default function() {\n var filter = defaultFilter,\n container = defaultContainer,\n subject = defaultSubject,\n touchable = defaultTouchable,\n gestures = {},\n listeners = dispatch(\"start\", \"drag\", \"end\"),\n active = 0,\n mousedownx,\n mousedowny,\n mousemoving,\n touchending,\n clickDistance2 = 0;\n\n function drag(selection) {\n selection\n .on(\"mousedown.drag\", mousedowned)\n .filter(touchable)\n .on(\"touchstart.drag\", touchstarted)\n .on(\"touchmove.drag\", touchmoved, nonpassive)\n .on(\"touchend.drag touchcancel.drag\", touchended)\n .style(\"touch-action\", \"none\")\n .style(\"-webkit-tap-highlight-color\", \"rgba(0,0,0,0)\");\n }\n\n function mousedowned(event, d) {\n if (touchending || !filter.call(this, event, d)) return;\n var gesture = beforestart(this, container.call(this, event, d), event, d, \"mouse\");\n if (!gesture) return;\n select(event.view)\n .on(\"mousemove.drag\", mousemoved, nonpassivecapture)\n .on(\"mouseup.drag\", mouseupped, nonpassivecapture);\n nodrag(event.view);\n nopropagation(event);\n mousemoving = false;\n mousedownx = event.clientX;\n mousedowny = event.clientY;\n gesture(\"start\", event);\n }\n\n function mousemoved(event) {\n noevent(event);\n if (!mousemoving) {\n var dx = event.clientX - mousedownx, dy = event.clientY - mousedowny;\n mousemoving = dx * dx + dy * dy > clickDistance2;\n }\n gestures.mouse(\"drag\", event);\n }\n\n function mouseupped(event) {\n select(event.view).on(\"mousemove.drag mouseup.drag\", null);\n yesdrag(event.view, mousemoving);\n noevent(event);\n gestures.mouse(\"end\", event);\n }\n\n function touchstarted(event, d) {\n if (!filter.call(this, event, d)) return;\n var touches = event.changedTouches,\n c = container.call(this, event, d),\n n = touches.length, i, gesture;\n\n for (i = 0; i < n; ++i) {\n if (gesture = beforestart(this, c, event, d, touches[i].identifier, touches[i])) {\n nopropagation(event);\n gesture(\"start\", event, touches[i]);\n }\n }\n }\n\n function touchmoved(event) {\n var touches = event.changedTouches,\n n = touches.length, i, gesture;\n\n for (i = 0; i < n; ++i) {\n if (gesture = gestures[touches[i].identifier]) {\n noevent(event);\n gesture(\"drag\", event, touches[i]);\n }\n }\n }\n\n function touchended(event) {\n var touches = event.changedTouches,\n n = touches.length, i, gesture;\n\n if (touchending) clearTimeout(touchending);\n touchending = setTimeout(function() { touchending = null; }, 500); // Ghost clicks are delayed!\n for (i = 0; i < n; ++i) {\n if (gesture = gestures[touches[i].identifier]) {\n nopropagation(event);\n gesture(\"end\", event, touches[i]);\n }\n }\n }\n\n function beforestart(that, container, event, d, identifier, touch) {\n var dispatch = listeners.copy(),\n p = pointer(touch || event, container), dx, dy,\n s;\n\n if ((s = subject.call(that, new DragEvent(\"beforestart\", {\n sourceEvent: event,\n target: drag,\n identifier,\n active,\n x: p[0],\n y: p[1],\n dx: 0,\n dy: 0,\n dispatch\n }), d)) == null) return;\n\n dx = s.x - p[0] || 0;\n dy = s.y - p[1] || 0;\n\n return function gesture(type, event, touch) {\n var p0 = p, n;\n switch (type) {\n case \"start\": gestures[identifier] = gesture, n = active++; break;\n case \"end\": delete gestures[identifier], --active; // falls through\n case \"drag\": p = pointer(touch || event, container), n = active; break;\n }\n dispatch.call(\n type,\n that,\n new DragEvent(type, {\n sourceEvent: event,\n subject: s,\n target: drag,\n identifier,\n active: n,\n x: p[0] + dx,\n y: p[1] + dy,\n dx: p[0] - p0[0],\n dy: p[1] - p0[1],\n dispatch\n }),\n d\n );\n };\n }\n\n drag.filter = function(_) {\n return arguments.length ? (filter = typeof _ === \"function\" ? _ : constant(!!_), drag) : filter;\n };\n\n drag.container = function(_) {\n return arguments.length ? (container = typeof _ === \"function\" ? _ : constant(_), drag) : container;\n };\n\n drag.subject = function(_) {\n return arguments.length ? (subject = typeof _ === \"function\" ? _ : constant(_), drag) : subject;\n };\n\n drag.touchable = function(_) {\n return arguments.length ? (touchable = typeof _ === \"function\" ? _ : constant(!!_), drag) : touchable;\n };\n\n drag.on = function() {\n var value = listeners.on.apply(listeners, arguments);\n return value === listeners ? drag : value;\n };\n\n drag.clickDistance = function(_) {\n return arguments.length ? (clickDistance2 = (_ = +_) * _, drag) : Math.sqrt(clickDistance2);\n };\n\n return drag;\n}\n"],"x_google_ignoreList":[0,1,2],"mappings":";;;AAAA,IAAA,KAAe,YAAW;;;ACA1B,SAAwB,EAAU,GAAM,EACtC,gBACA,YACA,WACA,eACA,WACA,MAAG,MAAG,OAAI,OACV,eACC;CACD,OAAO,iBAAiB,MAAM;EAC5B,MAAM;GAAC,OAAO;GAAM,YAAY;GAAM,cAAc;EAAI;EACxD,aAAa;GAAC,OAAO;GAAa,YAAY;GAAM,cAAc;EAAI;EACtE,SAAS;GAAC,OAAO;GAAS,YAAY;GAAM,cAAc;EAAI;EAC9D,QAAQ;GAAC,OAAO;GAAQ,YAAY;GAAM,cAAc;EAAI;EAC5D,YAAY;GAAC,OAAO;GAAY,YAAY;GAAM,cAAc;EAAI;EACpE,QAAQ;GAAC,OAAO;GAAQ,YAAY;GAAM,cAAc;EAAI;EAC5D,GAAG;GAAC,OAAO;GAAG,YAAY;GAAM,cAAc;EAAI;EAClD,GAAG;GAAC,OAAO;GAAG,YAAY;GAAM,cAAc;EAAI;EAClD,IAAI;GAAC,OAAO;GAAI,YAAY;GAAM,cAA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AC3B,OAAO,UAAU,UAAU,IAAY,OAAO,KAAM,aAAa,IAAIA,EAAS,CAAC,GAAG,KAAQ;CAC5F,GAEA,EAAK,UAAU,SAAS,GAAG;EACzB,OAAO,UAAU,UAAU,IAAU,OAAO,KAAM,aAAa,IAAIA,EAAS,CAAC,GAAG,KAAQ;CAC1F,GAEA,EAAK,YAAY,SAAS,GAAG;EAC3B,OAAO,UAAU,UAAU,IAAY,OAAO,KAAM,aAAa,IAAIA,EAAS,CAAC,CAAC,CAAC,GAAG,KAAQ;CAC9F,GAEA,EAAK,KAAK,WAAW;EACnB,IAAI,IAAQ,EAAU,GAAG,MAAM,GAAW,SAAS;EACnD,OAAO,MAAU,IAAY,IAAO;CACtC,GAEA,EAAK,gBAAgB,SAAS,GAAG;EAC/B,OAAO,UAAU,UAAU,KAAkB,IAAI,CAAC,KAAK,GAAG,KAAQ,KAAK,KAAK,CAAc;CAC5F,GAEO;AACT"}
1
+ {"version":3,"file":"drag-DfL4uwqz.js","names":["pointer","constant"],"sources":["../node_modules/d3-drag/src/constant.js","../node_modules/d3-drag/src/event.js","../node_modules/d3-drag/src/drag.js"],"sourcesContent":["export default x => () => x;\n","export default function DragEvent(type, {\n sourceEvent,\n subject,\n target,\n identifier,\n active,\n x, y, dx, dy,\n dispatch\n}) {\n Object.defineProperties(this, {\n type: {value: type, enumerable: true, configurable: true},\n sourceEvent: {value: sourceEvent, enumerable: true, configurable: true},\n subject: {value: subject, enumerable: true, configurable: true},\n target: {value: target, enumerable: true, configurable: true},\n identifier: {value: identifier, enumerable: true, configurable: true},\n active: {value: active, enumerable: true, configurable: true},\n x: {value: x, enumerable: true, configurable: true},\n y: {value: y, enumerable: true, configurable: true},\n dx: {value: dx, enumerable: true, configurable: true},\n dy: {value: dy, enumerable: true, configurable: true},\n _: {value: dispatch}\n });\n}\n\nDragEvent.prototype.on = function() {\n var value = this._.on.apply(this._, arguments);\n return value === this._ ? this : value;\n};\n","import {dispatch} from \"d3-dispatch\";\nimport {select, pointer} from \"d3-selection\";\nimport nodrag, {yesdrag} from \"./nodrag.js\";\nimport noevent, {nonpassive, nonpassivecapture, nopropagation} from \"./noevent.js\";\nimport constant from \"./constant.js\";\nimport DragEvent from \"./event.js\";\n\n// Ignore right-click, since that should open the context menu.\nfunction defaultFilter(event) {\n return !event.ctrlKey && !event.button;\n}\n\nfunction defaultContainer() {\n return this.parentNode;\n}\n\nfunction defaultSubject(event, d) {\n return d == null ? {x: event.x, y: event.y} : d;\n}\n\nfunction defaultTouchable() {\n return navigator.maxTouchPoints || (\"ontouchstart\" in this);\n}\n\nexport default function() {\n var filter = defaultFilter,\n container = defaultContainer,\n subject = defaultSubject,\n touchable = defaultTouchable,\n gestures = {},\n listeners = dispatch(\"start\", \"drag\", \"end\"),\n active = 0,\n mousedownx,\n mousedowny,\n mousemoving,\n touchending,\n clickDistance2 = 0;\n\n function drag(selection) {\n selection\n .on(\"mousedown.drag\", mousedowned)\n .filter(touchable)\n .on(\"touchstart.drag\", touchstarted)\n .on(\"touchmove.drag\", touchmoved, nonpassive)\n .on(\"touchend.drag touchcancel.drag\", touchended)\n .style(\"touch-action\", \"none\")\n .style(\"-webkit-tap-highlight-color\", \"rgba(0,0,0,0)\");\n }\n\n function mousedowned(event, d) {\n if (touchending || !filter.call(this, event, d)) return;\n var gesture = beforestart(this, container.call(this, event, d), event, d, \"mouse\");\n if (!gesture) return;\n select(event.view)\n .on(\"mousemove.drag\", mousemoved, nonpassivecapture)\n .on(\"mouseup.drag\", mouseupped, nonpassivecapture);\n nodrag(event.view);\n nopropagation(event);\n mousemoving = false;\n mousedownx = event.clientX;\n mousedowny = event.clientY;\n gesture(\"start\", event);\n }\n\n function mousemoved(event) {\n noevent(event);\n if (!mousemoving) {\n var dx = event.clientX - mousedownx, dy = event.clientY - mousedowny;\n mousemoving = dx * dx + dy * dy > clickDistance2;\n }\n gestures.mouse(\"drag\", event);\n }\n\n function mouseupped(event) {\n select(event.view).on(\"mousemove.drag mouseup.drag\", null);\n yesdrag(event.view, mousemoving);\n noevent(event);\n gestures.mouse(\"end\", event);\n }\n\n function touchstarted(event, d) {\n if (!filter.call(this, event, d)) return;\n var touches = event.changedTouches,\n c = container.call(this, event, d),\n n = touches.length, i, gesture;\n\n for (i = 0; i < n; ++i) {\n if (gesture = beforestart(this, c, event, d, touches[i].identifier, touches[i])) {\n nopropagation(event);\n gesture(\"start\", event, touches[i]);\n }\n }\n }\n\n function touchmoved(event) {\n var touches = event.changedTouches,\n n = touches.length, i, gesture;\n\n for (i = 0; i < n; ++i) {\n if (gesture = gestures[touches[i].identifier]) {\n noevent(event);\n gesture(\"drag\", event, touches[i]);\n }\n }\n }\n\n function touchended(event) {\n var touches = event.changedTouches,\n n = touches.length, i, gesture;\n\n if (touchending) clearTimeout(touchending);\n touchending = setTimeout(function() { touchending = null; }, 500); // Ghost clicks are delayed!\n for (i = 0; i < n; ++i) {\n if (gesture = gestures[touches[i].identifier]) {\n nopropagation(event);\n gesture(\"end\", event, touches[i]);\n }\n }\n }\n\n function beforestart(that, container, event, d, identifier, touch) {\n var dispatch = listeners.copy(),\n p = pointer(touch || event, container), dx, dy,\n s;\n\n if ((s = subject.call(that, new DragEvent(\"beforestart\", {\n sourceEvent: event,\n target: drag,\n identifier,\n active,\n x: p[0],\n y: p[1],\n dx: 0,\n dy: 0,\n dispatch\n }), d)) == null) return;\n\n dx = s.x - p[0] || 0;\n dy = s.y - p[1] || 0;\n\n return function gesture(type, event, touch) {\n var p0 = p, n;\n switch (type) {\n case \"start\": gestures[identifier] = gesture, n = active++; break;\n case \"end\": delete gestures[identifier], --active; // falls through\n case \"drag\": p = pointer(touch || event, container), n = active; break;\n }\n dispatch.call(\n type,\n that,\n new DragEvent(type, {\n sourceEvent: event,\n subject: s,\n target: drag,\n identifier,\n active: n,\n x: p[0] + dx,\n y: p[1] + dy,\n dx: p[0] - p0[0],\n dy: p[1] - p0[1],\n dispatch\n }),\n d\n );\n };\n }\n\n drag.filter = function(_) {\n return arguments.length ? (filter = typeof _ === \"function\" ? _ : constant(!!_), drag) : filter;\n };\n\n drag.container = function(_) {\n return arguments.length ? (container = typeof _ === \"function\" ? _ : constant(_), drag) : container;\n };\n\n drag.subject = function(_) {\n return arguments.length ? (subject = typeof _ === \"function\" ? _ : constant(_), drag) : subject;\n };\n\n drag.touchable = function(_) {\n return arguments.length ? (touchable = typeof _ === \"function\" ? _ : constant(!!_), drag) : touchable;\n };\n\n drag.on = function() {\n var value = listeners.on.apply(listeners, arguments);\n return value === listeners ? drag : value;\n };\n\n drag.clickDistance = function(_) {\n return arguments.length ? (clickDistance2 = (_ = +_) * _, drag) : Math.sqrt(clickDistance2);\n };\n\n return drag;\n}\n"],"x_google_ignoreList":[0,1,2],"mappings":";;;;AAAA,IAAA,KAAe,YAAW;;;ACA1B,SAAwB,EAAU,GAAM,EACtC,gBACA,YACA,WACA,eACA,WACA,MAAG,MAAG,OAAI,OACV,eACC;CACD,OAAO,iBAAiB,MAAM;EAC5B,MAAM;GAAC,OAAO;GAAM,YAAY;GAAM,cAAc;EAAI;EACxD,aAAa;GAAC,OAAO;GAAa,YAAY;GAAM,cAAc;EAAI;EACtE,SAAS;GAAC,OAAO;GAAS,YAAY;GAAM,cAAc;EAAI;EAC9D,QAAQ;GAAC,OAAO;GAAQ,YAAY;GAAM,cAAc;EAAI;EAC5D,YAAY;GAAC,OAAO;GAAY,YAAY;GAAM,cAAc;EAAI;EACpE,QAAQ;GAAC,OAAO;GAAQ,YAAY;GAAM,cAAc;EAAI;EAC5D,GAAG;GAAC,OAAO;GAAG,YAAY;GAAM,cAAc;EAAI;EAClD,GAAG;GAAC,OAAO;GAAG,YAAY;GAAM,cAAc;EAAI;EAClD,IAAI;GAAC,OAAO;GAAI,YAAY;GAAM,cAAc;EAAI;EACpD,IAAI;GAAC,OAAO;GAAI,YAAY;GAAM,cAAc;EAAI;EACpD,GAAG,EAAC,OAAO,EAAQ;CACrB,CAAC;AACH;AAEA,EAAU,UAAU,KAAK,WAAW;CAClC,IAAI,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,KAAM,aAAa,IAAIA,EAAS,CAAC,GAAG,KAAQ;CAC1F,GAEA,EAAK,YAAY,SAAS,GAAG;EAC3B,OAAO,UAAU,UAAU,IAAY,OAAO,KAAM,aAAa,IAAIA,EAAS,CAAC,CAAC,CAAC,GAAG,KAAQ;CAC9F,GAEA,EAAK,KAAK,WAAW;EACnB,IAAI,IAAQ,EAAU,GAAG,MAAM,GAAW,SAAS;EACnD,OAAO,MAAU,IAAY,IAAO;CACtC,GAEA,EAAK,gBAAgB,SAAS,GAAG;EAC/B,OAAO,UAAU,UAAU,KAAkB,IAAI,CAAC,KAAK,GAAG,KAAQ,KAAK,KAAK,CAAc;CAC5F,GAEO;AACT"}
@@ -0,0 +1,151 @@
1
+ //#region node_modules/d3-hierarchy/src/hierarchy/count.js
2
+ function e(e) {
3
+ var t = 0, n = e.children, r = n && n.length;
4
+ if (!r) t = 1;
5
+ else for (; --r >= 0;) t += n[r].value;
6
+ e.value = t;
7
+ }
8
+ function t() {
9
+ return this.eachAfter(e);
10
+ }
11
+ //#endregion
12
+ //#region node_modules/d3-hierarchy/src/hierarchy/each.js
13
+ function n(e, t) {
14
+ let n = -1;
15
+ for (let r of this) e.call(t, r, ++n, this);
16
+ return this;
17
+ }
18
+ //#endregion
19
+ //#region node_modules/d3-hierarchy/src/hierarchy/eachBefore.js
20
+ function r(e, t) {
21
+ for (var n = this, r = [n], i, a, o = -1; n = r.pop();) if (e.call(t, n, ++o, this), i = n.children) for (a = i.length - 1; a >= 0; --a) r.push(i[a]);
22
+ return this;
23
+ }
24
+ //#endregion
25
+ //#region node_modules/d3-hierarchy/src/hierarchy/eachAfter.js
26
+ function i(e, t) {
27
+ for (var n = this, r = [n], i = [], a, o, s, c = -1; n = r.pop();) if (i.push(n), a = n.children) for (o = 0, s = a.length; o < s; ++o) r.push(a[o]);
28
+ for (; n = i.pop();) e.call(t, n, ++c, this);
29
+ return this;
30
+ }
31
+ //#endregion
32
+ //#region node_modules/d3-hierarchy/src/hierarchy/find.js
33
+ function a(e, t) {
34
+ let n = -1;
35
+ for (let r of this) if (e.call(t, r, ++n, this)) return r;
36
+ }
37
+ //#endregion
38
+ //#region node_modules/d3-hierarchy/src/hierarchy/sum.js
39
+ function o(e) {
40
+ return this.eachAfter(function(t) {
41
+ for (var n = +e(t.data) || 0, r = t.children, i = r && r.length; --i >= 0;) n += r[i].value;
42
+ t.value = n;
43
+ });
44
+ }
45
+ //#endregion
46
+ //#region node_modules/d3-hierarchy/src/hierarchy/sort.js
47
+ function s(e) {
48
+ return this.eachBefore(function(t) {
49
+ t.children && t.children.sort(e);
50
+ });
51
+ }
52
+ //#endregion
53
+ //#region node_modules/d3-hierarchy/src/hierarchy/path.js
54
+ function c(e) {
55
+ for (var t = this, n = l(t, e), r = [t]; t !== n;) t = t.parent, r.push(t);
56
+ for (var i = r.length; e !== n;) r.splice(i, 0, e), e = e.parent;
57
+ return r;
58
+ }
59
+ function l(e, t) {
60
+ if (e === t) return e;
61
+ var n = e.ancestors(), r = t.ancestors(), i = null;
62
+ for (e = n.pop(), t = r.pop(); e === t;) i = e, e = n.pop(), t = r.pop();
63
+ return i;
64
+ }
65
+ //#endregion
66
+ //#region node_modules/d3-hierarchy/src/hierarchy/ancestors.js
67
+ function u() {
68
+ for (var e = this, t = [e]; e = e.parent;) t.push(e);
69
+ return t;
70
+ }
71
+ //#endregion
72
+ //#region node_modules/d3-hierarchy/src/hierarchy/descendants.js
73
+ function d() {
74
+ return Array.from(this);
75
+ }
76
+ //#endregion
77
+ //#region node_modules/d3-hierarchy/src/hierarchy/leaves.js
78
+ function f() {
79
+ var e = [];
80
+ return this.eachBefore(function(t) {
81
+ t.children || e.push(t);
82
+ }), e;
83
+ }
84
+ //#endregion
85
+ //#region node_modules/d3-hierarchy/src/hierarchy/links.js
86
+ function p() {
87
+ var e = this, t = [];
88
+ return e.each(function(n) {
89
+ n !== e && t.push({
90
+ source: n.parent,
91
+ target: n
92
+ });
93
+ }), t;
94
+ }
95
+ //#endregion
96
+ //#region node_modules/d3-hierarchy/src/hierarchy/iterator.js
97
+ function* m() {
98
+ var e = this, t, n = [e], r, i, a;
99
+ do
100
+ for (t = n.reverse(), n = []; e = t.pop();) if (yield e, r = e.children) for (i = 0, a = r.length; i < a; ++i) n.push(r[i]);
101
+ while (n.length);
102
+ }
103
+ //#endregion
104
+ //#region node_modules/d3-hierarchy/src/hierarchy/index.js
105
+ function h(e, t) {
106
+ e instanceof Map ? (e = [void 0, e], t === void 0 && (t = v)) : t === void 0 && (t = _);
107
+ for (var n = new x(e), r, i = [n], a, o, s, c; r = i.pop();) if ((o = t(r.data)) && (c = (o = Array.from(o)).length)) for (r.children = o, s = c - 1; s >= 0; --s) i.push(a = o[s] = new x(o[s])), a.parent = r, a.depth = r.depth + 1;
108
+ return n.eachBefore(b);
109
+ }
110
+ function g() {
111
+ return h(this).eachBefore(y);
112
+ }
113
+ function _(e) {
114
+ return e.children;
115
+ }
116
+ function v(e) {
117
+ return Array.isArray(e) ? e[1] : null;
118
+ }
119
+ function y(e) {
120
+ e.data.value !== void 0 && (e.value = e.data.value), e.data = e.data.data;
121
+ }
122
+ function b(e) {
123
+ var t = 0;
124
+ do
125
+ e.height = t;
126
+ while ((e = e.parent) && e.height < ++t);
127
+ }
128
+ function x(e) {
129
+ this.data = e, this.depth = this.height = 0, this.parent = null;
130
+ }
131
+ x.prototype = h.prototype = {
132
+ constructor: x,
133
+ count: t,
134
+ each: n,
135
+ eachAfter: i,
136
+ eachBefore: r,
137
+ find: a,
138
+ sum: o,
139
+ sort: s,
140
+ path: c,
141
+ ancestors: u,
142
+ descendants: d,
143
+ leaves: f,
144
+ links: p,
145
+ copy: g,
146
+ [Symbol.iterator]: m
147
+ };
148
+ //#endregion
149
+ export { h as n, x as t };
150
+
151
+ //# sourceMappingURL=hierarchy-CDFAetye.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"hierarchy-CDFAetye.js","names":["node_count","node_each","node_eachAfter","node_eachBefore","node_find","node_sum","node_sort","node_path","node_ancestors","node_descendants","node_leaves","node_links","node_iterator"],"sources":["../node_modules/d3-hierarchy/src/hierarchy/count.js","../node_modules/d3-hierarchy/src/hierarchy/each.js","../node_modules/d3-hierarchy/src/hierarchy/eachBefore.js","../node_modules/d3-hierarchy/src/hierarchy/eachAfter.js","../node_modules/d3-hierarchy/src/hierarchy/find.js","../node_modules/d3-hierarchy/src/hierarchy/sum.js","../node_modules/d3-hierarchy/src/hierarchy/sort.js","../node_modules/d3-hierarchy/src/hierarchy/path.js","../node_modules/d3-hierarchy/src/hierarchy/ancestors.js","../node_modules/d3-hierarchy/src/hierarchy/descendants.js","../node_modules/d3-hierarchy/src/hierarchy/leaves.js","../node_modules/d3-hierarchy/src/hierarchy/links.js","../node_modules/d3-hierarchy/src/hierarchy/iterator.js","../node_modules/d3-hierarchy/src/hierarchy/index.js"],"sourcesContent":["function count(node) {\n var sum = 0,\n children = node.children,\n i = children && children.length;\n if (!i) sum = 1;\n else while (--i >= 0) sum += children[i].value;\n node.value = sum;\n}\n\nexport default function() {\n return this.eachAfter(count);\n}\n","export default function(callback, that) {\n let index = -1;\n for (const node of this) {\n callback.call(that, node, ++index, this);\n }\n return this;\n}\n","export default function(callback, that) {\n var node = this, nodes = [node], children, i, index = -1;\n while (node = nodes.pop()) {\n callback.call(that, node, ++index, this);\n if (children = node.children) {\n for (i = children.length - 1; i >= 0; --i) {\n nodes.push(children[i]);\n }\n }\n }\n return this;\n}\n","export default function(callback, that) {\n var node = this, nodes = [node], next = [], children, i, n, index = -1;\n while (node = nodes.pop()) {\n next.push(node);\n if (children = node.children) {\n for (i = 0, n = children.length; i < n; ++i) {\n nodes.push(children[i]);\n }\n }\n }\n while (node = next.pop()) {\n callback.call(that, node, ++index, this);\n }\n return this;\n}\n","export default function(callback, that) {\n let index = -1;\n for (const node of this) {\n if (callback.call(that, node, ++index, this)) {\n return node;\n }\n }\n}\n","export default function(value) {\n return this.eachAfter(function(node) {\n var sum = +value(node.data) || 0,\n children = node.children,\n i = children && children.length;\n while (--i >= 0) sum += children[i].value;\n node.value = sum;\n });\n}\n","export default function(compare) {\n return this.eachBefore(function(node) {\n if (node.children) {\n node.children.sort(compare);\n }\n });\n}\n","export default function(end) {\n var start = this,\n ancestor = leastCommonAncestor(start, end),\n nodes = [start];\n while (start !== ancestor) {\n start = start.parent;\n nodes.push(start);\n }\n var k = nodes.length;\n while (end !== ancestor) {\n nodes.splice(k, 0, end);\n end = end.parent;\n }\n return nodes;\n}\n\nfunction leastCommonAncestor(a, b) {\n if (a === b) return a;\n var aNodes = a.ancestors(),\n bNodes = b.ancestors(),\n c = null;\n a = aNodes.pop();\n b = bNodes.pop();\n while (a === b) {\n c = a;\n a = aNodes.pop();\n b = bNodes.pop();\n }\n return c;\n}\n","export default function() {\n var node = this, nodes = [node];\n while (node = node.parent) {\n nodes.push(node);\n }\n return nodes;\n}\n","export default function() {\n return Array.from(this);\n}\n","export default function() {\n var leaves = [];\n this.eachBefore(function(node) {\n if (!node.children) {\n leaves.push(node);\n }\n });\n return leaves;\n}\n","export default function() {\n var root = this, links = [];\n root.each(function(node) {\n if (node !== root) { // Don’t include the root’s parent, if any.\n links.push({source: node.parent, target: node});\n }\n });\n return links;\n}\n","export default function*() {\n var node = this, current, next = [node], children, i, n;\n do {\n current = next.reverse(), next = [];\n while (node = current.pop()) {\n yield node;\n if (children = node.children) {\n for (i = 0, n = children.length; i < n; ++i) {\n next.push(children[i]);\n }\n }\n }\n } while (next.length);\n}\n","import node_count from \"./count.js\";\nimport node_each from \"./each.js\";\nimport node_eachBefore from \"./eachBefore.js\";\nimport node_eachAfter from \"./eachAfter.js\";\nimport node_find from \"./find.js\";\nimport node_sum from \"./sum.js\";\nimport node_sort from \"./sort.js\";\nimport node_path from \"./path.js\";\nimport node_ancestors from \"./ancestors.js\";\nimport node_descendants from \"./descendants.js\";\nimport node_leaves from \"./leaves.js\";\nimport node_links from \"./links.js\";\nimport node_iterator from \"./iterator.js\";\n\nexport default function hierarchy(data, children) {\n if (data instanceof Map) {\n data = [undefined, data];\n if (children === undefined) children = mapChildren;\n } else if (children === undefined) {\n children = objectChildren;\n }\n\n var root = new Node(data),\n node,\n nodes = [root],\n child,\n childs,\n i,\n n;\n\n while (node = nodes.pop()) {\n if ((childs = children(node.data)) && (n = (childs = Array.from(childs)).length)) {\n node.children = childs;\n for (i = n - 1; i >= 0; --i) {\n nodes.push(child = childs[i] = new Node(childs[i]));\n child.parent = node;\n child.depth = node.depth + 1;\n }\n }\n }\n\n return root.eachBefore(computeHeight);\n}\n\nfunction node_copy() {\n return hierarchy(this).eachBefore(copyData);\n}\n\nfunction objectChildren(d) {\n return d.children;\n}\n\nfunction mapChildren(d) {\n return Array.isArray(d) ? d[1] : null;\n}\n\nfunction copyData(node) {\n if (node.data.value !== undefined) node.value = node.data.value;\n node.data = node.data.data;\n}\n\nexport function computeHeight(node) {\n var height = 0;\n do node.height = height;\n while ((node = node.parent) && (node.height < ++height));\n}\n\nexport function Node(data) {\n this.data = data;\n this.depth =\n this.height = 0;\n this.parent = null;\n}\n\nNode.prototype = hierarchy.prototype = {\n constructor: Node,\n count: node_count,\n each: node_each,\n eachAfter: node_eachAfter,\n eachBefore: node_eachBefore,\n find: node_find,\n sum: node_sum,\n sort: node_sort,\n path: node_path,\n ancestors: node_ancestors,\n descendants: node_descendants,\n leaves: node_leaves,\n links: node_links,\n copy: node_copy,\n [Symbol.iterator]: node_iterator\n};\n"],"x_google_ignoreList":[0,1,2,3,4,5,6,7,8,9,10,11,12,13],"mappings":";AAAA,SAAS,EAAM,GAAM;CACnB,IAAI,IAAM,GACN,IAAW,EAAK,UAChB,IAAI,KAAY,EAAS;CAC7B,IAAI,CAAC,GAAG,IAAM;MACT,OAAO,EAAE,KAAK,IAAG,KAAO,EAAS,EAAE,CAAC;CACzC,EAAK,QAAQ;AACf;AAEA,SAAA,IAA0B;CACxB,OAAO,KAAK,UAAU,CAAK;AAC7B;;;ACXA,SAAA,EAAwB,GAAU,GAAM;CACtC,IAAI,IAAQ;CAC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