@ai-matrx/records 0.6.2 → 0.8.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/CHANGELOG.md +68 -0
- package/dist/core/index.cjs +191 -33
- package/dist/core/index.cjs.map +1 -1
- package/dist/core/index.d.cts +44 -4
- package/dist/core/index.d.ts +44 -4
- package/dist/core/index.js +191 -33
- package/dist/core/index.js.map +1 -1
- package/dist/index.cjs +126 -30
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +375 -30
- package/dist/index.d.ts +375 -30
- package/dist/index.js +126 -30
- package/dist/index.js.map +1 -1
- package/dist/react/index.cjs +222 -33
- package/dist/react/index.cjs.map +1 -1
- package/dist/react/index.d.cts +443 -31
- package/dist/react/index.d.ts +443 -31
- package/dist/react/index.js +222 -33
- package/dist/react/index.js.map +1 -1
- package/package.json +1 -1
package/dist/core/index.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Timestamp, Uuid, RelationCoordinate, RecordsConfig, RecordDocument, RecordsResult, RecordRead, ReadRow, Table, Field, StoredRecord, TableCapacity, NewFieldDeclaration, FieldPatch, AggregateMeasure, AggregateBucket, AggregateRow, Subscription, DocToken, DocUnresolvedToken, DocTemplateRow, DocRenderRow, DocSignatureRow, RecordRevision, ReadValue, AnonTokenBinding, WorkState, WorkGraph, WorkInstantiation, WorkTurn, WorkAssignmentField, WorkSlotHold, ExternalPrincipalCard, PublishBinding, ResolvedPublishBinding, FieldProposal, TableProposal, RecordsError, WriteConflict, PgError, RecordsDataSource, StaleWriteDetail, PredictedRefusal } from '../index.cjs';
|
|
2
|
-
export { ABSENCE_REASONS, ACTOR_VOCABULARY, AbsenceReason, Actor, AggregateOperation, COMPUTE_ON, CONTEXT_POLICIES, ComputeOn, ContextPolicy, DELIVERIES, Delivery, DocSignatureCheck, ENTITY_TOKENS, EntityToken, FIELD_SENSITIVITIES, FIELD_SOURCES, FRESHNESS, FieldBehavior, FieldRule, FieldSensitivity, FieldSource, ForbiddenEnvelopeWord, Freshness, HiddenFieldNotice, Home, KERNEL_TABLES, KernelTableName, MERGE_FIELD_MODIFIERS, MERGE_FIELD_SEMANTIC_TYPES, MERGE_FIELD_SOURCES, MergeField, MergeFieldModifier, MergeFieldProvenance, MergeFieldResolution, MergeFieldSemanticType, MergeFieldSource, MergeFieldTransform, MissingBehavior, ON_DELETE, OVERRIDE_POLICIES, OnDelete, OverridePolicy, PARITY_FIELD_TYPES, PER_VALUE_ACCESS_WORDS, ParityFieldType, ParityFieldTypeDescriptor, PerValueAccessWord, ProvenancePointer, RELATION_BINDINGS, RELATION_CARDINALITIES, RELATION_FLAVORS, RETIRED_ACTOR_WORDS, RULE_NODE_KINDS, RULE_USES, RecordsActor, RecordsErrorCode, RecordsErrorSink, RecordsFilter, RecordsRealtimePort, RecordsResolverPort, RecordsResponse, RecordsTableQuery, RegisteredTable, Relation, RelationBinding, RelationCardinality, RelationCarries, RelationFlavor, RelationProperties, RelationTarget, ResolutionTriple, RetiredActorWord, Rule, RuleAnswer, RuleExpression, RuleNodeKind, RuleUse, STORAGE_MODES, STORE_DOORS, STORE_KNOBS, STORE_REFUSAL_CODES, StorageMode, StoreDoorName, StoreRefusalCode, SubscriptionBlock, SubscriptionCadence, TABLE_DISPLAYS, TABLE_ORIGINS, TABLE_TYPES, TableDisplay, TableOrigin, TableType, VALUE_ALTERNATE_KEYS, VALUE_ENVELOPE_KEYS, ValueAlternate, ValueAlternateKey, ValueEnvelope, ValueEnvelopeKey, ValueSource, WorkTemplateNode, WorkTemplateRelation, err, isRecordsErr, measureKey, ok } from '../index.cjs';
|
|
1
|
+
import { Timestamp, Uuid, RelationCoordinate, RecordsConfig, RecordDocument, RecordsResult, RecordRead, ReadRow, Table, Field, StoredRecord, TableCapacity, NewFieldDeclaration, FieldPatch, FormSummary, AggregateMeasure, AggregateBucket, AggregateRow, Subscription, DocToken, DocUnresolvedToken, DocTemplateRow, DocRenderRow, DocSignatureRow, RecordRevision, ReadValue, AnonTokenBinding, WorkState, WorkGraph, WorkInstantiation, WorkTurn, WorkAssignmentField, WorkSlotHold, ExternalPrincipalCard, PublishBinding, ResolvedPublishBinding, FieldProposal, TableProposal, MyLevel, RecordsError, WriteConflict, PgError, RecordsDataSource, StaleWriteDetail, PredictedRefusal } from '../index.cjs';
|
|
2
|
+
export { ABSENCE_REASONS, ACTOR_VOCABULARY, AbsenceReason, Actor, AggregateOperation, COMPUTE_ON, CONTEXT_POLICIES, ComputeOn, ContextPolicy, DELIVERIES, Delivery, DocSignatureCheck, ENTITY_TOKENS, EntityToken, FIELD_SENSITIVITIES, FIELD_SOURCES, FRESHNESS, FieldBehavior, FieldRule, FieldSensitivity, FieldSource, ForbiddenEnvelopeWord, Freshness, HiddenFieldNotice, Home, KERNEL_TABLES, KernelTableName, MERGE_FIELD_MODIFIERS, MERGE_FIELD_SEMANTIC_TYPES, MERGE_FIELD_SOURCES, MergeField, MergeFieldModifier, MergeFieldProvenance, MergeFieldResolution, MergeFieldSemanticType, MergeFieldSource, MergeFieldTransform, MissingBehavior, ON_DELETE, OVERRIDE_POLICIES, OnDelete, OverridePolicy, PARITY_FIELD_TYPES, PERMISSION_LEVELS, PER_VALUE_ACCESS_WORDS, ParityFieldType, ParityFieldTypeDescriptor, PerValueAccessWord, PermissionLevel, ProvenancePointer, RELATION_BINDINGS, RELATION_CARDINALITIES, RELATION_FLAVORS, RETIRED_ACTOR_WORDS, RULE_NODE_KINDS, RULE_USES, RecordsActor, RecordsErrorCode, RecordsErrorSink, RecordsFilter, RecordsRealtimePort, RecordsResolverPort, RecordsResponse, RecordsTableQuery, RegisteredTable, Relation, RelationBinding, RelationCardinality, RelationCarries, RelationFlavor, RelationProperties, RelationTarget, ResolutionTriple, RetiredActorWord, Rule, RuleAnswer, RuleExpression, RuleNodeKind, RuleUse, STORAGE_MODES, STORE_DOORS, STORE_KNOBS, STORE_REFUSAL_CODES, StorageMode, StoreDoorName, StoreRefusalCode, SubscriptionBlock, SubscriptionCadence, TABLE_DISPLAYS, TABLE_ORIGINS, TABLE_TYPES, TableDisplay, TableOrigin, TableType, VALUE_ALTERNATE_KEYS, VALUE_ENVELOPE_KEYS, ValueAlternate, ValueAlternateKey, ValueEnvelope, ValueEnvelopeKey, ValueSource, WorkTemplateNode, WorkTemplateRelation, asPermissionLevel, atLeast, err, highestLevel, isRecordsErr, measureKey, ok, publicFormPath } from '../index.cjs';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* DOOR-8. As-of on EITHER clock, and they are different questions:
|
|
@@ -204,6 +204,29 @@ interface RecordsClient {
|
|
|
204
204
|
values: Record<string, unknown>;
|
|
205
205
|
context?: Record<string, unknown>;
|
|
206
206
|
}): Promise<RecordsResult<unknown>>;
|
|
207
|
+
/**
|
|
208
|
+
* Write ONE Rule as a real Rule. `recordWrite` into the Rule kernel makes a
|
|
209
|
+
* valid Rule document that carries `data_class = 'record'`, and every reader
|
|
210
|
+
* that looks for a Rule looks for the class — `custom.agg_subscriptions`
|
|
211
|
+
* selects `where data_class = 'rule'` — so a subscription written that way
|
|
212
|
+
* fires at nobody. This is the door that closes it.
|
|
213
|
+
*/
|
|
214
|
+
/** This organization's forms, with how many answers arrived and how many are in the table. */
|
|
215
|
+
forms(args?: {
|
|
216
|
+
table_id?: Uuid | null;
|
|
217
|
+
}): Promise<RecordsResult<FormSummary[]>>;
|
|
218
|
+
/** Create or re-state one form. A question naming no Field of that Table is refused BY NAME. */
|
|
219
|
+
formDeclare(args: {
|
|
220
|
+
table_id: Uuid;
|
|
221
|
+
title: string;
|
|
222
|
+
questions: unknown[];
|
|
223
|
+
presentation?: Record<string, unknown> | null;
|
|
224
|
+
submission_cap?: number | null;
|
|
225
|
+
quarantine_rule_id?: Uuid | null;
|
|
226
|
+
notify_rule_id?: Uuid | null;
|
|
227
|
+
form_id?: Uuid | null;
|
|
228
|
+
slug?: string | null;
|
|
229
|
+
}): Promise<RecordsResult<Uuid>>;
|
|
207
230
|
/**
|
|
208
231
|
* Group, bucket, filter and measure INSIDE `custom.record_aggregate`. The
|
|
209
232
|
* aggregate node sits above the visibility join, so what a chart draws is
|
|
@@ -486,7 +509,8 @@ interface RecordsClient {
|
|
|
486
509
|
*/
|
|
487
510
|
ruleDeclare(args: {
|
|
488
511
|
spec: Record<string, unknown>;
|
|
489
|
-
|
|
512
|
+
rule_id?: Uuid | null;
|
|
513
|
+
}): Promise<RecordsResult<Uuid>>;
|
|
490
514
|
fieldPropose(proposal: FieldProposal): Promise<RecordsResult<never>>;
|
|
491
515
|
tablePropose(proposal: TableProposal): Promise<RecordsResult<never>>;
|
|
492
516
|
promoteTable(args: {
|
|
@@ -498,6 +522,19 @@ interface RecordsClient {
|
|
|
498
522
|
}): Promise<RecordsResult<unknown>>;
|
|
499
523
|
/** Is the store switched on for this organization? A product switch, never the boundary. */
|
|
500
524
|
storeIsOpen(): Promise<RecordsResult<boolean>>;
|
|
525
|
+
/**
|
|
526
|
+
* WHAT THIS PERSON MAY DO TO THESE THINGS — asked once, for a whole page.
|
|
527
|
+
*
|
|
528
|
+
* There is no principal argument, on purpose: the door resolves the caller
|
|
529
|
+
* from the session, so a person can ask about their OWN access and about
|
|
530
|
+
* nobody else's. A subject they hold nothing on answers `level: null`, which
|
|
531
|
+
* is an answer; the row is never omitted, because a screen that could not
|
|
532
|
+
* tell "no access" from "not asked yet" would draw one of them as the other.
|
|
533
|
+
*/
|
|
534
|
+
myLevels(args: {
|
|
535
|
+
ids: Uuid[];
|
|
536
|
+
subject?: "record";
|
|
537
|
+
}): Promise<RecordsResult<MyLevel[]>>;
|
|
501
538
|
}
|
|
502
539
|
declare function createRecordsClient(config: RecordsConfig): RecordsClient;
|
|
503
540
|
/**
|
|
@@ -544,6 +581,7 @@ declare const DOORS: {
|
|
|
544
581
|
readonly recordReparent: "record_reparent";
|
|
545
582
|
readonly containmentChain: "containment_chain";
|
|
546
583
|
readonly storeIsOpen: "store_is_open";
|
|
584
|
+
readonly myLevels: "my_levels";
|
|
547
585
|
readonly ioRevisions: "io_revisions";
|
|
548
586
|
readonly resolveFirstMatch: "resolve_first_match";
|
|
549
587
|
readonly personKernelId: "person_kernel_id";
|
|
@@ -554,6 +592,8 @@ declare const DOORS: {
|
|
|
554
592
|
readonly ruleMembership: "rule_membership";
|
|
555
593
|
readonly ruleRun: "rule_run";
|
|
556
594
|
readonly ruleEval: "rule_eval";
|
|
595
|
+
readonly forms: "forms";
|
|
596
|
+
readonly formDeclare: "form_declare";
|
|
557
597
|
readonly recordAggregate: "record_aggregate";
|
|
558
598
|
readonly aggOperations: "agg_operations";
|
|
559
599
|
readonly aggBuckets: "agg_buckets";
|
|
@@ -711,4 +751,4 @@ declare function parseCsv(text: string): string[][];
|
|
|
711
751
|
declare function importCsv(fields: Field[], text: string): ParsedImport;
|
|
712
752
|
declare function importXlsx(fields: Field[], bytes: ArrayBuffer | Uint8Array): Promise<ParsedImport>;
|
|
713
753
|
|
|
714
|
-
export { AggregateBucket, AggregateMeasure, AggregateRow, AnonTokenBinding, type AsOf, DEFAULT_DOCUMENT_MAX_BYTES, DEFAULT_PAGE_SIZE, DEFAULT_VALUE_MAX_BYTES, DOORS, DocRenderRow, DocSignatureRow, DocTemplateRow, DocToken, DocUnresolvedToken, type DoorKey, type ExportRow, ExternalPrincipalCard, Field, FieldPatch, FieldProposal, MAPPED_SQLSTATES, type MirrorLimits, NewFieldDeclaration, type ParsedImport, PgError, PredictedRefusal, type PromotedPredicate, PublishBinding, type QueryPlan, ReadRow, ReadValue, RecordDocument, type RecordQuery, RecordRead, RecordRevision, type RecordsClient, RecordsConfig, RecordsDataSource, RecordsError, RecordsResult, RelationCoordinate, ResolvedPublishBinding, StaleWriteDetail, StoredRecord, Subscription, type SupabaseLike, Table, TableCapacity, TableProposal, Timestamp, Uuid, WorkAssignmentField, WorkGraph, WorkInstantiation, WorkSlotHold, WorkState, WorkTurn, WriteConflict, asWriteConflict, cellText, createRecordsClient, doorAbsent, doorCensus, doorExists, exportCsv, exportXlsx, importCsv, importXlsx, intersectIds, mapPgError, parseCsv, planQuery, predictEnvelopeRefusal, predictSizeRefusal, predictValueRefusals, predictWriteRefusals, staleWriteDetail, supabaseDataSource, toAoa };
|
|
754
|
+
export { AggregateBucket, AggregateMeasure, AggregateRow, AnonTokenBinding, type AsOf, DEFAULT_DOCUMENT_MAX_BYTES, DEFAULT_PAGE_SIZE, DEFAULT_VALUE_MAX_BYTES, DOORS, DocRenderRow, DocSignatureRow, DocTemplateRow, DocToken, DocUnresolvedToken, type DoorKey, type ExportRow, ExternalPrincipalCard, Field, FieldPatch, FieldProposal, FormSummary, MAPPED_SQLSTATES, type MirrorLimits, MyLevel, NewFieldDeclaration, type ParsedImport, PgError, PredictedRefusal, type PromotedPredicate, PublishBinding, type QueryPlan, ReadRow, ReadValue, RecordDocument, type RecordQuery, RecordRead, RecordRevision, type RecordsClient, RecordsConfig, RecordsDataSource, RecordsError, RecordsResult, RelationCoordinate, ResolvedPublishBinding, StaleWriteDetail, StoredRecord, Subscription, type SupabaseLike, Table, TableCapacity, TableProposal, Timestamp, Uuid, WorkAssignmentField, WorkGraph, WorkInstantiation, WorkSlotHold, WorkState, WorkTurn, WriteConflict, asWriteConflict, cellText, createRecordsClient, doorAbsent, doorCensus, doorExists, exportCsv, exportXlsx, importCsv, importXlsx, intersectIds, mapPgError, parseCsv, planQuery, predictEnvelopeRefusal, predictSizeRefusal, predictValueRefusals, predictWriteRefusals, staleWriteDetail, supabaseDataSource, toAoa };
|
package/dist/core/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Timestamp, Uuid, RelationCoordinate, RecordsConfig, RecordDocument, RecordsResult, RecordRead, ReadRow, Table, Field, StoredRecord, TableCapacity, NewFieldDeclaration, FieldPatch, AggregateMeasure, AggregateBucket, AggregateRow, Subscription, DocToken, DocUnresolvedToken, DocTemplateRow, DocRenderRow, DocSignatureRow, RecordRevision, ReadValue, AnonTokenBinding, WorkState, WorkGraph, WorkInstantiation, WorkTurn, WorkAssignmentField, WorkSlotHold, ExternalPrincipalCard, PublishBinding, ResolvedPublishBinding, FieldProposal, TableProposal, RecordsError, WriteConflict, PgError, RecordsDataSource, StaleWriteDetail, PredictedRefusal } from '../index.js';
|
|
2
|
-
export { ABSENCE_REASONS, ACTOR_VOCABULARY, AbsenceReason, Actor, AggregateOperation, COMPUTE_ON, CONTEXT_POLICIES, ComputeOn, ContextPolicy, DELIVERIES, Delivery, DocSignatureCheck, ENTITY_TOKENS, EntityToken, FIELD_SENSITIVITIES, FIELD_SOURCES, FRESHNESS, FieldBehavior, FieldRule, FieldSensitivity, FieldSource, ForbiddenEnvelopeWord, Freshness, HiddenFieldNotice, Home, KERNEL_TABLES, KernelTableName, MERGE_FIELD_MODIFIERS, MERGE_FIELD_SEMANTIC_TYPES, MERGE_FIELD_SOURCES, MergeField, MergeFieldModifier, MergeFieldProvenance, MergeFieldResolution, MergeFieldSemanticType, MergeFieldSource, MergeFieldTransform, MissingBehavior, ON_DELETE, OVERRIDE_POLICIES, OnDelete, OverridePolicy, PARITY_FIELD_TYPES, PER_VALUE_ACCESS_WORDS, ParityFieldType, ParityFieldTypeDescriptor, PerValueAccessWord, ProvenancePointer, RELATION_BINDINGS, RELATION_CARDINALITIES, RELATION_FLAVORS, RETIRED_ACTOR_WORDS, RULE_NODE_KINDS, RULE_USES, RecordsActor, RecordsErrorCode, RecordsErrorSink, RecordsFilter, RecordsRealtimePort, RecordsResolverPort, RecordsResponse, RecordsTableQuery, RegisteredTable, Relation, RelationBinding, RelationCardinality, RelationCarries, RelationFlavor, RelationProperties, RelationTarget, ResolutionTriple, RetiredActorWord, Rule, RuleAnswer, RuleExpression, RuleNodeKind, RuleUse, STORAGE_MODES, STORE_DOORS, STORE_KNOBS, STORE_REFUSAL_CODES, StorageMode, StoreDoorName, StoreRefusalCode, SubscriptionBlock, SubscriptionCadence, TABLE_DISPLAYS, TABLE_ORIGINS, TABLE_TYPES, TableDisplay, TableOrigin, TableType, VALUE_ALTERNATE_KEYS, VALUE_ENVELOPE_KEYS, ValueAlternate, ValueAlternateKey, ValueEnvelope, ValueEnvelopeKey, ValueSource, WorkTemplateNode, WorkTemplateRelation, err, isRecordsErr, measureKey, ok } from '../index.js';
|
|
1
|
+
import { Timestamp, Uuid, RelationCoordinate, RecordsConfig, RecordDocument, RecordsResult, RecordRead, ReadRow, Table, Field, StoredRecord, TableCapacity, NewFieldDeclaration, FieldPatch, FormSummary, AggregateMeasure, AggregateBucket, AggregateRow, Subscription, DocToken, DocUnresolvedToken, DocTemplateRow, DocRenderRow, DocSignatureRow, RecordRevision, ReadValue, AnonTokenBinding, WorkState, WorkGraph, WorkInstantiation, WorkTurn, WorkAssignmentField, WorkSlotHold, ExternalPrincipalCard, PublishBinding, ResolvedPublishBinding, FieldProposal, TableProposal, MyLevel, RecordsError, WriteConflict, PgError, RecordsDataSource, StaleWriteDetail, PredictedRefusal } from '../index.js';
|
|
2
|
+
export { ABSENCE_REASONS, ACTOR_VOCABULARY, AbsenceReason, Actor, AggregateOperation, COMPUTE_ON, CONTEXT_POLICIES, ComputeOn, ContextPolicy, DELIVERIES, Delivery, DocSignatureCheck, ENTITY_TOKENS, EntityToken, FIELD_SENSITIVITIES, FIELD_SOURCES, FRESHNESS, FieldBehavior, FieldRule, FieldSensitivity, FieldSource, ForbiddenEnvelopeWord, Freshness, HiddenFieldNotice, Home, KERNEL_TABLES, KernelTableName, MERGE_FIELD_MODIFIERS, MERGE_FIELD_SEMANTIC_TYPES, MERGE_FIELD_SOURCES, MergeField, MergeFieldModifier, MergeFieldProvenance, MergeFieldResolution, MergeFieldSemanticType, MergeFieldSource, MergeFieldTransform, MissingBehavior, ON_DELETE, OVERRIDE_POLICIES, OnDelete, OverridePolicy, PARITY_FIELD_TYPES, PERMISSION_LEVELS, PER_VALUE_ACCESS_WORDS, ParityFieldType, ParityFieldTypeDescriptor, PerValueAccessWord, PermissionLevel, ProvenancePointer, RELATION_BINDINGS, RELATION_CARDINALITIES, RELATION_FLAVORS, RETIRED_ACTOR_WORDS, RULE_NODE_KINDS, RULE_USES, RecordsActor, RecordsErrorCode, RecordsErrorSink, RecordsFilter, RecordsRealtimePort, RecordsResolverPort, RecordsResponse, RecordsTableQuery, RegisteredTable, Relation, RelationBinding, RelationCardinality, RelationCarries, RelationFlavor, RelationProperties, RelationTarget, ResolutionTriple, RetiredActorWord, Rule, RuleAnswer, RuleExpression, RuleNodeKind, RuleUse, STORAGE_MODES, STORE_DOORS, STORE_KNOBS, STORE_REFUSAL_CODES, StorageMode, StoreDoorName, StoreRefusalCode, SubscriptionBlock, SubscriptionCadence, TABLE_DISPLAYS, TABLE_ORIGINS, TABLE_TYPES, TableDisplay, TableOrigin, TableType, VALUE_ALTERNATE_KEYS, VALUE_ENVELOPE_KEYS, ValueAlternate, ValueAlternateKey, ValueEnvelope, ValueEnvelopeKey, ValueSource, WorkTemplateNode, WorkTemplateRelation, asPermissionLevel, atLeast, err, highestLevel, isRecordsErr, measureKey, ok, publicFormPath } from '../index.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* DOOR-8. As-of on EITHER clock, and they are different questions:
|
|
@@ -204,6 +204,29 @@ interface RecordsClient {
|
|
|
204
204
|
values: Record<string, unknown>;
|
|
205
205
|
context?: Record<string, unknown>;
|
|
206
206
|
}): Promise<RecordsResult<unknown>>;
|
|
207
|
+
/**
|
|
208
|
+
* Write ONE Rule as a real Rule. `recordWrite` into the Rule kernel makes a
|
|
209
|
+
* valid Rule document that carries `data_class = 'record'`, and every reader
|
|
210
|
+
* that looks for a Rule looks for the class — `custom.agg_subscriptions`
|
|
211
|
+
* selects `where data_class = 'rule'` — so a subscription written that way
|
|
212
|
+
* fires at nobody. This is the door that closes it.
|
|
213
|
+
*/
|
|
214
|
+
/** This organization's forms, with how many answers arrived and how many are in the table. */
|
|
215
|
+
forms(args?: {
|
|
216
|
+
table_id?: Uuid | null;
|
|
217
|
+
}): Promise<RecordsResult<FormSummary[]>>;
|
|
218
|
+
/** Create or re-state one form. A question naming no Field of that Table is refused BY NAME. */
|
|
219
|
+
formDeclare(args: {
|
|
220
|
+
table_id: Uuid;
|
|
221
|
+
title: string;
|
|
222
|
+
questions: unknown[];
|
|
223
|
+
presentation?: Record<string, unknown> | null;
|
|
224
|
+
submission_cap?: number | null;
|
|
225
|
+
quarantine_rule_id?: Uuid | null;
|
|
226
|
+
notify_rule_id?: Uuid | null;
|
|
227
|
+
form_id?: Uuid | null;
|
|
228
|
+
slug?: string | null;
|
|
229
|
+
}): Promise<RecordsResult<Uuid>>;
|
|
207
230
|
/**
|
|
208
231
|
* Group, bucket, filter and measure INSIDE `custom.record_aggregate`. The
|
|
209
232
|
* aggregate node sits above the visibility join, so what a chart draws is
|
|
@@ -486,7 +509,8 @@ interface RecordsClient {
|
|
|
486
509
|
*/
|
|
487
510
|
ruleDeclare(args: {
|
|
488
511
|
spec: Record<string, unknown>;
|
|
489
|
-
|
|
512
|
+
rule_id?: Uuid | null;
|
|
513
|
+
}): Promise<RecordsResult<Uuid>>;
|
|
490
514
|
fieldPropose(proposal: FieldProposal): Promise<RecordsResult<never>>;
|
|
491
515
|
tablePropose(proposal: TableProposal): Promise<RecordsResult<never>>;
|
|
492
516
|
promoteTable(args: {
|
|
@@ -498,6 +522,19 @@ interface RecordsClient {
|
|
|
498
522
|
}): Promise<RecordsResult<unknown>>;
|
|
499
523
|
/** Is the store switched on for this organization? A product switch, never the boundary. */
|
|
500
524
|
storeIsOpen(): Promise<RecordsResult<boolean>>;
|
|
525
|
+
/**
|
|
526
|
+
* WHAT THIS PERSON MAY DO TO THESE THINGS — asked once, for a whole page.
|
|
527
|
+
*
|
|
528
|
+
* There is no principal argument, on purpose: the door resolves the caller
|
|
529
|
+
* from the session, so a person can ask about their OWN access and about
|
|
530
|
+
* nobody else's. A subject they hold nothing on answers `level: null`, which
|
|
531
|
+
* is an answer; the row is never omitted, because a screen that could not
|
|
532
|
+
* tell "no access" from "not asked yet" would draw one of them as the other.
|
|
533
|
+
*/
|
|
534
|
+
myLevels(args: {
|
|
535
|
+
ids: Uuid[];
|
|
536
|
+
subject?: "record";
|
|
537
|
+
}): Promise<RecordsResult<MyLevel[]>>;
|
|
501
538
|
}
|
|
502
539
|
declare function createRecordsClient(config: RecordsConfig): RecordsClient;
|
|
503
540
|
/**
|
|
@@ -544,6 +581,7 @@ declare const DOORS: {
|
|
|
544
581
|
readonly recordReparent: "record_reparent";
|
|
545
582
|
readonly containmentChain: "containment_chain";
|
|
546
583
|
readonly storeIsOpen: "store_is_open";
|
|
584
|
+
readonly myLevels: "my_levels";
|
|
547
585
|
readonly ioRevisions: "io_revisions";
|
|
548
586
|
readonly resolveFirstMatch: "resolve_first_match";
|
|
549
587
|
readonly personKernelId: "person_kernel_id";
|
|
@@ -554,6 +592,8 @@ declare const DOORS: {
|
|
|
554
592
|
readonly ruleMembership: "rule_membership";
|
|
555
593
|
readonly ruleRun: "rule_run";
|
|
556
594
|
readonly ruleEval: "rule_eval";
|
|
595
|
+
readonly forms: "forms";
|
|
596
|
+
readonly formDeclare: "form_declare";
|
|
557
597
|
readonly recordAggregate: "record_aggregate";
|
|
558
598
|
readonly aggOperations: "agg_operations";
|
|
559
599
|
readonly aggBuckets: "agg_buckets";
|
|
@@ -711,4 +751,4 @@ declare function parseCsv(text: string): string[][];
|
|
|
711
751
|
declare function importCsv(fields: Field[], text: string): ParsedImport;
|
|
712
752
|
declare function importXlsx(fields: Field[], bytes: ArrayBuffer | Uint8Array): Promise<ParsedImport>;
|
|
713
753
|
|
|
714
|
-
export { AggregateBucket, AggregateMeasure, AggregateRow, AnonTokenBinding, type AsOf, DEFAULT_DOCUMENT_MAX_BYTES, DEFAULT_PAGE_SIZE, DEFAULT_VALUE_MAX_BYTES, DOORS, DocRenderRow, DocSignatureRow, DocTemplateRow, DocToken, DocUnresolvedToken, type DoorKey, type ExportRow, ExternalPrincipalCard, Field, FieldPatch, FieldProposal, MAPPED_SQLSTATES, type MirrorLimits, NewFieldDeclaration, type ParsedImport, PgError, PredictedRefusal, type PromotedPredicate, PublishBinding, type QueryPlan, ReadRow, ReadValue, RecordDocument, type RecordQuery, RecordRead, RecordRevision, type RecordsClient, RecordsConfig, RecordsDataSource, RecordsError, RecordsResult, RelationCoordinate, ResolvedPublishBinding, StaleWriteDetail, StoredRecord, Subscription, type SupabaseLike, Table, TableCapacity, TableProposal, Timestamp, Uuid, WorkAssignmentField, WorkGraph, WorkInstantiation, WorkSlotHold, WorkState, WorkTurn, WriteConflict, asWriteConflict, cellText, createRecordsClient, doorAbsent, doorCensus, doorExists, exportCsv, exportXlsx, importCsv, importXlsx, intersectIds, mapPgError, parseCsv, planQuery, predictEnvelopeRefusal, predictSizeRefusal, predictValueRefusals, predictWriteRefusals, staleWriteDetail, supabaseDataSource, toAoa };
|
|
754
|
+
export { AggregateBucket, AggregateMeasure, AggregateRow, AnonTokenBinding, type AsOf, DEFAULT_DOCUMENT_MAX_BYTES, DEFAULT_PAGE_SIZE, DEFAULT_VALUE_MAX_BYTES, DOORS, DocRenderRow, DocSignatureRow, DocTemplateRow, DocToken, DocUnresolvedToken, type DoorKey, type ExportRow, ExternalPrincipalCard, Field, FieldPatch, FieldProposal, FormSummary, MAPPED_SQLSTATES, type MirrorLimits, MyLevel, NewFieldDeclaration, type ParsedImport, PgError, PredictedRefusal, type PromotedPredicate, PublishBinding, type QueryPlan, ReadRow, ReadValue, RecordDocument, type RecordQuery, RecordRead, RecordRevision, type RecordsClient, RecordsConfig, RecordsDataSource, RecordsError, RecordsResult, RelationCoordinate, ResolvedPublishBinding, StaleWriteDetail, StoredRecord, Subscription, type SupabaseLike, Table, TableCapacity, TableProposal, Timestamp, Uuid, WorkAssignmentField, WorkGraph, WorkInstantiation, WorkSlotHold, WorkState, WorkTurn, WriteConflict, asWriteConflict, cellText, createRecordsClient, doorAbsent, doorCensus, doorExists, exportCsv, exportXlsx, importCsv, importXlsx, intersectIds, mapPgError, parseCsv, planQuery, predictEnvelopeRefusal, predictSizeRefusal, predictValueRefusals, predictWriteRefusals, staleWriteDetail, supabaseDataSource, toAoa };
|