Info box: Fix second right-click opening section menu

On Windows, after right-clicking on a title field.

this.querySelector('popupset') matched the popupset in the
collapsible-section head, not our own.

Fixes #5294
This commit is contained in:
Abe Jellinek 2025-05-21 12:11:42 -04:00
parent 46f80ebdfb
commit 3ff13bc08d

View file

@ -592,7 +592,6 @@
optionsButton.className = "zotero-clicky zotero-clicky-options show-on-hover";
optionsButton.setAttribute('data-l10n-id', "itembox-button-options");
optionsButton.id = `itembox-field-${fieldName}-options`;
// eslint-disable-next-line no-loop-func
let triggerPopup = (e) => {
let menupopup = ZoteroPane.buildFieldTransformMenu({
target: valueElement,
@ -600,7 +599,7 @@
this._setFieldTransformedValue(valueElement, newValue);
}
});
this.querySelector('popupset').append(menupopup);
this.querySelector('#info-box > popupset').append(menupopup);
menupopup.addEventListener('popuphidden', () => {
menupopup.remove();
});