If you have paid into your company pension for fifteen years and you resign, but don't take your pension for ten more years, does it continue to increase in value or does it remain at the level it reached at the time you ceased paying into it?
Your money will remain invested and therefore benefit from any gains made by those investments. https://www.pensionsadvisoryservice.org.uk/about-pensions/when-things-change/leaving-your-pension-scheme