@cdc/chart 4.24.3 → 4.24.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.
@@ -21,7 +21,6 @@ const SankeySettings = () => {
21
21
  }
22
22
 
23
23
  storyNodes[i][fieldName] = value
24
- console.log('story nodes', storyNodes[i])
25
24
  updateConfig({
26
25
  ...config,
27
26
  sankey: {
@@ -7,730 +7,6 @@
7
7
  }
8
8
 
9
9
  .cdc-open-viz-module.type-chart {
10
- .editor-panel {
11
- &.hidden {
12
- display: none;
13
- }
14
-
15
- .two-col-inputs {
16
- display: flex;
17
- margin-top: 1em;
18
- justify-content: space-between;
19
-
20
- > label {
21
- width: 48%;
22
- margin-top: 0 !important;
23
- }
24
- }
25
-
26
- .helper-tooltip {
27
- padding: 5px;
28
- max-width: 300px;
29
- }
30
-
31
- .helper {
32
- position: relative;
33
- opacity: 0.7;
34
- cursor: pointer;
35
- width: 17px;
36
- height: 17px;
37
- align-self: center;
38
- margin-left: 0.3rem;
39
- margin-top: -0.3rem;
40
- border: none !important;
41
- box-shadow: none !important;
42
-
43
- svg {
44
- position: absolute;
45
- top: 0;
46
- left: 0;
47
- width: 100%;
48
- height: 100%;
49
- }
50
- }
51
-
52
- .divider-heading {
53
- display: block;
54
- font-size: 1em;
55
- margin-top: 1em;
56
- }
57
-
58
- .series-list {
59
- list-style: none;
60
- border: $lightGray 1px solid;
61
-
62
- &:empty {
63
- border: none !important;
64
- }
65
-
66
- li {
67
- padding: 0.3em 0.5em;
68
- display: flex;
69
- align-items: center;
70
- justify-content: space-between;
71
- font-size: 0.9em;
72
- position: relative;
73
-
74
- &:hover {
75
- background-color: $lightestGray;
76
- }
77
-
78
- div {
79
- width: 100%;
80
- }
81
-
82
- .series-list__name {
83
- position: relative;
84
- user-select: none;
85
-
86
- &.series-list__name--truncate {
87
- &[data-title] {
88
- $bgColor: rgb(34 34 34 / 90%);
89
- position: relative;
90
-
91
- &::before,
92
- &::after {
93
- opacity: 0;
94
- pointer-events: none;
95
- position: absolute;
96
- transition: opacity 250ms cubic-bezier(0.16, 1, 0.3, 1);
97
- z-index: 1;
98
- }
99
-
100
- &::before {
101
- content: attr(data-title);
102
- bottom: -39px;
103
- padding: 6px 10px;
104
- background: $bgColor;
105
- color: #fff;
106
- font-size: 14px;
107
- white-space: nowrap;
108
- border-radius: 4px;
109
- }
110
-
111
- &::after {
112
- content: '';
113
- bottom: -8px;
114
- left: 10px;
115
- border: 7px solid transparent;
116
- border-bottom: 6px solid $bgColor;
117
- }
118
-
119
- &:hover {
120
- &::before,
121
- &::after {
122
- opacity: 1;
123
- }
124
- }
125
- }
126
-
127
- .series-list__name-text {
128
- cursor: pointer;
129
- }
130
- }
131
- }
132
-
133
- .series-list__dropdown {
134
- width: 100%;
135
- display: block;
136
- font-size: 0.8em;
137
- margin-bottom: 10px;
138
- select {
139
- width: 100%;
140
- }
141
- }
142
-
143
- .series-list__remove {
144
- padding: 0 4px;
145
- font-size: 1.125rem;
146
- color: #f00;
147
- cursor: pointer;
148
- position: absolute;
149
- top: 5px;
150
- right: 5px;
151
- }
152
-
153
- + li {
154
- border-top: $lightGray 1px solid;
155
- }
156
- }
157
- }
158
-
159
- .series-list__name-text {
160
- max-width: 150px;
161
- margin-bottom: 10px;
162
- white-space: nowrap;
163
- text-overflow: ellipsis;
164
- overflow: hidden;
165
- }
166
-
167
- .accordion__heading {
168
- background: $lightestGray;
169
- }
170
-
171
- .accordion__item {
172
- select {
173
- text-transform: capitalize;
174
- outline: none;
175
- }
176
-
177
- .number-narrow {
178
- min-width: auto;
179
- width: 75px;
180
- }
181
- }
182
-
183
- .form-container {
184
- border-right: $lightGray 1px solid;
185
- flex-grow: 1;
186
- }
187
-
188
- .guidance-link {
189
- margin: 2em 1em 0;
190
- padding: 0.75em 1em;
191
-
192
- svg {
193
- width: 60px;
194
- color: $blue;
195
- margin-right: 1rem;
196
- height: 60px; // IE11
197
- path {
198
- fill: currentColor;
199
- }
200
- }
201
- }
202
-
203
- .warning {
204
- color: #d8000c;
205
- background-color: #ffd2d2;
206
- padding: 0.75em 1em;
207
- margin: 1em 0;
208
- font-size: 0.8em;
209
- border: #d8000c 1px solid;
210
- border-radius: 0.4em;
211
-
212
- strong {
213
- font-weight: 600;
214
- display: block;
215
- }
216
- }
217
-
218
- .accordion__button {
219
- cursor: pointer;
220
- font-size: 1em;
221
- padding: 0.3em 1em;
222
- width: 100%;
223
- text-align: left;
224
- position: relative;
225
- border-bottom: 1px solid rgba(0, 0, 0, 0.2);
226
-
227
- &::before {
228
- display: inline-block;
229
- content: '';
230
- height: 7px;
231
- width: 7px;
232
- margin-right: 1em;
233
- border-bottom: 2px solid currentColor;
234
- border-right: 2px solid currentColor;
235
- right: 0;
236
- position: absolute;
237
- top: 50%;
238
- transform: rotate(-45deg) translateY(-50%);
239
- transition: 0.1s all;
240
- }
241
-
242
- &[aria-expanded='true']::before {
243
- transform: rotate(45deg) translateY(-50%);
244
- transform-origin: right;
245
- margin-right: 1.3em;
246
- transition: 0.1s all;
247
- }
248
- }
249
-
250
- .accordion__panel {
251
- border-bottom: 1px solid rgba(0, 0, 0, 0.2);
252
- padding: 1em 1.25em 2em;
253
- animation: fadein 0.2s ease-in;
254
-
255
- &:first-child {
256
- margin-top: 0;
257
- }
258
-
259
- h5 {
260
- font-size: 0.8em;
261
- }
262
- }
263
-
264
- .advanced {
265
- padding: 0 1em 1em;
266
- text-align: left;
267
-
268
- p {
269
- font-size: 0.8rem;
270
- }
271
-
272
- .advanced-toggle-link {
273
- padding-top: 1em;
274
- display: block;
275
- text-align: left;
276
- cursor: pointer;
277
- text-decoration: underline;
278
-
279
- span {
280
- text-decoration: none;
281
- display: inline-block;
282
- font-family: monospace;
283
- padding-right: 5px;
284
- }
285
-
286
- &:hover {
287
- color: rgba(0, 0, 0, 0.7);
288
- }
289
- }
290
-
291
- textarea {
292
- height: 400px;
293
- width: 100%;
294
- font-size: 0.9em;
295
- padding: 0.5em;
296
- font-family: monospace;
297
- box-sizing: border-box;
298
- }
299
- }
300
-
301
- @keyframes fadein {
302
- 0% {
303
- opacity: 0;
304
- }
305
-
306
- 100% {
307
- opacity: 1;
308
- }
309
- }
310
-
311
- .heading-2 {
312
- background: #565656;
313
- color: #fff;
314
- font-size: 1.1em;
315
- padding: 0.6em 1em;
316
- position: relative;
317
- border-bottom: #565656 3px solid;
318
- z-index: 3;
319
- }
320
-
321
- legend,
322
- label {
323
- text-transform: uppercase;
324
- display: block;
325
- font-size: 0.8em;
326
- font-weight: 600;
327
- user-select: none;
328
-
329
- &:not(:first-child) {
330
- margin-top: 1em;
331
- }
332
-
333
- span.edit-label {
334
- margin-bottom: 0.3em;
335
- display: block;
336
- }
337
-
338
- span.column-heading {
339
- font-size: 1em;
340
- }
341
-
342
- &.checkbox {
343
- display: flex;
344
-
345
- input {
346
- margin-left: 0;
347
- width: inherit;
348
- display: inline;
349
- }
350
- }
351
- }
352
-
353
- legend {
354
- font-weight: normal;
355
- margin-bottom: 0.3em;
356
- }
357
-
358
- legend + span {
359
- float: left;
360
- }
361
-
362
- .radio-label {
363
- font-weight: normal;
364
- }
365
-
366
- .accordion__panel fieldset:not(:first-child) {
367
- margin-top: 1em;
368
- }
369
-
370
- .accordion__panel fieldset {
371
- label:not(:first-child) {
372
- margin-top: 0rem;
373
- }
374
- }
375
-
376
- input[type='text'],
377
- input[role='combobox'],
378
- input[type='number'],
379
- textarea {
380
- min-width: 100%;
381
- max-width: 100%; // Doing this prevents width of textarea from being changed
382
- }
383
-
384
- textarea {
385
- min-height: 140px;
386
- }
387
-
388
- .header .color-palette button {
389
- width: 21px;
390
- height: 21px;
391
- border-radius: 40px;
392
- margin-right: 2.8px;
393
- }
394
-
395
- .color-palette {
396
- display: flex;
397
- max-width: 100%;
398
- padding: 0;
399
- margin: 0.5em 0 0 0;
400
- list-style: none;
401
- flex-wrap: wrap;
402
-
403
- button {
404
- width: 45px;
405
- height: 23px;
406
- margin-right: 4px;
407
- margin-bottom: 10px;
408
- display: flex;
409
- border-radius: 5px;
410
- overflow: hidden;
411
- cursor: pointer;
412
- position: relative;
413
- padding: 0;
414
-
415
- .click-target {
416
- position: absolute;
417
- top: 0;
418
- left: 0;
419
- right: 0;
420
- bottom: 0;
421
- }
422
-
423
- &.selected {
424
- border: rgba(0, 0, 0, 0.8) 2px solid;
425
- }
426
-
427
- span {
428
- width: 33.3%;
429
- height: 100%;
430
- }
431
-
432
- span.two-color {
433
- width: 50%;
434
- height: 100%;
435
- }
436
- }
437
- }
438
-
439
- fieldset {
440
- display: block;
441
-
442
- .float-left {
443
- float: left;
444
- }
445
- }
446
-
447
- .primary-fieldset {
448
- padding: 0;
449
- margin: 0;
450
- border: 0;
451
- }
452
-
453
- ul.column-edit {
454
- list-style: none;
455
-
456
- li {
457
- margin-top: 1em;
458
- }
459
-
460
- .three-col {
461
- display: flex;
462
- justify-content: space-between;
463
-
464
- > label {
465
- margin-top: 0;
466
- width: 30%;
467
- display: inline-block;
468
-
469
- input[type='text'],
470
- input[type='number'] {
471
- width: 50px;
472
- }
473
- }
474
- }
475
- }
476
-
477
- .emove-column {
478
- float: right;
479
- text-transform: uppercase;
480
- color: #c32b2b;
481
- font-size: 0.7em;
482
- line-height: 1.6em;
483
- border-radius: 5px;
484
- margin: 0 auto;
485
- transition: 0.1s all;
486
- border: 0;
487
- text-decoration: underline;
488
- outline: 0;
489
- cursor: pointer;
490
- font-weight: bold;
491
- }
492
-
493
- .edit-block {
494
- padding-left: 1em;
495
- border-left: rgba(0, 0, 0, 0.2) 4px solid;
496
- transition: 0.2s all;
497
-
498
- &:not(:first-child) {
499
- margin-top: 2em;
500
- }
501
-
502
- input[type='text'],
503
- input[type='number'] {
504
- font-size: 1em;
505
- }
506
-
507
- label {
508
- margin-top: 0;
509
- }
510
-
511
- label + label {
512
- margin-top: 1em;
513
- }
514
-
515
- &:hover {
516
- border-left: rgba(0, 0, 0, 0.7) 4px solid;
517
- transition: 0.2s all;
518
- }
519
- }
520
-
521
- span.subtext {
522
- display: block;
523
- color: rgba(0, 0, 0, 0.5);
524
- text-transform: none;
525
- font-weight: normal;
526
- }
527
-
528
- .btn {
529
- margin-top: 1em;
530
- }
531
-
532
- .sort-list {
533
- list-style: none;
534
-
535
- > li {
536
- margin-right: 0.3em;
537
- margin-bottom: 0.3em;
538
- }
539
- }
540
-
541
- .sort-list li > div {
542
- display: block;
543
- box-sizing: border-box;
544
- border: 1px solid #d1d1d1;
545
- border-radius: 2px;
546
- background: #f1f1f1;
547
- padding: 0.4em 0.6em;
548
- font-size: 0.8em;
549
- margin-bottom: 0.3em;
550
- cursor: move;
551
- }
552
-
553
- .info {
554
- font-size: 0.8em;
555
- line-height: 1.4em;
556
- font-style: italic;
557
- padding-top: 10px;
558
- }
559
-
560
- .react-tags__search {
561
- width: 100%;
562
- }
563
-
564
- .react-tags {
565
- position: relative;
566
-
567
- input.react-tags__search-input {
568
- font-size: 0.8rem;
569
- }
570
-
571
- /* clicking anywhere will focus the input */
572
- cursor: text;
573
-
574
- span {
575
- display: inline;
576
- }
577
- }
578
-
579
- .react-tags.is-focused {
580
- border-color: rgba(0, 0, 0, 0.7);
581
- }
582
-
583
- .react-tags__selected {
584
- display: inline;
585
- }
586
-
587
- .react-tags__selected-tag {
588
- display: inline-block;
589
- box-sizing: border-box;
590
- border: 1px solid #d1d1d1;
591
- border-radius: 2px;
592
- background: #f1f1f1;
593
- padding: 0.4em 0.6em;
594
- font-size: 0.8em;
595
- margin-right: 0.3em;
596
- margin-bottom: 0.3em;
597
- }
598
-
599
- .react-tags__selected-tag:after {
600
- content: '\2715';
601
- color: #aaa;
602
- margin-left: 8px;
603
- }
604
-
605
- .react-tags__selected-tag:hover,
606
- .react-tags__selected-tag:focus {
607
- border-color: #b1b1b1;
608
- }
609
-
610
- .react-tags__search {
611
- display: inline-block;
612
-
613
- /* prevent autoresize overflowing the container */
614
- max-width: 100%;
615
- }
616
-
617
- @media screen and (min-width: 30em) {
618
- .react-tags__search {
619
- /* this will become the offsetParent for suggestions */
620
- position: relative;
621
- }
622
- }
623
-
624
- .react-tags__search input {
625
- /* prevent autoresize overflowing the container */
626
- max-width: 100%;
627
-
628
- /* emove styles and layout from this element */
629
- margin: 0;
630
- outline: none;
631
- padding: 0.5em 0.3em;
632
-
633
- /* match the font styles */
634
- font-size: inherit;
635
- line-height: inherit;
636
- }
637
-
638
- .react-tags__search input::-ms-clear {
639
- display: none;
640
- }
641
-
642
- .react-tags__suggestions {
643
- position: absolute;
644
- top: 100%;
645
- left: 0;
646
- width: 100%;
647
- }
648
-
649
- @media screen and (min-width: 30em) {
650
- .react-tags__suggestions {
651
- width: 240px;
652
- }
653
- }
654
-
655
- .react-tags__suggestions ul {
656
- margin: 4px -1px;
657
- padding: 0;
658
- list-style: none;
659
- background: white;
660
- border: 1px solid #d1d1d1;
661
- border-radius: 2px;
662
- box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
663
- }
664
-
665
- .react-tags__suggestions li {
666
- border-bottom: 1px solid #ddd;
667
- padding: 6px 8px;
668
- }
669
-
670
- .react-tags__suggestions li mark {
671
- text-decoration: underline;
672
- background: none;
673
- font-weight: 600;
674
- }
675
-
676
- .react-tags__suggestions li:hover {
677
- cursor: pointer;
678
- background: #eee;
679
- }
680
-
681
- .react-tags__suggestions li.is-active {
682
- background: #b7cfe0;
683
- }
684
-
685
- .react-tags__suggestions li.is-disabled {
686
- opacity: 0.5;
687
- cursor: auto;
688
- }
689
-
690
- input[type='radio'] {
691
- border: 1px solid #8c8f94;
692
- border-radius: 50%;
693
- margin-right: 5px;
694
- }
695
- }
696
-
697
- .editor-toggle {
698
- background: #f2f2f2;
699
- border-radius: 60px;
700
- color: #000;
701
- font-size: 1em;
702
- border: 0;
703
- position: absolute;
704
- z-index: 100;
705
- transition: 0.1s background;
706
- cursor: pointer;
707
- width: 25px;
708
- height: 25px;
709
- left: 307px;
710
- box-shadow: rgba(0, 0, 0, 0.5) 0 1px 2px;
711
-
712
- &:before {
713
- top: 43%;
714
- left: 50%;
715
- transform: translate(-50%, -50%);
716
- position: absolute;
717
- content: '\00ab';
718
- }
719
-
720
- &.collapsed {
721
- left: 1em;
722
- margin-left: 0;
723
-
724
- &:before {
725
- content: '\00bb';
726
- }
727
- }
728
-
729
- &:hover {
730
- background: rgba(255, 255, 255, 1);
731
- }
732
- }
733
-
734
10
  @include breakpointClass(md) {
735
11
  .editor-panel:not(.hidden) + .cdc-chart-inner-container {
736
12
  padding-left: 350px;