I have social anxiety, but thankfully not panic attacks except in certain driving scenarios which is frankly dangerous.
I have a small understanding and am very sympathetic. I have to go to the gym early in the morning when there are fewer people there and I notice that the few people are very regular. You rarely see new faces. Last week I went to the pool expecting it to be empty. When it wasn't and I found all the lanes full, I did an about face and ran back to the "safety" of the locker room. I caught myself up and made myself go back. I simply asked someone who looked nice if I could share a lane and of course it was fine. I got into my mental zone and did fine. That fight or flight response is a real barrier and I'm very thankful that I'm able to talk myself rationally out of the flight mode, but I understand it's not like that for everyone.
People at the gym are so nice. I know you know that rationally, but what you're feeling inside tells you otherwise. Your body tells you you're actually in danger. Everyone at the gym is so consumed with themselves. Gym is "me time" for everyone. It's a time for self-reflection and for finding your inner voice and your inner athlete. That's what everyone is thinking about, and not you.
And just so you know, a tiny, very athletic man collapsed in one of my classes this morning.
It can happen to absolutely anyone. Everyone was very helpful, very sympathetic and very tactful