Skip to content

Commit

Permalink
fix(app/product): users can always change colors
Browse files Browse the repository at this point in the history
This patch updates the frontend to allow users to always change the
selected color. If their currently selected size is not available in a
color, selecting that color will simply select the first size option.
  • Loading branch information
nicholaschiang committed Feb 25, 2024
1 parent 3eb4627 commit b95f8f3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/routes/_wardrobe.products.$product/variants.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ function Colors() {
key={color}
label={color}
prices={variantsWithColor.flatMap((v) => v.prices)}
variant={active}
variant={active ?? variantsWithColor[0]}
/>
)
})}
Expand Down

0 comments on commit b95f8f3

Please sign in to comment.