{"action":"created","issue":{"url":"https://api.github.com/repos/dubert/react-kronos/issues/44","repository_url":"https://api.github.com/repos/dubert/react-kronos","labels_url":"https://api.github.com/repos/dubert/react-kronos/issues/44/labels{/name}","comments_url":"https://api.github.com/repos/dubert/react-kronos/issues/44/comments","events_url":"https://api.github.com/repos/dubert/react-kronos/issues/44/events","html_url":"https://github.com/dubert/react-kronos/issues/44","id":176040521,"number":44,"title":"Expose validation result in `onSelect`","user":{"login":"KCraw","id":8075821,"avatar_url":"https://avatars.githubusercontent.com/u/8075821?v=3","gravatar_id":"","url":"https://api.github.com/users/KCraw","html_url":"https://github.com/KCraw","followers_url":"https://api.github.com/users/KCraw/followers","following_url":"https://api.github.com/users/KCraw/following{/other_user}","gists_url":"https://api.github.com/users/KCraw/gists{/gist_id}","starred_url":"https://api.github.com/users/KCraw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/KCraw/subscriptions","organizations_url":"https://api.github.com/users/KCraw/orgs","repos_url":"https://api.github.com/users/KCraw/repos","events_url":"https://api.github.com/users/KCraw/events{/privacy}","received_events_url":"https://api.github.com/users/KCraw/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-09-09T15:40:08Z","updated_at":"2016-09-15T20:18:17Z","closed_at":null,"body":"When controlling visibility, there is currently no way to know whether validation succeeded or failed when `props.onSelect` is called.\r\n\r\nThe internal `onSelect` uses toggles state.visible; however, if you have enabled `controlVisibility`, this will be out of sync with the actual visibility. \r\n\r\nThe `props.onSelect` callback should set the appropriate visibility, but it would be nice to know whether the validation succeeded or not. \r\n\r\n"},"comment":{"url":"https://api.github.com/repos/dubert/react-kronos/issues/comments/247441757","html_url":"https://github.com/dubert/react-kronos/issues/44#issuecomment-247441757","issue_url":"https://api.github.com/repos/dubert/react-kronos/issues/44","id":247441757,"user":{"login":"KCraw","id":8075821,"avatar_url":"https://avatars.githubusercontent.com/u/8075821?v=3","gravatar_id":"","url":"https://api.github.com/users/KCraw","html_url":"https://github.com/KCraw","followers_url":"https://api.github.com/users/KCraw/followers","following_url":"https://api.github.com/users/KCraw/following{/other_user}","gists_url":"https://api.github.com/users/KCraw/gists{/gist_id}","starred_url":"https://api.github.com/users/KCraw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/KCraw/subscriptions","organizations_url":"https://api.github.com/users/KCraw/orgs","repos_url":"https://api.github.com/users/KCraw/repos","events_url":"https://api.github.com/users/KCraw/events{/privacy}","received_events_url":"https://api.github.com/users/KCraw/received_events","type":"User","site_admin":false},"created_at":"2016-09-15T20:18:17Z","updated_at":"2016-09-15T20:18:17Z","body":"Yeah, that would be great. That way we can follow similar logic to the\ndefault of not closing the input if it was somehow invalid. Thanks!\n\nOn Thu, Sep 15, 2016 at 12:35 PM, Luke Dubert <notifications@github.com>\nwrote:\n\n> Would you like for this to be a parameter in the callback? For example\n> change: https://github.com/dubert/react-kronos/blob/master/src/\n> index.js#L342\n>\n> to:\n>\n> if (this.props.onSelect) this.props.onSelect(datetime, willBeVisible, didValidate)\n>\n> (and obviously define the didValidate variable)\n>\n> —\n> You are receiving this because you authored the thread.\n> Reply to this email directly, view it on GitHub\n> <https://github.com/dubert/react-kronos/issues/44#issuecomment-247396932>,\n> or mute the thread\n> <https://github.com/notifications/unsubscribe-auth/AHs6LVuYe6fQzwDGYqLUQ4XjzbqX3Mltks5qqYHpgaJpZM4J5Lk3>\n> .\n>\n"}}
{"actor":{"display_login":"KCraw"}}