I tried to resolve this same bug but I couldn't because I didn't have it in the right project. So now, when playing java edition minecraft on linux, (debian/ubuntu lancher) the mouse is very buggy. It doesn't let you turn a full 360 degrees rotation. It only limits to my computer display. Also, from the Minecraft wiki, it said that mouse rotation on Linux is buggy. You would have to go to the esc menu and click back in to grab the mouse, but it still restricts rotation. (new chrome os versions allows users to add linux to the computer). It's like how you are on your computer on a website. Your mouse stops at the end of your display. You can't turn a full 360 degrees. When playing minecraft it does the same thing.
Related issues
Comments

People aren't getting my problem. I can't turn around all the way. It's like I can only look ow far my mouse goes. So like if your on a computer on a website of something your mouse can't turn you 360 degrees only what the screen let's you. That's exactly what the launcher is doing.

I have the same problem, but it also doesn’t let me break blocks
Thank you for your report!
We're actually already tracking this issue in MC-144107, so I resolved and linked this ticket as a duplicate.
If you would like to add a vote and any extra information to the main ticket it would be appreciated.
If you haven't already, you might like to make use of the search feature in the future to see if the issue has already been reported.
Quick Links:
📓 Issue Guidelines – 💬 Community Support – 📧 Customer Support – 📖 Game Wiki