MCPcopy Create free account
hub / github.com/bytebase/bytebase / channelToByte

Function channelToByte

frontend/src/utils/css.ts:37–38  ·  view source on GitHub ↗
(channel: number)

Source from the content-addressed store, hash-verified

35};
36
37const channelToByte = (channel: number): number =>
38 Math.max(0, Math.min(255, Math.round(channel * 255)));
39
40export const colorToHex = (color: Color): string =>
41 rgbToHex(

Callers 1

colorToHexFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected