import React, { useState } from 'react'; import { Modal, Table, Button, Group, TextInput, PasswordInput, Select, Stack, Text, ActionIcon, Box, } from '@mantine/core'; import { IconTrash, IconEdit, IconPlus } from '@tabler/icons-react'; // Dummy data - replace with actual API calls in production const DUMMY_USERS = [ { id: 1, email: 'admin@example.com', displayName: 'Admin User', role: 'admin', createdAt: '2024-01-01', }, { id: 2, email: 'editor@example.com', displayName: 'Editor User', role: 'editor', createdAt: '2024-01-02', }, { id: 3, email: 'viewer@example.com', displayName: 'Viewer User', role: 'viewer', createdAt: '2024-01-03', }, ]; const CreateUserModal = ({ opened, onClose, onCreateUser }) => { const [email, setEmail] = useState(''); const [password, setPassword] = useState(''); const [displayName, setDisplayName] = useState(''); const [role, setRole] = useState('viewer'); const handleSubmit = () => { onCreateUser({ email, password, displayName, role }); setEmail(''); setPassword(''); setDisplayName(''); setRole('viewer'); onClose(); }; return ( setEmail(e.currentTarget.value)} placeholder="user@example.com" /> setDisplayName(e.currentTarget.value)} placeholder="John Doe" /> setPassword(e.currentTarget.value)} placeholder="Enter password" />