It would be a percentage thing. If I am the only competitor in the market, I can pass costs on to my consumers 100% because they can't really go anywhere else. I can also sneak in additional markup because prices are rising in other markets, labor costs, etc., so they probably won't notice. I've dominated the market, so opportunities to grow are more challenging (growing the market rather than taking market share). This provides an easier opportunity. End result is that my profit might increase.
If I have more competition, I might trade off taking some of the hit from my increased costs while still passing some on to the consumer to offer a lower overall price than my competition and potentially increase my market share, which ideally still leads to greater profits due to increased sales.