Difference between revisions of "Team:Dalhousie/test5"

Line 16: Line 16:
 
</style>
 
</style>
  
 +
 +
  <meta charset="UTF-8" />
 +
  <title>An Animated Timeline</title>
 +
  <meta name="viewport" content="width=device-width">
 
</head>
 
</head>
 +
 
<body>
 
<body>
<div class="timeline">
+
  <header>
  <div class="circle"></div>
+
    <div class="poster">
   <ul>
+
      <h1 class="poster__heading">The North Pole 2015
     <li><em>2 days</em> <strong>Research and plan</strong></li>
+
          <span class="poster__subheading">The Ultimate Artic Adventure</span>
    <li><em>2 days</em> <strong>Wireframing</strong></li>
+
        <a href="#" class="btn--primary">Book Request</a>
    <li><em>5 days</em> <strong>Design and Development</strong></li>
+
      </div>
    <li><em>Forever</em> <strong>Launch and Support</strong></li>
+
    </div>
  </ul>
+
   </header>
  <div class="circle"></div>
+
  <main class="timeline-wrapper">
</div>
+
     <div class="svg-timeline">
 +
      <svg width="8px" height="1490.7px" viewBox="0 0 8 1490.7">
 +
        <line id="timeline" fill="none" stroke="#FFFFFF" stroke-width="8" stroke-miterlimit="10" x1="4" y1="0" x2="4" y2="1490.7"/>
 +
      </svg>
 +
    </div>
 +
    <ol class="timeline clearfix">
 +
      <li class="timeline__item">
 +
        <h3 class="timeline__day">Day 1: <span>Helsinki, Finland</span></h3>
 +
        <p class="timeline__day-sum">Your adventure begins with a one-night stay in Helsinki, Finland's capital.</p>
 +
        <a href="#" class="btn--comments">19 Comments</a>
 +
      </li>
 +
      <li class="timeline__item right">
 +
        <h3 class="timeline__day dayTwo">Day 2: <span>Embarkation Day in Murmansk</span></h3>
 +
        <p class="timeline__day-sum">From Helsinki, your charter flight will take you to Murmansk, Russia, where you'll embark on your voyage to the North Pole and get acquainted with 50 Years of Victory, the world's largest and most powerful icebreaker.</p>
 +
        <a href="#" class="btn--comments">35 Comments</a>
 +
      </li>
 +
      <li class="timeline__item">
 +
        <h3 class="timeline__day dayThree">Day 3-6: <span>Northbound in the Arctic Ocean</span></h3>
 +
        <p class="timeline__day-sum">Watching the ship crush through the Arctic ice pack is a sight you'll never forget, made even more memorable by taking a helicopter flight for a thrilling aerial view of the ship and expansive Arctic Ocean.</p>
 +
        <p class="timeline__day-sum">You can expect days, and hours,to present variable sailing conditions this far north. The crossing from Murmansk to the North Pole can take us anywhere from 5-8 days. This means you'll have plenty of time to get to know your shipmates, stare out at the horizon, grab some drinks at the bar or do some laps in our indoor pool.</p>
 +
        <a href="#" class="btn--comments">72 Comments</a>
 +
      </li>
 +
      <li class="timeline__item right">
 +
        <h3 class="timeline__day dayFour">Day 7: <span>90&deg; North</span></h3>
 +
        <p class="timeline__day-sum">All of the anticipation of the past few days reaches a climax as you reach the North Pole! Many travelers find themselves overcome with emotion, while others are in a festive mood. Take photos, wave a flag, enjoy your moment! Later, everyone enjoys a champagne toast and a BBQ on the ice. Add an exclamation to your success by rising high in one of our hot air balloons to commemerate this great moment.</p>
 +
        <a href="#" class="btn--comments">132 Comments</a>
 +
      </li>
 +
      <li class="timeline__item">
 +
        <h3 class="timeline__day dayFive">Day 8: <span>Southbound in the Arctic Ocean</span></h3>
 +
        <p class="timeline__day-sum">Now you can sit back and relax, everything from here on out is a bonus! Expect more great memories as you head south, you may get lucky and spot a Polar Bear hunting a Seal.</p>
 +
        <a href="#" class="btn--comments">2 Comments</a>
 +
      </li>
 +
      <li class="timeline__item right">
 +
        <h3 class="timeline__day daySix">Day 9-10: <span>Franz Josef Land</span></h3>
 +
        <p class="timeline__day-sum">Now you can sit back and relax, everything from here on out is a bonus! Expect more great memories as you head south, you may get lucky and spot a Polar Bear hunting a Seal.</p>
 +
        <a href="#" class="btn--comments">12 Comments</a>
 +
      </li>
 +
    </ol>
 +
  </main>
 
