Make sure that when we have a value, we also show the label#14
Open
compojoom wants to merge 2 commits intoAPSL:masterfrom
Open
Make sure that when we have a value, we also show the label#14compojoom wants to merge 2 commits intoAPSL:masterfrom
compojoom wants to merge 2 commits intoAPSL:masterfrom
Conversation
alvaromb
reviewed
Jan 16, 2018
| }) | ||
| } | ||
|
|
||
| super.componentWillReceiveProps(next) |
Collaborator
Author
There was a problem hiding this comment.
Yep. The parent component sets the internal state for value. We could either use this, or set the state ourself. But I thought it would be better to let the parent class manage what it is supposed to manage anyway.
Collaborator
Author
|
@alvaromb - want to merge this? |
Collaborator
|
@compojoom scheduled for tomorrow! Sorry, busy as hell (as always :)) Want to join as a collaborator? |
Collaborator
Author
|
Sure. I'm using this in our project, so happy to help where I can. |
Collaborator
Author
|
@alvaromb turned out that when having a 0 value the component was not behaving properly and was not showing the label on top. fixed this in the last commit as well. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When a user loads a form in our application it's by default empty. However we have a "favorites" feature - the user clicks on previous values and the form is pre-populated with data. This works, but the label was missing as it's set in the constructor to 0 when we don't have a value.
In this pull request I'm comparing the next props and if it has a value I'm setting fadeAnim to true