@studiohyperdrive/ngx-forms
Version:
An Angular package to help with complex forms and their validation.
12 lines (11 loc) • 479 B
TypeScript
import { FormGroup } from '@angular/forms';
/**
* FormGroup validator which checks if either all values or no values are filled in
*
* @param controls - An array of controls.
* @param dependedControlKey - A control within the group which the other controls depend on.
* @param matchFunction - Optional function the dependedControl should check
*/
export declare const allOrNothingRequiredValidator: (form: FormGroup) => {
allOrNothingRequiredError: string[];
} | null;