@deriv-web-design/ui 0.0.8 → 0.0.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -2257,26 +2257,98 @@ var CTABanner = ({
2257
2257
 
2258
2258
  // components/Navbar/Navbar.tsx
2259
2259
  import { useRef as useRef7, useState as useState8, useEffect as useEffect6, useCallback as useCallback2 } from "react";
2260
+ import { motion as motion2, AnimatePresence } from "framer-motion";
2260
2261
 
2261
2262
  // assets/icon-globe.svg
2262
2263
  var icon_globe_default = "./icon-globe-S54WYYEK.svg";
2263
2264
 
2264
2265
  // components/Navbar/Navbar.tsx
2265
2266
  import { jsx as jsx23, jsxs as jsxs22 } from "react/jsx-runtime";
2266
- var ChevronDownIcon3 = ({ className }) => /* @__PURE__ */ jsx23("svg", { className, width: "14", height: "14", viewBox: "0 0 14 14", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ jsx23("path", { d: "M2.625 4.8125L7 9.1875L11.375 4.8125", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
2267
- var ArrowRightIcon = () => /* @__PURE__ */ jsx23("svg", { width: "14", height: "14", viewBox: "0 0 14 14", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ jsx23("path", { d: "M2.625 7H11.375M11.375 7L7.875 3.5M11.375 7L7.875 10.5", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
2268
- var ArrowRightSmIcon = () => /* @__PURE__ */ jsx23("svg", { className: "navbar__lang-option-arrow", width: "12", height: "12", viewBox: "0 0 12 12", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ jsx23("path", { d: "M2.5 6H9.5M9.5 6L6.5 3M9.5 6L6.5 9", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
2269
- var ArrowUpRightIcon = () => /* @__PURE__ */ jsx23("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ jsx23("path", { d: "M4.5 11.5L11.5 4.5M11.5 4.5H5.5M11.5 4.5V10.5", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
2270
- var BarsIcon = () => /* @__PURE__ */ jsx23("svg", { width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ jsx23("path", { d: "M2.5 5H17.5M2.5 10H17.5M2.5 15H17.5", stroke: "currentColor", strokeWidth: "1.75", strokeLinecap: "round" }) });
2271
- var XMarkIcon2 = () => /* @__PURE__ */ jsx23("svg", { width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ jsx23("path", { d: "M15 5L5 15M5 5L15 15", stroke: "currentColor", strokeWidth: "1.75", strokeLinecap: "round" }) });
2267
+ var EASE_OUT_EXPO = [0.16, 1, 0.3, 1];
2268
+ var dropdownVariants = {
2269
+ hidden: { opacity: 0, scale: 0.96, y: -8 },
2270
+ visible: { opacity: 1, scale: 1, y: 0 }
2271
+ };
2272
+ var drawerVariants = {
2273
+ hidden: { y: "-100%" },
2274
+ visible: { y: 0 }
2275
+ };
2276
+ var accordionVariants = {
2277
+ hidden: { height: 0, opacity: 0 },
2278
+ visible: { height: "auto", opacity: 1 }
2279
+ };
2280
+ var ChevronDownIcon3 = ({ className }) => /* @__PURE__ */ jsx23(
2281
+ "svg",
2282
+ {
2283
+ className,
2284
+ width: "14",
2285
+ height: "14",
2286
+ viewBox: "0 0 14 14",
2287
+ fill: "none",
2288
+ "aria-hidden": "true",
2289
+ children: /* @__PURE__ */ jsx23(
2290
+ "path",
2291
+ {
2292
+ d: "M2.625 4.8125L7 9.1875L11.375 4.8125",
2293
+ stroke: "currentColor",
2294
+ strokeWidth: "1.5",
2295
+ strokeLinecap: "round",
2296
+ strokeLinejoin: "round"
2297
+ }
2298
+ )
2299
+ }
2300
+ );
2301
+ var ArrowRightIcon = () => /* @__PURE__ */ jsx23("svg", { width: "14", height: "14", viewBox: "0 0 14 14", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ jsx23(
2302
+ "path",
2303
+ {
2304
+ d: "M2.625 7H11.375M11.375 7L7.875 3.5M11.375 7L7.875 10.5",
2305
+ stroke: "currentColor",
2306
+ strokeWidth: "1.5",
2307
+ strokeLinecap: "round",
2308
+ strokeLinejoin: "round"
2309
+ }
2310
+ ) });
2311
+ var ArrowUpRightIcon = () => /* @__PURE__ */ jsx23("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ jsx23(
2312
+ "path",
2313
+ {
2314
+ d: "M4.5 11.5L11.5 4.5M11.5 4.5H5.5M11.5 4.5V10.5",
2315
+ stroke: "currentColor",
2316
+ strokeWidth: "1.5",
2317
+ strokeLinecap: "round",
2318
+ strokeLinejoin: "round"
2319
+ }
2320
+ ) });
2321
+ var BarsIcon = () => /* @__PURE__ */ jsx23("svg", { width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ jsx23(
2322
+ "path",
2323
+ {
2324
+ d: "M2.5 5H17.5M2.5 10H17.5M2.5 15H17.5",
2325
+ stroke: "currentColor",
2326
+ strokeWidth: "1.75",
2327
+ strokeLinecap: "round"
2328
+ }
2329
+ ) });
2330
+ var XMarkIcon2 = () => /* @__PURE__ */ jsx23("svg", { width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ jsx23(
2331
+ "path",
2332
+ {
2333
+ d: "M15 5L5 15M5 5L15 15",
2334
+ stroke: "currentColor",
2335
+ strokeWidth: "1.75",
2336
+ strokeLinecap: "round"
2337
+ }
2338
+ ) });
2272
2339
  var GlobeIcon = ({ className }) => /* @__PURE__ */ jsx23("img", { src: icon_globe_default, alt: "", "aria-hidden": "true", width: "20", height: "20", className });
2273
- var DropdownPanel = ({ item, isOpen, onMouseEnter, onMouseLeave }) => {
2340
+ var DropdownPanel = ({ item, onMouseEnter, onMouseLeave }) => {
2274
2341
  const { dropdown } = item;
2275
2342
  if (!dropdown) return null;
2276
2343
  return /* @__PURE__ */ jsx23(
2277
- "div",
2344
+ motion2.div,
2278
2345
  {
2279
- className: ["navbar__dropdown", isOpen ? "navbar__dropdown--open" : ""].filter(Boolean).join(" "),
2346
+ className: "navbar__dropdown",
2347
+ variants: dropdownVariants,
2348
+ initial: "hidden",
2349
+ animate: "visible",
2350
+ exit: "hidden",
2351
+ transition: { duration: 0.18, ease: EASE_OUT_EXPO },
2280
2352
  onMouseEnter,
2281
2353
  onMouseLeave,
2282
2354
  children: /* @__PURE__ */ jsxs22("div", { className: "navbar__dropdown-inner", children: [
@@ -2308,17 +2380,32 @@ var FeatureCard = ({ feature, mobile }) => /* @__PURE__ */ jsxs22(
2308
2380
  className: mobile ? "navbar__drawer-feature" : "navbar__dropdown-feature",
2309
2381
  style: feature.backgroundImageUrl ? { backgroundImage: `url(${feature.backgroundImageUrl})` } : void 0,
2310
2382
  children: [
2311
- feature.backgroundImageUrl && /* @__PURE__ */ jsx23("img", { src: feature.backgroundImageUrl, alt: "", className: mobile ? "navbar__drawer-feature-img" : "navbar__dropdown-feature-img", "aria-hidden": "true" }),
2383
+ feature.backgroundImageUrl && /* @__PURE__ */ jsx23(
2384
+ "img",
2385
+ {
2386
+ src: feature.backgroundImageUrl,
2387
+ alt: "",
2388
+ className: mobile ? "navbar__drawer-feature-img" : "navbar__dropdown-feature-img",
2389
+ "aria-hidden": "true"
2390
+ }
2391
+ ),
2312
2392
  /* @__PURE__ */ jsx23("div", { className: mobile ? "navbar__drawer-feature-overlay" : "navbar__dropdown-feature-overlay", "aria-hidden": "true" }),
2313
2393
  /* @__PURE__ */ jsxs22("div", { className: mobile ? "navbar__drawer-feature-content" : "navbar__dropdown-feature-content", children: [
2314
2394
  /* @__PURE__ */ jsxs22("div", { children: [
2315
2395
  /* @__PURE__ */ jsx23("p", { className: mobile ? "navbar__drawer-feature-title" : "navbar__dropdown-feature-title", children: feature.title }),
2316
2396
  /* @__PURE__ */ jsx23("p", { className: mobile ? "navbar__drawer-feature-desc" : "navbar__dropdown-feature-desc", children: feature.description })
2317
2397
  ] }),
2318
- /* @__PURE__ */ jsxs22("a", { href: feature.ctaHref, className: mobile ? "navbar__drawer-feature-cta" : "navbar__dropdown-feature-cta", children: [
2319
- feature.ctaLabel,
2320
- /* @__PURE__ */ jsx23(ArrowRightIcon, {})
2321
- ] })
2398
+ /* @__PURE__ */ jsxs22(
2399
+ "a",
2400
+ {
2401
+ href: feature.ctaHref,
2402
+ className: mobile ? "navbar__drawer-feature-cta" : "navbar__dropdown-feature-cta",
2403
+ children: [
2404
+ feature.ctaLabel,
2405
+ /* @__PURE__ */ jsx23(ArrowRightIcon, {})
2406
+ ]
2407
+ }
2408
+ )
2322
2409
  ] })
2323
2410
  ]
2324
2411
  }
@@ -2329,7 +2416,7 @@ var DrawerAccordion = ({ item, isOpen, onToggle }) => {
2329
2416
  /* @__PURE__ */ jsxs22(
2330
2417
  "button",
2331
2418
  {
2332
- className: ["navbar__drawer-trigger", isOpen ? "navbar__drawer-trigger--open" : ""].filter(Boolean).join(" "),
2419
+ className: `navbar__drawer-trigger ${isOpen ? "navbar__drawer-trigger--open" : ""}`,
2333
2420
  onClick: onToggle,
2334
2421
  "aria-expanded": isOpen,
2335
2422
  children: [
@@ -2338,23 +2425,34 @@ var DrawerAccordion = ({ item, isOpen, onToggle }) => {
2338
2425
  ]
2339
2426
  }
2340
2427
  ),
2341
- /* @__PURE__ */ jsx23("div", { className: ["navbar__drawer-panel", isOpen ? "navbar__drawer-panel--open" : ""].filter(Boolean).join(" "), children: /* @__PURE__ */ jsxs22("div", { className: "navbar__drawer-panel-inner", children: [
2342
- /* @__PURE__ */ jsx23("div", { className: "navbar__drawer-panel-cols", children: dropdown?.columns.map((col, colIdx) => /* @__PURE__ */ jsx23("div", { className: "navbar__drawer-panel-col", children: col.sections.map((section) => /* @__PURE__ */ jsxs22("div", { className: "navbar__drawer-col-section", children: [
2343
- /* @__PURE__ */ jsx23("p", { className: "navbar__drawer-col-title", children: section.title }),
2344
- /* @__PURE__ */ jsx23("div", { className: "navbar__drawer-col-links", children: section.items.map((link) => /* @__PURE__ */ jsx23(
2345
- "a",
2346
- {
2347
- href: link.href,
2348
- className: "navbar__drawer-link",
2349
- target: link.external ? "_blank" : void 0,
2350
- rel: link.external ? "noopener noreferrer" : void 0,
2351
- children: link.label
2352
- },
2353
- link.href
2354
- )) })
2355
- ] }, section.title)) }, colIdx)) }),
2356
- dropdown?.feature && /* @__PURE__ */ jsx23(FeatureCard, { feature: dropdown.feature, mobile: true })
2357
- ] }) })
2428
+ /* @__PURE__ */ jsx23(AnimatePresence, { initial: false, children: isOpen && dropdown && /* @__PURE__ */ jsx23(
2429
+ motion2.div,
2430
+ {
2431
+ className: "navbar__drawer-panel",
2432
+ variants: accordionVariants,
2433
+ initial: "hidden",
2434
+ animate: "visible",
2435
+ exit: "hidden",
2436
+ transition: { duration: 0.22, ease: EASE_OUT_EXPO },
2437
+ children: /* @__PURE__ */ jsxs22("div", { className: "navbar__drawer-panel-inner", children: [
2438
+ /* @__PURE__ */ jsx23("div", { className: "navbar__drawer-panel-cols", children: dropdown.columns.map((col, colIdx) => /* @__PURE__ */ jsx23("div", { className: "navbar__drawer-panel-col", children: col.sections.map((section) => /* @__PURE__ */ jsxs22("div", { className: "navbar__drawer-col-section", children: [
2439
+ /* @__PURE__ */ jsx23("p", { className: "navbar__drawer-col-title", children: section.title }),
2440
+ /* @__PURE__ */ jsx23("div", { className: "navbar__drawer-col-links", children: section.items.map((link) => /* @__PURE__ */ jsx23(
2441
+ "a",
2442
+ {
2443
+ href: link.href,
2444
+ className: "navbar__drawer-link",
2445
+ target: link.external ? "_blank" : void 0,
2446
+ rel: link.external ? "noopener noreferrer" : void 0,
2447
+ children: link.label
2448
+ },
2449
+ link.href
2450
+ )) })
2451
+ ] }, section.title)) }, colIdx)) }),
2452
+ dropdown.feature && /* @__PURE__ */ jsx23(FeatureCard, { feature: dropdown.feature, mobile: true })
2453
+ ] })
2454
+ }
2455
+ ) })
2358
2456
  ] });
2359
2457
  };
2360
2458
  var Navbar = ({
@@ -2367,7 +2465,6 @@ var Navbar = ({
2367
2465
  loginHref,
2368
2466
  ctaLabel = "Open account",
2369
2467
  ctaHref,
2370
- languages,
2371
2468
  languageLabel,
2372
2469
  onLanguageClick,
2373
2470
  className,
@@ -2377,15 +2474,9 @@ var Navbar = ({
2377
2474
  const [mobileOpen, setMobileOpen] = useState8(false);
2378
2475
  const [mobileExpanded, setMobileExpanded] = useState8(null);
2379
2476
  const [scrolled, setScrolled] = useState8(false);
2380
- const [langOpen, setLangOpen] = useState8(false);
2381
- const [mobileLangOpen, setMobileLangOpen] = useState8(false);
2382
2477
  const hoverTimeoutRef = useRef7(null);
2383
- const langTimeoutRef = useRef7(null);
2384
2478
  const pillAreaRef = useRef7(null);
2385
- const langWrapperRef = useRef7(null);
2386
2479
  const resolvedLogo = theme === "light" ? logoSrcDark ?? logoSrc : logoSrc;
2387
- const activeLanguage = languages?.find((l) => l.active);
2388
- const displayLabel = activeLanguage?.code ?? languageLabel;
2389
2480
  useEffect6(() => {
2390
2481
  const onScroll = () => setScrolled(window.scrollY > 0);
2391
2482
  window.addEventListener("scroll", onScroll, { passive: true });
@@ -2396,7 +2487,6 @@ var Navbar = ({
2396
2487
  if (e.key === "Escape") {
2397
2488
  setOpenDropdown(null);
2398
2489
  setMobileOpen(false);
2399
- setLangOpen(false);
2400
2490
  }
2401
2491
  };
2402
2492
  document.addEventListener("keydown", onKey);
@@ -2418,16 +2508,6 @@ var Navbar = ({
2418
2508
  document.addEventListener("pointerdown", onPointerDown);
2419
2509
  return () => document.removeEventListener("pointerdown", onPointerDown);
2420
2510
  }, [openDropdown]);
2421
- useEffect6(() => {
2422
- if (!langOpen) return;
2423
- const onPointerDown = (e) => {
2424
- if (langWrapperRef.current && !langWrapperRef.current.contains(e.target)) {
2425
- setLangOpen(false);
2426
- }
2427
- };
2428
- document.addEventListener("pointerdown", onPointerDown);
2429
- return () => document.removeEventListener("pointerdown", onPointerDown);
2430
- }, [langOpen]);
2431
2511
  const clearHoverTimeout = useCallback2(() => {
2432
2512
  if (hoverTimeoutRef.current) {
2433
2513
  clearTimeout(hoverTimeoutRef.current);
@@ -2442,11 +2522,7 @@ var Navbar = ({
2442
2522
  clearHoverTimeout();
2443
2523
  hoverTimeoutRef.current = setTimeout(() => setOpenDropdown(null), 120);
2444
2524
  }, [clearHoverTimeout]);
2445
- const handleLangSelect = useCallback2((lang) => {
2446
- lang.onClick();
2447
- setLangOpen(false);
2448
- setMobileLangOpen(false);
2449
- }, []);
2525
+ const activeDropdownItem = navItems.find((item) => item.label === openDropdown);
2450
2526
  return /* @__PURE__ */ jsxs22(
2451
2527
  "nav",
2452
2528
  {
@@ -2460,16 +2536,29 @@ var Navbar = ({
2460
2536
  /* @__PURE__ */ jsxs22("div", { className: "navbar__nav-group", children: [
2461
2537
  navItems.map((item) => {
2462
2538
  if (item.external) {
2463
- return /* @__PURE__ */ jsxs22("a", { href: item.href, className: "navbar__nav-item", target: "_blank", rel: "noopener noreferrer", children: [
2464
- item.label,
2465
- /* @__PURE__ */ jsx23(ArrowUpRightIcon, {})
2466
- ] }, item.label);
2539
+ return /* @__PURE__ */ jsxs22(
2540
+ "a",
2541
+ {
2542
+ href: item.href,
2543
+ className: "navbar__nav-item",
2544
+ target: "_blank",
2545
+ rel: "noopener noreferrer",
2546
+ children: [
2547
+ item.label,
2548
+ /* @__PURE__ */ jsx23(ArrowUpRightIcon, {})
2549
+ ]
2550
+ },
2551
+ item.label
2552
+ );
2467
2553
  }
2468
2554
  if (item.dropdown) {
2469
2555
  return /* @__PURE__ */ jsxs22(
2470
2556
  "button",
2471
2557
  {
2472
- className: ["navbar__nav-item", openDropdown === item.label ? "navbar__nav-item--open" : ""].filter(Boolean).join(" "),
2558
+ className: [
2559
+ "navbar__nav-item",
2560
+ openDropdown === item.label ? "navbar__nav-item--open" : ""
2561
+ ].filter(Boolean).join(" "),
2473
2562
  onMouseEnter: () => handleNavEnter(item.label),
2474
2563
  onMouseLeave: handleNavLeave,
2475
2564
  "aria-expanded": openDropdown === item.label,
@@ -2484,74 +2573,45 @@ var Navbar = ({
2484
2573
  }
2485
2574
  return /* @__PURE__ */ jsx23("a", { href: item.href, className: "navbar__nav-item", children: item.label }, item.label);
2486
2575
  }),
2487
- displayLabel && /* @__PURE__ */ jsxs22(
2488
- "div",
2489
- {
2490
- className: "navbar__lang-wrapper",
2491
- ref: langWrapperRef,
2492
- onMouseEnter: () => {
2493
- if (langTimeoutRef.current) clearTimeout(langTimeoutRef.current);
2494
- if (languages && languages.length > 0) setLangOpen(true);
2495
- },
2496
- onMouseLeave: () => {
2497
- langTimeoutRef.current = setTimeout(() => setLangOpen(false), 150);
2498
- },
2499
- children: [
2500
- /* @__PURE__ */ jsxs22(
2501
- "button",
2502
- {
2503
- className: ["navbar__nav-item", "navbar__lang-btn", langOpen ? "navbar__nav-item--open" : ""].filter(Boolean).join(" "),
2504
- onClick: () => {
2505
- if (!languages || languages.length === 0) onLanguageClick?.();
2506
- },
2507
- "aria-expanded": languages ? langOpen : void 0,
2508
- "aria-haspopup": languages ? "listbox" : void 0,
2509
- children: [
2510
- /* @__PURE__ */ jsx23(GlobeIcon, { className: "navbar__lang-globe" }),
2511
- displayLabel,
2512
- languages && languages.length > 0 && /* @__PURE__ */ jsx23(ChevronDownIcon3, { className: "navbar__nav-item__chevron" })
2513
- ]
2514
- }
2515
- ),
2516
- languages && languages.length > 0 && /* @__PURE__ */ jsx23("div", { className: ["navbar__lang-dropdown", langOpen ? "navbar__lang-dropdown--open" : ""].filter(Boolean).join(" "), role: "listbox", children: languages.map((lang) => /* @__PURE__ */ jsxs22(
2517
- "button",
2518
- {
2519
- className: ["navbar__lang-option", lang.active ? "navbar__lang-option--active" : ""].filter(Boolean).join(" "),
2520
- onClick: () => handleLangSelect(lang),
2521
- role: "option",
2522
- "aria-selected": lang.active,
2523
- children: [
2524
- lang.label,
2525
- /* @__PURE__ */ jsx23(ArrowRightSmIcon, {})
2526
- ]
2527
- },
2528
- lang.code
2529
- )) })
2530
- ]
2531
- }
2532
- )
2576
+ languageLabel && /* @__PURE__ */ jsxs22("button", { className: "navbar__nav-item navbar__lang-btn", onClick: onLanguageClick, children: [
2577
+ /* @__PURE__ */ jsx23(GlobeIcon, { className: "navbar__lang-globe" }),
2578
+ languageLabel
2579
+ ] })
2533
2580
  ] }),
2534
2581
  /* @__PURE__ */ jsxs22("div", { className: "navbar__pill-actions", children: [
2535
2582
  loginHref && /* @__PURE__ */ jsx23("a", { href: loginHref, children: /* @__PURE__ */ jsx23(Button, { colorScheme: "black", variant: "secondary", label: loginLabel }) }),
2536
2583
  ctaHref && /* @__PURE__ */ jsx23("a", { href: ctaHref, children: /* @__PURE__ */ jsx23(Button, { colorScheme: "coral", variant: "primary", label: ctaLabel }) })
2537
2584
  ] })
2538
2585
  ] }) }),
2539
- navItems.map((item) => item.dropdown ? /* @__PURE__ */ jsx23(
2586
+ /* @__PURE__ */ jsx23(AnimatePresence, { children: openDropdown && activeDropdownItem?.dropdown && /* @__PURE__ */ jsx23(
2540
2587
  DropdownPanel,
2541
2588
  {
2542
- item,
2543
- isOpen: openDropdown === item.label,
2589
+ item: activeDropdownItem,
2544
2590
  onMouseEnter: clearHoverTimeout,
2545
2591
  onMouseLeave: handleNavLeave
2546
2592
  },
2547
- item.label
2548
- ) : null),
2593
+ "dropdown"
2594
+ ) }),
2549
2595
  /* @__PURE__ */ jsxs22("div", { className: "navbar__actions", children: [
2550
- loginHref && /* @__PURE__ */ jsx23("a", { href: loginHref, className: "navbar__actions-login", children: /* @__PURE__ */ jsx23(Button, { colorScheme: theme === "dark" ? "white" : "black", variant: "secondary", label: loginLabel }) }),
2596
+ loginHref && /* @__PURE__ */ jsx23("a", { href: loginHref, className: "navbar__actions-login", children: /* @__PURE__ */ jsx23(
2597
+ Button,
2598
+ {
2599
+ colorScheme: theme === "dark" ? "white" : "black",
2600
+ variant: "secondary",
2601
+ label: loginLabel
2602
+ }
2603
+ ) }),
2551
2604
  ctaHref && /* @__PURE__ */ jsx23("a", { href: ctaHref, children: /* @__PURE__ */ jsx23(Button, { colorScheme: "coral", variant: "primary", label: ctaLabel }) })
2552
2605
  ] }),
2553
2606
  /* @__PURE__ */ jsxs22("div", { className: "navbar__mobile-actions", children: [
2554
- loginHref && /* @__PURE__ */ jsx23("a", { href: loginHref, children: /* @__PURE__ */ jsx23(Button, { colorScheme: scrolled || theme === "light" ? "black" : "white", variant: "secondary", label: loginLabel }) }),
2607
+ loginHref && /* @__PURE__ */ jsx23("a", { href: loginHref, children: /* @__PURE__ */ jsx23(
2608
+ Button,
2609
+ {
2610
+ colorScheme: scrolled || theme === "light" ? "black" : "white",
2611
+ variant: "secondary",
2612
+ label: loginLabel
2613
+ }
2614
+ ) }),
2555
2615
  /* @__PURE__ */ jsx23(
2556
2616
  "button",
2557
2617
  {
@@ -2563,66 +2623,77 @@ var Navbar = ({
2563
2623
  )
2564
2624
  ] })
2565
2625
  ] }),
2566
- /* @__PURE__ */ jsx23("div", { className: "navbar__drawer-clip", children: /* @__PURE__ */ jsxs22("div", { className: ["navbar__drawer", mobileOpen ? "navbar__drawer--open" : ""].filter(Boolean).join(" "), "aria-modal": "true", role: "dialog", "aria-label": "Navigation menu", children: [
2567
- /* @__PURE__ */ jsxs22("nav", { className: "navbar__drawer-nav", children: [
2568
- navItems.map((item) => {
2569
- if (item.dropdown) {
2570
- return /* @__PURE__ */ jsx23(
2571
- DrawerAccordion,
2626
+ /* @__PURE__ */ jsx23("div", { className: "navbar__drawer-clip", children: /* @__PURE__ */ jsx23(AnimatePresence, { children: mobileOpen && /* @__PURE__ */ jsxs22(
2627
+ motion2.div,
2628
+ {
2629
+ className: "navbar__drawer",
2630
+ variants: drawerVariants,
2631
+ initial: "hidden",
2632
+ animate: "visible",
2633
+ exit: "hidden",
2634
+ transition: { duration: 0.3, ease: EASE_OUT_EXPO },
2635
+ "aria-modal": "true",
2636
+ role: "dialog",
2637
+ "aria-label": "Navigation menu",
2638
+ children: [
2639
+ /* @__PURE__ */ jsxs22("nav", { className: "navbar__drawer-nav", children: [
2640
+ navItems.map((item) => {
2641
+ if (item.dropdown) {
2642
+ return /* @__PURE__ */ jsx23(
2643
+ DrawerAccordion,
2644
+ {
2645
+ item,
2646
+ isOpen: mobileExpanded === item.label,
2647
+ onToggle: () => setMobileExpanded(
2648
+ (prev) => prev === item.label ? null : item.label
2649
+ )
2650
+ },
2651
+ item.label
2652
+ );
2653
+ }
2654
+ return /* @__PURE__ */ jsxs22(
2655
+ "a",
2656
+ {
2657
+ href: item.href,
2658
+ className: "navbar__drawer-single",
2659
+ target: item.external ? "_blank" : void 0,
2660
+ rel: item.external ? "noopener noreferrer" : void 0,
2661
+ children: [
2662
+ item.label,
2663
+ item.external && /* @__PURE__ */ jsx23(ArrowUpRightIcon, {})
2664
+ ]
2665
+ },
2666
+ item.label
2667
+ );
2668
+ }),
2669
+ languageLabel && /* @__PURE__ */ jsxs22("button", { className: "navbar__drawer-lang", onClick: onLanguageClick, children: [
2670
+ /* @__PURE__ */ jsx23(GlobeIcon, { className: "navbar__lang-globe" }),
2671
+ languageLabel
2672
+ ] })
2673
+ ] }),
2674
+ /* @__PURE__ */ jsxs22("div", { className: "navbar__drawer-footer", children: [
2675
+ loginHref && /* @__PURE__ */ jsx23("a", { href: loginHref, style: { display: "block" }, children: /* @__PURE__ */ jsx23(
2676
+ Button,
2572
2677
  {
2573
- item,
2574
- isOpen: mobileExpanded === item.label,
2575
- onToggle: () => setMobileExpanded((prev) => prev === item.label ? null : item.label)
2576
- },
2577
- item.label
2578
- );
2579
- }
2580
- return /* @__PURE__ */ jsxs22("a", { href: item.href, className: "navbar__drawer-single", target: item.external ? "_blank" : void 0, rel: item.external ? "noopener noreferrer" : void 0, children: [
2581
- item.label,
2582
- item.external && /* @__PURE__ */ jsx23(ArrowUpRightIcon, {})
2583
- ] }, item.label);
2584
- }),
2585
- displayLabel && /* @__PURE__ */ jsxs22("div", { className: "navbar__drawer-item", children: [
2586
- /* @__PURE__ */ jsxs22(
2587
- "button",
2588
- {
2589
- className: ["navbar__drawer-trigger", mobileLangOpen ? "navbar__drawer-trigger--open" : ""].filter(Boolean).join(" "),
2590
- onClick: () => {
2591
- if (languages && languages.length > 0) {
2592
- setMobileLangOpen((o) => !o);
2593
- } else {
2594
- onLanguageClick?.();
2595
- }
2596
- },
2597
- "aria-expanded": languages ? mobileLangOpen : void 0,
2598
- children: [
2599
- /* @__PURE__ */ jsxs22("span", { className: "navbar__drawer-lang-label", children: [
2600
- /* @__PURE__ */ jsx23(GlobeIcon, { className: "navbar__lang-globe navbar__lang-globe--dark" }),
2601
- displayLabel
2602
- ] }),
2603
- languages && languages.length > 0 && /* @__PURE__ */ jsx23(ChevronDownIcon3, { className: "navbar__drawer-trigger__chevron" })
2604
- ]
2605
- }
2606
- ),
2607
- languages && languages.length > 0 && /* @__PURE__ */ jsx23("div", { className: ["navbar__drawer-lang-grid", mobileLangOpen ? "navbar__drawer-lang-grid--open" : ""].filter(Boolean).join(" "), children: /* @__PURE__ */ jsx23("div", { className: "navbar__drawer-lang-grid-inner", children: languages.map((lang) => /* @__PURE__ */ jsxs22(
2608
- "button",
2609
- {
2610
- className: ["navbar__drawer-lang-option", lang.active ? "navbar__drawer-lang-option--active" : ""].filter(Boolean).join(" "),
2611
- onClick: () => handleLangSelect(lang),
2612
- children: [
2613
- lang.label,
2614
- /* @__PURE__ */ jsx23(ArrowRightSmIcon, {})
2615
- ]
2616
- },
2617
- lang.code
2618
- )) }) })
2619
- ] })
2620
- ] }),
2621
- /* @__PURE__ */ jsxs22("div", { className: "navbar__drawer-footer", children: [
2622
- loginHref && /* @__PURE__ */ jsx23("a", { href: loginHref, style: { display: "block" }, children: /* @__PURE__ */ jsx23(Button, { colorScheme: "black", variant: "secondary", label: loginLabel, fullWidth: true }) }),
2623
- ctaHref && /* @__PURE__ */ jsx23("a", { href: ctaHref, style: { display: "block" }, children: /* @__PURE__ */ jsx23(Button, { colorScheme: "coral", variant: "primary", label: ctaLabel, fullWidth: true }) })
2624
- ] })
2625
- ] }) })
2678
+ colorScheme: "black",
2679
+ variant: "secondary",
2680
+ label: loginLabel,
2681
+ fullWidth: true
2682
+ }
2683
+ ) }),
2684
+ ctaHref && /* @__PURE__ */ jsx23("a", { href: ctaHref, style: { display: "block" }, children: /* @__PURE__ */ jsx23(
2685
+ Button,
2686
+ {
2687
+ colorScheme: "coral",
2688
+ variant: "primary",
2689
+ label: ctaLabel,
2690
+ fullWidth: true
2691
+ }
2692
+ ) })
2693
+ ] })
2694
+ ]
2695
+ }
2696
+ ) }) })
2626
2697
  ]
2627
2698
  }
2628
2699
  );
@@ -2631,7 +2702,7 @@ var Navbar = ({
2631
2702
  // templates/DayNightTransition/DayNightTransition.tsx
2632
2703
  import { useRef as useRef8 } from "react";
2633
2704
  import {
2634
- motion as motion2,
2705
+ motion as motion3,
2635
2706
  useScroll as useScroll2,
2636
2707
  useSpring as useSpring2,
2637
2708
  useTransform as useTransform2,
@@ -2687,7 +2758,7 @@ var DayNightTransition = ({
2687
2758
  }
2688
2759
  ),
2689
2760
  /* @__PURE__ */ jsx24(
2690
- motion2.img,
2761
+ motion3.img,
2691
2762
  {
2692
2763
  className: "dnt__bg dnt__bg--night",
2693
2764
  src: nightImageUrl,
@@ -2698,14 +2769,14 @@ var DayNightTransition = ({
2698
2769
  }
2699
2770
  ),
2700
2771
  /* @__PURE__ */ jsx24("div", { className: "dnt__content", children: /* @__PURE__ */ jsxs23(
2701
- motion2.div,
2772
+ motion3.div,
2702
2773
  {
2703
2774
  className: "dnt__text-wrap",
2704
2775
  style: { color: textColor },
2705
2776
  children: [
2706
2777
  /* @__PURE__ */ jsxs23("div", { className: "dnt__crossfade-wrap", children: [
2707
2778
  /* @__PURE__ */ jsx24(
2708
- motion2.h2,
2779
+ motion3.h2,
2709
2780
  {
2710
2781
  className: "dnt__headline",
2711
2782
  style: { opacity: dayOpacity },
@@ -2713,7 +2784,7 @@ var DayNightTransition = ({
2713
2784
  }
2714
2785
  ),
2715
2786
  /* @__PURE__ */ jsx24(
2716
- motion2.h2,
2787
+ motion3.h2,
2717
2788
  {
2718
2789
  className: "dnt__headline",
2719
2790
  "aria-hidden": "true",
@@ -2724,7 +2795,7 @@ var DayNightTransition = ({
2724
2795
  ] }),
2725
2796
  hasDescription && /* @__PURE__ */ jsxs23("div", { className: "dnt__crossfade-wrap", children: [
2726
2797
  /* @__PURE__ */ jsx24(
2727
- motion2.p,
2798
+ motion3.p,
2728
2799
  {
2729
2800
  className: "dnt__description",
2730
2801
  style: { opacity: dayOpacity },
@@ -2732,7 +2803,7 @@ var DayNightTransition = ({
2732
2803
  }
2733
2804
  ),
2734
2805
  /* @__PURE__ */ jsx24(
2735
- motion2.p,
2806
+ motion3.p,
2736
2807
  {
2737
2808
  className: "dnt__description",
2738
2809
  "aria-hidden": "true",
@@ -2753,7 +2824,7 @@ var DayNightTransition = ({
2753
2824
  // templates/PaymentMethods/PaymentMethods.tsx
2754
2825
  import { useRef as useRef9 } from "react";
2755
2826
  import {
2756
- motion as motion3,
2827
+ motion as motion4,
2757
2828
  useScroll as useScroll3,
2758
2829
  useVelocity,
2759
2830
  useAnimationFrame,
@@ -2839,7 +2910,7 @@ var PaymentMethods = ({
2839
2910
  /* @__PURE__ */ jsx25("div", { className: "pm__media", children: /* @__PURE__ */ jsxs24("div", { className: "pm__carousel", children: [
2840
2911
  /* @__PURE__ */ jsx25("div", { className: "pm__fade pm__fade--top", "aria-hidden": "true" }),
2841
2912
  /* @__PURE__ */ jsx25(
2842
- motion3.div,
2913
+ motion4.div,
2843
2914
  {
2844
2915
  ref: col1Ref,
2845
2916
  className: "pm__col",
@@ -2856,7 +2927,7 @@ var PaymentMethods = ({
2856
2927
  }
2857
2928
  ),
2858
2929
  /* @__PURE__ */ jsx25(
2859
- motion3.div,
2930
+ motion4.div,
2860
2931
  {
2861
2932
  ref: col2Ref,
2862
2933
  className: "pm__col",