fix: field drag uses text/plain to match DataBinding drop handler

LeftPanel was setting application/json but DataBinding reads text/plain.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
hailin 2026-04-05 02:37:59 -07:00
parent 735f00cbc3
commit 12f7f04d82
1 changed files with 1 additions and 4 deletions

View File

@ -133,10 +133,7 @@ function FieldsTab() {
} }
const handleDragStart = (e: React.DragEvent, field: FieldItemVM) => { const handleDragStart = (e: React.DragEvent, field: FieldItemVM) => {
e.dataTransfer.setData( e.dataTransfer.setData('text/plain', field.name);
'application/json',
JSON.stringify({ fieldName: field.name, fieldType: field.type }),
);
e.dataTransfer.effectAllowed = 'copy'; e.dataTransfer.effectAllowed = 'copy';
}; };