This commit is contained in:
ruihildt committed 2020-07-23 21:30:58 +02:00
commit 0afc771a60
16 files changed
+199

No files matched your search

+19
View File
@@ -0,0 +1,19 @@
{
"files": {
"main.js": "/spoti-search/static/js/main.d5729ca7.chunk.js",
"main.js.map": "/spoti-search/static/js/main.d5729ca7.chunk.js.map",
"runtime-main.js": "/spoti-search/static/js/runtime-main.c30f5be2.js",
"runtime-main.js.map": "/spoti-search/static/js/runtime-main.c30f5be2.js.map",
"static/js/2.f5c50d49.chunk.js": "/spoti-search/static/js/2.f5c50d49.chunk.js",
"static/js/2.f5c50d49.chunk.js.map": "/spoti-search/static/js/2.f5c50d49.chunk.js.map",
"index.html": "/spoti-search/index.html",
"precache-manifest.ddc2f33480751a029d100cd7d0e001f4.js": "/spoti-search/precache-manifest.ddc2f33480751a029d100cd7d0e001f4.js",
"service-worker.js": "/spoti-search/service-worker.js",
"static/js/2.f5c50d49.chunk.js.LICENSE.txt": "/spoti-search/static/js/2.f5c50d49.chunk.js.LICENSE.txt"
},
"entrypoints": [
"static/js/runtime-main.c30f5be2.js",
"static/js/2.f5c50d49.chunk.js",
"static/js/main.d5729ca7.chunk.js"
]
}
BIN
View File
Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

+1
View File
@@ -0,0 +1 @@
<!doctype html><html lang="en"><head><meta charset="utf-8"/><link rel="icon" href="/spoti-search/favicon.ico"/><meta name="viewport" content="width=device-width,initial-scale=1"/><meta name="theme-color" content="#000000"/><meta name="description" content="A frontend to search for an artist and display its albums"/><link rel="apple-touch-icon" href="/spoti-search/logo192.png"/><link rel="manifest" href="/spoti-search/manifest.json"/><link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto:300,400,500"/><title>Spoti Search</title><style>body{margin:0}</style></head><body><noscript>You need to enable JavaScript to run this app.</noscript><div id="root"></div><script>!function(e){function r(r){for(var n,i,a=r[0],l=r[1],p=r[2],f=0,s=[];f<a.length;f++)i=a[f],Object.prototype.hasOwnProperty.call(o,i)&&o[i]&&s.push(o[i][0]),o[i]=0;for(n in l)Object.prototype.hasOwnProperty.call(l,n)&&(e[n]=l[n]);for(c&&c(r);s.length;)s.shift()();return u.push.apply(u,p||[]),t()}function t(){for(var e,r=0;r<u.length;r++){for(var t=u[r],n=!0,a=1;a<t.length;a++){var l=t[a];0!==o[l]&&(n=!1)}n&&(u.splice(r--,1),e=i(i.s=t[0]))}return e}var n={},o={1:0},u=[];function i(r){if(n[r])return n[r].exports;var t=n[r]={i:r,l:!1,exports:{}};return e[r].call(t.exports,t,t.exports,i),t.l=!0,t.exports}i.m=e,i.c=n,i.d=function(e,r,t){i.o(e,r)||Object.defineProperty(e,r,{enumerable:!0,get:t})},i.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.t=function(e,r){if(1&r&&(e=i(e)),8&r)return e;if(4&r&&"object"==typeof e&&e&&e.__esModule)return e;var t=Object.create(null);if(i.r(t),Object.defineProperty(t,"default",{enumerable:!0,value:e}),2&r&&"string"!=typeof e)for(var n in e)i.d(t,n,function(r){return e[r]}.bind(null,n));return t},i.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(r,"a",r),r},i.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},i.p="/spoti-search/";var a=this["webpackJsonpspoti-search"]=this["webpackJsonpspoti-search"]||[],l=a.push.bind(a);a.push=r,a=a.slice();for(var p=0;p<a.length;p++)r(a[p]);var c=l;t()}([])</script><script src="/spoti-search/static/js/2.f5c50d49.chunk.js"></script><script src="/spoti-search/static/js/main.d5729ca7.chunk.js"></script></body></html>
BIN
View File
Binary file not shown.

After

Width:  |  Height:  |  Size: 5.2 KiB

BIN
View File
Binary file not shown.

After

Width:  |  Height:  |  Size: 9.4 KiB

