FlightAware Discussions

Is there a way to hide the sidebar by default

Whenever I open flightaware in a browser at the dump1090 screen the sidebar is showing. I want it to be minimized. Is there a way I can select that by default?

You’ll have to modify the javascript (/usr/share/dump1090-fa/html/script.js):

Add the 3rd of those lines. (you’ll find the “kick off” easily)

        // And kick off one refresh immediately.
        fetchData();
        toggleSidebarVisibility(); 

Modify this function:

function toggleSidebarVisibility(e) {                                                                                                  
    e.preventDefault();

to look like this:

function toggleSidebarVisibility(e) {
    if (e)                                                                                                                             
        e.preventDefault();

Don’t forget to Ctrl-F5 refresh the page

That modification does what you want, at least for me.

I’m have modified my own web interface quite a bit: https://github.com/wiedehopf/tar1090#tar1090

It will remember if the bar is hidden for the next visit, but changing the default for new visitors will be similar to the procedure above.

Many thanks. That worked a charm.

Note any updates to dump1090-fa will overwrite this modification.