/** * useConfigPanelValidation - ConfigPanelのバリデーション専用カスタムフック * * このフックは、純粋関数(validation.ts)のラッパーとして機能します。 * validateInput(完全なバリデーション)とcanApply(必須入力チェックのみ)を提供します。 * * バリデーションロジック自体は純粋関数として utils/validation.ts に実装されており、 * このカスタムフックはそれらをメモ化して提供します。 * * @example * ```tsx * const { validateInput, canApply } = useConfigPanelValidation({ * filterConfig, * operator, * selectedValues, * selectedRadioValue, * startDate, * endDate, * value, * isRangeOperator, * }); * ``` */ import { FilterTypeConfig } from "../types"; export type UseConfigPanelValidationProps = { filterConfig?: FilterTypeConfig; operator: string; selectedValues: (string | boolean)[]; selectedRadioValue: string | boolean; startDate: string; endDate: string; value: string; isRangeOperator: (operator: string) => boolean; }; export type UseConfigPanelValidationReturn = { validateInput: () => { isValid: boolean; errorMessage: string; }; canApply: () => boolean; }; export declare const useConfigPanelValidation: ({ filterConfig, operator, selectedValues, selectedRadioValue, startDate, endDate, value, isRangeOperator, }: UseConfigPanelValidationProps) => UseConfigPanelValidationReturn;