
import { C as Run, D as RunType, J as ValueDiffDetailViewOptions, Y as ValueDiffParams, dt as ProfileDiffViewOptions, ft as TopKDiffParams, ht as TopKViewOptions, lt as ProfileDiffParams, ot as HistogramDiffParams, s as LineageDiffViewOptions, wt as QueryViewOptions, yt as QueryDiffViewOptions, zt as AxiosQueryParams } from "./instanceInfo-D9Pe6gIo.js";
import { r as DataGridHandle } from "./ScreenshotDataGrid-BFA3jIej.js";
import * as react6 from "react";
import { ComponentType, ForwardRefExoticComponent, ReactNode, Ref, RefAttributes } from "react";
import * as react_jsx_runtime13 from "react/jsx-runtime";

//#region src/components/run/RunToolbar.d.ts
/**
 * Common view options for diff-based result views.
 * Used to control what data is shown in diff results.
 */
interface DiffViewOptions {
  /** When true, only show rows/columns that have changed */
  changed_only?: boolean;
}
/**
 * Props for the RunToolbar component
 */
interface RunToolbarProps {
  /** Array of warning messages to display */
  warnings?: string[];
  /** Toolbar actions or other content */
  children?: ReactNode;
  /** Optional CSS class */
  className?: string;
}
/**
 * RunToolbar Component
 *
 * A pure presentation component for displaying run toolbar with warnings.
 * Warnings are displayed with amber background when present.
 *
 * @example Basic usage with warnings
 * ```tsx
 * import { RunToolbar } from '@datarecce/ui/primitives';
 *
 * function RunPane({ run }) {
 *   return (
 *     <RunToolbar warnings={run.warnings}>
 *       <Button onClick={handleExport}>Export</Button>
 *     </RunToolbar>
 *   );
 * }
 * ```
 *
 * @example Without warnings
 * ```tsx
 * <RunToolbar>
 *   <Switch label="Changed only" />
 *   <Button onClick={handleCopy}>Copy</Button>
 * </RunToolbar>
 * ```
 */
declare function RunToolbarComponent({
  warnings,
  children,
  className
}: RunToolbarProps): react_jsx_runtime13.JSX.Element;
declare const RunToolbar: react6.MemoExoticComponent<typeof RunToolbarComponent>;
//#endregion
//#region src/components/run/types.d.ts
/**
 * Base props for run form components.
 * Generic type PT represents the params type for the specific run type.
 *
 * @example
 * interface MyFormProps extends RunFormProps<MyRunParams> {}
 */
interface RunFormProps<PT = unknown> {
  /** Current form parameter values */
  params: Partial<PT>;
  /** Callback when params change */
  onParamsChanged: (params: Partial<PT>) => void;
  /** Callback to set whether the form is valid and ready to execute */
  setIsReadyToExecute: (isReadyToExecute: boolean) => void;
}
/**
 * Base props for run result view components.
 * Generic type VO represents the view options type for the specific run type.
 *
 * @example
 * interface MyResultViewProps extends RunResultViewProps<MyViewOptions> {}
 */
interface RunResultViewProps<VO = unknown> {
  /** The run object containing execution results */
  run: Run;
  /** Optional view options to control how results are displayed */
  viewOptions?: VO;
  /** Callback when view options change */
  onViewOptionsChanged?: (viewOptions: VO) => void;
}
/**
 * Type for icon components - compatible with react-icons IconType pattern.
 * Uses a permissive type to allow react-icons IconType and custom icon components.
 *
 * This type accepts any component that can render an icon. The actual props
 * depend on the icon library used (react-icons, @mui/icons-material, etc.)
 */
type IconComponent = ComponentType<any>;
/**
 * Configuration for a single run type in the registry.
 * Icons and components are injectable, enabling extension/override.
 *
 * @param RefType - Type for the ref (DataGridHandle, HTMLDivElement, etc.)
 * @param ViewOptions - Type for view options specific to this run type
 * @param FormParams - Type for form parameters specific to this run type
 */
interface RunTypeConfig<RefType = unknown, ViewOptions = unknown, FormParams = unknown> {
  /** Human-readable title for the run type */
  title: string;
  /** Icon component for the run type - injectable for customization */
  icon: IconComponent;
  /** Optional result view component (forwardRef) for rendering run results */
  RunResultView?: ForwardRefExoticComponent<RunResultViewProps<ViewOptions> & RefAttributes<RefType>>;
  /** Optional form component for configuring run parameters */
  RunForm?: ComponentType<RunFormProps<FormParams>>;
}
/**
 * Interface for the full run type registry.
 * Consumers can extend this with additional run types:
 *
 * @example
 * const cloudRegistry: RunTypeRegistry & { custom: RunTypeConfig } = {
 *   ...defaultRunTypeRegistry,
 *   custom: { title: "Custom", icon: MyIcon }
 * };
 */
type RunTypeRegistry = { [K in RunType]: RunTypeConfig };
/**
 * Partial registry for registry extension/override patterns.
 * Useful when consumers want to override only some run types.
 *
 * @example
 * const overrides: Partial<RunTypeRegistry> = {
 *   query: { ...defaultRunTypeRegistry.query, icon: CustomQueryIcon }
 * };
 */
type PartialRunTypeRegistry = Partial<RunTypeRegistry>;
/**
 * Union of ref types used by run result views.
 * DataGridHandle for data grid components, HTMLDivElement for others.
 */
type RunResultViewRef = Ref<unknown> | Ref<HTMLDivElement>;
/**
 * Union of all view option types used across run result views.
 * Includes options for lineage diff, query diff, profile diff, etc.
 */
type ViewOptionTypes = LineageDiffViewOptions | DiffViewOptions | QueryViewOptions | QueryDiffViewOptions | ProfileDiffViewOptions | ValueDiffDetailViewOptions | TopKViewOptions;
/**
 * Union of ref types for result views.
 * DataGridHandle for data grid components, HTMLDivElement for others.
 */
type RefTypes = Ref<DataGridHandle> | Ref<HTMLDivElement>;
/**
 * Union of form param types for run forms.
 * These are the API-level parameter types.
 */
type RunFormParamTypes = ProfileDiffParams | ValueDiffParams | TopKDiffParams | HistogramDiffParams | AxiosQueryParams;
/**
 * Alias for RunTypeConfig for backward compatibility with OSS code.
 * RegistryEntry was the original name used in OSS registry.ts.
 *
 * @param RefType - Type for the ref (DataGridHandle, HTMLDivElement, etc.)
 * @param ViewOptions - Type for view options specific to this run type
 * @param FormParams - Type for form parameters specific to this run type
 */
type RegistryEntry<RefType = RefTypes, ViewOptions = ViewOptionTypes, FormParams = RunFormParamTypes> = RunTypeConfig<RefType, ViewOptions, FormParams>;
//#endregion
export { RunFormParamTypes as a, RunResultViewRef as c, ViewOptionTypes as d, DiffViewOptions as f, RegistryEntry as i, RunTypeConfig as l, RunToolbarProps as m, PartialRunTypeRegistry as n, RunFormProps as o, RunToolbar as p, RefTypes as r, RunResultViewProps as s, IconComponent as t, RunTypeRegistry as u };
//# sourceMappingURL=types-LBo5v16M.d.ts.map