@stndrds/schema 0.1.0-alpha.37 → 0.1.0-alpha.39

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/index.mjs CHANGED
@@ -3,25 +3,37 @@ import {
3
3
  AttributeInUseError,
4
4
  AttributeNotFoundError,
5
5
  AuditService,
6
+ ConditionExecutor,
7
+ ConditionGroupSchema,
8
+ ConditionNodeSchema,
9
+ ConditionOperatorSchema,
10
+ ConditionRuleSchema,
6
11
  CustomTabConfig,
7
12
  DEFAULT_LABEL_FALLBACK,
13
+ DEFAULT_THEME,
8
14
  DEFAULT_VALIDATION_MESSAGES,
9
15
  DirectTableTabConfig,
10
16
  DuplicateError,
11
17
  EMPTY_VALUE_PLACEHOLDER,
18
+ EndExecutor,
19
+ EndNodeSchema,
20
+ ExecutorRegistry,
12
21
  FileNotFoundError,
13
22
  FileService,
14
- FlowBuilder,
15
- FlowPageBuilder,
16
- FlowRowBuilder,
17
- FlowService,
23
+ FlowRowFieldSchema,
24
+ FlowRowSchema,
25
+ FlowsTabConfig,
18
26
  ForbiddenError,
27
+ FormExecutor,
28
+ FormFieldRefSchema,
29
+ FormNodeSchema,
19
30
  GeocodingService,
20
31
  GlobalSearchService,
21
32
  GroupBuilder,
22
33
  InvalidPathError,
23
34
  InverseTableTabConfig,
24
35
  MaxDepthExceededError,
36
+ NodePositionSchema,
25
37
  NoopCacheAdapter,
26
38
  NoopGeocodingAdapter,
27
39
  NoopHookRegistry,
@@ -32,7 +44,11 @@ import {
32
44
  ObjectNotFoundError,
33
45
  ObjectReferencedError,
34
46
  ObjectSchemaService,
47
+ ParticipantAuthConfigSchema,
48
+ ParticipantTemplateSchema,
49
+ ParticipationTokenService,
35
50
  PermissionService,
51
+ PinCodeService,
36
52
  PolicyRegistry,
37
53
  PolicyViolationError,
38
54
  ProtectedResourceError,
@@ -55,32 +71,66 @@ import {
55
71
  SYSTEM_FIELD_NAMES,
56
72
  SchemaError,
57
73
  SchemaErrorCode,
74
+ SlotModeSchema,
75
+ StartExecutor,
76
+ StartNodeSchema,
58
77
  SyncError,
59
78
  TabBuilder,
60
79
  TenantAwareRepository,
61
80
  TenantAwareService,
62
81
  TenantContextError,
82
+ ThemeColorsSchema,
83
+ ThemeLogoSchema,
63
84
  UserProfileNotFoundError,
64
85
  UserProfileService,
65
86
  UserService,
66
87
  ValidationError,
67
88
  ViewBuilder,
68
89
  ViewService,
90
+ ViewportSchema,
91
+ WorkflowBuilder,
92
+ WorkflowConditionBuilder,
93
+ WorkflowConfigSchema,
94
+ WorkflowDefinitionSchema,
95
+ WorkflowEndBuilder,
96
+ WorkflowFormBuilder,
97
+ WorkflowFormRowBuilder,
98
+ WorkflowInstanceService,
99
+ WorkflowLayoutSchema,
100
+ WorkflowNodeSchema,
101
+ WorkflowParticipantBuilder,
102
+ WorkflowParticipationService,
103
+ WorkflowRelationService,
104
+ WorkflowService,
105
+ WorkflowSimpleFormBuilder,
106
+ WorkflowSlotSchema,
107
+ WorkflowStartBuilder,
108
+ WorkflowStatusSchema,
109
+ WorkflowThemeSchema,
110
+ and,
69
111
  asTenantId,
70
112
  asUserId,
71
113
  attributeConfigSchemas,
72
114
  buildAuditChanges,
73
115
  cacheKeys,
74
116
  cacheTtl,
117
+ canAuthenticate,
118
+ canExecuteNode,
119
+ canParticipate,
120
+ canResumeInstance,
75
121
  checkbox,
76
122
  checkboxConfigSchema,
123
+ complete,
124
+ computeLabelWithRelations,
77
125
  computeRecordStatus,
78
126
  createAttributeValidator,
79
127
  createCheckboxValidator,
80
128
  createCurrencyValidator,
81
129
  createDateValidator,
130
+ createDefaultExecutorRegistry,
82
131
  createDefaultState,
83
132
  createDraftValidator,
133
+ createEmptyContext,
84
134
  createFileValidator,
85
135
  createFormAttributeValidator,
86
136
  createFormulaValidator,
@@ -98,6 +148,7 @@ import {
98
148
  createRollupValidator,
99
149
  createSelectValidator,
100
150
  createSingleRelationValidator,
151
+ createStartTransition,
101
152
  createStatusValidator,
102
153
  createTextAreaValidator,
103
154
  createTextValidator,
@@ -108,30 +159,41 @@ import {
108
159
  dateConfigSchema,
109
160
  defaultPolicyRegistry,
110
161
  enrichValuesWithSelectLabels,
162
+ eq,
163
+ error,
164
+ evaluate,
165
+ evaluateCondition,
111
166
  evaluateFormula,
112
167
  evaluateFormulaAttribute,
113
168
  evaluateFormulaAttributeWithRelations,
114
169
  evaluateFormulaWithRelations,
115
170
  evaluateFormulaWithResult,
171
+ evaluateWithTrace,
116
172
  extractAttributeNames,
117
173
  extractFormulaVariables,
174
+ extractRelationIds,
118
175
  extractRelationNames,
119
176
  extractRelationReferences,
120
177
  file,
121
178
  fileConfigSchema,
122
179
  flattenRelationsForEval,
123
- flow,
124
180
  formatAttributeValue,
125
181
  formatFormulaResult,
126
182
  formatRecord,
127
183
  formatRecords,
128
184
  formula,
129
185
  formulaConfigSchema,
186
+ generateCssVariables,
130
187
  generateId,
131
188
  generatePrefixedId,
132
189
  getAttributeConfigSchema,
133
190
  getContext,
191
+ getContextValue,
192
+ getDefaultExecutorRegistry,
193
+ getDefaultPinCodeService,
194
+ getDefaultTokenService,
134
195
  getMissingRequiredAttributes,
196
+ getNodeOutputs,
135
197
  getPathDepth,
136
198
  getRelationPath,
137
199
  getSyncPreview,
@@ -143,24 +205,51 @@ import {
143
205
  group,
144
206
  hasContext,
145
207
  hasRelationReferences,
208
+ inValues,
209
+ initializePinCodeService,
210
+ initializeTokenService,
211
+ isAdvancedFormNode,
212
+ isConditionGroup,
213
+ isConditionNode,
214
+ isConditionRule,
215
+ isEmpty,
216
+ isEndNode,
146
217
  isForbiddenError,
218
+ isFormNode,
219
+ isInstanceEvent,
220
+ isInstanceTerminal,
221
+ isInstanceWaiting,
147
222
  isLabelExpression,
223
+ isNodeEvent,
224
+ isNotEmpty,
148
225
  isNotFoundError,
226
+ isParticipationEvent,
227
+ isPinCodeAuth,
149
228
  isProtectedResourceError,
150
229
  isRecordComplete,
151
230
  isSchemaError,
231
+ isSignedLinkAuth,
232
+ isSimpleFormNode,
233
+ isStartNode,
152
234
  isSystemAttribute,
153
235
  isSystemAttributeObject,
236
+ isSystemWorkflow,
154
237
  isUniversalRelation,
155
238
  isValidationError,
239
+ isWorkflowDefinition,
240
+ isWorkflowPublished,
156
241
  location,
157
242
  locationConfigSchema,
243
+ mergeFormToSlot,
244
+ mergeWithDefaults,
158
245
  multiselect,
159
246
  multiselectConfigSchema,
247
+ neq,
160
248
  notesPolicy,
161
249
  number,
162
250
  numberConfigSchema,
163
251
  object,
252
+ or,
164
253
  parseAttributeConfig,
165
254
  parsePath,
166
255
  pathHasManyCardinality,
@@ -182,8 +271,10 @@ import {
182
271
  safeParseAttributeConfig,
183
272
  select,
184
273
  selectConfigSchema,
274
+ setContextValue,
185
275
  status,
186
276
  statusConfigSchema,
277
+ success,
187
278
  syncAll,
188
279
  syncNativeObjects,
189
280
  syncNativeViews,
@@ -205,8 +296,10 @@ import {
205
296
  verifyNativeObjectsSync,
206
297
  verifyNativeViewsSync,
207
298
  view,
208
- withTenantContext
209
- } from "./chunk-OXPVVEZS.mjs";
299
+ wait,
300
+ withTenantContext,
301
+ workflow
302
+ } from "./chunk-RYBKW22L.mjs";
210
303
  import {
211
304
  ALL_SYSTEM_RESOURCES,
212
305
  DEFAULT_ROLES,
@@ -325,11 +418,11 @@ function isNoValueOperator(operator) {
325
418
  function isFlowDefinition(obj) {
326
419
  return typeof obj === "object" && obj !== null && "slots" in obj && "pages" in obj && "relations" in obj && "status" in obj;
327
420
  }
328
- function isFlowPublished(flow2) {
329
- return flow2.status === "published";
421
+ function isFlowPublished(flow) {
422
+ return flow.status === "published";
330
423
  }
331
- function isSystemFlow(flow2) {
332
- return flow2.system === true;
424
+ function isSystemFlow(flow) {
425
+ return flow.system === true;
333
426
  }
334
427
 
335
428
  // src/types/views.ts
@@ -354,6 +447,9 @@ function isActivityTab(tab) {
354
447
  function isNotesTab(tab) {
355
448
  return tab.type === "notes";
356
449
  }
450
+ function isFlowsTab(tab) {
451
+ return tab.type === "flows";
452
+ }
357
453
 
358
454
  // src/native/notes.ts
359
455
  var NOTES = object({ name: "notes", label: "Note" }).pluralLabel("Notes").icon("file-text").description("Notes that can be linked to any record or used globally").system().labelExpression("{{ title }}").attribute(text({ name: "title", label: "Title" }).placeholder("Untitled").required()).attribute(richtext({ name: "content", label: "Content" }).required()).attribute(
@@ -507,23 +603,34 @@ export {
507
603
  AttributeInUseError,
508
604
  AttributeNotFoundError,
509
605
  AuditService,
606
+ ConditionExecutor,
607
+ ConditionGroupSchema,
608
+ ConditionNodeSchema,
609
+ ConditionOperatorSchema,
610
+ ConditionRuleSchema,
510
611
  CustomTabConfig,
511
612
  DEFAULT_LABEL_FALLBACK,
512
613
  DEFAULT_ROLES,
513
614
  DEFAULT_ROLE_DESCRIPTIONS,
514
615
  DEFAULT_ROLE_LABELS,
515
616
  DEFAULT_ROLE_PERMISSIONS,
617
+ DEFAULT_THEME,
516
618
  DEFAULT_VALIDATION_MESSAGES,
517
619
  DirectTableTabConfig,
518
620
  DuplicateError,
519
621
  EMPTY_VALUE_PLACEHOLDER,
622
+ EndExecutor,
623
+ EndNodeSchema,
624
+ ExecutorRegistry,
520
625
  FileNotFoundError,
521
626
  FileService,
522
- FlowBuilder,
523
- FlowPageBuilder,
524
- FlowRowBuilder,
525
- FlowService,
627
+ FlowRowFieldSchema,
628
+ FlowRowSchema,
629
+ FlowsTabConfig,
526
630
  ForbiddenError,
631
+ FormExecutor,
632
+ FormFieldRefSchema,
633
+ FormNodeSchema,
527
634
  GeocodingService,
528
635
  GlobalSearchService,
529
636
  GroupBuilder,
@@ -532,6 +639,7 @@ export {
532
639
  MaxDepthExceededError,
533
640
  NOTES,
534
641
  NO_VALUE_OPERATORS,
642
+ NodePositionSchema,
535
643
  NoopCacheAdapter,
536
644
  NoopGeocodingAdapter,
537
645
  NoopHookRegistry,
@@ -543,7 +651,11 @@ export {
543
651
  ObjectNotFoundError,
544
652
  ObjectReferencedError,
545
653
  ObjectSchemaService,
654
+ ParticipantAuthConfigSchema,
655
+ ParticipantTemplateSchema,
656
+ ParticipationTokenService,
546
657
  PermissionService,
658
+ PinCodeService,
547
659
  PolicyRegistry,
548
660
  PolicyViolationError,
549
661
  ProtectedResourceError,
@@ -568,32 +680,66 @@ export {
568
680
  SYSTEM_RESOURCE_LABELS,
569
681
  SchemaError,
570
682
  SchemaErrorCode,
683
+ SlotModeSchema,
684
+ StartExecutor,
685
+ StartNodeSchema,
571
686
  SyncError,
572
687
  TabBuilder,
573
688
  TenantAwareRepository,
574
689
  TenantAwareService,
575
690
  TenantContextError,
691
+ ThemeColorsSchema,
692
+ ThemeLogoSchema,
576
693
  UserProfileNotFoundError,
577
694
  UserProfileService,
578
695
  UserService,
579
696
  ValidationError,
580
697
  ViewBuilder,
581
698
  ViewService,
699
+ ViewportSchema,
700
+ WorkflowBuilder,
701
+ WorkflowConditionBuilder,
702
+ WorkflowConfigSchema,
703
+ WorkflowDefinitionSchema,
704
+ WorkflowEndBuilder,
705
+ WorkflowFormBuilder,
706
+ WorkflowFormRowBuilder,
707
+ WorkflowInstanceService,
708
+ WorkflowLayoutSchema,
709
+ WorkflowNodeSchema,
710
+ WorkflowParticipantBuilder,
711
+ WorkflowParticipationService,
712
+ WorkflowRelationService,
713
+ WorkflowService,
714
+ WorkflowSimpleFormBuilder,
715
+ WorkflowSlotSchema,
716
+ WorkflowStartBuilder,
717
+ WorkflowStatusSchema,
718
+ WorkflowThemeSchema,
719
+ and,
582
720
  asTenantId,
583
721
  asUserId,
584
722
  attributeConfigSchemas,
585
723
  buildAuditChanges,
586
724
  cacheKeys,
587
725
  cacheTtl,
726
+ canAuthenticate,
727
+ canExecuteNode,
728
+ canParticipate,
729
+ canResumeInstance,
588
730
  checkbox,
589
731
  checkboxConfigSchema,
732
+ complete,
733
+ computeLabelWithRelations,
590
734
  computeRecordStatus,
591
735
  createAttributeValidator,
592
736
  createCheckboxValidator,
593
737
  createCurrencyValidator,
594
738
  createDateValidator,
739
+ createDefaultExecutorRegistry,
595
740
  createDefaultState,
596
741
  createDraftValidator,
742
+ createEmptyContext,
597
743
  createFileValidator,
598
744
  createFormAttributeValidator,
599
745
  createFormulaValidator,
@@ -611,6 +757,7 @@ export {
611
757
  createRollupValidator,
612
758
  createSelectValidator,
613
759
  createSingleRelationValidator,
760
+ createStartTransition,
614
761
  createStatusValidator,
615
762
  createTextAreaValidator,
616
763
  createTextValidator,
@@ -621,30 +768,41 @@ export {
621
768
  dateConfigSchema,
622
769
  defaultPolicyRegistry,
623
770
  enrichValuesWithSelectLabels,
771
+ eq,
772
+ error,
773
+ evaluate,
774
+ evaluateCondition,
624
775
  evaluateFormula,
625
776
  evaluateFormulaAttribute,
626
777
  evaluateFormulaAttributeWithRelations,
627
778
  evaluateFormulaWithRelations,
628
779
  evaluateFormulaWithResult,
780
+ evaluateWithTrace,
629
781
  extractAttributeNames,
630
782
  extractFormulaVariables,
783
+ extractRelationIds,
631
784
  extractRelationNames,
632
785
  extractRelationReferences,
633
786
  file,
634
787
  fileConfigSchema,
635
788
  flattenRelationsForEval,
636
- flow,
637
789
  formatAttributeValue,
638
790
  formatFormulaResult,
639
791
  formatRecord,
640
792
  formatRecords,
641
793
  formula,
642
794
  formulaConfigSchema,
795
+ generateCssVariables,
643
796
  generateId,
644
797
  generatePrefixedId,
645
798
  getAttributeConfigSchema,
646
799
  getContext,
800
+ getContextValue,
801
+ getDefaultExecutorRegistry,
802
+ getDefaultPinCodeService,
803
+ getDefaultTokenService,
647
804
  getMissingRequiredAttributes,
805
+ getNodeOutputs,
648
806
  getPathDepth,
649
807
  getRelationPath,
650
808
  getSyncPreview,
@@ -656,37 +814,65 @@ export {
656
814
  group,
657
815
  hasContext,
658
816
  hasRelationReferences,
817
+ inValues,
818
+ initializePinCodeService,
819
+ initializeTokenService,
659
820
  isActivityTab,
660
821
  isAdvancedFilterState,
822
+ isAdvancedFormNode,
823
+ isConditionGroup,
824
+ isConditionNode,
825
+ isConditionRule,
661
826
  isCustomTab,
662
827
  isDefaultRole,
663
828
  isDirectTableTab,
829
+ isEmpty,
830
+ isEndNode,
664
831
  isFlowDefinition,
665
832
  isFlowPublished,
833
+ isFlowsTab,
666
834
  isForbiddenError,
835
+ isFormNode,
667
836
  isFormTab,
837
+ isInstanceEvent,
838
+ isInstanceTerminal,
839
+ isInstanceWaiting,
668
840
  isInverseTableTab,
669
841
  isLabelExpression,
670
842
  isNoValueOperator,
843
+ isNodeEvent,
844
+ isNotEmpty,
671
845
  isNotFoundError,
672
846
  isNotesTab,
847
+ isParticipationEvent,
848
+ isPinCodeAuth,
673
849
  isProtectedResourceError,
674
850
  isRecordComplete,
675
851
  isSchemaError,
852
+ isSignedLinkAuth,
853
+ isSimpleFormNode,
854
+ isStartNode,
676
855
  isSystemAttribute,
677
856
  isSystemAttributeObject,
678
857
  isSystemFlow,
858
+ isSystemWorkflow,
679
859
  isTableTab,
680
860
  isUniversalRelation,
681
861
  isValidationError,
862
+ isWorkflowDefinition,
863
+ isWorkflowPublished,
682
864
  location,
683
865
  locationConfigSchema,
866
+ mergeFormToSlot,
867
+ mergeWithDefaults,
684
868
  multiselect,
685
869
  multiselectConfigSchema,
870
+ neq,
686
871
  notesPolicy,
687
872
  number,
688
873
  numberConfigSchema,
689
874
  object,
875
+ or,
690
876
  parseAttributeConfig,
691
877
  parsePath,
692
878
  pathHasManyCardinality,
@@ -708,8 +894,10 @@ export {
708
894
  safeParseAttributeConfig,
709
895
  select,
710
896
  selectConfigSchema,
897
+ setContextValue,
711
898
  status,
712
899
  statusConfigSchema,
900
+ success,
713
901
  syncAll,
714
902
  syncNativeObjects,
715
903
  syncNativeViews,
@@ -734,5 +922,7 @@ export {
734
922
  verifyNativeViewsSync,
735
923
  view,
736
924
  viewRegistry,
737
- withTenantContext
925
+ wait,
926
+ withTenantContext,
927
+ workflow
738
928
  };