Oof, that is a terrible thing to hear.
I'm afraid I can't offer any real helpful advice, just a sad childhood story. We had a wire ball that my old hamster, Zoe, could fit her legs through, and one of the neighbors kids was probably 6 years old or so, she rolled the ball real hard, and both of Zoe's back legs swelled up and she started gnawing at them, and we had to put her down.
I'm really sorry to hear that this has happened. all I can suggest is that if you can maybe wrap up her leg, or find some way to make sure she can't reach it until you can get to the specialist, go for it. Those
wire cages, especially the wire balls, seem kind of risky for their little legs.

Make sure you keep an eye on her!
Edit: To try and ease your mind though, you said she can move her toes and such, Zoe's legs were so swollen they were almost to pencil-thickness or bigger, and they weren't even recognizable as legs anymore. I think it was an extreme case.