carbon-design-system / carbon-components-svelte

Svelte implementation of the Carbon Design System
https://svelte.carbondesignsystem.com
Apache License 2.0
2.68k stars 261 forks source link

ContextMenu prevents context menu invocations outside of the target #1909

Closed gtm-nayan closed 7 months ago

gtm-nayan commented 7 months ago

The use of preventDefault on this line https://github.com/carbon-design-system/carbon-components-svelte/blob/65904575743ba06344fb75e14685e42494c13cde/src/ContextMenu/ContextMenu.svelte#L141

applies to contextmenu events anywhere on the page, so even if you right click somewhere on the page that's not inside the target, it'll prevent the browser's context menu from opening

metonym commented 7 months ago

This is a major bug, thanks for reporting.

metonym commented 7 months ago

Fixed in v0.82.9