@odla-ai/chapter 0.40.2 → 0.41.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 CHANGED
@@ -116,7 +116,7 @@ Chapter-owned application, admin, CRM, payment, and scheduling behavior.
116
116
  boundary so you never pay for what you don't use:
117
117
  - `@odla-ai/chapter/ui/member` — **Preact-only**: `SlotPicker`, the date/timezone
118
118
  helpers, `JoinIsland` (form → payment → booking), `MembersArea`,
119
- `Rescheduler`, `PaymentStep`, `<BrandStyle>`. It never imports
119
+ `GiftCodeRedeemer`, `Rescheduler`, `PaymentStep`, `<BrandStyle>`. It never imports
120
120
  `@odla-ai/auth-clerk` or `@odla-ai/crm`, so you can adopt a single
121
121
  presentational component without the Clerk browser SDK. (A bundle-graph test
122
122
  enforces this.)
@@ -546,9 +546,11 @@ builderLibrary: {
546
546
 
547
547
  Every resource has exactly one scope: `{ kind: "chapter", chapterId }`,
548
548
  `{ kind: "built_not_found" }`, or `{ kind: "global" }`. There are no groups or
549
- audience arrays. A Chapter can author only its own scope. Its admins and agents
550
- see its own published material plus global material, never a sibling Chapter or
551
- Built Not Found-only material. Built Not Found admins see every configured
549
+ audience arrays. A Chapter can author only its own scope. Built Not Found can
550
+ author material for itself, every Chapter, or exactly one Chapter from its
551
+ configured source list. A Chapter's admins and agents see its own published
552
+ material plus global material, never a sibling Chapter or Built Not Found-only
553
+ material. Built Not Found admins see every configured
552
554
  Chapter source and can promote a Chapter resource to a global copy; the server
553
555
  records the source Chapter, source resource/document revisions, actor, and time.
554
556
 
@@ -556,7 +558,10 @@ Resources are bounded documents/notes, HTTPS links/inspiration, or canonical
556
558
  Brand `{ bookId, assetId }` references. Asset URLs, bytes, storage credentials,
557
559
  HTML, and executable content are not part of the contract. The standard admin
558
560
  adds a visibly private **Builder Library** tab separate from **Member content**.
559
- Saving a library item never creates or changes a member page.
561
+ It is a compact CMS inventory with search and type/status filters, type-specific
562
+ add/edit fields, previews, explicit Draft/Published/Archived state, and a
563
+ visibility picker whose Chapter choices come only from checked-in network
564
+ configuration. Saving a library item never creates or changes a member page.
560
565
 
561
566
  An authenticated admin or site-building agent reads the bounded, published-only
562
567
  manifest from `/api/admin/builder-library/manifest`. On Built Not Found, pass a
@@ -738,6 +743,15 @@ The host still decides which routes use managed theming and owns any legacy
738
743
  token aliases. Keep the marker after bootstrap declarations so the active
739
744
  `--ui-*` values win in the initial parsed document.
740
745
 
746
+ `GiftCodeRedeemer` is the reusable member-side gift redemption control. It
747
+ accepts the resolved `chapter.copy.member.gifts` copy contract, posts trimmed
748
+ codes to `/api/gifts/redeem`, and keeps its input, action, loading lock, and
749
+ reserved live status region aligned with the shared `@odla-ai/ui`
750
+ inline-action-field contract. `MemberGifts` composes it automatically, while a
751
+ custom member surface can import it directly from `@odla-ai/chapter/ui/member`.
752
+ Code entry uses one-time-code autocomplete, disables automatic capitalization
753
+ and correction, and retains the submitted code after an error.
754
+
741
755
  The hub owns a durable outbox: create/verify immutable Stripe Prices first,
742
756
  persist the desired revision, retry signed delivery, and mark it active only
743
757
  after the exact revision/digest receipt. Version history is for audit and