@amcharts/amcharts5-mcp 1.9.0 → 1.9.1

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 (82) hide show
  1. package/README.md +12 -10
  2. package/content/SKILL.md +4 -0
  3. package/content/flow.md +2 -0
  4. package/content/gantt.md +2 -0
  5. package/content/hierarchy.md +2 -0
  6. package/content/json.md +501 -0
  7. package/content/map.md +2 -0
  8. package/content/pie.md +2 -0
  9. package/content/radar.md +2 -0
  10. package/content/stock.md +3 -0
  11. package/content/timeline.md +2 -0
  12. package/content/venn.md +2 -0
  13. package/content/wordcloud.md +2 -0
  14. package/content/xy.md +30 -0
  15. package/extended/examples/column-bar/column-chart-with-patterns.md +170 -0
  16. package/extended/examples/json-configs/flow-arc-diagram.md +198 -0
  17. package/extended/examples/json-configs/flow-chord-directed.md +211 -0
  18. package/extended/examples/json-configs/flow-chord-non-ribbon.md +253 -0
  19. package/extended/examples/json-configs/flow-chord.md +203 -0
  20. package/extended/examples/json-configs/flow-sankey.md +191 -0
  21. package/extended/examples/json-configs/gantt-multilevel.md +190 -0
  22. package/extended/examples/json-configs/gantt-simple.md +167 -0
  23. package/extended/examples/json-configs/gauge-bands.md +379 -0
  24. package/extended/examples/json-configs/gauge.md +94 -0
  25. package/extended/examples/json-configs/hierarchy-force-directed.md +131 -0
  26. package/extended/examples/json-configs/hierarchy-pack.md +137 -0
  27. package/extended/examples/json-configs/hierarchy-partition.md +131 -0
  28. package/extended/examples/json-configs/hierarchy-sunburst.md +160 -0
  29. package/extended/examples/json-configs/hierarchy-tree.md +135 -0
  30. package/extended/examples/json-configs/hierarchy-treemap.md +159 -0
  31. package/extended/examples/json-configs/hierarchy-voronoi-treemap.md +533 -0
  32. package/extended/examples/json-configs/map-altitude-arcs.md +238 -0
  33. package/extended/examples/json-configs/map-animating-along-lines.md +217 -0
  34. package/extended/examples/json-configs/map-auto-home.md +85 -0
  35. package/extended/examples/json-configs/map-clustered-points.md +387 -0
  36. package/extended/examples/json-configs/map-day-and-night.md +68 -0
  37. package/extended/examples/json-configs/map-globe-rotate-to-country.md +131 -0
  38. package/extended/examples/json-configs/map-globe-with-projected-circles.md +377 -0
  39. package/extended/examples/json-configs/map-pixel-map.md +175 -0
  40. package/extended/examples/json-configs/map-sankey-waypoints.md +845 -0
  41. package/extended/examples/json-configs/map-sankey.md +191 -0
  42. package/extended/examples/json-configs/map-satellite-day-and-night.md +81 -0
  43. package/extended/examples/json-configs/map-satellite-globe.md +120 -0
  44. package/extended/examples/json-configs/map-surface-bullets.md +195 -0
  45. package/extended/examples/json-configs/map-us-heat-map.md +378 -0
  46. package/extended/examples/json-configs/map-with-bubbles.md +344 -0
  47. package/extended/examples/json-configs/map-zoom-to-country.md +103 -0
  48. package/extended/examples/json-configs/pie-chart.md +109 -0
  49. package/extended/examples/json-configs/pie-donut-chart.md +113 -0
  50. package/extended/examples/json-configs/radar-date-range-columns.md +188 -0
  51. package/extended/examples/json-configs/radar-heat-map.md +1163 -0
  52. package/extended/examples/json-configs/radar-line.md +194 -0
  53. package/extended/examples/json-configs/sliced-funnel.md +112 -0
  54. package/extended/examples/json-configs/sliced-pictorial-stacked.md +98 -0
  55. package/extended/examples/json-configs/sliced-pyramid.md +111 -0
  56. package/extended/examples/json-configs/timeline-linear-process-diagram.md +1145 -0
  57. package/extended/examples/json-configs/timeline-serpentine-chart.md +509 -0
  58. package/extended/examples/json-configs/timeline-spiral-chart.md +301 -0
  59. package/extended/examples/json-configs/venn-diagram.md +146 -0
  60. package/extended/examples/json-configs/wordcloud-with-data.md +275 -0
  61. package/extended/examples/json-configs/wordcloud-with-text.md +75 -0
  62. package/extended/examples/json-configs/xy-100-percent-stacked-column.md +415 -0
  63. package/extended/examples/json-configs/xy-bubble.md +774 -0
  64. package/extended/examples/json-configs/xy-candlestick.md +556 -0
  65. package/extended/examples/json-configs/xy-clustered-column.md +474 -0
  66. package/extended/examples/json-configs/xy-column.md +250 -0
  67. package/extended/examples/json-configs/xy-comparing-periods.md +269 -0
  68. package/extended/examples/json-configs/xy-dumbbell-plot.md +324 -0
  69. package/extended/examples/json-configs/xy-gapless-date-axis.md +306 -0
  70. package/extended/examples/json-configs/xy-line.md +2145 -0
  71. package/extended/examples/json-configs/xy-multiple-synced-value-axes.md +483 -0
  72. package/extended/examples/json-configs/xy-percent-change-comparison.md +1185 -0
  73. package/extended/examples/json-configs/xy-pulsing-last-bullet.md +260 -0
  74. package/extended/examples/json-configs/xy-smoothed-line.md +272 -0
  75. package/extended/examples/json-configs/xy-stacked-and-clustered-column.md +517 -0
  76. package/extended/examples/json-configs/xy-stacked-column.md +483 -0
  77. package/extended/examples/json-configs/xy-stacked-step.md +324 -0
  78. package/extended/examples/maps/map-with-patterns.md +3 -3
  79. package/extended/getting-started/integrations/am5-chart-element.md +2 -0
  80. package/package.json +5 -2
  81. package/src/content.js +26 -1
  82. package/src/tools.js +210 -46
