Browse Source

Again more style and parallax work.

master
Georg Hopp 10 years ago
parent
commit
0999f02334
  1. 1196
      app/assets/images/bwcartoon-m.svg
  2. 94
      app/assets/images/heckert_gnu.svg
  3. 9
      app/assets/javascripts/parallax.coffee
  4. 4
      app/views/layouts/application.html.erb
  5. 1
      app/views/welcome/index.html.erb

1196
app/assets/images/bwcartoon-m.svg
File diff suppressed because it is too large
View File

94
app/assets/images/heckert_gnu.svg
File diff suppressed because it is too large
View File

9
app/assets/javascripts/parallax.coffee

@ -31,10 +31,13 @@ App.init = ->
App.scroll = ->
v_scroll = $(document).scrollTop()
section = Math.floor(v_scroll / $(window).innerHeight())
bg_pos = (v_scroll-(section*$(window).innerHeight()))/2
$($(".section")[section]).css(
[section, section+1].forEach (section) ->
bg_pos = -((v_scroll-(section*$(window).innerHeight()))/2)
section_element = $($(".section")[section])
if section_element and section_element.css("background-image") != "none"
section_element.css(
"background-position",
"center -" + bg_pos + "px")
"center " + bg_pos + "px")
$(document).on "page:change", ->
App.init()

4
app/views/layouts/application.html.erb

@ -12,8 +12,8 @@
<div id="logo"><a href=""> WEIRD WEB WORKERS </a></div>
<nav id="nav">
<ul>
<li><a href="#section1" class="active" title="Next Section" >Slide 1</a></li>
<li><a href="#section2" title="Next Section">Slide 2</a></li>
<li><a href="#section1" class="active" title="Next Section" >About</a></li>
<li><a href="#section2" title="Next Section">Projects</a></li>
<li><a href="#section3" title="Next Section">Slide 3</a></li>
<li><a href="#section4" title="Next Section">Slide 4</a></li>
</ul>

1
app/views/welcome/index.html.erb

@ -12,6 +12,7 @@
Programs
</div>
<div class="textbox">
<%= image_tag("heckert_gnu.svg", size: "60") %>
<%= image_tag("tux-mono.svg", size: "60") %>
<h1>Linux Consulting</h1>
Support

Loading…
Cancel
Save