@agent-link/server 0.1.536 → 0.1.538
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/web/dist/landing/icons/agent-claude.svg +1 -0
- package/web/dist/landing/icons/agent-codex.svg +1 -0
- package/web/dist/landing/icons/agent-copilot.svg +1 -0
- package/web/dist/landing/icons/agent-pi.svg +5 -0
- package/web/dist/landing/icons/msclaude-animated.svg +43 -0
- package/web/dist/landing/landing.css +1228 -0
- package/web/dist/landing/landing.js +71 -0
- package/web/dist/landing.html +212 -572
- package/web/dist/landing.zh.html +212 -567
- package/web/dist/robots.txt +4 -0
- package/web/dist/site.webmanifest +21 -0
- package/web/dist/sitemap.xml +16 -0
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
const root = document.documentElement;
|
|
2
|
+
const header = document.querySelector('.site-header');
|
|
3
|
+
const toast = document.querySelector('.toast');
|
|
4
|
+
const installCommand = document.body.dataset.installCommand;
|
|
5
|
+
|
|
6
|
+
root.classList.add('motion-ready');
|
|
7
|
+
|
|
8
|
+
function fallbackCopy(text) {
|
|
9
|
+
const textarea = document.createElement('textarea');
|
|
10
|
+
textarea.value = text;
|
|
11
|
+
textarea.setAttribute('readonly', '');
|
|
12
|
+
textarea.style.position = 'fixed';
|
|
13
|
+
textarea.style.opacity = '0';
|
|
14
|
+
document.body.appendChild(textarea);
|
|
15
|
+
textarea.select();
|
|
16
|
+
const copied = document.execCommand('copy');
|
|
17
|
+
textarea.remove();
|
|
18
|
+
return copied;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
async function copyText(text) {
|
|
22
|
+
if (navigator.clipboard && window.isSecureContext) {
|
|
23
|
+
await navigator.clipboard.writeText(text);
|
|
24
|
+
return true;
|
|
25
|
+
}
|
|
26
|
+
return fallbackCopy(text);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
function showToast(message) {
|
|
30
|
+
if (!toast) return;
|
|
31
|
+
toast.textContent = message;
|
|
32
|
+
toast.classList.add('show');
|
|
33
|
+
window.clearTimeout(showToast.timeout);
|
|
34
|
+
showToast.timeout = window.setTimeout(() => toast.classList.remove('show'), 1800);
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
document.querySelectorAll('[data-copy-install]').forEach((button) => {
|
|
38
|
+
button.addEventListener('click', async () => {
|
|
39
|
+
try {
|
|
40
|
+
const copied = await copyText(installCommand);
|
|
41
|
+
showToast(copied ? document.body.dataset.copySuccess : document.body.dataset.copyFailure);
|
|
42
|
+
} catch {
|
|
43
|
+
showToast(document.body.dataset.copyFailure);
|
|
44
|
+
}
|
|
45
|
+
});
|
|
46
|
+
});
|
|
47
|
+
|
|
48
|
+
const updateHeader = () => {
|
|
49
|
+
header?.classList.toggle('is-scrolled', window.scrollY > 12);
|
|
50
|
+
};
|
|
51
|
+
|
|
52
|
+
updateHeader();
|
|
53
|
+
window.addEventListener('scroll', updateHeader, { passive: true });
|
|
54
|
+
|
|
55
|
+
if ('IntersectionObserver' in window) {
|
|
56
|
+
const observer = new IntersectionObserver((entries) => {
|
|
57
|
+
entries.forEach((entry) => {
|
|
58
|
+
if (!entry.isIntersecting) return;
|
|
59
|
+
entry.target.classList.add('is-visible');
|
|
60
|
+
observer.unobserve(entry.target);
|
|
61
|
+
});
|
|
62
|
+
}, { threshold: 0.12 });
|
|
63
|
+
|
|
64
|
+
document.querySelectorAll('.reveal').forEach((element) => observer.observe(element));
|
|
65
|
+
} else {
|
|
66
|
+
document.querySelectorAll('.reveal').forEach((element) => element.classList.add('is-visible'));
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
document.querySelectorAll('[data-year]').forEach((element) => {
|
|
70
|
+
element.textContent = String(new Date().getFullYear());
|
|
71
|
+
});
|