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

Connects to #1466: Allow query via DOIs when adding a new Article #1947

Open
wants to merge 10 commits into
base: dev
Choose a base branch
from

Conversation

markmandell
Copy link
Contributor

  • GCI => New Gene Curation => Add Article
  • Search via DOI (some example DOIs)
    • 10.1093/jnci/djq238
    • 10.1016/j.ijantimicag.2014.01.019
    • 10.1016/j.fsigen.2014.02.002
  • Form validation when searching by a DOI/PMID already associated with an article
  • Validation to recognize a "bad" DOI/PMID
  • UI changes in modal reflect the addition of DOIs (Add Article, Edit PMID/DOI, Add New Article)
  • Left hand side of Curation Central - Article "cards" - Long DOI should not overflow past length of card, should be hidden
  • Tests associated with Add Article modal have updated text and pass

@h-tong h-tong self-requested a review July 26, 2019 17:42
@h-tong
Copy link
Contributor

h-tong commented Jul 26, 2019

When the length of a DOI is longer than the "card" and another article is currently selected, it looks like the overflow is not hidden. Is this intended? Below is a screenshot of what I mean.

Screen Shot 2019-07-26 at 11 27 30 AM

@markmandell
Copy link
Contributor Author

markmandell commented Jul 29, 2019

Screen Shot 2019-07-29 at 10 07 27 AM

Screen Shot 2019-07-29 at 10 10 30 AM

DOI overflow now hidden for selected/non-selected articles. Thanks @h-tong !

@@ -283,14 +283,15 @@ var PmidSelectionList = createReactClass({
<PmidSummary article={annotation.article} />
</div>
<div className="pmid-selection-list-pmid"><a href={external_url_map['PubMed'] + annotation.article.pmid} target="_blank">PMID: {annotation.article.pmid}</a></div>
{ annotation.article.doi ? <div className="pmid-selection-list-pmid"><a href={external_url_map['PubMed'] + annotation.article.pmid} target="_blank">DOI: {annotation.article.doi}</a></div> : null}
Copy link
Contributor

Choose a reason for hiding this comment

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

Is it possible for annotation.article to be undefined? Accessing annotation.article.doi or annotation.article.pmid could throw an error if annotation.article is undefined.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Hey Howard! Apologies for it taking a while to come back to this. I have not been able to recreate the issue with an undefined article. Wanted to ask which steps you took when testing to recreate it and figure it out! Thanks

Copy link
Contributor

Choose a reason for hiding this comment

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

Oh, I didn't run into it. I was just wondering if it could ever be the case. I was thinking it could be safer to add a check to make sure the properties are defined, but since we both haven't come across it, then maybe it should be fine.

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.

None yet

2 participants