问题描述
所以我有点卡住了,当从桌面上拖动文档或文件夹之类的外部元素时,我无法更改其光标。 我已经尝试过更改整个页面的光标和正文光标,悬停效果或活动光标。 但是,当将文档从桌面拖到网络上时,它似乎是Web应用程序中未包含的完全不同的光标。
这是我想要的结果:here
如您在图片中看到的,我将图像拖到我的Web应用程序上,并且在悬停控制台时,它将光标更改为不允许。
那正是我的目标。
有人试图改变它吗?
解决方法
要添加功能,您应该编写javascript代码。
7 | / if s.len() > 10 {
8 | | None
| | ^^^^ expected `()`,found enum `std::option::Option`
9 | | }
| | -- help: consider using a semicolon here
| |_________|
| expected this to be `()`
|
= note: expected unit type `()`
found enum `std::option::Option<_>`
body{
cursor: no-drop;
}
.dropZone{
width: 50%;
height: 300px;
border: 1px solid #000;
cursor: move;
display: flex;
align-items: center;
justify-content: center;
}