@cratis/screenplay-language 4.147.1 → 4.148.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.
Files changed (41) hide show
  1. package/dist/ContinuationResponseField.d.ts +7 -0
  2. package/dist/ContinuationResponseField.d.ts.map +1 -0
  3. package/dist/ResponseAnalysis.d.ts +2 -0
  4. package/dist/ResponseAnalysis.d.ts.map +1 -1
  5. package/dist/bundles/compiler/Diagnostics/DiagnosticCodes.js +1 -1
  6. package/dist/bundles/compiler/Diagnostics/DiagnosticCodes.js.map +1 -1
  7. package/dist/bundles/compiler/Files/PlayApplicationAssembly.js +1 -1
  8. package/dist/bundles/compiler/Files/PlayApplicationAssembly.js.map +1 -1
  9. package/dist/bundles/compiler/Parsing/ContinuationValues.js +2 -0
  10. package/dist/bundles/compiler/Parsing/ContinuationValues.js.map +1 -0
  11. package/dist/bundles/compiler/Parsing/InputUses.js +1 -1
  12. package/dist/bundles/compiler/Parsing/InputUses.js.map +1 -1
  13. package/dist/bundles/compiler/Parsing/ParserContext.js +1 -1
  14. package/dist/bundles/compiler/Parsing/ParserContext.js.map +1 -1
  15. package/dist/bundles/compiler/Parsing/ResponseCommandResolver.js +2 -0
  16. package/dist/bundles/compiler/Parsing/ResponseCommandResolver.js.map +1 -0
  17. package/dist/bundles/compiler/Parsing/ResponseValidator.js +1 -1
  18. package/dist/bundles/compiler/Parsing/ResponseValidator.js.map +1 -1
  19. package/dist/bundles/compiler/ScreenplayCompiler.js +1 -1
  20. package/dist/bundles/compiler/ScreenplayCompiler.js.map +1 -1
  21. package/dist/bundles/compiler/index.js +1 -1
  22. package/dist/bundles/completion-planner.js +2 -2
  23. package/dist/bundles/completion-planner.js.map +1 -1
  24. package/dist/bundles/continuation-responses.js +2 -0
  25. package/dist/bundles/continuation-responses.js.map +1 -0
  26. package/dist/bundles/diagnostic-codes.js +1 -1
  27. package/dist/bundles/diagnostic-codes.js.map +1 -1
  28. package/dist/bundles/hover-content.js +5 -5
  29. package/dist/bundles/hover-content.js.map +1 -1
  30. package/dist/bundles/response-analysis.js +6 -6
  31. package/dist/bundles/response-analysis.js.map +1 -1
  32. package/dist/bundles/validation.js +1 -1
  33. package/dist/bundles/validation.js.map +1 -1
  34. package/dist/completion-planner.d.ts.map +1 -1
  35. package/dist/continuation-responses.d.ts +5 -0
  36. package/dist/continuation-responses.d.ts.map +1 -0
  37. package/dist/diagnostic-codes.d.ts +1 -0
  38. package/dist/diagnostic-codes.d.ts.map +1 -1
  39. package/dist/hover-content.d.ts.map +1 -1
  40. package/dist/response-analysis.d.ts.map +1 -1
  41. package/package.json +1 -1
@@ -0,0 +1,7 @@
1
+ import { AnalysisType } from './AnalysisType';
2
+ export interface ContinuationResponseField {
3
+ readonly name: string;
4
+ readonly type: AnalysisType;
5
+ readonly command: string;
6
+ }
7
+ //# sourceMappingURL=ContinuationResponseField.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ContinuationResponseField.d.ts","sourceRoot":"","sources":["../ContinuationResponseField.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE9C,MAAM,WAAW,yBAAyB;IACtC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,IAAI,EAAE,YAAY,CAAC;IAC5B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;CAC5B"}
@@ -1,3 +1,4 @@
1
+ import { ContinuationResponseField } from './ContinuationResponseField';
1
2
  import { AnalysisCommand } from './AnalysisCommand';
2
3
  import { AnalysisDiagnostic } from './AnalysisDiagnostic';
3
4
  import { AnalysisSpecification } from './AnalysisSpecification';
@@ -8,6 +9,7 @@ export interface ResponseAnalysis {
8
9
  readonly type: string;
9
10
  readonly line: number;
10
11
  }[];
12
+ readonly continuationResponses?: ReadonlyMap<number, readonly ContinuationResponseField[]>;
11
13
  readonly commands: ReadonlyMap<number, AnalysisCommand>;
12
14
  readonly specifications: ReadonlyMap<number, AnalysisSpecification>;
13
15
  readonly diagnostics: readonly AnalysisDiagnostic[];
