add option to disable custom context menu (#1128)

This commit is contained in:
Athou
2023-08-04 08:53:34 +02:00
parent cb779ec494
commit 466846d268
36 changed files with 156 additions and 3 deletions

View File

@@ -34,6 +34,7 @@ export function FeedEntries() {
const scrollMarks = useAppSelector(state => state.user.settings?.scrollMarks)
const scrollingToEntry = useAppSelector(state => state.entries.scrollingToEntry)
const sidebarVisible = useAppSelector(state => state.tree.sidebarVisible)
const customContextMenu = useAppSelector(state => state.user.settings?.customContextMenu)
const { viewMode } = useViewMode()
const dispatch = useAppDispatch()
const { openLinkInBackgroundTab } = useBrowserExtension()
@@ -62,7 +63,7 @@ export function FeedEntries() {
const contextMenu = useContextMenu()
const headerRightClicked = (entry: ExpendableEntry, event: React.MouseEvent) => {
if (event.shiftKey) return
if (event.shiftKey || !customContextMenu) return
event.preventDefault()
contextMenu.show({