diff options
author | Florrie <towerofnix@gmail.com> | 2019-10-15 22:03:09 -0300 |
---|---|---|
committer | Florrie <towerofnix@gmail.com> | 2019-10-15 22:03:09 -0300 |
commit | cb4835e4eb3df8cfddfe33b94cc1afb202615acf (patch) | |
tree | 6b967c6570700b13db3dd85f5876d740890c071b | |
parent | 3a8c4c7dcacdd2f292f9b8d32b3fa88caca46f87 (diff) |
Dim selected non-playable when not focused
-rw-r--r-- | ui.js | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/ui.js b/ui.js index a221b04..88b26af 100644 --- a/ui.js +++ b/ui.js @@ -2046,7 +2046,12 @@ class BasicGrouplikeItemElement extends Button { if (isSelfSelected) { writable.write(ansi.invert()) } else if (isCurrentInput) { - writable.write(ansi.setAttributes([ansi.A_INVERT, ansi.A_DIM])) + // technically cheating - isPlayable is defined on InteractiveGrouplikeElement + if (this.isPlayable === false) { + writable.write(ansi.setAttributes([ansi.A_INVERT, ansi.C_BLACK, ansi.A_BRIGHT])) + } else { + writable.write(ansi.setAttributes([ansi.A_INVERT, ansi.A_DIM])) + } } writable.write(ansi.moveCursor(this.absTop, this.absLeft)) |