const handleKeyDown = (e) => {
    if (e.keyCode === KEY_CONSTANTS.ENTER) {
        // Act as if space was pressed, taking into account cursor position and text highlighting
        const end = ref?.current.selectionEnd;
    }
};

handleKeyDown(5);
