This commit is contained in:
Nick Winter 2014-08-30 20:27:58 -07:00
parent 77e7efebeb
commit aa54cc32d1
7 changed files with 61 additions and 78 deletions

View file

@ -31,6 +31,7 @@ module.exports = class CocoRouter extends Backbone.Router
'admin/files': go('admin/FilesView') 'admin/files': go('admin/FilesView')
'admin/level-sessions': go('admin/LevelSessionsView') 'admin/level-sessions': go('admin/LevelSessionsView')
'admin/users': go('admin/UsersView') 'admin/users': go('admin/UsersView')
'admin/base': go('admin/BaseView')
'beta': go('HomeView') 'beta': go('HomeView')

View file

@ -45,6 +45,9 @@ a.disabled
padding: 4px 20px 0px 20px padding: 4px 20px 0px 20px
margin-left: -20px margin-left: -20px
.navbar-nav
float: right
.navbuttontext, .fancy-select .trigger .navbuttontext, .fancy-select .trigger
font-size: 20px font-size: 20px
font-weight: 400 font-weight: 400
@ -190,32 +193,38 @@ a.disabled
color: #ebebeb color: #ebebeb
padding: 8px 20px padding: 8px 20px
.navbar-toggle
display: none
#mobile-nav
display: none
@media only screen and (max-width: 800px) @media only screen and (max-width: 800px)
#top-nav #top-nav
display: none
#mobile-nav
display: inline display: inline
a.navbar-brand
padding: 4px 20px 0px 20px
button.navbar-toggle button.navbar-toggle
background: #483a2d background: #483a2d
border: 2px solid #2f261d border: 2px solid #2f261d
span.icon-bar display: inline-block
background: #F9E612
span.icon-bar
ul li background: #F9E612
font-family: 'Bangers', cursive
font-weight: normal a.navbar-brand
color: #fff padding: 4px 20px 0px 20px
font-size: 25px margin-left: 0
margin-top: 5px
margin-bottom: 5px .navbar-nav
.header-font float: none
color: #fff margin: 0 0 20px 0
.footer-link-text overflow: visible
width: 100%
display: ineline .dropdown-menu
background-color: white
position: absolute
.btn, .fancy-select
margin-bottom: 10px
.btn, .fancy-select
float: none
.fancy-select .options
right: auto

View file

@ -7,24 +7,6 @@
text-align: center text-align: center
margin-top: 0 margin-top: 0
#front-screenshot
margin: 15px 0 40px 150px
#trailer-wrapper
position: relative
margin: 0 auto 40px
width: 950px
iframe
display: block
margin: 0 auto
position: relative
top: 8px
img
position: absolute
left: 0
top: 0
pointer-events: none
.game-mode-wrapper .game-mode-wrapper
position: relative position: relative
margin-bottom: 60px margin-bottom: 60px
@ -244,29 +226,27 @@
#home-view #home-view
#site-slogan #site-slogan
font-size: 30px font-size: 30px
#trailer-wrapper margin-bottom: 30px
display: none .code-languages
#front-screenshot .col-sm-6, .col-sm-3
display: none margin-top: 30px
#mobile-trailer-wrapper .code-language
display: inline-block margin: 0px auto
width: 100%
iframe
display: block
margin: 0 auto
.game-mode-wrapper .game-mode-wrapper
width: 100% width: 100%
img img
width: 100% width: 100%
.play-text .play-text
position: absolute position: absolute
right: 45px right: 15px
bottom: 0px bottom: -15px
color: $yellow color: $yellow
font-size: 50px font-size: 50px
font-family: Bangers font-family: Bangers
@include transition(color .10s linear) @include transition(color .10s linear)
.code-language-logo
right: 0px
top: 5px
h1 h1
text-align: center text-align: center

View file

