mirror of
https://github.com/nicotsx/ironmount.git
synced 2025-12-10 12:10:51 +01:00
feat: repositories frontend
This commit is contained in:
18
apps/client/app/components/repository-icon.tsx
Normal file
18
apps/client/app/components/repository-icon.tsx
Normal file
@@ -0,0 +1,18 @@
|
||||
import type { RepositoryBackend } from "@ironmount/schemas/restic";
|
||||
import { Database, HardDrive, Cloud } from "lucide-react";
|
||||
|
||||
type Props = {
|
||||
backend: RepositoryBackend;
|
||||
className?: string;
|
||||
};
|
||||
|
||||
export const RepositoryIcon = ({ backend, className = "h-4 w-4" }: Props) => {
|
||||
switch (backend) {
|
||||
case "local":
|
||||
return <HardDrive className={className} />;
|
||||
case "s3":
|
||||
return <Cloud className={className} />;
|
||||
default:
|
||||
return <Database className={className} />;
|
||||
}
|
||||
};
|
||||
Reference in New Issue
Block a user