From eefb86bee677403aa63fe9519ed320082c91c1f5 Mon Sep 17 00:00:00 2001 From: tishko0 Date: Mon, 27 Oct 2025 10:36:22 +0200 Subject: [PATCH 1/4] fix(sample): clear pin position before pinning to make sure column pins correctly --- samples/grids/grid/column-pinning-both-sides/src/index.tsx | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/samples/grids/grid/column-pinning-both-sides/src/index.tsx b/samples/grids/grid/column-pinning-both-sides/src/index.tsx index be088f9bc..3449916e7 100644 --- a/samples/grids/grid/column-pinning-both-sides/src/index.tsx +++ b/samples/grids/grid/column-pinning-both-sides/src/index.tsx @@ -55,15 +55,16 @@ export default function App() { const pinLeft = () => { gridRef.current?.selectedColumns().forEach((col: IgrColumn) => { + col.pinned = false; col.pinningPosition = ColumnPinningPosition.Start; - col.pinned = true; + col.pinned = true; }); }; const pinRight = () => { gridRef.current?.selectedColumns().forEach((col: IgrColumn) => { + col.pinned = false; col.pinningPosition = ColumnPinningPosition.End; - col.pinned = true; - }); + col.pinned = true; }; const unpinColumn = () => { gridRef.current?.selectedColumns().forEach((col: IgrColumn) => { From ab9b3053a1825eff079b057018f32caea012ba26 Mon Sep 17 00:00:00 2001 From: tishko0 Date: Mon, 27 Oct 2025 10:39:23 +0200 Subject: [PATCH 2/4] fix(sample): fixed a typo --- samples/grids/grid/column-pinning-both-sides/src/index.tsx | 1 + 1 file changed, 1 insertion(+) diff --git a/samples/grids/grid/column-pinning-both-sides/src/index.tsx b/samples/grids/grid/column-pinning-both-sides/src/index.tsx index 3449916e7..c2461f695 100644 --- a/samples/grids/grid/column-pinning-both-sides/src/index.tsx +++ b/samples/grids/grid/column-pinning-both-sides/src/index.tsx @@ -65,6 +65,7 @@ export default function App() { col.pinned = false; col.pinningPosition = ColumnPinningPosition.End; col.pinned = true; + }); }; const unpinColumn = () => { gridRef.current?.selectedColumns().forEach((col: IgrColumn) => { From 582ef6de393ae9cccfd50ccd1b4521fdf7ca7aae Mon Sep 17 00:00:00 2001 From: tishko0 Date: Mon, 27 Oct 2025 10:40:19 +0200 Subject: [PATCH 3/4] fix(sample): removed a white space --- samples/grids/grid/column-pinning-both-sides/src/index.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/samples/grids/grid/column-pinning-both-sides/src/index.tsx b/samples/grids/grid/column-pinning-both-sides/src/index.tsx index c2461f695..e6c07f196 100644 --- a/samples/grids/grid/column-pinning-both-sides/src/index.tsx +++ b/samples/grids/grid/column-pinning-both-sides/src/index.tsx @@ -65,7 +65,7 @@ export default function App() { col.pinned = false; col.pinningPosition = ColumnPinningPosition.End; col.pinned = true; - }); + }); }; const unpinColumn = () => { gridRef.current?.selectedColumns().forEach((col: IgrColumn) => { From 06ca5f76c0fda18d7b3a94526578e037339ac961 Mon Sep 17 00:00:00 2001 From: tishko0 Date: Mon, 27 Oct 2025 14:18:07 +0200 Subject: [PATCH 4/4] fix(grids): reset pinned state before pinning columns in grid samples --- samples/grids/grid/column-pinning-both-sides/src/index.tsx | 4 ++-- .../hierarchical-grid/column-pinning-both-sides/src/index.tsx | 2 ++ .../grids/tree-grid/column-pinning-both-sides/src/index.tsx | 2 ++ 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/samples/grids/grid/column-pinning-both-sides/src/index.tsx b/samples/grids/grid/column-pinning-both-sides/src/index.tsx index e6c07f196..4480bcbf9 100644 --- a/samples/grids/grid/column-pinning-both-sides/src/index.tsx +++ b/samples/grids/grid/column-pinning-both-sides/src/index.tsx @@ -55,14 +55,14 @@ export default function App() { const pinLeft = () => { gridRef.current?.selectedColumns().forEach((col: IgrColumn) => { - col.pinned = false; + col.pinned = false; col.pinningPosition = ColumnPinningPosition.Start; col.pinned = true; }); }; const pinRight = () => { gridRef.current?.selectedColumns().forEach((col: IgrColumn) => { - col.pinned = false; + col.pinned = false; col.pinningPosition = ColumnPinningPosition.End; col.pinned = true; }); diff --git a/samples/grids/hierarchical-grid/column-pinning-both-sides/src/index.tsx b/samples/grids/hierarchical-grid/column-pinning-both-sides/src/index.tsx index d89d49303..9f49a89f3 100644 --- a/samples/grids/hierarchical-grid/column-pinning-both-sides/src/index.tsx +++ b/samples/grids/hierarchical-grid/column-pinning-both-sides/src/index.tsx @@ -33,6 +33,7 @@ export default function App() { const grid = gridRef.current; if (!grid) return; grid.selectedColumns().forEach((col) => { + col.pinned = false; col.pinningPosition = ColumnPinningPosition.Start; col.pinned = true; }); @@ -42,6 +43,7 @@ export default function App() { const grid = gridRef.current; if (!grid) return; grid.selectedColumns().forEach((col) => { + col.pinned = false; col.pinningPosition = ColumnPinningPosition.End; col.pinned = true; }); diff --git a/samples/grids/tree-grid/column-pinning-both-sides/src/index.tsx b/samples/grids/tree-grid/column-pinning-both-sides/src/index.tsx index 62e62f468..4a7d08f16 100644 --- a/samples/grids/tree-grid/column-pinning-both-sides/src/index.tsx +++ b/samples/grids/tree-grid/column-pinning-both-sides/src/index.tsx @@ -32,6 +32,7 @@ export default function App() { const grid = gridRef.current; if (!grid) return; grid.selectedColumns().forEach((col) => { + col.pinned = false; col.pinningPosition = ColumnPinningPosition.Start; col.pinned = true; }); @@ -41,6 +42,7 @@ export default function App() { const grid = gridRef.current; if (!grid) return; grid.selectedColumns().forEach((col) => { + col.pinned = false; col.pinningPosition = ColumnPinningPosition.End; col.pinned = true; });