@cdc/map 2.6.2 → 2.6.4

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 (67) hide show
  1. package/dist/cdcmap.js +37 -29
  2. package/examples/bubble-us.json +363 -0
  3. package/examples/bubble-world.json +427 -0
  4. package/examples/default-county.json +105 -0
  5. package/examples/default-hex.json +475 -0
  6. package/examples/default-single-state.json +109 -0
  7. package/examples/default-usa-regions.json +118 -0
  8. package/examples/default-usa.json +744 -603
  9. package/examples/default-world-data.json +1450 -0
  10. package/examples/default-world.json +5 -3
  11. package/examples/example-city-state.json +510 -0
  12. package/examples/example-world-map.json +1596 -0
  13. package/examples/gender-rate-map.json +1 -0
  14. package/examples/private/atsdr.json +439 -0
  15. package/examples/private/atsdr_new.json +436 -0
  16. package/examples/private/bubble.json +285 -0
  17. package/examples/private/default-world-data.json +1444 -0
  18. package/examples/private/default.json +968 -0
  19. package/examples/private/map.csv +60 -0
  20. package/examples/private/mdx.json +210 -0
  21. package/examples/private/regions.json +52 -0
  22. package/examples/private/wcmsrd-13881-data.json +2858 -0
  23. package/examples/private/wcmsrd-13881.json +5823 -0
  24. package/examples/private/wcmsrd-test.json +268 -0
  25. package/examples/private/world.json +1580 -0
  26. package/examples/private/worldmap.json +1490 -0
  27. package/package.json +11 -7
  28. package/src/CdcMap.js +726 -202
  29. package/src/components/BubbleList.js +240 -0
  30. package/src/components/CityList.js +22 -3
  31. package/src/components/CountyMap.js +557 -0
  32. package/src/components/DataTable.js +85 -24
  33. package/src/components/EditorPanel.js +2455 -1204
  34. package/src/components/Geo.js +1 -1
  35. package/src/components/Sidebar.js +5 -5
  36. package/src/components/SingleStateMap.js +326 -0
  37. package/src/components/UsaMap.js +41 -9
  38. package/src/components/UsaRegionMap.js +319 -0
  39. package/src/components/WorldMap.js +112 -35
  40. package/src/data/abbreviations.js +57 -0
  41. package/src/data/country-coordinates.js +250 -0
  42. package/src/data/county-map-halfquality.json +58453 -0
  43. package/src/data/county-map-quarterquality.json +1 -0
  44. package/src/data/county-topo.json +1 -0
  45. package/src/data/dfc-map.json +1 -0
  46. package/src/data/initial-state.js +21 -4
  47. package/src/data/newtest.json +1 -0
  48. package/src/data/state-abbreviations.js +60 -0
  49. package/src/data/state-coordinates.js +55 -0
  50. package/src/data/supported-geos.js +3592 -163
  51. package/src/data/test.json +1 -0
  52. package/src/data/us-regions-topo-2.json +360525 -0
  53. package/src/data/us-regions-topo.json +37894 -0
  54. package/src/hooks/useActiveElement.js +19 -0
  55. package/src/hooks/useColorPalette.ts +96 -0
  56. package/src/index.html +35 -20
  57. package/src/index.js +8 -4
  58. package/src/scss/datatable.scss +2 -1
  59. package/src/scss/editor-panel.scss +76 -55
  60. package/src/scss/main.scss +10 -1
  61. package/src/scss/map.scss +257 -121
  62. package/src/scss/sidebar.scss +0 -1
  63. package/uploads/upload-example-city-state.json +392 -0
  64. package/uploads/upload-example-world-data.json +1490 -0
  65. package/LICENSE +0 -201
  66. package/src/data/color-palettes.js +0 -191
  67. package/src/images/map-folded.svg +0 -1
