material-ui icon indicating copy to clipboard operation
material-ui copied to clipboard

[Discuss] Tooltip component

Open juhaelee opened this issue 11 years ago • 15 comments

Would it be better to make the tooltip into a higher order component? That way you can use the tooltip with any component and just wrap it with a tooltip component. Maybe it can take in a prop called action which specifies whether or not it appears onclick or hover

juhaelee avatar Aug 05 '15 18:08 juhaelee

@juhaelee Good idea. Maybe something like: http://react-bootstrap.github.io/components.html#tooltips-overlay-trigger?

jkruder avatar Aug 06 '15 00:08 jkruder

:+1:

mairh avatar Aug 06 '15 11:08 mairh

That would be great, it would be nice to have for <a> tags, buttons etc...

timarney avatar Aug 08 '15 12:08 timarney

:+1:

lucianlature avatar Sep 05 '15 17:09 lucianlature

:+1:

irium avatar Oct 15 '15 21:10 irium

@juhaelee would you like to take a shot at this and submit a prototype in a PR? :)

shaurya947 avatar Nov 24 '15 20:11 shaurya947

I think so. The tooltip is really lacking for me. Namely, there are two things I need (aside from the current bugs mentioned in https://github.com/callemall/material-ui/issues/3665)

  1. More flexibility in relative positioning. I'd like to position the tooltip all the way to the right or left, and not just above/below.

  2. The tooltip as far as I know is only available on buttons. I have a big use case for using tooltips on badges. If you tap/mouseover the circle from the badge, that will not cause the tooltip to show. (even though I want it to)

I'm imagining the component would wrap the element(s) like this:

<Tooltip position='right' text='# of problems'>
  <Badge badgeContent={'99'} badgeStyle={badgeStyle}>
    <IconButton>...</IconButton>
  </Badge>
</Tooltip>

matthewoates avatar Apr 23 '16 06:04 matthewoates

@matthewoates : A PR would be welcome.

tintin1343 avatar May 03 '16 21:05 tintin1343

Any updates?

audetpascale avatar Jul 05 '16 13:07 audetpascale

did anything happen with this?

HeWasntOffByMuch avatar Nov 04 '16 14:11 HeWasntOffByMuch

My solution has been to use native tooltips (title="...")

The performance around tooltips doesn't seem to be that great right now.

matthewoates avatar Nov 05 '16 05:11 matthewoates

I was surprised to see this component is not publicly available this is very useful to avoid overcrowded interfaces and to guide users...

Any updates on this ?

gpapin avatar Jan 19 '17 14:01 gpapin

Is this something that we are pursuing in the next branch @oliviertassinari or @nathanmarks? If so, maybe this issue can be closed.

m2mathew avatar Feb 28 '17 17:02 m2mathew

@m2mathew We haven't made any progress on a Tooltip component as far as I know. That's definitely something we should be doing 👍 .

oliviertassinari avatar Feb 28 '17 20:02 oliviertassinari

I'm closing this issue for the #2230 issue around implementing a Tooltip component.

oliviertassinari avatar Jun 24 '17 22:06 oliviertassinari