-
Notifications
You must be signed in to change notification settings - Fork 47
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
Feature/PrintAttachmentsMerge #1322
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
toggleDocumentsAttachments = () => { | ||
let showAttachments = this.state.showAttachments; | ||
this.setState({ showAttachments: !showAttachments }); | ||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This could lead to some state-timing issues, i would suggest:
this.setState((prevState) => ({ showAttachments: !prevState.showAttachments }));
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, I think the print button move is a remnant from my previous change, can revert it.
I'll fix the other two things. :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed!
…actored logic for toggling attachments
This is a branch created solely for merging the relevant changes made in #1289 (DocumentHandler - PrintAttachments). There was some code overlap with another branch that has already been merged.
closes #1289