Tweens a fixed-size array of HSL colors toward palette-chosen targets.
This class is stateful and uses Math.random() when (re)targeting.
Math.random()
Palette of candidate colors. Must be non-empty.
Number of colors to manage (array length for currentColors).
currentColors
Current interpolated colors (length equals the size passed to the constructor).
size
Chooses a new random target color for each entry.
Advances interpolation toward the current targets.
Interpolation factor (typically in $[0, 1]$). This method does not clamp t.
t
Tweens a fixed-size array of HSL colors toward palette-chosen targets.
This class is stateful and uses
Math.random()when (re)targeting.