From 12952564a4b1f11a6b6c850d5088e7e5aee92fe2 Mon Sep 17 00:00:00 2001 From: Adam Jones Date: Sun, 12 May 2024 11:38:47 +0100 Subject: [PATCH] Hide clipboard message if suppressInfo enabled Fixes #141 --- addon/sidebar.html | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/addon/sidebar.html b/addon/sidebar.html index 5f13558..eef29cb 100644 --- a/addon/sidebar.html +++ b/addon/sidebar.html @@ -256,14 +256,18 @@ // Test to see the result of the Promise from writing to the clipboard. function clipSuccess(result) { // All is well: notify for now until everyone gets used to it. - text.value = '\n\n' + text.value; + if (!config.suppressInfo) { + text.value = '\n\n' + text.value; + } } function clipError(error) { var text = document.getElementById('text'); // See https://bugs.chromium.org/p/chromium/issues/detail?id=1074489 // Don't bother people with error message: they'll need to cut and paste output as usual. //text.value = '\n\n' + text.value; - text.value = '\n\n' + text.value; + if (!config.suppressInfo) { + text.value = '\n\n' + text.value; + } }