@lunora/client 1.0.0-alpha.39 → 1.0.0-alpha.40
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.
- package/dist/auth/index.d.mts +2 -2
- package/dist/auth/index.d.ts +2 -2
- package/dist/index.d.mts +5 -5
- package/dist/index.d.ts +5 -5
- package/dist/packem_shared/{lunora-client.d-BkfH0Zom.d.ts → lunora-client.d-B23myJYW.d.ts} +5 -5
- package/dist/packem_shared/{lunora-client.d-yDX6HUZv.d.mts → lunora-client.d-BRXKXo0T.d.mts} +5 -5
- package/dist/packem_shared/{preload.d-DbtqnQ4C.d.mts → preload.d-BgoF8JQZ.d.mts} +2 -2
- package/dist/packem_shared/{preload.d--OibiIK_.d.ts → preload.d-cq7evweX.d.ts} +2 -2
- package/dist/packem_shared/{types.d-CxmbJf0E.d.mts → types.d-CA7ZeJm9.d.mts} +5 -5
- package/dist/packem_shared/{types.d-CxmbJf0E.d.ts → types.d-CA7ZeJm9.d.ts} +5 -5
- package/dist/query/index.d.mts +3 -3
- package/dist/query/index.d.ts +3 -3
- package/dist/service.d.mts +1 -1
- package/dist/service.d.ts +1 -1
- package/dist/ssr/index.d.mts +10 -10
- package/dist/ssr/index.d.ts +10 -10
- package/package.json +2 -2
package/dist/auth/index.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { L as LunoraClient } from "../packem_shared/lunora-client.d-
|
|
2
|
-
import { U as User } from "../packem_shared/types.d-
|
|
1
|
+
import { L as LunoraClient } from "../packem_shared/lunora-client.d-BRXKXo0T.mjs";
|
|
2
|
+
import { U as User } from "../packem_shared/types.d-CA7ZeJm9.mjs";
|
|
3
3
|
import '@lunora/runtime';
|
|
4
4
|
interface IdentityStore {
|
|
5
5
|
/** Read the current resolved user, or `null` when signed out / not yet resolved. */
|
package/dist/auth/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { L as LunoraClient } from "../packem_shared/lunora-client.d-
|
|
2
|
-
import { U as User } from "../packem_shared/types.d-
|
|
1
|
+
import { L as LunoraClient } from "../packem_shared/lunora-client.d-B23myJYW.js";
|
|
2
|
+
import { U as User } from "../packem_shared/types.d-CA7ZeJm9.js";
|
|
3
3
|
import '@lunora/runtime';
|
|
4
4
|
interface IdentityStore {
|
|
5
5
|
/** Read the current resolved user, or `null` when signed out / not yet resolved. */
|
package/dist/index.d.mts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { o as PersistenceAdapter, B as BookmarkStorage, H as HttpStreamRef, m as HttpStreamArgsOf, n as HttpStreamChunkOf, F as FunctionReference, A as ArgsOf, R as ReturnOf, O as OfflineQueueOptions, Q as QueryCacheAdapter, p as ReconnectOptions } from "./packem_shared/types.d-
|
|
2
|
-
export type { C as CachedQuery, q as ClientMessage, r as ClientShapeSubscribeMessage, s as ClientShapeUnsubscribeMessage, t as FunctionArgumentDescriptor, h as FunctionDescriptor, l as GlobalFacetResult, u as GlobalFacetValue, j as GlobalFilterClause, G as GlobalTableInfo, k as GlobalTablePage, v as HttpStreamCallArgs, L as LunoraClientOptions, w as OutboxMutation, x as OutboxSink, y as PersistedMutation, P as Preloaded, z as RowOp, D as RpcEnvelope, E as RpcResponseBody, b as ScheduleRecord, I as SchedulerPoolStatus, c as SchedulerStatus, J as ServerMessage, K as ServerPokeEndMessage, M as ServerPokePartMessage, N as ServerPokeStartMessage, T as ShardTrafficEntry, S as ShardTrafficResult, i as StorageListPage, V as StorageObject, a as Unsubscribe, U as User, g as WorkflowInstanceAction, f as WorkflowInstanceDetail, e as WorkflowInstancePage, d as WorkflowInstanceStatus, X as WorkflowInstanceSummary, Y as WorkflowStepDetail, W as WsTokenProvider } from "./packem_shared/types.d-
|
|
3
|
-
import { C as ConnectionStatus, S as SubscriptionError, b as StreamIterable, M as MutationCallOptions, L as LunoraClient } from "./packem_shared/lunora-client.d-
|
|
4
|
-
export { type B as BatchSlot, c as CONFLICT_ERROR_CODE, type d as ClientDebugShard, type e as ClientDebugSnapshot, type f as ClientDebugSubscription, type g as ClientQueryRef, D as DEFAULT_MAX_BUFFER, type h as LunoraClientError, type i as LunoraErrorCode, type j as MutationSettledEvent, type O as OptimisticLocalStore, type k as OptimisticUpdate, type l as StreamHandle, type m as SubscriptionCallback, type a as SubscriptionErrorCallback, n as SubscriptionRegistry, type o as SubscriptionState, type p as SyncWatermark, q as createClientQuery, r as createLocalStore, s as createStream, t as getErrorCode, u as getRetryAfterMs, v as isConflictError, w as isForbiddenError, x as isRateLimitedError, y as isUnauthorizedError } from "./packem_shared/lunora-client.d-
|
|
5
|
-
export { p as preloadQuery, a as preloadedQueryResult } from "./packem_shared/preload.d-
|
|
1
|
+
import { o as PersistenceAdapter, B as BookmarkStorage, H as HttpStreamRef, m as HttpStreamArgsOf, n as HttpStreamChunkOf, F as FunctionReference, A as ArgsOf, R as ReturnOf, O as OfflineQueueOptions, Q as QueryCacheAdapter, p as ReconnectOptions } from "./packem_shared/types.d-CA7ZeJm9.mjs";
|
|
2
|
+
export type { C as CachedQuery, q as ClientMessage, r as ClientShapeSubscribeMessage, s as ClientShapeUnsubscribeMessage, t as FunctionArgumentDescriptor, h as FunctionDescriptor, l as GlobalFacetResult, u as GlobalFacetValue, j as GlobalFilterClause, G as GlobalTableInfo, k as GlobalTablePage, v as HttpStreamCallArgs, L as LunoraClientOptions, w as OutboxMutation, x as OutboxSink, y as PersistedMutation, P as Preloaded, z as RowOp, D as RpcEnvelope, E as RpcResponseBody, b as ScheduleRecord, I as SchedulerPoolStatus, c as SchedulerStatus, J as ServerMessage, K as ServerPokeEndMessage, M as ServerPokePartMessage, N as ServerPokeStartMessage, T as ShardTrafficEntry, S as ShardTrafficResult, i as StorageListPage, V as StorageObject, a as Unsubscribe, U as User, g as WorkflowInstanceAction, f as WorkflowInstanceDetail, e as WorkflowInstancePage, d as WorkflowInstanceStatus, X as WorkflowInstanceSummary, Y as WorkflowStepDetail, W as WsTokenProvider } from "./packem_shared/types.d-CA7ZeJm9.mjs";
|
|
3
|
+
import { C as ConnectionStatus, S as SubscriptionError, b as StreamIterable, M as MutationCallOptions, L as LunoraClient } from "./packem_shared/lunora-client.d-BRXKXo0T.mjs";
|
|
4
|
+
export { type B as BatchSlot, c as CONFLICT_ERROR_CODE, type d as ClientDebugShard, type e as ClientDebugSnapshot, type f as ClientDebugSubscription, type g as ClientQueryRef, D as DEFAULT_MAX_BUFFER, type h as LunoraClientError, type i as LunoraErrorCode, type j as MutationSettledEvent, type O as OptimisticLocalStore, type k as OptimisticUpdate, type l as StreamHandle, type m as SubscriptionCallback, type a as SubscriptionErrorCallback, n as SubscriptionRegistry, type o as SubscriptionState, type p as SyncWatermark, q as createClientQuery, r as createLocalStore, s as createStream, t as getErrorCode, u as getRetryAfterMs, v as isConflictError, w as isForbiddenError, x as isRateLimitedError, y as isUnauthorizedError } from "./packem_shared/lunora-client.d-BRXKXo0T.mjs";
|
|
5
|
+
export { p as preloadQuery, a as preloadedQueryResult } from "./packem_shared/preload.d-BgoF8JQZ.mjs";
|
|
6
6
|
export type { AuthCapabilities, AuthConfigInfo, AuthImpersonation, AuthPage, AuthSession, AuthUser, AuthUserFieldSpec, CronJobInfo, KvKeyEntry, KvKeyListResult, KvNamespaceSummary, KvValueResult, PipelineLogColumnMap, PipelineLogCursor, PipelineLogField, PipelineLogPage, PipelineLogQuery, PipelineLogRow, VectorIndexSummary, VectorQueryMatch } from '@lunora/runtime';
|
|
7
7
|
declare const anyApi: Record<string, Record<string, unknown>>;
|
|
8
8
|
/**
|
package/dist/index.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { o as PersistenceAdapter, B as BookmarkStorage, H as HttpStreamRef, m as HttpStreamArgsOf, n as HttpStreamChunkOf, F as FunctionReference, A as ArgsOf, R as ReturnOf, O as OfflineQueueOptions, Q as QueryCacheAdapter, p as ReconnectOptions } from "./packem_shared/types.d-
|
|
2
|
-
export type { C as CachedQuery, q as ClientMessage, r as ClientShapeSubscribeMessage, s as ClientShapeUnsubscribeMessage, t as FunctionArgumentDescriptor, h as FunctionDescriptor, l as GlobalFacetResult, u as GlobalFacetValue, j as GlobalFilterClause, G as GlobalTableInfo, k as GlobalTablePage, v as HttpStreamCallArgs, L as LunoraClientOptions, w as OutboxMutation, x as OutboxSink, y as PersistedMutation, P as Preloaded, z as RowOp, D as RpcEnvelope, E as RpcResponseBody, b as ScheduleRecord, I as SchedulerPoolStatus, c as SchedulerStatus, J as ServerMessage, K as ServerPokeEndMessage, M as ServerPokePartMessage, N as ServerPokeStartMessage, T as ShardTrafficEntry, S as ShardTrafficResult, i as StorageListPage, V as StorageObject, a as Unsubscribe, U as User, g as WorkflowInstanceAction, f as WorkflowInstanceDetail, e as WorkflowInstancePage, d as WorkflowInstanceStatus, X as WorkflowInstanceSummary, Y as WorkflowStepDetail, W as WsTokenProvider } from "./packem_shared/types.d-
|
|
3
|
-
import { C as ConnectionStatus, S as SubscriptionError, b as StreamIterable, M as MutationCallOptions, L as LunoraClient } from "./packem_shared/lunora-client.d-
|
|
4
|
-
export { type B as BatchSlot, c as CONFLICT_ERROR_CODE, type d as ClientDebugShard, type e as ClientDebugSnapshot, type f as ClientDebugSubscription, type g as ClientQueryRef, D as DEFAULT_MAX_BUFFER, type h as LunoraClientError, type i as LunoraErrorCode, type j as MutationSettledEvent, type O as OptimisticLocalStore, type k as OptimisticUpdate, type l as StreamHandle, type m as SubscriptionCallback, type a as SubscriptionErrorCallback, n as SubscriptionRegistry, type o as SubscriptionState, type p as SyncWatermark, q as createClientQuery, r as createLocalStore, s as createStream, t as getErrorCode, u as getRetryAfterMs, v as isConflictError, w as isForbiddenError, x as isRateLimitedError, y as isUnauthorizedError } from "./packem_shared/lunora-client.d-
|
|
5
|
-
export { p as preloadQuery, a as preloadedQueryResult } from "./packem_shared/preload.d
|
|
1
|
+
import { o as PersistenceAdapter, B as BookmarkStorage, H as HttpStreamRef, m as HttpStreamArgsOf, n as HttpStreamChunkOf, F as FunctionReference, A as ArgsOf, R as ReturnOf, O as OfflineQueueOptions, Q as QueryCacheAdapter, p as ReconnectOptions } from "./packem_shared/types.d-CA7ZeJm9.js";
|
|
2
|
+
export type { C as CachedQuery, q as ClientMessage, r as ClientShapeSubscribeMessage, s as ClientShapeUnsubscribeMessage, t as FunctionArgumentDescriptor, h as FunctionDescriptor, l as GlobalFacetResult, u as GlobalFacetValue, j as GlobalFilterClause, G as GlobalTableInfo, k as GlobalTablePage, v as HttpStreamCallArgs, L as LunoraClientOptions, w as OutboxMutation, x as OutboxSink, y as PersistedMutation, P as Preloaded, z as RowOp, D as RpcEnvelope, E as RpcResponseBody, b as ScheduleRecord, I as SchedulerPoolStatus, c as SchedulerStatus, J as ServerMessage, K as ServerPokeEndMessage, M as ServerPokePartMessage, N as ServerPokeStartMessage, T as ShardTrafficEntry, S as ShardTrafficResult, i as StorageListPage, V as StorageObject, a as Unsubscribe, U as User, g as WorkflowInstanceAction, f as WorkflowInstanceDetail, e as WorkflowInstancePage, d as WorkflowInstanceStatus, X as WorkflowInstanceSummary, Y as WorkflowStepDetail, W as WsTokenProvider } from "./packem_shared/types.d-CA7ZeJm9.js";
|
|
3
|
+
import { C as ConnectionStatus, S as SubscriptionError, b as StreamIterable, M as MutationCallOptions, L as LunoraClient } from "./packem_shared/lunora-client.d-B23myJYW.js";
|
|
4
|
+
export { type B as BatchSlot, c as CONFLICT_ERROR_CODE, type d as ClientDebugShard, type e as ClientDebugSnapshot, type f as ClientDebugSubscription, type g as ClientQueryRef, D as DEFAULT_MAX_BUFFER, type h as LunoraClientError, type i as LunoraErrorCode, type j as MutationSettledEvent, type O as OptimisticLocalStore, type k as OptimisticUpdate, type l as StreamHandle, type m as SubscriptionCallback, type a as SubscriptionErrorCallback, n as SubscriptionRegistry, type o as SubscriptionState, type p as SyncWatermark, q as createClientQuery, r as createLocalStore, s as createStream, t as getErrorCode, u as getRetryAfterMs, v as isConflictError, w as isForbiddenError, x as isRateLimitedError, y as isUnauthorizedError } from "./packem_shared/lunora-client.d-B23myJYW.js";
|
|
5
|
+
export { p as preloadQuery, a as preloadedQueryResult } from "./packem_shared/preload.d-cq7evweX.js";
|
|
6
6
|
export type { AuthCapabilities, AuthConfigInfo, AuthImpersonation, AuthPage, AuthSession, AuthUser, AuthUserFieldSpec, CronJobInfo, KvKeyEntry, KvKeyListResult, KvNamespaceSummary, KvValueResult, PipelineLogColumnMap, PipelineLogCursor, PipelineLogField, PipelineLogPage, PipelineLogQuery, PipelineLogRow, VectorIndexSummary, VectorQueryMatch } from '@lunora/runtime';
|
|
7
7
|
declare const anyApi: Record<string, Record<string, unknown>>;
|
|
8
8
|
/**
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { F as FunctionReference, A as ArgsOf, R as ReturnOf, L as LunoraClientOptions, a as Unsubscribe, U as User, W as WsTokenProvider, S as ShardTrafficResult, b as ScheduleRecord, c as SchedulerStatus, d as WorkflowInstanceStatus, e as WorkflowInstancePage, f as WorkflowInstanceDetail, g as WorkflowInstanceAction, h as FunctionDescriptor, i as StorageListPage, G as GlobalTableInfo, j as GlobalFilterClause, k as GlobalTablePage, l as GlobalFacetResult, H as HttpStreamRef, m as HttpStreamArgsOf, n as HttpStreamChunkOf } from "./types.d-
|
|
1
|
+
import { F as FunctionReference, A as ArgsOf, R as ReturnOf, L as LunoraClientOptions, a as Unsubscribe, U as User, W as WsTokenProvider, S as ShardTrafficResult, b as ScheduleRecord, c as SchedulerStatus, d as WorkflowInstanceStatus, e as WorkflowInstancePage, f as WorkflowInstanceDetail, g as WorkflowInstanceAction, h as FunctionDescriptor, i as StorageListPage, G as GlobalTableInfo, j as GlobalFilterClause, k as GlobalTablePage, l as GlobalFacetResult, H as HttpStreamRef, m as HttpStreamArgsOf, n as HttpStreamChunkOf } from "./types.d-CA7ZeJm9.js";
|
|
2
2
|
import { CronJobInfo, VectorIndexSummary, VectorQueryMatch, PipelineLogQuery, PipelineLogPage, KvNamespaceSummary, KvKeyListResult, KvValueResult, AuthUser, AuthPage, AuthImpersonation, AuthCapabilities, AuthConfigInfo, AuthSession } from '@lunora/runtime';
|
|
3
3
|
/**
|
|
4
4
|
* Reactive key-value store for local-only client state.
|
|
@@ -322,7 +322,7 @@ interface ClientDebugShard {
|
|
|
322
322
|
interface ClientDebugSubscription {
|
|
323
323
|
/** Whether the server has acknowledged the subscription on the current socket. */
|
|
324
324
|
acked: boolean;
|
|
325
|
-
/** `namespace:fn` for a query, `shape
|
|
325
|
+
/** `namespace:fn` for a query, `shape:<name>` for a replication shape. */
|
|
326
326
|
functionPath: string;
|
|
327
327
|
id: string;
|
|
328
328
|
kind: "query" | "shape";
|
|
@@ -376,7 +376,7 @@ interface MutationSettledEvent {
|
|
|
376
376
|
readonly code?: string;
|
|
377
377
|
/** The rejection error on `status: "rejected"`. */
|
|
378
378
|
readonly error?: unknown;
|
|
379
|
-
/** The
|
|
379
|
+
/** The `<file>:<function>` reference of the mutation. */
|
|
380
380
|
readonly functionPath: string;
|
|
381
381
|
/** Whether a live caller was still awaiting this write's `mutation()` Promise. */
|
|
382
382
|
readonly hadAwaiter: boolean;
|
|
@@ -1694,7 +1694,7 @@ declare class LunoraClient {
|
|
|
1694
1694
|
shardKey?: string;
|
|
1695
1695
|
}): StreamIterable<ReturnOf<F>>;
|
|
1696
1696
|
/**
|
|
1697
|
-
* Open a typed **HTTP-SSE route stream** (`httpRoute
|
|
1697
|
+
* Open a typed **HTTP-SSE route stream** (`httpRoute.<verb>(path).stream()`).
|
|
1698
1698
|
* Distinct from {@link LunoraClient.stream}, which consumes the WS procedure
|
|
1699
1699
|
* stream (`kind: "stream"`): this one opens the route's own URL with `fetch`
|
|
1700
1700
|
* and parses the Server-Sent Events framing the route pump writes (`data:`
|
|
@@ -2028,7 +2028,7 @@ declare class LunoraClient {
|
|
|
2028
2028
|
*/
|
|
2029
2029
|
private identityFingerprint;
|
|
2030
2030
|
/**
|
|
2031
|
-
* Stable token-hash fingerprint of a bearer token (the
|
|
2031
|
+
* Stable token-hash fingerprint of a bearer token (the `<len>:<fnv>:<djb2>`
|
|
2032
2032
|
* format a token-stamped queued write carries). Extracted so the replay gate
|
|
2033
2033
|
* can recompute the hash of the current credential and recognise a write
|
|
2034
2034
|
* stamped under it — even after the fingerprint was relabelled to a subject.
|
package/dist/packem_shared/{lunora-client.d-yDX6HUZv.d.mts → lunora-client.d-BRXKXo0T.d.mts}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { F as FunctionReference, A as ArgsOf, R as ReturnOf, L as LunoraClientOptions, a as Unsubscribe, U as User, W as WsTokenProvider, S as ShardTrafficResult, b as ScheduleRecord, c as SchedulerStatus, d as WorkflowInstanceStatus, e as WorkflowInstancePage, f as WorkflowInstanceDetail, g as WorkflowInstanceAction, h as FunctionDescriptor, i as StorageListPage, G as GlobalTableInfo, j as GlobalFilterClause, k as GlobalTablePage, l as GlobalFacetResult, H as HttpStreamRef, m as HttpStreamArgsOf, n as HttpStreamChunkOf } from "./types.d-
|
|
1
|
+
import { F as FunctionReference, A as ArgsOf, R as ReturnOf, L as LunoraClientOptions, a as Unsubscribe, U as User, W as WsTokenProvider, S as ShardTrafficResult, b as ScheduleRecord, c as SchedulerStatus, d as WorkflowInstanceStatus, e as WorkflowInstancePage, f as WorkflowInstanceDetail, g as WorkflowInstanceAction, h as FunctionDescriptor, i as StorageListPage, G as GlobalTableInfo, j as GlobalFilterClause, k as GlobalTablePage, l as GlobalFacetResult, H as HttpStreamRef, m as HttpStreamArgsOf, n as HttpStreamChunkOf } from "./types.d-CA7ZeJm9.mjs";
|
|
2
2
|
import { CronJobInfo, VectorIndexSummary, VectorQueryMatch, PipelineLogQuery, PipelineLogPage, KvNamespaceSummary, KvKeyListResult, KvValueResult, AuthUser, AuthPage, AuthImpersonation, AuthCapabilities, AuthConfigInfo, AuthSession } from '@lunora/runtime';
|
|
3
3
|
/**
|
|
4
4
|
* Reactive key-value store for local-only client state.
|
|
@@ -322,7 +322,7 @@ interface ClientDebugShard {
|
|
|
322
322
|
interface ClientDebugSubscription {
|
|
323
323
|
/** Whether the server has acknowledged the subscription on the current socket. */
|
|
324
324
|
acked: boolean;
|
|
325
|
-
/** `namespace:fn` for a query, `shape
|
|
325
|
+
/** `namespace:fn` for a query, `shape:<name>` for a replication shape. */
|
|
326
326
|
functionPath: string;
|
|
327
327
|
id: string;
|
|
328
328
|
kind: "query" | "shape";
|
|
@@ -376,7 +376,7 @@ interface MutationSettledEvent {
|
|
|
376
376
|
readonly code?: string;
|
|
377
377
|
/** The rejection error on `status: "rejected"`. */
|
|
378
378
|
readonly error?: unknown;
|
|
379
|
-
/** The
|
|
379
|
+
/** The `<file>:<function>` reference of the mutation. */
|
|
380
380
|
readonly functionPath: string;
|
|
381
381
|
/** Whether a live caller was still awaiting this write's `mutation()` Promise. */
|
|
382
382
|
readonly hadAwaiter: boolean;
|
|
@@ -1694,7 +1694,7 @@ declare class LunoraClient {
|
|
|
1694
1694
|
shardKey?: string;
|
|
1695
1695
|
}): StreamIterable<ReturnOf<F>>;
|
|
1696
1696
|
/**
|
|
1697
|
-
* Open a typed **HTTP-SSE route stream** (`httpRoute
|
|
1697
|
+
* Open a typed **HTTP-SSE route stream** (`httpRoute.<verb>(path).stream()`).
|
|
1698
1698
|
* Distinct from {@link LunoraClient.stream}, which consumes the WS procedure
|
|
1699
1699
|
* stream (`kind: "stream"`): this one opens the route's own URL with `fetch`
|
|
1700
1700
|
* and parses the Server-Sent Events framing the route pump writes (`data:`
|
|
@@ -2028,7 +2028,7 @@ declare class LunoraClient {
|
|
|
2028
2028
|
*/
|
|
2029
2029
|
private identityFingerprint;
|
|
2030
2030
|
/**
|
|
2031
|
-
* Stable token-hash fingerprint of a bearer token (the
|
|
2031
|
+
* Stable token-hash fingerprint of a bearer token (the `<len>:<fnv>:<djb2>`
|
|
2032
2032
|
* format a token-stamped queued write carries). Extracted so the replay gate
|
|
2033
2033
|
* can recompute the hash of the current credential and recognise a write
|
|
2034
2034
|
* stamped under it — even after the fingerprint was relabelled to a subject.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { L as LunoraClient } from "./lunora-client.d-
|
|
2
|
-
import { F as FunctionReference, A as ArgsOf, R as ReturnOf, P as Preloaded } from "./types.d-
|
|
1
|
+
import { L as LunoraClient } from "./lunora-client.d-BRXKXo0T.mjs";
|
|
2
|
+
import { F as FunctionReference, A as ArgsOf, R as ReturnOf, P as Preloaded } from "./types.d-CA7ZeJm9.mjs";
|
|
3
3
|
/**
|
|
4
4
|
* Run a query once on the server (during SSR) and capture its result in a
|
|
5
5
|
* serializable {@link Preloaded} token. Embed the token in the rendered HTML and
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { L as LunoraClient } from "./lunora-client.d-
|
|
2
|
-
import { F as FunctionReference, A as ArgsOf, R as ReturnOf, P as Preloaded } from "./types.d-
|
|
1
|
+
import { L as LunoraClient } from "./lunora-client.d-B23myJYW.js";
|
|
2
|
+
import { F as FunctionReference, A as ArgsOf, R as ReturnOf, P as Preloaded } from "./types.d-CA7ZeJm9.js";
|
|
3
3
|
/**
|
|
4
4
|
* Run a query once on the server (during SSR) and capture its result in a
|
|
5
5
|
* serializable {@link Preloaded} token. Embed the token in the rendered HTML and
|
|
@@ -3,7 +3,7 @@ type FunctionKind = "action" | "mutation" | "query" | "stream";
|
|
|
3
3
|
/**
|
|
4
4
|
* Opaque reference to a registered function emitted by `@lunora/codegen`.
|
|
5
5
|
*
|
|
6
|
-
* At runtime it carries the
|
|
6
|
+
* At runtime it carries the `<file>:<function>` identifier in `__lunoraRef`.
|
|
7
7
|
* Generated declarations decorate this with phantom type parameters so the
|
|
8
8
|
* client can infer args / return values per call site.
|
|
9
9
|
*/
|
|
@@ -25,8 +25,8 @@ type ArgsOf<F> = F extends FunctionReference<infer _K, infer A, infer _R> ? A :
|
|
|
25
25
|
/** Extract the return type from a {@link FunctionReference}. */
|
|
26
26
|
type ReturnOf<F> = F extends FunctionReference<infer _K, infer _A, infer R> ? R : never;
|
|
27
27
|
/**
|
|
28
|
-
* Typed reference to an HTTP-SSE stream route (`httpRoute
|
|
29
|
-
* emitted by `@lunora/codegen` as `httpStreams
|
|
28
|
+
* Typed reference to an HTTP-SSE stream route (`httpRoute.<verb>(path).stream()`)
|
|
29
|
+
* emitted by `@lunora/codegen` as `httpStreams.<namespace>.<name>`.
|
|
30
30
|
*
|
|
31
31
|
* Distinct from {@link FunctionReference}: this is the **HTTP-SSE route stream**
|
|
32
32
|
* (opened with `fetch` + `ReadableStream` against the route's own URL), not the
|
|
@@ -421,7 +421,7 @@ interface RpcEnvelope {
|
|
|
421
421
|
idempotencyKey?: string;
|
|
422
422
|
/**
|
|
423
423
|
* Monotonic per-client mutation id (custom-mutator push path), backing the
|
|
424
|
-
* server-side per-client watermark: `id
|
|
424
|
+
* server-side per-client watermark: `id <= watermark` is a replay (skipped),
|
|
425
425
|
* `id == watermark + 1` runs authoritatively, `id > watermark + 1` halts the
|
|
426
426
|
* batch so the client resends from `watermark + 1`. Absent on plain
|
|
427
427
|
* `client.mutation` calls.
|
|
@@ -850,7 +850,7 @@ interface FunctionArgumentDescriptor {
|
|
|
850
850
|
}
|
|
851
851
|
/**
|
|
852
852
|
* One registered function, as returned by the worker's
|
|
853
|
-
* `GET /_lunora/admin/functions` endpoint: its
|
|
853
|
+
* `GET /_lunora/admin/functions` endpoint: its `<file>:<function>` path, which
|
|
854
854
|
* client method (`query` / `mutation` / `action`) invokes it, and its argument
|
|
855
855
|
* signature. `args` is absent on responses from an older worker.
|
|
856
856
|
*/
|
|
@@ -3,7 +3,7 @@ type FunctionKind = "action" | "mutation" | "query" | "stream";
|
|
|
3
3
|
/**
|
|
4
4
|
* Opaque reference to a registered function emitted by `@lunora/codegen`.
|
|
5
5
|
*
|
|
6
|
-
* At runtime it carries the
|
|
6
|
+
* At runtime it carries the `<file>:<function>` identifier in `__lunoraRef`.
|
|
7
7
|
* Generated declarations decorate this with phantom type parameters so the
|
|
8
8
|
* client can infer args / return values per call site.
|
|
9
9
|
*/
|
|
@@ -25,8 +25,8 @@ type ArgsOf<F> = F extends FunctionReference<infer _K, infer A, infer _R> ? A :
|
|
|
25
25
|
/** Extract the return type from a {@link FunctionReference}. */
|
|
26
26
|
type ReturnOf<F> = F extends FunctionReference<infer _K, infer _A, infer R> ? R : never;
|
|
27
27
|
/**
|
|
28
|
-
* Typed reference to an HTTP-SSE stream route (`httpRoute
|
|
29
|
-
* emitted by `@lunora/codegen` as `httpStreams
|
|
28
|
+
* Typed reference to an HTTP-SSE stream route (`httpRoute.<verb>(path).stream()`)
|
|
29
|
+
* emitted by `@lunora/codegen` as `httpStreams.<namespace>.<name>`.
|
|
30
30
|
*
|
|
31
31
|
* Distinct from {@link FunctionReference}: this is the **HTTP-SSE route stream**
|
|
32
32
|
* (opened with `fetch` + `ReadableStream` against the route's own URL), not the
|
|
@@ -421,7 +421,7 @@ interface RpcEnvelope {
|
|
|
421
421
|
idempotencyKey?: string;
|
|
422
422
|
/**
|
|
423
423
|
* Monotonic per-client mutation id (custom-mutator push path), backing the
|
|
424
|
-
* server-side per-client watermark: `id
|
|
424
|
+
* server-side per-client watermark: `id <= watermark` is a replay (skipped),
|
|
425
425
|
* `id == watermark + 1` runs authoritatively, `id > watermark + 1` halts the
|
|
426
426
|
* batch so the client resends from `watermark + 1`. Absent on plain
|
|
427
427
|
* `client.mutation` calls.
|
|
@@ -850,7 +850,7 @@ interface FunctionArgumentDescriptor {
|
|
|
850
850
|
}
|
|
851
851
|
/**
|
|
852
852
|
* One registered function, as returned by the worker's
|
|
853
|
-
* `GET /_lunora/admin/functions` endpoint: its
|
|
853
|
+
* `GET /_lunora/admin/functions` endpoint: its `<file>:<function>` path, which
|
|
854
854
|
* client method (`query` / `mutation` / `action`) invokes it, and its argument
|
|
855
855
|
* signature. `args` is absent on responses from an older worker.
|
|
856
856
|
*/
|
package/dist/query/index.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { F as FunctionReference, A as ArgsOf, R as ReturnOf, a as Unsubscribe } from "../packem_shared/types.d-
|
|
2
|
-
import { S as SubscriptionError, L as LunoraClient } from "../packem_shared/lunora-client.d-
|
|
3
|
-
export type { a as SubscriptionErrorCallback } from "../packem_shared/lunora-client.d-
|
|
1
|
+
import { F as FunctionReference, A as ArgsOf, R as ReturnOf, a as Unsubscribe } from "../packem_shared/types.d-CA7ZeJm9.mjs";
|
|
2
|
+
import { S as SubscriptionError, L as LunoraClient } from "../packem_shared/lunora-client.d-BRXKXo0T.mjs";
|
|
3
|
+
export type { a as SubscriptionErrorCallback } from "../packem_shared/lunora-client.d-BRXKXo0T.mjs";
|
|
4
4
|
import '@lunora/runtime';
|
|
5
5
|
/**
|
|
6
6
|
* The sentinel a framework adapter resolves its reactive args to when it wants
|
package/dist/query/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { F as FunctionReference, A as ArgsOf, R as ReturnOf, a as Unsubscribe } from "../packem_shared/types.d-
|
|
2
|
-
import { S as SubscriptionError, L as LunoraClient } from "../packem_shared/lunora-client.d-
|
|
3
|
-
export type { a as SubscriptionErrorCallback } from "../packem_shared/lunora-client.d-
|
|
1
|
+
import { F as FunctionReference, A as ArgsOf, R as ReturnOf, a as Unsubscribe } from "../packem_shared/types.d-CA7ZeJm9.js";
|
|
2
|
+
import { S as SubscriptionError, L as LunoraClient } from "../packem_shared/lunora-client.d-B23myJYW.js";
|
|
3
|
+
export type { a as SubscriptionErrorCallback } from "../packem_shared/lunora-client.d-B23myJYW.js";
|
|
4
4
|
import '@lunora/runtime';
|
|
5
5
|
/**
|
|
6
6
|
* The sentinel a framework adapter resolves its reactive args to when it wants
|
package/dist/service.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { F as FunctionReference, A as ArgsOf, R as ReturnOf } from "./packem_shared/types.d-
|
|
1
|
+
import { F as FunctionReference, A as ArgsOf, R as ReturnOf } from "./packem_shared/types.d-CA7ZeJm9.mjs";
|
|
2
2
|
/**
|
|
3
3
|
* The wire endpoint every Lunora Worker serves. Matches `createWorker`'s RPC
|
|
4
4
|
* route; the envelope shape below is that route's documented contract.
|
package/dist/service.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { F as FunctionReference, A as ArgsOf, R as ReturnOf } from "./packem_shared/types.d-
|
|
1
|
+
import { F as FunctionReference, A as ArgsOf, R as ReturnOf } from "./packem_shared/types.d-CA7ZeJm9.js";
|
|
2
2
|
/**
|
|
3
3
|
* The wire endpoint every Lunora Worker serves. Matches `createWorker`'s RPC
|
|
4
4
|
* route; the envelope shape below is that route's documented contract.
|
package/dist/ssr/index.d.mts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { P as Preloaded } from "../packem_shared/types.d-
|
|
2
|
-
export type { A as ArgsOf, F as FunctionReference, R as ReturnOf } from "../packem_shared/types.d-
|
|
3
|
-
export { p as preloadQuery, a as preloadedQueryResult } from "../packem_shared/preload.d-
|
|
4
|
-
import { L as LunoraClient } from "../packem_shared/lunora-client.d-
|
|
1
|
+
import { P as Preloaded } from "../packem_shared/types.d-CA7ZeJm9.mjs";
|
|
2
|
+
export type { A as ArgsOf, F as FunctionReference, R as ReturnOf } from "../packem_shared/types.d-CA7ZeJm9.mjs";
|
|
3
|
+
export { p as preloadQuery, a as preloadedQueryResult } from "../packem_shared/preload.d-BgoF8JQZ.mjs";
|
|
4
|
+
import { L as LunoraClient } from "../packem_shared/lunora-client.d-BRXKXo0T.mjs";
|
|
5
5
|
import '@lunora/runtime';
|
|
6
6
|
/**
|
|
7
7
|
* Structural shape of a better-auth `getSession` call's resolved value.
|
|
@@ -56,24 +56,24 @@ type HeadersSource = Headers | Request | {
|
|
|
56
56
|
declare const getServerSession: <Result>(request: HeadersSource, auth: AuthLike<Result>) => Promise<NonNullable<Result> | null>;
|
|
57
57
|
/**
|
|
58
58
|
* Serialize a {@link Preloaded} token to a JSON string for embedding in the
|
|
59
|
-
* rendered HTML (e.g. a
|
|
59
|
+
* rendered HTML (e.g. a `<script>` payload the client
|
|
60
60
|
* reads on hydration). Every field of `Preloaded` is JSON-serializable by
|
|
61
61
|
* construction — `preloadQuery` only captures the query args, function path,
|
|
62
62
|
* optional shard key, and the resolved value — so this is a thin, explicit
|
|
63
63
|
* `JSON.stringify` that documents the dehydration seam and keeps callers from
|
|
64
64
|
* accidentally stringifying a non-serializable wrapper.
|
|
65
65
|
*
|
|
66
|
-
* The
|
|
67
|
-
*
|
|
66
|
+
* The `<` is escaped to `<` so the payload is safe to inline inside a
|
|
67
|
+
* `<script>` tag without a stray `<\/script>` (or `<!--`) prematurely closing
|
|
68
68
|
* it — the standard XSS-safe script-embedding precaution. This escaping is NOT
|
|
69
|
-
* sufficient for an HTML *attribute* sink (which also needs the quote and
|
|
69
|
+
* sufficient for an HTML *attribute* sink (which also needs the quote and `&`
|
|
70
70
|
* characters escaped); embed the output in a raw-text script element, not a
|
|
71
71
|
* data attribute.
|
|
72
72
|
*/
|
|
73
73
|
declare const serializePreloaded: <T>(preloaded: Preloaded<T>) => string;
|
|
74
74
|
/**
|
|
75
75
|
* Inverse of {@link serializePreloaded}: parse a serialized token back into a
|
|
76
|
-
* {@link Preloaded} value on the client. The
|
|
76
|
+
* {@link Preloaded} value on the client. The `<` escape from serialization
|
|
77
77
|
* is transparent to `JSON.parse`, so no un-escaping step is needed.
|
|
78
78
|
*/
|
|
79
79
|
declare const deserializePreloaded: <T = unknown>(serialized: string) => Preloaded<T>;
|
|
@@ -87,7 +87,7 @@ interface ServerClientOptions {
|
|
|
87
87
|
*/
|
|
88
88
|
fetch?: typeof fetch;
|
|
89
89
|
/**
|
|
90
|
-
* Bearer token sent as `Authorization: Bearer
|
|
90
|
+
* Bearer token sent as `Authorization: Bearer <token>` on every RPC. In an
|
|
91
91
|
* SSR loader you typically read this from the request (e.g. the session
|
|
92
92
|
* resolved by `getServerSession`) and pass it here so the server-side
|
|
93
93
|
* load runs as the signed-in user — and so the client subscription that
|
package/dist/ssr/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { P as Preloaded } from "../packem_shared/types.d-
|
|
2
|
-
export type { A as ArgsOf, F as FunctionReference, R as ReturnOf } from "../packem_shared/types.d-
|
|
3
|
-
export { p as preloadQuery, a as preloadedQueryResult } from "../packem_shared/preload.d
|
|
4
|
-
import { L as LunoraClient } from "../packem_shared/lunora-client.d-
|
|
1
|
+
import { P as Preloaded } from "../packem_shared/types.d-CA7ZeJm9.js";
|
|
2
|
+
export type { A as ArgsOf, F as FunctionReference, R as ReturnOf } from "../packem_shared/types.d-CA7ZeJm9.js";
|
|
3
|
+
export { p as preloadQuery, a as preloadedQueryResult } from "../packem_shared/preload.d-cq7evweX.js";
|
|
4
|
+
import { L as LunoraClient } from "../packem_shared/lunora-client.d-B23myJYW.js";
|
|
5
5
|
import '@lunora/runtime';
|
|
6
6
|
/**
|
|
7
7
|
* Structural shape of a better-auth `getSession` call's resolved value.
|
|
@@ -56,24 +56,24 @@ type HeadersSource = Headers | Request | {
|
|
|
56
56
|
declare const getServerSession: <Result>(request: HeadersSource, auth: AuthLike<Result>) => Promise<NonNullable<Result> | null>;
|
|
57
57
|
/**
|
|
58
58
|
* Serialize a {@link Preloaded} token to a JSON string for embedding in the
|
|
59
|
-
* rendered HTML (e.g. a
|
|
59
|
+
* rendered HTML (e.g. a `<script>` payload the client
|
|
60
60
|
* reads on hydration). Every field of `Preloaded` is JSON-serializable by
|
|
61
61
|
* construction — `preloadQuery` only captures the query args, function path,
|
|
62
62
|
* optional shard key, and the resolved value — so this is a thin, explicit
|
|
63
63
|
* `JSON.stringify` that documents the dehydration seam and keeps callers from
|
|
64
64
|
* accidentally stringifying a non-serializable wrapper.
|
|
65
65
|
*
|
|
66
|
-
* The
|
|
67
|
-
*
|
|
66
|
+
* The `<` is escaped to `<` so the payload is safe to inline inside a
|
|
67
|
+
* `<script>` tag without a stray `<\/script>` (or `<!--`) prematurely closing
|
|
68
68
|
* it — the standard XSS-safe script-embedding precaution. This escaping is NOT
|
|
69
|
-
* sufficient for an HTML *attribute* sink (which also needs the quote and
|
|
69
|
+
* sufficient for an HTML *attribute* sink (which also needs the quote and `&`
|
|
70
70
|
* characters escaped); embed the output in a raw-text script element, not a
|
|
71
71
|
* data attribute.
|
|
72
72
|
*/
|
|
73
73
|
declare const serializePreloaded: <T>(preloaded: Preloaded<T>) => string;
|
|
74
74
|
/**
|
|
75
75
|
* Inverse of {@link serializePreloaded}: parse a serialized token back into a
|
|
76
|
-
* {@link Preloaded} value on the client. The
|
|
76
|
+
* {@link Preloaded} value on the client. The `<` escape from serialization
|
|
77
77
|
* is transparent to `JSON.parse`, so no un-escaping step is needed.
|
|
78
78
|
*/
|
|
79
79
|
declare const deserializePreloaded: <T = unknown>(serialized: string) => Preloaded<T>;
|
|
@@ -87,7 +87,7 @@ interface ServerClientOptions {
|
|
|
87
87
|
*/
|
|
88
88
|
fetch?: typeof fetch;
|
|
89
89
|
/**
|
|
90
|
-
* Bearer token sent as `Authorization: Bearer
|
|
90
|
+
* Bearer token sent as `Authorization: Bearer <token>` on every RPC. In an
|
|
91
91
|
* SSR loader you typically read this from the request (e.g. the session
|
|
92
92
|
* resolved by `getServerSession`) and pass it here so the server-side
|
|
93
93
|
* load runs as the signed-in user — and so the client subscription that
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lunora/client",
|
|
3
|
-
"version": "1.0.0-alpha.
|
|
3
|
+
"version": "1.0.0-alpha.40",
|
|
4
4
|
"description": "Lunora browser SDK: WebSocket transport, optimistic updates, and an offline mutation queue",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"cloudflare",
|
|
@@ -70,7 +70,7 @@
|
|
|
70
70
|
"access": "public"
|
|
71
71
|
},
|
|
72
72
|
"dependencies": {
|
|
73
|
-
"@lunora/errors": "1.0.0-alpha.
|
|
73
|
+
"@lunora/errors": "1.0.0-alpha.14",
|
|
74
74
|
"@visulima/storage-client": "1.0.0"
|
|
75
75
|
},
|
|
76
76
|
"engines": {
|