diff --git a/CHANGELOG.md b/CHANGELOG.md index d63d983bc46..cd36b2d6b85 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ ## [`master`](https://github.com/elastic/eui/tree/master) -No public interface changes since `3.5.0`. +- Fixed a bug around `indeterminate` checkboxes ([#1110](https://github.com/elastic/eui/pull/1110)) ## [`3.5.0`](https://github.com/elastic/eui/tree/v3.5.0) diff --git a/src/components/form/checkbox/checkbox.js b/src/components/form/checkbox/checkbox.js index 0f905f31399..2371a201261 100644 --- a/src/components/form/checkbox/checkbox.js +++ b/src/components/form/checkbox/checkbox.js @@ -85,13 +85,13 @@ export class EuiCheckbox extends Component { this.props.inputRef(input); } - if (input) { - this.invalidateIndeterminate(); - } + this.invalidateIndeterminate(); } invalidateIndeterminate() { - this.inputRef.indeterminate = this.props.indeterminate; + if (this.inputRef) { + this.inputRef.indeterminate = this.props.indeterminate; + } } }