@ndla/ui 55.0.14-alpha.0 → 55.0.16-alpha.0

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 (82) hide show
  1. package/dist/panda.buildinfo.json +40 -13
  2. package/dist/styles.css +160 -54
  3. package/es/Article/ArticleByline.js +81 -48
  4. package/es/Article/ArticleFootNotes.js +31 -19
  5. package/es/AudioPlayer/AudioPlayer.js +1 -0
  6. package/es/Concept/Concept.js +2 -2
  7. package/es/ContactBlock/ContactBlock.js +17 -17
  8. package/es/ContentTypeBadge/ContentTypeBadgeNew.js +1 -0
  9. package/es/Embed/BrightcoveEmbed.js +0 -1
  10. package/es/Embed/CopyrightEmbed.js +1 -2
  11. package/es/FrontpageArticle/FrontpageArticle.js +1 -2
  12. package/es/LicenseByline/EmbedByline.js +143 -33
  13. package/es/LicenseByline/LicenseLink.js +16 -9
  14. package/es/LicenseByline/index.js +2 -2
  15. package/es/index.js +0 -2
  16. package/es/model/ContentType.js +3 -1
  17. package/es/styles.css +160 -54
  18. package/lib/Article/ArticleByline.d.ts +1 -3
  19. package/lib/Article/ArticleByline.js +84 -51
  20. package/lib/Article/ArticleFootNotes.js +31 -20
  21. package/lib/AudioPlayer/AudioPlayer.js +1 -0
  22. package/lib/Concept/Concept.js +1 -1
  23. package/lib/ContactBlock/ContactBlock.js +18 -18
  24. package/lib/ContentTypeBadge/ContentTypeBadgeNew.d.ts +1 -2
  25. package/lib/ContentTypeBadge/ContentTypeBadgeNew.js +1 -0
  26. package/lib/Embed/BrightcoveEmbed.js +0 -1
  27. package/lib/Embed/CopyrightEmbed.js +1 -2
  28. package/lib/FrontpageArticle/FrontpageArticle.js +1 -2
  29. package/lib/LicenseByline/EmbedByline.d.ts +2 -4
  30. package/lib/LicenseByline/EmbedByline.js +145 -35
  31. package/lib/LicenseByline/LicenseLink.d.ts +2 -2
  32. package/lib/LicenseByline/LicenseLink.js +16 -9
  33. package/lib/LicenseByline/index.d.ts +2 -2
  34. package/lib/LicenseByline/index.js +4 -5
  35. package/lib/index.d.ts +0 -2
  36. package/lib/index.js +0 -20
  37. package/lib/model/ContentType.d.ts +1 -0
  38. package/lib/model/ContentType.js +4 -2
  39. package/lib/styles.css +160 -54
  40. package/package.json +5 -6
  41. package/src/Article/ArticleByline.tsx +83 -70
  42. package/src/Article/ArticleFootNotes.tsx +32 -36
  43. package/src/AudioPlayer/AudioPlayer.tsx +1 -0
  44. package/src/Concept/Concept.tsx +2 -2
  45. package/src/ContactBlock/ContactBlock.tsx +1 -1
  46. package/src/ContentTypeBadge/ContentTypeBadgeNew.tsx +3 -1
  47. package/src/Embed/BrightcoveEmbed.tsx +1 -1
  48. package/src/Embed/CopyrightEmbed.tsx +1 -1
  49. package/src/FrontpageArticle/FrontpageArticle.tsx +1 -1
  50. package/src/LicenseByline/EmbedByline.stories.tsx +9 -4
  51. package/src/LicenseByline/EmbedByline.tsx +139 -53
  52. package/src/LicenseByline/LicenseLink.tsx +15 -15
  53. package/src/LicenseByline/index.tsx +2 -2
  54. package/src/index.ts +0 -3
  55. package/src/model/ContentType.ts +2 -0
  56. package/es/CreatedBy/CreatedBy.js +0 -73
  57. package/es/CreatedBy/index.js +0 -10
  58. package/es/LicenseByline/LicenseDescription.js +0 -63
  59. package/es/List/OrderedList.js +0 -41
  60. package/es/List/UnOrderedList.js +0 -28
  61. package/es/List/index.js +0 -10
  62. package/lib/CreatedBy/CreatedBy.d.ts +0 -15
  63. package/lib/CreatedBy/CreatedBy.js +0 -78
  64. package/lib/CreatedBy/index.d.ts +0 -9
  65. package/lib/CreatedBy/index.js +0 -16
  66. package/lib/LicenseByline/LicenseDescription.d.ts +0 -15
  67. package/lib/LicenseByline/LicenseDescription.js +0 -70
  68. package/lib/List/OrderedList.d.ts +0 -16
  69. package/lib/List/OrderedList.js +0 -48
  70. package/lib/List/UnOrderedList.d.ts +0 -10
  71. package/lib/List/UnOrderedList.js +0 -35
  72. package/lib/List/index.d.ts +0 -9
  73. package/lib/List/index.js +0 -20
  74. package/src/CreatedBy/CreatedBy.stories.tsx +0 -36
  75. package/src/CreatedBy/CreatedBy.tsx +0 -63
  76. package/src/CreatedBy/index.ts +0 -11
  77. package/src/LicenseByline/LicenseDescription.tsx +0 -100
  78. package/src/List/OrderedList.stories.tsx +0 -135
  79. package/src/List/OrderedList.tsx +0 -158
  80. package/src/List/UnOrderedList.tsx +0 -43
  81. package/src/List/UnorderedList.stories.tsx +0 -72
  82. package/src/List/index.ts +0 -10
