chinchang / hint.css

A CSS only tooltip library for your lovely websites.
https://kushagra.dev/lab/hint/
MIT License
8.42k stars 701 forks source link

z-index as a variable #28

Closed jamiebuilds closed 11 years ago

jamiebuilds commented 11 years ago

While 1000000 seems like a great number for tooltips, I think it'd be more appropriate in the variables. How about it?

dgodfather commented 11 years ago

I've noticed this as a problem for me as well. This means that you have to use a number that big (1000000) for it to show up on top of other objects?

dgodfather commented 11 years ago

http://postimg.org/image/d3we37y5f/

I don't know if it has to do with the z-index or not, but the link to the image above shows the hint being cut off. Without doing a bunch of styling changes, is there a way to ultimately bring it to the front?

jamiebuilds commented 11 years ago

@dgodfather That looks like it's being cut off by an overflow, this is something you are going to need to fix outside of hint.css

clrunlc commented 10 years ago

@dgodfather I have the same problem. Did you find a solution?

tnrich commented 7 years ago

@thejameskyle @clrunlc and @clrunlc I am hitting the same issue as well. I need the overflow to be hidden, but also need the tooltip to show up... How can I get around this?

jamiebuilds commented 7 years ago

@tnrich It's just not possible with hint. You can use something like this instead: http://github.hubspot.com/tooltip/docs/welcome/

dgodfather commented 7 years ago

For me it was something with my underlying css that I had to work out. I can't quite recall. Do you have a link to your issue?

chinchang commented 7 years ago

@tnrich There can only be workarounds for this issue. For example, you could move the tooltip upwards and put it on the element that has overflow:hidden on it - if that works for your scenario.

If you could show your exact layout, may be I can suggest something. Otherwise if nothing works, you'll have to use some JavaScript based tooltip like @thejameskyle suggested.

tnrich commented 7 years ago

Okay thanks everyone for the input! I'll try using a js solution instead. Can anyone suggest a jquery-free solution that still works in a similar fashion to hintjs's data-attributes?

Thanks!

dgodfather commented 7 years ago

@tnrich The thing you should consider is that with a JQuery solution your tooltips can be responsive. I'm not sure about strictly JS and certainly not CSS only.

jamiebuilds commented 7 years ago

@tnrich The one I mentioned does not have a dependency on jQuery.

@dgodfather There's no reason that jQuery is needed for responsiveness

dgodfather commented 7 years ago

@thejameskyle Wouldn't JS/Jquery be required to acknowledge window resizing?

jamiebuilds commented 7 years ago

@dgodfather https://developer.mozilla.org/en-US/docs/Web/Events/resize