当前位置:网站首页>php短视频源码,点赞时会有大拇指动画飘起
php短视频源码,点赞时会有大拇指动画飘起
2022-07-04 21:48:00 【云豹网络科技】
php短视频源码,点赞时会有大拇指动画飘起
(function() {
var coreSocialistValues
, index = Math.floor(Math.random() * coreSocialistValues.length);
document.body.addEventListener('click', function(e) {
if (e.target.tagName == 'A') {
return; }
var x = e.pageX
, y = e.pageY
, span = document.createElement('span');
span.textContent = coreSocialistValues[index];
index = (index + 1) % coreSocialistValues.length;//取模循环
span.style.cssText = ['z-index: 9999999; position: absolute; font-weight: bold; color: #ff6651; top: ', y - 20, 'px; left: ', x, 'px;'].join(''); document.body.appendChild(span); animate(span); });
function animate(el) {
//动画 var i = 0 , top = parseInt(el.style.top) , id = setInterval(frame, 16.7); function frame() {//帧 if (i > 180) { clearInterval(id); el.parentNode.removeChild(el); } else { i += 2; el.style.top = top - i + 'px'; el.style.opacity = (180 - i) / 180; } } }
}());
以上就是 php短视频源码,点赞时会有大拇指动画飘起,更多内容欢迎关注之后的文章
边栏推荐
猜你喜欢
常用的开源无代码测试工具
A large number of virtual anchors in station B were collectively forced to refund: revenue evaporated, but they still owe station B; Jobs was posthumously awarded the U.S. presidential medal of freedo
Nat. Commun.| 机器学习对可突变的治疗性抗体的亲和力和特异性进行共同优化
QT—绘制其他问题
Use blocconsumer to build responsive components and monitor status at the same time
Nat. Commun.| Machine learning jointly optimizes the affinity and specificity of mutagenic therapeutic antibodies
Why do you have to be familiar with industry and enterprise business when doing Bi development?
GTEST from ignorance to proficiency (3) what are test suite and test case
TCP协议三次握手过程
智洋创新与华为签署合作协议,共同推进昇腾AI产业持续发展
随机推荐
TCP protocol three times handshake process
Application practice | Shuhai supply chain construction of data center based on Apache Doris
Ascendex launched Walken (WLKN) - an excellent and leading "walk to earn" game
Spatiotemporal prediction 3-graph transformer
The drawing method of side-by-side diagram, multi row and multi column
Play with grpc - go deep into concepts and principles
bizchart+slider实现分组柱状图
QT - double buffer plot
PostgreSQL JOIN实践及原理
力扣_回文数
常用的开源无代码测试工具
Go language loop statement (3 in Lesson 10)
Open3d surface normal vector calculation
【C语言进阶篇】数组&&指针&&数组笔试题
Relational database
Hash table
Scala下载和配置
leetcode 72. Edit Distance 编辑距离(中等)
迷失在Mysql的锁世界
new IntersectionObserver 使用笔记