88 lines
3.1 KiB
TypeScript
88 lines
3.1 KiB
TypeScript
import React, { useState } from "react";
|
|
|
|
import { Button } from "@common/components";
|
|
|
|
import Indicators from "./Indicators";
|
|
import RegionalGrid from "./RegionalGrid";
|
|
import ScatterChart from "./ScatterChart";
|
|
import VerificationList from "./VerificationList";
|
|
|
|
interface HbVerificationDetailProps {
|
|
anlsSn: number;
|
|
onBack: () => void;
|
|
}
|
|
|
|
const HbVerificationDetail: React.FC<HbVerificationDetailProps> = ({
|
|
anlsSn,
|
|
onBack,
|
|
}) => {
|
|
const [selectedVrfcTrgtSn, setSelectedVrfcTrgtSn] = useState<string | null>(
|
|
null,
|
|
);
|
|
const [selectedSido, setSelectedSido] = useState<string | null>(null);
|
|
|
|
return (
|
|
<div className="flex flex-col">
|
|
<div className="flex items-center gap-4 p-4">
|
|
<Button
|
|
variant="ghost"
|
|
size="icon"
|
|
color="white"
|
|
onClick={onBack}
|
|
className=""
|
|
>
|
|
<i className="diveicon di-arrow-back" />
|
|
<span className="sr-only">목록으로 돌아가기</span>
|
|
</Button>
|
|
<h2 className="text-[1.8rem] font-bold text-title">
|
|
검증 상세
|
|
</h2>
|
|
</div>
|
|
|
|
<div className="flex flex-col gap-4">
|
|
<div className="h-[20rem] overflow-y-auto">
|
|
<VerificationList
|
|
anlsSn={anlsSn}
|
|
selectedVrfcTrgtSn={selectedVrfcTrgtSn}
|
|
onSelect={setSelectedVrfcTrgtSn}
|
|
/>
|
|
</div>
|
|
|
|
<div className="card card-border !m-4">
|
|
<h3 className="p-4 pb-0 text-[1.8rem] font-bold text-title">
|
|
검증 결과 상세
|
|
</h3>
|
|
<div className="flex">
|
|
<div className="flex-[0.5] p-4">
|
|
<RegionalGrid
|
|
anlsSn={anlsSn}
|
|
vrfcTrgtSn={selectedVrfcTrgtSn}
|
|
selectedSido={selectedSido}
|
|
onSidoSelect={setSelectedSido}
|
|
/>
|
|
</div>
|
|
<div className="flex flex-[0.5] flex-col gap-4 p-4 pt-[4.8rem]">
|
|
<div className="flex-[0.5]">
|
|
<Indicators
|
|
anlsSn={anlsSn}
|
|
vrfcTrgtSn={selectedVrfcTrgtSn}
|
|
/>
|
|
</div>
|
|
|
|
<div className="flex-[0.5]">
|
|
<ScatterChart
|
|
anlsSn={anlsSn}
|
|
vrfcTrgtSn={selectedVrfcTrgtSn}
|
|
selectedSido={selectedSido}
|
|
/>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
);
|
|
};
|
|
|
|
export default HbVerificationDetail;
|