[Form][Validation] Add `forbid_extra_data` option

Fixed indentation.

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #7209
| License       | MIT

Added `ignore_extra_data` option to allow form validation pass, even with extra data.