boreal-ui 0.0.882 → 0.0.883

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.
@@ -9,49 +9,49 @@ import { I as IconButton } from "./IconButton-DQTmDwt_.js";
9
9
  import "./globals.js";
10
10
  import { S as Select } from "./Select-D4bH7djH.js";
11
11
  import { a as ThemeContext } from "./ThemeContext-CVJwo33B.js";
12
- import './Footer.css';const footer = "_footer_l3ftg_204";
13
- const primary = "_primary_l3ftg_214";
14
- const secondary = "_secondary_l3ftg_218";
15
- const tertiary = "_tertiary_l3ftg_222";
16
- const quaternary = "_quaternary_l3ftg_226";
17
- const clear = "_clear_l3ftg_230";
18
- const roundNone = "_roundNone_l3ftg_234";
19
- const roundSmall = "_roundSmall_l3ftg_238";
20
- const roundMedium = "_roundMedium_l3ftg_242";
21
- const roundLarge = "_roundLarge_l3ftg_246";
22
- const roundFull = "_roundFull_l3ftg_250";
23
- const shadowNone = "_shadowNone_l3ftg_254";
24
- const shadowLight = "_shadowLight_l3ftg_257";
25
- const shadowMedium = "_shadowMedium_l3ftg_260";
26
- const shadowStrong = "_shadowStrong_l3ftg_263";
27
- const shadowIntense = "_shadowIntense_l3ftg_266";
28
- const attachmentStatic = "_attachmentStatic_l3ftg_269";
29
- const attachmentSticky = "_attachmentSticky_l3ftg_272";
30
- const attachmentFixed = "_attachmentFixed_l3ftg_280";
31
- const content = "_content_l3ftg_289";
32
- const left = "_left_l3ftg_309";
33
- const links = "_links_l3ftg_337";
34
- const link = "_link_l3ftg_337";
35
- const logo = "_logo_l3ftg_385";
36
- const social = "_social_l3ftg_406";
37
- const themeToggle = "_themeToggle_l3ftg_419";
38
- const copyright = "_copyright_l3ftg_437";
39
- const layoutColumns = "_layoutColumns_l3ftg_441";
40
- const brand = "_brand_l3ftg_470";
41
- const brandLink = "_brandLink_l3ftg_480";
42
- const brandTitle = "_brandTitle_l3ftg_505";
43
- const brandDescription = "_brandDescription_l3ftg_514";
44
- const sections = "_sections_l3ftg_522";
45
- const section = "_section_l3ftg_522";
46
- const actionGroup = "_actionGroup_l3ftg_534";
47
- const sectionTitle = "_sectionTitle_l3ftg_541";
48
- const sectionList = "_sectionList_l3ftg_551";
49
- const actions = "_actions_l3ftg_560";
50
- const bottom = "_bottom_l3ftg_573";
51
- const bottomCopyright = "_bottomCopyright_l3ftg_592";
52
- const bottomEnd = "_bottomEnd_l3ftg_596";
53
- const spin = "_spin_l3ftg_1";
54
- const pulse = "_pulse_l3ftg_1";
12
+ import './Footer.css';const footer = "_footer_apmcr_204";
13
+ const primary = "_primary_apmcr_214";
14
+ const secondary = "_secondary_apmcr_218";
15
+ const tertiary = "_tertiary_apmcr_222";
16
+ const quaternary = "_quaternary_apmcr_226";
17
+ const clear = "_clear_apmcr_230";
18
+ const roundNone = "_roundNone_apmcr_234";
19
+ const roundSmall = "_roundSmall_apmcr_238";
20
+ const roundMedium = "_roundMedium_apmcr_242";
21
+ const roundLarge = "_roundLarge_apmcr_246";
22
+ const roundFull = "_roundFull_apmcr_250";
23
+ const shadowNone = "_shadowNone_apmcr_254";
24
+ const shadowLight = "_shadowLight_apmcr_257";
25
+ const shadowMedium = "_shadowMedium_apmcr_260";
26
+ const shadowStrong = "_shadowStrong_apmcr_263";
27
+ const shadowIntense = "_shadowIntense_apmcr_266";
28
+ const attachmentStatic = "_attachmentStatic_apmcr_269";
29
+ const attachmentSticky = "_attachmentSticky_apmcr_272";
30
+ const attachmentFixed = "_attachmentFixed_apmcr_280";
31
+ const content = "_content_apmcr_289";
32
+ const left = "_left_apmcr_309";
33
+ const links = "_links_apmcr_337";
34
+ const link = "_link_apmcr_337";
35
+ const logo = "_logo_apmcr_385";
36
+ const social = "_social_apmcr_406";
37
+ const themeToggle = "_themeToggle_apmcr_419";
38
+ const copyright = "_copyright_apmcr_437";
39
+ const layoutColumns = "_layoutColumns_apmcr_441";
40
+ const brand = "_brand_apmcr_470";
41
+ const brandLink = "_brandLink_apmcr_480";
42
+ const brandTitle = "_brandTitle_apmcr_507";
43
+ const brandDescription = "_brandDescription_apmcr_516";
44
+ const sections = "_sections_apmcr_524";
45
+ const section = "_section_apmcr_524";
46
+ const actionGroup = "_actionGroup_apmcr_536";
47
+ const sectionTitle = "_sectionTitle_apmcr_543";
48
+ const sectionList = "_sectionList_apmcr_553";
49
+ const actions = "_actions_apmcr_562";
50
+ const bottom = "_bottom_apmcr_575";
51
+ const bottomCopyright = "_bottomCopyright_apmcr_594";
52
+ const bottomEnd = "_bottomEnd_apmcr_598";
53
+ const spin = "_spin_apmcr_1";
54
+ const pulse = "_pulse_apmcr_1";
55
55
  const styles = {
56
56
  footer,
57
57
  primary,
@@ -94,15 +94,15 @@ const styles = {
94
94
  bottom,
95
95
  bottomCopyright,
96
96
  bottomEnd,
97
- "fade-in": "_fade-in_l3ftg_1",
98
- "slide-up": "_slide-up_l3ftg_1",
99
- "spin-3d": "_spin-3d_l3ftg_1",
97
+ "fade-in": "_fade-in_apmcr_1",
98
+ "slide-up": "_slide-up_apmcr_1",
99
+ "spin-3d": "_spin-3d_apmcr_1",
100
100
  spin,
101
101
  pulse,
102
- "fade-in-up": "_fade-in-up_l3ftg_1",
103
- "progress-grow": "_progress-grow_l3ftg_1",
104
- "indeterminate-move": "_indeterminate-move_l3ftg_1",
105
- "skeleton-loading": "_skeleton-loading_l3ftg_1"
102
+ "fade-in-up": "_fade-in-up_apmcr_1",
103
+ "progress-grow": "_progress-grow_apmcr_1",
104
+ "indeterminate-move": "_indeterminate-move_apmcr_1",
105
+ "skeleton-loading": "_skeleton-loading_apmcr_1"
106
106
  };
107
107
  const slugify = (value) => value.toLowerCase().trim().replace(/\s+/g, "-");
108
108
  const FooterBase = ({
@@ -124,6 +124,25 @@ const FooterBase = ({
124
124
  socialLinks = [],
125
125
  showThemeSelect = false,
126
126
  bottomEnd: bottomEnd2,
127
+ contentClassName,
128
+ leftClassName,
129
+ linksClassName,
130
+ linkClassName,
131
+ logoClassName,
132
+ socialClassName,
133
+ themeToggleClassName,
134
+ brandClassName,
135
+ brandLinkClassName,
136
+ brandTitleClassName,
137
+ brandDescriptionClassName,
138
+ sectionsClassName,
139
+ sectionTitleClassName,
140
+ actionsClassName,
141
+ actionGroupClassName,
142
+ bottomClassName,
143
+ bottomCopyrightClassName,
144
+ bottomEndClassName,
145
+ copyrightClassName,
127
146
  IconButton: IconButton2,
128
147
  ImageComponent = "img",
129
148
  ThemeSelect,
@@ -173,7 +192,7 @@ const FooterBase = ({
173
192
  return /* @__PURE__ */ jsx(
174
193
  "img",
175
194
  {
176
- className: classMap.logo,
195
+ className: combineClassNames(classMap.logo, logoClassName),
177
196
  "data-testid": `${testId}-logo`,
178
197
  loading: "lazy",
179
198
  src: logoSrc,
@@ -187,7 +206,7 @@ const FooterBase = ({
187
206
  return /* @__PURE__ */ jsx(
188
207
  ImageComponent,
189
208
  {
190
- className: classMap.logo,
209
+ className: combineClassNames(classMap.logo, logoClassName),
191
210
  "data-testid": `${testId}-logo`,
192
211
  src: logoSrc,
193
212
  alt: logoDecorative ? "" : logoAriaLabel,
@@ -203,7 +222,7 @@ const FooterBase = ({
203
222
  return /* @__PURE__ */ jsx(
204
223
  "span",
205
224
  {
206
- className: classMap.logo,
225
+ className: combineClassNames(classMap.logo, logoClassName),
207
226
  role: logoDecorative ? void 0 : "img",
208
227
  "aria-label": logoDecorative ? void 0 : logoAriaLabel,
209
228
  "aria-hidden": logoDecorative ? true : void 0,
@@ -212,14 +231,18 @@ const FooterBase = ({
212
231
  }
213
232
  );
214
233
  };
215
- const renderFooterLink = (link2, index) => {
234
+ const renderFooterLink = (link2, index, customLinkClassName) => {
216
235
  const slug = slugify(link2.label || link2.href || `link-${index}`);
217
236
  const key = `${link2.href ?? slug}-${index}`;
237
+ const resolvedLinkClassName = combineClassNames(
238
+ classMap.link,
239
+ customLinkClassName
240
+ );
218
241
  if (link2.disabled) {
219
242
  return /* @__PURE__ */ jsx("li", { children: /* @__PURE__ */ jsx(
220
243
  "span",
221
244
  {
222
- className: classMap.link,
245
+ className: resolvedLinkClassName,
223
246
  "data-testid": `${testId}-link-${slug}`,
224
247
  "aria-disabled": "true",
225
248
  title: link2.title,
@@ -231,7 +254,7 @@ const FooterBase = ({
231
254
  LinkWrapper,
232
255
  {
233
256
  href: link2.href,
234
- className: classMap.link,
257
+ className: resolvedLinkClassName,
235
258
  "data-testid": `${testId}-link-${slug}`,
236
259
  "aria-label": link2["aria-label"],
237
260
  "aria-current": link2["aria-current"],
@@ -249,7 +272,7 @@ const FooterBase = ({
249
272
  return /* @__PURE__ */ jsx(
250
273
  "nav",
251
274
  {
252
- className: classMap.social,
275
+ className: combineClassNames(classMap.social, socialClassName),
253
276
  "aria-label": socialNavAriaLabel,
254
277
  "data-testid": `${testId}-social`,
255
278
  children: socialLinks.map((social2, index) => /* @__PURE__ */ jsx(
@@ -279,7 +302,10 @@ const FooterBase = ({
279
302
  return /* @__PURE__ */ jsx(
280
303
  "div",
281
304
  {
282
- className: classMap.themeToggle,
305
+ className: combineClassNames(
306
+ classMap.themeToggle,
307
+ themeToggleClassName
308
+ ),
283
309
  "data-testid": `${testId}-theme-select`,
284
310
  "aria-label": themeSelectAriaLabel,
285
311
  children: /* @__PURE__ */ jsx(
@@ -300,61 +326,117 @@ const FooterBase = ({
300
326
  brandTitle2 && /* @__PURE__ */ jsx(
301
327
  "span",
302
328
  {
303
- className: classMap.brandTitle,
329
+ className: combineClassNames(
330
+ classMap.brandTitle,
331
+ brandTitleClassName
332
+ ),
304
333
  "data-testid": `${testId}-brand-title`,
305
334
  children: brandTitle2
306
335
  }
307
336
  )
308
337
  ] });
309
- return /* @__PURE__ */ jsxs("div", { className: classMap.brand, "data-testid": `${testId}-brand`, children: [
310
- brandHref ? /* @__PURE__ */ jsx(
311
- LinkWrapper,
312
- {
313
- href: brandHref,
314
- className: classMap.brandLink,
315
- "aria-label": typeof brandTitle2 === "string" ? brandTitle2 : logoAriaLabel,
316
- children: brandContent
317
- }
318
- ) : /* @__PURE__ */ jsx("div", { className: classMap.brandLink, children: brandContent }),
319
- brandDescription2 && /* @__PURE__ */ jsx(
320
- "p",
321
- {
322
- className: classMap.brandDescription,
323
- "data-testid": `${testId}-brand-description`,
324
- children: brandDescription2
325
- }
326
- ),
327
- copyright2 && !shouldRenderCopyrightInBottom && /* @__PURE__ */ jsx(
328
- "div",
329
- {
330
- className: classMap.copyright,
331
- "data-testid": `${testId}-copyright`,
332
- children: /* @__PURE__ */ jsx("p", { id: labelId, children: copyright2 })
333
- }
334
- )
335
- ] });
338
+ return /* @__PURE__ */ jsxs(
339
+ "div",
340
+ {
341
+ className: combineClassNames(classMap.brand, brandClassName),
342
+ "data-testid": `${testId}-brand`,
343
+ children: [
344
+ brandHref ? /* @__PURE__ */ jsx(
345
+ LinkWrapper,
346
+ {
347
+ href: brandHref,
348
+ className: combineClassNames(
349
+ classMap.brandLink,
350
+ brandLinkClassName
351
+ ),
352
+ "aria-label": typeof brandTitle2 === "string" ? brandTitle2 : logoAriaLabel,
353
+ children: brandContent
354
+ }
355
+ ) : /* @__PURE__ */ jsx(
356
+ "div",
357
+ {
358
+ className: combineClassNames(
359
+ classMap.brandLink,
360
+ brandLinkClassName
361
+ ),
362
+ children: brandContent
363
+ }
364
+ ),
365
+ brandDescription2 && /* @__PURE__ */ jsx(
366
+ "p",
367
+ {
368
+ className: combineClassNames(
369
+ classMap.brandDescription,
370
+ brandDescriptionClassName
371
+ ),
372
+ "data-testid": `${testId}-brand-description`,
373
+ children: brandDescription2
374
+ }
375
+ ),
376
+ copyright2 && !shouldRenderCopyrightInBottom && /* @__PURE__ */ jsx(
377
+ "div",
378
+ {
379
+ className: combineClassNames(
380
+ classMap.copyright,
381
+ copyrightClassName
382
+ ),
383
+ "data-testid": `${testId}-copyright`,
384
+ children: /* @__PURE__ */ jsx("p", { id: labelId, children: copyright2 })
385
+ }
386
+ )
387
+ ]
388
+ }
389
+ );
336
390
  };
337
391
  const renderSections = () => {
338
392
  if (normalizedSections.length === 0) {
339
393
  return null;
340
394
  }
341
- return /* @__PURE__ */ jsx("div", { className: classMap.sections, "data-testid": `${testId}-sections`, children: normalizedSections.map((section2, sectionIndex) => {
342
- const titleText = typeof section2.title === "string" ? section2.title : `section-${sectionIndex + 1}`;
343
- const sectionSlug = section2.testId ?? slugify(titleText);
344
- return /* @__PURE__ */ jsxs(
345
- "nav",
346
- {
347
- className: classMap.section,
348
- "aria-label": section2["aria-label"] ?? `${titleText} links`,
349
- "data-testid": `${testId}-section-${sectionSlug}`,
350
- children: [
351
- /* @__PURE__ */ jsx("h2", { className: classMap.sectionTitle, children: section2.title }),
352
- /* @__PURE__ */ jsx("ul", { className: classMap.sectionList, children: section2.links.map(renderFooterLink) })
353
- ]
354
- },
355
- sectionSlug
356
- );
357
- }) });
395
+ return /* @__PURE__ */ jsx(
396
+ "div",
397
+ {
398
+ className: combineClassNames(classMap.sections, sectionsClassName),
399
+ "data-testid": `${testId}-sections`,
400
+ children: normalizedSections.map((section2, sectionIndex) => {
401
+ const titleText = typeof section2.title === "string" ? section2.title : `section-${sectionIndex + 1}`;
402
+ const sectionSlug = section2.testId ?? slugify(titleText);
403
+ return /* @__PURE__ */ jsxs(
404
+ "nav",
405
+ {
406
+ className: combineClassNames(classMap.section, section2.className),
407
+ "aria-label": section2["aria-label"] ?? `${titleText} links`,
408
+ "data-testid": `${testId}-section-${sectionSlug}`,
409
+ children: [
410
+ /* @__PURE__ */ jsx(
411
+ "h2",
412
+ {
413
+ className: combineClassNames(
414
+ classMap.sectionTitle,
415
+ sectionTitleClassName,
416
+ section2.titleClassName
417
+ ),
418
+ children: section2.title
419
+ }
420
+ ),
421
+ /* @__PURE__ */ jsx(
422
+ "ul",
423
+ {
424
+ className: combineClassNames(
425
+ classMap.sectionList,
426
+ section2.listClassName
427
+ ),
428
+ children: section2.links.map(
429
+ (link2, index) => renderFooterLink(link2, index, section2.linkClassName)
430
+ )
431
+ }
432
+ )
433
+ ]
434
+ },
435
+ sectionSlug
436
+ );
437
+ })
438
+ }
439
+ );
358
440
  };
359
441
  if (layout === "columns") {
360
442
  return /* @__PURE__ */ jsxs(
@@ -368,36 +450,74 @@ const FooterBase = ({
368
450
  "aria-describedby": ariaDescribedBy,
369
451
  ...rest,
370
452
  children: [
371
- /* @__PURE__ */ jsxs("div", { className: classMap.content, children: [
453
+ /* @__PURE__ */ jsxs("div", { className: combineClassNames(classMap.content, contentClassName), children: [
372
454
  renderBrand(),
373
455
  renderSections(),
374
- (socialLinks.length > 0 || showThemeSelect) && /* @__PURE__ */ jsxs("div", { className: classMap.actions, "data-testid": `${testId}-actions`, children: [
375
- socialLinks.length > 0 && /* @__PURE__ */ jsxs("div", { className: classMap.actionGroup, children: [
376
- /* @__PURE__ */ jsx("h2", { className: classMap.sectionTitle, children: "Connect" }),
377
- renderSocialLinks()
378
- ] }),
379
- renderThemeSelect()
380
- ] })
381
- ] }),
382
- (copyright2 || bottomEnd2) && /* @__PURE__ */ jsxs("div", { className: classMap.bottom, "data-testid": `${testId}-bottom`, children: [
383
- copyright2 && shouldRenderCopyrightInBottom && /* @__PURE__ */ jsx(
384
- "p",
385
- {
386
- id: labelId,
387
- className: classMap.bottomCopyright,
388
- "data-testid": `${testId}-copyright`,
389
- children: copyright2
390
- }
391
- ),
392
- bottomEnd2 && /* @__PURE__ */ jsx(
456
+ (socialLinks.length > 0 || showThemeSelect) && /* @__PURE__ */ jsxs(
393
457
  "div",
394
458
  {
395
- className: classMap.bottomEnd,
396
- "data-testid": `${testId}-bottom-end`,
397
- children: bottomEnd2
459
+ className: combineClassNames(classMap.actions, actionsClassName),
460
+ "data-testid": `${testId}-actions`,
461
+ children: [
462
+ socialLinks.length > 0 && /* @__PURE__ */ jsxs(
463
+ "div",
464
+ {
465
+ className: combineClassNames(
466
+ classMap.actionGroup,
467
+ actionGroupClassName
468
+ ),
469
+ children: [
470
+ /* @__PURE__ */ jsx(
471
+ "h2",
472
+ {
473
+ className: combineClassNames(
474
+ classMap.sectionTitle,
475
+ sectionTitleClassName
476
+ ),
477
+ children: "Connect"
478
+ }
479
+ ),
480
+ renderSocialLinks()
481
+ ]
482
+ }
483
+ ),
484
+ renderThemeSelect()
485
+ ]
398
486
  }
399
487
  )
400
- ] })
488
+ ] }),
489
+ (copyright2 || bottomEnd2) && /* @__PURE__ */ jsxs(
490
+ "div",
491
+ {
492
+ className: combineClassNames(classMap.bottom, bottomClassName),
493
+ "data-testid": `${testId}-bottom`,
494
+ children: [
495
+ copyright2 && shouldRenderCopyrightInBottom && /* @__PURE__ */ jsx(
496
+ "p",
497
+ {
498
+ id: labelId,
499
+ className: combineClassNames(
500
+ classMap.bottomCopyright,
501
+ bottomCopyrightClassName
502
+ ),
503
+ "data-testid": `${testId}-copyright`,
504
+ children: copyright2
505
+ }
506
+ ),
507
+ bottomEnd2 && /* @__PURE__ */ jsx(
508
+ "div",
509
+ {
510
+ className: combineClassNames(
511
+ classMap.bottomEnd,
512
+ bottomEndClassName
513
+ ),
514
+ "data-testid": `${testId}-bottom-end`,
515
+ children: bottomEnd2
516
+ }
517
+ )
518
+ ]
519
+ }
520
+ )
401
521
  ]
402
522
  }
403
523
  );
@@ -412,25 +532,34 @@ const FooterBase = ({
412
532
  "aria-labelledby": ariaLabelledBy ?? labelId,
413
533
  "aria-describedby": ariaDescribedBy,
414
534
  ...rest,
415
- children: /* @__PURE__ */ jsxs("div", { className: classMap.content, children: [
416
- /* @__PURE__ */ jsxs("div", { className: classMap.left, "data-testid": `${testId}-left`, children: [
417
- renderLogo(),
418
- copyright2 && /* @__PURE__ */ jsx(
419
- "div",
420
- {
421
- className: classMap.copyright ?? classMap.left,
422
- "data-testid": `${testId}-copyright`,
423
- children: /* @__PURE__ */ jsx("p", { id: labelId, children: copyright2 })
424
- }
425
- )
426
- ] }),
535
+ children: /* @__PURE__ */ jsxs("div", { className: combineClassNames(classMap.content, contentClassName), children: [
536
+ /* @__PURE__ */ jsxs(
537
+ "div",
538
+ {
539
+ className: combineClassNames(classMap.left, leftClassName),
540
+ "data-testid": `${testId}-left`,
541
+ children: [
542
+ renderLogo(),
543
+ copyright2 && /* @__PURE__ */ jsx(
544
+ "div",
545
+ {
546
+ className: combineClassNames(classMap.copyright, copyrightClassName) ?? combineClassNames(classMap.left, leftClassName),
547
+ "data-testid": `${testId}-copyright`,
548
+ children: /* @__PURE__ */ jsx("p", { id: labelId, children: copyright2 })
549
+ }
550
+ )
551
+ ]
552
+ }
553
+ ),
427
554
  links2.length > 0 && /* @__PURE__ */ jsx(
428
555
  "nav",
429
556
  {
430
- className: classMap.links,
557
+ className: combineClassNames(classMap.links, linksClassName),
431
558
  "aria-label": navAriaLabel,
432
559
  "data-testid": `${testId}-nav`,
433
- children: /* @__PURE__ */ jsx("ul", { children: links2.map(renderFooterLink) })
560
+ children: /* @__PURE__ */ jsx("ul", { children: links2.map(
561
+ (link2, index) => renderFooterLink(link2, index, linkClassName)
562
+ ) })
434
563
  }
435
564
  ),
436
565
  renderThemeSelect(),
@@ -495,4 +624,4 @@ export {
495
624
  Footer as F,
496
625
  UserThemeSettings as U
497
626
  };
498
- //# sourceMappingURL=Footer-Dzwh3OnQ.js.map
627
+ //# sourceMappingURL=Footer-DLnIK3R3.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Footer-DLnIK3R3.js","sources":["../../src/components/Footer/FooterBase.tsx","../../src/components/Select/ThemeSelect/next/ThemeSelect.tsx","../../src/components/Footer/next/Footer.tsx"],"sourcesContent":["import React, { useMemo } from \"react\";\r\nimport {\r\n BaseFooterProps,\r\n FooterLink,\r\n FooterSection,\r\n LogoSource,\r\n} from \"./Footer.types\";\r\nimport { combineClassNames } from \"../../utils/classNames\";\r\nimport { getDefaultTheme } from \"../../config/boreal-style-config\";\r\nimport { capitalize } from \"@/utils/capitalize\";\r\n\r\nconst slugify = (value: string) =>\r\n value.toLowerCase().trim().replace(/\\s+/g, \"-\");\r\n\r\nconst FooterBase: React.FC<BaseFooterProps> = ({\r\n theme = getDefaultTheme(),\r\n attachment = \"static\",\r\n shadow = \"none\",\r\n rounding = \"none\",\r\n layout = \"inline\",\r\n className = \"\",\r\n \"data-testid\": testId = \"footer\",\r\n\r\n copyright,\r\n copyrightInBottom,\r\n links = [],\r\n sections,\r\n logo,\r\n brandTitle,\r\n brandDescription,\r\n brandHref,\r\n\r\n socialLinks = [],\r\n showThemeSelect = false,\r\n bottomEnd,\r\n\r\n contentClassName,\r\n leftClassName,\r\n linksClassName,\r\n linkClassName,\r\n logoClassName,\r\n socialClassName,\r\n themeToggleClassName,\r\n\r\n brandClassName,\r\n brandLinkClassName,\r\n brandTitleClassName,\r\n brandDescriptionClassName,\r\n\r\n sectionsClassName,\r\n sectionTitleClassName,\r\n actionsClassName,\r\n actionGroupClassName,\r\n\r\n bottomClassName,\r\n bottomCopyrightClassName,\r\n bottomEndClassName,\r\n copyrightClassName,\r\n\r\n IconButton,\r\n ImageComponent = \"img\",\r\n ThemeSelect,\r\n classMap,\r\n LinkWrapper = ({ href, children, ...rest }) => (\r\n <a href={href} {...rest}>\r\n {children}\r\n </a>\r\n ),\r\n\r\n \"aria-label\": ariaLabel,\r\n \"aria-labelledby\": ariaLabelledBy,\r\n \"aria-describedby\": ariaDescribedBy,\r\n navAriaLabel = \"Footer site links\",\r\n socialNavAriaLabel = \"Social media\",\r\n themeSelectAriaLabel = \"Theme selector\",\r\n logoAriaLabel = \"Logo\",\r\n logoDecorative = false,\r\n labelId,\r\n ...rest\r\n}) => {\r\n const footerClass = useMemo(\r\n () =>\r\n combineClassNames(\r\n classMap.footer,\r\n classMap[theme],\r\n layout !== \"inline\" && classMap[`layout${capitalize(layout)}`],\r\n shadow !== \"none\" && classMap[`shadow${capitalize(shadow)}`],\r\n rounding !== \"none\" && classMap[`round${capitalize(rounding)}`],\r\n classMap[`attachment${capitalize(attachment)}`],\r\n className,\r\n ),\r\n [classMap, theme, layout, shadow, rounding, attachment, className],\r\n );\r\n\r\n const isLogoImage = (\r\n value: unknown,\r\n ): value is { src: string; width?: number; height?: number } =>\r\n typeof value === \"object\" &&\r\n value !== null &&\r\n \"src\" in (value as Record<string, unknown>);\r\n\r\n const isImgLike = typeof logo === \"string\" || isLogoImage(logo);\r\n\r\n const imgLogo = isImgLike\r\n ? typeof logo === \"string\"\r\n ? { src: logo }\r\n : logo\r\n : undefined;\r\n\r\n const logoSrc = imgLogo?.src;\r\n const logoW = imgLogo?.width ?? 20;\r\n const logoH = imgLogo?.height ?? 20;\r\n\r\n const normalizedSections: FooterSection[] =\r\n sections && sections.length > 0\r\n ? sections\r\n : links.length > 0\r\n ? [\r\n {\r\n title: \"Links\",\r\n links,\r\n \"aria-label\": navAriaLabel,\r\n testId: \"links\",\r\n },\r\n ]\r\n : [];\r\n\r\n const shouldRenderCopyrightInBottom =\r\n copyrightInBottom ?? layout === \"columns\";\r\n\r\n const renderLogo = () => {\r\n if (isImgLike && logoSrc) {\r\n if (typeof ImageComponent === \"string\") {\r\n return (\r\n <img\r\n className={combineClassNames(classMap.logo, logoClassName)}\r\n data-testid={`${testId}-logo`}\r\n loading=\"lazy\"\r\n src={logoSrc}\r\n alt={logoDecorative ? \"\" : logoAriaLabel}\r\n aria-hidden={logoDecorative ? true : undefined}\r\n height={logoH}\r\n width={logoW}\r\n />\r\n );\r\n }\r\n\r\n return (\r\n <ImageComponent\r\n className={combineClassNames(classMap.logo, logoClassName)}\r\n data-testid={`${testId}-logo`}\r\n src={logoSrc}\r\n alt={logoDecorative ? \"\" : logoAriaLabel}\r\n aria-hidden={logoDecorative ? true : undefined}\r\n height={logoH}\r\n width={logoW}\r\n />\r\n );\r\n }\r\n\r\n if (!logo) {\r\n return null;\r\n }\r\n\r\n return (\r\n <span\r\n className={combineClassNames(classMap.logo, logoClassName)}\r\n role={logoDecorative ? undefined : \"img\"}\r\n aria-label={logoDecorative ? undefined : logoAriaLabel}\r\n aria-hidden={logoDecorative ? true : undefined}\r\n data-testid={`${testId}-logo`}\r\n >\r\n {\r\n logo as Exclude<\r\n LogoSource,\r\n string | { src: string; width?: number; height?: number }\r\n >\r\n }\r\n </span>\r\n );\r\n };\r\n\r\n const renderFooterLink = (\r\n link: FooterLink,\r\n index: number,\r\n customLinkClassName?: string,\r\n ) => {\r\n const slug = slugify(link.label || link.href || `link-${index}`);\r\n const key = `${link.href ?? slug}-${index}`;\r\n const resolvedLinkClassName = combineClassNames(\r\n classMap.link,\r\n customLinkClassName,\r\n );\r\n\r\n if (link.disabled) {\r\n return (\r\n <li key={key}>\r\n <span\r\n className={resolvedLinkClassName}\r\n data-testid={`${testId}-link-${slug}`}\r\n aria-disabled=\"true\"\r\n title={link.title}\r\n >\r\n {link.label}\r\n </span>\r\n </li>\r\n );\r\n }\r\n\r\n return (\r\n <li key={key}>\r\n <LinkWrapper\r\n href={link.href}\r\n className={resolvedLinkClassName}\r\n data-testid={`${testId}-link-${slug}`}\r\n aria-label={link[\"aria-label\"]}\r\n aria-current={link[\"aria-current\"]}\r\n title={link.title}\r\n rel={link.rel}\r\n target={link.target}\r\n >\r\n {link.label}\r\n </LinkWrapper>\r\n </li>\r\n );\r\n };\r\n\r\n const renderSocialLinks = () => {\r\n if (socialLinks.length === 0) {\r\n return null;\r\n }\r\n\r\n return (\r\n <nav\r\n className={combineClassNames(classMap.social, socialClassName)}\r\n aria-label={socialNavAriaLabel}\r\n data-testid={`${testId}-social`}\r\n >\r\n {socialLinks.map((social, index) => (\r\n <IconButton\r\n key={`${social.href ?? social.title}-${index}`}\r\n icon={social.icon}\r\n href={social.href}\r\n isExternal={social.isExternal ?? true}\r\n shadow=\"none\"\r\n aria-label={social[\"aria-label\"] ?? social.title}\r\n title={social.tooltip ?? social.title}\r\n theme=\"clear\"\r\n disabled={social.disabled}\r\n rel={social.rel}\r\n target={social.target}\r\n data-testid={`${testId}-social-${slugify(social.title)}`}\r\n />\r\n ))}\r\n </nav>\r\n );\r\n };\r\n\r\n const renderThemeSelect = () => {\r\n if (!showThemeSelect) {\r\n return null;\r\n }\r\n\r\n return (\r\n <div\r\n className={combineClassNames(\r\n classMap.themeToggle,\r\n themeToggleClassName,\r\n )}\r\n data-testid={`${testId}-theme-select`}\r\n aria-label={themeSelectAriaLabel}\r\n >\r\n <ThemeSelect\r\n theme=\"clear\"\r\n label={brandDescription}\r\n shadow=\"none\"\r\n aria-label={themeSelectAriaLabel}\r\n />\r\n </div>\r\n );\r\n };\r\n\r\n const renderBrand = () => {\r\n const brandContent = (\r\n <>\r\n {renderLogo()}\r\n\r\n {brandTitle && (\r\n <span\r\n className={combineClassNames(\r\n classMap.brandTitle,\r\n brandTitleClassName,\r\n )}\r\n data-testid={`${testId}-brand-title`}\r\n >\r\n {brandTitle}\r\n </span>\r\n )}\r\n </>\r\n );\r\n\r\n return (\r\n <div\r\n className={combineClassNames(classMap.brand, brandClassName)}\r\n data-testid={`${testId}-brand`}\r\n >\r\n {brandHref ? (\r\n <LinkWrapper\r\n href={brandHref}\r\n className={combineClassNames(\r\n classMap.brandLink,\r\n brandLinkClassName,\r\n )}\r\n aria-label={\r\n typeof brandTitle === \"string\" ? brandTitle : logoAriaLabel\r\n }\r\n >\r\n {brandContent}\r\n </LinkWrapper>\r\n ) : (\r\n <div\r\n className={combineClassNames(\r\n classMap.brandLink,\r\n brandLinkClassName,\r\n )}\r\n >\r\n {brandContent}\r\n </div>\r\n )}\r\n\r\n {brandDescription && (\r\n <p\r\n className={combineClassNames(\r\n classMap.brandDescription,\r\n brandDescriptionClassName,\r\n )}\r\n data-testid={`${testId}-brand-description`}\r\n >\r\n {brandDescription}\r\n </p>\r\n )}\r\n\r\n {copyright && !shouldRenderCopyrightInBottom && (\r\n <div\r\n className={combineClassNames(\r\n classMap.copyright,\r\n copyrightClassName,\r\n )}\r\n data-testid={`${testId}-copyright`}\r\n >\r\n <p id={labelId}>{copyright}</p>\r\n </div>\r\n )}\r\n </div>\r\n );\r\n };\r\n\r\n const renderSections = () => {\r\n if (normalizedSections.length === 0) {\r\n return null;\r\n }\r\n\r\n return (\r\n <div\r\n className={combineClassNames(classMap.sections, sectionsClassName)}\r\n data-testid={`${testId}-sections`}\r\n >\r\n {normalizedSections.map((section, sectionIndex) => {\r\n const titleText =\r\n typeof section.title === \"string\"\r\n ? section.title\r\n : `section-${sectionIndex + 1}`;\r\n\r\n const sectionSlug = section.testId ?? slugify(titleText);\r\n\r\n return (\r\n <nav\r\n key={sectionSlug}\r\n className={combineClassNames(classMap.section, section.className)}\r\n aria-label={section[\"aria-label\"] ?? `${titleText} links`}\r\n data-testid={`${testId}-section-${sectionSlug}`}\r\n >\r\n <h2\r\n className={combineClassNames(\r\n classMap.sectionTitle,\r\n sectionTitleClassName,\r\n section.titleClassName,\r\n )}\r\n >\r\n {section.title}\r\n </h2>\r\n\r\n <ul\r\n className={combineClassNames(\r\n classMap.sectionList,\r\n section.listClassName,\r\n )}\r\n >\r\n {section.links.map((link, index) =>\r\n renderFooterLink(link, index, section.linkClassName),\r\n )}\r\n </ul>\r\n </nav>\r\n );\r\n })}\r\n </div>\r\n );\r\n };\r\n\r\n if (layout === \"columns\") {\r\n return (\r\n <footer\r\n className={footerClass}\r\n data-testid={testId}\r\n role=\"contentinfo\"\r\n aria-label={ariaLabel}\r\n aria-labelledby={ariaLabelledBy ?? labelId}\r\n aria-describedby={ariaDescribedBy}\r\n {...rest}\r\n >\r\n <div className={combineClassNames(classMap.content, contentClassName)}>\r\n {renderBrand()}\r\n\r\n {renderSections()}\r\n\r\n {(socialLinks.length > 0 || showThemeSelect) && (\r\n <div\r\n className={combineClassNames(classMap.actions, actionsClassName)}\r\n data-testid={`${testId}-actions`}\r\n >\r\n {socialLinks.length > 0 && (\r\n <div\r\n className={combineClassNames(\r\n classMap.actionGroup,\r\n actionGroupClassName,\r\n )}\r\n >\r\n <h2\r\n className={combineClassNames(\r\n classMap.sectionTitle,\r\n sectionTitleClassName,\r\n )}\r\n >\r\n Connect\r\n </h2>\r\n {renderSocialLinks()}\r\n </div>\r\n )}\r\n\r\n {renderThemeSelect()}\r\n </div>\r\n )}\r\n </div>\r\n\r\n {(copyright || bottomEnd) && (\r\n <div\r\n className={combineClassNames(classMap.bottom, bottomClassName)}\r\n data-testid={`${testId}-bottom`}\r\n >\r\n {copyright && shouldRenderCopyrightInBottom && (\r\n <p\r\n id={labelId}\r\n className={combineClassNames(\r\n classMap.bottomCopyright,\r\n bottomCopyrightClassName,\r\n )}\r\n data-testid={`${testId}-copyright`}\r\n >\r\n {copyright}\r\n </p>\r\n )}\r\n\r\n {bottomEnd && (\r\n <div\r\n className={combineClassNames(\r\n classMap.bottomEnd,\r\n bottomEndClassName,\r\n )}\r\n data-testid={`${testId}-bottom-end`}\r\n >\r\n {bottomEnd}\r\n </div>\r\n )}\r\n </div>\r\n )}\r\n </footer>\r\n );\r\n }\r\n\r\n return (\r\n <footer\r\n className={footerClass}\r\n data-testid={testId}\r\n role=\"contentinfo\"\r\n aria-label={ariaLabel}\r\n aria-labelledby={ariaLabelledBy ?? labelId}\r\n aria-describedby={ariaDescribedBy}\r\n {...rest}\r\n >\r\n <div className={combineClassNames(classMap.content, contentClassName)}>\r\n <div\r\n className={combineClassNames(classMap.left, leftClassName)}\r\n data-testid={`${testId}-left`}\r\n >\r\n {renderLogo()}\r\n\r\n {copyright && (\r\n <div\r\n className={\r\n combineClassNames(classMap.copyright, copyrightClassName) ??\r\n combineClassNames(classMap.left, leftClassName)\r\n }\r\n data-testid={`${testId}-copyright`}\r\n >\r\n <p id={labelId}>{copyright}</p>\r\n </div>\r\n )}\r\n </div>\r\n\r\n {links.length > 0 && (\r\n <nav\r\n className={combineClassNames(classMap.links, linksClassName)}\r\n aria-label={navAriaLabel}\r\n data-testid={`${testId}-nav`}\r\n >\r\n <ul>\r\n {links.map((link, index) =>\r\n renderFooterLink(link, index, linkClassName),\r\n )}\r\n </ul>\r\n </nav>\r\n )}\r\n\r\n {renderThemeSelect()}\r\n {renderSocialLinks()}\r\n </div>\r\n </footer>\r\n );\r\n};\r\n\r\nFooterBase.displayName = \"FooterBase\";\r\nexport default FooterBase;\r\n","\"use client\";\r\n\r\nimport { useContext, useMemo, forwardRef } from \"react\";\r\nimport { Select } from \"@/index.next\";\r\nimport { ThemeContext } from \"../../../../context/ThemeContext\";\r\nimport {\r\n getDefaultRounding,\r\n getDefaultShadow,\r\n getDefaultTheme,\r\n} from \"@/config/boreal-style-config\";\r\nimport { ThemeSelectProps } from \"../../Select.types\";\r\n\r\nconst UserThemeSettings = forwardRef<HTMLSelectElement, ThemeSelectProps>(\r\n (\r\n {\r\n theme = getDefaultTheme(),\r\n shadow = getDefaultShadow(),\r\n rounding = getDefaultRounding(),\r\n state = \"\",\r\n \"data-testid\": testId = \"theme-select\",\r\n },\r\n ref,\r\n ) => {\r\n const ctx = useContext(ThemeContext);\r\n if (!ctx)\r\n throw new Error(\"ThemeContext is undefined. Wrap with ThemeProvider.\");\r\n\r\n const { selectedScheme, setSelectedScheme, schemes } = ctx;\r\n\r\n const options = useMemo(\r\n () =>\r\n schemes.map((scheme, index) => ({\r\n value: String(index),\r\n label: scheme.name,\r\n })),\r\n [schemes],\r\n );\r\n\r\n return (\r\n <div className={`control-container`}>\r\n <Select\r\n ref={ref}\r\n theme={theme}\r\n state={state}\r\n shadow={shadow}\r\n rounding={rounding}\r\n options={options}\r\n data-testid={testId}\r\n value={String(selectedScheme)}\r\n aria-label=\"Select Theme\"\r\n onChange={(value: string | number) =>\r\n setSelectedScheme(parseInt(String(value), 10))\r\n }\r\n />\r\n </div>\r\n );\r\n },\r\n);\r\nUserThemeSettings.displayName = \"UserThemeSettings\";\r\nexport default UserThemeSettings;\r\n","\"use client\";\r\n\r\nimport React from \"react\";\r\nimport Link from \"next/link\";\r\nimport Image from \"next/image\";\r\n\r\nimport FooterBase from \"../FooterBase\";\r\nimport { FooterProps } from \"../Footer.types\";\r\nimport IconButton from \"../../IconButton/next/IconButton\";\r\nimport ThemeSelect from \"../../Select/ThemeSelect/next/ThemeSelect\";\r\n\r\nimport styles from \"./Footer.module.scss\";\r\n\r\nconst Footer: React.FC<FooterProps> = (props) => {\r\n return (\r\n <FooterBase\r\n {...props}\r\n IconButton={IconButton}\r\n ImageComponent={Image}\r\n ThemeSelect={ThemeSelect}\r\n LinkWrapper={({ href, children, className, ...rest }) => (\r\n <Link href={href} className={className} {...rest}>\r\n {children}\r\n </Link>\r\n )}\r\n classMap={styles}\r\n />\r\n );\r\n};\r\n\r\nFooter.displayName = \"Footer\";\r\n\r\nexport default Footer;\r\n"],"names":["copyright","links","sections","logo","brandTitle","brandDescription","bottomEnd","IconButton","rest","link","social","section","ThemeSelect"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAWA,MAAM,UAAU,CAAC,UACf,MAAM,YAAA,EAAc,OAAO,QAAQ,QAAQ,GAAG;AAEhD,MAAM,aAAwC,CAAC;AAAA,EAC7C,QAAQ,gBAAA;AAAA,EACR,aAAa;AAAA,EACb,SAAS;AAAA,EACT,WAAW;AAAA,EACX,SAAS;AAAA,EACT,YAAY;AAAA,EACZ,eAAe,SAAS;AAAA,EAExB,WAAAA;AAAA,EACA;AAAA,EACA,OAAAC,SAAQ,CAAA;AAAA,EACR,UAAAC;AAAA,EACA,MAAAC;AAAA,EACA,YAAAC;AAAA,EACA,kBAAAC;AAAA,EACA;AAAA,EAEA,cAAc,CAAA;AAAA,EACd,kBAAkB;AAAA,EAClB,WAAAC;AAAA,EAEA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EAEA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EAEA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EAEA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EAEA,YAAAC;AAAA,EACA,iBAAiB;AAAA,EACjB;AAAA,EACA;AAAA,EACA,cAAc,CAAC,EAAE,MAAM,UAAU,GAAGC,MAAAA,MAClC,oBAAC,KAAA,EAAE,MAAa,GAAGA,OAChB,SAAA,CACH;AAAA,EAG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