摘要:
问题 如题所示 相关源码: function o() { var t = "function" == typeof e.onclick && e.onclick; e.onclick = function (e) { t && t(), i(e) } } 答案 var t = "function" 阅读全文
posted @ 2022-07-12 08:44
黄子涵
阅读(823)
评论(0)
推荐(0)
摘要:
问题 如题所示 答案 相关源码: d.push({ el: a, x: e.clientX - 5, y: e.clientY - 5, scale: 1, alpha: 1, color: s() }), CSS设置Alpha值 alpha: 1这个样式的作用是设置元素的不透明度,样式值为1是就是 阅读全文
posted @ 2022-07-12 08:37
黄子涵
阅读(63)
评论(0)
推荐(0)
摘要:
问题 如题所示 相关源码: function s() { return "rgb(" + ~~(255 * Math.random()) + "," + ~~(255 * Math.random()) + "," + ~~(255 * Math.random()) + ")" } 答案 这个函数就是 阅读全文
posted @ 2022-07-12 08:22
黄子涵
阅读(1158)
评论(0)
推荐(0)
摘要:
问题 如题所示 答案 相关源码: function i(e) { var a = t.createElement("div"); a.className = "heart", d.push({ el: a, x: e.clientX - 5, y: e.clientY - 5, scale: 1, 阅读全文
posted @ 2022-07-12 07:29
黄子涵
阅读(102)
评论(0)
推荐(0)
摘要:
问题 如题所示 相关源码: function c(e) { var a = t.createElement("style"); a.type = "text/css"; try { a.appendChild(t.createTextNode(e)) } catch (t) { a.styleShe 阅读全文
posted @ 2022-07-12 06:54
黄子涵
阅读(111)
评论(0)
推荐(0)