Skip to content

Commit 03da8bd

Browse files
authored
doi centralization, minor cosmetics on article pages (#36)
* made the link on the news page to the actual publication item * cosmetics + force doi in getcomputo-pub.fsx, fix badge alignment in publications.ejs
1 parent e7931e5 commit 03da8bd

File tree

8 files changed

+120
-27
lines changed

8 files changed

+120
-27
lines changed

_quarto.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ website:
4141
href: site/various/privacy.qmd
4242
- text: Terms of Use
4343
href: site/various/terms.qmd
44+
center: ""
4445
format:
4546
html:
4647
theme:

custom.scss

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,3 +118,35 @@ div.quarto-post {
118118
p {
119119
text-align: justify;
120120
}
121+
122+
// Ensure anchor scrolling works inside grid/flex containers
123+
.publication-anchor, a[id] {
124+
scroll-margin-top: 80px; // Adjust to your header height
125+
}
126+
127+
@media (max-width: 600px) {
128+
a[id], .publication-anchor {
129+
scroll-margin-top: 120px; // or more, adjust to your mobile header height
130+
}
131+
}
132+
133+
.nav-footer-center {
134+
height: 0px;
135+
max-height: 0px;
136+
overflow: hidden;
137+
display: flex;
138+
justify-content: center;
139+
}
140+
141+
.nav-footer-left {
142+
display: inline-block;
143+
margin: 0 10px;
144+
font-size: 0.9em;
145+
}
146+
147+
@media screen and (max-width: 768px) {
148+
.nav-footer-center {
149+
display: none; // Hide left footer on small screens
150+
}
151+
152+
}

getcomputo-pub.fsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -153,6 +153,7 @@ let extractCitation (d: Dictionary<obj, obj>) =
153153
{| title = d |> getSomeString "title"
154154
authors = d |> getAuthors
155155
journal = d |> getAnotherThing "citation" |> getSomeString "container-title"
156+
doi = d |> getAnotherThing "citation" |> getSomeString "doi"
156157
year = dateTime.Year
157158
date = dateTime.ToString("yyyy-MM-dd")
158159
description = d |> getSomeString "description"

index.qmd

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,10 @@ description: <h1>COMPUTO</h1> A journal of the <a href="https://sfds.asso.fr/">F
33
Statistical Society <img height="10px" src="assets/img/sfds.png" alt="SFdS"/></a>
44
- ISSN 2824-7795
55
listing:
6-
contents: news.yml
7-
sort: date desc
8-
page-size: 5
9-
fields:
10-
- date
11-
- description
12-
feed:
13-
items: 5
6+
- id: published
7+
template: site/news.ejs
8+
contents: site/published.yml
9+
sort: date desc
1410
---
1511

1612
:::: {layout="[30,70]" style="display: flex; margin-bottom: 3em;"}

site/mock-papers.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
date: 2008-08-11
2424
description: >
2525
This page is a reworking of the original t-SNE article using the Computo template. It aims to help authors submitting to the journal by using some advanced formatting features. We warmly thank the authors of t-SNE and the editor of JMLR for allowing us to use their work to illustrate the Computo spirit.
26+
doi: ''
2627
draft: false
2728
journal: Computo
2829
pdf: ''
@@ -55,6 +56,7 @@
5556
date: 2008-08-11
5657
description: >
5758
This page is a reworking of the original t-SNE article using the Computo template. It aims to help authors submitting to the journal by using some advanced formatting features. We warmly thank the authors of t-SNE and the editor of JMLR for allowing us to use their work to illustrate the Computo spirit.
59+
doi: ''
5860
draft: false
5961
journal: Computo
6062
pdf: ''

site/news.ejs

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
```{=html}
2+
<%
3+
// Only show articles from this year (2025) and not drafts
4+
const currentYear = new Date().getFullYear();
5+
for (const item of items) {
6+
if (!item.draft && item.year == currentYear) { %>
7+
<a href="/site/publications.html#<%= item.repo %>" class="list-group-item list-group-item-action">
8+
<strong><%= item.date %></strong>
9+
<%= item.title %>
10+
<% if (item.authors) { %>
11+
by <%= item.authors %>
12+
<% } %>
13+
<!-- <% if (item.url && item.url.trim()) { %>
14+
[<a href="<%= item.url %>" target="_blank">link</a>]
15+
<% } %> -->
16+
</a>
17+
<% }
18+
} %>
19+
```
20+

site/publications.ejs

Lines changed: 43 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
// Group items by year
88
let currentYear = null;
99
for (const item of items) {
10+
let doiurl = item.url === "" ? "https://doi.org/" + item.doi : item.url;
1011
if (item.year !== currentYear) {
1112
if (currentYear !== null) { %>
1213
</div> <!-- End previous year section -->
@@ -15,33 +16,34 @@ for (const item of items) {
1516
<div class="row year-section">
1617
<% currentYear = item.year;
1718
} %>
18-
<div class="col-12 mb-3">
19-
<div class="card">
20-
<div class="card-body">
21-
<div class="row align-items-center border-left border-primary">
22-
<div class="col-md-2">
23-
<a href="https://github.com/computorg/<%- item.repo %>" target="_blank">
24-
<img style="width:100px;" src=https://img.shields.io/github/actions/workflow/status/computorg/<%- item.repo %>/build.yml?label=build&logo=github" class="img-fluid" alt="Build Status">
19+
<a id="<%= item.repo %>" class="publication-anchor"></a>
20+
<div class="col-12 mb-2">
21+
<div class="card border-0" style="padding: 0.25rem 0.5rem; background: #fff;">
22+
<div class="card-body p-1" style="padding: 0.5rem 0.5rem 0.5rem 0.5rem !important;">
23+
<div class="row align-items-start"> <!-- align-items-start for top alignment -->
24+
<div class="col-md-2 col-3 d-flex flex-column justify-content-start align-items-start p-0 badge-left-align"> <!-- left-aligned, no padding -->
25+
<a href="https://github.com/computorg/<%- item.repo %>" target="_blank" style="margin-left:0;">
26+
<img src="https://img.shields.io/github/actions/workflow/status/computorg/<%- item.repo %>/build.yml?label=build&logo=github" class="img-fluid" alt="Build Status" style="vertical-align: top; margin-top: 0; margin-left:-20px; margin-top:5px; display:block;" />
2527
</a>
2628
</div>
27-
<div class="col-md-10">
28-
<h5 class="card-title mb-2">
29-
<a href="<%= item.url %>" data-toggle="modal" data-target="#articleModal" class="text-decoration-none"><%= item.title %></a>
29+
<div class="col-md-10 col-9 pl-1">
30+
<h5 class="card-title mb-1" style="font-size:1.1em;">
31+
<a href="<%= doiurl %>" data-toggle="modal" data-target="#articleModal" class="text-decoration-none"><%= item.title %></a>
3032
</h5>
3133
<% if (item.authors) { %>
32-
<p class="text-muted mb-2"><%= item.authors %></p>
34+
<p class="text-muted mb-1" style="font-size:0.97em;"><%= item.authors %></p>
3335
<% } %>
34-
<p class="text-muted mb-3"><em>Computo</em>, <%= item.year %>.</p>
35-
<div class="btn-group" role="group" aria-label="Article actions">
36-
<% if (item["abstract'"] && item["abstract'"].trim()) { %>
37-
<button type="button" class="btn btn-outline-secondary btn-sm" data-toggle="modal" data-target="#abstractModal" data-abstract="<%- item["abstract'"].replace(/"/g, '&quot;') %>" data-title="<%- item.title.replace(/"/g, '&quot;') %>">ABS</button>
36+
<p class="text-muted mb-2" style="font-size:0.95em;"><em>Computo</em>, <%= item.year %>.</p>
37+
<div class="btn-group btn-group-sm" role="group" aria-label="Article actions">
38+
<% if (item["abstract'" ] && item["abstract'"].trim()) { %>
39+
<button type="button" class="btn btn-outline-secondary btn-sm" data-toggle="modal" data-target="#abstractModal" data-abstract="<%- item["abstract'"].replace(/"/g, '&quot;') %>" data-title="<%- item.title.replace(/"/g, '&quot;') %>" style="padding:0.2em 0.6em;">ABS</button>
3840
<% } %>
39-
<a href="<%= item.url %>" class="btn btn-outline-secondary btn-sm" target="_blank">HTML</a>
41+
<a href="<%= doiurl %>" class="btn btn-outline-secondary btn-sm" target="_blank" style="padding:0.2em 0.6em;">HTML</a>
4042
<% if (item.pdf && item.pdf.trim()) { %>
41-
<a href="<%= item.pdf %>" class="btn btn-outline-secondary btn-sm" target="_blank">PDF</a>
43+
<a href="<%= item.pdf %>" class="btn btn-outline-secondary btn-sm" target="_blank" style="padding:0.2em 0.6em;">PDF</a>
4244
<% } %>
43-
<a href="https://github.com/computorg/<%- item.repo %>" class="btn btn-outline-secondary btn-sm" target="_blank">GIT REPO</a>
44-
<button type="button" class="btn btn-outline-secondary btn-sm" onclick="generateBibTex('<%- item.title.replace(/'/g, "\\'") %>', '<%- item.authors.replace(/'/g, "\\'") %>', '<%= item.year %>', '<%= item.url %>')">BIB</button>
45+
<a href="https://github.com/computorg/<%- item.repo %>" class="btn btn-outline-secondary btn-sm" target="_blank" style="padding:0.2em 0.6em;">GIT REPO</a>
46+
<button type="button" class="btn btn-outline-secondary btn-sm" onclick="generateBibTex('<%- item.title.replace(/'/g, "\\'") %>', '<%- item.authors.replace(/'/g, "\\'") %>', '<%= item.year %>', '<%= doiurl %>')" style="padding:0.2em 0.6em;">BIB</button>
4547
</div>
4648
</div>
4749
</div>
@@ -137,5 +139,27 @@ for (const item of items) {
137139
// Show a temporary alert
138140
alert('BibTeX citation copied to clipboard!');
139141
}
142+
143+
document.addEventListener("DOMContentLoaded", function() {
144+
if (window.location.hash) {
145+
var el = document.getElementById(window.location.hash.substring(1));
146+
if (el) {
147+
el.scrollIntoView({ behavior: "auto", block: "center" });
148+
}
149+
}
150+
});
151+
document.addEventListener("DOMContentLoaded", function() {
152+
function scrollToAnchor() {
153+
if (window.location.hash) {
154+
var el = document.getElementById(window.location.hash.substring(1));
155+
if (el) {
156+
el.scrollIntoView({ behavior: "auto", block: "center" });
157+
}
158+
}
159+
}
160+
// Try immediately, then again after a short delay (for mobile/layout shifts)
161+
scrollToAnchor();
162+
setTimeout(scrollToAnchor, 400);
163+
});
140164
</script>
141165
```

site/published.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
authors: Julien Jacques and Thomas Brendan Murphy
1111
date: 2025-07-01
1212
description: ''
13+
doi: 10.57750/6v7b-8483
1314
draft: false
1415
journal: Computo
1516
pdf: ''
@@ -41,6 +42,7 @@
4142
authors: Thomas Ferté, Kalidou Ba, Dan Dutartre, Pierrick Legrand, Vianney Jouhet, Rodolphe Thiébaut, Xavier Hinaut and Boris P Hejblum
4243
date: 2025-06-27
4344
description: ''
45+
doi: 10.57750/arxn-6z34
4446
draft: false
4547
journal: Computo
4648
pdf: ''
@@ -68,6 +70,7 @@
6870
date: 2025-01-27
6971
description: >
7072
This document provides a full description of the Stochastic Individual-Based Models (IBMs) that can be implemented in the IBMPopSim package. A unified mathematical and simulation framework is given, with a detailed description of the simulation algorithm. Examples of applications for the package are also provided, showing the performance and flexibility of IBMPopSim.
73+
doi: 10.57750/sfxn-1t05
7174
draft: false
7275
journal: Computo
7376
pdf: ''
@@ -96,6 +99,7 @@
9699
authors: Félix Laplante and Christophe Ambroise
97100
date: 2024-12-13
98101
description: Scalable Spectral Clustering Based on Vector Quantization
102+
doi: 10.57750/1gr8-bk61
99103
draft: false
100104
journal: Computo
101105
pdf: ''
@@ -124,6 +128,7 @@
124128
authors: Herbert Susmann, Antoine Chambaz and Julie Josse
125129
date: 2024-07-18
126130
description: ''
131+
doi: 10.57750/edan-5f53
127132
draft: false
128133
journal: Computo
129134
pdf: ''
@@ -164,6 +169,7 @@
164169
authors: Juliette Legrand, François Pimont, Jean-Luc Dupuy and Thomas Opitz
165170
date: 2024-07-12
166171
description: ''
172+
doi: 10.57750/4y84-4t68
167173
draft: false
168174
journal: Computo
169175
pdf: ''
@@ -195,6 +201,7 @@
195201
authors: Liudmila Pishchagina, Guillem Rigaill and Vincent Runge
196202
date: 2024-07-12
197203
description: ''
204+
doi: 10.57750/9vvx-eq57
198205
draft: false
199206
journal: Computo
200207
pdf: ''
@@ -223,6 +230,7 @@
223230
Sources of error can arise from the workers' skills, but also from the intrinsic difficulty of the task.
224231
225232
We introduce `peerannot`, a Python library for managing and learning from crowdsourced labels of image classification tasks.
233+
doi: 10.57750/qmaz-gr91
226234
draft: false
227235
journal: Computo
228236
pdf: ''
@@ -250,6 +258,7 @@
250258
date: 2024-03-11
251259
description: >
252260
This document provides a dimension-reduction strategy in order to improve the performance of importance sampling in high dimensions.
261+
doi: 10.57750/jjza-6j82
253262
draft: false
254263
journal: Computo
255264
pdf: https://computo.sfds.asso.fr/published-202402-elmasri-optimal/published-202312-elmasri-optimal.pdf
@@ -268,6 +277,7 @@
268277
authors: Hamza Adrat and Laurent Decreusefond
269278
date: 2024-01-25
270279
description: ''
280+
doi: 10.57750/3r07-aw28
271281
draft: false
272282
journal: Computo
273283
pdf: ''
@@ -321,6 +331,7 @@
321331
authors: Armand Favrot and David Makowski
322332
date: 2024-01-09
323333
description: ''
334+
doi: 10.57750/6cgk-g727
324335
draft: false
325336
journal: Computo
326337
pdf: ''
@@ -355,6 +366,7 @@
355366
authors: Alice Cleynen, Louis Raynal and Jean-Michel Marin
356367
date: 2023-12-14
357368
description: ''
369+
doi: 10.57750/3j8m-8d57
358370
draft: false
359371
journal: Computo
360372
pdf: ''
@@ -386,6 +398,7 @@
386398
authors: Maud Delattre and Estelle Kuhn
387399
date: 2023-11-21
388400
description: ''
401+
doi: 10.57750/r5gx-jk62
389402
draft: false
390403
journal: Computo
391404
pdf: https://computo.sfds.asso.fr/published-202311-delattre-fim/published-202311-delattre-fim.pdf
@@ -419,6 +432,7 @@
419432
authors: Edmond Sanou, Christophe Ambroise and Geneviève Robin
420433
date: 2023-06-28
421434
description: ''
435+
doi: 10.57750/1f4p-7955
422436
draft: false
423437
journal: Computo
424438
pdf: https://computo.sfds.asso.fr/published-202306-sanou-multiscale_glasso/published-202306-sanou-multiscale_glasso.pdf
@@ -449,6 +463,7 @@
449463
authors: Mathis Chagneux, Sylvain Le Corff, Pierre Gloaguen, Charles Ollion, Océane Lepâtre and Antoine Bruge
450464
date: 2023-02-16
451465
description: ''
466+
doi: 10.57750/845m-f805
452467
draft: false
453468
journal: Computo
454469
pdf: https://computo.sfds.asso.fr/published-202301-chagneux-macrolitter/published-202301-chagneux-macrolitter.pdf
@@ -473,6 +488,7 @@
473488
date: 2023-01-12
474489
description: >
475490
The package $\textsf{clayton}$ is designed to be intuitive, user-friendly, and efficient. It offers a wide range of copula models, including Archimedean, Elliptical, and Extreme. The package is implemented in pure $\textsf{Python}$, making it easy to install and use.
491+
doi: 10.57750/4szh-t752
476492
draft: false
477493
journal: Computo
478494
pdf: https://computo.sfds.asso.fr/published-202301-boulin-clayton/published-202301-boulin-clayton.pdf
@@ -509,6 +525,7 @@
509525
authors: Olivier Gimenez, Maëlis Kervellec, Jean-Baptiste Fanjul, Anna Chaine, Lucile Marescot, Yoann Bollet and Christophe Duchamp
510526
date: 2022-04-22
511527
description: ''
528+
doi: 10.57750/yfm2-5f45
512529
draft: false
513530
journal: Computo
514531
pdf: ''

0 commit comments

Comments
 (0)