Feature: Worldmap screenfixed objects#262
Conversation
For UX consinstence: browser doesn't show cursor:pointer which may make user feel it's clickable.
|
Thanks for the suggestion. The feature actually sounds useful. What I don't like about the proposed approach is that you have to do the configuration in two places. If I understood that correctly, you have to build a kind of dummy map (regular map) on which you position any objects. This map has to be referenced in the worldmap, then the dummy-map will show the objects as an overlay. Correct? We should try to implement this feature within the worldmap. For example, I could imagine that you add an object in the normal way and then adjust the way you position it. For this we could adapt the format of the relative coordinates. For example, "viewport%+123" could be a reference to the upper left edge of the map + 123 pixels. |
|
This very approach (new format of coordinates, in my design it was Such coordinates would have belonged to the etc/maps/*.cfg file, whereas "normal" lat/lng coordinates stay in sqlite. Only after modifying the backend re adding/editing an object I found it dead end: tons of code, On the other hand, combining Not to mention the complexity of View* and NagVis* javascript objects that would have needed to be modified so that screenfixed objects don't pan when leaflet map is panned. (Now they also behave like this, elegantly by swapping |
... and style it cursor:pointer to keep UX
What?
The
worldmapis a perfect tool to display geographical objects on the map. However, there are in real also non-geographical objects in play. This PR brings a feature to show them too.Overview zoom - note the map legend on upper left:

Detailed zoom - note the map legend still on the place:

Why?
Real-world NOC (Network Operations Centre) needs to see a big picture at a glance. Perfectly tuned geographical map shows how's the network. In addition, things like
are very handy to show on the screen too, regardless of the viewport (map center, map zoom).
How?
Two maps - interactive and regular - are merged together.

On an interactive map, new option comes into play
screenfixed_objects_from_map.Chosen regular map objects simply show on the screen. Since it's regular, objects positions are pixel-based (rather than coordinate-based) so that they're fixed on the screen.
Documentation in English updated on this.
Under the hood
The
ViewWorldmaploads this map object and additionally referred regular map objects firing subsequentGET getMapObjectsrequest. Then regularobj.render();draws them on the screen.