Not that long since Dilithium became readily available. Still might take years to design and build new ships, versus retrofitting older ones.
I disagree.
Even in the 24th century it was relatively easy to refit older ships with modern hw with just replicators and transporters - especially because SF ships are usually designed to be modular.
In the 32nd century, it would be even easier to upgrade everything.
Discovery was thoroughly refitted using 32nd century technology in 3 weeks... and that was a ship 930 years from the past.
Deign of ships took a longer time in the mid 24th century. The Galaxy class was probably in design development stage for a while (unofficial sources say 14 year) whereas actual construction of the thing would have taken a fraction of the time (about a month if you factor in all the tech SF had back then).
However, past that point, things started to accelerate radically... as we've seen new designs like the Sovereign, Intrepid, Defiant, etc. only about 5 years after Wolf 359 (which was end of S3 and start of S4 of TNG).
Plus if SF actually decided to use automated R&D using their computer systems, design and development of new ships would probably be reduced to a few days or less. That is if they have an equivalent of 'supercomputer datacentre' which networks multiple computer cores in massive parallelism.
True - all these ships may have been in drydock being built when all the dilithium went <FOOM!>, before the warp cores were installed. They may have been finished, but were just never commissioned and fielded, because they had nothing to run the engines.
In short, yes, they were all antiques, but had zero mileage, so still in mint condition and in their original factory wrapper. Just needed a fresh coat of paint and new-car scent sprayed everywhere.
I wouldn't exactly call them 'antiques' mainly because if the inner hw was modern, then they were basically 32nd century modern ships with up to date tech... just older frames (and even that's not certain because you can just take section of a ship, recycle it into energy and then just add a bit more energy or matter to basically create a frame that was just out of assembly line).
It would have been akin to the USS Lakota being modified with 24th century technology and managing to rival the Defiant (a modern late 24th century 'warship').
The only thing that grates me is that SF seemingly lost the ability to defend itself effectively against other powers.
The Emerald chain and the Breen seemingly had massive behemoths of ships that SF individual ships couldn't hope to match.
In the 24th century, SF wasn't generally fooling around and kept itself up to date. The Remans started a trend with the Scimitar, but even then the ENT-E was able to hold its own against that thing (until it got some assistance from the Romulans which gave it a second wind).
In the 32nd century, it seems any other power can just easily stomp over anything SF has in that future - which makes me wonder, why do more hostile species even 'tolerate' UFP's existence in that case and not simply wipe it out of existence?
Granted, its possible that because UFP spread so far before the Burn and a lot of time has passed, its possible that many hostile species simply were no longer hostile to the Federation.
But the ones that were (like the Breen)... I mean, it never made sense they'd need the Progenitor's technology to wipe out the Federation. They could have easily done it at any time, so why go through the whole song and dance when they'd really have 0 reason to do that?