@lunora/client 1.0.0-alpha.3 → 1.0.0-alpha.30

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.
Files changed (76) hide show
  1. package/LICENSE.md +6 -0
  2. package/README.md +2 -0
  3. package/dist/auth/index.d.mts +10 -10
  4. package/dist/auth/index.d.ts +10 -10
  5. package/dist/auth/index.mjs +1 -60
  6. package/dist/index.d.mts +521 -169
  7. package/dist/index.d.ts +521 -169
  8. package/dist/index.mjs +1 -14
  9. package/dist/packem_shared/CONFLICT_ERROR_CODE-B2SU0CaJ.mjs +1 -0
  10. package/dist/packem_shared/ClientServiceWorker-CRQ5yl7-.mjs +1 -0
  11. package/dist/packem_shared/DEFAULT_MAX_BUFFER-TBn2s7Rz.mjs +1 -0
  12. package/dist/packem_shared/LunoraClient-DDEoZdgP.mjs +1 -0
  13. package/dist/packem_shared/OfflineQueue-B603_q8m.mjs +1 -0
  14. package/dist/packem_shared/SKIP-CArzT3Vl.mjs +1 -0
  15. package/dist/packem_shared/SubscriptionRegistry-CdrOD7sZ.mjs +1 -0
  16. package/dist/packem_shared/TabCoordinator-ijLic02x.mjs +1 -0
  17. package/dist/packem_shared/applyDelta-DXqQORbM.mjs +1 -0
  18. package/dist/packem_shared/createAsyncStoragePersistence-BRLqeXsC.mjs +1 -0
  19. package/dist/packem_shared/createClientQuery-CrdRoicO.mjs +1 -0
  20. package/dist/packem_shared/createInMemoryBookmarkStorage-DCd5Ej-t.mjs +1 -0
  21. package/dist/packem_shared/createInMemoryPersistence-CQYXy8UP.mjs +1 -0
  22. package/dist/packem_shared/createInMemoryQueryCache-DjCKrLjk.mjs +1 -0
  23. package/dist/packem_shared/createLocalStore-B3Tw_Tw1.mjs +1 -0
  24. package/dist/packem_shared/createMutationRunner-lQXH8Amk.mjs +1 -0
  25. package/dist/packem_shared/createMutatorRunner-BVzo0FBZ.mjs +1 -0
  26. package/dist/packem_shared/createReconnect-CFT7YRSR.mjs +1 -0
  27. package/dist/packem_shared/createReply-DF0jRsv-.mjs +1 -0
  28. package/dist/packem_shared/createServerClient-B7KqO8tv.mjs +1 -0
  29. package/dist/packem_shared/createSnapshotPrecondition-DOKRAJ4b.mjs +1 -0
  30. package/dist/packem_shared/deserializePreloaded-CHfOFpka.mjs +1 -0
  31. package/dist/packem_shared/getServerSession-CGjgRBAE.mjs +1 -0
  32. package/dist/packem_shared/httpStream-Cz4_QyjV.mjs +11 -0
  33. package/dist/packem_shared/idb-utility-C-DR8nG1.mjs +1 -0
  34. package/dist/packem_shared/local-store-C53xDvEr.mjs +1 -0
  35. package/dist/packem_shared/lunora-client.d-Bt65hm_E.d.mts +2979 -0
  36. package/dist/packem_shared/lunora-client.d-Bt65hm_E.d.ts +2979 -0
  37. package/dist/packem_shared/offline-queue-D73Dq95V.mjs +1 -0
  38. package/dist/packem_shared/preload.d-BmztUzzG.d.mts +20 -0
  39. package/dist/packem_shared/preload.d-DGGRMWB5.d.ts +20 -0
  40. package/dist/packem_shared/preloadQuery-DjwSjFwt.mjs +1 -0
  41. package/dist/packem_shared/wire-key-D_zOxXK4.mjs +1 -0
  42. package/dist/pagination/index.d.mts +42 -42
  43. package/dist/pagination/index.d.ts +42 -42
  44. package/dist/pagination/index.mjs +1 -61
  45. package/dist/query/index.d.mts +42 -42
  46. package/dist/query/index.d.ts +42 -42
  47. package/dist/query/index.mjs +1 -1
  48. package/dist/ssr/index.d.mts +79 -79
  49. package/dist/ssr/index.d.ts +79 -79
  50. package/dist/ssr/index.mjs +1 -4
  51. package/dist/upload.d.mts +35 -0
  52. package/dist/upload.d.ts +35 -0
  53. package/dist/upload.mjs +1 -0
  54. package/package.json +9 -1
  55. package/dist/packem_shared/CONFLICT_ERROR_CODE-aUdVbEDw.mjs +0 -4
  56. package/dist/packem_shared/DEFAULT_MAX_BUFFER-BDkqO5PW.mjs +0 -107
  57. package/dist/packem_shared/LunoraClient-UiULzH_1.mjs +0 -2165
  58. package/dist/packem_shared/OfflineQueue-D5p_QgF_.mjs +0 -127
  59. package/dist/packem_shared/SKIP-vItZChkw.mjs +0 -50
  60. package/dist/packem_shared/SubscriptionRegistry-B-Qx_Gux.mjs +0 -26
  61. package/dist/packem_shared/applyDelta-4jFGTPA3.mjs +0 -61
  62. package/dist/packem_shared/createAsyncStoragePersistence-1Z5BZ8RC.mjs +0 -45
  63. package/dist/packem_shared/createInMemoryBookmarkStorage-BoN7a7TH.mjs +0 -11
  64. package/dist/packem_shared/createInMemoryPersistence-CW82inU5.mjs +0 -105
  65. package/dist/packem_shared/createInMemoryQueryCache-B1PQ9Twl.mjs +0 -138
  66. package/dist/packem_shared/createLocalStore-DSUfoLqY.mjs +0 -36
  67. package/dist/packem_shared/createMutationRunner-BqsavzvG.mjs +0 -21
  68. package/dist/packem_shared/createReconnect-Di_-oHH7.mjs +0 -22
  69. package/dist/packem_shared/createServerClient-BjZc3gD8.mjs +0 -11
  70. package/dist/packem_shared/deserializePreloaded-C0eJTY_W.mjs +0 -4
  71. package/dist/packem_shared/getServerSession-8jXewqxd.mjs +0 -13
  72. package/dist/packem_shared/lunora-client.d-DGvyuJ_p.d.mts +0 -1597
  73. package/dist/packem_shared/lunora-client.d-DGvyuJ_p.d.ts +0 -1597
  74. package/dist/packem_shared/preload.d-BoDmFqSG.d.ts +0 -20
  75. package/dist/packem_shared/preload.d-dSaRMuhL.d.mts +0 -20
  76. package/dist/packem_shared/preloadQuery-lobFkD2Z.mjs +0 -13
