This summary is not the rule. The rule text controls.
A lawyer usually can't act as both a witness and a trial lawyer in the same case. If a lawyer knows they will likely need to testify about something important, they generally have to step back and let another lawyer handle the trial. The idea is to avoid confusion for the jury and to keep the lawyer's job as an advocate separate from their role as a witness giving facts.
There are a few exceptions to this rule. A lawyer can still testify and represent the client if the testimony is about something nobody disputes, if it's just about the legal fees charged in the case, or if removing the lawyer from the case would create a real hardship for the client. These exceptions exist because sometimes switching lawyers mid-case is impractical or unfair, especially if the client has relied heavily on that specific lawyer.
This rule also covers situations where a lawyer's law partner or coworker might be called as a witness, rather than the lawyer handling the trial. In that case, the trial lawyer can usually still represent the client, even though their colleague may testify. The only exception is if separate conflict of interest rules (Rule 1.7 or Rule 1.9) would prevent it, such as if the colleague's testimony could hurt the client's case or create a conflict between the lawyer's duties to different clients.