plane/packages/ui/src/loader.tsx
Aaryan Khandelwal ac4bb1c1b4
refactor: remove unused icon files (#4297)
* refactor: remove unused icon files

* refactor: attachment icons folder structure
2024-04-29 00:51:31 +05:30

30 lines
613 B
TypeScript

import React from "react";
// helpers
import { cn } from "../helpers";
type Props = {
children: React.ReactNode;
className?: string;
};
const Loader = ({ children, className = "" }: Props) => (
<div className={cn("animate-pulse", className)} role="status">
{children}
</div>
);
type ItemProps = {
height?: string;
width?: string;
};
const Item: React.FC<ItemProps> = ({ height = "auto", width = "auto" }) => (
<div className="rounded-md bg-custom-background-80" style={{ height: height, width: width }} />
);
Loader.Item = Item;
Loader.displayName = "plane-ui-loader";
export { Loader };