{"action":"closed","issue":{"url":"https://api.github.com/repos/sconsult/croppic/issues/158","labels_url":"https://api.github.com/repos/sconsult/croppic/issues/158/labels{/name}","comments_url":"https://api.github.com/repos/sconsult/croppic/issues/158/comments","events_url":"https://api.github.com/repos/sconsult/croppic/issues/158/events","html_url":"https://github.com/sconsult/croppic/issues/158","id":103625056,"number":158,"title":"Set initial zoom as variable","user":{"login":"EricDu","id":3483810,"avatar_url":"https://avatars.githubusercontent.com/u/3483810?v=3","gravatar_id":"","url":"https://api.github.com/users/EricDu","html_url":"https://github.com/EricDu","followers_url":"https://api.github.com/users/EricDu/followers","following_url":"https://api.github.com/users/EricDu/following{/other_user}","gists_url":"https://api.github.com/users/EricDu/gists{/gist_id}","starred_url":"https://api.github.com/users/EricDu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/EricDu/subscriptions","organizations_url":"https://api.github.com/users/EricDu/orgs","repos_url":"https://api.github.com/users/EricDu/repos","events_url":"https://api.github.com/users/EricDu/events{/privacy}","received_events_url":"https://api.github.com/users/EricDu/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/sconsult/croppic/labels/enhancement","name":"enhancement","color":"84b6eb"},{"url":"https://api.github.com/repos/sconsult/croppic/labels/feature","name":"feature","color":"009800"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-08-28T01:04:55Z","updated_at":"2015-10-01T11:57:50Z","closed_at":"2015-10-01T11:57:50Z","body":"When I upload an image to Croppic, it's always a little bigger than the container. After looking through the parameters, I couldn't find a way to \"fix\" it so that it would fill the container exactly. After looking at the code, I found **that.zoom(40);** in the initialScaleImg function. Changing the value to **that.zoom(0);** solved my problem.\r\n\r\nI suggest adding initialZoom as an option, defaulting to a value of 40 for backwards compatibility, but that can be overwritten on initialization like zoomFactor. In my case, adding **initialZoom:0** to the parameters."}}