@powerhousedao/connect 1.0.19-dev.0 → 1.0.19-dev.1
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/assets/{app-CMvPXKGM.js → app-0PUokYXm.js} +29 -22
- package/dist/assets/{app-CMvPXKGM.js.map → app-0PUokYXm.js.map} +1 -1
- package/dist/assets/{app-loader-CBJsoaTy.js → app-loader-CVII2DYj.js} +182 -195
- package/dist/assets/app-loader-CVII2DYj.js.map +1 -0
- package/dist/assets/{browser-C1XtII0d.js → browser-DaWhu_1T.js} +4 -4
- package/dist/assets/{browser-C1XtII0d.js.map → browser-DaWhu_1T.js.map} +1 -1
- package/dist/assets/{ccip-pghZxJM2.js → ccip-BiEUOhIy.js} +4 -4
- package/dist/assets/{ccip-pghZxJM2.js.map → ccip-BiEUOhIy.js.map} +1 -1
- package/dist/assets/{content-Ckphl3_k.js → content-D_3kBNR7.js} +5 -5
- package/dist/assets/{content-Ckphl3_k.js.map → content-D_3kBNR7.js.map} +1 -1
- package/dist/assets/{index-CXW9Lig1.js → index-3a_rYGU1.js} +5 -5
- package/dist/assets/{index-CXW9Lig1.js.map → index-3a_rYGU1.js.map} +1 -1
- package/dist/assets/{index-BTynLKZO.js → index-C30XfZqk.js} +4 -4
- package/dist/assets/{index-BTynLKZO.js.map → index-C30XfZqk.js.map} +1 -1
- package/dist/assets/{index-Dgzoras6.js → index-DiejwhaO.js} +4 -4
- package/dist/assets/{index-Dgzoras6.js.map → index-DiejwhaO.js.map} +1 -1
- package/dist/assets/{main.yOd0NXUD.js → main.y7csLjWq.js} +2 -2
- package/dist/assets/{main.yOd0NXUD.js.map → main.y7csLjWq.js.map} +1 -1
- package/dist/assets/{reactor-analytics-8R1amkYi.js → reactor-analytics-DDw23exh.js} +4 -4
- package/dist/assets/{reactor-analytics-8R1amkYi.js.map → reactor-analytics-DDw23exh.js.map} +1 -1
- package/dist/assets/{router-vKaP_Iuh.js → router-D1e0l-Bx.js} +6 -6
- package/dist/assets/{router-vKaP_Iuh.js.map → router-D1e0l-Bx.js.map} +1 -1
- package/dist/index.html +1 -1
- package/dist/vite-envs.sh +1 -1
- package/package.json +7 -7
- package/dist/assets/app-loader-CBJsoaTy.js.map +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/ccip-
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/ccip-BiEUOhIy.js","assets/main.y7csLjWq.js","assets/app-loader-CVII2DYj.js","assets/app-loader-B74nopv_.css","assets/index-C30XfZqk.js","assets/style-Ce3V83BE.css","assets/index-3a_rYGU1.js","assets/browser-DaWhu_1T.js","assets/router-D1e0l-Bx.js","assets/reactor-analytics-DDw23exh.js"])))=>i.map(i=>d[i]);
|
|
2
2
|
var __defProp = Object.defineProperty;
|
|
3
3
|
var __typeError = (msg) => {
|
|
4
4
|
throw TypeError(msg);
|
|
@@ -19,9 +19,9 @@ var __privateWrapper = (obj, member, setter, getter) => ({
|
|
|
19
19
|
}
|
|
20
20
|
});
|
|
21
21
|
var _InternalTransmitter_instances, buildInternalOperationUpdate_fn, _focused, _cleanup, _setup, _a, _online, _cleanup2, _setup2, _b, _gcTimeout, _c, _initialState, _revertState, _cache, _client, _retryer, _defaultOptions, _abortSignalConsumed, _Query_instances, dispatch_fn, _d, _queries, _e2, _observers, _mutationCache, _retryer2, _Mutation_instances, dispatch_fn2, _f, _mutations, _scopes, _mutationId, _g, _queryCache, _mutationCache2, _defaultOptions2, _queryDefaults, _mutationDefaults, _mountCount, _unsubscribeFocus, _unsubscribeOnline, _h, _subtleCrypto, _keyPair, _keyPairStorage, _did, _ConnectCrypto_instances, initCrypto_fn, initialize_fn, parseDid_fn, generateECDSAKeyPair_fn, exportKeyPair_fn, importKeyPair_fn, _sign, _verify, _DB_NAME, _STORE_NAME, _KEY, _db, _BrowserKeyStorage_instances, useStore_fn;
|
|
22
|
-
import { _ as __vitePreload } from "./main.
|
|
22
|
+
import { _ as __vitePreload } from "./main.y7csLjWq.js";
|
|
23
23
|
import { jsx as jsx$1, Fragment, jsxs } from "react/jsx-runtime";
|
|
24
|
-
import { c as createAction, a as createReducer, i as isDocumentAction, R as ReorderStateExamplesInputSchema, D as DeleteStateExampleInputSchema, U as UpdateStateExampleInputSchema, A as AddStateExampleInputSchema, S as SetInitialStateInputSchema, b as SetStateSchemaInputSchema, d as ReorderModuleOperationsInputSchema, e as DeleteOperationInputSchema, M as MoveOperationInputSchema, f as SetOperationReducerInputSchema, g as SetOperationTemplateInputSchema, h as SetOperationDescriptionInputSchema, j as SetOperationSchemaInputSchema, k as SetOperationScopeInputSchema, l as SetOperationNameInputSchema, m as AddOperationInputSchema, n as ReorderOperationExamplesInputSchema, o as DeleteOperationExampleInputSchema, p as UpdateOperationExampleInputSchema, q as AddOperationExampleInputSchema, r as ReorderOperationErrorsInputSchema, s as DeleteOperationErrorInputSchema, t as SetOperationErrorTemplateInputSchema, u as SetOperationErrorDescriptionInputSchema, v as SetOperationErrorNameInputSchema, w as SetOperationErrorCodeInputSchema, x as AddOperationErrorInputSchema, y as ReorderModulesInputSchema, z as DeleteModuleInputSchema, B as SetModuleDescriptionInputSchema, C as SetModuleNameInputSchema, E as AddModuleInputSchema, F as ReorderChangeLogItemsInputSchema, G as DeleteChangeLogItemInputSchema, H as UpdateChangeLogItemInputSchema, I as AddChangeLogItemInputSchema, J as SetAuthorWebsiteInputSchema, K as SetAuthorNameInputSchema, L as SetModelDescriptionInputSchema, N as SetModelExtensionInputSchema, O as SetModelIdInputSchema, P as SetModelNameInputSchema, Q as baseCreateExtendedState, T as baseCreateDocument, V as baseSaveToFile, W as baseSaveToFileHandle, X as baseLoadFromFile, Y as baseLoadFromInput, Z as pascalCase, _ as logger$1, $ as Icon, a0 as getDefaultExportFromCjs, a1 as LOCAL, a2 as commonjsGlobal, a3 as PUBLIC, a4 as SWITCHBOARD, a5 as locationInfoByLocation, a6 as sharingTypeOptions, a7 as objectType, a8 as recordType, a9 as stringType, aa as capitalCase, ab as CLOUD, ac as createZip, ad as LZString, ae as buildSignedOperation, af as getI18n, ag as getDefaults, ah as connectConfig, ai as hashDocumentStateForScope, aj as getAugmentedNamespace, ak as process, al as setErrorHandler, am as driveDocumentModelModule, an as
|
|
24
|
+
import { c as createAction, a as createReducer, i as isDocumentAction, R as ReorderStateExamplesInputSchema, D as DeleteStateExampleInputSchema, U as UpdateStateExampleInputSchema, A as AddStateExampleInputSchema, S as SetInitialStateInputSchema, b as SetStateSchemaInputSchema, d as ReorderModuleOperationsInputSchema, e as DeleteOperationInputSchema, M as MoveOperationInputSchema, f as SetOperationReducerInputSchema, g as SetOperationTemplateInputSchema, h as SetOperationDescriptionInputSchema, j as SetOperationSchemaInputSchema, k as SetOperationScopeInputSchema, l as SetOperationNameInputSchema, m as AddOperationInputSchema, n as ReorderOperationExamplesInputSchema, o as DeleteOperationExampleInputSchema, p as UpdateOperationExampleInputSchema, q as AddOperationExampleInputSchema, r as ReorderOperationErrorsInputSchema, s as DeleteOperationErrorInputSchema, t as SetOperationErrorTemplateInputSchema, u as SetOperationErrorDescriptionInputSchema, v as SetOperationErrorNameInputSchema, w as SetOperationErrorCodeInputSchema, x as AddOperationErrorInputSchema, y as ReorderModulesInputSchema, z as DeleteModuleInputSchema, B as SetModuleDescriptionInputSchema, C as SetModuleNameInputSchema, E as AddModuleInputSchema, F as ReorderChangeLogItemsInputSchema, G as DeleteChangeLogItemInputSchema, H as UpdateChangeLogItemInputSchema, I as AddChangeLogItemInputSchema, J as SetAuthorWebsiteInputSchema, K as SetAuthorNameInputSchema, L as SetModelDescriptionInputSchema, N as SetModelExtensionInputSchema, O as SetModelIdInputSchema, P as SetModelNameInputSchema, Q as baseCreateExtendedState, T as baseCreateDocument, V as baseSaveToFile, W as baseSaveToFileHandle, X as baseLoadFromFile, Y as baseLoadFromInput, Z as pascalCase, _ as logger$1, $ as Icon, a0 as getDefaultExportFromCjs, a1 as LOCAL, a2 as commonjsGlobal, a3 as PUBLIC, a4 as SWITCHBOARD, a5 as locationInfoByLocation, a6 as sharingTypeOptions, a7 as objectType, a8 as recordType, a9 as stringType, aa as capitalCase, ab as CLOUD, ac as createZip, ad as LZString, ae as buildSignedOperation, af as getI18n, ag as getDefaults, ah as connectConfig, ai as hashDocumentStateForScope, aj as getAugmentedNamespace, ak as process, al as setErrorHandler, am as driveDocumentModelModule, an as createBrowserStorage, ao as createBrowserDocumentDriveServer, ap as hashKey$1, aq as childLogger, ar as reducer$8, as as isDocumentDrive, at as generateAddNodeAction, au as isFileNode, av as uploadDocumentOperations, aw as updateFile, ax as addFolder, ay as isFolderNode, az as deleteNode, aA as updateNode, aB as FILE$1, aC as moveNode, aD as generateNodesCopy, aE as copyNode, aF as createState$1, aG as setDriveName, aH as setAvailableOffline, aI as setSharingType, aJ as SynchronizationUnitNotFoundError, aK as removeTrigger, aL as generateUUID, aM as PullResponderTransmitter, aN as addTrigger, aO as ReadDriveNotFoundError, aP as openUrl, aQ as getNodeOptions, aR as DRIVE$1, aS as FOLDER, aT as requestPublicDrive, aU as serviceWorkerManager, aV as packageJson, aW as t$1, aX as generateId } from "./app-loader-CVII2DYj.js";
|
|
25
25
|
import * as React from "react";
|
|
26
26
|
import React__default, { useLayoutEffect, useEffect, useState, forwardRef, useCallback, useContext, useRef, useMemo, createContext, Component, Fragment as Fragment$1, createElement, useId as useId$1, useSyncExternalStore, isValidElement, cloneElement, Children, useReducer, useDebugValue, Suspense, lazy } from "react";
|
|
27
27
|
import * as ReactDOM from "react-dom";
|
|
@@ -20581,7 +20581,7 @@ async function call(client2, args) {
|
|
|
20581
20581
|
} catch (err) {
|
|
20582
20582
|
const data2 = getRevertErrorData(err);
|
|
20583
20583
|
const { offchainLookup, offchainLookupSignature } = await __vitePreload(async () => {
|
|
20584
|
-
const { offchainLookup: offchainLookup2, offchainLookupSignature: offchainLookupSignature2 } = await import("./ccip-
|
|
20584
|
+
const { offchainLookup: offchainLookup2, offchainLookupSignature: offchainLookupSignature2 } = await import("./ccip-BiEUOhIy.js");
|
|
20585
20585
|
return { offchainLookup: offchainLookup2, offchainLookupSignature: offchainLookupSignature2 };
|
|
20586
20586
|
}, true ? __vite__mapDeps([0,1,2,3]) : void 0);
|
|
20587
20587
|
if (client2.ccipRead !== false && (data2 == null ? void 0 : data2.slice(0, 10)) === offchainLookupSignature && to)
|
|
@@ -72610,7 +72610,7 @@ const useFilteredDocumentModels = () => {
|
|
|
72610
72610
|
return filteredDocumentModels;
|
|
72611
72611
|
};
|
|
72612
72612
|
async function loadBaseEditors() {
|
|
72613
|
-
const documentModelEditor = await __vitePreload(() => import("./index-
|
|
72613
|
+
const documentModelEditor = await __vitePreload(() => import("./index-C30XfZqk.js"), true ? __vite__mapDeps([4,2,1,3]) : void 0);
|
|
72614
72614
|
await __vitePreload(() => Promise.resolve({}), true ? __vite__mapDeps([5]) : void 0);
|
|
72615
72615
|
const module = documentModelEditor.documentModelEditorModule;
|
|
72616
72616
|
return [module];
|
|
@@ -72669,16 +72669,18 @@ async function initReactor(reactor) {
|
|
|
72669
72669
|
}
|
|
72670
72670
|
async function createReactor() {
|
|
72671
72671
|
var _a2;
|
|
72672
|
+
const storage = useAtomValue(storageAtom);
|
|
72672
72673
|
const documentModels = await atomStore.get(documentModelsAtom);
|
|
72673
|
-
const server = ((_a2 = window.electronAPI) == null ? void 0 : _a2.documentDrive) ?? createBrowserDocumentDriveServer(
|
|
72674
|
-
documentModels,
|
|
72675
|
-
connectConfig.routerBasename
|
|
72676
|
-
);
|
|
72674
|
+
const server = ((_a2 = window.electronAPI) == null ? void 0 : _a2.documentDrive) ?? createBrowserDocumentDriveServer(documentModels, storage);
|
|
72677
72675
|
await initReactor(server);
|
|
72678
72676
|
return server;
|
|
72679
72677
|
}
|
|
72680
|
-
const
|
|
72678
|
+
const storageAtom = atom(createBrowserStorage(connectConfig.routerBasename));
|
|
72679
|
+
const reactorAtom = atomWithLazy(
|
|
72680
|
+
() => createReactor()
|
|
72681
|
+
);
|
|
72681
72682
|
const unwrappedReactor = unwrap(reactorAtom);
|
|
72683
|
+
const useDocumentAdminStorage = () => useAtomValue(storageAtom);
|
|
72682
72684
|
const useUnwrappedReactor = () => useAtomValue(unwrappedReactor);
|
|
72683
72685
|
const useAsyncReactor = () => useAtomValue(reactorAsyncAtom);
|
|
72684
72686
|
const reactorAsyncAtom = atom(void 0);
|
|
@@ -72761,11 +72763,11 @@ const connectCrypto = (async () => {
|
|
|
72761
72763
|
return window.connectCrypto;
|
|
72762
72764
|
}
|
|
72763
72765
|
const { ConnectCrypto: ConnectCrypto2 } = await __vitePreload(async () => {
|
|
72764
|
-
const { ConnectCrypto: ConnectCrypto3 } = await import("./index-
|
|
72766
|
+
const { ConnectCrypto: ConnectCrypto3 } = await import("./index-3a_rYGU1.js");
|
|
72765
72767
|
return { ConnectCrypto: ConnectCrypto3 };
|
|
72766
72768
|
}, true ? __vite__mapDeps([6,1,2,3]) : void 0);
|
|
72767
72769
|
const { BrowserKeyStorage: BrowserKeyStorage2 } = await __vitePreload(async () => {
|
|
72768
|
-
const { BrowserKeyStorage: BrowserKeyStorage3 } = await import("./index-
|
|
72770
|
+
const { BrowserKeyStorage: BrowserKeyStorage3 } = await import("./index-3a_rYGU1.js");
|
|
72769
72771
|
return { BrowserKeyStorage: BrowserKeyStorage3 };
|
|
72770
72772
|
}, true ? __vite__mapDeps([6,1,2,3]) : void 0);
|
|
72771
72773
|
const connectCrypto2 = new ConnectCrypto2(new BrowserKeyStorage2());
|
|
@@ -72814,7 +72816,7 @@ function useRenown() {
|
|
|
72814
72816
|
return;
|
|
72815
72817
|
}
|
|
72816
72818
|
const { initRenownBrowser } = await __vitePreload(async () => {
|
|
72817
|
-
const { initRenownBrowser: initRenownBrowser2 } = await import("./index-
|
|
72819
|
+
const { initRenownBrowser: initRenownBrowser2 } = await import("./index-3a_rYGU1.js");
|
|
72818
72820
|
return { initRenownBrowser: initRenownBrowser2 };
|
|
72819
72821
|
}, true ? __vite__mapDeps([6,1,2,3]) : void 0);
|
|
72820
72822
|
const renownBrowser = initRenownBrowser(did2);
|
|
@@ -73123,6 +73125,7 @@ function useDocumentDriveServer() {
|
|
|
73123
73125
|
const connectDid = useConnectDid();
|
|
73124
73126
|
const { sign } = useConnectCrypto();
|
|
73125
73127
|
const reactor = useUnwrappedReactor();
|
|
73128
|
+
const storage = useDocumentAdminStorage();
|
|
73126
73129
|
const getDocumentModelModule2 = useGetDocumentModelModule();
|
|
73127
73130
|
const [documentDrives, refreshDocumentDrives, , documentDrivesStatus] = useDocumentDrives$1();
|
|
73128
73131
|
const openFile = useCallback(
|
|
@@ -73635,9 +73638,9 @@ function useDocumentDriveServer() {
|
|
|
73635
73638
|
if (!reactor) {
|
|
73636
73639
|
return;
|
|
73637
73640
|
}
|
|
73638
|
-
await
|
|
73641
|
+
await storage.clear();
|
|
73639
73642
|
await refreshDocumentDrives();
|
|
73640
|
-
}, [refreshDocumentDrives, reactor]);
|
|
73643
|
+
}, [refreshDocumentDrives, reactor, storage]);
|
|
73641
73644
|
const handleRemoveTrigger = useCallback(
|
|
73642
73645
|
async (driveId, triggerId) => {
|
|
73643
73646
|
const drive = await _addDriveOperation(
|
|
@@ -87817,9 +87820,11 @@ function diffStateStrings(str1, str2, path, scope) {
|
|
|
87817
87820
|
return changes;
|
|
87818
87821
|
}
|
|
87819
87822
|
class DiffAnalyticsProcessor {
|
|
87820
|
-
constructor(analyticsStore) {
|
|
87823
|
+
constructor(analyticsStore, logger2 = childLogger(["processor", "diff-analytics"])) {
|
|
87821
87824
|
__publicField(this, "analyticsStore");
|
|
87825
|
+
__publicField(this, "logger");
|
|
87822
87826
|
this.analyticsStore = analyticsStore;
|
|
87827
|
+
this.logger = logger2;
|
|
87823
87828
|
}
|
|
87824
87829
|
async onStrands(strands) {
|
|
87825
87830
|
if (strands.length === 0) {
|
|
@@ -87842,7 +87847,9 @@ class DiffAnalyticsProcessor {
|
|
|
87842
87847
|
}
|
|
87843
87848
|
}
|
|
87844
87849
|
}
|
|
87845
|
-
|
|
87850
|
+
if (inputs.length) {
|
|
87851
|
+
await this.analyticsStore.addSeriesValues(inputs);
|
|
87852
|
+
}
|
|
87846
87853
|
}
|
|
87847
87854
|
async onDisconnect() {
|
|
87848
87855
|
}
|
|
@@ -87850,7 +87857,7 @@ class DiffAnalyticsProcessor {
|
|
|
87850
87857
|
try {
|
|
87851
87858
|
await this.analyticsStore.clearSeriesBySource(source, true);
|
|
87852
87859
|
} catch (e2) {
|
|
87853
|
-
|
|
87860
|
+
this.logger.error("Failed to clear source", e2);
|
|
87854
87861
|
}
|
|
87855
87862
|
}
|
|
87856
87863
|
generateInput(documentId, branch, scope, revision, type, value, source, timestamp, path) {
|
|
@@ -87956,7 +87963,7 @@ class ProcessorManager {
|
|
|
87956
87963
|
}
|
|
87957
87964
|
async function createAnalyticsStore() {
|
|
87958
87965
|
const { BrowserAnalyticsStore } = await __vitePreload(async () => {
|
|
87959
|
-
const { BrowserAnalyticsStore: BrowserAnalyticsStore2 } = await import("./browser-
|
|
87966
|
+
const { BrowserAnalyticsStore: BrowserAnalyticsStore2 } = await import("./browser-DaWhu_1T.js");
|
|
87960
87967
|
return { BrowserAnalyticsStore: BrowserAnalyticsStore2 };
|
|
87961
87968
|
}, true ? __vite__mapDeps([7,2,1,3]) : void 0);
|
|
87962
87969
|
const store = new BrowserAnalyticsStore({
|
|
@@ -88002,7 +88009,7 @@ atomStore.sub(reactorAtom, () => {
|
|
|
88002
88009
|
return atomStore.get(processorManagerAtom);
|
|
88003
88010
|
});
|
|
88004
88011
|
const Router = React__default.lazy(async () => {
|
|
88005
|
-
const createRouterComponent = await __vitePreload(() => import("./router-
|
|
88012
|
+
const createRouterComponent = await __vitePreload(() => import("./router-D1e0l-Bx.js").then((n2) => n2.r), true ? __vite__mapDeps([8,1,2,3]) : void 0);
|
|
88006
88013
|
const router = await createRouterComponent.default();
|
|
88007
88014
|
return { default: router };
|
|
88008
88015
|
});
|
|
@@ -88014,7 +88021,7 @@ const Preloader = () => {
|
|
|
88014
88021
|
return null;
|
|
88015
88022
|
};
|
|
88016
88023
|
const ReactorAnalyticsProvider = lazy(
|
|
88017
|
-
() => __vitePreload(() => import("./reactor-analytics-
|
|
88024
|
+
() => __vitePreload(() => import("./reactor-analytics-DDw23exh.js"), true ? __vite__mapDeps([9,1,2,3]) : void 0)
|
|
88018
88025
|
);
|
|
88019
88026
|
const App = () => /* @__PURE__ */ jsx$1(React__default.StrictMode, { children: /* @__PURE__ */ jsx$1(Suspense, { fallback: /* @__PURE__ */ jsx$1(Fragment, {}), children: /* @__PURE__ */ jsxs(Provider, { store: atomStore, children: [
|
|
88020
88027
|
/* @__PURE__ */ jsx$1(Preloader, {}),
|
|
@@ -88200,4 +88207,4 @@ export {
|
|
|
88200
88207
|
useRoutesImpl as y,
|
|
88201
88208
|
mapRouteProperties as z
|
|
88202
88209
|
};
|
|
88203
|
-
//# sourceMappingURL=app-
|
|
88210
|
+
//# sourceMappingURL=app-0PUokYXm.js.map
|