package/content/radar.md CHANGED
@@ -1,5 +1,7 @@
1
1
  # Radar & Gauge Charts
2
2
 
3
+ > **As a JSON config:** see `references/json.md`. The settings below go into each object's `"settings"` there.
4
+
3
5
 
4
6
  ## Required imports
5
7
 
package/content/stock.md CHANGED
@@ -1,4 +1,7 @@
1
1
  # Stock & Financial Charts
2
+
3
+ > **As a JSON config:** see `references/json.md`. The settings below go into each object's `"settings"` there.
4
+
2
5
  Build financial stock charts with panels, indicators, and toolbar.
3
6
 
4
7
 
@@ -1,5 +1,7 @@
1
1
  # Timeline Charts — Curve, Serpentine, Spiral
2
2
 
3
+ > **As a JSON config:** see `references/json.md`. The settings below go into each object's `"settings"` there.
4
+
3
5
  Docs: https://www.amcharts.com/docs/v5/charts/timeline/
4
6
 
5
7
  Timeline charts are "curved XY charts" — they use XY-style axes and series but bend the chart into serpentine, spiral, or custom shapes. Added in amCharts 5.12.0.
package/content/venn.md CHANGED
@@ -1,5 +1,7 @@
1
1
  # Venn Diagram
2
2
 
3
+ > **As a JSON config:** see `references/json.md`. The settings below go into each object's `"settings"` there.
4
+
3
5
  Docs: https://www.amcharts.com/docs/v5/charts/venn/
4
6
 
5
7
  Venn diagrams show overlapping relationships between sets. There is NO `VennDiagram` chart class — `am5venn.Venn` is both the series and the visual container, pushed directly into `root.container.children` (or any `Container`).
@@ -1,5 +1,7 @@
1
1
  # Word Cloud
2
2
 
3
+ > **As a JSON config:** see `references/json.md`. The settings below go into each object's `"settings"` there.
4
+
3
5
  Docs: https://www.amcharts.com/docs/v5/charts/word-cloud/
4
6
 
5
7
  Word Cloud displays words/tags sized by their value/weight. It's a "container-less" chart — the series is pushed directly to `root.container.children` (no wrapper chart object).
package/content/xy.md CHANGED
@@ -1,5 +1,7 @@
1
1
  # XY Charts — Line, Area, Bar, Column, Candlestick, Scatter
2
2
 
3
+ > **As a JSON config:** see `references/json.md`. The settings below go into each object's `"settings"` there.
4
+
3
5
 
4
6
  ## Required imports
5
7
 
