@openfairygui/backend 0.3.0 → 0.4.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 +4 -2
- package/dist/docs.cjs +12756 -0
- package/dist/docs.d.cts +284 -0
- package/dist/docs.d.mts +284 -0
- package/dist/docs.mjs +12746 -0
- package/dist/index.cjs +1201 -97
- package/dist/index.d.cts +1867 -48
- package/dist/index.d.mts +1867 -48
- package/dist/index.mjs +1196 -98
- package/dist/node.cjs +1371 -111
- package/dist/node.d.cts +186 -12
- package/dist/node.d.mts +186 -12
- package/dist/node.mjs +1370 -111
- package/docs/skills/openfairygui/SKILL.md +16 -0
- package/docs/workflow.md +50 -0
- package/package.json +19 -5
- package/src/contracts.ts +21 -3
- package/src/diagnostics.ts +181 -0
- package/src/docs.ts +109 -0
- package/src/generated/contracts.ts +17927 -0
- package/src/generated/docs.ts +12 -0
- package/src/index.ts +27 -0
- package/src/node.ts +213 -14
- package/src/path-policy.ts +18 -0
- package/src/runtime/capabilities.ts +12 -5
- package/src/runtime/contracts.ts +147 -21
- package/src/runtime.ts +42 -8
- package/src/services/authoring-service.ts +51 -6
- package/src/services/capture-project.ts +75 -0
- package/src/services/context.ts +3 -1
- package/src/services/event-service.ts +2 -1
- package/src/services/read-service.ts +97 -1
- package/src/services/runtime-service.ts +54 -79
- package/src/services/session-project-writer.ts +31 -13
- package/src/services/transaction-preview.ts +114 -0
package/README.md
CHANGED
|
@@ -10,7 +10,7 @@ It owns:
|
|
|
10
10
|
|
|
11
11
|
- project/session lifecycle
|
|
12
12
|
- revisioned request handling
|
|
13
|
-
- coordinated
|
|
13
|
+
- coordinated save semantics, with atomic staged directory swaps on the Node adapter
|
|
14
14
|
- browser-safe project sessions
|
|
15
15
|
- browser-safe async project storage adapter
|
|
16
16
|
- adapter-backed file sessions and backend-local session locking
|
|
@@ -39,7 +39,9 @@ and browser editors can inject an async storage adapter for OPFS, IndexedDB, ZIP
|
|
|
39
39
|
or File System Access API bridges. Storage adapters must implement `unlink()` so resource rename/move/remove
|
|
40
40
|
can clean up stale source files. Existing browser projects use a session-lifetime Web Lock: a live peer tab
|
|
41
41
|
receives `lock_conflict`, while reload or abrupt document termination releases ownership without leaving a
|
|
42
|
-
persistent `.openfairygui.backend.lock` marker.
|
|
42
|
+
persistent `.openfairygui.backend.lock` marker. The Node adapter instead keeps a token-protected lock beside
|
|
43
|
+
the project directory, recovers only valid same-host stale ownership, and rejects project-directory symbolic
|
|
44
|
+
links. When Web Locks are unavailable, the storage adapter must
|
|
43
45
|
provide `acquireSessionLock()` with the same atomic cross-context and owner-termination semantics. The default
|
|
44
46
|
Node filesystem/runtime lives under `@openfairygui/backend/node` and retains its advisory lock file behavior.
|
|
45
47
|
Adapter-backed `openSession` hydrates primary resource bytes so browser-safe transactions can rename/move
|