Skip to content

Commit

Permalink
Updated component naming convention
Browse files Browse the repository at this point in the history
  • Loading branch information
xKhronoz committed May 19, 2024
1 parent 3f29cf6 commit a25e12f
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
10 changes: 5 additions & 5 deletions frontend/app/components/admin-section.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"use client";

import { useState } from "react";
import { AdminMenu, AdminCollectionsRequests, AdminManageCollections, AdminManageUsers } from "@/app/components/ui/admin";
import { AdminMenu, AdminManageRequests, AdminManageCollections, AdminManageUsers } from "@/app/components/ui/admin";
import { ToastContainer } from "react-toastify";
import "react-toastify/dist/ReactToastify.css";

Expand All @@ -26,17 +26,17 @@ const AdminSection: React.FC = () => {
setShowCollections={setShowCollections}
/>

{/* New Requests Section */}
{/* Manage Requests Section */}
{showNewRequest ? (
<AdminCollectionsRequests />
<AdminManageRequests />
) : null}

{/* Public Collections Section */}
{/* Manage Collections Section */}
{showCollections ? (
<AdminManageCollections />
) : null}

{/* Users Section */}
{/* Manage Users Section */}
{showUsers ? (
<AdminManageUsers />
) : null}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { IconSpinner } from '@/app/components/ui/icons';
import { toast } from 'react-toastify';
import Swal from 'sweetalert2';

export default function AdminCollectionsRequests() {
export default function AdminManageRequests() {
const [userRequests, setUserRequests] = useState<any[]>([]);
const [loading, setLoading] = useState<boolean>(true);
const [isRefreshed, setIsRefreshed] = useState<boolean>(true); // Track whether the data has been refreshed
Expand Down
4 changes: 2 additions & 2 deletions frontend/app/components/ui/admin/index.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import AdminMenu from './admin-menu';
import AdminManageUsers from './admin-manage-users';
import AdminCollectionsRequests from './admin-collections-requests';
import AdminManageRequests from './admin-manage-requests';
import AdminManageCollections from './admin-manage-collections';

export {
AdminMenu,
AdminCollectionsRequests,
AdminManageRequests,
AdminManageCollections,
AdminManageUsers
};

0 comments on commit a25e12f

Please sign in to comment.