@nocobase/plugin-flow-engine 2.2.0-beta.1 → 2.2.0-beta.10

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 (70) hide show
  1. package/dist/client/index.js +1 -1
  2. package/dist/externalVersion.js +9 -9
  3. package/dist/locale/en-US.json +1 -0
  4. package/dist/locale/index.d.ts +2 -0
  5. package/dist/locale/zh-CN.json +1 -0
  6. package/dist/node_modules/@ant-design/icons-svg/package.json +1 -1
  7. package/dist/node_modules/acorn/package.json +1 -1
  8. package/dist/node_modules/acorn-jsx/package.json +1 -1
  9. package/dist/node_modules/acorn-walk/package.json +1 -1
  10. package/dist/node_modules/ses/package.json +1 -1
  11. package/dist/node_modules/zod/package.json +1 -1
  12. package/dist/server/flow-surfaces/{runjs-authoring/blocked-global-stop/index.d.ts → approval/authoring-validation.d.ts} +1 -2
  13. package/dist/server/flow-surfaces/approval/authoring-validation.js +1151 -0
  14. package/dist/server/flow-surfaces/approval/blueprint-service.js +2 -0
  15. package/dist/server/flow-surfaces/authoring-validation.d.ts +2 -1
  16. package/dist/server/flow-surfaces/authoring-validation.js +495 -57
  17. package/dist/server/flow-surfaces/blueprint/compile-plan.js +19 -15
  18. package/dist/server/flow-surfaces/blueprint/export-document.d.ts +50 -0
  19. package/dist/server/flow-surfaces/blueprint/export-document.js +2510 -0
  20. package/dist/server/flow-surfaces/blueprint/normalize-document.js +2 -1
  21. package/dist/server/flow-surfaces/blueprint/public-types.d.ts +1 -0
  22. package/dist/server/flow-surfaces/builder.js +40 -5
  23. package/dist/server/flow-surfaces/catalog.js +13 -2
  24. package/dist/server/flow-surfaces/configure-options.js +5 -3
  25. package/dist/server/flow-surfaces/constants.d.ts +9 -2
  26. package/dist/server/flow-surfaces/constants.js +1 -0
  27. package/dist/server/flow-surfaces/contract-guard.js +24 -2
  28. package/dist/server/flow-surfaces/default-action-popup.d.ts +2 -0
  29. package/dist/server/flow-surfaces/default-action-popup.js +27 -13
  30. package/dist/server/flow-surfaces/filter-group.d.ts +19 -2
  31. package/dist/server/flow-surfaces/filter-group.js +232 -3
  32. package/dist/server/flow-surfaces/planning/compiler.d.ts +1 -0
  33. package/dist/server/flow-surfaces/planning/compiler.js +205 -82
  34. package/dist/server/flow-surfaces/planning/key-registry.d.ts +1 -1
  35. package/dist/server/flow-surfaces/planning/runtime.js +1 -0
  36. package/dist/server/flow-surfaces/planning/step-link.d.ts +1 -1
  37. package/dist/server/flow-surfaces/planning/step-link.js +22 -3
  38. package/dist/server/flow-surfaces/public-data-surface-default-filter.js +0 -9
  39. package/dist/server/flow-surfaces/reaction/field-value.d.ts +9 -0
  40. package/dist/server/flow-surfaces/reaction/field-value.js +51 -2
  41. package/dist/server/flow-surfaces/reaction/linkage.d.ts +6 -1
  42. package/dist/server/flow-surfaces/reaction/linkage.js +18 -3
  43. package/dist/server/flow-surfaces/reaction/meta.js +19 -1
  44. package/dist/server/flow-surfaces/reaction/types.d.ts +19 -0
  45. package/dist/server/flow-surfaces/relation-backing-foreign-key.d.ts +10 -0
  46. package/dist/server/flow-surfaces/relation-backing-foreign-key.js +79 -0
  47. package/dist/server/flow-surfaces/runjs-authoring/ast/source.d.ts +1 -0
  48. package/dist/server/flow-surfaces/runjs-authoring/ast/source.js +20 -0
  49. package/dist/server/flow-surfaces/runjs-authoring/rules.js +0 -2
  50. package/dist/server/flow-surfaces/runjs-authoring/runtime/constants.d.ts +0 -1
  51. package/dist/server/flow-surfaces/runjs-authoring/runtime/constants.js +11 -19
  52. package/dist/server/flow-surfaces/runjs-authoring/runtime/types.d.ts +0 -12
  53. package/dist/server/flow-surfaces/runjs-authoring/scan/filter.js +12 -2
  54. package/dist/server/flow-surfaces/runjs-authoring/scan/index.d.ts +0 -14
  55. package/dist/server/flow-surfaces/runjs-authoring/scan/index.js +10 -8
  56. package/dist/server/flow-surfaces/runjs-authoring/scan/source-patterns.d.ts +0 -14
  57. package/dist/server/flow-surfaces/runjs-authoring/scan/source-patterns.js +18 -73
  58. package/dist/server/flow-surfaces/runjs-authoring/types.d.ts +1 -1
  59. package/dist/server/flow-surfaces/runjs-authoring/validators/index.js +9 -53
  60. package/dist/server/flow-surfaces/service.d.ts +53 -0
  61. package/dist/server/flow-surfaces/service.js +990 -122
  62. package/dist/server/flow-surfaces/types.d.ts +2 -1
  63. package/dist/server/variables/registry.js +3 -0
  64. package/dist/swagger/flow-surfaces.d.ts +193 -0
  65. package/dist/swagger/flow-surfaces.examples.d.ts +11 -0
  66. package/dist/swagger/flow-surfaces.examples.js +11 -0
  67. package/dist/swagger/flow-surfaces.js +179 -10
  68. package/dist/swagger/index.d.ts +193 -0
  69. package/package.json +2 -2
  70. package/dist/server/flow-surfaces/runjs-authoring/blocked-global-stop/index.js +0 -40
