@almadar/ui 5.75.0 → 5.76.1
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/avl/index.cjs +2545 -6006
- package/dist/avl/index.d.ts +43 -43
- package/dist/avl/index.js +1250 -4711
- package/dist/components/avl/atoms/AvlApplication.d.ts +1 -1
- package/dist/components/avl/atoms/AvlBindingRef.d.ts +1 -1
- package/dist/components/avl/atoms/AvlEffect.d.ts +1 -1
- package/dist/components/avl/atoms/AvlEntity.d.ts +1 -1
- package/dist/components/avl/atoms/AvlEvent.d.ts +1 -1
- package/dist/components/avl/atoms/AvlField.d.ts +1 -1
- package/dist/components/avl/atoms/AvlFieldType.d.ts +1 -1
- package/dist/components/avl/atoms/AvlGuard.d.ts +1 -1
- package/dist/components/avl/atoms/AvlLiteral.d.ts +1 -1
- package/dist/components/avl/atoms/AvlOperator.d.ts +1 -1
- package/dist/components/avl/atoms/AvlPage.d.ts +1 -1
- package/dist/components/avl/atoms/AvlPersistence.d.ts +1 -1
- package/dist/components/avl/atoms/AvlSExpr.d.ts +1 -1
- package/dist/components/avl/atoms/AvlState.d.ts +2 -2
- package/dist/components/avl/atoms/index.d.ts +4 -4
- package/dist/components/avl/{molecules → lib}/avl-behavior-compose-converter.d.ts +1 -1
- package/dist/components/avl/{molecules → lib}/avl-elk-layout.d.ts +2 -2
- package/dist/components/avl/{molecules → lib}/avl-flow-converter.d.ts +1 -1
- package/dist/components/avl/{molecules → lib}/avl-preview-converter.d.ts +1 -1
- package/dist/components/avl/{molecules → lib}/avl-story-schemas.d.ts +6 -6
- package/dist/components/avl/{molecules → lib}/avl-zoom-band.d.ts +1 -1
- package/dist/components/avl/molecules/Avl3DExprTree.d.ts +1 -1
- package/dist/components/avl/molecules/AvlBehaviorGlyph.d.ts +1 -1
- package/dist/components/avl/molecules/AvlClosedCircuit.d.ts +1 -1
- package/dist/components/avl/molecules/AvlOrbitalUnit.d.ts +1 -1
- package/dist/components/avl/molecules/AvlStateMachine.d.ts +1 -1
- package/dist/components/avl/molecules/AvlTransitionLane.d.ts +1 -1
- package/dist/components/avl/molecules/BehaviorView.d.ts +1 -1
- package/dist/components/avl/molecules/DetailView.d.ts +1 -1
- package/dist/components/avl/molecules/MiniStateMachine.d.ts +1 -1
- package/dist/components/avl/molecules/ModuleCard.d.ts +1 -1
- package/dist/components/avl/molecules/OrbPreviewNode.d.ts +1 -1
- package/dist/components/avl/molecules/SystemNode.d.ts +1 -1
- package/dist/components/avl/molecules/index.d.ts +9 -9
- package/dist/components/avl/organisms/Avl3DApplicationScene.d.ts +1 -1
- package/dist/components/avl/organisms/Avl3DEffects.d.ts +1 -1
- package/dist/components/avl/organisms/Avl3DOrbitalScene.d.ts +1 -1
- package/dist/components/avl/organisms/Avl3DTraitScene.d.ts +1 -1
- package/dist/components/avl/organisms/Avl3DTransitionScene.d.ts +1 -1
- package/dist/components/avl/organisms/Avl3DViewer.d.ts +2 -2
- package/dist/components/avl/organisms/AvlCosmicZoom.d.ts +1 -1
- package/dist/components/avl/organisms/AvlLegend.d.ts +1 -1
- package/dist/components/avl/organisms/AvlTraitScene.d.ts +1 -1
- package/dist/components/avl/organisms/AvlTransitionDetail.d.ts +1 -1
- package/dist/components/avl/organisms/AvlTransitionScene.d.ts +1 -1
- package/dist/components/avl/organisms/FlowCanvas.d.ts +2 -2
- package/dist/components/avl/organisms/OrbInspector.d.ts +1 -1
- package/dist/components/avl/organisms/ZoomBreadcrumb.d.ts +1 -1
- package/dist/components/avl/organisms/ZoomLegend.d.ts +1 -1
- package/dist/components/avl/organisms/index.d.ts +2 -2
- package/dist/components/avl/{molecules → types}/avl-behavior-compose-types.d.ts +1 -1
- package/dist/components/avl/{molecules → types}/avl-canvas-types.d.ts +1 -1
- package/dist/components/core/atoms/index.d.ts +2 -3
- package/dist/components/core/molecules/Breadcrumb.d.ts +1 -1
- package/dist/components/core/molecules/Card.d.ts +1 -1
- package/dist/components/core/molecules/Chart.d.ts +0 -2
- package/dist/components/core/molecules/ConfirmDialog.d.ts +0 -2
- package/dist/components/core/molecules/DataGrid.d.ts +1 -1
- package/dist/components/core/molecules/DataList.d.ts +1 -1
- package/dist/components/core/molecules/EmptyState.d.ts +1 -1
- package/dist/components/core/molecules/FloatingActionButton.d.ts +1 -1
- package/dist/components/core/molecules/FormSectionHeader.d.ts +1 -1
- package/dist/components/core/molecules/GraphCanvas.d.ts +0 -2
- package/dist/components/core/molecules/Header.d.ts +1 -1
- package/dist/components/core/molecules/Menu.d.ts +1 -1
- package/dist/components/core/molecules/Navigation.d.ts +1 -1
- package/dist/components/core/molecules/OrbitalVisualization.d.ts +0 -2
- package/dist/components/core/molecules/PageHeader.d.ts +1 -1
- package/dist/components/core/molecules/Section.d.ts +0 -2
- package/dist/components/core/molecules/Sidebar.d.ts +1 -1
- package/dist/components/core/molecules/SignaturePad.d.ts +0 -2
- package/dist/components/core/molecules/Split.d.ts +0 -2
- package/dist/components/core/molecules/StatDisplay.d.ts +1 -1
- package/dist/components/core/molecules/SwipeableRow.d.ts +1 -1
- package/dist/components/core/molecules/TableView.d.ts +1 -1
- package/dist/components/core/molecules/Tabs.d.ts +1 -1
- package/dist/components/core/molecules/UploadDropZone.d.ts +1 -1
- package/dist/components/core/molecules/WizardContainer.d.ts +0 -2
- package/dist/components/core/molecules/index.d.ts +1 -1
- package/dist/components/core/organisms/UISlotRenderer.d.ts +1 -1
- package/dist/components/core/organisms/index.d.ts +4 -4
- package/dist/components/core/templates/index.d.ts +12 -12
- package/dist/components/game/2d/{ActionButton.d.ts → atoms/ActionButton.d.ts} +1 -1
- package/dist/components/game/2d/{ChoiceButton.d.ts → atoms/ChoiceButton.d.ts} +1 -1
- package/dist/components/game/2d/{ControlButton.d.ts → atoms/ControlButton.d.ts} +1 -1
- package/dist/components/game/2d/{GameAudioToggle.d.ts → atoms/GameAudioToggle.d.ts} +1 -3
- package/dist/components/game/2d/atoms/GameIcon.d.ts +18 -0
- package/dist/components/game/2d/{ItemSlot.d.ts → atoms/ItemSlot.d.ts} +1 -1
- package/dist/components/game/2d/{MiniMap.d.ts → atoms/MiniMap.d.ts} +1 -1
- package/dist/components/game/2d/{ResourceCounter.d.ts → atoms/ResourceCounter.d.ts} +2 -2
- package/dist/components/game/2d/{ScoreDisplay.d.ts → atoms/ScoreDisplay.d.ts} +1 -1
- package/dist/components/game/2d/{Sprite.d.ts → atoms/Sprite.d.ts} +1 -1
- package/dist/components/game/2d/{StateIndicator.d.ts → atoms/StateIndicator.d.ts} +5 -4
- package/dist/components/game/2d/{StatusEffect.d.ts → atoms/StatusEffect.d.ts} +2 -2
- package/dist/components/game/2d/{WaypointMarker.d.ts → atoms/WaypointMarker.d.ts} +1 -1
- package/dist/components/game/2d/{Canvas2D.d.ts → molecules/Canvas2D.d.ts} +3 -3
- package/dist/components/game/2d/{ControlGrid.d.ts → molecules/ControlGrid.d.ts} +3 -2
- package/dist/components/game/2d/{GameHud.d.ts → molecules/GameHud.d.ts} +3 -1
- package/dist/components/game/2d/{GameMenu.d.ts → molecules/GameMenu.d.ts} +1 -1
- package/dist/components/game/2d/{InventoryGrid.d.ts → molecules/InventoryGrid.d.ts} +3 -2
- package/dist/components/game/2d/{ResourceBar.d.ts → molecules/ResourceBar.d.ts} +3 -1
- package/dist/components/game/2d/{StatBadge.d.ts → molecules/StatBadge.d.ts} +1 -1
- package/dist/components/game/2d/molecules/index.d.ts +107 -0
- package/dist/components/game/2d/{ActionTile.d.ts → organisms/ActionTile.d.ts} +1 -1
- package/dist/components/game/2d/{BattleBoard.d.ts → organisms/BattleBoard.d.ts} +4 -3
- package/dist/components/game/2d/{BoardgameBoard.d.ts → organisms/BoardgameBoard.d.ts} +3 -3
- package/dist/components/game/2d/{BuilderBoard.d.ts → organisms/BuilderBoard.d.ts} +7 -3
- package/dist/components/game/2d/{CanvasEffect.d.ts → organisms/CanvasEffect.d.ts} +4 -4
- package/dist/components/game/2d/{CardBattlerBoard.d.ts → organisms/CardBattlerBoard.d.ts} +1 -1
- package/dist/components/game/2d/{CastleBoard.d.ts → organisms/CastleBoard.d.ts} +2 -1
- package/dist/components/game/2d/{CityBuilderBoard.d.ts → organisms/CityBuilderBoard.d.ts} +1 -1
- package/dist/components/game/2d/{ClassifierBoard.d.ts → organisms/ClassifierBoard.d.ts} +7 -3
- package/dist/components/game/2d/{DebuggerBoard.d.ts → organisms/DebuggerBoard.d.ts} +7 -3
- package/dist/components/game/2d/{EventHandlerBoard.d.ts → organisms/EventHandlerBoard.d.ts} +1 -1
- package/dist/components/game/2d/{FishingBoard.d.ts → organisms/FishingBoard.d.ts} +12 -2
- package/dist/components/game/2d/{HexStrategyBoard.d.ts → organisms/HexStrategyBoard.d.ts} +13 -6
- package/dist/components/game/2d/{HolidayRunnerBoard.d.ts → organisms/HolidayRunnerBoard.d.ts} +3 -3
- package/dist/components/game/2d/{MatchPuzzleBoard.d.ts → organisms/MatchPuzzleBoard.d.ts} +3 -3
- package/dist/components/game/2d/{MinigolfBoard.d.ts → organisms/MinigolfBoard.d.ts} +3 -3
- package/dist/components/game/2d/{NegotiatorBoard.d.ts → organisms/NegotiatorBoard.d.ts} +7 -3
- package/dist/components/game/2d/{PinballBoard.d.ts → organisms/PinballBoard.d.ts} +12 -4
- package/dist/components/game/2d/{PirateBoard.d.ts → organisms/PirateBoard.d.ts} +13 -6
- package/dist/components/game/2d/{PlatformerBoard.d.ts → organisms/PlatformerBoard.d.ts} +1 -1
- package/dist/components/game/2d/{RacingBoard.d.ts → organisms/RacingBoard.d.ts} +13 -6
- package/dist/components/game/2d/{RoguelikeBoard.d.ts → organisms/RoguelikeBoard.d.ts} +2 -2
- package/dist/components/game/2d/{SequencerBoard.d.ts → organisms/SequencerBoard.d.ts} +1 -1
- package/dist/components/game/2d/{SimulationCanvas.d.ts → organisms/SimulationCanvas.d.ts} +3 -2
- package/dist/components/game/2d/{SimulationControls.d.ts → organisms/SimulationControls.d.ts} +6 -1
- package/dist/components/game/2d/{SimulatorBoard.d.ts → organisms/SimulatorBoard.d.ts} +7 -3
- package/dist/components/game/2d/{SokobanBoard.d.ts → organisms/SokobanBoard.d.ts} +3 -3
- package/dist/components/game/2d/{SpaceShmupBoard.d.ts → organisms/SpaceShmupBoard.d.ts} +13 -6
- package/dist/components/game/2d/{SpaceStationBoard.d.ts → organisms/SpaceStationBoard.d.ts} +3 -3
- package/dist/components/game/2d/{SportsBoard.d.ts → organisms/SportsBoard.d.ts} +3 -3
- package/dist/components/game/2d/{StateArchitectBoard.d.ts → organisms/StateArchitectBoard.d.ts} +1 -1
- package/dist/components/game/2d/{StateNode.d.ts → organisms/StateNode.d.ts} +1 -1
- package/dist/components/game/2d/{TanksBoard.d.ts → organisms/TanksBoard.d.ts} +3 -3
- package/dist/components/game/2d/{TowerDefenseBoard.d.ts → organisms/TowerDefenseBoard.d.ts} +1 -1
- package/dist/components/game/2d/{TraitSlot.d.ts → organisms/TraitSlot.d.ts} +1 -1
- package/dist/components/game/2d/{TraitStateViewer.d.ts → organisms/TraitStateViewer.d.ts} +2 -2
- package/dist/components/game/2d/{TransitionArrow.d.ts → organisms/TransitionArrow.d.ts} +1 -1
- package/dist/components/game/2d/{UncontrolledBattleBoard.d.ts → organisms/UncontrolledBattleBoard.d.ts} +1 -1
- package/dist/components/game/2d/{VisualNovelBoard.d.ts → organisms/VisualNovelBoard.d.ts} +1 -9
- package/dist/components/game/2d/{WorldMapBoard.d.ts → organisms/WorldMapBoard.d.ts} +4 -3
- package/dist/components/game/2d/{BattleTemplate.d.ts → templates/BattleTemplate.d.ts} +4 -4
- package/dist/components/game/2d/{CardBattlerTemplate.d.ts → templates/CardBattlerTemplate.d.ts} +2 -2
- package/dist/components/game/2d/{CastleTemplate.d.ts → templates/CastleTemplate.d.ts} +4 -4
- package/dist/components/game/2d/{CityBuilderTemplate.d.ts → templates/CityBuilderTemplate.d.ts} +2 -2
- package/dist/components/game/2d/{GameTemplate.d.ts → templates/GameTemplate.d.ts} +1 -1
- package/dist/components/game/2d/{PlatformerTemplate.d.ts → templates/PlatformerTemplate.d.ts} +2 -2
- package/dist/components/game/2d/{RoguelikeTemplate.d.ts → templates/RoguelikeTemplate.d.ts} +3 -3
- package/dist/components/game/2d/{TopDownShooterTemplate.d.ts → templates/TopDownShooterTemplate.d.ts} +2 -2
- package/dist/components/game/2d/{TowerDefenseTemplate.d.ts → templates/TowerDefenseTemplate.d.ts} +2 -2
- package/dist/components/game/2d/{VisualNovelTemplate.d.ts → templates/VisualNovelTemplate.d.ts} +2 -2
- package/dist/components/game/2d/{WorldMapTemplate.d.ts → templates/WorldMapTemplate.d.ts} +4 -4
- package/dist/components/game/3d/{Canvas3D.d.ts → molecules/Canvas3D.d.ts} +1 -1
- package/dist/components/game/3d/{GameCanvas3D.d.ts → molecules/GameCanvas3D.d.ts} +3 -3
- package/dist/components/game/3d/{index.d.ts → molecules/index.d.ts} +20 -25
- package/dist/components/game/3d/{GameBoard3D.d.ts → organisms/GameBoard3D.d.ts} +2 -2
- package/dist/components/game/3d/{GameCanvas3DBattleTemplate.d.ts → templates/GameCanvas3DBattleTemplate.d.ts} +3 -3
- package/dist/components/game/3d/{GameCanvas3DCastleTemplate.d.ts → templates/GameCanvas3DCastleTemplate.d.ts} +3 -3
- package/dist/components/game/3d/{GameCanvas3DWorldMapTemplate.d.ts → templates/GameCanvas3DWorldMapTemplate.d.ts} +3 -3
- package/dist/components/game/{3d → shared/hooks}/useAssetLoader.d.ts +1 -1
- package/dist/components/game/{2d → shared/hooks}/useBattleState.d.ts +1 -1
- package/dist/components/game/{2d → shared/hooks}/useCamera.d.ts +1 -1
- package/dist/components/game/{2d → shared/hooks}/useCanvasEffects.d.ts +1 -1
- package/dist/components/game/{3d → shared/hooks}/useGameCanvas3DEvents.d.ts +1 -1
- package/dist/components/game/{3d → shared/hooks}/useThree.d.ts +1 -1
- package/dist/components/game/{2d → shared/hooks}/useUnitSpriteAtlas.d.ts +2 -2
- package/dist/components/game/shared/index.d.ts +0 -2
- package/dist/components/game/{2d → shared/lib}/editorUtils.d.ts +6 -1
- package/dist/components/game/{2d → shared/lib}/game3dAssetManifest.d.ts +1 -1
- package/dist/components/game/{2d → shared/lib}/mechanics.d.ts +1 -1
- package/dist/components/game/{2d → shared/lib}/physicsPresets.d.ts +2 -2
- package/dist/components/game/{2d → shared/lib}/puzzleObject.d.ts +1 -1
- package/dist/components/game/{2d → shared/providers}/GameAudioProvider.d.ts +3 -4
- package/dist/components/index.cjs +4459 -5117
- package/dist/components/index.d.ts +5 -5
- package/dist/components/index.js +3378 -4061
- package/dist/context/index.cjs +93 -827
- package/dist/context/index.d.ts +8 -8
- package/dist/context/index.js +3 -807
- package/dist/hooks/index.cjs +9 -278
- package/dist/hooks/index.d.ts +5 -6
- package/dist/hooks/index.js +11 -262
- package/dist/hooks/useAgentChat.d.ts +7 -6
- package/dist/{renderer → hooks}/useClientEffects.d.ts +1 -1
- package/dist/hooks/useCompile.d.ts +2 -6
- package/dist/hooks/useDeepAgentGeneration.d.ts +4 -4
- package/dist/hooks/useEventBus.d.ts +5 -3
- package/dist/hooks/useFileSystem.d.ts +11 -1
- package/dist/hooks/useOrbitalHistory.d.ts +2 -2
- package/dist/hooks/useQuerySingleton.d.ts +5 -4
- package/dist/{runtime → hooks}/useResolvedSchema.d.ts +1 -1
- package/dist/{runtime → hooks}/useTraitStateMachine.d.ts +5 -5
- package/dist/hooks/useUISlots.d.ts +7 -10
- package/dist/lib/api-client.d.ts +4 -3
- package/dist/{renderer → lib}/client-effect-executor.d.ts +4 -15
- package/dist/{runtime → lib}/createClientEffectHandlers.d.ts +4 -4
- package/dist/{renderer → lib}/data-resolver.d.ts +3 -16
- package/dist/lib/debugRegistry.d.ts +8 -7
- package/dist/lib/entityDebug.d.ts +4 -3
- package/dist/lib/getNestedValue.d.ts +15 -3
- package/dist/lib/guardRegistry.d.ts +3 -2
- package/dist/lib/index.cjs +11 -12
- package/dist/lib/index.d.ts +1 -1
- package/dist/lib/index.js +11 -12
- package/dist/lib/jazari/layout.d.ts +3 -2
- package/dist/{renderer → lib}/offline-executor.d.ts +6 -5
- package/dist/lib/parseContentSegments.d.ts +2 -1
- package/dist/{renderer → lib}/pattern-resolver.d.ts +2 -2
- package/dist/{runtime → lib}/perf.d.ts +0 -2
- package/dist/{renderer → lib}/slot-definitions.d.ts +3 -15
- package/dist/{renderer → lib}/trait-binding-resolver.d.ts +6 -2
- package/dist/lib/visualizer/browser.d.ts +3 -2
- package/dist/lib/visualizer/index.d.ts +6 -5
- package/dist/marketing/index.cjs +6 -6
- package/dist/marketing/index.js +6 -6
- package/dist/{runtime → providers}/EntitySchemaContext.d.ts +0 -4
- package/dist/providers/EventBusProvider.d.ts +3 -2
- package/dist/providers/OfflineModeProvider.d.ts +1 -1
- package/dist/providers/OrbitalProvider.d.ts +5 -4
- package/dist/providers/SelectionProvider.d.ts +6 -5
- package/dist/{runtime → providers}/ServerBridge.d.ts +14 -11
- package/dist/{context → providers}/ThemeContext.d.ts +5 -5
- package/dist/{runtime → providers}/TraitProvider.d.ts +4 -3
- package/dist/{context → providers}/UISlotContext.d.ts +2 -2
- package/dist/{context → providers}/UserContext.d.ts +3 -2
- package/dist/providers/VerificationProvider.d.ts +2 -1
- package/dist/providers/index.cjs +2679 -5114
- package/dist/providers/index.d.ts +7 -1
- package/dist/providers/index.js +1597 -4087
- package/dist/{renderer → providers}/navigation.d.ts +7 -7
- package/dist/renderer/index.cjs +84 -322
- package/dist/renderer/index.d.ts +12 -12
- package/dist/renderer/index.js +30 -301
- package/dist/runtime/OrbPreview.d.ts +1 -1
- package/dist/runtime/index.cjs +2809 -6315
- package/dist/runtime/index.d.ts +11 -11
- package/dist/runtime/index.js +1740 -5270
- package/dist/{hooks → types}/event-bus-types.d.ts +2 -1
- package/dist/{renderer/types.d.ts → types/renderer-types.d.ts} +14 -28
- package/dist/types/runtime-types.d.ts +21 -0
- package/dist/{runtime/ui → types}/slot-types.d.ts +5 -4
- package/locales/index.ts +1 -1
- package/package.json +4 -21
- package/dist/components/core/atoms/ThemeSelector.d.ts +0 -21
- package/dist/components/game/2d/CardHand.d.ts +0 -35
- package/dist/components/game/2d/CombatLog.d.ts +0 -30
- package/dist/components/game/2d/CraftingRecipe.d.ts +0 -40
- package/dist/components/game/2d/DialogueBox.d.ts +0 -66
- package/dist/components/game/2d/EnemyPlate.d.ts +0 -30
- package/dist/components/game/2d/GameCanvas2D.d.ts +0 -27
- package/dist/components/game/2d/GameOverScreen.d.ts +0 -57
- package/dist/components/game/2d/HealthPanel.d.ts +0 -31
- package/dist/components/game/2d/InventoryPanel.d.ts +0 -58
- package/dist/components/game/2d/IsometricCanvas.d.ts +0 -137
- package/dist/components/game/2d/PlatformerCanvas.d.ts +0 -60
- package/dist/components/game/2d/PowerupSlots.d.ts +0 -26
- package/dist/components/game/2d/QuestTracker.d.ts +0 -20
- package/dist/components/game/2d/ScoreBoard.d.ts +0 -18
- package/dist/components/game/2d/TurnPanel.d.ts +0 -32
- package/dist/components/game/2d/UnitCommandBar.d.ts +0 -25
- package/dist/components/game/2d/index.d.ts +0 -122
- package/dist/components/game/3d/FeatureRenderer.d.ts +0 -38
- package/dist/components/game/3d/FeatureRenderer3D.d.ts +0 -44
- package/dist/components/game/3d/PhysicsObject3D.d.ts +0 -74
- package/dist/components/game/3d/TileRenderer.d.ts +0 -57
- package/dist/components/game/3d/UnitRenderer.d.ts +0 -46
- package/dist/components/game/3d/index.cjs +0 -7715
- package/dist/components/game/3d/index.css +0 -503
- package/dist/components/game/3d/index.js +0 -7633
- package/dist/components/game/3d/patterns.d.ts +0 -20
- package/dist/components/game/shared/combatEffects.d.ts +0 -64
- package/dist/docs/index.cjs +0 -7024
- package/dist/docs/index.css +0 -1252
- package/dist/docs/index.d.cts +0 -574
- package/dist/docs/index.d.ts +0 -29
- package/dist/docs/index.js +0 -6981
- package/dist/hooks/useAgentTrace.d.ts +0 -85
- package/dist/hooks/useEntities.d.ts +0 -52
- package/dist/hooks/usePinchZoom.d.ts +0 -22
- package/dist/runtime/types.d.ts +0 -37
- package/dist/stores/entityStore.d.ts +0 -99
- package/dist/stores/filtering.d.ts +0 -51
- package/dist/stores/index.cjs +0 -217
- package/dist/stores/index.d.ts +0 -7
- package/dist/stores/index.js +0 -194
- /package/dist/components/avl/{molecules → hooks}/useCanvasDnd.d.ts +0 -0
- /package/dist/components/avl/{organisms → lib}/avl-3d-layout.d.ts +0 -0
- /package/dist/components/avl/{molecules → lib}/avl-layout.d.ts +0 -0
- /package/dist/components/avl/{organisms → lib}/avl-schema-parser.d.ts +0 -0
- /package/dist/components/avl/{organisms → lib}/avl-zoom-state.d.ts +0 -0
- /package/dist/components/avl/{derive-edit-focus.d.ts → lib/derive-edit-focus.d.ts} +0 -0
- /package/dist/components/avl/{molecules → lib}/wire-validation.d.ts +0 -0
- /package/dist/components/avl/{organisms → providers}/avl-3d-context.d.ts +0 -0
- /package/dist/components/avl/{atoms/types.d.ts → types/avl-atom-types.d.ts} +0 -0
- /package/dist/components/avl/{molecules → types}/avl-preview-types.d.ts +0 -0
- /package/dist/components/game/2d/{ComboCounter.d.ts → atoms/ComboCounter.d.ts} +0 -0
- /package/dist/components/game/2d/{DamageNumber.d.ts → atoms/DamageNumber.d.ts} +0 -0
- /package/dist/components/game/2d/{DialogueBubble.d.ts → atoms/DialogueBubble.d.ts} +0 -0
- /package/dist/components/game/2d/{GameCard.d.ts → atoms/GameCard.d.ts} +0 -0
- /package/dist/components/game/2d/{HealthBar.d.ts → atoms/HealthBar.d.ts} +0 -0
- /package/dist/components/game/2d/{TimerDisplay.d.ts → atoms/TimerDisplay.d.ts} +0 -0
- /package/dist/components/game/2d/{TurnIndicator.d.ts → atoms/TurnIndicator.d.ts} +0 -0
- /package/dist/components/game/2d/{ActionPalette.d.ts → organisms/ActionPalette.d.ts} +0 -0
- /package/dist/components/game/2d/{EventLog.d.ts → organisms/EventLog.d.ts} +0 -0
- /package/dist/components/game/2d/{ObjectRulePanel.d.ts → organisms/ObjectRulePanel.d.ts} +0 -0
- /package/dist/components/game/2d/{RuleEditor.d.ts → organisms/RuleEditor.d.ts} +0 -0
- /package/dist/components/game/2d/{SequenceBar.d.ts → organisms/SequenceBar.d.ts} +0 -0
- /package/dist/components/game/2d/{SimulationGraph.d.ts → organisms/SimulationGraph.d.ts} +0 -0
- /package/dist/components/game/2d/{StateJsonView.d.ts → organisms/StateJsonView.d.ts} +0 -0
- /package/dist/components/game/2d/{TopDownShooterBoard.d.ts → organisms/TopDownShooterBoard.d.ts} +0 -0
- /package/dist/components/game/2d/{VariablePanel.d.ts → organisms/VariablePanel.d.ts} +0 -0
- /package/dist/components/game/2d/{GameShell.d.ts → templates/GameShell.d.ts} +0 -0
- /package/dist/components/game/3d/{Camera3D.d.ts → molecules/Camera3D.d.ts} +0 -0
- /package/dist/components/game/3d/{Canvas3DErrorBoundary.d.ts → molecules/Canvas3DErrorBoundary.d.ts} +0 -0
- /package/dist/components/game/3d/{Canvas3DLoadingState.d.ts → molecules/Canvas3DLoadingState.d.ts} +0 -0
- /package/dist/components/game/3d/{Lighting3D.d.ts → molecules/Lighting3D.d.ts} +0 -0
- /package/dist/components/game/3d/{ModelLoader.d.ts → molecules/ModelLoader.d.ts} +0 -0
- /package/dist/components/game/3d/{Scene3D.d.ts → molecules/Scene3D.d.ts} +0 -0
- /package/dist/components/game/{2d → shared/hooks}/useGameAudio.d.ts +0 -0
- /package/dist/components/game/{3d → shared/hooks}/useRaycaster.d.ts +0 -0
- /package/dist/components/game/{3d → shared/hooks}/useSceneGraph.d.ts +0 -0
- /package/dist/components/game/{3d → shared/lib}/AssetLoader.d.ts +0 -0
- /package/dist/components/game/{3d → shared/lib}/culling.d.ts +0 -0
- /package/dist/components/game/{3d → shared/lib}/grid3D.d.ts +0 -0
- /package/dist/components/game/{2d/types.d.ts → shared/lib/physicsTypes.d.ts} +0 -0
- /package/dist/{runtime → lib}/embedded-traits.d.ts +0 -0
- /package/dist/{runtime → lib}/fn-form-lambda.d.ts +0 -0
- /package/dist/{renderer → lib}/init.d.ts +0 -0
- /package/dist/{runtime → lib}/orbitalsByTrait.d.ts +0 -0
- /package/dist/{runtime → lib}/prepareSchemaForPreview.d.ts +0 -0
- /package/dist/{context → lib}/themeTokens.d.ts +0 -0
- /package/dist/{runtime → lib}/wrapCallbackForEvent.d.ts +0 -0
- /package/dist/{context → providers}/CurrentPagePathContext.d.ts +0 -0
- /package/dist/{context → providers}/DesignThemeContext.d.ts +0 -0
- /package/dist/{context → providers}/OrbitalThemeProvider.d.ts +0 -0
|
@@ -9,7 +9,8 @@
|
|
|
9
9
|
*
|
|
10
10
|
* @packageDocumentation
|
|
11
11
|
*/
|
|
12
|
-
import type {
|
|
12
|
+
import type { FieldValue } from '@almadar/core';
|
|
13
|
+
import type { ClientEffect, ClientEffectExecutorConfig, PatternConfig, NotifyOptions } from '../types/renderer-types';
|
|
13
14
|
/**
|
|
14
15
|
* Execute an array of client effects.
|
|
15
16
|
*
|
|
@@ -40,29 +41,17 @@ export declare function executeClientEffects(effects: ClientEffect[], config: Cl
|
|
|
40
41
|
* Parse a raw effect array into a typed ClientEffect.
|
|
41
42
|
* Handles unknown effect formats gracefully.
|
|
42
43
|
*/
|
|
43
|
-
export declare function parseClientEffect(raw:
|
|
44
|
+
export declare function parseClientEffect(raw: FieldValue[]): ClientEffect | null;
|
|
44
45
|
/**
|
|
45
46
|
* Parse an array of raw effects into typed ClientEffects.
|
|
46
47
|
* Filters out invalid effects.
|
|
47
48
|
*/
|
|
48
|
-
export declare function parseClientEffects(raw:
|
|
49
|
-
/**
|
|
50
|
-
* Filter effects by type.
|
|
51
|
-
*/
|
|
52
|
-
export declare function filterEffectsByType<T extends ClientEffect[0]>(effects: ClientEffect[], type: T): Extract<ClientEffect, [T, ...unknown[]]>[];
|
|
49
|
+
export declare function parseClientEffects(raw: FieldValue[] | undefined): ClientEffect[];
|
|
53
50
|
/**
|
|
54
51
|
* Get all render-ui effects.
|
|
55
52
|
*/
|
|
56
53
|
export declare function getRenderUIEffects(effects: ClientEffect[]): Array<['render-ui', string, PatternConfig | null]>;
|
|
57
|
-
/**
|
|
58
|
-
* Get all navigate effects.
|
|
59
|
-
*/
|
|
60
|
-
export declare function getNavigateEffects(effects: ClientEffect[]): Array<['navigate', string, Record<string, unknown>?]>;
|
|
61
54
|
/**
|
|
62
55
|
* Get all notify effects.
|
|
63
56
|
*/
|
|
64
57
|
export declare function getNotifyEffects(effects: ClientEffect[]): Array<['notify', string, NotifyOptions?]>;
|
|
65
|
-
/**
|
|
66
|
-
* Get all emit effects.
|
|
67
|
-
*/
|
|
68
|
-
export declare function getEmitEffects(effects: ClientEffect[]): Array<['emit', string, unknown?]>;
|
|
@@ -5,19 +5,19 @@
|
|
|
5
5
|
*
|
|
6
6
|
* @packageDocumentation
|
|
7
7
|
*/
|
|
8
|
-
import type { EventPayload, EntityRow, ServiceParams } from '@almadar/core';
|
|
8
|
+
import type { EventPayload, EntityRow, FieldValue, ServiceParams, PatternConfig } from '@almadar/core';
|
|
9
9
|
import type { EffectHandlers } from '@almadar/runtime';
|
|
10
10
|
export interface ClientEventBus {
|
|
11
11
|
emit: (type: string, payload?: EventPayload) => void;
|
|
12
12
|
}
|
|
13
13
|
export interface SlotSetter {
|
|
14
|
-
addPattern: (slot: string, pattern:
|
|
14
|
+
addPattern: (slot: string, pattern: PatternConfig | null, props?: Record<string, FieldValue | undefined>) => void;
|
|
15
15
|
clearSlot: (slot: string) => void;
|
|
16
16
|
}
|
|
17
17
|
export interface CreateClientEffectHandlersOptions {
|
|
18
18
|
eventBus: ClientEventBus;
|
|
19
19
|
slotSetter: SlotSetter;
|
|
20
|
-
navigate?: (path: string, params?: Record<string,
|
|
20
|
+
navigate?: (path: string, params?: Record<string, string>) => void;
|
|
21
21
|
notify?: (message: string, type: 'success' | 'error' | 'warning' | 'info') => void;
|
|
22
22
|
/**
|
|
23
23
|
* Live client-entity write target for `[runtime]` entities. `(set
|
|
@@ -37,6 +37,6 @@ export interface CreateClientEffectHandlersOptions {
|
|
|
37
37
|
* mock result so service-atom chains advance end-to-end in offline /
|
|
38
38
|
* standalone-preview mode (see OrbitalServerRuntime's mock parallel).
|
|
39
39
|
*/
|
|
40
|
-
callService?: (service: string, action: string, params?: ServiceParams) => Promise<
|
|
40
|
+
callService?: (service: string, action: string, params?: ServiceParams) => Promise<EventPayload>;
|
|
41
41
|
}
|
|
42
42
|
export declare function createClientEffectHandlers(options: CreateClientEffectHandlersOptions): EffectHandlers;
|
|
@@ -11,7 +11,8 @@
|
|
|
11
11
|
*
|
|
12
12
|
* @packageDocumentation
|
|
13
13
|
*/
|
|
14
|
-
import type {
|
|
14
|
+
import type { EntityRow } from '@almadar/core';
|
|
15
|
+
import type { DataContext, DataResolution } from '../types/renderer-types';
|
|
15
16
|
/**
|
|
16
17
|
* Resolve entity data from available sources.
|
|
17
18
|
*
|
|
@@ -47,22 +48,8 @@ export declare function resolveEntityDataWithQuery(entityName: string, queryRef:
|
|
|
47
48
|
/**
|
|
48
49
|
* Get a single entity record by ID.
|
|
49
50
|
*/
|
|
50
|
-
export declare function resolveEntityById(entityName: string, id: string | number, context: DataContext):
|
|
51
|
-
/**
|
|
52
|
-
* Get the count of entities matching criteria.
|
|
53
|
-
*/
|
|
54
|
-
export declare function resolveEntityCount(entityName: string, context: DataContext, filters?: Record<string, unknown>): number;
|
|
51
|
+
export declare function resolveEntityById(entityName: string, id: string | number, context: DataContext): EntityRow | null;
|
|
55
52
|
/**
|
|
56
53
|
* Check if any entities exist for a given entity name.
|
|
57
54
|
*/
|
|
58
55
|
export declare function hasEntities(entityName: string, context: DataContext): boolean;
|
|
59
|
-
/**
|
|
60
|
-
* Create a data context from fetched data only.
|
|
61
|
-
* Convenience function for compiled shells.
|
|
62
|
-
*/
|
|
63
|
-
export declare function createFetchedDataContext(data: Record<string, unknown[]>): DataContext;
|
|
64
|
-
/**
|
|
65
|
-
* Merge multiple data contexts.
|
|
66
|
-
* Later contexts take precedence.
|
|
67
|
-
*/
|
|
68
|
-
export declare function mergeDataContexts(...contexts: DataContext[]): DataContext;
|
|
@@ -3,23 +3,24 @@
|
|
|
3
3
|
*
|
|
4
4
|
* @packageDocumentation
|
|
5
5
|
*/
|
|
6
|
+
import type { FieldValue } from '@almadar/core';
|
|
6
7
|
export type DebugEventType = 'state-change' | 'event-fired' | 'effect-executed' | 'guard-evaluated' | 'error' | 'warning' | 'info';
|
|
7
8
|
export interface DebugEvent {
|
|
8
9
|
id: string;
|
|
9
10
|
type: DebugEventType;
|
|
10
11
|
source: string;
|
|
11
12
|
message: string;
|
|
12
|
-
data?: Record<string,
|
|
13
|
+
data?: Record<string, FieldValue>;
|
|
13
14
|
timestamp: number;
|
|
14
15
|
}
|
|
15
16
|
type ChangeListener = () => void;
|
|
16
|
-
export declare function logDebugEvent(type: DebugEventType, source: string, message: string, data?: Record<string,
|
|
17
|
+
export declare function logDebugEvent(type: DebugEventType, source: string, message: string, data?: Record<string, FieldValue>): void;
|
|
17
18
|
export declare function logStateChange(source: string, from: string, to: string, event?: string): void;
|
|
18
|
-
export declare function logEventFired(source: string, eventName: string, payload?:
|
|
19
|
-
export declare function logEffectExecuted(source: string, effectType: string, details?:
|
|
20
|
-
export declare function logError(source: string, message: string, error?:
|
|
21
|
-
export declare function logWarning(source: string, message: string, data?: Record<string,
|
|
22
|
-
export declare function logInfo(source: string, message: string, data?: Record<string,
|
|
19
|
+
export declare function logEventFired(source: string, eventName: string, payload?: FieldValue): void;
|
|
20
|
+
export declare function logEffectExecuted(source: string, effectType: string, details?: FieldValue): void;
|
|
21
|
+
export declare function logError(source: string, message: string, error?: Error | null): void;
|
|
22
|
+
export declare function logWarning(source: string, message: string, data?: Record<string, FieldValue>): void;
|
|
23
|
+
export declare function logInfo(source: string, message: string, data?: Record<string, FieldValue>): void;
|
|
23
24
|
export declare function getDebugEvents(): DebugEvent[];
|
|
24
25
|
export declare function getRecentEvents(count: number): DebugEvent[];
|
|
25
26
|
export declare function getEventsByType(type: DebugEventType): DebugEvent[];
|
|
@@ -3,16 +3,17 @@
|
|
|
3
3
|
*
|
|
4
4
|
* @packageDocumentation
|
|
5
5
|
*/
|
|
6
|
+
import type { FieldValue, EntityRow } from '@almadar/core';
|
|
6
7
|
export interface EntityState {
|
|
7
8
|
id: string;
|
|
8
9
|
type: string;
|
|
9
|
-
fields: Record<string,
|
|
10
|
+
fields: Record<string, FieldValue>;
|
|
10
11
|
lastUpdated: number;
|
|
11
12
|
}
|
|
12
13
|
export interface RuntimeEntity {
|
|
13
14
|
id: string;
|
|
14
15
|
type: string;
|
|
15
|
-
data: Record<string,
|
|
16
|
+
data: Record<string, FieldValue>;
|
|
16
17
|
}
|
|
17
18
|
export interface PersistentEntityInfo {
|
|
18
19
|
loaded: boolean;
|
|
@@ -23,7 +24,7 @@ export interface EntitySnapshot {
|
|
|
23
24
|
timestamp: number;
|
|
24
25
|
totalCount: number;
|
|
25
26
|
/** Singleton entities by name */
|
|
26
|
-
singletons: Record<string,
|
|
27
|
+
singletons: Record<string, EntityRow>;
|
|
27
28
|
/** Runtime entities (in-memory) */
|
|
28
29
|
runtime: RuntimeEntity[];
|
|
29
30
|
/** Persistent entities info by type */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { FieldValue } from '@almadar/core';
|
|
1
|
+
import type { EventPayload, FieldValue } from '@almadar/core';
|
|
2
2
|
/**
|
|
3
3
|
* Get Nested Value Utility
|
|
4
4
|
*
|
|
@@ -7,8 +7,20 @@ import type { FieldValue } from '@almadar/core';
|
|
|
7
7
|
*
|
|
8
8
|
* @packageDocumentation
|
|
9
9
|
*/
|
|
10
|
-
|
|
11
|
-
|
|
10
|
+
/**
|
|
11
|
+
* Get a nested value from an object using dot-notation path.
|
|
12
|
+
*
|
|
13
|
+
* @param obj - The object to traverse
|
|
14
|
+
* @param path - Dot-notation path (e.g., "company.name", "address.city")
|
|
15
|
+
* @returns The value at the path, or undefined if not found
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* const data = { company: { name: "Acme Corp", address: { city: "NYC" } } };
|
|
19
|
+
* getNestedValue(data, "company.name"); // => "Acme Corp"
|
|
20
|
+
* getNestedValue(data, "company.address.city"); // => "NYC"
|
|
21
|
+
* getNestedValue(data, "company.missing"); // => undefined
|
|
22
|
+
*/
|
|
23
|
+
export declare function getNestedValue(obj: EventPayload | Record<string, FieldValue | undefined> | null | undefined, path: string): FieldValue | undefined;
|
|
12
24
|
/**
|
|
13
25
|
* Format a nested field path as a human-readable label.
|
|
14
26
|
*
|
|
@@ -3,13 +3,14 @@
|
|
|
3
3
|
*
|
|
4
4
|
* @packageDocumentation
|
|
5
5
|
*/
|
|
6
|
+
import type { FieldValue } from '@almadar/core';
|
|
6
7
|
export interface GuardContext {
|
|
7
8
|
traitName?: string;
|
|
8
9
|
type?: "transition" | "tick";
|
|
9
10
|
transitionFrom?: string;
|
|
10
11
|
transitionTo?: string;
|
|
11
12
|
tickName?: string;
|
|
12
|
-
[key: string]:
|
|
13
|
+
[key: string]: FieldValue | undefined;
|
|
13
14
|
}
|
|
14
15
|
export interface GuardEvaluation {
|
|
15
16
|
id: string;
|
|
@@ -20,7 +21,7 @@ export interface GuardEvaluation {
|
|
|
20
21
|
context: GuardContext;
|
|
21
22
|
timestamp: number;
|
|
22
23
|
/** Input values used in guard evaluation */
|
|
23
|
-
inputs: Record<string,
|
|
24
|
+
inputs: Record<string, FieldValue>;
|
|
24
25
|
}
|
|
25
26
|
type ChangeListener = () => void;
|
|
26
27
|
export declare function recordGuardEvaluation(evaluation: Omit<GuardEvaluation, "id" | "timestamp">): void;
|
package/dist/lib/index.cjs
CHANGED
|
@@ -279,16 +279,16 @@ function logDebugEvent(type, source, message, data) {
|
|
|
279
279
|
notifyListeners();
|
|
280
280
|
}
|
|
281
281
|
function logStateChange(source, from, to, event) {
|
|
282
|
-
logDebugEvent("state-change", source, `${from} \u2192 ${to}`, { from, to, event });
|
|
282
|
+
logDebugEvent("state-change", source, `${from} \u2192 ${to}`, { from, to, event: event ?? null });
|
|
283
283
|
}
|
|
284
284
|
function logEventFired(source, eventName, payload) {
|
|
285
|
-
logDebugEvent("event-fired", source, eventName, { eventName, payload });
|
|
285
|
+
logDebugEvent("event-fired", source, eventName, { eventName, payload: payload ?? null });
|
|
286
286
|
}
|
|
287
287
|
function logEffectExecuted(source, effectType, details) {
|
|
288
|
-
logDebugEvent("effect-executed", source, effectType, { effectType, details });
|
|
288
|
+
logDebugEvent("effect-executed", source, effectType, { effectType, details: details ?? null });
|
|
289
289
|
}
|
|
290
290
|
function logError(source, message, error) {
|
|
291
|
-
logDebugEvent("error", source, message, { error });
|
|
291
|
+
logDebugEvent("error", source, message, { error: error?.message ?? null });
|
|
292
292
|
}
|
|
293
293
|
function logWarning(source, message, data) {
|
|
294
294
|
logDebugEvent("warning", source, message, data);
|
|
@@ -766,7 +766,7 @@ function getNestedValue(obj, path) {
|
|
|
766
766
|
if (value === null || value === void 0) {
|
|
767
767
|
return void 0;
|
|
768
768
|
}
|
|
769
|
-
if (typeof value !== "object") {
|
|
769
|
+
if (typeof value !== "object" || Array.isArray(value)) {
|
|
770
770
|
return void 0;
|
|
771
771
|
}
|
|
772
772
|
value = value[part];
|
|
@@ -1132,7 +1132,7 @@ function drawTransitionLabelsSvg(from, to, transitions, positions, config) {
|
|
|
1132
1132
|
svg += `<g class="transition-group" ${dataAttrs}>`;
|
|
1133
1133
|
svg += `<text class="transition-label transition-event" x="${midX}" y="${labelY}" text-anchor="middle" fill="${config.colors.arrowText}" font-family="JetBrains Mono, monospace" font-size="14px" font-weight="600">${escapeXml(transition.event)}</text>`;
|
|
1134
1134
|
const hasGuard = !!transition.guard;
|
|
1135
|
-
const guardText = hasGuard ? formatGuardHuman(transition.guard) : "";
|
|
1135
|
+
const guardText = hasGuard && transition.guard !== void 0 ? formatGuardHuman(transition.guard) : "";
|
|
1136
1136
|
const effectLines = transition.effects ? formatEffectsHuman(transition.effects) : [];
|
|
1137
1137
|
const hasEffects = effectLines.length > 0;
|
|
1138
1138
|
if (hasGuard || hasEffects) {
|
|
@@ -1279,16 +1279,14 @@ function extractStateMachine(data) {
|
|
|
1279
1279
|
if (!data || typeof data !== "object") return null;
|
|
1280
1280
|
const obj = data;
|
|
1281
1281
|
if (obj.states && obj.transitions) {
|
|
1282
|
-
return obj;
|
|
1282
|
+
return { states: obj.states, transitions: obj.transitions };
|
|
1283
1283
|
}
|
|
1284
1284
|
if (obj.stateMachine) {
|
|
1285
1285
|
return obj.stateMachine;
|
|
1286
1286
|
}
|
|
1287
1287
|
if (Array.isArray(obj.traits)) {
|
|
1288
|
-
const traitWithSM = obj.traits.find(
|
|
1289
|
-
|
|
1290
|
-
);
|
|
1291
|
-
if (traitWithSM && typeof traitWithSM === "object" && "stateMachine" in traitWithSM) {
|
|
1288
|
+
const traitWithSM = obj.traits.find((t) => t.stateMachine != null);
|
|
1289
|
+
if (traitWithSM?.stateMachine) {
|
|
1292
1290
|
return traitWithSM.stateMachine;
|
|
1293
1291
|
}
|
|
1294
1292
|
}
|
|
@@ -1462,7 +1460,8 @@ function renderStateMachineToDomData(stateMachine, options = {}, config = DEFAUL
|
|
|
1462
1460
|
function tryParseOrbitalSchema(code) {
|
|
1463
1461
|
try {
|
|
1464
1462
|
const parsed = JSON.parse(code);
|
|
1465
|
-
if (parsed
|
|
1463
|
+
if (typeof parsed !== "object" || parsed === null) return null;
|
|
1464
|
+
if ("states" in parsed && "transitions" in parsed || Array.isArray(parsed.orbitals)) {
|
|
1466
1465
|
return parsed;
|
|
1467
1466
|
}
|
|
1468
1467
|
} catch {
|
package/dist/lib/index.d.ts
CHANGED
package/dist/lib/index.js
CHANGED
|
@@ -277,16 +277,16 @@ function logDebugEvent(type, source, message, data) {
|
|
|
277
277
|
notifyListeners();
|
|
278
278
|
}
|
|
279
279
|
function logStateChange(source, from, to, event) {
|
|
280
|
-
logDebugEvent("state-change", source, `${from} \u2192 ${to}`, { from, to, event });
|
|
280
|
+
logDebugEvent("state-change", source, `${from} \u2192 ${to}`, { from, to, event: event ?? null });
|
|
281
281
|
}
|
|
282
282
|
function logEventFired(source, eventName, payload) {
|
|
283
|
-
logDebugEvent("event-fired", source, eventName, { eventName, payload });
|
|
283
|
+
logDebugEvent("event-fired", source, eventName, { eventName, payload: payload ?? null });
|
|
284
284
|
}
|
|
285
285
|
function logEffectExecuted(source, effectType, details) {
|
|
286
|
-
logDebugEvent("effect-executed", source, effectType, { effectType, details });
|
|
286
|
+
logDebugEvent("effect-executed", source, effectType, { effectType, details: details ?? null });
|
|
287
287
|
}
|
|
288
288
|
function logError(source, message, error) {
|
|
289
|
-
logDebugEvent("error", source, message, { error });
|
|
289
|
+
logDebugEvent("error", source, message, { error: error?.message ?? null });
|
|
290
290
|
}
|
|
291
291
|
function logWarning(source, message, data) {
|
|
292
292
|
logDebugEvent("warning", source, message, data);
|
|
@@ -764,7 +764,7 @@ function getNestedValue(obj, path) {
|
|
|
764
764
|
if (value === null || value === void 0) {
|
|
765
765
|
return void 0;
|
|
766
766
|
}
|
|
767
|
-
if (typeof value !== "object") {
|
|
767
|
+
if (typeof value !== "object" || Array.isArray(value)) {
|
|
768
768
|
return void 0;
|
|
769
769
|
}
|
|
770
770
|
value = value[part];
|
|
@@ -1130,7 +1130,7 @@ function drawTransitionLabelsSvg(from, to, transitions, positions, config) {
|
|
|
1130
1130
|
svg += `<g class="transition-group" ${dataAttrs}>`;
|
|
1131
1131
|
svg += `<text class="transition-label transition-event" x="${midX}" y="${labelY}" text-anchor="middle" fill="${config.colors.arrowText}" font-family="JetBrains Mono, monospace" font-size="14px" font-weight="600">${escapeXml(transition.event)}</text>`;
|
|
1132
1132
|
const hasGuard = !!transition.guard;
|
|
1133
|
-
const guardText = hasGuard ? formatGuardHuman(transition.guard) : "";
|
|
1133
|
+
const guardText = hasGuard && transition.guard !== void 0 ? formatGuardHuman(transition.guard) : "";
|
|
1134
1134
|
const effectLines = transition.effects ? formatEffectsHuman(transition.effects) : [];
|
|
1135
1135
|
const hasEffects = effectLines.length > 0;
|
|
1136
1136
|
if (hasGuard || hasEffects) {
|
|
@@ -1277,16 +1277,14 @@ function extractStateMachine(data) {
|
|
|
1277
1277
|
if (!data || typeof data !== "object") return null;
|
|
1278
1278
|
const obj = data;
|
|
1279
1279
|
if (obj.states && obj.transitions) {
|
|
1280
|
-
return obj;
|
|
1280
|
+
return { states: obj.states, transitions: obj.transitions };
|
|
1281
1281
|
}
|
|
1282
1282
|
if (obj.stateMachine) {
|
|
1283
1283
|
return obj.stateMachine;
|
|
1284
1284
|
}
|
|
1285
1285
|
if (Array.isArray(obj.traits)) {
|
|
1286
|
-
const traitWithSM = obj.traits.find(
|
|
1287
|
-
|
|
1288
|
-
);
|
|
1289
|
-
if (traitWithSM && typeof traitWithSM === "object" && "stateMachine" in traitWithSM) {
|
|
1286
|
+
const traitWithSM = obj.traits.find((t) => t.stateMachine != null);
|
|
1287
|
+
if (traitWithSM?.stateMachine) {
|
|
1290
1288
|
return traitWithSM.stateMachine;
|
|
1291
1289
|
}
|
|
1292
1290
|
}
|
|
@@ -1460,7 +1458,8 @@ function renderStateMachineToDomData(stateMachine, options = {}, config = DEFAUL
|
|
|
1460
1458
|
function tryParseOrbitalSchema(code) {
|
|
1461
1459
|
try {
|
|
1462
1460
|
const parsed = JSON.parse(code);
|
|
1463
|
-
if (parsed
|
|
1461
|
+
if (typeof parsed !== "object" || parsed === null) return null;
|
|
1462
|
+
if ("states" in parsed && "transitions" in parsed || Array.isArray(parsed.orbitals)) {
|
|
1464
1463
|
return parsed;
|
|
1465
1464
|
}
|
|
1466
1465
|
} catch {
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
* 3. Transition arm routing: forward arcs above, backward arcs below, self-loops above.
|
|
8
8
|
* 4. Guard icons at 30% along arm, effect icons at 70%.
|
|
9
9
|
*/
|
|
10
|
+
import type { FieldValue } from '@almadar/core';
|
|
10
11
|
import type { JazariLayout } from './types.js';
|
|
11
12
|
export interface LayoutState {
|
|
12
13
|
name: string;
|
|
@@ -18,8 +19,8 @@ export interface LayoutTransition {
|
|
|
18
19
|
from: string;
|
|
19
20
|
to: string;
|
|
20
21
|
event: string;
|
|
21
|
-
guard?:
|
|
22
|
-
effects?:
|
|
22
|
+
guard?: FieldValue;
|
|
23
|
+
effects?: FieldValue[];
|
|
23
24
|
}
|
|
24
25
|
export interface LayoutInput {
|
|
25
26
|
states: LayoutState[];
|
|
@@ -11,7 +11,8 @@
|
|
|
11
11
|
*
|
|
12
12
|
* @packageDocumentation
|
|
13
13
|
*/
|
|
14
|
-
import type {
|
|
14
|
+
import type { EntityRow, FieldValue } from '@almadar/core';
|
|
15
|
+
import type { ClientEffect, ClientEffectExecutorConfig, EventResponse } from '../types/renderer-types';
|
|
15
16
|
/**
|
|
16
17
|
* Effect that needs to be synced to server when online
|
|
17
18
|
*/
|
|
@@ -23,7 +24,7 @@ export interface PendingSyncEffect {
|
|
|
23
24
|
/** Effect type (persist, call-service, etc.) */
|
|
24
25
|
type: string;
|
|
25
26
|
/** Effect payload */
|
|
26
|
-
payload:
|
|
27
|
+
payload: Record<string, FieldValue>;
|
|
27
28
|
/** Number of retry attempts */
|
|
28
29
|
retries: number;
|
|
29
30
|
/** Maximum retries before giving up */
|
|
@@ -37,7 +38,7 @@ export interface OfflineExecutorConfig extends ClientEffectExecutorConfig {
|
|
|
37
38
|
* Mock data provider for simulating fetch responses.
|
|
38
39
|
* Returns data for a given entity name.
|
|
39
40
|
*/
|
|
40
|
-
mockDataProvider?: (entityName: string) =>
|
|
41
|
+
mockDataProvider?: (entityName: string) => EntityRow[];
|
|
41
42
|
/**
|
|
42
43
|
* Whether to queue server effects for sync when online.
|
|
43
44
|
* Default: true
|
|
@@ -140,7 +141,7 @@ export declare class OfflineExecutor {
|
|
|
140
141
|
* Client effects are executed immediately.
|
|
141
142
|
* Server effects are queued for sync.
|
|
142
143
|
*/
|
|
143
|
-
processEventOffline(event: string, payload?: Record<string,
|
|
144
|
+
processEventOffline(event: string, payload?: Record<string, FieldValue>, effects?: Array<FieldValue[]>): EventResponse;
|
|
144
145
|
/**
|
|
145
146
|
* Sync pending effects to server.
|
|
146
147
|
*
|
|
@@ -205,7 +206,7 @@ export interface UseOfflineExecutorResult {
|
|
|
205
206
|
/** Execute client effects */
|
|
206
207
|
executeClientEffects: (effects: ClientEffect[]) => void;
|
|
207
208
|
/** Process event offline */
|
|
208
|
-
processEventOffline: (event: string, payload?: Record<string,
|
|
209
|
+
processEventOffline: (event: string, payload?: Record<string, FieldValue>, effects?: Array<FieldValue[]>) => EventResponse;
|
|
209
210
|
/** Manually trigger sync */
|
|
210
211
|
sync: () => Promise<number>;
|
|
211
212
|
/** Clear the queue */
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
* segments for rendering. Detects orbital schemas in JSON code blocks
|
|
6
6
|
* and marks them for JazariStateMachine rendering.
|
|
7
7
|
*/
|
|
8
|
+
import type { OrbitalSchema } from '@almadar/core';
|
|
8
9
|
/** Segment types for content rendering */
|
|
9
10
|
export type ContentSegment = {
|
|
10
11
|
type: 'markdown';
|
|
@@ -17,7 +18,7 @@ export type ContentSegment = {
|
|
|
17
18
|
type: 'orbital';
|
|
18
19
|
language: string;
|
|
19
20
|
content: string;
|
|
20
|
-
schema:
|
|
21
|
+
schema: OrbitalSchema;
|
|
21
22
|
} | {
|
|
22
23
|
type: 'quiz';
|
|
23
24
|
question: string;
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
* @packageDocumentation
|
|
11
11
|
*/
|
|
12
12
|
import type { PatternPropDef } from '@almadar/patterns';
|
|
13
|
-
import type { PatternConfig,
|
|
13
|
+
import type { PatternConfig, MappedPattern } from '../types/renderer-types';
|
|
14
14
|
/**
|
|
15
15
|
* Component mapping entry from component-mapping.json
|
|
16
16
|
*/
|
|
@@ -64,7 +64,7 @@ export declare function setPatternRegistry(registry: Record<string, PatternDefin
|
|
|
64
64
|
* // resolved.importPath === '@/components/organisms/DataTable'
|
|
65
65
|
* ```
|
|
66
66
|
*/
|
|
67
|
-
export declare function resolvePattern(config: PatternConfig):
|
|
67
|
+
export declare function resolvePattern(config: PatternConfig): MappedPattern;
|
|
68
68
|
/**
|
|
69
69
|
* Check if a pattern type is known.
|
|
70
70
|
*/
|
|
@@ -27,8 +27,6 @@ export declare function perfTime<T>(name: string, fn: () => T, detail?: Record<s
|
|
|
27
27
|
* Phase is `"mount" | "update" | "nested-update"`.
|
|
28
28
|
*/
|
|
29
29
|
export declare const profilerOnRender: ProfilerOnRenderCallback;
|
|
30
|
-
/** Snapshot in insertion order (oldest first). Stable identity until next push. */
|
|
31
|
-
export declare function getPerfSnapshot(): readonly PerfEntry[];
|
|
32
30
|
/** React hook: returns the current ring snapshot, re-renders on push. */
|
|
33
31
|
export declare function usePerfBuffer(): readonly PerfEntry[];
|
|
34
32
|
export declare function clearPerf(): void;
|
|
@@ -7,38 +7,26 @@
|
|
|
7
7
|
*
|
|
8
8
|
* @packageDocumentation
|
|
9
9
|
*/
|
|
10
|
-
import type { UISlot, SlotDefinition
|
|
10
|
+
import type { UISlot, SlotDefinition } from '../types/renderer-types';
|
|
11
11
|
/**
|
|
12
12
|
* Definitions for all available UI slots.
|
|
13
13
|
*
|
|
14
14
|
* Inline slots render within the component hierarchy.
|
|
15
15
|
* Portal slots render to document.body, breaking out of overflow containers.
|
|
16
16
|
*/
|
|
17
|
-
export declare const SLOT_DEFINITIONS: Record<UISlot, SlotDefinition>;
|
|
17
|
+
export declare const SLOT_DEFINITIONS: Partial<Record<UISlot, SlotDefinition>> & Record<'main' | 'sidebar' | 'modal' | 'drawer' | 'overlay' | 'center' | 'toast' | 'hud-top' | 'hud-bottom' | 'floating', SlotDefinition>;
|
|
18
18
|
/**
|
|
19
19
|
* Get the slot definition for a slot name.
|
|
20
20
|
*/
|
|
21
|
-
export declare function getSlotDefinition(slot: UISlot): SlotDefinition;
|
|
21
|
+
export declare function getSlotDefinition(slot: UISlot): SlotDefinition | undefined;
|
|
22
22
|
/**
|
|
23
23
|
* Check if a slot is a portal slot.
|
|
24
24
|
*/
|
|
25
25
|
export declare function isPortalSlot(slot: string): boolean;
|
|
26
|
-
/**
|
|
27
|
-
* Check if a slot is an inline slot.
|
|
28
|
-
*/
|
|
29
|
-
export declare function isInlineSlot(slot: UISlot): boolean;
|
|
30
|
-
/**
|
|
31
|
-
* Get all slots of a specific type.
|
|
32
|
-
*/
|
|
33
|
-
export declare function getSlotsByType(type: SlotType): UISlot[];
|
|
34
26
|
/**
|
|
35
27
|
* Get all inline slots.
|
|
36
28
|
*/
|
|
37
29
|
export declare function getInlineSlots(): UISlot[];
|
|
38
|
-
/**
|
|
39
|
-
* Get all portal slots.
|
|
40
|
-
*/
|
|
41
|
-
export declare function getPortalSlots(): UISlot[];
|
|
42
30
|
/**
|
|
43
31
|
* All valid slot names.
|
|
44
32
|
*/
|
|
@@ -22,6 +22,8 @@
|
|
|
22
22
|
*
|
|
23
23
|
* @see docs/Almadar_Std_Gaps.md §3.8
|
|
24
24
|
*/
|
|
25
|
+
import React from "react";
|
|
26
|
+
import type { FieldValue } from "@almadar/core";
|
|
25
27
|
export interface ResolveTraitBindingsContext {
|
|
26
28
|
/**
|
|
27
29
|
* Depth cap — the walker refuses to descend deeper than this to
|
|
@@ -44,10 +46,12 @@ export interface ResolveTraitBindingsContext {
|
|
|
44
46
|
* `content.props` with `currentSlot` bound to the slot whose render-ui
|
|
45
47
|
* is being composed.
|
|
46
48
|
*/
|
|
47
|
-
|
|
49
|
+
type PatternTreeNode = FieldValue | React.ReactElement | undefined;
|
|
50
|
+
export declare function resolveTraitBindingsInPattern(value: PatternTreeNode, ctx: ResolveTraitBindingsContext): PatternTreeNode;
|
|
48
51
|
/**
|
|
49
52
|
* Lower-level helper: is this string a `@trait.*` binding the resolver
|
|
50
53
|
* would handle? Useful for consumers that need to treat the trait case
|
|
51
54
|
* specially before handing the string back to the walker.
|
|
52
55
|
*/
|
|
53
|
-
export declare function isTraitBinding(value:
|
|
56
|
+
export declare function isTraitBinding(value: PatternTreeNode): value is string;
|
|
57
|
+
export {};
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
* It exports the visualizer to the global `OrbitalVisualizer` object.
|
|
6
6
|
*/
|
|
7
7
|
import { renderStateMachineToSvg, extractStateMachine, getEffectSummary, extractOutputsFromTransitions, type RenderOptions, type VisualizerConfig } from './index.js';
|
|
8
|
+
import type { OrbitalSchema } from '@almadar/core';
|
|
8
9
|
type SExpr = string | number | boolean | SExpr[];
|
|
9
10
|
declare function formatSExprHumanReadable(expr: SExpr, indent?: number): string;
|
|
10
11
|
interface BrowserRenderOptions extends RenderOptions {
|
|
@@ -13,7 +14,7 @@ interface BrowserRenderOptions extends RenderOptions {
|
|
|
13
14
|
/**
|
|
14
15
|
* Render a state machine into a container element
|
|
15
16
|
*/
|
|
16
|
-
declare function render(container: HTMLElement, data:
|
|
17
|
+
declare function render(container: HTMLElement, data: OrbitalSchema | object, options?: BrowserRenderOptions): void;
|
|
17
18
|
/**
|
|
18
19
|
* Auto-initialize diagrams from data attributes
|
|
19
20
|
*/
|
|
@@ -26,7 +27,7 @@ declare let pinnedTooltip: {
|
|
|
26
27
|
* Render a state machine into a container element using DOM-based approach
|
|
27
28
|
* This matches the React DomStateMachineVisualizer component
|
|
28
29
|
*/
|
|
29
|
-
declare function renderDom(container: HTMLElement, data:
|
|
30
|
+
declare function renderDom(container: HTMLElement, data: OrbitalSchema | object, options?: BrowserRenderOptions): void;
|
|
30
31
|
declare const OrbitalVisualizer: {
|
|
31
32
|
render: typeof render;
|
|
32
33
|
renderDom: typeof renderDom;
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
* Renders SVG diagrams from Orbital schemas and Trait definitions.
|
|
5
5
|
* Can be used in documentation, IDE previews, and other tools.
|
|
6
6
|
*/
|
|
7
|
+
import type { Effect, OrbitalSchema, SExpr } from '@almadar/core';
|
|
7
8
|
export interface VisualizerConfig {
|
|
8
9
|
nodeRadius: number;
|
|
9
10
|
nodeSpacing: number;
|
|
@@ -38,8 +39,8 @@ export interface TransitionDefinition {
|
|
|
38
39
|
from: string;
|
|
39
40
|
to: string;
|
|
40
41
|
event: string;
|
|
41
|
-
guard?:
|
|
42
|
-
effects?:
|
|
42
|
+
guard?: SExpr | null;
|
|
43
|
+
effects?: Effect[];
|
|
43
44
|
}
|
|
44
45
|
export interface StateMachineDefinition {
|
|
45
46
|
states: StateDefinition[];
|
|
@@ -122,8 +123,8 @@ export interface DomLayoutData {
|
|
|
122
123
|
config: VisualizerConfig;
|
|
123
124
|
}
|
|
124
125
|
export declare const DEFAULT_CONFIG: VisualizerConfig;
|
|
125
|
-
declare function formatGuard(guard:
|
|
126
|
-
export declare function getEffectSummary(effects:
|
|
126
|
+
declare function formatGuard(guard: SExpr | null | undefined): string;
|
|
127
|
+
export declare function getEffectSummary(effects: Effect[]): string;
|
|
127
128
|
declare function extractOutputsFromTransitions(transitions: TransitionDefinition[]): string[];
|
|
128
129
|
/**
|
|
129
130
|
* Render a state machine to an SVG string.
|
|
@@ -133,7 +134,7 @@ export declare function renderStateMachineToSvg(stateMachine: StateMachineDefini
|
|
|
133
134
|
/**
|
|
134
135
|
* Extract state machine from various data formats (Trait, Orbital, or raw)
|
|
135
136
|
*/
|
|
136
|
-
export declare function extractStateMachine(data:
|
|
137
|
+
export declare function extractStateMachine(data: OrbitalSchema | object): StateMachineDefinition | null;
|
|
137
138
|
/**
|
|
138
139
|
* Render a state machine to DOM layout data.
|
|
139
140
|
* This is used by the DOM-based visualizer component for hybrid SVG/DOM rendering.
|