Selection validators run every time a seat is selected or deselected. They check whether there are no orphan seats, and/or whether all selected seats are consecutive (meaning: next to each other and in the same category).
A typical way to use this is to disable the checkout button on your form and to show a warning when onSelectionInvalid is triggered.
Checks for orphan seats. An orphan is a single seat that's left open.
There's one exception: near the end of the sales, when the venue is almost completely sold-out, we allow single empty seats in some cases. E.g. in the example below, the ticket buyer has to leave an empty seat if he wants 2 seats. In that case, we don't consider the empty seat an orphan:
You can make the orphan seats validator less restrictive by passing in
In lenient mode, single empty seats are not considered orphans if there's no other way than to leave an empty seat in the current 'block'. Meaning: in the current group of selectable seats that are next to each other:
The default mode is 'strict'.
When you apply a social distancing ruleset with disabled seats to the sides, we automatically enable the orphan seats validator. If you want to disable it, you can do so by passing in
By default, orphans are highlighted by an exclamation mark, and are colored red. If you prefer this doesn't happen, pass in
Checks for seats that are not on the same row or not next to each other. Also, it checks for seats that don't have the same category.