Exploring Electromagnetic Field Effects on Charge-dependent Directed Flow with STAR