From 5ac5c30964d8f06169492e59dba73d10f7595256 Mon Sep 17 00:00:00 2001 From: jquense Date: Sun, 13 Dec 2015 16:36:43 -0500 Subject: [PATCH] [fixed] reset gutter widths before calculations --- src/TimeGrid.jsx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/TimeGrid.jsx b/src/TimeGrid.jsx index f15f40f0a..651de61a4 100644 --- a/src/TimeGrid.jsx +++ b/src/TimeGrid.jsx @@ -206,9 +206,13 @@ let TimeGrid = React.createClass({ let gutterCells = [findDOMNode(this.refs.gutter), ...this._gutters] let isOverflowing = this.refs.content.scrollHeight > this.refs.content.clientHeight; + if (width) + gutterCells.forEach( + node => node.style.width = ''); + this._gutterWidth = Math.max(...gutterCells.map(getWidth)); - if (width !== this._gutterWidth) { + if (this._gutterWidth && width !== this._gutterWidth) { width = this._gutterWidth + 'px'; gutterCells.forEach(node => node.style.width = width) }