Function
withChannelValue
(channel: ColorChannel, value: number)
Source from the content-addressed store, hash-verified
| 110 | } |
| 111 | |
| 112 | withChannelValue(channel: ColorChannel, value: number): IColor { |
| 113 | if (channel in this) { |
| 114 | let x = this.clone(); |
| 115 | x[channel] = value; |
| 116 | return x; |
| 117 | } |
| 118 | |
| 119 | throw new Error('Unsupported color channel: ' + channel); |
| 120 | } |
| 121 | |
| 122 | getChannelName(channel: ColorChannel, locale: string) { |
| 123 | let strings = |
Callers
nothing calls this directly
Tested by
no test coverage detected