mirror of
https://github.com/HelloZeroNet/ZeroNet.git
synced 2023-12-14 04:33:03 +01:00
32 lines
1.2 KiB
CoffeeScript
32 lines
1.2 KiB
CoffeeScript
class Fixbutton
|
|
constructor: ->
|
|
@dragging = false
|
|
$(".fixbutton-bg").on "mouseover", ->
|
|
$(".fixbutton-bg").stop().animate({"scale": 0.7}, 800, "easeOutElastic")
|
|
$(".fixbutton-burger").stop().animate({"opacity": 1.5, "left": 0}, 800, "easeOutElastic")
|
|
$(".fixbutton-text").stop().animate({"opacity": 0, "left": 20}, 300, "easeOutCubic")
|
|
|
|
$(".fixbutton-bg").on "mouseout", ->
|
|
if $(".fixbutton").hasClass("dragging")
|
|
return true
|
|
$(".fixbutton-bg").stop().animate({"scale": 0.6}, 300, "easeOutCubic")
|
|
$(".fixbutton-burger").stop().animate({"opacity": 0, "left": -20}, 300, "easeOutCubic")
|
|
$(".fixbutton-text").stop().animate({"opacity": 1, "left": 0}, 300, "easeOutBack")
|
|
|
|
|
|
###$(".fixbutton-bg").on "click", ->
|
|
return false
|
|
###
|
|
|
|
$(".fixbutton-bg").on "mousedown", ->
|
|
# $(".fixbutton-burger").stop().animate({"scale": 0.7, "left": 0}, 300, "easeOutCubic")
|
|
#$("#inner-iframe").toggleClass("back")
|
|
#$(".wrapper-iframe").stop().animate({"scale": 0.9}, 600, "easeOutCubic")
|
|
#$("body").addClass("back")
|
|
|
|
$(".fixbutton-bg").on "mouseup", ->
|
|
# $(".fixbutton-burger").stop().animate({"scale": 1, "left": 0}, 600, "easeOutElastic")
|
|
|
|
|
|
|
|
window.Fixbutton = Fixbutton
|