jaxon-agents 0.1.0 → 0.2.0
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/README.md +39 -31
- package/README.zh-CN.md +42 -34
- package/dist/BUILD_INFO.json +3 -3
- package/dist/PACKAGE_MANIFEST.json +31 -25
- package/dist/RELEASE_META.json +8 -2
- package/dist/api/mcp-tools.js +5 -4
- package/dist/connections/health.js +4 -1
- package/dist/console/activity-client.js +620 -0
- package/dist/console/activity-page.js +24 -0
- package/dist/console/activity-topics.js +640 -0
- package/dist/console/activity.js +379 -0
- package/dist/console/assets.js +207 -16
- package/dist/console/pages.js +38 -17
- package/dist/console/server.js +51 -5
- package/dist/console/station-pages.js +40 -6
- package/dist/daemon/client.js +1 -1
- package/dist/daemon/host.js +2 -0
- package/dist/environment/pi-launch-spec.js +1 -1
- package/dist/ops/catalog.js +1 -0
- package/dist/ops/core.js +89 -35
- package/dist/pi-host/history-reader.js +20 -0
- package/dist/pi-host/mcp-bridge.entry.js +22 -5
- package/dist/sessions/dashboard-usage.js +5 -3
- package/dist/sessions/supervisor.js +391 -31
- package/dist/stations/cues.js +59 -48
- package/dist/stations/interactions.js +75 -0
- package/dist/stations/member-instructions.js +25 -0
- package/dist/stations/station-member.entry.js +6 -6
- package/package.json +8 -2
- package/runtime/provenance.json +3 -3
- package/runtime/runtime-lock.json +2 -2
- package/runtime/runtime-package.json +1 -1
|
@@ -0,0 +1,620 @@
|
|
|
1
|
+
export const ACTIVITY_JS = String.raw `
|
|
2
|
+
function mountStationActivity() {
|
|
3
|
+
const root = document.querySelector('[data-station-activity]');
|
|
4
|
+
if (!root || root.dataset.mounted) return;
|
|
5
|
+
root.dataset.mounted = 'true';
|
|
6
|
+
const overview = root.hasAttribute('data-overview-activity');
|
|
7
|
+
const find = selector => root.querySelector(selector);
|
|
8
|
+
const stage = find('[data-activity-stage]'), scene = stage.parentElement;
|
|
9
|
+
const nodesTarget = find('[data-activity-nodes]');
|
|
10
|
+
const hub = find('.activity-hub'), lanes = [...root.querySelectorAll('.activity-lane')];
|
|
11
|
+
const svg = find('[data-activity-edges]'), trails = find('[data-activity-trails]'), pulseLayer = find('[data-activity-pulses]');
|
|
12
|
+
const status = find('[data-activity-status]'), empty = find('[data-activity-empty]'), title = find('[data-activity-title]');
|
|
13
|
+
const buttons = [...root.querySelectorAll('[data-activity-window]')];
|
|
14
|
+
const motion = matchMedia('(prefers-reduced-motion: reduce)');
|
|
15
|
+
const cards = new Map(), edges = new Map(), watchTopics = new Map(), departures = new Map(), moves = new Map(), pulses = new Set();
|
|
16
|
+
const animated = new Set(), cueArrivals = new Map();
|
|
17
|
+
let windowName = '10m', snapshot, cursor, clock = 0, offline = false, ghost, tooltipOwner;
|
|
18
|
+
let generation = 0, controller, timer, lastStart = -Infinity, failures = 0, frame = 0, needsLayout = false, motionUntil = 0;
|
|
19
|
+
const svgNode = name => document.createElementNS('http://www.w3.org/2000/svg', name);
|
|
20
|
+
const label = (en, zh) => snapshot?.topic_language === 'zh-CN' ? zh : en;
|
|
21
|
+
const setText = (node, text) => { if (node.textContent !== text) node.textContent = text; };
|
|
22
|
+
const dates = value => Date.parse(value) || 0;
|
|
23
|
+
const edgeKey = edge => [edge.from, edge.to, edge.kind].join('\0');
|
|
24
|
+
const running = new Set(['starting', 'running', 'stopping']);
|
|
25
|
+
const hues = [204, 266, 172, 325, 218, 28];
|
|
26
|
+
const hueFor = id => hues[[...id].reduce((hash, ch) => (31 * hash + ch.codePointAt(0)) >>> 0, 0) % hues.length];
|
|
27
|
+
const tooltip = el('div', {className:'activity-tooltip', attrs:{'aria-hidden':'true'}});
|
|
28
|
+
tooltip.hidden = true;
|
|
29
|
+
root.append(tooltip);
|
|
30
|
+
|
|
31
|
+
function animate(element, keyframes, options, finish) {
|
|
32
|
+
if (motion.matches) { finish?.(); return; }
|
|
33
|
+
const animation = element.animate(keyframes, options);
|
|
34
|
+
animated.add(animation);
|
|
35
|
+
animation.onfinish = () => { animated.delete(animation); finish?.(); };
|
|
36
|
+
animation.oncancel = () => animated.delete(animation);
|
|
37
|
+
return animation;
|
|
38
|
+
}
|
|
39
|
+
const restOpacity = element => element.classList.contains('activity-node')
|
|
40
|
+
? Number(getComputedStyle(element).getPropertyValue('--card-opacity')) : 1;
|
|
41
|
+
function fadeIn(element) { animate(element, [{opacity:0}, {opacity:restOpacity(element)}], {duration:420, easing:'ease-out'}); }
|
|
42
|
+
function leave(element, remove) {
|
|
43
|
+
if (departures.has(element)) return;
|
|
44
|
+
if (motion.matches) { remove(); return; }
|
|
45
|
+
element.inert = true;
|
|
46
|
+
const finish = () => { departures.delete(element); remove(); };
|
|
47
|
+
departures.set(element, {finish, animation:animate(element, [{opacity:getComputedStyle(element).opacity}, {opacity:0}],
|
|
48
|
+
{duration:380, easing:'ease-in', fill:'forwards'}, finish)});
|
|
49
|
+
}
|
|
50
|
+
function revive(element) {
|
|
51
|
+
const departure = departures.get(element);
|
|
52
|
+
if (!departure) return;
|
|
53
|
+
const opacity = getComputedStyle(element).opacity;
|
|
54
|
+
departure.animation.cancel(); departures.delete(element);
|
|
55
|
+
element.inert = false;
|
|
56
|
+
animate(element, [{opacity}, {opacity:restOpacity(element)}], {duration:350, easing:'ease-out'});
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
function toggleTopic(row, over, focus) {
|
|
60
|
+
if (over !== undefined) row.over = over;
|
|
61
|
+
if (focus !== undefined) row.focus = focus;
|
|
62
|
+
if (row.scroll) {
|
|
63
|
+
if (row.over || row.focus || document.hidden) row.scroll.pause();
|
|
64
|
+
else if (row.scroll.playState === 'paused') row.scroll.play();
|
|
65
|
+
}
|
|
66
|
+
if ((row.over || row.focus) && row.text) {
|
|
67
|
+
tooltipOwner = row;
|
|
68
|
+
setText(tooltip, row.description);
|
|
69
|
+
tooltip.hidden = false;
|
|
70
|
+
locateTooltip();
|
|
71
|
+
} else if (tooltipOwner === row) hideTooltip();
|
|
72
|
+
}
|
|
73
|
+
function hideTooltip() { tooltip.hidden = true; tooltipOwner = undefined; }
|
|
74
|
+
function locateTooltip() {
|
|
75
|
+
if (!tooltipOwner) return;
|
|
76
|
+
const box = tooltipOwner.link.getBoundingClientRect(), bounds = root.getBoundingClientRect();
|
|
77
|
+
const clip = tooltipOwner.link.closest('.activity-sessions').getBoundingClientRect();
|
|
78
|
+
if (box.bottom < clip.top || box.top > clip.bottom) { hideTooltip(); return; }
|
|
79
|
+
tooltip.style.left = Math.max(10, Math.min(box.left - bounds.left, bounds.width - tooltip.offsetWidth - 10)) + 'px';
|
|
80
|
+
tooltip.style.top = Math.min(bounds.height - tooltip.offsetHeight - 8, box.bottom - bounds.top + 6) + 'px';
|
|
81
|
+
}
|
|
82
|
+
function measureTopic(row) {
|
|
83
|
+
const distance = Math.ceil(row.track.offsetWidth - row.viewport.clientWidth);
|
|
84
|
+
if (row.distance === distance && row.reduced === motion.matches) return;
|
|
85
|
+
row.distance = distance; row.reduced = motion.matches;
|
|
86
|
+
row.scroll?.cancel(); row.scroll = null;
|
|
87
|
+
row.viewport.classList.toggle('overflowing', distance > 2);
|
|
88
|
+
if (motion.matches || distance <= 2) return;
|
|
89
|
+
const leg = distance / 45 * 1000, pause = 850, duration = (leg + pause) * 2;
|
|
90
|
+
row.scroll = row.track.animate([
|
|
91
|
+
{transform:'translateX(0px)', offset:0}, {transform:'translateX(0px)', offset:pause / duration},
|
|
92
|
+
{transform:'translateX(-' + distance + 'px)', offset:(pause + leg) / duration},
|
|
93
|
+
{transform:'translateX(-' + distance + 'px)', offset:(2 * pause + leg) / duration},
|
|
94
|
+
{transform:'translateX(0px)', offset:1},
|
|
95
|
+
], {duration, iterations:Infinity});
|
|
96
|
+
if (row.over || row.focus || document.hidden) row.scroll.pause();
|
|
97
|
+
}
|
|
98
|
+
const resize = new ResizeObserver(entries => {
|
|
99
|
+
for (const entry of entries) {
|
|
100
|
+
const row = watchTopics.get(entry.target);
|
|
101
|
+
if (row) measureTopic(row);
|
|
102
|
+
else scheduleFrame(true);
|
|
103
|
+
}
|
|
104
|
+
});
|
|
105
|
+
resize.observe(stage);
|
|
106
|
+
|
|
107
|
+
function sessionState(session) {
|
|
108
|
+
if (session.status === 'closed') return ['closed', label('Closed', '已关闭')];
|
|
109
|
+
if (session.status === 'waiting_input') return ['waiting_input', label('Waiting for input', '等待输入')];
|
|
110
|
+
if (running.has(session.status)) return ['running', label('Running', '运行中')];
|
|
111
|
+
if (session.queued_turns > 0) return ['queued', label('Queued', '排队中')];
|
|
112
|
+
if (session.status === 'failed') return ['failed', label('Failed', '失败')];
|
|
113
|
+
return ['idle', label('Idle', '空闲')];
|
|
114
|
+
}
|
|
115
|
+
const cueLabels = {
|
|
116
|
+
scheduled: ['Will be delivered on the next turn', '将在下一轮送达'], cooldown: ['Wake cooling down', '唤醒冷却中'],
|
|
117
|
+
rate_limited: ['Wake limit reached', '已达唤醒上限'], deferred_cap: ['Wake deferred', '唤醒已延后'],
|
|
118
|
+
hop_limit: ['No wake: relay limit', '转发上限:仅送达'], blocked: ['Wake blocked', '唤醒受阻'],
|
|
119
|
+
not_runnable: ['Session cannot run', '会话暂不可运行'],
|
|
120
|
+
};
|
|
121
|
+
const unread = count => count + label(' unread cues', ' 条待读提醒');
|
|
122
|
+
function cueDescription(cue) {
|
|
123
|
+
if (!cue?.count) return '';
|
|
124
|
+
const state = cueLabels[cue.wake];
|
|
125
|
+
return [unread(cue.count), cue.senders?.join(', '), state && label(...state)].filter(Boolean).join(' · ');
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
function sessionRow(session) {
|
|
129
|
+
const badge = el('span', {className:'activity-state-dot', attrs:{'aria-hidden':'true'}});
|
|
130
|
+
const track = el('span', {className:'activity-topic-track'});
|
|
131
|
+
const viewport = el('span', {className:'activity-topic-viewport'}, [track]);
|
|
132
|
+
const cueBadge = el('span', {className:'cue-badge activity-cue-count'}); cueBadge.hidden = true;
|
|
133
|
+
const cueIcon = el('span', {className:'activity-cue-origin', text:'↯', attrs:{'aria-hidden':'true'}}); cueIcon.hidden = true;
|
|
134
|
+
const link = el('a', {className:'activity-session', attrs:{'data-session-id':session.session_id,
|
|
135
|
+
href:session.url, target:'_blank', rel:'noopener'}}, [badge, cueBadge, cueIcon, viewport]);
|
|
136
|
+
const row = {link, badge, cueBadge, cueIcon, track, viewport};
|
|
137
|
+
link.addEventListener('pointerenter', () => toggleTopic(row, true));
|
|
138
|
+
link.addEventListener('pointerleave', () => toggleTopic(row, false));
|
|
139
|
+
link.addEventListener('focus', () => toggleTopic(row, undefined, true));
|
|
140
|
+
link.addEventListener('blur', () => toggleTopic(row, undefined, false));
|
|
141
|
+
watchTopics.set(viewport, row); resize.observe(viewport);
|
|
142
|
+
return row;
|
|
143
|
+
}
|
|
144
|
+
function clearRow(row) {
|
|
145
|
+
if (tooltipOwner === row) hideTooltip();
|
|
146
|
+
resize.unobserve(row.viewport); watchTopics.delete(row.viewport);
|
|
147
|
+
row.scroll?.cancel(); row.link.remove();
|
|
148
|
+
}
|
|
149
|
+
function updateRow(row, session, arriving = false) {
|
|
150
|
+
row.latestSession = session;
|
|
151
|
+
const cue = session.pending_cues;
|
|
152
|
+
const rise = (cue?.count ?? 0) > (row.cueCount ?? 0);
|
|
153
|
+
const arrival = cueArrivals.get(session.session_id);
|
|
154
|
+
const startingCue = session.origin === 'cue' && !row.cueOrigin;
|
|
155
|
+
if (arrival && row.text !== undefined && (rise || startingCue)) {
|
|
156
|
+
arrival.startsTurn = startingCue;
|
|
157
|
+
arrival.row = row;
|
|
158
|
+
return false;
|
|
159
|
+
}
|
|
160
|
+
const [state, name] = sessionState(session), topic = session.topic;
|
|
161
|
+
const topicText = topic?.text || label('Session', '会话');
|
|
162
|
+
const summary = topic?.state === 'generating' || topic?.stale ? label('Updating summary', '正在更新主题')
|
|
163
|
+
: topic?.source === 'fallback' ? label('No model summary yet', '暂无模型主题') : '';
|
|
164
|
+
row.link.dataset.state = row.badge.dataset.state = state;
|
|
165
|
+
row.link.classList.toggle('closed', state === 'closed');
|
|
166
|
+
row.link.classList.toggle('activity-fallback', topic?.source === 'fallback');
|
|
167
|
+
row.link.dataset.topicSource = topic?.source ?? 'fallback';
|
|
168
|
+
row.cueCount = cue?.count ?? 0;
|
|
169
|
+
row.cueOrigin = session.origin === 'cue';
|
|
170
|
+
row.cueBadge.hidden = !row.cueCount;
|
|
171
|
+
if (row.cueCount) setText(row.cueBadge, String(row.cueCount));
|
|
172
|
+
row.cueIcon.hidden = !row.cueOrigin;
|
|
173
|
+
const cueText = cueDescription(cue);
|
|
174
|
+
const origin = row.cueOrigin ? label('Woken by a cue', '由同事提醒唤醒') : '';
|
|
175
|
+
row.cueBadge.title = cueText; row.cueIcon.title = origin;
|
|
176
|
+
if (arriving && rise) animate(row.cueBadge, [{transform:'scale(1.22)', color:'#fff'}, {transform:'scale(1)'}], {duration:340, easing:'ease-out'});
|
|
177
|
+
row.description = [topicText, name, cueText, origin, summary, session.session_id].filter(Boolean).join(' · ');
|
|
178
|
+
row.link.setAttribute('aria-label', [topicText, name, cueText, origin, label('opens in a new tab', '在新标签页打开')].filter(Boolean).join(' · '));
|
|
179
|
+
if (row.text !== topicText) {
|
|
180
|
+
const changed = row.text !== undefined;
|
|
181
|
+
row.text = topicText;
|
|
182
|
+
setText(row.track, topicText);
|
|
183
|
+
row.distance = undefined;
|
|
184
|
+
if (changed) fadeIn(row.track);
|
|
185
|
+
}
|
|
186
|
+
if (tooltipOwner === row) setText(tooltip, row.description);
|
|
187
|
+
return true;
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
function createCard(node) {
|
|
191
|
+
const master = node.kind === 'master';
|
|
192
|
+
const light = el('div', {className:'activity-light', attrs:{'aria-hidden':'true'}});
|
|
193
|
+
const badge = el('span', {className:'activity-emblem', attrs:{'aria-hidden':'true'}}, [el('span', {text:master ? '✦' : [...node.id][0]?.toUpperCase() ?? '•'})]);
|
|
194
|
+
const name = el('span', {text:master ? label('Master', '主控') : node.id});
|
|
195
|
+
const openSession = el('a', {text:node.id, attrs:{target:'_blank', rel:'noopener'}}); openSession.hidden = true;
|
|
196
|
+
const heading = el('h3', {className:'activity-name'}, [name, openSession]);
|
|
197
|
+
const count = el('small', {className:'activity-count'});
|
|
198
|
+
const identity = el('div', {className:'activity-identity'}, [heading, count]);
|
|
199
|
+
const top = el('div', {className:'activity-node-head'}, [badge, identity]);
|
|
200
|
+
const card = el('article', {className:'activity-node' + (master ? ' master' : ''), attrs:{'data-agent-id':node.id}}, [light, top]);
|
|
201
|
+
card.style.setProperty('--role-hue', String(master ? 42 : hueFor(node.id)));
|
|
202
|
+
const rows = new Map();
|
|
203
|
+
if (master) { hub.append(card); return {card, name, count, rows}; }
|
|
204
|
+
const gear = el('a', {className:'activity-gear', text:'⚙', attrs:{href:node.url}});
|
|
205
|
+
const cueCount = el('span', {className:'cue-badge'}); cueCount.hidden = true;
|
|
206
|
+
top.append(cueCount, gear);
|
|
207
|
+
const list = el('div', {className:'activity-sessions'});
|
|
208
|
+
const more = el('a', {className:'activity-more', attrs:{href:'/sessions?' + new URLSearchParams({station:snapshot.station_id, agent:node.id})}});
|
|
209
|
+
const stack = el('div', {className:'activity-session-stack'}, [more]);
|
|
210
|
+
list.append(stack); card.append(list);
|
|
211
|
+
const lane = lanes[0].childElementCount <= lanes[1].childElementCount ? lanes[0] : lanes[1];
|
|
212
|
+
lane.append(card);
|
|
213
|
+
return {card, name, openSession, count, cueCount, gear, list, stack, more, rows};
|
|
214
|
+
}
|
|
215
|
+
function fitSessions(view, change, first = false) {
|
|
216
|
+
const before = view.list.getBoundingClientRect().height;
|
|
217
|
+
const previous = view.listMotion;
|
|
218
|
+
change();
|
|
219
|
+
const max = parseFloat(getComputedStyle(view.list).maxHeight) || Infinity;
|
|
220
|
+
const after = Math.min(view.stack.offsetHeight, max);
|
|
221
|
+
if (previous && previous.target === after) return;
|
|
222
|
+
previous?.animation.cancel(); view.listMotion = undefined;
|
|
223
|
+
if (first || motion.matches || Math.abs(before - after) < 1) return;
|
|
224
|
+
// Resize in flow so the cards below move without crossing each other.
|
|
225
|
+
const animation = animate(view.list, [{height:before + 'px'}, {height:after + 'px'}],
|
|
226
|
+
{duration:460, easing:'cubic-bezier(.25,.7,.25,1)'}, () => { view.listMotion = undefined; scheduleFrame(true); });
|
|
227
|
+
view.listMotion = {animation, target:after};
|
|
228
|
+
motionUntil = performance.now() + 475;
|
|
229
|
+
scheduleFrame(true);
|
|
230
|
+
}
|
|
231
|
+
function updateCard(view, node, first) {
|
|
232
|
+
view.node = node;
|
|
233
|
+
if (node.kind === 'master') {
|
|
234
|
+
setText(view.name, label('Master', '主控'));
|
|
235
|
+
setText(view.count, label('Station coordinator', 'Station 协调者'));
|
|
236
|
+
return;
|
|
237
|
+
}
|
|
238
|
+
view.card.classList.toggle('former', !node.in_roster);
|
|
239
|
+
const count = node.active_sessions + label(' active', ' 活跃') + ' / ' + node.window_sessions + label(' in window', ' 个窗口内会话');
|
|
240
|
+
setText(view.count, count + (node.in_roster ? '' : label(' · former', ' · 已退出')));
|
|
241
|
+
const single = node.window_sessions === 1 && node.sessions.length === 1;
|
|
242
|
+
view.openSession.hidden = !single; view.name.hidden = single;
|
|
243
|
+
if (single) view.openSession.href = node.sessions[0].url;
|
|
244
|
+
view.gear.title = label('Open agent settings', '打开角色设置');
|
|
245
|
+
view.gear.setAttribute('aria-label', view.gear.title + ': ' + node.id);
|
|
246
|
+
view.cueCount.hidden = !node.pending_cues;
|
|
247
|
+
if (node.pending_cues) {
|
|
248
|
+
setText(view.cueCount, String(node.pending_cues)); view.cueCount.title = unread(node.pending_cues);
|
|
249
|
+
view.cueCount.setAttribute('aria-label', view.cueCount.title);
|
|
250
|
+
}
|
|
251
|
+
fitSessions(view, () => {
|
|
252
|
+
const truncated = node.window_sessions - node.sessions.length;
|
|
253
|
+
view.more.hidden = truncated <= 0;
|
|
254
|
+
if (truncated > 0) setText(view.more, label('View all sessions →', '查看全部会话 →'));
|
|
255
|
+
const ids = new Set(node.sessions.map(session => session.session_id));
|
|
256
|
+
for (const [id, row] of view.rows) {
|
|
257
|
+
if (!ids.has(id)) {
|
|
258
|
+
const clear = () => { clearRow(row); view.rows.delete(id); };
|
|
259
|
+
if (motion.matches) clear();
|
|
260
|
+
else leave(row.link, () => fitSessions(view, clear));
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
for (const session of node.sessions) {
|
|
264
|
+
let row = view.rows.get(session.session_id);
|
|
265
|
+
const fresh = !row;
|
|
266
|
+
if (fresh) { row = sessionRow(session); view.rows.set(session.session_id, row); }
|
|
267
|
+
revive(row.link);
|
|
268
|
+
if (!updateRow(row, session)) cueArrivals.get(session.session_id).view = view;
|
|
269
|
+
// Keep the relative order of existing rows; scrolling and focus stay in place.
|
|
270
|
+
if (fresh) { view.stack.insertBefore(row.link, view.more); fadeIn(row.link); measureTopic(row); }
|
|
271
|
+
else if (row.distance === undefined) measureTopic(row);
|
|
272
|
+
}
|
|
273
|
+
}, first);
|
|
274
|
+
cueCardActivity(view);
|
|
275
|
+
}
|
|
276
|
+
function cueCardActivity(view) {
|
|
277
|
+
const delayed = view.node.sessions.filter(session => session.origin === 'cue' &&
|
|
278
|
+
cueArrivals.get(session.session_id)?.startsTurn).length;
|
|
279
|
+
view.card.classList.toggle('active', view.node.active_sessions > delayed);
|
|
280
|
+
}
|
|
281
|
+
function compactCard(view) {
|
|
282
|
+
const before = new Map([...cards.values()].filter(other => other !== view && other.node.kind !== 'master')
|
|
283
|
+
.map(other => [other.card, other.card.getBoundingClientRect().top]));
|
|
284
|
+
disposeCard(view);
|
|
285
|
+
const after = [...before].map(([card, y]) => [card, y - (card.getBoundingClientRect().top - (moves.get(card) ? translateY(card) : 0))]);
|
|
286
|
+
if (!motion.matches) for (const [card, delta] of after) {
|
|
287
|
+
if (Math.abs(delta) < .5) continue;
|
|
288
|
+
moves.get(card)?.cancel();
|
|
289
|
+
moves.set(card, animate(card, [{transform:'translateY(' + delta + 'px)'}, {transform:'translateY(0px)'}],
|
|
290
|
+
{duration:520, easing:'cubic-bezier(.25,.7,.25,1)'}, () => { moves.delete(card); scheduleFrame(true); }));
|
|
291
|
+
motionUntil = performance.now() + 530;
|
|
292
|
+
}
|
|
293
|
+
scheduleFrame(true);
|
|
294
|
+
}
|
|
295
|
+
function translateY(card) {
|
|
296
|
+
const transform = getComputedStyle(card).transform;
|
|
297
|
+
return transform === 'none' ? 0 : new DOMMatrixReadOnly(transform).m42;
|
|
298
|
+
}
|
|
299
|
+
function disposeCard(view) {
|
|
300
|
+
for (const row of view.rows.values()) { departures.get(row.link)?.animation.cancel(); departures.delete(row.link); clearRow(row); }
|
|
301
|
+
view.listMotion?.animation.cancel();
|
|
302
|
+
moves.get(view.card)?.cancel(); moves.delete(view.card);
|
|
303
|
+
view.card.remove(); cards.delete(view.node.id);
|
|
304
|
+
}
|
|
305
|
+
|
|
306
|
+
function route(edge, boxes) {
|
|
307
|
+
const a = boxes.get(edge.from), b = boxes.get(edge.to);
|
|
308
|
+
if (!a || !b) return null;
|
|
309
|
+
const report = edge.kind === 'report';
|
|
310
|
+
const port = box => Math.min(box.bottom - 6, box.top + (edge.kind === 'cue' ? 25 : report ? 20 : 11));
|
|
311
|
+
const master = boxes.get('master');
|
|
312
|
+
if (edge.from === edge.to || (a.lane !== hub && b.lane !== hub && Math.abs(a.left - b.left) < 2)) {
|
|
313
|
+
// Same-column cues stay outside the lane rather than crossing other cards.
|
|
314
|
+
const left = master && a.right <= master.left;
|
|
315
|
+
const outer = box => left ? box.left : box.right;
|
|
316
|
+
const side = left ? -1 : 1;
|
|
317
|
+
const x = outer(a), y = port(a);
|
|
318
|
+
if (edge.from === edge.to) return [x, y - 12, x + side * 21, y - 14, x + side * 21, y + 15, x, y + 9];
|
|
319
|
+
const end = port(b);
|
|
320
|
+
return [x, y, x + side * 23, y, outer(b) + side * 23, end, outer(b), end];
|
|
321
|
+
}
|
|
322
|
+
const toMaster = edge.to === 'master';
|
|
323
|
+
const agent = toMaster ? a : b;
|
|
324
|
+
if (master && (toMaster || edge.from === 'master') && master.left < agent.right && master.right > agent.left) {
|
|
325
|
+
// The stacked mobile layout has a left gutter for dispatch and report.
|
|
326
|
+
const x = master.left + (report ? 17 : 8), y = master.bottom, end = port(agent);
|
|
327
|
+
const rail = agent.left - (report ? 11 : 18);
|
|
328
|
+
const curve = [x, y, rail, y + 9, rail, end, agent.left, end];
|
|
329
|
+
return toMaster ? [curve[6], curve[7], curve[4], curve[5], curve[2], curve[3], x, y] : curve;
|
|
330
|
+
}
|
|
331
|
+
const direction = a.left < b.left ? 1 : -1;
|
|
332
|
+
const x1 = direction > 0 ? a.right : a.left, x2 = direction > 0 ? b.left : b.right;
|
|
333
|
+
const y1 = port(a), y2 = port(b);
|
|
334
|
+
const bend = direction * Math.min(100, Math.abs(x1 - x2) * .45);
|
|
335
|
+
const bypassHub = edge.kind === 'cue' && master && master.left > Math.min(x1, x2) && master.right < Math.max(x1, x2);
|
|
336
|
+
const under = bypassHub ? (master.bottom + 10 - .125 * (y1 + y2)) / .75 : -Infinity;
|
|
337
|
+
return [x1, y1, x1 + bend, Math.max(y1, under), x2 - bend, Math.max(y2, under), x2, y2];
|
|
338
|
+
}
|
|
339
|
+
function layoutEdges() {
|
|
340
|
+
if (stage.hidden) return;
|
|
341
|
+
const rect = stage.getBoundingClientRect();
|
|
342
|
+
const boxes = new Map();
|
|
343
|
+
for (const [id, view] of cards) {
|
|
344
|
+
const box = view.card.getBoundingClientRect();
|
|
345
|
+
boxes.set(id, {left:box.left - rect.left, right:box.right - rect.left,
|
|
346
|
+
top:box.top - rect.top, bottom:box.bottom - rect.top, lane:view.card.parentNode});
|
|
347
|
+
}
|
|
348
|
+
for (const item of edges.values()) {
|
|
349
|
+
const next = route(item.edge, boxes);
|
|
350
|
+
if (!next) { item.curve = null; continue; }
|
|
351
|
+
item.curve = next;
|
|
352
|
+
const d = 'M ' + next[0] + ' ' + next[1] + ' C ' + next.slice(2).join(' ');
|
|
353
|
+
if (item.d !== d) { item.d = d; item.path.setAttribute('d', d); }
|
|
354
|
+
}
|
|
355
|
+
}
|
|
356
|
+
function flash(view, kind) {
|
|
357
|
+
if (!view || !view.card.isConnected) return;
|
|
358
|
+
view.flash?.cancel();
|
|
359
|
+
const color = kind === 'cue' ? '#cbafff' : kind === 'steer' ? '#ffb97c' : kind === 'dispatch' ? '#ffd592' : '#9ceceb';
|
|
360
|
+
view.flash = animate(view.card, [{outline:'2px solid ' + color, outlineOffset:'-1px'},
|
|
361
|
+
{outline:'2px solid transparent', outlineOffset:'5px'}], {duration:490, easing:'ease-out'});
|
|
362
|
+
}
|
|
363
|
+
function finishCueArrival(arrival, highlight = true) {
|
|
364
|
+
if (!arrival || cueArrivals.get(arrival.sessionId) !== arrival) return;
|
|
365
|
+
cueArrivals.delete(arrival.sessionId);
|
|
366
|
+
const { row, view } = arrival;
|
|
367
|
+
if (row?.link.isConnected) {
|
|
368
|
+
updateRow(row, row.latestSession, highlight);
|
|
369
|
+
if (row.distance === undefined) measureTopic(row);
|
|
370
|
+
}
|
|
371
|
+
if (view?.card.isConnected) { cueCardActivity(view); decay(); }
|
|
372
|
+
}
|
|
373
|
+
function clearPulses() {
|
|
374
|
+
for (const {point} of pulses) point.remove();
|
|
375
|
+
pulses.clear();
|
|
376
|
+
for (const arrival of cueArrivals.values()) finishCueArrival(arrival, false);
|
|
377
|
+
}
|
|
378
|
+
function launch(item, count) {
|
|
379
|
+
const edge = item.edge;
|
|
380
|
+
const arrival = edge.kind === 'cue' ? cueArrivals.get(edge.last?.to_session) : undefined;
|
|
381
|
+
const matchingArrival = arrival?.cueId === edge.last?.cue_id ? arrival : undefined;
|
|
382
|
+
const kind = edge.kind === 'dispatch' && edge.last?.delivery === 'steered' ? 'steer' : edge.kind;
|
|
383
|
+
for (let i = 0; i < count; i++) {
|
|
384
|
+
const point = svgNode('circle');
|
|
385
|
+
point.setAttribute('class', 'activity-pulse ' + kind);
|
|
386
|
+
point.setAttribute('r', kind === 'cue' ? '3.5' : '3');
|
|
387
|
+
point.setAttribute('visibility', 'hidden');
|
|
388
|
+
pulseLayer.append(point);
|
|
389
|
+
pulses.add({point, item, target:cards.get(edge.to), kind, start:performance.now() + i * 135, last:i === count - 1,
|
|
390
|
+
arrival:i === 0 ? matchingArrival : undefined});
|
|
391
|
+
}
|
|
392
|
+
scheduleFrame(true);
|
|
393
|
+
}
|
|
394
|
+
function movePulses(now) {
|
|
395
|
+
for (const pulse of pulses) {
|
|
396
|
+
const {point, item, target, kind, last, arrival} = pulse, p = item.curve;
|
|
397
|
+
const t = (now - pulse.start) / 890;
|
|
398
|
+
if (t < 0) continue;
|
|
399
|
+
if (t >= 1 || !p || !item.path.isConnected) {
|
|
400
|
+
point.remove(); pulses.delete(pulse);
|
|
401
|
+
finishCueArrival(arrival, t >= 1 && !!p);
|
|
402
|
+
if (t >= 1 && last) flash(target, kind);
|
|
403
|
+
continue;
|
|
404
|
+
}
|
|
405
|
+
const u = 1 - t;
|
|
406
|
+
point.setAttribute('visibility', 'visible');
|
|
407
|
+
point.setAttribute('transform', 'translate(' + (u*u*u*p[0] + 3*u*u*t*p[2] + 3*u*t*t*p[4] + t*t*t*p[6]) + ' '
|
|
408
|
+
+ (u*u*u*p[1] + 3*u*u*t*p[3] + 3*u*t*t*p[5] + t*t*t*p[7]) + ')');
|
|
409
|
+
}
|
|
410
|
+
}
|
|
411
|
+
function scheduleFrame(layout = false) {
|
|
412
|
+
needsLayout ||= layout;
|
|
413
|
+
if (frame || document.hidden) return;
|
|
414
|
+
frame = requestAnimationFrame(now => {
|
|
415
|
+
frame = 0;
|
|
416
|
+
if (needsLayout || now < motionUntil) { needsLayout = false; layoutEdges(); locateTooltip(); }
|
|
417
|
+
movePulses(now);
|
|
418
|
+
if (pulses.size || now < motionUntil) scheduleFrame();
|
|
419
|
+
});
|
|
420
|
+
}
|
|
421
|
+
function newEdgeEvent(edge, old, previous) {
|
|
422
|
+
return old ? dates(edge.last_at) > dates(old.last_at) || edge.count > old.count
|
|
423
|
+
: dates(edge.last_at) >= dates(previous.now);
|
|
424
|
+
}
|
|
425
|
+
function syncEdges(previous, effects) {
|
|
426
|
+
const nextKeys = new Set(snapshot.edges.map(edgeKey));
|
|
427
|
+
for (const [key, item] of edges) {
|
|
428
|
+
if (!nextKeys.has(key)) leave(item.path, () => { item.path.remove(); edges.delete(key); });
|
|
429
|
+
}
|
|
430
|
+
const prior = new Map((previous?.edges ?? []).map(edge => [edgeKey(edge), edge]));
|
|
431
|
+
for (const edge of snapshot.edges) {
|
|
432
|
+
const key = edgeKey(edge);
|
|
433
|
+
let item = edges.get(key);
|
|
434
|
+
const fresh = !item;
|
|
435
|
+
if (fresh) {
|
|
436
|
+
const path = svgNode('path');
|
|
437
|
+
path.setAttribute('class', 'activity-edge ' + edge.kind);
|
|
438
|
+
trails.append(path);
|
|
439
|
+
item = {edge, path}; edges.set(key, item);
|
|
440
|
+
}
|
|
441
|
+
revive(item.path); item.edge = edge;
|
|
442
|
+
if (fresh) fadeIn(item.path);
|
|
443
|
+
if (!effects || motion.matches) continue;
|
|
444
|
+
const old = prior.get(key);
|
|
445
|
+
if (newEdgeEvent(edge, old, previous)) launch(item, old ? Math.min(3, Math.max(1, edge.count - old.count)) : 1);
|
|
446
|
+
}
|
|
447
|
+
scheduleFrame(true);
|
|
448
|
+
}
|
|
449
|
+
|
|
450
|
+
function brightness(at, now) {
|
|
451
|
+
const delta = Math.max(0, now - at);
|
|
452
|
+
return delta >= snapshot.window_ms ? 0 : Math.max(.08, Math.exp(-4 * delta / snapshot.window_ms));
|
|
453
|
+
}
|
|
454
|
+
function decay() {
|
|
455
|
+
if (!snapshot || document.hidden) return;
|
|
456
|
+
const now = Date.now() - clock;
|
|
457
|
+
let master = 0;
|
|
458
|
+
for (const edge of snapshot.edges) {
|
|
459
|
+
const value = brightness(dates(edge.last_at), now);
|
|
460
|
+
const item = edges.get(edgeKey(edge));
|
|
461
|
+
if (item) setHeat(item.path, value);
|
|
462
|
+
if (edge.to === 'master' || edge.from === 'master') master = Math.max(master, value);
|
|
463
|
+
}
|
|
464
|
+
for (const view of cards.values()) {
|
|
465
|
+
if (departures.has(view.card)) continue;
|
|
466
|
+
const node = view.node;
|
|
467
|
+
const value = node.kind === 'master' ? master : view.card.classList.contains('active') ? 1
|
|
468
|
+
: node.window_sessions ? brightness(dates(node.last_activity_at ?? node.sessions[0]?.last_activity_at), now) : .15;
|
|
469
|
+
setHeat(view.card, value);
|
|
470
|
+
}
|
|
471
|
+
}
|
|
472
|
+
function setHeat(element, value) {
|
|
473
|
+
const next = value.toFixed(4);
|
|
474
|
+
if (element.style.getPropertyValue('--heat') !== next) element.style.setProperty('--heat', next);
|
|
475
|
+
}
|
|
476
|
+
|
|
477
|
+
function crossFade() {
|
|
478
|
+
hideTooltip(); ghost?.remove();
|
|
479
|
+
if (!stage.hidden && !motion.matches) {
|
|
480
|
+
const old = stage.cloneNode(true);
|
|
481
|
+
old.classList.add('activity-outgoing'); old.setAttribute('aria-hidden', 'true'); old.inert = true;
|
|
482
|
+
old.style.height = stage.offsetHeight + 'px';
|
|
483
|
+
old.querySelector('[data-activity-pulses]').replaceChildren();
|
|
484
|
+
const oldRows = old.querySelectorAll('.activity-sessions');
|
|
485
|
+
stage.querySelectorAll('.activity-sessions').forEach((list, index) => { oldRows[index].dataset.scrollTop = list.scrollTop; });
|
|
486
|
+
scene.append(old); ghost = old;
|
|
487
|
+
for (const list of oldRows) list.scrollTop = Number(list.dataset.scrollTop);
|
|
488
|
+
animate(old, [{opacity:1}, {opacity:0}], {duration:460, easing:'ease-in-out'}, () => { old.remove(); if (ghost === old) ghost = null; });
|
|
489
|
+
}
|
|
490
|
+
for (const departure of departures.values()) departure.animation.cancel();
|
|
491
|
+
departures.clear();
|
|
492
|
+
for (const view of cards.values()) disposeCard(view);
|
|
493
|
+
clearPulses();
|
|
494
|
+
edges.clear(); trails.replaceChildren();
|
|
495
|
+
if (!stage.hidden) fadeIn(stage);
|
|
496
|
+
}
|
|
497
|
+
function updateStatus() {
|
|
498
|
+
const batch = snapshot?.topics_batch;
|
|
499
|
+
setText(status, offline ? label('Offline · retrying', '离线 · 正在重试') : batch?.pending
|
|
500
|
+
? label('Updating topics', '正在更新主题') + ' · ' + batch.pending : batch?.state === 'off'
|
|
501
|
+
? label('Topics off', '主题已关闭') : '');
|
|
502
|
+
root.classList.toggle('activity-offline', offline);
|
|
503
|
+
}
|
|
504
|
+
function render(previous, effects) {
|
|
505
|
+
if (overview && previous && snapshot._selected?.station_id !== previous._selected?.station_id) crossFade();
|
|
506
|
+
updateStatus();
|
|
507
|
+
if (overview) {
|
|
508
|
+
setText(title, snapshot._selected?.name ?? 'Activity');
|
|
509
|
+
title.href = snapshot._selected?.url ?? '/stations';
|
|
510
|
+
}
|
|
511
|
+
stage.hidden = !snapshot.nodes.length;
|
|
512
|
+
empty.hidden = false;
|
|
513
|
+
if (!snapshot.nodes.length) empty.replaceChildren(label('No Stations yet. ', '还没有 Station。'),
|
|
514
|
+
el('a', {text:label('Create a Station →', '新建 Station →'), attrs:{href:'/stations?view=new'}}));
|
|
515
|
+
else if (!snapshot.edges.length && !snapshot.nodes.some(node => node.window_sessions)) {
|
|
516
|
+
setText(empty, label('No activity in this window.', '该窗口内没有活动。'));
|
|
517
|
+
} else empty.hidden = true;
|
|
518
|
+
if (effects && !motion.matches) {
|
|
519
|
+
const prior = new Map(previous.edges.map(edge => [edgeKey(edge), edge]));
|
|
520
|
+
const visible = new Set(snapshot.nodes.map(node => node.id));
|
|
521
|
+
for (const edge of snapshot.edges) {
|
|
522
|
+
const sessionId = edge.last?.to_session, cueId = edge.last?.cue_id;
|
|
523
|
+
if (edge.kind !== 'cue' || !sessionId || !visible.has(edge.from) || !visible.has(edge.to)
|
|
524
|
+
|| !newEdgeEvent(edge, prior.get(edgeKey(edge)), previous) || cueArrivals.has(sessionId)) continue;
|
|
525
|
+
cueArrivals.set(sessionId, { sessionId, cueId });
|
|
526
|
+
}
|
|
527
|
+
}
|
|
528
|
+
const ids = new Set(snapshot.nodes.map(node => node.id));
|
|
529
|
+
for (const [id, view] of cards) {
|
|
530
|
+
if (!ids.has(id)) leave(view.card, () => compactCard(view));
|
|
531
|
+
}
|
|
532
|
+
for (const node of snapshot.nodes) {
|
|
533
|
+
let view = cards.get(node.id);
|
|
534
|
+
const fresh = !view;
|
|
535
|
+
if (fresh) { view = createCard(node); cards.set(node.id, view); }
|
|
536
|
+
revive(view.card); updateCard(view, node, fresh);
|
|
537
|
+
if (fresh) fadeIn(view.card);
|
|
538
|
+
}
|
|
539
|
+
syncEdges(previous, effects);
|
|
540
|
+
decay();
|
|
541
|
+
}
|
|
542
|
+
|
|
543
|
+
const interval = () => windowName === '1m' || windowName === '10m' ? 5000 : 30000;
|
|
544
|
+
function queue(wait = 0) {
|
|
545
|
+
clearTimeout(timer);
|
|
546
|
+
if (!document.hidden) timer = setTimeout(requestActivity, Math.max(wait, lastStart + interval() + 12 - performance.now(), 0));
|
|
547
|
+
}
|
|
548
|
+
async function requestActivity() {
|
|
549
|
+
if (document.hidden) return;
|
|
550
|
+
const version = ++generation;
|
|
551
|
+
controller?.abort(); controller = new AbortController();
|
|
552
|
+
lastStart = performance.now();
|
|
553
|
+
const query = new URLSearchParams({window:windowName});
|
|
554
|
+
if (cursor) { query.set('since', cursor); query.set('wait_ms', interval() === 5000 ? '25000' : '55000'); }
|
|
555
|
+
const endpoint = overview ? '/api/overview/activity' : '/api/stations/' + encodeURIComponent(root.dataset.stationActivity) + '/activity';
|
|
556
|
+
try {
|
|
557
|
+
const response = await fetch(endpoint + '?' + query, {signal:controller.signal, cache:'no-store'});
|
|
558
|
+
if (!response.ok) throw new Error('activity_unavailable');
|
|
559
|
+
const body = await response.json();
|
|
560
|
+
if (version !== generation) return;
|
|
561
|
+
const next = overview ? {...(body.snapshot ?? {nodes:[], edges:[], topic_language:body.topic_language}), _selected:body.selected} : body;
|
|
562
|
+
const changed = !snapshot || body.changed !== false;
|
|
563
|
+
const recovered = offline;
|
|
564
|
+
offline = false; failures = 0;
|
|
565
|
+
if (next.now) clock = Date.now() - dates(next.now);
|
|
566
|
+
if (changed) {
|
|
567
|
+
const previous = snapshot;
|
|
568
|
+
const effects = Boolean(cursor && previous && previous.window === next.window &&
|
|
569
|
+
(!overview || previous._selected?.station_id === next._selected?.station_id));
|
|
570
|
+
snapshot = next;
|
|
571
|
+
render(previous, effects);
|
|
572
|
+
} else if (recovered) updateStatus();
|
|
573
|
+
cursor = body.cursor ?? next.cursor;
|
|
574
|
+
queue();
|
|
575
|
+
} catch (error) {
|
|
576
|
+
if (version !== generation || error.name === 'AbortError') return;
|
|
577
|
+
offline = true; updateStatus();
|
|
578
|
+
if (!snapshot) {
|
|
579
|
+
empty.hidden = false;
|
|
580
|
+
setText(empty, label('Activity is temporarily unavailable.', '活动图暂时不可用。'));
|
|
581
|
+
}
|
|
582
|
+
queue([5000, 15000, 60000][Math.min(2, failures++)]);
|
|
583
|
+
}
|
|
584
|
+
}
|
|
585
|
+
for (const button of buttons) button.addEventListener('click', () => {
|
|
586
|
+
if (windowName === button.dataset.activityWindow) return;
|
|
587
|
+
windowName = button.dataset.activityWindow;
|
|
588
|
+
for (const choice of buttons) choice.setAttribute('aria-pressed', String(choice === button));
|
|
589
|
+
generation++; controller?.abort(); cursor = undefined; lastStart = -Infinity;
|
|
590
|
+
queue();
|
|
591
|
+
});
|
|
592
|
+
document.addEventListener('visibilitychange', () => {
|
|
593
|
+
if (document.hidden) {
|
|
594
|
+
generation++; clearTimeout(timer); controller?.abort();
|
|
595
|
+
cancelAnimationFrame(frame); frame = 0;
|
|
596
|
+
clearPulses(); hideTooltip();
|
|
597
|
+
for (const row of watchTopics.values()) row.scroll?.pause();
|
|
598
|
+
} else {
|
|
599
|
+
for (const row of watchTopics.values()) if (!row.focus && !row.over) row.scroll?.play();
|
|
600
|
+
decay(); scheduleFrame(true); queue();
|
|
601
|
+
}
|
|
602
|
+
});
|
|
603
|
+
motion.addEventListener('change', () => {
|
|
604
|
+
if (motion.matches) {
|
|
605
|
+
for (const {animation, finish} of [...departures.values()]) { animation.cancel(); finish(); }
|
|
606
|
+
for (const animation of animated) animation.cancel();
|
|
607
|
+
animated.clear(); moves.clear(); motionUntil = 0;
|
|
608
|
+
for (const view of cards.values()) view.listMotion = undefined;
|
|
609
|
+
clearPulses();
|
|
610
|
+
ghost?.remove();
|
|
611
|
+
}
|
|
612
|
+
for (const row of watchTopics.values()) measureTopic(row);
|
|
613
|
+
scheduleFrame(true);
|
|
614
|
+
});
|
|
615
|
+
root.addEventListener('scroll', () => { if (tooltipOwner) hideTooltip(); }, true);
|
|
616
|
+
root.addEventListener('keydown', event => { if (event.key === 'Escape') hideTooltip(); });
|
|
617
|
+
setInterval(decay, 250);
|
|
618
|
+
queue();
|
|
619
|
+
}
|
|
620
|
+
`;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { esc } from "./util.js";
|
|
2
|
+
export function activityPanel(stationId = '', overview = false) {
|
|
3
|
+
return `<section class="activity-panel" id="${overview ? 'overview-activity' : 'station-activity'}" data-station-activity="${esc(stationId)}"${overview ? ' data-overview-activity="true"' : ''}>
|
|
4
|
+
<header class="activity-header">
|
|
5
|
+
<div class="activity-heading"><div class="activity-kicker"><span></span> Station activity</div>
|
|
6
|
+
<h2>${overview ? '<a data-activity-title href="/stations">Activity</a>' : 'Activity map'}</h2>
|
|
7
|
+
</div>
|
|
8
|
+
<div class="activity-tools">${overview ? '<a class="activity-all" href="/stations">All stations →</a>' : ''}
|
|
9
|
+
<div class="activity-window" role="group" aria-label="Activity window">${['1m', '10m', '1h', '1d'].map(window => `<button type="button" class="secondary" data-activity-window="${window}" aria-pressed="${window === '10m'}">${window}</button>`).join('')}</div>
|
|
10
|
+
</div>
|
|
11
|
+
</header>
|
|
12
|
+
<div class="activity-meta">
|
|
13
|
+
<div class="activity-legend" aria-label="Connection types"><span data-link="dispatch">Dispatch</span><span data-link="report">Report</span><span data-link="cue">Cue</span></div>
|
|
14
|
+
<div class="activity-batch" data-activity-status role="status">Loading activity…</div>
|
|
15
|
+
</div>
|
|
16
|
+
<p class="activity-empty" data-activity-empty hidden></p>
|
|
17
|
+
<div class="activity-scene">
|
|
18
|
+
<div class="activity-stage" data-activity-stage hidden>
|
|
19
|
+
<svg class="activity-edges" data-activity-edges aria-hidden="true"><g data-activity-trails></g><g data-activity-pulses></g></svg>
|
|
20
|
+
<div class="activity-nodes" data-activity-nodes><div class="activity-hub"></div><div class="activity-agent-lanes"><div class="activity-lane"></div><div class="activity-lane"></div></div></div>
|
|
21
|
+
</div>
|
|
22
|
+
</div>
|
|
23
|
+
</section>`;
|
|
24
|
+
}
|