Sounds like you've burnt out the 5v regulator on the Uno. One of two things may have happened:-
1) The regulator chip has blown open circuit. This may have saved the rest of the arduino an it may be possible to power it up via the USB port and it might work.
2) The regulator chip has blown short circuit. This would have applied the 12V to the entire circuit and trashed the Arduino.
Either way I would replace the Uno.
Pololu have a useful resource for the A4988 here:-https://www.pololu.com/product/1182
Which includes this bare bones wiring diagram:-
Note that the 12V 10A supply should be connected directly
to the VMOT and GND pins NOT
via the Arduino. The Arduino should only be used to power up the VDD pin to supply the on-board logic.
Also check the spec sheet for your stepper motor as the A4988 is only rated for 1A into each coil. You may need something with a little more drive capacity such as the TB6600.
You might want to check the wiring of your motor windings you seem to have them in the order 1A(Red), 1B(Black), 2A(Red), 2B(Black) whereas the pinout of the A4988 is 1B(Black), 1A(red), 2A(Red), 2B(Black).