You'll want to check with your surgeon about this question. Returning to previous levels of activities like horseback riding may not be allowed until full healing has occurred. This is especially true if there are metal pins, screws, or plates in the joint.
Most expert riders agree a dorsiflexed ankle is important in riding. This means your toes
are pointing up and your heels are pressed down while in the stirrups. When the motion in the healing ankle is within five degrees of the other ankle, then activities like horseback riding may be allowed.
You may want to think about buying some breakaway or safety stirrups. If your horse falls, spooks, or throws you, the stirrups drop off the saddle. Your feet won't get stuck in the stirrups while you get dragged around or crushed by the horse.