Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using it's URL and the proper URL extention.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                <script src="https://cdn.freecodecamp.org/testable-projects-fcc/v1/bundle.js"></script>

<!DOCTYPE html>
<html>
  <head>
    <!-- metadata elements -->
    <!--no data, see CSS codes-->
  </head>
  <main id="main">
  <body>
    <h1 id=title>COVID-19 IN CANADA</h1>
    <hr>
    <p>How COVID-19 started in Canada</p>
    <figure id="img-div">
      <img
      id="image"
      src="https://cdn-res.keymedia.com/cms/images/us/036/0248_637205561118859116.jpg"
      alt="Canadian flag, syringe, mask and glove on wooden background"
      />
      <figcaption id="img-caption">
      Figure tributes to Canadian Health workers.
      </figcaption>
  </figure>
    
    <section id="tribute-info">  
      <h2>History of COVID-19 in Canada</h2>
        <div class="timeline">
        <div class="container left">
        <div class="content">
        <h3>December 2019</h3>
          <ul>
            <li>
              On December 31, the World Health Organization was alerted to several cases of pneumonia in Wuhan, China. The virus did not match any other known virus. </li>
        </ul>
          </div>
          </div>
          
        <div class="timeline">
        <div class="container right">
        <div class="content">
        <h3>January 2020</h3>
        <ul>
          <li>On January 30, the World Health Organization declares the outbreak of COVID-19 a public health event of international concern.</li>
<li>On January 25, Canada confirms its first case of COVID-19 related to travel in Wuhan, China.</li>
<li>On January 22, Canada implements screening requirements related to COVID-19 for travellers returning from China to major airports in Montréal, Toronto and Vancouver.</li>
<li>On January 15, the Public Health Agency of Canada activates the Emergency Operation Centre to support Canada's response to COVID-19.</li>
          <li>On January 7, China confirmed COVID-19.</li>
        </ul>
          </div>
          </div>
          
        <div class="timeline">
        <div class="container left">
        <div class="content">
          <h3>February 2020</h3>
        <ul>
          <li>On February 20, Canada confirms its first case related to travel outside mainland China.</li>
<li>On February 9, Canada expands COVID-19 screening requirements for travellers returning from affected areas to 10 airports across 6 provinces.</li>
        </ul>
          </div>
          </div>
          
          
        <div class="timeline">
        <div class="container right">
        <div class="content">
        <h3>March 2020</h3>
        <ul>
          <li>On March 31, Canada announces new partnerships with Canadian industries, under Canada's Plan to Mobilize Industry to fight COVID-19. The Government of Canada plans to invest $2 billion to support diagnostic testing and to purchase ventilators and protective personal equipment.</li>
<li>On March 30, Canada states that all passengers flying in Canada will be subject to a health check prior to boarding.</li>
<li>On March 29, Canada introduces measures to support vulnerable Canadians to help cope with the health, social, and economic impacts of COVID-19.</li>
<li>On March 27, Canada announces support for small businesses facing impacts of the pandemic, as part of the COVID-19 Economic Response Plan.</li>
<li>On March 23, Canada announces support to quickly mobilize Canadian researchers and life sciences companies to support large-scale efforts towards countermeasures to combat COVID-19, including potential vaccines and treatments.</li>
<li>On March 23, Canada announces new measures to support local farmers and agri-food businesses in Canada facing financial hardship due to the impacts of the COVID-19 pandemic.</li>
<li>On March 18, Canada announces financial help, through the COVID-19 Economic Response Plan, for Canadians and businesses facing hardship as a result of the COVID-19 outbreak.</li>
<li>On March 18, Canada implements a ban on foreign nationals from all countries, except the United States from entering Canada, Canada-U.S. border closes to all non-essential travel, and redirects international passenger flight arrivals to four airports in Calgary, Vancouver, Toronto and Montreal.</li>
<li>On March 16, Canada advises travellers entering Canada to self-isolate for 14 days.</li>
<li>On March 13, Canada advises Canadians to avoid all non-essential travel outside of Canada until further notice.
<li>On March 11, the World Health Organization declares the global outbreak of COVID-19 a pandemic.</li>
<li>On March 9, Canada confirms its first death related to COVID-19.</li>
        </ul>
          </div>
          </div>
          
          
         <div class="timeline">
        <div class="container left">
        <div class="content">
        <h3>April 2020</h3>
        <ul>
          <li>On April 29, Canada launches a new mobile app, ArriveCAN.</li>
