Sha256: dbfc11cab33b9bae947d9e17dc69bc30b568ad0e8bdc61c047076d6d20e1a049

Contents?: true

Size: 758 Bytes

Versions: 11

Compression:

Stored size: 758 Bytes

Contents

Button.func.update = self => {
  let text = $(self).find(".button-title"),
      bg   = $(self).find(".button-bg"),
      all  = [text,bg,self];

  Save.text  = $(self).find(".button-title").text();
  Save.color = $(self).css('backgroundColor');

  if (!UpdateIsLocked) {

    let tl = gsap.timeline();

     tl
     .set(text,{
       text : "Adding"
     })
     .set(bg,{
       backgroundColor : tinycolor(Save.color).darken(8)
     })
     .to(bg,{
       right : 0,
       duration : 1
     })
     .set(text,{
       text  : "Added"
     })
     .to(bg,{
       duration : 0.5,
       backgroundColor : Color.green
     });

     if (reset) {
      tl.call(()=>{
        Button.func.reset(self,Save.text);
      },"+=1");                
    }
   }
}

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
futuro-1.1.8 assets/js/footer/custom/5_button.func.update.js
futuro-1.1.7 assets/js/footer/custom/5_button.func.update.js
futuro-1.1.6 assets/js/footer/custom/5_button.func.update.js
futuro-1.1.5 assets/js/footer/custom/5_button.func.update.js
futuro-1.1.4 assets/js/footer/custom/5_button.func.update.js
futuro-1.1.3 assets/js/footer/custom/5_button.func.update.js
futuro-1.1.2 assets/js/footer/custom/5_button.func.update.js
futuro-1.1.1 assets/js/footer/custom/5_button.func.update.js
futuro-1.1.0 assets/js/footer/custom/5_button.func.update.js
futuro-1.0.9 assets/js/footer/custom/5_button.func.update.js
futuro-1.0.8 assets/js/footer/custom/5_button.func.update.js