// #region Imports
// #endregion
const requiredAttribute = 'required';
/**
 * Validator that requires the control's value be true. This validator is commonly used for required checkboxes.
 *
 * State:
 * * valueMissing
 *
 * @public
 * @param control
 * @returns null if the validation check passes, otherwise an object containing information.
 */
export function requiredTrueValidator(element) {
    if (!element.hasAttribute(requiredAttribute)) {
        console.warn(`The '${requiredAttribute}' attribute of '${element.tagName.toLowerCase()}' is missing in the inner form field element.`);
    }
    return element.value
        ? null
        : { valueMissing: true };
}
//# sourceMappingURL=RequiredTrueElementValidatorFn.js.map