From 890dbc6ad721f7685af19217331bd039e0da5923 Mon Sep 17 00:00:00 2001 From: BioSehnsucht Date: Tue, 3 Oct 2017 14:34:43 -0500 Subject: [PATCH] Rename input_slider to input_number and add numeric text box option (#431) * * Rename input_slider to input_number * Update input_number to Polymer 2.0 * Update input_number to optionally display slider, input box, or both * input_number support either input box or slider mode, but not both * input_number : change service from select_value to set_value --- src/state-summary/state-card-content.html | 2 +- .../state-card-input_number.html | 121 ++++++++++++++++++ .../state-card-input_slider.html | 83 ------------ src/util/hass-util.html | 6 +- 4 files changed, 125 insertions(+), 87 deletions(-) create mode 100644 src/state-summary/state-card-input_number.html delete mode 100644 src/state-summary/state-card-input_slider.html mode change 100755 => 100644 src/util/hass-util.html diff --git a/src/state-summary/state-card-content.html b/src/state-summary/state-card-content.html index 5f6fce3a2b..32269e870c 100644 --- a/src/state-summary/state-card-content.html +++ b/src/state-summary/state-card-content.html @@ -5,7 +5,7 @@ - + diff --git a/src/state-summary/state-card-input_number.html b/src/state-summary/state-card-input_number.html new file mode 100644 index 0000000000..1e41bdb299 --- /dev/null +++ b/src/state-summary/state-card-input_number.html @@ -0,0 +1,121 @@ + + + + + + + + + + + + + + + + + diff --git a/src/state-summary/state-card-input_slider.html b/src/state-summary/state-card-input_slider.html deleted file mode 100644 index 99a3d1ee2c..0000000000 --- a/src/state-summary/state-card-input_slider.html +++ /dev/null @@ -1,83 +0,0 @@ - - - - - - - - - - - - - diff --git a/src/util/hass-util.html b/src/util/hass-util.html old mode 100755 new mode 100644 index 7a191001e3..504005346b --- a/src/util/hass-util.html +++ b/src/util/hass-util.html @@ -15,7 +15,7 @@ window.hassUtil.DOMAINS_WITH_CARD = [ 'cover', 'configurator', 'input_select', - 'input_slider', + 'input_number', 'input_text', 'media_player', 'scene', @@ -32,7 +32,7 @@ window.hassUtil.DOMAINS_WITH_MORE_INFO = [ window.hassUtil.DOMAINS_WITH_NO_HISTORY = ['camera', 'configurator', 'scene']; window.hassUtil.HIDE_MORE_INFO = [ - 'input_select', 'scene', 'script', 'input_slider', 'input_text' + 'input_select', 'scene', 'script', 'input_number', 'input_text' ]; window.hassUtil.LANGUAGE = navigator.languages ? @@ -289,7 +289,7 @@ window.hassUtil.domainIcon = function (domain, state) { case 'input_select': return 'mdi:format-list-bulleted'; - case 'input_slider': + case 'input_number': return 'mdi:ray-vertex'; case 'input_text':