@company-semantics/contracts 2.3.1 → 2.4.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/package.json +1 -1
- package/src/content/schemas.ts +8 -1
- package/src/org/sharing.ts +12 -1
package/package.json
CHANGED
package/src/content/schemas.ts
CHANGED
|
@@ -99,7 +99,14 @@ const AclEntrySchema = z.object({
|
|
|
99
99
|
});
|
|
100
100
|
|
|
101
101
|
const AccessReasonSchema = z.object({
|
|
102
|
-
source: z.enum([
|
|
102
|
+
source: z.enum([
|
|
103
|
+
'org_rbac',
|
|
104
|
+
'sharing_policy',
|
|
105
|
+
'unit_baseline',
|
|
106
|
+
'unit_delegation',
|
|
107
|
+
'acl_grant',
|
|
108
|
+
'doc_ownership',
|
|
109
|
+
]),
|
|
103
110
|
detail: z.string(),
|
|
104
111
|
});
|
|
105
112
|
|
package/src/org/sharing.ts
CHANGED
|
@@ -25,8 +25,19 @@ export interface AclEntry {
|
|
|
25
25
|
/**
|
|
26
26
|
* Source of an access grant.
|
|
27
27
|
* Used in EffectiveAccess.reasons and EvaluationStep.source.
|
|
28
|
+
*
|
|
29
|
+
* `unit_delegation` covers leadership/delegation grants on the doc's owning
|
|
30
|
+
* unit via the authority projection (ADR-BE-169). Distinct from
|
|
31
|
+
* `unit_baseline` (which is membership-role-based) — delegations live on the
|
|
32
|
+
* `org_unit_authority_grants` table and carry an explicit scope set.
|
|
28
33
|
*/
|
|
29
|
-
export type AccessSource =
|
|
34
|
+
export type AccessSource =
|
|
35
|
+
| 'org_rbac'
|
|
36
|
+
| 'sharing_policy'
|
|
37
|
+
| 'unit_baseline'
|
|
38
|
+
| 'unit_delegation'
|
|
39
|
+
| 'acl_grant'
|
|
40
|
+
| 'doc_ownership';
|
|
30
41
|
|
|
31
42
|
export interface AccessReason {
|
|
32
43
|
readonly source: AccessSource;
|