@haverstack/core 0.41.0 → 0.42.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/README.md +121 -59
- package/dist/access.d.ts +34 -36
- package/dist/access.d.ts.map +1 -1
- package/dist/access.js +65 -42
- package/dist/access.js.map +1 -1
- package/dist/{combine.d.ts → adapter/combine.d.ts} +8 -1
- package/dist/adapter/combine.d.ts.map +1 -0
- package/dist/{combine.js → adapter/combine.js} +7 -0
- package/dist/adapter/combine.js.map +1 -0
- package/dist/{adapter-entry.d.ts → adapter/index.d.ts} +6 -5
- package/dist/adapter/index.d.ts.map +1 -0
- package/dist/{adapter-entry.js → adapter/index.js} +5 -4
- package/dist/adapter/index.js.map +1 -0
- package/dist/{sort.d.ts → adapter/sort.d.ts} +20 -20
- package/dist/adapter/sort.d.ts.map +1 -0
- package/dist/{sort.js → adapter/sort.js} +37 -27
- package/dist/adapter/sort.js.map +1 -0
- package/dist/associations/identity.d.ts +93 -0
- package/dist/associations/identity.d.ts.map +1 -0
- package/dist/associations/identity.js +198 -0
- package/dist/associations/identity.js.map +1 -0
- package/dist/associations/validation.d.ts +90 -0
- package/dist/associations/validation.d.ts.map +1 -0
- package/dist/associations/validation.js +339 -0
- package/dist/associations/validation.js.map +1 -0
- package/dist/attachment-records.d.ts +48 -0
- package/dist/attachment-records.d.ts.map +1 -0
- package/dist/attachment-records.js +52 -0
- package/dist/attachment-records.js.map +1 -0
- package/dist/collection.d.ts +182 -0
- package/dist/collection.d.ts.map +1 -0
- package/dist/collection.js +407 -0
- package/dist/collection.js.map +1 -0
- package/dist/content-match.d.ts +25 -0
- package/dist/content-match.d.ts.map +1 -0
- package/dist/content-match.js +51 -0
- package/dist/content-match.js.map +1 -0
- package/dist/content-translation.d.ts +42 -0
- package/dist/content-translation.d.ts.map +1 -0
- package/dist/content-translation.js +108 -0
- package/dist/content-translation.js.map +1 -0
- package/dist/did/did.d.ts.map +1 -0
- package/dist/{did.js → did/did.js} +3 -4
- package/dist/did/did.js.map +1 -0
- package/dist/{did-entry.d.ts → did/index.d.ts} +1 -1
- package/dist/did/index.d.ts.map +1 -0
- package/dist/{did-entry.js → did/index.js} +3 -3
- package/dist/did/index.js.map +1 -0
- package/dist/errors.d.ts +36 -63
- package/dist/errors.d.ts.map +1 -1
- package/dist/errors.js +35 -58
- package/dist/errors.js.map +1 -1
- package/dist/grants.d.ts +18 -42
- package/dist/grants.d.ts.map +1 -1
- package/dist/grants.js +68 -133
- package/dist/grants.js.map +1 -1
- package/dist/id.d.ts +13 -31
- package/dist/id.d.ts.map +1 -1
- package/dist/id.js +13 -31
- package/dist/id.js.map +1 -1
- package/dist/index.d.ts +12 -8
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +8 -5
- package/dist/index.js.map +1 -1
- package/dist/install.d.ts +3 -6
- package/dist/install.d.ts.map +1 -1
- package/dist/install.js +6 -10
- package/dist/install.js.map +1 -1
- package/dist/merge.d.ts.map +1 -1
- package/dist/merge.js +5 -11
- package/dist/merge.js.map +1 -1
- package/dist/migration-steps.d.ts +102 -0
- package/dist/migration-steps.d.ts.map +1 -0
- package/dist/migration-steps.js +293 -0
- package/dist/migration-steps.js.map +1 -0
- package/dist/query-validation.d.ts +28 -94
- package/dist/query-validation.d.ts.map +1 -1
- package/dist/query-validation.js +156 -336
- package/dist/query-validation.js.map +1 -1
- package/dist/record-changes.d.ts +2 -117
- package/dist/record-changes.d.ts.map +1 -1
- package/dist/record-changes.js +10 -212
- package/dist/record-changes.js.map +1 -1
- package/dist/schema.d.ts +18 -7
- package/dist/schema.d.ts.map +1 -1
- package/dist/schema.js +59 -30
- package/dist/schema.js.map +1 -1
- package/dist/scoped-stack/authority.d.ts +156 -0
- package/dist/scoped-stack/authority.d.ts.map +1 -0
- package/dist/scoped-stack/authority.js +384 -0
- package/dist/scoped-stack/authority.js.map +1 -0
- package/dist/scoped-stack/scoped-stack.d.ts +338 -0
- package/dist/scoped-stack/scoped-stack.d.ts.map +1 -0
- package/dist/scoped-stack/scoped-stack.js +776 -0
- package/dist/scoped-stack/scoped-stack.js.map +1 -0
- package/dist/scoped-stack/subscription.d.ts +55 -0
- package/dist/scoped-stack/subscription.d.ts.map +1 -0
- package/dist/scoped-stack/subscription.js +110 -0
- package/dist/scoped-stack/subscription.js.map +1 -0
- package/dist/stack/attachments.d.ts +24 -0
- package/dist/stack/attachments.d.ts.map +1 -0
- package/dist/stack/attachments.js +113 -0
- package/dist/stack/attachments.js.map +1 -0
- package/dist/{changes.d.ts → stack/changes.d.ts} +29 -65
- package/dist/stack/changes.d.ts.map +1 -0
- package/dist/{changes.js → stack/changes.js} +32 -66
- package/dist/stack/changes.js.map +1 -0
- package/dist/stack/client.d.ts +271 -0
- package/dist/stack/client.d.ts.map +1 -0
- package/dist/stack/client.js +9 -0
- package/dist/stack/client.js.map +1 -0
- package/dist/stack/identity-bindings.d.ts.map +1 -0
- package/dist/{identity-bindings.js → stack/identity-bindings.js} +5 -14
- package/dist/stack/identity-bindings.js.map +1 -0
- package/dist/stack/install-app.d.ts +22 -0
- package/dist/stack/install-app.d.ts.map +1 -0
- package/dist/stack/install-app.js +260 -0
- package/dist/stack/install-app.js.map +1 -0
- package/dist/stack/integrity.d.ts +94 -0
- package/dist/stack/integrity.d.ts.map +1 -0
- package/dist/stack/integrity.js +268 -0
- package/dist/stack/integrity.js.map +1 -0
- package/dist/{limits.d.ts → stack/limits.d.ts} +2 -5
- package/dist/stack/limits.d.ts.map +1 -0
- package/dist/{limits.js → stack/limits.js} +3 -6
- package/dist/stack/limits.js.map +1 -0
- package/dist/stack/migrations.d.ts +59 -0
- package/dist/stack/migrations.d.ts.map +1 -0
- package/dist/stack/migrations.js +141 -0
- package/dist/stack/migrations.js.map +1 -0
- package/dist/{stack-reads.d.ts → stack/reads.d.ts} +33 -6
- package/dist/stack/reads.d.ts.map +1 -0
- package/dist/{stack-reads.js → stack/reads.js} +49 -7
- package/dist/stack/reads.js.map +1 -0
- package/dist/stack/record-id.d.ts +35 -0
- package/dist/stack/record-id.d.ts.map +1 -0
- package/dist/stack/record-id.js +82 -0
- package/dist/stack/record-id.js.map +1 -0
- package/dist/stack/stack.d.ts +438 -0
- package/dist/stack/stack.d.ts.map +1 -0
- package/dist/stack/stack.js +1366 -0
- package/dist/stack/stack.js.map +1 -0
- package/dist/stack/system-types.d.ts +16 -0
- package/dist/stack/system-types.d.ts.map +1 -0
- package/dist/stack/system-types.js +111 -0
- package/dist/stack/system-types.js.map +1 -0
- package/dist/stack/type-grants.d.ts +20 -0
- package/dist/stack/type-grants.d.ts.map +1 -0
- package/dist/stack/type-grants.js +69 -0
- package/dist/stack/type-grants.js.map +1 -0
- package/dist/stack/write-expectation.d.ts +78 -0
- package/dist/stack/write-expectation.d.ts.map +1 -0
- package/dist/stack/write-expectation.js +71 -0
- package/dist/stack/write-expectation.js.map +1 -0
- package/dist/testing.d.ts +21 -26
- package/dist/testing.d.ts.map +1 -1
- package/dist/testing.js +50 -70
- package/dist/testing.js.map +1 -1
- package/dist/type-handle.d.ts +67 -78
- package/dist/type-handle.d.ts.map +1 -1
- package/dist/type-handle.js +44 -111
- package/dist/type-handle.js.map +1 -1
- package/dist/types/adapter.d.ts +223 -0
- package/dist/types/adapter.d.ts.map +1 -0
- package/dist/types/adapter.js +5 -0
- package/dist/types/adapter.js.map +1 -0
- package/dist/types/associations.d.ts +156 -0
- package/dist/types/associations.d.ts.map +1 -0
- package/dist/types/associations.js +13 -0
- package/dist/types/associations.js.map +1 -0
- package/dist/types/capabilities.d.ts +89 -0
- package/dist/types/capabilities.d.ts.map +1 -0
- package/dist/types/capabilities.js +5 -0
- package/dist/types/capabilities.js.map +1 -0
- package/dist/types/events.d.ts +155 -0
- package/dist/types/events.d.ts.map +1 -0
- package/dist/types/events.js +5 -0
- package/dist/types/events.js.map +1 -0
- package/dist/types/ids.d.ts +43 -0
- package/dist/types/ids.d.ts.map +1 -0
- package/dist/types/ids.js +5 -0
- package/dist/types/ids.js.map +1 -0
- package/dist/types/index.d.ts +19 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/index.js +19 -0
- package/dist/types/index.js.map +1 -0
- package/dist/types/journal.d.ts +47 -0
- package/dist/types/journal.d.ts.map +1 -0
- package/dist/types/journal.js +5 -0
- package/dist/types/journal.js.map +1 -0
- package/dist/types/query.d.ts +185 -0
- package/dist/types/query.d.ts.map +1 -0
- package/dist/types/query.js +10 -0
- package/dist/types/query.js.map +1 -0
- package/dist/types/records.d.ts +76 -0
- package/dist/types/records.d.ts.map +1 -0
- package/dist/types/records.js +5 -0
- package/dist/types/records.js.map +1 -0
- package/dist/types/schema.d.ts +74 -0
- package/dist/types/schema.d.ts.map +1 -0
- package/dist/types/schema.js +5 -0
- package/dist/types/schema.js.map +1 -0
- package/dist/types/system.d.ts +161 -0
- package/dist/types/system.d.ts.map +1 -0
- package/dist/types/system.js +32 -0
- package/dist/types/system.js.map +1 -0
- package/dist/types/tokens.d.ts +39 -0
- package/dist/types/tokens.d.ts.map +1 -0
- package/dist/types/tokens.js +5 -0
- package/dist/types/tokens.js.map +1 -0
- package/dist/validate.d.ts +29 -70
- package/dist/validate.d.ts.map +1 -1
- package/dist/validate.js +50 -91
- package/dist/validate.js.map +1 -1
- package/dist/{attachment-download.d.ts → wire/attachment-download.d.ts} +0 -57
- package/dist/wire/attachment-download.d.ts.map +1 -0
- package/dist/{attachment-download.js → wire/attachment-download.js} +0 -61
- package/dist/wire/attachment-download.js.map +1 -0
- package/dist/{auth.d.ts → wire/auth.d.ts} +5 -8
- package/dist/wire/auth.d.ts.map +1 -0
- package/dist/{auth.js → wire/auth.js} +5 -8
- package/dist/wire/auth.js.map +1 -0
- package/dist/{wire-body.d.ts → wire/body.d.ts} +4 -4
- package/dist/wire/body.d.ts.map +1 -0
- package/dist/{wire-body.js → wire/body.js} +5 -5
- package/dist/wire/body.js.map +1 -0
- package/dist/{wire-entry.d.ts → wire/index.d.ts} +12 -12
- package/dist/wire/index.d.ts.map +1 -0
- package/dist/{wire-entry.js → wire/index.js} +13 -17
- package/dist/wire/index.js.map +1 -0
- package/dist/{wire-record.d.ts → wire/record.d.ts} +10 -22
- package/dist/wire/record.d.ts.map +1 -0
- package/dist/{wire-record.js → wire/record.js} +12 -24
- package/dist/wire/record.js.map +1 -0
- package/dist/{wire-request.d.ts → wire/request.d.ts} +20 -37
- package/dist/wire/request.d.ts.map +1 -0
- package/dist/{wire-request.js → wire/request.js} +79 -54
- package/dist/wire/request.js.map +1 -0
- package/package.json +7 -7
- package/dist/adapter-entry.d.ts.map +0 -1
- package/dist/adapter-entry.js.map +0 -1
- package/dist/attachment-download.d.ts.map +0 -1
- package/dist/attachment-download.js.map +0 -1
- package/dist/auth.d.ts.map +0 -1
- package/dist/auth.js.map +0 -1
- package/dist/changes.d.ts.map +0 -1
- package/dist/changes.js.map +0 -1
- package/dist/combine.d.ts.map +0 -1
- package/dist/combine.js.map +0 -1
- package/dist/did-entry.d.ts.map +0 -1
- package/dist/did-entry.js.map +0 -1
- package/dist/did.d.ts.map +0 -1
- package/dist/did.js.map +0 -1
- package/dist/identity-bindings.d.ts.map +0 -1
- package/dist/identity-bindings.js.map +0 -1
- package/dist/limits.d.ts.map +0 -1
- package/dist/limits.js.map +0 -1
- package/dist/record-id.d.ts +0 -70
- package/dist/record-id.d.ts.map +0 -1
- package/dist/record-id.js +0 -127
- package/dist/record-id.js.map +0 -1
- package/dist/scoped-stack.d.ts +0 -549
- package/dist/scoped-stack.d.ts.map +0 -1
- package/dist/scoped-stack.js +0 -1301
- package/dist/scoped-stack.js.map +0 -1
- package/dist/sort.d.ts.map +0 -1
- package/dist/sort.js.map +0 -1
- package/dist/stack-reads.d.ts.map +0 -1
- package/dist/stack-reads.js.map +0 -1
- package/dist/stack.d.ts +0 -1032
- package/dist/stack.d.ts.map +0 -1
- package/dist/stack.js +0 -2337
- package/dist/stack.js.map +0 -1
- package/dist/types.d.ts +0 -1278
- package/dist/types.d.ts.map +0 -1
- package/dist/types.js +0 -51
- package/dist/types.js.map +0 -1
- package/dist/wire-body.d.ts.map +0 -1
- package/dist/wire-body.js.map +0 -1
- package/dist/wire-entry.d.ts.map +0 -1
- package/dist/wire-entry.js.map +0 -1
- package/dist/wire-record.d.ts.map +0 -1
- package/dist/wire-record.js.map +0 -1
- package/dist/wire-request.d.ts.map +0 -1
- package/dist/wire-request.js.map +0 -1
- /package/dist/{did.d.ts → did/did.d.ts} +0 -0
- /package/dist/{identity-bindings.d.ts → stack/identity-bindings.d.ts} +0 -0
package/dist/index.d.ts
CHANGED
|
@@ -17,23 +17,27 @@
|
|
|
17
17
|
* adapter-api, record-adapter-sqlite, record-adapter-do-sqlite,
|
|
18
18
|
* blob-adapter-disk and blob-adapter-s3, all under @haverstack/.
|
|
19
19
|
*/
|
|
20
|
-
export { Stack } from './stack.js';
|
|
21
|
-
export { ScopedStack } from './scoped-stack.js';
|
|
22
|
-
export type { StackClient, CreateRecordOptions, BackdatableCreateRecordOptions, StackOptions, DefineTypeOptions, GetRecordOptions, DeleteRecordOptions, DeleteResult, DeleteAndReturnResult, CollectAttachmentGarbageOptions, CollectAttachmentGarbageResult, MigrateAllOptions, } from './stack.js';
|
|
20
|
+
export { Stack } from './stack/stack.js';
|
|
21
|
+
export { ScopedStack } from './scoped-stack/scoped-stack.js';
|
|
22
|
+
export type { StackClient, CreateRecordOptions, BackdatableCreateRecordOptions, StackOptions, DefineTypeOptions, GetRecordOptions, DeleteRecordOptions, DeleteResult, DeleteAndReturnResult, CollectAttachmentGarbageOptions, CollectAttachmentGarbageResult, MigrateAllOptions, } from './stack/client.js';
|
|
23
23
|
export type { AppManifest, InstallPlan, ForeignRequest, TypeChange } from './install.js';
|
|
24
24
|
export { isPlanEmpty } from './install.js';
|
|
25
|
-
export { typeHandle } from './type-handle.js';
|
|
26
|
-
export
|
|
25
|
+
export { typeHandle, migration } from './type-handle.js';
|
|
26
|
+
export { rename, map, add, drop, derive } from './migration-steps.js';
|
|
27
|
+
export type { MigrationStep, RenameStep, MapStep, AddStep, DropStep, DeriveStep, } from './migration-steps.js';
|
|
28
|
+
export type { TypeHandle, Migration, ContentOf, StoredContentOf, UnlistedValue, ReadonlyFieldDef, ReadonlyTypeSchema, } from './type-handle.js';
|
|
29
|
+
export { MisfitError } from './collection.js';
|
|
30
|
+
export type { Collection, CollectionRecord, CollectionPage, CollectionQuery, CollectionChange, CollectionChangeSet, CollectionSubscribeOptions, ContentPatch, ContentPathOf, Misfit, SortableFieldOf, StoredContent, } from './collection.js';
|
|
27
31
|
export { StackError, StackValidationError, StackMigrationError, StackPermissionError, StackNotFoundError, StackConflictError, StackVersionConflictError, StackBadRequestError, StackSchemaDriftError, StackPayloadTooLargeError, StackTimeoutError, } from './errors.js';
|
|
28
32
|
export { UseAfterCloseError, InvalidAdapterError, RelayScopeError } from './errors.js';
|
|
29
33
|
export type { StackErrorCode } from './errors.js';
|
|
30
|
-
export type { RecordId, TypeId, BaseId, FileId, EntityId, AppId, AttachmentContent, StackRecord, RecordChangeSet, RecordVersion, RecordJournalEntry, JournalQuery, VersionsQuery, Actor, ActorOptions, ChangeKind, ChangeOp, ChangeActor, RecordChange, ChangeFilter, SubscribeOptions, Unsubscribe, StackType, TypeSchema, FieldDef, ScalarFieldDef, ArrayFieldDef, ObjectFieldDef, ScalarFieldKind, Association, TagAssociation, AttachmentAssociation, RelationshipAssociation, PermissionAssociation, Grantee, GroupRole, AnyoneAssociation, AuthorityAssociation, DataAssociation, AssociationChange, AssociationEdit, RelationshipTarget, RecordTarget, EntityTarget, ExternalTarget, StackQuery, RecordFilter, RelatedToFilter, AttachmentFilter, RelationshipTargetPattern, QuerySort,
|
|
34
|
+
export type { RecordId, TypeId, BaseId, FileId, EntityId, AppId, AttachmentContent, StackRecord, RecordChangeSet, RecordVersion, RecordJournalEntry, JournalQuery, VersionsQuery, Actor, ActorOptions, ChangeKind, ChangeOp, ChangeActor, RecordChange, ChangeFilter, SubscribeOptions, Unsubscribe, StackType, TypeSchema, FieldDef, ScalarFieldDef, EnumFieldDef, ArrayFieldDef, ObjectFieldDef, ScalarFieldKind, Association, TagAssociation, AttachmentAssociation, RelationshipAssociation, PermissionAssociation, Grantee, GroupRole, AnyoneAssociation, AuthorityAssociation, DataAssociation, AssociationChange, AssociationEdit, RelationshipTarget, RecordTarget, EntityTarget, ExternalTarget, StackQuery, RecordFilter, RelatedToFilter, AttachmentFilter, RelationshipTargetPattern, QuerySort, ContentArm, ContentSortKey, NativeSortField, QueryResult, DateRange, StackCapabilities, ContentFilterReach, MissingCapability, IfVersionOptions, EntityContent, AppContent, GroupContent, GrantAction, GrantContent, GrantGrantee, InstallContent, InstallRequest, TypeGrant, PutAttachmentOptions, ConfigContent, } from './types/index.js';
|
|
31
35
|
export type { GrantQuery } from './grants.js';
|
|
32
|
-
export { SYSTEM_TYPES, NATIVE_SORT_FIELDS } from './types.js';
|
|
36
|
+
export { SYSTEM_TYPES, NATIVE_SORT_FIELDS } from './types/index.js';
|
|
33
37
|
export { generateId } from './id.js';
|
|
34
38
|
export { hashSchema, isCompatible } from './schema.js';
|
|
35
39
|
export type { SchemaDriftViolation } from './schema.js';
|
|
36
40
|
export type { ValidationError } from './validate.js';
|
|
37
41
|
export { applyMergePatch } from './merge.js';
|
|
38
|
-
export { assertOneSurface } from './
|
|
42
|
+
export { assertOneSurface, isAuthorityAssociation } from './associations/identity.js';
|
|
39
43
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,EAAE,KAAK,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,EAAE,KAAK,EAAE,MAAM,kBAAkB,CAAC;AACzC,OAAO,EAAE,WAAW,EAAE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,aAAa,CAAC;AACxD,YAAY,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AACrD,OAAO,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,EAAE,gBAAgB,EAAE,sBAAsB,EAAE,MAAM,4BAA4B,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -18,22 +18,25 @@
|
|
|
18
18
|
* blob-adapter-disk and blob-adapter-s3, all under @haverstack/.
|
|
19
19
|
*/
|
|
20
20
|
// Core class and client interface
|
|
21
|
-
export { Stack } from './stack.js';
|
|
22
|
-
export { ScopedStack } from './scoped-stack.js';
|
|
21
|
+
export { Stack } from './stack/stack.js';
|
|
22
|
+
export { ScopedStack } from './scoped-stack/scoped-stack.js';
|
|
23
23
|
export { isPlanEmpty } from './install.js';
|
|
24
24
|
// Type handles
|
|
25
|
-
export { typeHandle } from './type-handle.js';
|
|
25
|
+
export { typeHandle, migration } from './type-handle.js';
|
|
26
|
+
export { rename, map, add, drop, derive } from './migration-steps.js';
|
|
27
|
+
// Collections
|
|
28
|
+
export { MisfitError } from './collection.js';
|
|
26
29
|
// The error taxonomy
|
|
27
30
|
export { StackError, StackValidationError, StackMigrationError, StackPermissionError, StackNotFoundError, StackConflictError, StackVersionConflictError, StackBadRequestError, StackSchemaDriftError, StackPayloadTooLargeError, StackTimeoutError, } from './errors.js';
|
|
28
31
|
// Local errors outside the taxonomy — no wire representation, and no
|
|
29
32
|
// `Stack` prefix. See docs/spec/wire-format.md § The taxonomy root.
|
|
30
33
|
export { UseAfterCloseError, InvalidAdapterError, RelayScopeError } from './errors.js';
|
|
31
|
-
export { SYSTEM_TYPES, NATIVE_SORT_FIELDS } from './types.js';
|
|
34
|
+
export { SYSTEM_TYPES, NATIVE_SORT_FIELDS } from './types/index.js';
|
|
32
35
|
// Utilities
|
|
33
36
|
// No in-repo caller: client-minted IDs are the default per spec, and an app
|
|
34
37
|
// needing the ID before the write round-trips has to mint one itself.
|
|
35
38
|
export { generateId } from './id.js';
|
|
36
39
|
export { hashSchema, isCompatible } from './schema.js';
|
|
37
40
|
export { applyMergePatch } from './merge.js';
|
|
38
|
-
export { assertOneSurface } from './
|
|
41
|
+
export { assertOneSurface, isAuthorityAssociation } from './associations/identity.js';
|
|
39
42
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,kCAAkC;AAClC,OAAO,EAAE,KAAK,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,kCAAkC;AAClC,OAAO,EAAE,KAAK,EAAE,MAAM,kBAAkB,CAAC;AACzC,OAAO,EAAE,WAAW,EAAE,MAAM,gCAAgC,CAAC;AAgB7D,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAE3C,eAAe;AACf,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AACzD,OAAO,EAAE,MAAM,EAAE,GAAG,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAmBtE,cAAc;AACd,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAgB9C,qBAAqB;AACrB,OAAO,EACL,UAAU,EACV,oBAAoB,EACpB,mBAAmB,EACnB,oBAAoB,EACpB,kBAAkB,EAClB,kBAAkB,EAClB,yBAAyB,EACzB,oBAAoB,EACpB,qBAAqB,EACrB,yBAAyB,EACzB,iBAAiB,GAClB,MAAM,aAAa,CAAC;AACrB,qEAAqE;AACrE,oEAAoE;AACpE,OAAO,EAAE,kBAAkB,EAAE,mBAAmB,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AAiFvF,OAAO,EAAE,YAAY,EAAE,kBAAkB,EAAE,MAAM,kBAAkB,CAAC;AAEpE,YAAY;AAEZ,4EAA4E;AAC5E,sEAAsE;AACtE,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AACrC,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAGvD,OAAO,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,EAAE,gBAAgB,EAAE,sBAAsB,EAAE,MAAM,4BAA4B,CAAC"}
|
package/dist/install.d.ts
CHANGED
|
@@ -16,10 +16,10 @@
|
|
|
16
16
|
*
|
|
17
17
|
* This module holds the parts that read an install as data: the write-time
|
|
18
18
|
* shape rules, the family claim, and the plan diff. The verbs that write
|
|
19
|
-
*
|
|
19
|
+
* are in stack/install-app.ts. See docs/spec/apps.md.
|
|
20
20
|
*/
|
|
21
|
-
import type { AppId, AuthorityAssociation, BaseId, EntityId, GrantContent, InstallContent, InstallRequest, RecordId, RelationshipAssociation, StackRecord, TypeId } from './types.js';
|
|
22
|
-
import type { DefineTypeOptions } from './stack.js';
|
|
21
|
+
import type { AppId, AuthorityAssociation, BaseId, EntityId, GrantContent, InstallContent, InstallRequest, RecordId, RelationshipAssociation, StackRecord, TypeId } from './types/index.js';
|
|
22
|
+
import type { DefineTypeOptions } from './stack/client.js';
|
|
23
23
|
import type { ValidationError } from './validate.js';
|
|
24
24
|
/** What an app ships: the types it defines and the grants it asks for. */
|
|
25
25
|
export type AppManifest = {
|
|
@@ -93,9 +93,6 @@ export declare const installGrantLink: (recordId: RecordId) => RelationshipAssoc
|
|
|
93
93
|
export declare const installReader: (entityId: EntityId) => AuthorityAssociation;
|
|
94
94
|
/** Record ids an install links to under `label`. */
|
|
95
95
|
export declare function linkedIds(record: StackRecord, label: string): RecordId[];
|
|
96
|
-
export declare const isSystemFamily: (baseId: BaseId) => boolean;
|
|
97
|
-
/** The Schema Commons namespace: families no app owns. See docs/commons/README.md. */
|
|
98
|
-
export declare const COMMONS_NAMESPACE = "org.haverstack";
|
|
99
96
|
/** The part of a family before its `/` — `com.example.notes` for `com.example.notes/note`. */
|
|
100
97
|
export declare const namespaceOf: (baseId: BaseId) => string | null;
|
|
101
98
|
/**
|
package/dist/install.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"install.d.ts","sourceRoot":"","sources":["../src/install.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAKH,OAAO,KAAK,EACV,KAAK,EACL,oBAAoB,EACpB,MAAM,EACN,QAAQ,EAER,YAAY,EACZ,cAAc,EACd,cAAc,EACd,QAAQ,EACR,uBAAuB,EACvB,WAAW,EACX,MAAM,EACP,MAAM,
|
|
1
|
+
{"version":3,"file":"install.d.ts","sourceRoot":"","sources":["../src/install.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAKH,OAAO,KAAK,EACV,KAAK,EACL,oBAAoB,EACpB,MAAM,EACN,QAAQ,EAER,YAAY,EACZ,cAAc,EACd,cAAc,EACd,QAAQ,EACR,uBAAuB,EACvB,WAAW,EACX,MAAM,EACP,MAAM,kBAAkB,CAAC;AAC1B,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAC3D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AAErD,0EAA0E;AAC1E,MAAM,MAAM,WAAW,GAAG;IACxB,KAAK,EAAE,KAAK,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,iBAAiB,EAAE,CAAC;IAC3B,QAAQ,EAAE,cAAc,EAAE,CAAC;CAC5B,CAAC;AAEF,oFAAoF;AACpF,MAAM,MAAM,cAAc,GAAG,cAAc,GAAG;IAC5C;;;;OAIG;IACH,KAAK,EAAE,KAAK,GAAG,SAAS,GAAG,QAAQ,GAAG,IAAI,CAAC;CAC5C,CAAC;AAEF;;;;GAIG;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,KAAG,MAAM,GAAG,IAGrD,CAAC;AAEF;;;;;;GAMG;AACH,wBAAgB,cAAc,CAC5B,MAAM,EAAE,MAAM,EACd,KAAK,EAAE,KAAK,GACX,KAAK,GAAG,SAAS,GAAG,QAAQ,GAAG,SAAS,CAK1C;AAED;;;GAGG;AACH,wBAAgB,eAAe,CAAC,OAAO,EAAE,OAAO,GAAG,GAAG,CAAC,MAAM,CAAC,CAU7D;AAED;;;;GAIG;AACH,wBAAgB,eAAe,CAAC,MAAM,EAAE,MAAM,EAAE,OAAO,EAAE,OAAO,GAAG,eAAe,EAAE,CA0CnF;AAED,yFAAyF;AACzF,wBAAgB,UAAU,CAAC,QAAQ,EAAE,WAAW,GAAG,MAAM,EAAE,CAK1D;AAED;;;GAGG;AACH,wBAAgB,gBAAgB,CAAC,QAAQ,EAAE,WAAW,GAAG,WAAW,CAEnE;AAUD,iFAAiF;AACjF,wBAAgB,WAAW,CAAC,CAAC,EAAE,cAAc,EAAE,CAAC,EAAE,cAAc,GAAG,OAAO,CAEzE;AAED,sEAAsE;AACtE,wBAAgB,cAAc,CAC5B,KAAK,EAAE,YAAY,EACnB,OAAO,EAAE,cAAc,EACvB,GAAG,EAAE,QAAQ,GACZ,OAAO,CAIT;AAED;;;;;;GAMG;AACH,wBAAgB,WAAW,CAAC,IAAI,EAAE,WAAW,GAAG,OAAO,CAatD;AAED;;;GAGG;AACH,wBAAgB,eAAe,CAAC,IAAI,EAAE,WAAW,GAAG,MAAM,CAczD"}
|
package/dist/install.js
CHANGED
|
@@ -16,11 +16,11 @@
|
|
|
16
16
|
*
|
|
17
17
|
* This module holds the parts that read an install as data: the write-time
|
|
18
18
|
* shape rules, the family claim, and the plan diff. The verbs that write
|
|
19
|
-
*
|
|
19
|
+
* are in stack/install-app.ts. See docs/spec/apps.md.
|
|
20
20
|
*/
|
|
21
21
|
import { baseIdOf, familyIdProblem, parseTypeId } from './schema.js';
|
|
22
|
-
import { GRANT_ACTION_SET, UNGRANTABLE_SYSTEM_TYPES } from './grants.js';
|
|
23
|
-
import { SYSTEM_TYPES } from './types.js';
|
|
22
|
+
import { GRANT_ACTION_SET, UNGRANTABLE_SYSTEM_TYPES, sameActions } from './grants.js';
|
|
23
|
+
import { SYSTEM_TYPES } from './types/index.js';
|
|
24
24
|
/** Relationship label from an install to an `_app` card it was installed for. */
|
|
25
25
|
export const INSTALL_APP_LABEL = 'install.app';
|
|
26
26
|
/** Relationship label from an install to a `_grant` it produced. */
|
|
@@ -52,9 +52,9 @@ export function linkedIds(record, label) {
|
|
|
52
52
|
return ids;
|
|
53
53
|
}
|
|
54
54
|
const SYSTEM_FAMILIES = new Set(Object.values(SYSTEM_TYPES));
|
|
55
|
-
|
|
55
|
+
const isSystemFamily = (baseId) => SYSTEM_FAMILIES.has(baseId);
|
|
56
56
|
/** The Schema Commons namespace: families no app owns. See docs/commons/README.md. */
|
|
57
|
-
|
|
57
|
+
const COMMONS_NAMESPACE = 'org.haverstack';
|
|
58
58
|
/** The part of a family before its `/` — `com.example.notes` for `com.example.notes/note`. */
|
|
59
59
|
export const namespaceOf = (baseId) => {
|
|
60
60
|
const slash = baseId.indexOf('/');
|
|
@@ -168,11 +168,7 @@ function deepFreeze(value) {
|
|
|
168
168
|
}
|
|
169
169
|
/** Whether two requests ask for the same family and exactly the same actions. */
|
|
170
170
|
export function sameRequest(a, b) {
|
|
171
|
-
|
|
172
|
-
return false;
|
|
173
|
-
const as = new Set(a.actions);
|
|
174
|
-
const bs = new Set(b.actions);
|
|
175
|
-
return as.size === bs.size && [...bs].every((x) => as.has(x));
|
|
171
|
+
return a.baseId === b.baseId && sameActions(a.actions, b.actions);
|
|
176
172
|
}
|
|
177
173
|
/** Whether a stored grant is exactly `request`, made out to `did`. */
|
|
178
174
|
export function grantIsRequest(grant, request, did) {
|
package/dist/install.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"install.js","sourceRoot":"","sources":["../src/install.ts"],"names":[],"mappings":"AAAA;;;;;;;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,CAAC,CAClC,CAAC;AACJ,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,eAAe,CAAC,IAAiB;IAC/C,OAAO,IAAI,CAAC,SAAS,CAAC;QACpB,IAAI,CAAC,QAAQ,EAAE,EAAE,IAAI,IAAI;QACzB,IAAI,CAAC,QAAQ,EAAE,OAAO,IAAI,IAAI;QAC9B,IAAI,CAAC,QAAQ,EAAE,SAAS,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK;QACvC,IAAI,CAAC,WAAW;QAChB,IAAI,CAAC,WAAW;QAChB,IAAI,CAAC,aAAa;QAClB,IAAI,CAAC,eAAe;QACpB,IAAI,CAAC,eAAe;QACpB,IAAI,CAAC,WAAW;QAChB,IAAI,CAAC,MAAM;QACX,IAAI,CAAC,UAAU;KAChB,CAAC,CAAC;AACL,CAAC"}
|
package/dist/merge.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"merge.d.ts","sourceRoot":"","sources":["../src/merge.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,wBAAgB,eAAe,CAC7B,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAChC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,GAAG,IAAI,CAAC,GACpC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,
|
|
1
|
+
{"version":3,"file":"merge.d.ts","sourceRoot":"","sources":["../src/merge.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,wBAAgB,eAAe,CAC7B,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAChC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,GAAG,IAAI,CAAC,GACpC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAoBzB"}
|
package/dist/merge.js
CHANGED
|
@@ -14,17 +14,11 @@ export function applyMergePatch(content, patch) {
|
|
|
14
14
|
delete merged[key];
|
|
15
15
|
}
|
|
16
16
|
else {
|
|
17
|
-
// defineProperty, not
|
|
18
|
-
//
|
|
19
|
-
//
|
|
20
|
-
//
|
|
21
|
-
//
|
|
22
|
-
// the same key is read back, so both write paths agree. The spread
|
|
23
|
-
// above is already safe (it copies data properties directly).
|
|
24
|
-
//
|
|
25
|
-
// Stack.create()/Stack.mutate() reject the reserved keys outright (see
|
|
26
|
-
// validateReservedKeys); this is the backstop for adapters that call
|
|
27
|
-
// this directly, and for the day someone deepens the merge.
|
|
17
|
+
// defineProperty, not assignment: [[Set]] on `__proto__` would
|
|
18
|
+
// reassign the prototype and lose the write, while an own data
|
|
19
|
+
// property is what JSON.parse makes of the same key, so both write
|
|
20
|
+
// paths agree. A backstop for adapters calling this directly; Stack
|
|
21
|
+
// refuses the reserved keys outright (validateReservedKeys).
|
|
28
22
|
Object.defineProperty(merged, key, {
|
|
29
23
|
value,
|
|
30
24
|
writable: true,
|
package/dist/merge.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"merge.js","sourceRoot":"","sources":["../src/merge.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,MAAM,UAAU,eAAe,CAC7B,OAAgC,EAChC,KAAqC;IAErC,MAAM,MAAM,GAA4B,EAAE,GAAG,OAAO,EAAE,CAAC;IACvD,KAAK,MAAM,CAAC,GAAG,EAAE,KAAK,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,EAAE,CAAC;QACjD,IAAI,KAAK,KAAK,IAAI,EAAE,CAAC;YACnB,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC;QACrB,CAAC;aAAM,CAAC;YACN
|
|
1
|
+
{"version":3,"file":"merge.js","sourceRoot":"","sources":["../src/merge.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,MAAM,UAAU,eAAe,CAC7B,OAAgC,EAChC,KAAqC;IAErC,MAAM,MAAM,GAA4B,EAAE,GAAG,OAAO,EAAE,CAAC;IACvD,KAAK,MAAM,CAAC,GAAG,EAAE,KAAK,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,EAAE,CAAC;QACjD,IAAI,KAAK,KAAK,IAAI,EAAE,CAAC;YACnB,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC;QACrB,CAAC;aAAM,CAAC;YACN,+DAA+D;YAC/D,+DAA+D;YAC/D,mEAAmE;YACnE,oEAAoE;YACpE,6DAA6D;YAC7D,MAAM,CAAC,cAAc,CAAC,MAAM,EAAE,GAAG,EAAE;gBACjC,KAAK;gBACL,QAAQ,EAAE,IAAI;gBACd,UAAU,EAAE,IAAI;gBAChB,YAAY,EAAE,IAAI;aACnB,CAAC,CAAC;QACL,CAAC;IACH,CAAC;IACD,OAAO,MAAM,CAAC;AAChB,CAAC"}
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Migration steps
|
|
3
|
+
* -------------------------------------------------------
|
|
4
|
+
* A migration is a list of declared steps — rename, map, add, drop and
|
|
5
|
+
* derive — rather than a function, so that core can read what became of
|
|
6
|
+
* each field. Two things are built from one list: the in-memory `migrate`
|
|
7
|
+
* that `Stack.open()`, a collection's reads and `migrateAll()` run, and the
|
|
8
|
+
* field origins a collection translates a content filter or sort through.
|
|
9
|
+
*
|
|
10
|
+
* `fieldOrigins()` also checks the list against both schemas, so a step
|
|
11
|
+
* the target Type would refuse fails when `migration()` runs rather than
|
|
12
|
+
* on the first record `migrateAll()` writes. See docs/spec/data-model.md
|
|
13
|
+
* § Migration steps.
|
|
14
|
+
*/
|
|
15
|
+
import type { ReadonlyTypeSchema } from './type-handle.js';
|
|
16
|
+
export type RenameStep = {
|
|
17
|
+
readonly op: 'rename';
|
|
18
|
+
readonly from: string;
|
|
19
|
+
readonly to: string;
|
|
20
|
+
};
|
|
21
|
+
export type MapStep = {
|
|
22
|
+
readonly op: 'map';
|
|
23
|
+
readonly field: string;
|
|
24
|
+
readonly values: Readonly<Record<string, string>>;
|
|
25
|
+
};
|
|
26
|
+
export type AddStep = {
|
|
27
|
+
readonly op: 'add';
|
|
28
|
+
readonly field: string;
|
|
29
|
+
readonly value: unknown;
|
|
30
|
+
};
|
|
31
|
+
export type DropStep = {
|
|
32
|
+
readonly op: 'drop';
|
|
33
|
+
readonly field: string;
|
|
34
|
+
};
|
|
35
|
+
/**
|
|
36
|
+
* `derive` is a method so a step typed on one handle's content fits a list
|
|
37
|
+
* of untyped ones, as `Migration.migrate` does.
|
|
38
|
+
*/
|
|
39
|
+
export type DeriveStep<F = Record<string, unknown>> = {
|
|
40
|
+
readonly op: 'derive';
|
|
41
|
+
readonly field: string;
|
|
42
|
+
derive(content: F): unknown;
|
|
43
|
+
};
|
|
44
|
+
/** One step of a migration, typed on the content stored at its `from`. */
|
|
45
|
+
export type MigrationStep<F = Record<string, unknown>> = RenameStep | MapStep | AddStep | DropStep | DeriveStep<F>;
|
|
46
|
+
/** Move a field's value to a new name. */
|
|
47
|
+
export declare const rename: (from: string, to: string) => RenameStep;
|
|
48
|
+
/**
|
|
49
|
+
* Replace each value `values` lists with its mapping, keeping any other,
|
|
50
|
+
* element-wise through an array. A stored enum may hold a value no handle
|
|
51
|
+
* lists, and it is carried through rather than lost.
|
|
52
|
+
*/
|
|
53
|
+
export declare const map: (field: string, values: Readonly<Record<string, string>>) => MapStep;
|
|
54
|
+
/** Set a field to a constant. */
|
|
55
|
+
export declare const add: (field: string, value: unknown) => AddStep;
|
|
56
|
+
/** Remove a field. */
|
|
57
|
+
export declare const drop: (field: string) => DropStep;
|
|
58
|
+
/**
|
|
59
|
+
* Set a field to what `fn` computes from the record as stored at the
|
|
60
|
+
* migration's `from`; `undefined` leaves it absent. The one opaque step: a
|
|
61
|
+
* field it produces does not translate across versions.
|
|
62
|
+
*/
|
|
63
|
+
export declare const derive: <F>(field: string, fn: (content: F) => unknown) => DeriveStep<F>;
|
|
64
|
+
/** The content `steps` produce from `content`, which is left untouched. */
|
|
65
|
+
export declare const applySteps: (steps: readonly MigrationStep[], content: Record<string, unknown>) => Record<string, unknown>;
|
|
66
|
+
/**
|
|
67
|
+
* What one of the target's top-level fields is, in terms of the source's:
|
|
68
|
+
* a source field, its string values possibly remapped; a constant, where
|
|
69
|
+
* `undefined` is no value; or derived, which nothing can see through.
|
|
70
|
+
*/
|
|
71
|
+
export type FieldOrigin = {
|
|
72
|
+
readonly kind: 'field';
|
|
73
|
+
readonly field: string;
|
|
74
|
+
readonly values?: Readonly<Record<string, string>>;
|
|
75
|
+
} | {
|
|
76
|
+
readonly kind: 'constant';
|
|
77
|
+
readonly value: unknown;
|
|
78
|
+
} | {
|
|
79
|
+
readonly kind: 'derived';
|
|
80
|
+
};
|
|
81
|
+
/**
|
|
82
|
+
* Every top-level field the target declares, by its origin, and every name
|
|
83
|
+
* the steps removed, as no value.
|
|
84
|
+
*/
|
|
85
|
+
export type FieldOrigins = ReadonlyMap<string, FieldOrigin>;
|
|
86
|
+
/**
|
|
87
|
+
* The origins across two migrations end to end: `lower` takes A to B and
|
|
88
|
+
* `upper` takes B to C, so the result says what each of C's fields is in
|
|
89
|
+
* terms of A's.
|
|
90
|
+
*/
|
|
91
|
+
export declare const composeOrigins: (lower: FieldOrigins, upper: FieldOrigins) => FieldOrigins;
|
|
92
|
+
/**
|
|
93
|
+
* What each of `to`'s top-level fields is in terms of `from`'s, after
|
|
94
|
+
* `steps`. Returns the problem that makes the list unusable as a string
|
|
95
|
+
* instead: a step naming a field that is not there, a field `to` would
|
|
96
|
+
* refuse, or one it requires that nothing produces. See
|
|
97
|
+
* docs/spec/data-model.md § Migration steps.
|
|
98
|
+
*/
|
|
99
|
+
export declare const fieldOrigins: (steps: readonly MigrationStep<never>[], from: ReadonlyTypeSchema, to: ReadonlyTypeSchema) => FieldOrigins | string;
|
|
100
|
+
export declare const recordOrigins: (migration: object, origins: FieldOrigins) => void;
|
|
101
|
+
export declare const originsOf: (migration: object) => FieldOrigins | undefined;
|
|
102
|
+
//# sourceMappingURL=migration-steps.d.ts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