From fdfcc3d68d7a5d7aa17dfc696168f7c9dd1f1eb2 Mon Sep 17 00:00:00 2001 From: Pedro Bonamin Date: Thu, 2 Nov 2023 17:01:53 +0100 Subject: [PATCH] fix(tests): is this making it fail? --- .../navbar/workspace/WorkspacePreview.tsx | 24 +++++++++++++++---- 1 file changed, 20 insertions(+), 4 deletions(-) diff --git a/packages/sanity/src/core/studio/components/navbar/workspace/WorkspacePreview.tsx b/packages/sanity/src/core/studio/components/navbar/workspace/WorkspacePreview.tsx index 843f347ab74b..e748b655ff06 100644 --- a/packages/sanity/src/core/studio/components/navbar/workspace/WorkspacePreview.tsx +++ b/packages/sanity/src/core/studio/components/navbar/workspace/WorkspacePreview.tsx @@ -15,9 +15,19 @@ interface MediaCardProps { $size: PreviewIconSize } -export const MediaCard = styled(Card)` - width: ${(props) => (props.$size === 'small' ? '35px' : '41px')}; - height: ${(props) => (props.$size === 'small' ? '35px' : '41px')}; +export const MediaCardBig = styled(Card)` + width: 41px; + height: 41px; + + svg { + width: 100%; + height: 100%; + } +` + +export const MediaCard = styled(Card)` + width: 35px; + height: 35px; svg { width: 100%; @@ -33,9 +43,15 @@ export const WorkspacePreviewIcon = ({ size: PreviewIconSize }) => { const iconComponent = useMemo(() => createIcon(icon), [icon]) + if (size === 'large') + return ( + + {iconComponent} + + ) return ( - + {iconComponent} )