Side Sheets instead of Modals
This commit is contained in:
@@ -12,6 +12,7 @@ import Snackbar from './Snackbar';
|
||||
import { Button } from './ui/Button';
|
||||
import { Card } from './ui/Card';
|
||||
import { Modal } from './ui/Modal';
|
||||
import { SideSheet } from './ui/SideSheet';
|
||||
|
||||
interface ProfileProps {
|
||||
user: User;
|
||||
@@ -601,11 +602,11 @@ const Profile: React.FC<ProfileProps> = ({ user, onLogout, lang, onLanguageChang
|
||||
|
||||
{/* Edit Exercise Modal */}
|
||||
{editingExercise && (
|
||||
<Modal
|
||||
<SideSheet
|
||||
isOpen={!!editingExercise}
|
||||
onClose={() => setEditingExercise(null)}
|
||||
title={t('edit', lang)}
|
||||
maxWidth="sm"
|
||||
width="md"
|
||||
>
|
||||
<div className="space-y-4">
|
||||
<div className="bg-surface-container-high rounded-t-lg border-b border-outline-variant px-3 py-2">
|
||||
@@ -632,7 +633,7 @@ const Profile: React.FC<ProfileProps> = ({ user, onLogout, lang, onLanguageChang
|
||||
<Button onClick={handleSaveExerciseEdit}>{t('save', lang)}</Button>
|
||||
</div>
|
||||
</div>
|
||||
</Modal>
|
||||
</SideSheet>
|
||||
)}
|
||||
|
||||
{/* Create Exercise Modal */}
|
||||
|
||||
Reference in New Issue
Block a user