From 2d3bc12ca02be7c7fc62716ea98fe7b985cdeef1 Mon Sep 17 00:00:00 2001 From: Bogdan Abaev Date: Thu, 1 Feb 2024 10:30:46 -0500 Subject: [PATCH] fx115: lookup panel fixes - do not resize based on scrollable content - it shrinks the panel - add padding into the stylesheet - remove onShowing, since it doesn't seem needed anymore --- chrome/content/zotero/lookup.js | 25 ------------------------- chrome/content/zotero/zoteroPane.xhtml | 1 - chrome/skin/default/zotero/overlay.css | 2 ++ 3 files changed, 2 insertions(+), 26 deletions(-) diff --git a/chrome/content/zotero/lookup.js b/chrome/content/zotero/lookup.js index 61fd6a01a9..fe64eab699 100644 --- a/chrome/content/zotero/lookup.js +++ b/chrome/content/zotero/lookup.js @@ -184,24 +184,6 @@ var Zotero_Lookup = new function () { } - /** - * Focuses the field - */ - this.onShowing = function (event) { - // Ignore context menu - if (event.originalTarget.id != 'zotero-lookup-panel') return; - - document.getElementById("zotero-lookup-panel").style.padding = "10px"; - - // Resize arrow box to fit content - if (Zotero.isMac) { - let panel = document.getElementById("zotero-lookup-panel"); - let box = panel.firstChild; - panel.sizeTo(box.scrollWidth, box.scrollHeight); - } - } - - /** * Focuses the field */ @@ -280,13 +262,6 @@ var Zotero_Lookup = new function () { mlTxtBox.rows = on ? 5 : 1; mlButtons.hidden = !on; - // Resize arrow box to fit content -- also done in onShowing() - if(Zotero.isMac) { - var panel = document.getElementById("zotero-lookup-panel"); - var box = panel.firstChild; - panel.sizeTo(box.scrollWidth, box.scrollHeight); - } - return mlTxtBox; }; diff --git a/chrome/content/zotero/zoteroPane.xhtml b/chrome/content/zotero/zoteroPane.xhtml index e4ecffaf35..a49d831569 100644 --- a/chrome/content/zotero/zoteroPane.xhtml +++ b/chrome/content/zotero/zoteroPane.xhtml @@ -1087,7 +1087,6 @@ />