   '.favorites2-collection-list li:not(.is-active)'
 ].join(','), (e) ->
   addedToSet = true
-  track.funnel 'Set Management: Add to set',
+  analytics.track 'Set Management: Add to set',
     setId: $(e.currentTarget).attr('data-id')
-  track.funnel 'Set Management: Successful save'
+  analytics.track 'Set Management: Successful save'
   # Added to an additional set
   if $(e.currentTarget).siblings().hasClass('is-active')
-    track.funnel 'Set Management: Add to set - additional set'
+    analytics.track 'Set Management: Add to set - additional set'
 
 # Removed from set X
 $(document).on 'click', [
   '.save-controls-drop-down-menu-item.is-active'
   '.favorites2-collection-list > li.is-active'
 ].join(','), (e) ->
-  track.funnel 'Set Management: Remove from set',
+  analytics.track 'Set Management: Remove from set',
     inline: true
     setId: $(e.currentTarget).attr('data-id')
 
 # Name Create new set
 onNewSetInline = (e) ->
   return if e.keyCode and e.keyCode isnt 13
-  track.funnel 'Set Management: Name Create new set'
+  analytics.track 'Set Management: Name Create new set'
 $(document).on(
   'keyup', '.favorites2-collection-list-create input', onNewSetInline
 )

# Remove via X in corner
$(document).on 'click', ('.favorites2-edit-modal-delete-confirm'), (e) ->
  return unless $(e.target).text() is 'Remove work'
  track.click 'Set Management: Remove from set', inline: false

# Delete set
$(document).on 'click', ('.favorites2-edit-modal-init + ' +
                         '.favorites2-edit-modal-delete-container' +
                         'favorites2-edit-modal-delete-confirm'), ->
  track.click 'Set Management: Delete set'

# Privacy switch
$(document).on 'click', '.favorites2-toggle-public', ->
  track.click 'Set Management: Make private'
$(document).on 'click', '.favorites2-toggle-private', ->
  track.click 'Set Management: Make public'

# Slideshow
$(document).on 'click', '#user-profile-collection-right-slideshow', ->
  track.click 'Set Management: Slideshow'

# Share set
$(document).on 'click', '#user-profile-collection-right-share', ->
  track.click 'Set Management: Share set'
# See: http://cl.ly/image/3q040w1J2I2y/o
#

Cookies = require 'cookies-js'
mediator = require '../../../lib/mediator.coffee'

MODE = Cookies.get('save-controls')

# Funnel 1 (NUX Onboarding modal to new set made)
# ------------------------------------------------------------------------------
