Skip to content

Commit

Permalink
add callback support (closes matthieua#149)
Browse files Browse the repository at this point in the history
  • Loading branch information
attilaolah committed Jan 14, 2015
1 parent da63aea commit 09e8606
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/wow.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ class @WOW
offset: 0
mobile: true
live: true
callback: null

constructor: (options = {}) ->
@scrolled = true
Expand Down Expand Up @@ -150,6 +151,7 @@ class @WOW
show: (box) ->
@applyStyle(box)
box.className = "#{box.className} #{@config.animateClass}"
@config.callback(box) if @config.callback?

applyStyle: (box, hidden) ->
duration = box.getAttribute('data-wow-duration')
Expand Down

0 comments on commit 09e8606

Please sign in to comment.