Skip to content

Commit abb669c

Browse files
committed
feat(frontend): color unselected variant rows light grey
1 parent 3f0309f commit abb669c

File tree

2 files changed

+9
-4
lines changed

2 files changed

+9
-4
lines changed

frontend/src/components/VariantListPage/VariantsTable.tsx

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -724,6 +724,7 @@ const VariantsTable: FC<VariantsTableProps> = ({
724724
}) => {
725725
const rowData = data[dataRowIndex];
726726
const isNotIncluded = notIncludedVariants.has(rowData.id);
727+
const isNotSelected = !selectedVariants.has(rowData.id);
727728

728729
return (
729730
<Tr
@@ -735,7 +736,11 @@ const VariantsTable: FC<VariantsTableProps> = ({
735736
height: `${ROW_HEIGHT}px`,
736737
boxShadow:
737738
"inset -0.65em 0em 1em -1.25em rgba(0, 0, 0, 0.9), inset 0.65em 0em 1em -1.25em rgba(0, 0, 0, 0.9)",
738-
backgroundColor: isNotIncluded ? "#f0f0f0" : "transparent",
739+
backgroundColor: isNotIncluded
740+
? "#f0f0f0"
741+
: isNotSelected
742+
? "#f8f8f8"
743+
: "transparent",
739744
}}
740745
style={style}
741746
>

frontend/src/components/VariantListPage/__snapshots__/VariantsTable.spec.tsx.snap

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -264,7 +264,7 @@ exports[`Variant Table has no unexpected changes 1`] = `
264264
class="css-0"
265265
>
266266
<tr
267-
class="css-11ta1vk"
267+
class="css-12kmu23"
268268
role="row"
269269
style="position: absolute; left: 0px; top: 0px; height: 70px; width: 100%;"
270270
>
@@ -476,7 +476,7 @@ exports[`Variant Table has no unexpected changes 1`] = `
476476
</td>
477477
</tr>
478478
<tr
479-
class="css-11ta1vk"
479+
class="css-12kmu23"
480480
role="row"
481481
style="position: absolute; left: 0px; top: 70px; height: 70px; width: 100%;"
482482
>
@@ -688,7 +688,7 @@ exports[`Variant Table has no unexpected changes 1`] = `
688688
</td>
689689
</tr>
690690
<tr
691-
class="css-11ta1vk"
691+
class="css-12kmu23"
692692
role="row"
693693
style="position: absolute; left: 0px; top: 140px; height: 70px; width: 100%;"
694694
>

0 commit comments

Comments
 (0)