@agent-link/server 0.1.128 → 0.1.130
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/app.js +28 -1
- package/web/index.html +1 -1
- package/web/style.css +2 -0
package/package.json
CHANGED
package/web/app.js
CHANGED
|
@@ -300,6 +300,24 @@ const App = {
|
|
|
300
300
|
let _resizeHandler = () => { isMobile.value = window.innerWidth <= 768; };
|
|
301
301
|
window.addEventListener('resize', _resizeHandler);
|
|
302
302
|
|
|
303
|
+
// ── iOS Safari keyboard fix ──
|
|
304
|
+
// Safari doesn't reliably support interactive-widget=resizes-content,
|
|
305
|
+
// so we use visualViewport API to shrink layout when the keyboard opens.
|
|
306
|
+
let _vvResizeHandler = null;
|
|
307
|
+
let _vvScrollHandler = null;
|
|
308
|
+
if (window.visualViewport) {
|
|
309
|
+
const vv = window.visualViewport;
|
|
310
|
+
const updateViewportHeight = () => {
|
|
311
|
+
// vv.height excludes the virtual keyboard; use it to constrain the layout
|
|
312
|
+
document.documentElement.style.height = vv.height + 'px';
|
|
313
|
+
};
|
|
314
|
+
_vvResizeHandler = updateViewportHeight;
|
|
315
|
+
_vvScrollHandler = updateViewportHeight;
|
|
316
|
+
vv.addEventListener('resize', _vvResizeHandler);
|
|
317
|
+
vv.addEventListener('scroll', _vvScrollHandler);
|
|
318
|
+
updateViewportHeight();
|
|
319
|
+
}
|
|
320
|
+
|
|
303
321
|
// Close workdir menu on outside click or Escape
|
|
304
322
|
let _workdirMenuClickHandler = (e) => {
|
|
305
323
|
if (!workdirMenuOpen.value) return;
|
|
@@ -452,7 +470,16 @@ const App = {
|
|
|
452
470
|
|
|
453
471
|
// ── Lifecycle ──
|
|
454
472
|
onMounted(() => { connect(scheduleHighlight); });
|
|
455
|
-
onUnmounted(() => {
|
|
473
|
+
onUnmounted(() => {
|
|
474
|
+
closeWs(); streaming.cleanup();
|
|
475
|
+
window.removeEventListener('resize', _resizeHandler);
|
|
476
|
+
document.removeEventListener('click', _workdirMenuClickHandler);
|
|
477
|
+
document.removeEventListener('keydown', _workdirMenuKeyHandler);
|
|
478
|
+
if (window.visualViewport) {
|
|
479
|
+
if (_vvResizeHandler) window.visualViewport.removeEventListener('resize', _vvResizeHandler);
|
|
480
|
+
if (_vvScrollHandler) window.visualViewport.removeEventListener('scroll', _vvScrollHandler);
|
|
481
|
+
}
|
|
482
|
+
});
|
|
456
483
|
|
|
457
484
|
return {
|
|
458
485
|
status, agentName, hostname, workDir, sessionId, error,
|
package/web/index.html
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
<html lang="en">
|
|
3
3
|
<head>
|
|
4
4
|
<meta charset="UTF-8">
|
|
5
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0, interactive-widget=resizes-content">
|
|
6
6
|
<title>AgentLink</title>
|
|
7
7
|
<link rel="icon" type="image/svg+xml" href="/favicon.svg">
|
|
8
8
|
<link rel="stylesheet" href="/style.css">
|