Lawmakers in the Virginia House narrowly passed a bill banning assault-style weapons as Democrats continued using their newfound political clout to push ahead on a slate of gun-control bills.

The path ahead for an assault-weapons ban remains uncertain, despite a push for limits by Democratic Gov. Ralph Northam. The bill will now go to the Senate, where a more stringent version was withdrawn earlier in the session. Democrats have a slimmer, 21-19 majority in the Senate, which means they could only afford to lose one vote from...