@@ -2,16 +2,33 @@
2
2
  "schemaVersion": "0.42.0",
3
3
  "styles": {
4
4
  "atomic": [
5
+ "marginBlockStart]___[value:medium",
6
+ "paddingBlockStart]___[value:xsmall",
7
+ "borderTop]___[value:1px solid",
8
+ "borderColor]___[value:stroke.subtle",
9
+ "display]___[value:flex",
10
+ "flexDirection]___[value:column-reverse",
11
+ "gap]___[value:3xsmall",
12
+ "width]___[value:100%",
13
+ "justifyContent]___[value:space-between",
14
+ "paddingBlock]___[value:xsmall",
15
+ "textStyle]___[value:body.medium",
16
+ "flexDirection]___[value:row]___[cond:tabletWide",
17
+ "gap]___[value:xsmall",
18
+ "paddingBlockStart]___[value:xxlarge",
19
+ "alignItems]___[value:center",
20
+ "flexDirection]___[value:column",
21
+ "gap]___[value:medium",
22
+ "listStyle]___[value:none",
5
23
  "textAlign]___[value:center]___[cond:&[data-align=\"center\"]",
6
24
  "direction]___[value:rtl]___[cond:&:has(span[dir=\"rtl\"])",
7
25
  "border]___[value:1px solid",
8
26
  "borderColor]___[value:stroke.default",
9
27
  "borderRadius]___[value:xsmall",
10
28
  "boxShadow]___[value:full",
29
+ "marginBlockEnd]___[value:4xsmall",
11
30
  "overflow]___[value:hidden",
12
- "display]___[value:flex",
13
31
  "display]___[value:block]___[cond:tabletWideDown",
14
- "alignItems]___[value:center",
15
32
  "flex]___[value:1 0 auto",
16
33
  "width]___[value:surface.4xsmall",
17
34
  "height]___[value:surface.4xsmall",
@@ -25,14 +42,10 @@
25
42
  "width]___[value:100%]___[cond:tabletWideDown",
26
43
  "height]___[value:auto]___[cond:tabletWideDown",
27
44
  "alignItems]___[value:flex-start",
28
- "flexDirection]___[value:column",
29
- "gap]___[value:xsmall",
30
45
  "padding]___[value:xsmall",
31
- "width]___[value:100%",
32
46
  "paddingBlock]___[value:xsmall]___[cond:&[data-has-image='true']<___>tablet",
33
47
  "paddingInline]___[value:medium]___[cond:&[data-has-image='true']<___>tablet",
34
48
  "width]___[value:100%]___[cond:tabletWide",
35
- "flexDirection]___[value:row]___[cond:tabletWide",
36
49
  "justifyContent]___[value:space-between]___[cond:tabletWide",
37
50
  "borderBlockStart]___[value:1px solid",
38
51
  "paddingBlock]___[value:medium",
@@ -44,7 +57,6 @@
44
57
  "borderBottomRadius]___[value:xsmall",
45
58
  "justifyContent]___[value:center",
46
59
  "background]___[value:background.default",
47
- "paddingBlock]___[value:xsmall",
48
60
  "paddingInline]___[value:medium",
49
61
  "display]___[value:grid]___[cond:tabletWideDown",
50
62
  "paddingBlock]___[value:xsmall]___[cond:tabletWideDown",
@@ -71,8 +83,6 @@
71
83
  "srOnly]___[value:true",
72
84
  "color]___[value:text.default",
73
85
  "backgroundColor]___[value:background.default",
74
- "gap]___[value:medium",
75
- "borderColor]___[value:stroke.subtle",
76
86
  "transitionDuration]___[value:fast",
77
87
  "transitionProperty]___[value:background-color, border-color, max-width",
78
88
  "transitionTimingFunction]___[value:default",
@@ -206,7 +216,6 @@
206
216
  "outlineColor]___[value:stroke.default]___[cond:_focusVisible<___>_after",
207
217
  "outlineOffset]___[value:3px]___[cond:_focusVisible<___>_after",
208
218
  "outlineStyle]___[value:solid]___[cond:_focusVisible<___>_after",
209
- "textStyle]___[value:body.medium",
210
219
  "textAlign]___[value:center",
211
220
  "color]___[value:text.strong]___[cond:& a",
212
221
  "marginTop]___[value:0]___[cond:& h1",
@@ -247,17 +256,36 @@
247
256
  "transitionDuration]___[value:fast]___[cond:& svg",
248
257
  "transform]___[value:rotate(180deg)]___[cond:_open<___>& svg",
249
258
  "display]___[value:none]___[cond:_print",
250
- "justifyContent]___[value:space-between",
251
259
  "gap]___[value:small",
252
260
  "paddingInline]___[value:0",
253
261
  "marginBlockStart]___[value:3xsmall",
254
262
  "paddingBlock]___[value:small",
255
- "borderTop]___[value:1px solid",
256
263
  "background]___[value:surface.brand.1.subtle]___[cond:_first",
257
264
  "borderColor]___[value:stroke.default]___[cond:_first",
258
265
  "fontWeight]___[value:bold]___[cond:_first<___>& p",
259
266
  "fontStyle]___[value:italic",
260
267
  "background]___[value:surface.default",
268
+ "borderColor]___[value:stroke.error",
269
+ "background]___[value:surface.dangerSubtle",
270
+ "display]___[value:inline-flex",
271
+ "whiteSpace]___[value:pre-wrap",
272
+ "display]___[value:grid]___[cond:mobileWideDown",
273
+ "gridTemplateColumns]___[value:1fr auto]___[cond:mobileWideDown",
274
+ "alignItems]___[value:center]___[cond:mobileWideDown",
275
+ "overflow]___[value:hidden]___[cond:mobileWideDown",
276
+ "display]___[value:inline]___[cond:mobileWideDown<___>_open",
277
+ "whiteSpace]___[value:nowrap]___[cond:mobileWideDown",
278
+ "maxHeight]___[value:large]___[cond:mobileWideDown",
279
+ "textOverflow]___[value:ellipsis]___[cond:mobileWideDown",
280
+ "transitionProperty]___[value:max-height]___[cond:mobileWideDown",
281
+ "transitionDuration]___[value:slow]___[cond:mobileWideDown",
282
+ "transitionTimingFunction]___[value:ease-in]___[cond:mobileWideDown",
283
+ "whiteSpace]___[value:pre-wrap]___[cond:mobileWideDown<___>_open",
284
+ "maxHeight]___[value:none]___[cond:mobileWideDown<___>_open",
285
+ "display]___[value:none]___[cond:mobileWide",
286
+ "color]___[value:primary",
287
+ "whiteSpace]___[value:nowrap",
288
+ "textDecoration]___[value:none]___[cond:_focusWithin",
261
289
  "textDecoration]___[value:underline]___[cond:& h3",
262
290
  "transitionProperty]___[value:width, height]___[cond:& [data-forward]",
263
291
  "transitionTimingFunction]___[value:ease-in-out]___[cond:& [data-forward]",
@@ -266,7 +294,6 @@
266
294
  "width]___[value:large]___[cond:_hover<___>& [data-forward]",
267
295
  "height]___[value:large]___[cond:_hover<___>& [data-forward]",
268
296
  "color]___[value:icon.strong",
269
- "listStyle]___[value:none",
270
297
  "content]___[value:\"\"]___[cond:_before",
271
298
  "position]___[value:absolute]___[cond:_before",
272
299
  "inset]___[value:0]___[cond:_before",
package/dist/styles.css CHANGED
@@ -1,5 +1,17 @@
1
1
  @layer utilities {
2
2
  @layer compositions {
3
+ .textStyle_body\.medium {
4
+ font-family: var(--fonts-sans);
5
+ font-weight: var(--font-weights-normal);
6
+ font-size: var(--font-sizes-small);
7
+ line-height: var(--line-heights-small);
8
+ }
9
+
10
+ .textStyle_body\.medium:where([lang='zh'], [lang='zh-Hans'], [lang='zh-Hant']):not([data-pinyin]) {
11
+ font-size: calc(var(--font-sizes-small) * 1.11);
12
+ line-height: calc(var(--line-heights-small) * 1.11);
13
+ }
14
+
3
15
  .textStyle_body\.large {
4
16
  font-family: var(--fonts-sans);
5
17
  font-weight: var(--font-weights-normal);
@@ -36,18 +48,6 @@
36
48
  line-height: calc(var(--line-heights-medium) * 1.11);
37
49
  }
38
50
 
39
- .textStyle_body\.medium {
40
- font-family: var(--fonts-sans);
41
- font-weight: var(--font-weights-normal);
42
- font-size: var(--font-sizes-small);
43
- line-height: var(--line-heights-small);
44
- }
45
-
46
- .textStyle_body\.medium:where([lang='zh'], [lang='zh-Hans'], [lang='zh-Hant']):not([data-pinyin]) {
47
- font-size: calc(var(--font-sizes-small) * 1.11);
48
- line-height: calc(var(--line-heights-small) * 1.11);
49
- }
50
-
51
51
  .\[\&_a\]\:textStyle_label\.xsmall a {
52
52
  font-family: var(--fonts-sans);
53
53
  font-weight: var(--font-weights-normal);
@@ -61,6 +61,50 @@
61
61
  }
62
62
  }
63
63
 
64
+ .mbs_medium {
65
+ margin-block-start: var(--spacing-medium);
66
+ }
67
+
68
+ .pbs_xsmall {
69
+ padding-block-start: var(--spacing-xsmall);
70
+ }
71
+
72
+ .bd-t_1px_solid {
73
+ border-top: 1px solid;
74
+ }
75
+
76
+ .d_flex {
77
+ display: flex;
78
+ }
79
+
80
+ .gap_3xsmall {
81
+ gap: var(--spacing-3xsmall);
82
+ }
83
+
84
+ .w_100\% {
85
+ width: 100%;
86
+ }
87
+
88
+ .py_xsmall {
89
+ padding-block: var(--spacing-xsmall);
90
+ }
91
+
92
+ .gap_xsmall {
93
+ gap: var(--spacing-xsmall);
94
+ }
95
+
96
+ .pbs_xxlarge {
97
+ padding-block-start: var(--spacing-xxlarge);
98
+ }
99
+
100
+ .gap_medium {
101
+ gap: var(--spacing-medium);
102
+ }
103
+
104
+ .li-s_none {
105
+ list-style: none;
106
+ }
107
+
64
108
  .bd_1px_solid {
65
109
  border: 1px solid;
66
110
  }
@@ -73,12 +117,12 @@
73
117
  box-shadow: var(--shadows-full);
74
118
  }
75
119
 
76
- .ov_hidden {
77
- overflow: hidden;
120
+ .mbe_4xsmall {
121
+ margin-block-end: var(--spacing-4xsmall);
78
122
  }
79
123
 
80
- .d_flex {
81
- display: flex;
124
+ .ov_hidden {
125
+ overflow: hidden;
82
126
  }
83
127
 
84
128
  .flex_1_0_auto {
@@ -93,18 +137,10 @@
93
137
  height: var(--sizes-surface-4xsmall);
94
138
  }
95
139
 
96
- .gap_xsmall {
97
- gap: var(--spacing-xsmall);
98
- }
99
-
100
140
  .p_xsmall {
101
141
  padding: var(--spacing-xsmall);
102
142
  }
103
143
 
104
- .w_100\% {
105
- width: 100%;
106
- }
107
-
108
144
  .bd-bs_1px_solid {
109
145
  border-block-start: 1px solid;
110
146
  }
@@ -130,10 +166,6 @@
130
166
  background: var(--colors-background-default);
131
167
  }
132
168
 
133
- .py_xsmall {
134
- padding-block: var(--spacing-xsmall);
135
- }
136
-
137
169
  .px_medium {
138
170
  padding-inline: var(--spacing-medium);
139
171
  }
@@ -210,10 +242,6 @@
210
242
  color: var(--colors-text-default);
211
243
  }
212
244
 
213
- .gap_medium {
214
- gap: var(--spacing-medium);
215
- }
216
-
217
245
  .h_100\% {
218
246
  height: 100%;
219
247
  }
@@ -407,20 +435,32 @@
407
435
  padding-block: var(--spacing-small);
408
436
  }
409
437
 
410
- .bd-t_1px_solid {
411
- border-top: 1px solid;
412
- }
413
-
414
438
  .bg_surface\.default {
415
439
  background: var(--colors-surface-default);
416
440
  }
417
441
 
418
- .c_icon\.strong {
419
- color: var(--colors-icon-strong);
442
+ .bg_surface\.dangerSubtle {
443
+ background: var(--colors-surface-danger-subtle);
420
444
  }
421
445
 
422
- .li-s_none {
423
- list-style: none;
446
+ .d_inline-flex {
447
+ display: inline-flex;
448
+ }
449
+
450
+ .white-space_pre-wrap {
451
+ white-space: pre-wrap;
452
+ }
453
+
454
+ .c_primary {
455
+ color: var(--colors-primary);
456
+ }
457
+
458
+ .white-space_nowrap {
459
+ white-space: nowrap;
460
+ }
461
+
462
+ .c_icon\.strong {
463
+ color: var(--colors-icon-strong);
424
464
  }
425
465
 
426
466
  .d_grid {
@@ -435,22 +475,34 @@
435
475
  aspect-ratio: 1/1;
436
476
  }
437
477
 
438
- .bd-c_stroke\.default {
439
- border-color: var(--colors-stroke-default);
478
+ .bd-c_stroke\.subtle {
479
+ border-color: var(--colors-stroke-subtle);
440
480
  }
441
481
 
442
- .ai_center {
443
- align-items: center;
482
+ .flex-d_column-reverse {
483
+ flex-direction: column-reverse;
444
484
  }
445
485
 
446
- .ai_flex-start {
447
- align-items: flex-start;
486
+ .jc_space-between {
487
+ justify-content: space-between;
488
+ }
489
+
490
+ .ai_center {
491
+ align-items: center;
448
492
  }
449
493
 
450
494
  .flex-d_column {
451
495
  flex-direction: column;
452
496
  }
453
497
 
498
+ .bd-c_stroke\.default {
499
+ border-color: var(--colors-stroke-default);
500
+ }
501
+
502
+ .ai_flex-start {
503
+ align-items: flex-start;
504
+ }
505
+
454
506
  .as_flex-start {
455
507
  align-self: flex-start;
456
508
  }
@@ -463,10 +515,6 @@
463
515
  background-color: var(--colors-background-default);
464
516
  }
465
517
 
466
- .bd-c_stroke\.subtle {
467
- border-color: var(--colors-stroke-subtle);
468
- }
469
-
470
518
  .trs-dur_fast {
471
519
  --transition-duration: var(--durations-fast);
472
520
  transition-duration: var(--durations-fast);
@@ -596,14 +644,14 @@
596
644
  bottom: calc(var(--spacing-medium) * -1);
597
645
  }
598
646
 
599
- .jc_space-between {
600
- justify-content: space-between;
601
- }
602
-
603
647
  .font-style_italic {
604
648
  font-style: italic;
605
649
  }
606
650
 
651
+ .bd-c_stroke\.error {
652
+ border-color: var(--colors-stroke-error);
653
+ }
654
+
607
655
  .grid-tc_repeat\(2\,_1fr\) {
608
656
  grid-template-columns: repeat(2, 1fr);
609
657
  }
@@ -926,6 +974,10 @@
926
974
  content: "";
927
975
  }
928
976
 
977
+ .focusWithin\:td_none:focus-within {
978
+ text-decoration: none;
979
+ }
980
+
929
981
  .focusVisible\:ring_none:is(:focus-visible, [data-focus-visible]) {
930
982
  outline: 2px solid transparent;
931
983
  outline-offset: 2px;
@@ -1042,6 +1094,9 @@
1042
1094
  @media screen and (min-width: 29.75rem) {
1043
1095
  .mobileWide\:max-w_surface\.medium {
1044
1096
  max-width: var(--sizes-surface-medium);
1097
+ }
1098
+ .mobileWide\:d_none {
1099
+ display: none;
1045
1100
  }
1046
1101
  }
1047
1102
 
@@ -1157,8 +1212,59 @@
1157
1212
  }
1158
1213
 
1159
1214
  @media screen and (max-width: 29.7475rem) {
1215
+ .mobileWideDown\:d_grid {
1216
+ display: grid;
1217
+ }
1218
+ .mobileWideDown\:ov_hidden {
1219
+ overflow: hidden;
1220
+ }
1221
+ .mobileWideDown\:white-space_nowrap {
1222
+ white-space: nowrap;
1223
+ }
1224
+ .mobileWideDown\:max-h_large {
1225
+ max-height: var(--sizes-large);
1226
+ }
1227
+ .mobileWideDown\:tov_ellipsis {
1228
+ text-overflow: ellipsis;
1229
+ }
1160
1230
  .mobileWideDown\:cg_3xsmall {
1161
1231
  column-gap: var(--spacing-3xsmall);
1232
+ }
1233
+ .mobileWideDown\:grid-tc_1fr_auto {
1234
+ grid-template-columns: 1fr auto;
1235
+ }
1236
+ .mobileWideDown\:ai_center {
1237
+ align-items: center;
1238
+ }
1239
+ .mobileWideDown\:trs-prop_max-height {
1240
+ --transition-prop: max-height;
1241
+ transition-property: max-height;
1242
+ }
1243
+ .mobileWideDown\:trs-dur_slow {
1244
+ --transition-duration: var(--durations-slow);
1245
+ transition-duration: var(--durations-slow);
1246
+ }
1247
+ .mobileWideDown\:trs-tmf_ease-in {
1248
+ --transition-easing: ease-in;
1249
+ transition-timing-function: ease-in;
1250
+ }
1251
+ }
1252
+
1253
+ @media screen and (max-width: 29.7475rem) {
1254
+ .mobileWideDown\:open\:d_inline:is([open], [data-open], [data-state="open"]) {
1255
+ display: inline;
1256
+ }
1257
+ }
1258
+
1259
+ @media screen and (max-width: 29.7475rem) {
1260
+ .mobileWideDown\:open\:white-space_pre-wrap:is([open], [data-open], [data-state="open"]) {
1261
+ white-space: pre-wrap;
1262
+ }
1263
+ }
1264
+
1265
+ @media screen and (max-width: 29.7475rem) {
1266
+ .mobileWideDown\:open\:max-h_none:is([open], [data-open], [data-state="open"]) {
1267
+ max-height: none;
1162
1268
  }
1163
1269
  }
1164
1270