@anywayseo/tools 1.1.0 → 1.5.1

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 (56) hide show
  1. package/dist/components/base/center/index.d.ts +6 -0
  2. package/dist/components/base/grid/index.d.ts +19 -0
  3. package/dist/components/base/grid/types.d.ts +3 -0
  4. package/dist/components/base/grid/utils.d.ts +2 -0
  5. package/dist/components/base/index.d.ts +3 -0
  6. package/dist/components/base/link-button/index.d.ts +7 -0
  7. package/dist/components/bonus-card/content/index.d.ts +7 -0
  8. package/dist/components/bonus-card/index.d.ts +7 -0
  9. package/dist/components/bonus-card/title/index.d.ts +7 -0
  10. package/dist/components/game-card/index.d.ts +7 -0
  11. package/dist/components/index.cjs +9 -1
  12. package/dist/components/index.d.ts +6 -0
  13. package/dist/components/index.mjs +12 -4
  14. package/dist/components/layout/container/index.d.ts +3 -0
  15. package/dist/components/layout/hero/index.d.ts +2 -0
  16. package/dist/components/list/index.d.ts +13 -0
  17. package/dist/components/table/index.d.ts +12 -0
  18. package/dist/components/tabs/index.d.ts +8 -0
  19. package/dist/i18n/index.cjs +1 -1
  20. package/dist/i18n/index.mjs +1 -1
  21. package/dist/i18n/resources/de/index.d.ts +108 -0
  22. package/dist/i18n/resources/en/index.d.ts +9 -0
  23. package/dist/i18n/resources/it/index.d.ts +9 -0
  24. package/dist/index-B-5oUop6.js +47 -0
  25. package/dist/index-BUx1Bxrs.mjs +48 -0
  26. package/dist/{index-jhNgIknB.mjs → index-CJvs4SfG.mjs} +1 -1
  27. package/dist/{index-DB1dS9cp.js → index-DCIXk-YH.js} +140 -4
  28. package/dist/{index-Bv4g3xBH.mjs → index-DD5l7Azu.mjs} +191 -20
  29. package/dist/{index-C1AoeBP2.js → index-DLPk8AIs.js} +179 -8
  30. package/dist/{index-Bh5idiRE.mjs → index-DxLcykuT.mjs} +140 -4
  31. package/dist/{index-C68DPwvx.js → index-jvxaXXE3.js} +1 -1
  32. package/dist/index.cjs +14 -3
  33. package/dist/index.mjs +20 -9
  34. package/dist/types/components/bonus-card/index.d.ts +9 -0
  35. package/dist/types/components/common/index.d.ts +3 -0
  36. package/dist/types/components/game-card/index.d.ts +6 -0
  37. package/dist/types/components/index.d.ts +8 -0
  38. package/dist/types/components/tabs/index.d.ts +8 -0
  39. package/dist/types/i18n/index.d.ts +1 -1
  40. package/dist/types/index.d.ts +4 -7
  41. package/dist/types/models/bonus/index.d.ts +4 -0
  42. package/dist/types/models/game/index.d.ts +3 -0
  43. package/dist/types/models/index.d.ts +5 -0
  44. package/dist/types/models/link/index.d.ts +4 -0
  45. package/dist/types/theme/index.d.ts +27 -0
  46. package/dist/utils/index.cjs +4 -1
  47. package/dist/utils/index.d.ts +1 -0
  48. package/dist/utils/index.mjs +4 -1
  49. package/dist/utils/theme/index.d.ts +3 -0
  50. package/package.json +2 -1
  51. /package/dist/types/{faq → components/faq}/index.d.ts +0 -0
  52. /package/dist/types/{game-info → components/game-info}/index.d.ts +0 -0
  53. /package/dist/types/{how-to → components/how-to}/index.d.ts +0 -0
  54. /package/dist/types/{pros-cons → components/pros-cons}/index.d.ts +0 -0
  55. /package/dist/types/{author → models/author}/index.d.ts +0 -0
  56. /package/dist/types/{feature → models/feature}/index.d.ts +0 -0
@@ -1,17 +1,18 @@
1
1
  import { jsxs, jsx, Fragment } from "react/jsx-runtime";
2
- import { Box, Collapse, Text, Button, Flex, Stack, Card, CardHeader, Heading, CardBody, useToast, useColorModeValue, VStack, FormControl, FormLabel, InputGroup, InputLeftElement, Input, Textarea, CardFooter, Accordion, AccordionItem, AccordionButton, AccordionIcon, AccordionPanel, SimpleGrid, IconButton, AbsoluteCenter, Spinner, useDisclosure, Divider, Circle, Container, Popover, PopoverTrigger, PopoverContent, Icon, useBreakpointValue, List, ListItem, ListIcon } from "@chakra-ui/react";
2
+ import { Box, Collapse, Text, Button, Flex, Stack, Card, CardHeader, Heading, CardBody, Center as Center$1, SimpleGrid, Link, Popover, PopoverTrigger, PopoverContent, PopoverBody, CardFooter, useToast, useColorModeValue, VStack, FormControl, FormLabel, InputGroup, InputLeftElement, Input, Textarea, Accordion, AccordionItem, AccordionButton, AccordionIcon, AccordionPanel, LinkBox, Image, LinkOverlay, IconButton, AbsoluteCenter, Spinner, useDisclosure, Divider, Circle, Container as Container$1, Icon, useBreakpointValue, List as List$1, ListItem, ListIcon, TableContainer, Table as Table$1, Thead, Tr, Th, Tbody, Td, TableCaption, Tabs as Tabs$1, TabList, Tab, TabPanels, TabPanel } from "@chakra-ui/react";
3
3
  import { useTranslation } from "react-i18next";
