1
0
mirror of https://github.com/chylex/TweetDuck.git synced 2025-05-03 05:34:07 +02:00

Add a hover class to Notification body element and only display skip button when over

This commit is contained in:
chylex 2016-09-27 03:48:14 +02:00
parent f23db31306
commit fde984d02b
2 changed files with 12 additions and 1 deletions
Core/Handling
Resources/Scripts

View File

@ -20,7 +20,7 @@ private static string DefaultHeadTag{
private static string CustomCSS{ private static string CustomCSS{
get{ get{
return @".scroll-styled-v::-webkit-scrollbar{width:8px}.scroll-styled-v::-webkit-scrollbar-thumb{border-radius:0}a[data-full-url]{word-break:break-all}#td-skip{opacity:0.75;cursor:pointer}#td-skip:hover{opacity:1}"; return @".scroll-styled-v::-webkit-scrollbar{width:8px}.scroll-styled-v::-webkit-scrollbar-thumb{border-radius:0}a[data-full-url]{word-break:break-all}#td-skip{opacity:0;cursor:pointer;transition:opacity 0.15s ease}.td-hover #td-skip{opacity:0.75}#td-skip:hover{opacity:1}";
} }
} }

View File

@ -136,6 +136,17 @@
}); });
})(); })();
//
// Block: Setup a hover class on body.
//
document.body.addEventListener("mouseenter", function(){
document.body.classList.add("td-hover");
});
document.body.addEventListener("mouseleave", function(){
document.body.classList.remove("td-hover");
});
// //
// Block: Page fully loaded. // Block: Page fully loaded.
// //