react-skylight icon indicating copy to clipboard operation
react-skylight copied to clipboard

Add/fix callbacks for SkylightStateless

Open GuiRitter opened this issue 6 years ago • 0 comments

Hi everyone.

I'm talking about the beforeOpen, afterOpen, beforeClose and afterClose callbacks.

If they also exist for SkylightStateless, they are not working, so they need to be fixed.

If they don't also exist for SkylightStateless, I would suggest that they get implemented for SkylightStateless too.

If they don't exist for SkylightStateless for a reason, I would like for this to be stated clearly somewhere. For example, at marcio.github.io/react-skylight, there is a list of propTypes, but it doesn't list the isVisible prop. This makes me believe that the list of propTypes is for Skylight only. There should be a list for each, or one list explaining in the comments which prop applies to which component.

I've just been in a situation where I needed those callbacks in SkylightStateless. I managed to do what I wanted without them, but it took me a while because either it's not working or it was not supposed to work but I didn't knew about it.

Here's an example of what I'm talking about: Edit ovo0xj7onq

Thanks in advance.

GuiRitter avatar Nov 04 '18 15:11 GuiRitter