@@ -1 +1 @@
1
- {"version":3,"file":"ResponseAnalysis.d.ts","sourceRoot":"","sources":["../ResponseAnalysis.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAChE,OAAO,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AAExD,MAAM,WAAW,gBAAgB;IAC7B,QAAQ,CAAC,eAAe,CAAC,EAAE,SAAS;QAAE,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;KAAE,EAAE,CAAC;IAC9G,QAAQ,CAAC,QAAQ,EAAE,WAAW,CAAC,MAAM,EAAE,eAAe,CAAC,CAAC;IACxD,QAAQ,CAAC,cAAc,EAAE,WAAW,CAAC,MAAM,EAAE,qBAAqB,CAAC,CAAC;IACpE,QAAQ,CAAC,WAAW,EAAE,SAAS,kBAAkB,EAAE,CAAC;IACpD,QAAQ,CAAC,wBAAwB,CAAC,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC;IACxD,QAAQ,CAAC,UAAU,CAAC,EAAE,iBAAiB,CAAC;CAC3C"}
1
+ {"version":3,"file":"ResponseAnalysis.d.ts","sourceRoot":"","sources":["../ResponseAnalysis.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,yBAAyB,EAAE,MAAM,6BAA6B,CAAC;AACxE,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAChE,OAAO,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AAExD,MAAM,WAAW,gBAAgB;IAC7B,QAAQ,CAAC,eAAe,CAAC,EAAE,SAAS;QAAE,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;KAAE,EAAE,CAAC;IAC9G,QAAQ,CAAC,qBAAqB,CAAC,EAAE,WAAW,CAAC,MAAM,EAAE,SAAS,yBAAyB,EAAE,CAAC,CAAC;IAC3F,QAAQ,CAAC,QAAQ,EAAE,WAAW,CAAC,MAAM,EAAE,eAAe,CAAC,CAAC;IACxD,QAAQ,CAAC,cAAc,EAAE,WAAW,CAAC,MAAM,EAAE,qBAAqB,CAAC,CAAC;IACpE,QAAQ,CAAC,WAAW,EAAE,SAAS,kBAAkB,EAAE,CAAC;IACpD,QAAQ,CAAC,wBAAwB,CAAC,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC;IACxD,QAAQ,CAAC,UAAU,CAAC,EAAE,iBAAiB,CAAC;CAC3C"}
@@ -1,2 +1,2 @@
1
- const e={InvalidIdentityDeclaration:`PLAY0633`,DuplicateIdentity:`PLAY0634`,InvalidIdentityDetail:`PLAY0635`,UnknownIdentitySource:`PLAY0636`,IdentityDetailWithoutSource:`PLAY0637`,IdentitySourceWithBody:`PLAY0638`,DuplicateIdentityDetail:`PLAY0639`,BuiltInIdentityDetail:`PLAY0640`,UnknownIdentityQuery:`PLAY0641`,InvalidIdentityQuery:`PLAY0642`,IdentityQueryWithoutKey:`PLAY0643`,InvalidIdentityQueryKey:`PLAY0644`,IdentityQueryAuthorizationDependency:`PLAY0645`,IdentityQueryTypeMismatch:`PLAY0646`,InvalidReactionIdentity:`PLAY0647`,GatedInvocationWithoutIdentity:`PLAY0648`,UnusedReactionIdentity:`PLAY0649`,UnusedReactionRole:`PLAY0650`,UnsatisfiedReactionIdentity:`PLAY0651`,ReactionPrivilegeEscalation:`PLAY0652`,CommandProducesPublicEvent:`PLAY0607`,PublicEventRequiresOutboundTranslation:`PLAY0608`,OutboundPublicEventCount:`PLAY0609`,ForeignPublicEventConsumer:`PLAY0610`,OutboundTranslationInput:`PLAY0611`,InboundTranslationOutput:`PLAY0612`,ForeignPublicEventProduced:`PLAY0613`,PublicTranslationRequiresDirection:`PLAY0614`,TranslationConstructDirection:`PLAY0615`,InboundTranslationInput:`PLAY0616`,OutboundTranslationOutput:`PLAY0617`,EventTargetOutsideOutboundTranslation:`PLAY0618`,EventsSourceOutsideInboundTranslation:`PLAY0619`,InvalidCaptureEventsSource:`PLAY0620`,InvalidExposureDeclaration:`PLAY0621`,UnknownExposureOwner:`PLAY0622`,ReExposureCycle:`PLAY0623`,ReExposureBroken:`PLAY0624`,InvalidInstanceContribution:`PLAY0625`,UnknownContributionInstance:`PLAY0626`,ContributionNotExposed:`PLAY0627`,ContributionTypeMismatch:`PLAY0628`,UnknownTemplateContentSlot:`PLAY0629`,UnknownNavigationOutlet:`PLAY0630`,TemplateScopeMismatch:`PLAY0631`,IncompatibleComponentPackage:`PLAY0632`,UnknownNavigationDestination:`PLAY0654`,UnknownScreenContributionPoint:`PLAY0655`,TemplateNestingCycle:`PLAY0656`,DuplicateComplianceMarker:`PLAY0653`,LegacyComplianceMarker:`PLAY0565`,UnknownComplianceMarker:`PLAY0566`,InvalidSecretScope:`PLAY0567`,DuplicateSecretScope:`PLAY0568`,SecretScopeIgnoredForPii:`PLAY0569`,InvalidPersonalDataQualifier:`PLAY0570`,DuplicateSpecialCategory:`PLAY0571`,InvalidPurposeDeclaration:`PLAY0596`,InvalidPurposeVocabulary:`PLAY0597`,DuplicatePurposeField:`PLAY0598`,DuplicatePurposeDeclaration:`PLAY0599`,UnknownPurpose:`PLAY0600`,PurposeInterestMismatch:`PLAY0601`,PersonalDataWithoutPurpose:`PLAY0602`,SpecialDataWithoutCondition:`PLAY0603`,CriminalDataWithoutAuthorization:`PLAY0604`,PurposeWithoutBasis:`PLAY0605`,UnusedPurpose:`PLAY0606`,ConflictingScreenDataBinding:`PLAY0530`,ScreenDataQueryMismatch:`PLAY0531`,ActionWithoutInputSurface:`PLAY0532`,CommandWithoutInputSurface:`PLAY0533`,ReadModelFieldWithoutOrigin:`PLAY0534`,QueryParameterNotHeldByView:`PLAY0535`,UnconsumedEvent:`PLAY0536`,UnreachableScreen:`PLAY0537`,UnknownActionSubjectField:`PLAY0345`,UnresolvedActionSubject:`PLAY0346`,UnreachableActionAlternative:`PLAY0347`,UnknownActionArgumentProperty:`PLAY0348`,UnreachableRefusalBranch:`PLAY0540`,InvalidRefusalValue:`PLAY0541`,UnknownRefusalConstraint:`PLAY0542`,UnknownRedeliveryReaction:`PLAY0544`,IndeterminateNegatedClaimTarget:`PLAY0546`,InvalidRefusalBranch:`PLAY0538`,InvalidRefusalBranchBody:`PLAY0539`,UnmatchedRedeliveredOccurrence:`PLAY0543`,InvalidNoEventsExpectation:`PLAY0545`,InvalidProducesDeclaration:`PLAY0042`,ProducesWhenWithoutEvent:`PLAY0043`,InvalidPropertyMapping:`PLAY0044`,DuplicateProducesTarget:`PLAY0193`,EventSourceIdInPayload:`PLAY0469`,ExplicitProducesTargetsRequired:`PLAY0470`,RedundantEventId:`PLAY0471`,InvalidEventId:`PLAY0472`,InlineEventCollision:`PLAY0473`,InlineEventOutsideCommand:`PLAY0474`,InlineEventGeneration:`PLAY0475`,ReservedProductionMetadata:`PLAY0476`,InvalidEventDocumentation:`PLAY0477`,OmittedProductionDestination:`PLAY0478`,UnknownConstraintProperty:`PLAY0391`,UnknownTopLevelConstruct:`PLAY0001`,InvalidDomainDeclaration:`PLAY0002`,DuplicateDomain:`PLAY0003`,DomainNotFirst:`PLAY0004`,InvalidImportDeclaration:`PLAY0005`,TabIndentation:`PLAY0006`,InvalidConceptDeclaration:`PLAY0007`,UnknownPrimitiveType:`PLAY0008`,InvalidEnumerationValue:`PLAY0009`,UnknownConceptDirective:`PLAY0010`,ValidateReadAsEnumerationBlock:`PLAY0011`,AttributeReasonWithoutAttribute:`PLAY0012`,DuplicateAttributeReason:`PLAY0013`,InvalidTypeDeclaration:`PLAY0014`,TypeWithoutProperties:`PLAY0015`,InvalidPropertyDeclaration:`PLAY0016`,IdentifierOutsideCommand:`PLAY0017`,InvalidEventDeclaration:`PLAY0018`,IdentifierOnEventProperty:`PLAY0019`,TagPropertyReadAsTag:`PLAY0020`,InvalidModuleDeclaration:`PLAY0021`,UnknownModuleDirective:`PLAY0022`,InvalidFeatureDeclaration:`PLAY0023`,UnknownFeatureDirective:`PLAY0024`,InvalidSliceDeclaration:`PLAY0027`,UnknownSliceType:`PLAY0028`,UnknownSliceDirective:`PLAY0029`,InvalidPersonaDeclaration:`PLAY0030`,InvalidPersonaPolicyReference:`PLAY0031`,UnknownPersonaDirective:`PLAY0032`,InvalidCommandDeclaration:`PLAY0033`,UnknownCommandDirective:`PLAY0034`,DuplicateCommandIdentifier:`PLAY0036`,InvalidQueryDeclaration:`PLAY0047`,UnknownQueryDirective:`PLAY0048`,InvalidQueryParameter:`PLAY0049`,InvalidProjectionDeclaration:`PLAY0056`,EmptyProjection:`PLAY0057`,UnknownProjectionDirective:`PLAY0058`,FromWithoutEvent:`PLAY0061`,InvalidEventReference:`PLAY0062`,InvalidJoinDeclaration:`PLAY0063`,JoinWithoutEvent:`PLAY0064`,InvalidChildrenDeclaration:`PLAY0065`,InvalidNestedDeclaration:`PLAY0066`,NestedBlockWithoutFrom:`PLAY0067`,InvalidRemoveDeclaration:`PLAY0068`,UnknownRemoveDirective:`PLAY0069`,InvalidClearDeclaration:`PLAY0070`,ClearWithOutsideNestedBlock:`PLAY0071`,InvalidSpecificationDeclaration:`PLAY0094`,UnknownSpecificationDirective:`PLAY0095`,InvalidSpecificationWhen:`PLAY0096`,DuplicateSpecificationWhen:`PLAY0097`,InvalidThenError:`PLAY0098`,InvalidReadModelStep:`PLAY0099`,InvalidEventStep:`PLAY0100`,InvalidSpecificationValue:`PLAY0101`,InvalidScreenDeclaration:`PLAY0102`,UnknownScreenDirective:`PLAY0103`,InvalidDataDirective:`PLAY0104`,InvalidActionDirective:`PLAY0105`,UnknownActionDirective:`PLAY0106`,InvalidNavigation:`PLAY0107`,InvalidScreenLayoutSlot:`PLAY0108`,InvalidTitleDirective:`PLAY0109`,UnknownTableDirective:`PLAY0110`,UnknownSummaryDirective:`PLAY0111`,AuthorizeWithoutPolicy:`PLAY0122`,InvalidPolicyReference:`PLAY0123`,InvalidConstraintDeclaration:`PLAY0132`,ConstraintWithoutRule:`PLAY0133`,InvalidConstraintBody:`PLAY0134`,DuplicateConstraintBody:`PLAY0135`,InvalidReactionDeclaration:`PLAY0136`,InvalidReactionTrigger:`PLAY0137`,ReactionWithoutTrigger:`PLAY0138`,InvalidValidateDeclaration:`PLAY0140`,InvalidValidationRule:`PLAY0141`,InvalidRuleName:`PLAY0143`,UnknownRuleImplementationDirective:`PLAY0144`,InvalidDescription:`PLAY0145`,EmptyDescription:`PLAY0146`,DuplicateDescription:`PLAY0147`,TagWithoutValue:`PLAY0148`,InvalidTagValue:`PLAY0149`,UnknownContextPath:`PLAY0153`,UnknownContextCausedByProperty:`PLAY0154`,UnknownContextIdentityProperty:`PLAY0155`,ExpectedCodeFence:`PLAY0163`,UnclosedCodeBlock:`PLAY0164`,DuplicateDeclaration:`PLAY0168`,RepeatedSingularDeclarationAcrossFiles:`PLAY0172`,RepeatedDeclarationAcrossFiles:`PLAY0173`,ConflictingDescriptionAcrossFiles:`PLAY0174`,UnexpectedTokenInAuthorize:`PLAY0184`,UnclosedAuthorizeGroup:`PLAY0185`,InvalidReadModelDeclaration:`PLAY0186`,InvalidInvokesDeclaration:`PLAY0194`,InvalidScopeDeclaration:`PLAY0199`,DuplicateScope:`PLAY0200`,InvalidIntervalTrigger:`PLAY0249`,InvalidScheduleTrigger:`PLAY0250`,DuplicateReactionTrigger:`PLAY0253`,InvalidSpecificationEventSource:`PLAY0275`,DuplicateSpecificationEventSource:`PLAY0276`,InvalidProjectionVariantDeclaration:`PLAY0277`,InvalidEntersOnDeclaration:`PLAY0279`,NestedProjectionVariantNotAllowed:`PLAY0280`,InvalidStructuredValue:`PLAY0291`,DuplicateStructuredValueMember:`PLAY0294`,ConflictingSpecificationActions:`PLAY0358`,InvalidSpecificationEventOrder:`PLAY0359`,InvalidValidationSeverity:`PLAY0368`,VariantRequiresEnteringEvent:`PLAY0382`,DuplicateProjectionVariant:`PLAY0384`,DuplicateVariantEnteringEvent:`PLAY0385`,InvalidSpecificationDenied:`PLAY0388`,DuplicateAuthorizationAcrossFiles:`PLAY0394`,FileConstraintOnlySupportsUniqueness:`PLAY0396`,LegacyInlineCodeFence:`PLAY0397`,InvalidEventGeneration:`PLAY0446`,InvalidFileImport:`PLAY0454`,FileImportMatchesNothing:`PLAY0455`,ImportedFileNotFound:`PLAY0456`,ConflictingImportPlacement:`PLAY0457`,ImportCycle:`PLAY0458`,ModuleInPlacedFile:`PLAY0459`,UnexpectedInPlacedFile:`PLAY0460`,InvalidSpecificationClock:`PLAY0461`,InvalidSpecificationTrigger:`PLAY0462`,InvalidSpecificationCapture:`PLAY0463`,InvalidSpecificationQueryAction:`PLAY0464`,UnknownSpecificationQueryArgument:`PLAY0468`,InvalidSpecificationQuery:`PLAY0265`,UnknownSpecificationQueryDirective:`PLAY0266`,DuplicateSpecificationQueryArguments:`PLAY0267`,InvalidAbsentReadModelStep:`PLAY0453`,LegacyOptionalSuffix:`PLAY0479`,InvalidOptionalModifierOrder:`PLAY0480`,OptionalReadsNotSupported:`PLAY0481`,InvalidSpecificationCaller:`PLAY0386`,DuplicateSpecificationCallerOrDenied:`PLAY0387`,GeneratedPropertyOutsideCommand:`PLAY0482`,InvalidGeneratedType:`PLAY0483`,InvalidGeneratedModifierOrder:`PLAY0484`,DuplicateEventSubject:`PLAY0590`,InvalidSubjectType:`PLAY0591`,ProtectedSubjectType:`PLAY0592`,InvalidSubjectOwner:`PLAY0593`,ReadModelSubjectNotSupported:`PLAY0594`,InvalidSubjectModifierOrder:`PLAY0595`,GeneratedPropertySuppliedAsInput:`PLAY0485`,InvalidCommandResponse:`PLAY0486`,InvalidResponseSource:`PLAY0487`,DuplicateResponseField:`PLAY0488`,InvalidResponseShape:`PLAY0489`,InvalidGeneratedFixture:`PLAY0490`,InvalidReturnExpectation:`PLAY0491`,InvalidImplementationBlock:`PLAY0492`,InvalidImplementationHint:`PLAY0493`,ConflictingImplementationSources:`PLAY0494`,UnknownType:`PLAY0165`,InvalidSystemDeclaration:`PLAY0495`,InvalidOperationDeclaration:`PLAY0496`,InvalidProductionReference:`PLAY0497`,ProductionDeclarationCollision:`PLAY0498`,OperationOutsideCommand:`PLAY0499`,InvalidSystemReference:`PLAY0500`,InvalidOperationMapping:`PLAY0501`,InvalidOperationSpecification:`PLAY0502`,InvalidCaptureDeclaration:`PLAY0078`,UnknownCaptureDirective:`PLAY0079`,InvalidMapEntry:`PLAY0080`,InvalidTranslation:`PLAY0081`,InvalidSplitDeclaration:`PLAY0082`,InvalidSplitTarget:`PLAY0083`,InvalidAppendDeclaration:`PLAY0084`,UnknownAppendDirective:`PLAY0085`,WhenWithoutTrigger:`PLAY0086`,InvalidWhenClause:`PLAY0087`,InvalidWhenTransitionClause:`PLAY0088`,MixedWhenCombinators:`PLAY0089`,WhenCombinatorWithoutProperty:`PLAY0090`,UnknownCaptureBlockDirective:`PLAY0091`,InvalidCompositeKeyPart:`PLAY0072`,TemplateInCompositeKey:`PLAY0073`,EmptyCompositeKey:`PLAY0074`,InvalidProjectionMapping:`PLAY0075`,ExpectedLiteralValue:`PLAY0150`,InvalidExpression:`PLAY0152`,UnterminatedInterpolation:`PLAY0157`,UnterminatedTemplateExpression:`PLAY0156`,ProjectionDocumentWithoutProjection:`PLAY0055`,CaptureDocumentWithoutCapture:`PLAY0077`,SpecificationDocumentWithoutSpecification:`PLAY0093`,InvalidSeedDeclaration:`PLAY0128`,InvalidSeedGroup:`PLAY0129`,InvalidSeedEvent:`PLAY0130`,InvalidSeedPropertyAssignment:`PLAY0131`,InvalidPolicyDeclaration:`PLAY0112`,UnknownPolicyDirective:`PLAY0113`,PolicyWithoutRequirement:`PLAY0114`,ExpectedRoleName:`PLAY0118`,ExpectedClaimName:`PLAY0119`,ExpectedClaimMatches:`PLAY0120`,ExpectedClaimMatchTarget:`PLAY0121`,MixedPolicyImplementation:`PLAY0440`,RepeatedPolicyRequirement:`PLAY0441`,UnexpectedTokenInPolicyCondition:`PLAY0115`,ExpectedPolicyCondition:`PLAY0116`,UnclosedPolicyConditionGroup:`PLAY0117`,UnexpectedTokenInCondition:`PLAY0158`,ExpectedCondition:`PLAY0159`,ExpectedComparisonOperator:`PLAY0161`,ExpectedComparisonValue:`PLAY0162`,InvalidActionAlternative:`PLAY0341`,GuardedActionWithoutAlternatives:`PLAY0342`,MisplacedActionOtherwise:`PLAY0343`,UnsupportedActionConditionOperand:`PLAY0344`,InvalidInteractionArgument:`PLAY0319`,UnclosedConditionGroup:`PLAY0160`,InvalidNumericDirective:`PLAY0508`,DuplicateNumericDirective:`PLAY0509`,LateNumericDirective:`PLAY0510`,InexactNumericLiteral:`PLAY0511`,MixedNumericModes:`PLAY0512`,IncompatibleNumericSource:`PLAY0513`,EventFromLaterSlice:`PLAY0516`,TimelineCycleGroup:`PLAY0517`,InvalidSpecificationExample:`PLAY0518`,DuplicateSpecificationAssignment:`PLAY0519`,UnresolvedSpecificationExampleType:`PLAY0520`,SpecificationExampleNameCollision:`PLAY0521`,SpecificationExampleKindMismatch:`PLAY0522`,InvalidSpecificationExampleValue:`PLAY0523`,MissingSpecificationProperty:`PLAY0524`,UnadmittedSpecificationExampleValue:`PLAY0525`,InvalidSpecificationExampleBody:`PLAY0526`,AmbiguousReference:`PLAY0198`,InvalidSpecificationStream:`PLAY0547`,SpecificationStreamOnCommand:`PLAY0548`,InvalidSpecificationStreamRoute:`PLAY0549`,InvalidSpecificationStreamEventSource:`PLAY0550`,SpecificationStreamContradictsCommand:`PLAY0551`,InvalidDependencyTarget:`PLAY0554`,RepeatedDependencyDeclaration:`PLAY0555`,UndeclaredDependency:`PLAY0552`,UnusedDependencyDeclaration:`PLAY0553`,MutualDependencyDeclarations:`PLAY0556`,AuthorizationRefusalWithoutIdentity:`PLAY0557`,InvalidDocumentation:`PLAY0558`,ConflictingDocumentationAcrossFiles:`PLAY0559`,InvalidSpecificationCallerPersona:`PLAY0572`,UnsynthesizablePersonaCaller:`PLAY0573`,PersonaWithoutGate:`PLAY0574`,GateWithoutPersona:`PLAY0575`,AmbiguousPersonaCaller:`PLAY0576`,InvalidSpecificationParameter:`PLAY0577`,InvalidSpecificationCase:`PLAY0578`,DuplicateSpecificationParameter:`PLAY0579`,DuplicateSpecificationCase:`PLAY0580`,IncompleteSpecificationTable:`PLAY0581`,InvalidSpecificationCaseAssignment:`PLAY0582`,InvalidSpecificationCaseValue:`PLAY0583`,InvalidSpecificationCaseReference:`PLAY0584`,OptionalSpecificationParameterTarget:`PLAY0585`,SpecificationCaseNameCollision:`PLAY0586`,IncompatibleSpecificationParameterType:`PLAY0587`,UnusedSpecificationParameter:`PLAY0588`,SingularSpecificationTableExpansion:`PLAY0589`,UnsupportedInteractionAlternatives:`PLAY0560`,MixedInteractionAlternatives:`PLAY0561`,InteractionAlternativeWithoutActions:`PLAY0562`,InlineInteractionAlternative:`PLAY0563`,LegacyInteractionWhere:`PLAY0564`,InvalidEventSourceDeclaration:`PLAY0503`,InvalidCommandStream:`PLAY0504`,AmbiguousCommandStream:`PLAY0505`,UnsupportedStreamIdType:`PLAY0506`,RedundantSourceStreamId:`PLAY0507`,UnknownEvent:`PLAY0166`,UnknownReadModelProperty:`PLAY0514`,PiiNotSupportedOnIdentifier:`PLAY0515`,HandlerWithoutImplementation:`PLAY0045`,UnknownHandlerDirective:`PLAY0046`,CommandWithProducesAndHandler:`PLAY0035`,AbsoluteFileReference:`PLAY0264`,InvalidTriggerData:`PLAY0246`,InvalidReadModelKey:`PLAY0660`,IncompleteReadModelKey:`PLAY0661`,InvalidReadModelKeyLookup:`PLAY0662`,ProductionRouteOutsideCommand:`PLAY0663`,RedundantProductionRoute:`PLAY0664`,InvalidObserverFilter:`PLAY0665`,ObserverFilterExcludesEveryProducer:`PLAY0666`,MixedEnumerationNumbering:`PLAY0667`,DuplicateEnumerationNumber:`PLAY0668`,EnumerationNumberOutsideInt32:`PLAY0669`,MalformedEnumerationNumber:`PLAY0670`,UnpinnedStoredEnumeration:`PLAY0671`,ReadsWithChildren:`PLAY0451`,UnknownGenerationStrategy:`PLAY0672`,InvalidGenerationArgument:`PLAY0673`,InvalidGenerationModifier:`PLAY0674`,DuplicateGenerationModifier:`PLAY0675`,DuplicateGeneration:`PLAY0676`,InvalidGenerationPrimitive:`PLAY0677`,InvalidGenerationPrefix:`PLAY0678`,InvalidGenerationAlphabet:`PLAY0679`,InvalidTypeIdPrefix:`PLAY0680`,GenerationSizeOutsideRange:`PLAY0681`,ReservedSequenceGeneration:`PLAY0682`,LowGenerationEntropy:`PLAY0683`,LowGeneratedIdentifierEntropy:`PLAY0684`};export{e as DiagnosticCodes};
1
+ const e={InvalidIdentityDeclaration:`PLAY0633`,DuplicateIdentity:`PLAY0634`,InvalidIdentityDetail:`PLAY0635`,UnknownIdentitySource:`PLAY0636`,IdentityDetailWithoutSource:`PLAY0637`,IdentitySourceWithBody:`PLAY0638`,DuplicateIdentityDetail:`PLAY0639`,BuiltInIdentityDetail:`PLAY0640`,UnknownIdentityQuery:`PLAY0641`,InvalidIdentityQuery:`PLAY0642`,IdentityQueryWithoutKey:`PLAY0643`,InvalidIdentityQueryKey:`PLAY0644`,IdentityQueryAuthorizationDependency:`PLAY0645`,IdentityQueryTypeMismatch:`PLAY0646`,InvalidReactionIdentity:`PLAY0647`,GatedInvocationWithoutIdentity:`PLAY0648`,UnusedReactionIdentity:`PLAY0649`,UnusedReactionRole:`PLAY0650`,UnsatisfiedReactionIdentity:`PLAY0651`,ReactionPrivilegeEscalation:`PLAY0652`,CommandProducesPublicEvent:`PLAY0607`,PublicEventRequiresOutboundTranslation:`PLAY0608`,OutboundPublicEventCount:`PLAY0609`,ForeignPublicEventConsumer:`PLAY0610`,OutboundTranslationInput:`PLAY0611`,InboundTranslationOutput:`PLAY0612`,ForeignPublicEventProduced:`PLAY0613`,PublicTranslationRequiresDirection:`PLAY0614`,TranslationConstructDirection:`PLAY0615`,InboundTranslationInput:`PLAY0616`,OutboundTranslationOutput:`PLAY0617`,EventTargetOutsideOutboundTranslation:`PLAY0618`,EventsSourceOutsideInboundTranslation:`PLAY0619`,InvalidCaptureEventsSource:`PLAY0620`,InvalidExposureDeclaration:`PLAY0621`,UnknownExposureOwner:`PLAY0622`,ReExposureCycle:`PLAY0623`,ReExposureBroken:`PLAY0624`,InvalidInstanceContribution:`PLAY0625`,UnknownContributionInstance:`PLAY0626`,ContributionNotExposed:`PLAY0627`,ContributionTypeMismatch:`PLAY0628`,UnknownTemplateContentSlot:`PLAY0629`,UnknownNavigationOutlet:`PLAY0630`,TemplateScopeMismatch:`PLAY0631`,IncompatibleComponentPackage:`PLAY0632`,UnknownNavigationDestination:`PLAY0654`,UnknownScreenContributionPoint:`PLAY0655`,TemplateNestingCycle:`PLAY0656`,DuplicateComplianceMarker:`PLAY0653`,LegacyComplianceMarker:`PLAY0565`,UnknownComplianceMarker:`PLAY0566`,InvalidSecretScope:`PLAY0567`,DuplicateSecretScope:`PLAY0568`,SecretScopeIgnoredForPii:`PLAY0569`,InvalidPersonalDataQualifier:`PLAY0570`,DuplicateSpecialCategory:`PLAY0571`,InvalidPurposeDeclaration:`PLAY0596`,InvalidPurposeVocabulary:`PLAY0597`,DuplicatePurposeField:`PLAY0598`,DuplicatePurposeDeclaration:`PLAY0599`,UnknownPurpose:`PLAY0600`,PurposeInterestMismatch:`PLAY0601`,PersonalDataWithoutPurpose:`PLAY0602`,SpecialDataWithoutCondition:`PLAY0603`,CriminalDataWithoutAuthorization:`PLAY0604`,PurposeWithoutBasis:`PLAY0605`,UnusedPurpose:`PLAY0606`,ConflictingScreenDataBinding:`PLAY0530`,ScreenDataQueryMismatch:`PLAY0531`,ActionWithoutInputSurface:`PLAY0532`,CommandWithoutInputSurface:`PLAY0533`,ReadModelFieldWithoutOrigin:`PLAY0534`,QueryParameterNotHeldByView:`PLAY0535`,UnconsumedEvent:`PLAY0536`,UnreachableScreen:`PLAY0537`,UnknownActionSubjectField:`PLAY0345`,UnresolvedActionSubject:`PLAY0346`,UnreachableActionAlternative:`PLAY0347`,UnknownActionArgumentProperty:`PLAY0348`,UnreachableRefusalBranch:`PLAY0540`,InvalidRefusalValue:`PLAY0541`,UnknownRefusalConstraint:`PLAY0542`,UnknownRedeliveryReaction:`PLAY0544`,IndeterminateNegatedClaimTarget:`PLAY0546`,InvalidRefusalBranch:`PLAY0538`,InvalidRefusalBranchBody:`PLAY0539`,UnmatchedRedeliveredOccurrence:`PLAY0543`,InvalidNoEventsExpectation:`PLAY0545`,InvalidProducesDeclaration:`PLAY0042`,ProducesWhenWithoutEvent:`PLAY0043`,InvalidPropertyMapping:`PLAY0044`,DuplicateProducesTarget:`PLAY0193`,EventSourceIdInPayload:`PLAY0469`,ExplicitProducesTargetsRequired:`PLAY0470`,RedundantEventId:`PLAY0471`,InvalidEventId:`PLAY0472`,InlineEventCollision:`PLAY0473`,InlineEventOutsideCommand:`PLAY0474`,InlineEventGeneration:`PLAY0475`,ReservedProductionMetadata:`PLAY0476`,InvalidEventDocumentation:`PLAY0477`,OmittedProductionDestination:`PLAY0478`,UnknownConstraintProperty:`PLAY0391`,UnknownTopLevelConstruct:`PLAY0001`,InvalidDomainDeclaration:`PLAY0002`,DuplicateDomain:`PLAY0003`,DomainNotFirst:`PLAY0004`,InvalidImportDeclaration:`PLAY0005`,TabIndentation:`PLAY0006`,InvalidConceptDeclaration:`PLAY0007`,UnknownPrimitiveType:`PLAY0008`,InvalidEnumerationValue:`PLAY0009`,UnknownConceptDirective:`PLAY0010`,ValidateReadAsEnumerationBlock:`PLAY0011`,AttributeReasonWithoutAttribute:`PLAY0012`,DuplicateAttributeReason:`PLAY0013`,InvalidTypeDeclaration:`PLAY0014`,TypeWithoutProperties:`PLAY0015`,InvalidPropertyDeclaration:`PLAY0016`,IdentifierOutsideCommand:`PLAY0017`,InvalidEventDeclaration:`PLAY0018`,IdentifierOnEventProperty:`PLAY0019`,TagPropertyReadAsTag:`PLAY0020`,InvalidModuleDeclaration:`PLAY0021`,UnknownModuleDirective:`PLAY0022`,InvalidFeatureDeclaration:`PLAY0023`,UnknownFeatureDirective:`PLAY0024`,InvalidSliceDeclaration:`PLAY0027`,UnknownSliceType:`PLAY0028`,UnknownSliceDirective:`PLAY0029`,InvalidPersonaDeclaration:`PLAY0030`,InvalidPersonaPolicyReference:`PLAY0031`,UnknownPersonaDirective:`PLAY0032`,InvalidCommandDeclaration:`PLAY0033`,UnknownCommandDirective:`PLAY0034`,DuplicateCommandIdentifier:`PLAY0036`,InvalidQueryDeclaration:`PLAY0047`,UnknownQueryDirective:`PLAY0048`,InvalidQueryParameter:`PLAY0049`,InvalidProjectionDeclaration:`PLAY0056`,EmptyProjection:`PLAY0057`,UnknownProjectionDirective:`PLAY0058`,FromWithoutEvent:`PLAY0061`,InvalidEventReference:`PLAY0062`,InvalidJoinDeclaration:`PLAY0063`,JoinWithoutEvent:`PLAY0064`,InvalidChildrenDeclaration:`PLAY0065`,InvalidNestedDeclaration:`PLAY0066`,NestedBlockWithoutFrom:`PLAY0067`,InvalidRemoveDeclaration:`PLAY0068`,UnknownRemoveDirective:`PLAY0069`,InvalidClearDeclaration:`PLAY0070`,ClearWithOutsideNestedBlock:`PLAY0071`,InvalidSpecificationDeclaration:`PLAY0094`,UnknownSpecificationDirective:`PLAY0095`,InvalidSpecificationWhen:`PLAY0096`,DuplicateSpecificationWhen:`PLAY0097`,InvalidThenError:`PLAY0098`,InvalidReadModelStep:`PLAY0099`,InvalidEventStep:`PLAY0100`,InvalidSpecificationValue:`PLAY0101`,InvalidScreenDeclaration:`PLAY0102`,UnknownScreenDirective:`PLAY0103`,InvalidDataDirective:`PLAY0104`,InvalidActionDirective:`PLAY0105`,UnknownActionDirective:`PLAY0106`,InvalidNavigation:`PLAY0107`,InvalidScreenLayoutSlot:`PLAY0108`,InvalidTitleDirective:`PLAY0109`,UnknownTableDirective:`PLAY0110`,UnknownSummaryDirective:`PLAY0111`,AuthorizeWithoutPolicy:`PLAY0122`,InvalidPolicyReference:`PLAY0123`,InvalidConstraintDeclaration:`PLAY0132`,ConstraintWithoutRule:`PLAY0133`,InvalidConstraintBody:`PLAY0134`,DuplicateConstraintBody:`PLAY0135`,InvalidReactionDeclaration:`PLAY0136`,InvalidReactionTrigger:`PLAY0137`,ReactionWithoutTrigger:`PLAY0138`,InvalidValidateDeclaration:`PLAY0140`,InvalidValidationRule:`PLAY0141`,InvalidRuleName:`PLAY0143`,UnknownRuleImplementationDirective:`PLAY0144`,InvalidDescription:`PLAY0145`,EmptyDescription:`PLAY0146`,DuplicateDescription:`PLAY0147`,TagWithoutValue:`PLAY0148`,InvalidTagValue:`PLAY0149`,UnknownContextPath:`PLAY0153`,UnknownContextCausedByProperty:`PLAY0154`,UnknownContextIdentityProperty:`PLAY0155`,ExpectedCodeFence:`PLAY0163`,UnclosedCodeBlock:`PLAY0164`,DuplicateDeclaration:`PLAY0168`,RepeatedSingularDeclarationAcrossFiles:`PLAY0172`,RepeatedDeclarationAcrossFiles:`PLAY0173`,ConflictingDescriptionAcrossFiles:`PLAY0174`,UnexpectedTokenInAuthorize:`PLAY0184`,UnclosedAuthorizeGroup:`PLAY0185`,InvalidReadModelDeclaration:`PLAY0186`,InvalidInvokesDeclaration:`PLAY0194`,InvalidScopeDeclaration:`PLAY0199`,DuplicateScope:`PLAY0200`,InvalidIntervalTrigger:`PLAY0249`,InvalidScheduleTrigger:`PLAY0250`,DuplicateReactionTrigger:`PLAY0253`,InvalidSpecificationEventSource:`PLAY0275`,DuplicateSpecificationEventSource:`PLAY0276`,InvalidProjectionVariantDeclaration:`PLAY0277`,InvalidEntersOnDeclaration:`PLAY0279`,NestedProjectionVariantNotAllowed:`PLAY0280`,InvalidStructuredValue:`PLAY0291`,DuplicateStructuredValueMember:`PLAY0294`,ConflictingSpecificationActions:`PLAY0358`,InvalidSpecificationEventOrder:`PLAY0359`,InvalidValidationSeverity:`PLAY0368`,VariantRequiresEnteringEvent:`PLAY0382`,DuplicateProjectionVariant:`PLAY0384`,DuplicateVariantEnteringEvent:`PLAY0385`,InvalidSpecificationDenied:`PLAY0388`,DuplicateAuthorizationAcrossFiles:`PLAY0394`,FileConstraintOnlySupportsUniqueness:`PLAY0396`,LegacyInlineCodeFence:`PLAY0397`,InvalidEventGeneration:`PLAY0446`,InvalidFileImport:`PLAY0454`,FileImportMatchesNothing:`PLAY0455`,ImportedFileNotFound:`PLAY0456`,ConflictingImportPlacement:`PLAY0457`,ImportCycle:`PLAY0458`,ModuleInPlacedFile:`PLAY0459`,UnexpectedInPlacedFile:`PLAY0460`,InvalidSpecificationClock:`PLAY0461`,InvalidSpecificationTrigger:`PLAY0462`,InvalidSpecificationCapture:`PLAY0463`,InvalidSpecificationQueryAction:`PLAY0464`,UnknownSpecificationQueryArgument:`PLAY0468`,InvalidSpecificationQuery:`PLAY0265`,UnknownSpecificationQueryDirective:`PLAY0266`,DuplicateSpecificationQueryArguments:`PLAY0267`,InvalidAbsentReadModelStep:`PLAY0453`,LegacyOptionalSuffix:`PLAY0479`,InvalidOptionalModifierOrder:`PLAY0480`,OptionalReadsNotSupported:`PLAY0481`,InvalidSpecificationCaller:`PLAY0386`,DuplicateSpecificationCallerOrDenied:`PLAY0387`,GeneratedPropertyOutsideCommand:`PLAY0482`,InvalidGeneratedType:`PLAY0483`,InvalidGeneratedModifierOrder:`PLAY0484`,DuplicateEventSubject:`PLAY0590`,InvalidSubjectType:`PLAY0591`,ProtectedSubjectType:`PLAY0592`,InvalidSubjectOwner:`PLAY0593`,ReadModelSubjectNotSupported:`PLAY0594`,InvalidSubjectModifierOrder:`PLAY0595`,GeneratedPropertySuppliedAsInput:`PLAY0485`,InvalidCommandResponse:`PLAY0486`,InvalidResponseSource:`PLAY0487`,DuplicateResponseField:`PLAY0488`,InvalidResponseShape:`PLAY0489`,InvalidGeneratedFixture:`PLAY0490`,InvalidReturnExpectation:`PLAY0491`,InvalidImplementationBlock:`PLAY0492`,InvalidImplementationHint:`PLAY0493`,ConflictingImplementationSources:`PLAY0494`,UnknownType:`PLAY0165`,InvalidSystemDeclaration:`PLAY0495`,InvalidOperationDeclaration:`PLAY0496`,InvalidProductionReference:`PLAY0497`,ProductionDeclarationCollision:`PLAY0498`,OperationOutsideCommand:`PLAY0499`,InvalidSystemReference:`PLAY0500`,InvalidOperationMapping:`PLAY0501`,InvalidOperationSpecification:`PLAY0502`,InvalidCaptureDeclaration:`PLAY0078`,UnknownCaptureDirective:`PLAY0079`,InvalidMapEntry:`PLAY0080`,InvalidTranslation:`PLAY0081`,InvalidSplitDeclaration:`PLAY0082`,InvalidSplitTarget:`PLAY0083`,InvalidAppendDeclaration:`PLAY0084`,UnknownAppendDirective:`PLAY0085`,WhenWithoutTrigger:`PLAY0086`,InvalidWhenClause:`PLAY0087`,InvalidWhenTransitionClause:`PLAY0088`,MixedWhenCombinators:`PLAY0089`,WhenCombinatorWithoutProperty:`PLAY0090`,UnknownCaptureBlockDirective:`PLAY0091`,InvalidCompositeKeyPart:`PLAY0072`,TemplateInCompositeKey:`PLAY0073`,EmptyCompositeKey:`PLAY0074`,InvalidProjectionMapping:`PLAY0075`,ExpectedLiteralValue:`PLAY0150`,InvalidExpression:`PLAY0152`,UnterminatedInterpolation:`PLAY0157`,UnterminatedTemplateExpression:`PLAY0156`,ProjectionDocumentWithoutProjection:`PLAY0055`,CaptureDocumentWithoutCapture:`PLAY0077`,SpecificationDocumentWithoutSpecification:`PLAY0093`,InvalidSeedDeclaration:`PLAY0128`,InvalidSeedGroup:`PLAY0129`,InvalidSeedEvent:`PLAY0130`,InvalidSeedPropertyAssignment:`PLAY0131`,InvalidPolicyDeclaration:`PLAY0112`,UnknownPolicyDirective:`PLAY0113`,PolicyWithoutRequirement:`PLAY0114`,ExpectedRoleName:`PLAY0118`,ExpectedClaimName:`PLAY0119`,ExpectedClaimMatches:`PLAY0120`,ExpectedClaimMatchTarget:`PLAY0121`,MixedPolicyImplementation:`PLAY0440`,RepeatedPolicyRequirement:`PLAY0441`,UnexpectedTokenInPolicyCondition:`PLAY0115`,ExpectedPolicyCondition:`PLAY0116`,UnclosedPolicyConditionGroup:`PLAY0117`,UnexpectedTokenInCondition:`PLAY0158`,ExpectedCondition:`PLAY0159`,ExpectedComparisonOperator:`PLAY0161`,ExpectedComparisonValue:`PLAY0162`,InvalidActionAlternative:`PLAY0341`,GuardedActionWithoutAlternatives:`PLAY0342`,MisplacedActionOtherwise:`PLAY0343`,UnsupportedActionConditionOperand:`PLAY0344`,InvalidInteractionArgument:`PLAY0319`,UnclosedConditionGroup:`PLAY0160`,InvalidNumericDirective:`PLAY0508`,DuplicateNumericDirective:`PLAY0509`,LateNumericDirective:`PLAY0510`,InexactNumericLiteral:`PLAY0511`,MixedNumericModes:`PLAY0512`,IncompatibleNumericSource:`PLAY0513`,EventFromLaterSlice:`PLAY0516`,TimelineCycleGroup:`PLAY0517`,InvalidSpecificationExample:`PLAY0518`,DuplicateSpecificationAssignment:`PLAY0519`,UnresolvedSpecificationExampleType:`PLAY0520`,SpecificationExampleNameCollision:`PLAY0521`,SpecificationExampleKindMismatch:`PLAY0522`,InvalidSpecificationExampleValue:`PLAY0523`,MissingSpecificationProperty:`PLAY0524`,UnadmittedSpecificationExampleValue:`PLAY0525`,InvalidSpecificationExampleBody:`PLAY0526`,AmbiguousReference:`PLAY0198`,InvalidSpecificationStream:`PLAY0547`,SpecificationStreamOnCommand:`PLAY0548`,InvalidSpecificationStreamRoute:`PLAY0549`,InvalidSpecificationStreamEventSource:`PLAY0550`,SpecificationStreamContradictsCommand:`PLAY0551`,InvalidDependencyTarget:`PLAY0554`,RepeatedDependencyDeclaration:`PLAY0555`,UndeclaredDependency:`PLAY0552`,UnusedDependencyDeclaration:`PLAY0553`,MutualDependencyDeclarations:`PLAY0556`,AuthorizationRefusalWithoutIdentity:`PLAY0557`,InvalidDocumentation:`PLAY0558`,ConflictingDocumentationAcrossFiles:`PLAY0559`,InvalidSpecificationCallerPersona:`PLAY0572`,UnsynthesizablePersonaCaller:`PLAY0573`,PersonaWithoutGate:`PLAY0574`,GateWithoutPersona:`PLAY0575`,AmbiguousPersonaCaller:`PLAY0576`,InvalidSpecificationParameter:`PLAY0577`,InvalidSpecificationCase:`PLAY0578`,DuplicateSpecificationParameter:`PLAY0579`,DuplicateSpecificationCase:`PLAY0580`,IncompleteSpecificationTable:`PLAY0581`,InvalidSpecificationCaseAssignment:`PLAY0582`,InvalidSpecificationCaseValue:`PLAY0583`,InvalidSpecificationCaseReference:`PLAY0584`,OptionalSpecificationParameterTarget:`PLAY0585`,SpecificationCaseNameCollision:`PLAY0586`,IncompatibleSpecificationParameterType:`PLAY0587`,UnusedSpecificationParameter:`PLAY0588`,SingularSpecificationTableExpansion:`PLAY0589`,UnsupportedInteractionAlternatives:`PLAY0560`,MixedInteractionAlternatives:`PLAY0561`,InteractionAlternativeWithoutActions:`PLAY0562`,InlineInteractionAlternative:`PLAY0563`,LegacyInteractionWhere:`PLAY0564`,InvalidEventSourceDeclaration:`PLAY0503`,InvalidCommandStream:`PLAY0504`,AmbiguousCommandStream:`PLAY0505`,UnsupportedStreamIdType:`PLAY0506`,RedundantSourceStreamId:`PLAY0507`,UnknownEvent:`PLAY0166`,UnknownReadModelProperty:`PLAY0514`,PiiNotSupportedOnIdentifier:`PLAY0515`,HandlerWithoutImplementation:`PLAY0045`,UnknownHandlerDirective:`PLAY0046`,CommandWithProducesAndHandler:`PLAY0035`,AbsoluteFileReference:`PLAY0264`,InvalidTriggerData:`PLAY0246`,InvalidReadModelKey:`PLAY0660`,IncompleteReadModelKey:`PLAY0661`,InvalidReadModelKeyLookup:`PLAY0662`,ProductionRouteOutsideCommand:`PLAY0663`,RedundantProductionRoute:`PLAY0664`,InvalidObserverFilter:`PLAY0665`,ObserverFilterExcludesEveryProducer:`PLAY0666`,MixedEnumerationNumbering:`PLAY0667`,DuplicateEnumerationNumber:`PLAY0668`,EnumerationNumberOutsideInt32:`PLAY0669`,MalformedEnumerationNumber:`PLAY0670`,UnpinnedStoredEnumeration:`PLAY0671`,ReadsWithChildren:`PLAY0451`,UnknownGenerationStrategy:`PLAY0672`,InvalidGenerationArgument:`PLAY0673`,InvalidGenerationModifier:`PLAY0674`,DuplicateGenerationModifier:`PLAY0675`,DuplicateGeneration:`PLAY0676`,InvalidGenerationPrimitive:`PLAY0677`,InvalidGenerationPrefix:`PLAY0678`,InvalidGenerationAlphabet:`PLAY0679`,InvalidTypeIdPrefix:`PLAY0680`,GenerationSizeOutsideRange:`PLAY0681`,ReservedSequenceGeneration:`PLAY0682`,LowGenerationEntropy:`PLAY0683`,LowGeneratedIdentifierEntropy:`PLAY0684`,ResponseNameUsedOnFailure:`PLAY0685`};export{e as DiagnosticCodes};
2
2
  //# sourceMappingURL=DiagnosticCodes.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"DiagnosticCodes.js","names":["DiagnosticCodes"],"sources":["../../../../../../Compiler/Diagnostics/DiagnosticCodes.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\n// Shared diagnostic names, including the explicitly C#-only checks below. Catalogue membership does\n// not imply TypeScript validation support; see Documentation/screenplay/editor-diagnostics.md.\nexport const DiagnosticCodes = {\n InvalidIdentityDeclaration: 'PLAY0633',\n DuplicateIdentity: 'PLAY0634',\n InvalidIdentityDetail: 'PLAY0635',\n UnknownIdentitySource: 'PLAY0636',\n IdentityDetailWithoutSource: 'PLAY0637',\n IdentitySourceWithBody: 'PLAY0638',\n DuplicateIdentityDetail: 'PLAY0639',\n BuiltInIdentityDetail: 'PLAY0640',\n UnknownIdentityQuery: 'PLAY0641',\n InvalidIdentityQuery: 'PLAY0642',\n IdentityQueryWithoutKey: 'PLAY0643',\n InvalidIdentityQueryKey: 'PLAY0644',\n IdentityQueryAuthorizationDependency: 'PLAY0645',\n IdentityQueryTypeMismatch: 'PLAY0646',\n InvalidReactionIdentity: 'PLAY0647',\n GatedInvocationWithoutIdentity: 'PLAY0648',\n UnusedReactionIdentity: 'PLAY0649',\n UnusedReactionRole: 'PLAY0650',\n UnsatisfiedReactionIdentity: 'PLAY0651',\n ReactionPrivilegeEscalation: 'PLAY0652',\n // C#-only whole-model public event boundaries; membership is not TypeScript validation support.\n CommandProducesPublicEvent: 'PLAY0607',\n PublicEventRequiresOutboundTranslation: 'PLAY0608',\n OutboundPublicEventCount: 'PLAY0609',\n ForeignPublicEventConsumer: 'PLAY0610',\n OutboundTranslationInput: 'PLAY0611',\n InboundTranslationOutput: 'PLAY0612',\n ForeignPublicEventProduced: 'PLAY0613',\n PublicTranslationRequiresDirection: 'PLAY0614',\n TranslationConstructDirection: 'PLAY0615',\n InboundTranslationInput: 'PLAY0616',\n OutboundTranslationOutput: 'PLAY0617',\n EventTargetOutsideOutboundTranslation: 'PLAY0618',\n EventsSourceOutsideInboundTranslation: 'PLAY0619',\n InvalidCaptureEventsSource: 'PLAY0620',\n // Syntax shared with C#; the reference checks (owners, instances, cycles, outlets, scopes, packages) are C#-only.\n InvalidExposureDeclaration: 'PLAY0621',\n UnknownExposureOwner: 'PLAY0622',\n ReExposureCycle: 'PLAY0623',\n ReExposureBroken: 'PLAY0624',\n InvalidInstanceContribution: 'PLAY0625',\n UnknownContributionInstance: 'PLAY0626',\n ContributionNotExposed: 'PLAY0627',\n ContributionTypeMismatch: 'PLAY0628',\n UnknownTemplateContentSlot: 'PLAY0629',\n UnknownNavigationOutlet: 'PLAY0630',\n TemplateScopeMismatch: 'PLAY0631',\n IncompatibleComponentPackage: 'PLAY0632',\n UnknownNavigationDestination: 'PLAY0654',\n UnknownScreenContributionPoint: 'PLAY0655',\n TemplateNestingCycle: 'PLAY0656',\n DuplicateComplianceMarker: 'PLAY0653',\n LegacyComplianceMarker: 'PLAY0565',\n UnknownComplianceMarker: 'PLAY0566',\n InvalidSecretScope: 'PLAY0567',\n DuplicateSecretScope: 'PLAY0568',\n SecretScopeIgnoredForPii: 'PLAY0569',\n InvalidPersonalDataQualifier: 'PLAY0570',\n DuplicateSpecialCategory: 'PLAY0571',\n InvalidPurposeDeclaration: 'PLAY0596',\n InvalidPurposeVocabulary: 'PLAY0597',\n DuplicatePurposeField: 'PLAY0598',\n DuplicatePurposeDeclaration: 'PLAY0599',\n UnknownPurpose: 'PLAY0600',\n PurposeInterestMismatch: 'PLAY0601',\n PersonalDataWithoutPurpose: 'PLAY0602',\n SpecialDataWithoutCondition: 'PLAY0603',\n CriminalDataWithoutAuthorization: 'PLAY0604',\n PurposeWithoutBasis: 'PLAY0605',\n UnusedPurpose: 'PLAY0606',\n // C#-only: opt-in completeness, scoped action/refusal reference validation, and semantic binding.\n ConflictingScreenDataBinding: 'PLAY0530',\n ScreenDataQueryMismatch: 'PLAY0531',\n ActionWithoutInputSurface: 'PLAY0532',\n CommandWithoutInputSurface: 'PLAY0533',\n ReadModelFieldWithoutOrigin: 'PLAY0534',\n QueryParameterNotHeldByView: 'PLAY0535',\n UnconsumedEvent: 'PLAY0536',\n UnreachableScreen: 'PLAY0537',\n UnknownActionSubjectField: 'PLAY0345',\n UnresolvedActionSubject: 'PLAY0346',\n UnreachableActionAlternative: 'PLAY0347',\n UnknownActionArgumentProperty: 'PLAY0348',\n UnreachableRefusalBranch: 'PLAY0540',\n InvalidRefusalValue: 'PLAY0541',\n UnknownRefusalConstraint: 'PLAY0542',\n UnknownRedeliveryReaction: 'PLAY0544',\n IndeterminateNegatedClaimTarget: 'PLAY0546',\n InvalidRefusalBranch: 'PLAY0538',\n InvalidRefusalBranchBody: 'PLAY0539',\n UnmatchedRedeliveredOccurrence: 'PLAY0543',\n InvalidNoEventsExpectation: 'PLAY0545',\n InvalidProducesDeclaration: 'PLAY0042',\n ProducesWhenWithoutEvent: 'PLAY0043',\n InvalidPropertyMapping: 'PLAY0044',\n DuplicateProducesTarget: 'PLAY0193',\n EventSourceIdInPayload: 'PLAY0469',\n ExplicitProducesTargetsRequired: 'PLAY0470',\n RedundantEventId: 'PLAY0471',\n InvalidEventId: 'PLAY0472',\n InlineEventCollision: 'PLAY0473',\n InlineEventOutsideCommand: 'PLAY0474',\n InlineEventGeneration: 'PLAY0475',\n ReservedProductionMetadata: 'PLAY0476',\n InvalidEventDocumentation: 'PLAY0477',\n OmittedProductionDestination: 'PLAY0478',\n UnknownConstraintProperty: 'PLAY0391',\n UnknownTopLevelConstruct: 'PLAY0001',\n InvalidDomainDeclaration: 'PLAY0002',\n DuplicateDomain: 'PLAY0003',\n DomainNotFirst: 'PLAY0004',\n InvalidImportDeclaration: 'PLAY0005',\n TabIndentation: 'PLAY0006',\n InvalidConceptDeclaration: 'PLAY0007',\n UnknownPrimitiveType: 'PLAY0008',\n InvalidEnumerationValue: 'PLAY0009',\n UnknownConceptDirective: 'PLAY0010',\n ValidateReadAsEnumerationBlock: 'PLAY0011',\n AttributeReasonWithoutAttribute: 'PLAY0012',\n DuplicateAttributeReason: 'PLAY0013',\n InvalidTypeDeclaration: 'PLAY0014',\n TypeWithoutProperties: 'PLAY0015',\n InvalidPropertyDeclaration: 'PLAY0016',\n IdentifierOutsideCommand: 'PLAY0017',\n InvalidEventDeclaration: 'PLAY0018',\n IdentifierOnEventProperty: 'PLAY0019',\n TagPropertyReadAsTag: 'PLAY0020',\n InvalidModuleDeclaration: 'PLAY0021',\n UnknownModuleDirective: 'PLAY0022',\n InvalidFeatureDeclaration: 'PLAY0023',\n UnknownFeatureDirective: 'PLAY0024',\n InvalidSliceDeclaration: 'PLAY0027',\n UnknownSliceType: 'PLAY0028',\n UnknownSliceDirective: 'PLAY0029',\n InvalidPersonaDeclaration: 'PLAY0030',\n InvalidPersonaPolicyReference: 'PLAY0031',\n UnknownPersonaDirective: 'PLAY0032',\n InvalidCommandDeclaration: 'PLAY0033',\n UnknownCommandDirective: 'PLAY0034',\n DuplicateCommandIdentifier: 'PLAY0036',\n InvalidQueryDeclaration: 'PLAY0047',\n UnknownQueryDirective: 'PLAY0048',\n InvalidQueryParameter: 'PLAY0049',\n InvalidProjectionDeclaration: 'PLAY0056',\n EmptyProjection: 'PLAY0057',\n UnknownProjectionDirective: 'PLAY0058',\n FromWithoutEvent: 'PLAY0061',\n InvalidEventReference: 'PLAY0062',\n InvalidJoinDeclaration: 'PLAY0063',\n JoinWithoutEvent: 'PLAY0064',\n InvalidChildrenDeclaration: 'PLAY0065',\n InvalidNestedDeclaration: 'PLAY0066',\n NestedBlockWithoutFrom: 'PLAY0067',\n InvalidRemoveDeclaration: 'PLAY0068',\n UnknownRemoveDirective: 'PLAY0069',\n InvalidClearDeclaration: 'PLAY0070',\n ClearWithOutsideNestedBlock: 'PLAY0071',\n InvalidSpecificationDeclaration: 'PLAY0094',\n UnknownSpecificationDirective: 'PLAY0095',\n InvalidSpecificationWhen: 'PLAY0096',\n DuplicateSpecificationWhen: 'PLAY0097',\n InvalidThenError: 'PLAY0098',\n InvalidReadModelStep: 'PLAY0099',\n InvalidEventStep: 'PLAY0100',\n InvalidSpecificationValue: 'PLAY0101',\n InvalidScreenDeclaration: 'PLAY0102',\n UnknownScreenDirective: 'PLAY0103',\n InvalidDataDirective: 'PLAY0104',\n InvalidActionDirective: 'PLAY0105',\n UnknownActionDirective: 'PLAY0106',\n InvalidNavigation: 'PLAY0107',\n InvalidScreenLayoutSlot: 'PLAY0108',\n InvalidTitleDirective: 'PLAY0109',\n UnknownTableDirective: 'PLAY0110',\n UnknownSummaryDirective: 'PLAY0111',\n AuthorizeWithoutPolicy: 'PLAY0122',\n InvalidPolicyReference: 'PLAY0123',\n InvalidConstraintDeclaration: 'PLAY0132',\n ConstraintWithoutRule: 'PLAY0133',\n InvalidConstraintBody: 'PLAY0134',\n DuplicateConstraintBody: 'PLAY0135',\n InvalidReactionDeclaration: 'PLAY0136',\n InvalidReactionTrigger: 'PLAY0137',\n ReactionWithoutTrigger: 'PLAY0138',\n InvalidValidateDeclaration: 'PLAY0140',\n InvalidValidationRule: 'PLAY0141',\n InvalidRuleName: 'PLAY0143',\n UnknownRuleImplementationDirective: 'PLAY0144',\n InvalidDescription: 'PLAY0145',\n EmptyDescription: 'PLAY0146',\n DuplicateDescription: 'PLAY0147',\n TagWithoutValue: 'PLAY0148',\n InvalidTagValue: 'PLAY0149',\n UnknownContextPath: 'PLAY0153',\n UnknownContextCausedByProperty: 'PLAY0154',\n UnknownContextIdentityProperty: 'PLAY0155',\n ExpectedCodeFence: 'PLAY0163',\n UnclosedCodeBlock: 'PLAY0164',\n DuplicateDeclaration: 'PLAY0168',\n RepeatedSingularDeclarationAcrossFiles: 'PLAY0172',\n RepeatedDeclarationAcrossFiles: 'PLAY0173',\n ConflictingDescriptionAcrossFiles: 'PLAY0174',\n UnexpectedTokenInAuthorize: 'PLAY0184',\n UnclosedAuthorizeGroup: 'PLAY0185',\n InvalidReadModelDeclaration: 'PLAY0186',\n InvalidInvokesDeclaration: 'PLAY0194',\n InvalidScopeDeclaration: 'PLAY0199',\n DuplicateScope: 'PLAY0200',\n InvalidIntervalTrigger: 'PLAY0249',\n InvalidScheduleTrigger: 'PLAY0250',\n DuplicateReactionTrigger: 'PLAY0253',\n InvalidSpecificationEventSource: 'PLAY0275',\n DuplicateSpecificationEventSource: 'PLAY0276',\n InvalidProjectionVariantDeclaration: 'PLAY0277',\n InvalidEntersOnDeclaration: 'PLAY0279',\n NestedProjectionVariantNotAllowed: 'PLAY0280',\n InvalidStructuredValue: 'PLAY0291',\n DuplicateStructuredValueMember: 'PLAY0294',\n ConflictingSpecificationActions: 'PLAY0358',\n InvalidSpecificationEventOrder: 'PLAY0359',\n InvalidValidationSeverity: 'PLAY0368',\n VariantRequiresEnteringEvent: 'PLAY0382',\n DuplicateProjectionVariant: 'PLAY0384',\n DuplicateVariantEnteringEvent: 'PLAY0385',\n InvalidSpecificationDenied: 'PLAY0388',\n DuplicateAuthorizationAcrossFiles: 'PLAY0394',\n FileConstraintOnlySupportsUniqueness: 'PLAY0396',\n LegacyInlineCodeFence: 'PLAY0397',\n InvalidEventGeneration: 'PLAY0446',\n InvalidFileImport: 'PLAY0454',\n FileImportMatchesNothing: 'PLAY0455',\n ImportedFileNotFound: 'PLAY0456',\n ConflictingImportPlacement: 'PLAY0457',\n ImportCycle: 'PLAY0458',\n ModuleInPlacedFile: 'PLAY0459',\n UnexpectedInPlacedFile: 'PLAY0460',\n InvalidSpecificationClock: 'PLAY0461',\n InvalidSpecificationTrigger: 'PLAY0462',\n InvalidSpecificationCapture: 'PLAY0463',\n InvalidSpecificationQueryAction: 'PLAY0464',\n UnknownSpecificationQueryArgument: 'PLAY0468',\n InvalidSpecificationQuery: 'PLAY0265',\n UnknownSpecificationQueryDirective: 'PLAY0266',\n DuplicateSpecificationQueryArguments: 'PLAY0267',\n InvalidAbsentReadModelStep: 'PLAY0453',\n LegacyOptionalSuffix: 'PLAY0479',\n InvalidOptionalModifierOrder: 'PLAY0480',\n OptionalReadsNotSupported: 'PLAY0481',\n InvalidSpecificationCaller: 'PLAY0386',\n DuplicateSpecificationCallerOrDenied: 'PLAY0387',\n GeneratedPropertyOutsideCommand: 'PLAY0482',\n InvalidGeneratedType: 'PLAY0483',\n InvalidGeneratedModifierOrder: 'PLAY0484',\n DuplicateEventSubject: 'PLAY0590',\n InvalidSubjectType: 'PLAY0591',\n ProtectedSubjectType: 'PLAY0592',\n InvalidSubjectOwner: 'PLAY0593',\n ReadModelSubjectNotSupported: 'PLAY0594',\n InvalidSubjectModifierOrder: 'PLAY0595',\n GeneratedPropertySuppliedAsInput: 'PLAY0485',\n InvalidCommandResponse: 'PLAY0486',\n InvalidResponseSource: 'PLAY0487',\n DuplicateResponseField: 'PLAY0488',\n InvalidResponseShape: 'PLAY0489',\n InvalidGeneratedFixture: 'PLAY0490',\n InvalidReturnExpectation: 'PLAY0491',\n InvalidImplementationBlock: 'PLAY0492',\n InvalidImplementationHint: 'PLAY0493',\n ConflictingImplementationSources: 'PLAY0494',\n UnknownType: 'PLAY0165',\n InvalidSystemDeclaration: 'PLAY0495',\n InvalidOperationDeclaration: 'PLAY0496',\n InvalidProductionReference: 'PLAY0497',\n ProductionDeclarationCollision: 'PLAY0498',\n OperationOutsideCommand: 'PLAY0499',\n InvalidSystemReference: 'PLAY0500',\n InvalidOperationMapping: 'PLAY0501',\n InvalidOperationSpecification: 'PLAY0502',\n InvalidCaptureDeclaration: 'PLAY0078',\n UnknownCaptureDirective: 'PLAY0079',\n InvalidMapEntry: 'PLAY0080',\n InvalidTranslation: 'PLAY0081',\n InvalidSplitDeclaration: 'PLAY0082',\n InvalidSplitTarget: 'PLAY0083',\n InvalidAppendDeclaration: 'PLAY0084',\n UnknownAppendDirective: 'PLAY0085',\n WhenWithoutTrigger: 'PLAY0086',\n InvalidWhenClause: 'PLAY0087',\n InvalidWhenTransitionClause: 'PLAY0088',\n MixedWhenCombinators: 'PLAY0089',\n WhenCombinatorWithoutProperty: 'PLAY0090',\n UnknownCaptureBlockDirective: 'PLAY0091',\n InvalidCompositeKeyPart: 'PLAY0072',\n TemplateInCompositeKey: 'PLAY0073',\n EmptyCompositeKey: 'PLAY0074',\n InvalidProjectionMapping: 'PLAY0075',\n ExpectedLiteralValue: 'PLAY0150',\n InvalidExpression: 'PLAY0152',\n UnterminatedInterpolation: 'PLAY0157',\n UnterminatedTemplateExpression: 'PLAY0156',\n ProjectionDocumentWithoutProjection: 'PLAY0055',\n CaptureDocumentWithoutCapture: 'PLAY0077',\n SpecificationDocumentWithoutSpecification: 'PLAY0093',\n InvalidSeedDeclaration: 'PLAY0128',\n InvalidSeedGroup: 'PLAY0129',\n InvalidSeedEvent: 'PLAY0130',\n InvalidSeedPropertyAssignment: 'PLAY0131',\n InvalidPolicyDeclaration: 'PLAY0112',\n UnknownPolicyDirective: 'PLAY0113',\n PolicyWithoutRequirement: 'PLAY0114',\n ExpectedRoleName: 'PLAY0118',\n ExpectedClaimName: 'PLAY0119',\n ExpectedClaimMatches: 'PLAY0120',\n ExpectedClaimMatchTarget: 'PLAY0121',\n MixedPolicyImplementation: 'PLAY0440',\n RepeatedPolicyRequirement: 'PLAY0441',\n UnexpectedTokenInPolicyCondition: 'PLAY0115',\n ExpectedPolicyCondition: 'PLAY0116',\n UnclosedPolicyConditionGroup: 'PLAY0117',\n UnexpectedTokenInCondition: 'PLAY0158',\n ExpectedCondition: 'PLAY0159',\n ExpectedComparisonOperator: 'PLAY0161',\n ExpectedComparisonValue: 'PLAY0162',\n InvalidActionAlternative: 'PLAY0341',\n GuardedActionWithoutAlternatives: 'PLAY0342',\n MisplacedActionOtherwise: 'PLAY0343',\n UnsupportedActionConditionOperand: 'PLAY0344',\n InvalidInteractionArgument: 'PLAY0319',\n UnclosedConditionGroup: 'PLAY0160',\n InvalidNumericDirective: 'PLAY0508',\n DuplicateNumericDirective: 'PLAY0509',\n LateNumericDirective: 'PLAY0510',\n InexactNumericLiteral: 'PLAY0511',\n MixedNumericModes: 'PLAY0512',\n IncompatibleNumericSource: 'PLAY0513',\n EventFromLaterSlice: 'PLAY0516',\n TimelineCycleGroup: 'PLAY0517',\n InvalidSpecificationExample: 'PLAY0518',\n DuplicateSpecificationAssignment: 'PLAY0519',\n UnresolvedSpecificationExampleType: 'PLAY0520',\n SpecificationExampleNameCollision: 'PLAY0521',\n SpecificationExampleKindMismatch: 'PLAY0522',\n InvalidSpecificationExampleValue: 'PLAY0523',\n MissingSpecificationProperty: 'PLAY0524',\n UnadmittedSpecificationExampleValue: 'PLAY0525',\n InvalidSpecificationExampleBody: 'PLAY0526',\n AmbiguousReference: 'PLAY0198',\n InvalidSpecificationStream: 'PLAY0547',\n SpecificationStreamOnCommand: 'PLAY0548',\n InvalidSpecificationStreamRoute: 'PLAY0549',\n InvalidSpecificationStreamEventSource: 'PLAY0550',\n SpecificationStreamContradictsCommand: 'PLAY0551',\n InvalidDependencyTarget: 'PLAY0554',\n RepeatedDependencyDeclaration: 'PLAY0555',\n UndeclaredDependency: 'PLAY0552',\n UnusedDependencyDeclaration: 'PLAY0553',\n MutualDependencyDeclarations: 'PLAY0556',\n AuthorizationRefusalWithoutIdentity: 'PLAY0557',\n InvalidDocumentation: 'PLAY0558',\n ConflictingDocumentationAcrossFiles: 'PLAY0559',\n InvalidSpecificationCallerPersona: 'PLAY0572',\n UnsynthesizablePersonaCaller: 'PLAY0573',\n PersonaWithoutGate: 'PLAY0574',\n GateWithoutPersona: 'PLAY0575',\n AmbiguousPersonaCaller: 'PLAY0576',\n InvalidSpecificationParameter: 'PLAY0577',\n InvalidSpecificationCase: 'PLAY0578',\n DuplicateSpecificationParameter: 'PLAY0579',\n DuplicateSpecificationCase: 'PLAY0580',\n IncompleteSpecificationTable: 'PLAY0581',\n InvalidSpecificationCaseAssignment: 'PLAY0582',\n InvalidSpecificationCaseValue: 'PLAY0583',\n InvalidSpecificationCaseReference: 'PLAY0584',\n OptionalSpecificationParameterTarget: 'PLAY0585',\n SpecificationCaseNameCollision: 'PLAY0586',\n IncompatibleSpecificationParameterType: 'PLAY0587',\n UnusedSpecificationParameter: 'PLAY0588',\n SingularSpecificationTableExpansion: 'PLAY0589',\n UnsupportedInteractionAlternatives: 'PLAY0560',\n MixedInteractionAlternatives: 'PLAY0561',\n InteractionAlternativeWithoutActions: 'PLAY0562',\n InlineInteractionAlternative: 'PLAY0563',\n LegacyInteractionWhere: 'PLAY0564',\n InvalidEventSourceDeclaration: 'PLAY0503',\n InvalidCommandStream: 'PLAY0504',\n AmbiguousCommandStream: 'PLAY0505',\n UnsupportedStreamIdType: 'PLAY0506',\n RedundantSourceStreamId: 'PLAY0507',\n UnknownEvent: 'PLAY0166',\n UnknownReadModelProperty: 'PLAY0514',\n PiiNotSupportedOnIdentifier: 'PLAY0515',\n HandlerWithoutImplementation: 'PLAY0045',\n UnknownHandlerDirective: 'PLAY0046',\n CommandWithProducesAndHandler: 'PLAY0035',\n AbsoluteFileReference: 'PLAY0264',\n InvalidTriggerData: 'PLAY0246',\n InvalidReadModelKey: 'PLAY0660',\n IncompleteReadModelKey: 'PLAY0661', // C# only: scoped read-model key resolution.\n InvalidReadModelKeyLookup: 'PLAY0662', // Shape checks shared; scoped lookup checks are C# only.\n ProductionRouteOutsideCommand: 'PLAY0663',\n RedundantProductionRoute: 'PLAY0664',\n InvalidObserverFilter: 'PLAY0665',\n ObserverFilterExcludesEveryProducer: 'PLAY0666', // C# only: statically known producer routes.\n MixedEnumerationNumbering: 'PLAY0667',\n DuplicateEnumerationNumber: 'PLAY0668',\n EnumerationNumberOutsideInt32: 'PLAY0669',\n MalformedEnumerationNumber: 'PLAY0670',\n UnpinnedStoredEnumeration: 'PLAY0671',\n ReadsWithChildren: 'PLAY0451',\n UnknownGenerationStrategy: 'PLAY0672',\n InvalidGenerationArgument: 'PLAY0673',\n InvalidGenerationModifier: 'PLAY0674',\n DuplicateGenerationModifier: 'PLAY0675',\n DuplicateGeneration: 'PLAY0676',\n InvalidGenerationPrimitive: 'PLAY0677',\n InvalidGenerationPrefix: 'PLAY0678',\n InvalidGenerationAlphabet: 'PLAY0679',\n InvalidTypeIdPrefix: 'PLAY0680',\n GenerationSizeOutsideRange: 'PLAY0681',\n ReservedSequenceGeneration: 'PLAY0682',\n LowGenerationEntropy: 'PLAY0683',\n LowGeneratedIdentifierEntropy: 'PLAY0684',\n} as const;\n"],"mappings":"AAKA,MAAaA,EAAkB,CAC3B,2BAA4B,WAC5B,kBAAmB,WACnB,sBAAuB,WACvB,sBAAuB,WACvB,4BAA6B,WAC7B,uBAAwB,WACxB,wBAAyB,WACzB,sBAAuB,WACvB,qBAAsB,WACtB,qBAAsB,WACtB,wBAAyB,WACzB,wBAAyB,WACzB,qCAAsC,WACtC,0BAA2B,WAC3B,wBAAyB,WACzB,+BAAgC,WAChC,uBAAwB,WACxB,mBAAoB,WACpB,4BAA6B,WAC7B,4BAA6B,WAE7B,2BAA4B,WAC5B,uCAAwC,WACxC,yBAA0B,WAC1B,2BAA4B,WAC5B,yBAA0B,WAC1B,y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rC,kCAAmC,WACnC,6BAA8B,WAC9B,mBAAoB,WACpB,mBAAoB,WACpB,uBAAwB,WACxB,8BAA+B,WAC/B,yBAA0B,WAC1B,gCAAiC,WACjC,2BAA4B,WAC5B,6BAA8B,WAC9B,mCAAoC,WACpC,8BAA+B,WAC/B,kCAAmC,WACnC,qCAAsC,WACtC,+BAAgC,WAChC,uCAAwC,WACxC,6BAA8B,WAC9B,oCAAqC,WACrC,mCAAoC,WACpC,6BAA8B,WAC9B,qCAAsC,WACtC,6BAA8B,WAC9B,uBAAwB,WACxB,8BAA+B,WAC/B,qBAAsB,WACtB,uBAAwB,WACxB,wBAAyB,WACzB,wBAAyB,WACzB,aAAc,WACd,yBAA0B,WAC1B,4BAA6B,WAC7B,6BAA8B,WAC9B,wBAAyB,WACzB,8BAA+B,WAC/B,sBAAuB,WACvB,mBAAoB,WACpB,oBAAqB,WACrB,uBAAwB,WACxB,0BAA2B,WAC3B,8BAA+B,WAC/B,yBAA0B,WAC1B,sBAAuB,WACvB,oCAAqC,WACrC,0BAA2B,WAC3B,2BAA4B,WAC5B,8BAA+B,WAC/B,2BAA4B,WAC5B,0BAA2B,WAC3B,kBAAmB,WACnB,0BAA2B,WAC3B,0BAA2B,WAC3B,0BAA2B,WAC3B,4BAA6B,WAC7B,oBAAqB,WACrB,2BAA4B,WAC5B,wBAAyB,WACzB,0BAA2B,WAC3B,oBAAqB,WACrB,2BAA4B,WAC5B,2BAA4B,WAC5B,qBAAsB,WACtB,8BAA+B,UACnC"}
1
+ {"version":3,"file":"DiagnosticCodes.js","names":["DiagnosticCodes"],"sources":["../../../../../../Compiler/Diagnostics/DiagnosticCodes.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\n// Shared diagnostic names, including the explicitly C#-only checks below. Catalogue membership does\n// not imply TypeScript validation support; see Documentation/screenplay/editor-diagnostics.md.\nexport const DiagnosticCodes = {\n InvalidIdentityDeclaration: 'PLAY0633',\n DuplicateIdentity: 'PLAY0634',\n InvalidIdentityDetail: 'PLAY0635',\n UnknownIdentitySource: 'PLAY0636',\n IdentityDetailWithoutSource: 'PLAY0637',\n IdentitySourceWithBody: 'PLAY0638',\n DuplicateIdentityDetail: 'PLAY0639',\n BuiltInIdentityDetail: 'PLAY0640',\n UnknownIdentityQuery: 'PLAY0641',\n InvalidIdentityQuery: 'PLAY0642',\n IdentityQueryWithoutKey: 'PLAY0643',\n InvalidIdentityQueryKey: 'PLAY0644',\n IdentityQueryAuthorizationDependency: 'PLAY0645',\n IdentityQueryTypeMismatch: 'PLAY0646',\n InvalidReactionIdentity: 'PLAY0647',\n GatedInvocationWithoutIdentity: 'PLAY0648',\n UnusedReactionIdentity: 'PLAY0649',\n UnusedReactionRole: 'PLAY0650',\n UnsatisfiedReactionIdentity: 'PLAY0651',\n ReactionPrivilegeEscalation: 'PLAY0652',\n // C#-only whole-model public event boundaries; membership is not TypeScript validation support.\n CommandProducesPublicEvent: 'PLAY0607',\n PublicEventRequiresOutboundTranslation: 'PLAY0608',\n OutboundPublicEventCount: 'PLAY0609',\n ForeignPublicEventConsumer: 'PLAY0610',\n OutboundTranslationInput: 'PLAY0611',\n InboundTranslationOutput: 'PLAY0612',\n ForeignPublicEventProduced: 'PLAY0613',\n PublicTranslationRequiresDirection: 'PLAY0614',\n TranslationConstructDirection: 'PLAY0615',\n InboundTranslationInput: 'PLAY0616',\n OutboundTranslationOutput: 'PLAY0617',\n EventTargetOutsideOutboundTranslation: 'PLAY0618',\n EventsSourceOutsideInboundTranslation: 'PLAY0619',\n InvalidCaptureEventsSource: 'PLAY0620',\n // Syntax shared with C#; the reference checks (owners, instances, cycles, outlets, scopes, packages) are C#-only.\n InvalidExposureDeclaration: 'PLAY0621',\n UnknownExposureOwner: 'PLAY0622',\n ReExposureCycle: 'PLAY0623',\n ReExposureBroken: 'PLAY0624',\n InvalidInstanceContribution: 'PLAY0625',\n UnknownContributionInstance: 'PLAY0626',\n ContributionNotExposed: 'PLAY0627',\n ContributionTypeMismatch: 'PLAY0628',\n UnknownTemplateContentSlot: 'PLAY0629',\n UnknownNavigationOutlet: 'PLAY0630',\n TemplateScopeMismatch: 'PLAY0631',\n IncompatibleComponentPackage: 'PLAY0632',\n UnknownNavigationDestination: 'PLAY0654',\n UnknownScreenContributionPoint: 'PLAY0655',\n TemplateNestingCycle: 'PLAY0656',\n DuplicateComplianceMarker: 'PLAY0653',\n LegacyComplianceMarker: 'PLAY0565',\n UnknownComplianceMarker: 'PLAY0566',\n InvalidSecretScope: 'PLAY0567',\n DuplicateSecretScope: 'PLAY0568',\n SecretScopeIgnoredForPii: 'PLAY0569',\n InvalidPersonalDataQualifier: 'PLAY0570',\n DuplicateSpecialCategory: 'PLAY0571',\n InvalidPurposeDeclaration: 'PLAY0596',\n InvalidPurposeVocabulary: 'PLAY0597',\n DuplicatePurposeField: 'PLAY0598',\n DuplicatePurposeDeclaration: 'PLAY0599',\n UnknownPurpose: 'PLAY0600',\n PurposeInterestMismatch: 'PLAY0601',\n PersonalDataWithoutPurpose: 'PLAY0602',\n SpecialDataWithoutCondition: 'PLAY0603',\n CriminalDataWithoutAuthorization: 'PLAY0604',\n PurposeWithoutBasis: 'PLAY0605',\n UnusedPurpose: 'PLAY0606',\n // C#-only: opt-in completeness, scoped action/refusal reference validation, and semantic binding.\n ConflictingScreenDataBinding: 'PLAY0530',\n ScreenDataQueryMismatch: 'PLAY0531',\n ActionWithoutInputSurface: 'PLAY0532',\n CommandWithoutInputSurface: 'PLAY0533',\n ReadModelFieldWithoutOrigin: 'PLAY0534',\n QueryParameterNotHeldByView: 'PLAY0535',\n UnconsumedEvent: 'PLAY0536',\n UnreachableScreen: 'PLAY0537',\n UnknownActionSubjectField: 'PLAY0345',\n UnresolvedActionSubject: 'PLAY0346',\n UnreachableActionAlternative: 'PLAY0347',\n UnknownActionArgumentProperty: 'PLAY0348',\n UnreachableRefusalBranch: 'PLAY0540',\n InvalidRefusalValue: 'PLAY0541',\n UnknownRefusalConstraint: 'PLAY0542',\n UnknownRedeliveryReaction: 'PLAY0544',\n IndeterminateNegatedClaimTarget: 'PLAY0546',\n InvalidRefusalBranch: 'PLAY0538',\n InvalidRefusalBranchBody: 'PLAY0539',\n UnmatchedRedeliveredOccurrence: 'PLAY0543',\n InvalidNoEventsExpectation: 'PLAY0545',\n InvalidProducesDeclaration: 'PLAY0042',\n ProducesWhenWithoutEvent: 'PLAY0043',\n InvalidPropertyMapping: 'PLAY0044',\n DuplicateProducesTarget: 'PLAY0193',\n EventSourceIdInPayload: 'PLAY0469',\n ExplicitProducesTargetsRequired: 'PLAY0470',\n RedundantEventId: 'PLAY0471',\n InvalidEventId: 'PLAY0472',\n InlineEventCollision: 'PLAY0473',\n InlineEventOutsideCommand: 'PLAY0474',\n InlineEventGeneration: 'PLAY0475',\n ReservedProductionMetadata: 'PLAY0476',\n InvalidEventDocumentation: 'PLAY0477',\n OmittedProductionDestination: 'PLAY0478',\n UnknownConstraintProperty: 'PLAY0391',\n UnknownTopLevelConstruct: 'PLAY0001',\n InvalidDomainDeclaration: 'PLAY0002',\n DuplicateDomain: 'PLAY0003',\n DomainNotFirst: 'PLAY0004',\n InvalidImportDeclaration: 'PLAY0005',\n TabIndentation: 'PLAY0006',\n InvalidConceptDeclaration: 'PLAY0007',\n UnknownPrimitiveType: 'PLAY0008',\n InvalidEnumerationValue: 'PLAY0009',\n UnknownConceptDirective: 'PLAY0010',\n ValidateReadAsEnumerationBlock: 'PLAY0011',\n AttributeReasonWithoutAttribute: 'PLAY0012',\n DuplicateAttributeReason: 'PLAY0013',\n InvalidTypeDeclaration: 'PLAY0014',\n TypeWithoutProperties: 'PLAY0015',\n InvalidPropertyDeclaration: 'PLAY0016',\n IdentifierOutsideCommand: 'PLAY0017',\n InvalidEventDeclaration: 'PLAY0018',\n IdentifierOnEventProperty: 'PLAY0019',\n TagPropertyReadAsTag: 'PLAY0020',\n InvalidModuleDeclaration: 'PLAY0021',\n UnknownModuleDirective: 'PLAY0022',\n InvalidFeatureDeclaration: 'PLAY0023',\n UnknownFeatureDirective: 'PLAY0024',\n InvalidSliceDeclaration: 'PLAY0027',\n UnknownSliceType: 'PLAY0028',\n UnknownSliceDirective: 'PLAY0029',\n InvalidPersonaDeclaration: 'PLAY0030',\n InvalidPersonaPolicyReference: 'PLAY0031',\n UnknownPersonaDirective: 'PLAY0032',\n InvalidCommandDeclaration: 'PLAY0033',\n UnknownCommandDirective: 'PLAY0034',\n DuplicateCommandIdentifier: 'PLAY0036',\n InvalidQueryDeclaration: 'PLAY0047',\n UnknownQueryDirective: 'PLAY0048',\n InvalidQueryParameter: 'PLAY0049',\n InvalidProjectionDeclaration: 'PLAY0056',\n EmptyProjection: 'PLAY0057',\n UnknownProjectionDirective: 'PLAY0058',\n FromWithoutEvent: 'PLAY0061',\n InvalidEventReference: 'PLAY0062',\n InvalidJoinDeclaration: 'PLAY0063',\n JoinWithoutEvent: 'PLAY0064',\n InvalidChildrenDeclaration: 'PLAY0065',\n InvalidNestedDeclaration: 'PLAY0066',\n NestedBlockWithoutFrom: 'PLAY0067',\n InvalidRemoveDeclaration: 'PLAY0068',\n UnknownRemoveDirective: 'PLAY0069',\n InvalidClearDeclaration: 'PLAY0070',\n ClearWithOutsideNestedBlock: 'PLAY0071',\n InvalidSpecificationDeclaration: 'PLAY0094',\n UnknownSpecificationDirective: 'PLAY0095',\n InvalidSpecificationWhen: 'PLAY0096',\n DuplicateSpecificationWhen: 'PLAY0097',\n InvalidThenError: 'PLAY0098',\n InvalidReadModelStep: 'PLAY0099',\n InvalidEventStep: 'PLAY0100',\n InvalidSpecificationValue: 'PLAY0101',\n InvalidScreenDeclaration: 'PLAY0102',\n UnknownScreenDirective: 'PLAY0103',\n InvalidDataDirective: 'PLAY0104',\n InvalidActionDirective: 'PLAY0105',\n UnknownActionDirective: 'PLAY0106',\n InvalidNavigation: 'PLAY0107',\n InvalidScreenLayoutSlot: 'PLAY0108',\n InvalidTitleDirective: 'PLAY0109',\n UnknownTableDirective: 'PLAY0110',\n UnknownSummaryDirective: 'PLAY0111',\n AuthorizeWithoutPolicy: 'PLAY0122',\n InvalidPolicyReference: 'PLAY0123',\n InvalidConstraintDeclaration: 'PLAY0132',\n ConstraintWithoutRule: 'PLAY0133',\n InvalidConstraintBody: 'PLAY0134',\n DuplicateConstraintBody: 'PLAY0135',\n InvalidReactionDeclaration: 'PLAY0136',\n InvalidReactionTrigger: 'PLAY0137',\n ReactionWithoutTrigger: 'PLAY0138',\n InvalidValidateDeclaration: 'PLAY0140',\n InvalidValidationRule: 'PLAY0141',\n InvalidRuleName: 'PLAY0143',\n UnknownRuleImplementationDirective: 'PLAY0144',\n InvalidDescription: 'PLAY0145',\n EmptyDescription: 'PLAY0146',\n DuplicateDescription: 'PLAY0147',\n TagWithoutValue: 'PLAY0148',\n InvalidTagValue: 'PLAY0149',\n UnknownContextPath: 'PLAY0153',\n UnknownContextCausedByProperty: 'PLAY0154',\n UnknownContextIdentityProperty: 'PLAY0155',\n ExpectedCodeFence: 'PLAY0163',\n UnclosedCodeBlock: 'PLAY0164',\n DuplicateDeclaration: 'PLAY0168',\n RepeatedSingularDeclarationAcrossFiles: 'PLAY0172',\n RepeatedDeclarationAcrossFiles: 'PLAY0173',\n ConflictingDescriptionAcrossFiles: 'PLAY0174',\n UnexpectedTokenInAuthorize: 'PLAY0184',\n UnclosedAuthorizeGroup: 'PLAY0185',\n InvalidReadModelDeclaration: 'PLAY0186',\n InvalidInvokesDeclaration: 'PLAY0194',\n InvalidScopeDeclaration: 'PLAY0199',\n DuplicateScope: 'PLAY0200',\n InvalidIntervalTrigger: 'PLAY0249',\n InvalidScheduleTrigger: 'PLAY0250',\n DuplicateReactionTrigger: 'PLAY0253',\n InvalidSpecificationEventSource: 'PLAY0275',\n DuplicateSpecificationEventSource: 'PLAY0276',\n InvalidProjectionVariantDeclaration: 'PLAY0277',\n InvalidEntersOnDeclaration: 'PLAY0279',\n NestedProjectionVariantNotAllowed: 'PLAY0280',\n InvalidStructuredValue: 'PLAY0291',\n DuplicateStructuredValueMember: 'PLAY0294',\n ConflictingSpecificationActions: 'PLAY0358',\n InvalidSpecificationEventOrder: 'PLAY0359',\n InvalidValidationSeverity: 'PLAY0368',\n VariantRequiresEnteringEvent: 'PLAY0382',\n DuplicateProjectionVariant: 'PLAY0384',\n DuplicateVariantEnteringEvent: 'PLAY0385',\n InvalidSpecificationDenied: 'PLAY0388',\n DuplicateAuthorizationAcrossFiles: 'PLAY0394',\n FileConstraintOnlySupportsUniqueness: 'PLAY0396',\n LegacyInlineCodeFence: 'PLAY0397',\n InvalidEventGeneration: 'PLAY0446',\n InvalidFileImport: 'PLAY0454',\n FileImportMatchesNothing: 'PLAY0455',\n ImportedFileNotFound: 'PLAY0456',\n ConflictingImportPlacement: 'PLAY0457',\n ImportCycle: 'PLAY0458',\n ModuleInPlacedFile: 'PLAY0459',\n UnexpectedInPlacedFile: 'PLAY0460',\n InvalidSpecificationClock: 'PLAY0461',\n InvalidSpecificationTrigger: 'PLAY0462',\n InvalidSpecificationCapture: 'PLAY0463',\n InvalidSpecificationQueryAction: 'PLAY0464',\n UnknownSpecificationQueryArgument: 'PLAY0468',\n InvalidSpecificationQuery: 'PLAY0265',\n UnknownSpecificationQueryDirective: 'PLAY0266',\n DuplicateSpecificationQueryArguments: 'PLAY0267',\n InvalidAbsentReadModelStep: 'PLAY0453',\n LegacyOptionalSuffix: 'PLAY0479',\n InvalidOptionalModifierOrder: 'PLAY0480',\n OptionalReadsNotSupported: 'PLAY0481',\n InvalidSpecificationCaller: 'PLAY0386',\n DuplicateSpecificationCallerOrDenied: 'PLAY0387',\n GeneratedPropertyOutsideCommand: 'PLAY0482',\n InvalidGeneratedType: 'PLAY0483',\n InvalidGeneratedModifierOrder: 'PLAY0484',\n DuplicateEventSubject: 'PLAY0590',\n InvalidSubjectType: 'PLAY0591',\n ProtectedSubjectType: 'PLAY0592',\n InvalidSubjectOwner: 'PLAY0593',\n ReadModelSubjectNotSupported: 'PLAY0594',\n InvalidSubjectModifierOrder: 'PLAY0595',\n GeneratedPropertySuppliedAsInput: 'PLAY0485',\n InvalidCommandResponse: 'PLAY0486',\n InvalidResponseSource: 'PLAY0487',\n DuplicateResponseField: 'PLAY0488',\n InvalidResponseShape: 'PLAY0489',\n InvalidGeneratedFixture: 'PLAY0490',\n InvalidReturnExpectation: 'PLAY0491',\n InvalidImplementationBlock: 'PLAY0492',\n InvalidImplementationHint: 'PLAY0493',\n ConflictingImplementationSources: 'PLAY0494',\n UnknownType: 'PLAY0165',\n InvalidSystemDeclaration: 'PLAY0495',\n InvalidOperationDeclaration: 'PLAY0496',\n InvalidProductionReference: 'PLAY0497',\n ProductionDeclarationCollision: 'PLAY0498',\n OperationOutsideCommand: 'PLAY0499',\n InvalidSystemReference: 'PLAY0500',\n InvalidOperationMapping: 'PLAY0501',\n InvalidOperationSpecification: 'PLAY0502',\n InvalidCaptureDeclaration: 'PLAY0078',\n UnknownCaptureDirective: 'PLAY0079',\n InvalidMapEntry: 'PLAY0080',\n InvalidTranslation: 'PLAY0081',\n InvalidSplitDeclaration: 'PLAY0082',\n InvalidSplitTarget: 'PLAY0083',\n InvalidAppendDeclaration: 'PLAY0084',\n UnknownAppendDirective: 'PLAY0085',\n WhenWithoutTrigger: 'PLAY0086',\n InvalidWhenClause: 'PLAY0087',\n InvalidWhenTransitionClause: 'PLAY0088',\n MixedWhenCombinators: 'PLAY0089',\n WhenCombinatorWithoutProperty: 'PLAY0090',\n UnknownCaptureBlockDirective: 'PLAY0091',\n InvalidCompositeKeyPart: 'PLAY0072',\n TemplateInCompositeKey: 'PLAY0073',\n EmptyCompositeKey: 'PLAY0074',\n InvalidProjectionMapping: 'PLAY0075',\n ExpectedLiteralValue: 'PLAY0150',\n InvalidExpression: 'PLAY0152',\n UnterminatedInterpolation: 'PLAY0157',\n UnterminatedTemplateExpression: 'PLAY0156',\n ProjectionDocumentWithoutProjection: 'PLAY0055',\n CaptureDocumentWithoutCapture: 'PLAY0077',\n SpecificationDocumentWithoutSpecification: 'PLAY0093',\n InvalidSeedDeclaration: 'PLAY0128',\n InvalidSeedGroup: 'PLAY0129',\n InvalidSeedEvent: 'PLAY0130',\n InvalidSeedPropertyAssignment: 'PLAY0131',\n InvalidPolicyDeclaration: 'PLAY0112',\n UnknownPolicyDirective: 'PLAY0113',\n PolicyWithoutRequirement: 'PLAY0114',\n ExpectedRoleName: 'PLAY0118',\n ExpectedClaimName: 'PLAY0119',\n ExpectedClaimMatches: 'PLAY0120',\n ExpectedClaimMatchTarget: 'PLAY0121',\n MixedPolicyImplementation: 'PLAY0440',\n RepeatedPolicyRequirement: 'PLAY0441',\n UnexpectedTokenInPolicyCondition: 'PLAY0115',\n ExpectedPolicyCondition: 'PLAY0116',\n UnclosedPolicyConditionGroup: 'PLAY0117',\n UnexpectedTokenInCondition: 'PLAY0158',\n ExpectedCondition: 'PLAY0159',\n ExpectedComparisonOperator: 'PLAY0161',\n ExpectedComparisonValue: 'PLAY0162',\n InvalidActionAlternative: 'PLAY0341',\n GuardedActionWithoutAlternatives: 'PLAY0342',\n MisplacedActionOtherwise: 'PLAY0343',\n UnsupportedActionConditionOperand: 'PLAY0344',\n InvalidInteractionArgument: 'PLAY0319',\n UnclosedConditionGroup: 'PLAY0160',\n InvalidNumericDirective: 'PLAY0508',\n DuplicateNumericDirective: 'PLAY0509',\n LateNumericDirective: 'PLAY0510',\n InexactNumericLiteral: 'PLAY0511',\n MixedNumericModes: 'PLAY0512',\n IncompatibleNumericSource: 'PLAY0513',\n EventFromLaterSlice: 'PLAY0516',\n TimelineCycleGroup: 'PLAY0517',\n InvalidSpecificationExample: 'PLAY0518',\n DuplicateSpecificationAssignment: 'PLAY0519',\n UnresolvedSpecificationExampleType: 'PLAY0520',\n SpecificationExampleNameCollision: 'PLAY0521',\n SpecificationExampleKindMismatch: 'PLAY0522',\n InvalidSpecificationExampleValue: 'PLAY0523',\n MissingSpecificationProperty: 'PLAY0524',\n UnadmittedSpecificationExampleValue: 'PLAY0525',\n InvalidSpecificationExampleBody: 'PLAY0526',\n AmbiguousReference: 'PLAY0198',\n InvalidSpecificationStream: 'PLAY0547',\n SpecificationStreamOnCommand: 'PLAY0548',\n InvalidSpecificationStreamRoute: 'PLAY0549',\n InvalidSpecificationStreamEventSource: 'PLAY0550',\n SpecificationStreamContradictsCommand: 'PLAY0551',\n InvalidDependencyTarget: 'PLAY0554',\n RepeatedDependencyDeclaration: 'PLAY0555',\n UndeclaredDependency: 'PLAY0552',\n UnusedDependencyDeclaration: 'PLAY0553',\n MutualDependencyDeclarations: 'PLAY0556',\n AuthorizationRefusalWithoutIdentity: 'PLAY0557',\n InvalidDocumentation: 'PLAY0558',\n ConflictingDocumentationAcrossFiles: 'PLAY0559',\n InvalidSpecificationCallerPersona: 'PLAY0572',\n UnsynthesizablePersonaCaller: 'PLAY0573',\n PersonaWithoutGate: 'PLAY0574',\n GateWithoutPersona: 'PLAY0575',\n AmbiguousPersonaCaller: 'PLAY0576',\n InvalidSpecificationParameter: 'PLAY0577',\n InvalidSpecificationCase: 'PLAY0578',\n DuplicateSpecificationParameter: 'PLAY0579',\n DuplicateSpecificationCase: 'PLAY0580',\n IncompleteSpecificationTable: 'PLAY0581',\n InvalidSpecificationCaseAssignment: 'PLAY0582',\n InvalidSpecificationCaseValue: 'PLAY0583',\n InvalidSpecificationCaseReference: 'PLAY0584',\n OptionalSpecificationParameterTarget: 'PLAY0585',\n SpecificationCaseNameCollision: 'PLAY0586',\n IncompatibleSpecificationParameterType: 'PLAY0587',\n UnusedSpecificationParameter: 'PLAY0588',\n SingularSpecificationTableExpansion: 'PLAY0589',\n UnsupportedInteractionAlternatives: 'PLAY0560',\n MixedInteractionAlternatives: 'PLAY0561',\n InteractionAlternativeWithoutActions: 'PLAY0562',\n InlineInteractionAlternative: 'PLAY0563',\n LegacyInteractionWhere: 'PLAY0564',\n InvalidEventSourceDeclaration: 'PLAY0503',\n InvalidCommandStream: 'PLAY0504',\n AmbiguousCommandStream: 'PLAY0505',\n UnsupportedStreamIdType: 'PLAY0506',\n RedundantSourceStreamId: 'PLAY0507',\n UnknownEvent: 'PLAY0166',\n UnknownReadModelProperty: 'PLAY0514',\n PiiNotSupportedOnIdentifier: 'PLAY0515',\n HandlerWithoutImplementation: 'PLAY0045',\n UnknownHandlerDirective: 'PLAY0046',\n CommandWithProducesAndHandler: 'PLAY0035',\n AbsoluteFileReference: 'PLAY0264',\n InvalidTriggerData: 'PLAY0246',\n InvalidReadModelKey: 'PLAY0660',\n IncompleteReadModelKey: 'PLAY0661', // C# only: scoped read-model key resolution.\n InvalidReadModelKeyLookup: 'PLAY0662', // Shape checks shared; scoped lookup checks are C# only.\n ProductionRouteOutsideCommand: 'PLAY0663',\n RedundantProductionRoute: 'PLAY0664',\n InvalidObserverFilter: 'PLAY0665',\n ObserverFilterExcludesEveryProducer: 'PLAY0666', // C# only: statically known producer routes.\n MixedEnumerationNumbering: 'PLAY0667',\n DuplicateEnumerationNumber: 'PLAY0668',\n EnumerationNumberOutsideInt32: 'PLAY0669',\n MalformedEnumerationNumber: 'PLAY0670',\n UnpinnedStoredEnumeration: 'PLAY0671',\n ReadsWithChildren: 'PLAY0451',\n UnknownGenerationStrategy: 'PLAY0672',\n InvalidGenerationArgument: 'PLAY0673',\n InvalidGenerationModifier: 'PLAY0674',\n DuplicateGenerationModifier: 'PLAY0675',\n DuplicateGeneration: 'PLAY0676',\n InvalidGenerationPrimitive: 'PLAY0677',\n InvalidGenerationPrefix: 'PLAY0678',\n InvalidGenerationAlphabet: 'PLAY0679',\n InvalidTypeIdPrefix: 'PLAY0680',\n GenerationSizeOutsideRange: 'PLAY0681',\n ReservedSequenceGeneration: 'PLAY0682',\n LowGenerationEntropy: 'PLAY0683',\n LowGeneratedIdentifierEntropy: 'PLAY0684',\n ResponseNameUsedOnFailure: 'PLAY0685',\n} as const;\n"],"mappings":"AAKA,MAAaA,EAAkB,CAC3B,2BAA4B,WAC5B,kBAAmB,WACnB,sBAAuB,WACvB,sBAAuB,WACvB,4BAA6B,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AC/B,0BAA2B,UAC/B"}
@@ -1,2 +1,2 @@
1
- import"../../_virtual/_virtual/_rolldown/runtime.js";import{splitLines as e}from"../Parsing/SourceLineSplitter.js";import{expandSpecificationExamples as t,validateSpecificationExampleTypes as n}from"../Parsing/SpecificationCommandExamples.js";import{validateResponses as r}from"../Parsing/ResponseValidator.js";import{validateSpecificationCases as i}from"../Parsing/SpecificationCaseValidator.js";import{productionDestinationDiagnostics as a}from"../Diagnostics/ProductionDestinationDiagnostics.js";import{validateConstraintProperties as o}from"../Parsing/ConstraintPropertyValidator.js";import{validateDependencyDeclarations as s}from"../Dependencies/DeclaredDependencyTargets.js";import{LineReader as c}from"../Parsing/LineReader.js";import{ParserContext as l}from"../Parsing/ParserContext.js";import"./AuthoredOrder.js";import{DeclaredDependencies as u}from"../Dependencies/DeclaredDependencies.js";import{validatePublicEventUsage as d}from"../Parsing/PublicEventUsageValidator.js";import{validateInlineEvents as f}from"../Parsing/InlineEventValidator.js";import{validateOperations as p}from"../Parsing/OperationValidator.js";import{CommandStreamCandidates as m}from"../Parsing/CommandStreamCandidates.js";import{validateEventSources as h}from"../Parsing/EventSourceValidator.js";import{validateProjectionTargets as g}from"../Parsing/ProjectionTargetValidator.js";import{validateIdentifierCompliance as _}from"../Parsing/IdentifierComplianceValidator.js";import{validateEventSubjects as v}from"../Parsing/EventSubjectValidator.js";import{validateReadModelKeys as y}from"../Parsing/ReadModelKeyValidator.js";import{validateReactionRefusals as b}from"../Parsing/ReactionRefusalValidator.js";import{validateSpecificationRedelivery as x}from"../Parsing/SpecificationRedeliveryValidator.js";import{validateGuardedActions as S}from"../Parsing/GuardedActionValidator.js";import{validatePersonaCallers as C}from"../Parsing/PersonaCallerValidator.js";import{validatePurposes as w}from"../Parsing/PurposeValidator.js";import"./TimelineOrder.js";import{parseForAuthoring as T}from"../ScreenplayCompiler.js";import{EventSourceReadConfidence as E}from"../Syntax/EventSourceReadConfidence.js";import"./OrderingRoot.js";import{mergeDocuments as D}from"./PlayFolderMerge.js";import"./PlayImports.js";function parsePlacedDocuments(e,t,n=!1){return parsePlacedDocumentsWithSyntax(e,t,n).result}function parsePlacedDocumentsWithSyntax(O,k,A=!1){let j=m.capturePlaced(O.filter(e=>e.isPlacementResolved!==!1).map(t=>({lines:e(t.source,!1,t.path),placement:t.placement})),k),M=O.map(e=>T(e.source,e.path,e.isPlacementResolved===!1?[]:e.placement,!1,j,k)),N=M.flatMap((e,t)=>(e.value.eventSources??[]).map(e=>({source:e,placementResolved:O[t].isPlacementResolved!==!1}))),P=O.every(e=>e.isPlacementResolved!==!1)&&M.every(e=>!E.hasUnknownExtent(e.diagnostics)),F=M.map((e,t)=>O[t].isPlacementResolved===!1?{...e,value:{...e.value,eventSources:[]}}:e),I=D(F),L=new l(new c([]),void 0,k);I.value.sourceOptions!==void 0&&(L.sourceOptions=I.value.sourceOptions),L.guardedInteractions.push(...F.flatMap(e=>e.guardedInteractions)),i(I.value,L),n(I.value,L,A);let R=t(I.value);h(I.value,L),p(I.value,L),d(I.value,L),f(I.value,L),o(I.value,L),r(R,L,F.flatMap(e=>e.inputUses)),g(I.value,L),_(R,L),v(I.value,L),y(I.value,L),b(I.value,L),x(I.value,L),S(I.value,L),C(I.value,L),w(I.value,L);let z=s(I.value,L);u.validate(z,L);for(let e of a(z))L.information(e.code,e.message,e.location);let B=I.diagnostics,V=new Set(B.map(diagnosticKey)),H=[...B,...L.diagnostics.filter(e=>!V.has(diagnosticKey(e)))];return{result:{...I,value:z,diagnostics:H,success:!H.some(e=>e.severity===`error`),physicalEventSources:N,sourceInventoryComplete:P},syntax:new Map(F.map((e,t)=>[O[t].path,e.value]))}}function diagnosticKey(e){return JSON.stringify([e.code,e.location.path,e.location.line,e.location.column])}export{parsePlacedDocuments};
1
+ import"../../_virtual/_virtual/_rolldown/runtime.js";import{splitLines as e}from"../Parsing/SourceLineSplitter.js";import{expandSpecificationExamples as t,validateSpecificationExampleTypes as n}from"../Parsing/SpecificationCommandExamples.js";import{validateResponses as r}from"../Parsing/ResponseValidator.js";import{validateSpecificationCases as i}from"../Parsing/SpecificationCaseValidator.js";import{productionDestinationDiagnostics as a}from"../Diagnostics/ProductionDestinationDiagnostics.js";import{validateConstraintProperties as o}from"../Parsing/ConstraintPropertyValidator.js";import{validateDependencyDeclarations as s}from"../Dependencies/DeclaredDependencyTargets.js";import{LineReader as c}from"../Parsing/LineReader.js";import{ParserContext as l}from"../Parsing/ParserContext.js";import"./AuthoredOrder.js";import{DeclaredDependencies as u}from"../Dependencies/DeclaredDependencies.js";import{validatePublicEventUsage as d}from"../Parsing/PublicEventUsageValidator.js";import{validateInlineEvents as f}from"../Parsing/InlineEventValidator.js";import{validateOperations as p}from"../Parsing/OperationValidator.js";import{CommandStreamCandidates as m}from"../Parsing/CommandStreamCandidates.js";import{validateEventSources as h}from"../Parsing/EventSourceValidator.js";import{validateProjectionTargets as g}from"../Parsing/ProjectionTargetValidator.js";import{validateIdentifierCompliance as _}from"../Parsing/IdentifierComplianceValidator.js";import{validateEventSubjects as v}from"../Parsing/EventSubjectValidator.js";import{validateReadModelKeys as y}from"../Parsing/ReadModelKeyValidator.js";import{validateReactionRefusals as b}from"../Parsing/ReactionRefusalValidator.js";import{validateSpecificationRedelivery as x}from"../Parsing/SpecificationRedeliveryValidator.js";import{validateGuardedActions as S}from"../Parsing/GuardedActionValidator.js";import{validatePersonaCallers as C}from"../Parsing/PersonaCallerValidator.js";import{validatePurposes as w}from"../Parsing/PurposeValidator.js";import"./TimelineOrder.js";import{parseForAuthoring as T}from"../ScreenplayCompiler.js";import{EventSourceReadConfidence as E}from"../Syntax/EventSourceReadConfidence.js";import"./OrderingRoot.js";import{mergeDocuments as D}from"./PlayFolderMerge.js";import"./PlayImports.js";function parsePlacedDocuments(e,t,n=!1){return parsePlacedDocumentsWithSyntax(e,t,n).result}function parsePlacedDocumentsWithSyntax(O,k,A=!1){let j=m.capturePlaced(O.filter(e=>e.isPlacementResolved!==!1).map(t=>({lines:e(t.source,!1,t.path),placement:t.placement})),k),M=O.map(e=>T(e.source,e.path,e.isPlacementResolved===!1?[]:e.placement,!1,j,k)),N=M.flatMap((e,t)=>(e.value.eventSources??[]).map(e=>({source:e,placementResolved:O[t].isPlacementResolved!==!1}))),P=O.every(e=>e.isPlacementResolved!==!1)&&M.every(e=>!E.hasUnknownExtent(e.diagnostics)),F=M.map((e,t)=>O[t].isPlacementResolved===!1?{...e,value:{...e.value,eventSources:[]}}:e),I=D(F),L=new l(new c([]),void 0,k);I.value.sourceOptions!==void 0&&(L.sourceOptions=I.value.sourceOptions),L.guardedInteractions.push(...F.flatMap(e=>e.guardedInteractions)),L.continuationValues.push(...F.flatMap(e=>e.continuationValues)),i(I.value,L),n(I.value,L,A);let R=t(I.value);h(I.value,L),p(I.value,L),d(I.value,L),f(I.value,L),o(I.value,L),r(R,L,F.flatMap(e=>e.inputUses)),g(I.value,L),_(R,L),v(I.value,L),y(I.value,L),b(I.value,L),x(I.value,L),S(I.value,L),C(I.value,L),w(I.value,L);let z=s(I.value,L);u.validate(z,L);for(let e of a(z))L.information(e.code,e.message,e.location);let B=I.diagnostics,V=new Set(B.map(diagnosticKey)),H=[...B,...L.diagnostics.filter(e=>!V.has(diagnosticKey(e)))];return{result:{...I,value:z,diagnostics:H,success:!H.some(e=>e.severity===`error`),physicalEventSources:N,sourceInventoryComplete:P,continuationValues:L.continuationValues},syntax:new Map(F.map((e,t)=>[O[t].path,e.value]))}}function diagnosticKey(e){return JSON.stringify([e.code,e.location.path,e.location.line,e.location.column])}export{parsePlacedDocuments};
2
2
  //# sourceMappingURL=PlayApplicationAssembly.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"PlayApplicationAssembly.js","names":["documents","languages","deferImportedExampleTypes","candidates","CommandStreamCandidates","document","splitLines","physical","parseForAuthoring","physicalEventSources","result","index","sourceInventoryComplete","EventSourceReadConfidence","parsed","merged","mergeDocuments","context","ParserContext","LineReader","validateSpecificationCases","validateSpecificationExampleTypes","effective","expandSpecificationExamples","validateEventSources","validateOperations","validatePublicEventUsage","validateInlineEvents","validateConstraintProperties","validateResponses","validateProjectionTargets","validateIdentifierCompliance","validateEventSubjects","validateReadModelKeys","validateReactionRefusals","validateSpecificationRedelivery","validateGuardedActions","validatePersonaCallers","validatePurposes","value","validateDependencyDeclarations","DeclaredDependencies","diagnostic","productionDestinationDiagnostics","existing","reported","all"],"sources":["../../../../../../Compiler/Files/PlayApplicationAssembly.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { Diagnostic } from '../Diagnostics/Diagnostic';\nimport { validateSpecificationCases } from '../Parsing/SpecificationCaseValidator';\nimport { expandSpecificationExamples, validateSpecificationExampleTypes } from '../Parsing/SpecificationCommandExamples';\nimport { productionDestinationDiagnostics } from '../Diagnostics/ProductionDestinationDiagnostics';\nimport { validateConstraintProperties } from '../Parsing/ConstraintPropertyValidator';\nimport { validateDependencyDeclarations } from '../Dependencies/DeclaredDependencyTargets';\nimport { DeclaredDependencies } from '../Dependencies/DeclaredDependencies';\nimport { validateInlineEvents } from '../Parsing/InlineEventValidator';\nimport { LineReader } from '../Parsing/LineReader';\nimport { CommandStreamCandidates } from '../Parsing/CommandStreamCandidates';\nimport { validateEventSources } from '../Parsing/EventSourceValidator';\nimport { validateProjectionTargets } from '../Parsing/ProjectionTargetValidator';\nimport { validateIdentifierCompliance } from '../Parsing/IdentifierComplianceValidator';\nimport { validateEventSubjects } from '../Parsing/EventSubjectValidator';\nimport { validateReadModelKeys } from '../Parsing/ReadModelKeyValidator';\nimport { validateReactionRefusals } from '../Parsing/ReactionRefusalValidator';\nimport { validateSpecificationRedelivery } from '../Parsing/SpecificationRedeliveryValidator';\nimport { validateGuardedActions } from '../Parsing/GuardedActionValidator';\nimport { validatePersonaCallers } from '../Parsing/PersonaCallerValidator';\nimport { validatePurposes } from '../Parsing/PurposeValidator';\nimport { splitLines } from '../Parsing/SourceLineSplitter';\nimport { ParserContext } from '../Parsing/ParserContext';\nimport { validateResponses } from '../Parsing/ResponseValidator';\nimport { validatePublicEventUsage } from '../Parsing/PublicEventUsageValidator';\nimport { validateOperations } from '../Parsing/OperationValidator';\nimport { CompilationResult, discoverImports, parseForAuthoring } from '../ScreenplayCompiler';\nimport { ApplicationSyntax } from '../Syntax/Structure';\nimport { EventSourceSyntax } from '../Syntax/EventSources';\nimport { EventSourceReadConfidence } from '../Syntax/EventSourceReadConfidence';\nimport { mergeDocuments } from './PlayFolderMerge';\nimport { inMemoryDocumentSource, PlacedPlayDocument, PlayDocumentSource } from './PlayDocumentSource';\nimport { normalizePlayPath } from './PlayGlob';\nimport { resolveImports } from './PlayImports';\nimport { recordAuthoredOrder } from './AuthoredOrder';\nimport { selectOrderingRoot } from './OrderingRoot';\nimport { timelineOrderDiagnostics } from './TimelineOrder';\n\n// One .play document of a folder: its path relative to the folder, and its text.\nexport interface PlayFileSource {\n readonly path: string;\n readonly source: string;\n}\n\n// One application compiled from documents: the documents that make it up, each with where its top level\n// belongs, and the merged syntax with every diagnostic - resolving, parsing and merging.\nexport interface ApplicationCompilation extends CompilationResult<ApplicationSyntax> {\n readonly documents: readonly PlacedPlayDocument[];\n}\n\n// Assembles one application from documents - following their imports from the roots, parsing each where it is\n// placed, and merging the lot. The port of the C# PlayApplicationAssembly.Compile.\nexport function assembleApplication(roots: Iterable<string>, source: PlayDocumentSource, languages?: ReadonlySet<string>, presentationRoot?: string | null): ApplicationCompilation {\n const rootPaths = [...roots];\n const { documents, diagnostics } = resolveImports(rootPaths, source, languages);\n const { result: merged, syntax } = parsePlacedDocumentsWithSyntax(documents, languages);\n // Resolution owns its import inventory; share one discovery between the presentation passes.\n const imports = new Map(documents.map(document => [document.path, discoverImports(document.source, document.path, languages)]));\n const orderingRoot = presentationRoot === null ? undefined : selectOrderingRoot(presentationRoot === undefined ? rootPaths : [presentationRoot], documents, languages, imports);\n if (orderingRoot !== undefined) recordAuthoredOrder(merged.value, [orderingRoot], documents, languages, syntax, imports);\n const timeline = orderingRoot === undefined ? [] : timelineOrderDiagnostics(merged.value);\n const all = [...diagnostics, ...merged.diagnostics, ...timeline];\n return { ...merged, documents, diagnostics: all, success: !all.some(diagnostic => diagnostic.severity === 'error') };\n}\n\n// Parses documents whose source identities and placements are already known (for example unsaved\n// editor buffers), then validates contracts against the merged declaration inventory. Editor callers may\n// defer example types whose imports are not in that inventory; resolved types are still checked.\nexport function parsePlacedDocuments(documents: readonly PlacedPlayDocument[], languages?: ReadonlySet<string>, deferImportedExampleTypes = false): CompilationResult<ApplicationSyntax> & {\n readonly physicalEventSources: readonly { source: EventSourceSyntax; placementResolved: boolean }[];\n readonly sourceInventoryComplete: boolean;\n} {\n return parsePlacedDocumentsWithSyntax(documents, languages, deferImportedExampleTypes).result;\n}\n\nfunction parsePlacedDocumentsWithSyntax(documents: readonly PlacedPlayDocument[], languages?: ReadonlySet<string>, deferImportedExampleTypes = false) {\n const candidates = CommandStreamCandidates.capturePlaced(documents.filter(document => document.isPlacementResolved !== false).map(document => ({ lines: splitLines(document.source, false, document.path), placement: document.placement })), languages);\n const physical = documents.map(document => parseForAuthoring(document.source, document.path, document.isPlacementResolved === false ? [] : document.placement, false, candidates, languages));\n const physicalEventSources = physical.flatMap((result, index) => (result.value.eventSources ?? []).map(source => ({ source, placementResolved: documents[index].isPlacementResolved !== false })));\n const sourceInventoryComplete = documents.every(document => document.isPlacementResolved !== false) && physical.every(result => !EventSourceReadConfidence.hasUnknownExtent(result.diagnostics));\n const parsed = physical.map((result, index) => documents[index].isPlacementResolved === false ? { ...result, value: { ...result.value, eventSources: [] } } : result);\n const merged = mergeDocuments(parsed);\n const context = new ParserContext(new LineReader([]), undefined, languages);\n if (merged.value.sourceOptions !== undefined) context.sourceOptions = merged.value.sourceOptions;\n context.guardedInteractions.push(...parsed.flatMap(document => document.guardedInteractions));\n validateSpecificationCases(merged.value, context);\n validateSpecificationExampleTypes(merged.value, context, deferImportedExampleTypes);\n const effective = expandSpecificationExamples(merged.value);\n validateEventSources(merged.value, context);\n validateOperations(merged.value, context);\n validatePublicEventUsage(merged.value, context);\n validateInlineEvents(merged.value, context);\n validateConstraintProperties(merged.value, context);\n validateResponses(effective, context, parsed.flatMap(document => document.inputUses));\n validateProjectionTargets(merged.value, context);\n validateIdentifierCompliance(effective, context);\n validateEventSubjects(merged.value, context);\n validateReadModelKeys(merged.value, context);\n validateReactionRefusals(merged.value, context);\n validateSpecificationRedelivery(merged.value, context);\n validateGuardedActions(merged.value, context);\n validatePersonaCallers(merged.value, context);\n validatePurposes(merged.value, context);\n const value = validateDependencyDeclarations(merged.value, context);\n DeclaredDependencies.validate(value, context);\n for (const diagnostic of productionDestinationDiagnostics(value)) context.information(diagnostic.code, diagnostic.message, diagnostic.location);\n const existing = merged.diagnostics;\n const reported = new Set(existing.map(diagnosticKey));\n const all = [...existing, ...context.diagnostics.filter(diagnostic => !reported.has(diagnosticKey(diagnostic)))];\n return {\n result: { ...merged, value, diagnostics: all, success: !all.some(diagnostic => diagnostic.severity === 'error'), physicalEventSources, sourceInventoryComplete },\n syntax: new Map(parsed.map((result, index) => [documents[index].path, result.value])),\n };\n}\n\nfunction diagnosticKey(diagnostic: Diagnostic): string {\n return JSON.stringify([diagnostic.code, diagnostic.location.path, diagnostic.location.line, diagnostic.location.column]);\n}\n\n// Compiles documents held in memory, keyed by portable path, as one application. Without roots every\n// document is a root, in ordinal order of its path - a folder compiled as one application, where a file an\n// import places in a module or feature is placed there. With roots, only those documents and what they import\n// make up the application - a single file compiled with its imports followed. The default sort compares\n// UTF-16 code units, which is the C# ordinal order.\nexport function compileApplication(documents: ReadonlyMap<string, string>, roots?: readonly string[], languages?: ReadonlySet<string>, presentationRoot?: string | null): ApplicationCompilation {\n const normalized = new Map([...documents].map(([path, source]) => [normalizePlayPath(path), source]));\n return assembleApplication(roots ?? [...normalized.keys()].sort(), inMemoryDocumentSource(normalized), languages, presentationRoot);\n}\n\n// Compiles the documents of a folder as one application - the counterpart of the C# CompileFolder. Every\n// document is a root, read in ordinal order of its relative path as the C# compiler reads them, so a merge\n// keeps the same first declaration in either language; one an import places in a module or feature is\n// placed there.\nexport function parseFolder(files: readonly PlayFileSource[], languages?: ReadonlySet<string>): ApplicationCompilation {\n return compileApplication(new Map(files.map(file => [file.path, file.source])), undefined, languages);\n}\n\n"],"mappings":"+uEAsEA,SAAgB,qBAAqB,EAA0C,EAAiC,EAA4B,GAG1I,CACE,OAAO,+BAA+BA,EAAWC,EAAWC,CAAyB,CAAC,CAAC,MAC3F,CAEA,SAAS,+BAA+B,EAA0C,EAAiC,EAA4B,GAAO,CAClJ,IAAMC,EAAaC,EAAwB,cAAcJ,EAAU,OAAO,GAAYK,EAAS,sBAAwB,EAAK,CAAC,CAAC,IAAI,IAAa,CAAE,MAAOC,EAAWD,EAAS,OAAQ,GAAOA,EAAS,IAAI,EAAG,UAAWA,EAAS,SAAU,EAAE,EAAGJ,CAAS,EACjPM,EAAWP,EAAU,IAAI,GAAYQ,EAAkBH,EAAS,OAAQA,EAAS,KAAMA,EAAS,sBAAwB,GAAQ,CAAC,EAAIA,EAAS,UAAW,GAAOF,EAAYF,CAAS,CAAC,EACtLQ,EAAuBF,EAAS,SAAS,EAAQ,KAAWG,EAAO,MAAM,cAAgB,CAAC,EAAA,CAAG,IAAI,IAAW,CAAE,SAAQ,kBAAmBV,EAAUW,EAAM,CAAC,sBAAwB,EAAM,EAAE,CAAC,EAC3LC,EAA0BZ,EAAU,MAAM,GAAYK,EAAS,sBAAwB,EAAK,GAAKE,EAAS,MAAM,GAAU,CAACM,EAA0B,iBAAiBH,EAAO,WAAW,CAAC,EACzLI,EAASP,EAAS,KAAK,EAAQ,IAAUP,EAAUW,EAAM,CAAC,sBAAwB,GAAQ,CAAE,GAAGD,EAAQ,MAAO,CAAE,GAAGA,EAAO,MAAO,aAAc,CAAC,CAAE,CAAE,EAAIA,CAAM,EAC9JK,EAASC,EAAeF,CAAM,EAC9BG,EAAU,IAAIC,EAAc,IAAIC,EAAW,CAAC,CAAC,EAAG,IAA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AcH,CAAU,CAAC,CAAC,CAAC,EAC/G,MAAO,CACH,OAAQ,CAAE,GAAG3B,EAAQ,QAAO,YAAa+B,EAAK,QAAS,CAACA,EAAI,KAAK,GAAcJ,EAAW,WAAa,OAAO,EAAG,uBAAsB,yBAAwB,EAC/J,OAAQ,IAAI,IAAI5B,EAAO,KAAK,EAAQ,IAAU,CAACd,EAAUW,EAAM,CAAC,KAAMD,EAAO,KAAK,CAAC,CAAC,CACxF,CACJ,CAEA,SAAS,cAAc,EAAgC,CACnD,OAAO,KAAK,UAAU,CAACgC,EAAW,KAAMA,EAAW,SAAS,KAAMA,EAAW,SAAS,KAAMA,EAAW,SAAS,MAAM,CAAC,CAC3H"}
1
+ {"version":3,"file":"PlayApplicationAssembly.js","names":["documents","languages","deferImportedExampleTypes","candidates","CommandStreamCandidates","document","splitLines","physical","parseForAuthoring","physicalEventSources","result","index","sourceInventoryComplete","EventSourceReadConfidence","parsed","merged","mergeDocuments","context","ParserContext","LineReader","validateSpecificationCases","validateSpecificationExampleTypes","effective","expandSpecificationExamples","validateEventSources","validateOperations","validatePublicEventUsage","validateInlineEvents","validateConstraintProperties","validateResponses","validateProjectionTargets","validateIdentifierCompliance","validateEventSubjects","validateReadModelKeys","validateReactionRefusals","validateSpecificationRedelivery","validateGuardedActions","validatePersonaCallers","validatePurposes","value","validateDependencyDeclarations","DeclaredDependencies","diagnostic","productionDestinationDiagnostics","existing","reported","all"],"sources":["../../../../../../Compiler/Files/PlayApplicationAssembly.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { Diagnostic } from '../Diagnostics/Diagnostic';\nimport { validateSpecificationCases } from '../Parsing/SpecificationCaseValidator';\nimport { expandSpecificationExamples, validateSpecificationExampleTypes } from '../Parsing/SpecificationCommandExamples';\nimport { productionDestinationDiagnostics } from '../Diagnostics/ProductionDestinationDiagnostics';\nimport { validateConstraintProperties } from '../Parsing/ConstraintPropertyValidator';\nimport { validateDependencyDeclarations } from '../Dependencies/DeclaredDependencyTargets';\nimport { DeclaredDependencies } from '../Dependencies/DeclaredDependencies';\nimport { validateInlineEvents } from '../Parsing/InlineEventValidator';\nimport { LineReader } from '../Parsing/LineReader';\nimport { CommandStreamCandidates } from '../Parsing/CommandStreamCandidates';\nimport { validateEventSources } from '../Parsing/EventSourceValidator';\nimport { validateProjectionTargets } from '../Parsing/ProjectionTargetValidator';\nimport { validateIdentifierCompliance } from '../Parsing/IdentifierComplianceValidator';\nimport { validateEventSubjects } from '../Parsing/EventSubjectValidator';\nimport { validateReadModelKeys } from '../Parsing/ReadModelKeyValidator';\nimport { validateReactionRefusals } from '../Parsing/ReactionRefusalValidator';\nimport { validateSpecificationRedelivery } from '../Parsing/SpecificationRedeliveryValidator';\nimport { validateGuardedActions } from '../Parsing/GuardedActionValidator';\nimport { validatePersonaCallers } from '../Parsing/PersonaCallerValidator';\nimport { validatePurposes } from '../Parsing/PurposeValidator';\nimport { splitLines } from '../Parsing/SourceLineSplitter';\nimport { ParserContext } from '../Parsing/ParserContext';\nimport { validateResponses } from '../Parsing/ResponseValidator';\nimport { validatePublicEventUsage } from '../Parsing/PublicEventUsageValidator';\nimport { validateOperations } from '../Parsing/OperationValidator';\nimport { CompilationResult, discoverImports, parseForAuthoring } from '../ScreenplayCompiler';\nimport { ApplicationSyntax } from '../Syntax/Structure';\nimport { EventSourceSyntax } from '../Syntax/EventSources';\nimport { EventSourceReadConfidence } from '../Syntax/EventSourceReadConfidence';\nimport { mergeDocuments } from './PlayFolderMerge';\nimport { inMemoryDocumentSource, PlacedPlayDocument, PlayDocumentSource } from './PlayDocumentSource';\nimport { normalizePlayPath } from './PlayGlob';\nimport { resolveImports } from './PlayImports';\nimport { recordAuthoredOrder } from './AuthoredOrder';\nimport { selectOrderingRoot } from './OrderingRoot';\nimport { timelineOrderDiagnostics } from './TimelineOrder';\n\n// One .play document of a folder: its path relative to the folder, and its text.\nexport interface PlayFileSource {\n readonly path: string;\n readonly source: string;\n}\n\n// One application compiled from documents: the documents that make it up, each with where its top level\n// belongs, and the merged syntax with every diagnostic - resolving, parsing and merging.\nexport interface ApplicationCompilation extends CompilationResult<ApplicationSyntax> {\n readonly documents: readonly PlacedPlayDocument[];\n}\n\n// Assembles one application from documents - following their imports from the roots, parsing each where it is\n// placed, and merging the lot. The port of the C# PlayApplicationAssembly.Compile.\nexport function assembleApplication(roots: Iterable<string>, source: PlayDocumentSource, languages?: ReadonlySet<string>, presentationRoot?: string | null): ApplicationCompilation {\n const rootPaths = [...roots];\n const { documents, diagnostics } = resolveImports(rootPaths, source, languages);\n const { result: merged, syntax } = parsePlacedDocumentsWithSyntax(documents, languages);\n // Resolution owns its import inventory; share one discovery between the presentation passes.\n const imports = new Map(documents.map(document => [document.path, discoverImports(document.source, document.path, languages)]));\n const orderingRoot = presentationRoot === null ? undefined : selectOrderingRoot(presentationRoot === undefined ? rootPaths : [presentationRoot], documents, languages, imports);\n if (orderingRoot !== undefined) recordAuthoredOrder(merged.value, [orderingRoot], documents, languages, syntax, imports);\n const timeline = orderingRoot === undefined ? [] : timelineOrderDiagnostics(merged.value);\n const all = [...diagnostics, ...merged.diagnostics, ...timeline];\n return { ...merged, documents, diagnostics: all, success: !all.some(diagnostic => diagnostic.severity === 'error') };\n}\n\n// Parses documents whose source identities and placements are already known (for example unsaved\n// editor buffers), then validates contracts against the merged declaration inventory. Editor callers may\n// defer example types whose imports are not in that inventory; resolved types are still checked.\nexport function parsePlacedDocuments(documents: readonly PlacedPlayDocument[], languages?: ReadonlySet<string>, deferImportedExampleTypes = false): CompilationResult<ApplicationSyntax> & {\n readonly physicalEventSources: readonly { source: EventSourceSyntax; placementResolved: boolean }[];\n readonly sourceInventoryComplete: boolean;\n readonly continuationValues: ReturnType<typeof parseForAuthoring>['continuationValues'];\n} {\n return parsePlacedDocumentsWithSyntax(documents, languages, deferImportedExampleTypes).result;\n}\n\nfunction parsePlacedDocumentsWithSyntax(documents: readonly PlacedPlayDocument[], languages?: ReadonlySet<string>, deferImportedExampleTypes = false) {\n const candidates = CommandStreamCandidates.capturePlaced(documents.filter(document => document.isPlacementResolved !== false).map(document => ({ lines: splitLines(document.source, false, document.path), placement: document.placement })), languages);\n const physical = documents.map(document => parseForAuthoring(document.source, document.path, document.isPlacementResolved === false ? [] : document.placement, false, candidates, languages));\n const physicalEventSources = physical.flatMap((result, index) => (result.value.eventSources ?? []).map(source => ({ source, placementResolved: documents[index].isPlacementResolved !== false })));\n const sourceInventoryComplete = documents.every(document => document.isPlacementResolved !== false) && physical.every(result => !EventSourceReadConfidence.hasUnknownExtent(result.diagnostics));\n const parsed = physical.map((result, index) => documents[index].isPlacementResolved === false ? { ...result, value: { ...result.value, eventSources: [] } } : result);\n const merged = mergeDocuments(parsed);\n const context = new ParserContext(new LineReader([]), undefined, languages);\n if (merged.value.sourceOptions !== undefined) context.sourceOptions = merged.value.sourceOptions;\n context.guardedInteractions.push(...parsed.flatMap(document => document.guardedInteractions));\n context.continuationValues.push(...parsed.flatMap(document => document.continuationValues));\n validateSpecificationCases(merged.value, context);\n validateSpecificationExampleTypes(merged.value, context, deferImportedExampleTypes);\n const effective = expandSpecificationExamples(merged.value);\n validateEventSources(merged.value, context);\n validateOperations(merged.value, context);\n validatePublicEventUsage(merged.value, context);\n validateInlineEvents(merged.value, context);\n validateConstraintProperties(merged.value, context);\n validateResponses(effective, context, parsed.flatMap(document => document.inputUses));\n validateProjectionTargets(merged.value, context);\n validateIdentifierCompliance(effective, context);\n validateEventSubjects(merged.value, context);\n validateReadModelKeys(merged.value, context);\n validateReactionRefusals(merged.value, context);\n validateSpecificationRedelivery(merged.value, context);\n validateGuardedActions(merged.value, context);\n validatePersonaCallers(merged.value, context);\n validatePurposes(merged.value, context);\n const value = validateDependencyDeclarations(merged.value, context);\n DeclaredDependencies.validate(value, context);\n for (const diagnostic of productionDestinationDiagnostics(value)) context.information(diagnostic.code, diagnostic.message, diagnostic.location);\n const existing = merged.diagnostics;\n const reported = new Set(existing.map(diagnosticKey));\n const all = [...existing, ...context.diagnostics.filter(diagnostic => !reported.has(diagnosticKey(diagnostic)))];\n return {\n result: { ...merged, value, diagnostics: all, success: !all.some(diagnostic => diagnostic.severity === 'error'), physicalEventSources, sourceInventoryComplete, continuationValues: context.continuationValues },\n syntax: new Map(parsed.map((result, index) => [documents[index].path, result.value])),\n };\n}\n\nfunction diagnosticKey(diagnostic: Diagnostic): string {\n return JSON.stringify([diagnostic.code, diagnostic.location.path, diagnostic.location.line, diagnostic.location.column]);\n}\n\n// Compiles documents held in memory, keyed by portable path, as one application. Without roots every\n// document is a root, in ordinal order of its path - a folder compiled as one application, where a file an\n// import places in a module or feature is placed there. With roots, only those documents and what they import\n// make up the application - a single file compiled with its imports followed. The default sort compares\n// UTF-16 code units, which is the C# ordinal order.\nexport function compileApplication(documents: ReadonlyMap<string, string>, roots?: readonly string[], languages?: ReadonlySet<string>, presentationRoot?: string | null): ApplicationCompilation {\n const normalized = new Map([...documents].map(([path, source]) => [normalizePlayPath(path), source]));\n return assembleApplication(roots ?? [...normalized.keys()].sort(), inMemoryDocumentSource(normalized), languages, presentationRoot);\n}\n\n// Compiles the documents of a folder as one application - the counterpart of the C# CompileFolder. Every\n// document is a root, read in ordinal order of its relative path as the C# compiler reads them, so a merge\n// keeps the same first declaration in either language; one an import places in a module or feature is\n// placed there.\nexport function parseFolder(files: readonly PlayFileSource[], languages?: ReadonlySet<string>): ApplicationCompilation {\n return compileApplication(new Map(files.map(file => [file.path, file.source])), undefined, languages);\n}\n\n"],"mappings":"+uEAsEA,SAAgB,qBAAqB,EAA0C,EAAiC,EAA4B,GAI1I,CACE,OAAO,+BAA+BA,EAAWC,EAAWC,CAAyB,CAAC,CAAC,MAC3F,CAEA,SAAS,+BAA+B,EAA0C,EAAiC,EAA4B,GAAO,CAClJ,IAAMC,EAAaC,EAAwB,cAAcJ,EAAU,OAAO,GAAYK,EAAS,sBAAwB,EAAK,CAAC,CAAC,IAAI,IAAa,CAAE,MAAOC,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,EAAW,SAAS,KAAMA,EAAW,SAAS,KAAMA,EAAW,SAAS,MAAM,CAAC,CAC3H"}
@@ -0,0 +1,2 @@
1
+ import"../../_virtual/_virtual/_rolldown/runtime.js";import{nativePattern as e}from"../Text/patterns.js";import{locationOf as t}from"./SourceLine.js";const n=e(`^form\\s+[A-Za-z_]\\w*\\s+for\\s+([\\w.]+)$`),r=e(`^execute\\s+([\\w.]+)$`),i=e(`^behavior\\s+[A-Za-z_]\\w*`),a=e(`^(?:field|parameter)\\s+([A-Za-z_]\\w*)(?:\\s|$)`),o=e(`^with\\s+\\w+\\s+from\\s+(.+)$`),s=e(`^on\\s+submit\\s+navigate\\s+to\\s+[\\w.]+\\s+by\\s+(.+)$`),c=e(`^set\\s+[\\w.$]+\\s+to\\s+(.+)$`),l=/^on\s+(success|failure|submit)$/;function collectContinuationValues(e,o){let s=[],c=/* @__PURE__ */ new Map,u=/* @__PURE__ */ new Map;for(let t of e){for(;s.length>0&&s.at(-1).indent>=t.indent;)s.pop();c.set(t,[...s]);let e=a.exec(t.content);if(e){let t=[...s].reverse().find(e=>n.test(e.content)||i.test(e.content));t&&u.set(t,[...u.get(t)??[],e[1]])}s.push(t)}return e.flatMap(e=>{let a=continuationOperand(e.content)??``,s=c.get(e),d=[],f=[];for(let e=0;e<s.length;e++){let t=s[e],i=s[e-1],a=l.exec(t.content)?.[1],o=i?r.exec(i.content):null;o&&a===`success`&&d.push(o[1]),o&&a===`failure`&&f.push(o[1]);let c=i?n.exec(i.content):null;c&&a===`submit`&&d.push(c[1])}if(/^on\s+submit\s+navigate\s+to\s+/.test(e.content)){let e=s.at(-1)?n.exec(s.at(-1).content):null;e&&d.push(e[1])}let p=s.filter(e=>i.test(e.content)).flatMap(e=>u.get(e)??[]);return[{text:a,location:t(e),scope:o,success:d,failure:f,parameters:p,locals:s.flatMap(e=>u.get(e)??[])}]})}function continuationOperand(e){return o.exec(e)?.[1]??s.exec(e)?.[1]??c.exec(e)?.[1]??/^notify\s+(?:info|warning|error)\s+(.+)$/.exec(e)?.[1]??/^confirm\s+(.+)$/.exec(e)?.[1]??null}export{collectContinuationValues,continuationOperand};
2
+ //# sourceMappingURL=ContinuationValues.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ContinuationValues.js","names":["pattern","formHeader","nativePattern","executeHeader","behaviorHeader","localDeclaration","argument","submitNavigation","stateValue","continuation","owners","parents","locals","line","lines","local","owner","parent","text","ancestry","success","failure","index","branch","outcome","executed","form","parameters","locationOf","content"],"sources":["../../../../../../Compiler/Parsing/ContinuationValues.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { nativePattern as pattern } from '../Text/patterns';\nimport { ContinuationValueUse } from './ContinuationValueUse';\nimport { locationOf, SourceLine } from './SourceLine';\n\nconst formHeader = pattern(/^form\\s+[A-Za-z_]\\w*\\s+for\\s+([\\w.]+)$/.source);\nconst executeHeader = pattern(/^execute\\s+([\\w.]+)$/.source);\nconst behaviorHeader = pattern(/^behavior\\s+[A-Za-z_]\\w*/.source);\nconst localDeclaration = pattern(/^(?:field|parameter)\\s+([A-Za-z_]\\w*)(?:\\s|$)/.source);\nconst argument = pattern(/^with\\s+\\w+\\s+from\\s+(.+)$/.source);\nconst submitNavigation = pattern(/^on\\s+submit\\s+navigate\\s+to\\s+[\\w.]+\\s+by\\s+(.+)$/.source);\nconst stateValue = pattern(/^set\\s+[\\w.$]+\\s+to\\s+(.+)$/.source);\nconst continuation = /^on\\s+(success|failure|submit)$/;\n\n// Lines have already had comments, fences and descriptions removed by the body reader.\n// Each owner remains alive only for its greater-indented subtree; siblings restore their ancestry.\nexport function collectContinuationValues(lines: readonly SourceLine[], scope: readonly string[]): ContinuationValueUse[] {\n const owners: SourceLine[] = [];\n const parents = new Map<SourceLine, readonly SourceLine[]>();\n const locals = new Map<SourceLine, string[]>();\n for (const line of lines) {\n while (owners.length > 0 && owners.at(-1)!.indent >= line.indent) owners.pop();\n parents.set(line, [...owners]);\n const local = localDeclaration.exec(line.content);\n if (local) {\n const owner = [...owners].reverse().find(parent => formHeader.test(parent.content) || behaviorHeader.test(parent.content));\n if (owner) locals.set(owner, [...locals.get(owner) ?? [], local[1]]);\n }\n owners.push(line);\n }\n return lines.flatMap(line => {\n const text = continuationOperand(line.content) ?? '';\n const ancestry = parents.get(line)!;\n const success: string[] = [];\n const failure: string[] = [];\n for (let index = 0; index < ancestry.length; index++) {\n const branch = ancestry[index];\n const parent = ancestry[index - 1];\n const outcome = continuation.exec(branch.content)?.[1];\n const executed = parent ? executeHeader.exec(parent.content) : null;\n if (executed && outcome === 'success') success.push(executed[1]);\n if (executed && outcome === 'failure') failure.push(executed[1]);\n const form = parent ? formHeader.exec(parent.content) : null;\n if (form && outcome === 'submit') success.push(form[1]);\n }\n // One-line form sugar is its own success continuation, not a screen action's navigation.\n if (/^on\\s+submit\\s+navigate\\s+to\\s+/.test(line.content)) {\n const form = ancestry.at(-1) ? formHeader.exec(ancestry.at(-1)!.content) : null;\n if (form) success.push(form[1]);\n }\n const parameters = ancestry.filter(parent => behaviorHeader.test(parent.content)).flatMap(parent => locals.get(parent) ?? []);\n return [{ text, location: locationOf(line), scope, success, failure, parameters,\n locals: ancestry.flatMap(parent => locals.get(parent) ?? []) }];\n });\n}\n\nexport function continuationOperand(content: string): string | null {\n return argument.exec(content)?.[1]\n ?? submitNavigation.exec(content)?.[1]\n ?? stateValue.exec(content)?.[1]\n ?? /^notify\\s+(?:info|warning|error)\\s+(.+)$/.exec(content)?.[1]\n ?? /^confirm\\s+(.+)$/.exec(content)?.[1]\n ?? null;\n}\n"],"mappings":"sJAOA,MAAMC,EAAaD,EAAQ,6CAA+C,EACpEG,EAAgBH,EAAQ,wBAA6B,EACrDI,EAAiBJ,EAAQ,4BAAiC,EAC1DK,EAAmBL,EAAQ,kDAAsD,EACjFM,EAAWN,EAAQ,gCAAmC,EACtDO,EAAmBP,EAAQ,2DAA2D,EACtFQ,EAAaR,EAAQ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F,IAAY,UAAUJ,EAAQ,KAAKM,EAAK,EAAE,CAC1D,CAEA,GAAI,kCAAkC,KAAKb,EAAK,OAAO,EAAG,CACtD,IAAMa,EAAOP,EAAS,GAAG,EAAE,EAAIlB,EAAW,KAAKkB,EAAS,GAAG,EAAE,CAAC,CAAE,OAAO,EAAI,KACvEO,GAAMN,EAAQ,KAAKM,EAAK,EAAE,CAClC,CACA,IAAMC,EAAaR,EAAS,OAAO,GAAUf,EAAe,KAAKa,EAAO,OAAO,CAAC,CAAC,CAAC,QAAQ,GAAUL,EAAO,IAAIK,CAAM,GAAK,CAAC,CAAC,EAC5H,MAAO,CAAC,CAAE,OAAM,SAAUW,EAAWf,CAAI,EAAG,QAAO,UAAS,UAAS,aACjE,OAAQM,EAAS,QAAQ,GAAUP,EAAO,IAAIK,CAAM,GAAK,CAAC,CAAC,CAAE,CAAC,CACtE,CAAC,CACL,CAEA,SAAgB,oBAAoB,EAAgC,CAChE,OAAOX,EAAS,KAAKuB,CAAO,CAAC,GAAG,IACzBtB,EAAiB,KAAKsB,CAAO,CAAC,GAAG,IACjCrB,EAAW,KAAKqB,CAAO,CAAC,GAAG,IAC3B,2CAA2C,KAAKA,CAAO,CAAC,GAAG,IAC3D,mBAAmB,KAAKA,CAAO,CAAC,GAAG,IACnC,IACX"}
@@ -1,2 +1,2 @@
1
- import"../../_virtual/_virtual/_rolldown/runtime.js";import{pattern as e}from"../Text/patterns.js";import{locationOf as t}from"./SourceLine.js";import{firstWord as n,unescapeIdentifier as r}from"./LineText.js";import{parseDescription as i}from"./DescriptionParser.js";import{validateInteractionBodies as a}from"./InteractionAlternatives.js";const o=e(`^form\\s+[A-Za-z_]\\w*\\s+for\\s+([A-Za-z_]\\w*(?:\\.\\w+)*)$`),s=e(`^(execute|invokes)\\s+([A-Za-z_]\\w*(?:\\.\\w+)*)$`),c=e(`^field\\s+([\\w.]+)(?:\\s|$)`),l=e(`^with\\s+([A-Za-z_]\\w*)\\s+from\\s+.+$`),u=e(`^(@?[\\w.]+)\\s*=(?!=|>)\\s*.+$`),d=e(`^parameter\\s+([A-Za-z_]\\w*)(?:\\s+([\\w.]+(?:\\[\\])?))?$`),f=/* @__PURE__ */ new Set([`refresh`,`navigate`,`open`,`close`,`set`,`notify`,`confirm`,`raise`,`on`,`when`,`otherwise`]);function collectInputUses(p,m){let h=[],g=/* @__PURE__ */ new Set,_=[],v=n(m.content)===`behavior`,y=null,recognize=e=>{for(;h.length>0&&h[h.length-1].indent>=e.indent;)h.pop();let i=v&&h.length===0?d.exec(e.content):null;i!==null&&g.add(i[1]);let a=o.exec(e.content),m=s.exec(e.content);if(a!==null)h.push({command:a[1],kind:`form`,indent:e.indent});else if(m!==null)h.push({command:m[2],kind:m[1],indent:e.indent});else if(f.has(n(e.content)))h.push({command:``,kind:`other`,indent:e.indent});else{let n=h.at(-1);if(n===void 0||n.kind===`other`)return;let i=(n.kind===`form`?c:n.kind===`execute`?l:u).exec(e.content);i!==null&&_.push({command:n.command,property:r(i[1]),scope:p.scope,location:t(e)})}};recognize(m);let b=[m];for(let t=p.peekChild(m.indent);t!==void 0;t=p.peekChild(m.indent)){for(p.reader.takeSignificant();h.length>0&&h[h.length-1].indent>=t.indent;)h.pop();o.test(m.content)&&n(t.content)===`description`&&h.at(-1)?.kind===`form`?y=i(p,t,y,`Form '${m.content.split(e(`\\s+`))[1]}'`):t.content.startsWith("```")?p.skipFencedBody():(b.push(t),recognize(t))}a(p,b);for(let e of _)p.inputUses.push(g.has(e.command)?{...e,isParameter:!0}:e)}export{collectInputUses};
1
+ import"../../_virtual/_virtual/_rolldown/runtime.js";import{pattern as e}from"../Text/patterns.js";import{locationOf as t}from"./SourceLine.js";import{firstWord as n,unescapeIdentifier as r}from"./LineText.js";import{parseDescription as i}from"./DescriptionParser.js";import{collectContinuationValues as a}from"./ContinuationValues.js";import{validateInteractionBodies as o}from"./InteractionAlternatives.js";const s=e(`^form\\s+[A-Za-z_]\\w*\\s+for\\s+([A-Za-z_]\\w*(?:\\.\\w+)*)$`),c=e(`^(execute|invokes)\\s+([A-Za-z_]\\w*(?:\\.\\w+)*)$`),l=e(`^field\\s+([\\w.]+)(?:\\s|$)`),u=e(`^with\\s+([A-Za-z_]\\w*)\\s+from\\s+.+$`),d=e(`^(@?[\\w.]+)\\s*=(?!=|>)\\s*.+$`),f=e(`^parameter\\s+([A-Za-z_]\\w*)(?:\\s+([\\w.]+(?:\\[\\])?))?$`),p=/* @__PURE__ */ new Set([`refresh`,`navigate`,`open`,`close`,`set`,`notify`,`confirm`,`raise`,`on`,`when`,`otherwise`]);function collectInputUses(m,h){let g=[],_=/* @__PURE__ */ new Set,v=[],y=n(h.content)===`behavior`,b=null,recognize=e=>{for(;g.length>0&&g[g.length-1].indent>=e.indent;)g.pop();let i=y&&g.length===0?f.exec(e.content):null;i!==null&&_.add(i[1]);let a=s.exec(e.content),o=c.exec(e.content);if(a!==null)g.push({command:a[1],kind:`form`,indent:e.indent});else if(o!==null)g.push({command:o[2],kind:o[1],indent:e.indent});else if(p.has(n(e.content)))g.push({command:``,kind:`other`,indent:e.indent});else{let n=g.at(-1);if(n===void 0||n.kind===`other`)return;let i=(n.kind===`form`?l:n.kind===`execute`?u:d).exec(e.content);i!==null&&v.push({command:n.command,property:r(i[1]),scope:m.scope,location:t(e)})}};recognize(h);let x=[h];for(let t=m.peekChild(h.indent);t!==void 0;t=m.peekChild(h.indent)){for(m.reader.takeSignificant();g.length>0&&g[g.length-1].indent>=t.indent;)g.pop();s.test(h.content)&&n(t.content)===`description`&&g.at(-1)?.kind===`form`?b=i(m,t,b,`Form '${h.content.split(e(`\\s+`))[1]}'`):t.content.startsWith("```")?m.skipFencedBody():(x.push(t),recognize(t))}o(m,x),m.continuationValues.push(...a(x,m.scope));for(let e of v)m.inputUses.push(_.has(e.command)?{...e,isParameter:!0}:e)}export{collectInputUses};
2
2
  //# sourceMappingURL=InputUses.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"InputUses.js","names":["form","pattern","execution","field","argument","mapping","parameter","actionBoundaries","owners","parameters","inputs","isBehavior","firstWord","header","formDescription","line","declared","formMatch","execute","owner","supplied","unescapeIdentifier","context","locationOf","lines","child","parseDescription","validateInteractionBodies","input"],"sources":["../../../../../../Compiler/Parsing/InputUses.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { SourceLocation } from '../Diagnostics/SourceLocation';\nimport { pattern } from '../Text/patterns';\nimport { firstWord, unescapeIdentifier } from './LineText';\nimport { validateInteractionBodies } from './InteractionAlternatives';\nimport { ParserContext } from './ParserContext';\nimport { parseDescription } from './DescriptionParser';\nimport { locationOf, SourceLine } from './SourceLine';\n\n// Typed authoring facts from bodies the TS syntax tree does not yet model. Never serialized as ESM.\nexport interface InputUse {\n readonly command: string;\n readonly property: string;\n readonly scope: readonly string[];\n readonly location: SourceLocation;\n readonly isParameter?: boolean;\n}\n\ninterface InputOwner { command: string; kind: 'form' | 'execute' | 'invokes' | 'other'; indent: number }\nconst form = pattern('^form\\\\s+[A-Za-z_]\\\\w*\\\\s+for\\\\s+([A-Za-z_]\\\\w*(?:\\\\.\\\\w+)*)$');\nconst execution = pattern('^(execute|invokes)\\\\s+([A-Za-z_]\\\\w*(?:\\\\.\\\\w+)*)$');\nconst field = pattern('^field\\\\s+([\\\\w.]+)(?:\\\\s|$)');\nconst argument = pattern('^with\\\\s+([A-Za-z_]\\\\w*)\\\\s+from\\\\s+.+$');\nconst mapping = pattern('^(@?[\\\\w.]+)\\\\s*=(?!=|>)\\\\s*.+$');\nconst parameter = pattern('^parameter\\\\s+([A-Za-z_]\\\\w*)(?:\\\\s+([\\\\w.]+(?:\\\\[\\\\])?))?$');\nconst actionBoundaries = new Set(['refresh', 'navigate', 'open', 'close', 'set', 'notify', 'confirm', 'raise', 'on', 'when', 'otherwise']);\n\n// A single forward walk, tracking owners by indentation and skipping fences as opaque text.\nexport function collectInputUses(context: ParserContext, header: SourceLine): void {\n const owners: InputOwner[] = [];\n const parameters = new Set<string>();\n const inputs: InputUse[] = [];\n const isBehavior = firstWord(header.content) === 'behavior';\n let formDescription: string | null = null;\n const recognize = (line: SourceLine): void => {\n while (owners.length > 0 && owners[owners.length - 1].indent >= line.indent) owners.pop();\n const declared = isBehavior && owners.length === 0 ? parameter.exec(line.content) : null;\n if (declared !== null) parameters.add(declared[1]);\n const formMatch = form.exec(line.content);\n const execute = execution.exec(line.content);\n if (formMatch !== null) owners.push({ command: formMatch[1], kind: 'form', indent: line.indent });\n else if (execute !== null) owners.push({ command: execute[2], kind: execute[1] as 'execute' | 'invokes', indent: line.indent });\n else if (actionBoundaries.has(firstWord(line.content))) owners.push({ command: '', kind: 'other', indent: line.indent });\n else {\n const owner = owners.at(-1);\n if (owner === undefined || owner.kind === 'other') return;\n const supplied = (owner.kind === 'form' ? field : owner.kind === 'execute' ? argument : mapping).exec(line.content);\n if (supplied !== null) inputs.push({ command: owner.command, property: unescapeIdentifier(supplied[1]), scope: context.scope, location: locationOf(line) });\n }\n };\n recognize(header);\n const lines = [header];\n for (let child = context.peekChild(header.indent); child !== undefined; child = context.peekChild(header.indent)) {\n context.reader.takeSignificant();\n while (owners.length > 0 && owners[owners.length - 1].indent >= child.indent) owners.pop();\n if (form.test(header.content) && firstWord(child.content) === 'description' && owners.at(-1)?.kind === 'form') {\n formDescription = parseDescription(context, child, formDescription, `Form '${header.content.split(pattern('\\\\s+'))[1]}'`);\n } else if (child.content.startsWith('```')) context.skipFencedBody();\n else {\n lines.push(child);\n recognize(child);\n }\n }\n validateInteractionBodies(context, lines);\n // Parameters may be declared after their bindings; commit facts once their scope is complete.\n for (const input of inputs) context.inputUses.push(parameters.has(input.command) ? { ...input, isParameter: true } : input);\n}\n"],"mappings":"qVAqBA,MAAMA,EAAOC,EAAQ,+DAA+D,EAC9EC,EAAYD,EAAQ,oDAAoD,EACxEE,EAAQF,EAAQ,8BAA8B,EAC9CG,EAAWH,EAAQ,yCAAyC,EAC5DI,EAAUJ,EAAQ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M,QAAS,SAAUE,EAAmBD,EAAS,EAAE,EAAG,MAAOE,EAAQ,MAAO,SAAUC,EAAWR,CAAI,CAAE,CAAC,CAC9J,CACJ,EACA,UAAUF,CAAM,EAChB,IAAMW,EAAQ,CAACX,CAAM,EACrB,IAAK,IAAIY,EAAQH,EAAQ,UAAUT,EAAO,MAAM,EAAGY,IAAU,IAAA,GAAW,EAAQH,EAAQ,UAAUT,EAAO,MAAM,EAAG,CAE9G,IADAS,EAAQ,OAAO,gBAAgB,EACxBd,EAAO,OAAS,GAAKA,EAAOA,EAAO,OAAS,EAAE,CAAC,QAAUiB,EAAM,QAAQjB,EAAO,IAAI,EACrFR,EAAK,KAAKa,EAAO,OAAO,GAAKD,EAAUa,EAAM,OAAO,IAAM,eAAiBjB,EAAO,GAAG,EAAE,CAAC,EAAE,OAAS,OACnG,EAAkBkB,EAAiBJ,EAASG,EAAOX,EAAiB,SAASD,EAAO,QAAQ,MAAMZ,EAAQ,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,EACjHwB,EAAM,QAAQ,WAAW,KAAK,EAAGH,EAAQ,eAAe,GAE/DE,EAAM,KAAKC,CAAK,EAChB,UAAUA,CAAK,EAEvB,CACAE,EAA0BL,EAASE,CAAK,EAExC,IAAK,IAAMI,KAASlB,EAAQY,EAAQ,UAAU,KAAKb,EAAW,IAAImB,EAAM,OAAO,EAAI,CAAE,GAAGA,EAAO,YAAa,EAAK,EAAIA,CAAK,CAC9H"}
1
+ {"version":3,"file":"InputUses.js","names":["form","pattern","execution","field","argument","mapping","parameter","actionBoundaries","owners","parameters","inputs","isBehavior","firstWord","header","formDescription","line","declared","formMatch","execute","owner","supplied","unescapeIdentifier","context","locationOf","lines","child","parseDescription","validateInteractionBodies","collectContinuationValues","input"],"sources":["../../../../../../Compiler/Parsing/InputUses.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { collectContinuationValues } from './ContinuationValues';\nimport { SourceLocation } from '../Diagnostics/SourceLocation';\nimport { pattern } from '../Text/patterns';\nimport { firstWord, unescapeIdentifier } from './LineText';\nimport { validateInteractionBodies } from './InteractionAlternatives';\nimport { ParserContext } from './ParserContext';\nimport { parseDescription } from './DescriptionParser';\nimport { locationOf, SourceLine } from './SourceLine';\n\n// Typed authoring facts from bodies the TS syntax tree does not yet model. Never serialized as ESM.\nexport interface InputUse {\n readonly command: string;\n readonly property: string;\n readonly scope: readonly string[];\n readonly location: SourceLocation;\n readonly isParameter?: boolean;\n}\n\ninterface InputOwner { command: string; kind: 'form' | 'execute' | 'invokes' | 'other'; indent: number }\nconst form = pattern('^form\\\\s+[A-Za-z_]\\\\w*\\\\s+for\\\\s+([A-Za-z_]\\\\w*(?:\\\\.\\\\w+)*)$');\nconst execution = pattern('^(execute|invokes)\\\\s+([A-Za-z_]\\\\w*(?:\\\\.\\\\w+)*)$');\nconst field = pattern('^field\\\\s+([\\\\w.]+)(?:\\\\s|$)');\nconst argument = pattern('^with\\\\s+([A-Za-z_]\\\\w*)\\\\s+from\\\\s+.+$');\nconst mapping = pattern('^(@?[\\\\w.]+)\\\\s*=(?!=|>)\\\\s*.+$');\nconst parameter = pattern('^parameter\\\\s+([A-Za-z_]\\\\w*)(?:\\\\s+([\\\\w.]+(?:\\\\[\\\\])?))?$');\nconst actionBoundaries = new Set(['refresh', 'navigate', 'open', 'close', 'set', 'notify', 'confirm', 'raise', 'on', 'when', 'otherwise']);\n\n// A single forward walk, tracking owners by indentation and skipping fences as opaque text.\nexport function collectInputUses(context: ParserContext, header: SourceLine): void {\n const owners: InputOwner[] = [];\n const parameters = new Set<string>();\n const inputs: InputUse[] = [];\n const isBehavior = firstWord(header.content) === 'behavior';\n let formDescription: string | null = null;\n const recognize = (line: SourceLine): void => {\n while (owners.length > 0 && owners[owners.length - 1].indent >= line.indent) owners.pop();\n const declared = isBehavior && owners.length === 0 ? parameter.exec(line.content) : null;\n if (declared !== null) parameters.add(declared[1]);\n const formMatch = form.exec(line.content);\n const execute = execution.exec(line.content);\n if (formMatch !== null) owners.push({ command: formMatch[1], kind: 'form', indent: line.indent });\n else if (execute !== null) owners.push({ command: execute[2], kind: execute[1] as 'execute' | 'invokes', indent: line.indent });\n else if (actionBoundaries.has(firstWord(line.content))) owners.push({ command: '', kind: 'other', indent: line.indent });\n else {\n const owner = owners.at(-1);\n if (owner === undefined || owner.kind === 'other') return;\n const supplied = (owner.kind === 'form' ? field : owner.kind === 'execute' ? argument : mapping).exec(line.content);\n if (supplied !== null) inputs.push({ command: owner.command, property: unescapeIdentifier(supplied[1]), scope: context.scope, location: locationOf(line) });\n }\n };\n recognize(header);\n const lines = [header];\n for (let child = context.peekChild(header.indent); child !== undefined; child = context.peekChild(header.indent)) {\n context.reader.takeSignificant();\n while (owners.length > 0 && owners[owners.length - 1].indent >= child.indent) owners.pop();\n if (form.test(header.content) && firstWord(child.content) === 'description' && owners.at(-1)?.kind === 'form') {\n formDescription = parseDescription(context, child, formDescription, `Form '${header.content.split(pattern('\\\\s+'))[1]}'`);\n } else if (child.content.startsWith('```')) context.skipFencedBody();\n else {\n lines.push(child);\n recognize(child);\n }\n }\n validateInteractionBodies(context, lines);\n context.continuationValues.push(...collectContinuationValues(lines, context.scope));\n // Parameters may be declared after their bindings; commit facts once their scope is complete.\n for (const input of inputs) context.inputUses.push(parameters.has(input.command) ? { ...input, isParameter: true } : input);\n}\n"],"mappings":"yZAsBA,MAAMA,EAAOC,EAAQ,+DAA+D,EAC9EC,EAAYD,EAAQ,oDAAoD,EACxEE,EAAQF,EAAQ,8BAA8B,EAC9CG,EAAWH,EAAQ,yCAAyC,EAC5DI,EAAUJ,EAAQ,iCAAiC,EACnDK,EAAYL,EAAQ,6DAA6D,EACjFM,kBAAmB,IAAI,IAAI,CAAC,UAAW,WAAY,OAAQ,QAAS,MAAO,SAAU,UAAW,QAAS,KAAM,OAAQ,WAAW,CAAC,EAGzI,SAAgB,iBAAiB,EAAwB,EAA0B,CAC/E,IAAMC,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AAO,MAAM,EAAGY,IAAU,IAAA,GAAW,EAAQH,EAAQ,UAAUT,EAAO,MAAM,EAAG,CAE9G,IADAS,EAAQ,OAAO,gBAAgB,EACxBd,EAAO,OAAS,GAAKA,EAAOA,EAAO,OAAS,EAAE,CAAC,QAAUiB,EAAM,QAAQjB,EAAO,IAAI,EACrFR,EAAK,KAAKa,EAAO,OAAO,GAAKD,EAAUa,EAAM,OAAO,IAAM,eAAiBjB,EAAO,GAAG,EAAE,CAAC,EAAE,OAAS,OACnG,EAAkBkB,EAAiBJ,EAASG,EAAOX,EAAiB,SAASD,EAAO,QAAQ,MAAMZ,EAAQ,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,EACjHwB,EAAM,QAAQ,WAAW,KAAK,EAAGH,EAAQ,eAAe,GAE/DE,EAAM,KAAKC,CAAK,EAChB,UAAUA,CAAK,EAEvB,CACAE,EAA0BL,EAASE,CAAK,EACxCF,EAAQ,mBAAmB,KAAK,GAAGM,EAA0BJ,EAAOF,EAAQ,KAAK,CAAC,EAElF,IAAK,IAAMO,KAASnB,EAAQY,EAAQ,UAAU,KAAKb,EAAW,IAAIoB,EAAM,OAAO,EAAI,CAAE,GAAGA,EAAO,YAAa,EAAK,EAAIA,CAAK,CAC9H"}
@@ -1,2 +1,2 @@
1
- import"../../_virtual/_virtual/_rolldown/runtime.js";import{sourceLocation as e}from"../Diagnostics/SourceLocation.js";import{legacySourceOptions as t}from"../Syntax/SourceOptions.js";var n=class ParserContext{reader;path;#e=[];triggerData=[];inputUses=[];guardedInteractions=[];interactionAncestors=/* @__PURE__ */ new Map;scope=[];languages;sourceOptions=t;authoredDeclarations=!1;deferIdentityValidation=!1;streamCandidates;get valueContext(){if(this.sourceOptions.numericMode===`exact`)return this;let e=new ParserContext(this.reader,this.path,this.languages);return e.sourceOptions=this.sourceOptions,e}constructor(e,t,n=/* @__PURE__ */ new Set([`csharp`,`typescript`,`react`,`html`,`sql`])){this.reader=e,this.path=t,this.languages=n}get start(){return e(1,1,this.path)}get diagnostics(){return this.nestedNumericDirectives.size>0&&this.sourceOptions.numericMode!==`legacy`&&this.reader.atEnd&&(this.#e.push(...[...this.nestedNumericDirectives].sort((e,t)=>e[0]-t[0]).map(e=>e[1])),this.nestedNumericDirectives.clear()),this.#e}nestedNumericDirectives=/* @__PURE__ */ new Map;claimField(e){this.nestedNumericDirectives.delete(e.number)}information(e,t,n){this.#e.push({severity:`information`,code:e,message:t,location:n})}error(e,t,n){this.#e.push({severity:`error`,code:e,message:t,location:n})}warning(e,t,n){this.#e.push({severity:`warning`,code:e,message:t,location:n})}peekChild(e){let t=this.reader.peekSignificant();return t!==void 0&&t.indent>e?t:void 0}skipBlock(e){for(;this.peekChild(e)!==void 0;)this.reader.takeSignificant()}skipOpaqueBlock(e){let t=this.peekChild(e);for(;t!==void 0;)this.reader.takeSignificant(),t.content.startsWith("```")&&this.skipFencedBody(),t=this.peekChild(e)}skipFencedBody(){for(let e=this.reader.takeRaw();e!==void 0;e=this.reader.takeRaw())if(e.raw.trim()==="```")return}};export{n as ParserContext};
1
+ import"../../_virtual/_virtual/_rolldown/runtime.js";import{sourceLocation as e}from"../Diagnostics/SourceLocation.js";import{legacySourceOptions as t}from"../Syntax/SourceOptions.js";var n=class ParserContext{reader;path;#e=[];triggerData=[];inputUses=[];continuationValues=[];guardedInteractions=[];interactionAncestors=/* @__PURE__ */ new Map;scope=[];languages;sourceOptions=t;authoredDeclarations=!1;deferIdentityValidation=!1;streamCandidates;get valueContext(){if(this.sourceOptions.numericMode===`exact`)return this;let e=new ParserContext(this.reader,this.path,this.languages);return e.sourceOptions=this.sourceOptions,e}constructor(e,t,n=/* @__PURE__ */ new Set([`csharp`,`typescript`,`react`,`html`,`sql`])){this.reader=e,this.path=t,this.languages=n}get start(){return e(1,1,this.path)}get diagnostics(){return this.nestedNumericDirectives.size>0&&this.sourceOptions.numericMode!==`legacy`&&this.reader.atEnd&&(this.#e.push(...[...this.nestedNumericDirectives].sort((e,t)=>e[0]-t[0]).map(e=>e[1])),this.nestedNumericDirectives.clear()),this.#e}nestedNumericDirectives=/* @__PURE__ */ new Map;claimField(e){this.nestedNumericDirectives.delete(e.number)}information(e,t,n){this.#e.push({severity:`information`,code:e,message:t,location:n})}error(e,t,n){this.#e.push({severity:`error`,code:e,message:t,location:n})}warning(e,t,n){this.#e.push({severity:`warning`,code:e,message:t,location:n})}peekChild(e){let t=this.reader.peekSignificant();return t!==void 0&&t.indent>e?t:void 0}skipBlock(e){for(;this.peekChild(e)!==void 0;)this.reader.takeSignificant()}skipOpaqueBlock(e){let t=this.peekChild(e);for(;t!==void 0;)this.reader.takeSignificant(),t.content.startsWith("```")&&this.skipFencedBody(),t=this.peekChild(e)}skipFencedBody(){for(let e=this.reader.takeRaw();e!==void 0;e=this.reader.takeRaw())if(e.raw.trim()==="```")return}};export{n as ParserContext};
2
2
  //# sourceMappingURL=ParserContext.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ParserContext.js","names":["ParserContext","legacySourceOptions","context","reader","path","languages","sourceLocation","#diagnostics","first","second","entry","line","parentIndent","child"],"sources":["../../../../../../Compiler/Parsing/ParserContext.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { Diagnostic } from '../Diagnostics/Diagnostic';\nimport { CommandStreamCandidates } from './CommandStreamCandidates';\nimport { SourceLocation, sourceLocation } from '../Diagnostics/SourceLocation';\nimport { PropertySyntax } from '../Syntax/Declarations';\nimport { legacySourceOptions, SourceOptions } from '../Syntax/SourceOptions';\nimport { InputUse } from './InputUses';\nimport { GuardedInteractionBinding, InteractionAncestor } from './InteractionAlternatives';\nimport { LineReader } from './LineReader';\nimport { SourceLine } from './SourceLine';\n\n// What every parser shares while it reads one document: the line reader, the diagnostics found so far and\n// the file the document came from.\nexport class ParserContext {\n readonly #diagnostics: Diagnostic[] = [];\n // Authoring verification needs these committed values even though SyntaxJson omits them.\n readonly triggerData: PropertySyntax[] = [];\n readonly inputUses: InputUse[] = [];\n readonly guardedInteractions: GuardedInteractionBinding[] = [];\n interactionAncestors: ReadonlyMap<number, readonly InteractionAncestor[]> = new Map();\n scope: readonly string[] = [];\n readonly languages: ReadonlySet<string>;\n sourceOptions: SourceOptions = legacySourceOptions;\n authoredDeclarations = false;\n deferIdentityValidation = false;\n streamCandidates?: CommandStreamCandidates;\n\n // Structural enrichment of formerly opaque Legacy fields must not add diagnostics. Exact operands\n // use the owning context so representability failures cannot turn into successful opaque syntax.\n get valueContext(): ParserContext {\n if (this.sourceOptions.numericMode === 'exact') return this;\n const context = new ParserContext(this.reader, this.path, this.languages);\n context.sourceOptions = this.sourceOptions;\n return context;\n }\n\n constructor(readonly reader: LineReader, readonly path?: string, languages: ReadonlySet<string> = new Set(['csharp', 'typescript', 'react', 'html', 'sql'])) {\n this.languages = languages;\n }\n\n get start(): SourceLocation {\n return sourceLocation(1, 1, this.path);\n }\n\n get diagnostics(): readonly Diagnostic[] {\n // Directive-shaped lines nobody claimed as a field are errors, wherever they sit.\n if (this.nestedNumericDirectives.size > 0 && this.sourceOptions.numericMode !== 'legacy' && this.reader.atEnd) {\n this.#diagnostics.push(...[...this.nestedNumericDirectives].sort((first, second) => first[0] - second[0]).map(entry => entry[1]));\n this.nestedNumericDirectives.clear();\n }\n return this.#diagnostics;\n }\n\n // Directive-shaped lines below the top level, keyed by line number, still unclaimed as a field.\n nestedNumericDirectives = new Map<number, Diagnostic>();\n\n claimField(line: SourceLine): void {\n this.nestedNumericDirectives.delete(line.number);\n }\n\n information(code: string, message: string, location: SourceLocation): void {\n this.#diagnostics.push({ severity: 'information', code, message, location });\n }\n\n error(code: string, message: string, location: SourceLocation): void {\n this.#diagnostics.push({ severity: 'error', code, message, location });\n }\n\n warning(code: string, message: string, location: SourceLocation): void {\n this.#diagnostics.push({ severity: 'warning', code, message, location });\n }\n\n // The next significant line when it is indented deeper than its parent - that is, when it belongs to\n // the parent's body under the offside rule.\n peekChild(parentIndent: number): SourceLine | undefined {\n const line = this.reader.peekSignificant();\n return line !== undefined && line.indent > parentIndent ? line : undefined;\n }\n\n // Skips the body of a construct, the way the C# parser does after reporting it.\n skipBlock(parentIndent: number): void {\n while (this.peekChild(parentIndent) !== undefined) {\n this.reader.takeSignificant();\n }\n }\n\n // Skips the body of a construct this compiler deliberately does not model. Unlike skipBlock it steps\n // over fenced code blocks whole, because a fenced line may be indented less than the block it is in -\n // reading it as significant would end the skip early and misread the code as Screenplay.\n skipOpaqueBlock(parentIndent: number): void {\n let child = this.peekChild(parentIndent);\n while (child !== undefined) {\n this.reader.takeSignificant();\n if (child.content.startsWith('```')) {\n this.skipFencedBody();\n }\n child = this.peekChild(parentIndent);\n }\n }\n\n // Takes the raw lines of a fenced block up to and including its closing fence.\n skipFencedBody(): void {\n for (let line = this.reader.takeRaw(); line !== undefined; line = this.reader.takeRaw()) {\n if (line.raw.trim() === '```') {\n return;\n }\n }\n }\n}\n"],"mappings":"wLAeA,IAAaA,EAAb,MAAa,aAAc,CAuBF,OAA6B,KAtBlD,GAAsC,CAAC,EAEvC,YAAyC,CAAC,EAC1C,UAAiC,CAAC,EAClC,oBAA4D,CAAC,EAC7D,qCAA4E,IAAI,IAChF,MAA2B,CAAC,EAC5B,UACA,cAA+BC,EAC/B,qBAAuB,GACvB,wBAA0B,GAC1B,iBAIA,IAAI,cAA8B,CAC9B,GAAI,KAAK,cAAc,cAAgB,QAAS,OAAO,KACvD,IAAMC,EAAU,IAAI,cAAc,KAAK,OAAQ,KAAK,KAAM,KAAK,SAAS,EAExE,MADA,GAAQ,cAAgB,KAAK,cACtBA,CACX,CAEA,YAAY,EAA6B,EAAwB,kBAAiC,IAAI,IAAI,CAAC,SAAU,aAAc,QAAS,OAAQ,KAAK,CAAC,EAAG,CAAxI,KAAA,OAAAC,EAA6B,KAAA,KAAAC,EAC9C,KAAK,UAAYC,CACrB,CAEA,IAAI,OAAwB,CACxB,OAAOC,EAAe,EAAG,EAAG,KAAK,IAAI,CACzC,CAEA,IAAI,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,EAClF,GAAIA,EAAK,IAAI,KAAK,IAAM,MACpB,MAGZ,CACJ"}
1
+ {"version":3,"file":"ParserContext.js","names":["ParserContext","legacySourceOptions","context","reader","path","languages","sourceLocation","#diagnostics","first","second","entry","line","parentIndent","child"],"sources":["../../../../../../Compiler/Parsing/ParserContext.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { Diagnostic } from '../Diagnostics/Diagnostic';\nimport { CommandStreamCandidates } from './CommandStreamCandidates';\nimport { SourceLocation, sourceLocation } from '../Diagnostics/SourceLocation';\nimport { PropertySyntax } from '../Syntax/Declarations';\nimport { legacySourceOptions, SourceOptions } from '../Syntax/SourceOptions';\nimport { InputUse } from './InputUses';\nimport { ContinuationValueUse } from './ContinuationValueUse';\nimport { GuardedInteractionBinding, InteractionAncestor } from './InteractionAlternatives';\nimport { LineReader } from './LineReader';\nimport { SourceLine } from './SourceLine';\n\n// What every parser shares while it reads one document: the line reader, the diagnostics found so far and\n// the file the document came from.\nexport class ParserContext {\n readonly #diagnostics: Diagnostic[] = [];\n // Authoring verification needs these committed values even though SyntaxJson omits them.\n readonly triggerData: PropertySyntax[] = [];\n readonly inputUses: InputUse[] = [];\n readonly continuationValues: ContinuationValueUse[] = [];\n readonly guardedInteractions: GuardedInteractionBinding[] = [];\n interactionAncestors: ReadonlyMap<number, readonly InteractionAncestor[]> = new Map();\n scope: readonly string[] = [];\n readonly languages: ReadonlySet<string>;\n sourceOptions: SourceOptions = legacySourceOptions;\n authoredDeclarations = false;\n deferIdentityValidation = false;\n streamCandidates?: CommandStreamCandidates;\n\n // Structural enrichment of formerly opaque Legacy fields must not add diagnostics. Exact operands\n // use the owning context so representability failures cannot turn into successful opaque syntax.\n get valueContext(): ParserContext {\n if (this.sourceOptions.numericMode === 'exact') return this;\n const context = new ParserContext(this.reader, this.path, this.languages);\n context.sourceOptions = this.sourceOptions;\n return context;\n }\n\n constructor(readonly reader: LineReader, readonly path?: string, languages: ReadonlySet<string> = new Set(['csharp', 'typescript', 'react', 'html', 'sql'])) {\n this.languages = languages;\n }\n\n get start(): SourceLocation {\n return sourceLocation(1, 1, this.path);\n }\n\n get diagnostics(): readonly Diagnostic[] {\n // Directive-shaped lines nobody claimed as a field are errors, wherever they sit.\n if (this.nestedNumericDirectives.size > 0 && this.sourceOptions.numericMode !== 'legacy' && this.reader.atEnd) {\n this.#diagnostics.push(...[...this.nestedNumericDirectives].sort((first, second) => first[0] - second[0]).map(entry => entry[1]));\n this.nestedNumericDirectives.clear();\n }\n return this.#diagnostics;\n }\n\n // Directive-shaped lines below the top level, keyed by line number, still unclaimed as a field.\n nestedNumericDirectives = new Map<number, Diagnostic>();\n\n claimField(line: SourceLine): void {\n this.nestedNumericDirectives.delete(line.number);\n }\n\n information(code: string, message: string, location: SourceLocation): void {\n this.#diagnostics.push({ severity: 'information', code, message, location });\n }\n\n error(code: string, message: string, location: SourceLocation): void {\n this.#diagnostics.push({ severity: 'error', code, message, location });\n }\n\n warning(code: string, message: string, location: SourceLocation): void {\n this.#diagnostics.push({ severity: 'warning', code, message, location });\n }\n\n // The next significant line when it is indented deeper than its parent - that is, when it belongs to\n // the parent's body under the offside rule.\n peekChild(parentIndent: number): SourceLine | undefined {\n const line = this.reader.peekSignificant();\n return line !== undefined && line.indent > parentIndent ? line : undefined;\n }\n\n // Skips the body of a construct, the way the C# parser does after reporting it.\n skipBlock(parentIndent: number): void {\n while (this.peekChild(parentIndent) !== undefined) {\n this.reader.takeSignificant();\n }\n }\n\n // Skips the body of a construct this compiler deliberately does not model. Unlike skipBlock it steps\n // over fenced code blocks whole, because a fenced line may be indented less than the block it is in -\n // reading it as significant would end the skip early and misread the code as Screenplay.\n skipOpaqueBlock(parentIndent: number): void {\n let child = this.peekChild(parentIndent);\n while (child !== undefined) {\n this.reader.takeSignificant();\n if (child.content.startsWith('```')) {\n this.skipFencedBody();\n }\n child = this.peekChild(parentIndent);\n }\n }\n\n // Takes the raw lines of a fenced block up to and including its closing fence.\n skipFencedBody(): void {\n for (let line = this.reader.takeRaw(); line !== undefined; line = this.reader.takeRaw()) {\n if (line.raw.trim() === '```') {\n return;\n }\n }\n }\n}\n"],"mappings":"wLAgBA,IAAaA,EAAb,MAAa,aAAc,CAwBF,OAA6B,KAvBlD,GAAsC,CAAC,EAEvC,YAAyC,CAAC,EAC1C,UAAiC,CAAC,EAClC,mBAAsD,CAAC,EACvD,oBAA4D,CAAC,EAC7D,qCAA4E,IAAI,IAChF,MAA2B,CAAC,EAC5B,UACA,cAA+BC,EAC/B,qBAAuB,GACvB,wBAA0B,GAC1B,iBAIA,IAAI,cAA8B,CAC9B,GAAI,KAAK,cAAc,cAAgB,QAAS,OAAO,KACvD,IAAMC,EAAU,IAAI,cAAc,KAAK,OAAQ,KAAK,KAAM,KAAK,SAAS,EAExE,MADA,GAAQ,cAAgB,KAAK,cACtBA,CACX,CAEA,YAAY,EAA6B,EAAwB,kBAAiC,IAAI,IAAI,CAAC,SAAU,aAAc,QAAS,OAAQ,KAAK,CAAC,EAAG,CAAxI,KAAA,OAAAC,EAA6B,KAAA,KAAAC,EAC9C,KAAK,UAAYC,CACrB,CAEA,IAAI,OAAwB,CACxB,OAAOC,EAAe,EAAG,EAAG,KAAK,IAAI,CACzC,CAEA,IAAI,aAAqC,CAMrC,OAJI,KAAK,wBAAwB,KAAO,GAAK,KAAK,cAAc,cAAgB,UAAY,KAAK,OAAO,QACpG,KAAKC,GAAa,KAAK,GAAG,CAAC,GAAG,KAAK,uBAAuB,CAAC,CAAC,MAAM,EAAO,IAAWC,EAAM,GAAKC,EAAO,EAAE,CAAC,CAAC,IAAI,GAASC,EAAM,EAAE,CAAC,EAChI,KAAK,wBAAwB,MAAM,GAEhC,KAAKH,EAChB,CAGA,wCAA0B,IAAI,IAE9B,WAAW,EAAwB,CAC/B,KAAK,wBAAwB,OAAOI,EAAK,MAAM,CACnD,CAEA,YAAY,EAAc,EAAiB,EAAgC,CACvE,KAAKJ,GAAa,KAAK,CAAE,SAAU,cAAe,OAAM,UAAS,UAAS,CAAC,CAC/E,CAEA,MAAM,EAAc,EAAiB,EAAgC,CACjE,KAAKA,GAAa,KAAK,CAAE,SAAU,QAAS,OAAM,UAAS,UAAS,CAAC,CACzE,CAEA,QAAQ,EAAc,EAAiB,EAAgC,CACnE,KAAKA,GAAa,KAAK,CAAE,SAAU,UAAW,OAAM,UAAS,UAAS,CAAC,CAC3E,CAIA,UAAU,EAA8C,CACpD,IAAMI,EAAO,KAAK,OAAO,gBAAgB,EACzC,OAAOA,IAAS,IAAA,IAAaA,EAAK,OAASC,EAAeD,EAAO,IAAA,EACrE,CAGA,UAAU,EAA4B,CAClC,KAAO,KAAK,UAAUC,CAAY,IAAM,IAAA,IACpC,KAAK,OAAO,gBAAgB,CAEpC,CAKA,gBAAgB,EAA4B,CACxC,IAAIC,EAAQ,KAAK,UAAUD,CAAY,EACvC,KAAOC,IAAU,IAAA,IACb,KAAK,OAAO,gBAAgB,EACxBA,EAAM,QAAQ,WAAW,KAAK,GAC9B,KAAK,eAAe,EAExB,EAAQ,KAAK,UAAUD,CAAY,CAE3C,CAGA,gBAAuB,CACnB,IAAK,IAAID,EAAO,KAAK,OAAO,QAAQ,EAAGA,IAAS,IAAA,GAAW,EAAO,KAAK,OAAO,QAAQ,EAClF,GAAIA,EAAK,IAAI,KAAK,IAAM,MACpB,MAGZ,CACJ"}
@@ -0,0 +1,2 @@
1
+ import"../../_virtual/_virtual/_rolldown/runtime.js";function responseCommandResolver(e,t){let n=/* @__PURE__ */ new Map;return(r,i)=>{let a=`${i.join(`.`)}|${r}`;if(n.has(a))return n.get(a);let o=t.filter(e=>e.qualifiedName.split(`.`).at(-1)===r),s=(e.filter(e=>e.command.name===r.split(`.`).at(-1)).length===0&&o.length===1?o[0].qualifiedName:r).split(`.`),c=e.filter(e=>e.command.name===s.at(-1));if(s.length>1){let e=s.slice(0,-1);c=c.filter(t=>e.length<=t.scope.length&&e.every((n,r)=>t.scope[t.scope.length-e.length+r]===n))}else for(let e=i.length;e>=0;e--){let t=c.filter(t=>e<=t.scope.length&&i.slice(0,e).every((e,n)=>t.scope[n]===e));if(t.length>0){c=t;break}}let l=c.length===1?c[0].command:null;return n.set(a,l),l}}export{responseCommandResolver};
2
+ //# sourceMappingURL=ResponseCommandResolver.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ResponseCommandResolver.js","names":["resolved","key","from","name","imported","imports","entry","segments","entries","candidates","qualifiers","index","value","depth","visible","command"],"sources":["../../../../../../Compiler/Parsing/ResponseCommandResolver.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { CommandSyntax } from '../Syntax/Commands';\n\n// Shared authoring resolution for input/response validation and continuation editor scopes.\nexport function responseCommandResolver(entries: readonly { command: CommandSyntax; scope: readonly string[] }[], imports: readonly { qualifiedName: string }[]): (name: string, from: readonly string[]) => CommandSyntax | null {\n const resolved = new Map<string, CommandSyntax | null>();\n return (name, from) => {\n const key = `${from.join('.')}|${name}`;\n if (resolved.has(key)) return resolved.get(key)!;\n const imported = imports.filter(entry => entry.qualifiedName.split('.').at(-1) === name);\n const local = entries.filter(entry => entry.command.name === name.split('.').at(-1));\n const reference = local.length === 0 && imported.length === 1 ? imported[0].qualifiedName : name;\n const segments = reference.split('.');\n let candidates = entries.filter(entry => entry.command.name === segments.at(-1));\n if (segments.length > 1) {\n const qualifiers = segments.slice(0, -1);\n candidates = candidates.filter(entry => qualifiers.length <= entry.scope.length && qualifiers.every((value, index) => entry.scope[entry.scope.length - qualifiers.length + index] === value));\n } else {\n for (let depth = from.length; depth >= 0; depth--) {\n const visible = candidates.filter(entry => depth <= entry.scope.length && from.slice(0, depth).every((value, index) => entry.scope[index] === value));\n if (visible.length > 0) { candidates = visible; break; }\n }\n }\n const command = candidates.length === 1 ? candidates[0].command : null;\n resolved.set(key, command);\n return command;\n };\n}\n"],"mappings":"qDAMA,SAAgB,wBA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
- import"../../_virtual/_virtual/_rolldown/runtime.js";import{DiagnosticCodes as e}from"../Diagnostics/DiagnosticCodes.js";import{exactIsIntegral as t}from"../Syntax/ExactMathFacts.js";import{responseDateValue as n}from"./ResponseDateValues.js";import{specificationCommandExamples as r}from"./SpecificationCommandExamples.js";const i=/* @__PURE__ */ new Set([`Uuid`,`String`,`Int`,`Decimal`,`Bool`,`Date`,`DateTime`]);function validateResponses(t,n,a=n.inputUses){let o=r(t),s=[],collect=(e,t)=>{let n=[...t,e.name];e.slices.forEach(e=>s.push({slice:e,scope:[...n,e.name]})),e.features.forEach(e=>collect(e,n))};t.modules.forEach(e=>e.features.forEach(t=>collect(t,[e.name])));let c=/* @__PURE__ */ new Map,l=/* @__PURE__ */ new Map,u=/* @__PURE__ */ new Map;for(let{slice:e,scope:t}of s)for(let n of e.commands){let e=c.get(n.name)??[];e.push({command:n,scope:t}),c.set(n.name,e),l.set(n,uniqueByName(n.properties)),n.response?.kind===`RecordCommandResponseSyntax`&&u.set(n,uniqueByName(n.response.fields))}let d=/* @__PURE__ */ new Map;for(let e of t.imports){let t=e.qualifiedName.split(`.`).at(-1);d.set(t,[...d.get(t)??[],e.qualifiedName])}let f=/* @__PURE__ */ new Map,resolve=(e,t)=>{let n=`${t.join(`.`)}|${e}`;if(f.has(n))return f.get(n);let r=d.get(e)??[],i=((c.get(e.split(`.`).at(-1))??[]).length===0&&r.length===1?r[0]:e).split(`.`),a=c.get(i.at(-1))??[];if(i.length>1){let e=i.slice(0,-1);a=a.filter(t=>e.length<=t.scope.length&&e.every((n,r)=>t.scope[t.scope.length-e.length+r]===n))}else for(let e=t.length;e>=0;e--){let n=a.filter(n=>e<=n.scope.length&&t.slice(0,e).every((e,t)=>n.scope[t]===e));if(n.length>0){a=n;break}}let o=a.length===1?a[0].command:null;return f.set(n,o),o},p=uniqueByName(t.concepts),m=new Set(t.concepts.map(e=>e.name)),h=new Map([...uniqueByName(t.types)].map(([e,t])=>[e,uniqueByName(t.properties)])),g=new Set(s.flatMap(e=>e.slice.readModels.map(e=>e.name))),_=new Set([...l.keys()].flatMap(e=>[...e.properties])),checkDeclarations=t=>{for(let r of t)r.isGenerated&&!_.has(r)&&n.error(e.GeneratedPropertyOutsideCommand,`Generated properties can only be declared on commands.`,r.location)},checkFeature=e=>{e.features.forEach(checkFeature);for(let t of e.slices){for(let e of t.commands)for(let t of e.produces)t.inlineEvent!==null&&checkDeclarations(t.inlineEvent.properties);t.events.forEach(e=>checkDeclarations(e.properties)),t.readModels.forEach(e=>checkDeclarations(e.properties));for(let e of t.reactions)for(let t of e.triggers)for(let e of t.produces)e.inlineEvent!==null&&checkDeclarations(e.inlineEvent.properties)}};t.types.forEach(e=>checkDeclarations(e.properties)),t.modules.forEach(e=>e.features.forEach(checkFeature));let validateSource=(t,r,i)=>{let a=l.get(i).get(t.property);if(a===void 0){n.error(e.InvalidResponseSource,`Response source '${t.property}' must reference one direct command property.`,t.location);return}let o=a.type;(o.isCollection||g.has(o.name))&&n.error(e.InvalidResponseShape,`Collection and whole-read-model responses are not supported.`,t.location),r!==null&&(r.name!==o.name||r.isCollection!==o.isCollection||r.isOptional!==o.isOptional)&&n.error(e.InvalidResponseShape,`An explicit response field type must match its source's declared type, collection shape and optionality.`,r.location)};for(let t of l.keys()){for(let r of t.properties){if(!r.isGenerated)continue;let t=p.get(r.type.name);(r.type.isOptional||r.type.isCollection||(t===void 0?i.has(r.type.name)||h.has(r.type.name)||m.has(r.type.name)||g.has(r.type.name):t.type!==`Uuid`&&t.generation==null))&&n.error(e.InvalidGeneratedType,`A generated property must be a required, noncollection generatable concept.`,r.location)}let r=t.response;if(r?.kind===`ScalarCommandResponseSyntax`)validateSource(r.source,null,t);else if(r?.kind===`RecordCommandResponseSyntax`){r.fields.length===0&&n.error(e.InvalidCommandResponse,`A response block requires at least one field.`,r.location);let i=/* @__PURE__ */ new Set;for(let a of r.fields)i.has(a.name)&&n.error(e.DuplicateResponseField,`Duplicate response field '${a.name}'.`,a.location),i.add(a.name),validateSource(a.source,a.type,t)}}let validateSpecification=(t,r)=>{let a=o(t.when,r),s=a===null?null:resolve(a.commandType,r);if(a!==null&&s!==null){let t=l.get(s);for(let r of a.values)t.get(r.property.split(`.`)[0])?.isGenerated&&n.error(e.GeneratedPropertySuppliedAsInput,`Generated property '${r.property}' cannot be supplied as request or form input.`,r.location);let r=[...t.values()].filter(e=>e.isIdentifier);if(a.for!==null&&r.length===1&&r[0].isGenerated){let t=r[0].type;(i.has(t.name)||p.has(t.name)||h.has(t.name))&&(t.isOptional||t.isCollection||![`Uuid`,`String`].includes(p.get(t.name)?.type??``)||!compatibleValue(a.for,t,p,h))&&n.error(e.InvalidGeneratedFixture,`A generated identifier fixture must supply one compatible concrete UUID value through 'for'.`,a.for.location)}let o=/* @__PURE__ */ new Set;for(let r of a.generatedValues??[]){let i=t.get(r.property);(o.has(r.property)||i===void 0||!i.isGenerated||i.isIdentifier||!compatibleValue(r.source,i.type,p,h))&&n.error(e.InvalidGeneratedFixture,`A generated fixture must uniquely supply a compatible value for a nonidentifier generated command property.`,r.location),o.add(r.property)}}let c=t.thenReturns;if(c==null||((a===null||t.thenErrors.length>0||t.thenDenied!=null)&&n.error(e.InvalidReturnExpectation,`A return expectation requires a command action and cannot accompany an error or denial.`,c.location),s===null))return;let d=s.response,f=l.get(s);if(c.kind===`ScalarSpecificationReturnSyntax`&&d?.kind===`ScalarCommandResponseSyntax`&&f.has(d.source.property))compatibleValue(c.value,f.get(d.source.property).type,p,h)||n.error(e.InvalidReturnExpectation,`The expected return value must match the response source's type.`,c.location);else if(c.kind===`RecordSpecificationReturnSyntax`&&d?.kind===`RecordCommandResponseSyntax`){c.fields.length===0&&n.error(e.InvalidReturnExpectation,`A record return expectation requires at least one field.`,c.location);let t=u.get(s),r=/* @__PURE__ */ new Set;for(let i of c.fields){let a=t.get(i.property),o=a===void 0?void 0:f.get(a.source.property);(r.has(i.property)||o===void 0||!compatibleValue(i.source,o.type,p,h))&&n.error(e.InvalidReturnExpectation,`A return assertion must uniquely name a response field and supply a compatible concrete value.`,i.location),r.add(i.property)}}else n.error(e.InvalidReturnExpectation,`The return expectation must match the command's scalar or record response shape.`,c.location)};for(let{slice:e,scope:t}of s)e.specifications.forEach(e=>validateSpecification(e,t));for(let t of a){if(t.isParameter===!0)continue;let r=resolve(t.command,t.scope);r!==null&&l.get(r).get(t.property.split(`.`)[0])?.isGenerated&&n.error(e.GeneratedPropertySuppliedAsInput,`Generated property '${t.property}' cannot be supplied as request or form input.`,t.location)}}function uniqueByName(e){let t=/* @__PURE__ */ new Map,n=/* @__PURE__ */ new Set;for(let r of e)t.has(r.name)&&n.add(r.name),t.set(r.name,r);return n.forEach(e=>t.delete(e)),t}function compatibleValue(e,r,a,o){if(e.kind===`LiteralExpressionSyntax`&&e.value===null)return r.isOptional;if(r.isCollection)return e.kind===`ListExpressionSyntax`&&e.items.every(e=>compatibleValue(e,{...r,isCollection:!1,isOptional:!1},a,o));let s=o.get(r.name);if(s!==void 0)return e.kind===`ObjectExpressionSyntax`&&e.members.every(e=>{let t=s.get(e.name);return t!==void 0&&compatibleValue(e.value,t.type,a,o)});let c=a.get(r.name),l=c?.type??r.name;if(c?.type===`Enum`)return e.kind===`LiteralExpressionSyntax`&&typeof e.value==`string`&&c.values.includes(e.value);if(e.kind===`LiteralExpressionSyntax`)switch(l){case`Uuid`:return typeof e.value==`string`&&uuidValue(e.value);case`String`:return typeof e.value==`string`;case`Bool`:return typeof e.value==`boolean`;case`Int`:return typeof e.value==`number`?Number.isFinite(e.value)&&Number.isInteger(e.value):typeof e.value==`object`&&e.value!==null&&t(e.value);case`Decimal`:return typeof e.value==`number`?Number.isFinite(e.value):typeof e.value==`object`&&e.value!==null&&e.value.literalType===`ExactNumber`;case`Date`:return typeof e.value==`string`&&n(e.value,!1);case`DateTime`:return typeof e.value==`string`&&n(e.value,!0);default:return!i.has(l)}return!i.has(l)&&c===void 0}const a=/^(?:[0-9a-f]{32}|[0-9a-f]{8}(?:-[0-9a-f]{4}){3}-[0-9a-f]{12}|\{[0-9a-f]{8}(?:-[0-9a-f]{4}){3}-[0-9a-f]{12}\}|\([0-9a-f]{8}(?:-[0-9a-f]{4}){3}-[0-9a-f]{12}\))(?![\s\S])/i;function uuidValue(e){return a.test(e)}export{compatibleValue,uniqueByName,validateResponses};
1
+ import"../../_virtual/_virtual/_rolldown/runtime.js";import{DiagnosticCodes as e}from"../Diagnostics/DiagnosticCodes.js";import{nativePattern as t}from"../Text/patterns.js";import{exactIsIntegral as n}from"../Syntax/ExactMathFacts.js";import{responseCommandResolver as r}from"./ResponseCommandResolver.js";import{responseDateValue as i}from"./ResponseDateValues.js";import{specificationCommandExamples as a}from"./SpecificationCommandExamples.js";const o=t(`^[A-Za-z_]\\w*$`),s=/* @__PURE__ */ new Set([`Uuid`,`String`,`Int`,`Decimal`,`Bool`,`Date`,`DateTime`]);function validateResponses(t,n,i=n.inputUses){let c=a(t),l=[],collect=(e,t)=>{let n=[...t,e.name];e.slices.forEach(e=>l.push({slice:e,scope:[...n,e.name]})),e.features.forEach(e=>collect(e,n))};t.modules.forEach(e=>e.features.forEach(t=>collect(t,[e.name])));let u=/* @__PURE__ */ new Map,d=/* @__PURE__ */ new Map,f=/* @__PURE__ */ new Map;for(let{slice:e,scope:t}of l)for(let n of e.commands){let e=u.get(n.name)??[];e.push({command:n,scope:t}),u.set(n.name,e),d.set(n,uniqueByName(n.properties)),n.response?.kind===`RecordCommandResponseSyntax`&&f.set(n,uniqueByName(n.response.fields))}let p=r([...u.values()].flat(),t.imports),m=uniqueByName(t.concepts),h=new Set(t.concepts.map(e=>e.name)),g=new Map([...uniqueByName(t.types)].map(([e,t])=>[e,uniqueByName(t.properties)])),_=new Set(l.flatMap(e=>e.slice.readModels.map(e=>e.name))),v=new Set([...d.keys()].flatMap(e=>[...e.properties])),checkDeclarations=t=>{for(let r of t)r.isGenerated&&!v.has(r)&&n.error(e.GeneratedPropertyOutsideCommand,`Generated properties can only be declared on commands.`,r.location)},checkFeature=e=>{e.features.forEach(checkFeature);for(let t of e.slices){for(let e of t.commands)for(let t of e.produces)t.inlineEvent!==null&&checkDeclarations(t.inlineEvent.properties);t.events.forEach(e=>checkDeclarations(e.properties)),t.readModels.forEach(e=>checkDeclarations(e.properties));for(let e of t.reactions)for(let t of e.triggers)for(let e of t.produces)e.inlineEvent!==null&&checkDeclarations(e.inlineEvent.properties)}};t.types.forEach(e=>checkDeclarations(e.properties)),t.modules.forEach(e=>e.features.forEach(checkFeature));let validateSource=(t,r,i)=>{let a=d.get(i).get(t.property);if(a===void 0){n.error(e.InvalidResponseSource,`Response source '${t.property}' must reference one direct command property.`,t.location);return}let o=a.type;(o.isCollection||_.has(o.name))&&n.error(e.InvalidResponseShape,`Collection and whole-read-model responses are not supported.`,t.location),r!==null&&(r.name!==o.name||r.isCollection!==o.isCollection||r.isOptional!==o.isOptional)&&n.error(e.InvalidResponseShape,`An explicit response field type must match its source's declared type, collection shape and optionality.`,r.location)};for(let t of d.keys()){for(let r of t.properties){if(!r.isGenerated)continue;let t=m.get(r.type.name);(r.type.isOptional||r.type.isCollection||(t===void 0?s.has(r.type.name)||g.has(r.type.name)||h.has(r.type.name)||_.has(r.type.name):t.type!==`Uuid`&&t.generation==null))&&n.error(e.InvalidGeneratedType,`A generated property must be a required, noncollection generatable concept.`,r.location)}let r=t.response;if(r?.kind===`ScalarCommandResponseSyntax`)validateSource(r.source,null,t);else if(r?.kind===`RecordCommandResponseSyntax`){r.fields.length===0&&n.error(e.InvalidCommandResponse,`A response block requires at least one field.`,r.location);let i=/* @__PURE__ */ new Set;for(let a of r.fields)i.has(a.name)&&n.error(e.DuplicateResponseField,`Duplicate response field '${a.name}'.`,a.location),i.add(a.name),validateSource(a.source,a.type,t)}}let validateSpecification=(t,r)=>{let i=c(t.when,r),a=i===null?null:p(i.commandType,r);if(i!==null&&a!==null){let t=d.get(a);for(let r of i.values)t.get(r.property.split(`.`)[0])?.isGenerated&&n.error(e.GeneratedPropertySuppliedAsInput,`Generated property '${r.property}' cannot be supplied as request or form input.`,r.location);let r=[...t.values()].filter(e=>e.isIdentifier);if(i.for!==null&&r.length===1&&r[0].isGenerated){let t=r[0].type;(s.has(t.name)||m.has(t.name)||g.has(t.name))&&(t.isOptional||t.isCollection||![`Uuid`,`String`].includes(m.get(t.name)?.type??``)||!compatibleValue(i.for,t,m,g))&&n.error(e.InvalidGeneratedFixture,`A generated identifier fixture must supply one compatible concrete UUID value through 'for'.`,i.for.location)}let o=/* @__PURE__ */ new Set;for(let r of i.generatedValues??[]){let i=t.get(r.property);(o.has(r.property)||i===void 0||!i.isGenerated||i.isIdentifier||!compatibleValue(r.source,i.type,m,g))&&n.error(e.InvalidGeneratedFixture,`A generated fixture must uniquely supply a compatible value for a nonidentifier generated command property.`,r.location),o.add(r.property)}}let o=t.thenReturns;if(o==null||((i===null||t.thenErrors.length>0||t.thenDenied!=null)&&n.error(e.InvalidReturnExpectation,`A return expectation requires a command action and cannot accompany an error or denial.`,o.location),a===null))return;let l=a.response,u=d.get(a);if(o.kind===`ScalarSpecificationReturnSyntax`&&l?.kind===`ScalarCommandResponseSyntax`&&u.has(l.source.property))compatibleValue(o.value,u.get(l.source.property).type,m,g)||n.error(e.InvalidReturnExpectation,`The expected return value must match the response source's type.`,o.location);else if(o.kind===`RecordSpecificationReturnSyntax`&&l?.kind===`RecordCommandResponseSyntax`){o.fields.length===0&&n.error(e.InvalidReturnExpectation,`A record return expectation requires at least one field.`,o.location);let t=f.get(a),r=/* @__PURE__ */ new Set;for(let i of o.fields){let a=t.get(i.property),o=a===void 0?void 0:u.get(a.source.property);(r.has(i.property)||o===void 0||!compatibleValue(i.source,o.type,m,g))&&n.error(e.InvalidReturnExpectation,`A return assertion must uniquely name a response field and supply a compatible concrete value.`,i.location),r.add(i.property)}}else n.error(e.InvalidReturnExpectation,`The return expectation must match the command's scalar or record response shape.`,o.location)};for(let{slice:e,scope:t}of l)e.specifications.forEach(e=>validateSpecification(e,t));let returned=(e,t)=>e.response?.kind===`ScalarCommandResponseSyntax`?e.response.source.property===t:f.get(e)?.has(t)===!0;for(let t of n.continuationValues){if(!o.test(t.text)||t.locals.includes(t.text))continue;let scopedCommands=e=>e.filter(e=>!t.parameters.includes(e)).flatMap(e=>{let n=p(e,t.scope);return n===null?[]:[n]});if(scopedCommands(t.success).some(e=>returned(e,t.text)))continue;let r=scopedCommands(t.failure).reverse().find(e=>returned(e,t.text));r&&n.error(e.ResponseNameUsedOnFailure,`'${t.text}' is returned by '${r.name}' only on success`,t.location)}for(let t of i){if(t.isParameter===!0)continue;let r=p(t.command,t.scope);r!==null&&d.get(r).get(t.property.split(`.`)[0])?.isGenerated&&n.error(e.GeneratedPropertySuppliedAsInput,`Generated property '${t.property}' cannot be supplied as request or form input.`,t.location)}}function uniqueByName(e){let t=/* @__PURE__ */ new Map,n=/* @__PURE__ */ new Set;for(let r of e)t.has(r.name)&&n.add(r.name),t.set(r.name,r);return n.forEach(e=>t.delete(e)),t}function compatibleValue(e,t,r,a){if(e.kind===`LiteralExpressionSyntax`&&e.value===null)return t.isOptional;if(t.isCollection)return e.kind===`ListExpressionSyntax`&&e.items.every(e=>compatibleValue(e,{...t,isCollection:!1,isOptional:!1},r,a));let o=a.get(t.name);if(o!==void 0)return e.kind===`ObjectExpressionSyntax`&&e.members.every(e=>{let t=o.get(e.name);return t!==void 0&&compatibleValue(e.value,t.type,r,a)});let c=r.get(t.name),l=c?.type??t.name;if(c?.type===`Enum`)return e.kind===`LiteralExpressionSyntax`&&typeof e.value==`string`&&c.values.includes(e.value);if(e.kind===`LiteralExpressionSyntax`)switch(l){case`Uuid`:return typeof e.value==`string`&&uuidValue(e.value);case`String`:return typeof e.value==`string`;case`Bool`:return typeof e.value==`boolean`;case`Int`:return typeof e.value==`number`?Number.isFinite(e.value)&&Number.isInteger(e.value):typeof e.value==`object`&&e.value!==null&&n(e.value);case`Decimal`:return typeof e.value==`number`?Number.isFinite(e.value):typeof e.value==`object`&&e.value!==null&&e.value.literalType===`ExactNumber`;case`Date`:return typeof e.value==`string`&&i(e.value,!1);case`DateTime`:return typeof e.value==`string`&&i(e.value,!0);default:return!s.has(l)}return!s.has(l)&&c===void 0}const c=/^(?:[0-9a-f]{32}|[0-9a-f]{8}(?:-[0-9a-f]{4}){3}-[0-9a-f]{12}|\{[0-9a-f]{8}(?:-[0-9a-f]{4}){3}-[0-9a-f]{12}\}|\([0-9a-f]{8}(?:-[0-9a-f]{4}){3}-[0-9a-f]{12}\))(?![\s\S])/i;function uuidValue(e){return c.test(e)}export{compatibleValue,uniqueByName,validateResponses};
2
2
  //# sourceMappingURL=ResponseValidator.js.map