{"id":1494,"url":"https://github.com/gkye/ComplimentaryGradientView","last_synced_at":"2025-08-02T04:31:39.631Z","repository":{"id":56906452,"uuid":"66331592","full_name":"gkye/ComplimentaryGradientView","owner":"gkye","description":"Create complementary gradients generated from dominant and prominent colors in supplied image. Inspired by Grade.js","archived":false,"fork":false,"pushed_at":"2019-08-09T02:53:42.000Z","size":30224,"stargazers_count":733,"open_issues_count":0,"forks_count":33,"subscribers_count":14,"default_branch":"master","last_synced_at":"2025-07-27T21:56:07.339Z","etag":null,"topics":["cocoapods","color","gradient","ios","swift"],"latest_commit_sha":null,"homepage":"","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/gkye.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}},"created_at":"2016-08-23T03:55:43.000Z","updated_at":"2025-07-16T15:42:30.000Z","dependencies_parsed_at":"2022-08-20T19:20:23.125Z","dependency_job_id":null,"html_url":"https://github.com/gkye/ComplimentaryGradientView","commit_stats":null,"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"purl":"pkg:github/gkye/ComplimentaryGradientView","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gkye%2FComplimentaryGradientView","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gkye%2FComplimentaryGradientView/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gkye%2FComplimentaryGradientView/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gkye%2FComplimentaryGradientView/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gkye","download_url":"https://codeload.github.com/gkye/ComplimentaryGradientView/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gkye%2FComplimentaryGradientView/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":268334612,"owners_count":24233793,"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","status":"online","status_checked_at":"2025-08-02T02:00:12.353Z","response_time":74,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["cocoapods","color","gradient","ios","swift"],"created_at":"2024-01-05T20:15:47.766Z","updated_at":"2025-08-02T04:31:38.311Z","avatar_url":"https://github.com/gkye.png","language":"Swift","readme":"[![codebeat badge](https://codebeat.co/badges/a41cd890-63e5-4738-9081-51af2bcfc4b8)](https://codebeat.co/projects/github-com-gkye-complimentarygradientview)\n\n# ComplimentaryGradientView\nCreate complementary gradients generated from dominant and prominent colors in supplied image.\nInspired by \u003ca href=\"https://github.com/benhowdle89/grade\"\u003e Grade.js \u003c/a\u003e:heart:\n\n\n`.all`\u003cbr\u003egradientStartPoint: `left`            |  `colors(start: .primary, end: .background)`\u003cbr\u003egradientStartPoint:`top`\n:-------------------------:|:-------------------------:\n![](https://cloud.githubusercontent.com/assets/14007152/17952751/733ba4ba-6a3b-11e6-9ae6-2b23d92b0dea.png)  |  ![](https://cloud.githubusercontent.com/assets/14007152/18399831/099a7c94-76a1-11e6-8362-e9504d33104f.png)\n\n`colors(start: .detail, end: .background)`\u003cbr\u003egradientStartPoint:`top`            |  \n`colors(start: .secondary, end: .background)`\u003cbr\u003egradientStartPoint:`bottom`\n:-------------------------:|:-------------------------:\n![](https://cloud.githubusercontent.com/assets/14007152/18399974/c8a7ba48-76a1-11e6-86e8-d1df76092855.png)  |  ![](https://cloud.githubusercontent.com/assets/14007152/18400039/23b266e0-76a2-11e6-819f-9d53f5376e54.png)\n\n\n## Demo\n#### Sorry for the poor quality gif \n![Demo](https://github.com/gkye/ComplimentaryGradientView/blob/master/Resources/demo.gif)\n\n\n## Usage\n\n### Code\n```swift\nlet gradientView = ComplimentaryGradientView(frame: CGRect(x: 0, y: 0, width: 300, height: 300))\n\n//Colors for gradient are derived from the provided image\ngradientView.image = UIImage(named: \"myImg\")\n\ngradientView.gradientTpye = .colors(start: .primary, end: .secondary)\n\n// Default = `.left`\ngradientView.gradientStartPoint = .left\n\n// Default = `.high`\ngradientView.quality = .high\n```\n\n### Storyboard\n![Demo](https://github.com/gkye/ComplimentaryGradientView/blob/master/Resources/storyboard_usage.png)\n\n### Migration [Guide](https://github.com/gkye/ComplimentaryGradientView/wiki/3.0-Migration-Guide).\nVersion 3.0 introduces `GradientVariant` and reduces `GradientType` to two simple options: \n``` swift\n// Create a gradient using all colors found in image\n case all \n // Create gradient using variants. ie. .colors(start: .primary, end: .detail) \n case colors(start: GradientVariant, end: GradientVariant) \n``` \n\n\n## Installation\n\n### CocoaPods\nComplimentaryGradientView is available through [CocoaPods](http://cocoapods.org). To install\nit, simply add the following line to your Podfile:\n\n### Swift 4.2\n```ruby\npod 'ComplimentaryGradientView', '~\u003e 3.0'\n\n```\n### Swift3.\n```ruby\npod 'ComplimentaryGradientView', '~\u003e 0.1.7'\n```\n\n### Swift 2.2\n```ruby\npod 'ComplimentaryGradientView', '~\u003e 0.1.0'\n```\n\n### Manually\nDownload and drop `ComplimentaryGradientView.xcodeproj` into your project\n\u003cb\u003eOR\u003c/b\u003e \nDrag `Source` folder into your project.\n\n## Dependencies\n\n\u003ca href=\"https://github.com/jathu/UIImageColors\" \u003e UIImageColors \u003ca/\u003e\n\n## License\n\nComplimentaryGradientView is available under the MIT license. See the LICENSE file for more info.\n\n\n","funding_links":[],"categories":["Media","ImageView","Swift","UI"],"sub_categories":["Image","Other free courses"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgkye%2FComplimentaryGradientView","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgkye%2FComplimentaryGradientView","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgkye%2FComplimentaryGradientView/lists"}