4
4
  import { EmailIcon, StarIcon, CloseIcon, ExternalLinkIcon, ChevronRightIcon, ChevronDownIcon, HamburgerIcon, ChevronUpIcon, WarningIcon, CheckCircleIcon } from "@chakra-ui/icons";
5
5
  import { getImage, GatsbyImage } from "gatsby-plugin-image";
6
6
  import "@mdx-js/react";
7
7
  import { u as useSiteMetadataContext } from "./index-Bs4zA1wD.mjs";
8
- import { useRef, useState, useLayoutEffect, Fragment as Fragment$1, useEffect } from "react";
8
+ import { useRef, useState, useLayoutEffect, Fragment as Fragment$1, useEffect, useMemo } from "react";
9
9
  import { u as usePrimaryColors } from "./index-xuSxvz5z.mjs";
10
10
  import { keyframes } from "@emotion/react";
11
- import { a as GameCharacteristic } from "./index-Bh5idiRE.mjs";
11
+ import { a as GameCharacteristic } from "./index-DxLcykuT.mjs";
12
12
  import { t } from "i18next";
13
- import { b as formatNumber, c as getCurrencySymbol, f as formatDate, d as getDomain, g as getCurrentYear, a as getCurrentMonth } from "./index-jhNgIknB.mjs";
14
- import { Link } from "gatsby";
13
+ import { b as formatNumber, c as getCurrencySymbol, f as formatDate, d as getDomain, g as getCurrentYear, a as getCurrentMonth } from "./index-CJvs4SfG.mjs";
14
+ import "@ctrl/tinycolor";
15
+ import { Link as Link$1 } from "gatsby";
15
16
  const ONE_LINE_HEIGHT = 24;
16
17
  const Bio = ({ content, maxLines = 1 }) => {
17
18
  const ref = useRef(null);
@@ -77,6 +78,85 @@ const Author = ({ author, ...cardProps }) => {
77
78
  )
78
79
  ] });
79
80
  };
81
+ const Center = ({ children, className }) => {
82
+ return /* @__PURE__ */ jsx(Center$1, { className, children });
83
+ };
84
+ const defaultColumns = { base: 1, sm: 2, md: 3, lg: 4, xl: 5 };
85
+ const Grid = ({ items, columns = defaultColumns, gap, render, getKey, className }) => {
86
+ return /* @__PURE__ */ jsx(SimpleGrid, { as: "ul", columns, spacing: gap, p: 0, m: 0, listStyleType: "none", className, children: items.map((item, index) => /* @__PURE__ */ jsx(Box, { as: "li", children: render(item) }, getKey ? getKey(item) : index)) });
87
+ };
88
+ const LinkButton = ({ label, url, width = "auto" }) => {
89
+ return /* @__PURE__ */ jsx(
90
+ Button,
91
+ {
92
+ as: Link,
93
+ href: url,
94
+ w: width,
95
+ bg: "brand.600",
96
+ textTransform: "uppercase",
97
+ _hover: { textDecoration: "none", bg: "brand.300" },
98
+ _active: { transform: "scale(0.95)" },
99
+ children: label
100
+ }
101
+ );
102
+ };
103
+ const BonusCardContent = ({ content }) => {
104
+ const { t: t2 } = useTranslation("author");
105
+ return /* @__PURE__ */ jsx(Popover, { flip: false, matchWidth: false, placement: "bottom", children: ({ isOpen }) => /* @__PURE__ */ jsxs(Fragment, { children: [
106
+ /* @__PURE__ */ jsx(PopoverTrigger, { children: /* @__PURE__ */ jsx(Button, { size: "sm", variant: "link", color: "white", children: isOpen ? t2("action.collapse") : t2("action.expand") }) }),
107
+ /* @__PURE__ */ jsx(PopoverContent, { w: 60, children: /* @__PURE__ */ jsx(PopoverBody, { children: Array.isArray(content) ? /* @__PURE__ */ jsx(Stack, { children: content.map((paragraph, index) => /* @__PURE__ */ jsx(Text, { as: "span", children: paragraph }, index)) }) : /* @__PURE__ */ jsx(Text, { children: content }) }) })
108
+ ] }) });
109
+ };
110
+ const BonusCardTitle = ({ content }) => {
111
+ return /* @__PURE__ */ jsx(
112
+ Text,
113
+ {
114
+ as: "h3",
115
+ display: "inline-block",
116
+ py: 1,
117
+ px: 2,
118
+ borderRadius: "md",
119
+ bg: "yellow",
120
+ color: "black",
121
+ fontWeight: "bold",
122
+ fontSize: "lg",
123
+ children: content
124
+ }
125
+ );
126
+ };
127
+ const BonusCard = ({ title, subtitle, content, link, image, className }) => {
128
+ return /* @__PURE__ */ jsxs(
129
+ Card,
130
+ {
131
+ as: "article",
132
+ h: "full",
133
+ bg: "linear-gradient(90deg, #3b1f47, #731d58)",
134
+ overflow: "hidden",
135
+ _before: image ? {
136
+ content: '""',
137
+ position: "absolute",
138
+ top: 0,
139
+ left: 0,
140
+ w: "100%",
141
+ h: "100%",
142
+ bgImage: `url(${image})`,
143
+ bgSize: "cover",
144
+ bgPosition: "center",
145
+ filter: "blur(0.05em) opacity(50%)",
146
+ zIndex: 0
147
+ } : void 0,
148
+ className,
149
+ children: [
150
+ /* @__PURE__ */ jsxs(CardBody, { as: "section", pb: 0, flex: 1, children: [
151
+ /* @__PURE__ */ jsx(BonusCardTitle, { content: title }),
152
+ /* @__PURE__ */ jsx(Text, { fontSize: "2xl", fontWeight: "bold", my: 2, children: subtitle }),
153
+ /* @__PURE__ */ jsx(BonusCardContent, { content })
154
+ ] }),
155
+ /* @__PURE__ */ jsx(CardFooter, { as: "footer", p: 4, children: /* @__PURE__ */ jsx(LinkButton, { ...link, width: "full" }) })
156
+ ]
157
+ }
158
+ );
159
+ };
80
160
  const ContactForm = () => {
81
161
  const toast = useToast();
82
162
  const { t: t2 } = useTranslation("contactForm");
@@ -193,6 +273,26 @@ const Features = ({ features, ...boxProps }) => {
193
273
  /* @__PURE__ */ jsx(CardBody, { as: "section", pt: 0, children: /* @__PURE__ */ jsx(Text, { color: "gray.600", children: description }) })
194
274
  ] }) }, title)) });
195
275
  };
276
+ const GameCard = ({ name, image, link, className }) => {
277
+ return /* @__PURE__ */ jsxs(
278
+ LinkBox,
279
+ {
280
+ as: "article",
281
+ rounded: "md",
282
+ borderWidth: 1,
283
+ transition: "transform 0.2s ease",
284
+ cursor: link ? "pointer" : "default",
285
+ overflow: "hidden",
286
+ bg: "blackAlpha.400",
287
+ _hover: { transform: "scale(1.1)" },
288
+ className,
289
+ children: [
290
+ typeof image === "string" ? /* @__PURE__ */ jsx(Image, { src: image, alt: name, w: "100%", aspectRatio: "16/9", objectFit: "cover", objectPosition: "center" }) : !!image && /* @__PURE__ */ jsx(Box, { w: "100%", aspectRatio: "16/9", children: image }),
291
+ /* @__PURE__ */ jsx(Box, { as: "section", rounded: "md", p: 4, children: /* @__PURE__ */ jsx(Text, { as: "span", children: link ? /* @__PURE__ */ jsx(LinkOverlay, { href: link, children: name }) : name }) })
292
+ ]
293
+ }
294
+ );
295
+ };
196
296
  const GameDemoContent = ({ src, isFullscreen, isLoaded, onLoad, onToggleFullscreen }) => {
197
297
  const { t: t2 } = useTranslation("gameDemo");
198
298
  return /* @__PURE__ */ jsxs(Fragment, { children: [
@@ -394,8 +494,11 @@ const HowTo = ({ steps, ...boxProps }) => {
394
494
  ] })
395
495
  ] }, index)) });
396
496
  };
497
+ const Container = ({ children }) => {
498
+ return /* @__PURE__ */ jsx(Container$1, { maxW: "container.xl", children });
499
+ };
397
500
  const Content = ({ children }) => {
398
- return /* @__PURE__ */ jsx(Container, { as: "section", maxW: "container.xl", children });
501
+ return /* @__PURE__ */ jsx(Box, { as: "section", py: 4, children: /* @__PURE__ */ jsx(Container, { children }) });
399
502
  };
