map
map copied to clipboard
Circle directive breaks circle svg tag, need to NS your directives
IMPORTANT
ERROR Error: StaticInjectorError(AppModule)[Circle -> NguiMapComponent]: StaticInjectorError(Platform: core)[Circle -> NguiMapComponent]: NullInjectorError: No provider for NguiMapComponent!
Steps to reproduce and a minimal demo demo
- just add a circle-svg element somewhere (even used namespacing i.e.
svg:circle)
Current behavior
- the map doesnt get rendered because the circle-element throws an error
Expected/desired behavior
- no error whatsoever
Other information
- #243
Any workaround for this issue? Mine was using NgNonBindable directive in the svg element, but it won't allow you to bind data to any child element.
It also happens with polygon tag
Please use ngNonBindable
<ngui-map zoom="5" center="24.886, -70.268" scrollwheel="false">
<map-polygon [editable]="true"
[paths]="paths"
[strokeColor]="'#FFC107'"
[strokeOpacity]="0.8"
[strokeWeight]="2"
[fillColor]="'#FFC107'"
[fillOpacity]="0.35"></map-polygon>
</ngui-map>
<svg ngNonBindable viewBox="0 0 100 100" xmlns="http://www.w3.org/2000/svg">
<circle cx="50" cy="50" r="10"/>
</svg>