@seedprotocol/sdk 0.7.6 → 0.7.7
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/{ClientManager-D6YA20jP.js → ClientManager-2GtDWHq6.js} +297 -218
- package/dist/ClientManager-2GtDWHq6.js.map +1 -0
- package/dist/{Item-B1MH0tXx.js → Item-D6j0IvBP.js} +233 -330
- package/dist/Item-D6j0IvBP.js.map +1 -0
- package/dist/{ModelProperty-Dw6dHdu_.js → ModelProperty-B52C3CQ2.js} +33 -33
- package/dist/ModelProperty-B52C3CQ2.js.map +1 -0
- package/dist/{Schema-DppObO6h.js → Schema-O1QLoXv6.js} +49 -58
- package/dist/Schema-O1QLoXv6.js.map +1 -0
- package/dist/{SchemaValidationService-DXQ-D531.js → SchemaValidationService-BxCbfDaI.js} +9 -9
- package/dist/SchemaValidationService-BxCbfDaI.js.map +1 -0
- package/dist/{backfillMetadataPropertyIds-Uhzlwg9X.js → backfillMetadataPropertyIds-CzSbuucw.js} +3 -3
- package/dist/{backfillMetadataPropertyIds-Uhzlwg9X.js.map → backfillMetadataPropertyIds-CzSbuucw.js.map} +1 -1
- package/dist/{configurePlatform-CVoh3JeR.js → configurePlatform-Bbpw_R4y.js} +2 -2
- package/dist/{configurePlatform-CVoh3JeR.js.map → configurePlatform-Bbpw_R4y.js.map} +1 -1
- package/dist/{detachRowsBeforeDelete-CtmIFpgV.js → detachRowsBeforeDelete-D1TyEMco.js} +2 -2
- package/dist/{detachRowsBeforeDelete-CtmIFpgV.js.map → detachRowsBeforeDelete-D1TyEMco.js.map} +1 -1
- package/dist/{discardNewDraft-oGYdB5vS.js → discardNewDraft-hiVaUVjV.js} +5 -5
- package/dist/{discardNewDraft-oGYdB5vS.js.map → discardNewDraft-hiVaUVjV.js.map} +1 -1
- package/dist/dist/{ClientManager-D6YA20jP.d.ts → ClientManager-2GtDWHq6.d.ts} +2 -1
- package/dist/dist/ClientManager-2GtDWHq6.d.ts.map +1 -0
- package/dist/dist/{Item-B1MH0tXx.d.ts → Item-D6j0IvBP.d.ts} +16 -23
- package/dist/dist/Item-D6j0IvBP.d.ts.map +1 -0
- package/dist/dist/{ModelProperty-Dw6dHdu_.d.ts → ModelProperty-B52C3CQ2.d.ts} +1 -1
- package/dist/dist/{ModelProperty-Dw6dHdu_.d.ts.map → ModelProperty-B52C3CQ2.d.ts.map} +1 -1
- package/dist/dist/{Schema-DppObO6h.d.ts → Schema-O1QLoXv6.d.ts} +2 -2
- package/dist/dist/{Schema-DppObO6h.d.ts.map → Schema-O1QLoXv6.d.ts.map} +1 -1
- package/dist/dist/{SchemaValidationService-DXQ-D531.d.ts → SchemaValidationService-BxCbfDaI.d.ts} +4 -4
- package/dist/dist/{SchemaValidationService-DXQ-D531.d.ts.map → SchemaValidationService-BxCbfDaI.d.ts.map} +1 -1
- package/dist/dist/{backfillMetadataPropertyIds-Uhzlwg9X.d.ts → backfillMetadataPropertyIds-CzSbuucw.d.ts} +1 -1
- package/dist/dist/backfillMetadataPropertyIds-CzSbuucw.d.ts.map +1 -0
- package/dist/dist/{configurePlatform-CVoh3JeR.d.ts → configurePlatform-Bbpw_R4y.d.ts} +1 -1
- package/dist/dist/configurePlatform-Bbpw_R4y.d.ts.map +1 -0
- package/dist/dist/{detachRowsBeforeDelete-CtmIFpgV.d.ts → detachRowsBeforeDelete-D1TyEMco.d.ts} +1 -1
- package/dist/dist/detachRowsBeforeDelete-D1TyEMco.d.ts.map +1 -0
- package/dist/dist/{discardNewDraft-oGYdB5vS.d.ts → discardNewDraft-hiVaUVjV.d.ts} +1 -1
- package/dist/dist/discardNewDraft-hiVaUVjV.d.ts.map +1 -0
- package/dist/dist/{eas-CSm5wmry.d.ts → eas-DOdj-EMK.d.ts} +1 -1
- package/dist/dist/eas-DOdj-EMK.d.ts.map +1 -0
- package/dist/dist/{errors-3tc6XkCB.d.ts → errors-KM-yq2MD.d.ts} +21 -8
- package/dist/dist/errors-KM-yq2MD.d.ts.map +1 -0
- package/dist/dist/{getItem-DM3a-7XE.d.ts → getItem-Bh0zv-o1.d.ts} +1 -1
- package/dist/dist/getItem-Bh0zv-o1.d.ts.map +1 -0
- package/dist/dist/{getPublishPayload-CJF0k5d8.d.ts → getPublishPayload-oH8wJhnH.d.ts} +1 -1
- package/dist/dist/getPublishPayload-oH8wJhnH.d.ts.map +1 -0
- package/dist/dist/{getPublishUploads-C7-fYIgX.d.ts → getPublishUploads-Cex-NBe6.d.ts} +1 -1
- package/dist/dist/{getPublishUploads-C7-fYIgX.d.ts.map → getPublishUploads-Cex-NBe6.d.ts.map} +1 -1
- package/dist/dist/{index--mmQ3LQu.d.ts → index-BAao3_Po.d.ts} +5 -5
- package/dist/dist/index-BAao3_Po.d.ts.map +1 -0
- package/dist/dist/{index-B7yAoYli.d.ts → index-BbFwftAv.d.ts} +1 -1
- package/dist/dist/{index-B7yAoYli.d.ts.map → index-BbFwftAv.d.ts.map} +1 -1
- package/dist/dist/{index-CrvIcVFJ.d.ts → index-DpgQMIRq.d.ts} +8 -4
- package/dist/dist/index-DpgQMIRq.d.ts.map +1 -0
- package/dist/dist/{index.browser-BmVS-c2C.d.ts → index.browser-nndbVM7z.d.ts} +4 -4
- package/dist/dist/{index.browser-BmVS-c2C.d.ts.map → index.browser-nndbVM7z.d.ts.map} +1 -1
- package/dist/dist/{index.node-BKpbCAWt.d.ts → index.node-BUfx-JaP.d.ts} +1 -1
- package/dist/dist/{index.node-BKpbCAWt.d.ts.map → index.node-BUfx-JaP.d.ts.map} +1 -1
- package/dist/dist/platform.browser.d.ts +2 -2
- package/dist/dist/platform.node.d.ts +2 -2
- package/dist/dist/{property-DQ-Owzki.d.ts → property-BDBvImLs.d.ts} +3 -3
- package/dist/dist/property-BDBvImLs.d.ts.map +1 -0
- package/dist/dist/{propertyValidationRules-BDhFjlwP.d.ts → propertyValidationRules-BlfLn4rP.d.ts} +1 -1
- package/dist/dist/propertyValidationRules-BlfLn4rP.d.ts.map +1 -0
- package/dist/dist/{publishDraftGraph-CzPd9oe9.d.ts → publishDraftGraph-CLO85LLz.d.ts} +1 -1
- package/dist/dist/{publishDraftGraph-CzPd9oe9.d.ts.map → publishDraftGraph-CLO85LLz.d.ts.map} +1 -1
- package/dist/dist/{resetAmbiguousLegacyItemData-cXZm4NuG.d.ts → resetAmbiguousLegacyItemData-Cy8ik7xk.d.ts} +1 -1
- package/dist/dist/resetAmbiguousLegacyItemData-Cy8ik7xk.d.ts.map +1 -0
- package/dist/dist/{resolveModelForSyncedSeed-BgxtVCHI.d.ts → resolveModelForSyncedSeed-DFr4COc4.d.ts} +3 -3
- package/dist/dist/resolveModelForSyncedSeed-DFr4COc4.d.ts.map +1 -0
- package/dist/dist/{syncDbWithEas-Y5GysSCm.d.ts → syncDbWithEas-CAOlw3i-.d.ts} +1 -1
- package/dist/dist/syncDbWithEas-CAOlw3i-.d.ts.map +1 -0
- package/dist/dist/{tabEvents-D9x26vf2.d.ts → tabEvents-DksXwk3X.d.ts} +1 -1
- package/dist/dist/{tabEvents-D9x26vf2.d.ts.map → tabEvents-DksXwk3X.d.ts.map} +1 -1
- package/dist/dist/{tolerantWebAccess-BFU2t-SC.d.ts → tolerantWebAccess-CEIjFGf0.d.ts} +1 -1
- package/dist/dist/{tolerantWebAccess-BFU2t-SC.d.ts.map → tolerantWebAccess-CEIjFGf0.d.ts.map} +1 -1
- package/dist/dist/{updateSeedRevokedAt-CCF8WWYS.d.ts → updateSeedRevokedAt-Cjr35YjE.d.ts} +1 -1
- package/dist/dist/updateSeedRevokedAt-Cjr35YjE.d.ts.map +1 -0
- package/dist/{eas-CSm5wmry.js → eas-DOdj-EMK.js} +4 -4
- package/dist/eas-DOdj-EMK.js.map +1 -0
- package/dist/{errors-3tc6XkCB.js → errors-KM-yq2MD.js} +55 -41
- package/dist/errors-KM-yq2MD.js.map +1 -0
- package/dist/{getItem-DM3a-7XE.js → getItem-Bh0zv-o1.js} +4 -4
- package/dist/{getItem-DM3a-7XE.js.map → getItem-Bh0zv-o1.js.map} +1 -1
- package/dist/{getPublishPayload-CJF0k5d8.js → getPublishPayload-oH8wJhnH.js} +16 -25
- package/dist/getPublishPayload-oH8wJhnH.js.map +1 -0
- package/dist/{getPublishUploads-C7-fYIgX.js → getPublishUploads-Cex-NBe6.js} +10 -10
- package/dist/getPublishUploads-Cex-NBe6.js.map +1 -0
- package/dist/{index--mmQ3LQu.js → index-BAao3_Po.js} +9 -9
- package/dist/index-BAao3_Po.js.map +1 -0
- package/dist/{index-B7yAoYli.js → index-BbFwftAv.js} +2 -2
- package/dist/index-BbFwftAv.js.map +1 -0
- package/dist/{index-CrvIcVFJ.js → index-DpgQMIRq.js} +32 -15
- package/dist/index-DpgQMIRq.js.map +1 -0
- package/dist/{index.browser-BmVS-c2C.js → index.browser-nndbVM7z.js} +26 -28
- package/dist/index.browser-nndbVM7z.js.map +1 -0
- package/dist/{index.node-BKpbCAWt.js → index.node-BUfx-JaP.js} +7 -7
- package/dist/index.node-BUfx-JaP.js.map +1 -0
- package/dist/main.js +155 -26
- package/dist/main.js.map +1 -1
- package/dist/node.js +13 -13
- package/dist/node.js.map +1 -1
- package/dist/platform.browser.js +5 -5
- package/dist/platform.node.js +4 -4
- package/dist/{property-DQ-Owzki.js → property-BDBvImLs.js} +11 -11
- package/dist/property-BDBvImLs.js.map +1 -0
- package/dist/{propertyValidationRules-BDhFjlwP.js → propertyValidationRules-BlfLn4rP.js} +6 -6
- package/dist/{propertyValidationRules-BDhFjlwP.js.map → propertyValidationRules-BlfLn4rP.js.map} +1 -1
- package/dist/{publishDraftGraph-CzPd9oe9.js → publishDraftGraph-CLO85LLz.js} +7 -7
- package/dist/publishDraftGraph-CLO85LLz.js.map +1 -0
- package/dist/{resetAmbiguousLegacyItemData-cXZm4NuG.js → resetAmbiguousLegacyItemData-Cy8ik7xk.js} +2 -2
- package/dist/{resetAmbiguousLegacyItemData-cXZm4NuG.js.map → resetAmbiguousLegacyItemData-Cy8ik7xk.js.map} +1 -1
- package/dist/{resolveModelForSyncedSeed-BgxtVCHI.js → resolveModelForSyncedSeed-DFr4COc4.js} +4 -4
- package/dist/resolveModelForSyncedSeed-DFr4COc4.js.map +1 -0
- package/dist/src/Item/Item.d.ts +2 -2
- package/dist/src/Item/Item.d.ts.map +1 -1
- package/dist/src/Item/errors.d.ts +25 -0
- package/dist/src/Item/errors.d.ts.map +1 -1
- package/dist/src/Item/service/actors/loadOrCreateItem.d.ts.map +1 -1
- package/dist/src/Item/service/itemMachineSingle.d.ts.map +1 -1
- package/dist/src/ItemProperty/ItemProperty.d.ts +14 -3
- package/dist/src/ItemProperty/ItemProperty.d.ts.map +1 -1
- package/dist/src/ItemProperty/service/actors/hydrateFromDb.d.ts.map +1 -1
- package/dist/src/ItemProperty/service/actors/loadOrCreateProperty.d.ts.map +1 -1
- package/dist/src/ItemProperty/service/actors/resolveRelatedValue.d.ts.map +1 -1
- package/dist/src/ItemProperty/service/actors/saveValueToDb/analyzeInput.d.ts.map +1 -1
- package/dist/src/ItemProperty/service/actors/saveValueToDb/index.d.ts +0 -1
- package/dist/src/ItemProperty/service/actors/saveValueToDb/index.d.ts.map +1 -1
- package/dist/src/ItemProperty/service/actors/saveValueToDb/saveFile.d.ts.map +1 -1
- package/dist/src/ItemProperty/service/actors/saveValueToDb/saveHtml.d.ts.map +1 -1
- package/dist/src/ItemProperty/service/actors/saveValueToDb/saveImage.d.ts.map +1 -1
- package/dist/src/ItemProperty/service/actors/saveValueToDb/saveItemStorage.d.ts.map +1 -1
- package/dist/src/ItemProperty/service/propertyMachine.d.ts +1 -6
- package/dist/src/ItemProperty/service/propertyMachine.d.ts.map +1 -1
- package/dist/src/Model/Model.d.ts.map +1 -1
- package/dist/src/ModelProperty/ModelProperty.d.ts.map +1 -1
- package/dist/src/Schema/Schema.d.ts.map +1 -1
- package/dist/src/Schema/service/actors/loadOrCreateSchema.d.ts.map +1 -1
- package/dist/src/Schema/service/actors/writeSchemaToDb.d.ts.map +1 -1
- package/dist/src/Schema/service/validation/SchemaValidationService.d.ts +1 -1
- package/dist/src/Schema/service/validation/SchemaValidationService.d.ts.map +1 -1
- package/dist/src/Schema/validation.d.ts.map +1 -1
- package/dist/src/browser/db/Db.d.ts +1 -1
- package/dist/src/browser/db/Db.d.ts.map +1 -1
- package/dist/src/browser/helpers/PathResolver.d.ts +2 -2
- package/dist/src/browser/helpers/PathResolver.d.ts.map +1 -1
- package/dist/src/browser/seed.d.ts +1 -1
- package/dist/src/browser/seed.d.ts.map +1 -1
- package/dist/src/browser/workers/imageResize.d.ts.map +1 -1
- package/dist/src/client/BaseClientManager.d.ts +1 -1
- package/dist/src/client/BaseClientManager.d.ts.map +1 -1
- package/dist/src/client/ClientManager.d.ts +1 -0
- package/dist/src/client/ClientManager.d.ts.map +1 -1
- package/dist/src/client/actors/addModelsToDb.d.ts.map +1 -1
- package/dist/src/client/actors/fileSystemInit.d.ts.map +1 -1
- package/dist/src/client/actors/platformClassesInit.d.ts.map +1 -1
- package/dist/src/client/clientManagerMachine.d.ts.map +1 -1
- package/dist/src/client/constants.d.ts.map +1 -1
- package/dist/src/db/clearStoredDisplayUrls.d.ts +18 -0
- package/dist/src/db/clearStoredDisplayUrls.d.ts.map +1 -0
- package/dist/src/db/read/getItems.d.ts.map +1 -1
- package/dist/src/db/read/getPublishPayload.d.ts.map +1 -1
- package/dist/src/db/read/nameMatchLevels.d.ts +7 -3
- package/dist/src/db/read/nameMatchLevels.d.ts.map +1 -1
- package/dist/src/db/read/resolveModelForSyncedSeed.d.ts +2 -2
- package/dist/src/db/write/applyPropertyAttestationUidsFromPublish.d.ts +10 -0
- package/dist/src/db/write/applyPropertyAttestationUidsFromPublish.d.ts.map +1 -1
- package/dist/src/db/write/deleteItem.d.ts +4 -0
- package/dist/src/db/write/deleteItem.d.ts.map +1 -1
- package/dist/src/db/write/updateItemPropertyValue.d.ts.map +1 -1
- package/dist/src/eas.d.ts.map +1 -1
- package/dist/src/events/item/index.d.ts.map +1 -1
- package/dist/src/events/item/syncDbWithEas.d.ts.map +1 -1
- package/dist/src/events/services/allItems.d.ts +1 -1
- package/dist/src/events/services/allItems.d.ts.map +1 -1
- package/dist/src/helpers/db.d.ts.map +1 -1
- package/dist/src/helpers/file/fetchAll/actors.d.ts.map +1 -1
- package/dist/src/helpers/file/fetchAll/index.d.ts.map +1 -1
- package/dist/src/helpers/schema.d.ts.map +1 -1
- package/dist/src/helpers/updateSchema.d.ts +1 -1
- package/dist/src/helpers/updateSchema.d.ts.map +1 -1
- package/dist/src/imports/json.d.ts.map +1 -1
- package/dist/src/imports/markdown.d.ts +1 -1
- package/dist/src/imports/markdown.d.ts.map +1 -1
- package/dist/src/index.d.ts +1 -1
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/interfaces/IItem.d.ts +1 -1
- package/dist/src/interfaces/IItem.d.ts.map +1 -1
- package/dist/src/interfaces/IItemProperty.d.ts +5 -1
- package/dist/src/interfaces/IItemProperty.d.ts.map +1 -1
- package/dist/src/node/helpers/scripts.d.ts +1 -1
- package/dist/src/services/write/actors/validateEntity.d.ts.map +1 -1
- package/dist/src/services/write/writeProcessMachine.d.ts +3 -4
- package/dist/src/services/write/writeProcessMachine.d.ts.map +1 -1
- package/dist/src/types/fileManager.d.ts.map +1 -1
- package/dist/src/types/item.d.ts +5 -4
- package/dist/src/types/item.d.ts.map +1 -1
- package/dist/src/types/model.d.ts.map +1 -1
- package/dist/src/types/property.d.ts +5 -5
- package/dist/src/types/property.d.ts.map +1 -1
- package/dist/{syncDbWithEas-Y5GysSCm.js → syncDbWithEas-CAOlw3i-.js} +17 -18
- package/dist/syncDbWithEas-CAOlw3i-.js.map +1 -0
- package/dist/{tabEvents-D9x26vf2.js → tabEvents-DksXwk3X.js} +4 -4
- package/dist/{tabEvents-D9x26vf2.js.map → tabEvents-DksXwk3X.js.map} +1 -1
- package/dist/{tolerantWebAccess-BFU2t-SC.js → tolerantWebAccess-CEIjFGf0.js} +6 -6
- package/dist/{tolerantWebAccess-BFU2t-SC.js.map → tolerantWebAccess-CEIjFGf0.js.map} +1 -1
- package/dist/{updateSeedRevokedAt-CCF8WWYS.js → updateSeedRevokedAt-Cjr35YjE.js} +3 -3
- package/dist/{updateSeedRevokedAt-CCF8WWYS.js.map → updateSeedRevokedAt-Cjr35YjE.js.map} +1 -1
- package/package.json +6 -6
- package/dist/ClientManager-D6YA20jP.js.map +0 -1
- package/dist/Item-B1MH0tXx.js.map +0 -1
- package/dist/ModelProperty-Dw6dHdu_.js.map +0 -1
- package/dist/Schema-DppObO6h.js.map +0 -1
- package/dist/SchemaValidationService-DXQ-D531.js.map +0 -1
- package/dist/dist/ClientManager-D6YA20jP.d.ts.map +0 -1
- package/dist/dist/Item-B1MH0tXx.d.ts.map +0 -1
- package/dist/dist/backfillMetadataPropertyIds-Uhzlwg9X.d.ts.map +0 -1
- package/dist/dist/configurePlatform-CVoh3JeR.d.ts.map +0 -1
- package/dist/dist/detachRowsBeforeDelete-CtmIFpgV.d.ts.map +0 -1
- package/dist/dist/discardNewDraft-oGYdB5vS.d.ts.map +0 -1
- package/dist/dist/eas-CSm5wmry.d.ts.map +0 -1
- package/dist/dist/errors-3tc6XkCB.d.ts.map +0 -1
- package/dist/dist/getItem-DM3a-7XE.d.ts.map +0 -1
- package/dist/dist/getPublishPayload-CJF0k5d8.d.ts.map +0 -1
- package/dist/dist/index--mmQ3LQu.d.ts.map +0 -1
- package/dist/dist/index-CrvIcVFJ.d.ts.map +0 -1
- package/dist/dist/property-DQ-Owzki.d.ts.map +0 -1
- package/dist/dist/propertyValidationRules-BDhFjlwP.d.ts.map +0 -1
- package/dist/dist/resetAmbiguousLegacyItemData-cXZm4NuG.d.ts.map +0 -1
- package/dist/dist/resolveModelForSyncedSeed-BgxtVCHI.d.ts.map +0 -1
- package/dist/dist/syncDbWithEas-Y5GysSCm.d.ts.map +0 -1
- package/dist/dist/updateSeedRevokedAt-CCF8WWYS.d.ts.map +0 -1
- package/dist/eas-CSm5wmry.js.map +0 -1
- package/dist/errors-3tc6XkCB.js.map +0 -1
- package/dist/getPublishPayload-CJF0k5d8.js.map +0 -1
- package/dist/getPublishUploads-C7-fYIgX.js.map +0 -1
- package/dist/index--mmQ3LQu.js.map +0 -1
- package/dist/index-B7yAoYli.js.map +0 -1
- package/dist/index-CrvIcVFJ.js.map +0 -1
- package/dist/index.browser-BmVS-c2C.js.map +0 -1
- package/dist/index.node-BKpbCAWt.js.map +0 -1
- package/dist/property-DQ-Owzki.js.map +0 -1
- package/dist/publishDraftGraph-CzPd9oe9.js.map +0 -1
- package/dist/resolveModelForSyncedSeed-BgxtVCHI.js.map +0 -1
- package/dist/src/ItemProperty/service/actors/saveValueToDb/saveRelation.d.ts +0 -5
- package/dist/src/ItemProperty/service/actors/saveValueToDb/saveRelation.d.ts.map +0 -1
- package/dist/src/db/write/recoverDeletedItem.d.ts +0 -5
- package/dist/src/db/write/recoverDeletedItem.d.ts.map +0 -1
- package/dist/src/interfaces/IEasClient.d.ts +0 -3
- package/dist/src/interfaces/IEasClient.d.ts.map +0 -1
- package/dist/syncDbWithEas-Y5GysSCm.js.map +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { g as getItemData, I as Item } from './Item-
|
|
1
|
+
import { g as getItemData, I as Item } from './Item-D6j0IvBP.js';
|
|
2
2
|
import { startCase } from 'lodash-es';
|
|
3
3
|
import 'xstate';
|
|
4
|
-
import './index-
|
|
4
|
+
import './index-DpgQMIRq.js';
|
|
5
5
|
import 'debug';
|
|
6
6
|
import '@seedprotocol/arweave';
|
|
7
7
|
import '@seedprotocol/eas';
|
|
@@ -16,7 +16,7 @@ import '@noble/hashes/sha256';
|
|
|
16
16
|
import '@noble/hashes/sha3';
|
|
17
17
|
import '@noble/hashes/utils';
|
|
18
18
|
import 'rxjs';
|
|
19
|
-
import './tabEvents-
|
|
19
|
+
import './tabEvents-DksXwk3X.js';
|
|
20
20
|
import './model-oHA3YhOd.js';
|
|
21
21
|
|
|
22
22
|
const getItem = async ({ modelName, seedLocalId, seedUid }) => {
|
|
@@ -42,4 +42,4 @@ const getItem = async ({ modelName, seedLocalId, seedUid }) => {
|
|
|
42
42
|
};
|
|
43
43
|
|
|
44
44
|
export { getItem };
|
|
45
|
-
//# sourceMappingURL=getItem-
|
|
45
|
+
//# sourceMappingURL=getItem-Bh0zv-o1.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getItem-
|
|
1
|
+
{"version":3,"file":"getItem-Bh0zv-o1.js","sources":["../../src/db/read/getItem.ts"],"sourcesContent":["import { getItemData } from './getItemData'\nimport { GetItem } from '@/types'\nimport { Item } from '@/Item/Item'\nimport { startCase } from 'lodash-es'\n\nexport const getItem: GetItem = async ({ modelName, seedLocalId, seedUid }) => {\n const itemInitObj = await getItemData({\n modelName,\n seedLocalId,\n seedUid,\n })\n\n if (!itemInitObj) {\n console.error(\n `[db/queries] [getItem] no itemInitObj modelName: ${modelName} seedLocalId: ${seedLocalId} seedUid: ${seedUid}`,\n )\n return\n }\n\n if (!itemInitObj.seedLocalId) {\n console.error(\n `[db/queries] [getItem] no itemInitObj.seedLocalId modelName: ${modelName} seedLocalId: ${seedLocalId} seedUid: ${seedUid}`,\n )\n return\n }\n\n if (!itemInitObj.modelName && itemInitObj.type) {\n itemInitObj.modelName = startCase(itemInitObj.type)\n }\n\n // DB + loadOrCreateItem + concurrent property saves (e.g. during publish) can exceed the default 5s idle wait.\n const getItemReadyTimeoutMs = 120_000\n return Item.create(itemInitObj, { readyTimeout: getItemReadyTimeoutMs })\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;AAKO,MAAM,OAAO,GAAY,OAAO,EAAE,SAAS,EAAE,WAAW,EAAE,OAAO,EAAE,KAAI;AAC5E,IAAA,MAAM,WAAW,GAAG,MAAM,WAAW,CAAC;QACpC,SAAS;QACT,WAAW;QACX,OAAO;AACR,KAAA,CAAC;IAEF,IAAI,CAAC,WAAW,EAAE;QAChB,OAAO,CAAC,KAAK,CACX,CAAA,iDAAA,EAAoD,SAAS,CAAA,cAAA,EAAiB,WAAW,CAAA,UAAA,EAAa,OAAO,CAAA,CAAE,CAChH;QACD;IACF;AAEA,IAAA,IAAI,CAAC,WAAW,CAAC,WAAW,EAAE;QAC5B,OAAO,CAAC,KAAK,CACX,CAAA,6DAAA,EAAgE,SAAS,CAAA,cAAA,EAAiB,WAAW,CAAA,UAAA,EAAa,OAAO,CAAA,CAAE,CAC5H;QACD;IACF;IAEA,IAAI,CAAC,WAAW,CAAC,SAAS,IAAI,WAAW,CAAC,IAAI,EAAE;QAC9C,WAAW,CAAC,SAAS,GAAG,SAAS,CAAC,WAAW,CAAC,IAAI,CAAC;IACrD;;IAGA,MAAM,qBAAqB,GAAG,MAAO;AACrC,IAAA,OAAO,IAAI,CAAC,MAAM,CAAC,WAAW,EAAE,EAAE,YAAY,EAAE,qBAAqB,EAAE,CAAC;AAC1E;;"}
|
|
@@ -1,15 +1,14 @@
|
|
|
1
1
|
import { isValidEasAttestationUid, easName, decodeEasNumber, getSchemaUidForSchemaDefinitionFromCache, getEasSchemaUidForSchemaDefinition } from '@seedprotocol/eas';
|
|
2
|
-
import { a1 as isNode, a2 as ZERO_BYTES32, B as BaseDb, a3 as resolveModelRecord, a4 as getItemModelScope, v as properties, a5 as VERSION_SCHEMA_UID,
|
|
3
|
-
import { f as getEasSchemaUidForModel, h as getLatestPublishedVersionRow, p as parseListPropertyValueFromStorage } from './Item-
|
|
4
|
-
import { i as isSeedRevoked, a as getSegmentedItemProperties, f as findRelatedSeedRow, r as relatedModelNameFromDef, h as htmlPropertyNameForHtmlSeed, b as isUnpublishedSeed, c as isLivePublishedSeed, d as draftWalkProperties } from './publishDraftGraph-
|
|
5
|
-
import { getPropertySchema } from './property-
|
|
2
|
+
import { a1 as isNode, a2 as ZERO_BYTES32, B as BaseDb, a3 as resolveModelRecord, a4 as getItemModelScope, v as properties, a5 as VERSION_SCHEMA_UID, t as models, M as ModelPropertyDataTypes, V as resolveSeedIdsFromRefString, U as normalizeRelationPropertyValue, R as isPublishedSeedRef, p as htmlEmbeddedImageCoPublish, Q as getCorrectId, a6 as INTERNAL_PROPERTY_NAMES, a7 as isStorageSeedRef, n as normalizeDataType, a8 as defaultAttestationData, a9 as INTERNAL_DATA_TYPES, aa as listRelationEasPropertyName, ab as easPropertyNameForPublish } from './index-DpgQMIRq.js';
|
|
3
|
+
import { f as getEasSchemaUidForModel, h as getLatestPublishedVersionRow, p as parseListPropertyValueFromStorage } from './Item-D6j0IvBP.js';
|
|
4
|
+
import { i as isSeedRevoked, a as getSegmentedItemProperties, f as findRelatedSeedRow, r as relatedModelNameFromDef, h as htmlPropertyNameForHtmlSeed, b as isUnpublishedSeed, c as isLivePublishedSeed, d as draftWalkProperties } from './publishDraftGraph-CLO85LLz.js';
|
|
5
|
+
import { getPropertySchema } from './property-BDBvImLs.js';
|
|
6
6
|
import { modelPropertiesToObject } from './model-oHA3YhOd.js';
|
|
7
7
|
import { upperFirst, camelCase } from 'lodash-es';
|
|
8
8
|
import { and, eq, sql } from 'drizzle-orm';
|
|
9
|
-
import debug from 'debug';
|
|
10
9
|
import '@noble/hashes/sha3';
|
|
11
10
|
import '@noble/hashes/utils';
|
|
12
|
-
import './errors-
|
|
11
|
+
import './errors-KM-yq2MD.js';
|
|
13
12
|
|
|
14
13
|
let easSdkPromise;
|
|
15
14
|
/**
|
|
@@ -97,7 +96,6 @@ class RelatedItemUnpublishedError extends PublishValidationFailedError {
|
|
|
97
96
|
}
|
|
98
97
|
}
|
|
99
98
|
|
|
100
|
-
debug('seedSdk:db:getPublishPayload');
|
|
101
99
|
/** Case-insensitive dataType match (schema JSON may use "text" vs "Text"). */
|
|
102
100
|
const matchesDataType = (actual, expected) => normalizeDataType(actual) === expected;
|
|
103
101
|
/** True (and the property is deferred) when `targetSeedLocalId` is an item still in progress. */
|
|
@@ -227,7 +225,7 @@ async function resolveVersionUid(seedLocalId, seedUid) {
|
|
|
227
225
|
if (published?.uid)
|
|
228
226
|
return published.uid;
|
|
229
227
|
try {
|
|
230
|
-
const { getItemVersionsFromEas } = await import('./eas-
|
|
228
|
+
const { getItemVersionsFromEas } = await import('./eas-DOdj-EMK.js');
|
|
231
229
|
const attestations = await getItemVersionsFromEas({ seedUids: [seedUid] });
|
|
232
230
|
const latest = attestations?.[0];
|
|
233
231
|
if (latest?.id)
|
|
@@ -286,10 +284,6 @@ const getPropertyData = async (itemProperty, ctx) => {
|
|
|
286
284
|
* created before loadOrCreateProperty was fixed). Ensures both new and existing items get property attestations.
|
|
287
285
|
* Also ensures Relation/Image properties have required from schema when missing (for publish validation). */
|
|
288
286
|
const ensurePropertyDefs = async (targetItem) => {
|
|
289
|
-
targetItem.properties.filter((p) => targetItem.modelName &&
|
|
290
|
-
(!p.propertyDef ||
|
|
291
|
-
(matchesDataType(p.propertyDef?.dataType, ModelPropertyDataTypes.Relation) &&
|
|
292
|
-
p.propertyDef?.required === undefined)));
|
|
293
287
|
let schema;
|
|
294
288
|
// Model names are only unique per schema: resolve definitions from this item's own model.
|
|
295
289
|
const targetScope = await getItemModelScope(targetItem);
|
|
@@ -298,16 +292,14 @@ const ensurePropertyDefs = async (targetItem) => {
|
|
|
298
292
|
schema = await getPropertySchema(targetItem.modelName, itemProperty.propertyName, targetScope);
|
|
299
293
|
if (!schema) {
|
|
300
294
|
try {
|
|
301
|
-
const _mod_0 = await import('./errors-
|
|
302
|
-
const _ns_0 = _mod_0.
|
|
295
|
+
const _mod_0 = await import('./errors-KM-yq2MD.js');
|
|
296
|
+
const _ns_0 = _mod_0.j;
|
|
303
297
|
const { Model } = _ns_0;
|
|
304
298
|
const normalizedModelName = upperFirst(camelCase(targetItem.modelName));
|
|
305
299
|
let model = Model.resolve(normalizedModelName, targetScope);
|
|
306
300
|
if (!model?.properties?.length && !targetScope.modelFileId) {
|
|
307
301
|
model = Model.findByModelType(easName(targetItem.modelName));
|
|
308
302
|
}
|
|
309
|
-
const modelFound = !!model;
|
|
310
|
-
const propsCount = model?.properties?.length ?? 0;
|
|
311
303
|
const schemaKeys = [];
|
|
312
304
|
if (model?.properties?.length) {
|
|
313
305
|
const schemas = modelPropertiesToObject(model.properties);
|
|
@@ -315,7 +307,7 @@ const ensurePropertyDefs = async (targetItem) => {
|
|
|
315
307
|
schema = schemas[itemProperty.propertyName];
|
|
316
308
|
}
|
|
317
309
|
}
|
|
318
|
-
catch
|
|
310
|
+
catch {
|
|
319
311
|
schema = undefined;
|
|
320
312
|
}
|
|
321
313
|
}
|
|
@@ -397,7 +389,6 @@ const processBasicProperties = async (itemBasicProperties, itemPublishData, ctx,
|
|
|
397
389
|
? context.propertyValue
|
|
398
390
|
: (basicProperty.value ??
|
|
399
391
|
(context ? context.propertyValue : undefined));
|
|
400
|
-
!!basicProperty.uid;
|
|
401
392
|
if (!context) {
|
|
402
393
|
continue;
|
|
403
394
|
}
|
|
@@ -470,7 +461,7 @@ const processBasicProperties = async (itemBasicProperties, itemPublishData, ctx,
|
|
|
470
461
|
}
|
|
471
462
|
// Validate against property validation rules (enum, pattern, minLength, maxLength) before encoding
|
|
472
463
|
if (propertyDef?.validation) {
|
|
473
|
-
const { SchemaValidationService } = await import('./SchemaValidationService-
|
|
464
|
+
const { SchemaValidationService } = await import('./SchemaValidationService-BxCbfDaI.js');
|
|
474
465
|
const validationService = new SchemaValidationService();
|
|
475
466
|
const validationResult = validationService.validatePropertyValue(value, normalizeDataType(propertyDef.dataType), propertyDef.validation, propertyDef.refValueType
|
|
476
467
|
? normalizeDataType(propertyDef.refValueType)
|
|
@@ -532,7 +523,7 @@ const processBasicProperties = async (itemBasicProperties, itemPublishData, ctx,
|
|
|
532
523
|
}
|
|
533
524
|
value = decimal;
|
|
534
525
|
}
|
|
535
|
-
|
|
526
|
+
const data = [
|
|
536
527
|
{
|
|
537
528
|
name: propertyNameForSchema,
|
|
538
529
|
type: easDataType,
|
|
@@ -624,7 +615,7 @@ const processRelationOrImageProperty = async (relationOrImageProperty, multiPubl
|
|
|
624
615
|
matchesDataType(relationOrImageProperty.propertyDef?.refValueType, ModelPropertyDataTypes.Html) ||
|
|
625
616
|
matchesDataType(relationOrImageProperty.propertyDef?.refValueType, ModelPropertyDataTypes.Json)));
|
|
626
617
|
if (isStorageSeed && (context.seedLocalId || context.seedUid)) {
|
|
627
|
-
const _mod_1 = await import('./Item-
|
|
618
|
+
const _mod_1 = await import('./Item-D6j0IvBP.js');
|
|
628
619
|
const _ns_1 = _mod_1.a5;
|
|
629
620
|
const { getPropertyData: getPropertyDataFromDb } = _ns_1;
|
|
630
621
|
const metaRow = await getPropertyDataFromDb({
|
|
@@ -715,7 +706,7 @@ const processRelationOrImageProperty = async (relationOrImageProperty, multiPubl
|
|
|
715
706
|
return multiPublishPayload;
|
|
716
707
|
}
|
|
717
708
|
// Use dynamic import to break circular dependency
|
|
718
|
-
const getItemMod = await import('./getItem-
|
|
709
|
+
const getItemMod = await import('./getItem-Bh0zv-o1.js');
|
|
719
710
|
const { getItem } = getItemMod;
|
|
720
711
|
const relatedItem = await getItem(relatedSeed ? { seedLocalId: relatedSeed.seedLocalId } : { seedLocalId, seedUid });
|
|
721
712
|
if (noteRelatedSeed(ctx, normalizedRef, relatedSeed, relationOrImageProperty.propertyName, relatedItem?.modelName ?? relatedModelNameFromDef(relationOrImageProperty.propertyDef))) {
|
|
@@ -894,7 +885,7 @@ async function processHtmlEmbeddedCoPublishImagePayloads(item, multiPublishPaylo
|
|
|
894
885
|
if (rows.length === 0)
|
|
895
886
|
return multiPublishPayload;
|
|
896
887
|
const forceFullSnapshot = buildOpts?.forceFullSnapshot === true;
|
|
897
|
-
const getItemMod = await import('./getItem-
|
|
888
|
+
const getItemMod = await import('./getItem-Bh0zv-o1.js');
|
|
898
889
|
const { getItem } = getItemMod;
|
|
899
890
|
const doneImages = new Set();
|
|
900
891
|
for (const row of rows) {
|
|
@@ -1035,7 +1026,7 @@ const processListProperty = async (listProperty, multiPublishPayload, uploadedTr
|
|
|
1035
1026
|
if (memberLocalId && ctx.newSeedsInProgress?.has(memberLocalId))
|
|
1036
1027
|
continue;
|
|
1037
1028
|
// Use dynamic import to break circular dependency
|
|
1038
|
-
const getItemMod = await import('./getItem-
|
|
1029
|
+
const getItemMod = await import('./getItem-Bh0zv-o1.js');
|
|
1039
1030
|
const { getItem } = getItemMod;
|
|
1040
1031
|
const relatedItem = await getItem(relatedSeed ? { seedLocalId: relatedSeed.seedLocalId } : { seedLocalId, seedUid });
|
|
1041
1032
|
if (noteRelatedSeed(ctx, idStr.trim(), relatedSeed, listProperty.propertyName, relatedItem?.modelName ?? relatedModelNameFromDef(listProperty.propertyDef))) {
|
|
@@ -1637,4 +1628,4 @@ var getPublishPayload$1 = /*#__PURE__*/Object.freeze({
|
|
|
1637
1628
|
});
|
|
1638
1629
|
|
|
1639
1630
|
export { PublishValidationFailedError as P, RELATED_ITEM_UNPUBLISHED_CODE as R, RelatedItemUnpublishedError as a, getPublishPayload$1 as g, resolvePublishPayloadValues as r, validateItemForPublish as v };
|
|
1640
|
-
//# sourceMappingURL=getPublishPayload-
|
|
1631
|
+
//# sourceMappingURL=getPublishPayload-oH8wJhnH.js.map
|