Added placeholder
This commit is contained in:
parent
5b4d0c62c8
commit
d56093fa80
1 changed files with 43 additions and 41 deletions
|
|
@ -95,47 +95,49 @@ export default function ComponentsComponent({
|
||||||
>
|
>
|
||||||
<div className="flex h-full w-full flex-col justify-between">
|
<div className="flex h-full w-full flex-col justify-between">
|
||||||
<div className="flex w-full flex-col gap-4">
|
<div className="flex w-full flex-col gap-4">
|
||||||
<div className="grid w-full gap-4 md:grid-cols-2 lg:grid-cols-2">
|
{!isLoading && data.length === 0 ? (
|
||||||
{!isLoading || data?.length > 0 ? (
|
<div className="w-full text-center">You haven't created any {name}s yet.</div>
|
||||||
data?.map((item, idx) => (
|
) : (
|
||||||
<CollectionCardComponent
|
<div className="grid w-full gap-4 md:grid-cols-2 lg:grid-cols-2">
|
||||||
onDelete={() => {
|
{!isLoading || data?.length > 0 ? (
|
||||||
removeFlow(item.id);
|
data?.map((item, idx) => (
|
||||||
}}
|
<CollectionCardComponent
|
||||||
key={idx}
|
onDelete={() => {
|
||||||
data={item}
|
removeFlow(item.id);
|
||||||
disabled={isLoading}
|
}}
|
||||||
button={
|
key={idx}
|
||||||
!is_component ? (
|
data={item}
|
||||||
<Button
|
disabled={isLoading}
|
||||||
variant="outline"
|
button={
|
||||||
size="sm"
|
!is_component ? (
|
||||||
className="whitespace-nowrap "
|
<Button
|
||||||
onClick={() => {
|
variant="outline"
|
||||||
navigate("/flow/" + item.id);
|
size="sm"
|
||||||
}}
|
className="whitespace-nowrap "
|
||||||
>
|
onClick={() => {
|
||||||
<IconComponent
|
navigate("/flow/" + item.id);
|
||||||
name="ExternalLink"
|
}}
|
||||||
className="main-page-nav-button"
|
>
|
||||||
/>
|
<IconComponent
|
||||||
Edit Flow
|
name="ExternalLink"
|
||||||
</Button>
|
className="main-page-nav-button"
|
||||||
) : (
|
/>
|
||||||
<></>
|
Edit Flow
|
||||||
)
|
</Button>
|
||||||
}
|
) : (
|
||||||
/>
|
<></>
|
||||||
))
|
)
|
||||||
) : !isLoading && data?.length === 0 ? (
|
}
|
||||||
<>You haven't created {name}s yet.</>
|
/>
|
||||||
) : (
|
))
|
||||||
<>
|
) : (
|
||||||
<SkeletonCardComponent />
|
<>
|
||||||
<SkeletonCardComponent />
|
<SkeletonCardComponent />
|
||||||
</>
|
<SkeletonCardComponent />
|
||||||
)}
|
</>
|
||||||
</div>
|
)}
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
</div>
|
</div>
|
||||||
{!isLoading && allData.length > 0 && (
|
{!isLoading && allData.length > 0 && (
|
||||||
<div className="relative py-6">
|
<div className="relative py-6">
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue