Breaker trips immediately
Mistakes were made. It happens. 


taking apart apart all the wires instead of just the 2 conductors the lamp was actually attached to (other than ground). This happens a Lot. 
not taking photos before the fact.   
"White" is a color.  "Neutral" is a function. Confusing them.  The trouble is, cables are manufactured only with certain colors (white and black), and you are stuck with those colors even though the wires will in fact have a variety of functions.  


Ideally, you re-mark the wires with colored tape - black for hot, red for switched-hot, yellow for messengers, blue/purple/green/etc. for alternate hots, or whatever scheme you prefer.   However the vast majority of "in a hurry" high-production installers never do that. 

Now in residential cables, there are special rules: white/gray can be reused/remarked as hot wires, but colored wires cannot be reused as neutrals.  Nothing can be remarked as a ground, and green/bare can't be remarked, so green tape on a black wire makes it still a hot.  

In a switch loop, it's common practice (and now Code) to make the white the always-hot, to help the next guy identify it as not a neutral (since a voltage tester will reveal hot all the time, even if the switch is off.)  The other wire in a switch loop is switched-hot, neutral is not present, (but is now required in new construction to support smart switches).

"switch loop" is the word I want you to Google, because this is where things went wrong in this setup.  One of the wires coming back from the switch is actually "switched hot", as is the hot wire to the lamp obviously.  Mark those red.  Once you have done so, then you can match by color.