@dialecte/core 0.7.0 → 0.8.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/hub.worker-B1HcVDhn.js +2 -0
- package/dist/diagnostics/diagnostics.d.ts +4 -0
- package/dist/diagnostics/diagnostics.d.ts.map +1 -1
- package/dist/diagnostics/types.d.ts +6 -1
- package/dist/diagnostics/types.d.ts.map +1 -1
- package/dist/dialecte/create-dialecte-project.d.ts +11 -0
- package/dist/dialecte/create-dialecte-project.d.ts.map +1 -0
- package/dist/dialecte/create-project-factory.d.ts +14 -0
- package/dist/dialecte/create-project-factory.d.ts.map +1 -0
- package/dist/dialecte/define-dialecte.d.ts +12 -0
- package/dist/dialecte/define-dialecte.d.ts.map +1 -0
- package/dist/dialecte/dialecte.constants.d.ts +4 -0
- package/dist/dialecte/dialecte.constants.d.ts.map +1 -0
- package/dist/dialecte/dialecte.types.d.ts +75 -0
- package/dist/dialecte/dialecte.types.d.ts.map +1 -0
- package/dist/dialecte/index.d.ts +4 -0
- package/dist/dialecte/index.d.ts.map +1 -0
- package/dist/{project-DIKdMMHx.js → dialecte-gIPrRzni.js} +8031 -8457
- package/dist/document/bind-extensions.d.ts +4 -1
- package/dist/document/bind-extensions.d.ts.map +1 -1
- package/dist/document/document.d.ts +58 -5
- package/dist/document/document.d.ts.map +1 -1
- package/dist/document/progress/progress.types.d.ts +21 -4
- package/dist/document/progress/progress.types.d.ts.map +1 -1
- package/dist/document/query/find/ancestor/find-ancestor.d.ts +2 -0
- package/dist/document/query/find/ancestor/find-ancestor.d.ts.map +1 -1
- package/dist/document/query/find/by-attribute/find-by-attributes.d.ts +4 -0
- package/dist/document/query/find/by-attribute/find-by-attributes.d.ts.map +1 -1
- package/dist/document/query/find/descendant/find-descendant.d.ts +2 -0
- package/dist/document/query/find/descendant/find-descendant.d.ts.map +1 -1
- package/dist/document/query/get/attribute/get-attribute.d.ts +4 -0
- package/dist/document/query/get/attribute/get-attribute.d.ts.map +1 -1
- package/dist/document/query/get/attribute/get-attributes.d.ts +4 -0
- package/dist/document/query/get/attribute/get-attributes.d.ts.map +1 -1
- package/dist/document/query/get/definition/get-definition.d.ts +2 -0
- package/dist/document/query/get/definition/get-definition.d.ts.map +1 -1
- package/dist/document/query/get/record/get-child.d.ts +2 -0
- package/dist/document/query/get/record/get-child.d.ts.map +1 -1
- package/dist/document/query/get/record/get-children.d.ts +2 -0
- package/dist/document/query/get/record/get-children.d.ts.map +1 -1
- package/dist/document/query/get/record/get-record.d.ts +2 -0
- package/dist/document/query/get/record/get-record.d.ts.map +1 -1
- package/dist/document/query/get/record/get-records-by-tagname.d.ts +2 -0
- package/dist/document/query/get/record/get-records-by-tagname.d.ts.map +1 -1
- package/dist/document/query/get/record/get-records.d.ts +2 -0
- package/dist/document/query/get/record/get-records.d.ts.map +1 -1
- package/dist/document/query/get/record/load-live-records.d.ts +2 -0
- package/dist/document/query/get/record/load-live-records.d.ts.map +1 -1
- package/dist/document/query/get/record/resolve-record.d.ts +2 -0
- package/dist/document/query/get/record/resolve-record.d.ts.map +1 -1
- package/dist/document/query/get/record/staged-lookup.d.ts +4 -0
- package/dist/document/query/get/record/staged-lookup.d.ts.map +1 -1
- package/dist/document/query/get/tree/get-tree.d.ts +6 -0
- package/dist/document/query/get/tree/get-tree.d.ts.map +1 -1
- package/dist/document/query/main.d.ts +50 -15
- package/dist/document/query/main.d.ts.map +1 -1
- package/dist/document/query/snapshot/collect-snapshot.d.ts +2 -0
- package/dist/document/query/snapshot/collect-snapshot.d.ts.map +1 -1
- package/dist/document/query/snapshot/get-snapshot.d.ts +2 -0
- package/dist/document/query/snapshot/get-snapshot.d.ts.map +1 -1
- package/dist/document/query/snapshot/records-to-tree.d.ts +2 -0
- package/dist/document/query/snapshot/records-to-tree.d.ts.map +1 -1
- package/dist/document/query/tree-filter/omit.d.ts +8 -0
- package/dist/document/query/tree-filter/omit.d.ts.map +1 -1
- package/dist/document/query/tree-filter/order.d.ts +5 -2
- package/dist/document/query/tree-filter/order.d.ts.map +1 -1
- package/dist/document/query/tree-filter/unwrap.d.ts +2 -0
- package/dist/document/query/tree-filter/unwrap.d.ts.map +1 -1
- package/dist/document/staged-operations.d.ts +5 -1
- package/dist/document/staged-operations.d.ts.map +1 -1
- package/dist/document/transaction/clone/clone.d.ts +2 -0
- package/dist/document/transaction/clone/clone.d.ts.map +1 -1
- package/dist/document/transaction/commit/commit.d.ts.map +1 -1
- package/dist/document/transaction/commit/merge-operations.d.ts +1 -1
- package/dist/document/transaction/commit/merge-operations.d.ts.map +1 -1
- package/dist/document/transaction/commit/summarize-operations.d.ts +16 -0
- package/dist/document/transaction/commit/summarize-operations.d.ts.map +1 -0
- package/dist/document/transaction/commit/summarize-operations.types.d.ts +17 -0
- package/dist/document/transaction/commit/summarize-operations.types.d.ts.map +1 -0
- package/dist/document/transaction/create/create.d.ts +2 -0
- package/dist/document/transaction/create/create.d.ts.map +1 -1
- package/dist/document/transaction/guard.d.ts +5 -0
- package/dist/document/transaction/guard.d.ts.map +1 -1
- package/dist/document/transaction/index.d.ts +2 -0
- package/dist/document/transaction/index.d.ts.map +1 -1
- package/dist/document/transaction/main.d.ts +46 -16
- package/dist/document/transaction/main.d.ts.map +1 -1
- package/dist/document/transaction/stage-operations.d.ts.map +1 -1
- package/dist/document/transaction/update/update.d.ts +2 -0
- package/dist/document/transaction/update/update.d.ts.map +1 -1
- package/dist/document/types.d.ts +3 -5
- package/dist/document/types.d.ts.map +1 -1
- package/dist/document/types.extensions.d.ts.map +1 -1
- package/dist/engine-store-CIEqgPUb.js +348 -0
- package/dist/engine.constants-DBMjMmV9.js +98 -0
- package/dist/engine.d.ts +9 -0
- package/dist/engine.d.ts.map +1 -0
- package/dist/engine.js +15805 -0
- package/dist/errors/codes.d.ts +451 -0
- package/dist/errors/codes.d.ts.map +1 -1
- package/dist/errors/errors.constants.d.ts +3 -0
- package/dist/errors/errors.constants.d.ts.map +1 -0
- package/dist/errors/errors.d.ts +10 -0
- package/dist/errors/errors.d.ts.map +1 -1
- package/dist/errors/types.d.ts +14 -0
- package/dist/errors/types.d.ts.map +1 -1
- package/dist/helpers/assert-fixed.d.ts +3 -1
- package/dist/helpers/assert-fixed.d.ts.map +1 -1
- package/dist/helpers/assert-xml-characters.d.ts +35 -0
- package/dist/helpers/assert-xml-characters.d.ts.map +1 -0
- package/dist/helpers/assert-xml-characters.types.d.ts +26 -0
- package/dist/helpers/assert-xml-characters.types.d.ts.map +1 -0
- package/dist/helpers/assert-xsi-type.d.ts +4 -0
- package/dist/helpers/assert-xsi-type.d.ts.map +1 -1
- package/dist/helpers/converter.d.ts +21 -6
- package/dist/helpers/converter.d.ts.map +1 -1
- package/dist/helpers/evaluate-expectations.d.ts +21 -0
- package/dist/helpers/evaluate-expectations.d.ts.map +1 -0
- package/dist/helpers/evaluate-expectations.types.d.ts +31 -0
- package/dist/helpers/evaluate-expectations.types.d.ts.map +1 -0
- package/dist/helpers/guard.d.ts +24 -4
- package/dist/helpers/guard.d.ts.map +1 -1
- package/dist/helpers/index.d.ts +2 -0
- package/dist/helpers/index.d.ts.map +1 -1
- package/dist/helpers/merge-extensions.d.ts +2 -0
- package/dist/helpers/merge-extensions.d.ts.map +1 -1
- package/dist/helpers/read-attributes.d.ts +4 -0
- package/dist/helpers/read-attributes.d.ts.map +1 -1
- package/dist/helpers/standardizing.d.ts +10 -0
- package/dist/helpers/standardizing.d.ts.map +1 -1
- package/dist/helpers/strip-attributes.d.ts +2 -0
- package/dist/helpers/strip-attributes.d.ts.map +1 -1
- package/dist/helpers-DVShv41E.js +489 -0
- package/dist/helpers.js +3 -439
- package/dist/in-process-link-DBeAOZRp.js +2791 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +13 -12
- package/dist/perf/create-perf.d.ts +8 -1
- package/dist/perf/create-perf.d.ts.map +1 -1
- package/dist/perf/index.d.ts +1 -1
- package/dist/perf/index.d.ts.map +1 -1
- package/dist/perf/noop-perf.d.ts.map +1 -1
- package/dist/perf/perf.types.d.ts +65 -6
- package/dist/perf/perf.types.d.ts.map +1 -1
- package/dist/project/index.d.ts +7 -5
- package/dist/project/index.d.ts.map +1 -1
- package/dist/project/io/export-blob.d.ts +5 -2
- package/dist/project/io/export-blob.d.ts.map +1 -1
- package/dist/project/io/export-document.d.ts +5 -4
- package/dist/project/io/export-document.d.ts.map +1 -1
- package/dist/project/io/index.d.ts +1 -1
- package/dist/project/io/index.d.ts.map +1 -1
- package/dist/project/io/init-empty-document.d.ts +2 -0
- package/dist/project/io/init-empty-document.d.ts.map +1 -1
- package/dist/project/io/run-export.d.ts +19 -0
- package/dist/project/io/run-export.d.ts.map +1 -0
- package/dist/project/io/run-export.types.d.ts +45 -0
- package/dist/project/io/run-export.types.d.ts.map +1 -0
- package/dist/project/io/run-import.d.ts +15 -0
- package/dist/project/io/run-import.d.ts.map +1 -0
- package/dist/project/io/run-import.types.d.ts +19 -0
- package/dist/project/io/run-import.types.d.ts.map +1 -0
- package/dist/project/io/store-runtime.constants.d.ts +6 -0
- package/dist/project/io/store-runtime.constants.d.ts.map +1 -0
- package/dist/project/io/store-runtime.d.ts +12 -0
- package/dist/project/io/store-runtime.d.ts.map +1 -0
- package/dist/project/io/store-runtime.types.d.ts +18 -0
- package/dist/project/io/store-runtime.types.d.ts.map +1 -0
- package/dist/project/project-channel.d.ts +11 -0
- package/dist/project/project-channel.d.ts.map +1 -0
- package/dist/project/project.constants.d.ts +12 -0
- package/dist/project/project.constants.d.ts.map +1 -0
- package/dist/project/project.d.ts +315 -31
- package/dist/project/project.d.ts.map +1 -1
- package/dist/project/state/document-lifecycle.d.ts +0 -12
- package/dist/project/state/document-lifecycle.d.ts.map +1 -1
- package/dist/project/state/document-state.d.ts +4 -0
- package/dist/project/state/document-state.d.ts.map +1 -1
- package/dist/project/types.d.ts +126 -60
- package/dist/project/types.d.ts.map +1 -1
- package/dist/project-key-Ch34EtFa.js +1435 -0
- package/dist/rolldown-runtime-CYdcPHCu.js +12 -0
- package/dist/running-operations-vnijBvn7.js +76 -0
- package/dist/same-json-value-C6kUaoyt.js +1603 -0
- package/dist/sqlite.d.ts +5 -0
- package/dist/sqlite.d.ts.map +1 -0
- package/dist/sqlite.js +2671 -0
- package/dist/sqlite3.wasm +0 -0
- package/dist/store/apply-record-patch.d.ts +13 -0
- package/dist/store/apply-record-patch.d.ts.map +1 -0
- package/dist/store/closing-connections.d.ts +7 -0
- package/dist/store/closing-connections.d.ts.map +1 -0
- package/dist/store/closing-connections.types.d.ts +13 -0
- package/dist/store/closing-connections.types.d.ts.map +1 -0
- package/dist/store/commit-progress.d.ts +10 -0
- package/dist/store/commit-progress.d.ts.map +1 -0
- package/dist/store/compare-by-id.d.ts +10 -0
- package/dist/store/compare-by-id.d.ts.map +1 -0
- package/dist/store/document-path.constants.d.ts +20 -0
- package/dist/store/document-path.constants.d.ts.map +1 -0
- package/dist/store/document-path.d.ts +75 -0
- package/dist/store/document-path.d.ts.map +1 -0
- package/dist/store/document-path.types.d.ts +11 -0
- package/dist/store/document-path.types.d.ts.map +1 -0
- package/dist/store/engine/client/check-engine-wire.d.ts +8 -0
- package/dist/store/engine/client/check-engine-wire.d.ts.map +1 -0
- package/dist/store/engine/client/client.constants.d.ts +30 -0
- package/dist/store/engine/client/client.constants.d.ts.map +1 -0
- package/dist/store/engine/client/client.types.d.ts +200 -0
- package/dist/store/engine/client/client.types.d.ts.map +1 -0
- package/dist/store/engine/client/engine-client.d.ts +15 -0
- package/dist/store/engine/client/engine-client.d.ts.map +1 -0
- package/dist/store/engine/client/engine-control.d.ts +16 -0
- package/dist/store/engine/client/engine-control.d.ts.map +1 -0
- package/dist/store/engine/client/heartbeat-watch.d.ts +17 -0
- package/dist/store/engine/client/heartbeat-watch.d.ts.map +1 -0
- package/dist/store/engine/client/hub-connector.d.ts +11 -0
- package/dist/store/engine/client/hub-connector.d.ts.map +1 -0
- package/dist/store/engine/client/hub-connector.types.d.ts +25 -0
- package/dist/store/engine/client/hub-connector.types.d.ts.map +1 -0
- package/dist/store/engine/client/worker-connector.d.ts +32 -0
- package/dist/store/engine/client/worker-connector.d.ts.map +1 -0
- package/dist/store/engine/creation-refusal.d.ts +10 -0
- package/dist/store/engine/creation-refusal.d.ts.map +1 -0
- package/dist/store/engine/dialecte-refusal.d.ts +18 -0
- package/dist/store/engine/dialecte-refusal.d.ts.map +1 -0
- package/dist/store/engine/engine-store.d.ts +163 -0
- package/dist/store/engine/engine-store.d.ts.map +1 -0
- package/dist/store/engine/engine-store.types.d.ts +53 -0
- package/dist/store/engine/engine-store.types.d.ts.map +1 -0
- package/dist/store/engine/engine.constants.d.ts +14 -0
- package/dist/store/engine/engine.constants.d.ts.map +1 -0
- package/dist/store/engine/engine.types.d.ts +165 -0
- package/dist/store/engine/engine.types.d.ts.map +1 -0
- package/dist/store/engine/host/engine-wire.d.ts +19 -0
- package/dist/store/engine/host/engine-wire.d.ts.map +1 -0
- package/dist/store/engine/host/heartbeat.d.ts +33 -0
- package/dist/store/engine/host/heartbeat.d.ts.map +1 -0
- package/dist/store/engine/host/host.constants.d.ts +13 -0
- package/dist/store/engine/host/host.constants.d.ts.map +1 -0
- package/dist/store/engine/host/host.types.d.ts +65 -0
- package/dist/store/engine/host/host.types.d.ts.map +1 -0
- package/dist/store/engine/host/store-events.d.ts +14 -0
- package/dist/store/engine/host/store-events.d.ts.map +1 -0
- package/dist/store/engine/hub/hub-client.constants.d.ts +27 -0
- package/dist/store/engine/hub/hub-client.constants.d.ts.map +1 -0
- package/dist/store/engine/hub/hub-client.d.ts +46 -0
- package/dist/store/engine/hub/hub-client.d.ts.map +1 -0
- package/dist/store/engine/hub/hub-client.types.d.ts +208 -0
- package/dist/store/engine/hub/hub-client.types.d.ts.map +1 -0
- package/dist/store/engine/hub/hub-protocol.types.d.ts +193 -0
- package/dist/store/engine/hub/hub-protocol.types.d.ts.map +1 -0
- package/dist/store/engine/hub/hub-router.d.ts +9 -0
- package/dist/store/engine/hub/hub-router.d.ts.map +1 -0
- package/dist/store/engine/hub/hub-shell.d.ts +13 -0
- package/dist/store/engine/hub/hub-shell.d.ts.map +1 -0
- package/dist/store/engine/hub/hub-shell.types.d.ts +64 -0
- package/dist/store/engine/hub/hub-shell.types.d.ts.map +1 -0
- package/dist/store/engine/hub/hub.constants.d.ts +33 -0
- package/dist/store/engine/hub/hub.constants.d.ts.map +1 -0
- package/dist/store/engine/hub/hub.types.d.ts +305 -0
- package/dist/store/engine/hub/hub.types.d.ts.map +1 -0
- package/dist/store/engine/hub/hub.worker.d.ts +2 -0
- package/dist/store/engine/hub/hub.worker.d.ts.map +1 -0
- package/dist/store/engine/hub/realm-host.d.ts +10 -0
- package/dist/store/engine/hub/realm-host.d.ts.map +1 -0
- package/dist/store/engine/hub/realm-host.types.d.ts +78 -0
- package/dist/store/engine/hub/realm-host.types.d.ts.map +1 -0
- package/dist/store/engine/project-key.d.ts +15 -0
- package/dist/store/engine/project-key.d.ts.map +1 -0
- package/dist/store/engine/wire/error-envelope.d.ts +25 -0
- package/dist/store/engine/wire/error-envelope.d.ts.map +1 -0
- package/dist/store/engine/wire/wire-values.d.ts +33 -0
- package/dist/store/engine/wire/wire-values.d.ts.map +1 -0
- package/dist/store/engine/wire/wire.constants.d.ts +116 -0
- package/dist/store/engine/wire/wire.constants.d.ts.map +1 -0
- package/dist/store/engine/wire/wire.types.d.ts +119 -0
- package/dist/store/engine/wire/wire.types.d.ts.map +1 -0
- package/dist/store/hub-public.d.ts +33 -0
- package/dist/store/hub-public.d.ts.map +1 -0
- package/dist/store/ignore-destroy-outcome.d.ts +6 -0
- package/dist/store/ignore-destroy-outcome.d.ts.map +1 -0
- package/dist/store/in-memory/in-memory-state.d.ts +46 -0
- package/dist/store/in-memory/in-memory-state.d.ts.map +1 -0
- package/dist/store/in-memory/in-memory-store.constants.d.ts +7 -0
- package/dist/store/in-memory/in-memory-store.constants.d.ts.map +1 -0
- package/dist/store/in-memory/in-memory-store.d.ts +105 -17
- package/dist/store/in-memory/in-memory-store.d.ts.map +1 -1
- package/dist/store/in-memory/types.d.ts +55 -1
- package/dist/store/in-memory/types.d.ts.map +1 -1
- package/dist/store/index.d.ts +8 -2
- package/dist/store/index.d.ts.map +1 -1
- package/dist/store/json-values.constants.d.ts +18 -0
- package/dist/store/json-values.constants.d.ts.map +1 -0
- package/dist/store/json-values.d.ts +40 -0
- package/dist/store/json-values.d.ts.map +1 -0
- package/dist/store/json-values.types.d.ts +18 -0
- package/dist/store/json-values.types.d.ts.map +1 -0
- package/dist/store/local/dexie-store.constants.d.ts +20 -0
- package/dist/store/local/dexie-store.constants.d.ts.map +1 -0
- package/dist/store/local/dexie-store.d.ts +134 -5
- package/dist/store/local/dexie-store.d.ts.map +1 -1
- package/dist/store/local/types.d.ts +6 -0
- package/dist/store/local/types.d.ts.map +1 -1
- package/dist/store/lost-write.d.ts +32 -0
- package/dist/store/lost-write.d.ts.map +1 -0
- package/dist/store/lost-write.types.d.ts +4 -0
- package/dist/store/lost-write.types.d.ts.map +1 -0
- package/dist/store/open-connections.d.ts +4 -0
- package/dist/store/open-connections.d.ts.map +1 -0
- package/dist/store/open-connections.types.d.ts +17 -0
- package/dist/store/open-connections.types.d.ts.map +1 -0
- package/dist/store/own-import.d.ts +10 -0
- package/dist/store/own-import.d.ts.map +1 -0
- package/dist/store/project-name.d.ts +10 -0
- package/dist/store/project-name.d.ts.map +1 -0
- package/dist/store/resolve-store.d.ts +28 -4
- package/dist/store/resolve-store.d.ts.map +1 -1
- package/dist/store/running-operations.d.ts +7 -0
- package/dist/store/running-operations.d.ts.map +1 -0
- package/dist/store/running-operations.types.d.ts +10 -0
- package/dist/store/running-operations.types.d.ts.map +1 -0
- package/dist/store/same-json-value.d.ts +9 -0
- package/dist/store/same-json-value.d.ts.map +1 -0
- package/dist/store/sqlite/adapter/in-process-link.d.ts +20 -0
- package/dist/store/sqlite/adapter/in-process-link.d.ts.map +1 -0
- package/dist/store/sqlite/adapter/in-process-link.types.d.ts +21 -0
- package/dist/store/sqlite/adapter/in-process-link.types.d.ts.map +1 -0
- package/dist/store/sqlite/adapter/realm-storage.d.ts +10 -0
- package/dist/store/sqlite/adapter/realm-storage.d.ts.map +1 -0
- package/dist/store/sqlite/adapter/sqlite-connector.d.ts +14 -0
- package/dist/store/sqlite/adapter/sqlite-connector.d.ts.map +1 -0
- package/dist/store/sqlite/adapter/sqlite-engine-settings.d.ts +4 -0
- package/dist/store/sqlite/adapter/sqlite-engine-settings.d.ts.map +1 -0
- package/dist/store/sqlite/adapter/sqlite-hub-spawner.d.ts +8 -0
- package/dist/store/sqlite/adapter/sqlite-hub-spawner.d.ts.map +1 -0
- package/dist/store/sqlite/adapter/sqlite-hub-spawner.types.d.ts +5 -0
- package/dist/store/sqlite/adapter/sqlite-hub-spawner.types.d.ts.map +1 -0
- package/dist/store/sqlite/adapter/sqlite-worker-connector.d.ts +8 -0
- package/dist/store/sqlite/adapter/sqlite-worker-connector.d.ts.map +1 -0
- package/dist/store/sqlite/adapter/sqlite-worker-connector.types.d.ts +5 -0
- package/dist/store/sqlite/adapter/sqlite-worker-connector.types.d.ts.map +1 -0
- package/dist/store/sqlite/engine/blobs.d.ts +55 -0
- package/dist/store/sqlite/engine/blobs.d.ts.map +1 -0
- package/dist/store/sqlite/engine/bulk-insert.d.ts +31 -0
- package/dist/store/sqlite/engine/bulk-insert.d.ts.map +1 -0
- package/dist/store/sqlite/engine/commit.d.ts +20 -0
- package/dist/store/sqlite/engine/commit.d.ts.map +1 -0
- package/dist/store/sqlite/engine/device-cache.d.ts +13 -0
- package/dist/store/sqlite/engine/device-cache.d.ts.map +1 -0
- package/dist/store/sqlite/engine/engine-errors.d.ts +26 -0
- package/dist/store/sqlite/engine/engine-errors.d.ts.map +1 -0
- package/dist/store/sqlite/engine/engine.constants.d.ts +144 -0
- package/dist/store/sqlite/engine/engine.constants.d.ts.map +1 -0
- package/dist/store/sqlite/engine/engine.types.d.ts +361 -0
- package/dist/store/sqlite/engine/engine.types.d.ts.map +1 -0
- package/dist/store/sqlite/engine/history.d.ts +114 -0
- package/dist/store/sqlite/engine/history.d.ts.map +1 -0
- package/dist/store/sqlite/engine/import-queue.d.ts +7 -0
- package/dist/store/sqlite/engine/import-queue.d.ts.map +1 -0
- package/dist/store/sqlite/engine/import-target.d.ts +23 -0
- package/dist/store/sqlite/engine/import-target.d.ts.map +1 -0
- package/dist/store/sqlite/engine/import-window.d.ts +23 -0
- package/dist/store/sqlite/engine/import-window.d.ts.map +1 -0
- package/dist/store/sqlite/engine/reclaim.d.ts +13 -0
- package/dist/store/sqlite/engine/reclaim.d.ts.map +1 -0
- package/dist/store/sqlite/engine/records.d.ts +117 -0
- package/dist/store/sqlite/engine/records.d.ts.map +1 -0
- package/dist/store/sqlite/engine/registry.d.ts +76 -0
- package/dist/store/sqlite/engine/registry.d.ts.map +1 -0
- package/dist/store/sqlite/engine/schema.d.ts +57 -0
- package/dist/store/sqlite/engine/schema.d.ts.map +1 -0
- package/dist/store/sqlite/engine/sqlite-engine.d.ts +14 -0
- package/dist/store/sqlite/engine/sqlite-engine.d.ts.map +1 -0
- package/dist/store/sqlite/engine/transaction.d.ts +12 -0
- package/dist/store/sqlite/engine/transaction.d.ts.map +1 -0
- package/dist/store/sqlite/list-projects.constants.d.ts +12 -0
- package/dist/store/sqlite/list-projects.constants.d.ts.map +1 -0
- package/dist/store/sqlite/list-projects.d.ts +22 -0
- package/dist/store/sqlite/list-projects.d.ts.map +1 -0
- package/dist/store/sqlite/list-projects.types.d.ts +28 -0
- package/dist/store/sqlite/list-projects.types.d.ts.map +1 -0
- package/dist/store/sqlite/load-sqlite.d.ts +11 -0
- package/dist/store/sqlite/load-sqlite.d.ts.map +1 -0
- package/dist/store/sqlite/runtime/close-engine.d.ts +18 -0
- package/dist/store/sqlite/runtime/close-engine.d.ts.map +1 -0
- package/dist/store/sqlite/runtime/install-pool.d.ts +94 -0
- package/dist/store/sqlite/runtime/install-pool.d.ts.map +1 -0
- package/dist/store/sqlite/runtime/pool-header.d.ts +13 -0
- package/dist/store/sqlite/runtime/pool-header.d.ts.map +1 -0
- package/dist/store/sqlite/runtime/progress-beat.d.ts +13 -0
- package/dist/store/sqlite/runtime/progress-beat.d.ts.map +1 -0
- package/dist/store/sqlite/runtime/runtime.constants.d.ts +57 -0
- package/dist/store/sqlite/runtime/runtime.constants.d.ts.map +1 -0
- package/dist/store/sqlite/runtime/runtime.types.d.ts +56 -0
- package/dist/store/sqlite/runtime/runtime.types.d.ts.map +1 -0
- package/dist/store/sqlite/runtime/serve-dialecte-engine.d.ts +16 -0
- package/dist/store/sqlite/runtime/serve-dialecte-engine.d.ts.map +1 -0
- package/dist/store/sqlite/sqlite-store-of.d.ts +7 -0
- package/dist/store/sqlite/sqlite-store-of.d.ts.map +1 -0
- package/dist/store/sqlite/sqlite-text.d.ts +20 -0
- package/dist/store/sqlite/sqlite-text.d.ts.map +1 -0
- package/dist/store/sqlite/sqlite-wasm-url.d.ts +9 -0
- package/dist/store/sqlite/sqlite-wasm-url.d.ts.map +1 -0
- package/dist/store/sqlite/sqlite.constants.d.ts +15 -0
- package/dist/store/sqlite/sqlite.constants.d.ts.map +1 -0
- package/dist/store/sqlite/sqlite.types.d.ts +36 -0
- package/dist/store/sqlite/sqlite.types.d.ts.map +1 -0
- package/dist/store/sqlite-storage.constants.d.ts +14 -0
- package/dist/store/sqlite-storage.constants.d.ts.map +1 -0
- package/dist/store/sqlite-storage.d.ts +22 -0
- package/dist/store/sqlite-storage.d.ts.map +1 -0
- package/dist/store/sqlite-storage.types.d.ts +24 -0
- package/dist/store/sqlite-storage.types.d.ts.map +1 -0
- package/dist/store/store-errors.d.ts +51 -0
- package/dist/store/store-errors.d.ts.map +1 -0
- package/dist/store/store.constants.d.ts +15 -3
- package/dist/store/store.constants.d.ts.map +1 -1
- package/dist/store/store.types.d.ts +280 -16
- package/dist/store/store.types.d.ts.map +1 -1
- package/dist/store/stored-record.d.ts +16 -0
- package/dist/store/stored-record.d.ts.map +1 -0
- package/dist/store/unfinished-imports.d.ts +15 -0
- package/dist/store/unfinished-imports.d.ts.map +1 -0
- package/dist/store/write-outcome.d.ts +34 -0
- package/dist/store/write-outcome.d.ts.map +1 -0
- package/dist/test/assert-valid-xml/assert-valid-xml.constants.d.ts +7 -0
- package/dist/test/assert-valid-xml/assert-valid-xml.constants.d.ts.map +1 -0
- package/dist/test/assert-valid-xml/assert-valid-xml.d.ts +19 -18
- package/dist/test/assert-valid-xml/assert-valid-xml.d.ts.map +1 -1
- package/dist/test/assert-valid-xml/assert-valid-xml.types.d.ts +8 -4
- package/dist/test/assert-valid-xml/assert-valid-xml.types.d.ts.map +1 -1
- package/dist/test/assert-xml/assert-xml.constants.d.ts +25 -0
- package/dist/test/assert-xml/assert-xml.constants.d.ts.map +1 -0
- package/dist/test/assert-xml/assert-xml.d.ts +23 -34
- package/dist/test/assert-xml/assert-xml.d.ts.map +1 -1
- package/dist/test/assert-xml/assert-xml.types.d.ts +48 -0
- package/dist/test/assert-xml/assert-xml.types.d.ts.map +1 -0
- package/dist/test/assert-xml/describe-nearby.d.ts +16 -0
- package/dist/test/assert-xml/describe-nearby.d.ts.map +1 -0
- package/dist/test/assert-xml/describe-node-place.d.ts +15 -0
- package/dist/test/assert-xml/describe-node-place.d.ts.map +1 -0
- package/dist/test/assert-xml/index.d.ts +1 -1
- package/dist/test/assert-xml/index.d.ts.map +1 -1
- package/dist/test/assert-xml/query-failure-message.d.ts +24 -0
- package/dist/test/assert-xml/query-failure-message.d.ts.map +1 -0
- package/dist/test/assert-xml/read-xpath-step.d.ts +8 -0
- package/dist/test/assert-xml/read-xpath-step.d.ts.map +1 -0
- package/dist/test/assert-xml/xpath-parser.d.ts +2 -1
- package/dist/test/assert-xml/xpath-parser.d.ts.map +1 -1
- package/dist/test/config.d.ts +5 -0
- package/dist/test/config.d.ts.map +1 -1
- package/dist/test/constant.d.ts +2 -0
- package/dist/test/constant.d.ts.map +1 -1
- package/dist/test/create-test-dialecte.d.ts +32 -37
- package/dist/test/create-test-dialecte.d.ts.map +1 -1
- package/dist/test/create-test-dialecte.types.d.ts +99 -0
- package/dist/test/create-test-dialecte.types.d.ts.map +1 -0
- package/dist/test/create-test-helpers-internal.types.d.ts +19 -0
- package/dist/test/create-test-helpers-internal.types.d.ts.map +1 -0
- package/dist/test/create-test-helpers.d.ts +13 -0
- package/dist/test/create-test-helpers.d.ts.map +1 -0
- package/dist/test/create-test-helpers.types.d.ts +50 -0
- package/dist/test/create-test-helpers.types.d.ts.map +1 -0
- package/dist/test/fixtures/test-entry-scan-constraint.d.ts +3 -0
- package/dist/test/fixtures/test-entry-scan-constraint.d.ts.map +1 -0
- package/dist/test/fixtures/test-entry-scan-edges.types.d.ts +10 -0
- package/dist/test/fixtures/test-entry-scan-edges.types.d.ts.map +1 -0
- package/dist/test/fixtures/test-entry-scan-recursive.d.ts +4 -0
- package/dist/test/fixtures/test-entry-scan-recursive.d.ts.map +1 -0
- package/dist/test/fixtures/test-entry-scan-recursive.types.d.ts +15 -0
- package/dist/test/fixtures/test-entry-scan-recursive.types.d.ts.map +1 -0
- package/dist/test/fixtures/test-entry-scan-shapes.d.ts +14 -0
- package/dist/test/fixtures/test-entry-scan-shapes.d.ts.map +1 -0
- package/dist/test/fixtures/test-entry-scan-shapes.types.d.ts +14 -0
- package/dist/test/fixtures/test-entry-scan-shapes.types.d.ts.map +1 -0
- package/dist/test/fixtures/test-entry-scan-tree.d.ts +3 -0
- package/dist/test/fixtures/test-entry-scan-tree.d.ts.map +1 -0
- package/dist/test/fixtures/test-entry-scan.d.ts +5 -0
- package/dist/test/fixtures/test-entry-scan.d.ts.map +1 -0
- package/dist/test/fixtures/test-entry-scan.types.d.ts +5 -0
- package/dist/test/fixtures/test-entry-scan.types.d.ts.map +1 -0
- package/dist/test/generated/definition.generated.d.ts +5 -0
- package/dist/test/generated/definition.generated.d.ts.map +1 -1
- package/dist/test/in-memory-storage.setup.d.ts +2 -0
- package/dist/test/in-memory-storage.setup.d.ts.map +1 -0
- package/dist/test/index.d.ts +6 -0
- package/dist/test/index.d.ts.map +1 -1
- package/dist/test/normalize-uuids.constants.d.ts +3 -0
- package/dist/test/normalize-uuids.constants.d.ts.map +1 -0
- package/dist/test/normalize-uuids.d.ts +12 -0
- package/dist/test/normalize-uuids.d.ts.map +1 -1
- package/dist/test/run-test-cases.d.ts +30 -11
- package/dist/test/run-test-cases.d.ts.map +1 -1
- package/dist/test/run-test-cases.type.d.ts +16 -0
- package/dist/test/run-test-cases.type.d.ts.map +1 -1
- package/dist/test/sqlite-storage.setup.d.ts +1 -0
- package/dist/test/sqlite-storage.setup.d.ts.map +1 -0
- package/dist/test/test-dialecte-setup.d.ts +31 -0
- package/dist/test/test-dialecte-setup.d.ts.map +1 -0
- package/dist/test/test-dialecte-setup.types.d.ts +29 -0
- package/dist/test/test-dialecte-setup.types.d.ts.map +1 -0
- package/dist/test/test-dialecte.d.ts +2722 -0
- package/dist/test/test-dialecte.d.ts.map +1 -0
- package/dist/test/test-dialecte.types.d.ts +3 -0
- package/dist/test/test-dialecte.types.d.ts.map +1 -0
- package/dist/test/test-dialecte.worker.d.ts +2 -0
- package/dist/test/test-dialecte.worker.d.ts.map +1 -0
- package/dist/test/test-entry-environment.constants.d.ts +27 -0
- package/dist/test/test-entry-environment.constants.d.ts.map +1 -0
- package/dist/test/test-record.d.ts +49 -1
- package/dist/test/test-record.d.ts.map +1 -1
- package/dist/test/test-storage/index.d.ts +5 -0
- package/dist/test/test-storage/index.d.ts.map +1 -0
- package/dist/test/test-storage/read-test-storage.d.ts +4 -0
- package/dist/test/test-storage/read-test-storage.d.ts.map +1 -0
- package/dist/test/test-storage/resolve-test-storage.d.ts +9 -0
- package/dist/test/test-storage/resolve-test-storage.d.ts.map +1 -0
- package/dist/test/test-storage/test-storage.constants.d.ts +9 -0
- package/dist/test/test-storage/test-storage.constants.d.ts.map +1 -0
- package/dist/test/test-storage/test-storage.types.d.ts +15 -0
- package/dist/test/test-storage/test-storage.types.d.ts.map +1 -0
- package/dist/test/test-storage/test-store-for.d.ts +19 -0
- package/dist/test/test-storage/test-store-for.d.ts.map +1 -0
- package/dist/test/test-storage/use-test-storage.d.ts +14 -0
- package/dist/test/test-storage/use-test-storage.d.ts.map +1 -0
- package/dist/test/test-timing.constants.d.ts +15 -0
- package/dist/test/test-timing.constants.d.ts.map +1 -0
- package/dist/test/xml/engine-console.d.ts +6 -0
- package/dist/test/xml/engine-console.d.ts.map +1 -0
- package/dist/test/xml/engine.d.ts +3 -0
- package/dist/test/xml/engine.d.ts.map +1 -0
- package/dist/test/xml/index.d.ts +8 -0
- package/dist/test/xml/index.d.ts.map +1 -0
- package/dist/test/xml/malformed-xml-error.d.ts +5 -0
- package/dist/test/xml/malformed-xml-error.d.ts.map +1 -0
- package/dist/test/xml/print-node.d.ts +7 -0
- package/dist/test/xml/print-node.d.ts.map +1 -0
- package/dist/test/xml/select-nodes.d.ts +14 -0
- package/dist/test/xml/select-nodes.d.ts.map +1 -0
- package/dist/test/xml/with-xml-document.constants.d.ts +7 -0
- package/dist/test/xml/with-xml-document.constants.d.ts.map +1 -0
- package/dist/test/xml/with-xml-document.d.ts +14 -0
- package/dist/test/xml/with-xml-document.d.ts.map +1 -0
- package/dist/test/xml/xml-query-refused-error.d.ts +13 -0
- package/dist/test/xml/xml-query-refused-error.d.ts.map +1 -0
- package/dist/test/xml/xml.constants.d.ts +16 -0
- package/dist/test/xml/xml.constants.d.ts.map +1 -0
- package/dist/test/xml/xml.types.d.ts +31 -0
- package/dist/test/xml/xml.types.d.ts.map +1 -0
- package/dist/test/xsd/test-ext.xsd +226 -0
- package/dist/test/xsd/test.xsd +528 -0
- package/dist/test.js +3427 -406
- package/dist/types/dialecte-config.d.ts +6 -0
- package/dist/types/dialecte-config.d.ts.map +1 -1
- package/dist/types/io.d.ts +5 -0
- package/dist/types/io.d.ts.map +1 -1
- package/dist/utils/attribute-rules.d.ts +16 -1
- package/dist/utils/attribute-rules.d.ts.map +1 -1
- package/dist/utils/child-occurrences.constants.d.ts +4 -0
- package/dist/utils/child-occurrences.constants.d.ts.map +1 -0
- package/dist/utils/child-occurrences.d.ts +17 -0
- package/dist/utils/child-occurrences.d.ts.map +1 -0
- package/dist/utils/child-occurrences.types.d.ts +6 -0
- package/dist/utils/child-occurrences.types.d.ts.map +1 -0
- package/dist/utils/datatype.d.ts +4 -0
- package/dist/utils/datatype.d.ts.map +1 -1
- package/dist/utils/format-xml.d.ts +4 -0
- package/dist/utils/format-xml.d.ts.map +1 -1
- package/dist/utils/index.d.ts +5 -1
- package/dist/utils/index.d.ts.map +1 -1
- package/dist/utils/invariant.d.ts +2 -0
- package/dist/utils/invariant.d.ts.map +1 -1
- package/dist/utils/namespaces.d.ts +15 -1
- package/dist/utils/namespaces.d.ts.map +1 -1
- package/dist/utils/order-children.d.ts +14 -3
- package/dist/utils/order-children.d.ts.map +1 -1
- package/dist/utils/order-children.types.d.ts +10 -0
- package/dist/utils/order-children.types.d.ts.map +1 -0
- package/dist/utils/particle-occurrences.d.ts +4 -0
- package/dist/utils/particle-occurrences.d.ts.map +1 -0
- package/dist/utils/required-choices.d.ts +17 -0
- package/dist/utils/required-choices.d.ts.map +1 -0
- package/dist/utils/required-choices.types.d.ts +15 -0
- package/dist/utils/required-choices.types.d.ts.map +1 -0
- package/dist/utils/resolve-definition.d.ts +4 -0
- package/dist/utils/resolve-definition.d.ts.map +1 -1
- package/dist/utils/save-to-disk.constants.d.ts +3 -0
- package/dist/utils/save-to-disk.constants.d.ts.map +1 -0
- package/dist/utils/save-to-disk.d.ts +17 -5
- package/dist/utils/save-to-disk.d.ts.map +1 -1
- package/dist/utils/save-to-disk.types.d.ts +17 -0
- package/dist/utils/save-to-disk.types.d.ts.map +1 -0
- package/dist/utils/seeded-uuid.constants.d.ts +5 -0
- package/dist/utils/seeded-uuid.constants.d.ts.map +1 -0
- package/dist/utils/seeded-uuid.d.ts +15 -0
- package/dist/utils/seeded-uuid.d.ts.map +1 -0
- package/dist/utils/seeded-uuid.types.d.ts +8 -0
- package/dist/utils/seeded-uuid.types.d.ts.map +1 -0
- package/dist/utils/tell-listener.constants.d.ts +9 -0
- package/dist/utils/tell-listener.constants.d.ts.map +1 -0
- package/dist/utils/tell-listener.d.ts +24 -0
- package/dist/utils/tell-listener.d.ts.map +1 -0
- package/dist/utils/xml-characters.constants.d.ts +9 -0
- package/dist/utils/xml-characters.constants.d.ts.map +1 -0
- package/dist/utils/xml-characters.d.ts +8 -0
- package/dist/utils/xml-characters.d.ts.map +1 -0
- package/dist/utils/xml-whitespace.constants.d.ts +8 -0
- package/dist/utils/xml-whitespace.constants.d.ts.map +1 -0
- package/dist/utils/xml-whitespace.d.ts +19 -0
- package/dist/utils/xml-whitespace.d.ts.map +1 -0
- package/dist/utils/xsi-type.d.ts +4 -0
- package/dist/utils/xsi-type.d.ts.map +1 -1
- package/dist/utils/yield-to-queue.d.ts +6 -0
- package/dist/utils/yield-to-queue.d.ts.map +1 -0
- package/dist/utils-USNkj4sT.js +1275 -0
- package/dist/utils.js +1 -2
- package/dist/xml/build/document-root.d.ts +7 -0
- package/dist/xml/build/document-root.d.ts.map +1 -0
- package/dist/xml/build/index.d.ts +0 -5
- package/dist/xml/build/index.d.ts.map +1 -1
- package/dist/xml/build/record-element.d.ts +15 -0
- package/dist/xml/build/record-element.d.ts.map +1 -0
- package/dist/xml/build/record-element.types.d.ts +12 -0
- package/dist/xml/build/record-element.types.d.ts.map +1 -0
- package/dist/xml/build/write-xml-records.d.ts +7 -0
- package/dist/xml/build/write-xml-records.d.ts.map +1 -0
- package/dist/xml/build/write-xml-records.types.d.ts +11 -0
- package/dist/xml/build/write-xml-records.types.d.ts.map +1 -0
- package/dist/xml/build/xml-element.d.ts +79 -0
- package/dist/xml/build/xml-element.d.ts.map +1 -0
- package/dist/xml/build/xml-element.types.d.ts +34 -0
- package/dist/xml/build/xml-element.types.d.ts.map +1 -0
- package/dist/xml/build/xml-writer.constants.d.ts +24 -0
- package/dist/xml/build/xml-writer.constants.d.ts.map +1 -0
- package/dist/xml/build/xml-writer.d.ts +40 -0
- package/dist/xml/build/xml-writer.d.ts.map +1 -0
- package/dist/xml/build/xml-writer.types.d.ts +34 -0
- package/dist/xml/build/xml-writer.types.d.ts.map +1 -0
- package/dist/xml/dom/index.d.ts +3 -0
- package/dist/xml/dom/index.d.ts.map +1 -0
- package/dist/xml/dom/xml-document-from-file.d.ts +10 -0
- package/dist/xml/dom/xml-document-from-file.d.ts.map +1 -0
- package/dist/xml/dom/xml-document-from-file.types.d.ts +5 -0
- package/dist/xml/dom/xml-document-from-file.types.d.ts.map +1 -0
- package/dist/xml/index.d.ts +1 -0
- package/dist/xml/index.d.ts.map +1 -1
- package/dist/xml/inspect-xml.d.ts +2 -0
- package/dist/xml/inspect-xml.d.ts.map +1 -1
- package/dist/xml/parse/index.d.ts +1 -1
- package/dist/xml/parse/index.d.ts.map +1 -1
- package/dist/xml/parse/parse-xml-document.constants.d.ts +5 -0
- package/dist/xml/parse/parse-xml-document.constants.d.ts.map +1 -0
- package/dist/xml/parse/parse-xml-document.d.ts +13 -2
- package/dist/xml/parse/parse-xml-document.d.ts.map +1 -1
- package/dist/xml/parse/parse-xml-document.types.d.ts +7 -2
- package/dist/xml/parse/parse-xml-document.types.d.ts.map +1 -1
- package/dist/xml/parse/parser.constants.d.ts +7 -0
- package/dist/xml/parse/parser.constants.d.ts.map +1 -0
- package/dist/xml/parse/parser.d.ts.map +1 -1
- package/package.json +88 -10
- package/skills/dialecte/SKILL.md +345 -0
- package/skills/dialecte/references/api.json +1830 -0
- package/skills/dialecte/references/api.md +557 -0
- package/skills/dialecte/references/core-api.md +205 -0
- package/skills/dialecte/references/testing.md +116 -0
- package/skills/dialecte-contributing/SKILL.md +374 -0
- package/skills/dialecte-contributing/references/code-rules.md +115 -0
- package/skills/dialecte-contributing/references/landing-changes.md +87 -0
- package/skills/dialecte-contributing/references/lot-in-a-package.md +45 -0
- package/skills/dialecte-contributing/references/perf.md +40 -0
- package/skills/dialecte-contributing/references/traps.md +109 -0
- package/skills/dialecte-lot/SKILL.md +526 -0
- package/skills/dialecte-lot/references/briefs.md +161 -0
- package/skills/dialecte-lot/references/model-tiers.md +52 -0
- package/skills/dialecte-lot/references/retro.md +51 -0
- package/skills/dialecte-lot/references/standard-check.md +45 -0
- package/skills/dialecte-lot/references/stations.md +110 -0
- package/dist/project/io/import-document.d.ts +0 -7
- package/dist/project/io/import-document.d.ts.map +0 -1
- package/dist/test/assert-xml/types.d.ts +0 -2
- package/dist/test/assert-xml/types.d.ts.map +0 -1
- package/dist/utils-DJN0Md0v.js +0 -624
- package/dist/xml/build/build-xml-document.d.ts +0 -10
- package/dist/xml/build/build-xml-document.d.ts.map +0 -1
- package/dist/xml/build/build-xml-document.types.d.ts +0 -22
- package/dist/xml/build/build-xml-document.types.d.ts.map +0 -1
- package/dist/xml/build/download-file.d.ts +0 -7
- package/dist/xml/build/download-file.d.ts.map +0 -1
- package/dist/xml/build/formatter.d.ts +0 -2
- package/dist/xml/build/formatter.d.ts.map +0 -1
- package/dist/xml/build/serialize.d.ts +0 -11
- package/dist/xml/build/serialize.d.ts.map +0 -1
- package/dist/xml/build/serialize.types.d.ts +0 -12
- package/dist/xml/build/serialize.types.d.ts.map +0 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Document, ExtensionModules, MergedExtensions, QueryExtensions, Query } from '../document';
|
|
2
|
-
import { InitEmptyDocumentOptions, ImportDocumentOptions, ImportedDocument, ImportEntry,
|
|
2
|
+
import { InitEmptyDocumentOptions, ImportDocumentOptions, ImportFilesOptions, ImportedDocument, ImportEntry, ProjectExportParams, ProjectExportResult, ProjectExportResultMaybeDocument, ProjectExportResultWithDocument, ProjectExportBlobParams, ExportBlobResult, ProjectParams, ProjectState, DocumentRecord } from './types';
|
|
3
3
|
import { Perf } from '../perf';
|
|
4
4
|
import { Store } from '../store';
|
|
5
5
|
import { AnyDialecteConfig, BlobAttachment, BlobRecord, DialecteHooks } from '../types';
|
|
@@ -11,7 +11,10 @@ import { AnyDialecteConfig, BlobAttachment, BlobRecord, DialecteHooks } from '..
|
|
|
11
11
|
*/
|
|
12
12
|
export declare class Project<GenericConfig extends AnyDialecteConfig, GenericModules extends ExtensionModules = Record<never, never>, GenericStore extends Store = Store> {
|
|
13
13
|
private _name?;
|
|
14
|
+
/** The store of the project last opened: open, or closed once `closing`. */
|
|
14
15
|
private _store?;
|
|
16
|
+
/** The store of an `open` it refused, closed again: kept only for `destroy()`, the reset of that project. */
|
|
17
|
+
private refusedStore?;
|
|
15
18
|
/**
|
|
16
19
|
* The project channel: posts this realm's mutations and listens for other
|
|
17
20
|
* realms' (other tab / iframe / second Project instance). BroadcastChannel
|
|
@@ -22,17 +25,49 @@ export declare class Project<GenericConfig extends AnyDialecteConfig, GenericMod
|
|
|
22
25
|
private _channel?;
|
|
23
26
|
/** Set once close()/destroy() begins, to stop new channel-triggered store work. */
|
|
24
27
|
private closing;
|
|
25
|
-
/**
|
|
26
|
-
|
|
28
|
+
/**
|
|
29
|
+
* Whether the open store announces its changes itself (`Store.subscribe`): the Project then hears them from it,
|
|
30
|
+
* reposts the other connections' on a channel of its own, and posts its own only when the store told one.
|
|
31
|
+
*/
|
|
32
|
+
private announcing;
|
|
33
|
+
/** The store's notices let go: called as the open project closes. */
|
|
34
|
+
private stopStoreNotices;
|
|
35
|
+
/**
|
|
36
|
+
* The changes the store told as this Project's own, waiting for the call that made them to post them (none waiting:
|
|
37
|
+
* a call changed nothing). Each post takes them all: the call's own posted as the call tells it, the others as the
|
|
38
|
+
* store told them, folded too (a change no call of the Project's own waits for is folded then).
|
|
39
|
+
*/
|
|
40
|
+
private ownChangesTold;
|
|
41
|
+
/**
|
|
42
|
+
* The open's documents read: calls are taken from then on, and the changes told meanwhile - its own and other
|
|
43
|
+
* connections' - fold into a state that holds them.
|
|
44
|
+
*/
|
|
45
|
+
private openSettled;
|
|
46
|
+
/** Every change told while the project opens, its own and other connections', in the order told: folded once open. */
|
|
47
|
+
private toldWhileOpening;
|
|
48
|
+
/** A resync told while the project opens, or more changes than held: its state read again once the open settled. */
|
|
49
|
+
private resyncWhenSettled;
|
|
50
|
+
/** The name of the open project's channel (`projectChannelName`), set as it opens. */
|
|
51
|
+
private _channelName?;
|
|
27
52
|
/** In-flight fire-and-forget work triggered by foreign messages, awaited on teardown. */
|
|
28
53
|
private readonly pendingBroadcastWork;
|
|
29
54
|
private readonly storage;
|
|
55
|
+
/**
|
|
56
|
+
* The dialecte the project belongs to (its declaration's `id`), when its factory said: with the name, which
|
|
57
|
+
* project a store holds. `undefined` for a Project made with no dialecte.
|
|
58
|
+
*/
|
|
59
|
+
readonly dialecteId: string | undefined;
|
|
60
|
+
/** The dialecte's version and its engine worker's address, from its factory: what `sqlite` storage runs. */
|
|
61
|
+
private readonly dialecteVersion;
|
|
62
|
+
private readonly engineUrl;
|
|
30
63
|
private configs;
|
|
31
64
|
private defaultConfigKey;
|
|
32
65
|
private mergedExtensions?;
|
|
33
66
|
private hooks?;
|
|
34
67
|
/** Single project-lived dev perf helper; frozen no-op unless `dev.perf`. */
|
|
35
68
|
readonly perf: Perf;
|
|
69
|
+
/** Whether `dev.perf` is on: the store then hands back the timings of each import it runs. */
|
|
70
|
+
private readonly perfEnabled;
|
|
36
71
|
get name(): string;
|
|
37
72
|
/** The store of an open project: one never opened, closed or destroyed has none to read or write. */
|
|
38
73
|
private get store();
|
|
@@ -43,22 +78,91 @@ export declare class Project<GenericConfig extends AnyDialecteConfig, GenericMod
|
|
|
43
78
|
private importChain;
|
|
44
79
|
/** Run `work` once every import queued before it has settled: one file in flight per project. */
|
|
45
80
|
private enqueueImport;
|
|
81
|
+
/** The imports queued and not settled yet, the one running included: what a close says it waits for. */
|
|
82
|
+
private readonly importsInFlight;
|
|
83
|
+
/**
|
|
84
|
+
* The Project's `open`, `close` and `destroy`, one at a time in the order called: each runs once the one
|
|
85
|
+
* called before it has settled, however it settled.
|
|
86
|
+
*/
|
|
87
|
+
private lifecycle;
|
|
88
|
+
/** How many times a project was opened in this Project: what a batch import or a Document belongs to. */
|
|
89
|
+
private opens;
|
|
90
|
+
/** How many opens, closes and destroys are called and not settled yet, the one running included. */
|
|
91
|
+
private lifecycleTurns;
|
|
92
|
+
/** Run `work` in its turn among the Project's opens, closes and destroys. */
|
|
93
|
+
private inLifecycleTurn;
|
|
94
|
+
/**
|
|
95
|
+
* The writes of the open project running (a document made or removed, an undo, a redo, a blob's
|
|
96
|
+
* change): the whole close waits for them, as for the imports, before it closes the store.
|
|
97
|
+
*/
|
|
98
|
+
private readonly writes;
|
|
99
|
+
/** A write of the open project counted in `writes` until the function answered is called (once). */
|
|
100
|
+
private startCountedWrite;
|
|
101
|
+
/** Run a write of the open project, counted in `writes`; it reads the store at the call. */
|
|
102
|
+
private counted;
|
|
46
103
|
/** Resolved once every import queued so far has settled, however it settled. */
|
|
47
104
|
private settledImports;
|
|
48
105
|
private get channel();
|
|
49
106
|
/**
|
|
50
107
|
* Name of this project's BroadcastChannel — the public event contract.
|
|
51
108
|
* Open your own instance (see createChannel) to receive every
|
|
52
|
-
*
|
|
109
|
+
* ProjectChannelEvent (each change, and a resync), same-tab and cross-tab.
|
|
53
110
|
*/
|
|
54
111
|
get channelName(): string;
|
|
55
112
|
/**
|
|
56
113
|
* Convenience: a fresh BroadcastChannel on this project's channel.
|
|
57
114
|
* The caller owns it — call channel.close() when done listening.
|
|
115
|
+
*
|
|
116
|
+
* @intent listen to project events, receive commits and imports made in other tabs
|
|
58
117
|
*/
|
|
59
118
|
createChannel(): BroadcastChannel;
|
|
60
|
-
/**
|
|
119
|
+
/**
|
|
120
|
+
* Post a change of this Project's on the project channel. On a store that announces, only what the store told: the
|
|
121
|
+
* call's own change when the store told it (none: the call changed nothing, nothing posted), and every other change
|
|
122
|
+
* of the Project's own told meanwhile (a call running beside it, a second step of the same call), each once.
|
|
123
|
+
*/
|
|
61
124
|
private broadcast;
|
|
125
|
+
/**
|
|
126
|
+
* Post the changes of this Project's own the store told, each once: `own` (the call's change, its state already
|
|
127
|
+
* updated) posted as the call made it when told; every other folded into the state, then posted. Without `own`, as
|
|
128
|
+
* after a write refused with its engine lost: only what the store told is posted, nothing guessed.
|
|
129
|
+
*/
|
|
130
|
+
private postToldChanges;
|
|
131
|
+
/**
|
|
132
|
+
* A notice of the open store: another connection's change folded into this Project's state and reposted to its
|
|
133
|
+
* listeners; its own kept, posted once the call that made it has updated the state - or, folded, once no call runs
|
|
134
|
+
* (a write on the store held directly, a call that ended without posting), or at once past `CHANGES_HELD_MAX` (then
|
|
135
|
+
* before a running call's state holds its own); a resync reads it all again. While the project opens, every change
|
|
136
|
+
* is held until its documents are read (`holdWhileOpening`). A fold no call awaits that fails (a Document's
|
|
137
|
+
* subscriber throwing, the store refusing a read) is reported on the console.
|
|
138
|
+
*/
|
|
139
|
+
private onStoreNotice;
|
|
140
|
+
/** Another Project's change heard on the name's channel (a store that announces nothing): folded once open. */
|
|
141
|
+
private onChannelHeard;
|
|
142
|
+
/**
|
|
143
|
+
* A change told while the project opens, held: the open reads its documents meanwhile, and a change folded now
|
|
144
|
+
* would find no entry, or be undone by that read; no call is taken that would claim it. Folded, in the order told,
|
|
145
|
+
* once the open settled - past `CHANGES_HELD_MAX`, or a resync told meanwhile, the state read again instead.
|
|
146
|
+
*/
|
|
147
|
+
private holdWhileOpening;
|
|
148
|
+
/**
|
|
149
|
+
* A change no call claims folded into this Project's state - reposted first to its listeners where the store
|
|
150
|
+
* announces (elsewhere the change came on the channel they hear).
|
|
151
|
+
*/
|
|
152
|
+
private foldTold;
|
|
153
|
+
/** Whether a call of this Project runs, which posts the changes its store tells it: a write, a Document's commit, an import. */
|
|
154
|
+
private callsRunning;
|
|
155
|
+
/**
|
|
156
|
+
* The changes of this Project's own kept, once no call runs to post them (none made them, or the one that did
|
|
157
|
+
* ended without posting - a transaction that threw): posted and folded on a microtask. A call running then claims
|
|
158
|
+
* them instead, posting them once its state holds its own.
|
|
159
|
+
*/
|
|
160
|
+
private drainWhenIdle;
|
|
161
|
+
private postUnclaimedChanges;
|
|
162
|
+
/** Whether the open Project posts what no call claims: once its open settled (its documents read), not while it closes. */
|
|
163
|
+
private canPost;
|
|
164
|
+
/** Changes may have been missed: the registry, each document's history read again, every document's view woken. */
|
|
165
|
+
private resync;
|
|
62
166
|
readonly state: ProjectState;
|
|
63
167
|
/**
|
|
64
168
|
* In-realm reactive registry, keyed by documentId (parallel to `state.documents`).
|
|
@@ -71,6 +175,10 @@ export declare class Project<GenericConfig extends AnyDialecteConfig, GenericMod
|
|
|
71
175
|
*/
|
|
72
176
|
private readonly stateSubscribers;
|
|
73
177
|
private subscribeState;
|
|
178
|
+
/**
|
|
179
|
+
* Every subscriber of the document told, one that throws stopping no other; the first failure thrown once all are
|
|
180
|
+
* told - the call that changed the document fails with it, a fold no call awaits reports it.
|
|
181
|
+
*/
|
|
74
182
|
private signalStateChange;
|
|
75
183
|
constructor(params: {
|
|
76
184
|
configs: Record<string, GenericConfig>;
|
|
@@ -84,12 +192,31 @@ export declare class Project<GenericConfig extends AnyDialecteConfig, GenericMod
|
|
|
84
192
|
dev?: {
|
|
85
193
|
perf?: boolean;
|
|
86
194
|
};
|
|
195
|
+
dialecteId?: ProjectParams<GenericConfig>['dialecteId'];
|
|
196
|
+
dialecteVersion?: ProjectParams<GenericConfig>['dialecteVersion'];
|
|
197
|
+
engineUrl?: ProjectParams<GenericConfig>['engineUrl'];
|
|
87
198
|
});
|
|
88
199
|
/**
|
|
89
200
|
* Open a named project: resolve store, open DB connection, hydrate state.
|
|
90
201
|
* Must be called before import/export/openDocument.
|
|
202
|
+
*
|
|
203
|
+
* Runs in turn with the Project's other `open`, `close` and `destroy` calls. On a Project already open -
|
|
204
|
+
* on another project or on the same one - it first closes it as `close()` does, and a call made from the
|
|
205
|
+
* `open` call on is refused until the last `open`, `close` or `destroy` called has settled; a Document of that
|
|
206
|
+
* open answers `STORE_CLOSED` when the store is made for each open (`local`, `sqlite`, `inMemory`) - a `custom` store is
|
|
207
|
+
* the same one opened again: open the Documents again. An open whose store refuses, or whose documents cannot
|
|
208
|
+
* be read, leaves the Project closed; `destroy()` on it still removes that project (the reset of
|
|
209
|
+
* `PROJECT_DATABASE_LOST`), then `open` makes it again, empty.
|
|
210
|
+
*
|
|
211
|
+
* Never await `open`, `close` or `destroy` inside a hook or a transaction callback: the close waits for that
|
|
212
|
+
* work, which waits for the close (after 10 seconds the console says what it waits for).
|
|
213
|
+
*
|
|
214
|
+
* @intent open or create a project database, start working on a project, reopen a project after close
|
|
91
215
|
*/
|
|
92
216
|
open(name: string): Promise<this>;
|
|
217
|
+
private openNow;
|
|
218
|
+
/** The store of the project named, resolved from the storage option and never opened here. */
|
|
219
|
+
private resolveProjectStore;
|
|
93
220
|
/**
|
|
94
221
|
* Fold an incoming channel message into project state. This realm never
|
|
95
222
|
* receives its own posts (BroadcastChannel withholds them from the posting
|
|
@@ -97,33 +224,80 @@ export declare class Project<GenericConfig extends AnyDialecteConfig, GenericMod
|
|
|
97
224
|
* iframe, or a second Project instance. Local mutations maintain state inline.
|
|
98
225
|
*/
|
|
99
226
|
private onChannelMessage;
|
|
227
|
+
/** The open store's notices let go. */
|
|
228
|
+
private stopListeningToStore;
|
|
100
229
|
/**
|
|
101
230
|
* Track channel-triggered fire-and-forget work so `close`/`destroy` can wait for
|
|
102
231
|
* it to settle before tearing down the store. A foreign message delivered as the
|
|
103
232
|
* project is closing would otherwise read or reconcile the store after it was
|
|
104
|
-
* closed/deleted — surfacing as DatabaseClosedError or ConstraintError.
|
|
105
|
-
*
|
|
233
|
+
* closed/deleted — surfacing as DatabaseClosedError or ConstraintError. A failure
|
|
234
|
+
* is reported unless the project closes; never rethrown.
|
|
106
235
|
*/
|
|
107
236
|
private trackBroadcastWork;
|
|
237
|
+
/**
|
|
238
|
+
* A change of its store no call awaits, failing as it is folded in - a Document's subscriber throwing, or the store
|
|
239
|
+
* refusing a read: told on the console, the other changes folded all the same.
|
|
240
|
+
*/
|
|
241
|
+
private reportFoldFailure;
|
|
242
|
+
/** A document's registry entry read again (another view renamed or moved it): its view woken. */
|
|
243
|
+
private refreshDocumentRecord;
|
|
108
244
|
/** Recompute canUndo/canRedo for a document from the store's history. */
|
|
109
245
|
private refreshHistoryStatus;
|
|
246
|
+
/** A document's canUndo/canRedo read from `store` into its entry (the open's own read, before calls are taken). */
|
|
247
|
+
private readHistoryStatus;
|
|
110
248
|
/**
|
|
111
|
-
* Close the store and release resources, once the imports in flight
|
|
112
|
-
*
|
|
113
|
-
*
|
|
249
|
+
* Close the store and release resources, once the imports in flight (running and queued), the project's
|
|
250
|
+
* writes running (a Document's transaction or prepared commit included) and the work other realms' messages
|
|
251
|
+
* started have settled. Then the channel and the store
|
|
252
|
+
* are closed, `state.documents` is emptied and the Documents' subscriptions are dropped. From the call on,
|
|
253
|
+
* the project is closed: a new call throws `PROJECT_NOT_OPENED`, a Document opened before answers
|
|
254
|
+
* `STORE_CLOSED` (on a `custom` store opened again it writes but tells nothing: open it again). The stored documents stay.
|
|
255
|
+
* Runs in turn with the Project's other `open`, `close` and `destroy` calls.
|
|
256
|
+
*
|
|
257
|
+
* Never await it inside a hook or a transaction callback: the close waits for that work, which waits for it.
|
|
258
|
+
* An import whose dialecte hook never settles keeps it waiting too (nothing aborts a hook): after
|
|
259
|
+
* `CLOSE_WAIT_REPORT_MS` the console names the files of the imports it waits for.
|
|
260
|
+
*
|
|
261
|
+
* @intent close a project, release the database connection when leaving a page
|
|
114
262
|
*/
|
|
115
263
|
close(): Promise<void>;
|
|
264
|
+
/** The whole close of an open project (the channel is there only while one is); nothing when none is open. */
|
|
265
|
+
private closeNow;
|
|
116
266
|
/**
|
|
117
|
-
*
|
|
267
|
+
* What a close still waits for, told once on the console - the files of the imports by name: a close that
|
|
268
|
+
* never ends is an import whose dialecte hook never settles, or a call awaited inside the work it waits for.
|
|
269
|
+
*/
|
|
270
|
+
private reportCloseWait;
|
|
271
|
+
/**
|
|
272
|
+
* Destroy the project - deletes the database entirely, every document with its history and blobs,
|
|
273
|
+
* once the imports in flight have landed; refused `PROJECT_OPEN_ELSEWHERE`, nothing removed, while another
|
|
274
|
+
* connection - a project or store of the name, in this page or another tab - has it open. To delete one
|
|
275
|
+
* document, use `removeDocument`.
|
|
276
|
+
*
|
|
277
|
+
* The project destroyed is the one this Project last opened, or the one whose `open` its store refused
|
|
278
|
+
* (`PROJECT_DATABASE_LOST`): that store is not opened again, and `open` then makes the project again, empty.
|
|
279
|
+
* Refused, the project is closed all the same, as by `close()`: a `destroy()` called again once the other
|
|
280
|
+
* connection closed removes it.
|
|
281
|
+
* Runs in turn with the Project's other `open`, `close` and `destroy` calls.
|
|
282
|
+
*
|
|
283
|
+
* Never await it inside a hook or a transaction callback: the close waits for that work, which waits for it.
|
|
284
|
+
*
|
|
285
|
+
* @intent delete a whole project, wipe the project database with every document
|
|
118
286
|
*/
|
|
119
287
|
destroy(): Promise<void>;
|
|
288
|
+
private destroyNow;
|
|
120
289
|
/**
|
|
121
290
|
* Register a new empty document in the project.
|
|
122
291
|
* Returns the new documentId. Records are added later via import or transactions.
|
|
292
|
+
*
|
|
293
|
+
* @intent create a new empty document, start a document from scratch without a file
|
|
123
294
|
*/
|
|
124
295
|
initEmptyDocument(options?: InitEmptyDocumentOptions): Promise<string>;
|
|
125
296
|
/**
|
|
126
|
-
* Remove
|
|
297
|
+
* Remove one document from the project - its records, history and blobs - and tell other tabs. The
|
|
298
|
+
* other documents stay.
|
|
299
|
+
*
|
|
300
|
+
* @intent delete a document from the project, remove one file and its records
|
|
127
301
|
*/
|
|
128
302
|
removeDocument(documentId: string): Promise<void>;
|
|
129
303
|
/**
|
|
@@ -136,30 +310,69 @@ export declare class Project<GenericConfig extends AnyDialecteConfig, GenericMod
|
|
|
136
310
|
* Import Files into the project: one entry per file, in the order given. The files are imported
|
|
137
311
|
* one after the other - memory is bounded by one file's batches, the registry sees one import -
|
|
138
312
|
* and a file that fails is its own `failed` entry, the next file still attempted: nothing of a
|
|
139
|
-
* failed file lands. The call itself rejects only for what is about the call: an unknown
|
|
140
|
-
* `configKey`, a project not open
|
|
313
|
+
* failed file lands (but an import whose engine was lost after it landed: see `importFile`). The call itself rejects only for what is about the call: an unknown
|
|
314
|
+
* `configKey`, a project not open, a `path` (`DOCUMENT_PATH_INVALID`: a path names one file,
|
|
315
|
+
* `importFile` takes it).
|
|
316
|
+
*
|
|
317
|
+
* @intent import several XML files at once, get one result per file without a throw for a failed file
|
|
141
318
|
*/
|
|
142
|
-
import(files: File[], options?:
|
|
319
|
+
import(files: File[], options?: ImportFilesOptions): Promise<ImportEntry[]>;
|
|
143
320
|
/**
|
|
144
|
-
* Import one File into the project:
|
|
145
|
-
* the project state and broadcast once
|
|
146
|
-
*
|
|
147
|
-
*
|
|
321
|
+
* Import one File into the project: the store registers, parses and stores it next to the data.
|
|
322
|
+
* The document is in the project state and broadcast once the store answers it `ready`; whatever
|
|
323
|
+
* fails before that, or an abort through `options.signal`, leaves nothing and is thrown
|
|
324
|
+
* (`PARSE_ERROR` for a malformed file, `IMPORT_ABORTED`, `IMPORT_FAILED` wrapping a foreign
|
|
325
|
+
* error). One refusal leaves its document: an import whose engine was lost after it landed is
|
|
326
|
+
* refused `STORE_ENGINE_LOST`, `meta.outcome` `applied`, its document in the state and broadcast. `options.onProgress` is told after each stored batch, never awaited. One file is in
|
|
327
|
+
* flight per project: a call made while another import runs waits for it.
|
|
328
|
+
*
|
|
329
|
+
* @intent import an XML file, load a file into the project, parse XML into records
|
|
148
330
|
*/
|
|
149
331
|
importFile(file: File, options?: ImportDocumentOptions): Promise<ImportedDocument>;
|
|
150
332
|
private importOne;
|
|
151
333
|
/**
|
|
152
|
-
*
|
|
334
|
+
* A write of the project with no id to ask its outcome by (an undo, a redo, a removal): refused `STORE_ENGINE_LOST`
|
|
335
|
+
* it may have landed, so the project's documents (and the document's history) are read again before the refusal is
|
|
336
|
+
* thrown - never made again. The change the store told before its engine went is posted to the listeners.
|
|
337
|
+
*/
|
|
338
|
+
private writeOrReadAgain;
|
|
339
|
+
/**
|
|
340
|
+
* An import refused `STORE_ENGINE_LOST`: its outcome asked once by its id; landed, its document read into the
|
|
341
|
+
* project's state (its diagnostics went with the lost answer, so it is no entry) and posted to the listeners - the
|
|
342
|
+
* refusal says which outcome, and the document it made (none when the documents could not be read again).
|
|
343
|
+
*/
|
|
344
|
+
private lostImportError;
|
|
345
|
+
/**
|
|
346
|
+
* Export a document through the store: its file (`Blob`, formatted unless `indent: false`) and filename. On the
|
|
347
|
+
* page, `xmlDocument: true` also answers its DOM (parsed from the compact file: pass `indent: false` to export
|
|
348
|
+
* once) and `download` saves the formatted file (the save dialog is asked first). Two store exports made for one
|
|
349
|
+
* call may see two states of the document if a commit lands between them.
|
|
350
|
+
*
|
|
351
|
+
* @intent export a document to an XML file, get a document as a Blob, download a document, save a document as XML, read the exported XML as a DOM
|
|
352
|
+
*/
|
|
353
|
+
export(params: ProjectExportParams & {
|
|
354
|
+
xmlDocument: true;
|
|
355
|
+
}): Promise<ProjectExportResultWithDocument>;
|
|
356
|
+
export(params: ProjectExportParams & {
|
|
357
|
+
xmlDocument?: false;
|
|
358
|
+
}): Promise<ProjectExportResult>;
|
|
359
|
+
export(params: ProjectExportParams): Promise<ProjectExportResultMaybeDocument>;
|
|
360
|
+
/**
|
|
361
|
+
* The documents of the project; one still importing - here or in another realm - is not among them.
|
|
362
|
+
*
|
|
363
|
+
* @intent list the documents of a project, show the files a project holds
|
|
153
364
|
*/
|
|
154
|
-
export(documentId: string, options?: ExportDocumentOptions): Promise<{
|
|
155
|
-
xmlDocument: XMLDocument;
|
|
156
|
-
filename: string;
|
|
157
|
-
}>;
|
|
158
|
-
/** The documents of the project; one still importing - here or in another realm - is not among them. */
|
|
159
365
|
getDocuments(): Promise<DocumentRecord[]>;
|
|
366
|
+
/**
|
|
367
|
+
* The metadata record of one document of the project, or `undefined` when it is unknown or still importing.
|
|
368
|
+
*
|
|
369
|
+
* @intent check a document exists, read a document's name or config key by id
|
|
370
|
+
*/
|
|
160
371
|
getDocument(documentId: string): Promise<DocumentRecord | undefined>;
|
|
161
372
|
/**
|
|
162
373
|
* Open a file-scoped Document for querying and mutating a specific file.
|
|
374
|
+
*
|
|
375
|
+
* @intent open a document to read or write it, get the Document of an id
|
|
163
376
|
*/
|
|
164
377
|
openDocument(documentId: string): Document<GenericConfig, MergedExtensions<GenericModules>>;
|
|
165
378
|
/**
|
|
@@ -174,52 +387,123 @@ export declare class Project<GenericConfig extends AnyDialecteConfig, GenericMod
|
|
|
174
387
|
* arrives in another realm, even before the import broadcast has been folded
|
|
175
388
|
* in. Returns `{ live: false, ready: false }` for an unknown document rather
|
|
176
389
|
* than throwing.
|
|
390
|
+
*
|
|
391
|
+
* @intent check that a document imported in another tab can be opened, wait for a document from another realm
|
|
177
392
|
*/
|
|
178
393
|
getDocumentStatus(documentId: string): Promise<{
|
|
179
394
|
live: boolean;
|
|
180
395
|
ready: boolean;
|
|
181
396
|
}>;
|
|
182
397
|
/**
|
|
183
|
-
* Get the config for a
|
|
398
|
+
* Get the dialecte config a document uses, or `undefined` for a document the project does not know.
|
|
399
|
+
*
|
|
400
|
+
* @intent get the dialecte config of a document, know which schema a document uses
|
|
184
401
|
*/
|
|
185
402
|
getDocumentConfig(documentId: string): GenericConfig | undefined;
|
|
403
|
+
/**
|
|
404
|
+
* Revert the last committed transaction of a document and tell other tabs. Does nothing when there is nothing to undo.
|
|
405
|
+
*
|
|
406
|
+
* @intent undo the last change to a document, roll back a commit
|
|
407
|
+
*/
|
|
186
408
|
undo(documentId: string): Promise<void>;
|
|
409
|
+
/**
|
|
410
|
+
* Re-apply the last undone transaction of a document and tell other tabs. Does nothing when there is nothing to redo.
|
|
411
|
+
*
|
|
412
|
+
* @intent redo an undone change to a document
|
|
413
|
+
*/
|
|
187
414
|
redo(documentId: string): Promise<void>;
|
|
188
415
|
/**
|
|
189
416
|
* Add a blob owned by `documentId`. The binary lives in `blob_{documentId}`.
|
|
190
417
|
* Returns the generated blob id.
|
|
418
|
+
*
|
|
419
|
+
* @intent store a binary file in the project, add an attachment owned by a document
|
|
191
420
|
*/
|
|
192
421
|
addBlob(documentId: string, file: File, attachedTo?: BlobAttachment[]): Promise<string>;
|
|
422
|
+
/**
|
|
423
|
+
* Read a stored blob: its metadata entry and its binary data, or `undefined` when the id is unknown.
|
|
424
|
+
*
|
|
425
|
+
* @intent read an attached file's content, load a blob by id
|
|
426
|
+
*/
|
|
193
427
|
getBlob(blobId: string): Promise<{
|
|
194
428
|
entry: BlobRecord;
|
|
195
429
|
data: Blob;
|
|
196
430
|
} | undefined>;
|
|
197
431
|
/**
|
|
198
|
-
* Export a blob from the store
|
|
199
|
-
*
|
|
200
|
-
*
|
|
432
|
+
* Export a blob from the store: `{ entry, data, filename }`; `download` also saves it (the save dialog, or a
|
|
433
|
+
* browser download), under its name or the one given.
|
|
434
|
+
*
|
|
435
|
+
* @intent download a stored file, save a blob to disk, read a blob with its file name
|
|
436
|
+
*/
|
|
437
|
+
exportBlob(params: ProjectExportBlobParams): Promise<ExportBlobResult>;
|
|
438
|
+
/**
|
|
439
|
+
* The blobs referenced from a document (any of their attachments points into it).
|
|
440
|
+
*
|
|
441
|
+
* @intent list the files attached to a document
|
|
201
442
|
*/
|
|
202
|
-
exportBlob(blobId: string, options?: ExportBlobOptions): Promise<ExportBlobResult>;
|
|
203
443
|
getBlobsByDocument(documentId: string): Promise<BlobRecord[]>;
|
|
444
|
+
/**
|
|
445
|
+
* The blobs referenced from one element of a document.
|
|
446
|
+
*
|
|
447
|
+
* @intent list the files attached to one element
|
|
448
|
+
*/
|
|
204
449
|
getBlobsByRecord(documentId: string, recordRef: string): Promise<BlobRecord[]>;
|
|
450
|
+
/**
|
|
451
|
+
* The blobs of the project that no document references (no attachment).
|
|
452
|
+
*
|
|
453
|
+
* @intent list unattached files, find orphan blobs to clean up
|
|
454
|
+
*/
|
|
205
455
|
getStandaloneBlobs(): Promise<BlobRecord[]>;
|
|
456
|
+
/**
|
|
457
|
+
* Reference an existing blob from an element of a document (optionally from one of its attributes) and tell other tabs.
|
|
458
|
+
*
|
|
459
|
+
* @intent link a stored file to an element, attach a blob to a record
|
|
460
|
+
*/
|
|
206
461
|
attachBlob(blobId: string, ref: BlobAttachment): Promise<void>;
|
|
462
|
+
/**
|
|
463
|
+
* Drop the reference from an element of a document to a blob; the blob itself stays stored.
|
|
464
|
+
*
|
|
465
|
+
* @intent unlink a file from an element, detach a blob from a record
|
|
466
|
+
*/
|
|
207
467
|
detachBlob(blobId: string, ref: {
|
|
208
468
|
documentId: string;
|
|
209
469
|
recordRef: string;
|
|
210
470
|
}): Promise<void>;
|
|
471
|
+
/**
|
|
472
|
+
* Delete a blob and its binary data from the project and tell other tabs. Does nothing when the id is unknown.
|
|
473
|
+
*
|
|
474
|
+
* @intent delete a stored file, remove a blob for good
|
|
475
|
+
*/
|
|
211
476
|
removeBlob(blobId: string): Promise<void>;
|
|
212
477
|
/**
|
|
213
478
|
* Run a query function across all documents, return the first non-undefined result.
|
|
214
479
|
* Iterates documents sequentially; stops at the first match.
|
|
480
|
+
*
|
|
481
|
+
* @intent find the first match across every document, search all documents of a project
|
|
215
482
|
*/
|
|
216
483
|
queryFirst<Result>(queryFunction: (query: Query<GenericConfig> & QueryExtensions<MergedExtensions<GenericModules>>) => Promise<Result | undefined>): Promise<Result | undefined>;
|
|
217
484
|
/**
|
|
218
485
|
* Run a query function across all documents, collect and flatten results.
|
|
219
486
|
* Iterates documents sequentially; merges all non-empty arrays.
|
|
487
|
+
*
|
|
488
|
+
* @intent collect results from every document, run one query over all documents
|
|
220
489
|
*/
|
|
221
490
|
queryAll<Result>(queryFunction: (query: Query<GenericConfig> & QueryExtensions<MergedExtensions<GenericModules>>) => Promise<Result[]>): Promise<Result[]>;
|
|
222
|
-
/**
|
|
491
|
+
/**
|
|
492
|
+
* Visit each document of the open project in turn, until `visit` answers `true`: the ids taken at the call, a
|
|
493
|
+
* document removed meanwhile skipped; refused `PROJECT_NOT_OPENED` once that open closes or another one opens,
|
|
494
|
+
* never a partial answer or one mixing two opens.
|
|
495
|
+
*/
|
|
496
|
+
private visitOpenDocuments;
|
|
497
|
+
/** Whether the open a Document was made in is still the open one, its channel there. */
|
|
498
|
+
private isCurrentOpen;
|
|
499
|
+
/** `PROJECT_NOT_OPENED` once the open a call was made in has closed, or another one opened. */
|
|
500
|
+
private refuseClosedOpen;
|
|
501
|
+
/**
|
|
502
|
+
* Expose the store's own database object, for debugging: the Dexie instance on `local` (cast it: the type is the
|
|
503
|
+
* store's, `unknown` unless the Project's store type is given), `null` on `sqlite` and `inMemory`.
|
|
504
|
+
*
|
|
505
|
+
* @intent inspect the underlying database, debug what the store holds
|
|
506
|
+
*/
|
|
223
507
|
getDatabaseInstance(): ReturnType<GenericStore['getDatabaseInstance']>;
|
|
224
508
|
private refreshState;
|
|
225
509
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"project.d.ts","sourceRoot":"","sources":["../../src/project/project.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"project.d.ts","sourceRoot":"","sources":["../../src/project/project.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAA;AAarC,OAAO,KAAK,EACX,wBAAwB,EACxB,qBAAqB,EACrB,kBAAkB,EAClB,gBAAgB,EAChB,WAAW,EACX,mBAAmB,EACnB,mBAAmB,EACnB,gCAAgC,EAChC,+BAA+B,EAC/B,uBAAuB,EACvB,gBAAgB,EAGhB,aAAa,EACb,YAAY,EACZ,cAAc,EACd,MAAM,SAAS,CAAA;AAChB,OAAO,KAAK,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,eAAe,EAAE,KAAK,EAAE,MAAM,YAAY,CAAA;AAC5F,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAA;AAClC,OAAO,KAAK,EAAoB,KAAK,EAAe,MAAM,SAAS,CAAA;AACnE,OAAO,KAAK,EAAE,iBAAiB,EAAE,cAAc,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,SAAS,CAAA;AAI3F;;;;;GAKG;AACH,qBAAa,OAAO,CACnB,aA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AU,CAAC,MAAM,EAAE,MAAM,EAAE,GAAG,EAAE;QAAE,UAAU,EAAE,MAAM,CAAC;QAAC,SAAS,EAAE,MAAM,CAAA;KAAE,GAAG,OAAO,CAAC,IAAI,CAAC;IAO/F;;;;OAIG;IACG,UAAU,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAS/C;;;;;OAKG;IACG,UAAU,CAAC,MAAM,EACtB,aAAa,EAAE,CACd,KAAK,EAAE,KAAK,CAAC,aAAa,CAAC,GAAG,eAAe,CAAC,gBAAgB,CAAC,cAAc,CAAC,CAAC,KAC3E,OAAO,CAAC,MAAM,GAAG,SAAS,CAAC,GAC9B,OAAO,CAAC,MAAM,GAAG,SAAS,CAAC;IAW9B;;;;;OAKG;IACG,QAAQ,CAAC,MAAM,EACpB,aAAa,EAAE,CACd,KAAK,EAAE,KAAK,CAAC,aAAa,CAAC,GAAG,eAAe,CAAC,gBAAgB,CAAC,cAAc,CAAC,CAAC,KAC3E,OAAO,CAAC,MAAM,EAAE,CAAC,GACpB,OAAO,CAAC,MAAM,EAAE,CAAC;IAWpB;;;;OAIG;YACW,kBAAkB;IAgBhC,wFAAwF;IACxF,OAAO,CAAC,aAAa;IAIrB,+FAA+F;IAC/F,OAAO,CAAC,gBAAgB;IASxB;;;;;OAKG;IACH,mBAAmB,IAAI,UAAU,CAAC,YAAY,CAAC,qBAAqB,CAAC,CAAC;YAIxD,YAAY;IAK1B;;;;;OAKG;YACW,sBAAsB;CAKpC"}
|
|
@@ -1,18 +1,6 @@
|
|
|
1
1
|
import { DocumentRecord } from '../types';
|
|
2
|
-
/** How often an import says it is still alive, through `DocumentRecord.importingAt`. */
|
|
3
|
-
export declare const IMPORT_HEARTBEAT_MS = 2000;
|
|
4
|
-
/**
|
|
5
|
-
* An import whose last heartbeat is older than this was left by a realm that died (a tab closed
|
|
6
|
-
* mid-import): `open()` removes it. Generous on purpose - a false "dead" loses a running import, a
|
|
7
|
-
* false "alive" only keeps a hidden leftover a few minutes longer: a hidden tab's timers are
|
|
8
|
-
* throttled to once a minute by the browser, and a dialecte's `afterImport` on a very large file
|
|
9
|
-
* may hold the main thread for tens of seconds.
|
|
10
|
-
*/
|
|
11
|
-
export declare const STALE_IMPORT_MS: number;
|
|
12
2
|
/** A document whose records are still being stored - by this realm or another one. */
|
|
13
3
|
export declare function isImporting(record: DocumentRecord): boolean;
|
|
14
|
-
/** An import nobody is running any more: still `importing`, its heartbeat long gone. */
|
|
15
|
-
export declare function isStaleImport(record: DocumentRecord, now?: number): boolean;
|
|
16
4
|
/** The documents a project opens, lists and serves: nothing half-imported is ever visible. */
|
|
17
5
|
export declare function openableDocuments(records: readonly DocumentRecord[]): DocumentRecord[];
|
|
18
6
|
//# sourceMappingURL=document-lifecycle.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"document-lifecycle.d.ts","sourceRoot":"","sources":["../../../src/project/state/document-lifecycle.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAA;AAErD,
|
|
1
|
+
{"version":3,"file":"document-lifecycle.d.ts","sourceRoot":"","sources":["../../../src/project/state/document-lifecycle.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAA;AAErD,sFAAsF;AACtF,wBAAgB,WAAW,CAAC,MAAM,EAAE,cAAc,GAAG,OAAO,CAE3D;AAED,8FAA8F;AAC9F,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,SAAS,cAAc,EAAE,GAAG,cAAc,EAAE,CAEtF"}
|
|
@@ -1,11 +1,15 @@
|
|
|
1
1
|
import { DocumentEntry, DocumentRecord } from '..';
|
|
2
2
|
/**
|
|
3
3
|
* Build the initial DocumentState for a newly registered document.
|
|
4
|
+
*
|
|
5
|
+
* @internal the project's in-memory document registry entry
|
|
4
6
|
*/
|
|
5
7
|
export declare function buildDocumentState(document: DocumentRecord): DocumentEntry;
|
|
6
8
|
/**
|
|
7
9
|
* Reconcile in-memory document state Map with the current store contents.
|
|
8
10
|
* Adds new documents, removes stale ones. Returns the mutated map for convenience.
|
|
11
|
+
*
|
|
12
|
+
* @internal the project's in-memory document registry sync
|
|
9
13
|
*/
|
|
10
14
|
export declare function reconcileDocumentState(state: Map<string, DocumentEntry>, storeDocuments: DocumentRecord[]): Map<string, DocumentEntry>;
|
|
11
15
|
//# sourceMappingURL=document-state.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"document-state.d.ts","sourceRoot":"","sources":["../../../src/project/state/document-state.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,WAAW,CAAA;AAE9D
|
|
1
|
+
{"version":3,"file":"document-state.d.ts","sourceRoot":"","sources":["../../../src/project/state/document-state.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,WAAW,CAAA;AAE9D;;;;GAIG;AACH,wBAAgB,kBAAkB,CAAC,QAAQ,EAAE,cAAc,GAAG,aAAa,CAW1E;AAED;;;;;GAKG;AACH,wBAAgB,sBAAsB,CACrC,KAAK,EAAE,GAAG,CAAC,MAAM,EAAE,aAAa,CAAC,EACjC,cAAc,EAAE,cAAc,EAAE,GAC9B,GAAG,CAAC,MAAM,EAAE,aAAa,CAAC,CAgB5B"}
|