@almadar/core 7.11.0 → 7.12.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/builders.d.ts +2 -2
- package/dist/builders.js +2 -1
- package/dist/builders.js.map +1 -1
- package/dist/{compose-behaviors-B0k9Zoiw.d.ts → compose-behaviors-D9fgB76L.d.ts} +1 -1
- package/dist/domain-language/index.d.ts +1 -1
- package/dist/domain-language/index.js +4 -3
- package/dist/domain-language/index.js.map +1 -1
- package/dist/index.d.ts +4 -4
- package/dist/index.js +8 -4
- package/dist/index.js.map +1 -1
- package/dist/{schema-CSAEAlE6.d.ts → schema-DyPfxNwk.d.ts} +2 -2
- package/dist/types/index.d.ts +18 -3
- package/dist/types/index.js +8 -4
- package/dist/types/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -753,8 +753,8 @@ interface ServiceParams {
|
|
|
753
753
|
* { name: 'status', type: 'enum', values: ['draft', 'published'] }
|
|
754
754
|
* { name: 'authorId', type: 'relation', relation: { entity: 'User', cardinality: 'one' } }
|
|
755
755
|
*/
|
|
756
|
-
type FieldType = 'string' | 'number' | 'boolean' | 'date' | 'timestamp' | 'datetime' | 'array' | 'object' | 'enum' | 'relation';
|
|
757
|
-
declare const FieldTypeSchema: z.ZodEnum<["string", "number", "boolean", "date", "timestamp", "datetime", "array", "object", "enum", "relation"]>;
|
|
756
|
+
type FieldType = 'string' | 'number' | 'boolean' | 'date' | 'timestamp' | 'datetime' | 'array' | 'object' | 'enum' | 'relation' | 'trait';
|
|
757
|
+
declare const FieldTypeSchema: z.ZodEnum<["string", "number", "boolean", "date", "timestamp", "datetime", "array", "object", "enum", "relation", "trait"]>;
|
|
758
758
|
/**
|
|
759
759
|
* Cardinality for relation fields.
|
|
760
760
|
* Matches Rust compiler's Cardinality enum.
|
package/dist/types/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { cb as ServiceParams, k as OrbitalSchema, g as EntityRow, aX as FieldValue, $ as DeclaredTraitConfig, d as TraitConfig } from '../schema-
|
|
2
|
-
export { A as AGENT_DOMAIN_CATEGORIES, o as ALLOWED_CUSTOM_COMPONENTS, p as AgentDomainCategory, q as AgentDomainCategorySchema, r as AgentEffect, s as AllowedCustomComponent, t as AnimationDef, u as AnimationDefInput, v as AnimationDefSchema, w as AssetMap, x as AssetMapInput, y as AssetMapSchema, z as AssetMapping, B as AssetMappingInput, C as AssetMappingSchema, D as AtomicEffect, F as CallServiceConfig, G as CallServiceEffect, H as CheckpointLoadEffect, I as CheckpointSaveEffect, J as ComputedEventContract, K as ComputedEventContractSchema, L as ComputedEventListener, M as ComputedEventListenerSchema, N as ConfigFieldDeclaration, Q as ConfigFieldDeclarationSchema, V as CustomPatternDefinition, W as CustomPatternDefinitionInput, X as CustomPatternDefinitionSchema, Y as CustomPatternMap, Z as CustomPatternMapInput, _ as CustomPatternMapSchema, a0 as DeclaredTraitConfigSchema, a1 as DerefEffect, a2 as DesignPreferences, a3 as DesignPreferencesInput, a4 as DesignPreferencesSchema, a5 as DesignTokens, a6 as DesignTokensInput, a7 as DesignTokensSchema, a8 as DespawnEffect, a9 as DoEffect, aa as DomainCategory, ab as DomainCategorySchema, ac as DomainContext, ad as DomainContextInput, ae as DomainContextSchema, af as DomainVocabulary, ag as DomainVocabularySchema, ah as ENTITY_ROLES, E as Effect, ai as EffectInput, aj as EffectSchema, ak as EmitConfig, al as EmitEffect, b as Entity, am as EntityCall, an as EntityCallSchema, ao as EntityData, e as EntityField, ap as EntityFieldInput, aq as EntityFieldSchema, f as EntityPersistence, ar as EntityPersistenceSchema, i as EntityRef, as as EntityRefSchema, at as EntityRefStringSchema, au as EntityRole, av as EntityRoleSchema, aw as EntitySchema, ax as EntitySemanticRole, ay as EntitySemanticRoleSchema, az as EvaluateConfig, aA as EvaluateEffect, aB as Event, aC as EventInput, aD as EventListener, aE as EventListenerSchema, aF as EventPayloadField, aG as EventPayloadFieldSchema, aH as EventSchema, aI as EventScope, aJ as EventScopeSchema, aK as EventSemanticRole, aL as EventSemanticRoleSchema, aM as EventSource, aN as EventSourceSchema, aO as FetchEffect, aP as FetchOptions, aQ as FetchResult, aR as Field, aS as FieldFormat, aT as FieldFormatSchema, aU as FieldSchema, aV as FieldType, aW as FieldTypeSchema, aY as ForwardConfig, aZ as ForwardEffect, a_ as FullOrbitalUnit, a$ as GAME_TYPES, b0 as GameSubCategory, b1 as GameSubCategorySchema, b2 as GameType, b3 as GameTypeSchema, b4 as Guard, b5 as GuardInput, b6 as GuardSchema, b7 as ListenSource, b8 as ListenSourceSchema, b9 as LogEffect, ba as McpServiceDef, bb as McpServiceDefSchema, bc as NavigateEffect, bd as NnConfig, be as NnLayer, bf as NodeClassification, bg as NodeClassificationSchema, bh as NotifyEffect, a_ as Orbital, bi as OrbitalConfig, bj as OrbitalConfigInput, bk as OrbitalConfigSchema, O as OrbitalDefinition, bl as OrbitalDefinitionSchema, bm as OrbitalEntity, bn as OrbitalEntityInput, bo as OrbitalEntitySchema, bp as OrbitalInput, bq as OrbitalPage, br as OrbitalPageInput, bs as OrbitalPageSchema, bt as OrbitalPageStrictInput, bu as OrbitalPageStrictSchema, bv as OrbitalSchemaInput, bw as OrbitalSchemaSchema, bx as OrbitalTraitRef, by as OrbitalTraitRefSchema, bz as OrbitalUnit, bA as OrbitalUnitSchema, bB as OrbitalZodSchema, bC as OsEffect, l as Page, P as PageRef, m as PageRefObject, bD as PageRefObjectSchema, bE as PageRefSchema, bF as PageRefStringSchema, bG as PageSchema, bH as PageTraitRef, bI as PageTraitRefSchema, bJ as PayloadField, bK as PayloadFieldSchema, bL as PersistData, bM as PersistEffect, bN as PersistEmitConfig, bO as PresentationType, bP as RefEffect, bQ as RelatedLink, bR as RelatedLinkSchema, bS as RelationConfig, bT as RelationConfigSchema, bU as RenderItemLambda, bV as RenderUIConfig, R as RenderUIEffect, bW as RenderUINode, bX as RequiredField, bY as RequiredFieldSchema, bZ as ResolvedAsset, b_ as ResolvedAssetInput, b$ as ResolvedAssetSchema, c0 as ResolvedPatternProps, c1 as RestAuthConfig, c2 as RestAuthConfigSchema, c3 as RestServiceDef, c4 as RestServiceDefSchema, c5 as SERVICE_TYPES, c6 as SemanticAssetRef, c7 as SemanticAssetRefInput, c8 as SemanticAssetRefSchema, c9 as ServiceDefinition, ca as ServiceDefinitionSchema, cc as ServiceRef, cd as ServiceRefObject, ce as ServiceRefObjectSchema, cf as ServiceRefSchema, cg as ServiceRefStringSchema, ch as ServiceType, ci as ServiceTypeSchema, cj as SetEffect, ck as SocketEvents, cl as SocketEventsSchema, cm as SocketServiceDef, cn as SocketServiceDefSchema, co as SpawnEffect, S as State, cp as StateInput, cq as StateMachine, cr as StateMachineInput, cs as StateMachineSchema, ct as StateSchema, cu as StateSemanticRole, cv as StateSemanticRoleSchema, cw as SuggestedGuard, cx as SuggestedGuardSchema, cy as SwapEffect, cz as ThemeDefinition, cA as ThemeDefinitionSchema, cB as ThemeRef, cC as ThemeRefSchema, cD as ThemeRefStringSchema, cE as ThemeTokens, cF as ThemeTokensSchema, cG as ThemeVariant, cH as ThemeVariantSchema, cI as TrainConfig, cJ as TrainEffect, T as Trait, cK as TraitCategory, cL as TraitCategorySchema, cM as TraitConfigObject, cN as TraitConfigSchema, cO as TraitConfigValue, cP as TraitConfigValueSchema, cQ as TraitDataEntity, cR as TraitDataEntitySchema, cS as TraitEntityField, cT as TraitEntityFieldSchema, a as TraitEventContract, cU as TraitEventContractSchema, c as TraitEventListener, cV as TraitEventListenerSchema, cW as TraitInput, j as TraitRef, cX as TraitRefSchema, n as TraitReference, cY as TraitReferenceInput, cZ as TraitReferenceSchema, c_ as TraitSchema, c$ as TraitTick, d0 as TraitTickSchema, d1 as TraitUIBinding, d2 as Transition, d3 as TransitionInput, d4 as TransitionSchema, d5 as TypedEffect, U as UISlot, d6 as UISlotSchema, d7 as UI_SLOTS, d8 as UXHints, d9 as UXHintsSchema, h as UseDeclaration, da as UseDeclarationSchema, db as UserPersona, dc as UserPersonaInput, dd as UserPersonaSchema, de as VISUAL_STYLES, df as ViewType, dg as ViewTypeSchema, dh as VisualStyle, di as VisualStyleSchema, dj as WatchEffect, dk as WatchOptions, dl as atomic, dm as callService, dn as createAssetKey, dp as deref, dq as deriveCollection, dr as despawn, ds as doEffects, dt as emit, du as findService, dv as getDefaultAnimationsForRole, dw as getServiceNames, dx as getTraitConfig, dy as getTraitName, dz as hasService, dA as isCircuitEvent, dB as isEffect, dC as isEntityCall, dD as isEntityReference, dE as isEntityReferenceAny, dF as isImportedTraitRef, dG as isInlineTrait, dH as isMcpService, dI as isOrbitalDefinition, dJ as isPageReference, dK as isPageReferenceObject, dL as isPageReferenceString, dM as isRestService, dN as isRuntimeEntity, dO as isSExprEffect, dP as isServiceReference, dQ as isServiceReferenceObject, dR as isSingletonEntity, dS as isSocketService, dT as isThemeReference, dU as navigate, dV as normalizeTraitRef, dW as notify, dX as parseAssetKey, dY as parseEntityRef, dZ as parseImportedTraitRef, d_ as parseOrbitalSchema, d$ as parsePageRef, e0 as parseServiceRef, e1 as persist, e2 as ref, e3 as renderUI, e4 as safeParseOrbitalSchema, e5 as set, e6 as spawn, e7 as swap, e8 as validateAssetAnimations, e9 as watch } from '../schema-
|
|
1
|
+
import { cb as ServiceParams, k as OrbitalSchema, g as EntityRow, aX as FieldValue, $ as DeclaredTraitConfig, d as TraitConfig } from '../schema-DyPfxNwk.js';
|
|
2
|
+
export { A as AGENT_DOMAIN_CATEGORIES, o as ALLOWED_CUSTOM_COMPONENTS, p as AgentDomainCategory, q as AgentDomainCategorySchema, r as AgentEffect, s as AllowedCustomComponent, t as AnimationDef, u as AnimationDefInput, v as AnimationDefSchema, w as AssetMap, x as AssetMapInput, y as AssetMapSchema, z as AssetMapping, B as AssetMappingInput, C as AssetMappingSchema, D as AtomicEffect, F as CallServiceConfig, G as CallServiceEffect, H as CheckpointLoadEffect, I as CheckpointSaveEffect, J as ComputedEventContract, K as ComputedEventContractSchema, L as ComputedEventListener, M as ComputedEventListenerSchema, N as ConfigFieldDeclaration, Q as ConfigFieldDeclarationSchema, V as CustomPatternDefinition, W as CustomPatternDefinitionInput, X as CustomPatternDefinitionSchema, Y as CustomPatternMap, Z as CustomPatternMapInput, _ as CustomPatternMapSchema, a0 as DeclaredTraitConfigSchema, a1 as DerefEffect, a2 as DesignPreferences, a3 as DesignPreferencesInput, a4 as DesignPreferencesSchema, a5 as DesignTokens, a6 as DesignTokensInput, a7 as DesignTokensSchema, a8 as DespawnEffect, a9 as DoEffect, aa as DomainCategory, ab as DomainCategorySchema, ac as DomainContext, ad as DomainContextInput, ae as DomainContextSchema, af as DomainVocabulary, ag as DomainVocabularySchema, ah as ENTITY_ROLES, E as Effect, ai as EffectInput, aj as EffectSchema, ak as EmitConfig, al as EmitEffect, b as Entity, am as EntityCall, an as EntityCallSchema, ao as EntityData, e as EntityField, ap as EntityFieldInput, aq as EntityFieldSchema, f as EntityPersistence, ar as EntityPersistenceSchema, i as EntityRef, as as EntityRefSchema, at as EntityRefStringSchema, au as EntityRole, av as EntityRoleSchema, aw as EntitySchema, ax as EntitySemanticRole, ay as EntitySemanticRoleSchema, az as EvaluateConfig, aA as EvaluateEffect, aB as Event, aC as EventInput, aD as EventListener, aE as EventListenerSchema, aF as EventPayloadField, aG as EventPayloadFieldSchema, aH as EventSchema, aI as EventScope, aJ as EventScopeSchema, aK as EventSemanticRole, aL as EventSemanticRoleSchema, aM as EventSource, aN as EventSourceSchema, aO as FetchEffect, aP as FetchOptions, aQ as FetchResult, aR as Field, aS as FieldFormat, aT as FieldFormatSchema, aU as FieldSchema, aV as FieldType, aW as FieldTypeSchema, aY as ForwardConfig, aZ as ForwardEffect, a_ as FullOrbitalUnit, a$ as GAME_TYPES, b0 as GameSubCategory, b1 as GameSubCategorySchema, b2 as GameType, b3 as GameTypeSchema, b4 as Guard, b5 as GuardInput, b6 as GuardSchema, b7 as ListenSource, b8 as ListenSourceSchema, b9 as LogEffect, ba as McpServiceDef, bb as McpServiceDefSchema, bc as NavigateEffect, bd as NnConfig, be as NnLayer, bf as NodeClassification, bg as NodeClassificationSchema, bh as NotifyEffect, a_ as Orbital, bi as OrbitalConfig, bj as OrbitalConfigInput, bk as OrbitalConfigSchema, O as OrbitalDefinition, bl as OrbitalDefinitionSchema, bm as OrbitalEntity, bn as OrbitalEntityInput, bo as OrbitalEntitySchema, bp as OrbitalInput, bq as OrbitalPage, br as OrbitalPageInput, bs as OrbitalPageSchema, bt as OrbitalPageStrictInput, bu as OrbitalPageStrictSchema, bv as OrbitalSchemaInput, bw as OrbitalSchemaSchema, bx as OrbitalTraitRef, by as OrbitalTraitRefSchema, bz as OrbitalUnit, bA as OrbitalUnitSchema, bB as OrbitalZodSchema, bC as OsEffect, l as Page, P as PageRef, m as PageRefObject, bD as PageRefObjectSchema, bE as PageRefSchema, bF as PageRefStringSchema, bG as PageSchema, bH as PageTraitRef, bI as PageTraitRefSchema, bJ as PayloadField, bK as PayloadFieldSchema, bL as PersistData, bM as PersistEffect, bN as PersistEmitConfig, bO as PresentationType, bP as RefEffect, bQ as RelatedLink, bR as RelatedLinkSchema, bS as RelationConfig, bT as RelationConfigSchema, bU as RenderItemLambda, bV as RenderUIConfig, R as RenderUIEffect, bW as RenderUINode, bX as RequiredField, bY as RequiredFieldSchema, bZ as ResolvedAsset, b_ as ResolvedAssetInput, b$ as ResolvedAssetSchema, c0 as ResolvedPatternProps, c1 as RestAuthConfig, c2 as RestAuthConfigSchema, c3 as RestServiceDef, c4 as RestServiceDefSchema, c5 as SERVICE_TYPES, c6 as SemanticAssetRef, c7 as SemanticAssetRefInput, c8 as SemanticAssetRefSchema, c9 as ServiceDefinition, ca as ServiceDefinitionSchema, cc as ServiceRef, cd as ServiceRefObject, ce as ServiceRefObjectSchema, cf as ServiceRefSchema, cg as ServiceRefStringSchema, ch as ServiceType, ci as ServiceTypeSchema, cj as SetEffect, ck as SocketEvents, cl as SocketEventsSchema, cm as SocketServiceDef, cn as SocketServiceDefSchema, co as SpawnEffect, S as State, cp as StateInput, cq as StateMachine, cr as StateMachineInput, cs as StateMachineSchema, ct as StateSchema, cu as StateSemanticRole, cv as StateSemanticRoleSchema, cw as SuggestedGuard, cx as SuggestedGuardSchema, cy as SwapEffect, cz as ThemeDefinition, cA as ThemeDefinitionSchema, cB as ThemeRef, cC as ThemeRefSchema, cD as ThemeRefStringSchema, cE as ThemeTokens, cF as ThemeTokensSchema, cG as ThemeVariant, cH as ThemeVariantSchema, cI as TrainConfig, cJ as TrainEffect, T as Trait, cK as TraitCategory, cL as TraitCategorySchema, cM as TraitConfigObject, cN as TraitConfigSchema, cO as TraitConfigValue, cP as TraitConfigValueSchema, cQ as TraitDataEntity, cR as TraitDataEntitySchema, cS as TraitEntityField, cT as TraitEntityFieldSchema, a as TraitEventContract, cU as TraitEventContractSchema, c as TraitEventListener, cV as TraitEventListenerSchema, cW as TraitInput, j as TraitRef, cX as TraitRefSchema, n as TraitReference, cY as TraitReferenceInput, cZ as TraitReferenceSchema, c_ as TraitSchema, c$ as TraitTick, d0 as TraitTickSchema, d1 as TraitUIBinding, d2 as Transition, d3 as TransitionInput, d4 as TransitionSchema, d5 as TypedEffect, U as UISlot, d6 as UISlotSchema, d7 as UI_SLOTS, d8 as UXHints, d9 as UXHintsSchema, h as UseDeclaration, da as UseDeclarationSchema, db as UserPersona, dc as UserPersonaInput, dd as UserPersonaSchema, de as VISUAL_STYLES, df as ViewType, dg as ViewTypeSchema, dh as VisualStyle, di as VisualStyleSchema, dj as WatchEffect, dk as WatchOptions, dl as atomic, dm as callService, dn as createAssetKey, dp as deref, dq as deriveCollection, dr as despawn, ds as doEffects, dt as emit, du as findService, dv as getDefaultAnimationsForRole, dw as getServiceNames, dx as getTraitConfig, dy as getTraitName, dz as hasService, dA as isCircuitEvent, dB as isEffect, dC as isEntityCall, dD as isEntityReference, dE as isEntityReferenceAny, dF as isImportedTraitRef, dG as isInlineTrait, dH as isMcpService, dI as isOrbitalDefinition, dJ as isPageReference, dK as isPageReferenceObject, dL as isPageReferenceString, dM as isRestService, dN as isRuntimeEntity, dO as isSExprEffect, dP as isServiceReference, dQ as isServiceReferenceObject, dR as isSingletonEntity, dS as isSocketService, dT as isThemeReference, dU as navigate, dV as normalizeTraitRef, dW as notify, dX as parseAssetKey, dY as parseEntityRef, dZ as parseImportedTraitRef, d_ as parseOrbitalSchema, d$ as parsePageRef, e0 as parseServiceRef, e1 as persist, e2 as ref, e3 as renderUI, e4 as safeParseOrbitalSchema, e5 as set, e6 as spawn, e7 as swap, e8 as validateAssetAnimations, e9 as watch } from '../schema-DyPfxNwk.js';
|
|
3
3
|
import { c as EventPayloadValue, b as EventPayload, L as LogMeta, S as SExpr } from '../expression-eBO9-SQM.js';
|
|
4
4
|
export { C as CORE_BINDINGS, a as CoreBinding, E as EvalContext, d as Expression, e as ExpressionInput, f as ExpressionSchema, P as ParsedBinding, g as SExprAtom, h as SExprAtomSchema, i as SExprInput, j as SExprSchema, k as collectBindings, l as getArgs, m as getOperator, n as isBinding, o as isSExpr, p as isSExprAtom, q as isSExprCall, r as isValidBinding, s as parseBinding, t as sexpr, w as walkSExpr } from '../expression-eBO9-SQM.js';
|
|
5
5
|
import { z } from 'zod';
|
|
@@ -140,6 +140,7 @@ declare function getBindingExamples(context: BindingContext): string[];
|
|
|
140
140
|
*
|
|
141
141
|
* @packageDocumentation
|
|
142
142
|
*/
|
|
143
|
+
|
|
143
144
|
type BindingRoot = 'entity' | 'payload' | 'state' | 'config' | 'user' | 'trait' | 'item' | 'now' | 'computed' | 'other';
|
|
144
145
|
/** Every known binding root, in a stable order — useful for exhaustiveness checks. */
|
|
145
146
|
declare const BINDING_ROOTS: readonly BindingRoot[];
|
|
@@ -150,6 +151,20 @@ declare const BINDING_ROOTS: readonly BindingRoot[];
|
|
|
150
151
|
* prefixes.
|
|
151
152
|
*/
|
|
152
153
|
declare function toBindingRoot(root: string): BindingRoot;
|
|
154
|
+
/**
|
|
155
|
+
* A trait reference string of the form `@trait.<TraitName>`. Used as the
|
|
156
|
+
* value type for `trait`-typed config fields. The runtime + compiled codegen
|
|
157
|
+
* both substitute this with embedded trait UI at render time.
|
|
158
|
+
*
|
|
159
|
+
* Branded as a literal-template type so TS narrows on use; consumers should
|
|
160
|
+
* call {@link isTraitFieldRef} to validate runtime values before assignment.
|
|
161
|
+
*/
|
|
162
|
+
type TraitFieldRef = `@trait.${string}`;
|
|
163
|
+
/** Type guard: narrow an unknown value to {@link TraitFieldRef}. */
|
|
164
|
+
declare function isTraitFieldRef(value: unknown): value is TraitFieldRef;
|
|
165
|
+
/** Zod schema for {@link TraitFieldRef} values. Useful when validating analyzer
|
|
166
|
+
* JSON or recipe overrides at runtime boundaries. */
|
|
167
|
+
declare const TraitFieldRefSchema: z.ZodString;
|
|
153
168
|
|
|
154
169
|
/**
|
|
155
170
|
* Agent Types
|
|
@@ -1480,4 +1495,4 @@ interface OrbitalVerificationAPI {
|
|
|
1480
1495
|
clearEventLog?: () => void;
|
|
1481
1496
|
}
|
|
1482
1497
|
|
|
1483
|
-
export { type AgentCodeSearchResult, type AgentCompactResult, type AgentCompactStrategy, type AgentContext, type AgentGenerateOptions, type AgentMemoryCategory, type AgentMemoryRecord, OrbitalSchema as AppSchema, type AppSummary, type AssetLoadStatus, BINDING_CONTEXT_RULES, BINDING_DOCS, BINDING_ROOTS, type BindingContext, type BindingRoot, BindingSchema, type BridgeHealth, type BusEvent, type BusEventListener, type BusEventSource, type CategorizedRemovals, type ChangeAuthor, type ChangeSetDocument, type ChangeSummary, type CheckStatus, type ContextExtensions, type CreateFlow, DEFAULT_INTERACTION_MODELS, DeclaredTraitConfig, type DeleteFlow, type EditFlow, type EffectTrace, EntityRow, type EventEmit, type EventKey, type EventListen, type EventLogEntry, EventPayload, EventPayloadValue, FieldValue, type GitHubLink, type HistoryMeta, type InteractionModel, type InteractionModelInput, InteractionModelSchema, type LazyService, type ListInteraction, LogMeta, OrbitalSchema, type OrbitalVerificationAPI, type PageContentReduction, PatternTypeSchema, type PersistActionName, type ResolvedEntity, type ResolvedEntityBinding, type ResolvedField, type ResolvedIR, type ResolvedNavigation, type ResolvedPage, type ResolvedPattern, type ResolvedSection, type ResolvedSectionEvent, type ResolvedTrait, type ResolvedTraitBinding, type ResolvedTraitDataEntity, type ResolvedTraitEvent, type ResolvedTraitGuard, type ResolvedTraitListener, type ResolvedTraitState, type ResolvedTraitTick, type ResolvedTraitTransition, type ResolvedTraitUIBinding, SExpr, type SaveOptions, type SaveResult, type SchemaChange, type SemanticChangeKind, type SemanticSchemaChange, type ServerResponseTrace, type ServiceAction, type ServiceActionName, type ServiceContract, type ServiceEvents, ServiceParams, type SnapshotDocument, type StatsView, type StoreContract, type StoreFilter, type StoreFilterOp, TraitConfig, type TraitStateSnapshot, type TransitionFrom, type TransitionTrace, type Unsubscribe, type ValidationDocument, type ValidationIssue, type ValidationMeta, type ValidationResults, type VerificationCheck, type VerificationSnapshot, type VerificationSummary, type ViewFlow, createEmptyResolvedPage, createEmptyResolvedTrait, createLazyService, createResolvedField, createTypedEventBus, getAllPatternTypes, getBindingExamples, getInteractionModelForDomain, inferTsType, isResolvedIR, toBindingRoot, validateBindingInContext };
|
|
1498
|
+
export { type AgentCodeSearchResult, type AgentCompactResult, type AgentCompactStrategy, type AgentContext, type AgentGenerateOptions, type AgentMemoryCategory, type AgentMemoryRecord, OrbitalSchema as AppSchema, type AppSummary, type AssetLoadStatus, BINDING_CONTEXT_RULES, BINDING_DOCS, BINDING_ROOTS, type BindingContext, type BindingRoot, BindingSchema, type BridgeHealth, type BusEvent, type BusEventListener, type BusEventSource, type CategorizedRemovals, type ChangeAuthor, type ChangeSetDocument, type ChangeSummary, type CheckStatus, type ContextExtensions, type CreateFlow, DEFAULT_INTERACTION_MODELS, DeclaredTraitConfig, type DeleteFlow, type EditFlow, type EffectTrace, EntityRow, type EventEmit, type EventKey, type EventListen, type EventLogEntry, EventPayload, EventPayloadValue, FieldValue, type GitHubLink, type HistoryMeta, type InteractionModel, type InteractionModelInput, InteractionModelSchema, type LazyService, type ListInteraction, LogMeta, OrbitalSchema, type OrbitalVerificationAPI, type PageContentReduction, PatternTypeSchema, type PersistActionName, type ResolvedEntity, type ResolvedEntityBinding, type ResolvedField, type ResolvedIR, type ResolvedNavigation, type ResolvedPage, type ResolvedPattern, type ResolvedSection, type ResolvedSectionEvent, type ResolvedTrait, type ResolvedTraitBinding, type ResolvedTraitDataEntity, type ResolvedTraitEvent, type ResolvedTraitGuard, type ResolvedTraitListener, type ResolvedTraitState, type ResolvedTraitTick, type ResolvedTraitTransition, type ResolvedTraitUIBinding, SExpr, type SaveOptions, type SaveResult, type SchemaChange, type SemanticChangeKind, type SemanticSchemaChange, type ServerResponseTrace, type ServiceAction, type ServiceActionName, type ServiceContract, type ServiceEvents, ServiceParams, type SnapshotDocument, type StatsView, type StoreContract, type StoreFilter, type StoreFilterOp, TraitConfig, type TraitFieldRef, TraitFieldRefSchema, type TraitStateSnapshot, type TransitionFrom, type TransitionTrace, type Unsubscribe, type ValidationDocument, type ValidationIssue, type ValidationMeta, type ValidationResults, type VerificationCheck, type VerificationSnapshot, type VerificationSummary, type ViewFlow, createEmptyResolvedPage, createEmptyResolvedTrait, createLazyService, createResolvedField, createTypedEventBus, getAllPatternTypes, getBindingExamples, getInteractionModelForDomain, inferTsType, isResolvedIR, isTraitFieldRef, toBindingRoot, validateBindingInContext };
|
package/dist/types/index.js
CHANGED
|
@@ -13,7 +13,8 @@ var FieldTypeSchema = z.enum([
|
|
|
13
13
|
"array",
|
|
14
14
|
"object",
|
|
15
15
|
"enum",
|
|
16
|
-
"relation"
|
|
16
|
+
"relation",
|
|
17
|
+
"trait"
|
|
17
18
|
]);
|
|
18
19
|
var RelationCardinalitySchema = z.enum([
|
|
19
20
|
"one",
|
|
@@ -1266,8 +1267,6 @@ function getBindingExamples(context) {
|
|
|
1266
1267
|
examples.push("@GameConfig.gravity", "@Filter.searchTerm");
|
|
1267
1268
|
return examples;
|
|
1268
1269
|
}
|
|
1269
|
-
|
|
1270
|
-
// src/types/binding.ts
|
|
1271
1270
|
var BINDING_ROOTS = [
|
|
1272
1271
|
"entity",
|
|
1273
1272
|
"payload",
|
|
@@ -1284,6 +1283,11 @@ var KNOWN_ROOTS = new Set(BINDING_ROOTS.filter((r) => r !== "other"));
|
|
|
1284
1283
|
function toBindingRoot(root) {
|
|
1285
1284
|
return KNOWN_ROOTS.has(root) ? root : "other";
|
|
1286
1285
|
}
|
|
1286
|
+
var TRAIT_REF_PATTERN = /^@trait\.[A-Z][a-zA-Z0-9]*$/;
|
|
1287
|
+
function isTraitFieldRef(value) {
|
|
1288
|
+
return typeof value === "string" && TRAIT_REF_PATTERN.test(value);
|
|
1289
|
+
}
|
|
1290
|
+
var TraitFieldRefSchema = z.string().regex(TRAIT_REF_PATTERN, "expected `@trait.<TraitName>` reference");
|
|
1287
1291
|
var InteractionModelSchema = z.object({
|
|
1288
1292
|
createFlow: z.enum(["modal", "page", "inline", "none"]),
|
|
1289
1293
|
editFlow: z.enum(["modal", "page", "inline", "none"]),
|
|
@@ -1426,6 +1430,6 @@ function isResolvedIR(ir) {
|
|
|
1426
1430
|
return typeof r.appName === "string" && r.traits instanceof Map && r.pages instanceof Map;
|
|
1427
1431
|
}
|
|
1428
1432
|
|
|
1429
|
-
export { AGENT_DOMAIN_CATEGORIES, ALLOWED_CUSTOM_COMPONENTS, AgentDomainCategorySchema, AnimationDefSchema, AssetMapSchema, AssetMappingSchema, BINDING_CONTEXT_RULES, BINDING_DOCS, BINDING_ROOTS, BindingSchema, CORE_BINDINGS, ComputedEventContractSchema, ComputedEventListenerSchema, ConfigFieldDeclarationSchema, CustomPatternDefinitionSchema, CustomPatternMapSchema, DEFAULT_INTERACTION_MODELS, DeclaredTraitConfigSchema, DesignPreferencesSchema, DesignTokensSchema, DomainCategorySchema, DomainContextSchema, DomainVocabularySchema, ENTITY_ROLES, EffectSchema, EntityCallSchema, EntityFieldSchema, EntityPersistenceSchema, EntityRefSchema, EntityRefStringSchema, EntityRoleSchema, EntitySchema, EntitySemanticRoleSchema, EventListenerSchema, EventPayloadFieldSchema, EventSchema, EventScopeSchema, EventSemanticRoleSchema, EventSourceSchema, ExpressionSchema, FieldFormatSchema, FieldSchema, FieldTypeSchema, GAME_TYPES, GameSubCategorySchema, GameTypeSchema, GuardSchema, InteractionModelSchema, ListenSourceSchema, McpServiceDefSchema, NodeClassificationSchema, OrbitalConfigSchema, OrbitalDefinitionSchema, OrbitalEntitySchema, OrbitalPageSchema, OrbitalPageStrictSchema, OrbitalSchemaSchema, OrbitalTraitRefSchema, OrbitalUnitSchema, OrbitalSchema as OrbitalZodSchema, PageRefObjectSchema, PageRefSchema, PageRefStringSchema, PageSchema, PageTraitRefSchema, PatternTypeSchema, PayloadFieldSchema, RelatedLinkSchema, RelationConfigSchema, RequiredFieldSchema, ResolvedAssetSchema, RestAuthConfigSchema, RestServiceDefSchema, SERVICE_TYPES, SExprAtomSchema, SExprSchema, SemanticAssetRefSchema, ServiceDefinitionSchema, ServiceRefObjectSchema, ServiceRefSchema, ServiceRefStringSchema, ServiceTypeSchema, SocketEventsSchema, SocketServiceDefSchema, StateMachineSchema, StateSchema, StateSemanticRoleSchema, SuggestedGuardSchema, ThemeDefinitionSchema, ThemeRefSchema, ThemeRefStringSchema, ThemeTokensSchema, ThemeVariantSchema, TraitCategorySchema, TraitConfigSchema, TraitConfigValueSchema, TraitDataEntitySchema, TraitEntityFieldSchema, TraitEventContractSchema, TraitEventListenerSchema, TraitRefSchema, TraitReferenceSchema, TraitSchema, TraitTickSchema, TransitionSchema, UISlotSchema, UI_SLOTS, UXHintsSchema, UseDeclarationSchema, UserPersonaSchema, VISUAL_STYLES, ViewTypeSchema, VisualStyleSchema, atomic, callService, collectBindings, createAssetKey, createEmptyResolvedPage, createEmptyResolvedTrait, createLazyService, createResolvedField, createTypedEventBus, deref, deriveCollection, despawn, doEffects, emit, findService, getAllPatternTypes, getArgs, getBindingExamples, getDefaultAnimationsForRole, getInteractionModelForDomain, getOperator, getServiceNames, getTraitConfig, getTraitName, hasService, inferTsType, isBinding, isCircuitEvent, isEffect, isEntityCall, isEntityReference, isEntityReferenceAny, isImportedTraitRef, isInlineTrait, isMcpService, isOrbitalDefinition, isPageReference, isPageReferenceObject, isPageReferenceString, isResolvedIR, isRestService, isRuntimeEntity, isSExpr, isSExprAtom, isSExprCall, isSExprEffect, isServiceReference, isServiceReferenceObject, isSingletonEntity, isSocketService, isThemeReference, isValidBinding, navigate, normalizeTraitRef, notify, parseAssetKey, parseBinding, parseEntityRef, parseImportedTraitRef, parseOrbitalSchema, parsePageRef, parseServiceRef, persist, ref, renderUI, safeParseOrbitalSchema, set, sexpr, spawn, swap, toBindingRoot, validateAssetAnimations, validateBindingInContext, walkSExpr, watch };
|
|
1433
|
+
export { AGENT_DOMAIN_CATEGORIES, ALLOWED_CUSTOM_COMPONENTS, AgentDomainCategorySchema, AnimationDefSchema, AssetMapSchema, AssetMappingSchema, BINDING_CONTEXT_RULES, BINDING_DOCS, BINDING_ROOTS, BindingSchema, CORE_BINDINGS, ComputedEventContractSchema, ComputedEventListenerSchema, ConfigFieldDeclarationSchema, CustomPatternDefinitionSchema, CustomPatternMapSchema, DEFAULT_INTERACTION_MODELS, DeclaredTraitConfigSchema, DesignPreferencesSchema, DesignTokensSchema, DomainCategorySchema, DomainContextSchema, DomainVocabularySchema, ENTITY_ROLES, EffectSchema, EntityCallSchema, EntityFieldSchema, EntityPersistenceSchema, EntityRefSchema, EntityRefStringSchema, EntityRoleSchema, EntitySchema, EntitySemanticRoleSchema, EventListenerSchema, EventPayloadFieldSchema, EventSchema, EventScopeSchema, EventSemanticRoleSchema, EventSourceSchema, ExpressionSchema, FieldFormatSchema, FieldSchema, FieldTypeSchema, GAME_TYPES, GameSubCategorySchema, GameTypeSchema, GuardSchema, InteractionModelSchema, ListenSourceSchema, McpServiceDefSchema, NodeClassificationSchema, OrbitalConfigSchema, OrbitalDefinitionSchema, OrbitalEntitySchema, OrbitalPageSchema, OrbitalPageStrictSchema, OrbitalSchemaSchema, OrbitalTraitRefSchema, OrbitalUnitSchema, OrbitalSchema as OrbitalZodSchema, PageRefObjectSchema, PageRefSchema, PageRefStringSchema, PageSchema, PageTraitRefSchema, PatternTypeSchema, PayloadFieldSchema, RelatedLinkSchema, RelationConfigSchema, RequiredFieldSchema, ResolvedAssetSchema, RestAuthConfigSchema, RestServiceDefSchema, SERVICE_TYPES, SExprAtomSchema, SExprSchema, SemanticAssetRefSchema, ServiceDefinitionSchema, ServiceRefObjectSchema, ServiceRefSchema, ServiceRefStringSchema, ServiceTypeSchema, SocketEventsSchema, SocketServiceDefSchema, StateMachineSchema, StateSchema, StateSemanticRoleSchema, SuggestedGuardSchema, ThemeDefinitionSchema, ThemeRefSchema, ThemeRefStringSchema, ThemeTokensSchema, ThemeVariantSchema, TraitCategorySchema, TraitConfigSchema, TraitConfigValueSchema, TraitDataEntitySchema, TraitEntityFieldSchema, TraitEventContractSchema, TraitEventListenerSchema, TraitFieldRefSchema, TraitRefSchema, TraitReferenceSchema, TraitSchema, TraitTickSchema, TransitionSchema, UISlotSchema, UI_SLOTS, UXHintsSchema, UseDeclarationSchema, UserPersonaSchema, VISUAL_STYLES, ViewTypeSchema, VisualStyleSchema, atomic, callService, collectBindings, createAssetKey, createEmptyResolvedPage, createEmptyResolvedTrait, createLazyService, createResolvedField, createTypedEventBus, deref, deriveCollection, despawn, doEffects, emit, findService, getAllPatternTypes, getArgs, getBindingExamples, getDefaultAnimationsForRole, getInteractionModelForDomain, getOperator, getServiceNames, getTraitConfig, getTraitName, hasService, inferTsType, isBinding, isCircuitEvent, isEffect, isEntityCall, isEntityReference, isEntityReferenceAny, isImportedTraitRef, isInlineTrait, isMcpService, isOrbitalDefinition, isPageReference, isPageReferenceObject, isPageReferenceString, isResolvedIR, isRestService, isRuntimeEntity, isSExpr, isSExprAtom, isSExprCall, isSExprEffect, isServiceReference, isServiceReferenceObject, isSingletonEntity, isSocketService, isThemeReference, isTraitFieldRef, isValidBinding, navigate, normalizeTraitRef, notify, parseAssetKey, parseBinding, parseEntityRef, parseImportedTraitRef, parseOrbitalSchema, parsePageRef, parseServiceRef, persist, ref, renderUI, safeParseOrbitalSchema, set, sexpr, spawn, swap, toBindingRoot, validateAssetAnimations, validateBindingInContext, walkSExpr, watch };
|
|
1430
1434
|
//# sourceMappingURL=index.js.map
|
|
1431
1435
|
//# sourceMappingURL=index.js.map
|