grinat / leaflet-simple-map-screenshoter

Leaflet plugin which take screenshot of map
MIT License
71 stars 19 forks source link

Some margin/border shows up in the screenshot #44

Closed berryhijwegen closed 1 year ago

berryhijwegen commented 1 year ago

With the following Leaflet map: image

I receive the following as output: image

Why does this happen?

berryhijwegen commented 1 year ago

This happened due to a border that tailwind assigned to every element on te page

jayli3n commented 1 year ago

This happened due to a border that tailwind assigned to every element on te page

@berryhijwegen Can you remember how you fixed it in the end? Im also using tailwind with the same problem...

jayli3n commented 1 year ago

Found the problem, tailwind sets a global border style to solid and width to 0, just override it before screenshot, and then set it back:

image

image

Would love to know if theres a proper fix within the package tho.