UNPKG

@baseplate-dev/ui-components

Version:

Shared UI component library

14 lines 573 B
import { jsx as _jsx } from "react/jsx-runtime"; import { ErrorDisplay } from '../error-display/error-display.js'; import { Loader } from '../loader/loader.js'; /** * Displays a loader component that if an error is passed, it will display an error message instead. */ function ErrorableLoader({ className, error, header, actions, }) { if (!error) { return _jsx(Loader, { className: className }); } return _jsx(ErrorDisplay, { header: header, error: error, actions: actions }); } export { ErrorableLoader }; //# sourceMappingURL=errorable-loader.js.map