@undrr/undrr-mangrove 1.3.3 → 1.4.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 (155) hide show
  1. package/README.md +32 -25
  2. package/components/BarChart.js +2 -2
  3. package/components/BookCard.js +6 -0
  4. package/components/BookCard.js.LICENSE.txt +11 -0
  5. package/components/Breadcrumbs.js +6 -0
  6. package/components/Breadcrumbs.js.LICENSE.txt +9 -0
  7. package/components/Checkbox.js +6 -0
  8. package/components/Checkbox.js.LICENSE.txt +9 -0
  9. package/components/Chips.js +6 -0
  10. package/components/Chips.js.LICENSE.txt +9 -0
  11. package/components/CtaButton.js +6 -0
  12. package/components/CtaButton.js.LICENSE.txt +9 -0
  13. package/components/EmbedContainer.js +6 -0
  14. package/components/EmbedContainer.js.LICENSE.txt +9 -0
  15. package/components/Fetcher.js +2 -2
  16. package/components/Footer.js +6 -0
  17. package/components/Footer.js.LICENSE.txt +9 -0
  18. package/components/FormErrorSummary.js +6 -0
  19. package/components/FormErrorSummary.js.LICENSE.txt +9 -0
  20. package/components/FormGroup.js +6 -0
  21. package/components/FormGroup.js.LICENSE.txt +9 -0
  22. package/components/FullWidth.js +6 -0
  23. package/components/FullWidth.js.LICENSE.txt +9 -0
  24. package/components/Gallery.js +1 -1
  25. package/components/Hero.js +6 -0
  26. package/components/Hero.js.LICENSE.txt +9 -0
  27. package/components/HighlightBox.js +6 -0
  28. package/components/HighlightBox.js.LICENSE.txt +9 -0
  29. package/components/HorizontalBookCard.js +6 -0
  30. package/components/HorizontalBookCard.js.LICENSE.txt +11 -0
  31. package/components/HorizontalCard.js +6 -0
  32. package/components/HorizontalCard.js.LICENSE.txt +11 -0
  33. package/components/IconCard.js +2 -2
  34. package/components/Loader.js +6 -0
  35. package/components/Loader.js.LICENSE.txt +9 -0
  36. package/components/MapComponent.js +2 -2
  37. package/components/MegaMenu.js +2 -2
  38. package/components/PageHeader.js +6 -0
  39. package/components/PageHeader.js.LICENSE.txt +9 -0
  40. package/components/Pager.js +2 -2
  41. package/components/QuoteHighlight.js +1 -1
  42. package/components/Radio.js +6 -0
  43. package/components/Radio.js.LICENSE.txt +9 -0
  44. package/components/ScrollContainer.js +1 -1
  45. package/components/Select.js +6 -0
  46. package/components/Select.js.LICENSE.txt +9 -0
  47. package/components/ShareButtons.js +1 -1
  48. package/components/ShowMore.js +6 -0
  49. package/components/ShowMore.js.LICENSE.txt +9 -0
  50. package/components/StatsCard.js +2 -2
  51. package/components/SyndicationSearchWidget.js +2 -2
  52. package/components/Tab.js +6 -0
  53. package/components/Tab.js.LICENSE.txt +9 -0
  54. package/components/TextCta.js +6 -0
  55. package/components/TextCta.js.LICENSE.txt +11 -0
  56. package/components/TextInput.js +6 -0
  57. package/components/TextInput.js.LICENSE.txt +9 -0
  58. package/components/Textarea.js +6 -0
  59. package/components/Textarea.js.LICENSE.txt +9 -0
  60. package/components/VerticalCard.js +6 -0
  61. package/components/VerticalCard.js.LICENSE.txt +11 -0
  62. package/components/hydrate.js +1 -1
  63. package/css/style-delta.css +464 -0
  64. package/css/style-delta.css.map +1 -0
  65. package/css/style-gutenberg.css +18 -18
  66. package/css/style-gutenberg.css.map +1 -1
  67. package/css/style-irp-legacy.css +469 -0
  68. package/css/style-irp-legacy.css.map +1 -0
  69. package/css/style-irp.css +96 -103
  70. package/css/style-irp.css.map +1 -1
  71. package/css/style-legacy.css +462 -0
  72. package/css/style-legacy.css.map +1 -0
  73. package/css/style-mcr-legacy.css +469 -0
  74. package/css/style-mcr-legacy.css.map +1 -0
  75. package/css/style-mcr.css +96 -103
  76. package/css/style-mcr.css.map +1 -1
  77. package/css/style-preventionweb-legacy.css +469 -0
  78. package/css/style-preventionweb-legacy.css.map +1 -0
  79. package/css/style-preventionweb.css +96 -103
  80. package/css/style-preventionweb.css.map +1 -1
  81. package/css/style.css +96 -103
  82. package/css/style.css.map +1 -1
  83. package/error-pages/401.html +10 -11
  84. package/error-pages/403.html +11 -12
  85. package/error-pages/404.html +13 -14
  86. package/error-pages/429.html +12 -13
  87. package/error-pages/500.html +10 -11
  88. package/error-pages/502.html +12 -13
  89. package/error-pages/503.html +12 -13
  90. package/error-pages/504.html +10 -11
  91. package/error-pages/5xx.html +10 -11
  92. package/error-pages/challenge.html +12 -13
  93. package/error-pages/managed-challenge.html +12 -13
  94. package/js/tabs.js +427 -81
  95. package/package.json +1 -1
  96. package/scss/Atom/BaseTypography/Blockquote/blockquote.scss +1 -8
  97. package/scss/Atom/BaseTypography/Cite/cite.scss +2 -2
  98. package/scss/Atom/Images/AuthorImage/author-image.scss +4 -4
  99. package/scss/Atom/Images/ImageCaptionCredit/image-caption-credit.scss +24 -28
  100. package/scss/Atom/Images/ImageCredit/image-credit.scss +1 -1
  101. package/scss/Atom/Layout/Container/container.scss +2 -2
  102. package/scss/Atom/Layout/Grid/grid.scss +1 -1
  103. package/scss/Atom/ReachElement/Details/details.scss +6 -6
  104. package/scss/Atom/ReachElement/Figcaption/figcaption.scss +1 -1
  105. package/scss/Atom/Table/table.scss +0 -8
  106. package/scss/Components/Boilerplate/boilerplate.scss +2 -2
  107. package/scss/Components/Breadcrumbs/breadcrumbs.scss +2 -9
  108. package/scss/Components/Buttons/Chips/chips.scss +5 -19
  109. package/scss/Components/Buttons/CtaButton/buttons.scss +3 -124
  110. package/scss/Components/Buttons/CtaButton/cta-button.scss +124 -0
  111. package/scss/Components/Buttons/ShareButtons/share-buttons.scss +2 -2
  112. package/scss/Components/Cards/Card/card.scss +39 -0
  113. package/scss/Components/ErrorPages/error-pages.scss +12 -12
  114. package/scss/Components/Footer/footer.scss +72 -4
  115. package/scss/Components/Forms/Select/select.scss +2 -2
  116. package/scss/Components/Forms/_form-base.scss +5 -5
  117. package/scss/Components/Forms/_form-legacy.scss +1 -1
  118. package/scss/Components/Gallery/gallery.scss +4 -4
  119. package/scss/Components/Hero/hero.scss +18 -17
  120. package/scss/Components/HighlightBox/highlight-box.scss +5 -5
  121. package/scss/Components/MegaMenu/mega-menu.scss +750 -0
  122. package/scss/Components/MegaMenu/megamenu.scss +3 -733
  123. package/scss/Components/PageHeader/page-header.scss +4 -4
  124. package/scss/Components/Pagination/pagination.scss +2 -2
  125. package/scss/Components/SyndicationSearchWidget/SyndicationSearchWidget.scss +3 -1480
  126. package/scss/Components/SyndicationSearchWidget/syndication-search-widget.scss +1515 -0
  127. package/scss/Components/Tab/tab.scss +66 -7
  128. package/scss/Components/TextCta/text-cta.scss +129 -0
  129. package/scss/Components/TextCta/textcta.scss +3 -27
  130. package/scss/Molecules/ImageCaption/image-caption.scss +6 -16
  131. package/scss/Molecules/SectionHeader/section-header.scss +8 -0
  132. package/scss/Molecules/SectionHeader/sectionheader.scss +3 -8
  133. package/scss/Utilities/FullWidth/FullWidth.scss +3 -23
  134. package/scss/Utilities/FullWidth/full-width.scss +23 -0
  135. package/scss/Utilities/Loader/loader.scss +1 -1
  136. package/scss/Utilities/ShowMore/ShowMore.scss +3 -26
  137. package/scss/Utilities/ShowMore/show-more.scss +26 -0
  138. package/scss/assets/scss/_components.scss +14 -9
  139. package/scss/assets/scss/_foundational.scss +13 -7
  140. package/scss/assets/scss/_mixins.scss +9 -314
  141. package/scss/assets/scss/_utility.scss +19 -71
  142. package/scss/assets/scss/_variables-delta.scss +105 -0
  143. package/scss/assets/scss/_variables-irp.scss +1 -1
  144. package/scss/assets/scss/_variables-mcr.scss +1 -1
  145. package/scss/assets/scss/_variables-preventionweb.scss +1 -1
  146. package/scss/assets/scss/_variables.scss +68 -34
  147. package/scss/assets/scss/style-delta.scss +8 -0
  148. package/scss/assets/scss/style-gutenberg.scss +2 -2
  149. package/scss/assets/scss/style-irp-legacy.scss +20 -0
  150. package/scss/assets/scss/style-legacy.scss +20 -0
  151. package/scss/assets/scss/style-mcr-legacy.scss +20 -0
  152. package/scss/assets/scss/style-preventionweb-legacy.scss +20 -0
  153. package/scss/Components/BlockquoteComponent/blockquotecomp.scss +0 -31
  154. package/scss/Components/Buttons/CtaLink/cta-link.scss +0 -61
  155. /package/scss/Components/TableOfContents/{TableOfContents.scss → table-of-contents.scss} +0 -0
