Car model only lists the models of the brands you pick, and Fuel type follows both. When a new brand removes a choice, a notice tells you.
Pick a brand to see only its models.
1{{# Needs 'enable_dependent_filters' => true in config/statamic-livewire-filters.php #}}
2
3{{ livewire:lf-checkbox-filter
4 blueprint="cars.car"
5 field="car_brand"
6 condition="taxonomy"
7}}
8
9{{ livewire:lf-checkbox-filter
10 blueprint="cars.car"
11 field="car_model"
12 condition="in"
13 depends_on="car_brand"
14 view="lf-checkbox-advanced"
15 searchable="true"
16}}
17
18{{ livewire:lf-select-filter
19 blueprint="cars.car"
20 field="fuel_type"
21 condition="is"
22 depends_on="car_brand|car_model"
23}}
24
25{{# Tell the visitor what a new brand removed #}}
26<div
27 x-data="{ cleared: [], timer: null }"
28 x-on:dependent-selection-cleared.window="
29 cleared.push(...$event.detail.labels);
30 clearTimeout(timer);
31 timer = setTimeout(() => cleared = [], 6000);
32 "
33 x-show="cleared.length > 0"
34 x-cloak
35>
36 Removed <strong x-text="cleared.join(', ')"></strong>: not available for your new selection.
37</div>