| 1 |
{ |
| 2 |
"$schema": "https://schemas.wp.org/trunk/block.json", |
| 3 |
"apiVersion": 3, |
| 4 |
"name": "blockenberg/dot-plot", |
| 5 |
"title": "Dot Plot", |
| 6 |
"category": "bkbg-charts", |
| 7 |
"icon": "chart-area", |
| 8 |
"description": "Strip / scatter dot plot showing individual data points for each series along a shared axis — ideal for comparing distributions.", |
| 9 |
"attributes": { |
| 10 |
"title": { |
| 11 |
"type": "string", |
| 12 |
"default": "Response Times by Team (ms)" |
| 13 |
}, |
| 14 |
"showTitle": { |
| 15 |
"type": "boolean", |
| 16 |
"default": true |
| 17 |
}, |
| 18 |
"svgWidth": { |
| 19 |
"type": "integer", |
| 20 |
"default": 700 |
| 21 |
}, |
| 22 |
"svgHeight": { |
| 23 |
"type": "integer", |
| 24 |
"default": 320 |
| 25 |
}, |
| 26 |
"padTop": { |
| 27 |
"type": "integer", |
| 28 |
"default": 36 |
| 29 |
}, |
| 30 |
"padLeft": { |
| 31 |
"type": "integer", |
| 32 |
"default": 130 |
| 33 |
}, |
| 34 |
"padRight": { |
| 35 |
"type": "integer", |
| 36 |
"default": 30 |
| 37 |
}, |
| 38 |
"padBottom": { |
| 39 |
"type": "integer", |
| 40 |
"default": 46 |
| 41 |
}, |
| 42 |
"dotRadius": { |
| 43 |
"type": "integer", |
| 44 |
"default": 7 |
| 45 |
}, |
| 46 |
"dotOpacity": { |
| 47 |
"type": "integer", |
| 48 |
"default": 75 |
| 49 |
}, |
| 50 |
"jitter": { |
| 51 |
"type": "integer", |
| 52 |
"default": 12 |
| 53 |
}, |
| 54 |
"showGridLines": { |
| 55 |
"type": "boolean", |
| 56 |
"default": true |
| 57 |
}, |
| 58 |
"showMeanLine": { |
| 59 |
"type": "boolean", |
| 60 |
"default": true |
| 61 |
}, |
| 62 |
"showLegend": { |
| 63 |
"type": "boolean", |
| 64 |
"default": true |
| 65 |
}, |
| 66 |
"labelFontSize": { |
| 67 |
"type": "integer", |
| 68 |
"default": 13 |
| 69 |
}, |
| 70 |
"labelFontWeight": { |
| 71 |
"type": "string", |
| 72 |
"default": "400" |
| 73 |
}, |
| 74 |
"axisFontSize": { |
| 75 |
"type": "integer", |
| 76 |
"default": 11 |
| 77 |
}, |
| 78 |
"axisFontWeight": { |
| 79 |
"type": "string", |
| 80 |
"default": "400" |
| 81 |
}, |
| 82 |
"titleFontSize": { |
| 83 |
"type": "integer", |
| 84 |
"default": 18 |
| 85 |
}, |
| 86 |
"titleFontWeight": { |
| 87 |
"type": "string", |
| 88 |
"default": "700" |
| 89 |
}, |
| 90 |
"bgColor": { |
| 91 |
"type": "string", |
| 92 |
"default": "#ffffff" |
| 93 |
}, |
| 94 |
"gridColor": { |
| 95 |
"type": "string", |
| 96 |
"default": "#f3f4f6" |
| 97 |
}, |
| 98 |
"titleColor": { |
| 99 |
"type": "string", |
| 100 |
"default": "#111827" |
| 101 |
}, |
| 102 |
"textColor": { |
| 103 |
"type": "string", |
| 104 |
"default": "#374151" |
| 105 |
}, |
| 106 |
"typoTitle": { |
| 107 |
"type": "object", |
| 108 |
"default": {} |
| 109 |
}, |
| 110 |
"series": { |
| 111 |
"type": "array", |
| 112 |
"default": [ |
| 113 |
{ |
| 114 |
"label": "Team Alpha", |
| 115 |
"color": "#6366f1", |
| 116 |
"points": [ |
| 117 |
120, |
| 118 |
145, |
| 119 |
98, |
| 120 |
210, |
| 121 |
133, |
| 122 |
158, |
| 123 |
175, |
| 124 |
102, |
| 125 |
190, |
| 126 |
141 |
| 127 |
] |
| 128 |
}, |
| 129 |
{ |
| 130 |
"label": "Team Beta", |
| 131 |
"color": "#10b981", |
| 132 |
"points": [ |
| 133 |
230, |
| 134 |
195, |
| 135 |
260, |
| 136 |
212, |
| 137 |
248, |
| 138 |
189, |
| 139 |
275, |
| 140 |
221, |
| 141 |
204, |
| 142 |
237 |
| 143 |
] |
| 144 |
}, |
| 145 |
{ |
| 146 |
"label": "Team Gamma", |
| 147 |
"color": "#f59e0b", |
| 148 |
"points": [ |
| 149 |
85, |
| 150 |
92, |
| 151 |
78, |
| 152 |
105, |
| 153 |
88, |
| 154 |
71, |
| 155 |
99, |
| 156 |
83, |
| 157 |
115, |
| 158 |
76 |
| 159 |
] |
| 160 |
} |
| 161 |
] |
| 162 |
} |
| 163 |
}, |
| 164 |
"supports": { |
| 165 |
"align": [ |
| 166 |
"wide", |
| 167 |
"full" |
| 168 |
] |
| 169 |
}, |
| 170 |
"editorScript": "bkbg-dot-plot-editor", |
| 171 |
"style": "bkbg-dot-plot-style" |
| 172 |
} |
| 173 |
|