import type { GraphLayout } from '../editing.js'; import type { DependencyGraphEditor } from './editorApi.js'; import { type RunWarning } from './runWarnings.js'; import { type RunLink, type WorkflowJob } from './types.js'; export type ViewMode = 'dag' | 'tree'; export declare const addCleanupSteps: ({ jobs }: { jobs: Record; }) => Record; interface GraphRun { id?: string | undefined; number?: number | undefined; slug?: string | undefined; workflowName?: string | undefined; status?: string | undefined; statusReason?: string | undefined; createdAt?: string | undefined; completedAt?: string | undefined; executedJobs?: Record | undefined; links?: Record | undefined; /** What is probably wrong with the run's jobs and steps as written, listed over the graph and * marked on each job and step they're about, which matters most for one skipped without a log. */ warnings?: readonly RunWarning[] | null | undefined; } export default function DependencyGraph({ run, preview, removeBorder, viewMode, setViewMode, layout, editor, yamlJobs, inputs, workflow, fixedHeight, fill, openStep, onCloseLog, stickySidebar, bleed, still, maxHeight, }: { run: GraphRun; preview?: boolean; removeBorder?: boolean | undefined; viewMode?: ViewMode; setViewMode?: (mode: ViewMode) => void; layout?: GraphLayout | undefined; editor?: DependencyGraphEditor | undefined; yamlJobs?: Record | undefined; inputs?: Record | undefined; /** The workflow as written, for what the editor's expressions can read. */ workflow?: Record | undefined; fixedHeight?: string | undefined; /** Takes its container's height, with `fixedHeight` 100%; the graph refits as the panel * resizes, until the reader pans or zooms it. */ fill?: boolean | undefined; /** A step to open; `prefix` is its `subworkflows//step_/` chain when it runs inside a subworkflow. */ openStep?: { job: string; step: number; prefix?: string | undefined; } | undefined; /** Called when the log dialog closes, so a host can forget the step it asked to open. */ onCloseLog?: (() => void) | undefined; /** Pins the job list as the page scrolls, under whatever the page already pins at its top. */ stickySidebar?: boolean | undefined; /** On a phone, the jobs' panel, graph or list, reaches past the host's content padding (`p-4`) to * the container's edges, without side borders or corners, so a job's row has the screen's width. */ bleed?: boolean | undefined; /** A run's graph to glance at, as in a hover card: its jobs in their statuses, fitted to the * panel's width, the panel as tall as the graph up to `maxHeight`, with nothing around the graph * and nothing in it to pan, zoom or press. */ still?: boolean | undefined; /** The tallest a still graph's panel grows, in pixels. */ maxHeight?: number | undefined; }): import("react").JSX.Element | undefined; export declare function DependencyGraphPreview(inputs: { yml?: Record; removeBorder?: boolean; layout?: GraphLayout | undefined; editor?: DependencyGraphEditor | undefined; /** A fixed panel height; without one the panel is only as tall as the graph. */ height?: string | undefined; /** Takes its container's height instead, such as a pane's, and refits the graph as the pane * resizes until the reader pans or zooms it. */ fill?: boolean | undefined; }): import("react").JSX.Element; export {};