@powerhousedao/reactor-browser 6.2.3-dev.60 → 6.2.3-dev.62
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/{attachment-service-DG6UkyMv.d.ts → attachment-service-CQ3JygJd.d.ts} +3 -3
- package/dist/{attachment-service-DG6UkyMv.d.ts.map → attachment-service-CQ3JygJd.d.ts.map} +1 -1
- package/dist/{client-Cq5avLW5.js → client-Bwiji4R6.js} +6 -2
- package/dist/client-Bwiji4R6.js.map +1 -0
- package/dist/{dispatch-C1VVTn5S.js → dispatch-BmdzdTwb.js} +15 -11
- package/dist/dispatch-BmdzdTwb.js.map +1 -0
- package/dist/{document-by-id-BRDkvmpn.js → document-by-id-BqNuTx4S.js} +2 -2
- package/dist/{document-by-id-BRDkvmpn.js.map → document-by-id-BqNuTx4S.js.map} +1 -1
- package/dist/{document-model-modules-Gsh1Xr7j.js → document-model-modules-Wjh92XAb.js} +192 -157
- package/dist/document-model-modules-Wjh92XAb.js.map +1 -0
- package/dist/{document-operations-BSzcF0mu.js → document-operations--Z0AOyyy.js} +74 -27
- package/dist/document-operations--Z0AOyyy.js.map +1 -0
- package/dist/{global-BuSwbbY0.d.ts → global-CPJA8ePb.d.ts} +56 -4
- package/dist/global-CPJA8ePb.d.ts.map +1 -0
- package/dist/{index-ewIc3pEO.d.ts → index-DRCTps7m.d.ts} +2 -2
- package/dist/{index-ewIc3pEO.d.ts.map → index-DRCTps7m.d.ts.map} +1 -1
- package/dist/index.d.ts +244 -18
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +305 -37
- package/dist/index.js.map +1 -1
- package/dist/make-ph-event-functions-C1JTfEw1.js +251 -0
- package/dist/make-ph-event-functions-C1JTfEw1.js.map +1 -0
- package/dist/navigation-B4fHR-Tm.js +315 -0
- package/dist/navigation-B4fHR-Tm.js.map +1 -0
- package/dist/{relational-DxHuX41f.js → relational-DZuyKp2y.js} +2 -2
- package/dist/{relational-DxHuX41f.js.map → relational-DZuyKp2y.js.map} +1 -1
- package/dist/{renown-D05wkobG.js → renown-CGQYQsvH.js} +2 -2
- package/dist/{renown-D05wkobG.js.map → renown-CGQYQsvH.js.map} +1 -1
- package/dist/{renown-CPAeJt5L.js → renown-DlkS61Dp.js} +28 -22
- package/dist/{renown-CPAeJt5L.js.map → renown-DlkS61Dp.js.map} +1 -1
- package/dist/src/ai/index.d.ts.map +1 -1
- package/dist/src/ai/index.js +3 -3
- package/dist/src/analytics/index.js +3 -3
- package/dist/src/graphql-client/entry.d.ts +2 -2
- package/dist/src/graphql-client/entry.js +3 -3
- package/dist/src/relational/index.js +1 -1
- package/dist/src/renown/index.d.ts +1 -1
- package/dist/src/renown/index.js +2 -2
- package/dist/src/rpc/index.d.ts +3 -1
- package/dist/src/rpc/index.d.ts.map +1 -1
- package/dist/src/rpc/index.js +1 -3
- package/dist/src/rpc/index.js.map +1 -1
- package/dist/{switchboard-3vHbIV5W.js → switchboard-DAvOdf_g.js} +8 -6
- package/dist/switchboard-DAvOdf_g.js.map +1 -0
- package/package.json +10 -10
- package/dist/client-Cq5avLW5.js.map +0 -1
- package/dist/dispatch-C1VVTn5S.js.map +0 -1
- package/dist/document-model-modules-Gsh1Xr7j.js.map +0 -1
- package/dist/document-operations-BSzcF0mu.js.map +0 -1
- package/dist/global-BuSwbbY0.d.ts.map +0 -1
- package/dist/make-ph-event-functions-CdsvEl5t.js +0 -55
- package/dist/make-ph-event-functions-CdsvEl5t.js.map +0 -1
- package/dist/switchboard-3vHbIV5W.js.map +0 -1
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { t as PGlite } from "./pglite-CntadC_p-DTkdF8sr.js";
|
|
2
2
|
import { c as ReactorGraphQLClient, r as GraphQLClientWindowEvents } from "./types-0Fh1tNjy.js";
|
|
3
3
|
import { r as IWorkerAdminClient, t as IInspectorProxy } from "./inspector-proxy-DODqs15F.js";
|
|
4
|
+
import { DragEventHandler, ReactNode } from "react";
|
|
4
5
|
import { IDocumentModelLoader, IReactorClient, InProcessReactorClientModule, InProcessReactorModule, ReactorClientModule, ReactorModule } from "@powerhousedao/reactor";
|
|
5
6
|
import { DocumentDriveDocument } from "@powerhousedao/shared/document-drive";
|
|
6
7
|
import { Action, DocumentAction, DocumentModelModule, Operation, PHDocument } from "@powerhousedao/shared/document-model";
|
|
7
|
-
import { DragEventHandler, ReactNode } from "react";
|
|
8
8
|
import { IRenown } from "@renown/sdk";
|
|
9
9
|
import { IAttachmentService } from "@powerhousedao/reactor-attachments/client";
|
|
10
10
|
import { WorkerPackageSource } from "@powerhousedao/reactor/rpc";
|
|
@@ -201,7 +201,9 @@ type PHModal = {
|
|
|
201
201
|
} | {
|
|
202
202
|
type: "driveSettings";
|
|
203
203
|
driveId: string;
|
|
204
|
-
} |
|
|
204
|
+
} |
|
|
205
|
+
/** @deprecated Open `{ settings: true }` through the navigation instead. */
|
|
206
|
+
{
|
|
205
207
|
type: "settings";
|
|
206
208
|
} | {
|
|
207
209
|
type: "clearStorage";
|
|
@@ -405,7 +407,57 @@ interface WorkerReactorClientModule extends ReactorClientModule {
|
|
|
405
407
|
registerPackages: (sources: WorkerPackageSource[]) => Promise<void>;
|
|
406
408
|
}
|
|
407
409
|
type LOADING = null;
|
|
410
|
+
/** A drive, or a node in it. */
|
|
411
|
+
type PHDriveTarget = {
|
|
412
|
+
driveSlug: string;
|
|
413
|
+
nodeSlug?: string;
|
|
414
|
+
};
|
|
415
|
+
/** A settings tab by id; `true` opens the first one. */
|
|
416
|
+
type PHSettingsTarget = {
|
|
417
|
+
settings: string | true;
|
|
418
|
+
};
|
|
419
|
+
/** What the app shows; `undefined` targets home. */
|
|
420
|
+
type PHNavigationTarget = PHDriveTarget | PHSettingsTarget;
|
|
421
|
+
/** Query params to write; an `undefined` value removes the param. */
|
|
422
|
+
type PHSearchUpdate = Record<string, string | undefined>;
|
|
423
|
+
type PHNavigateOptions = {
|
|
424
|
+
replace?: boolean;
|
|
425
|
+
/** The target's own query params; the host decides which others survive. */
|
|
426
|
+
search?: PHSearchUpdate;
|
|
427
|
+
};
|
|
428
|
+
/** Merges an object into the current query params; a function returns them all. */
|
|
429
|
+
type SearchParamsUpdate = PHSearchUpdate | ((prev: Record<string, string>) => PHSearchUpdate);
|
|
430
|
+
type SetSearchParams = (update: SearchParamsUpdate, options?: {
|
|
431
|
+
replace?: boolean;
|
|
432
|
+
}) => void;
|
|
433
|
+
/** Host-owned navigation and URL state; without one, the browser history is used.
|
|
434
|
+
* Set once on the store; its hooks must not change between renders. */
|
|
435
|
+
type PHNavigation = {
|
|
436
|
+
location(): {
|
|
437
|
+
pathname: string;
|
|
438
|
+
search: string;
|
|
439
|
+
};
|
|
440
|
+
open(target: PHNavigationTarget | undefined, options?: PHNavigateOptions): void;
|
|
441
|
+
/** The public href that opens `target`, base path included. */
|
|
442
|
+
hrefFor?(target: PHNavigationTarget | undefined): string;
|
|
443
|
+
/** Whether `target` is what the location shows now; search params aside. */
|
|
444
|
+
useIsCurrent?(target: PHNavigationTarget | undefined): boolean;
|
|
445
|
+
/** Warms what `target` shows, e.g. on hover; optional. */
|
|
446
|
+
preload?(target: PHNavigationTarget | undefined): void;
|
|
447
|
+
/** Replaces the query params with what `update` returns, keeping the path. */
|
|
448
|
+
setSearch(update: (prev: Record<string, string>) => PHSearchUpdate, options?: {
|
|
449
|
+
replace?: boolean;
|
|
450
|
+
}): void;
|
|
451
|
+
/** The current query params. */
|
|
452
|
+
useSearchParams(): Record<string, string>;
|
|
453
|
+
/** A stable setter for the query params. */
|
|
454
|
+
useSetSearchParams(): SetSearchParams;
|
|
455
|
+
/** Returns to the entry from before the open document was opened, past any
|
|
456
|
+
* pushed inside it; false when this session didn't open it. */
|
|
457
|
+
closeOpened?(): boolean;
|
|
458
|
+
};
|
|
408
459
|
type PHGlobal = PHGlobalConfig & {
|
|
460
|
+
navigation?: PHNavigation;
|
|
409
461
|
loading?: boolean;
|
|
410
462
|
reactorClientModule?: BrowserReactorClientModule | WorkerReactorClientModule;
|
|
411
463
|
reactorClient?: IReactorBrowserClient;
|
|
@@ -442,6 +494,6 @@ declare global {
|
|
|
442
494
|
interface WindowEventMap extends GraphQLClientWindowEvents {}
|
|
443
495
|
}
|
|
444
496
|
//#endregion
|
|
445
|
-
export {
|
|
497
|
+
export { PHDocumentEditorConfigSetters as $, PHToastFn as A, IPackageDiscoveryService as B, addDraggingNodeEventHandler as C, IPackageManager as D, IPackageListerUnsubscribe as E, TimelineItem as F, PHAppConfig as G, PHModal as H, DiscoveryEvent as I, PHAppConfigSetters as J, PHAppConfigHooks as K, DiscoveryEventListener as L, PHToastType as M, TimelineBarItem as N, IPackagesListener as O, TimelineDividerItem as P, PHDocumentEditorConfigKey as Q, FailedInstallation as R, DraggingNode as S, useDropNode as T, FullPHGlobalConfig as U, PendingInstallation as V, PHAnalyticsGlobalConfig as W, PHDocumentEditorConfig as X, PHCommonGlobalConfig as Y, PHDocumentEditorConfigHooks as Z, SetPHGlobalValue as _, OperationsCacheEntry as _t, PHDriveTarget as a, PHGlobalConfigSetters as at, WorkerReactorClientModule as b, RejectedPromise as bt, PHGlobalKey as c, PHRelationalProcessorsGlobalConfig as ct, PHNavigation as d, IReactorBrowserClient as dt, PHDrivesGlobalConfig as et, PHNavigationTarget as f, DocumentDispatch as ft, SetEvent as g, IOperationCache as gt, SearchParamsUpdate as h, IDocumentCache as ht, LOADING as i, PHGlobalConfigKey as it, PHToastOptions as j, PackageManagerInstallResult as k, PHGlobalValue as l, PHRenownGlobalConfig as lt, PHSettingsTarget as m, FulfilledPromise as mt, BrowserReactorClientModule as n, PHGlobalConfigHooks as nt, PHGlobal as o, PHGlobalConfigSettersForKey as ot, PHSearchUpdate as p, DocumentRefetchState as pt, PHAppConfigKey as q, BrowserReactorModule as r, PHGlobalConfigHooksForKey as rt, PHGlobalEventHandlerAdders as s, PHProcessorsGlobalConfig as st, AddPHGlobalEventHandler as t, PHGlobalConfig as tt, PHNavigateOptions as u, PHSentryGlobalConfig as ut, SetSearchParams as v, PromiseState as vt, useDragNode as w, WorkerReactorModule as x, UsePHGlobalValue as y, PromiseWithState as yt, FailedInstallationReason as z };
|
|
446
498
|
export {};
|
|
447
|
-
//# sourceMappingURL=global-
|
|
499
|
+
//# sourceMappingURL=global-CPJA8ePb.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"global-CPJA8ePb.d.ts","names":[],"sources":["../src/types/documents.ts","../src/types/reactor-browser-client.ts","../src/types/config.ts","../src/types/modals.ts","../src/types/package-discovery.ts","../src/types/timeline.ts","../src/types/toast.ts","../src/types/vetra.ts","../src/hooks/node-drag-and-drop.ts","../src/types/global.ts"],"mappings":"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"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { i as LOADING } from "./global-
|
|
1
|
+
import { i as LOADING } from "./global-CPJA8ePb.js";
|
|
2
2
|
import { CSSProperties, ReactNode } from "react";
|
|
3
3
|
import { CREDENTIAL_SCHEMA_EIP712_TYPE, CREDENTIAL_SUBJECT_TYPE, CREDENTIAL_TYPES, DOMAIN_TYPE, IRenown, ISSUER_TYPE, LoginStatus, User, VERIFIABLE_CREDENTIAL_EIP712_TYPE } from "@renown/sdk";
|
|
4
4
|
import { LoginMethod, WalletAdapterDescriptor, WalletController, WalletSession, WalletTheme } from "@renown/sdk/wallet";
|
|
@@ -268,4 +268,4 @@ declare function useRenownWalletAdapter<T extends WalletController = WalletContr
|
|
|
268
268
|
//#endregion
|
|
269
269
|
export { useUser as $, RENOWN_RETURN_URL_STRIPPED_PARAMS as A, UserIcon as B, CREDENTIAL_SCHEMA_EIP712_TYPE as C, ISSUER_TYPE as D, DOMAIN_TYPE as E, ChevronDownIcon as F, RenownLoginButtonProps as G, RenownUserButtonMenuItem as H, CopyIcon as I, addRenownEventHandler as J, RenownAuthButton as K, DisconnectIcon as L, VERIFIABLE_CREDENTIAL_EIP712_TYPE as M, initConnectCrypto as N, RENOWN_CHAIN_ID as O, initRenownCrypto as P, useRenown as Q, RenownLogo as R, useRenownInitialUser as S, CREDENTIAL_TYPES as T, RenownUserButtonProps as U, RenownUserButton as V, RenownLoginButton as W, useDid as X, setRenown as Y, useLoginStatus as Z, RENOWN_INITIAL_UNKNOWN as _, RenownWalletProviderProps as a, RenownAuthResolution as at, RenownInitialUserProviderProps as b, Renown as c, useRenownAuthAsync as ct, useRenownInit as d, login as et, RenownSessionCookieOptions as f, RENOWN_INITIAL_ANONYMOUS as g, useRenownSessionSynced as h, RenownWalletProvider as i, RenownAuthAsync as it, RENOWN_URL as j, RENOWN_NETWORK_ID as k, RenownProps as l, useRenownSessionCookie as m, RenownLoginMethod as n, openRenown as nt, RenownProvider as o, RenownAuthStatus as ot, RenownSessionCookieState as p, RenownAuthButtonProps as q, useRenownLoginMethods as r, RenownAuth as rt, RenownProviderProps as s, useRenownAuth as st, useRenownWalletAdapter as t, logout as tt, RenownInitOptions as u, RenownInitialAuth as v, CREDENTIAL_SUBJECT_TYPE as w, useRenownInitialAuth as x, RenownInitialUserProvider as y, SpinnerIcon as z };
|
|
270
270
|
export {};
|
|
271
|
-
//# sourceMappingURL=index-
|
|
271
|
+
//# sourceMappingURL=index-DRCTps7m.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index-
|
|
1
|
+
{"version":3,"file":"index-DRCTps7m.d.ts","names":[],"sources":["../src/renown/use-renown-auth.ts","../src/renown/session.ts","../src/hooks/renown.ts","../src/renown/components/RenownAuthButton.tsx","../src/renown/components/RenownLoginButton.tsx","../src/renown/components/RenownUserButton.tsx","../src/renown/components/icons.tsx","../src/renown/crypto.ts","../src/renown/constants.ts","../src/renown/initial-user.tsx","../src/renown/use-renown-session.ts","../src/renown/use-renown-init.ts","../src/renown/renown-init.tsx","../src/renown/provider.tsx","../src/renown/wallet-provider.tsx","../src/renown/login-methods.ts","../src/renown/use-renown-wallet-adapter.ts"],"mappings":";;;;;KAoBY,mBAAmB;UAEd;EACf,QAAQ;EACR,MAAM;EACN;EACA;EACA;EACA;EACA;EACA;EACA,QAAQ,UAAU,eAAe,SAAS;EAC1C;EACA,OAAO;EACP,cAAc;EACd;;iBA+Bc,iBAAiB;KAuFrB;UAKK,wBAAwB;;EAEvC,OAAO;EACP;;iBAOc,sBAAsB;;;iBCxJtB,WAAW;iBAuHL,MACpB,6BACA,QAAQ,sBACP,QAAQ;iBAgCW,UAAM;;;;cChKf;;cAIA,iBAAiB,UAAU;;cAI3B,YAAY,OAAO,UAAU;;iBAI1B;;iBA2CA,WAAW;;iBA2CX,kBAAkB;;;UCvGjB;EACf;EACA;EACA,eAAe;EACf,cAAc;EACd,iBAAiB;EACjB,YAAY,MAAM,eAAe;;iBAGnB,mBACd,WACA,UACA,cACA,aACA,gBACA,YACC,oDAAqB,IAAA;;;UCfP;EACf;EACA;EACA,QAAQ;EACR;EACA;EACA,WAAW;;iBAsCG,oBACd,SAAS,aACT,OACA,WACA,SACA,YACC,qDAAsB,IAAA;;;UCzCR;EACf;EACA,OAAO;EACP;EACA,QAAQ;;UAGO;EACf;EACA;EACA;EACA;EACA;EACA,QAAQ;EACR;EACA;EACA,WAAW;EACX,YAAY;;iBAiKE,mBACd,SAAS,aACT,UAAU,cACV,WAAW,eACX,QAAQ,YACR,cAAc,kBACd,OACA,WACA,SACA,UACA,aACC,oDAAqB,IAAA;;;UC1Md;EACR;EACA;EACA;EACA;EACA,QAAQ;EACR;;UAGQ,wBAAwB;EAChC;;iBAGc,aACd,OACA,QACA,SACA,OACA,aACC,8CAAe,IAAA;iBAwBF,WACd,MACA,SACC,wCAAS,IAAA;iBA2BI,iBACd,MACA,SACC,wCAAS,IAAA;iBAkCI,cAAc,MAAW,SAA0B,wCAAS,IAAA;iBAiE5D,kBACd,MACA,OACA,SACC,wCAAS,IAAA;iBAqBI,WAAW,MAAW,SAAqB,wCAAS,IAAA;;;;;;;;;iBClM9C,qBAAiB,8BAAA;;;;;iBAQjB,oBAAgB,8BAAA;;;cChBzB;cACA;cACA;cAUA;;;;KCJD;EACN;EAAwB,MAAM;;EAC9B;;EACA;;cAEO,wBAAwB;cACxB,0BAA0B;UAUtB;;EAEf,cAAc;;EAEd,cAAc;EACd,UAAU;;iBAGI,4BACd,aACA,aACA,YACC,6DAA8B,IAAA;;iBAejB,wBAAwB;iBAIxB,wBAAwB;;;UC7CvB;;EAEf;;EAEA;;EAEA;;UAGe;;EAEf;;iBAKc,uBACd,UAAS,6BACR;iBA4Ea;;;UCjGC;EACf;;EAEA;EACA;EACA;;EAEA;;EAEA;;;;;;;;;;;;;;;iBA4Cc,gBACd,SACA,WACA,KACA,gBACA,YACA,WACC,oBAAoB,QAAQ;;;UCjEd,oBAAoB;EACnC,WAAW;;;;;;;;;;;;;;;;;;iBAmBG,SAAS,YAAY,eAAe;;;UCJnC;EACf;;EAEA;EACA;EACA;;EAEA,WAAW;EACX,QAAQ;;EAER;;EAEA;;EAEA;IAAY,OAAO;;;EAEnB;EACA,WAAW;EACX,UAAU;;iBA0BI,iBACd,SACA,WACA,KACA,gBACA,UACA,OACA,YACA,SACA,SACA,iBACA,SACA,YACC,kDAAmB,IAAA;;;UCsBL;;EAEf,UAAU;;EAEV,QAAQ;EACR,UAAU;;;iBAII,uBACd,UAAU,gBACV,OACA,YACC,wDAAyB,IAAA;;;UCtGX;EACf,IAAI;EACJ;;;iBAWc,sBACd,SAAS,QAAQ,OAAO,wBACvB;;;;iBCXa,uBACd,UAAU,mBAAmB,kBAC7B,aAAa"}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import { a as getAnalyticsStore, i as createAnalyticsStore, n as IPowerhouseAnalytics, r as CreateStoreOptions } from "./types-520nWrB3.js";
|
|
2
|
-
import { $ as
|
|
3
|
-
import { $ as GraphQLReactorProvider, A as useDocumentCache, At as DocumentChangeListener, B as makeAuthConnectionParams, Bt as RemoteDocumentChangeEvent, C as useReactorClient, Ct as RevisionsListSelection, D as addDocumentCacheEventHandler, Dt as revisionMapFromRevisionsList, E as useSyncList, Et as phDocumentFromMutation, F as useGetDocuments, Ft as IRemoteController, G as resolveDocumentModelModule, Gt as TrackedAction, H as subscriptionsUrlFromGraphqlUrl, Ht as RemoteOperation, I as ConnectionParams, It as MergeHandler, J as stampAction, Jt as addPromiseState, K as prepareSignedActions, Kt as DocumentCache, L as DocumentChangesEventPayload, Lt as PushResult, M as useDocuments, Mt as GetDocumentWithOperationsResult, N as useGetDocument, Nt as GetOperationsResult, O as setDocumentCache, Ot as ConflictInfo, P as useGetDocumentAsync, Pt as IRemoteClient, Q as ReactorOperationFieldsFragmentDoc, R as DocumentChangesSubscriptionOptions, Rt as RemoteControllerGraphQLClient, S as usePGlite, St as GetDocumentQueryResult, T as useSync, Tt as phDocumentFromGetDocument, U as StaticPackageManager, Ut as RemoteOperationResultPage, V as startDocumentChangesSubscription, Vt as RemoteDocumentData, W as packageFromDocumentModels, Wt as SyncStatus, X as MutateDocumentWithOperationsResult, Xt as readPromiseState, Y as MutateDocumentWithOperationsDocument, Yt as isOperationCache, Z as MutateDocumentWithOperationsVariables, Zt as IDLE_REFETCH_STATE, _ as setFullReactorClient, _t as GraphQLWrongBackendError, a as DocumentOperationsState, at as GraphQLReactorClientOptions, b as useDatabase, bt as makeAuthMiddleware, c as useDocumentModelModuleById, ct as viewFilterInputFromViewFilter, d as UseDispatchResult, dt as SubgraphSdkRegistry, et as GraphQLReactorProviderProps, f as useDispatch, ft as TypedGraphQLDocument, g as getFullReactorClient, gt as GraphQLOperationNotSupportedError, h as addReactorClientModuleEventHandler, ht as BatchJobFailedError, i as DocumentOperationsResult, it as GraphQLReactorClient, j as useDocumentSafe, jt as GetDocumentResult, k as useDocument, kt as ConflictStrategy, l as useDocumentModelModules, lt as GraphQLRequestOptions, m as addReactorClientEventHandler, mt as subgraphUrlFromGraphqlUrl, n as setAttachmentService, nt as useSwitchboardClient, o as UseDocumentOperationsOptions, ot as findIsServableOverGraphQL, p as addFullReactorClientEventHandler, pt as describeGraphQLDocument, q as signStampedAction, qt as IDLE_OPERATIONS_ENTRY, r as useAttachmentService, rt as DriveIdCall, s as useDocumentOperations, st as isGraphQLReactorClient, t as addAttachmentServiceEventHandler, tt as ensurePHEventHandlers, u as DispatchFn, ut as SubgraphSdkFactory, v as setReactorClient, vt as BearerTokenProvider, w as useReactorClientModule, wt as isoStringFromDateTime, x as useModelRegistry, xt as GetDocumentQueryFields, y as setReactorClientModule, yt as ambientRenownTokenProvider, z as isAuthRefusalClose, zt as RemoteControllerOptions } from "./attachment-service-
|
|
2
|
+
import { $ as PHDocumentEditorConfigSetters, A as PHToastFn, B as IPackageDiscoveryService, C as addDraggingNodeEventHandler, D as IPackageManager, E as IPackageListerUnsubscribe, F as TimelineItem, G as PHAppConfig, H as PHModal, I as DiscoveryEvent, J as PHAppConfigSetters, K as PHAppConfigHooks, L as DiscoveryEventListener, M as PHToastType, N as TimelineBarItem, O as IPackagesListener, P as TimelineDividerItem, Q as PHDocumentEditorConfigKey, R as FailedInstallation, S as DraggingNode, T as useDropNode, U as FullPHGlobalConfig, V as PendingInstallation, W as PHAnalyticsGlobalConfig, X as PHDocumentEditorConfig, Y as PHCommonGlobalConfig, Z as PHDocumentEditorConfigHooks, _ as SetPHGlobalValue, _t as OperationsCacheEntry, a as PHDriveTarget, at as PHGlobalConfigSetters, b as WorkerReactorClientModule, bt as RejectedPromise, c as PHGlobalKey, ct as PHRelationalProcessorsGlobalConfig, d as PHNavigation, dt as IReactorBrowserClient, et as PHDrivesGlobalConfig, f as PHNavigationTarget, ft as DocumentDispatch, g as SetEvent, gt as IOperationCache, h as SearchParamsUpdate, ht as IDocumentCache, i as LOADING, it as PHGlobalConfigKey, j as PHToastOptions, k as PackageManagerInstallResult, l as PHGlobalValue, lt as PHRenownGlobalConfig, m as PHSettingsTarget, mt as FulfilledPromise, n as BrowserReactorClientModule, nt as PHGlobalConfigHooks, o as PHGlobal, ot as PHGlobalConfigSettersForKey, p as PHSearchUpdate, pt as DocumentRefetchState, q as PHAppConfigKey, r as BrowserReactorModule, rt as PHGlobalConfigHooksForKey, s as PHGlobalEventHandlerAdders, st as PHProcessorsGlobalConfig, t as AddPHGlobalEventHandler, tt as PHGlobalConfig, u as PHNavigateOptions, ut as PHSentryGlobalConfig, v as SetSearchParams, vt as PromiseState, w as useDragNode, x as WorkerReactorModule, y as UsePHGlobalValue, yt as PromiseWithState, z as FailedInstallationReason } from "./global-CPJA8ePb.js";
|
|
3
|
+
import { $ as GraphQLReactorProvider, A as useDocumentCache, At as DocumentChangeListener, B as makeAuthConnectionParams, Bt as RemoteDocumentChangeEvent, C as useReactorClient, Ct as RevisionsListSelection, D as addDocumentCacheEventHandler, Dt as revisionMapFromRevisionsList, E as useSyncList, Et as phDocumentFromMutation, F as useGetDocuments, Ft as IRemoteController, G as resolveDocumentModelModule, Gt as TrackedAction, H as subscriptionsUrlFromGraphqlUrl, Ht as RemoteOperation, I as ConnectionParams, It as MergeHandler, J as stampAction, Jt as addPromiseState, K as prepareSignedActions, Kt as DocumentCache, L as DocumentChangesEventPayload, Lt as PushResult, M as useDocuments, Mt as GetDocumentWithOperationsResult, N as useGetDocument, Nt as GetOperationsResult, O as setDocumentCache, Ot as ConflictInfo, P as useGetDocumentAsync, Pt as IRemoteClient, Q as ReactorOperationFieldsFragmentDoc, R as DocumentChangesSubscriptionOptions, Rt as RemoteControllerGraphQLClient, S as usePGlite, St as GetDocumentQueryResult, T as useSync, Tt as phDocumentFromGetDocument, U as StaticPackageManager, Ut as RemoteOperationResultPage, V as startDocumentChangesSubscription, Vt as RemoteDocumentData, W as packageFromDocumentModels, Wt as SyncStatus, X as MutateDocumentWithOperationsResult, Xt as readPromiseState, Y as MutateDocumentWithOperationsDocument, Yt as isOperationCache, Z as MutateDocumentWithOperationsVariables, Zt as IDLE_REFETCH_STATE, _ as setFullReactorClient, _t as GraphQLWrongBackendError, a as DocumentOperationsState, at as GraphQLReactorClientOptions, b as useDatabase, bt as makeAuthMiddleware, c as useDocumentModelModuleById, ct as viewFilterInputFromViewFilter, d as UseDispatchResult, dt as SubgraphSdkRegistry, et as GraphQLReactorProviderProps, f as useDispatch, ft as TypedGraphQLDocument, g as getFullReactorClient, gt as GraphQLOperationNotSupportedError, h as addReactorClientModuleEventHandler, ht as BatchJobFailedError, i as DocumentOperationsResult, it as GraphQLReactorClient, j as useDocumentSafe, jt as GetDocumentResult, k as useDocument, kt as ConflictStrategy, l as useDocumentModelModules, lt as GraphQLRequestOptions, m as addReactorClientEventHandler, mt as subgraphUrlFromGraphqlUrl, n as setAttachmentService, nt as useSwitchboardClient, o as UseDocumentOperationsOptions, ot as findIsServableOverGraphQL, p as addFullReactorClientEventHandler, pt as describeGraphQLDocument, q as signStampedAction, qt as IDLE_OPERATIONS_ENTRY, r as useAttachmentService, rt as DriveIdCall, s as useDocumentOperations, st as isGraphQLReactorClient, t as addAttachmentServiceEventHandler, tt as ensurePHEventHandlers, u as DispatchFn, ut as SubgraphSdkFactory, v as setReactorClient, vt as BearerTokenProvider, w as useReactorClientModule, wt as isoStringFromDateTime, x as useModelRegistry, xt as GetDocumentQueryFields, y as setReactorClientModule, yt as ambientRenownTokenProvider, z as isAuthRefusalClose, zt as RemoteControllerOptions } from "./attachment-service-CQ3JygJd.js";
|
|
4
4
|
import { baseDocumentModels, baseDocumentModelsMap } from "./src/document-model.js";
|
|
5
5
|
import { t as PGlite } from "./pglite-CntadC_p-DTkdF8sr.js";
|
|
6
6
|
import { r as PGliteWithLive } from "./index-rtDmzViP.js";
|
|
7
7
|
import { D as PropagationMode, T as MutateDocumentMutation, _ as CreateDocumentMutation, a as GraphQLDocumentEvents, c as ReactorGraphQLClient, d as DEFAULT_DRIVE_ID, f as DEFAULT_SWITCHBOARD_URL, g as ActionInput, h as graphqlEventsToSyncDrive, i as GraphQLDocumentEventOperationName, k as SdkFunctionWrapper, l as RunDocumentOptions, m as graphqlDocumentsEvents, n as GraphQLClientDocumentsEvent, o as GraphQLDocumentEventsOperationName, p as graphqlDocumentEvents, r as GraphQLClientWindowEvents, s as GraphQLDocumentsEvents, t as GraphQLClientDocumentEvent, u as TStateSchemaZodObject, v as DeleteDocumentMutation, w as GetDocumentWithOperationsQuery, x as FindDocumentsQuery, y as DeleteDocumentsMutation } from "./types-0Fh1tNjy.js";
|
|
8
8
|
import { t as createClient } from "./client-BnGewICj.js";
|
|
9
|
-
import { $ as useUser, A as RENOWN_RETURN_URL_STRIPPED_PARAMS, B as UserIcon, C as CREDENTIAL_SCHEMA_EIP712_TYPE, D as ISSUER_TYPE, E as DOMAIN_TYPE, F as ChevronDownIcon, G as RenownLoginButtonProps, H as RenownUserButtonMenuItem, I as CopyIcon, J as addRenownEventHandler, K as RenownAuthButton, L as DisconnectIcon, M as VERIFIABLE_CREDENTIAL_EIP712_TYPE, N as initConnectCrypto, O as RENOWN_CHAIN_ID, P as initRenownCrypto, Q as useRenown, R as RenownLogo, S as useRenownInitialUser, T as CREDENTIAL_TYPES, U as RenownUserButtonProps, V as RenownUserButton, W as RenownLoginButton, X as useDid, Y as setRenown, Z as useLoginStatus, _ as RENOWN_INITIAL_UNKNOWN, a as RenownWalletProviderProps, at as RenownAuthResolution, b as RenownInitialUserProviderProps, c as Renown, ct as useRenownAuthAsync, d as useRenownInit, et as login, f as RenownSessionCookieOptions, g as RENOWN_INITIAL_ANONYMOUS, h as useRenownSessionSynced, i as RenownWalletProvider, it as RenownAuthAsync, j as RENOWN_URL, k as RENOWN_NETWORK_ID, l as RenownProps, m as useRenownSessionCookie, n as RenownLoginMethod, nt as openRenown, o as RenownProvider, ot as RenownAuthStatus, p as RenownSessionCookieState, q as RenownAuthButtonProps, r as useRenownLoginMethods, rt as RenownAuth, s as RenownProviderProps, st as useRenownAuth, t as useRenownWalletAdapter, tt as logout, u as RenownInitOptions, v as RenownInitialAuth, w as CREDENTIAL_SUBJECT_TYPE, x as useRenownInitialAuth, y as RenownInitialUserProvider, z as SpinnerIcon } from "./index-
|
|
9
|
+
import { $ as useUser, A as RENOWN_RETURN_URL_STRIPPED_PARAMS, B as UserIcon, C as CREDENTIAL_SCHEMA_EIP712_TYPE, D as ISSUER_TYPE, E as DOMAIN_TYPE, F as ChevronDownIcon, G as RenownLoginButtonProps, H as RenownUserButtonMenuItem, I as CopyIcon, J as addRenownEventHandler, K as RenownAuthButton, L as DisconnectIcon, M as VERIFIABLE_CREDENTIAL_EIP712_TYPE, N as initConnectCrypto, O as RENOWN_CHAIN_ID, P as initRenownCrypto, Q as useRenown, R as RenownLogo, S as useRenownInitialUser, T as CREDENTIAL_TYPES, U as RenownUserButtonProps, V as RenownUserButton, W as RenownLoginButton, X as useDid, Y as setRenown, Z as useLoginStatus, _ as RENOWN_INITIAL_UNKNOWN, a as RenownWalletProviderProps, at as RenownAuthResolution, b as RenownInitialUserProviderProps, c as Renown, ct as useRenownAuthAsync, d as useRenownInit, et as login, f as RenownSessionCookieOptions, g as RENOWN_INITIAL_ANONYMOUS, h as useRenownSessionSynced, i as RenownWalletProvider, it as RenownAuthAsync, j as RENOWN_URL, k as RENOWN_NETWORK_ID, l as RenownProps, m as useRenownSessionCookie, n as RenownLoginMethod, nt as openRenown, o as RenownProvider, ot as RenownAuthStatus, p as RenownSessionCookieState, q as RenownAuthButtonProps, r as useRenownLoginMethods, rt as RenownAuth, s as RenownProviderProps, st as useRenownAuth, t as useRenownWalletAdapter, tt as logout, u as RenownInitOptions, v as RenownInitialAuth, w as CREDENTIAL_SUBJECT_TYPE, x as useRenownInitialAuth, y as RenownInitialUserProvider, z as SpinnerIcon } from "./index-DRCTps7m.js";
|
|
10
10
|
import { QueryCallbackReturnType, RelationalDbOptions, RelationalDbWithLive, createProcessorQuery, useRelationalDb, useRelationalQuery, useRelationalQueryOptions } from "./src/relational/index.js";
|
|
11
|
+
import { DragEventHandler, MouseEvent, ReactNode } from "react";
|
|
11
12
|
import { DocumentModelLib, DocumentModelModule, EditorModule, PHDocument, PHDocumentController } from "document-model";
|
|
12
13
|
import { ActionCandidate, ChannelScheme, ConnectionState, ConnectionStateSnapshot, ConnectionStateSnapshot as ConnectionStateSnapshot$1, Database, DocumentChangeType, DocumentIntegrityService, DriveCollectionId, Evaluation, GqlRequestChannel, IChannel, IDocumentModelLoader, IDocumentModelRegistry, IPeerAgreement, IProcessor, IProcessorHostModuleBase, IQueue, IReactorClient, IReactorClient as IReactorClient$1, IReactorProcessorHostModuleBase, IRelationalDb, InMemoryQueue, IntervalPollTimer, Job, JwtHandler, KeyframeValidationIssue, OperationWithContext, ParsedDriveUrl, PollBehavior, PollBehavior as PollBehavior$1, ProcessorApp, ProcessorFactory, ProcessorFactoryBuilder as ProcessorFactoryBuilder$1, ProcessorFilter, ProcessorRecord, REACTOR_SCHEMA, ReactorBuilder, ReactorClientBuilder, ReactorFeatureFlags, RebuildResult, RelationalDbProcessor, Remote, RemoteFilter, RemoteMeta, RemotePeer, SignerConfig, SnapshotValidationIssue, SyncHold, SyncOperation, SyncOperationStatus, ValidationResult, driveIdFromUrl, isDriveAuthError, parseDriveUrl } from "@powerhousedao/reactor";
|
|
13
14
|
import { DocumentDriveAction, DocumentDriveDocument, DriveInput, FileNode, FolderNode, Node, SharingType } from "@powerhousedao/shared/document-drive";
|
|
14
15
|
import { Action as Action$1, AuthSubject, DocumentOperations, Operation as Operation$1, PHBaseState, PHDocument as PHDocument$1, PHDocumentHeader, SubgraphModule, ValidationError } from "@powerhousedao/shared/document-model";
|
|
15
|
-
import { DragEventHandler } from "react";
|
|
16
16
|
import { AttachmentDownloadInput, AttachmentHeader, AttachmentUploadResult, IAttachmentClient, PreprocessResult } from "@powerhousedao/reactor-attachments/client";
|
|
17
|
-
import { ConflictResolution as ConflictResolution$1, DocumentDispatch as DocumentDispatch$1, FileUploadProgressCallback as FileUploadProgressCallback$1, IReactorBrowserClient as IReactorBrowserClient$1, PHAppConfig as PHAppConfig$1, PHAppConfigHooks as PHAppConfigHooks$1, PHAppConfigKey as PHAppConfigKey$1, PHAppConfigSetters as PHAppConfigSetters$1, PHDocumentEditorConfig as PHDocumentEditorConfig$1, PHDocumentEditorConfigHooks as PHDocumentEditorConfigHooks$1, PHDocumentEditorConfigKey as PHDocumentEditorConfigKey$1, PHDocumentEditorConfigSetters as PHDocumentEditorConfigSetters$1, PHGlobal as PHGlobal$1, PHGlobalConfig as PHGlobalConfig$1, PHGlobalConfigHooks as PHGlobalConfigHooks$1, PHGlobalConfigKey as PHGlobalConfigKey$1, PHGlobalConfigSetters as PHGlobalConfigSetters$1, PHGlobalKey as PHGlobalKey$1, PHModal as PHModal$1 } from "@powerhousedao/reactor-browser";
|
|
17
|
+
import { ConflictResolution as ConflictResolution$1, DocumentDispatch as DocumentDispatch$1, FileUploadProgressCallback as FileUploadProgressCallback$1, IReactorBrowserClient as IReactorBrowserClient$1, PHAppConfig as PHAppConfig$1, PHAppConfigHooks as PHAppConfigHooks$1, PHAppConfigKey as PHAppConfigKey$1, PHAppConfigSetters as PHAppConfigSetters$1, PHDocumentEditorConfig as PHDocumentEditorConfig$1, PHDocumentEditorConfigHooks as PHDocumentEditorConfigHooks$1, PHDocumentEditorConfigKey as PHDocumentEditorConfigKey$1, PHDocumentEditorConfigSetters as PHDocumentEditorConfigSetters$1, PHGlobal as PHGlobal$1, PHGlobalConfig as PHGlobalConfig$1, PHGlobalConfigHooks as PHGlobalConfigHooks$1, PHGlobalConfigKey as PHGlobalConfigKey$1, PHGlobalConfigSetters as PHGlobalConfigSetters$1, PHGlobalKey as PHGlobalKey$1, PHModal as PHModal$1, PHNavigateOptions as PHNavigateOptions$1, PHNavigation as PHNavigation$1, PHNavigationTarget as PHNavigationTarget$1, PHSearchUpdate as PHSearchUpdate$1, PHSettingsTarget as PHSettingsTarget$1, SearchParamsUpdate as SearchParamsUpdate$1, SetSearchParams as SetSearchParams$1 } from "@powerhousedao/reactor-browser";
|
|
18
18
|
import { Node as Node$1 } from "@powerhousedao/shared";
|
|
19
19
|
import { PackageInfo, PackagePage } from "@powerhousedao/shared/registry";
|
|
20
20
|
//#region src/actions/dispatch.d.ts
|
|
@@ -608,6 +608,9 @@ export declare function useFolderNodesInSelectedFolder(): FolderNode[] | undefin
|
|
|
608
608
|
export declare function useDocumentsInSelectedFolder(): PHDocument$1[] | undefined;
|
|
609
609
|
//#endregion
|
|
610
610
|
//#region src/hooks/make-ph-event-functions.d.ts
|
|
611
|
+
/** Calls `onChange` whenever `key` is set: through the bound store, or the
|
|
612
|
+
* `ph:<key>Updated` event on pages that bound none. */
|
|
613
|
+
export declare function subscribeToPHValue(key: PHGlobalKey$1, onChange: () => void): () => void;
|
|
611
614
|
export declare function makePHEventFunctions<TKey extends PHGlobalKey$1>(key: TKey): {
|
|
612
615
|
useValue: () => PHGlobal$1[TKey] | undefined;
|
|
613
616
|
setValue: (value: PHGlobal$1[TKey] | undefined) => void;
|
|
@@ -623,7 +626,7 @@ export declare const usePHModal: () => PHModal$1 | undefined;
|
|
|
623
626
|
export declare const setPHModal: (value: PHModal$1 | undefined) => void;
|
|
624
627
|
/** Adds an event handler for the modal */
|
|
625
628
|
export declare const addModalEventHandler: () => void;
|
|
626
|
-
/** Shows a modal */
|
|
629
|
+
/** Shows a modal; with an app-shell navigation, "settings" opens the settings page. */
|
|
627
630
|
export declare function showPHModal(modal: PHModal$1): void;
|
|
628
631
|
/** Closes the current modal */
|
|
629
632
|
export declare function closePHModal(): void;
|
|
@@ -686,30 +689,166 @@ export declare function useSelectedDocumentSafe(): UseDispatchResult<PHDocument$
|
|
|
686
689
|
export declare function useSelectedDocumentOfType(documentType: null | undefined): never[];
|
|
687
690
|
export declare function useSelectedDocumentOfType<TDocument extends PHDocument$1, TAction extends Action$1>(documentType: string): [TDocument, DocumentDispatch$1<TAction>];
|
|
688
691
|
//#endregion
|
|
692
|
+
//#region src/hooks/ph-store.d.ts
|
|
693
|
+
/** PH state of one app (or one server request); assigning a key notifies. */
|
|
694
|
+
export type PHStore = PHGlobal$1;
|
|
695
|
+
declare const ALL_KEYS: unique symbol;
|
|
696
|
+
export declare function createPHStore(initial?: PHGlobal$1): PHStore;
|
|
697
|
+
/** The keys a scoped store owns; every other key reads and writes its parent. */
|
|
698
|
+
export declare const SCOPED_PH_KEYS: readonly ["selectedDriveId", "selectedNodeId", "navigation"];
|
|
699
|
+
export type ScopedPHKey = (typeof SCOPED_PH_KEYS)[number];
|
|
700
|
+
export type ScopedPHStoreOverrides = Pick<PHGlobal$1, ScopedPHKey>;
|
|
701
|
+
/** A store with its own selection and navigation over `parent`, e.g. for an
|
|
702
|
+
* editor shown beside others; provide it with {@link PHStoreProvider}. */
|
|
703
|
+
export declare function createScopedPHStore(parent: PHStore, overrides?: ScopedPHStoreOverrides): PHStore;
|
|
704
|
+
/** Whether `store` was made by {@link createScopedPHStore}. */
|
|
705
|
+
export declare function isScopedPHStore(store: PHStore | undefined): boolean;
|
|
706
|
+
/** Subscribes to changes of `key`, or of every key when omitted. */
|
|
707
|
+
export declare function subscribePHStore(store: PHStore, listener: () => void, key?: PHGlobalKey$1 | typeof ALL_KEYS): () => void;
|
|
708
|
+
/** Notifies `key`'s listeners without a change, as re-setting a value does. */
|
|
709
|
+
export declare function notifyPHStore(store: PHStore, key: PHGlobalKey$1): void;
|
|
710
|
+
/** A subscribe for `key`, stable per store as useSyncExternalStore expects. */
|
|
711
|
+
export declare function getPHStoreSubscribe(store: PHStore, key?: PHGlobalKey$1): (listener: () => void) => () => void;
|
|
712
|
+
/** The store bound with {@link bindPHStoreToWindow}, if any. */
|
|
713
|
+
export declare function getActivePHStore(): PHGlobal$1 | undefined;
|
|
714
|
+
/** The app's state outside React: the bound store, else `window.ph`. */
|
|
715
|
+
export declare function getPHStore(): PHStore | undefined;
|
|
716
|
+
/** The bound store; otherwise binds `window.ph` if it is a store, else a new
|
|
717
|
+
* store that takes over a plain `window.ph`'s values. */
|
|
718
|
+
export declare function ensurePHStore(): PHStore;
|
|
719
|
+
/** Makes `store` the app's state and `window.ph`; values set on a plain
|
|
720
|
+
* `window.ph` carry over where `store` has none. */
|
|
721
|
+
export declare function bindPHStoreToWindow(store: PHStore): void;
|
|
722
|
+
/** Warns once in development when a global setter runs while a scoped store
|
|
723
|
+
* is mounted, since it acts on the app's store and not the scope's. */
|
|
724
|
+
export declare function warnGlobalSetterInScope(setter: string, hook: string): void;
|
|
725
|
+
/** Hooks below read from `store`; without a provider they read `window.ph`. */
|
|
726
|
+
export declare function PHStoreProvider(props: {
|
|
727
|
+
store: PHStore;
|
|
728
|
+
children: ReactNode;
|
|
729
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
730
|
+
export declare function usePHStore(): PHGlobal$1 | undefined;
|
|
731
|
+
//#endregion
|
|
732
|
+
//#region src/hooks/navigation.d.ts
|
|
733
|
+
/** Fired on `window` when the fallback navigator rewrites the URL. */
|
|
734
|
+
export declare const PH_LOCATION_CHANGE_EVENT = "ph:locationchange";
|
|
735
|
+
/** Params read at boot or app-wide; they survive every navigation. Others,
|
|
736
|
+
* e.g. a document's own, are dropped when the target changes. */
|
|
737
|
+
export declare const GLOBAL_SEARCH_PARAMS: readonly ["driveUrl", "theme", "embed", "LOG_LEVEL", "reactorWorker"];
|
|
738
|
+
/** Feature flags are any `FEATURE_*` param, so they are retained by prefix. */
|
|
739
|
+
export declare const FEATURE_FLAG_PARAM_PREFIX = "FEATURE_";
|
|
740
|
+
/** Whether `key` is a param every navigation keeps. */
|
|
741
|
+
export declare function isGlobalSearchParam(key: string): boolean;
|
|
742
|
+
/** A query string's params; repeated keys keep their last value. */
|
|
743
|
+
export declare function searchToRecord(search: string): Record<string, string>;
|
|
744
|
+
/** `prev` with `update` applied; an `undefined` value removes the key. */
|
|
745
|
+
export declare function applySearchUpdate(prev: Record<string, string>, update: PHSearchUpdate$1): Record<string, string>;
|
|
746
|
+
/** `?a=1&b=2`, or an empty string for no params. */
|
|
747
|
+
export declare function recordToSearch(record: Record<string, string>): string;
|
|
748
|
+
/** The settings page's path; its tabs are below it. */
|
|
749
|
+
export declare const SETTINGS_PATH = "/settings";
|
|
750
|
+
export declare function isSettingsTarget(target: PHNavigationTarget$1 | undefined): target is PHSettingsTarget$1;
|
|
751
|
+
/** The pathname a target opens at, base path included. */
|
|
752
|
+
export declare function targetPathname(target: PHNavigationTarget$1 | undefined): string;
|
|
753
|
+
/** History state key: the index of the entry a document was opened from. */
|
|
754
|
+
export declare const OPENED_FROM_STATE_KEY = "phOpenedFrom";
|
|
755
|
+
/** The index to go back to from `index`, when it lies before it. */
|
|
756
|
+
export declare function openedFromIndex(state: object | undefined, index: number): number | undefined;
|
|
757
|
+
/** @internal Selects what the browser fallback opens; sync-selection.ts sets it. */
|
|
758
|
+
export declare function setBrowserOpenSync(sync: () => void): void;
|
|
759
|
+
export declare const browserNavigation: PHNavigation$1;
|
|
760
|
+
/** The navigation `store` acts through: a scope's own, else the app's. */
|
|
761
|
+
export declare function getNavigationOf(store: PHStore | undefined): PHNavigation$1;
|
|
762
|
+
/** True when the store has a host navigation, not the browser fallback. */
|
|
763
|
+
export declare function hasHostNavigation(): boolean;
|
|
764
|
+
/** The app store's navigation, else the browser fallback. */
|
|
765
|
+
export declare function getPHNavigation(): PHNavigation$1;
|
|
766
|
+
/** The current pathname as the navigation sees it, base path included. */
|
|
767
|
+
export declare function getCurrentPathname(): string;
|
|
768
|
+
/** Opens `target`; without `search`, a target already open is left alone. */
|
|
769
|
+
export declare function openTarget(target: PHNavigationTarget$1 | undefined, options?: PHNavigateOptions$1): void;
|
|
770
|
+
/** Opens `target` through `navigation`, unless it is open already. */
|
|
771
|
+
export declare function openTargetWith(navigation: PHNavigation$1, target: PHNavigationTarget$1 | undefined, options?: PHNavigateOptions$1): void;
|
|
772
|
+
/** Asks the host navigation to warm `target`; a no-op without one. */
|
|
773
|
+
export declare function preloadTarget(target: PHNavigationTarget$1 | undefined): void;
|
|
774
|
+
/** The href `target` opens at through `navigation`, base path included. */
|
|
775
|
+
export declare function getTargetHref(target: PHNavigationTarget$1 | undefined, navigation?: PHNavigation$1): string;
|
|
776
|
+
export declare function resolveSearchUpdate(prev: Record<string, string>, update: SearchParamsUpdate$1): Record<string, string>;
|
|
777
|
+
/** Rewrites the current query params through the app store's navigation. */
|
|
778
|
+
export declare function setSearchParams(update: SearchParamsUpdate$1, options?: {
|
|
779
|
+
replace?: boolean;
|
|
780
|
+
}): void;
|
|
781
|
+
//#endregion
|
|
782
|
+
//#region src/hooks/url-state.d.ts
|
|
783
|
+
/** The nearest store's navigation, else the bound store's, else the browser's.
|
|
784
|
+
* Hosts set it once, so hook order holds. */
|
|
785
|
+
export declare function usePHNavigation(): PHNavigation$1;
|
|
786
|
+
/** The current query params. */
|
|
787
|
+
export declare function useSearchParams(): Record<string, string>;
|
|
788
|
+
/** Sets query params: an object merges into them, a function returns them all. */
|
|
789
|
+
export declare function useSetSearchParams(): SetSearchParams$1;
|
|
790
|
+
//#endregion
|
|
689
791
|
//#region src/hooks/selected-drive.d.ts
|
|
690
792
|
/** Returns the selected drive id */
|
|
691
793
|
export declare const useSelectedDriveId: () => string | undefined;
|
|
692
794
|
/** Sets the selected drive id */
|
|
693
795
|
export declare const setSelectedDriveId: (value: string | undefined) => void;
|
|
694
|
-
/** Adds an event handler for the selected drive id
|
|
796
|
+
/** Adds an event handler for the selected drive id
|
|
797
|
+
* @deprecated `ph:setSelectedDriveId` bypasses the URL; use `setSelectedDrive`. */
|
|
695
798
|
export declare const addSelectedDriveIdEventHandler: () => void;
|
|
696
799
|
/** Returns the selected drive */
|
|
697
800
|
export declare function useSelectedDrive(): [DocumentDriveDocument, DocumentDispatch$1<DocumentDriveAction>];
|
|
698
801
|
/** Returns the selected drive, or undefined if no drive is selected */
|
|
699
802
|
export declare function useSelectedDriveSafe(): [DocumentDriveDocument, DocumentDispatch$1<DocumentDriveAction>] | readonly [undefined, undefined];
|
|
700
|
-
|
|
701
|
-
|
|
803
|
+
type DriveRef = string | DocumentDriveDocument | undefined;
|
|
804
|
+
/** Selects a drive in the app's store; inside a scoped store, use
|
|
805
|
+
* `useSetSelectedDrive`. */
|
|
806
|
+
export declare function setSelectedDrive(driveOrDriveSlug: DriveRef): void;
|
|
807
|
+
/** `setSelectedDrive` for the store in context, e.g. a scoped editor's. */
|
|
808
|
+
export declare function useSetSelectedDrive(): (drive: DriveRef) => void;
|
|
809
|
+
/** Warms a drive's view before it is opened, e.g. on hover. */
|
|
810
|
+
export declare function preloadDrive(drive: DocumentDriveDocument | undefined): void;
|
|
811
|
+
/** `preloadDrive` for the store in context. */
|
|
812
|
+
export declare function usePreloadDrive(): (drive: DocumentDriveDocument | undefined) => void;
|
|
702
813
|
//#endregion
|
|
703
814
|
//#region src/hooks/selected-folder.d.ts
|
|
704
815
|
/** Returns the selected folder. */
|
|
705
816
|
export declare function useSelectedFolder(): FolderNode | undefined;
|
|
706
817
|
//#endregion
|
|
707
818
|
//#region src/hooks/set-selected-node.d.ts
|
|
819
|
+
/** Sets the selected node id without touching the URL. */
|
|
820
|
+
export declare const setSelectedNodeId: (value: string | undefined) => void;
|
|
821
|
+
/** @deprecated `ph:setSelectedNodeId` bypasses the URL; use `setSelectedNode`. */
|
|
708
822
|
export declare const addSelectedNodeIdEventHandler: () => void;
|
|
709
|
-
|
|
710
|
-
|
|
823
|
+
type NodeRef = Node | string | undefined;
|
|
824
|
+
/** Sets the selected node (file or folder) of the app's store; `search` sets
|
|
825
|
+
* the params it opens with. Inside a scoped store, use `useSetSelectedNode`. */
|
|
826
|
+
export declare function setSelectedNode(node: NodeRef, options?: PHNavigateOptions$1): void;
|
|
827
|
+
/** `setSelectedNode` for the store in context, e.g. a scoped editor's. */
|
|
828
|
+
export declare function useSetSelectedNode(): (node: NodeRef, options?: PHNavigateOptions$1) => void;
|
|
829
|
+
/** Opens a node, or with `undefined` its drive, in the store in context. */
|
|
830
|
+
export declare const useOpenNode: () => (node: Node | undefined, options?: PHNavigateOptions$1) => void;
|
|
831
|
+
/** Where a node of `store`'s open drive navigates to. */
|
|
832
|
+
export declare function getNodeTargetIn(store: PHStore | undefined, node: Node): PHNavigationTarget$1 | undefined;
|
|
833
|
+
/** Where a node of the open drive navigates to. */
|
|
834
|
+
export declare function getNodeTarget(node: Node | undefined): PHNavigationTarget$1 | undefined;
|
|
835
|
+
/** Warms a node's view before it is opened, e.g. on hover. */
|
|
836
|
+
export declare function preloadNode(node: Node | undefined): void;
|
|
837
|
+
/** `preloadNode` for the store in context. */
|
|
838
|
+
export declare function usePreloadNode(): (node: Node | undefined) => void;
|
|
711
839
|
export declare function addResetSelectedNodeEventHandler(): void;
|
|
712
|
-
|
|
840
|
+
//#endregion
|
|
841
|
+
//#region src/hooks/sync-selection.d.ts
|
|
842
|
+
/** Applies a path's selection without writing the URL; idempotent.
|
|
843
|
+
* @deprecated Set the store's `navigation`; its route loaders write the selection. */
|
|
844
|
+
export declare function syncSelectionFromPath(pathname?: string): void;
|
|
845
|
+
/** Syncs the selection on back/forward when no host navigation is set.
|
|
846
|
+
* @deprecated Set the store's `navigation`; its router handles back/forward. */
|
|
847
|
+
export declare function addSyncSelectionOnPopStateEventHandler(): void;
|
|
848
|
+
/** @deprecated Set the store's `navigation`; its router handles back/forward. */
|
|
849
|
+
export declare const addSetSelectedDriveOnPopStateEventHandler: typeof addSyncSelectionOnPopStateEventHandler;
|
|
850
|
+
/** @deprecated Set the store's `navigation`; its router handles back/forward. */
|
|
851
|
+
export declare const addSetSelectedNodeOnPopStateEventHandler: typeof addSyncSelectionOnPopStateEventHandler;
|
|
713
852
|
//#endregion
|
|
714
853
|
//#region src/hooks/selected-node.d.ts
|
|
715
854
|
/** Returns the selected node. */
|
|
@@ -940,6 +1079,26 @@ export declare function onVetraPackageManager(callback: (packageManager: IPackag
|
|
|
940
1079
|
/** Sets the Vetra package manager and registers its packages */
|
|
941
1080
|
export declare function setVetraPackageManager(packageManager: IPackageManager): void;
|
|
942
1081
|
//#endregion
|
|
1082
|
+
//#region src/hooks/close-node.d.ts
|
|
1083
|
+
/** Leaves a node's view: back to the entry it was opened from, past entries
|
|
1084
|
+
* pushed inside it; else, e.g. after a deep link, to its parent in place. */
|
|
1085
|
+
export declare function useCloseNode(nodeId: string | null | undefined): () => void;
|
|
1086
|
+
//#endregion
|
|
1087
|
+
//#region src/hooks/link-props.d.ts
|
|
1088
|
+
type ClickLike = Pick<MouseEvent, "button" | "metaKey" | "ctrlKey" | "shiftKey" | "altKey" | "defaultPrevented" | "preventDefault">;
|
|
1089
|
+
/** A plain primary click; modified and other-button clicks stay the browser's. */
|
|
1090
|
+
export declare function isPlainClick(event: ClickLike): boolean;
|
|
1091
|
+
export type LinkProps = {
|
|
1092
|
+
href: string;
|
|
1093
|
+
onClick: (event: ClickLike) => void;
|
|
1094
|
+
onMouseEnter: () => void;
|
|
1095
|
+
onFocus: () => void;
|
|
1096
|
+
"aria-current"?: "page";
|
|
1097
|
+
};
|
|
1098
|
+
/** Props for an `<a>` that opens `target` in the app on a plain click, and
|
|
1099
|
+
* leaves new tabs and windows to the browser; acts on the store in context. */
|
|
1100
|
+
export declare function useLinkProps(target: PHNavigationTarget$1 | undefined, open?: () => void): LinkProps;
|
|
1101
|
+
//#endregion
|
|
943
1102
|
//#region src/hooks/attachment-progress.d.ts
|
|
944
1103
|
/**
|
|
945
1104
|
* Progress in both units. `percent` is the house unit (0-100, matching
|
|
@@ -1066,6 +1225,64 @@ export type RefreshReactorDataConfig = {
|
|
|
1066
1225
|
export declare const refreshReactorData: (reactor: IReactorClient$1, immediate?: boolean) => Promise<void>;
|
|
1067
1226
|
export declare const refreshReactorDataClient: (reactor: IReactorClient$1 | undefined, immediate?: boolean) => Promise<void>;
|
|
1068
1227
|
//#endregion
|
|
1228
|
+
//#region src/routing/drive-arrivals.d.ts
|
|
1229
|
+
/** Drives that may still arrive, e.g. while the first sync runs. */
|
|
1230
|
+
export type DriveArrivals = {
|
|
1231
|
+
isPending(): boolean;
|
|
1232
|
+
/** Whether more of `driveId`'s content may arrive: its remote's first sync. */
|
|
1233
|
+
isDrivePending(driveId: string): boolean;
|
|
1234
|
+
/** Calls `listener` whenever the drives or `isPending()` may have changed. */
|
|
1235
|
+
subscribe(listener: () => void): () => void;
|
|
1236
|
+
};
|
|
1237
|
+
/** Counts a background drive addition as pending until it settles. */
|
|
1238
|
+
export declare function trackDriveArrival<T>(promise: Promise<T>): Promise<T>;
|
|
1239
|
+
/** Resolves once `store.drives` lists `driveId`, or after `maxWaitMs`: a
|
|
1240
|
+
* finished first pull does not mean the drive is listed yet. */
|
|
1241
|
+
export declare function untilDriveListed(store: PHStore, driveId: string, maxWaitMs?: number): Promise<void>;
|
|
1242
|
+
/** Drives still on their way into `store`: being added or first syncing. */
|
|
1243
|
+
export declare function createDriveArrivals(store: PHStore): DriveArrivals;
|
|
1244
|
+
//#endregion
|
|
1245
|
+
//#region src/routing/resolve-drive-route.d.ts
|
|
1246
|
+
export type DriveRouteResult = {
|
|
1247
|
+
kind: "drive";
|
|
1248
|
+
driveId: string;
|
|
1249
|
+
nodeId?: string;
|
|
1250
|
+
} | {
|
|
1251
|
+
kind: "drive-not-found";
|
|
1252
|
+
} | {
|
|
1253
|
+
kind: "node-not-found";
|
|
1254
|
+
driveId: string;
|
|
1255
|
+
};
|
|
1256
|
+
export type ResolveDriveRouteOptions = {
|
|
1257
|
+
store: PHStore;
|
|
1258
|
+
/** Without it, a missing drive is never waited for. */
|
|
1259
|
+
arrivals?: DriveArrivals;
|
|
1260
|
+
driveSlug: string;
|
|
1261
|
+
nodeSlug?: string;
|
|
1262
|
+
signal: AbortSignal;
|
|
1263
|
+
/** A preload only uses what is already here. */
|
|
1264
|
+
preload?: boolean;
|
|
1265
|
+
};
|
|
1266
|
+
/** How long a navigation waits for its document and editor before it shows;
|
|
1267
|
+
* past it the view commits and renders them as they load. */
|
|
1268
|
+
export declare const PREFETCH_WAIT_MS = 3000;
|
|
1269
|
+
export declare const DRIVE_ARRIVAL_MAX_WAIT_MS = 15000;
|
|
1270
|
+
/** A listed drive by slug, id, or a `<name>-<id>` slug's trailing id. */
|
|
1271
|
+
export declare function findDriveBySlugOrId(store: PHStore, ref: string): DocumentDriveDocument | undefined;
|
|
1272
|
+
/** Resolves with `read()` once it is defined, nothing is still arriving, the
|
|
1273
|
+
* signal aborts or the cap passes. */
|
|
1274
|
+
export declare function waitForArrival<T>(read: () => T | undefined, arrivals: DriveArrivals | undefined, signal: AbortSignal, maxWaitMs?: number): Promise<T | undefined>;
|
|
1275
|
+
/** Asks the reactor directly: a just-created drive may not be listed yet. */
|
|
1276
|
+
export declare function fetchDrive(store: PHStore, ref: string, signal?: AbortSignal): Promise<DocumentDriveDocument | undefined>;
|
|
1277
|
+
/** Loads a drive's app module so its view renders without suspending;
|
|
1278
|
+
* undefined when it is already loaded, so a warm open waits on nothing. */
|
|
1279
|
+
export declare function preloadDriveApp(store: PHStore, drive: DocumentDriveDocument): Promise<undefined> | undefined;
|
|
1280
|
+
/** Warms a file node's document and its editor module. */
|
|
1281
|
+
export declare function prefetchDocument(store: PHStore, node: Node): Promise<void>;
|
|
1282
|
+
/** Resolves a drive route's slugs, waiting for drives that are still syncing,
|
|
1283
|
+
* and warms what the resolved view needs. */
|
|
1284
|
+
export declare function resolveDriveRoute(options: ResolveDriveRouteOptions): Promise<DriveRouteResult>;
|
|
1285
|
+
//#endregion
|
|
1069
1286
|
//#region src/registry/types.d.ts
|
|
1070
1287
|
interface PublishEvent {
|
|
1071
1288
|
packageName: string;
|
|
@@ -1366,6 +1583,8 @@ export type UISyncStatus = "INITIAL_SYNC" | "SUCCESS" | "CONFLICT" | "MISSING" |
|
|
|
1366
1583
|
export declare function getDrives(reactor: IReactorClient$1): Promise<DocumentDriveDocument[]>;
|
|
1367
1584
|
export declare function getSyncStatus(documentId: string, sharingType: SharingType): Promise<UISyncStatus | undefined>;
|
|
1368
1585
|
export declare function getSyncStatusSync(documentId: string, sharingType: SharingType): UISyncStatus | undefined;
|
|
1586
|
+
/** A drive's display name: the header's (renames set it), else its creation name. */
|
|
1587
|
+
export declare function getDriveName(drive: DocumentDriveDocument): string;
|
|
1369
1588
|
//#endregion
|
|
1370
1589
|
//#region src/utils/download-document.d.ts
|
|
1371
1590
|
declare function defaultHandleError(error: Error): void;
|
|
@@ -1448,10 +1667,16 @@ export declare function getDocumentUpgradePreview(document: PHDocument$1, regist
|
|
|
1448
1667
|
//#endregion
|
|
1449
1668
|
//#region src/utils/url.d.ts
|
|
1450
1669
|
export declare function resolveUrlPathname(path: string): string;
|
|
1451
|
-
/** Returns the
|
|
1670
|
+
/** Returns the path without a leading base path */
|
|
1452
1671
|
export declare function getPathWithoutBase(path: string): string;
|
|
1453
|
-
/** Makes a URL component for a drive.
|
|
1672
|
+
/** Makes a URL component for a drive.
|
|
1673
|
+
* @deprecated Open drives through the store's `navigation`; it builds the path. */
|
|
1454
1674
|
export declare function makeDriveUrlComponent(drive: DocumentDriveDocument | undefined): string;
|
|
1675
|
+
/** A drive's URL component: its slug, else its id, prefixed with the slugged
|
|
1676
|
+
* name as `<name>-<id>` when the id is opaque (a UUID or derived id). */
|
|
1677
|
+
export declare function makeDriveSlug(drive: DocumentDriveDocument): string;
|
|
1678
|
+
/** The drive a URL slug names: its own slug, its id, or `<name>-<id>`. */
|
|
1679
|
+
export declare function findDriveBySlug(drives: readonly DocumentDriveDocument[] | undefined, ref: string | undefined): DocumentDriveDocument | undefined;
|
|
1455
1680
|
/**
|
|
1456
1681
|
* Makes a URL component for a node: `<slugged name>-<id>`. The id is kept
|
|
1457
1682
|
* verbatim, since a v2-required id is case-sensitive base64url.
|
|
@@ -1467,6 +1692,7 @@ export declare function findUuid(input: string | undefined): string | undefined;
|
|
|
1467
1692
|
/** The v2-required document id a slug ends with, if any. */
|
|
1468
1693
|
export declare function findDerivedId(input: string | undefined): string | undefined;
|
|
1469
1694
|
export declare function extractNodeIdFromSlug(nodeSlug: string | undefined): string | undefined;
|
|
1695
|
+
/** @deprecated Route loaders resolve the node; use `extractNodeIdFromSlug`. */
|
|
1470
1696
|
export declare function extractNodeIdFromPath(path: string): string | undefined;
|
|
1471
1697
|
/** Extracts the drive slug from a path.
|
|
1472
1698
|
* Used for extracting drive ids from drive slugs in the URL.
|
|
@@ -1474,10 +1700,10 @@ export declare function extractNodeIdFromPath(path: string): string | undefined;
|
|
|
1474
1700
|
*/
|
|
1475
1701
|
export declare function extractDriveSlugFromPath(path: string): string;
|
|
1476
1702
|
export declare function extractDriveIdFromSlug(driveSlug: string | undefined): string | undefined;
|
|
1703
|
+
/** @deprecated Route loaders resolve the drive; use `extractDriveIdFromSlug`. */
|
|
1477
1704
|
export declare function extractDriveIdFromPath(path: string): string | undefined;
|
|
1478
|
-
/**
|
|
1479
|
-
*
|
|
1480
|
-
*/
|
|
1705
|
+
/** Creates a URL string with the given pathname, keeping the query string.
|
|
1706
|
+
* @deprecated The store's `navigation` keeps global params across navigations. */
|
|
1481
1707
|
export declare function createUrlWithPreservedParams(pathname: string): string;
|
|
1482
1708
|
//#endregion
|
|
1483
1709
|
//#region src/utils/user.d.ts
|
|
@@ -1489,6 +1715,6 @@ export declare function getUserPermissions(): {
|
|
|
1489
1715
|
//#region src/utils/validate-document.d.ts
|
|
1490
1716
|
export declare const validateDocument: (document: PHDocument$1) => ValidationError[];
|
|
1491
1717
|
//#endregion
|
|
1492
|
-
export { type AddPHGlobalEventHandler, BatchJobFailedError, BearerTokenProvider, type BrowserReactorClientModule, type BrowserReactorModule, type BulkImportJob, CREDENTIAL_SCHEMA_EIP712_TYPE, CREDENTIAL_SUBJECT_TYPE, CREDENTIAL_TYPES, ChannelScheme, ChevronDownIcon, type ConflictInfo, type ConflictResolution, type ConflictStrategy, ConnectionParams, type ConnectionState, type ConnectionStateSnapshot, CopyIcon, CreateStoreOptions, DEFAULT_DRIVE_ID, DEFAULT_SWITCHBOARD_URL, DOMAIN_TYPE, type Database, DisconnectIcon, type DiscoveryEvent, type DiscoveryEventListener, DispatchFn, DocumentCache, type RemoteDocumentChangeEvent as DocumentChangeEvent, type DocumentChangeListener, DocumentChangeType, DocumentChangesEventPayload, DocumentChangesSubscriptionOptions, type DocumentDispatch, DocumentIntegrityService, DocumentOperationsResult, DocumentOperationsState, type DocumentRefetchState, type DocumentTypeIcon, DraggingNode, DriveCollectionId, DriveIdCall, type DriveInfo, type FailedInstallation, type FailedInstallationReason, type FileUploadProgress, type FileUploadProgressCallback, type FolderZipResult, type FulfilledPromise, type FullPHGlobalConfig, GetDocumentQueryFields, GetDocumentQueryResult, type GetDocumentResult, type GetDocumentWithOperationsResult, type GetOperationsResult, GqlRequestChannel, type GraphQLClientDocumentEvent, type GraphQLClientDocumentsEvent, type GraphQLClientWindowEvents, type GraphQLDocumentEventOperationName, type GraphQLDocumentEvents, type GraphQLDocumentEventsOperationName, type GraphQLDocumentsEvents, GraphQLOperationNotSupportedError, GraphQLReactorClient, GraphQLReactorClientOptions, GraphQLReactorProvider, GraphQLReactorProviderProps, GraphQLRequestOptions, GraphQLWrongBackendError, type IChannel, IDLE_OPERATIONS_ENTRY, IDLE_REFETCH_STATE, type IDocumentCache, type IDocumentModelLoader, type IOperationCache, type IPackageDiscoveryService, type IPackageListerUnsubscribe, type IPackageManager, type IPackagesListener, type IPeerAgreement, type IProcessor, type IProcessorHostModule, type IProcessorHostModuleBase, type IQueue, type IReactorBrowserClient, type IReactorClient, type IReactorProcessorHostModule, type IRelationalDb, type IRemoteClient, type IRemoteController, ISSUER_TYPE, InMemoryQueue, IntervalPollTimer, type Job, type JwtHandler, type KeyframeValidationIssue, type LOADING, type MergeHandler, MutateDocumentWithOperationsDocument, MutateDocumentWithOperationsResult, MutateDocumentWithOperationsVariables, type NodeKind, type OperationWithContext, type OperationsCacheEntry, type PHAnalyticsGlobalConfig, type PHAppConfig, type PHAppConfigHooks, type PHAppConfigKey, type PHAppConfigSetters, type PHCommonGlobalConfig, type PHDocumentEditorConfig, type PHDocumentEditorConfigHooks, type PHDocumentEditorConfigKey, type PHDocumentEditorConfigSetters, type PHDrivesGlobalConfig, type PHGlobal, type PHGlobalConfig, type PHGlobalConfigHooks, type PHGlobalConfigHooksForKey, type PHGlobalConfigKey, type PHGlobalConfigSetters, type PHGlobalConfigSettersForKey, type PHGlobalEventHandlerAdders, type PHGlobalKey, type PHGlobalValue, type PHModal, type PHProcessorsGlobalConfig, type PHRelationalProcessorsGlobalConfig, type PHRenownGlobalConfig, type PHSentryGlobalConfig, type PHToastFn, type PHToastOptions, type PHToastType, type PackageManagerInstallResult, type ParsedDriveUrl, type PendingInstallation, PollBehavior, type ProcessorApp, type ProcessorFactory, type ProcessorFactoryBuilder, type ProcessorFilter, type ProcessorRecord, type PromiseState, type PromiseWithState, PropagationMode, type PublishEvent, type PushResult, QueryCallbackReturnType, REACTOR_SCHEMA, RENOWN_CHAIN_ID, RENOWN_INITIAL_ANONYMOUS, RENOWN_INITIAL_UNKNOWN, RENOWN_NETWORK_ID, RENOWN_RETURN_URL_STRIPPED_PARAMS, RENOWN_URL, ReactorBuilder, ReactorClientBuilder, type ReactorFeatureFlags, type ReactorGraphQLClient, ReactorOperationFieldsFragmentDoc, type RebuildResult, type RejectedPromise, RelationalDbOptions, RelationalDbProcessor, RelationalDbWithLive, type Remote, type RemoteControllerGraphQLClient, type RemoteControllerOptions, type RemoteDocumentControllerWith, type RemoteDocumentData, type RemoteFilter, type RemoteMeta, type RemoteOperation, type RemoteOperationResultPage, type RemotePeer, Renown, RenownAuth, RenownAuthAsync, RenownAuthButton, type RenownAuthButtonProps, RenownAuthResolution, RenownAuthStatus, type RenownInitOptions, type RenownInitialAuth, RenownInitialUserProvider, type RenownInitialUserProviderProps, RenownLoginButton, type RenownLoginButtonProps, type RenownLoginMethod, RenownLogo, type RenownProps, RenownProvider, type RenownProviderProps, type RenownSessionCookieOptions, type RenownSessionCookieState, RenownUserButton, type RenownUserButtonMenuItem, type RenownUserButtonProps, RenownWalletProvider, type RenownWalletProviderProps, RevisionsListSelection, type RunDocumentOptions, type SdkFunctionWrapper, type SetEvent, type SetPHGlobalValue, type SignerConfig, type SnapshotValidationIssue, SpinnerIcon, StaticPackageManager, SubgraphSdkFactory, SubgraphSdkRegistry, type SyncHold, type SyncOperation, SyncOperationStatus, type SyncStatus, type TStateSchemaZodObject, type TimelineBarItem, type TimelineDividerItem, type TimelineItem, type TrackedAction, TypedGraphQLDocument, UseDispatchResult, UseDocumentOperationsOptions, type UseOnDropFile, type UsePHGlobalValue, UserIcon, VERIFIABLE_CREDENTIAL_EIP712_TYPE, type ValidationResult, type WorkerReactorClientModule, type WorkerReactorModule, addAttachmentServiceEventHandler, addDocumentCacheEventHandler, addDraggingNodeEventHandler, addFullReactorClientEventHandler, addPromiseState, addReactorClientEventHandler, addReactorClientModuleEventHandler, addRenownEventHandler, ambientRenownTokenProvider, baseDocumentModels, baseDocumentModelsMap, createAnalyticsStore, createClient, createProcessorQuery, describeGraphQLDocument, driveIdFromUrl, ensurePHEventHandlers, findIsServableOverGraphQL, getAnalyticsStore, getFullReactorClient, graphqlDocumentEvents, graphqlDocumentsEvents, graphqlEventsToSyncDrive, initConnectCrypto, initRenownCrypto, isAuthRefusalClose, isDriveAuthError, isGraphQLReactorClient, isOperationCache, isoStringFromDateTime, login, logout, makeAuthConnectionParams, makeAuthMiddleware, openRenown, packageFromDocumentModels, parseDriveUrl, phDocumentFromGetDocument, phDocumentFromMutation, prepareSignedActions, readPromiseState, resolveDocumentModelModule, revisionMapFromRevisionsList, setAttachmentService, setDocumentCache, setFullReactorClient, setReactorClient, setReactorClientModule, setRenown, signStampedAction, stampAction, startDocumentChangesSubscription, subgraphUrlFromGraphqlUrl, subscriptionsUrlFromGraphqlUrl, useAttachmentService, useDatabase, useDid, useDispatch, useDocument, useDocumentCache, useDocumentModelModuleById, useDocumentModelModules, useDocumentOperations, useDocumentSafe, useDocuments, useDragNode, useDropNode, useGetDocument, useGetDocumentAsync, useGetDocuments, useLoginStatus, useModelRegistry, usePGlite, useReactorClient, useReactorClientModule, useRelationalDb, useRelationalQuery, useRelationalQueryOptions, useRenown, useRenownAuth, useRenownAuthAsync, useRenownInit, useRenownInitialAuth, useRenownInitialUser, useRenownLoginMethods, useRenownSessionCookie, useRenownSessionSynced, useRenownWalletAdapter, useSwitchboardClient, useSync, useSyncList, useUser, viewFilterInputFromViewFilter };
|
|
1718
|
+
export { type AddPHGlobalEventHandler, BatchJobFailedError, BearerTokenProvider, type BrowserReactorClientModule, type BrowserReactorModule, type BulkImportJob, CREDENTIAL_SCHEMA_EIP712_TYPE, CREDENTIAL_SUBJECT_TYPE, CREDENTIAL_TYPES, ChannelScheme, ChevronDownIcon, type ConflictInfo, type ConflictResolution, type ConflictStrategy, ConnectionParams, type ConnectionState, type ConnectionStateSnapshot, CopyIcon, CreateStoreOptions, DEFAULT_DRIVE_ID, DEFAULT_SWITCHBOARD_URL, DOMAIN_TYPE, type Database, DisconnectIcon, type DiscoveryEvent, type DiscoveryEventListener, DispatchFn, DocumentCache, type RemoteDocumentChangeEvent as DocumentChangeEvent, type DocumentChangeListener, DocumentChangeType, DocumentChangesEventPayload, DocumentChangesSubscriptionOptions, type DocumentDispatch, DocumentIntegrityService, DocumentOperationsResult, DocumentOperationsState, type DocumentRefetchState, type DocumentTypeIcon, DraggingNode, DriveCollectionId, DriveIdCall, type DriveInfo, type FailedInstallation, type FailedInstallationReason, type FileUploadProgress, type FileUploadProgressCallback, type FolderZipResult, type FulfilledPromise, type FullPHGlobalConfig, GetDocumentQueryFields, GetDocumentQueryResult, type GetDocumentResult, type GetDocumentWithOperationsResult, type GetOperationsResult, GqlRequestChannel, type GraphQLClientDocumentEvent, type GraphQLClientDocumentsEvent, type GraphQLClientWindowEvents, type GraphQLDocumentEventOperationName, type GraphQLDocumentEvents, type GraphQLDocumentEventsOperationName, type GraphQLDocumentsEvents, GraphQLOperationNotSupportedError, GraphQLReactorClient, GraphQLReactorClientOptions, GraphQLReactorProvider, GraphQLReactorProviderProps, GraphQLRequestOptions, GraphQLWrongBackendError, type IChannel, IDLE_OPERATIONS_ENTRY, IDLE_REFETCH_STATE, type IDocumentCache, type IDocumentModelLoader, type IOperationCache, type IPackageDiscoveryService, type IPackageListerUnsubscribe, type IPackageManager, type IPackagesListener, type IPeerAgreement, type IProcessor, type IProcessorHostModule, type IProcessorHostModuleBase, type IQueue, type IReactorBrowserClient, type IReactorClient, type IReactorProcessorHostModule, type IRelationalDb, type IRemoteClient, type IRemoteController, ISSUER_TYPE, InMemoryQueue, IntervalPollTimer, type Job, type JwtHandler, type KeyframeValidationIssue, type LOADING, type MergeHandler, MutateDocumentWithOperationsDocument, MutateDocumentWithOperationsResult, MutateDocumentWithOperationsVariables, type NodeKind, type OperationWithContext, type OperationsCacheEntry, type PHAnalyticsGlobalConfig, type PHAppConfig, type PHAppConfigHooks, type PHAppConfigKey, type PHAppConfigSetters, type PHCommonGlobalConfig, type PHDocumentEditorConfig, type PHDocumentEditorConfigHooks, type PHDocumentEditorConfigKey, type PHDocumentEditorConfigSetters, type PHDriveTarget, type PHDrivesGlobalConfig, type PHGlobal, type PHGlobalConfig, type PHGlobalConfigHooks, type PHGlobalConfigHooksForKey, type PHGlobalConfigKey, type PHGlobalConfigSetters, type PHGlobalConfigSettersForKey, type PHGlobalEventHandlerAdders, type PHGlobalKey, type PHGlobalValue, type PHModal, type PHNavigateOptions, type PHNavigation, type PHNavigationTarget, type PHProcessorsGlobalConfig, type PHRelationalProcessorsGlobalConfig, type PHRenownGlobalConfig, type PHSearchUpdate, type PHSentryGlobalConfig, type PHSettingsTarget, type PHToastFn, type PHToastOptions, type PHToastType, type PackageManagerInstallResult, type ParsedDriveUrl, type PendingInstallation, PollBehavior, type ProcessorApp, type ProcessorFactory, type ProcessorFactoryBuilder, type ProcessorFilter, type ProcessorRecord, type PromiseState, type PromiseWithState, PropagationMode, type PublishEvent, type PushResult, QueryCallbackReturnType, REACTOR_SCHEMA, RENOWN_CHAIN_ID, RENOWN_INITIAL_ANONYMOUS, RENOWN_INITIAL_UNKNOWN, RENOWN_NETWORK_ID, RENOWN_RETURN_URL_STRIPPED_PARAMS, RENOWN_URL, ReactorBuilder, ReactorClientBuilder, type ReactorFeatureFlags, type ReactorGraphQLClient, ReactorOperationFieldsFragmentDoc, type RebuildResult, type RejectedPromise, RelationalDbOptions, RelationalDbProcessor, RelationalDbWithLive, type Remote, type RemoteControllerGraphQLClient, type RemoteControllerOptions, type RemoteDocumentControllerWith, type RemoteDocumentData, type RemoteFilter, type RemoteMeta, type RemoteOperation, type RemoteOperationResultPage, type RemotePeer, Renown, RenownAuth, RenownAuthAsync, RenownAuthButton, type RenownAuthButtonProps, RenownAuthResolution, RenownAuthStatus, type RenownInitOptions, type RenownInitialAuth, RenownInitialUserProvider, type RenownInitialUserProviderProps, RenownLoginButton, type RenownLoginButtonProps, type RenownLoginMethod, RenownLogo, type RenownProps, RenownProvider, type RenownProviderProps, type RenownSessionCookieOptions, type RenownSessionCookieState, RenownUserButton, type RenownUserButtonMenuItem, type RenownUserButtonProps, RenownWalletProvider, type RenownWalletProviderProps, RevisionsListSelection, type RunDocumentOptions, type SdkFunctionWrapper, type SearchParamsUpdate, type SetEvent, type SetPHGlobalValue, type SetSearchParams, type SignerConfig, type SnapshotValidationIssue, SpinnerIcon, StaticPackageManager, SubgraphSdkFactory, SubgraphSdkRegistry, type SyncHold, type SyncOperation, SyncOperationStatus, type SyncStatus, type TStateSchemaZodObject, type TimelineBarItem, type TimelineDividerItem, type TimelineItem, type TrackedAction, TypedGraphQLDocument, UseDispatchResult, UseDocumentOperationsOptions, type UseOnDropFile, type UsePHGlobalValue, UserIcon, VERIFIABLE_CREDENTIAL_EIP712_TYPE, type ValidationResult, type WorkerReactorClientModule, type WorkerReactorModule, addAttachmentServiceEventHandler, addDocumentCacheEventHandler, addDraggingNodeEventHandler, addFullReactorClientEventHandler, addPromiseState, addReactorClientEventHandler, addReactorClientModuleEventHandler, addRenownEventHandler, ambientRenownTokenProvider, baseDocumentModels, baseDocumentModelsMap, createAnalyticsStore, createClient, createProcessorQuery, describeGraphQLDocument, driveIdFromUrl, ensurePHEventHandlers, findIsServableOverGraphQL, getAnalyticsStore, getFullReactorClient, graphqlDocumentEvents, graphqlDocumentsEvents, graphqlEventsToSyncDrive, initConnectCrypto, initRenownCrypto, isAuthRefusalClose, isDriveAuthError, isGraphQLReactorClient, isOperationCache, isoStringFromDateTime, login, logout, makeAuthConnectionParams, makeAuthMiddleware, openRenown, packageFromDocumentModels, parseDriveUrl, phDocumentFromGetDocument, phDocumentFromMutation, prepareSignedActions, readPromiseState, resolveDocumentModelModule, revisionMapFromRevisionsList, setAttachmentService, setDocumentCache, setFullReactorClient, setReactorClient, setReactorClientModule, setRenown, signStampedAction, stampAction, startDocumentChangesSubscription, subgraphUrlFromGraphqlUrl, subscriptionsUrlFromGraphqlUrl, useAttachmentService, useDatabase, useDid, useDispatch, useDocument, useDocumentCache, useDocumentModelModuleById, useDocumentModelModules, useDocumentOperations, useDocumentSafe, useDocuments, useDragNode, useDropNode, useGetDocument, useGetDocumentAsync, useGetDocuments, useLoginStatus, useModelRegistry, usePGlite, useReactorClient, useReactorClientModule, useRelationalDb, useRelationalQuery, useRelationalQueryOptions, useRenown, useRenownAuth, useRenownAuthAsync, useRenownInit, useRenownInitialAuth, useRenownInitialUser, useRenownLoginMethods, useRenownSessionCookie, useRenownSessionSynced, useRenownWalletAdapter, useSwitchboardClient, useSync, useSyncList, useUser, viewFilterInputFromViewFilter };
|
|
1493
1719
|
export {};
|
|
1494
1720
|
//# sourceMappingURL=index.d.ts.map
|