diff --git a/cannaiq/src/pages/Users.tsx b/cannaiq/src/pages/Users.tsx index a09ebdbf..f7457ba2 100644 --- a/cannaiq/src/pages/Users.tsx +++ b/cannaiq/src/pages/Users.tsx @@ -2,7 +2,7 @@ import { useState, useEffect } from 'react'; import { Layout } from '../components/Layout'; import { api } from '../lib/api'; import { useAuthStore } from '../store/authStore'; -import { Users as UsersIcon, Plus, Pencil, Trash2, X, Check, AlertCircle, Globe, Shield, Power, PowerOff } from 'lucide-react'; +import { Users as UsersIcon, Plus, Pencil, Trash2, X, Check, AlertCircle, Globe, Shield, Power, PowerOff, ChevronDown } from 'lucide-react'; interface User { id: number; @@ -56,6 +56,9 @@ export function Users() { const [originsLoading, setOriginsLoading] = useState(true); const [originsError, setOriginsError] = useState(null); const [showOriginModal, setShowOriginModal] = useState(false); + + // Add dropdown state + const [showAddDropdown, setShowAddDropdown] = useState(false); const [editingOrigin, setEditingOrigin] = useState(null); const [originFormData, setOriginFormData] = useState({ name: '', origin_type: 'domain', origin_value: '', description: '' }); const [originFormError, setOriginFormError] = useState(null); @@ -344,23 +347,45 @@ export function Users() {

Manage users and trusted origins

- {activeTab === 'users' ? ( +
- ) : ( - - )} + {showAddDropdown && ( +
+ + +
+ )} +
{/* Tabs */}