Skip to content
This repository was archived by the owner on Sep 1, 2020. It is now read-only.

keyboard event listener not unregistered #176

@loicbourg

Description

@loicbourg

Version

1.9.1

Test Case

https://jsfiddle.net/6ty1r8yn/1/

Steps to reproduce

  • Right click on the context menu trigger.
  • Hover the first Sub menu
  • Click "Ajouter"
  • Type some text in the textarea and try to add a new line with enter

Expected Behavior

I should have a text with multiple new line in the textarea

Actual Behavior

no new line is added

Additional informations

The arrow key are also not working.

I suspect it comes from https://github.com/vkbansal/react-contextmenu/blob/master/src/AbstractMenu.js#L21

in the console there is a warning when using the arrow key or enter:
Warning: Can only update a mounted or mounting component. This usually means you called setState, replaceState, or forceUpdate on an unmounted component. This is a no-op.

Please check the code for the t component.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions