It's metaphorical, meaning no actual hitting happened. It emphasizes emotional hurt or shock. When she laughed at his poem, it felt like a slap in the face.
Pro Tip 2/3
Emotional Impact
Used to describe an event that causes significant emotional pain or embarrassment. His public criticism was a slap in the face to her hard work.
Pro Tip 3/3
Relationship Context
Often used when someone feels betrayed or let down by someone they trust. Finding out my friend lied to me was a slap in the face.