Term: compersion
Example: i feel compersion when i see my husband come home happy from spending time with his girlfriend
Definition: "a feeling of joy when a loved one invests in and takes pleasure from another romantic or sexual relationship