Home > widget-integration > CombinedProductListingsController > handleParentSwatchChanged
CombinedProductListingsController.handleParentSwatchChanged() method
Handles parent swatch change: resolves child product, clears previous child selection, auto-selects first available child variant, and persists to session.
Signature:
handleParentSwatchChanged(modal: HTMLElement, getSelectedVariant: () => PreOrderVariant | null): void;
Parameters
|
Parameter |
Type |
Description |
|---|---|---|
|
modal |
HTMLElement | |
|
getSelectedVariant |
() => PreOrderVariant | null |
Returns:
void