Releases: aminekun90/advanced-color-utils
v1.0.7
Full Changelog: v1.0.6...v1.0.7
v1.0.6
Update 1.0.6
⚡ Refactor
Consolidated color conversion and generation functions.
Fixed inconsistencies between HSL, RGB, and HEX conversions.
Updated hexToHsl to return h: 0-360, s: 0-100, l: 0-100 for standard HSL representation.
Updated hslToHex and hslToRgb to match standard HSL math and avoid inversion errors.
🎨 Color Generation Fixes
-
generateMonochromaticColors
-
Correctly produces a palette with decreasing lightness from base color.
-
First color in the palette is always the base color.
-
Handles edge cases with numColors = 1 or 0.
-
generateTriadicColors
-
Fixed the triadic calculation to match standard color wheel: base hue +120° and +240°.
-
generateComplementaryPalette and generateComplementaryColor
-
Correctly calculates complementary colors based on HSL hue rotation.
🧪 Unit Test Alignment
-
Updated tests to match standard HSL math.
-
All HSL-to-HEX and HEX-to-HSL tests now use 0–100% for s and l.
-
generateMonochromaticColors tests now validate proper lightness interpolation.
-
Triadic color tests corrected to match standard triadic hues.
🛠 Misc
-
Removed duplicate or conflicting functions (getComplementaryColor vs generateComplementaryColor).
-
Ensured all public static functions use chroma-js internally consistently.
-
Added handling for edge cases (white/black colors in complementary generation).
v1.0.5
feat : version 1.0.5
v1.0.4
Merge pull request #2 from aminekun90/dev Update v1.0.4
v1.0.3
feat: Update v1.2.3
v1.0.2
feat: rename name package json
v1.0.1
feat: update package.json definitions
v1.0.0
add package-lock