【发布时间】:2021-03-02 03:26:22
【问题描述】:
我正在为我的鼠标光标设计不同的 SVG 图像,但似乎我遗漏了一些明显的东西。这是一个带有简单 PNG 圆圈的最小示例:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Cursor</title>
<style>
.hoverText {
display: block;
margin-left: auto;
margin-right: auto;
width: 40%;
text-align: center;
}
.hoverText:hover {
cursor: url('circle.png'), pointer;
}
</style>
</head>
<body>
<div class="hoverText">Test</div>
</body>
</html>
感谢您的帮助!
【问题讨论】:
-
这能回答你的问题吗? Using external images for CSS custom cursors