@ -1,33 +1,19 @@
body body
#fb-root #fb-root
block header block header
.nav.navbar.navbar-fixed-top#mobile-nav .nav.navbar.navbar-fixed-top#top-nav
.content.clearfix .content.clearfix
.navbar-header .navbar-header
button.navbar-toggle(type="button" data-toggle="collapse" data-target="#collapsible-navbar") button.navbar-toggle(type="button" data-toggle="collapse" data-target=".navbar-nav.collapse")
span.sr-only Toggle navigation span.sr-only Toggle navigation
span.icon-bar span.icon-bar
span.icon-bar span.icon-bar
span.icon-bar span.icon-bar
a.navbar-brand(href='/')
img(src="/images/pages/base/logo.png", title="CodeCombat - Learn how to code by playing a game", alt="CodeCombat")
.collapse.navbar-collapse#collapsible-navbar
ul.nav.navbar-nav
li.play
a.header-font(href='/play', data-i18n="nav.play") Levels
li
a.header-font(href='/community', data-i18n="nav.community") Community
.nav.navbar.navbar-fixed-top#top-nav
.content.clearfix
.navbar-header
a.navbar-brand(href='/') a.navbar-brand(href='/')
img(src="/images/pages/base/logo.png", title="CodeCombat - Learn how to code by playing a game", alt="CodeCombat") img(src="/images/pages/base/logo.png", title="CodeCombat - Learn how to code by playing a game", alt="CodeCombat")
select.language-dropdown ul(class='navbar-link-text').nav.navbar-nav.navbar-collapse.collapse
ul(class='navbar-link-text').nav.navbar-nav.pull-right
li.play li.play
a.header-font(href='/play', data-i18n="nav.play") Levels a.header-font(href='/play', data-i18n="nav.play") Levels
li li
@ -65,6 +51,8 @@ body
span(data-i18n="login.log_in") Log In span(data-i18n="login.log_in") Log In
span.spr.spl / span.spr.spl /
span(data-i18n="login.sign_up") Create Account span(data-i18n="login.sign_up") Create Account
li
select.language-dropdown
block outer_content block outer_content
#outer-content-wrapper(class=showBackground ? 'show-background' : '') #outer-content-wrapper(class=showBackground ? 'show-background' : '')

View file

@ -6,7 +6,7 @@ block content
.code-languages .code-languages
.primary-code-languages.row .primary-code-languages.row
.col-md-6 .col-sm-6
.code-language#javascript(data-code-language='javascript') .code-language#javascript(data-code-language='javascript')
.code-wizard .code-wizard
h2 JavaScript h2 JavaScript
@ -17,7 +17,7 @@ block content
span.spr= playCount span.spr= playCount
span(data-i18n="resources.sessions") sessions span(data-i18n="resources.sessions") sessions
.col-md-6 .col-sm-6
.code-language.beta#python(data-code-language='python') .code-language.beta#python(data-code-language='python')
.code-wizard .code-wizard
.code-language-beta .code-language-beta
@ -30,7 +30,7 @@ block content
span(data-i18n="resources.sessions") sessions span(data-i18n="resources.sessions") sessions
.secondary-code-languages.row .secondary-code-languages.row
.col-md-3 .col-sm-3
.code-language.beta#coffeescript(data-code-language='coffeescript') .code-language.beta#coffeescript(data-code-language='coffeescript')
.code-language-logo .code-language-logo
.code-wizard .code-wizard
@ -43,7 +43,7 @@ block content
span.spr= playCount span.spr= playCount
span(data-i18n="resources.sessions") sessions span(data-i18n="resources.sessions") sessions
.col-md-3 .col-sm-3
.code-language.beta#clojure(data-code-language='clojure') .code-language.beta#clojure(data-code-language='clojure')
.code-language-logo .code-language-logo
.code-wizard .code-wizard
@ -56,7 +56,7 @@ block content
span.spr= playCount span.spr= playCount
span(data-i18n="resources.sessions") sessions span(data-i18n="resources.sessions") sessions
.col-md-3 .col-sm-3
.code-language.beta#lua(data-code-language='lua') .code-language.beta#lua(data-code-language='lua')
.code-language-logo .code-language-logo
.code-wizard .code-wizard
@ -69,7 +69,7 @@ block content
span.spr= playCount span.spr= playCount
span(data-i18n="resources.sessions") sessions span(data-i18n="resources.sessions") sessions
.col-md-3 .col-sm-3
.code-language.beta#io(data-code-language='io', title="Careful: Io is still quite buggy") .code-language.beta#io(data-code-language='io', title="Careful: Io is still quite buggy")
.code-language-logo .code-language-logo
.code-wizard .code-wizard

View file

@ -0,0 +1,6 @@
RootView = require 'views/kinds/RootView'
template = require 'templates/base'
module.exports = class BaseView extends RootView
id: 'base-view'
template: template

View file

@ -66,7 +66,6 @@ module.exports = class RootView extends CocoView
#location.hash = '' #location.hash = ''
#location.hash = hash #location.hash = hash
@renderScrollbar() @renderScrollbar()
#@$('.antiscroll-wrap').antiscroll() # not yet, buggy
getRenderData: -> getRenderData: ->
c = super() c = super()