aomran / ember-cli-zero-clipboard

Ember CLI addon for adding a "copy to clipboard" button component
https://www.npmjs.org/package/ember-cli-zero-clipboard
17 stars 12 forks source link

inner button hover/active states not triggering #6

Open samselikoff opened 9 years ago

samselikoff commented 9 years ago

The inner button's hover/active states seem to not be showing, because the zero clipboard .ember-view div is covering the button.

Anyone else seeing this?

aomran commented 9 years ago

I think this is happening because of the way zero-clipboard works. There is a flash element that gets inserted on-top of the button so hover/active states don't work. The work around is that zero-clipboard adds a class called "zeroclipboard-is-hover" which might help.

samselikoff commented 9 years ago

Gotcha. In this case I think the example with innerClass='btn' is misleading, since pretty much everyone will expect those hover/active states to work, but they won't.

Would it work if the view itself had the btn classes instead?

aomran commented 9 years ago

In a previous implementation the component itself was a button and it still didn't work. I played around with it a bit but didn't have time to solve it. If you do then please make a pull request :)

I'll see about fixing the example.

samselikoff commented 9 years ago

Gotcha, I'll try to make something work :)

aalimovs commented 8 years ago

Anyone had any luck with this?

There's a class .zeroclipboard-is-hover, however, background-color there doesn't help, because even though .zeroclipboard-is-hover is a parent of .btn, it seems hover color is behind the btn?