Trade unions condemn ‘dangerous precedent’ set by jailing fracking protesters