mirror of
https://github.com/Alvin-Zilverstand/return-youtube-dislike.git
synced 2026-11-26 00:03:01 +01:00
Fix ratiobar positioning in the new youtube design
This is done by attaching the bar to the like/dislike button container instead of the whole interaction menu, then using absolute positioning after modifying a few youtube styles.
This commit is contained in:
2 files changed
+21
-5
No files matched your search
@@ -57,14 +57,12 @@ function createRateBar(likes, dislikes) {
|
||||
|
||||
(
|
||||
document.getElementById(
|
||||
isNewDesign() ? "actions-inner" : "menu-container"
|
||||
isNewDesign() ? "top-level-buttons-computed" : "menu-container"
|
||||
) || document.querySelector("ytm-slim-video-action-bar-renderer")
|
||||
).insertAdjacentHTML(
|
||||
"beforeend",
|
||||
`
|
||||
<div class="ryd-tooltip" style="width: ${widthPx}px${
|
||||
isNewDesign() ? "; margin-bottom: -2px" : ""
|
||||
}">
|
||||
<div class="ryd-tooltip ryd-tooltip-${isNewDesign() ? "new" : "old"}-design" style="width: ${widthPx}px">
|
||||
<div class="ryd-tooltip-bar-container">
|
||||
<div
|
||||
id="ryd-bar-container"
|
||||
|
||||
Reference in new issue
Block a user