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.

    MMM-COVID19

    Scheduled Pinned Locked Moved Health
    63 Posts 25 Posters 33.7k Views 24 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.
    • B Offline
      bobwilliams
      last edited by

      how to resize letters

      1 Reply Last reply Reply Quote 1
      • A Offline
        almostgithub
        last edited by almostgithub

        Love how simple this looks! Having a little trouble pulling from the API however… I put in my API key but nothing displays under the “confirmed Deaths recovered active” header bar.

        Not getting any errors, only thing i changed was adding in the x-rapidapi key from the link. do i need to add the host as well?

        Thanks and stay safe! @bibaldo

        ? 1 Reply Last reply Reply Quote 0
        • B Offline
          bibaldo
          last edited by

          @bobwilliams I’ve added new configuration for the letter font-size. Please read again the README

          @almostgithub you have to put your rapidapikey at your global config file only.
          If you have more issues, please output here your logs.

          A 1 Reply Last reply Reply Quote 0
          • A Offline
            almostgithub @bibaldo
            last edited by

            @bibaldo No errors or warnings related to the COVID-19 module in my logs. In my main config.js file i just copied your sample and then changed the API key. Was i supposed to do anything else?

            1 Reply Last reply Reply Quote 0
            • S Do not disturb
              sdetweil
              last edited by

              see another tracker, with line charts

              https://forum.magicmirror.builders/topic/12387/covid-bell-curve-line-graph-tracker

              Sam

              How to add modules

              learning how to use browser developers window for css changes

              1 Reply Last reply Reply Quote 0
              • B Offline
                bibaldo
                last edited by

                @almostgithub no, nothing more than that (if you have the module up-to-date).
                I would suggest you to perform a curl from your magicmirror (raspi or whatever) and check if the API is responding well.

                A 1 Reply Last reply Reply Quote 0
                • D Offline
                  dc331903
                  last edited by

                  Nice job! Looking good and thank you for the additions.

                  To add to that ordering of countries by name… allowing the ‘countries’ list to set the order. It looks like ‘orderCountriesbyName’ alphabetizes them, but I wasn’t able to figure out how to have them list in any other way.

                  Great job getting this going so quickly and appreciate it. Always like to have current information showing.

                  My Sample Code:

                   {
                      module: 'MMM-COVID19',
                      position: 'top_left',
                      config: {
                        updateInterval: 300000,
                        orderCountriesByName: true,
                        worldStats: true,
                        countries: [ "Canada", "Italy", "USA", "Mexico" ],
                        headerRowClass: "medium",
                        infoRowClass: "small",
                        rapidapiKey : “xxxxxxxxxxx ADD YOUR OWN API KEY xxxxxxxxx”  \
                      }
                    },
                  
                  1 Reply Last reply Reply Quote 0
                  • F Offline
                    fireport
                    last edited by fireport

                    I have no output in my MagicMirror and no error in log file. I tried a curl and the output it’s ok.

                    curl -H "x-rapidapi-host: coronavirus-monitor.p.rapidapi.com" -H "x-rapidapi-key: mykey"  'https://coronavirus-monitor.p.rapidapi.com/coronavirus/cases_by_country.php'
                    

                    This is my config:

                    {
                       module: 'MMM-COVID19',
                       config: {
                           position: 'top_center',
                         updateInterval: 300000,
                         worldStats: true,
                         countries: [  "Italy" ],
                         headerRowClass: "small",
                         rapidapiKey : "my api key" 
                       }
                     },
                    

                    Any suggestion ?

                    1 Reply Last reply Reply Quote 0
                    • T Offline
                      totof60
                      last edited by totof60

                      @fireport
                      i suggest you, in the config, to put the " position" before “config”

                      {
                          module: "MMM-COVID19",
                      	position: "top_center",
                          config: {
                            updateInterval: 300000,
                            worldStats: true,
                            countries: [ "France", "China", "Italy", "Spain" ],
                            headerRowClass: "small",
                            rapidapiKey : "xxxxxxxxxxxxxxxxxx" 
                          }
                        },
                      
                      F 1 Reply Last reply Reply Quote 0
                      • S Offline
                        start-the-fire
                        last edited by

                        @almostgithub
                        First you need to add the module “twice” into your config: MagicMirrorFolder/config/config.js

                        modules: [
                                       
                                        {
                                            module: 'MMM-COVID19'
                                          },
                        etc ...
                        

                        afterwards you need to enter your preferred settings & variables

                         {
                                            module: 'MMM-COVID19',
                                              position: "bottom_bar",
                                              config: {
                        
                                              header: "COVID-19 Stats",
                                              worldStats: true,
                                              rapidapiKey: "yourverylongapikey",
                                              orderCountriesByName: "false",
                                              countries: [ "Austria", "Germany", "Italy" ],
                                              updateInterval: 10000000,
                                              lastUpdateInfo: "true",
                                              headerRowClass: "small",
                                              infoRowClass: "medium",
                                                    }
                                          },
                        

                        Let me know if this solves your problem

                        1 Reply Last reply Reply Quote 0
                        • F Offline
                          fireport @totof60
                          last edited by

                          @totof60 Thank you. Now it works.

                          T 1 Reply Last reply Reply Quote 0
                          • T Offline
                            totof60 @fireport
                            last edited by

                            @fireport :winking_face:

                            1 Reply Last reply Reply Quote 0
                            • A Offline
                              almostgithub @bibaldo
                              last edited by

                              @bibaldo checked all that, was all working fine. Ended up rebooting my PI and it came up flawlessly!

                              Thank you

                              1 Reply Last reply Reply Quote 0
                              • LordyL Offline
                                Lordy
                                last edited by

                                Hello,

                                First of all thanks for the exact status.
                                How can I rename “Confirmed, Deaths, …”, since older people live in the house and only speak your mother tongue?
                                This is not meant to be evil or racist.
                                So, once again, our heartfelt thanks to the Forum.

                                I 1 Reply Last reply Reply Quote 0
                                • A Offline
                                  asdean
                                  last edited by

                                  This is awesome! Anyway to add individual States in the United States? For instance California, Michigan, New York?

                                  rafaelcotaR 1 Reply Last reply Reply Quote 1
                                  • I Offline
                                    irich @Lordy
                                    last edited by irich

                                    @Lordy Hello, you can change this in the MMM-COVID19.js (you find it in /MagicMirror/modules/MMM-COVID19) .

                                       .......
                                        headerconfirmedCell.innerHTML = 'Confirmed'
                                        .....
                                        headerNewConfirmedCell.innerHTML = 'New Cases'
                                        .....
                                        headerdeathsCell.innerHTML = 'Deaths'
                                        ......
                                        headerNewDeathsCell.innerHTML = 'New Deaths'
                                        ......
                                        header.recoveredCell.innerHTML = 'Recovered'
                                        ......
                                        headeractiveCell.innerHTML = 'Active'
                                    ....
                                    
                                    

                                    Just type in the “” the text you would like to see on the module.

                                    i have translated it into german

                                    headerCountryNameCell.innerHTML = ''
                                        headerconfirmedCell.className = 'number confirmed ' + this.config.headerRowClass
                                        headerconfirmedCell.innerHTML = 'Bestätigt'
                                        headerNewConfirmedCell.className = 'number confirmed ' + this.config.headerRowClass
                                        headerNewConfirmedCell.innerHTML = 'Neue Fälle'
                                        headerdeathsCell.className = 'number deaths ' + this.config.headerRowClass
                                        headerdeathsCell.innerHTML = 'Tote'
                                        headerNewDeathsCell.className = 'number deaths ' + this.config.headerRowClass
                                        headerNewDeathsCell.innerHTML = 'Neue Tote'
                                        headerrecoveredCell.className = 'number recovered ' + this.config.headerRowClass
                                        headerrecoveredCell.innerHTML = 'Erholt'
                                        headeractiveCell.className = 'number active ' + this.config.headerRowClass
                                        headeractiveCell.innerHTML = 'Aktiv'
                                    

                                    Just replace the part.
                                    Ersetze einfach die Stelle

                                    LordyL Z 2 Replies Last reply Reply Quote 0
                                    • LordyL Offline
                                      Lordy @irich
                                      last edited by

                                      @irich said in MMM-COVID19:
                                      Das ist genau was ich haben wollte.
                                      Kann man die Umbenennung auch irgendwie Config eintragen, nicht das Änderung beim nächsten Update abhanden kommt?

                                      Thank you:thumbs_up_medium-light_skin_tone:
                                      Can you enter the renaming somehow Config, not that the change is lost in the next update?

                                      1 Reply Last reply Reply Quote 0
                                      • Z Offline
                                        Zinkeler @irich
                                        last edited by

                                        @irich Hallo, das hab ich auch schon geschafft. Weiß denn jemand, wie ich die “,” durch “.” ersetzen kann. Will anstatt 434,595 das deutsche Format haben.
                                        Danke für eventuelle Antworten.

                                        1 Reply Last reply Reply Quote 0
                                        • ? Offline
                                          A Former User
                                          last edited by A Former User

                                          This post is deleted!
                                          ? 1 Reply Last reply Reply Quote 0
                                          • B Offline
                                            bibaldo
                                            last edited by

                                            @Lordy what language do they speak? I can add the translations for them

                                            LordyL 1 Reply Last reply Reply Quote 0

                                            Hello! It looks like you're interested in this conversation, but you don't have an account yet.

                                            Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

                                            With your input, this post could be even better 💗

                                            Register Login
                                            • 1
                                            • 2
                                            • 3
                                            • 4
                                            • 3 / 4
                                            • 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