From 571fc63cd1d389a874d4e971abacb7a5ae131e3b Mon Sep 17 00:00:00 2001 From: Oleksii Skorobogatko Date: Mon, 16 Dec 2024 21:25:02 +0200 Subject: [PATCH] #4 show only first line of clipboard item in tray menu --- src/main/system.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/system.js b/src/main/system.js index ad6b706..76819eb 100644 --- a/src/main/system.js +++ b/src/main/system.js @@ -207,7 +207,7 @@ function updateTrayContextMenu(tray, contextMenu, clipItems) { * @return {string} */ function stringCut(str, limit, trail = '...') { - const cutStr = str.trim(); + const cutStr = str.trim().split('\n')[0]; if (cutStr.length <= limit) { return cutStr;