For better accessibility it's suggested by the WAI-ARIA doc to set focus on the button that triggered the opening of the modal, however this is not the modal's concern.
Another thing that might be good is to lock focus within the dialog. We could do that with something like the inert attribute.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
For better accessibility it's suggested by the WAI-ARIA doc to set focus on the button that triggered the opening of the modal, however this is not the modal's concern.
Another thing that might be good is to lock focus within the dialog. We could do that with something like the inert attribute.