@powerhousedao/reactor-browser 6.1.0 → 6.2.0-dev.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -5,7 +5,7 @@ import { A as useLoginStatus, C as RENOWN_CHAIN_ID, D as addRenownEventHandler,
5
5
  import { n as useRelationalQuery, r as useRelationalDb, t as createProcessorQuery } from "./relational-4_LVwp8p.js";
6
6
  import { documentModelDocumentModelModule, logger } from "document-model";
7
7
  import { baseLoadFromInput, baseSaveToFileHandle, createPresignedHeader, createZip, documentModelDocumentType, generateId, replayDocument, setName, validateInitialState, validateModules, validateStateSchemaName } from "@powerhousedao/shared/document-model";
8
- import { DriveDocumentSchema, addFolder as addFolder$1, copyNode, driveCreateDocument, driveDocumentModelModule, generateNodesCopy, handleTargetNameCollisions, isFileNode, isFolderNode, moveNode, setAvailableOffline, setSharingType, updateNode } from "@powerhousedao/shared/document-drive";
8
+ import { DriveDocumentSchema, addFolder as addFolder$1, copyNode, driveCreateDocument, driveDocumentModelModule, generateNodesCopy, handleTargetNameCollisions, isFileNode, isFolderNode, moveNode, setAvailableOffline, setDriveIcon, setDriveName, setSharingType, updateNode } from "@powerhousedao/shared/document-drive";
9
9
  import { allPass, conditional, constant, filter, find, forEach, forEachObj, funnel, hasAtLeast, isArray, isDefined, isIncludedIn, isNot, isStrictEqual, isString, isTruthy, last, map, mapToObj, once, pipe, prop, split, unique } from "remeda";
10
10
  import { ChannelScheme, DocumentChangeType, DocumentChangeType as DocumentChangeType$1, DocumentIntegrityService, DuplicateManifestError, DuplicateModuleError, GqlRequestChannel, InMemoryQueue, IntervalPollTimer, ModuleNotFoundError, PollBehavior, PropagationMode as PropagationMode$1, REACTOR_SCHEMA, REACTOR_SCHEMA as REACTOR_SCHEMA$1, ReactorBuilder, ReactorClientBuilder, RelationalDbProcessor, SyncOperationStatus, SyncStatus, driveCollectionId, driveCollectionId as driveCollectionId$1, driveIdFromUrl, parseDriveUrl } from "@powerhousedao/reactor";
11
11
  import { reactorDriveDocumentModelModule } from "@powerhousedao/reactor-drive";
@@ -14,6 +14,7 @@ import { useCallback, useEffect, useMemo, useRef, useState, useSyncExternalStore
14
14
  import slug from "slug";
15
15
  import normalizeException from "normalize-exception";
16
16
  import * as lzString from "lz-string";
17
+ import { createAttachmentClient } from "@powerhousedao/reactor-attachments/client";
17
18
  //#region src/errors.ts
18
19
  var UnsupportedDocumentTypeError = class extends Error {
19
20
  constructor(documentType) {
@@ -621,6 +622,17 @@ async function setDriveSharingType(driveId, sharingType) {
621
622
  if (!reactorClient) throw new Error("ReactorClient not initialized");
622
623
  return await reactorClient.execute(driveId, "main", [setSharingType({ type: sharingType })]);
623
624
  }
625
+ async function setDriveMetadata(driveId, metadata) {
626
+ const { isAllowedToCreateDocuments } = getUserPermissions();
627
+ if (!isAllowedToCreateDocuments) throw new Error("User is not allowed to update drive metadata");
628
+ const reactorClient = window.ph?.reactorClient;
629
+ if (!reactorClient) throw new Error("ReactorClient not initialized");
630
+ const actions = [];
631
+ if (metadata.name) actions.push(setDriveName({ name: metadata.name }));
632
+ if (metadata.icon !== void 0 && metadata.icon !== null) actions.push(setDriveIcon({ icon: metadata.icon }));
633
+ if (actions.length === 0) return;
634
+ return await reactorClient.execute(driveId, "main", actions);
635
+ }
624
636
  //#endregion
625
637
  //#region src/constants.ts
626
638
  const DEFAULT_DRIVE_EDITOR_ID = "powerhouse/generic-drive-explorer";
@@ -1157,6 +1169,15 @@ const phGlobalConfigHooks = {
1157
1169
  ...nonUserConfigHooks
1158
1170
  };
1159
1171
  //#endregion
1172
+ //#region src/hooks/attachment-service.ts
1173
+ const attachmentServiceEventFunctions = makePHEventFunctions("attachmentService");
1174
+ /** Returns the attachment service from window.ph */
1175
+ const useAttachmentService = attachmentServiceEventFunctions.useValue;
1176
+ /** Sets the attachment service on window.ph */
1177
+ const setAttachmentService = attachmentServiceEventFunctions.setValue;
1178
+ /** Registers the attachmentService window event handler */
1179
+ const addAttachmentServiceEventHandler = attachmentServiceEventFunctions.addEventHandler;
1180
+ //#endregion
1160
1181
  //#region src/hooks/features.ts
1161
1182
  const featuresEventFunctions = makePHEventFunctions("features");
1162
1183
  const useFeatures = featuresEventFunctions.useValue;
@@ -1234,6 +1255,40 @@ const setDrives = drivesEventFunctions.setValue;
1234
1255
  /** Adds an event handler for the drives */
1235
1256
  const addDrivesEventHandler = drivesEventFunctions.addEventHandler;
1236
1257
  //#endregion
1258
+ //#region src/hooks/set-selected-node.ts
1259
+ const selectedNodeIdEventFunctions = makePHEventFunctions("selectedNodeId");
1260
+ const useSelectedNodeId = selectedNodeIdEventFunctions.useValue;
1261
+ const setSelectedNodeId = selectedNodeIdEventFunctions.setValue;
1262
+ const addSelectedNodeIdEventHandler = selectedNodeIdEventFunctions.addEventHandler;
1263
+ /** Sets the selected node (file or folder). */
1264
+ function setSelectedNode(nodeOrNodeSlug) {
1265
+ const nodeSlug = typeof nodeOrNodeSlug === "string" ? nodeOrNodeSlug : makeNodeSlug(nodeOrNodeSlug);
1266
+ setSelectedNodeId(extractNodeIdFromSlug(nodeSlug));
1267
+ const driveSlugFromPath = extractDriveSlugFromPath(window.location.pathname);
1268
+ if (!driveSlugFromPath) return;
1269
+ if (!nodeSlug) {
1270
+ const pathname = resolveUrlPathname(`/d/${driveSlugFromPath}`);
1271
+ if (pathname === window.location.pathname) return;
1272
+ window.history.pushState(null, "", createUrlWithPreservedParams(pathname));
1273
+ return;
1274
+ }
1275
+ const pathname = resolveUrlPathname(`/d/${driveSlugFromPath}/${nodeSlug}`);
1276
+ if (pathname === window.location.pathname) return;
1277
+ window.history.pushState(null, "", createUrlWithPreservedParams(pathname));
1278
+ }
1279
+ function addResetSelectedNodeEventHandler() {
1280
+ window.addEventListener("ph:selectedDriveIdUpdated", () => {
1281
+ setSelectedNodeId(void 0);
1282
+ });
1283
+ }
1284
+ function addSetSelectedNodeOnPopStateEventHandler() {
1285
+ window.addEventListener("popstate", () => {
1286
+ const pathname = window.location.pathname;
1287
+ const nodeSlug = extractNodeSlugFromPath(pathname);
1288
+ if (extractNodeIdFromSlug(nodeSlug) !== window.ph?.selectedNodeId) setSelectedNode(nodeSlug);
1289
+ });
1290
+ }
1291
+ //#endregion
1237
1292
  //#region src/hooks/selected-drive.ts
1238
1293
  const selectedDriveIdEventFunctions = makePHEventFunctions("selectedDriveId");
1239
1294
  /** Returns the selected drive id */
@@ -1258,7 +1313,14 @@ function useSelectedDriveSafe() {
1258
1313
  }
1259
1314
  function setSelectedDrive(driveOrDriveSlug) {
1260
1315
  const driveSlug = typeof driveOrDriveSlug === "string" ? driveOrDriveSlug : driveOrDriveSlug?.header.slug;
1261
- const driveId = (window.ph?.drives?.find((d) => d.header.slug === driveSlug))?.header.id;
1316
+ const drives = window.ph?.drives;
1317
+ const driveId = (typeof driveOrDriveSlug === "object" && driveOrDriveSlug !== null ? driveOrDriveSlug : drives?.find((d) => d.header.slug === driveSlug))?.header.id;
1318
+ if (!driveId && driveSlug && extractDriveSlugFromPath(window.location.pathname) === driveSlug) {
1319
+ if (window.ph?.selectedDriveId) setSelectedDriveId(void 0);
1320
+ deferDriveSelection(driveSlug);
1321
+ return;
1322
+ }
1323
+ cancelPendingDriveSelection();
1262
1324
  setSelectedDriveId(driveId);
1263
1325
  if (!driveId) {
1264
1326
  const pathname = resolveUrlPathname("/");
@@ -1270,6 +1332,58 @@ function setSelectedDrive(driveOrDriveSlug) {
1270
1332
  if (pathname === window.location.pathname) return;
1271
1333
  window.history.pushState(null, "", createUrlWithPreservedParams(pathname));
1272
1334
  }
1335
+ const DEFERRED_DRIVE_TICK_MS = 2e3;
1336
+ const DEFERRED_DRIVE_MAX_WAIT_MS = 15e3;
1337
+ function isInitialSyncInFlight() {
1338
+ const remotes = window.ph?.reactorClientModule?.reactorModule?.syncModule?.syncManager?.list();
1339
+ if (!remotes?.length) return false;
1340
+ return remotes.some((remote) => {
1341
+ try {
1342
+ const snapshot = remote.channel.getConnectionState();
1343
+ return snapshot.receivingPages || !snapshot.lastSuccessUtcMs && snapshot.state !== "error";
1344
+ } catch {
1345
+ return false;
1346
+ }
1347
+ });
1348
+ }
1349
+ let pendingHandler;
1350
+ let pendingTimeout;
1351
+ function cancelPendingDriveSelection() {
1352
+ if (pendingHandler) {
1353
+ window.removeEventListener("ph:drivesUpdated", pendingHandler);
1354
+ pendingHandler = void 0;
1355
+ }
1356
+ if (pendingTimeout) {
1357
+ clearTimeout(pendingTimeout);
1358
+ pendingTimeout = void 0;
1359
+ }
1360
+ }
1361
+ function deferDriveSelection(driveSlug) {
1362
+ cancelPendingDriveSelection();
1363
+ const nodeSlug = extractNodeSlugFromPath(window.location.pathname);
1364
+ const handler = () => {
1365
+ if (!window.ph?.drives?.find((d) => d.header.slug === driveSlug)) return;
1366
+ cancelPendingDriveSelection();
1367
+ setSelectedDrive(driveSlug);
1368
+ setSelectedNode(nodeSlug);
1369
+ };
1370
+ pendingHandler = handler;
1371
+ window.addEventListener("ph:drivesUpdated", handler);
1372
+ const deadline = Date.now() + DEFERRED_DRIVE_MAX_WAIT_MS;
1373
+ const scheduleTick = () => {
1374
+ pendingTimeout = setTimeout(() => {
1375
+ if (Date.now() < deadline && isInitialSyncInFlight()) {
1376
+ scheduleTick();
1377
+ return;
1378
+ }
1379
+ cancelPendingDriveSelection();
1380
+ const pathname = resolveUrlPathname("/");
1381
+ if (pathname === window.location.pathname) return;
1382
+ window.history.pushState(null, "", createUrlWithPreservedParams(pathname));
1383
+ }, DEFERRED_DRIVE_TICK_MS);
1384
+ };
1385
+ scheduleTick();
1386
+ }
1273
1387
  function addSetSelectedDriveOnPopStateEventHandler() {
1274
1388
  window.addEventListener("popstate", () => {
1275
1389
  const pathname = window.location.pathname;
@@ -1525,43 +1639,11 @@ function isDocumentModelDocument(document) {
1525
1639
  }
1526
1640
  //#endregion
1527
1641
  //#region src/hooks/selected-node.ts
1528
- const selectedNodeIdEventFunctions = makePHEventFunctions("selectedNodeId");
1529
- const useSelectedNodeId = selectedNodeIdEventFunctions.useValue;
1530
- const setSelectedNodeId = selectedNodeIdEventFunctions.setValue;
1531
- const addSelectedNodeIdEventHandler = selectedNodeIdEventFunctions.addEventHandler;
1532
1642
  /** Returns the selected node. */
1533
1643
  function useSelectedNode() {
1534
1644
  const selectedNodeId = useSelectedNodeId();
1535
1645
  return useNodesInSelectedDrive()?.find((n) => n.id === selectedNodeId);
1536
1646
  }
1537
- /** Sets the selected node (file or folder). */
1538
- function setSelectedNode(nodeOrNodeSlug) {
1539
- const nodeSlug = typeof nodeOrNodeSlug === "string" ? nodeOrNodeSlug : makeNodeSlug(nodeOrNodeSlug);
1540
- setSelectedNodeId(extractNodeIdFromSlug(nodeSlug));
1541
- const driveSlugFromPath = extractDriveSlugFromPath(window.location.pathname);
1542
- if (!driveSlugFromPath) return;
1543
- if (!nodeSlug) {
1544
- const pathname = resolveUrlPathname(`/d/${driveSlugFromPath}`);
1545
- if (pathname === window.location.pathname) return;
1546
- window.history.pushState(null, "", createUrlWithPreservedParams(pathname));
1547
- return;
1548
- }
1549
- const pathname = resolveUrlPathname(`/d/${driveSlugFromPath}/${nodeSlug}`);
1550
- if (pathname === window.location.pathname) return;
1551
- window.history.pushState(null, "", createUrlWithPreservedParams(pathname));
1552
- }
1553
- function addResetSelectedNodeEventHandler() {
1554
- window.addEventListener("ph:selectedDriveIdUpdated", () => {
1555
- setSelectedNodeId(void 0);
1556
- });
1557
- }
1558
- function addSetSelectedNodeOnPopStateEventHandler() {
1559
- window.addEventListener("popstate", () => {
1560
- const pathname = window.location.pathname;
1561
- const nodeSlug = extractNodeSlugFromPath(pathname);
1562
- if (nodeSlug !== window.ph?.selectedNodeId) setSelectedNode(nodeSlug);
1563
- });
1564
- }
1565
1647
  //#endregion
1566
1648
  //#region src/hooks/selected-timeline-item.ts
1567
1649
  const selectedTimelineItemEventFunctions = makePHEventFunctions("selectedTimelineItem");
@@ -1660,6 +1742,7 @@ const phGlobalEventHandlerRegisterFunctions = {
1660
1742
  ...commonGlobalEventHandlerFunctions,
1661
1743
  reactorClientModule: addReactorClientModuleEventHandler,
1662
1744
  reactorClient: addReactorClientEventHandler,
1745
+ attachmentService: addAttachmentServiceEventHandler,
1663
1746
  features: addFeaturesEventHandler,
1664
1747
  modal: addModalEventHandler,
1665
1748
  renown: addRenownEventHandler,
@@ -2787,6 +2870,61 @@ function useUserPermissions() {
2787
2870
  };
2788
2871
  }
2789
2872
  //#endregion
2873
+ //#region src/hooks/use-attachments.ts
2874
+ /** Returns an IAttachmentClient wrapping the current IAttachmentService, or undefined if none is set. */
2875
+ function useAttachments() {
2876
+ const service = useAttachmentService();
2877
+ return useMemo(() => service ? createAttachmentClient(service) : void 0, [service]);
2878
+ }
2879
+ /** Upload lifecycle status. progress is coarse (0 before/during, 1 on Done) because RemoteAttachmentUpload buffers the full body before issuing a single PUT. */
2880
+ let UploadStatus = /* @__PURE__ */ function(UploadStatus) {
2881
+ UploadStatus["None"] = "None";
2882
+ UploadStatus["Hashing"] = "Hashing";
2883
+ UploadStatus["Uploading"] = "Uploading";
2884
+ UploadStatus["Done"] = "Done";
2885
+ UploadStatus["Error"] = "Error";
2886
+ return UploadStatus;
2887
+ }({});
2888
+ /** Hook for managing the full attachment preprocess + upload lifecycle. preprocess and upload callbacks are stable (useCallback) and depend only on the current IAttachmentClient reference. */
2889
+ function useAttachmentUpload() {
2890
+ const [status, setStatus] = useState(UploadStatus.None);
2891
+ const [progress, setProgress] = useState(0);
2892
+ const [error, setError] = useState(void 0);
2893
+ const client = useAttachments();
2894
+ return {
2895
+ preprocess: useCallback(async (file) => {
2896
+ if (!client) throw new Error("AttachmentClient not available");
2897
+ setError(void 0);
2898
+ setStatus(UploadStatus.Hashing);
2899
+ try {
2900
+ return await client.preprocess(file);
2901
+ } catch (err) {
2902
+ setError(err instanceof Error ? err : new Error(String(err)));
2903
+ setStatus(UploadStatus.Error);
2904
+ throw err;
2905
+ }
2906
+ }, [client]),
2907
+ upload: useCallback(async (results) => {
2908
+ if (!client) throw new Error("AttachmentClient not available");
2909
+ setError(void 0);
2910
+ setStatus(UploadStatus.Uploading);
2911
+ setProgress(0);
2912
+ try {
2913
+ await client.reserve(results.options, (handle) => handle.send(results.stream()));
2914
+ } catch (err) {
2915
+ setError(err instanceof Error ? err : new Error(String(err)));
2916
+ setStatus(UploadStatus.Error);
2917
+ throw err;
2918
+ }
2919
+ setProgress(1);
2920
+ setStatus(UploadStatus.Done);
2921
+ }, [client]),
2922
+ status,
2923
+ progress,
2924
+ error
2925
+ };
2926
+ }
2927
+ //#endregion
2790
2928
  //#region src/pglite/drop.ts
2791
2929
  async function dropTablesInSchema(pg, schema) {
2792
2930
  await pg.exec(`
@@ -3657,6 +3795,6 @@ var BrowserLocalStorage = class extends BaseStorage {
3657
3795
  }
3658
3796
  };
3659
3797
  //#endregion
3660
- export { ActionTracker, BaseStorage, BrowserLocalStorage, COMMON_PACKAGE_ID, CREDENTIAL_SCHEMA_EIP712_TYPE, CREDENTIAL_SUBJECT_TYPE, CREDENTIAL_TYPES, ChannelScheme, ChevronDownIcon, ConflictError, CopyIcon, DEFAULT_DRIVE_EDITOR_ID, DEFAULT_DRIVE_ID, DEFAULT_SWITCHBOARD_URL, DOMAIN_TYPE, DisconnectIcon, DocumentCache, DocumentChangeType, DocumentIntegrityService, EDITOR_FILE_DROP_OPT_OUT_ATTR, GqlRequestChannel, GraphQLClientDocumentCache, ISSUER_TYPE, InMemoryQueue, IntervalPollTimer, PollBehavior, PropagationMode, REACTOR_SCHEMA, RENOWN_CHAIN_ID, RENOWN_NETWORK_ID, RENOWN_URL, ReactorBuilder, ReactorClientBuilder, RegistryClient, RelationalDbProcessor, RemoteClient, RemoteDocumentController, Renown, RenownAuthButton, RenownLoginButton, RenownLogo, RenownUserButton, SpinnerIcon, SyncOperationStatus, UserIcon, VERIFIABLE_CREDENTIAL_EIP712_TYPE, addAllowListEventHandler, addAllowedDocumentTypesEventHandler, addAnalyticsDatabaseNameEventHandler, addBasePathEventHandler, addCliVersionEventHandler, addDefaultDrivesUrlEventHandler, addDisabledEditorsEventHandler, addDocument, addDocumentCacheEventHandler, addDraggingNodeEventHandler, addDrive, addDrivesEventHandler, addDrivesPreserveStrategyEventHandler, addEnabledEditorsEventHandler, addFeaturesEventHandler, addFileUploadOperationsChunkSizeEventHandler, addFolder, addGaTrackingIdEventHandler, addGraphQLReactorClientEventHandler, addIsAddCloudDrivesEnabledEventHandler, addIsAddDriveEnabledEventHandler, addIsAddLocalDrivesEnabledEventHandler, addIsAddPublicDrivesEnabledEventHandler, addIsAnalyticsDatabaseWorkerEnabledEventHandler, addIsAnalyticsEnabledEventHandler, addIsAnalyticsExternalProcessorsEnabledEventHandler, addIsCloudDrivesEnabledEventHandler, addIsDeleteCloudDrivesEnabledEventHandler, addIsDeleteLocalDrivesEnabledEventHandler, addIsDeletePublicDrivesEnabledEventHandler, addIsDiffAnalyticsEnabledEventHandler, addIsDocumentModelSelectionSettingsEnabledEventHandler, addIsDragAndDropEnabledEventHandler, addIsDriveAnalyticsEnabledEventHandler, addIsEditorDebugModeEnabledEventHandler, addIsEditorReadModeEnabledEventHandler, addIsExternalControlsEnabledEventHandler, addIsExternalPackagesEnabledEventHandler, addIsExternalProcessorsEnabledEventHandler, addIsExternalRelationalProcessorsEnabledEventHandler, addIsLocalDrivesEnabledEventHandler, addIsPublicDrivesEnabledEventHandler, addIsRelationalProcessorsEnabledEventHandler, addIsSentryTracingEnabledEventHandler, addLoadingEventHandler, addLocalDrivesEnabledEventHandler, addLogLevelEventHandler, addModalEventHandler, addPHEventHandlers, addPackageDiscoveryServiceEventHandler, addPromiseState, addReactorClientEventHandler, addReactorClientModuleEventHandler, addRemoteDrive, addRenownChainIdEventHandler, addRenownEventHandler, addRenownNetworkIdEventHandler, addRenownUrlEventHandler, addRequiresHardRefreshEventHandler, addResetSelectedNodeEventHandler, addRevisionHistoryVisibleEventHandler, addRouterBasenameEventHandler, addSelectedDriveIdEventHandler, addSelectedNodeIdEventHandler, addSelectedTimelineItemEventHandler, addSelectedTimelineRevisionEventHandler, addSentryDsnEventHandler, addSentryEnvEventHandler, addSentryReleaseEventHandler, addSetSelectedDriveOnPopStateEventHandler, addSetSelectedNodeOnPopStateEventHandler, addStudioModeEventHandler, addToastEventHandler, addVersionCheckIntervalEventHandler, addVersionEventHandler, addVetraPackageManagerEventHandler, addWarnOutdatedAppEventHandler, baseDocumentModels, baseDocumentModelsMap, buildDocumentSubgraphQuery, buildDocumentSubgraphUrl, callEventHandlerRegisterFunctions, callGlobalSetterForKey, clearGlobal, closePHModal, commonGlobalEventHandlerFunctions, convertRemoteOperations, createAnalyticsStore, createClient, createProcessorQuery, createUrlWithPreservedParams, deleteDrive, deleteNode, deriveSystemUrl, dispatchActions, downloadDocument, driveCollectionId, driveIdFromUrl, dropAllReactorStorage, exportFile, extractDriveIdFromPath, extractDriveIdFromSlug, extractDriveSlugFromPath, extractNodeIdFromPath, extractNodeIdFromSlug, extractNodeSlugFromPath, findUuid, getAnalyticsStore, getDocumentGraphqlQuery, getDriveIdBySlug, getDrives, getGlobal, getPackages, getPackagesByDocumentType, getPathWithoutBase, getRevisionFromDate, getSlugFromDriveUrl, getSwitchboardGatewayUrlFromDriveUrl, getSyncStatus, getSyncStatusSync, getUserPermissions, graphqlDocumentEvents, graphqlDocumentsEvents, graphqlEventsToSyncDrive, hideRevisionHistory, identifierFromMutateDocumentOperationVariables, initConnectCrypto, initRenownCrypto, initTheme, isDocumentTypeSupported, isExternalControlsEnabledEventFunctions, isFileNodeKind, isFolderNodeKind, loading, login, logout, makeDriveUrlComponent, makeNodeSlug, makePHEventFunctions, openRenown, parseDriveUrl, phAppConfigHooks, phAppConfigSetters, phDocumentEditorConfigHooks, phDocumentEditorConfigSetters, phDocumentFromQuery, phDocumentsFromQuery, phGlobalConfigHooks, phGlobalConfigSetters, reactorGraphqlBatchFetchDocuments, reactorGraphqlCreateDocument, reactorGraphqlDeleteDocument, reactorGraphqlDeleteDocuments, reactorGraphqlFetchDocument, reactorGraphqlMutateDocument, readPromiseState, refreshReactorData, refreshReactorDataClient, renameDrive, renameDriveNode, resolveUrlPathname, setAllowList, setAllowedDocumentTypes, setAnalyticsDatabaseName, setBasePath, setCliVersion, setDefaultDrivesUrl, setDefaultPHGlobalConfig, setDisabledEditors, setDocumentCache, setDriveAvailableOffline, setDriveSharingType, setDrives, setDrivesPreserveStrategy, setEnabledEditors, setFeatures, setFileUploadOperationsChunkSize, setGaTrackingId, setGlobal, setGraphQLReactorClient, setIsAddCloudDrivesEnabled, setIsAddDriveEnabled, setIsAddLocalDrivesEnabled, setIsAddPublicDrivesEnabled, setIsAnalyticsDatabaseWorkerEnabled, setIsAnalyticsEnabled, setIsAnalyticsExternalProcessorsEnabled, setIsCloudDrivesEnabled, setIsDeleteCloudDrivesEnabled, setIsDeleteLocalDrivesEnabled, setIsDeletePublicDrivesEnabled, setIsDiffAnalyticsEnabled, setIsDocumentModelSelectionSettingsEnabled, setIsDragAndDropEnabled, setIsDriveAnalyticsEnabled, setIsEditorDebugModeEnabled, setIsEditorReadModeEnabled, setIsExternalControlsEnabled, setIsExternalPackagesEnabled, setIsExternalProcessorsEnabled, setIsExternalRelationalProcessorsEnabled, setIsLocalDrivesEnabled, setIsPublicDrivesEnabled, setIsRelationalProcessorsEnabled, setIsSentryTracingEnabled, setLoading, setLocalDrivesEnabled, setLogLevel, setPHAppConfig, setPHAppConfigByKey, setPHDocumentEditorConfig, setPHDocumentEditorConfigByKey, setPHGlobalConfig, setPHGlobalConfigByKey, setPHModal, setPHToast, setPackageDiscoveryService, setReactorClient, setReactorClientModule, setRenown, setRenownChainId, setRenownNetworkId, setRenownUrl, setRequiresHardRefresh, setRevisionHistoryVisible, setRouterBasename, setSelectedDrive, setSelectedDriveId, setSelectedNode, setSelectedTimelineItem, setSelectedTimelineRevision, setSentryDsn, setSentryEnv, setSentryRelease, setStudioMode, setVersion, setVersionCheckInterval, setVetraPackageManager, setWarnOutdatedApp, showCreateDocumentModal, showDeleteNodeModal, showPHModal, showRevisionHistory, sortNodesByName, trimTrailingSlash, truncateAllTables, useAllowList, useAllowedDocumentModelModules, useAllowedDocumentTypes, useAnalyticsDatabaseName, useAppModuleById, useAppModules, useBasePath, useCliVersion, useConnectionState, useConnectionStates, useDatabase, useDefaultAppModule, useDefaultDrivesUrl, useDid, useDisabledEditors, useDispatch, useDocument, useDocumentById, useDocumentCache, useDocumentModelModuleById, useDocumentModelModules, useDocumentOfType, useDocumentOperations, useDocumentSafe, useDocumentTypes, useDocumentTypesInSelectedDrive, useDocuments, useDocumentsByIds, useDocumentsInSelectedDrive, useDocumentsInSelectedFolder, useDownloadDocument, useDragNode, useDriveById, useDriveSystemInfo, useDrives, useDrivesPreserveStrategy, useDropFile, useDropNode, useEditorFileDrop, useEditorModuleById, useEditorModules, useEditorModulesForDocumentType, useEnabledEditors, useFallbackEditorModule, useFeatures, useFileNodesInSelectedDrive, useFileNodesInSelectedFolder, useFileUploadOperationsChunkSize, useFolderById, useFolderNodesInSelectedDrive, useFolderNodesInSelectedFolder, useGaTrackingId, useGetDocument, useGetDocumentAsync, useGetDocuments, useGetSwitchboardLink, useGraphQLReactorClient, useInitReactorGraphqlClient, useIsAddCloudDrivesEnabled, useIsAddDriveEnabled, useIsAddLocalDrivesEnabled, useIsAddPublicDrivesEnabled, useIsAnalyticsDatabaseWorkerEnabled, useIsAnalyticsEnabled, useIsAnalyticsExternalProcessorsEnabled, useIsCloudDrivesEnabled, useIsDeleteCloudDrivesEnabled, useIsDeleteLocalDrivesEnabled, useIsDeletePublicDrivesEnabled, useIsDiffAnalyticsEnabled, useIsDocumentModelSelectionSettingsEnabled, useIsDragAndDropEnabled, useIsDriveAnalyticsEnabled, useIsEditorDebugModeEnabled, useIsEditorReadModeEnabled, useIsExternalControlsEnabled, useIsExternalPackagesEnabled, useIsExternalProcessorsEnabled, useIsExternalRelationalProcessorsEnabled, useIsLocalDrivesEnabled, useIsPublicDrivesEnabled, useIsRelationalProcessorsEnabled, useIsSentryTracingEnabled, useLoading, useLocalDrivesEnabled, useLogLevel, useLoginStatus, useModelRegistry, useNodeActions, useNodeById, useNodeParentFolderById, useNodePathById, useNodesInSelectedDrive, useNodesInSelectedDriveOrFolder, useNodesInSelectedFolder, useOnDropFile, usePGlite, usePHAppConfigByKey, usePHDocumentEditorConfigByKey, usePHGlobalConfigByKey, usePHModal, usePHToast, usePackageDiscoveryService, useParentFolderForSelectedNode, useReactorClient, useReactorClientModule, useRelationalDb, useRelationalQuery, useRenown, useRenownAuth, useRenownChainId, useRenownInit, useRenownNetworkId, useRenownUrl, useRequiresHardRefresh, useResetPHGlobalConfig, useRevisionHistoryVisible, useRouterBasename, useSelectedDocument, useSelectedDocumentId, useSelectedDocumentOfType, useSelectedDocumentSafe, useSelectedDrive, useSelectedDriveId, useSelectedDriveSafe, useSelectedFolder, useSelectedNode, useSelectedNodePath, useSelectedTimelineItem, useSelectedTimelineRevision, useSentryDsn, useSentryEnv, useSentryRelease, useSetDefaultPHGlobalConfig, useSetPHAppConfig, useSetPHDocumentEditorConfig, useSetPHGlobalConfig, useStudioMode, useSubgraphModules, useSupportedDocumentTypesInReactor, useSync, useSyncList, useTheme, useUser, useUserPermissions, useVersion, useVersionCheckInterval, useVetraPackageManager, useVetraPackages, useWarnOutdatedApp, validateDocument };
3798
+ export { ActionTracker, BaseStorage, BrowserLocalStorage, COMMON_PACKAGE_ID, CREDENTIAL_SCHEMA_EIP712_TYPE, CREDENTIAL_SUBJECT_TYPE, CREDENTIAL_TYPES, ChannelScheme, ChevronDownIcon, ConflictError, CopyIcon, DEFAULT_DRIVE_EDITOR_ID, DEFAULT_DRIVE_ID, DEFAULT_SWITCHBOARD_URL, DOMAIN_TYPE, DisconnectIcon, DocumentCache, DocumentChangeType, DocumentIntegrityService, EDITOR_FILE_DROP_OPT_OUT_ATTR, GqlRequestChannel, GraphQLClientDocumentCache, ISSUER_TYPE, InMemoryQueue, IntervalPollTimer, PollBehavior, PropagationMode, REACTOR_SCHEMA, RENOWN_CHAIN_ID, RENOWN_NETWORK_ID, RENOWN_URL, ReactorBuilder, ReactorClientBuilder, RegistryClient, RelationalDbProcessor, RemoteClient, RemoteDocumentController, Renown, RenownAuthButton, RenownLoginButton, RenownLogo, RenownUserButton, SpinnerIcon, SyncOperationStatus, UploadStatus, UserIcon, VERIFIABLE_CREDENTIAL_EIP712_TYPE, addAllowListEventHandler, addAllowedDocumentTypesEventHandler, addAnalyticsDatabaseNameEventHandler, addAttachmentServiceEventHandler, addBasePathEventHandler, addCliVersionEventHandler, addDefaultDrivesUrlEventHandler, addDisabledEditorsEventHandler, addDocument, addDocumentCacheEventHandler, addDraggingNodeEventHandler, addDrive, addDrivesEventHandler, addDrivesPreserveStrategyEventHandler, addEnabledEditorsEventHandler, addFeaturesEventHandler, addFileUploadOperationsChunkSizeEventHandler, addFolder, addGaTrackingIdEventHandler, addGraphQLReactorClientEventHandler, addIsAddCloudDrivesEnabledEventHandler, addIsAddDriveEnabledEventHandler, addIsAddLocalDrivesEnabledEventHandler, addIsAddPublicDrivesEnabledEventHandler, addIsAnalyticsDatabaseWorkerEnabledEventHandler, addIsAnalyticsEnabledEventHandler, addIsAnalyticsExternalProcessorsEnabledEventHandler, addIsCloudDrivesEnabledEventHandler, addIsDeleteCloudDrivesEnabledEventHandler, addIsDeleteLocalDrivesEnabledEventHandler, addIsDeletePublicDrivesEnabledEventHandler, addIsDiffAnalyticsEnabledEventHandler, addIsDocumentModelSelectionSettingsEnabledEventHandler, addIsDragAndDropEnabledEventHandler, addIsDriveAnalyticsEnabledEventHandler, addIsEditorDebugModeEnabledEventHandler, addIsEditorReadModeEnabledEventHandler, addIsExternalControlsEnabledEventHandler, addIsExternalPackagesEnabledEventHandler, addIsExternalProcessorsEnabledEventHandler, addIsExternalRelationalProcessorsEnabledEventHandler, addIsLocalDrivesEnabledEventHandler, addIsPublicDrivesEnabledEventHandler, addIsRelationalProcessorsEnabledEventHandler, addIsSentryTracingEnabledEventHandler, addLoadingEventHandler, addLocalDrivesEnabledEventHandler, addLogLevelEventHandler, addModalEventHandler, addPHEventHandlers, addPackageDiscoveryServiceEventHandler, addPromiseState, addReactorClientEventHandler, addReactorClientModuleEventHandler, addRemoteDrive, addRenownChainIdEventHandler, addRenownEventHandler, addRenownNetworkIdEventHandler, addRenownUrlEventHandler, addRequiresHardRefreshEventHandler, addResetSelectedNodeEventHandler, addRevisionHistoryVisibleEventHandler, addRouterBasenameEventHandler, addSelectedDriveIdEventHandler, addSelectedNodeIdEventHandler, addSelectedTimelineItemEventHandler, addSelectedTimelineRevisionEventHandler, addSentryDsnEventHandler, addSentryEnvEventHandler, addSentryReleaseEventHandler, addSetSelectedDriveOnPopStateEventHandler, addSetSelectedNodeOnPopStateEventHandler, addStudioModeEventHandler, addToastEventHandler, addVersionCheckIntervalEventHandler, addVersionEventHandler, addVetraPackageManagerEventHandler, addWarnOutdatedAppEventHandler, baseDocumentModels, baseDocumentModelsMap, buildDocumentSubgraphQuery, buildDocumentSubgraphUrl, callEventHandlerRegisterFunctions, callGlobalSetterForKey, clearGlobal, closePHModal, commonGlobalEventHandlerFunctions, convertRemoteOperations, createAnalyticsStore, createClient, createProcessorQuery, createUrlWithPreservedParams, deleteDrive, deleteNode, deriveSystemUrl, dispatchActions, downloadDocument, driveCollectionId, driveIdFromUrl, dropAllReactorStorage, exportFile, extractDriveIdFromPath, extractDriveIdFromSlug, extractDriveSlugFromPath, extractNodeIdFromPath, extractNodeIdFromSlug, extractNodeSlugFromPath, findUuid, getAnalyticsStore, getDocumentGraphqlQuery, getDriveIdBySlug, getDrives, getGlobal, getPackages, getPackagesByDocumentType, getPathWithoutBase, getRevisionFromDate, getSlugFromDriveUrl, getSwitchboardGatewayUrlFromDriveUrl, getSyncStatus, getSyncStatusSync, getUserPermissions, graphqlDocumentEvents, graphqlDocumentsEvents, graphqlEventsToSyncDrive, hideRevisionHistory, identifierFromMutateDocumentOperationVariables, initConnectCrypto, initRenownCrypto, initTheme, isDocumentTypeSupported, isExternalControlsEnabledEventFunctions, isFileNodeKind, isFolderNodeKind, loading, login, logout, makeDriveUrlComponent, makeNodeSlug, makePHEventFunctions, openRenown, parseDriveUrl, phAppConfigHooks, phAppConfigSetters, phDocumentEditorConfigHooks, phDocumentEditorConfigSetters, phDocumentFromQuery, phDocumentsFromQuery, phGlobalConfigHooks, phGlobalConfigSetters, reactorGraphqlBatchFetchDocuments, reactorGraphqlCreateDocument, reactorGraphqlDeleteDocument, reactorGraphqlDeleteDocuments, reactorGraphqlFetchDocument, reactorGraphqlMutateDocument, readPromiseState, refreshReactorData, refreshReactorDataClient, renameDrive, renameDriveNode, resolveUrlPathname, setAllowList, setAllowedDocumentTypes, setAnalyticsDatabaseName, setAttachmentService, setBasePath, setCliVersion, setDefaultDrivesUrl, setDefaultPHGlobalConfig, setDisabledEditors, setDocumentCache, setDriveAvailableOffline, setDriveMetadata, setDriveSharingType, setDrives, setDrivesPreserveStrategy, setEnabledEditors, setFeatures, setFileUploadOperationsChunkSize, setGaTrackingId, setGlobal, setGraphQLReactorClient, setIsAddCloudDrivesEnabled, setIsAddDriveEnabled, setIsAddLocalDrivesEnabled, setIsAddPublicDrivesEnabled, setIsAnalyticsDatabaseWorkerEnabled, setIsAnalyticsEnabled, setIsAnalyticsExternalProcessorsEnabled, setIsCloudDrivesEnabled, setIsDeleteCloudDrivesEnabled, setIsDeleteLocalDrivesEnabled, setIsDeletePublicDrivesEnabled, setIsDiffAnalyticsEnabled, setIsDocumentModelSelectionSettingsEnabled, setIsDragAndDropEnabled, setIsDriveAnalyticsEnabled, setIsEditorDebugModeEnabled, setIsEditorReadModeEnabled, setIsExternalControlsEnabled, setIsExternalPackagesEnabled, setIsExternalProcessorsEnabled, setIsExternalRelationalProcessorsEnabled, setIsLocalDrivesEnabled, setIsPublicDrivesEnabled, setIsRelationalProcessorsEnabled, setIsSentryTracingEnabled, setLoading, setLocalDrivesEnabled, setLogLevel, setPHAppConfig, setPHAppConfigByKey, setPHDocumentEditorConfig, setPHDocumentEditorConfigByKey, setPHGlobalConfig, setPHGlobalConfigByKey, setPHModal, setPHToast, setPackageDiscoveryService, setReactorClient, setReactorClientModule, setRenown, setRenownChainId, setRenownNetworkId, setRenownUrl, setRequiresHardRefresh, setRevisionHistoryVisible, setRouterBasename, setSelectedDrive, setSelectedDriveId, setSelectedNode, setSelectedTimelineItem, setSelectedTimelineRevision, setSentryDsn, setSentryEnv, setSentryRelease, setStudioMode, setVersion, setVersionCheckInterval, setVetraPackageManager, setWarnOutdatedApp, showCreateDocumentModal, showDeleteNodeModal, showPHModal, showRevisionHistory, sortNodesByName, trimTrailingSlash, truncateAllTables, useAllowList, useAllowedDocumentModelModules, useAllowedDocumentTypes, useAnalyticsDatabaseName, useAppModuleById, useAppModules, useAttachmentService, useAttachmentUpload, useAttachments, useBasePath, useCliVersion, useConnectionState, useConnectionStates, useDatabase, useDefaultAppModule, useDefaultDrivesUrl, useDid, useDisabledEditors, useDispatch, useDocument, useDocumentById, useDocumentCache, useDocumentModelModuleById, useDocumentModelModules, useDocumentOfType, useDocumentOperations, useDocumentSafe, useDocumentTypes, useDocumentTypesInSelectedDrive, useDocuments, useDocumentsByIds, useDocumentsInSelectedDrive, useDocumentsInSelectedFolder, useDownloadDocument, useDragNode, useDriveById, useDriveSystemInfo, useDrives, useDrivesPreserveStrategy, useDropFile, useDropNode, useEditorFileDrop, useEditorModuleById, useEditorModules, useEditorModulesForDocumentType, useEnabledEditors, useFallbackEditorModule, useFeatures, useFileNodesInSelectedDrive, useFileNodesInSelectedFolder, useFileUploadOperationsChunkSize, useFolderById, useFolderNodesInSelectedDrive, useFolderNodesInSelectedFolder, useGaTrackingId, useGetDocument, useGetDocumentAsync, useGetDocuments, useGetSwitchboardLink, useGraphQLReactorClient, useInitReactorGraphqlClient, useIsAddCloudDrivesEnabled, useIsAddDriveEnabled, useIsAddLocalDrivesEnabled, useIsAddPublicDrivesEnabled, useIsAnalyticsDatabaseWorkerEnabled, useIsAnalyticsEnabled, useIsAnalyticsExternalProcessorsEnabled, useIsCloudDrivesEnabled, useIsDeleteCloudDrivesEnabled, useIsDeleteLocalDrivesEnabled, useIsDeletePublicDrivesEnabled, useIsDiffAnalyticsEnabled, useIsDocumentModelSelectionSettingsEnabled, useIsDragAndDropEnabled, useIsDriveAnalyticsEnabled, useIsEditorDebugModeEnabled, useIsEditorReadModeEnabled, useIsExternalControlsEnabled, useIsExternalPackagesEnabled, useIsExternalProcessorsEnabled, useIsExternalRelationalProcessorsEnabled, useIsLocalDrivesEnabled, useIsPublicDrivesEnabled, useIsRelationalProcessorsEnabled, useIsSentryTracingEnabled, useLoading, useLocalDrivesEnabled, useLogLevel, useLoginStatus, useModelRegistry, useNodeActions, useNodeById, useNodeParentFolderById, useNodePathById, useNodesInSelectedDrive, useNodesInSelectedDriveOrFolder, useNodesInSelectedFolder, useOnDropFile, usePGlite, usePHAppConfigByKey, usePHDocumentEditorConfigByKey, usePHGlobalConfigByKey, usePHModal, usePHToast, usePackageDiscoveryService, useParentFolderForSelectedNode, useReactorClient, useReactorClientModule, useRelationalDb, useRelationalQuery, useRenown, useRenownAuth, useRenownChainId, useRenownInit, useRenownNetworkId, useRenownUrl, useRequiresHardRefresh, useResetPHGlobalConfig, useRevisionHistoryVisible, useRouterBasename, useSelectedDocument, useSelectedDocumentId, useSelectedDocumentOfType, useSelectedDocumentSafe, useSelectedDrive, useSelectedDriveId, useSelectedDriveSafe, useSelectedFolder, useSelectedNode, useSelectedNodePath, useSelectedTimelineItem, useSelectedTimelineRevision, useSentryDsn, useSentryEnv, useSentryRelease, useSetDefaultPHGlobalConfig, useSetPHAppConfig, useSetPHDocumentEditorConfig, useSetPHGlobalConfig, useStudioMode, useSubgraphModules, useSupportedDocumentTypesInReactor, useSync, useSyncList, useTheme, useUser, useUserPermissions, useVersion, useVersionCheckInterval, useVetraPackageManager, useVetraPackages, useWarnOutdatedApp, validateDocument, waitForDocumentReady };
3661
3799
 
3662
3800
  //# sourceMappingURL=index.js.map