UNPKG

@furystack/shades-common-components

Version:

Common UI components for FuryStack Shades

25 lines 856 B
import type { InputValidationResult } from '../inputs/input.js'; type ValidationOptions = { value: string; required?: boolean; getValidationResult?: (options: { value: string; }) => InputValidationResult; getHelperText?: (options: { value: string; validationResult?: InputValidationResult; }) => JSX.Element | string; }; export type ValidationState = { validationResult: InputValidationResult | undefined; isRequired: boolean; isInvalid: boolean; helperNode: JSX.Element | string; }; /** * Computes validation state from common markdown field props. * Shared between MarkdownInput and MarkdownEditor to keep the logic in one place. */ export declare const resolveValidationState: (options: ValidationOptions) => ValidationState; export {}; //# sourceMappingURL=markdown-validation.d.ts.map