summaryrefslogtreecommitdiff
path: root/script.js
diff options
context:
space:
mode:
authorMartin Fischer <martin@push-f.com>2022-07-21 12:03:06 +0200
committerMartin Fischer <martin@push-f.com>2022-07-21 12:14:45 +0200
commit8b28d1bb96fa2da47a44aa3b2d38544421ff8b51 (patch)
tree1eeb19961f755d43bd22afde155a54593d90d956 /script.js
parent1aa844458e6acd786a0b301eb965ecc8fccae942 (diff)
extract language prefix from page title
Diffstat (limited to 'script.js')
-rw-r--r--script.js6
1 files changed, 5 insertions, 1 deletions
diff --git a/script.js b/script.js
index 664985c..1301379 100644
--- a/script.js
+++ b/script.js
@@ -63,7 +63,11 @@ function display(proposals) {
const link = newEl('a', proposal.name || proposal.page_title);
link.href = 'https://wiki.openstreetmap.org/wiki/' + proposal.page_title.replaceAll(' ', '_');
- row.appendChild(newEl('td', link));
+
+ const nameCell = newEl('td', link);
+ if (proposal.lang)
+ nameCell.appendChild(document.createTextNode(` (${proposal.lang})`));
+ row.appendChild(nameCell);
row.appendChild(newEl('td', proposal.authors));
tbody.appendChild(row);