GoScrobble/web/node_modules/.cache/babel-loader/cc5f1a6fd20bb929b3b28047e45a2bfd.json

1 line
8.5 KiB
JSON
Raw Normal View History

2022-04-25 02:47:15 +00:00
{"ast":null,"code":"var _jsxFileName = \"/app/src/Components/HomeBanner.js\",\n _s = $RefreshSig$();\n\nimport React, { useEffect, useState } from 'react';\nimport '../App.css';\nimport './HomeBanner.css';\nimport { getStats } from '../Api/index';\nimport ClipLoader from 'react-spinners/ClipLoader';\nimport { Link } from 'react-router-dom';\nimport { jsxDEV as _jsxDEV } from \"react/jsx-dev-runtime\";\n\nconst HomeBanner = () => {\n _s();\n\n let [bannerData, setBannerData] = useState({});\n let [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n getStats().then(data => {\n if (data.users !== undefined) {\n setBannerData(data);\n setIsLoading(false);\n }\n });\n }, []);\n return /*#__PURE__*/_jsxDEV(\"div\", {\n className: \"homeBanner\",\n children: [/*#__PURE__*/_jsxDEV(\"div\", {\n className: \"homeBannerItem\",\n children: /*#__PURE__*/_jsxDEV(Link, {\n to: \"/recent\",\n className: \"homeBannerItemLink\",\n children: [isLoading ? /*#__PURE__*/_jsxDEV(ClipLoader, {\n color: \"#6AD7E5\",\n size: 34\n }, void 0, false, {\n fileName: _jsxFileName,\n lineNumber: 27,\n columnNumber: 15\n }, this) : /*#__PURE__*/_jsxDEV(\"span\", {\n className: \"homeBannerItemCount\",\n children: bannerData.scrobbles\n }, void 0, false, {\n fileName: _jsxFileName,\n lineNumber: 28,\n columnNumber: 15\n }, this), /*#__PURE__*/_jsxDEV(\"br\", {}, void 0, false, {\n fileName: _jsxFileName,\n lineNumber: 31,\n columnNumber: 11\n }, this), \"Scrobbles\"]\n }, void 0, true, {\n fileName: _jsxFileName,\n lineNumber: 25,\n columnNumber: 9\n }, this)\n }, void 0, false, {\n fileName: _jsxFileName,\n lineNumber: 24,\n columnNumber: 7\n }, this), /*#__PURE__*/_jsxDEV(\"div\", {\n className: \"homeBannerItem\",\n children: [isLoading ? /*#__PURE__*/_jsxDEV(ClipLoader, {\n color: \"#6AD7E5\",\n size: 34\n }, void 0, false, {\n fileName: _jsxFileName,\n lineNumber: 36,\n columnNumber: 13\n }, this) : /*#__PURE__*/_jsxDEV(\"span\", {\n className: \"homeBannerItemCount\",\n children: bannerData.users\n }, void 0, false, {\n fileName: _jsxFileName,\n lineNumber: 37,\n columnNumber: 13\n }, this), /*#__PURE__*/_jsxDEV(\"br\", {}, void 0, false, {\n fileName: _jsxFileName,\n lineNumber: 39,\n columnNumber: 9\n }, this), \"Users\"]\n }, void 0, true, {\n fileName: _jsxFileName,\n lineNumber: 34,\n columnNumber: 7\n }, this), /*#__PURE__*/_jsxDEV(\"div\", {\n className: \"homeBannerItem\",\n children: [isLoading ? /*#__PURE__*/_jsxDEV(ClipLoader, {\n color: \"#6AD7E5\",\n size: 34\n }, void 0, false, {\n fileName: _jsxFileName,\n lineNumber: 43,\n columnNumber: 13\n }, this) : /*#__PURE__*/_jsxDEV(\"span\", {\n className: \"homeBannerItemCount\",\n children: bannerData.tracks\n }, void 0, false, {\n fileName: _jsxFileName,\n lineNumber: 44,\n columnNumber: 13\n }, this), /*#__PURE__*/_jsxDEV(\"br\", {}, void 0, false, {\n fileName: _jsxFileName,\n lineNumber: 46,\n columnNumber: 9\n }, this), \"Tracks\"]\n }, void 0, true, {\n fileName: _jsxFileName,\n lineNumber: 41,\n columnNumber: 7\n }, this), /*#__PURE__*/_jsxDEV(\"div\", {\n className: \"homeBannerItem\",\n children: [isLoading ? /*#__PURE__*/_jsxDEV(ClipLoader, {\n color: \"#6AD7E5\",\n size: 34\n }, void 0, false, {\n fileName: _jsxFileName,\n lineNumber: 50,\n columnNumber: 13\n }, this) : /*#__PURE__*/_jsxDEV(\"span\", {\n className: \"homeBannerItemCount\",\n children: bannerData.artists\n }, void 0, false, {\n fileName: _jsxFileName,\n