简体   繁体   中英

Circle div with information, on hover show all information

I want to have three circular divs next to each other (that's not a problem). At the bottom of the circle it will show the first words of my information text. On hover the information text will go up so you can read the whole text:

http://i.imgur.com/zIbG27h.png

What I tried to do at first was to create a div width: 170px and height: 170px , set a circle as a background in my CSS and do class:hover to bring up the text.

What I realised while attempting this was that I can't hide some of the text "behind" the circle like in the Normal picture I posted above.

Whats the best way to do this?

Make an img that floats on top of the text (using CSS absolute positioning) that has the inner part of the circle transparent. See here for more information.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM