It depends on the kind of quantum computer and how many logical qubits it has. Not all quantum computer designs are capable of breaking cryptographic systems. The popular adiabatic quantum computers, while very useful for certain tasks, have no cryptanalytic utility. Designs that are capable of running, say, Shor's algorithm are currently in their infancy. It isn't known how well they'll scale.
Realistically, when/if such quantum computers become mainstay, we will need to have moved from algorithms based on factorization or the discrete log problem (or any other hardness problem in the BQP complexity class) to a post-quantum variant. Key exchange algorithms must be upgraded sooner. If you need 25 years of protection, you have to discontinue vulnerable algorithms 25 years before quantum computers can attack it. Key exchange algorithms are vulnerable to retroactive cryptanalysis.
It's not as important to upgrade to post-quantum signature schemes. You can delay upgrading a digital signature algorithm until the very day a quantum computer becomes available. This is because breaking a signature must be done at the time of the attack, not after. This isn't unique to quantum computers. Someone who used PGP in the 90s with a 512-bit key doesn't need to worry about someone forging their signatures because that key has long-since been revoked, so obtaining the private key is useless.
NIST is currently working on standardizing post-quantum key exchange and signature algorithms for this very reason. They have set a tentative completion date for 2024. They are currently in round 2.