@codecademy/gamut

72.5.172.5.2-alpha.319fdb.0
dist/Card/index.js
~dist/Card/index.jsModified
+2−2
Index: package/dist/Card/index.js
===================================================================
--- package/dist/Card/index.js
+++ package/dist/Card/index.js
@@ -1,9 +1,9 @@
 import { CheckerDense } from '@codecademy/gamut-patterns';
 import { borderRadii } from '@codecademy/gamut-styles';
 import * as React from 'react';
 import { DynamicCardWrapper, MotionBox, StaticCardWrapper } from './elements';
-import { hoverShadowLeft, hoverShadowRight, patternFadeInOut } from './styles';
+import { patternFadeInOut, useCardElevation } from './styles';
 import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
 export const Card = ({
   children,
   variant = 'default',
@@ -20,9 +20,9 @@
   const resolvedBorderRadius = borderRadii[trueBorderRadius];
   const SelectedWrapper = variant === 'default' ? DynamicCardWrapper : StaticCardWrapper;
   const hasPattern = shadow === 'patternLeft' || shadow === 'patternRight';
   const isOutline = shadow === 'outline';
-  const setHoverShadow = shadow === 'patternRight' ? hoverShadowRight(resolvedBorderRadius) : hoverShadowLeft(resolvedBorderRadius);
+  const setHoverShadow = useCardElevation(shadow, resolvedBorderRadius);
   const initialVariant = isOutline ? 'initialOutline' : 'initial';
   const animateVariant = isOutline ? 'animateOutline' : 'animate';
   return /*#__PURE__*/_jsxs(MotionBox, {
     height: height,