1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6125],{6655:function(a,b,c){function d(a){return(d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(a){return typeof a}:function(a){return a&&"function"==typeof Symbol&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a})(a)}Object.defineProperty(b,"__esModule",{value:!0}),b.default=void 0;var e=function(a){if(a&&a.__esModule)return a;if(null===a||"object"!==d(a)&&"function"!=typeof a)return{default:a};var b=h();if(b&&b.has(a))return b.get(a);var c={},e=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var f in a)if(Object.prototype.hasOwnProperty.call(a,f)){var g=e?Object.getOwnPropertyDescriptor(a,f):null;g&&(g.get||g.set)?Object.defineProperty(c,f,g):c[f]=a[f]}return c.default=a,b&&b.set(a,c),c}(c(7294)),f=c(6281),g=c(9790);function h(){if("function"!=typeof WeakMap)return null;var a=new WeakMap;return h=function(){return a},a}function i(a,b){var c=Object.keys(a);if(Object.getOwnPropertySymbols){var d=Object.getOwnPropertySymbols(a);b&&(d=d.filter(function(b){return Object.getOwnPropertyDescriptor(a,b).enumerable})),c.push.apply(c,d)}return c}function j(a){for(var b=1;b<arguments.length;b++){var c=null!=arguments[b]?arguments[b]:{};b%2?i(Object(c),!0).forEach(function(b){o(a,b,c[b])}):Object.getOwnPropertyDescriptors?Object.defineProperties(a,Object.getOwnPropertyDescriptors(c)):i(Object(c)).forEach(function(b){Object.defineProperty(a,b,Object.getOwnPropertyDescriptor(c,b))})}return a}function k(a,b){for(var c=0;c<b.length;c++){var d=b[c];d.enumerable=d.enumerable||!1,d.configurable=!0,"value"in d&&(d.writable=!0),Object.defineProperty(a,d.key,d)}}function l(a,b){return(l=Object.setPrototypeOf||function(a,b){return a.__proto__=b,a})(a,b)}function m(a){if(void 0===a)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return a}function n(a){return(n=Object.setPrototypeOf?Object.getPrototypeOf:function(a){return a.__proto__||Object.getPrototypeOf(a)})(a)}function o(a,b,c){return b in a?Object.defineProperty(a,b,{value:c,enumerable:!0,configurable:!0,writable:!0}):a[b]=c,a}var p=function(a){!function(a,b){if("function"!=typeof b&&null!==b)throw TypeError("Super expression must either be null or a function");a.prototype=Object.create(b&&b.prototype,{constructor:{value:a,writable:!0,configurable:!0}}),b&&l(a,b)}(q,a);var b,c,g,h,i,p=(b=q,c=function a(){if("undefined"==typeof Reflect||!Reflect.construct||Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(b){return!1}}(),function(){var a,e,f,g=n(b);if(c){var h=n(this).constructor;f=Reflect.construct(g,arguments,h)}else f=g.apply(this,arguments);return a=this,e=f,e&&("object"===d(e)||"function"==typeof e)?e:m(a)});function q(){var a;!function(a,b){if(!(a instanceof b))throw TypeError("Cannot call a class as a function")}(this,q);for(var b=arguments.length,c=Array(b),d=0;d<b;d++)c[d]=arguments[d];return a=p.call.apply(p,[this].concat(c)),o(m(a),"callPlayer",f.callPlayer),o(m(a),"duration",null),o(m(a),"currentTime",null),o(m(a),"fractionLoaded",null),o(m(a),"mute",function(){a.setVolume(0)}),o(m(a),"unmute",function(){null!==a.props.volume&&a.setVolume(a.props.volume)}),o(m(a),"ref",function(b){a.iframe=b}),a}return g=q,h=[{key:"componentDidMount",value:function(){this.props.onMount&&this.props.onMount(this)}},{key:"load",value:function(a,b){var c=this;(0,f.getSDK)("https://w.soundcloud.com/player/api.js","SC").then(function(d){if(c.iframe){var e=d.Widget.Events,f=e.PLAY,g=e.PLAY_PROGRESS,h=e.PAUSE,i=e.FINISH,k=e.ERROR;b||(c.player=d.Widget(c.iframe),c.player.bind(f,c.props.onPlay),c.player.bind(h,function(){!(c.duration-c.currentTime<.05)&&c.props.onPause()}),c.player.bind(g,function(a){c.currentTime=a.currentPosition/1e3,c.fractionLoaded=a.loadedProgress}),c.player.bind(i,function(){return c.props.onEnded()}),c.player.bind(k,function(a){return c.props.onError(a)})),c.player.load(a,j(j({},c.props.config.options),{},{callback:function(){c.player.getDuration(function(a){c.duration=a/1e3,c.props.onReady()})}}))}})}},{key:"play",value:function(){this.callPlayer("play")}},{key:"pause",value:function(){this.callPlayer("pause")}},{key:"stop",value:function(){}},{key:"seekTo",value:function(a){this.callPlayer("seekTo",1e3*a)}},{key:"setVolume",value:function(a){this.callPlayer("setVolume",100*a)}},{key:"getDuration",value:function(){return this.duration}},{key:"getCurrentTime",value:function(){return this.currentTime}},{key:"getSecondsLoaded",value:function(){return this.fractionLoaded*this.duration}},{key:"render",value:function(){var a=this.props.display;return e.default.createElement("iframe",{ref:this.ref,src:"https://w.soundcloud.com/player/?url=".concat(encodeURIComponent(this.props.url)),style:{width:"100%",height:"100%",display:a},frameBorder:0,allow:"autoplay"})}}],k(g.prototype,h),i&&k(g,i),q}(e.Component);b.default=p,o(p,"displayName","SoundCloud"),o(p,"canPlay",g.canPlay.soundcloud),o(p,"loopOnEnded",!0)}}])
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.