Think about it: you have N market makers offering both sides of the trade with a spread between them. When there is no other meaningful activity, the best prices are more or less stable. Now someone comes in and buys one side of the trade. Each marker maker will, individually, make the same two decisions:
1. "If you bought at that price, I should raise my price and charge you more"
2. "Since you bought at that price, I must assume you have more information and I should get out the way to avoid an expensive mistake"
The magnitude of the decisions made depends on various factors, but as a short-hand the size of the made trades in respect to the overall liquidity available near the midpoint directs how strongly the market makers react. A tiny trickle of insignificant trades does not move the price in any meaningful way (unless the sizes are so small that the execution commission starts to make a difference). A sustained directional flood of trades will cause the midpoint (and volume) to move to the direction where the market makers can sell at higher prices and avoid accumulating any further losses.