{"version":3,"sources":["I18n.js","components/Header.js","components/NavBar.js","components/Footer.js","routes/Home.js","components/Page.js","routes/Rules.js","routes/Tos.js","App.js","serviceWorker.js","index.js"],"names":["I18n","createI18n","en","main","route","language","rules","tos","onlinePlayers","copyright","fr","Header","props","languageHandler","e","preventDefault","setState","langToggled","state","console","log","stripLocale","pathname","locale","replace","this","match","location","params","className","to","t","src","alt","width","onClick","ignoreLocale","href","target","rel","React","Component","NavBar","Footer","Home","urlTestImage","Fragment","style","backgroundImage","datetime","Page","title","children","Rules","Tos","base","App","path","component","exact","Boolean","window","hostname","ReactDOM","render","StrictMode","document","getElementById","navigator","serviceWorker","ready","then","registration","unregister","catch","error","message"],"mappings":"uSAkCeA,EAFFC,qBA5BG,CAAC,KAAM,MAGF,CACpBC,GAAI,CACHC,KAAM,CACLC,MAAO,CACNC,SAAU,WACVC,MAAO,QACPC,IAAK,OAENC,cAAe,iBACfC,UAAW,wBAGbC,GAAI,CACHP,KAAM,CACLC,MAAO,CACNC,SAAU,SACVC,MAAO,eACPC,IAAK,OAENC,cAAe,mBACfC,UAAW,kCCmFCE,E,kDAvGb,WAAYC,GAAQ,IAAD,8BACjB,cAAMA,IAIRC,gBAAkB,SAACC,GACjBA,EAAEC,iBACF,EAAKC,SAAS,CAAEC,aAAc,EAAKC,MAAMD,cACzCE,QAAQC,IAAI,EAAKF,MAAMD,cARN,EAwBnBI,YAAc,SAACC,EAAUC,GACvB,OAAKA,EAIED,EAASE,QAAT,WAAqBD,GAAU,IAH7BD,GAxBT,EAAKJ,MAAQ,CAAED,aAAa,GAFX,E,qDAgCT,IAAD,EACqBQ,KAAKb,MAAzBc,EADD,EACCA,MACFJ,EAFC,EACQK,SACWL,SACpBC,EAASG,EAAME,OAAOL,OAE5B,OACE,yBAAKM,UAAU,0BACb,yBAAKA,UAAU,2BACb,wBAAIA,UAAU,WACZ,kBAAC,OAAD,CAAMC,GAAG,KAAT,eAEF,yBAAKD,UAAU,kBACb,wCADF,OACoB,kBAAC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AAD,CAAOI,KAAI,UAAKF,EAAL,QAAiBG,UAAWJ,KAEzC,kBAAC,IAAD,CAAOG,KAAMF,EAAMG,UAAWhB,MCXhBkB,QACW,cAA7BC,OAAOlC,SAASmC,UAEe,UAA7BD,OAAOlC,SAASmC,UAEhBD,OAAOlC,SAASmC,SAASpC,MACvB,2DCZNqC,IAASC,OACP,kBAAC,IAAMC,WAAP,KACE,kBAAC,EAAD,OAEFC,SAASC,eAAe,SDyHpB,kBAAmBC,WACrBA,UAAUC,cAAcC,MACrBC,MAAK,SAAAC,GACJA,EAAaC,gBAEdC,OAAM,SAAAC,GACLxD,QAAQwD,MAAMA,EAAMC,c","file":"static/js/main.c0f727c8.chunk.js","sourcesContent":["import { createI18n } from \"react-router-i18n\";\n\n// Array of supported locales\n// The first in the array is treated as the default locale\nconst locales = [\"en\", \"fr\"];\n\n// Dictionary of translations\nconst translations = {\n\ten: {\n\t\tmain: {\n\t\t\troute: {\n\t\t\t\tlanguage: \"Language\",\n\t\t\t\trules: \"Rules\",\n\t\t\t\ttos: \"TOS\",\n\t\t\t},\n\t\t\tonlinePlayers: \"online players\",\n\t\t\tcopyright: \"All Right Reserved.\",\n\t\t},\n\t},\n\tfr: {\n\t\tmain: {\n\t\t\troute: {\n\t\t\t\tlanguage: \"Langue\",\n\t\t\t\trules: \"Règlement\",\n\t\t\t\ttos: \"CGU\",\n\t\t\t},\n\t\t\tonlinePlayers: \"joueurs en ligne\",\n\t\t\tcopyright: \"Tous droits réservés.\",\n\t\t},\n\t},\n};\n\nconst I18n = createI18n(locales, translations);\n\nexport default I18n;\n","import React from \"react\";\nimport PropTypes from 'prop-types';\nimport { Link } from \"react-router-i18n\";\nimport I18n from \"../I18n\";\n\nclass Header extends React.Component {\n\n constructor(props) {\n super(props);\n this.state = { langToggled: false };\n }\n\n languageHandler = (e) => {\n e.preventDefault();\n this.setState({ langToggled: !this.state.langToggled });\n console.log(this.state.langToggled);\n };\n\n static propTypes = {\n location: PropTypes.shape({\n pathname: PropTypes.string,\n }).isRequired,\n match: PropTypes.shape({\n params: PropTypes.shape({\n locale: PropTypes.string,\n }).isRequired,\n }).isRequired,\n // eslint-disable-next-line react/forbid-prop-types\n history: PropTypes.object.isRequired,\n };\n\n stripLocale = (pathname, locale) => {\n if (!locale) {\n return pathname;\n }\n\n return pathname.replace(`/${locale}`, '');\n };\n\n render() {\n const { match, location } = this.props\n const pathname = location.pathname\n const locale = match.params.locale\n\n return (\n
\n
\n

\n BerryGames\n

\n
\n 50 \n
\n
\n
\n \n \n \n
\n
\n
\n \n \n \n {this.state.langToggled ? (\n
\n English\n
\n Français\n
\n ) : null}\n \n \n \n \n \n \n \n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n
\n
\n );\n }\n}\n\nexport default Header;\n","import React from \"react\";\nimport { Link } from \"react-router-i18n\";\n\nclass NavBar extends React.Component {\n\trender() {\n\t\treturn (\n\t\t\t
\n\t\t\t\t
\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t
\n\t\t\t
\n\t\t);\n\t}\n}\n\nexport default NavBar;\n","import React from 'react';\nimport I18n from '../I18n';\n\nclass Footer extends React.Component {\n\n render() {\n return (\n
\n © 2020 BerryGames. \n
\n )\n }\n}\n\nexport default Footer;","import React from \"react\";\nimport Footer from \"../components/Footer\";\n\nfunction Home() {\n\n\tconst urlFeaturedImage = 'https://blog.epikube.fr/content/images/2019/08/Base-Profile-Screenshot-2019.07.31---01.00.11.99.png'\n\tconst urlTestImage = 'https://teamvisionary.net/wp-content/uploads/2020/06/Mageville.jpg'\n\n\treturn (\n\t\t\n\t\t\t
\n\t\t\t\t
\n\t\t\t\t
\n\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t Featured\n \n\t\t\t\t\t\t

