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

LIcon with null size within LMarker slot fails to nullify default size #694

Open
1 of 6 tasks
mryellow opened this issue Nov 16, 2021 · 14 comments
Open
1 of 6 tasks

Comments

@mryellow
Copy link

mryellow commented Nov 16, 2021

When providing an icon without a size within the default slot the icon property defaults to new Icon.Default() which has an iconSize of [12,12].

Steps to Reproduce

  <l-marker :lat-lng = "[-10, 10]">
    <l-icon :icon-size="null" :class-name="`leaflet-marker-icon`">
      <div :style="`width: 50px; height: 50px; background-color: #03f;`">Icon</div>
    </l-icon>
  </l-marker>

Expected Results

No forced sizing on marker.

Actual Results

The internal div will have the correct size, however...

Using DOM inspection tools, observe .leaflet-marker-icon wrapping this to have a size of 12x12

Browsers Affected

  • Chrome
  • Firefox
  • Edge
  • Safari 9
  • Safari 8
  • IE 11

Versions

  • Leaflet: v1.7.1
  • Vue: v2.6.14
  • Vue2Leaflet: v2.7.1
@stale
Copy link

stale bot commented Apr 16, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Apr 16, 2022
@mryellow
Copy link
Author

Bump. I'll cycle back someday.

@stale stale bot removed the wontfix label Apr 21, 2022
@stale
Copy link

stale bot commented Jun 23, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Jun 23, 2022
@mryellow
Copy link
Author

It's not stale until it's fixed and long since forgotten.

@stale stale bot removed the wontfix label Jun 23, 2022
@mikeu
Copy link
Contributor

mikeu commented Aug 11, 2022

Hi @mryellow , thank you for reporting this issue, and sorry for the lengthy delay in getting to it. Unfortunately, I don't think this is the right place to be trying to get it fixed. The behaviour you describe appears to be that of Leaflet itself.

Here are two identical maps, one made with Vue2Leaflet and the other with vanilla Leaflet.

As you can see, the rendered maps and map elements appear functionally identical, down to the 12x12 .leaflet-marker-icon div wrapping the larger div icon.

@mryellow
Copy link
Author

You're probably right. I remember it being buried deep and very interconnected.

Looking back seems the null gets passed all the way through, yes resulting in a default icon but also ending up with an iconSize which is falsy all the way to Leaflet itself.

@stale
Copy link

stale bot commented Oct 16, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Oct 16, 2022
@mryellow
Copy link
Author

mryellow commented Oct 16, 2022

Please go away stalebot.

Hang-ong wontfix on a "stale" issue, entirely inappropriate.

@stale stale bot removed wontfix labels Oct 16, 2022
@stale
Copy link

stale bot commented Jan 7, 2023

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Jan 7, 2023
@mryellow
Copy link
Author

mryellow commented Jan 7, 2023

@Stale Please just go away.

@stale stale bot removed the wontfix label Jan 7, 2023
@stale
Copy link

stale bot commented Mar 25, 2023

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Mar 25, 2023
@mryellow
Copy link
Author

Someone may wish to know about it stalebot.

@stale stale bot removed the wontfix label Mar 25, 2023
@stale
Copy link

stale bot commented Jun 18, 2023

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Jun 18, 2023
@mryellow
Copy link
Author

mryellow commented Jun 18, 2023

I still hate you stalebot.

undefined !== null

@stale stale bot removed the wontfix label Jun 18, 2023
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

No branches or pull requests

2 participants