@quanta-intellect/vessel-browser 0.1.68 → 0.1.71

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1435,6 +1435,7 @@ function Dynamic(props) {
1435
1435
  }
1436
1436
  var _tmpl$$i = /* @__PURE__ */ template(`<div class=title-bar><div class=title-bar-drag></div><div class=mcp-status-area><button class=mcp-status-indicator><span class=mcp-dot></span><span class=mcp-label>MCP</span></button></div><div class=window-controls><button class=window-btn data-tooltip=Minimize><svg width=10 height=10 viewBox="0 0 10 10"><rect x=1 y=5 width=8 height=1 fill=currentColor></rect></svg></button><button class=window-btn data-tooltip=Maximize><svg width=10 height=10 viewBox="0 0 10 10"><rect x=1 y=1 width=8 height=8 fill=none stroke=currentColor stroke-width=1></rect></svg></button><button class="window-btn window-btn-close"data-tooltip=Close><svg width=10 height=10 viewBox="0 0 10 10"><line x1=1 y1=1 x2=9 y2=9 stroke=currentColor stroke-width=1.2></line><line x1=9 y1=1 x2=1 y2=9 stroke=currentColor stroke-width=1.2>`);
1437
1437
  const TitleBar = () => {
1438
+ const isPrivateWindow = new URLSearchParams(window.location.search).get("private") === "1";
1438
1439
  const [mcpStatus, setMcpStatus] = createSignal("starting");
1439
1440
  const [mcpTooltip, setMcpTooltip] = createSignal("MCP: starting...");
1440
1441
  const applyHealth = (health) => {
@@ -1461,6 +1462,7 @@ const TitleBar = () => {
1461
1462
  onCleanup(unsubscribe);
1462
1463
  });
1463
1464
  const handleMcpClick = () => {
1465
+ if (isPrivateWindow) return;
1464
1466
  window.vessel.ui.setSettingsVisibility(true);
1465
1467
  };
1466
1468
  return (() => {
@@ -1594,7 +1596,12 @@ function useTabs() {
1594
1596
  patchTab(id, { adBlockingEnabled: newState });
1595
1597
  }
1596
1598
  return newState;
1597
- }
1599
+ },
1600
+ zoomIn: (id) => window.vessel.tabs.zoomIn(id),
1601
+ zoomOut: (id) => window.vessel.tabs.zoomOut(id),
1602
+ zoomReset: (id) => window.vessel.tabs.zoomReset(id),
1603
+ reopenClosed: () => window.vessel.tabs.reopenClosed(),
1604
+ duplicate: (id) => window.vessel.tabs.duplicate(id)
1598
1605
  };
1599
1606
  }
1600
1607
  const [now, setNow] = createSignal(Date.now());
@@ -1773,7 +1780,7 @@ function getAgentPresence(state, currentTime = Date.now()) {
1773
1780
  }
1774
1781
  return "idle";
1775
1782
  }
1776
- var _tmpl$$h = /* @__PURE__ */ template(`<img class=tab-favicon alt>`), _tmpl$2$f = /* @__PURE__ */ template(`<span class=tab-favicon-fallback>`), _tmpl$3$c = /* @__PURE__ */ template(`<div class=tab-bar><div class=tab-list><button class=tab-new data-tooltip="New Tab">+`), _tmpl$4$c = /* @__PURE__ */ template(`<div role=tab><span class=tab-title></span><button class=tab-close>×`), _tmpl$5$b = /* @__PURE__ */ template(`<span class=tab-agent-indicator aria-hidden=true title="Agent active on this tab">`), _tmpl$6$a = /* @__PURE__ */ template(`<span class=tab-loading>`);
1783
+ var _tmpl$$h = /* @__PURE__ */ template(`<img class=tab-favicon alt>`), _tmpl$2$f = /* @__PURE__ */ template(`<span class=tab-favicon-fallback>`), _tmpl$3$c = /* @__PURE__ */ template(`<div class=tab-bar><div class=tab-list></div><div class=tab-actions><button class=tab-new data-tooltip="New tab"data-tooltip-pos=left>+</button><button class="tab-new tab-new-private"data-tooltip="Private window"data-tooltip-pos=left><svg width=12 height=12 viewBox="0 0 16 16"fill=currentColor><path d="M8 1a7 7 0 100 14A7 7 0 008 1zm0 1.5a5.5 5.5 0 110 11 5.5 5.5 0 010-11z">`), _tmpl$4$c = /* @__PURE__ */ template(`<div role=tab><span class=tab-title></span><button class=tab-close>×`), _tmpl$5$b = /* @__PURE__ */ template(`<span class=tab-agent-indicator aria-hidden=true title="Agent active on this tab">`), _tmpl$6$a = /* @__PURE__ */ template(`<span class=tab-loading>`);
1777
1784
  const TAB_CLOSE_MS = 200;
1778
1785
  function stringToHue(str) {
1779
1786
  let hash = 0;
@@ -1840,18 +1847,22 @@ const TabBar = () => {
1840
1847
  }, TAB_CLOSE_MS);
1841
1848
  };
1842
1849
  return (() => {
1843
- var _el$3 = _tmpl$3$c(), _el$4 = _el$3.firstChild, _el$5 = _el$4.firstChild;
1850
+ var _el$3 = _tmpl$3$c(), _el$4 = _el$3.firstChild, _el$5 = _el$4.nextSibling, _el$6 = _el$5.firstChild, _el$7 = _el$6.nextSibling;
1844
1851
  insert(_el$4, createComponent(For, {
1845
1852
  get each() {
1846
1853
  return tabs2();
1847
1854
  },
1848
1855
  children: (tab) => (() => {
1849
- var _el$6 = _tmpl$4$c(), _el$7 = _el$6.firstChild, _el$8 = _el$7.nextSibling;
1850
- _el$6.addEventListener("auxclick", (e) => {
1856
+ var _el$8 = _tmpl$4$c(), _el$9 = _el$8.firstChild, _el$0 = _el$9.nextSibling;
1857
+ _el$8.$$contextmenu = (e) => {
1858
+ e.preventDefault();
1859
+ window.vessel.tabs.showContextMenu(tab.id);
1860
+ };
1861
+ _el$8.addEventListener("auxclick", (e) => {
1851
1862
  if (e.button === 1) handleClose(tab.id);
1852
1863
  });
1853
- _el$6.$$click = () => switchTab(tab.id);
1854
- insert(_el$6, createComponent(TabFavicon, {
1864
+ _el$8.$$click = () => switchTab(tab.id);
1865
+ insert(_el$8, createComponent(TabFavicon, {
1855
1866
  get favicon() {
1856
1867
  return tab.favicon;
1857
1868
  },
@@ -1861,39 +1872,40 @@ const TabBar = () => {
1861
1872
  get url() {
1862
1873
  return tab.url;
1863
1874
  }
1864
- }), _el$7);
1865
- insert(_el$6, (() => {
1875
+ }), _el$9);
1876
+ insert(_el$8, (() => {
1866
1877
  var _c$ = memo(() => !!modelActiveTabIds().has(tab.id));
1867
1878
  return () => _c$() && _tmpl$5$b();
1868
- })(), _el$7);
1869
- insert(_el$7, () => tab.title || "New Tab");
1870
- insert(_el$6, (() => {
1879
+ })(), _el$9);
1880
+ insert(_el$9, () => tab.title || "New Tab");
1881
+ insert(_el$8, (() => {
1871
1882
  var _c$2 = memo(() => !!tab.isLoading);
1872
1883
  return () => _c$2() && _tmpl$6$a();
1873
- })(), _el$8);
1874
- _el$8.$$click = (e) => {
1884
+ })(), _el$0);
1885
+ _el$0.$$click = (e) => {
1875
1886
  e.stopPropagation();
1876
1887
  handleClose(tab.id);
1877
1888
  };
1878
1889
  createRenderEffect((_p$) => {
1879
1890
  var _v$ = `tab-item ${tab.id === activeTabId2() ? "active" : ""} ${modelActiveTabIds().has(tab.id) ? "model-active" : ""}`, _v$2 = !!closingTabIds().has(tab.id), _v$3 = modelActiveTabIds().has(tab.id) ? `${tab.title || "New Tab"} • Agent active` : tab.title;
1880
- _v$ !== _p$.e && className(_el$6, _p$.e = _v$);
1881
- _v$2 !== _p$.t && _el$6.classList.toggle("closing", _p$.t = _v$2);
1882
- _v$3 !== _p$.a && setAttribute(_el$6, "title", _p$.a = _v$3);
1891
+ _v$ !== _p$.e && className(_el$8, _p$.e = _v$);
1892
+ _v$2 !== _p$.t && _el$8.classList.toggle("closing", _p$.t = _v$2);
1893
+ _v$3 !== _p$.a && setAttribute(_el$8, "title", _p$.a = _v$3);
1883
1894
  return _p$;
1884
1895
  }, {
1885
1896
  e: void 0,
1886
1897
  t: void 0,
1887
1898
  a: void 0
1888
1899
  });
1889
- return _el$6;
1900
+ return _el$8;
1890
1901
  })()
1891
- }), _el$5);
1892
- _el$5.$$click = () => createTab();
1902
+ }));
1903
+ _el$6.$$click = () => createTab();
1904
+ _el$7.$$click = () => window.vessel.tabs.openPrivateWindow();
1893
1905
  return _el$3;
1894
1906
  })();
1895
1907
  };
1896
- delegateEvents(["click"]);
1908
+ delegateEvents(["click", "contextmenu"]);
1897
1909
  const DEFAULT_SIDEBAR_WIDTH = 400;
1898
1910
  const MIN_SIDEBAR = 240;
1899
1911
  const MAX_SIDEBAR = 800;
@@ -1964,6 +1976,82 @@ function useUI() {
1964
1976
  }
1965
1977
  };
1966
1978
  }
