mirror of
https://github.com/Portabase/portabase.git
synced 2026-07-14 11:16:13 +02:00
Correcting error loop in StatusBadge.
This commit is contained in:
@@ -4,7 +4,6 @@ import {CardsWithPagination} from "@/components/wrappers/cards-with-pagination";
|
|||||||
import {Button} from "@/components/ui/button";
|
import {Button} from "@/components/ui/button";
|
||||||
import Link from 'next/link'
|
import Link from 'next/link'
|
||||||
import {Page, PageActions, PageContent, PageHeader, PageTitle} from "@/features/layout/page";
|
import {Page, PageActions, PageContent, PageHeader, PageTitle} from "@/features/layout/page";
|
||||||
import {projects} from "@/utils/mock-data";
|
|
||||||
import {ProjectCard} from "@/components/wrappers/Dashboard/Projects/ProjectCard/ProjectCard";
|
import {ProjectCard} from "@/components/wrappers/Dashboard/Projects/ProjectCard/ProjectCard";
|
||||||
|
|
||||||
export default async function RoutePage(props: PageParams<{}>) {
|
export default async function RoutePage(props: PageParams<{}>) {
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
"use client"
|
|
||||||
import {Tabs, TabsContent, TabsList, TabsTrigger} from "@/components/ui/tabs";
|
import {Tabs, TabsContent, TabsList, TabsTrigger} from "@/components/ui/tabs";
|
||||||
import {DataTableWithPagination} from "@/components/wrappers/table/data-table-with-pagination";
|
import {DataTableWithPagination} from "@/components/wrappers/table/data-table-with-pagination";
|
||||||
import {backupColumns} from "@/features/backup/columns";
|
import {backupColumns} from "@/features/backup/columns";
|
||||||
@@ -20,7 +19,6 @@ export const DatabaseTabs = (props: DatabaseTabsProps) => {
|
|||||||
</TabsList>
|
</TabsList>
|
||||||
|
|
||||||
<TabsContent className="h-full justify-between" value="backup">
|
<TabsContent className="h-full justify-between" value="backup">
|
||||||
|
|
||||||
<DataTableWithPagination columns={backupColumns} data={props.backups}/>
|
<DataTableWithPagination columns={backupColumns} data={props.backups}/>
|
||||||
</TabsContent>
|
</TabsContent>
|
||||||
|
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ import {Badge} from "@/components/ui/badge";
|
|||||||
import {cn} from "@/lib/utils";
|
import {cn} from "@/lib/utils";
|
||||||
|
|
||||||
export type statusBadgeProps = {
|
export type statusBadgeProps = {
|
||||||
status: "pending" | "processing" | "success" | "failed"
|
status: "pending" | "ongoing" | "success" | "failed"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -14,7 +14,7 @@ export const StatusBadge = ({status}: statusBadgeProps) => {
|
|||||||
case 'pending':
|
case 'pending':
|
||||||
style = "text-yellow-500 border-yellow-500"
|
style = "text-yellow-500 border-yellow-500"
|
||||||
break
|
break
|
||||||
case 'processing':
|
case 'ongoing':
|
||||||
style = "text-orange-500 border-orange-500"
|
style = "text-orange-500 border-orange-500"
|
||||||
break
|
break
|
||||||
case 'failed':
|
case 'failed':
|
||||||
@@ -24,7 +24,7 @@ export const StatusBadge = ({status}: statusBadgeProps) => {
|
|||||||
style = "text-green-500 border-green-500"
|
style = "text-green-500 border-green-500"
|
||||||
break
|
break
|
||||||
default:
|
default:
|
||||||
throw Error
|
style = "text-yellow-500 border-yellow-500"
|
||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|||||||
Reference in New Issue
Block a user