<style>
 
<style>
$color-1:#222;
+
html {
$color-2:#666;
+
  box-sizing: border-box;
$color-3:#aaa;
+
}
$color-4:#fff;
+
*, *:before, *:after {
 +
  box-sizing: inherit;
 +
}
  
* {-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;position:relative;} /* Box sizing. Thanks Chris Coyier! */
+
.right {
body {background:$color-1;}
+
  float:right;
.timeline {font:normal bold 16px/1.6rem "Open Sans Condensed";padding:1rem;}
+
}
.timeline .circle {background:$color-3;border:.5rem solid $color-2;border-radius:100%;height:2.25rem;margin:auto;width:2.25rem;vertical-align:middle;}
+
/* ====== MIXINS ===== */
.timeline ul {margin:0;padding:0;}
+
// BEM selectors mixin
.timeline em {color:$color-2;display:block;font-weight:bold;}
+
// block__element
.timeline li {border:0 solid $color-3;color:$color-4;font-family:"Open Sans";list-style-type:none;text-transform:uppercase;padding:1rem 2rem;width:calc(50% + 1px);}
+
@mixin e($element) {
.timeline li:after {background:$color-3;border-radius:100%;content:"";display:inline-block;height:1rem;position:absolute;right:calc(-.5rem - 1px);width:1rem;}
+
  &__#{$element} {
.timeline li:nth-child(even):after {left:calc(-.5rem - 1px);}
+
    @content;
.timeline li:nth-child(odd) {border-right-width:2px;text-align:right;}
+
  }
.timeline li:nth-child(even) {border-left-width:2px;left:calc(50% - 1px);}
+
}
 +
 
 +
// block__element--modifier
 +
@mixin m($modifier) {
 +
  &--#{$modifier}{
 +
    @content;
 +
  }
 +
}
 +
// Media queries mixin
 +
$sm: 31.25em; // 500px
 +
$md: 50em; // 800px
 +
$lg: 75em; // 1200px
 +
@mixin mq($break) {
 +
  @if $break=="sm" {
 +
    @media screen and ( min-width: $sm) {
 +
      @content;
 +
    }
 +
  }
 +
  @else if $break=="md" {
 +
    @media screen and ( min-width: $md) {
 +
      @content;
 +
    }
 +
  }
 +
  @else if $break=="lg" {
 +
    @media screen and ( min-width: $lg) {
 +
      @content;
 +
    }
 +
  }
 +
  @else {
 +
    @media screen and ( min-width: $break) {
 +
      @content;
 +
    }
 +
  }
 +
}
 +
 
 +
// Variables
 +
$font-family--primary: 'Open Sans';
 +
$font-weight--light: 300;
 +
$font-weight--norm: 400;
 +
$font-weight--semi: 600;
 +
$font-weight--bold: 700;
 +
$font-weight--ultra: 900;
 +
$orange: #FF9639;
 +
// helpers
 +
%center-text {
 +
  text-align: center;
 +
}
 +
 
 +
%center-align {
 +
  margin: 0 auto;
 +
}
 +
 
 +
html {
 +
  font-family: $font-family--primary;
 +
  font-size: 100%;
 +
  @include mq(sm) {
 +
    font-size: 105%;
 +
  }
 +
  @include mq(md) {
 +
    font-size: 115%;
 +
  }
 +
  @include mq(lg) {
 +
    font-size: 125%;
 +
  }
 +
}
 +
 
 +
// button styles
 +
%btn {
 +
  display: inline;
 +
  text-decoration: none;
 +
  padding: .45em 1.25em;
 +
  text-transform: uppercase;
 +
  font-weight: $font-weight--norm;
 +
  letter-spacing: 1px;
 +
  font-size: .75rem;
 +
  border-radius: 25px;
 +
  color: white;
 +
  font-family: $font-family--primary;
 +
  transition: all 250ms ease;
 +
}
 +
 
 +
