| 1 |
{ |
| 2 |
"apiVersion": 3, |
| 3 |
"$schema": "https://schemas.wp.org/trunk/block.json", |
| 4 |
"name": "blockenberg/survey-results", |
| 5 |
"title": "Survey Results", |
| 6 |
"description": "Display survey data with percentage bars, charts, and methodology notes.", |
| 7 |
"category": "bkbg-blog", |
| 8 |
"icon": "chart-bar", |
| 9 |
"keywords": [ |
| 10 |
"survey", |
| 11 |
"poll", |
| 12 |
"results", |
| 13 |
"chart", |
| 14 |
"statistics", |
| 15 |
"data" |
| 16 |
], |
| 17 |
"textdomain": "blockenberg", |
| 18 |
"editorScript": "bkbg-survey-results-editor", |
| 19 |
"editorStyle": "bkbg-survey-results-style", |
| 20 |
"style": "bkbg-survey-results-style", |
| 21 |
"viewScript": "bkbg-survey-results-frontend", |
| 22 |
"supports": { |
| 23 |
"html": false, |
| 24 |
"anchor": true, |
| 25 |
"className": true, |
| 26 |
"align": [ |
| 27 |
"wide", |
| 28 |
"full" |
| 29 |
] |
| 30 |
}, |
| 31 |
"attributes": { |
| 32 |
"surveyTitle": { |
| 33 |
"type": "string", |
| 34 |
"default": "Developer Experience Survey 2026" |
| 35 |
}, |
| 36 |
"organization": { |
| 37 |
"type": "string", |
| 38 |
"default": "Stack Overflow" |
| 39 |
}, |
| 40 |
"respondents": { |
| 41 |
"type": "number", |
| 42 |
"default": 89000 |
| 43 |
}, |
| 44 |
"respondentsLabel": { |
| 45 |
"type": "string", |
| 46 |
"default": "respondents" |
| 47 |
}, |
| 48 |
"surveyDate": { |
| 49 |
"type": "string", |
| 50 |
"default": "January 2026" |
| 51 |
}, |
| 52 |
"showMeta": { |
| 53 |
"type": "boolean", |
| 54 |
"default": true |
| 55 |
}, |
| 56 |
"questions": { |
| 57 |
"type": "array", |
| 58 |
"default": [ |
| 59 |
{ |
| 60 |
"question": "What is your primary programming language?", |
| 61 |
"options": [ |
| 62 |
{ |
| 63 |
"label": "JavaScript", |
| 64 |
"percent": 63, |
| 65 |
"count": 56070 |
| 66 |
}, |
| 67 |
{ |
| 68 |
"label": "Python", |
| 69 |
"percent": 51, |
| 70 |
"count": 45390 |
| 71 |
}, |
| 72 |
{ |
| 73 |
"label": "TypeScript", |
| 74 |
"percent": 38, |
| 75 |
"count": 33820 |
| 76 |
}, |
| 77 |
{ |
| 78 |
"label": "Rust", |
| 79 |
"percent": 13, |
| 80 |
"count": 11570 |
| 81 |
} |
| 82 |
] |
| 83 |
}, |
| 84 |
{ |
| 85 |
"question": "Do you use AI coding tools (Copilot, Cursor, etc.)?", |
| 86 |
"options": [ |
| 87 |
{ |
| 88 |
"label": "Yes, daily", |
| 89 |
"percent": 44, |
| 90 |
"count": 39160 |
| 91 |
}, |
| 92 |
{ |
| 93 |
"label": "Yes, occasionally", |
| 94 |
"percent": 28, |
| 95 |
"count": 24920 |
| 96 |
}, |
| 97 |
{ |
| 98 |
"label": "No, but I plan to", |
| 99 |
"percent": 17, |
| 100 |
"count": 15130 |
| 101 |
}, |
| 102 |
{ |
| 103 |
"label": "No", |
| 104 |
"percent": 11, |
| 105 |
"count": 9790 |
| 106 |
} |
| 107 |
] |
| 108 |
}, |
| 109 |
{ |
| 110 |
"question": "How satisfied are you with your current tech stack?", |
| 111 |
"options": [ |
| 112 |
{ |
| 113 |
"label": "Very satisfied", |
| 114 |
"percent": 34, |
| 115 |
"count": 30260 |
| 116 |
}, |
| 117 |
{ |
| 118 |
"label": "Somewhat satisfied", |
| 119 |
"percent": 42, |
| 120 |
"count": 37380 |
| 121 |
}, |
| 122 |
{ |
| 123 |
"label": "Neutral", |
| 124 |
"percent": 15, |
| 125 |
"count": 13350 |
| 126 |
}, |
| 127 |
{ |
| 128 |
"label": "Dissatisfied", |
| 129 |
"percent": 9, |
| 130 |
"count": 8010 |
| 131 |
} |
| 132 |
] |
| 133 |
} |
| 134 |
] |
| 135 |
}, |
| 136 |
"showPercentages": { |
| 137 |
"type": "boolean", |
| 138 |
"default": true |
| 139 |
}, |
| 140 |
"showCounts": { |
| 141 |
"type": "boolean", |
| 142 |
"default": false |
| 143 |
}, |
| 144 |
"showBars": { |
| 145 |
"type": "boolean", |
| 146 |
"default": true |
| 147 |
}, |
| 148 |
"highlightWinner": { |
| 149 |
"type": "boolean", |
| 150 |
"default": true |
| 151 |
}, |
| 152 |
"methodology": { |
| 153 |
"type": "string", |
| 154 |
"default": "Online survey conducted among registered developers. Respondents could select multiple answers where applicable. Percentages may exceed 100% for multi-select questions." |
| 155 |
}, |
| 156 |
"showMethodology": { |
| 157 |
"type": "boolean", |
| 158 |
"default": true |
| 159 |
}, |
| 160 |
"titleTypo": { |
| 161 |
"type": "object", |
| 162 |
"default": {} |
| 163 |
}, |
| 164 |
"textTypo": { |
| 165 |
"type": "object", |
| 166 |
"default": {} |
| 167 |
}, |
| 168 |
"borderRadius": { |
| 169 |
"type": "number", |
| 170 |
"default": 12 |
| 171 |
}, |
| 172 |
"barHeight": { |
| 173 |
"type": "number", |
| 174 |
"default": 10 |
| 175 |
}, |
| 176 |
"bgColor": { |
| 177 |
"type": "string", |
| 178 |
"default": "#ffffff" |
| 179 |
}, |
| 180 |
"borderColor": { |
| 181 |
"type": "string", |
| 182 |
"default": "#e5e7eb" |
| 183 |
}, |
| 184 |
"headerBg": { |
| 185 |
"type": "string", |
| 186 |
"default": "#0f172a" |
| 187 |
}, |
| 188 |
"headerColor": { |
| 189 |
"type": "string", |
| 190 |
"default": "#ffffff" |
| 191 |
}, |
| 192 |
"metaColor": { |
| 193 |
"type": "string", |
| 194 |
"default": "#94a3b8" |
| 195 |
}, |
| 196 |
"questionColor": { |
| 197 |
"type": "string", |
| 198 |
"default": "#111827" |
| 199 |
}, |
| 200 |
"labelColor": { |
| 201 |
"type": "string", |
| 202 |
"default": "#374151" |
| 203 |
}, |
| 204 |
"percentColor": { |
| 205 |
"type": "string", |
| 206 |
"default": "#111827" |
| 207 |
}, |
| 208 |
"countColor": { |
| 209 |
"type": "string", |
| 210 |
"default": "#6b7280" |
| 211 |
}, |
| 212 |
"barBg": { |
| 213 |
"type": "string", |
| 214 |
"default": "#f1f5f9" |
| 215 |
}, |
| 216 |
"barFill": { |
| 217 |
"type": "string", |
| 218 |
"default": "#3b82f6" |
| 219 |
}, |
| 220 |
"barFillWinner": { |
| 221 |
"type": "string", |
| 222 |
"default": "#1d4ed8" |
| 223 |
}, |
| 224 |
"winnerBg": { |
| 225 |
"type": "string", |
| 226 |
"default": "#eff6ff" |
| 227 |
}, |
| 228 |
"methodologyBg": { |
| 229 |
"type": "string", |
| 230 |
"default": "#f8fafc" |
| 231 |
}, |
| 232 |
"methodologyColor": { |
| 233 |
"type": "string", |
| 234 |
"default": "#6b7280" |
| 235 |
} |
| 236 |
} |
| 237 |
} |
| 238 |
|