• This project
    • Loading...
  • Sign in

fe / YOHOBUYPC · Files

Go to a project

GitLab

  • Go to group
  • Project
  • Activity
  • Files
  • Commits
  • Pipelines 0
  • Builds 0
  • Graphs
  • Milestones
  • Issues 0
  • Merge Requests 2
  • Members
  • Labels
  • Wiki
  • Forks
  • Network
  • Create a new issue
  • YOHOBUYPC
  • web-static
  • js
  • guang
  • img-blink.js
  • PC的个人中心
    3ebc23bf
    by whb
    2016-04-12 22:30:56 +0800  
    Browse Files
img-blink.js 455 Bytes
Raw Blame History Permalink
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
/**
 * 图片移入闪动效果JS
 * @auhor: xuqi<qi.xu@yoho.cn>
 * @date: 2015/7/29
 */

var $ = require('yoho.jquery');

$('.guang-page').on('mouseover', 'a img, a .bg-img', function(e) {
    var $el = $(e.target);

    //slider中的图片不做此效果
    if ($el.closest('.slider').length > 0) {
        return;
    }

    $el.addClass('blink');

    setTimeout(function() {
        $el.removeClass('blink');
    }, 100);
});