MagicMirror Forum

    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • Donate
    • Discord
    MagicMirror² v2.20.0 is available! For more information about this release, check out this topic.

    SOLVED MMM-FlightRadarTracker width problem

    Troubleshooting
    2
    3
    82
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • E
      Exndfan last edited by

      I have 2 Magic Mirrors running and both of them have jesmak’s Flight Radar Tracker module installed. On the large mirror, the display is correct: IMG_0967crop.jpeg Both the origin and destination airports are shown (destination is sometimes shortened which is okay).

      My problem is on my second MagicMirror that is using an iPad as the display. Due to the limited real estate on the iPad, I had to narrow the column width and now the destination airport doesn’t display:IMG_0966.jpg

      I would like for the origin and destination airports to be on separate lines but can’t figure out for the life of me of how to do it. I am a complete novice when it comes to Javascript and when I attempted to alter the code, the module broke and displayed nothing.

      Is there a Javascript genius here that can guide me on what to change in the module to display the origin and destination airports on separate lines? Thanks!

      1 Reply Last reply Reply Quote 0
      • hango
        hango Module Developer last edited by

        @exndfan said in MMM-FlightRadarTracker width problem:

        Flight Radar Tracker

        I don’t use this module but I can try to help you

        at line 138 you need to put a line break <br> in front of span before fa-plane-arrival icon

        originSubHeading.innerHTML = `<span><i class="fas fa-plane-departure dimmed" style="margin-right: 0.5em;"></i>${aircraft.origin}</span><span class="dimmed">(${aircraft.originId})</span><br><span><i class="fas fa-plane-arrival dimmed" style="margin-right: 0.5em;"></i>${aircraft.destination}</span><span class="dimmed">(${aircraft.destinationId})</span>`;
        

        https://github.com/hangorazvan

        E 1 Reply Last reply Reply Quote 0
        • E
          Exndfan @hango last edited by

          @hango

          That worked like a charm! Thanks!

          1 Reply Last reply Reply Quote 0
          • 1 / 1
          • First post
            Last post
          Enjoying MagicMirror? Please consider a donation!
          MagicMirror created by Michael Teeuw.
          Forum managed by Paul-Vincent Roll and Rodrigo Ramírez Norambuena.
          This forum is using NodeBB as its core | Contributors
          Contact | Privacy Policy