├── ios ├── Runner │ ├── Runner-Bridging-Header.h │ ├── Assets.xcassets │ │ ├── LaunchImage.imageset │ │ │ ├── LaunchImage.png │ │ │ ├── LaunchImage@2x.png │ │ │ ├── LaunchImage@3x.png │ │ │ ├── README.md │ │ │ └── Contents.json │ │ └── AppIcon.appiconset │ │ │ ├── Icon-App-20x20@1x.png │ │ │ ├── Icon-App-20x20@2x.png │ │ │ ├── Icon-App-20x20@3x.png │ │ │ ├── Icon-App-29x29@1x.png │ │ │ ├── Icon-App-29x29@2x.png │ │ │ ├── Icon-App-29x29@3x.png │ │ │ ├── Icon-App-40x40@1x.png │ │ │ ├── Icon-App-40x40@2x.png │ │ │ ├── Icon-App-40x40@3x.png │ │ │ ├── Icon-App-60x60@2x.png │ │ │ ├── Icon-App-60x60@3x.png │ │ │ ├── Icon-App-76x76@1x.png │ │ │ ├── Icon-App-76x76@2x.png │ │ │ ├── Icon-App-1024x1024@1x.png │ │ │ ├── Icon-App-83.5x83.5@2x.png │ │ │ └── Contents.json │ ├── AppDelegate.swift │ ├── Base.lproj │ │ ├── Main.storyboard │ │ └── LaunchScreen.storyboard │ └── Info.plist ├── Flutter │ ├── Debug.xcconfig │ ├── Release.xcconfig │ └── AppFrameworkInfo.plist ├── Runner.xcodeproj │ ├── project.xcworkspace │ │ ├── contents.xcworkspacedata │ │ └── xcshareddata │ │ │ ├── WorkspaceSettings.xcsettings │ │ │ └── IDEWorkspaceChecks.plist │ └── xcshareddata │ │ └── xcschemes │ │ └── Runner.xcscheme ├── Runner.xcworkspace │ ├── contents.xcworkspacedata │ └── xcshareddata │ │ ├── WorkspaceSettings.xcsettings │ │ └── IDEWorkspaceChecks.plist ├── .gitignore ├── Podfile.lock └── Podfile ├── assets ├── ad.png ├── ae.png ├── af.png ├── ag.png ├── ai.png ├── al.png ├── am.png ├── an.png ├── ao.png ├── aq.png ├── ar.png ├── as.png ├── at.png ├── au.png ├── aw.png ├── ax.png ├── az.png ├── ba.png ├── bb.png ├── bd.png ├── be.png ├── bf.png ├── bg.png ├── bh.png ├── bi.png ├── bj.png ├── bl.png ├── bm.png ├── bn.png ├── bo.png ├── bq.png ├── br.png ├── bs.png ├── bt.png ├── bv.png ├── bw.png ├── by.png ├── bz.png ├── ca.png ├── cc.png ├── cd.png ├── cf.png ├── cg.png ├── ch.png ├── ci.png ├── ck.png ├── cl.png ├── cm.png ├── cn.png ├── co.png ├── cr.png ├── cu.png ├── cv.png ├── cw.png ├── cx.png ├── cy.png ├── cz.png ├── de.png ├── dj.png ├── dk.png ├── dm.png ├── do.png ├── dz.png ├── ec.png ├── ee.png ├── eg.png ├── eh.png ├── er.png ├── es.png ├── et.png ├── eu.png ├── fi.png ├── fj.png ├── fk.png ├── fm.png ├── fo.png ├── fr.png ├── ga.png ├── gb.png ├── gd.png ├── ge.png ├── gf.png ├── gg.png ├── gh.png ├── gi.png ├── gl.png ├── gm.png ├── gn.png ├── gp.png ├── gq.png ├── gr.png ├── gs.png ├── gt.png ├── gu.png ├── gw.png ├── gy.png ├── hk.png ├── hm.png ├── hn.png ├── hr.png ├── ht.png ├── hu.png ├── id.png ├── ie.png ├── il.png ├── im.png ├── in.png ├── io.png ├── iq.png ├── ir.png ├── is.png ├── it.png ├── je.png ├── jm.png ├── jo.png ├── jp.png ├── ke.png ├── kg.png ├── kh.png ├── ki.png ├── km.png ├── kn.png ├── kp.png ├── kr.png ├── kw.png ├── ky.png ├── kz.png ├── la.png ├── lb.png ├── lc.png ├── li.png ├── lk.png ├── lr.png ├── ls.png ├── lt.png ├── lu.png ├── lv.png ├── ly.png ├── ma.png ├── mc.png ├── md.png ├── me.png ├── mf.png ├── mg.png ├── mh.png ├── mk.png ├── ml.png ├── mm.png ├── mn.png ├── mo.png ├── mp.png ├── mq.png ├── mr.png ├── ms.png ├── mt.png ├── mu.png ├── mv.png ├── mw.png ├── mx.png ├── my.png ├── mz.png ├── na.png ├── nc.png ├── ne.png ├── nf.png ├── ng.png ├── ni.png ├── nl.png ├── no.png ├── np.png ├── nr.png ├── nu.png ├── nz.png ├── om.png ├── pa.png ├── pe.png ├── pf.png ├── pg.png ├── ph.png ├── pk.png ├── pl.png ├── pm.png ├── pn.png ├── pr.png ├── ps.png ├── pt.png ├── pw.png ├── py.png ├── qa.png ├── re.png ├── ro.png ├── rs.png ├── ru.png ├── rw.png ├── sa.png ├── sb.png ├── sc.png ├── sd.png ├── se.png ├── sg.png ├── sh.png ├── si.png ├── sj.png ├── sk.png ├── sl.png ├── sm.png ├── sn.png ├── so.png ├── sr.png ├── ss.png ├── st.png ├── sv.png ├── sx.png ├── sy.png ├── sz.png ├── tc.png ├── td.png ├── tf.png ├── tg.png ├── th.png ├── tj.png ├── tk.png ├── tl.png ├── tm.png ├── tn.png ├── to.png ├── tr.png ├── tt.png ├── tv.png ├── tw.png ├── tz.png ├── ua.png ├── ug.png ├── um.png ├── us.png ├── uy.png ├── uz.png ├── va.png ├── vc.png ├── ve.png ├── vg.png ├── vi.png ├── vn.png ├── vu.png ├── wf.png ├── ws.png ├── xk.png ├── ye.png ├── yt.png ├── za.png ├── zm.png ├── zw.png ├── gb-eng.png ├── gb-nir.png ├── gb-sct.png ├── gb-wls.png └── unknow.png ├── web ├── favicon.png ├── icons │ ├── Icon-192.png │ └── Icon-512.png ├── manifest.json └── index.html ├── screenshot └── screenshot.png ├── android ├── gradle.properties ├── .gitignore ├── app │ ├── src │ │ ├── main │ │ │ ├── res │ │ │ │ ├── mipmap-hdpi │ │ │ │ │ └── ic_launcher.png │ │ │ │ ├── mipmap-mdpi │ │ │ │ │ └── ic_launcher.png │ │ │ │ ├── mipmap-xhdpi │ │ │ │ │ └── ic_launcher.png │ │ │ │ ├── mipmap-xxhdpi │ │ │ │ │ └── ic_launcher.png │ │ │ │ ├── mipmap-xxxhdpi │ │ │ │ │ └── ic_launcher.png │ │ │ │ ├── drawable │ │ │ │ │ └── launch_background.xml │ │ │ │ └── values │ │ │ │ │ └── styles.xml │ │ │ ├── kotlin │ │ │ │ └── com │ │ │ │ │ └── example │ │ │ │ │ └── covid19 │ │ │ │ │ └── MainActivity.kt │ │ │ └── AndroidManifest.xml │ │ ├── debug │ │ │ └── AndroidManifest.xml │ │ └── profile │ │ │ └── AndroidManifest.xml │ └── build.gradle ├── gradle │ └── wrapper │ │ └── gradle-wrapper.properties ├── settings.gradle └── build.gradle ├── .metadata ├── .gitignore ├── README.md ├── lib ├── model │ ├── utils.dart │ ├── pcm.dart │ └── novel_covid.dart ├── chart │ ├── chart_label.dart │ ├── italy_chart.dart │ ├── chart.dart │ └── lineChart.dart ├── view │ ├── single_ita_reg_report.dart │ ├── details.dart │ ├── single_usa_states_report.dart │ ├── list_usa_states.dart │ ├── list_ita_regioni.dart │ ├── list_all_countries.dart │ ├── single_ita_report.dart │ └── single_int_report.dart ├── layout │ ├── master_detail_usa.dart │ ├── master_detail_ita.dart │ └── master_detail.dart ├── main.dart └── service │ └── service.dart ├── LICENSE ├── pubspec.yaml └── pubspec.lock /ios/Runner/Runner-Bridging-Header.h: -------------------------------------------------------------------------------- 1 | #import "GeneratedPluginRegistrant.h" 2 | -------------------------------------------------------------------------------- /assets/ad.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ad.png -------------------------------------------------------------------------------- /assets/ae.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ae.png -------------------------------------------------------------------------------- /assets/af.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/af.png -------------------------------------------------------------------------------- /assets/ag.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ag.png -------------------------------------------------------------------------------- /assets/ai.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ai.png -------------------------------------------------------------------------------- /assets/al.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/al.png -------------------------------------------------------------------------------- /assets/am.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/am.png -------------------------------------------------------------------------------- /assets/an.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/an.png -------------------------------------------------------------------------------- /assets/ao.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ao.png -------------------------------------------------------------------------------- /assets/aq.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/aq.png -------------------------------------------------------------------------------- /assets/ar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ar.png -------------------------------------------------------------------------------- /assets/as.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/as.png -------------------------------------------------------------------------------- /assets/at.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/at.png -------------------------------------------------------------------------------- /assets/au.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/au.png -------------------------------------------------------------------------------- /assets/aw.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/aw.png -------------------------------------------------------------------------------- /assets/ax.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ax.png -------------------------------------------------------------------------------- /assets/az.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/az.png -------------------------------------------------------------------------------- /assets/ba.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ba.png -------------------------------------------------------------------------------- /assets/bb.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/bb.png -------------------------------------------------------------------------------- /assets/bd.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/bd.png -------------------------------------------------------------------------------- /assets/be.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/be.png -------------------------------------------------------------------------------- /assets/bf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/bf.png -------------------------------------------------------------------------------- /assets/bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/bg.png -------------------------------------------------------------------------------- /assets/bh.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/bh.png -------------------------------------------------------------------------------- /assets/bi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/bi.png -------------------------------------------------------------------------------- /assets/bj.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/bj.png -------------------------------------------------------------------------------- /assets/bl.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/bl.png -------------------------------------------------------------------------------- /assets/bm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/bm.png -------------------------------------------------------------------------------- /assets/bn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/bn.png -------------------------------------------------------------------------------- /assets/bo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/bo.png -------------------------------------------------------------------------------- /assets/bq.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/bq.png -------------------------------------------------------------------------------- /assets/br.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/br.png -------------------------------------------------------------------------------- /assets/bs.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/bs.png -------------------------------------------------------------------------------- /assets/bt.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/bt.png -------------------------------------------------------------------------------- /assets/bv.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/bv.png -------------------------------------------------------------------------------- /assets/bw.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/bw.png -------------------------------------------------------------------------------- /assets/by.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/by.png -------------------------------------------------------------------------------- /assets/bz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/bz.png -------------------------------------------------------------------------------- /assets/ca.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ca.png -------------------------------------------------------------------------------- /assets/cc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/cc.png -------------------------------------------------------------------------------- /assets/cd.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/cd.png -------------------------------------------------------------------------------- /assets/cf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/cf.png -------------------------------------------------------------------------------- /assets/cg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/cg.png -------------------------------------------------------------------------------- /assets/ch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ch.png -------------------------------------------------------------------------------- /assets/ci.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ci.png -------------------------------------------------------------------------------- /assets/ck.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ck.png -------------------------------------------------------------------------------- /assets/cl.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/cl.png -------------------------------------------------------------------------------- /assets/cm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/cm.png -------------------------------------------------------------------------------- /assets/cn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/cn.png -------------------------------------------------------------------------------- /assets/co.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/co.png -------------------------------------------------------------------------------- /assets/cr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/cr.png -------------------------------------------------------------------------------- /assets/cu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/cu.png -------------------------------------------------------------------------------- /assets/cv.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/cv.png -------------------------------------------------------------------------------- /assets/cw.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/cw.png -------------------------------------------------------------------------------- /assets/cx.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/cx.png -------------------------------------------------------------------------------- /assets/cy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/cy.png -------------------------------------------------------------------------------- /assets/cz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/cz.png -------------------------------------------------------------------------------- /assets/de.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/de.png -------------------------------------------------------------------------------- /assets/dj.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/dj.png -------------------------------------------------------------------------------- /assets/dk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/dk.png -------------------------------------------------------------------------------- /assets/dm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/dm.png -------------------------------------------------------------------------------- /assets/do.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/do.png -------------------------------------------------------------------------------- /assets/dz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/dz.png -------------------------------------------------------------------------------- /assets/ec.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ec.png -------------------------------------------------------------------------------- /assets/ee.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ee.png -------------------------------------------------------------------------------- /assets/eg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/eg.png -------------------------------------------------------------------------------- /assets/eh.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/eh.png -------------------------------------------------------------------------------- /assets/er.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/er.png -------------------------------------------------------------------------------- /assets/es.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/es.png -------------------------------------------------------------------------------- /assets/et.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/et.png -------------------------------------------------------------------------------- /assets/eu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/eu.png -------------------------------------------------------------------------------- /assets/fi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/fi.png -------------------------------------------------------------------------------- /assets/fj.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/fj.png -------------------------------------------------------------------------------- /assets/fk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/fk.png -------------------------------------------------------------------------------- /assets/fm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/fm.png -------------------------------------------------------------------------------- /assets/fo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/fo.png -------------------------------------------------------------------------------- /assets/fr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/fr.png -------------------------------------------------------------------------------- /assets/ga.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ga.png -------------------------------------------------------------------------------- /assets/gb.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gb.png -------------------------------------------------------------------------------- /assets/gd.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gd.png -------------------------------------------------------------------------------- /assets/ge.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ge.png -------------------------------------------------------------------------------- /assets/gf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gf.png -------------------------------------------------------------------------------- /assets/gg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gg.png -------------------------------------------------------------------------------- /assets/gh.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gh.png -------------------------------------------------------------------------------- /assets/gi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gi.png -------------------------------------------------------------------------------- /assets/gl.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gl.png -------------------------------------------------------------------------------- /assets/gm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gm.png -------------------------------------------------------------------------------- /assets/gn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gn.png -------------------------------------------------------------------------------- /assets/gp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gp.png -------------------------------------------------------------------------------- /assets/gq.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gq.png -------------------------------------------------------------------------------- /assets/gr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gr.png -------------------------------------------------------------------------------- /assets/gs.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gs.png -------------------------------------------------------------------------------- /assets/gt.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gt.png -------------------------------------------------------------------------------- /assets/gu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gu.png -------------------------------------------------------------------------------- /assets/gw.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gw.png -------------------------------------------------------------------------------- /assets/gy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gy.png -------------------------------------------------------------------------------- /assets/hk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/hk.png -------------------------------------------------------------------------------- /assets/hm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/hm.png -------------------------------------------------------------------------------- /assets/hn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/hn.png -------------------------------------------------------------------------------- /assets/hr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/hr.png -------------------------------------------------------------------------------- /assets/ht.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ht.png -------------------------------------------------------------------------------- /assets/hu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/hu.png -------------------------------------------------------------------------------- /assets/id.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/id.png -------------------------------------------------------------------------------- /assets/ie.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ie.png -------------------------------------------------------------------------------- /assets/il.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/il.png -------------------------------------------------------------------------------- /assets/im.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/im.png -------------------------------------------------------------------------------- /assets/in.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/in.png -------------------------------------------------------------------------------- /assets/io.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/io.png -------------------------------------------------------------------------------- /assets/iq.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/iq.png -------------------------------------------------------------------------------- /assets/ir.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ir.png -------------------------------------------------------------------------------- /assets/is.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/is.png -------------------------------------------------------------------------------- /assets/it.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/it.png -------------------------------------------------------------------------------- /assets/je.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/je.png -------------------------------------------------------------------------------- /assets/jm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/jm.png -------------------------------------------------------------------------------- /assets/jo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/jo.png -------------------------------------------------------------------------------- /assets/jp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/jp.png -------------------------------------------------------------------------------- /assets/ke.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ke.png -------------------------------------------------------------------------------- /assets/kg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/kg.png -------------------------------------------------------------------------------- /assets/kh.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/kh.png -------------------------------------------------------------------------------- /assets/ki.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ki.png -------------------------------------------------------------------------------- /assets/km.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/km.png -------------------------------------------------------------------------------- /assets/kn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/kn.png -------------------------------------------------------------------------------- /assets/kp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/kp.png -------------------------------------------------------------------------------- /assets/kr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/kr.png -------------------------------------------------------------------------------- /assets/kw.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/kw.png -------------------------------------------------------------------------------- /assets/ky.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ky.png -------------------------------------------------------------------------------- /assets/kz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/kz.png -------------------------------------------------------------------------------- /assets/la.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/la.png -------------------------------------------------------------------------------- /assets/lb.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/lb.png -------------------------------------------------------------------------------- /assets/lc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/lc.png -------------------------------------------------------------------------------- /assets/li.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/li.png -------------------------------------------------------------------------------- /assets/lk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/lk.png -------------------------------------------------------------------------------- /assets/lr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/lr.png -------------------------------------------------------------------------------- /assets/ls.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ls.png -------------------------------------------------------------------------------- /assets/lt.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/lt.png -------------------------------------------------------------------------------- /assets/lu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/lu.png -------------------------------------------------------------------------------- /assets/lv.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/lv.png -------------------------------------------------------------------------------- /assets/ly.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ly.png -------------------------------------------------------------------------------- /assets/ma.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ma.png -------------------------------------------------------------------------------- /assets/mc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/mc.png -------------------------------------------------------------------------------- /assets/md.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/md.png -------------------------------------------------------------------------------- /assets/me.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/me.png -------------------------------------------------------------------------------- /assets/mf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/mf.png -------------------------------------------------------------------------------- /assets/mg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/mg.png -------------------------------------------------------------------------------- /assets/mh.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/mh.png -------------------------------------------------------------------------------- /assets/mk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/mk.png -------------------------------------------------------------------------------- /assets/ml.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ml.png -------------------------------------------------------------------------------- /assets/mm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/mm.png -------------------------------------------------------------------------------- /assets/mn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/mn.png -------------------------------------------------------------------------------- /assets/mo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/mo.png -------------------------------------------------------------------------------- /assets/mp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/mp.png -------------------------------------------------------------------------------- /assets/mq.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/mq.png -------------------------------------------------------------------------------- /assets/mr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/mr.png -------------------------------------------------------------------------------- /assets/ms.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ms.png -------------------------------------------------------------------------------- /assets/mt.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/mt.png -------------------------------------------------------------------------------- /assets/mu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/mu.png -------------------------------------------------------------------------------- /assets/mv.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/mv.png -------------------------------------------------------------------------------- /assets/mw.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/mw.png -------------------------------------------------------------------------------- /assets/mx.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/mx.png -------------------------------------------------------------------------------- /assets/my.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/my.png -------------------------------------------------------------------------------- /assets/mz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/mz.png -------------------------------------------------------------------------------- /assets/na.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/na.png -------------------------------------------------------------------------------- /assets/nc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/nc.png -------------------------------------------------------------------------------- /assets/ne.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ne.png -------------------------------------------------------------------------------- /assets/nf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/nf.png -------------------------------------------------------------------------------- /assets/ng.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ng.png -------------------------------------------------------------------------------- /assets/ni.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ni.png -------------------------------------------------------------------------------- /assets/nl.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/nl.png -------------------------------------------------------------------------------- /assets/no.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/no.png -------------------------------------------------------------------------------- /assets/np.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/np.png -------------------------------------------------------------------------------- /assets/nr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/nr.png -------------------------------------------------------------------------------- /assets/nu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/nu.png -------------------------------------------------------------------------------- /assets/nz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/nz.png -------------------------------------------------------------------------------- /assets/om.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/om.png -------------------------------------------------------------------------------- /assets/pa.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/pa.png -------------------------------------------------------------------------------- /assets/pe.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/pe.png -------------------------------------------------------------------------------- /assets/pf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/pf.png -------------------------------------------------------------------------------- /assets/pg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/pg.png -------------------------------------------------------------------------------- /assets/ph.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ph.png -------------------------------------------------------------------------------- /assets/pk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/pk.png -------------------------------------------------------------------------------- /assets/pl.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/pl.png -------------------------------------------------------------------------------- /assets/pm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/pm.png -------------------------------------------------------------------------------- /assets/pn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/pn.png -------------------------------------------------------------------------------- /assets/pr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/pr.png -------------------------------------------------------------------------------- /assets/ps.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ps.png -------------------------------------------------------------------------------- /assets/pt.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/pt.png -------------------------------------------------------------------------------- /assets/pw.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/pw.png -------------------------------------------------------------------------------- /assets/py.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/py.png -------------------------------------------------------------------------------- /assets/qa.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/qa.png -------------------------------------------------------------------------------- /assets/re.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/re.png -------------------------------------------------------------------------------- /assets/ro.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ro.png -------------------------------------------------------------------------------- /assets/rs.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/rs.png -------------------------------------------------------------------------------- /assets/ru.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ru.png -------------------------------------------------------------------------------- /assets/rw.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/rw.png -------------------------------------------------------------------------------- /assets/sa.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/sa.png -------------------------------------------------------------------------------- /assets/sb.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/sb.png -------------------------------------------------------------------------------- /assets/sc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/sc.png -------------------------------------------------------------------------------- /assets/sd.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/sd.png -------------------------------------------------------------------------------- /assets/se.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/se.png -------------------------------------------------------------------------------- /assets/sg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/sg.png -------------------------------------------------------------------------------- /assets/sh.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/sh.png -------------------------------------------------------------------------------- /assets/si.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/si.png -------------------------------------------------------------------------------- /assets/sj.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/sj.png -------------------------------------------------------------------------------- /assets/sk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/sk.png -------------------------------------------------------------------------------- /assets/sl.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/sl.png -------------------------------------------------------------------------------- /assets/sm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/sm.png -------------------------------------------------------------------------------- /assets/sn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/sn.png -------------------------------------------------------------------------------- /assets/so.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/so.png -------------------------------------------------------------------------------- /assets/sr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/sr.png -------------------------------------------------------------------------------- /assets/ss.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ss.png -------------------------------------------------------------------------------- /assets/st.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/st.png -------------------------------------------------------------------------------- /assets/sv.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/sv.png -------------------------------------------------------------------------------- /assets/sx.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/sx.png -------------------------------------------------------------------------------- /assets/sy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/sy.png -------------------------------------------------------------------------------- /assets/sz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/sz.png -------------------------------------------------------------------------------- /assets/tc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/tc.png -------------------------------------------------------------------------------- /assets/td.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/td.png -------------------------------------------------------------------------------- /assets/tf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/tf.png -------------------------------------------------------------------------------- /assets/tg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/tg.png -------------------------------------------------------------------------------- /assets/th.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/th.png -------------------------------------------------------------------------------- /assets/tj.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/tj.png -------------------------------------------------------------------------------- /assets/tk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/tk.png -------------------------------------------------------------------------------- /assets/tl.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/tl.png -------------------------------------------------------------------------------- /assets/tm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/tm.png -------------------------------------------------------------------------------- /assets/tn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/tn.png -------------------------------------------------------------------------------- /assets/to.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/to.png -------------------------------------------------------------------------------- /assets/tr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/tr.png -------------------------------------------------------------------------------- /assets/tt.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/tt.png -------------------------------------------------------------------------------- /assets/tv.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/tv.png -------------------------------------------------------------------------------- /assets/tw.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/tw.png -------------------------------------------------------------------------------- /assets/tz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/tz.png -------------------------------------------------------------------------------- /assets/ua.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ua.png -------------------------------------------------------------------------------- /assets/ug.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ug.png -------------------------------------------------------------------------------- /assets/um.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/um.png -------------------------------------------------------------------------------- /assets/us.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/us.png -------------------------------------------------------------------------------- /assets/uy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/uy.png -------------------------------------------------------------------------------- /assets/uz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/uz.png -------------------------------------------------------------------------------- /assets/va.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/va.png -------------------------------------------------------------------------------- /assets/vc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/vc.png -------------------------------------------------------------------------------- /assets/ve.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ve.png -------------------------------------------------------------------------------- /assets/vg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/vg.png -------------------------------------------------------------------------------- /assets/vi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/vi.png -------------------------------------------------------------------------------- /assets/vn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/vn.png -------------------------------------------------------------------------------- /assets/vu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/vu.png -------------------------------------------------------------------------------- /assets/wf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/wf.png -------------------------------------------------------------------------------- /assets/ws.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ws.png -------------------------------------------------------------------------------- /assets/xk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/xk.png -------------------------------------------------------------------------------- /assets/ye.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/ye.png -------------------------------------------------------------------------------- /assets/yt.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/yt.png -------------------------------------------------------------------------------- /assets/za.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/za.png -------------------------------------------------------------------------------- /assets/zm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/zm.png -------------------------------------------------------------------------------- /assets/zw.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/zw.png -------------------------------------------------------------------------------- /web/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/web/favicon.png -------------------------------------------------------------------------------- /assets/gb-eng.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gb-eng.png -------------------------------------------------------------------------------- /assets/gb-nir.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gb-nir.png -------------------------------------------------------------------------------- /assets/gb-sct.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gb-sct.png -------------------------------------------------------------------------------- /assets/gb-wls.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/gb-wls.png -------------------------------------------------------------------------------- /assets/unknow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/assets/unknow.png -------------------------------------------------------------------------------- /web/icons/Icon-192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/web/icons/Icon-192.png -------------------------------------------------------------------------------- /web/icons/Icon-512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/web/icons/Icon-512.png -------------------------------------------------------------------------------- /screenshot/screenshot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/screenshot/screenshot.png -------------------------------------------------------------------------------- /ios/Flutter/Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" 2 | #include "Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /android/gradle.properties: -------------------------------------------------------------------------------- 1 | org.gradle.jvmargs=-Xmx1536M 2 | android.enableR8=true 3 | android.useAndroidX=true 4 | android.enableJetifier=true 5 | -------------------------------------------------------------------------------- /ios/Flutter/Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" 2 | #include "Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /android/.gitignore: -------------------------------------------------------------------------------- 1 | gradle-wrapper.jar 2 | /.gradle 3 | /captures/ 4 | /gradlew 5 | /gradlew.bat 6 | /local.properties 7 | GeneratedPluginRegistrant.java 8 | -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/android/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/android/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dariolr/Flutter_Covid-19/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png -------------------------------------------------------------------------------- /android/app/src/main/kotlin/com/example/covid19/MainActivity.kt: -------------------------------------------------------------------------------- 1 | package com.example.covid19 2 | 3 | import io.flutter.embedding.android.FlutterActivity 4 | 5 | class MainActivity: FlutterActivity() { 6 | } 7 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /android/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Fri Jun 23 08:50:38 CEST 2017 2 | distributionBase=GRADLE_USER_HOME 3 | distributionPath=wrapper/dists 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.2-all.zip 7 | -------------------------------------------------------------------------------- /ios/Runner.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /.metadata: -------------------------------------------------------------------------------- 1 | # This file tracks properties of this Flutter project. 2 | # Used by Flutter tool to assess capabilities and perform upgrades etc. 3 | # 4 | # This file should be version controlled and should not be manually edited. 5 | 6 | version: 7 | revision: be3a4b37b3e9ab4e80d45b59bed53708b96d211f 8 | channel: master 9 | 10 | project_type: app 11 | -------------------------------------------------------------------------------- /android/app/src/debug/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /android/app/src/profile/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md: -------------------------------------------------------------------------------- 1 | # Launch Screen Assets 2 | 3 | You can customize the launch screen with your own desired assets by replacing the image files in this directory. 4 | 5 | You can also do it by opening your Flutter project's Xcode project with `open ios/Runner.xcworkspace`, selecting `Runner/Assets.xcassets` in the Project Navigator and dropping in the desired images. -------------------------------------------------------------------------------- /ios/Runner/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | import UIKit 2 | import Flutter 3 | 4 | @UIApplicationMain 5 | @objc class AppDelegate: FlutterAppDelegate { 6 | override func application( 7 | _ application: UIApplication, 8 | didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? 9 | ) -> Bool { 10 | GeneratedPluginRegistrant.register(with: self) 11 | return super.application(application, didFinishLaunchingWithOptions: launchOptions) 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /android/app/src/main/res/drawable/launch_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "LaunchImage.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "filename" : "LaunchImage@2x.png", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "idiom" : "universal", 15 | "filename" : "LaunchImage@3x.png", 16 | "scale" : "3x" 17 | } 18 | ], 19 | "info" : { 20 | "version" : 1, 21 | "author" : "xcode" 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /android/settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | 3 | def flutterProjectRoot = rootProject.projectDir.parentFile.toPath() 4 | 5 | def plugins = new Properties() 6 | def pluginsFile = new File(flutterProjectRoot.toFile(), '.flutter-plugins') 7 | if (pluginsFile.exists()) { 8 | pluginsFile.withReader('UTF-8') { reader -> plugins.load(reader) } 9 | } 10 | 11 | plugins.each { name, path -> 12 | def pluginDirectory = flutterProjectRoot.resolve(path).resolve('android').toFile() 13 | include ":$name" 14 | project(":$name").projectDir = pluginDirectory 15 | } 16 | -------------------------------------------------------------------------------- /web/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "covid19", 3 | "short_name": "covid19", 4 | "start_url": ".", 5 | "display": "minimal-ui", 6 | "background_color": "#0175C2", 7 | "theme_color": "#0175C2", 8 | "description": "A new Flutter project.", 9 | "orientation": "portrait-primary", 10 | "prefer_related_applications": false, 11 | "icons": [ 12 | { 13 | "src": "icons/Icon-192.png", 14 | "sizes": "192x192", 15 | "type": "image/png" 16 | }, 17 | { 18 | "src": "icons/Icon-512.png", 19 | "sizes": "512x512", 20 | "type": "image/png" 21 | } 22 | ] 23 | } 24 | -------------------------------------------------------------------------------- /ios/.gitignore: -------------------------------------------------------------------------------- 1 | *.mode1v3 2 | *.mode2v3 3 | *.moved-aside 4 | *.pbxuser 5 | *.perspectivev3 6 | **/*sync/ 7 | .sconsign.dblite 8 | .tags* 9 | **/.vagrant/ 10 | **/DerivedData/ 11 | Icon? 12 | **/Pods/ 13 | **/.symlinks/ 14 | profile 15 | xcuserdata 16 | **/.generated/ 17 | Flutter/App.framework 18 | Flutter/Flutter.framework 19 | Flutter/Flutter.podspec 20 | Flutter/Generated.xcconfig 21 | Flutter/app.flx 22 | Flutter/app.zip 23 | Flutter/flutter_assets/ 24 | Flutter/flutter_export_environment.sh 25 | ServiceDefinitions.json 26 | Runner/GeneratedPluginRegistrant.* 27 | 28 | # Exceptions to above rules. 29 | !default.mode1v3 30 | !default.mode2v3 31 | !default.pbxuser 32 | !default.perspectivev3 33 | -------------------------------------------------------------------------------- /android/build.gradle: -------------------------------------------------------------------------------- 1 | buildscript { 2 | ext.kotlin_version = '1.3.50' 3 | repositories { 4 | google() 5 | jcenter() 6 | } 7 | 8 | dependencies { 9 | classpath 'com.android.tools.build:gradle:3.5.0' 10 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" 11 | } 12 | } 13 | 14 | allprojects { 15 | repositories { 16 | google() 17 | jcenter() 18 | } 19 | } 20 | 21 | rootProject.buildDir = '../build' 22 | subprojects { 23 | project.buildDir = "${rootProject.buildDir}/${project.name}" 24 | } 25 | subprojects { 26 | project.evaluationDependsOn(':app') 27 | } 28 | 29 | task clean(type: Delete) { 30 | delete rootProject.buildDir 31 | } 32 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Miscellaneous 2 | *.class 3 | *.log 4 | *.pyc 5 | *.swp 6 | .DS_Store 7 | .atom/ 8 | .buildlog/ 9 | .history 10 | .svn/ 11 | 12 | # IntelliJ related 13 | *.iml 14 | *.ipr 15 | *.iws 16 | .idea/ 17 | 18 | .vscode/ 19 | 20 | # Flutter/Dart/Pub related 21 | **/doc/api/ 22 | .dart_tool/ 23 | .flutter-plugins 24 | .flutter-plugins-dependencies 25 | .packages 26 | .pub-cache/ 27 | .pub/ 28 | /build/ 29 | 30 | # Web related 31 | lib/generated_plugin_registrant.dart 32 | 33 | # Symbolication related 34 | app.*.symbols 35 | 36 | # Obfuscation related 37 | app.*.map.json 38 | 39 | # Exceptions to above rules. 40 | !/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages 41 | 42 | .test/ 43 | 44 | .dariolr.github.io/ -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 |