<li>On April 28, Canada surpasses 50,000 confirmed cases of COVID-19</li>
<li>On April 23, Canada announces more than $1 billion in support of a national medical research strategy to fight COVID-19</li>
<li>On April 23, Canada surpasses 2,000 confirmed deaths from COVID-19</li>
<li>On April 15, Canada surpasses 1,000 confirmed deaths from COVID-19</li>
<li>On April 15, Canada launches a new portal, Wellness Together Canada, dedicated to mental wellness</li>
<li>On April 15, expansion of the COVID-19 Emergency Response Act, to help essential workers</li>
<li>On April 11, expansion of the COVID-19 Emergency Response Act, to help businesses keep Canadians in their jobs</li>
<li>On April 9, Canada surpasses 20,000 confirmed cases of COVID-19</li>
<li>On April 3, Canada announces an investment of $100 million to improve access to food for Canadians facing social, economic, and health impacts of the COVID-19 pandemic.</li>
<li>On April 2, worldwide COVID-19 cases reach 1 million.</li>
<li>On April 2, Canada launches the Canada COVID-19 app on iOS and Android to provide Canadians with the latest information on COVID-19 and a way to check their symptoms.</li>
<li>On April 2, Canada surpasses 10,000 confirmed cases of COVID-19.</li>
        </ul>
          </div>
          </div>
          </section>
          
          
        <p id="link1"><em>To find more updated information about COVID-19 in Canada, click <a href="https://www.canada.ca/en/public-health/services/diseases/2019-novel-coronavirus-infection.html#a1" id="tribute-link" target="_blank"> here </a>.</em> </p>
       <p id="link2"><em>To find more data about other countries, click <a href="https://coronavirus.jhu.edu/map.html" target="_blank"> here</a> to access Johns Hopskin University's Coronavirus map.</em> </p>
    
          
  <footer>
			<em>&copy;2020 ngocpham1994x</em>
	</footer>
  </body>
  </main>
</html>




              
            
!

CSS

              
                
html{
   /* Setting a base font size of 10px give us easier rem calculations
     Info: 1rem === 10px, 1.5rem === 15px, 2rem === 20px and so forth
   */
  font-size: 10px; 
}

main{
  font-family: Arial, sans-serif;
  font-size: 1.6rem;
  line-height: 1.5;
  text-align: center;
  background:#eee;
  margin: 0;
}
#title{
 /*default style*/
}

#image {
  align: center; /*User Story #9: The img element should be centered within its parent element.*/
  max-width: 100%; 
  /*User Story #8: The img element should responsively resize, relative to the width of its parent element, without exceeding its original size.*/  
  /*User Story #9: The img element should be centered within its parent element.*/
  display: block;
  height: auto;
  margin: 0 auto;
  border-color: black;
  border-width: 5px;
  border-style: solid;
}

#img-div {
  background: white;
  padding: 10px;
  margin: 0;
}

#img-caption {
  margin: 15px 0 5px 0;
}

@media (max-width: 460px) {
  #img-caption {
    font-size: 1.4rem;
  }
}

#tribute-info {
  /*default style*/
}

ul {
  max-width: 550px;
  margin: 0 auto 50px auto;
  text-align: left;
  line-height: 1.6;
}

li {
  margin: 16px 0;
}

/* The actual timeline (the vertical ruler) */
.timeline {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
}

/* The actual timeline (the vertical ruler) */
.timeline::after {
  content: '';
  position: absolute;
  width: 6px;
  background-color: red;
  top: 0;
  bottom: 0%;
  left: 50%;
  margin-left: -3px;
}

/* Container around each content */
.container {
  padding: 0px 0px;
  position: relative;
  background-color: transparent;
  width: 50%;
}

/* The circles on the timeline */
.container::after {
  content: '';
  position: absolute;
  width: 25px;
  height: 25px;
  right: -17px;
  background-color: #FFFAF0;
  border: 4px solid #2DA1E7;
  top: 15px;
  border-radius: 50%;
  z-index: 1;
}

/* The actual content inside container */
.content {
  padding: 0px 10px;
  margin: 0px 40px;
  background-color: pink;
  position: relative;
  border-radius: 20px;
}

/* Place the container to the left "container left" */
.left {
  left: 0;
}

/* Place the container to the right "container right" */
.right {
  left: 50%;
}

/* Add arrows to the left container (pointing right) */
.left::before {
  content: " ";
  height: 0;
  position: absolute;
  top: 22px;
  width: 0;
  z-index: 1;
  right: 30px;
  border: medium solid white;
  border-width: 10px 0 10px 10px;
  border-color: transparent transparent transparent pink;
}

/* Add arrows to the right container (pointing left) */
.right::before {
  content: " ";
  height: 0;
  position: absolute;
  top: 22px;
  width: 0;
  z-index: 1;
  left: 30px;
  border: medium solid white;
  border-width: 10px 10px 10px 0;
  border-color: transparent pink transparent transparent;
}

/* Fix the circle for containers on the right side "container right" */
.right::after {
  left: -16px;
}



/* Media queries - Responsive timeline on screens less than 600px wide */
@media screen and (max-width: 600px) {
/* Place the timelime to the left */
  .timeline::after {
    left: 31px;
  }

/* Full-width containers */
  .container {
    width: 100%;
    padding: 0px 0px 0px 30px;
  }

/* Make sure that all arrows are pointing leftwards */
  .container::before {
    left: 60px;
    border: medium solid pink;
    border-width: 10px 10px 10px 0;
    border-color: transparent pink transparent transparent;
  }
  
/* Place the "container right" to further left, 0% */
.right {
  left: 0%;
}
  
/* Make sure all circles are at the same spot */
  .left::after, .right::after {
    left: 15px;
  }
}
              
            
!

JS

              
                
              
            
!
999px

Console