mirror of
git://f0xx.org/android_cast
synced 2026-07-29 05:58:14 +03:00
snap
This commit is contained in:
@@ -11,7 +11,7 @@
|
||||
})();
|
||||
</script>
|
||||
<link rel="stylesheet" href="/app/androidcast_project/crashes/assets/css/app.css">
|
||||
<link rel="stylesheet" href="hub.css?v=20260529a">
|
||||
<link rel="stylesheet" href="hub.css?v=20260530h">
|
||||
<link rel="stylesheet" href="hub-logo-layers.css">
|
||||
<script src="assets/analytics.config.js"></script>
|
||||
<script src="/app/androidcast_project/crashes/assets/js/analytics.js" defer></script>
|
||||
@@ -72,29 +72,72 @@
|
||||
</select>
|
||||
</label>
|
||||
</header>
|
||||
<nav class="hub-cards cards cards--lift" aria-label="Android Cast apps">
|
||||
<a class="hub-card card card--lift" href="crashes/?view=reports">
|
||||
<span class="hub-card-icon" aria-hidden="true">
|
||||
<span class="nav-icon nav-icon--reports"></span>
|
||||
</span>
|
||||
<span class="hub-card-label">AndroidCast reports</span>
|
||||
</a>
|
||||
<a class="hub-card card card--lift" href="git/">
|
||||
<span class="hub-card-icon" aria-hidden="true">
|
||||
<span class="nav-icon nav-icon--git"></span>
|
||||
</span>
|
||||
<span class="hub-card-label">AndroidCast git</span>
|
||||
</a>
|
||||
<a class="hub-card card card--lift" href="crashes/?view=tickets">
|
||||
<span class="hub-card-icon" aria-hidden="true">
|
||||
<span class="nav-icon nav-icon--tickets"></span>
|
||||
</span>
|
||||
<span class="hub-card-label">AndroidCast tickets</span>
|
||||
</a>
|
||||
</nav>
|
||||
</main>
|
||||
</div>
|
||||
<nav class="hub-nav-dock" id="hub-nav-dock" aria-label="Android Cast apps">
|
||||
<a class="hub-card card card--lift" href="git/">
|
||||
<span class="hub-card-icon" aria-hidden="true">
|
||||
<span class="nav-icon nav-icon--git"></span>
|
||||
</span>
|
||||
<span class="hub-card-label">AndroidCast git</span>
|
||||
</a>
|
||||
<a class="hub-card card card--lift" href="crashes/?view=tickets">
|
||||
<span class="hub-card-icon" aria-hidden="true">
|
||||
<span class="nav-icon nav-icon--tickets"></span>
|
||||
</span>
|
||||
<span class="hub-card-label">AndroidCast tickets</span>
|
||||
</a>
|
||||
<a class="hub-card card card--lift" href="crashes/?view=reports">
|
||||
<span class="hub-card-icon" aria-hidden="true">
|
||||
<span class="nav-icon nav-icon--reports"></span>
|
||||
</span>
|
||||
<span class="hub-card-label">AndroidCast crashes</span>
|
||||
</a>
|
||||
<a class="hub-card card card--lift" href="build/">
|
||||
<span class="hub-card-icon" aria-hidden="true">
|
||||
<span class="nav-icon nav-icon--builder"></span>
|
||||
</span>
|
||||
<span class="hub-card-label">AndroidCast builder</span>
|
||||
</a>
|
||||
</nav>
|
||||
<footer class="bottom-bar">(c) Anton Afanaasyeu</footer>
|
||||
<script>
|
||||
(function () {
|
||||
var GLOBE_VIEW = { imgW: 1920, imgH: 1080, cx: 720, cy: 560, r: 330 };
|
||||
function globeCoverRect() {
|
||||
var vw = window.innerWidth;
|
||||
var vh = window.innerHeight;
|
||||
var scale = Math.max(vw / GLOBE_VIEW.imgW, vh / GLOBE_VIEW.imgH);
|
||||
var drawW = GLOBE_VIEW.imgW * scale;
|
||||
var drawH = GLOBE_VIEW.imgH * scale;
|
||||
var offX = (vw - drawW) / 2;
|
||||
var offY = (vh - drawH) / 2;
|
||||
var left = offX + (GLOBE_VIEW.cx - GLOBE_VIEW.r) * scale;
|
||||
var top = offY + (GLOBE_VIEW.cy - GLOBE_VIEW.r) * scale;
|
||||
var bottom = offY + (GLOBE_VIEW.cy + GLOBE_VIEW.r) * scale;
|
||||
var right = offX + (GLOBE_VIEW.cx + GLOBE_VIEW.r) * scale;
|
||||
return { left: left, top: top, bottom: bottom, right: right, width: right - left, height: bottom - top };
|
||||
}
|
||||
function layoutHubNavDock() {
|
||||
var dock = document.getElementById('hub-nav-dock');
|
||||
if (!dock) return;
|
||||
var globe = globeCoverRect();
|
||||
var insetX = Math.max(16, globe.width * 0.06);
|
||||
var dockW = Math.min(300, Math.max(210, globe.width * 0.38));
|
||||
dock.style.width = dockW + 'px';
|
||||
dock.style.left = (globe.left + insetX) + 'px';
|
||||
dock.style.top = globe.top + 'px';
|
||||
dock.style.height = globe.height + 'px';
|
||||
dock.style.display = 'flex';
|
||||
dock.style.flexDirection = 'column';
|
||||
dock.style.flexWrap = 'nowrap';
|
||||
dock.style.gap = '5px';
|
||||
dock.style.justifyContent = 'flex-end';
|
||||
}
|
||||
layoutHubNavDock();
|
||||
window.addEventListener('resize', layoutHubNavDock);
|
||||
})();
|
||||
</script>
|
||||
<script>
|
||||
(function () {
|
||||
var sel = document.getElementById('theme-select');
|
||||
@@ -116,7 +159,7 @@
|
||||
var supportsLayout = !!(window.CSS && CSS.supports && CSS.supports('object-fit', 'cover'));
|
||||
if (!supportsSvg || !supportsLayout) return;
|
||||
|
||||
var logoBuild = '20260529a';
|
||||
var logoBuild = '20260530h';
|
||||
var fragments = {
|
||||
space: 'assets/hub-logo-fragment-space.svg',
|
||||
globe: 'assets/hub-logo-fragment-globe.svg',
|
||||
@@ -167,6 +210,44 @@
|
||||
stage.hidden = false;
|
||||
stage.setAttribute('aria-hidden', 'true');
|
||||
|
||||
/* Nav dock overlaps globe left hemisphere; stack top → bottom. */
|
||||
var GLOBE_VIEW = { imgW: 1920, imgH: 1080, cx: 720, cy: 560, r: 330 };
|
||||
function globeCoverRect() {
|
||||
var vw = window.innerWidth;
|
||||
var vh = window.innerHeight;
|
||||
var scale = Math.max(vw / GLOBE_VIEW.imgW, vh / GLOBE_VIEW.imgH);
|
||||
var drawW = GLOBE_VIEW.imgW * scale;
|
||||
var drawH = GLOBE_VIEW.imgH * scale;
|
||||
var offX = (vw - drawW) / 2;
|
||||
var offY = (vh - drawH) / 2;
|
||||
var left = offX + (GLOBE_VIEW.cx - GLOBE_VIEW.r) * scale;
|
||||
var top = offY + (GLOBE_VIEW.cy - GLOBE_VIEW.r) * scale;
|
||||
var bottom = offY + (GLOBE_VIEW.cy + GLOBE_VIEW.r) * scale;
|
||||
var right = offX + (GLOBE_VIEW.cx + GLOBE_VIEW.r) * scale;
|
||||
return { left: left, top: top, bottom: bottom, right: right, width: right - left, height: bottom - top };
|
||||
}
|
||||
function layoutHubNavDock() {
|
||||
var dock = document.getElementById('hub-nav-dock');
|
||||
if (!dock) return;
|
||||
var globe = globeCoverRect();
|
||||
var insetX = Math.max(16, globe.width * 0.06);
|
||||
var dockW = Math.min(300, Math.max(210, globe.width * 0.38));
|
||||
dock.style.width = dockW + 'px';
|
||||
dock.style.left = (globe.left + insetX) + 'px';
|
||||
dock.style.top = globe.top + 'px';
|
||||
dock.style.height = globe.height + 'px';
|
||||
dock.style.right = 'auto';
|
||||
dock.style.bottom = 'auto';
|
||||
dock.style.display = 'flex';
|
||||
dock.style.flexDirection = 'column';
|
||||
dock.style.flexWrap = 'nowrap';
|
||||
dock.style.alignItems = 'stretch';
|
||||
dock.style.gap = '5px';
|
||||
dock.style.justifyContent = 'flex-end';
|
||||
}
|
||||
layoutHubNavDock();
|
||||
window.addEventListener('resize', layoutHubNavDock);
|
||||
|
||||
var docsModal = document.getElementById('hub-docs-modal');
|
||||
var docsToc = document.getElementById('hub-docs-toc');
|
||||
var docsPanels = document.getElementById('hub-docs-panels');
|
||||
@@ -737,15 +818,20 @@
|
||||
return model;
|
||||
});
|
||||
|
||||
function setClockopiaText(el, text) {
|
||||
if (!el) return;
|
||||
el.textContent = text;
|
||||
}
|
||||
|
||||
function updateClockWidget() {
|
||||
var now = new Date();
|
||||
var p = timeParts(now, primaryTz);
|
||||
renderOvertimeDigits(document.getElementById('cw-hm-lcd'), p.hh + p.mm, false, false);
|
||||
renderOvertimeDigits(document.getElementById('cw-colon-lcd'), ':', false, false);
|
||||
renderOvertimeDigits(document.getElementById('cw-ss-lcd'), p.ss, false, false);
|
||||
renderOvertimeText(document.getElementById('cw-tz-text'), gmtOffsetLabel(now, primaryTz), { bold: false });
|
||||
renderOvertimeText(document.getElementById('cw-region'), regionLabel(primaryTz), { bold: false });
|
||||
renderOvertimeText(document.getElementById('cw-date-line'), formatDateLine(now, primaryTz), { bold: false });
|
||||
setClockopiaText(document.getElementById('cw-hm-lcd'), p.hh + ':' + p.mm);
|
||||
setClockopiaText(document.getElementById('cw-colon-lcd'), ':');
|
||||
setClockopiaText(document.getElementById('cw-ss-lcd'), p.ss);
|
||||
setClockopiaText(document.getElementById('cw-tz-text'), gmtOffsetLabel(now, primaryTz));
|
||||
setClockopiaText(document.getElementById('cw-region'), regionLabel(primaryTz));
|
||||
setClockopiaText(document.getElementById('cw-date-line'), formatDateLine(now, primaryTz));
|
||||
|
||||
secondary.forEach(function (clock) {
|
||||
var t = timeParts(now, clock.tz);
|
||||
@@ -836,10 +922,8 @@
|
||||
widget.releasePointerCapture(ev.pointerId);
|
||||
});
|
||||
})();
|
||||
loadOvertimeAlphabet(function () {
|
||||
updateClockWidget();
|
||||
setInterval(updateClockWidget, 1000);
|
||||
});
|
||||
updateClockWidget();
|
||||
setInterval(updateClockWidget, 1000);
|
||||
})();
|
||||
</script>
|
||||
</body>
|
||||
|
||||
Reference in New Issue
Block a user