.btn--primary {
 +
  border: 1px solid white;
 +
  @extend %btn;
 +
    &:hover {
 +
    background-color: white;
 +
    color: black;
 +
  }
 +
}
 +
 
 +
.poster {
 +
  height: 100vh;
 +
  width: 100%;
 +
  background-size: cover;
 +
  background-position: center center;
 +
  background-image: url("http://codepen.vincebrown.me/assets/images/snow-mountains.jpg");
 +
  // .poster__heading
 +
  @include e('heading') {
 +
    @extend %center-text;
 +
    @extend %center-align;
 +
    width: 95%;
 +
    color: white;
 +
    padding-top: 5.5rem;
 +
    font-weight: $font-weight--semi;
 +
    font-size: 2em;
 +
    transition: all 400ms ease;
 +
    @include mq(sm) {
 +
      font-size: 2.25em;
 +
    }
 +
    @include mq(md) {
 +
      font-size: 2.75em;
 +
    }
 +
  }
 +
  @include e('subheading') {
 +
    @extend %center-text;
 +
    display: block;
 +
    font-size: .3em;
 +
    letter-spacing: 5px;
 +
    font-weight: $font-weight--norm;
 +
    text-transform: uppercase;
 +
    color: $orange;
 +
    padding-top: .8em;
 +
    margin-bottom: .6em;
 +
  }
 +
} // end .poster
 +
 
 +
 
 +
// timeline
 +
.btn--comments{
 +
  @extend %btn;
 +
  background-color: rgba(255,255,255,.4);
 +
  border:none;
 +
  font-size: .6em;
 +
  &:hover {
 +
    background-color: rgba(255,255,255,.6);
 +
  }
 +
}
 +
 
 +
