Files
Homarr/src/components/layout/Background.tsx

21 lines
510 B
TypeScript
Raw Normal View History

import { Global } from '@mantine/core';
2022-12-04 17:36:30 +01:00
import { useConfigContext } from '../../config/provider';
export function Background() {
2022-12-04 17:36:30 +01:00
const { config } = useConfigContext();
return (
<Global
styles={{
body: {
minHeight: '100vh',
2022-12-04 17:36:30 +01:00
backgroundImage: `url('${config?.settings.customization.backgroundImageUrl}')` || '',
backgroundPosition: 'center center',
backgroundSize: 'cover',
backgroundRepeat: 'no-repeat',
},
}}
/>
);
}