// ==UserScript== // @name Crunchyroll responsive // @namespace https://gitlab.com/breatfr // @version 1.0.5 // @description Crunchyroll website is more suitable for wide screens. // @author BreatFR (https://breat.fr) // @homepageURL https://gitlab.com/breatfr/crunchyroll // @supportURL https://discord.gg/Q8KSHzdBxs // @license AGPL-3.0-or-later; https://www.gnu.org/licenses/agpl-3.0.txt // @grant GM_addStyle // @run-at document-start // @match *://*.crunchyroll.com/* // @include /^(?:https://www\.crunchyroll\.com/[^/]+/videos/.*)$/ // @include /^(?:https://www\.crunchyroll\.com/[^/]+/history)$/ // @include /^(?:https://www\.crunchyroll\.com/[^/]+/watchlist)$/ // @include /^(?:https://www\.crunchyroll\.com/[^/]+/series/.*)$/ // @include /^(?:https://www\.crunchyroll\.com/[^/]+/notifications)$/ // @include /^(?:https://www\.crunchyroll\.com/[^/]+/watch/.*)$/ // @downloadURL https://update.greasyfork.icu/scripts/496843/Crunchyroll%20responsive.user.js // @updateURL https://update.greasyfork.icu/scripts/496843/Crunchyroll%20responsive.meta.js // ==/UserScript== (function() { let css = ""; if ((location.hostname === "crunchyroll.com" || location.hostname.endsWith(".crunchyroll.com"))) { css += ` .browse-card-hover__description--e28NH { font-size: 18px; --max-lines: 19; } .hero-content-card__description--N73xU { font-size: 18px; -webkit-line-clamp: unset; } /* Footer */ .container--cq5XE { max-width: 100% !important; } `; } if (new RegExp("^(?:https://www\\.crunchyroll\\.com/[^/]+/videos/.*)\$").test(location.href)) { css += ` /* Genres */ .erc-genres-header .description, .content-wrapper--MF5LS, .erc-genres-content { max-width: 100%; } /* Hover texts */ .browse-card__title--YK28O { font-size: 16px; } .browse-card-hover__title--8m4Az, .browse-card-hover__description--e28NH { font-size: 18px; --max-lines: 19; } `; } if (new RegExp("^(?:https://www\\.crunchyroll\\.com/[^/]+/history)\$").test(location.href)) { css += ` /* History */ .history-playable-card__show-title--Ufpz3{ font-size: 1.2rem; line-height: 1.5; } .content-wrapper--MF5LS { max-width: 100%; } `; } if (new RegExp("^(?:https://www\\.crunchyroll\\.com/[^/]+/watchlist)\$").test(location.href)) { css += ` /* Watchlist */ .content-wrapper--MF5LS { max-width: 100%; } `; } if (new RegExp("^(?:https://www\\.crunchyroll\\.com/[^/]+/series/.*)\$").test(location.href)) { css += ` /* Series description */ .content-wrapper--MF5LS { max-width: 100%; } /* Hover texts */ .browse-card-hover__title--8m4Az, .browse-card-hover__description--e28NH { font-size: 1.2rem; --max-lines: 19; } /* Commentaires */ .reviews-section-body { max-width: 100% !important; } `; } if (new RegExp("^(?:https://www\\.crunchyroll\\.com/[^/]+/notifications)\$").test(location.href)) { css += ` /* Centre de notifications */ .content-wrapper--MF5LS { max-width: 100% !important; } `; } if (new RegExp("^(?:https://www\\.crunchyroll\\.com/[^/]+/watch/.*)\$").test(location.href)) { css += ` .content-wrapper--MF5LS { max-width: 100% !important; } .erc-watch-episode-layout .body-wrapper { grid-template-columns: 1fr 367px !important; } `; } if (typeof GM_addStyle !== "undefined") { GM_addStyle(css); } else { const styleNode = document.createElement("style"); styleNode.appendChild(document.createTextNode(css)); (document.querySelector("head") || document.documentElement).appendChild(styleNode); } })();