diff --git a/app/locale/ja.coffee b/app/locale/ja.coffee index a4cbdedb6..83f9e28d3 100644 --- a/app/locale/ja.coffee +++ b/app/locale/ja.coffee @@ -566,8 +566,8 @@ module.exports = nativeDescription: "日本語", englishDescription: "Japanese", rob_blurb: "コードの道具と材料" josh_c_title: "ゲームデザイナー" josh_c_blurb: "ゲームのデザイン" -# robin_title: "UX Design & Research" -# robin_blurb: "Scaffolding" + robin_title: "デザイン&研究" + robin_blurb: "土台作り" josh_title: "ゲームデザイナー" josh_blurb: "床は溶岩" retrostyle_title: "イラスト" diff --git a/app/styles/home.sass b/app/styles/home.sass index 61458923f..6857d6f29 100644 --- a/app/styles/home.sass +++ b/app/styles/home.sass @@ -126,11 +126,13 @@ top: 400px width: 380px z-index: 1 + + .glyphicon-remove:hover + text-decoration: none + .btn margin: 10px 0 - @media screen and ( max-width: 1000px ) - display: none @media screen and ( max-height: 800px ) top: 200px diff --git a/app/styles/new-home-view.sass b/app/styles/new-home-view.sass index 5afcefe2e..edcc284af 100644 --- a/app/styles/new-home-view.sass +++ b/app/styles/new-home-view.sass @@ -139,6 +139,18 @@ $forest: #20572B .language-dropdown width: 150px + .img-circle + border: $gold 8px solid + width: 98px + height: 98px // Includes the border + + .user-level + position: absolute + top: 76px + right: 42px + color: $gold + text-shadow: 1px 1px black, -1px -1px 0 black, 1px -1px 0 black, -1px 1px 0 black + // Buttons .btn @@ -221,11 +233,12 @@ $forest: #20572B line-height: 45px .well + border: none border-radius: 8px background: rgba(255, 255, 255, 0.5) margin-top: 170px #classroom-edition-header - margin-top: 40px + margin-top: 10px #learn-to-code-header margin-top: 80px @@ -233,9 +246,10 @@ $forest: #20572B margin-top: 80px h2, h6 color: white - h6 margin-top: 10px + a:hover + text-decoration: none &.alt-image background-image: url("/images/pages/home/student_jumbotron.png") @@ -362,12 +376,15 @@ $forest: #20572B display: inline-block width: 250px - #request-demo-row + .request-demo-row margin: 100px 0 .btn margin: 20px 10px + #total-hours-header + margin-top: 10px + #courses-container display: flex flex-wrap: wrap diff --git a/app/templates/home-view.jade b/app/templates/home-view.jade index af53357e4..75da07cb7 100644 --- a/app/templates/home-view.jade +++ b/app/templates/home-view.jade @@ -42,10 +42,11 @@ block outer_content if view.withTeacherNote .style-flat .bg-navy + a#close-teacher-note-link.glyphicon.glyphicon-remove.pull-right h3 Teachers! h4 Want the most engaging way to teach programming at your school? .text-center a.btn.btn-primary-alt.btn-lg(href="/teachers/quote") Request a Quote h6 - a.small(href="/home") Learn More + a.small(href="/schools") Learn More \ No newline at end of file diff --git a/app/templates/new-home-view.jade b/app/templates/new-home-view.jade index ebade0168..2af17452c 100644 --- a/app/templates/new-home-view.jade +++ b/app/templates/new-home-view.jade @@ -8,19 +8,45 @@ nav.navbar.navbar-default span.icon-bar a.navbar-brand(href="/") img#logo-img(src="/images/pages/base/logo.png") + span.glyphicon.glyphicon-home #navbar-collapse.collapse.navbar-collapse ul.nav.navbar-nav li a(href="/about") About + li + a(href="/courses") Courses li a(href="/courses/teachers") Teachers li a(href="https://discourse.codecombat.com/") Forum - li - a#create-account-link.signup-button Signup - li - a#login-link.login-button Login + if me.isAnonymous() + li + a#create-account-link.signup-button Create Account + li + a#login-link.login-button Login + else + li.dropdown + a.dropdown-toggle(href="#", data-toggle="dropdown" role="button" aroa-haspopup="true" aria-expanded="false") + span.spr My Account + ul.dropdown-menu + li.user-dropdown-header.text-center + span.user-level= me.level() + a(href="/user/#{me.getSlugOrID()}") + img.img-circle(src=me.getPhotoURL()) + h5=me.displayName() + li + a(href="/user/#{me.getSlugOrID()}" data-i18n="nav.profile") + li + a(href="/account/settings", data-i18n="play.settings") + li + a(href="/account/payments", data-i18n="account.payments") + li + a(href="/account/subscription", data-i18n="account.subscription") + li + a(href="/account/prepaid", data-i18n="account.prepaid_codes") Prepaid Codes + li + a#logout-button(data-i18n="login.log_out") #language-dropdown-wrapper.pull-right.hidden-xs.hidden-sm select.language-dropdown.form-control @@ -154,7 +180,7 @@ nav.navbar.navbar-default img(src="/images/pages/home/G3_game.png") #benefit-graphic-3-filler - #request-demo-row.text-center + .request-demo-row.text-center h3 Curious? Request a demo and we'll show you the ropes h4 Or create a class and see it for yourself! p @@ -168,7 +194,9 @@ nav.navbar.navbar-default option(value='elementary') Elementary School option(value='middle', selected=true) Middle School option(value='high') High School - h4#semester-duration.text-center + h5.text-center#total-hours-header + span.spr Total curriculum hours: + span#semester-duration #courses-container - var conceptsSeen = {}; - var lastScreenshot = ""; @@ -189,7 +217,7 @@ nav.navbar.navbar-default span.spr , - pastFirstConcept = true; span(data-i18n="concepts." + concept) - .media-object(style="background-image: url(" + course.get('screenshot') + ")") + img.media-object(src="/images/pages/home/course"+(courseIndex+1)+".png") - lastScreenshot = course.get('screenshot'); h6.course-duration span.spr Lesson time: diff --git a/app/views/HomeView.coffee b/app/views/HomeView.coffee index 63062281d..72d59bc13 100644 --- a/app/views/HomeView.coffee +++ b/app/views/HomeView.coffee @@ -7,6 +7,7 @@ module.exports = class HomeView extends RootView events: 'click #play-button': 'onClickPlayButton' + 'click #close-teacher-note-link': 'onClickCloseTeacherNoteLink' constructor: (options={}) -> super() @@ -56,3 +57,6 @@ module.exports = class HomeView extends RootView isNewPlayer: -> not me.get('stats')?.gamesCompleted and not me.get('heroConfig') + + onClickCloseTeacherNoteLink: -> + @$('.style-flat').addClass('hide') diff --git a/app/views/NewHomeView.coffee b/app/views/NewHomeView.coffee index a8806d1e8..ce4d898ae 100644 --- a/app/views/NewHomeView.coffee +++ b/app/views/NewHomeView.coffee @@ -72,4 +72,4 @@ module.exports = class NewHomeView extends RootView @scrollToLink('#classroom-in-box-container') onClickTeacherButton: -> - @scrollToLink('#request-demo-row', 600) + @scrollToLink('.request-demo-row', 600) diff --git a/app/views/core/CocoView.coffee b/app/views/core/CocoView.coffee index fc6175994..1c133e7a8 100644 --- a/app/views/core/CocoView.coffee +++ b/app/views/core/CocoView.coffee @@ -441,9 +441,8 @@ module.exports = class CocoView extends Backbone.View slider scrollToLink: (link, speed=300) -> - $('#page-container').animate({ - scrollTop: $(link).offset().top - }, speed) + scrollTo = $(link).offset().top + $('#page-container')[0].scrollTop + $('#page-container').animate({ scrollTop: scrollTo }, speed) toggleFullscreen: (e) -> # https://developer.mozilla.org/en-US/docs/Web/Guide/API/DOM/Using_full_screen_mode?redirectlocale=en-US&redirectslug=Web/Guide/DOM/Using_full_screen_mode