@firstpick/pi-package-webui 0.8.2 → 0.8.4
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 +76 -19
- package/bin/pi-webui.mjs +864 -140
- package/lib/WEBUI_TUI_NATIVE_PARITY.json +26 -0
- package/lib/git-workflow-preferences.mjs +246 -19
- package/lib/optional-feature-catalog.mjs +29 -0
- package/lib/optional-feature-migration.mjs +410 -0
- package/lib/session-summary-core.mjs +320 -0
- package/lib/session-summary-preferences.mjs +267 -0
- package/lib/thinking-stream-recovery.mjs +156 -0
- package/lib/ui-layout-settings.mjs +254 -0
- package/package.json +5 -40
- package/public/app.js +2898 -92
- package/public/index.html +77 -14
- package/public/service-worker.js +1 -1
- package/public/styles.css +669 -2
- package/session-summary.ts +403 -0
- package/tests/aur-review-widget-static.test.mjs +3 -2
- package/tests/boot-failure-diagnostics.test.mjs +3 -3
- package/tests/browser/composer-action-grid-reorder.spec.mjs +303 -0
- package/tests/browser/feature-decision-output-popup.spec.mjs +156 -0
- package/tests/browser/interaction-continuity.spec.mjs +29 -0
- package/tests/browser/persistent-ui-layout.spec.mjs +744 -0
- package/tests/browser/session-summary.spec.mjs +271 -0
- package/tests/codex-fast-mode-static.test.mjs +10 -9
- package/tests/composer-action-grid-reorder-static.test.mjs +63 -0
- package/tests/fast-mode-client-static.test.mjs +2 -2
- package/tests/feature-decision-output-popup-static.test.mjs +172 -0
- package/tests/fixtures/fake-pi.mjs +51 -1
- package/tests/git-workflow-preferences.test.mjs +4 -2
- package/tests/http-endpoints-harness.test.mjs +507 -4
- package/tests/interaction-state-stability-static.test.mjs +3 -0
- 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 +118 -103
- package/tests/native-parity-harness.test.mjs +9 -1
- package/tests/native-parity.test.mjs +23 -1
- package/tests/open-issue-wizard-static.test.mjs +1 -1
- package/tests/optional-feature-migration-frontend.test.mjs +72 -0
- package/tests/optional-feature-migration.test.mjs +142 -0
- package/tests/persistent-ui-layout-static.test.mjs +267 -0
- package/tests/questionnaire-dialog.test.mjs +511 -0
- package/tests/queue-edit-reorder-static.test.mjs +1 -0
- package/tests/remote-auth-settings-harness.test.mjs +1 -1
- package/tests/session-summary-core.test.mjs +491 -0
- package/tests/session-summary-preferences.test.mjs +103 -0
- package/tests/side-panel-resize-static.test.mjs +1 -0
- package/tests/side-panel-section-reorder-static.test.mjs +3 -3
- package/tests/subagent-launch-slots.test.mjs +1 -1
- package/tests/thinking-stream-recovery.test.mjs +88 -0
- package/tests/ui-layout-settings.test.mjs +92 -0
- package/tests/webui-settings-locking.test.mjs +159 -0
|
@@ -67,6 +67,7 @@ const restoreToolDetailsInteraction = functionBody("restoreToolDetailsInteractio
|
|
|
67
67
|
const updateLiveToolCard = functionBody("updateLiveToolCard");
|
|
68
68
|
const renderStreamingMarkdown = functionBody("renderStreamingMarkdown");
|
|
69
69
|
const refreshMessages = functionBody("refreshMessages");
|
|
70
|
+
const restoreStreamRender = functionBody("restoreStreamRenderAfterChatRebuild");
|
|
70
71
|
const captureMobileSurface = functionBody("captureMobileSurfaceRenderFocus");
|
|
71
72
|
const restoreMobileSurface = functionBody("restoreMobileSurfaceRenderFocus");
|
|
72
73
|
const captureAppRunnerInput = functionBody("captureAppRunnerInputFocus");
|
|
@@ -145,6 +146,8 @@ assert.doesNotMatch(captureToolDetailsInteraction, /scrollHeight|clientHeight|ge
|
|
|
145
146
|
assert.match(restoreToolDetailsInteraction, /details\.open = snapshot\.open[\s\S]*focus\(\{ preventScroll: true \}\)[\s\S]*requestAnimationFrame[\s\S]*scrollSnapshot\.mode === "follow-end"[\s\S]*node\.scrollLeft = Math\.min/, "tool disclosure restoration must preserve keyboard focus and bounded reader scroll after layout");
|
|
146
147
|
assert.match(updateLiveToolCard, /captureToolDetailsInteractionState\(body\)[\s\S]*transcriptRenderer\.replaceChildren\(body\)[\s\S]*restoreToolDetailsInteractionState\(body, detailsInteractionState\)/, "live tool updates must restore only their local disclosure interaction state around body replacement");
|
|
147
148
|
assert.match(refreshMessages, /const selectionSnapshot = captureChatTextSelection\(\);[\s\S]*adoptedOutput = adoptLiveAssistantBubble\(latestMessages\)[\s\S]*resetStreamBubble\(\{ preserveCompact: adoptedOutput === "compact" \}\)[\s\S]*restoreStreamRenderAfterChatRebuild\(\)[\s\S]*restoreChatTextSelection\(selectionSnapshot\)/, "stream settlement must adopt matching normal or compact output before reset and retain exact fallback selection");
|
|
149
|
+
assert.match(restoreStreamRender, /streamOutputMounted[\s\S]*thinkingOutputMounted[\s\S]*toolCallOutputMounted/, "stream restoration must distinguish preserved live-tail nodes from surfaces that were actually detached");
|
|
150
|
+
assert.match(restoreStreamRender, /if \(!streamOutputMounted\)[\s\S]*streamBubble = null[\s\S]*if \(!thinkingOutputMounted\)[\s\S]*streamThinkingBubble = null[\s\S]*if \(!toolCallOutputMounted\)[\s\S]*streamToolCallBubble = null/, "authoritative refreshes must retain mounted live assistant, thinking, and tool-call bubbles instead of orphaning and duplicating them");
|
|
148
151
|
|
|
149
152
|
// --- Transcript mutation coordinator contracts (keyed DOM ownership) ---
|
|
150
153
|
|
|
@@ -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-v71"/, "continuity/tablet assets need a coherent cache identity");
|
|
51
|
+
assert.match(html, /styles\.css\?v=98/, "tablet CSS must have a coherent HTML revision");
|
|
52
|
+
assert.match(html, /app\.js\?v=112/, "continuity app logic must have a coherent HTML revision");
|
|
53
53
|
assert.match(readme, /tabletShell=v2/, "tablet preview and rollback must be documented");
|
|
54
54
|
|
|
55
55
|
console.log("mobile-continuity-tablet-static.test.mjs passed");
|
|
@@ -38,9 +38,9 @@ assert.match(server, /"mobile-shell-state\.mjs"/, "the server allowlist must ser
|
|
|
38
38
|
assert.match(server, /"transcript-renderer\.mjs"/, "the server allowlist must serve the transcript startup module");
|
|
39
39
|
assert.match(serviceWorker, /"\/mobile-shell-state\.mjs"/, "the PWA shell must cache the new startup module");
|
|
40
40
|
assert.match(serviceWorker, /"\/transcript-renderer\.mjs"/, "the PWA shell must cache the transcript startup module");
|
|
41
|
-
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-
|
|
42
|
-
assert.match(html, /styles\.css\?v=
|
|
43
|
-
assert.match(html, /app\.js\?v=
|
|
41
|
+
assert.match(serviceWorker, /const CACHE_NAME = "pi-webui-pwa-v71"/, "the cache identity must change with the startup graph");
|
|
42
|
+
assert.match(html, /styles\.css\?v=98/, "the stylesheet revision must change with mobile/tablet CSS fixes");
|
|
43
|
+
assert.match(html, /app\.js\?v=112/, "the app revision must change with continuity/tablet wiring");
|
|
44
44
|
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");
|
|
45
45
|
assert.match(serviceWorker, /MOBILE_NAVIGATION_MESSAGE_TYPE = "pi-webui:navigate:v1"/, "the service worker must use a versioned active-client navigation message");
|
|
46
46
|
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-v71"/, "browser asset changes need a coherent cache tuple");
|
|
64
64
|
|
|
65
65
|
console.log("mobile-phone-experience-static.test.mjs passed");
|