iftechfoundation / twine-cookbook

Twine Cookbook
131 stars 31 forks source link

Minor Typo in Sugarcube Hidden Links #42

Closed htremura closed 6 years ago

htremura commented 6 years ago

As the title states, there's a typo in the section for having a link reveal itself permanently upon mouseover. It reads $('.reveals') .addClass('hidden') .one('mouseenter', function () { $(this).removeClass('hidden'); });

It should be .on instead of .one

greyelf commented 6 years ago

@Superechidna Once a .reveals based link is made visual via a mouseenter event it never needs to be made visible again, and the .one() function achieves that result. Could you explain in what use-case there is a need to react to multiple mouseenter events for a particular .reveals based link?

tmedwards commented 6 years ago

The use of the .one() method there is not a typo.

-- Thomas Michael EDWARDS Email: thomasmedwards@gmail.com Website: http://www.motoslave.net/thom/ "That a word like unnatural exists at all indicates a serious deficiency in common sense...." -- Anna Puma, Dominion: Conflict 1 (No More Noise)

htremura commented 6 years ago

That's entirely my bad, I misunderstood it completely.