Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prevent skewing on selected edit marker #341

Merged

Conversation

kyletolle
Copy link
Contributor

Using box-sizing: border-box; is a fairly common pattern these days. Specifically, projects like Bootstrap and Mapbox.js specifically set box-sizing: border-box;, which results in the marker being skewed when incorporating them and Leaflet.draw into your project. It would be best to protect against skewed draggable markers by explicitly setting box-sizing: content-box;.

Skewed selected edit marker:
screenshot 2014-11-26 13 28 00

Corrected selected edit marker:
screenshot 2014-11-26 13 28 55

Explicitly set box-sizing to prevent the selected edit marker from
being skewed when using other common libraries.
@kyletolle
Copy link
Contributor Author

Thanks @JasonSanford for the assistance with this topic.

This is my first PR for Leaflet, so please let me know if there's something I've missed.

@jacobtoye
Copy link
Member

Sorry for not accepting this earlier I missed it!

jacobtoye added a commit that referenced this pull request Jan 24, 2015
…ected

Prevent skewing on selected edit marker
@jacobtoye jacobtoye merged commit e5f153c into Leaflet:master Jan 24, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants