Skip to content

Commit

Permalink
disable item pane when selecting attachments, notes, et c.
Browse files Browse the repository at this point in the history
  • Loading branch information
Dominic-DallOsto committed Aug 8, 2024
1 parent e544803 commit 27dc59f
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/cita/zoteroOverlay.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -592,7 +592,10 @@ class ZoteroOverlay {
body.firstChild! as Element,
);
},
onRender: ({ body, item, editable, tabType }) => {
onRender: ({ body, item }) => {
if (!item.isRegularItem()) {
return;
}
const tab_id: string =
body.parentElement?.parentElement?.parentElement
?.parentElement?.parentElement?.parentElement?.id!;
Expand All @@ -608,6 +611,9 @@ class ZoteroOverlay {
/>,
);
},
onItemChange: ({ item, setEnabled }) => {
setEnabled(item.isRegularItem());
},
});
}

Expand Down

0 comments on commit 27dc59f

Please sign in to comment.