SoundCloud speed playback

speed playback for soundcloud wow

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Greasemonkey lub Violentmonkey.

You will need to install an extension such as Tampermonkey to install this script.

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Violentmonkey.

Aby zainstalować ten skrypt, wymagana będzie instalacja rozszerzenia Tampermonkey lub Userscripts.

You will need to install an extension such as Tampermonkey to install this script.

Aby zainstalować ten skrypt, musisz zainstalować rozszerzenie menedżera skryptów użytkownika.

(Mam już menedżera skryptów użytkownika, pozwól mi to zainstalować!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Musisz zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

(Mam już menedżera stylów użytkownika, pozwól mi to zainstalować!)

// ==UserScript==
// @name         SoundCloud speed playback
// @namespace    http://tampermonkey.net/
// @version      5.0
// @description  speed playback for soundcloud wow
// @author       You
// @match        https://soundcloud.com/*
// @grant        none
// @run-at       document-start
// ==/UserScript==

(function(){'use strict';var faelikesmechfags=1,faelikesmechfags2=null,faelikesmechfags3=null,faelikesmechfags4=Object.getOwnPropertyDescriptor(HTMLMediaElement.prototype,'playbackRate');Object.defineProperty(HTMLMediaElement.prototype,'playbackRate',{get:function(){return faelikesmechfags},set:function(){faelikesmechfags4.set.call(this,faelikesmechfags)},configurable:true});function faelikesmechfags5(){var a=document.querySelector('audio');a&&faelikesmechfags4.set.call(a,faelikesmechfags)}var faelikesmechfags6=document.createElement;document.createElement=function(t){var e=faelikesmechfags6.call(document,t);if(t.toLowerCase()==='audio'){setTimeout(()=>faelikesmechfags4.set.call(e,faelikesmechfags),0);['loadstart','loadeddata','loadedmetadata','canplay','canplaythrough','play','playing','timeupdate','seeking','seeked','pause','ratechange'].forEach(n=>e.addEventListener(n,()=>faelikesmechfags4.set.call(e,faelikesmechfags)))}return e};function faelikesmechfags7(){var d=document.createElement('div');d.id='soundcloud-speed-control';d.style.cssText='display:inline-flex;align-items:center;gap:6px;margin-left:12px;padding:4px 8px;background:rgba(23,24,26,1);border-radius:4px';var l=document.createElement('span');l.textContent='Speed:';l.style.cssText='font-size:12px;color:#ccc;font-weight:500';var s=document.createElement('select');s.style.cssText='background:#333;color:#fff;border:1px solid #555;border-radius:3px;padding:4px 6px;font-size:12px;cursor:pointer;outline:none';[0.25,0.5,0.75,1,1.25,1.5,1.75,2].forEach(v=>{var o=document.createElement('option');o.value=v;o.textContent=v===1?'Normal':v+'x';v===faelikesmechfags&&(o.selected=true);s.appendChild(o)});s.addEventListener('change',e=>{faelikesmechfags=parseFloat(e.target.value);var a=document.querySelector('audio');if(a)for(let i=0;i<10;i++)setTimeout(()=>faelikesmechfags4.set.call(a,faelikesmechfags),i*20)});d.append(l,s);return d}function faelikesmechfags8(){if(faelikesmechfags2&&document.body.contains(faelikesmechfags2))return true;for(const s of ['.playControls__elements','.playbackSoundBadge__actions','.playControls__inner','.playbackTimeline__duration']){var t=document.querySelector(s);if(t&&!document.getElementById('soundcloud-speed-control')){faelikesmechfags2&&faelikesmechfags2.remove();faelikesmechfags2=faelikesmechfags7();t.appendChild(faelikesmechfags2);return true}}return false}function faelikesmechfags9(){var i=setInterval(()=>{faelikesmechfags8()&&clearInterval(i)},500);faelikesmechfags3&&clearInterval(faelikesmechfags3);faelikesmechfags3=setInterval(faelikesmechfags5,50)}document.readyState==='loading'?document.addEventListener('DOMContentLoaded',faelikesmechfags9):faelikesmechfags9();window.addEventListener('load',()=>setTimeout(faelikesmechfags9,500));let faelikesmechfags10=location.href;new MutationObserver(()=>{location.href!==faelikesmechfags10&&(faelikesmechfags10=location.href,setTimeout(faelikesmechfags9,1000))}).observe(document,{subtree:true,childList:true})})();