I was at the end of the calculator exercise when I found a weird bug/conflict between my mouse and my keyboard support. You can reproduce the bug by clicking on, for example, 9 with your mouse, then + and 1 with the keyboard and finally you will see the problem when clicking “enter” on your keyboard.
I don’t understand how the last click (here 9) is saved in the “enter” keydown eventListener and I don’t even know if the problem come from there or if it come from another part of my code…
Other than that, my calculator works fine if I only use the mouse or the keyboard.
The calculator : https://dxshura.github.io/calculator/
The code : https://github.com/DxShura/calculator
Thank you in advance for your help,