Move CSS sprite tools into js/util.