Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WIP: Add Links in EmotionResults to correct Learn page; fix antipattern in Play - closes #31 and #36 #40

Merged
merged 3 commits into from
Jun 6, 2017

Conversation

letakeane
Copy link
Owner

What's this PR do?

I added in <Link> tags to the EmotionResults component so users can learn more about the emotions they are displaying.

I intentionally did not create a link for "neutral".

I also changed the antipattern of using function.bind(this) in the props to a dumb component.

Learning

Where should the reviewer start?

Take a look at the screenshot and let me know if the flow makes sense.

Any background context you want to provide?

I'm also trying to hook up a button for the intended emotion - the one selected on the left-hand side of the screen.

Screenshots

Demo of the learn-more link:
Demo of link

@letakeane letakeane changed the title WIP: Add Links in EmotionResults to correct Learn page; fix antipattern in Play - closes #36 WIP: Add Links in EmotionResults to correct Learn page; fix antipattern in Play - closes #31 and #36 Jun 6, 2017
@JohnBinning
Copy link

Looks pretty good Leta. I might have missed something, but why are you filtering out contempt? If you're not using it at all, it could potentially be easier to filter it out right at the response from the api call.

)
}
}

const showResults = () => {
let emotionsForDisplay = analyzeResponse(results);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I could be wrong but I think this should be a const. I don't think you're reassigning it.

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The results change, so the output of analyzeResponse changes ... but does that matter? I guess each time it's a new instance of emotionsForDisplay. I'm not mutating it once it's set.

@jbevis
Copy link

jbevis commented Jun 6, 2017

First of all the app looks incredible, it's a very clean UI and really cool feature. I think this is a great addition and adds another layer from the user can learn. Nice job. Is the info in the learn more feature also coming back from the api?

@letakeane
Copy link
Owner Author

@jbevis No, haha, I had to write it myself. I need to add references and further reading, still, but that's not MVP. I had a minor existential crisis when I was writing the happiness page - "What IS happiness?!"

@letakeane letakeane merged commit a59ca72 into master Jun 6, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants