YouTube Studio Scheduled Date Visual Enhancer

Sort YouTube Studio videos by scheduled and published date easier through visual cues (border and bgcolor)

  1. // ==UserScript==
  2. // @name YouTube Studio Scheduled Date Visual Enhancer
  3. // @description Sort YouTube Studio videos by scheduled and published date easier through visual cues (border and bgcolor)
  4. // @version 2
  5. // @grant none
  6. // @require https://ajax.googleapis.com/ajax/libs/jquery/3.4.1/jquery.min.js
  7. // @match https://studio.youtube.com/channel/*/videos/upload*
  8. // @namespace ปวัตน
  9. // ==/UserScript==
  10. console.log("YouTube Studio Scheduled Date Visual Enhancer running");
  11. window.addEventListener('load', function() {
  12.  
  13. this.$ = this.jQuery = jQuery.noConflict(true);
  14. var timerVar = setInterval (function() {DoMeEverySecond (); }, 5000);
  15.  
  16. function isOdd(num) { return num % 2;}
  17. function DoMeEverySecond ()
  18. {
  19. dayPrev=0;
  20. $("ytcp-content-section#video-list div.video-table-content ytcp-video-row").each(function() {
  21. cell = $(this).find("div#row-container div.tablecell-date")
  22. description = $(cell).find("div.cell-description").text().trim();
  23. visibility = $(this).find("#row-container div.tablecell-visibility span.label-span").text().trim();
  24. console.log(visibility);
  25. if (description == "Scheduled" || description == "Published") {
  26. day = $(cell).text().trim().split(",")[0].split(" ")[1];
  27. // border
  28. if (day != dayPrev) {
  29. $(this).find("#row-container").css("border-top", "solid black 3px");
  30. } else {
  31. $(this).find("#row-container").css("border-top", "solid black 0px");
  32. }
  33. dayPrev = day;
  34. // bg
  35. if (isOdd(day)) {
  36. if (visibility == "Public") {
  37. $(this).find("#row-container").css("background-color", "#ada");
  38. } else {
  39. $(this).find("#row-container").css("background-color", "#ddd");
  40. }
  41. } else {
  42. if (visibility == "Public") {
  43. $(this).find("#row-container").css("background-color", "#dfd");
  44. } else {
  45. $(this).find("#row-container").css("background-color", "transparent");
  46. }
  47. }
  48. }
  49. });
  50. }
  51.  
  52. //--- When ready to stop the timer, run this code:
  53. //clearInterval (timerVar);
  54. //timerVar = "";
  55. }, false);

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址