400
503
  const Logo = () => {
401
504
  const { logoImageData } = useSiteMetadataContext();
@@ -408,7 +511,7 @@ const Logo = () => {
408
511
  const Brand$1 = ({ brand }) => {
409
512
  return /* @__PURE__ */ jsxs(Box, { position: "relative", my: 2, py: 8, children: [
410
513
  /* @__PURE__ */ jsx(Divider, {}),
411
- /* @__PURE__ */ jsx(AbsoluteCenter, { display: "flex", bgColor: useColorModeValue("gray.50", "gray.900"), children: /* @__PURE__ */ jsx(Box, { as: Link, to: "/", children: brand }) })
514
+ /* @__PURE__ */ jsx(AbsoluteCenter, { display: "flex", bgColor: useColorModeValue("gray.50", "gray.900"), children: /* @__PURE__ */ jsx(Box, { as: Link$1, to: "/", children: brand }) })
412
515
  ] });
413
516
  };
414
517
  const Copyright = () => {
@@ -441,7 +544,7 @@ const Navigation$1 = () => {
441
544
  children: footerMenuLinks.map(({ url, title }) => /* @__PURE__ */ jsx(
442
545
  Text,
443
546
  {
444
- as: Link,
547
+ as: Link$1,
445
548
  to: url,
446
549
  fontSize: "md",
447
550
  fontWeight: "semibold",
@@ -462,7 +565,7 @@ const Footer = () => {
462
565
  bg: useColorModeValue("gray.50", "gray.900"),
463
566
  color: useColorModeValue("gray.700", "gray.200"),
464
567
  py: 4,
465
- children: /* @__PURE__ */ jsxs(Content, { children: [
568
+ children: /* @__PURE__ */ jsxs(Container, { children: [
466
569
  /* @__PURE__ */ jsx(Navigation$1, {}),
467
570
  /* @__PURE__ */ jsx(Disclaimer, {}),
468
571
  /* @__PURE__ */ jsx(Brand$1, { brand: /* @__PURE__ */ jsx(Logo, {}) }),
@@ -475,7 +578,7 @@ const Brand = ({ brand }) => {
475
578
  return /* @__PURE__ */ jsx(
476
579
  Box,
477
580
  {
478
- as: Link,
581
+ as: Link$1,
479
582
  to: "/",
480
583
  display: "flex",
481
584
  h: { base: "40px", md: "60px" },
@@ -492,7 +595,7 @@ const DesktopNavItem = ({ title, url, children }) => {
492
595
  /* @__PURE__ */ jsx(PopoverTrigger, { children: /* @__PURE__ */ jsx(
493
596
  Text,
494
597
  {
495
- as: Link,
598
+ as: Link$1,
496
599
  to: url,
497
600
  p: 2,
498
601
  fontSize: "sm",
@@ -542,7 +645,7 @@ const MobileNavItem = ({ title, children, url }) => {
542
645
  const { isOpen, onToggle } = useDisclosure();
543
646
  return /* @__PURE__ */ jsxs(Stack, { w: "100%", p: 2, children: [
544
647
  /* @__PURE__ */ jsxs(Flex, { align: "center", gap: 2, justify: "space-between", children: [
545
- /* @__PURE__ */ jsx(Text, { as: Link, to: url, isTruncated: true, fontWeight: 600, children: title }),
648
+ /* @__PURE__ */ jsx(Text, { as: Link$1, to: url, isTruncated: true, fontWeight: 600, children: title }),
546
649
  !!children && /* @__PURE__ */ jsx(Flex, { as: "button", onClick: onToggle, children: /* @__PURE__ */ jsx(
547
650
  Icon,
548
651
  {
@@ -562,7 +665,7 @@ const MobileNavItem = ({ title, children, url }) => {
562
665
  borderLeft: 1,
563
666
  borderStyle: "solid",
564
667
  borderColor: useColorModeValue("gray.200", "gray.700"),
565
- children: !!children && children.map((child) => /* @__PURE__ */ jsx(Flex, { as: "li", children: /* @__PURE__ */ jsx(Text, { as: Link, to: `${url}${child.url}`, py: 2, children: child.title }) }, child.url))
668
+ children: !!children && children.map((child) => /* @__PURE__ */ jsx(Flex, { as: "li", children: /* @__PURE__ */ jsx(Text, { as: Link$1, to: `${url}${child.url}`, py: 2, children: child.title }) }, child.url))
566
669
  }
567
670
  ) })
568
671
  ] });
@@ -606,12 +709,25 @@ const Header = () => {
606
709
  color: useColorModeValue("gray.700", "gray.200"),
607
710
  boxShadow: "sm",
608
711
  zIndex: 100,
609
- children: /* @__PURE__ */ jsx(Content, { children: /* @__PURE__ */ jsx(Navbar, { brand: /* @__PURE__ */ jsx(Logo, {}) }) })
712
+ children: /* @__PURE__ */ jsx(Container, { children: /* @__PURE__ */ jsx(Navbar, { brand: /* @__PURE__ */ jsx(Logo, {}) }) })
610
713
  }
611
714
  );
612
715
  };
613
- const Hero = () => {
614
- return /* @__PURE__ */ jsx("section", { children: /* @__PURE__ */ jsx(Content, {}) });
716
+ const Hero = ({ title, subtitle, content, link, image }) => {
717
+ return /* @__PURE__ */ jsx(Box, { as: "section", bg: "gray.900", children: /* @__PURE__ */ jsx(Container, { children: /* @__PURE__ */ jsxs(Flex, { direction: { base: "column", md: "row" }, children: [
718
+ /* @__PURE__ */ jsx(Flex, { align: "center", justify: { base: "center", md: "flex-start" }, flex: 1, py: 8, pe: 8, children: /* @__PURE__ */ jsxs(Stack, { spacing: 6, w: "full", maxW: "lg", children: [
719
+ /* @__PURE__ */ jsxs(Heading, { as: "h1", fontSize: { base: "3xl", md: "4xl", lg: "5xl" }, children: [
720
+ /* @__PURE__ */ jsxs(Text, { as: "span", display: "block", children: [
721
+ title,
722
+ " —"
723
+ ] }),
724
+ /* @__PURE__ */ jsx(Text, { as: "span", display: "block", color: "brand.400", children: subtitle })
725
+ ] }),
726
+ /* @__PURE__ */ jsx(Text, { fontSize: { base: "md", lg: "lg" }, color: "gray.500", children: content }),
727
+ !!link && /* @__PURE__ */ jsx(Flex, { direction: { base: "column", md: "row" }, children: /* @__PURE__ */ jsx(LinkButton, { ...link }) })
728
+ ] }) }),
729
+ image && /* @__PURE__ */ jsx(Flex, { display: { base: "none", md: "flex" }, flex: 1, children: image })
730
+ ] }) }) });
615
731
  };
616
732
  const Main = ({ children }) => {
617
733
  return /* @__PURE__ */ jsx(
@@ -620,7 +736,6 @@ const Main = ({ children }) => {
620
736
  as: "main",
621
737
  direction: "column",
622
738
  flexGrow: 1,
623
- py: 4,
624
739
  bg: useColorModeValue("white", "gray.800"),
625
740
  color: useColorModeValue("gray.700", "gray.200"),
626
741
  children
@@ -679,6 +794,12 @@ const Layout = ({ children }) => {
679
794
  /* @__PURE__ */ jsx(ScrollToTop, {})
680
795
  ] });
681
796
  };
797
+ const List = ({ items, bullet = "—", render, className }) => {
798
+ return /* @__PURE__ */ jsx(List$1, { as: "ul", pl: 0, ml: 2, mb: 4, className, children: items.map((item, index) => /* @__PURE__ */ jsxs(ListItem, { as: "li", display: "flex", gap: 1, children: [
799
+ /* @__PURE__ */ jsx(Box, { children: bullet }),
800
+ render ? render(item) : item
801
+ ] }, index)) });
802
+ };
682
803
  const TitleMap = {
683
804
  pros: "advantages",
684
805
  cons: "disadvantages"
@@ -722,7 +843,7 @@ const ProsConsCard = ({ itemType, items }) => {
722
843
  p: 2,
723
844
  borderBottomRadius: "md",
724
845
  bgColor: useColorModeValue("whiteAlpha.800", "blackAlpha.800"),
725
- children: /* @__PURE__ */ jsx(List, { spacing: 4, p: 0, children: items.map(({ title, description }) => /* @__PURE__ */ jsxs(ListItem, { display: "flex", children: [
846
+ children: /* @__PURE__ */ jsx(List$1, { spacing: 4, p: 0, children: items.map(({ title, description }) => /* @__PURE__ */ jsxs(ListItem, { display: "flex", children: [
726
847
  /* @__PURE__ */ jsx(ListIcon, { as: IconMap[itemType], w: 6, h: 6, color: IconColorMap[itemType] }),
727
848
  /* @__PURE__ */ jsxs(Text, { fontWeight: "semibold", fontSize: "md", children: [
728
849
  title,
@@ -768,16 +889,66 @@ const Seo = ({ children, siteMetadata, title, description, lang }) => {
768
889
  children
769
890
  ] });
770
891
  };
892
+ const Table = ({
893
+ columnNumber,
894
+ items,
895
+ caption,
896
+ bordered = false,
897
+ striped = true,
898
+ scrollable,
899
+ className
900
+ }) => {
901
+ const headerItems = items.slice(0, columnNumber);
902
+ const bodyItems = items.slice(columnNumber);
903
+ return /* @__PURE__ */ jsxs(
904
+ TableContainer,
905
+ {
906
+ border: bordered ? void 0 : "none",
907
+ ...scrollable ? { maxH: "50vh", overflowY: "auto" } : {},
908
+ className,
909
+ children: [
910
+ /* @__PURE__ */ jsxs(Table$1, { variant: striped ? "striped" : "simple", children: [
911
+ /* @__PURE__ */ jsx(Thead, { ...scrollable ? { position: "sticky", top: 0, zIndex: 1, bg: "gray.800" } : {}, children: /* @__PURE__ */ jsx(Tr, { children: headerItems.map((item, index) => /* @__PURE__ */ jsx(Th, { children: item }, index)) }) }),
912
+ /* @__PURE__ */ jsx(Tbody, { children: Array.from({ length: Math.ceil(bodyItems.length / columnNumber) }, (_, rowIndex) => /* @__PURE__ */ jsx(Tr, { children: Array.from({ length: columnNumber }, (_2, colIndex) => /* @__PURE__ */ jsx(Td, { children: bodyItems[rowIndex * columnNumber + colIndex] || "" }, colIndex)) }, rowIndex)) })
913
+ ] }),
914
+ !!caption && /* @__PURE__ */ jsx(TableCaption, { children: caption })
915
+ ]
916
+ }
917
+ );
918
+ };
919
+ const Tabs = ({ items, className, render }) => {
920
+ const { tabs, panels } = useMemo(() => {
921
+ const tabs2 = [];
922
+ const panels2 = [];
923
+ items.forEach(({ content, ...tab }) => {
924
+ tabs2.push(tab);
925
+ panels2.push(content);
926
+ });
927
+ return { tabs: tabs2, panels: panels2 };
928
+ }, []);
929
+ return /* @__PURE__ */ jsxs(Tabs$1, { overflow: "hidden", colorScheme: "brand", className, children: [
930
+ /* @__PURE__ */ jsx(TabList, { overflow: "auto hidden", children: tabs.map(({ label, icon }, index) => /* @__PURE__ */ jsx(Tab, { children: /* @__PURE__ */ jsx(Text, { as: "h3", isTruncated: true, children: icon ? `${icon} ${label}` : label }) }, index)) }),
931
+ /* @__PURE__ */ jsx(TabPanels, { children: panels.map((panel, index) => /* @__PURE__ */ jsx(TabPanel, { children: render(panel) }, index)) })
932
+ ] });
933
+ };
771
934
  export {
772
935
  Author as A,
936
+ BonusCard as B,
773
937
  ContactForm as C,
774
938
  ExpertTip as E,
775
939
  Faq as F,
776
- GameDemo as G,
940
+ GameCard as G,
777
941
  HowTo as H,
778
942
  Layout as L,
779
943
  ProsCons as P,
780
944
  Seo as S,
945
+ Table as T,
781
946
  Features as a,
782
- GameInfo as b
947
+ GameDemo as b,
948
+ GameInfo as c,
949
+ List as d,
950
+ Tabs as e,
951
+ Center as f,
952
+ Grid as g,
953
+ LinkButton as h
783
954
  };
@@ -9,9 +9,10 @@ const index = require("./index-D96zh94V.js");
9
9
  const react = require("react");
10
10
  const index$1 = require("./index-IpSV-c71.js");
11
11
  const react$2 = require("@emotion/react");
12
- const i18n = require("./index-DB1dS9cp.js");
12
+ const i18n = require("./index-DCIXk-YH.js");
13
13
  const i18n$1 = require("i18next");
14
- const index$2 = require("./index-C68DPwvx.js");
14
+ const index$2 = require("./index-jvxaXXE3.js");
15
+ require("@ctrl/tinycolor");
15
16
  const gatsby = require("gatsby");
16
17
  const ONE_LINE_HEIGHT = 24;
17
18
  const Bio = ({ content, maxLines = 1 }) => {
@@ -78,6 +79,85 @@ const Author = ({ author, ...cardProps }) => {
78
79
  )
79
80
  ] });
80
81
  };
82
+ const Center = ({ children, className }) => {
83
+ return /* @__PURE__ */ jsxRuntime.jsx(react$1.Center, { className, children });
84
+ };
85
+ const defaultColumns = { base: 1, sm: 2, md: 3, lg: 4, xl: 5 };
86
+ const Grid = ({ items, columns = defaultColumns, gap, render, getKey, className }) => {
87
+ return /* @__PURE__ */ jsxRuntime.jsx(react$1.SimpleGrid, { as: "ul", columns, spacing: gap, p: 0, m: 0, listStyleType: "none", className, children: items.map((item, index2) => /* @__PURE__ */ jsxRuntime.jsx(react$1.Box, { as: "li", children: render(item) }, getKey ? getKey(item) : index2)) });
88
+ };
89
+ const LinkButton = ({ label, url, width = "auto" }) => {
90
+ return /* @__PURE__ */ jsxRuntime.jsx(
91
+ react$1.Button,
92
+ {
93
+ as: react$1.Link,
94
+ href: url,
95
+ w: width,
96
+ bg: "brand.600",
97
+ textTransform: "uppercase",
98
+ _hover: { textDecoration: "none", bg: "brand.300" },
99
+ _active: { transform: "scale(0.95)" },
100
+ children: label
101
+ }
102
+ );
103
+ };
104
+ const BonusCardContent = ({ content }) => {
105
+ const { t } = reactI18next.useTranslation("author");
106
+ return /* @__PURE__ */ jsxRuntime.jsx(react$1.Popover, { flip: false, matchWidth: false, placement: "bottom", children: ({ isOpen }) => /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
107
+ /* @__PURE__ */ jsxRuntime.jsx(react$1.PopoverTrigger, { children: /* @__PURE__ */ jsxRuntime.jsx(react$1.Button, { size: "sm", variant: "link", color: "white", children: isOpen ? t("action.collapse") : t("action.expand") }) }),
108
+ /* @__PURE__ */ jsxRuntime.jsx(react$1.PopoverContent, { w: 60, children: /* @__PURE__ */ jsxRuntime.jsx(react$1.PopoverBody, { children: Array.isArray(content) ? /* @__PURE__ */ jsxRuntime.jsx(react$1.Stack, { children: content.map((paragraph, index2) => /* @__PURE__ */ jsxRuntime.jsx(react$1.Text, { as: "span", children: paragraph }, index2)) }) : /* @__PURE__ */ jsxRuntime.jsx(react$1.Text, { children: content }) }) })
109
+ ] }) });
110
+ };
111
+ const BonusCardTitle = ({ content }) => {
112
+ return /* @__PURE__ */ jsxRuntime.jsx(
113
+ react$1.Text,
114
+ {
115
+ as: "h3",
116
+ display: "inline-block",
117
+ py: 1,
118
+ px: 2,
119
+ borderRadius: "md",
120
+ bg: "yellow",
121
+ color: "black",
122
+ fontWeight: "bold",
123
+ fontSize: "lg",
124
+ children: content
125
+ }
126
+ );
127
+ };
128
+ const BonusCard = ({ title, subtitle, content, link, image, className }) => {
129
+ return /* @__PURE__ */ jsxRuntime.jsxs(
130
+ react$1.Card,
131
+ {
132
+ as: "article",
133
+ h: "full",
134
+ bg: "linear-gradient(90deg, #3b1f47, #731d58)",
135
+ overflow: "hidden",
136
+ _before: image ? {
137
+ content: '""',
138
+ position: "absolute",
139
+ top: 0,
140
+ left: 0,
141
+ w: "100%",
142
+ h: "100%",
143
+ bgImage: `url(${image})`,
144
+ bgSize: "cover",
145
+ bgPosition: "center",
146
+ filter: "blur(0.05em) opacity(50%)",
147
+ zIndex: 0
148
+ } : void 0,
149
+ className,
150
+ children: [
151
+ /* @__PURE__ */ jsxRuntime.jsxs(react$1.CardBody, { as: "section", pb: 0, flex: 1, children: [
152
+ /* @__PURE__ */ jsxRuntime.jsx(BonusCardTitle, { content: title }),
153
+ /* @__PURE__ */ jsxRuntime.jsx(react$1.Text, { fontSize: "2xl", fontWeight: "bold", my: 2, children: subtitle }),
154
+ /* @__PURE__ */ jsxRuntime.jsx(BonusCardContent, { content })
155
+ ] }),
156
+ /* @__PURE__ */ jsxRuntime.jsx(react$1.CardFooter, { as: "footer", p: 4, children: /* @__PURE__ */ jsxRuntime.jsx(LinkButton, { ...link, width: "full" }) })
157
+ ]
158
+ }
159
+ );
160
+ };
81
161
  const ContactForm = () => {
82
162
  const toast = react$1.useToast();
83
163
  const { t } = reactI18next.useTranslation("contactForm");
@@ -194,6 +274,26 @@ const Features = ({ features, ...boxProps }) => {
194
274
  /* @__PURE__ */ jsxRuntime.jsx(react$1.CardBody, { as: "section", pt: 0, children: /* @__PURE__ */ jsxRuntime.jsx(react$1.Text, { color: "gray.600", children: description }) })
195
275
  ] }) }, title)) });
196
276
  };
277
+ const GameCard = ({ name, image, link, className }) => {
278
+ return /* @__PURE__ */ jsxRuntime.jsxs(
279
+ react$1.LinkBox,
280
+ {
281
+ as: "article",
282
+ rounded: "md",
283
+ borderWidth: 1,
284
+ transition: "transform 0.2s ease",
285
+ cursor: link ? "pointer" : "default",
286
+ overflow: "hidden",
287
+ bg: "blackAlpha.400",
288
+ _hover: { transform: "scale(1.1)" },
289
+ className,
290
+ children: [
291
+ typeof image === "string" ? /* @__PURE__ */ jsxRuntime.jsx(react$1.Image, { src: image, alt: name, w: "100%", aspectRatio: "16/9", objectFit: "cover", objectPosition: "center" }) : !!image && /* @__PURE__ */ jsxRuntime.jsx(react$1.Box, { w: "100%", aspectRatio: "16/9", children: image }),
292
+ /* @__PURE__ */ jsxRuntime.jsx(react$1.Box, { as: "section", rounded: "md", p: 4, children: /* @__PURE__ */ jsxRuntime.jsx(react$1.Text, { as: "span", children: link ? /* @__PURE__ */ jsxRuntime.jsx(react$1.LinkOverlay, { href: link, children: name }) : name }) })
293
+ ]
294
+ }
295
+ );
296
+ };
197
297
  const GameDemoContent = ({ src, isFullscreen, isLoaded, onLoad, onToggleFullscreen }) => {
198
298
  const { t } = reactI18next.useTranslation("gameDemo");
199
299
  return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
@@ -395,8 +495,11 @@ const HowTo = ({ steps, ...boxProps }) => {
395
495
  ] })
396
496
  ] }, index2)) });
397
497
  };
498
+ const Container = ({ children }) => {
499
+ return /* @__PURE__ */ jsxRuntime.jsx(react$1.Container, { maxW: "container.xl", children });
500
+ };
398
501
  const Content = ({ children }) => {
399
- return /* @__PURE__ */ jsxRuntime.jsx(react$1.Container, { as: "section", maxW: "container.xl", children });
502
+ return /* @__PURE__ */ jsxRuntime.jsx(react$1.Box, { as: "section", py: 4, children: /* @__PURE__ */ jsxRuntime.jsx(Container, { children }) });
400
503
  };
401
504
  const Logo = () => {
402
505
  const { logoImageData } = index.useSiteMetadataContext();
@@ -463,7 +566,7 @@ const Footer = () => {
463
566
  bg: react$1.useColorModeValue("gray.50", "gray.900"),
464
567
  color: react$1.useColorModeValue("gray.700", "gray.200"),
465
568
  py: 4,
466
- children: /* @__PURE__ */ jsxRuntime.jsxs(Content, { children: [
569
+ children: /* @__PURE__ */ jsxRuntime.jsxs(Container, { children: [
467
570
  /* @__PURE__ */ jsxRuntime.jsx(Navigation$1, {}),
468
571
  /* @__PURE__ */ jsxRuntime.jsx(Disclaimer, {}),
469
572
  /* @__PURE__ */ jsxRuntime.jsx(Brand$1, { brand: /* @__PURE__ */ jsxRuntime.jsx(Logo, {}) }),
@@ -607,12 +710,25 @@ const Header = () => {
607
710
  color: react$1.useColorModeValue("gray.700", "gray.200"),
608
711
  boxShadow: "sm",
609
712
  zIndex: 100,
610
- children: /* @__PURE__ */ jsxRuntime.jsx(Content, { children: /* @__PURE__ */ jsxRuntime.jsx(Navbar, { brand: /* @__PURE__ */ jsxRuntime.jsx(Logo, {}) }) })
713
+ children: /* @__PURE__ */ jsxRuntime.jsx(Container, { children: /* @__PURE__ */ jsxRuntime.jsx(Navbar, { brand: /* @__PURE__ */ jsxRuntime.jsx(Logo, {}) }) })
611
714
  }
612
715
  );
613
716
  };
614
- const Hero = () => {
615
- return /* @__PURE__ */ jsxRuntime.jsx("section", { children: /* @__PURE__ */ jsxRuntime.jsx(Content, {}) });
717
+ const Hero = ({ title, subtitle, content, link, image }) => {
718
+ return /* @__PURE__ */ jsxRuntime.jsx(react$1.Box, { as: "section", bg: "gray.900", children: /* @__PURE__ */ jsxRuntime.jsx(Container, { children: /* @__PURE__ */ jsxRuntime.jsxs(react$1.Flex, { direction: { base: "column", md: "row" }, children: [
719
+ /* @__PURE__ */ jsxRuntime.jsx(react$1.Flex, { align: "center", justify: { base: "center", md: "flex-start" }, flex: 1, py: 8, pe: 8, children: /* @__PURE__ */ jsxRuntime.jsxs(react$1.Stack, { spacing: 6, w: "full", maxW: "lg", children: [
720
+ /* @__PURE__ */ jsxRuntime.jsxs(react$1.Heading, { as: "h1", fontSize: { base: "3xl", md: "4xl", lg: "5xl" }, children: [
721
+ /* @__PURE__ */ jsxRuntime.jsxs(react$1.Text, { as: "span", display: "block", children: [
722
+ title,
723
+ " —"
724
+ ] }),
725
+ /* @__PURE__ */ jsxRuntime.jsx(react$1.Text, { as: "span", display: "block", color: "brand.400", children: subtitle })
726
+ ] }),
727
+ /* @__PURE__ */ jsxRuntime.jsx(react$1.Text, { fontSize: { base: "md", lg: "lg" }, color: "gray.500", children: content }),
728
+ !!link && /* @__PURE__ */ jsxRuntime.jsx(react$1.Flex, { direction: { base: "column", md: "row" }, children: /* @__PURE__ */ jsxRuntime.jsx(LinkButton, { ...link }) })
729
+ ] }) }),
730
+ image && /* @__PURE__ */ jsxRuntime.jsx(react$1.Flex, { display: { base: "none", md: "flex" }, flex: 1, children: image })
731
+ ] }) }) });
616
732
  };
617
733
  const Main = ({ children }) => {
618
734
  return /* @__PURE__ */ jsxRuntime.jsx(
@@ -621,7 +737,6 @@ const Main = ({ children }) => {
621
737
  as: "main",
622
738
  direction: "column",
623
739
  flexGrow: 1,
624
- py: 4,
625
740
  bg: react$1.useColorModeValue("white", "gray.800"),
626
741
  color: react$1.useColorModeValue("gray.700", "gray.200"),
627
742
  children
@@ -680,6 +795,12 @@ const Layout = ({ children }) => {
680
795
  /* @__PURE__ */ jsxRuntime.jsx(ScrollToTop, {})
681
796
  ] });
682
797
  };
798
+ const List = ({ items, bullet = "—", render, className }) => {
799
+ return /* @__PURE__ */ jsxRuntime.jsx(react$1.List, { as: "ul", pl: 0, ml: 2, mb: 4, className, children: items.map((item, index2) => /* @__PURE__ */ jsxRuntime.jsxs(react$1.ListItem, { as: "li", display: "flex", gap: 1, children: [
800
+ /* @__PURE__ */ jsxRuntime.jsx(react$1.Box, { children: bullet }),
801
+ render ? render(item) : item
802
+ ] }, index2)) });
803
+ };
683
804
  const TitleMap = {
684
805
  pros: "advantages",
685
806
  cons: "disadvantages"
@@ -769,14 +890,64 @@ const Seo = ({ children, siteMetadata, title, description, lang }) => {
769
890
  children
770
891
  ] });
771
892
  };
893
+ const Table = ({
894
+ columnNumber,
895
+ items,
896
+ caption,
897
+ bordered = false,
898
+ striped = true,
899
+ scrollable,
900
+ className
901
+ }) => {
902
+ const headerItems = items.slice(0, columnNumber);
903
+ const bodyItems = items.slice(columnNumber);
904
+ return /* @__PURE__ */ jsxRuntime.jsxs(
905
+ react$1.TableContainer,
906
+ {
907
+ border: bordered ? void 0 : "none",
908
+ ...scrollable ? { maxH: "50vh", overflowY: "auto" } : {},
909
+ className,
910
+ children: [
911
+ /* @__PURE__ */ jsxRuntime.jsxs(react$1.Table, { variant: striped ? "striped" : "simple", children: [
912
+ /* @__PURE__ */ jsxRuntime.jsx(react$1.Thead, { ...scrollable ? { position: "sticky", top: 0, zIndex: 1, bg: "gray.800" } : {}, children: /* @__PURE__ */ jsxRuntime.jsx(react$1.Tr, { children: headerItems.map((item, index2) => /* @__PURE__ */ jsxRuntime.jsx(react$1.Th, { children: item }, index2)) }) }),
913
+ /* @__PURE__ */ jsxRuntime.jsx(react$1.Tbody, { children: Array.from({ length: Math.ceil(bodyItems.length / columnNumber) }, (_, rowIndex) => /* @__PURE__ */ jsxRuntime.jsx(react$1.Tr, { children: Array.from({ length: columnNumber }, (_2, colIndex) => /* @__PURE__ */ jsxRuntime.jsx(react$1.Td, { children: bodyItems[rowIndex * columnNumber + colIndex] || "" }, colIndex)) }, rowIndex)) })
914
+ ] }),
915
+ !!caption && /* @__PURE__ */ jsxRuntime.jsx(react$1.TableCaption, { children: caption })
916
+ ]
917
+ }
918
+ );
919
+ };
920
+ const Tabs = ({ items, className, render }) => {
921
+ const { tabs, panels } = react.useMemo(() => {
922
+ const tabs2 = [];
923
+ const panels2 = [];
924
+ items.forEach(({ content, ...tab }) => {
925
+ tabs2.push(tab);
926
+ panels2.push(content);
927
+ });
928
+ return { tabs: tabs2, panels: panels2 };
929
+ }, []);
930
+ return /* @__PURE__ */ jsxRuntime.jsxs(react$1.Tabs, { overflow: "hidden", colorScheme: "brand", className, children: [
931
+ /* @__PURE__ */ jsxRuntime.jsx(react$1.TabList, { overflow: "auto hidden", children: tabs.map(({ label, icon }, index2) => /* @__PURE__ */ jsxRuntime.jsx(react$1.Tab, { children: /* @__PURE__ */ jsxRuntime.jsx(react$1.Text, { as: "h3", isTruncated: true, children: icon ? `${icon} ${label}` : label }) }, index2)) }),
932
+ /* @__PURE__ */ jsxRuntime.jsx(react$1.TabPanels, { children: panels.map((panel, index2) => /* @__PURE__ */ jsxRuntime.jsx(react$1.TabPanel, { children: render(panel) }, index2)) })
933
+ ] });
934
+ };
772
935
  exports.Author = Author;
936
+ exports.BonusCard = BonusCard;
937
+ exports.Center = Center;
773
938
  exports.ContactForm = ContactForm;
774
939
  exports.ExpertTip = ExpertTip;
775
940
  exports.Faq = Faq;
776
941
  exports.Features = Features;
942
+ exports.GameCard = GameCard;
777
943
  exports.GameDemo = GameDemo;
778
944
  exports.GameInfo = GameInfo;
945
+ exports.Grid = Grid;
779
946
  exports.HowTo = HowTo;
780
947
  exports.Layout = Layout;
948
+ exports.LinkButton = LinkButton;
949
+ exports.List = List;
781
950
  exports.ProsCons = ProsCons;
782
951
  exports.Seo = Seo;
952
+ exports.Table = Table;
953
+ exports.Tabs = Tabs;