MediaWiki:Common.css: Difference between revisions
Jump to navigation
Jump to search
Created page with "→CSS placed here will be applied to all skins: .custom-tooltip { position: relative; cursor: pointer; border-bottom: 1px dotted black; →Makes it look like a link: } .tooltip-content { display: none; →Initially hide the tooltip: position: absolute; top: 1.5em; left: 0; background: white; border: 1px solid black; padding: 5px; z-index: 100; width: auto; max-width: 250px; box-shadow: 2px 2px 5px rgba(0,0,0..." |
No edit summary |
||
(10 intermediate revisions by one other user not shown) | |||
Line 1: | Line 1: | ||
.image-link { | |||
. | |||
position: relative; | position: relative; | ||
text-decoration: none; | |||
} | } | ||
. | .image-preview { | ||
position: absolute; | position: absolute; | ||
top: | top: 100%; | ||
left: | left: 50%; | ||
transform: translateX(-50%); | |||
width: 200px; /* Adjust as needed */ | |||
height: 200px; /* Adjust as needed */ | |||
background-size: cover; | |||
background-position: center; | |||
background-repeat: no-repeat; | |||
display: none; | |||
border: 1px solid #ccc; | |||
z-index: 10; | |||
} | } | ||
. | .image-link:hover + .image-preview { | ||
display: block; | display: block; | ||
} | } |
Latest revision as of 19:04, 13 February 2025
.image-link { position: relative; text-decoration: none; } .image-preview { position: absolute; top: 100%; left: 50%; transform: translateX(-50%); width: 200px; /* Adjust as needed */ height: 200px; /* Adjust as needed */ background-size: cover; background-position: center; background-repeat: no-repeat; display: none; border: 1px solid #ccc; z-index: 10; } .image-link:hover + .image-preview { display: block; }