Companies that do this should be named, shamed and you should question how financially liable they are. Nobody keeps their bonus to return it, this sounds weirdly illegal. I say let them sue and find a lawyer that challenges the lawsuit on the grounds of what bonuses are meant to be, if you don't want someone to leave before X years, hold their bonuses till their Xth year working for you, but let them pile up, and no take backsies.