@farthershore/farthershore-js 0.33.0 → 0.35.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.
Files changed (162) hide show
  1. package/CHANGELOG.md +122 -1
  2. package/README.md +19 -2
  3. package/dist/components/access-control.d.ts +15 -10
  4. package/dist/components/access-control.d.ts.map +1 -1
  5. package/dist/components/access-control.js +194 -95
  6. package/dist/components/access-control.js.map +1 -1
  7. package/dist/components/api-keys-manager.d.ts.map +1 -1
  8. package/dist/components/api-keys-manager.js +4 -20
  9. package/dist/components/api-keys-manager.js.map +1 -1
  10. package/dist/components/app.d.ts.map +1 -1
  11. package/dist/components/app.js +2 -1
  12. package/dist/components/app.js.map +1 -1
  13. package/dist/components/audit-log-table.d.ts.map +1 -1
  14. package/dist/components/audit-log-table.js +40 -5
  15. package/dist/components/audit-log-table.js.map +1 -1
  16. package/dist/components/billing.d.ts.map +1 -1
  17. package/dist/components/billing.js +5 -4
  18. package/dist/components/billing.js.map +1 -1
  19. package/dist/components/cancel-subscription.d.ts.map +1 -1
  20. package/dist/components/cancel-subscription.js +2 -18
  21. package/dist/components/cancel-subscription.js.map +1 -1
  22. package/dist/components/component-access-panel.d.ts.map +1 -1
  23. package/dist/components/component-access-panel.js +2 -7
  24. package/dist/components/component-access-panel.js.map +1 -1
  25. package/dist/components/keys.d.ts.map +1 -1
  26. package/dist/components/keys.js +11 -10
  27. package/dist/components/keys.js.map +1 -1
  28. package/dist/components/legal-document.d.ts.map +1 -1
  29. package/dist/components/legal-document.js +2 -1
  30. package/dist/components/legal-document.js.map +1 -1
  31. package/dist/components/notification-preferences.d.ts.map +1 -1
  32. package/dist/components/notification-preferences.js +3 -19
  33. package/dist/components/notification-preferences.js.map +1 -1
  34. package/dist/components/onboarding-plan-rail.d.ts.map +1 -1
  35. package/dist/components/onboarding-plan-rail.js +2 -18
  36. package/dist/components/onboarding-plan-rail.js.map +1 -1
  37. package/dist/components/onboarding-view.d.ts.map +1 -1
  38. package/dist/components/onboarding-view.js +3 -3
  39. package/dist/components/onboarding-view.js.map +1 -1
  40. package/dist/components/payment-required-gate.d.ts.map +1 -1
  41. package/dist/components/payment-required-gate.js +2 -1
  42. package/dist/components/payment-required-gate.js.map +1 -1
  43. package/dist/components/plans-table.d.ts.map +1 -1
  44. package/dist/components/plans-table.js +2 -1
  45. package/dist/components/plans-table.js.map +1 -1
  46. package/dist/components/product-docs/markdown.d.ts.map +1 -1
  47. package/dist/components/product-docs/markdown.js +2 -1
  48. package/dist/components/product-docs/markdown.js.map +1 -1
  49. package/dist/components/resource-limit-usage-card.d.ts.map +1 -1
  50. package/dist/components/resource-limit-usage-card.js +2 -1
  51. package/dist/components/resource-limit-usage-card.js.map +1 -1
  52. package/dist/components/resources-panel.d.ts.map +1 -1
  53. package/dist/components/resources-panel.js +4 -4
  54. package/dist/components/resources-panel.js.map +1 -1
  55. package/dist/components/root.d.ts.map +1 -1
  56. package/dist/components/root.js +4 -2
  57. package/dist/components/root.js.map +1 -1
  58. package/dist/components/route-panel.d.ts.map +1 -1
  59. package/dist/components/route-panel.js +4 -1
  60. package/dist/components/route-panel.js.map +1 -1
  61. package/dist/components/spend-cap-control.d.ts.map +1 -1
  62. package/dist/components/spend-cap-control.js +2 -1
  63. package/dist/components/spend-cap-control.js.map +1 -1
  64. package/dist/components/subscriber-status.d.ts.map +1 -1
  65. package/dist/components/subscriber-status.js +2 -1
  66. package/dist/components/subscriber-status.js.map +1 -1
  67. package/dist/components/team-members-panel.d.ts +12 -0
  68. package/dist/components/team-members-panel.d.ts.map +1 -0
  69. package/dist/components/team-members-panel.js +324 -0
  70. package/dist/components/team-members-panel.js.map +1 -0
  71. package/dist/components/team-panel.d.ts.map +1 -1
  72. package/dist/components/team-panel.js +61 -14
  73. package/dist/components/team-panel.js.map +1 -1
  74. package/dist/components/team-role-intent.d.ts +26 -0
  75. package/dist/components/team-role-intent.d.ts.map +1 -0
  76. package/dist/components/team-role-intent.js +45 -0
  77. package/dist/components/team-role-intent.js.map +1 -0
  78. package/dist/components/team-roles-panel.d.ts +8 -0
  79. package/dist/components/team-roles-panel.d.ts.map +1 -0
  80. package/dist/components/team-roles-panel.js +306 -0
  81. package/dist/components/team-roles-panel.js.map +1 -0
  82. package/dist/components/team-shared.d.ts +159 -0
  83. package/dist/components/team-shared.d.ts.map +1 -0
  84. package/dist/components/team-shared.js +367 -0
  85. package/dist/components/team-shared.js.map +1 -0
  86. package/dist/components/team.d.ts +36 -29
  87. package/dist/components/team.d.ts.map +1 -1
  88. package/dist/components/team.js +69 -52
  89. package/dist/components/team.js.map +1 -1
  90. package/dist/components/usage-limits.d.ts.map +1 -1
  91. package/dist/components/usage-limits.js +4 -7
  92. package/dist/components/usage-limits.js.map +1 -1
  93. package/dist/components/usage.d.ts.map +1 -1
  94. package/dist/components/usage.js +2 -1
  95. package/dist/components/usage.js.map +1 -1
  96. package/dist/config.d.ts.map +1 -1
  97. package/dist/config.js +4 -1
  98. package/dist/config.js.map +1 -1
  99. package/dist/errors/index.d.ts +30 -2
  100. package/dist/errors/index.d.ts.map +1 -1
  101. package/dist/errors/index.js +51 -2
  102. package/dist/errors/index.js.map +1 -1
  103. package/dist/errors/public-copy.d.ts +14 -0
  104. package/dist/errors/public-copy.d.ts.map +1 -0
  105. package/dist/errors/public-copy.js +24 -0
  106. package/dist/errors/public-copy.js.map +1 -0
  107. package/dist/fetch.d.ts.map +1 -1
  108. package/dist/fetch.js +2 -1
  109. package/dist/fetch.js.map +1 -1
  110. package/dist/generated/version.d.ts +2 -2
  111. package/dist/generated/version.js +2 -2
  112. package/dist/http.d.ts +0 -2
  113. package/dist/http.d.ts.map +1 -1
  114. package/dist/http.js +9 -8
  115. package/dist/http.js.map +1 -1
  116. package/dist/index.d.ts +5 -2
  117. package/dist/index.d.ts.map +1 -1
  118. package/dist/index.js +3 -0
  119. package/dist/index.js.map +1 -1
  120. package/dist/mock/fixtures.d.ts +29 -1
  121. package/dist/mock/fixtures.d.ts.map +1 -1
  122. package/dist/mock/fixtures.js +157 -39
  123. package/dist/mock/fixtures.js.map +1 -1
  124. package/dist/mock/team-roles.d.ts +46 -0
  125. package/dist/mock/team-roles.d.ts.map +1 -0
  126. package/dist/mock/team-roles.js +619 -0
  127. package/dist/mock/team-roles.js.map +1 -0
  128. package/dist/mock/transport.d.ts.map +1 -1
  129. package/dist/mock/transport.js +26 -24
  130. package/dist/mock/transport.js.map +1 -1
  131. package/dist/react/hooks.d.ts +2 -3
  132. package/dist/react/hooks.d.ts.map +1 -1
  133. package/dist/react/hooks.js +0 -5
  134. package/dist/react/hooks.js.map +1 -1
  135. package/dist/react/index.d.ts +2 -0
  136. package/dist/react/index.d.ts.map +1 -1
  137. package/dist/resources/account.d.ts +43 -7
  138. package/dist/resources/account.d.ts.map +1 -1
  139. package/dist/resources/account.js +9 -10
  140. package/dist/resources/account.js.map +1 -1
  141. package/dist/resources/keys.d.ts +8 -7
  142. package/dist/resources/keys.d.ts.map +1 -1
  143. package/dist/resources/keys.js +2 -4
  144. package/dist/resources/keys.js.map +1 -1
  145. package/dist/resources/team-roles.d.ts +11 -0
  146. package/dist/resources/team-roles.d.ts.map +1 -0
  147. package/dist/resources/team-roles.js +169 -0
  148. package/dist/resources/team-roles.js.map +1 -0
  149. package/dist/team-role-keys.d.ts +14 -0
  150. package/dist/team-role-keys.d.ts.map +1 -0
  151. package/dist/team-role-keys.js +46 -0
  152. package/dist/team-role-keys.js.map +1 -0
  153. package/dist/test-utils/index.d.ts +3 -1
  154. package/dist/test-utils/index.d.ts.map +1 -1
  155. package/dist/test-utils/index.js.map +1 -1
  156. package/dist/test-utils/mock-client.d.ts +9 -2
  157. package/dist/test-utils/mock-client.d.ts.map +1 -1
  158. package/dist/test-utils/mock-client.js +41 -25
  159. package/dist/test-utils/mock-client.js.map +1 -1
  160. package/dist/types.d.ts +118 -4
  161. package/dist/types.d.ts.map +1 -1
  162. package/package.json +3 -3
