This keyboard interaction was disabled as soon as the modal was created in XWIKI-15611 .
Note that there are four modals that follow this pattern. The solution I'll propose fixes all four of them the same way.