From db6662d76d4cfdd8c0e4c8976c37846ead59e01d Mon Sep 17 00:00:00 2001 From: Abhisek Pattnaik Date: Fri, 14 Aug 2015 12:31:58 +0530 Subject: [PATCH 01/55] Bonfire: Where art thou test case update Added further test cases to check for adhering to the instructions in bonfire properly. --- challenges/basic-bonfires.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/challenges/basic-bonfires.json b/challenges/basic-bonfires.json index 6f1cf7b9d4..d027bfa3ae 100644 --- a/challenges/basic-bonfires.json +++ b/challenges/basic-bonfires.json @@ -582,7 +582,8 @@ ], "tests": [ "assert.deepEqual(where([{ first: 'Romeo', last: 'Montague' }, { first: 'Mercutio', last: null }, { first: 'Tybalt', last: 'Capulet' }], { last: 'Capulet' }), [{ first: 'Tybalt', last: 'Capulet' }], 'should return an array of objects');", - "assert.deepEqual(where([{ 'a': 1 }, { 'a': 1 }, { 'a': 1, 'b': 2 }], { 'a': 1 }), [{ 'a': 1 }, { 'a': 1 }, { 'a': 1, 'b': 2 }], 'should return with multiples');" + "assert.deepEqual(where([{ 'a': 1 }, { 'a': 1 }, { 'a': 1, 'b': 2 }], { 'a': 1 }), [{ 'a': 1 }, { 'a': 1 }, { 'a': 1, 'b': 2 }], 'should return with multiples');", + "assert.deepEqual(where([{ 'a': 5 }, { 'a': 5 }, { 'a': 5, 'b': 10 }], { 'a': 5, 'b': 10 }), [{ 'a': 5, 'b': 10 }], 'should return a single object in array');" ], "MDNlinks": [ "Global Object", From bde8e4c5eb334774b61985666d5707a7191f55b1 Mon Sep 17 00:00:00 2001 From: Abhisek Pattnaik Date: Mon, 17 Aug 2015 18:27:33 +0530 Subject: [PATCH 02/55] Added additional test case --- challenges/basic-bonfires.json | 1 + 1 file changed, 1 insertion(+) diff --git a/challenges/basic-bonfires.json b/challenges/basic-bonfires.json index d027bfa3ae..845b55a1c8 100644 --- a/challenges/basic-bonfires.json +++ b/challenges/basic-bonfires.json @@ -583,6 +583,7 @@ "tests": [ "assert.deepEqual(where([{ first: 'Romeo', last: 'Montague' }, { first: 'Mercutio', last: null }, { first: 'Tybalt', last: 'Capulet' }], { last: 'Capulet' }), [{ first: 'Tybalt', last: 'Capulet' }], 'should return an array of objects');", "assert.deepEqual(where([{ 'a': 1 }, { 'a': 1 }, { 'a': 1, 'b': 2 }], { 'a': 1 }), [{ 'a': 1 }, { 'a': 1 }, { 'a': 1, 'b': 2 }], 'should return with multiples');", + "assert.deepEqual(where([{ 'a': 1, 'b': 2 }, { 'a': 1 }, { 'a': 1, 'b': 2, 'c': 2 }], { 'a': 1, 'b': 2 }), [{ 'a': 1, 'b': 2 }, { 'a': 1, 'b': 2, 'c': 2 }], 'should return two objects in array');", "assert.deepEqual(where([{ 'a': 5 }, { 'a': 5 }, { 'a': 5, 'b': 10 }], { 'a': 5, 'b': 10 }), [{ 'a': 5, 'b': 10 }], 'should return a single object in array');" ], "MDNlinks": [ From 5d3582aa0a805cff8daa4dca4ba3d7f4ecb500e5 Mon Sep 17 00:00:00 2001 From: Matt Trifilo Date: Tue, 18 Aug 2015 00:43:28 -0500 Subject: [PATCH 03/55] Fixed: issue #2014 I changed "#button" to "button" in the example to target all buttons, and I changed the single quotes to double quotes in the description for consistency. --- challenges/jquery.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/jquery.json b/challenges/jquery.json index d6a6fa0fb0..166ff7f431 100644 --- a/challenges/jquery.json +++ b/challenges/jquery.json @@ -415,7 +415,7 @@ "You can also change the non-CSS properties of HTML elements with jQuery. For example, you can disable buttons.", "When you disable a button, it will become grayed-out and can no longer be clicked.", "jQuery has a function called .prop() that allows you to adjust the properties of elements.", - "Here's how you would disable all buttons: $('#button').prop('disabled', true);", + "Here's how you would disable all buttons: $("button").prop("disabled", true);", "Disable only the target1 button." ], "tests": [ From 2c34c1016ebc959c76736f6ec7aff258fe356f67 Mon Sep 17 00:00:00 2001 From: Matt Trifilo Date: Wed, 19 Aug 2015 22:48:25 -0500 Subject: [PATCH 04/55] Edited Pull Request #2018 Escaped the double quotation marks on line 418. --- challenges/jquery.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/jquery.json b/challenges/jquery.json index 166ff7f431..3bc98205b4 100644 --- a/challenges/jquery.json +++ b/challenges/jquery.json @@ -415,7 +415,7 @@ "You can also change the non-CSS properties of HTML elements with jQuery. For example, you can disable buttons.", "When you disable a button, it will become grayed-out and can no longer be clicked.", "jQuery has a function called .prop() that allows you to adjust the properties of elements.", - "Here's how you would disable all buttons: $("button").prop("disabled", true);", + "Here's how you would disable all buttons: $(\"button\").prop(\"disabled\", true);", "Disable only the target1 button." ], "tests": [ From 48b1ae2e0da0229b95e8a27f0e58edd4edee18e1 Mon Sep 17 00:00:00 2001 From: Arsen Melikyan Date: Fri, 21 Aug 2015 17:56:44 +0400 Subject: [PATCH 05/55] fixed #1064 --- challenges/html5-and-css.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/html5-and-css.json b/challenges/html5-and-css.json index e5e376317d..006e812dd5 100644 --- a/challenges/html5-and-css.json +++ b/challenges/html5-and-css.json @@ -1062,7 +1062,7 @@ ], "tests": [ "assert((/cat photos/gi).test($(\"a\").text()), 'Your a element should have the anchor text of \"cat photos\"')", - "assert(/http:\\/\\/catphotoapp\\.com/gi.test($(\"a\").attr(\"href\")), 'You need an a element that links to http://catphotoapp.com.')", + "assert(/http:\\/\\/catphotoapp\\.com/gi.test($(\"a\").attr(\"href\")), 'You need an a element that links to http://catphotoapp.com.')", "assert(editor.match(/<\\/a>/g) && editor.match(/<\\/a>/g).length === editor.match(/a element has a closing tag.')" ], "challengeSeed": [ From c581274bf372b6ad2477ceb572053c426df947bf Mon Sep 17 00:00:00 2001 From: Arsen Melikyan Date: Fri, 21 Aug 2015 18:38:43 +0400 Subject: [PATCH 06/55] fixed missing URL scheme #1063 --- challenges/html5-and-css.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/html5-and-css.json b/challenges/html5-and-css.json index e5e376317d..10d1302ef9 100644 --- a/challenges/html5-and-css.json +++ b/challenges/html5-and-css.json @@ -750,7 +750,7 @@ "difficulty": 1.17, "description": [ "You can add images to your website by using the img element, and point to a specific image's URL using the src attribute.", - "An example of this would be <img src=\"www.your-image-source.com/your-image.jpg\">. Note that in most cases, img elements are self-closing.", + "An example of this would be <img src=\"http://www.your-image-source.com/your-image.jpg\">. Note that in most cases, img elements are self-closing.", "Try it with this image: https://bit.ly/fcc-relaxing-cat." ], "tests": [ From b9db124ea45592e5018d14f80da695c80f0473b4 Mon Sep 17 00:00:00 2001 From: waseem Date: Sat, 22 Aug 2015 22:21:15 +0800 Subject: [PATCH 07/55] Fixed grammar - replaced 'but' with 'by' --- challenges/basic-javascript.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/basic-javascript.json b/challenges/basic-javascript.json index ac835890ea..01144ee96b 100644 --- a/challenges/basic-javascript.json +++ b/challenges/basic-javascript.json @@ -903,7 +903,7 @@ "tests":[ "assert(typeof(myFunction()) === \"number\", 'The result of myFunction should be a number');", "assert(editor.getValue().match(/Math.random/g), 'You should be using Math.random to create a random number');", - "assert(!(''+myFunction()).match(/\\./g), 'You should have multiplied the result of Math.random but 10 to make it a number that\\'s greater then zero');", + "assert(!(''+myFunction()).match(/\\./g), 'You should have multiplied the result of Math.random by 10 to make it a number that\\'s greater then zero');", "assert(editor.getValue().match(/Math.floor/g), 'You should use Math.floor to remove the decimal part of the number');" ], "challengeSeed":[ From c3562e735f60b82220ac80764107490fd4483e8e Mon Sep 17 00:00:00 2001 From: Isabell Long Date: Sat, 22 Aug 2015 17:19:46 +0100 Subject: [PATCH 08/55] Add missing tags to form element bootstrap waypoint - Fixes #2409. --- challenges/bootstrap.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/bootstrap.json b/challenges/bootstrap.json index 34b5451572..ac60120ba5 100644 --- a/challenges/bootstrap.json +++ b/challenges/bootstrap.json @@ -1532,7 +1532,7 @@ "difficulty": 2.17, "description": [ "Now let's get your form input and your submission button on the same line. We'll do this the same way we have previously: by using a div element with the class row, and other div elements within it using the col-xs-* class.", - "Nest both your form's text input and submit button within a div with the class row. Nest your form's text input within a div with the class of \"col-xs-7\". Nest your form's submit button in a div with the class col-xs-5.", + "Nest both your form's text input and submit button within a div with the class row. Nest your form's text input within a div with the class of col-xs-7. Nest your form's submit button in a div with the class col-xs-5.", "This is the last challenge we'll do for our Cat Photo App for now. We hope you've enjoyed learning Font Awesome, Bootstrap, and responsive design!" ], "tests": [ From 43f229a2311cda63c27d4030f9989bc1b652b576 Mon Sep 17 00:00:00 2001 From: Isabell Long Date: Sat, 22 Aug 2015 18:06:24 +0100 Subject: [PATCH 09/55] Add periods at the end of sentences in the Random Whole Number waypoint - Partially fixes #1991. --- challenges/basic-javascript.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/challenges/basic-javascript.json b/challenges/basic-javascript.json index ac835890ea..2558381f3f 100644 --- a/challenges/basic-javascript.json +++ b/challenges/basic-javascript.json @@ -894,11 +894,11 @@ "difficulty":"9.9828", "description":[ "It's great that we can create random decimal numbers, but it's even more useful if we use it to generate a random whole number.", - "To achieve this we can multiply the random number by ten and use the Math.floor() to convert the decimal number to a whole number", - "This technique gives us a whole number between zero and nine", + "To achieve this we can multiply the random number by ten and use the Math.floor() to convert the decimal number to a whole number.", + "This technique gives us a whole number between zero and nine.", "Example:", "Math.floor(Math.random()*10);", - "Let's give this technique a go now" + "Let's give this technique a go now." ], "tests":[ "assert(typeof(myFunction()) === \"number\", 'The result of myFunction should be a number');", From b9000ce88f19e5468a34d450877ccb51ccf31ace Mon Sep 17 00:00:00 2001 From: Isabell Long Date: Sat, 22 Aug 2015 18:39:07 +0100 Subject: [PATCH 10/55] Target Parent jQuery: elements => element because we reference only one - Partially fixes #2392. --- challenges/jquery.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/jquery.json b/challenges/jquery.json index aecaf645a6..e3ed5de816 100644 --- a/challenges/jquery.json +++ b/challenges/jquery.json @@ -617,7 +617,7 @@ "title": "Target the Parent of an Element Using jQuery", "difficulty": 3.13, "description": [ - "Every HTML elements has a parent element from which it inherits properties.", + "Every HTML element has a parent element from which it inherits properties.", "For example, your jQuery Playground h3 element has the parent element of <div class=\"container-fluid\">, which itself has the parent body.", "jQuery has a function called parent() that allows you to access the parent of whichever element you've selected.", "Give the parent of the #target1 element background-color of red.", From 6ac4ded142ee1947943926313a21a3bb7870ef74 Mon Sep 17 00:00:00 2001 From: Isabell Long Date: Sat, 22 Aug 2015 18:51:21 +0100 Subject: [PATCH 11/55] Spans for Inline Elements: remove "grow" as we already said "fill" - Fixes #2332. --- challenges/bootstrap.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/bootstrap.json b/challenges/bootstrap.json index ac60120ba5..4211392b8a 100644 --- a/challenges/bootstrap.json +++ b/challenges/bootstrap.json @@ -893,7 +893,7 @@ "title": "Use Spans for Inline Elements", "difficulty": 2.105, "description": [ - "You can use use spans to create inline elements. Remember when we used the btn-block class to make the button grow fill the entire row?", + "You can use use spans to create inline elements. Remember when we used the btn-block class to make the button fill the entire row?", "This image illustrates the difference between inline elements and block-level elements:", "\"An", "By using the span element, you can put several elements together, and even style different parts of the same element differently.", From 6344f73a36fbf7498de988d382bed264b08102f3 Mon Sep 17 00:00:00 2001 From: Isabell Long Date: Sat, 22 Aug 2015 20:26:36 +0100 Subject: [PATCH 12/55] In the while loop iterator section, advise while loops, not for loops - Fixes #2504. --- challenges/basic-javascript.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/basic-javascript.json b/challenges/basic-javascript.json index 687b271a4f..153b461e73 100644 --- a/challenges/basic-javascript.json +++ b/challenges/basic-javascript.json @@ -843,7 +843,7 @@ "  ourArray.push(i);", "  i++;", "}", - "Let's try getting a for loop to work by pushing values to an array." + "Let's try getting a while loop to work by pushing values to an array." ], "tests":[ "assert(editor.getValue().match(/while/g), 'You should be using a while loop for this.');", From b224955e2fe2925beac05c82eec7789f810f8f22 Mon Sep 17 00:00:00 2001 From: Abhisek Pattnaik Date: Sun, 23 Aug 2015 03:22:05 +0530 Subject: [PATCH 13/55] Fix Add your JavaScript Slot Machine Instructions --- challenges/basic-javascript.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/challenges/basic-javascript.json b/challenges/basic-javascript.json index 687b271a4f..d12c94a6f3 100644 --- a/challenges/basic-javascript.json +++ b/challenges/basic-javascript.json @@ -1277,8 +1277,8 @@ "description":[ "Now that our slots will each generate random numbers, we need to check whether they've all returned the same number.", "If they have, we should notify our user that they've won.", - "Otherwise, we should return null, which is a JavaScript data structure that means nothing.", - "If all three numbers match, we should change the value of win to the number that we have three of or leave it as null.", + "Otherwise, we should return null, which is a JavaScript literal representing null or an "empty" value, i.e. no object value is present.", + "If all three numbers match, we should return the number that we have in three of slots or leave it as null.", "Let's create an if statement with multiple conditions in order to check whether all numbers are equal.", "if(slotOne !== slotTwo || slotTwo !== slotThree){", "  return(null);", From b44f5378357af16d992023d368f5d27e1df2dfe1 Mon Sep 17 00:00:00 2001 From: Abhisek Pattnaik Date: Sun, 23 Aug 2015 03:26:20 +0530 Subject: [PATCH 14/55] Fix error in string --- challenges/basic-javascript.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/basic-javascript.json b/challenges/basic-javascript.json index d12c94a6f3..5ee5ee83d7 100644 --- a/challenges/basic-javascript.json +++ b/challenges/basic-javascript.json @@ -1277,7 +1277,7 @@ "description":[ "Now that our slots will each generate random numbers, we need to check whether they've all returned the same number.", "If they have, we should notify our user that they've won.", - "Otherwise, we should return null, which is a JavaScript literal representing null or an "empty" value, i.e. no object value is present.", + "Otherwise, we should return null, which is a JavaScript literal representing null or an \"empty\" value, i.e. no object value is present.", "If all three numbers match, we should return the number that we have in three of slots or leave it as null.", "Let's create an if statement with multiple conditions in order to check whether all numbers are equal.", "if(slotOne !== slotTwo || slotTwo !== slotThree){", From a51d05953825dafff5d92dc1ddccfeda2303d54d Mon Sep 17 00:00:00 2001 From: Isabell Long Date: Sat, 22 Aug 2015 22:36:51 +0100 Subject: [PATCH 15/55] Target Even Numbered Elements: consistently use double quotes - Fixes #2528. --- challenges/jquery.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/jquery.json b/challenges/jquery.json index e3ed5de816..8576e4bc0d 100644 --- a/challenges/jquery.json +++ b/challenges/jquery.json @@ -786,7 +786,7 @@ "difficulty": 3.16, "description": [ "You can also target all the even-numbered elements.", - "Here's how you would target all the odd-numbered elements with class target and give them classes: $('.target:odd').addClass('animated shake');", + "Here's how you would target all the odd-numbered elements with class target and give them classes: $(\".target:odd\").addClass(\"animated shake\");", "Try selecting all the even-numbered elements - that is, what your browser will consider even-numbered elements - and giving them the classes of animated and shake." ], "tests": [ From f00a56580ca2a625419d40994f83d162c5a8a34d Mon Sep 17 00:00:00 2001 From: Quincy Larson Date: Sat, 22 Aug 2015 17:40:59 -0700 Subject: [PATCH 16/55] update JavaScript copy from pull request --- challenges/basic-javascript.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/challenges/basic-javascript.json b/challenges/basic-javascript.json index 5ee5ee83d7..cf16fb13db 100644 --- a/challenges/basic-javascript.json +++ b/challenges/basic-javascript.json @@ -1277,8 +1277,8 @@ "description":[ "Now that our slots will each generate random numbers, we need to check whether they've all returned the same number.", "If they have, we should notify our user that they've won.", - "Otherwise, we should return null, which is a JavaScript literal representing null or an \"empty\" value, i.e. no object value is present.", - "If all three numbers match, we should return the number that we have in three of slots or leave it as null.", + "Otherwise, we should return null, which is a JavaScript data structure that means nothing.", + "If all three numbers match, we should return the number that we have in three of slots or leave it as null.", "Let's create an if statement with multiple conditions in order to check whether all numbers are equal.", "if(slotOne !== slotTwo || slotTwo !== slotThree){", "  return(null);", From 4a27e965c2f86f79e32e32888bbe14a4f92d9078 Mon Sep 17 00:00:00 2001 From: Quincy Larson Date: Sat, 22 Aug 2015 17:44:53 -0700 Subject: [PATCH 17/55] replace evernote links with more reliable imgur links --- challenges/bootstrap.json | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/challenges/bootstrap.json b/challenges/bootstrap.json index 4211392b8a..3f4d258a47 100644 --- a/challenges/bootstrap.json +++ b/challenges/bootstrap.json @@ -347,7 +347,7 @@ "description": [ "Normally, your button elements are only as wide as the text that they contain. By making them block elements, your button will stretch to fill your page's entire horizontal space.", "This image illustrates the difference between inline elements and block-level elements:", - "\"An", + "\"An", "Note that these buttons still need the btn class.", "Add Bootstrap's btn-block class to your Bootstrap button." ], @@ -700,7 +700,7 @@ "description": [ "Bootstrap uses a responsive grid system, which makes it easy to put elements into rows and specify each element's relative width. Most of Bootstrap's classes can be applied to a div element.", "Here's a diagram of how Bootstrap's 12-column grid layout works:", - "", + "\"an", "Note that in this illustration, the col-md-* class is being used. Here, md means medium, and * is a number specifying how many columns wide the element should be. In this case, the column width of an element on a medium-sized screen, such as a laptop, is being specified.", "In the Cat Photo App that we're building, we'll use col-xs-*, where xs means extra small (like an extra-small mobile phone screen), and * is the number of columns specifying how many columns wide the element should be.", "Put the Like, Info and Delete buttons side-by-side by nesting all three of them within one <div class=\"row\"> element, then each of them within a <div class=\"col-xs-4\"> element.", @@ -895,7 +895,7 @@ "description": [ "You can use use spans to create inline elements. Remember when we used the btn-block class to make the button fill the entire row?", "This image illustrates the difference between inline elements and block-level elements:", - "\"An", + "\"An", "By using the span element, you can put several elements together, and even style different parts of the same element differently.", "Nest the word \"love\" in your \"Things cats love\" element below within a span element. Then give that span the class text-danger to make the text red.", "Here's how you would do this with the \"Top 3 things cats hate\" element: <p>Top 3 things cats <span class = \"text-danger\">hate</span></p>" @@ -997,7 +997,7 @@ "We will make a simple heading for our Cat Photo App by putting them in the same row.", "Remember, Bootstrap uses a responsive grid system, which makes it easy to put elements into rows and specify each element's relative width. Most of Bootstrap's classes can be applied to a div element.", "Here's a diagram of how Bootstrap's 12-column grid layout works:", - "", + "\"an", "Note that in this illustration, the col-md-* class is being used. Here, md means medium, and * is a number specifying how many columns wide the element should be. In this case, the column width of an element on a medium-sized screen, such as a laptop, is being specified.", "In the Cat Photo App that we're building, we'll use col-xs-*, where xs means extra small (like an extra-small mobile phone screen), and * is the number of columns specifying how many columns wide the element should be.", "Nest your first image and your h2 element within a single <div class=\"row\"> element. Nest your h2 text within a <div class=\"col-xs-8\"> and your image in a <div class=\"col-xs-4\"> so that they are on the same line.", From b96378ba41777e210188800f05676b3053bc650f Mon Sep 17 00:00:00 2001 From: Quincy Larson Date: Sat, 22 Aug 2015 17:47:52 -0700 Subject: [PATCH 18/55] replace other images with imgur images and turn one image into a code snippet --- challenges/html5-and-css.json | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/challenges/html5-and-css.json b/challenges/html5-and-css.json index b93a1de494..0949a05d51 100644 --- a/challenges/html5-and-css.json +++ b/challenges/html5-and-css.json @@ -428,8 +428,12 @@ "description": [ "Create a CSS class called red-text and apply it to your h2 element.", "Classes are reusable styles that can be added to HTML elements.", - "Here's the anatomy of a CSS class:", - "\"a", + "Here's an example CSS class declaration:", + "<style>", + "  .blue-text {", + "    color: blue;", + "  }", + "</style>", "You can see that we've created a CSS class called blue-text within the <style> tag.", "You can apply a class to an HTML element like this: <h2 class=\"blue-text\">CatPhotoApp</h2>.", "Note that in your CSS style element, classes should start with a period. In your HTML elements' class declarations, classes shouldn't start with a period.", @@ -1056,7 +1060,7 @@ "description": [ "a elements, also known as anchor elements, are used to link to content outside of the current page.", "Here's a diagram of an a element. In this case, the a element is used in the middle of a paragraph element, which means the link will appear in the middle of a sentence.", - "\"a", + "\"a", "Here's an example: <p>Here's a <a href=\"http://freecodecamp.com\"> link to Free Code Camp</a> for you to follow.</p>.", "Create an a element that links to http://catphotoapp.com and has \"cat photos\" as its anchor text." ], @@ -1126,7 +1130,7 @@ "difficulty": 1.23, "description": [ "Again, here's a diagram of an a element for your reference:", - "\"a", + "\"a", "Here's an example: <p>Here's a <a href=\"http://freecodecamp.com\"> link to Free Code Camp</a> for you to follow.</p>.", "Nesting just means putting one element inside of another element.", "Now nest your a element within a new p element so that the surrounding paragraph says \"click here for cat photos\", but where only \"cat photos\" is a link, and the rest of the text is rest is plain text." From 97728c8dd4138f116724715007a4f9dc761a4068 Mon Sep 17 00:00:00 2001 From: Quincy Larson Date: Sat, 22 Aug 2015 18:07:29 -0700 Subject: [PATCH 19/55] possibly fix issue with bootstrap wells challenge --- challenges/bootstrap.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/bootstrap.json b/challenges/bootstrap.json index 3f4d258a47..6710afb129 100644 --- a/challenges/bootstrap.json +++ b/challenges/bootstrap.json @@ -1770,7 +1770,7 @@ ], "tests": [ "assert($(\"div\").length > 4, 'Add a div element with the class well inside each of your div class=\"col-xs-6\"> elements')", - "assert($(\"div.col-xs-6\").children(\"div.well\").length > 1, 'Nest both of your div class=\"col-xs-6\" elements within your div class=\"row\" element.')", + "assert($(\"div.col-xs-6 div.well\").length > 1, 'Nest both of your div class=\"col-xs-6\" elements within your div class=\"row\" element.')", "assert(editor.match(/<\\/div>/g) && editor.match(/
/g).length === editor.match(/
div elements have closing tags.')" ], "challengeSeed": [ From 6c51c018086dd832743a563361b6372ce27569ac Mon Sep 17 00:00:00 2001 From: Aryan Jabbari Date: Sun, 23 Aug 2015 03:42:42 -0400 Subject: [PATCH 20/55] Fixes #1950 using @benschenker's suggested text. --- challenges/object-oriented-and-functional-programming.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/challenges/object-oriented-and-functional-programming.json b/challenges/object-oriented-and-functional-programming.json index c49dd082d8..601ae4cc6f 100644 --- a/challenges/object-oriented-and-functional-programming.json +++ b/challenges/object-oriented-and-functional-programming.json @@ -180,7 +180,8 @@ "  return(val+1);", "});", "", - "The map method is one of the easiest ways to iterate through an array or object there is. Let's use it now." + "The map method is one of the easiest ways to iterate through an array or object there is. Let's use it now.", + "Use the map function to add 3 to every value in the variable `array`" ], "tests":[ "assert.deepEqual(array, [4,5,6,7,8], 'You should have added three to each value in the array');", From 4a149df947b658b51a0f4b883e25fc2c913ff726 Mon Sep 17 00:00:00 2001 From: Aryan Jabbari Date: Sun, 23 Aug 2015 03:47:13 -0400 Subject: [PATCH 21/55] Deleted tab --- challenges/object-oriented-and-functional-programming.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/object-oriented-and-functional-programming.json b/challenges/object-oriented-and-functional-programming.json index 601ae4cc6f..a60fc9fa91 100644 --- a/challenges/object-oriented-and-functional-programming.json +++ b/challenges/object-oriented-and-functional-programming.json @@ -181,7 +181,7 @@ "});", "", "The map method is one of the easiest ways to iterate through an array or object there is. Let's use it now.", - "Use the map function to add 3 to every value in the variable `array`" + "Use the map function to add 3 to every value in the variable `array`" ], "tests":[ "assert.deepEqual(array, [4,5,6,7,8], 'You should have added three to each value in the array');", From 2074fc41ef2af8e215e611ce1fd965399173e2e8 Mon Sep 17 00:00:00 2001 From: Aryan Jabbari Date: Sun, 23 Aug 2015 05:03:52 -0400 Subject: [PATCH 22/55] Replaced backticks with --- challenges/object-oriented-and-functional-programming.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/object-oriented-and-functional-programming.json b/challenges/object-oriented-and-functional-programming.json index a60fc9fa91..97d277c003 100644 --- a/challenges/object-oriented-and-functional-programming.json +++ b/challenges/object-oriented-and-functional-programming.json @@ -181,7 +181,7 @@ "});", "", "The map method is one of the easiest ways to iterate through an array or object there is. Let's use it now.", - "Use the map function to add 3 to every value in the variable `array`" + "Use the map function to add 3 to every value in the variable array" ], "tests":[ "assert.deepEqual(array, [4,5,6,7,8], 'You should have added three to each value in the array');", From 918f57d1c4d50941dc9a64706b9400d23da54d9c Mon Sep 17 00:00:00 2001 From: Aryan Jabbari Date: Sun, 23 Aug 2015 05:19:45 -0400 Subject: [PATCH 23/55] Fixed #1876; fixed some grammar issues; adhered to JS comment conventions --- challenges/basic-javascript.json | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/challenges/basic-javascript.json b/challenges/basic-javascript.json index 5aeecfdae6..5f6c188555 100644 --- a/challenges/basic-javascript.json +++ b/challenges/basic-javascript.json @@ -670,8 +670,8 @@ "function functionName (a, b) {", "  return(a + b);", "}", - "We can \"call\" our function like this: functionName();, and it will run and return it's return value to us.", - "Create and call a function called myFunction." + "We can \"call\" our function like this: functionName();, and it will run and return its return value to us.", + "Create and call a function called myFunction that returns the sum of a and b." ], "tests":[ "assert((function(){if(typeof(f) !== \"undefined\" && typeof(f) === \"number\" && f === a + b && editor.getValue().match(/return/gi).length >= 1 && editor.getValue().match(/a/gi).length >= 1 && editor.getValue().match(/b/gi).length >= 1 && editor.getValue().match(/\\+/gi).length >= 1){return(true);}else{return(false);}})(), 'Your function should return the value of a + b');" @@ -684,9 +684,9 @@ " return a - b;", "};", "", - "//Don't modify above this line", - "//Create a function called myFunction that returns the value of a plus b.", - " // Only change code below this line.", + "// Don't modify above this line", + "// Create a function called myFunction that returns the value of a plus b.", + "// Only change code below this line.", "", "", "", From fb12e1da401d0de3e6e6e3e87520732f9ec5c688 Mon Sep 17 00:00:00 2001 From: dokkillo Date: Sun, 23 Aug 2015 12:14:03 +0200 Subject: [PATCH 24/55] issue 2308 --- challenges/bootstrap.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/bootstrap.json b/challenges/bootstrap.json index 610919a282..c8fa530760 100644 --- a/challenges/bootstrap.json +++ b/challenges/bootstrap.json @@ -177,7 +177,7 @@ "difficulty": 2.03, "description": [ "Now that we're using Bootstrap, we can center our heading elements to make them look better. All we need to do is add the class text-center to our h1 and h2 elements.", - "Remember that you can add several classes to the same element by separating each of them with a space, like this: <h2 class=\"text-red text-center\">your text</h2>." + "Remember that you can add several classes to the same element by separating each of them with a space, like this: <h2 class=\"red-text text-center\">your text</h2>." ], "tests": [ "assert($(\"h2\").hasClass(\"text-center\"), 'Your h2 element should be centered by applying the class text-center')" From af43f9732d4ae812d0599705363595c811e5210c Mon Sep 17 00:00:00 2001 From: Arsen Melikyan Date: Sun, 23 Aug 2015 16:38:38 +0400 Subject: [PATCH 25/55] Fixes a typo #2311 --- challenges/html5-and-css.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/html5-and-css.json b/challenges/html5-and-css.json index e5e376317d..6067e2bb1e 100644 --- a/challenges/html5-and-css.json +++ b/challenges/html5-and-css.json @@ -3281,7 +3281,7 @@ "Let's override your pink-text and blue-text classes, and make your h1 element orange, by giving the h1 element an id and then styling that id.", "Give your h1 element the id attribute of orange-text. Remember, id styles look like this: <h1 id=\"orange-text\">", "Leave the blue-text and pink-text classes on your h1 element.", - "Create a CSS declaration for your orange-text id in your style element. Here's and example of what this looks like: #brown-text { color: brown; }" + "Create a CSS declaration for your orange-text id in your style element. Here's an example of what this looks like: #brown-text { color: brown; }" ], "tests": [ "assert($(\"h1\").hasClass(\"pink-text\"), 'Your h1 element should have the class pink-text.')", From b0d2ac24ec4ff537d89f648dcc707bb0037c6313 Mon Sep 17 00:00:00 2001 From: suhussai Date: Sun, 23 Aug 2015 12:20:28 -0600 Subject: [PATCH 26/55] Typo Fix. Closes #2592 Changed "greater then" to "greater than" in Waypoint 30, http://freecodecamp.com/challenges/waypoint-generate-random-whole-numbers-with-javascript --- challenges/basic-javascript.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/basic-javascript.json b/challenges/basic-javascript.json index 5aeecfdae6..dd7c322d9d 100644 --- a/challenges/basic-javascript.json +++ b/challenges/basic-javascript.json @@ -903,7 +903,7 @@ "tests":[ "assert(typeof(myFunction()) === \"number\", 'The result of myFunction should be a number');", "assert(editor.getValue().match(/Math.random/g), 'You should be using Math.random to create a random number');", - "assert(!(''+myFunction()).match(/\\./g), 'You should have multiplied the result of Math.random by 10 to make it a number that\\'s greater then zero');", + "assert(!(''+myFunction()).match(/\\./g), 'You should have multiplied the result of Math.random by 10 to make it a number that\\'s greater than zero');", "assert(editor.getValue().match(/Math.floor/g), 'You should use Math.floor to remove the decimal part of the number');" ], "challengeSeed":[ From 8704aa9a8dd5a1c621f7ecf7a3b05a9e9284220f Mon Sep 17 00:00:00 2001 From: benmcmahon100 Date: Mon, 24 Aug 2015 00:22:35 +0100 Subject: [PATCH 27/55] Fix #2605 --- challenges/basic-javascript.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/basic-javascript.json b/challenges/basic-javascript.json index 5aeecfdae6..ea4ec2a0e7 100644 --- a/challenges/basic-javascript.json +++ b/challenges/basic-javascript.json @@ -606,7 +606,7 @@ "Take the myArray array and shift() the first value off of it." ], "tests": [ - "assert((function(d){if(d[0] == 23 && d[1][0] == 'dog' && d[1][1] == 3 && d[2] == undefined){return(true);}else{return(false);}})(myArray), 'myArray should only have the first two values left([\"John\", 23])');", + "assert((function(d){if(d[0] == 23 && d[1][0] == 'dog' && d[1][1] == 3 && d[2] == undefined){return(true);}else{return(false);}})(myArray), 'myArray should only have the last two values left([23, [\"dog\", 3]])');", "assert((function(d){if(d === 'John' && typeof(myRemoved) === 'string'){return(true);}else{return(false);}})(myRemoved), 'myRemoved should contain \"John\"');" ], "challengeSeed": [ From 2e31a9d34341839fdcea57b83a19eccd58f972ee Mon Sep 17 00:00:00 2001 From: benmcmahon100 Date: Mon, 24 Aug 2015 00:29:34 +0100 Subject: [PATCH 28/55] Added some leniency to the test so that it doesn't require a new line --- challenges/jquery.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/jquery.json b/challenges/jquery.json index 8576e4bc0d..54d1ea88a9 100644 --- a/challenges/jquery.json +++ b/challenges/jquery.json @@ -17,7 +17,7 @@ "assert(editor.match(/