package/CHANGELOG.md CHANGED
@@ -3,7 +3,128 @@
3
3
  All notable changes to `@farthershore/farthershore-js` are documented here.
4
4
  This project adheres to Semantic Versioning (pre-1.0: minors may break).
5
5
 
6
- ## [Unreleased]
6
+ ## [0.35.0] - 2026-10-07
7
+
8
+ ### Added
9
+
10
+ - `toPublicMessage(err, fallback?)`, from the package root and `/errors`:
11
+ the text to show a visitor for a caught error. A `4xx` that carried a
12
+ message reads as itself, a `401` asks the visitor to sign in again, and a
13
+ network failure, any `5xx` or an error the SDK did not mint becomes neutral
14
+ copy. Use it in custom UI over the hooks' `error`.
15
+ - `FartherShoreConfigError` takes an optional `cause`.
16
+ - `fs.team.roles` (`TeamRolesResource`): the team roles each member holds —
17
+ what they can do in the account (billing, API keys, invites, team
18
+ settings). `list()` (`GET /me/team-roles`: the permission catalog, every
19
+ role with its member count and, for Admin / Member, the platform defaults,
20
+ and its governed permission `version`, plus `caller` — what the signed-in member may grant and whether they hold
21
+ owner authority; `caller.independentOwner` distinguishes organization ownership
22
+ that survives changing the caller's subscriber seat), `create()`, `update()`, `remove()` (its members move to
23
+ Member) and `assign()` (`PATCH /me/team/:id { teamRole }`). Types:
24
+ `TeamRoleKind`, `TeamRoleDefinition`, `TeamPermissionGroup`, `TeamRoles`,
25
+ `TeamRoleCaller`, `CreateTeamRoleInput`, `UpdateTeamRoleInput`,
26
+ `TeamRoleDeleted`. `TeamMember`, `TeamInvitation` and
27
+ `TeamInvitationAccepted` gain `teamRole` (`owner` / `admin` / `member` / a
28
+ custom key), and `team.invites.create()` accepts `teamRole`.
29
+ `TeamMemberRoleUpdated` and `TeamMemberProductRolesUpdated` describe the
30
+ exact member PATCH projections; refetch `team.list()` for the full row.
31
+ `update()` and `remove()` require the opaque `expectedRevision` captured when
32
+ editing. Revisions bind to the role instance and advance on every write,
33
+ including renames; deleting and recreating a key cannot reuse a draft. Stale writes
34
+ return `ROLE_VERSION_CONFLICT` (409). The editor keeps its opening baseline,
35
+ sends only edited fields, and closes stale actions so retrying requires reopening.
36
+ Edit, rename, permission, restore-defaults and delete actions capture an immutable
37
+ opening snapshot. Background refreshes show a change notice without retargeting
38
+ the action; a removed role closes its action with an explanatory sentence. Product-role
39
+ definition and assignment writes refresh caller authority. Product settings writes
40
+ preserve an unrelated open team-role action. Request-access and approval controls
41
+ obey inherited read-only gates.
42
+ The key helpers `deriveTeamRoleKey`, `customTeamRoleKeyProblem`,
43
+ `TEAM_ROLE_KEY_PATTERN`, `RESERVED_TEAM_ROLE_KEYS` and
44
+ `MAX_CUSTOM_TEAM_ROLES` are public and pinned to the platform rules.
45
+ The mock transport implements role CRUD, caller authority, assignments,
46
+ invitations and typed failures; `createMockFartherShoreClient` accepts
47
+ a team seed for the same behaviour (`MockFartherShoreClientOptions`,
48
+ `MockTeamOptions`). Organization owners can be seeded separately with
49
+ `organizationOwnerUserIds`. Caller seeds contain identity only; team actions,
50
+ owner tier and grant ceilings derive from current membership, team roles,
51
+ direct grants and assigned product roles on every request. `rbacSettings` seeds
52
+ the enabled default product role for members without an explicit assignment;
53
+ settings reads and writes share that authority state. The same resolver
54
+ checks deferred invitations. The old caller authority and `permissions` seed
55
+ fields have been removed; seed role/member grants instead.
56
+ - Team-role caller metadata separates `actions` (what the caller may do) from
57
+ `grantable` (the permission ceiling). Direct action grants expose authorized
58
+ controls without widening role options or editable permissions.
59
+ - The access-request inbox uses `team:manage_rbac` independently of invitations.
60
+ Role writes preserve invitation drafts, manual acceptance links and pending
61
+ sends within the current team. Inherited read-only gates suppress team writes.
62
+
63
+ ### Removed
64
+
65
+ - **Breaking (pre-1.0 minor):** `team.updateRole(membershipId, role)` and
66
+ `useTeam().updateRole` are removed, as is the legacy `{ role }` input to
67
+ `team.invites.create`. Use `team.roles.assign(membershipId, teamRole)`
68
+ and `team.invites.create({ email, teamRole })`; the built-in keys are
69
+ `owner`, `admin` and `member` (formerly `OWNER`, `ADMIN`, `VIEWER`).
70
+ Call `useTeam().refetch()` after a direct assignment when using the hook.
71
+ Member and invitation `role` remains a read-only stored tier; every row's
72
+ `teamRole` is the authoritative team role.
73
+
74
+ ### Changed
75
+
76
+ - `<FsTeam/>` is the redesigned Team page: **Members** (an invite bar with
77
+ inline validation over one table of members and pending invites — inline
78
+ team-role select, product-role chips, last-owner protection, two-step
79
+ Remove / Revoke) and **Roles & permissions** (a card per team role with a
80
+ coverage bar, per-resource chips and member count; an inline grouped
81
+ permission editor with changed-dots, Select all / Clear all, Restore
82
+ defaults for Admin / Member and an unsaved-change count; "+ New role" with
83
+ the platform's key preview; delete; then the product-role block), plus the
84
+ access-request inbox, the request-access form and component access.
85
+ Permissions the viewer can't grant are locked ("You can only grant
86
+ permissions you have"); a viewer with `team:read` but not
87
+ `team:manage_rbac` sees the roles read-only. Role-write failures map to one
88
+ clear sentence per platform error code. `FsTeam` now includes the invite
89
+ flow; `FsTeamMembersSection` gains `onMembersChanged` and
90
+ `FsTeamRolesSection` gains `refreshSignal` (member counts stay current).
91
+ Standalone `TeamPanel`, `FsMemberRoles` and `FsInviteMembers` also use
92
+ `teamRole` and live caller authority, and keep their existing layouts.
93
+
94
+ - Portal visitors no longer see platform plumbing. A request that never
95
+ reaches the platform now throws `FartherShoreNetworkError` with "We
96
+ couldn't connect. Check your internet connection and try again." instead of
97
+ `Core request failed: <transport error>` and its Gateway and `fs.fetch`
98
+ variants; the transport error stays on `cause`. A managed portal without its platform route throws
99
+ `FartherShoreConfigError` with "This portal is temporarily unavailable.
100
+ Please try again later." and keeps the diagnostic on `cause`. Code that
101
+ matched the old message text must use `instanceof` instead.
102
+ - Every managed component renders failures through `toPublicMessage`: no
103
+ `5xx` message, payment-provider error text (such as "No such customer" on
104
+ Add funds) or render-crash message reaches the page — including a crash
105
+ inside a product docs page, which `SafeDocsMarkdown` catches itself. Each
106
+ says what failed and that the visitor can try again.
107
+ - `<AuditLogTable>` labels actors in product terms, in the table and the CSV,
108
+ and keeps credentials distinguishable without database ids: the person's
109
+ name; an API key as `API key "<name>" (<keyPrefix>…)`; a maker token as
110
+ `Maker token ••••<last4>`; else a teammate's user id, "Business team" for
111
+ the business's own people, and "Automated platform action" for platform
112
+ services — never a raw `actorType:actorUserId` such as `gateway:gw-node-7`.
113
+ `AuditLogEntry.actorCredential` (new type `AuditLogActorCredential`) carries
114
+ the handle Core resolves.
115
+
116
+ ## [0.34.0] - 2026-10-03
117
+
118
+ ### Removed
119
+
120
+ - **Breaking:** the Idempotency-Key request mechanism is gone from the
121
+ platform, so the SDK no longer sends an `idempotency-key` header.
122
+ `CoreRequest.idempotencyKey` is removed, and so is the trailing
123
+ `options: ServiceAccountMutationOptions` argument of
124
+ `serviceAccounts.create()` / `serviceAccounts.update()`. Drop that argument. Repeating
125
+ the same `create` lands on the pending approval it already opened, or
126
+ resumes a still-pending activation of that name. It never mints a second
127
+ credential.
7
128
 
8
129
  ## [0.33.0] - 2026-10-03
9
130
 
package/README.md CHANGED
@@ -3,7 +3,7 @@
3
3
  The **Farther Shore Frontend SDK** — the browser + React integration layer for
4
4
  your product's subscriber portal.
5
5
 
6
- > **Status: `0.33.0` (pre-1.0).** Pin the version you build against and read
6
+ > **Status: `0.35.0` (pre-1.0).** Pin the version you build against and read
7
7
  > [`CHANGELOG.md`](./CHANGELOG.md) before upgrading.
8
8
 
9
9
  ```bash
@@ -61,12 +61,14 @@ ecosystem shape — `{ data, error, isLoading, isError, isSuccess, refetch,
61
61
  queryKey }` — plus its mutations:
62
62
 
63
63
  ```tsx
64
+ import { toPublicMessage } from "@farthershore/farthershore-js";
64
65
  import { useApiKeys } from "@farthershore/farthershore-js/react";
65
66
 
66
67
  function ApiKeys() {
67
68
  const { data, isLoading, isError, error, refetch } = useApiKeys();
68
69
  if (isLoading) return <p>Loading…</p>;
69
- if (isError) return <p>Failed to load keys: {error?.message}</p>;
70
+ if (isError)
71
+ return <p>{toPublicMessage(error, "We couldn't load your keys.")}</p>;
70
72
  return (
71
73
  <ul>
72
74
  {data?.map((k) => (
@@ -370,6 +372,13 @@ The full taxonomy — throttle subclasses (`ConcurrencyLimitError`,
370
372
  `AdaptiveThrottleError`), deny-envelope parsers, `makeApiError`, secure-fetch
371
373
  codes, and more — lives at the `@farthershore/farthershore-js/errors` subpath.
372
374
 
375
+ To show an error to a visitor, render `toPublicMessage(err, fallback)` rather
376
+ than `err.message`. A `4xx` that carried a message (a validation refusal, a
377
+ missing permission) reads as itself and a `401` asks the visitor to sign in
378
+ again; a network failure, any `5xx` or an unrecognized error becomes neutral
379
+ copy, so platform and provider detail never reaches the page. The managed
380
+ components all render failures this way.
381
+
373
382
  ## Display helpers
374
383
 
375
384
  Pure catalog display helpers (declared plan kind, recurring price, quotas,
@@ -422,3 +431,11 @@ Core or the Gateway.
422
431
  See the platform docs for the full guide to building, publishing, and operating a
423
432
  product on Farther Shore. Breaking changes within `0.x` are recorded in
424
433
  [`CHANGELOG.md`](./CHANGELOG.md) — read it before bumping.
434
+
435
+ Team roles use one write surface: `fs.team.roles.assign(membershipId, teamRole)`
436
+ assigns `owner`, `admin`, `member` or a custom key. Invite with
437
+ `fs.team.invites.create({ email, teamRole })`; omit `teamRole` to invite a
438
+ Member. The legacy `{ role }` invite input and `team.updateRole` were removed
439
+ in 0.35.0. `role` on returned rows is the stored tier, while `teamRole` is
440
+ the member's actual role. Assignment returns `TeamMemberRoleUpdated`; refetch
441
+ `team.list()` for the full roster row.
@@ -2,6 +2,10 @@
2
2
  * (apps/core/src/routes/portal-customer/rbac.ts → `requirePermission(…,
3
3
  * "team:manage_rbac")`). Used as the default editor gate. */
4
4
  export declare const MANAGE_RBAC_PERMISSION = "team:manage_rbac";
5
+ /** Read the signed-in member's external id from `GET /me` — the value the
6
+ * roster matches against `member.userExternalId` to find "self" (mirrors the
7
+ * template's readUserId). */
8
+ export declare function readUserExternalId(subscriber: unknown): string | null;
5
9
  export interface FsRoleEditorProps {
6
10
  /** Appended to the root card. */
7
11
  className?: string;
@@ -21,14 +25,14 @@ export interface FsRoleEditorProps {
21
25
  * settings/catalog/roles under <FartherShoreRoot>; renders nothing when the
22
26
  * product doesn't enable RBAC or the caller can't read the config.
23
27
  */
24
- export declare function FsRoleEditor({ className, canManage, onRolesChanged, }?: FsRoleEditorProps): import("react").JSX.Element | null;
28
+ export declare function FsRoleEditor(props?: FsRoleEditorProps): import("react").JSX.Element;
25
29
  export interface FsMemberRolesProps {
26
30
  /** Appended to the root card. */
27
31
  className?: string;
28
32
  /** Whether the viewer may change roles/assignments. Defaults to the viewer's
29
33
  * team role (OWNER/ADMIN) resolved from the team read. */
30
34
  canManage?: boolean;
31
- /** Whether the viewer may remove members. Defaults to OWNER only. */
35
+ /** Whether the viewer may remove members. Defaults to the live caller's removal action. */
32
36
  canRemove?: boolean;
33
37
  /** Heading text. Defaults to "Team members". */
34
38
  title?: string;
@@ -36,15 +40,16 @@ export interface FsMemberRolesProps {
36
40
  * after a role create/delete so the product-role columns pick up the
37
41
  * change). Ignored when unchanged / undefined. */
38
42
  refreshSignal?: number;
43
+ /** Notify composed sections after a successful product assignment. */
44
+ onMembersChanged?: () => void;
39
45
  }
40
46
  /**
41
- * The member roster with Managed-RBAC assignment: platform-role select
42
- * (OWNER/ADMIN/VIEWER), the org's product-role assignment checkboxes,
47
+ * The member roster with Managed-RBAC assignment: team-role select, the org's product-role assignment checkboxes,
43
48
  * stale-role warnings, and remove. Self-fetches the team roster + `GET /me`
44
49
  * (to find "self") under <FartherShoreRoot>. A failed team read degrades to a
45
50
  * read-only roster with the server's reason (team-panel precedent).
46
51
  */
47
- export declare function FsMemberRoles({ className, canManage, canRemove, title, refreshSignal, }?: FsMemberRolesProps): import("react").JSX.Element;
52
+ export declare function FsMemberRoles({ className, canManage, canRemove, title, refreshSignal, onMembersChanged, }?: FsMemberRolesProps): import("react").JSX.Element;
48
53
  export interface FsInviteMembersProps {
49
54
  /** Appended to the root card. */
50
55
  className?: string;
@@ -61,12 +66,12 @@ export interface FsInviteMembersProps {
61
66
  }
62
67
  /**
63
68
  * Track T2 — the subscriber-team invitation piece: a create form (email +
64
- * platform role + optional product-role grants) and the pending-invitation list
69
+ * team role + optional product-role grants) and the pending-invitation list
65
70
  * with revoke. Self-fetches `fs.team.invites.list()` under <FartherShoreRoot>.
66
71
  * Renders nothing for non-managers (canManage=false). The raw token from a
67
72
  * successful create is surfaced once (email is the primary delivery channel).
68
73
  */
69
- export declare function FsInviteMembers({ className, canManage, availableRoles, }?: FsInviteMembersProps): import("react").JSX.Element | null;
74
+ export declare function FsInviteMembers(props?: FsInviteMembersProps): import("react").JSX.Element;
70
75
  export interface FsAcceptInviteProps {
71
76
  /** Appended to the root card. */
72
77
  className?: string;
@@ -113,10 +118,10 @@ export interface FsAccessControlProps {
113
118
  className?: string;
114
119
  /** Whether the viewer may mutate settings/roles/assignments. When omitted the
115
120
  * role editor defaults to the `team:manage_rbac` claim and the roster to the
116
- * viewer's team role; pass an explicit value to gate both off one signal
117
- * (e.g. the template's OWNER/ADMIN derivation). */
121
+ * server-resolved team authority; pass an explicit value to gate both off one signal
122
+ * (e.g. the template's permission derivation). */
118
123
  canManage?: boolean;
119
- /** Whether the viewer may remove members. Defaults to OWNER only. */
124
+ /** Whether the viewer may remove members. Defaults to the live caller's removal action. */
120
125
  canRemove?: boolean;
121
126
  }
122
127
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"access-control.d.ts","sourceRoot":"","sources":["../../src/components/access-control.tsx"],"names":[],"mappings":"AA8CA;;8DAE8D;AAC9D,eAAO,MAAM,sBAAsB,qBAAqB,CAAC;AAyEzD,MAAM,WAAW,iBAAiB;IAChC,iCAAiC;IACjC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;6EAGyE;IACzE,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB;oDACgD;IAChD,cAAc,CAAC,EAAE,MAAM,IAAI,CAAC;CAC7B;AAED;;;;;;GAMG;AACH,wBAAgB,YAAY,CAAC,EAC3B,SAAS,EACT,SAAS,EACT,cAAc,GACf,GAAE,iBAAsB,sCAuexB;AAID,MAAM,WAAW,kBAAkB;IACjC,iCAAiC;IACjC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;+DAC2D;I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AM,CAAC;IACnB,kEAAkE;IAClE,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAED;;;;;GAKG;AACH,wBAAgB,qBAAqB,CAAC,EACpC,SAAS,EACT,SAAiB,GAClB,GAAE,0BAA+B,sCAoGjC;AAID,MAAM,WAAW,oBAAoB;IACnC,+BAA+B;IAC/B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;wDAGoD;IACpD,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,qEAAqE;IACrE,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAED;;;;;;;GAOG;AACH,wBAAgB,eAAe,CAAC,EAC9B,SAAS,EACT,SAAS,EACT,SAAS,GACV,GAAE,oBAAyB,+BAyC3B"}
1
+ {"version":3,"file":"access-control.d.ts","sourceRoot":"","sources":["../../src/components/access-control.tsx"],"names":[],"mappings":"AAoDA;;8DAE8D;AAC9D,eAAO,MAAM,sBAAsB,qBAAqB,CAAC;AAoBzD;;8BAE8B;AAC9B,wBAAgB,kBAAkB,CAAC,UAAU,EAAE,OAAO,GAAG,MAAM,GAAG,IAAI,CAMrE;AA+CD,MAAM,WAAW,iBAAiB;IAChC,iCAAiC;IACjC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;6EAGyE;IACzE,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB;oDACgD;IAChD,cAAc,CAAC,EAAE,MAAM,IAAI,CAAC;CAC7B;AAED;;;;;;GAMG;AACH,wBAAgB,YAAY,CAAC,KAAK,GAAE,iBAAsB,+BAQzD;AA8iBD,MAAM,WAAW,kBAAkB;IACjC,iCAAiC;IACjC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;+DAC2D;IAC3D,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,2FAA2F;IAC3F,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,gDAAgD;IAChD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;uDAEmD;IACnD,aAAa,CAAC,EAAE,MAAM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