@@ -43,7 +43,7 @@ var import_filter = require("./filter");
43
43
  var import_constants = require("../runtime/constants");
44
44
  function scanJavaScriptSource(source, ast, context = {}, modelUse = "") {
45
45
  const masked = (0, import_source.maskJavaScriptSource)(source);
46
- const functionRanges = (0, import_source.findFunctionRanges)(masked);
46
+ const functionRanges = collectScanFunctionRanges(masked, ast);
47
47
  const blockRanges = (0, import_source.collectBraceRanges)(masked);
48
48
  const staticBlockRanges = (0, import_source.collectStaticBlockRanges)(masked);
49
49
  const sourceBindings = (0, import_bindings.collectSourceBindings)(masked, functionRanges, blockRanges, staticBlockRanges);
@@ -71,10 +71,7 @@ function scanJavaScriptSource(source, ast, context = {}, modelUse = "") {
71
71
  const flowResourceAliases = (0, import_source_patterns.collectFlowResourceAliases)(masked, sourceBindings);
72
72
  const directDomWrites = (0, import_source_patterns.collectDirectDomWrites)(source, masked, sourceBindings);
73
73
  const directDomAliases = (0, import_source_patterns.collectDirectDomAliases)(masked, sourceBindings);
74
- const windowDocumentNavigatorUses = (0, import_source_patterns.collectWindowDocumentNavigatorUses)(source, masked, sourceBindings);
75
- const windowDocumentNavigatorAliases = (0, import_source_patterns.collectWindowDocumentNavigatorAliases)(masked, sourceBindings);
76
74
  const ctxAliases = (0, import_source_patterns.collectCtxAliases)(masked, sourceBindings);
77
- const forbiddenBareGlobals = (0, import_source_patterns.collectForbiddenBareGlobals)(masked, sourceBindings);
78
75
  return {
79
76
  source,
80
77
  masked,
@@ -126,19 +123,24 @@ function scanJavaScriptSource(source, ast, context = {}, modelUse = "") {
126
123
  ),
127
124
  directDomWrites,
128
125
  directDomAliases,
129
- windowDocumentNavigatorUses,
130
- windowDocumentNavigatorAliases,
131
126
  ctxAliases,
132
127
  ctxLibMemberCaseMismatches: (0, import_source_patterns.collectCtxLibMemberCaseMismatches)(source, masked, sourceBindings),
133
128
  invalidCtxApiMemberAccesses: (astInspection == null ? void 0 : astInspection.invalidCtxApiMemberAccesses) || [],
134
129
  invalidCtxNonFunctionCalls: (astInspection == null ? void 0 : astInspection.invalidCtxNonFunctionCalls) || [],
135
130
  invalidCtxLibMemberAccesses: (astInspection == null ? void 0 : astInspection.invalidCtxLibMemberAccesses) || [],
136
- forbiddenBareGlobals,
137
131
  ctxMemberAccesses: (0, import_source_patterns.collectCtxMemberAccesses)(masked, sourceBindings),
138
132
  dynamicCtxAccesses: (0, import_static_values.findUnboundCtxMatches)(masked, /\bctx\s*(?:\?\.\s*)?\[/g, sourceBindings),
139
133
  isTopLevelFunctionWrapper: (0, import_source_patterns.isTopLevelFunctionWrapper)(masked, functionRanges, topLevelReachableCtxRenderCalls)
140
134
  };
141
135
  }
136
+ function collectScanFunctionRanges(masked, ast) {
137
+ if (!ast) {
138
+ return (0, import_source.findFunctionRanges)(masked);
139
+ }
140
+ const ranges = (0, import_source.collectAstFunctionBodyRanges)(ast);
141
+ (0, import_source.collectArrowExpressionRanges)(masked, ranges);
142
+ return (0, import_source.mergeRanges)(ranges);
143
+ }
142
144
  function collectAstUnknownBareGlobalsFromAst(ast, identifierBindings, modelUse) {
143
145
  var _a;
144
146
  const allowedGlobals = new Set(import_constants.RUNJS_ALLOWED_BARE_GLOBALS);
@@ -151,7 +153,7 @@ function collectAstUnknownBareGlobalsFromAst(ast, identifierBindings, modelUse)
151
153
  if (!name) {
152
154
  return;
153
155
  }
154
- if (allowedGlobals.has(name) || import_constants.FORBIDDEN_BARE_GLOBALS.has(name)) {
156
+ if (allowedGlobals.has(name)) {
155
157
  return;
156
158
  }
157
159
  const index = typeof node.start === "number" ? node.start : 0;
@@ -7,10 +7,6 @@
7
7
  * For more information, please refer to: https://www.nocobase.com/agreement.
8
8
  */
9
9
  import type { CtxLibMemberCaseMismatch, FlowResourceAlias, ReactComponentAlias, ResourceCallInReactHook, SourceBinding, SourceRange, StringLiteralBinding } from '../internal-types';
10
- export declare function collectForbiddenBareGlobals(masked: string, bindings: SourceBinding[]): {
11
- name: string;
12
- index: number;
13
- }[];
14
10
  export declare function collectInvalidApiResourceCalls(source: string, masked: string, bindings: SourceBinding[]): {
15
11
  index: number;
16
12
  match: string;
@@ -64,16 +60,6 @@ export declare function collectDirectDomWrites(source: string, masked: string, b
64
60
  index: number;
65
61
  match: string;
66
62
  }[];
67
- export declare function collectWindowDocumentNavigatorUses(source: string, masked: string, bindings: SourceBinding[]): {
68
- root: string;
69
- member: string;
70
- index: number;
71
- }[];
72
- export declare function collectWindowDocumentNavigatorAliases(masked: string, bindings: SourceBinding[]): {
73
- alias: string;
74
- root: string;
75
- index: number;
76
- }[];
77
63
  export declare function collectDirectDomAliases(masked: string, bindings: SourceBinding[]): {
78
64
  alias: string;
79
65
  index: number;
@@ -33,7 +33,6 @@ __export(source_patterns_exports, {
33
33
  collectDirectDomAliases: () => collectDirectDomAliases,
34
34
  collectDirectDomWrites: () => collectDirectDomWrites,
35
35
  collectFlowResourceAliases: () => collectFlowResourceAliases,
36
- collectForbiddenBareGlobals: () => collectForbiddenBareGlobals,
37
36
  collectInvalidApiResourceCalls: () => collectInvalidApiResourceCalls,
38
37
  collectInvalidFlowResourceListCalls: () => collectInvalidFlowResourceListCalls,
39
38
  collectInvalidResourceTypeCalls: () => collectInvalidResourceTypeCalls,
@@ -43,8 +42,6 @@ __export(source_patterns_exports, {
43
42
  collectReactHookCalls: () => collectReactHookCalls,
44
43
  collectResourceCallsInReactHooks: () => collectResourceCallsInReactHooks,
45
44
  collectUnboundReactCreateElementCalls: () => collectUnboundReactCreateElementCalls,
46
- collectWindowDocumentNavigatorAliases: () => collectWindowDocumentNavigatorAliases,
47
- collectWindowDocumentNavigatorUses: () => collectWindowDocumentNavigatorUses,
48
45
  getResourceLikeCtxRunjsEntrypoint: () => getResourceLikeCtxRunjsEntrypoint,
49
46
  isResourceLikeCtxRequest: () => isResourceLikeCtxRequest,
50
47
  isTopLevelFunctionWrapper: () => isTopLevelFunctionWrapper
@@ -53,18 +50,6 @@ module.exports = __toCommonJS(source_patterns_exports);
53
50
  var import_constants = require("../runtime/constants");
54
51
  var import_bindings = require("../ast/bindings");
55
52
  var import_source = require("../ast/source");
56
- function collectForbiddenBareGlobals(masked, bindings) {
57
- const entries = [];
58
- for (const name of import_constants.FORBIDDEN_BARE_GLOBALS) {
59
- const pattern = new RegExp(`(?<![.$\\w])${(0, import_source.escapeRegExp)(name)}\\b`, "g");
60
- for (const match of masked.matchAll(pattern)) {
61
- if (!(0, import_bindings.isNameBoundAtIndex)(bindings, name, match.index || 0) && !isObjectPropertyKey(masked, match.index || 0, name)) {
62
- entries.push({ name, index: match.index || 0 });
63
- }
64
- }
65
- }
66
- return entries.sort((left, right) => left.index - right.index);
67
- }
68
53
  function collectInvalidApiResourceCalls(source, masked, bindings) {
69
54
  var _a, _b, _c, _d, _e, _f, _g, _h;
70
55
  const resourceMethods = /* @__PURE__ */ new Set(["list", "get", "create", "update", "destroy"]);
@@ -618,6 +603,16 @@ function collectDirectDomWrites(source, masked, bindings) {
618
603
  }
619
604
  entries.push({ index, match: match[0].replace(/\s*(?:\?\.)?\($/, "") });
620
605
  }
606
+ for (const match of masked.matchAll(
607
+ /\b(document)\s*(?:\?\.|\.)\s*body\s*(?:\?\.|\.)\s*(innerHTML|insertAdjacentHTML)\b|(?<![.$\w])((window|globalThis)\s*(?:\?\.|\.)\s*document)\s*(?:\?\.|\.)\s*body\s*(?:\?\.|\.)\s*(innerHTML|insertAdjacentHTML)\b/g
608
+ )) {
609
+ const index = match.index || 0;
610
+ const root = match[1] || match[4];
611
+ if (root && (0, import_bindings.isNameBoundAtIndex)(bindings, root, index)) {
612
+ continue;
613
+ }
614
+ entries.push({ index, match: match[0] });
615
+ }
621
616
  for (const match of commentMasked.matchAll(
622
617
  /\b(ctx)\s*(?:\?\.|\.)\s*element\s*(?:\?\.\s*)?\[\s*(?:(['"])([A-Za-z_$][\w$]*)\2|([^\]]+))\s*\]/g
623
618
  )) {
@@ -639,71 +634,24 @@ function collectDirectDomWrites(source, masked, bindings) {
639
634
  }
640
635
  }
641
636
  for (const match of commentMasked.matchAll(
642
- /\b(element)\s*(?:\?\.\s*)?\[\s*(?:(['"])([A-Za-z_$][\w$]*)\2|([^\]]+))\s*\]/g
637
+ /(?<![.$\w])(window|globalThis)\s*(?:\?\.\s*)?\[\s*(['"])document\2\s*\]\s*(?:(?:\?\.|\.)\s*createElement|(?:\?\.\s*)?\[\s*(['"])createElement\3\s*\])/g
643
638
  )) {
644
639
  const index = match.index || 0;
645
- const member = match[3] || "";
646
- const dynamicMember = Boolean(match[4]);
647
- if (isCodeTokenAt(masked, index, match[1]) && !(0, import_bindings.isNameBoundAtIndex)(bindings, match[1], index) && (dynamicMember || isDirectDomMember(member))) {
640
+ if (isCodeTokenAt(masked, index, match[1]) && !(0, import_bindings.isNameBoundAtIndex)(bindings, match[1], index)) {
648
641
  entries.push({ index, match: match[0] });
649
642
  }
650
643
  }
651
- return entries;
652
- }
653
- function collectWindowDocumentNavigatorUses(source, masked, bindings) {
654
- const commentMasked = (0, import_source.maskJavaScriptComments)(source);
655
- const entries = [...masked.matchAll(/\b(window|document|navigator)\s*(?:\?\.|\.)\s*([A-Za-z_$][\w$]*)/g)].filter((match) => !(0, import_bindings.isNameBoundAtIndex)(bindings, match[1], match.index || 0)).map((match) => ({
656
- root: match[1],
657
- member: match[2],
658
- index: match.index || 0
659
- }));
660
644
  for (const match of commentMasked.matchAll(
661
- /\b(window|document|navigator)\s*(?:\?\.\s*)?\[\s*(?:(['"])([A-Za-z_$][\w$]*)\2|([^\]]+))\s*\]/g
645
+ /\b(element)\s*(?:\?\.\s*)?\[\s*(?:(['"])([A-Za-z_$][\w$]*)\2|([^\]]+))\s*\]/g
662
646
  )) {
663
647
  const index = match.index || 0;
664
- const root = match[1];
665
- if (!isCodeTokenAt(masked, index, root) || (0, import_bindings.isNameBoundAtIndex)(bindings, root, index)) {
666
- continue;
667
- }
668
- entries.push({
669
- root,
670
- member: match[3] || "[dynamic]",
671
- index
672
- });
673
- }
674
- return entries.sort((left, right) => left.index - right.index);
675
- }
676
- function collectWindowDocumentNavigatorAliases(masked, bindings) {
677
- const entries = [];
678
- collectAliasMatches(
679
- masked,
680
- [
681
- /\b(?:const|let|var)\s+([A-Za-z_$][\w$]*)\s*=\s*(window|document|navigator)\b/g,
682
- /(?<![.$\w])([A-Za-z_$][\w$]*)\s*=\s*(window|document|navigator)\b/g
683
- ],
684
- (match) => {
685
- const alias = match[1];
686
- const root = match[2];
687
- const rootIndex = (match.index || 0) + match[0].lastIndexOf(root);
688
- if (alias === root || (0, import_bindings.isNameBoundAtIndex)(bindings, root, rootIndex)) {
689
- return;
690
- }
691
- entries.push({ alias, root, index: rootIndex });
692
- }
693
- );
694
- for (const match of masked.matchAll(
695
- /\b(?:const|let|var)\s*\{([^}]*)\}\s*=\s*(window|document|navigator)\b(?!\s*(?:\.|\?\.))/g
696
- )) {
697
- const root = match[2];
698
- const rootIndex = (match.index || 0) + match[0].lastIndexOf(root);
699
- if ((0, import_bindings.isNameBoundAtIndex)(bindings, root, rootIndex)) {
700
- continue;
648
+ const member = match[3] || "";
649
+ const dynamicMember = Boolean(match[4]);
650
+ if (isCodeTokenAt(masked, index, match[1]) && !(0, import_bindings.isNameBoundAtIndex)(bindings, match[1], index) && (dynamicMember || isDirectDomMember(member))) {
651
+ entries.push({ index, match: match[0] });
701
652
  }
702
- collectObjectBindingAliases(match[1]).forEach((alias) => {
703
- entries.push({ alias, root, index: rootIndex });
704
- });
705
653
  }
706
- return dedupeAliasEntries(entries);
654
+ return entries;
707
655
  }
708
656
  function collectDirectDomAliases(masked, bindings) {
709
657
  const entries = [];
@@ -871,7 +819,6 @@ function isResourceLikeRunjsEntrypointExpression(value) {
871
819
  collectDirectDomAliases,
872
820
  collectDirectDomWrites,
873
821
  collectFlowResourceAliases,
874
- collectForbiddenBareGlobals,
875
822
  collectInvalidApiResourceCalls,
876
823
  collectInvalidFlowResourceListCalls,
877
824
  collectInvalidResourceTypeCalls,
@@ -881,8 +828,6 @@ function isResourceLikeRunjsEntrypointExpression(value) {
881
828
  collectReactHookCalls,
882
829
  collectResourceCallsInReactHooks,
883
830
  collectUnboundReactCreateElementCalls,
884
- collectWindowDocumentNavigatorAliases,
885
- collectWindowDocumentNavigatorUses,
886
831
  getResourceLikeCtxRunjsEntrypoint,
887
832
  isResourceLikeCtxRequest,
888
833
  isTopLevelFunctionWrapper
@@ -6,7 +6,7 @@
6
6
  * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
7
  * For more information, please refer to: https://www.nocobase.com/agreement.
8
8
  */
9
- export type RunJsAuthoringRepairClass = 'syntax-stop' | 'nested-runjs-stop' | 'source-limit-stop' | 'switch-to-resource-api' | 'missing-top-level-return' | 'value-surface-forbids-render' | 'unknown-surface-stop' | 'unknown-model-stop' | 'replace-innerhtml-with-render' | 'render-top-level-function-wrapper' | 'render-unreachable-render-call' | 'blocked-global-stop' | 'unknown-global-stop' | 'blocked-capability-reroute' | 'react-runtime-contract-stop' | 'resource-runtime-contract-stop' | 'ctx-libs-member-mismatch-stop' | 'ctx-root-mismatch-stop';
9
+ export type RunJsAuthoringRepairClass = 'syntax-stop' | 'nested-runjs-stop' | 'source-limit-stop' | 'switch-to-resource-api' | 'missing-top-level-return' | 'value-surface-forbids-render' | 'unknown-surface-stop' | 'unknown-model-stop' | 'replace-innerhtml-with-render' | 'render-top-level-function-wrapper' | 'render-unreachable-render-call' | 'unknown-global-stop' | 'blocked-capability-reroute' | 'react-runtime-contract-stop' | 'resource-runtime-contract-stop' | 'ctx-libs-member-mismatch-stop' | 'ctx-root-mismatch-stop';
10
10
  export type RunJsAuthoringSurfaceStyle = 'render' | 'value' | 'action';
11
11
  export interface RunJsAuthoringRuleDefinition {
12
12
  repairClass: RunJsAuthoringRepairClass;
@@ -310,58 +310,7 @@ function collectDirectDomErrors(path, source, scan, modelUse, surface, errors) {
310
310
  );
311
311
  });
312
312
  }
313
- function collectGlobalErrors(path, source, scan, modelUse, surface, errors) {
314
- scan.windowDocumentNavigatorAliases.forEach((entry) => {
315
- errors.push(
316
- (0, import_errors.buildRunJsAuthoringError)({
317
- path,
318
- repairClass: "blocked-global-stop",
319
- message: `flowSurfaces authoring ${path} cannot alias forbidden global ${entry.root}`,
320
- modelUse,
321
- surface,
322
- index: entry.index,
323
- source,
324
- details: {
325
- global: entry.root,
326
- alias: entry.alias
327
- }
328
- })
329
- );
330
- });
331
- scan.windowDocumentNavigatorUses.forEach((entry) => {
332
- errors.push(
333
- (0, import_errors.buildRunJsAuthoringError)({
334
- path,
335
- repairClass: "blocked-global-stop",
336
- ruleId: `runjs-${entry.root}-property-blocked`,
337
- message: `flowSurfaces authoring ${path} cannot access ${entry.root}.${entry.member} in RunJS`,
338
- modelUse,
339
- surface,
340
- index: entry.index,
341
- source,
342
- details: {
343
- global: entry.root,
344
- member: entry.member
345
- }
346
- })
347
- );
348
- });
349
- scan.forbiddenBareGlobals.forEach((entry) => {
350
- errors.push(
351
- (0, import_errors.buildRunJsAuthoringError)({
352
- path,
353
- repairClass: "blocked-global-stop",
354
- message: `flowSurfaces authoring ${path} cannot access forbidden global ${entry.name}`,
355
- modelUse,
356
- surface,
357
- index: entry.index,
358
- source,
359
- details: {
360
- global: entry.name
361
- }
362
- })
363
- );
364
- });
313
+ function collectUnknownGlobalErrors(path, source, scan, modelUse, surface, errors) {
365
314
  scan.unknownBareGlobals.forEach((entry) => {
366
315
  const suggestion = entry.suggestedCapability ? `; use ${entry.suggestedCapability} or assign it to a local variable first` : "; declare or import it before using it";
367
316
  errors.push(
@@ -840,7 +789,14 @@ const RUNJS_INSPECTION_VALIDATORS = [
840
789
  ),
841
790
  createLegacyValidator("dom-global", (runtime, errors) => {
842
791
  collectDirectDomErrors(runtime.input.path, runtime.source, runtime.scan, runtime.modelUse, runtime.surface, errors);
843
- collectGlobalErrors(runtime.input.path, runtime.source, runtime.scan, runtime.modelUse, runtime.surface, errors);
792
+ collectUnknownGlobalErrors(
793
+ runtime.input.path,
794
+ runtime.source,
795
+ runtime.scan,
796
+ runtime.modelUse,
797
+ runtime.surface,
798
+ errors
799
+ );
844
800
  }),
845
801
  createLegacyValidator(
846
802
  "react-runtime",
@@ -82,6 +82,23 @@ export declare class FlowSurfacesService {
82
82
  private assertMenuRouteUpdatable;
83
83
  private assertMenuParentNotSelfOrDescendant;
84
84
  private buildMenuResult;
85
+ private hasDesktopRouteUiLayoutsRelation;
86
+ private normalizeDesktopRouteRelationId;
87
+ private readDesktopRouteUiLayoutUids;
88
+ private resolveDefaultDesktopRouteUiLayoutUids;
89
+ private findDesktopRouteUiLayoutByUid;
90
+ private getDesktopRouteUiLayoutTypeByUid;
91
+ private isMobileDesktopRouteUiLayoutUid;
92
+ private resolveInheritedDesktopRouteUiLayoutUids;
93
+ private normalizeExplicitDesktopRouteLayoutUid;
94
+ private normalizeDesktopRouteLayoutUidFilter;
95
+ private resolveDesktopRouteLayoutUidFilter;
96
+ private assertEnabledDesktopRouteUiLayoutUid;
97
+ private assertDesktopRouteBelongsToUiLayout;
98
+ private resolveRequestedDesktopRouteUiLayoutUids;
99
+ private setDesktopRouteUiLayouts;
100
+ private attachDesktopRouteUiLayoutsToRouteAndChildren;
101
+ private ensureDesktopRouteUiLayouts;
85
102
  private isValidMenuIconName;
86
103
  private assertVisibleNavigationIcon;
87
104
  private assertVisibleNavigationRouteIconUpdate;
@@ -142,6 +159,7 @@ export declare class FlowSurfacesService {
142
159
  private getCollectionFilterTargetKey;
143
160
  private normalizeFlowContextTemplateValue;
144
161
  private isSameConfiguredFlowContextValue;
162
+ private isPopupCurrentRecordFilterByTkMatch;
145
163
  private isPopupAssociatedRecordsSourceIdMatch;
146
164
  private classifyPopupRawResourceInit;
147
165
  private resolvePopupAssociationField;
@@ -160,6 +178,7 @@ export declare class FlowSurfacesService {
160
178
  private persistReactionSlot;
161
179
  private buildLinkageWriteResult;
162
180
  private getLiveLinkageCapability;
181
+ private getLiveFieldValueCapability;
163
182
  getReactionMeta(values: FlowSurfaceGetReactionMetaValues, options?: {
164
183
  transaction?: any;
165
184
  }): Promise<FlowSurfaceGetReactionMetaResult>;
@@ -182,6 +201,17 @@ export declare class FlowSurfacesService {
182
201
  private buildSurfaceReadPayload;
183
202
  private buildSurfaceContextFingerprint;
184
203
  get(input: Record<string, any>, options?: FlowSurfaceReadOptions): Promise<Record<string, any>>;
204
+ exportBlueprint(input: Record<string, unknown>, options?: FlowSurfaceReadOptions): Promise<{
205
+ document: FlowSurfaceApplyBlueprintDocument;
206
+ source: {
207
+ target: {
208
+ pageSchemaUid: string;
209
+ };
210
+ pageTitle?: string;
211
+ };
212
+ warnings: string[];
213
+ unsupported: import("./blueprint/export-document").FlowSurfaceExportBlueprintUnsupportedItem[];
214
+ }>;
185
215
  private getDeclaredKeyPersistenceDeps;
186
216
  private patchDeclaredKeyModel;
187
217
  private persistCreatedKeysForAction;
@@ -192,6 +222,8 @@ export declare class FlowSurfacesService {
192
222
  private dispatchPlanOnlyAction;
193
223
  private resolveApplyBlueprintReplaceTargetInfo;
194
224
  private resolveApplyBlueprintCreateNavigationGroup;
225
+ private normalizeApplyBlueprintCreateMobileNavigation;
226
+ private assertApplyBlueprintCreateNavigationLayout;
195
227
  private resolveApplyBlueprintCreatePageIdentity;
196
228
  private prepareApplyBlueprintRequest;
197
229
  private prevalidateApplyBlueprintChartAssets;
@@ -288,6 +320,7 @@ export declare class FlowSurfacesService {
288
320
  private createFlowTemplateReferenceBlockModel;
289
321
  private buildPopupTemplateReferenceOpenView;
290
322
  private shouldHydrateDetachedPopupTemplateBlockResourceContext;
323
+ private resolveDetachedPopupTemplateBlockCurrentRecordFilterByTk;
291
324
  private collectDetachedPopupTemplateBlockResourceContextPatches;
292
325
  private hydrateDetachedPopupTemplateBlockResourceContext;
293
326
  private hydrateDetachedPopupTemplateSourceContext;
@@ -736,6 +769,9 @@ export declare class FlowSurfacesService {
736
769
  private syncFilterActionSettingsForUpdateSettings;
737
770
  private resolveFilterActionDefaultFilterRequiredFieldCount;
738
771
  private syncMirroredStepParamsForUpdateSettings;
772
+ private syncActionButtonSettingsForUpdateSettings;
773
+ private supportsActionButtonSettingsSync;
774
+ private pickRequestedActionButtonSettings;
739
775
  private syncCreatedFieldWrapperTitleFieldStepParams;
740
776
  private syncUpdateActionAssignedValuesForUpdateSettings;
741
777
  private syncActionTriggerWorkflowsForUpdateSettings;
@@ -916,6 +952,12 @@ export declare class FlowSurfacesService {
916
952
  private normalizeRemoveNodeTarget;
917
953
  private assertRemoveNodeResolvedTarget;
918
954
  private normalizeGetTarget;
955
+ private normalizeExportBlueprintRequest;
956
+ private normalizeExportBlueprintUnsupportedPolicy;
957
+ private normalizeExportBlueprintLocatorValue;
958
+ private readRouteString;
959
+ private resolveExportBlueprintPageSchemaUid;
960
+ private assertExportBlueprintRootTarget;
919
961
  private normalizeContextPath;
920
962
  private normalizeContextMaxDepth;
921
963
  private buildReadTargetSummary;
@@ -1038,14 +1080,19 @@ export declare class FlowSurfacesService {
1038
1080
  private stableSerializeAIEmployeeValue;
1039
1081
  private buildAIEmployeeActionDedupIdentity;
1040
1082
  private normalizeAIEmployeeWorkContextForDedupIdentity;
1083
+ private normalizeAIEmployeeActionWorkContextForDedupIdentity;
1084
+ private normalizeAIEmployeeDefaultActionWorkContextForSelfUid;
1085
+ private normalizeAIEmployeeTaskWorkContextForDedupIdentity;
1041
1086
  private normalizeAIEmployeeTasksForDedupIdentity;
1042
1087
  private assertNoDuplicateAIEmployeeAction;
1088
+ private assertNoDuplicateAIEmployeeActionForUpdateSettings;
1043
1089
  private hasAIEmployeePublicSettings;
1044
1090
  private assertOnlyAIEmployeePublicSettings;
1045
1091
  private aiEmployeeNestedRepairHint;
1046
1092
  private assertOnlyAIEmployeeNestedPublicSettings;
1047
1093
  private assertNoAIEmployeeInternalPropSettings;
1048
1094
  private readAIEmployeePersistedTasks;
1095
+ private normalizeAIEmployeeLegacyInheritedTaskWorkContext;
1049
1096
  private buildAIEmployeeTaskStepParams;
1050
1097
  private mergeAIEmployeeActionSettingsPayload;
1051
1098
  private syncAIEmployeeTaskStepParamsForUpdateSettings;
@@ -1058,6 +1105,7 @@ export declare class FlowSurfacesService {
1058
1105
  private normalizeAIEmployeeUsername;
1059
1106
  private assertAIEmployeeWorkContextType;
1060
1107
  private normalizeAIEmployeeWorkContext;
1108
+ private normalizeAIEmployeeEffectiveActionWorkContext;
1061
1109
  private normalizeAIEmployeeTaskModel;
1062
1110
  private normalizeAIEmployeeSkillSettings;
1063
1111
  private collectAIEmployeePromptVariables;
@@ -1080,14 +1128,19 @@ export declare class FlowSurfacesService {
1080
1128
  private normalizeAIEmployeeTaskMessage;
1081
1129
  private normalizeAIEmployeeTaskPatch;
1082
1130
  private normalizeAIEmployeeTasks;
1131
+ private withAIEmployeeTaskDefaultWorkContext;
1132
+ private shouldMaterializeAIEmployeeTaskDefaultWorkContext;
1133
+ private rebaseAIEmployeeInheritedTaskWorkContext;
1083
1134
  private normalizeAIEmployeeActionSettingsReferences;
1084
1135
  private normalizeAIEmployeeActionPublicSettings;
1085
1136
  private resolveAIEmployeeActionSelfUid;
1137
+ private resolveAIEmployeeActionSelfUidFromParentNode;
1086
1138
  private configureActionNode;
1087
1139
  private normalizeActionPanelActionChanges;
1088
1140
  private buildFieldCatalog;
1089
1141
  private getFieldMenuCatalogMode;
1090
1142
  private resolveRegisteredFieldBinding;
1143
+ private isCollectionTitleField;
1091
1144
  private resolveAssociationLeafDisplaySemantics;
1092
1145
  private buildFieldMenuDirectCandidates;
1093
1146
  private collectFieldMenuAssociationLeafCandidates;