+25
View File
@@ -0,0 +1,25 @@
{
"short_name": "React App",
"name": "Create React App Sample",
"icons": [
{
"src": "favicon.ico",
"sizes": "64x64 32x32 24x24 16x16",
"type": "image/x-icon"
},
{
"src": "logo192.png",
"type": "image/png",
"sizes": "192x192"
},
{
"src": "logo512.png",
"type": "image/png",
"sizes": "512x512"
}
],
"start_url": ".",
"display": "standalone",
"theme_color": "#000000",
"background_color": "#ffffff"
}
@@ -0,0 +1,22 @@
self.__precacheManifest = (self.__precacheManifest || []).concat([
{
"revision": "bd4e2216d96b60e23b76ec8e9ae16d5c",
"url": "/spoti-search/index.html"
},
{
"revision": "d91e41b9eb2072aa0092",
"url": "/spoti-search/static/js/2.f5c50d49.chunk.js"
},
{
"revision": "150ff86ada6d4117f6d430f6acba325e",
"url": "/spoti-search/static/js/2.f5c50d49.chunk.js.LICENSE.txt"
},
{
"revision": "dd7dd0cfc148390dd40c",
"url": "/spoti-search/static/js/main.d5729ca7.chunk.js"
},
{
"revision": "d8701ba7eff8f72dc134",
"url": "/spoti-search/static/js/runtime-main.c30f5be2.js"
}
]);
+3
View File
@@ -0,0 +1,3 @@
# https://www.robotstxt.org/robotstxt.html
User-agent: *
Disallow:
+39
View File
@@ -0,0 +1,39 @@
/**
* Welcome to your Workbox-powered service worker!
*
* You'll need to register this file in your web app and you should
* disable HTTP caching for this file too.
* See https://goo.gl/nhQhGp
*
* The rest of the code is auto-generated. Please don't update this file
* directly; instead, make changes to your Workbox build configuration
* and re-run your build process.
* See https://goo.gl/2aRDsh
*/
importScripts("https://storage.googleapis.com/workbox-cdn/releases/4.3.1/workbox-sw.js");
importScripts(
"/spoti-search/precache-manifest.ddc2f33480751a029d100cd7d0e001f4.js"
);
self.addEventListener('message', (event) => {
if (event.data && event.data.type === 'SKIP_WAITING') {
self.skipWaiting();
}
});
workbox.core.clientsClaim();
/**
* The workboxSW.precacheAndRoute() method efficiently caches and responds to
* requests for URLs in the manifest.
* See https://goo.gl/S9QRab
*/
self.__precacheManifest = [].concat(self.__precacheManifest || []);
workbox.precaching.precacheAndRoute(self.__precacheManifest, {});
workbox.routing.registerNavigationRoute(workbox.precaching.getCacheKeyForURL("/spoti-search/index.html"), {
blacklist: [/^\/_/,/\/[^/?]+\.[^/]+$/],
});
+3
View File
@@ -0,0 +1,3 @@
/*! For license information please see 2.f5c50d49.chunk.js.LICENSE.txt */
(this["webpackJsonpspoti-search"]=this["webpackJsonpspoti-search"]||[]).push([[2],[function(e,t,n){"use strict";e.exports=n(116)},function(e,t,n){"use strict";n.r(t),function(e){n.d(t,"ServerStyleSheet",(function(){return Fe})),n.d(t,"StyleSheetConsumer",(function(){return Y})),n.d(t,"StyleSheetContext",(function(){return G})),n.d(t,"StyleSheetManager",(function(){return ne})),n.d(t,"ThemeConsumer",(function(){return je})),n.d(t,"ThemeContext",(function(){return Se})),n.d(t,"ThemeProvider",(function(){return Te})),n.d(t,"__PRIVATE__",(function(){return Le})),n.d(t,"createGlobalStyle",(function(){return Re})),n.d(t,"css",(function(){return se})),n.d(t,"isStyledComponent",(function(){return w})),n.d(t,"keyframes",(function(){return De})),n.d(t,"useTheme",(function(){return ze})),n.d(t,"version",(function(){return Be})),n.d(t,"withTheme",(function(){return Me}));var r=n(59),i=n(0),o=n.n(i),a=n(93),u=n.n(a),c=n(94),l=n(95),s=n(83),f=n(77),d=n.n(f);function p(){return(p=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}var h=function(e,t){for(var n=[e[0]],r=0,i=t.length;r<i;r+=1)n.push(t[r],e[r+1]);return n},v=function(e){return null!==e&&"object"===typeof e&&"[object Object]"===(e.toString?e.toString():Object.prototype.toString.call(e))&&!Object(r.typeOf)(e)},b=Object.freeze([]),m=Object.freeze({});function y(e){return"function"===typeof e}function g(e){return e.displayName||e.name||"Component"}function w(e){return e&&"string"===typeof e.styledComponentId}var O="undefined"!==typeof e&&(Object({NODE_ENV:"production",PUBLIC_URL:"/spoti-search",WDS_SOCKET_HOST:void 0,WDS_SOCKET_PATH:void 0,WDS_SOCKET_PORT:void 0}).REACT_APP_SC_ATTR||Object({NODE_ENV:"production",PUBLIC_URL:"/spoti-search",WDS_SOCKET_HOST:void 0,WDS_SOCKET_PATH:void 0,WDS_SOCKET_PORT:void 0}).SC_ATTR)||"data-styled",x="undefined"!==typeof window&&"HTMLElement"in window,k="boolean"===typeof SC_DISABLE_SPEEDY&&SC_DISABLE_SPEEDY||"undefined"!==typeof e&&(Object({NODE_ENV:"production",PUBLIC_URL:"/spoti-search",WDS_SOCKET_HOST:void 0,WDS_SOCKET_PATH:void 0,WDS_SOCKET_PORT:void 0}).REACT_APP_SC_DISABLE_SPEEDY||Object({NODE_ENV:"production",PUBLIC_URL:"/spoti-search",WDS_SOCKET_HOST:void 0,WDS_SOCKET_PATH:void 0,WDS_SOCKET_PORT:void 0}).SC_DISABLE_SPEEDY)||!1,_={},E=function(){return n.nc};function S(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];throw new Error("An error occurred. See https://github.com/styled-components/styled-components/blob/master/packages/styled-components/src/utils/errors.md#"+e+" for more information."+(n.length>0?" Additional arguments: "+n.join(", "):""))}var j=function(e){var t=document.head,n=e||t,r=document.createElement("style"),i=function(e){for(var t=e.childNodes,n=t.length;n>=0;n--){var r=t[n];if(r&&1===r.nodeType&&r.hasAttribute(O))return r}}(n),o=void 0!==i?i.nextSibling:null;r.setAttribute(O,"active"),r.setAttribute("data-styled-version","5.1.1");var a=E();return a&&r.setAttribute("nonce",a),n.insertBefore(r,o),r},T=function(){function e(e){var t=this.element=j(e);t.appendChild(document.createTextNode("")),this.sheet=function(e){if(e.sheet)return e.sheet;for(var t=document.styleSheets,n=0,r=t.length;n<r;n++){var i=t[n];if(i.ownerNode===e)return i}S(17)}(t),this.length=0}var t=e.prototype;return t.insertRule=function(e,t){try{return this.sheet.insertRule(t,e),this.length++,!0}catch(n){return!1}},t.deleteRule=function(e){this.sheet.deleteRule(e),this.length--},t.getRule=function(e){var t=this.sheet.cssRules[e];return void 0!==t&&"string"===typeof t.cssText?t.cssText:""},e}(),C=function(){function e(e){var t=this.element=j(e);this.nodes=t.childNodes,this.length=0}var t=e.prototype;return t.insertRule=function(e,t){if(e<=this.length&&e>=0){var n=document.createTextNode(t),r=this.nodes[e];return this.element.insertBefore(n,r||null),this.length++,!0}return!1},t.deleteRule=function(e){this.element.removeChild(this.nodes[e]),this.length--},t.getRule=function(e){return e<this.length?this.nodes[e].textContent:""},e}(),P=function(){function e(e){this.rules=[],this.length=0}var t=e.prototype;return t.insertRule=function(e,t){return e<=this.length&&(this.rules.splice(e,0,t),this.length++,!0)},t.deleteRule=function(e){this.rules.splice(e,1),this.length--},t.getRule=function(e){return e<this.length?this.rules[e]:""},e}(),I=function(){function e(e){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=e}var t=e.prototype;return t.indexOfGroup=function(e){for(var t=0,n=0;n<e;n++)t+=this.groupSizes[n];return t},t.insertRules=function(e,t){if(e>=this.groupSizes.length){for(var n=this.groupSizes,r=n.length,i=r;e>=i;)(i<<=1)<0&&S(16,""+e);this.groupSizes=new Uint32Array(i),this.groupSizes.set(n),this.length=i;for(var o=r;o<i;o++)this.groupSizes[o]=0}for(var a=this.indexOfGroup(e+1),u=0,c=t.length;u<c;u++)this.tag.insertRule(a,t[u])&&(this.groupSizes[e]++,a++)},Line truncated
//# sourceMappingURL=2.f5c50d49.chunk.js.map
+80
View File
@@ -0,0 +1,80 @@
/*
object-assign
(c) Sindre Sorhus
@license MIT
*/
/*! *****************************************************************************
Copyright (c) Microsoft Corporation.
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
PERFORMANCE OF THIS SOFTWARE.
***************************************************************************** */
/*! *****************************************************************************
Copyright (c) Microsoft Corporation. All rights reserved.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
this file except in compliance with the License. You may obtain a copy of the
License at http://www.apache.org/licenses/LICENSE-2.0
THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
MERCHANTABLITY OR NON-INFRINGEMENT.
See the Apache Version 2.0 License for specific language governing permissions
and limitations under the License.
***************************************************************************** */
/**
* @license
* Lodash <https://lodash.com/>
* Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
* Released under MIT license <https://lodash.com/license>
* Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
* Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
*/
/** @license React v0.19.1
* scheduler.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/** @license React v16.13.1
* react-dom.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/** @license React v16.13.1
* react-is.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/** @license React v16.13.1
* react.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
+1
View File
@@ -0,0 +1 @@
{"version":3,"sources":["../node_modules/react/index.js","../../src/constants.js","../../src/sheet/Tag.js","../../src/sheet/GroupedTag.js","../../src/sheet/GroupIDAllocator.js","../../src/sheet/Sheet.js","../../src/models/StyleSheetManager.js","../../src/utils/isStaticRules.js","../../src/models/ComponentStyle.js","../../src/models/StyledComponent.js","../../src/models/GlobalStyle.js","../../src/constructors/createGlobalStyle.js","../../src/models/ServerStyleSheet.js","../../src/base.js","../node_modules/tslib/tslib.es6.js","../../src/invariant.ts","../storeUtils.js","../node_modules/grommet/es6/default-props.js","../networkStatus.js","../node_modules/zen-observable/index.js","../getFromAST.js","../helpers.js","../node_modules/graphql/jsutils/defineInspect.mjs","../node_modules/graphql/jsutils/invariant.mjs","../node_modules/graphql/language/ast.mjs","../node_modules/grommet/es6/utils/mixins.js","../../src/equality.ts","../node_modules/grommet/es6/utils/colors.js","../ApolloError.js","../../src/cache.ts","../../src/context.ts","../../src/helpers.ts","../../src/entry.ts","../../src/key-trie.ts","../../src/dep.ts","../../src/index.ts","../fragments.js","../node_modules/grommet-icons/StyledIcon.js","../node_modules/graphql/language/visitor.mjs","../ApolloLink.js","../createOperation.js","../transformOperation.js","../validateOperation.js","../reactiveVars.js","../parser.js","../arrays.js","../mergeDeep.js","../directives.js","../../src/slot.ts","../node_modules/graphql/language/printer.mjs","../selectHttpOptionsAndBody.js","../serializeFetchParameter.js","../execute.js","../node_modules/graphql-tag/src/index.js","../filterInPlace.js","../transform.js","../node_modules/symbol-observable/es/index.js","../node_modules/react-dom/index.js","../throwServerError.js","../fromError.js","../policies.js","../ApolloContext.js","../iteration.js","../selectURI.js","../parseAndCheckHttpResponse.js","../checkFetcher.js","../createSignalIfSupported.js","../rewriteURIForGET.js","../createHttpLink.js","../HttpLink.js","../cache.js","../common.js","../Reobserver.js","../ObservableQuery.js","../canUse.js","../node_modules/grommet-icons/icons/FormDown.js","../node_modules/@babel/runtime/helpers/esm/slicedToArray.js","../node_modules/@babel/runtime/helpers/esm/arrayWithHoles.js","../node_modules/@babel/runtime/helpers/esm/iterableToArrayLimit.js","../node_modules/@babel/runtime/helpers/esm/nonIterableRest.js","../node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js","../node_modules/graphql/jsutils/nodejsCustomInspectSymbol.mjs","../LocalState.js","../errorHandling.js","../mutations.js","../asyncMap.js","../Concast.js","../QueryInfo.js","../QueryManager.js","../version.js","../ApolloClient.js","../entityStore.js","../readFromStore.js","../writeToStore.js","../inMemoryCache.js","../node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js","../node_modules/react-is/index.js","../node_modules/grommet/es6/utils/background.js","../node_modules/graphql/jsutils/inspect.mjs","../node_modules/graphql/language/blockString.mjs","../node_modules/grommet/es6/utils/object.js","../node_modules/grommet-icons/icons/FormUp.js","../node_modules/process/browser.js","../node_modules/grommet-styles/es6/utils/index.js","../node_modules/grommet-icons/themes/base.js","../node_modules/grommet-styles/es6/utils/colors.js","../cloneDeep.js","../Cache.js","../index.js","../RenderPromises.js","../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../node_modules/grommet-icons/icons/Previous.js","../node_modules/grommet-icons/icons/Next.js","../node_modules/prop-types/index.js","../node_modules/polished/node_modules/@babel/runtime/helpers/esm/getPrototypeOf.js","../node_modules/polished/node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../node_modules/polished/node_modules/@babel/runtime/helpers/esm/isNativeReflectConstruct.js","../node_modules/polished/node_modules/@babel/runtime/helpers/esm/construct.js","../node_modules/polished/node_modules/@babel/runtime/helpers/esm/wrapNativeSuper.js","../node_modules/polished/node_modules/@babel/runtime/helpers/esm/isNativeFunction.js","../node_modules/polished/dist/polished.esm.js","../node_modules/polished/node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../node_modules/polished/node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js","../node_modules/grommet/es6/themes/base.js","../node_modules/@babel/runtime/helpers/esm/toConsumableArray.js","../node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js","../node_modules/@babel/runtime/helpers/esm/iterableToArray.js","../node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js","../node_modules/@emotion/memoize/dist/memoize.browser.esm.js","../node_modules/@emotion/is-prop-valid/dist/is-prop-valid.browser.esm.js","../node_modules/object-assign/index.js","../node_modules/webpack/buildin/global.js","../node_modules/grommet-styles/es6/styles/color.js","../ApolloProvider.js","../QueryData.js",".Line truncated
+2
View File
@@ -0,0 +1,2 @@
(this["webpackJsonpspoti-search"]=this["webpackJsonpspoti-search"]||[]).push([[0],{115:function(e,t,a){e.exports=a(131)},131:function(e,t,a){"use strict";a.r(t);var n=a(0),r=a.n(n),l=a(33),c=a.n(l),i=a(56),s=a(57),o=a(88),u=a(82),m=a(51),g=a(91),h=a(147),p=a(92),d=a(76),f=a(89),b=a(148),E=function(e){return r.a.createElement(b.a,Object.assign({as:"header",direction:"row",align:"center",justify:"center",background:"brand",pad:{left:"medium",right:"small",vertical:"small"},style:{zIndex:1}},e))},v=a(144),y=a(145),j=function(e){var t=e.inputValue,a=e.handleChange,n=e.suggestions,l=e.handleSelect;return r.a.createElement(b.a,{as:"section",direction:"row",justify:"center",margin:{vertical:"large"}},r.a.createElement(v.a,{value:t,onChange:a,onSelect:l,placeholder:"Type an artist name",icon:r.a.createElement(y.a,{color:"plain"}),dropHeight:"large",suggestions:n}))},O=a(151),S=a(149),w=a(146),x=a(143),k=a(150),A=function(e){var t=e.image,a=e.name;return r.a.createElement(b.a,{round:"xxsmall",elevation:"small",overflow:"hidden"},r.a.createElement(b.a,{height:"300px"},r.a.createElement(S.a,{src:t,fit:"cover"})),r.a.createElement(b.a,{pad:{horizontal:"small"}},r.a.createElement(b.a,{margin:{top:"small"},direction:"row",align:"center",justify:"between"},r.a.createElement(b.a,null,r.a.createElement(k.a,{level:"4",margin:{bottom:"small",top:"xsmall"}},a)))))},q=function(e){var t=e.artists,a=t[0],n=a.name,l=a.image,c=a.albums;return r.a.createElement(O.a,{rows:["fit","fit"],columns:["1/4","3/4"],gap:"small",areas:[["artist","other"],["discography","discography"]]},r.a.createElement(b.a,{gridArea:"artist",height:"300px"},r.a.createElement("h1",null,n),r.a.createElement(S.a,{src:l,fit:"cover"})),r.a.createElement(b.a,{gridArea:"other",background:"light-2"},r.a.createElement("h3",null,"Other results"),t.map((function(e){return r.a.createElement(b.a,{gridArea:"artist",key:e.id},r.a.createElement(w.a,{src:e.image}),r.a.createElement("h4",null,e.name))}))),r.a.createElement(x.a.Consumer,null,(function(e){return r.a.createElement(O.a,{gridArea:"discography",align:"start",columns:{count:"fill",size:"300px"},gap:"medium"},r.a.createElement(k.a,{level:"1"},"Discography"),c.map((function(e){return r.a.createElement(A,{key:e.id,image:e.image,name:e.name})})))})))};function C(){var e=Object(g.a)(["\n\tquery Artist($byName: String!) {\n\t\tqueryArtists(byName: $byName) {\n\t\t\tname\n\t\t\timage\n\t\t\tid\n\t\t\talbums {\n\t\t\t\tname\n\t\t\t\timage\n\t\t\t\tid\n\t\t\t}\n\t\t}\n\t}\n"]);return C=function(){return e},e}var z=Object(d.a)(C());function N(){var e=Object(n.useState)(""),t=Object(m.a)(e,2),a=t[0],l=t[1],c=Object(f.a)(z),i=Object(m.a)(c,2),s=i[0],o=i[1].data,g=Object(n.useState)([]),d=Object(m.a)(g,2),b=d[0],v=d[1],y=Object(n.useState)(),O=Object(m.a)(y,2),S=O[0],w=O[1],x=Object(n.useState)(!1),k=Object(m.a)(x,2),A=k[0],C=k[1],N=Object(n.useCallback)(Object(p.debounce)((function(){s({variables:{byName:a}})}),500),[a]);Object(n.useEffect)((function(){return N(),N.cancel}),[a,N]);return Object(n.useEffect)((function(){if(o&&o.queryArtists!==[]){var e=o.queryArtists.slice(0,5).map((function(e){return e.name}));w(e)}}),[o]),r.a.createElement(h.a,{theme:I},r.a.createElement(E,null,r.a.createElement("h1",null,"Spoti Search")),r.a.createElement(j,{inputValue:a,handleChange:function(e){l(e.target.value)},suggestions:S,handleSelect:function(e){for(var t=e.suggestion,a=[],n=o.queryArtists.slice(0,5).map((function(e){return e})),r=0;r<n.length;r++)if(n[r].name===t){var l=null===n||void 0===n?void 0:n.splice(r,1),c=n;a=[].concat(Object(u.a)(l),Object(u.a)(c));break}v(a),C(!0)}}),A&&r.a.createElement(q,{artists:b}))}var I={global:{font:{family:"Roboto",size:"18px",height:"20px"}}},J=new i.a({uri:"https://spotify-graphql-server.herokuapp.com/graphql",cache:new s.a});c.a.render(r.a.createElement(r.a.StrictMode,null,r.a.createElement(o.a,{client:J},r.a.createElement(N,null))),document.getElementById("root"))}},[[115,1,2]]]);
//# sourceMappingURL=main.d5729ca7.chunk.js.map
+1
View File
@@ -0,0 +1 @@
{"version":3,"sources":["components/Header.tsx","components/Search.tsx","components/Card.tsx","components/Results.tsx","components/App.tsx","index.tsx"],"names":["Header","props","Box","as","direction","align","justify","background","pad","left","right","vertical","style","zIndex","Search","inputValue","handleChange","suggestions","handleSelect","margin","TextInput","value","onChange","onSelect","placeholder","icon","FormSearch","color","dropHeight","Card","image","name","round","elevation","overflow","height","Image","src","fit","horizontal","top","Heading","level","bottom","Results","artists","selectedName","selectedImage","selectedAlbums","albums","Grid","rows","columns","gap","areas","gridArea","map","artist","key","id","Avatar","ResponsiveContext","Consumer","size","count","album","QUERY_ARTISTS","gql","App","useState","setInputValue","useLazyQuery","getArtists","data","setArtists","setSuggestions","selected","setSelected","delayedQuery","useCallback","debounce","variables","byName","useEffect","cancel","queryArtists","updatedSuggestions","slice","el","Grommet","theme","e","target","suggestion","updatedArtists","suggestedArtists","item","i","length","selectedArtist","splice","otherArtists","global","font","family","client","ApolloClient","uri","cache","InMemoryCache","ReactDOM","render","StrictMode","ApolloProvider","document","getElementById"],"mappings":"gSAGaA,EAAS,SAACC,GACtB,OACC,kBAACC,EAAA,EAAD,eACCC,GAAG,SACHC,UAAU,MACVC,MAAM,SACNC,QAAQ,SACRC,WAAW,QACXC,IAAK,CAAEC,KAAM,SAAUC,MAAO,QAASC,SAAU,SACjDC,MAAO,CAAEC,OA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,QAGZ4C,EAAeW,MAEd,CAACb,IAGH,kBAACgB,EAAA,EAAD,CAASC,MAAOA,GACf,kBAAC,EAAD,KACC,6CAED,kBAAC,EAAD,CACC3E,WAAYA,EACZC,aA7DkB,SAAC2E,GACrBrB,EAAcqB,EAAEC,OAAOvE,QA6DrBJ,YAAaA,EACbC,aA/CkB,SAAC2E,GAUrB,IATA,IAAM/C,EAAuB+C,EAAWA,WACpCC,EAA0B,GAG1BC,EAA4BtB,EAAKY,aACnCE,MAAM,EAAG,GACT/B,KAAI,SAACwC,GAAD,OAAkBA,KAGfC,EAAI,EAAGA,EAAIF,EAAkBG,OAAQD,IAC7C,GAAIF,EAAkBE,GAAGlE,OAASe,EAAc,CAC/C,IAAIqD,EAAuB,OAAGJ,QAAH,IAAGA,OAAH,EAAGA,EAAkBK,OAAOH,EAAG,GACtDI,EAAwBN,EAC5BD,EAAc,sBAAOK,GAAP,YAA0BE,IACxC,MAIF3B,EAAWoB,GACXjB,GAAY,MA6BVD,GAAY,kBAAC,EAAD,CAAS/B,QAASA,KAKlC,IAAM6C,EAAQ,CACbY,OAAQ,CACPC,KAAM,CACLC,OAAQ,SACRzC,KAAM,OACN5B,OAAQ,UCvGLsE,EAAS,IAAIC,IAAa,CAC/BC,IAAK,uDACLC,MAAO,IAAIC,MAGZC,IAASC,OACR,kBAAC,IAAMC,WAAP,KACC,kBAACC,EAAA,EAAD,CAAgBR,OAAQA,GACvB,kBAACrC,EAAD,QAGF8C,SAASC,eAAe,W","file":"static/js/main.d5729ca7.chunk.js","sourcesContent":["import React, { PropsWithChildren } from 'react';\nimport { Box } from 'grommet';\n\nexport const Header = (props: PropsWithChildren<{}>) => {\n\treturn (\n\t\t<Box\n\t\t\tas='header'\n\t\t\tdirection='row'\n\t\t\talign='center'\n\t\t\tjustify='center'\n\t\t\tbackground='brand'\n\t\t\tpad={{ left: 'medium', right: 'small', vertical: 'small' }}\n\t\t\tstyle={{ zIndex: 1 }}\n\t\t\t{...props}\n\t\t/>\n\t);\n};\n","import React from 'react';\nimport { BLine truncated
+2
View File
@@ -0,0 +1,2 @@
!function(e){function r(r){for(var n,i,a=r[0],l=r[1],p=r[2],f=0,s=[];f<a.length;f++)i=a[f],Object.prototype.hasOwnProperty.call(o,i)&&o[i]&&s.push(o[i][0]),o[i]=0;for(n in l)Object.prototype.hasOwnProperty.call(l,n)&&(e[n]=l[n]);for(c&&c(r);s.length;)s.shift()();return u.push.apply(u,p||[]),t()}function t(){for(var e,r=0;r<u.length;r++){for(var t=u[r],n=!0,a=1;a<t.length;a++){var l=t[a];0!==o[l]&&(n=!1)}n&&(u.splice(r--,1),e=i(i.s=t[0]))}return e}var n={},o={1:0},u=[];function i(r){if(n[r])return n[r].exports;var t=n[r]={i:r,l:!1,exports:{}};return e[r].call(t.exports,t,t.exports,i),t.l=!0,t.exports}i.m=e,i.c=n,i.d=function(e,r,t){i.o(e,r)||Object.defineProperty(e,r,{enumerable:!0,get:t})},i.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.t=function(e,r){if(1&r&&(e=i(e)),8&r)return e;if(4&r&&"object"===typeof e&&e&&e.__esModule)return e;var t=Object.create(null);if(i.r(t),Object.defineProperty(t,"default",{enumerable:!0,value:e}),2&r&&"string"!=typeof e)for(var n in e)i.d(t,n,function(r){return e[r]}.bind(null,n));return t},i.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(r,"a",r),r},i.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},i.p="/spoti-search/";var a=this["webpackJsonpspoti-search"]=this["webpackJsonpspoti-search"]||[],l=a.push.bind(a);a.push=r,a=a.slice();for(var p=0;p<a.length;p++)r(a[p]);var c=l;t()}([]);
//# sourceMappingURL=runtime-main.c30f5be2.js.map
+1
View File
@@ -0,0 +1 @@
{"version":3,"sources":["../webpack/bootstrap"],"names":["webpackJsonpCallback","data","moduleId","chunkId","chunkIds","moreModules","executeModules","i","resolves","length","Object","prototype","hasOwnProperty","call","installedChunks","push","modules","parentJsonpFunction","shift","deferredModules","apply","checkDeferredModules","result","deferredModule","fulfilled","j","depId","splice","__webpack_require__","s","installedModules","1","exports","module","l","m","c","d","name","getter","o","defineProperty","enumerable","get","r","Symbol","toStringTag","value","t","mode","__esModule","ns","create","key","bind","n","object","property","p","jsonpArray","this","oldJsonpFunction","slice"],"mappings":"aACE,SAASA,EAAqBC,GAQ7B,IAPA,IAMIC,EAAUC,EANVC,EAAWH,EAAK,GAChBI,EAAcJ,EAAK,GACnBK,EAAiBL,EAAK,GAIHM,EAAI,EAAGC,EAAW,GACpCD,EAAIH,EAASK,OAAQF,IACzBJ,EAAUC,EAASG,GAChBG,OAAOC,UAAUC,eAAeC,KAAKC,EAAiBX,IAAYW,EAAgBX,IACpFK,EAASO,KAAKD,EAAgBX,GAAS,IAExCW,EAAgBX,GAAW,EAE5B,IAAID,KAAYG,EACZK,OAAOC,UAAUC,eAAeC,KAAKR,EAAaH,KACpDc,EAAQd,GAAYG,EAAYH,IAKlC,IAFGe,GAAqBA,EAAoBhB,GAEtCO,EAASC,QACdD,EAASU,OAATV,GAOD,OAHAW,EAAgBJ,KAAKK,MAAMD,EAAiBb,GAAkB,IAGvDe,IAER,SAASA,IAER,IADA,IAAIC,EACIf,EAAI,EAAGA,EAAIY,EAAgBV,OAAQF,IAAK,CAG/C,IAFA,IAAIgB,EAAiBJ,EAAgBZ,GACjCiB,GAAY,EACRC,EAAI,EAAGA,EAAIF,EAAed,OAAQgB,IAAK,CAC9C,IAAIC,EAAQH,EAAeE,GACG,IAA3BX,EAAgBY,KAAcF,GAAY,GAE3CA,IACFL,EAAgBQ,OAAOpB,IAAK,GAC5Be,EAASM,EAAoBA,EAAoBC,EAAIN,EAAe,KAItE,OAAOD,EAIR,IAAIQ,EAAmB,GAKnBhB,EAAkB,CACrBiB,EAAG,GAGAZ,EAAkB,GAGtB,SAASS,EAAoB1B,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,EAAoBY,EAAI,SAASgB,EAAQC,GAAY,OAAO/C,OAAOC,UAAUC,eAAeC,KAAK2C,EAAQC,IAGzG7B,EAAoB8B,EAAI,iBAExB,IAAIC,EAAaC,KAAK,4BAA8BA,KAAK,6BAA+B,GACpFC,EAAmBF,EAAW5C,KAAKuC,KAAKK,GAC5CA,EAAW5C,KAAOf,EAClB2D,EAAaA,EAAWG,QACxB,IAAI,IAAIvD,EAAI,EAAGA,EAAIoD,EAAWlD,OAAQF,IAAKP,EAAqB2D,EAAWpD,IAC3E,IAAIU,EAAsB4C,EAI1BxC,I","file":"static/js/runtime-main.c30f5be2.js","sourcesContent":[" \t// install a JSONP callback for chunk loading\n \tfunction webpackJsonpCallback(data) {\n \t\tvar chunkIds = data[0];\n \t\tvar moreModules = data[1];\n \t\tvar executeModules = data[2];\n\n \t\t// add \"moreModules\" to the modules object,\n \t\t// then flag all \"chunkIds\" as loaded and fire callback\n \t\tvar moduleId, chunkId, i = 0, resolves = [];\n \t\tfor(;i < chunkIds.length; i++) {\n \t\t\tchunkId = chunkIds[i];\n \t\t\tif(Object.prototype.hasOwnProperty.call(installedChunks, chunkId) && installedChunks[chunkId]) {\n \t\t\t\tresolves.push(installedChunks[chunkId][0]);\n \t\t\t}\n \t\t\tinstalledChunks[chunkId] = 0;\n \t\t}\n \t\tfor(moduleId in moreModules) {\n \t\t\tif(Object.prototype.hasOwnProperty.call(moreModules, moduleId)) {\n \t\t\t\tmodules[moduleId] = moreModules[moduleId];\n \t\t\t}\n \t\t}\n \t\tif(parentJsonpFunction) parentJsonpFunction(data);\n\n \t\twhile(resolves.length) {\n \t\t\tresolves.shift()();\n \t\t}\n\n \t\t// add entry modules from loaded chunk to deferred list\n \t\tdeferredModules.push.apply(deferredModules, executeModules || []);\n\n \t\t// run deferred modules when all chunks ready\n \t\treturn checkDeferredModules();\n \t};\n \tfunction checkDeferredModules() {\n \t\tvar result;\n \t\tfor(var i = 0; i < deferredModules.length; i++) {\n \t\t\tvar deferredModule = deferredModules[i];\n \t\t\tvar fulfilled = true;\n \t\t\tfor(var j = 1; j < deferredModule.length; j++) {\n \t\t\t\tvar depId = deferredModule[j];\n \t\t\t\tif(installedChunks[depId] !== 0) fulfilled = false;\n \t\t\t}\n \t\t\tif(fulfilled) {\n \t\t\t\tdeferredModules.splice(i--, 1);\n \t\t\t\tresult = __webpack_require__(__webpack_require__.s = deferredModule[0]);\n \t\t\t}\n \t\t}\n\n \t\treturn result;\n \t}\n\n \t// The module cache\n \tvar installedModules = {};\n\n \t// object to store loaded and loading chunks\n \t// undefined = chunk not loaded, null = chunk preloaded/prefetched\n \t// Promise = chunk loading, 0 = chunk loaded\n \tvar installedChunks = {\n \t\t1: 0\n \t};\n\n \tvar deferredModules = [];\n\nLine truncated