#2 JavaScript::Eval (size: 279868, repeated: 2) //git revision = 9a9b4035cba959764bc91eed3a02a24de76a1f58
//@ sourceURL=application.js
(function() {
function require(a) {
if (!require_cache[a]) {
var b = require_cache[a] = {
exports: {}
};
require_modules[a].call(b.exports, global, b, require)
}
return require_cache[a].exports
}
var global = this,
require_modules = require.modules = [],
require_cache = require.cache = [],
__requiredCss = 'body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,form,fieldset,input,textarea,p,blockquote,th,td {margin: 0; padding: 0;}\ntable {border-collapse: collapse; border-spacing: 0;}\nfieldset,img {border: 0;}\naddress,caption,cite,code,dfn,em,strong,th,var {font-style: normal; font-weight: normal;}\nol,ul {list-style: none;}\ncaption,th {text-align: left;}\nh1, h2, h3, h4, h5, h6, button {font-size: 100%; font-weight: normal;}\nq:before,q:after {content: \'\';}\nabbr,acronym {border: 0;}\n\nhtml, body {height: 100%;}\nbody {font: 13px "Lucida Grande", "Lucida Sans", Arial, sans-serif; color: #333333; text-shadow: 0 1px 0 rgba(255,255,255,0.9);}\nh1 {font-size: 16px;}\nh2 {font-size: 13px; margin-left: 10px; padding: 12px 0 12px 0;}\na {color: #0066cc; text-decoration: none;}\n* {-webkit-tap-highlight-color: rgba(0,0,0,0);}\n@media only screen and (max-device-width: 480px) {html, body {-webkit-text-size-adjust: none;}}\n\n.g-spinner {display: block; height: 20px; width: 20px; text-indent: -9999px; background: url(data:image/gif;base64,R0lGODlhEAAQAPMPALu7u5mZmTMzM93d3REREQAAAHd3d1VVVWZmZqqqqoiIiO7u7kRERCIiIgARAAAAACH/C05FVFNDQVBFMi4wAwEAAAAh+QQFBwAPACwAAAAAEAAQAEAEcPDJtyg6dUrFetDTIopMoSyFcxxD1krD8AwCkASDIlPaUDQLR6G1Cy0SgqIkE1IQGMrFAKCcGWSBzwPAnAwarcKQ15MpTMJYd1ZyUDXSDGelBY0qIoBh/ZoYGgELCjoxCRRvIQcGD1kzgSAgAACQDxEAIfkEBQcADwAsAAAAAA8AEAAABF3wyfkMkotOJpscRKJJwtI4Q1MAoxQ0RFBw0xEvhGAVRZZJh4JgMAEQW7TWI4EwGFjKR+CAQECjn8DoN0kwDtvBT8FILAKJgfoo1iAGAPNVY9DGJXNMIHN/HJVqIxEAIfkEBQcADwAsAAAAABAADwAABFrwyfmColgiydpaQiY5x9Ith7hURdIl0wBIhpCAjKIIxaAUPQ0hFQsAC7MJALFSFi4SgC4wyHyuCYNWxH3AuhSEotkNGAALAPqqkigG8MWAjAnM4A8594vPUyIAIfkEBQcADwAsAAAAABAAEAAABF3wySkDvdKsddg+APYIWrcg2DIRQAcU6DJICjIsjBEETLEEBYLqYSDdJoCGiHgZwG4LQCCRECEIBAdoF5hdEIWwgBJqDs7DgcKyRHZl3uUwuhm2AbNNW+LV7yd+FxEAIfkEBQcACAAsAAAAABAADgAABEYQyYmMoVgeWQrP3NYhBCgZBdAFRUkdBIAUguVVo1ZsWFcEGB5GMBkEjiCBL2a5ZAi+m2SAURExwKqPiuCafBkvBSCcmiYRACH5BAUHAA4ALAAAAAAQABAAAARs0MnpAKDYrbSWMp0xZIvBKYrXjNmADOhAKBiQDF5gGcICNAyJTwFYTBaDQ0HAkgwSmAUj0OkMrkZM4HBgKK7YTKDRICAo2clAEIheKc9CISjEVTuEQrJASGcSBQcSUFEUDQUXJBgDBW0Zj34RACH5BAUHAA8ALAAAAAAQABAAAARf8Mn5xqBYgrVC4EEmBcOSfAEjSopJMglmcQlgBYjE5NJgZwjCAbO4YBAJjpIjSiAQh5ayyRAIDKvJIbnIagoFRFdkQDQKC0RBsCIUFAWsT7RwG410R8HiiK0WBwJjFBEAIfkEBQcADgAsAQABAA8ADwAABFrQybEWADXJLUHHAMJxIDAgnrOo2+AOibEMh1LN62gIxphzitRoCDAYNcNN6FBLShao4WzwHDQKvVGhoFAwGgtFgQHENhoB7nCwHRAIC0EyUcC8Zw1ha3NIRgAAIfkEBQcADwAsAAAAABAAEAAABGDwyfnWoljaNYYFV+Zx3hCEGEcuypBtMJBISpClAWLfWODymIFiCJwMDMiZBNAAYFqUAaNQ2E0YBIXGURAMCo1AAsFYBBoIScBJEwgSVcmP0li4FwcHz+FpCCQMPCFINxEAIfkEBQcADgAsAAABABAADwAABFzQyemWXYNqaSXY2vVtw3UNmROM4JQowKKlFOsgRI6ASQ8IhSADFAjAMIMAgSYJtByxyQIhcEoaBcSiwegpDgvAwSBJ0AIHBoCQqIAEi/TCIAABGhLG8MbcKBQgEQAh+QQFBwAPACwAAAEAEAAPAAAEXfDJSd+qeK5RB8fDRRWFspyotAAfQBbfNLCVUSSdKDV89gDAwcFBIBgywMRnkWBgcJUDKSZRIKAPQcGwYByAAYTEEJAAJIGbATEQ+B4ExmK9CDhBd8ThdHw/AmUYEQAh+QQFBwAPACwAAAEADwAPAAAEXvBJQIa8+ILSspdHkXxS9wxF4Q3L2aTBeC0sFjhAtuyLIjAMhYc2GBgaSKGuyNoBDp7czFAgeBIKwC6kWCAMxUSAFjtNCAAFGGF5tCQLAaJnWCTqHoREvQuQJAkyGBEAOw==) no-repeat center center; *background-image: url(/assets/css/global/assets/img/spinner.gif);}\n\n.g-border {border: 1px solid #e0e0e0;}\n.g-border-left {border-left: 1px solid #e0e0e0;}\n.g-border-right {border-right: 1px solid #e0e0e0;}\n.g-border-top {border-top: 1px solid #e0e0e0;}\n.g-border-bottom {border-bottom: 1px solid #e0e0e0;}\n\n.g-orange {color: #FF5500;}\n\n.g-bold {font-weight: bold;}\n.g-small {font-size: 80%;}\n\n.g-button {background-color: #E5E5E5; border: 1px solid #CCC; border-radius: 1em; color: #333 !important; cursor: pointer; display: inline-block; font-size: 11px !important; height: 17px; line-height: 17px !important; margin: 0; overflow: visible; padding: 0 10px !important; text-align: center; position: relative; white-space: nowrap; -webkit-background-clip: padding-box; -moz-background-clip: padding; background-clip: padding-box; -webkit-user-select: none; -moz-user-select: none; user-select: none; -webkit-transition: border-color .2s linear, color .2s linear, -webkit-box-shadow .3s linear; -moz-transition: border-color .2s linear, color .2s linear, -moz-box-shadow .3s linear; transition: border-color .2s linear, color .2s linear, box-shadow .3s linear;}\n.g-button {background-image: -webkit-linear-gradient(top, #FFF, #E5E5E5);}\n.g-button {background-image: -moz-linear-gradient(top, #FFF, #E5E5E5);}\n.g-button {background-image: linear-gradient(top, #FFF, #E5E5E5);}\n.g-button:visited {color: #333333;}\n.g-button:hover {border-color: #B3B3B3; color: #111; -webkit-box-shadow: 0 0 4px rgba(0, 0, 0, 0.2); -moz-box-shadow: 0 0 4px rgba(0, 0, 0, 0.2); box-shadow: 0 0 4px rgba(0, 0, 0, 0.2);}\n.g-button:active {background-color: #FFF; border: 1px solid #CCC; -webkit-box-shadow: none; -moz-box-shadow: none; box-shadow: none; -webkit-transition: none; -moz-transition: none; transition: none;}\n.g-button:active {background-image: -webkit-linear-gradient(top, #F5F5F5, #FFF);}\n.g-button:active {background-image: -moz-linear-gradient(top, #F5F5F5, #FFF);}\n.g-button:active {background-image: linear-gradient(top, #F5F5F5, #FFF);}\n.g-button-selected {background: <MAIN_COLOR> !important; color: <MAIN_CONTRAST_COLOR> !important; border-color: rgba(0, 0, 0, 0.1) !important; -webkit-transition: -webkit-box-shadow .2s linear; -moz-transition: -moz-box-shadow .2s linear; transition: box-shadow .2s linear;}\n.g-button-selected,\n.g-button-selected:hover {-webkit-box-shadow: inset 0 0 4px rgba(0, 0, 0, 0.2); -moz-box-shadow: inset 0 0 4px rgba(0, 0, 0, 0.2); box-shadow: inset 0 0 4px rgba(0, 0, 0, 0.2);}\n\n.g-label {cursor: pointer;}\n\n.g-close-button {position: absolute; width: 15px; height: 14px; cursor: pointer; background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA4AAAAPCAYAAADUFP50AAABMklEQVR42m2SMWqEQBSGbeceC4GU2YVcYSFNmvQLARUtYm3jGURYrWKjspI24Ak8gDfQQm8QgpJk8n6ZJzIq/MzM+//P8Y1jSCk3Mk1TkI5KYi+jA3ekG2kkSaURNXg6yNDZsqwvBnQp78x5hg62bY+O48g8zzdQFEXziAyyC+h5XgUjy7JfWl/rul4gzOn5DMNwXiM7g2iedvpZ7XAh4wIAwpxqb+yrrDCCIHjgog7rEMv3/ZNRluWzbqRp+s6HUBRFrvvEvBh9359c19V7esVO689mH9lhGB7xVhHH8dwjjZueGObTRhYMQKPrumq1a7XT85X+4x8yyK4vwKFpmpHhPcFDBlkGWU/U73eSJDjyBcAcNXjI6FeOdU/6mKZpbNtWQpijpjxDB3UJ0lFJ7GX+AQ46GnARWZt2AAAAAElFTkSuQmCC) no-repeat 0 0; text-indent: -9999px; *background-image: url(/assets/css/global/assets/img/close-button.png);}\n\n.g-scrollBar {position: absolute; top: 0; right: 1px; height: 100%; width: 7px; opacity: 0; -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";}\n.g-scrollBar.g-scrollBar__visible {opacity: 1; -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=100)";}\n.g-scrollBar__thumbClass {background: #000; cursor: pointer; width: 100%; height: 0; margin-left: -1px; opacity: 0.3; -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=30)"; -moz-border-radius: 4px; -webkit-border-radius: 4px; -o-border-radius: 4px; -ms-border-radius: 4px; border-radius: 4px;}\n.g-scrollBar__thumbHoverClass {opacity: 0.6; -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=60)";}\n.g-scrollBar,\n.g-scrollBar__thumbClass {-webkit-transition: opacity 0.3s linear; -moz-transition: opacity 0.3s linear; -o-transition: opacity 0.3s linear; -ms-transition: opacity 0.3s linear; transition: opacity 0.3s linear;}\n\n.g-bg-trackpanel {background: #f6f6f6;}\n\n.g-all-transition {-webkit-transition: all 0.3s ease-in-out; -moz-transition: all 0.3s ease-in-out; -o-transition: all 0.3s ease-in-out; -ms-transition: all 0.3s ease-in-out; transition: all 0.3s ease-in-out;}\n.g-all-transition__medium {-webkit-transition: all 0.2s linear; -moz-transition: all 0.2s linear; -o-transition: all 0.2s linear; -ms-transition: all 0.2s linear; transition: all 0.2s linear;}\n.g-all-transition__fast {-webkit-transition: all 0.1s linear; -moz-transition: all 0.1s linear; -o-transition: all 0.1s linear; -ms-transition: all 0.1s linear; transition: all 0.1s linear;}\n.g-all-transition__slow {-webkit-transition: all 0.5s ease-in-out; -moz-transition: all 0.5s ease-in-out; -o-transition: all 0.5s ease-in-out; -ms-transition: all 0.5s ease-in-out; transition: all 0.5s ease-in-out;}\n.g-top-transition {-webkit-transition: top 0.2s ease-in-out; -moz-transition: top 0.2s ease-in-out; -ms-transition: top 0.2s ease-in-out; transition: top 0.2s ease-in-out;}\n.g-opacity-transition {-webkit-transition: opacity 0.2s linear; -moz-transition: opacity 0.2s linear; -o-transition: opacity 0.2s linear; -ms-transition: opacity 0.2s linear; transition: opacity 0.2s linear;}\n.g-no-transition {-webkit-transition: none; -moz-transition: none; -o-transition: none; -ms-transition: none; transition: none;}\n.g-transition-delay {-webkit-transition-delay: 0.3s; -moz-transition-delay: 0.3s; -o-transition-delay: 0.3s; -ms-transition-delay: 0.3s; transition-delay: 0.3s;}\n\n.g-transform-3d {-webkit-transform-style: preserve-3d; -moz-transform-style: preserve-3d; -o-transform-style: preserve-3d; -ms-transform-style: preserve-3d; transform-style: preserve-3d;}\n.g-transform-origin__right {-webkit-transform-origin: right center; -moz-transform-origin: right center; -o-transform-origin: right center; -ms-transform-origin: right center; transform-origin: right center;}\n\n.g-selection::-webkit-selection {background: <MAIN_COLOR>; color: <MAIN_CONTRAST_COLOR>;}\n.g-selection::-moz-selection {background: <MAIN_COLOR>; color: <MAIN_CONTRAST_COLOR>;}\n.g-selection::selection {background: <MAIN_COLOR>; color: <MAIN_CONTRAST_COLOR>;}\n.g-selection-text {-webkit-user-select: text; -khtml-user-select: text; -moz-user-select: text; -o-user-select: text; user-select: text;}\n.g-selection-disabled {-webkit-user-select: none; -khtml-user-select: none; -moz-user-select: none; -o-user-select: none; user-select: none;}\n\n.g-shadow-top {-webkit-box-shadow: inset 0 1px 0 rgba(255,255,255,0.5);}\n.g-shadow-bottom {-webkit-box-shadow: 0 1px 0 rgba(255,255,255,0.5);}\n\n#sm2-container {position: absolute; width: 1px; height: 1px; overflow: hidden;}\n#sm2-container embed {width: 48px; height: 48px; max-width: 48px; max-height: 48px;}\n#sm2-container.swf_timedout {width: 48px; height: 48px;}\n#sm2-container.swf_timedout,\n#sm2-container.swf_timedout embed {min-width: 48px; min-height: 48px;}\n#sm2-container.swf_unblocked {width: 1px; height: 1px;}\n#sm2-container.swf_loaded embed,\n#sm2-container.swf_unblocked embed {left: -9999em; top: -9999em;}\n#soundmanager-debug,\n#soundmanager-debug-toggle {display: none;}\n\n.g-share-icon {display: inline-block; width: 11px; height: 11px; cursor: pointer; background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAKCAAAAABHm/tfAAAAAnRSTlMA70YmMtEAAABeSURBVAgdJcGhAYAgFATQ2+kK/Q/gFgzgEDTbL0S6O7gAA9As9Iu/ivoe9MvcBX0ukgNa5pFIE+aeS7LWzzvgJKtiERqZfOoF1eJm3usQYpEbaROSIqKTHNAnjq3GA66XS9zEOQukAAAAAElFTkSuQmCC) no-repeat 0 0; text-indent: -9999px; vertical-align: middle; margin-top: -3px; *background-image: url(/assets/css/global/assets/img/share-action-icon-small.png);}\n\n.g-soundcloud-logo {display: block; width: 95px; height: 12px; background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAF8AAAAMCAYAAAAEVmGsAAAEJUlEQVR42u2WS2sTURTHL4gguOpH0IVfIB9AhOjCrRRcKOgm4F7sUnDVnSC4SO0T0ldK6St9mbakL9qUtIWUhj6YLjTYQk0ktkmahGT8/4dz5TImOmJd6cCPMzPnnnvP+c+dM6OCweB/PLCysuKwtramRkdHHbu6uuowNzfn2OXlZd7nuIfz8/MdBOcPxsfHVTwe1zjjYrGY+udFvUTx70LUp7h/q6urq4YYWwPxDyB6UyPxAyArgxOgGZg+S3xR4JP7fmCLVUSuW4Ci1X7z2hWrCet5hSbAw5a8Whut6YoJ6xidhxAVlOdcvIt/G+IXFhcXC6FQqDozM/MZ4jtzmYyNjVkcD78yxffRubW1VUin0/bU1FQ2GkWeRmKJRCJD3+DgYK69vT0tybygjxZ8Fx+JTAFFy+uOjo5P9OlrjtWx29vbNuedmJj42NbWlhMBFdaIIe7Csiwnr56eni/M072mXlfH9Pf3Z3WMFB0YGRlRICMwD8+5/EL8G5xvc3PzLBwOV5eWlsq9vb01zF3R4ruB+PdN8TnJIzqGh4eTEP51Pp8ftW07MDAwoEAE920cLcB/fHyc0jvPq/hIqEwR6hWcTCbfcV6uKWOfwN7k+e7ubh6+ZlnbAr66axKJ2dvbs3QMNpDd19eXqie+11yAIhynYVuB+CXYc8z3AQ/6YmhoqOZF/EgkYkH892xPjvgsCk+dO7RkDAxgQgXSWCiHMUrw6eK9in9wcHCCXZmfnp6OuQumlXmbeD05ORkCj2UnvhYf53VsvTUxXumYjY2NVxLDdpCk4I3E95iLAqb4D3d2dnLQpLq+vl6i9Sq+G4j/UhfWArKnp6d8Oo4TO0eBNFsNxwhu8Sn2K91z64nPnYhXuYyHW6xXsN65Il4ID8sRkm+hq5//GCcwxsyF8E02xTfr4EbwkgtQhFoIFxC/cBniI6esFtQCAfwaPWOi6J32/v6+AhHjI+rv7OxM0YfDT3iOfmzRB3G7Ofbw8PCNS3yVyWRW+AfgKpgfoXewzXgzdqS9NYOb3AB8W+iTtXXPN+P8gk9idC46hr0/BRStroN+bgQI6SUXRViPULks8WdnZ88UPjJ3FhYWclKs81E9OTlJy8L+VCpld3d3Z+jDYqZP8RwfG8ax8BzHsjW5xac4/Ai6xdfgoZ8Wi8VtPW+hUIghuRJ9yKuA/lo0e74Bc4vrGP4s6Bi2UhwB+mjxi+fcl8JL7O0ecvlb4nNzx50eB4IgC3gkgA8oIQAs8UVdPp4nxGfpYoUWYDe49gPzCEoeish5WHxZ0Fo3TnJqEMP1lEGrUWOY4z3k4ubt0dHReT3x8REt4wNfw8P7qfjoHmxpF1yXE/7n97gHitVq9WulUqHNwZZgz8o4YM9rtVoFY6oNOATPgfrXhfwTroJrLntd7BUvc3wDRLX3Tpb2AXIAAAAASUVORK5CYII=) no-repeat 0 0; text-indent: -9999px; *background-image: url(/assets/css/global/assets/img/sc-logo-with-name.png);}\n\n.singleTrack {position: relative; height: 100%; background: #F5F5F5; overflow: hidden;}\n.singleTrack__artworkContainer {position: absolute; -webkit-box-sizing: border-box; -moz-box-sizing: border-box; box-sizing: border-box; width: 165px; height: 165px; padding: 7px 8px 8px 7px; top: 0; left: 0; display: none; overflow: hidden; border-right: 1px solid #dcdcdc; -webkit-box-shadow: inset -5px 0 5px -5px rgba(0,0,0,0.15); -moz-box-shadow: inset -5px 0 5px -5px rgba(0,0,0,0.15); box-shadow: inset -5px 0 5px -5px rgba(0,0,0,0.15);}\n.singleTrack__content,\n.singleTrack__sharePanelContainer {position: absolute; top: 7px; right: 7px; bottom: 7px; left: 7px;}\n.singleTrack__upperPart {position: relative; height: 49px;}\n.singleTrack__buttonContainerWrapper {width: 44px; height: 100%; float: left; margin-right: -44px; position: relative;}\n.singleTrack__buttonContainer {height: 34px; width: 34px; margin-top: 5px; margin-left: 2px;}\n.singleTrack__upperMainContent {height: 100%; margin-left: 48px; position: relative;}\n.singleTrack__titleContainer {padding: 9px 50px 0 0;}\n.singleTrack__buttons {position: absolute; top: 0px; right: 3px;}\n.singleTrack__favButton,\n .singleTrack__buyButton,\n .singleTrack__downloadButton {float: right; margin: 0 0 0 5px; outline: none;}\n.singleTrack__favButton {width: 43px;}\n.singleTrack__favButton span {background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAeCAYAAAD6t+QOAAABcElEQVR42u2TsUrDUBSGrxS0k7o7ikigoJikDSkdXVKKFgpOFR9AEeli8EnyAoWscSyNZGiTrUt3HRQEpdBiNSWQ6zkhB2JMQwdHf/g5uf/5yAnhHsY5Z6IoroPb4AvwFmZY43ML+5hFsCzLDxBwNDw/QT2UJOk1kd1HMDYoJFcqlXesKe+zTqdzRUGedV0/Y4PB4LxWq+WCjUaDz+fzKn7zjmVZX8tAVVX5aDR6Aa6AMLrd7XZ/gYqicMdxFtAv098gX5um+QPs9/sB5HViCCRf0oRer4dgE/NMmCZ4nsdBLcryYPQx1lVh9g//KUxaA2/HLmCANT5vRn2SIAh7w+Hw1nXdO7i7RxAVNU2T8Gzb9k2pVNoltjidTj0ey/f9Z8MwToMgeKNsMpnYwG0wuNhVnhKBSY3H4wM2m81OeL7oBWq0VmEYfuSB0H+M1gqFa5XDfoLLLCm89BngAlxnWcK1SoHNNLNsQoutIlyrrPwbHIUdibO9gYAAAAAASUVORK5CYII=) no-repeat 0 0; padding: 0 0 0 15px; background-position: 0 2px; text-shadow: 0 1px 0 rgba(255, 255, 255, 0.6); *background-image: url(/single-track/assets/img/button-favorites.png);}\n.singleTrack__favButtonActive.singleTrack__highlighting span {background-position: 0 -18px; text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.2);}\n.singleTrack__like,\n .singleTrack__favButtonActive .singleTrack__liked {display: inline;}\n.singleTrack__liked,\n .singleTrack__favButtonActive .singleTrack__like {display: none;}\n.singleTrack__shareLink {position: absolute; bottom: 0; right: 0; padding: 7px 0; font-size: 11px; color: #333; text-decoration: none; outline: none;}\n.singleTrack__shareLink:hover {color: #000;}\n.singleTrack__mainContent {position: absolute; top: 50px; left: 0; right: 0; bottom: 0;}\n.singleTrack__middleContent {height: 64px; margin: 4px 0 6px; position: relative; overflow: hidden;}\n.singleTrack__lowerPart {top: 2px; height: 21px; left: 0; position: relative; width: 100%;}\n.singleTrack__statsContainer {position: absolute; left: 0; bottom: 0;}\n.singleTrack__permalink {position: absolute; bottom: 0; right: 0; outline: none; opacity: 0.7;}\n.singleTrack__permalink:hover {opacity: 1;}\n.singleTrack__waveformContainer,\n.singleTrack__timeIndicatorContainer,\n.singleTrack__timelineCommentsContainer,\n.singleTrack__commentDetailsContainer,\n.singleTrack__scrubberContainer {position: absolute; top: 0; left: 0; width: 100%; height: 100%;}\n.singleTrack__sharePanelContainerWrapper {position: absolute; top: 100%; right: 0; bottom: 0; left: 0; z-index: 10; background: #f6f6f6;}\n.singleTrack__sharePanelState .singleTrack__sharePanelContainerWrapper {top: 0;}\n.singleTrack__waveformHighlightedState .singleTrack__mainContent {cursor: pointer;}\n.singleTrack__waveformHighlightedState .singleTrack__waveformContainer {cursor: pointer; opacity: 0.7;}\n.singleTrack__artworkMode .singleTrack__artworkContainer {display: block;}\n.singleTrack__artworkMode .singleTrack__content {left: 174px;}\n.singleTrack__artworkMode .singleTrack__sharePanelContainerWrapper {left: 167px;}\n@media (max-width: 50px) and (max-height: 50px) {.singleTrack__artworkMode .singleTrack__artworkContainer {display: none;}}\n@media (max-width: 100px) and (max-height: 100px) {.singleTrack__artworkMode .singleTrack__artworkContainer {width: 100%; height: 100%; border: none; -webkit-box-shadow: none; -moz-box-shadow: none; box-shadow: none;}.singleTrack__content,\n .singleTrack__artworkMode .singleTrack__content {top: 0; left: 0; right: 0; bottom: 0; padding: 0;}.singleTrack__upperPart {width: 100%; height: 100%; position: absolute; top: 0; left: 0;}.singleTrack__buttonContainerWrapper {width: 34px; height: 34px; float: none; margin: -17px 0 0 -17px; left: 50%; top: 50%;}.singleTrack__buttonContainer {margin: 0;}.singleTrack__artworkMode .singleTrack__buttonContainerWrapper {opacity: 0.95;}.singleTrack__upperMainContent,\n .singleTrack__sharePanelContainerWrapper {display: none;}.singleTrack__mainContent {visibility: hidden;}}\n@media (min-width: 61px) and (max-height: 60px) {.singleTrack__artworkMode .singleTrack__buttons,\n .singleTrack__artworkMode .singleTrack__artworkContainer,\n .singleTrack__shareLink,\n .singleTrack__mainContent,\n .singleTrack__sharePanelContainerWrapper {display: none;}.singleTrack__artworkMode .singleTrack__content {left: 7px;},\n .singleTrack__titleContainer {padding-right: 7px;}}\n@media (min-width: 351px) and (max-width: 435px) {.singleTrack__artworkMode .singleTrack__buttons a {display: none;}.singleTrack__artworkMode .singleTrack__buttons a:last-child {display: block;}}\n@media (min-width: 351px) and (max-width: 400px) {.singleTrack__artworkMode .singleTrack__buttons,\n .singleTrack__artworkMode .commentDetails__buttonsVisibleState .placeholder__label {display: none;}.singleTrack__artworkMode .singleTrack__permalink {width: 20px; background-position: right 0;}}\n@media (max-width: 350px) and (min-height: 166px) {.singleTrack__artworkMode .singleTrack__artworkContainer {display: none;}.singleTrack__artworkMode .singleTrack__content {left: 7px;}.singleTrack__artworkMode .singleTrack__sharePanelContainerWrapper {left: 0;}}\n@media (max-width: 250px) and (min-height: 166px) {.singleTrack__buttons,\n .singleTrack__shareLink,\n .commentDetails__buttonsVisibleState .placeholder__label {display: none;}.singleTrack__titleContainer {padding-right: 0;}.singleTrack__permalink {width: 20px; background-position: right 0;}}\n\n.playerButton {width: 100%; height: 100%; position: relative;}\n.playerButton__control {position: absolute; width: 100%; height: 100%; -moz-background-size: 100% 100%; -o-background-size: 100% 100%; -webkit-background-size: 100% 100%; background-size: 100% 100%; background-position: center center; top: 50%; left: 50%; margin: -50% 0 0 -50%; display: block; text-indent: -9999px; cursor: pointer;}\n.playerButton__playControl {display: block; background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACIAAAAiCAYAAAA6RwvCAAAHZUlEQVR42rWWCzSUaRjHhzEYGUNmQmypNkIdXbdcairb6SzaTknrUh1UUmamrbNbm/ak45rlCKVDOSEMg2FCqbVyrbXRqdwvhcklFXUqt67fPq99nZkdvkS77zn/c/i+1/f8PP/ned6XMpnV09Oj+uTJE+Nnz57Z9fb2OvX19Xk/f/6c/+LFCyQeyAl+t4fnJvCeTvmvV3d390yA2Chpb+eVlxTtuZwhtLsizrLKECSZCJMTjLLSUuanXYpfcOVylpU4Q2hbVnxjd1vrQz5A2z9+/Hj2FwN0dXVpA8S6utoabm525iYU9M7tilmNdbUGz/t69QYHBnQJgtBBQj+jZ+gd2jMCKEy1vXunitvR0WHT3t4+Y6oQi9rb2/g5WRkO4vRUIxRAGniMZsgL9uo01NboZwsF8wBoa11dLa+lpWXJZCEs6uEPIfVW1XfvfIUByIKz5cTCYiMN9PfPuFt5W1+QeHFleWkJt76+3vpzIVZV/lXBTU9JNG972KKPIMiC44DaWNPHFX7fIWnXSYmPM8nPy/W6d++e5YR2NNTX8TIFSYu7uzpnkmZACqAF0sRigjTkxJR5ryVpfchOvnjepOD6NW5lZeUSMgjGI4mEn5FyyQplYjyA169fs5ubm9mNjY0saFVNaFUUiAGahqUmK5nn6qNgdTX32XHRZ5YV3bjBu3nzps4YEGiz1VdzxM7SmhiTBW0EEB8frxsTEzM7MjKSnZ6ezqyqqkIBVbCU5aSCpSoDxigpLGDHno3cVFJSskEegt3c1MjLzkg1QS0oCyFrQ3V1tZaPj48eDKszALWfw+HM8PDwYERFRakAEA32UOWkhEVDYBiIDjEYMVHhBpnpQm5BQYF0zsDgWZ8nFm1FLUoCgTzWgOAMT09PFhSbFwHr6dOnKS4uLnOMjY0Zpqamyr6+vorwWEFOilhUWaCC/DzN8JAgm/z8fPtRCFpnRwdflJpsKmcJWwaCAVKDwUR3dXXVcHBwMP7w4cMwghkaGmpKTEzkwKeYIGWQomy2x0BhoM5HElV/nyN6wrQ0rlgsVqfAuWEEI9nzz7KS2eNAaOEiG60DmqOjI53FYulAsRYTeAHUAGTpMMTVBtFBVJCCfB3Kw4QFnGRGhP22UyQSLaKA35zrV3Id5GxhyUBMw96O1ADUhRKTydSqqanxJeQWWCWytbVFnquDaGQwWNT42Gj6yeNHOUKh0J4CJ6UjnCMcPDfkLVGXhQApoDpAgQICAizlQT5+/EgMDg62Jicnr4M9DJDSp2CESfG0H732GAkEAjcKzAKPLKFgKa4P+Wyo4eJSwikd/SgdZNDf318NwZE1xPv374l3794Rw8PDxMDAwBDMm8MyNlHIbLLjWLCTkpJ4FPDaC45uM3RIkWdDCiEDog9tn4eDo0wQAEa8evWKePPmDYEWnNwOo1khg1m7bKFWXNyFf0Cy0gQLMQgLNH28bFDwwh+dBpoFIGWjweE7BNhMvH37Flk0JJFIPGGPKs4I6VphNFvz/PnYERC3y5nCZX29z3RlbGGA6NLakGYDf5i5fPlyUwg8DF1HABAq1FGLOktLS1E7q5FmAy9jXU2F9d+Ys2NjY71RjTjkiDLWQV/rjmOL0ji20EDstLS0fTBXiNbW1hEIPFNuBQcHz8XWSSHIQRR3bNtsHB0dvQN1zer83MuO6M6AbWHillUZxxYKTrdeeXl5akNDw4glaME/dN7MzGw6vFMZM0fIQWgH9rivhSNiI5ojhjdLS/YX/X5tlhQE18dYWxTwjDCAOdIF3TFSD5AVb9yueLJiiIlB6D8fOrgrPDzchAJppcIVgJeacHHR054elmyhktQHIyIiwgoVJaqHioqKDbh4aRhi4oXrw3qxKevUqWBuaGio6ugt3QIOPaeyoj/0PgOEDvCHAaQ8JSVlPnk9TGyLp9tOG4CQXgU6OzvVW1qa+TByTbs7O7QmsIb28uVLZx6Pp4GtoE4BQmGl2dfaJ349fgCK+9+Xo7a2NguxKGNXXlamDrSyOkmxKuD0U7EUpwIBUvXa7bYZINaM2fDgwQNqU1MT/2JM9Lf5OdnTyacqBprKwpY4bdm0NDAwkOfv788YdxO0o2FVVSU/KvTUshxRugbJQKN8AYSS3XrrOSd9T3ABYsEnN8N10LyosJAX4udrfuFsBKP2/l2SrEzaDpq9zZq5x44eOQAQKz7rD+H+ubistJQf4u/L+enAXg10XE8JBE9PEN156/crcCaWT+oDt27dmlsKMLHRZ1z2u7vO+sF+A/3gXjfqJAGU164w1/X23LMN7i+oJoymlNLi4mKFwsJCi9ycHF5IoN/W3S7b564ynceAACrIbxRMTkooOGjadxwLg33uu+wD/P24QUFBln5+fspfXGRXr15Vy83NXZWdne0RfSZq34ljR7Yc8vay3rvTeaHTZjtDB9sNhu4u2828PHZZ8vd7bj7+y5F9YWFhe0NCQtZAd2hR/o8Fp64eXO0s4FZll5CQ4BQXF+cOx7jHuXPnnODwsj99+rQlQOhP9rt/A5je+3nNGl1eAAAAAElFTkSuQmCC); *background-image: url(/player-button/assets/img/play-button.png);}\n.playerButton__playingState .playerButton__playControl {display: none;}\n.playerButton__pauseControl {display: none; background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACIAAAAiCAYAAAA6RwvCAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAABwdJREFUWMOtmFlPW0cUgH2vr23AK96wwRjjmM1bTIEGEEkaVZGqqA99SZ/60B+RPERR8p7HPvelylOkSlXUKpEqkoomLClx2AwYs5vNxsY2eN/uvT1DfdHF+IIpGelo7AMz8805Z86cMca7RAsGgzUYhrXgOG6BXgqiAuGDoD/TIGGappMgayCbarU6U+3cWDX/tLe31wiLO3LZbPu2fyMTCYUChEBwmE6nohRFkgJCQOfzeb5ULlcV8gW5SqPRG4wt4jqxZJ2iKI9er/dfCWR3dxft2BmLRmzrKz5/OpX0Wdo7s2KxhNLqdGRNTS1dW1eHLMHLpNNYNpvBQsEgP5VK4qvLSzUCgcjSamkzq7UNXpIkPSaTKXRpEIBwFAr5O3NT7l2qWPR02hxpo6m1yCxc1s7oEJh/Y51YWvDU0Dzseofd0SQUikbb2tqmqwYBiIGjw1jvwuz0VEeXdQusUKgAQHNA0Oy506kUtuxdFHgX5w3G1mt9SrVmxmq1jl4IAhD9ezvbvRurvvd9/YMHDbpGkgVRqecCOrXGzpafePfXG6VS03Bbb2iec7lc45wgyB3xo8OvFmam3g/evhPSNzaRHBZghOKAYs/PrIFtgavej7xVNzQZv1YoVWN9fX0nbsJZEFKyWLwzP/1pqudGf5gFUb4wWZIi63Oh9L2SMH8jja3mfHffjQP/6spEMpEYGhsba2DWJ06IcNw1Ozsd7rDatpA7yq2wtraGbW5u4tvb20Q4HOaJRCISAi8XCAR4oOPHYjEc9JhEIqF6enoK7e3tFJwSHghdsgraNGa1O6mDUGhradHT2OlwOUE3fAICk2kS8SNXLpd5A+efORkMxLH5fT6f4NWrV8KNjQ0RWhSOdUGlUkHeokkAFKXTaWEqleJDK05MTCQBJnPv3j0EQ5VAqBIM5XB1Z70LnunwfvC74eHh5bt37/qJkjUcy96F3S6rI1GvVFHlEMisACCQy+Wa169fu9lBYDabdUNDQ9rnz5/PsvU6nU4CgMX79+9TrHg5tg6sQV9ra0965ua8XVKZA3R+fH9/X1DI5+25TGYJ5Ymy4KSZOIAYIuPx+JkjAeMhgaWISvqRkRGMI77ILpsjmzo6XIwfHZlevnwpAWPgrRtrK9lGQ3OK5RJmICPkzs4OlcmcvTrAJVgul8O4ji24kGaEPXdTsxGlhXRgZ+sIsm4r8rUekk4EzFV+VNk7oKLRKAX3CcW7QmPBHG8Q7qT8YSyyVSwWWxCINp/PHcgUCqrsqJ6CgZv3yiAsmOP4q6urKx5GIgGwiBqBSCFGEgpFPVVmDbbQEB807zM1Bub7H34kV7wLMQCRIhAhjvNzHNZgrIRcQ8OA4wngyPLgej9783Hoz3NTKpko5nLZ/zIrlBRY2UmhykB4kUgE5QwewPDAp7xCoXAKoJK+GphUIkEjeASS5RN8USaTxiqkdLYcLwhxwoNTwstms8ffz9Nf1Dp0CkyqUAiQIXEYlMAwXAb1w7kQqKFdw3E9EaahHVXSV2OURqNJCZY8QiAhgVCoDkMC4gJggguBoB2j3SMXMDvn0lfR+DKFUg/jwwhkWyZXqA9jUX6FrHoKCO2ciQPUX6SvohFiqcwIY7ZwmGTbdM1CBPf25GAV/JwCh4KbNccsxlqQrK2traSnL4oPja5RrGrQycAiG4RWqyWhSndLFXKbzzt/oGloyHOMLTqdzjRccuX6rN1uT1bQF0unjtMaVlfPdT6f8D18+DCLl0zr6bA5tKvLvvrA7g6fC+TJkydBuObFIPKSiFGd/OzZs0AFfYHLKsgaCpVapjMYO8CCcycVmsFgSBKE4GO9Wts7NfmPMBo5wFllHvtYo3SPkl+mJDlWJVauJyuBIAjoRN39Q0O1Ysn8o0eP9k+ViuCnyS67UxEK7Tsmx0eFbAgIaKzs7imUhCwTtp7isAjRPXDT2mxuQ0F6tma1WCwkuOh3Z++X1hWfr/WP334VXuY1WGUCIyxWu6HT2T0Iaw2DqxOcz4m5ubnrkXD41uTYu3dKZf36wM3bWZvTdWxm1s15WQC0DtFmczY7evu/qZNIPwLExwsfWG632wWZ9tb4329nw4G96b6BwQzclMX/AwIQyOqiLwZv2Tscrht8QvABINxVPznHx8fN4MNvvZ7Zgxn3h9FoOBTW6ZvyP/38C3kJAELf3KK0dfcN6Y0mPcTanwCxfOlHOKo5IYj7oYLrXfTM7C4vzM8szHwKw6M8zwpIdsNLIjB3dNUbzW2uZrPFhPOJKdiU++nTp/kr/SwBlXsdADlhMis8RwX7ezuhRDweTsKzEPokPNZ5MkW9WFRTIxeKajRSuUIHqQCqC9IHYzyPHz+OfZbfR9jtxYsXeoh4EyyiRJUVLFQLPbJcGj4noY+C+B88eLB7mXn/BSKOgEBl+LZEAAAAAElFTkSuQmCC); *background-image: url(/player-button/assets/img/pause-button.png);}\n.playerButton__playingState .playerButton__pauseControl {display: block;}\n.playerButton__svgContainer {position: absolute; top: 0; left: 0; width: 32px; height: 32px; padding: 0; margin: 1px 0 0 1px; display: block; cursor: pointer;}\n.playerButton__svgToggleControlBG {fill: url(\'#svg-button-gradient\') <MAIN_COLOR>;}\n.playerButton__svgToggleControlOverlay {fill: rgb(0,0,0); opacity: 0; -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";}\n.playerButton__hoverState .playerButton__svgToggleControlOverlay {opacity: 0.2; -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=20)";}\n.playerButton__vmlControl {position: absolute; display: block;}\n.playerButton__css {background: <MAIN_COLOR>; height: 100%; border-radius: 999px;}\n.playerButton__css {background: -webkit-linear-gradient(top, <MAIN_COLOR> 0%,<MAIN_COLOR_BURN> 100%);}\n\n.artwork {display: block; position: relative; height: 100%; width: 100%; cursor: pointer;}\n.artwork__flipContainer {width: 100%; height: 100%; position: absolute; left: 0;}\n.artwork__flippedState .artwork__flipContainer {left: -160px;}\n.artwork .artwork__flipFace {width: 100%; height: 100%; position: absolute;}\n.artwork__img {display: block; height: 100%; width: 100%; opacity: 0; -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";}\n.artwork__visibleState .artwork__img {opacity: 1; -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=100)";}\n.artwork__flipIndicator {-webkit-transform: translateZ(1px); position: absolute; bottom: 5px; left: 5px; display: block; width: 14px; height: 9px; background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA4AAAAJCAQAAACoRNXiAAAAn0lEQVQYV2NgYNgouSNhS/O6ipWB87QW8zO4MkgwwAHnqtL3i95NeVZ7OXVVKIPZ11IxX4S0wbvZrzZt7/Jw1LRmMGMw+Xrma51JJEza+Ousr+te7Xx0/vW5j2eBUiA4zSEeIm15P+rrhK8bv+6DSkBgG4MbWNrQ+2vQ16av65Ck66BSEHsZrIGu9GDwYwhBl0IGbl+rcEkxMAgLeCOkAIbRVlXYGtZrAAAAAElFTkSuQmCC) 0 0 no-repeat; text-indent: -9999px; *background-image: url(/artwork/assets/img/flip-indicator.png);}\n.artwork .artwork__flipBack {left: 160px;}\n.artwork__userAvatarImg {width: 100%;}\n.artwork__userInfo {position: absolute; left: 0; bottom: 0; width: 100%; height: 45px; background-color: rgba(255,255,255,0.8); text-align: center;}\n.ie8 .artwork__userInfo {background: #FFF; -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=80)";}\n.artwork__userName {display: block; margin: 6px 2px; color: #333; font-size: 11px; line-height: 13px; word-wrap: break-word;}\n.artwork__userName:hover {color: #000;}\n.artwork__userStats {font-size: 10px; margin: 0 auto;}\n.artwork__userStatsItem {border-right: 1px solid #AAA; display: inline-block; padding-right: 5px; margin-right: 5px;}\n.artwork__userStatsItemLast {border-right: none;}\n.artwork__userStatsIcon {background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB4AAAAyCAYAAABLXmvvAAADQ0lEQVR42u2Wv0scQRTHYxfwL1AwYHNgIXeeTSAQtkt1f0BAxDJ/gKXieqOipPAXqfIPnFx9IClUkATPdNqraKtyBEFPyU2+L8w4w8zsvDVbSEgefNib2ed8Zty37+6FlLIm+Ujm5+dr9XpdxkjTNKlWq7Xx8XEZo1KpJBDnC0aqMQKG/+J/Q5zkqeqzszNWSjlUsXmrWqPjPY0DJPbJj4+PgxvU+VoyNjYWXM8MolKDkrK5tpQR54aV8hixABQ1YHczYSejMwk6MXUxGutuRvPOaQWQ1MVobHWzxzwjNeGNbakmNLalBn+sxHzoZ8uhxJLj2cWCkQpK3N3djUpxX4sFIxZOcWVLFcLIfanOjci94nLkvtSRR6URuYi9xyIideS+NCIXbANhpBrBSW15wc7Fb5DHF0+AEpeMJjEB2Dx0qolyuVzKI6ZIQcJ9QWxsbGxCHs1T7TKlrz9ebCIFpSyxBn06RZSyxITeAJ2eF5tIYmJN6PRZX/6s2JcbMSfXYkZe/MT4uePlMtJiz3hvb09eXl4qKf+MC1c1hHRKs0G+qou/x0dHR/Lk5GRTb7D4e8zDbJCDFw+CKTBJnyMdbBBMgUmQmYcYBFNgkj5nifvBvjSxA166i01PT/cvLCy0IZSEEOIrrl4eoh/sA6nYAS9D4jLoWeI7MOIuiJb5WksBdbCfq6urlYC4DHqW+A6MhMRD4NoSX4EBd8F2u/1ueXn5UbyysiIPDw/fBsRD4NoSX4GBkLgPNC1xI/Tcbm9vXzUaja4Wb21tdUMbRPSBpiVuxIprFDyA+0j19p2enn7RjeTi4qIVKa5R8ADuQSlLPAyWQE9Rpzl3sZmZmeH19fXP+sRra2ufaC4gHQZLoKeo05wtroIm6Eg/OupeFZLq3NxcE8X0g4Q2NEf3KAeLE03QAdKho+5VSbyjJF1w40BzFNsoqO/q9ZGLi4s2NKcL7Zt6bSToghuHrrq3nbfT5N7gUzrXM+CLKd7k+NEnZ2dnmTxvPV7sj31xq9X6ENkIu54zEb66Ai12x67AvRYSk8C9/qlYMokUv08VE+vT513vKSeOis/Pz1XuX/Cv9qqQGxuRN861XqH3+ODg4GPk79j1fgHUqIiK1TNcdgAAAABJRU5ErkJggg==); background-repeat: no-repeat; float: left; width: 10px; height: 10px; margin: 1px 2px 0 0; *background-image: url(/artwork/assets/img/stats-icons.png);}\n.artwork__userTracksIcon {background-position: -10px -40px;}\n.artwork__userFollowersIcon {background-position: -10px -30px;}\n.artwork__transforms3d {-webkit-perspective: 600; -moz-perspective: 600; -o-perspective: 600; -ms-perspective: 600; perspective: 600;}\n.artwork__transforms3d .artwork__flipFace {-webkit-backface-visibility: hidden; -moz-backface-visibility: hidden; -o-backface-visibility: hidden; -ms-backface-visibility: hidden; backface-visibility: hidden;}\n.artwork__transforms3d.artwork__flippedState .artwork__flipContainer {left: 0; -webkit-transform: translateX(-100%) rotateY(-180deg); -moz-transform: translateX(-100%) rotateY(-180deg); -o-transform: translateX(-100%) rotateY(-180deg); -ms-transform: translateX(-100%) rotateY(-180deg); transform: translateX(-100%) rotateY(-180deg);}\n.artwork__transforms3d .artwork__flipBack {left: 0; -webkit-transform: rotateY(180deg) translateZ(1px); -moz-transform: rotateY(180deg) translateZ(1px); -o-transform: rotateY(180deg) translateZ(1px); -ms-transform: rotateY(180deg) translateZ(1px); transform: rotateY(180deg) translateZ(1px);}\n@media (max-width: 100px) and (max-height: 100px) {.artwork__flipIndicator,\n .artwork__userStats {display: none;}}\n\n.trackStats {color: #828282;}\n.trackStats__item {float: left; display: block; margin: 0 5px 0 0; padding: 0 5px 0 0; font-size: 10px; line-height: 12px; border-right: 1px solid #dcdcdc; cursor: default;}\n.trackStats__item:last-child {border-right: none; margin: 0;}\n.trackStats__icon {background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB4AAAAyCAYAAABLXmvvAAADQ0lEQVR42u2Wv0scQRTHYxfwL1AwYHNgIXeeTSAQtkt1f0BAxDJ/gKXieqOipPAXqfIPnFx9IClUkATPdNqraKtyBEFPyU2+L8w4w8zsvDVbSEgefNib2ed8Zty37+6FlLIm+Ujm5+dr9XpdxkjTNKlWq7Xx8XEZo1KpJBDnC0aqMQKG/+J/Q5zkqeqzszNWSjlUsXmrWqPjPY0DJPbJj4+PgxvU+VoyNjYWXM8MolKDkrK5tpQR54aV8hixABQ1YHczYSejMwk6MXUxGutuRvPOaQWQ1MVobHWzxzwjNeGNbakmNLalBn+sxHzoZ8uhxJLj2cWCkQpK3N3djUpxX4sFIxZOcWVLFcLIfanOjci94nLkvtSRR6URuYi9xyIideS+NCIXbANhpBrBSW15wc7Fb5DHF0+AEpeMJjEB2Dx0qolyuVzKI6ZIQcJ9QWxsbGxCHs1T7TKlrz9ebCIFpSyxBn06RZSyxITeAJ2eF5tIYmJN6PRZX/6s2JcbMSfXYkZe/MT4uePlMtJiz3hvb09eXl4qKf+MC1c1hHRKs0G+qou/x0dHR/Lk5GRTb7D4e8zDbJCDFw+CKTBJnyMdbBBMgUmQmYcYBFNgkj5nifvBvjSxA166i01PT/cvLCy0IZSEEOIrrl4eoh/sA6nYAS9D4jLoWeI7MOIuiJb5WksBdbCfq6urlYC4DHqW+A6MhMRD4NoSX4EBd8F2u/1ueXn5UbyysiIPDw/fBsRD4NoSX4GBkLgPNC1xI/Tcbm9vXzUaja4Wb21tdUMbRPSBpiVuxIprFDyA+0j19p2enn7RjeTi4qIVKa5R8ADuQSlLPAyWQE9Rpzl3sZmZmeH19fXP+sRra2ufaC4gHQZLoKeo05wtroIm6Eg/OupeFZLq3NxcE8X0g4Q2NEf3KAeLE03QAdKho+5VSbyjJF1w40BzFNsoqO/q9ZGLi4s2NKcL7Zt6bSToghuHrrq3nbfT5N7gUzrXM+CLKd7k+NEnZ2dnmTxvPV7sj31xq9X6ENkIu54zEb66Ai12x67AvRYSk8C9/qlYMokUv08VE+vT513vKSeOis/Pz1XuX/Cv9qqQGxuRN861XqH3+ODg4GPk79j1fgHUqIiK1TNcdgAAAABJRU5ErkJggg==); background-repeat: no-repeat; text-indent: -9999px; text-decoration: none; float: left; margin: 2px 3px 0 0; width: 10px; height: 10px; *background-image: url(/track-stats/assets/img/stats-icons.png);}\n.trackStats__favIcon {background-position: -10px -10px;}\n.g-list-alt-highlighted .trackStats__favIcon {background-position: -20px -10px;}\n.g-list-highlighted .trackStats__favIcon {background-position: 0 -10px;}\n.trackStats__commentIcon {background-position: -10px 0;}\n.g-list-alt-highlighted .trackStats__commentIcon {background-position: -20px 0;}\n.g-list-highlighted .trackStats__commentIcon {background-position: 0 0;}\n.trackStats__playbackIcon {background-position: -10px -20px;}\n.g-list-alt-highlighted .trackStats__playbackIcon {background-position: -20px -20px;}\n.g-list-highlighted .trackStats__playbackIcon {background-position: 0 -20px;}\n.trackStats__svgIcon {position: relative; height: 12px; width: 12px;}\n.trackStats__svgFavIcon {top: 2px; margin-right: 2px;}\n.trackStats__svgCommentIcon {top: 3px; margin-right: 3px;}\n.trackStats__svgPlaybackIcon {top: 2px; margin-right: 0px;}\n.trackStats__svgFill {fill: #828282;}\n.g-list-alt-highlighted .trackStats__svgFill,\n.g-list-highlighted .trackStats__svgFill {fill: <MAIN_CONTRAST_COLOR> !important;}\n.g-list-alt-highlighted .trackStats__item,\n.g-list-highlighted .trackStats__item {border-color: <MAIN_CONTRAST_COLOR> !important; color: <MAIN_CONTRAST_COLOR>;}\n\n.trackTitle__title,\n.trackTitle__username {white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 11px; height: 13px; line-height: 12px; color: #333;}\n.trackTitle__title {margin: 2px 0; font-weight: bold;}\n.g-list-highlighted .trackTitle__title,\n.g-list-highlighted .trackTitle__username {color: <MAIN_CONTRAST_COLOR>;}\n\n.waveform {position: relative; width: 100%; height: 100%;}\n.waveform__image {image-rendering: -webkit-optimize-contrast; -ms-interpolation-mode: nearest-neighbor;}\n.waveform__upperPart,\n.waveform__lowerPart,\n.waveform__canvas,\n.waveform__image {width: 100%; height: 100%; display: block; position: absolute; top: 0; left: 0; overflow: hidden;}\n.waveform__progressLoad,\n.waveform__progressPlay {height: 100%; width: 0;}\n.waveform__progressLoad {position: absolute; left: 0; top: 0; height: 1px; background: <MAIN_COLOR>;}\n.waveform__upperPart {background: #292929;}\n.waveform__upperPart .waveform__image {height: 200%;}\n.waveform__upperPart .waveform__progressPlay {background: linear-gradient(top, <MAIN_COLOR> 0%,<MAIN_COLOR_DARKER> 100%); filter: progid:DXImageTransform.Microsoft.gradient( startColorstr=\'<MAIN_COLOR>\', endColorstr=\'<MAIN_COLOR_DARKER>\',GradientType=0 );}\n.waveform__lowerPart {background: #a1a1a1;}\n.waveform__lowerPart .waveform__image {top: -99%; height: 200%;}\n.waveform__lowerPart .waveform__progressPlay {background: <MAIN_COLOR_LIGHTER>;}\n.player__waveformHighlightedState .waveform__lowerPart,\n.player__waveformHighlightedState .waveform__upperPart {-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=70)";}\n\n.scrubber {width: 100%; height: 100%; position: relative; top: 0; left: 0; background-color: #000; background: rgba(0, 0, 0, 0); -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";}\n.scrubber__positionIndicator {display: none; position: absolute; top: 0; left: -10px; width: 1px; height: 100%; background: <MAIN_COLOR>;}\n.scrubber__positionIndicatorVisibleState .scrubber__positionIndicator {display: block;}\n\n.timeIndicator {height: 100%; width: 100%; position: relative;}\n.timeIndicator__header {position: absolute; bottom: 0; overflow: hidden; height: 13px; -webkit-user-select: none; pointer-events: none;}\n.timeIndicator__current,\n.timeIndicator__duration {font-size: 9px; color: #2a2a2a; float: left; text-align: center; min-width: 25px; padding: 2px 2px 1px 2px; background: rgba(255, 255, 255, 0.9);}\n.ie8 .timeIndicator__current,\n.ie8 .timeIndicator__duration {background: #FFF; -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=90)";}\n.timeIndicator__initialState .timeIndicator__duration,\n.timeIndicator__current {-webkit-border-top-left-radius: 4px; -moz-border-radius-topleft: 4px; border-top-left-radius: 4px;}\n.timeIndicator__initialState .timeIndicator__current {display: none;}\n.timeIndicator__current {border-right: 1px solid <MAIN_COLOR>;}\n.timeIndicator__duration {-moz-border-radius-topright: 4px; -webkit-border-top-right-radius: 4px; border-top-right-radius: 4px;}\n\n.timelineComments {position: absolute; bottom: 0; left: 0; width: 100%; height: 100%; opacity: 0; -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";}\n.timelineComments__visibleState.timelineComments {opacity: 1; -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=100)";}\n.timelineComments__disabledState.timelineComments {opacity: 0.6 !important; -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=50)";}\n.timelineComments__list {height: 10px; width: 100%; position: absolute; top: 0; left: 0;}\n.timelineComments__item {width: 10px; height: 10px; top: 0; color: white; font-size: 11px !important; padding: 0; position: absolute !important;}\n.timelineComments__bar {position: absolute; bottom: 0; left: 0; padding-top: 500px; width: 1px; cursor: default !important; background: rgba(255, 255, 255, 0.2);}\n.ie8 .timelineComments__bar {background: transparent !important; -ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr=#33FFFFFF, endColorstr=#33FFFFFF)";}\n.timelineComments__fakeAvatar {background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAAAAACo4kLRAAAAwklEQVQYGQXBu04CURQAwDnnbiGYYIKPwtJo5/9/B71oYWE2EBEk0Y2Be5yJEQAAA8Bu3xe3AcQIrEdcPQdI4DjmMORhAySwjWyt5RYYgL9sEWoCEmhEMAAJzFDMgQSWFJZAAvO7UhbXQAIeGh4DSEBkhAQk8LPuEflyBGLE/uPYMlU/X9zfIEbT63drmej9fJ49XUqn1SEzUoTM1n5Xk/R+yowoVYgIb4a+CaoqUApf07A76bIA1atshi29egCqis9/9I5MmRrnTuUAAAAASUVORK5CYII=); background-size: 100% 100%; *background-image: url(/timeline-comments/assets/img/default_avatar_small.png);}\n.timelineComments__avatar {width: 10px; height: 10px; bottom: 0; position: absolute; outline: 0 none;}\n.timelineComments__avatarImg {display: block; width: 100%; height: 100%;}\n\n.zoomableAvatar {position: absolute; top: 0; left: 0; display: block; width: 0; height: 0; padding: 0 0 10px 0; -webkit-transition-property: width, height, left; -webkit-transition-duration: 0.15s, 0.15s, 0.25s; -moz-transition-property: width, height, left; -moz-transition-duration: 0.15s, 0.15s, 0.25s; -o-transition-property: width, height, left; -o-transition-duration: 0.15s, 0.15s, 0.25s; transition-property: width, height, left; transition-duration: 0.15s, 0.15s, 0.25s;}\n.zoomableAvatar__zoomedIn {width: 20px; height: 20px;}\n.zoomableAvatar__dragged {-webkit-transition: all 0s ease; -moz-transition: all 0s ease; -o-transition: all 0s ease; -ms-transition: all 0s ease; transition: all 0s ease;}\n@media only screen and (max-width: 180px) {.zoomableAvatar {display: none;}}\n\n.commentDetails {height: 100%; width: 100%; position: relative; background: #F5F5F5;}\n.commentDetails__closeIcon {top: 4px; right: 4px; position: absolute;}\n.commentDetails__content {overflow: hidden; font-size: 11px; top: 3px; position: relative;}\n.commentDetails__avatarImg {display: block; float: left; width: 20px; height: 20px; margin: 0 5px 0 2px;}\n.commentDetails__body {margin: 5px 25px 0 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;}\n.commentDetails__light,\n.commentDetails__timeInfo {font-size: 10px; color: #999;}\n.commentDetails__msg {white-space: nowrap; overflow: hidden; text-overflow: ellipsis;}\n.commentDetails__userName {color: <MAIN_COLOR>; font-weight: bold;}\n.commentDetails__arrow {position: absolute; width: 9px; height: 7px; top: -6px; margin-left: -4px; background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAkAAAAHCAYAAADam2dgAAAANUlEQVQYV2M4Y8zAgIyfPn36H4hRxLAqQFeITQEMwxXiUoCiEEMBkslwhQxfv379TwgTpQgA7yWo9xRv3HwAAAAASUVORK5CYII=) 0 0 no-repeat; *background-image: url(/comment-details/assets/img/current-comment-arrow.png);}\n.commentDetails__inputBlock {display: none; padding: 3px 0 0 0; z-index: 10; position: relative;}\n.commentDetails__inputWrapper {margin: 0 125px 0 22px; padding: 3px;}\n.commentDetails__input {border: none; background: transparent; width: 100%; outline: none; color: #333; -webkit-box-sizing: border-box; -moz-box-sizing: border-box; box-sizing: border-box;}\n.commentDetails__cancelButton {font-size: 11px; color: #999; line-height: 20px;}\n.commentDetails__cancelButton,\n .commentDetails__postButton {float: right; margin: 0 0 0 7px;}\n.commentDetails__composingState .commentDetails__content {display: none;}\n.commentDetails__composingState .commentDetails__inputBlock {display: block;}\n.commentDetails__button {visibility: hidden; opacity: 0; -webkit-transition: all 0.35s linear; -moz-transition: all 0.35s linear; -o-transition: all 0.35s linear; -ms-transition: all 0.35s linear; transition: all 0.35s linear;}\n.commentDetails__buttonsVisibleState .commentDetails__button {visibility: visible; opacity: 1;}\n\n.placeholder {position: relative; display: block; top: 0; left: 0;}\n.placeholder input {position: absolute; z-index: 2;}\n.placeholder__label {position: absolute; left: 2px; display: block; cursor: \'text\'; white-space: nowrap; opacity: 0.7;}\n.placeholder__enabled {display: block; z-index: 3;}\n.placeholder__focused {display: block; opacity: 0.4; z-index: 1;}\n.placeholder__disabled {display: none; z-index: 1;}\n\n.sharepanel {font-size: 11px;}\n.sharepanel__top,\n.sharepanel__bottom,\n.sharepanel__linkCode,\n.sharepanel__embedCode,\n.sharepanel__buttons {overflow: hidden; height: 24px; line-height: 24px;}\n.sharepanel__top {padding: 0 14px 5px 0;}\n.sharepanel__linkCode,\n.sharepanel__embedCode,\n.sharepanel__buttons {padding: 10px 0;}\n.sharepanel__buttonsList {overflow: hidden; height: 24px;}\n.sharepanel__buttonsListItem {float: left; width: 30%; display: block;}\n.sharepanel__tweeterWrapper {padding: 0 15px 0 5px;}\n.sharepanel__plusoneWrapper {padding: 0 0 0 5px;}\n.sharepanel__embedCodeState .sharepanel__linkCode,\n.sharepanel__embedCode {display: none;}\n.sharepanel__embedCodeState .sharepanel__embedCode,\n.sharepanel__linkCodeState .sharepanel__linkCode {display: block;}\n.sharepanel__input {padding: 2px 4px; border: 1px solid #ccc; -webkit-border-radius: 3px; -moz-border-radius: 3px; border-radius: 3px; outline: none; width: 100%; -webkit-box-sizing: border-box; -moz-box-sizing: border-box; box-sizing: border-box;}\n.sharepanel__cell {float: left;}\n.sharepanel__linkCodeWrapper {position: relative;}\n.sharepanel__linkCodeLabelCell {position: absolute;}\n.sharepanel__urlShortSpinner {display: none;}\n.sharepanel__shortUrlLoadingState .sharepanel__urlShortSpinner {display: block; position: absolute; top: 2px; left: 3px;}\n.sharepanel__shortUrlLoadingState .sharepanel__linkCodeLabelCell {display: none;}\n.sharepanel__linkCodeInputCell {margin: 0 100px 0 20px; padding: 0 63px 0 10px;}\n.sharepanel__linkCodeInputTextCell {position: absolute; top: 0; right: 113px;}\n.sharepanel__linkCodeInputLabel {vertical-align: 2px; padding-left: 3px;}\n.sharepanel__embedActionCell {position: absolute; top: 0; right: 0;}\n.sharepanel__embedCodeWrapper {position: relative;}\n.sharepanel__linkActionCell,\n .sharepanel__embedCodeLabelCell,\n .sharepanel__embedCodeInputTextCell {position: absolute;}\n.sharepanel__linkActionCell {padding-right: 10px;}\n.sharepanel__embedCodeLabelCell {top: 0; left: 65px;}\n.sharepanel__embedCodeInputCell {margin: 0 80px 0 110px;}\n.sharepanel__embedCodeInputTextCell {top: 0; right: 0;}\n.sharepanel__button {padding-top: 2px; overflow: hidden;}\n.sharepanel__tweeter {width: 100px;}\n.sharepanel__fb,\n.sharepanel__plusone {width: 89px;}\n.sharepanel__fb,\n.sharepanel__plusone,\n.sharepanel__tweeter {margin: 0 auto;}\n.sharepanel__bottom {padding: 5px 0 0 0;}\n.sharepanel__email,\n.sharepanel__icons,\n.sharepanel__iconLabel {float: left;}\n.sharepanel__iconLabel {margin: 0 7px;}\n.sharepanel__icon {float: left; margin: 3px 7px 0 0; display: inline-block; width: 17px; height: 17px; text-indent: -9999px; background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAPEAAAARCAYAAAAMj0qLAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAD3FJREFUeNrtmwlUVde9xknXem+1b70OaWIzNbUxaqw1RvPSpsTWRM3gGKegIMFY4xA1GIc6K6IgqICGFMclSkBBIcQJjANyVcBoGmYUJYLMynARkHnw6/725VwvcIF9SNr11npvr/Wtc/be/+/uey/3x3/vfc6xsRHFPygUb090Qr9XhiuL8fTZKJb9oV/jnel+6D/CTVmMp091jLgb+fCNjIfrkThlMZ4+lddPK7yBoV6v451tL2P0p4Mx7rPBGO83CBMtxDrbA2J2oLa2FmO9Y+ASnKT8GVhKI32Qsbg30qbZKIvx9KmOkfHEL9Ed2fwvKmgpl9IK4B76D7y/7WynWrQvBuGXb6G6rlH6VMcJCwszdEeqr99cY0RDkC2wxUaX6KHXZs+BYAx5axI+mL8OHy31VBbj6aO/qze5JzgWL432xlDHILz+/iFdoo9+FYB3nEnB5axypBTWKIvx9KmATIAJquOewfir/yDMCXhJal7gQLNYZ9/R+F3yh/Lu7ng8tuAEQi9lKf1oSo57ImvGf6Lmkx5oWPKkshhPH/0qABu3bkTZ9s0o9fFA6TYPGD/dAqOoG7d7ymOJpwvKj4WhsawM1UkJKPvMC6Wb1ukB+UfPDFt0uNc4F/SdvAl93/PoXCKGsfTQqzIAYVwdGAdH79O6RI8qxISxubkZ3ZEqyPUHBMD7+gMRdkCkohgrPPTaDBtrL4Gcs3hTO+0POYkTp2Os9lH00d/Vmxzu4NstgDXR39UYzKgEMqmgRrfoo7+rMZiBLQFecHAgFga/iCWHB0gtCnlR1glzRPJDiB9dcgZeJ9OVfjQ3nX9jAnjxE7pFH/0qEBctX4DiZQvE0RnFK5xxd+40FH38VxR/MlvWixfNhlGAW3sjXX6OpjIjSja56IH4J73GrsWHHmFw/jQCzr6RnUvEMJYeelUGCI/7DtO8vuqWLqXlK0Pc2NiImpoaXaJHFWK4isy6v3/3JLw2nBp/+ImbVZVVVMk/YEf9FP1dvUlOjQlxZxo1+wji0wphWbQ++rsag1PjzkD9PPw0tv59n9S8OXOkjhv+Ye6nv6sxOIXWANbgXR7eH6uO/s6sZWG/lzBrEL/nn4QeK6KUIebUuIEQt6hxRW80h69B86mtZjUdcm4VYyn6VSAuXPgh7i6ag7vieGfmZFREHENDQYE83vnIEXfmOcG4xw9VX8eidLcvHjQ1oTbjhh6If9p34kbM2PQFHNzD0fzgQTtl5BvhdjBG9lOMpYdelQGcd0fDfktkh2J/dV0DrMVtDLmiDHFDQ0MrQLPXn0RS34349idLpHjONssYepQh9hEQa4rdoiYtfm0nEJ+LOm+G6d8BcVuAf2iIly5fjTOxCVjr6g7DpTgEHzoEn92BuiDmWpcA/+2wLaLTQpCYZUDy7Yc6leyNDSf/KEE+e22H/Az2ASl4arUB3hE3lCFudH7cJAHwg/xUWCu1cYcexllIFeICkXUL509HwWx7VKcmPXzd9GvIHfY88me+hzsbVqI+N0dOpysvmn4POiD+eZ+JrrBfH4zJ64+gqanZqsrv18LB7QsZw1h66FUZYOrmk2irFfsv4kJqnjyyfi2nFAFRabAWqwpxXV2dGc7UP2zFd4+uRuETrih+aqMUz9nGPi2OHmWIVwoYvYQi5z/8A/O8qzo9K1sg5rTYUnfullr94aTdyGoXqwrxkKn+nUorzP77whKktD5ViBOyaq0q4uvrMvMa0nLkOUGmrmSVmGNUIOamFSFOyLwopktN7b6fuvoGCTIzsgaxY2AannW5CO/Im+oQL/ilFDNwZ+Xa/L7mWE2qEOfOdUSuw0hUtQD8oNG02VNzPQ3G8COoz8lBXV4OjF+EoOJSNIq2b0HF5Vh9EI9fi4krD+DdVUFoEN8XZb/hsKx//OkJ1NQ2yLYF249j3KpAGUuPKsRTPE6grUIv3ZCfg0fWd5xMlCBbi1WF2DIDFwhgS552k7o36XMprc4+y4ysDPFSZtWnW/9xv5nXeT1kPLBZ+Ja2QOwwd41ZY+xmiR9jk1Wlpaa2iqV+aIhDIlLb9alCHJtdhTOJt7HSxV2Ka3rOKPi+NZ04GSHbNZAZT58KxNzU4nqXsOYaq/GC11X02xEv9YcDKaZMdTcW6070Q1S6n6w7HbyOnutj4KMD4qaPfiHFqbNWkn1mIHKkDfLOHmjVdm/mT83xlCrEWWNexb2zX5kAFlPbjsq9qDMS3GzHMbg99lV9EI9bjdFL9mDkUn/U1jdKTVoTiLErDsAjMFrWK6pqZRtjGEuPKsR27sfQVh94RSL0Yro8avUq8c/CWqzKGEeOHDFUVVWByhq4FcZfb5Kqjrgmsy3Fc62dMVo8vUoQL7QxQer/Wusvv7M6zzcJ38IWiO1mrTSLG1XMWvyxa/Bqa0juSlvGUqoQvzZlr1VpWVcrnFZrbVqMHog5Rd65Y6eEl++9/p6x1T8irc7pdGhomIzXC/HNwm8kyMzkJ68ZMTUyDwOO5Mj3f7v0SjuIf+sqID6lA+I5P5N6cNwDKkWLp5QzsesKPKivN72A2Emt+e6muER1HHeD9sN47jSqxbSa7XUFeSiPi0HuumXItB+lD+KxyzFsni9GLNyFqpp6qwo5G4/hzjulGEuPKsTvuX0JFcm9CSvtKmMEBwcbKioqQBU/446yZz1QPjkQ9+/fh9bOc7axjzFaO71KEM+zkRtUUlpRqW8UmtcC8cQZy8wa57RYZuM9e/aYf/isU+yzjKW+L8QdZX1KL8QXMivx94AwbPbwlNdoK9LikTf0tyg7f1zWSw76yTrbWV/8yUIZT58eiLkmTso+ZwJIbPgwK2sQZxuvSoi16bQZYj2Z+MP/llKF+OzoR8weVYiNF0xr3Lr8POS6rUGmwygYT0fCeP6shPXm4B7I9/VCs8g0Mk6sjb+ze1sXxL1HL8WA9z0xaPoWufbtSF9EJ8kYxtKjCvHkDeFQEYu1dpUxgoKCDGXiMhtV3nOzVNGE/dDaNLFN69fa6FWCeJaAcX03IKZnVgvEhLOtmM00mKz1a1KF+E+Td1gVYepIWowqxNGZ96WYZbm2porCD6CssNBUF0eCrPXt3BckAVaFWFsTm3am+2PZ4b5iPf2VBJnZmKWoPFtubrG9u9Pp5hn/JWUJcdbR7cg46GpWzd3bD/c4Rj70qEJcJXaam8W67db0CUh/9QnU5uaYX68i4VvcGP47XH/qUZRdjJZtDffKkCFidUE8cpEAcxMGOW5CaUW11JBZ3rLOo1fQOdlWfK8KLzt5yFh6VCGeuD4MbeUZYroG/NnRb2R97vZTcjptLVZljICAAENxcTGoyiG7UPncVhSJbJsdFAutnedsYx9jtHZ6lSCeYdpl1g0xPTNaIB7lsLCdLCHmtNlaDPV9IdZUXl4u5RcY065PFeLTGZVShLOotFzKPzBYTq25I80lAj+X1septOZRgbiyshptxWl1RW0j+u9Kw5fXSyTQWjsz9POuF/HrddzYUt+dbp7+Y6kHR90fgpWZiKq0C2Y1Vt2T7TxKiFs8qhDX5GSjUmxqJf3qF8jf64dqMZ3OcV9rGkvsRl+zfRKpoq9MXGKSG45icyttwOO6IH7+7Y8FmG54yWGDAPW+1GszN8s65RnwlWy7a6zE/zi5y1h6VCGe4HIEbXU+wfTPbZrHl7K+71QCrqTnw1qsyhj+/v6GO3fugCrzjML9Xl5SN7kb/cZ2KZ5r7YzR4ulVgthJwLhKJ8RcQ9PjpAjx1cR0uRnEY3chHjLJp1NpEPvuN7Tr0wtxsCFZZmPushNeLg04xeaR9YysXAl3eHyuLojjMopBXb5VKtfDFF9j2N4ECfErOxPga8gwtw/1uiin0rzE5KXjEtODaf9hkvubXU6lmaEJseZRnk5fjhHptQHpE15HSr/HYBQZt1bsRldn3kL6++OR2EPA7W+61l19Owvpk99E6juv6IP4rfkY4CiAneqCO6WVHSr03LcyhrH0qEI8fm0I2qpIZPXzCVmt6vvEjTzWYlXG2Lt3ryEvLw8Us2vV6ABU9/aRKvmNp5RWZx9jtHh6lSB2EDAut4CUgHYEseUuNT0OLRAPm/xRO3Ejy9oUt23cDwWxlh23+0d/b4gpQsQbOwhrlCFGipmY9bYAq0LM2yd54wahZIbt4xaDFzyvoN+2eLO4Y93H/ZLse25DLJ5ee0H3zR5miIXqvCe1mjprhRlYA/jK2Ed0Q5w2ZRRqxc0dTfcrURgajMwNq3B722ZkLJmH3H1iI+pWhrjs1CBhTxkxEMl/6YPk0ba6IO41Yg5+7+iKgXarUVBS0U5pmYXYfzwGttM3yBjG0qMK8Szv43h3TXCHmuV1HKlZRbB3C7ParzLGrl27JMTZ2dlSRqMR97caUDN0L2r6bDNJnLONfVocPfQqQWxnulRklquiGGvXAvHQCbPbafCQdzB+zFiZkTXxsk3bOFWIJ8zd16mYNSk+8NC2TxXio9fLW4k7x5qYnS3rbWNVIeYtlL9aGS2nyIS0j/tlCbKlervFyQysAUyP97FryhBj6o9aKW/iI3LzisC2FQFumPKIOVYV4kTb55Bs2xOFJ4/J7EugGyrKUS8ySXVWJoxXv0bG6iWIFxk5afggJI/8I5JGDNIFcc+/fIAXphBOF6H1XchFxtKjCnFwVIq4vnyw21IZw8/Pz5Cfn4/MzEyzCsXeSmlpqXkDi+dss4yhh14liCeJv/ncbkp4bV4fNQW2Y2ZYBZkPONi+McasIWOcWvXTR39Xb5LZlDBO/1tQh+KXQBFiy3b66Fe5d7otmHqkcu80n0YikJSWkXkjBzeuCC3FcwLOPg3gZ5ecQl5JlfK90xJKO/2iT/Xe6VQBZYKA85seP0f8MwLUicORMtMeSXajED/ocVxl+4DHkDjKFolvDkbCsBeR8tbLeiD+2ZODx1/o+Wcn9HpjJnoN60IihrH00KsyADesnH0jMGZFYLekMoavr6+hQPyD647oVRmjYsnL4hqYaacZzopirPDQa8NNIGZdAqlX9NHf1ZvkFJmPFXYHYvq4Tu5qDN6N5XMquVsA00e/yhfOp5E4NaZ4KyXvxOLOM68D+7SccxOLa2AZIzKwKsAsfArptr0Nau1MfyRVMZ4+laeYNJD/xY8i8iGGZzkRExqgqP4tHqUHILSlRdS3t7Bi9xmMXv65Lql+kG3bthm6I9XXb6goRsWiwcBYG12ih175IgSRWVfP88SMVwHYEmQ+VqjneWLG06c6BkHszvPEqgD/u4rx3E7cWvGirueJGU+fzf+X/3Pln7affIxA9LM6AAAAAElFTkSuQmCC); background-repeat: no-repeat; *background-image: url(/sharepanel/assets/img/share-icons.png);}\n.sharepanel__tumblrIcon {background-position: 0 0;}\n.sharepanel__facebookIcon {background-position: -25px 0;}\n.sharepanel__redditIcon {background-position: -50px 0;}\n.sharepanel__stumbleUponIcon {background-position: -75px 0;}\n.sharepanel__bloggerIcon {background-position: -100px 0;}\n.sharepanel__weiboIcon {background-position: -125px 0;}\n.sharepanel__vkontakteIcon {background-position: -150px 0;}\n.sharepanel__tuentiIcon {background-position: -175px 0;}\n.sharepanel__orkutIcon {background-position: -200px 0;}\n.sharepanel__mixiIcon {background-position: -225px 0;}\n.sharepanel__compactState .sharepanel__tweeterWrapper {padding: 0 5px;}\n.sharepanel__compactState .sharepanel__tweeter {width: 55px !important;}\n.sharepanel__compactState .sharepanel__fb {width: 51px !important;}\n.sharepanel__compactState .sharepanel__plusone {width: 33px !important;}\n.fb_edge_comment_widget {display: none !important;}\n@media screen and (max-width: 450px) {.sharepanel__linkCodeInputCell {margin-right: 95px; padding-right: 5px;}.sharepanel__linkCodeInputTextCell {display: none;}}\n\n.closable {position: relative; display: block; height: 100%; overflow: hidden;}\n.closable__content {overflow: hidden;}\n.closable__closeButton {position: absolute; top: 0; right: 0;}\n\n.errorMessage {padding: 40px 60px 0 60px; text-align: center; line-height: 19px;}\n.errorMessage__link {position: relative; margin: 25px auto 0 auto;}\n\n.multiTracks {overflow: hidden; position: absolute; top: 0; right: 0; bottom: 0; left: 0; background: #F5F5F5;}\n.multiTracks__playerContainer {overflow: hidden; height: 163px; position: relative;}\n.multiTracks__mainContentWrapper {position: absolute; top: 163px; right: 0; bottom: 0; left: 0; z-index: 0;}\n.multiTracks__mainContent {position: absolute; top: 10px; right: 0; bottom: 0; left: 0;}\n.multiTracks__tracklistHeader {position: absolute; top: 0; left: 0; height: 20px; width: 100%; font-weight: bold; font-size: 11px; padding: 0 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; -webkit-box-sizing: border-box; -moz-box-sizing: border-box; box-sizing: border-box;}\n.multiTracks__tracklistHeaderLink {text-decoration: underline; color: #333;}\n.multiTracks__tracklistContainerWrapper {position: absolute; top: 0; right: 0; bottom: 0; left: 0; overflow: hidden;}\n.multiTracks__detailedMode .multiTracks__tracklistContainerWrapper {top: 20px;}\n.multiTracks__setMode .multiTracks__tracklistContainerWrapper {bottom: 55px;}\n.multiTracks__tracklistContainer {height: 100%;}\n.multiTracks__tracklistContainer .trackTitle__username {font-weight: normal;}\n.multiTracks__setDetailsContainer {position: absolute; bottom: 0; left: 0; right: 0; height: 55px; font-size: 11px;}\n\n.tracklist {font-size: 11px; display: block; position: relative; background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAAAwAQMAAABpObv5AAAABlBMVEXv7+////9mUzfqAAAAAnRSTlP/AOW3MEoAAAASSURBVBhXY2AY4uA/GBwYqjQAoLyhcRiSQxgAAAAASUVORK5CYII=); *background-image: url(/tracklist/assets/img/24-list.png);}\n.tracklist__detailedMode {background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAAB2AQMAAACwOFKIAAAABlBMVEXv7+////9mUzfqAAAAAnRSTlP/AOW3MEoAAAAVSURBVChTY2AYBcMS/AeDA6P08KIBIVmM7rpNdG0AAAAASUVORK5CYII=); *background-image: url(/tracklist/assets/img/59-list.png);}\n.tracklist__item {line-height: 16px; cursor: pointer; clear: both; overflow: hidden; position: relative; text-shadow: none;}\n.tracklist__itemContent {padding: 4px 10px 4px 0px;}\n.tracklist__trackTitleWrapper {font-weight: bold; margin-left: 25px; position: relative;}\n.tracklist__trackArtwork {width: 40px; height: 40px; display: block; position: absolute; top: 0; left: -45px;}\n.tracklist__trackTitle {word-wrap: break-word; position: relative;}\n.tracklist__index {position: absolute; top: 0; right: 100%; padding-right: 3px; text-align: right; font-weight: normal;}\n.tracklist__trackLength {margin: 0 0 0 5px; font-weight: normal;}\n.tracklist__title {margin: 0 0 3px 0;}\n.tracklist__stats {float: right; visibility: visible; position: relative; padding: 0 0 4px 4px; opacity: 0.4; -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=40)";}\n.tracklist__detailedMode .tracklist__stats {float: none; position: static; padding: 0;}\n.tracklist__detailedMode .tracklist__itemContent {padding: 8px 9px; min-height: 43px;}\n.tracklist__detailedMode .tracklist__trackTitleWrapper {margin-left: 45px;}\n.tracklist__wideIndex .tracklist__trackTitleWrapper {margin-left: 30px;}\n.tracklist__item__odd {background: #efefef;}\n.tracklist__item__even {background: #f5f5f5;}\n.tracklist__item:hover .tracklist__itemContent {background-color: rgba(<MAIN_COLOR_RGB>, 0.1) !important;}\n.tracklist__item__currentState:hover,\n.tracklist__item__currentState {color: <MAIN_CONTRAST_COLOR>; background-color: <MAIN_COLOR> !important;}\n.tracklist__item__currentState .tracklist__stats {opacity: 1; -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=100)";}\n.tracklist__item__currentState,\n.tracklist__item__currentState .tracklist__trackLength,\n.tracklist__item:hover .tracklist__trackLength {opacity: 1 !important; -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=100)";}\n@media only screen and (max-width: 180px) {.tracklist__detailedMode .tracklist__trackTitleWrapper {margin-left: 0;}.tracklist__trackArtwork {display: none;}}\n\n.setDetails {overflow: hidden; position: relative;}\n.setDetails__content {margin: 7px 5px;}\n.setDetails__artworkLink,\n .setDetails__artwork {width: 40px; height: 40px; margin-right: -40px; position: relative; float: left;}\n.setDetails__artworkLink img {width: 40px; height: 40px;}\n.setDetails__mainContent {position: relative; margin-left: 49px; padding-top: 2px;}\n.setDetails__userName,\n .setDetails__title {color: #333;}\n.setDetails__userName {margin: 3px 0 2px 0;}\n.setDetails__title {font-weight: bold;}\n.setDetails__buy {position: absolute; bottom: 0; right: 0;}\n.setDetails__shareLink {position: absolute; top: 0; right: 0; padding: 0; font-size: 12px; color: #333; text-decoration: none; visibility: hidden;}\n.setDetails__shareLinkIcon {background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAKCAAAAABHm/tfAAAAAnRSTlMA70YmMtEAAABeSURBVAgdJcGhAYAgFATQ2+kK/Q/gFgzgEDTbL0S6O7gAA9As9Iu/ivoe9MvcBX0ukgNa5pFIE+aeS7LWzzvgJKtiERqZfOoF1eJm3usQYpEbaROSIqKTHNAnjq3GA66XS9zEOQukAAAAAElFTkSuQmCC) no-repeat 0 3px; padding: 0 0 0 15px; *background-image: url(/set-details/assets/img/share-action-icon-small.png);}\n';
require_modules[0] = function(a, b, c) {
var d = this;
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1;
var e = c(1),
f = c(2),
g = c(4),
h = c(5),
i = c(7),
j = c(10),
k = c(11),
l = c(44),
m = c(48).Events,
n = c(107),
o = c(21),
p = c(46).SoundManager,
q = c(46).Events;
h.isIE8 && (document.body.className += " ie8");
var r = f.supplant(__requiredCss, i.getColorParams(), !0);
f.createStylesheet(r), e.extend(a.SC = a.SC || {}, {
AudioPlayer: l,
Connect: o,
utils: f
}), n.init();
var s = e.once(function() {
var a = new j;
g.sound || a.showError({
sound_error: !0
}), k.history.start()
});
(function b() {
document.body.offsetWidth > 0 ? g.audio ? (a.audioPlayer = l.getInstance(), s()) : p.loadSoundManagerLibrary(function() {
a.audioPlayer = l.getInstance(), s()
}) : setTimeout(b, 200)
})()
}, require_modules[1] = function(a, b, c) {
var d = this;
(function() {
var a = this,
c = a._,
d = {},
e = Array.prototype,
f = Object.prototype,
g = Function.prototype,
h = e.slice,
i = e.unshift,
j = f.toString,
k = f.hasOwnProperty,
l = e.forEach,
m = e.map,
n = e.reduce,
o = e.reduceRight,
p = e.filter,
q = e.every,
r = e.some,
s = e.indexOf,
t = e.lastIndexOf,
u = Array.isArray,
v = Object.keys,
w = g.bind,
x = function(a) {
return new C(a)
};
typeof b != "undefined" && b.exports ? (b.exports = x, x._ = x) : a._ = x, x.VERSION = "1.1.7";
var y = x.each = x.forEach = function(a, b, c) {
if (a != null) if (l && a.forEach === l) a.forEach(b, c);
else if (a.length === +a.length) {
for (var e = 0, f = a.length; e < f; e++) if (e in a && b.call(c, a[e], e, a) === d) return
} else for (var g in a) if (k.call(a, g) && b.call(c, a[g], g, a) === d) return
};
x.map = function(a, b, c) {
var d = [];
if (a == null) return d;
if (m && a.map === m) return a.map(b, c);
y(a, function(a, e, f) {
d[d.length] = b.call(c, a, e, f)
});
return d
}, x.reduce = x.foldl = x.inject = function(a, b, c, d) {
var e = c !== void 0;
a == null && (a = []);
if (n && a.reduce === n) {
d && (b = x.bind(b, d));
return e ? a.reduce(b, c) : a.reduce(b)
}
y(a, function(a, f, g) {
e ? c = b.call(d, c, a, f, g) : (c = a, e = !0)
});
if (!e) throw new TypeError("Reduce of empty array with no initial value");
return c
}, x.reduceRight = x.foldr = function(a, b, c, d) {
a == null && (a = []);
if (o && a.reduceRight === o) {
d && (b = x.bind(b, d));
return c !== void 0 ? a.reduceRight(b, c) : a.reduceRight(b)
}
var e = (x.isArray(a) ? a.slice() : x.toArray(a)).reverse();
return x.reduce(e, b, c, d)
}, x.find = x.detect = function(a, b, c) {
var d;
z(a, function(a, e, f) {
if (b.call(c, a, e, f)) {
d = a;
return !0
}
});
return d
}, x.filter = x.select = function(a, b, c) {
var d = [];
if (a == null) return d;
if (p && a.filter === p) return a.filter(b, c);
y(a, function(a, e, f) {
b.call(c, a, e, f) && (d[d.length] = a)
});
return d
}, x.reject = function(a, b, c) {
var d = [];
if (a == null) return d;
y(a, function(a, e, f) {
b.call(c, a, e, f) || (d[d.length] = a)
});
return d
}, x.every = x.all = function(a, b, c) {
var e = !0;
if (a == null) return e;
if (q && a.every === q) return a.every(b, c);
y(a, function(a, f, g) {
if (!(e = e && b.call(c, a, f, g))) return d
});
return e
};
var z = x.some = x.any = function(a, b, c) {
b = b || x.identity;
var e = !1;
if (a == null) return e;
if (r && a.some === r) return a.some(b, c);
y(a, function(a, f, g) {
if (e |= b.call(c, a, f, g)) return d
});
return !!e
};
x.include = x.contains = function(a, b) {
var c = !1;
if (a == null) return c;
if (s && a.indexOf === s) return a.indexOf(b) != -1;
z(a, function(a) {
if (c = a === b) return !0
});
return c
}, x.invoke = function(a, b) {
var c = h.call(arguments, 2);
return x.map(a, function(a) {
return (b.call ? b || a : a[b]).apply(a, c)
})
}, x.pluck = function(a, b) {
return x.map(a, function(a) {
return a[b]
})
}, x.max = function(a, b, c) {
if (!b && x.isArray(a)) return Math.max.apply(Math, a);
var d = {
computed: -Infinity
};
y(a, function(a, e, f) {
var g = b ? b.call(c, a, e, f) : a;
g >= d.computed && (d = {
value: a,
computed: g
})
});
return d.value
}, x.min = function(a, b, c) {
if (!b && x.isArray(a)) return Math.min.apply(Math, a);
var d = {
computed: Infinity
};
y(a, function(a, e, f) {
var g = b ? b.call(c, a, e, f) : a;
g < d.computed && (d = {
value: a,
computed: g
})
});
return d.value
}, x.sortBy = function(a, b, c) {
return x.pluck(x.map(a, function(a, d, e) {
return {
value: a,
criteria: b.call(c, a, d, e)
}
}).sort(function(a, b) {
var c = a.criteria,
d = b.criteria;
return c < d ? -1 : c > d ? 1 : 0
}), "value")
}, x.groupBy = function(a, b) {
var c = {};
y(a, function(a, d) {
var e = b(a, d);
(c[e] || (c[e] = [])).push(a)
});
return c
}, x.sortedIndex = function(a, b, c) {
c || (c = x.identity);
var d = 0,
e = a.length;
while (d < e) {
var f = d + e >> 1;
c(a[f]) < c(b) ? d = f + 1 : e = f
}
return d
}, x.toArray = function(a) {
if (!a) return [];
if (a.toArray) return a.toArray();
if (x.isArray(a)) return h.call(a);
if (x.isArguments(a)) return h.call(a);
return x.values(a)
}, x.size = function(a) {
return x.toArray(a).length
}, x.first = x.head = function(a, b, c) {
return b != null && !c ? h.call(a, 0, b) : a[0]
}, x.rest = x.tail = function(a, b, c) {
return h.call(a, b == null || c ? 1 : b)
}, x.last = function(a) {
return a[a.length - 1]
}, x.compact = function(a) {
return x.filter(a, function(a) {
return !!a
})
}, x.flatten = function(a) {
return x.reduce(a, function(a, b) {
if (x.isArray(b)) return a.concat(x.flatten(b));
a[a.length] = b;
return a
}, [])
}, x.without = function(a) {
return x.difference(a, h.call(arguments, 1))
}, x.uniq = x.unique = function(a, b) {
return x.reduce(a, function(a, c, d) {
if (0 == d || (b === !0 ? x.last(a) != c : !x.include(a, c))) a[a.length] = c;
return a
}, [])
}, x.union = function() {
return x.uniq(x.flatten(arguments))
}, x.intersection = x.intersect = function(a) {
var b = h.call(arguments, 1);
return x.filter(x.uniq(a), function(a) {
return x.every(b, function(b) {
return x.indexOf(b, a) >= 0
})
})
}, x.difference = function(a, b) {
return x.filter(a, function(a) {
return !x.include(b, a)
})
}, x.zip = function() {
var a = h.call(arguments),
b = x.max(x.pluck(a, "length")),
c = Array(b);
for (var d = 0; d < b; d++) c[d] = x.pluck(a, "" + d);
return c
}, x.indexOf = function(a, b, c) {
if (a == null) return -1;
var d, e;
if (c) {
d = x.sortedIndex(a, b);
return a[d] === b ? d : -1
}
if (s && a.indexOf === s) return a.indexOf(b);
for (d = 0, e = a.length; d < e; d++) if (a[d] === b) return d;
return -1
}, x.lastIndexOf = function(a, b) {
if (a == null) return -1;
if (t && a.lastIndexOf === t) return a.lastIndexOf(b);
var c = a.length;
while (c--) if (a[c] === b) return c;
return -1
}, x.range = function(a, b, c) {
arguments.length <= 1 && (b = a || 0, a = 0), c = arguments[2] || 1;
var d = Math.max(Math.ceil((b - a) / c), 0),
e = 0,
f = Array(d);
while (e < d) f[e++] = a, a += c;
return f
}, x.bind = function(a, b) {
if (a.bind === w && w) return w.apply(a, h.call(arguments, 1));
var c = h.call(arguments, 2);
return function() {
return a.apply(b, c.concat(h.call(arguments)))
}
}, x.bindAll = function(a) {
var b = h.call(arguments, 1);
b.length == 0 && (b = x.functions(a)), y(b, function(b) {
a[b] = x.bind(a[b], a)
});
return a
}, x.memoize = function(a, b) {
var c = {};
b || (b = x.identity);
return function() {
var d = b.apply(this, arguments);
return k.call(c, d) ? c[d] : c[d] = a.apply(this, arguments)
}
}, x.delay = function(a, b) {
var c = h.call(arguments, 2);
return setTimeout(function() {
return a.apply(a, c)
}, b)
}, x.defer = function(a) {
return x.delay.apply(x, [a, 1].concat(h.call(arguments, 1)))
};
var A = function(a, b, c) {
var d;
return function() {
var e = this,
f = arguments,
g = function() {
d = null, a.apply(e, f)
};
c && clearTimeout(d);
if (c || !d) d = setTimeout(g, b)
}
};
x.throttle = function(a, b) {
return A(a, b, !1)
}, x.debounce = function(a, b) {
return A(a, b, !0)
}, x.once = function(a) {
var b = !1,
c;
return function() {
if (b) return c;
b = !0;
return c = a.apply(this, arguments)
}
}, x.wrap = function(a, b) {
return function() {
var c = [a].concat(h.call(arguments));
return b.apply(this, c)
}
}, x.compose = function() {
var a = h.call(arguments);
return function() {
var b = h.call(arguments);
for (var c = a.length - 1; c >= 0; c--) b = [a[c].apply(this, b)];
return b[0]
}
}, x.after = function(a, b) {
return function() {
if (--a < 1) return b.apply(this, arguments)
}
}, x.keys = v ||
function(a) {
if (a !== Object(a)) throw new TypeError("Invalid object");
var b = [];
for (var c in a) k.call(a, c) && (b[b.length] = c);
return b
}, x.values = function(a) {
return x.map(a, x.identity)
}, x.functions = x.methods = function(a) {
var b = [];
for (var c in a) x.isFunction(a[c]) && b.push(c);
return b.sort()
}, x.extend = function(a) {
y(h.call(arguments, 1), function(b) {
for (var c in b) b[c] !== void 0 && (a[c] = b[c])
});
return a
}, x.defaults = function(a) {
y(h.call(arguments, 1), function(b) {
for (var c in b) a[c] == null && (a[c] = b[c])
});
return a
}, x.clone = function(a) {
return x.isArray(a) ? a.slice() : x.extend({}, a)
}, x.tap = function(a, b) {
b(a);
return a
}, x.isEqual = function(a, b) {
if (a === b) return !0;
var c = typeof a,
d = typeof b;
if (c != d) return !1;
if (a == b) return !0;
if (!a && b || a && !b) return !1;
a._chain && (a = a._wrapped), b._chain && (b = b._wrapped);
if (a.isEqual) return a.isEqual(b);
if (b.isEqual) return b.isEqual(a);
if (x.isDate(a) && x.isDate(b)) return a.getTime() === b.getTime();
if (x.isNaN(a) && x.isNaN(b)) return !1;
if (x.isRegExp(a) && x.isRegExp(b)) return a.source === b.source && a.global === b.global && a.ignoreCase === b.ignoreCase && a.multiline === b.multiline;
if (c !== "object") return !1;
if (a.length && a.length !== b.length) return !1;
var e = x.keys(a),
f = x.keys(b);
if (e.length != f.length) return !1;
for (var g in a) if (!(g in b) || !x.isEqual(a[g], b[g])) return !1;
return !0
}, x.isEmpty = function(a) {
if (x.isArray(a) || x.isString(a)) return a.length === 0;
for (var b in a) if (k.call(a, b)) return !1;
return !0
}, x.isElement = function(a) {
return !!a && a.nodeType == 1
}, x.isArray = u ||
function(a) {
return j.call(a) === "[object Array]"
}, x.isObject = function(a) {
return a === Object(a)
}, x.isArguments = function(a) {
return !!a && !! k.call(a, "callee")
}, x.isFunction = function(a) {
return !!(a && a.constructor && a.call && a.apply)
}, x.isString = function(a) {
return !!(a === "" || a && a.charCodeAt && a.substr)
}, x.isNumber = function(a) {
return !!(a === 0 || a && a.toExponential && a.toFixed)
}, x.isNaN = function(a) {
return a !== a
}, x.isBoolean = function(a) {
return a === !0 || a === !1
}, x.isDate = function(a) {
return !!(a && a.getTimezoneOffset && a.setUTCFullYear)
}, x.isRegExp = function(a) {
return !(!(a && a.test && a.exec) || !a.ignoreCase && a.ignoreCase !== !1)
}, x.isNull = function(a) {
return a === null
}, x.isUndefined = function(a) {
return a === void 0
}, x.noConflict = function() {
a._ = c;
return this
}, x.identity = function(a) {
return a
}, x.times = function(a, b, c) {
for (var d = 0; d < a; d++) b.call(c, d)
}, x.mixin = function(a) {
y(x.functions(a), function(b) {
E(b, x[b] = a[b])
})
};
var B = 0;
x.uniqueId = function(a) {
var b = B++;
return a ? a + b : b
}, x.templateSettings = {
evaluate: /<%([\s\S]+?)%>/g,
interpolate: /<%=([\s\S]+?)%>/g
}, x.template = function(a, b) {
var c = x.templateSettings,
d = "var __p=[],print=function(){__p.push.apply(__p,arguments);};with(obj||{}){__p.push('" + a.replace(/\\/g, "\\\\").replace(/'/g, "\\'").replace(c.interpolate, function(a, b) {
return "'," + b.replace(/\\'/g, "'") + ",'"
}).replace(c.evaluate || null, function(a, b) {
return "');" + b.replace(/\\'/g, "'").replace(/[\r\n\t]/g, " ") + "__p.push('"
}).replace(/\r/g, "\\r").replace(/\n/g, "\\n").replace(/\t/g, "\\t") + "');}return __p.join('');",
e = new Function("obj", d);
return b ? e(b) : e
};
var C = function(a) {
this._wrapped = a
};
x.prototype = C.prototype;
var D = function(a, b) {
return b ? x(a).chain() : a
},
E = function(a, b) {
C.prototype[a] = function() {
var a = h.call(arguments);
i.call(a, this._wrapped);
return D(b.apply(x, a), this._chain)
}
};
x.mixin(x), y(["pop", "push", "reverse", "shift", "sort", "splice", "unshift"], function(a) {
var b = e[a];
C.prototype[a] = function() {
b.apply(this._wrapped, arguments);
return D(this._wrapped, this._chain)
}
}), y(["concat", "join", "slice"], function(a) {
var b = e[a];
C.prototype[a] = function() {
return D(b.apply(this._wrapped, arguments), this._chain)
}
}), C.prototype.chain = function() {
this._chain = !0;
return this
}, C.prototype.value = function() {
return this._wrapped
}
})()
}, require_modules[2] = function(a, b, c) {
var d = this,
e = c(3).build,
f = window.location,
g = /[&<>\"\']/g,
h = function(a) {
return "&#" + a.charCodeAt(0) + ";"
},
i = /(&(lt|gt|quot|apos|amp|#\d+);|.)/gi,
j = {
lt: "<",
gt: ">",
quot: '"',
apos: "'",
amp: "&"
},
k = function(a, b, c) {
return j[c] || (c ? String.fromCharCode(c.substring(1)) : b)
},
l = String.prototype.trim,
m = /^\s+/,
n = /\s+$/,
o = window.document,
p = Array.prototype.slice,
q = b.exports = {
unescapeHTML: function(a) {
return (a || "").replace(i, k)
},
escapeHTML: function(a) {
return (a || "").replace(g, h)
},
supplant: function(a, b, c) {
var d = c ? /<([^<>]*)>/g : /\{([^\{\}]*)\}/g;
return (a || "").replace(d, function(a, c) {
var d = b[c];
return typeof d == "string" || typeof d == "number" ? d : a
})
},
inherits: function(a, b) {
var c = function() {};
c.prototype = b.prototype, a.superClass_ = b.prototype, a.prototype = new c, a.prototype.constructor = a
},
extend: function(a) {
var b = p.call(arguments, 1),
c, d, e, f;
for (c = 0, d = b.length; c < d; c++) {
e = b[c];
for (f in e) e[f] !== void 0 && (a[f] = e[f])
}
return a
},
emptyElement: function(a) {
while (a.firstChild) a.removeChild(a.firstChild)
},
createStylesheet: function(a) {
var b = o.createElement("style");
o.getElementsByTagName("head")[0].appendChild(b), b.styleSheet ? b.styleSheet.cssText = a : b.appendChild(o.createTextNode(a))
},
isUIWebView: function() {
return /(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(navigator.userAgent)
},
isFunction: function(a) {
return Object.prototype.toString.call(a) === "[object Function]"
},
trim: l ?
function(a) {
return a === null ? "" : l.call(a)
} : function(a) {
return a === null ? "" : (a + "").replace(m, "").replace(n, "")
},
mapSubFields: function(a, b, c) {
var d;
c = c || "";
for (d in b) b.hasOwnProperty(d) && (a[c + d] = b[d]);
return a
},
getTimestamp: function() {
var a = new Date;
return a.getTime()
},
addParamsToUrl: function(a, b) {
a += (/\?/.test(a) ? "&" : "?") + b;
return a
},
noop: function() {},
getAssetsDir: function() {
return f.protocol + "//" + f.host + f.pathname + e.assetsDir
},
getImageDir: function() {
return this.getAssetsDir() + "/" + "img"
},
capitalize: function(a) {
return a.charAt(0).toUpperCase() + a.slice(1)
}
}
}, require_modules[3] = function(a, b, c) {
var d = this;
d.bootstrapper = {
appHost: "wt.soundcloud.dev/",
appJs: "application.js",
debug: !0,
clearSessionStorage: !0,
flashPlayerUrl: "//player.soundcloud.com/player.swf"
}, d.build = {
appDir: "app",
htmlFile: "application.html",
outDir: "public",
assetsDir: "assets",
outFile2options: {
"index.html": {},
"flash-version.html": {
flashVersion: !0
},
"disabled-comments.html": {
showComments: !1
}
},
toBeSqueezed: !1
}, d.file = {
staticDir: "app"
}, d.http = {
port: 9200,
host: "0.0.0.0",
defaultFile: "/application.html"
}, d.wavProxy = {
host: "w1.sndcdn.com",
root: "/_waveform"
}, d.routes = {
api: /^\/_api/,
"static": /\.(?:js|png|gif|json|css|swf|ico|html|manifest|mp3)(?:\?.*)?$/,
waveform: /^\/_waveform/,
wildcard: /.*/
}, d.api = {
clientID: typeof window != "undefined" && window.location ? /wt\.soundcloud\.dev|10\.\d+/.test(window.location.host) ? "181fbe7e56ac80af29353323774890c3" : /wt\.soundcloud\.com/.test(window.location.host) ? "8925a570bf9dc21c78991ddb5f4b2254" : "0f8fdbbaa21a9bd18210986a7dc2d72c" : null,
host: "//api.soundcloud.com"
}, d.soundmanager = {
version: "WIDGET-20120828",
url: "./assets/soundmanager-js-20120828/soundmanager2.js",
minified: "./assets/soundmanager-js-20120828/soundmanager2-nodebug-jsmin.js",
swf: "assets/soundmanager-swf-20120828/"
}, d.widget = {
MAIN_COLOR: "#FF6600",
MAIN_CONTRAST_COLOR: "#FFFFFF",
MAIN_CONTRAST_COLOR2: "#000000",
WAVEFORM_BG_COLOR: "#EFEFEF",
WAVEFORM_WIDTH: 1800,
WAVEFORM_HEIGHT: 280
}
}, require_modules[4] = function(a, b, c) {
function j(a) {
try {
var b = !! a.getItem,
c = !1;
try {
var d = new Date,
e = d.getTime();
a.setItem(e, e), a.removeItem(e), c = !0
} catch (f) {}
return b && c
} catch (g) {
return !1
}
}
var d = this,
e = c(5),
f = c(6).namespaces,
g = {},
h = {},
i;
h.authSupported = function() {
return h.cors()
}, h.cors = function() {
var a = !1,
b = new XMLHttpRequest;
typeof b.withCredentials != "undefined" && (a = !0);
return a
}, h.json = function() {
return typeof window.JSON != "undefined"
}, h.transforms3d = function() {
var a = document.createElement("modernizr"),
b = a.style,
c = document.head || document.getElementsByTagName("head")[0],
d = document.documentElement,
e = " -webkit- -moz- -o- -ms- -khtml- ".split(" "),
f = "@media (" + e.join("transform-3d),(") + "modernizr)",
g = document.createElement("style"),
h = document.createElement("div"),
i = 0,
j = function(a) {
while (a[i]) {
if (typeof b[a[i]] != "undefined") return !0;
i++
}
},
k = !! j(["perspectiveProperty", "WebkitPerspective", "MozPerspective", "OPerspective", "msPerspective"]);
k && typeof d.style.webkitPerspective != "undefined" && (k = null, g.textContent = f + "{#modernizr{height:3px}}", c.appendChild(g), h.id = "modernizr", d.appendChild(h), k = h.offsetHeight === 3 ? !0 : !1, g.parentNode.removeChild(g), h.parentNode.removeChild(h));
return k
}, h.canvas = function() {
var a = document.createElement("canvas");
return !!a.getContext && !! a.getContext("2d")
}, h.vml = function() {
var a, b, c;
a = document.body.appendChild(document.createElement("div")), a.innerHTML = '<v:shape id="vml_flag1" adj="1" />', b = a.firstChild, b.style.behavior = "url(#default#VML)", c = b ? typeof b.adj == "object" : !0, a.parentNode.removeChild(a);
return c
}, h.svg = function() {
return !!document.createElementNS && !! document.createElementNS(f.svg, "svg").createSVGRect
}, h.inlineSVG = function() {
var a = document.createElement("div");
a.innerHTML = "<svg/>";
return (a.firstChild && a.firstChild.namespaceURI) === "http://www.w3.org/2000/svg"
}, h.sessionStorage = function() {
try {
return typeof sessionStorage != "undefined" && j(sessionStorage)
} catch (a) {
return !1
}
}, h.localStorage = function() {
try {
return typeof localStorage != "undefined" && j(localStorage)
} catch (a) {
return !1
}
}, h.newWidget = function() {
var a = document.documentMode,
b = h.json();
if (!b) return !1;
if (e.isIEMobile) return !0;
if (a === 7 || e.isIE7 || e.isIE6) return !1;
return !0
}, h.audio = function() {
var a = !1;
try {
var b = new Audio;
a = b.canPlayType && /maybe|probably/.test(b.canPlayType("audio/mpeg"))
} catch (c) {}
return a
}, h.touch = function() {
try {
return window.hasOwnProperty("ontouchstart")
} catch (a) {
return !1
}
}, h.flash = function() {
var a = !1,
b = navigator,
c = b.plugins,
d = window.ActiveXObject,
e, f, g;
if (c && c.length) f = "application/x-shockwave-flash", g = b.mimeTypes, g && g[f] && g[f].enabledPlugin && g[f].enabledPlugin.description && (a = !0);
else if (typeof d != "undefined") {
try {
e = new d("ShockwaveFlash.ShockwaveFlash")
} catch (h) {}
a = !! e
}
return a
}, h.sound = function() {
return !!h.audio() || !! h.flash()
};
for (i in h) h.hasOwnProperty(i) && (g[i] = h[i]());
g.set = function(a, b) {
g.hasOwnProperty(a) && (g[a] = b)
}, g.noVectors = !g.svg && !g.vml, b.exports = g
}, require_modules[5] = function(a, b, c) {
var d = this,
e = navigator.userAgent.toLowerCase(),
f = function(a) {
return a.test(e)
},
g = b.exports = {};
g.isOpera = f(/opera/), g.isChrome = f(/chrome/), g.isWebKit = f(/webkit/), g.isSafari = !g.isChrome && f(/safari/), g.isIE = !g.isOpera && f(/msie/), g.isIE7 = g.isIE && f(/msie 7/), g.isIE8 = g.isIE && f(/msie 8/), g.isIE9 = g.isIE && f(/msie 9/), g.isIE6 = g.isIE && !g.isIE7 && !g.isIE8 && !g.isIE9, g.isGecko = !g.isWebKit && f(/gecko/), g.isGecko2 = g.isGecko && f(/rv:1\.8/), g.isGecko3 = g.isGecko && f(/rv:1\.9/), g.isWindows = f(/windows|win32/), g.isMac = f(/macintosh|mac os x/), g.isLinux = f(/linux/), g.isMobile = f(/mobile/), g.isTouch = function() {
try {
return window.hasOwnProperty("ontouchstart")
} catch (a) {
return !1
}
}(), g.isAndroid = f(/android/), g.isIEMobile = g.isMobile && g.isIE, g.isSecure = /^https/i.test(window.location.protocol), g.isChrome15 = g.isChrome && f(/chrome\/15/)
}, require_modules[6] = function(a, b, c) {
var d = this;
d.namespaces = {
svg: "http://www.w3.org/2000/svg",
xhtml: "http://www.w3.org/1999/xhtml",
xlink: "http://www.w3.org/1999/xlink",
ev: "http://www.w3.org/2001/xml-events",
xml: "http://www.w3.org/XML/1998/namespace",
vml: "urn:schemas-microsoft-com:vml",
office: "urn:schemas-microsoft-com:office:office"
}
}, require_modules[7] = function(a, b, c) {
function m() {
if (!m.__cached) {
var a = g.clone(i),
b = l(),
c = /^#[a-f0-9]{3}$/i;
g.each(k, function(d, e) {
var f = b[e];
f && (f[0] !== "#" && (f = "#" + f), c.test(f) && (f = f.replace(/([a-z0-9])/gi, "$1$1")), a[d] = f)
}), h.match(a.MAIN_COLOR, a.MAIN_CONTRAST_COLOR) || (a.MAIN_CONTRAST_COLOR = a.MAIN_CONTRAST_COLOR2), a.MAIN_COLOR_RGB = h.hex2rgbString(a.MAIN_COLOR), a.MAIN_COLOR_BURN = h.burn(a.MAIN_COLOR, .35), a.MAIN_COLOR_LIGHTER = h.rgb2hex(h.lighten(a.MAIN_COLOR_RGB.split(","), .5)), a.MAIN_COLOR_DARKER = h.rgb2hex(h.darken(a.MAIN_COLOR_RGB.split(","), .1)), m.__cached = a
}
return m.__cached
}
function l() {
return f.parse(e.unescapeHTML(location.search)).params
}
var d = this,
e = c(2),
f = c(8),
g = c(1),
h = c(9),
i = {
MAIN_COLOR: "#FF6600",
MAIN_CONTRAST_COLOR: "#FFFFFF",
MAIN_CONTRAST_COLOR2: "#333333",
WAVEFORM_BG_COLOR: "#EFEFEF"
},
j = {
WAVEFORM_WIDTH: 1800,
WAVEFORM_HEIGHT: 280
},
k = {
color: "MAIN_COLOR",
waveformbg: "WAVEFORM_BG_COLOR"
};
d.getColorParams = m, d.isAlternativeContrastColor = function() {
var a = m();
return a.MAIN_CONTRAST_COLOR === i.MAIN_CONTRAST_COLOR2
}, d.scaleFactor = .5, d.defaultUrlParams = {
auto_advance: !0,
auto_play: !1,
buying: !0,
liking: !0,
download: !0,
sharing: !0,
show_artwork: !0,
show_comments: !0,
show_playcount: !0,
show_user: !0,
start_track: 0
}
}, require_modules[8] = function(a, b, c) {
function h(a) {
var b = [],
c;
for (c in a) a.hasOwnProperty(c) && b.push(encodeURIComponent(c) + "=" + encodeURIComponent(a[c]));
return b.join("&")
}
function g(a) {
var b = f,
c = b.parser[b.strictMode ? "strict" : "loose"].exec(a),
d = {},
e = 14;
while (e--) d[b.key[e]] = c[e] || "";
d[b.q.name] = {}, d[b.key[12]].replace(b.q.parser, function(a, c, e) {
c && (d[b.q.name][c] = e)
});
return d
}
var d = this,
e = c(2),
f = {
strictMode: !1,
key: ["source", "protocol", "authority", "userInfo", "user", "password", "host", "port", "relative", "path", "directory", "file", "query", "anchor"],
q: {
name: "params",
parser: /(?:^|&)([^&=]*)=?([^&]*)/g
},
parser: {
strict: /^(?:([^:\/?#]+):)?(?:\/\/((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?))?((((?:[^?#\/]*\/)*)([^?#]*))(?:\?([^#]*))?(?:#(.*))?)/,
loose: /^(?:(?![^:@]+:[^:@\/]*@)([^:\/?#.]+):)?(?:\/\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/
}
};
b.exports = {
parse: g,
serialize: h,
getUrlParams: function() {
return g(e.unescapeHTML(location.search)).params
}
}
}, require_modules[9] = function(a, b, c) {
var d = this,
e = 260,
f = 100,
g = b.exports = {
getBrightnessDiff: function(a, b) {
var c = (a[0] * 299 + a[1] * 587 + a[2] * 114) / 1e3,
d = (b[0] * 299 + b[1] * 587 + b[2] * 114) / 1e3;
return Math.abs(Math.round(c - d))
},
getColorDiff: function(a, b) {
var c = Math.max(a[0], b[0]) - Math.min(a[0], b[0]) + (Math.max(a[1], b[1]) - Math.min(a[1], b[1])) + (Math.max(a[2], b[2]) - Math.min(a[2], b[2]));
return Math.abs(Math.round(c))
},
hex2rgbString: function(a) {
var b = g.hex2rgb(a);
return b.join(",")
},
hex2rgb: function(a) {
a = a.replace("#", "");
var b = [parseInt(a[0] + a[1], 16), parseInt(a[2] + a[3], 16), parseInt(a[4] + a[5], 16)];
return b
},
rgb2hex: function(a) {
var b = "#",
c, d;
for (d = 0; d < 3; d++) c = a[d].toString(16), b += c.length < 2 ? "0" + c : c;
return b
},
rgb2hsl: function(a) {
var b = a[0] / 255,
c = a[1] / 255,
d = a[2] / 255,
e = Math.min(b, c, d),
f = Math.max(b, c, d),
g = f - e,
h, i, j;
f === e ? h = 0 : b === f ? h = (c - d) / g : c === f ? h = 2 + (d - b) / g : d === f && (h = 4 + (b - c) / g), h = Math.min(h * 60, 360), h < 0 && (h += 360), j = (e + f) / 2, f === e ? i = 0 : j <= .5 ? i = g / (f + e) : i = g / (2 - f - e);
return [h, i * 100, j * 100]
},
hsl2rgb: function(a) {
var b = a[0] / 360,
c = a[1] / 100,
d = a[2] / 100,
e, f, g, h, i, j;
if (c === 0) {
i = Math.floor(d * 255);
return [i, i, i]
}
d < .5 ? f = d * (1 + c) : f = d + c - d * c, e = 2 * d - f, h = [0, 0, 0];
for (j = 0; j < 3; j++) g = b + 1 / 3 * -(j - 1), g < 0 && g++, g > 1 && g--, 6 * g < 1 ? i = e + (f - e) * 6 * g : 2 * g < 1 ? i = f : 3 * g < 2 ? i = e + (f - e) * (2 / 3 - g) * 6 : i = e, h[j] = Math.floor(i * 255);
return h
},
match: function(a, b) {
var c = this.hex2rgb(a),
d = this.hex2rgb(b),
g = this.getBrightnessDiff(c, d),
h = this.getColorDiff(c, d);
return g >= f && h >= e ? !0 : !1
},
darken: function(a, b) {
var c = g.rgb2hsl(a);
c[2] -= c[2] * b;
return g.hsl2rgb(c)
},
lighten: function(a, b) {
var c = g.rgb2hsl(a);
c[2] += c[2] * b;
return g.hsl2rgb(c)
},
burn: function(a, b) {
var c = g.hex2rgb(a),
d = [],
e;
b = b || 1;
for (e = 0; e < 3; e++) d[e] = c[e] === 255 ? 255 : Math.round(c[e] * (1 - b));
return g.rgb2hex(d)
}
}
}, require_modules[10] = function(a, b, c) {
var d = this,
e = c(1),
f = c(11),
g = c(28).View,
h = c(96).View,
i = c(94).View,
j = c(95).Model,
k = c(104).Model,
l = c(105).Model,
m = c(106).Model,
n = c(50).Model,
o = b.exports = f.Router.extend({
initialize: function() {
var a = this,
b = function(b, c, d) {
return function(f, g) {
g.id = f, this.errorMessage && (c = i, e.extend(g, this.errorMessage));
var h = new c(e.extend({
model: new b(e.extend(g, d)),
el: a.view.el
}, d));
a.setCurrentView(h)
}
};
this.view = new f.View({
el: "#widget"
}), this.set(/^\/tracks\/([^\/]+)\/?$/, b(n, g)), this.set(/^\/playlists\/([^\/]+)\/?$/, b(k, h, {
widgetType: "set"
})), this.set(/^\/users\/([^\/]+)\/?$/, b(j, h, {
widgetType: "user",
subresourceType: "tracks"
})), this.set(/^\/users\/([^\/]+)\/favorites\/?$/, b(j, h, {
widgetType: "user",
subresourceType: "favorites"
})), this.set(/^\/groups\/([^\/]+)\/?$/, b(m, h, {
widgetType: "group",
subresourceType: "tracks"
})), this.set(/^\/apps\/([^\/]+)\/?$/, b(l, h, {
widgetType: "app",
subresourceType: "tracks"
}))
},
set: function(a, b) {
this.route(a, a, b)
},
setCurrentView: function(a) {
this.currentView = a
},
showError: function(a) {
this.errorMessage = a
}
})
}, require_modules[11] = function(a, b, c) {
var d = this,
e = c(12),
f = c(19),
g = c(8),
h = c(2),
i = c(1),
j = c(13),
k = c(3).api,
l = c(4),
m = c(20),
n = c(21),
o = c(23),
p = e.sync,
q = 1e4;
e.sync = function(a, b, c) {
c = i.extend({
cacheResult: !1
}, c);
var d = n.getAccessToken(),
g = location.protocol.indexOf("https") === 0,
o = c.data && c.data.oauth_token,
r = d || g || o ? "https" : "http",
s = c.url || (i.isFunction(b.url) ? b.url() : b.url),
t = s,
u = r + ":" + k.host + s;
c.data = c.data || {}, i.extend(c.data, {
client_id: k.clientID,
format: "json"
});
var v = e.history && e.history.getOptions() || {};
v.secret_token && (c.data.secret_token = v.secret_token), i.extend(c, {
url: u,
crossOrigin: l.cors,
type: l.cors ? "json" : "jsonp",
timeout: q
});
if (a === "read") {
this instanceof e.Collection && (t += JSON.stringify(c.data || {}));
var w = c.success || h.noop,
x = c.error || h.noop,
y = f.get(t);
if (y) {
setTimeout(function() {
m.log("CACHED DATA " + c.url), c.success(y)
}, 0);
return
}
i.extend(c, {
error: function(a) {
var c, d;
a = a || {};
try {
c = a.status || 0, d = a.statusText || "unknown"
} catch (f) {
c = 0, d = "unknown"
}
b.trigger(e.SERVER_ERROR_EVENT, a), j(document).trigger(e.SERVER_ERROR_EVENT, {
status: c,
statusText: d,
url: u
}), x.apply(this, arguments)
},
success: function(b) {
a === "read" && b && !b.error && c.cacheResult && f.set(t, b), w.apply(this, arguments)
}
})
}
p.apply(this, arguments)
};
var r = "url",
s = window.location;
i.extend(e.History.prototype, {
getFragment: function(a) {
var b = this.getOptions(a);
return b.hasOwnProperty(r) ? b[r] : ""
},
_getParams: function(a) {
return g.parse(h.unescapeHTML(a)).params
},
getOptions: function(a) {
var b = this._getParams(a || s.search);
b[r] = decodeURIComponent(b[r]);
var c = this._getParams(b[r]);
b[r] = g.parse(b[r]).path, b = i.extend(b, c), i.each(b, function(a, c) {
a === "false" ? b[c] = !1 : a === "true" && (b[c] = !0)
});
return b
}
}), i.extend(e.Router.prototype, {
_extractParameters: function(a, b) {
var c = i.extend(e.history.getOptions(), {
show_comments: window.loadCommentsFromAPI
});
return a.exec(b).slice(1).concat([c])
}
}), e.SERVER_ERROR_EVENT = "server-error.backbone", b.exports = e
}, require_modules[12] = function(a, b, c) {
var d = this,
e = c(1),
f = c(13),
g = b.exports = {};
g.VERSION = "0.5.3", g.emulateHTTP = !1, g.emulateJSON = !1, g.Events = {
bind: function(a, b, c) {
var d = this._callbacks || (this._callbacks = {}),
e = d[a] || (d[a] = []);
e.push([b, c]);
return this
},
unbind: function(a, b) {
var c;
if (!a) this._callbacks = {};
else if (c = this._callbacks) if (!b) c[a] = [];
else {
var d = c[a];
if (!d) return this;
for (var e = 0, f = d.length; e < f; e++) if (d[e] && b === d[e][0]) {
d[e] = null;
break
}
}
return this
},
trigger: function(a) {
var b, c, d, e, f, g = 2;
if (!(c = this._callbacks)) return this;
while (g--) {
d = g ? a : "all";
if (b = c[d]) for (var h = 0, i = b.length; h < i; h++)(e = b[h]) ? (f = g ? Array.prototype.slice.call(arguments, 1) : arguments, e[0].apply(e[1] || this, f)) : (b.splice(h, 1), h--, i--)
}
return this
}
}, g.Model = function(a, b) {
var c;
a || (a = {});
if (c = this.defaults) e.isFunction(c) && (c = c.call(this)), a = e.extend({}, c, a);
this.attributes = {}, this._escapedAttributes = {}, this.cid = e.uniqueId("c"), this.set(a, {
silent: !0
}), this._changed = !1, this._previousAttributes = e.clone(this.attributes), b && b.collection && (this.collection = b.collection), this.initialize(a, b)
}, e.extend(g.Model.prototype, g.Events, {
_previousAttributes: null,
_changed: !1,
idAttribute: "id",
initialize: function() {},
toJSON: function() {
return e.clone(this.attributes)
},
get: function(a) {
return this.attributes[a]
},
escape: function(a) {
var b;
if (b = this._escapedAttributes[a]) return b;
var c = this.attributes[a];
return this._escapedAttributes[a] = y(c == null ? "" : "" + c)
},
has: function(a) {
return this.attributes[a] != null
},
set: function(a, b) {
b || (b = {});
if (!a) return this;
a.attributes && (a = a.attributes);
var c = this.attributes,
d = this._escapedAttributes;
if (!b.silent && this.validate && !this._performValidation(a, b)) return !1;
this.idAttribute in a && (this.id = a[this.idAttribute]);
var f = this._changing;
this._changing = !0;
for (var g in a) {
var h = a[g];
e.isEqual(c[g], h) || (c[g] = h, delete d[g], this._changed = !0, b.silent || this.trigger("change:" + g, this, h, b))
}!f && !b.silent && this._changed && this.change(b), this._changing = !1;
return this
},
unset: function(a, b) {
if (!(a in this.attributes)) return this;
b || (b = {});
var c = this.attributes[a],
d = {};
d[a] = void 0;
if (!b.silent && this.validate && !this._performValidation(d, b)) return !1;
delete this.attributes[a], delete this._escapedAttributes[a], a == this.idAttribute && delete this.id, this._changed = !0, b.silent || (this.trigger("change:" + a, this, void 0, b), this.change(b));
return this
},
clear: function(a) {
a || (a = {});
var b, c = this.attributes,
d = {};
for (b in c) d[b] = void 0;
if (!a.silent && this.validate && !this._performValidation(d, a)) return !1;
this.attributes = {}, this._escapedAttributes = {}, this._changed = !0;
if (!a.silent) {
for (b in c) this.trigger("change:" + b, this, void 0, a);
this.change(a)
}
return this
},
fetch: function(a) {
a || (a = {});
var b = this,
c = a.success;
a.success = function(d, e, f) {
if (!b.set(b.parse(d, f), a)) return !1;
c && c(b, d)
}, a.error = x(a.error, b, a);
return (this.sync || g.sync).call(this, "read", this, a)
},
save: function(a, b) {
b || (b = {});
if (a && !this.set(a, b)) return !1;
var c = this,
d = b.success;
b.success = function(a, e, f) {
if (!c.set(c.parse(a, f), b)) return !1;
d && d(c, a, f)
}, b.error = x(b.error, c, b);
var e = this.isNew() ? "create" : "update";
return (this.sync || g.sync).call(this, e, this, b)
},
destroy: function(a) {
a || (a = {});
if (this.isNew()) return this.trigger("destroy", this, this.collection, a);
var b = this,
c = a.success;
a.success = function(d) {
b.trigger("destroy", b, b.collection, a), c && c(b, d)
}, a.error = x(a.error, b, a);
return (this.sync || g.sync).call(this, "delete", this, a)
},
url: function() {
var a = v(this.collection) || this.urlRoot || w();
if (this.isNew()) return a;
return a + (a.charAt(a.length - 1) == "/" ? "" : "/") + encodeURIComponent(this.id)
},
parse: function(a, b) {
return a
},
clone: function() {
return new this.constructor(this)
},
isNew: function() {
return this.id == null
},
change: function(a) {
this.trigger("change", this, a), this._previousAttributes = e.clone(this.attributes), this._changed = !1
},
hasChanged: function(a) {
if (a) return this._previousAttributes[a] != this.attributes[a];
return this._changed
},
changedAttributes: function(a) {
a || (a = this.attributes);
var b = this._previousAttributes,
c = !1;
for (var d in a) e.isEqual(b[d], a[d]) || (c = c || {}, c[d] = a[d]);
return c
},
previous: function(a) {
if (!a || !this._previousAttributes) return null;
return this._previousAttributes[a]
},
previousAttributes: function() {
return e.clone(this._previousAttributes)
},
_performValidation: function(a, b) {
var c = this.validate(a);
if (c) {
b.error ? b.error(this, c, b) : this.trigger("error", this, c, b);
return !1
}
return !0
}
}), g.Collection = function(a, b) {
b || (b = {}), b.comparator && (this.comparator = b.comparator), e.bindAll(this, "_onModelEvent", "_removeReference"), this._reset(), a && this.reset(a, {
silent: !0
}), this.initialize.apply(this, arguments)
}, e.extend(g.Collection.prototype, g.Events, {
model: g.Model,
initialize: function() {},
toJSON: function() {
return this.map(function(a) {
return a.toJSON()
})
},
add: function(a, b) {
if (e.isArray(a)) for (var c = 0, d = a.length; c < d; c++) this._add(a[c], b);
else this._add(a, b);
return this
},
remove: function(a, b) {
if (e.isArray(a)) for (var c = 0, d = a.length; c < d; c++) this._remove(a[c], b);
else this._remove(a, b);
return this
},
get: function(a) {
if (a == null) return null;
return this._byId[a.id != null ? a.id : a]
},
getByCid: function(a) {
return a && this._byCid[a.cid || a]
},
at: function(a) {
return this.models[a]
},
sort: function(a) {
a || (a = {});
if (!this.comparator) throw new Error("Cannot sort a set without a comparator");
this.models = this.sortBy(this.comparator), a.silent || this.trigger("reset", this, a);
return this
},
pluck: function(a) {
return e.map(this.models, function(b) {
return b.get(a)
})
},
reset: function(a, b) {
a || (a = []), b || (b = {}), this.each(this._removeReference), this._reset(), this.add(a, {
silent: !0
}), b.silent || this.trigger("reset", this, b);
return this
},
fetch: function(a) {
a || (a = {});
var b = this,
c = a.success;
a.success = function(d, e, f) {
b[a.add ? "add" : "reset"](b.parse(d, f), a), c && c(b, d)
}, a.error = x(a.error, b, a);
return (this.sync || g.sync).call(this, "read", this, a)
},
create: function(a, b) {
var c = this;
b || (b = {}), a = this._prepareModel(a, b);
if (!a) return !1;
var d = b.success;
b.success = function(a, e, f) {
c.add(a, b), d && d(a, e, f)
}, a.save(null, b);
return a
},
parse: function(a, b) {
return a
},
chain: function() {
return e(this.models).chain()
},
_reset: function(a) {
this.length = 0, this.models = [], this._byId = {}, this._byCid = {}
},
_prepareModel: function(a, b) {
if (a instanceof g.Model) a.collection || (a.collection = this);
else {
var c = a;
a = new this.model(c, {
collection: this
}), a.validate && !a._performValidation(c, b) && (a = !1)
}
return a
},
_add: function(a, b) {
b || (b = {}), a = this._prepareModel(a, b);
if (!a) return !1;
var c = this.getByCid(a);
if (c) throw new Error(["Can't add the same model to a set twice", c.id]);
this._byId[a.id] = a, this._byCid[a.cid] = a;
var d = b.at != null ? b.at : this.comparator ? this.sortedIndex(a, this.comparator) : this.length;
this.models.splice(d, 0, a), a.bind("all", this._onModelEvent), this.length++, b.silent || a.trigger("add", a, this, b);
return a
},
_remove: function(a, b) {
b || (b = {}), a = this.getByCid(a) || this.get(a);
if (!a) return null;
delete this._byId[a.id], delete this._byCid[a.cid], this.models.splice(this.indexOf(a), 1), this.length--, b.silent || a.trigger("remove", a, this, b), this._removeReference(a);
return a
},
_removeReference: function(a) {
this == a.collection && delete a.collection, a.unbind("all", this._onModelEvent)
},
_onModelEvent: function(a, b, c, d) {
if (a != "add" && a != "remove" || c == this) a == "destroy" && this._remove(b, d), b && a === "change:" + b.idAttribute && (delete this._byId[b.previous(b.idAttribute)], this._byId[b.id] = b), this.trigger.apply(this, arguments)
}
});
var h = ["forEach", "each", "map", "reduce", "reduceRight", "find", "detect", "filter", "select", "reject", "every", "all", "some", "any", "include", "contains", "invoke", "max", "min", "sortBy", "sortedIndex", "toArray", "size", "first", "rest", "last", "without", "indexOf", "lastIndexOf", "isEmpty", "groupBy"];
e.each(h, function(a) {
g.Collection.prototype[a] = function() {
return e[a].apply(e, [this.models].concat(e.toArray(arguments)))
}
}), g.Router = function(a) {
a || (a = {}), a.routes && (this.routes = a.routes), this._bindRoutes(), this.initialize.apply(this, arguments)
};
var i = /:([\w\d]+)/g,
j = /\*([\w\d]+)/g,
k = /[-[\]{}()+?.,\\^$|#\s]/g;
e.extend(g.Router.prototype, g.Events, {
initialize: function() {},
route: function(a, b, c) {
g.history || (g.history = new g.History), e.isRegExp(a) || (a = this._routeToRegExp(a)), g.history.route(a, e.bind(function(d) {
var e = this._extractParameters(a, d);
c.apply(this, e), this.trigger.apply(this, ["route:" + b].concat(e))
}, this))
},
navigate: function(a, b) {
g.history.navigate(a, b)
},
_bindRoutes: function() {
if ( !! this.routes) {
var a = [];
for (var b in this.routes) a.unshift([b, this.routes[b]]);
for (var c = 0, d = a.length; c < d; c++) this.route(a[c][0], a[c][1], this[a[c][1]])
}
},
_routeToRegExp: function(a) {
a = a.replace(k, "\\$&").replace(i, "([^/]*)").replace(j, "(.*?)");
return new RegExp("^" + a + "$")
},
_extractParameters: function(a, b) {
return a.exec(b).slice(1)
}
}), g.History = function() {
this.handlers = [], e.bindAll(this, "checkUrl")
};
var l = /^#*/,
m = /msie [\w.]+/,
n = !1;
e.extend(g.History.prototype, {
interval: 50,
getFragment: function(a, b) {
if (a == null) if (this._hasPushState || b) {
a = window.location.pathname;
var c = window.location.search;
c && (a += c)
} else a = window.location.hash;
a = decodeURIComponent(a.replace(l, "")), a.indexOf(this.options.root) || (a = a.substr(this.options.root.length));
return a
},
start: function(a) {
if (n) throw new Error("Backbone.history has already been started");
this.options = e.extend({}, {
root: "/"
}, this.options, a), this._wantsPushState = !! this.options.pushState, this._hasPushState = !! (this.options.pushState && window.history && window.history.pushState);
var b = this.getFragment(),
c = document.documentMode,
d = m.exec(navigator.userAgent.toLowerCase()) && (!c || c <= 7);
d && (this.iframe = f('<iframe src="javascript:0" tabindex="-1" />').hide().appendTo("body")[0].contentWindow, this.navigate(b)), this._hasPushState ? f(window).bind("popstate", this.checkUrl) : "onhashchange" in window && !d ? f(window).bind("hashchange", this.checkUrl) : setInterval(this.checkUrl, this.interval), this.fragment = b, n = !0;
var g = window.location,
h = g.pathname == this.options.root;
if (this._wantsPushState && !this._hasPushState && !h) {
this.fragment = this.getFragment(null, !0), window.location.replace(this.options.root + "#" + this.fragment);
return !0
}
this._wantsPushState && this._hasPushState && h && g.hash && (this.fragment = g.hash.replace(l, ""), window.history.replaceState({}, document.title, g.protocol + "//" + g.host + this.options.root + this.fragment));
if (!this.options.silent) return this.loadUrl()
},
route: function(a, b) {
this.handlers.unshift({
route: a,
callback: b
})
},
checkUrl: function(a) {
var b = this.getFragment();
b == this.fragment && this.iframe && (b = this.getFragment(this.iframe.location.hash));
if (b == this.fragment || b == decodeURIComponent(this.fragment)) return !1;
this.iframe && this.navigate(b), this.loadUrl() || this.loadUrl(window.location.hash)
},
loadUrl: function(a) {
var b = this.fragment = this.getFragment(a),
c = e.any(this.handlers, function(a) {
if (a.route.test(b)) {
a.callback(b);
return !0
}
});
return c
},
navigate: function(a, b) {
var c = (a || "").replace(l, "");
if (this.fragment != c && this.fragment != decodeURIComponent(c)) {
if (this._hasPushState) {
var d = window.location;
c.indexOf(this.options.root) != 0 && (c = this.options.root + c), this.fragment = c, window.history.pushState({}, document.title, d.protocol + "//" + d.host + c)
} else window.location.hash = this.fragment = c, this.iframe && c != this.getFragment(this.iframe.location.hash) && (this.iframe.document.open().close(), this.iframe.location.hash = c);
b && this.loadUrl(a)
}
}
}), g.View = function(a) {
this.cid = e.uniqueId("view"), this._configure(a || {}), this._ensureElement(), this.delegateEvents(), this.initialize.apply(this, arguments)
};
var o = function(a) {
return f(a, this.el)
},
p = /^(\S+)\s*(.*)$/,
q = ["model", "collection", "el", "id", "attributes", "className", "tagName"];
e.extend(g.View.prototype, g.Events, {
tagName: "div",
$: o,
initialize: function() {},
render: function() {
return this
},
remove: function() {
f(this.el).remove();
return this
},
make: function(a, b, c) {
var d = document.createElement(a);
b && f(d).attr(b), c && f(d).html(c);
return d
},
delegateEvents: function(a) {
if ( !! a || !! (a = this.events)) {
e.isFunction(a) && (a = a.call(this)), this.undelegateEvents();
for (var b in a) {
var c = this[a[b]];
if (!c) throw new Error('Event "' + a[b] + '" does not exist');
var d = b.match(p),
g = d[1],
h = d[2];
c = e.bind(c, this), g += ".delegateEvents" + this.cid, h === "" ? f(this.el).bind(g, c) : f(this.el).delegate(h, g, c)
}
}
},
undelegateEvents: function() {
f(this.el).unbind(".delegateEvents" + this.cid)
},
_configure: function(a) {
this.options && (a = e.extend({}, this.options, a));
for (var b = 0, c = q.length; b < c; b++) {
var d = q[b];
a[d] && (this[d] = a[d])
}
this.options = a
},
_ensureElement: function() {
if (!this.el) {
var a = this.attributes || {};
this.id && (a.id = this.id), this.className && (a["class"] = this.className), this.el = this.make(this.tagName, a)
} else e.isString(this.el) && (this.el = f(this.el).get(0))
}
});
var r = function(a, b) {
var c = u(this, a, b);
c.extend = this.extend;
return c
};
g.Model.extend = g.Collection.extend = g.Router.extend = g.View.extend = r;
var s = {
create: "POST",
update: "PUT",
"delete": "DELETE",
read: "GET"
};
g.sync = function(a, b, c) {
var d = s[a],
h = e.extend({
method: d,
dataType: "json"
}, c);
h.url || (h.url = v(b) || w()), !h.data && b && (a == "create" || a == "update") && (h.contentType = "application/json", h.data = JSON.stringify(b.toJSON())), g.emulateJSON && (h.contentType = "application/x-www-form-urlencoded", h.data = h.data ? {
model: h.data
} : {}), g.emulateHTTP && (d === "PUT" || d === "DELETE") && (g.emulateJSON && (h.data._method = d), h.method = "POST", h.beforeSend = function(a) {
a.setRequestHeader("X-HTTP-Method-Override", d)
});
return f.ajax(h)
};
var t = function() {},
u = function(a, b, c) {
var d;
b && b.hasOwnProperty("constructor") ? d = b.constructor : d = function() {
return a.apply(this, arguments)
}, e.extend(d, a), t.prototype = a.prototype, d.prototype = new t, b && e.extend(d.prototype, b), c && e.extend(d, c), d.prototype.constructor = d, d.__super__ = a.prototype;
return d
},
v = function(a) {
if (!a || !a.url) return null;
return e.isFunction(a.url) ? a.url() : a.url
},
w = function() {
throw new Error('A "url" property or function must be specified')
},
x = function(a, b, c) {
return function(d) {
a ? a(b, d, c) : b.trigger("error", b, d, c)
}
},
y = function(a) {
return a.replace(/&(?!\w+;|#\d+;|#x[\da-f]+;)/gi, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """).replace(/'/g, "'").replace(/\//g, "/")
}
}, require_modules[13] = function(a, b, c) {
function y(a, b) {
var c = /^\s*<([^\s>]+)\s*/.exec(a)[1],
d = (b || v).createElement(x[c] || "div"),
e = [];
d.innerHTML = a;
var f = d.childNodes;
d = d.firstChild, d.nodeType == 1 && e.push(d);
while (d = d.nextSibling) d.nodeType == 1 && e.push(d);
return e
}
function n(a, b, c) {
return a ? b.css(c, a) : function(a) {
a = b.css(c), a.indexOf("%") > -1 ? a = NaN : a = parseInt(a, 10);
return isNaN(a) ? b[0]["offset" + c.replace(/^\w/, function(a) {
return a.toUpperCase()
})] : a
}()
}
function m(a) {
var b = [],
c, d;
label: for (c = 0; c < a.length; c++) {
for (d = 0; d < b.length; d++) if (b[d] == a[c]) continue label;
b[b.length] = a[c]
}
return b
}
function k(a, b) {
for (var c = 0; c < a.length; c++) if (a[c] === b) return c;
return -1
}
var d = this,
e = c(14),
f = c(15),
g = function(a) {
return function() {
var b = (this && this.length > 0 ? this : []).concat(Array.prototype.slice.call(arguments, 0));
return f[a].apply(null, b)
}
},
h = g("serialize"),
i = g("serializeArray");
e.ender({
ajax: f,
serialize: h,
serializeArray: i,
toQueryString: f.toQueryString
}), e.ender({
serialize: h,
serializeArray: i
}, !0);
var j = c(16);
j.setQueryEngine(e), e.ender(j), e.ender(j(), !0), e.ender({
create: function(a) {
return e(j.create(a))
}
}), e.id = function(a) {
return e([document.getElementById(a)])
}, e.ender({
parents: function(a, b) {
var c = e(a),
d, f, g, h = [];
for (d = 0, f = this.length; d < f; d++) {
g = this[d];
while (g = g.parentNode) if (~k(c, g)) {
h.push(g);
if (b) break
}
}
return e(m(h))
},
closest: function(a) {
return this.parents(a, !0)
},
first: function() {
return e(this[0])
},
last: function() {
return e(this[this.length - 1])
},
next: function() {
return e(j(this).next())
},
previous: function() {
return e(j(this).previous())
},
appendTo: function(a) {
return j(this.selector).appendTo(a, this)
},
prependTo: function(a) {
return j(this.selector).prependTo(a, this)
},
insertAfter: function(a) {
return j(this.selector).insertAfter(a, this)
},
insertBefore: function(a) {
return j(this.selector).insertBefore(a, this)
},
siblings: function() {
var a, b, c, d = [];
for (a = 0, b = this.length; a < b; a++) {
c = this[a];
while (c = c.previousSibling) c.nodeType == 1 && d.push(c);
c = this[a];
while (c = c.nextSibling) c.nodeType == 1 && d.push(c)
}
return e(d)
},
children: function() {
var a, b, c = [];
for (a = 0, l = this.length; a < l; a++) {
if (!(b = j.firstChild(this[a]))) continue;
c.push(b);
while (b = b.nextSibling) b.nodeType == 1 && c.push(b)
}
return e(m(c))
},
height: function(a) {
return n(a, this, "height")
},
width: function(a) {
return n(a, this, "width")
}
}, !0);
var j = c(17),
g = function(a, b, c) {
var d = b ? [b] : [];
return function() {
for (var c, f = 0, g = this.length; f < g; f++) c = [this[f]].concat(d, Array.prototype.slice.call(arguments, 0)), c.length == 4 && c.push(e), !arguments.length && a == "add" && b && (a = "fire"), j[a].apply(this, c);
return this
}
},
o = g("add"),
p = g("remove"),
q = g("fire"),
r = {
on: o,
addListener: o,
bind: o,
listen: o,
delegate: o,
one: g("one"),
unbind: p,
unlisten: p,
removeListener: p,
undelegate: p,
emit: q,
trigger: q,
cloneEvents: g("clone"),
hover: function(a, b, c) {
for (c = this.length; c--;) j.add.call(this, this[c], "mouseenter", a), j.add.call(this, this[c], "mouseleave", b);
return this
}
},
s, t = ["blur", "change", "click", "dblclick", "error", "focus", "focusin", "focusout", "keydown", "keypress", "keyup", "load", "mousedown", "mouseenter", "mouseleave", "mouseout", "mouseover", "mouseup", "mousemove", "resize", "scroll", "select", "submit", "unload"];
for (s = t.length; s--;) r[t[s]] = g("add", t[s]);
e.ender(r, !0);
var u = c(18),
v = document,
w = "table",
x = {
thead: w,
tbody: w,
tfoot: w,
tr: "tbody",
th: "tr",
td: "tr",
fieldset: "form",
option: "select"
};
e._select = function(a, b) {
return /^\s*</.test(a) ? y(a, b) : u(a, b)
}, e.pseudos = u.pseudos, e.ender({
find: function(a) {
var b = [],
c, d, f, g, h;
for (c = 0, d = this.length; c < d; c++) {
h = u(a, this[c]);
for (f = 0, g = h.length; f < g; f++) b.push(h[f])
}
return e(u.uniq(b))
},
and: function(a) {
var b = e(a);
for (var c = this.length, d = 0, f = this.length + b.length; c < f; c++, d++) this[c] = b[d];
return this
}
}, !0), b.exports = e
}, require_modules[14] = function(a, b, c) {
var d = this;
!
function(a) {
function i(a, b) {
return h(a, b)
}
function h(a, b, c) {
i._select && (typeof a == "string" || a.nodeName || a.length && "item" in a || a == window) ? (c = i._select(a, b), c.selector = a) : c = isFinite(a.length) ? a : [a];
return g(c, h)
}
function g(a, b) {
for (var c in b) c != "noConflict" && c != "_VERSION" && (a[c] = b[c]);
return a
}
function f(a, b) {
return c[a] = b
}
function e(a) {
var b = c[a] || window[a];
if (!b) throw new Error("Requested module '" + a + "' has not been defined.");
return b
}
a.global = a;
var c = {},
d = a.$;
a.provide = f, a.require = e, g(i, {
_VERSION: "0.3.4",
fn: h,
ender: function(a, b) {
g(b ? h : i, a)
},
_select: function(a, b) {
return (b || document).querySelectorAll(a)
}
}), g(h, {
forEach: function(a, b, c) {
for (c = 0, l = this.length; c < l; ++c) c in this && a.call(b || this[c], this[c], c, this);
return this
},
$: i
}), i.noConflict = function() {
a.$ = d;
return this
}, typeof b != "undefined" && b.exports && (b.exports = i), a.ender = a.$ = a.ender || i
}(this)
}, require_modules[15] = function(global, module, require) {
var exports = this;
!
function(a, b) {
typeof define == "function" ? define(b) : typeof module != "undefined" ? module.exports = b() : this[a] = b()
}("reqwest", function() {
function serializeHash() {
var a = {};
eachFormElement.apply(function(b, c) {
b in a ? (a[b] && !isArray(a[b]) && (a[b] = [a[b]]), a[b].push(c)) : a[b] = c
}, arguments);
return a
}
function serializeQueryString() {
return reqwest.toQueryString(reqwest.serializeArray.apply(null, arguments))
}
function eachFormElement() {
var a = this,
b, c, d, e = function(b, c) {
for (var e = 0; e < c.length; e++) {
var f = b[byTag](c[e]);
for (d = 0; d < f.length; d++) serial(f[d], a)
}
};
for (c = 0; c < arguments.length; c++) b = arguments[c], /input|select|textarea/i.test(b.tagName) && serial(b, a), e(b, ["input", "select", "textarea"])
}
function serial(a, b) {
var c = a.name,
d = a.tagName.toLowerCase(),
e = function(a) {
a && !a.disabled && b(c, normalize(a.attributes.value && a.attributes.value.specified ? a.value : a.text))
};
if (!a.disabled && !! c) switch (d) {
case "input":
if (!/reset|button|image|file/i.test(a.type)) {
var f = /checkbox/i.test(a.type),
g = /radio/i.test(a.type),
h = a.value;
(!f && !g || a.checked) && b(c, normalize(f && h === "" ? "on" : h))
}
break;
case "textarea":
b(c, normalize(a.value));
break;
case "select":
if (a.type.toLowerCase() === "select-one") e(a.selectedIndex >= 0 ? a.options[a.selectedIndex] : null);
else for (var i = 0; a.length && i < a.length; i++) a.options[i].selected && e(a.options[i])
}
}
function normalize(a) {
return a ? a.replace(/\r?\n/g, "\r\n") : ""
}
function reqwest(a, b) {
return new Reqwest(a, b)
}
function init(o, fn) {
function error(a, b, c) {
o.error && o.error(a, b, c), complete(a)
}
function success(resp) {
var r = resp.responseText;
if (r) switch (type) {
case "json":
try {
resp = win.JSON ? win.JSON.parse(r) : eval("(" + r + ")")
} catch (err) {
return error(resp, "Could not parse JSON in response", err)
}
break;
case "js":
resp = eval(r);
break;
case "html":
resp = r
}
fn(resp), o.success && o.success(resp), complete(resp)
}
function complete(a) {
o.timeout && clearTimeout(self.timeout), self.timeout = null, o.complete && o.complete(a)
}
this.url = typeof o == "string" ? o : o.url, this.timeout = null;
var type = o.type || setType(this.url),
self = this;
fn = fn ||
function() {}, o.timeout && (this.timeout = setTimeout(function() {
self.abort()
}, o.timeout)), this.request = getRequest(o, success, error, complete)
}
function setType(a) {
var b = a.match(/\.(json|jsonp|html|xml)(\?|$)/);
return b ? b[1] : "js"
}
function Reqwest(a, b) {
this.o = a, this.fn = b, init.apply(this, arguments)
}
function getRequest(a, b, c, d) {
var e = (a.method || "GET").toUpperCase(),
f = typeof a == "string" ? a : a.url,
g = a.processData !== !1 && a.data && typeof a.data != "string" ? reqwest.toQueryString(a.data) : a.data || null;
(a.type == "jsonp" || e == "GET") && g && (f = urlappend(f, g)) && (g = null);
if (a.type == "jsonp") return handleJsonp(a, b, c, f, d);
var h = xhr();
h.open(e, f, !0), setHeaders(h, a), h.onreadystatechange = handleReadyState(h, b, c), a.before && a.before(h), h.send(g);
return h
}
function handleJsonp(a, b, c, d, e) {
var f = uniqid++,
g = a.jsonpCallback || "callback",
h = a.jsonpCallbackName || "reqwest_" + f,
i = new RegExp("(" + g + ")=(.+)(&|$)"),
j = d.match(i),
k = doc.createElement("script"),
l = 0;
j ? j[2] === "?" ? d = d.replace(i, "$1=" + h + "$3") : h = j[2] : d = urlappend(d, g + "=" + h), win[h] = generalCallback, k.type = "text/javascript", k.src = urlappend(d, "_=" + +(new Date)), k.async = !0, k.onload = k.onreadystatechange = function() {
if (k[readyState] && k[readyState] !== "complete" && k[readyState] !== "loaded" || l) return !1;
l = 1, k.onload = k.onreadystatechange = null, k.onclick && k.onclick(), e && e(lastValue), a.success && a.success(lastValue), lastValue = undefined, head.removeChild(k)
}, head.appendChild(k);
return {
abort: function() {
c && c()
}
}
}
function urlappend(a, b) {
return a + (/\?/.test(a) ? "&" : "?") + b
}
function generalCallback(a) {
lastValue = a
}
function setHeaders(a, b) {
var c = b.headers || {},
d = {
xml: "application/xml, text/xml",
html: "text/html",
text: "text/plain",
json: "application/json, text/javascript",
js: "application/javascript, text/javascript"
};
c.Accept = c.Accept || d[b.type] || "text/javascript, text/html, application/xml, text/xml, */*", b.crossOrigin || (c["X-Requested-With"] = c["X-Requested-With"] || "XMLHttpRequest"), c[contentType] = c[contentType] || "application/x-www-form-urlencoded";
for (var e in c) c.hasOwnProperty(e) && a.setRequestHeader(e, c[e])
}
function handleReadyState(a, b, c) {
return function() {
a && a[readyState] == 4 && (twoHundo.test(a.status) ? b(a) : c(a))
}
}
var context = this,
win = window,
doc = document,
old = context.reqwest,
twoHundo = /^20\d$/,
byTag = "getElementsByTagName",
readyState = "readyState",
contentType = "Content-Type",
head = doc[byTag]("head")[0],
uniqid = 0,
lastValue, xhr = "XMLHttpRequest" in win ?
function() {
return new XMLHttpRequest
} : function() {
return new ActiveXObject("Microsoft.XMLHTTP")
};
Reqwest.prototype = {
abort: function() {
this.request.abort()
},
retry: function() {
init.call(this, this.o, this.fn)
}
};
var isArray = typeof Array.isArray == "function" ? Array.isArray : function(a) {
return a instanceof Array
};
reqwest.serializeArray = function() {
var a = [];
eachFormElement.apply(function(b, c) {
a.push({
name: b,
value: c
})
}, arguments);
return a
}, reqwest.serialize = function() {
if (arguments.length === 0) return "";
var a, b, c = Array.prototype.slice.call(arguments, 0);
a = c.pop(), a && a.nodeType && c.push(a) && (a = null), a && (a = a.type), a == "map" ? b = serializeHash : a == "array" ? b = reqwest.serializeArray : b = serializeQueryString;
return b.apply(null, c)
}, reqwest.toQueryString = function(a) {
var b = "",
c, d = encodeURIComponent,
e = function(a, c) {
b += d(a) + "=" + d(c) + "&"
};
if (isArray(a)) for (c = 0; a && c < a.length; c++) e(a[c].name, a[c].value);
else for (var f in a) {
if (!Object.hasOwnProperty.call(a, f)) continue;
var g = a[f];
if (isArray(g)) for (c = 0; c < g.length; c++) e(f, g[c]);
else e(f, a[f])
}
return b.replace(/&$/, "").replace(/%20/g, "+")
}, reqwest.noConflict = function() {
context.reqwest = old;
return this
};
return reqwest
})
}, require_modules[16] = function(a, b, c) {
var d = this;
!
function(a, c) {
typeof b != "undefined" ? b.exports = c() : typeof define == "function" ? define(c) : this[a] = c()
}("bonzo", function() {
function O(a, b) {
return new J(a, b)
}
function N() {
return {
x: b.pageXOffset || d.scrollLeft,
y: b.pageYOffset || d.scrollTop
}
}
function M(a) {
return a === b || /^(?:body|html)$/i.test(a.tagName)
}
function L(a, c, d) {
var e = this[0];
if (a == null && c == null) return (M(e) ? N() : {
x: e.scrollLeft,
y: e.scrollTop
})[d];
M(e) ? b.scrollTo(a, c) : (a != null && (e.scrollLeft = a), c != null && (e.scrollTop = c));
return this
}
function K(a) {
return typeof a == "string" ? O.create(a) : A(a) ? [a] : a
}
function J(a) {
this.length = 0;
if (a) {
a = typeof a != "string" && !a.nodeType && typeof a.length != "undefined" ? a : [a], this.length = a.length;
for (var b = 0; b < a.length; b++) this[b] = a[b]
}
}
function I(a, b) {
return typeof b == "function" ? b(a) : b
}
function H(a, b) {
a.className = w(a.className.replace(x(b), " "))
}
function G(a, b) {
a.className = w(a.className + " " + b)
}
function F(a, b) {
return x(b).test(a.className)
}
function E(a, b, c) {
var d = O(a),
e = d.css("position"),
f = d.offset(),
g = "relative",
h = e == g,
i = [parseInt(d.css("left"), 10), parseInt(d.css("top"), 10)];
e == "static" && (d.css("position", g), e = g), isNaN(i[0]) && (i[0] = h ? 0 : a.offsetLeft), isNaN(i[1]) && (i[1] = h ? 0 : a.offsetTop), b != null && (a.style.left = b - f.left + i[0] + q), c != null && (a.style.top = c - f.top + i[1] + q)
}
function D(a, b, c) {
var d = 0,
g = b || this,
h = [],
i = f && typeof a == "string" && a.charAt(0) != "<" ? f(a) : a;
y(K(i), function(a) {
y(g, function(b) {
var f = !b[e] || b[e] && !b[e][e] ?
function() {
var a = b.cloneNode(!0);
g.$ && g.cloneEvents && g.$(a).cloneEvents(b);
return a
}() : b;
c(a, f), h[d] = f, d++
})
}, this), y(h, function(a, b) {
g[b] = a
}), g.length = d;
return g
}
function B(a, b, c, d) {
for (d = 0, j = a.length; d < j; ++d) if (b.call(c, a[d], d, a)) return !0;
return !1
}
function A(a) {
return a && a.nodeName && a.nodeType == 1
}
function z(a) {
return a.replace(/-(.)/g, function(a, b) {
return b.toUpperCase()
})
}
function y(a, b, c) {
for (var d = 0, e = a.length; d < e; d++) b.call(c || a[d], a[d], d, a);
return a
}
function x(a) {
return new RegExp("(^|\\s+)" + a + "(\\s+|$)")
}
var a = this,
b = window,
c = b.document,
d = c.documentElement,
e = "parentNode",
f = null,
g = /^checked|value|selected$/,
h = /select|fieldset|table|tbody|tfoot|td|tr|colgroup/i,
i = "table",
k = {
thead: i,
tbody: i,
tfoot: i,
tr: "tbody",
th: "tr",
td: "tr",
fieldset: "form",
option: "select"
},
l = /^checked|selected$/,
m = /msie/i.test(navigator.userAgent),
n = [],
o = 0,
p = /^-?[\d\.]+$/,
q = "px",
r = "setAttribute",
s = "getAttribute",
t = /(^\s*|\s*$)/g,
u = {
lineHeight: 1,
zoom: 1,
zIndex: 1,
opacity: 1
},
v = function() {
var a = ["webkitTransform", "MozTransform", "OTransform", "msTransform", "Transform"],
b;
for (b = 0; b < a.length; b++) if (a[b] in c.createElement("a").style) return a[b]
}(),
w = String.prototype.trim ?
function(a) {
return a.trim()
} : function(a) {
return a.replace(t, "")
}, C = c.defaultView && c.defaultView.getComputedStyle ?
function(a, b) {
b = b == "transform" ? v : b, b = b == "transform-origin" ? v + "Origin" : b;
var d = null;
b == "float" && (b = "cssFloat");
var e = c.defaultView.getComputedStyle(a, "");
e && (d = e[z(b)]);
return a.style[b] || d
} : m && d.currentStyle ?
function(a, b) {
b = z(b), b = b == "float" ? "styleFloat" : b;
if (b == "opacity") {
var c = 100;
try {
c = a.filters["DXImageTransform.Microsoft.Alpha"].opacity
} catch (d) {
try {
c = a.filters("alpha").opacity
} catch (e) {}
}
return c / 100
}
var f = a.currentStyle ? a.currentStyle[b] : null;
return a.style[b] || f
} : function(a, b) {
return a.style[z(b)]
};
J.prototype = {
get: function(a) {
return this[a]
},
each: function(a, b) {
return y(this, a, b)
},
map: function(a, b) {
var c = [],
d, e;
for (e = 0; e < this.length; e++) d = a.call(this, this[e], e), b ? b(d) && c.push(d) : c.push(d);
return c
},
first: function() {
return O(this[0])
},
last: function() {
return O(this[this.length - 1])
},
html: function(a, b) {
function f(b) {
while (b.firstChild) b.removeChild(b.firstChild);
y(K(a), function(a) {
b.appendChild(a)
})
}
var c = b ? d.textContent === null ? "innerText" : "textContent" : "innerHTML",
e;
return typeof a != "undefined" ? this.each(function(b) {
(e = b.tagName.match(h)) ? f(b, e[0]) : b[c] = a
}) : this[0] ? this[0][c] : ""
},
text: function(a) {
return this.html(a, 1)
},
addClass: function(a) {
return this.each(function(b) {
F(b, I(b, a)) || G(b, I(b, a))
})
},
removeClass: function(a) {
return this.each(function(b) {
F(b, I(b, a)) && H(b, I(b, a))
})
},
hasClass: function(a) {
return B(this, function(b) {
return F(b, a)
})
},
toggleClass: function(a, b) {
return this.each(function(c) {
typeof b != "undefined" ? b ? G(c, a) : H(c, a) : F(c, a) ? H(c, a) : G(c, a)
})
},
show: function(a) {
return this.each(function(b) {
b.style.display = a || ""
})
},
hide: function(a) {
return this.each(function(a) {
a.style.display = "none"
})
},
append: function(a) {
return this.each(function(b) {
y(K(a), function(a) {
b.appendChild(a)
})
})
},
prepend: function(a) {
return this.each(function(b) {
var c = b.firstChild;
y(K(a), function(a) {
b.insertBefore(a, c)
})
})
},
appendTo: function(a, b) {
return D.call(this, a, b, function(a, b) {
a.appendChild(b)
})
},
prependTo: function(a, b) {
return D.call(this, a, b, function(a, b) {
a.insertBefore(b, a.firstChild)
})
},
next: function() {
return this.related("nextSibling")
},
previous: function() {
return this.related("previousSibling")
},
related: function(a) {
return this.map(function(b) {
b = b[a];
while (b && b.nodeType !== 1) b = b[a];
return b || 0
}, function(a) {
return a
})
},
before: function(a) {
return this.each(function(b) {
y(O.create(a), function(a) {
b[e].insertBefore(a, b)
})
})
},
after: function(a) {
return this.each(function(b) {
y(O.create(a), function(a) {
b[e].insertBefore(a, b.nextSibling)
})
})
},
insertBefore: function(a, b) {
return D.call(this, a, b, function(a, b) {
a[e].insertBefore(b, a)
})
},
insertAfter: function(a, b) {
return D.call(this, a, b, function(a, b) {
var c = a.nextSibling;
c ? a[e].insertBefore(b, c) : a[e].appendChild(b)
})
},
replaceWith: function(a) {
return this.each(function(b) {
b.parentNode.replaceChild(O.create(a)[0], b)
})
},
css: function(a, d, e) {
function g(a, b, c) {
for (var d in f) f.hasOwnProperty(d) && (c = f[d], (b = z(d)) && p.test(c) && !(b in u) && (c += q), b = b == "transform" ? v : b, b = b == "transformOrigin" ? v + "Origin" : b, a.style[b] = I(a, c))
}
if (d === undefined && typeof a == "string") {
d = this[0];
if (!d) return null;
if (d == c || d == b) {
e = d == c ? O.doc() : O.viewport();
return a == "width" ? e.width : a == "height" ? e.height : ""
}
return C(d, a)
}
var f = a;
typeof a == "string" && (f = {}, f[a] = d), m && f.opacity && (f.filter = "alpha(opacity=" + f.opacity * 100 + ")", f.zoom = a.zoom || 1, delete f.opacity);
if (d = f["float"]) m ? f.styleFloat = d : f.cssFloat = d, delete f["float"];
return this.each(g)
},
offset: function(a, b) {
if (typeof a == "number" || typeof b == "number") return this.each(function(c) {
E(c, a, b)
});
var c = this[0],
d = c.offsetWidth,
e = c.offsetHeight,
f = c.offsetTop,
g = c.offsetLeft;
while (c = c.offsetParent) f = f + c.offsetTop, g = g + c.offsetLeft;
return {
top: f,
left: g,
height: e,
width: d
}
},
attr: function(a, b) {
var c = this[0];
if (typeof a != "string" && !(a instanceof String)) {
for (var d in a) a.hasOwnProperty(d) && this.attr(d, a[d]);
return this
}
return typeof b == "undefined" ? g.test(a) ? l.test(a) && typeof c[a] == "string" ? !0 : c[a] : c[s](a) : this.each(function(c) {
g.test(a) ? c[a] = I(c, b) : c[r](a, I(c, b))
})
},
val: function(a) {
return typeof a == "string" ? this.attr("value", a) : this[0].value
},
removeAttr: function(a) {
return this.each(function(b) {
l.test(a) ? b[a] = !1 : b.removeAttribute(a)
})
},
data: function(a, b) {
var c = this[0];
if (typeof b == "undefined") {
c[s]("data-node-uid") || c[r]("data-node-uid", ++o);
var d = c[s]("data-node-uid");
n[d] || (n[d] = {});
return n[d][a]
}
return this.each(function(c) {
c[s]("data-node-uid") || c[r]("data-node-uid", ++o);
var d = c[s]("data-node-uid"),
e = n[d] || (n[d] = {});
e[a] = b
})
},
remove: function() {
return this.each(function(a) {
a[e] && a[e].removeChild(a)
})
},
empty: function() {
return this.each(function(a) {
while (a.firstChild) a.removeChild(a.firstChild)
})
},
detach: function() {
return this.map(function(a) {
return a[e].removeChild(a)
})
},
scrollTop: function(a) {
return L.call(this, null, a, "y")
},
scrollLeft: function(a) {
return L.call(this, a, null, "x")
},
toggle: function(a) {
this.each(function(a) {
a.style.display = a.offsetWidth || a.offsetHeight ? "none" : "block"
}), a && a();
return this
}
}, O.setQueryEngine = function(a) {
f = a, delete O.setQueryEngine
}, O.aug = function(a, b) {
for (var c in a) a.hasOwnProperty(c) && ((b || J.prototype)[c] = a[c])
}, O.create = function(a) {
return typeof a == "string" && a !== "" ?
function() {
var b = /^<([^\s>]+)/.exec(a),
d = c.createElement(b && k[b[1].toLowerCase()] || "div"),
e = [];
d.innerHTML = a;
var f = d.childNodes;
d = d.firstChild, d.nodeType == 1 && e.push(d);
while (d = d.nextSibling) d.nodeType == 1 && e.push(d);
return e
}() : A(a) ? [a.cloneNode(!0)] : []
}, O.doc = function() {
var a = this.viewport();
return {
width: Math.max(c.body.scrollWidth, d.scrollWidth, a.width),
height: Math.max(c.body.scrollHeight, d.scrollHeight, a.height)
}
}, O.firstChild = function(a) {
for (var b = a.childNodes, c = 0, d = b && b.length || 0, e; c < d; c++) b[c].nodeType === 1 && (e = b[d = c]);
return e
}, O.viewport = function() {
return {
width: m ? d.clientWidth : self.innerWidth,
height: m ? d.clientHeight : self.innerHeight
}
}, O.isAncestor = "compareDocumentPosition" in d ?
function(a, b) {
return (a.compareDocumentPosition(b) & 16) == 16
} : "contains" in d ?
function(a, b) {
return a !== b && a.contains(b)
} : function(a, b) {
while (b = b[e]) if (b === a) return !0;
return !1
};
var P = a.bonzo;
O.noConflict = function() {
a.bonzo = P;
return this
};
return O
})
}, require_modules[17] = function(a, b, c) {
var d = this;
!
function(a, c, d) {
typeof b != "undefined" ? b.exports = d(a, c) : typeof define == "function" && typeof define.amd == "object" ? define(d) : c[a] = d(a, c)
}("bean", this, function(a, b) {
var c = window,
d = b[a],
e = /over|out/,
f = /[^\.]*(?=\..*)\.|.*/,
g = /\..*/,
h = "addEventListener",
i = "attachEvent",
j = "removeEventListener",
k = "detachEvent",
l = document || {},
m = l.documentElement || {},
n = m[h],
o = n ? h : i,
p = Array.prototype.slice,
q = /click|mouse(?!(.*wheel|scroll))|menu|drag|drop/i,
r = /mouse.*(wheel|scroll)/i,
s = /^text/i,
t = /^touch|^gesture/i,
u = {
one: 1
},
v = function(a, b, c) {
for (c = 0; c < b.length; c++) a[b[c]] = 1;
return a
}({}, ("click dblclick mouseup mousedown contextmenu mousewheel mousemultiwheel DOMMouseScroll mouseover mouseout mousemove selectstart selectend keydown keypress keyup orientationchange focus blur change reset select submit load unload beforeunload resize move DOMContentLoaded readystatechange error abort scroll " + (n ? "show input invalid touchstart touchmove touchend touchcancel gesturestart gesturechange gestureend message readystatechange pageshow pagehide popstate hashchange offline online afterprint beforeprint dragstart dragenter dragover dragleave drag drop dragend loadstart progress suspend emptied stalled loadmetadata loadeddata canplay canplaythrough playing waiting seeking seeked ended durationchange timeupdate play pause ratechange volumechange cuechange checking noupdate downloading cached updateready obsolete " : "")).split(" ")),
w = function() {
function b(b) {
var c = b.relatedTarget;
if (!c) return c === null;
return c !== this && c.prefix !== "xul" && !/document/.test(this + "") && !a(this, c)
}
function a(a, b) {
while ((b = b.parentNode) !== null) if (b === a) return !0;
return !1
}
return {
mouseenter: {
base: "mouseover",
condition: b
},
mouseleave: {
base: "mouseout",
condition: b
},
mousewheel: {
base: /Firefox/.test(navigator.userAgent) ? "DOMMouseScroll" : "mousewheel"
}
}
}(),
x = function() {
var a = "altKey attrChange attrName bubbles cancelable ctrlKey currentTarget detail eventPhase getModifierState isTrusted metaKey relatedNode relatedTarget shiftKey srcElement target timeStamp type view which".split(" "),
b = a.concat("button buttons clientX clientY dataTransfer fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" ")),
c = b.concat("wheelDelta wheelDeltaX wheelDeltaY wheelDeltaZ axis".split(" ")),
d = a.concat("char charCode key keyCode keyIdentifier keyLocation".split(" ")),
f = a.concat(["data"]),
g = a.concat("touches targetTouches changedTouches scale rotation".split(" ")),
h = "preventDefault",
i = function(a) {
return function() {
a[h] ? a[h]() : a.returnValue = !1
}
},
j = "stopPropagation",
k = function(a) {
return function() {
a[j] ? a[j]() : a.cancelBubble = !0
}
},
n = function(a) {
return function() {
a[h](), a[j](), a.stopped = !0
}
},
o = function(a, b, c) {
var d, e;
for (d = c.length; d--;) e = c[d], !(e in b) && e in a && (b[e] = a[e])
};
return function(p, u) {
var v = {
originalEvent: p,
isNative: u
};
if (!p) return v;
var w, x = p.type,
y = p.target || p.srcElement;
v[h] = i(p), v[j] = k(p), v.stop = n(v), v.target = y && y.nodeType === 3 ? y.parentNode : y;
if (u) {
if (x.indexOf("key") !== -1) w = d, v.keyCode = p.which || p.keyCode;
else if (q.test(x)) {
w = b, v.rightClick = p.which === 3 || p.button === 2, v.pos = {
x: 0,
y: 0
};
if (p.pageX || p.pageY) v.clientX = p.pageX, v.clientY = p.pageY;
else if (p.clientX || p.clientY) v.clientX = p.clientX + l.body.scrollLeft + m.scrollLeft, v.clientY = p.clientY + l.body.scrollTop + m.scrollTop;
e.test(x) && (v.relatedTarget = p.relatedTarget || p[(x === "mouseover" ? "from" : "to") + "Element"])
} else t.test(x) ? w = g : r.test(x) ? w = c : s.test(x) && (w = f);
o(p, v, w || a)
}
return v
}
}(),
y = function(a, b) {
return !n && !b && (a === l || a === c) ? m : a
},
z = function() {
function a(a, b, c, d, e) {
this.element = a, this.type = b, this.handler = c, this.original = d, this.namespaces = e, this.custom = w[b], this.isNative = v[b] && a[o], this.eventType = n || this.isNative ? b : "propertychange", this.customType = !n && !this.isNative && b, this.target = y(a, this.isNative), this.eventSupport = this.target[o]
}
a.prototype = {
inNamespaces: function(a) {
var b, c;
if (!a) return !0;
if (!this.namespaces) return !1;
for (b = a.length; b--;) for (c = this.namespaces.length; c--;) if (a[b] === this.namespaces[c]) return !0;
return !1
},
matches: function(a, b, c) {
return this.element === a && (!b || this.original === b) && (!c || this.handler === c)
}
};
return a
}(),
A = function() {
var a = {},
b = function(c, d, e, f, g) {
if (!d || d === "*") for (var h in a) h.charAt(0) === "$" && b(c, h.substr(1), e, f, g);
else {
var i = 0,
j, k = a["$" + d],
l = c === "*";
if (!k) return;
for (j = k.length; i < j; i++) if (l || k[i].matches(c, e, f)) if (!g(k[i], k, i, d)) return
}
},
c = function(b, c, d) {
var e, f = a["$" + c];
if (f) for (e = f.length; e--;) if (f[e].matches(b, d, null)) return !0;
return !1
},
d = function(a, c, d) {
var e = [];
b(a, c, d, null, function(a) {
return e.push(a)
});
return e
},
e = function(b) {
(a["$" + b.type] || (a["$" + b.type] = [])).push(b);
return b
},
f = function(c) {
b(c.element, c.type, null, c.handler, function(b, c, d) {
c.splice(d, 1), c.length === 0 && delete a["$" + b.type];
return !1
})
},
g = function() {
var b, c = [];
for (b in a) b.charAt(0) === "$" && (c = c.concat(a[b]));
return c
};
return {
has: c,
get: d,
put: e,
del: f,
entries: g
}
}(),
B = n ?
function(a, b, c, d) {
a[d ? h : j](b, c, !1)
} : function(a, b, c, d, e) {
e && d && a["_on" + e] === null && (a["_on" + e] = 0), a[d ? i : k]("on" + b, c)
}, C = function(a, b, d) {
return function(e) {
e = x(e || ((this.ownerDocument || this.document || this).parentWindow || c).event, !0);
return b.apply(a, [e].concat(d))
}
}, D = function(a, b, d, e, f, g) {
return function(h) {
if (e ? e.apply(this, arguments) : n ? !0 : h && h.propertyName === "_on" + d || !h) h && (h = x(h || ((this.ownerDocument || this.document || this).parentWindow || c).event, g)), b.apply(a, h && (!f || f.length === 0) ? arguments : p.call(arguments, h ? 0 : 1).concat(f))
}
}, E = function(a, b, c, d, e) {
return function() {
a(b, c, e), d.apply(this, arguments)
}
}, F = function(a, b, c, d) {
var e, f, h, i = b && b.replace(g, ""),
j = A.get(a, i, c);
for (e = 0, f = j.length; e < f; e++) j[e].inNamespaces(d) && ((h = j[e]).eventSupport && B(h.target, h.eventType, h.handler, !1, h.type), A.del(h))
}, G = function(a, b, c, d, e) {
var h, i = b.replace(g, ""),
j = b.replace(f, "").split(".");
if (A.has(a, i, c)) return a;
i === "unload" && (c = E(F, a, i, c, d)), w[i] && (w[i].condition && (c = D(a, c, i, w[i].condition, !0)), i = w[i].base || i), h = A.put(new z(a, i, c, d, j[0] && j)), h.handler = h.isNative ? C(a, h.handler, e) : D(a, h.handler, i, !1, e, !1), h.eventSupport && B(h.target, h.eventType, h.handler, !0, h.customType)
}, H = function(a, b, c) {
return function(d) {
var e, f, g = typeof a == "string" ? c(a, this) : a;
for (e = d.target; e && e !== this; e = e.parentNode) for (f = g.length; f--;) if (g[f] === e) return b.apply(e, arguments)
}
}, I = function(a, b, c) {
var d, e, h, i, j, k = F,
l = b && typeof b == "string";
if (l && b.indexOf(" ") > 0) {
b = b.split(" ");
for (j = b.length; j--;) I(a, b[j], c);
return a
}
h = l && b.replace(g, ""), h && w[h] && (h = w[h].type);
if (!b || l) {
if (i = l && b.replace(f, "")) i = i.split(".");
k(a, h, c, i)
} else if (typeof b == "function") k(a, null, b);
else for (d in b) b.hasOwnProperty(d) && I(a, d, b[d]);
return a
}, J = function(a, b, c, d, e) {
var f, g, h, i, j = c,
k = c && typeof c == "string";
if (b && !c && typeof b == "object") for (f in b) b.hasOwnProperty(f) && J.apply(this, [a, f, b[f]]);
else {
i = arguments.length > 3 ? p.call(arguments, 3) : [], g = (k ? c : b).split(" "), k && (c = H(b, j = d, e)) && (i = p.call(i, 1)), this === u && (c = E(I, a, b, c, j));
for (h = g.length; h--;) G(a, g[h], c, j, i)
}
return a
}, K = function() {
return J.apply(u, arguments)
}, L = n ?
function(a, b, d) {
var e = l.createEvent(a ? "HTMLEvents" : "UIEvents");
e[a ? "initEvent" : "initUIEvent"](b, !0, !0, c, 1), d.dispatchEvent(e)
} : function(a, b, c) {
c = y(c, a), a ? c.fireEvent("on" + b, l.createEventObject()) : c["_on" + b]++
}, M = function(a, b, c) {
var d, e, h, i, j, k = b.split(" ");
for (d = k.length; d--;) {
b = k[d].replace(g, "");
if (i = k[d].replace(f, "")) i = i.split(".");
if (!i && !c && a[o]) L(v[b], b, a);
else {
j = A.get(a, b), c = [!1].concat(c);
for (e = 0, h = j.length; e < h; e++) j[e].inNamespaces(i) && j[e].handler.apply(a, c)
}
}
return a
}, N = function(a, b, c) {
var d = 0,
e = A.get(b, c),
f = e.length;
for (; d < f; d++) e[d].original && J(a, e[d].type, e[d].original);
return a
}, O = {
add: J,
one: K,
remove: I,
clone: N,
fire: M,
noConflict: function() {
b[a] = d;
return this
}
};
if (c[i]) {
var P = function() {
var a, b = A.entries();
for (a in b) b[a].type && b[a].type !== "unload" && I(b[a].element, b[a].type);
c[k]("onunload", P), c.CollectGarbage && c.CollectGarbage()
};
c[i]("onunload", P)
}
return O
})
}, require_modules[18] = function(a, b, c) {
var d = this;
!
function(a, c) {
typeof define == "function" ? define(c) : typeof b != "undefined" ? b.exports = c() : this[a] = c()
}("qwery", function() {
function ba(a, c) {
var d = _(c);
if (!d || !a) return [];
if (a === window || Y(a)) return !c || a !== window && Y(d) && bb(a, d) ? [a] : [];
if (a && $(a)) return R(a);
if (i = a.match(x)) return (n = b.getElementById(i[1])) ? [n] : [];
if (i = a.match(z)) return R(d.getElementsByTagName(i[1]));
return bd(a, d)
}
function _(a) {
if (!a) return b;
if (typeof a == "string") return ba(a)[0];
if ($(a)) return a[0];
return a
}
function $(a) {
return typeof a == "object" && isFinite(a.length)
}
function Z(a) {
var b = [],
c, d;
label: for (c = 0; c < a.length; c++) {
for (d = 0; d < b.length; d++) if (b[d] == a[c]) continue label;
b[b.length] = a[c]
}
return b
}
function Y(a) {
return a && a.nodeType && (a.nodeType == 1 || a.nodeType == 9)
}
function X(a) {
var c = [],
d = [],
e, f = 0,
g, h, i, j, k, l, m, n, o, q, r, s = Q.g(a) || Q.s(a, a.split(J)),
t = a.match(I),
u;
s = s.slice(0);
if (!s.length) return c;
k = s.pop(), n = s.length && (i = s[s.length - 1].match(x)) ? b.getElementById(i[1]) : b;
if (!n) return c;
o = T(k), m = t && /^[+~]$/.test(t[t.length - 1]) ?
function(a) {
while (n = n.nextSibling) n.nodeType == 1 && (o[1] ? o[1] == n.tagName.toLowerCase() : 1) && a.push(n);
return a
}([]) : n.getElementsByTagName(o[1] || "*");
for (e = 0, h = m.length; e < h; e++) if (q = U.apply(m[e], o)) c[f++] = q;
if (!s.length) return c;
for (f = 0, h = c.length, g = 0; f < h; f++) {
j = c[f];
for (e = s.length; e--;) while (j = L[t[e]](j, c[f])) if (p = U.apply(j, T(s[e]))) break;
p && (d[g++] = c[f])
}
return d
}
function W(a, b, c) {
switch (a) {
case "=":
return b == c;
case "^=":
return b.match(P.g("^=" + c) || P.s("^=" + c, new RegExp("^" + V(c))));
case "$=":
return b.match(P.g("$=" + c) || P.s("$=" + c, new RegExp(V(c) + "$")));
case "*=":
return b.match(P.g(c) || P.s(c, new RegExp(V(c))));
case "~=":
return b.match(P.g("~=" + c) || P.s("~=" + c, new RegExp("(?:^|\\s+)" + V(c) + "(?:\\s+|$)")));
case "|=":
return b.match(P.g("|=" + c) || P.s("|=" + c, new RegExp("^" + V(c) + "(-|$)")))
}
return 0
}
function V(a) {
return O.g(a) || O.s(a, a.replace(E, "\\$1"))
}
function U(a, b, c, d, f, g, h, i, k, l, m) {
var n, o, p;
if (b && this.tagName.toLowerCase() !== b) return !1;
if (c && (n = c.match(v)) && n[1] !== this.id) return !1;
if (c && (q = c.match(w))) for (e = q.length; e--;) {
o = q[e].slice(1);
if (!(N.g(o) || N.s(o, new RegExp("(^|\\s+)" + o + "(\\s+|$)"))).test(this.className)) return !1
}
if (k && ba.pseudos[k] && !ba.pseudos[k](this, m)) return !1;
if (d && !h) {
j = this.attributes;
for (p in j) if (Object.prototype.hasOwnProperty.call(j, p) && (j[p].name || p) == f) return this
}
if (d && !W(g, this.getAttribute(f) || "", h)) return !1;
return this
}
function T(a) {
return a.match(K)
}
function S(a) {
while (a = a.previousSibling) if (a.nodeType == 1) break;
return a
}
function R(a) {
l = [];
for (e = 0, h = a.length; e < h; e++) $(a[e]) ? l = l.concat(a[e]) : l.push(a[e]);
return l
}
function M() {
this.c = {}
}
var a = this,
b = document,
c = a.qwery,
d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u = b.documentElement,
v = /#([\w\-]+)/,
w = /\.[\w\-]+/g,
x = /^#([\w\-]+$)/,
y = /^\.([\w\-]+)$/,
z = /^([\w\-]+)$/,
A = /^([\w]+)?\.([\w\-]+)$/,
B = /\s*([\s\+\~>])\s*/g,
C = /[\s\>\+\~]/,
D = /(?![\s\w\-\/\?\&\=\:\.\(\)\!,@#%<>\{\}\$\*\^'"]*\]|[\s\w\+\-]*\))/,
E = /([.*+?\^=!:${}()|\[\]\/\\])/g,
F = /^([a-z0-9]+)?(?:([\.\#]+[\w\-\.#]+)?)/,
G = /\[([\w\-]+)(?:([\|\^\$\*\~]?\=)['"]?([ \w\-\/\?\&\=\:\.\(\)\!,@#%<>\{\}\$\*\^]+)["']?)?\]/,
H = /:([\w\-]+)(\(['"]?([\s\w\+\-]+)['"]?\))?/,
I = new RegExp("(" + C.source + ")" + D.source, "g"),
J = new RegExp(C.source + D.source),
K = new RegExp(F.source + "(" + G.source + ")?" + "(" + H.source + ")?"),
L = {
" ": function(a) {
return a && a !== u && a.parentNode
},
">": function(a, b) {
return a && a.parentNode == b.parentNode && a.parentNode
},
"~": function(a) {
return a && a.previousSibling
},
"+": function(a, b, c, d) {
if (!a) return !1;
c = S(a), d = S(b);
return c && d && c == d && c
}
};
M.prototype = {
g: function(a) {
return this.c[a] || undefined
},
s: function(a, b) {
this.c[a] = b;
return b
}
};
var N = new M,
O = new M,
P = new M,
Q = new M,
bb = "compareDocumentPosition" in u ?
function(a, b) {
return (b.compareDocumentPosition(a) & 16) == 16
} : "contains" in u ?
function(a, c) {
c = c == b || c == window ? u : c;
return c !== a && c.contains(a)
} : function(a, b) {
while (a = a.parentNode) if (a === b) return 1;
return 0
}, bc = function() {
if (!b.querySelector || !b.querySelectorAll) return !1;
try {
return b.querySelectorAll(":nth-of-type(1)").length
} catch (a) {
return !1
}
}(), bd = bc ?
function(a, c) {
return b.getElementsByClassName && (i = a.match(y)) ? R(c.getElementsByClassName(i[1])) : R(c.querySelectorAll(a))
} : function(a, c) {
a = a.replace(B, "$1");
var d = [],
e, g, j = [],
k;
if (i = a.match(A)) {
s = c.getElementsByTagName(i[1] || "*"), l = N.g(i[2]) || N.s(i[2], new RegExp("(^|\\s+)" + i[2] + "(\\s+|$)"));
for (k = 0, h = s.length, f = 0; k < h; k++) l.test(s[k].className) && (d[f++] = s[k]);
return d
}
for (k = 0, s = a.split(","), h = s.length; k < h; k++) j[k] = X(s[k]);
for (k = 0, h = j.length; k < h && (g = j[k]); k++) {
var m = g;
if (c !== b) {
m = [];
for (f = 0, i = g.length; f < i && (e = g[f]); f++) bb(e, c) && m.push(e)
}
d = d.concat(m)
}
return Z(d)
};
ba.uniq = Z, ba.pseudos = {}, ba.noConflict = function() {
a.qwery = c;
return this
};
return ba
})
}, require_modules[19] = function(a, b, c) {
var d = this,
e = c(4),
f = c(1),
g = {},
h = /^sc\-/,
i = function(a) {
return "sc-" + a
},
j = {
set: function(a, b, c) {
a = i(a), b = c ? b : JSON.stringify(b), g[a] = b;
if (e.sessionStorage) try {
sessionStorage.setItem(a, b)
} catch (d) {
this.clearOldest(3), this.set(a, b)
}
},
get: function(a, b) {
a = i(a);
var c = g[a] || e.sessionStorage && sessionStorage.getItem(a) || undefined;
c && !b && (c = JSON.parse(c));
return c
},
remove: function(a, b) {
a = b ? a : i(a), delete g[a], e.sessionStorage && sessionStorage.removeItem(a)
},
clearKeys: function(a) {
function c(a, c) {
var d;
for (d in a) a.hasOwnProperty(d) && d.search(c) > -1 && b.remove(d, !0)
}
var b = this;
c(g, a), e.sessionStorage && c(sessionStorage, a)
},
clear: function() {
if (e.sessionStorage) {
var a = [],
b;
for (b in sessionStorage) sessionStorage.hasOwnProperty(b) && (a[a.length] = b);
f.each(a, function(a) {
h.test(a) && sessionStorage.removeItem(a)
})
}
g = {}
},
clearOldest: function(a) {
var b, c;
a = a || 1;
for (b = sessionStorage.length, c = Math.min(b - a, 0); b > c; b--) sessionStorage.removeItem(sessionStorage.key(b))
}
};
b.exports = j
}, require_modules[20] = function(a, b, c) {
var d = this,
e = c(8),
f = function() {},
g = e.getUrlParams().debug === "true",
h = {
log: f,
warn: f
};
g && typeof console != "undefined" && (typeof console.log != "undefined" && console.log.apply && (h.log = function() {
return console.log.apply(console, arguments)
}), typeof console.warn != "undefined" && console.warn.apply && (h.warn = function() {
return console.warn.apply(console, arguments)
})), b.exports = h
}, require_modules[21] = function(a, b, c) {
function v(a, b) {
while (a.length) {
var c = a.pop();
e.isFunction(c) ? c(q.access_token) : c[b ? "error" : "success"](q.access_token)
}
}
var d = this,
e = c(1),
f = c(13),
g = c(2),
h = c(4),
i = c(3).api,
j = c(22),
k = "access_token",
l = "scope",
m = "callback.html",
n = h.localStorage,
o = n && j("connect"),
p = location,
q = {},
r = [],
s = [],
t = !1,
u;
o && o.onChange(function(a) {
u.setConnectConfig(o.data)
}), u = b.exports = {
connect: function(a) {
a = a || {};
var b = a.success || g.noop,
c = a.error || g.noop,
d = this.getAccessToken();
if (d) setTimeout(function() {
b(d)
}, 1);
else {
r.push({
success: b,
error: c
});
if (!t) {
t = !0;
var e = {
response_type: "token",
display: "popup",
scope: "non-expiring playcount",
client_id: i.clientID,
redirect_uri: p.protocol + "//" + p.host + p.pathname + m
},
h = "https://soundcloud.com/connect?" + f.toQueryString(e),
j = window.open(h, "connect", "resizable=no,scrollbars=no,status=no,width=360,height=450");
(function a() {
(!j || j.closed) && !q.access_token ? (t = !1, v(r, !0)) : j.closed || setTimeout(a, 250)
})()
}
}
},
getAccessToken: function() {
return q.access_token || n ? o.get(k) : null
},
getAccessTokenScope: function() {
return q.scope || n ? o.get(l) : null
},
setConnectConfig: function(a) {
q = a, n && (o.set(k, a.access_token), o.set(l, a.scope)), v(r), v(s)
},
onToken: function(a) {
var b = this.getAccessToken();
b ? setTimeout(function() {
a(b)
}, 1) : s.push(a)
}
}
}, require_modules[22] = function(a, b, c) {
function h(a) {
try {
localStorage.setItem(a.namespace, JSON.stringify(a.data));
return !0
} catch (b) {
a.clear();
return !1
}
}
function g(a, b) {
var c = function(c) {
c.key === a && b.call(null, c)
};
window.addEventListener ? window.addEventListener("storage", c, !1) : document.attachEvent("onstorage", c)
}
function f(a) {
return JSON.parse(localStorage.getItem(a) || "{}")
}
var d = this,
e = c(2),
i = function(a) {
this.namespace = a, this.data = f(a);
var b = this;
g(this.namespace, function() {
b.data = f(a)
})
};
i.prototype = {
constructor: i,
get: function(a) {
return this.data[a]
},
set: function(a, b) {
this.data[a] !== b && (this.data[a] = b, h(this) || this.remove(a));
return b
},
clear: function() {
this.data = {}, h(this)
},
remove: function(a) {
delete this.data[a], h(this)
},
onChange: function(a) {
a && e.isFunction(a) && g(this.namespace, a)
}
}, b.exports = function(a) {
return new i(a)
}
}, require_modules[23] = function(a, b, c) {
function r(b) {
a.SC.bootConf = f.extend(o, b)
}
function q() {
var a = g.getUrlParams().debug;
a = a === "true" ? !0 : a === "false" ? !1 : undefined, a = typeof a == "undefined" ? o.debug : a;
return f.extend(o, {
debug: a
})
}
function n(a) {
var b = a + location.search,
c = f.supplant(i, {
flashPlayerSrc: b
}),
d = document.getElementById("widget");
d.className += " noBorders", d.innerHTML = c
}
var d = this,
e = c(24),
f = c(2),
g = c(8),
h = c(4),
i = c(27),
j = c(3);
a.SC = a.SC || {};
var k = "bootstrapper",
l = "dev",
m = location,
o = f.extend({}, j.bootstrapper),
p = {
start: function(a) {
if (a.flashVersion || !h.newWidget) n(o.flashPlayerUrl);
else {
a.showComments !== undefined && (window.loadCommentsFromAPI = a.showComments), j.clearSessionStorage && h.sessionStorage && sessionStorage.clear();
var b = new e({
namespace: k,
debugMode: a.debug,
version: a.version || l,
js: "//" + m.host + m.pathname + a.appJs + (a.debug ? "" : "?" + a.version)
})
}
}
};
d.Bootstrapper = p, d.getBootstrapperConfig = q, d.setBootstrapperConfig = r, f.extend(a.SC, d), r(a.SC.bootConf || {})
}, require_modules[24] = function(a, b, c) {
var d = this,
e = c(25),
f = c(22),
g = c(20).log,
h = c(2),
i = c(4),
j = window,
k = document,
l = k.head || k.getElementsByTagName("head")[0],
m = i.localStorage,
n = "status",
o = "version",
p = 0,
q = 1,
r = 2,
s = 7e3,
t = b.exports = function(a) {
this.options = a, this.debugMode = a.hasOwnProperty("debugMode") ? a.debugMode : !1, this.async = a.hasOwnProperty("async") ? a.async : !0, this.createScriptTag = a.hasOwnProperty("createScriptTag") ? a.createScriptTag : !0, this.initLocalStorage();
var b = m ? this.storage.get(n) : undefined;
this.status = b ? b : p, this.areResourcesLoaded() ? (g("resources for %s (version: %s) are already loaded and are in local storage", this.options.namespace, this.options.version), this.onAllResourcesLoaded(!0)) : (g("loading resources for %s (version: %s) in %s mode", this.options.namespace, this.options.version, this.async ? "async" : "sync"), this.load())
};
t.prototype = {
constructor: t,
updateStatus: function(a) {
this.status = a, m && this.storage.set(n, this.status)
},
initLocalStorage: function() {
if (m) {
var a = this;
this.storage = f(this.options.namespace), this.debugMode && this.storage.clear(), this.storage.onChange(function() {
var b = a.storage.get(n);
a.status !== b && (a.updateStatus(a.storage.get(n)), a.status === r && a.onAllResourcesLoaded())
})
}
},
areResourcesLoaded: function() {
return m ? this.storage.get(n) === r && this.storage.get(o) === this.options.version : !1
},
load: function() {
var a = this,
b = this.options;
if (m) {
g("loader status for " + b.namespace + " = " + this.status);
if (this.status === q && this.storage.get(o) === b.version) {
g("waiting until resources are loaded in another iframe"), setTimeout(function() {
a.status !== r && (g("resources in another iframe/tab are not loaded for some reason"), a.status = p, a.load())
}, s);
return
}
this.status !== r && (this.updateStatus(q), this.storage.set(o, b.version))
}
var c = new e({
css: this.options.css,
js: this.options.js,
async: this.async,
callback: function(c) {
a.resources = c;
if (m) {
var d;
for (d in c) c.hasOwnProperty(d) && a.storage.set(d, c[d]);
a.storage.set(n, r), a.storage.set(o, b.version)
}
a.onAllResourcesLoaded()
}
})
},
onAllResourcesLoaded: function(a) {
this.activateResources(), this.options.callback && h.isFunction(this.options.callback) && this.options.callback.call(null, a)
},
activateResources: function() {
this.areResourcesActivated || (this.areResourcesActivated = !0, this.options.css && this.activateResource("css", m ? this.storage.get("css") : this.resources.css), this.options.js && this.activateResource("js", m ? this.storage.get("js") : this.resources.js))
},
activateResource: function(a, b) {
switch (a) {
case "css":
this.addStyles(b);
break;
case "js":
this.globalEval(b)
}
},
globalEval: function(a) {
if (this.debugMode && this.createScriptTag) {
var b = k.createElement("script");
b.setAttribute("type", "text/javascript"), b.setAttribute("async", "async"), b.setAttribute("src", this.options.js), l.appendChild(b)
} else(j.execScript ||
function(a) {
j.eval.call(j, a)
})(a)
},
addStyles: function(a) {
a = this.postProcessStylesContent(a);
var b = k.createElement("style");
b.setAttribute("type", "text/css"), l.appendChild(b), this.appendStyles(b, a)
},
postProcessStylesContent: function(a) {
if (this.options.postProcessStyles) return this.options.postProcessStyles.call(null, a);
return a
},
appendStyles: function(a, b) {
a.styleSheet ? a.styleSheet.cssText = b : (h.emptyElement(a), a.appendChild(k.createTextNode(b)))
}
}
}, require_modules[25] = function(a, b, c) {
function f(a) {
return !!(a && a.constructor && a.call && a.apply)
}
var d = this,
e = c(26),
g = b.exports = function(a) {
this.options = a, this.loaded = [], this.toBeLoaded = function() {
var b = [];
a.css && b.push({
type: "css",
url: a.css
}), a.js && b.push({
type: "js",
url: a.js
});
return b
}(), this.load()
};
g.prototype = {
constructor: g,
load: function() {
if (this.toBeLoaded.length === this.loaded.length) this.onAllResourcesLoaded();
else {
var a, b;
for (a = 0, b = this.toBeLoaded.length; a < b; a++) this.loadResource(this.toBeLoaded[a])
}
},
loadResource: function(a) {
var b = this,
c;
c = e.get({
url: a.url,
async: this.options.hasOwnProperty("async") ? this.options.async : !1,
success: function(c) {
b.loaded.push({
type: a.type,
content: c
}), b.loaded.length === b.toBeLoaded.length && b.onAllResourcesLoaded()
},
error: function() {
try {
c.abort()
} catch (d) {}
b.loadResource(a)
}
})
},
loadScript: function(a, b) {
var c = document,
d = c.createElement("script");
d.type = "text/javascript", d.src = a, d.async = !0, d.onload = d.onreadystatechange = function() {
var a = d.readyState;
if (!a || /loaded|complete/.test(a)) b && !b.isExecuted && (b.isExecuted = !0, b()), d.onload = d.onreadystatechange = null
}, (c.head || c.body).appendChild(d)
},
onAllResourcesLoaded: function() {
if (f(this.options.callback)) {
var a = {},
b, c;
for (b = 0, c = this.loaded.length; b < c; b++) {
var d = this.loaded[b];
a[d.type] = d.content
}
this.options.callback.call(null, a)
}
}
}
}, require_modules[26] = function(a, b, c) {
var d = this,
e = c(2),
f = e.isFunction,
g = function() {
return window.ActiveXObject ? new ActiveXObject("Microsoft.XMLHTTP") : window.XMLHttpRequest ? new XMLHttpRequest : !1
},
h = function(a, b) {
var c = g(),
d;
if ( !! c) {
d = function() {
c.status >= 200 && c.status < 300 || c.status === 304 ? f(b.success) && b.success.call(null, c.responseText) : f(b.error) && b.error.call(null, c)
}, c.open(a, b.url, b.hasOwnProperty("async") ? b.async : !0), c.onreadystatechange = function() {
c.readyState === 4 && d()
};
if (a === "GET") c.send(null), b.async === !1 && d();
else if (a === "POST") {
c.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
var e = [],
h = b.data,
i;
for (i in h) h.hasOwnProperty(i) && e.push(encodeURIComponent(i) + "=" + encodeURIComponent(h[i]));
c.send(e.join("&"))
}
return c
}
};
b.exports = {
get: function(a) {
return h("GET", a)
},
post: function(a) {
h("POST", a)
}
}
}, require_modules[27] = function(a, b, c) {
var d = this;
b.exports = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="100%" height="100%" id="flashwidget"><param name="movie" value="{flashPlayerSrc}"> </param><param name="allowscriptaccess" value="always"> </param><embed src="{flashPlayerSrc}" type="application/x-shockwave-flash" allowscriptaccess="always" width="100%" height="100%"> </embed></object>'
}, require_modules[28] = function(a, b, c) {
var d = this;
1;
var e = c(13),
f = c(1),
g = c(11),
h = c(4),
i = c(29).View,
j = c(29).Events,
k = c(37),
l = c(41),
m = c(42).ListViewEvents,
n = c(44),
o = c(47),
p = c(46).SoundManager,
q = c(48).Events,
r = c(56).View,
s = c(57).View,
t = c(58).View,
u = c(59).View,
v = c(60),
w = c(68).View,
x = c(68).Events,
y = c(69),
z = c(70).List,
A = c(73),
B = c(75).Events,
C = c(79).View,
D = c(79).Events,
E = c(81).View,
F = c(81).Model,
G = c(62),
H = c(7),
I = c(87),
J = c(92).View,
K = c(92).Events,
L = c(94).View,
M = c(95).Model,
N = c(2),
O = {
COMMENT_DETAILS_VISIBLE: "COMMENT_DETAILS_VISIBLE_STATE",
SHARE_PANEL_VISIBLE: "SHARE_PANEL_VISIBLE_STATE",
WAVEFORM_HIGHLIGHTED: "WAVEFORM_HIGHLIGHTED_STATE"
},
P = d.Events = f.extend({}, j, {
SHARE_PANEL_OPENED: "sharePanelOpened.player",
DOWNLOAD_BUTTON_CLICKED: "downloadButtonClicked.player",
BUY_BUTTON_CLICKED: "buyButtonClicked.player",
SCRUBBER_CLICKED: "scrubberClicked.player",
LIKE_BUTTON_CLICKED: "likeButtonClicked.player"
}),
Q = d.View = i.createView("single-track", {
initialize: function() {
this.model.bind("change:is_favorite", f.bind(function() {
this.updateFavButton()
}, this));
var a = {};
a[q.PLAY] = this.onAudioStart, a[q.FINISH] = this.onAudioFinish, n.getInstance().addAudioEventListeners(this.model.get("id"), a, this), i.prototype.initialize.apply(this, arguments)
},
options: {
template: '<div class="singleTrack g-selection-text {{#url_show_artwork}}singleTrack__artworkMode{{/url_show_artwork}}">{{#available}}<div class="singleTrack__artworkContainer">{{>artwork}}</div><div class="singleTrack__content"><div class="singleTrack__upperPart"><div class="singleTrack__buttonContainerWrapper"><div class="singleTrack__buttonContainer">{{>player-button}}</div></div><div class="singleTrack__upperMainContent"><div class="singleTrack__titleContainer">{{>track-title}}</div><div class="singleTrack__buttons">{{#buyable}}<a class="singleTrack__buyButton g-button" href="{{purchase_url}}" target="_blank"><span>{{purchase_title}}</span></a>{{/buyable}}{{^buyable}}{{#downloadable}}<a class="singleTrack__downloadButton g-button" href="{{download_url}}" target="_blank"><span>Download</span></a>{{/downloadable}}{{/buyable}}{{#authSupported}}{{#url_liking}}<a class="singleTrack__favButton g-button" href="#"><span class="singleTrack__like">Like</span><span class="singleTrack__liked">Liked</span></a>{{/url_liking}}{{/authSupported}}</div>{{#shareable}}<a class="singleTrack__shareLink" href="{{permalink_url}}"><span class="g-share-icon">#</span> Share</a>{{/shareable}}</div></div><div class="singleTrack__mainContent g-border-top g-shadow-top"><div class="singleTrack__middleContent g-all-transition"><div class="singleTrack__waveformContainer g-opacity-transition">{{>waveform}}</div><div class="singleTrack__timelineCommentsContainer">{{>timeline-comments}}</div><div class="singleTrack__timeIndicatorContainer">{{>time-indicator}}</div><div class="singleTrack__scrubberContainer">{{>scrubber}}</div></div><div class="singleTrack__lowerPart g-border-top g-shadow-top"><div class="singleTrack__statsContainer">{{>track-stats}}</div><a class="singleTrack__permalink g-soundcloud-logo" href="{{#shareable}}{{permalink_url}}{{/shareable}}{{^shareable}}{{user_permalink_url}}{{/shareable}}" target="_blank" title="Listen on SoundCloud">#</a>{{#url_show_comments}}<div class="singleTrack__commentDetailsContainer"></div>{{/url_show_comments}}</div></div></div>{{#shareable}}<div class="singleTrack__sharePanelContainerWrapper g-top-transition"><div class="singleTrack__sharePanelContainer"></div></div>{{/shareable}}{{/available}}{{#waveform_url}}{{^available}}{{>error-message}}{{/available}}{{/waveform_url}}{{#server_error}}{{>error-message}}{{/server_error}}</div>',
elementCssClass: "singleTrack"
},
events: {
"click .singleTrack__permalink": "onPermalinkClick",
"mouseover .singleTrack__shareLink": "onShareLinkMouseOver",
"click .singleTrack__shareLink": "onShareLinkClick",
"click .singleTrack__scrubberContainer": "onScrubberContainerClick",
"mouseout .singleTrack__scrubberContainer": "onScrubberContainerHover",
"mouseover .singleTrack__scrubberContainer": "onScrubberContainerHover",
"click .singleTrack__buyButton": "onBuyButtonClick",
"click .singleTrack__favButton": "onFavButtonClick",
"click .singleTrack__downloadButton": "onDownloadButtonClick"
},
element2selector: {
playerButtonContainer: ".singleTrack__buttonContainer",
artworkContainer: ".singleTrack__artworkContainer",
waveformContainer: ".singleTrack__waveformContainer",
scrubberContainer: ".singleTrack__scrubberContainer",
timeIndicatorContainer: ".singleTrack__timeIndicatorContainer",
timelineCommentsContainer: ".singleTrack__timelineCommentsContainer",
playerCommentDetaislViewContainer: ".singleTrack__commentDetailsContainer",
sharePanelViewContainer: ".singleTrack__sharePanelContainer",
trackTitleContainer: ".singleTrack__titleContainer",
trackStatsContainer: ".singleTrack__statsContainer",
favButton: ".singleTrack__favButton"
},
cssClass2stateName: {
singleTrack__sharePanelState: O.SHARE_PANEL_VISIBLE,
singleTrack__waveformHighlightedState: O.WAVEFORM_HIGHLIGHTED
},
getAdditionalData: function() {
var a = i.prototype.getAdditionalData.apply(this, arguments);
return f.extend(a, {
singleTrack: !0
})
},
canBeRendered: function(a) {
if (!this.model.hasDataFromAPI && !this.options.isModelPopulated) return !1;
var b = this.model.getRtmpUrl() !== undefined,
c = this.options.isModelPopulated || a.embeddable_by === "all" || this.model.get("availableForThisDomain") !== undefined,
d = c && b;
d || (b || this.model.getStreamUrls(a, {
success: f.bind(function(a) {
this.model.setRtmpUrl(a.rtmp || null), a.rtmp && h.audio && n.getInstance() instanceof o ? n.useFlashPlayer(f.bind(function() {
this.render()
}, this)) : this.render()
}, this),
error: function() {
this.model.set({
rtmp_stream_url: null
}), this.render()
}
}), c || this.model.getDomainsLockings({
success: f.bind(function(b) {
this.model.set({
availableForThisDomain: this.model.isLockedDomain(a, document.referrer, b)
}), this.render()
}, this),
error: f.bind(function() {
this.model.set({
availableForThisDomain: !1
}), this.render()
}, this)
}));
return d
},
renderDecorate: function() {
var a = this.model.toJSON();
if ( !! a.available) {
this.comments = new z([], {
track: this.model,
count: this.model.toJSON().comment_count
}), this.model.setCommentsCollection(this.comments);
if (this.model.hasDataFromAPI || this.options.isModelPopulated) I.setTrack(a), I.start();
this.updateFavButton(a.is_favorite);
var b = G.putIntoUpperHalf(this.scrubberContainer(), this.waveformContainer()),
c = G.putIntoUpperHalf(this.timeIndicatorContainer(), this.waveformContainer()),
d = [
[r, this.playerButtonContainer(), "playerButtonView"],
[u, this.trackTitleContainer(), "trackTitleView"],
[t, this.trackStatsContainer(), "trackStatsView"],
[v, this.waveformContainer(), "waveformView"],
[w, b, "scrubberView"],
[y, c, "timeIndicatorView"]
];
f.each(d, function(a) {
this[a[2]] = this.initSubView({
component: a[0],
el: a[1]
})
}, this), this.initArtworkView(function(a) {
var b = N.mapSubFields({
user_details: a
}, a, "user_details_");
this.model.set(b), this.artworkView = this.initSubView({
component: s,
el: this.artworkContainer()
})
}), a.url_show_comments && this.comments.fetch({
success: f.bind(this.onSuccessfulCommentsFetching, this)
}), a.url_auto_play && n.getInstance().toggle(this.model.toJSON(), !0)
}
},
displaySharePanel: function() {
this.getState(O.SHARE_PANEL_VISIBLE) || (this.toggleState(O.SHARE_PANEL_VISIBLE, !0), this.initSharePanelView() && this.sharePanelView.contentView.onActiveState(), this.notifyDocument(P.SHARE_PANEL_OPENED))
},
hideSharePanel: function() {
this.toggleState(O.SHARE_PANEL_VISIBLE, !1)
},
onAudioStart: function() {
this.toggleState(O.WAVEFORM_HIGHLIGHTED, !1)
},
onAudioFinish: function() {
var a = this.commentDetailsView;
(!a || !a.isUserInteractingWithComments) && this.displaySharePanel()
},
updateFavButton: function(a) {
a = f.isUndefined(a) ? this.model.get("is_favorite") : a;
var b = H.isAlternativeContrastColor() ? "" : "singleTrack__highlighting",
c = "singleTrack__favButtonActive g-button-selected " + b;
f.each(c.split(" "), function(b) {
this.favButton().toggleClass(b, a)
}, this)
},
initArtworkView: function(a) {
var b = this,
c = this.options.userData;
if (c && c.length) return a.call(this, c);
var d = new M({
id: this.model.toJSON().user_id
});
d.fetch({
success: function() {
return a.call(b, d.toJSON())
}
})
},
initSharePanelView: function() {
if (!this.sharePanelView && !! this.model.toJSON().shareable) {
var a = this.sharePanelView = this.initSubView({
component: J,
contentViewComponent: E,
el: this.sharePanelViewContainer(),
model: new F(this.model.toJSON())
});
a.bind(K.CLOSE_BUTTON_CLICK, f.bind(this.hideSharePanel, this));
return a
}
},
onSuccessfulCommentsFetching: function() {
this.initTimelineCommentsView(), this.initCommentDetailsView();
if (this.timelineCommentsView) {
var a = this.commentDetailsView,
b = this.timelineCommentsView;
b.bind(B.MOUSE_MOVE, function(c) {
a.toggleAudioSync(!1);
if (!b.draggableAvatar || !b.draggableAvatar.zoomedIn) a.showCommentInput(c.timestamp, {
force: !0,
focusInput: !1
}), a.blurCommentInput()
});
var c = function(c) {
var d = b.offset,
e = a.offset,
f = d.top + G.getTopOffset(b.el),
g = d.left,
h = d.width;
(c.clientY < f || c.clientY > e.top + e.height || c.clientX < g || c.clientX > g + h) && (!b.draggableAvatar || !b.draggableAvatar.zoomedIn) && (!b.zoomableAvatar || !b.zoomableAvatar.zoomedIn) && a.cancelComment(), a.toggleAudioSync(!0)
};
a.bind(D.MOUSE_OUT, c), b.bind(B.MOUSE_OUT, c), b.bind(B.AVATAR_MOVE_END, function(b) {
a.showCommentInput(b.timestamp, {
force: !0
})
}), b.bind(B.AVATAR_MOVE, function(b) {
a.updatePlaceholder(b.timestamp), a.updatePointer(b.timestamp)
}), b.bind(B.CLICK, function(b) {
a.showCommentInput(b.timestamp, {
force: !0
}), setTimeout(function() {
a.commentInput()[0].focus()
}, 10)
}), b.bind(m.ITEM_CLICK, f.bind(function() {
a.showCommentDetails(this.comments.getCurrentCommentData(), {
force: !0
})
}, this)), a.bind(D.INPUT_ACTIVATED, f.bind(function(a) {
var c = this.timelineCommentsContainer().offset(),
d = c.left + c.width * (a / this.model.get("duration"));
b.showDraggableAvatar(d)
}, this)), a.bind(D.INPUT_DEACTIVATED, function() {
b.hideDraggableAvatar()
}), this.scrubberView.bind(x.CLICKED, function() {
!a.isUserInteractingWithComments && !a.commentValue && a.cancelComment()
})
}
},
initTimelineCommentsView: function() {
if (!this.timelineCommentsView) {
var a = this.timelineCommentsContainer();
h.canvas || G.putIntoLowerPart(a, this.waveformContainer()), this.timelineCommentsView = this.initSubView({
component: A,
el: a,
model: null,
track: this.model,
isCommentingEnabled: this.model.isCommentingEnabled(),
collection: this.comments
})
}
},
initCommentDetailsView: function() {
var a = this.commentDetailsView = this.initSubView({
el: this.playerCommentDetaislViewContainer(),
component: C,
model: new k({
current_user_avatar_url: l.avatarSrc(),
current_user_permalink: l.permalink(),
current_user_name: l.name()
}),
comments: this.comments,
track: this.model,
isCommentingEnabled: this.model.isCommentingEnabled()
});
a.hide()
},
onShareLinkMouseOver: function() {
h.touch || this.initSharePanelView()
},
onShareLinkClick: function(a) {
a.preventDefault(), this.displaySharePanel()
},
onPermalinkClick: function(a) {
a.stopPropagation()
},
onScrubberContainerHover: function(a) {
var b = a.type === "mouseover",
c = n.getInstance().isPlaying(),
d = b && !c;
this.toggleState(O.WAVEFORM_HIGHLIGHTED, d)
},
onScrubberContainerClick: function(a) {
a.stopPropagation();
var b = n.getInstance();
b.isPlaying() || (b.toggle(this.model.toJSON(), !0), this.notifyDocument(P.SCRUBBER_CLICKED))
},
onFavButtonClick: function(a) {
a.preventDefault(), this.model.toggleFavoriteStatus(), this.notifyDocument(P.LIKE_BUTTON_CLICKED)
},
onBuyButtonClick: function(a) {
this.notifyDocument(P.BUY_BUTTON_CLICKED)
},
onDownloadButtonClick: function(a) {
this.notifyDocument(P.DOWNLOAD_BUTTON_CLICKED)
}
})
}, require_modules[29] = function(a, b, c) {
var d = this,
e = c(11),
f = c(1),
g = c(13),
h = c(30),
i = c(32),
j = c(33),
k = c(34),
l = c(35),
m = c(36),
n = c(4),
o = c(5),
p = c(2),
q = c(7),
r = g(document),
s = d.Events = {
RENDER_DECORATE_EVENT: "renderDecorate.widget-view",
RENDER_EVENT: "render.widget-view"
},
t = d.View = e.View.extend(f.extend({}, j, k, {
initialize: function() {
var a = this;
this.$element = g(this.el), this.subViews = [], this.initStateHandlers(), this.initUIElementGetters(), this.model && (this.model.bind("change", f.bind(this.onModelChange, this)), this.render(), this.options.isModelPopulated || this.model.fetch({
success: function() {
a.model.hasDataFromAPI = !0, a.render()
},
error: function() {
a.render()
}
}))
},
observableAttributes: [],
cssClass2stateName: {},
initStateHandlers: function() {
this.stateHandlers = {}, f.each(this.cssClass2stateName, function(a, b) {
this.stateHandlers[a] = {
teardown: b,
setup: b
}
}, this)
},
element2selector: {},
initUIElementGetters: function() {
function b(a, b) {
return function() {
return this.$element.find(b)
}
}
var a = this.constructor.prototype;
f.each(this.element2selector, function(c, d) {
a[d] || (a[d] = b(d, c))
})
},
onModelChange: function() {
var a = f.keys(this.model.changedAttributes() || {}),
b = f.intersection(a, this.observableAttributes);
b.length && this.onObservableAttributeChange()
},
onObservableAttributeChange: function() {
this.render()
},
initSubView: function(a) {
a = f.extend({}, {
model: this.model,
collection: this.collection,
isModelPopulated: !0,
isCollectionPopulated: !0
}, a);
if ( !! a.el.length) {
var b = a.component,
c = new b(a);
c._parentView = this, this.subViews.push(c);
return c
}
},
disposeDecorate: function() {
f.each(this.subViews, function(a) {
a.dispose()
});
try {
this.undelegateEvents()
} catch (a) {}
delete this.el
},
getElement: function() {
var a = this.options.elementCssClass;
return a ? this.$element.hasClass(a) ? this.$element : g(this.$element.find("." + a)[0]) : this.$element
},
hide: function() {
this.$element.hide()
},
show: function() {
this.$element.show()
},
postProcessSVGElements: function(a) {
if (n.svg && !n.inlineSVG) {
var b = a.find("svg");
if (b.length) {
var c = new XMLSerializer;
f.each(b, function(a) {
var b = c.serializeToString(a),
d = l.parseFromString(b);
g(a).before(d), g(a).remove()
})
}
}
return a
},
appendRenderedContent: function(a) {
var b = g(a);
b = this.postProcessSVGElements(b), n.vml && a.indexOf("<v:") > -1 && m.addVMLNamespaces(), this.$element.empty().append(b)
},
getAdditionalData: function() {
return f.extend(i, n, o, q.getColorParams() || {})
},
canBeRendered: function() {
return !0
},
render: function(a) {
a = a || this.model.toJSON(), f.extend(a, this.getAdditionalData());
if (this.model && this.model.get("permalink_url") && p.isUIWebView() && !document.referrer) document.location = this.model.get("permalink_url").replace("http://", "http://m.");
else {
if (!this.canBeRendered(a)) return;
var b = h.render(this.options.template, a);
this.appendRenderedContent(b), this.trigger(s.RENDER_EVENT), (!this.model || this.options.isModelPopulated || this.model.hasDataFromAPI) && this.renderDecorate(a), this.trigger(s.RENDER_DECORATE_EVENT, a);
return this
}
},
renderDecorate: function() {},
notifyDocument: function(a, b) {
r.trigger(a, [a, b || this.model.toJSON(), this])
}
})),
u = function(a) {
var b = this.extend.apply(this, f.toArray(arguments).slice(1)),
c = b.prototype,
d = c.options || {},
e = h.addTemplate;
c.typeName = a, b.createView = u, e(a, d.template || ""), f.each(d.partials || {}, function(a, b) {
e(b, a)
});
return b
};
t.createView = u, t.extend = function() {
var a = e.View.extend.apply(this, arguments);
a.createView = u;
return a
}
}, require_modules[30] = function(a, b, c) {
var d = this,
e = c(31),
f = {},
g = {},
h = b.exports = {
getTemplate: function(a) {
return g[a]
},
addTemplate: function(a, b) {
g[a] = f[a] = b
},
render: function(a, b) {
return e.to_html(a, b, f)
}
}
}, require_modules[31] = function(a, b, c) {
var d = this,
e = b.exports = function() {
var a = {},
b = function() {};
b.prototype = {
otag: "{{",
ctag: "}}",
pragmas: {},
buffer: [],
pragmas_implemented: {
"IMPLICIT-ITERATOR": !0
},
context: {},
render: function(a, b, c, d) {
d || (this.context = b, this.buffer = []);
if (!this.includes("", a)) {
if (d) return a;
this.send(a)
} else {
a = this.render_pragmas(a);
var e = this.render_section(a, b, c);
e === !1 && (e = this.render_tags(a, b, c, d));
if (d) return e;
this.sendLines(e)
}
},
send: function(a) {
a !== "" && this.buffer.push(a)
},
sendLines: function(a) {
if (a) {
var b = a.split("\n");
for (var c = 0; c < b.length; c++) this.send(b[c])
}
},
render_pragmas: function(a) {
if (!this.includes("%", a)) return a;
var b = this,
c = this.getCachedRegex("render_pragmas", function(a, b) {
return new RegExp(a + "%([\\w-]+) ?([\\w]+=[\\w]+)?" + b, "g")
});
return a.replace(c, function(a, c, d) {
if (!b.pragmas_implemented[c]) throw {
message: "This implementation of mustache doesn't understand the '" + c + "' pragma"
};
b.pragmas[c] = {};
if (d) {
var e = d.split("=");
b.pragmas[c][e[0]] = e[1]
}
return ""
})
},
render_partial: function(a, b, c) {
a = this.trim(a);
if (!c || c[a] === undefined) throw {
message: "unknown_partial '" + a + "'"
};
if (typeof b[a] != "object") return this.render(c[a], b, c, !0);
return this.render(c[a], b[a], c, !0)
},
render_section: function(a, b, c) {
if (!this.includes("#", a) && !this.includes("^", a)) return !1;
var d = this,
e = this.getCachedRegex("render_section", function(a, b) {
return new RegExp("^([\\s\\S]*?)" + a + "(\\^|\\#)\\s*(.+)\\s*" + b + "\n*([\\s\\S]*?)" + a + "\\/\\s*\\3\\s*" + b + "\\s*([\\s\\S]*)$", "g")
});
return a.replace(e, function(a, e, f, g, h, i) {
var j = e ? d.render_tags(e, b, c, !0) : "",
k = i ? d.render(i, b, c, !0) : "",
l, m = d.find(g, b);
f === "^" ? !m || d.is_array(m) && m.length === 0 ? l = d.render(h, b, c, !0) : l = "" : f === "#" && (d.is_array(m) ? l = d.map(m, function(a) {
return d.render(h, d.create_context(a), c, !0)
}).join("") : d.is_object(m) ? l = d.render(h, d.create_context(m), c, !0) : typeof m == "function" ? l = m.call(b, h, function(a) {
return d.render(a, b, c, !0)
}) : m ? l = d.render(h, b, c, !0) : l = "");
return j + l + k
})
},
render_tags: function(a, b, c, d) {
var e = this,
f = function() {
return e.getCachedRegex("render_tags", function(a, b) {
return new RegExp(a + "(=|!|>|\\{|%)?([^\\/#\\^]+?)\\1?" + b + "+", "g")
})
},
g = f(),
h = function(a, d, h) {
switch (d) {
case "!":
return "";
case "=":
e.set_delimiters(h), g = f();
return "";
case ">":
return e.render_partial(h, b, c);
case "{":
return e.find(h, b);
default:
return e.escape(e.find(h, b))
}
},
i = a.split("\n");
for (var j = 0; j < i.length; j++) i[j] = i[j].replace(g, h, this), d || this.send(i[j]);
if (d) return i.join("\n")
},
set_delimiters: function(a) {
var b = a.split(" ");
this.otag = this.escape_regex(b[0]), this.ctag = this.escape_regex(b[1])
},
escape_regex: function(a) {
if (!arguments.callee.sRE) {
var b = ["/", ".", "*", "+", "?", "|", "(", ")", "[", "]", "{", "}", "\\"];
arguments.callee.sRE = new RegExp("(\\" + b.join("|\\") + ")", "g")
}
return a.replace(arguments.callee.sRE, "\\$1")
},
find: function(a, b) {
function c(a) {
return a === !1 || a === 0 || a
}
a = this.trim(a);
var d;
c(b[a]) ? d = b[a] : c(this.context[a]) && (d = this.context[a]);
if (typeof d == "function") return d.apply(b);
if (d !== undefined) return d;
return ""
},
includes: function(a, b) {
return b.indexOf(this.otag + a) != -1
},
escape: function(a) {
a = String(a === null ? "" : a);
return a.replace(/&(?!\w+;)|["'<>\\]/g, function(a) {
switch (a) {
case "&":
return "&";
case '"':
return """;
case "'":
return "'";
case "<":
return "<";
case ">":
return ">";
default:
return a
}
})
},
create_context: function(a) {
if (this.is_object(a)) return a;
var b = ".";
this.pragmas["IMPLICIT-ITERATOR"] && (b = this.pragmas["IMPLICIT-ITERATOR"].iterator);
var c = {};
c[b] = a;
return c
},
is_object: function(a) {
return a && typeof a == "object"
},
is_array: function(a) {
return Object.prototype.toString.call(a) === "[object Array]"
},
trim: function(a) {
return a.replace(/^\s*|\s*$/g, "")
},
map: function(a, b) {
if (typeof a.map == "function") return a.map(b);
var c = [],
d = a.length;
for (var e = 0; e < d; e++) c.push(b(a[e]));
return c
},
getCachedRegex: function(b, c) {
var d = a[this.otag];
d || (d = a[this.otag] = {});
var e = d[this.ctag];
e || (e = d[this.ctag] = {});
var f = e[b];
f || (f = e[b] = c(this.otag, this.ctag));
return f
}
};
return {
name: "mustache.js",
version: "0.4.0-dev",
to_html: function(a, c, d, e) {
var f = new b;
e && (f.send = e), f.render(a, c || {}, d);
if (!e) return f.buffer.join("\n")
}
}
}()
}, require_modules[32] = function(a, b, c) {
var d = this,
e = {
tag_link_prefix: location.protocol + "//soundcloud.com/tags/"
};
b.exports = e
}, require_modules[33] = function(a, b, c) {
var d = this;
b.exports = {
dispose: function() {
this._isDisposed || (this._isDisposed = !0, this.disposeDecorate());
return this
},
disposeDecorate: function() {}
}
}, require_modules[34] = function(a, b, c) {
var d = this,
e = c(1);
b.exports = {
toggleState: function(a, b) {
if ( !! this.stateHandlers && !! this.stateHandlers[a]) {
this._states = this._states || {}, b = typeof b != "undefined" ? b : !this._states[a];
if (this._states[a] === b) return;
this._states[a] = !! b;
var c = this.stateHandlers[a][b ? "setup" : "teardown"];
if (e.isFunction(c)) c.call(this);
else if (e.isString(c)) {
var d = c;
this.getElement()[b ? "addClass" : "removeClass"](d)
}
}
},
getState: function(a) {
if (!this._states) return !1;
return !!this._states[a]
}
}
}, require_modules[35] = function(a, b, c) {
var d = this,
e = c(1),
f = c(6).namespaces,
g = b.exports = {
_xlinkAttributesMap: ["actuate", "arcrole", "href", "role", "show", "title", "type"],
_xmlAttributesMap: ["base", "lang", "space"],
_getAttributeParts: function(a) {
var b;
e.indexOf(this._xlinkAttributesMap, a) > -1 ? b = [f.xlink, a] : e.indexOf(this._xmlAttributesMap, a) > -1 ? b = [f.xml, a] : b = [null, a];
return b
},
setProperties: function(a, b) {
e.each(b, function(b, c) {
var d = g._getAttributeParts(c);
a.setAttributeNS(d[0], d[1], b + "")
})
},
parseFromString: function(a) {
var b = a.indexOf(" ");
if (b > -1) {
var c = "";
a = a.replace('xmlns="http://www.w3.org/1999/xhtml"', ""), e.each(f, function(b, d) {
d !== "xml" && a.indexOf(b) === -1 && (c += " xmlns" + (d === "svg" ? "" : ":" + d) + '="' + b + '"')
}), c && (a = a.substr(0, b) + c + a.substr(b))
}
var d = new DOMParser,
h = d.parseFromString(a, "text/xml"),
i = document.createElementNS(f.svg, "svg"),
j = {
version: "1.1"
},
k;
for (k = 0; k < h.documentElement.attributes.length; k++) {
var l = h.documentElement.attributes.item(k);
"version" !== l.nodeName && "xmlns" !== l.nodeName.substring(0, 5) && (j[l.nodeName] = l.nodeValue)
}
g.setProperties(i, j), e.each(h.documentElement.childNodes, function(a) {
i.appendChild(a.cloneNode(!0))
});
return i
}
}
}, require_modules[36] = function(a, b, c) {
var d = this,
e = c(6).namespaces,
f = !1;
b.exports = {
addVMLNamespaces: function() {
if (!f) {
if (!document.namespaces.v) {
document.namespaces.add("v", e.svg), document.namespaces.add("o", e.office);
var a;
try {
a = document.createStyleSheet(), a.cssText = "v\\:arc,v\\:curve,v\\:extrusion,v\\:fill,v\\:formulas,v\\:group,v\\:handles,v\\:image,v\\:imagedata,v\\:line,v\\:oval,v\\:path,v\\:polyline,v\\:rect,v\\:roundrect,v\\:shadow,v\\:shape,v\\:shapetype,v\\:stroke,v\\:textbox,v\\:textpath,v\\:vmlframe{behavior:url(#default#VML);display:block;} o\\:callout, o\\:locks, o\\:skew {behavior:url(#default#VML);antialias:true;}"
} catch (b) {
a = document.styleSheets[document.styleSheets.length - 1], a.cssText += "\r\nv\\:arc,v\\:curve,v\\:extrusion,v\\:fill,v\\:formulas,v\\:group,v\\:handles,v\\:image,v\\:imagedata,v\\:line,v\\:oval,v\\:path,v\\:polyline,v\\:rect,v\\:roundrect,v\\:shadow,v\\:shape,v\\:shapetype,v\\:stroke,v\\:textbox,v\\:textpath,v\\:vmlframe{behavior:url(#default#VML);display:block;} o\\:callout, o\\:locks, o\\:skew {behavior:url(#default#VML);antialias:true;}"
}
}
f = !0
}
}
}
}, require_modules[37] = function(a, b, c) {
var d = this,
e = c(1),
f = c(11),
g = c(38),
h = c(40),
i = c(7).defaultUrlParams,
j = c(2),
k = b.exports = f.Model.extend({
initialize: function() {
var a = this.getUrlOptions(),
b = j.mapSubFields({
url: a.url
}, a, "url_");
this.set(b), this.bind(f.SERVER_ERROR_EVENT, e.bind(this.onServerError, this))
},
onServerError: function(a) {
this.set(e.extend({
server_error: !0
}, this.getErrorData(a)))
},
getErrorData: function() {
return {}
},
toJSON: function() {
var a, b;
a = f.Model.prototype.toJSON.apply(this, arguments), b = this.prepare(a);
return b
},
url: function() {
var a = this.baseUrl();
return g.addSecretTokenToUrl(a, this.get("secret_token"))
},
prepare: function(a) {
return a
},
resolveUrl: function(a) {
return h.resolveUrl(a)
},
getUrlOptions: function() {
var a;
return function() {
if (!a) {
var b = f.history.getOptions();
b.secret_token && typeof b.sharing == "undefined" && (b.sharing = !1), a = e.extend({}, i, b)
}
return a
}
}()
})
}, require_modules[38] = function(a, b, c) {
var d = this,
e = c(39),
f = c(3).api,
g = null;
b.exports = function() {
g = g || new e(f);
return g
}()
}, require_modules[39] = function(a, b, c) {
var d = this,
e = c(13),
f = c(2),
g = c(21),
h = b.exports = function(a) {
this.clientID = a.clientID
};
h.prototype = {
constructor: h,
allowedDomains: /^http(s)?:\/\/api\.(soundcloud|sandbox-soundcloud|staging-soundcloud)\.com/,
signStream: function(a) {
if (a) {
var b = {
client_id: this.clientID,
skip_logging: !0
};
g.getAccessToken() && (a = a.replace("http:", "https:"), b.oauth_token = g.getAccessToken()), a = f.addParamsToUrl(a, e.toQueryString(b))
}
return a
},
addSecretTokenToUrl: function(a, b) {
if (!b) return a;
return f.addParamsToUrl(a, "secret_token=" + b)
}
}
}, require_modules[40] = function(a, b, c) {
var d = this;
b.exports = {
prefix: "/resolve?url=http://soundcloud.com",
resolveUrl: function(a) {
return this.prefix + (a.indexOf("/") === 0 ? "" : "/") + a
}
}
}, require_modules[41] = function(a, b, c) {
function m(a, b) {
j[a] = k && k.get(a) || b;
return function(b) {
if (!arguments.length) return j[a];
j[a] = b, k && k.set(a, b)
}
}
var d = this,
e = c(1),
f = c(2),
g = c(4),
h = c(22),
i = b.exports = {},
j = {},
k = g.localStorage ? h("current-user") : null,
l = {
avatarSrc: f.getImageDir() + "/default_avatar_small.png",
favoriteIds: [],
permalink: "#",
name: ""
};
e.each(l, function(a, b) {
i[b] = m(b, a)
})
}, require_modules[42] = function(a, b, c) {
var d = this,
e = c(13),
f = c(1),
g = c(7),
h = c(11),
i = c(37),
j = c(43),
k = c(29).View,
l = d.ListEvents = {
CURRENT_CHANGE: "current"
},
m = d.constants = {
ITEM_INDEX: "_item_index_",
HIGHLIGHTED_CLASS: "g-list-highlighted",
HIGHLIGHTED_ALT_CLASS: "g-list-alt-highlighted"
},
n = d.List = h.Collection.extend(f.extend({}, j, {
initialize: function(a, b) {
this.options = b || {}, this.current = 0, f.bindAll(this, "prepare")
},
DEFAULT_PAGE_SIZE: 50,
MAX_PAGE_SIZE: 200,
model: i,
toJSON: function() {
var a = h.Collection.prototype.toJSON.apply(this, arguments),
b = this.prepare(a);
return b
},
url: function() {
return i.prototype.url.apply(this, arguments)
},
prepare: function(a) {
return a
},
getModelIndex: function(a) {
var b;
this.find(function(c, d) {
if (a.cid === c.cid) {
b = d;
return !0
}
});
return b
},
fetch: function(a) {
a = a || {}, a.data = a.data || {};
var b = this.options.count;
b = b && b > this.DEFAULT_PAGE_SIZE ? b : this.DEFAULT_PAGE_SIZE;
var c = this.MAX_PAGE_SIZE,
d = 0,
e = Math.ceil(b / c),
g = e,
i = [];
if (b <= this.MAX_PAGE_SIZE) {
f.defaults(a.data, {
limit: b,
offset: d
});
return h.Collection.prototype.fetch.call(this, a)
}
var j = f.bind(function(b) {
g--, i = i.concat(b);
if (!g) {
this[a.add ? "add" : "reset"](this.parse(i), a);
var c = a.success;
c && c(this, i)
}
}, this);
while (e) h.sync("read", this, {
data: {
limit: c,
offset: d
},
success: j
}), e--, d += this.MAX_PAGE_SIZE
},
setCurrent: function(a, b) {
a = a | 0, b = f.defaults(b || {}, {
silent: !1,
force: !1
});
var c = this.current !== a;
if (!this.at(a) || !c && !b.force) return !1;
this.current = a, b.silent || this.trigger(l.CURRENT_CHANGE, a);
return c
},
getCurrent: function() {
return this.at(this.current)
}
})),
o = d.ListViewEvents = {
ITEM_CLICK: "itemclick.listview"
},
p = d.ListView = k.extend({
initialize: function() {
this.options.ListItemView && (this.ListItemView = this.options.ListItemView, this.listItemCssClass = this.ListItemView.prototype.options.elementCssClass), this.listItemViews = [], this.index2listItemView = {}, k.prototype.initialize.apply(this, arguments), this.collection && (this.collection.bind("add", f.bind(this.onAdd, this)), this.collection.bind("remove", f.bind(this.onRemove, this)), this.collection.bind("reset", f.bind(this.onCollectionReset, this)), this.collection.bind("change", f.bind(this.onCollectionChange, this)), this.collection.bind(l.CURRENT_CHANGE, f.bind(this.onCurrentItemChange, this)), this.options.isCollectionPopulated || this.collection.length > 0 ? this.render() : this.collection.fetch()), this.bindEventHandlers()
},
bindEventHandlers: function() {
this.delegateEvents(this.getEventHandlers())
},
getEventHandlers: function() {
var a = {};
a["click ." + this.listItemCssClass] = "onItemClick";
return a
},
render: function(a) {
this.templateData = a || this.collection.toJSON(), k.prototype.render.call(this, this.templateData)
},
appendRenderedContent: function(a) {
var b = e(a);
f.each(this.collection.models, function(a) {
this.addListItem(a, b)
}, this), this.$element.empty().append(b)
},
renderDecorate: function() {
this.highlightCurrentItem()
},
onCollectionChange: function(a) {},
onCollectionReset: function() {
this.render()
},
onRemove: function(a) {
this.removeListItem(a), this.updateListItemIndexes()
},
removeListItem: function(a) {
var b = this.collection.getModelIndex(a),
c = this.listItemViews[b];
c.$element.remove(), c.dispose(), this.listItemViews.splice(b, 1)
},
onAdd: function(a) {
this.addListItem(a), this.updateListItemIndexes(a)
},
addListItem: function(a, b) {
b = b || this.getElement();
var c = this.renderListItem(a);
this.setListItemIndex(c), b.append(c.el), this.listItemViews.push(c)
},
renderListItem: function(a) {
var b = {
model: a,
isModelPopulated: !0
};
if (this.ListItemView) return new this.ListItemView(b);
throw new Error("Cannot render list item. ListItemView is not defined")
},
updateListItemIndexes: function(a) {
var b = this.collection.getModelIndex(a);
f.each(this.listItemViews.slice(b), this.setListItemIndex, this)
},
setListItemIndex: function(a) {
var b = this.collection.getModelIndex(a.model);
this.index2listItemView[b] !== a && (this.index2listItemView[b] = a, a.getElement().data(m.ITEM_INDEX, b))
},
onItemClick: function(a) {
a.preventDefault();
var b = this.getItemIndexByEvent(a);
this.setCurrentItem(b, !0)
},
onCurrentItemChange: function() {
this.highlightCurrentItem()
},
getItemIndexByEvent: function(a) {
var b = e(a.target),
c = b.closest("." + this.listItemCssClass);
c = c.length ? c : b;
return c.data(m.ITEM_INDEX)
},
setCurrentItem: function(a, b) {
var c = this.collection.setCurrent(a);
b && this.trigger(o.ITEM_CLICK, c)
},
getCurrentItemNode: function() {
var a = this.index2listItemView[this.collection.current];
return a ? a.getElement() : null
},
highlightCurrentItem: function() {
if ( !! this.options.currentItemCssClass) {
var a = this.options.currentItemCssClass;
this.currentItemNode && this.currentItemNode.removeClass(a).removeClass(m.HIGHLIGHTED_CLASS).removeClass(m.HIGHLIGHTED_ALT_CLASS), this.currentItemNode = this.getCurrentItemNode(), this.currentItemNode && (this.currentItemNode.addClass(a), this.currentItemNode.addClass(g.isAlternativeContrastColor() ? m.HIGHLIGHTED_ALT_CLASS : m.HIGHLIGHTED_CLASS))
}
}
})
}, require_modules[43] = function(a, b, c) {
function j(a, b, c) {
e.connect({
success: function(d) {
c.data = c.data || {}, g.extend(c.data, {
oauth_token: d
}), f.sync(a, b, c)
},
error: c.error
})
}
var d = this,
e = c(21),
f = c(11),
g = c(1),
h = b.exports = {},
i = {
post: "create",
read: "read",
put: "update",
"delete": "delete"
};
g.each(i, function(a, b) {
h[b] = function(b) {
j(a, this, b)
}
})
}, require_modules[44] = function(a, b, c) {
var d = this,
e = c(1),
f = c(45),
g = c(4),
h = c(46).SoundManager,
i = c(47),
j = c(55),
k = b.exports = function() {
this.audioComponent = g.audio ? new i : new j, this.audioComponent.isHTML5 = g.audio;
return this.audioComponent
};
e.extend(k, f), k.useFlashPlayer = function(b) {
var c = k.getInstance(),
d;
c instanceof i ? h.loadSoundManagerLibrary(e.bind(function() {
k.removeInstance(), g.set("audio", !1), d = a.audioPlayer = k.getInstance(), e.each(c._callbacks, function(a, b) {
d.bind(b, function(a) {
c.trigger(b, a)
})
}), b(d)
}, this)) : setTimeout(b, 1)
}
}, require_modules[45] = function(a, b, c) {
var d = this,
e = b.exports = {
getInstance: function() {
var a = this.prototype.constructor;
a.instance_ || (a.instance_ = new a);
return a.instance_
},
removeInstance: function() {
delete this.prototype.constructor.instance_
}
}
}, require_modules[46] = function(a, b, c) {
var d = this,
e = c(1),
f = c(3).soundmanager,
g = c(24),
h = c(45),
i = c(23).getBootstrapperConfig(),
j = c(11).Events;
a.SM2_DEFER = !0;
var k, l = document.location,
m = i.debug ? "soundmanager-debug" : "soundmanager",
n = d.Events = {
INITED: "onSoundManagerInited",
FAIL: "onSoundManagerFail",
TIMEOUT: "onSoundManagerTimeout"
},
o = d.SoundManager = function() {
if (k) return k;
if (!window.SoundManager) throw new Error("SoundManager is not loaded");
k = window.soundManager = new window.SoundManager, k.flashLoadTimeout = 0, k.flashVersion = 9, k.url = "//" + l.host + l.pathname + f.swf, k.useFlashBlock = !0, k.onready(function() {
o.trigger(n[k.supported() ? "INITED" : "FAIL"])
}), k.ontimeout(function() {
o.trigger(n.TIMEOUT)
}), k.beginDelayedInit();
return k
};
e.extend(o, h, j, {
loadSoundManagerLibrary: function(a) {
var b = new g({
namespace: m,
debugMode: !1,
createScriptTag: !1,
async: !0,
version: f.version,
js: i.debug ? f.url : f.minified,
callback: a
})
}
})
}, require_modules[47] = function(a, b, c) {
var d = this,
e = c(1),
f = c(2),
g = c(48).Player,
h = c(5),
i = b.exports = function() {
g.prototype.constructor.apply(this, arguments), this._isFirstTime = !0, this._iOSWorkaround = e.bind(this._iOSWorkaround, this)
};
f.inherits(i, g), e.extend(i.prototype, {
initAudioObject: function() {
var a = this.audioObject = new Audio;
a.addEventListener("play", e.bind(this.onPlay, this), !1), a.addEventListener("pause", e.bind(this.onPause, this), !1), a.addEventListener("ended", e.bind(this.onFinish, this), !1), a.addEventListener("error", e.bind(this.onError, this), !1), a.addEventListener("timeupdate", e.bind(this.onTime, this), !1), a.addEventListener("progress", e.bind(this.onLoading, this), !1), a.addEventListener("loadedmetadata", e.bind(this.onLoading, this), !1), a.addEventListener("canplay", e.bind(this.onLoading, this), !1)
},
resetAudioObject: function() {
if (this.audioObject) {
var a = this.audioObject;
a.pause(), a.removeEventListener("play", this.onPlay, !1), a.removeEventListener("pause", this.onPause, !1), a.removeEventListener("ended", this.onFinish, !1), a.removeEventListener("error", this.onError, !1), a.removeEventListener("timeupdate", this.onTime, !1), a.removeEventListener("progress", this.onLoading, !1), a.removeEventListener("loadedmetadata", this.onLoading, !1), a.removeEventListener("canplay", this.onLoading, !1)
}
},
disposeDecorate: function() {
this.resetAudioObject(), this.audioObject && delete this.audioObject
},
onFinish: function() {
this.audioObject.currentTime > 1 && this.audioObject.currentTime === this.audioObject.duration && (this.audioObject.pause(), this.audioObject.currentTime = 0, i.superClass_.onFinish.apply(this, arguments))
},
stopInternal: function() {
if (this.audioObject) try {
this.audioObject.pause(), this.audioObject.currentTime = 0
} catch (a) {}
},
getRelative: function() {
if (!this.audioObject) return null;
return this.audioObject.currentTime / this.audioObject.duration
},
getPosition_: function() {
if (!this.audioObject) return null;
return Math.max(0, this.audioObject.currentTime * 1e3)
},
seekTo_: function(a) {
this.audioObject.currentTime = a / 1e3
},
internalSetPosition: function(a) {
try {
this.audioObject || this.initAudioObject(), this.audioObject.currentTime = a * this.audioObject.duration
} catch (b) {}
},
getVolume_: function() {
if (this.audioObject) return this.audioObject.volume * 100
},
setVolume_: function(a) {
this.audioObject && (this.audioObject.volume = parseFloat(a / 100, 10))
},
getDuration_: function() {
if (this.audioObject) return this.audioObject.duration
},
getLoadedProgress: function() {
if (!this.audioObject) return null;
var a = this.audioObject,
b = h.isAndroid ? "buffered" : "seekable",
c = (a[b].length && a[b].end(0)) / a.duration;
return c || 0
},
internalSetCurrentTrack: function() {
this.resetAudioObject(), this.audioObject || this.initAudioObject(), this.audioObject.src = this.getCurrentTrack().stream_url
},
play: function() {
this._isFinished = !1, this._isFirstTime ? (this.audioObject.addEventListener("playing", this._iOSWorkaround, !1), this._isFirstTime = !1) : this._isPlaying = !0, this.audioObject.play()
},
_iOSWorkaround: function() {
this._isPlaying = !0, this.audioObject.removeEventListener("playing", this._iOSWorkaround, !1)
}
})
}, require_modules[48] = function(a, b, c) {
var d = this,
e = c(2),
f = c(4),
g = c(5),
h = c(22),
i = c(33),
j = c(11).Events,
k = c(49),
l = c(50).Model,
m = c(1),
n = c(13),
o = c(20),
p = c(23).getBootstrapperConfig().debug,
q = n(document),
r = f.localStorage,
s = "player",
t = function() {},
u = d.Events = {
PLAY: "onPlay",
PLAYING: "onPlaying",
PAUSE: "onPause",
FINISH: "onFinish",
TIME: "onTime",
LOADING: "onLoading",
ERROR: "onError",
SEEK: "onSeek",
NEXT: "nextTrack",
PREV: "prevTrack",
SKIP: "skip",
PROGRESS_10: "audioProgress10",
PROGRESS_95: "audioProgress95",
BLOCKED: "onBlocked"
},
v = d.Player = function() {
this.currentTrack = null, this.audioObject = null, this._isPlaying = !1, this._uid = e.getTimestamp(), this.storage = r && h(s), this.progressEvents = [{
name: "audioProgress10",
value: .1
}, {
name: "audioProgress95",
value: .95
}], this.currentProgress = null, this.bindEventHandlers()
};
m.extend(v.prototype, i, j, {
constructor: v,
getVolume_: t,
getPosition_: t,
getRelative: t,
getLoadedProgress: t,
getDuration_: t,
internalSetPosition: t,
seekTo_: t,
internalSetCurrentTrack: t,
setVolume_: t,
bindEventHandlers: function() {
var a = this.storage;
a && a.onChange(m.bind(function() {
a.get("id") !== this._uid && this.pause()
}, this))
},
handlers: {},
addAudioEventListeners: function(a, b, c) {
var d = this,
e;
a = parseInt(a, 10), m.each(b, function(b, f) {
e = function(e) {
if ( !! e.track) {
var f = d.getCurrentTrack();
f && a === e.track.id && a === f.id && b.apply(c, arguments)
}
}, this.bind(f, e);
var g = this.handlers[a] || [];
g.push([f, e])
}, this)
},
removeAudioEventListeners: function(a) {
var b = this.handlers[a] || [],
c, d;
m.each(b, function(a) {
c = a[0], d = a[1], this.unbind(c, d)
}, this), this.handlers[a] = []
},
isCurrentTrack: function(a) {
return this.currentTrack && this.currentTrack.id === a.id
},
getCurrentTrack: function() {
return this.currentTrack
},
setCurrentTrack: function(a) {
this.isCurrentTrack(a) || (this.currentTrack = a, this.internalSetCurrentTrack(), this.currentProgress = this.progressEvents.slice())
},
getCurrentTime: function() {
return this.getPosition() / 1e3
},
getDuration: function() {
return this.getDuration_() || 0
},
getPosition: function() {
return this.getPosition_() || 0
},
getVolume: function() {
return this.getVolume_()
},
setVolume: function(a) {
this.setVolume_(a)
},
setPosition: function(a) {
this.internalSetPosition(a), this.dispatchEvent(u.SEEK)
},
seekTo: function(a) {
this.seekTo_(a), this.dispatchEvent(u.SEEK)
},
toggle: function(a, b) {
a = a || this.getCurrentTrack(), this.isCurrentTrack(a) ? (b = typeof b != "undefined" ? b : this._isFinished ? !0 : !this._isPlaying, b ? this.play() : this.pause()) : (this.stop(), this.setCurrentTrack(a), this.play())
},
pauseAllOtherWidgets: function() {
if (!g.isIE8 && r) this.storage.remove("id"), this.storage.set("id", this._uid);
else {
var a = parent.frames,
b, c;
for (b = 0, c = a.length; b < c; b++) try {
var d = a[b];
d.location.hostname === location.hostname && d.SC.AudioPlayer.getInstance()._uid !== this._uid && d.SC.AudioPlayer.getInstance().pause()
} catch (e) {}
}
},
onPlay: function() {
this.pauseAllOtherWidgets(), this.dispatchEvent(u.PLAY);
var a = this.getCurrentTrack();
this._tracked = this._tracked || {};
if (!this._tracked[a.id]) {
this._tracked[a.id] = !0;
var b = new l({
id: a.id
});
b.playCount({
error: m.bind(function() {
this._tracked[a.id] = !1
}, this)
})
}
},
onTime: function() {
a.clearRequestInterval(this.onTimeIntervalID), this.onTimeIntervalID = a.requestInterval(m.bind(function() {
this._isPlaying && this.dispatchEvent(u.TIME)
}, this), 1e3 / 60), this.currentProgress.length && this.getRelative() >= this.currentProgress[0].value && (this.dispatchEvent(this.currentProgress[0].name), this.currentProgress.shift()), this._isPlaying && this.dispatchEvent(u.PLAYING)
},
onPause: function() {
this.dispatchEvent(u.PAUSE)
},
onLoading: function() {
this.dispatchEvent(u.LOADING)
},
onFinish: function() {
this._isFinished = !0;
while (this.currentProgress.length) this.dispatchEvent(this.currentProgress[0].name, this.getCurrentTrack()), this.currentProgress.shift();
this.currentProgress = this.progressEvents.slice(), this.dispatchEvent(u.FINISH)
},
onError: function() {
this.pause(), this.dispatchEvent(u.ERROR)
},
isPlaying: function() {
return this._isPlaying
},
play: function() {
this.isPlaying() || (this._isFinished = !1, this._isPlaying = !0, this.audioObject && (this.getLoadedProgress() === 1 && this.dispatchEvent(u.LOADING), this.audioObject.play()))
},
isPaused: function() {
return !this._isPlaying && !this._isFinished
},
pause: function() {
this._isPlaying = !1, this._isFinished = !1, this.audioObject && this.audioObject.pause()
},
stop: function() {
this._isPlaying = !1, this.stopInternal()
},
next: function() {
this.dispatchEvent(u.NEXT)
},
prev: function() {
this.dispatchEvent(u.PREV)
},
skip: function(a) {
this.dispatchEvent(u.SKIP, a)
},
stopInternal: function() {
this.audioObject && this.audioObject.stop()
},
dispatchEvent: function(a, b) {
p && o.log(a);
var c = this.getPosition();
b = b || {
track: this.getCurrentTrack(),
loadedProgress: this.getLoadedProgress(),
relative: this.getRelative(),
position: c,
timestamp: c
};
var d = [a, b];
q.trigger(a, d), this.trigger.apply(this, d)
}
})
}, require_modules[49] = function(a, b, c) {
var d = this;
a.requestAnimationFrame = window.requestAnimationFrame || window.webkitRequestAnimationFrame || window.mozRequestAnimationFrame || window.oRequestAnimationFrame || window.msRequestAnimationFrame ||
function(a, b) {
window.setTimeout(a, 1e3 / 60)
}, a.cancelRequestAnimationFrame = window.cancelRequestAnimationFrame || window.webkitCancelRequestAnimationFrame || window.mozCancelRequestAnimationFrame || window.oCancelRequestAnimationFrame || window.msCancelRequestAnimationFrame || clearTimeout, a.requestInterval = function(b, c) {
function f() {
var g = (new Date).getTime(),
h = g - d;
h >= c && (b.call(), d = (new Date).getTime()), e.value = a.requestAnimationFrame(f)
}
if (window.cancelRequestAnimationFrame === clearTimeout) return window.setInterval(b, c);
var d = (new Date).getTime(),
e = {};
e.value = a.requestAnimationFrame(f);
return e
}, a.clearRequestInterval = function(b) {
!b || a.cancelRequestAnimationFrame(window.cancelRequestAnimationFrame === clearTimeout ? b : b.value)
}
}, require_modules[50] = function(a, b, c) {
var d = this,
e = c(13),
f = c(1),
g = c(11),
h = c(51),
i = c(52),
j = c(38),
k = c(2),
l = c(4),
m = c(21),
n = c(43),
o = c(41),
p = c(53).Model,
q = c(54),
r = d.Model = p.extend({
resourceType: "tracks",
playCount: function(a) {
var b = m.getAccessToken(),
c = {
referer: document.referrer
};
b && (c.oauth_token = b), f.extend(a, {
data: c
}), g.sync("create", this, f.extend({
url: "/tracks/" + this.id + "/plays"
}, a))
},
prepare: function(a) {
var b = p.prototype.prepare.apply(this, arguments);
b = b || {}, b.availableForThisDomain === undefined && (b.availableForThisDomain = !0), b.available = b && b.stream_url && b.availableForThisDomain, b.non_embeddable = !b.available, b.shareable = b.shareable && b.embeddable_by !== "none", b.tags = b.tag_list ? b.tag_list.split(" ") : [], b.duration_timecode = h.timecode(b.duration), b.playback_count_string = b.playback_count + (b.playback_count !== 1 ? " plays" : " play"), b.stream_url = j.signStream(b.stream_url), b.track_artwork = i.from(b, i.SIZE.MEDIUM), b.track_artwork_large = i.from(b, i.SIZE.LARGE), b.downloadable = !! b.url_download && !! b.download_url, b.downloadable && (b.download_url = k.addParamsToUrl(b.download_url, "client_id=" + j.clientID)), b.is_favorite = f.indexOf(o.favoriteIds(), this.id) > -1, b.purchase_title = q.getPurchaseTitle(b, "Buy");
return b
},
getStreamUrls: function(a, b) {
g.sync("read", this, {
url: "/i1/tracks/" + this.get("id") + "/streams",
cacheResult: !1,
success: function(a) {
if (b.success) {
var c = {};
f.each(a, function(a, b) {
var d = b.split("_")[0];
c[d] = a
}), c.rtmp && (c.rtmp = c.rtmp.replace(/([a-z0-9.]+\?)/i, function(a) {
a = a.replace(".mp3", "");
return "mp3:" + a
})), b.success(c)
}
},
error: b.error
})
},
getRtmpUrl: function() {
return this.get("rtmp_stream_url")
},
setRtmpUrl: function(a) {
this.set({
rtmp_stream_url: a
})
},
setCommentsCollection: function(a) {
var b = this.comments = a,
c = f.bind(this.updateCommentCount, this);
b.bind("add", c), b.bind("remove", c)
},
isCommentingEnabled: function() {
return this.get("commentable") && l.authSupported
},
updateCommentCount: function() {
this.comments && this.set({
comment_count: this.comments.length
})
},
toggleFavoriteStatus: function(a) {
a = f.isUndefined(a) ? !this.toJSON().is_favorite : a;
var b = a ? "put" : "delete",
c = this;
m.getAccessToken() && c.set({
is_favorite: a
}), this[b]({
url: "/me/favorites/" + this.id,
success: function() {
var b = o.favoriteIds();
a ? o.favoriteIds(b.concat([c.id])) : o.favoriteIds(f.without(b, c.id)), c.set({
is_favorite: a
})
},
error: function() {
c.set({
is_favorite: !a
})
}
})
}
});
m.onToken(function() {
n.read({
url: "/me/favorites/ids",
success: function(a) {
o.favoriteIds(a || [])
},
cacheResult: !1
})
})
}, require_modules[51] = function(a, b, c) {
var d = this;
b.exports = {
timecode: function(a) {
if (isNaN(a)) return a;
var b = [],
c = {
h: Math.floor(a / 36e5),
m: Math.floor(a / 6e4 % 60),
s: Math.floor(a / 1e3 % 60)
};
c.h > 0 && b.push(c.h), b.push(c.m < 10 && c.h > 0 ? "0" + c.m : c.m), b.push(c.s < 10 ? "0" + c.s : c.s);
return b.join(".")
}
}
}, require_modules[52] = function(a, b, c) {
var d = this,
e = c(1),
f = c(13),
g = c(2).noop,
h = b.exports = {
SIZE: {
LARGE: "t300x300",
MEDIUM: "badge",
SMALL: "small"
},
from: function(a, b) {
return (a.artwork_url || a.user_avatar_url || a.avatar_url || "").replace(/-large/, "-" + b)
},
load: function(a, b) {
b = e.extend({
onLoad: g,
onError: g
}, b);
var c = new Image;
f(c).bind("load", function() {
b.onLoad(c)
}), f(c).bind("error", function() {
b.onError(c)
}), c.src = a;
return c
}
}
}, require_modules[53] = function(a, b, c) {
var d = this,
e = c(13),
f = c(1),
g = c(11),
h = c(37),
i = c(43),
j = c(2),
k = c(8),
l = c(52),
m = d.Model = h.extend(f.extend({}, i, {
resourceType: null,
baseUrl: function() {
if (!this.resourceType) throw new Error('A "resourceType" property must be specified for this resource');
return "/" + this.resourceType + "/" + this.get("id")
},
getSubresourceUrl: function(a) {
a = a || this.get("subresourceType");
var b = e.toQueryString(this.getAdditionalParams(a));
return this.baseUrl() + "/" + a + (b ? "?" + b : "")
},
getAdditionalParams: function(a) {
return {}
},
getDomainsLockings: function(a) {
g.sync("read", this, f.extend({
url: "/e1/" + this.resourceType + "/" + this.get("id") + "/domain-lockings",
cacheResult: !1
}, a))
},
isLockedDomain: function(a, b, c) {
if (a.embeddable_by === "all" || a.embeddable_by === "me" && !c.length) return !0;
b = k.parse(b);
return f.any(c, function(a) {
var c = b.host.match(k.parse(a.domain).host);
return c && c.length
})
},
prepare: function(a) {
var b = a;
j.mapSubFields(b, b.user, "user_"), b.set_artwork_url = l.from(b, l.SIZE.MEDIUM), b.shareable = !! b.url_sharing && b.sharing !== "private", b.buyable = !! b.url_buying && !! b.purchase_url;
return b
},
getErrorData: function(a) {
var b = {},
c;
try {
c = a.status
} catch (d) {
c = null
}
c === 0 ? b.error_connection = !0 : c >= 500 ? b.error_50X = !0 : b.error_404 = !0;
return b
}
}))
}, require_modules[54] = function(a, b, c) {
var d = this;
(function() {
var a = {
getPurchaseTitle: function(a, b) {
var c = a.purchase_url,
d = this._shops;
if (c && !a.purchase_title) {
a.purchase_title = b || "Buy";
for (var e in d) if (d["Getty Images"].test(c)) a.purchase_title = "License";
else if (d[e].test(c)) {
a.purchase_title += " on " + e;
break
}
}
return a.purchase_title
},
_shops: {
Amazon: /amazon\.(co\.(jp|uk)|com|de)/,
Beatport: /beatport\.(com|it)/,
iTunes: /apple\.com/,
Juno: /juno(\.co\.uk|download\.com)/,
"Digital Tunes": /digital-tunes\.net/,
'zero"': /zero-inch\.com/,
whatpeopleplay: /whatpeopleplay\.com/,
DJdownload: /djdownload\.com/,
Minno: /soundra\.in/,
Flattr: /flattr\.com/,
Ganxy: /ganxy\.com/,
"Getty Images": /soundcloud\.(.*-)?gettyimages\.com/
}
};
typeof b != "undefined" && b.exports ? b.exports = a : (window.SC = window.SC || {}, window.SC.OnlineStores = a)
})()
}, require_modules[55] = function(a, b, c) {
var d = this,
e = c(2),
f = c(8),
g = c(1),
h = c(48).Player,
i = c(48).Events,
j = c(46).SoundManager,
k = c(46).Events,
l = [],
m = b.exports = function() {
h.prototype.constructor.apply(this, arguments), this.soundManager = j.getInstance(), j.bind(k.TIMEOUT, this.onFlashBlock, this), j.bind(k.INITED, g.once(g.bind(this.onSoundManagerInitHandler, this)))
};
e.inherits(m, h), g.extend(m.prototype, {
toggle: function(a) {
this.isEnabled() ? m.superClass_.toggle.apply(this, arguments) : l.push(function() {
this.toggle(a)
})
},
isEnabled: function() {
return this.soundManager && this.soundManager.enabled
},
onSoundManagerInitHandler: function() {
g.each(l, function(a) {
a.call(this)
}, this)
},
getRelative: function() {
if (!this.audioObject) return null;
return this.audioObject.position / this.audioObject.durationEstimate
},
seekTo_: function(a) {
this.audioObject && this.audioObject.setPosition(a)
},
internalSetPosition: function(a) {
this.audioObject && this.audioObject.setPosition(a * this.audioObject.durationEstimate)
},
getDuration_: function() {
if (this.audioObject) return this.audioObject.durationEstimate
},
getVolume_: function() {
if (this.audioObject) return this.audioObject.volume
},
setVolume_: function(a) {
this.audioObject && this.audioObject.setVolume(a)
},
getPosition_: function() {
if (!this.audioObject) return null;
return this.audioObject.position
},
getLoadedProgress: function() {
if (!this.audioObject) return null;
if (this.audioObject.options && this.audioObject.options.rtmp) return 1;
return this.audioObject.bytesLoaded / this.audioObject.bytesTotal
},
disposeDecorate: function() {
this.resetAudioObject(), this.audioObject && (this.audioObject.destruct(), delete this.audioObject)
},
createAudioObject: function(a) {
var b = this,
c, d = a.rtmp_stream_url,
e = {
id: a.id,
url: a.stream_url,
onplay: function() {
b.onPlay()
},
onpause: function() {
b.onPause()
},
onresume: function() {
b.onPlay()
},
onfinish: function() {
b.onFinish()
},
whileloading: function() {
b.onLoading()
},
whileplaying: function() {
b.onTime()
}
};
d && (c = f.parse(d), g.extend(e, {
url: c.file + "?" + c.query,
serverURL: d.substr(0, d.indexOf(c.file)),
duration: a.duration,
rtmp: !0
}));
return this.soundManager.createSound(e)
},
internalSetCurrentTrack: function() {
this.isEnabled() ? this.audioObject = this.soundManager.getSoundById(this.getCurrentTrack().id) || this.createAudioObject(this.getCurrentTrack()) : l.push(function() {
this.internalSetCurrentTrack()
})
},
onFlashBlock: function() {
this.dispatchEvent(i.BLOCKED)
}
})
}, require_modules[56] = function(a, b, c) {
var d = this;
1;
var e = c(13),
f = c(29).View,
g = c(4),
h = c(5),
i = c(48).Events,
j = c(44),
k = c(46).SoundManager,
l = {
HOVER: "HOVER_STATE",
PLAYING: "PLAYING_STATE"
},
m = d.Events = {
MOUSEENTER: "mouseenter.playerbutton",
MOUSELEAVE: "mouseleave.playerbutton",
CLICK: "click.playerbutton"
},
n = d.View = f.createView("player-button", {
initialize: function() {
f.prototype.initialize.apply(this, arguments);
var a = {};
a[i.PLAY] = this.onAudioStart, a[i.PAUSE] = this.onAudioStop, a[i.FINISH] = this.onAudioStop, j.getInstance().addAudioEventListeners(this.model.get("id"), a, this), j.getInstance().isHTML5 || j.getInstance().bind(i.BLOCKED, this.onFlashBlock, this)
},
options: {
template: '<div class="playerButton"> {{#svg}} <svg class="playerButton__svgContainer" width="32" height="32"><defs><linearGradient id="svg-button-gradient" x1="0%" y1="0%" x2="0%" y2="100%"><stop offset="0%" style="stop-color:{{MAIN_COLOR}};"></stop><stop offset="100%" style="stop-color:{{MAIN_COLOR_BURN}};"></stop></linearGradient></defs><circle class="playerButton__svgToggleControlBG" r="50%" cx="50%" cy="50%"></circle><circle class="playerButton__svgToggleControlOverlay g-opacity-transition" r="50%" cx="50%" cy="50%"></circle></svg> {{/svg}}{{#vml}} <v:oval class="playerButton__vmlControl" fillcolor="{{MAIN_COLOR}}" strokecolor="none"></v:oval> {{/vml}}{{#noVectors}} <div class="playerButton__css"></div> {{/noVectors}} <div class="playerButton__control playerButton__playControl" title="Play"></div><div class="playerButton__control playerButton__pauseControl" title="Pause"></div></div>',
elementCssClass: "playerButton"
},
element2selector: {
vmlControls: ".playerButton__vmlControl"
},
cssClass2stateName: {
playerButton__hoverState: l.HOVER,
playerButton__playingState: l.PLAYING
},
events: {
"click .playerButton__control": "onButtonClick",
"mouseover .playerButton__control": "onButtonHover",
"mouseout .playerButton__control": "onButtonHover"
},
appendRenderedContent: function() {
f.prototype.appendRenderedContent.apply(this, arguments), g.vml && h.isIE8 && document.documentMode && document.documentMode >= 8 && this.vmlControls().each(function(a, b) {
var c = e(a.parentNode.parentNode);
a.style.width = c.width() + "px", a.style.height = c.height() + "px"
})
},
onButtonClick: function() {
j.getInstance().toggle(this.model.toJSON()), this.trigger(m.CLICK)
},
onButtonHover: function(a) {
var b = a.type === "mouseover",
c = j.getInstance();
this.toggleState(l.HOVER, b);
var d = b ? m.MOUSEENTER : m.MOUSELEAVE;
this.trigger(d, d), c.audioObject || c.setCurrentTrack(this.model.toJSON())
},
onAudioStart: function(a) {
this.toggleState(l.PLAYING, !0)
},
onAudioStop: function(a) {
this.toggleState(l.PLAYING, !1)
},
onFlashBlock: function() {
var a = k.getInstance(),
b = e("#" + a.movieID),
c = this.$element.offset();
b.css({
left: (this.$element.width() - b.width()) / 2 + c.left + "px",
top: (this.$element.height() - b.height()) / 2 + c.top + "px"
})
}
})
}, require_modules[57] = function(a, b, c) {
var d = this;
1;
var e = c(1),
f = c(29).View,
g = c(44),
h = c(4),
i = c(52),
j = c(2),
k = d.Events = {
CLICKED: "clicked.artwork"
},
l = {
VISIBLE: "VISIBLE_STATE",
FLIPPED: "FLIPPED_STATE"
},
m = d.View = f.createView("artwork", {
options: {
template: '<div class="artwork{{#transforms3d}} artwork__transforms3d{{/transforms3d}}"><div class="artwork__flipContainer g-transform-3d g-transform-origin__right g-all-transition__slow g-transition-delay"><div class="artwork__flipFace artwork__flipFront">{{#url_show_user}}<img class="artwork__img g-opacity-transition" src="{{track_artwork_large}}"><ins class="artwork__flipIndicator">#</ins>{{/url_show_user}}{{^url_show_user}}<a href="{{permalink_url}}" target="_blank" title="Open SoundCloud page"><img class="artwork__img g-opacity-transition" src="{{track_artwork_large}}"></a>{{/url_show_user}}</div>{{#url_show_user}}<div class="artwork__flipFace artwork__flipBack"><img class="artwork__userAvatarImg g-shadow-bottom" src="{{user_details_avatar_large}}"><div class="artwork__userInfo"><div><a class="artwork__userName g-bold" href="{{user_permalink_url}}" target="_blank">{{user_username}}</a></div>{{#url_show_playcount}}<ul class="artwork__userStats"><li class="artwork__userStatsItem"><ins class="artwork__userStatsIcon artwork__userTracksIcon"></ins>{{user_details_track_count}}</li><li class="artwork__userStatsItem artwork__userStatsItemLast"><ins class="artwork__userStatsIcon artwork__userFollowersIcon"></ins>{{user_details_followers_count}}</li></ul>{{/url_show_playcount}}</div></div>{{/url_show_user}}</div></div>',
elementCssClass: "artwork"
},
events: {
click: "onClick",
"mouseover .artwork": "onHover",
"mouseout .artwork": "onHover"
},
cssClass2stateName: {
artwork__visibleState: l.VISIBLE,
artwork__flippedState: l.FLIPPED
},
element2selector: {
userAvatar: ".artwork__userAvatarImg"
},
renderDecorate: function() {
var a = this.model.toJSON();
this.hasFlipContent = a.url_show_user, this.preloadArtwork()
},
preloadArtwork: function() {
i.load(this.model.toJSON().track_artwork_large, {
onLoad: e.bind(function() {
this.toggleState(l.VISIBLE, !0)
}, this)
}), i.load(this.model.toJSON().user_details_avatar_large, {
onError: e.bind(function() {
this.userAvatar().attr("src", j.getImageDir() + "/default_avatar_large.png")
}, this)
})
},
flip: function() {
this.toggleState(l.FLIPPED, !0)
},
unflip: function() {
this.toggleState(l.FLIPPED, !1)
},
unflipTimeout: function() {
this.unflip(), clearTimeout(this.flipTimeout), this.flipTimeout = null
},
onClick: function(a) {
this.hasFlipContent && (this.flipTimeout ? this.unflipTimeout() : (this.flip(), this.flipTimeout = e.delay(e.bind(this.unflipTimeout, this), 5e3))), this.notifyDocument(k.CLICKED)
},
onHover: function(a) { !! this.hasFlipContent && !h.touch && (a.type === "mouseover" ? this.flip() : this.flipTimeout || this.unflip())
}
})
}, require_modules[58] = function(a, b, c) {
var d = this;
1;
var e = c(29).View,
f = d.View = e.createView("track-stats", {
options: {
template: '{{#url_show_playcount}}<ul class="trackStats">{{#playback_count}}<li class="trackStats__item" title="{{playback_count}} Plays"><ins class="trackStats__icon trackStats__playbackIcon">#</ins>{{playback_count}}</li>{{/playback_count}}{{#comment_count}}<li class="trackStats__item" title="{{comment_count}} Comments"><ins class="trackStats__icon trackStats__commentIcon">#</ins>{{comment_count}}</li>{{/comment_count}}{{#favoritings_count}}<li class="trackStats__item" title="{{favoritings_count}} Likes"><ins class="trackStats__icon trackStats__favIcon">#</ins>{{favoritings_count}}</li>{{/favoritings_count}}</ul>{{/url_show_playcount}}'
},
observableAttributes: "favoritings_count playback_count comment_count".split(" ")
})
}, require_modules[59] = function(a, b, c) {
var d = this;
1;
var e = c(29).View,
f = d.Events = {
TITLE_CLICKED: "titleClicked.trackTitle",
UPLOADER_CLICKED: "uploaderClicked.trackTitle"
},
g = d.View = e.createView("track-title", {
options: {
template: '<div class="trackTitle">{{#url_show_user}}<div class="trackTitle__username"><a class="trackTitle__username" href="{{user_permalink_url}}" target="_blank">{{user_username}}</a></div>{{/url_show_user}}<div class="trackTitle__title">{{#shareable}}<a class="trackTitle__title" href="{{permalink_url}}" target="_blank">{{title}}</a>{{/shareable}}{{^shareable}}<span class="trackTitle__title">{{title}}</span>{{/shareable}}</div></div>'
},
events: {
"click a.trackTitle__title": "onSoundTitleClick",
"click a.trackTitle__username": "onSoundUploaderClick"
},
observableAttributes: "username title".split(" "),
onSoundTitleClick: function() {
this.notifyDocument(f.TITLE_CLICKED)
},
onSoundUploaderClick: function() {
this.notifyDocument(f.UPLOADER_CLICKED)
}
})
}, require_modules[60] = function(a, b, c) {
var d = this,
e = c(4),
f = c(30),
g = c(61),
h = c(65);
b.exports = function() {
var a = e.canvas ? h : g;
f.addTemplate("waveform", a.prototype.options.template);
return a
}()
}, require_modules[61] = function(a, b, c) {
var d = this;
1;
var e = c(1),
f = c(62),
g = c(29).View,
h = c(63),
i = c(64).View,
j = g.createView("image-waveform", e.extend({}, h, i, {
initialize: function() {
g.prototype.initialize.apply(this, arguments), this.initTrackProgressBar()
},
options: {
template: '<div class="waveform"><div class="waveform__upperPart"><div class="waveform__progressPlay"></div><img class="waveform__image" src="{{waveform_url}}"></div><div class="waveform__lowerPart"><div class="waveform__progressPlay"></div><img class="waveform__image" src="{{waveform_url}}"></div><div class="waveform__progressLoad"></div></div>'
},
element2selector: {
upperPart: ".waveform__upperPart",
lowerPart: ".waveform__lowerPart",
loaded: ".waveform__progressLoad",
played: ".waveform__progressPlay"
},
renderDecorate: function() {
f.putIntoUpperHalf(this.upperPart(), this.$element), f.putIntoLowerPart(this.lowerPart(), this.$element), this.loaded().css({
top: f.getTopOffset(this.$element) - 1
})
},
updatePlayedDecorate: function() {
a.requestAnimationFrame(e.bind(function() {
this.played().css("width", this.playedProgress * 100 + "%")
}, this), this.played()[0])
},
updateLoadedDecorate: function() {
this.isLoadingProgressHidden || (a.requestAnimationFrame(e.bind(function() {
this.loaded().css("width", Math.floor(this.relativeLoad * 100) + "%")
}, this), this.loaded()[0]), this.isFullyLoaded && setTimeout(e.bind(function() {
this.loaded().hide(), this.isLoadingProgressHidden = !0
}, this), this.HIDE_LOADING_PROGRESS_INTERVAL))
}
}));
b.exports = j
}, require_modules[62] = function(a, b, c) {
var d = this,
e = c(7).scaleFactor;
b.exports = {
getTopOffset: function(a) {
var b = a[0].offsetHeight;
return b / (1 + e)
},
putIntoUpperHalf: function(a, b) {
a.css({
height: b.height() / (1 + e),
top: 0
});
return a
},
putIntoLowerPart: function(a, b) {
var c = b[0].offsetHeight;
a.css({
height: c * e / (1 + e),
top: this.getTopOffset(b)
});
return a
}
}
}, require_modules[63] = function(a, b, c) {
var d = this,
e = c(13),
f = c(1),
g = c(44),
h = c(48).Events,
i = b.exports = {
initTrackProgressBar: function() {
this.relativeLoad = 0, this.playedProgress = 0;
var a = {};
a[h.PLAY] = f.once(this.onAudioStart, this), g.getInstance().addAudioEventListeners(this.model.get("id"), a, this)
},
_lastContainerSize: -1,
updatePlayedDecorate: function() {},
updateLoadedDecorate: function() {},
onAudioStart: function() {
f.bindAll(this, "onAudioFinish", "updateProgressBar", "rethrottle"), this.updateProgressBarThrottled = this.updateProgressBar, this.rethrottleDebounced = f.debounce(this.rethrottle, 300), e(window).on("resize", this.rethrottleDebounced), g.getInstance().addAudioEventListeners(this.model.get("id"), this.getAudioHandlers(), this)
},
getAudioHandlers: function() {
var a = {};
a[h.FINISH] = this.onAudioFinish, a[h.TIME] = this.updateProgressBarThrottled, a[h.LOADING] = this.updateProgressBarThrottled;
return a
},
rethrottle: function() {
var a = g.getInstance(),
b = this.el.clientWidth,
c = parseInt(a.getDuration(), 10),
d;
b !== this._lastContainerSize && (this._lastContainerSize = b, b && (a.removeAudioEventListeners(this.model.get("id")), d = Math.max(33, Math.floor(c / b)), this.updateProgressBarThrottled = f.throttle(this.updateProgressBar, d), a.addAudioEventListeners(this.model.get("id"), this.getAudioHandlers(), this)))
},
onAudioFinish: function(a) {
this.updatePlayed(0)
},
updateProgressBar: function(a) {
this.updateLoaded(a.loadedProgress), this.updatePlayed(a.relative)
},
updatePlayed: function(a) {
this.playedProgress = isNaN(a) ? 0 : a, this.updatePlayedDecorate()
},
updateLoaded: function(a) {
this.isFullyLoaded || (this.relativeLoad = isNaN(a) ? 0 : a, this.relativeLoad === 1 && (this.isFullyLoaded = !0), this.updateLoadedDecorate())
}
}
}, require_modules[64] = function(a, b, c) {
var d = this,
e = c(7),
f = c(9),
g = d.View = {
HIDE_LOADING_PROGRESS_INTERVAL: 500,
WAVEFORM_BG_GRAD_COLORS: ["#3e3e3e", "#292929", "#141414", "#a1a1a1", "#bababa"],
SHADOW_HEIGHT: 3,
SCALE_FACTOR: e.scaleFactor,
WAVEFORM_BG_COLOR: f.hex2rgb(e.getColorParams().WAVEFORM_BG_COLOR)
}
}, require_modules[65] = function(a, b, c) {
var d = this;
1;
var e = c(1),
f = c(49),
g = c(9),
h = c(52),
i = c(4),
j = c(29).View,
k = c(66),
l = c(22),
m = c(3),
n = c(20).log,
o = c(67),
p = c(62),
q = c(7),
r = c(63),
s = c(64).View,
t = "waveforms",
u = i.localStorage && l(t);
b.exports = j.createView("canvas-waveform", e.extend({}, k, r, s, {
initialize: function() {
j.prototype.initialize.apply(this, arguments), this.initTrackProgressBar()
},
options: {
template: '<div class="waveform"><div class="waveform__canvas"></div></div>',
elementCssClass: "waveform__canvas"
},
renderDecorate: function() {
this.initCanvasView();
this.width !== 0 && (this.mainColor = q.getColorParams().MAIN_COLOR, this.middleY = Math.floor(p.getTopOffset(this.$element)), this.initGradients(), this.createWaveform(), this.getElement().append(this.canvas))
},
initGradients: function() {
var a = this.context,
b = o.precise(this.middleY / this.height, 2),
c = g.hex2rgb(this.mainColor),
d = g.hex2rgbString(this.mainColor),
e = this.bgGrad = a.createLinearGradient(0, 0, 0, this.height);
e.addColorStop(0, this.WAVEFORM_BG_GRAD_COLORS[0]), e.addColorStop(b - .02, this.WAVEFORM_BG_GRAD_COLORS[1]), e.addColorStop(b, this.WAVEFORM_BG_GRAD_COLORS[2]), e.addColorStop(b + .02, this.WAVEFORM_BG_GRAD_COLORS[3]), e.addColorStop(1, this.WAVEFORM_BG_GRAD_COLORS[4]);
var f = this.playedGrad = a.createLinearGradient(0, 0, 0, this.middleY);
f.addColorStop(0, "rgb(" + d + ")"), f.addColorStop(1, "rgb(" + g.darken(c, .1).join(",") + ")");
var h = this.shadowGrad = a.createLinearGradient(0, this.middleY, 0, this.middleY + this.SHADOW_HEIGHT);
h.addColorStop(0, "rgba(0,0,0,.6)"), h.addColorStop(1, "rgba(0,0,0,0)"), this.lowerPlayedFill = "rgba(" + d + ",.5)"
},
onWindowResizeDecorate: function() {
this.createWaveform()
},
createWaveform: function() {
var a = this.model.get("id"),
b = u && u.get(a),
c, d;
if (b) {
if (b.length) {
this.waveformImageData = this.waveformImageData || this.getWaveformImageData(b), this.renderWaveform(this.waveformImageData);
return
}
u.remove(a)
}
this.waveformImage ? this.renderWaveform(this.waveformImage) : (c = this.model.get("waveform_url").split("/").pop(), d = location.protocol + "//" + location.host + m.wavProxy.root + "/" + c, this.waveformImage = h.load(d, {
onLoad: e.bind(function() {
this.renderWaveform(this.waveformImage)
}, this)
}))
},
renderWaveform: function(a) {
var b = this.scaleImage(a, this.width, this.height, this.SCALE_FACTOR),
c = 0,
d = 0,
e = this.canvas,
f = this.context;
e.setAttribute("width", this.width), e.setAttribute("height", this.height), this.clearCanvas(), f.putImageData(b, c, d), f.save(), f.globalCompositeOperation = "xor", f.fillStyle = this.bgGrad, f.fillRect(0, 0, f.canvas.width, f.canvas.height), f.restore();
var g = this.model.get("id");
f.fillStyle = this.shadowGrad, f.fillRect(0, this.middleY, this.width, this.SHADOW_HEIGHT), u && !u.get(g) && u.set(g, this.getArrayRepresentation(a))
},
updatePlayedDecorate: function() {
a.requestAnimationFrame(e.bind(this.renderBar, this), this.canvas)
},
updateLoadedDecorate: function() {
a.requestAnimationFrame(e.bind(this.renderBar, this), this.canvas)
},
renderBar: function() {
var a = this.context;
this.loadedWidth = this.relativeLoad * this.width, this.playedWidth = (this.playedProgress * this.width | 0) + .5, a.save(), a.globalCompositeOperation = "source-atop", a.fillStyle = this.bgGrad, a.fillRect(0, 0, this.width, this.height), a.fillStyle = "white", a.fillRect(0, 0, this.playedWidth, this.height), a.fillStyle = this.playedGrad, a.fillRect(0, 0, this.playedWidth, this.middleY), a.fillStyle = this.lowerPlayedFill, a.fillRect(0, this.middleY, this.playedWidth, this.height - this.middleY), a.fillStyle = this.shadowGrad, a.fillRect(0, this.middleY, this.width, this.SHADOW_HEIGHT), this.isLoadingProgressHidden || (a.fillStyle = this.mainColor, a.fillRect(this.playedWidth, this.middleY, (this.loadedWidth | 0) - this.playedWidth + .5, 1), this.isFullyLoaded && setTimeout(e.bind(function() {
this.isLoadingProgressHidden = !0
}, this), this.HIDE_LOADING_PROGRESS_INTERVAL)), a.restore()
},
disposeDecorate: function() {
delete this.canvas
},
scaleImage: function(a, b, c, d) {
function B(a, b, c, d, f) {
f = f || 0;
var g = (Math.floor(b / c) * j + Math.floor(a / k)) * 4,
h = f + (b * e + a) * 4,
i = d.data[g + 3],
l = i === 255;
w.data[h] = l ? x[0] : 0, w.data[h + 1] = l ? x[1] : 0, w.data[h + 2] = l ? x[2] : 0, w.data[h + 3] = i;
return h
}
d = d || 1;
var e = b,
f = c / (1 + d),
g = f,
h = d * f,
i = a.height / 2,
j = a.width,
k = o.precise(e / a.width, 4),
l = o.precise(g / i, 4),
m = o.precise(h / i, 4);
g = Math.round(g), h = Math.round(h);
var n = !1;
try {
n = !(a instanceof Image)
} catch (p) {
n = a.hasOwnProperty("data") && a.data.hasOwnProperty("length")
}
var q = document.createElement("canvas");
q.width = a.width, q.height = a.height;
var r = q.getContext("2d"),
s, t;
n ? r.putImageData(a, 0, 0) : r.drawImage(a, 0, 0, a.width, a.height, 0, 0, a.width, a.height), s = r.getImageData(0, 0, a.width, i), t = r.getImageData(0, i, a.width, i);
var u = document.createElement("canvas");
u.width = b, u.height = c;
var v = u.getContext("2d"),
w = v.getImageData(0, 0, b, c),
x = this.WAVEFORM_BG_COLOR,
y, z, A;
for (z = 0; z < g; z++) for (y = 0; y < e; y++) A = B(y, z, l, s, 0);
A += 4;
for (z = 0; z < h; z++) for (y = 0; y < e; y++) B(y, z, m, t, A);
return w
},
getWaveformImageData: function(a) {
var b = a.length,
c = document.createElement("canvas");
c.width = b, c.height = this.height;
var d = c.getContext("2d"),
e = d.getImageData(0, 0, b, this.height),
f, g;
for (f = 0; f < b; f++) {
var h = Math.ceil(a[f] / 100 * this.height),
i = this.height - h;
for (g = 0; g < this.height; g++) {
var j = (g * b + f) * 4,
k = g < h || g > i;
e.data[j] = k ? this.WAVEFORM_BG_COLOR[0] : 0, e.data[j + 1] = k ? this.WAVEFORM_BG_COLOR[1] : 0, e.data[j + 2] = k ? this.WAVEFORM_BG_COLOR[2] : 0, e.data[j + 3] = k ? 255 : 0
}
}
return e
},
getArrayRepresentation: function(a) {
var b = document.createElement("canvas");
b.width = a.width, b.height = a.height;
var c = b.getContext("2d");
c.drawImage(a, 0, 0, a.width, a.height, 0, 0, a.width, a.height);
var d = c.getImageData(0, 0, a.width, a.height),
e = d.data,
f = a.width,
g = a.height,
h, i, j = [],
k, l;
for (k = 0; k < f; k++) for (l = 0; l < g; l++) {
h = (l * f + k) * 4, i = e[h + 3];
if (i < 20) {
j.push(l / g * 100 | 0);
break
}
}
return j
}
}))
}, require_modules[66] = function(a, b, c) {
var d = this,
e = c(13),
f = c(1),
g = b.exports = {
CANVAS_RESIZE_INTERVAL: 100,
initCanvasView: function() {
this.initCanvasElement(), this.initDimensions(), e(window).resize(f.debounce(f.bind(function() {
try {
this.width !== this.$element.width() && this.onWindowResize()
} catch (a) {}
}, this), this.CANVAS_RESIZE_INTERVAL))
},
onWindowResize: function() {
this.initDimensions(), this.onWindowResizeDecorate()
},
onWindowResizeDecorate: function() {},
initDimensions: function() {
this.$element = this.$element || e(this.el), this.width = this.$element.width(), this.height = this.$element.height(), this.canvas.setAttribute("width", this.width), this.canvas.setAttribute("height", this.height)
},
initCanvasElement: function() {
this.canvas = this.canvas || this.createCanvasElement(), this.context = this.canvas.getContext("2d")
},
createCanvasElement: function() {
var a = document.createElement("canvas");
a.style.position = "absolute", a.style.top = "0", a.style.left = "0", a.style.width = "100%", a.style.height = "100%";
return a
},
clearCanvas: function() {
this.context.clearRect(0, 0, this.canvas.width, this.canvas.height)
}
}
}, require_modules[67] = function(a, b, c) {
var d = this;
b.exports = {
precise: function(a, b) {
b = Math.pow(10, b || 0);
return Math.round(a * b) / b
}
}
}, require_modules[68] = function(a, b, c) {
var d = this;
1;
var e = c(1),
f = c(13),
g = c(4),
h = c(29).View,
i = c(44),
j = c(48).Events,
k = d.Events = {
CLICKED: "scrubber.clicked",
SEEKED: "scrubber.seeked"
},
l = {
POSITION_INDICATOR_VISIBLE: "POSITION_INDICATOR_VISIBLE_STATE"
},
m = d.View = h.createView("scrubber", {
initialize: function() {
h.prototype.initialize.apply(this, arguments), f(window).resize(e.debounce(e.bind(function() {
this.onWindowResize()
}, this), 50))
},
options: {
elementCssClass: "scrubber",
template: '<div class="scrubber"><div class="scrubber__positionIndicator"></div></div>'
},
events: {
"click .scrubber": "onClick",
"mousemove .scrubber": "onMove",
"mouseover .scrubber": "onHover",
"mouseleave .scrubber": "onHover"
},
element2selector: {
positionIndicator: ".scrubber__positionIndicator"
},
cssClass2stateName: {
scrubber__positionIndicatorVisibleState: l.POSITION_INDICATOR_VISIBLE
},
getXCoord: function() {
this.xCoord = this.xCoord || this.$element.offset().left;
return this.xCoord
},
getWidth: function() {
this.width = this.width || this.$element.width();
return this.width
},
onWindowResize: function() {
this.width = null
},
getLoadedWidth: function() {
var a = i.getInstance().getLoadedProgress();
return a * this.getWidth()
},
onHover: function(a) {
var b = a.type === "mouseover";
this.toggleState(l.POSITION_INDICATOR_VISIBLE, b);
var c = i.getInstance();
g.touch && b && this.onClick.call(this, a), c.audioObject || c.setCurrentTrack(this.model.toJSON())
},
onClick: function(a) {
var b = a.clientX,
c = Math.min(b - this.getXCoord(), this.getLoadedWidth()) / this.getWidth(),
d = i.getInstance();
this.trigger(k.CLICKED), d.isPlaying() && (d.setPosition(c), d.trigger(j.TRACK_SEEK, c), this.notifyDocument(k.SEEKED))
},
onMove: function(a) {
if (!g.touch) {
var b = i.getInstance().isPlaying(),
c = a.clientX - this.getXCoord();
!b || c > this.getLoadedWidth() || c <= 0 ? this.toggleState(l.POSITION_INDICATOR_VISIBLE, !1) : (this.__indicator = this.__indicator || this.positionIndicator(), this.__indicator.css({
left: c + "px"
}), this.toggleState(l.POSITION_INDICATOR_VISIBLE, !0))
}
}
})
}, require_modules[69] = function(a, b, c) {
var d = this;
1;
var e = c(13),
f = c(1),
g = c(49),
h = c(29).View,
i = c(51),
j = c(44),
k = c(48).Events,
l = {
INITIAL: "INITIAL_STATE"
},
m = b.exports = h.createView("time-indicator", {
initialize: function() {
h.prototype.initialize.apply(this, arguments);
var a = {};
a[k.PLAY] = this.onAudioTime, a[k.FINISH] = this.onAudioFinish, a[k.TIME] = this.onAudioTime, j.getInstance().addAudioEventListeners(this.model.get("id"), a, this), e(window).resize(f.debounce(f.bind(this.onWindowResize, this), 25))
},
options: {
template: '{{#duration_timecode}}<div class="timeIndicator g-selection-disabled"><ul class="timeIndicator__header"><li class="timeIndicator__current">00:00</li><li class="timeIndicator__duration">{{duration_timecode}}</li></ul></div>{{/duration_timecode}}',
elementCssClass: "timeIndicator "
},
element2selector: {
header: ".timeIndicator__header",
currentTime: ".timeIndicator__current"
},
cssClass2stateName: {
timeIndicator__initialState: l.INITIAL
},
renderDecorate: function() {
this.currentTimeContainer = this.currentTime(), this.toggleState(l.INITIAL, !0), this.updateHeader()
},
onWindowResize: function() {
this.containerWidth = null
},
updateHeader: function(a, b) {
a = a || j.getInstance().getRelative(), b = b || j.getInstance().getPosition();
var c = this.currentTimeContainer,
d = i.timecode(b);
c.html(f.isNaN(d) ? "0.00" : d), this.containerWidth = this.containerWidth || this.$element.width();
var e = this.header().width(),
g = c[0].offsetWidth,
h = a * this.containerWidth - g + 1;
e > this.containerWidth - h ? this.header()[0].setAttribute("style", "right: 0;") : this.header()[0].setAttribute("style", "left:" + (h < 0 ? 0 : h) + "px")
},
onAudioTime: function(b) {
this.toggleState(l.INITIAL, !1), this.el && a.requestAnimationFrame(f.bind(this.updateHeader, this, b.relative, b.position), this.el[0])
},
onAudioFinish: function() {
this.updateHeader()
}
})
}, require_modules[70] = function(a, b, c) {
var d = this,
e = c(1),
f = c(19),
g = c(2).noop,
h = c(42).List,
i = c(42).ListEvents,
j = c(71).Model,
k = c(41),
l = c(44),
m = c(48).Events,
n = 1500,
o = 3e3,
p = d.Events = e.extend({}, i, {
TIME_QUOTA_EXCEEDED: "timeQuotaExceeded.comments"
}),
q = d.List = h.extend({
initialize: function() {
h.prototype.initialize.apply(this, arguments), this.current = null, this.track = this.options.track, this.canSetCurrentComment = !0, this.audioSyncEnabled = !0;
var a = {};
a[m.TIME] = this.onAudioTime, l.getInstance().addAudioEventListeners(this.track.get("id"), a, this)
},
model: j,
parse: function(a) {
var b = e.groupBy(a, function(a) {
return a.timestamp
});
delete b["null"];
return e.map(b, function(a) {
return e.sortBy(a, function(a) {
return Date.parse(a.created_at)
})[0]
})
},
comparator: function(a) {
return a.get("timestamp")
},
baseUrl: function() {
return "/tracks/" + this.track.get("id") + "/comments"
},
_prepareModel: function(a) {
a = h.prototype._prepareModel.apply(this, arguments), e.extend(a.attributes, {
relative_position: this.getRelativePositionOfComment(a.get("timestamp"))
});
return a
},
addComment: function(a, b, c) {
var d = this;
c = e.extend({
before: g,
success: g,
error: g
}, c);
var f = d._add({
body: a,
timestamp: b,
user: {
avatar_url: k.avatarSrc(),
username: k.name()
}
});
c.before(f.toJSON()), this.post({
url: this.baseUrl(),
data: {
"comment[body]": a,
"comment[timestamp]": b
},
success: function(a) {
k.avatarSrc(a.user.avatar_url), k.permalink(a.user.permalink_url), k.name(a.user.username), f.set(a), d.clearSessionCache(), c.success(f.toJSON())
},
error: function(a) {
d.remove(f), c.error(a)
}
})
},
clearSessionCache: function() {
f.clearKeys(this.url())
},
getRelativePositionOfComment: function(a) {
return a / this.track.get("duration") * 100
},
isCommentCloseToPosition: function(a, b) {
var c = b - a.get("timestamp");
return c < 300 && c > 0 || c === 0
},
getCommentIndexByPosition: function(a) {
var b;
e.find(this.models, function(c, d) {
if (this.isCommentCloseToPosition(c, a)) {
b = d;
return !0
}
}, this);
return b
},
getCommentIndexByTimestamp: function(a) {
return e.indexOf(e.pluck(this.toJSON(), "timestamp"), a)
},
getCurrentCommentData: function() {
return this.getCommentDataByIndex(this.current)
},
getCommentDataByIndex: function(a) {
return a ? this.at(a).toJSON() : undefined
},
setCurrentComment: function(a, b) {
if (this.canSetCurrentComment || b) {
this.canSetCurrentComment = !1, clearTimeout(this.timeIntervalTimeoutID), clearTimeout(this.commentQuotaTimeoutID);
var c = this.getCommentDataByIndex(a);
this.timeIntervalTimeoutID = setTimeout(e.bind(function() {
this.canSetCurrentComment = !0
}, this), n), this.commentQuotaTimeoutID = setTimeout(e.bind(function() {
this.trigger(p.TIME_QUOTA_EXCEEDED, c)
}, this), o), this.setCurrent(a, {
force: e.isUndefined(b) ? !1 : b
})
}
},
enableAudioSync: function() {
this.audioSyncEnabled = !0
},
disableAudioSync: function() {
this.audioSyncEnabled = !1
},
onAudioTime: function(a) {
if (this.audioSyncEnabled) {
var b = this.getCommentIndexByPosition(a.position),
c = this.getCommentDataByIndex(b);
b !== undefined && c && this.setCurrentComment(b)
}
}
})
}, require_modules[71] = function(a, b, c) {
var d = this,
e = c(37),
f = c(51),
g = c(52),
h = c(72),
i = c(2),
j = h.withDefaults({
whitelist: [],
paragraphs: !1,
internalLinks: !1,
internalLinksBaseUrl: "//soundcloud.com/"
}),
k = d.Model = e.extend({
prepare: function(a) {
var b = a;
i.mapSubFields(b, b.user, "user_"), b.timecode = f.timecode(b.timestamp), b.user_avatar_url = g.from(b, g.SIZE.SMALL), b.body_formated = j(b.body);
return b
}
})
}, require_modules[72] = function(a, b, c) {
var d = this;
(function() {
var c, d, e, f, g, h, i, j = /\b((?:https?:\/\/|www\d{0,3}\.|(?:[a-z0-9\-]+\.)+[a-z]{2,4}\/)\S*[^\s`!()\[\]{};:'".,<>?«»])/ig,
k = /([a-z0-9._%+\-]+@[a-z0-9.\-]+\.[a-z]{2,6})/gi,
l = /(\s|[^\w]|^)@([\w\-]+)/g,
m = /\{\{\b((?:https?:\/\/|www\d{0,3}\.|(?:[a-z0-9\-]+\.)+[a-z]{2,4}\/)\S*[^\s`!()\[\]{};:'".,<>?«»])\}\}/ig,
n = /\{\{(?:mailto:)?([a-z0-9._%+\-]+@[a-z0-9.\-]+\.[a-z]{2,6})\}\}/gi,
o = /\{\{@([\w\-]+)\}\}/gi,
p = /^((?:https?:\/\/)?(?:www\.|m\.)?soundcloud\.(?:com|dev))\/?/i,
q = /^(?:ht|f)tps?:\/\//i,
r = /(?:[ \t]*\r?\n[ \t]*){2,}/,
s = /[ \t][ \t]+/g;
d = {
paragraphs: !0,
links: !0,
externalLinks: !0,
internalLinks: !0,
userLinks: !0,
whitelist: ["b", "i", "em"],
internalLinksBaseUrl: "/",
isOpeningNewWindow: !1,
maxLength: null
}, e = function(a) {
var b, c, d, e, f, g;
f = [].slice.call(arguments, 1);
for (b = 0, c = f.length; b < c; ++b) {
e = f[b];
for (g in e) e[g] !== d && (a[g] = e[g])
}
return a
}, f = function(a) {
return a.replace(/^\s+/, "").replace(/\s+$/, "")
}, g = function(a) {
return a.textContent || a.innerText || ""
}, i = function a(b, c) {
c(b), b = b.firstChild;
while (b) a(b, c), b = b.nextSibling
}, h = function(a, b) {
if (a.length < b) return a;
var c = document.createElement("div"),
d, e;
d = function(a) {
if (b > 0) {
var c = a.data.length;
b -= c, b <= 0 && (a.data = a.substringData(0, a.data.length + b))
} else a.data = ""
}, e = function(a, c) {
var d = a.firstChild,
f;
do d.nodeType === 3 ? c(d) : d.nodeType === 1 && e(d, c);
while ((d = d.nextSibling) && b > 0);
while (d) f = d, d = d.nextSibling, a.removeChild(f)
}, c.innerHTML = a, e(c, d);
return c.innerHTML === a ? c.innerHTML : c.innerHTML + "…"
}, c = function(a, b) {
var c = e({}, d, b),
g, t, u = document.createElement("div");
if (typeof a != "string") return "";
c.links ? !c.userLinks && !c.internalLinks && !c.externalLinks ? c.links = !1 : c.whitelist.push("a") : c.userLinks = c.internalLinks = c.externalLinks = !1, j.lastIndex = l.lastIndex = k.lastIndex = 0, a = a.replace(/<\/p>/g, "\n\n").replace(/<br\s*\/?>/g, "\n").replace(s, " "), c.whitelist && c.whitelist.length && (a = a.replace(new RegExp("<(?!\\s*\\/?(" + c.whitelist.join("|") + ")\\b)[^>]*>", "ig"), "")), u.innerHTML = a, c.links && i(u, function(a) {
a.nodeType === 3 && a.parentNode.nodeName.toLowerCase() !== "a" && (a.nodeValue = a.nodeValue.replace(j, "{{$1}}").replace(k, "{{mailto:$1}}").replace(l, "$1{{@$2}}"))
}), a = u.innerHTML, c.links && (a = a.replace(m, function(a, b) {
return c.internalLinks && p.test(b) ? '<a href="' + b.replace(p, c.internalLinksBaseUrl) + '">' + b + "</a>" : c.externalLinks ? '<a href="' + (q.test(b) ? b : "http://" + b) + '" rel="nofollow" target="_blank">' + b + "</a>" : b
}).replace(n, '<a href="mailto:$1">$1</a>').replace(o, '@<a href="' + c.internalLinksBaseUrl + '$1"' + (c.isOpeningNewWindow ? ' target="_blank"' : "") + ">$1</a>")), c.maxLength && (a = h(a, c.maxLength));
if (c.paragraphs) {
a = a.split(r);
for (g = 0, t = a.length; g < t; g++) a[g] = f(a[g]), a[g] = a[g].replace(/\r?\n/g, "<br>"), a[g] = "<p>" + a[g] + "</p>";
a = a.join("")
} else a = a.replace(/[\r\n]+/g, " ").replace(s, " ");
return a
}, c.withDefaults = function(a) {
var b = e({}, d, a);
return function(a, d) {
var f = d ? e({}, b, d) : b;
return c.call(this, a, f)
}
}, typeof b != "undefined" && b.exports ? b.exports = c : (a = function() {
return this
}(), a.SC = a.SC || {}, a.SC.usertext = c)
})()
}, require_modules[73] = function(a, b, c) {
var d = this,
e = c(4),
f = c(30),
g = c(74),
h = c(77),
i = b.exports = function() {
var a = e.canvas ? g : h;
f.addTemplate("timeline-comments", a.prototype.options.template);
return a
}()
}, require_modules[74] = function(a, b, c) {
var d = this;
1;
var e = c(13),
f = c(1),
g = c(52),
h = c(4),
i = c(75).View,
j = c(66),
k = c(7),
l = k.scaleFactor,
m = "auto",
n = i.createView("canvas-timeline-comments", f.extend({}, j, {
initialize: function() {
this.loadedAvatars = 0, this.coords = {}, i.prototype.initialize.apply(this, arguments)
},
options: {
template: '<div class="timelineComments g-opacity-transition"></div>',
elementCssClass: "timelineComments"
},
render: function() {
this.initCanvasView(), this.middleY = this.height / (1 + l) + 1, this.avatarWidth = this.avatarHeight = 10, i.prototype.render.apply(this, arguments)
},
renderDecorate: function() {
this.getElement().append(this.canvas)
},
bindEventHandlers: function() {
this.canvas.addEventListener("mousemove", f.bind(this.onCanvasMouseMove, this), !1), this.canvas.addEventListener("click", f.bind(this.onCanvasClick, this), !1)
},
getCurrentItemCoords: function() {
var a = this.coords[this.collection.current];
if ( !! a) return {
top: Math.floor(a[1] + this.offset.top + 1),
left: Math.floor(a[0] + this.offset.left + 1)
}
},
initDimensions: function() {
j.initDimensions.apply(this, arguments), this.offset = this.$element.offset()
},
onCollectionChange: function(a) {
this.renderListItem(a)
},
updateListItemIndexes: function() {
this.coords = {}, f.each(this.collection.models, function(a) {
this.coords[this.collection.getModelIndex(a)] = this.getAvatarCoords(a.toJSON())
}, this)
},
addListItem: function(a) {
this.renderListItem(a)
},
removeListItem: function() {
this.clearCanvas(), this.renderAllAvatars()
},
renderAllAvatars: function() {
f.each(this.collection.models, this.renderListItem, this)
},
renderListItem: function(a) {
this.toggleState(this.stateNames.COMMENTS_VISIBLE, this.loadedAvatars);
var b = a.toJSON();
g.load(b.user_avatar_url, {
onError: f.bind(function() {
this.collection.remove(a)
}, this),
onLoad: f.bind(function(c) {
this.coords[this.collection.getModelIndex(a)] = this.renderAvatar(c, b), this.loadedAvatars++, this.loadedAvatars === this.collection.models.length && this.toggleState(this.stateNames.COMMENTS_VISIBLE, !0)
}, this)
})
},
renderAvatar: function(a, b) {
var c = this.context,
d = this.getAvatarCoords(b),
e = d[0],
f = d[1];
c.drawImage(a, e, f, this.avatarWidth, this.avatarHeight), this.renderVerticalBar(e);
return d
},
renderVerticalBar: function(a, b) {
var c = this.context;
c.clearRect(a, 0, .5, this.middleY), c.strokeStyle = b ? "rgba(255, 255, 255, 0.6)" : "rgba(255, 255, 255, 0.1)", c.beginPath(), c.moveTo(a + .5, 0), c.lineTo(a + .5, this.middleY), c.stroke(), c.closePath()
},
highlightCurrentItem: function() {
if (this.prevZoomableAvatar) {
var a = this.prevZoomableAvatar.coords.left - this.offset.left;
this.renderVerticalBar(a)
}
i.prototype.highlightCurrentItem.apply(this, arguments)
},
onTimeQuotaExceeded: function() {
var a = i.prototype.onTimeQuotaExceeded.apply(this, arguments);
if (a) {
var b = a.coords.left - this.offset.left;
this.renderVerticalBar(b)
}
},
zoomCurrentAvatarNode: function(a) {
var b = i.prototype.zoomCurrentAvatarNode.apply(this, arguments);
if (this.getCurrentItemCoords()) {
var c = this.getCurrentItemCoords().left - this.offset.left;
this.renderVerticalBar(c, !a)
}
return b
},
onWindowResizeDecorate: function() {
this.renderAllAvatars()
},
getAvatarCoords: function(a) {
var b = a.relative_position / 100 * this.width,
c = Math.floor(this.middleY);
return [b, c]
},
getItemIndexByEvent: function(a) {
var b, c, d, e = a.clientX - this.offset.left,
g = a.clientY - this.offset.top,
h = 2,
i = 2;
f.find(this.coords, function(a, f) {
c = a[0], d = a[1], e >= c - h && e <= c + this.avatarWidth + h && g >= d && g <= d + this.avatarHeight + i && (b = parseInt(f, 10));
return b !== undefined
}, this);
return b
},
onCanvasMouseMove: function(a) {
if (!this.isDraggableAvatarVisible) {
var b = this.getItemIndexByEvent(a),
c = b !== undefined;
this.canvas.style.cursor = c ? "pointer" : m, c ? this.onCommentMouseOver(a) : this.onCommentMouseOut(a)
}
},
onCanvasClick: function(a) {
var b = this.getItemIndexByEvent(a),
c = b !== undefined;
this.canvas.style.cursor = c ? "pointer" : m, c && !this.isDraggableAvatarVisible ? this.setCurrentItem(b, !0) : this.notifyAboutClicking(a)
}
}));
b.exports = n
}, require_modules[75] = function(a, b, c) {
var d = this,
e = c(1),
f = c(13),
g = c(51),
h = c(62),
i = c(4),
j = c(5),
k = c(42).ListView,
l = c(76),
m = c(41),
n = c(70).Events,
o = f(document.body),
p = {
COMMENTS_VISIBLE: "COMMENTS_VISIBLE_STATE",
DISABLED: "DISABLED_STATE"
},
q = d.Events = {
CLICK: "click.timelinecomment",
AVATAR_MOVE: "avatarMove.timelinecomment",
AVATAR_MOVE_END: "avatarMoveEnd.timelinecomment",
MOUSE_MOVE: "mouseMove.ttimelinecomment",
MOUSE_OUT: "mouseOut.ttimelinecomment"
},
r = d.View = k.extend({
initialize: function() {
k.prototype.initialize.apply(this, arguments), this.track = this.options.track, this.zoomableAvatars = {}, this.collection.bind(n.TIME_QUOTA_EXCEEDED, this.onTimeQuotaExceeded, this), this.addOnMoveHandler()
},
stateNames: p,
cssClass2stateName: {
timelineComments__visibleState: p.COMMENTS_VISIBLE,
timelineComments__disabledState: p.DISABLED
},
renderDecorate: function() {
this.offset = this.$element.offset(), k.prototype.renderDecorate.apply(this, arguments)
},
disposeDecorate: function() {
e.each(this.zoomableAvatars, function(a) {
a.dispose()
}), this.draggableAvatar && this.draggableAvatar.dispose()
},
setCurrentItem: function(a, b) {
k.prototype.setCurrentItem.apply(this, arguments), b && this.draggableAvatar && this.draggableAvatar.zoomOut()
},
highlightCurrentItem: function() {
this.prevZoomableAvatar && this.prevZoomableAvatar.zoomOut(), this.prevZoomableAvatar = this.zoomCurrentAvatarNode()
},
getCurrentItemCoords: function() {},
showDraggableAvatar: function(a) {
this.draggableAvatar || (this.draggableAvatar = new l(m.avatarSrc(), {
draggable: !0,
container: this.$element,
onMouseEnter: function() {
window.document.body.style.cursor = "move"
},
onMouseLeave: function() {
window.document.body.style.cursor = "default"
},
onDrag: e.bind(function(a) {
this.trigger(q.AVATAR_MOVE, this.getTimestampDataByLeftOffset(a))
}, this),
onDragFinish: e.bind(function(a) {
this.trigger(q.AVATAR_MOVE_END, this.getTimestampDataByLeftOffset(a))
}, this)
}));
if (!this.coords || this.coords.left !== a) this.isDraggableAvatarVisible = !0, this.draggableAvatar.setSrc(m.avatarSrc()), this.draggableAvatar.zoomIn({
top: this.getTopOffsetForDraggableAvatar(),
left: a
}), this.toggleState(p.DISABLED, !0)
},
hideDraggableAvatar: function() {
this.draggableAvatar && (this.isDraggableAvatarVisible = !1, this.draggableAvatar.zoomOut(), this.toggleState(p.DISABLED, !1))
},
addOnMoveHandler: function() {
this.$element.bind("mouseout", e.bind(function(a) {
this.trigger(q.MOUSE_OUT, a)
}, this)), this.$element.bind("mousemove", e.bind(function(a) {
this.options.isCommentingEnabled && this.zoomCurrentAvatarNode(!0), this.trigger(q.MOUSE_MOVE, this.getTimestampDataByLeftOffset(a.clientX))
}, this))
},
getTopOffsetForDraggableAvatar: function() {
if (!this.topOffset) {
var a = this.$element.offset().top + (i.canvas ? h.getTopOffset(this.$element) : 0);
j.isWebKit ? a += 3 : a += 1, this.topOffset = a
}
return this.topOffset
},
zoomCurrentAvatarNode: function(a) {
var b = this.collection.getCurrentCommentData();
if (b) {
var c = this.zoomableAvatars[b.id];
c || (c = new l(b.user_avatar_url, {
coords: this.getCurrentItemCoords(),
onMouseEnter: e.bind(function() {
this.collection.disableAudioSync()
}, this),
onMouseLeave: e.bind(function() {
this.collection.enableAudioSync()
}, this)
}), this.zoomableAvatars[b.id] = c), this.zoomableAvatar = c, c[a ? "zoomOut" : "zoomIn"]();
return c
}
},
getTimestampDataByLeftOffset: function(a) {
var b = this.collection.track,
c = b.get("duration"),
d = a - this.offset.left,
e = Math.floor(c * d / this.width);
return {
timestamp: e,
timecode: g.timecode(e)
}
},
notifyAboutClicking: function(a) {
clearTimeout(this.onCommentHoverTimeoutID), this.zoomCurrentAvatarNode(!0), this.trigger(q.CLICK, this.getTimestampDataByLeftOffset(a.clientX))
},
onTimeQuotaExceeded: function(a) {
var b = this.zoomableAvatars[a.id];
b && b.zoomOut();
return b
},
onCommentHover: function(a) {
a.stopPropagation(), a.type === "mouseover" && this.onCommentMouseOver(a)
},
onCommentMouseOver: function(a) {
clearTimeout(this.onCommentHoverTimeoutID);
var b = this.collection.getCurrentCommentData(),
c = this.zoomableAvatars[b && b.id],
d = c && c.zoomedIn;
this.onCommentHoverTimeoutID = setTimeout(e.bind(function() {
var b = this.getItemIndexByEvent(a);
this.setCurrentItem(b, !0), this.zoomCurrentAvatarNode()
}, this), d ? 1 : 250)
},
onCommentMouseOut: function(a) {
clearTimeout(this.onCommentHoverTimeoutID)
}
})
}, require_modules[76] = function(a, b, c) {
var d = this;
1;
var e = c(13),
f = c(1),
g = c(2).noop,
h = c(31),
i = e(document.body),
j = e(window.document),
k = "zoomableAvatar__zoomedIn",
l = "zoomableAvatar__dragged",
m = 200,
n = b.exports = function(a, b) {
this.options = f.extend({
coords: {
top: 0,
left: 0
},
onMouseEnter: g,
onMouseLeave: g,
onDrag: g,
onDragFinish: g,
draggable: !1,
container: i
}, b), this.src = a, this.containerOffset = this.options.container.offset(), this.createNode(), this.setCoords(this.options.coords)
};
n.prototype = {
constructor: n,
template: '<img class="zoomableAvatar" src="{{src}}">',
createNode: function() {
if (!this.node) {
var a = h.to_html(this.template, {
src: this.src
}),
b = this.node = e(a);
b.attr("src", this.src), b.bind("mouseenter", this.options.onMouseEnter), b.bind("mouseleave", this.options.onMouseLeave), this.options.draggable && b.bind("mousedown", f.bind(this.onMouseDown, this))
}
return this.node
},
setSrc: function(a) {
if (this.src !== a) {
this.src = a;
var b = this.createNode();
b.attr("src", a)
}
},
setCoords: function(a) {
this.coords = f.defaults(a, this.coords || {}), this.node.css(this.coords)
},
zoomIn: function(a) {
clearTimeout(this.removeOnTransitionTimeout);
var b = this.createNode();
b.hide(), this.setCoords(a || this.coords), b.show(), i.append(b), setTimeout(function() {
b.addClass(k)
}, 1), this.zoomedIn = !0
},
zoomOut: function() {
var a = this.createNode();
a.removeClass(k), this.removeOnTransitionTimeout = setTimeout(function() {
a.remove()
}, m), this.zoomedIn = !1
},
dispose: function() {
this.node.unbind(), this.node.remove()
},
onMouseDown: function(a) {
this.node.addClass(l), j.on("mousemove.zoomableAvatar", f.bind(this.onMouseMove, this)), j.on("mouseup.zoomableAvatar", f.bind(this.onMouseUp, this)), window.document.body.style.cursor = "col-resize", a.preventDefault(), a.stopPropagation()
},
onMouseMove: function(a) {
this.avatarWidth = this.avatarWidth || this.node.width();
var b = this.avatarWidth,
c = this.containerOffset,
d = a.clientX - b / 2,
e = Math.min(Math.max(c.left, d), c.left + c.width - b);
this.setCoords({
left: e
}), this.options.onDrag(e), a.preventDefault(), a.stopPropagation()
},
onMouseUp: function(a) {
window.document.body.style.cursor = "move", this.node.removeClass(l), this.options.onDragFinish(this.coords.left), j.unbind("mousemove.zoomableAvatar"), j.unbind("mouseup.zoomableAvatar"), a.preventDefault(), a.stopPropagation()
}
}
}, require_modules[77] = function(a, b, c) {
var d = this;
1;
var e = c(1),
f = c(13),
g = c(78).View,
h = c(75).View,
i = b.exports = h.createView("dom-timeline-comments", {
initialize: function() {
h.prototype.initialize.apply(this, arguments), this.initDimensions()
},
options: {
elementCssClass: "timelineComments",
template: '<div class="timelineComments g-opacity-transition"></div>',
ListItemView: g
},
bindEventHandlers: function() {
h.prototype.bindEventHandlers.apply(this, arguments), f(window).resize(e.debounce(e.bind(this.onWindowResize, this), 100))
},
getEventHandlers: function() {
var a = h.prototype.getEventHandlers.apply(this, arguments);
a["mouseover ." + this.listItemCssClass] = "onCommentHover", a["mouseout ." + this.listItemCssClass] = "onCommentHover", a.click = "onClick";
return a
},
renderDecorate: function() {
var a = this;
h.prototype.renderDecorate.apply(this, arguments), this.toggleState(this.stateNames.COMMENTS_VISIBLE, !1), setTimeout(function() {
a.toggleState(a.stateNames.COMMENTS_VISIBLE, !0)
}, 125)
},
initDimensions: function() {
this.width = this.$element.width(), this.offset = this.$element.offset()
},
onWindowResize: function() {
this.initDimensions()
},
onClick: function(a) {
!f(a.target).hasClass(this.options.elementCssClass) || this.notifyAboutClicking(a)
},
getCurrentItemCoords: function() {
var a = this.getCurrentItemNode().offset();
return {
top: a.top + 1,
left: a.left + 1
}
}
})
}, require_modules[78] = function(a, b, c) {
var d = this,
e = c(29).View,
f = d.View = e.createView("timeline-comment", {
options: {
elementCssClass: "timelineComments__item",
template: '<div class="timelineComments__item" style="left: {{relative_position}}%"><div class="timelineComments__bar">{{#id}}<a class="timelineComments__avatar" target="_blank" title="{{user_username}} at {{timecode}}" href="{{user_permalink_url}}"><img class="timelineComments__avatarImg" src="{{user_avatar_url}}"></a>{{/id}}{{^id}}<a class="timelineComments__avatar timelineComments__fakeAvatar" target="_blank" href="#"></a>{{/id}}</div></div>'
},
observableAttributes: ["id"]
})
}, require_modules[79] = function(a, b, c) {
var d = this;
1;
var e = c(1),
f = c(13),
g = c(51),
h = c(37),
i = c(29).View,
j = c(44),
k = c(80).Placeholder,
l = c(41),
m = c(48).Events,
n = c(70).Events,
o = {
COMPOSING: "COMPOSING_STATE",
BUTTONS_VISIBLE: "BUTTONS_VISIBLE_STATE"
},
p = d.Events = {
INPUT_DEACTIVATED: "inputDeactivated.comment-details",
INPUT_ACTIVATED: "inputActivated.comment-details",
COMMENT_POSTED: "commentPosted.comment-details",
INPUT_FOCUSED: "inputFocused.comment-details",
FORM_SUBMIT: "formSubmit.comment-details",
MOUSE_OUT: "mouseOut.comment-details"
},
q = d.View = i.createView("comment-details", {
initialize: function() {
i.prototype.initialize.apply(this, arguments), this.isUserInteractingWithComments = !1, this.areCommentDetailsDisplayed = !1, this.commentValue = null, this.audioSyncEnabled = !0;
var a = {};
a[m.PLAY] = this.onAudioPlay, a[m.TIME] = this.onAudioTime, j.getInstance().addAudioEventListeners(this.options.track.id, a, this);
var b = this.options.comments;
b.bind(n.CURRENT_CHANGE, this.onCurrentCommentChange, this), b.bind(n.TIME_QUOTA_EXCEEDED, this.onTimeQuotaExceeded, this), this.$element.bind("touchstart touchmove touchend touchcancel", function(a) {
a.stopPropagation()
})
},
options: {
template: '<div class="commentDetails"><div class="commentDetails__content g-all-transition__medium"><a class="commentDetails__avatar" href="{{user_permalink_url}}" target="_blank"><img class="commentDetails__avatarImg" src="{{user_avatar_url}}" alt="{{user_username}}"></a><p class="commentDetails__body"><span class="commentDetails__msg">{{{body_formated}}}</span>{{#user_username}}<span class="commentDetails__light"> by </span><a class="commentDetails__userName" href="{{user_permalink_url}}" target="_blank">{{user_username}}</a>{{/user_username}}<span class="commentDetails__light"> at </span><span class="commentDetails__timeInfo">{{timecode}}</span></p></div><div class="commentDetails__inputBlock"><a class="commentDetails__postButton commentDetails__button g-button" href="#">Post</a><a class="commentDetails__cancelButton commentDetails__button" href="#">Cancel</a><img class="commentDetails__avatarImg" src="{{current_user_avatar_url}}" alt="{{current_user_name}}"><div class="commentDetails__inputWrapper"><input class="commentDetails__input" type="text"></div></div><span class="commentDetails__arrow" style="left: {{relative_position}}%"> </span></div>',
elementCssClass: "commentDetails"
},
events: {
mouseover: "onHover",
mouseout: "onHover",
"keydown .commentDetails__input": "saveInputValue",
"change .commentDetails__input": "saveInputValue",
"keyup .commentDetails__input": "onInputKeyup",
"mouseover .commentDetails__content": "onCommentDetailsHover",
"mouseout .commentDetails__content": "onCommentDetailsHover",
"click .commentDetails__postButton": "onPostButtonClick",
"click .commentDetails__cancelButton": "onCancelButtonClick"
},
cssClass2stateName: {
commentDetails__composingState: o.COMPOSING,
commentDetails__buttonsVisibleState: o.BUTTONS_VISIBLE
},
element2selector: {
commentInput: ".commentDetails__input",
pointer: ".commentDetails__arrow",
avatar: ".commentDetails__inputBlock .commentDetails__avatarImg",
avatarLink: ".commentDetails__inputBlock .commentDetails__avatar"
},
toggleComposingState: function(a) {
this.toggleState(o.COMPOSING, !1), this.toggleState(o.COMPOSING, a)
},
renderDecorate: function() {
this.offset = this.$element.offset(), this.commentInput().bind("focus", e.bind(function() {
this.activateCommentInput(), this.notifyDocument(p.INPUT_FOCUSED, this.options.track.toJSON())
}, this)), this.commentValue && this.commentInput().val(this.commentValue), this.placeholder = new k(this.commentInput()[0]), this.updatePlaceholder(this.timestamp), this.show()
},
isFakeCommentData: function(a) {
return !a.id
},
onCurrentCommentChange: function() {
this.showCommentDetails(this.options.comments.getCurrentCommentData())
},
onTimeQuotaExceeded: function() {
this.hideCommentDetails()
},
showCommentInput: function(a, b) {
if ( !! this.options.isCommentingEnabled) {
b = e.extend({
force: !1,
buttons: !1,
focusInput: !0
}, b);
if (!this.areCommentDetailsDisplayed && !this.isUserInteractingWithComments || b.force) this.show(), a = this.timestamp = a || 0, this.hideCommentDetails(), this.updatePointer(a), this.updatePlaceholder(a), this.avatarLink().attr("href", l.permalink()), (this.avatar().attr("src") !== l.avatarSrc() || this.avatar().attr("alt") !== l.name()) && this.avatar().attr({
src: l.avatarSrc(),
alt: l.name()
}), this.toggleState(o.BUTTONS_VISIBLE, this.commentValue || b.buttons), (this.commentValue || b.force) && b.focusInput && (this.commentInput()[0].focus(), this.activateCommentInput())
}
},
showCommentDetails: function(a, b) {
b = b || {};
if (!this.isUserInteractingWithComments || b.force) this.show(), b.force && this.deactivateCommentInput(), this.areCommentDetailsDisplayed = !0, this.model.set(a), this.render(), this.toggleComposingState(!1)
},
hideCommentDetails: function() {
this.options.isCommentingEnabled ? (this.areCommentDetailsDisplayed = !1, this.isUserInteractingWithComments = !1, this.toggleComposingState(!0)) : this.$element.hide()
},
updatePointer: function(a) {
var b = a / this.options.track.get("duration");
this.absoluteLeftPosition = b * this.offset.width + this.offset.left;
var c = b * 100;
this.pointer().css({
left: c + "%"
})
},
updatePlaceholder: function(a) {
var b = g.timecode(a);
this.placeholder.updateText({
timecode: b
})
},
saveInputValue: function() {
this.commentValue = this.commentInput().val()
},
toggleAudioSync: function(a) {
this.audioSyncEnabled = a
},
toggleCommentsAudioSync: function(a) {
this.options.comments[a ? "enableAudioSync" : "disableAudioSync"]()
},
activateCommentInput: function(a) {
a = e.isUndefined(a) ? !0 : a, this.isUserInteractingWithComments = !0, this.toggleCommentsAudioSync(!1), this.toggleState(o.BUTTONS_VISIBLE, !0), a && this.trigger(p.INPUT_ACTIVATED, this.timestamp)
},
deactivateCommentInput: function() {
this.isUserInteractingWithComments = !1, this.toggleCommentsAudioSync(!0), this.toggleState(o.BUTTONS_VISIBLE, !1), this.trigger(p.INPUT_DEACTIVATED)
},
onInputKeyup: function(a) {
this.saveInputValue(), a.keyCode === 13 && (this.postComment(), a.stopPropagation()), a.keyCode === 27 && (this.cancelComment(), a.stopPropagation())
},
onCancelButtonClick: function(a) {
a.preventDefault(), this.cancelComment()
},
onPostButtonClick: function(a) {
a.preventDefault(), this.postComment()
},
cancelComment: function() {
this.commentValue = null, this.commentInput().val(""), this.blurCommentInput(), this.deactivateCommentInput(), this.hide()
},
blurCommentInput: function() {
this.commentInput()[0].blur()
},
postComment: function() {
if (!this.commentValue) this.commentInput()[0].focus();
else if (this.options.track && !this.postingCommentNow) {
var a = this.options.comments;
this.postingCommentNow = !0;
var b = this.commentValue,
c = this.timestamp,
d = e.bind(function(a) {
var b = this.isFakeCommentData(a);
this.postingCommentNow = b, this.commentValue = null, this.showCommentDetails(a, {
force: !0
}), b || this.notifyDocument(p.COMMENT_POSTED, this.options.track.toJSON())
}, this),
f = e.bind(function() {
this.postingCommentNow = !1, this.commentValue = b, this.showCommentInput(c, {
force: !0
})
}, this);
a.addComment(this.commentValue, this.timestamp, {
before: d,
success: d,
error: f
}), this.notifyDocument(p.FORM_SUBMIT, this.options.track.toJSON())
}
},
onHover: function(a) {
var b = a.type === "mouseover";
b || this.trigger(p.MOUSE_OUT, a)
},
onCommentDetailsHover: function(a) {
var b = a.type === "mouseover";
this.toggleCommentsAudioSync(!b)
},
onAudioPlay: function(a) {
this.showCommentInput(a.timestamp, {
buttons: !1
})
},
onAudioTime: function(a) {
this.audioSyncEnabled && this.showCommentInput(a.timestamp, {
buttons: !1
})
},
onAudioFinish: function() {
this.toggleComposingState(!1)
}
})
}, require_modules[80] = function(a, b, c) {
var d = this;
1;
var e = c(1),
f = c(13),
g = c(2),
h = '<span class="placeholder"><label class="placeholder__label g-opacity-transition">Add your comment at {timecode}</label></span>',
i = {
blur: "enabled",
focus: "focused",
keydown: "disabled",
keyup: "focused"
},
j = d.Placeholder = function(a) {
this.$element = f(a), this.$container = f(h), this.$placeholder = this.$container.find(".placeholder__label"), this.tmpl = this.$placeholder.html(), e.bindAll(this), this._createAndAttach(), this.bindEventHandlers()
};
j.prototype = {
constructor: j,
_createAndAttach: function() {
var a = "input_" + (Math.random() * 1e4 | 0),
b = this.$element.attr("id", a),
c = this.$placeholder.attr("for", a);
c.css({
"line-height": b.css("line-height"),
"font-size": b.css("font-size"),
color: b.css("color")
}), this.setState(b.val().length ? "disabled" : "enabled"), b[0].parentNode.replaceChild(this.$container[0], b[0]), this.$container.prepend(b)
},
bindEventHandlers: function() {
e.each(i, function(a, b) {
this.$element.bind(b, this.setStateWithEvent)
}, this)
},
unbindEventHandlers: function() {
e.each(i, function(a, b) {
this.$element.unbind(b, this.setStateWithEvent)
}, this)
},
updateText: function(a) {
this.$placeholder.text(g.supplant(this.tmpl, a))
},
setStateWithEvent: function(a) {
var b = i[a.type];
this.$element.val().length || this.setState(b)
},
setState: function(a) {
e.each(i, function(a, b) {
this.$placeholder.removeClass("placeholder__" + a)
}, this), this.$placeholder.addClass("placeholder__" + a)
}
}
}, require_modules[81] = function(a, b, c) {
var d = this;
1;
var e = c(13),
f = c(1),
g = c(2),
h = c(82),
i = c(5),
j = c(37),
k = c(83),
l = c(25),
m = c(29).View,
n = c(84),
o = c(86),
p = c(8),
q = window,
r = l.prototype.loadScript,
s = d.Events = {
LINK_BUTTON_CLICKED: "linkButtonClicked.sharePanel",
LINK_INPUT_CLICKED: "linkInputClicked.sharePanel",
EMBED_CODE_BUTTON_CLICKED: "embedCodeButtonClicked.sharePanel",
EMBED_CODE_INPUT_CLICKED: "embedCodeInputClicked.sharePanel",
SHARE_BUTTON_CLICKED: "shareButtonClicked.sharePanel",
SHARE_ICON_CLICKED: "shareIconClicked.sharePanel",
EMAIL_BUTTON_CLICKED: "emailButtonClicked.sharePanel"
},
t = {
LINK_CODE: "LINK_CODE_STATE",
EMBED_CODE: "EMBED_CODE_STATE",
SHORT_URL_LOADING: "SHORT_URL_LOADING_STATE",
COMPACT_STATE: "COMPACT_STATE"
},
u = d.View = m.createView("sharepanel", {
options: {
template: '<div class="sharepanel" id="sharepanel"><div class="sharepanel__top g-border-bottom g-shadow-bottom"><div class="sharepanel__title"><span class="g-share-icon">#</span> Share</div></div><div class="sharepanel__buttons g-border-bottom"><ul class="sharepanel__buttonsList"><li class="sharepanel__buttonsListItem g-border-right"><div class="sharepanel__button sharepanel__fb">{{>like-button}}</div></li><li class="sharepanel__buttonsListItem sharepanel__tweeterWrapper g-border-right"><div class="sharepanel__button sharepanel__tweeter">{{>tweet-button}}</div></li><li class="sharepanel__buttonsListItem sharepanel__plusoneWrapper"><div class="sharepanel__button share sharepanel__plusone">{{>plusone-button}}</div></li></ul></div><div class="sharepanel__linkCode"><div class="sharepanel__linkCodeWrapper"><div class="sharepanel__urlShortSpinner g-spinner">loading</div><div class="sharepanel__linkCodeLabelCell"><label for="link-code-input" class="sharepanel__linkCodeLabel">Link:</label></div><div class="sharepanel__linkCodeInputCell g-border-right"><input id="link-code-input" class="sharepanel__linkCodeInput sharepanel__input g-selection" type="text" value="{{permalink_url}}"></div><div class="sharepanel__linkCodeInputTextCell"><input type="checkbox" id="link-code-short" class="sharepanel__shortUrlCheckbox"><label for="link-code-short" class="g-label sharepanel__linkCodeInputLabel">Short</label></div><div class="sharepanel__embedActionCell"><a class="sharepanel__embedActionButton sharepanel__code g-button" href="#">Embed Code</a></div></div></div><div class="sharepanel__embedCode"><div class="sharepanel__embedCodeWrapper"><div class="sharepanel__linkActionCell g-border-right"><a class="sharepanel__linkActionButton sharepanel__link g-button" href="#">Link</a></div><div class="sharepanel__embedCodeLabelCell"><label for="embed-code-input" class="sharepanel__embedCodeLabel">Embed:</label></div><div class="sharepanel__embedCodeInputCell"><input class="sharepanel__embedCodeInput sharepanel__input g-selection" type="text"></div><div class="sharepanel__embedCodeInputTextCell"><input type="checkbox" id="embed-code-wordpress" class="sharepanel__wordpressEmbedCheckbox"><label for="embed-code-wordpress" class="g-label sharepanel__linkCodeInputLabel">WordPress</label></div></div></div><div class="sharepanel__bottom g-border-top"><div class="sharepanel__email"><a class="sharepanel__emailButton g-button" href="mailto:?subject={{share_text}} - SoundCloud&body={{share_url_email}}" share-icon="email">Share via Email</a></div><div class="sharepanel__icons"><span class="sharepanel__iconLabel">or to</span>{{#socialnetworks}}{{/socialnetworks}}</div></div></div>',
elementCssClass: "sharepanel",
partials: {
"like-button": '<fb:like href="{{permalink_url}}" send="false" layout="button_count" height="21" show_faces="false"></fb:like>',
"tweet-button": '<a href="{{permalink_url}}" data-url="{{share_url_twitter}}" data-text="{{share_text}} via #soundcloud" class="twitter-share-button">Tweet</a>',
"plusone-button": '<g:plusone size="medium" count="true" href={{permalink_url}}></g:plusone>'
}
},
events: {
"click .sharepanel__link": "onLinkButtonClick",
"click .sharepanel__code": "onEmbedCodeButtonClick",
"click .sharepanel__linkCodeInput": "onLinkCodeInputClick",
"click .sharepanel__embedCodeInput": "onEmbedCodeInputClick",
"change .sharepanel__shortUrlCheckbox": "onShortUrlCheckboxChange",
"change .sharepanel__wordpressEmbedCheckbox": "onWordpressEmbedCheckboxChange",
"click .sharepanel__icon": "onShareIconClick",
"click .sharepanel__fbIcon": "onFacebookShareIconClick",
"click .sharepanel__emailButton": "onEmailButtonClick"
},
cssClass2stateName: {
sharepanel__shortUrlLoadingState: t.SHORT_URL_LOADING,
sharepanel__linkCodeState: t.LINK_CODE,
sharepanel__embedCodeState: t.EMBED_CODE,
sharepanel__compactState: t.COMPACT_STATE
},
element2selector: {
shortUrlCheckbox: ".sharepanel__shortUrlCheckbox",
linkCodeInput: ".sharepanel__linkCodeInput",
embedCodeInput: ".sharepanel__embedCodeInput"
},
renderDecorate: function() {
this.checkDimensions(), this.initPlusOneButton(), this.initFBLike(), this.initTweetButton(), this.initEmbedCode()
},
notifyDocument: function(a, b) {
var c = f.extend({}, b, this.model.toJSON());
m.prototype.notifyDocument.call(this, a, c)
},
onShortUrlCheckboxChange: function() {
var a = this,
b = this.model.get("permalink_url"),
c = this.shortUrlCheckbox()[0].checked;
c ? (this.toggleState(t.SHORT_URL_LOADING, !0), k.shorten({
url: b,
callback: function(b) {
a.toggleState(t.SHORT_URL_LOADING, !1), a.linkCodeInput().val(b)
},
error: function() {
a.toggleState(t.SHORT_URL_LOADING, !1), a.shortUrlCheckbox()[0].checked = !1
}
})) : this.linkCodeInput()[0].value = b
},
onWordpressEmbedCheckboxChange: function(a) {
var b = p,
c = this.model.get("embed_code");
if (a.target.checked && c) {
var d = e(c)[0],
f = d.width,
g = d.height,
h = p.parse(d.src),
i = h.params,
j = decodeURIComponent(i.url);
delete i.url, delete i.callback, delete i._, i = p.serialize(i), c = '[soundcloud url="' + j + '" params="' + i + '" width="' + f + '" height="' + g + '" iframe="true" /]'
}
this.embedCodeInput().val(c)
},
checkDimensions: function() {
f.find(this.$element.parents("div"), f.bind(function(a) {
var b = e(a);
if (b.css("display") !== "none") {
b.width() < 300 && this.toggleState(t.COMPACT_STATE, !0);
return !0
}
}, this))
},
initTweetButton: function() {
var a = this;
r("//platform.twitter.com/widgets.js", function() {
try {
twttr && twttr.events && twttr.events.bind && twttr.events.bind("click", function(b) {
a.notifyDocument(s.SHARE_BUTTON_CLICKED, {
shareButtonType: "twitter"
})
})
} catch (b) {}
})
},
initFBLike: function() {
var a = this;
r("//connect.facebook.net/en_GB/all.js#xfbml=1", function() {
try {
FB && FB.Event && FB.Event.subscribe && FB.Event.subscribe("edge.create", function(b) {
a.notifyDocument(s.SHARE_BUTTON_CLICKED, {
shareButtonType: "facebook"
})
})
} catch (b) {}
})
},
initPlusOneButton: function() {
q.gapi && q.gapi.plusone && q.gapi.plusone.go ? q.gapi.plusone.go("sharepanel") : r("//apis.google.com/js/plusone.js")
},
initEmbedCode: function() {
var a = this.model.get("permalink_url") + (this.model.get("sharing") === "private" ? "/" + this.model.get("secret_token") : ""),
b = this;
o.getEmbedCode({
params: f.extend(p.getUrlParams(), {
url: a
}),
success: function(a) {
b.model.set({
embed_code: a.html
}), b.embedCodeInput().val(a.html)
}
})
},
onActiveState: function() {
this.getState(t.EMBED_CODE) ? this.focusEmbedCode() : this.focusLinkCode()
},
onShareIconClick: function(a) {
var b = e(a.target);
this.notifyDocument(s.SHARE_ICON_CLICKED, {
shareIconType: b.attr("share-icon")
})
},
onFacebookShareIconClick: function(a) {
var b = e(a.target),
c = b.attr("href");
h.open(c), a.preventDefault()
},
onEmailButtonClick: function(a) {
this.notifyDocument(s.EMAIL_BUTTON_CLICKED)
},
onLinkCodeInputClick: function() {
this.linkCodeInput()[0].select(), this.notifyDocument(s.LINK_INPUT_CLICKED)
},
onEmbedCodeInputClick: function() {
this.embedCodeInput()[0].select(), this.notifyDocument(s.EMBED_CODE_INPUT_CLICKED)
},
onLinkButtonClick: function(a) {
this.toggleState(t.EMBED_CODE, !1), this.toggleState(t.LINK_CODE), this.focusLinkCode(), this.notifyDocument(s.LINK_BUTTON_CLICKED), a.preventDefault(), a.stopPropagation()
},
onEmbedCodeButtonClick: function(a) {
this.toggleState(t.LINK_CODE, !1), this.toggleState(t.EMBED_CODE), this.focusEmbedCode(), this.notifyDocument(s.EMBED_CODE_BUTTON_CLICKED), a.preventDefault(), a.stopPropagation()
},
focusEmbedCode: function() {
i.isMobile || this.embedCodeInput()[0].select()
},
focusLinkCode: function() {
i.isMobile || this.linkCodeInput()[0].select()
}
});
d.Model = j.extend({
prepare: function(a) {
var b = a,
c = b.permalink_url + (b.sharing === "private" ? "/" + b.secret_token : ""),
d;
b.share_url_twitter = c + "?utm_source=soundcloud&utm_campaign=wtshare&utm_medium=twitter&utm_content=" + c, b.share_url_email = encodeURIComponent(c + "?utm_source=soundcloud&utm_campaign=wtshare&utm_medium=email&utm_content=" + c), b.share_text = a.title + " by " + a.user_username, n.prepareButtons(b), b.socialnetworks = f.once(n.getButtons);
return b
}
})
}, require_modules[82] = function(a, b, c) {
var d = this,
e = c(1),
f = {
name: "widgetPopup",
height: 400,
width: 400,
location: !1,
toolbar: !1,
scrollbars: !0
},
g = function(a) {
var b = "location=" + (a.location ? "yes" : "no") + ", width=" + a.width + ", height=" + a.height + ", toolbar=" + (a.toolbar ? "yes" : "no") + ", scrollbars=" + (a.scrollbars ? "yes" : "no");
return b
},
h = b.exports = {
open: function(a, b) {
if (a && e.isString(a)) {
var c = e.extend({}, f, b);
return window.open(a, c.name, g(c))
}
}
}
}, require_modules[83] = function(a, b, c) {
var d = this,
e = c(13),
f = c(1),
g = c(19),
h = c(3).api,
i = function(a) {
return "shorten-url-" + a
},
j = f.extend({}, g, {
shorten: function(a) {
var b = this,
c = i(a.url),
d = this.get(c, !0);
if (d) a.callback(d);
else {
a = f.extend({
url: null,
callback: function(a) {},
timeout: 2e4,
error: function() {}
}, a);
var g = "https://api.soundcloud.com/e1/shorten?" + e.toQueryString({
url: a.url,
client_id: h.clientID
});
e.ajax({
url: g,
crossOrigin: !0,
success: function(e) {
d = e.responseText, b.set(c, d, !0);
return a.callback(d)
},
error: a.error,
type: "text",
timeout: a.timeout
})
}
}
});
b.exports = j
}, require_modules[84] = function(a, b, c) {
var d = this,
e, f = c(1),
g = c(85),
h = c(2),
i, j, k, l, m, n;
k = {
facebook: {
url: "https://www.facebook.com/dialog/feed?app_id=19507961798&display=popup&redirect_uri={{fb_popup_page_url}}&link={{share_url}}"
},
tumblr: {
url: "http://www.tumblr.com/share/audio?externally_hosted_url={{share_url}}"
},
reddit: {
url: "http://www.reddit.com/submit?url={{share_url}}"
},
blogger: {
url: "http://www.blogger.com/blog-this.g?n={{share_title}}&u={{share_url}} "
},
stumbleUpon: {
url: "http://www.stumbleupon.com/submit?url={{share_url}}&title={{share_title}}"
},
weibo: {
url: "http://service.weibo.com/share/share.php?url={{share_url}}"
},
orkut: {
url: "http://promote.orkut.com/preview?nt=orkut.com&tt={{share_title}}&du={{share_url}}"
},
vkontakte: {
url: "http://vkontakte.ru/share.php?url={{share_url}}"
},
mixi: {
url: "http://mixi.jp/share.pl?u={{share_url}}&k={{mixi_api_key}}"
},
tuenti: {
url: "http://www.tuenti.com/share?url={{share_url}}&suggested-text={{share_title}}"
}
}, l = {
global: ["tumblr", "facebook", "reddit", "blogger", "stumbleUpon"],
china: ["tumblr", "facebook", "blogger", "stumbleUpon", "weibo"],
brazil: ["tumblr", "facebook", "blogger", "stumbleUpon", "orkut"],
russia: ["tumblr", "facebook", "blogger", "stumbleUpon", "vkontakte"],
japan: ["tumblr", "facebook", "blogger", "stumbleUpon", "mixi"],
spain: ["tumblr", "facebook", "blogger", "stumbleUpon", "tuenti"]
}, m = function(a, b) {
var c = "Share to " + h.capitalize(a),
d = b.url;
f.each(j, function(a, b) {
d = d.replace("{{" + b + "}}", a)
});
return '<a class="sharepanel__icon sharepanel__' + a + 'Icon"' + ' href="' + d + '"' + ' target="_blank"' + ' share-icon="' + a + '"' + ' title="' + c + '">' + c + "</a>"
}, n = function() {
var a = "global";
g.isUsedLanguage("zh") ? a = "china" : g.isUsedLanguageAndCountry("pt-BR") ? a = "brazil" : g.isUsedLanguage("ru") || g.isUsedLanguage("uk") ? a = "russia" : g.isUsedLanguage("jp") ? a = "japan" : g.isUsedLanguageAndCountry("es-ES") && (a = "spain");
return l[a].map(function(a) {
return m(a, k[a])
})
}, e = b.exports = {
prepareButtons: function(a) {
j = {
share_title: a.title + " by " + a.user_username,
share_url: encodeURIComponent(a.permalink_url + (a.sharing === "private" ? "/" + a.secret_token : "")),
fb_popup_page_url: encodeURIComponent("http://w.soundcloud.com/player/fb_popup_callback.html"),
mixi_api_key: "1403ed11563185e9cff6cfeedf4f2ecf77fa459e"
}, i = n()
},
getButtons: function() {
return function(a, b) {
return b(i).join("")
}
}
}
}, require_modules[85] = function(a, b, c) {
var d = this,
e, f;
f = navigator.userLanguage || navigator.language || "", e = b.exports = {
isUsedLanguage: function(a) {
return f.split("-")[0] === a.toLowerCase()
},
isCountry: function(a) {
return f.split("-")[1] === a.toUpperCase()
},
isUsedLanguageAndCountry: function(a) {
return f === a
}
}
}, require_modules[86] = function(a, b, c) {
var d = this,
e, f = c(13),
g = c(1);
e = b.exports = {
getEmbedCode: function(a) {
var b = g.extend({
url: a.url,
format: "js"
}, a.params);
return f.ajax({
url: "http://soundcloud.com/oembed",
data: b,
type: "jsonp",
success: a.success,
error: a.error
})
}
}
}, require_modules[87] = function(a, b, c) {
function F(a) {
var b = {};
b.relativePosition = a.relative, b.loadedProgress = a.loadedProgress, b.currentPosition = a.position;
return b
}
function E(a) {
var b;
try {
b = JSON.parse(a.data)
} catch (c) {
return
}
var d = b.method;
if ( !! d) if (f.indexOf(m, d) > -1) z(d, w(d));
else if (f.indexOf(n, d) > -1) x(d, b.value);
else if (f.indexOf(o, d) > -1) {
var e = b.value;
e && (d === k.ADD_LISTENER ? C(e) : D(e))
}
}
function D(a) {
B(a) && (r = f.without(r, a))
}
function C(a) {
B(a) && r.push(a)
}
function B(a) {
return f.indexOf(f.values(j), a) > -1
}
function A(a, b, c) {
(c || f.indexOf(r, a) > -1) && z(a, b)
}
function z(a, b) {
if (!parent.postMessage || parent === window) return !1;
var c = JSON.stringify({
widgetId: y(),
method: a,
value: f.isUndefined(b) ? null : b
});
parent.postMessage(c, "*")
}
function y() {
window._widgetId = window._widgetId || g.getTimestamp();
return window._widgetId
}
function x(a, b) {
t(a) && s();
switch (a) {
case h.SET_VOLUME:
v().setVolume(b);
break;
case h.SEEK_TO:
v().seekTo(b);
break;
case h.PLAY:
v().play();
break;
case h.PAUSE:
v().pause();
break;
case h.TOGGLE:
v().toggle();
break;
case h.NEXT:
v().next();
break;
case h.PREV:
v().prev();
break;
case h.SKIP:
v().skip(b)
}
}
function w(a) {
var b;
u(a) && s();
switch (a) {
case i.GET_VOLUME:
b = v().getVolume();
break;
case i.GET_POSITION:
b = v().getPosition();
break;
case i.GET_DURATION:
b = v().getCurrentTrack().duration;
break;
case i.GET_CURRENT_SOUND:
b = v().getCurrentTrack();
break;
case i.GET_CURRENT_SOUND_INDEX:
b = p ? p.current : 0;
break;
case i.GET_SOUNDS:
b = p ? f.map(p.models, function(a) {
return a.toJSON()
}) : [v().getCurrentTrack()];
break;
case i.IS_PAUSED:
b = v().isPaused()
}
return b
}
function v() {
return l.getInstance()
}
function u(a) {
return f.indexOf(f.values(i), a) > -1
}
function t(a) {
return f.indexOf(f.values(h), a) > -1
}
function s() {
!l.getInstance().getCurrentTrack() && q && l.getInstance().setCurrentTrack(q)
}
var d = this,
e = c(13),
f = c(1),
g = c(2),
h = c(88),
i = c(89),
j = c(90).api,
k = c(90).bridge,
l = c(44),
m = f.values(i),
n = f.values(h),
o = f.values(k),
p, q, r = [],
G = !1,
H = b.exports = {
start: function() {
var a = c(91);
G || (window.addEventListener ? window.addEventListener("message", E, !1) : window.attachEvent("onmessage", E), f.each(a.audio, function(a, b) {
v().bind(a, function(a) {
A(b, F(a), b === j.PLAY)
})
}), f.each(a.ui, function(a, b) {
e(document).bind(a, function(a, c) {
c = c && c.shareButtonType ? c : null, A(b, c)
})
}), G = !0, z(j.READY))
},
setTracklist: function(a) {
p = a
},
setTrack: function(a) {
q = a
}
}
}, require_modules[88] = function(a, b, c) {
var d = this;
b.exports = {
PLAY: "play",
PAUSE: "pause",
TOGGLE: "toggle",
SEEK_TO: "seekTo",
SET_VOLUME: "setVolume",
NEXT: "next",
PREV: "prev",
SKIP: "skip"
}
}, require_modules[89] = function(a, b, c) {
var d = this;
b.exports = {
GET_VOLUME: "getVolume",
GET_DURATION: "getDuration",
GET_POSITION: "getPosition",
GET_SOUNDS: "getSounds",
GET_CURRENT_SOUND: "getCurrentSound",
GET_CURRENT_SOUND_INDEX: "getCurrentSoundIndex",
IS_PAUSED: "isPaused"
}
}, require_modules[90] = function(a, b, c) {
var d = this;
d.api = {
LOAD_PROGRESS: "loadProgres",
PLAY_PROGRESS: "playProgress",
PLAY: "play",
PAUSE: "pause",
FINISH: "finish",
SEEK: "seek",
READY: "ready",
OPEN_SHARE_PANEL: "sharePanelOpened",
SHARE: "share",
CLICK_DOWNLOAD: "downloadClicked",
CLICK_BUY: "buyClicked"
}, d.bridge = {
REMOVE_LISTENER: "removeEventListener",
ADD_LISTENER: "addEventListener"
}
}, require_modules[91] = function(a, b, c) {
var d = this,
e = c(48).Events,
f = c(28).Events,
g = c(81).Events,
h = c(90).api,
i = b.exports = {};
i.audio = {}, i.audio[h.PLAY_PROGRESS] = e.PLAYING, i.audio[h.PLAY] = e.PLAY, i.audio[h.PAUSE] = e.PAUSE, i.audio[h.FINISH] = e.FINISH, i.audio[h.LOAD_PROGRESS] = e.LOADING, i.audio[h.SEEK] = e.SEEK, i.ui = {}, i.ui[h.OPEN_SHARE_PANEL] = f.SHARE_PANEL_OPENED, i.ui[h.CLICK_DOWNLOAD] = f.DOWNLOAD_BUTTON_CLICKED, i.ui[h.CLICK_BUY] = f.BUY_BUTTON_CLICKED, i.ui[h.SHARE] = g.SHARE_BUTTON_CLICKED
}, require_modules[92] = function(a, b, c) {
var d = this;
1;
var e = c(93).View,
f = d.Events = {
CLOSE_BUTTON_CLICK: "close.closable"
},
g = d.View = e.extend({
options: {
template: '<div class="closable g-bg-trackpanel"><div class="closable__content g-all-transition"></div><div class="closable__closeButton g-close-button">close me</div></div>',
elementCssClass: "closable"
},
contentContainerSelector: ".closable__content",
getContentContainer: function() {
return this.$element.find(this.contentContainerSelector)
},
events: {
"click .closable__closeButton": "onCloseButtonClick"
},
onCloseButtonClick: function() {
this.trigger(f.CLOSE_BUTTON_CLICK)
}
})
}, require_modules[93] = function(a, b, c) {
var d = this,
e = c(1),
f = c(29).View,
g = d.View = f.extend({
getContentContainer: function() {},
renderDecorate: function() {
var a = this;
this.contentView && this.contentView.dispose();
var b = this.options.contentViewComponent;
this.contentView = new b({
el: this.getContentContainer(),
model: this.model,
isModelPopulated: this.options.isModelPopulated
}), this.contentView.bind("all", function(b) {
var c = e.toArray(arguments).slice(1);
a.trigger.apply(a, [b].concat(c))
})
}
})
}, require_modules[94] = function(a, b, c) {
var d = this;
1;
var e = c(29).View,
f = d.View = e.createView("error-message", {
options: {
template: '<div class="errorMessage">{{#server_error}}{{#error_50X}}<p class="g-bold">Oops, something went wrong.</p><p class="g-small">{{#singleTrack}} Please try again or check out this <a class="g-orange" href="{{permalink_url}}" target="_blank">sounds page</a> on SoundCloud. {{/singleTrack}}{{^singleTrack}} Please try again. {{/singleTrack}}</p>{{/error_50X}}{{#error_404}}<p class="g-bold">{{#appWidget}} This applications sounds are currently unavailable. {{/appWidget}}{{#userWidget}} This user is currently unavailable. {{/userWidget}}{{#groupWidget}} This group is currently unavailable. {{/groupWidget}}{{#favWidget}} This user is currently unavailable. {{/favWidget}}{{#setWidget}} This set is currently unavailable. {{/setWidget}}{{#singleTrack}} This sound is currently unavailable. {{/singleTrack}}</p>{{/error_404}}{{#error_connection}}<p class="g-bold">Oops, we cant reach SoundCloud.</p><p class="g-small"><a href="javascript:window.location.reload();" class="g-orange">Click to reload</a></p>{{/error_connection}}{{/server_error}}{{^server_error}}{{#non_embeddable}}{{#singleTrack}}<p class="g-bold">This sound cant be played outside of SoundCloud.</p>{{/singleTrack}}{{^singleTrack}}<p class="g-bold">These sounds cant be played outside of SoundCloud.</p>{{/singleTrack}}<p class="g-small"><a href="{{permalink_url}}" target="_blank" class="g-orange">Click here to listen</a></p>{{/non_embeddable}}{{/server_error}}{{#sound_error}}<p class="g-bold">Oops! SoundCloud doesnt fully support your browser yet, but we\'re working on it.</p><p>Meanwhile, please install <a href="http://get.adobe.com/flashplayer/" target="_blank">Adobe Flash</a> to help your browser load SoundCloud.</p>{{/sound_error}}<a class="errorMessage__link g-soundcloud-logo" href="{{^server_error}}{{permalink_url}}{{/server_error}}{{#error_404}}//soundcloud.com{{/error_404}}{{#error_50X}}{{#shareable}}{{permalink_url}}{{/shareable}}{{^shareable}}{{user_permalink_url}}{{/shareable}}{{/error_50X}}" target="_blank" title="Listen on SoundCloud">#</a></div>',
elementCssClass: "errorMessage"
}
})
}, require_modules[95] = function(a, b, c) {
var d = this,
e = c(53).Model,
f = c(52),
g = {
FAVORITES: "favorites",
TRACKS: "tracks"
},
h = d.Model = e.extend({
resourceType: "users",
prepare: function(a) {
var b = a;
b.avatar_large = f.from(b, f.SIZE.LARGE);
return b
},
getAdditionalParams: function(a) {
return {
order: a === g.FAVORITES ? "favorited_at" : "created_at"
}
},
getTotalTracks: function() {
var a = this.get("subresourceType");
return a === g.FAVORITES ? this.get("public_favorites_count") : this.get("track_count")
}
})
}, require_modules[96] = function(a, b, c) {
var d = this;
1;
var e = c(1),
f = c(29).View,
g = c(44),
h = c(48).Events,
i = c(95).Model,
j = c(42).ListEvents,
k = c(42).ListViewEvents,
l = c(28).View,
m = c(97).View,
n = c(97).List,
o = c(103).View,
p = c(87),
q = c(94).View,
r = d.Events = {
HEADER_CLICKED: "headerClicked.multi-tracks"
},
s = d.View = f.createView("multi-tracks", {
initialize: function() {
f.prototype.initialize.apply(this, arguments);
var a = g.getInstance();
a.bind(h.SKIP, e.bind(function(a) {
this.skip(a)
}, this)), a.bind(h.NEXT, e.bind(function() {
this.playNextTrack()
}, this)), a.bind(h.PREV, e.bind(function() {
this.playPrevTrack()
}, this)), this.model.get("url_auto_advance") && a.bind(h.FINISH, e.bind(function(a) {
var b = this.trackListCollection.getCurrent();
b.get("id") === a.track.id && this.playNextTrack()
}, this))
},
options: {
template: '<div class="multiTracks {{#setWidget}} multiTracks__setMode{{/setWidget}}{{#miscTracksWidget}} multiTracks__miscTracksMode{{/miscTracksWidget}}{{#detailedTrackList}} multiTracks__detailedMode{{/detailedTrackList}}">{{#available}}{{^server_error}}<div class="multiTracks__playerContainer">{{>single-track}}</div><div class="multiTracks__mainContentWrapper g-border-top g-shadow-top"><div class="multiTracks__mainContent"><div class="multiTracks__tracklistHeader">{{#name}}{{#appWidget}} Sounds created using the <a href="{{permalink_url}}" target="_blank" class="multiTracks__tracklistHeaderLink">{{name}}</a> application. {{/appWidget}}{{#groupWidget}} Sounds from the <a href="{{permalink_url}}" target="_blank" class="multiTracks__tracklistHeaderLink">{{name}}</a> group {{/groupWidget}}{{/name}}{{#username}}{{#userWidget}} Latest sounds by <a href="{{permalink_url}}" target="_blank" class="multiTracks__tracklistHeaderLink">{{username}}</a>{{/userWidget}}{{#favWidget}} Favorite sounds of <a href="{{permalink_url}}" target="_blank" class="multiTracks__tracklistHeaderLink">{{username}}</a>{{/favWidget}}{{/username}}</div><div class="multiTracks__tracklistContainerWrapper"><div class="multiTracks__tracklistContainer">{{>tracklist}}</div></div>{{#setWidget}}<div class="multiTracks__setDetailsContainer g-border-top g-shadow-top">{{>set-details}}</div>{{/setWidget}}</div></div>{{/server_error}}{{#server_error}}{{>error-message}}{{/server_error}}{{/available}}{{^available}}{{>error-message}}{{/available}}</div>',
elementCssClass: "multiTracks"
},
element2selector: {
playerViewContainer: ".multiTracks__playerContainer",
trackListViewContainer: ".multiTracks__tracklistContainer",
setDetailsContainer: ".multiTracks__setDetailsContainer"
},
events: {
"click .multiTracks__tracklistHeaderLink": "onHeaderClick"
},
onHeaderClick: function() {
this.notifyDocument(r.HEADER_CLICKED)
},
getAdditionalData: function() {
var a = f.prototype.getAdditionalData.apply(this, arguments),
b = this.options.widgetType,
c = this.options.subresourceType;
return e.extend(a, {
detailedTrackList: b !== "set",
miscTracksWidget: b !== "set",
setWidget: b === "set",
userWidget: b === "user" && c === "tracks",
groupWidget: b === "group",
favWidget: b === "user" && c === "favorites",
appWidget: b === "app"
})
},
canBeRendered: function(a) {
if (!this.model.hasDataFromAPI) return !1;
a.available = this.availableForThisDomain === undefined ? this.model.hasDataFromAPI : this.availableForThisDomain, this.availableForThisDomain && (a.available = a.tracks ? !! a.tracks.length : a.available), a.non_embeddable = !a.available;
var b = !a.setWidget || a.embeddable_by === "all" || this.availableForThisDomain !== undefined;
b || this.model.getDomainsLockings({
success: e.bind(function(b) {
this.availableForThisDomain = this.model.isLockedDomain(a, document.referrer, b);
if (this.availableForThisDomain) {
var c, d = e.filter(this.model.get("tracks"), function(a) {
c = b.filter(function(b) {
return b.track_id === a.id
});
return this.model.isLockedDomain(a, document.referrer, c)
}, this);
e.filter(d, function(a) {
a.embeddable_by = "all"
}), this.model.set({
tracks: d
})
}
this.render()
}, this),
error: e.bind(function() {
this.availableForThisDomain = !1, this.render()
}, this)
});
return b
},
renderDecorate: function(a) {
!a.available || (this.getTrackListCollection(function(a) {
p.setTracklist(a), p.start(), this.trackListCollection.bind(j.CURRENT_CHANGE, e.bind(this.onCurrentTrackChange, this)), a.setCurrent(this.model.get("url_start_track"), {
silent: !0
}), this.current = a.current, this.initTrackListView(), this.initPlayerView()
}), this.initSetDetailsView())
},
onCurrentTrackChange: function() {
this.playerView && this.playerView.model && this.initPlayerView()
},
getTrackListCollection: function(a) {
var b = this,
c = this.model.toJSON().tracks;
if (c && c.length) {
this.trackListCollection = new n(c);
return a.call(this, this.trackListCollection)
}
this.trackListCollection = new n([], {
url: this.model.getSubresourceUrl()
}), this.trackListCollection.fetch({
success: function() {
return a.call(b, b.trackListCollection)
}
})
},
initTrackListView: function() {
this.trackListView && this.trackListView.dispose();
var a = this.getAdditionalData(),
b = this.trackListView = this.initSubView(e.extend({
el: this.trackListViewContainer(),
component: m,
collection: this.trackListCollection,
model: null,
totalTracks: this.model.getTotalTracks(),
dynamicLoading: !a.setWidget
}, a));
b.bind(k.ITEM_CLICK, e.bind(function(a) {
this.toggleCurrentTrack(a || undefined)
}, this)), b.scrollToCurrent(!0)
},
initPlayerView: function() {
this.playerView && this.playerView.dispose(), this.playerView = this.initSubView({
el: this.playerViewContainer(),
component: l,
model: this.trackListCollection.getCurrent(),
userData: this.checkForUserData(),
isModelPopulated: !0
})
},
initSetDetailsView: function() {
this.initSubView({
component: o,
el: this.setDetailsContainer()
})
},
checkForUserData: function() {
var a = this.model instanceof i,
b = this.trackListCollection.getCurrent(),
c = this.model.toJSON();
if (a && (!b || b.toJSON().user_id === c.id)) return c;
return !1
},
playNextTrack: function() {
this.skip(parseInt(this.trackListCollection.current, 10) + 1)
},
playPrevTrack: function() {
this.skip(parseInt(this.trackListCollection.current, 10) - 1)
},
skip: function(a) {
a = parseInt(a, 10);
var b = this.trackListCollection.setCurrent(a);
b && this.toggleCurrentTrack(!0)
},
toggleCurrentTrack: function(a) {
var b = this.trackListCollection.getCurrent();
clearInterval(this.pollingRtmpUrlId), this.pollingRtmpUrlId = setInterval(e.bind(function() {
b.getRtmpUrl() !== undefined && (clearInterval(this.pollingRtmpUrlId), a = a ? a : undefined, g.getInstance().toggle(b.toJSON(), a))
}, this), 50)
}
})
}, require_modules[97] = function(a, b, c) {
var d = this;
1;
var e = c(1),
f = c(50).Model,
g = c(42).List,
h = c(98).View,
i = c(102).View,
j = d.Events = {
SCROLL_STARTED: "scrollStarted.tracklist",
EXTRA_FETCH: "extraFetch.tracklist"
},
k = d.constants = {
EVEN_CLASS: "tracklist__item__even",
ODD_CLASS: "tracklist__item__odd"
},
l = d.View = h.createView("tracklist", {
options: {
template: '<div class="tracklist g-selection-text{{#detailedTrackList}} tracklist__detailedMode{{/detailedTrackList}}"></div>',
elementCssClass: "tracklist",
wideIndex: "tracklist__wideIndex",
currentItemCssClass: "tracklist__item__currentState",
ListItemView: i
},
bindEventHandlers: function() {
h.prototype.bindEventHandlers.apply(this, arguments), this._onScrollHandler = e.bind(this.onTracklistScroll, this), this.$element.bind("scroll", this._onScrollHandler)
},
onTracklistScroll: function() {
this.$element.unbind("scroll", this._onScrollHandler), this.notifyDocument(j.SCROLL_STARTED)
},
onAdditionalFetch: function() {
this.notifyDocument(j.EXTRA_FETCH)
},
renderDecorate: function() {
h.prototype.renderDecorate.apply(this, arguments), this.collection.length >= 100 && this.getElement().addClass(this.options.wideIndex), this.initPagify()
},
notifyDocument: function(a) {
var b = {},
c = this._parentView,
d = c || this;
c && c.model ? b = c.model.toJSON() : this.collection.getCurrent() && (b = this.collection.getCurrent().toJSON()), h.prototype.notifyDocument.call(d, a, b)
},
setListItemIndex: function(a) {
h.prototype.setListItemIndex.apply(this, arguments);
var b = this.collection.getModelIndex(a.model);
a.getElement().addClass(b % 2 ? k.ODD_CLASS : k.EVEN_CLASS)
}
}),
m = d.List = g.extend({
model: f,
baseUrl: function() {
return this.options.url
},
parse: function(a) {
return e.filter(a, function(a) {
return !!a.stream_url && a.embeddable_by === "all"
})
},
_prepareModel: function(a) {
a = g.prototype._prepareModel.apply(this, arguments), e.extend(a.attributes, {
_index_: this.length + 1
});
return a
}
})
}, require_modules[98] = function(a, b, c) {
var d = this,
e = c(13),
f = c(1),
g = c(42).ListView,
h = c(99),
i = c(29).View,
j = c(101),
k = g,
l = k.prototype,
m = function(a) {
this.view = a
};
m.prototype.render = function() {
return this.view.el
};
var n = d.View = g.extend(f.extend({}, h, {
initialize: function() {
this.scrollingItems = [], l.initialize.apply(this, arguments), this.initScrollBar()
},
disposeDecorate: function() {
this.scrollbar.dispose(), this.pagify.dispose()
},
scrollToCurrent: function(a) {
this.currentItemNode && this.scrollTop(this.currentItemNode[0].offsetTop), this.scrollbar[a ? "hide" : "show"]()
},
addListItem: function(a, b) {
var c = this.renderListItem(a);
this.scrollingItems.push(new m(c)), this.setListItemIndex(c), this.listItemViews.push(c)
},
renderDecorate: function() {
g.prototype.renderDecorate.apply(this, arguments), this.initPagify()
},
initPagify: function() {
var a = this.getElement()[0],
b = 0,
c = 50,
d, e;
this.pagify = j(a, this.scrollingItems, this.$element[0], {
minActivationSize: c + 1
}), this.options.dynamicLoading && (e = f.bind(function(a, b) {
b.length && (this.pagify.refresh(), this.pagify.on("nearEnd", d), this.scrollbar.reset())
}, this), d = f.bind(function() {
this.pagify.off("nearEnd"), b += c;
if (this.options.totalTracks === null || b <= this.options.totalTracks) this.onAdditionalFetch(), this.collection.fetch({
data: {
offset: b,
limit: c
},
add: !0,
success: e
})
}, this), this.pagify.on("nearEnd", d))
},
onAdditionalFetch: function() {}
}))
}, require_modules[99] = function(a, b, c) {
var d = this,
e = c(100),
f = b.exports = {
initScrollBar: function() {
this.scrollbar = new e(this.el[0])
},
scrollTop: function(a) {
return this.scrollbar.scrollTop(a)
}
}
}, require_modules[100] = function(a, b, c) {
var d = this,
e = c(1),
f = c(13),
g = c(5),
h = c(4),
i = b.exports = function(a, b) {
this.container = a, this.$container = f(this.container), this.scrollHeight = this.$container.height(), this.options = e.defaults(b || {}, {
scrollBarClass: "g-scrollBar",
visibleBarClass: "g-scrollBar__visible",
thumbClass: "g-scrollBar__thumbClass",
thumbHoverClass: "g-scrollBar__thumbHoverClass"
}), this.bottomDelta = 10, this.minThumbHeight = 40, this.touchScroll = this.isTouchScrollAvailable();
this.touchScroll ? this.createTouchScroll() : (this.createScrollBar(), this.bindEventHandlers(), this.isInited = !0, this.update(!0), this.hide())
};
i.prototype = {
constructor: i,
createScrollBar: function() {
this.container.style.overflow = "hidden", this.thumb = document.createElement("div"), this.thumb.className = this.options.thumbClass, this.$thumb = f(this.thumb), this.scrollBar = document.createElement("div"), this.scrollBar.className = this.options.scrollBarClass, this.scrollBar.appendChild(this.thumb), this.$scrollBar = f(this.scrollBar), this.container.parentNode.insertBefore(this.scrollBar, this.container.nextSibling)
},
createTouchScroll: function() {
this.container.style.overflow = "auto", this.container.style["-webkit-overflow-scrolling"] = "touch", this.container.childNodes[0].style.webkitTransform = "translate3d(0,0,0)"
},
bindEventHandlers: function() {
var a = e.bind(this.hide, this),
b = e.bind(this.show, this);
this.$container.bind("mousewheel", e.bind(this.onMouseWheel, this)), this.$container.bind("mouseenter", b), this.$container.bind("mouseleave", a), this.$thumb.bind("mouseenter", b), this.$thumb.bind("mouseleave", a), this.$thumb.bind("mousedown", e.bind(this.onMouseDown, this)), f(window).resize(e.debounce(e.bind(this.reset, this), 250))
},
dispose: function() {
this.$container.unbind(), this.$thumb.unbind()
},
reset: function() {
this.show(), this.actualHeight = null, this.update(!0, !0)
},
checkEvent: function(a) {
return a && (a.which > 1 || a.button > 1 || a.ctrlKey || a.shiftKey || h.isMac && a.metaKey)
},
onMouseDown: function(a) {
!this.moveY && !this.checkEvent(a) && (this.isMouseDown = !0, f(window.document).on("mousemove.scrollbar", e.bind(this.onMouseMove, this)), f(window.document).on("mouseup.scrollbar", e.bind(this.onMouseUp, this)), this.moveY = a.clientY - (this.thumb.offsetTop || 0), window.document.body.style.cursor = "pointer", this.$thumb.addClass(this.options.thumbHoverClass), a.preventDefault(), a.stopPropagation())
},
onMouseMove: function(a) {
this.container.scrollTop = Math.floor((this.getActualHeight() - this.scrollHeight) * Math.min(1, (a.clientY - this.moveY) / (this.scrollHeight - this.thumbHeight - this.bottomDelta))), this.update(!0), a.preventDefault(), a.stopPropagation()
},
onMouseUp: function(a) {
this.moveY = !1, this.isMouseDown = !1, f(window.document).unbind("mousemove.scrollbar"), f(window.document).unbind("mouseup.scrollbar"), window.document.body.style.cursor = "default", this.$thumb.removeClass(this.options.thumbHoverClass), a.preventDefault(), a.stopPropagation()
},
onMouseWheel: function(a) {
a || (a = window.event);
var b = 0;
a.wheelDeltaY || a.wheelDelta ? b = (a.wheelDeltaY || a.wheelDelta) / 2 : a.detail && (b = -a.detail * 10);
var c = this.container.scrollTop;
this.container.scrollTop -= b, c !== this.container.scrollTop && this.isHidden !== !0 && (this.update(!0), this.$thumb.addClass(this.options.thumbHoverClass), clearTimeout(this.moveTimeout), this.moveTimeout = setTimeout(e.bind(function() {
this.$thumb.removeClass(this.options.thumbHoverClass)
}, this), 150)), this.isHidden || (a.preventDefault(), a.stopPropagation())
},
getActualHeight: function() {
if (this.actualHeight) return this.actualHeight;
var a = this.container.childNodes,
b = 0,
c = a.length;
while (c--) b += a[c].offsetHeight || 0;
this.actualHeight = b;
return b
},
hide: function() {
this.touchScroll || this.isHidden || this.isMouseDown || (this.$scrollBar.removeClass(this.options.visibleBarClass), this.isHidden = !0)
},
show: function() {
!this.touchScroll && this.isHidden !== !1 && (this.$scrollBar.addClass(this.options.visibleBarClass), this.isHidden = !1)
},
scrollTop: function(a) {
this.container.scrollTop = parseInt(a, 10), this.update(!0, !0)
},
update: function(a, b) {
if (!(this.touchScroll || !this.isInited || this.isHidden)) {
if (!a) {
this.containerHeight = !1;
if (this.moveY) return !0
}
b && (this.scrollHeight = this.$container.height());
var c = this.getActualHeight();
if (c <= this.scrollHeight) {
this.thumb.style.display = "none";
return
}
this.thumb.style.display = "block";
var d = this.lastProgress = Math.min(1, this.container.scrollTop / (c - this.scrollHeight));
this.thumbHeight = Math.max(this.minThumbHeight, Math.floor(this.scrollHeight * this.scrollHeight / c)), this.thumb.style.height = this.thumbHeight + "px", this.thumb.style.marginTop = Math.floor((this.scrollHeight - this.thumbHeight - this.bottomDelta) * d) + this.bottomDelta / 2 + "px"
}
},
isTouchScrollAvailable: function() {
return window.ontouchstart
}
}
}, require_modules[101] = function(a, b, c) {
var d = this;
(function(a, c) {
function u() {
o.call(this), r.call(this)
}
function t() {
p.call(this), s.call(this), delete this.parent, delete this.container, delete this.items, delete this.events, delete this.listeners
}
function s() {
this.listeners.scroll && (this.parent.removeEventListener ? this.parent.removeEventListener("scroll", this.listeners.scroll) : this.parent.detachEvent && this.parent.detachEvent("onscroll", this.listeners.scroll), delete this.listeners.scroll)
}
function r() {
this.listeners.scroll || (this.listeners.scroll = i(q.bind(this), 250, !0), this.parent.addEventListener ? this.parent.addEventListener("scroll", this.listeners.scroll, !1) : this.parent.attachEvent("onscroll", this.listeners.scroll))
}
function q() {
var a = h(this.parent),
b = f(this.parent),
c = e(this.container),
d = 200;
a + b + d > c && k.call(this, "nearEnd")
}
function p() {
this.listeners.redraw && (this.parent.removeEventListener ? (this.parent.removeEventListener("scroll", this.listeners.redraw.scroll, !1), a.removeEventListener("resize", this.listeners.redraw.resize, !1)) : this.parent.detachEvent && (this.parent.detachEvent("onscroll", this.listeners.redraw.scroll), a.detachEvent("onresize", this.listeners.redraw.resize)), delete this.listeners.redraw)
}
function o() {
this.listeners.redraw || (this.listeners.redraw = {
scroll: i(m.bind(this), 200, !0),
resize: i(n.bind(this), 200, !0)
}, this.parent.addEventListener ? (this.parent.addEventListener("scroll", this.listeners.redraw.scroll, !1), a.addEventListener("resize", this.listeners.redraw.resize, !1)) : this.parent.attachEvent && (this.parent.attachEvent("onscroll", this.listeners.redraw.scroll), a.attachEvent("onresize", this.listeners.redraw.resize)))
}
function n() {
if (this.items.length) {
if (this.itemHeight == null) {
var a = this.items[0].render();
this.container.style.visibility = "hidden", this.container.appendChild(a), this.itemHeight = e(a), this.container.removeChild(a), this.container.style.visibility = ""
}
this.pageSize = Math.ceil(f(this.parent) / this.itemHeight), m.call(this)
}
}
function m() {
var a, b, c, d, e, f, i, j, m, n, q, r, s, t;
if (this.items.length < this.options.minActivationSize) p.call(this), l.call(this, 0, this.items.length - 1), t = {
top: 0,
bottom: 0
};
else {
o.call(this), j = Math.floor(h(this.parent) / this.itemHeight), e = Math.max(0, j - this.pageSize), f = Math.min(this.items.length - 1, j + this.pageSize * 2), i = this.lastFirstItemIndex == null, this.lastFirstItemIndex = i ? e : this.lastFirstItemIndex, this.lastLastItemIndex = i ? f : this.lastLastItemIndex;
if (i || e !== this.lastFirstItemIndex || f !== this.lastLastItemIndex) {
r = this.items.slice(e, f + 1);
for (a = g(this.container); a--;) {
s = !1;
for (c = 0, d = r.length; c < d; c++) if (r[c].node === this.container.children[a]) {
s = !0;
break
}
s || k.call(this, "remove", this.container.removeChild(this.container.children[a]))
}
l.call(this, e, f), this.lastFirstItemIndex = e, this.lastLastItemIndex = f
}
t = {
top: e * this.itemHeight,
bottom: Math.max(0, this.items.length - f - 1) * this.itemHeight
}, t.bottom === 0 && parseInt(this.container.style.paddingBottom, 10) && k.call(this, "nearEnd")
}
this.container.style.paddingTop = t.top + "px", this.container.style.paddingBottom = t.bottom + "px"
}
function l(a, b) {
var c, d, e, f;
for (c = b; c >= a; --c) d = this.items[c + 1] && this.items[c + 1].render(), e = this.items[c].render(), f = !e.parentNode, d && d.parentNode === this.container ? this.container.insertBefore(e, d) : this.container.appendChild(e), f && k.call(this, "insert", this.items[c], e)
}
function k(a) {
var b, c, d;
if (this.events && this.events[a]) {
d = Array.prototype.slice.call(arguments, 1);
for (b = 0, c = this.events[a].length; b < c; ++b) this.events[a][b].apply(this, d)
}
}
function j(b, c, d, e) {
this.parent = d || a, this.container = b, this.items = c, this.events = {}, this.listeners = {}, this.options = e || {}
}
function i(a, b, c) {
b || (b = 100);
var d = 0,
e, f, g, h = c === !1 ? 0 : b;
return function() {
function k() {
e && (e = clearTimeout(e)), a.apply(j, i), d = f
}
var f = +(new Date),
g = f - d - h,
i = arguments,
j = this;
g > b ? k() : !e && c !== !1 && (e = setTimeout(k, b))
}
}
function h(b) {
var d;
b === a ? a.pageYOffset ? d = a.pageYOffset : c.documentElement && c.documentElement.scrollTop ? d = c.documentElement.scrollTop : c.body && (d = c.body.scrollTop) : d = b.scrollTop;
return d || 0
}
function g(a) {
var b = a.childNodes,
c = [],
d, e, f;
for (d = 0, e = b.length; d < e; d++) f = b[d], f.nodeType === 1 && c.push(f);
return c.length
}
function f(b) {
var d = "inner";
"innerWidth" in b || (d = "client", b === a && (b = c.documentElement || c.body));
return b[d + "Height"]
}
function e(a) {
return a.offsetHeight
}
var d;
Function.prototype.bind || (Function.prototype.bind = function(a) {
var b = [].slice,
c = b.call(arguments, 1),
d = this,
e = function() {},
f = function() {
return d.apply(this instanceof e ? this : a || {}, c.concat(b.call(arguments)))
};
e.prototype = d.prototype, f.prototype = new e;
return f
}), j.prototype.refresh = n, j.prototype.on = function(a, b) {
this.events[a] || (this.events[a] = []), this.events[a].push(b)
}, j.prototype.off = function(a, b) {
if (!b) this.events[a] = [];
else if (this.events[a] && this.events[a].length) {
var c, d;
for (c = 0, d = this.events[a].length; c < d; ++c) this.events[a][c] === b && this.events.splice(c, 1)
}
}, j.prototype.dispose = t, d = function(a, b, c, d) {
var e = new j(a, b, c, d);
u.call(e), n.call(e);
return e
}, typeof b != "undefined" && b.exports ? b.exports = d : a.pagify = d
})(window, document)
}, require_modules[102] = function(a, b, c) {
var d = this;
1;
var e = c(29).View,
f = c(58).View,
g = c(59).View,
h = d.View = e.createView("tracklist-item", {
options: {
elementCssClass: "tracklist__item",
template: '{{^detailedTrackList}}<div class="tracklist__item"><div class="tracklist__itemContent"><span class="tracklist__stats">{{>track-stats}}</span><div class="tracklist__trackTitleWrapper"><div class="tracklist__trackTitle"><div class="tracklist__index">{{_index_}}.</div>{{title}}<span class="tracklist__trackLength">{{duration_timecode}}</span></div></div></div></div>{{/detailedTrackList}}{{#detailedTrackList}}<div class="tracklist__item"><div class="tracklist__itemContent"><div class="tracklist__trackTitleWrapper"><img class="tracklist__trackArtwork" src="{{track_artwork}}"><div class="tracklist__title">{{>track-title}}</div><div class="tracklist__stats">{{>track-stats}}</div></div></div></div>{{/detailedTrackList}}'
},
element2selector: {
trackStatsContainer: ".tracklist__stats"
},
renderDecorate: function() {
this.initSubView({
component: f,
el: this.trackStatsContainer()
})
}
})
}, require_modules[103] = function(a, b, c) {
var d = this;
1;
var e = c(29).View,
f = d.Events = {
UPLOADER_CLICKED: "uploaderClicked.setDetails",
ARTWORK_CLICKED: "artworkClicked.setDetails"
},
g = d.View = e.createView("set-details", {
options: {
elementCssClass: "setDetails",
template: '<div class="setDetails"><div class="setDetails__content">{{#shareable}}<a class="setDetails__artworkLink" href="{{permalink_url}}" target="_blank"><img src="{{set_artwork_url}}"></a>{{/shareable}}{{^shareable}}<img class="setDetails__artwork" src="{{set_artwork_url}}">{{/shareable}}<div class="setDetails__mainContent"><a class="setDetails__shareLink" href="#"><span class="setDetails__shareLinkIcon">Share</span></a>{{#buyable}}<a class="setDetails__buy g-button g-button" href="{{purchase_url}}" target="_blank"><span>{{purchase_title}}</span></a>{{/buyable}}{{#url_show_user}}<p class="setDetails__userName"><a class="setDetails__userName" href="{{user_permalink_url}}" target="_blank">{{user_username}}</a></p>{{/url_show_user}}<p class="setDetails__title">{{#shareable}}<a class="setDetails__title" href="{{permalink_url}}" target="_blank">{{title}}</a>{{/shareable}}{{^shareable}}<span class="setDetails__title">{{title}}</span>{{/shareable}}</p></div></div></div>'
},
events: {
"click a.setDetails__userName": "onUploaderClick",
"click .setDetails__artworkLink": "onArtworkClick"
},
onArtworkClick: function() {
this.notifyDocument(f.ARTWORK_CLICKED)
},
onUploaderClick: function() {
this.notifyDocument(f.UPLOADER_CLICKED)
}
})
}, require_modules[104] = function(a, b, c) {
var d = this,
e = c(53).Model,
f = c(54),
g = d.Model = e.extend({
resourceType: "playlists",
getTotalTracks: function() {
return this.get("tracks").length
},
prepare: function() {
var a = e.prototype.prepare.apply(this, arguments);
a.purchase_title = f.getPurchaseTitle(a, "Buy all");
return a
}
})
}, require_modules[105] = function(a, b, c) {
var d = this,
e = c(53).Model,
f = d.Model = e.extend({
resourceType: "apps",
getAdditionalParams: function(a) {
return {
order: "hotness"
}
},
getTotalTracks: function() {
return undefined
}
})
}, require_modules[106] = function(a, b, c) {
var d = this,
e = c(53).Model,
f = d.Model = e.extend({
resourceType: "groups",
getTotalTracks: function() {
return null
}
})
}, require_modules[107] = function(a, b, c) {
var d = this,
e = c(13),
f = c(1),
g = c(108),
h = c(11),
i = c(67),
j = c(8),
k = c(48).Events,
l = c(57).Events,
m = c(28).Events,
n = c(81).Events,
o = c(68).Events,
p = c(59).Events,
q = c(96).Events,
r = c(103).Events,
s = c(97).Events,
t = c(79).Events,
u = c(28).Events,
v = {
facebook: "liked",
twitter: "tweeted",
google: "plus one"
},
w = j.parse(document.referrer).host,
x = decodeURIComponent(j.getUrlParams().url),
y = 0,
z = "widgetshare",
A = "UI",
B = "Tracks",
C = "Error",
D = {},
E = {},
F = /Location\.toString/,
G, H, I, J, K, L, M, N = b.exports = {
init: function() {
var a = e(document),
b = [k, n, o, m, l, p, r, s, q, t, u];
f.each(b, function(b) {
f.each(b, function(b) {
a.bind(b, I)
})
}), a.bind(h.SERVER_ERROR_EVENT, G), window.onerror = H, g.trackPageView(y, w + "::" + x)
}
};
G = function(a) {
L(C, a.status + " - " + a.statusText, "url:" + a.url)
}, H = function(a, b, c) {
F.test(a || "") || L(C, "JS - " + a, "file:" + b + "; line:" + c);
return !1
}, I = function(a, b, c) {
b.track && (b = b.track);
var d, e, f, g = b.permalink_url,
h = !1,
i = !1,
j;
switch (a) {
case u.LIKE_BUTTON_CLICKED:
d = A, e = "Like button clicked", j = "Like";
break;
case t.INPUT_FOCUSED:
d = A, e = "Comment form focused", j = "Comment_main", h = !0;
break;
case t.FORM_SUBMIT:
d = A, e = "Comment form submit";
break;
case t.COMMENT_POSTED:
d = A, e = "Comment has been posted", j = "Comment_post";
break;
case o.SEEKED:
d = A, e = "Seeking in the waveform";
break;
case n.EMBED_CODE_BUTTON_CLICKED:
d = A, e = "Share panel - embed code button clicked", j = "Share::embed";
break;
case n.LINK_BUTTON_CLICKED:
d = A, e = "Share panel - link button clicked", j = "Share::link";
break;
case n.EMBED_CODE_INPUT_CLICKED:
d = A, e = "Share panel - embed code input clicked";
break;
case n.LINK_INPUT_CLICKED:
d = A, e = "Share panel - link input clicked";
break;
case m.SHARE_PANEL_OPENED:
d = A, e = "Share panel opened", j = "Share_main";
break;
case m.DOWNLOAD_BUTTON_CLICKED:
d = A, e = "Player - download button clicked", j = "Download";
break;
case m.BUY_BUTTON_CLICKED:
d = A, e = "Player - buy button clicked", j = "Buy";
break;
case m.SCRUBBER_CLICKED:
d = A, e = "Waveform Click Play", j = "Waveform Click Play", i = !0;
break;
case l.CLICKED:
d = A, e = "Artwork cliked", j = "Artwork clicked";
break;
case l.HOVERED:
d = A, e = "Artwork hover", j = "Artwork hover";
break;
case s.SCROLL_STARTED:
d = A, e = "Playlist Scroll", j = "Playlist Scroll";
break;
case s.EXTRA_FETCH:
d = A, e = "Playlist Scroll 50";
break;
case p.TITLE_CLICKED:
d = A, e = "Sound Title Link Click", j = "Links_to_mothership::title_link";
break;
case p.UPLOADER_CLICKED:
d = A, e = "Sound Uploader Link Click", j = "Links_to_mothership::uploader_link";
break;
case q.HEADER_CLICKED:
d = A, e = "Set Title Link Click";
break;
case r.UPLOADER_CLICKED:
d = A, e = "Set Uploader Link Click";
break;
case r.ARTWORK_CLICKED:
d = A, e = "Set Artwork Click", j = "Artwork clicked";
break;
case n.SHARE_ICON_CLICKED:
d = z, f = b.shareIconType, e = f + " - clicked", j = "Share::" + f, K(f, g, !0);
break;
case n.EMAIL_BUTTON_CLICKED:
d = z, e = "email - clicked", j = "Share::email", K(f, g, !0);
break;
case n.SHARE_BUTTON_CLICKED:
d = z, f = b.shareButtonType, e = f + " - " + v[f], j = "Share::" + f + "_" + v[f], K(f, g);
break;
case k.PLAY:
d = B, e = "Track Play", j = "play", h = !0;
break;
case k.PAUSE:
d = B, e = "Track Pause", j = "pause", h = !0;
break;
case k.PROGRESS_10:
d = B, e = "10percent", h = !0;
break;
case k.PROGRESS_95:
d = B, e = "95percent", h = !0;
break;
case k.FINISH:
d = B, e = "Track Complete", j = "stop", h = !0;
break;
case k.BLOCKED:
d = C, e = "Flash Blocked"
}
d && e && L(d, e, g, h), j && (d === B ? J(j, g, b) : M(j, g, i))
}, K = function(a, b, c) {
var d = c ? "share icon is clicked" : v[a];
_gaq.push(["_trackSocial", a, d, b])
}, L = function(a, b, c, d) {
var e = [a, b, c].join("::");
if (d) {
D.hasOwnProperty(c) || (D[c] = {});
if (!D[c].hasOwnProperty(b)) D[c][b] = !0;
else return
}
a === C && g.trackClick(y, e), _gaq.push(["_trackEvent", a, b, c])
}, J = function(a, b, c) {
var d = ["sound", w, c.permalink_url].join("::"),
e = i.precise(c.duration / 1e3, 1),
f = i.precise(e / 4, 1);
g.trackAudioEvent(y, d, a, f, e)
}, M = function(a, b, c) {
var d = [a, b, w].join("::");
if (c) {
E.hasOwnProperty(b) || (E[b] = {});
if (!E[b].hasOwnProperty(a)) E[b][a] = !0;
else return
}
g.trackClick(y, d)
}
}, require_modules[108] = function(a, b, c) {
var d = this,
e;
e = b.exports = {
trackPageView: function(a, b) {
typeof xt_med == "function" ? xt_med("F", a, b) : setTimeout(function() {
typeof xt_med == "function" && xt_med("F", a, b)
}, 1e3)
},
trackAudioEvent: function(a, b, c, d, e) {
typeof xt_rm == "function" && xt_rm("audio", a, b, c, "", d, e, "", "", "", "int", "clip", "")
},
trackClick: function(a, b) {
typeof xt_med == "function" && xt_med("A", a, b)
}
}
}, require(0)
})();
SC.setBootstrapperConfig({
"version": "9a9b4035cba959764bc91eed3a02a24de76a1f58",
"debug": false,
"clearSessionStorage": false
}); |