import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
import { Loader } from '../../Loader';
import { Typography } from '../../Typography';
import { classNames } from '../../utils/classNames';
import { loadingPlaceholderClassnames } from './constants';
import { LoadingContainer } from './styles';
/**
 * Дефолтный лоадер загрузки
 */
export const LoadingPlaceholder = ({ title, content, isShowLoader = true, className, }) => {
    if (!isShowLoader) {
        return (_jsx(LoadingContainer, { className: classNames(loadingPlaceholderClassnames.root, className) }));
    }
    if (content) {
        return (_jsx(LoadingContainer, { className: classNames(loadingPlaceholderClassnames.root, className), children: content }));
    }
    return (_jsxs(LoadingContainer, { className: classNames(loadingPlaceholderClassnames.root, className), children: [_jsx(Loader, {}), title && _jsx(Typography, { variant: "h4", children: title })] }));
};
