It doesn't happen in any textbox, only in some sites/apps like github and matrix. The text is correctly pasted but takes a long time and the UI process is blocked during that time (I guess it's a sync message). I haven't tried in X11, so I'm assuming it's Wayland specific.