From dcc5f9334429484f7e0440be9bdacd41a74bf256 Mon Sep 17 00:00:00 2001 From: Joffrey JAFFEUX Date: Tue, 29 Aug 2017 14:32:23 +0200 Subject: [PATCH] FIX: disable highlighting when no value set on select-box --- app/assets/javascripts/discourse/components/select-box.js.es6 | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/app/assets/javascripts/discourse/components/select-box.js.es6 b/app/assets/javascripts/discourse/components/select-box.js.es6 index 7cd76b39640..3085f35eaea 100644 --- a/app/assets/javascripts/discourse/components/select-box.js.es6 +++ b/app/assets/javascripts/discourse/components/select-box.js.es6 @@ -65,6 +65,10 @@ export default Ember.Component.extend({ shouldHighlightRow: function() { return (rowComponent) => { + if (Ember.isNone(this.get("value"))) { + return false; + } + const id = this._castInteger(rowComponent.get(`content.${this.get("idKey")}`)); if (Ember.isNone(this.get("lastHovered"))) { return id === this.get("value");