1979
+ const logger$3 = createLogger("HistoryStore");
1980
+ const INITIAL$1 = { entries: [] };
1981
+ const [historyState, setHistoryState] = createSignal(INITIAL$1);
1982
+ let initialized$2 = false;
1983
+ let initPromise$1 = null;
1984
+ async function init$2() {
1985
+ if (initPromise$1) return initPromise$1;
1986
+ if (initialized$2) return;
1987
+ initialized$2 = true;
1988
+ initPromise$1 = (async () => {
1989
+ try {
1990
+ const state = await window.vessel.history.get();
1991
+ setHistoryState(state);
1992
+ window.vessel.history.onUpdate((s) => setHistoryState(s));
1993
+ } catch (error) {
1994
+ initialized$2 = false;
1995
+ logger$3.error("Failed to initialize history store:", error);
1996
+ } finally {
1997
+ initPromise$1 = null;
1998
+ }
1999
+ })();
2000
+ return initPromise$1;
2001
+ }
2002
+ function useHistory() {
2003
+ void init$2();
2004
+ return {
2005
+ historyState,
2006
+ search: (query) => window.vessel.history.search(query),
2007
+ clear: () => window.vessel.history.clear()
2008
+ };
2009
+ }
2010
+ const logger$2 = createLogger("BookmarksStore");
2011
+ const INITIAL = { folders: [], bookmarks: [] };
2012
+ const [bookmarksState, setBookmarksState] = createSignal(INITIAL);
2013
+ let initialized$1 = false;
2014
+ let initPromise = null;
2015
+ async function init$1() {
2016
+ if (initPromise) return initPromise;
2017
+ if (initialized$1) return;
2018
+ initialized$1 = true;
2019
+ initPromise = (async () => {
2020
+ try {
2021
+ const state = await window.vessel.bookmarks.get();
2022
+ setBookmarksState(state);
2023
+ window.vessel.bookmarks.onUpdate((s) => setBookmarksState(s));
2024
+ } catch (error) {
2025
+ initialized$1 = false;
2026
+ logger$2.error("Failed to initialize bookmarks store:", error);
2027
+ } finally {
2028
+ initPromise = null;
2029
+ }
2030
+ })();
2031
+ return initPromise;
2032
+ }
2033
+ function useBookmarks() {
2034
+ void init$1();
2035
+ return {
2036
+ bookmarksState,
2037
+ saveBookmark: (url, title, folderId, note, intent, expectedContent, keyFields, agentHints) => window.vessel.bookmarks.saveBookmark(
2038
+ url,
2039
+ title,
2040
+ folderId,
2041
+ note,
2042
+ intent,
2043
+ expectedContent,
2044
+ keyFields,
2045
+ agentHints
2046
+ ),
2047
+ updateBookmark: (id, updates) => window.vessel.bookmarks.updateBookmark(id, updates),
2048
+ removeBookmark: (id) => window.vessel.bookmarks.removeBookmark(id),
2049
+ createFolder: (name) => window.vessel.bookmarks.createFolder(name),
2050
+ createFolderWithSummary: (name, summary) => window.vessel.bookmarks.createFolderWithSummary(name, summary),
2051
+ removeFolder: (id, deleteContents) => window.vessel.bookmarks.removeFolder(id, deleteContents),
2052
+ renameFolder: (id, newName, summary) => window.vessel.bookmarks.renameFolder(id, newName, summary)
2053
+ };
2054
+ }
1967
2055
  function normalizePageUrl(rawUrl) {
1968
2056
  try {
1969
2057
  const url = new URL(rawUrl);
@@ -2078,7 +2166,15 @@ function buildPageSnapshotKey(rawUrl) {
2078
2166
  function matchesPageSnapshotUrl(left, right) {
2079
2167
  return buildPageSnapshotKey(left) === buildPageSnapshotKey(right);
2080
2168
  }
2081
- var _tmpl$$g = /* @__PURE__ */ template(`<button class="agent-status-badge recent"title="Open the What Changed timeline"style=cursor:pointer;font-size:11px><span class=agent-status-dot aria-hidden=true style=background:#f59e0b></span><span class=agent-status-text>What Changed?`), _tmpl$2$e = /* @__PURE__ */ template(`<span class=page-diff-burst-meta>Updated <!> times over `), _tmpl$3$b = /* @__PURE__ */ template(`<div class=page-diff-burst-history><div class=page-diff-burst-history-label>Changed recently`), _tmpl$4$b = /* @__PURE__ */ template(`<div class=page-diff-popup><div class=page-diff-popup-header><div class=page-diff-popup-header-copy><span>What changed since </span></div><div style=display:flex;gap:8px;align-items:center><button class=nav-btn title="Open the full What Changed timeline"style="height:24px;min-width:auto;padding:0 8px">Timeline</button><button class=page-diff-popup-close>&times;`), _tmpl$5$a = /* @__PURE__ */ template(`<svg><path d="M3 3 L11 3 L11 9 Q7 13 3 9 Z"fill=none stroke=currentColor stroke-width=1.2 stroke-linejoin=round></svg>`, false, true, false), _tmpl$6$9 = /* @__PURE__ */ template(`<svg><line x1=2 y1=12 x2=12 y2=2 stroke=currentColor stroke-width=1.4 stroke-linecap=round></svg>`, false, true, false), _tmpl$7$7 = /* @__PURE__ */ template(`<span class=nav-btn-badge>`), _tmpl$8$5 = /* @__PURE__ */ template(`<div class=address-bar><div class=nav-controls><button class=nav-btn data-tooltip=Back><svg width=14 height=14 viewBox="0 0 14 14"><path d="M9 2L4 7l5 5"fill=none stroke=currentColor stroke-width=1.5 stroke-linecap=round stroke-linejoin=round></path></svg></button><button class=nav-btn data-tooltip=Forward><svg width=14 height=14 viewBox="0 0 14 14"><path d="M5 2l5 5-5 5"fill=none stroke=currentColor stroke-width=1.5 stroke-linecap=round stroke-linejoin=round></path></svg></button><button class=nav-btn data-tooltip=Reload><svg width=14 height=14 viewBox="0 0 14 14"><path d="M2.5 7a4.5 4.5 0 1 1 1 3"fill=none stroke=currentColor stroke-width=1.5 stroke-linecap=round></path><path d="M2 4v3.5h3.5"fill=none stroke=currentColor stroke-width=1.5 stroke-linecap=round stroke-linejoin=round></path></svg></button></div><div class=url-shell><form class=url-form><input class=url-input type=text placeholder="Search or enter URL"></form><div><span class=agent-status-dot aria-hidden=true></span><span class=agent-status-text></span></div></div><div class=toolbar-actions><button class=nav-btn><svg width=14 height=14 viewBox="0 0 14 14"></svg></button><button class=nav-btn data-tooltip="Reader Mode"><svg width=14 height=14 viewBox="0 0 14 14"><rect x=2 y=1 width=10 height=12 rx=1 fill=none stroke=currentColor stroke-width=1.2></rect><line x1=4 y1=4 x2=10 y2=4 stroke=currentColor stroke-width=1></line><line x1=4 y1=6.5 x2=10 y2=6.5 stroke=currentColor stroke-width=1></line><line x1=4 y1=9 x2=8 y2=9 stroke=currentColor stroke-width=1></line></svg></button><button class=nav-btn data-tooltip="Dev Tools"><svg width=14 height=14 viewBox="0 0 14 14"><polyline points="3,5 1,7 3,9"fill=none stroke=currentColor stroke-width=1.2 stroke-linecap=round stroke-linejoin=round></polyline><polyline points="11,5 13,7 11,9"fill=none stroke=currentColor stroke-width=1.2 stroke-linecap=round stroke-linejoin=round></polyline><line x1=8.5 y1=2 x2=5.5 y2=12 stroke=currentColor stroke-width=1.2 stroke-linecap=round></line></svg></button><button class="nav-btn nav-btn-sidebar"><svg width=14 height=14 viewBox="0 0 14 14"><rect x=1 y=1 width=12 height=12 rx=1.5 fill=none stroke=currentColor stroke-width=1.2></rect><line x1=9 y1=1 x2=9 y2=13 stroke=currentColor stroke-width=1.2></line></svg></button><button class=nav-btn data-tooltip=Settings><svg width=14 height=14 viewBox="0 0 14 14"><circle cx=7 cy=7 r=2 fill=none stroke=currentColor stroke-width=1.2></circle><path d="M7 1v2M7 11v2M1 7h2M11 7h2M2.8 2.8l1.4 1.4M9.8 9.8l1.4 1.4M11.2 2.8l-1.4 1.4M4.2 9.8l-1.4 1.4"stroke=currentColor stroke-width=1 stroke-linecap=round>`), _tmpl$9$4 = /* @__PURE__ */ template(`<div class=page-diff-burst-row><span class=page-diff-burst-time></span><span class=page-diff-burst-summary>`), _tmpl$0$4 = /* @__PURE__ */ template(`<div class=page-diff-snippet><span class=page-diff-snippet-label>Before</span><span class=page-diff-snippet-text>`), _tmpl$1$4 = /* @__PURE__ */ template(`<div class=page-diff-snippet><span class=page-diff-snippet-label>After</span><span class=page-diff-snippet-text>`), _tmpl$10$4 = /* @__PURE__ */ template(`<div class=page-diff-snippets>`), _tmpl$11$4 = /* @__PURE__ */ template(`<div class=page-diff-list-group><span class=page-diff-list-label>Added</span><ul class=page-diff-list>`), _tmpl$12$4 = /* @__PURE__ */ template(`<div class=page-diff-list-group><span class=page-diff-list-label>Removed</span><ul class=page-diff-list>`), _tmpl$13$3 = /* @__PURE__ */ template(`<div><div class=page-diff-item-header><span class=page-diff-section></span><span class=page-diff-summary>`), _tmpl$14$3 = /* @__PURE__ */ template(`<li>`);
2169
+ const SEARCH_ENGINE_PRESETS = {
2170
+ duckduckgo: { label: "DuckDuckGo", url: "https://duckduckgo.com/?q=" },
2171
+ google: { label: "Google", url: "https://www.google.com/search?q=" },
2172
+ bing: { label: "Bing", url: "https://www.bing.com/search?q=" },
2173
+ brave: { label: "Brave Search", url: "https://search.brave.com/search?q=" },
2174
+ ecosia: { label: "Ecosia", url: "https://www.ecosia.org/search?q=" },
2175
+ kagi: { label: "Kagi", url: "https://kagi.com/search?q=" }
2176
+ };
2177
+ var _tmpl$$g = /* @__PURE__ */ template(`<div class=private-badge title="Private Browsing - history and cookies are not saved"><svg width=12 height=12 viewBox="0 0 16 16"fill=currentColor><path d="M8 1a7 7 0 100 14A7 7 0 008 1zm0 1.5a5.5 5.5 0 110 11 5.5 5.5 0 010-11zM5.5 7a1.5 1.5 0 103 0 1.5 1.5 0 00-3 0zm3.5 3.5c0-1-1.5-2-2.5-2s-2.5 1-2.5 2"></path></svg><span>Private`), _tmpl$2$e = /* @__PURE__ */ template(`<div id=address-autocomplete class=autocomplete-dropdown role=listbox>`), _tmpl$3$b = /* @__PURE__ */ template(`<div><span class=agent-status-dot aria-hidden=true></span><span class=agent-status-text>`), _tmpl$4$b = /* @__PURE__ */ template(`<button class="agent-status-badge recent"title="Open the What Changed timeline"style=cursor:pointer;font-size:11px><span class=agent-status-dot aria-hidden=true style=background:#f59e0b></span><span class=agent-status-text>What Changed?`), _tmpl$5$a = /* @__PURE__ */ template(`<span class=page-diff-burst-meta>Updated <!> times over `), _tmpl$6$9 = /* @__PURE__ */ template(`<div class=page-diff-burst-history><div class=page-diff-burst-history-label>Changed recently`), _tmpl$7$7 = /* @__PURE__ */ template(`<div class=page-diff-popup><div class=page-diff-popup-header><div class=page-diff-popup-header-copy><span>What changed since </span></div><div style=display:flex;gap:8px;align-items:center><button class=nav-btn title="Open the full What Changed timeline"style="height:24px;min-width:auto;padding:0 8px">Timeline</button><button class=page-diff-popup-close>&times;`), _tmpl$8$5 = /* @__PURE__ */ template(`<svg><path d="M3 3 L11 3 L11 9 Q7 13 3 9 Z"fill=none stroke=currentColor stroke-width=1.2 stroke-linejoin=round></svg>`, false, true, false), _tmpl$9$4 = /* @__PURE__ */ template(`<svg><line x1=2 y1=12 x2=12 y2=2 stroke=currentColor stroke-width=1.4 stroke-linecap=round></svg>`, false, true, false), _tmpl$0$4 = /* @__PURE__ */ template(`<button class=nav-btn data-tooltip="Reader Mode"><svg width=14 height=14 viewBox="0 0 14 14"><rect x=2 y=1 width=10 height=12 rx=1 fill=none stroke=currentColor stroke-width=1.2></rect><line x1=4 y1=4 x2=10 y2=4 stroke=currentColor stroke-width=1></line><line x1=4 y1=6.5 x2=10 y2=6.5 stroke=currentColor stroke-width=1></line><line x1=4 y1=9 x2=8 y2=9 stroke=currentColor stroke-width=1>`), _tmpl$1$4 = /* @__PURE__ */ template(`<button class=nav-btn data-tooltip="Dev Tools"><svg width=14 height=14 viewBox="0 0 14 14"><polyline points="3,5 1,7 3,9"fill=none stroke=currentColor stroke-width=1.2 stroke-linecap=round stroke-linejoin=round></polyline><polyline points="11,5 13,7 11,9"fill=none stroke=currentColor stroke-width=1.2 stroke-linecap=round stroke-linejoin=round></polyline><line x1=8.5 y1=2 x2=5.5 y2=12 stroke=currentColor stroke-width=1.2 stroke-linecap=round>`), _tmpl$10$4 = /* @__PURE__ */ template(`<span class=nav-btn-badge>`), _tmpl$11$4 = /* @__PURE__ */ template(`<button class="nav-btn nav-btn-sidebar"><svg width=14 height=14 viewBox="0 0 14 14"><rect x=1 y=1 width=12 height=12 rx=1.5 fill=none stroke=currentColor stroke-width=1.2></rect><line x1=9 y1=1 x2=9 y2=13 stroke=currentColor stroke-width=1.2>`), _tmpl$12$4 = /* @__PURE__ */ template(`<button class=nav-btn data-tooltip=Settings><svg width=14 height=14 viewBox="0 0 14 14"><circle cx=7 cy=7 r=2 fill=none stroke=currentColor stroke-width=1.2></circle><path d="M7 1v2M7 11v2M1 7h2M11 7h2M2.8 2.8l1.4 1.4M9.8 9.8l1.4 1.4M11.2 2.8l-1.4 1.4M4.2 9.8l-1.4 1.4"stroke=currentColor stroke-width=1 stroke-linecap=round>`), _tmpl$13$3 = /* @__PURE__ */ template(`<div class=address-bar><div class=nav-controls><button class=nav-btn data-tooltip=Back><svg width=14 height=14 viewBox="0 0 14 14"><path d="M9 2L4 7l5 5"fill=none stroke=currentColor stroke-width=1.5 stroke-linecap=round stroke-linejoin=round></path></svg></button><button class=nav-btn data-tooltip=Forward><svg width=14 height=14 viewBox="0 0 14 14"><path d="M5 2l5 5-5 5"fill=none stroke=currentColor stroke-width=1.5 stroke-linecap=round stroke-linejoin=round></path></svg></button><button class=nav-btn data-tooltip=Reload><svg width=14 height=14 viewBox="0 0 14 14"><path d="M2.5 7a4.5 4.5 0 1 1 1 3"fill=none stroke=currentColor stroke-width=1.5 stroke-linecap=round></path><path d="M2 4v3.5h3.5"fill=none stroke=currentColor stroke-width=1.5 stroke-linecap=round stroke-linejoin=round></path></svg></button></div><div class=url-shell><form class=url-form><input class=url-input type=text placeholder="Search or enter URL"autocomplete=off aria-autocomplete=list aria-controls=address-autocomplete></form></div><div class=toolbar-actions><button class=nav-btn><svg width=14 height=14 viewBox="0 0 14 14">`), _tmpl$14$3 = /* @__PURE__ */ template(`<div role=option><span class=autocomplete-icon></span><span class=autocomplete-text><span class=autocomplete-title></span><span class=autocomplete-url>`), _tmpl$15$3 = /* @__PURE__ */ template(`<div class=page-diff-burst-row><span class=page-diff-burst-time></span><span class=page-diff-burst-summary>`), _tmpl$16$3 = /* @__PURE__ */ template(`<div class=page-diff-snippet><span class=page-diff-snippet-label>Before</span><span class=page-diff-snippet-text>`), _tmpl$17$3 = /* @__PURE__ */ template(`<div class=page-diff-snippet><span class=page-diff-snippet-label>After</span><span class=page-diff-snippet-text>`), _tmpl$18$3 = /* @__PURE__ */ template(`<div class=page-diff-snippets>`), _tmpl$19$3 = /* @__PURE__ */ template(`<div class=page-diff-list-group><span class=page-diff-list-label>Added</span><ul class=page-diff-list>`), _tmpl$20$3 = /* @__PURE__ */ template(`<div class=page-diff-list-group><span class=page-diff-list-label>Removed</span><ul class=page-diff-list>`), _tmpl$21$3 = /* @__PURE__ */ template(`<div><div class=page-diff-item-header><span class=page-diff-section></span><span class=page-diff-summary>`), _tmpl$22$3 = /* @__PURE__ */ template(`<li>`);
2082
2178
  const AddressBar = () => {
2083
2179
  const {
2084
2180
  activeTab,
@@ -2098,16 +2194,48 @@ const AddressBar = () => {
2098
2194
  toggleDevTools,
2099
2195
  devtoolsPanelOpen: devtoolsPanelOpen2
2100
2196
  } = useUI();
2197
+ const isPrivateWindow = new URLSearchParams(window.location.search).get("private") === "1";
2198
+ const {
2199
+ historyState: historyState2
2200
+ } = useHistory();
2201
+ const {
2202
+ bookmarksState: bookmarksState2
2203
+ } = useBookmarks();
2101
2204
  const [inputValue, setInputValue] = createSignal("");
2205
+ const [showSuggestions, setShowSuggestions] = createSignal(false);
2206
+ const [selectedIndex, setSelectedIndex] = createSignal(-1);
2207
+ const [searchEngine, setSearchEngine] = createSignal("duckduckgo");
2102
2208
  const now2 = useNow();
2103
2209
  let inputRef;
2104
2210
  const agentPresence = createMemo(() => getAgentPresence(runtimeState2(), now2()));
2105
2211
  const agentStatusMessage = createMemo(() => getLatestAgentStatusMessage(runtimeState2(), now2()));
2106
2212
  const pendingApprovalCount = createMemo(() => runtimeState2().supervisor.pendingApprovals.length);
2213
+ const searchEnginePreset = createMemo(() => {
2214
+ const engine = searchEngine();
2215
+ return engine === "none" ? SEARCH_ENGINE_PRESETS.duckduckgo : SEARCH_ENGINE_PRESETS[engine];
2216
+ });
2217
+ const buildSearchUrl = (query) => searchEnginePreset().url + encodeURIComponent(query);
2107
2218
  const [pageDiff, setPageDiff] = createSignal(null);
2108
2219
  const [diffExpanded, setDiffExpanded] = createSignal(false);
2109
2220
  let diffCollapseTimer = null;
2221
+ onMount(() => {
2222
+ let disposed = false;
2223
+ void window.vessel.settings.get().then((settings) => {
2224
+ if (!disposed) {
2225
+ setSearchEngine(settings.defaultSearchEngine ?? "duckduckgo");
2226
+ }
2227
+ }).catch(() => {
2228
+ });
2229
+ const unsubscribe = window.vessel.settings.onUpdate((settings) => {
2230
+ setSearchEngine(settings.defaultSearchEngine ?? "duckduckgo");
2231
+ });
2232
+ onCleanup(() => {
2233
+ disposed = true;
2234
+ unsubscribe();
2235
+ });
2236
+ });
2110
2237
  const showIncomingDiff = (diff) => {
2238
+ if (isPrivateWindow) return;
2111
2239
  setPageDiff(diff);
2112
2240
  setDiffExpanded(true);
2113
2241
  if (diffCollapseTimer) clearTimeout(diffCollapseTimer);
@@ -2117,6 +2245,7 @@ const AddressBar = () => {
2117
2245
  }, 8e3);
2118
2246
  };
2119
2247
  const openDiffTimeline = async () => {
2248
+ if (isPrivateWindow) return;
2120
2249
  setDiffExpanded(false);
2121
2250
  if (diffCollapseTimer) {
2122
2251
  clearTimeout(diffCollapseTimer);
@@ -2145,6 +2274,7 @@ const AddressBar = () => {
2145
2274
  return `${hours}h`;
2146
2275
  };
2147
2276
  createEffect(() => {
2277
+ if (isPrivateWindow) return;
2148
2278
  const unsubscribe = window.vessel.pageDiff.onChanged((diff) => {
2149
2279
  const tab = activeTab();
2150
2280
  if (!tab) return;
@@ -2163,10 +2293,65 @@ const AddressBar = () => {
2163
2293
  const tab = activeTab();
2164
2294
  if (tab && !inputRef?.matches(":focus")) {
2165
2295
  setInputValue(tab.url === "about:blank" ? "" : tab.url);
2296
+ setShowSuggestions(false);
2297
+ setSelectedIndex(-1);
2166
2298
  }
2167
2299
  });
2300
+ const MAX_SUGGESTIONS = 8;
2301
+ const suggestions = createMemo(() => {
2302
+ const rawQuery = inputValue().trim();
2303
+ const query = rawQuery.toLowerCase();
2304
+ if (!query || query.length < 2) return [];
2305
+ const results = [];
2306
+ const seen = /* @__PURE__ */ new Set();
2307
+ const matchLimit = MAX_SUGGESTIONS - 1;
2308
+ for (const b of bookmarksState2().bookmarks) {
2309
+ if (seen.has(b.url)) continue;
2310
+ const urlMatch = b.url.toLowerCase().includes(query);
2311
+ const titleMatch = b.title.toLowerCase().includes(query);
2312
+ if (urlMatch || titleMatch) {
2313
+ seen.add(b.url);
2314
+ results.push({
2315
+ url: b.url,
2316
+ title: b.title,
2317
+ source: "bookmark"
2318
+ });
2319
+ }
2320
+ if (results.length >= matchLimit) break;
2321
+ }
2322
+ if (results.length < matchLimit) {
2323
+ for (const h of historyState2().entries) {
2324
+ if (seen.has(h.url)) continue;
2325
+ const urlMatch = h.url.toLowerCase().includes(query);
2326
+ const titleMatch = h.title.toLowerCase().includes(query);
2327
+ if (urlMatch || titleMatch) {
2328
+ seen.add(h.url);
2329
+ results.push({
2330
+ url: h.url,
2331
+ title: h.title,
2332
+ source: "history"
2333
+ });
2334
+ }
2335
+ if (results.length >= matchLimit) break;
2336
+ }
2337
+ }
2338
+ if (results.length < MAX_SUGGESTIONS) {
2339
+ results.push({
2340
+ url: buildSearchUrl(rawQuery),
2341
+ title: `Search for "${rawQuery}"`,
2342
+ subtitle: searchEnginePreset().label,
2343
+ source: "search"
2344
+ });
2345
+ }
2346
+ return results;
2347
+ });
2168
2348
  createEffect(() => {
2169
2349
  const tab = activeTab();
2350
+ if (isPrivateWindow) {
2351
+ setPageDiff(null);
2352
+ setDiffExpanded(false);
2353
+ return;
2354
+ }
2170
2355
  if (!tab) {
2171
2356
  setPageDiff(null);
2172
2357
  setDiffExpanded(false);
@@ -2190,37 +2375,150 @@ const AddressBar = () => {
2190
2375
  cancelled = true;
2191
2376
  });
2192
2377
  });
2378
+ const selectSuggestion = (url) => {
2379
+ setInputValue(url);
2380
+ setShowSuggestions(false);
2381
+ setSelectedIndex(-1);
2382
+ navigate(url);
2383
+ inputRef?.blur();
2384
+ };
2193
2385
  const handleSubmit = (e) => {
2194
2386
  e.preventDefault();
2195
- const val = inputValue().trim();
2196
- if (val) {
2197
- navigate(val);
2198
- inputRef?.blur();
2387
+ const idx = selectedIndex();
2388
+ const items = suggestions();
2389
+ if (idx >= 0 && idx < items.length) {
2390
+ selectSuggestion(items[idx].url);
2391
+ } else {
2392
+ const val = inputValue().trim();
2393
+ if (val) {
2394
+ navigate(val);
2395
+ inputRef?.blur();
2396
+ setShowSuggestions(false);
2397
+ }
2398
+ }
2399
+ };
2400
+ const handleInputKeyDown = (e) => {
2401
+ const items = suggestions();
2402
+ const idx = selectedIndex();
2403
+ if (e.key === "ArrowDown") {
2404
+ e.preventDefault();
2405
+ if (items.length > 0) {
2406
+ setShowSuggestions(true);
2407
+ setSelectedIndex(idx < items.length - 1 ? idx + 1 : 0);
2408
+ }
2409
+ } else if (e.key === "ArrowUp") {
2410
+ e.preventDefault();
2411
+ if (items.length > 0) {
2412
+ setShowSuggestions(true);
2413
+ setSelectedIndex(idx > 0 ? idx - 1 : items.length - 1);
2414
+ }
2415
+ } else if (e.key === "Escape") {
2416
+ if (showSuggestions()) {
2417
+ setShowSuggestions(false);
2418
+ setSelectedIndex(-1);
2419
+ } else {
2420
+ inputRef?.blur();
2421
+ }
2199
2422
  }
2200
2423
  };
2201
2424
  const formatSectionLabel = (section) => section === "title" ? "Title" : section === "headings" ? "Headings" : "Content";
2202
2425
  return (() => {
2203
- var _el$ = _tmpl$8$5(), _el$2 = _el$.firstChild, _el$3 = _el$2.firstChild, _el$4 = _el$3.nextSibling, _el$5 = _el$4.nextSibling, _el$6 = _el$2.nextSibling, _el$7 = _el$6.firstChild, _el$8 = _el$7.firstChild, _el$9 = _el$7.nextSibling, _el$0 = _el$9.firstChild, _el$1 = _el$0.nextSibling, _el$26 = _el$6.nextSibling, _el$27 = _el$26.firstChild, _el$28 = _el$27.firstChild, _el$32 = _el$27.nextSibling, _el$33 = _el$32.nextSibling, _el$34 = _el$33.nextSibling;
2204
- _el$34.firstChild;
2205
- var _el$37 = _el$34.nextSibling;
2426
+ var _el$ = _tmpl$13$3(), _el$2 = _el$.firstChild, _el$3 = _el$2.firstChild, _el$4 = _el$3.nextSibling, _el$5 = _el$4.nextSibling, _el$7 = _el$2.nextSibling, _el$8 = _el$7.firstChild, _el$9 = _el$8.firstChild, _el$28 = _el$7.nextSibling, _el$29 = _el$28.firstChild, _el$30 = _el$29.firstChild;
2206
2427
  addEventListener(_el$3, "click", goBack, true);
2207
2428
  addEventListener(_el$4, "click", goForward, true);
2208
2429
  addEventListener(_el$5, "click", reload, true);
2209
- _el$7.addEventListener("submit", handleSubmit);
2210
- _el$8.addEventListener("focus", (e) => e.currentTarget.select());
2211
- _el$8.$$input = (e) => setInputValue(e.currentTarget.value);
2430
+ insert(_el$, createComponent(Show, {
2431
+ when: isPrivateWindow,
2432
+ get children() {
2433
+ return _tmpl$$g();
2434
+ }
2435
+ }), _el$7);
2436
+ _el$8.addEventListener("submit", handleSubmit);
2437
+ _el$9.addEventListener("blur", () => {
2438
+ setTimeout(() => {
2439
+ setShowSuggestions(false);
2440
+ setSelectedIndex(-1);
2441
+ }, 150);
2442
+ });
2443
+ _el$9.$$keydown = handleInputKeyDown;
2444
+ _el$9.addEventListener("focus", (e) => {
2445
+ e.currentTarget.select();
2446
+ const query = inputValue().trim();
2447
+ if (query.length >= 2) setShowSuggestions(true);
2448
+ });
2449
+ _el$9.$$input = (e) => {
2450
+ setInputValue(e.currentTarget.value);
2451
+ setShowSuggestions(true);
2452
+ setSelectedIndex(-1);
2453
+ };
2212
2454
  var _ref$ = inputRef;
2213
- typeof _ref$ === "function" ? use(_ref$, _el$8) : inputRef = _el$8;
2214
- setAttribute(_el$8, "spellcheck", false);
2215
- insert(_el$1, () => agentStatusMessage() || (agentPresence() === "active" ? "Agent Active" : agentPresence() === "recent" ? "Agent Connected" : "Agent Offline"));
2216
- insert(_el$6, createComponent(Show, {
2455
+ typeof _ref$ === "function" ? use(_ref$, _el$9) : inputRef = _el$9;
2456
+ setAttribute(_el$9, "spellcheck", false);
2457
+ insert(_el$7, createComponent(Show, {
2458
+ get when() {
2459
+ return memo(() => !!showSuggestions())() && suggestions().length > 0;
2460
+ },
2461
+ get children() {
2462
+ var _el$0 = _tmpl$2$e();
2463
+ insert(_el$0, createComponent(For, {
2464
+ get each() {
2465
+ return suggestions();
2466
+ },
2467
+ children: (item, i) => (() => {
2468
+ var _el$40 = _tmpl$14$3(), _el$41 = _el$40.firstChild, _el$42 = _el$41.nextSibling, _el$43 = _el$42.firstChild, _el$44 = _el$43.nextSibling;
2469
+ _el$40.addEventListener("mouseenter", () => setSelectedIndex(i()));
2470
+ _el$40.$$mousedown = (e) => {
2471
+ e.preventDefault();
2472
+ selectSuggestion(item.url);
2473
+ };
2474
+ insert(_el$41, (() => {
2475
+ var _c$ = memo(() => item.source === "bookmark");
2476
+ return () => _c$() ? "★" : item.source === "search" ? "⌕" : "◌";
2477
+ })());
2478
+ insert(_el$43, () => item.title || item.url);
2479
+ insert(_el$44, () => item.subtitle || item.url);
2480
+ createRenderEffect((_p$) => {
2481
+ var _v$10 = `address-autocomplete-${i()}`, _v$11 = `autocomplete-item ${selectedIndex() === i() ? "selected" : ""}`, _v$12 = selectedIndex() === i();
2482
+ _v$10 !== _p$.e && setAttribute(_el$40, "id", _p$.e = _v$10);
2483
+ _v$11 !== _p$.t && className(_el$40, _p$.t = _v$11);
2484
+ _v$12 !== _p$.a && setAttribute(_el$40, "aria-selected", _p$.a = _v$12);
2485
+ return _p$;
2486
+ }, {
2487
+ e: void 0,
2488
+ t: void 0,
2489
+ a: void 0
2490
+ });
2491
+ return _el$40;
2492
+ })()
2493
+ }));
2494
+ return _el$0;
2495
+ }
2496
+ }), null);
2497
+ insert(_el$7, createComponent(Show, {
2498
+ when: !isPrivateWindow,
2499
+ get children() {
2500
+ var _el$1 = _tmpl$3$b(), _el$10 = _el$1.firstChild, _el$11 = _el$10.nextSibling;
2501
+ insert(_el$11, () => agentStatusMessage() || (agentPresence() === "active" ? "Agent Active" : agentPresence() === "recent" ? "Agent Connected" : "Agent Offline"));
2502
+ createRenderEffect((_p$) => {
2503
+ var _v$ = `agent-status-badge ${agentPresence()}`, _v$2 = agentStatusMessage() || (agentPresence() === "active" ? "Agent is actively using the browser" : agentPresence() === "recent" ? "Agent is connected" : "No agent connection detected");
2504
+ _v$ !== _p$.e && className(_el$1, _p$.e = _v$);
2505
+ _v$2 !== _p$.t && setAttribute(_el$1, "title", _p$.t = _v$2);
2506
+ return _p$;
2507
+ }, {
2508
+ e: void 0,
2509
+ t: void 0
2510
+ });
2511
+ return _el$1;
2512
+ }
2513
+ }), null);
2514
+ insert(_el$7, createComponent(Show, {
2217
2515
  get when() {
2218
2516
  return pageDiff();
2219
2517
  },
2220
2518
  get children() {
2221
- var _el$10 = _tmpl$$g();
2222
- _el$10.$$click = () => void openDiffTimeline();
2223
- return _el$10;
2519
+ var _el$12 = _tmpl$4$b();
2520
+ _el$12.$$click = () => void openDiffTimeline();
2521
+ return _el$12;
2224
2522
  }
2225
2523
  }), null);
2226
2524
  insert(_el$, createComponent(Show, {
@@ -2228,176 +2526,212 @@ const AddressBar = () => {
2228
2526
  return memo(() => !!pageDiff())() && diffExpanded();
2229
2527
  },
2230
2528
  get children() {
2231
- var _el$11 = _tmpl$4$b(), _el$12 = _el$11.firstChild, _el$13 = _el$12.firstChild, _el$14 = _el$13.firstChild;
2232
- _el$14.firstChild;
2233
- var _el$21 = _el$13.nextSibling, _el$22 = _el$21.firstChild, _el$23 = _el$22.nextSibling;
2234
- insert(_el$14, () => formatRelativeTime(pageDiff().oldSnapshot.capturedAt), null);
2235
- insert(_el$13, createComponent(Show, {
2529
+ var _el$13 = _tmpl$7$7(), _el$14 = _el$13.firstChild, _el$15 = _el$14.firstChild, _el$16 = _el$15.firstChild;
2530
+ _el$16.firstChild;
2531
+ var _el$23 = _el$15.nextSibling, _el$24 = _el$23.firstChild, _el$25 = _el$24.nextSibling;
2532
+ insert(_el$16, () => formatRelativeTime(pageDiff().oldSnapshot.capturedAt), null);
2533
+ insert(_el$15, createComponent(Show, {
2236
2534
  get when() {
2237
2535
  return memo(() => !!((pageDiff().burstCount || 0) > 1 && pageDiff().firstDetectedAt))() && pageDiff().lastDetectedAt;
2238
2536
  },
2239
2537
  get children() {
2240
- var _el$16 = _tmpl$2$e(), _el$17 = _el$16.firstChild, _el$20 = _el$17.nextSibling;
2241
- _el$20.nextSibling;
2242
- insert(_el$16, () => pageDiff().burstCount, _el$20);
2243
- insert(_el$16, () => formatElapsed(pageDiff().firstDetectedAt, pageDiff().lastDetectedAt), null);
2244
- return _el$16;
2538
+ var _el$18 = _tmpl$5$a(), _el$19 = _el$18.firstChild, _el$22 = _el$19.nextSibling;
2539
+ _el$22.nextSibling;
2540
+ insert(_el$18, () => pageDiff().burstCount, _el$22);
2541
+ insert(_el$18, () => formatElapsed(pageDiff().firstDetectedAt, pageDiff().lastDetectedAt), null);
2542
+ return _el$18;
2245
2543
  }
2246
2544
  }), null);
2247
- _el$22.$$click = () => void openDiffTimeline();
2248
- _el$23.$$click = () => setDiffExpanded(false);
2249
- insert(_el$11, createComponent(Show, {
2545
+ _el$24.$$click = () => void openDiffTimeline();
2546
+ _el$25.$$click = () => setDiffExpanded(false);
2547
+ insert(_el$13, createComponent(Show, {
2250
2548
  get when() {
2251
2549
  return memo(() => !!pageDiff().recentBursts?.length)() && (pageDiff().recentBursts?.length || 0) > 1;
2252
2550
  },
2253
2551
  get children() {
2254
- var _el$24 = _tmpl$3$b();
2255
- _el$24.firstChild;
2256
- insert(_el$24, createComponent(For, {
2552
+ var _el$26 = _tmpl$6$9();
2553
+ _el$26.firstChild;
2554
+ insert(_el$26, createComponent(For, {
2257
2555
  get each() {
2258
2556
  return pageDiff().recentBursts;
2259
2557
  },
2260
2558
  children: (burst) => (() => {
2261
- var _el$38 = _tmpl$9$4(), _el$39 = _el$38.firstChild, _el$40 = _el$39.nextSibling;
2262
- insert(_el$39, () => formatRelativeTime(burst.detectedAt));
2263
- insert(_el$40, () => burst.summary);
2264
- return _el$38;
2559
+ var _el$45 = _tmpl$15$3(), _el$46 = _el$45.firstChild, _el$47 = _el$46.nextSibling;
2560
+ insert(_el$46, () => formatRelativeTime(burst.detectedAt));
2561
+ insert(_el$47, () => burst.summary);
2562
+ return _el$45;
2265
2563
  })()
2266
2564
  }), null);
2267
- return _el$24;
2565
+ return _el$26;
2268
2566
  }
2269
2567
  }), null);
2270
- insert(_el$11, createComponent(For, {
2568
+ insert(_el$13, createComponent(For, {
2271
2569
  get each() {
2272
2570
  return pageDiff().changes;
2273
2571
  },
2274
2572
  children: (change) => (() => {
2275
- var _el$41 = _tmpl$13$3(), _el$42 = _el$41.firstChild, _el$43 = _el$42.firstChild, _el$44 = _el$43.nextSibling;
2276
- insert(_el$43, () => formatSectionLabel(change.section));
2277
- insert(_el$44, () => change.summary);
2278
- insert(_el$41, createComponent(Show, {
2573
+ var _el$48 = _tmpl$21$3(), _el$49 = _el$48.firstChild, _el$50 = _el$49.firstChild, _el$51 = _el$50.nextSibling;
2574
+ insert(_el$50, () => formatSectionLabel(change.section));
2575
+ insert(_el$51, () => change.summary);
2576
+ insert(_el$48, createComponent(Show, {
2279
2577
  get when() {
2280
2578
  return change.before || change.after;
2281
2579
  },
2282
2580
  get children() {
2283
- var _el$45 = _tmpl$10$4();
2284
- insert(_el$45, createComponent(Show, {
2581
+ var _el$52 = _tmpl$18$3();
2582
+ insert(_el$52, createComponent(Show, {
2285
2583
  get when() {
2286
2584
  return change.before;
2287
2585
  },
2288
2586
  get children() {
2289
- var _el$46 = _tmpl$0$4(), _el$47 = _el$46.firstChild, _el$48 = _el$47.nextSibling;
2290
- insert(_el$48, () => change.before);
2291
- return _el$46;
2587
+ var _el$53 = _tmpl$16$3(), _el$54 = _el$53.firstChild, _el$55 = _el$54.nextSibling;
2588
+ insert(_el$55, () => change.before);
2589
+ return _el$53;
2292
2590
  }
2293
2591
  }), null);
2294
- insert(_el$45, createComponent(Show, {
2592
+ insert(_el$52, createComponent(Show, {
2295
2593
  get when() {
2296
2594
  return change.after;
2297
2595
  },
2298
2596
  get children() {
2299
- var _el$49 = _tmpl$1$4(), _el$50 = _el$49.firstChild, _el$51 = _el$50.nextSibling;
2300
- insert(_el$51, () => change.after);
2301
- return _el$49;
2597
+ var _el$56 = _tmpl$17$3(), _el$57 = _el$56.firstChild, _el$58 = _el$57.nextSibling;
2598
+ insert(_el$58, () => change.after);
2599
+ return _el$56;
2302
2600
  }
2303
2601
  }), null);
2304
- return _el$45;
2602
+ return _el$52;
2305
2603
  }
2306
2604
  }), null);
2307
- insert(_el$41, createComponent(Show, {
2605
+ insert(_el$48, createComponent(Show, {
2308
2606
  get when() {
2309
2607
  return change.addedItems?.length;
2310
2608
  },
2311
2609
  get children() {
2312
- var _el$52 = _tmpl$11$4(), _el$53 = _el$52.firstChild, _el$54 = _el$53.nextSibling;
2313
- insert(_el$54, createComponent(For, {
2610
+ var _el$59 = _tmpl$19$3(), _el$60 = _el$59.firstChild, _el$61 = _el$60.nextSibling;
2611
+ insert(_el$61, createComponent(For, {
2314
2612
  get each() {
2315
2613
  return change.addedItems;
2316
2614
  },
2317
2615
  children: (item) => (() => {
2318
- var _el$58 = _tmpl$14$3();
2319
- insert(_el$58, item);
2320
- return _el$58;
2616
+ var _el$65 = _tmpl$22$3();
2617
+ insert(_el$65, item);
2618
+ return _el$65;
2321
2619
  })()
2322
2620
  }));
2323
- return _el$52;
2621
+ return _el$59;
2324
2622
  }
2325
2623
  }), null);
2326
- insert(_el$41, createComponent(Show, {
2624
+ insert(_el$48, createComponent(Show, {
2327
2625
  get when() {
2328
2626
  return change.removedItems?.length;
2329
2627
  },
2330
2628
  get children() {
2331
- var _el$55 = _tmpl$12$4(), _el$56 = _el$55.firstChild, _el$57 = _el$56.nextSibling;
2332
- insert(_el$57, createComponent(For, {
2629
+ var _el$62 = _tmpl$20$3(), _el$63 = _el$62.firstChild, _el$64 = _el$63.nextSibling;
2630
+ insert(_el$64, createComponent(For, {
2333
2631
  get each() {
2334
2632
  return change.removedItems;
2335
2633
  },
2336
2634
  children: (item) => (() => {
2337
- var _el$59 = _tmpl$14$3();
2338
- insert(_el$59, item);
2339
- return _el$59;
2635
+ var _el$66 = _tmpl$22$3();
2636
+ insert(_el$66, item);
2637
+ return _el$66;
2340
2638
  })()
2341
2639
  }));
2342
- return _el$55;
2640
+ return _el$62;
2343
2641
  }
2344
2642
  }), null);
2345
- createRenderEffect(() => className(_el$41, `page-diff-item page-diff-${change.kind}`));
2346
- return _el$41;
2643
+ createRenderEffect(() => className(_el$48, `page-diff-item page-diff-${change.kind}`));
2644
+ return _el$48;
2347
2645
  })()
2348
2646
  }), null);
2349
- return _el$11;
2647
+ return _el$13;
2350
2648
  }
2351
- }), _el$26);
2352
- _el$27.$$click = async () => {
2649
+ }), _el$28);
2650
+ _el$29.$$click = async () => {
2353
2651
  const id = activeTabId2();
2354
2652
  if (!id) return;
2355
2653
  await toggleAdBlock(id);
2356
2654
  };
2357
- insert(_el$28, createComponent(Show, {
2655
+ insert(_el$30, createComponent(Show, {
2358
2656
  get when() {
2359
2657
  return activeTab()?.adBlockingEnabled;
2360
2658
  },
2361
2659
  get children() {
2362
- return _tmpl$5$a();
2660
+ return _tmpl$8$5();
2363
2661
  }
2364
2662
  }), null);
2365
- insert(_el$28, createComponent(Show, {
2663
+ insert(_el$30, createComponent(Show, {
2366
2664
  get when() {
2367
2665
  return !activeTab()?.adBlockingEnabled;
2368
2666
  },
2369
2667
  get children() {
2370
- return [_tmpl$5$a(), _tmpl$6$9()];
2668
+ return [_tmpl$8$5(), _tmpl$9$4()];
2371
2669
  }
2372
2670
  }), null);
2373
- _el$32.$$click = () => window.vessel.content.toggleReader();
2374
- addEventListener(_el$33, "click", toggleDevTools, true);
2375
- addEventListener(_el$34, "click", toggleSidebar, true);
2376
- insert(_el$34, createComponent(Show, {
2377
- get when() {
2378
- return pendingApprovalCount() > 0;
2379
- },
2671
+ insert(_el$28, createComponent(Show, {
2672
+ when: !isPrivateWindow,
2673
+ get children() {
2674
+ var _el$34 = _tmpl$0$4();
2675
+ _el$34.$$click = () => window.vessel.content.toggleReader();
2676
+ createRenderEffect(() => _el$34.classList.toggle("active", !!activeTab()?.isReaderMode));
2677
+ return _el$34;
2678
+ }
2679
+ }), null);
2680
+ insert(_el$28, createComponent(Show, {
2681
+ when: !isPrivateWindow,
2682
+ get children() {
2683
+ var _el$35 = _tmpl$1$4();
2684
+ addEventListener(_el$35, "click", toggleDevTools, true);
2685
+ createRenderEffect(() => _el$35.classList.toggle("active", !!devtoolsPanelOpen2()));
2686
+ return _el$35;
2687
+ }
2688
+ }), null);
2689
+ insert(_el$28, createComponent(Show, {
2690
+ when: !isPrivateWindow,
2380
2691
  get children() {
2381
- var _el$36 = _tmpl$7$7();
2382
- insert(_el$36, pendingApprovalCount);
2383
- createRenderEffect(() => setAttribute(_el$36, "aria-label", `${pendingApprovalCount()} pending`));
2692
+ var _el$36 = _tmpl$11$4();
2693
+ _el$36.firstChild;
2694
+ addEventListener(_el$36, "click", toggleSidebar, true);
2695
+ insert(_el$36, createComponent(Show, {
2696
+ get when() {
2697
+ return pendingApprovalCount() > 0;
2698
+ },
2699
+ get children() {
2700
+ var _el$38 = _tmpl$10$4();
2701
+ insert(_el$38, pendingApprovalCount);
2702
+ createRenderEffect(() => setAttribute(_el$38, "aria-label", `${pendingApprovalCount()} pending`));
2703
+ return _el$38;
2704
+ }
2705
+ }), null);
2706
+ createRenderEffect((_p$) => {
2707
+ var _v$3 = !!(pendingApprovalCount() > 0), _v$4 = pendingApprovalCount() > 0 ? `AI Sidebar — ${pendingApprovalCount()} pending approval${pendingApprovalCount() > 1 ? "s" : ""}` : "AI Sidebar (Ctrl+Shift+L)";
2708
+ _v$3 !== _p$.e && _el$36.classList.toggle("has-approvals", _p$.e = _v$3);
2709
+ _v$4 !== _p$.t && setAttribute(_el$36, "title", _p$.t = _v$4);
2710
+ return _p$;
2711
+ }, {
2712
+ e: void 0,
2713
+ t: void 0
2714
+ });
2384
2715
  return _el$36;
2385
2716
  }
2386
2717
  }), null);
2387
- addEventListener(_el$37, "click", openSettings, true);
2718
+ insert(_el$28, createComponent(Show, {
2719
+ when: !isPrivateWindow,
2720
+ get children() {
2721
+ var _el$39 = _tmpl$12$4();
2722
+ addEventListener(_el$39, "click", openSettings, true);
2723
+ return _el$39;
2724
+ }
2725
+ }), null);
2388
2726
  createRenderEffect((_p$) => {
2389
- var _v$ = !activeTab()?.canGoBack, _v$2 = !activeTab()?.canGoForward, _v$3 = `agent-status-badge ${agentPresence()}`, _v$4 = agentStatusMessage() || (agentPresence() === "active" ? "Agent is actively using the browser" : agentPresence() === "recent" ? "Agent is connected" : "No agent connection detected"), _v$5 = !!activeTab()?.adBlockingEnabled, _v$6 = !activeTab()?.adBlockingEnabled, _v$7 = activeTab()?.adBlockingEnabled ? "Ad Block: On (click to disable)" : "Ad Block: Off (click to enable)", _v$8 = !!activeTab()?.isReaderMode, _v$9 = !!devtoolsPanelOpen2(), _v$0 = !!(pendingApprovalCount() > 0), _v$1 = pendingApprovalCount() > 0 ? `AI Sidebar — ${pendingApprovalCount()} pending approval${pendingApprovalCount() > 1 ? "s" : ""}` : "AI Sidebar (Ctrl+Shift+L)";
2390
- _v$ !== _p$.e && (_el$3.disabled = _p$.e = _v$);
2391
- _v$2 !== _p$.t && (_el$4.disabled = _p$.t = _v$2);
2392
- _v$3 !== _p$.a && className(_el$9, _p$.a = _v$3);
2393
- _v$4 !== _p$.o && setAttribute(_el$9, "title", _p$.o = _v$4);
2394
- _v$5 !== _p$.i && _el$27.classList.toggle("active", _p$.i = _v$5);
2395
- _v$6 !== _p$.n && _el$27.classList.toggle("nav-btn-muted", _p$.n = _v$6);
2396
- _v$7 !== _p$.s && setAttribute(_el$27, "title", _p$.s = _v$7);
2397
- _v$8 !== _p$.h && _el$32.classList.toggle("active", _p$.h = _v$8);
2398
- _v$9 !== _p$.r && _el$33.classList.toggle("active", _p$.r = _v$9);
2399
- _v$0 !== _p$.d && _el$34.classList.toggle("has-approvals", _p$.d = _v$0);
2400
- _v$1 !== _p$.l && setAttribute(_el$34, "title", _p$.l = _v$1);
2727
+ var _v$5 = !activeTab()?.canGoBack, _v$6 = !activeTab()?.canGoForward, _v$7 = showSuggestions() && suggestions().length > 0, _v$8 = selectedIndex() >= 0 ? `address-autocomplete-${selectedIndex()}` : void 0, _v$9 = !!activeTab()?.adBlockingEnabled, _v$0 = !activeTab()?.adBlockingEnabled, _v$1 = activeTab()?.adBlockingEnabled ? "Ad Block: On (click to disable)" : "Ad Block: Off (click to enable)";
2728
+ _v$5 !== _p$.e && (_el$3.disabled = _p$.e = _v$5);
2729
+ _v$6 !== _p$.t && (_el$4.disabled = _p$.t = _v$6);
2730
+ _v$7 !== _p$.a && setAttribute(_el$9, "aria-expanded", _p$.a = _v$7);
2731
+ _v$8 !== _p$.o && setAttribute(_el$9, "aria-activedescendant", _p$.o = _v$8);
2732
+ _v$9 !== _p$.i && _el$29.classList.toggle("active", _p$.i = _v$9);
2733
+ _v$0 !== _p$.n && _el$29.classList.toggle("nav-btn-muted", _p$.n = _v$0);
2734
+ _v$1 !== _p$.s && setAttribute(_el$29, "title", _p$.s = _v$1);
2401
2735
  return _p$;
2402
2736
  }, {
2403
2737
  e: void 0,
@@ -2406,17 +2740,13 @@ const AddressBar = () => {
2406
2740
  o: void 0,
2407
2741
  i: void 0,
2408
2742
  n: void 0,
2409
- s: void 0,
2410
- h: void 0,
2411
- r: void 0,
2412
- d: void 0,
2413
- l: void 0
2743
+ s: void 0
2414
2744
  });
2415
- createRenderEffect(() => _el$8.value = inputValue());
2745
+ createRenderEffect(() => _el$9.value = inputValue());
2416
2746
  return _el$;
2417
2747
  })();
2418
2748
  };
2419
- delegateEvents(["click", "input"]);
2749
+ delegateEvents(["click", "input", "keydown", "mousedown"]);
2420
2750
  var _tmpl$$f = /* @__PURE__ */ template(`<div class=bookmark-toast-stack aria-live=polite aria-atomic=true>`), _tmpl$2$d = /* @__PURE__ */ template(`<div class=bookmark-toast role=status><div class=bookmark-toast-title></div><div class=bookmark-toast-message>`);
2421
2751
  const TOAST_DURATION_MS$1 = 4200;
2422
2752
  const TOAST_EXIT_MS$2 = 300;
@@ -3154,7 +3484,7 @@ const [pendingQueries, setPendingQueries] = createSignal([]);
3154
3484
  const [pendingQueryActivities, setPendingQueryActivities] = createSignal([]);
3155
3485
  const [queueNotice, setQueueNotice] = createSignal(null);
3156
3486
  const [automationActivities, setAutomationActivities] = createSignal([]);
3157
- let initialized$2 = false;
3487
+ let initialized = false;
3158
3488
  let pendingDrainScheduled = false;
3159
3489
  let listenerCleanups = [];
3160
3490
  let pendingAutomationActivity = null;
@@ -3212,9 +3542,9 @@ function schedulePendingDrain() {
3212
3542
  }
3213
3543
  });
3214
3544
  }
3215
- function init$2() {
3216
- if (initialized$2) return;
3217
- initialized$2 = true;
3545
+ function init() {
3546
+ if (initialized) return;
3547
+ initialized = true;
3218
3548
  listenerCleanups.push(window.vessel.ai.onStreamStart((prompt) => {
3219
3549
  setMessages((prev) => {
3220
3550
  const next = [...prev, { role: "user", content: prompt }];
@@ -3297,7 +3627,7 @@ function init$2() {
3297
3627
  }));
3298
3628
  }
3299
3629
  function useAI() {
3300
- init$2();
3630
+ init();
3301
3631
  const query = async (prompt, activity = null) => {
3302
3632
  recordRecentQuery(prompt);
3303
3633
  if (isStreaming()) {
@@ -3513,82 +3843,6 @@ const CommandBar = () => {
3513
3843
  });
3514
3844
  };
3515
3845
  delegateEvents(["click", "input", "keydown"]);
3516
- const logger$3 = createLogger("HistoryStore");
3517
- const INITIAL$1 = { entries: [] };
3518
- const [historyState, setHistoryState] = createSignal(INITIAL$1);
3519
- let initialized$1 = false;
3520
- let initPromise$1 = null;
3521
- async function init$1() {
3522
- if (initPromise$1) return initPromise$1;
3523
- if (initialized$1) return;
3524
- initialized$1 = true;
3525
- initPromise$1 = (async () => {
3526
- try {
3527
- const state = await window.vessel.history.get();
3528
- setHistoryState(state);
3529
- window.vessel.history.onUpdate((s) => setHistoryState(s));
3530
- } catch (error) {
3531
- initialized$1 = false;
3532
- logger$3.error("Failed to initialize history store:", error);
3533
- } finally {
3534
- initPromise$1 = null;
3535
- }
3536
- })();
3537
- return initPromise$1;
3538
- }
3539
- function useHistory() {
3540
- void init$1();
3541
- return {
3542
- historyState,
3543
- search: (query) => window.vessel.history.search(query),
3544
- clear: () => window.vessel.history.clear()
3545
- };
3546
- }
3547
- const logger$2 = createLogger("BookmarksStore");
3548
- const INITIAL = { folders: [], bookmarks: [] };
3549
- const [bookmarksState, setBookmarksState] = createSignal(INITIAL);
3550
- let initialized = false;
3551
- let initPromise = null;
3552
- async function init() {
3553
- if (initPromise) return initPromise;
3554
- if (initialized) return;
3555
- initialized = true;
3556
- initPromise = (async () => {
3557
- try {
3558
- const state = await window.vessel.bookmarks.get();
3559
- setBookmarksState(state);
3560
- window.vessel.bookmarks.onUpdate((s) => setBookmarksState(s));
3561
- } catch (error) {
3562
- initialized = false;
3563
- logger$2.error("Failed to initialize bookmarks store:", error);
3564
- } finally {
3565
- initPromise = null;
3566
- }
3567
- })();
3568
- return initPromise;
3569
- }
3570
- function useBookmarks() {
3571
- void init();
3572
- return {
3573
- bookmarksState,
3574
- saveBookmark: (url, title, folderId, note, intent, expectedContent, keyFields, agentHints) => window.vessel.bookmarks.saveBookmark(
3575
- url,
3576
- title,
3577
- folderId,
3578
- note,
3579
- intent,
3580
- expectedContent,
3581
- keyFields,
3582
- agentHints
3583
- ),
3584
- updateBookmark: (id, updates) => window.vessel.bookmarks.updateBookmark(id, updates),
3585
- removeBookmark: (id) => window.vessel.bookmarks.removeBookmark(id),
3586
- createFolder: (name) => window.vessel.bookmarks.createFolder(name),
3587
- createFolderWithSummary: (name, summary) => window.vessel.bookmarks.createFolderWithSummary(name, summary),
3588
- removeFolder: (id, deleteContents) => window.vessel.bookmarks.removeFolder(id, deleteContents),
3589
- renameFolder: (id, newName, summary) => window.vessel.bookmarks.renameFolder(id, newName, summary)
3590
- };
3591
- }
3592
3846
  const MEMORY_STORAGE_KEY = "vessel.bookmark-context.memories";
3593
3847
  const MAX_MEMORY_LINES = 4;
3594
3848
  const MAX_MEMORY_CHARS = 420;
@@ -4945,7 +5199,7 @@ function renderToolChip(name, args) {
4945
5199
  function renderMarkdown(source) {
4946
5200
  const codeBlocks = [];
4947
5201
  const toolChips = [];
4948
- const normalized = source.replace(/\r\n?/g, "\n").replace(
5202
+ const normalized = source.replace(/\r\n?/g, "\n").replace(/<<erase_prev>>/g, "\0ERASE\0").replace(
4949
5203
  /<<tool:([^:>\n]+)(?::([^>\n]*))?>>/g,
4950
5204
  (_, name, args) => {
4951
5205
  const token = `\0TC${toolChips.length}\0`;
@@ -4969,10 +5223,16 @@ ${token}
4969
5223
  );
4970
5224
  const rendered = normalized.split(/\n{2,}/).map((block) => {
4971
5225
  const trimmed = block.trim();
5226
+ if (trimmed === "\0ERASE\0") return "\0ERASE\0";
4972
5227
  if (/^\x00TC\d+\x00$/.test(trimmed)) return trimmed;
4973
5228
  return renderBlock(block);
4974
5229
  }).filter(Boolean).join("");
4975
- let output = rendered;
5230
+ const erased = rendered.replace(
5231
+ /(?:^|(?<=\x00TC\d+\x00))([\s\S]*?)\x00ERASE\x00/g,
5232
+ (_, _content) => ""
5233
+ );
5234
+ const cleaned = erased.replace(/\x00ERASE\x00/g, "");
5235
+ let output = cleaned;
4976
5236
  output = codeBlocks.reduce(
4977
5237
  (out, snippet, index) => out.replace(`\0CB${index}\0`, snippet),
4978
5238
  output
@@ -8455,7 +8715,7 @@ const PROVIDERS = {
8455
8715
  apiKeyHint: "Optional — only if your endpoint requires authentication"
8456
8716
  }
8457
8717
  };
8458
- var _tmpl$$2 = /* @__PURE__ */ template(`<div class=welcome-banner-actions><button class="premium-btn premium-btn-upgrade">Try Premium free for 7 days — $5.99/mo after</button><span class=welcome-banner-note>Best for screenshots, saved sessions, credential vault, and longer autonomous runs.`), _tmpl$2$2 = /* @__PURE__ */ template(`<div class=welcome-banner><div class=welcome-banner-header><span class=welcome-banner-title>Welcome to Vessel</span><button class=welcome-banner-dismiss>&times;</button></div><p class=welcome-banner-text>Get started in three steps:</p><ol class=welcome-banner-steps><li><strong>Configure a chat provider</strong> — scroll to Chat Assistant below and add an API key</li><li><strong>Connect your agent harness</strong> — point it at the MCP endpoint shown below</li><li><strong>Learn the shortcuts</strong> — press <kbd>?</kbd> anytime for a quick reference`), _tmpl$3$1 = /* @__PURE__ */ template(`<div class="settings-callout settings-premium-callout"><div class=settings-callout-title>Start Vessel Premium with a 7-day free trial</div><p class=settings-callout-copy>Unlock screenshots, saved sessions, workflow tracking, table extraction, the credential vault, and longer autonomous runs without leaving the app.</p><div class=settings-premium-callout-actions><button class="premium-btn premium-btn-upgrade">Start 7-day free trial — $5.99/mo after</button><button class="premium-btn premium-btn-activate">See activation steps`), _tmpl$4$1 = /* @__PURE__ */ template(`<input id=max-tool-iterations class=settings-input type=number min=10 max=1000 placeholder=200>`), _tmpl$5$1 = /* @__PURE__ */ template(`<div class=vault-entries>`), _tmpl$6$1 = /* @__PURE__ */ template(`<div class=settings-field><label class=settings-label for=chat-provider>Provider</label><select id=chat-provider class="settings-input settings-select">`), _tmpl$7 = /* @__PURE__ */ template(`<span class=settings-label-optional> (optional)`), _tmpl$8 = /* @__PURE__ */ template(`<p class=settings-hint>An API key is already stored securely for this provider. Leave this blank to keep it, or enter a new key to replace it.`), _tmpl$9 = /* @__PURE__ */ template(`<p class=settings-hint>If your endpoint requires authentication, enter the API key or bearer token here.`), _tmpl$0 = /* @__PURE__ */ template(`<div class=settings-field><label class=settings-label for=chat-api-key>API Key</label><input id=chat-api-key class=settings-input type=password>`), _tmpl$1 = /* @__PURE__ */ template(`<select id=chat-model class="settings-input settings-select"style=flex:1>`), _tmpl$10 = /* @__PURE__ */ template(`<p class=settings-hint style=color:var(--error)>Could not fetch models — check your API key and connection.`), _tmpl$11 = /* @__PURE__ */ template(`<div class=settings-field><label class=settings-label for=chat-model>Model</label><div style=display:flex;gap:6px;align-items:center><button type=button class=settings-refresh-btn title="Refresh model list">↺`), _tmpl$12 = /* @__PURE__ */ template(`<div class=settings-field><label class=settings-label for=chat-base-url>Base URL</label><input id=chat-base-url class=settings-input>`), _tmpl$13 = /* @__PURE__ */ template(`<p class=settings-hint>Vessel auto-detects the active model from your configured \`llama-server\` base URL. For agent loops, run \`llama-server\` with \`--ctx-size 16384\` minimum and \`32768\` recommended.`), _tmpl$14 = /* @__PURE__ */ template(`<div class=premium-section><div class=premium-active-badge>Premium Active</div><p class=premium-detail></p><div class=premium-actions-row><button class="premium-btn premium-btn-manage">Manage Subscription</button><button class="premium-btn premium-btn-reset">Sign Out`), _tmpl$15 = /* @__PURE__ */ template(`<span class=vault-premium-badge>Premium`), _tmpl$16 = /* @__PURE__ */ template(`<p class=settings-hint style=margin-bottom:10px>Store credentials for agent-driven logins. Credentials are encrypted at rest and never sent to AI providers — they are filled directly into login forms with your consent.`), _tmpl$17 = /* @__PURE__ */ template(`<button class=vault-add-btn>+ Add Credential`), _tmpl$18 = /* @__PURE__ */ template(`<div class=vault-add-form><input class=settings-input placeholder="Label (e.g. Work GitHub)"><input class=settings-input placeholder="Domain pattern (e.g. github.com, *.aws.amazon.com)"><input class=settings-input placeholder="Username / email"><input class=settings-input type=password placeholder=Password><input class=settings-input placeholder="TOTP secret (optional, base32)"><input class=settings-input placeholder="Notes (optional)"><div class=vault-add-actions><button class="premium-btn premium-btn-activate">Save Credential</button><button class="premium-btn premium-btn-reset">Cancel`), _tmpl$19 = /* @__PURE__ */ template(`<button class=vault-add-btn>+ Add Profile`), _tmpl$20 = /* @__PURE__ */ template(`<div class=vault-add-form><input class=settings-input placeholder="Profile name (e.g. Personal, Work)"><div style="display:grid;grid-template-columns:1fr 1fr;gap:8px"><input class=settings-input placeholder="First name"><input class=settings-input placeholder="Last name"></div><div style="display:grid;grid-template-columns:1fr 1fr;gap:8px"><input class=settings-input placeholder=Email><input class=settings-input placeholder=Phone></div><input class=settings-input placeholder="Organization (optional)"><input class=settings-input placeholder="Address line 1"><input class=settings-input placeholder="Address line 2 (optional)"><div style="display:grid;grid-template-columns:1fr 1fr 1fr;gap:8px"><input class=settings-input placeholder=City><input class=settings-input placeholder=State><input class=settings-input placeholder="ZIP / Postal"></div><input class=settings-input placeholder=Country><div class=vault-add-actions><button class="premium-btn premium-btn-activate">Save Profile</button><button class="premium-btn premium-btn-reset">Cancel`), _tmpl$21 = /* @__PURE__ */ template(`<textarea class="settings-input settings-textarea"rows=4>`), _tmpl$22 = /* @__PURE__ */ template(`<p class=settings-hint>`), _tmpl$23 = /* @__PURE__ */ template(`<p class=settings-hint>Restrict which domains can be navigated to. Use allowlist mode for kiosk or supervised browsing, blocklist to block specific sites.`), _tmpl$24 = /* @__PURE__ */ template(`<div class=command-bar-overlay><div class=settings-panel><h2 class=settings-title>Runtime Settings</h2><div class=settings-callout><div class=settings-callout-title>External Agent Control</div><p class=settings-callout-copy>Vessel is configured to run under an external harness such as Hermes Agent or OpenClaw. Provider and model selection are not configured inside Vessel.</p></div><div class=settings-field><label class=settings-label for=default-homepage>Homepage</label><input id=default-homepage class=settings-input placeholder=https://start.duckduckgo.com><p class=settings-hint>The page that opens when you create a new tab or launch Vessel without restoring a previous session.</p></div><div class=settings-field><label class=settings-label for=download-path>Download Location</label><input id=download-path class=settings-input placeholder="Default: ~/Downloads"><p class=settings-hint>Directory for saved files. Leave blank to use the system default Downloads folder.</p></div><div class=settings-field><label class=settings-label for=mcp-port>MCP Port</label><input id=mcp-port class=settings-input placeholder=3100><p class=settings-hint>External harnesses connect to Vessel at <code>http://127.0.0.1:&lt;port&gt;/mcp</code>. Changing this value restarts the MCP server immediately.</p></div><div class=settings-field><label class=settings-label for=max-tool-iterations>Max Tool Iterations</label><p class=settings-hint></p></div><div class=settings-field><label class=settings-label for=obsidian-vault-path>Obsidian Vault Path</label><input id=obsidian-vault-path class=settings-input placeholder=/home/you/Documents/MyVault><p class=settings-hint>Optional. When set, Vessel memory tools can write markdown notes into this vault for research breadcrumbs and summaries.</p></div><div class=settings-field><label class=settings-label for=agent-transcript-mode>Agent Transcript Monitor</label><select id=agent-transcript-mode class="settings-input settings-select"><option value=off>Off</option><option value=summary>Summary HUD</option><option value=full>Full transcript</option></select><p class=settings-hint>Controls the in-browser transcript monitor when an external harness publishes reasoning or status updates into Vessel via the<code>vessel_publish_transcript</code> MCP tool. Summary HUD shows a compact 2-line status surface; Full transcript shows the recent entry list.</p></div><div class=settings-field><label class=settings-toggle><button type=button class=toggle-switch role=switch><span class=toggle-switch-thumb></span></button><span>Restore last browser session on launch</span></label></div><div class=settings-field><label class=settings-toggle><button type=button class=toggle-switch role=switch><span class=toggle-switch-thumb></span></button><span>Start bookmarks fresh on launch</span></label><p class=settings-hint>Off by default. When enabled, bookmark folders and saved pages are cleared each time Vessel starts.</p></div><div class=settings-section-divider></div><div class=settings-field><label class=settings-label>Saved Sessions</label><p class=settings-hint style=margin-bottom:10px>Save the current browser state (tabs, cookies, storage) as a named session. Restore it later from this panel.</p><div class=premium-activate-row style=margin-bottom:8px><input class="settings-input premium-email-input"placeholder="Session name"><button class="premium-btn premium-btn-activate">Save Current</button></div></div><div class=settings-section-divider></div><div class=settings-field><label class=settings-toggle><button type=button class=toggle-switch role=switch><span class=toggle-switch-thumb></span></button><span>Enable Chat Assistant</span></label><p class=settings-hint>Adds a Chat tab to the sidebar for conversing with an AI provider of your choice.</p></div><div class=settings-section-divider></div><div class=settings-field><label class=settings-label>Vessel Premium</label></div><div class=settings-section-divider></div><div class=settings-field><label class=settings-label>Agent Credential Vault</label></div><div class=settings-section-divider></div><div class=settings-field><label class=settings-label>Form Autofill</label><p class=settings-hint style=margin-bottom:10px>Store your info once. Vessel matches it to form fields on any site using labels, field names, and autocomplete hints.</p></div><div class=settings-section-divider></div><div class=settings-field><label class=settings-toggle><button type=button class=toggle-switch role=switch><span class=toggle-switch-thumb></span></button><span>Anonymous Usage Analytics</span></label><p class=settings-hint>Help improve Vessel by sending anonymous usage data (tool popularity, session duration, provider type). No URLs, page content, queries, or personal data is ever collected.</p></div><div class=settings-section-divider></div><div class=settings-field><label class=settings-label for=theme-select>Theme</label><select id=theme-select class="settings-input settings-select"><option value=dark>Dark</option><option value=light>Light</option></select><p class=settings-hint>Choose the application color scheme. Takes effect after saving.</p></div><div class=settings-field><label class=settings-label for=domain-policy-mode>Domain Restrictions</label><select id=domain-policy-mode class="settings-input settings-select"><option value=none>No restrictions</option><option value=allowlist>Allowlist (only listed domains)</option><option value=blocklist>Blocklist (block listed domains)</option></select></div><div class=settings-actions><button class=settings-save>Save</button><button class=settings-close>Close`), _tmpl$25 = /* @__PURE__ */ template(`<style>
8718
+ var _tmpl$$2 = /* @__PURE__ */ template(`<div class=welcome-banner-actions><button class="premium-btn premium-btn-upgrade">Try Premium free for 7 days — $5.99/mo after</button><span class=welcome-banner-note>Best for screenshots, saved sessions, credential vault, and longer autonomous runs.`), _tmpl$2$2 = /* @__PURE__ */ template(`<div class=welcome-banner><div class=welcome-banner-header><span class=welcome-banner-title>Welcome to Vessel</span><button class=welcome-banner-dismiss>&times;</button></div><p class=welcome-banner-text>Get started in three steps:</p><ol class=welcome-banner-steps><li><strong>Configure a chat provider</strong> — scroll to Chat Assistant below and add an API key</li><li><strong>Connect your agent harness</strong> — point it at the MCP endpoint shown below</li><li><strong>Learn the shortcuts</strong> — press <kbd>?</kbd> anytime for a quick reference`), _tmpl$3$1 = /* @__PURE__ */ template(`<div class="settings-callout settings-premium-callout"><div class=settings-callout-title>Start Vessel Premium with a 7-day free trial</div><p class=settings-callout-copy>Unlock screenshots, saved sessions, workflow tracking, table extraction, the credential vault, and longer autonomous runs without leaving the app.</p><div class=settings-premium-callout-actions><button class="premium-btn premium-btn-upgrade">Start 7-day free trial — $5.99/mo after</button><button class="premium-btn premium-btn-activate">See activation steps`), _tmpl$4$1 = /* @__PURE__ */ template(`<input id=max-tool-iterations class=settings-input type=number min=10 max=1000 placeholder=200>`), _tmpl$5$1 = /* @__PURE__ */ template(`<div class=vault-entries>`), _tmpl$6$1 = /* @__PURE__ */ template(`<div class=settings-field><label class=settings-label for=chat-provider>Provider</label><select id=chat-provider class="settings-input settings-select">`), _tmpl$7 = /* @__PURE__ */ template(`<span class=settings-label-optional> (optional)`), _tmpl$8 = /* @__PURE__ */ template(`<p class=settings-hint>An API key is already stored securely for this provider. Leave this blank to keep it, or enter a new key to replace it.`), _tmpl$9 = /* @__PURE__ */ template(`<p class=settings-hint>If your endpoint requires authentication, enter the API key or bearer token here.`), _tmpl$0 = /* @__PURE__ */ template(`<div class=settings-field><label class=settings-label for=chat-api-key>API Key</label><input id=chat-api-key class=settings-input type=password>`), _tmpl$1 = /* @__PURE__ */ template(`<select id=chat-model class="settings-input settings-select"style=flex:1>`), _tmpl$10 = /* @__PURE__ */ template(`<p class=settings-hint style=color:var(--error)>Could not fetch models — check your API key and connection.`), _tmpl$11 = /* @__PURE__ */ template(`<div class=settings-field><label class=settings-label for=chat-model>Model</label><div style=display:flex;gap:6px;align-items:center><button type=button class=settings-refresh-btn title="Refresh model list">↺`), _tmpl$12 = /* @__PURE__ */ template(`<div class=settings-field><label class=settings-label for=chat-base-url>Base URL</label><input id=chat-base-url class=settings-input>`), _tmpl$13 = /* @__PURE__ */ template(`<p class=settings-hint>Vessel auto-detects the active model from your configured \`llama-server\` base URL. For agent loops, run \`llama-server\` with \`--ctx-size 16384\` minimum and \`32768\` recommended.`), _tmpl$14 = /* @__PURE__ */ template(`<div class=premium-section><div class=premium-active-badge>Premium Active</div><p class=premium-detail></p><div class=premium-actions-row><button class="premium-btn premium-btn-manage">Manage Subscription</button><button class="premium-btn premium-btn-reset">Sign Out`), _tmpl$15 = /* @__PURE__ */ template(`<span class=vault-premium-badge>Premium`), _tmpl$16 = /* @__PURE__ */ template(`<p class=settings-hint style=margin-bottom:10px>Store credentials for agent-driven logins. Credentials are encrypted at rest and never sent to AI providers — they are filled directly into login forms with your consent.`), _tmpl$17 = /* @__PURE__ */ template(`<button class=vault-add-btn>+ Add Credential`), _tmpl$18 = /* @__PURE__ */ template(`<div class=vault-add-form><input class=settings-input placeholder="Label (e.g. Work GitHub)"><input class=settings-input placeholder="Domain pattern (e.g. github.com, *.aws.amazon.com)"><input class=settings-input placeholder="Username / email"><input class=settings-input type=password placeholder=Password><input class=settings-input placeholder="TOTP secret (optional, base32)"><input class=settings-input placeholder="Notes (optional)"><div class=vault-add-actions><button class="premium-btn premium-btn-activate">Save Credential</button><button class="premium-btn premium-btn-reset">Cancel`), _tmpl$19 = /* @__PURE__ */ template(`<button class=vault-add-btn>+ Add Profile`), _tmpl$20 = /* @__PURE__ */ template(`<div class=vault-add-form><input class=settings-input placeholder="Profile name (e.g. Personal, Work)"><div style="display:grid;grid-template-columns:1fr 1fr;gap:8px"><input class=settings-input placeholder="First name"><input class=settings-input placeholder="Last name"></div><div style="display:grid;grid-template-columns:1fr 1fr;gap:8px"><input class=settings-input placeholder=Email><input class=settings-input placeholder=Phone></div><input class=settings-input placeholder="Organization (optional)"><input class=settings-input placeholder="Address line 1"><input class=settings-input placeholder="Address line 2 (optional)"><div style="display:grid;grid-template-columns:1fr 1fr 1fr;gap:8px"><input class=settings-input placeholder=City><input class=settings-input placeholder=State><input class=settings-input placeholder="ZIP / Postal"></div><input class=settings-input placeholder=Country><div class=vault-add-actions><button class="premium-btn premium-btn-activate">Save Profile</button><button class="premium-btn premium-btn-reset">Cancel`), _tmpl$21 = /* @__PURE__ */ template(`<textarea class="settings-input settings-textarea"rows=4>`), _tmpl$22 = /* @__PURE__ */ template(`<p class=settings-hint>`), _tmpl$23 = /* @__PURE__ */ template(`<p class=settings-hint>Restrict which domains can be navigated to. Use allowlist mode for kiosk or supervised browsing, blocklist to block specific sites.`), _tmpl$24 = /* @__PURE__ */ template(`<div class=command-bar-overlay><div class=settings-panel><h2 class=settings-title>Runtime Settings</h2><div class=settings-callout><div class=settings-callout-title>External Agent Control</div><p class=settings-callout-copy>Vessel is configured to run under an external harness such as Hermes Agent or OpenClaw. Provider and model selection are not configured inside Vessel.</p></div><div class=settings-field><label class=settings-label for=default-homepage>Homepage</label><input id=default-homepage class=settings-input placeholder=https://start.duckduckgo.com><p class=settings-hint>The page that opens when you create a new tab or launch Vessel without restoring a previous session.</p></div><div class=settings-field><label class=settings-label for=default-search-engine>Default Search Engine</label><select id=default-search-engine class=settings-input><option value=none>None (disabled)</option></select><p class=settings-hint>The search engine used by the AI agent when it needs to search the web. "None" disables the fallback and forces the agent to use on-page search inputs only.</p></div><div class=settings-field><label class=settings-label for=download-path>Download Location</label><input id=download-path class=settings-input placeholder="Default: ~/Downloads"><p class=settings-hint>Directory for saved files. Leave blank to use the system default Downloads folder.</p></div><div class=settings-field><label class=settings-label for=mcp-port>MCP Port</label><input id=mcp-port class=settings-input placeholder=3100><p class=settings-hint>External harnesses connect to Vessel at <code>http://127.0.0.1:&lt;port&gt;/mcp</code>. Changing this value restarts the MCP server immediately.</p></div><div class=settings-field><label class=settings-label for=max-tool-iterations>Max Tool Iterations</label><p class=settings-hint></p></div><div class=settings-field><label class=settings-label for=obsidian-vault-path>Obsidian Vault Path</label><input id=obsidian-vault-path class=settings-input placeholder=/home/you/Documents/MyVault><p class=settings-hint>Optional. When set, Vessel memory tools can write markdown notes into this vault for research breadcrumbs and summaries.</p></div><div class=settings-field><label class=settings-label for=agent-transcript-mode>Agent Transcript Monitor</label><select id=agent-transcript-mode class="settings-input settings-select"><option value=off>Off</option><option value=summary>Summary HUD</option><option value=full>Full transcript</option></select><p class=settings-hint>Controls the in-browser transcript monitor when an external harness publishes reasoning or status updates into Vessel via the<code>vessel_publish_transcript</code> MCP tool. Summary HUD shows a compact 2-line status surface; Full transcript shows the recent entry list.</p></div><div class=settings-field><label class=settings-toggle><button type=button class=toggle-switch role=switch><span class=toggle-switch-thumb></span></button><span>Restore last browser session on launch</span></label></div><div class=settings-field><label class=settings-toggle><button type=button class=toggle-switch role=switch><span class=toggle-switch-thumb></span></button><span>Start bookmarks fresh on launch</span></label><p class=settings-hint>Off by default. When enabled, bookmark folders and saved pages are cleared each time Vessel starts.</p></div><div class=settings-section-divider></div><div class=settings-field><label class=settings-label>Saved Sessions</label><p class=settings-hint style=margin-bottom:10px>Save the current browser state (tabs, cookies, storage) as a named session. Restore it later from this panel.</p><div class=premium-activate-row style=margin-bottom:8px><input class="settings-input premium-email-input"placeholder="Session name"><button class="premium-btn premium-btn-activate">Save Current</button></div></div><div class=settings-section-divider></div><div class=settings-field><label class=settings-toggle><button type=button class=toggle-switch role=switch><span class=toggle-switch-thumb></span></button><span>Enable Chat Assistant</span></label><p class=settings-hint>Adds a Chat tab to the sidebar for conversing with an AI provider of your choice.</p></div><div class=settings-section-divider></div><div class=settings-field><label class=settings-label>Vessel Premium</label></div><div class=settings-section-divider></div><div class=settings-field><label class=settings-label>Agent Credential Vault</label></div><div class=settings-section-divider></div><div class=settings-field><label class=settings-label>Form Autofill</label><p class=settings-hint style=margin-bottom:10px>Store your info once. Vessel matches it to form fields on any site using labels, field names, and autocomplete hints.</p></div><div class=settings-section-divider></div><div class=settings-field><label class=settings-toggle><button type=button class=toggle-switch role=switch><span class=toggle-switch-thumb></span></button><span>Anonymous Usage Analytics</span></label><p class=settings-hint>Help improve Vessel by sending anonymous usage data (tool popularity, session duration, provider type). No URLs, page content, queries, or personal data is ever collected.</p></div><div class=settings-section-divider></div><div class=settings-field><label class=settings-label for=theme-select>Theme</label><select id=theme-select class="settings-input settings-select"><option value=dark>Dark</option><option value=light>Light</option></select><p class=settings-hint>Choose the application color scheme. Takes effect after saving.</p></div><div class=settings-field><label class=settings-label for=domain-policy-mode>Domain Restrictions</label><select id=domain-policy-mode class="settings-input settings-select"><option value=none>No restrictions</option><option value=allowlist>Allowlist (only listed domains)</option><option value=blocklist>Blocklist (block listed domains)</option></select></div><div class=settings-actions><button class=settings-save>Save</button><button class=settings-close>Close`), _tmpl$25 = /* @__PURE__ */ template(`<style>
8459
8719
  .settings-panel {
8460
8720
  width: min(440px, calc(100vw - 32px));
8461
8721
  max-height: calc(100vh - 48px);
@@ -8997,7 +9257,7 @@ var _tmpl$$2 = /* @__PURE__ */ template(`<div class=welcome-banner-actions><butt
8997
9257
  justify-content: flex-end;
8998
9258
  margin-top: 4px;
8999
9259
  }
9000
- `), _tmpl$26 = /* @__PURE__ */ template(`<div class="settings-input settings-input-disabled"title="Upgrade to Vessel Premium for unlimited tool iterations">50`), _tmpl$27 = /* @__PURE__ */ template(`<div class=settings-health-issues>`), _tmpl$28 = /* @__PURE__ */ template(`<div class=settings-health><div class=settings-callout-title>Runtime Health</div><p class=settings-hint>MCP status: <strong></strong> `), _tmpl$29 = /* @__PURE__ */ template(`<p class=settings-hint>Active endpoint: <code>`), _tmpl$30 = /* @__PURE__ */ template(`<div class=settings-health-issue><strong></strong><div>`), _tmpl$31 = /* @__PURE__ */ template(`<div>`), _tmpl$32 = /* @__PURE__ */ template(`<div class=vault-entry><div class=vault-entry-info><span class=vault-entry-label></span><span class=vault-entry-detail> &middot; <!> cookies &middot; <!> domains</span></div><div style=display:flex;gap:6px;align-items:center><button class="premium-btn premium-btn-activate"title="Restore this session (replaces current tabs and cookies)"style="padding:2px 10px;font-size:12px">Load</button><button class=vault-entry-remove title="Delete session">&times;`), _tmpl$33 = /* @__PURE__ */ template(`<option>`), _tmpl$34 = /* @__PURE__ */ template(`<input id=chat-model class=settings-input style=flex:1>`), _tmpl$35 = /* @__PURE__ */ template(`<p class=settings-hint style=color:var(--accent-primary)>`), _tmpl$36 = /* @__PURE__ */ template(`<div class=premium-activate-row><input class="settings-input premium-email-input"inputmode=numeric maxlength=6 placeholder="Enter 6-digit code"><button class="premium-btn premium-btn-activate">`), _tmpl$37 = /* @__PURE__ */ template(`<button class="premium-btn premium-btn-reset">Clear Saved Email`), _tmpl$38 = /* @__PURE__ */ template(`<div class=premium-section><p class=premium-description>Unlock screenshot/vision analysis, session management, Obsidian integration, workflow tracking, DevTools tools, table extraction, Agent Credential Vault, and unlimited tool iterations.</p><div class=premium-activate-row><input class="settings-input premium-email-input"type=email placeholder="Enter your subscription email"><button class="premium-btn premium-btn-activate"></button></div><button class="premium-btn premium-btn-upgrade">Subscribe to Premium — $5.99/mo after 7-day free trial`), _tmpl$39 = /* @__PURE__ */ template(`<p class=settings-status>`), _tmpl$40 = /* @__PURE__ */ template(`<p class=settings-hint>Securely store credentials for agent-driven logins. Upgrade to Premium to unlock the Agent Credential Vault.`), _tmpl$41 = /* @__PURE__ */ template(`<div class=vault-entry><div class=vault-entry-info><span class=vault-entry-label></span><span class=vault-entry-detail> &middot; </span></div><button class=vault-entry-remove title="Remove credential">&times;`), _tmpl$42 = /* @__PURE__ */ template(`<div class=vault-entry><div class=vault-entry-info><span class=vault-entry-label></span><span class=vault-entry-detail></span></div><div style=display:flex;gap:6px;align-items:center><button class="premium-btn premium-btn-activate"title="Fill forms on current page with this profile"style="padding:2px 10px;font-size:12px">Fill</button><button class=vault-entry-remove title="Remove profile">&times;`);
9260
+ `), _tmpl$26 = /* @__PURE__ */ template(`<option>`), _tmpl$27 = /* @__PURE__ */ template(`<div class="settings-input settings-input-disabled"title="Upgrade to Vessel Premium for unlimited tool iterations">50`), _tmpl$28 = /* @__PURE__ */ template(`<div class=settings-health-issues>`), _tmpl$29 = /* @__PURE__ */ template(`<div class=settings-health><div class=settings-callout-title>Runtime Health</div><p class=settings-hint>MCP status: <strong></strong> `), _tmpl$30 = /* @__PURE__ */ template(`<p class=settings-hint>Active endpoint: <code>`), _tmpl$31 = /* @__PURE__ */ template(`<div class=settings-health-issue><strong></strong><div>`), _tmpl$32 = /* @__PURE__ */ template(`<div>`), _tmpl$33 = /* @__PURE__ */ template(`<div class=vault-entry><div class=vault-entry-info><span class=vault-entry-label></span><span class=vault-entry-detail> &middot; <!> cookies &middot; <!> domains</span></div><div style=display:flex;gap:6px;align-items:center><button class="premium-btn premium-btn-activate"title="Restore this session (replaces current tabs and cookies)"style="padding:2px 10px;font-size:12px">Load</button><button class=vault-entry-remove title="Delete session">&times;`), _tmpl$34 = /* @__PURE__ */ template(`<input id=chat-model class=settings-input style=flex:1>`), _tmpl$35 = /* @__PURE__ */ template(`<p class=settings-hint style=color:var(--accent-primary)>`), _tmpl$36 = /* @__PURE__ */ template(`<div class=premium-activate-row><input class="settings-input premium-email-input"inputmode=numeric maxlength=6 placeholder="Enter 6-digit code"><button class="premium-btn premium-btn-activate">`), _tmpl$37 = /* @__PURE__ */ template(`<button class="premium-btn premium-btn-reset">Clear Saved Email`), _tmpl$38 = /* @__PURE__ */ template(`<div class=premium-section><p class=premium-description>Unlock screenshot/vision analysis, session management, Obsidian integration, workflow tracking, DevTools tools, table extraction, Agent Credential Vault, and unlimited tool iterations.</p><div class=premium-activate-row><input class="settings-input premium-email-input"type=email placeholder="Enter your subscription email"><button class="premium-btn premium-btn-activate"></button></div><button class="premium-btn premium-btn-upgrade">Subscribe to Premium — $5.99/mo after 7-day free trial`), _tmpl$39 = /* @__PURE__ */ template(`<p class=settings-status>`), _tmpl$40 = /* @__PURE__ */ template(`<p class=settings-hint>Securely store credentials for agent-driven logins. Upgrade to Premium to unlock the Agent Credential Vault.`), _tmpl$41 = /* @__PURE__ */ template(`<div class=vault-entry><div class=vault-entry-info><span class=vault-entry-label></span><span class=vault-entry-detail> &middot; </span></div><button class=vault-entry-remove title="Remove credential">&times;`), _tmpl$42 = /* @__PURE__ */ template(`<div class=vault-entry><div class=vault-entry-info><span class=vault-entry-label></span><span class=vault-entry-detail></span></div><div style=display:flex;gap:6px;align-items:center><button class="premium-btn premium-btn-activate"title="Fill forms on current page with this profile"style="padding:2px 10px;font-size:12px">Fill</button><button class=vault-entry-remove title="Remove profile">&times;`);
9001
9261
  const CHAT_PROVIDERS = Object.values(PROVIDERS).map((p) => ({
9002
9262
  id: p.id,
9003
9263
  name: p.name,
@@ -9026,6 +9286,7 @@ const Settings = () => {
9026
9286
  const [agentTranscriptMode, setAgentTranscriptMode] = createSignal("summary");
9027
9287
  const [health, setHealth] = createSignal(null);
9028
9288
  const [defaultUrl, setDefaultUrl] = createSignal("https://start.duckduckgo.com");
9289
+ const [defaultSearchEngine, setDefaultSearchEngine] = createSignal("duckduckgo");
9029
9290
  const [downloadPath, setDownloadPath] = createSignal("");
9030
9291
  const [status, setStatus] = createSignal(null);
9031
9292
  const [telemetryEnabled, setTelemetryEnabled] = createSignal(true);
@@ -9315,6 +9576,7 @@ const Settings = () => {
9315
9576
  const runtimeHealth = await window.vessel.settings.getHealth();
9316
9577
  setTheme(settings.theme ?? "dark");
9317
9578
  setDefaultUrl(settings.defaultUrl ?? "https://start.duckduckgo.com");
9579
+ setDefaultSearchEngine(settings.defaultSearchEngine ?? "duckduckgo");
9318
9580
  setDownloadPath(settings.downloadPath ?? "");
9319
9581
  setAutoRestoreSession(settings.autoRestoreSession ?? true);
9320
9582
  setClearBookmarksOnLaunch(settings.clearBookmarksOnLaunch ?? false);
@@ -9416,6 +9678,7 @@ const Settings = () => {
9416
9678
  await window.vessel.settings.set("maxToolIterations", Math.max(10, Math.min(1e3, parsedIterations)));
9417
9679
  await window.vessel.settings.set("agentTranscriptMode", agentTranscriptMode());
9418
9680
  await window.vessel.settings.set("telemetryEnabled", telemetryEnabled());
9681
+ await window.vessel.settings.set("defaultSearchEngine", defaultSearchEngine());
9419
9682
  const domains = domainList().split("\n").map((d) => d.trim()).filter((d) => d.length > 0);
9420
9683
  const domainPolicy = domainMode() === "allowlist" ? {
9421
9684
  allowedDomains: domains,
@@ -9457,13 +9720,13 @@ const Settings = () => {
9457
9720
  },
9458
9721
  get children() {
9459
9722
  return [(() => {
9460
- var _el$ = _tmpl$24(), _el$2 = _el$.firstChild, _el$3 = _el$2.firstChild, _el$11 = _el$3.nextSibling, _el$18 = _el$11.nextSibling, _el$19 = _el$18.firstChild, _el$20 = _el$19.nextSibling, _el$21 = _el$18.nextSibling, _el$22 = _el$21.firstChild, _el$23 = _el$22.nextSibling, _el$24 = _el$21.nextSibling, _el$25 = _el$24.firstChild, _el$26 = _el$25.nextSibling, _el$27 = _el$24.nextSibling, _el$28 = _el$27.firstChild, _el$30 = _el$28.nextSibling, _el$31 = _el$27.nextSibling, _el$32 = _el$31.firstChild, _el$33 = _el$32.nextSibling, _el$34 = _el$31.nextSibling, _el$35 = _el$34.firstChild, _el$36 = _el$35.nextSibling, _el$37 = _el$34.nextSibling, _el$38 = _el$37.firstChild, _el$39 = _el$38.firstChild, _el$40 = _el$37.nextSibling, _el$41 = _el$40.firstChild, _el$42 = _el$41.firstChild, _el$43 = _el$40.nextSibling, _el$44 = _el$43.nextSibling, _el$45 = _el$44.firstChild, _el$46 = _el$45.nextSibling, _el$47 = _el$46.nextSibling, _el$48 = _el$47.firstChild, _el$49 = _el$48.nextSibling, _el$51 = _el$44.nextSibling, _el$52 = _el$51.nextSibling, _el$53 = _el$52.firstChild, _el$54 = _el$53.firstChild, _el$75 = _el$52.nextSibling, _el$76 = _el$75.nextSibling;
9461
- _el$76.firstChild;
9462
- var _el$85 = _el$76.nextSibling, _el$86 = _el$85.nextSibling, _el$87 = _el$86.firstChild;
9463
- _el$87.firstChild;
9464
- var _el$103 = _el$86.nextSibling, _el$104 = _el$103.nextSibling, _el$105 = _el$104.firstChild;
9465
- _el$105.nextSibling;
9466
- var _el$128 = _el$104.nextSibling, _el$129 = _el$128.nextSibling, _el$130 = _el$129.firstChild, _el$131 = _el$130.firstChild, _el$132 = _el$129.nextSibling, _el$133 = _el$132.nextSibling, _el$134 = _el$133.firstChild, _el$135 = _el$134.nextSibling, _el$136 = _el$133.nextSibling, _el$137 = _el$136.firstChild, _el$138 = _el$137.nextSibling, _el$142 = _el$136.nextSibling, _el$143 = _el$142.firstChild, _el$144 = _el$143.nextSibling;
9723
+ var _el$ = _tmpl$24(), _el$2 = _el$.firstChild, _el$3 = _el$2.firstChild, _el$11 = _el$3.nextSibling, _el$18 = _el$11.nextSibling, _el$19 = _el$18.firstChild, _el$20 = _el$19.nextSibling, _el$21 = _el$18.nextSibling, _el$22 = _el$21.firstChild, _el$23 = _el$22.nextSibling, _el$24 = _el$23.firstChild, _el$25 = _el$21.nextSibling, _el$26 = _el$25.firstChild, _el$27 = _el$26.nextSibling, _el$28 = _el$25.nextSibling, _el$29 = _el$28.firstChild, _el$30 = _el$29.nextSibling, _el$31 = _el$28.nextSibling, _el$32 = _el$31.firstChild, _el$34 = _el$32.nextSibling, _el$35 = _el$31.nextSibling, _el$36 = _el$35.firstChild, _el$37 = _el$36.nextSibling, _el$38 = _el$35.nextSibling, _el$39 = _el$38.firstChild, _el$40 = _el$39.nextSibling, _el$41 = _el$38.nextSibling, _el$42 = _el$41.firstChild, _el$43 = _el$42.firstChild, _el$44 = _el$41.nextSibling, _el$45 = _el$44.firstChild, _el$46 = _el$45.firstChild, _el$47 = _el$44.nextSibling, _el$48 = _el$47.nextSibling, _el$49 = _el$48.firstChild, _el$50 = _el$49.nextSibling, _el$51 = _el$50.nextSibling, _el$52 = _el$51.firstChild, _el$53 = _el$52.nextSibling, _el$55 = _el$48.nextSibling, _el$56 = _el$55.nextSibling, _el$57 = _el$56.firstChild, _el$58 = _el$57.firstChild, _el$79 = _el$56.nextSibling, _el$80 = _el$79.nextSibling;
9724
+ _el$80.firstChild;
9725
+ var _el$89 = _el$80.nextSibling, _el$90 = _el$89.nextSibling, _el$91 = _el$90.firstChild;
9726
+ _el$91.firstChild;
9727
+ var _el$107 = _el$90.nextSibling, _el$108 = _el$107.nextSibling, _el$109 = _el$108.firstChild;
9728
+ _el$109.nextSibling;
9729
+ var _el$132 = _el$108.nextSibling, _el$133 = _el$132.nextSibling, _el$134 = _el$133.firstChild, _el$135 = _el$134.firstChild, _el$136 = _el$133.nextSibling, _el$137 = _el$136.nextSibling, _el$138 = _el$137.firstChild, _el$139 = _el$138.nextSibling, _el$140 = _el$137.nextSibling, _el$141 = _el$140.firstChild, _el$142 = _el$141.nextSibling, _el$146 = _el$140.nextSibling, _el$147 = _el$146.firstChild, _el$148 = _el$147.nextSibling;
9467
9730
  addEventListener(_el$, "click", closeSettings, true);
9468
9731
  _el$2.$$keydown = handleKeyDown;
9469
9732
  _el$2.$$click = (e) => e.stopPropagation();
@@ -9513,25 +9776,37 @@ const Settings = () => {
9513
9776
  }), _el$18);
9514
9777
  _el$20.$$input = (e) => setDefaultUrl(e.currentTarget.value);
9515
9778
  setAttribute(_el$20, "spellcheck", false);
9516
- _el$23.$$input = (e) => setDownloadPath(e.currentTarget.value);
9517
- setAttribute(_el$23, "spellcheck", false);
9518
- _el$26.$$input = (e) => setMcpPort(e.currentTarget.value);
9519
- setAttribute(_el$26, "spellcheck", false);
9520
- insert(_el$27, createComponent(Show, {
9779
+ _el$23.addEventListener("change", (e) => setDefaultSearchEngine(e.currentTarget.value));
9780
+ insert(_el$23, createComponent(For, {
9781
+ get each() {
9782
+ return Object.entries(SEARCH_ENGINE_PRESETS);
9783
+ },
9784
+ children: ([id, preset]) => (() => {
9785
+ var _el$150 = _tmpl$26();
9786
+ _el$150.value = id;
9787
+ insert(_el$150, () => preset.label);
9788
+ return _el$150;
9789
+ })()
9790
+ }), _el$24);
9791
+ _el$27.$$input = (e) => setDownloadPath(e.currentTarget.value);
9792
+ setAttribute(_el$27, "spellcheck", false);
9793
+ _el$30.$$input = (e) => setMcpPort(e.currentTarget.value);
9794
+ setAttribute(_el$30, "spellcheck", false);
9795
+ insert(_el$31, createComponent(Show, {
9521
9796
  get when() {
9522
9797
  return premiumActive();
9523
9798
  },
9524
9799
  get fallback() {
9525
- return _tmpl$26();
9800
+ return _tmpl$27();
9526
9801
  },
9527
9802
  get children() {
9528
- var _el$29 = _tmpl$4$1();
9529
- _el$29.$$input = (e) => setMaxToolIterations(e.currentTarget.value);
9530
- createRenderEffect(() => _el$29.value = maxToolIterations());
9531
- return _el$29;
9803
+ var _el$33 = _tmpl$4$1();
9804
+ _el$33.$$input = (e) => setMaxToolIterations(e.currentTarget.value);
9805
+ createRenderEffect(() => _el$33.value = maxToolIterations());
9806
+ return _el$33;
9532
9807
  }
9533
- }), _el$30);
9534
- insert(_el$30, createComponent(Show, {
9808
+ }), _el$34);
9809
+ insert(_el$34, createComponent(Show, {
9535
9810
  get when() {
9536
9811
  return premiumActive();
9537
9812
  },
@@ -9543,65 +9818,65 @@ const Settings = () => {
9543
9818
  return health();
9544
9819
  },
9545
9820
  children: (currentHealth) => (() => {
9546
- var _el$147 = _tmpl$28(), _el$148 = _el$147.firstChild, _el$149 = _el$148.nextSibling, _el$150 = _el$149.firstChild, _el$152 = _el$150.nextSibling;
9547
- _el$152.nextSibling;
9548
- insert(_el$152, () => currentHealth().mcp.status);
9549
- insert(_el$149, () => currentHealth().mcp.message, null);
9550
- insert(_el$147, createComponent(Show, {
9821
+ var _el$152 = _tmpl$29(), _el$153 = _el$152.firstChild, _el$154 = _el$153.nextSibling, _el$155 = _el$154.firstChild, _el$157 = _el$155.nextSibling;
9822
+ _el$157.nextSibling;
9823
+ insert(_el$157, () => currentHealth().mcp.status);
9824
+ insert(_el$154, () => currentHealth().mcp.message, null);
9825
+ insert(_el$152, createComponent(Show, {
9551
9826
  get when() {
9552
9827
  return currentHealth().mcp.endpoint;
9553
9828
  },
9554
9829
  children: (endpoint) => (() => {
9555
- var _el$155 = _tmpl$29(), _el$156 = _el$155.firstChild, _el$157 = _el$156.nextSibling;
9556
- insert(_el$157, endpoint);
9557
- return _el$155;
9830
+ var _el$160 = _tmpl$30(), _el$161 = _el$160.firstChild, _el$162 = _el$161.nextSibling;
9831
+ insert(_el$162, endpoint);
9832
+ return _el$160;
9558
9833
  })()
9559
9834
  }), null);
9560
- insert(_el$147, createComponent(Show, {
9835
+ insert(_el$152, createComponent(Show, {
9561
9836
  get when() {
9562
9837
  return currentHealth().startupIssues.length > 0;
9563
9838
  },
9564
9839
  get children() {
9565
- var _el$154 = _tmpl$27();
9566
- insert(_el$154, () => currentHealth().startupIssues.map((issue) => (() => {
9567
- var _el$158 = _tmpl$30(), _el$159 = _el$158.firstChild, _el$160 = _el$159.nextSibling;
9568
- insert(_el$159, () => issue.title);
9569
- insert(_el$160, () => issue.detail);
9570
- insert(_el$158, createComponent(Show, {
9840
+ var _el$159 = _tmpl$28();
9841
+ insert(_el$159, () => currentHealth().startupIssues.map((issue) => (() => {
9842
+ var _el$163 = _tmpl$31(), _el$164 = _el$163.firstChild, _el$165 = _el$164.nextSibling;
9843
+ insert(_el$164, () => issue.title);
9844
+ insert(_el$165, () => issue.detail);
9845
+ insert(_el$163, createComponent(Show, {
9571
9846
  get when() {
9572
9847
  return issue.action;
9573
9848
  },
9574
9849
  children: (action) => (() => {
9575
- var _el$161 = _tmpl$31();
9576
- insert(_el$161, action);
9577
- return _el$161;
9850
+ var _el$166 = _tmpl$32();
9851
+ insert(_el$166, action);
9852
+ return _el$166;
9578
9853
  })()
9579
9854
  }), null);
9580
9855
  createRenderEffect((_p$) => {
9581
9856
  var _v$1 = !!(issue.severity === "warning"), _v$10 = !!(issue.severity === "error");
9582
- _v$1 !== _p$.e && _el$158.classList.toggle("warning", _p$.e = _v$1);
9583
- _v$10 !== _p$.t && _el$158.classList.toggle("error", _p$.t = _v$10);
9857
+ _v$1 !== _p$.e && _el$163.classList.toggle("warning", _p$.e = _v$1);
9858
+ _v$10 !== _p$.t && _el$163.classList.toggle("error", _p$.t = _v$10);
9584
9859
  return _p$;
9585
9860
  }, {
9586
9861
  e: void 0,
9587
9862
  t: void 0
9588
9863
  });
9589
- return _el$158;
9864
+ return _el$163;
9590
9865
  })()));
9591
- return _el$154;
9866
+ return _el$159;
9592
9867
  }
9593
9868
  }), null);
9594
- return _el$147;
9869
+ return _el$152;
9595
9870
  })()
9596
- }), _el$31);
9597
- _el$33.$$input = (e) => setObsidianVaultPath(e.currentTarget.value);
9598
- setAttribute(_el$33, "spellcheck", false);
9599
- _el$36.addEventListener("change", (e) => setAgentTranscriptMode(e.currentTarget.value));
9600
- _el$39.$$click = () => setAutoRestoreSession(!autoRestoreSession());
9601
- _el$42.$$click = () => setClearBookmarksOnLaunch(!clearBookmarksOnLaunch());
9602
- _el$48.$$input = (e) => setSessionSaveName(e.currentTarget.value);
9603
- setAttribute(_el$48, "spellcheck", false);
9604
- _el$49.$$click = async () => {
9871
+ }), _el$35);
9872
+ _el$37.$$input = (e) => setObsidianVaultPath(e.currentTarget.value);
9873
+ setAttribute(_el$37, "spellcheck", false);
9874
+ _el$40.addEventListener("change", (e) => setAgentTranscriptMode(e.currentTarget.value));
9875
+ _el$43.$$click = () => setAutoRestoreSession(!autoRestoreSession());
9876
+ _el$46.$$click = () => setClearBookmarksOnLaunch(!clearBookmarksOnLaunch());
9877
+ _el$52.$$input = (e) => setSessionSaveName(e.currentTarget.value);
9878
+ setAttribute(_el$52, "spellcheck", false);
9879
+ _el$53.$$click = async () => {
9605
9880
  try {
9606
9881
  await window.vessel.sessions.save(sessionSaveName().trim());
9607
9882
  setSessionSaveName("");
@@ -9618,25 +9893,25 @@ const Settings = () => {
9618
9893
  });
9619
9894
  }
9620
9895
  };
9621
- insert(_el$44, createComponent(Show, {
9896
+ insert(_el$48, createComponent(Show, {
9622
9897
  get when() {
9623
9898
  return sessionList().length > 0;
9624
9899
  },
9625
9900
  get children() {
9626
- var _el$50 = _tmpl$5$1();
9627
- insert(_el$50, createComponent(For, {
9901
+ var _el$54 = _tmpl$5$1();
9902
+ insert(_el$54, createComponent(For, {
9628
9903
  get each() {
9629
9904
  return sessionList();
9630
9905
  },
9631
9906
  children: (s) => (() => {
9632
- var _el$162 = _tmpl$32(), _el$163 = _el$162.firstChild, _el$164 = _el$163.firstChild, _el$165 = _el$164.nextSibling, _el$166 = _el$165.firstChild, _el$172 = _el$166.nextSibling, _el$168 = _el$172.nextSibling, _el$173 = _el$168.nextSibling;
9633
- _el$173.nextSibling;
9634
- var _el$174 = _el$163.nextSibling, _el$175 = _el$174.firstChild, _el$176 = _el$175.nextSibling;
9635
- insert(_el$164, () => s.name);
9636
- insert(_el$165, () => new Date(s.updatedAt).toLocaleDateString(), _el$166);
9637
- insert(_el$165, () => s.cookieCount, _el$172);
9638
- insert(_el$165, () => s.domains.length, _el$173);
9639
- _el$175.$$click = async () => {
9907
+ var _el$167 = _tmpl$33(), _el$168 = _el$167.firstChild, _el$169 = _el$168.firstChild, _el$170 = _el$169.nextSibling, _el$171 = _el$170.firstChild, _el$177 = _el$171.nextSibling, _el$173 = _el$177.nextSibling, _el$178 = _el$173.nextSibling;
9908
+ _el$178.nextSibling;
9909
+ var _el$179 = _el$168.nextSibling, _el$180 = _el$179.firstChild, _el$181 = _el$180.nextSibling;
9910
+ insert(_el$169, () => s.name);
9911
+ insert(_el$170, () => new Date(s.updatedAt).toLocaleDateString(), _el$171);
9912
+ insert(_el$170, () => s.cookieCount, _el$177);
9913
+ insert(_el$170, () => s.domains.length, _el$178);
9914
+ _el$180.$$click = async () => {
9640
9915
  try {
9641
9916
  await window.vessel.sessions.load(s.name);
9642
9917
  setStatus({
@@ -9651,25 +9926,25 @@ const Settings = () => {
9651
9926
  });
9652
9927
  }
9653
9928
  };
9654
- _el$176.$$click = async () => {
9929
+ _el$181.$$click = async () => {
9655
9930
  await window.vessel.sessions.delete(s.name);
9656
9931
  await loadSessionList();
9657
9932
  };
9658
- return _el$162;
9933
+ return _el$167;
9659
9934
  })()
9660
9935
  }));
9661
- return _el$50;
9936
+ return _el$54;
9662
9937
  }
9663
9938
  }), null);
9664
- _el$54.$$click = () => setChatEnabled(!chatEnabled());
9939
+ _el$58.$$click = () => setChatEnabled(!chatEnabled());
9665
9940
  insert(_el$2, createComponent(Show, {
9666
9941
  get when() {
9667
9942
  return chatEnabled();
9668
9943
  },
9669
9944
  get children() {
9670
9945
  return [(() => {
9671
- var _el$55 = _tmpl$6$1(), _el$56 = _el$55.firstChild, _el$57 = _el$56.nextSibling;
9672
- _el$57.addEventListener("change", (e) => {
9946
+ var _el$59 = _tmpl$6$1(), _el$60 = _el$59.firstChild, _el$61 = _el$60.nextSibling;
9947
+ _el$61.addEventListener("change", (e) => {
9673
9948
  const id = e.currentTarget.value;
9674
9949
  setChatProviderId(id);
9675
9950
  setChatModel("");
@@ -9679,26 +9954,26 @@ const Settings = () => {
9679
9954
  setProviderModels([]);
9680
9955
  setModelFetchState("idle");
9681
9956
  });
9682
- insert(_el$57, createComponent(For, {
9957
+ insert(_el$61, createComponent(For, {
9683
9958
  each: CHAT_PROVIDERS,
9684
9959
  children: (p) => (() => {
9685
- var _el$177 = _tmpl$33();
9686
- insert(_el$177, () => p.name);
9687
- createRenderEffect(() => _el$177.value = p.id);
9688
- return _el$177;
9960
+ var _el$182 = _tmpl$26();
9961
+ insert(_el$182, () => p.name);
9962
+ createRenderEffect(() => _el$182.value = p.id);
9963
+ return _el$182;
9689
9964
  })()
9690
9965
  }));
9691
- createRenderEffect(() => _el$57.value = chatProviderId());
9692
- return _el$55;
9966
+ createRenderEffect(() => _el$61.value = chatProviderId());
9967
+ return _el$59;
9693
9968
  })(), createComponent(Show, {
9694
9969
  get when() {
9695
9970
  return chatProviderMeta().requiresKey || chatProviderId() === "custom";
9696
9971
  },
9697
9972
  get children() {
9698
- var _el$58 = _tmpl$0(), _el$59 = _el$58.firstChild;
9699
- _el$59.firstChild;
9700
- var _el$62 = _el$59.nextSibling;
9701
- insert(_el$59, createComponent(Show, {
9973
+ var _el$62 = _tmpl$0(), _el$63 = _el$62.firstChild;
9974
+ _el$63.firstChild;
9975
+ var _el$66 = _el$63.nextSibling;
9976
+ insert(_el$63, createComponent(Show, {
9702
9977
  get when() {
9703
9978
  return !chatProviderMeta().requiresKey;
9704
9979
  },
@@ -9706,14 +9981,14 @@ const Settings = () => {
9706
9981
  return _tmpl$7();
9707
9982
  }
9708
9983
  }), null);
9709
- _el$62.$$input = (e) => {
9984
+ _el$66.$$input = (e) => {
9710
9985
  setChatApiKey(e.currentTarget.value);
9711
9986
  if (e.currentTarget.value.trim()) {
9712
9987
  setChatHasStoredApiKey(true);
9713
9988
  }
9714
9989
  };
9715
- setAttribute(_el$62, "spellcheck", false);
9716
- insert(_el$58, createComponent(Show, {
9990
+ setAttribute(_el$66, "spellcheck", false);
9991
+ insert(_el$62, createComponent(Show, {
9717
9992
  get when() {
9718
9993
  return memo(() => !!chatHasStoredApiKey())() && !chatApiKey().trim();
9719
9994
  },
@@ -9721,7 +9996,7 @@ const Settings = () => {
9721
9996
  return _tmpl$8();
9722
9997
  }
9723
9998
  }), null);
9724
- insert(_el$58, createComponent(Show, {
9999
+ insert(_el$62, createComponent(Show, {
9725
10000
  get when() {
9726
10001
  return chatProviderId() === "custom";
9727
10002
  },
@@ -9729,46 +10004,46 @@ const Settings = () => {
9729
10004
  return _tmpl$9();
9730
10005
  }
9731
10006
  }), null);
9732
- createRenderEffect(() => setAttribute(_el$62, "placeholder", chatHasStoredApiKey() && !chatApiKey().trim() ? "Stored securely. Enter a new key to replace it." : chatProviderMeta().keyPlaceholder || "Bearer token or API key"));
9733
- createRenderEffect(() => _el$62.value = chatApiKey());
9734
- return _el$58;
10007
+ createRenderEffect(() => setAttribute(_el$66, "placeholder", chatHasStoredApiKey() && !chatApiKey().trim() ? "Stored securely. Enter a new key to replace it." : chatProviderMeta().keyPlaceholder || "Bearer token or API key"));
10008
+ createRenderEffect(() => _el$66.value = chatApiKey());
10009
+ return _el$62;
9735
10010
  }
9736
10011
  }), (() => {
9737
- var _el$65 = _tmpl$11(), _el$66 = _el$65.firstChild, _el$67 = _el$66.nextSibling, _el$69 = _el$67.firstChild;
9738
- insert(_el$67, createComponent(Show, {
10012
+ var _el$69 = _tmpl$11(), _el$70 = _el$69.firstChild, _el$71 = _el$70.nextSibling, _el$73 = _el$71.firstChild;
10013
+ insert(_el$71, createComponent(Show, {
9739
10014
  get when() {
9740
10015
  return providerModels().length > 0;
9741
10016
  },
9742
10017
  get fallback() {
9743
10018
  return (() => {
9744
- var _el$178 = _tmpl$34();
9745
- _el$178.$$input = (e) => setChatModel(e.currentTarget.value);
9746
- setAttribute(_el$178, "spellcheck", false);
9747
- createRenderEffect(() => setAttribute(_el$178, "placeholder", modelFetchState() === "loading" ? "Fetching models…" : chatProviderMeta().requiresKey && !chatApiKey().trim() && !chatHasStoredApiKey() ? "Enter API key to load models" : chatProviderMeta().defaultModel || "model name"));
9748
- createRenderEffect(() => _el$178.value = chatModel());
9749
- return _el$178;
10019
+ var _el$183 = _tmpl$34();
10020
+ _el$183.$$input = (e) => setChatModel(e.currentTarget.value);
10021
+ setAttribute(_el$183, "spellcheck", false);
10022
+ createRenderEffect(() => setAttribute(_el$183, "placeholder", modelFetchState() === "loading" ? "Fetching models…" : chatProviderMeta().requiresKey && !chatApiKey().trim() && !chatHasStoredApiKey() ? "Enter API key to load models" : chatProviderMeta().defaultModel || "model name"));
10023
+ createRenderEffect(() => _el$183.value = chatModel());
10024
+ return _el$183;
9750
10025
  })();
9751
10026
  },
9752
10027
  get children() {
9753
- var _el$68 = _tmpl$1();
9754
- _el$68.addEventListener("change", (e) => setChatModel(e.currentTarget.value));
9755
- insert(_el$68, createComponent(For, {
10028
+ var _el$72 = _tmpl$1();
10029
+ _el$72.addEventListener("change", (e) => setChatModel(e.currentTarget.value));
10030
+ insert(_el$72, createComponent(For, {
9756
10031
  get each() {
9757
10032
  return providerModels();
9758
10033
  },
9759
10034
  children: (m) => (() => {
9760
- var _el$179 = _tmpl$33();
9761
- _el$179.value = m;
9762
- insert(_el$179, m);
9763
- return _el$179;
10035
+ var _el$184 = _tmpl$26();
10036
+ _el$184.value = m;
10037
+ insert(_el$184, m);
10038
+ return _el$184;
9764
10039
  })()
9765
10040
  }));
9766
- createRenderEffect(() => _el$68.value = chatModel());
9767
- return _el$68;
10041
+ createRenderEffect(() => _el$72.value = chatModel());
10042
+ return _el$72;
9768
10043
  }
9769
- }), _el$69);
9770
- _el$69.$$click = doFetchModels;
9771
- insert(_el$65, createComponent(Show, {
10044
+ }), _el$73);
10045
+ _el$73.$$click = doFetchModels;
10046
+ insert(_el$69, createComponent(Show, {
9772
10047
  get when() {
9773
10048
  return modelFetchState() === "error";
9774
10049
  },
@@ -9776,29 +10051,29 @@ const Settings = () => {
9776
10051
  return _tmpl$10();
9777
10052
  }
9778
10053
  }), null);
9779
- insert(_el$65, createComponent(Show, {
10054
+ insert(_el$69, createComponent(Show, {
9780
10055
  get when() {
9781
10056
  return modelFetchWarning();
9782
10057
  },
9783
10058
  children: (warning) => (() => {
9784
- var _el$180 = _tmpl$35();
9785
- insert(_el$180, warning);
9786
- return _el$180;
10059
+ var _el$185 = _tmpl$35();
10060
+ insert(_el$185, warning);
10061
+ return _el$185;
9787
10062
  })()
9788
10063
  }), null);
9789
- createRenderEffect(() => _el$69.disabled = modelFetchState() === "loading");
9790
- return _el$65;
10064
+ createRenderEffect(() => _el$73.disabled = modelFetchState() === "loading");
10065
+ return _el$69;
9791
10066
  })(), createComponent(Show, {
9792
10067
  get when() {
9793
10068
  return chatProviderMeta().needsBaseUrl || chatProviderId() === "custom";
9794
10069
  },
9795
10070
  get children() {
9796
- var _el$71 = _tmpl$12(), _el$72 = _el$71.firstChild, _el$73 = _el$72.nextSibling;
9797
- _el$73.$$input = (e) => setChatBaseUrl(e.currentTarget.value);
9798
- setAttribute(_el$73, "spellcheck", false);
9799
- createRenderEffect(() => setAttribute(_el$73, "placeholder", chatProviderMeta().defaultBaseUrl ?? "https://..."));
9800
- createRenderEffect(() => _el$73.value = chatBaseUrl());
9801
- return _el$71;
10071
+ var _el$75 = _tmpl$12(), _el$76 = _el$75.firstChild, _el$77 = _el$76.nextSibling;
10072
+ _el$77.$$input = (e) => setChatBaseUrl(e.currentTarget.value);
10073
+ setAttribute(_el$77, "spellcheck", false);
10074
+ createRenderEffect(() => setAttribute(_el$77, "placeholder", chatProviderMeta().defaultBaseUrl ?? "https://..."));
10075
+ createRenderEffect(() => _el$77.value = chatBaseUrl());
10076
+ return _el$75;
9802
10077
  }
9803
10078
  }), createComponent(Show, {
9804
10079
  get when() {
@@ -9809,15 +10084,15 @@ const Settings = () => {
9809
10084
  }
9810
10085
  })];
9811
10086
  }
9812
- }), _el$75);
9813
- insert(_el$76, createComponent(Show, {
10087
+ }), _el$79);
10088
+ insert(_el$80, createComponent(Show, {
9814
10089
  get when() {
9815
10090
  return premiumActive();
9816
10091
  },
9817
10092
  get fallback() {
9818
10093
  return (() => {
9819
- var _el$181 = _tmpl$38(), _el$182 = _el$181.firstChild, _el$183 = _el$182.nextSibling, _el$184 = _el$183.firstChild, _el$185 = _el$184.nextSibling, _el$189 = _el$183.nextSibling;
9820
- _el$184.$$input = (e) => {
10094
+ var _el$186 = _tmpl$38(), _el$187 = _el$186.firstChild, _el$188 = _el$187.nextSibling, _el$189 = _el$188.firstChild, _el$190 = _el$189.nextSibling, _el$194 = _el$188.nextSibling;
10095
+ _el$189.$$input = (e) => {
9821
10096
  const nextEmail = e.currentTarget.value;
9822
10097
  if (nextEmail.trim().toLowerCase() !== premiumEmail().trim().toLowerCase()) {
9823
10098
  resetPremiumActivationFlow();
@@ -9825,8 +10100,8 @@ const Settings = () => {
9825
10100
  }
9826
10101
  setPremiumEmail(nextEmail);
9827
10102
  };
9828
- setAttribute(_el$184, "spellcheck", false);
9829
- _el$185.$$click = async () => {
10103
+ setAttribute(_el$189, "spellcheck", false);
10104
+ _el$190.$$click = async () => {
9830
10105
  setPremiumLoading(true);
9831
10106
  setPremiumMessage(null);
9832
10107
  try {
@@ -9855,23 +10130,23 @@ const Settings = () => {
9855
10130
  setPremiumLoading(false);
9856
10131
  }
9857
10132
  };
9858
- insert(_el$185, (() => {
10133
+ insert(_el$190, (() => {
9859
10134
  var _c$ = memo(() => !!premiumLoading());
9860
10135
  return () => _c$() ? "Sending..." : premiumCodeSent() ? "Resend Code" : "Send Code";
9861
10136
  })());
9862
- insert(_el$181, createComponent(Show, {
10137
+ insert(_el$186, createComponent(Show, {
9863
10138
  get when() {
9864
10139
  return premiumCodeSent();
9865
10140
  },
9866
10141
  get children() {
9867
- var _el$186 = _tmpl$36(), _el$187 = _el$186.firstChild, _el$188 = _el$187.nextSibling;
9868
- _el$187.$$input = (e) => {
10142
+ var _el$191 = _tmpl$36(), _el$192 = _el$191.firstChild, _el$193 = _el$192.nextSibling;
10143
+ _el$192.$$input = (e) => {
9869
10144
  const nextCode = e.currentTarget.value.replace(/\D+/g, "").slice(0, 6);
9870
10145
  setPremiumCode(nextCode);
9871
10146
  setPremiumMessage(null);
9872
10147
  };
9873
- setAttribute(_el$187, "spellcheck", false);
9874
- _el$188.$$click = async () => {
10148
+ setAttribute(_el$192, "spellcheck", false);
10149
+ _el$193.$$click = async () => {
9875
10150
  setPremiumLoading(true);
9876
10151
  setPremiumMessage(null);
9877
10152
  try {
@@ -9898,60 +10173,60 @@ const Settings = () => {
9898
10173
  setPremiumLoading(false);
9899
10174
  }
9900
10175
  };
9901
- insert(_el$188, () => premiumLoading() ? "Verifying..." : "Verify Code");
9902
- createRenderEffect(() => _el$188.disabled = premiumLoading() || !premiumEmail().trim() || premiumCode().trim().length !== 6 || !premiumChallengeToken());
9903
- createRenderEffect(() => _el$187.value = premiumCode());
9904
- return _el$186;
10176
+ insert(_el$193, () => premiumLoading() ? "Verifying..." : "Verify Code");
10177
+ createRenderEffect(() => _el$193.disabled = premiumLoading() || !premiumEmail().trim() || premiumCode().trim().length !== 6 || !premiumChallengeToken());
10178
+ createRenderEffect(() => _el$192.value = premiumCode());
10179
+ return _el$191;
9905
10180
  }
9906
- }), _el$189);
9907
- _el$189.$$click = () => {
10181
+ }), _el$194);
10182
+ _el$194.$$click = () => {
9908
10183
  startPremiumCheckout();
9909
10184
  };
9910
- insert(_el$181, createComponent(Show, {
10185
+ insert(_el$186, createComponent(Show, {
9911
10186
  get when() {
9912
10187
  return premiumMessage();
9913
10188
  },
9914
10189
  children: (msg) => (() => {
9915
- var _el$191 = _tmpl$39();
9916
- insert(_el$191, () => msg().text);
10190
+ var _el$196 = _tmpl$39();
10191
+ insert(_el$196, () => msg().text);
9917
10192
  createRenderEffect((_p$) => {
9918
10193
  var _v$11 = !!(msg().kind === "success"), _v$12 = !!(msg().kind === "error");
9919
- _v$11 !== _p$.e && _el$191.classList.toggle("success", _p$.e = _v$11);
9920
- _v$12 !== _p$.t && _el$191.classList.toggle("error", _p$.t = _v$12);
10194
+ _v$11 !== _p$.e && _el$196.classList.toggle("success", _p$.e = _v$11);
10195
+ _v$12 !== _p$.t && _el$196.classList.toggle("error", _p$.t = _v$12);
9921
10196
  return _p$;
9922
10197
  }, {
9923
10198
  e: void 0,
9924
10199
  t: void 0
9925
10200
  });
9926
- return _el$191;
10201
+ return _el$196;
9927
10202
  })()
9928
10203
  }), null);
9929
- insert(_el$181, createComponent(Show, {
10204
+ insert(_el$186, createComponent(Show, {
9930
10205
  get when() {
9931
10206
  return premiumState().email || premiumEmail();
9932
10207
  },
9933
10208
  get children() {
9934
- var _el$190 = _tmpl$37();
9935
- _el$190.$$click = async () => {
10209
+ var _el$195 = _tmpl$37();
10210
+ _el$195.$$click = async () => {
9936
10211
  const state = await window.vessel.premium.reset();
9937
10212
  setPremiumState(state);
9938
10213
  setPremiumEmail("");
9939
10214
  resetPremiumActivationFlow();
9940
10215
  setPremiumMessage(null);
9941
10216
  };
9942
- return _el$190;
10217
+ return _el$195;
9943
10218
  }
9944
10219
  }), null);
9945
- createRenderEffect(() => _el$185.disabled = premiumLoading() || !premiumEmail().trim());
9946
- createRenderEffect(() => _el$184.value = premiumEmail());
9947
- return _el$181;
10220
+ createRenderEffect(() => _el$190.disabled = premiumLoading() || !premiumEmail().trim());
10221
+ createRenderEffect(() => _el$189.value = premiumEmail());
10222
+ return _el$186;
9948
10223
  })();
9949
10224
  },
9950
10225
  get children() {
9951
- var _el$78 = _tmpl$14(), _el$79 = _el$78.firstChild;
9952
- _el$79.firstChild;
9953
- var _el$81 = _el$79.nextSibling, _el$82 = _el$81.nextSibling, _el$83 = _el$82.firstChild, _el$84 = _el$83.nextSibling;
9954
- insert(_el$79, createComponent(Show, {
10226
+ var _el$82 = _tmpl$14(), _el$83 = _el$82.firstChild;
10227
+ _el$83.firstChild;
10228
+ var _el$85 = _el$83.nextSibling, _el$86 = _el$85.nextSibling, _el$87 = _el$86.firstChild, _el$88 = _el$87.nextSibling;
10229
+ insert(_el$83, createComponent(Show, {
9955
10230
  get when() {
9956
10231
  return premiumState().status === "trialing";
9957
10232
  },
@@ -9959,8 +10234,8 @@ const Settings = () => {
9959
10234
  return [" ", "(Trial)"];
9960
10235
  }
9961
10236
  }), null);
9962
- insert(_el$81, () => premiumState().email, null);
9963
- insert(_el$81, createComponent(Show, {
10237
+ insert(_el$85, () => premiumState().email, null);
10238
+ insert(_el$85, createComponent(Show, {
9964
10239
  get when() {
9965
10240
  return premiumState().expiresAt;
9966
10241
  },
@@ -9968,7 +10243,7 @@ const Settings = () => {
9968
10243
  return [" ", "· Renews", " ", memo(() => new Date(premiumState().expiresAt).toLocaleDateString())];
9969
10244
  }
9970
10245
  }), null);
9971
- _el$83.$$click = async () => {
10246
+ _el$87.$$click = async () => {
9972
10247
  const result = await window.vessel.premium.portal();
9973
10248
  if (!result.ok) {
9974
10249
  setPremiumMessage({
@@ -9978,36 +10253,36 @@ const Settings = () => {
9978
10253
  setTimeout(() => setPremiumMessage(null), 5e3);
9979
10254
  }
9980
10255
  };
9981
- _el$84.$$click = async () => {
10256
+ _el$88.$$click = async () => {
9982
10257
  const state = await window.vessel.premium.reset();
9983
10258
  setPremiumState(state);
9984
10259
  setPremiumEmail("");
9985
10260
  resetPremiumActivationFlow();
9986
10261
  setPremiumMessage(null);
9987
10262
  };
9988
- insert(_el$78, createComponent(Show, {
10263
+ insert(_el$82, createComponent(Show, {
9989
10264
  get when() {
9990
10265
  return premiumMessage();
9991
10266
  },
9992
10267
  children: (msg) => (() => {
9993
- var _el$192 = _tmpl$39();
9994
- insert(_el$192, () => msg().text);
10268
+ var _el$197 = _tmpl$39();
10269
+ insert(_el$197, () => msg().text);
9995
10270
  createRenderEffect((_p$) => {
9996
10271
  var _v$13 = !!(msg().kind === "success"), _v$14 = !!(msg().kind === "error");
9997
- _v$13 !== _p$.e && _el$192.classList.toggle("success", _p$.e = _v$13);
9998
- _v$14 !== _p$.t && _el$192.classList.toggle("error", _p$.t = _v$14);
10272
+ _v$13 !== _p$.e && _el$197.classList.toggle("success", _p$.e = _v$13);
10273
+ _v$14 !== _p$.t && _el$197.classList.toggle("error", _p$.t = _v$14);
9999
10274
  return _p$;
10000
10275
  }, {
10001
10276
  e: void 0,
10002
10277
  t: void 0
10003
10278
  });
10004
- return _el$192;
10279
+ return _el$197;
10005
10280
  })()
10006
10281
  }), null);
10007
- return _el$78;
10282
+ return _el$82;
10008
10283
  }
10009
10284
  }), null);
10010
- insert(_el$87, createComponent(Show, {
10285
+ insert(_el$91, createComponent(Show, {
10011
10286
  get when() {
10012
10287
  return !premiumActive();
10013
10288
  },
@@ -10015,7 +10290,7 @@ const Settings = () => {
10015
10290
  return _tmpl$15();
10016
10291
  }
10017
10292
  }), null);
10018
- insert(_el$86, createComponent(Show, {
10293
+ insert(_el$90, createComponent(Show, {
10019
10294
  get when() {
10020
10295
  return premiumActive();
10021
10296
  },
@@ -10028,17 +10303,17 @@ const Settings = () => {
10028
10303
  return vaultEntries().length > 0;
10029
10304
  },
10030
10305
  get children() {
10031
- var _el$91 = _tmpl$5$1();
10032
- insert(_el$91, createComponent(For, {
10306
+ var _el$95 = _tmpl$5$1();
10307
+ insert(_el$95, createComponent(For, {
10033
10308
  get each() {
10034
10309
  return vaultEntries();
10035
10310
  },
10036
10311
  children: (entry) => (() => {
10037
- var _el$194 = _tmpl$41(), _el$195 = _el$194.firstChild, _el$196 = _el$195.firstChild, _el$197 = _el$196.nextSibling, _el$198 = _el$197.firstChild, _el$199 = _el$195.nextSibling;
10038
- insert(_el$196, () => entry.label);
10039
- insert(_el$197, () => entry.username, _el$198);
10040
- insert(_el$197, () => entry.domainPattern, null);
10041
- insert(_el$197, createComponent(Show, {
10312
+ var _el$199 = _tmpl$41(), _el$200 = _el$199.firstChild, _el$201 = _el$200.firstChild, _el$202 = _el$201.nextSibling, _el$203 = _el$202.firstChild, _el$204 = _el$200.nextSibling;
10313
+ insert(_el$201, () => entry.label);
10314
+ insert(_el$202, () => entry.username, _el$203);
10315
+ insert(_el$202, () => entry.domainPattern, null);
10316
+ insert(_el$202, createComponent(Show, {
10042
10317
  get when() {
10043
10318
  return entry.useCount > 0;
10044
10319
  },
@@ -10046,43 +10321,43 @@ const Settings = () => {
10046
10321
  return [" ", "· Used ", memo(() => entry.useCount), "x"];
10047
10322
  }
10048
10323
  }), null);
10049
- _el$199.$$click = () => handleVaultRemove(entry.id);
10050
- return _el$194;
10324
+ _el$204.$$click = () => handleVaultRemove(entry.id);
10325
+ return _el$199;
10051
10326
  })()
10052
10327
  }));
10053
- return _el$91;
10328
+ return _el$95;
10054
10329
  }
10055
10330
  }), createComponent(Show, {
10056
10331
  get when() {
10057
10332
  return !vaultAdding();
10058
10333
  },
10059
10334
  get children() {
10060
- var _el$92 = _tmpl$17();
10061
- _el$92.$$click = () => {
10335
+ var _el$96 = _tmpl$17();
10336
+ _el$96.$$click = () => {
10062
10337
  setVaultAdding(true);
10063
10338
  setVaultMessage(null);
10064
10339
  };
10065
- return _el$92;
10340
+ return _el$96;
10066
10341
  }
10067
10342
  }), createComponent(Show, {
10068
10343
  get when() {
10069
10344
  return vaultAdding();
10070
10345
  },
10071
10346
  get children() {
10072
- var _el$93 = _tmpl$18(), _el$94 = _el$93.firstChild, _el$95 = _el$94.nextSibling, _el$96 = _el$95.nextSibling, _el$97 = _el$96.nextSibling, _el$98 = _el$97.nextSibling, _el$99 = _el$98.nextSibling, _el$100 = _el$99.nextSibling, _el$101 = _el$100.firstChild, _el$102 = _el$101.nextSibling;
10073
- _el$94.$$input = (e) => setVaultNewLabel(e.currentTarget.value);
10074
- setAttribute(_el$94, "spellcheck", false);
10075
- _el$95.$$input = (e) => setVaultNewDomain(e.currentTarget.value);
10076
- setAttribute(_el$95, "spellcheck", false);
10077
- _el$96.$$input = (e) => setVaultNewUsername(e.currentTarget.value);
10078
- setAttribute(_el$96, "spellcheck", false);
10079
- _el$97.$$input = (e) => setVaultNewPassword(e.currentTarget.value);
10080
- _el$98.$$input = (e) => setVaultNewTotp(e.currentTarget.value);
10347
+ var _el$97 = _tmpl$18(), _el$98 = _el$97.firstChild, _el$99 = _el$98.nextSibling, _el$100 = _el$99.nextSibling, _el$101 = _el$100.nextSibling, _el$102 = _el$101.nextSibling, _el$103 = _el$102.nextSibling, _el$104 = _el$103.nextSibling, _el$105 = _el$104.firstChild, _el$106 = _el$105.nextSibling;
10348
+ _el$98.$$input = (e) => setVaultNewLabel(e.currentTarget.value);
10081
10349
  setAttribute(_el$98, "spellcheck", false);
10082
- _el$99.$$input = (e) => setVaultNewNotes(e.currentTarget.value);
10350
+ _el$99.$$input = (e) => setVaultNewDomain(e.currentTarget.value);
10083
10351
  setAttribute(_el$99, "spellcheck", false);
10084
- _el$101.$$click = handleVaultAdd;
10085
- _el$102.$$click = () => {
10352
+ _el$100.$$input = (e) => setVaultNewUsername(e.currentTarget.value);
10353
+ setAttribute(_el$100, "spellcheck", false);
10354
+ _el$101.$$input = (e) => setVaultNewPassword(e.currentTarget.value);
10355
+ _el$102.$$input = (e) => setVaultNewTotp(e.currentTarget.value);
10356
+ setAttribute(_el$102, "spellcheck", false);
10357
+ _el$103.$$input = (e) => setVaultNewNotes(e.currentTarget.value);
10358
+ setAttribute(_el$103, "spellcheck", false);
10359
+ _el$105.$$click = handleVaultAdd;
10360
+ _el$106.$$click = () => {
10086
10361
  setVaultAdding(false);
10087
10362
  setVaultNewLabel("");
10088
10363
  setVaultNewDomain("");
@@ -10091,100 +10366,100 @@ const Settings = () => {
10091
10366
  setVaultNewTotp("");
10092
10367
  setVaultNewNotes("");
10093
10368
  };
10094
- createRenderEffect(() => _el$94.value = vaultNewLabel());
10095
- createRenderEffect(() => _el$95.value = vaultNewDomain());
10096
- createRenderEffect(() => _el$96.value = vaultNewUsername());
10097
- createRenderEffect(() => _el$97.value = vaultNewPassword());
10098
- createRenderEffect(() => _el$98.value = vaultNewTotp());
10099
- createRenderEffect(() => _el$99.value = vaultNewNotes());
10100
- return _el$93;
10369
+ createRenderEffect(() => _el$98.value = vaultNewLabel());
10370
+ createRenderEffect(() => _el$99.value = vaultNewDomain());
10371
+ createRenderEffect(() => _el$100.value = vaultNewUsername());
10372
+ createRenderEffect(() => _el$101.value = vaultNewPassword());
10373
+ createRenderEffect(() => _el$102.value = vaultNewTotp());
10374
+ createRenderEffect(() => _el$103.value = vaultNewNotes());
10375
+ return _el$97;
10101
10376
  }
10102
10377
  }), createComponent(Show, {
10103
10378
  get when() {
10104
10379
  return vaultMessage();
10105
10380
  },
10106
10381
  children: (msg) => (() => {
10107
- var _el$200 = _tmpl$39();
10108
- insert(_el$200, () => msg().text);
10382
+ var _el$205 = _tmpl$39();
10383
+ insert(_el$205, () => msg().text);
10109
10384
  createRenderEffect((_p$) => {
10110
10385
  var _v$15 = !!(msg().kind === "success"), _v$16 = !!(msg().kind === "error");
10111
- _v$15 !== _p$.e && _el$200.classList.toggle("success", _p$.e = _v$15);
10112
- _v$16 !== _p$.t && _el$200.classList.toggle("error", _p$.t = _v$16);
10386
+ _v$15 !== _p$.e && _el$205.classList.toggle("success", _p$.e = _v$15);
10387
+ _v$16 !== _p$.t && _el$205.classList.toggle("error", _p$.t = _v$16);
10113
10388
  return _p$;
10114
10389
  }, {
10115
10390
  e: void 0,
10116
10391
  t: void 0
10117
10392
  });
10118
- return _el$200;
10393
+ return _el$205;
10119
10394
  })()
10120
10395
  })];
10121
10396
  }
10122
10397
  }), null);
10123
- insert(_el$104, createComponent(Show, {
10398
+ insert(_el$108, createComponent(Show, {
10124
10399
  get when() {
10125
10400
  return autofillProfiles().length > 0;
10126
10401
  },
10127
10402
  get children() {
10128
- var _el$107 = _tmpl$5$1();
10129
- insert(_el$107, createComponent(For, {
10403
+ var _el$111 = _tmpl$5$1();
10404
+ insert(_el$111, createComponent(For, {
10130
10405
  get each() {
10131
10406
  return autofillProfiles();
10132
10407
  },
10133
10408
  children: (profile) => (() => {
10134
- var _el$201 = _tmpl$42(), _el$202 = _el$201.firstChild, _el$203 = _el$202.firstChild, _el$204 = _el$203.nextSibling, _el$205 = _el$202.nextSibling, _el$206 = _el$205.firstChild, _el$207 = _el$206.nextSibling;
10135
- insert(_el$203, () => profile.label);
10136
- insert(_el$204, () => profile.firstName, null);
10137
- insert(_el$204, (() => {
10409
+ var _el$206 = _tmpl$42(), _el$207 = _el$206.firstChild, _el$208 = _el$207.firstChild, _el$209 = _el$208.nextSibling, _el$210 = _el$207.nextSibling, _el$211 = _el$210.firstChild, _el$212 = _el$211.nextSibling;
10410
+ insert(_el$208, () => profile.label);
10411
+ insert(_el$209, () => profile.firstName, null);
10412
+ insert(_el$209, (() => {
10138
10413
  var _c$2 = memo(() => !!profile.lastName);
10139
10414
  return () => _c$2() ? ` ${profile.lastName}` : "";
10140
10415
  })(), null);
10141
- insert(_el$204, (() => {
10416
+ insert(_el$209, (() => {
10142
10417
  var _c$3 = memo(() => !!profile.email);
10143
10418
  return () => _c$3() ? ` · ${profile.email}` : "";
10144
10419
  })(), null);
10145
- _el$206.$$click = () => handleAutofillFill(profile.id);
10146
- _el$207.$$click = () => handleAutofillRemove(profile.id);
10147
- return _el$201;
10420
+ _el$211.$$click = () => handleAutofillFill(profile.id);
10421
+ _el$212.$$click = () => handleAutofillRemove(profile.id);
10422
+ return _el$206;
10148
10423
  })()
10149
10424
  }));
10150
- return _el$107;
10425
+ return _el$111;
10151
10426
  }
10152
10427
  }), null);
10153
- insert(_el$104, createComponent(Show, {
10428
+ insert(_el$108, createComponent(Show, {
10154
10429
  get when() {
10155
10430
  return !autofillAdding();
10156
10431
  },
10157
10432
  get children() {
10158
- var _el$108 = _tmpl$19();
10159
- _el$108.$$click = () => {
10433
+ var _el$112 = _tmpl$19();
10434
+ _el$112.$$click = () => {
10160
10435
  setAutofillAdding(true);
10161
10436
  setAutofillMessage(null);
10162
10437
  };
10163
- return _el$108;
10438
+ return _el$112;
10164
10439
  }
10165
10440
  }), null);
10166
- insert(_el$104, createComponent(Show, {
10441
+ insert(_el$108, createComponent(Show, {
10167
10442
  get when() {
10168
10443
  return autofillAdding();
10169
10444
  },
10170
10445
  get children() {
10171
- var _el$109 = _tmpl$20(), _el$110 = _el$109.firstChild, _el$111 = _el$110.nextSibling, _el$112 = _el$111.firstChild, _el$113 = _el$112.nextSibling, _el$114 = _el$111.nextSibling, _el$115 = _el$114.firstChild, _el$116 = _el$115.nextSibling, _el$117 = _el$114.nextSibling, _el$118 = _el$117.nextSibling, _el$119 = _el$118.nextSibling, _el$120 = _el$119.nextSibling, _el$121 = _el$120.firstChild, _el$122 = _el$121.nextSibling, _el$123 = _el$122.nextSibling, _el$124 = _el$120.nextSibling, _el$125 = _el$124.nextSibling, _el$126 = _el$125.firstChild, _el$127 = _el$126.nextSibling;
10172
- _el$110.$$input = (e) => setAutofillLabel(e.currentTarget.value);
10173
- setAttribute(_el$110, "spellcheck", false);
10174
- _el$112.$$input = (e) => setAutofillFirstName(e.currentTarget.value);
10175
- _el$113.$$input = (e) => setAutofillLastName(e.currentTarget.value);
10176
- _el$115.$$input = (e) => setAutofillEmail(e.currentTarget.value);
10177
- setAttribute(_el$115, "spellcheck", false);
10178
- _el$116.$$input = (e) => setAutofillPhone(e.currentTarget.value);
10179
- _el$117.$$input = (e) => setAutofillOrg(e.currentTarget.value);
10180
- _el$118.$$input = (e) => setAutofillAddr1(e.currentTarget.value);
10181
- _el$119.$$input = (e) => setAutofillAddr2(e.currentTarget.value);
10182
- _el$121.$$input = (e) => setAutofillCity(e.currentTarget.value);
10183
- _el$122.$$input = (e) => setAutofillState(e.currentTarget.value);
10184
- _el$123.$$input = (e) => setAutofillZip(e.currentTarget.value);
10185
- _el$124.$$input = (e) => setAutofillCountry(e.currentTarget.value);
10186
- _el$126.$$click = handleAutofillAdd;
10187
- _el$127.$$click = () => {
10446
+ var _el$113 = _tmpl$20(), _el$114 = _el$113.firstChild, _el$115 = _el$114.nextSibling, _el$116 = _el$115.firstChild, _el$117 = _el$116.nextSibling, _el$118 = _el$115.nextSibling, _el$119 = _el$118.firstChild, _el$120 = _el$119.nextSibling, _el$121 = _el$118.nextSibling, _el$122 = _el$121.nextSibling, _el$123 = _el$122.nextSibling, _el$124 = _el$123.nextSibling, _el$125 = _el$124.firstChild, _el$126 = _el$125.nextSibling, _el$127 = _el$126.nextSibling, _el$128 = _el$124.nextSibling, _el$129 = _el$128.nextSibling, _el$130 = _el$129.firstChild, _el$131 = _el$130.nextSibling;
10447
+ _el$114.$$input = (e) => setAutofillLabel(e.currentTarget.value);
10448
+ setAttribute(_el$114, "spellcheck", false);
10449
+ _el$116.$$input = (e) => setAutofillFirstName(e.currentTarget.value);
10450
+ _el$117.$$input = (e) => setAutofillLastName(e.currentTarget.value);
10451
+ _el$119.$$input = (e) => setAutofillEmail(e.currentTarget.value);
10452
+ setAttribute(_el$119, "spellcheck", false);
10453
+ _el$120.$$input = (e) => setAutofillPhone(e.currentTarget.value);
10454
+ _el$121.$$input = (e) => setAutofillOrg(e.currentTarget.value);
10455
+ _el$122.$$input = (e) => setAutofillAddr1(e.currentTarget.value);
10456
+ _el$123.$$input = (e) => setAutofillAddr2(e.currentTarget.value);
10457
+ _el$125.$$input = (e) => setAutofillCity(e.currentTarget.value);
10458
+ _el$126.$$input = (e) => setAutofillState(e.currentTarget.value);
10459
+ _el$127.$$input = (e) => setAutofillZip(e.currentTarget.value);
10460
+ _el$128.$$input = (e) => setAutofillCountry(e.currentTarget.value);
10461
+ _el$130.$$click = handleAutofillAdd;
10462
+ _el$131.$$click = () => {
10188
10463
  setAutofillAdding(false);
10189
10464
  setAutofillLabel("");
10190
10465
  setAutofillFirstName("");
@@ -10199,63 +10474,63 @@ const Settings = () => {
10199
10474
  setAutofillZip("");
10200
10475
  setAutofillCountry("");
10201
10476
  };
10202
- createRenderEffect(() => _el$110.value = autofillLabel());
10203
- createRenderEffect(() => _el$112.value = autofillFirstName());
10204
- createRenderEffect(() => _el$113.value = autofillLastName());
10205
- createRenderEffect(() => _el$115.value = autofillEmail());
10206
- createRenderEffect(() => _el$116.value = autofillPhone());
10207
- createRenderEffect(() => _el$117.value = autofillOrg());
10208
- createRenderEffect(() => _el$118.value = autofillAddr1());
10209
- createRenderEffect(() => _el$119.value = autofillAddr2());
10210
- createRenderEffect(() => _el$121.value = autofillCity());
10211
- createRenderEffect(() => _el$122.value = autofillState());
10212
- createRenderEffect(() => _el$123.value = autofillZip());
10213
- createRenderEffect(() => _el$124.value = autofillCountry());
10214
- return _el$109;
10477
+ createRenderEffect(() => _el$114.value = autofillLabel());
10478
+ createRenderEffect(() => _el$116.value = autofillFirstName());
10479
+ createRenderEffect(() => _el$117.value = autofillLastName());
10480
+ createRenderEffect(() => _el$119.value = autofillEmail());
10481
+ createRenderEffect(() => _el$120.value = autofillPhone());
10482
+ createRenderEffect(() => _el$121.value = autofillOrg());
10483
+ createRenderEffect(() => _el$122.value = autofillAddr1());
10484
+ createRenderEffect(() => _el$123.value = autofillAddr2());
10485
+ createRenderEffect(() => _el$125.value = autofillCity());
10486
+ createRenderEffect(() => _el$126.value = autofillState());
10487
+ createRenderEffect(() => _el$127.value = autofillZip());
10488
+ createRenderEffect(() => _el$128.value = autofillCountry());
10489
+ return _el$113;
10215
10490
  }
10216
10491
  }), null);
10217
- insert(_el$104, createComponent(Show, {
10492
+ insert(_el$108, createComponent(Show, {
10218
10493
  get when() {
10219
10494
  return autofillMessage();
10220
10495
  },
10221
10496
  children: (msg) => (() => {
10222
- var _el$208 = _tmpl$39();
10223
- insert(_el$208, () => msg().text);
10497
+ var _el$213 = _tmpl$39();
10498
+ insert(_el$213, () => msg().text);
10224
10499
  createRenderEffect((_p$) => {
10225
10500
  var _v$17 = !!(msg().kind === "success"), _v$18 = !!(msg().kind === "error");
10226
- _v$17 !== _p$.e && _el$208.classList.toggle("success", _p$.e = _v$17);
10227
- _v$18 !== _p$.t && _el$208.classList.toggle("error", _p$.t = _v$18);
10501
+ _v$17 !== _p$.e && _el$213.classList.toggle("success", _p$.e = _v$17);
10502
+ _v$18 !== _p$.t && _el$213.classList.toggle("error", _p$.t = _v$18);
10228
10503
  return _p$;
10229
10504
  }, {
10230
10505
  e: void 0,
10231
10506
  t: void 0
10232
10507
  });
10233
- return _el$208;
10508
+ return _el$213;
10234
10509
  })()
10235
10510
  }), null);
10236
- _el$131.$$click = () => setTelemetryEnabled(!telemetryEnabled());
10237
- _el$135.addEventListener("change", (e) => setTheme(e.currentTarget.value));
10238
- _el$138.addEventListener("change", (e) => setDomainMode(e.currentTarget.value));
10239
- insert(_el$136, createComponent(Show, {
10511
+ _el$135.$$click = () => setTelemetryEnabled(!telemetryEnabled());
10512
+ _el$139.addEventListener("change", (e) => setTheme(e.currentTarget.value));
10513
+ _el$142.addEventListener("change", (e) => setDomainMode(e.currentTarget.value));
10514
+ insert(_el$140, createComponent(Show, {
10240
10515
  get when() {
10241
10516
  return domainMode() !== "none";
10242
10517
  },
10243
10518
  get children() {
10244
10519
  return [(() => {
10245
- var _el$139 = _tmpl$21();
10246
- _el$139.$$input = (e) => setDomainList(e.currentTarget.value);
10247
- setAttribute(_el$139, "spellcheck", false);
10248
- createRenderEffect(() => setAttribute(_el$139, "placeholder", domainMode() === "allowlist" ? "example.com\napi.example.com" : "ads.example.com\ntracker.io"));
10249
- createRenderEffect(() => _el$139.value = domainList());
10250
- return _el$139;
10520
+ var _el$143 = _tmpl$21();
10521
+ _el$143.$$input = (e) => setDomainList(e.currentTarget.value);
10522
+ setAttribute(_el$143, "spellcheck", false);
10523
+ createRenderEffect(() => setAttribute(_el$143, "placeholder", domainMode() === "allowlist" ? "example.com\napi.example.com" : "ads.example.com\ntracker.io"));
10524
+ createRenderEffect(() => _el$143.value = domainList());
10525
+ return _el$143;
10251
10526
  })(), (() => {
10252
- var _el$140 = _tmpl$22();
10253
- insert(_el$140, () => domainMode() === "allowlist" ? "One domain per line. Subdomains of listed domains are also allowed." : "One domain per line. Subdomains of listed domains are also blocked.");
10254
- return _el$140;
10527
+ var _el$144 = _tmpl$22();
10528
+ insert(_el$144, () => domainMode() === "allowlist" ? "One domain per line. Subdomains of listed domains are also allowed." : "One domain per line. Subdomains of listed domains are also blocked.");
10529
+ return _el$144;
10255
10530
  })()];
10256
10531
  }
10257
10532
  }), null);
10258
- insert(_el$136, createComponent(Show, {
10533
+ insert(_el$140, createComponent(Show, {
10259
10534
  get when() {
10260
10535
  return domainMode() === "none";
10261
10536
  },
@@ -10263,39 +10538,39 @@ const Settings = () => {
10263
10538
  return _tmpl$23();
10264
10539
  }
10265
10540
  }), null);
10266
- _el$143.$$click = handleSave;
10267
- addEventListener(_el$144, "click", closeSettings, true);
10541
+ _el$147.$$click = handleSave;
10542
+ addEventListener(_el$148, "click", closeSettings, true);
10268
10543
  insert(_el$2, createComponent(Show, {
10269
10544
  get when() {
10270
10545
  return status();
10271
10546
  },
10272
10547
  children: (currentStatus) => (() => {
10273
- var _el$209 = _tmpl$39();
10274
- insert(_el$209, () => currentStatus().text);
10548
+ var _el$214 = _tmpl$39();
10549
+ insert(_el$214, () => currentStatus().text);
10275
10550
  createRenderEffect((_p$) => {
10276
10551
  var _v$19 = !!(currentStatus().kind === "success"), _v$20 = !!(currentStatus().kind === "error");
10277
- _v$19 !== _p$.e && _el$209.classList.toggle("success", _p$.e = _v$19);
10278
- _v$20 !== _p$.t && _el$209.classList.toggle("error", _p$.t = _v$20);
10552
+ _v$19 !== _p$.e && _el$214.classList.toggle("success", _p$.e = _v$19);
10553
+ _v$20 !== _p$.t && _el$214.classList.toggle("error", _p$.t = _v$20);
10279
10554
  return _p$;
10280
10555
  }, {
10281
10556
  e: void 0,
10282
10557
  t: void 0
10283
10558
  });
10284
- return _el$209;
10559
+ return _el$214;
10285
10560
  })()
10286
10561
  }), null);
10287
10562
  createRenderEffect((_p$) => {
10288
10563
  var _v$ = !!settingsClosing(), _v$2 = !!autoRestoreSession(), _v$3 = autoRestoreSession(), _v$4 = !!clearBookmarksOnLaunch(), _v$5 = clearBookmarksOnLaunch(), _v$6 = !sessionSaveName().trim(), _v$7 = !!chatEnabled(), _v$8 = chatEnabled(), _v$9 = !!telemetryEnabled(), _v$0 = telemetryEnabled();
10289
10564
  _v$ !== _p$.e && _el$.classList.toggle("closing", _p$.e = _v$);
10290
- _v$2 !== _p$.t && _el$39.classList.toggle("on", _p$.t = _v$2);
10291
- _v$3 !== _p$.a && setAttribute(_el$39, "aria-checked", _p$.a = _v$3);
10292
- _v$4 !== _p$.o && _el$42.classList.toggle("on", _p$.o = _v$4);
10293
- _v$5 !== _p$.i && setAttribute(_el$42, "aria-checked", _p$.i = _v$5);
10294
- _v$6 !== _p$.n && (_el$49.disabled = _p$.n = _v$6);
10295
- _v$7 !== _p$.s && _el$54.classList.toggle("on", _p$.s = _v$7);
10296
- _v$8 !== _p$.h && setAttribute(_el$54, "aria-checked", _p$.h = _v$8);
10297
- _v$9 !== _p$.r && _el$131.classList.toggle("on", _p$.r = _v$9);
10298
- _v$0 !== _p$.d && setAttribute(_el$131, "aria-checked", _p$.d = _v$0);
10565
+ _v$2 !== _p$.t && _el$43.classList.toggle("on", _p$.t = _v$2);
10566
+ _v$3 !== _p$.a && setAttribute(_el$43, "aria-checked", _p$.a = _v$3);
10567
+ _v$4 !== _p$.o && _el$46.classList.toggle("on", _p$.o = _v$4);
10568
+ _v$5 !== _p$.i && setAttribute(_el$46, "aria-checked", _p$.i = _v$5);
10569
+ _v$6 !== _p$.n && (_el$53.disabled = _p$.n = _v$6);
10570
+ _v$7 !== _p$.s && _el$58.classList.toggle("on", _p$.s = _v$7);
10571
+ _v$8 !== _p$.h && setAttribute(_el$58, "aria-checked", _p$.h = _v$8);
10572
+ _v$9 !== _p$.r && _el$135.classList.toggle("on", _p$.r = _v$9);
10573
+ _v$0 !== _p$.d && setAttribute(_el$135, "aria-checked", _p$.d = _v$0);
10299
10574
  return _p$;
10300
10575
  }, {
10301
10576
  e: void 0,
@@ -10310,13 +10585,14 @@ const Settings = () => {
10310
10585
  d: void 0
10311
10586
  });
10312
10587
  createRenderEffect(() => _el$20.value = defaultUrl());
10313
- createRenderEffect(() => _el$23.value = downloadPath());
10314
- createRenderEffect(() => _el$26.value = mcpPort());
10315
- createRenderEffect(() => _el$33.value = obsidianVaultPath());
10316
- createRenderEffect(() => _el$36.value = agentTranscriptMode());
10317
- createRenderEffect(() => _el$48.value = sessionSaveName());
10318
- createRenderEffect(() => _el$135.value = theme());
10319
- createRenderEffect(() => _el$138.value = domainMode());
10588
+ createRenderEffect(() => _el$23.value = defaultSearchEngine());
10589
+ createRenderEffect(() => _el$27.value = downloadPath());
10590
+ createRenderEffect(() => _el$30.value = mcpPort());
10591
+ createRenderEffect(() => _el$37.value = obsidianVaultPath());
10592
+ createRenderEffect(() => _el$40.value = agentTranscriptMode());
10593
+ createRenderEffect(() => _el$52.value = sessionSaveName());
10594
+ createRenderEffect(() => _el$139.value = theme());
10595
+ createRenderEffect(() => _el$142.value = domainMode());
10320
10596
  return _el$;
10321
10597
  })(), _tmpl$25()];
10322
10598
  }
@@ -10408,28 +10684,52 @@ var _tmpl$$1 = /* @__PURE__ */ template(`<div class=command-bar-overlay><div cla
10408
10684
  `), _tmpl$3 = /* @__PURE__ */ template(`<div class=keyboard-help-keys>`), _tmpl$4 = /* @__PURE__ */ template(`<div class=keyboard-help-action>`), _tmpl$5 = /* @__PURE__ */ template(`<kbd>`), _tmpl$6 = /* @__PURE__ */ template(`<span class=keyboard-help-plus>+`);
10409
10685
  const SHORTCUTS = [{
10410
10686
  keys: "Ctrl+L",
10411
- action: "AI Command Bar"
10687
+ action: "AI Command Bar",
10688
+ privateMode: false
10412
10689
  }, {
10413
10690
  keys: "Ctrl+Shift+L",
10414
- action: "Toggle AI Sidebar"
10691
+ action: "Toggle AI Sidebar",
10692
+ privateMode: false
10415
10693
  }, {
10416
10694
  keys: "Ctrl+Shift+F",
10417
- action: "Toggle Focus Mode"
10695
+ action: "Toggle Focus Mode",
10696
+ privateMode: false
10418
10697
  }, {
10419
10698
  keys: "F12",
10420
- action: "Toggle Dev Tools Panel"
10699
+ action: "Toggle Dev Tools Panel",
10700
+ privateMode: false
10421
10701
  }, {
10422
10702
  keys: "Ctrl+T",
10423
10703
  action: "New Tab"
10424
10704
  }, {
10425
10705
  keys: "Ctrl+W",
10426
10706
  action: "Close Tab"
10707
+ }, {
10708
+ keys: "Ctrl+Shift+T",
10709
+ action: "Reopen Closed Tab"
10710
+ }, {
10711
+ keys: "Ctrl+F",
10712
+ action: "Find in Page"
10713
+ }, {
10714
+ keys: "Ctrl++ / Ctrl+=",
10715
+ action: "Zoom In"
10716
+ }, {
10717
+ keys: "Ctrl+-",
10718
+ action: "Zoom Out"
10719
+ }, {
10720
+ keys: "Ctrl+0",
10721
+ action: "Reset Zoom"
10722
+ }, {
10723
+ keys: "Ctrl+Shift+N",
10724
+ action: "New Private Window"
10427
10725
  }, {
10428
10726
  keys: "Ctrl+,",
10429
- action: "Settings"
10727
+ action: "Settings",
10728
+ privateMode: false
10430
10729
  }, {
10431
10730
  keys: "Ctrl+H",
10432
- action: "Capture Highlight"
10731
+ action: "Capture Highlight",
10732
+ privateMode: false
10433
10733
  }, {
10434
10734
  keys: "?",
10435
10735
  action: "This help overlay"
@@ -10439,6 +10739,7 @@ const KeyboardHelp = (props) => {
10439
10739
  visible,
10440
10740
  closing
10441
10741
  } = useAnimatedPresence(() => props.open, 200);
10742
+ const shortcuts = () => props.privateMode ? SHORTCUTS.filter((shortcut) => shortcut.privateMode !== false) : SHORTCUTS;
10442
10743
  return createComponent(Show, {
10443
10744
  get when() {
10444
10745
  return visible();
@@ -10449,7 +10750,7 @@ const KeyboardHelp = (props) => {
10449
10750
  addEventListener(_el$, "click", props.onClose, true);
10450
10751
  _el$2.$$click = (e) => e.stopPropagation();
10451
10752
  addEventListener(_el$5, "click", props.onClose, true);
10452
- insert(_el$6, () => SHORTCUTS.map((s) => [(() => {
10753
+ insert(_el$6, () => shortcuts().map((s) => [(() => {
10453
10754
  var _el$8 = _tmpl$3();
10454
10755
  insert(_el$8, () => s.keys.split("+").map((k, i) => [i > 0 && _tmpl$6(), (() => {
10455
10756
  var _el$0 = _tmpl$5();
@@ -10472,27 +10773,38 @@ delegateEvents(["click"]);
10472
10773
  function setupKeybindings(handlers) {
10473
10774
  const listener = (e) => {
10474
10775
  const ctrl = e.ctrlKey || e.metaKey;
10475
- if (ctrl && e.key === "l" && !e.shiftKey) {
10776
+ const key = e.key.toLowerCase();
10777
+ if (ctrl && key === "l" && !e.shiftKey) {
10476
10778
  e.preventDefault();
10477
10779
  handlers.openCommandBar();
10478
10780
  return;
10479
10781
  }
10480
- if (ctrl && e.key === "L" && e.shiftKey) {
10782
+ if (ctrl && key === "l" && e.shiftKey) {
10481
10783
  e.preventDefault();
10482
10784
  handlers.toggleSidebar();
10483
10785
  return;
10484
10786
  }
10485
- if (ctrl && e.key === "F" && e.shiftKey) {
10787
+ if (ctrl && key === "f" && e.shiftKey) {
10486
10788
  e.preventDefault();
10487
10789
  handlers.toggleFocusMode();
10488
10790
  return;
10489
10791
  }
10490
- if (ctrl && e.key === "t") {
10792
+ if (ctrl && key === "t" && e.shiftKey) {
10793
+ e.preventDefault();
10794
+ handlers.reopenClosedTab?.();
10795
+ return;
10796
+ }
10797
+ if (ctrl && key === "n" && e.shiftKey) {
10798
+ e.preventDefault();
10799
+ handlers.openPrivateWindow?.();
10800
+ return;
10801
+ }
10802
+ if (ctrl && key === "t" && !e.shiftKey) {
10491
10803
  e.preventDefault();
10492
10804
  handlers.newTab();
10493
10805
  return;
10494
10806
  }
10495
- if (ctrl && e.key === "w") {
10807
+ if (ctrl && key === "w") {
10496
10808
  e.preventDefault();
10497
10809
  handlers.closeTab();
10498
10810
  return;
@@ -10502,7 +10814,7 @@ function setupKeybindings(handlers) {
10502
10814
  handlers.openSettings();
10503
10815
  return;
10504
10816
  }
10505
- if (ctrl && e.key === "h" && !e.shiftKey) {
10817
+ if (ctrl && key === "h" && !e.shiftKey) {
10506
10818
  e.preventDefault();
10507
10819
  handlers.captureHighlight();
10508
10820
  return;
@@ -10512,6 +10824,21 @@ function setupKeybindings(handlers) {
10512
10824
  handlers.toggleDevTools?.();
10513
10825
  return;
10514
10826
  }
10827
+ if (ctrl && (e.key === "+" || e.key === "=")) {
10828
+ e.preventDefault();
10829
+ handlers.zoomIn?.();
10830
+ return;
10831
+ }
10832
+ if (ctrl && e.key === "-") {
10833
+ e.preventDefault();
10834
+ handlers.zoomOut?.();
10835
+ return;
10836
+ }
10837
+ if (ctrl && e.key === "0") {
10838
+ e.preventDefault();
10839
+ handlers.zoomReset?.();
10840
+ return;
10841
+ }
10515
10842
  if (e.key === "?" && !ctrl && !e.altKey) {
10516
10843
  const tag = e.target?.tagName;
10517
10844
  if (tag !== "INPUT" && tag !== "TEXTAREA" && !e.target?.isContentEditable) {
@@ -10534,6 +10861,7 @@ try {
10534
10861
  }
10535
10862
  const App = () => {
10536
10863
  const view = new URLSearchParams(window.location.search).get("view") || "chrome";
10864
+ const isPrivateWindow = new URLSearchParams(window.location.search).get("private") === "1";
10537
10865
  const {
10538
10866
  openCommandBar,
10539
10867
  toggleSidebar,
@@ -10545,7 +10873,11 @@ const App = () => {
10545
10873
  createTab,
10546
10874
  closeTab,
10547
10875
  activeTabId: activeTabId2,
10548
- activeTab
10876
+ activeTab,
10877
+ zoomIn,
10878
+ zoomOut,
10879
+ zoomReset,
10880
+ reopenClosed
10549
10881
  } = useTabs();
10550
10882
  const [highlightToast, setHighlightToast] = createSignal(null);
10551
10883
  const [keyboardHelpOpen, setKeyboardHelpOpen] = createSignal(false);
@@ -10597,17 +10929,31 @@ const App = () => {
10597
10929
  });
10598
10930
  if (view !== "chrome") return;
10599
10931
  const cleanupKeys = setupKeybindings({
10600
- openCommandBar,
10601
- toggleSidebar,
10602
- toggleFocusMode,
10932
+ openCommandBar: isPrivateWindow ? void 0 : openCommandBar,
10933
+ toggleSidebar: isPrivateWindow ? void 0 : toggleSidebar,
10934
+ toggleFocusMode: isPrivateWindow ? void 0 : toggleFocusMode,
10603
10935
  newTab: () => createTab(),
10604
10936
  closeTab: () => {
10605
10937
  const id = activeTabId2();
10606
10938
  if (id) closeTab(id);
10607
10939
  },
10608
- openSettings,
10609
- captureHighlight,
10610
- toggleDevTools: () => {
10940
+ openSettings: isPrivateWindow ? void 0 : openSettings,
10941
+ captureHighlight: isPrivateWindow ? void 0 : captureHighlight,
10942
+ zoomIn: () => {
10943
+ const id = activeTabId2();
10944
+ if (id) zoomIn(id);
10945
+ },
10946
+ zoomOut: () => {
10947
+ const id = activeTabId2();
10948
+ if (id) zoomOut(id);
10949
+ },
10950
+ zoomReset: () => {
10951
+ const id = activeTabId2();
10952
+ if (id) zoomReset(id);
10953
+ },
10954
+ reopenClosedTab: () => reopenClosed(),
10955
+ openPrivateWindow: () => window.vessel.tabs.openPrivateWindow(),
10956
+ toggleDevTools: isPrivateWindow ? void 0 : () => {
10611
10957
  window.vessel.devtoolsPanel.toggle();
10612
10958
  },
10613
10959
  toggleKeyboardHelp: () => setKeyboardHelpOpen((v) => !v)
@@ -10628,17 +10974,25 @@ const App = () => {
10628
10974
  }
10629
10975
  return (() => {
10630
10976
  var _el$ = _tmpl$2(), _el$2 = _el$.firstChild;
10631
- insert(_el$, createComponent(BookmarkNotifications, {}), _el$2);
10632
- insert(_el$, createComponent(HighlightNotifications, {
10633
- get toast() {
10634
- return highlightToast();
10635
- },
10636
- onDismiss: () => setHighlightToast(null)
10977
+ insert(_el$, createComponent(Show, {
10978
+ when: !isPrivateWindow,
10979
+ get children() {
10980
+ return [createComponent(BookmarkNotifications, {}), createComponent(HighlightNotifications, {
10981
+ get toast() {
10982
+ return highlightToast();
10983
+ },
10984
+ onDismiss: () => setHighlightToast(null)
10985
+ })];
10986
+ }
10637
10987
  }), _el$2);
10638
10988
  insert(_el$, createComponent(DownloadToast, {}), _el$2);
10639
10989
  insert(_el$, createComponent(FindBar, {}), _el$2);
10640
- insert(_el$, createComponent(FlowProgress, {}), _el$2);
10641
- insert(_el$, createComponent(AgentTranscriptDock, {}), _el$2);
10990
+ insert(_el$, createComponent(Show, {
10991
+ when: !isPrivateWindow,
10992
+ get children() {
10993
+ return [createComponent(FlowProgress, {}), createComponent(AgentTranscriptDock, {})];
10994
+ }
10995
+ }), _el$2);
10642
10996
  insert(_el$2, createComponent(TitleBar, {}), null);
10643
10997
  insert(_el$2, createComponent(TabBar, {}), null);
10644
10998
  insert(_el$2, createComponent(AddressBar, {}), null);
@@ -10652,13 +11006,18 @@ const App = () => {
10652
11006
  return _el$3;
10653
11007
  }
10654
11008
  }), null);
10655
- insert(_el$, createComponent(CommandBar, {}), null);
10656
- insert(_el$, createComponent(Settings, {}), null);
11009
+ insert(_el$, createComponent(Show, {
11010
+ when: !isPrivateWindow,
11011
+ get children() {
11012
+ return [createComponent(CommandBar, {}), createComponent(Settings, {})];
11013
+ }
11014
+ }), null);
10657
11015
  insert(_el$, createComponent(KeyboardHelp, {
10658
11016
  get open() {
10659
11017
  return keyboardHelpOpen();
10660
11018
  },
10661
- onClose: () => setKeyboardHelpOpen(false)
11019
+ onClose: () => setKeyboardHelpOpen(false),
11020
+ privateMode: isPrivateWindow
10662
11021
  }), null);
10663
11022
  createRenderEffect(() => _el$.classList.toggle("focus-mode", !!focusMode2()));
10664
11023
  return _el$;