diff --git a/CHANGELOG.md b/CHANGELOG.md index 6ec68565..e0d48165 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,10 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) a ## [Unreleased] +### Added + +- `labelComponents` options to add custom label components in `form-control-has-label` + ## [1.1.1] - 2021-12-23 ### Changed diff --git a/docs/form-control-has-label.md b/docs/form-control-has-label.md index 2865efa4..11cc8f5c 100644 --- a/docs/form-control-has-label.md +++ b/docs/form-control-has-label.md @@ -8,6 +8,23 @@ _References:_ ## Rule details +This rule takes one optional object argument of type object: + +```json +{ + "rules": { + "vuejs-accessibility/form-control-has-label": [ + "error", + { + "labelComponents": ["CustomLabel"], + } + ] + } +} +``` + +For the `labelComponents` option, these strings determine which elements (**always including** `