2 | 3 |

4 | 5 | # Covid-19 Stats 6 | 7 | Covid-19 stats around the world. 8 | 9 | - USA stats by single states 10 | - Italy stats by single regions 11 | 12 | 13 | ## Flutter web 14 | 15 | 16 | to buid use: 17 | 18 | flutter build web --dart-define=FLUTTER_WEB_USE_SKIA=true 19 | 20 | ## License 21 | 22 | MIT License - see the [LICENSE](LICENSE) 23 | 24 | ## Inspired from 25 | 26 | * [CovidUpdates](https://github.com/ashishkhuraishy/CovidUpdates) - by Ashish 27 | * [Covid19Stats](https://github.com/GabrielTavernini/Covid19Stats) - by Gabriel Tavernini 28 | 29 | ## Credits 30 | 31 | * [COVID-19](https://github.com/pcm-dpc/COVID-19) - Italy stats 32 | * [NovelCOVID/API](https://github.com/NovelCOVID/API) - other countries stats 33 | 34 | 35 | -------------------------------------------------------------------------------- /lib/model/utils.dart: -------------------------------------------------------------------------------- 1 | // 2 | class _Util { 3 | const _Util(); 4 | // 5 | bool url(String input) => RegExp(r"^(?:http|https):\/\/[\w\-_]+(?:\.[\w\-_]+)+[\w\-.,@?^=%&:/~\\+#]*$").hasMatch(input); 6 | // 7 | String perOneMillionToString(dynamic input) { 8 | if (input is int) { 9 | return input.toString(); 10 | } else if (input is double) { 11 | return input.toString(); 12 | } else { 13 | return input ?? "0"; 14 | } 15 | } 16 | // 17 | int dynamicToInt(dynamic input) { 18 | if (input is int) { 19 | return input; 20 | } else if (input is double) { 21 | return input.toInt(); 22 | } else if (input is String) { 23 | return int.parse(input); 24 | } else { 25 | return 0; 26 | } 27 | } 28 | // 29 | } 30 | // 31 | final _Util util = const _Util(); 32 | // 33 | // 34 | 35 | 36 | -------------------------------------------------------------------------------- /ios/Flutter/AppFrameworkInfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | App 9 | CFBundleIdentifier 10 | io.flutter.flutter.app 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | App 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1.0 23 | MinimumOSVersion 24 | 8.0 25 | 26 | 27 | -------------------------------------------------------------------------------- /android/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 15 | 18 | 19 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2020 Dario La Rosa 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /web/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | Covid-19 Stats 18 | 19 | 20 | 21 | 24 | 31 | 32 | 33 | 34 | -------------------------------------------------------------------------------- /lib/chart/chart_label.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | class ChartLabel extends StatelessWidget { 4 | final Color color; 5 | final double percent; 6 | final String label; 7 | 8 | const ChartLabel({ 9 | Key key, 10 | this.color, 11 | this.label, 12 | this.percent = 15, 13 | }) : super(key: key); 14 | 15 | @override 16 | Widget build(BuildContext context) { 17 | return Padding( 18 | padding: const EdgeInsets.only(bottom: 10), 19 | child: Row( 20 | crossAxisAlignment: CrossAxisAlignment.start, 21 | children: [ 22 | Container( 23 | margin: EdgeInsets.only(top: 3), 24 | width: 10, 25 | height: 10, 26 | decoration: BoxDecoration( 27 | shape: BoxShape.circle, 28 | color: color, 29 | ), 30 | ), 31 | const SizedBox( 32 | width: 5, 33 | ), 34 | Column( 35 | crossAxisAlignment: CrossAxisAlignment.start, 36 | children: [ 37 | Text( 38 | label, 39 | style: Theme.of(context).textTheme.caption, 40 | ), 41 | Text( 42 | '${percent.toStringAsFixed(2)}%', 43 | style: Theme.of(context).textTheme.subtitle2.copyWith( 44 | fontWeight: FontWeight.bold, 45 | ), 46 | ), 47 | ], 48 | ) 49 | ], 50 | ), 51 | ); 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /ios/Runner/Base.lproj/Main.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /ios/Runner/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | covid19 15 | CFBundlePackageType 16 | APPL 17 | CFBundleShortVersionString 18 | $(FLUTTER_BUILD_NAME) 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | $(FLUTTER_BUILD_NUMBER) 23 | LSRequiresIPhoneOS 24 | 25 | UILaunchStoryboardName 26 | LaunchScreen 27 | UIMainStoryboardFile 28 | Main 29 | UISupportedInterfaceOrientations 30 | 31 | UIInterfaceOrientationPortrait 32 | UIInterfaceOrientationLandscapeLeft 33 | UIInterfaceOrientationLandscapeRight 34 | 35 | UISupportedInterfaceOrientations~ipad 36 | 37 | UIInterfaceOrientationPortrait 38 | UIInterfaceOrientationPortraitUpsideDown 39 | UIInterfaceOrientationLandscapeLeft 40 | UIInterfaceOrientationLandscapeRight 41 | 42 | UIViewControllerBasedStatusBarAppearance 43 | 44 | 45 | 46 | -------------------------------------------------------------------------------- /lib/view/single_ita_reg_report.dart: -------------------------------------------------------------------------------- 1 | import 'package:covid19/chart/italy_chart.dart'; 2 | import 'package:covid19/model/pcm.dart'; 3 | import 'package:covid19/view/single_ita_report.dart'; 4 | import 'package:flutter/foundation.dart'; 5 | import 'package:flutter/material.dart'; 6 | 7 | class SingleITARegReportView extends StatefulWidget { 8 | static const routeName = '/singleITARegReportView'; 9 | final Nazionale provincia; 10 | SingleITARegReportView({Key key, @required this.provincia}) : super(key: key); 11 | @override 12 | _SingleITARegReportViewState createState() => _SingleITARegReportViewState(); 13 | } 14 | 15 | class _SingleITARegReportViewState extends State { 16 | @override 17 | Widget build(BuildContext context) { 18 | return OrientationBuilder(builder: (context, orientation) { 19 | final isLargeScreen = MediaQuery.of(context).size.width > 600; 20 | return Scaffold( 21 | backgroundColor: Colors.grey[50], 22 | appBar: AppBar( 23 | leading: isLargeScreen ? new Container() : null, 24 | title: Text(widget.provincia.denominazioneRegione), 25 | backgroundColor: Colors.white, 26 | elevation: 1.0, 27 | iconTheme: IconThemeData(color: Colors.black), 28 | centerTitle: true, 29 | ), 30 | body: SafeArea( 31 | child: SingleChildScrollView( 32 | child: Container( 33 | color: Colors.grey[50], 34 | child: Column( 35 | mainAxisAlignment: MainAxisAlignment.spaceEvenly, 36 | children: [ 37 | DetailITA(nazionale: widget.provincia), 38 | ItalyStatsPieChart(stats: widget.provincia), 39 | ]))))); 40 | }); 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /ios/Podfile.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - Flutter (1.0.0) 3 | - flutter_keyboard_visibility (0.7.0): 4 | - Flutter 5 | - path_provider (0.0.1): 6 | - Flutter 7 | - path_provider_macos (0.0.1): 8 | - Flutter 9 | - url_launcher (0.0.1): 10 | - Flutter 11 | - url_launcher_macos (0.0.1): 12 | - Flutter 13 | - url_launcher_web (0.0.1): 14 | - Flutter 15 | 16 | DEPENDENCIES: 17 | - Flutter (from `Flutter`) 18 | - flutter_keyboard_visibility (from `.symlinks/plugins/flutter_keyboard_visibility/ios`) 19 | - path_provider (from `.symlinks/plugins/path_provider/ios`) 20 | - path_provider_macos (from `.symlinks/plugins/path_provider_macos/ios`) 21 | - url_launcher (from `.symlinks/plugins/url_launcher/ios`) 22 | - url_launcher_macos (from `.symlinks/plugins/url_launcher_macos/ios`) 23 | - url_launcher_web (from `.symlinks/plugins/url_launcher_web/ios`) 24 | 25 | EXTERNAL SOURCES: 26 | Flutter: 27 | :path: Flutter 28 | flutter_keyboard_visibility: 29 | :path: ".symlinks/plugins/flutter_keyboard_visibility/ios" 30 | path_provider: 31 | :path: ".symlinks/plugins/path_provider/ios" 32 | path_provider_macos: 33 | :path: ".symlinks/plugins/path_provider_macos/ios" 34 | url_launcher: 35 | :path: ".symlinks/plugins/url_launcher/ios" 36 | url_launcher_macos: 37 | :path: ".symlinks/plugins/url_launcher_macos/ios" 38 | url_launcher_web: 39 | :path: ".symlinks/plugins/url_launcher_web/ios" 40 | 41 | SPEC CHECKSUMS: 42 | Flutter: 0e3d915762c693b495b44d77113d4970485de6ec 43 | flutter_keyboard_visibility: 6195387fb6d8f46e5cd6dda4a4154e41f800f545 44 | path_provider: fb74bd0465e96b594bb3b5088ee4a4e7bb1f2a9d 45 | path_provider_macos: f760a3c5b04357c380e2fddb6f9db6f3015897e0 46 | url_launcher: a1c0cc845906122c4784c542523d8cacbded5626 47 | url_launcher_macos: fd7894421cd39320dce5f292fc99ea9270b2a313 48 | url_launcher_web: e5527357f037c87560776e36436bf2b0288b965c 49 | 50 | PODFILE CHECKSUM: c34e2287a9ccaa606aeceab922830efb9a6ff69a 51 | 52 | COCOAPODS: 1.9.1 53 | -------------------------------------------------------------------------------- /android/app/build.gradle: -------------------------------------------------------------------------------- 1 | def localProperties = new Properties() 2 | def localPropertiesFile = rootProject.file('local.properties') 3 | if (localPropertiesFile.exists()) { 4 | localPropertiesFile.withReader('UTF-8') { reader -> 5 | localProperties.load(reader) 6 | } 7 | } 8 | 9 | def flutterRoot = localProperties.getProperty('flutter.sdk') 10 | if (flutterRoot == null) { 11 | throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.") 12 | } 13 | 14 | def flutterVersionCode = localProperties.getProperty('flutter.versionCode') 15 | if (flutterVersionCode == null) { 16 | flutterVersionCode = '1' 17 | } 18 | 19 | def flutterVersionName = localProperties.getProperty('flutter.versionName') 20 | if (flutterVersionName == null) { 21 | flutterVersionName = '1.0' 22 | } 23 | 24 | apply plugin: 'com.android.application' 25 | apply plugin: 'kotlin-android' 26 | apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" 27 | 28 | android { 29 | compileSdkVersion 28 30 | 31 | sourceSets { 32 | main.java.srcDirs += 'src/main/kotlin' 33 | } 34 | 35 | lintOptions { 36 | disable 'InvalidPackage' 37 | } 38 | 39 | defaultConfig { 40 | // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). 41 | applicationId "com.example.covid19" 42 | minSdkVersion 16 43 | targetSdkVersion 28 44 | versionCode flutterVersionCode.toInteger() 45 | versionName flutterVersionName 46 | } 47 | 48 | buildTypes { 49 | release { 50 | // TODO: Add your own signing config for the release build. 51 | // Signing with the debug keys for now, so `flutter run --release` works. 52 | signingConfig signingConfigs.debug 53 | } 54 | } 55 | } 56 | 57 | flutter { 58 | source '../..' 59 | } 60 | 61 | dependencies { 62 | implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" 63 | } 64 | -------------------------------------------------------------------------------- /lib/layout/master_detail_usa.dart: -------------------------------------------------------------------------------- 1 | import 'package:covid19/model/novel_covid.dart'; 2 | import 'package:covid19/view/list_usa_states.dart'; 3 | import 'package:covid19/view/single_int_report.dart'; 4 | import 'package:covid19/view/single_usa_states_report.dart'; 5 | import 'package:flutter/foundation.dart'; 6 | import 'package:flutter/material.dart'; 7 | 8 | class MasterDetailPageUSA extends StatefulWidget { 9 | static const routeName = '/masterDetailPageUSA'; 10 | static const countryName = 'USA'; 11 | final Country country; 12 | MasterDetailPageUSA({Key key, this.country}) : super(key: key); 13 | 14 | @override 15 | _MasterDetailPageUSAState createState() => _MasterDetailPageUSAState(); 16 | } 17 | 18 | class _MasterDetailPageUSAState extends State { 19 | States _states; 20 | var _isLargeScreen; 21 | 22 | @override 23 | Widget build(BuildContext context) { 24 | return Scaffold( 25 | body: OrientationBuilder(builder: (context, orientation) { 26 | _isLargeScreen = MediaQuery.of(context).size.width > 600; 27 | return Row(children: [ 28 | Expanded( 29 | child: ListUSAStatesView((value) { 30 | _states = value; 31 | if (_isLargeScreen) { 32 | setState(() {}); 33 | } else { 34 | _states.state == ListUSAStatesView.tuttiGliStati 35 | ? Navigator.pushNamed( 36 | context, SingleIntReportView.routeName, 37 | arguments: widget.country) 38 | : Navigator.pushNamed( 39 | context, SingleUSAStatesReportView.routeName, 40 | arguments: _states); 41 | } 42 | }, widget.country), 43 | ), 44 | _isLargeScreen && _states != null 45 | ? Expanded( 46 | child: _states.state == ListUSAStatesView.tuttiGliStati 47 | ? SingleIntReportView( 48 | country: widget.country, 49 | ) 50 | : SingleUSAStatesReportView(state: _states)) 51 | : _isLargeScreen 52 | ? Expanded(child: Container()) 53 | : Container(), 54 | ]); 55 | }), 56 | ); 57 | } 58 | } 59 | -------------------------------------------------------------------------------- /lib/layout/master_detail_ita.dart: -------------------------------------------------------------------------------- 1 | import 'package:covid19/model/novel_covid.dart'; 2 | import 'package:covid19/model/pcm.dart'; 3 | import 'package:covid19/view/list_ita_regioni.dart'; 4 | import 'package:covid19/view/single_ita_report.dart'; 5 | import 'package:covid19/view/single_ita_reg_report.dart'; 6 | import 'package:flutter/foundation.dart'; 7 | import 'package:flutter/material.dart'; 8 | 9 | class MasterDetailPageITA extends StatefulWidget { 10 | static const routeName = '/masterDetailPageITA'; 11 | static const countryName = 'Italy'; 12 | final Country selectedCountry; 13 | MasterDetailPageITA({Key key, this.selectedCountry}) : super(key: key); 14 | 15 | @override 16 | _MasterDetailPageITAState createState() => _MasterDetailPageITAState(); 17 | } 18 | 19 | class _MasterDetailPageITAState extends State { 20 | Nazionale _nazionale; 21 | var _isLargeScreen; 22 | 23 | @override 24 | Widget build(BuildContext context) { 25 | return Scaffold( 26 | body: OrientationBuilder(builder: (context, orientation) { 27 | _isLargeScreen = MediaQuery.of(context).size.width > 600; 28 | return Row(children: [ 29 | Expanded( 30 | child: ListITARegioniView((value) { 31 | _nazionale = value; 32 | if (_isLargeScreen) { 33 | setState(() {}); 34 | } else { 35 | _nazionale.denominazioneRegione == 36 | ListITARegioniView.tutteLeRegioni 37 | ? Navigator.pushNamed( 38 | context, SingleITAReportView.routeName, 39 | arguments: widget.selectedCountry) 40 | : Navigator.pushNamed( 41 | context, SingleITARegReportView.routeName, 42 | arguments: _nazionale); 43 | } 44 | }, widget.selectedCountry), 45 | ), 46 | _isLargeScreen && _nazionale != null 47 | ? Expanded( 48 | child: _nazionale.denominazioneRegione == 49 | ListITARegioniView.tutteLeRegioni 50 | ? SingleITAReportView( 51 | country: widget.selectedCountry, 52 | ) 53 | : SingleITARegReportView(provincia: _nazionale)) 54 | : _isLargeScreen ? Expanded(child: Container()) : Container(), 55 | ]); 56 | }), 57 | ); 58 | } 59 | } 60 | -------------------------------------------------------------------------------- /ios/Runner/Base.lproj/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /lib/layout/master_detail.dart: -------------------------------------------------------------------------------- 1 | import 'package:covid19/layout/master_detail_ita.dart'; 2 | import 'package:covid19/layout/master_detail_usa.dart'; 3 | import 'package:covid19/model/novel_covid.dart'; 4 | import 'package:covid19/view/details.dart'; 5 | import 'package:covid19/view/list_all_countries.dart'; 6 | import 'package:covid19/view/single_int_report.dart'; 7 | import 'package:flutter/material.dart'; 8 | 9 | class MasterDetailPage extends StatefulWidget { 10 | static Color f = const Color(0xffffffff); 11 | @override 12 | _MasterDetailPageState createState() => _MasterDetailPageState(); 13 | } 14 | 15 | class _MasterDetailPageState extends State { 16 | Country _selectedCountry; 17 | var _isLargeScreen = false; 18 | @override 19 | Widget build(BuildContext context) { 20 | return Scaffold( 21 | body: OrientationBuilder(builder: (context, orientation) { 22 | _isLargeScreen = MediaQuery.of(context).size.width > 600; 23 | return Row(children: [ 24 | Expanded( 25 | child: ListCountryView((value) { 26 | if (value.country == MasterDetailPageITA.countryName) { 27 | Navigator.pushNamed(context, MasterDetailPageITA.routeName, 28 | arguments: value); 29 | } else if (value.country == MasterDetailPageUSA.countryName) { 30 | Navigator.pushNamed(context, MasterDetailPageUSA.routeName, 31 | arguments: value); 32 | } else { 33 | _selectedCountry = value; 34 | if (_isLargeScreen) { 35 | setState(() {}); 36 | } else { 37 | Navigator.pushNamed(context, SingleIntReportView.routeName, 38 | arguments: _selectedCountry); 39 | } 40 | } 41 | }), 42 | ), 43 | _isLargeScreen && _selectedCountry != null 44 | ? Expanded( 45 | child: _selectedCountry.country == 46 | MasterDetailPageITA.countryName 47 | ? MasterDetailPageITA( 48 | selectedCountry: _selectedCountry, 49 | ) 50 | : _selectedCountry.country == 51 | MasterDetailPageUSA.countryName 52 | ? MasterDetailPageUSA( 53 | country: _selectedCountry, 54 | ) 55 | : SingleIntReportView(country: _selectedCountry)) 56 | : _isLargeScreen ? Expanded(child: DetailsView()) : Container(), 57 | ]); 58 | }), 59 | ); 60 | } 61 | } 62 | -------------------------------------------------------------------------------- /android/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 8 | 12 | 19 | 23 | 27 | 32 | 36 | 37 | 38 | 39 | 40 | 41 | 43 | 46 | 47 | 48 | -------------------------------------------------------------------------------- /lib/view/details.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:url_launcher/url_launcher.dart'; 3 | 4 | class DetailsView extends StatefulWidget { 5 | @override 6 | _DetailsViewState createState() => _DetailsViewState(); 7 | } 8 | 9 | class _DetailsViewState extends State { 10 | @override 11 | Widget build(BuildContext context) { 12 | final pcmUrl = "https://github.com/pcm-dpc/COVID-19"; 13 | final novelCovidUrl = "https://github.com/NovelCOVID/API"; 14 | return Scaffold( 15 | backgroundColor: Colors.white, 16 | appBar: AppBar( 17 | backgroundColor: Colors.white, 18 | elevation: 1.0, 19 | leading: new Container(), 20 | ), 21 | body: Center( 22 | child: SafeArea( 23 | child: SingleChildScrollView( 24 | child: Container( 25 | child: Column( 26 | mainAxisAlignment: MainAxisAlignment.spaceEvenly, 27 | children: [ 28 | Row(children: [ 29 | Text("Credits: ", 30 | style: TextStyle(fontWeight: FontWeight.bold),), 31 | InkWell( 32 | child: Text(pcmUrl, 33 | style: TextStyle( 34 | color: Colors.blue[800], 35 | decoration: TextDecoration.underline, 36 | )), 37 | onTap: () async { 38 | if (await canLaunch(pcmUrl)) { 39 | await launch(pcmUrl); 40 | } 41 | }, 42 | ), 43 | ]), 44 | Divider( 45 | height: 50, 46 | ), 47 | Row(children: [ 48 | Text("Credits: ", 49 | style: TextStyle(fontWeight: FontWeight.bold)), 50 | InkWell( 51 | child: Text(novelCovidUrl, 52 | style: TextStyle( 53 | color: Colors.blue[800], 54 | decoration: TextDecoration.underline, 55 | )), 56 | onTap: () async { 57 | if (await canLaunch(novelCovidUrl)) { 58 | await launch(novelCovidUrl); 59 | } 60 | }, 61 | ), 62 | ]), 63 | ], 64 | ), 65 | ), 66 | ), 67 | ), 68 | )); 69 | } 70 | } 71 | -------------------------------------------------------------------------------- /pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: covid19 2 | description: A new Flutter project. 3 | 4 | # The following defines the version and build number for your application. 5 | # A version number is three numbers separated by dots, like 1.2.43 6 | # followed by an optional build number separated by a +. 7 | # Both the version and the builder number may be overridden in flutter 8 | # build by specifying --build-name and --build-number, respectively. 9 | # In Android, build-name is used as versionName while build-number used as versionCode. 10 | # Read more about Android versioning at https://developer.android.com/studio/publish/versioning 11 | # In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion. 12 | # Read more about iOS versioning at 13 | # https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html 14 | version: 1.0.0+1 15 | 16 | environment: 17 | sdk: ">=2.3.0 <3.0.0" 18 | 19 | dependencies: 20 | flutter: 21 | sdk: flutter 22 | 23 | 24 | # The following adds the Cupertino Icons font to your application. 25 | # Use with the CupertinoIcons class for iOS style icons. 26 | cupertino_icons: ^0.1.3 27 | google_fonts: ^0.3.10 28 | http: ^0.12.0+4 29 | intl: ^0.16.1 30 | fl_chart: ^0.8.7 31 | url_launcher: ^5.4.2 32 | transparent_image: ^1.0.0 33 | search_widget: ^1.0.2 34 | liquid_pull_to_refresh: ^1.1.1 35 | 36 | dev_dependencies: 37 | flutter_test: 38 | sdk: flutter 39 | 40 | # For information on the generic Dart part of this file, see the 41 | # following page: https://dart.dev/tools/pub/pubspec 42 | 43 | # The following section is specific to Flutter. 44 | flutter: 45 | 46 | # The following line ensures that the Material Icons font is 47 | # included with your application, so that you can use the icons in 48 | # the material Icons class. 49 | uses-material-design: true 50 | 51 | assets: 52 | - assets/ 53 | # To add assets to your application, add an assets section, like this: 54 | # assets: 55 | # - images/a_dot_burr.jpeg 56 | # - images/a_dot_ham.jpeg 57 | 58 | # An image asset can refer to one or more resolution-specific "variants", see 59 | # https://flutter.dev/assets-and-images/#resolution-aware. 60 | 61 | # For details regarding adding assets from package dependencies, see 62 | # https://flutter.dev/assets-and-images/#from-packages 63 | 64 | # To add custom fonts to your application, add a fonts section here, 65 | # in this "flutter" section. Each entry in this list should have a 66 | # "family" key with the font family name, and a "fonts" key with a 67 | # list giving the asset and other descriptors for the font. For 68 | # example: 69 | # fonts: 70 | # - family: Schyler 71 | # fonts: 72 | # - asset: fonts/Schyler-Regular.ttf 73 | # - asset: fonts/Schyler-Italic.ttf 74 | # style: italic 75 | # - family: Trajan Pro 76 | # fonts: 77 | # - asset: fonts/TrajanPro.ttf 78 | # - asset: fonts/TrajanPro_Bold.ttf 79 | # weight: 700 80 | # 81 | # For details regarding fonts from package dependencies, 82 | # see https://flutter.dev/custom-fonts/#from-packages 83 | -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "size" : "20x20", 5 | "idiom" : "iphone", 6 | "filename" : "Icon-App-20x20@2x.png", 7 | "scale" : "2x" 8 | }, 9 | { 10 | "size" : "20x20", 11 | "idiom" : "iphone", 12 | "filename" : "Icon-App-20x20@3x.png", 13 | "scale" : "3x" 14 | }, 15 | { 16 | "size" : "29x29", 17 | "idiom" : "iphone", 18 | "filename" : "Icon-App-29x29@1x.png", 19 | "scale" : "1x" 20 | }, 21 | { 22 | "size" : "29x29", 23 | "idiom" : "iphone", 24 | "filename" : "Icon-App-29x29@2x.png", 25 | "scale" : "2x" 26 | }, 27 | { 28 | "size" : "29x29", 29 | "idiom" : "iphone", 30 | "filename" : "Icon-App-29x29@3x.png", 31 | "scale" : "3x" 32 | }, 33 | { 34 | "size" : "40x40", 35 | "idiom" : "iphone", 36 | "filename" : "Icon-App-40x40@2x.png", 37 | "scale" : "2x" 38 | }, 39 | { 40 | "size" : "40x40", 41 | "idiom" : "iphone", 42 | "filename" : "Icon-App-40x40@3x.png", 43 | "scale" : "3x" 44 | }, 45 | { 46 | "size" : "60x60", 47 | "idiom" : "iphone", 48 | "filename" : "Icon-App-60x60@2x.png", 49 | "scale" : "2x" 50 | }, 51 | { 52 | "size" : "60x60", 53 | "idiom" : "iphone", 54 | "filename" : "Icon-App-60x60@3x.png", 55 | "scale" : "3x" 56 | }, 57 | { 58 | "size" : "20x20", 59 | "idiom" : "ipad", 60 | "filename" : "Icon-App-20x20@1x.png", 61 | "scale" : "1x" 62 | }, 63 | { 64 | "size" : "20x20", 65 | "idiom" : "ipad", 66 | "filename" : "Icon-App-20x20@2x.png", 67 | "scale" : "2x" 68 | }, 69 | { 70 | "size" : "29x29", 71 | "idiom" : "ipad", 72 | "filename" : "Icon-App-29x29@1x.png", 73 | "scale" : "1x" 74 | }, 75 | { 76 | "size" : "29x29", 77 | "idiom" : "ipad", 78 | "filename" : "Icon-App-29x29@2x.png", 79 | "scale" : "2x" 80 | }, 81 | { 82 | "size" : "40x40", 83 | "idiom" : "ipad", 84 | "filename" : "Icon-App-40x40@1x.png", 85 | "scale" : "1x" 86 | }, 87 | { 88 | "size" : "40x40", 89 | "idiom" : "ipad", 90 | "filename" : "Icon-App-40x40@2x.png", 91 | "scale" : "2x" 92 | }, 93 | { 94 | "size" : "76x76", 95 | "idiom" : "ipad", 96 | "filename" : "Icon-App-76x76@1x.png", 97 | "scale" : "1x" 98 | }, 99 | { 100 | "size" : "76x76", 101 | "idiom" : "ipad", 102 | "filename" : "Icon-App-76x76@2x.png", 103 | "scale" : "2x" 104 | }, 105 | { 106 | "size" : "83.5x83.5", 107 | "idiom" : "ipad", 108 | "filename" : "Icon-App-83.5x83.5@2x.png", 109 | "scale" : "2x" 110 | }, 111 | { 112 | "size" : "1024x1024", 113 | "idiom" : "ios-marketing", 114 | "filename" : "Icon-App-1024x1024@1x.png", 115 | "scale" : "1x" 116 | } 117 | ], 118 | "info" : { 119 | "version" : 1, 120 | "author" : "xcode" 121 | } 122 | } 123 | -------------------------------------------------------------------------------- /lib/main.dart: -------------------------------------------------------------------------------- 1 | import 'package:covid19/layout/master_detail.dart'; 2 | import 'package:covid19/layout/master_detail_ita.dart'; 3 | import 'package:covid19/layout/master_detail_usa.dart'; 4 | import 'package:covid19/view/list_usa_states.dart'; 5 | import 'package:covid19/view/single_int_report.dart'; 6 | import 'package:covid19/view/list_ita_regioni.dart'; 7 | import 'package:covid19/view/single_ita_report.dart'; 8 | import 'package:covid19/view/single_ita_reg_report.dart'; 9 | import 'package:covid19/view/single_usa_states_report.dart'; 10 | import 'package:flutter/material.dart'; 11 | import 'package:google_fonts/google_fonts.dart'; 12 | 13 | void main() => runApp(MyApp()); 14 | 15 | 16 | class MyApp extends StatelessWidget { 17 | @override 18 | Widget build(BuildContext context) { 19 | return MaterialApp( 20 | title: 'Covid-19', 21 | theme: ThemeData( 22 | primaryColor: Colors.grey[400], 23 | textTheme: GoogleFonts.latoTextTheme(Theme.of(context).textTheme), 24 | ), 25 | debugShowCheckedModeBanner: false, 26 | onGenerateRoute: (settings) { 27 | if (settings.name == SingleIntReportView.routeName) { 28 | return MaterialPageRoute( 29 | builder: (context) { 30 | return SingleIntReportView(country: settings.arguments); 31 | }, 32 | ); 33 | } else 34 | if (settings.name == MasterDetailPageUSA.routeName) { 35 | return MaterialPageRoute( 36 | builder: (context) { 37 | return MasterDetailPageUSA(country: settings.arguments); 38 | }, 39 | ); 40 | } else 41 | if (settings.name == ListUSAStatesView.routeName) { 42 | return MaterialPageRoute( 43 | builder: (context) { 44 | return ListUSAStatesView(null , settings.arguments); 45 | }, 46 | ); 47 | } else 48 | if (settings.name == SingleUSAStatesReportView.routeName) { 49 | return MaterialPageRoute( 50 | builder: (context) { 51 | return SingleUSAStatesReportView(state: settings.arguments); 52 | }, 53 | ); 54 | } else 55 | if (settings.name == MasterDetailPageITA.routeName) { 56 | return MaterialPageRoute( 57 | builder: (context) { 58 | return MasterDetailPageITA(selectedCountry: settings.arguments); 59 | }, 60 | ); 61 | } else 62 | if (settings.name == ListITARegioniView.routeName) { 63 | return MaterialPageRoute( 64 | builder: (context) { 65 | return ListITARegioniView(null , settings.arguments); 66 | }, 67 | ); 68 | } else 69 | if (settings.name == SingleITAReportView.routeName) { 70 | return MaterialPageRoute( 71 | builder: (context) { 72 | return SingleITAReportView(country: settings.arguments); 73 | }, 74 | ); 75 | } else 76 | if (settings.name == SingleITARegReportView.routeName) { 77 | return MaterialPageRoute( 78 | builder: (context) { 79 | return SingleITARegReportView(provincia: settings.arguments); 80 | }, 81 | ); 82 | } else 83 | return null; 84 | }, 85 | routes: { 86 | '/': (context) => MasterDetailPage(), 87 | }, 88 | ); 89 | } 90 | 91 | 92 | } 93 | -------------------------------------------------------------------------------- /lib/model/pcm.dart: -------------------------------------------------------------------------------- 1 | import 'package:covid19/model/utils.dart'; 2 | 3 | class Nazionale { 4 | DateTime data; 5 | String stato; 6 | int ricoveratiConSintomi; 7 | int terapiaIntensiva; 8 | int totaleOspedalizzati; 9 | int isolamentoDomiciliare; 10 | int totaleAttualmentePositivi; 11 | int variazioneTotalePositivi; 12 | int nuoviPositivi; 13 | int dimessiGuariti; 14 | int deceduti; 15 | int totaleCasi; 16 | int tamponi; 17 | String noteIt; 18 | String noteEn; 19 | int codiceRegione; 20 | String denominazioneRegione; 21 | double lat; 22 | double long; 23 | 24 | Nazionale({ 25 | this.data, 26 | this.stato, 27 | this.ricoveratiConSintomi, 28 | this.terapiaIntensiva, 29 | this.totaleOspedalizzati, 30 | this.isolamentoDomiciliare, 31 | this.totaleAttualmentePositivi, 32 | this.variazioneTotalePositivi, 33 | this.nuoviPositivi, 34 | this.dimessiGuariti, 35 | this.deceduti, 36 | this.totaleCasi, 37 | this.tamponi, 38 | this.noteIt, 39 | this.noteEn, 40 | this.codiceRegione, 41 | this.denominazioneRegione, 42 | this.lat, 43 | this.long, 44 | }); 45 | 46 | factory Nazionale.fromJson(Map json) => Nazionale( 47 | data: DateTime.parse(json["data"]), 48 | stato: json["stato"], 49 | ricoveratiConSintomi: json["ricoverati_con_sintomi"], 50 | terapiaIntensiva: json["terapia_intensiva"], 51 | totaleOspedalizzati: json["totale_ospedalizzati"], 52 | isolamentoDomiciliare: json["isolamento_domiciliare"], 53 | totaleAttualmentePositivi: json["totale_positivi"], 54 | variazioneTotalePositivi: json["variazione_totale_positivi"], 55 | nuoviPositivi: json["nuovi_positivi"], 56 | dimessiGuariti: json["dimessi_guariti"], 57 | deceduti: json["deceduti"], 58 | totaleCasi: util.dynamicToInt(json["totale_casi"]), 59 | tamponi: json["tamponi"], 60 | noteIt: json["note_it"], 61 | noteEn: json["note_en"], 62 | codiceRegione: json["codice_regione"] == null ? null : json["codice_regione"], 63 | denominazioneRegione: json["denominazione_regione"] == null ? null : json["denominazione_regione"], 64 | lat: json["lat"] == null ? null : json["lat"].toDouble(), 65 | long: json["long"] == null ? null : json["long"].toDouble(), 66 | ); 67 | 68 | Map toJson() => { 69 | "data": data.toIso8601String(), 70 | "stato": stato, 71 | "ricoverati_con_sintomi": ricoveratiConSintomi, 72 | "terapia_intensiva": terapiaIntensiva, 73 | "totale_ospedalizzati": totaleOspedalizzati, 74 | "isolamento_domiciliare": isolamentoDomiciliare, 75 | "totale_positivi": totaleAttualmentePositivi, 76 | "variazione_totale_positivi": variazioneTotalePositivi, 77 | "nuovi_positivi": nuoviPositivi, 78 | "dimessi_guariti": dimessiGuariti, 79 | "deceduti": deceduti, 80 | "totale_casi": totaleCasi, 81 | "tamponi": tamponi, 82 | "note_it": noteIt, 83 | "note_en": noteEn, 84 | "codice_regione": codiceRegione == null ? null : codiceRegione, 85 | "denominazione_regione": denominazioneRegione == null ? null : denominazioneRegione, 86 | "lat": lat == null ? null : lat, 87 | "long": long == null ? null : long, 88 | }; 89 | } 90 | -------------------------------------------------------------------------------- /ios/Podfile: -------------------------------------------------------------------------------- 1 | # Uncomment this line to define a global platform for your project 2 | # platform :ios, '9.0' 3 | 4 | # CocoaPods analytics sends network stats synchronously affecting flutter build latency. 5 | ENV['COCOAPODS_DISABLE_STATS'] = 'true' 6 | 7 | project 'Runner', { 8 | 'Debug' => :debug, 9 | 'Profile' => :release, 10 | 'Release' => :release, 11 | } 12 | 13 | def parse_KV_file(file, separator='=') 14 | file_abs_path = File.expand_path(file) 15 | if !File.exists? file_abs_path 16 | return []; 17 | end 18 | generated_key_values = {} 19 | skip_line_start_symbols = ["#", "/"] 20 | File.foreach(file_abs_path) do |line| 21 | next if skip_line_start_symbols.any? { |symbol| line =~ /^\s*#{symbol}/ } 22 | plugin = line.split(pattern=separator) 23 | if plugin.length == 2 24 | podname = plugin[0].strip() 25 | path = plugin[1].strip() 26 | podpath = File.expand_path("#{path}", file_abs_path) 27 | generated_key_values[podname] = podpath 28 | else 29 | puts "Invalid plugin specification: #{line}" 30 | end 31 | end 32 | generated_key_values 33 | end 34 | 35 | target 'Runner' do 36 | use_frameworks! 37 | use_modular_headers! 38 | 39 | # Flutter Pod 40 | 41 | copied_flutter_dir = File.join(__dir__, 'Flutter') 42 | copied_framework_path = File.join(copied_flutter_dir, 'Flutter.framework') 43 | copied_podspec_path = File.join(copied_flutter_dir, 'Flutter.podspec') 44 | unless File.exist?(copied_framework_path) && File.exist?(copied_podspec_path) 45 | # Copy Flutter.framework and Flutter.podspec to Flutter/ to have something to link against if the xcode backend script has not run yet. 46 | # That script will copy the correct debug/profile/release version of the framework based on the currently selected Xcode configuration. 47 | # CocoaPods will not embed the framework on pod install (before any build phases can generate) if the dylib does not exist. 48 | 49 | generated_xcode_build_settings_path = File.join(copied_flutter_dir, 'Generated.xcconfig') 50 | unless File.exist?(generated_xcode_build_settings_path) 51 | raise "Generated.xcconfig must exist. If you're running pod install manually, make sure flutter pub get is executed first" 52 | end 53 | generated_xcode_build_settings = parse_KV_file(generated_xcode_build_settings_path) 54 | cached_framework_dir = generated_xcode_build_settings['FLUTTER_FRAMEWORK_DIR']; 55 | 56 | unless File.exist?(copied_framework_path) 57 | FileUtils.cp_r(File.join(cached_framework_dir, 'Flutter.framework'), copied_flutter_dir) 58 | end 59 | unless File.exist?(copied_podspec_path) 60 | FileUtils.cp(File.join(cached_framework_dir, 'Flutter.podspec'), copied_flutter_dir) 61 | end 62 | end 63 | 64 | # Keep pod path relative so it can be checked into Podfile.lock. 65 | pod 'Flutter', :path => 'Flutter' 66 | 67 | # Plugin Pods 68 | 69 | # Prepare symlinks folder. We use symlinks to avoid having Podfile.lock 70 | # referring to absolute paths on developers' machines. 71 | system('rm -rf .symlinks') 72 | system('mkdir -p .symlinks/plugins') 73 | plugin_pods = parse_KV_file('../.flutter-plugins') 74 | plugin_pods.each do |name, path| 75 | symlink = File.join('.symlinks', 'plugins', name) 76 | File.symlink(path, symlink) 77 | pod name, :path => File.join(symlink, 'ios') 78 | end 79 | end 80 | 81 | post_install do |installer| 82 | installer.pods_project.targets.each do |target| 83 | target.build_configurations.each do |config| 84 | config.build_settings['ENABLE_BITCODE'] = 'NO' 85 | end 86 | end 87 | end 88 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 39 | 40 | 41 | 42 | 43 | 44 | 54 | 56 | 62 | 63 | 64 | 65 | 66 | 67 | 73 | 75 | 81 | 82 | 83 | 84 | 86 | 87 | 90 | 91 | 92 | -------------------------------------------------------------------------------- /lib/chart/italy_chart.dart: -------------------------------------------------------------------------------- 1 | import 'package:covid19/chart/chart.dart'; 2 | import 'package:covid19/chart/chart_label.dart'; 3 | import 'package:covid19/model/pcm.dart'; 4 | import 'package:covid19/view/single_int_report.dart'; 5 | import 'package:fl_chart/fl_chart.dart'; 6 | import 'package:flutter/material.dart'; 7 | 8 | class ItalyStatsPieChart extends StatefulWidget { 9 | final Nazionale stats; 10 | ItalyStatsPieChart({Key key, this.stats}) : super(key: key); 11 | @override 12 | _ItalyStatsPieChart createState() => _ItalyStatsPieChart(); 13 | } 14 | 15 | class _ItalyStatsPieChart extends State { 16 | 17 | int touchedIndex; 18 | 19 | @override 20 | Widget build(BuildContext context) { 21 | Percent1M perc = Percent1M(widget.stats); 22 | List widgets = [ 23 | ChartLabel( 24 | color: SingleIntReportView.colors[0], 25 | label: SingleIntReportView.active, 26 | percent: perc.activePerc, 27 | ), 28 | SizedBox( 29 | height: 10, 30 | ), 31 | ChartLabel( 32 | color: SingleIntReportView.colors[1], 33 | label: SingleIntReportView.recovered, 34 | percent: perc.recoveredPerc, 35 | ), 36 | ChartLabel( 37 | color: SingleIntReportView.colors[2], 38 | label: SingleIntReportView.deaths, 39 | percent: perc.deathPerc, 40 | ), 41 | ]; 42 | 43 | return Container( 44 | child: Card( 45 | elevation: 0.0, 46 | color: Colors.grey[50], 47 | child: Column( 48 | children: [ 49 | Row( 50 | children: [ 51 | const SizedBox( 52 | height: 25, 53 | ), 54 | Expanded( 55 | child: PieChart( 56 | PieChartData( 57 | pieTouchData: 58 | PieTouchData(touchCallback: (pieTouchResponse) { 59 | setState(() { 60 | if (pieTouchResponse.touchInput is FlLongPressEnd || 61 | pieTouchResponse.touchInput is FlPanEnd) { 62 | touchedIndex = -1; 63 | } else { 64 | touchedIndex = 65 | pieTouchResponse.touchedSectionIndex; 66 | } 67 | }); 68 | }), 69 | borderData: FlBorderData( 70 | show: false, 71 | ), 72 | sectionsSpace: 2, 73 | centerSpaceRadius: 30, 74 | sections: showingSections(touchedIndex, widget.stats.totaleAttualmentePositivi, widget.stats.deceduti, widget.stats.dimessiGuariti)), 75 | ), 76 | ), 77 | Column( 78 | crossAxisAlignment: CrossAxisAlignment.start, 79 | children: widgets, 80 | ), 81 | const SizedBox( 82 | width: 25, 83 | ), 84 | ], 85 | ), 86 | ], 87 | ), 88 | ), 89 | ); 90 | } 91 | 92 | } 93 | 94 | class Percent1M { 95 | Nazionale report; 96 | double deathPerc, recoveredPerc, activePerc; 97 | 98 | Percent1M(Nazionale _report) { 99 | this.report = _report; 100 | deathPerc = (report.deceduti / (report.totaleCasi)) * 100; 101 | recoveredPerc = (report.dimessiGuariti / (report.totaleCasi)) * 100; 102 | activePerc = (report.totaleAttualmentePositivi / (report.totaleCasi)) * 100; 103 | } 104 | } 105 | -------------------------------------------------------------------------------- /lib/view/single_usa_states_report.dart: -------------------------------------------------------------------------------- 1 | import 'package:covid19/chart/chart.dart'; 2 | import 'package:covid19/model/novel_covid.dart'; 3 | import 'package:covid19/view/single_int_report.dart'; 4 | import 'package:flutter/foundation.dart'; 5 | import 'package:flutter/material.dart'; 6 | 7 | class SingleUSAStatesReportView extends StatefulWidget { 8 | static const routeName = '/singleUSAStatesReportView'; 9 | final States state; 10 | SingleUSAStatesReportView({Key key, @required this.state}) : super(key: key); 11 | @override 12 | _SingleUSAStatesReportViewState createState() => 13 | _SingleUSAStatesReportViewState(); 14 | } 15 | 16 | class _SingleUSAStatesReportViewState extends State { 17 | @override 18 | Widget build(BuildContext context) { 19 | return OrientationBuilder(builder: (context, orientation) { 20 | final isLargeScreen = MediaQuery.of(context).size.width > 600; 21 | return Scaffold( 22 | backgroundColor: Colors.grey[50], 23 | appBar: AppBar( 24 | leading: isLargeScreen ? new Container() : null, 25 | title: Text(widget.state.state), 26 | backgroundColor: Colors.white, 27 | elevation: 1.0, 28 | iconTheme: IconThemeData(color: Colors.black), 29 | centerTitle: true, 30 | ), 31 | body: SafeArea( 32 | child: SingleChildScrollView( 33 | child: Container( 34 | color: Colors.grey[50], 35 | child: Column( 36 | mainAxisAlignment: MainAxisAlignment.spaceEvenly, 37 | children: [ 38 | Details(state: widget.state), 39 | StatsPieChart(stats: Country.fromStates(widget.state)), 40 | ]))))); 41 | }); 42 | } 43 | } 44 | 45 | class Details extends StatelessWidget { 46 | final States state; 47 | 48 | Details({ 49 | this.state, 50 | }); 51 | 52 | @override 53 | Widget build(BuildContext context) { 54 | // 55 | List children = [ 56 | Container( 57 | child: Row( 58 | mainAxisAlignment: MainAxisAlignment.center, 59 | children: [ 60 | createDetailItem( 61 | context: context, 62 | color: SingleIntReportView.colors[0], 63 | value: state.active, 64 | text: SingleIntReportView.active), 65 | ], 66 | ), 67 | ), 68 | Container( 69 | child: Row( 70 | mainAxisAlignment: MainAxisAlignment.center, 71 | children: [ 72 | createDetailItem( 73 | context: context, 74 | color: SingleIntReportView.colors[1], 75 | value: state.cases - state.active - state.deaths, 76 | text: SingleIntReportView.recovered), 77 | ], 78 | ), 79 | ), 80 | Container( 81 | child: Row( 82 | mainAxisAlignment: MainAxisAlignment.center, 83 | children: [ 84 | createDetailItem( 85 | context: context, 86 | color: SingleIntReportView.colors[2], 87 | value: state.deaths, 88 | text: SingleIntReportView.deaths, 89 | todaysUpdate: state.todayDeaths, 90 | ), 91 | ], 92 | ), 93 | ), 94 | Container( 95 | child: Row( 96 | mainAxisAlignment: MainAxisAlignment.center, 97 | children: [ 98 | createDetailItem( 99 | context: context, 100 | colors: SingleIntReportView.colors, 101 | value: state.cases, 102 | todaysUpdate: state.todayCases, 103 | text: SingleIntReportView.cases), 104 | ], 105 | ), 106 | ), 107 | ]; 108 | return Padding( 109 | padding: const EdgeInsets.fromLTRB(8.0, 20.0, 8.0, 8.0), 110 | child: Container( 111 | child: Column( 112 | children: children, 113 | ), 114 | ), 115 | ); 116 | } 117 | } 118 | -------------------------------------------------------------------------------- /lib/service/service.dart: -------------------------------------------------------------------------------- 1 | import 'dart:convert'; 2 | 3 | import 'package:covid19/model/novel_covid.dart'; 4 | import 'package:covid19/model/pcm.dart'; 5 | import 'package:covid19/view/list_ita_regioni.dart'; 6 | import 'package:covid19/view/list_usa_states.dart'; 7 | import 'package:covid19/view/single_int_report.dart'; 8 | import 'package:http/http.dart'; 9 | import 'package:intl/intl.dart'; 10 | 11 | // 12 | //final String novelCovid = "https://corona.lmao.ninja/"; 13 | final String novelCovidV2 = "https://corona.lmao.ninja/v2/"; 14 | final String dpc = 15 | "https://raw.githubusercontent.com/pcm-dpc/COVID-19/master/dati-json/"; 16 | // 17 | Future getNazionaleLatest() async { 18 | Nazionale result = Nazionale(); 19 | List temp = []; 20 | try { 21 | Response response = 22 | await get(dpc + "dpc-covid19-ita-andamento-nazionale-latest.json"); 23 | List data = jsonDecode(response.body); 24 | temp = data.map((i) => Nazionale.fromJson(i)).toList(); 25 | result = temp.first; 26 | } catch (e) { 27 | print( 28 | "\n>>>>>>GET NAZIONALE ELATEST RROR>>>>>>>\n$e\n<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<"); 29 | } 30 | return result; 31 | } 32 | 33 | // 34 | Future> getRegionaleLatest() async { 35 | List result = []; 36 | try { 37 | Response response = await get(dpc + "dpc-covid19-ita-regioni-latest.json"); 38 | List data = jsonDecode(response.body); 39 | result = data.map((i) => Nazionale.fromJson(i)).toList(); 40 | if (result.length > 1) { 41 | Nazionale italia = 42 | Nazionale(denominazioneRegione: ListITARegioniView.tutteLeRegioni); 43 | result.insert(0, italia); 44 | } 45 | } catch (e) { 46 | print( 47 | "\n>>>>>>GET REGIONALE ERROR>>>>>>>\n$e\n<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<"); 48 | } 49 | return result; 50 | } 51 | 52 | // 53 | Future> getCountries() async { 54 | List result = []; 55 | try { 56 | Response response = await get(novelCovidV2 + "countries"); 57 | List data = jsonDecode(response.body); 58 | result = data.map((i) => Country.fromJson(i)).toList(); 59 | if (result.length > 1) { 60 | if (result.first.country != SingleIntReportView.allCountries) { 61 | Country allCountry = Country( 62 | country: SingleIntReportView.allCountries, 63 | cases: 0, 64 | todayCases: 0, 65 | deaths: 0, 66 | todayDeaths: 0, 67 | recovered: 0, 68 | active: 0, 69 | critical: 0); 70 | for (Country country in result) { 71 | allCountry.cases += country.cases ?? 0; 72 | allCountry.todayCases += country.todayCases ?? 0; 73 | allCountry.deaths += country.deaths ?? 0; 74 | allCountry.todayDeaths += country.todayDeaths ?? 0; 75 | allCountry.recovered += country.recovered ?? 0; 76 | allCountry.active += country.active ?? 0; 77 | allCountry.critical += country.critical ?? 0; 78 | } 79 | result.insert(0, allCountry); 80 | } 81 | } 82 | result.sort((a, b) => b.cases.compareTo(a.cases)); 83 | } catch (e) { 84 | print( 85 | "\n>>>>>>GET COUNTRIES ERROR>>>>>>>\n$e\n<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<"); 86 | } 87 | return result; 88 | } 89 | 90 | // 91 | Future> getStates() async { 92 | List result = []; 93 | try { 94 | Response response = await get(novelCovidV2 + "states"); 95 | List data = jsonDecode(response.body); 96 | result = data.map((i) => States.fromJson(i)).toList(); 97 | if (result.length > 1) { 98 | States allStates = States(state: ListUSAStatesView.tuttiGliStati); 99 | result.insert(0, allStates); 100 | } 101 | } catch (e) { 102 | print( 103 | "\n>>>>>>GET STATES ERROR>>>>>>>\n$e\n<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<"); 104 | } 105 | return result; 106 | } 107 | 108 | Future getCountryHistorical(String countryName) async { 109 | if (countryName == SingleIntReportView.allCountries) { 110 | return null; 111 | } 112 | try { 113 | Response response = await get(novelCovidV2 + "historical/" + countryName); 114 | dynamic data = jsonDecode(response.body); 115 | 116 | Map cases = data["timeline"]["cases"]; 117 | Map deaths = data["timeline"]["deaths"]; 118 | return new CountryTrend( 119 | cases: cases.map(_history), 120 | deaths: deaths.map(_history), 121 | ); 122 | } catch (e) { 123 | print( 124 | "\n>>>>>>GET COUNTRY HISTORICAL ERROR>>>>>>>\n$e\n<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<"); 125 | return CountryTrend( 126 | cases: {}, 127 | deaths: {}, 128 | ); 129 | } 130 | } 131 | 132 | // 133 | final DateFormat format = new DateFormat("MM/dd/yy"); 134 | 135 | MapEntry _history(String dateString, dynamic count) { 136 | return MapEntry(format.parse(dateString), count.toInt()); 137 | } 138 | -------------------------------------------------------------------------------- /lib/view/list_usa_states.dart: -------------------------------------------------------------------------------- 1 | import 'package:covid19/layout/master_detail_usa.dart'; 2 | import 'package:covid19/model/novel_covid.dart'; 3 | import 'package:covid19/service/service.dart'; 4 | import 'package:covid19/view/list_all_countries.dart'; 5 | import 'package:flutter/material.dart'; 6 | import 'package:liquid_pull_to_refresh/liquid_pull_to_refresh.dart'; 7 | 8 | typedef Null ItemSelectedCallback(States value); 9 | 10 | class ListUSAStatesView extends StatefulWidget { 11 | static const routeName = '/listUSAStatesView'; 12 | static const tuttiGliStati = 'All States'; 13 | final ItemSelectedCallback onItemSelected; 14 | final Country country; 15 | 16 | ListUSAStatesView( 17 | this.onItemSelected, 18 | this.country, 19 | ); 20 | 21 | @override 22 | _ListUSAStatesViewState createState() => _ListUSAStatesViewState(); 23 | } 24 | 25 | class _ListUSAStatesViewState extends State 26 | with TickerProviderStateMixin { 27 | List _states, _newstates; 28 | final GlobalKey _refreshIndicatorKey = GlobalKey(); 29 | 30 | @override 31 | void initState() { 32 | super.initState(); 33 | WidgetsBinding.instance.addPostFrameCallback((_) { 34 | (_refreshIndicatorKey.currentState as dynamic)?.show(); 35 | }); 36 | _getStates(); 37 | } 38 | 39 | Future _getStates() async { 40 | List temp = await getStates(); 41 | setState(() { 42 | _states = temp; 43 | _newstates = _states; 44 | }); 45 | } 46 | 47 | @override 48 | Widget build(BuildContext context) { 49 | return _states != null 50 | ? Scaffold( 51 | backgroundColor: Colors.white, 52 | appBar: AppBar( 53 | title: Text( 54 | MasterDetailPageUSA.countryName, 55 | style: TextStyle(color: Colors.black), 56 | ), 57 | centerTitle: true, 58 | backgroundColor: Colors.white, 59 | iconTheme: IconThemeData(color: Colors.black), 60 | elevation: 1.0, 61 | ), 62 | body: Column( 63 | children: [ 64 | Container( 65 | padding: EdgeInsets.all(24.0), 66 | child: Row( 67 | children: [ 68 | Expanded( 69 | child: TextField( 70 | decoration: InputDecoration( 71 | fillColor: Colors.blue, 72 | border: OutlineInputBorder(), 73 | labelText: ListCountryView.search, 74 | suffixIcon: Icon(Icons.search), 75 | ), 76 | onChanged: (text) { 77 | setState(() { 78 | _newstates = _states 79 | .where((r) => (r.state 80 | .toLowerCase() 81 | .contains(text.trim().toLowerCase()))) 82 | .toList(); 83 | }); 84 | }, 85 | ), 86 | ) 87 | ], 88 | ), 89 | ), 90 | Expanded( 91 | child: LiquidPullToRefresh( 92 | springAnimationDurationInMilliseconds: 500, 93 | key: _refreshIndicatorKey, 94 | showChildOpacityTransition: false, 95 | onRefresh: _getStates, 96 | child: ListView.builder( 97 | padding: EdgeInsets.symmetric(horizontal: 16.0), 98 | itemCount: _newstates.length, 99 | itemBuilder: (BuildContext context, int index) { 100 | Widget leading = _newstates[index].state == 101 | ListUSAStatesView.tuttiGliStati 102 | ? Image.asset( 103 | "assets/us.png", 104 | height: 24, 105 | ) 106 | : null; 107 | return Card( 108 | elevation: 1, 109 | color: Colors.grey[50], 110 | child: ListTile( 111 | onTap: () { 112 | widget.onItemSelected(_newstates[index]); 113 | }, 114 | leading: leading, 115 | title: Text(_newstates[index].state), 116 | trailing: Icon(Icons.keyboard_arrow_right), 117 | ), 118 | ); 119 | }, 120 | ), 121 | ), 122 | ) 123 | ], 124 | )) 125 | : Scaffold( 126 | body: Center( 127 | child: CircularProgressIndicator(), 128 | ), 129 | ); 130 | } 131 | } 132 | -------------------------------------------------------------------------------- /lib/chart/chart.dart: -------------------------------------------------------------------------------- 1 | import 'package:covid19/chart/chart_label.dart'; 2 | import 'package:covid19/model/novel_covid.dart'; 3 | import 'package:covid19/view/single_int_report.dart'; 4 | import 'package:fl_chart/fl_chart.dart'; 5 | import 'package:flutter/material.dart'; 6 | 7 | class StatsPieChart extends StatefulWidget { 8 | final Country stats; 9 | StatsPieChart({Key key, final this.stats}) : super(key: key); 10 | @override 11 | _StatsPieChartState createState() => _StatsPieChartState(); 12 | } 13 | 14 | class _StatsPieChartState extends State { 15 | int touchedIndex; 16 | 17 | @override 18 | Widget build(BuildContext context) { 19 | Percent1M perc = new Percent1M(widget.stats); 20 | List widgets = [ 21 | ChartLabel( 22 | color: SingleIntReportView.colors[0], 23 | label: SingleIntReportView.active, 24 | percent: perc.activePerc, 25 | ), 26 | ChartLabel( 27 | color: SingleIntReportView.colors[1], 28 | label: SingleIntReportView.recovered, 29 | percent: perc.recoveredPerc, 30 | ), 31 | ChartLabel( 32 | color: SingleIntReportView.colors[2], 33 | label: SingleIntReportView.deaths, 34 | percent: perc.deathPerc, 35 | ), 36 | ]; 37 | 38 | return Container( 39 | child: Card( 40 | elevation: 0.0, 41 | color: Colors.grey[50], 42 | child: Column( 43 | children: [ 44 | Row( 45 | children: [ 46 | const SizedBox( 47 | height: 25, 48 | ), 49 | Expanded( 50 | child: PieChart( 51 | PieChartData( 52 | pieTouchData: 53 | PieTouchData(touchCallback: (pieTouchResponse) { 54 | setState(() { 55 | if (pieTouchResponse.touchInput is FlLongPressEnd || 56 | pieTouchResponse.touchInput is FlPanEnd) { 57 | touchedIndex = -1; 58 | } else { 59 | touchedIndex = 60 | pieTouchResponse.touchedSectionIndex; 61 | } 62 | }); 63 | }), 64 | borderData: FlBorderData( 65 | show: false, 66 | ), 67 | sectionsSpace: 0, 68 | centerSpaceRadius: 30, 69 | sections: showingSections(touchedIndex, widget.stats.active, widget.stats.deaths, widget.stats.recovered)), 70 | ), 71 | ), 72 | Column( 73 | crossAxisAlignment: CrossAxisAlignment.start, 74 | children: widgets, 75 | ), 76 | const SizedBox( 77 | width: 25, 78 | ), 79 | ], 80 | ), 81 | ], 82 | ), 83 | ), 84 | ); 85 | } 86 | 87 | } 88 | 89 | List showingSections(int touchedIndex, int active, int deaths, int recovered) { 90 | return List.generate(recovered == null ? 2 : 3, (i) { 91 | final isTouched = i == touchedIndex; 92 | final double fontSize = isTouched ? 25 : 16; 93 | final double radius = isTouched ? 60 : 50; 94 | switch (i) { 95 | case 0: 96 | return PieChartSectionData( 97 | color: SingleIntReportView.colors[2], 98 | value: deaths + 0.0, 99 | title: '', 100 | radius: radius, 101 | titleStyle: TextStyle( 102 | fontSize: fontSize, 103 | fontWeight: FontWeight.bold, 104 | color: Colors.white), 105 | ); 106 | case 1: 107 | return PieChartSectionData( 108 | color: SingleIntReportView.colors[0], 109 | value: active + 0.0, 110 | title: '', 111 | radius: radius, 112 | titleStyle: TextStyle( 113 | fontSize: fontSize, 114 | fontWeight: FontWeight.bold, 115 | color: Colors.white), 116 | ); 117 | case 2: 118 | return PieChartSectionData( 119 | color: SingleIntReportView.colors[1], 120 | value: recovered + 0.0, 121 | title: '', 122 | radius: radius, 123 | titleStyle: TextStyle( 124 | fontSize: fontSize, 125 | fontWeight: FontWeight.bold, 126 | color: Colors.white), 127 | ); 128 | default: 129 | return null; 130 | } 131 | }); 132 | } 133 | 134 | class Percent1M { 135 | Country report; 136 | double deathPerc, recoveredPerc, activePerc; 137 | 138 | Percent1M(Country _report) { 139 | this.report = _report; 140 | deathPerc = (report.deaths / (report.cases)) * 100; 141 | recoveredPerc = (report.recovered / (report.cases)) * 100; 142 | activePerc = (report.active / (report.cases)) * 100; 143 | } 144 | } 145 | -------------------------------------------------------------------------------- /lib/view/list_ita_regioni.dart: -------------------------------------------------------------------------------- 1 | import 'package:covid19/layout/master_detail_ita.dart'; 2 | import 'package:covid19/model/novel_covid.dart'; 3 | import 'package:covid19/model/pcm.dart'; 4 | import 'package:covid19/service/service.dart'; 5 | import 'package:flutter/material.dart'; 6 | import 'package:liquid_pull_to_refresh/liquid_pull_to_refresh.dart'; 7 | 8 | typedef Null ItemSelectedCallback(Nazionale value); 9 | 10 | class ListITARegioniView extends StatefulWidget { 11 | static const routeName = '/listITARegioniView'; 12 | static const tutteLeRegioni = 'Tutte le regioni'; 13 | static const search = 'Cerca'; 14 | final ItemSelectedCallback onItemSelected; 15 | final Country country; 16 | 17 | ListITARegioniView( 18 | this.onItemSelected, 19 | this.country, 20 | ); 21 | 22 | @override 23 | _ListITARegioniViewState createState() => _ListITARegioniViewState(); 24 | } 25 | 26 | class _ListITARegioniViewState extends State 27 | with TickerProviderStateMixin { 28 | List _regioni, _newregioni; 29 | final GlobalKey _refreshIndicatorKey = GlobalKey(); 30 | @override 31 | void initState() { 32 | super.initState(); 33 | WidgetsBinding.instance.addPostFrameCallback((_) { 34 | (_refreshIndicatorKey.currentState as dynamic)?.show(); 35 | }); 36 | _getRegionaleLatest(); 37 | } 38 | 39 | Future _getRegionaleLatest() async { 40 | List temp = await getRegionaleLatest(); 41 | setState(() { 42 | _regioni = temp; 43 | _newregioni = _regioni; 44 | }); 45 | } 46 | 47 | @override 48 | Widget build(BuildContext context) { 49 | return _regioni != null 50 | ? Scaffold( 51 | backgroundColor: Colors.white, 52 | appBar: AppBar( 53 | title: Text( 54 | MasterDetailPageITA.countryName, 55 | style: TextStyle(color: Colors.black), 56 | ), 57 | centerTitle: true, 58 | backgroundColor: Colors.white, 59 | iconTheme: IconThemeData(color: Colors.black), 60 | elevation: 1.0, 61 | ), 62 | body: Column( 63 | children: [ 64 | Container( 65 | padding: EdgeInsets.all(24.0), 66 | child: Row( 67 | children: [ 68 | Expanded( 69 | child: TextField( 70 | decoration: InputDecoration( 71 | fillColor: Colors.blue, 72 | border: OutlineInputBorder(), 73 | labelText: ListITARegioniView.search, 74 | suffixIcon: Icon(Icons.search), 75 | ), 76 | onChanged: (text) { 77 | setState(() { 78 | _newregioni = _regioni 79 | .where((r) => (r.denominazioneRegione 80 | .toLowerCase() 81 | .contains(text.trim().toLowerCase()))) 82 | .toList(); 83 | }); 84 | }, 85 | ), 86 | ) 87 | ], 88 | ), 89 | ), 90 | Expanded( 91 | child: LiquidPullToRefresh( 92 | springAnimationDurationInMilliseconds: 500, 93 | key: _refreshIndicatorKey, 94 | showChildOpacityTransition: false, 95 | onRefresh: _getRegionaleLatest, 96 | child: ListView.builder( 97 | padding: EdgeInsets.symmetric(horizontal: 16.0), 98 | itemCount: _newregioni.length, 99 | itemBuilder: (BuildContext context, int index) { 100 | Widget leading = 101 | _newregioni[index].denominazioneRegione == 102 | ListITARegioniView.tutteLeRegioni 103 | ? Image.asset( 104 | "assets/it.png", 105 | height: 24, 106 | ) 107 | : null; 108 | return Card( 109 | elevation: 1, 110 | color: Colors.grey[50], 111 | child: ListTile( 112 | onTap: () { 113 | widget.onItemSelected(_newregioni[index]); 114 | }, 115 | leading: leading, 116 | title: 117 | Text(_newregioni[index].denominazioneRegione), 118 | trailing: Icon(Icons.keyboard_arrow_right), 119 | ), 120 | ); 121 | }, 122 | ), 123 | ), 124 | ) 125 | ], 126 | )) 127 | : Scaffold( 128 | body: Center( 129 | child: CircularProgressIndicator(), 130 | ), 131 | ); 132 | } 133 | } 134 | -------------------------------------------------------------------------------- /lib/view/list_all_countries.dart: -------------------------------------------------------------------------------- 1 | import 'package:covid19/model/novel_covid.dart'; 2 | import 'package:covid19/model/utils.dart'; 3 | import 'package:covid19/service/service.dart'; 4 | import 'package:flutter/material.dart'; 5 | import 'package:liquid_pull_to_refresh/liquid_pull_to_refresh.dart'; 6 | 7 | typedef Null ItemSelectedCallback(Country value); 8 | 9 | class ListCountryView extends StatefulWidget { 10 | static const search = 'Search'; 11 | final ItemSelectedCallback onItemSelected; 12 | 13 | ListCountryView( 14 | this.onItemSelected, 15 | ); 16 | 17 | @override 18 | _ListCountryViewState createState() => _ListCountryViewState(); 19 | } 20 | 21 | class _ListCountryViewState extends State 22 | with TickerProviderStateMixin { 23 | List _allCountries, _countries; 24 | final GlobalKey _refreshIndicatorKey = GlobalKey(); 25 | 26 | @override 27 | void initState() { 28 | super.initState(); 29 | WidgetsBinding.instance.addPostFrameCallback((_) { 30 | (_refreshIndicatorKey.currentState as dynamic)?.show(); 31 | }); 32 | _getCountries(); 33 | } 34 | 35 | Future _getCountries() async { 36 | setState(() { 37 | _countries = []; 38 | }); 39 | List temp = await getCountries(); 40 | setState(() { 41 | _allCountries = temp; 42 | _countries = _allCountries; 43 | }); 44 | } 45 | 46 | @override 47 | Widget build(BuildContext context) { 48 | return _allCountries != null 49 | ? Scaffold( 50 | backgroundColor: Colors.white, 51 | appBar: AppBar( 52 | title: Text( 53 | 'Covid-19', 54 | style: TextStyle(color: Colors.black), 55 | ), 56 | centerTitle: true, 57 | backgroundColor: Colors.white, 58 | iconTheme: IconThemeData(color: Colors.black), 59 | elevation: 1.0, 60 | ), 61 | body: Column( 62 | children: [ 63 | Container( 64 | padding: EdgeInsets.all(24.0), 65 | child: Row( 66 | children: [ 67 | Expanded( 68 | child: TextField( 69 | decoration: InputDecoration( 70 | fillColor: Colors.blue, 71 | border: OutlineInputBorder(), 72 | labelText: ListCountryView.search, 73 | suffixIcon: Icon(Icons.search), 74 | ), 75 | onChanged: (text) { 76 | setState(() { 77 | _countries = _allCountries 78 | .where((r) => (r.country 79 | .toLowerCase() 80 | .contains(text.trim().toLowerCase()))) 81 | .toList(); 82 | }); 83 | }, 84 | ), 85 | ) 86 | ], 87 | ), 88 | ), 89 | Expanded( 90 | child: LiquidPullToRefresh( 91 | springAnimationDurationInMilliseconds: 500, 92 | key: _refreshIndicatorKey, 93 | showChildOpacityTransition: false, 94 | onRefresh: _getCountries, 95 | child: ListView.builder( 96 | padding: EdgeInsets.symmetric(horizontal: 16.0), 97 | itemCount: _countries.length, 98 | itemBuilder: (BuildContext context, int index) { 99 | Widget leading = Icon( 100 | Icons.public, 101 | color: Colors.blue[800], 102 | size: 36, 103 | ); 104 | if (_countries[index].countryInfo != null && 105 | util.url(_countries[index].countryInfo.flag) && 106 | _countries[index].country != "World") { 107 | leading = Image.asset( 108 | "assets/" + 109 | _countries[index].countryInfo.flag.split( 110 | "https://corona.lmao.ninja/assets/img/flags/")[1], 111 | height: 24, 112 | ); 113 | } 114 | return Card( 115 | elevation: 1, 116 | color: Colors.grey[50], 117 | child: ListTile( 118 | onTap: () { 119 | widget.onItemSelected(_countries[index]); 120 | }, 121 | leading: leading, 122 | title: Text(_countries[index].country), 123 | trailing: Icon(Icons.keyboard_arrow_right), 124 | ), 125 | ); 126 | }, 127 | ), 128 | ), 129 | ) 130 | ], 131 | ), 132 | ) 133 | : Scaffold( 134 | body: Center( 135 | child: CircularProgressIndicator(), 136 | ), 137 | ); 138 | } 139 | } 140 | -------------------------------------------------------------------------------- /lib/model/novel_covid.dart: -------------------------------------------------------------------------------- 1 | import 'package:covid19/model/utils.dart'; 2 | 3 | 4 | 5 | class All { 6 | int cases; 7 | int deaths; 8 | int recovered; 9 | int updated; 10 | int active; 11 | 12 | All({ 13 | this.cases, 14 | this.deaths, 15 | this.recovered, 16 | this.updated, 17 | this.active, 18 | }); 19 | 20 | factory All.fromJson(Map json) => All( 21 | cases: json["cases"], 22 | deaths: json["deaths"], 23 | recovered: json["recovered"], 24 | updated: json["updated"], 25 | active: json["active"], 26 | ); 27 | 28 | Map toJson() => { 29 | "cases": cases, 30 | "deaths": deaths, 31 | "recovered": recovered, 32 | "updated": updated, 33 | "active": active, 34 | }; 35 | } 36 | 37 | class Country { 38 | String country; 39 | CountryInfo countryInfo; 40 | int cases; 41 | int todayCases; 42 | int deaths; 43 | int todayDeaths; 44 | int recovered; 45 | int active; 46 | dynamic critical; 47 | dynamic casesPerOneMillion; 48 | dynamic deathsPerOneMillion; 49 | 50 | Country({ 51 | this.country, 52 | this.countryInfo, 53 | this.cases, 54 | this.todayCases, 55 | this.deaths, 56 | this.todayDeaths, 57 | this.recovered, 58 | this.active, 59 | this.critical, 60 | this.casesPerOneMillion, 61 | this.deathsPerOneMillion, 62 | }); 63 | 64 | factory Country.fromJson(Map json) => Country( 65 | country: json["country"], 66 | countryInfo: CountryInfo.fromJson(json["countryInfo"]), 67 | cases: json["cases"], 68 | todayCases: json["todayCases"], 69 | deaths: json["deaths"], 70 | todayDeaths: json["todayDeaths"], 71 | recovered: json["recovered"], 72 | active: json["active"], 73 | critical: json["critical"], 74 | casesPerOneMillion: util.perOneMillionToString(json["casesPerOneMillion"]), 75 | deathsPerOneMillion: util.perOneMillionToString(json["deathsPerOneMillion"]), 76 | ); 77 | 78 | factory Country.fromStates(States state) => Country( 79 | cases: state.cases, 80 | todayCases: state.todayCases, 81 | deaths: state.deaths, 82 | todayDeaths: state.todayDeaths, 83 | recovered: state.cases - state.deaths - state.active, 84 | active: state.active, 85 | ); 86 | 87 | Map toJson() => { 88 | "country": country, 89 | "countryInfo": countryInfo.toJson(), 90 | "cases": cases, 91 | "todayCases": todayCases, 92 | "deaths": deaths, 93 | "todayDeaths": todayDeaths, 94 | "recovered": recovered, 95 | "active": active, 96 | "critical": critical, 97 | "casesPerOneMillion": casesPerOneMillion, 98 | "deathsPerOneMillion": deathsPerOneMillion, 99 | }; 100 | } 101 | 102 | class CountryInfo { 103 | int id; 104 | double lat; 105 | double long; 106 | String flag; 107 | String iso3; 108 | String iso2; 109 | 110 | CountryInfo({ 111 | this.id, 112 | this.lat, 113 | this.long, 114 | this.flag, 115 | this.iso3, 116 | this.iso2, 117 | }); 118 | 119 | factory CountryInfo.fromJson(Map json) => CountryInfo( 120 | id: json["_id"], 121 | lat: json["lat"].toDouble(), 122 | long: json["long"].toDouble(), 123 | flag: json["flag"], 124 | iso3: json["iso3"], 125 | iso2: json["iso2"], 126 | ); 127 | 128 | Map toJson() => { 129 | "_id": id, 130 | "lat": lat, 131 | "long": long, 132 | "flag": flag, 133 | "iso3": iso3, 134 | "iso2": iso2, 135 | }; 136 | } 137 | 138 | class Historical { 139 | String country; 140 | dynamic province; 141 | Timeline timeline; 142 | 143 | Historical({ 144 | this.country, 145 | this.province, 146 | this.timeline, 147 | }); 148 | 149 | factory Historical.fromJson(Map json) => Historical( 150 | country: json["country"], 151 | province: json["province"], 152 | timeline: Timeline.fromJson(json["timeline"]), 153 | ); 154 | 155 | Map toJson() => { 156 | "country": country, 157 | "province": province, 158 | "timeline": timeline.toJson(), 159 | }; 160 | } 161 | 162 | class Timeline { 163 | Map cases; 164 | Map deaths; 165 | 166 | Timeline({ 167 | this.cases, 168 | this.deaths, 169 | }); 170 | 171 | factory Timeline.fromJson(Map json) => Timeline( 172 | cases: Map.from(json["cases"]).map((k, v) => MapEntry(k, v)), 173 | deaths: Map.from(json["deaths"]).map((k, v) => MapEntry(k, v)), 174 | ); 175 | 176 | Map toJson() => { 177 | "cases": Map.from(cases).map((k, v) => MapEntry(k, v)), 178 | "deaths": Map.from(deaths).map((k, v) => MapEntry(k, v)), 179 | }; 180 | } 181 | 182 | class States { 183 | String state; 184 | int cases; 185 | int todayCases; 186 | int deaths; 187 | int todayDeaths; 188 | int active; 189 | 190 | States({ 191 | this.state, 192 | this.cases, 193 | this.todayCases, 194 | this.deaths, 195 | this.todayDeaths, 196 | this.active, 197 | }); 198 | 199 | factory States.fromJson(Map json) => States( 200 | state: json["state"], 201 | cases: json["cases"], 202 | todayCases: json["todayCases"], 203 | deaths: json["deaths"], 204 | todayDeaths: json["todayDeaths"], 205 | active: json["active"], 206 | ); 207 | 208 | Map toJson() => { 209 | "state": state, 210 | "cases": cases, 211 | "todayCases": todayCases, 212 | "deaths": deaths, 213 | "todayDeaths": todayDeaths, 214 | "active": active, 215 | }; 216 | } 217 | 218 | class CountryTrend { 219 | Map cases; 220 | Map deaths; 221 | CountryTrend({this.cases, this.deaths}); 222 | 223 | factory CountryTrend.fromJson(Map json) => CountryTrend( 224 | cases: json["cases"], 225 | deaths: json["deaths"], 226 | ); 227 | 228 | 229 | } 230 | -------------------------------------------------------------------------------- /lib/view/single_ita_report.dart: -------------------------------------------------------------------------------- 1 | import 'package:covid19/chart/italy_chart.dart'; 2 | import 'package:covid19/model/novel_covid.dart'; 3 | import 'package:covid19/model/pcm.dart'; 4 | import 'package:covid19/service/service.dart'; 5 | import 'package:covid19/chart/lineChart.dart'; 6 | import 'package:covid19/view/list_ita_regioni.dart'; 7 | import 'package:covid19/view/single_int_report.dart'; 8 | import 'package:flutter/foundation.dart'; 9 | import 'package:flutter/material.dart'; 10 | 11 | class SingleITAReportView extends StatefulWidget { 12 | static const routeName = '/singleITAReportView'; 13 | 14 | static const active = "Attualmente positivi"; 15 | static const hospitalSymptomatic = "Ricoverati\ncon sintomi"; 16 | static const critical = "Terapia\nintensiva"; 17 | static const homeIsolation = "Isolamento\ndomiciliare"; 18 | static const recovered = "Dimessi / Guariti"; 19 | static const deaths = "Deceduti"; 20 | static const cases = "Casi totali"; 21 | static const cases1M = "Casi per milione"; 22 | static const deaths1M = "Deceduti per milione"; 23 | static const swabs = "Tamponi"; 24 | 25 | final Country country; 26 | SingleITAReportView({Key key, this.country}) : super(key: key); 27 | @override 28 | _SingleITAReportViewState createState() => _SingleITAReportViewState(); 29 | } 30 | 31 | class _SingleITAReportViewState extends State { 32 | Future _nazionale; 33 | 34 | @override 35 | void initState() { 36 | super.initState(); 37 | _nazionale = getNazionaleLatest(); 38 | } 39 | 40 | @override 41 | Widget build(BuildContext context) { 42 | return OrientationBuilder(builder: (context, orientation) { 43 | final isLargeScreen = MediaQuery.of(context).size.width > 600; 44 | return Scaffold( 45 | backgroundColor: Colors.grey[50], 46 | appBar: AppBar( 47 | leading: isLargeScreen ? new Container() : null, 48 | title: Text(isLargeScreen 49 | ? ListITARegioniView.tutteLeRegioni 50 | : widget.country.country), 51 | backgroundColor: Colors.white, 52 | elevation: 1.0, 53 | iconTheme: IconThemeData(color: Colors.black), 54 | centerTitle: true, 55 | ), 56 | body: SafeArea( 57 | child: SingleChildScrollView( 58 | child: Container( 59 | color: Colors.grey[50], 60 | child: FutureBuilder( 61 | future: _nazionale, 62 | builder: (context, snapshot) { 63 | if (snapshot.hasData) { 64 | final nazionale = snapshot.data; 65 | return Column( 66 | mainAxisAlignment: 67 | MainAxisAlignment.spaceEvenly, 68 | children: [ 69 | DetailITA( 70 | nazionale: nazionale, 71 | country: widget.country), 72 | ItalyStatsPieChart( 73 | stats: nazionale, 74 | ), 75 | TrendChart(country: widget.country.country, italy: true), 76 | ]); 77 | } else { 78 | return CircularProgressIndicator(); 79 | } 80 | }))))); 81 | }); 82 | } 83 | } 84 | 85 | class DetailITA extends StatelessWidget { 86 | final Nazionale nazionale; 87 | final Country country; 88 | 89 | DetailITA({ 90 | this.nazionale, 91 | this.country, 92 | }); 93 | 94 | @override 95 | Widget build(BuildContext context) { 96 | // 97 | final inner = Row( 98 | mainAxisAlignment: MainAxisAlignment.spaceAround, 99 | children: [ 100 | _createDetailInnerItem( 101 | context: context, 102 | value: nazionale.ricoveratiConSintomi, 103 | text: SingleITAReportView.hospitalSymptomatic), 104 | _createDetailInnerItem( 105 | context: context, 106 | value: nazionale.terapiaIntensiva, 107 | text: SingleITAReportView.critical), 108 | _createDetailInnerItem( 109 | context: context, 110 | value: nazionale.isolamentoDomiciliare, 111 | text: SingleITAReportView.homeIsolation), 112 | ], 113 | ); 114 | 115 | List children = [ 116 | Container( 117 | child: Row( 118 | mainAxisAlignment: MainAxisAlignment.center, 119 | children: [ 120 | createDetailItem( 121 | context: context, 122 | color: SingleIntReportView.colors[0], 123 | value: nazionale.totaleAttualmentePositivi, 124 | text: SingleITAReportView.active, 125 | todaysUpdate: nazionale.variazioneTotalePositivi, 126 | innerWidget: inner), 127 | ], 128 | ), 129 | ), 130 | Container( 131 | child: Row( 132 | mainAxisAlignment: MainAxisAlignment.center, 133 | children: [ 134 | createDetailItem( 135 | context: context, 136 | color: SingleIntReportView.colors[1], 137 | value: nazionale.dimessiGuariti, 138 | text: SingleITAReportView.recovered), 139 | ], 140 | ), 141 | ), 142 | Container( 143 | child: Row( 144 | mainAxisAlignment: MainAxisAlignment.center, 145 | children: [ 146 | createDetailItem( 147 | context: context, 148 | color: SingleIntReportView.colors[2], 149 | value: nazionale.deceduti, 150 | text: SingleITAReportView.deaths), 151 | ], 152 | ), 153 | ), 154 | Container( 155 | child: Row( 156 | mainAxisAlignment: MainAxisAlignment.center, 157 | children: [ 158 | createDetailItem( 159 | context: context, 160 | colors: SingleIntReportView.colors, 161 | value: nazionale.totaleCasi, 162 | todaysUpdate: nazionale.nuoviPositivi, 163 | text: SingleITAReportView.cases), 164 | ], 165 | ), 166 | ), 167 | country == null 168 | ? SizedBox() 169 | : Container( 170 | child: Row( 171 | mainAxisAlignment: MainAxisAlignment.center, 172 | children: [ 173 | createDetailItem( 174 | context: context, 175 | value: country.casesPerOneMillion, 176 | text: SingleITAReportView.cases1M), 177 | createDetailItem( 178 | context: context, 179 | value: country.deathsPerOneMillion, 180 | text: SingleITAReportView.deaths1M), 181 | ], 182 | ), 183 | ), 184 | Container( 185 | child: Row( 186 | mainAxisAlignment: MainAxisAlignment.center, 187 | children: [ 188 | createDetailItem( 189 | context: context, 190 | value: nazionale.tamponi, 191 | text: SingleITAReportView.swabs), 192 | ], 193 | ), 194 | ) 195 | ]; 196 | return Padding( 197 | padding: const EdgeInsets.fromLTRB(8.0, 20.0, 8.0, 8.0), 198 | child: Container( 199 | child: Column( 200 | children: children, 201 | ), 202 | ), 203 | ); 204 | } 205 | } 206 | 207 | Widget _createDetailInnerItem({ 208 | BuildContext context, 209 | dynamic value, 210 | String text, 211 | }) { 212 | return Padding( 213 | padding: const EdgeInsets.only(top: 16.0), 214 | child: Column( 215 | crossAxisAlignment: CrossAxisAlignment.start, 216 | children: [ 217 | Text( 218 | '$text', 219 | style: Theme.of(context).textTheme.caption, 220 | ), 221 | SizedBox( 222 | height: 5.0, 223 | ), 224 | Text( 225 | '${value ?? 0}', 226 | style: Theme.of(context) 227 | .textTheme 228 | .subtitle1 229 | .copyWith(fontWeight: FontWeight.bold), 230 | ), 231 | ], 232 | ), 233 | ); 234 | } 235 | -------------------------------------------------------------------------------- /lib/chart/lineChart.dart: -------------------------------------------------------------------------------- 1 | import 'package:covid19/model/novel_covid.dart'; 2 | import 'package:covid19/service/service.dart'; 3 | import 'package:covid19/view/single_int_report.dart'; 4 | import 'package:covid19/view/single_ita_report.dart'; 5 | import 'package:fl_chart/fl_chart.dart'; 6 | import 'package:flutter/material.dart'; 7 | import 'dart:math'; 8 | 9 | import 'package:intl/intl.dart'; 10 | 11 | class TrendChart extends StatefulWidget { 12 | final String country; 13 | final bool italy; 14 | TrendChart({Key key, @required this.country, @required this.italy}) 15 | : super(key: Key(country)); 16 | @override 17 | _TrendChart createState() => _TrendChart(); 18 | } 19 | 20 | class TrendData { 21 | Map data; 22 | Color color; 23 | String label; 24 | 25 | TrendData(this.data, this.color, this.label); 26 | } 27 | 28 | class _TrendChart extends State { 29 | Future _trend; 30 | 31 | List _trendData = List(); 32 | 33 | @override 34 | void initState() { 35 | super.initState(); 36 | _trend = getCountryHistorical(widget.country); 37 | } 38 | 39 | @override 40 | Widget build(BuildContext context) { 41 | return FutureBuilder( 42 | future: _trend, 43 | builder: (context, snapshot) { 44 | if (snapshot.hasData) { 45 | final trend = snapshot.data; 46 | if (trend == null || 47 | trend.deaths == null || 48 | trend.cases == null || 49 | trend.deaths.length == 0 || 50 | trend.cases.length == 0) { 51 | return SizedBox(); 52 | } else { 53 | _trendData.add(TrendData( 54 | trend.cases, 55 | SingleIntReportView.totColor, 56 | widget.italy 57 | ? SingleITAReportView.active 58 | : SingleIntReportView.active)); 59 | _trendData.add(TrendData( 60 | trend.deaths, 61 | SingleIntReportView.colors[2], 62 | widget.italy 63 | ? SingleITAReportView.deaths 64 | : SingleIntReportView.deaths)); 65 | return Padding( 66 | padding: EdgeInsets.only(left: 0.0, right: 20.0), 67 | child: AspectRatio( 68 | aspectRatio: 1.23, 69 | child: Container( 70 | decoration: BoxDecoration( 71 | borderRadius: const BorderRadius.all(Radius.circular(18)), 72 | ), 73 | child: Stack( 74 | children: [ 75 | Column( 76 | crossAxisAlignment: CrossAxisAlignment.stretch, 77 | children: [ 78 | const SizedBox( 79 | height: 37, 80 | ), 81 | Text( 82 | widget.italy 83 | ? "Andamento storico\n(ultimi 20 giorni)" 84 | : "Historical", 85 | style: Theme.of(context) 86 | .primaryTextTheme 87 | .subtitle2 88 | .copyWith( 89 | color: Colors.black, 90 | ), 91 | textAlign: TextAlign.center, 92 | ), 93 | const SizedBox( 94 | height: 37, 95 | ), 96 | Expanded( 97 | child: Padding( 98 | padding: const EdgeInsets.only( 99 | right: 30.0, left: 20.0), 100 | child: LineChart( 101 | trendData(trend), 102 | swapAnimationDuration: 103 | Duration(milliseconds: 250), 104 | ), 105 | ), 106 | ), 107 | const SizedBox( 108 | height: 10, 109 | ), 110 | ], 111 | ), 112 | ], 113 | ), 114 | ), 115 | ), 116 | ); 117 | } 118 | } else { 119 | return CircularProgressIndicator(); 120 | } 121 | }); 122 | } 123 | 124 | int startIndex(CountryTrend trend) { 125 | return max( 126 | trend.cases != null && trend.cases.length > 0 127 | ? trend.cases.values.length - 20 128 | : 0, 129 | 0); 130 | } 131 | 132 | LineChartData trendData(CountryTrend trend) { 133 | int maxCases = trend.cases.values.reduce(max); 134 | int rounded = ((maxCases + 999) ~/ 1000) * 1000; 135 | double verticalInterval = (rounded.toDouble() / 4.0); 136 | double horizontalInterval = 3.0; 137 | return LineChartData( 138 | minY: 0, 139 | maxY: rounded.toDouble(), 140 | lineTouchData: LineTouchData( 141 | touchTooltipData: LineTouchTooltipData( 142 | tooltipBgColor: Colors.blueGrey.withOpacity(0.8), 143 | getTooltipItems: (spots) { 144 | return spots 145 | .asMap() 146 | .map((index, spot) { 147 | return MapEntry( 148 | index, 149 | LineTooltipItem( 150 | "${_trendData[index].label} - ${spot.y.toInt()}", 151 | Theme.of(context) 152 | .textTheme 153 | .bodyText2 154 | .copyWith(color: _trendData[index].color))); 155 | }) 156 | .values 157 | .toList(); 158 | }, 159 | ), 160 | handleBuiltInTouches: true, 161 | ), 162 | titlesData: FlTitlesData( 163 | show: true, 164 | leftTitles: SideTitles( 165 | showTitles: true, 166 | interval: verticalInterval, 167 | getTitles: (value) { 168 | return "${NumberFormat.compact().format(value.toInt())}"; 169 | }, 170 | rotateAngle: 30.0), 171 | bottomTitles: SideTitles( 172 | interval: horizontalInterval, 173 | showTitles: true, 174 | getTitles: (value) { 175 | DateTime date = 176 | trend.cases.keys.toList()[startIndex(trend) + value.toInt()]; 177 | return widget.italy ? DateFormat("d/M").format(date) : DateFormat("M/d").format(date); 178 | }, 179 | rotateAngle: 30.0), 180 | ), 181 | gridData: FlGridData( 182 | show: true, 183 | verticalInterval: horizontalInterval, 184 | horizontalInterval: verticalInterval, 185 | ), 186 | borderData: FlBorderData( 187 | show: false, 188 | border: Border( 189 | bottom: BorderSide( 190 | color: const Color(0xff4e4965), 191 | width: 4, 192 | ), 193 | left: BorderSide( 194 | color: Colors.transparent, 195 | ), 196 | right: BorderSide( 197 | color: Colors.transparent, 198 | ), 199 | top: BorderSide( 200 | color: Colors.transparent, 201 | ), 202 | ), 203 | ), 204 | lineBarsData: _trendData 205 | .map((set) => _fromData(set.data, set.color, trend)) 206 | .toList(), 207 | ); 208 | } 209 | 210 | LineChartBarData _fromData( 211 | Map data, Color color, CountryTrend trend) { 212 | var listData = List(); 213 | data.values 214 | .toList() 215 | .sublist(startIndex(trend)) 216 | .asMap() 217 | .forEach((index, value) { 218 | listData.add(FlSpot(index.toDouble(), value.toDouble())); 219 | }); 220 | if (listData.isEmpty) { 221 | listData.add(FlSpot(0.0, 0.0)); 222 | } 223 | return LineChartBarData( 224 | spots: listData, 225 | isCurved: true, 226 | colors: [ 227 | color, 228 | ], 229 | barWidth: 4, 230 | isStrokeCapRound: true, 231 | dotData: FlDotData(show: true, dotColor: color), 232 | ); 233 | } 234 | } 235 | -------------------------------------------------------------------------------- /lib/view/single_int_report.dart: -------------------------------------------------------------------------------- 1 | import 'package:covid19/model/novel_covid.dart'; 2 | import 'package:covid19/chart/chart.dart'; 3 | import 'package:covid19/chart/lineChart.dart'; 4 | import 'package:flutter/material.dart'; 5 | 6 | class SingleIntReportView extends StatefulWidget { 7 | static const routeName = '/singleIntReportView'; 8 | static const String allCountries = "World"; 9 | 10 | static const active = "Active"; 11 | static const critical = "Critical"; 12 | static const recovered = "Recovered"; 13 | static const deaths = "Deaths"; 14 | static const cases = "Cases"; 15 | static const cases1M = "Cases per million"; 16 | static const deaths1M = "Deaths per million"; 17 | 18 | static List colors = [ 19 | Colors.yellow[500], 20 | Colors.green[400], 21 | Colors.red[400], 22 | ]; 23 | static Color totColor = Colors.orange[400]; 24 | 25 | final Country country; 26 | SingleIntReportView({Key key, final this.country}) : super(key: key); 27 | @override 28 | _SingleIntReportViewState createState() => _SingleIntReportViewState(); 29 | } 30 | 31 | class _SingleIntReportViewState extends State { 32 | @override 33 | Widget build(BuildContext context) { 34 | return OrientationBuilder(builder: (context, orientation) { 35 | final isLargeScreen = MediaQuery.of(context).size.width > 600; 36 | return Scaffold( 37 | backgroundColor: Colors.grey[50], 38 | appBar: AppBar( 39 | leading: isLargeScreen ? new Container() : null, 40 | title: Text('${widget.country.country}'), 41 | actions: [], 42 | backgroundColor: Colors.white, 43 | elevation: 1.0, 44 | iconTheme: IconThemeData(color: Colors.black), 45 | centerTitle: true, 46 | ), 47 | body: SafeArea( 48 | child: SingleChildScrollView( 49 | child: Container( 50 | color: Colors.grey[50], 51 | child: Column( 52 | mainAxisAlignment: MainAxisAlignment.spaceEvenly, 53 | children: [ 54 | Details(countryStats: widget.country), 55 | StatsPieChart(stats: widget.country), 56 | widget.country.country == SingleIntReportView.allCountries 57 | ? SizedBox() 58 | : TrendChart(country: widget.country.country, italy: false), 59 | SizedBox( 60 | height: 16.0, 61 | ), 62 | ], 63 | ), 64 | ), 65 | ), 66 | )); 67 | }); 68 | } 69 | } 70 | 71 | class Details extends StatelessWidget { 72 | final Country countryStats; 73 | 74 | Details({ 75 | this.countryStats, 76 | }); 77 | 78 | @override 79 | Widget build(BuildContext context) { 80 | // 81 | List children = [ 82 | Container( 83 | child: Row( 84 | mainAxisAlignment: MainAxisAlignment.center, 85 | children: [ 86 | createDetailItem( 87 | context: context, 88 | color: SingleIntReportView.colors[0], 89 | value: countryStats.active, 90 | text: SingleIntReportView.active), 91 | createDetailItem( 92 | context: context, 93 | value: countryStats.critical, 94 | text: SingleIntReportView.critical), 95 | ], 96 | ), 97 | ), 98 | Container( 99 | child: Row( 100 | mainAxisAlignment: MainAxisAlignment.center, 101 | children: [ 102 | createDetailItem( 103 | context: context, 104 | color: SingleIntReportView.colors[1], 105 | value: countryStats.recovered, 106 | text: SingleIntReportView.recovered), 107 | ], 108 | ), 109 | ), 110 | Container( 111 | child: Row( 112 | mainAxisAlignment: MainAxisAlignment.center, 113 | children: [ 114 | createDetailItem( 115 | context: context, 116 | color: SingleIntReportView.colors[2], 117 | value: countryStats.deaths, 118 | todaysUpdate: countryStats.todayDeaths, 119 | text: SingleIntReportView.deaths, 120 | ), 121 | ], 122 | ), 123 | ), 124 | Container( 125 | child: Row( 126 | mainAxisAlignment: MainAxisAlignment.center, 127 | children: [ 128 | createDetailItem( 129 | context: context, 130 | colors: SingleIntReportView.colors, 131 | value: countryStats.cases, 132 | text: SingleIntReportView.cases, 133 | todaysUpdate: countryStats.todayCases), 134 | ], 135 | ), 136 | ), 137 | countryStats.country == SingleIntReportView.allCountries 138 | ? SizedBox() 139 | : Container( 140 | child: Row( 141 | mainAxisAlignment: MainAxisAlignment.center, 142 | children: [ 143 | createDetailItem( 144 | context: context, 145 | value: countryStats.casesPerOneMillion, 146 | text: SingleIntReportView.cases1M), 147 | createDetailItem( 148 | context: context, 149 | value: countryStats.deathsPerOneMillion, 150 | text: SingleIntReportView.deaths1M), 151 | ], 152 | ), 153 | ) 154 | ]; 155 | return Padding( 156 | padding: const EdgeInsets.fromLTRB(8.0, 20.0, 8.0, 8.0), 157 | child: Container( 158 | child: Column( 159 | children: children, 160 | ), 161 | ), 162 | ); 163 | } 164 | } 165 | 166 | Widget createDetailItem( 167 | {BuildContext context, 168 | dynamic value, 169 | Color color, 170 | List colors, 171 | String text, 172 | int todaysUpdate, 173 | Row innerWidget}) { 174 | List listWidgets = []; 175 | if (colors != null) { 176 | for (Color col in colors) { 177 | listWidgets.add(Container( 178 | margin: EdgeInsets.only(right: 8.0), 179 | width: 13, 180 | height: 13, 181 | decoration: BoxDecoration( 182 | shape: BoxShape.rectangle, 183 | color: col ?? Colors.transparent, 184 | borderRadius: BorderRadius.circular(2.0)), 185 | )); 186 | } 187 | } 188 | 189 | return Expanded( 190 | child: Container( 191 | margin: EdgeInsets.all(4.0), 192 | padding: EdgeInsets.all(8.0), 193 | decoration: BoxDecoration( 194 | color: color == null ? Colors.white : color.withAlpha(20), 195 | shape: BoxShape.rectangle, 196 | border: Border.all(color: Colors.grey, width: 0.5), 197 | borderRadius: BorderRadius.all(Radius.circular(5.0))), 198 | child: Column( 199 | crossAxisAlignment: CrossAxisAlignment.start, 200 | children: [ 201 | Row( 202 | children: [ 203 | color != null 204 | ? Container( 205 | margin: EdgeInsets.only(right: 8.0), 206 | width: 13, 207 | height: 13, 208 | decoration: BoxDecoration( 209 | shape: BoxShape.rectangle, 210 | color: color ?? Colors.transparent, 211 | borderRadius: BorderRadius.circular(2.0)), 212 | ) 213 | : colors != null 214 | ? Row( 215 | children: listWidgets, 216 | ) 217 | : SizedBox(), 218 | Text( 219 | '$text', 220 | style: Theme.of(context).textTheme.caption, 221 | ), 222 | ], 223 | ), 224 | SizedBox( 225 | height: 16.0, 226 | ), 227 | Row( 228 | children: [ 229 | Text( 230 | '${value ?? 0}', 231 | style: Theme.of(context) 232 | .textTheme 233 | .headline6 234 | .copyWith(fontWeight: FontWeight.bold), 235 | ), 236 | todaysUpdate != null && todaysUpdate > 0 237 | ? Text( 238 | ' +$todaysUpdate', 239 | style: Theme.of(context).textTheme.caption, 240 | ) 241 | : SizedBox() 242 | ], 243 | ), 244 | innerWidget ?? SizedBox() 245 | ], 246 | ), 247 | ), 248 | ); 249 | } 250 | 251 | -------------------------------------------------------------------------------- /pubspec.lock: -------------------------------------------------------------------------------- 1 | # Generated by pub 2 | # See https://dart.dev/tools/pub/glossary#lockfile 3 | packages: 4 | async: 5 | dependency: transitive 6 | description: 7 | name: async 8 | url: "https://pub.dartlang.org" 9 | source: hosted 10 | version: "2.5.0-nullsafety.3" 11 | boolean_selector: 12 | dependency: transitive 13 | description: 14 | name: boolean_selector 15 | url: "https://pub.dartlang.org" 16 | source: hosted 17 | version: "2.1.0-nullsafety.3" 18 | characters: 19 | dependency: transitive 20 | description: 21 | name: characters 22 | url: "https://pub.dartlang.org" 23 | source: hosted 24 | version: "1.1.0-nullsafety.5" 25 | charcode: 26 | dependency: transitive 27 | description: 28 | name: charcode 29 | url: "https://pub.dartlang.org" 30 | source: hosted 31 | version: "1.2.0-nullsafety.3" 32 | clock: 33 | dependency: transitive 34 | description: 35 | name: clock 36 | url: "https://pub.dartlang.org" 37 | source: hosted 38 | version: "1.1.0-nullsafety.3" 39 | collection: 40 | dependency: transitive 41 | description: 42 | name: collection 43 | url: "https://pub.dartlang.org" 44 | source: hosted 45 | version: "1.15.0-nullsafety.5" 46 | convert: 47 | dependency: transitive 48 | description: 49 | name: convert 50 | url: "https://pub.dartlang.org" 51 | source: hosted 52 | version: "2.1.1" 53 | crypto: 54 | dependency: transitive 55 | description: 56 | name: crypto 57 | url: "https://pub.dartlang.org" 58 | source: hosted 59 | version: "2.1.4" 60 | cupertino_icons: 61 | dependency: "direct main" 62 | description: 63 | name: cupertino_icons 64 | url: "https://pub.dartlang.org" 65 | source: hosted 66 | version: "0.1.3" 67 | fake_async: 68 | dependency: transitive 69 | description: 70 | name: fake_async 71 | url: "https://pub.dartlang.org" 72 | source: hosted 73 | version: "1.2.0-nullsafety.3" 74 | fl_chart: 75 | dependency: "direct main" 76 | description: 77 | name: fl_chart 78 | url: "https://pub.dartlang.org" 79 | source: hosted 80 | version: "0.8.7" 81 | flutter: 82 | dependency: "direct main" 83 | description: flutter 84 | source: sdk 85 | version: "0.0.0" 86 | flutter_keyboard_visibility: 87 | dependency: transitive 88 | description: 89 | name: flutter_keyboard_visibility 90 | url: "https://pub.dartlang.org" 91 | source: hosted 92 | version: "0.7.0" 93 | flutter_test: 94 | dependency: "direct dev" 95 | description: flutter 96 | source: sdk 97 | version: "0.0.0" 98 | flutter_web_plugins: 99 | dependency: transitive 100 | description: flutter 101 | source: sdk 102 | version: "0.0.0" 103 | google_fonts: 104 | dependency: "direct main" 105 | description: 106 | name: google_fonts 107 | url: "https://pub.dartlang.org" 108 | source: hosted 109 | version: "0.3.10" 110 | http: 111 | dependency: "direct main" 112 | description: 113 | name: http 114 | url: "https://pub.dartlang.org" 115 | source: hosted 116 | version: "0.12.0+4" 117 | http_parser: 118 | dependency: transitive 119 | description: 120 | name: http_parser 121 | url: "https://pub.dartlang.org" 122 | source: hosted 123 | version: "3.1.4" 124 | intl: 125 | dependency: "direct main" 126 | description: 127 | name: intl 128 | url: "https://pub.dartlang.org" 129 | source: hosted 130 | version: "0.16.1" 131 | js: 132 | dependency: transitive 133 | description: 134 | name: js 135 | url: "https://pub.dartlang.org" 136 | source: hosted 137 | version: "0.6.3-nullsafety.3" 138 | liquid_pull_to_refresh: 139 | dependency: "direct main" 140 | description: 141 | name: liquid_pull_to_refresh 142 | url: "https://pub.dartlang.org" 143 | source: hosted 144 | version: "1.1.1" 145 | matcher: 146 | dependency: transitive 147 | description: 148 | name: matcher 149 | url: "https://pub.dartlang.org" 150 | source: hosted 151 | version: "0.12.10-nullsafety.3" 152 | meta: 153 | dependency: transitive 154 | description: 155 | name: meta 156 | url: "https://pub.dartlang.org" 157 | source: hosted 158 | version: "1.3.0-nullsafety.6" 159 | path: 160 | dependency: transitive 161 | description: 162 | name: path 163 | url: "https://pub.dartlang.org" 164 | source: hosted 165 | version: "1.8.0-nullsafety.3" 166 | path_drawing: 167 | dependency: transitive 168 | description: 169 | name: path_drawing 170 | url: "https://pub.dartlang.org" 171 | source: hosted 172 | version: "0.4.1" 173 | path_parsing: 174 | dependency: transitive 175 | description: 176 | name: path_parsing 177 | url: "https://pub.dartlang.org" 178 | source: hosted 179 | version: "0.1.4" 180 | path_provider: 181 | dependency: transitive 182 | description: 183 | name: path_provider 184 | url: "https://pub.dartlang.org" 185 | source: hosted 186 | version: "1.6.5" 187 | path_provider_macos: 188 | dependency: transitive 189 | description: 190 | name: path_provider_macos 191 | url: "https://pub.dartlang.org" 192 | source: hosted 193 | version: "0.0.4" 194 | path_provider_platform_interface: 195 | dependency: transitive 196 | description: 197 | name: path_provider_platform_interface 198 | url: "https://pub.dartlang.org" 199 | source: hosted 200 | version: "1.0.1" 201 | pedantic: 202 | dependency: transitive 203 | description: 204 | name: pedantic 205 | url: "https://pub.dartlang.org" 206 | source: hosted 207 | version: "1.9.0" 208 | platform: 209 | dependency: transitive 210 | description: 211 | name: platform 212 | url: "https://pub.dartlang.org" 213 | source: hosted 214 | version: "2.2.1" 215 | plugin_platform_interface: 216 | dependency: transitive 217 | description: 218 | name: plugin_platform_interface 219 | url: "https://pub.dartlang.org" 220 | source: hosted 221 | version: "1.0.2" 222 | search_widget: 223 | dependency: "direct main" 224 | description: 225 | name: search_widget 226 | url: "https://pub.dartlang.org" 227 | source: hosted 228 | version: "1.0.2" 229 | sky_engine: 230 | dependency: transitive 231 | description: flutter 232 | source: sdk 233 | version: "0.0.99" 234 | source_span: 235 | dependency: transitive 236 | description: 237 | name: source_span 238 | url: "https://pub.dartlang.org" 239 | source: hosted 240 | version: "1.8.0-nullsafety.4" 241 | stack_trace: 242 | dependency: transitive 243 | description: 244 | name: stack_trace 245 | url: "https://pub.dartlang.org" 246 | source: hosted 247 | version: "1.10.0-nullsafety.6" 248 | stream_channel: 249 | dependency: transitive 250 | description: 251 | name: stream_channel 252 | url: "https://pub.dartlang.org" 253 | source: hosted 254 | version: "2.1.0-nullsafety.3" 255 | string_scanner: 256 | dependency: transitive 257 | description: 258 | name: string_scanner 259 | url: "https://pub.dartlang.org" 260 | source: hosted 261 | version: "1.1.0-nullsafety.3" 262 | term_glyph: 263 | dependency: transitive 264 | description: 265 | name: term_glyph 266 | url: "https://pub.dartlang.org" 267 | source: hosted 268 | version: "1.2.0-nullsafety.3" 269 | test_api: 270 | dependency: transitive 271 | description: 272 | name: test_api 273 | url: "https://pub.dartlang.org" 274 | source: hosted 275 | version: "0.2.19-nullsafety.6" 276 | transparent_image: 277 | dependency: "direct main" 278 | description: 279 | name: transparent_image 280 | url: "https://pub.dartlang.org" 281 | source: hosted 282 | version: "1.0.0" 283 | typed_data: 284 | dependency: transitive 285 | description: 286 | name: typed_data 287 | url: "https://pub.dartlang.org" 288 | source: hosted 289 | version: "1.3.0-nullsafety.5" 290 | url_launcher: 291 | dependency: "direct main" 292 | description: 293 | name: url_launcher 294 | url: "https://pub.dartlang.org" 295 | source: hosted 296 | version: "5.4.2" 297 | url_launcher_macos: 298 | dependency: transitive 299 | description: 300 | name: url_launcher_macos 301 | url: "https://pub.dartlang.org" 302 | source: hosted 303 | version: "0.0.1+4" 304 | url_launcher_platform_interface: 305 | dependency: transitive 306 | description: 307 | name: url_launcher_platform_interface 308 | url: "https://pub.dartlang.org" 309 | source: hosted 310 | version: "1.0.6" 311 | url_launcher_web: 312 | dependency: transitive 313 | description: 314 | name: url_launcher_web 315 | url: "https://pub.dartlang.org" 316 | source: hosted 317 | version: "0.1.1+1" 318 | vector_math: 319 | dependency: transitive 320 | description: 321 | name: vector_math 322 | url: "https://pub.dartlang.org" 323 | source: hosted 324 | version: "2.1.0-nullsafety.5" 325 | sdks: 326 | dart: ">=2.12.0-0.0 <3.0.0" 327 | flutter: ">=1.12.8 <2.0.0" 328 | --------------------------------------------------------------------------------