@seedprotocol/sdk 0.1.82 → 0.1.84
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-fFLXHK1c.js → index-CBTE_R-7.js} +2 -2
- package/dist/{index-fFLXHK1c.js.map → index-CBTE_R-7.js.map} +1 -1
- package/dist/{index-FL8U-FO4.js → index-JmHVBmP7.js} +17 -12
- package/dist/index-JmHVBmP7.js.map +1 -0
- package/dist/main.js +1 -1
- package/dist/{seed.schema.config-DqizK2KH.js → seed.schema.config-BSTzpuJg.js} +2 -2
- package/dist/{seed.schema.config-DqizK2KH.js.map → seed.schema.config-BSTzpuJg.js.map} +1 -1
- package/dist/src/download.ts +6 -5
- package/dist/src/hydrateFromDb.ts +7 -5
- package/dist/types/src/browser/events/files/download.d.ts.map +1 -1
- package/dist/types/src/browser/property/actors/hydrateFromDb.d.ts.map +1 -1
- package/package.json +1 -1
- package/dist/index-FL8U-FO4.js.map +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { g as GET_ALL_PROPERTIES_FOR_ALL_VERSIONS, f as GET_PROPERTIES, G as GET_SCHEMAS, a as GET_SCHEMA_BY_NAME, b as GET_SEEDS, c as GET_SEED_IDS, d as GET_STORAGE_TRANSACTION_ID, e as GET_VERSIONS, I as Item, h as itemMachineAll, i as itemMachineSingle } from './index-
|
|
1
|
+
export { g as GET_ALL_PROPERTIES_FOR_ALL_VERSIONS, f as GET_PROPERTIES, G as GET_SCHEMAS, a as GET_SCHEMA_BY_NAME, b as GET_SEEDS, c as GET_SEED_IDS, d as GET_STORAGE_TRANSACTION_ID, e as GET_VERSIONS, I as Item, h as itemMachineAll, i as itemMachineSingle } from './index-JmHVBmP7.js';
|
|
2
2
|
import './constants-rmQ8zg8_.js';
|
|
3
3
|
import '@ethereum-attestation-service/eas-sdk';
|
|
4
4
|
import 'thirdweb';
|
|
@@ -29,4 +29,4 @@ import 'rxjs';
|
|
|
29
29
|
import 'drizzle-orm/sqlite-proxy';
|
|
30
30
|
import '@zenfs/dom';
|
|
31
31
|
import 'arweave';
|
|
32
|
-
//# sourceMappingURL=index-
|
|
32
|
+
//# sourceMappingURL=index-CBTE_R-7.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index-
|
|
1
|
+
{"version":3,"file":"index-CBTE_R-7.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1018,18 +1018,20 @@ const hydrateFromDb = fromCallback(({ sendBack, input: { context } }) => {
|
|
|
1018
1018
|
return path.basename(file).includes(refResolvedValue);
|
|
1019
1019
|
});
|
|
1020
1020
|
let fileExists = false;
|
|
1021
|
-
|
|
1021
|
+
let filename;
|
|
1022
|
+
let filePath;
|
|
1022
1023
|
if (matchingFiles && matchingFiles.length > 0) {
|
|
1023
1024
|
fileExists = true;
|
|
1025
|
+
filename = matchingFiles[0];
|
|
1026
|
+
filePath = `/files/${dir}/${filename}`;
|
|
1024
1027
|
}
|
|
1025
|
-
|
|
1026
|
-
if (fileExists) {
|
|
1028
|
+
if (fileExists && filename && filePath) {
|
|
1027
1029
|
const fileContents = yield fs.promises.readFile(filePath);
|
|
1028
|
-
const fileHandler = new File([fileContents],
|
|
1030
|
+
const fileHandler = new File([fileContents], filename);
|
|
1029
1031
|
refResolvedDisplayValue = URL.createObjectURL(fileHandler);
|
|
1030
1032
|
yield updateMetadata({
|
|
1031
1033
|
localId,
|
|
1032
|
-
|
|
1034
|
+
refResolvedValue: filename,
|
|
1033
1035
|
});
|
|
1034
1036
|
}
|
|
1035
1037
|
}
|
|
@@ -1059,7 +1061,7 @@ const hydrateFromDb = fromCallback(({ sendBack, input: { context } }) => {
|
|
|
1059
1061
|
if (propertyRecordSchema &&
|
|
1060
1062
|
propertyRecordSchema.storageType &&
|
|
1061
1063
|
propertyRecordSchema.storageType === 'ItemStorage') {
|
|
1062
|
-
const { Item } = yield import('./index-
|
|
1064
|
+
const { Item } = yield import('./index-CBTE_R-7.js');
|
|
1063
1065
|
const item = yield Item.find({
|
|
1064
1066
|
seedLocalId,
|
|
1065
1067
|
modelName: itemModelName,
|
|
@@ -2621,7 +2623,7 @@ const addModelsToDb = fromCallback(({ sendBack, input: { context } }) => {
|
|
|
2621
2623
|
if (!models$1) {
|
|
2622
2624
|
return;
|
|
2623
2625
|
}
|
|
2624
|
-
const { models: SeedModels } = yield import('./seed.schema.config-
|
|
2626
|
+
const { models: SeedModels } = yield import('./seed.schema.config-BSTzpuJg.js');
|
|
2625
2627
|
const allModels = Object.assign(Object.assign({}, SeedModels), models$1);
|
|
2626
2628
|
let hasModelsInDb = false;
|
|
2627
2629
|
const schemaDefsByModelName = new Map();
|
|
@@ -3767,11 +3769,14 @@ const downloadAllFilesBinaryRequestHandler = () => __awaiter(void 0, void 0, voi
|
|
|
3767
3769
|
}
|
|
3768
3770
|
}
|
|
3769
3771
|
}
|
|
3770
|
-
const
|
|
3772
|
+
const dataString = yield queryClient.fetchQuery({
|
|
3771
3773
|
queryKey: ['fetchTransaction', transactionId],
|
|
3772
|
-
queryFn: () => __awaiter(void 0, void 0, void 0, function* () {
|
|
3774
|
+
queryFn: () => __awaiter(void 0, void 0, void 0, function* () {
|
|
3775
|
+
const response = yield fetch(`https://${ARWEAVE_HOST}/raw/${transactionId}`);
|
|
3776
|
+
return yield response.text();
|
|
3777
|
+
}),
|
|
3778
|
+
networkMode: "offlineFirst"
|
|
3773
3779
|
});
|
|
3774
|
-
const dataString = yield fetchResponse.text();
|
|
3775
3780
|
// const dataString = await arweave.transactions.getData(transactionId, {
|
|
3776
3781
|
// decode: true,
|
|
3777
3782
|
// string: true,
|
|
@@ -6628,7 +6633,7 @@ const client = {
|
|
|
6628
6633
|
console.error('fs listeners not ready during init');
|
|
6629
6634
|
}
|
|
6630
6635
|
globalService.send({ type: 'init', endpoints, models, addresses });
|
|
6631
|
-
import('./seed.schema.config-
|
|
6636
|
+
import('./seed.schema.config-BSTzpuJg.js').then(({ models }) => {
|
|
6632
6637
|
for (const [key, value] of Object.entries(models)) {
|
|
6633
6638
|
setModel(key, value);
|
|
6634
6639
|
}
|
|
@@ -7582,4 +7587,4 @@ if (isNode()) {
|
|
|
7582
7587
|
}
|
|
7583
7588
|
|
|
7584
7589
|
export { GET_SCHEMAS as G, Item as I, Json as J, List as L, Model as M, Property as P, Relation as R, Text as T, GET_SCHEMA_BY_NAME as a, GET_SEEDS as b, GET_SEED_IDS as c, GET_STORAGE_TRANSACTION_ID as d, GET_VERSIONS as e, GET_PROPERTIES as f, GET_ALL_PROPERTIES_FOR_ALL_VERSIONS as g, itemMachineAll as h, itemMachineSingle as i, ImageSrc as j, ItemProperty as k, useItem as l, useItemProperties as m, useCreateItem as n, useItemProperty as o, useDeleteItem as p, useGlobalServiceStatus as q, useServices as r, getGlobalService as s, client as t, useItems as u, getCorrectId as v, withSeed as w };
|
|
7585
|
-
//# sourceMappingURL=index-
|
|
7590
|
+
//# sourceMappingURL=index-JmHVBmP7.js.map
|