@public-ui/components
Version:
Contains all web components that belong to KoliBri - The accessible HTML-Standard.
13 lines (12 loc) • 493 B
JavaScript
/*!
* KoliBri - The accessible HTML-Standard
*/
import { headingLevelOptions } from "../../internal/props/level";
import { watchValidator } from "../../schema/utils";
export const watchHeadingLevel = (component, value) => {
watchValidator(component, '_level', (value) => typeof value === 'number' && headingLevelOptions.includes(value), new Set(headingLevelOptions.map(String)), value, {
defaultValue: 1,
required: true,
});
};
//# sourceMappingURL=validation.js.map