From b2320696319b0add818de9ed817decda97ef1157 Mon Sep 17 00:00:00 2001 From: j433866 Date: Thu, 30 May 2019 14:32:05 +0100 Subject: [PATCH] If a tab can't be added, show the shadow on the... last tab to indicate there are more tabs --- src/web/InputWaiter.mjs | 3 +++ src/web/OutputWaiter.mjs | 3 +++ 2 files changed, 6 insertions(+) diff --git a/src/web/InputWaiter.mjs b/src/web/InputWaiter.mjs index fec0f1b8..b59d1f86 100644 --- a/src/web/InputWaiter.mjs +++ b/src/web/InputWaiter.mjs @@ -1283,6 +1283,9 @@ class InputWaiter { action: "updateTabHeader", data: inputNum }); + } else if (numTabs === this.maxTabs) { + // Can't create a new tab + document.getElementById("input-tabs").lastElementChild.style.boxShadow = "-15px 0px 15px -15px var(--primary-border-colour) inset"; } if (changeTab) { diff --git a/src/web/OutputWaiter.mjs b/src/web/OutputWaiter.mjs index f6806ff3..2563d7e8 100755 --- a/src/web/OutputWaiter.mjs +++ b/src/web/OutputWaiter.mjs @@ -663,6 +663,9 @@ class OutputWaiter { document.getElementById("save-all-to-file").style.display = "none"; } + } else if (numTabs === this.maxTabs) { + // Can't create a new tab + document.getElementById("output-tabs").lastElementChild.style.boxShadow = "-15px 0px 15px -15px var(--primary-border-colour) inset"; } if (changeTab) {