.timeline-wrapper{
 +
  position: relative;
 +
  padding-bottom:25em;
 +
  background: linear-gradient(#000 10%, #283048 60%, #55679a 70%, rgba(255,255,255,0));
 +
  &:after{
 +
    content:'';
 +
    display:block;
 +
    background-image: url('http://codepen.vincebrown.me/assets/images/white-mountains.jpg');
 +
    height:500px;
 +
    width: 100%;
 +
    background-size:cover;
 +
    position: absolute;
 +
    background-position:25% center;
 +
    z-index:-10;
 +
    bottom:0;
 +
  }
 +
}
 +
.svg-timeline {
 +
  position: absolute;
 +
  margin-left:50%;
 +
  transform: translateX(-50%);
 +
  display:none;
 +
  @include mq(md) {
 +
    display:block;
 +
  }
 +
}
 +
.timeline {
 +
  transition:all 250ms ease;
 +
  width: 90%;
 +
  margin: 0 auto;
 +
  @include mq(sm) {
 +
    width: 80%;
 +
  }
 +
  @include mq(md) {
 +
    width: 95%;
 +
  }
 +
  @include e('item') {
 +
    margin-bottom: 4em;
 +
    clear:both;
 +
    @include mq(md) {
 +
      width: 40%;
 +
    }
 +
  }
 +
  // .timeline__day
 +
  @include e('day') {
 +
    font-weight: $font-weight--semi;
 +
    font-size: .9em;
 +
    color:white;
 +
    text-transform: uppercase;
 +
    padding-bottom:.75em;
 +
    span{
 +
      font-weight: $font-weight--light;
 +
      color:orange;
 +
      text-transform: none;
 +
    }
 +
  }
 +
  //.timeline__day-sum
 +
  @include e('day-sum') {
 +
    color:white;
 +
    font-weight: $font-weight--light;
 +
    font-size: .8em;
 +
    display:block;
 +
    margin-bottom:1.5em;
 +
    line-height: 1.5;
 +
   
 +
  }
 +
 
 +
}
 +
 
 +
 
 +
 
 +
 
 +
 
 +
 
 +
 
 +
.clearfix:after {
 +
    visibility: hidden;
 +
    display: block;
 +
    font-size: 0;
 +
    content: " ";
 +
    clear: both;
 +
    height: 0;
 +
    }
 +
.clearfix { display: inline-block; }
 +
/* start commented backslash hack \*/
 +
* html .clearfix { height: 1%; }
 +
.clearfix { display: block; }
 +
/* close commented backslash hack */
 
</style>
 
</style>
 +
<script>
 +
var controller = new ScrollMagic.Controller();
 +
TweenMax.set('#timeline',{visibility:0});
 +
 +
var tweenOne =
 +
new TweenMax.fromTo('#timeline',1,{drawSVG:"0%"}, {drawSVG:"10%"}); 
 +
 +
var scene1 = new ScrollMagic.Scene({
 +
  triggerElement: '#timeline',
 +
}).setTween(tweenOne).addTo(controller);
 +
   
 +
var tweenTwo =
 +
new TweenMax.fromTo('#timeline',1,{drawSVG:"10%"}, {drawSVG:"20%"});
 +
 +
var scene2 = new ScrollMagic.Scene({
 +
  triggerElement: '.dayTwo',
 +
}).setTween(tweenTwo).addTo(controller);
 +
 +
 +
var tweenThree =
 +
new TweenMax.fromTo('#timeline',1,{drawSVG:"20%"}, {drawSVG:"40%"});
 +
 +
var scene3 = new ScrollMagic.Scene({
 +
  triggerElement: '.dayThree',
 +
}).setTween(tweenThree).addTo(controller);
 +
 +
 +
var tweenFour =
 +
new TweenMax.fromTo('#timeline',1,{drawSVG:"40%"}, {drawSVG:"65%"});
 +
 +
var scene3 = new ScrollMagic.Scene({
 +
  triggerElement: '.dayFour',
 +
}).setTween(tweenFour).addTo(controller);
 +
 +
var tweenFive =
 +
new TweenMax.fromTo('#timeline',1,{drawSVG:"65%"}, {drawSVG:"85%"});
 +
 +
var scene3 = new ScrollMagic.Scene({
 +
  triggerElement: '.dayFive',
 +
}).setTween(tweenFive).addTo(controller);
 +
 +
var tweenSix =
 +
new TweenMax.fromTo('#timeline',1,{drawSVG:"85%"}, {drawSVG:"102%"});
 +
 +
var scene3 = new ScrollMagic.Scene({
 +
  triggerElement: '.daySix',
 +
}).setTween(tweenSix).addTo(controller);
 +
</script>
 
</body>
 
</body>
 
</html>
 
</html>

Revision as of 20:46, 9 October 2017

         






  
  An Animated Timeline
  



  

The North Pole 2015 The Ultimate Artic Adventure Book Request

  1. Day 1: Helsinki, Finland

    Your adventure begins with a one-night stay in Helsinki, Finland's capital.

    19 Comments
  2. Day 2: Embarkation Day in Murmansk

    From Helsinki, your charter flight will take you to Murmansk, Russia, where you'll embark on your voyage to the North Pole and get acquainted with 50 Years of Victory, the world's largest and most powerful icebreaker.

    35 Comments
  3. Day 3-6: Northbound in the Arctic Ocean

    Watching the ship crush through the Arctic ice pack is a sight you'll never forget, made even more memorable by taking a helicopter flight for a thrilling aerial view of the ship and expansive Arctic Ocean.

    You can expect days, and hours,to present variable sailing conditions this far north. The crossing from Murmansk to the North Pole can take us anywhere from 5-8 days. This means you'll have plenty of time to get to know your shipmates, stare out at the horizon, grab some drinks at the bar or do some laps in our indoor pool.

    72 Comments
  4. Day 7: 90° North

    All of the anticipation of the past few days reaches a climax as you reach the North Pole! Many travelers find themselves overcome with emotion, while others are in a festive mood. Take photos, wave a flag, enjoy your moment! Later, everyone enjoys a champagne toast and a BBQ on the ice. Add an exclamation to your success by rising high in one of our hot air balloons to commemerate this great moment.

    132 Comments
  5. Day 8: Southbound in the Arctic Ocean

    Now you can sit back and relax, everything from here on out is a bonus! Expect more great memories as you head south, you may get lucky and spot a Polar Bear hunting a Seal.

    2 Comments
  6. Day 9-10: Franz Josef Land

    Now you can sit back and relax, everything from here on out is a bonus! Expect more great memories as you head south, you may get lucky and spot a Polar Bear hunting a Seal.

    12 Comments