feat: 일시정지 버튼을 눌렀을 때 별의 움직임이 함께 멈춤
This commit is contained in:
@@ -8,7 +8,6 @@ import {
|
||||
DialogHeader,
|
||||
DialogTitle,
|
||||
} from "@/components/ui/dialog";
|
||||
import { useFlightSession } from "@/features/flight-session/model/useFlightSession";
|
||||
import { saveCurrentVoyage, saveToHistory } from "@/shared/lib/store";
|
||||
import { Voyage, VoyageStatus } from "@/shared/types";
|
||||
|
||||
@@ -23,16 +22,24 @@ const statusOptions: { value: VoyageStatus; label: string; desc: string }[] = [
|
||||
];
|
||||
const FINISH_HOLD_MS = 1000;
|
||||
|
||||
export function FlightHudWidget() {
|
||||
type FlightHudWidgetProps = {
|
||||
voyage: Voyage | null;
|
||||
isPaused: boolean;
|
||||
formattedTime: string;
|
||||
isCountdownCompleted: boolean;
|
||||
handlePauseToggle: () => void;
|
||||
handleFinish: () => Voyage | null;
|
||||
};
|
||||
|
||||
export function FlightHudWidget({
|
||||
voyage,
|
||||
isPaused,
|
||||
formattedTime,
|
||||
isCountdownCompleted,
|
||||
handlePauseToggle,
|
||||
handleFinish,
|
||||
}: FlightHudWidgetProps) {
|
||||
const router = useRouter();
|
||||
const {
|
||||
voyage,
|
||||
isPaused,
|
||||
formattedTime,
|
||||
isCountdownCompleted,
|
||||
handlePauseToggle,
|
||||
handleFinish,
|
||||
} = useFlightSession();
|
||||
const [isDebriefOpen, setIsDebriefOpen] = useState(false);
|
||||
const [finishedVoyage, setFinishedVoyage] = useState<Voyage | null>(null);
|
||||
const [status, setStatus] = useState<VoyageStatus | null>(null);
|
||||
|
||||
Reference in New Issue
Block a user