{link.href}
- {onPreview && !restriction ? : null} - {t("webPreview.external")} - - {restriction ?{t(`webPreview.${restriction}`)}
: null} - {feedback ?{t(`webPreview.${feedback}`)}
: null} -{t(`webPreview.${restriction}`)}
: null} - {feedback === "copyFailed" ?{url?.href}
-{t("webPreview.isolated")}
-{t("webPreview.blockedHint")}
- {loopback ?{t("webPreview.loopback")}
: null} -这段内容来自当前示例的本地文档。
点击顶部 刷新 按钮,重新显示文档;打开信息按钮查看隔离说明。
{t("previews.webPreview.refreshes", { amount: revision })}
-
-
{t("previews.webLinks.hint")}
-Preview
Preview
diff --git a/webui/src/tests/temporary-chat-navigation.test.tsx b/webui/src/tests/temporary-chat-navigation.test.tsx index b3ebce5df..74ad9b988 100644 --- a/webui/src/tests/temporary-chat-navigation.test.tsx +++ b/webui/src/tests/temporary-chat-navigation.test.tsx @@ -1,4 +1,3 @@ -// @vitest-environment-options {"settings":{"disableIframePageLoading":true}} import { act, cleanup, fireEvent, render, screen, waitFor, within } from "@testing-library/react"; import { afterEach, beforeAll, beforeEach, describe, expect, it, vi } from "vitest"; @@ -11,7 +10,6 @@ import { canonicalThreadPayload } from "./thread-test-payload"; let groupedTopics = false; let withFiles = false; -const credentialless = Object.getOwnPropertyDescriptor(HTMLIFrameElement.prototype, "credentialless"); const previewFile = (path: string) => ({ path: `/workspace/${path}`, display_path: path, project_path: "/workspace", language: "text", content: `Preview of ${path}`, size: 20, truncated: false, @@ -151,8 +149,6 @@ describe("temporary chat navigation", () => { afterEach(() => { cleanup(); - if (credentialless) Object.defineProperty(HTMLIFrameElement.prototype, "credentialless", credentialless); - else Reflect.deleteProperty(HTMLIFrameElement.prototype, "credentialless"); if (vi.isFakeTimers()) vi.clearAllTimers(); vi.useRealTimers(); vi.restoreAllMocks(); @@ -323,53 +319,6 @@ describe("temporary chat navigation", () => { } }); - it("restores website targets per session, switches to files, and closes below menus", async () => { - // Exercise the working embed path; unsupported browsers do not offer it. - Object.defineProperty(HTMLIFrameElement.prototype, "credentialless", { configurable: true, value: false }); - withFiles = true; - render(