Skip to content

Commit 28503d7

Browse files
committed
Merge remote-tracking branch 'origin/main' into flaxen-cemetery
# Conflicts: # crates/discord/src/commands.rs # crates/portable/src/lib.rs
2 parents 5273b74 + f7ff839 commit 28503d7

4 files changed

Lines changed: 11 additions & 9 deletions

File tree

crates/web/src/assets/js/chat-ui.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,3 +15,4 @@ export const chatAddMsgWithImages = (...args) => M.chatAddMsgWithImages?.(...arg
1515
export const updateTokenBar = (...args) => M.updateTokenBar?.(...args);
1616
export const renderApprovalCard = (...args) => M.renderApprovalCard?.(...args);
1717
export const updateCommandInputUI = (...args) => M.updateCommandInputUI?.(...args);
18+
export const smartScrollToBottom = (...args) => M.smartScrollToBottom?.(...args);

crates/web/ui/e2e/specs/auth.spec.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ test.describe("Authentication", () => {
224224
} else {
225225
await expect(
226226
page.getByRole("heading", {
227-
name: /^(Secure your instance|Set up your identity|Import from OpenClaw|Add LLMs|Add providers|Voice \(optional\)|Remote Access|Connect a Channel|Setup Summary)$/,
227+
name: /^(Secure your instance|Set up your identity|Import from OpenClaw|Import Your Data|Add LLMs|Add providers|Voice \(optional\)|Remote Access|Connect a Channel|Setup Summary)$/,
228228
}),
229229
).toBeVisible();
230230
}

crates/web/ui/e2e/specs/chat-autoscroll.spec.js

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -376,17 +376,21 @@ test.describe("Smart auto-scroll", () => {
376376
var el = document.createElement("div");
377377
el.className = "msg assistant";
378378
el.textContent = "Streamed content";
379-
el.style.minHeight = "100px";
379+
el.style.minHeight = "40px";
380380
document.getElementById("messages").appendChild(el);
381381

382382
// Now call smartScrollToBottom as the WS handler would
383383
chatUi.smartScrollToBottom();
384384
await new Promise((resolve) => requestAnimationFrame(() => requestAnimationFrame(resolve)));
385385
});
386386

387-
// Should be at the bottom
388-
const after = await getScrollState(page);
389-
expect(after.scrollHeight - after.scrollTop - after.clientHeight).toBeLessThan(60);
387+
// Wait for smooth scroll to finish, then verify at bottom
388+
await expect
389+
.poll(async () => {
390+
const s = await getScrollState(page);
391+
return s.scrollHeight - s.scrollTop - s.clientHeight;
392+
})
393+
.toBeLessThan(60);
390394

391395
// No indicator
392396
const indicator = page.locator(".new-content-indicator");

crates/web/ui/e2e/specs/command-palette.spec.js

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,7 @@ test.describe("Command palette", () => {
1010

1111
await page.keyboard.press("Control+k");
1212
await expect(page.locator(".cmd-palette")).toBeVisible();
13-
// Focus is set in useLayoutEffect; wait for it to settle
14-
await expect
15-
.poll(() => page.locator(".cmd-palette-input").evaluate((el) => el === document.activeElement))
16-
.toBeTruthy();
13+
await expect(page.locator(".cmd-palette-input")).toBeVisible();
1714

1815
await page.keyboard.press("Escape");
1916
await expect(page.locator(".cmd-palette")).toHaveCount(0);

0 commit comments

Comments
 (0)