@contentful/experience-design-system-types 2.42.1-dev-build-f69db6bf.0 → 2.43.0-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (94) hide show
  1. package/README.md +15 -0
  2. package/dist/package.json +1 -1
  3. package/dist/src/agent-process-lifecycle.d.ts +26 -0
  4. package/dist/src/agent-process-lifecycle.js +171 -0
  5. package/dist/src/agent-prompt-artifact.d.ts +8 -0
  6. package/dist/src/agent-prompt-artifact.js +37 -0
  7. package/dist/src/agent-prompt-transport.d.ts +1 -0
  8. package/dist/src/agent-prompt-transport.js +4 -0
  9. package/dist/src/cdf/build.d.ts +9 -2
  10. package/dist/src/cdf/build.js +134 -17
  11. package/dist/src/cdf/finite-values.d.ts +8 -0
  12. package/dist/src/cdf/finite-values.js +21 -0
  13. package/dist/src/cdf/index.d.ts +2 -1
  14. package/dist/src/cdf/index.js +1 -0
  15. package/dist/src/cdf/property-validation.d.ts +16 -0
  16. package/dist/src/cdf/property-validation.js +211 -0
  17. package/dist/src/cdf/representation-validation.d.ts +6 -0
  18. package/dist/src/cdf/representation-validation.js +182 -0
  19. package/dist/src/cdf/schema.d.ts +778 -20
  20. package/dist/src/cdf/schema.js +362 -5
  21. package/dist/src/cdf/types.d.ts +57 -59
  22. package/dist/src/cdf/types.js +72 -15
  23. package/dist/src/cdf/validate.js +31 -1
  24. package/dist/src/cdf/vocabularies.d.ts +1 -1
  25. package/dist/src/cdf/vocabularies.js +9 -1
  26. package/dist/src/config/index.js +6 -3
  27. package/dist/src/exploration/constants.d.ts +10 -0
  28. package/dist/src/exploration/constants.js +18 -0
  29. package/dist/src/exploration/index.d.ts +3 -0
  30. package/dist/src/exploration/index.js +3 -0
  31. package/dist/src/exploration/schemas.d.ts +201 -0
  32. package/dist/src/exploration/schemas.js +126 -0
  33. package/dist/src/exploration/types.d.ts +393 -0
  34. package/dist/src/exploration/types.js +1 -0
  35. package/dist/src/handoff/index.d.ts +1 -1
  36. package/dist/src/index.d.ts +15 -1
  37. package/dist/src/index.js +12 -4
  38. package/dist/src/property-contract/analysis-representation-candidates.d.ts +19 -0
  39. package/dist/src/property-contract/analysis-representation-candidates.js +45 -0
  40. package/dist/src/property-contract/classification.d.ts +38 -0
  41. package/dist/src/property-contract/classification.js +84 -0
  42. package/dist/src/property-contract/compact-model-components.d.ts +16 -0
  43. package/dist/src/property-contract/compact-model-components.js +113 -0
  44. package/dist/src/property-contract/content-digest.d.ts +2 -0
  45. package/dist/src/property-contract/content-digest.js +69 -0
  46. package/dist/src/property-contract/decision-protocol.d.ts +45 -0
  47. package/dist/src/property-contract/decision-protocol.js +251 -0
  48. package/dist/src/property-contract/definition-import-rules.d.ts +10 -0
  49. package/dist/src/property-contract/definition-import-rules.js +105 -0
  50. package/dist/src/property-contract/definition-import.d.ts +13 -0
  51. package/dist/src/property-contract/definition-import.js +52 -0
  52. package/dist/src/property-contract/discriminated-union-source.d.ts +17 -0
  53. package/dist/src/property-contract/discriminated-union-source.js +180 -0
  54. package/dist/src/property-contract/import-prerequisites.d.ts +70 -0
  55. package/dist/src/property-contract/import-prerequisites.js +208 -0
  56. package/dist/src/property-contract/index.d.ts +18 -1
  57. package/dist/src/property-contract/index.js +18 -6
  58. package/dist/src/property-contract/logical-source-graph.d.ts +36 -0
  59. package/dist/src/property-contract/logical-source-graph.js +240 -0
  60. package/dist/src/property-contract/mapper-readiness.d.ts +6 -0
  61. package/dist/src/property-contract/mapper-readiness.js +34 -0
  62. package/dist/src/property-contract/model-exploration.d.ts +42 -0
  63. package/dist/src/property-contract/model-exploration.js +94 -0
  64. package/dist/src/property-contract/native-source-region.d.ts +5 -0
  65. package/dist/src/property-contract/native-source-region.js +125 -0
  66. package/dist/src/property-contract/null-handling.d.ts +10 -0
  67. package/dist/src/property-contract/null-handling.js +45 -0
  68. package/dist/src/property-contract/physical-property-import.d.ts +6 -0
  69. package/dist/src/property-contract/physical-property-import.js +55 -0
  70. package/dist/src/property-contract/property-decision.d.ts +14 -0
  71. package/dist/src/property-contract/property-decision.js +155 -0
  72. package/dist/src/property-contract/property-model.d.ts +197 -0
  73. package/dist/src/property-contract/property-model.js +833 -0
  74. package/dist/src/property-contract/representation-plan.d.ts +133 -0
  75. package/dist/src/property-contract/representation-plan.js +756 -0
  76. package/dist/src/property-contract/representation-proposal.d.ts +65 -0
  77. package/dist/src/property-contract/representation-proposal.js +204 -0
  78. package/dist/src/property-contract/resource-link-schema.d.ts +55 -0
  79. package/dist/src/property-contract/resource-link-schema.js +28 -0
  80. package/dist/src/property-contract/source-representation.d.ts +9 -0
  81. package/dist/src/property-contract/source-representation.js +79 -0
  82. package/dist/src/property-contract/target-definition.d.ts +17 -16
  83. package/dist/src/property-contract/target-definition.js +4 -26
  84. package/dist/src/schema-export.d.ts +30 -0
  85. package/dist/src/schema-export.js +285 -0
  86. package/dist/src/shared-source.d.ts +105 -0
  87. package/dist/src/shared-source.js +1 -0
  88. package/dist/src/source-input-association.d.ts +23 -0
  89. package/dist/src/source-input-association.js +52 -0
  90. package/dist/src/sources-api/preview/index.d.ts +37 -3
  91. package/dist/src/sources-api/preview/index.js +39 -1
  92. package/dist/src/sources-api/preview/schema.d.ts +2 -0
  93. package/dist/src/sources-api/preview/schema.js +74 -0
  94. package/package.json +1 -1
