@xmachines/docs 1.0.0-beta.26 → 1.0.0-beta.28
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/api/@xmachines/play/classes/PlayError.md +4 -10
- package/api/@xmachines/play/type-aliases/PlayEvent.md +2 -2
- package/api/@xmachines/play-actor/classes/AbstractActor.md +3 -25
- package/api/@xmachines/play-actor/functions/typedSpec.md +1 -1
- package/api/@xmachines/play-actor/interfaces/PlaySpec.md +2 -2
- package/api/@xmachines/play-actor/interfaces/Routable.md +3 -3
- package/api/@xmachines/play-actor/interfaces/ViewMetadata.md +3 -3
- package/api/@xmachines/play-actor/interfaces/Viewable.md +2 -2
- package/api/@xmachines/play-actor-shared/README.md +155 -0
- package/api/@xmachines/play-actor-shared/interfaces/AuthContext.md +14 -0
- package/api/@xmachines/play-actor-shared/type-aliases/AuthActor.md +27 -0
- package/api/@xmachines/play-actor-shared/type-aliases/AuthCatalog.md +16 -0
- package/api/@xmachines/play-actor-shared/type-aliases/AuthEvents.md +17 -0
- package/api/@xmachines/play-actor-shared/type-aliases/AuthInput.md +9 -0
- package/api/@xmachines/play-actor-shared/type-aliases/AuthSnapshot.md +11 -0
- package/api/@xmachines/play-actor-shared/type-aliases/CatalogProps.md +187 -0
- package/api/@xmachines/play-actor-shared/type-aliases/InferProps.md +17 -0
- package/api/@xmachines/play-actor-shared/variables/authCatalog.md +173 -0
- package/api/@xmachines/play-actor-shared/variables/authMachine.md +189 -0
- package/api/@xmachines/play-actor-shared/variables/authSetup.md +22 -0
- package/api/@xmachines/play-dom/README.md +74 -8
- package/api/@xmachines/play-dom/classes/PlayRenderer.md +4 -4
- package/api/@xmachines/play-dom/functions/connectRenderer.md +1 -1
- package/api/@xmachines/play-dom/functions/defineRegistry.md +61 -0
- package/api/@xmachines/play-dom/functions/renderSpec.md +29 -12
- package/api/@xmachines/play-dom/interfaces/ComponentContext.md +62 -0
- package/api/@xmachines/play-dom/interfaces/ConnectRendererOptions.md +9 -9
- package/api/@xmachines/play-dom/interfaces/DefineRegistryOptions.md +25 -0
- package/api/@xmachines/play-dom/interfaces/DefineRegistryResult.md +18 -0
- package/api/@xmachines/play-dom/interfaces/DomRenderContext.md +13 -10
- package/api/@xmachines/play-dom/interfaces/EventHandle.md +29 -0
- package/api/@xmachines/play-dom/interfaces/PlayDomOptions.md +5 -5
- package/api/@xmachines/play-dom/type-aliases/ComponentFn.md +53 -0
- package/api/@xmachines/play-dom/type-aliases/ComponentRegistry.md +21 -0
- package/api/@xmachines/play-dom/type-aliases/DomComponentRenderer.md +16 -3
- package/api/@xmachines/play-dom/type-aliases/DomRegistry.md +5 -2
- package/api/@xmachines/play-dom-demo/README.md +145 -0
- package/api/@xmachines/play-dom-demo/functions/initShell.md +20 -0
- package/api/@xmachines/play-dom-demo/variables/About.md +9 -0
- package/api/@xmachines/play-dom-demo/variables/Contact.md +9 -0
- package/api/@xmachines/play-dom-demo/variables/Dashboard.md +9 -0
- package/api/@xmachines/play-dom-demo/variables/Home.md +9 -0
- package/api/@xmachines/play-dom-demo/variables/Login.md +9 -0
- package/api/@xmachines/play-dom-demo/variables/Navigation.md +9 -0
- package/api/@xmachines/play-dom-demo/variables/Overview.md +9 -0
- package/api/@xmachines/play-dom-demo/variables/Profile.md +9 -0
- package/api/@xmachines/play-dom-demo/variables/Settings.md +9 -0
- package/api/@xmachines/play-dom-demo/variables/Stats.md +9 -0
- package/api/@xmachines/play-dom-router/functions/connectRouter.md +1 -1
- package/api/@xmachines/play-dom-router/functions/createBrowserHistory.md +1 -1
- package/api/@xmachines/play-dom-router/functions/createRouteMap.md +1 -1
- package/api/@xmachines/play-dom-router/functions/createRouter.md +1 -1
- package/api/@xmachines/play-dom-router/interfaces/BrowserHistory.md +14 -14
- package/api/@xmachines/play-dom-router/interfaces/BrowserWindow.md +14 -14
- package/api/@xmachines/play-dom-router/interfaces/ConnectRouterOptions.md +4 -4
- package/api/@xmachines/play-dom-router/interfaces/PlayRouteEvent.md +6 -6
- package/api/@xmachines/play-dom-router/interfaces/RouteMap.md +3 -3
- package/api/@xmachines/play-dom-router/interfaces/RouteMapLike.md +3 -3
- package/api/@xmachines/play-dom-router/interfaces/RouteMapping.md +3 -3
- package/api/@xmachines/play-dom-router/interfaces/RouterBridge.md +3 -3
- package/api/@xmachines/play-dom-router/interfaces/VanillaRouter.md +4 -4
- package/api/@xmachines/play-dom-router/type-aliases/RoutableActor.md +1 -1
- package/api/@xmachines/play-dom-router-demo/README.md +56 -61
- package/api/@xmachines/play-react/classes/PlayErrorBoundary.md +5 -31
- package/api/@xmachines/play-react/functions/defineRegistry.md +0 -2
- package/api/@xmachines/play-react/functions/useActor.md +1 -1
- package/api/@xmachines/play-react/functions/useBoundProp.md +0 -2
- package/api/@xmachines/play-react/functions/useSignalEffect.md +1 -1
- package/api/@xmachines/play-react/functions/useStateBinding.md +0 -2
- package/api/@xmachines/play-react/interfaces/ComponentContext.md +0 -2
- package/api/@xmachines/play-react/interfaces/PlayErrorBoundaryProps.md +4 -4
- package/api/@xmachines/play-react/interfaces/PlayErrorBoundaryState.md +3 -3
- package/api/@xmachines/play-react/interfaces/PlayRendererProps.md +7 -7
- package/api/@xmachines/play-react/type-aliases/ComponentFn.md +0 -2
- package/api/@xmachines/play-react/type-aliases/PlayActor.md +1 -1
- package/api/@xmachines/play-react/variables/PlayRenderer.md +1 -1
- package/api/@xmachines/play-react-demo/README.md +173 -0
- package/api/@xmachines/play-react-demo/functions/App.md +13 -0
- package/api/@xmachines/play-react-demo/functions/DebugPanel.md +20 -0
- package/api/@xmachines/play-react-demo/functions/HeaderNav.md +20 -0
- package/api/@xmachines/play-react-demo/functions/Shell.md +22 -0
- package/api/@xmachines/play-react-demo/variables/About.md +9 -0
- package/api/@xmachines/play-react-demo/variables/Contact.md +9 -0
- package/api/@xmachines/play-react-demo/variables/Dashboard.md +9 -0
- package/api/@xmachines/play-react-demo/variables/Home.md +9 -0
- package/api/@xmachines/play-react-demo/variables/Login.md +9 -0
- package/api/@xmachines/play-react-demo/variables/Navigation.md +9 -0
- package/api/@xmachines/play-react-demo/variables/Overview.md +9 -0
- package/api/@xmachines/play-react-demo/variables/Profile.md +9 -0
- package/api/@xmachines/play-react-demo/variables/Settings.md +9 -0
- package/api/@xmachines/play-react-demo/variables/Stats.md +9 -0
- package/api/@xmachines/play-react-router/classes/ReactRouterBridge.md +23 -23
- package/api/@xmachines/play-react-router/classes/RouteMap.md +4 -4
- package/api/@xmachines/play-react-router/functions/PlayRouterProvider.md +1 -1
- package/api/@xmachines/play-react-router/functions/createRouteMapFromTree.md +1 -1
- package/api/@xmachines/play-react-router/interfaces/PlayRouteEvent.md +6 -6
- package/api/@xmachines/play-react-router/interfaces/PlayRouterProviderProps.md +5 -5
- package/api/@xmachines/play-react-router/interfaces/RouteMapping.md +3 -3
- package/api/@xmachines/play-react-router/interfaces/RouterBridge.md +3 -3
- package/api/@xmachines/play-react-router-demo/README.md +10 -10
- package/api/@xmachines/play-router/README.md +1 -1
- package/api/@xmachines/play-router/classes/BaseRouteMap.md +4 -4
- package/api/@xmachines/play-router/classes/RouterBridgeBase.md +23 -23
- package/api/@xmachines/play-router/functions/buildPlayRouteEvent.md +1 -1
- package/api/@xmachines/play-router/functions/buildRouteTree.md +1 -1
- package/api/@xmachines/play-router/functions/createRouteMap.md +1 -1
- package/api/@xmachines/play-router/functions/createRouteMapFromMachine.md +1 -1
- package/api/@xmachines/play-router/functions/createRouteMapFromTree.md +1 -1
- package/api/@xmachines/play-router/functions/detectDuplicateRoutes.md +1 -1
- package/api/@xmachines/play-router/functions/extractMachineRoutes.md +1 -1
- package/api/@xmachines/play-router/functions/extractQuery.md +1 -1
- package/api/@xmachines/play-router/functions/extractRouteParams.md +1 -1
- package/api/@xmachines/play-router/functions/findRouteById.md +1 -1
- package/api/@xmachines/play-router/functions/findRouteByPath.md +1 -1
- package/api/@xmachines/play-router/functions/getNavigableRoutes.md +1 -1
- package/api/@xmachines/play-router/functions/getRoutableRoutes.md +1 -1
- package/api/@xmachines/play-router/functions/getTransitionReachableRoutes.md +1 -1
- package/api/@xmachines/play-router/functions/isRouteReachable.md +1 -1
- package/api/@xmachines/play-router/functions/machineToGraph.md +1 -1
- package/api/@xmachines/play-router/functions/routeExists.md +1 -1
- package/api/@xmachines/play-router/functions/sanitizePathname.md +1 -1
- package/api/@xmachines/play-router/functions/validateRouteFormat.md +1 -1
- package/api/@xmachines/play-router/functions/validateStateExists.md +1 -1
- package/api/@xmachines/play-router/interfaces/BuildPlayRouteEventOptions.md +4 -4
- package/api/@xmachines/play-router/interfaces/LocationLike.md +3 -3
- package/api/@xmachines/play-router/interfaces/MachineEdgeData.md +3 -3
- package/api/@xmachines/play-router/interfaces/MachineNodeData.md +5 -5
- package/api/@xmachines/play-router/interfaces/PlayRouteEvent.md +6 -6
- package/api/@xmachines/play-router/interfaces/RouteInfo.md +8 -8
- package/api/@xmachines/play-router/interfaces/RouteMap.md +4 -4
- package/api/@xmachines/play-router/interfaces/RouteMapping.md +3 -3
- package/api/@xmachines/play-router/interfaces/RouteMatch.md +3 -3
- package/api/@xmachines/play-router/interfaces/RouteNode.md +10 -10
- package/api/@xmachines/play-router/interfaces/RouteObject.md +2 -2
- package/api/@xmachines/play-router/interfaces/RouteTree.md +5 -5
- package/api/@xmachines/play-router/interfaces/RouteWatcherHandle.md +3 -3
- package/api/@xmachines/play-router/interfaces/RouterBridge.md +3 -3
- package/api/@xmachines/play-router/interfaces/WindowLike.md +3 -3
- package/api/@xmachines/play-router/type-aliases/MachineGraph.md +1 -1
- package/api/@xmachines/play-router/type-aliases/RouteMetadata.md +1 -1
- package/api/@xmachines/play-signals/functions/watchSignal.md +1 -1
- package/api/@xmachines/play-signals/interfaces/ComputedOptions.md +2 -2
- package/api/@xmachines/play-signals/interfaces/SignalComputed.md +2 -2
- package/api/@xmachines/play-signals/interfaces/SignalOptions.md +2 -2
- package/api/@xmachines/play-signals/interfaces/SignalState.md +3 -3
- package/api/@xmachines/play-signals/interfaces/SignalWatcher.md +4 -4
- package/api/@xmachines/play-signals/namespaces/Signal/classes/Computed.md +0 -6
- package/api/@xmachines/play-signals/namespaces/Signal/classes/State.md +0 -8
- package/api/@xmachines/play-signals/namespaces/Signal/interfaces/Options.md +0 -2
- package/api/@xmachines/play-signals/namespaces/Signal/namespaces/subtle/classes/Watcher.md +0 -10
- package/api/@xmachines/play-signals/namespaces/Signal/namespaces/subtle/functions/currentComputed.md +0 -2
- package/api/@xmachines/play-signals/namespaces/Signal/namespaces/subtle/functions/hasSinks.md +0 -2
- package/api/@xmachines/play-signals/namespaces/Signal/namespaces/subtle/functions/hasSources.md +0 -2
- package/api/@xmachines/play-signals/namespaces/Signal/namespaces/subtle/functions/introspectSinks.md +0 -2
- package/api/@xmachines/play-signals/namespaces/Signal/namespaces/subtle/functions/introspectSources.md +0 -2
- package/api/@xmachines/play-signals/namespaces/Signal/namespaces/subtle/functions/untrack.md +0 -2
- package/api/@xmachines/play-signals/namespaces/Signal/namespaces/subtle/variables/unwatched.md +0 -2
- package/api/@xmachines/play-signals/namespaces/Signal/namespaces/subtle/variables/watched.md +0 -2
- package/api/@xmachines/play-signals/namespaces/Signal/variables/isComputed.md +0 -2
- package/api/@xmachines/play-signals/namespaces/Signal/variables/isState.md +0 -2
- package/api/@xmachines/play-signals/namespaces/Signal/variables/isWatcher.md +0 -2
- package/api/@xmachines/play-signals/type-aliases/WatcherNotify.md +1 -1
- package/api/@xmachines/play-solid/functions/defineRegistry.md +0 -2
- package/api/@xmachines/play-solid/functions/useActor.md +1 -1
- package/api/@xmachines/play-solid/functions/useStateBinding.md +0 -2
- package/api/@xmachines/play-solid/interfaces/ComponentContext.md +0 -2
- package/api/@xmachines/play-solid/interfaces/PlayRendererProps.md +7 -7
- package/api/@xmachines/play-solid/type-aliases/ComponentFn.md +0 -2
- package/api/@xmachines/play-solid/type-aliases/PlayActor.md +1 -1
- package/api/@xmachines/play-solid/variables/PlayRenderer.md +1 -1
- package/api/@xmachines/play-solid-demo/README.md +159 -0
- package/api/@xmachines/play-solid-demo/functions/App.md +13 -0
- package/api/@xmachines/play-solid-demo/functions/DebugPanel.md +20 -0
- package/api/@xmachines/play-solid-demo/functions/HeaderNav.md +20 -0
- package/api/@xmachines/play-solid-demo/functions/Shell.md +22 -0
- package/api/@xmachines/play-solid-demo/variables/About.md +9 -0
- package/api/@xmachines/play-solid-demo/variables/Contact.md +9 -0
- package/api/@xmachines/play-solid-demo/variables/Dashboard.md +9 -0
- package/api/@xmachines/play-solid-demo/variables/Home.md +9 -0
- package/api/@xmachines/play-solid-demo/variables/Login.md +9 -0
- package/api/@xmachines/play-solid-demo/variables/Navigation.md +9 -0
- package/api/@xmachines/play-solid-demo/variables/Overview.md +9 -0
- package/api/@xmachines/play-solid-demo/variables/Profile.md +9 -0
- package/api/@xmachines/play-solid-demo/variables/Settings.md +9 -0
- package/api/@xmachines/play-solid-demo/variables/Stats.md +9 -0
- package/api/@xmachines/play-solid-router/classes/RouteMap.md +4 -4
- package/api/@xmachines/play-solid-router/classes/SolidRouterBridge.md +24 -24
- package/api/@xmachines/play-solid-router/functions/PlayRouterProvider.md +1 -1
- package/api/@xmachines/play-solid-router/functions/createRouteMap.md +1 -1
- package/api/@xmachines/play-solid-router/interfaces/AbstractActor.md +3 -23
- package/api/@xmachines/play-solid-router/interfaces/PlayRouteEvent.md +6 -6
- package/api/@xmachines/play-solid-router/interfaces/PlayRouterProviderProps.md +5 -5
- package/api/@xmachines/play-solid-router/interfaces/RouteMapping.md +3 -3
- package/api/@xmachines/play-solid-router/interfaces/RouterBridge.md +3 -3
- package/api/@xmachines/play-solid-router/type-aliases/RoutableActor.md +1 -1
- package/api/@xmachines/play-solid-router/type-aliases/SolidRouterHooks.md +4 -4
- package/api/@xmachines/play-solid-router-demo/README.md +25 -28
- package/api/@xmachines/play-svelte/functions/defineRegistry.md +0 -2
- package/api/@xmachines/play-svelte/interfaces/BaseComponentProps.md +0 -2
- package/api/@xmachines/play-svelte/interfaces/ComponentContext.md +0 -2
- package/api/@xmachines/play-svelte/interfaces/PlayRendererProps.md +7 -7
- package/api/@xmachines/play-svelte/type-aliases/ComponentFn.md +0 -2
- package/api/@xmachines/play-svelte/type-aliases/PlayRenderer.md +0 -2
- package/api/@xmachines/play-svelte/variables/PlayRenderer.md +0 -2
- package/api/@xmachines/play-svelte-demo/README.md +127 -0
- package/api/@xmachines/play-svelte-spa-router/classes/RouteMap.md +4 -4
- package/api/@xmachines/play-svelte-spa-router/functions/connectRouter.md +1 -1
- package/api/@xmachines/play-svelte-spa-router/functions/createRouteMap.md +1 -1
- package/api/@xmachines/play-svelte-spa-router/interfaces/ConnectRouterOptions.md +4 -4
- package/api/@xmachines/play-svelte-spa-router/interfaces/PlayRouteEvent.md +6 -6
- package/api/@xmachines/play-svelte-spa-router/interfaces/RouteMapping.md +3 -3
- package/api/@xmachines/play-svelte-spa-router/interfaces/RouterBridge.md +3 -3
- package/api/@xmachines/play-svelte-spa-router/interfaces/WindowLike.md +3 -3
- package/api/@xmachines/play-svelte-spa-router/type-aliases/RoutableActor.md +1 -1
- package/api/@xmachines/play-sveltekit-router/classes/RouteMap.md +4 -4
- package/api/@xmachines/play-sveltekit-router/functions/connectRouter.md +1 -1
- package/api/@xmachines/play-sveltekit-router/functions/createRouteMap.md +1 -1
- package/api/@xmachines/play-sveltekit-router/interfaces/ConnectRouterOptions.md +4 -4
- package/api/@xmachines/play-sveltekit-router/interfaces/LocationLike.md +3 -3
- package/api/@xmachines/play-sveltekit-router/interfaces/PlayRouteEvent.md +6 -6
- package/api/@xmachines/play-sveltekit-router/interfaces/RouteMapping.md +3 -3
- package/api/@xmachines/play-sveltekit-router/interfaces/RouterBridge.md +3 -3
- package/api/@xmachines/play-sveltekit-router/type-aliases/RoutableActor.md +1 -1
- package/api/@xmachines/play-tanstack-react-router/classes/RouteMap.md +4 -4
- package/api/@xmachines/play-tanstack-react-router/classes/TanStackReactRouterBridge.md +23 -23
- package/api/@xmachines/play-tanstack-react-router/functions/PlayRouterProvider.md +1 -1
- package/api/@xmachines/play-tanstack-react-router/functions/createRouteMap.md +1 -1
- package/api/@xmachines/play-tanstack-react-router/functions/createRouteMapFromTree.md +1 -1
- package/api/@xmachines/play-tanstack-react-router/functions/extractMachineRoutes.md +1 -1
- package/api/@xmachines/play-tanstack-react-router/interfaces/PlayRouteEvent.md +6 -6
- package/api/@xmachines/play-tanstack-react-router/interfaces/PlayRouterProviderProps.md +5 -5
- package/api/@xmachines/play-tanstack-react-router/interfaces/RouteMapping.md +3 -3
- package/api/@xmachines/play-tanstack-react-router/interfaces/RouteNavigateEvent.md +3 -3
- package/api/@xmachines/play-tanstack-react-router/interfaces/RouterBridge.md +3 -3
- package/api/@xmachines/play-tanstack-react-router/type-aliases/TanStackRouterInstance.md +1 -1
- package/api/@xmachines/play-tanstack-react-router/type-aliases/TanStackRouterLike.md +17 -3
- package/api/@xmachines/play-tanstack-react-router-demo/README.md +23 -29
- package/api/@xmachines/play-tanstack-solid-router/classes/RouteMap.md +4 -4
- package/api/@xmachines/play-tanstack-solid-router/classes/SolidRouterBridge.md +24 -24
- package/api/@xmachines/play-tanstack-solid-router/functions/PlayRouterProvider.md +1 -1
- package/api/@xmachines/play-tanstack-solid-router/functions/createRouteMap.md +1 -1
- package/api/@xmachines/play-tanstack-solid-router/interfaces/PlayRouteEvent.md +6 -6
- package/api/@xmachines/play-tanstack-solid-router/interfaces/PlayRouterProviderProps.md +5 -5
- package/api/@xmachines/play-tanstack-solid-router/interfaces/RouteMapping.md +3 -3
- package/api/@xmachines/play-tanstack-solid-router/interfaces/RouterBridge.md +3 -3
- package/api/@xmachines/play-tanstack-solid-router/type-aliases/RoutableActor.md +1 -1
- package/api/@xmachines/play-tanstack-solid-router/type-aliases/TanStackRouterInstance.md +1 -1
- package/api/@xmachines/play-tanstack-solid-router/type-aliases/TanStackRouterLike.md +3 -3
- package/api/@xmachines/play-tanstack-solid-router-demo/README.md +25 -26
- package/api/@xmachines/play-vue/functions/defineRegistry.md +1 -1
- package/api/@xmachines/play-vue/functions/useActor.md +1 -1
- package/api/@xmachines/play-vue/functions/useStateBinding.md +0 -2
- package/api/@xmachines/play-vue/interfaces/ComponentContext.md +0 -2
- package/api/@xmachines/play-vue/interfaces/PlayRendererProps.md +5 -5
- package/api/@xmachines/play-vue/type-aliases/ComponentEntry.md +1 -1
- package/api/@xmachines/play-vue/type-aliases/ComponentFn.md +0 -2
- package/api/@xmachines/play-vue/type-aliases/ComponentsMap.md +1 -1
- package/api/@xmachines/play-vue/type-aliases/DefineRegistryOptions.md +4 -3
- package/api/@xmachines/play-vue/type-aliases/PlayActor.md +1 -1
- package/api/@xmachines/play-vue/variables/PlayRenderer.md +1 -1
- package/api/@xmachines/play-vue-demo/README.md +145 -0
- package/api/@xmachines/play-vue-router/classes/RouteMap.md +4 -4
- package/api/@xmachines/play-vue-router/classes/VueBaseRouteMap.md +4 -4
- package/api/@xmachines/play-vue-router/classes/VueRouterBridge.md +24 -24
- package/api/@xmachines/play-vue-router/functions/createRouteMap.md +1 -1
- package/api/@xmachines/play-vue-router/interfaces/PlayRouteEvent.md +6 -6
- package/api/@xmachines/play-vue-router/interfaces/RouteMapping.md +3 -3
- package/api/@xmachines/play-vue-router/interfaces/RouterBridge.md +3 -3
- package/api/@xmachines/play-vue-router/type-aliases/RoutableActor.md +1 -1
- package/api/@xmachines/play-vue-router/variables/PlayRouterProvider.md +1 -1
- package/api/@xmachines/play-vue-router-demo/README.md +48 -41
- package/api/@xmachines/play-xstate/classes/PlayerActor.md +11 -25
- package/api/@xmachines/play-xstate/functions/buildRouteUrl.md +1 -1
- package/api/@xmachines/play-xstate/functions/composeGuards.md +1 -1
- package/api/@xmachines/play-xstate/functions/composeGuardsOr.md +1 -1
- package/api/@xmachines/play-xstate/functions/contextFieldMatches.md +1 -1
- package/api/@xmachines/play-xstate/functions/definePlayer.md +1 -1
- package/api/@xmachines/play-xstate/functions/deriveRoute.md +1 -1
- package/api/@xmachines/play-xstate/functions/eventMatches.md +1 -1
- package/api/@xmachines/play-xstate/functions/formatPlayRouteTransitions.md +1 -1
- package/api/@xmachines/play-xstate/functions/hasContext.md +1 -1
- package/api/@xmachines/play-xstate/functions/isAbsoluteRoute.md +1 -1
- package/api/@xmachines/play-xstate/functions/negateGuard.md +1 -1
- package/api/@xmachines/play-xstate/interfaces/PlayerConfig.md +3 -3
- package/api/@xmachines/play-xstate/interfaces/PlayerFactoryResumeOptions.md +2 -2
- package/api/@xmachines/play-xstate/interfaces/PlayerOptions.md +6 -6
- package/api/@xmachines/play-xstate/interfaces/RouteContext.md +5 -5
- package/api/@xmachines/play-xstate/type-aliases/ComposedGuard.md +1 -1
- package/api/@xmachines/play-xstate/type-aliases/Guard.md +1 -1
- package/api/@xmachines/play-xstate/type-aliases/GuardArray.md +1 -1
- package/api/@xmachines/play-xstate/type-aliases/PlayerFactory.md +1 -1
- package/api/@xmachines/play-xstate/type-aliases/RouteMachineConfig.md +4 -4
- package/api/@xmachines/play-xstate/type-aliases/RouteStateNode.md +4 -4
- package/api/@xmachines/shared/functions/defineXmVitestConfig.md +3 -7
- package/api/@xmachines/shared/functions/xmAliases.md +1 -1
- package/api/README.md +6 -2
- package/api/llms.txt +0 -3
- package/examples/README.md +48 -35
- package/examples/basic-state-machine.md +75 -31
- package/examples/form-validation.md +199 -127
- package/examples/multi-router-integration.md +312 -230
- package/examples/routing-patterns.md +243 -189
- package/examples/traffic-light.md +114 -65
- package/guides/README.md +29 -15
- package/guides/getting-started.md +224 -144
- package/guides/installation.md +153 -213
- package/package.json +2 -2
- package/api/@xmachines/play-svelte-spa-router-demo/README.md +0 -23
- package/api/@xmachines/play-sveltekit-router-demo/README.md +0 -23
|
@@ -0,0 +1,187 @@
|
|
|
1
|
+
[Documentation](../../../README.md) / [@xmachines/play-actor-shared](../README.md) / CatalogProps
|
|
2
|
+
|
|
3
|
+
# Type Alias: CatalogProps
|
|
4
|
+
|
|
5
|
+
```ts
|
|
6
|
+
type CatalogProps = object;
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
Defined in: [packages/play-actor/examples/shared/src/catalog.ts:48](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.28/packages/play-actor/examples/shared/src/catalog.ts#L48)
|
|
10
|
+
|
|
11
|
+
## Properties
|
|
12
|
+
|
|
13
|
+
### About
|
|
14
|
+
|
|
15
|
+
```ts
|
|
16
|
+
About: object;
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
Defined in: [packages/play-actor/examples/shared/src/catalog.ts:50](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.28/packages/play-actor/examples/shared/src/catalog.ts#L50)
|
|
20
|
+
|
|
21
|
+
#### title
|
|
22
|
+
|
|
23
|
+
```ts
|
|
24
|
+
title: string;
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
---
|
|
28
|
+
|
|
29
|
+
### Contact
|
|
30
|
+
|
|
31
|
+
```ts
|
|
32
|
+
Contact: object;
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
Defined in: [packages/play-actor/examples/shared/src/catalog.ts:51](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.28/packages/play-actor/examples/shared/src/catalog.ts#L51)
|
|
36
|
+
|
|
37
|
+
#### title
|
|
38
|
+
|
|
39
|
+
```ts
|
|
40
|
+
title: string;
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
---
|
|
44
|
+
|
|
45
|
+
### Dashboard
|
|
46
|
+
|
|
47
|
+
```ts
|
|
48
|
+
Dashboard: object;
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
Defined in: [packages/play-actor/examples/shared/src/catalog.ts:53](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.28/packages/play-actor/examples/shared/src/catalog.ts#L53)
|
|
52
|
+
|
|
53
|
+
#### username
|
|
54
|
+
|
|
55
|
+
```ts
|
|
56
|
+
username: string;
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
#### welcome
|
|
60
|
+
|
|
61
|
+
```ts
|
|
62
|
+
welcome: boolean;
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
---
|
|
66
|
+
|
|
67
|
+
### Home
|
|
68
|
+
|
|
69
|
+
```ts
|
|
70
|
+
Home: object;
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
Defined in: [packages/play-actor/examples/shared/src/catalog.ts:49](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.28/packages/play-actor/examples/shared/src/catalog.ts#L49)
|
|
74
|
+
|
|
75
|
+
#### title
|
|
76
|
+
|
|
77
|
+
```ts
|
|
78
|
+
title: string;
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
---
|
|
82
|
+
|
|
83
|
+
### Login
|
|
84
|
+
|
|
85
|
+
```ts
|
|
86
|
+
Login: object;
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
Defined in: [packages/play-actor/examples/shared/src/catalog.ts:52](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.28/packages/play-actor/examples/shared/src/catalog.ts#L52)
|
|
90
|
+
|
|
91
|
+
#### title
|
|
92
|
+
|
|
93
|
+
```ts
|
|
94
|
+
title: string;
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
---
|
|
98
|
+
|
|
99
|
+
### Navigation
|
|
100
|
+
|
|
101
|
+
```ts
|
|
102
|
+
Navigation: object;
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
Defined in: [packages/play-actor/examples/shared/src/catalog.ts:56](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.28/packages/play-actor/examples/shared/src/catalog.ts#L56)
|
|
106
|
+
|
|
107
|
+
#### currentPath
|
|
108
|
+
|
|
109
|
+
```ts
|
|
110
|
+
currentPath: string;
|
|
111
|
+
```
|
|
112
|
+
|
|
113
|
+
#### isAuthenticated
|
|
114
|
+
|
|
115
|
+
```ts
|
|
116
|
+
isAuthenticated: boolean;
|
|
117
|
+
```
|
|
118
|
+
|
|
119
|
+
---
|
|
120
|
+
|
|
121
|
+
### Overview
|
|
122
|
+
|
|
123
|
+
```ts
|
|
124
|
+
Overview: object;
|
|
125
|
+
```
|
|
126
|
+
|
|
127
|
+
Defined in: [packages/play-actor/examples/shared/src/catalog.ts:57](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.28/packages/play-actor/examples/shared/src/catalog.ts#L57)
|
|
128
|
+
|
|
129
|
+
#### title
|
|
130
|
+
|
|
131
|
+
```ts
|
|
132
|
+
title: string;
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
---
|
|
136
|
+
|
|
137
|
+
### Profile
|
|
138
|
+
|
|
139
|
+
```ts
|
|
140
|
+
Profile: object;
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
Defined in: [packages/play-actor/examples/shared/src/catalog.ts:54](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.28/packages/play-actor/examples/shared/src/catalog.ts#L54)
|
|
144
|
+
|
|
145
|
+
#### username
|
|
146
|
+
|
|
147
|
+
```ts
|
|
148
|
+
username: string;
|
|
149
|
+
```
|
|
150
|
+
|
|
151
|
+
---
|
|
152
|
+
|
|
153
|
+
### Settings
|
|
154
|
+
|
|
155
|
+
```ts
|
|
156
|
+
Settings: object;
|
|
157
|
+
```
|
|
158
|
+
|
|
159
|
+
Defined in: [packages/play-actor/examples/shared/src/catalog.ts:55](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.28/packages/play-actor/examples/shared/src/catalog.ts#L55)
|
|
160
|
+
|
|
161
|
+
#### section?
|
|
162
|
+
|
|
163
|
+
```ts
|
|
164
|
+
optional section?: string;
|
|
165
|
+
```
|
|
166
|
+
|
|
167
|
+
#### username
|
|
168
|
+
|
|
169
|
+
```ts
|
|
170
|
+
username: string;
|
|
171
|
+
```
|
|
172
|
+
|
|
173
|
+
---
|
|
174
|
+
|
|
175
|
+
### Stats
|
|
176
|
+
|
|
177
|
+
```ts
|
|
178
|
+
Stats: object;
|
|
179
|
+
```
|
|
180
|
+
|
|
181
|
+
Defined in: [packages/play-actor/examples/shared/src/catalog.ts:58](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.28/packages/play-actor/examples/shared/src/catalog.ts#L58)
|
|
182
|
+
|
|
183
|
+
#### title
|
|
184
|
+
|
|
185
|
+
```ts
|
|
186
|
+
title: string;
|
|
187
|
+
```
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
[Documentation](../../../README.md) / [@xmachines/play-actor-shared](../README.md) / InferProps
|
|
2
|
+
|
|
3
|
+
# Type Alias: InferProps\<K\>
|
|
4
|
+
|
|
5
|
+
```ts
|
|
6
|
+
type InferProps<K> = CatalogProps[K];
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
Defined in: [packages/play-actor/examples/shared/src/catalog.ts:74](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.28/packages/play-actor/examples/shared/src/catalog.ts#L74)
|
|
10
|
+
|
|
11
|
+
Infer props for a named component from the catalog type
|
|
12
|
+
|
|
13
|
+
## Type Parameters
|
|
14
|
+
|
|
15
|
+
| Type Parameter |
|
|
16
|
+
| ----------------------------------------------------- |
|
|
17
|
+
| `K` _extends_ keyof [`CatalogProps`](CatalogProps.md) |
|
|
@@ -0,0 +1,173 @@
|
|
|
1
|
+
[Documentation](../../../README.md) / [@xmachines/play-actor-shared](../README.md) / authCatalog
|
|
2
|
+
|
|
3
|
+
# Variable: authCatalog
|
|
4
|
+
|
|
5
|
+
```ts
|
|
6
|
+
const authCatalog: Catalog<
|
|
7
|
+
{
|
|
8
|
+
catalog: SchemaType<
|
|
9
|
+
"object",
|
|
10
|
+
{
|
|
11
|
+
actions: SchemaType<
|
|
12
|
+
"map",
|
|
13
|
+
{
|
|
14
|
+
description: SchemaType<"string", unknown>;
|
|
15
|
+
params: SchemaType<"zod", unknown>;
|
|
16
|
+
}
|
|
17
|
+
>;
|
|
18
|
+
components: SchemaType<
|
|
19
|
+
"map",
|
|
20
|
+
{
|
|
21
|
+
description: SchemaType<"string", unknown>;
|
|
22
|
+
example: SchemaType<"any", unknown>;
|
|
23
|
+
props: SchemaType<"zod", unknown>;
|
|
24
|
+
slots: SchemaType<"array", SchemaType<"string", unknown>>;
|
|
25
|
+
}
|
|
26
|
+
>;
|
|
27
|
+
}
|
|
28
|
+
>;
|
|
29
|
+
spec: SchemaType<
|
|
30
|
+
"object",
|
|
31
|
+
{
|
|
32
|
+
elements: SchemaType<
|
|
33
|
+
"record",
|
|
34
|
+
SchemaType<
|
|
35
|
+
"object",
|
|
36
|
+
{
|
|
37
|
+
children: SchemaType<"array", SchemaType<"string", unknown>>;
|
|
38
|
+
props: SchemaType<"propsOf", string>;
|
|
39
|
+
type: SchemaType<"ref", string>;
|
|
40
|
+
visible: SchemaType<"any", unknown>;
|
|
41
|
+
}
|
|
42
|
+
>
|
|
43
|
+
>;
|
|
44
|
+
root: SchemaType<"string", unknown>;
|
|
45
|
+
}
|
|
46
|
+
>;
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
actions: {
|
|
50
|
+
login: {
|
|
51
|
+
description: string;
|
|
52
|
+
params: ZodObject<
|
|
53
|
+
{
|
|
54
|
+
username: ZodString;
|
|
55
|
+
},
|
|
56
|
+
$strip
|
|
57
|
+
>;
|
|
58
|
+
};
|
|
59
|
+
logout: {
|
|
60
|
+
description: string;
|
|
61
|
+
};
|
|
62
|
+
routeDashboard: {
|
|
63
|
+
description: string;
|
|
64
|
+
};
|
|
65
|
+
routeHome: {
|
|
66
|
+
description: string;
|
|
67
|
+
};
|
|
68
|
+
routeLogin: {
|
|
69
|
+
description: string;
|
|
70
|
+
};
|
|
71
|
+
routeOverview: {
|
|
72
|
+
description: string;
|
|
73
|
+
};
|
|
74
|
+
routeProfile: {
|
|
75
|
+
description: string;
|
|
76
|
+
};
|
|
77
|
+
routeSettings: {
|
|
78
|
+
description: string;
|
|
79
|
+
};
|
|
80
|
+
routeStats: {
|
|
81
|
+
description: string;
|
|
82
|
+
};
|
|
83
|
+
};
|
|
84
|
+
components: {
|
|
85
|
+
About: {
|
|
86
|
+
props: ZodObject<
|
|
87
|
+
{
|
|
88
|
+
title: ZodString;
|
|
89
|
+
},
|
|
90
|
+
$strip
|
|
91
|
+
>;
|
|
92
|
+
};
|
|
93
|
+
Contact: {
|
|
94
|
+
props: ZodObject<
|
|
95
|
+
{
|
|
96
|
+
title: ZodString;
|
|
97
|
+
},
|
|
98
|
+
$strip
|
|
99
|
+
>;
|
|
100
|
+
};
|
|
101
|
+
Dashboard: {
|
|
102
|
+
props: ZodObject<
|
|
103
|
+
{
|
|
104
|
+
username: ZodString;
|
|
105
|
+
welcome: ZodBoolean;
|
|
106
|
+
},
|
|
107
|
+
$strip
|
|
108
|
+
>;
|
|
109
|
+
};
|
|
110
|
+
Home: {
|
|
111
|
+
props: ZodObject<
|
|
112
|
+
{
|
|
113
|
+
title: ZodString;
|
|
114
|
+
},
|
|
115
|
+
$strip
|
|
116
|
+
>;
|
|
117
|
+
};
|
|
118
|
+
Login: {
|
|
119
|
+
props: ZodObject<
|
|
120
|
+
{
|
|
121
|
+
title: ZodString;
|
|
122
|
+
},
|
|
123
|
+
$strip
|
|
124
|
+
>;
|
|
125
|
+
};
|
|
126
|
+
Navigation: {
|
|
127
|
+
props: ZodObject<
|
|
128
|
+
{
|
|
129
|
+
currentPath: ZodString;
|
|
130
|
+
isAuthenticated: ZodBoolean;
|
|
131
|
+
},
|
|
132
|
+
$strip
|
|
133
|
+
>;
|
|
134
|
+
};
|
|
135
|
+
Overview: {
|
|
136
|
+
props: ZodObject<
|
|
137
|
+
{
|
|
138
|
+
title: ZodString;
|
|
139
|
+
},
|
|
140
|
+
$strip
|
|
141
|
+
>;
|
|
142
|
+
};
|
|
143
|
+
Profile: {
|
|
144
|
+
props: ZodObject<
|
|
145
|
+
{
|
|
146
|
+
username: ZodString;
|
|
147
|
+
},
|
|
148
|
+
$strip
|
|
149
|
+
>;
|
|
150
|
+
};
|
|
151
|
+
Settings: {
|
|
152
|
+
props: ZodObject<
|
|
153
|
+
{
|
|
154
|
+
section: ZodOptional<ZodString>;
|
|
155
|
+
username: ZodString;
|
|
156
|
+
},
|
|
157
|
+
$strip
|
|
158
|
+
>;
|
|
159
|
+
};
|
|
160
|
+
Stats: {
|
|
161
|
+
props: ZodObject<
|
|
162
|
+
{
|
|
163
|
+
title: ZodString;
|
|
164
|
+
},
|
|
165
|
+
$strip
|
|
166
|
+
>;
|
|
167
|
+
};
|
|
168
|
+
};
|
|
169
|
+
}
|
|
170
|
+
>;
|
|
171
|
+
```
|
|
172
|
+
|
|
173
|
+
Defined in: [packages/play-actor/examples/shared/src/catalog.ts:14](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.28/packages/play-actor/examples/shared/src/catalog.ts#L14)
|
|
@@ -0,0 +1,189 @@
|
|
|
1
|
+
[Documentation](../../../README.md) / [@xmachines/play-actor-shared](../README.md) / authMachine
|
|
2
|
+
|
|
3
|
+
# Variable: authMachine
|
|
4
|
+
|
|
5
|
+
```ts
|
|
6
|
+
const authMachine: StateMachine<AuthContext, AuthEvents, {
|
|
7
|
+
}, never, never, never, never,
|
|
8
|
+
| "login"
|
|
9
|
+
| "home"
|
|
10
|
+
| "about"
|
|
11
|
+
| "contact"
|
|
12
|
+
| "profile"
|
|
13
|
+
| "settings"
|
|
14
|
+
| {
|
|
15
|
+
dashboard: "overview" | "stats";
|
|
16
|
+
}, string, AuthInput, NonReducibleUnknown, EventObject, MetaObject, ToStateSchema<{
|
|
17
|
+
context: (__namedParameters) => object;
|
|
18
|
+
id: string;
|
|
19
|
+
initial: string;
|
|
20
|
+
on: {
|
|
21
|
+
auth.login: {
|
|
22
|
+
actions: ActionFunction<AuthContext, AuthEvents, AuthEvents, undefined, never, never, never, never, never>;
|
|
23
|
+
guard: (__namedParameters) => boolean;
|
|
24
|
+
target: string;
|
|
25
|
+
};
|
|
26
|
+
auth.logout: {
|
|
27
|
+
actions: ActionFunction<AuthContext, AuthEvents, AuthEvents, undefined, never, never, never, never, never>;
|
|
28
|
+
guard: (__namedParameters) => boolean;
|
|
29
|
+
target: string;
|
|
30
|
+
};
|
|
31
|
+
};
|
|
32
|
+
states: {
|
|
33
|
+
about: {
|
|
34
|
+
id: string;
|
|
35
|
+
meta: {
|
|
36
|
+
route: string;
|
|
37
|
+
view: {
|
|
38
|
+
component: string;
|
|
39
|
+
spec: {
|
|
40
|
+
elements: {
|
|
41
|
+
root: {
|
|
42
|
+
children: ...[];
|
|
43
|
+
props: {
|
|
44
|
+
title: ...;
|
|
45
|
+
};
|
|
46
|
+
type: string;
|
|
47
|
+
};
|
|
48
|
+
};
|
|
49
|
+
root: string;
|
|
50
|
+
};
|
|
51
|
+
};
|
|
52
|
+
};
|
|
53
|
+
};
|
|
54
|
+
contact: {
|
|
55
|
+
id: string;
|
|
56
|
+
meta: {
|
|
57
|
+
route: string;
|
|
58
|
+
view: {
|
|
59
|
+
component: string;
|
|
60
|
+
spec: {
|
|
61
|
+
elements: {
|
|
62
|
+
root: {
|
|
63
|
+
children: ...[];
|
|
64
|
+
props: {
|
|
65
|
+
title: ...;
|
|
66
|
+
};
|
|
67
|
+
type: string;
|
|
68
|
+
};
|
|
69
|
+
};
|
|
70
|
+
root: string;
|
|
71
|
+
};
|
|
72
|
+
};
|
|
73
|
+
};
|
|
74
|
+
};
|
|
75
|
+
dashboard: {
|
|
76
|
+
always: {
|
|
77
|
+
guard: (__namedParameters) => boolean;
|
|
78
|
+
target: string;
|
|
79
|
+
};
|
|
80
|
+
id: string;
|
|
81
|
+
initial: string;
|
|
82
|
+
meta: {
|
|
83
|
+
route: string;
|
|
84
|
+
};
|
|
85
|
+
states: {
|
|
86
|
+
overview: {
|
|
87
|
+
id: string;
|
|
88
|
+
meta: {
|
|
89
|
+
route: string;
|
|
90
|
+
view: {
|
|
91
|
+
component: string;
|
|
92
|
+
spec: PlaySpec;
|
|
93
|
+
};
|
|
94
|
+
};
|
|
95
|
+
};
|
|
96
|
+
stats: {
|
|
97
|
+
id: string;
|
|
98
|
+
meta: {
|
|
99
|
+
route: string;
|
|
100
|
+
view: {
|
|
101
|
+
component: string;
|
|
102
|
+
spec: PlaySpec;
|
|
103
|
+
};
|
|
104
|
+
};
|
|
105
|
+
};
|
|
106
|
+
};
|
|
107
|
+
};
|
|
108
|
+
home: {
|
|
109
|
+
id: string;
|
|
110
|
+
meta: {
|
|
111
|
+
route: string;
|
|
112
|
+
view: {
|
|
113
|
+
component: string;
|
|
114
|
+
spec: {
|
|
115
|
+
elements: {
|
|
116
|
+
root: {
|
|
117
|
+
children: ...[];
|
|
118
|
+
props: {
|
|
119
|
+
title: ...;
|
|
120
|
+
};
|
|
121
|
+
type: string;
|
|
122
|
+
};
|
|
123
|
+
};
|
|
124
|
+
root: string;
|
|
125
|
+
};
|
|
126
|
+
};
|
|
127
|
+
};
|
|
128
|
+
};
|
|
129
|
+
login: {
|
|
130
|
+
id: string;
|
|
131
|
+
meta: {
|
|
132
|
+
route: string;
|
|
133
|
+
view: {
|
|
134
|
+
component: string;
|
|
135
|
+
spec: {
|
|
136
|
+
elements: {
|
|
137
|
+
root: {
|
|
138
|
+
children: ...[];
|
|
139
|
+
on: {
|
|
140
|
+
submit: ...;
|
|
141
|
+
};
|
|
142
|
+
props: {
|
|
143
|
+
title: ...;
|
|
144
|
+
username: ...;
|
|
145
|
+
};
|
|
146
|
+
type: string;
|
|
147
|
+
};
|
|
148
|
+
};
|
|
149
|
+
root: string;
|
|
150
|
+
state: {
|
|
151
|
+
username: string;
|
|
152
|
+
};
|
|
153
|
+
};
|
|
154
|
+
};
|
|
155
|
+
};
|
|
156
|
+
};
|
|
157
|
+
profile: {
|
|
158
|
+
always: {
|
|
159
|
+
guard: (__namedParameters) => boolean;
|
|
160
|
+
target: string;
|
|
161
|
+
};
|
|
162
|
+
id: string;
|
|
163
|
+
meta: {
|
|
164
|
+
route: string;
|
|
165
|
+
view: {
|
|
166
|
+
component: string;
|
|
167
|
+
spec: PlaySpec;
|
|
168
|
+
};
|
|
169
|
+
};
|
|
170
|
+
};
|
|
171
|
+
settings: {
|
|
172
|
+
always: {
|
|
173
|
+
guard: (__namedParameters) => boolean;
|
|
174
|
+
target: string;
|
|
175
|
+
};
|
|
176
|
+
id: string;
|
|
177
|
+
meta: {
|
|
178
|
+
route: string;
|
|
179
|
+
view: {
|
|
180
|
+
component: string;
|
|
181
|
+
spec: PlaySpec;
|
|
182
|
+
};
|
|
183
|
+
};
|
|
184
|
+
};
|
|
185
|
+
};
|
|
186
|
+
}>>;
|
|
187
|
+
```
|
|
188
|
+
|
|
189
|
+
Defined in: [packages/play-actor/examples/shared/src/auth-machine.ts:49](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.28/packages/play-actor/examples/shared/src/auth-machine.ts#L49)
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
[Documentation](../../../README.md) / [@xmachines/play-actor-shared](../README.md) / authSetup
|
|
2
|
+
|
|
3
|
+
# Variable: authSetup
|
|
4
|
+
|
|
5
|
+
```ts
|
|
6
|
+
const authSetup: SetupReturn<
|
|
7
|
+
AuthContext,
|
|
8
|
+
AuthEvents,
|
|
9
|
+
{},
|
|
10
|
+
{},
|
|
11
|
+
{},
|
|
12
|
+
{},
|
|
13
|
+
never,
|
|
14
|
+
string,
|
|
15
|
+
AuthInput,
|
|
16
|
+
NonReducibleUnknown,
|
|
17
|
+
EventObject,
|
|
18
|
+
MetaObject
|
|
19
|
+
>;
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
Defined in: [packages/play-actor/examples/shared/src/auth-machine.ts:41](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.28/packages/play-actor/examples/shared/src/auth-machine.ts#L41)
|
|
@@ -2,18 +2,77 @@
|
|
|
2
2
|
|
|
3
3
|
# @xmachines/play-dom
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
**Vanilla DOM renderer for XMachines**
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
`connectRenderer` — a framework-free `PlayRenderer` equivalent that wires an XState v5 actor's `currentView` TC39 Signal to pure DOM rendering via a catalog-typed `DomRegistry`.
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
Zero XMachines dependencies. Upstreamable to @json-render/dom.
|
|
11
|
-
- Outer layer (PlayRenderer): XMachines wrapper. Bridges actor.currentView
|
|
12
|
-
(TC39 Signal) to the inner DOM renderer using watchSignal.
|
|
9
|
+
## Installation
|
|
13
10
|
|
|
14
|
-
|
|
11
|
+
```bash
|
|
12
|
+
npm install @xmachines/play-dom
|
|
13
|
+
```
|
|
15
14
|
|
|
16
|
-
|
|
15
|
+
## Key Exports
|
|
16
|
+
|
|
17
|
+
- `connectRenderer({ actor, registry, container })` — connect actor view signal to DOM
|
|
18
|
+
- `defineRegistry(catalog, { components, actions })` — build a catalog-typed `DomRegistry`
|
|
19
|
+
- `PlayRenderer` — class-based renderer (connect/disconnect lifecycle)
|
|
20
|
+
- `ComponentFn<C, K>` — catalog-typed DOM component function type
|
|
21
|
+
- `ComponentContext<C, K>` — context passed to each `ComponentFn` (props, emit, on, children, bindings)
|
|
22
|
+
- `renderSpec(spec, store, registry, send, actorActions)` — pure Spec → DOM renderer
|
|
23
|
+
|
|
24
|
+
## Usage
|
|
25
|
+
|
|
26
|
+
```ts
|
|
27
|
+
import { definePlayer } from "@xmachines/play-xstate";
|
|
28
|
+
import { connectRenderer, defineRegistry } from "@xmachines/play-dom";
|
|
29
|
+
import { authMachine, authCatalog, type AuthCatalog } from "@xmachines/play-actor-shared";
|
|
30
|
+
import type { ComponentFn } from "@xmachines/play-dom";
|
|
31
|
+
|
|
32
|
+
const Home: ComponentFn<AuthCatalog, "Home"> = ({ props }) => {
|
|
33
|
+
const el = document.createElement("section");
|
|
34
|
+
el.textContent = props.title;
|
|
35
|
+
return el;
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
const { registry } = defineRegistry(authCatalog, {
|
|
39
|
+
components: { Home /* ... */ },
|
|
40
|
+
actions: { login: "auth.login", logout: "auth.logout" },
|
|
41
|
+
});
|
|
42
|
+
|
|
43
|
+
const createPlayer = definePlayer({ machine: authMachine });
|
|
44
|
+
const actor = createPlayer();
|
|
45
|
+
actor.start();
|
|
46
|
+
|
|
47
|
+
const container = document.getElementById("app")!;
|
|
48
|
+
const disconnect = connectRenderer({ actor, registry, container });
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
## Learn More
|
|
52
|
+
|
|
53
|
+
- [DOM Router adapter `@xmachines/play-dom-router`](../play-dom-router/README.md)
|
|
54
|
+
|
|
55
|
+
@xmachines/play-dom — Vanilla DOM renderer for XMachines Play architecture.
|
|
56
|
+
|
|
57
|
+
Public API split into two layers:
|
|
58
|
+
|
|
59
|
+
**XMachines layer** (this package):
|
|
60
|
+
|
|
61
|
+
- `PlayRenderer` — connects actor.currentView signal → DOM renderer
|
|
62
|
+
- `connectRenderer()` — backward-compat functional API
|
|
63
|
+
- `ConnectRendererOptions`, `PlayDomOptions`
|
|
64
|
+
|
|
65
|
+
**json-render layer** (upstreamable to @json-render/dom):
|
|
66
|
+
|
|
67
|
+
- `defineRegistry` — build a catalog-typed DomRegistry
|
|
68
|
+
- `renderSpec` — pure Spec → DOM renderer (uses resolveElementProps from core)
|
|
69
|
+
- `ComponentFn` — catalog-typed component function type
|
|
70
|
+
- `ComponentContext` — catalog-typed render context (props, emit, on, children, bindings)
|
|
71
|
+
- `ComponentRegistry` — catalog-typed registry input type
|
|
72
|
+
- `DomComponentRenderer` — raw element-level renderer type
|
|
73
|
+
- `DomRegistry` — raw registry type
|
|
74
|
+
- `DomRenderContext` — raw render context
|
|
75
|
+
- `EventHandle` — event handle returned by on()
|
|
17
76
|
|
|
18
77
|
## Classes
|
|
19
78
|
|
|
@@ -21,16 +80,23 @@ No framework required. Pure DOM APIs only.
|
|
|
21
80
|
|
|
22
81
|
## Interfaces
|
|
23
82
|
|
|
83
|
+
- [ComponentContext](interfaces/ComponentContext.md)
|
|
24
84
|
- [ConnectRendererOptions](interfaces/ConnectRendererOptions.md)
|
|
85
|
+
- [DefineRegistryOptions](interfaces/DefineRegistryOptions.md)
|
|
86
|
+
- [DefineRegistryResult](interfaces/DefineRegistryResult.md)
|
|
25
87
|
- [DomRenderContext](interfaces/DomRenderContext.md)
|
|
88
|
+
- [EventHandle](interfaces/EventHandle.md)
|
|
26
89
|
- [PlayDomOptions](interfaces/PlayDomOptions.md)
|
|
27
90
|
|
|
28
91
|
## Type Aliases
|
|
29
92
|
|
|
93
|
+
- [ComponentFn](type-aliases/ComponentFn.md)
|
|
94
|
+
- [ComponentRegistry](type-aliases/ComponentRegistry.md)
|
|
30
95
|
- [DomComponentRenderer](type-aliases/DomComponentRenderer.md)
|
|
31
96
|
- [DomRegistry](type-aliases/DomRegistry.md)
|
|
32
97
|
|
|
33
98
|
## Functions
|
|
34
99
|
|
|
35
100
|
- [connectRenderer](functions/connectRenderer.md)
|
|
101
|
+
- [defineRegistry](functions/defineRegistry.md)
|
|
36
102
|
- [renderSpec](functions/renderSpec.md)
|