  We systematically study the properties of pure nucleonic and hyperonic
magnetic stars using a density-dependent relativistic mean-field (DD-RMF)
equations of state. We explore several parameter sets and hyperon coupling
schemes within the DD-RMF formalism. We focus on sets that agree with nuclear
and other astrophysical data, while generating heavy neutron stars. Magnetic
field effects are included in the matter equation of state and in general
relativity solutions, which in addition fulfill Maxwell's equations. We find
that pure nucleonic matter, even without magnetic field effects, generates
neutron stars that satisfy the potential GW190814 mass constraint. However,
this is not the case for hyperonic matter, which instead only satisfies the
more conservative 2.1 M$_{\odot}$ constraint. In the presence of strong but
still realistic internal magnetic fields $\approx 10^{17}$ G, the stellar
charged particle population re-leptonizes and de-hyperonizes. As a consequence,
magnetic fields stiffen hyperonic equations of state and generate more massive
neutron stars, which can satisfy the possible GW190814 mass constraint but
present a large deformation with respect to spherical symmetry.
