BrickclayDesign System

Validator

bk-validator: a small, reusable error-message renderer for template-driven forms. Point it at an NgModel (via a template reference) and gate it with showError.

bk-validatorForms and inputsAngular

Preview

A working preview of Validator in the Brickclay style. Try it.

Interact with the preview to see events here.

Required field

Email pattern

Focus a field, leave it empty (or invalid), then blur to see the message.

API reference

InputTypeDefaultDescription
controlNgModelrequiredThe template-driven control to read validity from.
labelstringrequiredField label used in the message.
errorMessagestring''Message text shown when visible.
showErrorbooleanfalseCaller decides when to show it (e.g. invalid && touched).