Lorem ipsum dolor sit amet.\n\t\t\t\t\t\t

\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\tby\n\t\t\t\t\t\t\t3DX900\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t
\n\t\t\t
\n\t\t\t
\n\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t

Lorem ipsum dolor sit amet.

\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\tby\n\t\t\t\t\t\t\t\t3DX900\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tInterview\n \n\t\t\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t

Lorem ipsum dolor sit amet.\n\t\t\t\t\t\t\t

\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\tby\n\t\t\t\t\t\t\t\t3DX900\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tInterview\n \n\t\t\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t

Lorem ipsum dolor sit amet.\n\t\t\t\t\t\t\t

\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\tby\n\t\t\t\t\t\t\t\t3DX900\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tInterview\n \n\t\t\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t

Lorem ipsum dolor sit amet.\n\t\t\t\t\t\t\t

\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\tby\n\t\t\t\t\t\t\t\t3DX900\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tInterview\n \n\t\t\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t
\n\t\t\t\t
\n\t\t\t
\n\t\t
\n\t);\n}\n\nexport default Home;\n","import React from \"react\";\nimport Footer from \"./Footer\";\n\nclass Page extends React.Component {\n\tconstructor(props) {\n\t\tsuper(props);\n\t}\n\n\trender() {\n\t\treturn (\n\t\t\t\n\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t

