You can see at about 2:24 in this video that these players tested if when Sombra is invisible and protected by Zarya's bubble she turns visible. It looks like she does not turn visible.
However, Zarya's bubble makes it pretty clear where she is.
As for if she turns visible when she is shot and protected, the only information I can really find about this is from a battle.net post. They said:
Zarya bubble does reveal allied stealthed Sombra, however as long as the barrier isn't broken her stealth isn't cancelled. Zarya gets charge as normal from this.
Contrary to what I found in the video, this user states it that Zarya's bubble does reveal Sombra if she is invisible. I disagree about that point, unless they are referring to how the bubble reveals her position. They do state that as long as the barrier of the bubble is not broken, then she will remain invisible. I would imagine this to be true. I would think that Sombra would in fact become visible if you shot her whether or not she was being protected. It only makes sense for the game mechanic to work that way.