It's a little montage that serves me in many projects, the input voltage (Vin) accepts an industrial voltage 24V (max), the output is adjustable from 0 to Vin with the potentiometer R2.
Connector K1 is more useful to be installed in its bent 90 ° version, making this power supply not greedy on space. (vertical installation on a breadboard or soldered on a motherboard mounting)
The PCB is only 30 x 18 mm, and dimensions can be further improved, however, if it interested someone.
Another possible improvement is to use SMD components to further reduce the footprint of this circuit.
Just a small contribution to start, I hope it will serve the greatest number.
Enjoy !
Unfortunately, you won't be able to get to the full range at 1A because the LM317 will have to dissipate the voltage drop * current as heat. That layout is not designed for mounting a huge heat sink.
In reality, a bare TO220 has theta JA of 40C/W, so each watt of power it dissipate will increase its temperature over the ambient by 40C. So a couple of watts is all it can take on tis layout. You are looking at over 100C already. :P