This thread has been closed, so creating a new threat to give the solution: Microsoft Surface Book 2 Detach Pop-up - Won't detach without closing brave - #2 by joshuabeny1999
The problem is that Brave is accessing the GPU in the keyboard. If you disable hardware acceleration in the Brave setting, then it should work fine.
Best wishes,
Paul