@cdc/map 4.24.12 → 4.25.2-25
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.
- package/dist/cdcmap.js +50119 -48822
- package/examples/annotation/index.json +1 -1
- package/examples/custom-map-layers.json +1 -1
- package/examples/default-geocode.json +2 -2
- package/examples/example-city-state.json +1 -1
- package/examples/private/DEV-9989.json +229 -0
- package/examples/private/ardi.json +180 -0
- package/examples/private/colors 2.json +416 -0
- package/examples/private/colors.json +416 -0
- package/examples/private/colors.json.zip +0 -0
- package/examples/private/customColors.json +45348 -0
- package/examples/private/mmr.json +246 -0
- package/examples/private/test.json +1632 -0
- package/index.html +12 -14
- package/package.json +8 -3
- package/src/CdcMap.tsx +126 -396
- package/src/_stories/CdcMap.Filters.stories.tsx +19 -0
- package/src/_stories/CdcMap.Legend.Gradient.stories.tsx +9 -0
- package/src/_stories/CdcMap.stories.tsx +1 -1
- package/src/_stories/GoogleMap.stories.tsx +19 -0
- package/src/_stories/_mock/DEV-10148.json +859 -0
- package/src/_stories/_mock/DEV-9989.json +229 -0
- package/src/_stories/_mock/example-city-state.json +1 -1
- package/src/_stories/_mock/google-map.json +819 -0
- package/src/_stories/_mock/wastewater-map.json +210 -206
- package/src/components/Annotation/Annotation.Draggable.tsx +34 -43
- package/src/components/Annotation/AnnotationDropdown.tsx +4 -4
- package/src/components/CityList.tsx +3 -9
- package/src/components/DataTable.tsx +8 -9
- package/src/components/EditorPanel/components/EditorPanel.tsx +255 -490
- package/src/components/GoogleMap/components/GoogleMap.tsx +67 -0
- package/src/components/GoogleMap/index.tsx +3 -0
- package/src/components/Legend/components/Legend.tsx +40 -30
- package/src/components/Legend/components/LegendItem.Hex.tsx +7 -3
- package/src/components/Legend/components/index.scss +22 -16
- package/src/components/Modal.tsx +6 -5
- package/src/components/NavigationMenu.tsx +4 -3
- package/src/components/UsaMap/components/TerritoriesSection.tsx +66 -0
- package/src/components/UsaMap/components/Territory/Territory.Hexagon.tsx +15 -16
- package/src/components/UsaMap/components/Territory/Territory.Rectangle.tsx +3 -3
- package/src/components/UsaMap/components/UsaMap.County.tsx +1 -1
- package/src/components/UsaMap/components/UsaMap.Region.tsx +12 -8
- package/src/components/UsaMap/components/UsaMap.SingleState.tsx +2 -2
- package/src/components/UsaMap/components/UsaMap.State.tsx +23 -29
- package/src/components/WorldMap/WorldMap.tsx +3 -5
- package/src/context.ts +0 -12
- package/src/data/initial-state.js +2 -2
- package/src/data/supported-geos.js +23 -3
- package/src/helpers/applyColorToLegend.ts +3 -3
- package/src/helpers/closeModal.ts +9 -0
- package/src/helpers/handleMapAriaLabels.ts +38 -0
- package/src/helpers/indexOfIgnoreType.ts +8 -0
- package/src/helpers/navigationHandler.ts +21 -0
- package/src/helpers/toTitleCase.ts +44 -0
- package/src/helpers/validateFipsCodeLength.ts +30 -0
- package/src/hooks/useResizeObserver.ts +42 -0
- package/src/hooks/useTooltip.ts +4 -2
- package/src/index.jsx +1 -0
- package/src/scss/editor-panel.scss +2 -1
- package/src/scss/filters.scss +0 -5
- package/src/scss/main.scss +57 -61
- package/src/scss/map.scss +1 -13
- package/src/types/MapConfig.ts +20 -11
- package/src/types/MapContext.ts +4 -12
|
@@ -0,0 +1,416 @@
|
|
|
1
|
+
{
|
|
2
|
+
"general": {
|
|
3
|
+
"geoType": "us",
|
|
4
|
+
"geoBorderColor": "darkGray",
|
|
5
|
+
"showTitle": false,
|
|
6
|
+
"showSidebar": true,
|
|
7
|
+
"showDownloadButton": false,
|
|
8
|
+
"showDownloadMediaButton": false,
|
|
9
|
+
"displayAsHex": true,
|
|
10
|
+
"displayStateLabels": false,
|
|
11
|
+
"territoriesLabel": "Territories",
|
|
12
|
+
"language": "en",
|
|
13
|
+
"hasRegions": false,
|
|
14
|
+
"expandDataTable": false,
|
|
15
|
+
"fullBorder": false,
|
|
16
|
+
"type": "data",
|
|
17
|
+
"palette": {
|
|
18
|
+
"isReversed": true
|
|
19
|
+
},
|
|
20
|
+
"statePicked": {
|
|
21
|
+
"fipsCode": "01",
|
|
22
|
+
"stateName": "Alabama"
|
|
23
|
+
},
|
|
24
|
+
"territoriesAlwaysShow": false,
|
|
25
|
+
"geoLabelOverride": "",
|
|
26
|
+
"convertFipsCodes": true,
|
|
27
|
+
"allowMapZoom": true,
|
|
28
|
+
"hideGeoColumnInTooltip": false,
|
|
29
|
+
"hidePrimaryColumnInTooltip": false,
|
|
30
|
+
"superTitle": "",
|
|
31
|
+
"noStateFoundMessage": "Map Unavailable",
|
|
32
|
+
"annotationDropdownText": "Annotations",
|
|
33
|
+
"headerColor": "theme-blue",
|
|
34
|
+
"title": ""
|
|
35
|
+
},
|
|
36
|
+
"type": "map",
|
|
37
|
+
"customColors": [
|
|
38
|
+
"#edf8fb",
|
|
39
|
+
"#b3cde3",
|
|
40
|
+
"#8c96c6",
|
|
41
|
+
"#8856a7",
|
|
42
|
+
"#810f7c"
|
|
43
|
+
],
|
|
44
|
+
"columns": {
|
|
45
|
+
"geo": {
|
|
46
|
+
"name": "state",
|
|
47
|
+
"label": "Location",
|
|
48
|
+
"tooltip": false,
|
|
49
|
+
"dataTable": true
|
|
50
|
+
},
|
|
51
|
+
"primary": {
|
|
52
|
+
"dataTable": true,
|
|
53
|
+
"tooltip": true,
|
|
54
|
+
"prefix": "",
|
|
55
|
+
"suffix": "%",
|
|
56
|
+
"name": "value",
|
|
57
|
+
"label": ""
|
|
58
|
+
},
|
|
59
|
+
"navigate": {
|
|
60
|
+
"name": ""
|
|
61
|
+
},
|
|
62
|
+
"latitude": {
|
|
63
|
+
"name": ""
|
|
64
|
+
},
|
|
65
|
+
"longitude": {
|
|
66
|
+
"name": ""
|
|
67
|
+
}
|
|
68
|
+
},
|
|
69
|
+
"legend": {
|
|
70
|
+
"descriptions": {},
|
|
71
|
+
"specialClasses": [],
|
|
72
|
+
"unified": false,
|
|
73
|
+
"singleColumn": false,
|
|
74
|
+
"dynamicDescription": false,
|
|
75
|
+
"type": "equalnumber",
|
|
76
|
+
"numberOfItems": 5,
|
|
77
|
+
"position": "side",
|
|
78
|
+
"title": "Legend",
|
|
79
|
+
"singleRow": false,
|
|
80
|
+
"verticalSorted": false,
|
|
81
|
+
"showSpecialClassesLast": false,
|
|
82
|
+
"style": "circles",
|
|
83
|
+
"subStyle": "linear blocks",
|
|
84
|
+
"tickRotation": "",
|
|
85
|
+
"singleColumnLegend": false,
|
|
86
|
+
"hideBorder": false
|
|
87
|
+
},
|
|
88
|
+
"filters": [],
|
|
89
|
+
"table": {
|
|
90
|
+
"wrapColumns": false,
|
|
91
|
+
"label": "Data Table",
|
|
92
|
+
"expanded": false,
|
|
93
|
+
"limitHeight": false,
|
|
94
|
+
"height": "",
|
|
95
|
+
"caption": "",
|
|
96
|
+
"showDownloadUrl": false,
|
|
97
|
+
"showDataTableLink": false,
|
|
98
|
+
"showFullGeoNameInCSV": false,
|
|
99
|
+
"forceDisplay": false,
|
|
100
|
+
"download": true,
|
|
101
|
+
"indexLabel": "",
|
|
102
|
+
"showDownloadLinkBelow": true
|
|
103
|
+
},
|
|
104
|
+
"tooltips": {
|
|
105
|
+
"appearanceType": "hover",
|
|
106
|
+
"linkLabel": "Learn More",
|
|
107
|
+
"capitalizeLabels": true,
|
|
108
|
+
"opacity": 90
|
|
109
|
+
},
|
|
110
|
+
"visual": {
|
|
111
|
+
"minBubbleSize": 1,
|
|
112
|
+
"maxBubbleSize": 20,
|
|
113
|
+
"extraBubbleBorder": false,
|
|
114
|
+
"cityStyle": "circle",
|
|
115
|
+
"cityStyleLabel": "",
|
|
116
|
+
"showBubbleZeros": false,
|
|
117
|
+
"additionalCityStyles": [],
|
|
118
|
+
"geoCodeCircleSize": 8
|
|
119
|
+
},
|
|
120
|
+
"mapPosition": {
|
|
121
|
+
"coordinates": [
|
|
122
|
+
0,
|
|
123
|
+
30
|
|
124
|
+
],
|
|
125
|
+
"zoom": 1
|
|
126
|
+
},
|
|
127
|
+
"map": {
|
|
128
|
+
"layers": [],
|
|
129
|
+
"patterns": []
|
|
130
|
+
},
|
|
131
|
+
"filterBehavior": "Filter Change",
|
|
132
|
+
"dataTable": {
|
|
133
|
+
"title": "Data Table",
|
|
134
|
+
"forceDisplay": true,
|
|
135
|
+
"caption": "Lorem Ipsum - Text added to Data Table Caption",
|
|
136
|
+
"limitHeight": true,
|
|
137
|
+
"height": "100"
|
|
138
|
+
},
|
|
139
|
+
"orientation": null,
|
|
140
|
+
"visualizationSubType": null,
|
|
141
|
+
"validated": "4.24.3",
|
|
142
|
+
"data": [
|
|
143
|
+
{
|
|
144
|
+
"state": "Alabama",
|
|
145
|
+
"stratification": "Total",
|
|
146
|
+
"value": "33.7"
|
|
147
|
+
},
|
|
148
|
+
{
|
|
149
|
+
"state": "Connecticut",
|
|
150
|
+
"stratification": "Total",
|
|
151
|
+
"value": "35.6"
|
|
152
|
+
},
|
|
153
|
+
{
|
|
154
|
+
"state": "Alaska",
|
|
155
|
+
"stratification": "Total",
|
|
156
|
+
"value": "36.4"
|
|
157
|
+
},
|
|
158
|
+
{
|
|
159
|
+
"state": "Arkansas",
|
|
160
|
+
"stratification": "Total",
|
|
161
|
+
"value": "33.6"
|
|
162
|
+
},
|
|
163
|
+
{
|
|
164
|
+
"state": "Arizona",
|
|
165
|
+
"stratification": "Total",
|
|
166
|
+
"value": "33.5"
|
|
167
|
+
},
|
|
168
|
+
{
|
|
169
|
+
"state": "California",
|
|
170
|
+
"stratification": "Total",
|
|
171
|
+
"value": "34.7"
|
|
172
|
+
},
|
|
173
|
+
{
|
|
174
|
+
"state": "Colorado",
|
|
175
|
+
"stratification": "Total",
|
|
176
|
+
"value": "35.6"
|
|
177
|
+
},
|
|
178
|
+
{
|
|
179
|
+
"state": "District of Columbia",
|
|
180
|
+
"stratification": "Total",
|
|
181
|
+
"value": "30.9"
|
|
182
|
+
},
|
|
183
|
+
{
|
|
184
|
+
"state": "Delaware",
|
|
185
|
+
"stratification": "Total",
|
|
186
|
+
"value": "33.9"
|
|
187
|
+
},
|
|
188
|
+
{
|
|
189
|
+
"state": "Florida",
|
|
190
|
+
"stratification": "Total",
|
|
191
|
+
"value": "34.5"
|
|
192
|
+
},
|
|
193
|
+
{
|
|
194
|
+
"state": "Texas",
|
|
195
|
+
"stratification": "Total",
|
|
196
|
+
"value": "34.7"
|
|
197
|
+
},
|
|
198
|
+
{
|
|
199
|
+
"state": "Georgia",
|
|
200
|
+
"stratification": "Total",
|
|
201
|
+
"value": "31.9"
|
|
202
|
+
},
|
|
203
|
+
{
|
|
204
|
+
"state": "Guam",
|
|
205
|
+
"stratification": "Total",
|
|
206
|
+
"value": "34.5"
|
|
207
|
+
},
|
|
208
|
+
{
|
|
209
|
+
"state": "Hawaii",
|
|
210
|
+
"stratification": "Total",
|
|
211
|
+
"value": "33.8"
|
|
212
|
+
},
|
|
213
|
+
{
|
|
214
|
+
"state": "Iowa",
|
|
215
|
+
"stratification": "Total",
|
|
216
|
+
"value": "33.8"
|
|
217
|
+
},
|
|
218
|
+
{
|
|
219
|
+
"state": "Idaho",
|
|
220
|
+
"stratification": "Total",
|
|
221
|
+
"value": "35.4"
|
|
222
|
+
},
|
|
223
|
+
{
|
|
224
|
+
"state": "Illinois",
|
|
225
|
+
"stratification": "Total",
|
|
226
|
+
"value": "33.9"
|
|
227
|
+
},
|
|
228
|
+
{
|
|
229
|
+
"state": "Indiana",
|
|
230
|
+
"stratification": "Total",
|
|
231
|
+
"value": "33.3"
|
|
232
|
+
},
|
|
233
|
+
{
|
|
234
|
+
"state": "Kansas",
|
|
235
|
+
"stratification": "Total",
|
|
236
|
+
"value": "33.4"
|
|
237
|
+
},
|
|
238
|
+
{
|
|
239
|
+
"state": "Kentucky",
|
|
240
|
+
"stratification": "Total",
|
|
241
|
+
"value": "34.1"
|
|
242
|
+
},
|
|
243
|
+
{
|
|
244
|
+
"state": "Louisiana",
|
|
245
|
+
"stratification": "Total",
|
|
246
|
+
"value": "31.7"
|
|
247
|
+
},
|
|
248
|
+
{
|
|
249
|
+
"state": "Massachusetts",
|
|
250
|
+
"stratification": "Total",
|
|
251
|
+
"value": "34.7"
|
|
252
|
+
},
|
|
253
|
+
{
|
|
254
|
+
"state": "Maryland",
|
|
255
|
+
"stratification": "Total",
|
|
256
|
+
"value": "34.4"
|
|
257
|
+
},
|
|
258
|
+
{
|
|
259
|
+
"state": "Maine",
|
|
260
|
+
"stratification": "Total",
|
|
261
|
+
"value": "33.0"
|
|
262
|
+
},
|
|
263
|
+
{
|
|
264
|
+
"state": "Michigan",
|
|
265
|
+
"stratification": "Total",
|
|
266
|
+
"value": "32.8"
|
|
267
|
+
},
|
|
268
|
+
{
|
|
269
|
+
"state": "Minnesota",
|
|
270
|
+
"stratification": "Total",
|
|
271
|
+
"value": "34.9"
|
|
272
|
+
},
|
|
273
|
+
{
|
|
274
|
+
"state": "Missouri",
|
|
275
|
+
"stratification": "Total",
|
|
276
|
+
"value": "33.9"
|
|
277
|
+
},
|
|
278
|
+
{
|
|
279
|
+
"state": "Mississippi",
|
|
280
|
+
"stratification": "Total",
|
|
281
|
+
"value": "32.7"
|
|
282
|
+
},
|
|
283
|
+
{
|
|
284
|
+
"state": "Montana",
|
|
285
|
+
"stratification": "Total",
|
|
286
|
+
"value": "35.4"
|
|
287
|
+
},
|
|
288
|
+
{
|
|
289
|
+
"state": "North Carolina",
|
|
290
|
+
"stratification": "Total",
|
|
291
|
+
"value": "35.2"
|
|
292
|
+
},
|
|
293
|
+
{
|
|
294
|
+
"state": "North Dakota",
|
|
295
|
+
"stratification": "Total",
|
|
296
|
+
"value": "35.6"
|
|
297
|
+
},
|
|
298
|
+
{
|
|
299
|
+
"state": "Nebraska",
|
|
300
|
+
"stratification": "Total",
|
|
301
|
+
"value": "35.1"
|
|
302
|
+
},
|
|
303
|
+
{
|
|
304
|
+
"state": "New Hampshire",
|
|
305
|
+
"stratification": "Total",
|
|
306
|
+
"value": "36.7"
|
|
307
|
+
},
|
|
308
|
+
{
|
|
309
|
+
"state": "New Jersey",
|
|
310
|
+
"stratification": "Total",
|
|
311
|
+
"value": "36.7"
|
|
312
|
+
},
|
|
313
|
+
{
|
|
314
|
+
"state": "New Mexico",
|
|
315
|
+
"stratification": "Total",
|
|
316
|
+
"value": "36.9"
|
|
317
|
+
},
|
|
318
|
+
{
|
|
319
|
+
"state": "Nevada",
|
|
320
|
+
"stratification": "Total",
|
|
321
|
+
"value": "33.8"
|
|
322
|
+
},
|
|
323
|
+
{
|
|
324
|
+
"state": "New York",
|
|
325
|
+
"stratification": "Total",
|
|
326
|
+
"value": "33.9"
|
|
327
|
+
},
|
|
328
|
+
{
|
|
329
|
+
"state": "Ohio",
|
|
330
|
+
"stratification": "Total",
|
|
331
|
+
"value": "32.8"
|
|
332
|
+
},
|
|
333
|
+
{
|
|
334
|
+
"state": "Oklahoma",
|
|
335
|
+
"stratification": "Total",
|
|
336
|
+
"value": "32.3"
|
|
337
|
+
},
|
|
338
|
+
{
|
|
339
|
+
"state": "Oregon",
|
|
340
|
+
"stratification": "Total",
|
|
341
|
+
"value": "36.0"
|
|
342
|
+
},
|
|
343
|
+
{
|
|
344
|
+
"state": "Pennsylvania",
|
|
345
|
+
"stratification": "Total",
|
|
346
|
+
"value": "34.3"
|
|
347
|
+
},
|
|
348
|
+
{
|
|
349
|
+
"state": "Puerto Rico",
|
|
350
|
+
"stratification": "Total",
|
|
351
|
+
"value": "36.6"
|
|
352
|
+
},
|
|
353
|
+
{
|
|
354
|
+
"state": "Rhode Island",
|
|
355
|
+
"stratification": "Total",
|
|
356
|
+
"value": "36.5"
|
|
357
|
+
},
|
|
358
|
+
{
|
|
359
|
+
"state": "South Carolina",
|
|
360
|
+
"stratification": "Total",
|
|
361
|
+
"value": "34.8"
|
|
362
|
+
},
|
|
363
|
+
{
|
|
364
|
+
"state": "South Dakota",
|
|
365
|
+
"stratification": "Total",
|
|
366
|
+
"value": "35.4"
|
|
367
|
+
},
|
|
368
|
+
{
|
|
369
|
+
"state": "Tennessee",
|
|
370
|
+
"stratification": "Total",
|
|
371
|
+
"value": "32.0"
|
|
372
|
+
},
|
|
373
|
+
{
|
|
374
|
+
"state": "Utah",
|
|
375
|
+
"stratification": "Total",
|
|
376
|
+
"value": "34.2"
|
|
377
|
+
},
|
|
378
|
+
{
|
|
379
|
+
"state": "Virginia",
|
|
380
|
+
"stratification": "Total",
|
|
381
|
+
"value": "32.1"
|
|
382
|
+
},
|
|
383
|
+
{
|
|
384
|
+
"state": "Virgin Islands",
|
|
385
|
+
"stratification": "Total",
|
|
386
|
+
"value": "37.0"
|
|
387
|
+
},
|
|
388
|
+
{
|
|
389
|
+
"state": "Vermont",
|
|
390
|
+
"stratification": "Total",
|
|
391
|
+
"value": "34.1"
|
|
392
|
+
},
|
|
393
|
+
{
|
|
394
|
+
"state": "Washington",
|
|
395
|
+
"stratification": "Total",
|
|
396
|
+
"value": "34.6"
|
|
397
|
+
},
|
|
398
|
+
{
|
|
399
|
+
"state": "Wisconsin",
|
|
400
|
+
"stratification": "Total",
|
|
401
|
+
"value": "33.0"
|
|
402
|
+
},
|
|
403
|
+
{
|
|
404
|
+
"state": "West Virginia",
|
|
405
|
+
"stratification": "Total",
|
|
406
|
+
"value": "33.4"
|
|
407
|
+
},
|
|
408
|
+
{
|
|
409
|
+
"state": "Wyoming",
|
|
410
|
+
"stratification": "Total",
|
|
411
|
+
"value": "35.6"
|
|
412
|
+
}
|
|
413
|
+
],
|
|
414
|
+
"color": "",
|
|
415
|
+
"version": "4.24.12"
|
|
416
|
+
}
|