Prompt $${J/\psi }$$-pair production at the LHC: impact of loop-induced contributions and of the colour-octet mechanism