import { UseQueryResult } from '@tanstack/react-query'; import { RequestOptions } from '@elaraai/e3-api-client'; import { EastTypeValue } from '@elaraai/east'; import { PlatformFunction } from '@elaraai/east/internal'; import { QueryOverrides } from './types.js'; export interface UseDatasetValueOptions { requestOptions?: RequestOptions; queryOverrides?: QueryOverrides; /** Set false to skip the fetch (e.g. when oversized). Defaults to true. */ enabled?: boolean; /** * Hash of the current dataset version. Used as part of the query key so * the cached value invalidates when the underlying data changes. Pass * `null` if not yet known — the fetch is gated on it being non-null. */ hash?: string | null; /** * Platform implementations passed to `decodeBeast2For`. Closures inside * the decoded value (callbacks, etc) close over these. Defaults to the * global Data/State/Overlay impls. Pass a manifest-scoped variant for * per-subtree read/write validation. */ platforms?: PlatformFunction[]; /** East type to decode against. Required. */ type: EastTypeValue; } export interface DatasetValueResult { decoded: unknown; sizeBytes: number; } /** Fetch + decode a dataset value. Caller is responsible for size gating. */ export declare function useDatasetValue(apiUrl: string, repo: string, workspace: string | null, datasetPath: string | null, options: UseDatasetValueOptions): UseQueryResult; /** Trigger a binary download of a dataset value. */ export declare function useDatasetDownload(apiUrl: string, repo: string, workspace: string | null, datasetPath: string | null, requestOptions?: RequestOptions): () => Promise; //# sourceMappingURL=useDatasetValue.d.ts.map