Merge branch 'interview' into staging

Conflicts:
	app.js
	controllers/challenge.js
	seed/future-jquery-ajax-json.json
This commit is contained in:
Quincy Larson
2015-06-14 01:02:39 -07:00
8 changed files with 446 additions and 195 deletions

View File

@ -176,8 +176,8 @@ ul {
font-size: 26px; font-size: 26px;
} }
.ten-pixel-break { .five-pixel-break {
height: 10px; height: 5px;
} }
.fifteen-pixel-break { .fifteen-pixel-break {
@ -201,12 +201,12 @@ ul {
.responsive-container { position: relative; padding-bottom: 56.25%; padding-top: 30px; height: 0; overflow: hidden; } .responsive-container { position: relative; padding-bottom: 56.25%; padding-top: 30px; height: 0; overflow: hidden; }
.responsive-container iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; } .responsive-container iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }
.positive-5 { .positive-10 {
margin-top: 5px; margin-top: 10px;
} }
.positive-10 { .positive-15-bottom {
padding-top: 10px; margin-bottom: 15px;
} }
.positive-15 { .positive-15 {
@ -251,6 +251,10 @@ ul {
margin-top: -20px; margin-top: -20px;
} }
.negative-bottom-margin-30 {
margin-bottom: -30px;
}
.large-p { .large-p {
font-size: 18px; font-size: 18px;
} }

View File

@ -90,7 +90,7 @@ var testResults = [];
var postSuccess = function(data) { var postSuccess = function(data) {
var testDoc = document.createElement("div"); var testDoc = document.createElement("div");
$(testDoc) $(testDoc)
.html("<div class='row'><div class='col-xs-2 text-center'><i class='ion-checkmark-circled big-success-icon'></i></div><div class='col-xs-10 test-output test-vertical-center wrappable'>" + JSON.parse(data) + "</div></div><div class='ten-pixel-break'/>"); .html("<div class='row'><div class='col-xs-2 text-center'><i class='ion-checkmark-circled big-success-icon'></i></div><div class='col-xs-10 test-output test-vertical-center wrappable'>" + JSON.parse(data) + "</div>");
$('#testSuite').append(testDoc); $('#testSuite').append(testDoc);
testSuccess(); testSuccess();
}; };
@ -98,7 +98,7 @@ var postSuccess = function(data) {
var postError = function(data) { var postError = function(data) {
var testDoc = document.createElement("div"); var testDoc = document.createElement("div");
$(testDoc) $(testDoc)
.html("<div class='row'><div class='col-xs-2 text-center'><i class='ion-close-circled big-error-icon'></i></div><div class='col-xs-10 test-vertical-center test-output wrappable'>" + JSON.parse(data) + "</div></div><div class='ten-pixel-break'/>"); .html("<div class='row'><div class='col-xs-2 text-center'><i class='ion-close-circled big-error-icon'></i></div><div class='col-xs-10 test-vertical-center test-output wrappable'>" + JSON.parse(data) + "</div>");
$('#testSuite').append(testDoc); $('#testSuite').append(testDoc);
}; };
var goodTests = 0; var goodTests = 0;

View File

@ -3,6 +3,7 @@
var tests = parent.tests; var tests = parent.tests;
var editor = parent.editorValueForIFrame; var editor = parent.editorValueForIFrame;
setTimeout(function() {
for (var i = 0; i < tests.length; i++) { for (var i = 0; i < tests.length; i++) {
var thisTest = true; var thisTest = true;
try { try {
@ -13,8 +14,10 @@
parent.postError(JSON.stringify(err.message.split(':').shift())); parent.postError(JSON.stringify(err.message.split(':').shift()));
} finally { } finally {
if (thisTest) { if (thisTest) {
parent.postSuccess(JSON.stringify(tests[i].split(',').pop().replace(/\'/g, '').replace(/\)/, ''))); parent.postSuccess(JSON.stringify(tests[i].split(',').pop().replace(
/\'/g, '').replace(/\)/, '')));
} }
} }
} }
}, 10);
})(); })();

View File

@ -46,9 +46,8 @@
"dashedName": "bonfire-meet-bonfire", "dashedName": "bonfire-meet-bonfire",
"difficulty": "0", "difficulty": "0",
"description": [ "description": [
"Click the button below for further instructions.",
"Your goal is to fix the failing test.", "Your goal is to fix the failing test.",
"First, run all the tests by clicking \"Run code\" or by pressing Control + Enter", "First, run all the tests by clicking \"Run code\" or by pressing Control + Enter.",
"The failing test is in red. Fix the code so that all tests pass. Then you can move on to the next Bonfire.", "The failing test is in red. Fix the code so that all tests pass. Then you can move on to the next Bonfire.",
"Make this function return true no matter what." "Make this function return true no matter what."
], ],

View File

@ -1,73 +1,231 @@
{ {
"name": "jQuery, Ajax and JSON", "name": "jQuery, Ajax and JSON",
"order": 0.004, "order": 0.004,
"challenges": [ "challenges": [{
{
"id": "bad87fee1348bd9acdd08826", "id": "bad87fee1348bd9acdd08826",
"name": "Waypoint: Learn how Script Tags and Document Ready Work", "name": "Waypoint: Learn how Script Tags and Document Ready Work",
"difficulty": 0.072, "difficulty": 0.072,
"description": [ "description": [
"Test" "We've simplified our Cat Photo App and removed our <code>style</code> element. Add a <code>script</code> element to your page and create a <code>$(document).ready</code> function within it.",
"Add <code>$(document).ready(function() {</code> to your <code>script</code> element, and then close it on the following line with <code>});</code>."
], ],
"tests": [ "tests": [
"assert(typeof $('#target').attr('disabled') === 'undefined', 'Change the disabled attribute of the \"target\" button to false');", "assert(editor.match(/<script>/g), 'Create a <code>script</code> element.')",
"expect($('#target')).to.exist()" "assert(editor.match(/<\\/script>/g) && editor.match(/<script/g) && editor.match(/<\\/script>/g).length === editor.match(/<script/g).length, 'Make sure your <code>script</code> element has a closing tag.')",
"assert(editor.match(/\\$\\(document\\)\\.ready\\(function\\(\\)\\s?\\{/g), 'Add <code>$(document).ready(function() {</code> to the beginning of your <code>script</code> element.')",
"assert(editor.match(/\\n\\s+?\\}\\);/g), 'Close your <code>$(document).ready(function() {</code> function with <code>\\}\\);</code>.')"
],
"challengeSeed": [
"<br>",
"<img src='http://bit.ly/fcc-kittens2' class='img-responsive'>",
"<br>",
"<div class='row'>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-primary'><i class='fa fa-thumbs-up'></i> Like</button>",
" </div>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-info'><i class='fa fa-info-circle'></i> Info</button>",
" </div>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-danger'><i class='fa fa-trash'></i> Delete</button>",
" </div>",
"</div>",
"<br>",
"<form action='submit-cat-photo'>",
" <div class='row'>",
" <div class='col-xs-7'>",
" <input type='text' class='form-control' placeholder='cat photo URL' required>",
" </div>",
" <div class='col-xs-5'>",
" <button type='submit' class='btn btn-primary'><i class='fa fa-paper-plane'></i> Submit</button>",
" </div>",
" </div>",
"</form>"
],
"challengeType": 0
},
{
"id": "bad87fee1348bd9bedc08826",
"name": "Waypoint: Target Elements by Selectors Using jQuery",
"difficulty": 0.073,
"description": [
"Make all <code>img</code> elements bounce $('img').addClass('animated bounce')"
],
"tests": [
"assert($('img').hasClass('animated') && $('img').hasClass('bounce'), 'Use the jQuery <code>addClass()</code> function to give the classes \"animated\" and \"bounce\" to your <code>img</code> element.')",
"assert(!editor.match(/class.*animated/g), 'Only use jQuery to add these classes to the element.')"
], ],
"challengeSeed": [ "challengeSeed": [
"fccss", "fccss",
" $(document).ready(function() {", " $(document).ready(function() {",
" $('#target').attr('disabled', true)", "",
" });", " });",
"fcces", "fcces",
"<button id='target' class='btn btn-primary btn-block'>Enable this button with jQuery</button>" "<br>",
"<img src='http://bit.ly/fcc-kittens2' class='img-responsive'>",
"<br>",
"<div class='row'>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-primary'><i class='fa fa-thumbs-up'></i> Like</button>",
" </div>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-info'><i class='fa fa-info-circle'></i> Info</button>",
" </div>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-danger'><i class='fa fa-trash'></i> Delete</button>",
" </div>",
"</div>",
"<br>",
"<form action='submit-cat-photo'>",
" <div class='row'>",
" <div class='col-xs-7'>",
" <input type='text' class='form-control' placeholder='cat photo URL' required>",
" </div>",
" <div class='col-xs-5'>",
" <button type='submit' class='btn btn-primary'><i class='fa fa-paper-plane'></i> Submit</button>",
" </div>",
" </div>",
"</form>"
], ],
"challengeType": 0 "challengeType": 0
}, },
{ {
"id": "bad87fee1348bd9aedc08826", "id": "bad87fee1348bd9aedc08826",
"name": "Waypoint: Target Elements by Selectors Using jQuery",
"difficulty": 0.073,
"description": [
],
"tests": [
],
"challengeSeed": [
],
"challengeType": 0
},
{
"id": "bad87fee1348bd9aedb08826",
"name": "Waypoint: Target Elements by Class Using jQuery", "name": "Waypoint: Target Elements by Class Using jQuery",
"difficulty": 0.074, "difficulty": 0.074,
"description": [ "description": [
], ],
"tests": [ "tests": [
"assert($('.btn').hasClass('animated') && $('.btn').hasClass('shake'), 'Use the jQuery <code>addClass()</code> function to give the classes \"animated\" and \"shake\" to all your elements with the class \"btn\".')",
"assert(!editor.match(/class.*animated/g), 'Only use jQuery to add these classes to the element.')"
], ],
"challengeSeed": [ "challengeSeed": [
"fccss",
" $(document).ready(function() {",
" $('img').addClass('animated bounce');",
" });",
"fcces",
"<br>",
"<img src='http://bit.ly/fcc-kittens2' class='img-responsive'>",
"<br>",
"<div class='row'>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-primary'><i class='fa fa-thumbs-up'></i> Like</button>",
" </div>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-info'><i class='fa fa-info-circle'></i> Info</button>",
" </div>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-danger'><i class='fa fa-trash'></i> Delete</button>",
" </div>",
"</div>",
"<br>",
"<form action='submit-cat-photo'>",
" <div class='row'>",
" <div class='col-xs-7'>",
" <input type='text' class='form-control' placeholder='cat photo URL' required>",
" </div>",
" <div class='col-xs-5'>",
" <button type='submit' class='btn btn-primary'><i class='fa fa-paper-plane'></i> Submit</button>",
" </div>",
" </div>",
"</form>"
],
"challengeType": 0
},
{
"id": "bad87fee1348bd9aedb08826",
"name": "Waypoint: Add an ID to an Element",
"difficulty": 0.075,
"description": [
],
"tests": [
"assert($('form').attr('id') === 'cat-photo-form', 'Add the ID of \"cat-photo-form\" to your <code>form</code> element.')"
],
"challengeSeed": [
"fccss",
" $(document).ready(function() {",
" $('img').addClass('animated bounce');",
" $('.btn').addClass('animated shake');",
" });",
"fcces",
"<br>",
"<img src='http://bit.ly/fcc-kittens2' class='img-responsive'>",
"<br>",
"<div class='row'>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-primary'><i class='fa fa-thumbs-up'></i> Like</button>",
" </div>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-info'><i class='fa fa-info-circle'></i> Info</button>",
" </div>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-danger'><i class='fa fa-trash'></i> Delete</button>",
" </div>",
"</div>",
"<br>",
"<form action='submit-cat-photo'>",
" <div class='row'>",
" <div class='col-xs-7'>",
" <input type='text' class='form-control' placeholder='cat photo URL' required>",
" </div>",
" <div class='col-xs-5'>",
" <button type='submit' class='btn btn-primary'><i class='fa fa-paper-plane'></i> Submit</button>",
" </div>",
" </div>",
"</form>"
], ],
"challengeType": 0 "challengeType": 0
}, },
{ {
"id": "bad87fee1348bd9aeda08826", "id": "bad87fee1348bd9aeda08826",
"name": "Waypoint: Target an element by ID Using jQuery", "name": "Waypoint: Target Elements by ID Using jQuery",
"difficulty": 0.075, "difficulty": 0.075,
"description": [ "description": [
], ],
"tests": [ "tests": [
"assert($('#cat-photo-form') && $('#cat-photo-form').hasClass('animated') && $('#cat-photo-form').hasClass('pulse'), 'Select the element with the <code>id</code> of \"cat-photo-form\" and use the jQuery <code>addClass()</code> function to give it the classes of \"animated\" and \"pulse\".')",
"assert(!editor.match(/class.*animated/g), 'Only use jQuery to add these classes to the element.')"
], ],
"challengeSeed": [ "challengeSeed": [
"fccss",
" $(document).ready(function() {",
" $('img').addClass('animated bounce');",
" $('.btn').addClass('animated shake');",
" });",
"fcces",
"<br>",
"<img src='http://bit.ly/fcc-kittens2' class='img-responsive'>",
"<br>",
"<div class='row'>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-primary'><i class='fa fa-thumbs-up'></i> Like</button>",
" </div>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-info'><i class='fa fa-info-circle'></i> Info</button>",
" </div>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-danger'><i class='fa fa-trash'></i> Delete</button>",
" </div>",
"</div>",
"<br>",
"<form action='submit-cat-photo' id='cat-photo-form'>",
" <div class='row'>",
" <div class='col-xs-7'>",
" <input type='text' class='form-control' placeholder='cat photo URL' required>",
" </div>",
" <div class='col-xs-5'>",
" <button type='submit' class='btn btn-primary'><i class='fa fa-paper-plane'></i> Submit</button>",
" </div>",
" </div>",
"</form>"
], ],
"challengeType": 0 "challengeType": 0
}, },
@ -80,10 +238,42 @@
], ],
"tests": [ "tests": [
"assert(!editor.match(/nce\\'\\)\\;/g) && !editor.match(/ke\\'\\)\\;/g), 'Delete your <code>img</code> element selector statement and your \".btn\" selector statement.')",
"assert(editor.match(/css.*,.*background-color.*gray.\\);/g), 'Select the element with the <code>id</code> of \"cat-photo-form\" give it the background color of gray.')"
], ],
"challengeSeed": [ "challengeSeed": [
"fccss",
" $(document).ready(function() {",
" $('img').addClass('animated bounce');",
" $('.btn').addClass('animated shake');",
" $('#cat-photo-form').addClass('animated pulse');",
" });",
"fcces",
"<br>",
"<img src='http://bit.ly/fcc-kittens2' class='img-responsive'>",
"<br>",
"<div class='row'>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-primary'><i class='fa fa-thumbs-up'></i> Like</button>",
" </div>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-info'><i class='fa fa-info-circle'></i> Info</button>",
" </div>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-danger'><i class='fa fa-trash'></i> Delete</button>",
" </div>",
"</div>",
"<br>",
"<form action='submit-cat-photo' id='cat-photo-form'>",
" <div class='row'>",
" <div class='col-xs-7'>",
" <input type='text' class='form-control' placeholder='cat photo URL' required>",
" </div>",
" <div class='col-xs-5'>",
" <button type='submit' class='btn btn-primary'><i class='fa fa-paper-plane'></i> Submit</button>",
" </div>",
" </div>",
"</form>"
], ],
"challengeType": 0 "challengeType": 0
}, },
@ -96,10 +286,40 @@
], ],
"tests": [ "tests": [
"assert($('form button').attr('id') === 'submit-button', 'Add the ID of \"submit-button\" to your the <code>button</code> on your <code>form</code> element.')",
"assert($('#submit-button') && $('#submit-button').prop('disabled'), 'Disable your element with the id of \"submit-button\".')"
], ],
"challengeSeed": [ "challengeSeed": [
"fccss",
" $(document).ready(function() {",
" $('#cat-photo-form').css('background-color', 'gray');",
" });",
"fcces",
"<br>",
"<img src='http://bit.ly/fcc-kittens2' class='img-responsive'>",
"<br>",
"<div class='row'>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-primary'><i class='fa fa-thumbs-up'></i> Like</button>",
" </div>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-info'><i class='fa fa-info-circle'></i> Info</button>",
" </div>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-danger'><i class='fa fa-trash'></i> Delete</button>",
" </div>",
"</div>",
"<br>",
"<form action='submit-cat-photo' id='cat-photo-form'>",
" <div class='row'>",
" <div class='col-xs-7'>",
" <input type='text' class='form-control' placeholder='cat photo URL' required>",
" </div>",
" <div class='col-xs-5'>",
" <button type='submit' class='btn btn-primary'><i class='fa fa-paper-plane'></i> Submit</button>",
" </div>",
" </div>",
"</form>"
], ],
"challengeType": 0 "challengeType": 0
}, },
@ -112,10 +332,41 @@
], ],
"tests": [ "tests": [
"assert($('img').length === 0, 'Use jQuery to remove your <code>img</code> element from your page.')",
"assert(editor.match(/<img/g), 'You should still have an <code>img</code> element in your HTML but jQuery should remove it.')"
], ],
"challengeSeed": [ "challengeSeed": [
"fccss",
" $(document).ready(function() {",
" $('#cat-photo-form').css('background-color', 'gray');",
" $('#submit-button').prop('disabled', 'true');",
" });",
"fcces",
"<br>",
"<img src='http://bit.ly/fcc-kittens2' class='img-responsive'>",
"<br>",
"<div class='row'>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-primary'><i class='fa fa-thumbs-up'></i> Like</button>",
" </div>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-info'><i class='fa fa-info-circle'></i> Info</button>",
" </div>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-danger'><i class='fa fa-trash'></i> Delete</button>",
" </div>",
"</div>",
"<br>",
"<form action='submit-cat-photo' id='cat-photo-form'>",
" <div class='row'>",
" <div class='col-xs-7'>",
" <input type='text' class='form-control' placeholder='cat photo URL' required>",
" </div>",
" <div class='col-xs-5'>",
" <button type='submit' id='submit-button' class='btn btn-primary'><i class='fa fa-paper-plane'></i> Submit</button>",
" </div>",
" </div>",
"</form>"
], ],
"challengeType": 0 "challengeType": 0
}, },
@ -125,7 +376,38 @@
"name": "Waypoint: Move an Element Using jQuery", "name": "Waypoint: Move an Element Using jQuery",
"difficulty": 0.079, "difficulty": 0.079,
"description": [ "description": [
"fccss",
" $(document).ready(function() {",
" $('#cat-photo-form').css('background-color', 'gray');",
" $('#submit-button').prop('disabled', 'true');",
" $('img').remove();",
" });",
"fcces",
"<br>",
"<img src='http://bit.ly/fcc-kittens2' class='img-responsive'>",
"<br>",
"<div class='row'>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-primary'><i class='fa fa-thumbs-up'></i> Like</button>",
" </div>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-info'><i class='fa fa-info-circle'></i> Info</button>",
" </div>",
" <div class='col-xs-4'>",
" <button class='btn btn-block btn-danger'><i class='fa fa-trash'></i> Delete</button>",
" </div>",
"</div>",
"<br>",
"<form action='submit-cat-photo' id='cat-photo-form'>",
" <div class='row'>",
" <div class='col-xs-7'>",
" <input type='text' class='form-control' placeholder='cat photo URL' required>",
" </div>",
" <div class='col-xs-5'>",
" <button type='submit' id='submit-button' class='btn btn-primary'><i class='fa fa-paper-plane'></i> Submit</button>",
" </div>",
" </div>",
"</form>"
], ],
"tests": [ "tests": [
@ -152,22 +434,6 @@
"challengeType": 0 "challengeType": 0
}, },
{
"id": "bad87fee1348bd9aed408826",
"name": "Waypoint: Animate an Element Using jQuery",
"difficulty": 0.081,
"description": [
],
"tests": [
],
"challengeSeed": [
],
"challengeType": 0
},
{ {
"id": "bad87fee1348bd9aed308826", "id": "bad87fee1348bd9aed308826",
"name": "Waypoint: Target the Parent of an Element Using jQuery", "name": "Waypoint: Target the Parent of an Element Using jQuery",
@ -295,8 +561,7 @@
], ],
"challengeType": 0 "challengeType": 0
}, }, {
{
"id": "bad87fee1348bd9aede08826", "id": "bad87fee1348bd9aede08826",
"name": "Waypoint: Use Hex Codes for Precise Colors", "name": "Waypoint: Use Hex Codes for Precise Colors",
"difficulty": 0.071, "difficulty": 0.071,
@ -310,8 +575,7 @@
], ],
"challengeType": 0 "challengeType": 0
}, }, {
{
"id": "bad87fee1348bd9aedd08826", "id": "bad87fee1348bd9aedd08826",
"name": "Waypoint: Use Shortened Hex Codes for Colors", "name": "Waypoint: Use Shortened Hex Codes for Colors",
"difficulty": 0.071, "difficulty": 0.071,

View File

@ -17,11 +17,11 @@ block content
script(type='text/javascript', src='/js/lib/coursewares/sandbox.js') script(type='text/javascript', src='/js/lib/coursewares/sandbox.js')
.row(ng-controller="pairedWithController") .row(ng-controller="pairedWithController")
.col-xs-12.col-sm-12.col-md-4.bonfire-top .col-xs-12.col-sm-12.col-md-4.col-lg-3
#testCreatePanel #testCreatePanel.well
h1#bonfire-name.text-center= name h3.text-center.negative-10= name
h2.text-center .positive-15.positive-15-bottom
.bonfire-flames Difficulty:&thinsp; h4.text-center.bonfire-flames Difficulty:&thinsp;
if (difficulty == "0") if (difficulty == "0")
i.ion-ios-flame-outline i.ion-ios-flame-outline
i.ion-ios-flame-outline i.ion-ios-flame-outline
@ -58,30 +58,21 @@ block content
i.ion-ios-flame i.ion-ios-flame
i.ion-ios-flame i.ion-ios-flame
i.ion-ios-flame i.ion-ios-flame
.well
.row .row
.col-xs-12 .col-xs-12
.bonfire-instructions .bonfire-instructions
p.wrappable= brief
#brief-instructions
#more-info.btn.btn-primary.btn-block.btn-primary-ghost
span.ion-arrow-down-b
| More information
#long-instructions.row.hide
.col-xs-12
for sentence in details for sentence in details
p.wrappable!= sentence p.wrappable.negative-10!= sentence
.negative-bottom-margin-30
#MDN-links #MDN-links
p Here are some helpful links: p.negative-10 Here are some helpful links:
for link, index in MDNlinks for link, index in MDNlinks
.negative-10
ul: li: a(href=""+link, target="_blank") !{MDNkeys[index]} ul: li: a(href=""+link, target="_blank") !{MDNkeys[index]}
#less-info.btn.btn-primary.btn-block.btn-primary-ghost
span.ion-arrow-up-b
| Less information
if (user) if (user)
form.form-horizontal(novalidate='novalidate', name='completedWithForm') form.form-horizontal(novalidate='novalidate', name='completedWithForm')
.form-group.text-center .form-group.text-center.negative-10
.col-xs-12 .col-xs-12
// extra field to distract password tools like lastpass from injecting css into our username field // extra field to distract password tools like lastpass from injecting css into our username field
input.form-control(ng-show="false") input.form-control(ng-show="false")
@ -90,7 +81,10 @@ block content
alert(type='danger') alert(type='danger')
span.ion-close-circled span.ion-close-circled
| Username not found | Username not found
#submitButton.btn.btn-primary.btn-big.btn-block Run code (ctrl + enter) label.negative-10.btn.btn-primary.btn-block#submitButton
i.fa.fa-play
| &nbsp; Run code (ctrl + enter)
if (user && user.sentSlackInvite) if (user && user.sentSlackInvite)
.button-spacer .button-spacer
.btn-group.input-group.btn-group-justified .btn-group.input-group.btn-group-justified
@ -108,7 +102,7 @@ block content
.form-group.codeMirrorView .form-group.codeMirrorView
textarea#codeOutput(style='display: none;') textarea#codeOutput(style='display: none;')
br br
#testSuite #testSuite.negative-10
br br
script(type="text/javascript"). script(type="text/javascript").
var tests = !{JSON.stringify(tests)}; var tests = !{JSON.stringify(tests)};
@ -140,7 +134,6 @@ block content
a.animated.fadeIn.btn.btn-lg.btn-primary.btn-block#next-courseware-button(name='_csrf', value=_csrf) Go to my next challenge (ctrl + enter) a.animated.fadeIn.btn.btn-lg.btn-primary.btn-block#next-courseware-button(name='_csrf', value=_csrf) Go to my next challenge (ctrl + enter)
if (user.progressTimestamps.length > 2) if (user.progressTimestamps.length > 2)
a.animated.fadeIn.btn.btn-lg.btn-block.btn-twitter(target="_blank", href="https://twitter.com/intent/tweet?text=I%20just%20#{verb}%20%40FreeCodeCamp%20#{name}&url=http%3A%2F%2Ffreecodecamp.com/challenges/#{dashedName}&hashtags=LearnToCode, JavaScript") a.animated.fadeIn.btn.btn-lg.btn-block.btn-twitter(target="_blank", href="https://twitter.com/intent/tweet?text=I%20just%20#{verb}%20%40FreeCodeCamp%20#{name}&url=http%3A%2F%2Ffreecodecamp.com/challenges/#{dashedName}&hashtags=LearnToCode, JavaScript")
i.fa.fa-twitter &thinsp; i.fa.fa-twitter &thinsp;

View File

@ -20,31 +20,20 @@ block content
script(src='/js/lib/codemirror/mode/htmlmixed/htmlmixed.js') script(src='/js/lib/codemirror/mode/htmlmixed/htmlmixed.js')
script(src='/js/lib/codemirror/addon/emmet/emmet.js') script(src='/js/lib/codemirror/addon/emmet/emmet.js')
.row.courseware-height .row.courseware-height
.vertical-scroll
.col-xs-12.col-sm-12.col-md-3.col-lg-3 .col-xs-12.col-sm-12.col-md-3.col-lg-3
.well .well
.row .row
.col-xs-12 .col-xs-12
h2.text-center= name h3.text-center.negative-10= name
.bonfire-instructions .bonfire-instructions
p.wrappable!= brief
#brief-instructions
#more-info.btn.btn-primary.btn-block.btn-primary-ghost
span.ion-arrow-down-b
| More information
#long-instructions.row.hide
.col-xs-12
for sentence in details for sentence in details
p.wrappable!= sentence p.wrappable.negative-10!= sentence
#less-info.btn.btn-primary.btn-block.btn-primary-ghost .negative-bottom-margin-30
span.ion-arrow-up-b
| Less information
br
if (user) if (user)
a.btn.btn-primary.btn-big.btn-block#next-courseware-button label.btn.btn-primary.btn-block.negative-10#next-courseware-button
| Go to my next challenge .ion-checkmark-circled
br | &nbsp; Go to my next challenge (ctrl + enter)
| (ctrl + enter)
if (user.sentSlackInvite) if (user.sentSlackInvite)
.button-spacer .button-spacer
.btn-group.input-group.btn-group-justified .btn-group.input-group.btn-group-justified
@ -58,7 +47,7 @@ block content
script. script.
var userLoggedIn = true; var userLoggedIn = true;
else else
a.btn.btn-lg.signup-btn.btn-block(href='/login') Sign in so you can save your progress a.btn.signup-btn.btn-block.btn-block.negative-15(href='/login') Sign in so you can save your progress
script. script.
var userLoggedIn = false; var userLoggedIn = false;
.button-spacer .button-spacer

View File

@ -3,7 +3,6 @@ html(ng-app='profileValidation', lang='en')
head head
include partials/universal-head include partials/universal-head
body.top-and-bottom-margins body.top-and-bottom-margins
include partials/css-cdns
include partials/navbar include partials/navbar
.container .container
include partials/flash include partials/flash