Mindfulness, deep breaths, even letting yourself curse and yell for a moment after a bad beat or missed play then let it go.
I find for me that more upbeat music helps keep focused, and taking a deep breath before, during, and after a big play (well online at least, I don't want to give away tells live, so live I would likely mentally self talk and tell myself to remain calm and focused).
Also what I found recently helps is that if I feel I'm playing tilted or scared or suffered a bunch of bad beats, I'll drop to a lower level briefly and get some confidence back. I thought it was silly but it actually makes me feel better, gets me focused again, and then I go back to my level ready to crush.
I had a big win a few weeks ago which changed my perspective and also took pressure off those nervous moments in poker play. Which I think is incorrect , I shouldn't let the win influence me either way but from a human perspective it's nice to have a win put me in the black and not feel like the account is just going down down down lol.