React cannot focus inside of showDialog

I am rendering ReactWidget for dialog body and want to give focus to input inside of React widget when I open dialog opens. but it doesn’t get focus. (it works correctly outside of jupyterlab in custom react project)

only thing i can do is using hacky solution to fix it.