canvas直播点赞冒泡动画效果代码

代码语言:html

所属分类:动画

代码描述:canvas直播点赞冒泡动画效果代码

代码标签: 冒泡 动画 效果

下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开

<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">

    <style type="text/css">
        html,  body {
            height: 100%;
            position: relative;
            width: 100%;
        }
        canvas {
            display: block;
            position: absolute;
            bottom: 100px;
            right: -24px;
            z-index: 20;
            cursor: pointer;
            -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
        }
        .journal-reward {
            position: absolute;
            bottom: 70px;
            right: 20px;
            height: 80px;
            width: 80px;
            display: block;
            z-index: 21;
        }
        .zancont {
           position: relative;
           width: 300px;
           height:100%;
    
        }
    </style>
</head>

<body>
    <div class="zancont">
        <img src="//repo.bfw.wiki/bfwrepo/image/5f9e911f6d925.png" class="journal-reward" />
    </div>
<script type="text/javascript" src="//repo.bfw.wiki/bfwrepo/js/jquery-3.2.1.min.js"></script>
    <script type="text/javascript">
        
        /**
 * @ProjectName flutter-hearts-zmt
 * @Version 0.0.0
 * @Author Jiangshilong(https://github.com/JSL8023)
 * @Update 2018-03-22 17:24 pm 
 */

! function(t, e) {
	"object" == typeof exports && "undefined" != typeof module ? module.exports = e() : "function" == typeof define && define.amd ? define(e) : t.BubbleHearts = e()
}(this, function() {
	"use strict";

	function t(t, n, r) {
		var i = e.uniformDiscrete(89, 91) / 100,
			o = 1 - i,
			u = (e.uniformDiscrete(45, 60) + e.uniformDiscrete(45, 60)) / 100,
			a = function(t) {
				return t > i ? Math.max(((1 - t) / o).toFixed(2), .1) * u : u
			},
			c = e.uniformDiscrete(-30, 30),
			f = function(t) {
				return c
			},
			h = 10,
			s = n.width / 2 + e.uniformDiscrete(-h, h),
			d = (n.width - Math.sqrt(Math.pow(t.width, 2) + Math.pow(t.height, 2))) / 2 - h,
			l = e.uniformDiscr.........完整代码请登录后点击上方下载按钮下载查看

网友评论0