@@ -1,733 +1,3 @@
1
- .mg-mega-wrapper {
2
- position: relative;
3
- background: $mg-color-white;
4
- box-shadow: 0 2px 3px 0 rgb(51 51 51 / 0.31);
5
- z-index: 10;
6
- }
7
-
8
- .mg-mega-topbar {
9
- width: 100%;
10
- display: flex;
11
- align-items: flex-start;
12
- z-index: 10;
13
- padding: 0;
14
- max-width: $mg-breakpoint-desktop;
15
- margin: 0 auto;
16
-
17
- @media screen and (min-width: $mg-breakpoint-desktop-wide) {
18
- max-width: $mg-breakpoint-desktop-wide;
19
- }
20
-
21
- // these are note "mobile first" as they seem to cause a glitch with firefox and .mg-container-full-width
22
- @media screen and (max-width: $mg-breakpoint-tablet) {
23
- padding-left: 4rem; // space for the icon button
24
- overflow-x: hidden; // primarily for mobile
25
- }
26
-
27
- // --- Branded variant (with inline logo) ---
28
- &--branded {
29
- align-items: center;
30
-
31
- @media screen and (max-width: $mg-breakpoint-tablet) {
32
- padding-left: 0; // logo replaces the left padding
33
- overflow-x: hidden;
34
- }
35
-
36
- // Hamburger becomes a discrete button (not full-width overlay)
37
- .mg-mega-topbar-mobile__icon-button {
38
- position: relative;
39
- width: auto;
40
- margin-inline-start: auto;
41
- background: $mg-color-white;
42
- flex-shrink: 0;
43
- box-shadow: -3px 0 6px -2px rgb(0 0 0 / 0.15);
44
-
45
- &:has(.mg-icon-angle-circled-left) {
46
- background: $mg-color-white;
47
- box-shadow: -3px 0 6px -2px rgb(0 0 0 / 0.15);
48
- }
49
- }
50
- }
51
-
52
- // Logo link
53
- &__logo {
54
- flex-shrink: 1;
55
- min-width: 0; // allow shrinking below intrinsic size
56
- display: flex;
57
- align-items: center;
58
- padding: $mg-spacing-100 $mg-spacing-150;
59
- }
60
-
61
- // Logo image
62
- &__logo-img {
63
- display: block;
64
- height: 3rem;
65
- max-width: 100%;
66
- width: auto;
67
-
68
- @media screen and (min-width: $mg-breakpoint-tablet) {
69
- height: 3.5rem;
70
- }
71
- }
72
-
73
- // Inner nav list inside branded variant
74
- &__nav {
75
- display: flex;
76
- align-items: flex-start;
77
- flex: 1;
78
- padding: 0;
79
- margin: 0;
80
- list-style: none;
81
-
82
- // Hide items on mobile (same as default topbar behavior)
83
- @media screen and (max-width: $mg-breakpoint-tablet) {
84
- // Items are there but non-interactive on mobile (hamburger opens sidebar)
85
- pointer-events: none;
86
- overflow: hidden;
87
- flex: 1;
88
- min-width: 0;
89
- }
90
- }
91
-
92
- // Hide desktop menu items on mobile/tablet, show on desktop
93
- &__item {
94
- pointer-events: none; // on mobile we only advertise the buttons, but not clickable
95
-
96
- @media screen and (min-width: $mg-breakpoint-tablet) {
97
- display: block;
98
- pointer-events: unset;
99
- }
100
-
101
- .mg-mega-content {
102
- display: none;
103
- }
104
-
105
- font-size: $mg-font-size-300;
106
- color: $mg-color-interactive;
107
- font-weight: bold;
108
- list-style: none;
109
- padding: 0;
110
- margin: 0;
111
-
112
- p {
113
- font-weight: normal;
114
- }
115
-
116
- > a,
117
- > button {
118
- padding: $mg-spacing-150;
119
- display: block;
120
- cursor: pointer;
121
- line-height: 1.75rem; // normalization
122
- width: max-content; // overflow menu style on mobile
123
-
124
- @media screen and (min-width: $mg-breakpoint-tablet) {
125
- width: unset;
126
- }
127
- }
128
-
129
- @media screen and (min-width: $mg-breakpoint-tablet) {
130
- &--active {
131
- background: rgba($mg-color-interactive, 0.2);
132
-
133
- a,
134
- .mg-mega-topbar__item-link {
135
- color: $mg-color-interactive;
136
- text-decoration: none;
137
- }
138
-
139
- a.mg-button-primary {
140
- color: $mg-color-white;
141
- text-decoration: none;
142
- }
143
-
144
- .mg-mega-content {
145
- display: flex;
146
- }
147
- }
148
- }
149
- }
150
-
151
- &__item-link {
152
- font-family: $mg-font-family-condensed;
153
- color: $mg-color-interactive;
154
- background: none;
155
- border: none;
156
- font-weight: bold;
157
- cursor: pointer;
158
- list-style: none;
159
- }
160
-
161
- // Desktop: Make the top level button links larger
162
- @media screen and (min-width: $mg-breakpoint-tablet) {
163
- &__item-link {
164
- font-size: $mg-font-size-400;
165
- }
166
- }
167
- }
168
-
169
- .mg-mega-content {
170
- // Mobile-first: Start with mobile styles
171
- display: flex;
172
- flex-direction: column;
173
- height: auto;
174
- position: relative;
175
- top: 1px;
176
- align-items: flex-start;
177
- justify-content: start;
178
- background-color: rgba($mg-color-button, 0.7);
179
- backdrop-filter: blur(10px);
180
- border-radius: $mg-radius-tab;
181
- box-shadow: -1px 5px 10px -1px rgb(0 0 0 / 0.25);
182
- inset-inline-start: 0;
183
- z-index: 1;
184
- width: 100%;
185
-
186
- // Desktop: Float over content with horizontal layout
187
- @media screen and (min-width: $mg-breakpoint-tablet) {
188
- display: none;
189
- flex-direction: row; // Horizontal layout for left/right sections
190
- height: 35rem;
191
- overflow: hidden;
192
- top: 4.8rem;
193
- position: absolute;
194
- }
195
-
196
- &.mg-container-full-width {
197
- position: absolute;
198
- }
199
-
200
- &__left {
201
- height: 100%;
202
- width: 100%; // mobile-first
203
- background-color: rgba($mg-color-button, 0.8);
204
-
205
- @media screen and (min-width: $mg-breakpoint-tablet) {
206
- flex-basis: 33%;
207
- }
208
- }
209
- &__banner {
210
- padding: $mg-spacing-250;
211
- header {
212
- font-size: $mg-font-size-500;
213
- font-weight: bold;
214
- padding-bottom: $mg-spacing-100;
215
- }
216
- p {
217
- a {
218
- text-decoration: underline;
219
- }
220
- a:hover {
221
- text-decoration: none;
222
- }
223
- }
224
- }
225
- }
226
-
227
- .mg-mega-content,
228
- .mg-mega-content__left,
229
- .mg-mega-content__right,
230
- .mg-mega-topbar__item-link {
231
- &:focus-visible {
232
- outline: -webkit-focus-ring-color auto 1px;
233
- outline-offset: 1px;
234
- }
235
- }
236
-
237
- .mg-mega-content__left {
238
- box-shadow: inset 0 5px 5px -3px rgb(0 0 0 / 0.2);
239
-
240
- // RTL-friendly border
241
- border-inline-end: 2px solid rgba($mg-color-black, 0.2);
242
-
243
- // Mobile-first: Hide section list on mobile
244
- .mg-mega-content__section-list {
245
- display: none;
246
-
247
- @media screen and (min-width: $mg-breakpoint-tablet) {
248
- display: block;
249
- }
250
- }
251
-
252
- .mg-mega-content__section-list-link:hover,
253
- .mg-mega-content__section-list-link {
254
- color: $mg-color-interactive-active;
255
- }
256
- }
257
-
258
- .mg-mega-content__section-list {
259
- padding-inline: $mg-spacing-200;
260
- }
261
-
262
- .mg-mega-content__section-list-item {
263
- list-style: none;
264
- padding: 0;
265
- margin: 0;
266
-
267
- .mg-mega-content__section-list-link {
268
- text-decoration: none;
269
- display: block;
270
-
271
- // RTL-friendly: Use logical properties for better improvements
272
- letter-spacing: 0.2px;
273
- position: relative;
274
- padding: $mg-spacing-150 $mg-spacing-250;
275
- margin-inline: -$mg-spacing-200; // extend hit area to both edges
276
- font-weight: 600;
277
- transition:
278
- background-color 150ms ease,
279
- color 150ms ease,
280
- transform 150ms ease;
281
-
282
- &:hover,
283
- &:focus-visible {
284
- background: rgba($mg-color-interactive, 0.15);
285
- text-decoration: underline;
286
- }
287
-
288
- // RTL-friendly chevron indicator
289
- &::after {
290
- content: "›";
291
- display: inline-block;
292
- position: absolute;
293
- font-size: 3rem;
294
- inset-inline-end: auto;
295
- padding-inline-start: $mg-spacing-150;
296
- margin-inline-end: $mg-spacing-150;
297
- transition:
298
- transform 150ms ease,
299
- inset-inline-start 200ms cubic-bezier(0.4, 0, 0.2, 1),
300
- inset-inline-end 200ms cubic-bezier(0.4, 0, 0.2, 1),
301
- opacity 150ms ease;
302
- opacity: 0.55;
303
- }
304
-
305
- &--active {
306
- padding: $mg-spacing-150 $mg-spacing-250;
307
- margin-inline-start: -$mg-spacing-200;
308
- border-inline-start: 4px solid $mg-color-interactive; // RTL-friendly vertical rule
309
- text-decoration: underline;
310
- background: rgba($mg-color-interactive, 0.15);
311
-
312
- &::after {
313
- opacity: 1;
314
- inset-inline-end: 0;
315
- }
316
- }
317
- }
318
- }
319
-
320
- // RTL: Flip chevron direction
321
- [dir="rtl"]
322
- .mg-mega-content__section-list-item
323
- .mg-mega-content__section-list-link::after {
324
- content: "‹";
325
- }
326
-
327
- /* Brief pulse to draw attention when active becomes visible */
328
- @keyframes mg-mega-tab-pulse {
329
- 0% {
330
- box-shadow:
331
- inset 4px 0 0 0 $mg-color-button,
332
- 0 0 0 0 rgba($mg-color-interactive, 0);
333
- }
334
- 60% {
335
- box-shadow:
336
- inset 4px 0 0 0 $mg-color-button,
337
- 0 0 0 8px rgba($mg-color-interactive, 0.12);
338
- }
339
- 100% {
340
- box-shadow:
341
- inset 4px 0 0 0 $mg-color-button,
342
- 0 0 0 0 rgba($mg-color-interactive, 0);
343
- }
344
- }
345
-
346
- .mg-mega-content__section-list-link--active {
347
- animation: mg-mega-tab-pulse 700ms ease-out 1;
348
- }
349
-
350
- /* Slide motion for right content when tab changes */
351
- @keyframes mg-mega-content-swap {
352
- 0% {
353
- transform: translateX(8px);
354
- opacity: 0.98;
355
- }
356
- 100% {
357
- transform: translateX(0);
358
- opacity: 1;
359
- }
360
- }
361
-
362
- .mg-mega-content__right--sliding {
363
- animation: mg-mega-content-swap 180ms ease-out;
364
- }
365
-
366
- /* Stronger keyboard focus ring for accessibility */
367
- .mg-mega-content__section-list-link:focus-visible {
368
- outline: 2px solid $mg-color-white;
369
- outline-offset: -2px;
370
- }
371
-
372
- .mg-mega-content__right {
373
- box-shadow: inset 0 5px 5px -3px rgb(0 0 0 / 0.2);
374
- flex: 1;
375
- height: 100%;
376
- display: flex;
377
-
378
- // Mobile-first: full width by default
379
- width: 100%;
380
-
381
- // Mobile-first: Show mobile menu, hide desktop menu
382
- .mg-mega-content__menu--mobile {
383
- display: block;
384
- }
385
-
386
- .mg-mega-content__menu--desktop {
387
- display: none;
388
- }
389
-
390
- // Desktop: Hide mobile menu, show desktop menu
391
- @media screen and (min-width: $mg-breakpoint-tablet) {
392
- .mg-mega-content__menu--mobile {
393
- display: none;
394
- }
395
-
396
- .mg-mega-content__menu--desktop {
397
- display: block;
398
-
399
- // Blue flash background that fades out (retriggered via React key)
400
- animation: mg-mega-right-flash 400ms ease-out;
401
-
402
- // Staggered slide-in for menu items
403
- li {
404
- animation: mg-mega-item-slide-in 250ms ease-out both;
405
-
406
- @for $i from 1 through 25 {
407
- &:nth-child(#{$i}) {
408
- animation-delay: #{($i - 1) * 30}ms;
409
- }
410
- }
411
- }
412
- }
413
- }
414
-
415
- ul {
416
- flex: 1;
417
- padding: $mg-spacing-150;
418
- list-style: none;
419
- column-count: auto;
420
- column-width: 300px;
421
- column-gap: $mg-spacing-200;
422
- column-fill: balance;
423
-
424
- // nested menus - RTL-friendly
425
- ul {
426
- padding-block: 0;
427
- padding-inline: $mg-spacing-150;
428
- opacity: 0.8;
429
- break-inside: avoid;
430
- }
431
-
432
- li {
433
- padding: 0;
434
- margin: 0;
435
- break-inside: avoid;
436
-
437
- a {
438
- display: block;
439
- padding: $mg-spacing-50;
440
- overflow: hidden;
441
- white-space: wrap;
442
- text-overflow: clip;
443
- color: $mg-color-black;
444
- font-weight: bold;
445
-
446
- &:hover {
447
- color: $mg-color-black;
448
- text-decoration: underline;
449
- }
450
- }
451
- }
452
- }
453
- }
454
-
455
- /* Subtle blue gradient flash that fades to transparent on right content area */
456
- @keyframes mg-mega-right-flash {
457
- 0% {
458
- background: linear-gradient(
459
- to bottom,
460
- rgba($mg-color-interactive, 0.06) 0%,
461
- transparent 100%
462
- );
463
- }
464
- 100% {
465
- background: transparent;
466
- }
467
- }
468
-
469
- /* Menu items slide in from the left */
470
- @keyframes mg-mega-item-slide-in {
471
- 0% {
472
- opacity: 0;
473
- transform: translateX(-12px);
474
- }
475
- 100% {
476
- opacity: 1;
477
- transform: translateX(0);
478
- }
479
- }
480
-
481
- .mg-icon-button {
482
- padding: $mg-spacing-100;
483
- background-color: transparent;
484
- border: none;
485
- cursor: pointer;
486
- display: flex;
487
- align-items: center;
488
- justify-content: center;
489
-
490
- &:hover {
491
- background-color: $mg-color-interactive-active;
492
- }
493
- }
494
-
495
- .mg-mega-sidebar-section {
496
- list-style: none;
497
-
498
- ol {
499
- list-style: none;
500
- margin: 0;
501
-
502
- li {
503
- margin: 0;
504
- }
505
-
506
- ol li {
507
- list-style: none;
508
- padding-block: $mg-spacing-50;
509
- padding-inline-start: $mg-spacing-350; // RTL-friendly
510
- margin: 0;
511
-
512
- a {
513
- color: $mg-color-white;
514
- text-decoration: none;
515
- }
516
-
517
- &:hover {
518
- background: $mg-color-interactive-active;
519
- }
520
- }
521
- }
522
- }
523
-
524
- .mg-mega-sidebar-section__item {
525
- display: flex;
526
- align-items: center;
527
- justify-content: space-between;
528
- color: $mg-color-white;
529
- cursor: pointer;
530
- padding: $mg-spacing-100 $mg-spacing-250;
531
-
532
- // Mobile-first: Start with mobile styles
533
- background: $mg-color-interactive;
534
- width: 100%;
535
- border: none;
536
- border-block-end: 1px solid $mg-color-white; // RTL-friendly
537
-
538
- // Desktop: Remove mobile-specific styles
539
- @media screen and (min-width: $mg-breakpoint-tablet) {
540
- background: transparent;
541
- border-block-end: none;
542
- }
543
-
544
- &:hover {
545
- background: $mg-color-interactive-active;
546
- color: $mg-color-white;
547
- }
548
-
549
- &:focus-visible {
550
- outline: -webkit-focus-ring-color auto 2px;
551
- outline-offset: -1px;
552
- }
553
-
554
- // Rotate arrow icon when section is expanded
555
- &[aria-expanded="true"] {
556
- .mg-icon-angle-circled-left {
557
- transform: rotate(-90deg);
558
- transition: transform 0.3s ease-in-out;
559
- }
560
- }
561
-
562
- // Ensure smooth transition for icon default state
563
- .mg-icon-angle-circled-left {
564
- transition: transform 0.3s ease-in-out;
565
- }
566
- }
567
-
568
- // RTL: Flip rotation direction
569
- [dir="rtl"]
570
- .mg-mega-sidebar-section__item[aria-expanded="true"]
571
- .mg-icon-angle-circled-left {
572
- transform: rotate(90deg);
573
- }
574
-
575
- .mg-mega-sidebar {
576
- position: absolute;
577
- overflow: auto;
578
- background-color: $mg-color-interactive-active;
579
- z-index: 10;
580
-
581
- // Mobile-first: Full-width mobile sidebar
582
- width: 100%;
583
- height: auto;
584
- max-height: 80vh;
585
- top: -100%;
586
- inset-inline: 0; // RTL-friendly
587
- transition: top 0.4s ease-in-out;
588
- box-shadow: 0 5px 8px -4px rgb(0 0 0 / 0.25);
589
-
590
- &.mg-sidebar-open {
591
- top: 0;
592
- }
593
-
594
- // Desktop: Side panel from end (right in LTR, left in RTL)
595
- @media screen and (min-width: $mg-breakpoint-tablet) {
596
- width: 300px;
597
- height: 100vh;
598
- top: 0;
599
- inset-inline-start: auto;
600
- inset-inline-end: 0; // RTL-friendly: appears from right in LTR, left in RTL
601
- box-shadow: -5px 0 8px -4px rgb(0 0 0 / 0.25);
602
- }
603
- }
604
-
605
- // RTL: Flip box shadow direction on desktop
606
- [dir="rtl"] .mg-mega-sidebar {
607
- @media screen and (min-width: $mg-breakpoint-tablet) {
608
- box-shadow: 5px 0 8px -4px rgb(0 0 0 / 0.25);
609
- }
610
- }
611
-
612
- .mg-mega-sidebar__list {
613
- background: $mg-color-white;
614
- display: flex;
615
- flex-direction: column;
616
- padding: 0;
617
- margin-bottom: 0;
618
- width: 100%;
619
- position: relative;
620
- inset-inline-end: auto; // RTL-friendly
621
- }
622
-
623
- .mg-mega-sidebar__section {
624
- display: flex;
625
- align-items: center;
626
- justify-content: space-between;
627
- padding: $mg-spacing-150 $mg-spacing-350;
628
- color: $mg-color-white;
629
- cursor: pointer;
630
-
631
- &:hover {
632
- background: $mg-color-interactive-active;
633
- }
634
- }
635
-
636
- .mg-mega-topbar-mobile__icon-button {
637
- // Mobile-first: Display by default
638
- position: absolute;
639
- inset-inline-end: 0; // RTL-friendly
640
- background: rgb(0 0 0 / 0); // we let the menu items show through to advertise the contents
641
- color: $mg-color-interactive;
642
- font-size: 2rem;
643
- width: 100vw;
644
- height: 100%;
645
- padding: $mg-spacing-100;
646
- border: none;
647
- cursor: pointer;
648
- align-items: start;
649
- justify-content: start;
650
- z-index: 14;
651
- display: flex;
652
-
653
- // Hide mobile button on desktop
654
- @media screen and (min-width: $mg-breakpoint-tablet) {
655
- display: none;
656
- }
657
-
658
- &:hover {
659
- // background: $mg-color-interactive-active;
660
- color: rgba($mg-color-interactive, 0.9);
661
- }
662
-
663
- .mg-mega-topbar {
664
- position: relative;
665
- }
666
-
667
- &:has(.mg-icon-angle-circled-left) {
668
- background: rgb(255 255 255 / 0.8);
669
- color: $mg-color-interactive-active;
670
- box-shadow: 0 0 4px rgb(0 0 0 / 0.2);
671
- }
672
- }
673
-
674
- // Mobile sidebar (slides down/up from the top)
675
- .mg-mega-mobile-sidebar {
676
- // Mobile-first: Show on mobile, hide on desktop
677
- width: 100%;
678
- position: absolute;
679
- top: 0;
680
- inset-inline-start: 0; // RTL-friendly
681
- z-index: 9;
682
- display: block;
683
- overflow: auto;
684
- background-color: $mg-color-interactive;
685
- max-height: 80vh;
686
- height: 80vh;
687
- transform: translateY(-100vh);
688
- transition: transform 0.4s ease-in-out;
689
- box-shadow: 0 5px 8px -4px rgb(0 0 0 / 0.25);
690
-
691
- &.mg-mega-mobile-sidebar--open {
692
- transform: translateY(calc(5rem - 2px)); // mystery math?
693
- }
694
-
695
- // Desktop: Hide completely
696
- @media screen and (min-width: $mg-breakpoint-tablet) {
697
- display: none;
698
- }
699
- }
700
-
701
- // Overlay backdrop (only shown when sidebar open)
702
- .mg-mega-mobile-sidebar-overlay {
703
- // Mobile-first: Show on mobile
704
- display: block;
705
- position: fixed;
706
- inset: 0; // Already RTL-friendly logical property
707
- background: rgb(0 0 0 / 0.4);
708
- border: none;
709
- padding: 0;
710
- cursor: pointer;
711
- z-index: 9; // just below sidebar which has 10
712
-
713
- // Desktop: Hide
714
- @media screen and (min-width: $mg-breakpoint-tablet) {
715
- display: none;
716
- }
717
- }
718
-
719
- // RTL: Flip hamburger shadow direction in branded variant
720
- [dir="rtl"] .mg-mega-topbar--branded .mg-mega-topbar-mobile__icon-button {
721
- box-shadow: 3px 0 6px -2px rgb(0 0 0 / 0.15);
722
- }
723
-
724
- [dir="rtl"] .mg-mega-topbar--branded .mg-mega-topbar-mobile__icon-button:has(.mg-icon-angle-circled-left) {
725
- box-shadow: 3px 0 6px -2px rgb(0 0 0 / 0.15);
726
- }
727
-
728
- // Arabic
729
- :lang(ar) {
730
- .mg-mega-menu__item-link {
731
- font-family: $mg-font-family-arabic-body;
732
- }
733
- }
1
+ // megamenu.scss — DEPRECATED, use mega-menu.scss
2
+ @import "./mega-menu";
3
+ @warn "megamenu.scss is deprecated. Import mega-menu.scss instead.";