import type { Accessor } from "solid-js";
import type { HostSharedState, PageCommand } from "../sdk/protocol";

export type PageProps = {
  state: Accessor<HostSharedState | null>;
  /**
   * False while a keep-alive iframe is hidden. Page-owned polling, media or
   * render loops should pause until this accessor becomes true again.
   */
  active: Accessor<boolean>;
  command: (command: PageCommand) => void;
};
