diff --git a/app.js b/app.js index d77bd8b15b..dff8270448 100644 --- a/app.js +++ b/app.js @@ -208,6 +208,7 @@ app.use( app.get('/', homeController.index); app.get('/privacy', resourcesController.privacy); app.get('/jquery-exercises', resourcesController.jqueryExercises); +app.get('/chat', resourcesController.chat); app.get('/live-pair-programming', resourcesController.livePairProgramming); app.get('/install-screenhero', resourcesController.installScreenHero); app.get('/javascript-in-your-inbox', resourcesController.javaScriptInYourInbox); diff --git a/controllers/resources.js b/controllers/resources.js index 86b74627e1..99844a3095 100644 --- a/controllers/resources.js +++ b/controllers/resources.js @@ -55,6 +55,12 @@ module.exports = { }); }, + chat: function chat(req, res) { + res.render('resources/chat', { + title: "Enter Free Code Camp's Chat Rooms" + }); + }, + nonprofitProjectInstructions: function nonprofitProjectInstructions(req, res) { res.render('resources/nonprofit-project-instructions', { title: 'Nonprofit Project Instructions' @@ -142,29 +148,22 @@ module.exports = { var timeDiff = Math.abs(date2.getTime() - date1.getTime()); var daysRunning = Math.ceil(timeDiff / (1000 * 3600 * 24)); var announcements = resources.announcements; - User.count({'points': {'$gt': 2}}, function (err, c3) { + User.count({}, function (err, c3) { if (err) { debug('User err: ', err); next(err); } - User.count({'points': {'$gt': 9}}, function (err, c10) { + User.count({'points': {'$gt': 53}}, function (err, all) { if (err) { debug('User err: ', err); next(err); } - User.count({'points': {'$gt': 53}}, function (err, all) { - if (err) { - debug('User err: ', err); - next(err); - } - res.render('resources/learn-to-code', { - title: 'About Free Code Camp and Our Team of Volunteers', - daysRunning: daysRunning, - c3: c3, - c10: c10, - all: all, - announcements: announcements - }); + res.render('resources/learn-to-code', { + title: 'About Free Code Camp and Our Team of Volunteers', + daysRunning: daysRunning, + c3: c3, + all: all, + announcements: announcements }); }); }); diff --git a/public/css/main.less b/public/css/main.less index eef9b6b785..cf8b467ed8 100644 --- a/public/css/main.less +++ b/public/css/main.less @@ -700,8 +700,13 @@ iframe.iphone { line-height: 150%; } -.github-button-container { - padding-top: 5px; +.github-and-twitter-button-text { + padding-top: 10px; +} + +.gitter-imbed { + height: 100%; + margin-bottom: 50px; } //uncomment this to see the dimensions of all elements outlined in red diff --git a/views/account/account.jade b/views/account/account.jade index 25a0c9c063..5e849b8278 100644 --- a/views/account/account.jade +++ b/views/account/account.jade @@ -2,8 +2,8 @@ extends ../layout block content script. var challengeName = 'Account View' - .panel.panel-primary.min-height-1000(ng-controller="profileValidationController") - .panel-heading.text-center Update your profile here: + .panel.panel-info.min-height-1000(ng-controller="profileValidationController") + .panel-heading.text-center Update your portfolio here: .panel-body .container.text-center form.form-horizontal(action='/account/profile', method='POST', novalidate='novalidate', name='profileForm' ng-show="asyncComplete") @@ -268,75 +268,65 @@ block content span.ion-edit | Update my Portfolio br - .panel.panel-primary - .panel-heading.text-center Actions - .panel-body - .col-xs-12 - if (user.profile.username) - a.btn.btn-lg.btn-block.btn-info.btn-link-social(href='/#{user.profile.username}') Check out my Public Profile - a.btn.btn-lg.btn-block.btn-primary.btn-link-social(href='/challenges') Take me to my current challenge - a.btn.btn-lg.btn-block.btn-warning.btn-link-social(href='/logout') Sign out - br + - if (!user.google || !user.facebook || /*!user.github ||*/ !user.linkedin || !user.twitter) - .panel.panel-primary - .panel-heading.text-center Link other services to your account: + .panel.panel-info + .panel-heading.text-center Manage your account here: .panel-body - if (!user.google) .col-xs-12 a.btn.btn-lg.btn-block.btn-google-plus.btn-link-social(href='/auth/google') i.fa.fa-google-plus - | Link Google with your account + | Link Google with my account - if (!user.facebook) .col-xs-12 a.btn.btn-lg.btn-block.btn-facebook.btn-link-social(href='/auth/facebook') i.fa.fa-facebook - | Link Facebook with your account + | Link Facebook with my account //- if (!user.github) // .col-xs-12 // a.btn.btn-lg.btn-block.btn-github.btn-link-social(href='/auth/github') // i.fa.fa-github - // | Link GitHub with your account + // | Link GitHub with my account - if (!user.linkedin) .col-xs-12 a.btn.btn-lg.btn-block.btn-linkedin.btn-link-social(href='/auth/linkedin') i.fa.fa-linkedin - | Link LinkedIn with your account + | Link LinkedIn with my account - if (!user.twitter) .col-xs-12 a.btn.btn-lg.btn-block.btn-twitter.btn-link-social(href='/auth/twitter') i.fa.fa-twitter - | Link Twitter with your account - - .panel.panel-danger - .panel-heading.text-center Danger Zone: - .panel-body - .col-xs-12.text-center - button.btn.btn-danger.btn-small.confirm-deletion - span.ion-trash-b - | I want to delete my account - br - br - script. - $('.confirm-deletion').on("click", function() { - $('#modal-dialog').modal('show'); - }); - #modal-dialog.modal.animated.wobble - .modal-dialog - .modal-content - .modal-header - a.close(href='#', data-dismiss='modal', aria-hidden='true') × - h3 Are you really leaving us? - .modal-body - p Pro Tip: If you tweet feedback to - a(href="https://twitter.com/intent/tweet?text=Hey%20@freecodecamp") @FreeCodeCamp - | , we'll act quickly on it! - .modal-footer - a.btn.btn-success.btn-block(href='#', data-dismiss='modal', aria-hidden='true') - span.ion-happy - | Nevermind, I'll stick around - br - form(action='/account/delete', method='POST') - input(type='hidden', name='_csrf', value=_csrf) - button.btn.btn-danger.btn-block(type='submit') - span.ion-trash-b - | Yes, Delete my account + | Link Twitter with my account + .col-xs-12 + a.btn.btn-lg.btn-block.btn-warning.btn-link-social(href='/logout') + span.ion-android-exit + | Sign me out of Free Code Camp + .col-xs-12 + a.btn.btn-lg.btn-block.btn-danger.confirm-deletion.btn-link-social + span.ion-trash-b + | Delete my Free Code Camp account + script. + $('.confirm-deletion').on("click", function() { + $('#modal-dialog').modal('show'); + }); + #modal-dialog.modal.animated.wobble + .modal-dialog + .modal-content + .modal-header + a.close(href='#', data-dismiss='modal', aria-hidden='true') × + h3 Are you really leaving us? + .modal-body + p Pro Tip: If you tweet feedback to + a(href="https://twitter.com/intent/tweet?text=Hey%20@freecodecamp") @FreeCodeCamp + | , we'll act quickly on it! + .modal-footer + a.btn.btn-success.btn-block(href='#', data-dismiss='modal', aria-hidden='true') + span.ion-happy + | Nevermind, I'll stick around + br + form(action='/account/delete', method='POST') + input(type='hidden', name='_csrf', value=_csrf) + button.btn.btn-danger.btn-block(type='submit') + span.ion-trash-b + | Yes, Delete my account diff --git a/views/account/show.jade b/views/account/show.jade index ad95d1b91b..8194c4b107 100644 --- a/views/account/show.jade +++ b/views/account/show.jade @@ -1,10 +1,15 @@ extends ../layout block content .col-xs-12.col-sm-12.col-md-12 - .panel.panel-primary + .panel.panel-info .panel-heading.text-center h1 #{username}'s portfolio .panel-body + if (user && user.profile.username === username) + .col-xs-12 + .text-center + a.btn.btn-big.btn-primary(href="/account") Update my public portfolio + br .row .col-xs-12 .col-xs-12.col-sm-12.col-md-5 @@ -35,9 +40,6 @@ block content h3.flat-top.bolded.wrappable= location h4.flat-top.wrappable= bio .col-xs-12.col-sm-12.col-md-3.text-center - if (user && user.profile.username === username) - a.btn.btn-warning(href="/account") Edit my Profile - .background-svg.img-center .points-on-top = "[ " + points + " ]" diff --git a/views/account/signin.jade b/views/account/signin.jade index 053085e1d0..b32eab5057 100644 --- a/views/account/signin.jade +++ b/views/account/signin.jade @@ -14,9 +14,9 @@ block content a.btn.btn-lg.btn-block.btn-linkedin.btn-social(href='/auth/linkedin') i.fa.fa-linkedin | Sign in with LinkedIn - //a.btn.btn-lg.btn-block.btn-twitter.btn-social(href='/auth/twitter') - // i.fa.fa-twitter - // | Sign in with Twitter + a.btn.btn-lg.btn-block.btn-twitter.btn-social(href='/auth/twitter') + i.fa.fa-twitter + | Sign in with Twitter br p a(href="/email-signup") Or sign up using your email address here. diff --git a/views/partials/faq.jade b/views/partials/faq.jade index 6b55904968..19144be470 100644 --- a/views/partials/faq.jade +++ b/views/partials/faq.jade @@ -36,23 +36,23 @@ table.table thead th Time budgeted - th Hours per week + th.hidden-xs Hours per week th Weeks to complete tr.info td Weekends - td 10 hours/week + td.hidden-xs 10 hours/week td 100 weeks (2 years) tr.success td Nights and Weekends - td 20 hours/week + td.hidden-xs 20 hours/week td 50 weeks (1 year) tr.warning td Full time - td 40 hours/week + td.hidden-xs 40 hours/week td 25 weeks (6 months) tr.danger td Traditional Bootcamp Pacing - td 80 hours/week + td.hidden-xs 80 hours/week td 12 weeks (3 months) h2 Why does Free Code Camp use JavaScript instead of Ruby or Python? ul diff --git a/views/partials/github.jade b/views/partials/github.jade index 2b0b77e914..51a549c290 100644 --- a/views/partials/github.jade +++ b/views/partials/github.jade @@ -7,7 +7,7 @@ script. }).done( function(data) { var github = document.createElement('div'); - $(github).html('