Skip to content

Commit 228eff8

Browse files
author
HarveyQue
committed
refactor(ResourceActionDialog): 替换Dialog组件为LocalDialog并移除size属性
使用LocalDialog组件替代原有Dialog组件,并移除不再需要的size属性,以保持组件一致性
1 parent 56fc885 commit 228eff8

File tree

1 file changed

+7
-8
lines changed

1 file changed

+7
-8
lines changed

web/src/app/dashboard/environment/components/ResourceActionDialog.tsx

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,14 @@
1111
*/
1212

1313
import { Button } from '@/components/ui/button';
14-
import {
15-
Dialog,
16-
DialogContent,
17-
DialogDescription,
18-
DialogHeader,
19-
DialogTitle,
20-
} from '@/components/ui/dialog';
2114
import { Label } from '@/components/ui/label';
15+
import {
16+
LocalDialog as Dialog,
17+
LocalDialogContent as DialogContent,
18+
LocalDialogDescription as DialogDescription,
19+
LocalDialogHeader as DialogHeader,
20+
LocalDialogTitle as DialogTitle,
21+
} from '@/components/ui/local-dialog';
2222
import type { DeviceActionInfo, ResourceTemplate } from '@/types/material';
2323
import Editor, { loader } from '@monaco-editor/react';
2424
import { ChevronRight, Loader2, Play, Sparkles } from 'lucide-react';
@@ -130,7 +130,6 @@ export default function ResourceActionDialog({
130130
if (!open) resetState();
131131
onOpenChange(open);
132132
}}
133-
size="5xl"
134133
>
135134
<DialogContent className="max-w-5xl w-[95vw] h-[90vh] overflow-hidden flex flex-col p-0">
136135
<DialogHeader className="px-4 sm:px-6 pt-4 sm:pt-6 pb-3 sm:pb-4 border-b border-neutral-200 dark:border-neutral-800 flex-shrink-0">

0 commit comments

Comments
 (0)