Just press pause on negative thoughts, don’t allow them to ruin your day
Sometimes when negative thoughts intrude or are triggered by others/situations, you can simply say “no, not right now”, and kindly park it on one side. Not dismissing it, just acknowledging those thoughts and emotions, and saying that now you do not choose to engage with them. Instead, you can allow yourself to continue to enjoy what you were doing, or can use a positive memory or thought to empower your mind - because ultimately what you think about can be chosen, and those negative thoughts do not have all encompassing power.
Unbelievably, what comes to mind is Harry Potter - summon a patronus by focusing on something positive and beautiful, as when facing negativity and darkness it will give you strength.