@@ -0,0 +1 @@
1
+ const c=(n,e)=>n!==void 0&&e!==n;let h=0;const a=()=>{if(typeof crypto<"u"&&typeof crypto.randomUUID=="function")return crypto.randomUUID();h+=1;const n=typeof crypto<"u"&&typeof crypto.getRandomValues=="function"?[...crypto.getRandomValues(new Uint8Array(8))].map(e=>e.toString(16).padStart(2,"0")).join(""):Math.random().toString(16).slice(2,12);return`m_${Date.now().toString(36)}_${h.toString(36)}_${n}`},r=(n,e,t,s)=>{if(n){n({error:t,mutationId:s,operation:e});return}console.warn(`[lunora] offline-queue persistence ${e} failed`,t)};class d{queueBeforeFirstConnect;maxItems;onPersistenceError;persistence;onEvict;onSizeChange;version;items=[];constructor(e={},t={}){this.maxItems=e.maxItems??1e3,this.queueBeforeFirstConnect=e.queueBeforeFirstConnect??!1,this.onPersistenceError=e.onPersistenceError,this.persistence=t.persistence,this.onEvict=t.onEvict,this.onSizeChange=t.onSizeChange,this.version=t.version}get size(){return this.items.length}enqueue(e){const t=e;for(t.id??=a(),this.items.push(t),this.persistence?.append({args:t.args,functionPath:t.functionPath,id:t.id,identity:t.identity,shardKey:t.shardKey,...this.version===void 0?{}:{version:this.version}}).catch(s=>{r(this.onPersistenceError,"append",s,t.id)});this.items.length>this.maxItems;){const s=this.items.shift();if(s){s.id&&this.persistence?.remove(s.id).catch(o=>{r(this.onPersistenceError,"remove",o,s.id)});const i=new Error("offline queue overflow");i.code="OFFLINE_QUEUE_OVERFLOW",s.reject(i),this.onEvict?.(s,i)}}this.notifySize()}async hydrate(){if(!this.persistence)return[];let e;try{e=await this.persistence.load()}catch(i){throw r(this.onPersistenceError,"load",i),i}const t=new Set,s=[];for(const i of e)if(!(this.items.some(o=>o.id===i.id)||s.some(o=>o.id===i.id))){if(c(this.version,i.version)){this.persistence.remove(i.id).catch(o=>{r(this.onPersistenceError,"remove",o,i.id)});continue}s.push({args:i.args,functionPath:i.functionPath,id:i.id,identity:i.identity,reject:()=>{},resolve:()=>{},shardKey:i.shardKey}),t.add(i.shardKey)}return this.items.unshift(...s),this.notifySize(),[...t]}drain(e){if(!e){const i=[...this.items];return this.items.length=0,this.notifySize(),i}const t=[],s=[];for(const i of this.items)(e(i)?t:s).push(i);return this.items.length=0,this.items.push(...s),this.notifySize(),t}requeue(e){e.length!==0&&(this.items.unshift(...e),this.notifySize())}drainConflict(){const e=[],t=[];for(const s of this.items)if(s.precondition!==void 0&&!s.precondition()){const i=new Error("offline mutation skipped: precondition failed before replay");i.code="OFFLINE_PRECONDITION_FAILED",s.reject(i),e.push(s)}else t.push(s);return e.length>0&&(this.items.length=0,this.items.push(...t),this.notifySize()),e}clear(){for(const e of this.items){const t=new Error("CLIENT_CLOSED");t.code="CLIENT_CLOSED",e.reject(t)}this.items.length=0,this.notifySize()}notifySize(){this.onSizeChange?.(this.items.length)}}export{d as c,c as d,r as s,a as u};
@@ -0,0 +1,20 @@
1
+ import { F as FunctionReference, L as LunoraClient, A as ArgsOf, R as ReturnOf, P as Preloaded } from "./lunora-client.d-Bt65hm_E.mjs";
2
+ /**
3
+ * Run a query once on the server (during SSR) and capture its result in a
4
+ * serializable {@link Preloaded} token. Embed the token in the rendered HTML and
5
+ * pass it to `usePreloadedQuery` on the client: the first client render shows
6
+ * the server value with no loading flash, then a live subscription takes over.
7
+ *
8
+ * The query is executed through the supplied {@link LunoraClient} over the same
9
+ * HTTP RPC path the browser uses, so the SSR client only needs a `fetch`
10
+ * implementation that can reach the worker — no in-process Durable Object access.
11
+ */
12
+ declare const preloadQuery: <F extends FunctionReference>(client: LunoraClient, function_: F, args: ArgsOf<F>, options?: {
13
+ shardKey?: string;
14
+ }) => Promise<Preloaded<ReturnOf<F>>>;
15
+ /**
16
+ * Read the captured value out of a {@link Preloaded} token without subscribing.
17
+ * Useful on the server (or in tests) when you only need the data, not a live feed.
18
+ */
19
+ declare const preloadedQueryResult: <T>(preloaded: Preloaded<T>) => T;
20
+ export { preloadedQueryResult as a, preloadQuery as p };
@@ -0,0 +1,20 @@
1
+ import { F as FunctionReference, L as LunoraClient, A as ArgsOf, R as ReturnOf, P as Preloaded } from "./lunora-client.d-Bt65hm_E.js";
2
+ /**
3
+ * Run a query once on the server (during SSR) and capture its result in a
4
+ * serializable {@link Preloaded} token. Embed the token in the rendered HTML and
5
+ * pass it to `usePreloadedQuery` on the client: the first client render shows
6
+ * the server value with no loading flash, then a live subscription takes over.
7
+ *
8
+ * The query is executed through the supplied {@link LunoraClient} over the same
9
+ * HTTP RPC path the browser uses, so the SSR client only needs a `fetch`
10
+ * implementation that can reach the worker — no in-process Durable Object access.
11
+ */
12
+ declare const preloadQuery: <F extends FunctionReference>(client: LunoraClient, function_: F, args: ArgsOf<F>, options?: {
13
+ shardKey?: string;
14
+ }) => Promise<Preloaded<ReturnOf<F>>>;
15
+ /**
16
+ * Read the captured value out of a {@link Preloaded} token without subscribing.
17
+ * Useful on the server (or in tests) when you only need the data, not a live feed.
18
+ */
19
+ declare const preloadedQueryResult: <T>(preloaded: Preloaded<T>) => T;
20
+ export { preloadedQueryResult as a, preloadQuery as p };
@@ -0,0 +1 @@
1
+ const l=async(e,a,r,u={})=>{const o=await e.query(a,r,u);return{__lunoraPreloaded:!0,args:r??{},functionPath:a.__lunoraRef,shardKey:u.shardKey,value:o}},t=e=>e.value;export{l as preloadQuery,t as preloadedQueryResult};
@@ -0,0 +1 @@
1
+ const m=(e,t)=>e<t?-1:e>t?1:0,p=e=>{if(e===void 0)return"null";if(typeof e=="bigint")throw new TypeError("stableStringify: cannot use a bigint in a stable JSON cache key — pass it as a string, or use stableWireKey");if(e===null||typeof e!="object")return JSON.stringify(e);if(Array.isArray(e))return`[${e.map(o=>p(o)).join(",")}]`;const t=Object.getPrototypeOf(e);if(t!==null&&t!==Object.prototype){const o=e.constructor?.name??"value";throw new TypeError(`stableStringify: cannot use a ${o} in a stable JSON cache key — only plain objects, arrays, and JSON primitives are supported (wire-typed values key via stableWireKey)`)}const i=e,c=Object.keys(i).toSorted(m),n=[];for(const o of c){const r=i[o];r!==void 0&&n.push(`${JSON.stringify(o)}:${p(r)}`)}return`{${n.join(",")}}`},b=e=>{let t="";for(let i=0;i<e.length;i+=32768)t+=String.fromCharCode(...e.subarray(i,i+32768));return btoa(t)},A=e=>{const t=atob(e),i=new Uint8Array(t.length);for(let c=0;c<t.length;c+=1)i[c]=t.codePointAt(c)??0;return i},s="$lunora.wire$";const g="__proto__",d={BigInt64Array,BigUint64Array,Float32Array,Float64Array,Int8Array,Int16Array,Int32Array,Uint8Array,Uint8ClampedArray,Uint16Array,Uint32Array},w={Error,EvalError,RangeError,ReferenceError,SyntaxError,TypeError,URIError},l=(e,t=0)=>{if(t>64)throw new RangeError("wire-codec: value nesting exceeds the 64-level limit");if(e===void 0)return[s,"undefined"];if(e===null)return null;const i=typeof e;if(i==="bigint")return[s,"bigint",e.toString()];if(i==="number"){const r=e;return Number.isNaN(r)?[s,"nan"]:r===1/0?[s,"inf"]:r===-1/0?[s,"-inf"]:r}if(i!=="object")return e;if(e instanceof Date)return[s,"date",l(e.getTime(),t+1)];if(e instanceof Error){const r=e,a={};for(const y of Object.keys(r))r[y]!==void 0&&(a[y]=l(r[y],t+1));const f=[s,"error",r.name,r.message,a];return r.cause!==void 0&&f.push(l(r.cause,t+1)),f}if(e instanceof URL)return[s,"url",e.href];if(e instanceof Map)return[s,"map",[...e.entries()].map(([r,a])=>[l(r,t+1),l(a,t+1)])];if(e instanceof Set)return[s,"set",[...e].map(r=>l(r,t+1))];if(e instanceof ArrayBuffer)return[s,"bytes",b(new Uint8Array(e)),"ArrayBuffer"];if(ArrayBuffer.isView(e)){const r=e,a=r.constructor.name,f=new Uint8Array(r.buffer,r.byteOffset,r.byteLength);return a==="Uint8Array"?[s,"bytes",b(f)]:[s,"bytes",b(f),a]}if(Array.isArray(e)){const r=e.map(a=>l(a,t+1));return r.length>0&&r[0]===s?[s,"arr",r]:r}const c=Object.getPrototypeOf(e);if(c!==null&&c!==Object.prototype){const r=e.constructor?.name??"value";throw new TypeError(`wire-codec: cannot encode a ${r} over the Lunora wire — only plain objects, arrays, and the supported built-ins (Date, Error, URL, Map, Set, ArrayBuffer/typed arrays, bigint) round-trip`)}const n=e,o={};for(const r of Object.keys(n)){const a=n[r];a!==void 0&&(o[r]=l(a,t+1))}return o},u=(e,t=0)=>{if(t>64)throw new RangeError("wire-codec: value nesting exceeds the 64-level limit");if(e===null||typeof e!="object")return e;if(Array.isArray(e)){if(e[0]===s)switch(e[1]){case"-inf":return-1/0;case"arr":return e[2].map(n=>u(n,t+1));case"bigint":{const n=e[2];if(typeof n!="string"||n.length>1024||!/^-?\d+$/.test(n))throw new RangeError("wire-codec: invalid or over-long bigint (max 1024 digits)");return BigInt(n)}case"date":return new Date(u(e[2],t+1));case"map":return new Map(e[2].map(([n,o])=>[u(n,t+1),u(o,t+1)]));case"set":return new Set(e[2].map(n=>u(n,t+1)));case"url":return new URL(e[2]);case"error":{const n=e[2],o=e[3],r=(Object.hasOwn(w,n)?w[n]:void 0)??Error,a=new r(o);a.name!==n&&Object.defineProperty(a,"name",{configurable:!0,value:n,writable:!0});const f=u(e[4],t+1);for(const y of Object.keys(f))y===g?Object.defineProperty(a,y,{configurable:!0,enumerable:!0,value:f[y],writable:!0}):a[y]=f[y];return e.length>5&&Object.defineProperty(a,"cause",{configurable:!0,value:u(e[5],t+1),writable:!0}),a}case"bytes":{const n=A(e[2]),o=e[3]??"Uint8Array";if(o==="ArrayBuffer")return n.buffer.byteLength===n.byteLength?n.buffer:n.slice().buffer;const r=Object.hasOwn(d,o)?d[o]:void 0;return r?new r(n.slice().buffer):n}case"inf":return 1/0;case"nan":return Number.NaN;case"undefined":return;default:return e.map(n=>u(n,t+1))}return e.map(n=>u(n,t+1))}const i=e,c={};for(const n of Object.keys(i)){const o=u(i[n],t+1);n===g?Object.defineProperty(c,n,{configurable:!0,enumerable:!0,value:o,writable:!0}):c[n]=o}return c},h=e=>p(l(e));export{u as c,l as f,h as t};
@@ -1,13 +1,13 @@
1
1
  /**
2
- * `@lunora/client/pagination` — the framework-agnostic pagination state machine
3
- * shared by every Lunora UI adapter (React, Vue, Svelte, Solid).
4
- *
5
- * Owns cursor tracking, page-size rebalancing (split/join), `initialPages`,
6
- * `rebalance`, and the shared types (`Page`, `PaginationResult`,
7
- * `PaginationStatus`, `PaginatedCoreResult`). Nothing here imports a UI
8
- * framework — each adapter wires the pure functions into its own reactive
9
- * primitives.
10
- */
2
+ * `@lunora/client/pagination` — the framework-agnostic pagination state machine
3
+ * shared by every Lunora UI adapter (React, Vue, Svelte, Solid).
4
+ *
5
+ * Owns cursor tracking, page-size rebalancing (split/join), `initialPages`,
6
+ * `rebalance`, and the shared types (`Page`, `PaginationResult`,
7
+ * `PaginationStatus`, `PaginatedCoreResult`). Nothing here imports a UI
8
+ * framework — each adapter wires the pure functions into its own reactive
9
+ * primitives.
10
+ */
11
11
  /** Grow factor: a bounded page is split when it exceeds this multiple of its target size. */
12
12
  declare const SPLIT_FACTOR = 2;
13
13
  /** Shrink factor: a bounded page with a neighbour is joined when it falls below this multiple of its target size. */
@@ -24,20 +24,20 @@ interface PaginationResult<T = unknown> {
24
24
  isDone: boolean;
25
25
  page: T[];
26
26
  /**
27
- * Reactive-pagination only: the midpoint cursor of a bounded
28
- * `(cursor, endCursor]` page, used to split an over-grown page into two
29
- * adjacent ranges. Absent on legacy (open-ended) pages.
30
- */
27
+ * Reactive-pagination only: the midpoint cursor of a bounded
28
+ * `(cursor, endCursor]` page, used to split an over-grown page into two
29
+ * adjacent ranges. Absent on legacy (open-ended) pages.
30
+ */
31
31
  splitCursor?: null | string;
32
32
  }
33
33
  /**
34
- * Lifecycle of a `usePaginatedQuery` feed.
35
- *
36
- * - `LoadingFirstPage` — the first page is in flight; `results` is empty.
37
- * - `CanLoadMore` — the loaded tail has a cursor; calling `loadMore` fetches the next page.
38
- * - `LoadingMore` — a `loadMore` page is in flight; earlier results stay visible.
39
- * - `Exhausted` — every page has loaded and the server reported `isDone`.
40
- */
34
+ * Lifecycle of a `usePaginatedQuery` feed.
35
+ *
36
+ * - `LoadingFirstPage` — the first page is in flight; `results` is empty.
37
+ * - `CanLoadMore` — the loaded tail has a cursor; calling `loadMore` fetches the next page.
38
+ * - `LoadingMore` — a `loadMore` page is in flight; earlier results stay visible.
39
+ * - `Exhausted` — every page has loaded and the server reported `isDone`.
40
+ */
41
41
  type PaginationStatus = "CanLoadMore" | "Exhausted" | "LoadingFirstPage" | "LoadingMore";
