UNPKG

@public-ui/components

Version:

Contains all web components that belong to KoliBri - The accessible HTML-Standard.

22 lines (17 loc) 918 B
/*! * KoliBri - The accessible HTML-Standard */ import { b as watchBoolean, I as watchNumber, a as watchValidator } from './prop.validators.js'; const validateHasCounter = (component, value, options) => { watchBoolean(component, '_hasCounter', value, options); }; const validateMaxLength = (component, value, options = {}) => { watchNumber(component, '_maxLength', value, Object.assign({ min: 0 }, options)); }; const maxLengthBehaviorPropTypeOptions = ['hard', 'soft']; const validateMaxLengthBehavior = (component, value) => { watchValidator(component, '_maxLengthBehavior', (value) => typeof value === 'string' && maxLengthBehaviorPropTypeOptions.includes(value), new Set(['String {hard, soft}']), value); }; export { validateHasCounter as a, validateMaxLength as b, validateMaxLengthBehavior as v }; //# sourceMappingURL=max-length-behavior.js.map //# sourceMappingURL=max-length-behavior.js.map