reboot alterflixhub

This commit is contained in:
Bkk1234 committed 2026-11-01 17:24:44 +07:00
commit 1e84023a44
188 files changed
+31629

No files matched your search

+31
View File
@@ -0,0 +1,31 @@
/**
* See what the user is currently looking at on screen.
*
* Reads and returns the current navigation state from application state.
*
* Usage:
* pnpm action view-screen
*/
import { defineAction } from "@agent-native/core/action";
import { readAppState } from "@agent-native/core/application-state";
import { z } from "zod";
export default defineAction({
description:
"See what the user is currently looking at on screen. Returns the current navigation state for the app canvas plus agent rail. Always call this first before taking any action.",
schema: z.object({}),
http: false,
readOnly: true,
run: async () => {
const navigation = await readAppState("navigation");
const screen: Record<string, unknown> = {};
if (navigation) screen.navigation = navigation;
if (Object.keys(screen).length === 0) {
return "No application state found. Is the app running?";
}
return screen;
},
});