@@ -811,6 +813,34 @@ series.fills.template.set("fillGradient", am5.LinearGradient.new(root, {
811
813
 
812
814
  `RadialGradient` is centered on map polygons, line and area fills and bullets since 5.21.1 (with `target` set, on the target). 5.21.1 put one with pixel `x`/`y` off-center on radar fills and similar shapes; 5.21.2 fixes that.
813
815
 
816
+ ## Different pattern per column
817
+
818
+ To tell columns apart without color (print, grayscale, color-blind readers), give each one a fill pattern through its data row. The full example is `column-bar/column-chart-with-patterns`.
819
+
820
+ ```js
821
+ series.columns.template.setAll({
822
+ fill: am5.color(0xffffff), // shows in the gaps between the pattern's shapes
823
+ stroke: am5.color(0x000000),
824
+ templateField: "columnSettings" // on the columns' template, not on the series
825
+ });
826
+
827
+ const black = am5.color(0x000000);
828
+ const data = [
829
+ { source: "Search", visits: 4200, columnSettings: { fillPattern: am5.LinePattern.new(root, { color: black, angle: 45, strokeWidth: 2, gap: 6 }) } },
830
+ { source: "Social", visits: 2600, columnSettings: { fillPattern: am5.CirclePattern.new(root, { color: black, radius: 2, gap: 5 }) } },
831
+ { source: "Email", visits: 1500, columnSettings: { fillPattern: am5.RectanglePattern.new(root, { color: black, maxWidth: 5, maxHeight: 5, gap: 5, checkered: true }) } },
832
+ { source: "Direct", visits: 3100, columnSettings: { fillPattern: am5.LinePattern.new(root, { color: black, angle: 90, strokeWidth: 2, gap: 6 }) } }
833
+ ];
834
+ xAxis.data.setAll(data);
835
+ series.data.setAll(data);
836
+ ```
837
+
838
+ - `templateField` is a setting of `series.columns.template`. Set on the series, it does nothing and the columns stay plain.
839
+ - A pattern's `color` is the color of its lines, dots or squares. The gaps show the column's `fill`, or the pattern's own `fill` (with `fillOpacity`) when it has one. A `color` equal to what shows in the gaps makes the column look solid. Always set `color`: without one, the shapes are black whatever the column's colors (5.21.3).
840
+ - `LinePattern`: set the line direction with `angle` (5.14+; 0 is horizontal, 90 upright). `rotation` turns the whole tile instead, and at 45° the tile edges show as broken lines.
841
+ - Make each pattern once, as above. An adapter that returns `am5.LinePattern.new(…)` makes a new pattern every time the setting is read.
842
+ - In a JSON config, a row that holds a pattern needs `"__parse": true`, and so does its settings object (`references/json.md`, rule 3): `{ "source": "Search", "visits": 4200, "columnSettings": { "fillPattern": { "type": "LinePattern", "settings": { "color": { "type": "Color", "value": "#000000" }, "angle": 45 } }, "__parse": true }, "__parse": true }`.
843
+
814
844
  ## Changing fields and axes after creation (5.20.0)
815
845
 
816
846
  ```js
@@ -0,0 +1,170 @@
1
+ ---
2
+ title: "Column Chart with Patterns"
3
+ source: "amcharts5-mcp: written for the skill, checked in a browser with amCharts 5.21.3"
4
+ category: "column-bar"
5
+ ---
6
+
7
+ A column chart where every column has a fill pattern of its own: diagonal lines, dots, a checkerboard and vertical lines (LinePattern, CirclePattern, RectanglePattern), in black on white, so it reads printed in black and white.
8
+
9
+ When patterns beat colors: patterns tell columns apart without relying on color, which helps readers with color blindness and survives grayscale printing. Each column gets its pattern through its data row, with a template field on the columns' template. Keep to a handful: past six or seven, patterns get busy.
10
+
11
+ Good for:
12
+ - Charts that must read in print or grayscale
13
+ - Accessible charts for color-blind readers
14
+ - Marking special columns: forecast, estimate, incomplete
15
+
16
+ Think twice when:
17
+ - Many columns: patterns get busy, use colors and a legend
18
+ - Thin columns: patterns need room to show
19
+
20
+ Things that go wrong:
21
+ - `templateField` set on the series instead of on `series.columns.template`: the series ignores it, and the columns stay plain.
22
+ - A pattern `color` equal to the fill behind it: the stripes vanish and the column looks solid. The gaps show the column's `fill`, or the pattern's own `fill` if it has one.
23
+ - No pattern `color`: the shapes are drawn black whatever the column's colors (5.21.3).
24
+ - `rotation` on a LinePattern turns the whole tile, and at 45° its edges show as broken lines. Set the line direction with `angle`.
25
+
26
+ Prompt: Create a column chart of website visits by traffic source (Search, Social, Email, Direct), with a different black-and-white fill pattern in each column and the value above it. Use the amCharts 5 library.
27
+
28
+ ## JavaScript
29
+
30
+ ```javascript
31
+ // Create root and chart
32
+ var root = am5.Root.new("chartdiv");
33
+
34
+ // Set themes
35
+ root.setThemes([
36
+ am5themes_Animated.new(root)
37
+ ]);
38
+
39
+ var chart = root.container.children.push(am5xy.XYChart.new(root, {
40
+ panX: false,
41
+ panY: false,
42
+ paddingLeft: 0
43
+ }));
44
+
45
+ // Create axes
46
+ // https://www.amcharts.com/docs/v5/charts/xy-chart/axes/
47
+ var xAxis = chart.xAxes.push(am5xy.CategoryAxis.new(root, {
48
+ categoryField: "source",
49
+ renderer: am5xy.AxisRendererX.new(root, { minGridDistance: 30 })
50
+ }));
51
+
52
+ var yAxis = chart.yAxes.push(am5xy.ValueAxis.new(root, {
53
+ min: 0,
54
+ renderer: am5xy.AxisRendererY.new(root, {})
55
+ }));
56
+
57
+ // Create series
58
+ // https://www.amcharts.com/docs/v5/charts/xy-chart/series/
59
+ var series = chart.series.push(am5xy.ColumnSeries.new(root, {
60
+ name: "Visits",
61
+ xAxis: xAxis,
62
+ yAxis: yAxis,
63
+ valueYField: "visits",
64
+ categoryXField: "source",
65
+ tooltip: am5.Tooltip.new(root, { labelText: "{categoryX}: {valueY}" })
66
+ }));
67
+
68
+ var black = am5.color(0x000000);
69
+
70
+ series.columns.template.setAll({
71
+ width: am5.percent(70),
72
+ fill: am5.color(0xffffff), // white: shows in the gaps between the pattern's shapes
73
+ stroke: black, // a black outline
74
+ strokeWidth: 2,
75
+ // each column's pattern comes from "columnSettings" in its data row;
76
+ // templateField goes on the columns' template, not on the series
77
+ templateField: "columnSettings"
78
+ });
79
+
80
+ // Value labels above the columns
81
+ series.bullets.push(function () {
82
+ return am5.Bullet.new(root, {
83
+ locationY: 1,
84
+ sprite: am5.Label.new(root, {
85
+ text: "{valueY}",
86
+ fill: black,
87
+ centerX: am5.p50,
88
+ centerY: am5.p100,
89
+ populateText: true
90
+ })
91
+ });
92
+ });
93
+
94
+ // One pattern per column, made once here. Each pattern's color is black,
95
+ // which contrasts with the white column fill behind it.
96
+ var data = [{
97
+ source: "Search",
98
+ visits: 4200,
99
+ columnSettings: {
100
+ fillPattern: am5.LinePattern.new(root, { // lines...
101
+ color: black, // ...in black...
102
+ angle: 45, // ...at 45 degrees: angle turns the lines, not the tile...
103
+ strokeWidth: 2,
104
+ gap: 6 // ...6px apart
105
+ })
106
+ }
107
+ }, {
108
+ source: "Social",
109
+ visits: 2600,
110
+ columnSettings: {
111
+ fillPattern: am5.CirclePattern.new(root, { // dots...
112
+ color: black, // ...in black...
113
+ radius: 2, // ...with a 2px radius...
114
+ gap: 5 // ...5px apart
115
+ })
116
+ }
117
+ }, {
118
+ source: "Email",
119
+ visits: 1500,
120
+ columnSettings: {
121
+ fillPattern: am5.RectanglePattern.new(root, { // squares...
122
+ color: black, // ...in black...
123
+ maxWidth: 5, // ...5px wide...
124
+ maxHeight: 5, // ...and 5px high...
125
+ gap: 5, // ...5px apart...
126
+ checkered: true // ...every second one, like a checkerboard
127
+ })
128
+ }
129
+ }, {
130
+ source: "Direct",
131
+ visits: 3100,
132
+ columnSettings: {
133
+ fillPattern: am5.LinePattern.new(root, { // lines...
134
+ color: black, // ...in black...
135
+ angle: 90, // ...upright...
136
+ strokeWidth: 2,
137
+ gap: 6 // ...6px apart
138
+ })
139
+ }
140
+ }];
141
+
142
+ xAxis.data.setAll(data);
143
+ series.data.setAll(data);
144
+
145
+ // Make stuff animate on load
146
+ // https://www.amcharts.com/docs/v5/concepts/animations/
147
+ series.appear(1000);
148
+ chart.appear(1000, 100);
149
+ ```
150
+
151
+ ## HTML
152
+
153
+ ```html
154
+ <div id="chartdiv"></div>
155
+ ```
156
+
157
+ ## CSS
158
+
159
+ ```css
160
+ #chartdiv {
161
+ width: 100%;
162
+ height: 500px;
163
+ }
164
+ ```
165
+
166
+ ## Required resources
167
+
168
+ - https://cdn.amcharts.com/lib/5/index.js
169
+ - https://cdn.amcharts.com/lib/5/xy.js
170
+ - https://cdn.amcharts.com/lib/5/themes/Animated.js
@@ -0,0 +1,198 @@
1
+ ---
2
+ title: "Arc Diagram (JSON config)"
3
+ category: "json-configs"
4
+ source: "@amcharts/amcharts5@5.21.3: examples/flow-arc-diagram/config.json"
5
+ ---
6
+
7
+ # Arc Diagram (JSON config)
8
+
9
+ An arc diagram: nodes in a row, sized by their total, with arcs for the links between them and a label under each node.
10
+
11
+ Chart family: flow · Tags: arc diagram, flow, links, labels
12
+
13
+ A complete amCharts 5 JSON config, as shipped in the `@amcharts/amcharts5` npm package (examples/flow-arc-diagram/config.json, version 5.21.3). It works with `am5plugins_json.JsonParser`, the `<am5-chart>` element, the framework packages' `config` prop, and Chart Maker links. The rules for writing one are in the skill's JSON reference (get_chart_reference("json")).
14
+
15
+ Themes are not part of a config. The example is meant for: Animated, set with `root.setThemes()`, the element's `themes` attribute, or a Chart Maker link's `theme`.
16
+
17
+ ## Required resources
18
+
19
+ - https://cdn.amcharts.com/lib/5/index.js
20
+ - https://cdn.amcharts.com/lib/5/plugins/json.js
21
+ - https://cdn.amcharts.com/lib/5/flow.js
22
+ - https://cdn.amcharts.com/lib/5/themes/Animated.js (theme, applied separately)
23
+
24
+ ## JSON config
25
+
26
+ ```json
27
+ {
28
+ "type": "ArcDiagram",
29
+ "settings": {
30
+ "sourceIdField": "source",
31
+ "targetIdField": "target",
32
+ "valueField": "value",
33
+ "orientation": "horizontal",
34
+ "paddingBottom": 70,
35
+ "autoAppear": true,
36
+ "appearDuration": 1000,
37
+ "appearDelay": 100
38
+ },
39
+ "properties": {
40
+ "data": "#data-0",
41
+ "nodes": {
42
+ "properties": {
43
+ "labels": {
44
+ "properties": {
45
+ "template": {
46
+ "settings": {
47
+ "fontSize": "0.85em",
48
+ "position": "absolute",
49
+ "y": {
50
+ "type": "Percent",
51
+ "value": 50
52
+ },
53
+ "paddingRight": 6
54
+ }
55
+ }
56
+ }
57
+ }
58
+ }
59
+ }
60
+ },
61
+ "refs": [
62
+ {
63
+ "data-0": [
64
+ {
65
+ "source": "Monica",
66
+ "target": "Rachel",
67
+ "value": 4
68
+ },
69
+ {
70
+ "source": "Monica",
71
+ "target": "Chandler",
72
+ "value": 63
73
+ },
74
+ {
75
+ "source": "Monica",
76
+ "target": "Ross",
77
+ "value": 16
78
+ },
79
+ {
80
+ "source": "Monica",
81
+ "target": "Joey",
82
+ "value": 9
83
+ },
84
+ {
85
+ "source": "Monica",
86
+ "target": "Phoebe",
87
+ "value": 3
88
+ },
89
+ {
90
+ "source": "Monica",
91
+ "target": "Pete",
92
+ "value": 10
93
+ },
94
+ {
95
+ "source": "Rachel",
96
+ "target": "Chandler",
97
+ "value": 7
98
+ },
99
+ {
100
+ "source": "Rachel",
101
+ "target": "Ross",
102
+ "value": 80
103
+ },
104
+ {
105
+ "source": "Rachel",
106
+ "target": "Joey",
107
+ "value": 30
108
+ },
109
+ {
110
+ "source": "Rachel",
111
+ "target": "Phoebe",
112
+ "value": 6
113
+ },
114
+ {
115
+ "source": "Rachel",
116
+ "target": "Tag",
117
+ "value": 4
118
+ },
119
+ {
120
+ "source": "Chandler",
121
+ "target": "Joey",
122
+ "value": 1
123
+ },
124
+ {
125
+ "source": "Chandler",
126
+ "target": "Phoebe",
127
+ "value": 7
128
+ },
129
+ {
130
+ "source": "Chandler",
131
+ "target": "Janice",
132
+ "value": 11
133
+ },
134
+ {
135
+ "source": "Chandler",
136
+ "target": "Kathy",
137
+ "value": 7
138
+ },
139
+ {
140
+ "source": "Ross",
141
+ "target": "Joey",
142
+ "value": 3
143
+ },
144
+ {
145
+ "source": "Ross",
146
+ "target": "Phoebe",
147
+ "value": 18
148
+ },
149
+ {
150
+ "source": "Ross",
151
+ "target": "Carol",
152
+ "value": 10
153
+ },
154
+ {
155
+ "source": "Ross",
156
+ "target": "Emily",
157
+ "value": 12
158
+ },
159
+ {
160
+ "source": "Ross",
161
+ "target": "Mona",
162
+ "value": 11
163
+ },
164
+ {
165
+ "source": "Ross",
166
+ "target": "Charlie",
167
+ "value": 10
168
+ },
169
+ {
170
+ "source": "Joey",
171
+ "target": "Phoebe",
172
+ "value": 6
173
+ },
174
+ {
175
+ "source": "Joey",
176
+ "target": "Janine",
177
+ "value": 9
178
+ },
179
+ {
180
+ "source": "Joey",
181
+ "target": "Charlie",
182
+ "value": 3
183
+ },
184
+ {
185
+ "source": "Phoebe",
186
+ "target": "David",
187
+ "value": 14
188
+ },
189
+ {
190
+ "source": "Phoebe",
191
+ "target": "Mike",
192
+ "value": 18
193
+ }
194
+ ]
195
+ }
196
+ ]
197
+ }
198
+ ```
@@ -0,0 +1,211 @@
1
+ ---
2
+ title: "Directed Chord Diagram (JSON config)"
3
+ category: "json-configs"
4
+ source: "@amcharts/amcharts5@5.21.3: examples/flow-chord-directed/config.json"
5
+ ---
6
+
7
+ # Directed Chord Diagram (JSON config)
8
+
9
+ A chord diagram whose links end in arrowheads, so each one shows its direction.
10
+
11
+ Chart family: flow · Tags: chord, directed, flow, radial labels
12
+
13
+ A complete amCharts 5 JSON config, as shipped in the `@amcharts/amcharts5` npm package (examples/flow-chord-directed/config.json, version 5.21.3). It works with `am5plugins_json.JsonParser`, the `<am5-chart>` element, the framework packages' `config` prop, and Chart Maker links. The rules for writing one are in the skill's JSON reference (get_chart_reference("json")).
14
+
15
+ Themes are not part of a config. The example is meant for: Animated, set with `root.setThemes()`, the element's `themes` attribute, or a Chart Maker link's `theme`.
16
+
17
+ ## Required resources
18
+
19
+ - https://cdn.amcharts.com/lib/5/index.js
20
+ - https://cdn.amcharts.com/lib/5/plugins/json.js
21
+ - https://cdn.amcharts.com/lib/5/flow.js
22
+ - https://cdn.amcharts.com/lib/5/themes/Animated.js (theme, applied separately)
23
+
24
+ ## JSON config
25
+
26
+ ```json
27
+ {
28
+ "type": "ChordDirected",
29
+ "settings": {
30
+ "sourceIdField": "source",
31
+ "targetIdField": "target",
32
+ "valueField": "value",
33
+ "radius": {
34
+ "type": "Percent",
35
+ "value": 75
36
+ },
37
+ "startAngle": 80,
38
+ "autoAppear": true,
39
+ "appearDuration": 1000,
40
+ "appearDelay": 100
41
+ },
42
+ "properties": {
43
+ "data": "#data-0",
44
+ "links": {
45
+ "properties": {
46
+ "template": {
47
+ "settings": {
48
+ "fillStyle": "source"
49
+ }
50
+ }
51
+ }
52
+ },
53
+ "nodes": {
54
+ "properties": {
55
+ "labels": {
56
+ "properties": {
57
+ "template": {
58
+ "settings": {
59
+ "textType": "radial",
60
+ "centerX": 0,
61
+ "fontSize": "0.8em"
62
+ }
63
+ }
64
+ }
65
+ }
66
+ }
67
+ }
68
+ },
69
+ "refs": [
70
+ {
71
+ "data-0": [
72
+ {
73
+ "source": "Monica",
74
+ "target": "Rachel",
75
+ "value": 4
76
+ },
77
+ {
78
+ "source": "Monica",
79
+ "target": "Chandler",
80
+ "value": 113
81
+ },
82
+ {
83
+ "source": "Monica",
84
+ "target": "Ross",
85
+ "value": 16
86
+ },
87
+ {
88
+ "source": "Monica",
89
+ "target": "Joey",
90
+ "value": 9
91
+ },
92
+ {
93
+ "source": "Monica",
94
+ "target": "Phoebe",
95
+ "value": 3
96
+ },
97
+ {
98
+ "source": "Monica",
99
+ "target": "Richard",
100
+ "value": 16
101
+ },
102
+ {
103
+ "source": "Monica",
104
+ "target": "Pete",
105
+ "value": 10
106
+ },
107
+ {
108
+ "source": "Rachel",
109
+ "target": "Chandler",
110
+ "value": 7
111
+ },
112
+ {
113
+ "source": "Rachel",
114
+ "target": "Ross",
115
+ "value": 80
116
+ },
117
+ {
118
+ "source": "Rachel",
119
+ "target": "Joey",
120
+ "value": 30
121
+ },
122
+ {
123
+ "source": "Rachel",
124
+ "target": "Phoebe",
125
+ "value": 6
126
+ },
127
+ {
128
+ "source": "Chandler",
129
+ "target": "Joey",
130
+ "value": 1
131
+ },
132
+ {
133
+ "source": "Chandler",
134
+ "target": "Phoebe",
135
+ "value": 7
136
+ },
137
+ {
138
+ "source": "Chandler",
139
+ "target": "Janice",
140
+ "value": 11
141
+ },
142
+ {
143
+ "source": "Chandler",
144
+ "target": "Kathy",
145
+ "value": 7
146
+ },
147
+ {
148
+ "source": "Ross",
149
+ "target": "Joey",
150
+ "value": 3
151
+ },
152
+ {
153
+ "source": "Ross",
154
+ "target": "Phoebe",
155
+ "value": 18
156
+ },
157
+ {
158
+ "source": "Ross",
159
+ "target": "Carol",
160
+ "value": 10
161
+ },
162
+ {
163
+ "source": "Ross",
164
+ "target": "Emily",
165
+ "value": 12
166
+ },
167
+ {
168
+ "source": "Ross",
169
+ "target": "Elizabeth",
170
+ "value": 8
171
+ },
172
+ {
173
+ "source": "Ross",
174
+ "target": "Mona",
175
+ "value": 11
176
+ },
177
+ {
178
+ "source": "Ross",
179
+ "target": "Charlie",
180
+ "value": 10
181
+ },
182
+ {
183
+ "source": "Joey",
184
+ "target": "Phoebe",
185
+ "value": 6
186
+ },
187
+ {
188
+ "source": "Joey",
189
+ "target": "Janine",
190
+ "value": 9
191
+ },
192
+ {
193
+ "source": "Phoebe",
194
+ "target": "David",
195
+ "value": 14
196
+ },
197
+ {
198
+ "source": "Phoebe",
199
+ "target": "Gary",
200
+ "value": 7
201
+ },
202
+ {
203
+ "source": "Phoebe",
204
+ "target": "Mike",
205
+ "value": 18
206
+ }
207
+ ]
208
+ }
209
+ ]
210
+ }
211
+ ```