@firstpick/pi-package-webui 0.10.0 → 0.10.1
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/DEVELOPMENT.md +7 -2
- package/README.md +5 -3
- package/TECHNICAL.md +4 -0
- package/bin/pi-webui.mjs +5 -4
- package/package.json +1 -1
- package/public/app.js +145 -33
- package/public/index.html +10 -7
- package/public/service-worker.js +1 -1
- package/public/styles.css +51 -7
- package/tests/boot-failure-diagnostics.test.mjs +3 -3
- package/tests/browser/interaction-continuity.spec.mjs +9 -3
- package/tests/codex-fast-mode-static.test.mjs +2 -2
- package/tests/composer-action-grid-reorder-static.test.mjs +3 -3
- package/tests/control-visibility-static.test.mjs +3 -3
- package/tests/controls-layout-static.test.mjs +3 -3
- package/tests/events-tree-context-menu-static.test.mjs +3 -3
- package/tests/fast-mode-client-static.test.mjs +1 -1
- package/tests/feature-decision-output-popup-static.test.mjs +2 -2
- package/tests/file-viewer-image-static.test.mjs +3 -3
- package/tests/guided-git-activation-static.test.mjs +3 -3
- package/tests/guided-git-fallback-ui-static.test.mjs +2 -2
- package/tests/guided-git-publication-backend-static.test.mjs +10 -5
- package/tests/http-endpoints-harness.test.mjs +5 -9
- package/tests/intercom-conversation-viewer-static.test.mjs +3 -3
- package/tests/main-output-loading-static.test.mjs +18 -12
- package/tests/middle-button-drag-scroll-static.test.mjs +3 -3
- package/tests/mobile-continuity-tablet-static.test.mjs +3 -3
- package/tests/mobile-foundation-static.test.mjs +3 -3
- package/tests/mobile-phone-experience-static.test.mjs +1 -1
- package/tests/mobile-static.test.mjs +8 -5
- package/tests/open-issue-wizard-static.test.mjs +1 -1
- package/tests/optional-feature-prompt-impact-static.test.mjs +67 -0
- package/tests/persistent-ui-layout-static.test.mjs +3 -3
- package/tests/prompt-input-vertical-scroll-static.test.mjs +3 -3
- package/tests/questionnaire-dialog.test.mjs +3 -3
- package/tests/session-sampling-ui-static.test.mjs +3 -3
- package/tests/side-panel-section-height-removal-static.test.mjs +3 -3
- package/tests/streaming-ui-coupling.test.mjs +2 -0
- package/tests/subagent-observability-static.test.mjs +2 -2
- package/tests/syntax-highlighting-static.test.mjs +3 -3
- package/tests/theme-customizer-static.test.mjs +1 -1
- package/tests/windows-drive-cwd-picker-static.test.mjs +3 -3
package/public/index.html
CHANGED
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
<link rel="manifest" href="/manifest.webmanifest" />
|
|
13
13
|
<link rel="icon" type="image/svg+xml" href="/favicon.svg" />
|
|
14
14
|
<link rel="apple-touch-icon" href="/apple-touch-icon.png" />
|
|
15
|
-
<link rel="stylesheet" href="/styles.css?v=
|
|
15
|
+
<link rel="stylesheet" href="/styles.css?v=152" />
|
|
16
16
|
<script>
|
|
17
17
|
// Public-only issue-bot runtime configuration. Keep disabled unless the gateway,
|
|
18
18
|
// Turnstile site key, exact CORS origin, and private-report destination are approved.
|
|
@@ -297,10 +297,6 @@
|
|
|
297
297
|
<button id="chatSearchCloseButton" class="chat-search-button" type="button" aria-label="Close search" title="Close (Escape)">✕</button>
|
|
298
298
|
</div>
|
|
299
299
|
<div class="main-output-surface">
|
|
300
|
-
<div id="mainOutputLoading" class="main-output-loading" role="status" aria-live="polite" aria-atomic="true" aria-controls="chat" hidden>
|
|
301
|
-
<span class="main-output-loading-spinner" aria-hidden="true"></span>
|
|
302
|
-
<span>Loading agent output…</span>
|
|
303
|
-
</div>
|
|
304
300
|
<div id="chat" class="chat" aria-live="polite" aria-busy="false">
|
|
305
301
|
<button id="stickyUserPromptButton" class="sticky-user-prompt-button" type="button" aria-controls="chat" hidden></button>
|
|
306
302
|
</div>
|
|
@@ -311,7 +307,13 @@
|
|
|
311
307
|
<span id="feedbackTraySummary">No action feedback queued.</span>
|
|
312
308
|
<button id="sendFeedbackButton" type="button">Send & create LEARNING</button>
|
|
313
309
|
</div>
|
|
314
|
-
<div
|
|
310
|
+
<div class="footer-status-host">
|
|
311
|
+
<div id="mainOutputLoading" class="main-output-loading" role="status" aria-live="polite" aria-atomic="true" aria-controls="chat" hidden>
|
|
312
|
+
<span class="main-output-loading-spinner" aria-hidden="true"></span>
|
|
313
|
+
<span id="mainOutputLoadingLabel">Loading conversation history…</span>
|
|
314
|
+
</div>
|
|
315
|
+
<div id="statusBar" class="statusbar" aria-live="polite"></div>
|
|
316
|
+
</div>
|
|
315
317
|
<section id="contextMeterBar" class="context-meter-bar" aria-live="polite"></section>
|
|
316
318
|
<section id="gitWorkflowPanel" class="git-workflow-panel" aria-live="polite" hidden>
|
|
317
319
|
<div class="git-workflow-header">
|
|
@@ -1455,6 +1457,7 @@
|
|
|
1455
1457
|
<h2 id="textPromptTitle">Enter a value</h2>
|
|
1456
1458
|
<p id="textPromptSummary" class="muted"></p>
|
|
1457
1459
|
<input id="textPromptInput" class="dialog-input" type="text" autocomplete="off" spellcheck="false" aria-labelledby="textPromptTitle" />
|
|
1460
|
+
<select id="textPromptSelect" class="dialog-input" aria-labelledby="textPromptTitle" hidden></select>
|
|
1458
1461
|
<p id="textPromptError" class="path-picker-error" hidden></p>
|
|
1459
1462
|
<menu>
|
|
1460
1463
|
<button id="textPromptCancelButton" type="button">Cancel</button>
|
|
@@ -1889,7 +1892,7 @@
|
|
|
1889
1892
|
</form>
|
|
1890
1893
|
</dialog>
|
|
1891
1894
|
|
|
1892
|
-
<script id="webuiBootLoader" data-app-src="/app.js?v=
|
|
1895
|
+
<script id="webuiBootLoader" data-app-src="/app.js?v=182">
|
|
1893
1896
|
(() => {
|
|
1894
1897
|
"use strict";
|
|
1895
1898
|
|
package/public/service-worker.js
CHANGED
package/public/styles.css
CHANGED
|
@@ -4478,6 +4478,36 @@ button.subagent-gate-attempt:focus-visible {
|
|
|
4478
4478
|
background: linear-gradient(90deg, var(--ctp-green), var(--ctp-yellow), var(--ctp-peach));
|
|
4479
4479
|
box-shadow: 0 0 0.85rem rgba(148, 226, 213, 0.20);
|
|
4480
4480
|
}
|
|
4481
|
+
.optional-feature-prompt-impact {
|
|
4482
|
+
display: inline-grid;
|
|
4483
|
+
place-items: center;
|
|
4484
|
+
box-sizing: border-box;
|
|
4485
|
+
flex: 0 0 auto;
|
|
4486
|
+
width: 2.8rem;
|
|
4487
|
+
min-width: 2.8rem;
|
|
4488
|
+
min-height: 1.15rem;
|
|
4489
|
+
padding: 0.08rem 0.2rem;
|
|
4490
|
+
border: 1px solid rgba(180, 190, 254, 0.2);
|
|
4491
|
+
border-radius: 0.42rem;
|
|
4492
|
+
color: var(--ctp-subtext);
|
|
4493
|
+
background: rgba(var(--ctp-surface-rgb), 0.48);
|
|
4494
|
+
font-family: var(--font-mono);
|
|
4495
|
+
font-size: var(--text-xs);
|
|
4496
|
+
font-weight: 900;
|
|
4497
|
+
line-height: 1;
|
|
4498
|
+
}
|
|
4499
|
+
.optional-feature-prompt-impact.initial {
|
|
4500
|
+
color: var(--ctp-peach);
|
|
4501
|
+
border-color: rgba(250, 179, 135, 0.34);
|
|
4502
|
+
}
|
|
4503
|
+
.optional-feature-prompt-impact.conditional {
|
|
4504
|
+
color: var(--ctp-yellow);
|
|
4505
|
+
border-color: rgba(249, 226, 175, 0.34);
|
|
4506
|
+
}
|
|
4507
|
+
.optional-feature-prompt-impact.none {
|
|
4508
|
+
color: var(--ctp-green);
|
|
4509
|
+
border-color: rgba(166, 227, 161, 0.28);
|
|
4510
|
+
}
|
|
4481
4511
|
.optional-feature-row {
|
|
4482
4512
|
position: relative;
|
|
4483
4513
|
display: grid;
|
|
@@ -4578,17 +4608,25 @@ button.subagent-gate-attempt:focus-visible {
|
|
|
4578
4608
|
.optional-feature-title {
|
|
4579
4609
|
display: flex;
|
|
4580
4610
|
flex-direction: column;
|
|
4581
|
-
gap: 0.28rem;
|
|
4582
4611
|
align-items: flex-start;
|
|
4612
|
+
gap: 0.28rem;
|
|
4583
4613
|
min-width: 0;
|
|
4584
4614
|
}
|
|
4585
4615
|
.optional-feature-title strong {
|
|
4586
4616
|
color: rgba(var(--ctp-text-rgb), 0.94);
|
|
4587
4617
|
font-size: 0.82rem;
|
|
4588
4618
|
}
|
|
4619
|
+
.optional-feature-status-tags {
|
|
4620
|
+
display: inline-flex;
|
|
4621
|
+
flex-wrap: wrap;
|
|
4622
|
+
align-items: center;
|
|
4623
|
+
gap: 0.34rem;
|
|
4624
|
+
}
|
|
4589
4625
|
.optional-feature-pill {
|
|
4590
4626
|
display: inline-flex;
|
|
4627
|
+
flex: 0 0 auto;
|
|
4591
4628
|
align-items: center;
|
|
4629
|
+
justify-content: center;
|
|
4592
4630
|
min-height: 1.15rem;
|
|
4593
4631
|
padding: 0.12rem 0.42rem;
|
|
4594
4632
|
border-radius: 999px;
|
|
@@ -5571,7 +5609,7 @@ button.subagent-gate-attempt:focus-visible {
|
|
|
5571
5609
|
body.terminal-tabs-left .main-output-surface,
|
|
5572
5610
|
body.terminal-tabs-left .run-indicator-host,
|
|
5573
5611
|
body.terminal-tabs-left .feedback-tray,
|
|
5574
|
-
body.terminal-tabs-left .
|
|
5612
|
+
body.terminal-tabs-left .footer-status-host,
|
|
5575
5613
|
body.terminal-tabs-left .context-meter-bar,
|
|
5576
5614
|
body.terminal-tabs-left .git-workflow-panel,
|
|
5577
5615
|
body.terminal-tabs-left .composer,
|
|
@@ -5585,10 +5623,9 @@ button.subagent-gate-attempt:focus-visible {
|
|
|
5585
5623
|
body.terminal-tabs-left .subagent-terminal-view { grid-row: 1 / -1; }
|
|
5586
5624
|
body.terminal-tabs-left .chat-search-bar { grid-row: 3; }
|
|
5587
5625
|
body.terminal-tabs-left .main-output-surface { grid-row: 4; }
|
|
5588
|
-
body.terminal-tabs-left .main-output-loading { top: 0.75rem; }
|
|
5589
5626
|
body.terminal-tabs-left .run-indicator-host { grid-row: 5; }
|
|
5590
5627
|
body.terminal-tabs-left .feedback-tray { grid-row: 6; }
|
|
5591
|
-
body.terminal-tabs-left .
|
|
5628
|
+
body.terminal-tabs-left .footer-status-host { grid-row: 7; }
|
|
5592
5629
|
body.terminal-tabs-left .context-meter-bar { grid-row: 8; }
|
|
5593
5630
|
body.terminal-tabs-left .git-workflow-panel { grid-row: 9; }
|
|
5594
5631
|
body.terminal-tabs-left .composer,
|
|
@@ -5622,7 +5659,7 @@ button.subagent-gate-attempt:focus-visible {
|
|
|
5622
5659
|
body.terminal-tabs-left.terminal-tabs-sidebar-start .main-output-surface,
|
|
5623
5660
|
body.terminal-tabs-left.terminal-tabs-sidebar-start .run-indicator-host,
|
|
5624
5661
|
body.terminal-tabs-left.terminal-tabs-sidebar-start .feedback-tray,
|
|
5625
|
-
body.terminal-tabs-left.terminal-tabs-sidebar-start .
|
|
5662
|
+
body.terminal-tabs-left.terminal-tabs-sidebar-start .footer-status-host,
|
|
5626
5663
|
body.terminal-tabs-left.terminal-tabs-sidebar-start .context-meter-bar,
|
|
5627
5664
|
body.terminal-tabs-left.terminal-tabs-sidebar-start .git-workflow-panel,
|
|
5628
5665
|
body.terminal-tabs-left.terminal-tabs-sidebar-start .composer,
|
|
@@ -8308,16 +8345,22 @@ button.git-workflow-step:hover:not(:disabled) {
|
|
|
8308
8345
|
padding: 1rem;
|
|
8309
8346
|
scroll-behavior: smooth;
|
|
8310
8347
|
}
|
|
8348
|
+
.footer-status-host {
|
|
8349
|
+
position: relative;
|
|
8350
|
+
flex: 0 0 auto;
|
|
8351
|
+
min-width: 0;
|
|
8352
|
+
}
|
|
8311
8353
|
.main-output-loading[hidden] { display: none !important; }
|
|
8312
8354
|
.main-output-loading {
|
|
8313
8355
|
position: absolute;
|
|
8314
8356
|
z-index: 13;
|
|
8315
|
-
top: 0.55rem;
|
|
8316
8357
|
left: 50%;
|
|
8358
|
+
bottom: calc(100% + 0.3rem);
|
|
8317
8359
|
display: inline-flex;
|
|
8318
8360
|
align-items: center;
|
|
8319
8361
|
gap: 0.48rem;
|
|
8320
|
-
|
|
8362
|
+
width: max-content;
|
|
8363
|
+
max-width: calc(100% - 2rem);
|
|
8321
8364
|
margin: 0;
|
|
8322
8365
|
transform: translateX(-50%);
|
|
8323
8366
|
padding: 0.42rem 0.7rem;
|
|
@@ -13075,6 +13118,7 @@ body:not(.mobile-keyboard-open) .composer-input-row:has(.composer-workflow-mode-
|
|
|
13075
13118
|
body.subagent-terminal-active .workspace-dashboard,
|
|
13076
13119
|
body.subagent-terminal-active .widget-area,
|
|
13077
13120
|
body.subagent-terminal-active .main-output-surface,
|
|
13121
|
+
body.subagent-terminal-active .main-output-loading,
|
|
13078
13122
|
body.subagent-terminal-active .feedback-tray,
|
|
13079
13123
|
body.subagent-terminal-active .jump-to-latest-button,
|
|
13080
13124
|
body.subagent-terminal-active .statusbar,
|
|
@@ -65,7 +65,7 @@ function makeEnvironment({
|
|
|
65
65
|
reload: new FakeElement(),
|
|
66
66
|
copyStatus: new FakeElement(),
|
|
67
67
|
};
|
|
68
|
-
const styleLink = new FakeElement({ href: "http://127.0.0.1:31415/styles.css?v=
|
|
68
|
+
const styleLink = new FakeElement({ href: "http://127.0.0.1:31415/styles.css?v=152", sheet: stylesheetLoaded ? {} : null });
|
|
69
69
|
const listeners = new Map();
|
|
70
70
|
const timers = new Map();
|
|
71
71
|
let timerId = 0;
|
|
@@ -84,7 +84,7 @@ function makeEnvironment({
|
|
|
84
84
|
removeEventListener(name) { listeners.delete(name); },
|
|
85
85
|
};
|
|
86
86
|
const document = {
|
|
87
|
-
currentScript: new FakeElement({ dataset: { appSrc: "/app.js?v=
|
|
87
|
+
currentScript: new FakeElement({ dataset: { appSrc: "/app.js?v=182" } }),
|
|
88
88
|
readyState: "complete",
|
|
89
89
|
querySelector(selector) {
|
|
90
90
|
return {
|
|
@@ -232,7 +232,7 @@ for (const moduleName of startupModuleNames) {
|
|
|
232
232
|
assert.ok(serviceWorker.includes(`"/${moduleName}"`), `the PWA app shell should include every app.js startup module: ${moduleName}`);
|
|
233
233
|
}
|
|
234
234
|
assert.match(serviceWorker, /pi-webui-pwa-v\d+/, "the app-shell cache should retain a versioned identity");
|
|
235
|
-
assert.ok(html.indexOf('id="webuiBootLoader"') < html.indexOf("/app.js?v=
|
|
235
|
+
assert.ok(html.indexOf('id="webuiBootLoader"') < html.indexOf("/app.js?v=182"), "the inline loader should own app module startup");
|
|
236
236
|
assert.doesNotMatch(html, /<script type="module" src="\/app\.js/, "the app module should not bypass the guarded loader");
|
|
237
237
|
|
|
238
238
|
console.log("boot-failure-diagnostics.test.mjs passed");
|
|
@@ -229,19 +229,25 @@ test("main output shows non-blocking inline feedback while transcript data loads
|
|
|
229
229
|
const loading = page.locator("#mainOutputLoading");
|
|
230
230
|
const chat = page.locator("#chat");
|
|
231
231
|
await expect(loading).toBeVisible();
|
|
232
|
-
await expect(loading).toContainText("Loading
|
|
232
|
+
await expect(loading).toContainText("Loading conversation history…");
|
|
233
233
|
await expect(loading).toHaveCSS("pointer-events", "none");
|
|
234
234
|
await expect(chat).toHaveAttribute("aria-busy", "true");
|
|
235
235
|
await expect(page.locator("#promptInput")).toBeEnabled();
|
|
236
236
|
assert.equal(await page.evaluate(() => document.querySelectorAll("dialog:modal").length), 0, "loading feedback should not open a popup");
|
|
237
237
|
const loadingChatBounds = await chat.boundingBox();
|
|
238
|
-
|
|
238
|
+
const loadingBounds = await loading.boundingBox();
|
|
239
|
+
const footerBounds = await page.locator("#statusBar").boundingBox();
|
|
240
|
+
assert.ok(loadingChatBounds && loadingBounds && footerBounds, "the transcript, loading status, and footer should have measurable bounds");
|
|
241
|
+
assert.ok(loadingBounds.y + loadingBounds.height <= footerBounds.y, "the loading status should sit above the Git footer status");
|
|
239
242
|
|
|
240
243
|
releaseMessages();
|
|
241
244
|
await expect(loading).toBeHidden();
|
|
242
245
|
await expect(chat).toHaveAttribute("aria-busy", "false");
|
|
243
246
|
const settledChatBounds = await chat.boundingBox();
|
|
244
|
-
assert.
|
|
247
|
+
assert.ok(settledChatBounds, "the settled transcript should have measurable bounds");
|
|
248
|
+
assert.equal(settledChatBounds.x, loadingChatBounds.x, "the loading row should not move the transcript horizontally");
|
|
249
|
+
assert.equal(settledChatBounds.width, loadingChatBounds.width, "the loading row should not resize the transcript horizontally");
|
|
250
|
+
assert.equal(settledChatBounds.height, loadingChatBounds.height, "the loading overlay should not resize the transcript");
|
|
245
251
|
} finally {
|
|
246
252
|
releaseMessages?.();
|
|
247
253
|
await page.unroute(messagesPattern);
|
|
@@ -55,7 +55,7 @@ assert.match(app, /statusKey === CODEX_FAST_MODE_STATUS_KEY[\s\S]*?applyCodexFas
|
|
|
55
55
|
assert.match(technical, /## Normal and compact output[\s\S]*?select \*\*Compact\*\*[\s\S]*?`compact-v1`/, "technical reference should document Compact mode with the stable identifier");
|
|
56
56
|
assert.match(development, /### Codex subscription Fast mode[\s\S]*?service_tier: "priority"[\s\S]*?1\.5× faster[\s\S]*?2× Standard credits[\s\S]*?2\.5×/, "development guide should document Fast-mode integration and cost semantics");
|
|
57
57
|
// Intent preserved: browser-asset changes must advance the coherent cache tuple.
|
|
58
|
-
assert.match(serviceWorker, /pi-webui-pwa-
|
|
59
|
-
assert.match(html, /data-app-src="\/app\.js\?v=
|
|
58
|
+
assert.match(serviceWorker, /pi-webui-pwa-v153/, "PWA cache identity should be bumped for changed browser assets");
|
|
59
|
+
assert.match(html, /data-app-src="\/app\.js\?v=182"/, "browser module URL should be cache-busted for Fast-mode wiring");
|
|
60
60
|
|
|
61
61
|
console.log("codex-fast-mode-static.test.mjs passed");
|
|
@@ -57,8 +57,8 @@ assert.match(app, /function initializeComposerActionOrdering\(\)[\s\S]*MutationO
|
|
|
57
57
|
assert.match(app, /event\.key === COMPOSER_ACTION_ORDER_STORAGE_KEY\) restoreComposerActionOrder\(\)[\s\S]*event\.key === COMPOSER_ACTION_LAYOUT_STORAGE_KEY\) restoreComposerActionSlotLayout\(\)/, "other tabs should apply persisted composer order and sparse-layout changes");
|
|
58
58
|
assert.match(app, /initializeComposerActionOrdering\(\);[\s\S]*restoreSidePanelSectionOrder\(\);/, "composer ordering should initialize during guarded app startup");
|
|
59
59
|
|
|
60
|
-
assert.match(html, /styles\.css\?v=
|
|
61
|
-
assert.match(html, /app\.js\?v=
|
|
62
|
-
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-
|
|
60
|
+
assert.match(html, /styles\.css\?v=152/, "changed composer styles should advance the stylesheet revision");
|
|
61
|
+
assert.match(html, /app\.js\?v=182/, "changed composer behavior should advance the app revision");
|
|
62
|
+
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-v153"/, "changed browser assets should advance the PWA cache identity");
|
|
63
63
|
|
|
64
64
|
console.log("composer-action-grid-reorder-static.test.mjs passed");
|
|
@@ -348,10 +348,10 @@ assert.match(
|
|
|
348
348
|
|
|
349
349
|
assert.match(
|
|
350
350
|
serviceWorker,
|
|
351
|
-
/const CACHE_NAME = "pi-webui-pwa-
|
|
351
|
+
/const CACHE_NAME = "pi-webui-pwa-v153";/,
|
|
352
352
|
"browser asset changes should advance the PWA cache identity",
|
|
353
353
|
);
|
|
354
|
-
assert.match(html, /styles\.css\?v=
|
|
355
|
-
assert.match(html, /data-app-src="\/app\.js\?v=
|
|
354
|
+
assert.match(html, /styles\.css\?v=152/, "visibility styles should advance the stylesheet query revision");
|
|
355
|
+
assert.match(html, /data-app-src="\/app\.js\?v=182"/, "visibility behavior should advance the app query revision");
|
|
356
356
|
|
|
357
357
|
console.log("control-visibility-static.test.mjs passed");
|
|
@@ -15,8 +15,8 @@ assert.equal((html.match(/class="control-row-label"[^>]*data-tooltip=/g) || []).
|
|
|
15
15
|
assert.match(app, /function initializeControlSettingTooltips\(\)[\s\S]*#sidePanelSectionControls \.control-row-label\[data-tooltip\][\s\S]*bindStyledTooltipEvents\(label\)[\s\S]*showFooterTooltip\(label\)/, "Controls help should use the viewport-safe floating tooltip for hover and keyboard access");
|
|
16
16
|
assert.match(html, /class="control-row remote-auth-control-row" hidden[\s\S]*id="remoteAuthToggle"/, "optional PIN protection should retain its guarded visibility");
|
|
17
17
|
assert.match(app, /remoteAuthToggle\?\.closest\("\.remote-auth-control-row"\)[\s\S]*remoteAuthRow\.hidden = false/, "loading remote status should reveal the optional PIN protection setting");
|
|
18
|
-
assert.match(html, /styles\.css\?v=
|
|
19
|
-
assert.match(html, /app\.js\?v=
|
|
20
|
-
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-
|
|
18
|
+
assert.match(html, /styles\.css\?v=152/, "Controls stylesheet changes should advance the cache query");
|
|
19
|
+
assert.match(html, /app\.js\?v=182/, "Controls tooltip wiring should advance the app cache query");
|
|
20
|
+
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-v153"/, "Controls browser assets should advance the PWA cache identity");
|
|
21
21
|
|
|
22
22
|
console.log("controls-layout-static.test.mjs passed");
|
|
@@ -124,8 +124,8 @@ assert.match(styles, /\.event-log\[data-display-mode="compact"\] \.event\[data-e
|
|
|
124
124
|
assert.match(styles, /\.event-tree-context-menu \{[\s\S]*max-width: calc\(100vw - 1rem\)/, "the dedicated menu should remain viewport bounded");
|
|
125
125
|
|
|
126
126
|
// Cache tuple for this browser-asset change.
|
|
127
|
-
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-
|
|
128
|
-
assert.match(html, /styles\.css\?v=
|
|
129
|
-
assert.match(html, /data-app-src="\/app\.js\?v=
|
|
127
|
+
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-v153";/, "the PWA cache identity should advance");
|
|
128
|
+
assert.match(html, /styles\.css\?v=152/, "compact-mode styles should advance the stylesheet revision");
|
|
129
|
+
assert.match(html, /data-app-src="\/app\.js\?v=182"/, "the app query revision should advance");
|
|
130
130
|
|
|
131
131
|
console.log("events-tree-context-menu-static.test.mjs passed");
|
|
@@ -159,7 +159,7 @@ assert.match(worker, /pi-webui-pwa-v\d+[\s\S]*?"\/fast-output-live\.mjs"/, "PWA
|
|
|
159
159
|
assert.match(html, /<label for="fastOutputModeSelect">Compact mode \(Experimental\)<\/label>/, "the sidebar should mark compact mode as experimental");
|
|
160
160
|
assert.match(html, /Lightweight browser rendering; Markdown final output; live thinking expanded; stored thinking grouped and collapsed/, "the sidebar should distinguish compact rendering from model inference");
|
|
161
161
|
// Intent preserved: the guarded PWA entry point must advance whenever app wiring changes.
|
|
162
|
-
assert.match(html, /id="webuiBootLoader"[^>]*data-app-src="\/app\.js\?v=
|
|
162
|
+
assert.match(html, /id="webuiBootLoader"[^>]*data-app-src="\/app\.js\?v=182"/, "the guarded PWA entry point should cache-bust browser wiring");
|
|
163
163
|
assert.match(JSON.parse(packageRaw).scripts.check, /node --check public\/fast-output-live\.mjs/, "package checks should parse the compact helper");
|
|
164
164
|
|
|
165
165
|
const events = createFastModeOutputEvents();
|
|
@@ -166,7 +166,7 @@ assert.match(functionSource("closeTerminalTabs"), /clearFeatureDecisionStateForT
|
|
|
166
166
|
assert.match(app, /case "webui_connected":[\s\S]*clearFeatureDecisionStateForTab\(connectedTabId, \{ render: true \}\)[\s\S]*scheduleForegroundReconcile\("event stream reconnect", 0\)/, "reconnect should clear local state before authoritative replay");
|
|
167
167
|
assert.match(app, /statusKey === FEATURE_DECISION_OUTPUT_STATUS_KEY[\s\S]*handleFeatureDecisionOutputStatus[\s\S]*return;[\s\S]*statusKey === FEATURE_CATEGORY_STATUS_KEY[\s\S]*return;[\s\S]*statusEntries\.set/, "both feature statuses should be intercepted before generic footer storage while preserving category handling");
|
|
168
168
|
|
|
169
|
-
assert.match(html, /\/styles\.css\?v=
|
|
170
|
-
assert.match(html, /\/app\.js\?v=
|
|
169
|
+
assert.match(html, /\/styles\.css\?v=152/, "integrated stylesheet changes should advance the cache query");
|
|
170
|
+
assert.match(html, /\/app\.js\?v=182/, "integrated app changes should advance the cache query");
|
|
171
171
|
|
|
172
172
|
console.log("feature decision-output popup static checks passed");
|
|
@@ -62,8 +62,8 @@ assert.match(css, /\.file-viewer-image img \{[\s\S]*max-width: 100%;[\s\S]*max-h
|
|
|
62
62
|
assert.match(readme, /PNG, JPEG, GIF, WebP, and AVIF/i, "the Files panel guide should list supported image formats");
|
|
63
63
|
assert.match(technical, /supported raster images[\s\S]*2 MiB/i, "the advanced reference should document image support and its size limit");
|
|
64
64
|
assert.match(development, /kind: "image"[\s\S]*base64/i, "the contributor guide should document the image response contract");
|
|
65
|
-
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-
|
|
66
|
-
assert.match(html, /styles\.css\?v=
|
|
67
|
-
assert.match(html, /app\.js\?v=
|
|
65
|
+
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-v153"/, "changed viewer assets should advance the PWA cache identity");
|
|
66
|
+
assert.match(html, /styles\.css\?v=152/, "changed image styles should advance the stylesheet revision");
|
|
67
|
+
assert.match(html, /app\.js\?v=182/, "changed image rendering should advance the app revision");
|
|
68
68
|
|
|
69
69
|
console.log("file viewer image static tests passed");
|
|
@@ -82,9 +82,9 @@ test("server dispatch requires extension provenance and completes on a fresh nat
|
|
|
82
82
|
test("fixture, cache revisions, and layered docs expose the migration contract", () => {
|
|
83
83
|
assert.match(fakePi, /FAKE_PI_GUIDED_GIT_ACTIVATION/u);
|
|
84
84
|
assert.match(fakePi, /git-guided-workflow:webui-start/u);
|
|
85
|
-
assert.match(html, /styles\.css\?v=
|
|
86
|
-
assert.match(html, /app\.js\?v=
|
|
87
|
-
assert.match(serviceWorker, /pi-webui-pwa-
|
|
85
|
+
assert.match(html, /styles\.css\?v=152/u);
|
|
86
|
+
assert.match(html, /app\.js\?v=182/u);
|
|
87
|
+
assert.match(serviceWorker, /pi-webui-pwa-v153/u);
|
|
88
88
|
assert.match(serviceWorker, /"\/guided-git-command-state\.mjs"/u);
|
|
89
89
|
assert.match(readme, /pi-extension-git-guided-workflow/u);
|
|
90
90
|
assert.match(technical, /\/git-guided-workflow/u);
|
|
@@ -54,7 +54,7 @@ assert.match(readme, /fallback model and its own reasoning effort[\s\S]*tries th
|
|
|
54
54
|
assert.match(technical, /## Guided Git generation profiles[\s\S]*strict one-retry policy[\s\S]*model and reasoning effort are restored[\s\S]*dead Pi process cannot run the fallback/i, "technical reference should document configuration and operational limits");
|
|
55
55
|
assert.match(development, /### Fallback browser\/runtime contract[\s\S]*fallbackUsed: true[\s\S]*webui_git_workflow_generation_fallback_started[\s\S]*never sends a retry/, "development guide should preserve the response/event and browser ownership contract");
|
|
56
56
|
|
|
57
|
-
assert.match(html, /data-app-src="\/app\.js\?v=
|
|
58
|
-
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-
|
|
57
|
+
assert.match(html, /data-app-src="\/app\.js\?v=182"/, "the changed browser app should use the next query revision");
|
|
58
|
+
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-v153";/, "the PWA cache identity should advance with browser behavior");
|
|
59
59
|
|
|
60
60
|
console.log("guided-git-fallback-ui-static.test.mjs passed");
|
|
@@ -20,13 +20,18 @@ assert.match(
|
|
|
20
20
|
);
|
|
21
21
|
assert.match(
|
|
22
22
|
server,
|
|
23
|
-
/case "\/api\/git-workflow\/publish": \{[\s\S]*cleanGitHubRepoName\(
|
|
24
|
-
"the server must validate name
|
|
23
|
+
/case "\/api\/git-workflow\/publish": \{[\s\S]*const root = await getGitRoot\(cwd\);[\s\S]*cleanGitHubRepoName\(path\.basename\(root\)\)[\s\S]*visibility !== "public" && visibility !== "private"[\s\S]*requireConfirmed\(body,[\s\S]*gitRemoteNames\(root\)[\s\S]*remotes\.length[\s\S]*currentGitBranch\(root\)/,
|
|
24
|
+
"the server must derive and validate the Git root directory name, validate visibility/confirmation, and refuse existing-remote repair before publication",
|
|
25
|
+
);
|
|
26
|
+
assert.doesNotMatch(
|
|
27
|
+
server,
|
|
28
|
+
/case "\/api\/git-workflow\/publish": \{[\s\S]*?cleanGitHubRepoName\(body\.repoName\)[\s\S]*?case "\/api\/git-workflow\/create-pr"/,
|
|
29
|
+
"publication must not trust a client-selected repository name",
|
|
25
30
|
);
|
|
26
31
|
assert.match(
|
|
27
32
|
server,
|
|
28
|
-
/runGitHubWorkflowCommand\(\s*\["repo", "create", repoName, `--\$\{visibility\}`, "--source",
|
|
29
|
-
"publication must run the
|
|
33
|
+
/runGitHubWorkflowCommand\(\s*\["repo", "create", repoName, `--\$\{visibility\}`, "--source", "\.", "--remote", "origin", "--push"\],[\s\S]*\{ cwd: root, timeoutMs: 15 \* 60 \* 1000/,
|
|
34
|
+
"publication must run gh repo create from the Git root so system GitHub CLI configuration adds origin and pushes",
|
|
30
35
|
);
|
|
31
36
|
assert.match(
|
|
32
37
|
server,
|
|
@@ -34,7 +39,7 @@ assert.match(
|
|
|
34
39
|
"successful publication must extend the process envelope with the approved metadata",
|
|
35
40
|
);
|
|
36
41
|
assert.match(server, /payload\.code = "AUTH";[\s\S]*gh auth login/, "gh authentication failures should receive an actionable AUTH hint");
|
|
37
|
-
assert.match(server, /name already exists on this account\|repository \.\+ already exists[\s\S]*
|
|
42
|
+
assert.match(server, /name already exists on this account\|repository \.\+ already exists[\s\S]*rename the local directory before retrying/, "name conflicts should explain how the directory-derived name can be changed");
|
|
38
43
|
assert.match(server, /GH_PROMPT_DISABLED: process\.env\.GH_PROMPT_DISABLED \|\| "1"/, "gh publication must inherit disabled interactive prompts");
|
|
39
44
|
|
|
40
45
|
console.log("guided git publication backend static tests passed");
|
|
@@ -1995,28 +1995,24 @@ try {
|
|
|
1995
1995
|
assert.equal(pushWithoutRemote.body?.code, "NO_REMOTE", "remote-less push should have a stable recovery code");
|
|
1996
1996
|
assert.match(String(pushWithoutRemote.body?.hint || ""), /publish this repository|add a Git remote/i);
|
|
1997
1997
|
assert.match(String(pushWithoutRemote.body?.data?.stderr || ""), /No configured push destination/i, "classified failures should preserve process output");
|
|
1998
|
+
assert.equal(pushWithoutRemote.body?.data?.repoName, path.basename(cwd), "remote-less push should report the local Git root directory name for publication");
|
|
1998
1999
|
|
|
1999
2000
|
const unconfirmedPublish = await request("127.0.0.1", "/api/git-workflow/publish", {
|
|
2000
2001
|
method: "POST",
|
|
2001
|
-
body: { tab: tabId, repoName: "
|
|
2002
|
+
body: { tab: tabId, repoName: "client-selected-name", visibility: "private" },
|
|
2002
2003
|
});
|
|
2003
2004
|
assert.equal(unconfirmedPublish.status, 200);
|
|
2004
2005
|
assert.equal(unconfirmedPublish.body?.ok, false, "publication should require exact server-side confirmation");
|
|
2005
2006
|
assert.match(String(unconfirmedPublish.body?.error || ""), /confirmed: true/);
|
|
2007
|
+
assert.match(String(unconfirmedPublish.body?.error || ""), new RegExp(`GitHub repository ${path.basename(cwd)} as private`), "publication confirmation should use the server-derived Git root directory name");
|
|
2008
|
+
assert.doesNotMatch(String(unconfirmedPublish.body?.error || ""), /client-selected-name/, "publication should ignore client-supplied repository names");
|
|
2006
2009
|
|
|
2007
2010
|
const invalidVisibilityPublish = await request("127.0.0.1", "/api/git-workflow/publish", {
|
|
2008
2011
|
method: "POST",
|
|
2009
|
-
body: { tab: tabId,
|
|
2012
|
+
body: { tab: tabId, visibility: "internal", confirmed: true },
|
|
2010
2013
|
});
|
|
2011
2014
|
assert.equal(invalidVisibilityPublish.body?.ok, false, "publication should reject visibility outside public/private");
|
|
2012
2015
|
assert.match(String(invalidVisibilityPublish.body?.error || ""), /visibility must be 'public' or 'private'/);
|
|
2013
|
-
|
|
2014
|
-
const invalidNamePublish = await request("127.0.0.1", "/api/git-workflow/publish", {
|
|
2015
|
-
method: "POST",
|
|
2016
|
-
body: { tab: tabId, repoName: "invalid repository name", visibility: "public", confirmed: true },
|
|
2017
|
-
});
|
|
2018
|
-
assert.equal(invalidNamePublish.body?.ok, false, "publication should reuse GitHub repository-name validation");
|
|
2019
|
-
assert.match(String(invalidNamePublish.body?.error || ""), /Invalid GitHub repository name/);
|
|
2020
2016
|
assert.equal(runGitFixture(["remote"], cwd, "guarded publication requests must not configure a remote"), "");
|
|
2021
2017
|
|
|
2022
2018
|
const initialWorktrees = await request("127.0.0.1", `/api/git-worktrees?tab=${encodeURIComponent(tabId)}`);
|
|
@@ -96,9 +96,9 @@ assert.match(css, /\.composer-intercom-tag:hover,[\s\S]*\.composer-intercom-tag:
|
|
|
96
96
|
assert.match(css, /\.extension-dialog\.intercom-conversation-dialog \{[\s\S]*width: min\(76rem,[\s\S]*height: min\(54rem,/, "the viewer should use a large in-app modal");
|
|
97
97
|
assert.match(css, /@media \(max-width: 720px\)[\s\S]*\.composer-intercom-tag \{ min-height: 44px;[\s\S]*\.extension-dialog\.intercom-conversation-dialog[\s\S]*width: calc\(100vw - 0\.7rem\)/, "tags and the dialog should remain reachable on narrow and coarse-pointer layouts");
|
|
98
98
|
|
|
99
|
-
assert.match(html, /\/styles\.css\?v=
|
|
100
|
-
assert.match(html, /data-app-src="\/app\.js\?v=
|
|
101
|
-
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-
|
|
99
|
+
assert.match(html, /\/styles\.css\?v=152/, "the stylesheet URL should advance for the bounded conversation tags");
|
|
100
|
+
assert.match(html, /data-app-src="\/app\.js\?v=182"/, "the guarded app URL should advance for current browser wiring");
|
|
101
|
+
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-v153"/, "the PWA cache identity should advance with browser assets");
|
|
102
102
|
|
|
103
103
|
assert.match(readme, /one compact tag per conversation appears beneath the composer/i, "the README should explain the user-visible entry point");
|
|
104
104
|
assert.match(technical, /## Agent conversation viewer[\s\S]*Attachments, tool calls and results, thinking, stdout\/stderr, filesystem paths, raw session records/i, "the advanced guide should document privacy exclusions");
|
|
@@ -22,40 +22,46 @@ function sourceBetween(startMarker, endMarker, label) {
|
|
|
22
22
|
|
|
23
23
|
assert.match(
|
|
24
24
|
html,
|
|
25
|
-
/class="
|
|
26
|
-
"the
|
|
25
|
+
/id="feedbackTray"[\s\S]*?<div class="footer-status-host">[\s\S]*?<div id="mainOutputLoading" class="main-output-loading" role="status" aria-live="polite" aria-atomic="true" aria-controls="chat" hidden>[\s\S]*?main-output-loading-spinner[\s\S]*?id="mainOutputLoadingLabel">Loading conversation history…<\/span>[\s\S]*?<div id="statusBar" class="statusbar"/,
|
|
26
|
+
"the accessible loading status and Git footer should share an overlay host",
|
|
27
27
|
);
|
|
28
28
|
assert.doesNotMatch(html, /<dialog[^>]+id="mainOutputLoading"/, "loading feedback must not use a popup dialog");
|
|
29
|
-
assert.match(app, /mainOutputLoading: \$\("#mainOutputLoading"\)/, "the browser should bind the inline status
|
|
29
|
+
assert.match(app, /mainOutputLoading: \$\("#mainOutputLoading"\)[\s\S]*mainOutputLoadingLabel: \$\("#mainOutputLoadingLabel"\)/, "the browser should bind the inline status and its detail label");
|
|
30
30
|
assert.match(app, /const mainOutputLoadingRequests = new Set\(\);[\s\S]*MAIN_OUTPUT_LOADING_REVEAL_DELAY_MS = 120/, "loading requests should have bounded concurrent ownership and a short anti-flicker delay");
|
|
31
31
|
|
|
32
32
|
const loadingHelpers = sourceBetween("function mainOutputLoadingRequestIsCurrent(", "\nasync function refreshMessages(", "main output loading helpers");
|
|
33
33
|
assert.match(loadingHelpers, /isCurrentTabContext\(request\.tabContext\)/, "only the active tab generation should control visible loading feedback");
|
|
34
|
+
assert.match(loadingHelpers, /filter\(mainOutputLoadingRequestIsCurrent\)\.at\(-1\)/, "the newest active request should supply the displayed operation");
|
|
34
35
|
assert.match(loadingHelpers, /setAttribute\("aria-busy", active \? "true" : "false"\)/, "the transcript should expose request state immediately to assistive technology");
|
|
36
|
+
assert.match(loadingHelpers, /mainOutputLoadingLabel\.textContent = request\?\.label/, "the live status should name the current operation");
|
|
35
37
|
assert.match(loadingHelpers, /setTimeout\([\s\S]*MAIN_OUTPUT_LOADING_REVEAL_DELAY_MS/, "visible animation should be delayed to avoid flashing on fast requests");
|
|
36
38
|
assert.match(loadingHelpers, /mainOutputLoadingRequests\.add\(request\)/, "overlapping requests should receive independent tokens");
|
|
39
|
+
assert.match(loadingHelpers, /function updateMainOutputLoading\([\s\S]*request\.label = label/, "an active request should be able to report its next stage");
|
|
37
40
|
assert.match(loadingHelpers, /mainOutputLoadingRequests\.delete\(request\)/, "settled requests should release only their own token");
|
|
38
41
|
assert.doesNotMatch(loadingHelpers, /showModal|alert\(|confirm\(/, "main output loading must remain non-modal");
|
|
39
42
|
|
|
40
43
|
const refreshMessages = sourceBetween("async function refreshMessages(", "\nasync function refreshModels(", "refreshMessages");
|
|
41
|
-
assert.match(refreshMessages, /
|
|
44
|
+
assert.match(refreshMessages, /beginMainOutputLoading\(tabContext, loadDelta \? "Checking for new messages…" : "Loading conversation history…"\)/, "message fetches should distinguish delta checks from complete transcript loads");
|
|
45
|
+
assert.match(refreshMessages, /updateMainOutputLoading\(loadingRequest, "Loading conversation history…"\)[\s\S]*api\("\/api\/messages"/, "delta fallback should report that it is loading the complete transcript");
|
|
46
|
+
assert.match(refreshMessages, /updateMainOutputLoading\(loadingRequest, "Preparing your conversation…"\)[\s\S]*renderMessages\(latestMessages\)/, "the status should report transcript rendering after data arrives");
|
|
42
47
|
assert.match(refreshMessages, /finally \{\s*finishMainOutputLoading\(loadingRequest\);\s*\}/, "success, failure, and stale responses should all clear their request token");
|
|
43
48
|
assert.match(app, /activeTabId = nextTabId;\s*renderMainOutputLoading\(\);/, "tab changes should immediately reconcile stale and current request visibility");
|
|
44
49
|
|
|
45
50
|
assert.match(css, /\.main-output-loading\[hidden\] \{ display: none !important; \}/, "hidden loading feedback should not render");
|
|
46
|
-
assert.match(css, /\.main-output-surface \{[\s\S]*?position: relative;[\s\S]*?flex: 1 1 auto;[\s\S]*?min-height: 0;/, "the transcript
|
|
47
|
-
assert.match(css, /\.
|
|
51
|
+
assert.match(css, /\.main-output-surface \{[\s\S]*?position: relative;[\s\S]*?flex: 1 1 auto;[\s\S]*?min-height: 0;/, "the transcript should retain its flexible layout surface");
|
|
52
|
+
assert.match(css, /\.footer-status-host \{[\s\S]*?position: relative;[\s\S]*?flex: 0 0 auto;[\s\S]*?min-width: 0;/, "the Git footer should provide a stable positioning host");
|
|
53
|
+
assert.match(css, /\.main-output-loading \{[\s\S]*?position: absolute;[\s\S]*?left: 50%;[\s\S]*?bottom: calc\(100% \+ 0\.3rem\);[\s\S]*?transform: translateX\(-50%\);[\s\S]*?pointer-events: none;/, "the loading status should overlay above the footer without entering layout flow");
|
|
48
54
|
assert.match(css, /\.main-output-loading \{[\s\S]*?font-size: var\(--text-xs\)/, "the loading status should remain compact");
|
|
49
55
|
assert.match(css, /\.main-output-loading-spinner \{[\s\S]*?animation: main-output-loading-spin 780ms linear infinite/, "the status should include a visible spinner animation");
|
|
50
56
|
assert.match(css, /@keyframes main-output-loading-spin/, "the spinner should have a local animation contract");
|
|
51
57
|
assert.match(css, /@media \(prefers-reduced-motion: reduce\)[\s\S]*?animation-duration: 1ms !important;[\s\S]*?animation-iteration-count: 1 !important;/, "the existing reduced-motion policy should stop repeated spinner motion");
|
|
52
|
-
assert.match(css, /body\.terminal-tabs-left \.main-output-surface \{ grid-row: 4; \}/, "sidebar tab placement should keep the
|
|
53
|
-
assert.match(css, /body\.subagent-terminal-active \.main-output-surface,/, "
|
|
58
|
+
assert.match(css, /body\.terminal-tabs-left \.main-output-surface \{ grid-row: 4; \}[\s\S]*body\.terminal-tabs-left \.footer-status-host \{ grid-row: 7; \}[\s\S]*body\.terminal-tabs-left \.context-meter-bar \{ grid-row: 8; \}/, "sidebar tab placement should keep the loading overlay anchored to the footer host");
|
|
59
|
+
assert.match(css, /body\.subagent-terminal-active \.main-output-surface,[\s\S]*body\.subagent-terminal-active \.main-output-loading,/, "dedicated subagent output should hide the main transcript and its loading status");
|
|
54
60
|
|
|
55
|
-
assert.match(html, /styles\.css\?v=
|
|
56
|
-
assert.match(html, /app\.js\?v=
|
|
57
|
-
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-
|
|
58
|
-
assert.match(readme, /Loading
|
|
61
|
+
assert.match(html, /styles\.css\?v=152/, "the stylesheet cache query should advance");
|
|
62
|
+
assert.match(html, /app\.js\?v=182/, "the app cache query should advance");
|
|
63
|
+
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-v153"/, "the PWA cache identity should advance with browser assets");
|
|
64
|
+
assert.match(readme, /Loading conversation history/, "user documentation should describe the plain-language loading feedback");
|
|
59
65
|
assert.match(development, /main output loading/i, "developer documentation should preserve the request-ownership contract");
|
|
60
66
|
|
|
61
67
|
console.log("main output loading static tests passed");
|
|
@@ -16,9 +16,9 @@ assert.match(app, /import \{ installMiddleButtonDragScroll \} from "\.\/middle-b
|
|
|
16
16
|
assert.match(app, /installMiddleButtonDragScroll\(\{[\s\S]*onDirection: \(\{ target, offsetY \}\)[\s\S]*noteChatUserScrollIntent\(\{ type: "middle-drag", deltaY: offsetY \}\)/, "chat auto-scroll direction should feed the existing follow/pause intent state");
|
|
17
17
|
assert.match(app, /event\?\.type === "middle-drag"\) return event\.deltaY > 0;/, "moving below the press point should be recognized as intent to read later chat output");
|
|
18
18
|
assert.match(css, /body\.middle-button-auto-scrolling,[\s\S]*cursor: all-scroll !important;[\s\S]*user-select: none !important;/, "active automatic scrolling should expose a directional-scroll affordance and suppress accidental selection");
|
|
19
|
-
assert.match(html, /styles\.css\?v=
|
|
20
|
-
assert.match(html, /app\.js\?v=
|
|
21
|
-
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-
|
|
19
|
+
assert.match(html, /styles\.css\?v=152/, "changed drag-scroll styles should advance the stylesheet revision");
|
|
20
|
+
assert.match(html, /app\.js\?v=182/, "changed drag-scroll wiring should advance the app revision");
|
|
21
|
+
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-v153";[\s\S]*"\/middle-button-drag-scroll\.mjs"/, "offline PWA installs should refresh and cache the new controller module");
|
|
22
22
|
assert.match(JSON.parse(packageJson).scripts.check, /node --check public\/middle-button-drag-scroll\.mjs/, "the package check should parse the startup-critical controller module");
|
|
23
23
|
|
|
24
24
|
console.log("middle-button-drag-scroll-static.test.mjs passed");
|
|
@@ -47,9 +47,9 @@ assert.match(css, /html\[data-tablet-shell="v2"\] \.mobile-shell-nav[\s\S]*?widt
|
|
|
47
47
|
assert.match(css, /html\[data-tablet-shell="v2"\] \.mobile-shell-surface[\s\S]*?width: min\(30rem, 72vw\)/, "tablet inspector must be a bounded right-side sheet");
|
|
48
48
|
assert.match(css, /html\[data-tablet-shell="v2"\] \.file-viewer-pane[\s\S]*?position: fixed[\s\S]*?inset: 0/, "tablet files must default to full-screen replacement");
|
|
49
49
|
assert.match(css, /and \(pointer: coarse\)[\s\S]*?min-height: 44px/, "coarse tablet pointers must retain the 44px target floor");
|
|
50
|
-
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-
|
|
51
|
-
assert.match(html, /styles\.css\?v=
|
|
52
|
-
assert.match(html, /app\.js\?v=
|
|
50
|
+
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-v153"/, "continuity/tablet assets need a coherent cache identity");
|
|
51
|
+
assert.match(html, /styles\.css\?v=152/, "tablet CSS must have a coherent HTML revision");
|
|
52
|
+
assert.match(html, /app\.js\?v=182/, "continuity app logic must have a coherent HTML revision");
|
|
53
53
|
assert.match(technical, /tabletShell=v2[\s\S]*tabletShell=legacy/, "technical reference should document tablet preview and rollback");
|
|
54
54
|
|
|
55
55
|
console.log("mobile-continuity-tablet-static.test.mjs passed");
|
|
@@ -37,9 +37,9 @@ assert.match(pkg.scripts.check, /node --check public\/transcript-renderer\.mjs/,
|
|
|
37
37
|
assert.match(server, /STATIC_PUBLIC_FILE_EXTENSIONS[\s\S]*"\.mjs"/, "the server must serve typed startup modules from the public asset boundary");
|
|
38
38
|
assert.match(serviceWorker, /"\/mobile-shell-state\.mjs"/, "the PWA shell must cache the new startup module");
|
|
39
39
|
assert.match(serviceWorker, /"\/transcript-renderer\.mjs"/, "the PWA shell must cache the transcript startup module");
|
|
40
|
-
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-
|
|
41
|
-
assert.match(html, /styles\.css\?v=
|
|
42
|
-
assert.match(html, /app\.js\?v=
|
|
40
|
+
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-v153"/, "the cache identity must change with the startup graph");
|
|
41
|
+
assert.match(html, /styles\.css\?v=152/, "the stylesheet revision must change with mobile/tablet CSS fixes");
|
|
42
|
+
assert.match(html, /app\.js\?v=182/, "the app revision must change with continuity/tablet wiring");
|
|
43
43
|
assert.match(serviceWorker, /const APP_SHELL_NETWORK_TIMEOUT_MS = 8_000;[\s\S]*?event\.waitUntil\([\s\S]*?cache\.put\(request, response\.clone\(\)\)[\s\S]*?return networkResponse;/, "runtime cache writes must extend the event lifetime without blocking bounded network responses");
|
|
44
44
|
assert.match(serviceWorker, /MOBILE_NAVIGATION_MESSAGE_TYPE = "pi-webui:navigate:v1"/, "the service worker must use a versioned active-client navigation message");
|
|
45
45
|
assert.match(serviceWorker, /client\.postMessage\(\{ type: MOBILE_NAVIGATION_MESSAGE_TYPE, target \}\)/, "existing clients must receive only a validated target message");
|
|
@@ -60,6 +60,6 @@ assert.match(css, /data-mobile-presentation="essential"/, "Essential presentatio
|
|
|
60
60
|
assert.match(css, /html\[data-mobile-shell="v2"\] body\.mobile-keyboard-open \.widget-area,[\s\S]*?\.composer-actions-button \{ display: block !important; \}/, "v2 keyboard mode must keep run widgets and the actions entry available");
|
|
61
61
|
assert.match(css, /@media \(prefers-reduced-motion: reduce\)/, "reduced-motion behavior is required");
|
|
62
62
|
assert.match(css, /@media \(forced-colors: active\)/, "forced-color affordances are required");
|
|
63
|
-
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-
|
|
63
|
+
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-v153"/, "browser asset changes need a coherent cache tuple");
|
|
64
64
|
|
|
65
65
|
console.log("mobile-phone-experience-static.test.mjs passed");
|