Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Drag and drop broken after latest version 4.2.0 #886

Closed
oyusof1 opened this issue Mar 18, 2025 · 3 comments · Fixed by #888
Closed

Drag and drop broken after latest version 4.2.0 #886

oyusof1 opened this issue Mar 18, 2025 · 3 comments · Fixed by #888

Comments

@oyusof1
Copy link

oyusof1 commented Mar 18, 2025

Describe the bug
Setting props dndEdges or rootOverlayModel throws an error in version 4.2.0

TypeError: Cannot set properties of undefined (setting 'disabled') at At.updateDropTargetModel (dockviewComponent.js:1639:34)

To Reproduce

  1. Initialize DockviewReact in a React project.
  2. Set dndEdges
    dndEdges={{ size: { value: 100, type: 'pixels' }, activationSize: { value: 5, type: 'percentage' } }}

Observe the
TypeError: Cannot set properties of undefined (setting 'disabled')

Expected behavior
Should render properly

Screenshots

Image

Desktop (please complete the following information):

  • Browser: Chrome
  • Version 134.0.6998.89 (Official Build) (arm64)
@oyusof1
Copy link
Author

oyusof1 commented Mar 18, 2025

https://dockview.dev/docs/core/dnd/external is also broken due to this bug, error is thrown on screen

downgrading to 3.2.0 and using rootOverlayModel works just fine

@novecento
Copy link

It seems this._rootDropTarget is defined 'after' set its disabled.

@mathuo mathuo linked a pull request Mar 18, 2025 that will close this issue
@mathuo
Copy link
Owner

mathuo commented Mar 18, 2025

Apologies, fixed in 4.2.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants