diff --git a/doc/CHANGES.md b/doc/CHANGES.md index d56427792..70cd1aae2 100644 --- a/doc/CHANGES.md +++ b/doc/CHANGES.md @@ -139,6 +139,7 @@ Change log ## 12.5.0-dev (TBD) * feat: [#3250](https://github.com/gridstack/gridstack.js/pull/3250) full RTL support - thank you [Daniel Cohen Gindi](https://github.com/danielgindi) +* fix: [#3261](https://github.com/gridstack/gridstack.js/pull/3261) prepareDragDrop() returns for disable after deletion ## 12.5.0 (2026-04-05) * fix: [#3237](https://github.com/gridstack/gridstack.js/pull/3237) updateOptions() fixes for columnOpts, maxRow. load() not cloning diff --git a/src/gridstack.ts b/src/gridstack.ts index a095845e7..f5ce1b1b4 100644 --- a/src/gridstack.ts +++ b/src/gridstack.ts @@ -2723,8 +2723,10 @@ export class GridStack { this._removeDD(el); // nukes everything instead of just disable, will add some styles back next delete node._initDD; } - if (disable) el.classList.add('ui-draggable-disabled', 'ui-resizable-disabled'); // add styles one might depend on #1435 - if (!force) return this; + if (disable) { + el.classList.add('ui-draggable-disabled', 'ui-resizable-disabled'); // add styles one might depend on #1435 + return this; + } } if (!node._initDD) {