YouTube Restore "Show More" Button

Restores the "Show More" button on old youtube

Από την 05/06/2020. Δείτε την τελευταία έκδοση.

// ==UserScript==
// @name        YouTube Restore "Show More" Button
// @description Restores the "Show More" button on old youtube
// @namespace   http://www.youtube.com/
// @include     http://www.youtube.com/watch?*
// @include     https://www.youtube.com/watch?*
// @version     1.4
// @grant       none
// ==/UserScript==


//I'm not a coder/scripter. I'm sure there's a much better way of doing this, but I couldn't figure it out.

function restoreDetailButtons() {
  var showMoreButton = ('<button class="yt-uix-button yt-uix-button-size-default yt-uix-button-expander yt-uix-expander-head yt-uix-expander-collapsed-body yt-uix-gen204" type="button" onclick=";return false;" data-gen204="feature=watch-show-more-metadata"><span class="yt-uix-button-content">Show more</span></button>');
  var showLessButton = ('<button class="yt-uix-button yt-uix-button-size-default yt-uix-button-expander yt-uix-expander-head yt-uix-expander-body" type="button" onclick=";return false;"><span class="yt-uix-button-content">Show less</span></button>');

  document.getElementById("action-panel-details").insertAdjacentHTML('beforeend', showMoreButton + showLessButton);
}

restoreDetailButtons();