@firstpick/pi-package-webui 0.8.5 → 0.8.7
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 +18 -584
- package/bin/pi-webui-launcher.mjs +22 -0
- package/bin/pi-webui-update-supervisor.mjs +86 -0
- package/bin/pi-webui.mjs +933 -554
- package/index.ts +16 -6
- package/lib/component-update-state.mjs +21 -0
- package/lib/git-workflow-preferences.mjs +20 -2
- package/lib/optional-feature-catalog.mjs +1 -0
- package/lib/sampling-parameter-capabilities.mjs +160 -0
- package/lib/session-summary-core.mjs +4 -3
- package/lib/session-summary-preferences.mjs +16 -1
- package/lib/subagent-launch-slots.mjs +14 -2
- package/lib/trust-boundaries.mjs +16 -0
- package/lib/update/executor.mjs +99 -0
- package/lib/update/journal.mjs +175 -0
- package/lib/update/owners.mjs +70 -0
- package/lib/update/plan.mjs +134 -0
- package/lib/update/resolver.mjs +168 -0
- package/lib/update/supervisor.mjs +238 -0
- package/lib/update/verify.mjs +52 -0
- package/lib/update-commands.mjs +25 -13
- package/lib/webui-workspaces.mjs +17 -1
- package/lib/workspace-session-summaries.mjs +400 -0
- package/package.json +4 -4
- package/public/app.js +2487 -349
- package/public/index.html +200 -51
- package/public/middle-button-drag-scroll.mjs +154 -0
- package/public/sampling-parameter-controls.mjs +361 -0
- package/public/service-worker.js +5 -1
- package/public/stream-output-controller.mjs +327 -0
- package/public/styles.css +666 -71
- package/public/theme-contract.mjs +244 -0
- package/session-summary.ts +164 -4
- package/tests/aur-review-widget-static.test.mjs +2 -1
- package/tests/boot-failure-diagnostics.test.mjs +3 -3
- package/tests/browser/control-deck-component-updates.spec.mjs +20 -22
- package/tests/browser/interaction-continuity.spec.mjs +2 -2
- package/tests/browser/middle-button-drag-scroll.spec.mjs +145 -0
- package/tests/browser/persistent-ui-layout.spec.mjs +68 -23
- package/tests/browser/sampling-tooltip.spec.mjs +228 -0
- package/tests/browser/session-summary.spec.mjs +131 -3
- package/tests/browser/stream-output-isolation.spec.mjs +510 -0
- package/tests/browser/update-reconnect.spec.mjs +92 -0
- package/tests/codex-fast-mode-static.test.mjs +2 -2
- package/tests/common-options-submenus-interaction-static.test.mjs +172 -0
- package/tests/common-options-submenus-markup-static.test.mjs +152 -0
- package/tests/component-update-api-static.test.mjs +22 -61
- package/tests/composer-action-grid-reorder-static.test.mjs +3 -3
- package/tests/control-deck-component-updates-static.test.mjs +13 -237
- package/tests/durable-rpc-supervisor-harness.test.mjs +3 -1
- package/tests/fast-mode-client-static.test.mjs +3 -2
- package/tests/feature-decision-output-popup-static.test.mjs +2 -2
- package/tests/feature-system-prompt-optional-feature-static.test.mjs +49 -0
- package/tests/fixtures/fake-pi.mjs +269 -2
- package/tests/fixtures/update/tree-timeout-descendant.mjs +6 -0
- package/tests/fixtures/update/tree-timeout-parent.mjs +11 -0
- package/tests/git-footer-context-menu-static.test.mjs +58 -0
- package/tests/git-workflow-preferences.test.mjs +7 -1
- package/tests/guided-git-aur-review.test.mjs +4 -3
- package/tests/http-endpoints-harness.test.mjs +274 -23
- package/tests/middle-button-drag-scroll-static.test.mjs +24 -0
- package/tests/middle-button-drag-scroll.test.mjs +170 -0
- package/tests/mobile-continuity-tablet-static.test.mjs +3 -3
- package/tests/mobile-foundation-static.test.mjs +5 -6
- package/tests/mobile-phone-experience-static.test.mjs +1 -1
- package/tests/mobile-static.test.mjs +85 -50
- package/tests/native-parity.test.mjs +1 -1
- package/tests/open-issue-wizard-static.test.mjs +2 -3
- package/tests/optional-feature-migration-frontend.test.mjs +9 -5
- package/tests/persistent-ui-layout-static.test.mjs +13 -2
- package/tests/questionnaire-dialog.test.mjs +3 -3
- package/tests/remote-auth-settings-harness.test.mjs +43 -0
- package/tests/rpc-supervisor-host.test.mjs +11 -2
- package/tests/safety-guard-auto-review-harness.test.mjs +117 -0
- package/tests/safety-guard-auto-review-static.test.mjs +34 -0
- package/tests/sampling-native-controls-user-flow.test.mjs +752 -0
- package/tests/sampling-parameter-capabilities.test.mjs +167 -0
- package/tests/sampling-parameter-controls.test.mjs +241 -0
- package/tests/session-sampling-helper.test.mjs +228 -0
- package/tests/session-sampling-http.test.mjs +168 -0
- package/tests/session-sampling-ui-static.test.mjs +370 -0
- package/tests/session-summary-core.test.mjs +205 -10
- package/tests/side-panel-section-height-removal-static.test.mjs +34 -0
- package/tests/side-panel-section-reorder-static.test.mjs +3 -3
- package/tests/staged-content-hash-contract.test.mjs +52 -11
- package/tests/stream-lifecycle-core.test.mjs +134 -0
- package/tests/stream-output-controller.test.mjs +252 -0
- package/tests/stream-output-isolation-static.test.mjs +89 -0
- package/tests/streaming-ui-coupling.test.mjs +50 -0
- package/tests/subagent-gate-visibility.test.mjs +1 -1
- package/tests/subagent-launch-slots-static.test.mjs +1 -1
- package/tests/subagent-launch-slots.test.mjs +18 -1
- package/tests/theme-contract.test.mjs +104 -0
- package/tests/theme-customizer-static.test.mjs +82 -0
- package/tests/theme-scheme-mode.test.mjs +15 -0
- package/tests/ui-layout-settings.test.mjs +18 -1
- package/tests/update-api-harness.test.mjs +111 -0
- package/tests/update-commands.test.mjs +15 -45
- package/tests/update-executor-process-tree-harness.test.mjs +22 -0
- package/tests/update-journal-harness.test.mjs +59 -0
- package/tests/update-lock-multiprocess-harness.test.mjs +46 -0
- package/tests/update-owners.test.mjs +27 -0
- package/tests/update-plan.test.mjs +58 -0
- package/tests/update-resolver.test.mjs +56 -0
- package/tests/update-supervisor-harness.test.mjs +57 -0
- package/tests/update-tab-restore-harness.test.mjs +24 -0
- package/tests/update-verify.test.mjs +31 -0
- package/tests/workspace-files-live-updates-static.test.mjs +13 -4
- package/tests/workspace-session-summaries.test.mjs +288 -0
- package/webui-rpc-helper.mjs +119 -0
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
import assert from "node:assert/strict";
|
|
2
|
+
import { spawn } from "node:child_process";
|
|
3
|
+
import { createServer } from "node:net";
|
|
4
|
+
import { mkdtemp, rm } from "node:fs/promises";
|
|
5
|
+
import { tmpdir } from "node:os";
|
|
6
|
+
import { dirname, join } from "node:path";
|
|
7
|
+
import { setTimeout as delay } from "node:timers/promises";
|
|
8
|
+
import { fileURLToPath } from "node:url";
|
|
9
|
+
import { expect, test } from "@playwright/test";
|
|
10
|
+
|
|
11
|
+
const root = join(dirname(fileURLToPath(import.meta.url)), "..", "..");
|
|
12
|
+
const serverScript = join(root, "bin", "pi-webui.mjs");
|
|
13
|
+
const fakePi = join(root, "tests", "fixtures", "fake-pi.mjs");
|
|
14
|
+
|
|
15
|
+
async function freePort() {
|
|
16
|
+
const server = createServer();
|
|
17
|
+
await new Promise((resolve) => server.listen(0, "127.0.0.1", resolve));
|
|
18
|
+
const { port } = server.address();
|
|
19
|
+
await new Promise((resolve) => server.close(resolve));
|
|
20
|
+
return port;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
let child;
|
|
24
|
+
let baseURL;
|
|
25
|
+
let tempRoot;
|
|
26
|
+
let output = "";
|
|
27
|
+
|
|
28
|
+
test.beforeAll(async () => {
|
|
29
|
+
const port = await freePort();
|
|
30
|
+
tempRoot = await mkdtemp(join(tmpdir(), "pi-webui-middle-drag-scroll-"));
|
|
31
|
+
baseURL = `http://127.0.0.1:${port}`;
|
|
32
|
+
child = spawn(process.execPath, [serverScript, "--cwd", tempRoot, "--host", "127.0.0.1", "--port", String(port), "--pi", fakePi], {
|
|
33
|
+
stdio: ["ignore", "pipe", "pipe"],
|
|
34
|
+
env: {
|
|
35
|
+
...process.env,
|
|
36
|
+
PI_WEBUI_RPC_SUPERVISOR: "0",
|
|
37
|
+
PI_CODING_AGENT_DIR: join(tempRoot, "agent"),
|
|
38
|
+
PI_WEBUI_SETTINGS_FILE: join(tempRoot, "settings.json"),
|
|
39
|
+
},
|
|
40
|
+
});
|
|
41
|
+
child.stdout.on("data", (chunk) => { output += String(chunk); });
|
|
42
|
+
child.stderr.on("data", (chunk) => { output += String(chunk); });
|
|
43
|
+
for (let attempt = 0; attempt < 80; attempt += 1) {
|
|
44
|
+
if (child.exitCode !== null) break;
|
|
45
|
+
try {
|
|
46
|
+
const response = await fetch(`${baseURL}/api/health`, { signal: AbortSignal.timeout(500) });
|
|
47
|
+
if (response.ok) return;
|
|
48
|
+
} catch {
|
|
49
|
+
// Wait for the local browser fixture.
|
|
50
|
+
}
|
|
51
|
+
await delay(100);
|
|
52
|
+
}
|
|
53
|
+
throw new Error(`Pi Web UI did not start:\n${output}`);
|
|
54
|
+
});
|
|
55
|
+
|
|
56
|
+
test.afterAll(async () => {
|
|
57
|
+
if (child?.exitCode === null) {
|
|
58
|
+
await fetch(`${baseURL}/api/shutdown`, { method: "POST", signal: AbortSignal.timeout(1_000) }).catch(() => undefined);
|
|
59
|
+
await new Promise((resolve) => child.once("exit", resolve));
|
|
60
|
+
}
|
|
61
|
+
await rm(tempRoot, { recursive: true, force: true });
|
|
62
|
+
});
|
|
63
|
+
|
|
64
|
+
test("middle-button displacement automatically scrolls in both directions and releases outside", async ({ page }) => {
|
|
65
|
+
await page.setViewportSize({ width: 1000, height: 700 });
|
|
66
|
+
await page.goto(baseURL);
|
|
67
|
+
await page.evaluate(() => {
|
|
68
|
+
const surface = document.createElement("div");
|
|
69
|
+
surface.dataset.middleDragFixture = "true";
|
|
70
|
+
Object.assign(surface.style, {
|
|
71
|
+
position: "fixed",
|
|
72
|
+
inset: "100px auto auto 100px",
|
|
73
|
+
zIndex: "10000",
|
|
74
|
+
width: "400px",
|
|
75
|
+
height: "300px",
|
|
76
|
+
overflowY: "auto",
|
|
77
|
+
scrollBehavior: "auto",
|
|
78
|
+
background: "white",
|
|
79
|
+
});
|
|
80
|
+
const content = document.createElement("div");
|
|
81
|
+
content.style.height = "2400px";
|
|
82
|
+
content.textContent = "middle drag scroll fixture";
|
|
83
|
+
surface.append(content);
|
|
84
|
+
document.body.append(surface);
|
|
85
|
+
surface.scrollTop = 900;
|
|
86
|
+
surface.style.scrollBehavior = "smooth";
|
|
87
|
+
});
|
|
88
|
+
const surface = page.locator("[data-middle-drag-fixture]");
|
|
89
|
+
const before = await surface.evaluate((node) => node.scrollTop);
|
|
90
|
+
assert.ok(before > 0, "the browser fixture should begin at a real reader position");
|
|
91
|
+
|
|
92
|
+
const box = await surface.boundingBox();
|
|
93
|
+
assert.ok(box, "the scroll surface should have pointer geometry");
|
|
94
|
+
const x = box.x + box.width / 2;
|
|
95
|
+
const y = box.y + box.height / 2;
|
|
96
|
+
await page.mouse.move(x, y);
|
|
97
|
+
await page.mouse.down({ button: "middle" });
|
|
98
|
+
await expect(page.locator("body")).toHaveClass(/middle-button-auto-scrolling/);
|
|
99
|
+
await page.mouse.move(x, y + 120, { steps: 6 });
|
|
100
|
+
await expect.poll(() => surface.evaluate((node) => node.scrollTop)).toBeGreaterThan(before + 80);
|
|
101
|
+
const afterDown = await surface.evaluate((node) => node.scrollTop);
|
|
102
|
+
await page.mouse.move(x, y - 120, { steps: 6 });
|
|
103
|
+
await expect.poll(() => surface.evaluate((node) => node.scrollTop)).toBeLessThan(afterDown - 80);
|
|
104
|
+
await page.mouse.move(Math.max(0, box.x - 10), y - 120);
|
|
105
|
+
await page.mouse.up({ button: "middle" });
|
|
106
|
+
|
|
107
|
+
await expect(page.locator("body")).not.toHaveClass(/middle-button-auto-scrolling/);
|
|
108
|
+
await expect.poll(() => surface.evaluate((node) => node.style.scrollBehavior)).toBe("smooth");
|
|
109
|
+
});
|
|
110
|
+
|
|
111
|
+
test("middle-clicking an interactive control keeps native behavior and does not pan", async ({ page }) => {
|
|
112
|
+
await page.setViewportSize({ width: 1000, height: 700 });
|
|
113
|
+
await page.goto(baseURL);
|
|
114
|
+
await page.evaluate(() => {
|
|
115
|
+
const surface = document.createElement("div");
|
|
116
|
+
surface.dataset.middleDragInteractiveSurface = "true";
|
|
117
|
+
Object.assign(surface.style, {
|
|
118
|
+
position: "fixed",
|
|
119
|
+
inset: "100px auto auto 100px",
|
|
120
|
+
zIndex: "10000",
|
|
121
|
+
width: "400px",
|
|
122
|
+
height: "300px",
|
|
123
|
+
overflowY: "auto",
|
|
124
|
+
background: "white",
|
|
125
|
+
});
|
|
126
|
+
const button = document.createElement("button");
|
|
127
|
+
button.type = "button";
|
|
128
|
+
button.textContent = "interactive middle-click fixture";
|
|
129
|
+
button.dataset.middleDragInteractiveFixture = "true";
|
|
130
|
+
const spacer = document.createElement("div");
|
|
131
|
+
spacer.style.height = "2200px";
|
|
132
|
+
surface.append(button, spacer);
|
|
133
|
+
document.body.append(surface);
|
|
134
|
+
});
|
|
135
|
+
const surface = page.locator("[data-middle-drag-interactive-surface]");
|
|
136
|
+
const button = page.locator("[data-middle-drag-interactive-fixture]");
|
|
137
|
+
const box = await button.boundingBox();
|
|
138
|
+
assert.ok(box, "the interactive fixture should have pointer geometry");
|
|
139
|
+
await page.mouse.move(box.x + box.width / 2, box.y + box.height / 2);
|
|
140
|
+
await page.mouse.down({ button: "middle" });
|
|
141
|
+
await page.mouse.move(box.x + box.width / 2, box.y + box.height / 2 + 100);
|
|
142
|
+
await page.mouse.up({ button: "middle" });
|
|
143
|
+
await expect(page.locator("body")).not.toHaveClass(/middle-button-auto-scrolling/);
|
|
144
|
+
assert.equal(await surface.evaluate((node) => node.scrollTop), 0);
|
|
145
|
+
});
|
|
@@ -219,6 +219,7 @@ async function assertRestoredLayout(page, expected, { expectCustomGroup = null }
|
|
|
219
219
|
await expect(page.locator("#terminalTabsLayoutSelect")).toHaveValue("left");
|
|
220
220
|
await expect.poll(async () => Number(await page.locator("#sidePanelResizeHandle").getAttribute("aria-valuenow"))).toBeGreaterThanOrEqual(320);
|
|
221
221
|
await expect.poll(async () => Number(await page.locator("#sidePanelResizeHandle").getAttribute("aria-valuenow"))).toBeLessThanOrEqual(expected.sidePanelWidth);
|
|
222
|
+
await expect(page.locator("[data-side-panel-section-resize]")).toHaveCount(0);
|
|
222
223
|
const matchingViewportWidth = await useMatchingComposerViewport(page, expected.composerGrid.columns);
|
|
223
224
|
await expect.poll(() => page.locator('[data-composer-action-id="options"]').evaluate((node) => node.style.getPropertyValue("--composer-action-grid-column"))).toBe(expected.optionsColumn);
|
|
224
225
|
if (expectCustomGroup === true) await expect(page.locator(".terminal-tab-custom-group")).toHaveCount(1);
|
|
@@ -252,7 +253,7 @@ test.beforeEach(async () => {
|
|
|
252
253
|
|
|
253
254
|
test.afterAll(async () => {
|
|
254
255
|
await stopServer();
|
|
255
|
-
await rm(tempRoot, { recursive: true, force: true });
|
|
256
|
+
await rm(tempRoot, { recursive: true, force: true, maxRetries: 5, retryDelay: 100 });
|
|
256
257
|
});
|
|
257
258
|
|
|
258
259
|
test("server-owned layout survives stale reads, failed writes, localStorage clear, and process restart", async ({ browser }) => {
|
|
@@ -317,10 +318,14 @@ test("server-owned layout survives stale reads, failed writes, localStorage clea
|
|
|
317
318
|
|
|
318
319
|
await openFooterModelPicker(page);
|
|
319
320
|
const selectedModel = page.locator('[data-footer-model-key="fake/fake-model"]');
|
|
320
|
-
await
|
|
321
|
-
|
|
322
|
-
const
|
|
323
|
-
|
|
321
|
+
const initialFooterOrder = await page.locator(".footer-model-option").evaluateAll((buttons) => buttons.map((button) => button.dataset.footerModelKey));
|
|
322
|
+
const selectedModelIndex = initialFooterOrder.indexOf("fake/fake-model");
|
|
323
|
+
const moveOffset = selectedModelIndex > 0 ? -1 : 1;
|
|
324
|
+
const expectedFooterOrder = [...initialFooterOrder];
|
|
325
|
+
[expectedFooterOrder[selectedModelIndex], expectedFooterOrder[selectedModelIndex + moveOffset]] = [expectedFooterOrder[selectedModelIndex + moveOffset], expectedFooterOrder[selectedModelIndex]];
|
|
326
|
+
await selectedModel.evaluate((button, key) => button.dispatchEvent(new KeyboardEvent("keydown", { key, altKey: true, bubbles: true })), moveOffset < 0 ? "ArrowUp" : "ArrowDown");
|
|
327
|
+
await expect.poll(() => page.evaluate((key) => JSON.parse(localStorage.getItem(key) || "[]"), layoutKeys.footerOrder)).toEqual(expectedFooterOrder);
|
|
328
|
+
await expect.poll(() => page.locator(".footer-model-option").evaluateAll((buttons) => buttons.map((button) => button.dataset.footerModelKey))).toEqual(expectedFooterOrder);
|
|
324
329
|
await expect(page.locator('.footer-model-option[aria-selected="true"]')).toHaveAttribute("data-footer-model-key", "fake/fake-model");
|
|
325
330
|
await page.keyboard.press("Escape");
|
|
326
331
|
|
|
@@ -335,7 +340,6 @@ test("server-owned layout survives stale reads, failed writes, localStorage clea
|
|
|
335
340
|
await expect(page.locator("#terminalTabsLayoutSelect")).toBeVisible();
|
|
336
341
|
await page.locator("#terminalTabsLayoutSelect").selectOption("left");
|
|
337
342
|
await expect(page.locator("body")).toHaveClass(/terminal-tabs-left/);
|
|
338
|
-
|
|
339
343
|
const options = page.locator('[data-composer-action-id="options"]');
|
|
340
344
|
const optionsBox = await options.boundingBox();
|
|
341
345
|
expect(optionsBox).toBeTruthy();
|
|
@@ -393,8 +397,8 @@ test("server-owned layout survives stale reads, failed writes, localStorage clea
|
|
|
393
397
|
await page.reload();
|
|
394
398
|
const matchingViewportWidth = await assertRestoredLayout(page, expected, { expectCustomGroup: true });
|
|
395
399
|
|
|
396
|
-
await page.setViewportSize({ width:
|
|
397
|
-
await expect
|
|
400
|
+
await page.setViewportSize({ width: 700, height: 900 });
|
|
401
|
+
await expect(page.locator("body")).not.toHaveClass(/composer-action-grid-enabled/);
|
|
398
402
|
await expect.poll(() => page.evaluate((key) => JSON.parse(localStorage.getItem(key) || "null"), layoutKeys.composerGrid)).toEqual(expected.composerGrid);
|
|
399
403
|
await page.setViewportSize({ width: matchingViewportWidth, height: 1000 });
|
|
400
404
|
await expect.poll(() => options.evaluate((node) => node.style.getPropertyValue("--composer-action-grid-column"))).toBe(expected.optionsColumn);
|
|
@@ -403,6 +407,7 @@ test("server-owned layout survives stale reads, failed writes, localStorage clea
|
|
|
403
407
|
await stopServer();
|
|
404
408
|
const settingsOnDisk = JSON.parse(await readFile(settingsFile, "utf8"));
|
|
405
409
|
assert.deepEqual(settingsOnDisk.uiLayout.sidePanel.sectionOrder, expected.sideOrder, "the private settings file should contain the browser-committed Control Deck order");
|
|
410
|
+
assert.equal("sectionHeights" in settingsOnDisk.uiLayout.sidePanel, false, "removed Control Deck section heights must not be persisted");
|
|
406
411
|
assert.deepEqual(settingsOnDisk.uiLayout.composerActions.grid, expected.composerGrid, "the private settings file should contain the exact sparse composer grid");
|
|
407
412
|
assert.equal(settingsOnDisk.uiLayout.fileViewerWidth, expected.fileViewerWidth, "the private settings file should contain the browser-committed file-viewer width");
|
|
408
413
|
|
|
@@ -440,6 +445,7 @@ test("returning browsers adopt authoritative Control Deck state without echo wri
|
|
|
440
445
|
await context.addInitScript(({ sideOrder, sideCollapsed }) => {
|
|
441
446
|
localStorage.setItem(sideOrder, JSON.stringify(["files", "controls", "git"]));
|
|
442
447
|
localStorage.setItem(sideCollapsed, "1");
|
|
448
|
+
localStorage.setItem("pi-webui-side-panel-section-heights-v1", JSON.stringify({ controls: 240 }));
|
|
443
449
|
}, layoutKeys);
|
|
444
450
|
const page = await context.newPage();
|
|
445
451
|
let layoutPuts = 0;
|
|
@@ -449,13 +455,27 @@ test("returning browsers adopt authoritative Control Deck state without echo wri
|
|
|
449
455
|
});
|
|
450
456
|
|
|
451
457
|
await page.goto(baseURL);
|
|
458
|
+
await expect.poll(() => page.evaluate(() => localStorage.getItem("pi-webui-side-panel-section-heights-v1"))).toBeNull();
|
|
452
459
|
await expect.poll(async () => (await sectionOrder(page)).slice(0, serverSideOrder.length)).toEqual(serverSideOrder);
|
|
453
460
|
await expect(page.locator("body")).not.toHaveClass(/side-panel-collapsed/);
|
|
454
461
|
await page.waitForTimeout(700);
|
|
455
462
|
expect(layoutPuts).toBe(0);
|
|
456
463
|
const persisted = await serverApi("/api/interface-preferences");
|
|
457
464
|
assert.deepEqual(persisted.data.layout.sidePanel.sectionOrder, serverSideOrder);
|
|
465
|
+
assert.equal("sectionHeights" in persisted.data.layout.sidePanel, false);
|
|
458
466
|
assert.equal(persisted.data.layout.sidePanel.collapsed, false);
|
|
467
|
+
|
|
468
|
+
const controlsToggle = page.locator('[data-side-panel-section-toggle="controls"]');
|
|
469
|
+
if (await controlsToggle.getAttribute("aria-expanded") !== "true") await controlsToggle.click();
|
|
470
|
+
const controlsSection = page.locator('[data-side-panel-section="controls"]');
|
|
471
|
+
await expect(page.locator("[data-side-panel-section-resize]")).toHaveCount(0);
|
|
472
|
+
await controlsToggle.click({ button: "right" });
|
|
473
|
+
const controlsVisibilityItem = page.locator('[data-side-panel-section-visibility="controls"]');
|
|
474
|
+
await expect(controlsVisibilityItem).toBeVisible();
|
|
475
|
+
await controlsVisibilityItem.click();
|
|
476
|
+
await expect(controlsSection).toBeHidden();
|
|
477
|
+
await controlsVisibilityItem.click();
|
|
478
|
+
await expect(controlsSection).toBeVisible();
|
|
459
479
|
await context.close();
|
|
460
480
|
});
|
|
461
481
|
|
|
@@ -576,10 +596,11 @@ test("one tab cannot erase another tab's failed pending journal", async ({ brows
|
|
|
576
596
|
await route.continue();
|
|
577
597
|
});
|
|
578
598
|
await Promise.all([pageA.goto(baseURL), pageB.goto(baseURL)]);
|
|
599
|
+
await expect.poll(() => pageA.evaluate((key) => JSON.parse(localStorage.getItem(key) || "[]").slice(0, 2), layoutKeys.composerOrder)).toEqual(["send", "new"]);
|
|
579
600
|
|
|
580
601
|
const newSession = pageA.locator('[data-composer-action-id="new"]');
|
|
581
|
-
await newSession.
|
|
582
|
-
await
|
|
602
|
+
await newSession.evaluate((button) => button.dispatchEvent(new KeyboardEvent("keydown", { key: "ArrowLeft", altKey: true, bubbles: true })));
|
|
603
|
+
await expect.poll(() => pageA.evaluate((key) => JSON.parse(localStorage.getItem(key) || "[]").slice(0, 2), layoutKeys.composerOrder)).toEqual(["new", "send"]);
|
|
583
604
|
await expect.poll(() => failedComposerWrites).toBeGreaterThan(0);
|
|
584
605
|
await expect.poll(() => pageA.evaluate(() => Object.keys(localStorage).filter((key) => key.startsWith("pi-webui-ui-layout-pending-v3:")).length)).toBeGreaterThan(0);
|
|
585
606
|
|
|
@@ -655,11 +676,12 @@ test("in-flight sibling acknowledgement clears only the acknowledged subfield",
|
|
|
655
676
|
await route.continue();
|
|
656
677
|
});
|
|
657
678
|
await Promise.all([pageA.goto(baseURL), pageB.goto(baseURL)]);
|
|
679
|
+
await expect.poll(async () => (await sectionOrder(pageA)).slice(0, initialOrder.length)).toEqual(initialOrder);
|
|
680
|
+
await expect.poll(async () => (await sectionOrder(pageB)).slice(0, initialOrder.length)).toEqual(initialOrder);
|
|
658
681
|
interceptWrites = true;
|
|
659
682
|
|
|
660
683
|
const controlsA = pageA.locator('[data-side-panel-section-toggle="controls"]');
|
|
661
|
-
await controlsA.
|
|
662
|
-
await controlsA.press("Alt+ArrowDown");
|
|
684
|
+
await controlsA.evaluate((button) => button.dispatchEvent(new KeyboardEvent("keydown", { key: "ArrowDown", altKey: true, bubbles: true })));
|
|
663
685
|
await firstOrderFetchedPromise;
|
|
664
686
|
await pageA.locator("#toggleSidePanelButton").click();
|
|
665
687
|
releaseFirstOrder();
|
|
@@ -668,8 +690,7 @@ test("in-flight sibling acknowledgement clears only the acknowledged subfield",
|
|
|
668
690
|
assert.equal(secondPayload.layout.sidePanel?.collapsed, true);
|
|
669
691
|
|
|
670
692
|
const controlsB = pageB.locator('[data-side-panel-section-toggle="controls"]');
|
|
671
|
-
await controlsB.
|
|
672
|
-
await controlsB.press("Alt+ArrowUp");
|
|
693
|
+
await controlsB.evaluate((button) => button.dispatchEvent(new KeyboardEvent("keydown", { key: "ArrowUp", altKey: true, bubbles: true })));
|
|
673
694
|
const browserBOrder = ["controls", "files", "git"];
|
|
674
695
|
await expect.poll(async () => (await serverApi("/api/interface-preferences")).data.layout.sidePanel.sectionOrder.slice(0, browserBOrder.length)).toEqual(browserBOrder);
|
|
675
696
|
releaseSecondWrite();
|
|
@@ -716,9 +737,12 @@ test("a delayed GET cannot regress the revision acknowledged by a newer PUT", as
|
|
|
716
737
|
await route.fulfill({ response });
|
|
717
738
|
return;
|
|
718
739
|
}
|
|
719
|
-
if (captureNextPut && request.method() === "PUT"
|
|
720
|
-
|
|
721
|
-
|
|
740
|
+
if (captureNextPut && request.method() === "PUT") {
|
|
741
|
+
const payload = request.postDataJSON();
|
|
742
|
+
if (Object.hasOwn(payload?.layout?.sidePanel || {}, "collapsed")) {
|
|
743
|
+
captureNextPut = false;
|
|
744
|
+
capturedExpectedRevision = payload.expectedLayoutRevision;
|
|
745
|
+
}
|
|
722
746
|
}
|
|
723
747
|
await route.continue();
|
|
724
748
|
});
|
|
@@ -728,17 +752,38 @@ test("a delayed GET cannot regress the revision acknowledged by a newer PUT", as
|
|
|
728
752
|
await delayedGetCapturedPromise;
|
|
729
753
|
|
|
730
754
|
const controls = page.locator('[data-side-panel-section-toggle="controls"]');
|
|
731
|
-
await
|
|
732
|
-
|
|
733
|
-
const
|
|
755
|
+
const orderBeforeMove = (await sectionOrder(page)).slice(0, 3);
|
|
756
|
+
const controlsIndex = orderBeforeMove.indexOf("controls");
|
|
757
|
+
const moveOffset = controlsIndex < orderBeforeMove.length - 1 ? 1 : -1;
|
|
758
|
+
const newerOrder = [...orderBeforeMove];
|
|
759
|
+
[newerOrder[controlsIndex], newerOrder[controlsIndex + moveOffset]] = [newerOrder[controlsIndex + moveOffset], newerOrder[controlsIndex]];
|
|
760
|
+
const newerPutResponse = page.waitForResponse((response) => {
|
|
761
|
+
if (!response.url().includes("/api/interface-preferences") || response.request().method() !== "PUT") return false;
|
|
762
|
+
return Array.isArray(response.request().postDataJSON()?.layout?.sidePanel?.sectionOrder);
|
|
763
|
+
});
|
|
764
|
+
await controls.evaluate((button, key) => button.dispatchEvent(new KeyboardEvent("keydown", { key, altKey: true, bubbles: true })), moveOffset > 0 ? "ArrowDown" : "ArrowUp");
|
|
765
|
+
await newerPutResponse;
|
|
734
766
|
await expect.poll(async () => (await serverApi("/api/interface-preferences")).data.layout.sidePanel.sectionOrder.slice(0, newerOrder.length)).toEqual(newerOrder);
|
|
735
|
-
|
|
767
|
+
await expect.poll(() => page.evaluate((prefix) => {
|
|
768
|
+
for (let index = 0; index < localStorage.length; index += 1) {
|
|
769
|
+
const key = localStorage.key(index);
|
|
770
|
+
if (!key?.startsWith(prefix)) continue;
|
|
771
|
+
try {
|
|
772
|
+
const record = JSON.parse(localStorage.getItem(key) || "null");
|
|
773
|
+
if (record?.field === "sidePanel" && record?.subfield === "sectionOrder") return true;
|
|
774
|
+
} catch {
|
|
775
|
+
// Ignore malformed unrelated records; production also fails soft here.
|
|
776
|
+
}
|
|
777
|
+
}
|
|
778
|
+
return false;
|
|
779
|
+
}, "pi-webui-ui-layout-pending-v3:")).toBe(false);
|
|
736
780
|
releaseDelayedGet();
|
|
737
781
|
await page.waitForTimeout(300);
|
|
782
|
+
const revisionBeforeCollapse = (await serverApi("/api/interface-preferences")).data.layoutRevision;
|
|
738
783
|
|
|
739
784
|
captureNextPut = true;
|
|
740
|
-
await page.locator("#toggleSidePanelButton").click();
|
|
741
|
-
await expect.poll(() => capturedExpectedRevision).toBe(
|
|
785
|
+
await page.locator("#toggleSidePanelButton").evaluate((button) => button.click());
|
|
786
|
+
await expect.poll(() => capturedExpectedRevision).toBe(revisionBeforeCollapse);
|
|
742
787
|
await expect.poll(async () => (await serverApi("/api/interface-preferences")).data.layout.sidePanel.collapsed).toBe(true);
|
|
743
788
|
await context.close();
|
|
744
789
|
});
|
|
@@ -0,0 +1,228 @@
|
|
|
1
|
+
import { spawn } from "node:child_process";
|
|
2
|
+
import { createServer } from "node:net";
|
|
3
|
+
import { mkdtemp, rm } from "node:fs/promises";
|
|
4
|
+
import { tmpdir } from "node:os";
|
|
5
|
+
import { dirname, join } from "node:path";
|
|
6
|
+
import { setTimeout as delay } from "node:timers/promises";
|
|
7
|
+
import { fileURLToPath } from "node:url";
|
|
8
|
+
import { expect, test } from "@playwright/test";
|
|
9
|
+
|
|
10
|
+
const root = join(dirname(fileURLToPath(import.meta.url)), "..", "..");
|
|
11
|
+
const serverScript = join(root, "bin", "pi-webui.mjs");
|
|
12
|
+
const fakePi = join(root, "tests", "fixtures", "fake-pi.mjs");
|
|
13
|
+
const parameterLabels = {
|
|
14
|
+
temperature: "Temperature",
|
|
15
|
+
top_p: "Top P",
|
|
16
|
+
frequency_penalty: "Frequency Penalty",
|
|
17
|
+
presence_penalty: "Presence Penalty",
|
|
18
|
+
seed: "Seed",
|
|
19
|
+
top_k: "Top K",
|
|
20
|
+
min_p: "Min P",
|
|
21
|
+
};
|
|
22
|
+
|
|
23
|
+
async function freePort() {
|
|
24
|
+
const server = createServer();
|
|
25
|
+
await new Promise((resolve) => server.listen(0, "127.0.0.1", resolve));
|
|
26
|
+
const { port } = server.address();
|
|
27
|
+
await new Promise((resolve) => server.close(resolve));
|
|
28
|
+
return port;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
let child;
|
|
32
|
+
let baseURL;
|
|
33
|
+
let tempRoot;
|
|
34
|
+
let output = "";
|
|
35
|
+
|
|
36
|
+
test.beforeAll(async () => {
|
|
37
|
+
const port = await freePort();
|
|
38
|
+
tempRoot = await mkdtemp(join(tmpdir(), "pi-webui-sampling-tooltip-"));
|
|
39
|
+
baseURL = `http://127.0.0.1:${port}`;
|
|
40
|
+
child = spawn(process.execPath, [serverScript, "--cwd", tempRoot, "--host", "127.0.0.1", "--port", String(port), "--pi", fakePi], {
|
|
41
|
+
stdio: ["ignore", "pipe", "pipe"],
|
|
42
|
+
env: {
|
|
43
|
+
...process.env,
|
|
44
|
+
PI_WEBUI_RPC_SUPERVISOR: "0",
|
|
45
|
+
PI_CODING_AGENT_DIR: join(tempRoot, "agent"),
|
|
46
|
+
PI_WEBUI_SETTINGS_FILE: join(tempRoot, "settings.json"),
|
|
47
|
+
},
|
|
48
|
+
});
|
|
49
|
+
child.stdout.on("data", (chunk) => { output += String(chunk); });
|
|
50
|
+
child.stderr.on("data", (chunk) => { output += String(chunk); });
|
|
51
|
+
for (let attempt = 0; attempt < 80; attempt += 1) {
|
|
52
|
+
if (child.exitCode !== null) break;
|
|
53
|
+
try {
|
|
54
|
+
const response = await fetch(`${baseURL}/api/health`, { signal: AbortSignal.timeout(500) });
|
|
55
|
+
if (response.ok) return;
|
|
56
|
+
} catch {
|
|
57
|
+
// Wait for the package server and fake Pi fixture to start.
|
|
58
|
+
}
|
|
59
|
+
await delay(100);
|
|
60
|
+
}
|
|
61
|
+
throw new Error(`Pi Web UI did not start:\n${output}`);
|
|
62
|
+
});
|
|
63
|
+
|
|
64
|
+
test.afterAll(async () => {
|
|
65
|
+
if (child?.exitCode === null) {
|
|
66
|
+
await fetch(`${baseURL}/api/shutdown`, { method: "POST", signal: AbortSignal.timeout(1_000) }).catch(() => undefined);
|
|
67
|
+
await new Promise((resolve) => child.once("exit", resolve));
|
|
68
|
+
}
|
|
69
|
+
await rm(tempRoot, { recursive: true, force: true });
|
|
70
|
+
});
|
|
71
|
+
|
|
72
|
+
function samplingState() {
|
|
73
|
+
const parameters = Object.fromEntries(Object.entries(parameterLabels).map(([key, label]) => [key, {
|
|
74
|
+
supported: key === "temperature",
|
|
75
|
+
reason: key === "temperature"
|
|
76
|
+
? "Supported by openai-codex-responses."
|
|
77
|
+
: `openai-codex-responses does not declare ${label} support.`,
|
|
78
|
+
source: key === "temperature" ? "api" : "unsupported",
|
|
79
|
+
}]));
|
|
80
|
+
return {
|
|
81
|
+
session: { temperature: 0.7, top_p: 0.9 },
|
|
82
|
+
defaults: { temperature: 1 },
|
|
83
|
+
effective: { temperature: 0.7 },
|
|
84
|
+
support: {
|
|
85
|
+
supported: true,
|
|
86
|
+
api: "openai-codex-responses",
|
|
87
|
+
model: { provider: "openai-codex", id: "gpt-5.6-sol", name: "GPT-5.6 Sol" },
|
|
88
|
+
parameters,
|
|
89
|
+
compatibleApis: ["openai-completions", "openai-responses", "openai-codex-responses"],
|
|
90
|
+
message: "Session sampling parameters apply to subsequent provider requests.",
|
|
91
|
+
},
|
|
92
|
+
};
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
async function tooltipVisualState(tooltip) {
|
|
96
|
+
return tooltip.evaluate((node) => {
|
|
97
|
+
const style = getComputedStyle(node);
|
|
98
|
+
const rect = node.getBoundingClientRect();
|
|
99
|
+
return {
|
|
100
|
+
visuallyShown: !node.hidden && style.display !== "none" && style.clipPath === "none" && rect.width > 1 && rect.height > 1,
|
|
101
|
+
pointerEvents: style.pointerEvents,
|
|
102
|
+
rect: { top: rect.top, right: rect.right, bottom: rect.bottom, left: rect.left, width: rect.width, height: rect.height },
|
|
103
|
+
};
|
|
104
|
+
});
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
async function computedUnsupportedLabelContrast(row) {
|
|
108
|
+
return row.evaluate((node) => {
|
|
109
|
+
const parseColor = (value) => {
|
|
110
|
+
const parts = String(value).match(/[\d.]+/g)?.map(Number) || [];
|
|
111
|
+
return { r: parts[0] || 0, g: parts[1] || 0, b: parts[2] || 0, a: parts[3] ?? 1 };
|
|
112
|
+
};
|
|
113
|
+
const composite = (foreground, background) => ({
|
|
114
|
+
r: foreground.r * foreground.a + background.r * (1 - foreground.a),
|
|
115
|
+
g: foreground.g * foreground.a + background.g * (1 - foreground.a),
|
|
116
|
+
b: foreground.b * foreground.a + background.b * (1 - foreground.a),
|
|
117
|
+
a: 1,
|
|
118
|
+
});
|
|
119
|
+
const luminance = ({ r, g, b }) => {
|
|
120
|
+
const linear = [r, g, b].map((channel) => {
|
|
121
|
+
const value = channel / 255;
|
|
122
|
+
return value <= 0.04045 ? value / 12.92 : ((value + 0.055) / 1.055) ** 2.4;
|
|
123
|
+
});
|
|
124
|
+
return linear[0] * 0.2126 + linear[1] * 0.7152 + linear[2] * 0.0722;
|
|
125
|
+
};
|
|
126
|
+
|
|
127
|
+
const body = document.body;
|
|
128
|
+
let background = parseColor(getComputedStyle(body).backgroundColor);
|
|
129
|
+
background = composite(background, { r: 17, g: 17, b: 27, a: 1 });
|
|
130
|
+
const ancestors = [];
|
|
131
|
+
for (let current = node; current && current !== body; current = current.parentElement) ancestors.unshift(current);
|
|
132
|
+
for (const ancestor of ancestors) background = composite(parseColor(getComputedStyle(ancestor).backgroundColor), background);
|
|
133
|
+
|
|
134
|
+
const label = node.querySelector("label");
|
|
135
|
+
const header = node.querySelector(".sampling-parameter-control-header");
|
|
136
|
+
const labelColor = parseColor(getComputedStyle(label).color);
|
|
137
|
+
labelColor.a *= Number.parseFloat(getComputedStyle(header).opacity) || 1;
|
|
138
|
+
const renderedText = composite(labelColor, background);
|
|
139
|
+
const light = Math.max(luminance(renderedText), luminance(background));
|
|
140
|
+
const dark = Math.min(luminance(renderedText), luminance(background));
|
|
141
|
+
return (light + 0.05) / (dark + 0.05);
|
|
142
|
+
});
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
test("unsupported sampling tooltip is bounded, hoverable, accessible, and Escape-dismissible", async ({ page }) => {
|
|
146
|
+
await page.setViewportSize({ width: 1280, height: 620 });
|
|
147
|
+
await page.route("**/api/tabs/*/sampling-parameters", async (route) => {
|
|
148
|
+
await route.fulfill({
|
|
149
|
+
status: 200,
|
|
150
|
+
contentType: "application/json",
|
|
151
|
+
body: JSON.stringify({ ok: true, data: samplingState() }),
|
|
152
|
+
});
|
|
153
|
+
});
|
|
154
|
+
await page.goto(baseURL);
|
|
155
|
+
|
|
156
|
+
const toggle = page.locator('[data-side-panel-section-toggle="sampling"]');
|
|
157
|
+
await expect(toggle).toBeVisible();
|
|
158
|
+
if (await toggle.getAttribute("aria-expanded") !== "true") await toggle.click();
|
|
159
|
+
|
|
160
|
+
const supportedRow = page.locator('[data-sampling-parameter="temperature"]');
|
|
161
|
+
const supportedTooltip = supportedRow.locator('[role="tooltip"]');
|
|
162
|
+
await expect(supportedRow).not.toHaveClass(/unsupported/);
|
|
163
|
+
await expect(supportedRow).not.toHaveAttribute("aria-describedby", /.+/);
|
|
164
|
+
await expect(supportedTooltip).toHaveAttribute("hidden", "");
|
|
165
|
+
await expect(supportedTooltip).toHaveText("");
|
|
166
|
+
|
|
167
|
+
const row = page.locator('[data-sampling-parameter="top_p"]');
|
|
168
|
+
const tooltip = row.locator('[role="tooltip"]');
|
|
169
|
+
await expect(row).toHaveClass(/unsupported/);
|
|
170
|
+
await expect(row).toHaveAttribute("aria-describedby", "samplingParameterTopPUnsupportedReason");
|
|
171
|
+
await expect(row.locator('input[type="checkbox"]')).toHaveAttribute("aria-describedby", "samplingParameterTopPUnsupportedReason");
|
|
172
|
+
await expect(tooltip).not.toHaveAttribute("hidden", "");
|
|
173
|
+
await expect(tooltip).toContainText("does not declare Top P support");
|
|
174
|
+
|
|
175
|
+
await row.evaluate((node) => {
|
|
176
|
+
const scrollports = [node.closest(".side-panel-section-content"), node.closest(".side-panel-body")].filter(Boolean);
|
|
177
|
+
for (const scrollport of scrollports) {
|
|
178
|
+
const delta = node.getBoundingClientRect().top - scrollport.getBoundingClientRect().top - 2;
|
|
179
|
+
scrollport.scrollTop += delta;
|
|
180
|
+
}
|
|
181
|
+
});
|
|
182
|
+
await row.hover();
|
|
183
|
+
await expect.poll(() => tooltipVisualState(tooltip)).toMatchObject({ visuallyShown: true, pointerEvents: "auto" });
|
|
184
|
+
await expect(tooltip).toHaveClass(/sampling-tooltip-below/);
|
|
185
|
+
|
|
186
|
+
const [tooltipBox, sectionBox, panelBox] = await Promise.all([
|
|
187
|
+
tooltip.boundingBox(),
|
|
188
|
+
page.locator("#sidePanelSectionSampling").boundingBox(),
|
|
189
|
+
page.locator("#sidePanel .side-panel-body").boundingBox(),
|
|
190
|
+
]);
|
|
191
|
+
expect(tooltipBox).toBeTruthy();
|
|
192
|
+
expect(sectionBox).toBeTruthy();
|
|
193
|
+
expect(panelBox).toBeTruthy();
|
|
194
|
+
const clippingTop = Math.max(0, sectionBox.y, panelBox.y);
|
|
195
|
+
const clippingBottom = Math.min(620, sectionBox.y + sectionBox.height, panelBox.y + panelBox.height);
|
|
196
|
+
expect(tooltipBox.y).toBeGreaterThanOrEqual(clippingTop - 1);
|
|
197
|
+
expect(tooltipBox.y + tooltipBox.height).toBeLessThanOrEqual(clippingBottom + 1);
|
|
198
|
+
expect(tooltipBox.x).toBeGreaterThanOrEqual(panelBox.x - 1);
|
|
199
|
+
expect(tooltipBox.x + tooltipBox.width).toBeLessThanOrEqual(panelBox.x + panelBox.width + 1);
|
|
200
|
+
|
|
201
|
+
await page.mouse.move(tooltipBox.x + tooltipBox.width / 2, tooltipBox.y + tooltipBox.height / 2);
|
|
202
|
+
await expect.poll(() => tooltipVisualState(tooltip)).toMatchObject({ visuallyShown: true, pointerEvents: "auto" });
|
|
203
|
+
await page.keyboard.press("Escape");
|
|
204
|
+
await expect(row).toHaveClass(/sampling-tooltip-dismissed/);
|
|
205
|
+
await expect.poll(() => tooltipVisualState(tooltip)).toMatchObject({ visuallyShown: false, pointerEvents: "none" });
|
|
206
|
+
|
|
207
|
+
await page.mouse.move(20, 20);
|
|
208
|
+
await expect(row).toHaveClass(/sampling-tooltip-dismissed/);
|
|
209
|
+
await row.hover();
|
|
210
|
+
await expect(row).not.toHaveClass(/sampling-tooltip-dismissed/);
|
|
211
|
+
await expect.poll(() => tooltipVisualState(tooltip)).toMatchObject({ visuallyShown: true });
|
|
212
|
+
|
|
213
|
+
await page.mouse.move(20, 20);
|
|
214
|
+
await row.focus();
|
|
215
|
+
await expect(row).toBeFocused();
|
|
216
|
+
await expect.poll(() => tooltipVisualState(tooltip)).toMatchObject({ visuallyShown: true });
|
|
217
|
+
await page.keyboard.press("Escape");
|
|
218
|
+
await expect(row).toHaveClass(/sampling-tooltip-dismissed/);
|
|
219
|
+
await expect.poll(() => tooltipVisualState(tooltip)).toMatchObject({ visuallyShown: false });
|
|
220
|
+
await toggle.focus();
|
|
221
|
+
await expect(row).not.toHaveClass(/sampling-tooltip-dismissed/);
|
|
222
|
+
await row.focus();
|
|
223
|
+
await expect.poll(() => tooltipVisualState(tooltip)).toMatchObject({ visuallyShown: true });
|
|
224
|
+
|
|
225
|
+
const contrast = await computedUnsupportedLabelContrast(row);
|
|
226
|
+
console.log(`unsupported sampling label computed contrast: ${contrast.toFixed(2)}:1`);
|
|
227
|
+
expect(contrast, `unsupported label computed contrast was ${contrast.toFixed(2)}:1`).toBeGreaterThanOrEqual(4.5);
|
|
228
|
+
});
|