Skip to content

Commit e4a7342

Browse files
committed
preview(ui): pr-72 1e99571 1e99571
1 parent 152fa7e commit e4a7342

291 files changed

Lines changed: 24370 additions & 0 deletions

File tree

Some content is hidden

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

pr-72/404.html

Lines changed: 100 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,100 @@
1+
<!DOCTYPE html>
2+
<!--
3+
Stage 9 + Stage 15 (spec 015-neuroscape-context): smart root 404.
4+
5+
gh-pages serves a SINGLE `404.html` from the publishing-source root
6+
for every path that doesn't resolve to a static file. With the
7+
Stage 15 three-mode deployment (`/`, `/ohbm2026/`, `/neuroscape/`),
8+
this single file has to hand a deep-linked request off to the RIGHT
9+
per-mode SvelteKit shell:
10+
11+
1. **Path inside `/ohbm2026/`** (e.g. `<host>/ohbm2026/abstract/<n>/`) →
12+
bounce to `<host>/ohbm2026/?spa=<encoded-original-path>`. The
13+
OHBM 2026 SvelteKit shell at `/ohbm2026/index.html` boots, reads
14+
`?spa=` in `+layout.svelte`'s `onMount`, and `goto`s the deep link.
15+
16+
2. **Path inside `/neuroscape/`** (e.g.
17+
`<host>/neuroscape/abstract/<pubmed_id>/`) → bounce to
18+
`<host>/neuroscape/?spa=…`. Same SvelteKit handoff, different
19+
bundle.
20+
21+
3. **Path inside the atlas-root deploy** (e.g. `<host>/some-random/`)
22+
— no subroutes exist there yet, so bounce to the atlas-root home.
23+
24+
PR previews add a `/pr-<N>/` prefix and the legacy staging used
25+
`/sandbox/` — both have to be honoured in every branch. The prefix
26+
is detected from the request URL so the SAME file works at the
27+
gh-pages root, at every per-PR root, and at the sandbox root.
28+
29+
Relative paths like `./neuroscape/` are NOT safe here — the browser
30+
resolves them against the REQUEST URL, not the file's gh-pages
31+
location. Absolute paths composed from the detected prefix are
32+
correct in every case.
33+
-->
34+
<html lang="en">
35+
<head>
36+
<meta charset="utf-8">
37+
<title>Abstract Atlas — locating your page</title>
38+
<meta name="robots" content="noindex">
39+
<script>
40+
(function () {
41+
var p = window.location.pathname;
42+
var search = window.location.search;
43+
var hash = window.location.hash;
44+
// Detect the prefix the user landed under (per-PR preview or
45+
// the legacy sandbox staging root) so absolute redirects
46+
// compose correctly.
47+
var prefixMatch = p.match(/^(\/(?:pr-\d+|sandbox))\//);
48+
var prefix = prefixMatch ? prefixMatch[1] : '';
49+
50+
// LOOP SAFETY: if we got here AFTER already issuing a
51+
// `?spa=` redirect to the same subsite shell, the target
52+
// SvelteKit bundle isn't deployed in this environment
53+
// (e.g. /neuroscape/ exists in PR-preview but not on
54+
// production until the spec-015 PR merges). Re-redirecting
55+
// would loop forever. Detect that case and fall through
56+
// to the safe atlas-root home instead.
57+
var alreadyRedirected = /[?&]spa=/.test(search);
58+
59+
// 1. Inside /neuroscape/ → bounce to that bundle's SPA shell.
60+
var ns = p.match(/^(\/(?:pr-\d+|sandbox))?\/neuroscape\//);
61+
if (ns && !alreadyRedirected) {
62+
var nsBase = (ns[1] || '') + '/neuroscape';
63+
var stash = p + search + hash;
64+
try { sessionStorage.setItem('ohbm2026.spa.redirect', stash); } catch (e) {}
65+
window.location.replace(nsBase + '/?spa=' + encodeURIComponent(stash));
66+
return;
67+
}
68+
69+
// 2. Inside /ohbm2026/ → bounce to that bundle's SPA shell.
70+
var m = p.match(/^(\/(?:pr-\d+|sandbox))?\/ohbm2026\//);
71+
if (m && !alreadyRedirected) {
72+
var base = (m[1] || '') + '/ohbm2026';
73+
var stash2 = p + search + hash;
74+
try { sessionStorage.setItem('ohbm2026.spa.redirect', stash2); } catch (e) {}
75+
window.location.replace(base + '/?spa=' + encodeURIComponent(stash2));
76+
return;
77+
}
78+
79+
// 3. Outside any known subsite — OR a loop-safety fall-
80+
// through — bounce to the atlas-root home for the current
81+
// prefix. Trailing slash matters because gh-pages serves
82+
// the root index from `/`, not `''`.
83+
window.location.replace((prefix || '') + '/' + search + hash);
84+
})();
85+
</script>
86+
<!-- No-JS fallback: a 2-second meta-refresh + a manual link to
87+
each subsite. Deep-link recovery requires JS and is best-effort. -->
88+
<meta http-equiv="refresh" content="2; url=/">
89+
</head>
90+
<body>
91+
<noscript>
92+
<p>Page not found. Try one of:</p>
93+
<ul>
94+
<li><a href="/">Cross-conference atlas</a></li>
95+
<li><a href="/ohbm2026/">OHBM 2026 Atlas</a></li>
96+
<li><a href="/neuroscape/">NeuroScape PubMed Atlas</a></li>
97+
</ul>
98+
</noscript>
99+
</body>
100+
</html>

pr-72/_app/env.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
export const env={}

pr-72/_app/immutable/assets/0.BtvwxPGw.css

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

pr-72/_app/immutable/assets/1.DmClMd9z.css

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

pr-72/_app/immutable/assets/2.C1kf4n7V.css

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

pr-72/_app/immutable/assets/3.PjM-19we.css

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

pr-72/_app/immutable/assets/4.I7ufn5KF.css

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

pr-72/_app/immutable/assets/DetailPanel.jzpL67me.css

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
27.4 KB
Binary file not shown.
32.7 KB
Binary file not shown.

0 commit comments

Comments
 (0)