It is not dependent upon how the current flows at the output of the opamp.
We can treat the output pin as having a very low output impedance.
The calculations determine by how much the inverting input changes in voltage due to the current flowing into (or out of) the inverting input itself. This is determined by the effective resistance of the feedback network.
By putting the same value resistor on the non-inverting input we can compensate for that error.
For example if R1 and R2 were both 2K, the effective resistance at the input would be 1K. (the two are effectively in parallel and the output pin is assumed to have zero resistance).
If the amplifier had an input bias current of 1uA this would cause a 1mV change in the voltage at the input that would cause an error as the output would have to change by 2mV to make the non-inverting input match the inverting input.
If however we put a 1K resistor in series with the non-inverting input as well, it would also change its voltage by 1mV in the same direction and cancel out the error.
I think the images you posted cover the math reasonably. Let me just try to give you a bigger picture view.
Output impedance is the change in output voltage due to a change in the output current. (I don't think your sources do a good job making this point, at least within the bits you cut and pasted).
So if you have negative feedback circuit, and the load starts to draw more current (say it has a switch inside it that gets closed), then what happens?
At first, the output voltage might drop, because of the internal resistance of the op-amp output circuit. But when it does, that will be conveyed by the feedback network back to the op-amp inputs, telling it to increase its output voltage. Which counteracts (mostly) that initial change. If the load current change is slow enough, you wouldn't even see the "initial" change before the feedback responded and eliminated it.
So the output voltage change of the closed-loop circuit is much smaller than it would have been without the feedback. This is the point your sources are trying to convey.
Of course, this all depends on the changes in load current being slow enough for the op-amp and feedback network to keep up with. That means you can only count on this improvement in output impedance for load changes with frequencies in the operating bandwidth of your circuit (op-amp and feedback network).
Best Answer
(1) The voltage at the inverting terminal is 0V* so, by KVL,
$$v_{OUT} = 0V - i_{R_F}R_F $$
where the reference direction for \$i_{R_F}\$ is from left to right through \$R_F\$
(2) By KCL,
$$i_{R_i} = i_{R_F} $$
since the inverting input is an open circuit.
(3) By Ohm's Law,
$$i_{R_i} = \dfrac{v_{IN}}{R_i}$$
(remember, the voltage at the inverting terminal is 0V).
Thus:
$$v_{OUT} = 0V - i_{R_F}R_F = -i_{R_i}R_F = -\dfrac{v_{IN}}{R_i}R_F$$
or
$$\dfrac{v_{OUT}}{v_{IN}} = -\dfrac{R_F}{R_i}$$
*For an ideal op-amp with negative feedback, the inverting and non-inverting input voltages are equal.