@voltro/web 0.33.0 → 0.34.0

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.
@@ -53,7 +53,8 @@ var y = e("reconnect", null), b = () => c(y) ?? (() => {}), x = 150, S = 220, C
53
53
  generation: 0,
54
54
  reconnectStatusDispose: null,
55
55
  everOpened: !1,
56
- healthPollHandle: null
56
+ healthPollHandle: null,
57
+ subjectMayHaveChanged: !1
57
58
  }), O = (e) => {
58
59
  e.healthPollHandle !== null && (clearInterval(e.healthPollHandle), e.healthPollHandle = null);
59
60
  }, k = (e) => {
@@ -119,7 +120,7 @@ var y = e("reconnect", null), b = () => c(y) ?? (() => {}), x = 150, S = 220, C
119
120
  return;
120
121
  }
121
122
  let s = t.resolved;
122
- t.resolved = o, t.reconnectStatusDispose &&= (t.reconnectStatusDispose(), null), m(), s && k(s);
123
+ s && !t.subjectMayHaveChanged && o.cache.seedStaleFrom(s.cache), t.subjectMayHaveChanged = !1, t.resolved = o, t.reconnectStatusDispose &&= (t.reconnectStatusDispose(), null), m(), s && k(s);
123
124
  } catch {
124
125
  if (d || t.generation !== r) return;
125
126
  h(e);
@@ -145,7 +146,7 @@ var y = e("reconnect", null), b = () => c(y) ?? (() => {}), x = 150, S = 220, C
145
146
  reconnect: () => {
146
147
  if (!d) for (let e of t) {
147
148
  let t = u.get(e.name);
148
- t && (t.retryToken += 1, t.generation += 1, t.failureCount = 0, O(t), g(e));
149
+ t && (t.subjectMayHaveChanged = !0, t.retryToken += 1, t.generation += 1, t.failureCount = 0, O(t), g(e));
149
150
  }
150
151
  }
151
152
  });
@@ -1,2 +1,2 @@
1
- import { n as e, t } from "./frameworkBoot-Dm6UaRP-.js";
1
+ import { n as e, t } from "./frameworkBoot--fOA34nd.js";
2
2
  export { t as FrameworkBoot, e as VoltroRuntimeProvider };
package/dist/index.d.ts CHANGED
@@ -443,14 +443,14 @@ export declare const lazyPageRoute: (pattern: string, load: () => Promise<Record
443
443
  readonly chain?: ReadonlyArray<RouteSegment>;
444
444
  }) => PageDescriptor;
445
445
 
446
- export declare const Link: ({ to, children, onClick, prefetch: prefetchProp, replace, onMouseEnter, onFocus, ...anchorProps }: LinkProps) => ReactNode;
446
+ export declare const Link: ({ to, children, onClick, prefetch: prefetchProp, replace, onMouseEnter, onFocus, ref, ...anchorProps }: LinkProps) => ReactNode;
447
447
 
