{"id":21064631,"url":"https://github.com/capturecontext/palette","last_synced_at":"2025-03-14T01:32:28.028Z","repository":{"id":107401549,"uuid":"228273456","full_name":"CaptureContext/Palette","owner":"CaptureContext","description":"Static Factory of Generic Colors","archived":false,"fork":false,"pushed_at":"2021-10-18T15:48:03.000Z","size":100,"stargazers_count":3,"open_issues_count":1,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-03-10T07:52:46.638Z","etag":null,"topics":["color-palette","colors","generic","generics","ios","linux","osx","palette","pantone","swift","ui","ux","web"],"latest_commit_sha":null,"homepage":null,"language":"Swift","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/CaptureContext.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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":"2019-12-16T00:35:46.000Z","updated_at":"2023-05-12T16:57:08.000Z","dependencies_parsed_at":"2023-05-17T10:00:27.654Z","dependency_job_id":null,"html_url":"https://github.com/CaptureContext/Palette","commit_stats":null,"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CaptureContext%2FPalette","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CaptureContext%2FPalette/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CaptureContext%2FPalette/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CaptureContext%2FPalette/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/CaptureContext","download_url":"https://codeload.github.com/CaptureContext/Palette/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243507607,"owners_count":20301867,"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":["color-palette","colors","generic","generics","ios","linux","osx","palette","pantone","swift","ui","ux","web"],"created_at":"2024-11-19T17:50:32.962Z","updated_at":"2025-03-14T01:32:28.010Z","avatar_url":"https://github.com/CaptureContext.png","language":"Swift","readme":"\u003cp align=\"center\"\u003e\n  \u003cimg src=\"Assets/Palette-Logo-Pink.png\" width=100%/\u003e\n\u003c/p\u003e\n\n\u003cp\u003e    \n  \u003ca href=\"https://swift.org\"\u003e\n        \u003cimg src=\"https://img.shields.io/badge/Swift-5.3-orange.svg?logo=swift\" /\u003e\n    \u003c/a\u003e\n    \u003ca href=\"https://swift.org/package-manager\"\u003e\n        \u003cimg src=\"https://img.shields.io/badge/SwiftPM-Compatible-brightgreen.svg?style=flat\" alt=\"SwiftPM\" /\u003e\n    \u003c/a\u003e\n    \u003cimg src=\"https://img.shields.io/badge/Platforms-Mac \u0026 Linux-green.svg?style=flat\" alt=\"Mac \u0026 Linux\" /\u003e\n    \u003ca href=\"https://twitter.com/maximkrouk\"\u003e\n        \u003cimg src=\"https://img.shields.io/badge/twitter-@maximkrouk-blue.svg?logo=twitter\u0026style=social\" alt=\"Twitter: @maximkrouk\"/\u003e\n    \u003c/a\u003e\n\u003c/p\u003e\n\nPlatform agnostic static factory of [colors](https://github.com/MakeupStudio/GenericColor).\n\n## Usage\n\n```swift\nimport Palette\n```\n\n```swift\nlet color1 = Color\u003cRGB\u003e.pantone(.classicBlue()) // Pantone color of 2020\nlet color2 = Color\u003cRGB\u003e.web(.skyBlue()) // WebColor SkyBlue\nlet color3 = Color\u003cRGB\u003e.fuchsia // The same as magenta\nlet color4 = Color\u003cRGB\u003e.iOS(.systemRed())\nlet color5 = Color\u003cRGB\u003e.iOS(.systemRed(.light))\nlet color6 = Color\u003cRGB\u003e.iOS(.systemRed(.dark))\n```\n\nCompatibility with NSColor/UIColor:\n\n```swift\nfunc setTextColor(_ color: Color\u003cRGB\u003e, to label: UILabel) {\n    label.textColor = .init(color)\n}\n\nfunc getTextColor(from label: UILabel) -\u003e Color\u003cRGB\u003e {\n    label.textColor.genericRGB\n}\n```\n\n## Installation\n\nAdd the package to Your SwiftPM package dependencies:\n\n```swift\n.package(\n    url: \"https://github.com/MakeupStudio/Palette.git\", \n    from: \"4.0.0-beta.3.0\"\n)\n```\n\nthen add `Palette` dependency to your target.\n\n## Licence\n\nMIT\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcapturecontext%2Fpalette","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcapturecontext%2Fpalette","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcapturecontext%2Fpalette/lists"}