File tree Expand file tree Collapse file tree 2 files changed +44
-13
lines changed Expand file tree Collapse file tree 2 files changed +44
-13
lines changed Original file line number Diff line number Diff line change 55
55
< div class ="card " style ="margin-bottom: 1.5em; ">
56
56
< div class ="card-body ">
57
57
<!-- TODO: each ontology should configure which browsers to be exposed in -->
58
- < a href ="https://ontobee.org/ontology/{{page.id}} " class ="btn btn-outline-primary ">
58
+ < a href ="https://ontobee.org/ontology/{{page.id}} " class ="btn btn-outline-primary " target =" _blank " rel =" noopener " >
59
59
OntoBee
60
60
</ a >
61
61
{% if page.aberowl_id %}
62
- < a href ="http://aber-owl.net/ontology/{{page.aberowl_id | upcase}} " class ="btn btn-outline-primary ">
63
- AberOWL
64
- </ a >
62
+ < a href ="http://aber-owl.net/ontology/{{page.aberowl_id | upcase}} " class ="btn btn-outline-primary " target =" _blank " rel =" noopener ">
63
+ AberOWL
64
+ </ a >
65
65
{% else %}
66
- < a href ="http://aber-owl.net/ontology/{{page.id | upcase}} " class ="btn btn-outline-primary ">
67
- AberOWL
68
- </ a >
66
+ < a href ="http://aber-owl.net/ontology/{{page.id | upcase}} " class ="btn btn-outline-primary " target =" _blank " rel =" noopener ">
67
+ AberOWL
68
+ </ a >
69
69
{% endif %}
70
- < a href ="http://www.ebi.ac.uk/ols/ontologies/{{page.id}} " class ="btn btn-outline-primary ">
70
+ < a href ="http://www.ebi.ac.uk/ols/ontologies/{{page.id}} " class ="btn btn-outline-primary " target =" _blank " rel =" noopener " >
71
71
OLS
72
72
</ a >
73
- {% for b in page.browsers %}
74
- < a href ="{{b.url}} " class ="btn btn-outline-primary ">
75
- {{b.label}}
73
+ < a href ="https://bioportal.bioontology.org/ontologies/{{ page.id | make_bioportal_id }} " class ="btn btn-outline-primary " target ="_blank " rel ="noopener ">
74
+ BioPortal
76
75
</ a >
76
+ {% for b in page.browsers %}
77
+ < a href ="{{b.url}} " class ="btn btn-outline-primary " target ="_blank " rel ="noopener ">
78
+ {{b.label}}
79
+ </ a >
77
80
{% endfor %}
78
- < a href ="https://bioregistry.io/metaregistry/obofoundry/{{page.id}} " class ="btn btn-outline-primary ">
81
+ < a href ="https://bioregistry.io/metaregistry/obofoundry/{{page.id}} " class ="btn btn-outline-primary " target =" _blank " rel =" noopener " >
79
82
Bioregistry
80
83
</ a >
81
84
{% if stripped_content_size > 0 %}
82
- < p class ="card-text "> {{ content }}</ p >
85
+ < p class ="card-text "> {{ content }}</ p >
83
86
{% endif %}
84
87
</ div >
85
88
</ div >
Original file line number Diff line number Diff line change
1
+ module CustomFilter
2
+ def make_bioportal_id ( obo_id )
3
+ return obo_id unless obo_id . is_a? ( String )
4
+
5
+ # ID requirements should be locked down moving forward, so additions to this table
6
+ # should be rare
7
+ special_cases = {
8
+ 'fbbt' => 'FB-BT' ,
9
+ 'ro' => 'OBOREL' ,
10
+ 'apollo_sv' => 'APOLLO-SV' ,
11
+ 'trans' => 'PTRANS' ,
12
+ 'wbls' => 'WB-LS' ,
13
+ 'fbdv' => 'FB-DV' ,
14
+ 'wbbt' => 'WB-BT' ,
15
+ 'wbphenotype' => 'WB-PHENOTYPE' ,
16
+ 'to' => 'PTO' ,
17
+ 'fbcv' => 'FB-CV' ,
18
+ 'mod' => 'PSIMOD' ,
19
+ 'pso' => 'PLANTSO'
20
+ }
21
+
22
+ return special_cases [ obo_id ] if special_cases . key? obo_id
23
+
24
+ obo_id == obo_id . downcase ? obo_id . upcase : obo_id
25
+ end
26
+ end
27
+
28
+ Liquid ::Template . register_filter ( CustomFilter )
You can’t perform that action at this time.
0 commit comments