{"id":18706166,"url":"https://github.com/bendc/color-picker","last_synced_at":"2025-04-12T10:20:51.591Z","repository":{"id":84104406,"uuid":"69275223","full_name":"bendc/color-picker","owner":"bendc","description":"Web component color picker","archived":false,"fork":false,"pushed_at":"2016-09-26T17:49:07.000Z","size":5,"stargazers_count":43,"open_issues_count":1,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-26T05:11:30.183Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://playground.deaxon.com/js/color-picker","language":"JavaScript","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/bendc.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","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-09-26T17:35:48.000Z","updated_at":"2025-02-26T03:31:12.000Z","dependencies_parsed_at":"2023-07-18T15:30:52.061Z","dependency_job_id":null,"html_url":"https://github.com/bendc/color-picker","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bendc%2Fcolor-picker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bendc%2Fcolor-picker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bendc%2Fcolor-picker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bendc%2Fcolor-picker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bendc","download_url":"https://codeload.github.com/bendc/color-picker/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248550623,"owners_count":21122934,"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:13:06.728Z","updated_at":"2025-04-12T10:20:51.580Z","avatar_url":"https://github.com/bendc.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Usage\n\nInsert the custom element and the library in your document:\n\n```html\n\u003c!doctype html\u003e\n\u003ctitle\u003eExample\u003c/title\u003e\n\n\u003ccolor-picker\u003e\u003c/color-picker\u003e\n\n\u003cscript src=color-picker.js\u003e\u003c/script\u003e\n```\n\nListen for the `color-change` event to get the selected color:\n\n```javascript\nconst picker = document.querySelector(\"color-picker\");\n\npicker.addEventListener(\"color-change\", () =\u003e {\n  const { state } = picker;\n  console.log(state); // =\u003e object containing the current rgb, hsb and hex values\n});\n```\n\nPlease note this component is based on the [Shadow DOM v1\nspec](http://w3c.github.io/webcomponents/spec/shadow/) which might require a\n[polyfill](https://github.com/webcomponents/shadydom) for older browsers.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbendc%2Fcolor-picker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbendc%2Fcolor-picker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbendc%2Fcolor-picker/lists"}