Navbar link action
zoeames opened this issue · 4 comments
zoeames commented
Story
As a user, when I click on the navbar, the view should change.
Acceptance Criteria
When the user click on My Movies link
Then they should see an h1 tag that says "My Movies"
When the user click on Search link
Then they should see an h1 tag that says "Search Movies"
And they should see search bar
And if they search for movies the movies should show up
zoeames commented
Comment by zoeames
Tuesday Oct 17, 2017 at 05:19 GMT
modify index.html
- in navbar add ids to the three links
- add div with "#myMovies" that has an h1 tag in it
- add div with "#search" that has an h1 tag, the search input, #movies div
zoeames commented
Comment by zoeames
Tuesday Oct 17, 2017 at 05:22 GMT
modify events.js
Add function: myLinks - click events that checks the id of event.target and:
- if search link in nav is clicked it shows search div and hides myMovies div
- if my movies link in nav is clicked is shows myMovies div and hides search div