From 6feb767cb8a289f5c167ae981b435e4c02f50215 Mon Sep 17 00:00:00 2001 From: John Walley Date: Thu, 25 Nov 2021 10:42:07 +0000 Subject: [PATCH] fix: distribute space evenly when adding a pane (#58) --- src/split-view/split-view.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/split-view/split-view.ts b/src/split-view/split-view.ts index d9f487e6..6cdeeac0 100644 --- a/src/split-view/split-view.ts +++ b/src/split-view/split-view.ts @@ -372,6 +372,10 @@ export class SplitView extends EventEmitter implements Disposable { if (!skipLayout) { this.relayout(); } + + if (!skipLayout && typeof size !== "number" && size.type === "distribute") { + this.distributeViewSizes(); + } } public removeView(index: number, sizing?: Sizing): View {