{"action":"created","issue":{"url":"https://api.github.com/repos/adobe-photoshop/spaces-design/issues/3006","labels_url":"https://api.github.com/repos/adobe-photoshop/spaces-design/issues/3006/labels{/name}","comments_url":"https://api.github.com/repos/adobe-photoshop/spaces-design/issues/3006/comments","events_url":"https://api.github.com/repos/adobe-photoshop/spaces-design/issues/3006/events","html_url":"https://github.com/adobe-photoshop/spaces-design/pull/3006","id":112045179,"number":3006,"title":"Add missing onChange prop to ColorPicker","user":{"login":"iwehrman","id":1075154,"avatar_url":"https://avatars.githubusercontent.com/u/1075154?v=3","gravatar_id":"","url":"https://api.github.com/users/iwehrman","html_url":"https://github.com/iwehrman","followers_url":"https://api.github.com/users/iwehrman/followers","following_url":"https://api.github.com/users/iwehrman/following{/other_user}","gists_url":"https://api.github.com/users/iwehrman/gists{/gist_id}","starred_url":"https://api.github.com/users/iwehrman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/iwehrman/subscriptions","organizations_url":"https://api.github.com/users/iwehrman/orgs","repos_url":"https://api.github.com/users/iwehrman/repos","events_url":"https://api.github.com/users/iwehrman/events{/privacy}","received_events_url":"https://api.github.com/users/iwehrman/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-10-18T22:11:47Z","updated_at":"2015-10-20T17:35:55Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/adobe-photoshop/spaces-design/pulls/3006","html_url":"https://github.com/adobe-photoshop/spaces-design/pull/3006","diff_url":"https://github.com/adobe-photoshop/spaces-design/pull/3006.diff","patch_url":"https://github.com/adobe-photoshop/spaces-design/pull/3006.patch"},"body":"The `ColorInput` has three change event handlers:\r\n\r\n1. `onColorChange` for changes to the opaque (RGB) color;\r\n2. `onAlphaChange` for changes to the alpha (and not RGB) value;\r\n3. `onChange` for arbitrary color changes.\r\n\r\nThe latter wasn't correctly percolating from the `ColorInput` to the internal `ColorPicker` component, which prevented color changes in the picker's text input to not correctly propagate changes to the opacity. This fixes that.\r\n\r\nOne reason why this problem wasn't caught earlier is that the three handlers were not marked as required for either component, and the default value for `onChange` was the identity. To avoid this in teh future, all three handlers are now marked as required for both components.\r\n\r\nThese components have become fairly convoluted since moving the text input inside the picker itself. We should look into smoothing them out a bit after M3.\r\n\r\nAddresses #3003. "},"comment":{"url":"https://api.github.com/repos/adobe-photoshop/spaces-design/issues/comments/149642276","html_url":"https://github.com/adobe-photoshop/spaces-design/pull/3006#issuecomment-149642276","issue_url":"https://api.github.com/repos/adobe-photoshop/spaces-design/issues/3006","id":149642276,"user":{"login":"pineapplespatula","id":1008531,"avatar_url":"https://avatars.githubusercontent.com/u/1008531?v=3","gravatar_id":"","url":"https://api.github.com/users/pineapplespatula","html_url":"https://github.com/pineapplespatula","followers_url":"https://api.github.com/users/pineapplespatula/followers","following_url":"https://api.github.com/users/pineapplespatula/following{/other_user}","gists_url":"https://api.github.com/users/pineapplespatula/gists{/gist_id}","starred_url":"https://api.github.com/users/pineapplespatula/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pineapplespatula/subscriptions","organizations_url":"https://api.github.com/users/pineapplespatula/orgs","repos_url":"https://api.github.com/users/pineapplespatula/repos","events_url":"https://api.github.com/users/pineapplespatula/events{/privacy}","received_events_url":"https://api.github.com/users/pineapplespatula/received_events","type":"User","site_admin":false},"created_at":"2015-10-20T17:35:55Z","updated_at":"2015-10-20T17:35:55Z","body":"one question. otherwise looks great. "}}