import { useState } from 'react';
import { PATHS } from '@/shared/constants/paths';
import { useNavigate } from '@/shared/lib/hooks/use-navigate';
import { SettlementAgencyTab } from '@/entities/additional-service/ui/settlement-agency-tab'; 
import { SettlementAgencyManageWrap } from '@/entities/additional-service/ui/settlement-agency-manage-wrap';
import { SettlementAgencyTabKeys } from '@/entities/additional-service/model/types';
import { HeaderType } from '@/entities/common/model/types';
import { 
	useSetHeaderTitle,
	useSetHeaderType,
	useSetFooterMode,
  useSetOnBack
} from '@/widgets/sub-layout/use-sub-layout';

export const SettlementAgencyManagePage = () => {
  const { navigate } = useNavigate();

  const [activeTab, setActiveTab] = useState<SettlementAgencyTabKeys>(SettlementAgencyTabKeys.Manage);

  useSetHeaderTitle('정산대행');
  useSetHeaderType(HeaderType.LeftArrow);
  useSetFooterMode(false);
  useSetOnBack(() => {
    navigate(PATHS.home);
  });

  return (
    <>
      <main>
        <div className="tab-content">
          <div className="tab-pane sub active">
            <SettlementAgencyTab activeTab={ activeTab }></SettlementAgencyTab>
            <SettlementAgencyManageWrap></SettlementAgencyManageWrap>
          </div>
        </div>
      </main>
    </>
  );
};