Retirement tax questions

Quick question. What happened to the capital gains on the original transfer? I had almost the same situation. They transferred my original rollover into an ira using the irs form but left over 8k in the brokerage account that was capital gains.