The Current-Voltage Laws of Capacitor and Inductor
Current is proportional to how fast the voltage changes
The upper panel is the triangle-wave voltage applied to a capacitor, and the lower panel is the current that flows. Slide the slope of the voltage, its rate of change dv/dt, and the triangle wave steepens while the height of the square wave below changes with it. That is because a capacitor's current is proportional not to the voltage at that instant but to how fast the voltage is changing: i = C·dv/dt. Set the slope so the current reaches the target of 4 on the orange dashed line.
A different arithmetic from the resistor
A resistor ties the voltage and current of this very instant directly through Ohm's law, v = iR. A capacitor works differently. The charge q stored on its plates is proportional to the voltage (q = Cv), and the current is the rate at which that charge moves in and out (i = dq/dt), so combining them gives i = C·dv/dt. The current therefore depends not on what the voltage is now but on how fast it is changing: a high voltage that holds still drives no current, while a low voltage that changes quickly drives a large one.
A steady voltage blocks the current
If dv/dt is 0, that is, if the voltage does not change, the current is 0 too. Leave a DC voltage applied and the capacitor, once charged, passes no more current, so it blocks DC; when the voltage swings quickly, on the other hand, a large current flows, so fast signals pass easily. The triangle wave in the plot shows this clearly. During the first half, while the voltage climbs at a straight slope, the current is flat and constant; in the second half, where the slope turns negative, the current flips sign at once and traces a square wave. The current waveform is simply the slope of the voltage waveform carried over.
The inductor is the mirror
An inductor is the capacitor's mirror, with voltage and current swapped. If the capacitor was i = C·dv/dt, the inductor is v = L·di/dt: the rate of change of current makes the voltage. That is why an inductor's current cannot change suddenly; changing in an instant would need an unboundedly large voltage. For the same reason a capacitor's voltage cannot change suddenly either, since that would need an unboundedly large current. These two differential laws are the starting point of every transient, and the time constant τ, as well as the impedances jωL and 1/jωC seen with sinusoids, all come from putting a sinusoid into this pair of laws.
Back to the first screen
As you slid the slope dv/dt, the current in the lower panel grew in proportion, and it reached the target of 4 when the slope was 2 (C = 2). While the voltage rose straight the current was flat, the steeper the slope the larger the current, and when the slope turned negative the current flipped sign. The current follows not the voltage at that instant but how fast the voltage changes; that is all of i = C·dv/dt. The inductor is its mirror with the roles swapped, v = L·di/dt. If a resistor ties values together, capacitors and inductors tie changes together, and this pair of differential laws is the root of transients and reactance.