• Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
MagicMirror Forum
  • Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
A New Chapter for MagicMirror: The Community Takes the Lead
Read the statement by Michael Teeuw here.

Trying to modify dimensions of module MMM-RAIN-RADAR

Scheduled Pinned Locked Moved Development
9 Posts 6 Posters 1.9k Views 5 Watching
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.
  • M Offline
    maddmurph @BD0G
    last edited by Dec 2, 2019, 8:01 PM

    @BD0G ahhhh I put it in the body brackets. I’ll try outside of them. Thanks!

    1 Reply Last reply Reply Quote 1
    • M Offline
      mcneilp
      last edited by Jan 22, 2020, 3:59 PM

      I am having the same trouble. This line of code seems to set the iframe height to 50vh. I have no idea what “vh” is.

      iframe.style = “border:0;height:50vh”;

      In my custom CSS i had to use:

      .MMM-RAIN-RADAR .iframe {
      width: 300px;
      height: 300px !important
      }

      I added the !important to get it to override this other inline style which seems to be ill formed.

      S 1 Reply Last reply Jan 22, 2020, 4:05 PM Reply Quote 0
      • S Offline
        sdetweil @mcneilp
        last edited by Jan 22, 2020, 4:05 PM

        @mcneilp vh is a percentage of view height, vw is view width…

        you would use these instead of hard coded number of pixels (99px),
        caus eon big screens the number of pixles change the percentage of vh would keep the look the same

        Sam

        How to add modules

        learning how to use browser developers window for css changes

        M 1 Reply Last reply Jan 22, 2020, 4:07 PM Reply Quote 0
        • M Offline
          mcneilp @sdetweil
          last edited by Jan 22, 2020, 4:07 PM

          @sdetweil
          interesting. I have never used “vh” as a unit before. Haven’t done much CSS in a while though.

          S 1 Reply Last reply Jan 22, 2020, 4:08 PM Reply Quote 0
          • S Offline
            sdetweil @mcneilp
            last edited by Jan 22, 2020, 4:08 PM

            @mcneilp 50vh is 1/2 the screen height, 100vh is full height

            Sam

            How to add modules

            learning how to use browser developers window for css changes

            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 Sam, technical setup by Karsten.
            This forum is using NodeBB as its core | Contributors
            Contact | Privacy Policy