From 1bb9951d0402485bd688a701814b4a96314de7f9 Mon Sep 17 00:00:00 2001 From: Quincy Larson Date: Fri, 19 Jun 2015 17:39:11 -0700 Subject: [PATCH 1/5] Merge branch 'master' into staging Conflicts: seed/challenges/basic-bonfires.json --- bonfireMDNlinks.js | 1 + challenges/basic-bonfires.json | 6 ++++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/bonfireMDNlinks.js b/bonfireMDNlinks.js index 9a9ea86741..bedd51b2db 100644 --- a/bonfireMDNlinks.js +++ b/bonfireMDNlinks.js @@ -12,6 +12,7 @@ var links = "Currying": "https://leanpub.com/javascript-allonge/read#pabc", "Smallest Common Multiple": "https://www.mathsisfun.com/least-common-multiple.html", "Permutations": "https://www.mathsisfun.com/combinatorics/combinations-permutations.html", + "HTML Entities": "http://dev.w3.org/html5/html-author/charref", // ========= GLOBAL OBJECTS "Global Array Object" : "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array", diff --git a/challenges/basic-bonfires.json b/challenges/basic-bonfires.json index 49600d63ba..6a36355e62 100644 --- a/challenges/basic-bonfires.json +++ b/challenges/basic-bonfires.json @@ -1093,7 +1093,7 @@ "dashedName": "bonfire-convert-html-entities", "difficulty": "2.07", "description": [ - "Convert the characters \"&\", \"<\", \">\", '\"', and \"'\", in a string to their corresponding HTML entities.", + "Convert the characters \"&\", \"<\", \">\", '\"' (double quote), and \"'\" (apostrophe), in a string to their corresponding HTML entities.", "Remember to use RSAP if you get stuck. Try to pair program. Write your own code." ], "challengeSeed": [ @@ -1110,10 +1110,12 @@ "assert.strictEqual(convert('Sixty > twelve'), 'Sixty > twelve', 'should escape characters');", "assert.strictEqual(convert('Stuff in \"quotation marks\"'), 'Stuff in "quotation marks"', 'should escape characters');", "assert.strictEqual(convert(\"Shindler's List\"), 'Shindler's List', 'should escape characters');", + "assert.strictEqual('Submit', '<input type="submit">Submit</input>', 'should escape characters');", "assert.strictEqual(convert('abc'), 'abc', 'should handle strings with nothing to escape');" ], "MDNlinks": [ - "RegExp" + "RegExp", + "HTML Entities" ], "challengeType": 5, "nameCn": "", From fe9d1e97bb92da72c3f3c82a63958bcb500a256b Mon Sep 17 00:00:00 2001 From: Quincy Larson Date: Fri, 19 Jun 2015 17:53:59 -0700 Subject: [PATCH 2/5] fix broken test from recent pull request --- challenges/basic-bonfires.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/basic-bonfires.json b/challenges/basic-bonfires.json index 6a36355e62..11274ec1a7 100644 --- a/challenges/basic-bonfires.json +++ b/challenges/basic-bonfires.json @@ -1110,7 +1110,7 @@ "assert.strictEqual(convert('Sixty > twelve'), 'Sixty > twelve', 'should escape characters');", "assert.strictEqual(convert('Stuff in \"quotation marks\"'), 'Stuff in "quotation marks"', 'should escape characters');", "assert.strictEqual(convert(\"Shindler's List\"), 'Shindler's List', 'should escape characters');", - "assert.strictEqual('Submit', '<input type="submit">Submit</input>', 'should escape characters');", + "assert.strictEqual(convert('<>'), '<>', 'should escape characters');", "assert.strictEqual(convert('abc'), 'abc', 'should handle strings with nothing to escape');" ], "MDNlinks": [ From c01a0ad9d74a76fd838758267e871aa03de364ed Mon Sep 17 00:00:00 2001 From: Quincy Larson Date: Fri, 19 Jun 2015 18:31:21 -0700 Subject: [PATCH 3/5] fix a bunch of github issues regarding waypoints --- challenges/basic-html5-and-css.json | 5 +++-- challenges/bootstrap.json | 2 +- challenges/get-set-for-free-code-camp.json | 2 +- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/challenges/basic-html5-and-css.json b/challenges/basic-html5-and-css.json index ccd2fdaa5f..24b1c71939 100644 --- a/challenges/basic-html5-and-css.json +++ b/challenges/basic-html5-and-css.json @@ -943,7 +943,8 @@ "In addition to pixels, you can also specify a border-radius using a percentage." ], "tests": [ - "assert(parseInt($('img').css('border-top-left-radius')) > 48, 'Your image should have a border radius of 50 percent, making it perfectly circular.')" + "assert(parseInt($('img').css('border-top-left-radius')) > 48, 'Your image should have a border radius of 50 percent, making it perfectly circular.')", + "assert(editor.match(/50%/g), 'Be sure to use a percentage instead of a pixel value.')" ], "challengeSeed": [ "", @@ -1613,7 +1614,7 @@ "For example: <form action=\"/url-where-you-want-to-submit-form-data\"></form>." ], "tests": [ - "assert($('form').length > 0, 'Wrap your text input element within a form element.')", + "assert($('form') && $('form').children('input') && $('form').children('input').length > 0, 'Wrap your text input element within a form element.')", "assert($('form').attr('action'), 'Your form element should have an action attribute.')", "assert(editor.match(/<\\/form>/g) && editor.match(/
/g).length === editor.match(/form element has a closing tag.')", "assert(editor.match(/\\/submit-cat-photo/ig), 'Make sure your form action is set to /submit-cat-photo.')" diff --git a/challenges/bootstrap.json b/challenges/bootstrap.json index 9f2b704153..41a7229731 100644 --- a/challenges/bootstrap.json +++ b/challenges/bootstrap.json @@ -1264,7 +1264,7 @@ "tests": [ "assert($('button[type=\\'submit\\']').hasClass('btn btn-primary'), 'Give the submit button in your form the classes \"btn btn-primary\".')", "assert($('button[type=\\'submit\\']:has(i.fa.fa-paper-plane)').length > 0, 'Add a <i class=\"fa fa-paper-plane\"></i> within your submit button element.')", - "assert($('input[type=\\'text\\']').hasClass('form-control'), 'Give the text input in your form the class \"form-control\".')", + "assert($('input[type=\\'text\\']').hasClass('form-control'), 'Give the text input in your form the class \"form-control\".')", "assert(editor.match(/<\\/i>/g) && editor.match(/<\\/i/g).length > 3, 'Make sure each of your i elements has a closing tag.')" ], "challengeSeed": [ diff --git a/challenges/get-set-for-free-code-camp.json b/challenges/get-set-for-free-code-camp.json index 3a9d366102..2aaac7aff8 100644 --- a/challenges/get-set-for-free-code-camp.json +++ b/challenges/get-set-for-free-code-camp.json @@ -195,7 +195,7 @@ "Click \"News\" in the upper right hand corner.", "You'll see a variety of links that have been submitted. Click on the \"Discuss\" button under one of them.", "You can upvote links. This will push the link up the rankings of hot links.", - "You an also comment on a link. If someone responds to your comment, you'll get an email notification so you can come back and respond to them.", + "You can also comment on a link. If someone responds to your comment, you'll get an email notification so you can come back and respond to them.", "You can also submit links. You can modify the link's headline and also leave an initial comment about the link.", "You can view the portfolio pages of any camper who has posted links or comments on Camper News. Just click on their photo.", "When you submit a link, you'll get a point. You will also get a point each time someone upvotes your link.", From a6ca40d6f347f58992e69fc82d613767d88dd61f Mon Sep 17 00:00:00 2001 From: Quincy Larson Date: Fri, 19 Jun 2015 21:24:04 -0700 Subject: [PATCH 4/5] finishing touches on calculator --- challenges/basic-html5-and-css.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenges/basic-html5-and-css.json b/challenges/basic-html5-and-css.json index 24b1c71939..7fdae6da09 100644 --- a/challenges/basic-html5-and-css.json +++ b/challenges/basic-html5-and-css.json @@ -1541,7 +1541,7 @@ ], "tests": [ "assert($('input[placeholder]').length > 0, 'Add a placeholder attribute text input element.')", - "assert($('input').attr('placeholder').match(/cat\\s+photo\\s+URL/gi), 'Set the value of your placeholder attribute to \"cat photo URL\".')" + "assert($('input') && $('input').attr('placeholder') && $('input').attr('placeholder').match(/cat\\s+photo\\s+URL/gi), 'Set the value of your placeholder attribute to \"cat photo URL\".')" ], "challengeSeed": [ "", From 3f21574b5e0d70eab9783ac8913e2624d983450b Mon Sep 17 00:00:00 2001 From: Quincy Larson Date: Sat, 20 Jun 2015 18:12:12 -0700 Subject: [PATCH 5/5] add new chat challenge --- challenges/get-set-for-free-code-camp.json | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/challenges/get-set-for-free-code-camp.json b/challenges/get-set-for-free-code-camp.json index 2aaac7aff8..379bc26f6e 100644 --- a/challenges/get-set-for-free-code-camp.json +++ b/challenges/get-set-for-free-code-camp.json @@ -45,18 +45,20 @@ "name": "Waypoint: Join Our Chat Room", "dashedName": "waypoint-join-our-chat-room", "difficulty": 0.002, - "challengeSeed": ["124555254"], + "challengeSeed": ["131321596"], "description": [ "Now we're going to join the Free Code Camp chat room. You can come here any time of day to hang out, ask questions, or find another camper to pair program with.", - "Make sure your Free Code Camp account includes your email address. Please note that the email address you use will be invisible to the public, but Slack will make it visible to other campers in our slack chat rooms. You can do this here: http://freecodecamp.com/account.", - "Click this link, which will email you can invite to Free Code Camp's Slack chat rooms: http://freecodecamp.com/api/slack.", - "Now check your email and click the link in the email from Slack.", - "Complete the sign up process, then update your biographical information and upload an image. A picture of your face works best. This is how people will see you in our chat rooms, so put your best foot forward.", - "Now enter the General chat room and introduce yourself to our chat room by typing: \"Hello world!\".", + "Create an account with GitHub here: https://github.com/join.", + "Click the pixel art in the upper right hand corner of GitHub, then choose settings. Upload a picture of yourself. A picture of your face works best. This is how people will see you in our chat rooms, so put your best foot forward. You can add your city and your personal website if you have one.", + "Now follow this link to enter our Welcome chat room: https://gitter.im/FreeCodeCamp/welcome.", + "Once you're in our Welcome chat room, introduce yourself by saying : \"Hello world!\".", "Tell your fellow campers how you found Free Code Camp. Also tell us why you want to learn to code.", + "This is the best room for new campers, but feel free to join other chat rooms as well. Our main chat room: https://gitter.im/FreeCodeCamp/FreeCodeCamp.", "Keep the chat room open while you work through the other challenges. That way you ask for help if you get stuck on a challenge. You can also socialize when you feel like taking a break.", + "You can also download a desktop or mobile chat application here: https://gitter.im/apps", "You can also access this chat room by clicking the \"Chat\" button in the upper right hand corner.", - "In order to keep our community a friendly and positive place to learn to code, please read and follow our Code of Conduct: http://freecodecamp.com/field-guide/what-is-the-free-code-camp-code-of-conduct?" + "In order to keep our community a friendly and positive place to learn to code, please read and follow our Code of Conduct: http://freecodecamp.com/field-guide/what-is-the-free-code-camp-code-of-conduct?", + "Now you're ready to move on. Click the \"I've completed this challenge\" button to move on to your next challenge." ], "challengeType": 2, "tests": [],