@odla-ai/chapter 0.41.1 → 0.42.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/README.md +38 -12
- package/dist/{chunk-IAWBE5PX.js → chunk-JXFYOUDL.js} +8 -2
- package/dist/chunk-JXFYOUDL.js.map +1 -0
- package/dist/{chunk-O22RRPBT.js → chunk-MMDWXTJU.js} +2 -2
- package/dist/{chunk-PCRYLPMQ.js → chunk-S7CND3R5.js} +373 -327
- package/dist/chunk-S7CND3R5.js.map +1 -0
- package/dist/{copy-context-B14OOiYq.d.ts → copy-context-BNUzbL5g.d.ts} +19 -1
- package/dist/index.cjs +67 -11
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +66 -2
- package/dist/index.d.ts +66 -2
- package/dist/index.js +67 -11
- package/dist/index.js.map +1 -1
- package/dist/ui/admin/index.d.ts +2 -2
- package/dist/ui/admin/index.js +2 -2
- package/dist/ui/index.d.ts +2 -2
- package/dist/ui/index.js +5 -3
- package/dist/ui/member/index.d.ts +37 -9
- package/dist/ui/member/index.js +4 -2
- package/dist/worker/index.cjs +368 -62
- package/dist/worker/index.cjs.map +1 -1
- package/dist/worker/index.d.cts +19 -1
- package/dist/worker/index.d.ts +19 -1
- package/dist/worker/index.js +361 -55
- package/dist/worker/index.js.map +1 -1
- package/package.json +2 -2
- package/runbooks/greenfield.md +3 -0
- package/dist/chunk-IAWBE5PX.js.map +0 -1
- package/dist/chunk-PCRYLPMQ.js.map +0 -1
- /package/dist/{chunk-O22RRPBT.js.map → chunk-MMDWXTJU.js.map} +0 -0
package/dist/worker/index.d.cts
CHANGED
|
@@ -44,7 +44,7 @@ interface ChapterCopy {
|
|
|
44
44
|
payment: TextFields<"setupFailed" | "preparing" | "pending" | "processing" | "payAndContinue" | "incomplete" | "consent">;
|
|
45
45
|
done: TextFields<"label" | "calendarInvite" | "memberArea">;
|
|
46
46
|
accepted: TextFields<"label" | "body">;
|
|
47
|
-
gift: TextFields<"chooseSelf" | "optionsLabel" | "label" | "body" | "save" | "rotate" | "rotateFailed">;
|
|
47
|
+
gift: TextFields<"chooseSelf" | "optionsLabel" | "label" | "body" | "save" | "rotate" | "rotateFailed" | "claimTitle" | "claimBody" | "code" | "redeem" | "redeemed" | "redeemFailed">;
|
|
48
48
|
};
|
|
49
49
|
members: {
|
|
50
50
|
loadFailed: string;
|
|
@@ -185,6 +185,13 @@ interface ChapterNetworkTarget {
|
|
|
185
185
|
* this follower. Omitted by default: a target never gains write permission
|
|
186
186
|
* merely because its records are browsable. */
|
|
187
187
|
sharedNotes?: readonly string[];
|
|
188
|
+
/** Per-record-type upper bound on profile fields this leader permits its
|
|
189
|
+
* admins to edit remotely. The follower must independently delegate the
|
|
190
|
+
* same field; readable fields never become writable implicitly. */
|
|
191
|
+
editableFields?: Record<string, readonly string[]>;
|
|
192
|
+
/** Record types on which this leader permits remote lifecycle transitions.
|
|
193
|
+
* The follower must independently opt in and remains pipeline authority. */
|
|
194
|
+
stageTransitions?: readonly string[];
|
|
188
195
|
}
|
|
189
196
|
/** One signed peer allowed to browse a privacy-bounded projection of this
|
|
190
197
|
* site's CRM. The follower owns this allowlist; a leader target declaration
|
|
@@ -199,6 +206,13 @@ interface ChapterNetworkReader {
|
|
|
199
206
|
* Omitted by default: browse permission never silently grants write access.
|
|
200
207
|
* Shared notes land in the follower CRM activity feed. */
|
|
201
208
|
sharedNotes?: readonly string[];
|
|
209
|
+
/** Exact local CRM fields this reader may edit remotely, by record type.
|
|
210
|
+
* Every field must also be readable so the peer can perform an optimistic
|
|
211
|
+
* edit against the value and revision it actually reviewed. */
|
|
212
|
+
editableFields?: Record<string, readonly string[]>;
|
|
213
|
+
/** Local CRM record types on which this reader may request a lifecycle
|
|
214
|
+
* transition. Chapter still enforces the local pipeline and gates. */
|
|
215
|
+
stageTransitions?: readonly string[];
|
|
202
216
|
}
|
|
203
217
|
/** Leader/follower network configuration. A follower needs no code config to
|
|
204
218
|
* receive pushed records. It must explicitly declare `readers` before any peer
|
|
@@ -241,12 +255,16 @@ interface ResolvedNetworkTarget {
|
|
|
241
255
|
secretName: string;
|
|
242
256
|
fields?: Record<string, readonly string[]>;
|
|
243
257
|
sharedNotes: readonly string[];
|
|
258
|
+
editableFields: Record<string, readonly string[]>;
|
|
259
|
+
stageTransitions: readonly string[];
|
|
244
260
|
}
|
|
245
261
|
/** A validated follower-owned record projection for one signed reader. */
|
|
246
262
|
interface ResolvedNetworkReader {
|
|
247
263
|
id: string;
|
|
248
264
|
fields: Record<string, readonly string[]>;
|
|
249
265
|
sharedNotes: readonly string[];
|
|
266
|
+
editableFields: Record<string, readonly string[]>;
|
|
267
|
+
stageTransitions: readonly string[];
|
|
250
268
|
}
|
|
251
269
|
/** Fully-resolved leader network configuration. */
|
|
252
270
|
interface ResolvedNetwork {
|
package/dist/worker/index.d.ts
CHANGED
|
@@ -44,7 +44,7 @@ interface ChapterCopy {
|
|
|
44
44
|
payment: TextFields<"setupFailed" | "preparing" | "pending" | "processing" | "payAndContinue" | "incomplete" | "consent">;
|
|
45
45
|
done: TextFields<"label" | "calendarInvite" | "memberArea">;
|
|
46
46
|
accepted: TextFields<"label" | "body">;
|
|
47
|
-
gift: TextFields<"chooseSelf" | "optionsLabel" | "label" | "body" | "save" | "rotate" | "rotateFailed">;
|
|
47
|
+
gift: TextFields<"chooseSelf" | "optionsLabel" | "label" | "body" | "save" | "rotate" | "rotateFailed" | "claimTitle" | "claimBody" | "code" | "redeem" | "redeemed" | "redeemFailed">;
|
|
48
48
|
};
|
|
49
49
|
members: {
|
|
50
50
|
loadFailed: string;
|
|
@@ -185,6 +185,13 @@ interface ChapterNetworkTarget {
|
|
|
185
185
|
* this follower. Omitted by default: a target never gains write permission
|
|
186
186
|
* merely because its records are browsable. */
|
|
187
187
|
sharedNotes?: readonly string[];
|
|
188
|
+
/** Per-record-type upper bound on profile fields this leader permits its
|
|
189
|
+
* admins to edit remotely. The follower must independently delegate the
|
|
190
|
+
* same field; readable fields never become writable implicitly. */
|
|
191
|
+
editableFields?: Record<string, readonly string[]>;
|
|
192
|
+
/** Record types on which this leader permits remote lifecycle transitions.
|
|
193
|
+
* The follower must independently opt in and remains pipeline authority. */
|
|
194
|
+
stageTransitions?: readonly string[];
|
|
188
195
|
}
|
|
189
196
|
/** One signed peer allowed to browse a privacy-bounded projection of this
|
|
190
197
|
* site's CRM. The follower owns this allowlist; a leader target declaration
|
|
@@ -199,6 +206,13 @@ interface ChapterNetworkReader {
|
|
|
199
206
|
* Omitted by default: browse permission never silently grants write access.
|
|
200
207
|
* Shared notes land in the follower CRM activity feed. */
|
|
201
208
|
sharedNotes?: readonly string[];
|
|
209
|
+
/** Exact local CRM fields this reader may edit remotely, by record type.
|
|
210
|
+
* Every field must also be readable so the peer can perform an optimistic
|
|
211
|
+
* edit against the value and revision it actually reviewed. */
|
|
212
|
+
editableFields?: Record<string, readonly string[]>;
|
|
213
|
+
/** Local CRM record types on which this reader may request a lifecycle
|
|
214
|
+
* transition. Chapter still enforces the local pipeline and gates. */
|
|
215
|
+
stageTransitions?: readonly string[];
|
|
202
216
|
}
|
|
203
217
|
/** Leader/follower network configuration. A follower needs no code config to
|
|
204
218
|
* receive pushed records. It must explicitly declare `readers` before any peer
|
|
@@ -241,12 +255,16 @@ interface ResolvedNetworkTarget {
|
|
|
241
255
|
secretName: string;
|
|
242
256
|
fields?: Record<string, readonly string[]>;
|
|
243
257
|
sharedNotes: readonly string[];
|
|
258
|
+
editableFields: Record<string, readonly string[]>;
|
|
259
|
+
stageTransitions: readonly string[];
|
|
244
260
|
}
|
|
245
261
|
/** A validated follower-owned record projection for one signed reader. */
|
|
246
262
|
interface ResolvedNetworkReader {
|
|
247
263
|
id: string;
|
|
248
264
|
fields: Record<string, readonly string[]>;
|
|
249
265
|
sharedNotes: readonly string[];
|
|
266
|
+
editableFields: Record<string, readonly string[]>;
|
|
267
|
+
stageTransitions: readonly string[];
|
|
250
268
|
}
|
|
251
269
|
/** Fully-resolved leader network configuration. */
|
|
252
270
|
interface ResolvedNetwork {
|