# Shadows

### Mui core shadows

We used core shadows as provided by MUI. Refer: <https://mui.com/system/shadows/>

### Customized `customShadows`

There are few shadows that we customized as per theme's need. check here: `src\themes\shadows.tsx`.&#x20;

**Demo**: <https://berrydashboard.com/utils/util-shadow>

### How to use

1. &#x20;Import MUI theme
2. &#x20;Use shadow with an element.

<pre class="language-typescript"><code class="lang-typescript">import {useTheme} from '@mui/material/style';

function YourComponent() {
<strong> const theme = useTheme();
</strong>
 return (
  &#x3C;>
   ...
   ...
<strong>    // normal shadow
</strong>    &#x3C;Box sx={{ boxShadow: theme.customShadows.z1 }}>....&#x3C;/Box>

    // shadows according to palette
<strong>    &#x3C;Box sx={{ boxShadow: theme.customShadows.primary }}>....&#x3C;/Box>
</strong>   ...
   ...
  &#x3C;/>
 )
}
</code></pre>
