
import { useState } from "react";
import CircuitStandSecondTab01 from "./circuitstandsecondtab/CircuitStandSecondTab01";
import CircuitStandSecondTab02 from "./circuitstandsecondtab/CircuitStandSecondTab02";

export default function CircuitStandTab02({setTabNum}){
    const [secondTab, setSecondTab] = useState(1);
    return(
        <>
            <div className="module-box-tab">
                <button className={`module-btn ${secondTab === 1 ? 'act':''}`} onClick={() => setSecondTab(1)}>自動回路割り当て</button>
                <button className={`module-btn ${secondTab === 2 ? 'act':''}`} onClick={() => setSecondTab(2)}>手動回路割当</button>
            </div>
            {secondTab === 1 && <CircuitStandSecondTab01/>}
            {secondTab === 2 && <CircuitStandSecondTab02/>}
            <div className="grid-btn-wrap">
                <button className="btn-frame modal mr5" onClick={() => setTabNum(1)}>以前</button>
                <button className="btn-frame modal act" onClick={() => setTabNum(3)}>保存</button>
            </div>
        </>
    )
}