{"id":18705207,"url":"https://github.com/hsluv/hsluv-go","last_synced_at":"2025-04-12T10:07:04.395Z","repository":{"id":57484398,"uuid":"49813760","full_name":"hsluv/hsluv-go","owner":"hsluv","description":"Go implementation of HSLuv (revision 4) ","archived":false,"fork":false,"pushed_at":"2023-05-03T00:15:30.000Z","size":1019,"stargazers_count":31,"open_issues_count":0,"forks_count":2,"subscribers_count":6,"default_branch":"master","last_synced_at":"2025-04-12T10:05:00.661Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/hsluv.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-01-17T11:02:46.000Z","updated_at":"2025-04-08T02:50:13.000Z","dependencies_parsed_at":"2024-06-18T23:10:23.776Z","dependency_job_id":null,"html_url":"https://github.com/hsluv/hsluv-go","commit_stats":null,"previous_names":["husl-colors/husl-go"],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hsluv%2Fhsluv-go","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hsluv%2Fhsluv-go/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hsluv%2Fhsluv-go/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hsluv%2Fhsluv-go/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hsluv","download_url":"https://codeload.github.com/hsluv/hsluv-go/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248550634,"owners_count":21122933,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-07T12:10:02.026Z","updated_at":"2025-04-12T10:07:04.375Z","avatar_url":"https://github.com/hsluv.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![Build Status](https://github.com/hsluv/hsluv-go/actions/workflows/test.yml/badge.svg)](https://github.com/hsluv/hsluv-go/actions/workflows/test.yml)\n\nGo port of HSLuv (revision 4), written by [Michael Glanznig](https://github.com/nebulon42)\n\nMore details about HSLuv at http://www.hsluv.org.\n\n# API\n\n**hsluv.HsluvToHex(hue, saturation, lightness)**\n\n*hue* is a number between 0 and 360, *saturation* and *lightness* are numbers between 0 and 100. This function returns the resulting color as a hex string.\n\n**hsluv.HsluvlToRGB(hue, saturation, lightness)**\n\nLike above, but returns 3 numbers between 0 and 1, for the r, g, and b channel.\n\n**hsluv.HsluvFromHex(hex)**\n\nTakes a hex string and returns the HSLuv color as 3 numbers for hue (0-360), saturation (0-100) and lightness (0-100).\n_Note_: The result can have rounding errors. For example saturation can be 100.00000000000007\n\n**hsluv.HsluvFromRGB(red, green, blue)**\n\nLike above, but *red*, *green* and *blue* are passed as numbers between 0 and 1.\n\nUse **HpluvToHex**, **HpluvToRGB**, **HpluvFromHex** and **HpluvFromRGB** for the pastel variant (HPLuv).\n\n# Testing\n\nRun `go test`.\n\n# Thanks\n\nTesting was inspired by [omniscale/magnacarto](https://github.com/omniscale/magnacarto).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhsluv%2Fhsluv-go","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhsluv%2Fhsluv-go","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhsluv%2Fhsluv-go/lists"}