From 410d852d36ea587b3c666a7a8c7d76110f81d6a8 Mon Sep 17 00:00:00 2001 From: Stephen Birarda Date: Mon, 21 Dec 2015 14:51:37 -0700 Subject: [PATCH] add opacity for disabled button --- console/src/css/style.less | 4 ++++ console/src/index.js | 7 ++++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/console/src/css/style.less b/console/src/css/style.less index 603be6c28d..6075555a6d 100644 --- a/console/src/css/style.less +++ b/console/src/css/style.less @@ -226,6 +226,10 @@ header { &#settings { margin-left: @side-margin + 2; } + + &.disabled { + opacity: 0.3; + } } #manage-separator { diff --git a/console/src/index.js b/console/src/index.js index f102999870..226dbb45b6 100755 --- a/console/src/index.js +++ b/console/src/index.js @@ -41,15 +41,16 @@ $(function() { switch (sendingGroup.state) { case HFProcess.ProcessGroupStates.STOPPED: - // if the process group is stopped, the stop button should be disabled - stopButton.removeAttr('href'); break; case HFProcess.ProcessGroupStates.STOPPING: + // if the process group is stopping, the stop button should be disabled + stopButton.removeAttr('href'); + stopButton.addClass('disabled'); break; case HFProcess.ProcessGroupStates.STARTED: - console.log("SETTING HREF"); // if the process group is going, the stop button should be active stopButton.attr('href', '#'); + stopButton.removeClass('disabled'); break; } }