summaryrefslogtreecommitdiff
path: root/scraper/client/paper/paper.verify.js
diff options
context:
space:
mode:
authorjules@lens <julescarbon@gmail.com>2019-03-30 15:15:12 +0100
committerjules@lens <julescarbon@gmail.com>2019-03-30 15:15:12 +0100
commit90579a6ef41c4920034e73ef39365acc27cd8022 (patch)
tree743239148b1aa8ae2dc50d71a8f279309869c4d5 /scraper/client/paper/paper.verify.js
parentd982ad1d50a6c7ff749d2508df5f1e7f6576a5b1 (diff)
parentb9944ee1a4b07edda741cdfc89abf0715f65a164 (diff)
Merge branch 'master' of asdf.us:megapixels_dev
Diffstat (limited to 'scraper/client/paper/paper.verify.js')
-rw-r--r--scraper/client/paper/paper.verify.js18
1 files changed, 16 insertions, 2 deletions
diff --git a/scraper/client/paper/paper.verify.js b/scraper/client/paper/paper.verify.js
index f5dbc13c..a60f9698 100644
--- a/scraper/client/paper/paper.verify.js
+++ b/scraper/client/paper/paper.verify.js
@@ -195,7 +195,7 @@ class PaperVerify extends Component {
<h3>{citation.title}</h3>
<div className='gray'>
{citation.id}
- {' | PDFs: '}
+ {citation.pdf.length ? ' | PDF: ' : ''}
{citation.pdf.map((pdf,i) => {
const domain = pdf.replace('www.','').split('/').slice(2,3)[0] || 'unknown'
return (
@@ -209,13 +209,27 @@ class PaperVerify extends Component {
</a>
)
})}
+ {citation.doi.length ? ' | DOI: ' : ''}
+ {citation.doi.map((doi,i) => {
+ const domain = doi.replace('www.','').split('/').slice(2,3)[0] || 'unknown'
+ return (
+ <a
+ key={i}
+ href={doi}
+ onClick={() => this.setState({ doi_index: i })}
+ className={i === this.state.doi_index ? 'selected pdfLink' : 'pdfLink'}
+ >
+ {'[' + domain + '] '}
+ </a>
+ )
+ })}
{' | '}
<a
href={'https://www.semanticscholar.org/paper/' + citation.id}
target="_blank"
className={'pdfLink'}
>
- {'[semantic scholar]'}
+ {'[s2]'}
</a>
</div>