My sister married a man who treated her badly. Her husband didn’t respect her at all. After one year , they split up. After hearing that news , I called my sister and said :
Don’t worry. I think you’ll marry the man who deserves you. I strongly believe that you did the right thing.
Is this sentence idiomatic in English?
Yes, this sentence is correct, and it is idiomatic:
do the right thing
To act or behave correctly, appropriately, or with the best intentions.
You could’ve said, "What you did was appropriate, your actions were correct". Instead, you used a natural English idiom to get the same message across.
Note the the word "idiom" has several meanings (it’s a polysemic word). Consider:
Meaning 1: a manner of speaking that is natural to native speakers of a language
Meaning 4: an expression whose meanings cannot be inferred from the meanings of the words that make it up