import React from "react"; // Define the prop types interface SkeletonUIProps { type: "asset" | "assetLibrary" | "assetWidget" | "default"; // You can expand this with other types as needed } // Define the SkeletonUI component const SkeletonUI: React.FC = ({ type }) => { // Function to render skeleton content based on 'type' const renderSkeleton = () => { switch (type) { case "assetLibrary": return ( <> {Array(5) .fill(null) // Create an array of 5 empty items .map((_, index) => (
))} ); case "assetWidget": return (
); case "asset": return ( <>
); default: return (
); } }; return
{renderSkeleton()}
; }; export default SkeletonUI;