-
Notifications
You must be signed in to change notification settings - Fork 229
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
Enable LayerGroups #97
Comments
Hi @PeterC66 , I can add this component during this week, when I'll have time for this. |
Thanks, that is good to hear. I am in no hurry as I have lots of other things to work on in refactoring my system, and my skills are limited, so I am happy to wait for you to implement. I am enjoying working with vue.js and vuelayers, and finding out all that I can do with them. |
Layer group <vl-layer-group id="layer-group" :opacity="opacity" :visible="visible">
<vl-layer-tile id="wms">
<vl-source-wms url="https://ahocevar.com/geoserver/wms" layers="topp:states" :ext-params="{ TILED: true }" server-type="geoserver"/>
</vl-layer-tile>
<vl-layer-image id="wms-image">
<vl-source-image-wms url="https://ahocevar.com/geoserver/wms" layers="topp:states" server-type="geoserver"/>
</vl-layer-image>
<vl-layer-vector id="points" v-if="pointsLayer">
<vl-source-cluster>
<vl-source-vector :features="points"/>
</vl-source-cluster>
<vl-style-func :factory="clusterStyleFunc"></vl-style-func>
</vl-layer-vector>
</vl-layer-group> |
Can you add it to v0.11 for me to try it out? I have tried going back to 0.10 but had troubles with babel that I could not solve. Thanks. |
Yes, I'll add it |
Hi @PeterC66 , |
Thanks - that seems to work OK. I did have a small issue with BingMapsSource moving from v0.11.0-rc.3 to v0.11.0-rc.4 as I Vue.use() components separately. Once I changed it to BingmapsSource the problem was solved. ( I do have a more significant problem with loading vectors in the new rc version that I will raise as a separate issue.) Thanks again for all you are doing. |
I forget to mention breaking change of name of the Bing source. |
I seem to be having an issue with zIndex. I never bothered much with zindex when using plain OL, relying on the order of the layers array, but with Vue.js/vuelayers I seem to to need to set it. My app works OK now I now that. However the layer group seems to misbehave. I have set zindex for the GroupLayer, but when I look in devtools the layers that make up that group have zIndex undefined. Should I be setting zindex for each layer that makes up the layer group, or should OL or vuelayers do that for me? |
The OL |
Thanks. I am using a render function and setting the same z-index for each vl-layer-.. as the vl-layer-group, and it works OK. By the way I have realised that at least in this context I need to distinguish between attrs and props in the Data Object (createElement argument). I thought I had read somewhere that this was not necessary, but I need to be stricter in my mind in future. |
I am not sure if I can implement LayerGroups within the current vuelayers components or, if not, if this is something you are planning?
In my existing js system I implement them using something like layer.setLayers(layerCollection). They are very useful, for example when I have several sources, each of a sheet tiled separately, which together cover an area.
The text was updated successfully, but these errors were encountered: