complimentHex function

List<String> complimentHex (
  1. num n,
  2. String hex
)

returns an length n array of hex strings. The 0th color is the same as the input hexString, while the others are colours corresponding to an eve turn around the colour wheel. If n is 3 for example, the two other colours would represent a 1/3 and 2/3 rotation of the colour wheel.

Implementation

List<String> complimentHex(num n, String hex) {
  var hsl = hex2hsl(hex);
  return complimentHsl(n, hsl).map(hsl2hex).toList();
}