Skip to content

Commit aa78345

Browse files
committed
chore: revert lint script adjustments
Restore upstream lint/format scripts and revert incidental lint-driven edits.
1 parent cbab5b5 commit aa78345

File tree

3 files changed

+10
-29
lines changed

3 files changed

+10
-29
lines changed

components/multimodal-input.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import {
1111
type SetStateAction,
1212
useCallback,
1313
useEffect,
14+
useMemo,
1415
useRef,
1516
useState,
1617
} from "react";

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
"dev": "next dev --turbo",
77
"build": "tsx lib/db/migrate && next build",
88
"start": "next start",
9-
"lint": "pnpm exec ultracite check",
10-
"format": "pnpm exec ultracite fix",
9+
"lint": "npx ultracite@latest check",
10+
"format": "npx ultracite@latest fix",
1111
"db:generate": "drizzle-kit generate",
1212
"db:migrate": "npx tsx lib/db/migrate.ts",
1313
"db:studio": "drizzle-kit studio",

tests/e2e/model-selector.test.ts

Lines changed: 7 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -9,29 +9,20 @@ test.describe("Model Selector", () => {
99

1010
test("displays a model button", async ({ page }) => {
1111
// Look for any button with model-related content
12-
const modelButton = page
13-
.locator("button")
14-
.filter({ hasText: MODEL_BUTTON_REGEX })
15-
.first();
12+
const modelButton = page.locator("button").filter({ hasText: MODEL_BUTTON_REGEX }).first();
1613
await expect(modelButton).toBeVisible();
1714
});
1815

1916
test("opens model selector popover on click", async ({ page }) => {
20-
const modelButton = page
21-
.locator("button")
22-
.filter({ hasText: MODEL_BUTTON_REGEX })
23-
.first();
17+
const modelButton = page.locator("button").filter({ hasText: MODEL_BUTTON_REGEX }).first();
2418
await modelButton.click();
2519

2620
// Search input should be visible in the popover
2721
await expect(page.getByPlaceholder("Search models...")).toBeVisible();
2822
});
2923

3024
test("can search for models", async ({ page }) => {
31-
const modelButton = page
32-
.locator("button")
33-
.filter({ hasText: MODEL_BUTTON_REGEX })
34-
.first();
25+
const modelButton = page.locator("button").filter({ hasText: MODEL_BUTTON_REGEX }).first();
3526
await modelButton.click();
3627

3728
const searchInput = page.getByPlaceholder("Search models...");
@@ -42,10 +33,7 @@ test.describe("Model Selector", () => {
4233
});
4334

4435
test("can close model selector by clicking outside", async ({ page }) => {
45-
const modelButton = page
46-
.locator("button")
47-
.filter({ hasText: MODEL_BUTTON_REGEX })
48-
.first();
36+
const modelButton = page.locator("button").filter({ hasText: MODEL_BUTTON_REGEX }).first();
4937
await modelButton.click();
5038

5139
await expect(page.getByPlaceholder("Search models...")).toBeVisible();
@@ -57,10 +45,7 @@ test.describe("Model Selector", () => {
5745
});
5846

5947
test("shows model provider groups", async ({ page }) => {
60-
const modelButton = page
61-
.locator("button")
62-
.filter({ hasText: MODEL_BUTTON_REGEX })
63-
.first();
48+
const modelButton = page.locator("button").filter({ hasText: MODEL_BUTTON_REGEX }).first();
6449
await modelButton.click();
6550

6651
// Should show provider group headers
@@ -69,10 +54,7 @@ test.describe("Model Selector", () => {
6954
});
7055

7156
test("can select a different model", async ({ page }) => {
72-
const modelButton = page
73-
.locator("button")
74-
.filter({ hasText: MODEL_BUTTON_REGEX })
75-
.first();
57+
const modelButton = page.locator("button").filter({ hasText: MODEL_BUTTON_REGEX }).first();
7658
await modelButton.click();
7759

7860
// Select a specific model
@@ -82,8 +64,6 @@ test.describe("Model Selector", () => {
8264
await expect(page.getByPlaceholder("Search models...")).not.toBeVisible();
8365

8466
// Model button should now show the selected model
85-
await expect(
86-
page.locator("button").filter({ hasText: "Claude Haiku" }).first()
87-
).toBeVisible();
67+
await expect(page.locator("button").filter({ hasText: "Claude Haiku" }).first()).toBeVisible();
8868
});
8969
});

0 commit comments

Comments
 (0)