mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-07-13 16:16:46 +08:00
feat: change cursor when drag
This commit is contained in:
@@ -133,6 +133,7 @@ export const LeftMenuDraggable: FC<LeftMenuProps> = props => {
|
||||
);
|
||||
|
||||
const onDragStart = async (event: React.DragEvent<Element>) => {
|
||||
editor.dragDropManager.isOnDrag = true;
|
||||
if (block == null) return;
|
||||
const dragImage = await editor.blockHelper.getBlockDragImg(
|
||||
block.blockId
|
||||
|
||||
@@ -55,8 +55,8 @@ export class LeftMenuPlugin extends BasePlugin {
|
||||
blockInfo: BlockDomInfo
|
||||
) => {
|
||||
const { type, dom, blockId } = blockInfo;
|
||||
event.preventDefault();
|
||||
if (this.editor.dragDropManager.isDragBlock(event)) {
|
||||
event.preventDefault();
|
||||
if (ignoreBlockTypes.includes(type)) {
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user