Open barryross opened 7 years ago
Bryan, awesome work with this! Excellent job hitting the tech requirements and finding a solution for the "jerky" slideUp()
issue you were describing. That's the solution I was going to suggest...using a callback in conjunction with the slideUp()
method...excellent work identifying and tackling a problem/something that was bugging you about the UX 💯 . Please see inline comments for additional feedback and keep up the great work!
FEWD Week #4 Project: JavaScript Basics
Description
The team from Relaxr is back...again! They want their page to be more interactive and asked you to add JavaScript to their source code. You've been given the HTML and CSS but will need to create a JavaScript file and add a few different pieces of interactivity: Users should be able to click a link and have the remainder of the blog's content slide down and appear on the page, both on the main content column and the side bar; users should also be able hide the content when they are finished reading. See a detailed technical explanation below.
Student: Bryan Saylor
Project URL: https://github.com/bryansaylor/homework-portfolio
event.preventDefault()
function$.ready()
handler to delay your code from executing until all DOM assets have been loaded$.click()
handler<p>
tag slide down along with a "Read Less" link in the blog post using,$.slideDown()
and$.show()
$.hide()
<p>
slide up and hide the "Read Less" link using$.slideUp()
and$.hide()
$.show()
' slide down and hide the "Learn More" link using
$.slideDown()
and$.hide()