DETROIT - Hyundai is recalling thousands of late-model Velosters in the United States and Canada to fix problems involving parking brakes on some models and a sunroof that can shatter and cause injuries on others.

The recall involving the sunroof affects cars from the 2012 model year, including some 13,500 in the United States and 1,593 in Canada.

The separate recall to fix parking brakes affects about 4,500 vehicles in the United States and 1,565 in Canada.

The U.S. National Highway Traffic Safety Administration began investigating the sunroof problem in October after getting complaints from customers. Hyundai traced the problem to a manufacturing defect that damaged the sunroof glass.

The car maker says parking brake mechanisms on some Velosters built between July 2, 2011 and Feb. 27, 2012, might bind after exposure to moisture and road grime, which could cause the parking brake to rub and generate excess friction.

The compromised parking brake might also not engage properly when the car is parked, possibly allowing it to roll away, Hyundai said.

Hyundai says it will start notifying owners by mail in January and will inspect and replace the panoramic sunroof glass for free if necessary. The parking brake problem will also be fixed free of charge.

— With files from The Canadian Press