Re-add zoom controls

This commit is contained in:
Râu Cao 2026-02-10 17:47:03 +04:00
parent c37f794eea
commit 53300b92f5
Signed by: raucao
GPG Key ID: 37036C356E56CC51
2 changed files with 25 additions and 7 deletions

View File

@ -101,7 +101,7 @@ export default class MapComponent extends Component {
layers: [openfreemap, bookmarkLayer], layers: [openfreemap, bookmarkLayer],
view: view, view: view,
controls: defaultControls({ controls: defaultControls({
zoom: false, zoom: true,
rotate: true, rotate: true,
attribution: true, attribution: true,
}), }),

View File

@ -539,22 +539,40 @@ body {
} }
} }
/* Locate Control */ /* Zoom Control - Moved to bottom right above attribution */
.ol-zoom {
top: auto !important;
left: auto !important;
bottom: 2.5em;
right: 0.5em;
}
.ol-touch .ol-zoom {
bottom: 3.5em;
}
/* Locate Control - Above Zoom */
.ol-control.ol-locate { .ol-control.ol-locate {
inset: auto 0.5em 2.5em auto; top: auto !important;
left: auto !important;
bottom: 6.5em;
right: 0.5em;
} }
.ol-touch .ol-control.ol-locate { .ol-touch .ol-control.ol-locate {
inset: auto 0.5em 3.5em auto; bottom: 8.5em;
} }
/* Rotate Control */ /* Rotate Control - Above Locate */
.ol-rotate { .ol-rotate {
inset: auto 0.5em 5em auto; top: auto !important;
left: auto !important;
bottom: 9em;
right: 0.5em;
} }
.ol-touch .ol-rotate { .ol-touch .ol-rotate {
inset: auto 0.5em 6em auto; bottom: 11.5em;
} }
span.icon { span.icon {