netjsongraph.js icon indicating copy to clipboard operation
netjsongraph.js copied to clipboard

[feature] Use as much screen estate as possible on initial load

Open nemesifier opened this issue 4 months ago • 0 comments

Consider the following examples:

1) Custom attributes example

Image

2) Wireguard VPN data coming from a test server

Image

Both graphs contain little amount of data, therefore when the page loads, it would be a lot better if the library could automatically zoom in as much as possible. E.g:

1. Custom attributes example - updated

Probably I excedeed the zoom a little, but it's just to give you the idea.

Image

2. Wireguard VPN data coming from a test server - updated

Image

I think it would be a lot better if the library could automatically load the page with the sizes shown in the second set of examples. To summarize:

  • On small charts, the library will zoom in and due to the changes in #419, the labels will be visible.
  • On big charts, the library will still try to use all the available screen estate but will probably not zoom in much or not at all, and due to the changes in #419 the labels shouldn't be visible.

nemesifier avatar Aug 21 '25 18:08 nemesifier