{"action":"created","issue":{"url":"https://api.github.com/repos/Collaborne/paper-collapse-item/issues/7","repository_url":"https://api.github.com/repos/Collaborne/paper-collapse-item","labels_url":"https://api.github.com/repos/Collaborne/paper-collapse-item/issues/7/labels{/name}","comments_url":"https://api.github.com/repos/Collaborne/paper-collapse-item/issues/7/comments","events_url":"https://api.github.com/repos/Collaborne/paper-collapse-item/issues/7/events","html_url":"https://github.com/Collaborne/paper-collapse-item/pull/7","id":175051581,"number":7,"title":"Added toggle event","user":{"login":"hyyan","id":4313420,"avatar_url":"https://avatars.githubusercontent.com/u/4313420?v=3","gravatar_id":"","url":"https://api.github.com/users/hyyan","html_url":"https://github.com/hyyan","followers_url":"https://api.github.com/users/hyyan/followers","following_url":"https://api.github.com/users/hyyan/following{/other_user}","gists_url":"https://api.github.com/users/hyyan/gists{/gist_id}","starred_url":"https://api.github.com/users/hyyan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hyyan/subscriptions","organizations_url":"https://api.github.com/users/hyyan/orgs","repos_url":"https://api.github.com/users/hyyan/repos","events_url":"https://api.github.com/users/hyyan/events{/privacy}","received_events_url":"https://api.github.com/users/hyyan/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-09-05T11:25:57Z","updated_at":"2016-09-05T12:23:16Z","closed_at":"2016-09-05T12:22:38Z","pull_request":{"url":"https://api.github.com/repos/Collaborne/paper-collapse-item/pulls/7","html_url":"https://github.com/Collaborne/paper-collapse-item/pull/7","diff_url":"https://github.com/Collaborne/paper-collapse-item/pull/7.diff","patch_url":"https://github.com/Collaborne/paper-collapse-item/pull/7.patch"},"body":"I have added the `toggle` event to listen to the element state\r\n\r\n```html\r\n<paper-collapse-item id=\"collapse1\" icon=\"editor:mode-comment\"  on-toggle=\"onToggleListener\">\r\n</paper-collapse-item>\r\n<paper-collapse-item id=\"collapse2\" icon=\"editor:mode-comment\"  on-toggle=\"onToggleListener\">\r\n</paper-collapse-item>\r\n<paper-collapse-item id=\"collapse3\" icon=\"editor:mode-comment\"  on-toggle=\"onToggleListener\">\r\n</paper-collapse-item>\r\n```\r\n```js\r\nPolymer({\r\n  is: 'my-element',\r\n  // close other paper-collapse-item (s)\r\n  onToggleListener: function(e) {\r\n    var items = this.querySelectorAll(\"paper-collapse-item\");\r\n    for(var x=0;x<items.length;x++){\r\n      if(items[x].id !== e.detail.id){\r\n          items[x].opened = false;\r\n      }\r\n    }\r\n  }\r\n\r\n});\r\n</script>\r\n```"},"comment":{"url":"https://api.github.com/repos/Collaborne/paper-collapse-item/issues/comments/244734498","html_url":"https://github.com/Collaborne/paper-collapse-item/pull/7#issuecomment-244734498","issue_url":"https://api.github.com/repos/Collaborne/paper-collapse-item/issues/7","id":244734498,"user":{"login":"hyyan","id":4313420,"avatar_url":"https://avatars.githubusercontent.com/u/4313420?v=3","gravatar_id":"","url":"https://api.github.com/users/hyyan","html_url":"https://github.com/hyyan","followers_url":"https://api.github.com/users/hyyan/followers","following_url":"https://api.github.com/users/hyyan/following{/other_user}","gists_url":"https://api.github.com/users/hyyan/gists{/gist_id}","starred_url":"https://api.github.com/users/hyyan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hyyan/subscriptions","organizations_url":"https://api.github.com/users/hyyan/orgs","repos_url":"https://api.github.com/users/hyyan/repos","events_url":"https://api.github.com/users/hyyan/events{/privacy}","received_events_url":"https://api.github.com/users/hyyan/received_events","type":"User","site_admin":false},"created_at":"2016-09-05T12:23:16Z","updated_at":"2016-09-05T12:23:16Z","body":"@ronnyroeller Thanks :)"}}
{"actor":{"display_login":"hyyan"}}