Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit b56a277

Browse files
committed
added isIgnoreChangeCB()
* added `isIgnoreChangeCB()` if changeCB should be ignored due to column change, sizeToContent, loading, etc...
1 parent 77e1ac3 commit b56a277

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

doc/CHANGES.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ Change log
55
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
66
**Table of Contents** *generated with [DocToc](http://doctoc.herokuapp.com/)*
77

8+
- [11.2.0-dev (TBD)](#1120-dev-tbd)
89
- [11.2.0 (2024-12-29)](#1120-2024-12-29)
910
- [11.1.2 (2024-12-08)](#1112-2024-12-08)
1011
- [11.1.1 (2024-11-26)](#1111-2024-11-26)
@@ -119,6 +120,9 @@ Change log
119120

120121
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
121122

123+
## 11.2.0-dev (TBD)
124+
* feat: added `isIgnoreChangeCB()` if changeCB should be ignored due to column change, sizeToContent, loading, etc...
125+
122126
## 11.2.0 (2024-12-29)
123127
* feat: [#2695](https://github.com/gridstack/gridstack.js/issues/2695) 'Esc' to cancel now works on sidebar external items, also works dragging over trash.
124128
* feat: [#2852](https://github.com/gridstack/gridstack.js/pull/2852) better React example. Thank you [CNine](https://github.com/Aysnine)

src/gridstack.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -974,6 +974,9 @@ export class GridStack {
974974
.filter((el: HTMLElement) => el.matches('.' + this.opts.itemClass) && !el.matches('.' + this.opts.placeholderClass)) as GridItemHTMLElement[];
975975
}
976976

977+
/** true if changeCB should be ignored due to column change, sizeToContent, loading, etc... which caller can ignore for dirty flag case */
978+
public isIgnoreChangeCB(): boolean { return this._ignoreLayoutsNodeChange; }
979+
977980
/**
978981
* Destroys a grid instance. DO NOT CALL any methods or access any vars after this as it will free up members.
979982
* @param removeDOM if `false` grid and items HTML elements will not be removed from the DOM (Optional. Default `true`).

0 commit comments

Comments
 (0)