Apply local draft version or discard it
Indent with tabs
Auto-run code (beta)
Only auto-run code that validates
Auto-save code (bumps the version)
Auto-close HTML tags
Clear console on run
Live code validation
No autoresizing to fit the code
Render blocking of the parent page
In this pen I'm trying to display an image caption on top of its image when it's hovered (centered horizontally and vertically). I do not want any unnecessary markup (otherwise there would have been solutions using "display: table-cell") nor any pixel based calculations.
I'm not finally happy with the current solution since the negative "margin-top" being half the line-height does not seem totally uncalculated, but I can live with it for now.
And there might be better ways for dealing with the image border; it's not really beautiful depending on the overall image brightness and its size.
Add title to make the fiddle public.
/echo simulates Async calls:
See docs for more info.
Created and maintained by Piotr and @oskar.
Hosted on DigitalOcean
All code belongs to the poster and no license is enforced.
JSFiddle or its authors are not responsible or liable for any loss or damage of any kind during the usage of provided code.
Roadmap (vote for features)
Status page by updown.io
If you don't mind tech-related ads, and want to keep us running, whitelist JSFiddle in your ad blocker.
Thank you! ❤️