{"action":"created","issue":{"url":"https://api.github.com/repos/xcatliu/mobi.css/issues/33","repository_url":"https://api.github.com/repos/xcatliu/mobi.css","labels_url":"https://api.github.com/repos/xcatliu/mobi.css/issues/33/labels{/name}","comments_url":"https://api.github.com/repos/xcatliu/mobi.css/issues/33/comments","events_url":"https://api.github.com/repos/xcatliu/mobi.css/issues/33/events","html_url":"https://github.com/xcatliu/mobi.css/pull/33","id":175433453,"number":33,"title":"Remove duplicate code","user":{"login":"pixcai","id":11440779,"avatar_url":"https://avatars.githubusercontent.com/u/11440779?v=3","gravatar_id":"","url":"https://api.github.com/users/pixcai","html_url":"https://github.com/pixcai","followers_url":"https://api.github.com/users/pixcai/followers","following_url":"https://api.github.com/users/pixcai/following{/other_user}","gists_url":"https://api.github.com/users/pixcai/gists{/gist_id}","starred_url":"https://api.github.com/users/pixcai/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pixcai/subscriptions","organizations_url":"https://api.github.com/users/pixcai/orgs","repos_url":"https://api.github.com/users/pixcai/repos","events_url":"https://api.github.com/users/pixcai/events{/privacy}","received_events_url":"https://api.github.com/users/pixcai/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":7,"created_at":"2016-09-07T07:38:13Z","updated_at":"2016-09-07T15:56:46Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/xcatliu/mobi.css/pulls/33","html_url":"https://github.com/xcatliu/mobi.css/pull/33","diff_url":"https://github.com/xcatliu/mobi.css/pull/33.diff","patch_url":"https://github.com/xcatliu/mobi.css/pull/33.patch"},"body":"貌似多余"},"comment":{"url":"https://api.github.com/repos/xcatliu/mobi.css/issues/comments/245328221","html_url":"https://github.com/xcatliu/mobi.css/pull/33#issuecomment-245328221","issue_url":"https://api.github.com/repos/xcatliu/mobi.css/issues/33","id":245328221,"user":{"login":"xcatliu","id":5453359,"avatar_url":"https://avatars.githubusercontent.com/u/5453359?v=3","gravatar_id":"","url":"https://api.github.com/users/xcatliu","html_url":"https://github.com/xcatliu","followers_url":"https://api.github.com/users/xcatliu/followers","following_url":"https://api.github.com/users/xcatliu/following{/other_user}","gists_url":"https://api.github.com/users/xcatliu/gists{/gist_id}","starred_url":"https://api.github.com/users/xcatliu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xcatliu/subscriptions","organizations_url":"https://api.github.com/users/xcatliu/orgs","repos_url":"https://api.github.com/users/xcatliu/repos","events_url":"https://api.github.com/users/xcatliu/events{/privacy}","received_events_url":"https://api.github.com/users/xcatliu/received_events","type":"User","site_admin":false},"created_at":"2016-09-07T15:56:46Z","updated_at":"2016-09-07T15:56:46Z","body":"嗯，你说的有道理。\r\n\r\n> Bootstrap之类的框架好像没有这样的做法吧？\r\n\r\n[Pure.css](http://purecss.io/forms/) 有 `.form` 但是内部的 `<button>` 还是需要 `class=\"btn\"`\r\n\r\n> 我认为比较好的做法是，只有改变元素的可视属性时（比如 `color`, `background`, `:hover` 等等），才需要添加额外的类。也就是说，`.form button`、`.form [type=radio]`这些只定义大小、位置和盒模型等属性，并不定义外观。\r\n\r\n你的意思是 `.form button` 定义大小和位置 `.btn` 定义外观？\r\n\r\n这样是有问题的，这样的话，在 `.form` 外部，就不能直接用 `.btn` 了（会失去大小和位置的 styles）。\r\n\r\n唯一的做法是直接去掉 `.form button` 的样式，按钮的样式都写到 `.btn` 中。\r\n\r\n我再考虑下，没问题的话下一版会改过来。\r\n\r\n多些建议！"}}
{"actor":{"display_login":"xcatliu"}}