Skip to content
This repository has been archived by the owner on Jan 24, 2023. It is now read-only.

Feature Request: Group Directive #6

Open
elvirusHDS opened this issue Oct 30, 2018 · 1 comment
Open

Feature Request: Group Directive #6

elvirusHDS opened this issue Oct 30, 2018 · 1 comment

Comments

@elvirusHDS
Copy link

Hello guys,

what do you think? Is it a huge effort to include Groups as a directive into the lib? I tried to figure out, what shall be done to have this functionality but to be honest, I am a little bit lost here.
I am using groups (see https://developer.here.com/documentation/maps/topics_api/h-map-group.html) in my application to group markers and perform actions on them easily but this means that I have to sacrifice the marker directives and create all markers per code. So, sadly, I am losing data binding with my collections and I have to do everything by code.

Looking forward to hear your opinions on that!

Best regards,
elvirus

@mjaric
Copy link
Owner

mjaric commented Oct 30, 2018

Nope, there is no Marker sacrifice. Your GroupDirective should act as MapComponent (as other objects container) plus as any other map object to which map is assigned to. While it queries for children of type MarkerDirective (or maybe better as any map object) it should wait for map assignment.

So, implement it as any other BaseMapComponent and on its AfterContentInit, hook to this.proxy promise and pass callback to then function that should set mapComponent to group "queried" children. MapComponent will be assigned once MapComponent content is initialized then this.proxy will be resolved.

I guess there is some more work to do here for z-index etc. but that should be it in nutshell

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

No branches or pull requests

2 participants