{"action":"created","issue":{"url":"https://api.github.com/repos/callemall/material-ui/issues/2361","labels_url":"https://api.github.com/repos/callemall/material-ui/issues/2361/labels{/name}","comments_url":"https://api.github.com/repos/callemall/material-ui/issues/2361/comments","events_url":"https://api.github.com/repos/callemall/material-ui/issues/2361/events","html_url":"https://github.com/callemall/material-ui/pull/2361","id":120189402,"number":2361,"title":"Prevent CardActions from overriding child.style","user":{"login":"XiaonuoGantan","id":1310387,"avatar_url":"https://avatars.githubusercontent.com/u/1310387?v=3","gravatar_id":"","url":"https://api.github.com/users/XiaonuoGantan","html_url":"https://github.com/XiaonuoGantan","followers_url":"https://api.github.com/users/XiaonuoGantan/followers","following_url":"https://api.github.com/users/XiaonuoGantan/following{/other_user}","gists_url":"https://api.github.com/users/XiaonuoGantan/gists{/gist_id}","starred_url":"https://api.github.com/users/XiaonuoGantan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/XiaonuoGantan/subscriptions","organizations_url":"https://api.github.com/users/XiaonuoGantan/orgs","repos_url":"https://api.github.com/users/XiaonuoGantan/repos","events_url":"https://api.github.com/users/XiaonuoGantan/events{/privacy}","received_events_url":"https://api.github.com/users/XiaonuoGantan/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/callemall/material-ui/labels/Review:%20needs-revision","name":"Review: needs-revision","color":"e11d21"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-12-03T14:57:37Z","updated_at":"2015-12-03T17:10:59Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/callemall/material-ui/pulls/2361","html_url":"https://github.com/callemall/material-ui/pull/2361","diff_url":"https://github.com/callemall/material-ui/pull/2361.diff","patch_url":"https://github.com/callemall/material-ui/pull/2361.patch"},"body":"Suppose we have the following JSX:\r\n\r\n```\r\n<CardActions>\r\n  <IconButton style={{ margin: '0 auto', display: 'inherit' }} ... />\r\n</CardActions>\r\n```\r\n\r\nThe current `CardActions` component's `React.cloneElement(child, { style: {marginRight: 8} })`\r\nwill return a list of children whose `style` property gets overridden by the `React.cloneElement`\r\ncalls. The end result is an JSX in the following way:\r\n\r\n```\r\n<CardActions>\r\n  <IconButton style={{ marginRight: 8 }} ... />\r\n</CardActions>\r\n```\r\n\r\nThis commit will change CardActions' behaviour to always return the list of children as-is\r\nif some of them have already specified the property `style`."},"comment":{"url":"https://api.github.com/repos/callemall/material-ui/issues/comments/161719023","html_url":"https://github.com/callemall/material-ui/pull/2361#issuecomment-161719023","issue_url":"https://api.github.com/repos/callemall/material-ui/issues/2361","id":161719023,"user":{"login":"XiaonuoGantan","id":1310387,"avatar_url":"https://avatars.githubusercontent.com/u/1310387?v=3","gravatar_id":"","url":"https://api.github.com/users/XiaonuoGantan","html_url":"https://github.com/XiaonuoGantan","followers_url":"https://api.github.com/users/XiaonuoGantan/followers","following_url":"https://api.github.com/users/XiaonuoGantan/following{/other_user}","gists_url":"https://api.github.com/users/XiaonuoGantan/gists{/gist_id}","starred_url":"https://api.github.com/users/XiaonuoGantan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/XiaonuoGantan/subscriptions","organizations_url":"https://api.github.com/users/XiaonuoGantan/orgs","repos_url":"https://api.github.com/users/XiaonuoGantan/repos","events_url":"https://api.github.com/users/XiaonuoGantan/events{/privacy}","received_events_url":"https://api.github.com/users/XiaonuoGantan/received_events","type":"User","site_admin":false},"created_at":"2015-12-03T17:10:59Z","updated_at":"2015-12-03T17:10:59Z","body":"Absolutely. I have just squashed all my commits into one and pushed this commit."}}