Why did Congress pass the Civil Rights Act of 1866 (or Reconstruction Act of 1867)?

They passed it as a reaction to the South passing Black Code

They passed it as a reaction to Andrew Johnson's vetoing everything

They passed it as a reaction to Abraham Lincoln's assassination

They passed it as a reaction to Andrew Johnson's opposition to the Freedman's
Bureau​