{"action":"closed","issue":{"url":"https://api.github.com/repos/nolimits4web/Swiper/issues/1062","labels_url":"https://api.github.com/repos/nolimits4web/Swiper/issues/1062/labels{/name}","comments_url":"https://api.github.com/repos/nolimits4web/Swiper/issues/1062/comments","events_url":"https://api.github.com/repos/nolimits4web/Swiper/issues/1062/events","html_url":"https://github.com/nolimits4web/Swiper/issues/1062","id":55119544,"number":1062,"title":"Swiper doesn't take box-sizing into account","user":{"login":"pyrokinetiq","id":621277,"avatar_url":"https://avatars.githubusercontent.com/u/621277?v=3","gravatar_id":"","url":"https://api.github.com/users/pyrokinetiq","html_url":"https://github.com/pyrokinetiq","followers_url":"https://api.github.com/users/pyrokinetiq/followers","following_url":"https://api.github.com/users/pyrokinetiq/following{/other_user}","gists_url":"https://api.github.com/users/pyrokinetiq/gists{/gist_id}","starred_url":"https://api.github.com/users/pyrokinetiq/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pyrokinetiq/subscriptions","organizations_url":"https://api.github.com/users/pyrokinetiq/orgs","repos_url":"https://api.github.com/users/pyrokinetiq/repos","events_url":"https://api.github.com/users/pyrokinetiq/events{/privacy}","received_events_url":"https://api.github.com/users/pyrokinetiq/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-01-22T06:33:03Z","updated_at":"2015-01-25T19:27:53Z","closed_at":"2015-01-25T19:27:53Z","body":"When calculating offsets for slides, Swiper should ignore padding when the element has a `box-sizing` value of `border-box`.\r\n\r\nCurrently if I have a box with:\r\n```css\r\n.swiper-slide {\r\n    width: 300px;\r\n    padding: 15px;\r\n    box-sizing: border-box;\r\n}\r\n```\r\n\r\nWhen sliding to slide 2, there is a negative offset of `-330px` which would usually be correct, however `box-sizing: border-box;` means the padding does not contribute to the total box width, the padding pushes inwards instead.\r\n\r\nSo given the aforementioned styles, the negative offset should be `-300px` per box. i.e. Swiper needs to ignore padding in calculating offsets on slides with `box-sizing: border-box;`"}}