Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

196
Views
Adapt width of leaflet popup using Vue2Leaflet's l-popup component

I am programming a web application and using leaflet to display a map. I defined markers and popups which appear upon click on the respective markers.

Unfortunately the popups look weird at the moment (the height is too large and the width too small). For this reason I am trying adapt the width of the popups.

I saw in the Vue2Leaflet documentation (https://vue2-leaflet.netlify.app/components/LPopup.html) that I can pass an options prop to the l-popup component. So I tried the following:

<l-popup :options="{ width: 600 }" id="popup"></l-popup>

But it did not work. How do I pass the width options correctly, so that the width of the popup changes? Or am I on a completely wrong path? If yes, how can I modify the width of the l-popup component?

Thanks for any help!

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

I just had the same issue. Finally, I didn't use the options in but used CSS instead.

Example:

<l-popup class="map-popup"></l-popup>

and then simply styled my element in CSS:

.map-popup {
    min-width: 600px;
}
about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!