{"action":"created","issue":{"url":"https://api.github.com/repos/TeamWertarbyte/material-ui-chip-input/issues/52","repository_url":"https://api.github.com/repos/TeamWertarbyte/material-ui-chip-input","labels_url":"https://api.github.com/repos/TeamWertarbyte/material-ui-chip-input/issues/52/labels{/name}","comments_url":"https://api.github.com/repos/TeamWertarbyte/material-ui-chip-input/issues/52/comments","events_url":"https://api.github.com/repos/TeamWertarbyte/material-ui-chip-input/issues/52/events","html_url":"https://github.com/TeamWertarbyte/material-ui-chip-input/issues/52","id":193896371,"number":52,"title":"Inconsistent argumentt for onRequestDelete callback","user":{"login":"leMaik","id":5544859,"avatar_url":"https://avatars1.githubusercontent.com/u/5544859?v=3","gravatar_id":"","url":"https://api.github.com/users/leMaik","html_url":"https://github.com/leMaik","followers_url":"https://api.github.com/users/leMaik/followers","following_url":"https://api.github.com/users/leMaik/following{/other_user}","gists_url":"https://api.github.com/users/leMaik/gists{/gist_id}","starred_url":"https://api.github.com/users/leMaik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leMaik/subscriptions","organizations_url":"https://api.github.com/users/leMaik/orgs","repos_url":"https://api.github.com/users/leMaik/repos","events_url":"https://api.github.com/users/leMaik/events{/privacy}","received_events_url":"https://api.github.com/users/leMaik/received_events","type":"User","site_admin":false},"labels":[{"id":438408698,"url":"https://api.github.com/repos/TeamWertarbyte/material-ui-chip-input/labels/bug","name":"bug","color":"ee0701","default":true}],"state":"closed","locked":false,"assignee":{"login":"leMaik","id":5544859,"avatar_url":"https://avatars1.githubusercontent.com/u/5544859?v=3","gravatar_id":"","url":"https://api.github.com/users/leMaik","html_url":"https://github.com/leMaik","followers_url":"https://api.github.com/users/leMaik/followers","following_url":"https://api.github.com/users/leMaik/following{/other_user}","gists_url":"https://api.github.com/users/leMaik/gists{/gist_id}","starred_url":"https://api.github.com/users/leMaik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leMaik/subscriptions","organizations_url":"https://api.github.com/users/leMaik/orgs","repos_url":"https://api.github.com/users/leMaik/repos","events_url":"https://api.github.com/users/leMaik/events{/privacy}","received_events_url":"https://api.github.com/users/leMaik/received_events","type":"User","site_admin":false},"assignees":[{"login":"leMaik","id":5544859,"avatar_url":"https://avatars1.githubusercontent.com/u/5544859?v=3","gravatar_id":"","url":"https://api.github.com/users/leMaik","html_url":"https://github.com/leMaik","followers_url":"https://api.github.com/users/leMaik/followers","following_url":"https://api.github.com/users/leMaik/following{/other_user}","gists_url":"https://api.github.com/users/leMaik/gists{/gist_id}","starred_url":"https://api.github.com/users/leMaik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leMaik/subscriptions","organizations_url":"https://api.github.com/users/leMaik/orgs","repos_url":"https://api.github.com/users/leMaik/repos","events_url":"https://api.github.com/users/leMaik/events{/privacy}","received_events_url":"https://api.github.com/users/leMaik/received_events","type":"User","site_admin":false}],"milestone":null,"comments":1,"created_at":"2016-12-06T21:55:13Z","updated_at":"2017-05-12T14:30:02Z","closed_at":"2016-12-12T22:52:22Z","body":"Originally reported by @Vishal0203 in #51.\r\n\r\n```\r\n       <ChipInput\r\n              value={this.state.tags}\r\n              onRequestAdd={(tag) => this.handleTagAdd(tag)}\r\n              onRequestDelete={(deletedTag) => this.handleTagDelete(deletedTag)}\r\n              dataSource={{name: 'Something', tag_guid: '123-567'}}\r\n              dataSourceConfig={[{text: 'name', value: 'tag_guid'}]}\r\n              hintText=\"Add tags to your question for easy visibility.\"\r\n              openOnFocus={true}\r\n              fullWidth\r\n              chipRenderer={({ text, value, isFocused, isDisabled, handleClick, handleRequestDelete }, key) => (\r\n                <Chip\r\n                  key={key}\r\n                  className=\"chip\"\r\n                  labelStyle={this.styles.chipLabel}\r\n                  onTouchTap={handleClick}\r\n                  onRequestDelete={handleRequestDelete}\r\n                >\r\n                  {text}\r\n                </Chip>\r\n              )}\r\n            />\r\n```\r\n\r\nand my `handleRequestDelete` is as follows\r\n\r\n```\r\nthis.setState({\r\n        tags: this.state.tags.filter((c) => c !== deletedTag)\r\n      })\r\n```\r\n\r\nFor backspace, `deleteTag` receives `{name: 'Something', tag_guid: '123-567'}` but on clicking \r\n`x`,  `deleteTag` receives `123-567` (and hence doesn't remove the tag unless I explicitly handle this condition)"},"comment":{"url":"https://api.github.com/repos/TeamWertarbyte/material-ui-chip-input/issues/comments/301092427","html_url":"https://github.com/TeamWertarbyte/material-ui-chip-input/issues/52#issuecomment-301092427","issue_url":"https://api.github.com/repos/TeamWertarbyte/material-ui-chip-input/issues/52","id":301092427,"user":{"login":"leMaik","id":5544859,"avatar_url":"https://avatars1.githubusercontent.com/u/5544859?v=3","gravatar_id":"","url":"https://api.github.com/users/leMaik","html_url":"https://github.com/leMaik","followers_url":"https://api.github.com/users/leMaik/followers","following_url":"https://api.github.com/users/leMaik/following{/other_user}","gists_url":"https://api.github.com/users/leMaik/gists{/gist_id}","starred_url":"https://api.github.com/users/leMaik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leMaik/subscriptions","organizations_url":"https://api.github.com/users/leMaik/orgs","repos_url":"https://api.github.com/users/leMaik/repos","events_url":"https://api.github.com/users/leMaik/events{/privacy}","received_events_url":"https://api.github.com/users/leMaik/received_events","type":"User","site_admin":false},"created_at":"2017-05-12T14:30:02Z","updated_at":"2017-05-12T14:30:02Z","body":"It _was_ fixed, but in the other way: `onRequestDelete` no _always_ gets called with the value (which is either the string or the `value` property when using `dataSourceConfig`."}}
{"actor":{"display_login":"leMaik"}}