瀏覽代碼

Modify parallax image speeds and offsets.

Add:
        templates/about.html, static/sass/about.sass
                -Change parallax image offsets and scroll speeds; current
                implementation still isn't scalable to different resolutions
                (it'll work for most, but not all).
tags/v1.0^2
Severyn Kozak 10 年之前
父節點
當前提交
9dcc0adbf4
共有 2 個檔案被更改,包括 12 行新增11 行删除
  1. +8
    -7
      static/sass/about.sass
  2. +4
    -4
      templates/about.html

+ 8
- 7
static/sass/about.sass 查看文件

@@ -18,25 +18,26 @@ div.bg
&#img-1
background: url(../img/about/bg1.png) no-repeat
background-size: cover
height: 400px
top: -210px
height: 600px
top: -300px

&#img-2
background: url(../img/about/bg2.png) no-repeat
height: $img-height + 530
top: 550px
background-size: cover
height: $img-height + 300
top: 450px

&#img-3
background: url(../img/about/bg3.png) no-repeat
background-size: cover
height: $img-height + 250
top: 1560px
height: $img-height + 300
top: 1250px

&#img-4
background: url(../img/about/bg4.png) no-repeat
background-size: cover
height: $img-height + 400
top: 5280px
top: 2500px

div.section
background-color: white


+ 4
- 4
templates/about.html 查看文件

@@ -12,10 +12,10 @@
= endblock

= block after_body
<!-- <div id="img-1" class="bg" speed="-1.25"></div> -->
<!-- <div id="img-2" class="bg" speed="1.8"></div> -->
<!-- <div id="img-3" class="bg" speed="1.6"></div> -->
<!-- <div id="img-4" class="bg" speed="3.64"></div> -->
<div id="img-1" class="bg" speed="-1.25"></div>
<div id="img-2" class="bg" speed="1.4"></div>
<div id="img-3" class="bg" speed="1.4"></div>
<div id="img-4" class="bg" speed="1.4"></div>

<div id="top" class="section">
<div class="centered">


Loading…
取消
儲存