@@ -0,0 +1,55 @@
1
+ import { cdfToTarget, cdfDefinitionChildren } from '../cdf/property-validation.js';
2
+ import { DESIGN_TOKEN_TYPES } from '../dtcg/token-types.js';
3
+ import { childPath, own } from './json-value.js';
4
+ /** Finite choices stay in the source; target mapping owns enforcement and loss reporting. */
5
+ export function propertyDefinitionImportBlockers(definition, path = '') {
6
+ return propertyDefinitionImportIssues(definition).map((issue) => `${path}${issue.path}: ${issue.message}`);
7
+ }
8
+ /** Physical restrictions apply to emitted fields, never to retained source evidence. */
9
+ export function propertyDefinitionImportIssues(definition) {
10
+ if (definition.$category === 'state' || definition.$category === 'unattached')
11
+ return [];
12
+ const issues = [];
13
+ if (definition.$category === 'design') {
14
+ if (!['String', 'Number', 'Boolean'].includes(cdfToTarget(definition).type))
15
+ issues.push({ path: '', message: 'Structured design properties require a model representation' });
16
+ if (definition.$type === 'token') {
17
+ if (!DESIGN_TOKEN_TYPES.includes(definition['$token.kind']))
18
+ issues.push({ path: '/$token.kind', message: 'Token properties require a recognized token kind' });
19
+ for (const [index, reference] of (definition['$token.allowed'] ?? []).entries())
20
+ if (!reference.trim())
21
+ issues.push({ path: '/$token.allowed/' + index, message: 'Token reference must not be empty' });
22
+ if (own(definition, '$default') && !String(definition.$default).trim())
23
+ issues.push({ path: '/$default', message: 'Token reference must not be empty' });
24
+ }
25
+ return issues;
26
+ }
27
+ const unsafeValueKeys = (value, path) => {
28
+ if (!value || typeof value !== 'object')
29
+ return;
30
+ for (const [key, child] of Object.entries(value)) {
31
+ const childLocation = childPath(path, key);
32
+ if (key === '__proto__')
33
+ issues.push({
34
+ path: childLocation,
35
+ message: 'The storage update path cannot preserve this object key; select a source-derived model representation',
36
+ });
37
+ else
38
+ unsafeValueKeys(child, childLocation);
39
+ }
40
+ };
41
+ const walk = (field, path) => {
42
+ if (field.$type === 'array' && path !== '')
43
+ issues.push({ path, message: 'Nested Array fields require a source-derived model representation' });
44
+ if (field.$type === 'record' && path !== '' && path !== '/$items')
45
+ issues.push({ path, message: 'Nested Record fields require a source-derived model representation' });
46
+ if (own(field, '$default'))
47
+ unsafeValueKeys(field.$default, path + '/$default');
48
+ if (own(field, 'value'))
49
+ unsafeValueKeys(field.value, path + '/value');
50
+ for (const child of cdfDefinitionChildren(field))
51
+ walk(child.definition, path + child.path);
52
+ };
53
+ walk(definition, '');
54
+ return issues;
55
+ }
@@ -0,0 +1,14 @@
1
+ import type { CDFPropertyDefinition } from '../cdf/types.js';
2
+ import type { RepresentationProposalDraft } from './representation-proposal.js';
3
+ export interface PropertyDecisionIssue {
4
+ path: string;
5
+ message: string;
6
+ }
7
+ export interface PropertyDecisionRepresentations {
8
+ /** Definitions and drafts admitted against their authoritative source context by the caller. */
9
+ definition?: CDFPropertyDefinition;
10
+ representationProposal?: RepresentationProposalDraft;
11
+ sourceRequired?: boolean;
12
+ }
13
+ /** Validates decision metadata without deriving a source shape or certifying mapper readiness. */
14
+ export declare function validatePropertyDecisionMetadata(input: unknown, representations?: PropertyDecisionRepresentations): PropertyDecisionIssue[];
@@ -0,0 +1,155 @@
1
+ import { cdfToTarget, targetToCDF, validateCDFProperty } from '../cdf/property-validation.js';
2
+ import { CDF_PROPERTY_CATEGORIES, CDF_PROPERTY_TYPES } from '../cdf/vocabularies.js';
3
+ import { finiteValuesIssue } from '../cdf/finite-values.js';
4
+ import { isSourceBoundRepresentation } from './source-representation.js';
5
+ import { validateTargetDefinition, validateTargetValue } from './target-definition.js';
6
+ import { jsonValueIssue, jsonEqual, own, childPath } from './json-value.js';
7
+ const DECISION_KEYS = new Set([
8
+ 'name',
9
+ 'type',
10
+ 'category',
11
+ 'required',
12
+ 'default',
13
+ 'values',
14
+ 'observedValues',
15
+ 'tokenKind',
16
+ 'tokenPaths',
17
+ 'description',
18
+ 'reasoning',
19
+ 'definition',
20
+ 'representationProposal',
21
+ ]);
22
+ /** Validates decision metadata without deriving a source shape or certifying mapper readiness. */
23
+ export function validatePropertyDecisionMetadata(input, representations = {}) {
24
+ if (typeof input !== 'object' || input === null || Array.isArray(input))
25
+ return [{ path: '', message: 'A property decision must be an object' }];
26
+ const decision = input;
27
+ const errors = [];
28
+ const issue = (key, message) => errors.push({ path: childPath('', key), message });
29
+ const present = (key) => Object.hasOwn(decision, key);
30
+ for (const key of Object.keys(decision)) {
31
+ if (!DECISION_KEYS.has(key))
32
+ issue(key, 'Unrecognized property decision metadata');
33
+ }
34
+ if (typeof decision.name !== 'string' || decision.name.trim().length === 0)
35
+ issue('name', 'Property decisions require a nonempty name');
36
+ if (present('category') && !CDF_PROPERTY_CATEGORIES.some((category) => category === decision.category))
37
+ issue('category', 'Invalid property category');
38
+ if (present('required') && typeof decision.required !== 'boolean')
39
+ issue('required', 'required must be a boolean');
40
+ for (const key of ['description', 'reasoning']) {
41
+ if (present(key) && typeof decision[key] !== 'string')
42
+ issue(key, `${key} must be a string`);
43
+ }
44
+ if (present('observedValues')) {
45
+ if (!Array.isArray(decision.observedValues))
46
+ issue('observedValues', 'observedValues must be an array of JSON values');
47
+ else
48
+ decision.observedValues.forEach((value, index) => {
49
+ const invalid = jsonValueIssue(value, childPath('/observedValues', index));
50
+ if (invalid)
51
+ errors.push(invalid);
52
+ });
53
+ }
54
+ const { definition, representationProposal: proposal } = representations;
55
+ if (present('definition') && !definition)
56
+ issue('definition', 'A complete admitted definition is required');
57
+ if (present('representationProposal') && !proposal)
58
+ issue('representationProposal', 'An admitted source-bound representation proposal is required');
59
+ if (definition && proposal)
60
+ issue('representationProposal', 'A decision cannot combine competing representations');
61
+ if (!present('type') && !definition && !proposal) {
62
+ for (const key of ['default', 'values', 'tokenKind', 'tokenPaths']) {
63
+ if (present(key))
64
+ issue(key, 'A type-absent decision cannot include representation metadata');
65
+ }
66
+ if (typeof decision.reasoning !== 'string' || decision.reasoning.trim().length === 0)
67
+ issue('reasoning', 'A type-absent decision requires nonempty reasoning');
68
+ return errors;
69
+ }
70
+ if (present('type') && !CDF_PROPERTY_TYPES.some((type) => type === decision.type)) {
71
+ issue('type', decision.type === 'enum'
72
+ ? 'obsolete type "enum"; use string, number, or boolean with native finite values'
73
+ : 'Invalid property type');
74
+ }
75
+ if (proposal) {
76
+ if (decision.category !== 'content')
77
+ issue('category', 'A content representation proposal requires content category');
78
+ const desired = proposal.desiredDefinition;
79
+ if (representations.sourceRequired !== undefined && (desired.required ?? false) !== representations.sourceRequired)
80
+ issue('required', 'Representation proposal requiredness must match the current source property');
81
+ const type = targetToCDF(desired).$type;
82
+ if (present('type') && decision.type !== type)
83
+ issue('type', 'type must match the representation proposal');
84
+ if (present('required') && decision.required !== (desired.required ?? false))
85
+ issue('required', 'required must match the representation proposal');
86
+ for (const key of ['values', 'tokenKind', 'tokenPaths']) {
87
+ if (present(key))
88
+ issue(key, 'Unrelated metadata cannot accompany a representation proposal');
89
+ }
90
+ if (present('default')) {
91
+ const invalid = validateTargetDefinition({ ...desired, defaultValue: decision.default }).issues;
92
+ if (invalid.length)
93
+ issue('default', 'default must match the complete representation proposal');
94
+ if (own(desired, 'defaultValue') && !jsonEqual(decision.default, desired.defaultValue))
95
+ issue('default', 'default conflicts with the representation proposal');
96
+ }
97
+ return errors;
98
+ }
99
+ if (present('values')) {
100
+ if (!Array.isArray(decision.values))
101
+ issue('values', 'Invalid finite values: values must be an array');
102
+ else {
103
+ const invalid = finiteValuesIssue(decision.type, decision.values);
104
+ if (invalid)
105
+ issue('values', `Invalid finite values: ${invalid.message}`);
106
+ }
107
+ }
108
+ for (const key of ['tokenKind', 'tokenPaths']) {
109
+ if (present(key) && decision.type !== 'token')
110
+ issue(key, `${key} is only valid for token decisions`);
111
+ }
112
+ if (present('tokenKind') && (typeof decision.tokenKind !== 'string' || decision.tokenKind.trim().length === 0))
113
+ issue('tokenKind', 'tokenKind must be a nonempty string');
114
+ if (present('tokenPaths') &&
115
+ (!Array.isArray(decision.tokenPaths) ||
116
+ !decision.tokenPaths.every((value) => typeof value === 'string' && value.trim().length > 0)))
117
+ issue('tokenPaths', 'tokenPaths must be an array of nonempty strings');
118
+ if (typeof decision.type === 'string' && isSourceBoundRepresentation(decision.type))
119
+ issue('type', `${String(decision.type)} requires a source-bound representation proposal`);
120
+ if (decision.type === 'Literal' && !definition)
121
+ issue('definition', 'Literal requires a complete representation');
122
+ if (definition) {
123
+ if (decision.type !== definition.$type || decision.category !== definition.$category)
124
+ issue('definition', 'Complete definition type and category must match the decision');
125
+ }
126
+ if (!present('default'))
127
+ return errors;
128
+ if (definition) {
129
+ errors.push(...validateTargetValue(cdfToTarget(definition), decision.default));
130
+ }
131
+ else if (decision.type === 'array' || decision.type === 'record') {
132
+ // Flat inventory records root transport only; it cannot invent recursive fields.
133
+ const matches = decision.type === 'array'
134
+ ? Array.isArray(decision.default)
135
+ : typeof decision.default === 'object' && decision.default !== null && !Array.isArray(decision.default);
136
+ if (!matches)
137
+ issue('default', 'default must match the declared container type');
138
+ else {
139
+ const invalid = jsonValueIssue(decision.default, '/default');
140
+ if (invalid)
141
+ errors.push(invalid);
142
+ }
143
+ }
144
+ else {
145
+ const parsed = validateCDFProperty({
146
+ $type: decision.type,
147
+ $category: decision.category ?? 'content',
148
+ $default: decision.default,
149
+ ...(present('values') ? { $values: decision.values } : {}),
150
+ });
151
+ if (!parsed.valid)
152
+ issue('default', 'default must match the native property type and finite values');
153
+ }
154
+ return errors;
155
+ }
@@ -0,0 +1,197 @@
1
+ import type { CDFFieldDefinition } from '../cdf/types.js';
2
+ import { type JsonValue, type PropertyIssue } from './json-value.js';
3
+ import { type TargetDefinition, type TargetPropertyType } from './target-definition.js';
4
+ import { type RepresentationProposalDraft } from './representation-proposal.js';
5
+ import { type NullHandlingJudgment } from './null-handling.js';
6
+ export type MapperAvailability = 'enabled' | 'unavailable' | 'unknown';
7
+ export interface SourceGraphDeclaration {
8
+ fileId: string | null;
9
+ canonicalPath: string | null;
10
+ textHash: string | null;
11
+ startLine: number | null;
12
+ endLine: number | null;
13
+ startOffset?: number | null;
14
+ endOffset?: number | null;
15
+ binding: 'verified' | 'changed' | 'unverified' | 'unavailable';
16
+ }
17
+ export interface SourceGraphNode {
18
+ id: string;
19
+ path?: Array<{
20
+ kind: 'field' | 'item' | 'tuple' | 'union' | 'intersection' | 'index';
21
+ key: string | number;
22
+ }>;
23
+ compilerIdentity?: {
24
+ typeId: string;
25
+ declarationId?: string;
26
+ };
27
+ declarations?: SourceGraphDeclaration[];
28
+ alias?: string;
29
+ readonly?: boolean;
30
+ nullable?: boolean;
31
+ undefinable?: boolean;
32
+ tupleElements?: Array<{
33
+ nodeId: string;
34
+ label: string | null;
35
+ optional: boolean;
36
+ rest: boolean;
37
+ }>;
38
+ discriminatorKeys?: string[];
39
+ discriminator?: {
40
+ provenance: 'compiler' | 'unknown';
41
+ complete: boolean;
42
+ keys: string[];
43
+ };
44
+ nullabilityProvenance?: 'compiler' | 'syntax' | 'compiler-erased' | 'unknown';
45
+ nullability?: {
46
+ compilerMode: 'enabled' | 'disabled';
47
+ null: {
48
+ state: 'present' | 'absent' | 'unknown';
49
+ source: 'compiler' | 'syntax' | 'compiler-erased' | 'unknown';
50
+ };
51
+ undefined: {
52
+ state: 'present' | 'absent' | 'unknown';
53
+ source: 'compiler' | 'syntax' | 'compiler-erased' | 'unknown';
54
+ };
55
+ };
56
+ callSignatures?: string[];
57
+ keyPath: string[];
58
+ kind: string;
59
+ typeText: string;
60
+ required: boolean;
61
+ domain: {
62
+ openness: 'closed' | 'open' | 'unknown';
63
+ declaredValues: JsonValue[];
64
+ provenance: 'compiler' | 'unknown';
65
+ unrepresentedValues?: Array<{
66
+ typeText: string;
67
+ reason: string;
68
+ }>;
69
+ };
70
+ fields?: Array<{
71
+ key: string;
72
+ nodeId: string;
73
+ required: boolean;
74
+ readonly?: boolean;
75
+ declarations?: SourceGraphDeclaration[];
76
+ description?: string;
77
+ path?: NonNullable<SourceGraphNode['path']>;
78
+ }>;
79
+ items?: string[];
80
+ alternatives?: string[];
81
+ indexSignatures?: Array<{
82
+ keyType: string;
83
+ valueNodeId: string;
84
+ }>;
85
+ coverage: 'complete-within-declared-bound' | 'partial' | 'unavailable';
86
+ reason: string | null;
87
+ }
88
+ export interface PropertySourceGraph {
89
+ schemaVersion: 1;
90
+ rootId: string;
91
+ nodes: SourceGraphNode[];
92
+ coverage: 'complete-within-declared-bound' | 'partial' | 'unavailable';
93
+ limits: {
94
+ maxDepth: number;
95
+ maxNodes: number;
96
+ maxFields: number;
97
+ maxEdges?: number;
98
+ };
99
+ resources?: {
100
+ nodes: number;
101
+ edges: number;
102
+ };
103
+ omittedCount: number;
104
+ }
105
+ export type DefaultIntent = {
106
+ action: 'absent';
107
+ } | {
108
+ action: 'clear';
109
+ } | {
110
+ action: 'set';
111
+ value: JsonValue;
112
+ };
113
+ export interface PropertyModel {
114
+ identity: {
115
+ componentId: string;
116
+ propertyId: string;
117
+ key: string;
118
+ sourceRevision: string;
119
+ nodeId: string;
120
+ };
121
+ source: {
122
+ typeText: string;
123
+ graph: PropertySourceGraph;
124
+ shape: CDFFieldDefinition | null;
125
+ default?: {
126
+ expression: string;
127
+ state?: 'value' | 'unsupported';
128
+ value?: JsonValue;
129
+ reason?: string | null;
130
+ };
131
+ observations: JsonValue[];
132
+ useEvidence?: Array<{
133
+ reference: string;
134
+ status: 'output-flow-found' | 'closed-absence' | 'unresolved';
135
+ }>;
136
+ originalFacts?: JsonValue;
137
+ };
138
+ category?: 'content' | 'design' | 'state' | 'unattached';
139
+ description?: string;
140
+ representation?: CDFFieldDefinition;
141
+ representationProposal?: RepresentationProposalDraft;
142
+ nullHandling?: NullHandlingJudgment[];
143
+ defaultIntent: DefaultIntent;
144
+ defaultAuthority?: 'generation' | 'review' | 'existing' | 'token';
145
+ }
146
+ export interface PropertyProfile {
147
+ id: string;
148
+ revision: 2;
149
+ mapperTypes: string[];
150
+ targetTypes: TargetPropertyType[];
151
+ defaultSourceTypes: string[];
152
+ defaultTargetTypes: TargetPropertyType[];
153
+ requirements: Array<{
154
+ path: string;
155
+ capability: string;
156
+ }>;
157
+ }
158
+ export interface ProjectionContext {
159
+ capabilities: Record<string, MapperAvailability>;
160
+ }
161
+ export interface PropertyProjection {
162
+ model: Readonly<PropertyModel>;
163
+ profile: Readonly<PropertyProfile>;
164
+ outcome: 'supported' | 'conditional' | 'lossy' | 'unsupported';
165
+ target?: TargetDefinition;
166
+ issues: PropertyIssue[];
167
+ requirements: Array<{
168
+ path: string;
169
+ capability: string;
170
+ availability: MapperAvailability;
171
+ }>;
172
+ }
173
+ export declare function createPropertyProfile(profile: PropertyProfile): Readonly<PropertyProfile>;
174
+ export declare const LOCAL_NATIVE_PROPERTY_PROFILE: Readonly<PropertyProfile>;
175
+ export declare function validateSourceGraph(graph: PropertySourceGraph): PropertyIssue[];
176
+ /** Validate JSON defaults against source structure independently of target support. */
177
+ export declare function validateSourceValue(graph: PropertySourceGraph, value: JsonValue, path?: string, nodeId?: string): PropertyIssue[];
178
+ /** Source domains remain independently proven; caller defaults and observations never close them. */
179
+ export declare function validateSourceDomain(graph: PropertySourceGraph, definition: TargetDefinition, nullHandling?: readonly NullHandlingJudgment[]): PropertyIssue[];
180
+ export declare function projectProperty(model: PropertyModel, profile: Readonly<PropertyProfile>, context: ProjectionContext): PropertyProjection;
181
+ export interface RepresentationAlternative {
182
+ sourceRevision: string;
183
+ sourceNodeIds: string[];
184
+ kind: 'json-document' | 'record-component';
185
+ definition: TargetDefinition;
186
+ accounting: Array<{
187
+ nodeId: string;
188
+ keyPath: string[];
189
+ disposition: 'retained';
190
+ }>;
191
+ dependencies: string[];
192
+ mapper: MapperAvailability;
193
+ cardinality: MapperAvailability;
194
+ approved: false;
195
+ }
196
+ /** Generic drafts preserve complete accounting; deployment and approval are caller responsibilities. */
197
+ export declare function deriveRepresentationAlternatives(model: PropertyModel): RepresentationAlternative[];