mirror of
https://github.com/pacnpal/thrilltrack-explorer.git
synced 2025-12-28 13:06:58 -05:00
Wrap forms with error boundaries
This commit is contained in:
@@ -18,6 +18,7 @@ import { getErrorMessage, handleNonCriticalError } from '@/lib/errorHandler';
|
||||
import { useAuthModal } from '@/hooks/useAuthModal';
|
||||
import { useDocumentTitle } from '@/hooks/useDocumentTitle';
|
||||
import { useOpenGraph } from '@/hooks/useOpenGraph';
|
||||
import { SubmissionErrorBoundary } from '@/components/error/SubmissionErrorBoundary';
|
||||
|
||||
export default function ParkRides() {
|
||||
const { parkSlug } = useParams<{ parkSlug: string }>();
|
||||
@@ -353,12 +354,14 @@ export default function ParkRides() {
|
||||
{/* Create Modal */}
|
||||
<Dialog open={isCreateModalOpen} onOpenChange={setIsCreateModalOpen}>
|
||||
<DialogContent className="max-w-4xl max-h-[90vh] overflow-y-auto">
|
||||
<RideForm
|
||||
onSubmit={handleCreateSubmit as any}
|
||||
onCancel={() => setIsCreateModalOpen(false)}
|
||||
isEditing={false}
|
||||
initialData={{ park_id: park.id }}
|
||||
/>
|
||||
<SubmissionErrorBoundary>
|
||||
<RideForm
|
||||
onSubmit={handleCreateSubmit as any}
|
||||
onCancel={() => setIsCreateModalOpen(false)}
|
||||
isEditing={false}
|
||||
initialData={{ park_id: park.id }}
|
||||
/>
|
||||
</SubmissionErrorBoundary>
|
||||
</DialogContent>
|
||||
</Dialog>
|
||||
</main>
|
||||
|
||||
Reference in New Issue
Block a user