Open instance in new tab as full page, not embed shell.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
dekun
2026-06-25 22:47:02 +08:00
parent 5cf88818c1
commit ee011800e1
2 changed files with 15 additions and 7 deletions
+2 -2
View File
@@ -418,7 +418,7 @@
const next = nextPath || "/";
const q = new URLSearchParams({ exchange_id: String(exchangeId), next });
if (options.embed) q.set("embed", "1");
if (globalThis.HubTheme && typeof HubTheme.get === "function") {
if (options.embed && globalThis.HubTheme && typeof HubTheme.get === "function") {
q.set("hub_theme", HubTheme.get());
}
const r = await apiFetch("/api/instance/open-url?" + q.toString());
@@ -456,7 +456,7 @@
try {
const embedded = isHubEmbedded();
const url = await fetchInstanceOpenUrl(exchangeId, next, {
embed: embedded || !newTab,
embed: !newTab,
});
if (newTab) {
window.open(url, "_blank", "noopener");