Files
Homarr/src/components/layout/Background.tsx
2023-07-21 18:08:40 +09:00

22 lines
511 B
TypeScript

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