import TinyHtmlInput from '../../TinyHtmlInput.mjs';
/**
* TinyHtmlCheckboxInput is a helper class for managing elements.
* It allows configuring standard attributes such as name, value, checked, readonly, and required,
* with validation and getter/setter consistency.
*
* @example
* const checkbox = new TinyHtmlCheckboxInput({
* name: 'acceptTerms',
* checked: true,
* value: 'yes'
* });
*/
declare class TinyHtmlCheckboxInput extends TinyHtmlInput {
/**
* Creates a new TinyHtmlCheckboxInput instance.
* @param {Object} config - Configuration object.
* @param {boolean} [config.checked=false] - Whether the checkbox is checked.
* @param {string} config.name - Input name attribute.
* @param {string} [config.value] - Input value when checked.
* @param {boolean} [config.readonly=false] - Whether the checkbox is readonly.
* @param {boolean} [config.required=false] - Whether the checkbox is required.
* @param {string|string[]|Set} [config.tags=[]] - Initial CSS classes.
* @param {string} [config.mainClass=''] - Main CSS class.
* @throws {TypeError} If an attribute is of the wrong type.
*/
constructor({ checked, name, value, readonly, required, tags, mainClass, }: {
checked?: boolean;
name: string;
value?: string;
readonly?: boolean;
required?: boolean;
tags?: string | string[] | Set;
mainClass?: string;
});
/** @param {boolean} checked */
set checked(checked: boolean);
/** @returns {boolean} */
get checked(): boolean;
/** @param {string} value */
set value(value: string);
/** @returns {string|null} */
get value(): string | null;
/**
* Checks the checkbox.
* @returns {this}
*/
check(): this;
/**
* Unchecks the checkbox.
* @returns {this}
*/
uncheck(): this;
/**
* Toggles the checkbox state.
* @returns {this}
*/
toggle(): this;
}
export default TinyHtmlCheckboxInput;
//# sourceMappingURL=TinyHtmlCheckboxInput.d.mts.map