nekromoff / bicycle-master-plan

Bicycle Master Plan is a bike map that allows visualizing cycling related data from different sources in multiple layers. Built heavily around data from OpenStreetMap, it allows full visual customization using CSS.
https://mapa.cyklokoalicia.sk/bratislava/public/
GNU General Public License v3.0
11 stars 0 forks source link

Enable/Disable Individual Editable Sublayers #33

Closed pqhf5kd closed 3 years ago

pqhf5kd commented 3 years ago

Add the option to enable individual sublayers instead of the whole editable layer.

image
nekromoff commented 3 years ago

I'll refactor code fetching respective types for the editable layer. It is already possible for the marker layers with multiple types, e.g.:

3   => [
            'type'  => 'marker',
            'name'  => 'Bikesharing',
            'class' => 'bikeshare',
            'types' => [
                1 => [
                    'name'    => '<img src="images/whitebikes.png" width="17"> Biele bicykle bikesharing',
                    'class'   => 'bikeshare-wb',
                    'icon'    => 'class',
                    'cluster' => false,
                ],
                2 => [
                    'name'    => '<img src="images/rekola.png" width="20"> Rekola bikesharing',
                    'class'   => 'bikeshare-rekola',
                    'icon'    => 'class',
                    'cluster' => false,
                ],
                3 => [
                    'name'    => '<img src="images/slovnaft-bajk.png" width="20"> Slovnaft BAJK bikesharing',
                    'class'   => 'bikeshare-sb',
                    'icon'    => 'class',
                    'file'    => 'bikeshare-sb.json',
                    'cluster' => false,
                ],
                4 => [
                    'name'    => '<img src="images/antik.png" width="20"> Antik Verejný bicykel bikesharing',
                    'class'   => 'bikeshare-antik',
                    'icon'    => 'class',
                    'cluster' => false,
                ],
            ],
        ],