At least 23 people were injured and dozens of buildings collapsed, state media reported, after a shallow 5.4-magnitude earthquake struck eastern China in the early hours of Sunday.