Advertisement
daviidsebastiian96

〘ツ〙Youtube Mp3〘ツ〙Source

Oct 10th, 2022 (edited)
245
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.28 KB | None | 0 0
  1. (function() {
  2. if (document.getElementById("browser-app") || document.getElementById("masthead") || window.Polymer) {
  3. setInterval(function() {
  4. if (window.location.href.indexOf("watch?v=") < 0) {
  5. return false;
  6. }
  7. if (document.getElementById("meta-contents") && document.getElementById("punisherx") === null) {
  8. AddYT();
  9. }
  10. }, 1);
  11.  
  12. setElement = function(url) {
  13. var regExp = /^.*((youtu.be\/)|(v\/)|(\/u\/\w\/)|(embed\/)|(watch\?))\??v?=?([^#\&\?]*).*/;
  14. var match = String(url).match(regExp);
  15. return (match&&match[7].length==11)? match[7]: false;
  16. };
  17. }
  18.  
  19. function AddYT() {
  20. var buttonDiv = document.createElement("span");
  21. buttonDiv.id = "punisherx";
  22. buttonDiv.style.width = "100%";
  23. buttonDiv.style.marginTop = "3px";
  24. buttonDiv.style.padding = "10px 0";
  25. var addButton = document.createElement("a");
  26. addButton.appendChild(document.createTextNode("📥 MP3🔊"));
  27. addButton.style.width = "100%";
  28. addButton.style.cursor = "pointer";
  29. addButton.style.height = "inherit";
  30. addButton.style.backgroundColor = "#393939";
  31. addButton.style.color = "#ffffff";
  32. addButton.style.padding = "10px 22px";
  33. addButton.style.margin = "0px 0px";
  34. addButton.style.border = "0";
  35. addButton.style.borderRadius = "2px";
  36. addButton.style.fontSize = "1.4rem";
  37. addButton.style.fontFamily = "inherit";
  38. addButton.style.textAlign = "center";
  39. addButton.style.textDecoration = "none";
  40. addButton.href = "//getmp3.pro/" + encodeURIComponent(setElement(window.location)) + "/5lbz9DG7q6uzW5PQazmMs5YP2EWzJrCN9ree5WqEt8N/mp3_128";
  41. addButton.target = "_blank";
  42. buttonDiv.appendChild(addButton);
  43. var targetElement = document.querySelectorAll("[id='subscribe-button']");
  44. if(targetElement){
  45. for(var i = 0; i < targetElement.length; i++){
  46. if(targetElement[i].className.indexOf("ytd-video-secondary-info-renderer") > -1){
  47. targetElement[i].appendChild(buttonDiv);
  48. }
  49. }
  50. }
  51. var descriptionBox = document.querySelectorAll("ytd-video-secondary-info-renderer");
  52. if(descriptionBox[0].className.indexOf("loading") > -1){
  53. descriptionBox[0].classList.remove("loading");
  54. }
  55. }
  56. })();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement