Skip to content
This repository has been archived by the owner on Sep 20, 2019. It is now read-only.

markers / label drawing on the screen #329

Open
vvavepacket opened this issue Feb 4, 2017 · 1 comment
Open

markers / label drawing on the screen #329

vvavepacket opened this issue Feb 4, 2017 · 1 comment

Comments

@vvavepacket
Copy link

vvavepacket commented Feb 4, 2017

Let's say we have a marker with label. Where in the code can we modify it in such a way, we can add css properties just before they are rendered on screen? Basically, when the markers and label are rendered in screen, they should have already the custom css properties in them... As of now, I can add css properties after they are loaded,, but I want to do it before,, so that user's will see the change immediately. Any best approches/best practice? Thank you.

@BAByrne
Copy link

BAByrne commented Feb 16, 2017

There's an "options" property for labels, where you can use "className" define the css class to add to the label element. Is that what you're looking for?

markers: {
  main_marker: {
    lat: 0,
    lng: 0,
    focus: true,
    title: "Marker",
    draggable: true,
    label: {
      message: "I'm a label",
      options: {
        className: "my-class-name"
      }
    }
  }
}

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants