Compare commits

...
Author SHA1 Message Date
Cline Evaluation f4e6c620d4 Fixes types for webview building 2025-05-14 03:04:28 +04:00
2 changed files with 3 additions and 4 deletions
@@ -120,7 +120,7 @@ describe("ApiOptions Component", () => {
const mockPostMessage = vi.fn()
beforeEach(() => {
global.vscode = { postMessage: mockPostMessage } as any
;(global as any).vscode = { postMessage: mockPostMessage }
})
it("renders Fireworks API Key input", () => {
@@ -167,7 +167,7 @@ describe("ApiOptions Component", () => {
vi.mock("../../../context/ExtensionStateContext", async (importOriginal) => {
const actual = await importOriginal()
return {
...actual,
...(actual || {}),
// your mocked methods
useExtensionState: vi.fn(() => ({
apiConfiguration: {
+1 -2
View File
@@ -1,6 +1,5 @@
import { mentionRegex } from "@shared/context-mentions"
import { Fzf } from "fzf"
import * as path from "path"
export interface SearchResult {
path: string
@@ -193,7 +192,7 @@ export function getContextMenuOptions(
const item = {
type: result.type === "folder" ? ContextMenuOptionType.Folder : ContextMenuOptionType.File,
value: formattedPath,
label: result.label || path.basename(result.path),
label: result.label || result.path.split("/").pop() || result.path,
description: formattedPath,
}
return item