{"ast":null,"code":"var _jsxFileName = \"/app/src/Components/TracksForRecordTable.js\",\n _s = $RefreshSig$();\n\nimport React, { useContext, useState, useEffect } from 'react';\nimport { Link } from 'react-router-dom';\nimport { getAlbumTracks, getArtistTracks } from '../Api/index';\nimport ScaleLoader from 'react-spinners/ScaleLoader';\nimport { jsxDEV as _jsxDEV } from \"react/jsx-dev-runtime\";\n\nconst TracksForRecordTable = props => {\n _s();\n\n const [tracks, setTracks] = useState({});\n const [loading, setLoading] = useState(true);\n useEffect(() => {\n if (props.albumuuid !== undefined) {\n getAlbumTracks(props.albumuuid).then(data => {\n setTracks(data);\n setLoading(false);\n });\n } else if (props.artistuuid !== undefined) {\n getArtistTracks(props.artistuuid).then(data => {\n setTracks(data);\n setLoading(false);\n });\n }\n }, [props.albumuuid, props.artistuuid]);\n\n if (loading) {\n return /*#__PURE__*/_jsxDEV(\"div\", {\n className: \"pageWrapper\",\n children: /*#__PURE__*/_jsxDEV(ScaleLoader, {\n color: \"#6AD7E5\"\n }, void 0, false, {\n fileName: _jsxFileName,\n lineNumber: 29,\n columnNumber: 11\n }, this)\n }, void 0, false, {\n fileName: _jsxFileName,\n lineNumber: 28,\n columnNumber: 9\n }, this);\n }\n\n console.log(tracks);\n return /*#__PURE__*/_jsxDEV(\"div\", {\n style: {\n textAlign: `center`\n },\n children: [\"Tracks\", /*#__PURE__*/_jsxDEV(\"br\", {}, void 0, false, {\n fileName: _jsxFileName,\n lineNumber: 39,\n columnNumber: 19\n }, this), /*#__PURE__*/_jsxDEV(\"div\", {\n style: {\n border: `1px solid #FFFFFF`,\n width: `100%`,\n display: `flex`,\n flexWrap: `wrap`,\n minWidth: `300px`,\n maxWidth: `1200px`\n },\n children: tracks && tracks.tracks && Object.keys(tracks.tracks).map(key => {\n return /*#__PURE__*/_jsxDEV(\"div\", {\n style: {\n borderBottom: `1px solid #CCC`,\n width: `100%`,\n padding: `2px`\n },\n children: /*#__PURE__*/_jsxDEV(Link, {\n to: \"/track/\" + tracks.tracks[key].uuid,\n children: [\" \", tracks.tracks[key].name]\n }, \"track\" + tracks.tracks[key].uuid, true, {\n fileName: _jsxFileName,\n lineNumber: 52,\n columnNumber: 22\n }, this)\n }, \"box\" + tracks.tracks[key].uuid, false, {\n fileName: _jsxFileName,\n lineNumber: 51,\n columnNumber: 23\n }, this);\n })\n }, void 0, false, {\n fileName: _jsxFileName,\n lineNumber: 40,\n columnNumber: 9\n }, this)]\n }, void 0, true, {\n fileName: _jsxFileName,\n lineNumber: 37,\n columnNumber: 8\n }, this);\n};\n\n_s(TracksForRecordTable, \"gL+UZKRPM2bUOc7d9pxgg2EZX44=\");\n\n_c = TracksForRecordTable;\nexport default TracksForRecordTable;\n\nvar _c;\n\n$RefreshReg$(_c, \"TracksForRecordTable\");","map":{"version":3,"sources":["/app/src/Components/TracksForRecordTable.js"],"names":["React","useContext","useState","useEffect","Link","getAlbumTracks","getArtistTracks","ScaleLoader","TracksForRecordTable","props","tracks","setTracks","loading","setLoading","albumuuid","undefined","then","data","artistuuid","console","log","textAlign","border","width","display","flexWrap","minWidth","maxWidth","Object","keys","map","key","borderBottom","padding","uuid","name"],"mappings":";;;AAAA,OAAOA,KAAP,IAAgBC,UAAhB,EAA4BC,QAA5B,EAAsCC,SAAtC,QAAuD,OAAvD;AACA,SAASC,IAAT,QAAqB,kBAArB;AACA,SAASC,cAAT,EAAyBC,eAAzB,QAAgD,cAAhD;AACA,OAAOC,WAAP,MAAwB,4BAAxB;;;AAEA,MAAMC,oBAAoB,GAAIC,KAAD,IAAW;AAAA;;AACrC,QAAM,CAACC,MAAD,EAASC,SAAT,IAAsBT,QAAQ,CAAC,EAAD,CAApC;AACA,QAAM,CAACU,OAAD,EAAUC,UAAV,IAAwBX,QAAQ,CAAC,IAAD,CAAtC;AAEAC,EAAAA,SAAS,CAAC,MAAM;AACb,QAAIM,KAAK,CAACK,SAAN,KAAoBC,SAAxB,EAAmC;AAChCV,MAAAA,cAAc,CAACI,KAAK,CAACK,SAAP,CAAd,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AAiCT,YAAAA,KAAK,EAAG,MAAzC;AAAgDU,YAAAA,OAAO,EAAG;AAA1D,WAAZ;AAAA,iCACD,QAAC,IAAD;AAEG,YAAA,EAAE,EAAE,YAAUvB,MAAM,CAACA,MAAP,CAAcqB,GAAd,EAAmBG,IAFpC;AAAA,4BAGAxB,MAAM,CAACA,MAAP,CAAcqB,GAAd,EAAmBI,IAHnB;AAAA,aACQ,UAAUzB,MAAM,CAACA,MAAP,CAAcqB,GAAd,EAAmBG,IADrC;AAAA;AAAA;AAAA;AAAA;AADC,WAAkF,QAAQxB,MAAM,CAACA,MAAP,CAAcqB,GAAd,EAAmBG,IAA7G;AAAA;AAAA;AAAA;AAAA,gBAAP;AAOF,OARD;AAVJ;AAAA;AAAA;AAAA;AAAA,YAHD;AAAA;AAAA;AAAA;AAAA;AAAA,UADH;AA2BH,CAzDD;;GAAM1B,oB;;KAAAA,oB;AA2DN,eAAeA,oBAAf","sourcesContent":["import React, { useContext, useState, useEffect } from 'react';\nimport { Link } from 'react-router-dom';\nimport { getAlbumTracks, getArtistTracks } from '../Api/index'\nimport ScaleLoader from 'react-spinners/ScaleLoader';\n\nconst TracksForRecordTable = (props) => {\n const [tracks, setTracks] = useState({});\n const [loading, setLoading] = useState(true);\n\n useEffect(() => {\n if (props.albumuuid !== undefined) {\n getAlbumTracks(props.albumuuid)\n .then(data => {\n setTracks(data);\n setLoading(false);\n })\n } else if (props.artistuuid !== undefined) {\n getArtistTracks(props.artistuuid)\n .then(data => {\n setTracks(data);\n setLoading(false);\n })\n } \n }, [props.albumuuid, props.artistuuid]);\n\n if (loading) {\n return (\n