@adminiumjs/manifest 0.3.27 → 0.3.29
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/dist/app-grants.d.ts +134 -0
- package/dist/app-grants.d.ts.map +1 -0
- package/dist/app-grants.js +263 -0
- package/dist/app-grants.js.map +1 -0
- package/dist/automations.d.ts +2255 -58
- package/dist/automations.d.ts.map +1 -1
- package/dist/automations.js +450 -25
- package/dist/automations.js.map +1 -1
- package/dist/compose.d.ts.map +1 -1
- package/dist/compose.js +3 -0
- package/dist/compose.js.map +1 -1
- package/dist/documents.d.ts +1 -0
- package/dist/documents.d.ts.map +1 -1
- package/dist/documents.js +2 -0
- package/dist/documents.js.map +1 -1
- package/dist/index.d.ts +11 -5
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +10 -4
- package/dist/index.js.map +1 -1
- package/dist/ledgers.d.ts.map +1 -1
- package/dist/ledgers.js +2 -0
- package/dist/ledgers.js.map +1 -1
- package/dist/modules.d.ts +93 -0
- package/dist/modules.d.ts.map +1 -0
- package/dist/modules.js +489 -0
- package/dist/modules.js.map +1 -0
- package/dist/occupies.d.ts +50 -0
- package/dist/occupies.d.ts.map +1 -0
- package/dist/occupies.js +123 -0
- package/dist/occupies.js.map +1 -0
- package/dist/outbox.d.ts +223 -17
- package/dist/outbox.d.ts.map +1 -1
- package/dist/outbox.js +125 -13
- package/dist/outbox.js.map +1 -1
- package/dist/page-board.d.ts +144 -0
- package/dist/page-board.d.ts.map +1 -0
- package/dist/page-board.js +280 -0
- package/dist/page-board.js.map +1 -0
- package/dist/plan-context.d.ts.map +1 -1
- package/dist/plan-context.js +3 -0
- package/dist/plan-context.js.map +1 -1
- package/dist/plan-model.d.ts +7 -0
- package/dist/plan-model.d.ts.map +1 -1
- package/dist/public-access.d.ts +6 -0
- package/dist/public-access.d.ts.map +1 -1
- package/dist/public-access.js +75 -1
- package/dist/public-access.js.map +1 -1
- package/dist/rail.d.ts +50 -0
- package/dist/rail.d.ts.map +1 -0
- package/dist/rail.js +122 -0
- package/dist/rail.js.map +1 -0
- package/dist/roles.d.ts +647 -1
- package/dist/roles.d.ts.map +1 -1
- package/dist/roles.js +459 -3
- package/dist/roles.js.map +1 -1
- package/dist/sample.d.ts +62 -0
- package/dist/sample.d.ts.map +1 -1
- package/dist/sample.js +203 -4
- package/dist/sample.js.map +1 -1
- package/dist/schema.d.ts +4349 -169
- package/dist/schema.d.ts.map +1 -1
- package/dist/schema.js +540 -41
- package/dist/schema.js.map +1 -1
- package/dist/shapes.d.ts +3 -2
- package/dist/shapes.d.ts.map +1 -1
- package/dist/shapes.js +76 -7
- package/dist/shapes.js.map +1 -1
- package/dist/state-actions.d.ts +4 -0
- package/dist/state-actions.d.ts.map +1 -1
- package/dist/state-actions.js +7 -0
- package/dist/state-actions.js.map +1 -1
- package/dist/states.d.ts +20 -1
- package/dist/states.d.ts.map +1 -1
- package/dist/states.js +47 -5
- package/dist/states.js.map +1 -1
- package/dist/validate.d.ts.map +1 -1
- package/dist/validate.js +110 -3
- package/dist/validate.js.map +1 -1
- package/dist/words.d.ts +1 -1
- package/dist/words.d.ts.map +1 -1
- package/dist/words.js +332 -1
- package/dist/words.js.map +1 -1
- package/package.json +2 -2
package/dist/roles.d.ts
CHANGED
|
@@ -36,9 +36,249 @@
|
|
|
36
36
|
*
|
|
37
37
|
* `writableValues` holds what a column is moved TO; this, what it is moved
|
|
38
38
|
* FROM. It is judged on the stored row, whatever columns the update changes.
|
|
39
|
+
*
|
|
40
|
+
* `rows` says which ROWS the role's read, update or delete reaches, when it
|
|
41
|
+
* does not reach every row. A rep reads the deals they own and a manager the
|
|
42
|
+
* deals of the teams they lead:
|
|
43
|
+
*
|
|
44
|
+
* ```json
|
|
45
|
+
* "rows": { "read": { "reach": "own" }, "update": { "reach": "own" } }
|
|
46
|
+
* ```
|
|
47
|
+
*
|
|
48
|
+
* A row is somebody's by what its table says of it (`belongs`, below): a
|
|
49
|
+
* column that holds a staff member, a table that lists people against the
|
|
50
|
+
* row, or the row it hangs off. `unowned` adds the rows that are nobody's
|
|
51
|
+
* yet, and `while` keeps only the rows whose column holds one of some values
|
|
52
|
+
* now. Roles add up here too: someone whose other role reads the table with
|
|
53
|
+
* no `rows` reads every row.
|
|
54
|
+
*
|
|
55
|
+
* An action may also name SEVERAL reaches, any one of which is enough: an
|
|
56
|
+
* account manager reads every won deal, and an open one only while he is
|
|
57
|
+
* listed on it —
|
|
58
|
+
*
|
|
59
|
+
* ```json
|
|
60
|
+
* "rows": { "read": [{ "reach": "all", "while": { "column": "state", "in": ["won"] } }, { "reach": "own" }] }
|
|
61
|
+
* ```
|
|
62
|
+
*
|
|
63
|
+
* Each reach is its own whole test (its `while` and its `by` hold for it
|
|
64
|
+
* alone), as two roles' reaches are.
|
|
39
65
|
*/
|
|
40
66
|
import { z } from 'zod';
|
|
41
67
|
import { type ColumnShape, type ReferenceIssue, type TableIndex } from './refs.js';
|
|
68
|
+
/** How far one action reaches: the person's own rows, their teams', or every row (only `while` some value). */
|
|
69
|
+
export declare const ROW_REACHES: readonly ["own", "team", "all"];
|
|
70
|
+
export declare const rowReachSchema: z.ZodObject<{
|
|
71
|
+
reach: z.ZodEnum<{
|
|
72
|
+
own: "own";
|
|
73
|
+
team: "team";
|
|
74
|
+
all: "all";
|
|
75
|
+
}>;
|
|
76
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
77
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
78
|
+
column: z.ZodString;
|
|
79
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
80
|
+
}, z.core.$strict>>;
|
|
81
|
+
by: z.ZodOptional<z.ZodString>;
|
|
82
|
+
}, z.core.$strict>;
|
|
83
|
+
export type RowReach = z.infer<typeof rowReachSchema>;
|
|
84
|
+
/** The actions a row limit narrows. A create makes a new row: it is held by the links and people it names. */
|
|
85
|
+
export declare const ROW_LIMIT_ACTIONS: readonly ["read", "update", "delete"];
|
|
86
|
+
/** The most reaches one action names. */
|
|
87
|
+
export declare const ROW_REACHES_MAX = 4;
|
|
88
|
+
/** One action's reach, or several of which any one is enough (every won deal, or an open one the person is listed on). */
|
|
89
|
+
export declare const rowReachesSchema: z.ZodUnion<readonly [z.ZodObject<{
|
|
90
|
+
reach: z.ZodEnum<{
|
|
91
|
+
own: "own";
|
|
92
|
+
team: "team";
|
|
93
|
+
all: "all";
|
|
94
|
+
}>;
|
|
95
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
96
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
97
|
+
column: z.ZodString;
|
|
98
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
99
|
+
}, z.core.$strict>>;
|
|
100
|
+
by: z.ZodOptional<z.ZodString>;
|
|
101
|
+
}, z.core.$strict>, z.ZodArray<z.ZodObject<{
|
|
102
|
+
reach: z.ZodEnum<{
|
|
103
|
+
own: "own";
|
|
104
|
+
team: "team";
|
|
105
|
+
all: "all";
|
|
106
|
+
}>;
|
|
107
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
108
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
109
|
+
column: z.ZodString;
|
|
110
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
111
|
+
}, z.core.$strict>>;
|
|
112
|
+
by: z.ZodOptional<z.ZodString>;
|
|
113
|
+
}, z.core.$strict>>]>;
|
|
114
|
+
export type RowReaches = z.infer<typeof rowReachesSchema>;
|
|
115
|
+
/** An action's reaches as a list, whether the manifest wrote one or several. */
|
|
116
|
+
export declare function reachList(reaches: RowReaches | undefined): readonly RowReach[];
|
|
117
|
+
/** Which rows a role's read, update and delete reach, each on its own. */
|
|
118
|
+
export declare const rowsLimitSchema: z.ZodObject<{
|
|
119
|
+
read: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
120
|
+
reach: z.ZodEnum<{
|
|
121
|
+
own: "own";
|
|
122
|
+
team: "team";
|
|
123
|
+
all: "all";
|
|
124
|
+
}>;
|
|
125
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
126
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
127
|
+
column: z.ZodString;
|
|
128
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
129
|
+
}, z.core.$strict>>;
|
|
130
|
+
by: z.ZodOptional<z.ZodString>;
|
|
131
|
+
}, z.core.$strict>, z.ZodArray<z.ZodObject<{
|
|
132
|
+
reach: z.ZodEnum<{
|
|
133
|
+
own: "own";
|
|
134
|
+
team: "team";
|
|
135
|
+
all: "all";
|
|
136
|
+
}>;
|
|
137
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
138
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
139
|
+
column: z.ZodString;
|
|
140
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
141
|
+
}, z.core.$strict>>;
|
|
142
|
+
by: z.ZodOptional<z.ZodString>;
|
|
143
|
+
}, z.core.$strict>>]>>;
|
|
144
|
+
update: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
145
|
+
reach: z.ZodEnum<{
|
|
146
|
+
own: "own";
|
|
147
|
+
team: "team";
|
|
148
|
+
all: "all";
|
|
149
|
+
}>;
|
|
150
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
151
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
152
|
+
column: z.ZodString;
|
|
153
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
154
|
+
}, z.core.$strict>>;
|
|
155
|
+
by: z.ZodOptional<z.ZodString>;
|
|
156
|
+
}, z.core.$strict>, z.ZodArray<z.ZodObject<{
|
|
157
|
+
reach: z.ZodEnum<{
|
|
158
|
+
own: "own";
|
|
159
|
+
team: "team";
|
|
160
|
+
all: "all";
|
|
161
|
+
}>;
|
|
162
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
163
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
164
|
+
column: z.ZodString;
|
|
165
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
166
|
+
}, z.core.$strict>>;
|
|
167
|
+
by: z.ZodOptional<z.ZodString>;
|
|
168
|
+
}, z.core.$strict>>]>>;
|
|
169
|
+
delete: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
170
|
+
reach: z.ZodEnum<{
|
|
171
|
+
own: "own";
|
|
172
|
+
team: "team";
|
|
173
|
+
all: "all";
|
|
174
|
+
}>;
|
|
175
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
176
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
177
|
+
column: z.ZodString;
|
|
178
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
179
|
+
}, z.core.$strict>>;
|
|
180
|
+
by: z.ZodOptional<z.ZodString>;
|
|
181
|
+
}, z.core.$strict>, z.ZodArray<z.ZodObject<{
|
|
182
|
+
reach: z.ZodEnum<{
|
|
183
|
+
own: "own";
|
|
184
|
+
team: "team";
|
|
185
|
+
all: "all";
|
|
186
|
+
}>;
|
|
187
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
188
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
189
|
+
column: z.ZodString;
|
|
190
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
191
|
+
}, z.core.$strict>>;
|
|
192
|
+
by: z.ZodOptional<z.ZodString>;
|
|
193
|
+
}, z.core.$strict>>]>>;
|
|
194
|
+
}, z.core.$strict>;
|
|
195
|
+
export type RowsLimit = z.infer<typeof rowsLimitSchema>;
|
|
196
|
+
/** Who a person who is limited to some rows may put in a staff column: themselves, someone they reach, or anyone. */
|
|
197
|
+
export declare const STAFF_SET_RULES: readonly ["self", "team", "anyone"];
|
|
198
|
+
/** What a listing row must hold to count: one of some values in a column, or a column empty (or not). */
|
|
199
|
+
export declare const listingWhileSchema: z.ZodUnion<readonly [z.ZodObject<{
|
|
200
|
+
column: z.ZodString;
|
|
201
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
202
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
203
|
+
column: z.ZodString;
|
|
204
|
+
isNull: z.ZodBoolean;
|
|
205
|
+
}, z.core.$strict>]>;
|
|
206
|
+
export type ListingWhile = z.infer<typeof listingWhileSchema>;
|
|
207
|
+
/**
|
|
208
|
+
* One way a person belongs to a row of the table:
|
|
209
|
+
*
|
|
210
|
+
* - `column`: the staff member this column holds; with `person`, the column
|
|
211
|
+
* is a link and `person` the staff column of the row it points at (a
|
|
212
|
+
* ticket's agent, whose own row holds the staff member);
|
|
213
|
+
* - `through`: a table that lists people against the row — its `link` holds
|
|
214
|
+
* this row's key (or this row's `on` column), its `user` the staff member
|
|
215
|
+
* (or, with `person`, a link to the row that holds one), `from` / `to`
|
|
216
|
+
* the days the listing counts on, both `date` columns (cover for a colleague on leave),
|
|
217
|
+
* and `while` a column of the listing it counts only while it holds one of
|
|
218
|
+
* some values, or while it is empty or not (`isNull`): a member row whose
|
|
219
|
+
* `ended_at` is set lists nobody;
|
|
220
|
+
* - `via`: whoever belongs to the row this link points at (a quote's deal).
|
|
221
|
+
*/
|
|
222
|
+
export declare const belongsWaySchema: z.ZodUnion<readonly [z.ZodObject<{
|
|
223
|
+
column: z.ZodString;
|
|
224
|
+
person: z.ZodOptional<z.ZodString>;
|
|
225
|
+
set: z.ZodOptional<z.ZodEnum<{
|
|
226
|
+
self: "self";
|
|
227
|
+
team: "team";
|
|
228
|
+
anyone: "anyone";
|
|
229
|
+
}>>;
|
|
230
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
231
|
+
through: z.ZodObject<{
|
|
232
|
+
table: z.ZodString;
|
|
233
|
+
link: z.ZodString;
|
|
234
|
+
on: z.ZodOptional<z.ZodString>;
|
|
235
|
+
user: z.ZodString;
|
|
236
|
+
person: z.ZodOptional<z.ZodString>;
|
|
237
|
+
from: z.ZodOptional<z.ZodString>;
|
|
238
|
+
to: z.ZodOptional<z.ZodString>;
|
|
239
|
+
while: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
240
|
+
column: z.ZodString;
|
|
241
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
242
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
243
|
+
column: z.ZodString;
|
|
244
|
+
isNull: z.ZodBoolean;
|
|
245
|
+
}, z.core.$strict>]>>;
|
|
246
|
+
}, z.core.$strict>;
|
|
247
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
248
|
+
via: z.ZodString;
|
|
249
|
+
}, z.core.$strict>]>;
|
|
250
|
+
export type BelongsWay = z.infer<typeof belongsWaySchema>;
|
|
251
|
+
/** The ways people belong to a table's rows: any one is enough. */
|
|
252
|
+
export declare const belongsSchema: z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
|
|
253
|
+
column: z.ZodString;
|
|
254
|
+
person: z.ZodOptional<z.ZodString>;
|
|
255
|
+
set: z.ZodOptional<z.ZodEnum<{
|
|
256
|
+
self: "self";
|
|
257
|
+
team: "team";
|
|
258
|
+
anyone: "anyone";
|
|
259
|
+
}>>;
|
|
260
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
261
|
+
through: z.ZodObject<{
|
|
262
|
+
table: z.ZodString;
|
|
263
|
+
link: z.ZodString;
|
|
264
|
+
on: z.ZodOptional<z.ZodString>;
|
|
265
|
+
user: z.ZodString;
|
|
266
|
+
person: z.ZodOptional<z.ZodString>;
|
|
267
|
+
from: z.ZodOptional<z.ZodString>;
|
|
268
|
+
to: z.ZodOptional<z.ZodString>;
|
|
269
|
+
while: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
270
|
+
column: z.ZodString;
|
|
271
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
272
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
273
|
+
column: z.ZodString;
|
|
274
|
+
isNull: z.ZodBoolean;
|
|
275
|
+
}, z.core.$strict>]>>;
|
|
276
|
+
}, z.core.$strict>;
|
|
277
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
278
|
+
via: z.ZodString;
|
|
279
|
+
}, z.core.$strict>]>>;
|
|
280
|
+
/** How many links a `via` may follow before it reaches a table people belong to directly. */
|
|
281
|
+
export declare const BELONGS_VIA_MAX_STEPS = 2;
|
|
42
282
|
/** One table's limit. */
|
|
43
283
|
export declare const roleLimitSchema: z.ZodObject<{
|
|
44
284
|
writable: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
@@ -47,6 +287,83 @@ export declare const roleLimitSchema: z.ZodObject<{
|
|
|
47
287
|
readable: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
48
288
|
creatable: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
49
289
|
creatableValues: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>>>;
|
|
290
|
+
rows: z.ZodOptional<z.ZodObject<{
|
|
291
|
+
read: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
292
|
+
reach: z.ZodEnum<{
|
|
293
|
+
own: "own";
|
|
294
|
+
team: "team";
|
|
295
|
+
all: "all";
|
|
296
|
+
}>;
|
|
297
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
298
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
299
|
+
column: z.ZodString;
|
|
300
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
301
|
+
}, z.core.$strict>>;
|
|
302
|
+
by: z.ZodOptional<z.ZodString>;
|
|
303
|
+
}, z.core.$strict>, z.ZodArray<z.ZodObject<{
|
|
304
|
+
reach: z.ZodEnum<{
|
|
305
|
+
own: "own";
|
|
306
|
+
team: "team";
|
|
307
|
+
all: "all";
|
|
308
|
+
}>;
|
|
309
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
310
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
311
|
+
column: z.ZodString;
|
|
312
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
313
|
+
}, z.core.$strict>>;
|
|
314
|
+
by: z.ZodOptional<z.ZodString>;
|
|
315
|
+
}, z.core.$strict>>]>>;
|
|
316
|
+
update: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
317
|
+
reach: z.ZodEnum<{
|
|
318
|
+
own: "own";
|
|
319
|
+
team: "team";
|
|
320
|
+
all: "all";
|
|
321
|
+
}>;
|
|
322
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
323
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
324
|
+
column: z.ZodString;
|
|
325
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
326
|
+
}, z.core.$strict>>;
|
|
327
|
+
by: z.ZodOptional<z.ZodString>;
|
|
328
|
+
}, z.core.$strict>, z.ZodArray<z.ZodObject<{
|
|
329
|
+
reach: z.ZodEnum<{
|
|
330
|
+
own: "own";
|
|
331
|
+
team: "team";
|
|
332
|
+
all: "all";
|
|
333
|
+
}>;
|
|
334
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
335
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
336
|
+
column: z.ZodString;
|
|
337
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
338
|
+
}, z.core.$strict>>;
|
|
339
|
+
by: z.ZodOptional<z.ZodString>;
|
|
340
|
+
}, z.core.$strict>>]>>;
|
|
341
|
+
delete: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
342
|
+
reach: z.ZodEnum<{
|
|
343
|
+
own: "own";
|
|
344
|
+
team: "team";
|
|
345
|
+
all: "all";
|
|
346
|
+
}>;
|
|
347
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
348
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
349
|
+
column: z.ZodString;
|
|
350
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
351
|
+
}, z.core.$strict>>;
|
|
352
|
+
by: z.ZodOptional<z.ZodString>;
|
|
353
|
+
}, z.core.$strict>, z.ZodArray<z.ZodObject<{
|
|
354
|
+
reach: z.ZodEnum<{
|
|
355
|
+
own: "own";
|
|
356
|
+
team: "team";
|
|
357
|
+
all: "all";
|
|
358
|
+
}>;
|
|
359
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
360
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
361
|
+
column: z.ZodString;
|
|
362
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
363
|
+
}, z.core.$strict>>;
|
|
364
|
+
by: z.ZodOptional<z.ZodString>;
|
|
365
|
+
}, z.core.$strict>>]>>;
|
|
366
|
+
}, z.core.$strict>>;
|
|
50
367
|
}, z.core.$strict>;
|
|
51
368
|
export type RoleLimit = z.infer<typeof roleLimitSchema>;
|
|
52
369
|
/** Per table ref, the limit on the role's update there. */
|
|
@@ -57,6 +374,83 @@ export declare const roleLimitsSchema: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
|
57
374
|
readable: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
58
375
|
creatable: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
59
376
|
creatableValues: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>>>;
|
|
377
|
+
rows: z.ZodOptional<z.ZodObject<{
|
|
378
|
+
read: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
379
|
+
reach: z.ZodEnum<{
|
|
380
|
+
own: "own";
|
|
381
|
+
team: "team";
|
|
382
|
+
all: "all";
|
|
383
|
+
}>;
|
|
384
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
385
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
386
|
+
column: z.ZodString;
|
|
387
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
388
|
+
}, z.core.$strict>>;
|
|
389
|
+
by: z.ZodOptional<z.ZodString>;
|
|
390
|
+
}, z.core.$strict>, z.ZodArray<z.ZodObject<{
|
|
391
|
+
reach: z.ZodEnum<{
|
|
392
|
+
own: "own";
|
|
393
|
+
team: "team";
|
|
394
|
+
all: "all";
|
|
395
|
+
}>;
|
|
396
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
397
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
398
|
+
column: z.ZodString;
|
|
399
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
400
|
+
}, z.core.$strict>>;
|
|
401
|
+
by: z.ZodOptional<z.ZodString>;
|
|
402
|
+
}, z.core.$strict>>]>>;
|
|
403
|
+
update: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
404
|
+
reach: z.ZodEnum<{
|
|
405
|
+
own: "own";
|
|
406
|
+
team: "team";
|
|
407
|
+
all: "all";
|
|
408
|
+
}>;
|
|
409
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
410
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
411
|
+
column: z.ZodString;
|
|
412
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
413
|
+
}, z.core.$strict>>;
|
|
414
|
+
by: z.ZodOptional<z.ZodString>;
|
|
415
|
+
}, z.core.$strict>, z.ZodArray<z.ZodObject<{
|
|
416
|
+
reach: z.ZodEnum<{
|
|
417
|
+
own: "own";
|
|
418
|
+
team: "team";
|
|
419
|
+
all: "all";
|
|
420
|
+
}>;
|
|
421
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
422
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
423
|
+
column: z.ZodString;
|
|
424
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
425
|
+
}, z.core.$strict>>;
|
|
426
|
+
by: z.ZodOptional<z.ZodString>;
|
|
427
|
+
}, z.core.$strict>>]>>;
|
|
428
|
+
delete: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
429
|
+
reach: z.ZodEnum<{
|
|
430
|
+
own: "own";
|
|
431
|
+
team: "team";
|
|
432
|
+
all: "all";
|
|
433
|
+
}>;
|
|
434
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
435
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
436
|
+
column: z.ZodString;
|
|
437
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
438
|
+
}, z.core.$strict>>;
|
|
439
|
+
by: z.ZodOptional<z.ZodString>;
|
|
440
|
+
}, z.core.$strict>, z.ZodArray<z.ZodObject<{
|
|
441
|
+
reach: z.ZodEnum<{
|
|
442
|
+
own: "own";
|
|
443
|
+
team: "team";
|
|
444
|
+
all: "all";
|
|
445
|
+
}>;
|
|
446
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
447
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
448
|
+
column: z.ZodString;
|
|
449
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
450
|
+
}, z.core.$strict>>;
|
|
451
|
+
by: z.ZodOptional<z.ZodString>;
|
|
452
|
+
}, z.core.$strict>>]>>;
|
|
453
|
+
}, z.core.$strict>>;
|
|
60
454
|
}, z.core.$strict>>;
|
|
61
455
|
/** What the checks read of a role. */
|
|
62
456
|
export interface RoleShape {
|
|
@@ -66,7 +460,26 @@ export interface RoleShape {
|
|
|
66
460
|
limits?: Readonly<Record<string, RoleLimit>> | undefined;
|
|
67
461
|
}
|
|
68
462
|
/** Every `limits` problem across the app's roles. */
|
|
69
|
-
export declare function roleLimitIssues<C extends ColumnShape>(roles: readonly RoleShape[], index: TableIndex<C
|
|
463
|
+
export declare function roleLimitIssues<C extends ColumnShape>(roles: readonly RoleShape[], index: TableIndex<C>, rowTables?: RowTables): ReferenceIssue[];
|
|
464
|
+
/** What the row checks read of a table beside its columns. */
|
|
465
|
+
export interface BelongsTableShape {
|
|
466
|
+
ref: string;
|
|
467
|
+
belongs?: readonly BelongsWay[] | undefined;
|
|
468
|
+
private?: true | undefined;
|
|
469
|
+
}
|
|
470
|
+
/** What `roleLimitIssues` asks of the tables' row words. */
|
|
471
|
+
export interface RowTables {
|
|
472
|
+
belongs: (ref: string) => boolean;
|
|
473
|
+
privateTables: () => readonly string[];
|
|
474
|
+
}
|
|
475
|
+
export declare function rowTablesOf(tables: readonly BelongsTableShape[]): RowTables;
|
|
476
|
+
/**
|
|
477
|
+
* Every problem of the tables' `belongs` and `private`: a column that is not
|
|
478
|
+
* there or not of the kind the way needs, a `via` that never reaches a table
|
|
479
|
+
* people belong to directly, and a private table that is reached any way but
|
|
480
|
+
* by its own staff columns.
|
|
481
|
+
*/
|
|
482
|
+
export declare function belongsIssues<C extends ColumnShape>(tables: readonly BelongsTableShape[], index: TableIndex<C>, isStaff: (table: string, column: string) => boolean): ReferenceIssue[];
|
|
70
483
|
/** What a role may do on a table of an add-on: read it, add rows, change rows. Never delete, export or import. */
|
|
71
484
|
export declare const ROLE_ADD_ON_ACTIONS: readonly ["read", "create", "update"];
|
|
72
485
|
/**
|
|
@@ -90,6 +503,83 @@ export declare const roleAddOnTableSchema: z.ZodObject<{
|
|
|
90
503
|
readable: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
91
504
|
creatable: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
92
505
|
creatableValues: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>>>;
|
|
506
|
+
rows: z.ZodOptional<z.ZodObject<{
|
|
507
|
+
read: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
508
|
+
reach: z.ZodEnum<{
|
|
509
|
+
own: "own";
|
|
510
|
+
team: "team";
|
|
511
|
+
all: "all";
|
|
512
|
+
}>;
|
|
513
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
514
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
515
|
+
column: z.ZodString;
|
|
516
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
517
|
+
}, z.core.$strict>>;
|
|
518
|
+
by: z.ZodOptional<z.ZodString>;
|
|
519
|
+
}, z.core.$strict>, z.ZodArray<z.ZodObject<{
|
|
520
|
+
reach: z.ZodEnum<{
|
|
521
|
+
own: "own";
|
|
522
|
+
team: "team";
|
|
523
|
+
all: "all";
|
|
524
|
+
}>;
|
|
525
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
526
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
527
|
+
column: z.ZodString;
|
|
528
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
529
|
+
}, z.core.$strict>>;
|
|
530
|
+
by: z.ZodOptional<z.ZodString>;
|
|
531
|
+
}, z.core.$strict>>]>>;
|
|
532
|
+
update: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
533
|
+
reach: z.ZodEnum<{
|
|
534
|
+
own: "own";
|
|
535
|
+
team: "team";
|
|
536
|
+
all: "all";
|
|
537
|
+
}>;
|
|
538
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
539
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
540
|
+
column: z.ZodString;
|
|
541
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
542
|
+
}, z.core.$strict>>;
|
|
543
|
+
by: z.ZodOptional<z.ZodString>;
|
|
544
|
+
}, z.core.$strict>, z.ZodArray<z.ZodObject<{
|
|
545
|
+
reach: z.ZodEnum<{
|
|
546
|
+
own: "own";
|
|
547
|
+
team: "team";
|
|
548
|
+
all: "all";
|
|
549
|
+
}>;
|
|
550
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
551
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
552
|
+
column: z.ZodString;
|
|
553
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
554
|
+
}, z.core.$strict>>;
|
|
555
|
+
by: z.ZodOptional<z.ZodString>;
|
|
556
|
+
}, z.core.$strict>>]>>;
|
|
557
|
+
delete: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
558
|
+
reach: z.ZodEnum<{
|
|
559
|
+
own: "own";
|
|
560
|
+
team: "team";
|
|
561
|
+
all: "all";
|
|
562
|
+
}>;
|
|
563
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
564
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
565
|
+
column: z.ZodString;
|
|
566
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
567
|
+
}, z.core.$strict>>;
|
|
568
|
+
by: z.ZodOptional<z.ZodString>;
|
|
569
|
+
}, z.core.$strict>, z.ZodArray<z.ZodObject<{
|
|
570
|
+
reach: z.ZodEnum<{
|
|
571
|
+
own: "own";
|
|
572
|
+
team: "team";
|
|
573
|
+
all: "all";
|
|
574
|
+
}>;
|
|
575
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
576
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
577
|
+
column: z.ZodString;
|
|
578
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
579
|
+
}, z.core.$strict>>;
|
|
580
|
+
by: z.ZodOptional<z.ZodString>;
|
|
581
|
+
}, z.core.$strict>>]>>;
|
|
582
|
+
}, z.core.$strict>>;
|
|
93
583
|
}, z.core.$strict>>;
|
|
94
584
|
}, z.core.$strict>;
|
|
95
585
|
export type RoleAddOnTable = z.infer<typeof roleAddOnTableSchema>;
|
|
@@ -108,6 +598,83 @@ export declare const roleAddOnTablesSchema: z.ZodArray<z.ZodObject<{
|
|
|
108
598
|
readable: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
109
599
|
creatable: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
110
600
|
creatableValues: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>>>;
|
|
601
|
+
rows: z.ZodOptional<z.ZodObject<{
|
|
602
|
+
read: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
603
|
+
reach: z.ZodEnum<{
|
|
604
|
+
own: "own";
|
|
605
|
+
team: "team";
|
|
606
|
+
all: "all";
|
|
607
|
+
}>;
|
|
608
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
609
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
610
|
+
column: z.ZodString;
|
|
611
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
612
|
+
}, z.core.$strict>>;
|
|
613
|
+
by: z.ZodOptional<z.ZodString>;
|
|
614
|
+
}, z.core.$strict>, z.ZodArray<z.ZodObject<{
|
|
615
|
+
reach: z.ZodEnum<{
|
|
616
|
+
own: "own";
|
|
617
|
+
team: "team";
|
|
618
|
+
all: "all";
|
|
619
|
+
}>;
|
|
620
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
621
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
622
|
+
column: z.ZodString;
|
|
623
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
624
|
+
}, z.core.$strict>>;
|
|
625
|
+
by: z.ZodOptional<z.ZodString>;
|
|
626
|
+
}, z.core.$strict>>]>>;
|
|
627
|
+
update: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
628
|
+
reach: z.ZodEnum<{
|
|
629
|
+
own: "own";
|
|
630
|
+
team: "team";
|
|
631
|
+
all: "all";
|
|
632
|
+
}>;
|
|
633
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
634
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
635
|
+
column: z.ZodString;
|
|
636
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
637
|
+
}, z.core.$strict>>;
|
|
638
|
+
by: z.ZodOptional<z.ZodString>;
|
|
639
|
+
}, z.core.$strict>, z.ZodArray<z.ZodObject<{
|
|
640
|
+
reach: z.ZodEnum<{
|
|
641
|
+
own: "own";
|
|
642
|
+
team: "team";
|
|
643
|
+
all: "all";
|
|
644
|
+
}>;
|
|
645
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
646
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
647
|
+
column: z.ZodString;
|
|
648
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
649
|
+
}, z.core.$strict>>;
|
|
650
|
+
by: z.ZodOptional<z.ZodString>;
|
|
651
|
+
}, z.core.$strict>>]>>;
|
|
652
|
+
delete: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
653
|
+
reach: z.ZodEnum<{
|
|
654
|
+
own: "own";
|
|
655
|
+
team: "team";
|
|
656
|
+
all: "all";
|
|
657
|
+
}>;
|
|
658
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
659
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
660
|
+
column: z.ZodString;
|
|
661
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
662
|
+
}, z.core.$strict>>;
|
|
663
|
+
by: z.ZodOptional<z.ZodString>;
|
|
664
|
+
}, z.core.$strict>, z.ZodArray<z.ZodObject<{
|
|
665
|
+
reach: z.ZodEnum<{
|
|
666
|
+
own: "own";
|
|
667
|
+
team: "team";
|
|
668
|
+
all: "all";
|
|
669
|
+
}>;
|
|
670
|
+
unowned: z.ZodOptional<z.ZodLiteral<true>>;
|
|
671
|
+
while: z.ZodOptional<z.ZodObject<{
|
|
672
|
+
column: z.ZodString;
|
|
673
|
+
in: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
|
|
674
|
+
}, z.core.$strict>>;
|
|
675
|
+
by: z.ZodOptional<z.ZodString>;
|
|
676
|
+
}, z.core.$strict>>]>>;
|
|
677
|
+
}, z.core.$strict>>;
|
|
111
678
|
}, z.core.$strict>>;
|
|
112
679
|
}, z.core.$strict>>;
|
|
113
680
|
/** Every problem of the roles' grants on add-on tables that the app's own manifest can see. */
|
|
@@ -115,4 +682,83 @@ export declare function roleAddOnTableIssues(roles: readonly {
|
|
|
115
682
|
key: string;
|
|
116
683
|
tables?: readonly RoleAddOnTable[] | undefined;
|
|
117
684
|
}[], named: ReadonlySet<string>): ReferenceIssue[];
|
|
685
|
+
/**
|
|
686
|
+
* The ways a manifest's own tables could carry a private table's rows out
|
|
687
|
+
* from under it, or lean on it and stop working: each is refused where it is
|
|
688
|
+
* written. A private table's rows are read on the screen by the people they
|
|
689
|
+
* belong to; nothing is kept from them elsewhere, nothing else is reached
|
|
690
|
+
* through them, and nothing Adminium does by itself runs on them.
|
|
691
|
+
*/
|
|
692
|
+
export declare function privateShapeIssues(tables: readonly {
|
|
693
|
+
ref: string;
|
|
694
|
+
private?: true | undefined;
|
|
695
|
+
belongs?: readonly unknown[] | undefined;
|
|
696
|
+
states?: {
|
|
697
|
+
timed?: unknown;
|
|
698
|
+
effects?: readonly {
|
|
699
|
+
via?: string;
|
|
700
|
+
}[] | undefined;
|
|
701
|
+
} | undefined;
|
|
702
|
+
postings?: unknown;
|
|
703
|
+
adjust?: unknown;
|
|
704
|
+
columns: readonly {
|
|
705
|
+
ref: string;
|
|
706
|
+
type?: string;
|
|
707
|
+
references?: string | undefined;
|
|
708
|
+
rules?: {
|
|
709
|
+
rollup?: {
|
|
710
|
+
from: string;
|
|
711
|
+
} | undefined;
|
|
712
|
+
copy?: {
|
|
713
|
+
via: string;
|
|
714
|
+
} | undefined;
|
|
715
|
+
lookup?: {
|
|
716
|
+
table: unknown;
|
|
717
|
+
} | undefined;
|
|
718
|
+
} | undefined;
|
|
719
|
+
}[];
|
|
720
|
+
}[]): ReferenceIssue[];
|
|
721
|
+
/**
|
|
722
|
+
* A STORED TOTAL IS EVERY ROW'S. A `rollup` column is written whole — a count
|
|
723
|
+
* or a sum over every child row, whoever reads it. Beside a list of those
|
|
724
|
+
* child rows that its reader sees only part of, it says "14" over six rows,
|
|
725
|
+
* and hands a rep the size of everybody else's book. So a role that reaches
|
|
726
|
+
* only some rows of a table is not also shown a stored total of that table:
|
|
727
|
+
* the app works the figure out when it is read (a measure, which counts the
|
|
728
|
+
* reader's rows), or keeps the column from that role (`readable`).
|
|
729
|
+
*
|
|
730
|
+
* Not refused: a total over rows that are reached exactly as their parent is
|
|
731
|
+
* (the child's `belongs` is `via` the very link the total counts by) —
|
|
732
|
+
* whoever reads the parent reaches every one of them.
|
|
733
|
+
*/
|
|
734
|
+
export declare function storedTotalIssues(tables: readonly {
|
|
735
|
+
ref: string;
|
|
736
|
+
belongs?: readonly unknown[] | undefined;
|
|
737
|
+
columns: readonly {
|
|
738
|
+
ref: string;
|
|
739
|
+
rules?: {
|
|
740
|
+
rollup?: {
|
|
741
|
+
from: string;
|
|
742
|
+
via: string;
|
|
743
|
+
} | undefined;
|
|
744
|
+
} | undefined;
|
|
745
|
+
}[];
|
|
746
|
+
}[], roles: readonly {
|
|
747
|
+
key: string;
|
|
748
|
+
permissions?: readonly string[] | undefined;
|
|
749
|
+
limits?: Readonly<Record<string, {
|
|
750
|
+
rows?: {
|
|
751
|
+
read?: unknown;
|
|
752
|
+
} | undefined;
|
|
753
|
+
readable?: readonly string[] | undefined;
|
|
754
|
+
} | undefined>> | undefined;
|
|
755
|
+
}[]): ReferenceIssue[];
|
|
756
|
+
/**
|
|
757
|
+
* Every place one of those blocks names a private table. A private table's
|
|
758
|
+
* rows are read by the people they belong to and by nothing that acts for
|
|
759
|
+
* anyone else, so a rule, a public entry, a document or a mail that names
|
|
760
|
+
* one is refused where it is written. Reads the plain document: a block it
|
|
761
|
+
* does not know the shape of is walked all the same.
|
|
762
|
+
*/
|
|
763
|
+
export declare function privateTableIssues(document: Readonly<Record<string, unknown>>, privateTables: readonly string[]): ReferenceIssue[];
|
|
118
764
|
//# sourceMappingURL=roles.d.ts.map
|