forked from shashwatup9k/acl-anthology
-
Notifications
You must be signed in to change notification settings - Fork 0
/
list-entry.html
60 lines (59 loc) · 3.31 KB
/
list-entry.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
{{ $volume_id := index (split .Params.anthology_id "-") 0 }}
{{ $paper := index (index $.Site.Data.papers $volume_id) .Params.anthology_id }}
{{ if not $paper.removed }}
<p class="d-sm-flex align-items-stretch">
<span class="d-block mr-2 text-nowrap list-button-row">
{{- with $paper.pdf -}}
<a class="badge badge-primary align-middle mr-1" href="{{ . }}" data-toggle="tooltip" data-placement="top" title="Open PDF">
pdf
</a>
{{- end -}}
{{- if and (not $paper.retracted) (fileExists (printf "/data-export/%s.bib" .Params.anthology_id)) -}}
<a class="badge badge-secondary align-middle mr-1" href="{{ (printf "/%s.bib" .Params.anthology_id) | relURL }}" data-toggle="tooltip" data-placement="top" title="Export to BibTeX">
bib
</a>
{{- end -}}
{{- with $paper.abstract_html -}}
<a class="badge badge-info align-middle mr-1" href="#abstract-{{ replace $.Params.anthology_id "." "--" }}" data-toggle="collapse" aria-expanded="false" aria-controls="abstract-{{ $.Params.anthology_id }}" title="Show Abstract">abs</a>
{{- end -}}
<br class="d-none d-sm-inline-block" />
{{- range $paper.award -}}
<span class="align-middle mr-1" data-toggle=tooltip data-placement=bottom title="{{ . }}"><i class="fas fa-award"></i></span>
{{- end -}}
{{- range $paper.attachment -}}
<a class="badge badge-attachment align-middle mr-1" href="{{ .url }}" data-toggle="tooltip" data-placement="top" title="{{ .type | humanize }}">{{ partial "attachment_repr.html" . }}</a>
{{- end -}}
{{- range $paper.video -}}
<a class="badge badge-attachment align-middle mr-1" href="{{ . }}" data-toggle="tooltip" data-placement="top" title="Video"><i class="fas fa-video"></i></a>
{{- end -}}
{{- with $paper.pwccode -}}
{{- if (or (eq .additional "true") .url) -}}
<a class="badge badge-secondary align-middle mr-1 pwc-reduced-padding" href="https://paperswithcode.com/paper/?acl={{ $.Params.anthology_id }}" data-toggle="tooltip" data-placement="top" title="Code">
<svg xmlns="http://www.w3.org/2000/svg" class="pwc-icon-small" viewBox="0 0 512 512"><path stroke="#4d8093" fill="#4d8093" d="M88 128h48v256H88zM232 128h48v256h-48zM160 144h48v224h-48zM304 144h48v224h-48zM376 128h48v256h-48z"></path><path stroke="#4d8093" fill="#4d8093" d="M104 104V56H16v400h88v-48H64V104zM408 56v48h40v304h-40v48h88V56z"></path></svg>
</a>
{{- end -}}
{{- end -}}
</span>
<span class="d-block" {{ if $paper.retracted }} style="text-decoration: line-through" {{ end }}>
{{ if eq hugo.Environment "development" }}
<span class="badge badge-light align-middle">{{ .Params.anthology_id }}</span>
{{ end }}
<strong><a class="align-middle" href="{{ .RelPermalink }}">{{ $paper.title_html | safeHTML }}</a></strong>
<br />
{{ with $paper.author }}
{{ $len := (len $paper.author) }}
{{ range $index, $person := $paper.author }}
{{ partial "author_link.html" (dict "ctx" $ "person" $person) }}
{{ if ne (add $index 1) $len }} | {{ end }}
{{ end }}
{{ end }}
</span>
</p>
{{ with $paper.abstract_html }}
<div class="card bg-light mb-2 mb-lg-3 collapse abstract-collapse" id="abstract-{{ replace $.Params.anthology_id "." "--" }}">
<div class="card-body p-3 small">
{{ . | safeHTML }}
</div>
</div>
{{ end }}
{{ end }}