Skip to content

Commit

Permalink
Increase feature slider height for smallest screens (#47058)
Browse files Browse the repository at this point in the history
In our empty state pages, we have this neat purple frame that slides
over each feature. This gets very slightly wonky if the feature text is
a bit too large. This just bumps up the height for the smallest screens
to give a bit more breathing room to the text.
  • Loading branch information
avatus committed Oct 2, 2024
1 parent a9e0a96 commit 473b149
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions web/packages/shared/components/EmptyState/EmptyState.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ export const FeatureContainer = styled(Flex)`
@media (max-width: 1302px) {
--feature-slider-width: 372px;
--feature-width: 372px;
--feature-height: 112px;
--feature-height: 120px;
--feature-preview-scale: scale(0.7);
--feature-text-display: inline;
}
Expand All @@ -55,8 +55,7 @@ export const FeatureSlider = styled.div<{ $currIndex: number }>`
top: calc(var(--feature-height) * ${p => p.$currIndex});
background-color: ${p =>
p.theme.colors.interactive.tonal.primary[0].background};
background-color: ${p => p.theme.colors.interactive.tonal.primary[0]};
`;

export type FeatureProps = {
Expand Down Expand Up @@ -101,7 +100,7 @@ export const Feature = styled(Box)<{ $isSliding?: boolean; $active?: boolean }>`
background-color: ${p =>
!p.$isSliding && p.$active
? p => p.theme.colors.interactive.tonal.primary[0].background
? p => p.theme.colors.interactive.tonal.primary[0]
: 'inherit'};
${Title} {
Expand Down

0 comments on commit 473b149

Please sign in to comment.