MCPcopy Create free account
hub / github.com/DavidHDev/react-bits / generateColor

Function generateColor

src/content/Animations/SplashCursor/SplashCursor.jsx:896–905  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

894 }
895
896 function generateColor() {
897 if (!config.RAINBOW_MODE) {
898 return hexToRGB(config.COLOR);
899 }
900 let c = HSVtoRGB(Math.random(), 1.0, 1.0);
901 c.r *= 0.15;
902 c.g *= 0.15;
903 c.b *= 0.15;
904 return c;
905 }
906
907 function HSVtoRGB(h, s, v) {
908 let r, g, b, i, f, p, q, t;

Callers 4

updateColorsFunction · 0.70
clickSplatFunction · 0.70
updatePointerDownDataFunction · 0.70
handleMouseMoveFunction · 0.70

Calls 2

hexToRGBFunction · 0.70
HSVtoRGBFunction · 0.70

Tested by

no test coverage detected