Initial icosin.org website

Static site for ICOSIN (International Conference on Smart Informatics),
organized by the Department of Informatics, Universitas Tanjungpura.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Izuardo Zulkarnain
2026-10-15 22:08:42 +07:00
co-authored by Claude Opus 5.5
commit c7872ade11
25 changed files with 1878 additions and 0 deletions
+223
View File
@@ -0,0 +1,223 @@
/* ICOSIN site — shared header/footer, menus, and data-driven blocks. */
(function () {
"use strict";
document.documentElement.classList.remove("no-js");
var D = window.ICOSIN;
var ed = D.editions[D.current];
var root = document.body.getAttribute("data-root") || "";
var page = document.body.getAttribute("data-page") || "";
var cfp = D.pretalxBase + "/" + ed.pretalxSlug + "/";
var Y = ed.year + "/";
var icon = {
menu: '<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round"><path d="M4 7h16M4 12h16M4 17h16"/></svg>',
close: '<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round"><path d="M6 6l12 12M18 6L6 18"/></svg>',
chev: '<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round"><path d="M6 9l6 6 6-6"/></svg>'
};
var NAV = [
{ label: "Call for Papers", href: Y, id: "edition" },
{ label: "Committees", id: "committee", sub: [
{ label: "Advisory Board", href: "committee/#advisory" },
{ label: "Technical Program Committee", href: "committee/#tpc" },
{ label: "Reviewers", href: "reviewers/" },
{ label: "Organizing Committee", href: "committee/#organizing" }
] },
{ label: "Speakers", href: Y + "#speakers" },
{ label: "For Authors", id: "authors", sub: [
{ label: "Submission Guidelines", href: "authors/#guidelines" },
{ label: "Paper Template", href: "authors/#template" },
{ label: "Registration Fee", href: "authors/#fees" },
{ label: "Program Schedule", href: "authors/#schedule" },
{ label: "Presentation Template", href: "authors/#presentation" },
{ label: "Virtual Background (Zoom)", href: "authors/#background" },
{ label: "Flyer", href: "authors/#flyer" }
] },
{ label: "Proceedings", href: "proceedings/", id: "proceedings" },
{ label: "Previous ICOSIN", href: "past/", id: "past" },
{ label: "Contact", href: "contact/", id: "contact" }
];
function esc(s) { return String(s).replace(/[&<>"]/g, function (c) { return { "&": "&amp;", "<": "&lt;", ">": "&gt;", '"': "&quot;" }[c]; }); }
/* ---------- header ---------- */
var header = document.getElementById("site-header");
if (header) {
var desktop = NAV.map(function (n) {
var cur = n.id === page ? ' aria-current="page"' : "";
if (n.sub) {
return '<li class="has-sub"><button type="button" aria-haspopup="true"' + cur + ">" + n.label + icon.chev + '</button><ul class="submenu">' +
n.sub.map(function (s) { return '<li><a href="' + root + s.href + '">' + s.label + "</a></li>"; }).join("") + "</ul></li>";
}
return '<li><a href="' + root + n.href + '"' + cur + ">" + n.label + "</a></li>";
}).join("");
var mobile = '<a href="' + root + '">Home</a>' + NAV.map(function (n) {
if (n.sub) return '<div class="group">' + n.label + "</div>" + n.sub.map(function (s) { return '<a class="sub" href="' + root + s.href + '">' + s.label + "</a>"; }).join("");
return '<a href="' + root + n.href + '">' + n.label + "</a>";
}).join("");
header.className = "site-header";
header.innerHTML =
'<div class="wrap nav">' +
'<a class="brand" href="' + root + '" aria-label="ICOSIN home">' +
'<img src="' + root + 'assets/img/icosin-mark.png" alt="" width="40" height="39">' +
"<span><b>ICOSIN</b><small>Int'l Conference on Smart Informatics</small></span>" +
"</a>" +
'<ul class="nav-links">' + desktop +
'<li class="nav-cta"><a class="btn btn-primary btn-sm" href="' + cfp + '" target="_blank" rel="noopener">Author Portal</a></li>' +
"</ul>" +
'<button class="menu-toggle" aria-label="Open menu" aria-expanded="false">' + icon.menu + "</button>" +
"</div>" +
'<nav class="mobile-menu" aria-label="Mobile">' + mobile +
'<a class="btn btn-primary" href="' + cfp + '" target="_blank" rel="noopener">Author Portal</a>' +
"</nav>";
var toggle = header.querySelector(".menu-toggle");
var menu = header.querySelector(".mobile-menu");
toggle.addEventListener("click", function () {
var open = menu.classList.toggle("open");
toggle.setAttribute("aria-expanded", open);
toggle.innerHTML = open ? icon.close : icon.menu;
document.body.style.overflow = open ? "hidden" : "";
});
menu.addEventListener("click", function (e) { if (e.target.tagName === "A") toggle.click(); });
}
/* ---------- footer ---------- */
function logoTile(file, alt, wide) {
return '<div class="logo-tile' + (wide ? " wide" : "") + '"><img src="' + root + "assets/img/logos/" + file + '" alt="' + esc(alt) + '" loading="lazy"></div>';
}
var footer = document.getElementById("site-footer");
if (footer) {
footer.className = "site-footer";
footer.innerHTML =
'<div class="wrap">' +
'<div class="foot-grid">' +
"<div>" +
'<a class="brand" href="' + root + '"><img src="' + root + 'assets/img/icosin-mark.png" alt="" width="40" height="39"><span><b>ICOSIN</b><small>Int\'l Conference on Smart Informatics</small></span></a>' +
'<p style="margin-top:16px;max-width:380px">An annual international conference on artificial intelligence, informatics and computing, organized by the ' + esc(D.owner.name) + ", Pontianak — on the Equator, in the heart of Borneo.</p>" +
'<div class="foot-owner">' + D.owner.logos.map(function (l) { return logoTile(l.file, l.alt, l.wide); }).join("") + "</div>" +
"</div>" +
"<div><h4>Conference</h4><ul>" +
'<li><a href="' + root + Y + '">ICOSIN ' + ed.year + "</a></li>" +
'<li><a href="' + root + Y + '#speakers">Speakers</a></li>' +
'<li><a href="' + root + 'committee/">Committees</a></li>' +
'<li><a href="' + root + 'reviewers/">Reviewers</a></li>' +
'<li><a href="' + root + 'past/">Previous ICOSIN</a></li>' +
"</ul></div>" +
"<div><h4>For Authors</h4><ul>" +
'<li><a href="' + root + 'authors/#guidelines">Submission Guidelines</a></li>' +
'<li><a href="' + root + 'authors/#template">Paper Template</a></li>' +
'<li><a href="' + root + 'authors/#fees">Registration Fee</a></li>' +
'<li><a href="' + root + 'proceedings/">Proceedings &amp; Policies</a></li>' +
"</ul></div>" +
"<div><h4>Contact</h4><ul>" +
'<li><a href="mailto:' + D.email + '">' + D.email + "</a></li>" +
"<li>" + esc(D.owner.name) + "</li>" +
"<li>Jl. Prof. Dr. H. Hadari Nawawi, Pontianak 78124, West Kalimantan, Indonesia</li>" +
'<li><a href="' + cfp + '" target="_blank" rel="noopener">Author Portal ↗</a></li>' +
"</ul></div>" +
"</div>" +
'<div class="foot-bottom"><span>© ' + new Date().getFullYear() + " ICOSIN · " + esc(D.owner.name) + "</span><span>ICOSIN " + ed.year + " co-hosted with Universiti Malaysia Sarawak (UNIMAS)</span></div>" +
"</div>";
}
/* ---------- helpers ---------- */
var MONTHS = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"];
function fmtDate(iso) { var p = iso.split("-"); return MONTHS[+p[1] - 1] + " " + +p[2] + ", " + p[0]; }
function todayISO() { return new Date(Date.now() + 7 * 3600 * 1000).toISOString().slice(0, 10); }
function idr(n) { return "IDR " + n.toLocaleString("en-US"); }
document.querySelectorAll("[data-ed]").forEach(function (el) { var v = ed[el.getAttribute("data-ed")]; if (v != null) el.textContent = v; });
document.querySelectorAll("[data-cfp]").forEach(function (el) { el.href = cfp; });
document.querySelectorAll("[data-mail]").forEach(function (el) { el.href = "mailto:" + D.email; if (!el.textContent.trim()) el.textContent = D.email; });
/* Important dates, with changed dates struck through */
document.querySelectorAll("[data-render=dates]").forEach(function (el) {
var today = todayISO(), nextDone = false;
el.innerHTML = ed.dates.map(function (d) {
var cls = [];
if (d.date < today) cls.push("past");
else if (!nextDone) { cls.push("next"); nextDone = true; }
if (d.main) cls.push("main");
return '<li class="' + cls.join(" ") + '"><time datetime="' + d.date + '"' + (d.was ? ' class="changed"' : "") + ">" +
(d.was ? '<s title="Original date">' + fmtDate(d.was) + "</s>" : "") + fmtDate(d.date) +
"</time><strong>" + esc(d.label) + "</strong></li>";
}).join("");
});
document.querySelectorAll("[data-render=fees]").forEach(function (el) {
el.innerHTML = "<table><thead><tr><th>Category</th><th>Fee</th></tr></thead><tbody>" +
ed.fees.map(function (f) { return "<tr><td>" + esc(f.who) + '</td><td class="num">' + idr(f.idr) + "</td></tr>"; }).join("") +
"</tbody></table>";
});
function personCard(p, flag) {
return '<div class="card person reveal"><div class="ph"><img src="' + root + "assets/img/people/" + p.photo + '" alt="' + esc(p.name) + '" loading="lazy"></div>' +
"<h3>" + esc(p.name) + "</h3><p>" + esc(p.affiliation) + "</p>" + (flag && p.country ? '<span class="flag">' + esc(p.country) + "</span>" : "") + "</div>";
}
document.querySelectorAll("[data-render=keynotes]").forEach(function (el) { el.innerHTML = ed.keynotes.map(function (p) { return personCard(p, true); }).join(""); });
document.querySelectorAll("[data-render=welcoming]").forEach(function (el) { el.innerHTML = ed.welcoming.map(function (p) { return personCard(p, false); }).join(""); });
document.querySelectorAll("[data-render=speakers-row]").forEach(function (el) {
var list = el.getAttribute("data-list") === "welcoming" ? ed.welcoming : ed.keynotes;
el.innerHTML = list.map(function (p) {
return '<div class="speaker"><div class="ph"><img src="' + root + "assets/img/people/" + p.photo + '" alt="" loading="lazy"></div><div><b>' + esc(p.name) + "</b><span>" + esc(p.affiliation) + "</span></div></div>";
}).join("");
});
document.querySelectorAll("[data-render=tracks]").forEach(function (el) {
var limit = +(el.getAttribute("data-limit") || 0);
el.innerHTML = ed.tracks.map(function (t) {
var list = limit ? t.topics.slice(0, limit) : t.topics;
var more = limit && t.topics.length > limit ? '<a class="more" href="' + root + Y + '#tracks">+ ' + (t.topics.length - limit) + " more topics →</a>" : "";
return '<div class="card track"><span class="tag">' + esc(t.code) + "</span><h3>" + esc(t.name) + "</h3><ul>" +
list.map(function (x) { return "<li>" + esc(x) + "</li>"; }).join("") + "</ul>" + more + "</div>";
}).join("");
});
/* Partners of the edition, grouped by role */
document.querySelectorAll("[data-render=partners]").forEach(function (el) {
el.className += " logo-strip";
el.innerHTML = ed.partners.map(function (p) {
return '<div class="logo-group"><h4>' + esc(p.role) + '</h4><div class="row">' +
p.logos.map(function (f) { return logoTile(f, p.name, /informatika/.test(f)); }).join("") +
"</div><p>" + esc(p.name) + "</p></div>";
}).join("");
});
/* General chair welcome message */
document.querySelectorAll("[data-render=chair]").forEach(function (el) {
var c = ed.generalChair;
var initials = c.name.replace(/(Prof|Dr|S\.T|M\.T)\.?/g, "").match(/\b[A-Z]/g) || [];
el.innerHTML = '<div class="chair">' +
'<div class="chair-photo">' + (c.photo ? '<img src="' + root + "assets/img/people/" + c.photo + '" alt="' + esc(c.name) + '">' : "<span>" + initials.slice(0, 2).join("") + "</span>") + "</div>" +
"<div><blockquote>" + c.message.map(function (p) { return "<p>" + esc(p) + "</p>"; }).join("") + "</blockquote>" +
'<div class="sig"><b>' + esc(c.name) + "</b><span>" + esc(c.title) + "</span></div></div></div>";
});
/* Countdown */
document.querySelectorAll("[data-render=countdown]").forEach(function (cd) {
var target = new Date(ed.startTime).getTime();
cd.innerHTML = ["Days", "Hours", "Minutes", "Seconds"].map(function (p) { return "<div><b>0</b><small>" + p + "</small></div>"; }).join("");
var cells = cd.querySelectorAll("b");
var tick = function () {
var s = Math.max(0, Math.floor((target - Date.now()) / 1000));
[Math.floor(s / 86400), Math.floor(s % 86400 / 3600), Math.floor(s % 3600 / 60), s % 60].forEach(function (v, i) {
cells[i].textContent = i ? String(v).padStart(2, "0") : v;
});
};
tick(); setInterval(tick, 1000);
});
/* Reveal on scroll */
var els = document.querySelectorAll(".reveal");
if ("IntersectionObserver" in window) {
var io = new IntersectionObserver(function (entries) {
entries.forEach(function (e) { if (e.isIntersecting) { e.target.classList.add("in"); io.unobserve(e.target); } });
}, { rootMargin: "0px 0px -8% 0px" });
els.forEach(function (el) { io.observe(el); });
} else {
els.forEach(function (el) { el.classList.add("in"); });
}
})();