Your wife doesn't want you to fix her. She wants your support, attention, love and interest. You don't give up, that makes her feel insecure, you give her space to be on her own two feet. Stop chasing her.
You can't stop her from leaving. You shouldn't enable her or be a doormat. You focus on yourself. A lot of times we call it script but our spouses usually have pretty good insight into us. Something about your behavior is causing her to walk. Improve and grow. You will attract your wife back by your actions. Confidence is a killer chick magnet. It means you can take care of business. You want your wife you don't need her. Control is needy, insecure and a fraud. Confidence is the tool to handle any situation regardless of the circumstances. That's what loving detachment is - I want you and you might choose to leave, I will thrive either way. Her actions won't dictate your success because that is your responsibility. When I coach I'll take a player with heart anyday they thrive under adversity. Make your mind up that this is just a challenge that you must show your true character in. You are the man in the arena.
Cheers
M22,H45,W45 S21/18D12 Retain faith that you will prevail in the end, regardless of the difficulties and at the same time confront the most brutal facts of your current reality, whatever they might be.