448
448
  export declare interface LinkProps extends Omit<React.AnchorHTMLAttributes<HTMLAnchorElement>, 'href' | 'onClick'> {
449
449
  readonly to: VoltroUrl;
450
450
  readonly children: ReactNode;
451
451
  readonly onClick?: (event: MouseEvent_2<HTMLAnchorElement>) => void;
452
- /** When set, pre-warm the destination's loader on hover/focus. */
453
- readonly prefetch?: boolean;
452
+ /** When and how to pre-warm the destination. See {@link PrefetchMode}. */
453
+ readonly prefetch?: PrefetchMode;
454
454
  /** Swap the current history entry instead of pushing a new one —
455
455
  * mirror of `NavigateOptions.replace`. */
456
456
  readonly replace?: boolean;
@@ -673,6 +673,8 @@ export declare class NotFoundError extends Error {
673
673
  constructor(detail?: string);
674
674
  }
675
675
 
676
+ export declare const noticeIslandsShipTheFullBundle: (isDev: boolean) => void;
677
+
676
678
  export declare const PAGE_SLOT_ATTR = "data-voltro-page-slot";
677
679
 
678
680
  export declare interface PageDescriptor<TLoaderData = unknown> {
@@ -797,9 +799,23 @@ export declare interface PlainLinkProps {
797
799
  readonly className?: string;
798
800
  readonly style?: React.CSSProperties;
799
801
  readonly onClick?: (event: MouseEvent_2<HTMLAnchorElement>) => void;
800
- readonly prefetch?: boolean;
802
+ readonly prefetch?: PrefetchMode;
801
803
  }
802
804
 
805
+ /**
806
+ * When a link pre-warms its destination — both the route's loaders AND its
807
+ * lazy page chunk.
808
+ *
809
+ * - `false` (default) — never.
810
+ * - `true` / `'hover'` — on pointer-enter and on focus. Costs nothing until
811
+ * the user shows intent, which is why it is the safe default to reach for.
812
+ * - `'visible'` — additionally as soon as the link scrolls into view
813
+ * (IntersectionObserver, 128px ahead). Right for a short, deliberate set of
814
+ * links (a nav bar, "next chapter"); wrong for a long list, where it turns
815
+ * a scroll into one request per row.
816
+ */
817
+ export declare type PrefetchMode = boolean | 'hover' | 'visible';
818
+
803
819
  /**
804
820
  * Preload the page module for the route matching `pathname`, when that route is
805
821
  * lazy. `load()` fetches the chunk AND — via the codegen's lazy thunk — records
package/dist/index.js CHANGED
@@ -1,29 +1,29 @@
1
1
  import { t as e } from "./globalContext-d4A-ugDg.js";
2
2
  import { AppClientsContext as t, useAppClient as n } from "./hooks.js";
3
- import { a as r, c as i, i as a, l as o, o as s, r as c, s as l, u } from "./frameworkBoot-Dm6UaRP-.js";
3
+ import { a as r, c as i, i as a, l as o, o as s, r as c, s as l, u } from "./frameworkBoot--fOA34nd.js";
4
4
  import { a as d, c as f, i as p, l as m, o as h, u as g } from "./defaultFallbacks-B4Ak-R6R.js";
5
- import { i as _, n as ee, r as te, t as ne } from "./mount-CXlKierJ.js";
6
- import { c as re, d as ie, h as ae, l as oe, p as se, u as ce } from "./routerState-DAT472IC.js";
7
- import { A as le, B as ue, C as de, D as fe, E as pe, F as me, G as he, H as ge, I as _e, K as v, L as y, M as b, N as x, O as S, P as C, R as w, S as T, T as E, U as D, V as O, W as k, _ as A, a as j, b as M, c as N, d as P, f as F, g as I, h as ve, i as ye, j as be, k as xe, l as Se, m as Ce, n as we, o as Te, p as Ee, q as De, r as Oe, s as ke, t as Ae, u as je, v as Me, w as Ne, x as Pe, y as Fe, z as Ie } from "./serverContext-3i6Dr4ev.js";
8
- import { Component as Le, Suspense as Re, createElement as L, use as ze, useCallback as Be, useContext as Ve, useSyncExternalStore as He } from "react";
5
+ import { a as _, i as ee, n as te, r as ne, t as re } from "./mount-BKP99m_W.js";
6
+ import { c as ie, d as ae, h as oe, l as se, p as ce, u as le } from "./routerState-DAT472IC.js";
7
+ import { A as ue, B as de, C as fe, D as pe, E as me, F as he, G as ge, H as _e, I as v, K as y, L as b, M as x, N as S, O as C, P as w, R as T, S as E, T as D, U as O, V as k, W as A, _ as j, a as M, b as N, c as P, d as F, f as I, g as ve, h as ye, i as be, j as xe, k as Se, l as Ce, m as we, n as Te, o as Ee, p as De, q as Oe, r as ke, s as Ae, t as je, u as Me, v as Ne, w as Pe, x as Fe, y as Ie, z as Le } from "./serverContext-7toyzR70.js";
8
+ import { Component as Re, Suspense as ze, createElement as L, use as Be, useCallback as Ve, useContext as He, useSyncExternalStore as Ue } from "react";
9
9
  import { Fragment as R, jsx as z, jsxs as B } from "react/jsx-runtime";
10
10
  export * from "@voltro/client";
11
11
  export * from "@voltro/ui";
12
12
  //#region src/await.tsx
13
- var Ue = ({ value: e, fallback: t, children: n, errorFallback: r }) => /* @__PURE__ */ z(Re, {
13
+ var We = ({ value: e, fallback: t, children: n, errorFallback: r }) => /* @__PURE__ */ z(ze, {
14
14
  fallback: t,
15
- children: /* @__PURE__ */ z(Ge, {
15
+ children: /* @__PURE__ */ z(Ke, {
16
16
  errorFallback: r,
17
- children: /* @__PURE__ */ z(We, {
17
+ children: /* @__PURE__ */ z(Ge, {
18
18
  value: e,
19
19
  errorFallback: r ?? null,
20
20
  children: n
21
21
  })
22
22
  })
23
- }), V = ({ body: e }) => /* @__PURE__ */ z("script", { dangerouslySetInnerHTML: { __html: e } }), We = ({ value: e, errorFallback: t, children: n }) => {
24
- let r = ze(e), i = ce(e), a = ae(r);
25
- return a === void 0 ? /* @__PURE__ */ B(R, { children: [i === void 0 ? null : /* @__PURE__ */ z(V, { body: ie(i, r) }), n(r)] }) : /* @__PURE__ */ B(R, { children: [i === void 0 ? null : /* @__PURE__ */ z(V, { body: oe(i, a) }), t] });
26
- }, Ge = class extends Le {
23
+ }), V = ({ body: e }) => /* @__PURE__ */ z("script", { dangerouslySetInnerHTML: { __html: e } }), Ge = ({ value: e, errorFallback: t, children: n }) => {
24
+ let r = Be(e), i = le(e), a = oe(r);
25
+ return a === void 0 ? /* @__PURE__ */ B(R, { children: [i === void 0 ? null : /* @__PURE__ */ z(V, { body: ae(i, r) }), n(r)] }) : /* @__PURE__ */ B(R, { children: [i === void 0 ? null : /* @__PURE__ */ z(V, { body: se(i, a) }), t] });
26
+ }, Ke = class extends Re {
27
27
  state = { error: void 0 };
28
28
  static getDerivedStateFromError(e) {
29
29
  return { error: e };
@@ -31,7 +31,7 @@ var Ue = ({ value: e, fallback: t, children: n, errorFallback: r }) => /* @__PUR
31
31
  render() {
32
32
  return this.state.error === void 0 ? this.props.children : this.props.errorFallback ?? null;
33
33
  }
34
- }, H = ({ src: e }) => e, U = e("imageConfig", { loader: H }), Ke = ({ loader: e, children: t }) => L(U.Provider, { value: { loader: e } }, t), W = [
34
+ }, H = ({ src: e }) => e, U = e("imageConfig", { loader: H }), qe = ({ loader: e, children: t }) => L(U.Provider, { value: { loader: e } }, t), W = [
35
35
  640,
36
36
  750,
37
37
  828,
@@ -40,7 +40,7 @@ var Ue = ({ value: e, fallback: t, children: n, errorFallback: r }) => /* @__PUR
40
40
  1920,
41
41
  2048,
42
42
  3840
43
- ], qe = (e, t, n, r) => {
43
+ ], Je = (e, t, n, r) => {
44
44
  let i = n !== void 0 && !r ? Array.from(new Set(W.filter((e) => e <= n * 2).concat(n))).sort((e, t) => e - t) : [...W];
45
45
  return {
46
46
  srcSet: i.map((n) => `${e({
@@ -52,10 +52,10 @@ var Ue = ({ value: e, fallback: t, children: n, errorFallback: r }) => /* @__PUR
52
52
  width: i[i.length - 1]
53
53
  })
54
54
  };
55
- }, Je = ({ src: e, alt: t, width: n, height: r, fill: i = !1, sizes: a, priority: o = !1, loader: s, placeholder: c = "empty", blurDataURL: l, style: u, ...d }) => {
56
- let f = Ve(U).loader, p = s ?? f;
55
+ }, Ye = ({ src: e, alt: t, width: n, height: r, fill: i = !1, sizes: a, priority: o = !1, loader: s, placeholder: c = "empty", blurDataURL: l, style: u, ...d }) => {
56
+ let f = He(U).loader, p = s ?? f;
57
57
  !i && (n === void 0 || r === void 0) && typeof console < "u" && console.warn(`<Image src="${e}"> needs both width and height (or fill) to reserve layout space and avoid CLS.`);
58
- let { srcSet: m, fallback: h } = qe(p, e, n, i), g = c === "blur" && l ? {
58
+ let { srcSet: m, fallback: h } = Je(p, e, n, i), g = c === "blur" && l ? {
59
59
  backgroundImage: `url(${l})`,
60
60
  backgroundSize: "cover",
61
61
  backgroundPosition: "center"
@@ -85,10 +85,10 @@ var Ue = ({ value: e, fallback: t, children: n, errorFallback: r }) => /* @__PUR
85
85
  },
86
86
  ...d
87
87
  });
88
- }, Ye = ({ to: e, children: t, className: n }) => L("a", {
88
+ }, Xe = ({ to: e, children: t, className: n }) => L("a", {
89
89
  href: e,
90
90
  className: n
91
- }, t), Xe = {
91
+ }, t), Ze = {
92
92
  position: "sticky",
93
93
  top: 0,
94
94
  zIndex: 10,
@@ -99,13 +99,13 @@ var Ue = ({ value: e, fallback: t, children: n, errorFallback: r }) => /* @__PUR
99
99
  padding: "1rem 1.5rem",
100
100
  borderBottom: "1px solid var(--voltro-blog-border, rgba(127,127,127,0.2))",
101
101
  backdropFilter: "blur(8px)"
102
- }, Ze = {
102
+ }, Qe = {
103
103
  maxWidth: "48rem",
104
104
  margin: "0 auto",
105
105
  padding: "2rem 1.5rem",
106
106
  width: "100%"
107
- }, Qe = (e) => {
108
- let { brand: t, topNav: n, children: r, pathname: i, footer: a, breadcrumbs: o, headerRight: s } = e, c = e.Link ?? Ye, l = L("nav", {
107
+ }, $e = (e) => {
108
+ let { brand: t, topNav: n, children: r, pathname: i, footer: a, breadcrumbs: o, headerRight: s } = e, c = e.Link ?? Xe, l = L("nav", {
109
109
  className: "voltro-blog-nav",
110
110
  style: {
111
111
  display: "flex",
@@ -122,7 +122,7 @@ var Ue = ({ value: e, fallback: t, children: n, errorFallback: r }) => /* @__PUR
122
122
  });
123
123
  })), u = L("header", {
124
124
  className: "voltro-blog-header",
125
- style: Xe
125
+ style: Ze
126
126
  }, L("div", { className: "voltro-blog-brand" }, t), s ? L("div", { style: {
127
127
  display: "flex",
128
128
  gap: "1rem",
@@ -150,7 +150,7 @@ var Ue = ({ value: e, fallback: t, children: n, errorFallback: r }) => /* @__PUR
150
150
  })) : null;
151
151
  return L("div", { className: "voltro-blog-layout" }, u, L("main", {
152
152
  className: "voltro-blog-main",
153
- style: Ze
153
+ style: Qe
154
154
  }, d, r), a ? L("footer", {
155
155
  className: "voltro-blog-footer",
156
156
  style: {
@@ -170,7 +170,7 @@ var Ue = ({ value: e, fallback: t, children: n, errorFallback: r }) => /* @__PUR
170
170
  }, q = (e, t, n) => {
171
171
  let r = G(e);
172
172
  return t === n ? r : r === "/" ? `/${t}` : `/${t}${r}`;
173
- }, $e = (e, t) => K(e, t), et = (e) => {
173
+ }, J = (e, t) => K(e, t), et = (e) => {
174
174
  let { siteUrl: t, path: n, locale: r, locales: i, defaultLocale: a, xDefault: o = !0 } = e, s = K(t, q(n, r, a)), c = i.map((e) => ({
175
175
  rel: "alternate",
176
176
  hreflang: e,
@@ -184,7 +184,7 @@ var Ue = ({ value: e, fallback: t, children: n, errorFallback: r }) => /* @__PUR
184
184
  canonical: s,
185
185
  links: c
186
186
  };
187
- }, J = "voltro:theme", tt = 31536e3, Y = () => {
187
+ }, Y = "voltro:theme", tt = 31536e3, nt = () => {
188
188
  if (typeof document > "u") return "system";
189
189
  try {
190
190
  let e = document.cookie.match(/(?:^|;\s*)voltro:theme=([^;]*)/), t = e?.[1] === void 0 ? "" : decodeURIComponent(e[1]);
@@ -192,17 +192,17 @@ var Ue = ({ value: e, fallback: t, children: n, errorFallback: r }) => /* @__PUR
192
192
  } catch {
193
193
  return "system";
194
194
  }
195
- }, nt = () => {
195
+ }, rt = () => {
196
196
  if (typeof window > "u" || !window.matchMedia) return !1;
197
197
  try {
198
198
  return window.matchMedia("(prefers-color-scheme: dark)").matches;
199
199
  } catch {
200
200
  return !1;
201
201
  }
202
- }, X = (e) => e === "system" ? nt() ? "dark" : "light" : e, Z = 0, Q = /* @__PURE__ */ new Set(), $ = () => {
202
+ }, X = (e) => e === "system" ? rt() ? "dark" : "light" : e, Z = 0, Q = /* @__PURE__ */ new Set(), $ = () => {
203
203
  Z++;
204
204
  for (let e of Q) e();
205
- }, rt = (e) => {
205
+ }, it = (e) => {
206
206
  Q.add(e);
207
207
  let t, n = () => $();
208
208
  if (typeof window < "u" && window.matchMedia) try {
@@ -214,21 +214,21 @@ var Ue = ({ value: e, fallback: t, children: n, errorFallback: r }) => /* @__PUR
214
214
  t?.removeEventListener("change", n);
215
215
  } catch {}
216
216
  };
217
- }, it = () => {
218
- let e = Y();
217
+ }, at = () => {
218
+ let e = nt();
219
219
  return `${Z}:${e}:${X(e)}`;
220
- }, at = () => "0:system:light", ot = () => {
221
- let [, e, t] = He(rt, it, at).split(":");
220
+ }, ot = () => "0:system:light", st = () => {
221
+ let [, e, t] = Ue(it, at, ot).split(":");
222
222
  return {
223
223
  theme: e,
224
224
  resolvedTheme: t,
225
- setTheme: Be((e) => {
225
+ setTheme: Ve((e) => {
226
226
  if (typeof document < "u") try {
227
- document.cookie = e === "system" ? `${J}=; path=/; max-age=0; SameSite=Lax` : `${J}=${e}; path=/; max-age=${tt}; SameSite=Lax`, document.documentElement.classList.toggle("dark", X(e) === "dark");
227
+ document.cookie = e === "system" ? `${Y}=; path=/; max-age=0; SameSite=Lax` : `${Y}=${e}; path=/; max-age=${tt}; SameSite=Lax`, document.documentElement.classList.toggle("dark", X(e) === "dark");
228
228
  } catch {}
229
229
  $();
230
230
  }, [])
231
231
  };
232
- }, st = "framework-web";
232
+ }, ct = "framework-web";
233
233
  //#endregion
234
- export { t as AppClientsContext, Ue as Await, Qe as BlogLayout, p as FallbackStringsProvider, Je as Image, Ke as ImageConfigProvider, Te as Link, ke as LoaderCache, N as LoaderDataContext, Se as NO_LOADER_DATA, i as NavigationIndicator, Ie as NotFoundError, je as PAGE_SLOT_ATTR, P as PageSlot, F as PlainLink, Ee as RENDER_MODES, o as ReconnectContext, ue as RedirectError, Ce as Router, ve as RouterContext, Ae as ServerRequestContext, we as ServerRequestProvider, J as THEME_COOKIE, st as WEB_NAME, $e as canonicalUrl, I as compileRoute, d as defaultFallbackStrings, re as defer, A as externalUrl, Me as findNotFound, c as formatPrintf, ee as getIslandComponent, he as getRouteSnapshot, f as getStatuses, te as hydrateIslandsOnPage, a as installBrowserConsoleBridge, r as installServerLogRelay, se as isDeferredLoaderResult, O as isNotFound, ge as isRedirect, _ as island, K as joinUrl, Fe as lazyPageRoute, M as loaderCacheKey, q as localizedPath, Pe as matchRoute, ne as mount, G as normalizePath, D as notFound, T as pageRoute, Oe as parseCookieHeader, H as passthroughImageLoader, de as preloadRouteModule, m as pushStatus, k as redirect, s as registerClientTrace, Ne as renderRouterProviderTree, E as resolveAnchorNavigation, pe as resolveMeta, fe as segmentLoaderKey, et as seoAlternates, v as setRouteSnapshot, S as sortRoutesByPriority, De as subscribeRouteSnapshot, g as subscribeStatuses, l as subscribeTraceErrors, n as useAppClient, xe as useBlocker, h as useFallbackStrings, le as useLoaderData, be as useLocation, b as useNavigate, x as useOptionalLoaderData, C as useParams, me as usePrefetch, u as useReconnect, ye as useSearchParams, j as useServerRequest, _e as useSetSearchParams, ot as useTheme, y as withHash, w as withQuery };
234
+ export { t as AppClientsContext, We as Await, $e as BlogLayout, p as FallbackStringsProvider, Ye as Image, qe as ImageConfigProvider, Ee as Link, Ae as LoaderCache, P as LoaderDataContext, Ce as NO_LOADER_DATA, i as NavigationIndicator, Le as NotFoundError, Me as PAGE_SLOT_ATTR, F as PageSlot, I as PlainLink, De as RENDER_MODES, o as ReconnectContext, de as RedirectError, we as Router, ye as RouterContext, je as ServerRequestContext, Te as ServerRequestProvider, Y as THEME_COOKIE, ct as WEB_NAME, J as canonicalUrl, ve as compileRoute, d as defaultFallbackStrings, ie as defer, j as externalUrl, Ne as findNotFound, c as formatPrintf, ne as getIslandComponent, ge as getRouteSnapshot, f as getStatuses, ee as hydrateIslandsOnPage, a as installBrowserConsoleBridge, r as installServerLogRelay, ce as isDeferredLoaderResult, k as isNotFound, _e as isRedirect, _ as island, K as joinUrl, Ie as lazyPageRoute, N as loaderCacheKey, q as localizedPath, Fe as matchRoute, re as mount, G as normalizePath, O as notFound, te as noticeIslandsShipTheFullBundle, E as pageRoute, ke as parseCookieHeader, H as passthroughImageLoader, fe as preloadRouteModule, m as pushStatus, A as redirect, s as registerClientTrace, Pe as renderRouterProviderTree, D as resolveAnchorNavigation, me as resolveMeta, pe as segmentLoaderKey, et as seoAlternates, y as setRouteSnapshot, C as sortRoutesByPriority, Oe as subscribeRouteSnapshot, g as subscribeStatuses, l as subscribeTraceErrors, n as useAppClient, Se as useBlocker, h as useFallbackStrings, ue as useLoaderData, xe as useLocation, x as useNavigate, S as useOptionalLoaderData, w as useParams, he as usePrefetch, u as useReconnect, be as useSearchParams, M as useServerRequest, v as useSetSearchParams, st as useTheme, b as withHash, T as withQuery };
@@ -1,4 +1,4 @@
1
- import { t as e } from "./frameworkBoot-Dm6UaRP-.js";
1
+ import { t as e } from "./frameworkBoot--fOA34nd.js";
2
2
  import { o as t, r as n, t as r } from "./routerState-DAT472IC.js";
3
3
  import { StrictMode as i, createElement as a } from "react";
4
4
  import { createRoot as o, hydrateRoot as s } from "react-dom/client";
@@ -50,28 +50,32 @@ var d = /* @__PURE__ */ new Map(), f = (e, t) => {
50
50
  t.addEventListener("pointerdown", e, { passive: !0 }), t.addEventListener("keydown", e);
51
51
  }
52
52
  }
53
- }, _ = (e) => `${window.location.protocol === "https:" ? "wss:" : "ws:"}//${window.location.host}/ws/${e}`, v = (a, d) => {
53
+ }, _ = () => !1, v = "__voltroIslandsBundleNoticeShown", y = (e) => {
54
+ if (!e) return;
55
+ let t = globalThis;
56
+ t[v] !== !0 && (t[v] = !0, console.info("[voltro] islands mode: hydration is scoped to this page's islands, but the JS payload is NOT reduced — the full app bundle is still downloaded and evaluated. Islands buy CPU, not bytes, today. See the \"Render modes\" docs page."));
57
+ }, b = (e) => `${window.location.protocol === "https:" ? "wss:" : "ws:"}//${window.location.host}/ws/${e}`, x = (a, d) => {
54
58
  let f = document.getElementById(d.rootId ?? "root");
55
59
  if (!f) throw Error(`@voltro/web: no #${d.rootId ?? "root"} element in the document`);
56
60
  let p = Object.entries(d.apis).map(([e, t]) => ({
57
61
  name: e,
58
62
  group: t.group,
59
63
  descriptors: t.descriptors ?? {},
60
- wsUrl: t.wsUrl ?? _(e),
64
+ wsUrl: t.wsUrl ?? b(e),
61
65
  headers: t.headers
62
66
  })), m = n(document.getElementById(r)?.textContent, window.location.pathname), h = m !== null && f.children.length > 0, v = document.querySelector("meta[name=\"voltro-interactive\"]")?.getAttribute("content") ?? "full";
63
67
  if (v === "none") return;
64
68
  if (v === "islands") {
65
- g();
69
+ y(_()), g();
66
70
  return;
67
71
  }
68
72
  h && t(m), l(m?.storeSeeds), c(m?.preloadSeeds);
69
- let y = /* @__PURE__ */ u(i, { children: /* @__PURE__ */ u(e, {
73
+ let x = /* @__PURE__ */ u(i, { children: /* @__PURE__ */ u(e, {
70
74
  App: a,
71
75
  apis: p,
72
76
  ...d.Devtools ? { Devtools: d.Devtools } : {}
73
77
  }) });
74
- h ? s(f, y) : o(f).render(y);
78
+ h ? s(f, x) : o(f).render(x);
75
79
  };
76
80
  //#endregion
77
- export { f as i, p as n, g as r, v as t };
81
+ export { f as a, g as i, y as n, p as r, x as t };
package/dist/mount.d.ts CHANGED
@@ -58,4 +58,6 @@ export declare interface MountOptions {
58
58
  readonly Devtools?: ComponentType;
59
59
  }
60
60
 
61
+ export declare const noticeIslandsShipTheFullBundle: (isDev: boolean) => void;
62
+
61
63
  export { }
package/dist/mount.js CHANGED
@@ -1,2 +1,2 @@
1
- import { t as e } from "./mount-CXlKierJ.js";
2
- export { e as mount };
1
+ import { n as e, t } from "./mount-BKP99m_W.js";
2
+ export { t as mount, e as noticeIslandsShipTheFullBundle };