@@ -0,0 +1,427 @@
1
+ {
2
+ "defaultData": true,
3
+ "general": {
4
+ "title": "Default World Map",
5
+ "subtext": "",
6
+ "type": "bubble",
7
+ "geoType": "world",
8
+ "headerColor": "theme-blue",
9
+ "geoBorderColor": "darkGray",
10
+ "showSidebar": true,
11
+ "showTitle": true,
12
+ "showDownloadButton": true,
13
+ "expandDataTable": true
14
+ },
15
+ "color": "redreverse",
16
+ "columns": {
17
+ "geo": {
18
+ "name": "Country",
19
+ "label": "Location",
20
+ "tooltip": false,
21
+ "dataTable": true
22
+ },
23
+ "primary": {
24
+ "name": "Cases",
25
+ "label": "Total Confirmed Cases",
26
+ "prefix": "",
27
+ "suffix": "",
28
+ "dataTable": true,
29
+ "tooltip": true
30
+ },
31
+ "navigate": {
32
+ "name": "Link",
33
+ "tooltip": false,
34
+ "dataTable": false
35
+ }
36
+ },
37
+ "legend": {
38
+ "numberOfItems": 1,
39
+ "position": "side",
40
+ "title": "Legend Title",
41
+ "description": "Legend Text",
42
+ "type": "equalnumber",
43
+ "specialClasses": [
44
+ "N/A"
45
+ ]
46
+ },
47
+ "data": [
48
+ {
49
+ "Country": "Argentina",
50
+ "Cases": "9",
51
+ "Category": "Has not historically reported monkeypox",
52
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
53
+ },
54
+ {
55
+ "Country": "Australia",
56
+ "Cases": "23",
57
+ "Category": "Has not historically reported monkeypox",
58
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
59
+ },
60
+ {
61
+ "Country": "Austria",
62
+ "Cases": "62",
63
+ "Category": "Has not historically reported monkeypox",
64
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
65
+ },
66
+ {
67
+ "Country": "Bahamas",
68
+ "Cases": "1",
69
+ "Category": "Has not historically reported monkeypox",
70
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
71
+ },
72
+ {
73
+ "Country": "Belgium",
74
+ "Cases": "168",
75
+ "Category": "Has not historically reported monkeypox",
76
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
77
+ },
78
+ {
79
+ "Country": "Benin",
80
+ "Cases": "3",
81
+ "Category": "Has not historically reported monkeypox",
82
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
83
+ },
84
+ {
85
+ "Country": "Brazil",
86
+ "Cases": "218",
87
+ "Category": "Has not historically reported monkeypox",
88
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
89
+ },
90
+ {
91
+ "Country": "Bulgaria",
92
+ "Cases": "3",
93
+ "Category": "Has not historically reported monkeypox",
94
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
95
+ },
96
+ {
97
+ "Country": "Cameroon",
98
+ "Cases": "3",
99
+ "Category": "Has historically reported monkeypox",
100
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
101
+ },
102
+ {
103
+ "Country": "Canada",
104
+ "Cases": "375",
105
+ "Category": "Has not historically reported monkeypox",
106
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
107
+ },
108
+ {
109
+ "Country": "Central African Republic",
110
+ "Cases": "8",
111
+ "Category": "Has historically reported monkeypox",
112
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
113
+ },
114
+ {
115
+ "Country": "Chile",
116
+ "Cases": "13",
117
+ "Category": "Has not historically reported monkeypox",
118
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
119
+ },
120
+ {
121
+ "Country": "Colombia",
122
+ "Cases": "6",
123
+ "Category": "Has not historically reported monkeypox",
124
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
125
+ },
126
+ {
127
+ "Country": "Croatia",
128
+ "Cases": "1",
129
+ "Category": "Has not historically reported monkeypox",
130
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
131
+ },
132
+ {
133
+ "Country": "Czechia",
134
+ "Cases": "11",
135
+ "Category": "Has not historically reported monkeypox",
136
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
137
+ },
138
+ {
139
+ "Country": "Democratic Republic of the Congo",
140
+ "Cases": "107",
141
+ "Category": "Has historically reported monkeypox",
142
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
143
+ },
144
+ {
145
+ "Country": "Denmark",
146
+ "Cases": "29",
147
+ "Category": "Has not historically reported monkeypox",
148
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
149
+ },
150
+ {
151
+ "Country": "Dominican Republic",
152
+ "Cases": "1",
153
+ "Category": "Has not historically reported monkeypox",
154
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
155
+ },
156
+ {
157
+ "Country": "Ecuador",
158
+ "Cases": "1",
159
+ "Category": "Has not historically reported monkeypox",
160
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
161
+ },
162
+ {
163
+ "Country": "Estonia",
164
+ "Cases": "2",
165
+ "Category": "Has not historically reported monkeypox",
166
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
167
+ },
168
+ {
169
+ "Country": "Finland",
170
+ "Cases": "13",
171
+ "Category": "Has not historically reported monkeypox",
172
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
173
+ },
174
+ {
175
+ "Country": "France",
176
+ "Cases": "721",
177
+ "Category": "Has not historically reported monkeypox",
178
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
179
+ },
180
+ {
181
+ "Country": "Georgia",
182
+ "Cases": "1",
183
+ "Category": "Has not historically reported monkeypox",
184
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
185
+ },
186
+ {
187
+ "Country": "Germany",
188
+ "Cases": "1556",
189
+ "Category": "Has not historically reported monkeypox",
190
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
191
+ },
192
+ {
193
+ "Country": "Ghana",
194
+ "Cases": "19",
195
+ "Category": "Has historically reported monkeypox",
196
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
197
+ },
198
+ {
199
+ "Country": "Gibraltar",
200
+ "Cases": "1",
201
+ "Category": "Has not historically reported monkeypox",
202
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
203
+ },
204
+ {
205
+ "Country": "Greece",
206
+ "Cases": "11",
207
+ "Category": "Has not historically reported monkeypox",
208
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
209
+ },
210
+ {
211
+ "Country": "Hungary",
212
+ "Cases": "24",
213
+ "Category": "Has not historically reported monkeypox",
214
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
215
+ },
216
+ {
217
+ "Country": "Iceland",
218
+ "Cases": "6",
219
+ "Category": "Has not historically reported monkeypox",
220
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
221
+ },
222
+ {
223
+ "Country": "Ireland",
224
+ "Cases": "44",
225
+ "Category": "Has not historically reported monkeypox",
226
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
227
+ },
228
+ {
229
+ "Country": "Israel",
230
+ "Cases": "66",
231
+ "Category": "Has not historically reported monkeypox",
232
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
233
+ },
234
+ {
235
+ "Country": "Italy",
236
+ "Cases": "255",
237
+ "Category": "Has not historically reported monkeypox",
238
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
239
+ },
240
+ {
241
+ "Country": "Jamaica",
242
+ "Cases": "1",
243
+ "Category": "Has not historically reported monkeypox",
244
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
245
+ },
246
+ {
247
+ "Country": "Latvia",
248
+ "Cases": "2",
249
+ "Category": "Has not historically reported monkeypox",
250
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
251
+ },
252
+ {
253
+ "Country": "Lebanon",
254
+ "Cases": "1",
255
+ "Category": "Has not historically reported monkeypox",
256
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
257
+ },
258
+ {
259
+ "Country": "Luxembourg",
260
+ "Cases": "6",
261
+ "Category": "Has not historically reported monkeypox",
262
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
263
+ },
264
+ {
265
+ "Country": "Malta",
266
+ "Cases": "8",
267
+ "Category": "Has not historically reported monkeypox",
268
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
269
+ },
270
+ {
271
+ "Country": "Mexico",
272
+ "Cases": "35",
273
+ "Category": "Has not historically reported monkeypox",
274
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
275
+ },
276
+ {
277
+ "Country": "Morocco",
278
+ "Cases": "1",
279
+ "Category": "Has not historically reported monkeypox",
280
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
281
+ },
282
+ {
283
+ "Country": "Netherlands",
284
+ "Cases": "503",
285
+ "Category": "Has not historically reported monkeypox",
286
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
287
+ },
288
+ {
289
+ "Country": "Nigeria",
290
+ "Cases": "84",
291
+ "Category": "Has historically reported monkeypox",
292
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
293
+ },
294
+ {
295
+ "Country": "Norway",
296
+ "Cases": "19",
297
+ "Category": "Has not historically reported monkeypox",
298
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
299
+ },
300
+ {
301
+ "Country": "Panama",
302
+ "Cases": "1",
303
+ "Category": "Has not historically reported monkeypox",
304
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
305
+ },
306
+ {
307
+ "Country": "Peru",
308
+ "Cases": "18",
309
+ "Category": "Has not historically reported monkeypox",
310
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
311
+ },
312
+ {
313
+ "Country": "Poland",
314
+ "Cases": "19",
315
+ "Category": "Has not historically reported monkeypox",
316
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
317
+ },
318
+ {
319
+ "Country": "Portugal",
320
+ "Cases": "473",
321
+ "Category": "Has not historically reported monkeypox",
322
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
323
+ },
324
+ {
325
+ "Country": "Republic of the Congo",
326
+ "Cases": "2",
327
+ "Category": "Has historically reported monkeypox",
328
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
329
+ },
330
+ {
331
+ "Country": "Romania",
332
+ "Cases": "14",
333
+ "Category": "Has not historically reported monkeypox",
334
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
335
+ },
336
+ {
337
+ "Country": "Serbia",
338
+ "Cases": "1",
339
+ "Category": "Has not historically reported monkeypox",
340
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
341
+ },
342
+ {
343
+ "Country": "Singapore",
344
+ "Cases": "2",
345
+ "Category": "Has not historically reported monkeypox",
346
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
347
+ },
348
+ {
349
+ "Country": "Slovakia",
350
+ "Cases": "1",
351
+ "Category": "Has not historically reported monkeypox",
352
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
353
+ },
354
+ {
355
+ "Country": "Slovenia",
356
+ "Cases": "18",
357
+ "Category": "Has not historically reported monkeypox",
358
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
359
+ },
360
+ {
361
+ "Country": "South Africa",
362
+ "Cases": "3",
363
+ "Category": "Has not historically reported monkeypox",
364
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
365
+ },
366
+ {
367
+ "Country": "South Korea",
368
+ "Cases": "1",
369
+ "Category": "Has not historically reported monkeypox",
370
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
371
+ },
372
+ {
373
+ "Country": "Spain",
374
+ "Cases": "2034",
375
+ "Category": "Has not historically reported monkeypox",
376
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
377
+ },
378
+ {
379
+ "Country": "Sweden",
380
+ "Cases": "43",
381
+ "Category": "Has not historically reported monkeypox",
382
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
383
+ },
384
+ {
385
+ "Country": "Switzerland",
386
+ "Cases": "163",
387
+ "Category": "Has not historically reported monkeypox",
388
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
389
+ },
390
+ {
391
+ "Country": "Taiwan",
392
+ "Cases": "1",
393
+ "Category": "Has not historically reported monkeypox",
394
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
395
+ },
396
+ {
397
+ "Country": "Turkey",
398
+ "Cases": "1",
399
+ "Category": "Has not historically reported monkeypox",
400
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
401
+ },
402
+ {
403
+ "Country": "United Arab Emirates",
404
+ "Cases": "13",
405
+ "Category": "Has not historically reported monkeypox",
406
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
407
+ },
408
+ {
409
+ "Country": "United Kingdom",
410
+ "Cases": "1552",
411
+ "Category": "Has not historically reported monkeypox",
412
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
413
+ },
414
+ {
415
+ "Country": "United States",
416
+ "Cases": "0",
417
+ "Category": "Has not historically reported monkeypox",
418
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
419
+ },
420
+ {
421
+ "Country": "Venezuela",
422
+ "Cases": "1",
423
+ "Category": "Has not historically reported monkeypox",
424
+ "AsOf": "11 Jul 2022 5:00 PM EDT"
425
+ }
426
+ ]
427
+ }
@@ -0,0 +1,105 @@
1
+ {
2
+ "type": "map",
3
+ "general": {
4
+ "title": "Default County Map",
5
+ "subtext": "",
6
+ "territoriesLabel": "Territories",
7
+ "type": "map",
8
+ "geoType": "us-county",
9
+ "headerColor": "theme-blue",
10
+ "showSidebar": true,
11
+ "showTitle": true,
12
+ "geoBorderColor": "darkGray",
13
+ "showDownloadButton": true,
14
+ "expandDataTable": false
15
+ },
16
+ "color": "pinkpurple",
17
+ "columns": {
18
+ "geo": {
19
+ "name": "FIPS Codes",
20
+ "label": "Location",
21
+ "tooltip": false,
22
+ "dataTable": true
23
+ },
24
+ "primary": {
25
+ "name": "Insured Rate",
26
+ "label": "Data Label",
27
+ "prefix": "",
28
+ "suffix": "%",
29
+ "dataTable": true,
30
+ "tooltip": true
31
+ },
32
+ "navigate": {
33
+ "name": "",
34
+ "tooltip": false,
35
+ "dataTable": false
36
+ }
37
+ },
38
+ "legend": {
39
+ "numberOfItems": 3,
40
+ "position": "side",
41
+ "title": "Legend Title",
42
+ "description": "Legend Text",
43
+ "type": "equalnumber",
44
+ "specialClasses": ["N/A"]
45
+ },
46
+ "filters": [],
47
+ "data": [
48
+ {
49
+ "Insured Rate": "8",
50
+ "Coverage Status": "Insured",
51
+ "FIPS Codes": "06071",
52
+ "Year (Good filter option)": "2010",
53
+ "link": ""
54
+ },
55
+ {
56
+ "Insured Rate": "25",
57
+ "Coverage Status": "Insured",
58
+ "FIPS Codes": "55005",
59
+ "Year (Good filter option)": "2010",
60
+ "link": "https://cdc.gov"
61
+ },
62
+ {
63
+ "Insured Rate": "25",
64
+ "Coverage Status": "Insured",
65
+ "FIPS Codes": "12103",
66
+ "Year (Good filter option)": "2010",
67
+ "link": ""
68
+ },
69
+ {
70
+ "Insured Rate": "25",
71
+ "Coverage Status": "Insured",
72
+ "FIPS Codes": "32005",
73
+ "Year (Good filter option)": "2010",
74
+ "link": ""
75
+ },
76
+ {
77
+ "Insured Rate": "18",
78
+ "Coverage Status": "Insured",
79
+ "FIPS Codes": "06075",
80
+ "Year (Good filter option)": "2010",
81
+ "link": ""
82
+ },
83
+ {
84
+ "Insured Rate": "3",
85
+ "Coverage Status": "Insured",
86
+ "FIPS Codes": "06027",
87
+ "Year (Good filter option)": "2010",
88
+ "link": ""
89
+ },
90
+ {
91
+ "Insured Rate": "25",
92
+ "Coverage Status": "Insured",
93
+ "FIPS Codes": "06029",
94
+ "Year (Good filter option)": "2010",
95
+ "link": ""
96
+ },
97
+ {
98
+ "Insured Rate": "60",
99
+ "Coverage Status": "Insured",
100
+ "FIPS Codes": "06065",
101
+ "Year (Good filter option)": "2010",
102
+ "link": ""
103
+ }
104
+ ]
105
+ }