Skip to content

Commit dec36c4

Browse files
committed
blog -> talks
1 parent 46522f0 commit dec36c4

File tree

49 files changed

+34
-8
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

49 files changed

+34
-8
lines changed

_freeze/site_libs/quarto-listing/list.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

_freeze/site_libs/quarto-listing/quarto-listing.js

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ const kProgressiveAttr = "data-src";
22
let categoriesLoaded = false;
33

44
window.quartoListingCategory = (category) => {
5+
// category is URI encoded in EJS template for UTF-8 support
6+
category = decodeURIComponent(atob(category));
57
if (categoriesLoaded) {
68
activateCategory(category);
79
setCategoryHash(category);
@@ -15,7 +17,9 @@ window["quarto-listing-loaded"] = () => {
1517
if (hash) {
1618
// If there is a category, switch to that
1719
if (hash.category) {
18-
activateCategory(hash.category);
20+
// category hash are URI encoded so we need to decode it before processing
21+
// so that we can match it with the category element processed in JS
22+
activateCategory(decodeURIComponent(hash.category));
1923
}
2024
// Paginate a specific listing
2125
const listingIds = Object.keys(window["quarto-listings"]);
@@ -58,7 +62,10 @@ window.document.addEventListener("DOMContentLoaded", function (_event) {
5862
);
5963

6064
for (const categoryEl of categoryEls) {
61-
const category = categoryEl.getAttribute("data-category");
65+
// category needs to support non ASCII characters
66+
const category = decodeURIComponent(
67+
atob(categoryEl.getAttribute("data-category"))
68+
);
6269
categoryEl.onclick = () => {
6370
activateCategory(category);
6471
setCategoryHash(category);
@@ -208,7 +215,9 @@ function activateCategory(category) {
208215

209216
// Activate this category
210217
const categoryEl = window.document.querySelector(
211-
`.quarto-listing-category .category[data-category='${category}'`
218+
`.quarto-listing-category .category[data-category='${btoa(
219+
encodeURIComponent(category)
220+
)}']`
212221
);
213222
if (categoryEl) {
214223
categoryEl.classList.add("active");
@@ -231,7 +240,9 @@ function filterListingCategory(category) {
231240
list.filter(function (item) {
232241
const itemValues = item.values();
233242
if (itemValues.categories !== null) {
234-
const categories = itemValues.categories.split(",");
243+
const categories = decodeURIComponent(
244+
atob(itemValues.categories)
245+
).split(",");
235246
return categories.includes(category);
236247
} else {
237248
return false;
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
{
2+
"hash": "6992621056d34d0a92c91aebb98f5a92",
3+
"result": {
4+
"engine": "knitr",
5+
"markdown": "---\ntitle: \"Welcome to Warwick R User Group\"\ndescription: |\n Welcome to our new blog, Warwick R User Group. We hope you enjoy \n reading what we have to say!\nauthor:\n - name: \"Heather Turner\" \n url: https://www.heatherturner.net/\n affiliation: University of Warwick\n affiliation_url: https://warwick.ac.uk\n - name: \"James Tripp\" \n url: https://warwick.ac.uk/fac/arts/research/digitalhumanities/team/\n affiliation: University of Warwick\n affiliation_url: https://warwick.ac.uk\n - name: \"Carlos Cámara\" \n url: https://carloscamara.es/en\n affiliation: University of Warwick\n affiliation_url: https://warwick.ac.uk\ndate: 02-07-2022\nimage: \"media/logo_small.png\"\ncategories:\n - announcements\ndraft: true\n---\n\n\n\n\nAfter some time without much activity, we're back with plenty of ideas!\n",
6+
"supporting": [],
7+
"filters": [
8+
"rmarkdown/pagebreak.lua"
9+
],
10+
"includes": {},
11+
"engineDependencies": {},
12+
"preserve": {},
13+
"postProcess": true
14+
}
15+
}

_quarto.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ website:
1818
- href: index.qmd
1919
text: Home
2020
- about.qmd
21-
- blog.qmd
21+
- talks.qmd
2222
tools:
2323
- icon: mastodon
2424
href: https://fosstodon.org/@WarwickRUG

blog.qmd renamed to talks.qmd

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
---
2-
title: "Blog"
2+
title: "Talks"
33
listing:
44
contents:
5-
- "posts"
5+
- "talks"
66
sort: "date desc"
77
type: default
88
categories: true
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)