42
42
  interface PaginatedCoreResult<T> {
43
43
  /** Request another page off the open-ended tail. A no-op unless `status === "CanLoadMore"`. */
@@ -49,34 +49,34 @@ interface PaginatedCoreResult<T> {
49
49
  /** First-page seed: a single open-ended range starting at the feed head. */
50
50
  declare const initialPages: (numberItems: number) => Page[];
51
51
  /**
52
- * Run the SPLIT/JOIN maintenance pass over the current page list given freshly
53
- * resolved results. Returns a new page list when a boundary changed, or
54
- * `undefined` when the layout is already balanced (so the caller can skip a
55
- * setState).
56
- *
57
- * Only ONE structural edit is applied per pass (the first split or join found),
58
- * letting the subsequent re-render's resolved results drive the next pass — this
59
- * keeps each transition observable and avoids reasoning about several
60
- * simultaneous boundary moves.
61
- */
52
+ * Run the SPLIT/JOIN maintenance pass over the current page list given freshly
53
+ * resolved results. Returns a new page list when a boundary changed, or
54
+ * `undefined` when the layout is already balanced (so the caller can skip a
55
+ * setState).
56
+ *
57
+ * Only ONE structural edit is applied per pass (the first split or join found),
58
+ * letting the subsequent re-render's resolved results drive the next pass — this
59
+ * keeps each transition observable and avoids reasoning about several
60
+ * simultaneous boundary moves.
61
+ */
62
62
  declare const rebalance: (pages: Page[], results: (PaginationResult | undefined)[]) => Page[] | undefined;
63
63
  /**
64
- * Derive the feed `status` and the next-page cursor from the current page list
65
- * and resolved page results. Framework adapters call this each render/effect to
66
- * compute what to expose to callers.
67
- */
64
+ * Derive the feed `status` and the next-page cursor from the current page list
65
+ * and resolved page results. Framework adapters call this each render/effect to
66
+ * compute what to expose to callers.
67
+ */
68
68
  declare const derivePaginationStatus: <T>(skipped: boolean, pageResults: (PaginationResult<T> | undefined)[]) => {
69
69
  nextCursor: null | string | undefined;
70
70
  status: PaginationStatus;
71
71
  };
72
72
  /**
73
- * Apply a `loadMore` to the current page list. Pins the open-ended tail at
74
- * `cursor` (making it a fixed bounded range) and appends a fresh open-ended
75
- * page starting at `cursor`. The shared boundary keeps the feed gap- and
76
- * dup-free.
77
- *
78
- * Returns the new page list, or `undefined` when the given `cursor` is not
79
- * valid (null or undefined — caller should no-op).
80
- */
73
+ * Apply a `loadMore` to the current page list. Pins the open-ended tail at
74
+ * `cursor` (making it a fixed bounded range) and appends a fresh open-ended
75
+ * page starting at `cursor`. The shared boundary keeps the feed gap- and
76
+ * dup-free.
77
+ *
78
+ * Returns the new page list, or `undefined` when the given `cursor` is not
79
+ * valid (null or undefined — caller should no-op).
80
+ */
81
81
  declare const applyLoadMore: (pages: Page[], cursor: null | string | undefined, numberItems: number) => Page[] | undefined;
82
82
  export { JOIN_FACTOR, type Page, type PaginatedCoreResult, type PaginationResult, type PaginationStatus, SPLIT_FACTOR, applyLoadMore, derivePaginationStatus, initialPages, rebalance };
@@ -1,13 +1,13 @@
1
1
  /**
2
- * `@lunora/client/pagination` — the framework-agnostic pagination state machine
3
- * shared by every Lunora UI adapter (React, Vue, Svelte, Solid).
4
- *
5
- * Owns cursor tracking, page-size rebalancing (split/join), `initialPages`,
6
- * `rebalance`, and the shared types (`Page`, `PaginationResult`,
7
- * `PaginationStatus`, `PaginatedCoreResult`). Nothing here imports a UI
8
- * framework — each adapter wires the pure functions into its own reactive
9
- * primitives.
10
- */
2
+ * `@lunora/client/pagination` — the framework-agnostic pagination state machine
3
+ * shared by every Lunora UI adapter (React, Vue, Svelte, Solid).
4
+ *
5
+ * Owns cursor tracking, page-size rebalancing (split/join), `initialPages`,
6
+ * `rebalance`, and the shared types (`Page`, `PaginationResult`,
7
+ * `PaginationStatus`, `PaginatedCoreResult`). Nothing here imports a UI
8
+ * framework — each adapter wires the pure functions into its own reactive
9
+ * primitives.
10
+ */
11
11
  /** Grow factor: a bounded page is split when it exceeds this multiple of its target size. */
12
12
  declare const SPLIT_FACTOR = 2;
13
13
  /** Shrink factor: a bounded page with a neighbour is joined when it falls below this multiple of its target size. */
@@ -24,20 +24,20 @@ interface PaginationResult<T = unknown> {
24
24
  isDone: boolean;
25
25
  page: T[];
26
26
  /**
27
- * Reactive-pagination only: the midpoint cursor of a bounded
28
- * `(cursor, endCursor]` page, used to split an over-grown page into two
29
- * adjacent ranges. Absent on legacy (open-ended) pages.
30
- */
27
+ * Reactive-pagination only: the midpoint cursor of a bounded
28
+ * `(cursor, endCursor]` page, used to split an over-grown page into two
29
+ * adjacent ranges. Absent on legacy (open-ended) pages.
30
+ */
31
31
  splitCursor?: null | string;
32
32
  }
33
33
  /**
34
- * Lifecycle of a `usePaginatedQuery` feed.
35
- *
36
- * - `LoadingFirstPage` — the first page is in flight; `results` is empty.
37
- * - `CanLoadMore` — the loaded tail has a cursor; calling `loadMore` fetches the next page.
38
- * - `LoadingMore` — a `loadMore` page is in flight; earlier results stay visible.
39
- * - `Exhausted` — every page has loaded and the server reported `isDone`.
40
- */
34
+ * Lifecycle of a `usePaginatedQuery` feed.
35
+ *
36
+ * - `LoadingFirstPage` — the first page is in flight; `results` is empty.
37
+ * - `CanLoadMore` — the loaded tail has a cursor; calling `loadMore` fetches the next page.
38
+ * - `LoadingMore` — a `loadMore` page is in flight; earlier results stay visible.
39
+ * - `Exhausted` — every page has loaded and the server reported `isDone`.
40
+ */
41
41
  type PaginationStatus = "CanLoadMore" | "Exhausted" | "LoadingFirstPage" | "LoadingMore";
42
42
  interface PaginatedCoreResult<T> {
43
43
  /** Request another page off the open-ended tail. A no-op unless `status === "CanLoadMore"`. */
@@ -49,34 +49,34 @@ interface PaginatedCoreResult<T> {
49
49
  /** First-page seed: a single open-ended range starting at the feed head. */
50
50
  declare const initialPages: (numberItems: number) => Page[];
51
51
  /**
52
- * Run the SPLIT/JOIN maintenance pass over the current page list given freshly
53
- * resolved results. Returns a new page list when a boundary changed, or
54
- * `undefined` when the layout is already balanced (so the caller can skip a
55
- * setState).
56
- *
57
- * Only ONE structural edit is applied per pass (the first split or join found),
58
- * letting the subsequent re-render's resolved results drive the next pass — this
59
- * keeps each transition observable and avoids reasoning about several
60
- * simultaneous boundary moves.
61
- */
52
+ * Run the SPLIT/JOIN maintenance pass over the current page list given freshly
53
+ * resolved results. Returns a new page list when a boundary changed, or
54
+ * `undefined` when the layout is already balanced (so the caller can skip a
55
+ * setState).
56
+ *
57
+ * Only ONE structural edit is applied per pass (the first split or join found),
58
+ * letting the subsequent re-render's resolved results drive the next pass — this
59
+ * keeps each transition observable and avoids reasoning about several
60
+ * simultaneous boundary moves.
61
+ */
62
62
  declare const rebalance: (pages: Page[], results: (PaginationResult | undefined)[]) => Page[] | undefined;
63
63
  /**
64
- * Derive the feed `status` and the next-page cursor from the current page list
65
- * and resolved page results. Framework adapters call this each render/effect to
66
- * compute what to expose to callers.
67
- */
64
+ * Derive the feed `status` and the next-page cursor from the current page list
65
+ * and resolved page results. Framework adapters call this each render/effect to
66
+ * compute what to expose to callers.
67
+ */
68
68
  declare const derivePaginationStatus: <T>(skipped: boolean, pageResults: (PaginationResult<T> | undefined)[]) => {
69
69
  nextCursor: null | string | undefined;
70
70
  status: PaginationStatus;
71
71
  };
72
72
  /**
73
- * Apply a `loadMore` to the current page list. Pins the open-ended tail at
74
- * `cursor` (making it a fixed bounded range) and appends a fresh open-ended
75
- * page starting at `cursor`. The shared boundary keeps the feed gap- and
76
- * dup-free.
77
- *
78
- * Returns the new page list, or `undefined` when the given `cursor` is not
79
- * valid (null or undefined — caller should no-op).
80
- */
73
+ * Apply a `loadMore` to the current page list. Pins the open-ended tail at
74
+ * `cursor` (making it a fixed bounded range) and appends a fresh open-ended
75
+ * page starting at `cursor`. The shared boundary keeps the feed gap- and
76
+ * dup-free.
77
+ *
78
+ * Returns the new page list, or `undefined` when the given `cursor` is not
79
+ * valid (null or undefined — caller should no-op).
80
+ */
81
81
  declare const applyLoadMore: (pages: Page[], cursor: null | string | undefined, numberItems: number) => Page[] | undefined;
82
82
  export { JOIN_FACTOR, type Page, type PaginatedCoreResult, type PaginationResult, type PaginationStatus, SPLIT_FACTOR, applyLoadMore, derivePaginationStatus, initialPages, rebalance };
@@ -1,61 +1 @@
1
- const SPLIT_FACTOR = 2;
2
- const JOIN_FACTOR = 0.5;
3
- const initialPages = (numberItems) => [
4
- // eslint-disable-next-line unicorn/no-null -- `lower: null` is the feed head, `upper: null` the open-ended tail — both are wire-shape cursors.
5
- { lower: null, numItems: numberItems, upper: null }
6
- ];
7
- const rebalance = (pages, results) => {
8
- for (const [index, page] of pages.entries()) {
9
- if (page.upper === null) {
10
- continue;
11
- }
12
- const result = results[index];
13
- if (!result) {
14
- continue;
15
- }
16
- const size = result.page.length;
17
- if (size > SPLIT_FACTOR * page.numItems && result.splitCursor) {
18
- const split = result.splitCursor;
19
- const next = [...pages];
20
- next.splice(index, 1, { lower: page.lower, numItems: page.numItems, upper: split }, { lower: split, numItems: page.numItems, upper: page.upper });
21
- return next;
22
- }
23
- if (size < JOIN_FACTOR * page.numItems && index + 1 < pages.length) {
24
- const neighbour = pages[index + 1];
25
- if (!neighbour) {
26
- continue;
27
- }
28
- const next = [...pages];
29
- next.splice(index, 2, { lower: page.lower, numItems: page.numItems, upper: neighbour.upper });
30
- return next;
31
- }
32
- }
33
- return void 0;
34
- };
35
- const derivePaginationStatus = (skipped, pageResults) => {
36
- if (skipped || !pageResults[0]) {
37
- return { nextCursor: void 0, status: "LoadingFirstPage" };
38
- }
39
- const tail = pageResults.at(-1);
40
- if (!tail) {
41
- return { nextCursor: void 0, status: "LoadingMore" };
42
- }
43
- if (tail.isDone || tail.continueCursor === null) {
44
- return { nextCursor: void 0, status: "Exhausted" };
45
- }
46
- return { nextCursor: tail.continueCursor, status: "CanLoadMore" };
47
- };
48
- const applyLoadMore = (pages, cursor, numberItems) => {
49
- if (cursor === void 0 || cursor === null) {
50
- return void 0;
51
- }
52
- const next = [...pages];
53
- const tail = next.at(-1);
54
- if (tail) {
55
- next[next.length - 1] = { lower: tail.lower, numItems: tail.numItems, upper: cursor };
56
- }
57
- next.push({ lower: cursor, numItems: numberItems, upper: null });
58
- return next;
59
- };
60
-
61
- export { JOIN_FACTOR, SPLIT_FACTOR, applyLoadMore, derivePaginationStatus, initialPages, rebalance };
1
+ const l=2,a=.5,p=r=>[{lower:null,numItems:r,upper:null}],m=(r,s)=>{for(const[n,e]of r.entries()){if(e.upper===null)continue;const t=s[n];if(!t)continue;const i=t.page.length;if(i>2*e.numItems&&t.splitCursor){const u=t.splitCursor,o=[...r];return o.splice(n,1,{lower:e.lower,numItems:e.numItems,upper:u},{lower:u,numItems:e.numItems,upper:e.upper}),o}if(i<.5*e.numItems&&n+1<r.length){const u=r[n+1];if(!u)continue;const o=[...r];return o.splice(n,2,{lower:e.lower,numItems:e.numItems,upper:u.upper}),o}}},c=(r,s)=>{if(r||!s[0])return{nextCursor:void 0,status:"LoadingFirstPage"};const n=s.at(-1);return n?n.isDone||n.continueCursor===null?{nextCursor:void 0,status:"Exhausted"}:{nextCursor:n.continueCursor,status:"CanLoadMore"}:{nextCursor:void 0,status:"LoadingMore"}},I=(r,s,n)=>{if(s==null)return;const e=[...r],t=e.at(-1);return t&&(e[e.length-1]={lower:t.lower,numItems:t.numItems,upper:s}),e.push({lower:s,numItems:n,upper:null}),e};export{a as JOIN_FACTOR,l as SPLIT_FACTOR,I as applyLoadMore,c as derivePaginationStatus,p as initialPages,m as rebalance};
@@ -1,26 +1,26 @@
1
- import { S as SubscriptionError, F as FunctionReference, A as ArgsOf, R as ReturnOf, L as LunoraClient, a as Unsubscribe } from "../packem_shared/lunora-client.d-DGvyuJ_p.mjs";
2
- export type { b as SubscriptionErrorCallback } from "../packem_shared/lunora-client.d-DGvyuJ_p.mjs";
1
+ import { S as SubscriptionError, F as FunctionReference, A as ArgsOf, R as ReturnOf, L as LunoraClient, a as Unsubscribe } from "../packem_shared/lunora-client.d-Bt65hm_E.mjs";
2
+ export type { b as SubscriptionErrorCallback } from "../packem_shared/lunora-client.d-Bt65hm_E.mjs";
3
3
  import '@lunora/runtime';
4
4
  /**
5
- * The sentinel a framework adapter resolves its reactive args to when it wants
6
- * to short-circuit a query — no network call, no socket.
7
- */
5
+ * The sentinel a framework adapter resolves its reactive args to when it wants
6
+ * to short-circuit a query — no network call, no socket.
7
+ */
8
8
  declare const SKIP: "skip";
9
9
  /** Args after a framework has resolved its reactivity primitive, or the skip sentinel. */
10
10
  type ResolvedArgs<F extends FunctionReference> = ArgsOf<F> | typeof SKIP;
11
11
  /**
12
- * The framework-neutral sinks a {@link createQuerySubscription} call drives. A
13
- * framework adapter supplies these, wiring each into its own reactivity
14
- * primitive (a TanStack cache write, a Vue `ref`, a Svelte store `set`, a Solid
15
- * signal setter).
16
- *
17
- * `onData` fires when a fresh server value lands (the initial frame or a delta).
18
- * `onError` fires when the subscription attach threw, or the server pushed a
19
- * subscription-scoped error — it is optional, and when omitted an attach throw
20
- * propagates to the caller (preserving the "no error channel" behaviour of
21
- * adapters like Solid/Vue that never had one) rather than being swallowed.
22
- * `onReset` fires when the resolved args are `"skip"`: clear any prior value.
23
- */
12
+ * The framework-neutral sinks a {@link createQuerySubscription} call drives. A
13
+ * framework adapter supplies these, wiring each into its own reactivity
14
+ * primitive (a TanStack cache write, a Vue `ref`, a Svelte store `set`, a Solid
15
+ * signal setter).
16
+ *
17
+ * `onData` fires when a fresh server value lands (the initial frame or a delta).
18
+ * `onError` fires when the subscription attach threw, or the server pushed a
19
+ * subscription-scoped error — it is optional, and when omitted an attach throw
20
+ * propagates to the caller (preserving the "no error channel" behaviour of
21
+ * adapters like Solid/Vue that never had one) rather than being swallowed.
22
+ * `onReset` fires when the resolved args are `"skip"`: clear any prior value.
23
+ */
24
24
  interface QuerySubscriptionSinks<T> {
25
25
  onData: (value: T) => void;
26
26
  onError?: (error: SubscriptionError) => void;
@@ -33,30 +33,30 @@ interface QuerySubscriptionOptions {
33
33
  /** Normalise an unknown thrown value into the client's {@link SubscriptionError} shape. */
34
34
  declare const toSubscriptionError: (error: unknown) => SubscriptionError;
35
35
  /**
36
- * The subscribe → snapshot → error/reset → cleanup state machine shared by
37
- * every Lunora framework adapter's live-query hook.
38
- *
39
- * Given a `client`, a function reference, the already-resolved `args` (a
40
- * framework reads its own reactive source first, then hands the plain value in),
41
- * and a set of {@link QuerySubscriptionSinks}, this opens one `client.subscribe`
42
- * registration and returns the {@link Unsubscribe} to tear it down. Each
43
- * framework owns *when* to call this (a React effect, a Vue `watch`, a Svelte
44
- * store start callback, a Solid `createEffect(on(...))`) and *where* to stash
45
- * the value — this owns the lifecycle in between, so the skip-handling, the
46
- * value/error fan-out, the attach-throw normalisation, and the
47
- * cancellation-guarded teardown live in exactly one place.
48
- *
49
- * Behaviour. When `args === "skip"` it calls `sinks.onReset?.()` and returns a
50
- * no-op teardown; no `client.subscribe` is issued. Otherwise it opens
51
- * `client.subscribe(fn, args, …, { shardKey, onError })`: server pushes route to
52
- * `sinks.onData`, and the client's own `onError` channel (a server-rejected
53
- * subscription) routes to `sinks.onError` when present. The attach is wrapped —
54
- * if `client.subscribe` itself throws, the error is normalised to a
55
- * {@link SubscriptionError} and delivered to `sinks.onError` when present; with
56
- * no `onError` sink the throw is rethrown so adapters without an error channel
57
- * behave exactly as before. The returned teardown is idempotent and
58
- * cancellation-guarded: once it runs, no further `onData`/`onError` from an
59
- * in-flight push reaches the sinks.
60
- */
36
+ * The subscribe → snapshot → error/reset → cleanup state machine shared by
37
+ * every Lunora framework adapter's live-query hook.
38
+ *
39
+ * Given a `client`, a function reference, the already-resolved `args` (a
40
+ * framework reads its own reactive source first, then hands the plain value in),
41
+ * and a set of {@link QuerySubscriptionSinks}, this opens one `client.subscribe`
42
+ * registration and returns the {@link Unsubscribe} to tear it down. Each
43
+ * framework owns *when* to call this (a React effect, a Vue `watch`, a Svelte
44
+ * store start callback, a Solid `createEffect(on(...))`) and *where* to stash
45
+ * the value — this owns the lifecycle in between, so the skip-handling, the
46
+ * value/error fan-out, the attach-throw normalisation, and the
47
+ * cancellation-guarded teardown live in exactly one place.
48
+ *
49
+ * Behaviour. When `args === "skip"` it calls `sinks.onReset?.()` and returns a
50
+ * no-op teardown; no `client.subscribe` is issued. Otherwise it opens
51
+ * `client.subscribe(fn, args, …, { shardKey, onError })`: server pushes route to
52
+ * `sinks.onData`, and the client's own `onError` channel (a server-rejected
53
+ * subscription) routes to `sinks.onError` when present. The attach is wrapped —
54
+ * if `client.subscribe` itself throws, the error is normalised to a
55
+ * {@link SubscriptionError} and delivered to `sinks.onError` when present; with
56
+ * no `onError` sink the throw is rethrown so adapters without an error channel
57
+ * behave exactly as before. The returned teardown is idempotent and
58
+ * cancellation-guarded: once it runs, no further `onData`/`onError` from an
59
+ * in-flight push reaches the sinks.
60
+ */
61
61
  declare const createQuerySubscription: <F extends FunctionReference, T = ReturnOf<F>>(client: LunoraClient, function_: F, args: ResolvedArgs<F>, sinks: QuerySubscriptionSinks<T>, options?: QuerySubscriptionOptions) => Unsubscribe;
62
62
  export { type ArgsOf, type FunctionReference, type QuerySubscriptionOptions, type QuerySubscriptionSinks, type ResolvedArgs, type ReturnOf, SKIP, type SubscriptionError, type Unsubscribe, createQuerySubscription, toSubscriptionError };
@@ -1,26 +1,26 @@
1
- import { S as SubscriptionError, F as FunctionReference, A as ArgsOf, R as ReturnOf, L as LunoraClient, a as Unsubscribe } from "../packem_shared/lunora-client.d-DGvyuJ_p.js";
2
- export type { b as SubscriptionErrorCallback } from "../packem_shared/lunora-client.d-DGvyuJ_p.js";
1
+ import { S as SubscriptionError, F as FunctionReference, A as ArgsOf, R as ReturnOf, L as LunoraClient, a as Unsubscribe } from "../packem_shared/lunora-client.d-Bt65hm_E.js";
2
+ export type { b as SubscriptionErrorCallback } from "../packem_shared/lunora-client.d-Bt65hm_E.js";
3
3
  import '@lunora/runtime';
4
4
  /**
5
- * The sentinel a framework adapter resolves its reactive args to when it wants
6
- * to short-circuit a query — no network call, no socket.
7
- */
5
+ * The sentinel a framework adapter resolves its reactive args to when it wants
6
+ * to short-circuit a query — no network call, no socket.
7
+ */
8
8
  declare const SKIP: "skip";
9
9
  /** Args after a framework has resolved its reactivity primitive, or the skip sentinel. */
10
10
  type ResolvedArgs<F extends FunctionReference> = ArgsOf<F> | typeof SKIP;
11
11
  /**
12
- * The framework-neutral sinks a {@link createQuerySubscription} call drives. A
13
- * framework adapter supplies these, wiring each into its own reactivity
14
- * primitive (a TanStack cache write, a Vue `ref`, a Svelte store `set`, a Solid
15
- * signal setter).
16
- *
17
- * `onData` fires when a fresh server value lands (the initial frame or a delta).
18
- * `onError` fires when the subscription attach threw, or the server pushed a
19
- * subscription-scoped error — it is optional, and when omitted an attach throw
20
- * propagates to the caller (preserving the "no error channel" behaviour of
21
- * adapters like Solid/Vue that never had one) rather than being swallowed.
22
- * `onReset` fires when the resolved args are `"skip"`: clear any prior value.
23
- */
12
+ * The framework-neutral sinks a {@link createQuerySubscription} call drives. A
13
+ * framework adapter supplies these, wiring each into its own reactivity
14
+ * primitive (a TanStack cache write, a Vue `ref`, a Svelte store `set`, a Solid
15
+ * signal setter).
16
+ *
17
+ * `onData` fires when a fresh server value lands (the initial frame or a delta).
18
+ * `onError` fires when the subscription attach threw, or the server pushed a
19
+ * subscription-scoped error — it is optional, and when omitted an attach throw
20
+ * propagates to the caller (preserving the "no error channel" behaviour of
21
+ * adapters like Solid/Vue that never had one) rather than being swallowed.
22
+ * `onReset` fires when the resolved args are `"skip"`: clear any prior value.
23
+ */
24
24
  interface QuerySubscriptionSinks<T> {
25
25
  onData: (value: T) => void;
26
26
  onError?: (error: SubscriptionError) => void;
@@ -33,30 +33,30 @@ interface QuerySubscriptionOptions {
33
33
  /** Normalise an unknown thrown value into the client's {@link SubscriptionError} shape. */
34
34
  declare const toSubscriptionError: (error: unknown) => SubscriptionError;
35
35
  /**
36
- * The subscribe → snapshot → error/reset → cleanup state machine shared by
37
- * every Lunora framework adapter's live-query hook.
38
- *
39
- * Given a `client`, a function reference, the already-resolved `args` (a
40
- * framework reads its own reactive source first, then hands the plain value in),
41
- * and a set of {@link QuerySubscriptionSinks}, this opens one `client.subscribe`
42
- * registration and returns the {@link Unsubscribe} to tear it down. Each
43
- * framework owns *when* to call this (a React effect, a Vue `watch`, a Svelte
44
- * store start callback, a Solid `createEffect(on(...))`) and *where* to stash
45
- * the value — this owns the lifecycle in between, so the skip-handling, the
46
- * value/error fan-out, the attach-throw normalisation, and the
47
- * cancellation-guarded teardown live in exactly one place.
48
- *
49
- * Behaviour. When `args === "skip"` it calls `sinks.onReset?.()` and returns a
50
- * no-op teardown; no `client.subscribe` is issued. Otherwise it opens
51
- * `client.subscribe(fn, args, …, { shardKey, onError })`: server pushes route to
52
- * `sinks.onData`, and the client's own `onError` channel (a server-rejected
53
- * subscription) routes to `sinks.onError` when present. The attach is wrapped —
54
- * if `client.subscribe` itself throws, the error is normalised to a
55
- * {@link SubscriptionError} and delivered to `sinks.onError` when present; with
56
- * no `onError` sink the throw is rethrown so adapters without an error channel
57
- * behave exactly as before. The returned teardown is idempotent and
58
- * cancellation-guarded: once it runs, no further `onData`/`onError` from an
59
- * in-flight push reaches the sinks.
60
- */
36
+ * The subscribe → snapshot → error/reset → cleanup state machine shared by
37
+ * every Lunora framework adapter's live-query hook.
38
+ *
39
+ * Given a `client`, a function reference, the already-resolved `args` (a
40
+ * framework reads its own reactive source first, then hands the plain value in),
41
+ * and a set of {@link QuerySubscriptionSinks}, this opens one `client.subscribe`
42
+ * registration and returns the {@link Unsubscribe} to tear it down. Each
43
+ * framework owns *when* to call this (a React effect, a Vue `watch`, a Svelte
44
+ * store start callback, a Solid `createEffect(on(...))`) and *where* to stash
45
+ * the value — this owns the lifecycle in between, so the skip-handling, the
46
+ * value/error fan-out, the attach-throw normalisation, and the
47
+ * cancellation-guarded teardown live in exactly one place.
48
+ *
49
+ * Behaviour. When `args === "skip"` it calls `sinks.onReset?.()` and returns a
50
+ * no-op teardown; no `client.subscribe` is issued. Otherwise it opens
51
+ * `client.subscribe(fn, args, …, { shardKey, onError })`: server pushes route to
52
+ * `sinks.onData`, and the client's own `onError` channel (a server-rejected
53
+ * subscription) routes to `sinks.onError` when present. The attach is wrapped —
54
+ * if `client.subscribe` itself throws, the error is normalised to a
55
+ * {@link SubscriptionError} and delivered to `sinks.onError` when present; with
56
+ * no `onError` sink the throw is rethrown so adapters without an error channel
57
+ * behave exactly as before. The returned teardown is idempotent and
58
+ * cancellation-guarded: once it runs, no further `onData`/`onError` from an
59
+ * in-flight push reaches the sinks.
60
+ */
61
61
  declare const createQuerySubscription: <F extends FunctionReference, T = ReturnOf<F>>(client: LunoraClient, function_: F, args: ResolvedArgs<F>, sinks: QuerySubscriptionSinks<T>, options?: QuerySubscriptionOptions) => Unsubscribe;
62
62
  export { type ArgsOf, type FunctionReference, type QuerySubscriptionOptions, type QuerySubscriptionSinks, type ResolvedArgs, type ReturnOf, SKIP, type SubscriptionError, type Unsubscribe, createQuerySubscription, toSubscriptionError };
@@ -1 +1 @@
1
- export { SKIP, createQuerySubscription, toSubscriptionError } from '../packem_shared/SKIP-vItZChkw.mjs';
1
+ import{SKIP as t,createQuerySubscription as e,toSubscriptionError as i}from"../packem_shared/SKIP-CArzT3Vl.mjs";export{t as SKIP,e as createQuerySubscription,i as toSubscriptionError};