{this.props.title}

\n\t\t\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t
\n\t\t\t\t
\n\t\t\t\t\t
{this.props.children}
\n\t\t\t\t\t
\n\t\t\t\t
\n\t\t\t
\n\t\t);\n\t}\n}\n\nexport default Page;\n","import React from \"react\";\nimport Page from \"../components/Page\";\nimport I18n from \"../I18n\";\n\nfunction Rules() {\n\treturn (\n\t\t}>\n\t\t\tLorem ipsum dolor sit amet, consectetur adipisicing elit. Id autem blanditiis nulla? Placeat, omnis tempore\n\t\t\tfacere quo fuga maiores! Consectetur nostrum rerum qui tempore doloribus repellendus eius ab at temporibus\n\t\t\tquis alias nam recusandae a omnis, ipsam veniam soluta autem quas sequi est voluptates? Animi at dolore\n\t\t\tdolorum eius, quam soluta quis nesciunt vitae, sunt aliquam velit reiciendis voluptate sit? Voluptatibus\n\t\t\tminus, eveniet voluptas soluta sint recusandae autem ipsa sunt quasi consectetur facere blanditiis hic\n\t\t\tquidem dolorem provident vero accusantium, cupiditate voluptatum officiis perferendis iste eaque? Similique\n\t\t\tplaceat inventore, delectus animi magnam doloremque molestias distinctio, veniam fuga dignissimos culpa\n\t\t\tsaepe. Laboriosam sequi maiores eligendi id! Perferendis porro, architecto at rem commodi maxime debitis\n\t\t\tdolorem eum. Fugit sunt obcaecati minima veniam nostrum temporibus corrupti facilis culpa fuga quis\n\t\t\taccusantium, quae iusto amet asperiores a sed. Debitis minima nam mollitia neque vitae earum ad dolore quia\n\t\t\tprovident praesentium officia repudiandae, assumenda reprehenderit, temporibus aspernatur, veniam unde\n\t\t\tdeserunt sunt itaque quibusdam dolorem esse. Dignissimos, veniam perspiciatis aspernatur earum magni amet\n\t\t\talias quas explicabo ex quos distinctio. Autem aperiam dolorum doloremque natus, neque deserunt numquam\n\t\t\titaque omnis sed sunt perferendis corrupti repellendus, aspernatur illo, ipsum aliquam ex ad. Cumque\n\t\t\tdignissimos odit temporibus nam consectetur consequatur esse omnis nemo eligendi cum quasi adipisci tempore\n\t\t\teum in, fugit, iusto vero voluptatibus praesentium! Error explicabo nam repellat odit iure quas voluptates\n\t\t\tvitae minima quis harum maiores exercitationem consectetur id, dolores quia officiis tenetur ipsam\n\t\t\tdignissimos? Quidem reprehenderit commodi recusandae eaque officiis rerum maiores quam accusantium nisi.\n\t\t\n\t);\n}\n\nexport default Rules;\n","import React from \"react\";\nimport Page from \"../components/Page\";\nimport I18n from \"../I18n\";\n\nfunction Tos() {\n\treturn (\n\t\t}>\n\t\t\tLorem ipsum dolor sit amet, consectetur adipisicing elit. Id autem blanditiis nulla? Placeat, omnis tempore\n\t\t\tfacere quo fuga maiores! Consectetur nostrum rerum qui tempore doloribus repellendus eius ab at temporibus\n\t\t\tquis alias nam recusandae a omnis, ipsam veniam soluta autem quas sequi est voluptates? Animi at dolore\n\t\t\tdolorum eius, quam soluta quis nesciunt vitae, sunt aliquam velit reiciendis voluptate sit? Voluptatibus\n\t\t\tminus, eveniet voluptas soluta sint recusandae autem ipsa sunt quasi consectetur facere blanditiis hic\n\t\t\tquidem dolorem provident vero accusantium, cupiditate voluptatum officiis perferendis iste eaque? Similique\n\t\t\tplaceat inventore, delectus animi magnam doloremque molestias distinctio, veniam fuga dignissimos culpa\n\t\t\tsaepe. Laboriosam sequi maiores eligendi id! Perferendis porro, architecto at rem commodi maxime debitis\n\t\t\tdolorem eum. Fugit sunt obcaecati minima veniam nostrum temporibus corrupti facilis culpa fuga quis\n\t\t\taccusantium, quae iusto amet asperiores a sed. Debitis minima nam mollitia neque vitae earum ad dolore quia\n\t\t\tprovident praesentium officia repudiandae, assumenda reprehenderit, temporibus aspernatur, veniam unde\n\t\t\tdeserunt sunt itaque quibusdam dolorem esse. Dignissimos, veniam perspiciatis aspernatur earum magni amet\n\t\t\talias quas explicabo ex quos distinctio. Autem aperiam dolorum doloremque natus, neque deserunt numquam\n\t\t\titaque omnis sed sunt perferendis corrupti repellendus, aspernatur illo, ipsum aliquam ex ad. Cumque\n\t\t\tdignissimos odit temporibus nam consectetur consequatur esse omnis nemo eligendi cum quasi adipisci tempore\n\t\t\teum in, fugit, iusto vero voluptatibus praesentium! Error explicabo nam repellat odit iure quas voluptates\n\t\t\tvitae minima quis harum maiores exercitationem consectetur id, dolores quia officiis tenetur ipsam\n\t\t\tdignissimos? Quidem reprehenderit commodi recusandae eaque officiis rerum maiores quam accusantium nisi.\n\t\t\n\t);\n}\n\nexport default Tos;\n","import React from 'react';\nimport {\n BrowserRouter as Router, Route\n} from \"react-router-dom\";\nimport './App.css';\n\nimport Header from \"./components/Header\"\nimport NavBar from \"./components/NavBar\"\nimport Home from './routes/Home';\nimport Rules from './routes/Rules';\nimport Tos from './routes/Tos';\n\nconst base = '/:locale(en|fr)?';\n\nfunction App() {\n return (\n \n \n
\n \n \n \n
\n \n
\n );\n}\n\nexport default App;\n","// This optional code is used to register a service worker.\n// register() is not called by default.\n\n// This lets the app load faster on subsequent visits in production, and gives\n// it offline capabilities. However, it also means that developers (and users)\n// will only see deployed updates on subsequent visits to a page, after all the\n// existing tabs open on the page have been closed, since previously cached\n// resources are updated in the background.\n\n// To learn more about the benefits of this model and instructions on how to\n// opt-in, read https://bit.ly/CRA-PWA\n\nconst isLocalhost = Boolean(\n window.location.hostname === 'localhost' ||\n // [::1] is the IPv6 localhost address.\n window.location.hostname === '[::1]' ||\n // 127.0.0.0/8 are considered localhost for IPv4.\n window.location.hostname.match(\n /^127(?:\\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}$/\n )\n);\n\nexport function register(config) {\n if (process.env.NODE_ENV === 'production' && 'serviceWorker' in navigator) {\n // The URL constructor is available in all browsers that support SW.\n const publicUrl = new URL(process.env.PUBLIC_URL, window.location.href);\n if (publicUrl.origin !== window.location.origin) {\n // Our service worker won't work if PUBLIC_URL is on a different origin\n // from what our page is served on. This might happen if a CDN is used to\n // serve assets; see https://github.com/facebook/create-react-app/issues/2374\n return;\n }\n\n window.addEventListener('load', () => {\n const swUrl = `${process.env.PUBLIC_URL}/service-worker.js`;\n\n if (isLocalhost) {\n // This is running on localhost. Let's check if a service worker still exists or not.\n checkValidServiceWorker(swUrl, config);\n\n // Add some additional logging to localhost, pointing developers to the\n // service worker/PWA documentation.\n navigator.serviceWorker.ready.then(() => {\n console.log(\n 'This web app is being served cache-first by a service ' +\n 'worker. To learn more, visit https://bit.ly/CRA-PWA'\n );\n });\n } else {\n // Is not localhost. Just register service worker\n registerValidSW(swUrl, config);\n }\n });\n }\n}\n\nfunction registerValidSW(swUrl, config) {\n navigator.serviceWorker\n .register(swUrl)\n .then(registration => {\n registration.onupdatefound = () => {\n const installingWorker = registration.installing;\n if (installingWorker == null) {\n return;\n }\n installingWorker.onstatechange = () => {\n if (installingWorker.state === 'installed') {\n if (navigator.serviceWorker.controller) {\n // At this point, the updated precached content has been fetched,\n // but the previous service worker will still serve the older\n // content until all client tabs are closed.\n console.log(\n 'New content is available and will be used when all ' +\n 'tabs for this page are closed. See https://bit.ly/CRA-PWA.'\n );\n\n // Execute callback\n if (config && config.onUpdate) {\n config.onUpdate(registration);\n }\n } else {\n // At this point, everything has been precached.\n // It's the perfect time to display a\n // \"Content is cached for offline use.\" message.\n console.log('Content is cached for offline use.');\n\n // Execute callback\n if (config && config.onSuccess) {\n config.onSuccess(registration);\n }\n }\n }\n };\n };\n })\n .catch(error => {\n console.error('Error during service worker registration:', error);\n });\n}\n\nfunction checkValidServiceWorker(swUrl, config) {\n // Check if the service worker can be found. If it can't reload the page.\n fetch(swUrl, {\n headers: { 'Service-Worker': 'script' },\n })\n .then(response => {\n // Ensure service worker exists, and that we really are getting a JS file.\n const contentType = response.headers.get('content-type');\n if (\n response.status === 404 ||\n (contentType != null && contentType.indexOf('javascript') === -1)\n ) {\n // No service worker found. Probably a different app. Reload the page.\n navigator.serviceWorker.ready.then(registration => {\n registration.unregister().then(() => {\n window.location.reload();\n });\n });\n } else {\n // Service worker found. Proceed as normal.\n registerValidSW(swUrl, config);\n }\n })\n .catch(() => {\n console.log(\n 'No internet connection found. App is running in offline mode.'\n );\n });\n}\n\nexport function unregister() {\n if ('serviceWorker' in navigator) {\n navigator.serviceWorker.ready\n .then(registration => {\n registration.unregister();\n })\n .catch(error => {\n console.error(error.message);\n });\n }\n}\n","import React from 'react';\nimport ReactDOM from 'react-dom';\nimport './index.css';\nimport App from './App';\nimport * as serviceWorker from './serviceWorker';\n\nReactDOM.render(\n \n \n ,\n document.getElementById('root')\n);\n\n// If you want your app to work offline and load faster, you can change\n// unregister() to register() below. Note this comes with some pitfalls.\n// Learn more about service workers: https://bit.ly/CRA-PWA\nserviceWorker.unregister();\n"],"sourceRoot":""}