mirror of
https://github.com/arc53/DocsGPT.git
synced 2025-12-01 01:23:14 +00:00
applying loader in the settings respective components
This commit is contained in:
@@ -1,10 +1,17 @@
|
||||
import React from 'react';
|
||||
|
||||
const SkeletonLoader = ({ count = 1 }) => {
|
||||
interface SkeletonLoaderProps {
|
||||
count?: number; // Optional prop to define the number of skeleton loaders
|
||||
}
|
||||
|
||||
const SkeletonLoader: React.FC<SkeletonLoaderProps> = ({ count = 1 }) => {
|
||||
return (
|
||||
<div className="flex space-x-4">
|
||||
{[...Array(count)].map((_, idx) => (
|
||||
<div key={idx} className="p-6 w-60 h-32 bg-gray-800 rounded-3xl animate-pulse">
|
||||
<div
|
||||
key={idx}
|
||||
className="p-6 w-60 h-32 bg-gray-800 rounded-3xl animate-pulse"
|
||||
>
|
||||
<div className="space-y-4">
|
||||
<div className="w-3/4 h-4 bg-gray-500 rounded"></div>
|
||||
<div className="w-full h-4 bg-gray-500 rounded"></div>
|
||||
@@ -18,5 +25,5 @@ const SkeletonLoader = ({ count = 1 }) => {
|
||||
|
||||
export default SkeletonLoader;
|
||||
|
||||
// calling function should be pass --- no. of sketeton cards
|
||||
// calling function should be pass --- no. of sketeton cards
|
||||
// eg . ----------->>> <SkeletonLoader count={4} />
|
||||
|
||||
Reference in New Issue
Block a user