@cratis/screenplay-language 4.136.0 → 4.137.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bundles/compiler/Diagnostics/DiagnosticCodes.js +1 -1
- package/dist/bundles/compiler/Diagnostics/DiagnosticCodes.js.map +1 -1
- package/dist/bundles/compiler/Parsing/EnumerationMembers.js +2 -0
- package/dist/bundles/compiler/Parsing/EnumerationMembers.js.map +1 -0
- package/dist/bundles/compiler/Parsing/ScreenplayParser.js +1 -1
- package/dist/bundles/compiler/Parsing/ScreenplayParser.js.map +1 -1
- package/dist/bundles/compiler/Syntax/SyntaxCollections.js +1 -1
- package/dist/bundles/compiler/Syntax/SyntaxCollections.js.map +1 -1
- package/dist/bundles/compiler/Syntax/SyntaxInvariants.js +1 -1
- package/dist/bundles/compiler/Syntax/SyntaxInvariants.js.map +1 -1
- package/dist/bundles/compiler/Syntax/SyntaxJson.js +1 -1
- package/dist/bundles/compiler/Syntax/SyntaxJson.js.map +1 -1
- package/dist/bundles/completion-items.js +1 -1
- package/dist/bundles/completion-items.js.map +1 -1
- package/dist/bundles/completion-planner.js +1 -1
- package/dist/bundles/completion-planner.js.map +1 -1
- package/dist/bundles/diagnostic-codes.js +1 -1
- package/dist/bundles/diagnostic-codes.js.map +1 -1
- package/dist/bundles/hover-content.js +1 -1
- package/dist/bundles/hover-content.js.map +1 -1
- package/dist/bundles/keyword-docs.js +1 -1
- package/dist/bundles/keyword-docs.js.map +1 -1
- package/dist/bundles/symbols.js +2 -2
- package/dist/bundles/symbols.js.map +1 -1
- package/dist/bundles/tokens.js +1 -1
- package/dist/bundles/tokens.js.map +1 -1
- package/dist/bundles/validation.js +1 -1
- package/dist/bundles/validation.js.map +1 -1
- package/dist/diagnostic-codes.d.ts +5 -0
- package/dist/diagnostic-codes.d.ts.map +1 -1
- package/dist/symbols.d.ts +1 -0
- package/dist/symbols.d.ts.map +1 -1
- package/dist/tokens.d.ts.map +1 -1
- package/dist/validation.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"completion-planner.js","names":["items.moduleItems","items.featureItems","items.sliceItemsFor","items.conceptItems","items.typeItems","items.commandItems","items.eventItems","scope.readModelItems","scope.reducerItems","scope.formItems","scope.contributeItems","scope.behaviorItems","scope.personaItems","items.identityItems","scope.authenticationItems","scope.seedItems","scope.themeItems","scope.uiProfileItems","scope.outcomeItems","scope.layoutItems","items.operationItems","items.operationPhaseItems","items.producesItems","items.handlerItems","items.implementationItems","items.operationImplementationItems","items.queryItems","items.performerItems","items.constraintItems","items.reactionItems","items.invocationItems","items.triggerItems","items.reactionTriggerItems","items.specificationItems","items.policyItems","items.validateItems","items.actionItems","items.tableItems","scope.templateItems","items.screenItems","items.guardedActionItems","items.actionArgumentItems","items.interactionChoiceItems","items.interactionActionItems","items.refusalItems","items.namedRuleImplementationItems","items.commandRuleItems","items.optionalTypeItems","items.specificationStepItems","items.inlineEventItems","items.ruleItems","productionRouteItem","RULE_LINE_PATTERN","document","keyword","line","topLevelItems","item","header","relative","text","index","indent","indentOf","construct","chain","where","subLanguage","getSubLanguage","purposeItems","moduleScopeItems","featureScopeItems","sliceItemsFor","conceptItems","typeItems","commandItems","eventItems","readModelItems","reducerItems","formItems","contributeItems","behaviorItems","personaItems","identityItems","authenticationItems","seedItems","themeItems","uiProfileItems","outcomeItems","layoutItems","operationItems","operationPhaseItems","producesItems","handlerItems","implementationItems","operationImplementationItems","queryItems","performerItems","constraintItems","reactionItems","invocationItems","triggerItems","reactionTriggerItems","specificationItems","policyItems","validateItems","actionItems","tableItems","templateItems","screenItems","candidate","scanDocument","lines","fences","fenceMap","lineIndex","withoutComment","textBefore","marker","inConcept","enclosingChain","scope","category","responseEntries","exampleCompletions","responseCompletions","keyEntries","readModelKeyCompletions","symbols","dependencyEntries","dependencyTargetCompletions","importPath","refusal","refusalContext","member","contextVariableMatch","currentLine","effectiveIndent","parentIndent","guarded","parent","guardedActionItems","nearestEnclosingLine","actionArgumentItems","interactionChoiceItems","interactionActionItems","refusalItems","ruleContext","namedRuleContext","namedRuleImplementationItems","commandRuleItems","propertyOwner","propertyName","reservedProperty","match","afterPropertyType","afterQueryType","subjectModifier","subjectConcept","concept","subjectType","subjectTarget","attribute","afterSubjectType","keyModifier","modifierEntries","optionalTypeItems","step","specificationStepItems","enclosingLine","inlineEventItems","ruleItems","headers","enclosingHeaders","entries","expansion","structureCompletion"],"sources":["../../completion-planner.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 { enclosingChain, enclosingHeaders, fenceMap, indentOf, nearestEnclosingLine, withoutComment } from './document-context';\nimport { refusalContext } from './refusal-context';\nimport { namedRuleContext } from './named-rule-context';\nimport { responseCompletions } from './response-completions';\nimport { dependencyTargetCompletions } from './dependency-completions';\nimport { exampleCompletions } from './example-authoring';\nimport { DocumentSymbols, scanDocument } from './symbols';\nimport { structureCompletion } from './structure-completions';\nimport { getSubLanguage } from './sub-language-registry';\nimport * as items from './completion-items';\nimport * as scope from './scope-items';\nimport { CompletionEntry } from './completion-items';\nimport { purposeItems } from './purpose-items';\nimport { readModelKeyCompletions } from './read-model-key-completions';\n\n// Matches a validation rule line ending in \"rule <Name>\" (optionally followed by a\n// message clause) - both the command form (\"<property> rule <Name>\") and the\n// concept implied-subject form (\"rule <Name>\"). Its first word is the property\n// name, not \"rule\", so it can't be recognized through the chain[0] keyword switch\n// the way \"on <EventType>\" or \"handler\" are - hence the dedicated regex check.\nconst productionRouteItem = { label: 'stream', insertText: 'stream ${1:Source.Stream}', documentation: 'Replace the whole command route for this event production. ESM v10.' };\n\nconst RULE_LINE_PATTERN = /(?:^|\\s)rule\\s+[A-Za-z_]\\w*(?:\\s+severity\\s+(?:information|warning|error))?(?:\\s+message\\s+.*)?$/;\n\nexport type CompletionPlan =\n | { kind: 'none' }\n | { kind: 'entries'; entries: CompletionEntry[] }\n | { kind: 'contextVariables'; replaceLength: number }\n | { kind: 'playFiles'; replaceLength: number }\n | { kind: 'policies' }\n | { kind: 'events' }\n | { kind: 'triggers' }\n | { kind: 'commands' }\n | { kind: 'producesTargets' }\n | { kind: 'screens' }\n | { kind: 'queries' }\n | { kind: 'types' };\n\n// What the position sits inside, beyond the keyword chain: the whole header of each enclosing block, so a\n// slice's type and a template's kind are known, and the document's own lines, so a declaration that may\n// appear once is not offered again.\nexport interface CompletionScope {\n headers: readonly string[];\n document: readonly string[];\n}\n\nconst declaredIn = (document: readonly string[], keyword: string) => document.some(line => new RegExp(`^${keyword}\\\\b`).test(line));\n\nfunction topLevelEntries(document: readonly string[]): CompletionEntry[] {\n return items.topLevelItems.filter(item => !(item.label === 'domain' && declaredIn(document, 'domain')) && !(item.label === 'authentication' && declaredIn(document, 'authentication')) && !(item.label === 'identity' && declaredIn(document, 'identity')));\n}\n\nconst isTemplate = (header: string | undefined) => /^(?:screen|dialog)\\s+template\\b/.test(header ?? '');\n\n// A whole block as one completion entry. Continuation lines are indented relative to the line it is inserted on,\n// which is how the editors indent a multi-line snippet.\nfunction expansionEntry(text: string, indent: number): CompletionEntry {\n const relative = text.split('\\n').map((line, index) => (index === 0 ? line : line.slice(Math.min(indent, indentOf(line))))).join('\\n');\n const label = text.split('\\n')[0].trim();\n return { label, insertText: relative.replace(/[$}\\\\]/g, '\\\\$&'), documentation: 'Expands the whole block from what the command and its events declare.' };\n}\n\nexport function completionEntriesFor(chain: string[], where: CompletionScope = { headers: [], document: [] }): CompletionEntry[] {\n const construct = chain[0];\n if (construct === undefined || construct === 'domain') return topLevelEntries(where.document);\n const subLanguage = getSubLanguage(construct);\n if (subLanguage) return subLanguage.completions ?? [];\n const header = where.headers[0];\n switch (construct) {\n case 'purpose':\n return purposeItems;\n case 'module':\n return items.moduleItems;\n case 'feature':\n return items.featureItems;\n case 'slice':\n return items.sliceItemsFor(header?.split(/\\s+/)[1]);\n case 'concept':\n return items.conceptItems;\n case 'type':\n return items.typeItems;\n case 'command':\n return items.commandItems;\n case 'public':\n case 'event':\n return items.eventItems;\n case 'readmodel':\n return scope.readModelItems;\n case 'reducer':\n return scope.reducerItems;\n case 'form':\n return scope.formItems;\n case 'contribute':\n return scope.contributeItems;\n case 'behavior':\n return scope.behaviorItems;\n case 'persona':\n return scope.personaItems;\n case 'identity':\n return items.identityItems;\n case 'authentication':\n return scope.authenticationItems;\n case 'seed':\n return scope.seedItems;\n case 'theme':\n return scope.themeItems;\n case 'ui':\n return scope.uiProfileItems;\n case 'on':\n case 'success':\n case 'failure':\n case 'confirm':\n return scope.outcomeItems;\n case 'layout':\n return scope.layoutItems;\n case 'system':\n return items.operationItems.filter(item => item.label === 'description');\n case 'operation':\n return items.operationItems;\n case 'execute':\n case 'compensate':\n return items.operationPhaseItems;\n case 'produces':\n return chain.includes('command') ? [...items.producesItems, productionRouteItem] : items.producesItems;\n case 'handler':\n return items.handlerItems;\n case 'implementation':\n return chain[1] === 'handler' ? items.implementationItems : ['execute', 'compensate'].includes(chain[1]) ? items.operationImplementationItems : [];\n case 'reads':\n return [{ label: 'by parts', insertText: 'by\\n ${1:part} = ${2:source}\\n ${3:part} = ${4:source}', documentation: 'Supply every composite read-model key part by name.' }];\n case 'query':\n return items.queryItems;\n case 'performer':\n return items.performerItems;\n case 'constraint':\n return items.constraintItems;\n case 'reaction':\n return items.reactionItems;\n case 'invokes':\n return chain.includes('reaction') ? items.invocationItems : [];\n case 'trigger':\n return items.triggerItems;\n case 'when':\n case 'every':\n case 'at':\n return chain.includes('reaction') ? items.reactionTriggerItems : [];\n case 'specification':\n return items.specificationItems;\n case 'policy':\n return items.policyItems;\n case 'validate':\n return items.validateItems;\n case 'action':\n return items.actionItems;\n case 'table':\n case 'summary':\n return items.tableItems;\n case 'screen':\n return isTemplate(header) ? scope.templateItems : items.screenItems;\n case 'dialog':\n return scope.templateItems;\n default:\n if (isTemplate(where.headers.find(candidate => isTemplate(candidate)))) return scope.templateItems;\n // Sections inside a screen expose the screen vocabulary.\n if (chain.includes('screen') || construct === 'section') return items.screenItems;\n if (chain.includes('produces')) return chain.includes('command') ? [...items.producesItems, productionRouteItem] : items.producesItems;\n return [];\n }\n}\n\n// Decides what to complete at a position, without any editor dependency — the\n// Monaco service and the VSCode extension both materialize the plan into items.\nexport function planCompletions(\n lines: string[],\n lineIndex: number,\n textBefore: string,\n symbols: DocumentSymbols = scanDocument(lines),\n): CompletionPlan {\n const fences = fenceMap(lines);\n if (fences[lineIndex] || withoutComment(textBefore).length < textBefore.length) return { kind: 'none' };\n if (/^\\s*concept\\s+[\\p{L}\\p{Mn}\\p{Nd}\\p{Pc}]+\\s*:\\s*\\w+\\s+(?:(?:pii|personal|secret)\\s+)*\\w*$/u.test(textBefore)) {\n return { kind: 'entries', entries: ['pii', 'secret'].filter(marker => !new RegExp(`\\\\b${marker}\\\\b`).test(textBefore)).map(marker => ({ label: marker, insertText: marker, documentation: marker === 'pii' ? 'personal data (GDPR Art. 4(1)); renders Chronicle [PII]' : 'Operational secret; renders [Encrypted] + [NotAudited].' })) };\n }\n const inConcept = enclosingChain(lines, fences, lineIndex, indentOf(textBefore))[0] === 'concept';\n if (inConcept && /^\\s*(?:secret|sensitive|@sensitive)\\s+scope\\s+\\w*$/.test(textBefore)) {\n return { kind: 'entries', entries: ['subject', 'namespace', 'global'].map(scope => ({ label: scope, insertText: scope, documentation: 'Explicit secret encryption scope.' })) };\n }\n if (inConcept && /^\\s*(?:pii|personal|@pii)\\s+special\\s+\\w*$/.test(textBefore)) {\n return { kind: 'entries', entries: ['racialOrEthnicOrigin', 'politicalOpinions', 'religiousOrPhilosophicalBeliefs', 'tradeUnionMembership', 'genetic', 'biometric', 'health', 'sexLifeOrSexualOrientation'].map(category => ({ label: category, insertText: category, documentation: 'GDPR Art. 9(1) special category.' })) };\n }\n const responseEntries = exampleCompletions(lines, lineIndex, textBefore) ?? responseCompletions(lines, lineIndex, textBefore, scanDocument(lines));\n if (responseEntries !== null) return { kind: 'entries', entries: responseEntries };\n const keyEntries = readModelKeyCompletions(lines, lineIndex, textBefore, symbols);\n if (keyEntries !== null) return { kind: 'entries', entries: keyEntries };\n const dependencyEntries = dependencyTargetCompletions(lines, lineIndex, textBefore, symbols);\n if (dependencyEntries !== null) return { kind: 'entries', entries: dependencyEntries };\n\n // Inside the quotes of a file import, what is wanted is a path - replacing what has been typed so far.\n const importPath = textBefore.match(/^\\s*import\\s+\"([^\"]*)$/);\n if (importPath) {\n return { kind: 'playFiles', replaceLength: importPath[1].length };\n }\n\n // A quote or a slash only asks for a completion inside an import path.\n if (/[\"/]$/.test(textBefore)) return { kind: 'none' };\n\n const refusal = refusalContext(lines, lineIndex, indentOf(lines[lineIndex] ?? textBefore));\n if (/\\$refusal\\.\\w*$/.test(textBefore)) {\n return { kind: 'entries', entries: refusal === undefined ? [] : ['reason', 'message', ...(/^on\\s+refused\\s+by\\s+constraint(?:\\s|$)/.test(refusal) ? ['constraint'] : [])].map(member => ({ label: member, insertText: member, documentation: 'String refusal value; syntax-only, not yet executable (PLAY0268).' })) };\n }\n const contextVariableMatch = textBefore.match(/\\$[\\w.]*$/);\n if (contextVariableMatch) {\n return { kind: 'contextVariables', replaceLength: contextVariableMatch[0].length };\n }\n\n const currentLine = lines[lineIndex] ?? '';\n const effectiveIndent =\n textBefore.trim().length === 0 ? textBefore.length : indentOf(currentLine);\n const chain = enclosingChain(lines, fences, lineIndex, effectiveIndent);\n if (chain.includes('screen')) {\n let parentIndent = effectiveIndent;\n let guarded = false;\n for (let index = lineIndex - 1; index >= 0; index--) {\n if (fences[index]) continue;\n const parent = withoutComment(lines[index]);\n if (parent.trim().length === 0 || indentOf(parent) >= parentIndent) continue;\n parentIndent = indentOf(parent);\n if (/^\\s*action\\s+(?:\"|\\$strings\\.)/.test(parent)) { guarded = true; break; }\n if (/^\\s*screen\\b/.test(parent)) break;\n }\n if (guarded) {\n if (/^\\s*(?:when\\b.*|otherwise)\\s+execute\\s+[\\w.]*$/.test(textBefore)) return { kind: 'commands' };\n if (chain[0] === 'action') return { kind: 'entries', entries: items.guardedActionItems };\n if (['when', 'otherwise'].includes(chain[0])) {\n const parent = nearestEnclosingLine(lines, fences, lineIndex, effectiveIndent) ?? '';\n return { kind: 'entries', entries: /\\bexecute\\s+[\\w.]+$/.test(parent) ? items.actionArgumentItems : [] };\n }\n }\n }\n if (['on', 'when', 'otherwise'].includes(chain[0])) {\n let parentIndent = effectiveIndent;\n for (let index = lineIndex - 1; index >= 0; index--) {\n if (fences[index]) continue;\n const parent = withoutComment(lines[index]);\n if (parent.trim().length === 0 || indentOf(parent) >= parentIndent) continue;\n parentIndent = indentOf(parent);\n if (/^\\s*on\\s+(?:click|double click|select)\\s*$/.test(parent)) {\n return { kind: 'entries', entries: chain[0] === 'on' ? items.interactionChoiceItems : items.interactionActionItems };\n }\n if (/^\\s*(?:screen|behavior|specification|reaction)\\b/.test(parent)) break;\n }\n }\n if (chain[0] === 'on' && refusal !== undefined) return { kind: 'entries', entries: items.refusalItems };\n const ruleContext = namedRuleContext(lines, lineIndex, effectiveIndent);\n if (ruleContext === 'implementation') return { kind: 'entries', entries: items.namedRuleImplementationItems };\n if (ruleContext === 'rule') return { kind: 'entries', entries: items.commandRuleItems };\n\n const propertyOwner = ['public', 'event', 'command', 'type', 'readmodel', 'trigger', 'when', 'every', 'at'].includes(chain[0]) ||\n (chain[0] === 'produces' && /^produces\\s+event\\b/.test(nearestEnclosingLine(lines, fences, lineIndex, effectiveIndent) ?? ''));\n const propertyName = textBefore.trimStart().split(/\\s+/)[0];\n const reservedProperty = (chain[0] === 'command' && ['reads', 'authorize', 'produces'].includes(propertyName)) ||\n (chain[0] === 'event' && propertyName === 'tag') ||\n (['trigger', 'when', 'every', 'at'].includes(chain[0]) && ['description', 'file', 'reads', 'produces', 'invokes'].includes(propertyName));\n const optionalPrefix = (match: RegExpMatchArray | null) => match !== null && 'optional'.startsWith(match[1]);\n const afterPropertyType = propertyOwner && !reservedProperty && optionalPrefix(textBefore.match(/^\\s*@?[a-z_]\\w*\\s+[\\w.]+(?:\\[\\])?\\s+(\\w*)$/));\n const afterQueryType = (chain[0] === 'query' && optionalPrefix(textBefore.match(/^\\s*(?:by|filter)\\s+[a-z_]\\w*\\s+[\\w.]+(?:\\[\\])?\\s+(\\w*)$/))) ||\n optionalPrefix(textBefore.match(/^\\s*query\\s+[A-Za-z_]\\w*\\s*=>\\s*(?:observable\\s+)?[\\w.]+(?:\\[\\])?\\s+(\\w*)$/));\n const eventPropertyOwner = chain[0] === 'event' || (chain[0] === 'produces' && /^produces\\s+event\\b/.test(nearestEnclosingLine(lines, fences, lineIndex, effectiveIndent) ?? ''));\n const subjectModifier = eventPropertyOwner && !reservedProperty ? textBefore.match(/^\\s*@?[a-z_]\\w*\\s+([\\w.]+)\\s+(\\w*)$/) : null;\n const subjectConcept = symbols.concepts.find(concept => concept.name === subjectModifier?.[1]);\n const subjectType = subjectConcept?.primitive ?? subjectModifier?.[1];\n const subjectTarget = (subjectType === 'String' || subjectType === 'Uuid' || (subjectType === 'Int' && subjectConcept !== undefined)) &&\n !subjectConcept?.attributes.some(attribute => ['pii', 'personal', 'secret', 'sensitive'].includes(attribute.replace(/^@/, '')));\n const afterSubjectType = subjectModifier !== null && subjectTarget && 'subject'.startsWith(subjectModifier[2]);\n const keyModifier = chain[0] === 'readmodel' ? textBefore.match(/^\\s*@?[a-z_]\\w*\\s+[\\w.]+\\s+(\\w*)$/) : null;\n const modifierEntries = [\n ...(keyModifier && 'key'.startsWith(keyModifier[1]) ? [{ label: 'key', insertText: 'key', documentation: 'Declares a required read-model key part. Explicit keys replace inference. Composite keys are authoring-only (#599).' }] : []),\n ...((afterPropertyType || afterQueryType) && !/=>\\s*observable\\s+$/.test(textBefore) ? items.optionalTypeItems : []),\n ...(afterSubjectType ? [{ label: 'subject', insertText: 'subject', documentation: 'One required scalar event data-subject identity; not pii or secret. Report-only lineage metadata (PLAY0270), no ESM or provider output yet.' }] : []),\n ];\n if (modifierEntries.length > 0) return { kind: 'entries', entries: modifierEntries };\n\n if (/\\bauthorize\\s+[\\w\\s]*$/.test(textBefore) || chain[0] === 'authorize') {\n return { kind: 'policies' };\n }\n if (/\\bwhen\\s+\\w*$/.test(textBefore) && chain.includes('reaction')) {\n return { kind: 'triggers' };\n }\n if (/\\bon\\s+\\w*$/.test(textBefore) && chain.includes('constraint')) {\n return { kind: 'events' };\n }\n if (/\\binvokes\\s+\\w*$/.test(textBefore) && chain.includes('reaction')) {\n return { kind: 'commands' };\n }\n if (/\\b(?:on|unique\\s+event)\\s+\\w*$/.test(textBefore) && chain[0] === 'constraint') {\n return { kind: 'events' };\n }\n if (/\\bproduces\\s+\\w*$/.test(textBefore)) {\n return { kind: 'producesTargets' };\n }\n if (/\\bnavigate\\s+to\\s+\\w*$/.test(textBefore)) {\n return { kind: 'screens' };\n }\n if (chain[0] === 'specification') {\n if (/^\\s*when\\s+query\\s+[\\w.]*$/.test(textBefore)) return { kind: 'queries' };\n const step = textBefore.match(/^\\s*(given|when|then)\\s+\\w*$/);\n if (step) return { kind: 'entries', entries: items.specificationStepItems[step[1] as 'given' | 'when' | 'then'] };\n }\n if (/\\b(?:via|then)\\s+query\\s+[\\w.]*$/.test(textBefore)) {\n return { kind: 'queries' };\n }\n if (\n (chain[0] === 'event' || chain[0] === 'command' || chain[0] === 'type') &&\n /^\\s+[a-z_]\\w*\\s+[\\w[\\]?]*$/.test(textBefore)\n ) {\n return { kind: 'types' };\n }\n if (chain[0] === 'query' && /^\\s+(?:by|filter)\\s+[a-z_]\\w*\\s+[\\w[\\]?]*$/.test(textBefore)) {\n return { kind: 'types' };\n }\n\n const enclosingLine = nearestEnclosingLine(lines, fences, lineIndex, effectiveIndent);\n if (enclosingLine && /^produces\\s+operation\\b/.test(enclosingLine)) return { kind: 'entries', entries: items.operationItems };\n if (enclosingLine && /^produces\\s+event\\b/.test(enclosingLine)) {\n if (/^\\s+@?[a-z_]\\w*\\s+[\\w[\\]?]*$/.test(textBefore)) return { kind: 'types' };\n return { kind: 'entries', entries: chain.includes('command') ? [...items.inlineEventItems, productionRouteItem] : items.inlineEventItems };\n }\n if (enclosingLine && RULE_LINE_PATTERN.test(enclosingLine)) {\n return { kind: 'entries', entries: items.ruleItems };\n }\n\n const headers = enclosingHeaders(lines, fences, lineIndex, effectiveIndent);\n if (chain[0] === 'for' && chain.includes('seed')) return { kind: 'events' };\n const entries = completionEntriesFor(chain, { headers, document: lines });\n const expansion = chain[0] === 'command' ? structureCompletion(lines, lineIndex, ' '.repeat(effectiveIndent), '', symbols) : null;\n return { kind: 'entries', entries: expansion ? [expansionEntry(expansion.text, effectiveIndent), ...entries] : entries };\n}\n"],"mappings":"i6DAuBA,MAAMmD,EAAsB,CAAE,MAAO,SAAU,WAAY,4BAA6B,cAAe,qEAAsE,EAEvKC,GAAoB,mGAwBpB,YAAc,EAA6B,IAAoBC,EAAS,KAAK,GAAY,OAAO,IAAIC,EAAQ,IAAI,CAAC,CAAC,KAAKC,CAAI,CAAC,EAElI,SAAS,gBAAgB,EAAgD,CACrE,OAAAC,GAA2B,OAAO,GAAQ,EAAEC,EAAK,QAAU,UAAY,WAAWJ,EAAU,QAAQ,IAAM,EAAEI,EAAK,QAAU,kBAAoB,WAAWJ,EAAU,gBAAgB,IAAM,EAAEI,EAAK,QAAU,YAAc,WAAWJ,EAAU,UAAU,EAAE,CAC9P,CAEA,MAAM,WAAc,GAA+B,kCAAkC,KAAKK,GAAU,EAAE,EAItG,SAAS,eAAe,EAAc,EAAiC,CACnE,IAAMC,EAAWC,EAAK,MAAM;CAAI,CAAC,CAAC,KAAK,EAAM,IAAWC,IAAU,EAAIN,EAAOA,EAAK,MAAM,KAAK,IAAIO,EAAQC,EAASR,CAAI,CAAC,CAAC,CAAE,CAAC,CAAC,KAAK;CAAI,EAErI,MAAO,CAAE,MADKK,EAAK,MAAM;CAAI,CAAC,CAAC,EAAE,CAAC,KACrB,EAAG,WAAYD,EAAS,QAAQ,UAAW,MAAM,EAAG,cAAe,uEAAwE,CAC5J,CAEA,SAA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SAAW,6CAA6C,KAAKoD,CAAU,EACpF,MAAO,CAAE,KAAM,OAAQ,EAG3B,IAAMoD,EAAgB3B,EAAqB9B,EAAOC,EAAQE,EAAWsB,CAAe,EACpF,GAAIgC,GAAiB,0BAA0B,KAAKA,CAAa,EAAG,MAAO,CAAE,KAAM,UAAW,QAASrJ,CAAqB,EAC5H,GAAIqJ,GAAiB,sBAAsB,KAAKA,CAAa,EAEzD,MADI,+BAA+B,KAAKpD,CAAU,EAAU,CAAE,KAAM,OAAQ,EACrE,CAAE,KAAM,UAAW,QAASpD,EAAM,SAAS,SAAS,EAAI,CAAC,GAAGhB,EAAwBE,CAAmB,EAAIF,CAAuB,EAE7I,GAAIwH,GAAiBrH,GAAkB,KAAKqH,CAAa,EACrD,MAAO,CAAE,KAAM,UAAW,QAASvH,CAAgB,EAGvD,IAAM0H,EAAUC,EAAiB7D,EAAOC,EAAQE,EAAWsB,CAAe,EAC1E,GAAIxE,EAAM,KAAO,OAASA,EAAM,SAAS,MAAM,EAAG,MAAO,CAAE,KAAM,QAAS,EAC1E,IAAM6G,EAAU,qBAAqB7G,EAAO,CAAE,UAAS,SAAU+C,CAAM,CAAC,EAClE+D,EAAY9G,EAAM,KAAO,UAAY+G,GAAoBhE,EAAOG,EAAW,IAAI,OAAOsB,CAAe,EAAG,GAAIT,CAAO,EAAI,KAC7H,MAAO,CAAE,KAAM,UAAW,QAAS+C,EAAY,CAAC,eAAeA,EAAU,KAAMtC,CAAe,EAAG,GAAGqC,CAAO,EAAIA,CAAQ,CAC3H"}
|
|
1
|
+
{"version":3,"file":"completion-planner.js","names":["items.moduleItems","items.featureItems","items.sliceItemsFor","items.conceptItems","items.typeItems","items.commandItems","items.eventItems","scope.readModelItems","scope.reducerItems","scope.formItems","scope.contributeItems","scope.behaviorItems","scope.personaItems","items.identityItems","scope.authenticationItems","scope.seedItems","scope.themeItems","scope.uiProfileItems","scope.outcomeItems","scope.layoutItems","items.operationItems","items.operationPhaseItems","items.producesItems","items.handlerItems","items.implementationItems","items.operationImplementationItems","items.queryItems","items.performerItems","items.constraintItems","items.reactionItems","items.invocationItems","items.triggerItems","items.reactionTriggerItems","items.specificationItems","items.policyItems","items.validateItems","items.actionItems","items.tableItems","scope.templateItems","items.screenItems","items.guardedActionItems","items.actionArgumentItems","items.interactionChoiceItems","items.interactionActionItems","items.refusalItems","items.namedRuleImplementationItems","items.commandRuleItems","items.optionalTypeItems","items.specificationStepItems","items.inlineEventItems","items.ruleItems","productionRouteItem","RULE_LINE_PATTERN","document","keyword","line","topLevelItems","item","header","relative","text","index","indent","indentOf","construct","chain","where","subLanguage","getSubLanguage","purposeItems","moduleScopeItems","featureScopeItems","sliceItemsFor","conceptItems","typeItems","commandItems","eventItems","readModelItems","reducerItems","formItems","contributeItems","behaviorItems","personaItems","identityItems","authenticationItems","seedItems","themeItems","uiProfileItems","outcomeItems","layoutItems","operationItems","operationPhaseItems","producesItems","handlerItems","implementationItems","operationImplementationItems","queryItems","performerItems","constraintItems","reactionItems","invocationItems","triggerItems","reactionTriggerItems","specificationItems","policyItems","validateItems","actionItems","tableItems","templateItems","screenItems","candidate","scanDocument","lines","fences","fenceMap","lineIndex","withoutComment","textBefore","marker","inConcept","enclosingChain","scope","category","responseEntries","exampleCompletions","responseCompletions","keyEntries","readModelKeyCompletions","symbols","dependencyEntries","dependencyTargetCompletions","importPath","refusal","refusalContext","member","contextVariableMatch","currentLine","effectiveIndent","parentIndent","guarded","parent","guardedActionItems","nearestEnclosingLine","actionArgumentItems","interactionChoiceItems","interactionActionItems","refusalItems","ruleContext","namedRuleContext","namedRuleImplementationItems","commandRuleItems","propertyOwner","propertyName","reservedProperty","match","afterPropertyType","afterQueryType","subjectModifier","subjectConcept","concept","subjectType","subjectTarget","attribute","afterSubjectType","keyModifier","modifierEntries","optionalTypeItems","step","specificationStepItems","enclosingLine","inlineEventItems","ruleItems","headers","enclosingHeaders","entries","expansion","structureCompletion"],"sources":["../../completion-planner.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 { enclosingChain, enclosingHeaders, fenceMap, indentOf, nearestEnclosingLine, withoutComment } from './document-context';\nimport { refusalContext } from './refusal-context';\nimport { namedRuleContext } from './named-rule-context';\nimport { responseCompletions } from './response-completions';\nimport { dependencyTargetCompletions } from './dependency-completions';\nimport { exampleCompletions } from './example-authoring';\nimport { DocumentSymbols, scanDocument } from './symbols';\nimport { structureCompletion } from './structure-completions';\nimport { getSubLanguage } from './sub-language-registry';\nimport * as items from './completion-items';\nimport * as scope from './scope-items';\nimport { CompletionEntry } from './completion-items';\nimport { purposeItems } from './purpose-items';\nimport { readModelKeyCompletions } from './read-model-key-completions';\n\n// Matches a validation rule line ending in \"rule <Name>\" (optionally followed by a\n// message clause) - both the command form (\"<property> rule <Name>\") and the\n// concept implied-subject form (\"rule <Name>\"). Its first word is the property\n// name, not \"rule\", so it can't be recognized through the chain[0] keyword switch\n// the way \"on <EventType>\" or \"handler\" are - hence the dedicated regex check.\nconst productionRouteItem = { label: 'stream', insertText: 'stream ${1:Source.Stream}', documentation: 'Replace the whole command route for this event production. ESM v10.' };\n\nconst RULE_LINE_PATTERN = /(?:^|\\s)rule\\s+[A-Za-z_]\\w*(?:\\s+severity\\s+(?:information|warning|error))?(?:\\s+message\\s+.*)?$/;\n\nexport type CompletionPlan =\n | { kind: 'none' }\n | { kind: 'entries'; entries: CompletionEntry[] }\n | { kind: 'contextVariables'; replaceLength: number }\n | { kind: 'playFiles'; replaceLength: number }\n | { kind: 'policies' }\n | { kind: 'events' }\n | { kind: 'triggers' }\n | { kind: 'commands' }\n | { kind: 'producesTargets' }\n | { kind: 'screens' }\n | { kind: 'queries' }\n | { kind: 'types' };\n\n// What the position sits inside, beyond the keyword chain: the whole header of each enclosing block, so a\n// slice's type and a template's kind are known, and the document's own lines, so a declaration that may\n// appear once is not offered again.\nexport interface CompletionScope {\n headers: readonly string[];\n document: readonly string[];\n}\n\nconst declaredIn = (document: readonly string[], keyword: string) => document.some(line => new RegExp(`^${keyword}\\\\b`).test(line));\n\nfunction topLevelEntries(document: readonly string[]): CompletionEntry[] {\n return items.topLevelItems.filter(item => !(item.label === 'domain' && declaredIn(document, 'domain')) && !(item.label === 'authentication' && declaredIn(document, 'authentication')) && !(item.label === 'identity' && declaredIn(document, 'identity')));\n}\n\nconst isTemplate = (header: string | undefined) => /^(?:screen|dialog)\\s+template\\b/.test(header ?? '');\n\n// A whole block as one completion entry. Continuation lines are indented relative to the line it is inserted on,\n// which is how the editors indent a multi-line snippet.\nfunction expansionEntry(text: string, indent: number): CompletionEntry {\n const relative = text.split('\\n').map((line, index) => (index === 0 ? line : line.slice(Math.min(indent, indentOf(line))))).join('\\n');\n const label = text.split('\\n')[0].trim();\n return { label, insertText: relative.replace(/[$}\\\\]/g, '\\\\$&'), documentation: 'Expands the whole block from what the command and its events declare.' };\n}\n\nexport function completionEntriesFor(chain: string[], where: CompletionScope = { headers: [], document: [] }): CompletionEntry[] {\n const construct = chain[0];\n if (construct === undefined || construct === 'domain') return topLevelEntries(where.document);\n const subLanguage = getSubLanguage(construct);\n if (subLanguage) return subLanguage.completions ?? [];\n const header = where.headers[0];\n switch (construct) {\n case 'purpose':\n return purposeItems;\n case 'module':\n return items.moduleItems;\n case 'feature':\n return items.featureItems;\n case 'slice':\n return items.sliceItemsFor(header?.split(/\\s+/)[1]);\n case 'concept':\n return /:\\s*Enum\\b/.test(header ?? '') ? [...items.conceptItems, { label: 'enum member (numbered)', insertText: '${1:value} = ${2:0}', documentation: 'Every member must declare a unique int32 number. Keep published numbers unchanged; specifications name members, not numbers.' }] : items.conceptItems;\n case 'type':\n return items.typeItems;\n case 'command':\n return items.commandItems;\n case 'public':\n case 'event':\n return items.eventItems;\n case 'readmodel':\n return scope.readModelItems;\n case 'reducer':\n return scope.reducerItems;\n case 'form':\n return scope.formItems;\n case 'contribute':\n return scope.contributeItems;\n case 'behavior':\n return scope.behaviorItems;\n case 'persona':\n return scope.personaItems;\n case 'identity':\n return items.identityItems;\n case 'authentication':\n return scope.authenticationItems;\n case 'seed':\n return scope.seedItems;\n case 'theme':\n return scope.themeItems;\n case 'ui':\n return scope.uiProfileItems;\n case 'on':\n case 'success':\n case 'failure':\n case 'confirm':\n return scope.outcomeItems;\n case 'layout':\n return scope.layoutItems;\n case 'system':\n return items.operationItems.filter(item => item.label === 'description');\n case 'operation':\n return items.operationItems;\n case 'execute':\n case 'compensate':\n return items.operationPhaseItems;\n case 'produces':\n return chain.includes('command') ? [...items.producesItems, productionRouteItem] : items.producesItems;\n case 'handler':\n return items.handlerItems;\n case 'implementation':\n return chain[1] === 'handler' ? items.implementationItems : ['execute', 'compensate'].includes(chain[1]) ? items.operationImplementationItems : [];\n case 'reads':\n return [{ label: 'by parts', insertText: 'by\\n ${1:part} = ${2:source}\\n ${3:part} = ${4:source}', documentation: 'Supply every composite read-model key part by name.' }];\n case 'query':\n return items.queryItems;\n case 'performer':\n return items.performerItems;\n case 'constraint':\n return items.constraintItems;\n case 'reaction':\n return items.reactionItems;\n case 'invokes':\n return chain.includes('reaction') ? items.invocationItems : [];\n case 'trigger':\n return items.triggerItems;\n case 'when':\n case 'every':\n case 'at':\n return chain.includes('reaction') ? items.reactionTriggerItems : [];\n case 'specification':\n return items.specificationItems;\n case 'policy':\n return items.policyItems;\n case 'validate':\n return items.validateItems;\n case 'action':\n return items.actionItems;\n case 'table':\n case 'summary':\n return items.tableItems;\n case 'screen':\n return isTemplate(header) ? scope.templateItems : items.screenItems;\n case 'dialog':\n return scope.templateItems;\n default:\n if (isTemplate(where.headers.find(candidate => isTemplate(candidate)))) return scope.templateItems;\n // Sections inside a screen expose the screen vocabulary.\n if (chain.includes('screen') || construct === 'section') return items.screenItems;\n if (chain.includes('produces')) return chain.includes('command') ? [...items.producesItems, productionRouteItem] : items.producesItems;\n return [];\n }\n}\n\n// Decides what to complete at a position, without any editor dependency — the\n// Monaco service and the VSCode extension both materialize the plan into items.\nexport function planCompletions(\n lines: string[],\n lineIndex: number,\n textBefore: string,\n symbols: DocumentSymbols = scanDocument(lines),\n): CompletionPlan {\n const fences = fenceMap(lines);\n if (fences[lineIndex] || withoutComment(textBefore).length < textBefore.length) return { kind: 'none' };\n if (/^\\s*concept\\s+[\\p{L}\\p{Mn}\\p{Nd}\\p{Pc}]+\\s*:\\s*\\w+\\s+(?:(?:pii|personal|secret)\\s+)*\\w*$/u.test(textBefore)) {\n return { kind: 'entries', entries: ['pii', 'secret'].filter(marker => !new RegExp(`\\\\b${marker}\\\\b`).test(textBefore)).map(marker => ({ label: marker, insertText: marker, documentation: marker === 'pii' ? 'personal data (GDPR Art. 4(1)); renders Chronicle [PII]' : 'Operational secret; renders [Encrypted] + [NotAudited].' })) };\n }\n const inConcept = enclosingChain(lines, fences, lineIndex, indentOf(textBefore))[0] === 'concept';\n if (inConcept && /^\\s*(?:secret|sensitive|@sensitive)\\s+scope\\s+\\w*$/.test(textBefore)) {\n return { kind: 'entries', entries: ['subject', 'namespace', 'global'].map(scope => ({ label: scope, insertText: scope, documentation: 'Explicit secret encryption scope.' })) };\n }\n if (inConcept && /^\\s*(?:pii|personal|@pii)\\s+special\\s+\\w*$/.test(textBefore)) {\n return { kind: 'entries', entries: ['racialOrEthnicOrigin', 'politicalOpinions', 'religiousOrPhilosophicalBeliefs', 'tradeUnionMembership', 'genetic', 'biometric', 'health', 'sexLifeOrSexualOrientation'].map(category => ({ label: category, insertText: category, documentation: 'GDPR Art. 9(1) special category.' })) };\n }\n const responseEntries = exampleCompletions(lines, lineIndex, textBefore) ?? responseCompletions(lines, lineIndex, textBefore, scanDocument(lines));\n if (responseEntries !== null) return { kind: 'entries', entries: responseEntries };\n const keyEntries = readModelKeyCompletions(lines, lineIndex, textBefore, symbols);\n if (keyEntries !== null) return { kind: 'entries', entries: keyEntries };\n const dependencyEntries = dependencyTargetCompletions(lines, lineIndex, textBefore, symbols);\n if (dependencyEntries !== null) return { kind: 'entries', entries: dependencyEntries };\n\n // Inside the quotes of a file import, what is wanted is a path - replacing what has been typed so far.\n const importPath = textBefore.match(/^\\s*import\\s+\"([^\"]*)$/);\n if (importPath) {\n return { kind: 'playFiles', replaceLength: importPath[1].length };\n }\n\n // A quote or a slash only asks for a completion inside an import path.\n if (/[\"/]$/.test(textBefore)) return { kind: 'none' };\n\n const refusal = refusalContext(lines, lineIndex, indentOf(lines[lineIndex] ?? textBefore));\n if (/\\$refusal\\.\\w*$/.test(textBefore)) {\n return { kind: 'entries', entries: refusal === undefined ? [] : ['reason', 'message', ...(/^on\\s+refused\\s+by\\s+constraint(?:\\s|$)/.test(refusal) ? ['constraint'] : [])].map(member => ({ label: member, insertText: member, documentation: 'String refusal value; syntax-only, not yet executable (PLAY0268).' })) };\n }\n const contextVariableMatch = textBefore.match(/\\$[\\w.]*$/);\n if (contextVariableMatch) {\n return { kind: 'contextVariables', replaceLength: contextVariableMatch[0].length };\n }\n\n const currentLine = lines[lineIndex] ?? '';\n const effectiveIndent =\n textBefore.trim().length === 0 ? textBefore.length : indentOf(currentLine);\n const chain = enclosingChain(lines, fences, lineIndex, effectiveIndent);\n if (chain.includes('screen')) {\n let parentIndent = effectiveIndent;\n let guarded = false;\n for (let index = lineIndex - 1; index >= 0; index--) {\n if (fences[index]) continue;\n const parent = withoutComment(lines[index]);\n if (parent.trim().length === 0 || indentOf(parent) >= parentIndent) continue;\n parentIndent = indentOf(parent);\n if (/^\\s*action\\s+(?:\"|\\$strings\\.)/.test(parent)) { guarded = true; break; }\n if (/^\\s*screen\\b/.test(parent)) break;\n }\n if (guarded) {\n if (/^\\s*(?:when\\b.*|otherwise)\\s+execute\\s+[\\w.]*$/.test(textBefore)) return { kind: 'commands' };\n if (chain[0] === 'action') return { kind: 'entries', entries: items.guardedActionItems };\n if (['when', 'otherwise'].includes(chain[0])) {\n const parent = nearestEnclosingLine(lines, fences, lineIndex, effectiveIndent) ?? '';\n return { kind: 'entries', entries: /\\bexecute\\s+[\\w.]+$/.test(parent) ? items.actionArgumentItems : [] };\n }\n }\n }\n if (['on', 'when', 'otherwise'].includes(chain[0])) {\n let parentIndent = effectiveIndent;\n for (let index = lineIndex - 1; index >= 0; index--) {\n if (fences[index]) continue;\n const parent = withoutComment(lines[index]);\n if (parent.trim().length === 0 || indentOf(parent) >= parentIndent) continue;\n parentIndent = indentOf(parent);\n if (/^\\s*on\\s+(?:click|double click|select)\\s*$/.test(parent)) {\n return { kind: 'entries', entries: chain[0] === 'on' ? items.interactionChoiceItems : items.interactionActionItems };\n }\n if (/^\\s*(?:screen|behavior|specification|reaction)\\b/.test(parent)) break;\n }\n }\n if (chain[0] === 'on' && refusal !== undefined) return { kind: 'entries', entries: items.refusalItems };\n const ruleContext = namedRuleContext(lines, lineIndex, effectiveIndent);\n if (ruleContext === 'implementation') return { kind: 'entries', entries: items.namedRuleImplementationItems };\n if (ruleContext === 'rule') return { kind: 'entries', entries: items.commandRuleItems };\n\n const propertyOwner = ['public', 'event', 'command', 'type', 'readmodel', 'trigger', 'when', 'every', 'at'].includes(chain[0]) ||\n (chain[0] === 'produces' && /^produces\\s+event\\b/.test(nearestEnclosingLine(lines, fences, lineIndex, effectiveIndent) ?? ''));\n const propertyName = textBefore.trimStart().split(/\\s+/)[0];\n const reservedProperty = (chain[0] === 'command' && ['reads', 'authorize', 'produces'].includes(propertyName)) ||\n (chain[0] === 'event' && propertyName === 'tag') ||\n (['trigger', 'when', 'every', 'at'].includes(chain[0]) && ['description', 'file', 'reads', 'produces', 'invokes'].includes(propertyName));\n const optionalPrefix = (match: RegExpMatchArray | null) => match !== null && 'optional'.startsWith(match[1]);\n const afterPropertyType = propertyOwner && !reservedProperty && optionalPrefix(textBefore.match(/^\\s*@?[a-z_]\\w*\\s+[\\w.]+(?:\\[\\])?\\s+(\\w*)$/));\n const afterQueryType = (chain[0] === 'query' && optionalPrefix(textBefore.match(/^\\s*(?:by|filter)\\s+[a-z_]\\w*\\s+[\\w.]+(?:\\[\\])?\\s+(\\w*)$/))) ||\n optionalPrefix(textBefore.match(/^\\s*query\\s+[A-Za-z_]\\w*\\s*=>\\s*(?:observable\\s+)?[\\w.]+(?:\\[\\])?\\s+(\\w*)$/));\n const eventPropertyOwner = chain[0] === 'event' || (chain[0] === 'produces' && /^produces\\s+event\\b/.test(nearestEnclosingLine(lines, fences, lineIndex, effectiveIndent) ?? ''));\n const subjectModifier = eventPropertyOwner && !reservedProperty ? textBefore.match(/^\\s*@?[a-z_]\\w*\\s+([\\w.]+)\\s+(\\w*)$/) : null;\n const subjectConcept = symbols.concepts.find(concept => concept.name === subjectModifier?.[1]);\n const subjectType = subjectConcept?.primitive ?? subjectModifier?.[1];\n const subjectTarget = (subjectType === 'String' || subjectType === 'Uuid' || (subjectType === 'Int' && subjectConcept !== undefined)) &&\n !subjectConcept?.attributes.some(attribute => ['pii', 'personal', 'secret', 'sensitive'].includes(attribute.replace(/^@/, '')));\n const afterSubjectType = subjectModifier !== null && subjectTarget && 'subject'.startsWith(subjectModifier[2]);\n const keyModifier = chain[0] === 'readmodel' ? textBefore.match(/^\\s*@?[a-z_]\\w*\\s+[\\w.]+\\s+(\\w*)$/) : null;\n const modifierEntries = [\n ...(keyModifier && 'key'.startsWith(keyModifier[1]) ? [{ label: 'key', insertText: 'key', documentation: 'Declares a required read-model key part. Explicit keys replace inference. Composite keys are authoring-only (#599).' }] : []),\n ...((afterPropertyType || afterQueryType) && !/=>\\s*observable\\s+$/.test(textBefore) ? items.optionalTypeItems : []),\n ...(afterSubjectType ? [{ label: 'subject', insertText: 'subject', documentation: 'One required scalar event data-subject identity; not pii or secret. Report-only lineage metadata (PLAY0270), no ESM or provider output yet.' }] : []),\n ];\n if (modifierEntries.length > 0) return { kind: 'entries', entries: modifierEntries };\n\n if (/\\bauthorize\\s+[\\w\\s]*$/.test(textBefore) || chain[0] === 'authorize') {\n return { kind: 'policies' };\n }\n if (/\\bwhen\\s+\\w*$/.test(textBefore) && chain.includes('reaction')) {\n return { kind: 'triggers' };\n }\n if (/\\bon\\s+\\w*$/.test(textBefore) && chain.includes('constraint')) {\n return { kind: 'events' };\n }\n if (/\\binvokes\\s+\\w*$/.test(textBefore) && chain.includes('reaction')) {\n return { kind: 'commands' };\n }\n if (/\\b(?:on|unique\\s+event)\\s+\\w*$/.test(textBefore) && chain[0] === 'constraint') {\n return { kind: 'events' };\n }\n if (/\\bproduces\\s+\\w*$/.test(textBefore)) {\n return { kind: 'producesTargets' };\n }\n if (/\\bnavigate\\s+to\\s+\\w*$/.test(textBefore)) {\n return { kind: 'screens' };\n }\n if (chain[0] === 'specification') {\n if (/^\\s*when\\s+query\\s+[\\w.]*$/.test(textBefore)) return { kind: 'queries' };\n const step = textBefore.match(/^\\s*(given|when|then)\\s+\\w*$/);\n if (step) return { kind: 'entries', entries: items.specificationStepItems[step[1] as 'given' | 'when' | 'then'] };\n }\n if (/\\b(?:via|then)\\s+query\\s+[\\w.]*$/.test(textBefore)) {\n return { kind: 'queries' };\n }\n if (\n (chain[0] === 'event' || chain[0] === 'command' || chain[0] === 'type') &&\n /^\\s+[a-z_]\\w*\\s+[\\w[\\]?]*$/.test(textBefore)\n ) {\n return { kind: 'types' };\n }\n if (chain[0] === 'query' && /^\\s+(?:by|filter)\\s+[a-z_]\\w*\\s+[\\w[\\]?]*$/.test(textBefore)) {\n return { kind: 'types' };\n }\n\n const enclosingLine = nearestEnclosingLine(lines, fences, lineIndex, effectiveIndent);\n if (enclosingLine && /^produces\\s+operation\\b/.test(enclosingLine)) return { kind: 'entries', entries: items.operationItems };\n if (enclosingLine && /^produces\\s+event\\b/.test(enclosingLine)) {\n if (/^\\s+@?[a-z_]\\w*\\s+[\\w[\\]?]*$/.test(textBefore)) return { kind: 'types' };\n return { kind: 'entries', entries: chain.includes('command') ? [...items.inlineEventItems, productionRouteItem] : items.inlineEventItems };\n }\n if (enclosingLine && RULE_LINE_PATTERN.test(enclosingLine)) {\n return { kind: 'entries', entries: items.ruleItems };\n }\n\n const headers = enclosingHeaders(lines, fences, lineIndex, effectiveIndent);\n if (chain[0] === 'for' && chain.includes('seed')) return { kind: 'events' };\n const entries = completionEntriesFor(chain, { headers, document: lines });\n const expansion = chain[0] === 'command' ? structureCompletion(lines, lineIndex, ' '.repeat(effectiveIndent), '', symbols) : null;\n return { kind: 'entries', entries: expansion ? [expansionEntry(expansion.text, effectiveIndent), ...entries] : entries };\n}\n"],"mappings":"i6DAuBA,MAAMmD,EAAsB,CAAE,MAAO,SAAU,WAAY,4BAA6B,cAAe,qEAAsE,EAEvKC,GAAoB,mGAwBpB,YAAc,EAA6B,IAAoBC,EAAS,KAAK,GAAY,OAAO,IAAIC,EAAQ,IAAI,CAAC,CAAC,KAAKC,CAAI,CAAC,EAElI,SAAS,gBAAgB,EAAgD,CACrE,OAAAC,GAA2B,OAAO,GAAQ,EAAEC,EAAK,QAAU,UAAY,WAAWJ,EAAU,QAAQ,IAAM,EAAEI,EAAK,QAAU,kBAAoB,WAAWJ,EAAU,gBAAgB,IAAM,EAAEI,EAAK,QAAU,YAAc,WAAWJ,EAAU,UAAU,EAAE,CAC9P,CAEA,MAAM,WAAc,GAA+B,kCAAkC,KAAKK,GAAU,EAAE,EAItG,SAAS,eAAe,EAAc,EAAiC,CACnE,IAAMC,EAAWC,EAAK,MAAM;CAAI,CAAC,CAAC,KAAK,EAAM,IAAWC,IAAU,EAAIN,EAAOA,EAAK,MAAM,KAAK,IAAIO,EAAQC,EAASR,CAAI,CAAC,CAAC,CAAE,CAAC,CAAC,KAAK;CAAI,EAErI,MAAO,CAAE,MADKK,EAAK,MAAM;CAAI,CAAC,CAAC,EAAE,CAAC,KACrB,EAAG,WAAYD,EAAS,QAAQ,UAAW,MAAM,EAAG,cAAe,uEAAwE,CAC5J,CAEA,SAAgB,qBAAqB,EAAiB,EAAyB,CAAE,QAAS,CAAC,EAAG,SAAU,CAAC,CAAE,EAAsB,CAC7H,IAAMK,EAAYC,EAAM,GACxB,GAAID,IAAc,IAAA,IAAaA,IAAc,SAAU,OAAO,gBAAgBE,EAAM,QAAQ,EAC5F,IAAMC,EAAcC,GA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,EAAqB9B,EAAOC,EAAQE,EAAWsB,CAAe,EACpF,GAAIgC,GAAiB,0BAA0B,KAAKA,CAAa,EAAG,MAAO,CAAE,KAAM,UAAW,QAASrJ,CAAqB,EAC5H,GAAIqJ,GAAiB,sBAAsB,KAAKA,CAAa,EAEzD,MADI,+BAA+B,KAAKpD,CAAU,EAAU,CAAE,KAAM,OAAQ,EACrE,CAAE,KAAM,UAAW,QAASpD,EAAM,SAAS,SAAS,EAAI,CAAC,GAAGhB,EAAwBE,CAAmB,EAAIF,CAAuB,EAE7I,GAAIwH,GAAiBrH,GAAkB,KAAKqH,CAAa,EACrD,MAAO,CAAE,KAAM,UAAW,QAASvH,CAAgB,EAGvD,IAAM0H,EAAUC,EAAiB7D,EAAOC,EAAQE,EAAWsB,CAAe,EAC1E,GAAIxE,EAAM,KAAO,OAASA,EAAM,SAAS,MAAM,EAAG,MAAO,CAAE,KAAM,QAAS,EAC1E,IAAM6G,EAAU,qBAAqB7G,EAAO,CAAE,UAAS,SAAU+C,CAAM,CAAC,EAClE+D,EAAY9G,EAAM,KAAO,UAAY+G,GAAoBhE,EAAOG,EAAW,IAAI,OAAOsB,CAAe,EAAG,GAAIT,CAAO,EAAI,KAC7H,MAAO,CAAE,KAAM,UAAW,QAAS+C,EAAY,CAAC,eAAeA,EAAU,KAAMtC,CAAe,EAAG,GAAGqC,CAAO,EAAIA,CAAQ,CAC3H"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const e={repeatedSingularDeclarationAcrossFiles:`PLAY0172`,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`,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`,invalidReadModelKey:`PLAY0660`,incompleteReadModelKey:`PLAY0661`,invalidReadModelKeyLookup:`PLAY0662`,productionRouteOutsideCommand:`PLAY0663`,redundantProductionRoute:`PLAY0664`,invalidObserverFilter:`PLAY0665`,observerFilterExcludesEveryProducer:`PLAY0666`,invalidDescription:`PLAY0145`,emptyDescription:`PLAY0146`,duplicateDescription:`PLAY0147`,unknownConceptDirective:`PLAY0010`,attributeReasonWithoutAttribute:`PLAY0012`,duplicateAttributeReason:`PLAY0013`,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`,duplicateEventSubject:`PLAY0590`,invalidSubjectType:`PLAY0591`,protectedSubjectType:`PLAY0592`,invalidSubjectOwner:`PLAY0593`,readModelSubjectNotSupported:`PLAY0594`,invalidSubjectModifierOrder:`PLAY0595`,conflictingScreenDataBinding:`PLAY0530`,screenDataQueryMismatch:`PLAY0531`,actionWithoutInputSurface:`PLAY0532`,commandWithoutInputSurface:`PLAY0533`,readModelFieldWithoutOrigin:`PLAY0534`,queryParameterNotHeldByView:`PLAY0535`,unconsumedEvent:`PLAY0536`,unreachableScreen:`PLAY0537`,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`,invalidActionAlternative:`PLAY0341`,guardedActionWithoutAlternatives:`PLAY0342`,misplacedActionOtherwise:`PLAY0343`,unsupportedActionConditionOperand:`PLAY0344`,unknownActionSubjectField:`PLAY0345`,unresolvedActionSubject:`PLAY0346`,unreachableActionAlternative:`PLAY0347`,unknownActionArgumentProperty:`PLAY0348`,invalidRefusalBranch:`PLAY0538`,invalidRefusalBranchBody:`PLAY0539`,unreachableRefusalBranch:`PLAY0540`,invalidRefusalValue:`PLAY0541`,unknownRefusalConstraint:`PLAY0542`,unmatchedRedeliveredOccurrence:`PLAY0543`,unknownRedeliveryReaction:`PLAY0544`,invalidNoEventsExpectation:`PLAY0545`,indeterminateNegatedClaimTarget:`PLAY0546`,invalidAbsentReadModelStep:`PLAY0453`,unknownConstraintProperty:`PLAY0391`,invalidSpecificationExample:`PLAY0518`,duplicateSpecificationAssignment:`PLAY0519`,unknownReadModelProperty:`PLAY0514`,piiNotSupportedOnIdentifier:`PLAY0515`,invalidEventSourceDeclaration:`PLAY0503`,invalidCommandStream:`PLAY0504`,invalidSpecificationStream:`PLAY0547`,specificationStreamOnCommand:`PLAY0548`,invalidSpecificationStreamRoute:`PLAY0549`,invalidSpecificationStreamEventSource:`PLAY0550`,specificationStreamContradictsCommand:`PLAY0551`,ambiguousCommandStream:`PLAY0505`,unsupportedStreamIdType:`PLAY0506`,redundantSourceStreamId:`PLAY0507`,eventFromLaterSlice:`PLAY0516`,timelineCycleGroup:`PLAY0517`,invalidSpecificationExampleBody:`PLAY0526`,undeclaredDependency:`PLAY0552`,unusedDependencyDeclaration:`PLAY0553`,invalidDependencyTarget:`PLAY0554`,repeatedDependencyDeclaration:`PLAY0555`,mutualDependencyDeclarations:`PLAY0556`,authorizationRefusalWithoutIdentity:`PLAY0557`,invalidDocumentation:`PLAY0558`,conflictingDocumentationAcrossFiles:`PLAY0559`,unsupportedInteractionAlternatives:`PLAY0560`,mixedInteractionAlternatives:`PLAY0561`,interactionAlternativeWithoutActions:`PLAY0562`,inlineInteractionAlternative:`PLAY0563`,legacyInteractionWhere:`PLAY0564`,ambiguousReference:`PLAY0198`,invalidImplementationBlock:`PLAY0492`,invalidImplementationHint:`PLAY0493`,conflictingImplementationSources:`PLAY0494`,eventSourceIdInPayload:`PLAY0469`,explicitProducesTargetsRequired:`PLAY0470`,redundantEventId:`PLAY0471`,invalidEventId:`PLAY0472`,inlineEventCollision:`PLAY0473`,inlineEventOutsideCommand:`PLAY0474`,inlineEventGeneration:`PLAY0475`,reservedProductionMetadata:`PLAY0476`,invalidEventDocumentation:`PLAY0477`,tabIndentation:`PLAY0006`,unknownPrimitiveType:`PLAY0008`,unknownSliceType:`PLAY0028`,duplicateCommandIdentifier:`PLAY0036`,unknownContextPath:`PLAY0153`,unknownContextCausedByProperty:`PLAY0154`,unknownContextIdentityProperty:`PLAY0155`,unclosedCodeBlock:`PLAY0164`,unknownType:`PLAY0165`,unknownEvent:`PLAY0166`,unknownPolicy:`PLAY0167`,duplicateDeclaration:`PLAY0168`,unknownEventContextMember:`PLAY0295`,unknownEventContextPath:`PLAY0296`,eventContextPathBelowCollection:`PLAY0297`,missingEventContextPath:`PLAY0298`,unresolvedDynamicKeySource:`PLAY0299`,invalidFileImport:`PLAY0454`,omittedProductionDestination:`PLAY0478`,legacyOptionalSuffix:`PLAY0479`,invalidOptionalModifierOrder:`PLAY0480`,optionalReadsNotSupported:`PLAY0481`,unavailableResponseExecution:`PLAY0268`,generatedPropertyOutsideCommand:`PLAY0482`,invalidGeneratedType:`PLAY0483`,invalidGeneratedModifierOrder:`PLAY0484`,generatedPropertyInput:`PLAY0485`,invalidCommandResponse:`PLAY0486`,invalidResponseSource:`PLAY0487`,duplicateResponseField:`PLAY0488`,invalidResponseShape:`PLAY0489`,invalidGeneratedFixture:`PLAY0490`,invalidReturnExpectation:`PLAY0491`};export{e as diagnosticCodes};
|
|
1
|
+
const e={repeatedSingularDeclarationAcrossFiles:`PLAY0172`,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`,mixedEnumerationNumbering:`PLAY0667`,duplicateEnumerationNumber:`PLAY0668`,enumerationNumberOutsideInt32:`PLAY0669`,malformedEnumerationNumber:`PLAY0670`,unpinnedStoredEnumeration:`PLAY0671`,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`,invalidReadModelKey:`PLAY0660`,incompleteReadModelKey:`PLAY0661`,invalidReadModelKeyLookup:`PLAY0662`,productionRouteOutsideCommand:`PLAY0663`,redundantProductionRoute:`PLAY0664`,invalidObserverFilter:`PLAY0665`,observerFilterExcludesEveryProducer:`PLAY0666`,invalidDescription:`PLAY0145`,emptyDescription:`PLAY0146`,duplicateDescription:`PLAY0147`,unknownConceptDirective:`PLAY0010`,attributeReasonWithoutAttribute:`PLAY0012`,duplicateAttributeReason:`PLAY0013`,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`,duplicateEventSubject:`PLAY0590`,invalidSubjectType:`PLAY0591`,protectedSubjectType:`PLAY0592`,invalidSubjectOwner:`PLAY0593`,readModelSubjectNotSupported:`PLAY0594`,invalidSubjectModifierOrder:`PLAY0595`,conflictingScreenDataBinding:`PLAY0530`,screenDataQueryMismatch:`PLAY0531`,actionWithoutInputSurface:`PLAY0532`,commandWithoutInputSurface:`PLAY0533`,readModelFieldWithoutOrigin:`PLAY0534`,queryParameterNotHeldByView:`PLAY0535`,unconsumedEvent:`PLAY0536`,unreachableScreen:`PLAY0537`,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`,invalidActionAlternative:`PLAY0341`,guardedActionWithoutAlternatives:`PLAY0342`,misplacedActionOtherwise:`PLAY0343`,unsupportedActionConditionOperand:`PLAY0344`,unknownActionSubjectField:`PLAY0345`,unresolvedActionSubject:`PLAY0346`,unreachableActionAlternative:`PLAY0347`,unknownActionArgumentProperty:`PLAY0348`,invalidRefusalBranch:`PLAY0538`,invalidRefusalBranchBody:`PLAY0539`,unreachableRefusalBranch:`PLAY0540`,invalidRefusalValue:`PLAY0541`,unknownRefusalConstraint:`PLAY0542`,unmatchedRedeliveredOccurrence:`PLAY0543`,unknownRedeliveryReaction:`PLAY0544`,invalidNoEventsExpectation:`PLAY0545`,indeterminateNegatedClaimTarget:`PLAY0546`,invalidAbsentReadModelStep:`PLAY0453`,unknownConstraintProperty:`PLAY0391`,invalidSpecificationExample:`PLAY0518`,duplicateSpecificationAssignment:`PLAY0519`,unknownReadModelProperty:`PLAY0514`,piiNotSupportedOnIdentifier:`PLAY0515`,invalidEventSourceDeclaration:`PLAY0503`,invalidCommandStream:`PLAY0504`,invalidSpecificationStream:`PLAY0547`,specificationStreamOnCommand:`PLAY0548`,invalidSpecificationStreamRoute:`PLAY0549`,invalidSpecificationStreamEventSource:`PLAY0550`,specificationStreamContradictsCommand:`PLAY0551`,ambiguousCommandStream:`PLAY0505`,unsupportedStreamIdType:`PLAY0506`,redundantSourceStreamId:`PLAY0507`,eventFromLaterSlice:`PLAY0516`,timelineCycleGroup:`PLAY0517`,invalidSpecificationExampleBody:`PLAY0526`,undeclaredDependency:`PLAY0552`,unusedDependencyDeclaration:`PLAY0553`,invalidDependencyTarget:`PLAY0554`,repeatedDependencyDeclaration:`PLAY0555`,mutualDependencyDeclarations:`PLAY0556`,authorizationRefusalWithoutIdentity:`PLAY0557`,invalidDocumentation:`PLAY0558`,conflictingDocumentationAcrossFiles:`PLAY0559`,unsupportedInteractionAlternatives:`PLAY0560`,mixedInteractionAlternatives:`PLAY0561`,interactionAlternativeWithoutActions:`PLAY0562`,inlineInteractionAlternative:`PLAY0563`,legacyInteractionWhere:`PLAY0564`,ambiguousReference:`PLAY0198`,invalidImplementationBlock:`PLAY0492`,invalidImplementationHint:`PLAY0493`,conflictingImplementationSources:`PLAY0494`,eventSourceIdInPayload:`PLAY0469`,explicitProducesTargetsRequired:`PLAY0470`,redundantEventId:`PLAY0471`,invalidEventId:`PLAY0472`,inlineEventCollision:`PLAY0473`,inlineEventOutsideCommand:`PLAY0474`,inlineEventGeneration:`PLAY0475`,reservedProductionMetadata:`PLAY0476`,invalidEventDocumentation:`PLAY0477`,tabIndentation:`PLAY0006`,unknownPrimitiveType:`PLAY0008`,unknownSliceType:`PLAY0028`,duplicateCommandIdentifier:`PLAY0036`,unknownContextPath:`PLAY0153`,unknownContextCausedByProperty:`PLAY0154`,unknownContextIdentityProperty:`PLAY0155`,unclosedCodeBlock:`PLAY0164`,unknownType:`PLAY0165`,unknownEvent:`PLAY0166`,unknownPolicy:`PLAY0167`,duplicateDeclaration:`PLAY0168`,unknownEventContextMember:`PLAY0295`,unknownEventContextPath:`PLAY0296`,eventContextPathBelowCollection:`PLAY0297`,missingEventContextPath:`PLAY0298`,unresolvedDynamicKeySource:`PLAY0299`,invalidFileImport:`PLAY0454`,omittedProductionDestination:`PLAY0478`,legacyOptionalSuffix:`PLAY0479`,invalidOptionalModifierOrder:`PLAY0480`,optionalReadsNotSupported:`PLAY0481`,unavailableResponseExecution:`PLAY0268`,generatedPropertyOutsideCommand:`PLAY0482`,invalidGeneratedType:`PLAY0483`,invalidGeneratedModifierOrder:`PLAY0484`,generatedPropertyInput:`PLAY0485`,invalidCommandResponse:`PLAY0486`,invalidResponseSource:`PLAY0487`,duplicateResponseField:`PLAY0488`,invalidResponseShape:`PLAY0489`,invalidGeneratedFixture:`PLAY0490`,invalidReturnExpectation:`PLAY0491`};export{e as diagnosticCodes};
|
|
2
2
|
//# sourceMappingURL=diagnostic-codes.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"diagnostic-codes.js","names":["diagnosticCodes"],"sources":["../../diagnostic-codes.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// The PLAY codes the editor reports. Every one of them mirrors a condition the compiler checks and\n// carries the compiler's own code for it, so the same problem is called the same thing whether it was\n// found by the CLI or by a squiggle - see Documentation/screenplay/diagnostics.md for the catalogue.\n//\n// A code is only ever added here for a condition the compiler can also report. The editor makes a few\n// structural checks the compiler does not - the capture and projection validators are where they live -\n// and those stay codeless deliberately: minting a PLAY number for something no compiler run can emit\n// would make the catalogue describe two different tools.\nexport const diagnosticCodes = {\n repeatedSingularDeclarationAcrossFiles: 'PLAY0172',\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 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 // Preserve supplied C# whole-model diagnostics; these checks are not yet run by the editor.\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 invalidReadModelKey: 'PLAY0660',\n incompleteReadModelKey: 'PLAY0661',\n invalidReadModelKeyLookup: 'PLAY0662',\n productionRouteOutsideCommand: 'PLAY0663',\n redundantProductionRoute: 'PLAY0664',\n invalidObserverFilter: 'PLAY0665',\n observerFilterExcludesEveryProducer: 'PLAY0666',\n invalidDescription: 'PLAY0145',\n emptyDescription: 'PLAY0146',\n duplicateDescription: 'PLAY0147',\n unknownConceptDirective: 'PLAY0010',\n attributeReasonWithoutAttribute: 'PLAY0012',\n duplicateAttributeReason: 'PLAY0013',\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 duplicateEventSubject: 'PLAY0590',\n invalidSubjectType: 'PLAY0591',\n protectedSubjectType: 'PLAY0592',\n invalidSubjectOwner: 'PLAY0593',\n readModelSubjectNotSupported: 'PLAY0594',\n invalidSubjectModifierOrder: 'PLAY0595',\n // Supplied compiler diagnostics are preserved, even for checks only the C# tool can run.\n // See Documentation/screenplay/editor-diagnostics.md for the validation boundary.\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 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 invalidActionAlternative: 'PLAY0341',\n guardedActionWithoutAlternatives: 'PLAY0342',\n misplacedActionOtherwise: 'PLAY0343',\n unsupportedActionConditionOperand: 'PLAY0344',\n unknownActionSubjectField: 'PLAY0345',\n unresolvedActionSubject: 'PLAY0346',\n unreachableActionAlternative: 'PLAY0347',\n unknownActionArgumentProperty: 'PLAY0348',\n invalidRefusalBranch: 'PLAY0538',\n invalidRefusalBranchBody: 'PLAY0539',\n unreachableRefusalBranch: 'PLAY0540',\n invalidRefusalValue: 'PLAY0541',\n unknownRefusalConstraint: 'PLAY0542',\n unmatchedRedeliveredOccurrence: 'PLAY0543',\n unknownRedeliveryReaction: 'PLAY0544',\n invalidNoEventsExpectation: 'PLAY0545',\n indeterminateNegatedClaimTarget: 'PLAY0546',\n invalidAbsentReadModelStep: 'PLAY0453',\n unknownConstraintProperty: 'PLAY0391',\n invalidSpecificationExample: 'PLAY0518',\n duplicateSpecificationAssignment: 'PLAY0519',\n unknownReadModelProperty: 'PLAY0514',\n piiNotSupportedOnIdentifier: 'PLAY0515',\n invalidEventSourceDeclaration: 'PLAY0503',\n invalidCommandStream: 'PLAY0504',\n invalidSpecificationStream: 'PLAY0547',\n specificationStreamOnCommand: 'PLAY0548',\n invalidSpecificationStreamRoute: 'PLAY0549',\n invalidSpecificationStreamEventSource: 'PLAY0550',\n specificationStreamContradictsCommand: 'PLAY0551',\n ambiguousCommandStream: 'PLAY0505',\n unsupportedStreamIdType: 'PLAY0506',\n redundantSourceStreamId: 'PLAY0507',\n eventFromLaterSlice: 'PLAY0516',\n timelineCycleGroup: 'PLAY0517',\n invalidSpecificationExampleBody: 'PLAY0526',\n undeclaredDependency: 'PLAY0552',\n unusedDependencyDeclaration: 'PLAY0553',\n invalidDependencyTarget: 'PLAY0554',\n repeatedDependencyDeclaration: 'PLAY0555',\n mutualDependencyDeclarations: 'PLAY0556',\n authorizationRefusalWithoutIdentity: 'PLAY0557',\n invalidDocumentation: 'PLAY0558',\n conflictingDocumentationAcrossFiles: 'PLAY0559',\n unsupportedInteractionAlternatives: 'PLAY0560',\n mixedInteractionAlternatives: 'PLAY0561',\n interactionAlternativeWithoutActions: 'PLAY0562',\n inlineInteractionAlternative: 'PLAY0563',\n legacyInteractionWhere: 'PLAY0564',\n ambiguousReference: 'PLAY0198',\n invalidImplementationBlock: 'PLAY0492',\n invalidImplementationHint: 'PLAY0493',\n conflictingImplementationSources: 'PLAY0494',\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 tabIndentation: 'PLAY0006',\n unknownPrimitiveType: 'PLAY0008',\n unknownSliceType: 'PLAY0028',\n duplicateCommandIdentifier: 'PLAY0036',\n unknownContextPath: 'PLAY0153',\n unknownContextCausedByProperty: 'PLAY0154',\n unknownContextIdentityProperty: 'PLAY0155',\n unclosedCodeBlock: 'PLAY0164',\n unknownType: 'PLAY0165',\n unknownEvent: 'PLAY0166',\n unknownPolicy: 'PLAY0167',\n duplicateDeclaration: 'PLAY0168',\n unknownEventContextMember: 'PLAY0295',\n unknownEventContextPath: 'PLAY0296',\n eventContextPathBelowCollection: 'PLAY0297',\n missingEventContextPath: 'PLAY0298',\n unresolvedDynamicKeySource: 'PLAY0299',\n invalidFileImport: 'PLAY0454',\n omittedProductionDestination: 'PLAY0478',\n legacyOptionalSuffix: 'PLAY0479',\n invalidOptionalModifierOrder: 'PLAY0480',\n optionalReadsNotSupported: 'PLAY0481',\n unavailableResponseExecution: 'PLAY0268',\n generatedPropertyOutsideCommand: 'PLAY0482',\n invalidGeneratedType: 'PLAY0483',\n invalidGeneratedModifierOrder: 'PLAY0484',\n generatedPropertyInput: 'PLAY0485',\n invalidCommandResponse: 'PLAY0486',\n invalidResponseSource: 'PLAY0487',\n duplicateResponseField: 'PLAY0488',\n invalidResponseShape: 'PLAY0489',\n invalidGeneratedFixture: 'PLAY0490',\n invalidReturnExpectation: 'PLAY0491',\n} as const;\n\nexport type DiagnosticCode = (typeof diagnosticCodes)[keyof typeof diagnosticCodes];\n"],"mappings":"AAWA,MAAaA,EAAkB,CAC3B,uCAAwC,WACxC,2BAA4B,WAC5B,qBAAsB,WACtB,gBAAiB,WACjB,iBAAkB,WAClB,4BAA6B,WAC7B,4BAA6B,WAC7B,uBAAwB,WACxB,yBAA0B,WAC1B,2BAA4B,WAC5B,wBAAyB,WACzB,sBAAuB,WACvB,6BAA8B,WAC9B,6BAA8B,WAC9B,+BAAgC,WAChC,qBAAsB,WACtB,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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B,8BAA+B,WAC/B,uBAAwB,WACxB,uBAAwB,WACxB,sBAAuB,WACvB,uBAAwB,WACxB,qBAAsB,WACtB,wBAAyB,WACzB,yBAA0B,UAC9B"}
|
|
1
|
+
{"version":3,"file":"diagnostic-codes.js","names":["diagnosticCodes"],"sources":["../../diagnostic-codes.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// The PLAY codes the editor reports. Every one of them mirrors a condition the compiler checks and\n// carries the compiler's own code for it, so the same problem is called the same thing whether it was\n// found by the CLI or by a squiggle - see Documentation/screenplay/diagnostics.md for the catalogue.\n//\n// A code is only ever added here for a condition the compiler can also report. The editor makes a few\n// structural checks the compiler does not - the capture and projection validators are where they live -\n// and those stay codeless deliberately: minting a PLAY number for something no compiler run can emit\n// would make the catalogue describe two different tools.\nexport const diagnosticCodes = {\n repeatedSingularDeclarationAcrossFiles: 'PLAY0172',\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 mixedEnumerationNumbering: 'PLAY0667',\n duplicateEnumerationNumber: 'PLAY0668',\n enumerationNumberOutsideInt32: 'PLAY0669',\n malformedEnumerationNumber: 'PLAY0670',\n unpinnedStoredEnumeration: 'PLAY0671',\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 // Preserve supplied C# whole-model diagnostics; these checks are not yet run by the editor.\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 invalidReadModelKey: 'PLAY0660',\n incompleteReadModelKey: 'PLAY0661',\n invalidReadModelKeyLookup: 'PLAY0662',\n productionRouteOutsideCommand: 'PLAY0663',\n redundantProductionRoute: 'PLAY0664',\n invalidObserverFilter: 'PLAY0665',\n observerFilterExcludesEveryProducer: 'PLAY0666',\n invalidDescription: 'PLAY0145',\n emptyDescription: 'PLAY0146',\n duplicateDescription: 'PLAY0147',\n unknownConceptDirective: 'PLAY0010',\n attributeReasonWithoutAttribute: 'PLAY0012',\n duplicateAttributeReason: 'PLAY0013',\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 duplicateEventSubject: 'PLAY0590',\n invalidSubjectType: 'PLAY0591',\n protectedSubjectType: 'PLAY0592',\n invalidSubjectOwner: 'PLAY0593',\n readModelSubjectNotSupported: 'PLAY0594',\n invalidSubjectModifierOrder: 'PLAY0595',\n // Supplied compiler diagnostics are preserved, even for checks only the C# tool can run.\n // See Documentation/screenplay/editor-diagnostics.md for the validation boundary.\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 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 invalidActionAlternative: 'PLAY0341',\n guardedActionWithoutAlternatives: 'PLAY0342',\n misplacedActionOtherwise: 'PLAY0343',\n unsupportedActionConditionOperand: 'PLAY0344',\n unknownActionSubjectField: 'PLAY0345',\n unresolvedActionSubject: 'PLAY0346',\n unreachableActionAlternative: 'PLAY0347',\n unknownActionArgumentProperty: 'PLAY0348',\n invalidRefusalBranch: 'PLAY0538',\n invalidRefusalBranchBody: 'PLAY0539',\n unreachableRefusalBranch: 'PLAY0540',\n invalidRefusalValue: 'PLAY0541',\n unknownRefusalConstraint: 'PLAY0542',\n unmatchedRedeliveredOccurrence: 'PLAY0543',\n unknownRedeliveryReaction: 'PLAY0544',\n invalidNoEventsExpectation: 'PLAY0545',\n indeterminateNegatedClaimTarget: 'PLAY0546',\n invalidAbsentReadModelStep: 'PLAY0453',\n unknownConstraintProperty: 'PLAY0391',\n invalidSpecificationExample: 'PLAY0518',\n duplicateSpecificationAssignment: 'PLAY0519',\n unknownReadModelProperty: 'PLAY0514',\n piiNotSupportedOnIdentifier: 'PLAY0515',\n invalidEventSourceDeclaration: 'PLAY0503',\n invalidCommandStream: 'PLAY0504',\n invalidSpecificationStream: 'PLAY0547',\n specificationStreamOnCommand: 'PLAY0548',\n invalidSpecificationStreamRoute: 'PLAY0549',\n invalidSpecificationStreamEventSource: 'PLAY0550',\n specificationStreamContradictsCommand: 'PLAY0551',\n ambiguousCommandStream: 'PLAY0505',\n unsupportedStreamIdType: 'PLAY0506',\n redundantSourceStreamId: 'PLAY0507',\n eventFromLaterSlice: 'PLAY0516',\n timelineCycleGroup: 'PLAY0517',\n invalidSpecificationExampleBody: 'PLAY0526',\n undeclaredDependency: 'PLAY0552',\n unusedDependencyDeclaration: 'PLAY0553',\n invalidDependencyTarget: 'PLAY0554',\n repeatedDependencyDeclaration: 'PLAY0555',\n mutualDependencyDeclarations: 'PLAY0556',\n authorizationRefusalWithoutIdentity: 'PLAY0557',\n invalidDocumentation: 'PLAY0558',\n conflictingDocumentationAcrossFiles: 'PLAY0559',\n unsupportedInteractionAlternatives: 'PLAY0560',\n mixedInteractionAlternatives: 'PLAY0561',\n interactionAlternativeWithoutActions: 'PLAY0562',\n inlineInteractionAlternative: 'PLAY0563',\n legacyInteractionWhere: 'PLAY0564',\n ambiguousReference: 'PLAY0198',\n invalidImplementationBlock: 'PLAY0492',\n invalidImplementationHint: 'PLAY0493',\n conflictingImplementationSources: 'PLAY0494',\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 tabIndentation: 'PLAY0006',\n unknownPrimitiveType: 'PLAY0008',\n unknownSliceType: 'PLAY0028',\n duplicateCommandIdentifier: 'PLAY0036',\n unknownContextPath: 'PLAY0153',\n unknownContextCausedByProperty: 'PLAY0154',\n unknownContextIdentityProperty: 'PLAY0155',\n unclosedCodeBlock: 'PLAY0164',\n unknownType: 'PLAY0165',\n unknownEvent: 'PLAY0166',\n unknownPolicy: 'PLAY0167',\n duplicateDeclaration: 'PLAY0168',\n unknownEventContextMember: 'PLAY0295',\n unknownEventContextPath: 'PLAY0296',\n eventContextPathBelowCollection: 'PLAY0297',\n missingEventContextPath: 'PLAY0298',\n unresolvedDynamicKeySource: 'PLAY0299',\n invalidFileImport: 'PLAY0454',\n omittedProductionDestination: 'PLAY0478',\n legacyOptionalSuffix: 'PLAY0479',\n invalidOptionalModifierOrder: 'PLAY0480',\n optionalReadsNotSupported: 'PLAY0481',\n unavailableResponseExecution: 'PLAY0268',\n generatedPropertyOutsideCommand: 'PLAY0482',\n invalidGeneratedType: 'PLAY0483',\n invalidGeneratedModifierOrder: 'PLAY0484',\n generatedPropertyInput: 'PLAY0485',\n invalidCommandResponse: 'PLAY0486',\n invalidResponseSource: 'PLAY0487',\n duplicateResponseField: 'PLAY0488',\n invalidResponseShape: 'PLAY0489',\n invalidGeneratedFixture: 'PLAY0490',\n invalidReturnExpectation: 'PLAY0491',\n} as const;\n\nexport type DiagnosticCode = (typeof diagnosticCodes)[keyof typeof diagnosticCodes];\n"],"mappings":"AAWA,MAAaA,EAAkB,CAC3B,uCAAwC,WACxC,2BAA4B,WAC5B,qBAAsB,WACtB,gBAAiB,WACjB,iBAAkB,WAClB,4BAA6B,WAC7B,4BAA6B,WAC7B,uBAAwB,WACxB,yBAA0B,WAC1B,2BAA4B,WAC5B,wBAAyB,WACzB,sBAAuB,WACvB,6BAA8B,WAC9B,6BAA8B,WAC9B,+BAAgC,WAChC,qBAAsB,WACtB,0BAA2B,WAC3B,2BAA4B,WAC5B,8BAA+B,WAC/B,2BAA4B,WAC5B,0BAA2B,WAC3B,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,yBAA0B,WAC1B,2BAA4B,WAC5B,mCAAoC,WACpC,8BAA+B,WAC/B,w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|
-
import"./_virtual/_virtual/_rolldown/runtime.js";import{typeReferenceText as e}from"./TypeReferenceSymbol.js";import{enclosingChain as t,enclosingHeaders as n,fenceMap as r,indentOf as i,withoutComment as a}from"./document-context.js";import{eventAnalysisSource as o}from"./event-analysis-source.js";import{responseAnalysis as s,responseAvailability as c}from"./response-analysis.js";import{directBody as ee,propertyTypeReference as l,scanDocument as u,symbolsForBuffer as d}from"./symbols.js";import{exampleHover as f}from"./example-authoring.js";import{operationHover as p}from"./operation-authoring.js";import{eventSourceHover as m}from"./event-source-authoring.js";import{refusalContext as h}from"./refusal-context.js";import{namedRuleContext as g}from"./named-rule-context.js";import{getSubLanguage as te}from"./sub-language-registry.js";import{reactionReferenceAt as ne}from"./reaction-authoring.js";import{attributeDocs as re,contextVariableDocs as _,handlerIntentDocs as v,keywordDocs as y,specialCategoryDocs as b,specificationKeywordDocs as x}from"./keyword-docs.js";function hoverContent(S,C,w,T,E,D){let O=r(S);if(O[C])return null;let k=S[C]??``;if(E-1>a(k).length)return null;let A=!1,j=!1;for(let e=0;e<T-1;e++)k[e]===`\\`&&A?e++:k[e]===`"`&&!j?A=!A:k[e]==="`"&&!A&&(j=!j);if(A||j)return null;let M=ne(S,C,T,E,D);if(M)return M.content;let N=f(S,C,T,E,D);if(N)return N;let P=m(S,C,T,E,D);if(P)return P;let F=p(S,C,T,E,D);if(F)return F;let tokenAt=(e,t)=>{let n=e+ +(k[e-1]===`@`);return w===t&&T===n&&E===n+t.length&&k.slice(n-1,E-1)===t},I=k.charAt(T-2);if(w===`authorization`&&t(S,O,C,i(k))[0]===`purpose`)return`A quoted authorization in law for criminal-offence data (Art. 10).`;let L=/^\s*concept\s+[^\s:]+\s*:\s*\w+\s+/.exec(k),R=t(S,O,C,i(k))[0]===`concept`&&/^\s*(?:@?pii|personal|@?sensitive|secret)\s+(?:reason|scope|special|criminal)\b/.test(k);if(L!==null&&T-1>=L[0].length-1||R){let e=re[w];if(e)return e;if(Object.hasOwn(b,w)&&/^\s*(?:@?pii|personal)\s+special\s+/.test(k))return`**${w}** — ${b[w]}`;if(w===`special`)return`GDPR Art. 9(1) special category; requires pii. At most one category per concept.`;if(w===`criminal`)return`Personal data relating to criminal convictions and offenses (GDPR Art. 10); requires pii.`;if(/^\s*(?:secret|sensitive|@sensitive)\s+scope\s+/.test(k)&&[`subject`,`namespace`,`global`].includes(w))return`**${w}** — Secret encryption scope${w===`subject`?` per data subject`:w===`namespace`?` per tenant namespace`:` shared globally`}. Not an event-property subject role.`;if(w===`scope`)return`Secret encryption scope: subject, namespace or global. Omitted scope keeps Chronicle’s Subject default; pii secret renders only [PII].`}if(I===`$`||I===`.`){let e=k.substring(0,E-1).match(/\$[\w.]*$/)?.[0];if(e){if(e.startsWith(`$refusal`)){let t=h(S,C,i(k)),n=e.substring(9),r={reason:`Refusal kind as a String: validation, constraint or authorization.`,message:`Rejection details verbatim, including unresolved $strings keys.`,constraint:`Violated constraint name as a String, only in a by constraint branch.`};return t!==void 0&&r[n]!==void 0?`**${e}** — ${r[n]} Syntax-only, not yet executable (PLAY0268).`:null}if(e.startsWith(`$identity.`)){let t=e.substring(10).split(`.`)[0],n=d(S,D).identityDetails?.find(e=>e.name===t);if(n)return`**$identity.${n.name}** — ${n.type}. Declared caller detail; authoring metadata only, not executable until admitted (#600).`}let t=_[e]??(e.startsWith(`$env`)?_.$env:void 0);if(t)return t}}let z=k.slice(0,T-1),B=/^\s*(?:by|filter)\s+/.test(z)?/^\s*(?:by|filter)\s+[a-z_]\w*\s+[\w.]+(?:\[\])?\s+$/.test(z):/^\s*@?[a-z_]\w*\s+[\w.]+(?:\[\])?\s+$/.test(z),V=/^\s*query\s+\w+\s*=>\s*(?:observable\s+)?[\w.]+(?:\[\])?\s+$/.test(z)&&!/^\s*query\s+\w+\s*=>\s*observable\s+$/.test(z);if(w===`subject`){let e=o(S),r=/^\s*@?[a-z_]\w*\s+[\w.]+(?:\[\])?(?:\?|\s+optional)?(?:\s+generated)?(?:\s+identifier)?\s+$/.test(z),a=t(e,O,C,i(k));return r&&(a[0]===`event`||/^produces\s+event\s+/.test(n(e,O,C,i(k))[0]??``))?`**subject** — This event property identifies its one data subject instead of the event source (decision 0008). Required scalar String, Uuid or their concepts, or an Int-backed concept; never pii or secret. Report-only lineage metadata (PLAY0270); no ESM bytes or provider output yet.`:/\bclaim\s+"(?:[^"\\]|\\.)*"\s+matches\s+$/.test(z)&&a.includes(`policy`)?`**subject** — ${y.subject}`:null}if(w===`optional`&&(B||V))return`**optional** — ${y.optional}`;if(w===`implementation`||w===`hint`){let e=t(S,O,C,i(k)),n=g(S,C,i(k));if(w===`implementation`&&n===`rule`&&/^\s*implementation\s*$/.test(a(k))||w===`hint`&&n===`implementation`&&/^\s*hint\s+"/.test(k))return`**${w}** — Command named-rule guidance with at most one file or tagged fence. No payload means pending and fails binding (PLAY0268). Attached predicates keep their existing pure RuleContext contract; reference execution is unsupported, never confirmation.`;if(w===`implementation`&&e[0]===`handler`&&/^\s*implementation\s*$/.test(a(k)))return`**implementation** — ${v.implementation}`;if(w===`hint`&&e[0]===`implementation`&&e[1]===`handler`&&/^\s*hint\s+"/.test(k))return`**hint** — ${v.hint}`}let H=u(S),U=H.commands.filter(e=>e.line<C).at(-1),W=U?.properties.find(e=>e.name===w&&e.line===C);if(W?.isGenerated||w===`generated`&&U?.properties.some(e=>e.isGenerated&&e.line===C)&&B)return`**${W?.name??`generated`}** — ${W?e(l(W))+`. `:``}Generated value, not a request or form input. ${c}`;let G=U?.response;if(G?.location.line===C+1&&(tokenAt(G.location.column,`returns`)||G.kind===`ScalarCommandResponseSyntax`&&tokenAt(G.source.location.column,G.source.property))){let t=G.kind===`ScalarCommandResponseSyntax`?U?.properties.find(e=>e.name===G.source.property):void 0;return`**returns**${t?` — ${e(l(t))}`:` — unnamed record response`}. ${c}`}if(G?.kind===`RecordCommandResponseSyntax`){let t=G.fields.find(e=>e.location.line===C+1&&(tokenAt(e.location.column,e.name)||tokenAt(e.source.location.column,e.source.property)));if(t){let n=U?.properties.find(e=>e.name===t.source.property),r=t.type?e(t.type):n?e(l(n)):`Unresolved type`;return`**${t.name}** — ${r}${t.type?` (explicit)`:` (inferred)`} = ${t.source.property}. ${n?.isGenerated?`Generated source, not request input. `:``}${c}`}}for(let e of s(S).specifications.values())if(w===`returns`&&e.thenReturns?.location.line===C+1||w===`generated`&&e.when?.generatedValues?.some(e=>e.location.line===C+1))return c;let K=H.concepts.find(e=>e.name===w);if(K){let e=K.attributes.length?` ${K.attributes.join(` `)}`:``,t=K.enumValues.length?`\n\nValues: ${K.enumValues.join(`, `)}`:``,n=Object.entries(K.attributeReasons).map(([e,t])=>`\n\n**@${e}** — ${t}`).join(``);return`\`\`\`screenplay\nconcept ${K.name} : ${K.primitive}${e}\n\`\`\`${n}${t}`}let q=H.types.find(e=>e.name===w);if(q){let t=q.properties.map(t=>`${t.name} ${e(l(t))}`).join(`
|
|
1
|
+
import"./_virtual/_virtual/_rolldown/runtime.js";import{typeReferenceText as e}from"./TypeReferenceSymbol.js";import{enclosingChain as t,enclosingHeaders as n,fenceMap as r,indentOf as i,withoutComment as a}from"./document-context.js";import{eventAnalysisSource as o}from"./event-analysis-source.js";import{responseAnalysis as s,responseAvailability as c}from"./response-analysis.js";import{directBody as ee,propertyTypeReference as l,scanDocument as u,symbolsForBuffer as d}from"./symbols.js";import{exampleHover as f}from"./example-authoring.js";import{operationHover as p}from"./operation-authoring.js";import{eventSourceHover as m}from"./event-source-authoring.js";import{refusalContext as h}from"./refusal-context.js";import{namedRuleContext as g}from"./named-rule-context.js";import{getSubLanguage as te}from"./sub-language-registry.js";import{reactionReferenceAt as ne}from"./reaction-authoring.js";import{attributeDocs as re,contextVariableDocs as _,handlerIntentDocs as v,keywordDocs as y,specialCategoryDocs as b,specificationKeywordDocs as x}from"./keyword-docs.js";function hoverContent(S,C,w,T,E,D){let O=r(S);if(O[C])return null;let k=S[C]??``;if(E-1>a(k).length)return null;let A=!1,j=!1;for(let e=0;e<T-1;e++)k[e]===`\\`&&A?e++:k[e]===`"`&&!j?A=!A:k[e]==="`"&&!A&&(j=!j);if(A||j)return null;let M=ne(S,C,T,E,D);if(M)return M.content;let N=f(S,C,T,E,D);if(N)return N;let P=m(S,C,T,E,D);if(P)return P;let F=p(S,C,T,E,D);if(F)return F;let tokenAt=(e,t)=>{let n=e+ +(k[e-1]===`@`);return w===t&&T===n&&E===n+t.length&&k.slice(n-1,E-1)===t},I=k.charAt(T-2);if(w===`authorization`&&t(S,O,C,i(k))[0]===`purpose`)return`A quoted authorization in law for criminal-offence data (Art. 10).`;let L=/^\s*concept\s+[^\s:]+\s*:\s*\w+\s+/.exec(k),R=t(S,O,C,i(k))[0]===`concept`&&/^\s*(?:@?pii|personal|@?sensitive|secret)\s+(?:reason|scope|special|criminal)\b/.test(k);if(L!==null&&T-1>=L[0].length-1||R){let e=re[w];if(e)return e;if(Object.hasOwn(b,w)&&/^\s*(?:@?pii|personal)\s+special\s+/.test(k))return`**${w}** — ${b[w]}`;if(w===`special`)return`GDPR Art. 9(1) special category; requires pii. At most one category per concept.`;if(w===`criminal`)return`Personal data relating to criminal convictions and offenses (GDPR Art. 10); requires pii.`;if(/^\s*(?:secret|sensitive|@sensitive)\s+scope\s+/.test(k)&&[`subject`,`namespace`,`global`].includes(w))return`**${w}** — Secret encryption scope${w===`subject`?` per data subject`:w===`namespace`?` per tenant namespace`:` shared globally`}. Not an event-property subject role.`;if(w===`scope`)return`Secret encryption scope: subject, namespace or global. Omitted scope keeps Chronicle’s Subject default; pii secret renders only [PII].`}if(I===`$`||I===`.`){let e=k.substring(0,E-1).match(/\$[\w.]*$/)?.[0];if(e){if(e.startsWith(`$refusal`)){let t=h(S,C,i(k)),n=e.substring(9),r={reason:`Refusal kind as a String: validation, constraint or authorization.`,message:`Rejection details verbatim, including unresolved $strings keys.`,constraint:`Violated constraint name as a String, only in a by constraint branch.`};return t!==void 0&&r[n]!==void 0?`**${e}** — ${r[n]} Syntax-only, not yet executable (PLAY0268).`:null}if(e.startsWith(`$identity.`)){let t=e.substring(10).split(`.`)[0],n=d(S,D).identityDetails?.find(e=>e.name===t);if(n)return`**$identity.${n.name}** — ${n.type}. Declared caller detail; authoring metadata only, not executable until admitted (#600).`}let t=_[e]??(e.startsWith(`$env`)?_.$env:void 0);if(t)return t}}let z=k.slice(0,T-1),B=/^\s*(?:by|filter)\s+/.test(z)?/^\s*(?:by|filter)\s+[a-z_]\w*\s+[\w.]+(?:\[\])?\s+$/.test(z):/^\s*@?[a-z_]\w*\s+[\w.]+(?:\[\])?\s+$/.test(z),V=/^\s*query\s+\w+\s*=>\s*(?:observable\s+)?[\w.]+(?:\[\])?\s+$/.test(z)&&!/^\s*query\s+\w+\s*=>\s*observable\s+$/.test(z);if(w===`subject`){let e=o(S),r=/^\s*@?[a-z_]\w*\s+[\w.]+(?:\[\])?(?:\?|\s+optional)?(?:\s+generated)?(?:\s+identifier)?\s+$/.test(z),a=t(e,O,C,i(k));return r&&(a[0]===`event`||/^produces\s+event\s+/.test(n(e,O,C,i(k))[0]??``))?`**subject** — This event property identifies its one data subject instead of the event source (decision 0008). Required scalar String, Uuid or their concepts, or an Int-backed concept; never pii or secret. Report-only lineage metadata (PLAY0270); no ESM bytes or provider output yet.`:/\bclaim\s+"(?:[^"\\]|\\.)*"\s+matches\s+$/.test(z)&&a.includes(`policy`)?`**subject** — ${y.subject}`:null}if(w===`optional`&&(B||V))return`**optional** — ${y.optional}`;if(w===`implementation`||w===`hint`){let e=t(S,O,C,i(k)),n=g(S,C,i(k));if(w===`implementation`&&n===`rule`&&/^\s*implementation\s*$/.test(a(k))||w===`hint`&&n===`implementation`&&/^\s*hint\s+"/.test(k))return`**${w}** — Command named-rule guidance with at most one file or tagged fence. No payload means pending and fails binding (PLAY0268). Attached predicates keep their existing pure RuleContext contract; reference execution is unsupported, never confirmation.`;if(w===`implementation`&&e[0]===`handler`&&/^\s*implementation\s*$/.test(a(k)))return`**implementation** — ${v.implementation}`;if(w===`hint`&&e[0]===`implementation`&&e[1]===`handler`&&/^\s*hint\s+"/.test(k))return`**hint** — ${v.hint}`}let H=u(S),U=H.commands.filter(e=>e.line<C).at(-1),W=U?.properties.find(e=>e.name===w&&e.line===C);if(W?.isGenerated||w===`generated`&&U?.properties.some(e=>e.isGenerated&&e.line===C)&&B)return`**${W?.name??`generated`}** — ${W?e(l(W))+`. `:``}Generated value, not a request or form input. ${c}`;let G=U?.response;if(G?.location.line===C+1&&(tokenAt(G.location.column,`returns`)||G.kind===`ScalarCommandResponseSyntax`&&tokenAt(G.source.location.column,G.source.property))){let t=G.kind===`ScalarCommandResponseSyntax`?U?.properties.find(e=>e.name===G.source.property):void 0;return`**returns**${t?` — ${e(l(t))}`:` — unnamed record response`}. ${c}`}if(G?.kind===`RecordCommandResponseSyntax`){let t=G.fields.find(e=>e.location.line===C+1&&(tokenAt(e.location.column,e.name)||tokenAt(e.source.location.column,e.source.property)));if(t){let n=U?.properties.find(e=>e.name===t.source.property),r=t.type?e(t.type):n?e(l(n)):`Unresolved type`;return`**${t.name}** — ${r}${t.type?` (explicit)`:` (inferred)`} = ${t.source.property}. ${n?.isGenerated?`Generated source, not request input. `:``}${c}`}}for(let e of s(S).specifications.values())if(w===`returns`&&e.thenReturns?.location.line===C+1||w===`generated`&&e.when?.generatedValues?.some(e=>e.location.line===C+1))return c;let K=H.concepts.find(e=>e.name===w);if(K){let e=K.attributes.length?` ${K.attributes.join(` `)}`:``,t=K.enumValues.length?`\n\nValues: ${K.enumValues.map((e,t)=>K.enumNumbers===void 0?e:`${e} = ${K.enumNumbers[t]}`).join(`, `)}`:``,n=Object.entries(K.attributeReasons).map(([e,t])=>`\n\n**@${e}** — ${t}`).join(``);return`\`\`\`screenplay\nconcept ${K.name} : ${K.primitive}${e}\n\`\`\`${n}${t}`}let q=H.types.find(e=>e.name===w);if(q){let t=q.properties.map(t=>`${t.name} ${e(l(t))}`).join(`
|
|
2
2
|
`);return`\`\`\`screenplay\ntype ${q.name}\n${t}\n\`\`\``}let J=H.policies.find(e=>e.name===w);if(J){let e=J.requires.length?J.requires.join(`
|
|
3
3
|
`):`(custom C#)`;return`\`\`\`screenplay\npolicy ${J.name}\n${e}\n\`\`\``}let Y=H.events.find(e=>e.name===w&&e.line===C)??H.events.filter(e=>e.name===w).sort((e,t)=>(t.generation??1)-(e.generation??1))[0];if(Y){let t=Y.properties.map(t=>`${t.name} ${e(l(t))}${t.isSubject?` subject`:``}`).join(`
|
|
4
4
|
`);return`\`\`\`screenplay\n${Y.visibility===`Public`?`public `:``}event ${Y.name}${Y.generation===void 0?``:` generation ${Y.generation}`}${Y.origin===void 0?``:` from ${JSON.stringify(Y.origin)}`}\n${t}\n\`\`\``}let X=H.commands.find(e=>e.name===w);if(X&&X.properties.length>0){let t=X.properties.map(t=>`${t.name} ${e(l(t))}${t.isGenerated?` generated`:``}${t.isIdentifier?` identifier`:``}`).join(`
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"hover-content.js","names":["fences","fenceMap","lines","lineIndex","line","endColumn","withoutComment","inString","inTemplate","index","startColumn","reaction","reactionReferenceAt","application","fixtureHover","exampleHover","sourceHover","eventSourceHover","operation","operationHover","start","column","word","name","before","enclosingChain","indentOf","complianceHeader","complianceBody","doc","attributeDocs","specialCategoryDocs","variable","branch","refusalContext","member","descriptions","detail","symbolsForBuffer","contextVariableDocs","\"$env\"","prefix","followsPropertyType","followsQueryType","source","eventAnalysisSource","subjectPrefix","ownerChain","enclosingHeaders","keywordDocs","chain","ruleContext","namedRuleContext","handlerIntentDocs","symbols","scanDocument","owner","command","property","typeReferenceText","propertyTypeReference","responseAvailability","response","field","type","specification","responseAnalysis","value","concept","candidate","attributes","values","reasons","attribute","reason","properties","policy","body","event","right","left","construct","getSubLanguage","step","specificationKeywordDocs","inEvent","directBody","directive","keywordDoc"],"sources":["../../hover-content.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 { reactionReferenceAt } from './reaction-authoring';\nimport { refusalContext } from './refusal-context';\nimport { namedRuleContext } from './named-rule-context';\nimport { eventSourceHover } from './event-source-authoring';\nimport { exampleHover } from './example-authoring';\nimport { operationHover } from './operation-authoring';\nimport { DocumentSymbols, symbolsForBuffer } from './symbols';\nimport { responseAnalysis, responseAvailability } from './response-analysis';\nimport { enclosingChain, enclosingHeaders, fenceMap, indentOf, withoutComment } from './document-context';\nimport { directBody, propertyTypeReference, scanDocument } from './symbols';\nimport { typeReferenceText } from './TypeReferenceSymbol';\nimport { eventAnalysisSource } from './event-analysis-source';\nimport { getSubLanguage } from './sub-language-registry';\nimport { attributeDocs, contextVariableDocs, handlerIntentDocs, keywordDocs, specialCategoryDocs, specificationKeywordDocs } from './keyword-docs';\n\n// Produces the hover markdown for a word at a position, without any editor\n// dependency — the Monaco service and the VSCode extension share this content.\n// Columns are 1-based, matching both editors' word-at-position APIs.\nexport function hoverContent(\n lines: string[],\n lineIndex: number,\n word: string,\n startColumn: number,\n endColumn: number,\n application?: DocumentSymbols,\n): string | null {\n const fences = fenceMap(lines);\n if (fences[lineIndex]) return null;\n\n const line = lines[lineIndex] ?? '';\n if (endColumn - 1 > withoutComment(line).length) return null;\n let inString = false;\n let inTemplate = false;\n for (let index = 0; index < startColumn - 1; index++) {\n if (line[index] === '\\\\' && inString) index++;\n else if (line[index] === '\"' && !inTemplate) inString = !inString;\n else if (line[index] === '`' && !inString) inTemplate = !inTemplate;\n }\n if (inString || inTemplate) return null;\n const reaction = reactionReferenceAt(lines, lineIndex, startColumn, endColumn, application);\n if (reaction) return reaction.content;\n const fixtureHover = exampleHover(lines, lineIndex, startColumn, endColumn, application);\n if (fixtureHover) return fixtureHover;\n const sourceHover = eventSourceHover(lines, lineIndex, startColumn, endColumn, application);\n if (sourceHover) return sourceHover;\n const operation = operationHover(lines, lineIndex, startColumn, endColumn, application);\n if (operation) return operation;\n const tokenAt = (column: number, name: string): boolean => {\n const start = column + (line[column - 1] === '@' ? 1 : 0);\n return word === name && startColumn === start && endColumn === start + name.length && line.slice(start - 1, endColumn - 1) === name;\n };\n const before = line.charAt(startColumn - 2);\n if (word === 'authorization' && enclosingChain(lines, fences, lineIndex, indentOf(line))[0] === 'purpose') return 'A quoted authorization in law for criminal-offence data (Art. 10).';\n\n const complianceHeader = /^\\s*concept\\s+[^\\s:]+\\s*:\\s*\\w+\\s+/.exec(line);\n const complianceBody = enclosingChain(lines, fences, lineIndex, indentOf(line))[0] === 'concept' && /^\\s*(?:@?pii|personal|@?sensitive|secret)\\s+(?:reason|scope|special|criminal)\\b/.test(line);\n if ((complianceHeader !== null && startColumn - 1 >= complianceHeader[0].length - 1) || complianceBody) {\n const doc = attributeDocs[word];\n if (doc) return doc;\n if (Object.hasOwn(specialCategoryDocs, word) && /^\\s*(?:@?pii|personal)\\s+special\\s+/.test(line)) return `**${word}** — ${specialCategoryDocs[word]}`;\n if (word === 'special') return 'GDPR Art. 9(1) special category; requires pii. At most one category per concept.';\n if (word === 'criminal') return 'Personal data relating to criminal convictions and offenses (GDPR Art. 10); requires pii.';\n if (/^\\s*(?:secret|sensitive|@sensitive)\\s+scope\\s+/.test(line) && ['subject', 'namespace', 'global'].includes(word)) return `**${word}** — Secret encryption scope${word === 'subject' ? ' per data subject' : word === 'namespace' ? ' per tenant namespace' : ' shared globally'}. Not an event-property subject role.`;\n if (word === 'scope') return 'Secret encryption scope: subject, namespace or global. Omitted scope keeps Chronicle’s Subject default; pii secret renders only [PII].';\n }\n if (before === '$' || before === '.') {\n const variable = line.substring(0, endColumn - 1).match(/\\$[\\w.]*$/)?.[0];\n if (variable) {\n if (variable.startsWith('$refusal')) {\n const branch = refusalContext(lines, lineIndex, indentOf(line));\n const member = variable.substring('$refusal.'.length);\n const descriptions: Record<string, string> = { reason: 'Refusal kind as a String: validation, constraint or authorization.', message: 'Rejection details verbatim, including unresolved $strings keys.', constraint: 'Violated constraint name as a String, only in a by constraint branch.' };\n return branch !== undefined && descriptions[member] !== undefined ? `**${variable}** — ${descriptions[member]} Syntax-only, not yet executable (PLAY0268).` : null;\n }\n if (variable.startsWith('$identity.')) {\n const name = variable.substring('$identity.'.length).split('.')[0];\n const detail = symbolsForBuffer(lines, application).identityDetails?.find(detail => detail.name === name);\n if (detail) return `**$identity.${detail.name}** — ${detail.type}. Declared caller detail; authoring metadata only, not executable until admitted (#600).`;\n }\n const doc =\n contextVariableDocs[variable] ??\n (variable.startsWith('$env') ? contextVariableDocs['$env'] : undefined);\n if (doc) return doc;\n }\n }\n\n // Do not mistake a property/type named optional for the contextual modifier.\n const prefix = line.slice(0, startColumn - 1);\n // Commit to query-parameter context before matching the name and type.\n const followsPropertyType = /^\\s*(?:by|filter)\\s+/.test(prefix)\n ? /^\\s*(?:by|filter)\\s+[a-z_]\\w*\\s+[\\w.]+(?:\\[\\])?\\s+$/.test(prefix)\n : /^\\s*@?[a-z_]\\w*\\s+[\\w.]+(?:\\[\\])?\\s+$/.test(prefix);\n const followsQueryType = /^\\s*query\\s+\\w+\\s*=>\\s*(?:observable\\s+)?[\\w.]+(?:\\[\\])?\\s+$/.test(prefix) &&\n !/^\\s*query\\s+\\w+\\s*=>\\s*observable\\s+$/.test(prefix);\n if (word === 'subject') {\n const source = eventAnalysisSource(lines);\n const subjectPrefix = /^\\s*@?[a-z_]\\w*\\s+[\\w.]+(?:\\[\\])?(?:\\?|\\s+optional)?(?:\\s+generated)?(?:\\s+identifier)?\\s+$/.test(prefix);\n const ownerChain = enclosingChain(source, fences, lineIndex, indentOf(line));\n if (subjectPrefix && (ownerChain[0] === 'event' || /^produces\\s+event\\s+/.test(enclosingHeaders(source, fences, lineIndex, indentOf(line))[0] ?? ''))) {\n return '**subject** — This event property identifies its one data subject instead of the event source (decision 0008). Required scalar String, Uuid or their concepts, or an Int-backed concept; never pii or secret. Report-only lineage metadata (PLAY0270); no ESM bytes or provider output yet.';\n }\n if (/\\bclaim\\s+\"(?:[^\"\\\\]|\\\\.)*\"\\s+matches\\s+$/.test(prefix) && ownerChain.includes('policy')) return `**subject** — ${keywordDocs.subject}`;\n return null;\n }\n if (word === 'optional' && (followsPropertyType || followsQueryType)) {\n return `**optional** — ${keywordDocs.optional}`;\n }\n\n if (word === 'implementation' || word === 'hint') {\n const chain = enclosingChain(lines, fences, lineIndex, indentOf(line));\n const ruleContext = namedRuleContext(lines, lineIndex, indentOf(line));\n if ((word === 'implementation' && ruleContext === 'rule' && /^\\s*implementation\\s*$/.test(withoutComment(line))) ||\n (word === 'hint' && ruleContext === 'implementation' && /^\\s*hint\\s+\"/.test(line))) {\n return `**${word}** — Command named-rule guidance with at most one file or tagged fence. No payload means pending and fails binding (PLAY0268). Attached predicates keep their existing pure RuleContext contract; reference execution is unsupported, never confirmation.`;\n }\n if (word === 'implementation' && chain[0] === 'handler' && /^\\s*implementation\\s*$/.test(withoutComment(line))) {\n return `**implementation** — ${handlerIntentDocs.implementation}`;\n }\n if (word === 'hint' && chain[0] === 'implementation' && chain[1] === 'handler' && /^\\s*hint\\s+\"/.test(line)) {\n return `**hint** — ${handlerIntentDocs.hint}`;\n }\n }\n\n const symbols = scanDocument(lines);\n const owner = symbols.commands.filter(command => command.line < lineIndex).at(-1);\n const property = owner?.properties.find(property => property.name === word && property.line === lineIndex);\n if (property?.isGenerated || (word === 'generated' && owner?.properties.some(property => property.isGenerated && property.line === lineIndex) && followsPropertyType)) {\n return `**${property?.name ?? 'generated'}** — ${property ? typeReferenceText(propertyTypeReference(property)) + '. ' : ''}Generated value, not a request or form input. ${responseAvailability}`;\n }\n const response = owner?.response;\n if (response?.location.line === lineIndex + 1 && (tokenAt(response.location.column, 'returns') || (response.kind === 'ScalarCommandResponseSyntax' && tokenAt(response.source.location.column, response.source.property)))) {\n const source = response.kind === 'ScalarCommandResponseSyntax' ? owner?.properties.find(property => property.name === response.source.property) : undefined;\n return `**returns**${source ? ` — ${typeReferenceText(propertyTypeReference(source))}` : ' — unnamed record response'}. ${responseAvailability}`;\n }\n if (response?.kind === 'RecordCommandResponseSyntax') {\n const field = response.fields.find(field => field.location.line === lineIndex + 1 && (tokenAt(field.location.column, field.name) || tokenAt(field.source.location.column, field.source.property)));\n if (field) {\n const source = owner?.properties.find(property => property.name === field.source.property);\n const type = field.type ? typeReferenceText(field.type) : source ? typeReferenceText(propertyTypeReference(source)) : 'Unresolved type';\n return `**${field.name}** — ${type}${field.type ? ' (explicit)' : ' (inferred)'} = ${field.source.property}. ${source?.isGenerated ? 'Generated source, not request input. ' : ''}${responseAvailability}`;\n }\n }\n for (const specification of responseAnalysis(lines).specifications.values()) {\n if ((word === 'returns' && specification.thenReturns?.location.line === lineIndex + 1) || (word === 'generated' && specification.when?.generatedValues?.some(value => value.location.line === lineIndex + 1))) return responseAvailability;\n }\n\n const concept = symbols.concepts.find((candidate) => candidate.name === word);\n if (concept) {\n const attributes = concept.attributes.length ? ` ${concept.attributes.join(' ')}` : '';\n const values = concept.enumValues.length\n ? `\\n\\nValues: ${concept.enumValues.join(', ')}`\n : '';\n const reasons = Object.entries(concept.attributeReasons)\n .map(([attribute, reason]) => `\\n\\n**@${attribute}** — ${reason}`)\n .join('');\n return `\\`\\`\\`screenplay\\nconcept ${concept.name} : ${concept.primitive}${attributes}\\n\\`\\`\\`${reasons}${values}`;\n }\n\n const type = symbols.types.find((candidate) => candidate.name === word);\n if (type) {\n const properties = type.properties\n .map((property) => `${property.name} ${typeReferenceText(propertyTypeReference(property))}`)\n .join('\\n');\n return `\\`\\`\\`screenplay\\ntype ${type.name}\\n${properties}\\n\\`\\`\\``;\n }\n\n const policy = symbols.policies.find((candidate) => candidate.name === word);\n if (policy) {\n const body = policy.requires.length ? policy.requires.join('\\n') : '(custom C#)';\n return `\\`\\`\\`screenplay\\npolicy ${policy.name}\\n${body}\\n\\`\\`\\``;\n }\n\n const event = symbols.events.find((candidate) => candidate.name === word && candidate.line === lineIndex) ??\n symbols.events.filter((candidate) => candidate.name === word)\n .sort((left, right) => (right.generation ?? 1) - (left.generation ?? 1))[0];\n if (event) {\n const properties = event.properties\n .map((property) => `${property.name} ${typeReferenceText(propertyTypeReference(property))}${property.isSubject ? ' subject' : ''}`)\n .join('\\n');\n return `\\`\\`\\`screenplay\\n${event.visibility === 'Public' ? 'public ' : ''}event ${event.name}${event.generation !== undefined ? ` generation ${event.generation}` : ''}${event.origin !== undefined ? ` from ${JSON.stringify(event.origin)}` : ''}\\n${properties}\\n\\`\\`\\``;\n }\n\n const command = symbols.commands.find((candidate) => candidate.name === word);\n if (command && command.properties.length > 0) {\n const properties = command.properties\n .map(\n (property) =>\n `${property.name} ${typeReferenceText(propertyTypeReference(property))}${property.isGenerated ? ' generated' : ''}${property.isIdentifier ? ' identifier' : ''}`,\n )\n .join('\\n');\n return `\\`\\`\\`screenplay\\ncommand ${command.name}\\n${properties}\\n\\`\\`\\`${command.response || command.properties.some(property => property.isGenerated) ? `\\n\\n${responseAvailability}` : ''}`;\n }\n\n // Sub-language keywords take precedence inside their construct.\n const chain = enclosingChain(lines, fences, lineIndex, indentOf(line));\n for (const construct of [line.trim().split(/\\s+/)[0], ...chain]) {\n const subLanguage = getSubLanguage(construct ?? '');\n const doc = subLanguage?.hovers?.[word];\n if (doc) return doc;\n }\n\n if (word === 'reads' && (chain[0] === 'every' || chain[0] === 'at') && chain.includes('reaction')) {\n return '**reads** — Declares a whole view this clock trigger consults: `reads <View>`. Clock triggers take no values, so `by` is unavailable.';\n }\n\n const step = line.trim().match(/^(given|when|then)\\s+(?:no\\s+)?(\\w+)/);\n if (step && step[2] === word && chain[0] === 'specification' && specificationKeywordDocs[word]) {\n return `**${word}** — ${specificationKeywordDocs[word]}`;\n }\n\n if (word === 'id' || word === 'documentation') {\n const source = eventAnalysisSource(lines);\n const inEvent = symbols.events.some(event => directBody(source, fences, event.line, indentOf(source[event.line])).includes(lineIndex));\n const directive = word === 'id' ? /^\\s*id\\s+\"/.test(source[lineIndex]) : /^\\s*documentation\\s*$/.test(source[lineIndex]);\n const supportedOwner = inEvent || (word === 'documentation' && ['module', 'feature', 'slice', 'command', 'readmodel', 'reaction'].includes(chain[0]));\n if (!supportedOwner || !directive || startColumn !== indentOf(line) + 1) return null;\n }\n\n if (word === 'optional' || word === 'generated' || word === 'returns') return null;\n const keywordDoc = keywordDocs[word];\n if (keywordDoc) return `**${word}** — ${keywordDoc}`;\n\n return null;\n}\n"],"mappings":"qjCAqBA,SAAgB,aACZ,EACA,EACA,EACA,EACA,EACA,EACa,CACb,IAAMA,EAASC,EAASC,CAAK,EAC7B,GAAIF,EAAOG,GAAY,OAAO,KAE9B,IAAMC,EAAOF,EAAMC,IAAc,GACjC,GAAIE,EAAY,EAAIC,EAAeF,CAAI,CAAC,CAAC,OAAQ,OAAO,KACxD,IAAIG,EAAW,GACXC,EAAa,GACjB,IAAK,IAAIC,EAAQ,EAAGA,EAAQC,EAAc,EAAG,IACrCN,EAAKK,KAAW,MAAQF,EAAU,IAC7BH,EAAKK,KAAW,KAAO,CAACD,EAAY,EAAW,CAACD,EAChDH,EAAKK,KAAW,KAAO,CAACF,IAAU,EAAa,CAACC,GAE7D,GAAID,GAAYC,EAAY,OAAO,KACnC,IAAMG,EAAWC,GAAoBV,EAAOC,EAAWO,EAAaL,EAAWQ,CAAW,EAC1F,GAAIF,EAAU,OAAOA,EAAS,QAC9B,IAAMG,EAAeC,EAAab,EAAOC,EAAWO,EAAaL,EAAWQ,CAAW,EACvF,GAAIC,EAAc,OAAOA,EACzB,IAAME,EAAcC,EAAiBf,EAAOC,EAAWO,EAAaL,EAAWQ,CAAW,EAC1F,GAAIG,EAAa,OAAOA,EACxB,IAAME,EAAYC,EAAejB,EAAOC,EAAWO,EAAaL,EAAWQ,CAAW,EACtF,GAAIK,EAAW,OAAOA,EACtB,IAAM,SAAW,EAAgB,IAA0B,CACvD,IAAME,EAAQC,GAAU,IAAKA,EAAS,KAAO,KAC7C,OAAOC,IAASC,GAAQb,IAAgBU,GAASf,IAAce,EAAQG,EAAK,QAAUnB,EAAK,MAAMgB,EAAQ,EAAGf,EAAY,CAAC,IAAMkB,CACnI,EACMC,EAASpB,EAAK,OAAOM,EAAc,CA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C,EAAU,EAEvH,GAAI,EADmBkF,GAAY/D,IAAS,iBAAmB,CAAC,SAAU,UAAW,QAAS,UAAW,YAAa,UAAU,CAAC,CAAC,SAAS4B,EAAM,EAAE,IAC5H,CAACqC,GAAa7E,IAAgBgB,EAAStB,CAAI,EAAI,EAAG,OAAO,IACpF,CAEA,GAAIkB,IAAS,YAAcA,IAAS,aAAeA,IAAS,UAAW,OAAO,KAC9E,IAAMkE,EAAavC,EAAY3B,GAG/B,OAFIkE,EAAmB,KAAKlE,EAAK,OAAOkE,IAEjC,IACX"}
|
|
1
|
+
{"version":3,"file":"hover-content.js","names":["fences","fenceMap","lines","lineIndex","line","endColumn","withoutComment","inString","inTemplate","index","startColumn","reaction","reactionReferenceAt","application","fixtureHover","exampleHover","sourceHover","eventSourceHover","operation","operationHover","start","column","word","name","before","enclosingChain","indentOf","complianceHeader","complianceBody","doc","attributeDocs","specialCategoryDocs","variable","branch","refusalContext","member","descriptions","detail","symbolsForBuffer","contextVariableDocs","\"$env\"","prefix","followsPropertyType","followsQueryType","source","eventAnalysisSource","subjectPrefix","ownerChain","enclosingHeaders","keywordDocs","chain","ruleContext","namedRuleContext","handlerIntentDocs","symbols","scanDocument","owner","command","property","typeReferenceText","propertyTypeReference","responseAvailability","response","field","type","specification","responseAnalysis","value","concept","candidate","attributes","values","reasons","attribute","reason","properties","policy","body","event","right","left","construct","getSubLanguage","step","specificationKeywordDocs","inEvent","directBody","directive","keywordDoc"],"sources":["../../hover-content.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 { reactionReferenceAt } from './reaction-authoring';\nimport { refusalContext } from './refusal-context';\nimport { namedRuleContext } from './named-rule-context';\nimport { eventSourceHover } from './event-source-authoring';\nimport { exampleHover } from './example-authoring';\nimport { operationHover } from './operation-authoring';\nimport { DocumentSymbols, symbolsForBuffer } from './symbols';\nimport { responseAnalysis, responseAvailability } from './response-analysis';\nimport { enclosingChain, enclosingHeaders, fenceMap, indentOf, withoutComment } from './document-context';\nimport { directBody, propertyTypeReference, scanDocument } from './symbols';\nimport { typeReferenceText } from './TypeReferenceSymbol';\nimport { eventAnalysisSource } from './event-analysis-source';\nimport { getSubLanguage } from './sub-language-registry';\nimport { attributeDocs, contextVariableDocs, handlerIntentDocs, keywordDocs, specialCategoryDocs, specificationKeywordDocs } from './keyword-docs';\n\n// Produces the hover markdown for a word at a position, without any editor\n// dependency — the Monaco service and the VSCode extension share this content.\n// Columns are 1-based, matching both editors' word-at-position APIs.\nexport function hoverContent(\n lines: string[],\n lineIndex: number,\n word: string,\n startColumn: number,\n endColumn: number,\n application?: DocumentSymbols,\n): string | null {\n const fences = fenceMap(lines);\n if (fences[lineIndex]) return null;\n\n const line = lines[lineIndex] ?? '';\n if (endColumn - 1 > withoutComment(line).length) return null;\n let inString = false;\n let inTemplate = false;\n for (let index = 0; index < startColumn - 1; index++) {\n if (line[index] === '\\\\' && inString) index++;\n else if (line[index] === '\"' && !inTemplate) inString = !inString;\n else if (line[index] === '`' && !inString) inTemplate = !inTemplate;\n }\n if (inString || inTemplate) return null;\n const reaction = reactionReferenceAt(lines, lineIndex, startColumn, endColumn, application);\n if (reaction) return reaction.content;\n const fixtureHover = exampleHover(lines, lineIndex, startColumn, endColumn, application);\n if (fixtureHover) return fixtureHover;\n const sourceHover = eventSourceHover(lines, lineIndex, startColumn, endColumn, application);\n if (sourceHover) return sourceHover;\n const operation = operationHover(lines, lineIndex, startColumn, endColumn, application);\n if (operation) return operation;\n const tokenAt = (column: number, name: string): boolean => {\n const start = column + (line[column - 1] === '@' ? 1 : 0);\n return word === name && startColumn === start && endColumn === start + name.length && line.slice(start - 1, endColumn - 1) === name;\n };\n const before = line.charAt(startColumn - 2);\n if (word === 'authorization' && enclosingChain(lines, fences, lineIndex, indentOf(line))[0] === 'purpose') return 'A quoted authorization in law for criminal-offence data (Art. 10).';\n\n const complianceHeader = /^\\s*concept\\s+[^\\s:]+\\s*:\\s*\\w+\\s+/.exec(line);\n const complianceBody = enclosingChain(lines, fences, lineIndex, indentOf(line))[0] === 'concept' && /^\\s*(?:@?pii|personal|@?sensitive|secret)\\s+(?:reason|scope|special|criminal)\\b/.test(line);\n if ((complianceHeader !== null && startColumn - 1 >= complianceHeader[0].length - 1) || complianceBody) {\n const doc = attributeDocs[word];\n if (doc) return doc;\n if (Object.hasOwn(specialCategoryDocs, word) && /^\\s*(?:@?pii|personal)\\s+special\\s+/.test(line)) return `**${word}** — ${specialCategoryDocs[word]}`;\n if (word === 'special') return 'GDPR Art. 9(1) special category; requires pii. At most one category per concept.';\n if (word === 'criminal') return 'Personal data relating to criminal convictions and offenses (GDPR Art. 10); requires pii.';\n if (/^\\s*(?:secret|sensitive|@sensitive)\\s+scope\\s+/.test(line) && ['subject', 'namespace', 'global'].includes(word)) return `**${word}** — Secret encryption scope${word === 'subject' ? ' per data subject' : word === 'namespace' ? ' per tenant namespace' : ' shared globally'}. Not an event-property subject role.`;\n if (word === 'scope') return 'Secret encryption scope: subject, namespace or global. Omitted scope keeps Chronicle’s Subject default; pii secret renders only [PII].';\n }\n if (before === '$' || before === '.') {\n const variable = line.substring(0, endColumn - 1).match(/\\$[\\w.]*$/)?.[0];\n if (variable) {\n if (variable.startsWith('$refusal')) {\n const branch = refusalContext(lines, lineIndex, indentOf(line));\n const member = variable.substring('$refusal.'.length);\n const descriptions: Record<string, string> = { reason: 'Refusal kind as a String: validation, constraint or authorization.', message: 'Rejection details verbatim, including unresolved $strings keys.', constraint: 'Violated constraint name as a String, only in a by constraint branch.' };\n return branch !== undefined && descriptions[member] !== undefined ? `**${variable}** — ${descriptions[member]} Syntax-only, not yet executable (PLAY0268).` : null;\n }\n if (variable.startsWith('$identity.')) {\n const name = variable.substring('$identity.'.length).split('.')[0];\n const detail = symbolsForBuffer(lines, application).identityDetails?.find(detail => detail.name === name);\n if (detail) return `**$identity.${detail.name}** — ${detail.type}. Declared caller detail; authoring metadata only, not executable until admitted (#600).`;\n }\n const doc =\n contextVariableDocs[variable] ??\n (variable.startsWith('$env') ? contextVariableDocs['$env'] : undefined);\n if (doc) return doc;\n }\n }\n\n // Do not mistake a property/type named optional for the contextual modifier.\n const prefix = line.slice(0, startColumn - 1);\n // Commit to query-parameter context before matching the name and type.\n const followsPropertyType = /^\\s*(?:by|filter)\\s+/.test(prefix)\n ? /^\\s*(?:by|filter)\\s+[a-z_]\\w*\\s+[\\w.]+(?:\\[\\])?\\s+$/.test(prefix)\n : /^\\s*@?[a-z_]\\w*\\s+[\\w.]+(?:\\[\\])?\\s+$/.test(prefix);\n const followsQueryType = /^\\s*query\\s+\\w+\\s*=>\\s*(?:observable\\s+)?[\\w.]+(?:\\[\\])?\\s+$/.test(prefix) &&\n !/^\\s*query\\s+\\w+\\s*=>\\s*observable\\s+$/.test(prefix);\n if (word === 'subject') {\n const source = eventAnalysisSource(lines);\n const subjectPrefix = /^\\s*@?[a-z_]\\w*\\s+[\\w.]+(?:\\[\\])?(?:\\?|\\s+optional)?(?:\\s+generated)?(?:\\s+identifier)?\\s+$/.test(prefix);\n const ownerChain = enclosingChain(source, fences, lineIndex, indentOf(line));\n if (subjectPrefix && (ownerChain[0] === 'event' || /^produces\\s+event\\s+/.test(enclosingHeaders(source, fences, lineIndex, indentOf(line))[0] ?? ''))) {\n return '**subject** — This event property identifies its one data subject instead of the event source (decision 0008). Required scalar String, Uuid or their concepts, or an Int-backed concept; never pii or secret. Report-only lineage metadata (PLAY0270); no ESM bytes or provider output yet.';\n }\n if (/\\bclaim\\s+\"(?:[^\"\\\\]|\\\\.)*\"\\s+matches\\s+$/.test(prefix) && ownerChain.includes('policy')) return `**subject** — ${keywordDocs.subject}`;\n return null;\n }\n if (word === 'optional' && (followsPropertyType || followsQueryType)) {\n return `**optional** — ${keywordDocs.optional}`;\n }\n\n if (word === 'implementation' || word === 'hint') {\n const chain = enclosingChain(lines, fences, lineIndex, indentOf(line));\n const ruleContext = namedRuleContext(lines, lineIndex, indentOf(line));\n if ((word === 'implementation' && ruleContext === 'rule' && /^\\s*implementation\\s*$/.test(withoutComment(line))) ||\n (word === 'hint' && ruleContext === 'implementation' && /^\\s*hint\\s+\"/.test(line))) {\n return `**${word}** — Command named-rule guidance with at most one file or tagged fence. No payload means pending and fails binding (PLAY0268). Attached predicates keep their existing pure RuleContext contract; reference execution is unsupported, never confirmation.`;\n }\n if (word === 'implementation' && chain[0] === 'handler' && /^\\s*implementation\\s*$/.test(withoutComment(line))) {\n return `**implementation** — ${handlerIntentDocs.implementation}`;\n }\n if (word === 'hint' && chain[0] === 'implementation' && chain[1] === 'handler' && /^\\s*hint\\s+\"/.test(line)) {\n return `**hint** — ${handlerIntentDocs.hint}`;\n }\n }\n\n const symbols = scanDocument(lines);\n const owner = symbols.commands.filter(command => command.line < lineIndex).at(-1);\n const property = owner?.properties.find(property => property.name === word && property.line === lineIndex);\n if (property?.isGenerated || (word === 'generated' && owner?.properties.some(property => property.isGenerated && property.line === lineIndex) && followsPropertyType)) {\n return `**${property?.name ?? 'generated'}** — ${property ? typeReferenceText(propertyTypeReference(property)) + '. ' : ''}Generated value, not a request or form input. ${responseAvailability}`;\n }\n const response = owner?.response;\n if (response?.location.line === lineIndex + 1 && (tokenAt(response.location.column, 'returns') || (response.kind === 'ScalarCommandResponseSyntax' && tokenAt(response.source.location.column, response.source.property)))) {\n const source = response.kind === 'ScalarCommandResponseSyntax' ? owner?.properties.find(property => property.name === response.source.property) : undefined;\n return `**returns**${source ? ` — ${typeReferenceText(propertyTypeReference(source))}` : ' — unnamed record response'}. ${responseAvailability}`;\n }\n if (response?.kind === 'RecordCommandResponseSyntax') {\n const field = response.fields.find(field => field.location.line === lineIndex + 1 && (tokenAt(field.location.column, field.name) || tokenAt(field.source.location.column, field.source.property)));\n if (field) {\n const source = owner?.properties.find(property => property.name === field.source.property);\n const type = field.type ? typeReferenceText(field.type) : source ? typeReferenceText(propertyTypeReference(source)) : 'Unresolved type';\n return `**${field.name}** — ${type}${field.type ? ' (explicit)' : ' (inferred)'} = ${field.source.property}. ${source?.isGenerated ? 'Generated source, not request input. ' : ''}${responseAvailability}`;\n }\n }\n for (const specification of responseAnalysis(lines).specifications.values()) {\n if ((word === 'returns' && specification.thenReturns?.location.line === lineIndex + 1) || (word === 'generated' && specification.when?.generatedValues?.some(value => value.location.line === lineIndex + 1))) return responseAvailability;\n }\n\n const concept = symbols.concepts.find((candidate) => candidate.name === word);\n if (concept) {\n const attributes = concept.attributes.length ? ` ${concept.attributes.join(' ')}` : '';\n const values = concept.enumValues.length\n ? `\\n\\nValues: ${concept.enumValues.map((value, index) => concept.enumNumbers === undefined ? value : `${value} = ${concept.enumNumbers[index]}`).join(', ')}`\n : '';\n const reasons = Object.entries(concept.attributeReasons)\n .map(([attribute, reason]) => `\\n\\n**@${attribute}** — ${reason}`)\n .join('');\n return `\\`\\`\\`screenplay\\nconcept ${concept.name} : ${concept.primitive}${attributes}\\n\\`\\`\\`${reasons}${values}`;\n }\n\n const type = symbols.types.find((candidate) => candidate.name === word);\n if (type) {\n const properties = type.properties\n .map((property) => `${property.name} ${typeReferenceText(propertyTypeReference(property))}`)\n .join('\\n');\n return `\\`\\`\\`screenplay\\ntype ${type.name}\\n${properties}\\n\\`\\`\\``;\n }\n\n const policy = symbols.policies.find((candidate) => candidate.name === word);\n if (policy) {\n const body = policy.requires.length ? policy.requires.join('\\n') : '(custom C#)';\n return `\\`\\`\\`screenplay\\npolicy ${policy.name}\\n${body}\\n\\`\\`\\``;\n }\n\n const event = symbols.events.find((candidate) => candidate.name === word && candidate.line === lineIndex) ??\n symbols.events.filter((candidate) => candidate.name === word)\n .sort((left, right) => (right.generation ?? 1) - (left.generation ?? 1))[0];\n if (event) {\n const properties = event.properties\n .map((property) => `${property.name} ${typeReferenceText(propertyTypeReference(property))}${property.isSubject ? ' subject' : ''}`)\n .join('\\n');\n return `\\`\\`\\`screenplay\\n${event.visibility === 'Public' ? 'public ' : ''}event ${event.name}${event.generation !== undefined ? ` generation ${event.generation}` : ''}${event.origin !== undefined ? ` from ${JSON.stringify(event.origin)}` : ''}\\n${properties}\\n\\`\\`\\``;\n }\n\n const command = symbols.commands.find((candidate) => candidate.name === word);\n if (command && command.properties.length > 0) {\n const properties = command.properties\n .map(\n (property) =>\n `${property.name} ${typeReferenceText(propertyTypeReference(property))}${property.isGenerated ? ' generated' : ''}${property.isIdentifier ? ' identifier' : ''}`,\n )\n .join('\\n');\n return `\\`\\`\\`screenplay\\ncommand ${command.name}\\n${properties}\\n\\`\\`\\`${command.response || command.properties.some(property => property.isGenerated) ? `\\n\\n${responseAvailability}` : ''}`;\n }\n\n // Sub-language keywords take precedence inside their construct.\n const chain = enclosingChain(lines, fences, lineIndex, indentOf(line));\n for (const construct of [line.trim().split(/\\s+/)[0], ...chain]) {\n const subLanguage = getSubLanguage(construct ?? '');\n const doc = subLanguage?.hovers?.[word];\n if (doc) return doc;\n }\n\n if (word === 'reads' && (chain[0] === 'every' || chain[0] === 'at') && chain.includes('reaction')) {\n return '**reads** — Declares a whole view this clock trigger consults: `reads <View>`. Clock triggers take no values, so `by` is unavailable.';\n }\n\n const step = line.trim().match(/^(given|when|then)\\s+(?:no\\s+)?(\\w+)/);\n if (step && step[2] === word && chain[0] === 'specification' && specificationKeywordDocs[word]) {\n return `**${word}** — ${specificationKeywordDocs[word]}`;\n }\n\n if (word === 'id' || word === 'documentation') {\n const source = eventAnalysisSource(lines);\n const inEvent = symbols.events.some(event => directBody(source, fences, event.line, indentOf(source[event.line])).includes(lineIndex));\n const directive = word === 'id' ? /^\\s*id\\s+\"/.test(source[lineIndex]) : /^\\s*documentation\\s*$/.test(source[lineIndex]);\n const supportedOwner = inEvent || (word === 'documentation' && ['module', 'feature', 'slice', 'command', 'readmodel', 'reaction'].includes(chain[0]));\n if (!supportedOwner || !directive || startColumn !== indentOf(line) + 1) return null;\n }\n\n if (word === 'optional' || word === 'generated' || word === 'returns') return null;\n const keywordDoc = keywordDocs[word];\n if (keywordDoc) return `**${word}** — ${keywordDoc}`;\n\n return null;\n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Y/D,IAAS,iBAAmB,CAAC,SAAU,UAAW,QAAS,UAAW,YAAa,UAAU,CAAC,CAAC,SAAS4B,EAAM,EAAE,IAC5H,CAACqC,GAAa7E,IAAgBgB,EAAStB,CAAI,EAAI,EAAG,OAAO,IACpF,CAEA,GAAIkB,IAAS,YAAcA,IAAS,aAAeA,IAAS,UAAW,OAAO,KAC9E,IAAMkE,EAAavC,EAAY3B,GAG/B,OAFIkE,EAAmB,KAAKlE,EAAK,OAAOkE,IAEjC,IACX"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import"./_virtual/_virtual/_rolldown/runtime.js";import{eventContextPaths as e}from"./event-context-catalog.js";import"./event-context.js";const t={implementation:`Handler-only intent with ordered hints and at most one file or tagged fence. No payload means pending. Handler execution is unsupported; this is not confirmation.`,hint:`One nonblank quoted implementation hint. Order and decoded text are retained; hints do not execute or confirm code.`},n={parameter:`A typed value declared by a specification table, or an argument of a named behavior. Table types are required; every case supplies each parameter exactly once.`,case:`One named concrete row of a specification table, expanded as <Specification>_<Case>. Use case.<parameter> for a whole step value.`,example:"One typed, possibly partial fixture: `example <Name> : <EventOrCommandOrReadModel>`. Use its name in a matching specification step; assignments override example values without changing matching or supplying defaults. Event examples may carry stream or no stream; a step replaces that route as a whole.",domain:`The domain the file belongs to — optional, at most one per file, before everything else.`,import:'Imports a type from another module by its qualified name — `import Module.Type` — making it available by its short name; or, quoted, other `.play` files by path or glob — `import "Orders/**/*.play"`, relative to this file\'s folder. Written inside a module or feature, a file import places the imported files there: their top level is that module\'s or feature\'s body. `import Module.Event from "origin"` is instead public contract metadata with an opaque origin; executable binding refuses it with PLAY0268.',concept:`A formalized value type wrapping a primitive. Bare pii and secret markers travel with every usage, with optional concept notes and qualifiers.`,type:`A composite value type — a named shape built from several properties, referenced by events, commands and other types the same way a concept is.`,reason:`A free-text concept note, not a lawful basis. Written as pii reason "..." or secret reason "..."; migration preserves it verbatim.`,optional:"Allows a value to be absent. Write it after the type: `note String optional` or `lines InvoiceLine[] optional`. The collection itself may be absent; its items keep their declared type.",identifier:`Marks the command property a runtime resolves the event source id from. At most one per command; without it a new Uuid is generated.`,policy:`A named authorization rule referenced by commands and queries. Multiple policies AND together.`,purpose:`A report-only processing declaration (GDPR Art. 30), referenced on modules, features and slices. Coverage is their union, not an authorization gate. Generated declarations are not legal advice.`,basis:`One declared Art. 6(1) basis: consent, contract, legalObligation, vitalInterests, publicTask or legitimateInterests; an optional quoted reference may follow.`,interest:`The legitimate-interest statement for basis legitimateInterests (Art. 13(1)(d)).`,condition:`One Art. 9(2) processing condition, optionally followed by a quoted reference.`,subjects:`Comma-separated categories of data subjects, as open identifiers.`,retention:`Declared retention period or criteria, not enforced by the model or Chronicle.`,recipient:`A quoted recipient category; repeatable on a purpose.`,transfer:`A declared destination followed by safeguard and quoted safeguards; repeatable.`,safeguard:`The declared safeguard accompanying a third-country transfer.`,erasure:`An erasure exception under Art. 17(3); Chronicle crypto-shredding remains per subject, not per purpose.`,exception:`One declared Art. 17(3) exception: expression, legalObligation, publicTask, publicHealth, archiving or legalClaims.`,persona:`A named role interacting with the application, with an optional description and its associated policies.`,identity:"Declares typed additional caller details from a claim, a keyed single-result query, inline code or a file. Authoring metadata only; executable use of `$identity.<detail>` reports PLAY0268 until admitted (#600).",authentication:`Declares the identity providers of the application — at most one block per file.`,provider:"A named identity provider within `authentication`, with free-form `name value` settings.",description:"A human-readable description, including the rule or case a specification witnesses, as a quoted single line or a fenced ```text block for multiple lines.",depends:"Declares `depends on <Name>` on a module or feature. This opts only that container into checking counted explicit references against its own declarations; it does not change executable bytes.",module:`The top-level namespace — maps to a bounded context.`,layout:`A reusable screen template with named slots.`,template:`Declares the named slots of a layout.`,feature:`A vertical slice grouping. Features nest arbitrarily deep.`,slice:`The atomic unit of behavior, aligned with Event Modeling. Has a type and a name.`,public:`Marks an event as a public contract. An event with from "origin" is also public. Origin is opaque, not a path or declaration reference. Public events and origins are admitted by executable semantic model (ESM) v9.`,direction:`Declare direction inbound or direction outbound once inside a Translate slice. Admitted by executable semantic model (ESM) v9; a Translate slice that uses public events must declare it (PLAY0614).`,inbound:`Inbound Translate direction metadata. No transport or delivery guarantee is implied.`,outbound:`Outbound Translate direction metadata. No transport or delivery guarantee is implied.`,event:"An immutable, past-tense fact. Declare it in a slice or inline with `produces event <Name>` in a command. Inline properties are typed mappings; inline tags belong to the event type.",documentation:"Authoring-only reasoning on a module, feature, slice, command, event, read model or reaction in one nonempty fenced ```markdown block. It does not change executable model bytes.",id:`Preserves the previous persisted event name after a rename. Leave absent on new events; repeating the current name is redundant.`,command:`An imperative intent. Declares authorization, validation, and what events it produces — declaratively, or via a full handler.`,query:`A read-side entry point mapping to a return type, with an optional description, parameters and performer.`,observable:"Qualifies a query return type as a live read — `query <Name> => observable <ReadModel>` keeps pushing as the read model changes, instead of answering once.",performer:"The code that performs a query — a `file <Path>` reference or an inline `csharp`/`sql` block. The query's counterpart to a command handler.",from:"On a reaction or reducer, `from Source[.Stream]` observes only matching routed facts. It does not filter stream ids. Admitted by ESM v10. On a query parameter, fills it from the query context instead of the caller, as in `filter tenantId TenantId from $context.tenant`.",projection:`Declares how events project into a read model, using the embedded Projection Declaration Language (PDL).`,capture:`Converts external data into events, using the embedded Change Data Capture Language (CDL).`,reaction:"Behavior that runs when something happens. Lives inside Automation slices. A trigger with no body states intent on its own — `file`/code is optional realization metadata.",runs:'`runs as system [role "Role" and role "Role"]` declares the identity for every returned or invoked command of a reaction, not imperative pipeline calls. Admitted by released ESM v10; claims are unknown for this identity. Clock and application triggers have no Stage realization yet.',trigger:`Declares a kind of occurrence a reaction can respond to, and the values it hands the reaction. What makes one occur belongs to whoever provides it, never to the compiler.`,where:`Narrows which occurrences actually run the reaction.`,contains:`Text comparison — true when the left string holds the right one anywhere.`,every:"Runs a reaction on an interval — `every 15 minutes`, `every 1 day`.",refused:"Ordered invocation refusal branch: first match wins. Bare `on refused` covers validation and constraints, not authorization. Syntax-only, not yet executable (PLAY0268).",acknowledge:`A refusal branch acknowledges alone, or produces events instead. Syntax-only, not yet executable (PLAY0268).`,validation:"In `on refused by validation`, selects property, concept and require refusals. Syntax-only, not yet executable (PLAY0268).",authorization:"In `on refused by authorization`, explicitly selects unauthorized results, never Unsupported. Syntax-only, not yet executable (PLAY0268).",redelivered:"`when redelivered <Event> to <Reaction>` selects exactly one effective given occurrence by optional for, stated values and stream or no stream, without appending it again. Syntax-only, not yet executable (PLAY0268).",invokes:`A command a reaction hands on. A command is asked for, not produced — it may still be rejected.`,screen:`A UI declaration. Supports intent, structure, and layout-with-code levels, or a full file reference.`,constraint:`A server-side rule enforced in the Chronicle kernel before events are committed.`,authorize:`References the policies that must all pass for the construct to execute.`,validate:"Declarative validation rules, or `validate` followed by ```csharp for imperative rules — on commands and concepts.",produces:"References a declared event with `produces <Name>`, or declares one inline with `produces event <Name>`. An inline omitted `for` uses the command identifier only when all destinations are the same source; legacy plain omission allocates an identity.",reads:"Declares a view consulted by a command or reaction trigger: `reads <View> [as <alias>] [by <value>]`. A reaction `by` names a value taken by its trigger; clock triggers cannot use `by`. A child by block supplies composite key parts by name, using part = source. Repeated views require unique aliases. Runtime binding is not yet supported for command or reaction reads.",as:"Names an instance of a view in a command or reaction trigger reads declaration, for example `reads Account as source by sourceId`.",handler:"A fully imperative command implementation — a `file <Path>` reference or an inline `csharp` block, instead of `produces`.",when:"Guards a produced event or a capture append with a condition. In a labeled screen action, `when item.<field> == <literal> execute <Command>` selects the first matching command. Inside on click, double click or select, block-form `when <condition>` selects one whole action list at gesture time.",rule:"Names a predicate. Bare, it states that a constraint exists without expressing what it computes — nothing resolves the name. Optionally followed by an indented `file <Path>` reference or inline `csharp` block giving it a body.",require:'A policy condition: `authenticated`, `role "..."`, or `claim "..." matches ...`. Unary `not` negates a condition or group; precedence is not, and, or.',authenticated:`Requires an authenticated caller.`,role:`Requires the caller to have the given role.`,claim:`Requires a claim on the caller to match a subject or value.`,subject:"In policy `matches subject`, the identifier of the thing acted on, not the caller. The caller is `$context.causedBy.subject`.",data:`Binds a read model to a screen through a query.`,action:'Makes a command available on a screen. `action "Label"` declares one button with ordered `when … execute` alternatives over the nearest data item or selected row. No subject hides it; commands still enforce authorization and validation.',otherwise:"The final fallback of a guarded action: `otherwise hidden` or `otherwise execute <Command>`. In an item interaction, bare `otherwise` opens a fallback action list. No subject runs nothing, including fallback; authorization never falls through.",hidden:`Hides a guarded action when no condition matches. Without a subject the action is always hidden, even with an execute fallback.`,execute:"Executes a command. A guarded screen action selects it by the first matching condition; explicit `with … from` bindings precede same-name item fields, its declared form and renderer input.",navigate:"Navigates to a screen, optionally passing a parameter with `by`.",section:`A named structural section of a screen.`,table:`A table widget over a read model or child collection.`,summary:`A summary widget showing labeled fields.`,column:`A table column bound to a property.`,field:`A summary field bound to a property.`,title:`The display title of a screen or section.`,label:`The display label of an action, column, or field.`,unique:"A uniqueness constraint — `unique <property> on <EventType>` or `unique event <EventType>`.",concurrency:"The concurrency scope enforced when the command appends events — dimensions: `eventSource`, `sourceType`, `streamType`, `streamId`, `events`.",eventSource:`Concurrency dimension — scope the check to the event source id of the command.`,sourceType:`Concurrency dimension — scope the check to an event source type.`,streamType:`Concurrency dimension — scope the check to an event stream type.`,streamId:`Concurrency dimension — scope the check to an event stream id.`,tag:"Attaches a tag to appended events — a static identifier or string, or a `$context.` expression resolved at append time.",seed:`Declares events to seed into the event store per event source id — multiple blocks accumulate.`,for:"Names the event source of a production or seed group. Inside `produces event`, omission uses the command identifier unless another production targets a different source.",readmodel:"Declares a read model — its name and properties — in a slice, or, in a specification, read model state: `given readmodel` establishes it, `then readmodel` asserts it, `then no readmodel <View> for <key>` asserts keyed absence.",reducer:"Builds a read model from events with imperative code — `reducer <Name> => <ReadModel>` with an `on <EventType>` rule per event. Use it when a projection cannot express the transition.",specification:`Given/when/then acceptance criteria for a slice: prior events and state, the command, query or appended event under test, and the events, state, results, errors or denials that follow.`,dialog:"A dialog opened over the shell, or with `dialog template` a reusable dialog shape.",form:"A form bound to a command — `form <Name> for <Command>` with a `field` per input.",contribute:"Contributes entries to a slot of the shell — `contribute to Navigation` with `navigate to`, `label` and `order`.",theme:`A named theme and the component packages it is compatible with.`,ui:"A UI profile — `ui profile <Name>` binds a target platform and size to a layout, theme and packages.",behavior:"A named interaction wiring of `on <interaction>` handlers, attached to a screen, form or dialog with `uses`.",system:`An application-scoped external system that operations use.`,eventsource:`An application-owned event source with nested streams.`,operation:`A reusable operation intent that uses one external system.`,no:"A keyed absence assertion: `then no readmodel <View> for <key>`.",arguments:"The values supplied to a query asserted by `then query`.",result:"One expected result - `then result [exactly]` after `when query`, or a `result` block inside `then query`. Repeat it to assert several results in authored order.",clock:'The instant a specification happens at - `given clock "2026-10-05T08:00:00Z"` fixes when everything occurs; `when clock "<instant>"` is the clock reaching it, as the action.',exactly:"Requires every property to match, rather than only the ones asserted - on `then readmodel`, `then query` and `then result`.",file:`Delegates the implementation to an external file; the Screenplay contract stays visible.`,key:`Trailing modifier on a required top-level read-model property. Explicit keys replace inference. Composite keys remain authoring-only (PLAY0268, #599).`,stream:`On a command event production, replaces the whole command route for that event. Other productions keep the command route. Admitted by ESM v10.`,by:`Introduces one identifying parameter or a block of at least two named key parts. Reads use part = source; queries use part Type.`,via:`Connects screen data to the query that supplies it.`,filter:`An optional query filter parameter.`,on:"The event a constraint applies to, the day a schedule narrows to, or a widget interaction such as `on row-click`.",message:`The validation message reported when the rule fails.`,matches:"Matches a value against a regular expression or a named pattern such as `email`.",all:`Applies a comparison to every element of a collection.`,max:`Maximum length or value.`,min:`Minimum length or value.`,length:`Constrains the exact length of a value.`,today:`The current date.`,empty:"Used with `not empty` — the value must be present.",not:"Negates a validation condition, as in `not empty`.",and:`Both conditions must hold.`,or:`Either condition may hold.`,csharp:"An inline C# block whose opening fence is ```csharp.",sql:`An inline SQL block between triple backticks — a query performer written against a relational store.`,typescript:`An inline TypeScript block between triple backticks.`,react:"An inline React/TSX block; receives the surrounding data contract as `Props`.",html:`An inline static HTML block.`,StateChange:`Slice type — a command → events flow; something that changes the system.`,StateView:`Slice type — a query + projection + screen; something that reads the system.`,Automation:`Slice type — a reaction or reducer; something that runs when something happens.`,Translate:`Slice type — a capture; converts external data into events.`,Uuid:`Primitive type — a universally unique identifier.`,String:`Primitive type — a string of characters.`,Int:`Primitive type — an integer number.`,Decimal:`Primitive type — a decimal number.`,Bool:`Primitive type — true or false.`,Date:`Primitive type — a date without time.`,DateTime:`Primitive type — a date and time.`,Enum:`An enumeration concept with a fixed set of values.`},r={parameter:"Declares a required typed case value: `parameter <name> <Type>`. Every case assigns it once. `optional` permits literal null but supplies no default.",case:"One named complete row of a specification table. `case.<parameter>` substitutes a whole value after example overrides; each row runs as `<Specification>_<Case>`.",caller:"`given caller` states an explicit identity; `given caller as <Persona>` synthesizes an authenticated deterministic witness of the persona, with no body. Leftmost buildable policy alternatives are significant.",clock:n.clock,redelivered:n.redelivered,trigger:"`when trigger <Trigger>` - an application trigger fires, as the action, with the values on the lines beneath it.",capture:"`given capture <Capture>` - a record the capture's source held before; `when capture <Capture>` - the record it sees now, as the action. The fields go on the lines beneath.",query:"`when query <Query>` - the query is performed, as the action, with its arguments on the lines beneath; assert what it returns with `then result` or `then no result`. `then query` instead asserts a query after another action.",events:"`then no events` - asserts no new events after a non-append action. Syntax-only, not yet executable (PLAY0268). Cannot accompany event, event-order, error or denial expectations.",result:"`then result [exactly]` - one result the query performed by `when query` returns, in order; `then no result` - it returns nothing."},i={pii:`personal data (GDPR Art. 4(1)); renders Chronicle [PII]. Bare suffix marker; @pii is deprecated (PLAY0565). Not admitted by the executable model (PLAY0268).`,personal:`Alias of pii: personal data (GDPR Art. 4(1)); renders Chronicle [PII]. No diagnostic; canonical printing writes pii.`,secret:`Operational secret, not personal data: encrypted at rest without erasure and withheld from causation. Provider mapping: [Encrypted] + [NotAudited], or [PII] only with pii. Cannot be identity (PLAY0515). Not admitted by the executable model (PLAY0268).`,sensitive:`Deprecated spelling of secret (PLAY0565); repair to bare secret. Operational secret, not GDPR Art. 9 special-category data.`},a={"$context.occurred":`When the command or query was received.`,"$context.tenant":`The tenant the command or query is executing for.`,"$context.command":"The command being handled, shaped by its `command` declaration.","$context.arguments":`The arguments of the query being performed.`,"$context.causedBy":"The identity that caused the command or query — `subject`, `name`, `userName`.","$context.causedBy.subject":`The subject of the identity that caused the command or query.`,"$context.causedBy.name":`The display name of the identity that caused the command or query.`,"$context.causedBy.userName":`The user name of the identity that caused the command or query.`,"$context.causation":"What caused the command or query — `type`, `occurred`, `properties`.","$context.causation.type":`What caused the command or query — a command, a reactor, a schedule.`,$identity:"The caller — token built-ins `id`, `name`, `userName`, `isAuthenticated`, `roles`, `claims`, plus declared identity details. Built-ins are equivalent to `$context.identity`; details are authoring-only until admitted (#600).","$identity.id":"The identifier of the caller from the auth token; equivalent to `$context.identity.id`.","$identity.name":"The display name of the caller; equivalent to `$context.identity.name`.","$identity.userName":"The user name of the caller; equivalent to `$context.identity.userName`.","$identity.isAuthenticated":`Whether the caller is authenticated.`,"$identity.roles":`The roles the caller holds.`,"$identity.claims":"The claims the caller carries — `$identity.claims.<name>` reads one.","$context.identity":"The caller a decision is made about — `id`, `name`, `userName`, `isAuthenticated`, `roles`, `claims`.","$context.identity.id":`The identifier of the caller from the auth token.`,"$context.identity.name":`The display name of the caller.`,"$context.identity.userName":`The user name of the caller.`,"$context.identity.isAuthenticated":`Whether the caller is authenticated.`,"$context.identity.roles":`The roles the caller holds.`,"$context.identity.claims":"The claims the caller carries — `$context.identity.claims.<name>` reads one.",$env:"An environment variable, e.g. `$env.SERVICE_NAME`.",$secrets:"An encrypted secret resolved at runtime, e.g. `$secrets.azureAdClientId` — stays symbolic in the compiled tree.",$strings:"A localized string resolved from the `.strings` file of the active locale, e.g. `$strings.invoices.title`.",...Object.fromEntries(e.map(e=>[`$eventContext.${e.path}`,e.description]))},o={racialOrEthnicOrigin:`Data revealing a person's racial or ethnic origin (GDPR Art. 9(1)).`,politicalOpinions:`Data revealing a person's political opinions (GDPR Art. 9(1)).`,religiousOrPhilosophicalBeliefs:`Data revealing a person's religious or philosophical beliefs (GDPR Art. 9(1)).`,tradeUnionMembership:`Data revealing whether a person belongs to a trade union (GDPR Art. 9(1)).`,genetic:`Data about inherited or acquired genetic characteristics that gives unique information about a person's physiology or health (GDPR Art. 9(1), Art. 4(13)).`,biometric:`Data from technical processing of physical, physiological or behavioral characteristics, special only when processed to uniquely identify a person (GDPR Art. 9(1), Art. 4(14)).`,health:`Data about a person's physical or mental health, including health care services, that reveals their health status (GDPR Art. 9(1), Art. 4(15)).`,sexLifeOrSexualOrientation:`Data concerning a person's sex life or sexual orientation (GDPR Art. 9(1)).`};export{i as attributeDocs,a as contextVariableDocs,t as handlerIntentDocs,n as keywordDocs,o as specialCategoryDocs,r as specificationKeywordDocs};
|
|
1
|
+
import"./_virtual/_virtual/_rolldown/runtime.js";import{eventContextPaths as e}from"./event-context-catalog.js";import"./event-context.js";const t={implementation:`Handler-only intent with ordered hints and at most one file or tagged fence. No payload means pending. Handler execution is unsupported; this is not confirmation.`,hint:`One nonblank quoted implementation hint. Order and decoded text are retained; hints do not execute or confirm code.`},n={parameter:`A typed value declared by a specification table, or an argument of a named behavior. Table types are required; every case supplies each parameter exactly once.`,case:`One named concrete row of a specification table, expanded as <Specification>_<Case>. Use case.<parameter> for a whole step value.`,example:"One typed, possibly partial fixture: `example <Name> : <EventOrCommandOrReadModel>`. Use its name in a matching specification step; assignments override example values without changing matching or supplying defaults. Event examples may carry stream or no stream; a step replaces that route as a whole.",domain:`The domain the file belongs to — optional, at most one per file, before everything else.`,import:'Imports a type from another module by its qualified name — `import Module.Type` — making it available by its short name; or, quoted, other `.play` files by path or glob — `import "Orders/**/*.play"`, relative to this file\'s folder. Written inside a module or feature, a file import places the imported files there: their top level is that module\'s or feature\'s body. `import Module.Event from "origin"` is instead public contract metadata with an opaque origin; executable binding refuses it with PLAY0268.',concept:`A formalized value type wrapping a primitive. Bare pii and secret markers travel with every usage, with optional concept notes and qualifiers.`,type:`A composite value type — a named shape built from several properties, referenced by events, commands and other types the same way a concept is.`,reason:`A free-text concept note, not a lawful basis. Written as pii reason "..." or secret reason "..."; migration preserves it verbatim.`,optional:"Allows a value to be absent. Write it after the type: `note String optional` or `lines InvoiceLine[] optional`. The collection itself may be absent; its items keep their declared type.",identifier:`Marks the command property a runtime resolves the event source id from. At most one per command; without it a new Uuid is generated.`,policy:`A named authorization rule referenced by commands and queries. Multiple policies AND together.`,purpose:`A report-only processing declaration (GDPR Art. 30), referenced on modules, features and slices. Coverage is their union, not an authorization gate. Generated declarations are not legal advice.`,basis:`One declared Art. 6(1) basis: consent, contract, legalObligation, vitalInterests, publicTask or legitimateInterests; an optional quoted reference may follow.`,interest:`The legitimate-interest statement for basis legitimateInterests (Art. 13(1)(d)).`,condition:`One Art. 9(2) processing condition, optionally followed by a quoted reference.`,subjects:`Comma-separated categories of data subjects, as open identifiers.`,retention:`Declared retention period or criteria, not enforced by the model or Chronicle.`,recipient:`A quoted recipient category; repeatable on a purpose.`,transfer:`A declared destination followed by safeguard and quoted safeguards; repeatable.`,safeguard:`The declared safeguard accompanying a third-country transfer.`,erasure:`An erasure exception under Art. 17(3); Chronicle crypto-shredding remains per subject, not per purpose.`,exception:`One declared Art. 17(3) exception: expression, legalObligation, publicTask, publicHealth, archiving or legalClaims.`,persona:`A named role interacting with the application, with an optional description and its associated policies.`,identity:"Declares typed additional caller details from a claim, a keyed single-result query, inline code or a file. Authoring metadata only; executable use of `$identity.<detail>` reports PLAY0268 until admitted (#600).",authentication:`Declares the identity providers of the application — at most one block per file.`,provider:"A named identity provider within `authentication`, with free-form `name value` settings.",description:"A human-readable description, including the rule or case a specification witnesses, as a quoted single line or a fenced ```text block for multiple lines.",depends:"Declares `depends on <Name>` on a module or feature. This opts only that container into checking counted explicit references against its own declarations; it does not change executable bytes.",module:`The top-level namespace — maps to a bounded context.`,layout:`A reusable screen template with named slots.`,template:`Declares the named slots of a layout.`,feature:`A vertical slice grouping. Features nest arbitrarily deep.`,slice:`The atomic unit of behavior, aligned with Event Modeling. Has a type and a name.`,public:`Marks an event as a public contract. An event with from "origin" is also public. Origin is opaque, not a path or declaration reference. Public events and origins are admitted by executable semantic model (ESM) v9.`,direction:`Declare direction inbound or direction outbound once inside a Translate slice. Admitted by executable semantic model (ESM) v9; a Translate slice that uses public events must declare it (PLAY0614).`,inbound:`Inbound Translate direction metadata. No transport or delivery guarantee is implied.`,outbound:`Outbound Translate direction metadata. No transport or delivery guarantee is implied.`,event:"An immutable, past-tense fact. Declare it in a slice or inline with `produces event <Name>` in a command. Inline properties are typed mappings; inline tags belong to the event type.",documentation:"Authoring-only reasoning on a module, feature, slice, command, event, read model or reaction in one nonempty fenced ```markdown block. It does not change executable model bytes.",id:`Preserves the previous persisted event name after a rename. Leave absent on new events; repeating the current name is redundant.`,command:`An imperative intent. Declares authorization, validation, and what events it produces — declaratively, or via a full handler.`,query:`A read-side entry point mapping to a return type, with an optional description, parameters and performer.`,observable:"Qualifies a query return type as a live read — `query <Name> => observable <ReadModel>` keeps pushing as the read model changes, instead of answering once.",performer:"The code that performs a query — a `file <Path>` reference or an inline `csharp`/`sql` block. The query's counterpart to a command handler.",from:"On a reaction or reducer, `from Source[.Stream]` observes only matching routed facts. It does not filter stream ids. Admitted by ESM v10. On a query parameter, fills it from the query context instead of the caller, as in `filter tenantId TenantId from $context.tenant`.",projection:`Declares how events project into a read model, using the embedded Projection Declaration Language (PDL).`,capture:`Converts external data into events, using the embedded Change Data Capture Language (CDL).`,reaction:"Behavior that runs when something happens. Lives inside Automation slices. A trigger with no body states intent on its own — `file`/code is optional realization metadata.",runs:'`runs as system [role "Role" and role "Role"]` declares the identity for every returned or invoked command of a reaction, not imperative pipeline calls. Admitted by released ESM v10; claims are unknown for this identity. Clock and application triggers have no Stage realization yet.',trigger:`Declares a kind of occurrence a reaction can respond to, and the values it hands the reaction. What makes one occur belongs to whoever provides it, never to the compiler.`,where:`Narrows which occurrences actually run the reaction.`,contains:`Text comparison — true when the left string holds the right one anywhere.`,every:"Runs a reaction on an interval — `every 15 minutes`, `every 1 day`.",refused:"Ordered invocation refusal branch: first match wins. Bare `on refused` covers validation and constraints, not authorization. Syntax-only, not yet executable (PLAY0268).",acknowledge:`A refusal branch acknowledges alone, or produces events instead. Syntax-only, not yet executable (PLAY0268).`,validation:"In `on refused by validation`, selects property, concept and require refusals. Syntax-only, not yet executable (PLAY0268).",authorization:"In `on refused by authorization`, explicitly selects unauthorized results, never Unsupported. Syntax-only, not yet executable (PLAY0268).",redelivered:"`when redelivered <Event> to <Reaction>` selects exactly one effective given occurrence by optional for, stated values and stream or no stream, without appending it again. Syntax-only, not yet executable (PLAY0268).",invokes:`A command a reaction hands on. A command is asked for, not produced — it may still be rejected.`,screen:`A UI declaration. Supports intent, structure, and layout-with-code levels, or a full file reference.`,constraint:`A server-side rule enforced in the Chronicle kernel before events are committed.`,authorize:`References the policies that must all pass for the construct to execute.`,validate:"Declarative validation rules, or `validate` followed by ```csharp for imperative rules — on commands and concepts.",produces:"References a declared event with `produces <Name>`, or declares one inline with `produces event <Name>`. An inline omitted `for` uses the command identifier only when all destinations are the same source; legacy plain omission allocates an identity.",reads:"Declares a view consulted by a command or reaction trigger: `reads <View> [as <alias>] [by <value>]`. A reaction `by` names a value taken by its trigger; clock triggers cannot use `by`. A child by block supplies composite key parts by name, using part = source. Repeated views require unique aliases. Runtime binding is not yet supported for command or reaction reads.",as:"Names an instance of a view in a command or reaction trigger reads declaration, for example `reads Account as source by sourceId`.",handler:"A fully imperative command implementation — a `file <Path>` reference or an inline `csharp` block, instead of `produces`.",when:"Guards a produced event or a capture append with a condition. In a labeled screen action, `when item.<field> == <literal> execute <Command>` selects the first matching command. Inside on click, double click or select, block-form `when <condition>` selects one whole action list at gesture time.",rule:"Names a predicate. Bare, it states that a constraint exists without expressing what it computes — nothing resolves the name. Optionally followed by an indented `file <Path>` reference or inline `csharp` block giving it a body.",require:'A policy condition: `authenticated`, `role "..."`, or `claim "..." matches ...`. Unary `not` negates a condition or group; precedence is not, and, or.',authenticated:`Requires an authenticated caller.`,role:`Requires the caller to have the given role.`,claim:`Requires a claim on the caller to match a subject or value.`,subject:"In policy `matches subject`, the identifier of the thing acted on, not the caller. The caller is `$context.causedBy.subject`.",data:`Binds a read model to a screen through a query.`,action:'Makes a command available on a screen. `action "Label"` declares one button with ordered `when … execute` alternatives over the nearest data item or selected row. No subject hides it; commands still enforce authorization and validation.',otherwise:"The final fallback of a guarded action: `otherwise hidden` or `otherwise execute <Command>`. In an item interaction, bare `otherwise` opens a fallback action list. No subject runs nothing, including fallback; authorization never falls through.",hidden:`Hides a guarded action when no condition matches. Without a subject the action is always hidden, even with an execute fallback.`,execute:"Executes a command. A guarded screen action selects it by the first matching condition; explicit `with … from` bindings precede same-name item fields, its declared form and renderer input.",navigate:"Navigates to a screen, optionally passing a parameter with `by`.",section:`A named structural section of a screen.`,table:`A table widget over a read model or child collection.`,summary:`A summary widget showing labeled fields.`,column:`A table column bound to a property.`,field:`A summary field bound to a property.`,title:`The display title of a screen or section.`,label:`The display label of an action, column, or field.`,unique:"A uniqueness constraint — `unique <property> on <EventType>` or `unique event <EventType>`.",concurrency:"The concurrency scope enforced when the command appends events — dimensions: `eventSource`, `sourceType`, `streamType`, `streamId`, `events`.",eventSource:`Concurrency dimension — scope the check to the event source id of the command.`,sourceType:`Concurrency dimension — scope the check to an event source type.`,streamType:`Concurrency dimension — scope the check to an event stream type.`,streamId:`Concurrency dimension — scope the check to an event stream id.`,tag:"Attaches a tag to appended events — a static identifier or string, or a `$context.` expression resolved at append time.",seed:`Declares events to seed into the event store per event source id — multiple blocks accumulate.`,for:"Names the event source of a production or seed group. Inside `produces event`, omission uses the command identifier unless another production targets a different source.",readmodel:"Declares a read model — its name and properties — in a slice, or, in a specification, read model state: `given readmodel` establishes it, `then readmodel` asserts it, `then no readmodel <View> for <key>` asserts keyed absence.",reducer:"Builds a read model from events with imperative code — `reducer <Name> => <ReadModel>` with an `on <EventType>` rule per event. Use it when a projection cannot express the transition.",specification:`Given/when/then acceptance criteria for a slice: prior events and state, the command, query or appended event under test, and the events, state, results, errors or denials that follow.`,dialog:"A dialog opened over the shell, or with `dialog template` a reusable dialog shape.",form:"A form bound to a command — `form <Name> for <Command>` with a `field` per input.",contribute:"Contributes entries to a slot of the shell — `contribute to Navigation` with `navigate to`, `label` and `order`.",theme:`A named theme and the component packages it is compatible with.`,ui:"A UI profile — `ui profile <Name>` binds a target platform and size to a layout, theme and packages.",behavior:"A named interaction wiring of `on <interaction>` handlers, attached to a screen, form or dialog with `uses`.",system:`An application-scoped external system that operations use.`,eventsource:`An application-owned event source with nested streams.`,operation:`A reusable operation intent that uses one external system.`,no:"A keyed absence assertion: `then no readmodel <View> for <key>`.",arguments:"The values supplied to a query asserted by `then query`.",result:"One expected result - `then result [exactly]` after `when query`, or a `result` block inside `then query`. Repeat it to assert several results in authored order.",clock:'The instant a specification happens at - `given clock "2026-10-05T08:00:00Z"` fixes when everything occurs; `when clock "<instant>"` is the clock reaching it, as the action.',exactly:"Requires every property to match, rather than only the ones asserted - on `then readmodel`, `then query` and `then result`.",file:`Delegates the implementation to an external file; the Screenplay contract stays visible.`,key:`Trailing modifier on a required top-level read-model property. Explicit keys replace inference. Composite keys remain authoring-only (PLAY0268, #599).`,stream:`On a command event production, replaces the whole command route for that event. Other productions keep the command route. Admitted by ESM v10.`,by:`Introduces one identifying parameter or a block of at least two named key parts. Reads use part = source; queries use part Type.`,via:`Connects screen data to the query that supplies it.`,filter:`An optional query filter parameter.`,on:"The event a constraint applies to, the day a schedule narrows to, or a widget interaction such as `on row-click`.",message:`The validation message reported when the rule fails.`,matches:"Matches a value against a regular expression or a named pattern such as `email`.",all:`Applies a comparison to every element of a collection.`,max:`Maximum length or value.`,min:`Minimum length or value.`,length:`Constrains the exact length of a value.`,today:`The current date.`,empty:"Used with `not empty` — the value must be present.",not:"Negates a validation condition, as in `not empty`.",and:`Both conditions must hold.`,or:`Either condition may hold.`,csharp:"An inline C# block whose opening fence is ```csharp.",sql:`An inline SQL block between triple backticks — a query performer written against a relational store.`,typescript:`An inline TypeScript block between triple backticks.`,react:"An inline React/TSX block; receives the surrounding data contract as `Props`.",html:`An inline static HTML block.`,StateChange:`Slice type — a command → events flow; something that changes the system.`,StateView:`Slice type — a query + projection + screen; something that reads the system.`,Automation:`Slice type — a reaction or reducer; something that runs when something happens.`,Translate:`Slice type — a capture; converts external data into events.`,Uuid:`Primitive type — a universally unique identifier.`,String:`Primitive type — a string of characters.`,Int:`Primitive type — an integer number.`,Decimal:`Primitive type — a decimal number.`,Bool:`Primitive type — true or false.`,Date:`Primitive type — a date without time.`,DateTime:`Primitive type — a date and time.`,Enum:`An enumeration concept with named members. Members may all declare unique int32 numbers (draft = 1) or all omit them (zero-based positions). Never renumber or reuse a published number. Non-positional numbers are not admitted by any supported executable model (ESM) version yet (#643); specifications still name members.`},r={parameter:"Declares a required typed case value: `parameter <name> <Type>`. Every case assigns it once. `optional` permits literal null but supplies no default.",case:"One named complete row of a specification table. `case.<parameter>` substitutes a whole value after example overrides; each row runs as `<Specification>_<Case>`.",caller:"`given caller` states an explicit identity; `given caller as <Persona>` synthesizes an authenticated deterministic witness of the persona, with no body. Leftmost buildable policy alternatives are significant.",clock:n.clock,redelivered:n.redelivered,trigger:"`when trigger <Trigger>` - an application trigger fires, as the action, with the values on the lines beneath it.",capture:"`given capture <Capture>` - a record the capture's source held before; `when capture <Capture>` - the record it sees now, as the action. The fields go on the lines beneath.",query:"`when query <Query>` - the query is performed, as the action, with its arguments on the lines beneath; assert what it returns with `then result` or `then no result`. `then query` instead asserts a query after another action.",events:"`then no events` - asserts no new events after a non-append action. Syntax-only, not yet executable (PLAY0268). Cannot accompany event, event-order, error or denial expectations.",result:"`then result [exactly]` - one result the query performed by `when query` returns, in order; `then no result` - it returns nothing."},i={pii:`personal data (GDPR Art. 4(1)); renders Chronicle [PII]. Bare suffix marker; @pii is deprecated (PLAY0565). Not admitted by the executable model (PLAY0268).`,personal:`Alias of pii: personal data (GDPR Art. 4(1)); renders Chronicle [PII]. No diagnostic; canonical printing writes pii.`,secret:`Operational secret, not personal data: encrypted at rest without erasure and withheld from causation. Provider mapping: [Encrypted] + [NotAudited], or [PII] only with pii. Cannot be identity (PLAY0515). Not admitted by the executable model (PLAY0268).`,sensitive:`Deprecated spelling of secret (PLAY0565); repair to bare secret. Operational secret, not GDPR Art. 9 special-category data.`},a={"$context.occurred":`When the command or query was received.`,"$context.tenant":`The tenant the command or query is executing for.`,"$context.command":"The command being handled, shaped by its `command` declaration.","$context.arguments":`The arguments of the query being performed.`,"$context.causedBy":"The identity that caused the command or query — `subject`, `name`, `userName`.","$context.causedBy.subject":`The subject of the identity that caused the command or query.`,"$context.causedBy.name":`The display name of the identity that caused the command or query.`,"$context.causedBy.userName":`The user name of the identity that caused the command or query.`,"$context.causation":"What caused the command or query — `type`, `occurred`, `properties`.","$context.causation.type":`What caused the command or query — a command, a reactor, a schedule.`,$identity:"The caller — token built-ins `id`, `name`, `userName`, `isAuthenticated`, `roles`, `claims`, plus declared identity details. Built-ins are equivalent to `$context.identity`; details are authoring-only until admitted (#600).","$identity.id":"The identifier of the caller from the auth token; equivalent to `$context.identity.id`.","$identity.name":"The display name of the caller; equivalent to `$context.identity.name`.","$identity.userName":"The user name of the caller; equivalent to `$context.identity.userName`.","$identity.isAuthenticated":`Whether the caller is authenticated.`,"$identity.roles":`The roles the caller holds.`,"$identity.claims":"The claims the caller carries — `$identity.claims.<name>` reads one.","$context.identity":"The caller a decision is made about — `id`, `name`, `userName`, `isAuthenticated`, `roles`, `claims`.","$context.identity.id":`The identifier of the caller from the auth token.`,"$context.identity.name":`The display name of the caller.`,"$context.identity.userName":`The user name of the caller.`,"$context.identity.isAuthenticated":`Whether the caller is authenticated.`,"$context.identity.roles":`The roles the caller holds.`,"$context.identity.claims":"The claims the caller carries — `$context.identity.claims.<name>` reads one.",$env:"An environment variable, e.g. `$env.SERVICE_NAME`.",$secrets:"An encrypted secret resolved at runtime, e.g. `$secrets.azureAdClientId` — stays symbolic in the compiled tree.",$strings:"A localized string resolved from the `.strings` file of the active locale, e.g. `$strings.invoices.title`.",...Object.fromEntries(e.map(e=>[`$eventContext.${e.path}`,e.description]))},o={racialOrEthnicOrigin:`Data revealing a person's racial or ethnic origin (GDPR Art. 9(1)).`,politicalOpinions:`Data revealing a person's political opinions (GDPR Art. 9(1)).`,religiousOrPhilosophicalBeliefs:`Data revealing a person's religious or philosophical beliefs (GDPR Art. 9(1)).`,tradeUnionMembership:`Data revealing whether a person belongs to a trade union (GDPR Art. 9(1)).`,genetic:`Data about inherited or acquired genetic characteristics that gives unique information about a person's physiology or health (GDPR Art. 9(1), Art. 4(13)).`,biometric:`Data from technical processing of physical, physiological or behavioral characteristics, special only when processed to uniquely identify a person (GDPR Art. 9(1), Art. 4(14)).`,health:`Data about a person's physical or mental health, including health care services, that reveals their health status (GDPR Art. 9(1), Art. 4(15)).`,sexLifeOrSexualOrientation:`Data concerning a person's sex life or sexual orientation (GDPR Art. 9(1)).`};export{i as attributeDocs,a as contextVariableDocs,t as handlerIntentDocs,n as keywordDocs,o as specialCategoryDocs,r as specificationKeywordDocs};
|
|
2
2
|
//# sourceMappingURL=keyword-docs.js.map
|