@uuv/a11y
Version:
A javascript lib for running a11y validation based on multiple reference(RGAA, etc)
48 lines (47 loc) • 1.9 kB
TypeScript
import { IAttributeSpecification } from "./attribut-specification";
export declare class CompliantSpecification {
readonly attribute: string;
specification: IAttributeSpecification;
constructor(attribute: string, specification: IAttributeSpecification);
}
export declare class AttributeChecker {
/**
* Check if the value of the attributeName is empty
* @param attributeName : HTMLElement attributeName
*/
static emptyAttribute(attributeName: string): CompliantSpecification;
/**
* Check if the value of the attributeName is not empty
* @param attributeName : HTMLElement attributeName
*/
static notEmptyAttribute(attributeName: string): CompliantSpecification;
/**
* Check that the text of the HTMLElement whose id matches the value of the attribute named attributeName another HTMLElement is empty
* @param attributeName : HTMLElement attribute name
*/
static emptyHtmlNodeTargetedByTheAttribute(attributeName: string): CompliantSpecification;
/**
* Check that id attribute is not unique in current page
*/
static notUniqueId(): CompliantSpecification;
/**
* Check that html element does not have the expected value
*/
static notEquals(attributeName: string, expectedValueList: string[]): CompliantSpecification;
/**
* Check that html element have the expected value
*/
static equals(attributeName: string, expectedValueList: string[]): CompliantSpecification;
/**
* Check that html element accessible name contains visible text ignoring case
*/
static accessibleNameNotContainsVisibleText(): CompliantSpecification;
/**
* Check that html element have empty text
*/
static emptyText(): CompliantSpecification;
/**
* Check that html element have not empty text
*/
static notEmptyText(): CompliantSpecification;
}